11 lines
5.8 MiB
11 lines
5.8 MiB
/**
|
||
* Kendo UI v2025.3.1002 (http://www.telerik.com/kendo-ui)
|
||
* Copyright 2025 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(){const e=t;function t(e,n){const i=s();return t=function(n,r){let o=i[n-=458];if(void 0===t.HNXGMp){t.hsTxhI=function(e){let t="",n="";for(let n,i,r=0,o=0;i=e.charAt(o++);~i&&(n=r%4?64*n+i:i,r++%4)?t+=String.fromCharCode(255&n>>(-2*r&6)):0)i="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=".indexOf(i);for(let e=0,i=t.length;e<i;e++)n+="%"+("00"+t.charCodeAt(e).toString(16)).slice(-2);return decodeURIComponent(n)},e=arguments,t.HNXGMp=!0}const a=n+i[0],s=e[a];return s?o=s:(o=t.hsTxhI(o),e[a]=o),o},t(e,n)}!function(e){const n=t,i=e();for(;;)try{if(910208===-parseInt(n(597))/1+-parseInt(n(469))/2+-parseInt(n(631))/3+parseInt(n(592))/4*(parseInt(n(616))/5)+parseInt(n(589))/6*(parseInt(n(622))/7)+-parseInt(n(541))/8*(-parseInt(n(490))/9)+-parseInt(n(561))/10*(-parseInt(n(566))/11))break;i.push(i.shift())}catch(e){i.push(i.shift())}}(s);const n=e(582),i=e(590),r=e(464);function o(t){const n=e;return Math[n(546)](t[n(640)]()/1e3)}function a(t,n){const i=e,r=new Date(1e3*t);return r[i(636)](r[i(555)]()+n),o(r)}function s(){const e=["ls0Tls1cruDjtIbqvujmsumGs0vzls0Tls0","vg8Gy29UDgLUDwuGDxnPBMCGB3vYihbYB2r1y3qSignVBNnPzgvYihvWz3jHzgLUzYb0BYbHignVBw1LCMnPywWGBgLJzw5Zzs4G","vw5RBM93BIbSAwnLBNnLigv2AwrLBMnLihr5Cgu","DvrmvhK","ndG5mJG5wNrXzwTk","icbby2nLC3mGDg8GDgHLigXHDgvZDcb1CgrHDgvZigfUzcbZDxbWB3j0ihjLCxvPCMvZigeGpgeGAhjLzJ0I","zNDuAey","DuzLreu","vwrwt2y","swXUqK8","icbmzwfYBIbTB3jLigfIB3v0ia","D2fYBG","igHHCYbLEhbPCMvKia","Dxvbywy","uKTnquy","BgLJzw5Zzuv4CgLYyxrPB25eyxrL","icbuBYbJB250Aw51zsb1C2LUzYbVDxiGChjVzhvJDcWGy29UC2LKzxiGDxbNCMfKAw5NihrVigeGy29TBwvYy2LHBcbSAwnLBNnLoIbODhrWCZOVl3bYz3jLC3mUy28Vm0m5BxiXtq","zw5JB2rL","BMrtt3a","zgvJB2rL","igfUzcbPCYbUB3qGDMfSAwqGzM9Yia","ihzLCNnPB24G","BLDlEhq","nvbmC21cBG","u0Hblti1nG","DhjPBq","sNPbt0m","BMfTzq","C3rYAw5NAwz5","mZqZntK0m2j3DMzRtG","C3bRAq","igXPy2vUC2LUzZWVyt4U","y2XLyxi","vwDLBLq","igLZig5VDcbSAxn0zwqGAw4GEw91CIbJDxjYzw50igXPy2vUC2uGzMLSzs4k","zgf0yq","su5HEfC","su5gtW","mtK5otqZnhbPu3vVvq","CvLhtK0","z2Levxu","y25ot1q","iJ52ywXPzcbSAwnLBNnLpc9HpI4","C2v0rgf0zq","ls0Tls1ftKqGufvcteLdieTfws0Tls0T","reHSBwC","igXPy2vUC2LUzYbHDca","z2v0vgLTzq","B2jQzwn0","veTmmJaZ","yxrVyIbPCYb1BMrLzMLUzwq","vg8Gy29UDgLUDwuGDxnPBMCGDgHLihbYB2r1y3qSigLUC3rHBgWGysa8ysbOCMvMpsi","AgrJDuS","D2PQwxq","y29Kzq","CMvWBgfJzq","tgLJzw5ZzsbRzxKGBwLZC2LUzYbMB3iG","s2LqEge","rwHVAue","zNjVBq","A3zzBvG","iJ5OB3CGDg8GC2v0ihvWigeGBgLJzw5ZzsbRzxK8l2e+lG","ls0Tls1cruDjtIbqvujmsumGs0vzls0Tls0ktuLjqKLQqu5cz2TXAgTPrZL3mejbuuvgqufpq0froefnsuLcq2Dlq0frrueYBw5vvK1TA3rOmNGRtI9prhn6rWPprKLzqKW2tK9pmvHxuMOXD2TTzwnlDuX6AuPeAez6mfDrBxLpALKZnfLTzZLWthvcqtLru1DYCLP1DLb3ndbocM0Wwc9hqM10DezTue52y2eZv21kmM9lttDqCeXPvvu5zJDpDJvxzuLyBNGRk3rZl0Xdl09cn0z0wITmAvjNsJCkmg1ABLbLvg9NzezYqvnMmhPtuuP2ngPTwdG0meXqytzUB21xzvvNsvzhueXmvKKXneDPyJHeBcTUt2nRCunoyWPRqvvvAZrjqKy2n0r1zLj0oxPrEvj4zZK5ExnHA3ziwdjtrgjKr3zjqMr4v3H2AgHTCKjVzwL4mhvtvNrhmMDTcMPKDLnXBfbkvMr2twjRmvHLmITtvwXKsLbYEeGXvNjuwwvsvxq0ExfxEhKXnM5gsLveAJLLEfOYmdjynfriA1uksLfjrefrquikls0Tls1ftKqGufvcteLdieTfws0Tls0T","ww91CIbSAwnLBNnLigLZig5VDcb2ywXPzcbMB3iG","ChjVzhvJDe5HBwu","zxHWAxjHDgLVBG","C2nYAxb0s2v5","mtCZoti3ngHoqM1fsG","iJ52ywXPzcbSAwnLBNnLpc9HpI4G","v0fstG","z2v0rNvSBfLLyxi","DhLWzq","rurLCLy","ChvZAa","veTmmJa0","DxnHz2u","ywrK","AgfZ","ww91CIbJDxjYzw50igXPy2vUC2uGAgfZigv4CgLYzwqGB24G","ww91CIbuCMLHBcbSAwnLBNnLihDPBgWGzxHWAxjLigLUia","CMvKAxn0CMLIDxrLzej5","t2reCw8","BM90AwzPy2f0Aw9UtwvZC2fNzq","DxnLCKLK","Dg9mB2nHBgveyxrLu3rYAw5N","tM8GBgLJzw5ZzsbMB3vUzcbMB3iG","DKjtufC","z3jVDxbfBMq","mtC5mdfJtvvMteS","C2v0","Aw1WB3j0s2v5","icbuBYbHy3f1AxjLigeGy29TBwvYy2LHBcbSAwnLBNnLlcb2AxnPDcbODhrWCZOVl3bYz3jLC3mUy28Vm1b5seLVsa","z2v0tw9UDgG","DMvYAwz5","CuPtu2q","uMvUzxCGpgeGAhjLzJ0IAhr0Chm6lY9WCMDYzxnZlMnVlZnqD1foAteIpNLVDxiGBgLJzw5ZztWVyt4Gyw5KigrVD25SB2fKigeGBMv3igXPy2vUC2uGA2v5lG","zMLSDgvY","z3jVDxa","yMTzz0y","q1bZruG","y2f0y2G","r3HAvuO","CgvYCgv0DwfS","uK95qMu","icbuBYbKB3DUBg9HzcbHigXPy2vUC2uGA2v5igzPBguSihzPC2L0igH0DhbZoI8VChjNCMvZCY5JBY8ZuhDrtuTA","C29YDa","DvD5uwG","ywXNB3jPDgHT","uLnbu1nblvblq1mXlxyXxZu","BwfW","ww91CIb0CMLHBcbSAwnLBNnLigzVCIa","A09kDLi","DMvYC2LVBG","lIbuAguGChjVzhvJDcb3yxmGChvIBgLZAgvKig9Uia","Dw5KzwzPBMvK","DuHyA3O","z2v0","ChvIBgLZAerHDgu","DhLW","C3bSAwnL","DgHLBG","zMLUza","C2XPy2u","tvfXDNe","icbszw5LDYb5B3vYigXPy2vUC2uGyxqGAhr0Chm6lY9WCMDYzxnZlMnVlZnqEdLTnuy","BwvZC2fNzq","ven5Afu","terPq2y","tKfvEfa","igfNBY4G","zNvUy3rPB24","Aw5JBhvKzxm","ChjVzhvJDhm","sw52ywXPzcbSAwnLBNnLigv2AwrLBMnL","ChjVzhvJDenVzgu","EertsLq","ww91CIb0CMLHBcbOyxmGzxHWAxjLzca","DxrMoa","ywXS","ndi0zfLHDuje","igrHEsHZksbHz28UcG","t3HowxK","zNjVBunOyxjdB2rL","CfPryNK","zMXVB3i","BgLJzw5Zzxm","C3bSAxq","Exvfv28","igrHEsHZks4k","qLrRtNO","DgLTzxn0yw1W","BgLJzw5ZAw5Nrg9JC1vYBa","ChjVzhvJDenVzgvZ","z2v0rgf0zq","wfvkCKq","C3vIrxe","AxnbCNjHEq","C3vIDgXL","veTmmJaY","mtqWotb5EK5RyLG","lcb3zsbOB3bLihLVDsbLBMPVEwvKihLVDxiGDhjPywWGCgvYAw9KlGO","CgfYC2u","icbuAgfUAYb5B3uGzM9YihrYEwLUzYbVDxqG","wfjeuvm","ndK3mLbyuKHnwq","rw5fuKS","CgfYC2vjBNq","wfvXC20","AwXyq20","C3vIC2nYAxb0Aw9U","icbbigXPy2vUC2uGA2v5igLZihjLCxvPCMvKigzVCIbIB3rOihbHAwqGyw5KihrYAwfSihvZywDLlIbmzwfYBIa8ysbOCMvMpsi","u3rVuxq","DhjPywW","y2HHCKnVzgvbDa","veDctxi","CKf4Dxu","z1H6quu","veTmmJaX","yMfZzty0","BgvUz3rO","vgvSzxjPAYbmAwnLBNnLiev2AwrLBMnL","q0vbr0y","tgvHCM4GBw9YzsbHyM91Dca8ysbOCMvMpsjODhrWCZOVl3bYz3jLC3mUy28Vm1b3uu1Kwci+","C2v2zxjPDhK","tM8GvgvSzxjPAYbHBMqGs2vUzg8GvuKGtgLJzw5ZzsbMB3vUzc4k","AM9PBG","Dg9tDhjPBMC","nNjiq0DIzG","vgvSzxjPAYbHBMqGs2vUzg8GvuKGtgLJzw5ZAw5N","Ee1Hvu8","nJGWotKXmNPXy3D4AW"];return(s=function(){return e})()}function l(){return o(new Date)}function c(t){const n=e,i=function(t){const n=e;if(typeof atob===n(532)){if(n(488)==n(488))return atob(t);_0x3f9147=new _0x142e0d(_0xa4812e[n(466)],_0x382d22[n(514)],_0x2febde[n(553)])}if(typeof Buffer===n(532)){if(n(474)==n(474))return Buffer[n(461)](t,n(580))[n(588)](n(539));_0x2b2088[n(521)](3,0,"")}throw new Error(n(643))}(t),r=new Uint8Array(i[n(581)]);for(let e=0;e<i[n(581)];e++){if(n(565)!=n(565))return _0x1ec36d[n(546)](_0x4f8442[n(640)]()/1e3);r[e]=i[n(575)](e)}return r}function d(t){const n=e;return c(t[n(648)](/-/g,"+")[n(648)](/_/g,"/"))}function h(e){return new Date(1e3*e)}function u(t,n){const i=e,r=h(n);return t>new Date(r[i(472)](),r[i(494)](),r[i(555)]()+1)[i(640)]()/1e3}function p(t,n){const i=e;var r,o;let s=[];if((null===(r=t[i(547)])||void 0===r?void 0:r[i(581)])>0){var c,h;if(i(460)===i(573))return(null===(c=_0x1d71c2[i(547)])||void 0===c?void 0:c[i(581)])>0&&_0x1f2346[i(540)](null===(h=_0x3d6149[i(547)])||void 0===h?void 0:h[i(511)]((e=>_0x2ea74c(e,_0x2fde18))))[i(522)]((()=>{_0x3b5989=!0}))[i(502)]((()=>{_0x260db5=!1,_0x563f2c[i(625)]()})),_0x23b3af;s=t[i(547)][i(511)]((t=>function(t){const n=e,i=t[n(548)](".")[1],r=String[n(544)](...d(i));return JSON[n(563)](r)}(t)))}else if((null===(o=t[i(534)])||void 0===o?void 0:o[i(581)])>0){var p,f;if(i(556)!=i(556))return _0x174020[i(536)]===_0xe32b2c[i(647)]||(null===(p=_0xcbbcd9[i(482)])||void 0===p?void 0:p[i(533)](_0x1bcf3a[i(647)]))||(null===(f=_0x3585ec[i(554)])||void 0===f?void 0:f[i(533)](_0x347526[i(647)]));s=t[i(534)][i(511)]((e=>({type:e[i(574)]?i(574):i(504),code:e[i(647)],expiration:e[i(608)],licenseId:null,userId:t[i(485)]})))}return function(t,n){const i=e,r=n[i(498)]((e=>e[i(473)]!==i(477)))[i(498)]((e=>{const n=i;var r,o;if(n(557)==n(557))return t[n(536)]===e[n(647)]||(null===(r=t[n(482)])||void 0===r?void 0:r[n(533)](e[n(647)]))||(null===(o=t[n(554)])||void 0===o?void 0:o[n(533)](e[n(647)]));_0xe9a631=new _0x2ab351(_0x4e77cc[n(466)],_0x40763d[n(514)],_0x5859bd[n(553)])}))[i(507)](((e,t)=>t[i(467)]-e[i(467)]));return r[i(523)]((e=>e[i(473)]===i(571)&&!u(l(),e[i(467)])))||r[i(523)]((e=>e[i(473)]===i(504)&&!u(t[i(519)],e[i(467)])))||r[i(523)]((e=>e[i(473)]===i(571)&&!u(a(l(),10),e[i(467)])))||r[i(523)]((e=>e[i(473)]===i(574)&&!u(l(),e[i(467)])))||r[i(523)]((e=>e[i(473)]===i(571)))||r[i(523)]((e=>e[i(473)]===i(504)))||r[i(523)]((e=>e[i(473)]===i(574)))}(n,s)}class f{constructor(t,n,i){const r=e;this[r(466)]=t,this[r(585)]=r(471),this[r(647)]=r(579),this[r(527)]=r(586)+r(506),this[r(484)]=r(458)+t+" v"+n+"."+(r(572)+i+r(463))}}class m{constructor(t,n,i){const r=e;this[r(466)]=t,this[r(585)]=r(471),this[r(647)]=r(560),this[r(527)]=t+r(627)+(r(603)+t+r(639)+i),this[r(484)]=r(487)+t+" v"+n+"."+(r(598)+i+r(635))}}class g{constructor(t,n,i){const r=e;this[r(466)]=t,this[r(585)]=r(471),this[r(647)]=r(642),this[r(527)]=r(538)+i+r(542)+(r(564)+t+r(562))+r(609),this[r(484)]=r(512)+t+" v"+n+r(605)+i+r(531)+r(594)+(r(584)+t+r(624))}}class v{constructor(t,n,i,r,o){const a=e;this[a(466)]=t,this[a(585)]=a(471),this[a(647)]=a(476);const s=i?a(614)+i:"";this[a(527)]=a(480)+n[a(486)]()+a(613)+""+t+s+a(515)+r[a(486)]()+".\n"+a(526),this[a(484)]=a(465)+t+" v"+i+". "+(a(644)+o+a(470))+a(497)}}class _{constructor(t,n){const i=e;this[i(466)]=t,this[i(585)]=i(630),this[i(527)]=i(481)+-n+i(550)+i(493)}}async function b(t,i){const r=e;if(typeof crypto!==r(641)||typeof crypto[r(559)]!==r(641)||typeof TextEncoder!==r(532)||typeof TextDecoder!==r(532)){if(r(529)!==r(578))return;{const e=_0x12d2c6[r(563)](_0x9f2c78(_0x43319b));_0x5e1466[r(558)](e[3])&&e[r(521)](3,0,"");const t={products:e[1][r(511)]((([e,t,n])=>({code:e,licenseExpirationDate:t,trial:_0x2b8ae3(n)}))),userId:e[2],integrity:e[3],licenses:e[4],scriptKey:!0};try{const e=_0x212110[r(563)](_0x2eccfe[r(628)]);t[r(534)]=[...e[r(534)],...t[r(534)]],t[r(547)]=[...e[r(547)],...t[r(547)]]}catch(e){}_0x53734a[r(628)]=_0x1e6d93[r(621)](t)}}const o=crypto[r(559)],[a,s,l]=t[r(548)]("."),h=d(l),u=new TextEncoder,p=new TextDecoder,f=u[r(610)](a+"."+s),m=p[r(612)](d(a));if(!(JSON[r(563)](m)[r(520)]===n)){if(r(629)!==r(505))throw new Error(r(595));{const e=_0x2b8c6b(_0x4e37b9),t=new _0x4d911f(e[r(581)]);for(let n=0;n<e[r(581)];n++)t[n]=e[r(575)](n);return t}}const g=await function(t){const n=e,i=n(593),r=n(637),o=c(t[n(648)](i,"")[n(648)](r,"")[n(648)](/\n/gm,""));return crypto[n(559)][n(492)](n(623),o,{name:n(510),hash:n(617)},!0,[n(495)])}(i);if(!await o[r(495)](g[r(509)],g,h,f)){if(r(500)!==r(462))throw new Error(r(535));_0x7e2b1a=_0x50c9e0(_0x465f44,_0x32b805)}}const w={data:" {} "};let y=r;const k=new Map,x=new Set;let C=!0;function S(t){const n=e,i=JSON[n(563)](w[n(628)]),r=!i[n(468)]&&!i[n(552)],s=i[n(468)]&&typeof KendoLicensing===n(516);let c,d,x=!1;if(r||s||!(t=>{const n=e;var i,r;return(null===(i=t[n(547)])||void 0===i?void 0:i[n(581)])>0&&(n(591)===n(530)?_0x421b4d[n(499)](_0x297151):Promise[n(540)](null===(r=t[n(547)])||void 0===r?void 0:r[n(511)]((e=>b(e,y))))[n(522)]((()=>{const e=n;e(567)!==e(576)?C=!0:(_0x27973b=new _0x4f1083(_0x13c3b4[e(466)],_0x109720),_0x5328a8=!0)}))[n(502)]((()=>{const e=n;if(e(615)!=e(615))return _0x4d94b2(_0x3d509c);C=!1,k[e(625)]()}))),C})(i)){if(n(601)!=n(601))return new _0x43ed92(1e3*_0x537ca5);c=new f(t[n(466)],t[n(514)],t[n(553)])}else if(n(549)===n(537)){this[n(466)]=_0x23c718,this[n(585)]=n(471),this[n(647)]=n(476);const e=_0x375945?n(614)+_0xdd19e5:"";this[n(527)]=n(480)+_0x42ec16[n(486)]()+n(613)+""+_0x31dafe+e+n(515)+_0x5c8ae7[n(486)]()+".\n"+n(526),this[n(484)]=n(465)+_0x338eab+" v"+_0x5c788b+". "+(n(644)+_0x4dacc1+n(470))+n(497)}else if(d=p(i,t),d){if(d[n(473)]===n(574)){if(n(632)===n(543)){var S,T;let e=[];return(null===(S=_0xa7e67c[n(547)])||void 0===S?void 0:S[n(581)])>0?e=_0x1a819d[n(547)][n(511)]((e=>_0xb4c6fc(e))):(null===(T=_0xfadd7e[n(534)])||void 0===T?void 0:T[n(581)])>0&&(e=_0xb01d9f[n(534)][n(511)]((e=>({type:e[n(574)]?n(574):n(504),code:e[n(647)],expiration:e[n(608)],licenseId:null,userId:_0x496a35[n(485)]})))),_0x3f58c2(_0x352e4e,e)}{const i=function(t){const n=e,i=l()-o(t);return Math[n(546)](i/86400)}(h(d[n(467)]));if(u(l(),d[n(467)])){if(n(626)!=n(626)){if(_0x155598[n(479)](_0x12d0ed[n(620)]))return _0x4d8fdc[n(518)](_0x1622cf[n(620)]);const{isLicenseValid:e,message:t}=_0x51f17c(_0x272926),i=_0x453e2c(_0x2b4069);return t&&!_0x555221[n(479)](i)&&(_0x352892(t,_0x344cab),_0x51749a[n(478)](i)),_0x2b72f9[n(491)](_0x111b72[n(620)],e),e}c=new g(t[n(466)],t[n(514)],i)}else n(600)===n(513)?(this[n(466)]=_0x35976e,this[n(585)]=n(471),this[n(647)]=n(579),this[n(527)]=n(586)+n(506),this[n(484)]=n(458)+_0x285ad0+" v"+_0x35d2a3+"."+(n(572)+_0x18b9b1+n(463))):(c=new _(t[n(466)],i),x=!0)}}else if(d[n(473)]===n(504)||d[n(473)]===n(571)){if(n(545)===n(570))throw new _0x5f0f00(n(535));{let e=d[n(467)];if(d[n(473)]===n(571)){if(n(607)!=n(607))return _0x4365ad[n(461)](_0x407494,n(580))[n(588)](n(539));e=a(e,10)}if(u(t[n(519)],e)){if(n(634)!=n(634))throw new _0x285b82(n(595));c=new v(t[n(466)],h(d[n(467)]),t[n(514)],h(t[n(519)]),t[n(553)])}else n(619)==n(619)?x=!0:(_0x1e4198(_0x431298,_0x4a05b7),_0x39bec4[n(478)](_0x485458))}}}else{if(n(503)===n(459)){const e=_0x469978^_0x2a41e;return _0x1ec978=_0x3937d9,e}c=new m(t[n(466)],t[n(514)],t[n(553)])}const M=d,A=(null==M?void 0:M[n(467)])?h(M[n(467)]):void 0;return{isLicenseValid:x,licenseType:null==d?void 0:d[n(473)],licenseProductCode:null==M?void 0:M[n(647)],expiration:A,message:c}}function T(t){const n=e;if(k[n(479)](t[n(620)])){if(n(577)!==n(606))return k[n(518)](t[n(620)]);_0x473c56[n(489)]()}const{isLicenseValid:r,message:o}=S(t),a=(s=t)[e(536)]||s[e(554)][0];var s;return o&&!x[n(479)](a)&&(n(602)!==n(508)?(function(t,n){const r=e;if(typeof console===r(641))if(r(638)===r(599))_0x3f8ac1=_0x1445aa[r(547)][r(511)]((e=>_0x5c7829(e)));else{const e="["+t[r(585)]+"]["+i+"]"+(o?" "+o+":":"")+" "+n[r(466)],a=typeof console[r(499)]===r(532);if(a){if(r(583)===r(611)){if(typeof _0x3aa332===r(532))return _0x4ef116(_0x51dcdd);if(typeof _0x31ba6f===r(532))return _0x4e420a[r(461)](_0x513fbe,r(580))[r(588)](r(539));throw new _0x4e4ff7(r(643))}console[r(499)](e)}else r(633)!==r(646)?console[r(604)](e):_0x5c387f=!0;if(console[r(604)](t[r(527)]),a)if(r(483)===r(501)){const e=_0x4cbcb5[r(563)](_0x16b5e3[r(628)]);_0x3787f6[r(534)]=[...e[r(534)],..._0x4ec76c[r(534)]],_0x56ecb3[r(547)]=[...e[r(547)],..._0x2de826[r(547)]]}else console[r(489)]()}var o}(o,t),x[n(478)](a)):_0x5c92dc=new _0x2ff2a0(_0x47c79d[n(466)],_0x2ebc02[n(514)],_0x1f5410)),k[n(491)](t[n(620)],r),r}let M=null;try{M=Object.freeze(JSON.parse('{"productName":"Kendo UI","productCode":"KENDOUICOMPLETE","redistributedBy":["KENDOUI","UIASPCORE","KENDOMVC","KENDOUIMVC"],"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","name":"@progress/kendo-ui","version":"2025.3.1002","publishDate":1759395912,"productCodes":["KENDOUICOMPLETE","KENDOUI","UIASPCORE","KENDOMVC","KENDOUIMVC"]}'))}catch(e){M=Object.freeze({name:"@progress/kendo-ui",productName:"Kendo UI for jQuery",productCode:"KENDOUICOMPLETE",productCodes:["KENDOUICOMPLETE","KENDOUI","UIASPCORE","KENDOMVC","KENDOUIMVC"],redistributedBy:["KENDOUI","UIASPCORE","KENDOMVC","KENDOUIMVC"],publishDate:0,version:"0.0.0",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"})}const A=M;function D(e){return[/telerik\.com/,/progress\.com/,/stackblitz\.io/,/csb\.app/,/telerik\.io/].map((e=>e.test(window.location.hostname))).indexOf(!0)>-1||!1}const E=function(){return T(A)};const I=function(t){const n=e;try{if(n(496)!=n(496))return _0x430c4f[n(518)](_0x62bcc7[n(620)]);{const i=JSON[n(563)](function(t){const n=e,i=[],r=t[n(618)]();for(let e=0;e<r[n(581)];e+=2){if(n(645)===n(596)){const e=_0x312dfa[n(498)]((e=>e[n(473)]!==n(477)))[n(498)]((e=>{const t=n;var i,r;return _0xcbad92[t(536)]===e[t(647)]||(null===(i=_0xbac7c1[t(482)])||void 0===i?void 0:i[t(533)](e[t(647)]))||(null===(r=_0x11563c[t(554)])||void 0===r?void 0:r[t(533)](e[t(647)]))}))[n(507)](((e,t)=>t[n(467)]-e[n(467)])),t=()=>e[n(523)]((e=>e[n(473)]===n(504)&&!_0x1cb780(_0x56c1e5[n(519)],e[n(467)]))),i=()=>e[n(523)]((e=>e[n(473)]===n(571)&&!_0xf135d9(_0x2147ae(_0x5b8f04(),_0x2e9187),e[n(467)]))),r=()=>e[n(523)]((e=>e[n(473)]===n(574)&&!_0x203f66(_0x27b095(),e[n(467)]))),o=()=>e[n(523)]((e=>e[n(473)]===n(504))),a=()=>e[n(523)]((e=>e[n(473)]===n(571))),s=()=>e[n(523)]((e=>e[n(473)]===n(574)));return e[n(523)]((e=>e[n(473)]===n(571)&&!_0x1b6df6(_0x3e3f18(),e[n(467)])))||t()||i()||r()||a()||o()||s()}{const t=r[n(524)](e,e+2);i[n(475)](Number[n(568)](t,21))}}let o=66;return i[n(511)]((e=>{const t=n;if(t(517)==t(517)){const t=e^o;return o=e,t}}))[n(511)]((e=>String[n(544)](e)))[n(587)]("")}(t));if(Array[n(558)](i[3]))if(n(551)===n(528)){let e=_0x1afa26[n(467)];_0x505753[n(473)]===n(571)&&(e=_0x1e07ff(e,_0x2b0e20)),_0x5c052e(_0x1e314f[n(519)],e)?_0x50256e=new _0x3aeabd(_0x243779[n(466)],_0x482fe6(_0x3a63b4[n(467)]),_0x4fb6e8[n(514)],_0x193859(_0x97725e[n(519)]),_0x533287[n(553)]):_0x35d424=!0}else i[n(521)](3,0,"");const r={products:i[1][n(511)]((([e,t,n])=>({code:e,licenseExpirationDate:t,trial:Boolean(n)}))),userId:i[2],integrity:i[3],licenses:i[4],scriptKey:!0};try{if(n(525)!==n(569)){const e=JSON[n(563)](w[n(628)]);r[n(534)]=[...e[n(534)],...r[n(534)]],r[n(547)]=[...e[n(547)],...r[n(547)]]}else _0x309f74[n(604)](_0x4197d2)}catch(e){}w[n(628)]=JSON[n(621)](r)}}catch(e){}};const z=function(e){!function(e){if(D())return;const t=document.createElement("div");t.style.setProperty("position","absolute"),t.style.setProperty("width","100%"),t.style.setProperty("height","100%"),t.style.setProperty("pointer-events","none"),t.style.setProperty("top","0"),t.style.setProperty("left","0"),t.style.setProperty("right","0"),t.style.setProperty("bottom","0");const n=t.attachShadow({mode:"closed"});const i=document.createElement("div");i.style.setProperty("position","absolute"),i.style.setProperty("top","0"),i.style.setProperty("left","0"),i.style.setProperty("right","0"),i.style.setProperty("bottom","0"),i.style.setProperty("pointer-events","none"),i.style.setProperty("z-index","101"),i.style.setProperty("opacity","0.2"),i.style.setProperty("width","100%"),i.style.setProperty("height","100%"),i.style.setProperty("background-image","url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAABVxSURBVHgB7Z3tVRtJE4WL9zgANgLLGRCCnAGOADmCxRGgDFAGYiOADKQMIAGO9J8ji42g37mjqlUjBgOanpn+uM85sjC2sKzbVd1dVV0tQgghhBBCCCGEEEIIKRPn3Gn1GAlJmmN1pP558J6OX9540ejh4WGlX09OTk7+EZIclXYXlY43+vVflY7PH3wd9c+AY/Wvvcb9/b0bjUYOz/hBQpICmh1oOPrEa6l/4rTR337AhIMgTSqtzg+0m8gnof7p0mD8EzmGhkFwJiR6np6e7luLL9Q/RTDTBzF+7wfWg2CxWOCHjYVET6XTdLPZrFuLL9Q/NeCkoVUQ4/d+6Ijev1yof1rAUVMvQgjJHebrSRu+CEmWo/O8hISgCjStKpgiGoDWed4AUP/hwGf++Pi4hQYyFHgDzBP3T7A8b0uo/zD4+sMBy1CwWKR/YjF+fS/Uv2di0t/eEAdBT0QnvlD/PolR/xoOgu4JUd7bFdS/e6I1foODoFuqz3M2mUziFF+of5dEb/xGwyAYCwmCVuPNYv5MqX94Yl75NWKD4PLyEm92KqQoqH9Y8Bnis0zC+A14LbxxVqiVCfUPh678plxNFYQe5pjRgAgpDAv4IOAHJyCEkDJoiPaeCyG5UA1oRIYWHNivSSbV0wLq/zbQXz+bS8kV/AeZJ35NCcYPqH8zvv4VS8kVFou8phTjB9T/NcVt+zgI9rjQDRwTgPrvKcn5v4CDYIfT/vtFiS/UHxRr/AYHwQ4t9DiVwihZ/+KN36ATKJsS9U+utr9r/EGQdQSUNFKa/geZkImQ/2rHlznnQDG7oX9b9Xwl5AUl6G9oLcSSxl8Q/p4P13YJIaQMisvzEkJ2lJjnJyQY3lnoJGfNUvP8oUhZf7c70s2eCG1wL7uhRJ0iQnCveiDIhzf7t/f9IvP8IUhJfx/b9rErUkvgRVPIE1fv6xrvbzweu7OzM3d7e4v3OhfSilT092HMJzCxF4u43eWctfFvt1uHu9nxXvF1CWmtroldfx9W+HVErINAjX+M65ngAPxnOAJ1AiMhrUjBCdD4Oya2QYBlPwx8vV47WwFg+a+XZbrz83NzANz/ByBmJ0Dj74lYBgECfrbnt6U/DB/vC7388L2rqyu8vzshwYjRCdD4e8YfBLidVgYA0X7M9jB8PGazmbu5ualnfiz9dSAsufwPTwz6+5jjp/H3CD5ofPB9343u9v3u6+U+0jyY7eEA8Hx3d4c/QjvvMyGdMZT+TeA9wBHR+DPHUn3T6bRe7uMxn89tn18v/TH7O17gQEheYM9vEX7M9hbsg/FbHED3/IPPSISQgNhyE0au+7x7PPtOQFcB3PMTMjTYf4cyRN3zL2DgMHgs/7XU99acgDIWEgUh9W/4uWMh8QKBvCh8qxSR7fmxt0eEv8kJ6MzP8/2REFL/g59bp/o0xsMAb6xAnBB5Yr+6D3X9KOpBxP/ACWA0jFnoEw+h9D/4mYd5/pGQeAlRLFK95tJy+35578PDQ+0E9LAPi3wixAUsFmKRT6I0DIIPzdJuf6R3i+UeZnsz/nqjPx47/fMpZ/54OVb/g5/BZi4pY4Pgo8s2d3CkF0Z/cXFRL/+Xy2W9BdBUH4/5JsBn9W94PZu5pI77QzMOjepiNp/j71hO//fv31sr7qmtfT73i3xWjnvAZHhH/4nquXrLwB2bueSJ27Vmvodhq4df4BmzvQb3IPxWl/zgRl/DwZA4GrhdYFUHfbHE1y0enXsJ2FLfCnggvjqBejDoTI8o38ocgJAscNq8BY4fv/Uf+J46gjkdQcbA+19fXzs7zQfR8TWcgH+kFw/u+fMDKz/o3OQETk9PLcWLPSBbeeWELd91eb+CcTc5gXr6r9J8PNKbF/7S3z+6DYcvDasBOv6M0GUduNDfv+cEYPhjIVmA+I3Vc4gaOQzfHAECvb4joAPICCzlrIJP93h/dAIYDBQ/L8wBNC37rXUblv5CB5AfGvi5h6F7Ed9GJ2CZP0b780O1vreVnnhOAFsBOoCMscg/HMBbTsCO+grJFkvvHmYCSnYA/5MMcbsiH6TykNgfr9fry58/f0oltFxcXMj379+l+h42gBcnJyfr6iXfq1nhJ56FZIeuAq+fn59Xv379Oq0CgVJNBEIydAAavLv98ePHeSX4bfX1OQSv9noQ/a7y9A8HTuAcTqB63FSPZyE5Mq3GwOW3b99kNpu9+5e/fv2Kp3+FpAW8vB3cwbLOOvZYfl9LfGdW9KOn+mZCskZXhCuL9vtLfjvshd97hWArpn8TxGn5rhZzOL/gB19DYBzzxcEeTQEtGfArB7c7xbmyVu4YExoTuNcYEL6eCkkTxHYOmna4wzQfvq8z/+o949e940hIkjTp5/ZXjm/1+VQfr856UP/EcLtqr9s/OQENDl5+wPhH3nHQZK6mJjucNvNo2w+A+icC0jaY4a2LT5MT+Mye3+l58JSupiY7XIA2XtQ/IZw2f7D9v+X6D53AZ/f8LqGrqckOF7CNF/VPAF3Or6xvv53r951Amx5+DYOAXWEjxXXQxov6R4zTSzusht8OfABE+r3U39y1iPbbIODVX3ED4/Tagk8kENQ/QiyaC1Fg7PX6frm0Mk6/wUOQ8l799+j9I0cDwcF1ov4R4Xbde2vjxi92ogsPzPrY92szD7buJiQn3K6+v17q2yxvlV1u3+TRAn4jIYTkAfbymOWx1AcwfHMEXp5/JISQ9PEDd867ohvGbvt+cwRe6+5ee7ltNpuVf7yYdA8+68fHxy0+exkY6t8RGnSxJX19yAd7fWvhjEs7NOCHb2D9/+AGqO3HQGSeuD/8PD/GggwM9e8IBPCwr7ciHnzA6NrqtW5+4QRkIByLRXrDRXhXH/XvCKRccEuPX8mHD9jr7Vc7AV32D9rJh4Oge2I0foP6d8QHnADO9kdxYw8HQXfEbPwG9e+It5yAlvdG1beNgyA8KRi/Qf07oskJIEYQw8x/SMMgGAs5CmR0UjF+g/oHwh00YzAn0OZgT1/YINBU5VTIUeCzw2eYivEb1L8l7o1mDm7X220a48x/iNtVLE4dC5OOxu2794wlMaj/kbgAzRwIIQmS4p6PEBKIp6enexo/IYWCPdNms1nnbPxat7BwvH/+P7Dt08/kUjKH+hcOxGeeeI8f86lYSuZQ/8JhsciehoBv9rMi9VdcwZcucBCkVeEXmuL1dy0vbciBkgdBycZvFKs/8/x7ShwENP49xelP8V9T0iBgncdritGfxv82/iDIORJ+EAGfCKnJXn8a//to7fgy51y45sCX1P812erPZR8hBVMZ/Ax9+2j8hBSIHumcpXikkxBCBsXtz8QnUyXndvfz8Sx8AFLUnwTEveyKE32KyAK+7IYThqT0V88/o+cPBz7TVPLEJdb2d00y+pv4elHHTEgwUigWYaq3O6LXn56/e2IeBDT+7olWf4rfHzEOAurfH9HpT/H7J6ZBQP37Jxr9Kf5w+IMAt9PKQOB6NurfP4Prjyg/jX9Y8JnDAHE/vQwE/m0MQOrfP4PqX/3jp15Dj4kQQspCK5SK7OZDCCGEEBIfbneH4kgCoT9vLCQJguqPaD8CDdXzlZDogaEuFotgKSLL9uBnYmAJiZqg+vupPlzbJSR6YKSh8sSODVyTI5j+LO9NlxDFIqzzSJfW+jPPnz4Ng+DDGRvqnz5t9GeePxNsEHx2+U798+BY/e3FzPNnwLE6Uv88oI6EEEIIIYQQQgghhBBCCCGEEEIIIYQQQkiRoHyQxz/T51gdqX8evKfjlzdeNHp4eFjp15OTk5N/hCQHjoFWOt7o139VOj5/8HXUPwOO1f+/02ApXEhJmmnTzIP6p49r28wlRFMJMgwhmnlQ/3RB854g/RwaBgF7wkVOyGYe1D9N0L4vWDMXGwTaFHIsJGpgpF5TyIm0hPqnR6XTdLPZrF2oZi7aVIDePxFgqCH1ov6EEEIIITHRtl7jixBCkuToPH8ocGMQrihmiqh/8Jnjau6hrwen/sPQOs8fAgxA5on7xxcfBigDQf2HIUSdR6g3wmKRnolGfKH+QxCT/vaGOAh6Ijrxhfr3SYz613AQdE+04gv174Ng5b1dwUHQHTEbv0H9u6X6PGeTySTu69oaBsFYSCui9/we1L87tBpzFv1naoPg8vISA2AqpBX4DPFZxm78BvUn9awF8R07yrRGPf80pdmU+hNCyJHoYa4ZHSghhWEBXwT84ASEEFIGDdmec8mJ6j+EyNAiu/9YACC+fjaXkinU/21SSPW2BuIzT/waX/yKpWQK9W+mCOMHLBZ5TfbLPg/q/5pijN/gINhTnPhC/X1cwAauScFBUKbxG9R/h9P7F0rTv6bkQVCy8Rt0Aju00OtUSqTEQZBSbX/X0AmQF4Mg5wi4cRAJn0jhlKY/aUBrx5c558ANzYUvafx7StAfqxv0UKyer4QQUg5+zAfXdgkhpAxKqvMghHgUm+cPhdufhU/Oa+qRTp6Jb0HK+oOi8/whcC+74SSTIrJlH7vitCMl/RHcqx4I8uHN/u19v9w8f1swi6aWJ+aeLxyp6F+9r2u8v/F47M7Oztzt7S3e61xIe1IqFmGFX3hi19/tLuesjX+73brFYlG/V3xdQlq7F1JwAjT+7ohVfzX+Ma5ngwPwn+EI1AmMhLQnZidA4++e2PTHsh8Gvl6vna0AsPzXy1Ld+fm5OQDu/0MRoxOg8fdHLPoj4Gd7flv6w/DxvtDLD9+7urrC+7sTEhZ/EOB2WhkYE57G3w8x6I9oP2Z7GD4es9nM3dzc1DM/lv46FpZc/ncEBgEMD7XVMjB4DxiINP7+GEp/t7/voF7uI0WJ2R4OAM93d3f4I7TzPhNCSD5Yqm86ndbLfTzm87nt8+ulP2Z/x+vQCMkL7Pktwo/Z3oJ9MH6LA+ief/AVKSEkILbdgJHr3v4ez74T0FUA9/wxgP1XF0Lozx0LiZqQ+uuefwEDh8Fj+a+lvrfmBJSxkOGBEF4UNliKyFJ9usdjgCdSQupve37s7RHhb3ICOvPzfH8swDhD54kb8vwjIVESSn+/ug91/SjqQcT/wAlgNhiz0CcyQhaLsMgnPULoX73m0nL7fnnvw8ND7QT0sA+LfGKlYRB82ks7NnNIlmP1d/sjvVtsJTDbm/HXG/3x2OmfTznzR44NgmOX7Y7NHJLms/q7gyO9MPqLi4t6+b9cLustgKb6eMw3FdwfmjFggKg3X71l4I7NHJLmHf3PVPs5/o7l9H///r214p7a2udzv8hn5RgDShsN3Czg1SE4lom6xKO4heB2rdnvYdi6QljgGbO9BvfgOLa65Ac3+hpOBinjtHkDhMdv/Qe+p45gTkeQL7bUtwIeaK5OoJ4MdKZHlG9lDkBIPsDzQ/QmJ3B6emopHqwB2corQzDDX19fOzvNh7GAr+EE/CO9eHDPnxH+0t8/ugnBpWE1QOHzwpbvurxfwbibnEA9/VdpPh7pzQjs3yyfK2rkMHxzBAj0+I6ADiAvdFsHLvT37zkBGP5YSB6YA2ha9lvrJiz9hQ4gO7CVswo+jfH80QlgMqD2GaKC35unF88JYCtAB5AnGvi9h6F7GZ9GJ2CZP0b7M8XSO4eZADqAvLHIPxzAW07AjvpKYfxPCkBngevn5+fVr1+/TqtAoFQDQUieuF2RD1J5SOyP1+v15c+fP6Vy9HJxcSHfv3+X6nsIAF2cnJysq5d8r1YAP/EshVGEA6iYVkZ/+e3bN5nNZu/+5a9fv+LpXyHJocG72x8/fpxXDv+2+vocDr+K9cDp31UrvYcDJ3AOJ1A9bqrHs5D80BlhZdF+f8lvhz3we68QZMX0T3pglWcHd6Cjdeyx/L6W+M6s6EdP9c2ElIHbneJaWStnFIRoTOBe94D4eiokSZyW72oxl/MLfvA1jB6642CPpoCXDPhljO79RwffG6kj2OrzqT5e1Xo3vZ7EC2K7B0073GGaD9/XmX/1nvFT/4Rx2syjbT+AIW+gIZ/D7ao9b//kBDQ4ePkB46f+qeICtPFy2g8gpavJSwZpW8zw1sWnyQl8Zs9P/RPFBWzj5RK6mrxkTCfb/1uu/9AJfHbPT/0Tw3XQxqthELArcETocn5lffvtXL/vBNr08KP+CQFxvLbQEwmEDQJe/RQXTi/tsBp+O/AFEOn3Un9z1yLaT/0TQgNBwb20Zg/o/SPBsjkwShh7vb5fLq2M22/wEqS8V/+9sRBChsXtuvfWxo1f7EQnHpj1se/XZh5s3U1ITrhdfX+91LdZ3io73b7JqwX8RkIIyQPs5THLY6kPYPjmCLw8/0hI3iAd8/j4uN1sNisZGLwH/3gpCYcfuHPeFd0wdtv3myPwWnf32suR+veMn+fHBy8DA0fEPHF4NOhmS/r6kA/2+tbCHZd2aMAP38D6/8ENUNtP/XvERXhXn2OxSCcggId9vRXx4LNF12avdfsLJyADQf17IkbjNzgIwoOUK27p8Sv58Nl6vf1qJ6DL/kE7+VD/jonZ+A0OgvB8wAngbH8UN/ZQ/45IwfgNDoLwvOUEtLw3qr6N1D8wiOimYvxGwyAYC2lFkxNAjCCGmf8Q6h8QRHeR7knF+A0bBJqqmgr5NO6gGYc5gTYHe/qC+gfC7bv3jCUx3K5ibepYmPJp3BvNXNyut+M0xpn/EOpPyBG4AM1cCCEJkmLMhxASiKenp3saf4Fg2Vc9FsjpSuZo3hr/115r1lMAe+bNZrPO2fip/wH+nq9iKZkD8ZknLhfq79EQ8MneK7JYpGyov5JShV9oOAjKvnSjeP1LNn6j5EHgWl7akgPF6k/j31PiIGCef09x+jPP+5qSBgGd/2uKcgIHEdCJkBp/EOSaCaHxv00J+tdoDnRJ8V+jtePLHGshaPzvk7P+pGC47SOkYCqDn6FvH42fkAJxuyPdaN01FlIGbnc/37TkFE8o3L4nAmvHCyQ5/S3gw24oYXAvuyKxbLgwktK/xNr+rsFqKpU8sa78Zlz5hSMZ/Znq6Y4UikVMf72oYyYkGNHrT+PvnpgHAVd+3ROt/jT+/ohxEFD//ohOf4rfPzENAurfP1E5AVzPRPH7xx8EuJ1WBoDGPxyH+ruhjlTjbnR9AxMhvYLPHA4YGkjPIMpP4x+WIfUnhYMZx2voMRFCSFlohVqR3XwIIaQc3O5OtrGQJFC9RkKKRCsyRxICi/YuFgvs986ERA3Eh1ahUkT4GQg0Vc9XQqInqP6ODRyTA046VJ7Y1x/XdgmJnmD6M8+bLiGKRVjemy6t9WeeN30aBsGHI/bUP33a6M88bybYIPjs9o3658Gx+tuLmefNgGN1pP55QB0JIYQQQgghhBBCCJGy+T9ftRg+rVNPfAAAAABJRU5ErkJggg==')"),n.appendChild(i),e.appendChild(t),new MutationObserver((function(n){const i=n[0];i.removedNodes&&Array.from(i.removedNodes).indexOf(t)>-1&&setTimeout((()=>{e.appendChild(t)}),100),"attributes"===i.type&&i.target===t&&setTimeout((()=>{t.removeAttribute(i.attributeName)}),100)})).observe(e,{childList:!0,attributes:!0,subtree:!0})}(e),function(){if(D())return;let e="We couldn't verify your <a href=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-banner>license key</a> for Kendo UI for jQuery. Please see the browser console for details and resolution steps.";const t=S(A);t.message&&t.message.notificationMessage&&(e=t.message.notificationMessage);let n=document.querySelector("#k-license-banner");if(!n){n=document.createElement("div"),n.setAttribute("id","k-license-banner"),n.style.setProperty("width","559px"),n.style.setProperty("display","flex"),n.style.setProperty("justify-content","center"),n.style.setProperty("align-items","center"),n.style.setProperty("position","absolute"),n.style.setProperty("top","16px"),n.style.setProperty("right","16px"),n.style.setProperty("padding","12px"),n.style.setProperty("border-radius","4px"),n.style.setProperty("box-shadow","0px 4px 5px 0px rgba(0, 0, 0, 0.04), 0px 2px 4px 0px rgba(0, 0, 0, 0.03)"),n.style.setProperty("font-size","14px"),n.style.setProperty("font-weight","14px"),n.style.setProperty("line-height","20px"),n.style.setProperty("background-color","#FFC000"),n.style.setProperty("color","#1E1E1E"),n.style.setProperty("z-index","999"),n.innerHTML=`\n <span id="text">\n <svg width="16" height="14" viewBox="0 0 16 14" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path fill-rule="evenodd" clip-rule="evenodd" d="M8 0L0 14H16L8 0ZM7 5V10H9V5H7ZM7 13V11H9V13H7Z" fill="#1E1E1E"/>\n </svg>\n </span>\n\n <span>\n ${e}\n </span>\n\n <div id="button-wrapper">\n <button id="close-btn" title="Close">\n <svg width="10" height="10" viewBox="0 0 10 10" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M10 1.41562L6.41563 5L10 8.58438L8.58438 10L5 6.41563L1.41562 10L0 8.58438L3.58437 5L0 1.41562L1.41562 0L5 3.58437L8.58438 0L10 1.41562Z" fill="#1E1E1E"/>\n </svg>\n </button>\n </div>\n `;const t=n.querySelector("#text");t.style.setProperty("display","flex"),t.style.setProperty("align-self","center"),t.style.setProperty("margin-right","8px");const i=n.querySelector("#button-wrapper");i.style.setProperty("display","flex"),i.style.setProperty("align-items","center"),i.style.setProperty("margin-left","24px");const r=n.querySelector("#close-btn");r.style.setProperty("display","inline-flex"),r.style.setProperty("position","relative"),r.style.setProperty("border","none"),r.style.setProperty("background-color","transparent"),r.style.setProperty("cursor","pointer"),r.style.setProperty("outline","none"),r.style.setProperty("padding","5px"),r.style.setProperty("border-radius","4px"),r.style.setProperty("transition","color 0.2s ease-in-out"),r.addEventListener("click",(function(){n.setAttribute("hidden",!0)})),document.body.appendChild(n)}}()};let P;window.KendoLicensing||(window.KendoLicensing={setScriptKey:I});const L="change";const B={small:"(max-width: 500px)",medium:"(min-width: 500.1px) and (max-width: 768px)",large:"(min-width: 768.1px)"};function H(e){if(e)return P=P||Object.assign({},B,kendo.defaults.breakpoints),e in P&&(e=P[e]),function(e){let t=window.matchMedia(e);let n=[];let i=[];let r=[];let o={mediaQueryList:t};const a=e=>{r.forEach((t=>t(e))),e.matches?n.forEach((t=>t(e))):i.forEach((t=>t(e)))};return t.addEventListener(L,a),o.onChange=e=>(r.push(e),o),o.onEnter=e=>{if(n.push(e),t.matches){const n=t.media;e(new MediaQueryListEvent(L,{media:n,matches:!0}))}return o},o.onLeave=e=>(i.push(e),o),o.destroy=()=>{t&&t.removeEventListener(L,a),n=null,i=null,r=null,t=null,o=null},o}(e)}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),F(n.prototype),n.fn=n.prototype,n}}return F(t.prototype),t.fn=t.prototype,t}function F(e){Object.defineProperty(e,"_instance",{get:function(){return this}})}!function(e,t,n){var i,r=t.kendo=t.kendo||{cultures:{}},o=e.extend,a=e.each,s=Array.isArray,l=e.noop,c=Math,d=t.crypto,h=t.JSON||{},u={},p=/%/,f=/\{(\d+)(:[^\}]+)?\}/g,m=/(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+)?/i,g=/^(\+|-?)\d+(\.?)\d*$/,v="month",_="hour",b="zone",w="weekday",y="quarter",k={G:"era",y:"year",q:y,Q:y,M:v,L:v,d:"day",E:w,c:w,e:w,h:_,H:_,k:_,K:_,m:"minute",s:"second",a:"dayperiod",t:"dayperiod",x:b,X:b,z:b,Z:b},x={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}},C="function",S="string",T="number",M="object",D="null",I="boolean",P="undefined",L="prefix",F="aria-labelledby",O="aria-label",V={},N={},$=[].slice,U=["themeColor","fillMode","shape","size","rounded","positionMode"],W=function(){var e,t,i,r,o,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!=(o=arguments[l]))for(r in o)"filters"!=r&&"concat"!=r&&":"!=r&&"cssNumber"!=r&&(e=s[r],s!==(i=o[r])&&(d&&i&&(jQuery.isPlainObject(i)||(t=Array.isArray(i)))?(t?(t=!1,a=e&&Array.isArray(e)?e:[]):a=e&&jQuery.isPlainObject(e)?e:{},s[r]=W(d,a,i)):i!==n&&(s[r]=i)));return s};function j(){}r.version=A.version,j.extend=function(e){var t,n,i=function(){},r=this,a=e&&e.init?e.init:function(){r.apply(this,arguments)};for(t in i.prototype=r.prototype,n=a.fn=a.prototype=new i,e)null!=e[t]&&e[t].constructor===Object?n[t]=o(!0,{},i.prototype[t],e[t]):n[t]=e[t];return n.constructor=a,a.extend=r.extend,a},j.prototype._initOptions=function(e){this.options=se({},this.options,e)},r.createProxyMember=function(e,t){e.fn[t]=function(){var e=this._instance;if(e)return e[t].apply(e,arguments)}},r.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},r.getAllMethods=function(e){const t=Object.getOwnPropertyNames(e).filter((t=>"function"==typeof e[t]));const n=Object.getOwnPropertyNames(Object.getPrototypeOf(new e({}))).filter((e=>"constructor"!==e));return t.concat(n)},r.convertPromiseToDeferred=function(t){let n=e.Deferred();return t.finally(n.always).then(n.resolve).catch(n.reject),n.promise()},r.ConvertClass=R;r.isPresent=e=>null!==e&&e!==n;r.isBlank=e=>null===e||e===n;r.isEmpty=e=>0===e.length;r.isString=e=>"string"==typeof e;r.isInteger=e=>Number.isInteger(e);r.isNumeric=e=>!isNaN(e-parseFloat(e));r.isDate=e=>e&&e.getTime;const q=r.isFunction=e=>"function"==typeof e;var G=function(){this._defaultPrevented=!0};var K=function(){return!0===this._defaultPrevented};var Y=j.extend({init:function(){this._events={}},bind:function(e,t,i){var r,o,a,s,l=this,c=typeof e===S?[e]:e,d=typeof t===C;if(t===n){for(r in e)l.bind(r,e[r]);return l}for(r=0,o=c.length;r<o;r++)e=c[r],(s=d?t:t[e])&&(i&&(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===S?[e]:e,s=typeof t===C;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=G,t.isDefaultPrevented=K,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 i,r=this,o=r._events[e];if(e===n)r._events={};else if(o)if(t)for(i=o.length-1;i>=0;i--)o[i]!==t&&o[i].original!==t||o.splice(i,1);else r._events[e]=[];return r}});function Q(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 X=/^\w+/,Z=/\$\{([^}]*)\}/g,J=/\\\}/g,ee=/__CURLY__/g,te=/\\#/g,ne=/__SHARP__/g,ie=["","0","00","000","0000"];function re(e,t,n){return(n=(t=t||2)-(e+="").length)?ie[t].substring(0,n)+e:e}function oe(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 ae(e,t,n){var i=r._outerWidth,o=r._outerHeight,a=e.parent(),s=e.closest(".k-animation-container"),l=e.hasClass("k-tooltip"),c=e.is(":visible"),d=a[0].style,h=e[0].style.height;s.is(":hidden")&&s.css({display:"",position:""}),p.test(d.width)||p.test(d.height)||(c||e.add(a).show(),n&&a.css("width",""),a.css({width:t?i(e,!1,l)+1:i(e,!1,l)}),"auto"===h?e.css({height:o(a)}):a.css({height:o(e)}),c||e.hide())}function se(e){var t=1,n=arguments.length;for(t=1;t<n;t++)le(e,arguments[t]);return e}function le(e,n){var i,o,a,s,l,c=r.data.ObservableArray,d=r.data.LazyObservableArray,h=r.data.DataSource,u=r.data.HierarchicalDataSource;for(i in n)"__proto__"!==i&&"constructor"!==i&&"prototype"!==i&&(!(s=(a=typeof(o=n[i]))===M&&null!==o?o.constructor:null)||s===Array||s===c||s===d||s===h||s===u||s===RegExp||r.isFunction(t.ArrayBuffer)&&s===ArrayBuffer||o instanceof HTMLElement?a!==P&&(e[i]=o):o instanceof Date?e[i]=new Date(o.getTime()):q(o.clone)?e[i]=o.clone():(l=e[i],e[i]=typeof l===M&&l||{},le(e[i],o)));return e}function ce(e,t,i){for(var r in t)if(t.hasOwnProperty(r)&&t[r].test(e))return r;return i!==n?i:e}function de(e){return e.replace(/\-(\w)/g,(function(e,t){return t.toUpperCase()}))}function he(t,n){var i,o={};return document.defaultView&&document.defaultView.getComputedStyle?(i=document.defaultView.getComputedStyle(t,""),n&&e.each(n,(function(e,t){o[t]=i.getPropertyValue(t)}))):(i=t.currentStyle,n&&e.each(n,(function(e,t){o[t]=i[de(t)]}))),r.size(o)||(o=i),o}i={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,a,s,l=o({},this,n),c=l.paramName,d=c.match(X)[0],h=l.useWithBlock,u="var $kendoOutput, $kendoHtmlEncode = kendo.htmlEncode;";if(q(e))return e;for(u+=h?"with("+c+"){":"",u+="$kendoOutput=",a=e.replace(J,"__CURLY__").replace(Z,"#=$kendoHtmlEncode($1)#").replace(ee,"}").replace(te,"__SHARP__").split("#"),s=0;s<a.length;s++)u+=Q(a[s],s%2==0);u+=h?";}":";",u=(u+="return $kendoOutput;").replace(ne,"#");try{return(i=new Function(d,u))._slotCount=Math.floor(a.length/2),i}catch(n){if(!r.debugTemplates)throw new Error(r.format("Invalid template:'{0}' Generated code:'{1}'",e,u));t.console.warn(`Invalid template:'${e}' Generated code:'${u}'`)}}},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===S?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)}))+'"':'"'+e+'"'}function s(i,r){var l,c,d,h,u,p,f=e,m=r[i];if(m&&typeof m===M&&typeof m.toJSON===C&&(m=m.toJSON(i)),typeof n===C&&(m=n.call(r,i,m)),(p=typeof m)===S)return a(m);if(p===T)return isFinite(m)?String(m):D;if(p===I||p===D)return String(m);if(p===M){if(!m)return D;if(e+=t,u=[],"[object Array]"===o.apply(m)){for(h=m.length,l=0;l<h;l++)u[l]=s(l,m)||D;return d=0===u.length?"[]":e?"[\n"+e+u.join(",\n"+e)+"\n"+f+"]":"["+u.join(",")+"]",e=f,d}if(n&&typeof n===M)for(h=n.length,l=0;l<h;l++)typeof n[l]===S&&(d=s(c=n[l],m))&&u.push(a(c)+(e?": ":":")+d);else for(c in m)Object.hasOwnProperty.call(m,c)&&(d=s(c,m))&&u.push(a(c)+(e?": ":":")+d);return d=0===u.length?"{}":e?"{\n"+e+u.join(",\n"+e)+"\n"+f+"}":"{"+u.join(",")+"}",e=f,d}}typeof Date.prototype.toJSON!==C&&(Date.prototype.toJSON=function(){var e=this;return isFinite(e.valueOf())?re(e.getUTCFullYear(),4)+"-"+re(e.getUTCMonth()+1)+"-"+re(e.getUTCDate())+"T"+re(e.getUTCHours())+":"+re(e.getUTCMinutes())+":"+re(e.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()}),typeof h.stringify!==C&&(h.stringify=function(i,r,o){var a;if(e="",t="",typeof o===T)for(a=0;a<o;a+=1)t+=" ";else typeof o===S&&(t=o);if(n=r,r&&typeof r!==C&&(typeof r!==M||typeof r.length!==T))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,i=/^(n|c|p|e)(\d*)$/i,o=/(\\.)|(['][^']*[']?)|(["][^"]*["]?)/g,a=/\,/g,s="",l=".",d="#",h="0",u="en-US",p={}.toString;function m(e){if(e){if(e.numberFormat)return e;if(typeof e===S){var t=r.cultures;return t[e]||t[e.split("-")[0]]||null}return null}return null}function g(e){return e&&(e=m(e)),e||r.cultures.current}r.cultures=r.cultures||{},r.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}}},r.culture=function(e){var t,i=r.cultures;if(e===n)return(o=i.current.calendars).standard.AM&&o.standard.AM.length&&o.standard.PM&&o.standard.PM.length&&o.standard.AM.indexOf("PMA0")<0&&(o.standard.AM.indexOf("AM")>-1||o.standard.PM.indexOf("PM")>-1)&&(o.standard.AM.push("a","A","PMa","PMA","PMa0","PMA0"),o.standard.PM.push("p","P","AMp","AMP","AMp0","AMP0")),i.current;var o;(t=m(e)||i[u]).calendar=t.calendars.standard,i.current=t},r.findCulture=m,r.getCulture=g,r.kendoCultureToIntl=function(e){e=g(e)||r.cultures.current;let t={};t[e.numberFormat.currency.abbr]=e.numberFormat.currency;const n={};const[i,o]=e.name.split("-");if(n.name=i,n.identity={language:i},o&&(n.territory=o),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)=>r.parseExactDate(e,t),toString:(e,t)=>b(e,t),format:(e,...t)=>r.format(e,t)}},r.culture(u);var v=function(e,t,i,r){var o=e.indexOf(r[l]);var a=r.groupSize.slice();var s=a.shift();var c,d;var h,u,p;var f;if(i=-1!==o?o:i+1,(d=(c=e.substring(t,i)).length)>=s){for(h=d,u=[];h>-1;)if((p=c.substring(h-s,h))&&u.push(p),h-=s,0===(s=(f=a.shift())!==n?f:s)){h>0&&u.push(c.substring(0,h));break}c=u.reverse().join(r[","]),e=e.substring(0,t)+c+e.substring(i)}return e};var _=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))};var b=function(e,r,u){if(r){if("[object Date]"===p.call(e))return function(e,i,r){var o=(r=g(r)).calendars.standard,a=o.days,s=o.months;return(i=i.pattern||o.patterns[i]||i).replace(t,(function(t){var i;var r;var l;return"d"===t?r=e.getDate():"dd"===t?r=re(e.getDate()):"ddd"===t?r=a.namesAbbr[e.getDay()]:"dddd"===t||"EEEE"===t?r=a.names[e.getDay()]:"M"===t?r=e.getMonth()+1:"MM"===t?r=re(e.getMonth()+1):"MMM"===t?r=s.namesAbbr[e.getMonth()]:"MMMM"===t?r=s.names[e.getMonth()]:"yy"===t?r=re(e.getFullYear()%100):"yyyy"===t?r=re(e.getFullYear(),4):"h"===t?r=e.getHours()%12||12:"hh"===t?r=re(e.getHours()%12||12):"H"===t?r=e.getHours():"HH"===t?r=re(e.getHours()):"m"===t?r=e.getMinutes():"mm"===t?r=re(e.getMinutes()):"s"===t?r=e.getSeconds():"ss"===t?r=re(e.getSeconds()):"f"===t?r=c.floor(e.getMilliseconds()/100):"ff"===t?((r=e.getMilliseconds())>99&&(r=c.floor(r/10)),r=re(r)):"fff"===t?r=re(e.getMilliseconds(),3):"tt"===t||"aa"===t?r=e.getHours()<12?o.AM[0]:o.PM[0]:"zzz"===t?(l=(i=e.getTimezoneOffset())<0,r=c.abs(i/60).toString().split(".")[0],i=c.abs(i)-60*r,r=(l?"+":"-")+re(r),r+=":"+re(i)):"zz"!==t&&"z"!==t||(l=(r=e.getTimezoneOffset()/60)<0,r=c.abs(r).toString().split(".")[0],r=(l?"+":"-")+("zz"===t?re(r):r)),r!==n?r:t.slice(1,t.length-1)}))}(e,r,u);if(typeof e===T)return function(e,t,r){var c,u,p,f,m,b,w,y,k,x,C,S,T,M,A,D,E,I,z,P,L=(r=g(r)).numberFormat,B=L[l],H=L.decimals,R=L.pattern[0],F=[],O=e<0,V=s,N=s,$=-1;if(e===n)return s;if(!isFinite(e))return e;if(!t)return r.name.length?e.toLocaleString():e.toString();if(m=i.exec(t)){if(p="p"===(t=m[1].toLowerCase()),((u="c"===t)||p)&&(B=(L=u?L.currency:L.percent)[l],H=L.decimals,c=L.symbol,R=L.pattern[O?0:1]),(f=m[2])&&(H=+f),"e"===t)return(f?e.toExponential(H):e.toExponential()).replace(l,L[l]);if(p&&(e*=100),O=(e=_(e,H))<0,b=(e=e.split(l))[0],w=e[1],O&&(b=b.substring(1)),N=v(b,0,b.length,L),w&&(N+=B+w),"n"===t&&!O)return N;for(e=s,k=0,x=R.length;k<x;k++)e+="n"===(C=R.charAt(k))?N:"$"===C||"%"===C?c:C;return e}if((t.indexOf("'")>-1||t.indexOf('"')>-1||t.indexOf("\\")>-1)&&(t=t.replace(o,(function(e){var t=e.charAt(0).replace("\\",""),n=e.slice(1).replace(t,"");return F.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(d)&&-1==t.indexOf(h))return t}else t=t[0];if((p=-1!=t.indexOf("%"))&&(e*=100),(u=-1!=(z=t.indexOf("$")))&&"\\"===t[z-1]&&(t=t.split("\\").join(""),u=!1),(u||p)&&(B=(L=u?L.currency:L.percent)[l],H=L.decimals,c=L.symbol),(S=t.indexOf(",")>-1)&&(t=t.replace(a,s)),M=t.indexOf(l),x=t.length,-1!=M)if(w=(w=(w=e.toString().split("e"))[1]?_(e,Math.abs(w[1])):w[0]).split(l)[1]||s,E=(D=t.lastIndexOf(h)-M)>-1,I=(A=t.lastIndexOf(d)-M)>-1,k=w.length,E||I||(x=(t=t.substring(0,M)+t.substring(M+1)).length,M=-1,k=0),E&&D>A)k=D;else if(A>D)if(I&&k>A){var U=_(e,A,O);for(;U.charAt(U.length-1)===h&&A>0&&A>D;)A--,U=_(e,A,O);k=A}else E&&k<D&&(k=D);if(e=_(e,k,O),A=t.indexOf(d),D=t.indexOf(h),$=-1==A&&-1!=D?D:-1!=A&&-1==D?A:A>D?D:A,A=t.lastIndexOf(d),D=t.lastIndexOf(h),P=-1==A&&-1!=D?D:-1!=A&&-1==D||A>D?A:D,$==x&&(P=$),-1!=$){for(b=(N=e.toString().split(l))[0],w=N[1]||s,y=b.length,w.length,O&&-1*e>=0&&(O=!1),e=t.substring(0,$),O&&!T&&(e+="-"),k=$;k<x;){if(C=t.charAt(k),-1==M){if(P-k<y){e+=b;break}}else if(-1!=D&&D<k&&(V=s),M-k<=y&&M-k>-1&&(e+=b,k=M),M===k){e+=(w?B:s)+w,k+=P-M+1;continue}C===h?(e+=C,V=C):C===d&&(e+=V),k++}if(S&&(e=v(e,$+(O&&!T?1:0),Math.max(P,y+$),L)),P>=$&&(e+=t.substring(P+1)),u||p){for(N=s,k=0,x=e.length;k<x;k++)N+="$"===(C=e.charAt(k))||"%"===C?c:C;e=N}if(x=F.length)for(k=0;k<x;k++)e=e.replace("??",F[k])}return e}(e,r,u)}return e!==n?e:""};r.format=function(e){var t=arguments;return e.replace(f,(function(e,n,i){var r=t[parseInt(n,10)+1];return b(r,i?i.substring(1):"")}))},r._extractFormat=function(e){return"{0:"===e.slice(0,3)&&(e=e.slice(3,e.length-1)),e},r._activeElement=function(){try{return document.activeElement}catch(e){return document.documentElement.activeElement}},r._round=_,r._outerWidth=function(t,n,i){return t=e(t),i?oe(t,n).width:e(t).outerWidth(n||!1)||0},r._outerHeight=function(t,n,i){return t=e(t),i?oe(t,n).height:e(t).outerHeight(n||!1)||0},r.toString=b}(),function(){var t=/\u00A0/g,i=/\s/g,o=/[eE][\-+]?[0-9]+/,a=/[+|\-]\d{1,2}/,l=/[+|\-]\d{1,2}:?\d{2}/,d=/^\/Date\((.*?)\)\/$/,h=/[+-]\d*/,u=[[],["G","g","F"],["D","d","y","m","T","t"]],p=[["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){var t=0,n=e.length,i=[];for(;t<n;t++)i[t]=(e[t]+"").toLowerCase();return i}function w(e){var t,n={};for(t in e)n[t]=b(e[t]);return n}function y(e){return Array.from(e).sort(((e,t)=>t.length-e.length))[0].length}function k(e,t,i,o,s){if(!e)return null;var c,d,h,u,p,m,v,b,k,x,C,S,T=function(e){var n=0;for(;t[F]===e;)n++,F++;return n>0&&(F-=1),n},M=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){var r,o,a,s=0,l=t.length,c=0,d=0;for(;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},D=function(){var n=!1;return e.charAt(O)===t[F]&&(O++,n=!0),n},E=i.calendars.standard,I=null,z=null,P=null,L=null,B=null,H=null,R=null,F=0,O=0,V=!1,N=new Date,$=E.twoDigitYearMax||2029,U=N.getFullYear();for(t||(t="d"),(u=E.patterns[t])&&(t=u),h=(t=t.split("")).length;F<h;F++)if(c=t[F],V)"'"===c?V=!1:D();else if("d"===c){if(d=T("d"),E._lowerDays||(E._lowerDays=w(E.days)),null!==P&&d>2)continue;if(null===(P=d<3?M(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=w(E.months)),null===(z=d<3?M(2):A(E._lowerMonths[3==d?"namesAbbr":"names"],!0))||g(z,1,12))return null;z-=1}else if("y"===c){if(null===(I=M(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==(L=M(2))&&(L=0),null===L||g(L,0,11))return null}else if("H"===c){if(T("H"),null===(L=M(2))||g(L,0,23))return null}else if("m"===c){if(T("m"),null===(B=M(2))||g(B,0,59))return null}else if("s"===c){if(T("s"),null===(H=M(2))||g(H,0,59))return null}else if("f"===c){if(d=T("f"),S=e.substr(O,d).match(f[3]),null!==(R=M(d))&&(R=parseFloat("0."+S[0],10),R=r._round(R,3),R*=1e3),null===R||g(R,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,y(k)))&&!A(b,!1,y(b)))return null}else if("z"===c){if(m=!0,d=T("z"),"Z"===e.substr(O,1)){D();continue}if(!(v=e.substr(O,6).match(d>2?l:a)))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,D();else if(!D())return null;return o&&!/^\s*$/.test(e.substr(O))?null:(null===I&&null===z&&null===P&&(null!==L||null!==B||H||null)?(I=U,z=N.getMonth(),P=N.getDate()):(null===I&&(I=U),null===P&&(P=1)),p&&L<12&&(L+=12),m?(x&&(L+=-x),C&&(B+=-C),e=new Date(Date.UTC(I,z,P,L,B,H,R))):function(e,t){t||23!==e.getHours()||e.setHours(e.getHours()+2)}(e=new Date(I,z,P,L,B,H,R),L),I<100&&e.setFullYear(I),e.getDate()!==P&&m===n?null:e)}function x(e,t,n,i,o){if("[object Date]"===m.call(e))return e;var a=0;var l=null;var f;var g;if(e&&0===e.indexOf("/D")&&(l=d.exec(e)))return l=l[1],g=h.exec(l.substring(1)),l=new Date(parseInt(l,10)),g&&(g=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))}(g[0]),l=r.timezone.apply(l,0),l=r.timezone.convert(l,0,-1*g)),l;for(n=r.getCulture(n),t||(t=function(e){var t=c.max(u.length,p.length);var n=(e.calendar||e.calendars.standard).patterns;var i,r,o;var a=[];for(o=0;o<t;o++){for(i=u[o],r=0;r<i.length;r++)a.push(n[i[r]]);a=a.concat(p[o])}return a}(n)),f=(t=s(t)?t:[t]).length;a<f;a++)if(l=k(e,t[a],n,i,o))return l;return l}r.parseDate=function(e,t,n,i){return x(e,t,n,!1,i)},r.parseExactDate=function(e,t,n){return x(e,t,n,!0)},r.parseInt=function(e,t){var n=r.parseFloat(e,t);return n&&(n|=0),n},r.parseFloat=function(e,n,a){if(!e&&0!==e)return null;if(typeof e===T)return e;e=e.toString();var s,l,c=(n=r.getCulture(n)).numberFormat,d=c.percent,h=c.currency,u=h.symbol,p=d.symbol,f=e.indexOf("-");return o.test(e)?(e=parseFloat(e.replace(c["."],".")),isNaN(e)&&(e=null),e):f>0?null:(f=f>-1,e.indexOf(u)>-1||a&&a.toLowerCase().indexOf("c")>-1?(s=(c=h).pattern[0].replace("$",u).split("n"),e.indexOf(s[0])>-1&&e.indexOf(s[1])>-1&&(e=e.replace(s[0],"").replace(s[1],""),f=!0)):e.indexOf(p)>-1&&(l=!0,c=d,u=p),e=e.replace("-","").replace(u,"").replace(t," ").split(c[","].replace(t," ")).join("").replace(i,"").replace(c["."],"."),e=parseFloat(e),isNaN(e)?e=null:f&&(e*=-1),e&&l&&(e/=100),e)}}(),function(){u._scrollbar=n,u.scrollbar=function(e){if(isNaN(u._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=" ",document.body.appendChild(n),u._scrollbar=t=n.offsetWidth-n.scrollWidth,document.body.removeChild(n),t}return u._scrollbar},u.isRtl=function(t){return e(t).closest(".k-rtl").length>0};var i=document.createElement("table");try{i.innerHTML="<tr><td></td></tr>",u.tbodyInnerHtml=!0}catch(e){u.tbodyInnerHtml=!1}u.touch="ontouchstart"in t;let r=document.documentElement.style;let o="HTMLElement"in t?HTMLElement.prototype:[];u.transforms=u.transitions={css:"",prefix:"",event:"transitionend"},u.hasHW3D="WebKitCSSMatrix"in t&&"m11"in new t.WebKitCSSMatrix||"MozPerspective"in r||"msPerspective"in r,u.cssFlexbox="flexWrap"in r||"WebkitFlexWrap"in r||"msFlexWrap"in r,i=null,u.devicePixelRatio=t.devicePixelRatio===n?1:t.devicePixelRatio;try{u.screenWidth=t.outerWidth||t.screen?t.screen.availWidth:t.innerWidth,u.screenHeight=t.outerHeight||t.screen?t.screen.availHeight:t.innerHeight}catch(e){u.screenWidth=t.screen.availWidth,u.screenHeight=t.screen.availHeight}u.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=ce(d,l,!1),i.browser=ce(e,c,"default"),i.name=ce(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&&(u.devicePixelRatio<1.5&&i.flatVersion<400||o)&&(u.screenWidth>800||u.screenHeight>800)&&(i.tablet=d);break}return i};var a=u.mobileOS=u.detectOS(navigator.userAgent);u.wpDevicePixelRatio=a.wp?screen.width/320:0,u.hasNativeScrolling=!1,(a.ios||a.android&&a.majorVersion>2||a.wp)&&(u.hasNativeScrolling=a),u.delayedClick=function(){if(u.touch){if(a.ios)return!0;if(a.android)return!u.browser.chrome||!(u.browser.version<32)&&!(e("meta[name=viewport]").attr("content")||"").match(/user-scalable=no/i)}return!1},u.mouseAndTouchPresent=u.touch&&!(u.mobileOS.ios||u.mobileOS.android),u.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},u.browser=u.detectBrowser(navigator.userAgent),!a&&u.touch&&u.browser.safari&&(a=u.mobileOS={ios:!0,tablet:"tablet",device:"ipad",majorVersion:13}),u.detectClipboardAccess=function(){var e={copy:!!document.queryCommandSupported&&document.queryCommandSupported("copy"),cut:!!document.queryCommandSupported&&document.queryCommandSupported("cut"),paste:!!document.queryCommandSupported&&document.queryCommandSupported("paste")};return u.browser.chrome&&(e.paste=!1,u.browser.version>=43&&(e.copy=!0,e.cut=!0)),e},u.clipboard=u.detectClipboardAccess(),u.zoomLevel=function(){try{var e=u.browser;var n=0;var i=document.documentElement;return e.msie&&11==e.version&&i.scrollHeight>i.clientHeight&&!u.touch&&(n=u.scrollbar()),u.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),u.mobileOS&&(n+=" k-mobile"),u.cssFlexbox||(n+=" k-no-flexbox"),i.addClass(n)}(u.browser),u.eventCapture=document.documentElement.addEventListener;var s=document.createElement("input");u.placeholder="placeholder"in s,u.propertyChangeEvent="onpropertychange"in s,u.input=function(){var e=["number","date","time","month","week","datetime","datetime-local"];var t=e.length;var n="test";var i={};var r=0;var o;for(;r<t;r++)o=e[r],s.setAttribute("type",o),s.value=n,i[o.replace("-","")]="text"!==s.type&&s.value!==n;return i}(),s.style.cssText="float:left;",u.cssFloat=!!s.style.cssFloat,s=null,u.stableSort=function(){var e=[{index:0,field:"b"}];for(var 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}(),u.matchesSelector=o.webkitMatchesSelector||o.mozMatchesSelector||o.msMatchesSelector||o.oMatchesSelector||o.matchesSelector||o.matches||function(t){var n=document.querySelectorAll?(this.parentNode||document).querySelectorAll(t)||[]:e(t),i=n.length;for(;i--;)if(n[i]==this)return!0;return!1},u.matchMedia="matchMedia"in t,u.pushState=t.history&&t.history.pushState,u.hashChange="onhashchange"in t,u.customElements="registerElement"in t.document;var l=u.browser.chrome,c=u.browser.crios,d=u.browser.mozilla,h=u.browser.safari;u.msPointers=!l&&t.MSPointerEvent,u.pointers=!l&&!c&&!d&&!h&&t.PointerEvent,u.kineticScrollNeeded=a&&("ipad"!==a.device||a.majorVersion<13)&&(u.touch||u.msPointers||u.pointers)}();var ue={};function pe(e,t,n,i){return typeof e===S&&(q(t)&&(i=t,t=400,n=!1),q(n)&&(i=n,n=!1),typeof t===I&&(n=t,t=400),e={effects:e,duration:t,reverse:n,complete:i}),o({effects:{},duration:400,reverse:!1,init:l,teardown:l,hide:!1},e,{completeCallback:e.complete,complete:l})}function fe(t,n,i,r,o){var a,s=0,l=t.length;for(;s<l;s++)(a=e(t[s])).queue((function(){ue.promise(a,pe(n,i,r,o))}));return t}e.extend(ue,{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.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}}),ue.promiseShim=ue.promise,"kendoAnimate"in e.fn||o(e.fn,{kendoStop:function(e,t){return this.stop(e,t)},kendoAnimate:function(e,t,n,i){return fe(this,e,t,n,i)},kendoAddClass:function(e,t){return r.toggleClass(this,e,t,!0)},kendoRemoveClass:function(e,t){return r.toggleClass(this,e,t,!1)},kendoToggleClass:function(e,t,n){return r.toggleClass(this,e,t,n)}});var me=/&/g,ge=/</g,ve=/"/g,_e=/'/g,be=/>/g;function we(e,t){return!0===t&&(e=function(e){var t={"&":"&","<":"<",">":">",""":'"',"'":"'"};return e.replace(/&(?:amp|lt|gt|quot|#39);/g,(function(e){return t[e]}))}(e)),(""+e).replace(me,"&").replace(ge,"<").replace(be,">").replace(ve,""").replace(_e,"'")}var ye=function(e){return e.target};u.touch&&(ye=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},a(["swipe","swipeLeft","swipeRight","swipeUp","swipeDown","doubleTap","tap"],(function(t,n){e.fn[n]=function(e){return this.on(n,e)}}))),u.touch?u.mobileOS?(u.mousedown="touchstart",u.mouseup="touchend",u.mousemove="touchmove",u.mousecancel="touchcancel",u.click="touchend",u.resize="orientationchange"):(u.mousedown="mousedown touchstart",u.mouseup="mouseup touchend",u.mousemove="mousemove touchmove",u.mousecancel="mouseleave touchcancel",u.click="click",u.resize="resize"):u.pointers?(u.mousemove="pointermove",u.mousedown="pointerdown",u.mouseup="pointerup",u.mousecancel="pointercancel",u.click="pointerup",u.resize="orientationchange resize"):u.msPointers?(u.mousemove="MSPointerMove",u.mousedown="MSPointerDown",u.mouseup="MSPointerUp",u.mousecancel="MSPointerCancel",u.click="MSPointerUp",u.resize="orientationchange resize"):(u.mousemove="mousemove",u.mousedown="mousedown",u.mouseup="mouseup",u.mousecancel="mouseleave",u.click="click",u.resize="resize");var ke=/^([a-z]+:)?\/\//i;o(r,{widgets:[],_widgetRegisteredCallbacks:[],ui:r.ui||{},fx:r.fx||function(e){return new r.effects.Element(e)},effects:r.effects||ue,mobile:r.mobile||{},data:r.data||{},dataviz:r.dataviz||{},drawing:r.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,SHIFT:16,NUMPAD_PLUS:107,NUMPAD_MINUS:109,NUMPAD_DOT:110},support:r.support||u,animate:r.animate||fe,ns:"",attr:function(e){return"data-"+r.ns+e},getShadows:function(e){var t=e.css("box-shadow"),n=t&&t.match(m)||[0,0,0,0,0],i=c.max(+n[3],+(n[4]||0));return{left:-n[1]+i,right:+n[1]+i,bottom:+n[2]+i}},wrap:function(n,i,o,a=!0,s){var l,c=r._outerWidth,d=r._outerHeight,h=n.parent(),u=c(t);if(h.parent().removeClass("k-animation-container-sm"),h.hasClass("k-child-animation-container"))ae(n,i,a);else{var f=n[0].style.width,m=n[0].style.height,g=p.test(f),v=p.test(m),_=n.hasClass("k-tooltip")||n.is(".k-menu-horizontal.k-context-menu"),b=n.hasClass("k-tooltip");l=g||v,!g&&(!i||i&&f||_)&&(f=i?c(n,!1,b)+1:c(n,!1,b)),(!v&&(!i||i&&m)||_)&&(m=d(n,!1,b)),n.wrap(e("<div/>").addClass("k-child-animation-container").css({width:s?"auto":f,height:m})),(h=n.parent()).wrap(e("<div/>").addClass("k-animation-container").attr("role","region")),l&&n.css({width:"100%",height:"100%"})}return u<c(h=h.parent())&&(h.addClass("k-animation-container-sm"),o=!0),o&&ae(n,i,a),h},deepExtend:se,getComputedStyles:he,isScrollable:function(e){if("false"===e.dataset[r.ns+"scrollable"])return!1;if(e&&e.className&&"string"==typeof e.className&&e.className.indexOf("k-auto-scrollable")>-1)return!0;var t=he(e,["overflow"]).overflow;return t.indexOf("auto")>-1||t.indexOf("scroll")>-1},scrollLeft:function t(i,r){var o=u.browser.webkit;var a=u.browser.mozilla;var s=u.browser.version;var l,c;if(i instanceof e&&r!==n)i.each((function(e,n){t(n,r)}));else if(l=i instanceof e?i[0]:i){if(c=u.isRtl(i),r===n)return c&&o&&(s<85||u.browser.safari)?l.scrollWidth-l.clientWidth-l.scrollLeft:Math.abs(l.scrollLeft);c&&o&&(s<85||u.browser.safari)?l.scrollLeft=l.scrollWidth-l.clientWidth-r:l.scrollLeft=c&&(a||o)&&r>0?-r:r}},size:function(e){var t,n=0;for(t in e)e.hasOwnProperty(t)&&"toJSON"!=t&&n++;return n},toCamelCase:de,toHyphens:function(e){return e.replace(/([a-z][A-Z])/g,(function(e){return e.charAt(0)+"-"+e.charAt(1).toLowerCase()}))},getOffset:r.getOffset||function(e,n,i){n||(n="offset");var r=e[n]();var o={top:r.top,right:r.right,bottom:r.bottom,left:r.left};if(u.browser.msie&&(u.pointers||u.msPointers)&&!i){var a=u.isRtl(e)?1:-1;o.top-=t.pageYOffset-document.documentElement.scrollTop,o.left-=t.pageXOffset+a*document.documentElement.scrollLeft}return o},parseEffects:r.parseEffects||function(e){var t={};return a("string"==typeof e?e.split(" "):e,(function(e){t[e]=this})),t},toggleClass:r.toggleClass||function(e,t,n,i){return t&&(t=t.split(" "),a(t,(function(t,n){e.toggleClass(n,i)}))),e},directions:r.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:Y,Class:j,Template:i,template:i.compile.bind(i),render:i.render.bind(i),stringify:h.stringify.bind(h),eventTarget:ye,htmlEncode:we,sanitizeLink:function(e){const n=["http:","https:"];let i="";try{const r=new URL(e,t.location.origin);if(!n.includes(r.protocol))throw new Error("Invalid protocol");i=e}catch{i="#INVALIDLINK"}return we(i)},convertTextUrlToLink:function(e){return e.replace(/(https?|chrome|mailto):\/\/[^\s$.?#].[^\s]*/gi,(function(e){let t=e;const n=e;t.match(/^[a-zA-Z][a-zA-Z0-9+.-]*:/)||(t=t.toLowerCase().startsWith("www.")?"https://"+t:t.includes("@")?"mailto:"+t:"https://"+t);try{t=new URL(t).href}catch(t){return e}let i="_blank";let r="noopener noreferrer";const o=t.split(":")[0].toLowerCase();return["mailto","tel","sms"].includes(o)&&(i="_self",r=""),`<a href="${we(t)}" target="${i}"${r?` rel="${r}"`:""}>${we(n)}</a>`}))},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&&!ke.test(e)},mediaQuery:H,expr:function(e,t,n){return typeof t==S&&(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 V[n]=V[n]||(n=>{const i=r.exprToArray(e,t);let o=n;for(let e=0;e<i.length;e++)if(o=o[i[e]],!r.isPresent(o)&&t)return o;return o})},setter:function(e){return N[e]=N[e]||((t,n)=>{const i=r.exprToArray(e);const o=({parent:e,val:t,prop:n,props:i})=>{i.length?(e=e[i.shift()],o({parent:e,val:t,prop:n,props:i})):e[n]=t};o({parent:t,val:n,prop:i.pop(),props:i})})},accessor:function(e){return{get:r.getter(e),set:r.setter(e)}},guid:function(){try{return d.randomUUID()}catch(e){return d.getRandomValues(new Uint8Array(16)).reduce(((e,t,n)=>(4!==n&&6!==n&&8!==n&&10!==n||(e+="-"),e+=t.toString(16).padStart(2,"0"))),"")}},roleSelector:function(e){return e.replace(/(\S+)/g,"["+r.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=r.widgets.length;t<n;t++)e(r.widgets[t]);r._widgetRegisteredCallbacks.push(e)},logToConsole:function(e,n){var i=t.console;!r.suppressLog&&void 0!==i&&i.log&&i[n||"log"](e)}});var xe=Y.extend({init:function(e,t){var n=this;E()||(n._showWatermarkOverlay=z),n.element=r.jQuery(e).handler(n),Y.fn.init.call(n);var i=t?t.dataSource:null;var a;t&&(a=(n.componentTypes||{})[(t||{}).componentType]),i&&(t=o({},t,{dataSource:{}})),t=n.options=o(!0,{},n.options,n.defaults,a||{},t),i&&(t.dataSource=i),n.element.attr(r.attr("role"))||n.element.attr(r.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){var 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: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 r.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,o,a=this.__proto__.options,s=this.options,l=e||this.wrapper||this.element,c=[];if(r.cssProperties.propertyDictionary[a.name]){for(t=0;t<U.length;t++)n=U[t],o=this.options._altname||a.name,a.hasOwnProperty(n)&&("themeColor"===n?(i=r.cssProperties.getValidClass({widget:o,propName:"fillMode",value:s.fillMode}))&&i.length&&c.push(r.cssProperties.getValidClass({widget:o,propName:n,value:s[n],fill:s.fillMode})):c.push(r.cssProperties.getValidClass({widget:o,propName:n,value:s[n]})));l.addClass(c.join(" "))}},_ariaLabel:function(t){var n,i=this.element,o=i.attr("id"),a=e('label[for="'+o+'"]'),s=i.attr(O),l=i.attr(F);t[0]!==i[0]&&(s?t.attr(O,s):l?t.attr(F,l):a.length&&(n=a.attr("id")||this._generateLabelId(a,o||r.guid()),t.attr(F,n)))},_clearCssClasses:function(e,t){var n,i,o,a=this.__proto__.options,s=this.options,l=t||this.wrapper||this.element;if(r.cssProperties.propertyDictionary[a.name])for(n=0;n<U.length;n++)i=U[n],o=this.options._altname||a.name,a.hasOwnProperty(i)&&e.hasOwnProperty(i)&&("themeColor"===i?l.removeClass(r.cssProperties.getValidClass({widget:o,propName:i,value:s[i],fill:s.fillMode})):("fillMode"===i&&l.removeClass(r.cssProperties.getValidClass({widget:o,propName:"themeColor",value:s.themeColor,fill:s.fillMode})),l.removeClass(r.cssProperties.getValidClass({widget:o,propName:i,value:s[i]}))))},_generateLabelId:function(e,t){var n=t+"_label";return e.attr("id",n),n}});var Ce=xe.extend({dataItems:function(){return this.dataSource.flatView()}});r.dimensions=function(e,t){var n=e[0];return t&&e.css(t),{width:n.offsetWidth,height:n.offsetHeight}},r.notify=l;var Se=/template$/i,Te=/^\s*(?:\{(?:.|\r\n|\n)*\}|\[(?:.|\r\n|\n)*\])\s*$/,Me=/^\{(\d+)(:[^\}]+)?\}|^\[[A-Za-z_]+\]$/,Ae=/([A-Z])/g;function De(e,t,i){let o,a=!1;if(0===t.indexOf("data")&&(t=(t=t.substring(4)).charAt(0).toLowerCase()+t.substring(1)),t=t.replace(Ae,"-$1"),o=e.getAttribute("data-"+r.ns+t),null===o&&(o=e.getAttribute("bind:data-"+r.ns+t),a=!0),null===o)o=n;else if("null"===o)o=null;else if("true"===o)o=!0;else if("false"===o)o=!1;else if(g.test(o)&&"mask"!=t&&"format"!=t)o=parseFloat(o);else if(Te.test(o)&&!Me.test(o))try{o=h.parse(o)}catch(e){o=new Function("return ("+o+")")()}else a&&(o=i[o],o instanceof Y&&(o=o.toJSON(!0)));return o}function Ee(t,i,o){var a,s,l={},c=t.getAttribute("data-"+r.ns+"role");for(a in i)(s=De(t,a,o))!==n&&(Se.test(a)&&"drawer"!=c&&("string"==typeof s?s=Ie(s)?r.template(e("#"+s).html()):o&&o[s]?r.template(o[s]):r.template(s):q(s)||(s=t.getAttribute(a))),l[a]=s);return l}function Ie(t){try{return e("#"+t).length}catch(e){}return!1}function ze(t,n){return e.contains(t,n)?-1:1}function Pe(){var t=e(this);return e.inArray(t.attr("data-"+r.ns+"role"),["slider","rangeslider","breadcrumb"])>-1||t.is(":visible")}r.initWidget=function(i,o,a,s){var l,c,d,h,u,p,f,m,g,v;if(a?a.roles&&(a=a.roles):a=r.ui.roles,p=(i=i.nodeType?i:i[0]).getAttribute("data-"+r.ns+"role")){d=(g=-1===p.indexOf("."))?a[p]:r.getter(p)(t);var _=e(i).data(),b=d?"kendo"+d.fn.options.prefix+d.fn.options.name:"";for(var w in v=g?new RegExp("^kendo.*"+p+"$","i"):new RegExp("^"+b+"$","i"),_)if(w.match(v)){if(w!==b)return _[w];l=_[w]}if(d){for(m=De(i,"dataSource"),o=e.extend({},Ee(i,e.extend({},d.fn.options,d.fn.defaults),s),o),m&&(o.dataSource=typeof m===S?r.getter(m)(t):m),h=0,u=d.fn.events.length;h<u;h++)(f=De(i,c=d.fn.events[h]))!==n&&(o[c]=r.getter(f)(t));return l?e.isEmptyObject(o)||l.setOptions(o):l=new d(i,o),l}}},r.rolesFromNamespaces=function(e){var t,n,i=[];for(e[0]||(e=[r.ui,r.dataviz.ui]),t=0,n=e.length;t<n;t++)i[t]=e[t].roles;return o.apply(null,[{}].concat(i.reverse()))},r.init=function(t){var n=r.rolesFromNamespaces($.call(arguments,1));e(t).find("[data-"+r.ns+"role]").addBack().each((function(){r.initWidget(this,{},n)}))},r.destroy=function(t){e(t).find("[data-"+r.ns+"role]").addBack().each((function(){var t=e(this).data();for(var n in t)0===n.indexOf("kendo")&&typeof t[n].destroy===C&&t[n].destroy()}))},r.resize=function(t,n){var i=e(t).find("[data-"+r.ns+"role]").addBack().filter(Pe);if(i.length){var o=e.makeArray(i);o.sort(ze),e.each(o,(function(){var t=r.widgetInstance(e(this));t&&t.resize(n)}))}},r.parseOptions=Ee,o(r.ui,{Widget:xe,DataBoundWidget:Ce,roles:{},progress:function(t,n,i){var o,a,s,l,c,d=t.find(".k-loading-mask"),h=r.support,u=h.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||(a=(o=h.isRtl(t))?"right":"left",l=r.scrollLeft(t),s=u.webkit&&o?t[0].scrollWidth-t.width()-2*l:0,d=e(r.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,r.ui.progress.messages.loading)).width(i.width).height(i.height).css("top",i.top).css(a,Math.abs(l)+s).prependTo(t)):d&&d.remove()},plugin:function(t,i,o){var a,s=t.fn.options.name;o=o||"",(i=i||r.ui)[s]=t,i.roles[s.toLowerCase()]=t,a="getKendo"+o+s;var l={name:s="kendo"+o+s,widget:t,prefix:o||""};r.widgets.push(l);for(var c=0,d=r._widgetRegisteredCallbacks.length;c<d;c++)r._widgetRegisteredCallbacks[c](l);e.fn[s]=function(i){var o,a=this;return typeof i===S?(o=$.call(arguments,1),this.each((function(){var t,l,c=e.data(this,s);if(!c)throw new Error(r.format("Cannot call method '{0}' of {1} before it is initialized",i,s));if(typeof(t=c[i])!==C)throw new Error(r.format("Cannot find method '{0}' of {1}",i,s));if((l=t.apply(c,o))!==n)return a=l,!1}))):this.each((function(){return new t(this,i)})),a},e.fn[s].widget=t,e.fn[a]=function(){return this.data(s)}}}),r.ui.progress.messages={loading:"Loading..."};var Le={bind:function(){return this},nullObject:!0,options:{}};var Be=xe.extend({init:function(e,t){xe.fn.init.call(this,e,t),this.element.autoApplyNS(),this.wrapper=this.element,this.element.addClass("km-widget")},destroy:function(){xe.fn.destroy.call(this),this.element.kendoDestroy()},options:{prefix:"Mobile"},events:[],view:function(){var e=this.element.closest(r.roleSelector("view splitview modalview drawer"));return r.widgetInstance(e,r.mobile.ui)||Le},viewHasNativeScrolling:function(){var e=this.view();return e&&e.options.useNativeScrolling},container:function(){var e=this.element.closest(r.roleSelector("view layout modalview drawer splitview"));return r.widgetInstance(e.eq(0),r.mobile.ui)||Le}});function He(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)}o(r.mobile,{init:function(e){r.init(e,r.mobile.ui,r.ui,r.dataviz.ui)},roles:{},ui:{Widget:Be,DataBoundWidget:Ce.extend(Be.prototype),roles:{},plugin:function(e){r.ui.plugin(e,r.mobile.ui,"Mobile")}}}),se(r.dataviz,{init:function(e){r.init(e,r.dataviz.ui)},ui:{roles:{},themes:{},views:[],plugin:function(e){r.ui.plugin(e,r.dataviz.ui)}},roles:{}}),r.touchScroller=function(t,n){return n||(n={}),n.useNative=!0,e(t).map((function(t,i){return i=e(i),!(!u.kineticScrollNeeded||!r.mobile.ui.Scroller||i.data("kendoMobileScroller"))&&(i.kendoMobileScroller(n),i.data("kendoMobileScroller"))}))[0]},r.preventDefault=function(e){e.preventDefault()},r.widgetInstance=function(e,n){var i,o,a=e.data(r.ns+"role"),s=[],l=e.data("kendoView");if(a){if("content"===a&&(a="scroller"),"view"===a&&l)return l;if(n)if(n[0])for(i=0,o=n.length;i<o;i++)s.push(n[i].roles[a]);else s.push(n.roles[a]);else s=[r.ui.roles[a],r.dataviz.ui.roles[a],r.mobile.ui.roles[a]];for(a.indexOf(".")>=0&&(s=[r.getter(a)(t)]),i=0,o=s.length;i<o;i++){var c=s[i];if(c){var d=e.data("kendo"+c.fn.options.prefix+c.fn.options.name);if(d)return d}}}},r.onResize=function(n){var i=n;return u.mobileOS.android&&(i=function(){setTimeout(n,600)}),e(t).on(u.resize,i),i},r.unbindResize=function(n){e(t).off(u.resize,n)},r.attrValue=function(e,t){return e.data(r.ns+t)},r.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 He(t,!isNaN(n)&&n>-1)}});var Re=["mousedown","mousemove","mouseenter","mouseleave","mouseover","mouseout","mouseup","click"];var Fe={setupMouseMute:function(){var t=0,n=Re.length,i=document.documentElement;if(!Fe.mouseTrap&&u.eventCapture){Fe.mouseTrap=!0,Fe.bustClick=!1,Fe.captureMouse=!1;var r=function(t){Fe.captureMouse&&("click"===t.type?Fe.bustClick&&!e(t.target).is("label, input, [data-rel=external]")&&(t.preventDefault(),t.stopPropagation()):t.stopPropagation())};for(;t<n;t++)i.addEventListener(Re[t],r,!0)}},muteMouse:function(e){Fe.captureMouse=!0,e.data.bustClick&&(Fe.bustClick=!0),clearTimeout(Fe.mouseTrapTimeoutID)},unMuteMouse:function(){clearTimeout(Fe.mouseTrapTimeoutID),Fe.mouseTrapTimeoutID=setTimeout((function(){Fe.captureMouse=!1,Fe.bustClick=!1}),400)}};var Oe={down:"touchstart mousedown",move:"mousemove touchmove",up:"mouseup touchend touchcancel",cancel:"mouseleave touchcancel"};u.touch&&(u.mobileOS.ios||u.mobileOS.android)?Oe={down:"touchstart",move:"touchmove",up:"touchend touchcancel",cancel:"touchcancel"}:u.pointers?Oe={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"}:u.msPointers&&(Oe={down:"MSPointerDown",move:"MSPointerMove",up:"MSPointerUp",cancel:"MSPointerCancel MSPointerLeave"}),u.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 Ve=function(e){return Oe[e]||e},Ne=/([^ ]+)/g;r.applyEventMap=function(e,t){return e=e.replace(Ne,Ve),t&&(e=e.replace(Ne,"$1."+t)),e},r.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 $e=e.fn.on;function Ue(e,t){return new Ue.fn.init(e,t)}W(!0,Ue,e),Ue.fn=Ue.prototype=new e,Ue.fn.constructor=Ue,Ue.fn.init=function(t,n){return n&&n instanceof e&&!(n instanceof Ue)&&(n=Ue(n)),e.fn.init.call(this,t,n,We)},Ue.fn.init.prototype=Ue.fn;var We=Ue(document);o(Ue.fn,{handler:function(e){return this.data("handler",e),this},autoApplyNS:function(e){return this.data("kendoNS",e||r.guid()),this},on:function(){var e=this,t=e.data("kendoNS");if(1===arguments.length)return $e.call(e,arguments[0]);var n=e,i=$.call(arguments);typeof i[i.length-1]===P&&i.pop();var o=i[i.length-1],a=r.applyEventMap(i[0],t);if(u.mouseAndTouchPresent&&a.search(/mouse|click/)>-1&&this[0]!==document.documentElement){Fe.setupMouseMute();var s=2===i.length?null:i[1],l=a.indexOf("click")>-1&&a.indexOf("touchend")>-1;$e.call(this,{touchstart:Fe.muteMouse,touchend:Fe.unMuteMouse},s,{bustClick:l})}if(-1!==arguments[0].indexOf("keydown")&&i[1]&&i[1].options){i[0]=a;var c=i[1];var d=i[i.length-1];return i[i.length-1]=function(e){if(r.keyDownHandler(e,c))return d.apply(this,[e])},$e.apply(e,i),e}return typeof o===S&&(n=e.data("handler"),o=n[o],i[i.length-1]=function(e){o.call(n,e)}),i[0]=a,$e.apply(e,i),e},kendoDestroy:function(e){return(e=e||this.data("kendoNS"))&&this.off("."+e),this}}),r.jQuery=Ue,r.eventMap=Oe,r.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};var t={Sun:0,Mon:1,Tue:2,Wed:3,Thu:4,Fri:5,Sat:6};function n(n,i){var r;var o;var a;var s=i[3];var l=i[4];var c=i[5];var 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(":");var 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];var 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 o(e,t,n,r){typeof e!=T&&(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=o(e,this.zones,this.rules,t);var i=n.zone;var a=n.rule;return r.parseFloat(a?i[0]-a[6]:i[0])},convert:function(e,t,n){var i=n;var r;typeof t==S&&(t=this.offset(e,t)),typeof n==S&&(n=this.offset(e,n));var o=e.getTimezoneOffset();var a=(e=new Date(e.getTime()+6e4*(t-n))).getTimezoneOffset();return typeof i==S&&(i=this.offset(e,i)),r=a-o+(n-i),new Date(e.getTime()+6e4*r)},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=o(e,this.zones,this.rules,t);var i=n.zone;var r=n.rule;var a=i[2];return a.indexOf("/")>=0?a.split("/")[r&&+r[6]?1:0]:a.indexOf("%s")>=0?a.replace("%s",r&&"-"!=r[7]?r[7]:""):a},toLocalDate:function(e){return this.apply(new Date(e),"Etc/UTC")}}}(),r.date=function(){var e=6e4,t=864e5;function i(e,t){return 0===t&&23===e.getHours()&&(e.setHours(e.getHours()+2),!0)}function o(e,t,n){var r=e.getHours();n=n||1,t=(t-e.getDay()+7*n)%7,e.setDate(e.getDate()+t),i(e,r)}function a(e,t,n){return o(e=new Date(e),t,n),e}function s(e){return new Date(e.getFullYear(),e.getMonth(),1)}function l(e,n){var i=new Date(e.getFullYear(),0,1,-6);var r=function(e,t){return 1!==t?h(a(e,t,-1),4):h(e,4-(e.getDay()||7))}(e,n);var o=r.getTime()-i.getTime();var s=Math.floor(o/t);return 1+Math.floor(s/7)}function c(e){return i(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 h(e,n){var r=e.getHours();return u(e=new Date(e),n*t),i(e,r),e}function u(t,n,i){var r=t.getTimezoneOffset();var o;t.setTime(t.getTime()+n),i||(o=t.getTimezoneOffset()-r,t.setTime(t.getTime()+o*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:i,dayOfWeek:a,setDayOfWeek:o,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 h(e,1)},previousDay:function(e){return h(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:u,setHours:function(e,t){return i(e=new Date(e.getFullYear(),e.getMonth(),e.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),t.getHours()),e},addDays:h,today:p,toInvariantTime:f,firstDayOfMonth:s,splitDateFormat:function(e){var t=function(e,t){var n=t.calendar;var i;return"string"==typeof e&&(i=n.patterns[e]?n.patterns[e]:e),i||(i=n.patterns.d),i}(e,r.culture()).replaceAll("dddd","EEEE").replaceAll("ddd","EEE").replace("tt","aa");var n=[];var i=/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;var o=i.lastIndex=0;var a=i.exec(t);var s;var l;var c;var d;var h;var u;for(;a;){var p=a[0];o<a.index&&g(n,t.substring(o,a.index)),_(p,'"')||_(p,"'")?g(n,p):(s=p[0],c={type:l=k[s],pattern:p},"hour"===l&&(c.hour12=v(p)),(d=x[l])&&(h="number"==typeof d.minLength?d.minLength:d.minLength[s],(u=p.length)>=h&&"aa"!==p&&(c.names={type:d.type,nameType:(f=u,m=void 0,f<=3?m="abbreviated":4===f?m="wide":5===f&&(m="narrow"),m),standAlone:d.standAlone===s})),n.push(c)),o=i.lastIndex,a=i.exec(t)}var f,m;return o<t.length&&g(n,t.substring(o)),n},dateFieldName:function(e){return(r.culture().calendar.dateFields[e.type]||{})[e.nameType]},dateFormatNames:function(e){let{type:t,nameType:n}=e;const i=r.culture();"wide"===n&&(n="names"),"abbreviated"===n&&(n="namesAbbr"),"narrow"===n&&(n="namesShort");let o=i.calendar[t][n];return o||(o=i.calendar[t].name),o},lastDayOfMonth:function(e){var t=new Date(e.getFullYear(),e.getMonth()+1,0),n=s(e),i=Math.abs(t.getTimezoneOffset()-n.getTimezoneOffset());return i&&t.setHours(n.getHours()+i/60),t},weekInYear:function(e,t){t===n&&(t=r.culture().calendar.firstDay);var i=h(e,-7);var o=h(e,7);var a=l(e,t);return 0===a?l(i,t)+1:53===a&&l(o,t)>1?1:a},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)}}}(),r.stripWhitespace=function(e){if(document.createNodeIterator){var t=document.createNodeIterator(e,NodeFilter.SHOW_TEXT,(function(t){return t.parentNode==e?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}),!1);for(;t.nextNode();)t.referenceNode&&!t.referenceNode.textContent.trim()&&t.referenceNode.parentNode.removeChild(t.referenceNode)}};var je=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e){setTimeout(e,1e3/60)};r.animationFrame=function(e){je.call(t,e)};var qe=[];r.queueAnimation=function(e){qe[qe.length]=e,1===qe.length&&r.runNextAnimation()},r.runNextAnimation=function(){r.animationFrame((function(){qe[0]&&(qe.shift()(),qe[0]&&r.runNextAnimation())}))},r.parseQueryStringParams=function(e){var t={},n=(e.split("?")[1]||"").split(/&|=/),i=n.length,r=0;for(;r<i;r+=2)""!==n[r]&&(t[decodeURIComponent(n[r])]=decodeURIComponent(n[r+1]));return t},r.elementUnderCursor=function(e){if(void 0!==e.x.client)return document.elementFromPoint(e.x.client,e.y.client)},r.wheelDeltaY=function(e){var t,i=e.originalEvent,r=i.wheelDeltaY;return i.wheelDelta?(r===n||r)&&(t=i.wheelDelta):i.detail&&i.axis===i.VERTICAL_AXIS&&(t=10*-i.detail),t},r.throttle=function(e,t){var n;var i=0;if(!t||t<=0)return e;var r=function(){var r=this;var o=+new Date-i;var 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},r.caret=function(t,i,r){var o;var a=i!==n;if(r===n&&(r=i),t[0]&&(t=t[0]),!a||!t.disabled){try{if(t.selectionStart!==n)if(a){t.focus();var s=u.mobileOS;s.wp||s.android?setTimeout((function(){t.setSelectionRange(i,r)}),0):t.setSelectionRange(i,r)}else i=[t.selectionStart,t.selectionEnd];else if(document.selection)if(e(t).is(":visible")&&t.focus(),o=t.createTextRange(),a)o.collapse(!0),o.moveStart("character",i),o.moveEnd("character",r-i),o.select();else{var l,c,d=o.duplicate();o.moveToBookmark(document.selection.createRange().getBookmark()),d.setEndPoint("EndToStart",o),c=(l=d.text.length)+o.text.length,i=[l,c]}}catch(e){i=[]}return i}},r.antiForgeryTokens=function(){var t={},i=e("meta[name=csrf-token],meta[name=_csrf]").attr("content"),r=e("meta[name=csrf-param],meta[name=_csrf_header]").attr("content");return e("input[name^='__RequestVerificationToken']").each((function(){t[this.name]=this.value})),r!==n&&i!==n&&(t[r]=i),t},r.cycleForm=function(e){var t=e.find("input, .k-widget, .k-dropdownlist, .k-combobox").first();var n=e.find("button, .k-button").last();function i(e){var t=r.widgetInstance(e);t&&t.focus?t.focus():e.trigger("focus")}n.on("keydown",(function(e){e.keyCode!=r.keys.TAB||e.shiftKey||(e.preventDefault(),i(t))})),t.on("keydown",(function(e){e.keyCode==r.keys.TAB&&e.shiftKey&&(e.preventDefault(),i(n))}))},r.focusElement=function(n){var i=[];var o=n.parentsUntil("body").filter((function(e,t){return"visible"!==r.getComputedStyles(t,["overflow"]).overflow})).add(t);o.each((function(t,n){i[t]=e(n).scrollTop()}));try{n[0].setActive()}catch(e){n.trigger("focus")}o.each((function(t,n){e(n).scrollTop(i[t])}))},r.focusNextElement=function(){if(document.activeElement){var t=e(":kendoFocusable");var n=t.index(document.activeElement);if(n>-1)(t[n+1]||t[0]).focus()}},r.trim=function(e){return e?e.toString().trim():""},r.getWidgetFocusableElement=function(t){var n=t.closest(":kendoFocusable"),i=r.widgetInstance(t);return n.length?n:i?"Editor"===i.options.name?e(i.body):i.wrapper.find(":kendoFocusable").first():t},r.addAttribute=function(e,t,n){var i=e.attr(t)||"";i.indexOf(n)<0&&e.attr(t,(i+" "+n).trim())},r.removeAttribute=function(e,t,n){var i=e.attr(t)||"";e.attr(t,i.replace(n,"").trim())},r.toggleAttribute=function(e,t,n){(e.attr(t)||"").indexOf(n)<0?r.addAttribute(e,t,n):r.removeAttribute(e,t,n)},r.matchesMedia=function(e){var n=r._bootstrapToMedia(e)||e;return u.matchMedia&&t.matchMedia(n).matches},r._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]},r.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"]},r.getFileGroup=function(e,t){var i=r.fileGroupMap;var o=Object.keys(i);var a="file";if(e===n||!e.length)return a;for(var s=0;s<o.length;s+=1){if(i[o[s]].indexOf(e.toLowerCase())>-1)return t?"file-"+o[s]:o[s]}return a},r.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]},r.selectorFromClasses=function(e){return"."+e.split(" ").join(".")};var Ge=["base","primary","secondary","tertiary","inherit","info","success","warning","error","dark","light","inverse"];var Ke=["solid","outline","flat"];var Ye=["rectangle","square"];var Qe=[["small","sm"],["medium","md"],["large","lg"]];var Xe=[["small","sm"],["medium","md"],["large","lg"],["full","full"]];var Ze=["fixed","static","sticky","absolute"];var Je=[["both","resize"],["horizontal","resize-x"],["vertical","resize-y"]];var et=["auto","hidden","visible","scroll","clip"];var tt=[["vertical","!k-flex-col"],["horizontal","!k-flex-row"]];r.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++)s(n[i])?t(e,n[i][0],n[i][1]):t(e,n[i])}return n("themeColor",Ge),n("fillMode",Ke),n("shape",Ye),n("size",Qe),n("positionMode",Ze),n("rounded",Xe),n("resize",Je),n("overflow",et),n("layoutFlow",tt),{positionModeValues:Ze,roundedValues:Xe,sizeValues:Qe,shapeValues:Ye,fillModeValues:Ke,themeColorValues:Ge,defaultValues:e,propertyDictionary:{},registerValues:function(e,t){var n,i,o,a,l,c,d=r.cssProperties.propertyDictionary;for(n=0;n<t.length;n++)for(o=t[n].prop,l=t[n].values,d[e][o]||(d[e][o]={}),a=d[e][o],i=0;i<l.length;i++)c=l[i],s(l[i])?a[c[0]]=c[1]:a[c]=c},getValidClass:function(e){var t,n,i,o=e.widget,a=e.propName,s=e.value,l=e.fill,c=r.cssProperties,d=c.defaultValues[a],h=c.propertyDictionary[o],u=e.prefix;return h&&(n=(t=h[a])&&t[s]||d[s])?(i="themeColor"===a?h[L]+l+"-":"positionMode"===a?"k-pos-":"rounded"===a?"k-rounded-":"resize"===a?"k-":"overflow"===a?"k-overflow-":"layoutFlow"===a?"":h[L],(i=u||i)+n):""},registerPrefix:function(e,t){var n=r.cssProperties.propertyDictionary;n[e]||(n[e]={}),n[e][L]=t}}}(),r.registerCssClass=function(e,t,n){r.propertyToCssClassMap[e]||(r.propertyToCssClassMap[e]={}),r.propertyToCssClassMap[e][t]=n||t},r.registerCssClasses=function(e,t){for(var n=0;n<t.length;n++)s(t[n])?r.registerCssClass(e,t[n][0],t[n][1]):r.registerCssClass(e,t[n])},r.getValidCssClass=function(e,t,n){var i=r.propertyToCssClassMap[t][n];if(i)return e+i},r.propertyToCssClassMap={},r.registerCssClasses("themeColor",Ge),r.registerCssClasses("fill",Ke),r.registerCssClasses("shape",Ye),r.registerCssClasses("size",Qe),r.registerCssClasses("positionMode",Ze),r.applyStylesFromKendoAttributes=function(t,n){let i=n.map((e=>`[${r.attr(`style-${e}`)}]`)).join(",");t.find(i).addBack(i).each(((t,i)=>{let o=e(i);n.forEach((function(e){let t=r.attr(`style-${e}`);o.attr(t)&&(o.css(e,o.attr(t)),o.removeAttr(t))}))}))},r.whenAll=function(t){var n,i=1==arguments.length&&Array.isArray(t)?t:Array.prototype.slice.call(arguments),o=i.length,a=o,s=e.Deferred(),l=0,c=0,d=Array(o),h=Array(o),u=Array(o);function p(e,t,n){return function(){n!=i&&c++,s.notifyWith(t[e]=this,n[e]=Array.prototype.slice.call(arguments)),--a||s[(c?"reject":"resolve")+"With"](t,n)}}for(;l<o;l++)(n=i[l])&&r.isFunction(n.promise)?n.promise().done(p(l,u,i)).fail(p(l,d,h)):(s.notifyWith(this,n),--a);return a||s.resolveWith(u,i),s.promise()},function(){function n(t,n,i,o){var a=e("<form>").attr({action:i,method:"POST",target:o});var s=r.antiForgeryTokens();s.fileName=n;var l=t.split(";base64,");for(var c in s.contentType=l[0].replace("data:",""),s.base64=l[1],s)s.hasOwnProperty(c)&&e("<input>").attr({value:s[c],name:c,type:"hidden"}).appendTo(a);a.appendTo("body").submit().remove()}var i=document.createElement("a");var o="download"in i&&!r.support.browser.edge;function a(e,t){var n=e;if("string"==typeof e){var i=e.split(";base64,");var r=i[0];var o=atob(i[1]);var a=new Uint8Array(o.length);for(var s=0;s<o.length;s++)a[s]=o.charCodeAt(s);n=new Blob([a.buffer],{type:r})}navigator.msSaveBlob(n,t)}function s(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)}))}r.saveAs=function(e){var t=n;e.forceProxy||(o?t=s:navigator.msSaveBlob&&(t=a)),t(e.dataURI,e.fileName,e.proxyURL,e.proxyTarget)}}(),r.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},r.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},r.isElement=function(e){return e instanceof Element||e instanceof HTMLDocument},r.defaults=r.defaults||{},r.setDefaults=function(e,t){var i=e.split(".");var o=r.defaults;e=i.pop(),i.forEach((function(e){o[e]===n&&(o[e]={}),o=o[e]})),t.constructor===Object?o[e]=se({},o[e],t):o[e]=t},r.debugTemplates=t.DEBUG_KENDO_TEMPLATES,r.setDefaults("breakpoints",B),r.class2type={},jQuery.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),(function(e,t){r.class2type["[object "+t+"]"]=t.toLowerCase()})),r.type=function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?r.class2type[Object.prototype.toString.call(e)]||"object":typeof e}}(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 h(e){return e?"#!":"#"}function u(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)}});var 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=u(h(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=h(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 u(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)}});var 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,h=/[\-{}\[\]+?.,\\\^$|#\s]/g;function u(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(h,"\\$&").replace(l,"(?:$1)?").replace(c,u).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)}});var 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;var i=!!t.decode;var a=t.backButtonPressed;if(n||(n="/"),this.trigger(o,{url:t.url,params:e.parseQueryStringParams(t.url),backButtonPressed:a}))t.preventDefault();else{var s=0,l=this.routes,c=l.length;for(;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,h,u,p,f=[],m=e.logic||"and",g=e.filters;for(i=0,r=g.length;i<r;i++)o=(e=g[i]).field,u=e.value,h=e.operator,e.filters?e=d(e,n):(p=e.ignoreCase,o=o.replace(/\./g,"/"),e=a[h],n&&(e=s[h]),"isnullorempty"===h?e=t.format("({0} {1} null or {0} {1} '')",o,e):"isnotnullorempty"===h?e=t.format("({0} {1} null and {0} {1} '')",o,e):"isnull"===h||"isnotnull"===h?e=t.format("{0} {1} null",o,e):"isempty"===h||"isnotempty"===h?e=t.format("{0} {1} ''",o,e):e&&undefined!==u&&("string"===(l=t.type(u))?(c="'{1}'",u=u.replace(/'/g,"''"),!0===p&&(o="tolower("+o+")")):"date"===l?n?(c="{1:yyyy-MM-ddTHH:mm:ss+00:00}",u=t.timezone.apply(u,"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"===h&&(n?(c="{0}({2},'{1}') eq -1",e="indexof"):c+=" eq false")):c="{2} {0} "+c,e=t.format(c,e,u,o))),f.push(e);return e=f.join(" "+m+" "),f.length>1&&(e="("+e+")"),e}function h(e){for(var t in e)0===t.indexOf("@odata")&&delete e[t]}function u(){return Math.floor(65536*(1+Math.random())).toString(16).substr(1)}function p(e){return e+u()+"-"+u()+"-"+u()}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;var 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){var c="";for(var d=0;d<e.length;d++)c+=g(n,o),c+=r+m(s,e[d],s.options[a].type,a)+" HTTP/1.1",l||(c+=(h=e[d],u=void 0,u="",u+="\r\nContent-Type: application/json;odata=minimalmetadata",u+="\r\nPrefer: return=representation",u+=r+t.stringify(h))),c+=i,o++;var h,u;return c}(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++)h(t[n]);return t}return h(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);var r=p("sf_batch_");var a="";var s=0;var l=e.options.batch.url;var 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);var a=i.data;(a.updated.length||a.destroyed.length||a.created.length)&&e.ajax(n(!0,{},{success:function(e){var n=function(e){var n=e.match(/--changesetresponse_[a-z0-9-]+$/gm);var i=0;var r=[];var o;var a;var s;var l;var c;r.push({models:[],passed:!0});for(var d=0;d<n.length;d++)(l=n[d]).lastIndexOf("--",l.length-1)?d<n.length-1&&r.push({models:[],passed:!0}):(i=i?e.indexOf(l,i+l.length):e.indexOf(l),a=(o=e.substring(i,e.indexOf("--",i+1))).match(/^HTTP\/1\.\d (\d{3}) (.*)$/gm).pop(),(s=t.parseFloat(a.match(/\d{3}/g).pop()))>=200&&s<=299?(c=o.match(/\{.*\}/gm))&&r[r.length-1].models.push(JSON.parse(c[0])):r[r.length-1].passed=!1);return r}(e);var r=0;var o;a.updated.length&&((o=n[r]).passed&&i.success(o.models.length?o.models:[],"update"),r++),a.destroyed.length&&((o=n[r]).passed&&i.success([],"destroy"),r++),a.created.length&&(o=n[r]).passed&&i.success(o.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;var l=t.Class.extend({init:function(e){var s=this,l=e.total,c=e.model,d=e.parse,h=e.errors,u=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)),h&&("string"==typeof h?(h=s.getter(h),s.errors=function(e){return h(e)||null}):"function"==typeof h&&(s.errors=h)),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 u&&(s.serialize=u)},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,h=d.length;for(l=0;l<h;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){var i,r,o,a,s,l=t.split(".");for(;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 O={or:{concat:(e,t)=>n=>e(n)||t(n),identity:()=>!1},and:{concat:(e,t)=>n=>e(n)&&t(n),identity:()=>!0}};const V={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)};const N=/^\/Date\((.*?)\)\/$/;const U=({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=N.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=N.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:V[i];return e=>a(o(e),n,t)};const W=e=>{const t=e.accentFoldingFiltering;const n=O[e.logic||"and"];return e.filters.filter(kendo.isPresent).map((e=>{return n=e,kendo.isPresent(n.filters)?W(j(e,t)):U(j(e,t));var n})).reduce(n.concat,n.identity)};const j=(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,u=h.isFunction,p=h.Observable,f=h.Class,m="string",g="function",v="create",_="read",b="update",w="destroy",y="change",k="sync",x="get",C="error",S="requestStart",T="progress",M="requestEnd",A="itemsLoaded",D="itemLoad",E=[v,_,b,w],I=function(e){return e},z=h.getter,P=h.stringify,L=Math,B=[].push,H=[].join,R=[].pop,F=[].splice,O=[].shift,V=[].slice,N=[].unshift,$={}.toString,U=h.support.stableSort,j=/^\/Date\((.*?)\)\/$/,q=[];var G=p.extend({init:function(e,t){var n=this;n.type=t||X,p.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]"===$.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(y,(function(t){var i=e.hasOwnProperty("hasSubgroups");n.trigger(y,{field:t.field,node:t.node,index:t.index,items:t.items||[this],action:t.node||i?t.action||"itemloaded":"itemchange"})})),e.bind(D,(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(A,{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=B.apply(this,n),this.omitChangeEvent||this.trigger(y,{action:"add",index:t,items:n}),e},slice:V,sort:[].sort,join:H,pop:function(){var e=this.length,t=R.apply(this);return e&&this.trigger(y,{action:"remove",index:e-1,items:[t]}),t},splice:function(e,t,n){var i,r,o,a=this.wrapAll(V.call(arguments,2));if((i=F.apply(this,[e,t].concat(a))).length)for(this.omitChangeEvent||(this.trigger(y,{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(y);return n&&(this.omitChangeEvent||this.trigger(y,{action:"add",index:e,items:a})),i},shift:function(){var e=this.length,t=O.apply(this);return e&&this.trigger(y,{action:"remove",index:0,items:[t]}),t},unshift:function(){var e,t=this.wrapAll(arguments);return e=N.apply(this,t),this.trigger(y,{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){var n=0;var i=this.length;var r=t||window;for(;n<i;n++)e.call(r,this[n],n,this)},map:function(e,t){var n=0;var i=[];var r=this.length;var o=t||window;for(;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){var n=0;var i=[];var r;var o=this.length;var a=t||window;for(;n<o;n++)r=this[n],e.call(a,r,n,this)&&(i[i.length]=r);return i},find:function(e,t){var n=0;var i;var r=this.length;var o=t||window;for(;n<r;n++)if(i=this[n],e.call(o,i,n,this))return i},every:function(e,t){var n=0;var i;var r=this.length;var o=t||window;for(;n<r;n++)if(i=this[n],!e.call(o,i,n,this))return!1;return!0},some:function(e,t){var n=0;var i;var r=this.length;var o=t||window;for(;n<r;n++)if(i=this[n],e.call(o,i,n,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){p.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==y&&e._notifyChange&&e._notifyChange(a),e.trigger(t,a)}}function Q(e,t){var n=[];var i=[];var 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||{})||(i=Object.getOwnPropertyNames(Object.getPrototypeOf(e)).filter((e=>0!==e.indexOf("__")))),r=Object.getOwnPropertyNames(e).concat(i),o=q.filter((function(e){return r.indexOf(e)<0}));e;)Object.getOwnPropertyNames(e).forEach((function(e){-1===n.indexOf(e)&&(!t||o.indexOf(e)<0)&&n.push(e)})),e=Object.getPrototypeOf(e);return n}q=Q({},!1);var X=p.extend({init:function(e){var t,n=this,i=Q(e,!0),r=function(){return n};p.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]!==g)&&"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(x,{field:e}),"this"===e?t:h.getter(e,!0)(t)},_set:function(e,t){var n=e.indexOf(".")>=0;if(n){var i=e.split("."),r="";for(;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 p&&this._handlers[e]&&(this._handlers[e].get&&o.unbind(x,this._handlers[e].get),o.unbind(y,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(y,{field:e}))),i},parent:d,wrap:function(e,t,n){var i=this;var r;var o;var a=$.call(e);if(null!=e&&("[object Object]"===a||"[object Array]"===a)){var s=e instanceof G;var l=e instanceof Ge;"[object Object]"!==a||l||s?("[object Array]"===a||s||l)&&(s||l||(e=new G(e)),o=Y(i,y,t,!1),e.bind(y,o),i._handlers[t]={change:o}):(e instanceof X||(e=new X(e)),r=Y(i,x,t,!0),e.bind(x,r),o=Y(i,y,t,!0),e.bind(y,o),i._handlers[t]={get:r,change:o}),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===m&&"null"===e.toLowerCase()?null:h.parseFloat(e)},date:function(e){return typeof e===m&&"null"===e.toLowerCase()?null:h.parseDate(e)},boolean:function(e){return typeof e===m?"null"===e.toLowerCase()?null:"true"===e.toLowerCase():null!=e?!!e:e},string:function(e){return typeof e===m&&"null"===e.toLowerCase()?null:null!=e?e+"":e},default:function(e){return e}};var 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;var 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,h,u,p=i({defaults:{}},r),f={},g=p.id,v=[];if(g&&(p.idField=g),p.id&&delete p.id,g&&(p.defaults[g]=p._defaultId=""),"[object Array]"===$.call(p.fields)){for(d=0,h=p.fields.length;d<h;d++)typeof(s=p.fields[d])===m?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,u=a;let n=typeof s.field===m?s.field:a;s.nullable&&!s.defaultValue||"function"==typeof(c=p.defaults[u!==n?u:n]=s.defaultValue!==t?s.defaultValue:ee[l.toLowerCase()])&&v.push(n),r.id===n&&(p._defaultId=c),p.defaults[u!==n?u: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 u(e)?e:z(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}}};var ie=i({},ne,{asc:function(e){var t=this.selector(e);return function(e,n){var i=t(e);var 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);var 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===m){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===m?{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){var r=typeof e===m?{field:e,dir:n}:e,o=a(r)?r:r!==t?[r]:[];for(var 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 W(e)}(e);var i,r,o,a,s,l,c=[],d=[],u=[],p=e.filters;for(i=0,r=p.length;i<r;i++)s=(o=p[i]).field,l=o.operator,o.filters?(o=(a=oe.filterExpr(o)).expression.replace(/__o\[(\d+)\]/g,(function(e,t){return t=+t,"__o["+(u.length+t)+"]"})).replace(/__f\[(\d+)\]/g,(function(e,t){return t=+t,"__f["+(d.length+t)+"]"})),u.push.apply(u,a.operators),d.push.apply(d,a.fields)):(typeof s===g?(a="__f["+d.length+"](d)",d.push(s)):a=h.expr(s),typeof l===g?(o="__o["+u.length+"]("+a+", "+re.quote(o.value)+")",u.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:u}};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===m&&(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 he(e,t){return!e.logic&&!t.logic&&(e.field===t.field&&e.value===t.value&&e.operator===t.operator)}function ue(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===m?{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){var i=fe(e,t,n);for(var 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=ue(t),n=ue(n),t.logic!==n.logic)return!1;var i,r;var o=(t.filters||[]).slice();var 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(!he(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);var 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;var 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(!U){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&&u(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)||we(e)||(e=i),e<i&&(be(i)||we(i))&&(e=i),e},min:function(e,t,n){var i=n.get(t);return be(e)||we(e)||(e=i),e>i&&(be(i)||we(i))&&(e=i),e}};function be(e){return"number"==typeof e&&!isNaN(e)}function we(e){return e&&e.getTime}function ye(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=(r=r||{}).group;var c=function(e){var t=a(e)?e:[e];for(var n=0;n<t.length;n++)if(t[n]&&u(t[n].compare))return!0;return!1}(fe(l||[]));var d,h,p=new oe(e),f=me(l||[]),m=ae(r.sort||[]),g=c?m:f.concat(m),v=r.filterCallback,_=r.filter,b=r.skip,w=r.take;return g&&s&&(p=p.sort(g,t,t,s)),_&&(p=p.filter(_),v&&(p=v(p)),h=p.toArray().length),g&&(s||(p=p.sort(g)),l&&(e=p.toArray())),c?(p=p.group(l,e,r),b===t||w===t||r.groupPaging||(p=new oe(Le(p.toArray())).range(b,w),d=n(f,(function(e){return i({},e,{skipItemSorting:!0})})),p=p.group(d,e,r))):(b!==t&&w!==t&&(b+w>(h=p.data.length)&&r.virtual&&(b=(b-=b+w-h)<0?0:b),p=p.range(b,w)),!l||o(l)&&0===l.length||(p=p.group(l,e,r))),{total:h,data:p.toArray()}};var ke=f.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)}});var xe=f.extend({init:function(e){var t,n=this;e=n.options=i({},n.options,e),c(E,(function(t,n){typeof e[n]===m&&(e[n]={url:e[n]})})),n.cache=e.cache?Se.create(e.cache):{find:d,add:d},t=e.parameterMap,e.submit&&(n.submit=e.submit),u(e.push)&&(n.push=e.push),n.push||(n.push=I),n.parameterMap=u(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:I},create:function(e){return l(this.setup(e,v))},read:function(n){var i,r,o=this.cache;n=this.setup(n,_),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,b))},destroy:function(e){return l(this.setup(e,w))},setup:function(e,t){e=e||{};var n,r=this.options[t],o=u(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),u(e.url)&&(e.url=e.url(n)),e}});var Ce=f.extend({init:function(e){const t=this;e=t.options=i({},t.options,e),t.messageTypes={ai:"assistant",system:"system",user:"user",tool:"tool"}},read:function(t){const n=this;t=n.setup(t),n.options.requestStart&&n.options.requestStart(t),e.ajax(t)},success:function(e,t){const n=this;const i=t?.service||n.options.service;const r=i?.outputGetter||n._getResponseData;const o=t?.isRetry;const a=t?.prompt;const s={id:h.guid(),output:r(e),prompt:a,isRetry:o,response:e};n.options.success&&n.options.success(s)},error:function(e,t){const n=this;const i=t?.service||n.options.service;const r=i?.outputGetter||n._getResponseData;const o=t?.isRetry;const a=t?.prompt;const s={status:e.status,statusText:e.statusText,responseText:e.responseText};const l={id:h.guid(),output:r(s),prompt:a,isRetry:o,response:e};n.options.error&&n.options.error(l)},setup:function(e={}){const t=this;const n=e?.service||t.options.service;const i=t.getData(e);const r={url:"string"==typeof n?n:n.url,type:"POST",contentType:"application/json",data:JSON.stringify(i),success:function(n){t.success.call(t,n,e)},error:function(n){t.error.call(t,n,e)}};return n?.headers&&(r.headers=n.headers),r},getData:function(t){const n=t?.service;const i=t?.isRetry;const r=t?.history||[];const o=t?.prompt;let a=[...r,{role:this.messageTypes.user,contents:[{$type:"text",text:o}]}];return n?.data&&u(n?.data)?n.data(o,i,r):n?.data&&Object.keys(n.data).length?e.extend({},n.data,{messages:a}):a},_getResponseData:function(e){return e?.messages?.[0]?.contents?.[0]?.text||"An error occurred while processing the request."}});var Se=f.extend({init:function(){this._store={}},add:function(e,n){e!==t&&(this._store[P(e)]=n)},find:function(e){return this._store[P(e)]},clear:function(){this._store={}},remove:function(e){delete this._store[P(e)]}});function Te(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 Me(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 Ae(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?Ae(o.items,t,n,i,r):Me(o.items,t,n,0,r))}function De(e,t,n,i,r,o){return function(a){return a=e(a),Ee(t,n,i,r,o)(a)}}function Ee(e,t,n,i,r){return function(a){return a&&!o(n)&&("[object Array]"===$.call(a)||a instanceof G||(a=[a]),t(a,n,new e,i,r)),a||[]}}Se.create=function(e){var t={inmemory:function(){return new Se}};return r(e)&&u(e.find)?e:!0===e?new Se:t[e]()};var Ie=f.extend({init:function(e){var t,n,i,o,a=this;for(t in e=e||{})n=e[t],a[t]=typeof n===m?z(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,h=a.groups.bind(a),u=a.serialize.bind(a),p={},f={},g={},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===m&&(l=t),r(t)&&t.from&&(n=t.from),_=_||n&&n!==e||l!==e,d=n||l,f[e]=-1!==d.indexOf(".")?z(d,!0):z(d),g[e]=z(e),p[n||l]=e,v[e]=n||l})),!e.serialize&&_&&(a.serialize=De(u,i,Te,g,p,v))),a._dataAccessFunction=s,a._wrapDataAccessBase=Ee(i,Me,f,p,v),a.data=De(s,i,Me,f,p,v),a.groups=De(h,i,Ae,f,p,v)}},errors:function(e){return e?e.errors:null},parse:I,data:I,total:function(e){return e.length},groups:I,aggregates:function(){return{}},serialize:function(e){return e}});function ze(e,t){var n;var 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?ze(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 Pe(e,t,n,i){var r,o,a=0;for(;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?Pe(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?(Pe(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 Le(e,t){var n=[];var i=(e||[]).length;var r;var o;var a=u(t)?t:function(e,t){return e[t]};for(var s=0;s<i;s++)if((r=a(e,s)).hasSubgroups)n=n.concat(Le(r.items));else{o=r.items;for(var l=0;l<o.length;l++)n.push(a(o,l))}return n}function Be(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(Be(a.items));else for(i=a.items,r=0;r<i.length;r++)o.push(i.at(r))}return o}function He(e,t){var n,i,r;if(t)for(n=0,i=e.length;n<i;n++)(r=e.at(n)).items&&(r.hasSubgroups?He(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 Fe(e,t,n,i){for(var r=0;r<e.length&&e[r].data!==t&&!Oe(e[r].data,n,i);r++);}function Oe(e,t,n){for(var i=0,r=e.length;i<r;i++){if(e[i]&&e[i].hasSubgroups)return Oe(e[i].items,t,n);if(e[i]===t||e[i]===n)return e[i]=n,!0}}function Ve(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),Fe(i,n,l,e[a]);break}}else Ve(l.items,n,i,r,o)}}function Ne(e,t){return t?Ue(e,(function(e){return e.uid&&e.uid==t.uid||e[t.idField]===t.id&&t.id!==t._defaultId})):-1}function $e(e,t){return t?Ue(e,(function(e){return e.uid==t.uid})):-1}function Ue(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 We(e,t){if(e&&!o(e)){var n=e[t];var i;return i=r(n)?n.from||n.field||t:e[t]||t,u(i)?t:i}return t}function je(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]=je(e.filters[n],t);else r.field=We(t.fields,r.field);return r}function qe(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=We(t.fields,r.field),r.aggregates&&a(r.aggregates)&&(r.aggregates=qe(r.aggregates,t)),s.push(r)}return s}var Ge=p.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,p.fn.init.call(r),r.transport=Ke.create(e,n,r),u(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,P(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",C,y,S,k,M,T],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 Be(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 $e(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;Ve(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?Be(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=[];var o=this.options.autoSync;this.options.autoSync=!1;try{for(var s=0;s<n.length;s++){var l=n[s];var 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]);var t=[];for(var n=0;n<e.length;n++){var i=e[n];var r=this._createNewModel(i);var o=this.get(r.id);o?(t.push(o),o.accept(i),o.trigger(y),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;var i=[];var r=this.options.autoSync;this.options.autoSync=!1;try{for(var o=0;o<e.length;o++){var s=e[o];var l=this._createNewModel(s);var c=!1;var d=o;this._eachItem(this._data,(function(t){d!==e.length-1?(t.omitChangeEvent=!0,t.omitCache=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=[];var 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=e.length;var i;var r;for(r=0;r<n;r++)if((i=e[r]).uid&&i.uid==t.uid)return e.splice(r,1),i}}(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,n=this,i=[],r=[];n._destroyed=n._destroyed.filter((e=>!e.hasOwnProperty("_isMoved"))),t=n._destroyed;var o=e.Deferred().resolve().promise();if(n.online()){if(!n.reader.model)return o;i=n.created(),r=n.updated();var a=[];n.options.batch&&n.transport.submit?a=n._sendSubmit(i,r,t):(a.push.apply(a,n._send("create",i)),a.push.apply(a,n._send("update",r)),a.push.apply(a,n._send("destroy",t))),o=e.when.apply(null,a).then((function(){var e,t,i=[];for(e=0,t=arguments.length;e<t;e++)arguments[e]&&(n._accept(arguments[e]),i.push(...arguments[e].models));n._storeData(!0),n._syncEnd(),n._change({action:"sync",changedItems:i}),n.trigger(k),n._isServerGroupPaged()&&n.read(),n.data().map((function(e){return e.hasOwnProperty("_isMoved")&&delete e._isMoved,e}))}))}else n._storeData(!0),n._syncEnd(),n._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,h=t.type;if(i.trigger(M,{response:s,type:h}),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"===h&&(i._destroyed=[]),l=0,n=r.length;l<n;l++)"destroy"!==h?(r[l].accept(s[l]),"create"===h?d.push(c?i._wrapInEmptyGroup(r[l].toJSON()):s[l]):"update"===h&&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=Ne(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;var n=t.options;var 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=Ne(i,e))>-1)return t=i[n],!0})),t},_cancelModel:function(e){var t=this;var n=this._pristineForModel(e);this._eachItem(this._data,(function(i){var r=$e(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(S,{type:"submit"}),r.trigger(T),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(ye(t)),updated:r.reader.serialize(ye(n)),destroyed:r.reader.serialize(ye(i))}})),o},_promise:function(t,n,r){var o=this;return e.Deferred((function(e){o.trigger(S,{type:r}),o.trigger(T),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(ye(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);var r=e.Deferred();return n._queueRequest(i,(function(){var e=n.trigger(S,{type:"read"});e?(n._dequeueRequest(),r.resolve(e)):(n.trigger(T),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=V.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(M,{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={};var a=i.reader.model;var s=a?a.idField:"id";var l;for(l=0;l<this._destroyed.length;l++){var c=this._destroyed[l][s];o[c]=c}for(l=0;l<e.length;l++){var d=e[l];"destroy"==d.__state__?o[d[s]]||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 h.isBlank(e)&&(e=[]),i._pristineData=e.slice(0);if(i._detachObservableParents(),i.options.endless){i._data.unbind(y,i._changeHandler),i._isServerGrouped()&&i._data[i._data.length-1].value===e[0].value&&(ze(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 p=0;p<e.length;p++)i._data.push(e[p]);i._data.bind(y,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();var n=this.reader.model;if(null!=this.options.offlineStorage){var i=function e(i){var r=[];for(var o=0;o<i.length;o++){var a=i.at(o);var 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);var r=[];for(var 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){var t=e.length;for(var n=0;n<t;n++)this._groupsFlat.push(e[n])},_getGroupByUid:function(e){var t=this._groupsFlat.length;var n;for(var i=0;i<t;i++)if((n=this._groupsFlat[i]).uid===e)return n},_sortRanges:function(){this._ranges.sort((function(e,t){return e.start-t.start}))},error:function(e,t,n){this._dequeueRequest(),this.trigger(M,{}),this.trigger(C,{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=qe(n.group,t.reader.model)):delete n.group,t.options.serverFiltering?t.reader.model&&n.filter&&(n.filter=je(n.filter,t.reader.model)):delete n.filter,t.options.serverSorting?t.reader.model&&n.sort&&(n.sort=qe(n.sort,t.reader.model)):delete n.sort,t.options.serverAggregates?t.reader.model&&n.aggregate&&(n.aggregate=qe(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(C,{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()&&He(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(y,t._changeHandler),e.bind(y,t._changeHandler)},_updateTotalForAction:function(e,t){var n=this;var 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=P(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=Be(s)),s.find((function(e){return e.uid===a.uid}))||!a.index&&null!==a.id||(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(y,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||F.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=this;var r;return n!==t&&(i._pageSize=n.pageSize,i._page=n.page,i._sort=n.sort,i._filter=n.filter,i._group=n.group,i._aggregate=n.aggregate,i._skip=i._currentRangeStart=n.skip,i._take=n.take,i._skip===t&&(i._skip=i._currentRangeStart=i.skip(),n.skip=i.skip()),i._take===t&&i._pageSize!==t&&(i._take=i._pageSize,n.take=i._take),i.options.virtual&&(n.virtual=i.options.virtual),n.sort&&(i._sort=n.sort=ae(n.sort),i._sortFields=se(n.sort)),n.filter&&(i._filter=n.filter=i.options.accentFoldingFiltering&&!e.isEmptyObject(n.filter)?e.extend({},de(n.filter),{accentFoldingFiltering:i.options.accentFoldingFiltering}):de(n.filter)),n.group&&(i._group=n.group=fe(n.group)),n.aggregate&&(i._aggregate=n.aggregate=(r=n.aggregate,a(r)?r:[r]))),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(S,{type:"read"});return o||(this.trigger(T),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(M,{type:"read"}),this.trigger(y,{items:i.data,action:n?n.action:""})),e.Deferred().resolve(o).promise()},_hasExpandedSubGroups:function(e){var t=!1;var 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){var o=this;var a=e.length;var s;var l;var c;var d;var h;for(var u=0;u<a&&(s=e[u],!(n.taken>=n.take));u++)if(o._getGroupByUid(s.uid)||o._groupsFlat.push(s),o._groupsState[s.uid]){if(o._isServerGroupPaged()){if(o._fetchGroupItems(s,n,i,r))return void(o._fetchingGroupItems=!0);if(d=(s.subgroupCount||s.itemCount)+1,h=n.skip-n.skipped,!o._hasExpandedSubGroups(s)&&h>d){n.skipped+=d;continue}}if(n.includeParents&&n.skipped<n.skip?(n.skipped++,s.excludeHeader=!0):n.includeParents&&(n.taken++,s.excludeHeader=!1),s.hasSubgroups&&s.items&&s.items.length)s.currentItems=[],i||(i=[]),i.push(s),o._findGroupedRange(s.items,s.currentItems,n,i,r),i.pop(),s.currentItems.length||n.taken>0?t.push(s):s.excludeHeader=!1;else{l=[],c=s.items.length;for(var p=0;p<c;p++)if(n.skipped<n.skip)n.skipped++;else{if(n.taken>=n.take)break;l.push(s.items[p]),n.taken++}l.length||n.taken>0?(s.currentItems=l,t.push(s)):s.excludeHeader=!1}}else{if(n.skipped<n.skip){n.skipped++;continue}t.push(s),n.taken++}},_expandedSubGroupItemsCount:function(e,t,n){var i=this;var r=0;var o;var a="number"==typeof t;var s=a?t:e.subgroupCount;var l;if(!e.hasSubgroups)return r;for(var c=0;c<s&&(o=e.items[c]);c++)if(o.hasSubgroups&&i._groupsState[e.uid]?(r+=l=i._expandedSubGroupItemsCount(o,s,!0),a&&(s-=l)):!o.hasSubgroups&&i._groupsState[o.uid]&&(r+=l=o.items?o.items.length:0,a&&(s-=l)),n&&(r+=1,a&&(s-=1)),a&&r>s)return r;return r},_fetchGroupItems:function(e,t,n,i){let r=this;let o;let a;let s;let l=e.hasSubgroups?e.subgroupCount:e.itemCount;let c=t.take;let d=t.skipped;let h=r.take();let u;if(t.includeParents&&(d<t.skip?d+=1:c-=1),!e.items||e.items&&!e.items.length)return r.getGroupItems(e,t,n,i,0),!0;{if(u=this._expandedSubGroupItemsCount(e,t.skip-d),o=Math.max(t.skip-(d+u),0),o>=l)return!1;let p=Math.min(o+c,l-1);if(a=e.items[o],s=e.items[p],a.notFetched)return r.getGroupItems(e,t,n,i,o,L.round((o+h)/h)),!0;if(s.notFetched)return r.getGroupItems(e,t,n,i,L.max(L.floor((o+h)/h),0)*h,L.round((o+h)/h)),!0;if(!a.notFetched&&!s.notFetched&&function(e,t,n){for(let i=t;i<n;i++)if(e[i].notFetched)return!0;return!1}(e.items,o,p))return r.getGroupItems(e,t,n,i,o,p),!0}},getGroupItems:function(e,t,n,i,r,o){var a=this;var s;var l;var c;var d;e.items||(e.items=[]),s=a.take(),l=this._composeItemsFilter(e,n),c={page:o||1,pageSize:s,skip:r,take:s,filter:l,aggregate:a._aggregate,sort:a._sort},(d=a.findSubgroups(e))&&d.length&&(c.group=d),c.groupPaging=!0,a._queueWithTimeout(c,(function(){a.trigger(S,{type:"read"})?a._dequeueRequest():a.transport.read({data:c,success:a._groupItemsSuccessHandler(e,t.skip,a.take(),i,r),error:function(){var e=V.call(arguments);a.error.apply(a,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;var a=o._timeStamp();i=u(i)?i:d;var s=o.options.schema&&o.options.schema.total?o.options.schema.total:"Total";return function(l){var c;var d=te.define(o.options.schema.model);var h;o._dequeueRequest(),o.trigger(M,{response:l,type:"read"}),h=u(s)?s(l):l[s],l=o.reader.parse(l),e.hasSubgroups?(c=o.reader.groups(l),e.subgroupCount=h):c=(c=o.reader.data(l)).map((function(e){return new d(e)})),e.items.omitChangeEvent=!0;for(var p=0;p<h;p++)p>=r&&p<r+n?e.items.splice(p,1,c[p-r]):e.items[p]||e.items.splice(p,0,{notFetched:!0});e.items.omitChangeEvent=!1,o._updateRangePristineData(e),o._fetchingGroupItems=!1,e.countAdded||(o._serverGroupsTotal+=h,e.countAdded=!0),o.range(t,n,i,"expandGroup"),(a>=o._currentRequestTimeStamp||!o._skipRequestsInProgress)&&o.trigger(y,{})}},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){var t=this;var n=t._ranges;var i=n.length;var r;var o;var a;var s;var l;for(var c=0;c<i;c++){s=(a=n[c]).data.length,l=[],r=null;for(var d=0;d<s&&(o=a.data[d],l.push(d),!(o.uid===e.uid||o.hasSubgroups&&o.items.length&&t._containsSubGroup(o,e,l)));d++)l.pop();if(l.length){for(r=n[c].pristineData;l.length>1;)r=r[l.splice(0,1)[0]].items;r[l[0]]=t._cloneGroup(e);break}}},_containsSubGroup:function(e,t,n){var i=e.items.length;var r;if(e.hasSubgroups&&i)for(var o=0;o<i;o++){if(r=e.items[o],n.push(o),r.uid===t.uid||r.hasSubgroups&&r.items.length&&this._containsSubGroup(r,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&&u(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=L.max(L.min(L.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?L.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;var i={group:e};if(n._groupPaging&&(e===t||e&&e.length||(n._ranges=[]),i.page=1),e===t)return n._group;n._query(i)},parseHighlightDescriptors:function(e,n){const r=this._data?this._flatData(this._data):[];if(!e||!e.length||!r.length)return[];const o=function(e,n,r){var o=function(e,n){const i=!(n.cells&&Object.keys(n.cells).length>0)||n.cells;const o={};let a,s;for(a=0,s=e.length;a<s;a++){const n=e[a];n&&n.uid!==t&&(o[String(n[r])]=i)}return o};let s={};let l,c,d,h,u;if(!a(n))return s;for(l=0,c=n.length;l<c;l++)d=n[l],d&&(h=new oe(e).filter(d).toArray(),u=o(h,d),u&&(s=i(!0,s,u)));return s}(r,e,n||"id");return o},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=this;var o;var a;if(n=n||"items",r._group.length&&e){o=0,a=e.length;for(var s=0;s<a;s++)o+=r.groupCount(e[s],t,n,i);return r._groupsTotal=o,o}return r._groupsTotal=r._data.length,r._groupsTotal},groupCount:function(e,t,n,i){var r=this;var 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){var t=0;var n=e.length;for(var 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 L.ceil((n||0)/t)},inRange:function(e,t){var n=this,i=L.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=L.min(e||0,o),i=u(i)?i:d;var a,s=this,l=L.max(L.floor(e/n),0)*n,c=L.min(l+n,o);if(((a=s._findRange(e,L.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=L.max(L.floor(s._adjustPageSkip(e,n)/n),0)*n,c=L.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,L.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,h,u,p,f,m,g=this,v=g._ranges,_=[],b=g.options,w=b.serverSorting||b.serverPaging||b.serverFiltering||b.serverGrouping||b.serverAggregates,y={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){y.skipped+=r.outerEnd-(m||0),m=r.outerEnd;continue}if(void 0!==m&&m!=r.outerStart&&(y.skipped+=r.outerStart-m),y.skipped>y.skip)return[];for(void 0===m&&e>0&&r.start>0&&(y.skipped=r.outerStart),a=o;;){if(this._findGroupedRange(r.data,_,y,null,i),g._calculateGroupsTotal(_,!0,"currentItems")>=y.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],(u=g._flatData(r.data,!0)).length&&e+p>=r.start){if(c=r.data,d=r.end,!w){if(b.inPlaceSort)h=g._queryProcess(r.data,{filter:g.filter()});else{var S=me(g.group()||[]).concat(ae(g.sort()||[]));h=g._queryProcess(r.data,{sort:S,filter:g.filter()})}u=c=h.data,h.total!==t&&(d=h.total)}if(s=0,e+p>r.start&&(s=e+p-r.start),l=u.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){var t=this._ranges;var n=0;var i=0;for(;;){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]),Pe(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?L.min(o,(s.totalPages()-1)*s.take()):r,s._currentRangeStart=n,s._take=i;var l=s.options.serverPaging;var c=s.options.serverSorting;var d=s.options.serverFiltering;var h=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=h}},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;var o=r._timeStamp();return function(a){var s,l,c,d=!1,h={start:e,end:t,data:[],timestamp:r._timeStamp()};if(r._dequeueRequest(),r.trigger(M,{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,h=r._ranges[s],r._isGroupPaged()||(h.pristineData=c,h.data=r._observe(c),h.end=h.start+r._flatData(h.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(y,{}))}},prefetch:function(e,t,n){var i=this,r=L.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(S,{type:"read"})?i._dequeueRequest():(i._omitPrefetch&&i.trigger(T),i.transport.read({data:i._params(o),success:i._prefetchSuccessHandler(e,r,n),error:function(){var e=V.call(arguments);i.error.apply(i,e)}}))}),100):n&&n()},_multiplePrefetch:function(e,t,n){var i=this,r=L.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(S,{type:"read"})||i.transport.read({data:i._params(o),success:i._prefetchSuccessHandler(e,r,n,!0)})},_adjustPageSkip:function(e,t){var n=this;var i=n._getPrevRange(e);var r;var o=n.total();var a;if(i){if(!(a=n._getRangesMismatch(e)))return e;e-=a}if((r=L.max(L.floor(e/t),0)*t)>o)for(;!((r-=t)<o););return r},_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=this;var t=e._ranges;var n=e.currentRangeStart();var i=n+(e.take()||0);var r=[];var o;var a;var s=t.length;for(a=0;a<s;a++)((o=t[a]).start<=n&&o.end>=n||o.start>=n&&o.start<=i)&&r.push(o);return r},_removeModelFromRanges:function(e){var t;for(var 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=this;var i=n._ranges||[];var r=i.length;var o;var a;for(a=0;a<r;a++)if((o=i[a]).start<=e&&o.end>=e){n._getByUid(t.uid,o.data)||(n._isServerGrouped()?o.data.splice(e,0,n._wrapInEmptyGroup(t)):o.data.splice(e,0,t));break}n._updateRangesLength()},_updateRangesLength:function(){var e=this;var t=e._ranges||[];var n=t.length;var i=!1;var r=0;var o=0;var a;var s;for(s=0;s<n;s++)a=t[s],o=(e._isGroupPaged()?a.data.length:e._flatData(a.data,!0).length)-L.abs(a.end-a.start),i||0===o?i&&(a.start+=r,a.end+=r):(i=!0,r=o,a.end+=r)},_updateOuterRangesLength:function(){var e=this;var t=e._ranges||[];var n=t.length;var i=0;var r;var o;var a;var s;for(o=0;o<n;o++)r=t[o],s=e._isGroupPaged()?e._calculateGroupsTotal(r.data,!0,"items",!0):e._flatData(r.data,!0).length,a?(a.end!=r.start&&(i=r.start-a.end),r.outerStart=a.outerEnd+i,i=0):r.outerStart=r.start,r.outerEnd=r.outerStart+s,a=r},isLocalTransport:function(){return this.transport instanceof ke},isRemoteTransport:function(){return this.transport instanceof xe}});var Ke={};Ke.create=function(t,n,o){var a,s=t.transport?e.extend({},t.transport):null;return s?(s.read=typeof s.read===m?{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=u(s.read)?s:new xe(s))):a=new ke({data:t.data||[]}),a},Ge.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],h=d?d.rows:[],u=n.length,p=[];for(i=0,r=h.length;i<r;i++){for(s={},c=!0,a=h[i].cells,o=0;o<u;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=t.options;var r=n[0];var o=n[1];var a=[];var s,l;var c;var d;var h;var u;for(s=0,l=i.length;s<l;s++)h={},(c=(d=i[s]).parentNode)===t&&(c=null),d.disabled||c&&c.disabled||(c&&(h.optgroup=c.label),h[r.field]=d.text,u=(u=d.attributes.value)&&u.specified?d.value:d.text,h[o.field]=u,a.push(h));return a}(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 Ge?c:new Ge(c)};var Ye=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===m&&(r=t.children),o={schema:{data:r,model:{hasChildren:n,id:t.idField,fields:t.fields}}},typeof t.children!==m&&i(o,t.children),o.data=e,n||(n=o.schema.data),typeof n===m&&(n=h.getter(n)),u(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=this;var t,n,i;e.children instanceof Xe||(n=(t=e.children=new Xe(e._childrenOptions)).transport,i=n.parameterMap,n.parameterMap=function(t,n){return t[e.idField||"id"]=e.id,i&&(t=i.call(e,t,n)),t},t.parent=function(){return e},t.bind(y,(function(t){t.node=t.node||e,e.trigger(y,t)})),t.bind(C,(function(t){var n=e.parent();n&&(t.node=t.node||e,n.trigger(C,t))})),t.bind(A,(function(t){var n=e.parent();n&&n.trigger(A,t)})),e._updateChildrenField())},append:function(e){this._initChildren(),this.loaded(!0),this.children.add(e)},hasChildren:!1,level:function(){var e=this.parentNode(),t=0;for(;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={};var i="_query";var r,o;return this.hasChildren?(this._initChildren(),r=this.children,n[this.idField||"id"]=this.id,this._loaded||(r._data=t,i="read"),r.one(y,this._childrenLoaded.bind(this)),this._matchFilter&&(n.filter={field:"_matchFilter",operator:"eq",value:!0}),o=r[i](n),this._loaded||this.trigger(D,{promise:o,node:this})):this.loaded(!0),o||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 Qe(e){return function(){var t=this._data,n=Ge.fn[e].apply(this,V.call(arguments));return this._data!=t&&this._attachBubbleHandlers(),n}}var Xe=Ge.extend({init:function(e){var t=Ye.define({children:e});e.filter&&!e.serverFiltering&&(this._hierarchicalFilter=e.filter,e.filter=null),Ge.fn.init.call(this,i(!0,{},{schema:{modelBase:t,model:t}},e)),this._attachBubbleHandlers()},_attachBubbleHandlers:function(){var e=this;e._data.bind(C,(function(t){e.trigger(C,t)})),e._data.bind(A,(function(t){e.trigger(A,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=Ge.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=Ge.fn.remove.call(i,e),n&&!i.data().length&&(n.hasChildren=!1),t},success:Qe("success"),data:Qe("data"),insert:function(e,t){var n=this.parent();return n&&n._initChildren&&(n.hasChildren=!0,n._initChildren()),Ge.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;var 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){var t;var n=this._data;var i=!1;for(var 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;var a=this._data;if(a){if(r=Ge.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 Xe&&(r=o[e](t)))return r}},get:function(e){return this._find("get",e)},getByUid:function(e){return this._find("getByUid",e)}});function Ze(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=Ze(t.eq(0),n)),"true"==a.attr("data-hasChildren")&&(o.hasChildren=!0),p.push(o);return p}Xe.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=Ze(r,i)),t.data=n,t instanceof Xe?t:new Xe(t))};var Je=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=L.max(L.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=L.max(L.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}});var et=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 Je(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:Ie},Query:oe,DataSource:Ge,HierarchicalDataSource:Xe,Node:Ye,Comparer:ne,ObservableObject:X,ObservableArray:G,LazyObservableArray:K,LocalTransport:ke,RemoteTransport:xe,AiTransport:Ce,Cache:Se,DataReader:Ie,Model:te,Buffer:Je,BatchBuffer:et})}(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",h="source",u="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;var 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;var 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()}});var 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)}});var _=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}});var 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(){}});var w=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 y(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){D(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],h=n.data.HierarchicalDataSource;if(!(h&&d instanceof h)&&c.length)for(a=e.addedDataItems||d.flatView(),s=this.bindings[t]._parents(),r=0,o=a.length;r<o;r++)c[r]&&D(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&&(o instanceof n.data.DataSource?c[r](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(L(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();var 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=w.extend({init:function(t,n,i){w.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);const 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),D(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++)D(l.children[i],o[i],this.options.roles,[o[i]].concat(t))}else e(l).html(n.render(c,o))}}),l.input={checked:w.extend({init:function(t,n,i){w.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;var t=this.value();if("radio"==e.type)t=this.parsedValue(),this.bindings[p].set(t);else if("checkbox"==e.type){var n=this.bindings[p].get();var i;if(n instanceof a){if((t=this.parsedValue())instanceof Date){for(var r=0;r<n.length;r++)if(n[r]instanceof Date&&+n[r]==+t){i=r;break}}else i=n.indexOf(t);i>-1?n.splice(i,1):n.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=L(r.bindings.value.get(),e(r.element).data("valueField"));null===s?r.element.selectedIndex=-1:r.element.value=s}}else r.render()}}),value:w.extend({init:function(t,n,i){w.fn.init.call(this,t,n,i),this._change=this.change.bind(this),e(this.element).change(this._change)},parsedValue:function(){var e=this.dataType();var t=[];var n,i,r,o;for(r=0,o=this.element.options.length;r<o;r++)(i=this.element.options[r]).selected&&(n=(n=i.attributes.value)&&n.specified?i.value:i.text,t.push(this._parseValue(n,e)));return t},change:function(){var e,i,r,s,l,c,h=[],u=this.element,p=this.options.valueField||this.options.textField,f=this.options.valuePrimitive;for(l=0,c=u.options.length;l<c;l++)(i=u.options[l]).selected&&(s=(s=i.attributes.value)&&s.specified?i.value:i.text,p?h.push(s):h.push(this._parseValue(s,this.dataType())));if(p)for((e=this.bindings.source.get())instanceof n.data.DataSource&&(e=e.view()),r=0;r<h.length;r++)for(l=0,c=e.length;l<c;l++){var m=e[l].get(p);if(String(m)===h[r]){h[r]=e[l];break}}(s=this.bindings[d].get())instanceof a?s.splice.apply(s,[0,s.length].concat(h)):f||!(s instanceof o||null===s||s===t)&&p?this.bindings[d].set(h[0].get(p)):this.bindings[d].set(h[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,h=this.dataType();l instanceof a||(l=new a([s])),i.selectedIndex=-1;for(var u=0;u<l.length;u++)for(s=l[u],c&&s instanceof o&&(s=s.get(c)),"date"==h?s=n.toString(l[u],"yyyy-MM-dd"):"datetime-local"==h&&(s=n.toString(l[u],"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();var 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();var 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:y("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),h=this._valueIsObservableObject,u=[];if(this._initChange=!0,c)if(""===l&&(h||this.options.valuePrimitive))l=null;else{for(a=this._source(),d&&(t=l.length,u=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==u[e]){u[e]=n;break}}else if(i==l){l=h?n:i;break}u[0]&&(l=this._valueIsObservableArray?u:h||!c?u[0]:u[0].get(c))}this.bindings.value.set(l),this._initChange=!1},refresh:function(){if(!this._initChange){var e=this.widget;var n=e.options;var i=n.dataTextField;var r=n.dataValueField||i;var s=this.bindings.value.get();var l=n.text||"";var c,d=0;var h=[];if(s===t&&(s=null),r)if(s instanceof a){for(c=s.length;d<c;d++)h[d]=s[d].get(r);s=h}else s instanceof o&&(l=s.get(i),s=s.get(r));!1!==n.autoBind||n.cascadeFrom||!e.listView||e.listView.bound()?"Upload"!=e.options.name&&e.value(s):(i!==r||l||(l=s),l||!s&&0!==s||!n.valuePrimitive?e._preselect(s,l):e.value(s))}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;var l=this.options.dataValueField||this.options.dataTextField;if(s=s.slice?s.slice(0):s,e._initChange=!0,n instanceof a){var c=[];var h=s.length;var u=0,p=0;var f=n[u];var m;var g;var v;for(;f!==t;){for(v=!1,p=0;p<h;p++)if(i?s[p]==f:(g=(g=s[p]).get?g.get(l):g)==(f.get?f.get(l):f)){s.splice(p,1),h-=1,v=!0;break}v?u+=1:(c.push(f),k(n,u,1),m=u),f=n[u]}k(n,n.length,0,s),c.length&&n.trigger("change",{action:"remove",items:c,index:m}),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:y("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();var o=this.options.dataValueField||this.options.dataTextField;if(r=r.slice(0),e._initChange=!0,n instanceof a){var s=[];var l=r.length;var c=0,h=0;var u=n[c];var p;var f;var m;for(;u!==t;){for(m=!1,h=0;h<l;h++)if(i?r[h]==u:(f=(f=r[h]).get?f.get(o):f)==(u.get?u.get(o):u)){r.splice(h,1),l-=1,m=!0;break}m?c+=1:(s.push(u),k(n,c,1),p=c),u=n[c]}k(n,n.length,0,r),s.length&&n.trigger("change",{action:"remove",items:s,index:p}),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,h=[];if(l===t&&(l=null),s)if(l instanceof a){for(e=l.length;d<e;d++)n=l[d],h[d]=n.get?n.get(s):n;l=h}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:y("source","dataSource","setDataSource").extend({dataBound:function(e){var t;var n;var i=this.widget;var r=e.addedItems||i.items();var o,a;if(r.length)for(o=e.addedDataItems||i.dataItems(),a=this.bindings.source._parents(),t=0,n=o.length;t<n;t++)D(r[t],o[t],this._ns(e.ns),[o[t]].concat(a))}})},grid:{source:y("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++)D(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=(i=i||[]).length;var o=e.length;var a=[].slice.call(e,t+n);var s=a.length;var l;if(r){for(r=t+r,l=0;t<r;t++)e[t]=i[l],l++;e.length=r}else if(n)for(e.length=t,n+=t;t<n;)delete e[--n];if(s){for(s=t+s,l=0;t<s;t++)e[t]=a[l],l++;e.length=s}for(t=e.length;t<o;)delete e[t],t++};var 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==h?i=!0:t!=u||s?t==p?o=!0:"css"==t?a=!0:this.applyBinding(t,e,l):r=!0;i&&this.applyBinding(h,e,l),n&&this.applyBinding(d,e,l),o&&this.applyBinding(p,e,l),r&&!s&&this.applyBinding(u,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()}});var 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 M(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=M(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 D(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=[],h=!0,u={};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=M(c.replace(T,"")),s||((u=n.parseOptions(e,{textField:"",valueField:"",template:"",valueUpdate:m,valuePrimitive:!1,autoBind:!0},t)).roles=i,s=new x(e,u)),s.source=t,a=A(c,r,g),u.template&&(a.template=new _(r,"",u.template)),a.click&&(c.events=c.events||{},c.events.click=c.click,a.click.destroy(),delete a.click),a.source&&(h=!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(h&&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++)D(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&&D(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 L(e,t){var n=[];var i=0;var r;var s;if(!t)return e;if(e instanceof a){for(r=e.length;i<r;i++)s=e[i],n[i]=s.get?s.get(t):s[t];e=n}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"],h=["rotate","scale","scalex","scaley","skew","skewx","skewy","translate","translatex","translatey","matrix"],u=Math.round,p="px",f="auto",m="width",g="height",v="hidden",_="origin",b="abortId",w="overflow",y="position",k="completeCallback",x="transitionend",C="transition",S="transform",T="perspective",M="1500px",A="perspective("+M+")",D={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==h.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=D,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?D[a].reverse:a),n[o[0]]=s})):i(e,(function(e){var i=this.direction;i&&t&&!c.test(e)&&(this.direction=D[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;let 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,h=t.length,u=d.element,p=d.options,f=e.Deferred(),m={},g={};for(d.effects=t,f.done(d.complete.bind(d)),u.data("animating",!0),o=0;o<h;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(u.is(":visible")||r(m,{display:u.data("olddisplay")||"block"}),p.reset||(s=u.data("targetTransform"),s&&(m=r(s,m))),m=I(0,m),u.css(m).css(S),o=0;o<h;o++)t[o].setup();return p.init&&p.init(),u.data("targetTransform",g),n.animate(u,g,r({},p,{complete:f.resolve})),f.promise()},stop:function(){e(this.element).kendoStop(!0,!0)},addRestoreProperties:function(e){var t,n=this.element,i=0,r=e.length;for(;i<r;i++)t=e[i],this.restore.push(t),n.data(t)||n.data(t,n.css(t))},restoreCallback:function(){var e=this.element;for(var 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.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[L(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==h.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(),h={},u={},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(h,u),a.is(":visible")||r(h,{display:a.data("olddisplay")||"block"}),i=a.data("targetTransform"),i&&(h=r(i,h)),h=I(0,h),a.css(h).css(S),o.setup(),a.data("targetTransform",u),n.animate(a,u,{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(){var e=this.element;for(var 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 L(e){return e.charAt(0).toUpperCase()+e.substring(1)}function B(e,t){var r=P.extend(t),o=r.prototype.directions;n[L(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+L(i)]=function(e,t,n){return new r(this.element,i,e,t,n)}}))}var H=["left","right","up","down"],R=["in","out"];function F(e,t,n,i){B(e,{directions:R,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}})}B("slideIn",{directions:H,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=D[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"}}),B("tile",{directions:H,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;var a=[t.fx(e.element).slideIn(o).setReverse(n)];return i&&a.push(t.fx(i).slideIn(D[o].reverse).divisor(r).setReverse(!n)),a}}),F("fade","opacity",1,0),F("zoom","scale",1,.01),B("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}}),B("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")}}),B("expand",{directions:["horizontal","vertical"],restore:[w],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=u(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};B("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"),h=n.fillScale(c,l),u=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=u.x+p+" "+u.y+p,i._reverse?e.scale=h:t.scale=h}});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)"};var 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)}B("turningPage",{directions:H,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?D[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}}),B("staticPage",{directions:H,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?D[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}}),B("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]=M,e.transformStyle="preserve-3d",e.opacity=.999,t.opacity=1},teardown:function(){this.element.find(".temp-page").remove()}}),B("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]=M,e.transformStyle="preserve-3d"}});var U=!o.mobileOS.android;B("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(w,""),this.isAbsolute||this._both().css(y,""),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(y);return a.length||(a=r.parent()),this.container=a,this.deferred=l,this.isAbsolute="absolute"==c,this.isAbsolute||s.css(y,"absolute"),U&&(n=a.css(w),a.css(w,"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))}});var 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=B,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",h="show",u="hide",p=/unrecognized expression/;var f="showStart";var m="sameViewRequested";var g="viewShow";var v="viewTypeDetermined";var _="after";var b="k-content",w="k-view",y="k-stretched-view",k="k-widget",x="k-footer";var 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,h,u,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(h)),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(u)},destroy:function(){var e=this;var 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;var 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(w),i.addClass(k),i.attr("role","view")},_createContent:function(){var t=e(this.wrapper);var 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(y).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)}});var 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});var 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 D(i)).bind("accepted",(function(e){e.view.render(i)})),t}});var M=C.extend({attach:function(e,t){e.element.find(t).replaceWith(this.render())},detach:function(){}});var A=/^(\w+)(:(\w+))?( (\w+))?$/;var D=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()}});var 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;var 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=D,t.Fragment=M,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){var t="string"==typeof this.nodeName?document.createElement(this.nodeName):this.nodeName;var n=this.children;for(var 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;var a=o.length;var s=t.children;var 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];var r=e[n];"style"===n?this.setStyle(i,r):i!==r&&this.setAttribute(n,i,r)}},r.prototype.setStyle=function(e,t){var n=this.node;var i;if(t)for(i in e)e[i]!==t[i]&&(n.style[i]=e[i]);else for(i in e)n.style[i]=e[i]},r.prototype.removeStyle=function(e){var t=this.attr.style||{};var 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(){var e="";for(var 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 h(e){this.root=e,this.children=[]}h.prototype={html:l,element:c,text:d,render:function(e){var t=this.children;var n;var r;for(n=0,r=e.length;n<r;n++){var o=t[n];o?o.node&&o.node.parentNode||(o.remove(),o=i):o=i,e[n].render(this.root,o)}for(n=r;n<t.length;n++)t[n].remove();this.children=e}},e.dom={html:l,text:d,element:c,Tree:h,Node:t}}(window.kendo);var q=-2;function G(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function K(e){var t=Array.prototype.slice.call(arguments,1);for(;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)G(n,i)&&(e[i]=n[i])}}return e}function Y(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)}var Q={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)}};var X={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)}};var Z=function(){var e="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;return Z=function(){return e},e};var J=function(e,t,n,i,r){return(J=Z()?Q.arraySet:X.arraySet)(e,t,n,i,r)};var ee=function(e){return(ee=Z()?Q.flattenChunks:X.flattenChunks)(e)};var te=function(e){return(te=Z()?Q.Buf8:X.Buf8)(e)};var ne=function(e){return(ne=Z()?Q.Buf16:X.Buf16)(e)};var ie=function(e){return(ie=Z()?Q.Buf32:X.Buf32)(e)};var re=function(){var e=!0;try{String.fromCharCode.apply(null,[0])}catch(t){e=!1}return re=function(){return e},e};var oe=function(){var e=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(t){e=!1}return oe=function(){return e},e};var ae=function(e){var t=te(256);for(var 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,ae=function(e){return t[e]},t[e]};function se(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 le(e,t){if(t<65534&&(e.subarray&&oe()||!e.subarray&&re()))return String.fromCharCode.apply(null,Y(e,t));var n="";for(var i=0;i<t;i++)n+=String.fromCharCode(e[i]);return n}function ce(e,t){var n,i,r,o;var a=t||e.length;var s=new Array(2*a);for(i=0,n=0;n<a;)if((r=e[n++])<128)s[i++]=r;else if((o=ae(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 le(s,i)}function de(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+ae(e[n])>t?n:t}function he(e,t,n,i){var r=65535&e,o=e>>>16&65535,a=0;for(;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 ue=function(){var e=function(){var e,t=[];for(var 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 ue=function(){return e},e};function pe(e,t,n,i){var r=ue(),o=i+n;e^=-1;for(var a=i;a<o;a++)e=e>>>8^r[255&(e^t[a])];return~e}function fe(e,t){var n;var i;var r;var o;var a;var s;var l;var c;var d;var h;var u;var p;var f;var m;var g;var v;var _;var b;var w;var y;var k;var x;var C;var 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,h=n.wnext,u=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>>>=w=b>>>24,f-=w,0===(w=b>>>16&255))T[o++]=65535&b;else{if(!(16&w)){if(64&w){if(32&w){n.mode=12;break e}e.msg="invalid literal/length code",n.mode=30;break e}b=m[(65535&b)+(p&(1<<w)-1)];continue t}for(y=65535&b,(w&=15)&&(f<w&&(p+=S[i++]<<f,f+=8),y+=p&(1<<w)-1,p>>>=w,f-=w),f<15&&(p+=S[i++]<<f,f+=8,p+=S[i++]<<f,f+=8),b=g[p&_];;){if(p>>>=w=b>>>24,f-=w,16&(w=b>>>16&255)){if(k=65535&b,f<(w&=15)&&(p+=S[i++]<<f,(f+=8)<w&&(p+=S[i++]<<f,f+=8)),(k+=p&(1<<w)-1)>l){e.msg="invalid distance too far back",n.mode=30;break e}if(p>>>=w,f-=w,k>(w=o-a)){if((w=k-w)>d&&n.sane){e.msg="invalid distance too far back",n.mode=30;break e}if(x=0,C=u,0===h){if(x+=c-w,w<y){y-=w;do{T[o++]=u[x++]}while(--w);x=o-k,C=T}}else if(h<w){if(x+=c+h-w,(w-=h)<y){y-=w;do{T[o++]=u[x++]}while(--w);if(x=0,h<y){y-=w=h;do{T[o++]=u[x++]}while(--w);x=o-k,C=T}}}else if(x+=h-w,w<y){y-=w;do{T[o++]=u[x++]}while(--w);x=o-k,C=T}for(;y>2;)T[o++]=C[x++],T[o++]=C[x++],T[o++]=C[x++],y-=3;y&&(T[o++]=C[x++],y>1&&(T[o++]=C[x++]))}else{x=o-k;do{T[o++]=T[x++],T[o++]=T[x++],T[o++]=T[x++],y-=3}while(y>2);y&&(T[o++]=T[x++],y>1&&(T[o++]=T[x++]))}break}if(64&w){e.msg="invalid distance code",n.mode=30;break e}b=g[(65535&b)+(p&(1<<w)-1)]}}break}}while(i<r&&o<s);i-=y=f>>3,p&=(1<<(f-=y<<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 me=15;var ge=[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];var ve=[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];var _e=[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];var be=[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 we(e,t,n,i,r,o,a,s){var l=s.bits;var c=0;var d=0;var h=0,u=0;var p=0;var f=0;var m=0;var g=0;var v=0;var _=0;var b;var w;var y;var k;var x;var C=null;var S=0;var T;var M=ne(16);var A=ne(16);var D=null;var E=0;var I,z,P;for(c=0;c<=me;c++)M[c]=0;for(d=0;d<i;d++)M[t[n+d]]++;for(p=l,u=me;u>=1&&0===M[u];u--);if(p>u&&(p=u),0===u)return r[o++]=20971520,r[o++]=20971520,s.bits=1,0;for(h=1;h<u&&0===M[h];h++);for(p<h&&(p=h),g=1,c=1;c<=me;c++)if(g<<=1,(g-=M[c])<0)return-1;if(g>0&&(0===e||1!==u))return-1;for(A[1]=0,c=1;c<me;c++)A[c+1]=A[c]+M[c];for(d=0;d<i;d++)0!==t[n+d]&&(a[A[t[n+d]]++]=d);if(0===e?(C=D=a,T=19):1===e?(C=ge,S-=257,D=ve,E-=257,T=256):(C=_e,D=be,T=-1),_=0,d=0,c=h,x=o,f=p,m=0,y=-1,k=(v=1<<p)-1,1===e&&v>852||2===e&&v>592)return 1;for(;;){I=c-m,a[d]<T?(z=0,P=a[d]):a[d]>T?(z=D[E+a[d]],P=C[S+a[d]]):(z=96,P=0),b=1<<c-m,h=w=1<<f;do{r[x+(_>>m)+(w-=b)]=I<<24|z<<16|P}while(0!==w);for(b=1<<c-1;_&b;)b>>=1;if(0!==b?(_&=b-1,_+=b):_=0,d++,0==--M[c]){if(c===u)break;c=t[n+a[d]]}if(c>p&&(_&k)!==y){for(0===m&&(m=p),x+=h,g=1<<(f=c-m);f+m<u&&!((g-=M[f+m])<=0);)f++,g<<=1;if(v+=1<<f,1===e&&v>852||2===e&&v>592)return 1;r[y=_&k]=p<<24|f<<16|x-o}}return 0!==_&&(r[x+_]=c-m<<24|64<<16),s.bits=p,0}var ye=-2;var ke=12;var xe=30;function Ce(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function Se(){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=ne(320),this.work=ne(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function Te(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=ie(852),t.distcode=t.distdyn=ie(592),t.sane=1,t.back=-1,0):ye}(e)):ye}function Me(e,t){var n;var i;return e?(i=new Se,e.state=i,i.window=null,n=function(e,t){var n;var 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)?ye:(null!==i.window&&i.wbits!==t&&(i.window=null),i.wrap=n,i.wbits=t,Te(e))):ye}(e,t),0!==n&&(e.state=null),n):ye}var Ae=!0;var De,Ee;function Ie(e){if(Ae){var t;for(De=ie(512),Ee=ie(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(we(1,e.lens,0,288,De,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;we(2,e.lens,0,32,Ee,0,e.work,{bits:5}),Ae=!1}e.lencode=De,e.lenbits=9,e.distcode=Ee,e.distbits=5}function ze(e,t,n,i){var r;var o=e.state;return null===o.window&&(o.wsize=1<<o.wbits,o.wnext=0,o.whave=0,o.window=te(o.wsize)),i>=o.wsize?(J(o.window,t,n-o.wsize,o.wsize,0),o.wnext=0,o.whave=o.wsize):((r=o.wsize-o.wnext)>i&&(r=i),J(o.window,t,n-i,r,o.wnext),(i-=r)?(J(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 Pe(e,t){var n;var i,r;var o;var a;var s,l;var c;var d;var h,u;var p;var f;var m;var g=0;var v,_,b;var w,y,k;var x;var C;var S=te(4);var T;var M;var A=[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 ye;(n=e.state).mode===ke&&(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,h=s,u=l,C=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,S[0]=255&c,S[1]=c>>>8&255,n.check=pe(n.check,S,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=xe;break}if(8!=(15&c)){e.msg="unknown compression method",n.mode=xe;break}if(d-=4,x=8+(15&(c>>>=4)),0===n.wbits)n.wbits=x;else if(x>n.wbits){e.msg="invalid window size",n.mode=xe;break}n.dmax=1<<x,e.adler=n.check=1,n.mode=512&c?10:ke,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=xe;break}if(57344&n.flags){e.msg="unknown header flags set",n.mode=xe;break}n.head&&(n.head.text=c>>8&1),512&n.flags&&(S[0]=255&c,S[1]=c>>>8&255,n.check=pe(n.check,S,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&&(S[0]=255&c,S[1]=c>>>8&255,S[2]=c>>>16&255,S[3]=c>>>24&255,n.check=pe(n.check,S,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&&(S[0]=255&c,S[1]=c>>>8&255,n.check=pe(n.check,S,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&&(S[0]=255&c,S[1]=c>>>8&255,n.check=pe(n.check,S,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&&(x=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),J(n.head.extra,i,o,p,x)),512&n.flags&&(n.check=pe(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{x=i[o+p++],n.head&&x&&n.length<65536&&(n.head.name+=String.fromCharCode(x))}while(x&&p<s);if(512&n.flags&&(n.check=pe(n.check,i,p,o)),s-=p,o+=p,x)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{x=i[o+p++],n.head&&x&&n.length<65536&&(n.head.comment+=String.fromCharCode(x))}while(x&&p<s);if(512&n.flags&&(n.check=pe(n.check,i,p,o)),s-=p,o+=p,x)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=xe;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=ke;break;case 10:for(;d<32;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}e.adler=n.check=Ce(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=ke;case ke: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(Ie(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=xe}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=xe;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;J(r,i,o,p,a),s-=p,o+=p,l-=p,a+=p,n.length-=p;break}n.mode=ke;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=xe;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[A[n.have++]]=7&c,c>>>=3,d-=3}for(;n.have<19;)n.lens[A[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,T={bits:n.lenbits},C=we(0,n.lens,0,19,n.lencode,0,n.work,T),n.lenbits=T.bits,C){e.msg="invalid code lengths set",n.mode=xe;break}n.have=0,n.mode=19;case 19:for(;n.have<n.nlen+n.ndist;){for(;_=(g=n.lencode[c&(1<<n.lenbits)-1])>>>16&255,b=65535&g,!((v=g>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(b<16)c>>>=v,d-=v,n.lens[n.have++]=b;else{if(16===b){for(M=v+2;d<M;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(c>>>=v,d-=v,0===n.have){e.msg="invalid bit length repeat",n.mode=xe;break}x=n.lens[n.have-1],p=3+(3&c),c>>>=2,d-=2}else if(17===b){for(M=v+3;d<M;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}d-=v,x=0,p=3+(7&(c>>>=v)),c>>>=3,d-=3}else{for(M=v+7;d<M;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}d-=v,x=0,p=11+(127&(c>>>=v)),c>>>=7,d-=7}if(n.have+p>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=xe;break}for(;p--;)n.lens[n.have++]=x}}if(n.mode===xe)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=xe;break}if(n.lenbits=9,T={bits:n.lenbits},C=we(1,n.lens,0,n.nlen,n.lencode,0,n.work,T),n.lenbits=T.bits,C){e.msg="invalid literal/lengths set",n.mode=xe;break}if(n.distbits=6,n.distcode=n.distdyn,T={bits:n.distbits},C=we(2,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,T),n.distbits=T.bits,C){e.msg="invalid distances set",n.mode=xe;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,fe(e,u),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===ke&&(n.back=-1);break}for(n.back=0;_=(g=n.lencode[c&(1<<n.lenbits)-1])>>>16&255,b=65535&g,!((v=g>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(_&&!(240&_)){for(w=v,y=_,k=b;_=(g=n.lencode[k+((c&(1<<w+y)-1)>>w)])>>>16&255,b=65535&g,!(w+(v=g>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}c>>>=w,d-=w,n.back+=w}if(c>>>=v,d-=v,n.back+=v,n.length=b,0===_){n.mode=26;break}if(32&_){n.back=-1,n.mode=ke;break}if(64&_){e.msg="invalid literal/length code",n.mode=xe;break}n.extra=15&_,n.mode=22;case 22:if(n.extra){for(M=n.extra;d<M;){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(;_=(g=n.distcode[c&(1<<n.distbits)-1])>>>16&255,b=65535&g,!((v=g>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(!(240&_)){for(w=v,y=_,k=b;_=(g=n.distcode[k+((c&(1<<w+y)-1)>>w)])>>>16&255,b=65535&g,!(w+(v=g>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}c>>>=w,d-=w,n.back+=w}if(c>>>=v,d-=v,n.back+=v,64&_){e.msg="invalid distance code",n.mode=xe;break}n.offset=b,n.extra=15&_,n.mode=24;case 24:if(n.extra){for(M=n.extra;d<M;){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=xe;break}n.mode=25;case 25:if(0===l)break e;if(p=u-l,n.offset>p){if((p=n.offset-p)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=xe;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(u-=l,e.total_out+=u,n.total+=u,u&&(e.adler=n.check=n.flags?pe(n.check,r,u,a-u):he(n.check,r,u,a-u)),u=l,(n.flags?c:Ce(c))!==n.check){e.msg="incorrect data check",n.mode=xe;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=xe;break}c=0,d=0}n.mode=29;case 29:C=1;break e;case xe:C=-3;break e;case 31:return-4;default:return ye}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||u!==e.avail_out&&n.mode<xe&&(n.mode<27||4!==t))&&ze(e,e.output,e.next_out,u-e.avail_out),h-=e.avail_in,u-=e.avail_out,e.total_in+=h,e.total_out+=u,n.total+=u,n.wrap&&u&&(e.adler=n.check=n.flags?pe(n.check,r,u,e.next_out-u):he(n.check,r,u,e.next_out-u)),e.data_type=n.bits+(n.last?64:0)+(n.mode===ke?128:0)+(20===n.mode||15===n.mode?256:0),(0===h&&0===u||4===t)&&0===C&&(C=-5),C}function Le(e,t){var n=t.length;var i;return e&&e.state?0!==(i=e.state).wrap&&11!==i.mode?ye:11===i.mode&&he(1,t,n,0)!==i.check?-3:ze(e,t,n,n)?(i.mode=31,-4):(i.havedict=1,0):ye}var Be={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 He(){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 Re(){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 Fe=Object.prototype.toString;var Oe=function e(t){if(!(this instanceof e))return new e(t);this.options=K({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 He,this.strm.avail_out=0;var i=Me(this.strm,n.windowBits);if(0!==i)throw new Error(Be[i]);var r,o,a;if(this.header=new Re,r=this.strm,o=this.header,r&&r.state&&2&(a=r.state).wrap&&(a.head=o,o.done=!1),n.dictionary&&("string"==typeof n.dictionary?n.dictionary=se(n.dictionary):"[object ArrayBuffer]"===Fe.call(n.dictionary)&&(n.dictionary=new Uint8Array(n.dictionary)),n.raw&&0!==(i=Le(this.strm,n.dictionary))))throw new Error(Be[i])};Oe.prototype.push=function(e,t){var n=this.strm;var i=this.options.chunkSize;var r=this.options.dictionary;var o,a;var s,l,c;var d;var h=!1;if(this.ended)return!1;a=t===~~t?t:!0===t?4:0,"string"==typeof e?n.input=function(e){var t=new Uint8Array(e.length);for(var n=0,i=t.length;n<i;n++)t[n]=e.charCodeAt(n);return t}(e):"[object ArrayBuffer]"===Fe.call(e)?n.input=new Uint8Array(e):n.input=e,n.next_in=0,n.avail_in=n.input.length;do{if(0===n.avail_out&&(n.output=te(i),n.next_out=0,n.avail_out=i),2===(o=Pe(n,0))&&r&&(d="string"==typeof r?se(r):"[object ArrayBuffer]"===Fe.call(r)?new Uint8Array(r):r,o=Le(this.strm,d)),-5===o&&!0===h&&(o=0,h=!1),1!==o&&0!==o)return this.onEnd(o),this.ended=!0,!1;n.next_out&&(0!==n.avail_out&&1!==o&&(0!==n.avail_in||4!==a&&2!==a)||("string"===this.options.to?(s=de(n.output,n.next_out),l=n.next_out-s,c=ce(n.output,s),n.next_out=l,n.avail_out=i-l,l&&J(n.output,n.output,s,l,0),this.onData(c)):this.onData(Y(n.output,n.next_out)))),0===n.avail_in&&0===n.avail_out&&(h=!0)}while((n.avail_in>0||0===n.avail_out)&&1!==o);return 1===o&&(a=4),4===a?(o=function(e){if(!e||!e.state)return ye;var t=e.state;return t.window&&(t.window=null),e.state=null,0}(this.strm),this.onEnd(o),this.ended=!0,0===o):2!==a||(this.onEnd(0),n.avail_out=0,!0)},Oe.prototype.onData=function(e){this.chunks.push(e)},Oe.prototype.onEnd=function(e){0===e&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=ee(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function Ve(e){var t=e.length;for(;--t>=0;)e[t]=0}var Ne=256;var $e=286;var Ue=30;var We=15;var je=[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];var qe=[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];var Ge=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7];var Ke=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];var Ye;var Qe;var Xe;var Ze;var Je;var et;function tt(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}var nt;var it;var rt;function ot(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function at(e){return e<256?Xe[e]:Xe[256+(e>>>7)]}function st(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function lt(e,t,n){e.bi_valid>16-n?(e.bi_buf|=t<<e.bi_valid&65535,st(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 ct(e,t,n){lt(e,n[2*t],n[2*t+1])}function dt(e,t){var n=0;do{n|=1&e,e>>>=1,n<<=1}while(--t>0);return n>>>1}function ht(e,t,n){var i=new Array(16);var r=0;var o;var a;for(o=1;o<=We;o++)i[o]=r=r+n[o-1]<<1;for(a=0;a<=t;a++){var s=e[2*a+1];0!==s&&(e[2*a]=dt(i[s]++,s))}}function ut(e){var t;for(t=0;t<$e;t++)e.dyn_ltree[2*t]=0;for(t=0;t<Ue;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 pt(e){e.bi_valid>8?st(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 ft(e,t,n,i){var r=2*t;var o=2*n;return e[r]<e[o]||e[r]===e[o]&&i[t]<=i[n]}function mt(e,t,n){var i=e.heap[n];var r=n<<1;for(;r<=e.heap_len&&(r<e.heap_len&&ft(t,e.heap[r+1],e.heap[r],e.depth)&&r++,!ft(t,i,e.heap[r],e.depth));)e.heap[n]=e.heap[r],n=r,r<<=1;e.heap[n]=i}function gt(e,t,n){var i;var r;var o=0;var a;var s;if(0!==e.last_lit)do{i=e.pending_buf[e.d_buf+2*o]<<8|e.pending_buf[e.d_buf+2*o+1],r=e.pending_buf[e.l_buf+o],o++,0===i?ct(e,r,t):(ct(e,(a=Ze[r])+Ne+1,t),0!==(s=je[a])&<(e,r-=Je[a],s),ct(e,a=at(--i),n),0!==(s=qe[a])&<(e,i-=et[a],s))}while(o<e.last_lit);ct(e,256,t)}function vt(e,t){var n=t.dyn_tree;var i=t.stat_desc.static_tree;var r=t.stat_desc.has_stree;var o=t.stat_desc.elems;var a,s;var l=-1;var c;for(e.heap_len=0,e.heap_max=573,a=0;a<o;a++)0!==n[2*a]?(e.heap[++e.heap_len]=l=a,e.depth[a]=0):n[2*a+1]=0;for(;e.heap_len<2;)n[2*(c=e.heap[++e.heap_len]=l<2?++l:0)]=1,e.depth[c]=0,e.opt_len--,r&&(e.static_len-=i[2*c+1]);for(t.max_code=l,a=e.heap_len>>1;a>=1;a--)mt(e,n,a);c=o;do{a=e.heap[1],e.heap[1]=e.heap[e.heap_len--],mt(e,n,1),s=e.heap[1],e.heap[--e.heap_max]=a,e.heap[--e.heap_max]=s,n[2*c]=n[2*a]+n[2*s],e.depth[c]=(e.depth[a]>=e.depth[s]?e.depth[a]:e.depth[s])+1,n[2*a+1]=n[2*s+1]=c,e.heap[1]=c++,mt(e,n,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var n=t.dyn_tree;var i=t.max_code;var r=t.stat_desc.static_tree;var o=t.stat_desc.has_stree;var a=t.stat_desc.extra_bits;var s=t.stat_desc.extra_base;var l=t.stat_desc.max_length;var c;var d,h;var u;var p;var f;var m=0;for(u=0;u<=We;u++)e.bl_count[u]=0;for(n[2*e.heap[e.heap_max]+1]=0,c=e.heap_max+1;c<573;c++)(u=n[2*n[2*(d=e.heap[c])+1]+1]+1)>l&&(u=l,m++),n[2*d+1]=u,d>i||(e.bl_count[u]++,p=0,d>=s&&(p=a[d-s]),f=n[2*d],e.opt_len+=f*(u+p),o&&(e.static_len+=f*(r[2*d+1]+p)));if(0!==m){do{for(u=l-1;0===e.bl_count[u];)u--;e.bl_count[u]--,e.bl_count[u+1]+=2,e.bl_count[l]--,m-=2}while(m>0);for(u=l;0!==u;u--)for(d=e.bl_count[u];0!==d;)(h=e.heap[--c])>i||(n[2*h+1]!==u&&(e.opt_len+=(u-n[2*h+1])*n[2*h],n[2*h+1]=u),d--)}}(e,t),ht(n,l,e.bl_count)}function _t(e,t,n){var i;var r=-1;var o;var a=t[1];var s=0;var l=7;var c=4;for(0===a&&(l=138,c=3),t[2*(n+1)+1]=65535,i=0;i<=n;i++)o=a,a=t[2*(i+1)+1],++s<l&&o===a||(s<c?e.bl_tree[2*o]+=s:0!==o?(o!==r&&e.bl_tree[2*o]++,e.bl_tree[32]++):s<=10?e.bl_tree[34]++:e.bl_tree[36]++,s=0,r=o,0===a?(l=138,c=3):o===a?(l=6,c=3):(l=7,c=4))}function bt(e,t,n){var i;var r=-1;var o;var a=t[1];var s=0;var l=7;var c=4;for(0===a&&(l=138,c=3),i=0;i<=n;i++)if(o=a,a=t[2*(i+1)+1],!(++s<l&&o===a)){if(s<c)do{ct(e,o,e.bl_tree)}while(0!=--s);else 0!==o?(o!==r&&(ct(e,o,e.bl_tree),s--),ct(e,16,e.bl_tree),lt(e,s-3,2)):s<=10?(ct(e,17,e.bl_tree),lt(e,s-3,3)):(ct(e,18,e.bl_tree),lt(e,s-11,7));s=0,r=o,0===a?(l=138,c=3):o===a?(l=6,c=3):(l=7,c=4)}}var wt=!1;function yt(e){wt||(!function(){var e;var t;var n;var i;var r;var o=new Array(16);for(Ve(Ye=new Array(576)),Ve(Qe=new Array(60)),Ve(Xe=new Array(512)),Ve(Ze=new Array(256)),Ve(Je=new Array(29)),Ve(et=new Array(Ue)),n=0,i=0;i<28;i++)for(Je[i]=n,e=0;e<1<<je[i];e++)Ze[n++]=i;for(Ze[n-1]=i,r=0,i=0;i<16;i++)for(et[i]=r,e=0;e<1<<qe[i];e++)Xe[r++]=i;for(r>>=7;i<Ue;i++)for(et[i]=r<<7,e=0;e<1<<qe[i]-7;e++)Xe[256+r++]=i;for(t=0;t<=We;t++)o[t]=0;for(e=0;e<=143;)Ye[2*e+1]=8,e++,o[8]++;for(;e<=255;)Ye[2*e+1]=9,e++,o[9]++;for(;e<=279;)Ye[2*e+1]=7,e++,o[7]++;for(;e<=287;)Ye[2*e+1]=8,e++,o[8]++;for(ht(Ye,287,o),e=0;e<Ue;e++)Qe[2*e+1]=5,Qe[2*e]=dt(e,5);nt=new tt(Ye,je,257,$e,We),it=new tt(Qe,qe,0,Ue,We),rt=new tt(new Array(0),Ge,0,19,7)}(),wt=!0),e.l_desc=new ot(e.dyn_ltree,nt),e.d_desc=new ot(e.dyn_dtree,it),e.bl_desc=new ot(e.bl_tree,rt),e.bi_buf=0,e.bi_valid=0,ut(e)}function kt(e,t,n,i){lt(e,0+(i?1:0),3),function(e,t,n,i){pt(e),i&&(st(e,n),st(e,~n)),J(e.pending_buf,e.window,t,n,e.pending),e.pending+=n}(e,t,n,!0)}function xt(e){lt(e,2,3),ct(e,256,Ye),function(e){16===e.bi_valid?(st(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 Ct(e,t,n,i){var r,o;var a=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t=4093624447;var n;for(n=0;n<=31;n++,t>>>=1)if(1&t&&0!==e.dyn_ltree[2*n])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(n=32;n<Ne;n++)if(0!==e.dyn_ltree[2*n])return 1;return 0}(e)),vt(e,e.l_desc),vt(e,e.d_desc),a=function(e){var t;for(_t(e,e.dyn_ltree,e.l_desc.max_code),_t(e,e.dyn_dtree,e.d_desc.max_code),vt(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*Ke[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?kt(e,t,n,i):4===e.strategy||o===r?(lt(e,2+(i?1:0),3),gt(e,Ye,Qe)):(lt(e,4+(i?1:0),3),function(e,t,n,i){var r;for(lt(e,t-257,5),lt(e,n-1,5),lt(e,i-4,4),r=0;r<i;r++)lt(e,e.bl_tree[2*Ke[r]+1],3);bt(e,e.dyn_ltree,t-1),bt(e,e.dyn_dtree,n-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,a+1),gt(e,e.dyn_ltree,e.dyn_dtree)),ut(e),i&&pt(e)}function St(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*(Ze[n]+Ne+1)]++,e.dyn_dtree[2*at(t)]++),e.last_lit===e.lit_bufsize-1}var Tt=258;var Mt=262;var At=103;var Dt=113;var Et=666;function It(e,t){return e.msg=Be[t],t}function zt(e){return(e<<1)-(e>4?9:0)}function Pt(e){var t=e.length;for(;--t>=0;)e[t]=0}function Lt(e){var t=e.state;var n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(J(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 Bt(e,t){Ct(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,Lt(e.strm)}function Ht(e,t){e.pending_buf[e.pending++]=t}function Rt(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function Ft(e,t,n,i){var r=e.avail_in;return r>i&&(r=i),0===r?0:(e.avail_in-=r,J(t,e.input,e.next_in,r,n),1===e.state.wrap?e.adler=he(e.adler,t,r,n):2===e.state.wrap&&(e.adler=pe(e.adler,t,r,n)),e.next_in+=r,e.total_in+=r,r)}function Ot(e,t){var n=e.max_chain_length;var i=e.strstart;var r;var o;var a=e.prev_length;var s=e.nice_match;var l=e.strstart>e.w_size-Mt?e.strstart-(e.w_size-Mt):0;var c=e.window;var d=e.w_mask;var h=e.prev;var u=e.strstart+Tt;var p=c[i+a-1];var f=c[i+a];e.prev_length>=e.good_match&&(n>>=2),s>e.lookahead&&(s=e.lookahead);do{if(c[(r=t)+a]===f&&c[r+a-1]===p&&c[r]===c[i]&&c[++r]===c[i+1]){i+=2,r++;do{}while(c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&c[++i]===c[++r]&&i<u);if(o=Tt-(u-i),i=u-Tt,o>a){if(e.match_start=t,a=o,o>=s)break;p=c[i+a-1],f=c[i+a]}}}while((t=h[t&d])>l&&0!=--n);return a<=e.lookahead?a:e.lookahead}function Vt(e){var t=e.w_size;var n,i,r,o,a;do{if(o=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-Mt)){J(e.window,e.window,t,t,0),e.match_start-=t,e.strstart-=t,e.block_start-=t,n=i=e.hash_size;do{r=e.head[--n],e.head[n]=r>=t?r-t:0}while(--i);n=i=t;do{r=e.prev[--n],e.prev[n]=r>=t?r-t:0}while(--i);o+=t}if(0===e.strm.avail_in)break;if(i=Ft(e.strm,e.window,e.strstart+e.lookahead,o),e.lookahead+=i,e.lookahead+e.insert>=3)for(a=e.strstart-e.insert,e.ins_h=e.window[a],e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+3-1])&e.hash_mask,e.prev[a&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=a,a++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<Mt&&0!==e.strm.avail_in)}function Nt(e,t){var n=65535;for(n>e.pending_buf_size-5&&(n=e.pending_buf_size-5);;){if(e.lookahead<=1){if(Vt(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,Bt(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-Mt&&(Bt(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(Bt(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(Bt(e,!1),e.strm.avail_out),1)}function $t(e,t){var n;var i;for(;;){if(e.lookahead<Mt){if(Vt(e),e.lookahead<Mt&&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-Mt&&(e.match_length=Ot(e,n)),e.match_length>=3)if(i=St(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=St(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(i&&(Bt(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,4===t?(Bt(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Bt(e,!1),0===e.strm.avail_out)?1:2}function Ut(e,t){var n;var i;var r;for(;;){if(e.lookahead<Mt){if(Vt(e),e.lookahead<Mt&&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-Mt&&(e.match_length=Ot(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=St(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&&(Bt(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((i=St(e,0,e.window[e.strstart-1]))&&Bt(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=St(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,4===t?(Bt(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Bt(e,!1),0===e.strm.avail_out)?1:2}function Wt(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 jt=function(){var e=[new Wt(0,0,0,0,Nt),new Wt(4,4,8,4,$t),new Wt(4,5,16,8,$t),new Wt(4,6,32,32,$t),new Wt(4,4,16,16,Ut),new Wt(8,16,32,32,Ut),new Wt(8,16,128,128,Ut),new Wt(8,32,128,256,Ut),new Wt(32,128,258,1024,Ut),new Wt(32,258,258,4096,Ut)];return jt=function(){return e},e};function qt(){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=ne(1146),this.dyn_dtree=ne(122),this.bl_tree=ne(78),Pt(this.dyn_ltree),Pt(this.dyn_dtree),Pt(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=ne(16),this.heap=ne(573),Pt(this.heap),this.heap_len=0,this.heap_max=0,this.depth=ne(573),Pt(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 Gt(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:Dt,e.adler=2===t.wrap?0:1,t.last_flush=0,yt(t),0):It(e,q)}(e);return 0===t&&function(e){e.window_size=2*e.w_size,Pt(e.head);var t=jt();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 Kt(e,t){var n,i;var r,o;if(!e||!e.state||t>5||t<0)return e?It(e,q):q;if(i=e.state,!e.output||!e.input&&0!==e.avail_in||i.status===Et&&4!==t)return It(e,0===e.avail_out?-5:q);if(i.strm=e,n=i.last_flush,i.last_flush=t,42===i.status)if(2===i.wrap)e.adler=0,Ht(i,31),Ht(i,139),Ht(i,8),i.gzhead?(Ht(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)),Ht(i,255&i.gzhead.time),Ht(i,i.gzhead.time>>8&255),Ht(i,i.gzhead.time>>16&255),Ht(i,i.gzhead.time>>24&255),Ht(i,9===i.level?2:i.strategy>=2||i.level<2?4:0),Ht(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(Ht(i,255&i.gzhead.extra.length),Ht(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=pe(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69):(Ht(i,0),Ht(i,0),Ht(i,0),Ht(i,0),Ht(i,0),Ht(i,9===i.level?2:i.strategy>=2||i.level<2?4:0),Ht(i,3),i.status=Dt);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=Dt,Rt(i,a),0!==i.strstart&&(Rt(i,e.adler>>>16),Rt(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=pe(e.adler,i.pending_buf,i.pending-r,r)),Lt(e),r=i.pending,i.pending!==i.pending_buf_size));)Ht(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>r&&(e.adler=pe(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=pe(e.adler,i.pending_buf,i.pending-r,r)),Lt(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,Ht(i,o)}while(0!==o);i.gzhead.hcrc&&i.pending>r&&(e.adler=pe(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=pe(e.adler,i.pending_buf,i.pending-r,r)),Lt(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,Ht(i,o)}while(0!==o);i.gzhead.hcrc&&i.pending>r&&(e.adler=pe(e.adler,i.pending_buf,i.pending-r,r)),0===o&&(i.status=At)}else i.status=At;if(i.status===At&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&Lt(e),i.pending+2<=i.pending_buf_size&&(Ht(i,255&e.adler),Ht(i,e.adler>>8&255),e.adler=0,i.status=Dt)):i.status=Dt),0!==i.pending){if(Lt(e),0===e.avail_out)return i.last_flush=-1,0}else if(0===e.avail_in&&zt(t)<=zt(n)&&4!==t)return It(e,-5);if(i.status===Et&&0!==e.avail_in)return It(e,-5);if(0!==e.avail_in||0!==i.lookahead||0!==t&&i.status!==Et){var s=2===i.strategy?function(e,t){var n;for(;;){if(0===e.lookahead&&(Vt(e),0===e.lookahead)){if(0===t)return 1;break}if(e.match_length=0,n=St(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(Bt(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(Bt(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Bt(e,!1),0===e.strm.avail_out)?1:2}(i,t):3===i.strategy?function(e,t){var n;var i;var r,o;var a=e.window;for(;;){if(e.lookahead<=Tt){if(Vt(e),e.lookahead<=Tt&&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+Tt;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=Tt-(o-r),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(n=St(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=St(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(Bt(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(Bt(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Bt(e,!1),0===e.strm.avail_out)?1:2}(i,t):jt()[i.level].func(i,t);if(3!==s&&4!==s||(i.status=Et),1===s||3===s)return 0===e.avail_out&&(i.last_flush=-1),0;if(2===s&&(1===t?xt(i):5!==t&&(kt(i,0,0,!1),3===t&&(Pt(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),Lt(e),0===e.avail_out))return i.last_flush=-1,0}return 4!==t?0:i.wrap<=0?1:(2===i.wrap?(Ht(i,255&e.adler),Ht(i,e.adler>>8&255),Ht(i,e.adler>>16&255),Ht(i,e.adler>>24&255),Ht(i,255&e.total_in),Ht(i,e.total_in>>8&255),Ht(i,e.total_in>>16&255),Ht(i,e.total_in>>24&255)):(Rt(i,e.adler>>>16),Rt(i,65535&e.adler)),Lt(e),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?0:1)}var Yt=Object.prototype.toString;var Qt=function(e){this.options=K({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 He,this.strm.avail_out=0;var n=function(e,t,n,i,r,o){if(!e)return q;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 It(e,q);8===i&&(i=9);var s=new qt;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=te(2*s.w_size),s.head=ne(s.hash_size),s.prev=ne(s.w_size),s.lit_bufsize=1<<r+6,s.pending_buf_size=4*s.lit_bufsize,s.pending_buf=te(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,Gt(e)}(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(0!==n)throw new Error(Be[n]);var i,r;if(t.header&&(i=this.strm,r=t.header,i&&i.state&&(2!==i.state.wrap||(i.state.gzhead=r))),t.dictionary){var o;if(o="string"==typeof t.dictionary?se(t.dictionary):"[object ArrayBuffer]"===Yt.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,n=function(e,t){var n=t.length;var i;var r,o;var a;var s;var l;var c;var d;if(!e||!e.state)return q;if(2===(a=(i=e.state).wrap)||1===a&&42!==i.status||i.lookahead)return q;for(1===a&&(e.adler=he(e.adler,t,n,0)),i.wrap=0,n>=i.w_size&&(0===a&&(Pt(i.head),i.strstart=0,i.block_start=0,i.insert=0),d=te(i.w_size),J(d,t,n-i.w_size,i.w_size,0),t=d,n=i.w_size),s=e.avail_in,l=e.next_in,c=e.input,e.avail_in=n,e.next_in=0,e.input=t,Vt(i);i.lookahead>=3;){r=i.strstart,o=i.lookahead-2;do{i.ins_h=(i.ins_h<<i.hash_shift^i.window[r+3-1])&i.hash_mask,i.prev[r&i.w_mask]=i.head[i.ins_h],i.head[i.ins_h]=r,r++}while(--o);i.strstart=r,i.lookahead=2,Vt(i)}return i.strstart+=i.lookahead,i.block_start=i.strstart,i.insert=i.lookahead,i.lookahead=0,i.match_length=i.prev_length=2,i.match_available=0,e.next_in=l,e.input=c,e.avail_in=s,i.wrap=a,0}(this.strm,o),0!==n)throw new Error(Be[n]);this._dict_set=!0}};function Xt(e,t){var n=new Qt(t);if(n.push(e,!0),n.err)throw n.msg||Be[n.err];return n.result}Qt.prototype.push=function(e,t){var n=this.strm;var i=this.options.chunkSize;var r,o;if(this.ended)return!1;o=t===~~t?t:!0===t?4:0,"string"==typeof e?n.input=se(e):"[object ArrayBuffer]"===Yt.call(e)?n.input=new Uint8Array(e):n.input=e,n.next_in=0,n.avail_in=n.input.length;do{if(0===n.avail_out&&(n.output=te(i),n.next_out=0,n.avail_out=i),1!==(r=Kt(n,o))&&0!==r)return this.onEnd(r),this.ended=!0,!1;0!==n.avail_out&&(0!==n.avail_in||4!==o&&2!==o)||("string"===this.options.to?this.onData(le(a=Y(n.output,n.next_out),a.length)):this.onData(Y(n.output,n.next_out)))}while((n.avail_in>0||0===n.avail_out)&&1!==r);var a;return 4===o?(r=function(e){var t;return e&&e.state?42!==(t=e.state.status)&&69!==t&&73!==t&&91!==t&&t!==At&&t!==Dt&&t!==Et?It(e,q):(e.state=null,t===Dt?It(e,-3):0):q}(this.strm),this.onEnd(r),this.ended=!0,0===r):2!==o||(this.onEnd(0),n.avail_out=0,!0)},Qt.prototype.onData=function(e){this.chunks.push(e)},Qt.prototype.onEnd=function(e){0===e&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=ee(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var Zt={Promise:Promise};var Jt={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 en()}};var en=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 en=function(){return e},e};var tn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function nn(e){return e}function rn(e,t){for(var n=0;n<e.length;++n)t[n]=255&e.charCodeAt(n);return t}function on(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 an=function(){var e;try{e=Jt.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(t){e=!1}return an=function(){return e},e};function sn(e){var t=65536,n=pn(e),i=!0;if("uint8array"===n&&(i=an()),i)for(;t>1;)try{return on(e,n,t)}catch(e){t=Math.floor(t/2)}return function(e){var t="";for(var n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t}(e)}var ln=sn;function cn(e,t){for(var n=0;n<e.length;n++)t[n]=e[n];return t}var dn={string:{string:nn,array:function(e){return rn(e,new Array(e.length))},arraybuffer:function(e){return dn.string.uint8array(e).buffer},uint8array:function(e){return rn(e,new Uint8Array(e.length))}},array:{string:sn,array:nn,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)}},arraybuffer:{string:function(e){return sn(new Uint8Array(e))},array:function(e){return cn(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:nn,uint8array:function(e){return new Uint8Array(e)}},uint8array:{string:sn,array:function(e){return cn(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:nn}};var hn=function(e,t){if(t||(t=""),!e)return t;fn(e);var n=pn(t);return dn[n][e](t)};var un=function(e){var t=e.split("/");var n=[];for(var i=0;i<t.length;i++){var r=t[i];"."===r||""===r&&0!==i&&i!==t.length-1||(".."===r?n.pop():n.push(r))}return n.join("/")};var pn=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":Jt.uint8array&&e instanceof Uint8Array?"uint8array":Jt.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0};var fn=function(e){if(!Jt[e.toLowerCase()])throw new Error(e+" is not supported by this platform")};var mn=65535;var gn=-1;var vn=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};var _n=function(e,t,n){setTimeout((function(){e.apply(n||null,t||[])}),0)};var bn=function(){var e=arguments;var t,n,i={};for(t=0;t<arguments.length;t++)for(n in arguments[t])Object.hasOwnProperty.call(e[t],n)&&void 0===i[n]&&(i[n]=e[t][n]);return i};var wn=function(e,t,n,i,r){var o=Zt.Promise.resolve(t).then((function(e){return Jt.blob&&(e instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(e)))&&"undefined"!=typeof FileReader?new Zt.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}));return o.then((function(t){var o=pn(t);return o?("arraybuffer"===o?t=hn("uint8array",t):"string"===o&&(r?t=function(e){var t,n,i;var r,o,a;var s=0,l=0;var c="data:";if(e.substr(0,5)===c)throw new Error("Invalid base64 input, it looks like a data url.");var d=3*(e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"")).length/4;if(e.charAt(e.length-1)===tn.charAt(64)&&d--,e.charAt(e.length-2)===tn.charAt(64)&&d--,d%1!=0)throw new Error("Invalid base64 input, bad content length.");var h;for(h=Jt.uint8array?new Uint8Array(0|d):new Array(0|d);s<e.length;)t=tn.indexOf(e.charAt(s++))<<2|(r=tn.indexOf(e.charAt(s++)))>>4,n=(15&r)<<4|(o=tn.indexOf(e.charAt(s++)))>>2,i=(3&o)<<6|(a=tn.indexOf(e.charAt(s++))),h[l++]=t,64!==o&&(h[l++]=n),64!==a&&(h[l++]=i);return h}(t):n&&!0!==i&&(t=rn(a=t,Jt.uint8array?new Uint8Array(a.length):new Array(a.length)))),t):Zt.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"));var a}))};var yn=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};yn.prototype.push=function(e){this.emit("data",e)},yn.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},yn.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)},yn.prototype.on=function(e,t){return this._listeners[e].push(t),this},yn.prototype.cleanUp=function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},yn.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)},yn.prototype.pipe=function(e){return e.registerPrevious(this)},yn.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},yn.prototype.pause=function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},yn.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},yn.prototype.flush=function(){},yn.prototype.processChunk=function(e){this.push(e)},yn.prototype.withStreamInfo=function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},yn.prototype.mergeStreamInfo=function(){for(var e in this.extraStreamInfo)this.extraStreamInfo.hasOwnProperty(e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},yn.prototype.lock=function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},yn.prototype.toString=function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e};var kn=function(e){var t=new Array(256);for(var 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,kn=function(e){return t[e]},t[e]};var xn=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=Jt.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)};var Cn=function(e){return function(e){var t,n,i,r;var o=e.length;var a=new Array(2*o);for(n=0,t=0;t<o;)if((i=e[t++])<128)a[n++]=i;else if((r=kn(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),ln(a)}(e=hn(Jt.uint8array?"uint8array":"array",e))};var Sn=function(e){function t(){e.call(this,"utf-8 decode"),this.leftOver=null}return t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){var t=hn(Jt.uint8array?"uint8array":"array",e.data);if(this.leftOver&&this.leftOver.length){if(Jt.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+kn(e[n])>t?n:t}(t);var r=t;i!==t.length&&(Jt.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:Cn(r),meta:e.meta})},t.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:Cn(this.leftOver),meta:{}}),this.leftOver=null)},t}(yn);var Tn=function(e){function t(){e.call(this,"utf-8 encode")}return t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.push({data:xn(e.data),meta:e.meta})},t}(yn);var Mn=function(e){function t(t){e.call(this,"ConvertWorker to "+t),this.destType=t}return t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.push({data:hn(this.destType,e.data),meta:e.meta})},t}(yn);function An(e,t,n){switch(e){case"blob":return function(e,t){return fn("blob"),new Blob([e],{type:t})}(hn("arraybuffer",t),n);case"base64":return function(e){var t=[];var n,i,r,o,a,s,l;var c=0,d=e.length,h=d;var u="string"!=typeof e;for(;c<e.length;)h=d-c,u?(n=e[c++],i=c<d?e[c++]:0,r=c<d?e[c++]:0):(n=e.charCodeAt(c++),i=c<d?e.charCodeAt(c++):0,r=c<d?e.charCodeAt(c++):0),o=n>>2,a=(3&n)<<4|i>>4,s=h>1?(15&i)<<2|r>>6:64,l=h>2?63&r:64,t.push(tn.charAt(o)+tn.charAt(a)+tn.charAt(s)+tn.charAt(l));return t.join("")}(t);default:return hn(e,t)}}function Dn(e,t){return new Zt.Promise((function(n,i){var r=[];var 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=An(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 En=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,fn(i),this._worker=e.pipe(new Mn(i)),e.lock()}catch(e){this._worker=new yn("error"),this._worker.error(e)}};En.prototype.accumulate=function(e){return Dn(this,e)},En.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(){_n(t,arguments,n)})),this},En.prototype.resume=function(){return _n(this._worker.resume,[],this._worker),this},En.prototype.pause=function(){return this._worker.pause(),this};var In=!0;var zn=Object.freeze({__proto__:null,base64:!1,binary:!1,comment:null,compression:null,compressionOptions:null,createFolders:In,date:null,dir:!1,dosPermissions:null,unixPermissions:null});var Pn=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=pn(e),n.isPaused||n._tickAndRepeat()}),(function(e){n.error(e)}))}return t.__proto__=e,t.prototype=Object.create(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,_n(this._tickAndRepeat,[],this)),!0)},t.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(_n(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}(yn);var Ln=function(e){function t(t){e.call(this,"DataLengthProbe for "+t),this.propName=t,this.withStreamInfo(t,0)}return t.__proto__=e,t.prototype=Object.create(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}(yn);var Bn=function(){var e=[];for(var t=0;t<256;t++){var n=t;for(var i=0;i<8;i++)n=1&n?3988292384^n>>>1:n>>>1;e[t]=n}return Bn=function(){return e},e};function Hn(e,t){return void 0!==e&&e.length?"string"!==pn(e)?function(e,t,n,i){var r=Bn();var 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=Bn();var 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 t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.streamInfo.crc32=Hn(e.data,this.streamInfo.crc32||0),this.push(e)},t}(yn);var Fn=function(e,t,n,i,r){this.compressedSize=e,this.uncompressedSize=t,this.crc32=n,this.compression=i,this.compressedContent=r};Fn.prototype.getContentWorker=function(){var e=new Pn(Zt.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new Ln("data_length"));var t=this;return e.on("end",(function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")})),e},Fn.prototype.getCompressedWorker=function(){return new Pn(Zt.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)},Fn.createWorkerFrom=function(e,t,n){return e.pipe(new Rn).pipe(new Ln("uncompressedSize")).pipe(t.compressWorker(n)).pipe(new Ln("compressedSize")).withStreamInfo("compression",t)};var On=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}};On.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 Tn)),!r&&i&&(t=t.pipe(new Sn))}catch(e){(t=new yn("error")).error(e)}return new En(t,n,"")},On.prototype.async=function(e,t){return this.internalStream(e).accumulate(t)},On.prototype._compressWorker=function(e,t){if(this._data instanceof Fn&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var n=this._decompressWorker();return this._dataBinary||(n=n.pipe(new Tn)),Fn.createWorkerFrom(n,e,t)},On.prototype._decompressWorker=function(){return this._data instanceof Fn?this._data.getContentWorker():this._data instanceof yn?this._data:new Pn(this._data)};var Vn=function(){var e="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array?"uint8array":"array";Vn=function(){return e}};var Nn=function(e){function t(t,n){e.call(this,"FlateWorker/"+t),this._pako=null,this._pakoAction=t,this._pakoOptions=n,this.meta={}}return t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.meta=e.meta,null===this._pako&&this._createPako(),this._pako.push(hn(Vn(),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;var t={raw:!0,level:this._pakoOptions.level||-1};this._pako="Deflate"===this._pakoAction?new Qt(t):new Oe(t),this._pako.onData=function(t){e.push({data:t,meta:e.meta})}},t}(yn);var $n={magic:"\b\0",compressWorker:function(e){return new Nn("Deflate",e)},uncompressWorker:function(){return new Nn("Inflate",{})}};var Un={STORE:{magic:"\0\0",compressWorker:function(){return new yn("STORE compression")},uncompressWorker:function(){return new yn("STORE decompression")}},DEFLATE:$n};var Wn="PK";var jn="PK";var qn="PK";var Gn="PK";var Kn="PK";var Yn=function(e,t){var n,i="";for(n=0;n<t;n++)i+=String.fromCharCode(255&e),e>>>=8;return i};var Qn=function(e,t,n,i,r,o){var a,s,l=e.file,c=e.compression,d=o!==xn,h=hn("string",o(l.name)),u=hn("string",xn(l.name)),p=l.comment,f=hn("string",o(p)),m=hn("string",xn(p)),g=u.length!==l.name.length,v=m.length!==p.length,_="",b="",w="",y=l.dir,k=l.date;var 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;var T=0;y&&(S|=16),"UNIX"===r?(T=798,S|=function(e,t){var n=e;return e||(n=t?16893:33204),(65535&n)<<16}(l.unixPermissions,y)):(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=Yn(1,1)+Yn(Hn(h),4)+u,_+="up"+Yn(b.length,2)+b),v&&(w=Yn(1,1)+Yn(Hn(f),4)+m,_+="uc"+Yn(w.length,2)+w);var M="";return M+="\n\0",M+=Yn(C,2),M+=c.magic,M+=Yn(a,2),M+=Yn(s,2),M+=Yn(x.crc32,4),M+=Yn(x.compressedSize,4),M+=Yn(x.uncompressedSize,4),M+=Yn(h.length,2),M+=Yn(_.length,2),{fileRecord:Wn+M+h+_,dirRecord:jn+Yn(T,2)+M+Yn(f.length,2)+"\0\0\0\0"+Yn(S,4)+Yn(i,4)+h+_+f}};var Xn=function(e){return"PK\b"+Yn(e.crc32,4)+Yn(e.compressedSize,4)+Yn(e.uncompressedSize,4)};var Zn=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 t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.push=function(t){var n=t.meta.percent||0;var i=this.entriesCount;var 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=Qn(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;var n=Qn(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(n.dirRecord),t)this.push({data:Xn(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(){var e=this.bytesWritten;for(var t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var n=this.bytesWritten-e;var i=function(e,t,n,i,r){var o=hn("string",r(i));return qn+"\0\0\0\0"+Yn(e,2)+Yn(e,2)+Yn(t,4)+Yn(n,4)+Yn(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);var t=this._sources;for(var n=0;n<t.length;n++)t[n].lock()},t}(yn);var Jn=function(e,t,n){var i=new Zn(t.streamFiles,n,t.platform,t.encodeFileName);var r=0;try{e.forEach((function(e,n){r++;var o=function(e,t){var n=e||t;var i=Un[n];if(!i)throw new Error(n+" is not a valid compression method !");return i}(n.options.compression,t.compression);var a=n.options.compressionOptions||t.compressionOptions||{};var 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};var ei=function(e){this.data=e,this.length=e.length,this.index=0,this.zero=0};ei.prototype.checkOffset=function(e){this.checkIndex(this.index+e)},ei.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 ?")},ei.prototype.setIndex=function(e){this.checkIndex(e),this.index=e},ei.prototype.skip=function(e){this.setIndex(this.index+e)},ei.prototype.byteAt=function(e){},ei.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},ei.prototype.readString=function(e){return hn("string",this.readData(e))},ei.prototype.readData=function(e){},ei.prototype.lastIndexOfSignature=function(e){},ei.prototype.readAndCheckSignature=function(e){},ei.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 ti=function(e){function t(t){e.call(this,t);for(var n=0;n<this.data.length;n++)t[n]=255&t[n]}return t.__proto__=e,t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.prototype.byteAt=function(e){return this.data[this.zero+e]},t.prototype.lastIndexOfSignature=function(e){var t=e.charCodeAt(0),n=e.charCodeAt(1),i=e.charCodeAt(2),r=e.charCodeAt(3);for(var 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}(ei);var ni=function(e){function t(t){e.call(this,t)}return t.__proto__=e,t.prototype=Object.create(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}(ei);var ii=function(e){function t(t){e.call(this,t)}return t.__proto__=e,t.prototype=Object.create(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}(ti);function ri(e){var t=pn(e);return fn(t),"string"!==t||Jt.uint8array?Jt.uint8array?new ii(hn("uint8array",e)):new ti(hn("array",e)):new ni(e)}var oi=function(e,t){this.options=e,this.loadOptions=t};oi.prototype.isEncrypted=function(){return!(1&~this.bitFlag)},oi.prototype.useUTF8=function(){return!(2048&~this.bitFlag)},oi.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 Un)if(Un.hasOwnProperty(t)&&Un[t].magic===e)return Un[t];return null}(this.compressionMethod)))throw new Error("Corrupted zip : compression "+vn(this.compressionMethod)+" unknown (inner file : "+hn("string",this.fileName)+")");this.decompressed=new Fn(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},oi.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)},oi.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)},oi.prototype.parseZIP64ExtraField=function(e){if(this.extraFields[1]){var t=ri(this.extraFields[1].value);this.uncompressedSize===gn&&(this.uncompressedSize=t.readInt(8)),this.compressedSize===gn&&(this.compressedSize=t.readInt(8)),this.localHeaderOffset===gn&&(this.localHeaderOffset=t.readInt(8)),this.diskNumberStart===gn&&(this.diskNumberStart=t.readInt(4))}},oi.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}},oi.prototype.handleUTF8=function(){var e=Jt.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=Cn(this.fileName),this.fileCommentStr=Cn(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(null!==t)this.fileNameStr=t;else{var n=hn(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(n)}var i=this.findExtraFieldUnicodeComment();if(null!==i)this.fileCommentStr=i;else{var r=hn(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(r)}}},oi.prototype.findExtraFieldUnicodePath=function(){var e=this.extraFields[28789];if(e){var t=ri(e.value);return 1!==t.readInt(1)||Hn(this.fileName)!==t.readInt(4)?null:Cn(t.readData(e.length-5))}return null},oi.prototype.findExtraFieldUnicodeComment=function(){var e=this.extraFields[25461];if(e){var t=ri(e.value);return 1!==t.readInt(1)||Hn(this.fileComment)!==t.readInt(4)?null:Cn(t.readData(e.length-5))}return null};var ai=function(e){this.files=[],this.loadOptions=e};function si(e){return new Zt.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 li(e,t){var n=this;return t=bn(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:Cn}),wn("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then((function(e){var n=new ai(t);return n.load(e),n})).then((function(e){var n=[Zt.Promise.resolve(e)];var i=e.files;if(t.checkCRC32)for(var r=0;r<i.length;r++)n.push(si(i[r]));return Zt.Promise.all(n)})).then((function(e){var i=e.shift();var r=i.files;for(var o=0;o<r.length;o++){var a=r[o];var s=a.fileNameStr;var l=un(a.fileNameStr);n.file(l,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}),a.dir||(n.file(l).unsafeOriginalName=s)}return i.zipComment.length&&(n.comment=i.zipComment),n}))}ai.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 ("+vn(t)+", expected "+vn(e)+")")}},ai.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},ai.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);var t=Jt.uint8array?"uint8array":"array";var n=hn(t,e);this.zipComment=this.loadOptions.decodeFileName(n)},ai.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={};var e,t,n,i=this.zip64EndOfCentralSize-44;for(;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}},ai.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")},ai.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(Wn),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},ai.prototype.readCentralDir=function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(jn);)(e=new oi({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)},ai.prototype.readEndOfCentral=function(){var e=this.reader.lastIndexOfSignature(qn);if(e<0)throw!this.isSignature(0,Wn)?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(qn),this.readBlockEndOfCentral(),this.diskNumber===mn||this.diskWithCentralDirStart===mn||this.centralDirRecordsOnThisDisk===mn||this.centralDirRecords===mn||this.centralDirSize===gn||this.centralDirOffset===gn){if(this.zip64=!0,(e=this.reader.lastIndexOfSignature(Gn))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(Gn),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,Kn)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(Kn),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(Kn),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,jn)||(this.reader.zero=i);else if(i<0)throw new Error("Corrupted zip: missing "+Math.abs(i)+" bytes.")},ai.prototype.prepareReader=function(e){this.reader=ri(e)},ai.prototype.load=function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()};var ci=function(e,t,n){var i,r=pn(t);var o=bn(n||{},zn);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=hi(e)),o.createFolders&&(i=di(e))&&ui.call(this,i,!0);var a="string"===r&&!1===o.binary&&!1===o.base64;n&&void 0!==n.binary||(o.binary=!a),(t instanceof Fn&&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 Fn||t instanceof yn?t:wn(e,t,o.binary,o.optimizedBinaryString,o.base64);var l=new On(e,s,o);this.files[e]=l};var di=function(e){"/"===e.slice(-1)&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return t>0?e.substring(0,t):""};var hi=function(e){return"/"!==e.slice(-1)&&(e+="/"),e};var ui=function(e,t){return t=void 0!==t?t:In,e=hi(e),this.files[e]||ci.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]};function pi(e){return"[object RegExp]"===Object.prototype.toString.call(e)}var fi=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}};var mi={support:{configurable:!0},defaults:{configurable:!0},version:{configurable:!0},external:{configurable:!0}};fi.prototype.load=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},fi.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)},fi.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(i)})),t},fi.prototype.file=function(e,t,n){if(1===arguments.length){if(pi(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,ci.call(this,e,t,n),this},fi.prototype.folder=function(e){if(!e)return this;if(pi(e))return this.filter((function(t,n){return n.dir&&e.test(t)}));var t=this.root+e;var n=ui.call(this,t);var i=this.clone();return i.root=n.name,i},fi.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{var n=this.filter((function(t,n){return n.name.slice(0,e.length)===e}));for(var i=0;i<n.length;i++)delete this.files[n[i].name]}return this},fi.prototype.generate=function(e){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},fi.prototype.generateInternalStream=function(e){var t,n={};try{if((n=bn(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:xn})).type=n.type.toLowerCase(),n.compression=n.compression.toUpperCase(),"binarystring"===n.type&&(n.type="string"),!n.type)throw new Error("No output type specified.");fn(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=Jn(this,n,i)}catch(e){(t=new yn("error")).error(e)}return new En(t,n.type||"string",n.mimeType)},fi.prototype.generateAsync=function(e,t){return this.generateInternalStream(e).accumulate(t)},fi.prototype.loadAsync=function(e,t){return li.apply(this,[e,t])},fi.loadAsync=function(e,t){return(new fi).loadAsync(e,t)},mi.support.get=function(){return Jt},mi.defaults.get=function(){return zn},mi.version.get=function(){return"3.2.2-esm"},mi.external.get=function(){return Zt},Object.defineProperties(fi,mi);let gi={compile:function(e){return e}};let vi=class{static register(e){gi=e}static compile(e){return gi.compile(e)}};const _i=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;const bi={};const wi="undefined";function yi(e){if(bi[e])return bi[e];const t=[];return e.replace(_i,(function(e,n,i,r){t.push(typeof n!==wi?n:i||r)})),bi[e]=function(e){let n=e;for(let e=0;e<t.length&&n;e++)n=n[t[e]];return n},bi[e]}function ki(e,t){return e.reduce(((e,n,i)=>{const r=t(n,i);return null!=r&&e.push(r),e}),[])}function xi(e){return`${e.title}: ${e.value}`}function Ci(e,t){const n=[];for(let i=0;i<e;i++)n.push(t(i));return n}function Si(e){return e.id}bi[wi]=function(e){return e};class Ti{constructor(e){e.columns=this._trimColumns(e.columns||[]),this.allColumns=ki(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((e=>e.groupHeaderColumnTemplate)),this.collapsible=this.options.collapsible}workbook(){return{sheets:[{columns:this._columns(),rows:this.hierarchy?this._hierarchyRows():this._rows(),freezePane:this._freezePane(),filter:this._filter()}]}}_trimColumns(e){return e.filter((e=>{let t=Boolean(e.field);return!t&&e.columns&&(t=this._trimColumns(e.columns).length>0),t}))}_leafColumns(e){let t=[];for(let n=0;n<e.length;n++)e[n].columns?t=t.concat(this._leafColumns(e[n].columns)):t.push(e[n]);return t}_prepareColumn(e){if(!e.field)return null;let t=function(t){return yi(e.field)(t)};let n=null;return e.values&&(n={},e.values.forEach((function(e){n[e.value]=e.text})),t=function(t){return n[yi(e.field)(t)]}),Object.assign({},e,{value:t,values:n,groupHeaderTemplate:e.groupHeaderTemplate?vi.compile(e.groupHeaderTemplate):xi,groupHeaderColumnTemplate:e.groupHeaderColumnTemplate?vi.compile(e.groupHeaderColumnTemplate):null,groupFooterTemplate:e.groupFooterTemplate?vi.compile(e.groupFooterTemplate):null,footerTemplate:e.footerTemplate?vi.compile(e.footerTemplate):null})}_filter(){if(!this.options.filterable)return null;const e=this._depth();return{from:e,to:e+this.columns.length-1}}_createPaddingCells(e){return Ci(e,(()=>Object.assign({background:"#dfdfdf",color:"#333"},this.options.paddingCellOptions)))}_dataRow(e,t,n){let i=this._createPaddingCells(t);if(this.hasGroups&&n&&e.items){i=i.concat(this._groupHeaderCells(e,t,n));const 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))}const r=[];for(let t=0;t<this.columns.length;t++)r[t]=this._cell(e,this.columns[t]);return this.hierarchy&&(r[0].colSpan=n-t+1),[{type:"data",cells:i.concat(r),level:this.collapsible?t:null}]}_groupHeaderCells(e,t,n){const i=[];const r=this.allColumns.filter((function(t){return t.field===e.field}))[0]||{};const o=r&&r.title?r.title:e.field;const a=r?r.groupHeaderTemplate||r.groupHeaderColumnTemplate:null;const 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]);const 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}_dataRows(e,t){const n=this._depth();const i=[];for(let r=0;r<e.length;r++)i.push.apply(i,this._dataRow(e[r],t,n));return i}_hierarchyRows(){const e=this._depth();const t=this.data;const n=this.hierarchy.itemLevel;const i=this.hierarchy.itemId||Si;const r=this._hasFooterTemplate();const o=[];const a=[];let s=0;let l;r||(this.collapsible=!1);for(let c=0;c<t.length;c++){const d=t[c];const h=n(d,c);r&&(h>s?a.push({id:l,level:s}):h<s&&o.push.apply(o,this._hierarchyFooterRows(a,h,e)),s=h,l=i(d,c)),o.push.apply(o,this._dataRow(d,h+1,e))}if(r){o.push.apply(o,this._hierarchyFooterRows(a,0,e));const n=t.length?this.aggregates[t[0].parentId]:{};o.push(this._hierarchyFooter(n,0,e))}return this._prependHeaderRows(o),o}_hierarchyFooterRows(e,t,n){const i=[];for(;e.length&&e[e.length-1].level>=t;){const t=e.pop();i.push(this._hierarchyFooter(this.aggregates[t.id],t.level+1,n))}return i}_hasFooterTemplate(){const e=this.columns;for(let t=0;t<e.length;t++)if(e[t].footerTemplate)return!0}_hierarchyFooter(e,t,n){const i=this.columns.map((function(i,r){const o=r?1:n-t+1;if(i.footerTemplate){const t=(e||{})[i.field];return Object.assign({background:"#dfdfdf",color:"#333",colSpan:o,value:i.footerTemplate(Object.assign({aggregates:e},t))},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}}_footer(e,t){const n=[];const i=this.columns.some((e=>e.groupFooterTemplate));let r,o;i&&(o={group:{items:e.items,field:e.field,value:e.value}},r={},Object.keys(e.aggregates).forEach((t=>{r[t]=Object.assign({},e.aggregates[t],o)})));const a=this.columns.map((t=>{if(t.groupFooterTemplate){let n=Object.assign({},r,e.aggregates[t.field],o);return Object.assign({background:"#dfdfdf",color:"#333",value:t.groupFooterTemplate(n)},t.groupFooterCellOptions)}return Object.assign({background:"#dfdfdf",color:"#333"},t.groupFooterCellOptions)}));return i&&n.push({type:"group-footer",cells:this._createPaddingCells(this.groups.length).concat(a),level:this.collapsible?t:null}),n}_isColumnVisible(e){return this._visibleColumns([e]).length>0&&(e.field||e.columns)}_visibleColumns(e){return e.filter((e=>{let t=e.exportable;"object"==typeof t&&(t=e.exportable.excel);const n=!e.hidden&&!1!==t;const i=e.hidden&&!0===t;let r=n||i;return r&&e.columns&&(r=this._visibleColumns(e.columns).length>0),r}))}_headerRow(e,t){const n=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&&n[0].firstCell&&(n[0].colSpan+=this._depth()),{type:"header",cells:Ci(t.length,(()=>Object.assign({background:"#7a7a7a",color:"#fff"},this.options.headerPaddingCellOptions))).concat(n)}}_prependHeaderRows(e){const t=this.groups;const n=[{rowSpan:1,cells:[],index:0}];this._prepareHeaderRows(n,this.options.columns);for(let i=n.length-1;i>=0;i--)e.unshift(this._headerRow(n[i],t))}_prepareHeaderRows(e,t,n,i){const r=i||e[e.length-1];let o=e[r.index+1];let a=0;for(let i=0;i<t.length;i++){const s=t[i];if(this._isColumnVisible(s)){const t=Object.assign({background:"#7a7a7a",color:"#fff",value:s.title||s.field,colSpan:0,firstCell:0===i&&(!n||n.firstCell)},s.headerCellOptions);r.cells.push(t),s.columns&&s.columns.length&&(o||(o={rowSpan:0,cells:[],index:e.length},e.push(o)),t.colSpan=this._trimColumns(this._visibleColumns(s.columns)).length,this._prepareHeaderRows(e,s.columns,t,o),a+=t.colSpan-1,r.rowSpan=e.length-r.index)}}n&&(n.colSpan+=a)}_rows(){const e=this._dataRows(this.data,0);if(this.columns.length){this._prependHeaderRows(e);let t=!1;const n=this.columns.map((e=>e.footerTemplate?(t=!0,Object.assign({background:"#dfdfdf",color:"#333",value:e.footerTemplate(Object.assign({},this.aggregates,this.aggregates[e.field]))},e.footerCellOptions)):Object.assign({background:"#dfdfdf",color:"#333"},e.footerCellOptions)));t&&e.push({type:"footer",cells:this._createPaddingCells(this.groups.length).concat(n)})}return e}_headerDepth(e){let t=0;for(let n=0;n<e.length;n++)if(e[n].columns){const i=this._headerDepth(e[n].columns);i>t&&(t=i)}return 1+t}_freezePane(){const e=this._visibleColumns(this.options.columns||[]);const 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}}_cell(e,t){return Object.assign({value:t.value(e)},t.cellOptions)}_depth(){let e=0;return e=this.hierarchy?this.hierarchy.depth:this.groups.length,e}_columns(){return Ci(this._depth(),(()=>({width:20}))).concat(this.columns.map((function(e){return{width:parseInt(e.width,10),autoWidth:!e.width}})))}}let Mi={toString:e=>e};let Ai=class{static register(e){Mi=e}static toString(e,t){return Mi.toString(e,t)}};function Di(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}const Ei=Di(1900,0,-1);function Ii(e){const t=(n=e.getHours(),i=e.getMinutes(),r=e.getSeconds(),o=e.getMilliseconds(),(n+(i+(r+o/1e3)/60)/60)/24);var n,i,r,o;const a=function(e,t,n){return Di(e,t,n)-Ei}(e.getFullYear(),e.getMonth(),e.getDate());return a<0?a-1+t:a+t}const zi="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";const Pi=`data:${zi};base64,`;const Li={compression:"DEFLATE",type:"base64"};const Bi={compression:"DEFLATE",type:"blob"};const Hi={compression:"DEFLATE",type:"arraybuffer"};function Ri(e){return Pi+e}function Fi(e,t){return t.indexOf(e)}const Oi=JSON.parse.bind(JSON);function Vi(e){return String(e).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/\"/g,""").replace(/\'/g,"'")}function Ni(e,t){let n="";for(let i=0;i<e;++i)n+=t(i);return n}function $i(e,t){let n="";if(null!=e)if(Array.isArray(e))for(let i=0;i<e.length;++i)n+=t(e[i],i);else"object"==typeof e&&Object.keys(e).forEach(((i,r)=>{n+=t(e[i],i,r)}));return n}const Ui='<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r';const Wi=`${Ui}\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>`;const ji=({frozenColumns:e,frozenRows:t,columns:n,defaults:i,data:r,index:o,mergeCells:a,autoFilter:s,filter:l,showGridLines:c,hyperlinks:d,validations:h,defaultCellStyleId:u,rtl:p,legacyDrawing:f,drawing:m,lastRow:g,lastCol:v,hasDisabledCells:_})=>`${Ui}\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 ${g&&v?`<dimension ref="A1:${Ki(g-1,v-1)}" />`:""}\n\n <sheetViews>\n <sheetView ${p?'rightToLeft="1"':""} ${0===o?'tabSelected="1"':""} workbookViewId="0" ${!1===c?'showGridLines="0"':""}>\n ${t||e?`\n <pane state="frozen"\n ${e?`xSplit="${e}"`:""}\n ${t?`ySplit="${t}"`:""}\n topLeftCell="${String.fromCharCode(65+(e||0))+((t||0)+1)}"\n />`:""}\n </sheetView>\n </sheetViews>\n\n <sheetFormatPr x14ac:dyDescent="0.25" ${i.skipCustomHeight?"":'customHeight="1"'} defaultRowHeight="${i.rowHeight?.75*i.rowHeight:15}"\n ${i.columnWidth?`defaultColWidth="${Xi(i.columnWidth)}"`:""} />\n\n ${null!=u||n&&n.length>0?`\n <cols>\n ${n&&n.length?"":`\n <col min="1" max="16384" style="${u}"\n ${i.columnWidth?`width="${Xi(i.columnWidth)}"`:""} /> `}\n ${$i(n,((e,t)=>{const n="number"==typeof e.index?e.index+1:t+1;return 0===e.width?`<col ${null!=u?`style="${u}"`:""}\n min="${n}" max="${n}" hidden="1" customWidth="1" />`:`<col ${null!=u?`style="${u}"`:""}\n min="${n}" max="${n}" customWidth="1"\n ${e.autoWidth?`width="${(7*e.width+5)/7*256/256}" bestFit="1"`:`width="${Xi(e.width)}"`} />`}))}\n </cols>`:""}\n\n <sheetData>\n ${$i(r,((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="${n=e.height,.75*n}" customHeight="1"`:""}>\n ${$i(e.data,(e=>`\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>${Vi(e)}</f>`;return`<f t="array" ref="${e.ref}">${Vi(e.src)}</f>`}(e.formula):""}\n ${null!=e.value?`<v>${Vi(e.value)}</v>`:""}\n </c>`))}\n </row>\n `;var n}))}\n </sheetData>\n\n ${_?'<sheetProtection sheet="1" objects="1" scenarios="1"/>':""}\n\n ${s?`<autoFilter ref="${s.from}:${s.to}"/>`:l?yr(l):""}\n\n ${a.length?`\n <mergeCells count="${a.length}">\n ${$i(a,(e=>`<mergeCell ref="${e}"/>`))}\n </mergeCells>`:""}\n\n ${h.length?`\n <dataValidations>\n ${$i(h,(e=>`\n <dataValidation sqref="${e.sqref.join(" ")}"\n showErrorMessage="${e.showErrorMessage}"\n type="${Vi(e.type)}"\n ${"list"!==e.type?`operator="${Vi(e.operator)}"`:""}\n allowBlank="${e.allowBlank}"\n showDropDown="${e.showDropDown}"\n ${e.error?`error="${Vi(e.error)}"`:""}\n ${e.errorTitle?`errorTitle="${Vi(e.errorTitle)}"`:""}>\n ${e.formula1?`<formula1>${Vi(e.formula1)}</formula1>`:""}\n ${e.formula2?`<formula2>${Vi(e.formula2)}</formula2>`:""}\n </dataValidation>`))}\n </dataValidations>`:""}\n\n ${d.length?`\n <hyperlinks>\n ${$i(d,(e=>`\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 ${m?`<drawing r:id="${m}"/>`:""}\n ${f?`<legacyDrawing r:id="${f}"/>`:""}\n</worksheet>`;const qi=e=>`${Ui}\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n ${$i(e,(e=>`\n <Relationship Id="${e.rId}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image" Target="${e.target}"/>`))}\n</Relationships>`;function Gi(e){const t=Math.floor(e/26)-1;return(t>=0?Gi(t):"")+String.fromCharCode(65+e%26)}function Ki(e,t){return Gi(t)+(e+1)}function Yi(e,t){return"$"+Gi(t)+"$"+(e+1)}function Qi(e){return(e.frozenRows||(e.freezePane||{}).rowSplit||1)-1}function Xi(e){return e/7-Math.floor(128/7)/256}class Zi{constructor(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(((e,t)=>Object.assign({},e,{rId:`link${t}`})))}relsToXML(){const e=this._hyperlinks;const t=this._comments;const n=this._drawings;if(e.length||t.length||n.length)return(({hyperlinks:e,comments:t,sheetIndex:n,drawings:i})=>`${Ui}\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n ${$i(e,(e=>`\n <Relationship Id="${e.rId}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" Target="${Vi(e.target)}" TargetMode="External" />`))}\n ${t.length?`\n <Relationship Id="comment${n}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" Target="../comments${n}.xml"/>\n <Relationship Id="vml${n}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing" Target="../drawings/vmlDrawing${n}.vml"/>`:""}\n ${i.length?`\n <Relationship Id="drw${n}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing" Target="../drawings/drawing${n}.xml"/>`:""}\n</Relationships>`)({hyperlinks:e,comments:t,sheetIndex:this.options.sheetIndex,drawings:n})}toXML(e){const t=this.options.mergedCells||[];const n=function(e,t){const n=[];const i=[];!function(e,t){for(let n=0;n<e.length;n++){const i=e[n];if(!i)continue;let r=i.index;"number"!=typeof r&&(r=n),t(i,r)}}(e,(function(e,t){const r={_source:e,index:t,height:e.height,level:e.level,cells:[]};n.push(r),i[t]=r}));const r=lr(n).slice(0);const o={rowData:n,rowsByIndex:i,mergedCells:t};for(let e=0;e<r.length;e++)ur(r[e],o),delete r[e]._source;return lr(n)}(this.options.rows||[],t);this._readCells(n);let i=this.options.filter;let r;i&&"number"==typeof i.from&&"number"==typeof i.to?i={from:Ki(Qi(this.options),i.from),to:Ki(Qi(this.options),i.to)}:i&&i.ref&&i.columns&&(r=i,i=null);const o=[];for(let e in this._validations)Object.prototype.hasOwnProperty.call(this._validations,e)&&o.push(this._validations[e]);let a=null;let s=this.options.defaultCellStyle;this._hasDisabledCells&&(s=s?Object.assign({disabled:!1},s):{disabled:!1}),s&&(a=this._lookupStyle(s));const l=this.options.freezePane||{};const c=this.options.defaults||{};const d=this.options.rows?this._getLastRow():1;const h=this.options.rows?this._getLastCol():1;return ji({frozenColumns:this.options.frozenColumns||l.colSplit,frozenRows:this.options.frozenRows||l.rowSplit,columns:this.options.columns,defaults:c,data:n,index:e,mergeCells:t,autoFilter:i,filter:r,showGridLines:this.options.showGridLines,hyperlinks:this._hyperlinks,validations:o,defaultCellStyleId:a,rtl:void 0!==this.options.rtl?this.options.rtl:c.rtl,legacyDrawing:this._comments.length?`vml${this.options.sheetIndex}`:null,drawing:this._drawings.length?`drw${this.options.sheetIndex}`:null,lastRow:d,lastCol:h,hasDisabledCells:this._hasDisabledCells})}commentsXML(){if(this._comments.length)return(({comments:e})=>`${Ui}\n<comments xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main">\n <authors>\n <author></author>\n </authors>\n <commentList>\n ${$i(e,(e=>`\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>${Vi(e.text)}</t>\n </r>\n </text>\n </comment>`))}\n </commentList>\n</comments>`)({comments:this._comments})}drawingsXML(e){if(this._drawings.length){let n={};let i=this._drawings.map((t=>{let i=dr(t.topLeftCell);let r=n[t.image];return r||(r=n[t.image]={rId:`img${t.image}`,target:e[t.image].target}),{col:i.col,colOffset:hr(t.offsetX),row:i.row,rowOffset:hr(t.offsetY),width:hr(t.width),height:hr(t.height),imageId:r.rId}}));return{main:(t=i,`${Ui}\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 ${$i(t,((e,t)=>`\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:qi(n)}}var t}legacyDrawing(){if(this._comments.length)return(({comments:e})=>`<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 ${$i(e,(e=>`\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})}_lookupString(e){const t="$"+e;const n=this._strings.indexes[t];let i;return void 0!==n?i=n:(i=this._strings.indexes[t]=this._strings.uniqueCount,this._strings.uniqueCount++),this._strings.count++,i}_lookupStyle(e){const t=JSON.stringify(e);if("{}"===t)return 0;let n=Fi(t,this._styles);return n<0&&(n=this._styles.push(t)-1),n+1}_lookupBorder(e){const t=JSON.stringify(e);if("{}"===t)return;let n=Fi(t,this._borders);return n<0&&(n=this._borders.push(t)-1),n+1}_readCells(e){for(let t=0;t<e.length;t++){const n=e[t];const i=n.cells;n.data=[];for(let e=0;e<i.length;e++){const t=this._cell(i[e],n.index,e);t&&n.data.push(t)}}}_cell(e,t,n){if(!e||e===sr)return null;let i=e.value;let r={};e.borderLeft&&(r.left=e.borderLeft),e.borderRight&&(r.right=e.borderRight),e.borderTop&&(r.top=e.borderTop),e.borderBottom&&(r.bottom=e.borderBottom),e.dBorders&&(r.diagonal=e.dBorders),r=this._lookupBorder(r);const o=this.options.defaultCellStyle||{};let a={borderId:r};(e=>{e("color"),e("background"),e("bold"),e("italic"),e("underline"),e("fontFamily")||e("fontName","fontFamily"),e("fontSize"),e("format"),e("textAlign")||e("hAlign","textAlign"),e("verticalAlign")||e("vAlign","verticalAlign"),e("wrap"),e("indent"),e("disabled")||e("enable")&&(a.disabled=!a.enable,delete a.enable),a.disabled&&(this._hasDisabledCells=!0)})(((t,n)=>{let i=e[t];if(void 0===i&&(i=o[t]),void 0!==i)return a[n||t]=i,!0}));const s=(this.options.columns||[])[n];let l=typeof i;if(s&&s.autoWidth&&(!e.colSpan||1===e.colSpan)){let t=i;"number"===l&&(t=Ai.toString(i,e.format)),s.width=Math.max(s.width||0,String(t).length)}"string"===l?(i=function(e){return String(e).replace(/[\x00-\x09\x0B\x0C\x0E-\x1F]/g,"").replace(/\r?\n/g,"\r\n")}(i),i=this._lookupString(i),l="s"):"number"===l?l="n":"boolean"===l?(l="b",i=Number(i)):i&&i.getTime?(l=null,i=Ii(i),a.format||(a.format="mm-dd-yy")):(l=null,i=null),a=this._lookupStyle(a);const c=Ki(t,n);if(e.validation&&this._addValidation(e.validation,c),e.comment){let i=[n+1,15,t,10,n+3,15,t+3,4];this._comments.push({ref:c,text:e.comment,row:t,col:n,anchor:i.join(", ")})}return{value:i,formula:e.formula,type:l,style:a,ref:c}}_addValidation(e,t){const n={showErrorMessage:"reject"===e.type?1:0,formula1:e.from,formula2:e.to,type:tr[e.dataType]||e.dataType,operator:er[e.comparerType]||e.comparerType,allowBlank:e.allowNulls?1:0,showDropDown:e.showButton?0:1,error:e.messageTemplate,errorTitle:e.titleTemplate};const i=JSON.stringify(n);this._validations[i]||(this._validations[i]=n,n.sqref=[]),this._validations[i].sqref.push(t)}_getLastRow(){return Ji(this.options.rows)}_getLastCol(){let e=0;return this.options.rows.forEach((function(t){t.cells&&(e=Math.max(e,Ji(t.cells)))})),e}}function Ji(e){let t=e.length;return e.forEach((function(e){e.index&&e.index>=t&&(t=e.index+1)})),t}const er={greaterThanOrEqualTo:"greaterThanOrEqual",lessThanOrEqualTo:"lessThanOrEqual"};const tr={number:"decimal"};const nr={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 ir(e){let t=function(e){function t(e){let t=parseInt(e,10).toString(16);return t.length<2?"0"+t:t}let n=/^rgba?\((\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*([0-9.]+)\s*)?\)/i.exec(e.trim());if(n)return"#"+t(255*(n[4]?parseFloat(n[4]):1)|0)+t(n[1])+t(n[2])+t(n[3]);return e}(e);return t.length<6&&(t=t.replace(/(\w)/g,(function(e,t){return t+t}))),t=t.substring(1).toUpperCase(),t.length<8&&(t="FF"+t),t}let rr=class{constructor(e){this.options=e||{},this._strings={indexes:{},count:0,uniqueCount:0},this._styles=[],this._borders=[],this._images=this.options.images,this._imgId=0,this._sheets=ki(this.options.sheets||[],((e,t)=>(e.defaults=this.options,e.sheetIndex=t+1,new Zi(e,this._strings,this._styles,this._borders))))}imageFilename(e){const 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`}}toZIP(){const e=new fi;const t=e.folder("docProps");t.file("core.xml",(({creator:e,lastModifiedBy:t,created:n,modified:i})=>`${Ui}\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>${Vi(e)}</dc:creator>\n <cp:lastModifiedBy>${Vi(t)}</cp:lastModifiedBy>\n <dcterms:created xsi:type="dcterms:W3CDTF">${Vi(n)}</dcterms:created>\n <dcterms:modified xsi:type="dcterms:W3CDTF">${Vi(i)}</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()}));const n=this._sheets.length;t.file("app.xml",(({sheets:e})=>`${Ui}\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>${e.length}</vt:i4>\n </vt:variant>\n </vt:vector>\n </HeadingPairs>\n <TitlesOfParts>\n <vt:vector size="${e.length}" baseType="lpstr">${$i(e,((e,t)=>e.options.title?`<vt:lpstr>${Vi(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}));e.folder("_rels").file(".rels",Wi);const i=e.folder("xl");if(i.folder("_rels").file("workbook.xml.rels",(({count:e})=>`${Ui}\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n ${Ni(e,(e=>`\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${e+1}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" Target="styles.xml" />\n <Relationship Id="rId${e+2}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings" Target="sharedStrings.xml" />\n</Relationships>`)({count:n})),this._images){const e=i.folder("media");Object.keys(this._images).forEach((t=>{const n=this._images[t];const i=this.imageFilename(n.type);e.file(i,n.data),n.target=`../media/${i}`}))}const r={};i.file("workbook.xml",(({sheets:e,filterNames:t,userNames:n})=>`${Ui}\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 ${$i(e,(({options:e},t)=>{const n=e.name||e.title||`Sheet${t+1}`;const i=e.state||"visible";return`<sheet name="${Vi(n)}" state="${i}" sheetId="${t+1}" r:id="rId${t+1}" />`}))}\n </sheets>\n ${t.length||n.length?`\n <definedNames>\n ${$i(t,(e=>{return`\n <definedName name="_xlnm._FilterDatabase" hidden="1" localSheetId="${e.localSheetId}">${Vi((t=e.name,/^\'/.test(t)||/^[a-z_][a-z0-9_]*$/i.test(t)?t:"'"+t.replace(/\x27/g,"\\'")+"'"))}!${Vi(e.from)}:${Vi(e.to)}</definedName>`;var t}))}\n ${$i(n,(e=>`\n <definedName name="${e.name}" hidden="${e.hidden?1:0}" ${null!=e.localSheetId?`localSheetId="${e.localSheetId}"`:""}>${Vi(e.value)}</definedName>`))}\n </definedNames>`:""}\n <calcPr fullCalcOnLoad="1" calcId="145621" />\n</workbook>`)({sheets:this._sheets,filterNames:ki(this._sheets,(function(e,t){const n=e.options;const i=n.name||n.title||"Sheet"+(t+1);r[i.toLowerCase()]=t;const o=n.filter;if(o){if(o.ref){let e=o.ref.split(":");let n=dr(e[0]);let r=dr(e[1]);return{localSheetId:t,name:i,from:Yi(n.row,n.col),to:Yi(r.row,r.col)}}if(void 0!==o.from&&void 0!==o.to)return{localSheetId:t,name:i,from:Yi(Qi(n),o.from),to:Yi(Qi(n),o.to)}}})),userNames:ki(this.options.names||[],(function(e){return{name:e.localName,localSheetId:e.sheet?r[e.sheet.toLowerCase()]:null,value:e.value,hidden:e.hidden}}))}));const o=i.folder("worksheets");const a=i.folder("drawings");const s=a.folder("_rels");const l=o.folder("_rels");const c=[];const d=[];let h=!1;for(let e=0;e<n;e++){const t=this._sheets[e];const n=`sheet${e+1}.xml`;const r=t.toXML(e);const u=t.relsToXML();const p=t.commentsXML();const f=t.legacyDrawing();const m=t.drawingsXML(this._images);if(t._hasDisabledCells&&(h=!0),u&&l.file(n+".rels",u),p){let e=`comments${t.options.sheetIndex}.xml`;i.file(e,p),c.push(e)}if(f&&a.file(`vmlDrawing${t.options.sheetIndex}.vml`,f),m){let e=`drawing${t.options.sheetIndex}.xml`;a.file(e,m.main),s.file(`${e}.rels`,m.rels),d.push(e)}o.file(n,r)}const u=ki(this._borders,Oi);const p=ki(this._styles,Oi);const f=function(e){return e.underline||e.bold||e.italic||e.color||e.fontFamily||e.fontSize};const m=ki(p,(function(e){if(e.fontSize&&(e.fontSize=function(e){let t=Number(e);let n;return t&&(n=3*t/4),n}(e.fontSize)),e.color&&(e.color=ir(e.color)),f(e))return e}));const g=ki(p,(function(e){if(e.format&&void 0===nr[e.format])return e}));const v=ki(p,(function(e){if(e.background)return e.background=ir(e.background),e}));return i.file("styles.xml",(({formats:e,fonts:t,fills:n,borders:i,styles:r})=>`${Ui}\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="${e.length}">\n ${$i(e,((e,t)=>`\n <numFmt formatCode="${Vi(e.format)}" numFmtId="${165+t}" />`))}\n </numFmts>\n <fonts count="${t.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 ${$i(t,(e=>`\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="${Vi(e.color)}" />`:'<color theme="1" />'}\n ${e.fontFamily?`\n <name val="${Vi(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="${n.length+2}">\n <fill><patternFill patternType="none"/></fill>\n <fill><patternFill patternType="gray125"/></fill>\n ${$i(n,(e=>"\n "+(e.background?`\n <fill>\n <patternFill patternType="solid">\n <fgColor rgb="${Vi(e.background)}"/>\n </patternFill>\n </fill>\n `:"")))}\n </fills>\n <borders count="${i.length+1}">\n <border><left/><right/><top/><bottom/><diagonal/></border>\n ${$i(i,ar)}\n </borders>\n <cellStyleXfs count="1">\n <xf borderId="0" fillId="0" fontId="0" />\n </cellStyleXfs>\n <cellXfs count="${r.length+1}">\n <xf numFmtId="0" fontId="0" fillId="0" borderId="0" xfId="0" />\n ${$i(r,(e=>`\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="${Vi(e.textAlign)}"`:""}\n ${e.verticalAlign?`vertical="${Vi(e.verticalAlign)}"`:""}\n ${e.indent?`indent="${Vi(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:m,fills:v,formats:g,borders:u,styles:ki(p,(function(e){const t={};return f(e)&&(t.fontId=Fi(e,m)+1),e.background&&(t.fillId=Fi(e,v)+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!==nr[e.format]?t.numFmtId=nr[e.format]:t.numFmtId=165+Fi(e,g)),h&&(t.disabled=!!e.disabled),t}))})),i.file("sharedStrings.xml",(({count:e,uniqueCount:t,indexes:n})=>`${Ui}\n<sst xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" count="${e}" uniqueCount="${t}">\n ${$i(Object.keys(n),(e=>`\n <si><t xml:space="preserve">${Vi(e.substring(1))}</t></si>`))}\n</sst>`)(this._strings)),e.file("[Content_Types].xml",(({sheetCount:e,commentFiles:t,drawingFiles:n})=>`${Ui}\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 ${Ni(e,(e=>`<Override PartName="/xl/worksheets/sheet${e+1}.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml" />`))}\n ${$i(t,(e=>`<Override PartName="/xl/${e}" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml"/>`))}\n ${$i(n,(e=>`<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:n,commentFiles:c,drawingFiles:d})),e}toDataURL(){const e=this.toZIP();return e.generateAsync?e.generateAsync(Li).then(Ri):Ri(e.generate(Li))}toBlob(){const e=this.toZIP();return e.generateAsync?e.generateAsync(Bi):new Blob([e.generate(Hi)],{type:zi})}};function or(e,t){let n="";return t&&(n+="<"+e+' style="'+function(e){let t="thin";return 2===e?t="medium":3===e&&(t="thick"),t}(t.size)+'">',t.color&&(n+='<color rgb="'+ir(t.color)+'"/>'),n+="</"+e+">"),n}function ar(e){let t=e.diagonal?e.diagonal.type:0;return`<border ${2&t?'diagonalUp="true"':""} ${1&t?'diagonalDown="true"':""}>\n ${or("left",e.left)}\n ${or("right",e.right)}\n ${or("top",e.top)}\n ${or("bottom",e.bottom)}\n ${or("diagonal",e.diagonal)}\n </border>`}const sr={};function lr(e){return e.sort((function(e,t){return e.index-t.index}))}function cr(e,t){for(let n=0;n<e.length;++n){const i=e[n].split(":");let r=i[0];if(r===t){let e=i[1];return r=dr(r),e=dr(e),{rowSpan:e.row-r.row+1,colSpan:e.col-r.col+1}}}}function dr(e){const t=/^([a-z]+)(\d+)$/i.exec(e);return{row:(n=t[2],parseInt(n,10)-1),col:function(e){let t=e.toUpperCase();let n=0;for(let e=0;e<t.length;++e)n=26*n+t.charCodeAt(e)-64;return n-1}(t[1])};var n}function hr(e){return Math.round(9525*e)}function ur(e,t){const n=e._source;const i=e.index;const r=n.cells;const o=e.cells;var a,s;if(r)for(let e=0;e<r.length;e++){const n=r[e]||sr;let l=n.rowSpan||1;let c=n.colSpan||1;const d=pr(o,n);const h=Ki(i,d);if(1===l&&1===c){const e=cr(t.mergedCells,h);e&&(c=e.colSpan,l=e.rowSpan)}if(mr(n,o,d,c),(l>1||c>1)&&(a=t.mergedCells,s=h+":"+Ki(i+l-1,d+c-1),a.indexOf(s)<0&&a.push(s)),l>1)for(let e=i+1;e<i+l;e++){let i=t.rowsByIndex[e];i||(i=t.rowsByIndex[e]={index:e,cells:[]},t.rowData.push(i)),mr(n,i.cells,d-1,c+1)}}}function pr(e,t){let n;return"number"==typeof t.index?(n=t.index,fr(e,t,t.index)):n=function(e,t){let n=e.length;for(let i=0;i<e.length+1;i++)if(!e[i]){e[i]=t,n=i;break}return n}(e,t),n}function fr(e,t,n){e[n]=t}function mr(e,t,n,i){for(let r=1;r<i;r++){fr(t,{borderTop:e.borderTop,borderRight:e.borderRight,borderBottom:e.borderBottom,borderLeft:e.borderLeft},n+r)}}const gr=({ref:e,columns:t,generators:n})=>`\n<autoFilter ref="${e}">\n ${$i(t,(e=>`\n <filterColumn colId="${e.index}">\n ${n[e.filter](e)}\n </filterColumn>\n `))}\n</autoFilter>`;const vr=({logic:e,criteria:t})=>`\n<customFilters ${"and"===e?'and="1"':""}>\n${$i(t,(e=>{let t=yr.customOperator(e);return`<customFilter ${t?`operator="${t}"`:""} val="${yr.customValue(e)}"/>`}))}\n</customFilters>`;const _r=({type:e})=>`<dynamicFilter type="${yr.dynamicFilterType(e)}" />`;const br=({type:e,value:t})=>`<top10 percent="${/percent$/i.test(e)?1:0}"\n top="${/^top/i.test(e)?1:0}"\n val="${t}" />`;const wr=({blanks:e,values:t})=>`<filters ${e?'blank="1"':""}>\n ${$i(t,(e=>`\n <filter val="${e}" />`))}\n </filters>`;function yr(e){return gr({ref:e.ref,columns:e.columns,generators:{custom:vr,dynamic:_r,top:br,value:wr}})}yr.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()]},yr.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}},yr.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){Ai.register({toString:kendo.toString});let t=kendo.ConvertClass(rr);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();var 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=Ai,window.kendo.ooxml.Workbook=t,window.kendo.ooxml.Worksheet=kendo.ConvertClass(Zi),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(Ti);vi.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;var t=this.dataSource;if(e&&t.level){e={itemLevel:function(e){return t.level(e)}};var n=t.view();var i=0;var r;for(var o=0;o<n.length;o++)(r=t.level(n[o]))>i&&(i=r);e.depth=i+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=vi}(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||{};var 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}))e&&e.resolve();else{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;var 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:{};var 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;var s=this.promise;var 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]];var 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 kr=function(){return"undefined"!=typeof window};var xr={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/};var Cr={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/};var Sr={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};var Tr={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};var Mr=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};var Ar=function(e){var t;var n=[];for(var i in xr)if(xr.hasOwnProperty(i)){if(!(n=e.match(xr[i])))continue;if("windows"===i&&"plugins"in window.navigator)return null;var r={};return r.device=i,r.browser=Mr(e,Tr,"default"),r.name=Mr(i,Cr),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};var Dr=function(e){var t=null;var n=[];for(var i in Sr)if(Sr.hasOwnProperty(i)&&(n=e.match(Sr[i]))){(t={})[i]=!0,t[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,t.version=parseInt(document.documentMode||n[2],10);break}return t};var Er=kr()&&window.navigator?window.navigator.userAgent:null;var Ir=Er?Dr(Er):null;var zr=Er?Ar(Er):null;kr()&&window;Ir&&!Ir.chrome&&window.MSPointerEvent;Ir&&!Ir.chrome&&window.PointerEvent;var Pr={};Pr[void 0]=function(e){return e};var Lr={};Lr[void 0]=function(e){return e};var Br=/\/\*[\s\S]*?\*\//g;var Hr=/([^\s:;]+?)\s*:\s*((?:(?:url\(\s*(?:(?:[^"')\\]|\\.)*|"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*')\s*\)|"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|[^;"'])*?)\s*)(?=;|$)/gi;var Rr=/"|"|"/gi;var Fr=/'|'|'/gi;function Or(e){var t={};var n=(e||"").replace(Br,"").replace(Rr,'"').replace(Fr,"'");var i,r,o=Hr.exec(n);for(;null!==o;)i=o[1].trim(),r=o[2].trim(),t[i]=r,o=Hr.exec(n);return t}var Vr=function(){};var Nr=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;var r=this;var o=Ur(e);var a=$r(t);var s=o.length;if(void 0===t){for(var l in e)r.bind(l,e[l]);return this}var c=function(e){var s=o[e];var 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)}};for(var 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){var n=Ur(e);var i=$r(t);for(var r=0,o=n.length;r<o;r++){var a=n[r];var 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=Wr,t.isDefaultPrevented=jr,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}(Vr);function $r(e){return"function"==typeof e}function Ur(e){return"string"==typeof e?[e]:e}function Wr(){this._defaultPrevented=!0}function jr(){return!0===this._defaultPrevented}var qr=function(e){var t="undefined"!=typeof window?window:{};var n=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e){setTimeout(e,1e3/60)};qr=function(e){return n.call(t,e)},qr(e)};var Gr=qr;var Kr=/&/g;var Yr=/</g;var Qr=/"/g;var Xr=/'/g;var Zr=/>/g;function Jr(e){return String(e).replace(Kr,"&").replace(Yr,"<").replace(Zr,">").replace(Qr,""").replace(Xr,"'")}function eo(e){var t=window.console;void 0!==t&&t.log&&t.log(e)}function to(e){var t=e.dataURI;var n=e.fileName;var i=t;if("string"==typeof i&&window.Blob){var r=i.split(";base64,");var o=r[0];var a=atob(r[1]);var s=new Uint8Array(a.length);for(var 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 no=null;var io={get browser(){return"undefined"==typeof window||no||(no=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};var 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)),no}};var ro=Date.now||function(){return(new Date).getTime()};function oo(e,t){var n=0;var i;if(!t||t<=0)return e;var r=function(){var r=ro()-n;var o=arguments;var a=function(){e.apply(null,o),n=ro()};if(!n)return a();i&&clearTimeout(i),r>t?a():i=setTimeout(a,t-r)};return r.cancel=function(){clearTimeout(i)},r}var ao={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"};var so=io.browser;var lo=function(e){var t=Object.keys(ao);t.push("transparent");var n=new RegExp("^("+t.join("|")+")(\\W|$)","i");return lo=function(e){return n.exec(e)},n.exec(e)};var co=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 so.msie&&so.version<9?this.toCss():this.toCssRgba()},t.prototype.equals=function(e){return e===this||null!=e&&this.toCssRgba()===_o(e).toCssRgba()},t.prototype.diff=function(e){if(null===e)return NaN;var t=this.toBytes();var 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 uo(e.r,e.g,e.b,e.a)),e},t}(Vr);var ho=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=this;var t=e.r;var n=e.g;var i=e.b;var r=Math.min(t,n,i);var o=Math.max(t,n,i);var a=o-r;var s=o;var l,c;return 0===a?new fo(0,0,s,this.a):(0!==o?(c=a/o,l=t===o?(n-i)/a:n===o?2+(i-t)/a:4+(t-n)/a,(l*=60)<0&&(l+=360)):(c=0,l=-1),new fo(l,c,s,this.a))},t.prototype.toHSL=function(){var e=this;var t=e.r;var n=e.g;var i=e.b;var r=Math.max(t,n,i);var o=Math.min(t,n,i);var a,s,l=(r+o)/2;if(r===o)a=s=0;else{var c=r-o;switch(s=l>.5?c/(2-r-o):c/(r+o),r){case t:a=(n-i)/c+(n<i?6:0);break;case n:a=(i-t)/c+2;break;case i:a=(t-n)/c+4}}return new mo(60*a,100*s,100*l,this.a)},t.prototype.toBytes=function(){return new uo(255*this.r,255*this.g,255*this.b,this.a)},t}(co);var uo=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=po(this.r,2)+po(this.g,2)+po(this.b,2);return e&&e.alpha&&(t+=po(Math.round(255*this.a),2)),t},t.prototype.toBytes=function(){return this},t}(ho);function po(e,t,n){void 0===n&&(n="0");var i=e.toString(16);for(;t>i.length;)i=n+i;return i}var fo=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=this;var t=e.h;var n=e.s;var i=e.v;var r,o,a;if(0===n)r=o=a=i;else{t/=60;var s=Math.floor(t);var l=t-s;var c=i*(1-n);var d=i*(1-n*l);var h=i*(1-n*(1-l));switch(s){case 0:r=i,o=h,a=c;break;case 1:r=d,o=i,a=c;break;case 2:r=c,o=i,a=h;break;case 3:r=c,o=d,a=i;break;case 4:r=h,o=c,a=i;break;default:r=i,o=c,a=d}}return new ho(r,o,a,this.a)},t.prototype.toHSL=function(){return this.toRGB().toHSL()},t.prototype.toBytes=function(){return this.toRGB().toBytes()},t}(co);var mo=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=this.h/360;var t=this.s/100;var n=this.l/100;var i,r,o;if(0===t)i=r=o=n;else{var a=n<.5?n*(1+t):n+t-n*t;var s=2*n-a;i=go(s,a,e+1/3),r=go(s,a,e),o=go(s,a,e-1/3)}return new ho(i,r,o,this.a)},t.prototype.toHSV=function(){return this.toRGB().toHSV()},t.prototype.toBytes=function(){return this.toRGB().toBytes()},t}(co);function go(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 vo(e){return parseFloat(parseFloat(parseInt(e,16)/255).toFixed(3))}function _o(e,t){var n,i;if(!e||"none"===e)return null;if(e instanceof co)return e;var r=e.toLowerCase();if(n=lo(r))return(r="transparent"===n[1]?new ho(1,1,1,0):_o(ao[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 uo(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 uo(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 uo(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),vo(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 uo(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),vo(n[4])):(n=/^rgb\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/.exec(r))?i=new uo(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 uo(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 ho(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 ho(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 ho(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 bo=function(e){function t(n){var i=this;if(e.call(this),1===arguments.length){var r=t.formats;var o=this.resolveColor(n);for(var a=0;a<r.length;a++){var s=r[a].re;var l=r[a].process;var 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;var t=this.r.toString(16);var n=this.g.toString(16);var 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 uo(e,t,n,null!=i?i:1)},t.fromRGB=function(e,t,n,i){return new ho(e,t,n,null!=i?i:1)},t.fromHSV=function(e,t,n,i){return new fo(e,t,n,null!=i?i:1)},t.fromHSL=function(e,t,n,i){return new mo(e,t,n,null!=i?i:1)},t}(Vr);bo.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)]}}],bo.namedColors=ao;var wo=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();var 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}(Vr);function yo(e,t){return e.push.apply(e,t),e}var ko={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 xo(e){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];var n="";for(;e>0;)e<t[0]?t.shift():(n+=ko[t[0]],e-=t[0]);return n}function Co(){var e,t;var 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 So(e){return void 0!==e}var To=1;function Mo(){return"kdef"+To++}var Ao=Math.PI/180;var Do=Number.MAX_VALUE;var Eo=-Number.MAX_VALUE;function Io(e){return e/Ao}var zo=String.fromCharCode;function Po(e){return zo(e>>8)+zo(255&e)}var Lo="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function Bo(e){var t="";var n=0;var i=function(e){var t="";for(var n=0;n<e.length;n++){var i=e.charCodeAt(n);if(55296<=i&&i<=56319){var r=i;var o=e.charCodeAt(++n);isNaN(o)||(i=1024*(r-55296)+(o-56320)+65536)}i<128?t+=zo(i):i<2048?(t+=zo(192|i>>>6),t+=zo(128|63&i)):i<65536?(t+=zo(224|i>>>12),t+=zo(128|i>>>6&63),t+=zo(128|63&i)):i<1114111&&(t+=zo(240|i>>>18),t+=zo(128|i>>>12&63),t+=zo(128|i>>>6&63),t+=zo(128|63&i))}return t}(e);for(;n<i.length;){var r=i.charCodeAt(n++);var o=i.charCodeAt(n++);var a=i.charCodeAt(n++);var s=r>>2;var l=(3&r)<<4|o>>4;var c=(15&o)<<2|a>>6;var d=63&a;isNaN(o)?c=d=64:isNaN(a)&&(d=64),t=t+Lo.charAt(s)+Lo.charAt(l)+Lo.charAt(c)+Lo.charAt(d)}return t}function Ho(e){return So((e.x||{}).location)?{x:e.x.location,y:e.y.location}:{x:e.pageX||e.clientX||0,y:e.pageY||e.clientY||0}}function Ro(e){return void 0===e&&(e={}),e.touch?e.touch.initialTouch:e.target}function Fo(e){return""===e||null===e||"none"===e||"transparent"===e||!So(e)}function Oo(e){if(e)return e[e.length-1]}function Vo(e,t,n){return Math.max(Math.min(e,n),t)}function No(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);var r=n.slice(0,i);var o=n.slice(i);return function(e,n){var i=[],r=0,o=0,a=0;for(;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 $o(e){return Promise.all(e)}function Uo(e){return e*Ao}function Wo(e,t){var n=(i=t)?Math.pow(10,i):1;var i;return Math.round(e*n)/n}function jo(e,t){return So(e)?e:t}function qo(e,t){for(var n in t){var i=n.trim().split(" ");for(var r=0;r<i.length;r++)e.addEventListener(i[r],t[n],!1)}}function Go(e){var t=e.getBoundingClientRect();var 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){var n={};var i=window.getComputedStyle(e)||{};var r=Array.isArray(t)?t:[t];for(var o=0;o<r.length;o++){var a=r[o];n[a]=i[a]}return n}function Yo(e){return isNaN(e)?e:e+"px"}function Qo(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;var r=t.height;So(i)&&(e.style.width=Yo(i)),So(r)&&(e.style.height=Yo(r))}function Xo(e,t){for(var n in void 0===t&&(t={}),t){var i=n.trim().split(" ");for(var r=0;r<i.length;r++)e.removeEventListener(i[r],t[n],!1)}}function Zo(e){var t=Ko(e,["paddingLeft","paddingTop"]);var n=t.paddingLeft;var i=t.paddingTop;return{top:parseFloat(i),left:parseFloat(n)}}var Jo=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;var n=e.a;var i=e.b;var r=e.c;var o=e.d;var a=e.e;var s=e.f;var 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=Wo(this.a,e),this.b=Wo(this.b,e),this.c=Wo(this.c,e),this.d=Wo(this.d,e),this.e=Wo(this.e,e),this.f=Wo(this.f,e),this},t.prototype.toArray=function(e){var t=[this.a,this.b,this.c,this.d,this.e,this.f];if(So(e))for(var n=0;n<t.length;n++)t[n]=Wo(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(Uo(e)),r.b=Math.sin(Uo(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}(Vr);Jo.IDENTITY=Jo.unit();var ea=/matrix\((.*)\)/;function ta(e){var t=getComputedStyle(e).transform;return"none"===t?Jo.unit():function(e){var t=e.match(ea);if(null===t||2!==t.length)return Jo.unit();var n=t[1].split(",").map((function(e){return parseFloat(e)}));return new(Function.prototype.bind.apply(Jo,[null].concat(n)))}(t)}function na(e){if(!e)return Jo.unit();var t=ta(e);var n=e.parentElement;for(;n;){var i=ta(n);t=t.multiplyCopy(i),n=n.parentElement}return t.b=t.c=t.e=t.f=0,t}var ia=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;var 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}(Vr);var ra=/\r?\n|\r|\t/g;function oa(e){return String(e).replace(ra," ")}function aa(e){var t=[];for(var n in e)t.push(n+e[n]);return t.sort().join("")}function sa(e){var t=2166136261;for(var 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 la={baselineMarkerSize:1};var ca;"undefined"!=typeof document&&((ca=document.createElement("div")).style.setProperty("position","absolute","important"),ca.style.setProperty("top","-4000px","important"),ca.style.setProperty("width","auto","important"),ca.style.setProperty("height","auto","important"),ca.style.setProperty("padding","0","important"),ca.style.setProperty("margin","0","important"),ca.style.setProperty("border","0","important"),ca.style.setProperty("line-height","normal","important"),ca.style.setProperty("visibility","hidden","important"),ca.style.setProperty("white-space","pre","important"));var da=function(e){function t(t){e.call(this),this._cache=new ia(1e3),this.options=Object.assign({},la,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=sa(e+aa(t));var r=this._cache.get(i);if(r)return r;var o={width:0,height:0,baseline:0};var a=n.box||ca;var 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?oa(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}(Vr);function ha(e,t,n){return da.current.measure(e,t,n)}da.current=new da;var ua=Object.freeze({__proto__:null,DEG_TO_RAD:Ao,LRUCache:ia,MAX_NUM:Do,MIN_NUM:Eo,TextMetrics:da,append:yo,arabicToRoman:xo,bindEvents:qo,createPromise:Co,defined:So,definitionId:Mo,deg:Io,elementOffset:Go,elementPadding:Zo,elementScale:na,elementSize:Qo,elementStyles:Ko,encodeBase64:Bo,eventCoordinates:Ho,eventElement:Ro,hashKey:sa,isTransparent:Fo,last:Oo,limitValue:Vo,measureText:ha,mergeSort:No,normalizeText:oa,now:ro,objectKey:aa,promiseAll:$o,rad:Uo,round:Wo,unbindEvents:Xo,valueOrDefault:jo});var pa={}.toString;var fa=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){var t=e.split(".");var n=this;for(;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;var r=this;var o=e;if(i){var a=o.split(".");var s=this.prefix;for(;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=pa.call(e);var r=e;return null!==r&&So(r)&&"[object Object]"===i&&(e instanceof t||e instanceof Vr||(r=new t(r,this.prefix+n+".")),r.addObserver(this)),r},t}(wo);function ma(e){return function(t){return this[e]!==t&&(this[e]=t,this.geometryChange()),this}}function ga(e){return function(){return this[e]}}var va=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];var r=i.charAt(0).toUpperCase()+i.substring(1,i.length);e["set"+r]=ma(i),e["get"+r]=ga(i)}}(n.prototype,t),n};function _a(e){return e&&"function"==typeof e.matrix?e.matrix():e}var ba=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(Jo.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=_a(e);var n=this.x;var 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;var n=this.y-e.y;return Math.sqrt(t*t+n*n)},t.prototype.round=function(e){return this.x=Wo(this.x,e),this.y=Wo(this.y,e),this.geometryChange(),this},t.prototype.toArray=function(e){var t=So(e);return[t?Wo(this.x,e):this.x,t?Wo(this.y,e):this.y]},t.prototype.toString=function(e,t){void 0===t&&(t=" ");var n=this.x;var i=this.y;return So(e)&&(n=Wo(n,e),i=Wo(i,e)),n+t+i},t.create=function(e,n){if(So(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(){var e=arguments;var n=Do;var i=Do;for(var 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(){var e=arguments;var n=Eo;var i=Eo;for(var 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(Eo,Eo)},t.maxPoint=function(){return new t(Do,Do)},n.ZERO.get=function(){return new t(0,0)},Object.defineProperties(t,n),t}(va(wo,["x","y"]));var wa=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=So(e);return[t?Wo(this.width,e):this.width,t?Wo(this.height,e):this.height]},t.create=function(e,n){if(So(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}(va(wo,["width","height"]));var ya=function(e){function t(t,n,i){void 0===t&&(t=new ba),void 0===n&&(n=new wa),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",ba.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",wa.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);var i=this.topRight().transformCopy(e);var r=this.bottomRight().transformCopy(e);var 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;var 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);var i=this.expandCopy(-t,-t);return n.containsPoint(e)&&!i.containsPoint(e)},t.fromPoints=function(){var e=ba.min.apply(null,arguments);var n=ba.max.apply(null,arguments);return new t(e,new wa(n.x-e.x,n.y-e.y))},t.union=function(e,n){return t.fromPoints(ba.min(e.topLeft(),n.topLeft()),ba.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};var 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 ba(Math.max(i.left,r.left),Math.max(i.top,r.top)),new ba(Math.min(i.right,r.right),Math.min(i.bottom,r.bottom)))},t}(wo);var ka=function(e){function t(t){void 0===t&&(t=Jo.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(Jo.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=ba.create(i),this._matrix=this._matrix.multiplyCopy(Jo.translate(i.x,i.y))),this._matrix=this._matrix.multiplyCopy(Jo.scale(e,t)),i&&(this._matrix=this._matrix.multiplyCopy(Jo.translate(-i.x,-i.y))),this._optionsChange(),this},t.prototype.rotate=function(e,t){var n=ba.create(t)||ba.ZERO;return this._matrix=this._matrix.multiplyCopy(Jo.rotate(e,n.x,n.y)),this._optionsChange(),this},t.prototype.multiply=function(e){var t=_a(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}(wo);function xa(e){return null===e?null:e instanceof ka?e:new ka(e)}var Ca={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]};var Sa="solid";var Ta="butt";var Ma="Pattern";var Aa=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;var n=e.transform;n&&(e.transform=xa(n)),t&&!t.id&&(t.id=Mo()),this.options=new fa(e),this.options.addObserver(this)},t.prototype.transform=function(e){if(!So(e))return this.options.get("transform");this.options.set("transform",xa(e))},t.prototype.parentTransform=function(){var e=this;var t;for(;e.parent;){var n=(e=e.parent).transform();n&&(t=n.matrix().multiplyCopy(t||Jo.unit()))}if(t)return xa(t)},t.prototype.currentTransform=function(e){void 0===e&&(e=this.parentTransform());var t=_a(this.transform());var n=_a(e);var i;if(i=t&&n?n.multiplyCopy(t):t||n)return xa(i)},t.prototype.visible=function(e){return So(e)?(this.options.set("visible",e),this):!1!==this.options.get("visible")},t.prototype.clip=function(e){var t=this.options;return So(e)?(e&&!e.id&&(e.id=Mo()),t.set("clip",e),this):t.get("clip")},t.prototype.opacity=function(e){return So(e)?(this.options.set("opacity",e),this):jo(this.options.get("opacity"),1)},t.prototype.className=function(e){return So(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?ya.intersect(t,n.bbox(e)):t}},t.prototype.containsPoint=function(e,t){if(this.visible()){var n=this.currentTransform(t);var 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===Ma||!Fo(e.color))},t.prototype._hasStroke=function(){var e=this.options.stroke;return e&&e.width>0&&!Fo(e.color)},t.prototype._clippedBBox=function(e){return this.bbox(e)},Object.defineProperties(t.prototype,n),t}(wo);function Da(e,t,n,i){var r=0;var 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 Ea=Math.PI/2;var Ia=function(e){function t(t,n){void 0===t&&(t=new ba),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",ba.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(Uo(e))},t.prototype.bbox=function(e){var t=Da(this.center,this.radius,this.radius,e);var n=ba.maxPoint();var i=ba.minPoint();for(var r=0;r<4;r++){var o=this._pointAt(t.x+r*Ea).transformCopy(e);var a=this._pointAt(t.y+r*Ea).transformCopy(e);var s=new ba(o.x,a.y);n=ba.min(n,s),i=ba.max(i,s)}return ya.fromPoints(n,i)},t.prototype._pointAt=function(e){var t=this.center;var n=this.radius;return new ba(t.x+n*Math.cos(e),t.y+n*Math.sin(e))},t.prototype.containsPoint=function(e){var t=this.center;var 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;var i=this.radius;var r=n.distanceTo(e);return i-t<=r&&r<=i+t},t}(va(wo,["radius"]));var za=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(So(e)){if(e&&"Gradient"!==e.nodeType){var i={color:e};So(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 So(e)?(this.options.set("stroke.color",e),So(t)&&this.options.set("stroke.width",t),So(n)&&this.options.set("stroke.opacity",n),this):this.options.get("stroke")},t}(e)};var Pa=Jo.IDENTITY.toString();var 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=_a(this.currentTransform(e));var n=t?t.toString():Pa;var i;this._bboxCache&&this._matrixHash===n?i=this._bboxCache.clone():(i=this._bbox(t),this._bboxCache=i?i.clone():null,this._matrixHash=n);var r=this.options.get("stroke.width");return r&&i&&i.expand(r/2),i},t.prototype.geometryChange=function(){delete this._bboxCache,this.trigger("geometryChange",{element:this})},t}(e)};function Ba(e){var t="_"+e;return function(e){return So(e)?(this._observerField(t,e),this.geometryChange(),this):this[t]}}var Ha=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]]=Ba(t[n])}(n.prototype,t),n};var Ra=function(e){function t(t,n){void 0===t&&(t=new Ia),void 0===n&&(n={}),e.call(this,n),this.geometry(t),So(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}(za(La(Ha(Aa))));var Fa=10;function Oa(e,t,n){return void 0===n&&(n=Fa),0===Wo(Math.abs(e-t),n)}function Va(e,t,n){return e<t||Oa(e,t,n)}var Na=Math.pow;var $a=function(e){function t(t,n){void 0===t&&(t=new ba),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",ba.create(e)),this.geometryChange(),this},t.prototype.getCenter=function(){return this.center},t.prototype.pointAt=function(e){var t=this.center;var n=Uo(e);return new ba(t.x+this.radiusX*Math.cos(n),t.y+this.radiusY*Math.sin(n))},t.prototype.curvePoints=function(){var e=this.startAngle;var t=this.anticlockwise?-1:1;var n=[this.pointAt(e)];var i=this._arcInterval();var r=i.endAngle-i.startAngle;var o=Math.ceil(r/45);var a=r/o;var s=e;var l;this.xRotation&&(l=xa().rotate(this.xRotation,this.center));for(var c=1;c<=o;c++){var d=s+t*a;var h=this._intervalCurvePoints(s,d,l);n.push(h.cp1,h.cp2,h.p2),s=d}return n},t.prototype.bbox=function(e){var t=this._arcInterval();var n=t.startAngle;var i=t.endAngle;var r=Da(this.center,this.radiusX,this.radiusY,e);var o=Io(r.x);var a=Io(r.y);var s=this.pointAt(i).transformCopy(e);var l=Wa(o,n);var c=Wa(a,n);var d=this.pointAt(n).transformCopy(e);var h=ba.min(d,s);var u=ba.max(d,s);for(;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 ba(p.x,f.y),h=ba.min(h,d),u=ba.max(u,d)}return ya.fromPoints(h,u)},t.prototype._arcInterval=function(){var e=this;var t=e.startAngle;var n=e.endAngle;var 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);var r=this.pointAt(t);var o=this._derivativeAt(e);var a=this._derivativeAt(t);var s=(Uo(t)-Uo(e))/3;var l=new ba(i.x+s*o.x,i.y+s*o.y);var c=new ba(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=Uo(e);return new ba(-this.radiusX*Math.sin(t),this.radiusY*Math.cos(t))},t.prototype.containsPoint=function(e){var t=this._arcInterval();var n=t.endAngle-t.startAngle;var i=this;var r=i.center;var o=i.radiusX;var a=i.radiusY;var s=r.distanceTo(e);var l=Math.atan2(e.y-r.y,e.x-r.x);var c=o*a/Math.sqrt(Na(o,2)*Na(Math.sin(l),2)+Na(a,2)*Na(Math.cos(l),2));var d=this.pointAt(this.startAngle).round(Fa);var h=this.pointAt(this.endAngle).round(Fa);var u=function(e,t,n,i){var r=t.x-e.x;var o=i.x-n.x;var a=t.y-e.y;var s=i.y-n.y;var l=e.x-n.x;var c=e.y-n.y;var d=r*s-o*a;var h=(r*c-a*l)/d;var u=(o*c-s*l)/d;if(h>=0&&h<=1&&u>=0&&u<=1)return new ba(e.x+u*r,e.y+u*a)}(r,e.round(Fa),d,h);var p;if(n<180)p=u&&Va(r.distanceTo(u),s)&&Va(s,c);else{var f=Ua(r.x,r.y,o,a,e.x,e.y);360!==f&&(f=(360+f)%360);var m=t.startAngle<=f&&f<=t.endAngle;p=m&&Va(s,c)||!m&&(!u||u.equals(e))}return p},t.prototype._isOnPath=function(e,t){var n=this._arcInterval();var i=this.center;var r=Ua(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;var n=e.y1;var i=e.x2;var r=e.y2;var o=e.rx;var a=e.ry;var s=e.largeArc;var l=e.swipe;var c=e.rotation;void 0===c&&(c=0);var d=Uo(c);var h=Math.cos(d);var u=Math.sin(d);var p=h*(t-i)/2+u*(n-r)/2;var f=-u*(t-i)/2+h*(n-r)/2;var m=s!==l?1:-1;var g=Math.pow(p,2);var v=Math.pow(f,2);var _=Math.pow(o,2);var b=Math.pow(a,2);var w=g/_+v/b;w>1&&(o*=w=Math.sqrt(g/_+v/b),_=Math.pow(o,2),a*=w,b=Math.pow(a,2));var y=m*Math.sqrt((_*b-_*v-b*g)/(_*v+b*g));isNaN(y)&&(y=0);var k=y*(o*f)/a;var x=a*p*-y/o;var C=h*k-u*x+(t+i)/2;var S=u*k+h*x+(n+r)/2;var T=(p-k)/o;var M=(f-x)/a;var A=-(p+k)/o;var D=-(f+x)/a;var E=(M>=0?1:-1)*Io(Math.acos(T/Math.sqrt(T*T+M*M)));var I=Wo((T*A+M*D)/(Math.sqrt(T*T+M*M)*Math.sqrt(A*A+D*D)),10);var z=(T*D-M*A>=0?1:-1)*Io(Math.acos(I));!l&&z>0&&(z-=360);l&&z<0&&(z+=360);var P=E+z;var L=P>=0?1:-1;return P=Math.abs(P)%360*L,{center:new ba(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}(va(wo,["radiusX","radiusY","startAngle","endAngle","anticlockwise"]));function Ua(e,t,n,i,r,o){var a=Wo((r-e)/n,3);var s=Wo((o-t)/i,3);return Wo(Io(Math.atan2(s,a)))}function Wa(e,t){var n=e;for(;n<t;)n+=90;return n}var ja=[].push;var qa=[].pop;var Ga=[].splice;var Ka=[].shift;var Ya=[].slice;var Qa=[].unshift;var Xa=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;var t=ja.apply(this,e);return this._add(e),t},t.prototype.slice=function(){return Ya.call(this)},t.prototype.pop=function(){var e=this.length;var t=qa.apply(this);return e&&this._remove([t]),t},t.prototype.splice=function(e,t){var n=Ya.call(arguments,2);var i=this._splice(e,t,n);return this._change(),i},t.prototype.shift=function(){var e=this.length;var t=Ka.apply(this);return e&&this._remove([t]),t},t.prototype.unshift=function(){var e=arguments;var t=Qa.apply(this,e);return this._add(e),t},t.prototype.indexOf=function(e){var t=this.length;for(var n=0;n<t;n++)if(this[n]===e)return n;return-1},t.prototype._splice=function(e,t,n){var i=Ga.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}(wo);var Za=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}(Xa);function Ja(e,t,n){var i=Io(Math.atan2(t.y-e.y,t.x-e.x));return n.transformCopy(xa().rotate(-i,e)).x<e.x}function es(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 ts(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 ns=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(Wo(this.real+e.real,Fa),Wo(this.img+e.img,Fa))},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);var i=Math.sqrt(Math.pow(this.img,2)+Math.pow(this.real,2));var 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}(Vr);function is(e){return e<0?-1:1}function rs(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=(3*e*n-Math.pow(t,2))/(3*Math.pow(e,2));var o=(2*Math.pow(t,3)-9*e*t*n+27*Math.pow(e,2)*i)/(27*Math.pow(e,3));var a=Math.pow(r/3,3)+Math.pow(o/2,2);var s=new ns(0,1);var l=-t/(3*e);var c,d,h,u,p,f,m;a<0?(c=new ns(-o/2,Math.sqrt(-a)).nthRoot(3),d=new ns(-o/2,-Math.sqrt(-a)).nthRoot(3)):(c=-o/2+Math.sqrt(a),c=new ns(is(c)*Math.pow(Math.abs(c),1/3)),d=-o/2-Math.sqrt(a),d=new ns(is(d)*Math.pow(Math.abs(d),1/3))),h=c.add(d),f=c.add(d).multiplyConstant(-.5),m=c.add(d.negate()).multiplyConstant(Math.sqrt(3)/2),u=f.add(s.multiply(m)),p=f.add(s.negate().multiply(m));var g=[];return h.isReal()&&g.push(Wo(h.real+l,Fa)),u.isReal()&&g.push(Wo(u.real+l,Fa)),p.isReal()&&g.push(Wo(p.real+l,Fa)),g}function os(e,t,n,i,r){var o=ts(e,i);var a=rs(o[0],o[1],o[2],o[3]-t[i]);var s;for(var l=0;l<a.length;l++)if(0<=a[l]&&a[l]<=1&&(s=es(a[l],n,e),Math.abs(s-t[n])<=r))return!0}function as(e,t,n){var i;if(e.x!==t.x){var r=Math.min(e.x,t.x);var o=Math.max(e.x,t.x);var a=Math.min(e.y,t.y);var s=Math.max(e.y,t.y);var 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 ss(e){var t="_"+e;return function(e){return So(e)?(this._observerField(t,ba.create(e)),this.geometryChange(),this):this[t]}}var ls=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]]=ss(t[n])}(n.prototype,t),n};var cs=function(e){function t(t,n,i){e.call(this),this.anchor(t||new ba),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);var 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 ya.fromPoints(e,t)},t.prototype._curveBoundingBox=function(e,t,n,i){var r=[e,t,n,i];var o=this._curveExtremesFor(r,"x");var a=this._curveExtremesFor(r,"y");var s=ds([o.min,o.max,e.x,i.x]);var l=ds([a.min,a.max,e.y,i.y]);return ya.fromPoints(new ba(s.min,l.min),new ba(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:es(n.min,t,e),max:es(n.max,t,e)}},t.prototype._curveExtremes=function(e,t,n,i){var r=e-3*t+3*n-i;var o=-2*(e-2*t+n);var a=e-t;var s=Math.sqrt(o*o-4*r*a);var l=0;var 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 h=Math.min(Math.max(l,c),1);return(h>1||h<0)&&(h=1),{min:d,max:h}},t.prototype._intersectionsTo=function(e,t){var n;return n=this.controlOut()&&e.controlIn()?function(e,t,n){var i=ts(e,"x");var r=rs(i[0],i[1],i[2],i[3]-t.x);var o;var a=0;for(var s=0;s<r.length;s++)(Oa(o=es(r[s],"y",e),t.y)||o>t.y)&&((0===r[s]||1===r[s])&&n.bottomRight().x>t.x||0<r[s]&&r[s]<1)&&a++;return a}([this.anchor(),this.controlOut(),e.controlIn(),e.anchor()],t,this.bboxTo(e)):as(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();var o=this.controlOut();var a=e.controlIn();var s=e.anchor();if("start"===i&&r.distanceTo(t)<=n)return!Ja(r,o,t);if("end"===i&&s.distanceTo(t)<=n)return!Ja(s,a,t);var l=[r,o,a,s];if(os(l,t,"x","y",n)||os(l,t,"y","x",n))return!0;var c=xa().rotate(45,t);var d=[r.transformCopy(c),o.transformCopy(c),a.transformCopy(c),s.transformCopy(c)];return os(d,t,"x","y",n)||os(d,t,"y","x",n)}},t.prototype._isOnLineTo=function(e,t,n){var i=this.anchor();var r=e.anchor();var o=Io(Math.atan2(r.y-i.y,r.x-i.x));return new ya([i.x,i.y-n/2],[i.distanceTo(r),n]).containsPoint(t.transformCopy(xa().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}(ls(wo,["anchor","controlIn","controlOut"]));function ds(e){var t=e.length;var n=Do;var i=Eo;for(var r=0;r<t;r++)i=Math.max(i,e[r]),n=Math.min(n,e[r]);return{min:n,max:i}}var hs=Object.freeze({__proto__:null,Arc:$a,Circle:Ia,Matrix:Jo,Point:ba,Rect:ya,Segment:cs,Size:wa,Transformation:ka,toMatrix:_a,transform:xa});var us="x";var ps="y";function fs(e,t){var n=e.slice(0);var i=[];var r=n.length;if(r>2&&(ms(0,n),r=n.length),r<2||2===r&&n[0].equals(n[1]))return i;var o=n[0];var a=n[1];var s=n[2];for(i.push(new cs(o));o.equals(n[r-1]);)t=!0,n.pop(),r--;if(2===r){var l=bs(o,a,us,ps);return Oo(i).controlOut(ys(l,o,a,us,ps)),i.push(new cs(a,ks(l,o,a,us,ps))),i}var c,d;if(t){var h=vs(o=n[r-1],a=n[0],s=n[1]);c=h[1],d=h[0]}else{c=ys(bs(o,a,us,ps),o,a,us,ps)}var u=c;for(var p=0;p<=r-3;p++)if(ms(p,n),p+3<=(r=n.length)){var f=vs(o=n[p],a=n[p+1],s=n[p+2]);Oo(i).controlOut(u),u=f[1];var m=f[0];i.push(new cs(a,m))}if(t){var g=vs(o=n[r-2],a=n[r-1],s=n[0]);Oo(i).controlOut(u),i.push(new cs(a,g[0])),Oo(i).controlOut(g[1]),i.push(new cs(s,d))}else{var v=bs(a,s,us,ps);Oo(i).controlOut(u),i.push(new cs(s,ks(v,a,s,us,ps)))}return i}function ms(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 gs(e,t){var n=(t.y-e.y)/(t.x-e.x);return[e.y-n*e.x,n]}function vs(e,t,n){var i=us;var r=ps;var o=!1;var a=!1;var s;if(function(e,t,n){var i=Cs(gs(e,t),n.x);return e.x===t.x&&t.x===n.x||Wo(i,1)===Wo(n.y,1)}(e,t,n))s=bs(e,t,us,ps);else{var l={x:ws(e,t,n,us),y:ws(e,t,n,ps)};if(l.x&&l.y)s=bs(e,n,us,ps),o=!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=Cs(gs(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)&&(i=ps,r=us),l[i])s=0;else s=.01*(n[r]<e[r]&&e[r]<=t[r]||e[r]<n[r]&&t[r]<=e[r]?Ss((n[r]-e[r])*(t[i]-e[i])):-Ss((n[i]-e[i])*(t[r]-e[r]))),a=!0}var c=ks(s,e,t,i,r);if(a){var d=i;i=r,r=d}var h=ys(s,t,n,i,r);return o&&(_s(e,t,c,s),_s(t,n,h,s)),[c,h]}function _s(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 bs(e,t,n,i){var r=t[n]-e[n];var o=t[i]-e[i];return 0===r?0:o/r}function ws(e,t,n,i){return n[i]>t[i]&&t[i]>e[i]||n[i]<t[i]&&t[i]<e[i]}function ys(e,t,n,i,r){var o=t[i];var a=.333*(n[i]-o);return xs(o+a,t[r]+a*e,i,r)}function ks(e,t,n,i,r){var o=t[i];var a=n[i];var s=.333*(a-o);return xs(a-s,n[r]-s*e,i,r)}function xs(e,t,n,i){var r=new ba;return r[n]=e,r[i]=t,r}function Cs(e,t){var n=e.length;var i=0;for(var r=0;r<n;r++)i+=Math.pow(t,r)*e[r];return i}function Ss(e){return e<=0?-1:1}var Ts={l:function(e,t){var n=t.parameters;var i=t.position;for(var r=0;r<n.length;r+=2){var o=new ba(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){var n=t.parameters;var i=t.position;for(var r=0;r<n.length;r+=6){var o=new ba(n[r],n[r+1]);var a=new ba(n[r+2],n[r+3]);var s=new ba(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;Ms(t.parameters,!0,n),this.l(e,t)},h:function(e,t){var n=t.isRelative?0:t.position.y;Ms(t.parameters,!1,n),this.l(e,t)},a:function(e,t){var n=t.parameters;var i=t.position;for(var r=0;r<n.length;r+=7){var o=n[r];var a=n[r+1];var s=n[r+2];var l=n[r+3];var c=n[r+4];var d=new ba(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=t.parameters;var i=t.position;var r=t.previousCommand;var o;"s"!==r&&"c"!==r||(o=Oo(Oo(e.paths).segments).controlIn());for(var a=0;a<n.length;a+=4){var s=new ba(n[a],n[a+1]);var l=new ba(n[a+2],n[a+3]);var c=void 0;t.isRelative&&(s.translateWith(i),l.translateWith(i)),c=o?As(o,i):i.clone(),o=s,e.curveTo(c,s,l),i.x=l.x,i.y=l.y}},q:function(e,t){var n=t.parameters;var i=t.position;for(var r=0;r<n.length;r+=4){var o=new ba(n[r],n[r+1]);var a=new ba(n[r+2],n[r+3]);t.isRelative&&(o.translateWith(i),a.translateWith(i));var s=Es(i,o,a);e.curveTo(s.controlOut,s.controlIn,a),i.x=a.x,i.y=a.y}},t:function(e,t){var n=t.parameters;var i=t.position;var r=t.previousCommand;var o;"q"!==r&&"t"!==r||(o=Oo(Oo(e.paths).segments).controlIn().clone().translateWith(i.scaleCopy(-1/3)).scale(1.5));for(var a=0;a<n.length;a+=2){var s=new ba(n[a],n[a+1]);t.isRelative&&s.translateWith(i),o=o?As(o,i):i.clone();var l=Es(i,o,s);e.curveTo(l.controlOut,l.controlIn,s),i.x=s.x,i.y=s.y}}};function Ms(e,t,n){var i=t?0:1;for(var r=0;r<e.length;r+=2)e.splice(r+i,0,n)}function As(e,t){if(e&&t)return t.scaleCopy(2).translate(-e.x,-e.y)}var Ds=1/3;function Es(e,t,n){var i=t.clone().scale(2/3);return{controlOut:i.clone().translateWith(e.scaleCopy(Ds)),controlIn:i.translateWith(n.scaleCopy(Ds))}}var Is=/([a-df-z]{1})([^a-df-z]*)(z)?/gi;var zs=/[,\s]?([+\-]?(?:\d*\.\d+|\d+)(?:[eE][+\-]?\d+)?)/g;function Ps(e,t){var n=new ba;var i;return t.replace(Is,(function(t,r,o,a){var s=r.toLowerCase();var l=s===r;var c=function(e){var t=[];return e.replace(zs,(function(e,n){t.push(parseFloat(n))})),t}(o.trim());if("m"===s&&(l?(n.x+=c[0],n.y+=c[1]):(n.x=c[0],n.y=c[1]),e.moveTo(n.x,n.y),c.length>2&&(s="l",c.splice(0,2))),Ts[s])Ts[s](e,{parameters:c,position:n,isRelative:l,previousCommand:i}),a&&"z"===a.toLowerCase()&&e.close();else if("m"!==s)throw new Error("Error while parsing SVG path. Unsupported command: "+s);i=s})),e}function Ls(e,t,n){var i;for(var r=0;r<e.length;r++){var o=e[r];if(o.visible()){var a=t?o.bbox(n):o.rawBBox();a&&(i=i?ya.union(i,a):a)}}return i}function Bs(e,t){var n;for(var i=0;i<e.length;i++){var r=e[i];if(r.visible()){var o=r.clippedBBox(t);o&&(n=n?ya.union(n,o):o)}}return n}var Hs=" ";var Rs=function(e){function t(t){e.call(this,t),this.segments=new Za,this.segments.addObserver(this),So(this.options.stroke)||(this.stroke("#000"),So(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=So(t)?new ba(e,t):e;var i=new cs(n);return this.segments.push(i),this},t.prototype.curveTo=function(e,t,n){if(this.segments.length>0){var i=Oo(this.segments);var r=new cs(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=Oo(this.segments).anchor();var a=Uo(e);var s=new ba(o.x-n*Math.cos(a),o.y-i*Math.sin(a));var l=new $a(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=Oo(this.segments).anchor();var s=$a.fromPoints(a,ba.create(e),t,n,i,r,o);this._addArcSegments(s)}return this},t.prototype._addArcSegments=function(e){this.suspend();var t=e.curvePoints();for(var 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="";var n=this.segments;var i=n.length;if(i>0){var r=[];var o=(h=e,function(){var e=[],t=arguments.length;for(;t--;)e[t]=arguments[t];return e.map((function(e){return e.toString(h)})).join(Hs)});var a;for(var s=1;s<i;s++){var l=(c=n[s-1],d=n[s],c.controlOut()&&d.controlIn()?"C":"L");l!==a&&(a=l,r.push(l)),"L"===l?r.push(o(n[s].anchor())):r.push(o(n[s-1].controlOut(),n[s].controlIn(),n[s].anchor()))}t="M"+o(n[0].anchor())+Hs+r.join(Hs),this.options.closed&&(t+="Z")}var c,d;var h;return t},t.prototype._containsPoint=function(e){var t=this.segments;var n=t.length;var i=0;var r,o;for(var a=1;a<n;a++)r=t[a-1],o=t[a],i+=r._intersectionsTo(o,e);return!this.options.closed&&t[0].anchor().equals(t[n-1].anchor())||(i+=as(t[0].anchor(),t[n-1].anchor(),e)),i%2!=0},t.prototype._isOnPath=function(e,t){var n=this.segments;var i=n.length;var 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=this.segments;var n=t.length;var i;if(1===n){var r=t[0].anchor().transformCopy(e);i=new ya(r,wa.ZERO)}else if(n>0)for(var o=1;o<n;o++){var a=t[o-1].bboxTo(t[o],e);i=i?ya.union(i,a):a}return i},t.parse=function(e,t){return Fs.parse(e,t)},t.fromRect=function(e,n){var i=new t(n);var r=e.cornerRadius;var o=r[0];var 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;var l=s.x;var c=s.y;var d=e.width();var h=e.height();o=Vo(o,0,d/2),a=Vo(a,0,h/2),i.moveTo(l+o,c).lineTo(l+d-o,c).arcTo([l+d,c+a],o,a,!1).lineTo(l+d,c+h-a).arcTo([l+d-o,c+h],o,a,!1).lineTo(l+o,c+h).arcTo([l,c+h-a],o,a,!1).lineTo(l,c+a).arcTo([l+o,c],o,a,!1)}return i},t.fromPoints=function(e,n){if(e){var i=new t(n);for(var r=0;r<e.length;r++){var o=ba.create(e[r]);o&&(0===r?i.moveTo(o):i.lineTo(o))}return i}},t.curveFromPoints=function(e,n){if(e){var i=fs(e);var r=new t(n);return r.segments.push.apply(r.segments,i),r}},t.fromArc=function(e,n){var i=new t(n);var r=e.startAngle;var 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}(za(La(Aa)));var Fs=function(e){function t(t){e.call(this,t),this.paths=new Za,this.paths.addObserver(this),So(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 Ps(new t(n),e)},t.prototype.toString=function(e){var t=this.paths;var n="";if(t.length>0){var i=[];for(var r=0;r<t.length;r++)i.push(t[r].toString(e));n=i.join(Hs)}return n},n.nodeType.get=function(){return"MultiPath"},t.prototype.moveTo=function(e,t){var n=new Rs;return n.moveTo(e,t),this.paths.push(n),this},t.prototype.lineTo=function(e,t){return this.paths.length>0&&Oo(this.paths).lineTo(e,t),this},t.prototype.curveTo=function(e,t,n){return this.paths.length>0&&Oo(this.paths).curveTo(e,t,n),this},t.prototype.arc=function(e,t,n,i,r){return this.paths.length>0&&Oo(this.paths).arc(e,t,n,i,r),this},t.prototype.arcTo=function(e,t,n,i,r,o){return this.paths.length>0&&Oo(this.paths).arcTo(e,t,n,i,r,o),this},t.prototype.close=function(){return this.paths.length>0&&Oo(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){var t=this.paths;for(var n=0;n<t.length;n++)if(t[n]._containsPoint(e))return!0;return!1},t.prototype._isOnPath=function(e){var t=this.paths;var n=this.options.stroke.width;for(var i=0;i<t.length;i++)if(t[i]._isOnPath(e,n))return!0;return!1},t.prototype._clippedBBox=function(e){return Bs(this.paths,this.currentTransform(e))},Object.defineProperties(t.prototype,n),t}(za(La(Aa)));var Os=function(e){function t(t,n){void 0===t&&(t=new $a),void 0===n&&(n={}),e.call(this,n),this.geometry(t),So(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 Rs;var 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}(za(La(Ha(Aa))));var Vs=function(e){function t(t,n,i){void 0===n&&(n=new ba),void 0===i&&(i={}),e.call(this,i),this.content(t),this.position(n),this.options.font||(this.options.font="12px sans-serif"),So(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 So(e)?(this.options.set("content",e),this):this.options.get("content")},t.prototype.measure=function(){return ha(this.content(),{font:this.options.get("font")})},t.prototype.rect=function(){var e=this.measure();var t=this.position().clone();return new ya(t,[e.width,e.height])},t.prototype.bbox=function(e){var t=_a(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}(za(ls(Aa,["position"])));var Ns=function(e){function t(t,n,i){void 0===n&&(n=new ya),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 So(e)?(this.options.set("src",e),this):this.options.get("src")},t.prototype.bbox=function(e){var t=_a(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}(Ha(Aa,["rect"]));var $s=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){var n=this[t];for(var i=0;i<n.length;i++){var r=n[i];r.traverse?r.traverse(e):e(r)}return this},n}(e)};var Us=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 yo(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 Bs(this.children,this.currentTransform(e))},t.prototype.currentTransform=function(e){return Aa.prototype.currentTransform.call(this,e)||null},t.prototype.containsPoint=function(e,t){if(this.visible()){var n=this.children;var i=this.currentTransform(t);for(var 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];var r=i.parent;r&&r!==this&&r.remove&&r.remove(i),i.parent=t}},Object.defineProperties(t.prototype,n),t}($s(Aa,"children"));function Ws(e,t,n){var i=n.transform()||xa();var r=i.matrix();r.e+=e.x-t.origin.x,r.f+=e.y-t.origin.y,i.matrix(r),n.transform(i)}function js(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 qs(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 Gs={alignContent:"start",justifyContent:"start",alignItems:"start",spacing:0,orientation:"horizontal",lineSpacing:0,wrap:!0,revers:!1};var Ks=function(e,t){e.forEach(t)};var Ys=function(e,t){for(var n=e.length-1;n>=0;n--)t(e[n],n)};var Qs=function(e){function t(t,n){e.call(this,Object.assign({},Gs,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;var 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=Ys,this.justifyAlign=qs):(this.forEach=Ks,this.justifyAlign=js)},t.prototype.reflow=function(){if(this._rect&&0!==this.children.length){this._initMap(),this.options.transform&&this.transform(null);var e=this.options;var t=this._rect;var n=this._initGroups();var i=n.groups;var r=n.groupsSize;var o=this._fieldMap;var a=o.sizeField;var s=o.groupsSizeField;var l=o.groupAxis;var c=o.groupsAxis;var d=new ba;var h=new ba;var u=new wa;var p=js(r,t,e.alignContent,c,s);var f,m,g;var v=function(t,n){var i=m.elements[n];h[l]=f,h[c]=js(t.size[s],g,e.alignItems,c,s),Ws(h,t,i),f+=t.size[a]+e.spacing};for(var _=0;_<i.length;_++)m=i[_],d[l]=f=this.justifyAlign(m.size,t,e.justifyContent,l,a),d[c]=p,u[a]=m.size,u[s]=m.lineSize,g=new ya(d,u),this.forEach(m.bboxes,v),p+=m.lineSize+e.lineSpacing;if(!e.wrap&&m.size>t.size[a]){var b=t.size[a]/g.size[a];var w=g.topLeft().scale(b,b);var y=js(g.size[s]*b,t,e.alignContent,c,s);var k=xa();"x"===l?k.translate(t.origin.x-w.x,y-w.y):k.translate(y-w.x,t.origin.y-w.y),k.scale(b,b),this.transform(k)}}},t.prototype._initGroups=function(){var e=this;var t=this.options;var n=this.children;var i=t.lineSpacing;var r=t.wrap;var o=t.spacing;var a=this._fieldMap.sizeField;var s=this._newGroup();var l=[];var c=function(){l.push(s),d+=s.lineSize+i};var d=-i;for(var h=0;h<n.length;h++){var u=n[h];var p=n[h].clippedBBox();u.visible()&&p&&(r&&s.size+p.size[a]+o>e._rect.size[a]?0===s.bboxes.length?(e._addToGroup(s,p,u),c(),s=e._newGroup()):(c(),s=e._newGroup(),e._addToGroup(s,p,u)):e._addToGroup(s,p,u))}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}(Us);var Xs=function(e){function t(t,n){void 0===t&&(t=new ya),void 0===n&&(n={}),e.call(this,n),this.geometry(t),So(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}(za(La(Ha(Aa))));function Zs(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]=js(a.size[r],t,n||"start",i,r),Ws(s,a,e[o])}}}function Js(e,t,n,i){if(e.length>1){var r=new ba;var o=e[0].bbox;for(var a=1;a<e.length;a++){var s=e[a].element;var l=e[a].bbox;r[t]=o.origin[t]+o.size[i],r[n]=l.origin[n],Ws(r,l,s),l.origin[t]=r[t],o=l}}}function el(e){var t=[];for(var n=0;n<e.length;n++){var i=e[n];var r=i.clippedBBox();r&&t.push({element:i,bbox:r})}return t}function tl(e,t,n,i,r){var o=function(e,t,n){var i=t.size[n];var r=[];var o=[];var a=0;var s,l;var c=function(){o.push({element:s,bbox:l})};for(var d=0;d<e.length;d++)if(s=e[d],l=s.clippedBBox()){var h=l.size[n];a+h>i?o.length?(r.push(o),o=[],c(),a=h):(c(),r.push(o),o=[],a=0):(c(),a+=h)}return o.length&&r.push(o),r}(e,t,r);var a=t.origin.clone();var s=[];for(var l=0;l<o.length;l++){var c=o[l];var d=c[0];a[i]=d.bbox.origin[i],Ws(a,d.bbox,d.element),d.bbox.origin[n]=a[n],Js(c,n,i,r),s.push([]);for(var h=0;h<c.length;h++)s[l].push(c[h].element)}return s}var 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._change=function(){this.optionsChange({field:"stops"})},t}(Xa);function il(e){return function(t){return So(t)?(this.options.set(e,t),this):this.options.get(e)}}var rl=function(e){function t(t,n,i){e.call(this),this.options=new fa({offset:t,color:n,opacity:So(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(So(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}((ol=["offset","color","opacity"],al=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}(wo),function(e,t){for(var n=0;n<t.length;n++)e[t[n]]=il(t[n])}(al.prototype,ol),al));var ol,al;var sl=function(e){function t(t){void 0===t&&(t={}),e.call(this),this.stops=new nl(this._createStops(t.stops)),this.stops.addObserver(this),this._userSpace=t.userSpace,this.id=Mo()}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 So(e)?(this._userSpace=e,this.optionsChange(),this):this._userSpace},t.prototype._createStops=function(e){void 0===e&&(e=[]);var t=[];for(var n=0;n<e.length;n++)t.push(rl.create(e[n]));return t},t.prototype.addStop=function(e,t,n){this.stops.push(new rl(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}(wo);var ll=function(e){function t(t){void 0===t&&(t={}),e.call(this,t),this.start(t.start||new ba),this.end(t.end||new ba(1,0))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(ls(sl,["start","end"]));var cl=function(e){function t(t){void 0===t&&(t={}),e.call(this,t),this.center(t.center||new ba),this._radius=So(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 So(e)?(this._radius=e,this.geometryChange(),this):this._radius},t.prototype.fallbackFill=function(e){return So(e)?(this._fallbackFill=e,this.optionsChange(),this):this._fallbackFill},t}(ls(sl,["center"]));var dl="#aba4a6";var hl=2,ul=18;var pl=10,fl=10;var ml=18,gl=2;var vl=function(e){function t(t){e.call(this);var n=t.width;var i=t.height;this._size=wa.create([n,i]),this.id=Mo()}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 Ma},t.prototype.size=function(e){return e?(this._size=wa.create(e),this):this._size},Object.defineProperties(t.prototype,n),t}(Us);var _l=function(e,t,n){t&&e.append(new Xs(new ya([0,0],n),{fill:{color:t},stroke:null}))};var bl=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}});var wl;var yl=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 wl||(wl=new t),wl},t.prototype.register=function(e,t){this._items.push({name:e,type:t})},t.prototype.create=function(e,t){var n=this._items;var i;if(t&&t.type){var r=t.type.toLowerCase();for(var o=0;o<n.length;o++)if(n[o].name.toLowerCase()===r){i=n[o];break}}if(i)return new i.type(e,t)},Object.defineProperties(t,n),t}(Vr);var kl=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 yl.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;var t=this.options;var n=t.duration;var i=t.delay;void 0===i&&(i=0);var r=bl[t.easing];var o=ro()+i;var a=o+n;0===n?(this.step(1),this.abort()):setTimeout((function(){var t=function(){if(!e._stopped){var i=ro();var s=Vo(i-o,0,n);var l=r(s/n,s,0,1,n);e.step(l),i<a?Gr(t):e.abort()}};t()}),i)},t.prototype.abort=function(){this._stopped=!0},t.prototype.destroy=function(){this.abort()},Object.defineProperties(t.prototype,n),t}(Vr);var xl;var Cl=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 xl||(xl=new t),xl},t.prototype.parse=function(e,t){return Ps(new Fs(t),e)},Object.defineProperties(t,n),t}(Vr);var Sl=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);var e=this.childNodes;for(var 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){var n=e+t;for(var 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}(Vr);var Tl=["click","mouseenter","mouseleave","mousemove","resize"];var Ml=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 Us,Qo(t,this.options),this.bind(Tl,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){var t=Ro(e);var n;for(;!n&&t&&(n=t._kendoNode,t!==this.element);)t=t.parentElement;if(n)return n.srcElement},t.prototype.exportVisual=function(){return this._visual},t.prototype.getSize=function(){return Qo(this.element)},t.prototype.currentSize=function(e){if(!e)return this._size;this._size=e},t.prototype.setSize=function(e){Qo(this.element,e),this.currentSize(e),this._resize()},t.prototype.resize=function(e){var t=this.getSize();var 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;var t=Zo(e);var n=Go(e);var i=n.left;var r=n.top;return{left:i+t.left,top:r+t.top}},t.prototype._surfacePoint=function(e){var t=this._elementOffset();var n=Ho(e);var i=n.x-t.left;var r=n.y-t.top;var o=na(this.element).invert();return new ba(i,r).transform(o)},t}(Nr);function Al(e,t){return So(t)&&null!==t?" "+e+'="'+t+'" ':""}function Dl(e){var t="";for(var n=0;n<e.length;n++)t+=Al(e[n][0],e[n][1]);return t}function El(e){var t="";for(var n=0;n<e.length;n++){var i=e[n][1];So(i)&&(t+=e[n][0]+":"+i+";")}if(""!==t)return t}var Il={};var zl=function(e,t){var n=Or(t);Object.keys(n).forEach((function(t){e.style[t]=n[t]}))};var Pl="data-style";var Ll=function(e){return(e||"").replace(/\sstyle=/g," "+Pl+"=")};var Bl=function(e){Array.from(e.querySelectorAll("["+Pl+"]")).forEach((function(e){var t=e.getAttribute(Pl);e.removeAttribute(Pl),zl(e,t)}))};var Hl=function(e,t){e.innerHTML=Ll(t),Bl(e)};var Rl="http://www.w3.org/2000/svg";var Fl="none";var Ol=function(e,t){Hl(e,t)};if("undefined"!=typeof document){var Vl="<svg xmlns='"+Rl+"'></svg>";var Nl=document.createElement("div");var $l="undefined"!=typeof DOMParser;Nl.innerHTML=Vl,$l&&Nl.firstChild.namespaceURI!==Rl&&(Ol=function(e,t){var n=(new DOMParser).parseFromString(Ll(t),"text/xml");Bl(n);var i=document.adoptNode(n.documentElement);e.innerHTML="",e.appendChild(i)})}var Ul=Ol;var Wl="transform";var jl={clip:"clip-path",fill:"fill"};function ql(e,t){return"clip"===e||"fill"===e&&(!t||"Gradient"===t.nodeType||t.nodeType===Ma)}var Gl=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){var n=this;for(var i=0;i<e.length;i++){var r=e[i];var o=r.children;var a=new Il[r.nodeType](r,n.options);So(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(){var e=this;for(;e.parent;)e=e.parent;return e},t.prototype.attachTo=function(e,t){var n=document.createElement("div");Ul(n,"<svg xmlns='"+Rl+"' version='1.1'>"+this.render()+"</svg>");var i=n.firstChild.firstChild;i&&(So(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;var t=this.childNodes;for(var 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="");var e=this.childNodes;for(var 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(){var e=this.childNodes;var t="";for(var n=0;n<e.length;n++)t+=e[n].render();return t},t.prototype.optionsChange=function(t){var n=t.field;var i=t.value;"visible"===n?this.css("display",i?"":Fl):jl[n]&&ql(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;var n=e.value;"role"===t?n?this.attr("role",n):this.removeAttr("role"):"ariaLabel"===t?n?this.attr("aria-label",Jr(n)):this.removeAttr("aria-label"):"ariaRoleDescription"===t?n?this.attr("aria-roledescription",Jr(n)):this.removeAttr("aria-roledescription"):"ariaChecked"===t?So(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=this;var n;this.element&&((n=this.element.classList).remove.apply(n,this.element.classList),e.split(" ").forEach((function(e){t.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([Wl,"matrix("+e.matrix().toString(6)+")"]),t},t.prototype.renderTransform=function(){return Dl(this.mapTransform(this.srcElement.transform()))},t.prototype.transformChange=function(e){e?this.allAttr(this.mapTransform(e)):this.removeAttr(Wl)},t.prototype.mapStyle=function(){var e=this.srcElement.options;var t=[["cursor",e.cursor]];return!1===e.visible&&t.push(["display",Fl]),t},t.prototype.renderStyle=function(){return Al("style",El(this.mapStyle(!0)))},t.prototype.renderOpacity=function(){return Al("opacity",this.srcElement.options.opacity)},t.prototype.renderId=function(){return Al("id",this.srcElement.options.id)},t.prototype.renderClassName=function(){return Al("class",this.srcElement.options.className)},t.prototype.renderRole=function(){return Al("role",this.srcElement.options.role)},t.prototype.renderAriaLabel=function(){var e=this.srcElement.options.ariaLabel;return e&&(e=Jr(e)),Al("aria-label",e)},t.prototype.renderAriaRoleDescription=function(){var e=this.srcElement.options.ariaRoleDescription;return e&&(e=Jr(e)),Al("aria-roledescription",e)},t.prototype.renderAriaChecked=function(){return Al("aria-checked",this.srcElement.options.ariaChecked)},t.prototype.createDefinitions=function(){var e=this.srcElement;var t=this.definitions;if(e){var n=e.options;var i;for(var r in jl){var o=n.get(r);o&&ql(r,o)&&(t[r]=o,i=!0)}i&&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;var i=n[e];var r=jl[e];var 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 Dl(this.mapDefinitions())},t.prototype.mapDefinitions=function(){var e=this.definitions;var t=[];for(var n in e)t.push([jl[n],this.refUrl(e[n].id)]);return t},t.prototype.refUrl=function(e){var t=(this.options||{}).skipBaseHref;var n=this.baseUrl().replace(/'/g,"\\'");return"url("+(t?"":n)+"#"+e+")"},t.prototype.baseUrl=function(){return function(){var e=document.getElementsByTagName("base")[0];var t=document.location.href;var n="";if(e&&!(io.browser||{}).msie){var i=t.indexOf("#");-1!==i&&(t=t.substring(0,i)),n=t}return n}()},t}(Sl);var Kl=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 Al("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}(Gl);var Yl=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(){var e=this.srcElement.stops;var t=this.element;for(var n=0;n<e.length;n++){var i=new Kl(e[n]);this.append(i),t&&i.attachTo(t)}},t.prototype.optionsChange=function(e){"gradient.stops"===e.field?(Sl.prototype.clear.call(this),this.loadStops()):"gradient"===e.field&&this.allAttr(this.mapCoordinates())},t.prototype.renderCoordinates=function(){return Dl(this.mapCoordinates())},t.prototype.mapSpace=function(){return["gradientUnits",this.srcElement.userSpace()?"userSpaceOnUse":"objectBoundingBox"]},t}(Gl);var Ql=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;var t=e.start();var n=e.end();return[["x1",t.x],["y1",t.y],["x2",n.x],["y2",n.y],this.mapSpace()]},t}(Yl);var Xl=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;var t=e.center();var n=e.radius();return[["cx",t.x],["cy",t.y],["r",n],this.mapSpace()]},t}(Yl);var Zl=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();var t=this.srcElement.size().getHeight();return"<pattern id='"+this.srcElement.id+"' width='"+e+"' height='"+t+"' patternUnits='userSpaceOnUse'>"+this.renderChildren()+"</pattern>"},t}(Gl);var Jl=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 Al("clip-rule","evenodd")},t.prototype.template=function(){return"<clipPath "+this.renderClipRule()+" id='"+this.id+"'>"+this.renderChildren()+"</clipPath>"},t}(Gl);var ec=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;var 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=Jl:"fill"===e&&(t instanceof ll?n=Ql:t instanceof cl?n=Xl:t.nodeType===Ma&&(n=Zl)),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;var i=this.definitionMap;var r=t.id;var 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;var n=e.id;var i=t[n];i&&(i.count--,0===i.count&&(this.remove(this.childNodes.indexOf(i.element),1),delete t[n]))},t}(Gl);var tc=function(e){function t(t){e.call(this),this.options=t,this.defs=new ec}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(){Sl.prototype.clear.call(this)},t.prototype.template=function(){return this.defs.render()+this.renderChildren()},t.prototype.definitionChange=function(e){this.defs.definitionChange(e)},t}(Gl);var nc={"fill.opacity":"fill-opacity","stroke.color":"stroke","stroke.width":"stroke-width","stroke.opacity":"stroke-opacity"};var ic=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=nc[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&&!Fo(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]),So(e.opacity)&&t.push(["stroke-opacity",e.opacity]),So(e.dashType)&&t.push(["stroke-dasharray",this.renderDashType(e)])):t.push(["stroke",Fl]),t},t.prototype.renderStroke=function(){return Dl(this.mapStroke(this.srcElement.options.stroke))},t.prototype.renderDashType=function(e){var t=e.dashType;var n=e.width;if(void 0===n&&(n=1),t&&t!==Sa){var i=Ca[t.toLowerCase()];var r=[];for(var o=0;o<i.length;o++)r.push(i[o]*n);return r.join(" ")}},t.prototype.renderLinecap=function(e){var t=e.dashType;var n=e.lineCap;return t&&t!==Sa?Ta:n},t.prototype.mapFill=function(e){var t=[];return(!e||"Gradient"!==e.nodeType&&e.nodeType!==Ma)&&(e&&!Fo(e.color)?(t.push(["fill",e.color]),So(e.opacity)&&t.push(["fill-opacity",e.opacity])):t.push(["fill",Fl])),t},t.prototype.renderFill=function(){return Dl(this.mapFill(this.srcElement.options.fill))},t.prototype.template=function(){return"<path "+this.renderId()+" "+this.renderStyle()+" "+this.renderOpacity()+" "+Al("d",this.renderData())+this.renderStroke()+this.renderFill()+this.renderDefinitions()+this.renderTransform()+this.renderClassName()+" "+this.renderRole()+this.renderAriaLabel()+" "+this.renderAriaRoleDescription()+this.renderAriaChecked()+" ></path>"},t}(Gl);var 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.renderData=function(){return this.srcElement.toPath().toString(3)},t}(ic);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.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}(ic);var 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.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;var i=t.value;"transform"===n&&this.transformChange(i),this.accessibilityOptionsChange(t),e.prototype.optionsChange.call(this,t)},t}(Gl);var 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.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();var t=e.topLeft();return[["x",t.x],["y",t.y],["width",e.width()+"px"],["height",e.height()+"px"]]},t.prototype.renderPosition=function(){return Dl(this.mapPosition())},t.prototype.mapSource=function(e){var t=this.srcElement.src();return e&&(t=Jr(t)),[["xlink:href",t]]},t.prototype.renderSource=function(){return Dl(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}(ic);var 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.renderData=function(){return this.srcElement.toString(3)||"undefined"},t}(ic);var 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.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}(ic);var dc=/&(?:[a-zA-Z]+|#\d+);/g;function hc(e){if(!e||"string"!=typeof e||!dc.test(e))return e;var t=hc._element;return dc.lastIndex=0,e.replace(dc,(function(e){return t.innerHTML=e,t.textContent||t.innerText}))}"undefined"!=typeof document&&(hc._element=document.createElement("span"));var 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.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",El(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);var i=this.srcElement.options.font;return t&&(i=Jr(i)),n.push(["font",i],["white-space","pre"]),n},t.prototype.pos=function(){var e=this.srcElement.position();var t=this.srcElement.measure();return e.clone().setY(e.y+t.baseline)},t.prototype.renderContent=function(){var e=this.srcElement.content();return oa(e=Jr(e=hc(e)))},t.prototype.renderTextAnchor=function(){var e;return!(this.options||{}).rtl||io.browser.msie||io.browser.edge||(e="end"),Al("text-anchor",e)},t.prototype.renderPaintOrder=function(){var e=this.srcElement.options.paintOrder;return e?Al("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}(ic);Il.Arc=rc,Il.Circle=oc,Il.Group=ac,Il.Image=sc,Il.MultiPath=lc,Il.Path=ic,Il.Rect=cc,Il.Text=uc;var pc=function(e){function t(t,n){e.call(this,t,n),this._root=new tc(Object.assign({rtl:"rtl"===Ko(t,"direction").direction},this.options)),Ul(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;var i=-t.f%1;var r=e.style;0===n&&0===i||(r.left=n+"px",r.top=i+"px")}}(this._rootElement),this._root.attachTo(this._rootElement),qo(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,Xo(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;var t=this._offset;if(t){var n=new Us;n.children.push(e),n.transform(xa().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='"+Rl+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+this._root.render()+"</svg>"},Object.defineProperties(t.prototype,n),t}(Ml);var fc={};var mc=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 fc[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];var o=r.children;var a=new fc[r.nodeType](r,n);o&&o.length>0&&a.load(o,t,n),So(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();So(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}(Sl);var gc=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);var t=this.childNodes;for(var n=0;n<t.length;n++){var i=t[n];i.visible()&&i.renderTo(e)}e.restore()}},t}($s(mc,"childNodes"));var vc=1e3/60;var _c=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=oo((function(){Gr(i)}),vc)}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;var 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}($s(gc,"childNodes"));var bc=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){var t=this.shapes;var n=t.length;var i=[];for(var 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){var t=this.shapes;var n=t.length;for(var i=0;i<n;i++)if(t[i].shape===e){t.splice(i,1);break}},t}(Vr);var wc=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;var n=t.bottomRight();var i=e.bottomRight();var 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){var n=this.children;var i=n.length;var r=e.prototype.pointShapes.call(this,t);for(var o=0;o<i;o++)yo(r,n[o].pointShapes(t));return r},t.prototype.insert=function(e,t){var n=this.children;var 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;var n=this.children;var i=e.center();var r=e.width()/2;var o=e.height()/2;n.push(new t(new ya([e.origin.x,e.origin.y],[r,o])),new t(new ya([i.x,e.origin.y],[r,o])),new t(new ya([e.origin.x,i.y],[r,o])),new t(new ya([i.x,i.y],[r,o])))},t}(bc);var yc=3e3;var kc=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 bc,this.rootElements=[]},t.prototype.clear=function(){var e=this.rootElements;for(var 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/yc)]||{})[Math.floor(e.y/yc)];var n=this.root.pointShapes(e);t&&(n=n.concat(t.pointShapes(e))),this.assignZindex(n),n.sort(xc);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++){var n=e[t];var i=0;var r=Math.pow(1e4,75);var o=[];for(;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];yo(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){var t;for(;e.length>0;)(t=e.pop()).addObserver(this),"Group"===t.nodeType?yo(e,t.children):this._insertShape(t)},t.prototype._insertShape=function(e){var t=e.bbox();if(t){var n=this.getSectors(t);var i=n[0][0];var 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 wc(new ya([i*yc,r*yc],[yc,yc]))),o[i][r].insert(e,t)}}},t.prototype.remove=function(e){if(e.removeObserver(this),"Group"===e.nodeType){var t=e.children;for(var 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){var t=e.bottomRight();var n=Math.floor(t.x/yc);var i=Math.floor(t.y/yc);var r=[[],[]];for(var o=Math.floor(e.origin.x/yc);o<=n;o++)r[0].push(o);for(var a=Math.floor(e.origin.y/yc);a<=i;a++)r[1].push(a);return r},t}(Vr);function xc(e,t){return e._zIndex<t._zIndex?1:e._zIndex>t._zIndex?-1:0}var Cc=function(e){e.bind("mouseenter",this._mouseenter.bind(this)),e.bind("mouseleave",this._mouseleave.bind(this)),this.element=e.element};function Sc(e,t){var n=t.segments;if(0!==n.length){var i=n[0];var 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();var 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()}}Cc.prototype.clear=function(){this._resetCursor()},Cc.prototype.destroy=function(){this._resetCursor(),delete this.element},Cc.prototype._mouseenter=function(e){var t=this._shapeCursor(e);t?(this._current||(this._defaultCursor=this._getCursor()),this._setCursor(t)):this._resetCursor()},Cc.prototype._mouseleave=function(){this._resetCursor()},Cc.prototype._shapeCursor=function(e){var t=e.element;for(;t&&!So(t.options.cursor);)t=t.parent;if(t)return t.options.cursor},Cc.prototype._getCursor=function(){if(this.element)return this.element.style.cursor},Cc.prototype._setCursor=function(e){this.element&&(this.element.style.cursor=e,this._current=e)},Cc.prototype._resetCursor=function(){this._current&&(this._setCursor(this._defaultCursor||""),delete this._current)};var Tc=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;var n=!1;return t&&("Gradient"===t.nodeType?(this.setGradientFill(e,t),n=!0):t.nodeType===Ma?(this.setPatternFill(e,t),n=!0):Fo(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=this.srcElement.rawBBox();var i;if(t instanceof ll){var r=t.start();var o=t.end();i=e.createLinearGradient(r.x,r.y,o.x,o.y)}else if(t instanceof cl){var a=t.center();i=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];var r=_o(i.color());r.a*=i.opacity(),e.addColorStop(i.offset(),r.toCssRgba())}}(i,t.stops),e.save(),t.userSpace()||e.transform(n.width(),0,0,n.height(),n.origin.x,n.origin.y),e.fillStyle=i,e.fill(),e.restore()},t.prototype.setPatternFill=function(e,t){var n=t.size();var i=document.createElement("canvas");var r=i.getContext("2d");i.width=n.getWidth(),i.height=n.getHeight(),this.childNodes.length=0,this.loadElements(t.children);var o=this.childNodes;for(var 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&&!Fo(t.color)&&t.width>0)return e.strokeStyle=t.color,e.lineWidth=jo(t.width,1),e.lineJoin=jo(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!==Sa){var n=Ca[t];e.setLineDash?e.setLineDash(n):(e.mozDash=n,e.webkitLineDash=n)}},t.prototype.setLineCap=function(e){var t=this.dashType();var n=this.srcElement.options.stroke;t&&t!==Sa?e.lineCap=Ta: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){Sc(e,t)},t}(mc);var Mc=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){Sc(e,this.srcElement.toPath())},t}(Tc);var 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){var t=this.srcElement.geometry();var n=t.center;var i=t.radius;e.arc(n.x,n.y,i,0,2*Math.PI)},t}(Tc);var Dc=function(e){function t(t,n){e.call(this,t),this.onLoad=this.onLoad.bind(this),this.onError=this.onError.bind(this),this.loading=Co();var i=this.img=new Image;var 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=Co(),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();var n=t.topLeft();e.drawImage(this.img,n.x,n.y,t.width(),t.height())},t}(Tc);var Ec=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.paths;for(var n=0;n<t.length;n++)Sc(e,t[n])},t}(Tc);var Ic=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();var i=n.cornerRadius;var r=i[0];var o=i[1];if(0===r&&0===o){var a=n.origin;var s=n.size;t.rect(a.x,a.y,s.width,s.height)}else e.prototype.renderPoints.call(this,t,Rs.fromRect(n))},t}(Tc);var zc=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;var n=t.position();var 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}(Tc);fc.Arc=Mc,fc.Circle=Ac,fc.Group=gc,fc.Image=Dc,fc.MultiPath=Ec,fc.Path=Tc,fc.Rect=Ic,fc.Text=zc;var Pc=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=Qo(t);i.width=r.width,i.height=r.height,this._rootElement=i,this._root=new _c(i,r),this._mouseTrackHandler=this._trackMouse.bind(this),qo(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),Xo(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;var t=this._rootElement;var n=[];e.traverse((function(e){e.loading&&n.push(e.loading)}));var i=Co();var r=function(){e._invalidate({fixedScale:!0});try{var n=t.toDataURL();i.resolve(n)}catch(e){i.reject(e)}};return $o(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 kc;var t=this._root.childNodes;var n=[];for(var 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 kc,this._cursor=new Cc(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}(Ml);var Lc;var Bc;var Hc=function(){return"undefined"!=typeof document};var Rc=function(e){function t(){e.call(this),this._items=[{name:"svg",type:pc},{name:"canvas",type:Pc}]}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 Bc||(Bc={canvas:Hc()&&document.createElement("canvas").getContext,svg:Hc()&&document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")}),Bc},n.current.get=function(){return Lc||(Lc=new t),Lc},t.prototype.create=function(e,t){var n=this._items;var i=n[0];if(t&&t.type){var r=t.type.toLowerCase();for(var o=0;o<n.length;o++)if(n[o].name===r){i=n[o];break}}if(i)return new i.type(e,t);eo("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}(Vr);var Fc=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 Rc.support},t.create=function(e,t){return Rc.current.create(e,t)},Object.defineProperties(t,n),t}(Ml);function Oc(e){var t=new tc({skipBaseHref:!0});var n=e.clippedBBox();var i=e;if(n){var r=n.getOrigin();var o=new Us;o.transform(xa().translate(-r.x,-r.y)),o.children.push(e),i=o}t.load([i]);var a="<?xml version='1.0' ?><svg xmlns='"+Rl+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+t.render()+"</svg>";return t.destroy(),a}var Vc=Object.freeze({__proto__:null,ArcNode:rc,CircleNode:oc,ClipNode:Jl,DefinitionNode:ec,GradientStopNode:Kl,GroupNode:ac,ImageNode:sc,LinearGradientNode:Ql,MultiPathNode:lc,Node:Gl,PathNode:ic,RadialGradientNode:Xl,RectNode:cc,RootNode:tc,Surface:pc,TextNode:uc,exportGroup:Oc});var Nc=Object.freeze({__proto__:null,ArcNode:Mc,CircleNode:Ac,GroupNode:gc,ImageNode:Dc,MultiPathNode:Ec,Node:mc,PathNode:Tc,RectNode:Ic,RootNode:_c,Surface:Pc,TextNode:zc});function $c(e,t){var n={width:"800px",height:"600px",cors:"Anonymous"};var i=e;var r=e.clippedBBox();if(r){var o=r.getOrigin();(i=new Us).transform(xa().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);var l=document.createElement("div");var c=l.style;c.display="none",c.width=s.width,c.height=s.height,document.body.appendChild(l);var d=new Pc(l,s);d.suspendTracking(),d.draw(i);var h=d.image();var u=function(){d.destroy(),document.body.removeChild(l)};return h.then(u,u),h}function Uc(e,t){var n=Oc(e);return t&&t.raw||(n="data:image/svg+xml;base64,"+Bo(n)),Co().resolve(n)}var Wc=Object.freeze({__proto__:null,Animation:kl,AnimationFactory:yl,Arc:Os,BaseNode:Sl,Circle:Ra,Element:Aa,Gradient:sl,GradientStop:rl,Group:Us,HasObservers:wo,Image:Ns,Layout:Qs,LinearGradient:ll,MultiPath:Fs,OptionsStore:fa,Path:Rs,PathParser:Cl,Pattern:vl,QuadNode:wc,RadialGradient:cl,Rect:Xs,ShapesQuadTree:kc,Surface:Fc,SurfaceFactory:Rc,Text:Vs,align:function(e,t,n){Zs(e,t,n,"x","width")},canvas:Nc,crosshatchPattern:function(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=ul);var n=e.width;void 0===n&&(n=hl);var i=e.color;void 0===i&&(i=dl);var r=e.background;var o=Math.sqrt(2)*(n+t);var a={fill:null,stroke:{color:i,width:n}};var s=new vl({width:o,height:o});_l(s,r,[o,o]);var l=new Rs(a);l.moveTo(0,0).lineTo(o,o);var c=new Rs(a);return c.moveTo(o,0).lineTo(0,o),s.append(l,c),s},diagonalStripesPattern:function(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=ul);var n=e.width;void 0===n&&(n=hl);var i=e.color;void 0===i&&(i=dl);var r=e.background;var o=Math.sqrt(2)*(n+t);var a={fill:null,stroke:{color:i,width:n,lineCap:"square"}};var s=new vl({width:o,height:o});_l(s,r,[o,o]);var l=new Rs(a);l.moveTo(0,o/2).lineTo(o/2,0);var c=new Rs(a);return c.moveTo(o/2,o).lineTo(o,o/2),s.append(l,c),s},dotsPattern:function(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=fl);var n=e.radius;void 0===n&&(n=pl);var i=e.color;void 0===i&&(i=dl);var r=e.background;var o={fill:{color:i},stroke:null};var a=4*n+2*t;var s=3*n+1.5*t;var l=[a/2,n+.5*t];var c=[0,s];var d=[a,s];var h=new vl({width:a,height:a});return _l(h,r,[a,a]),h.append(new Ra(new Ia(l,n),o),new Ra(new Ia(c,n),o),new Ra(new Ia(d,n),o)),h},exportImage:$c,exportSVG:Uc,fit:function(e,t){var n=e.clippedBBox();if(n){var i=n.size;var r=t.size;if(r.width<i.width||r.height<i.height){var o=Math.min(r.width/i.width,r.height/i.height);var a=e.transform()||xa();a.scale(o,o),e.transform(a)}}},gridPattern:function(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=gl);var n=e.size;void 0===n&&(n=ml);var i=e.color;void 0===i&&(i=dl);var r=e.background;var o=n+t;var a=t/2;var s={fill:{color:i},stroke:null};var l=new vl({width:o,height:o});_l(l,r,[o,o]);var c=new Xs(new ya([a,a],[n,n]),s);return l.append(c),l},parsePath:Ps,stack:function(e){Js(el(e),"x","y","width")},svg:Vc,util:ua,vAlign:function(e,t,n){Zs(e,t,n,"y","height")},vStack:function(e){Js(el(e),"y","x","height")},vWrap:function(e,t){return tl(e,t,"y","x","height")},verticalStripesPattern:function(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=ul);var n=e.width;void 0===n&&(n=hl);var i=e.color;void 0===i&&(i=dl);var r=e.background;var o=n+t;var a={fill:null,stroke:{color:i,width:n/2}};var s=new vl({width:o,height:o});_l(s,r,[o,o]);var l=n/4;var c=o-n/4;var d=new Rs(a);d.moveTo(l,0).lineTo(l,o);var h=new Rs(a);return h.moveTo(c,0).lineTo(c,o),s.append(d,h),s},wrap:function(e,t){return tl(e,t,"x","y","width")}});var jc="undefined"!=typeof Uint8Array&&io.browser&&(!io.browser.msie||io.browser.version>9);var qc=(Gc="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",{decode:function(e){var t=e.replace(/[^A-Za-z0-9\+\/\=]/g,""),n=0,i=t.length,r=[];for(;n<i;){var o=Gc.indexOf(t.charAt(n++));var a=Gc.indexOf(t.charAt(n++));var s=Gc.indexOf(t.charAt(n++));var l=Gc.indexOf(t.charAt(n++));var c=o<<2|a>>>4;var d=(15&a)<<4|s>>>2;var h=(3&s)<<6|l;r.push(c),64!=s&&r.push(d),64!=l&&r.push(h)}return r},encode:function(e){var t=0,n=e.length;var i="";for(;t<n;){var r=e[t++];var o=e[t++];var a=e[t++];var s=(3&r)<<4|o>>>4;var l=(15&o)<<2|a>>>6;var c=63&a;t-n==2?l=c=64:t-n==1&&(c=64),i+=Gc.charAt(r>>>2)+Gc.charAt(s)+Gc.charAt(l)+Gc.charAt(c)}return i}});var Gc;function Kc(e){var t=0,n=0;null==e?e=jc?new Uint8Array(256):[]:n=e.length;var i=jc?function(t){if(t>=e.length){var n=new Uint8Array(Math.max(t+256,2*e.length));n.set(e,0),e=n}}:function(){};var r=jc?function(){return new Uint8Array(e.buffer,0,n)}:function(){return e};var o=jc?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])};var a=jc?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 h(){return 65536*c()+c()}function u(e){d(e>>>16&65535),d(65535&e)}function p(){var e=h();return e>=2147483648?e-4294967296:e}function f(e){u(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:h,writeLong:u,readFixed:function(){return h()/65536},writeFixed:function(e){u(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(qc.decode(e))},base64:function(){return qc.encode(r())}};return _}function Yc(e){return window.atob?function(e){var t=window.atob(e);var n=new Uint8Array(t.length);for(var i=0;i<t.length;i++)n[i]=t.charCodeAt(i);return n}(e):function(e){var t=new Uint8Array(e.length);for(var n=0;n<e.length;n++)t[n]=e[n];return t}(qc.decode(e))}function Qc(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Xc(e){return Object.keys(e).sort((function(e,t){return e-t})).map(parseFloat)}var Zc=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();var t=this.tables={};for(var 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}};Zc.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)},Zc.prototype.render=function(e){var t=Object.keys(e).length;var n=Math.pow(2,Math.floor(Math.log(t)/Math.LN2));var i=16*n;var r=Math.floor(Math.log(n)/Math.LN2);var o=16*t-i;var a=Kc();a.writeLong(this.scalerType),a.writeShort(t),a.writeShort(i),a.writeShort(r),a.writeShort(o);var s=16*t;var l=a.offset()+s;var c=null;var d=Kc();for(var h in e)if(Qc(e,h)){var u=e[h];for(a.writeString(h),a.writeLong(this.checksum(u)),a.writeLong(l),a.writeLong(u.length),d.write(u),"head"==h&&(c=l),l+=u.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()},Zc.prototype.checksum=function(e){e=Kc(e);var t=0;for(;!e.eof();)t+=e.readLong();return 4294967295&t};var Jc=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)};Jc.prototype.raw=function(){return this.rawData.slice(this.offset,this.length)},Jc.prototype.parse=function(){};var ed=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=Kc();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}(Jc);var td=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){var t=Kc();var n=e[e.length-1]>65535;for(var 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}(Jc);var nd=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=Kc();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}(Jc);var id=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=Kc();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}(Jc);var rd=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;var n=t.length;return e<n?t[e]:{advance:t[n-1].advance,lsb:this.leftSideBearings[e-n]}},t.prototype.render=function(e){var t=Kc();for(var n=0;n<e.length;++n){var i=this.forGlyph(e[n]);t.writeShort(i.advance),t.writeShort_(i.lsb)}return t.get()},t}(Jc);var od=function(){var e=function(e){this.raw=e};var 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;var t=this.glyphIds=[];var n=this.idOffsets=[];for(;;){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)}};var i={compound:{configurable:!0}};return i.compound.get=function(){return!0},n.prototype.render=function(e){var t=Kc(this.raw.get());for(var 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(Qc(i,t))return i[t];var r=this.file.loca;var o=r.lengthOf(t);if(0===o)return i[t]=null;var a=this.rawData;var s=this.offset+r.offsetOf(t);var l=Kc(a.slice(s,o));var c=l.readShort_();var d=l.readShort_();var h=l.readShort_();var u=l.readShort_();var p=l.readShort_();var f=i[t]=c<0?new n(l):new e(l);return f.numberOfContours=c,f.xMin=d,f.yMin=h,f.xMax=u,f.yMax=p,f},i.prototype.render=function(e,t,n){var i=Kc(),r=[];for(var 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}(Jc)}();var ad=(sd=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();var t=e.readShort();var n=this.offset+e.readShort();var 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}}));var r=this.strings={};for(var 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 sd(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;var n=0;for(var i in t)Qc(t,i)&&(n+=t[i].length);var r=Kc();var o=Kc();for(i in r.writeShort(0),r.writeShort(n),r.writeShort(6+12*n),t)if(Qc(t,i)){var a=6==i?[new sd(e,this.postscriptEntry)]:t[i];for(var 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}(Jc));var sd;var ld=(cd=".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=[];var n=this.offset+this.length;for(;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 cd[e]||".notdef";case 131072:var t=this.glyphNameIndex[e];return t<cd.length?cd[t]:this.names[t-cd.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=Kc(this.rawData.slice(this.offset,32));t.writeLong(131072),t.offset(32);var n=[];var i=[];for(var r=0;r<e.length;++r){var o=e[r];var a=this.glyphFor(o);var s=cd.indexOf(a);s>=0?n.push(s):(n.push(cd.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}(Jc));var cd;var dd=(hd=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);var l=e.times(o,e.readShort_);var c=e.times(o,e.readShort);var d=(i.length+i.offset-e.offset())/2;var h=e.times(d,e.readShort);for(r=0;r<o;++r){var u=s[r],p=a[r];for(t=u;t<=p;++t){var f;0===c[r]?f=t+l[r]:0!==(f=h[c[r]/2-(o-r)+(t-u)]||0)&&(f+=l[r]),n[t]=65535&f}}break;case 6:i.length=e.readShort(),i.language=e.readShort(),t=e.readShort();var m=e.readShort();for(;m-- >0;)n[t++]=e.readShort();break;case 12:e.readShort(),i.length=e.readLong(),i.language=e.readLong();var g=e.readLong();for(;g-- >0;){t=e.readLong();var v=e.readLong();var _=e.readLong();for(;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;var n=t.offset;e.offset(n),t.codeMap={},t.version=e.readShort();var i=e.readShort();t.tables=e.times(i,(function(){return new hd(e,n,t.codeMap)}))},t.render=function(e,t){var n=Kc();return n.writeShort(0),n.writeShort(1),n.write(function(e,t){var n=Xc(e);var i=[];var r=[];var o=null;var a=null;function s(n){return t[e[n]]}for(var l=0;l<n.length;++l){var c=n[l];var 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 h=i.length;var u=2*h;var p=2*Math.pow(2,Math.floor(Math.log(h)/Math.LN2));var f=Math.log(p/2)/Math.LN2;var m=u-p;var g=[];var v=[];var _=[];for(l=0;l<h;++l){var b=i[l];var w=r[l];if(65535==b){g.push(0),v.push(0);break}var y=s(b);if(b-y>=32768){g.push(0),v.push(2*(_.length+h-l));for(var k=b;k<=w;++k)_.push(s(k))}else g.push(y-b),v.push(0)}var x=Kc();return x.writeShort(3),x.writeShort(1),x.writeLong(12),x.writeShort(4),x.writeShort(16+8*h+2*_.length),x.writeShort(0),x.writeShort(u),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}(Jc));var hd;var ud=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}(Jc);var pd=1e5;var fd=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(){var e="",t=String(pd);for(var n=0;n<t.length;++n)e+=String.fromCharCode(t.charCodeAt(n)-48+65);return++pd,e}()+"+"+this.font.psName};fd.prototype.use=function(e){var t=this;if("string"==typeof e)return function(e){var t,n,i=[],r=0,o=e.length;for(;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},fd.prototype.encodeText=function(e){return this.use(e)},fd.prototype.glyphIds=function(){return Xc(this.ogid2ngid)},fd.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},fd.prototype.render=function(){var e=this;var t=this.glyphsFor(this.glyphIds());for(var n in t)if(Qc(t,n)&&(n=parseInt(n,10),null==e.ogid2ngid[n])){var i=e.nextGid++;e.ogid2ngid[n]=i,e.ngid2ogid[i]=n}var r=Xc(this.ngid2ogid).map((function(e){return this.ngid2ogid[e]}),this);var o=this.font;var a=o.glyf.render(t,r,this.ogid2ngid);var s=o.loca.render(a.offsets);this.lastChar=this.next-1;var l={cmap:dd.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)},fd.prototype.cidToGidMap=function(){var e=Kc(),t=0;for(var 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 md=function(e,t){var n=this;var i=n.contents=Kc(e);if("ttcf"==i.readString(4)){var r;var o=function(){i.offset(r),n.parse()};if(!t)throw new Error("Must specify a name for TTC files");i.readLong();var a=i.readLong();for(var 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()};md.prototype.parse=function(){var e=this.directory=new Zc(this.contents);this.head=e.readTable("head",ed),this.loca=e.readTable("loca",td),this.hhea=e.readTable("hhea",nd),this.maxp=e.readTable("maxp",id),this.hmtx=e.readTable("hmtx",rd),this.glyf=e.readTable("glyf",od),this.name=e.readTable("name",ad),this.post=e.readTable("post",ld),this.cmap=e.readTable("cmap",dd),this.os2=e.readTable("OS/2",ud),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},md.prototype.widthOfGlyph=function(e){return this.hmtx.forGlyph(e).advance*this.scale},md.prototype.makeSubset=function(){return new fd(this)};var gd=Xt;var vd=io.browser;var _d="\n";var bd=0;var wd=0;var yd={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 kd(){var e=0,t=Kc();function n(){var e=arguments;for(var 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 Nd)r.beforeRender(n),r.render(n);else if(Ld(r))Bd(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 qd(r)):t.writeString("null"))}}return n.writeData=function(e){t.write(e)},n.withIndent=function(t){++e,t(n),--e},n.indent=function(){n(_d,Id("",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 xd(e){if("function"!=typeof e){var t=e;e=function(e,n){return e in t?t[e]:n}}var n=e("paperSize",yd.a4);if(!n)return{};if("string"==typeof n&&null==(n=yd[n.toLowerCase()]))throw new Error("Unknown paper size");n[0]=Vd(n[0]),n[1]=Vd(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=Vd(i,0),top:i,right:i,bottom:i}:{left:Vd(i.left,0),top:Vd(i.top,0),right:Vd(i.right,0),bottom:Vd(i.bottom,0)},e("addMargin")&&(n[0]+=i.left+i.right,n[1]+=i.top+i.bottom)),{paperSize:n,margin:i}}var Cd={"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 Sd={};function Td(){Sd={}}var Md=(Ad=function(e,t){var n=Cd[e];n?t(n):function(e,t){var n;if(vd.msie&&(n=/^data:.*?;base64,/i.exec(e)))t(Yc(e.substr(n[0].length)));else{var i=new XMLHttpRequest;i.open("GET",e,!0),jc&&(i.responseType="arraybuffer"),i.onload=function(){200==i.status||304==i.status?t(jc?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 md(n);Cd[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;)Ad(e[i],r)});var Ad;var Dd=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=Sd[e];if(a)n(a);else if(a=new Image,/^data:/i.test(e)||(a.crossOrigin="Anonymous"),jc&&!/^data:/i.test(e)){var s=new XMLHttpRequest;s.onload=function(){if(o=s.response,vd.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,"+Bo((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&&!vd.msie?h.call(a):(a.onload=h,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=o.getContext("2d");var l;s.drawImage(a,0,0,t.width,t.height);try{l=s.getImageData(0,0,t.width,t.height)}catch(e){return void d()}finally{r&&URL.revokeObjectURL(r)}var c=!1,h=Kc(),u=Kc();var p=l.data;var f=0;for(;f<p.length;){h.writeByte(p[f++]),h.writeByte(p[f++]),h.writeByte(p[f++]);var m=p[f++];m<255&&(c=!0),u.writeByte(m)}if(c||i.keepPNG)a=new Zd(t.width,t.height,h,u);else{var g=o.toDataURL("image/jpeg",i.jpegQuality);g=g.substr(g.indexOf(";base64,")+8);var v=Kc();v.writeBase64(g),a=new Xd(v)}n(Sd[e]=a)}function d(){n(Sd[e]="ERROR")}function h(){if(t){var i=o&&"image/svg+xml"===o.type||/^data:image\/svg\+xml;/i.test(this.src.substring(0,19));var 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 Xd(Kc(new Uint8Array(this.result)));URL.revokeObjectURL(r),n(Sd[e]=t)}catch(e){c()}},l.readAsArrayBuffer(o)}else c()}}(t,e[t],o,n)}))};var Ed=function(e){var t=this;var n=kd();var i=0;var 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;var 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.PATTERNS={},t.IMAGES={},t.GRAD_COL_FUNCTIONS={},t.GRAD_OPC_FUNCTIONS={},t.GRAD_COL={},t.GRAD_OPC={};var a=t.attach(new Kd);var s=t.attach(new Yd);if(o("autoPrint")){var l={};l.JavaScript=new qd({Names:[new $d("JS"),t.attach(new qd({S:jd("JavaScript"),JS:new $d("print(true);")}))]}),a.props.Names=new qd(l)}a.setPages(s);var c=t.attach(new qd({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=xd((function(t,n){return e&&null!=e[t]?e[t]:n}));var i=n.paperSize;var r=n.margin;var o=i[0];var a=i[1];r&&(o-=r.left+r.right,a-=r.top+r.bottom);var l=new Gd(kd(),null,!0);var c={Contents:t.attach(l),Parent:s,MediaBox:[0,0,i[0],i[1]]};var d=new sh(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",_d,"%ÂÁÚÏÎ",_d,_d),e=0;e<r.length;++e)r[e].renderFull(n),n(_d,_d);var t=n.offset();for(n("xref",_d,0," ",r.length+1,_d),n("0000000000 65535 f ",_d),e=0;e<r.length;++e)n(zd(r[e]._offset,10)," 00000 n ",_d);return n(_d),n("trailer",_d),n(new qd({Size:r.length+1,Root:a,Info:c}),_d,_d),n("startxref",_d,t,_d),n("%%EOF",_d),n.stream().offset(0)},t.loadFonts=Md,t.loadImages=Dd};function Id(e,t,n){for(;e.length<t;)e=n+e;return e}function zd(e,t){return Id(String(e),t,"0")}function Pd(e,t){return Object.prototype.hasOwnProperty.call(e,t)}Ed.prototype.getFont=function(e){var t=this.FONTS[e];if(!t){if(!(t=Cd[e]))throw new Error("Font "+e+" has not been loaded");t=!0===t?this.attach(new eh(e)):this.attach(new th(this,t)),this.FONTS[e]=t}return t},Ed.prototype.getPattern=function(e,t,n){var i=this.PATTERNS[e.id];return i||(i=this.attach(new Jd(e,t,n)),this.PATTERNS[e.id]=i),i},Ed.prototype.getImage=function(e){var t=this.IMAGES[e];if(!t){if(!(t=Sd[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},Ed.prototype.getOpacityGS=function(e,t){var n=parseFloat(e).toFixed(3);e=parseFloat(n),n+=t?"S":"F";var i=this._opacityGSCache||(this._opacityGSCache={});var r=i[n];if(!r){var o={Type:jd("ExtGState")};t?o.CA=e:o.ca=e,(r=this.attach(new qd(o)))._resourceName=jd("GS"+ ++bd),i[n]=r}return r},Ed.prototype.dict=function(e){return new qd(e)},Ed.prototype.name=function(e){return jd(e)},Ed.prototype.stream=function(e,t){return new Gd(t,e)};var Ld=Array.isArray||function(e){return e instanceof Array};function Bd(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:",zd(e.getUTCFullYear(),4),zd(e.getUTCMonth()+1,2),zd(e.getUTCDate(),2),zd(e.getUTCHours(),2),zd(e.getUTCMinutes(),2),zd(e.getUTCSeconds(),2),"Z)")}function Rd(e){return e*(72/25.4)}function Fd(e){return Rd(10*e)}function Od(e){return 72*e}function Vd(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:Rd,cm:Fd,in:Od}[n[2]](i)}if(null!=t)return t;throw new Error("Can't parse unit: "+e)}var Nd=function(){};Nd.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){var t="";for(var n=0;n<e.length;n++){var i=e.charCodeAt(n);if(i<65535)t+=Po(i);else{var r=56320+(i-65536&1023);t+=Po(55296+(i-65536>>10)),t+=Po(r)}}return t}(t),e("(",t=t.replace(/([\(\)\\])/g,"\\$1"),")");else{var n=[40];for(var 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}(Nd);var Ud=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(zd(this.value.charCodeAt(t).toString(16),4));e(">")},t}($d);var Wd=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 jd(e)},t.prototype.render=function(e){e("/"+this.escape())},t.prototype.escape=function(){return this.name.replace(/[^\x21-\x7E]/g,(function(e){return"#"+zd(e.charCodeAt(0).toString(16),2)}))},t.prototype.toString=function(){return this.name},t}(Nd);function jd(e){return new Wd(e)}var qd=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)Pd(t,i)&&!/^_/.test(i)&&(n=!1,e.indent(jd(i)," ",t[i]))})),n||e.indent(),e(">>")},t}(Nd);var Gd=function(e){function t(t,n,i){if(e.call(this),"string"==typeof t){var r=Kc();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(jd("FlateDecode")),t=gd(t)),n.Length=t.length,e(new qd(n)," stream",_d),e.writeData(t),e(_d,"endstream")},t}(Nd);var Kd=function(e){function t(){e.call(this,{Type:jd("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}(qd);var Yd=function(e){function t(){e.call(this,{Type:jd("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}(qd);var Qd=[192,193,194,195,197,198,199,201,202,203,205,206,207];var Xd=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();var a=e.readShort();if(Qd.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:jd("XObject"),Subtype:jd("Image"),Width:t,Height:n,BitsPerComponent:r,Filter:jd("DCTDecode")};switch(i){case 1:s.ColorSpace=jd("DeviceGray");break;case 3:s.ColorSpace=jd("DeviceRGB");break;case 4:s.ColorSpace=jd("DeviceCMYK"),s.Decode=[1,0,1,0,1,0,1,0]}this.asStream=function(){e.offset(0);var t=new Gd(e,s);return t._resourceName=jd("I"+ ++bd),t}};var Zd=function(e,t,n,i){this.asStream=function(r){var o=new Gd(i,{Type:jd("XObject"),Subtype:jd("Image"),Width:e,Height:t,BitsPerComponent:8,ColorSpace:jd("DeviceGray")},!0);var a=new Gd(n,{Type:jd("XObject"),Subtype:jd("Image"),Width:e,Height:t,BitsPerComponent:8,ColorSpace:jd("DeviceRGB"),SMask:r.attach(o)},!0);return a._resourceName=jd("I"+ ++bd),a}};var Jd=function(e){function t(t,n,i){var r=t.size();var o=r.width;var a=r.height;var s=new sh(n._pdf,{});s._content=new Gd(kd(),null,!0),i(t,s,{}),n._xResources=Object.assign(n._xResources,s._xResources),n._fontResources=Object.assign(n._fontResources,s._fontResources),n._gsResources=Object.assign(n._gsResources,s._gsResources),e.call(this,{Type:jd("Pattern"),PatternType:1,PaintType:1,TilingType:1,BBox:[0,0,o,a],XStep:o,YStep:a,Matrix:[1,0,0,-1,0,a],Resources:{ExtGState:new e(s._gsResources),XObject:new e(s._xResources),Font:new e(s._fontResources)}}),this._resourceName=jd("P"+ ++wd),this.data=s._content.data,this.compress=!0}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(e){Gd.prototype.render.call(this,e)},t}(qd);var eh=function(e){function t(t){e.call(this,{Type:jd("Font"),Subtype:jd("Type1"),BaseFont:jd(t)}),this._resourceName=jd("F"+ ++bd)}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}(qd);var th=function(e){function t(t,n,i){e.call(this,{}),(i=this.props).Type=jd("Font"),i.Subtype=jd("Type0"),i.Encoding=jd("Identity-H"),this._pdf=t,this._font=n,this._sub=n.makeSubset(),this._resourceName=jd("F"+ ++bd);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 Ud(this._sub.encodeText(String(e)))},t.prototype.getTextWidth=function(e,t){var n=0,i=this._font.cmap.codeMap;for(var 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;var n=t._sub;var i=n.render();var r=new Gd(Kc(i),{Length1:i.length},!0);var o=t._pdf.attach(new e({Type:jd("FontDescriptor"),FontName:jd(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)}));var a=n.ncid2ogid;var s=n.firstChar;var l=n.lastChar;var 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:jd("Font"),Subtype:jd("CIDFontType2"),BaseFont:jd(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())});var h=t.props;h.BaseFont=jd(t._sub.psName),h.DescendantFonts=[t._pdf.attach(d)];var u=new nh(s,l,n.subset);var p=new Gd(kd(),null,!0);p.data(u),h.ToUnicode=t._pdf.attach(p)},t.prototype._makeCidToGidMap=function(){return new Gd(Kc(this._sub.cidToGidMap()),null,!0)},t}(qd);var nh=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];var 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("<",zd(n.toString(16),4),">","<");for(var o=0;o<r.length;++o)e(zd(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}(Nd);function ih(e){return e.map((function(e){return Ld(e)?ih(e):"number"==typeof e?(Math.round(1e3*e)/1e3).toFixed(3):e})).join(" ")}function rh(e,t,n,i,r,o,a){var s=ih([t,n,i,r,o,a]);var l=e.GRAD_COL_FUNCTIONS[s];return l||(l=e.GRAD_COL_FUNCTIONS[s]=e.attach(new qd({FunctionType:2,Domain:[0,1],Range:[0,1,0,1,0,1],N:1,C0:[t,n,i],C1:[r,o,a]}))),l}function oh(e,t,n){var i=ih([t,n]);var r=e.GRAD_OPC_FUNCTIONS[i];return r||(r=e.GRAD_OPC_FUNCTIONS[i]=e.attach(new qd({FunctionType:2,Domain:[0,1],Range:[0,1],N:1,C0:[t],C1:[n]}))),r}function ah(e,t,n){var i="radial"==t.type;var r=function(e,t){var n=!1;var i=[];var r=[];var o=[];var a=[];var s,l,c,d,h;for(s=1;s<t.length;++s)l=t[s-1],c=t[s],d=l.color,h=c.color,r.push(rh(e,d.r,d.g,d.b,h.r,h.g,h.b)),(d.a<1||h.a<1)&&(n=!0),o.push(c.offset),a.push(0,1);if(n)for(s=1;s<t.length;++s)l=t[s-1],c=t[s],d=l.color,h=c.color,i.push(oh(e,d.a,h.a));return o.pop(),{hasAlpha:n,colors:u(r),opacities:n?u(i):null};function u(e){return 1==e.length?e[0]:{FunctionType:3,Functions:e,Domain:[0,1],Bounds:o,Encode:a}}}(e,t.stops);var 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];var 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=ih(l),a=e.GRAD_COL[s]}return a||(a=new qd({Type:jd("Shading"),ShadingType:t?3:2,ColorSpace:jd("DeviceRGB"),Coords:i,Domain:[0,1],Function:r,Extend:[!0,!0]}),e.attach(a),a._resourceName="S"+ ++bd,s&&(e.GRAD_COL[s]=a)),a}(e,i,t.stops,o,r.colors,t.userSpace&&n);var 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=ih(l),a=e.GRAD_OPC[s]}return a||(a=new qd({Type:jd("ExtGState"),AIS:!1,CA:1,ca:1,SMask:{Type:jd("Mask"),S:jd("Luminosity"),G:e.attach(new Gd("/a0 gs /s0 sh",{Type:jd("XObject"),Subtype:jd("Form"),FormType:1,BBox:o?[o.left,o.top+o.height,o.left+o.width,o.top]:[0,1,1,0],Group:{Type:jd("Group"),S:jd("Transparency"),CS:jd("DeviceGray"),I:!0},Resources:{ExtGState:{a0:{CA:1,ca:1}},Shading:{s0:{ColorSpace:jd("DeviceGray"),Coords:i,Domain:[0,1],ShadingType:t?3:2,Function:r,Extend:[!0,!0]}}}}))}}),e.attach(a),a._resourceName="O"+ ++bd,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 sh=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=jd("Page"),n.ProcSet=[jd("PDF"),jd("Text"),jd("ImageB"),jd("ImageC"),jd("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];var l=t[0],c=t[1],d=t[2],h=t[3],u=t[4],p=t[5];return[n*l+i*d,n*c+i*h,r*l+o*d,r*c+o*h,a*l+s*d+u,a*c+s*h+p]}(arguments,this._matrix),this._out(e," ",t," ",n," ",i," ",r," ",o," cm"),this._out(_d))},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",_d)},t.prototype.endText=function(){this._textMode=!1,this._out("ET",_d)},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 th||(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",_d)},t.prototype.setTextLeading=function(e){this._requireTextMode(),this._out(e," TL",_d)},t.prototype.setTextRenderingMode=function(e){this._requireTextMode(),this._out(e," Tr",_d)},t.prototype.showText=function(e,t){if(this._requireFont(),e.length>1&&t&&this._font instanceof th){var n=t/this._font.getTextWidth(this._fontSize,e)*100;this._out(n," Tz ")}this._out(this._font.encodeText(e)," Tj",_d)},t.prototype.showTextNL=function(e){this._requireFont(),this._out(this._font.encodeText(e)," '",_d)},t.prototype.addLink=function(t,n){var i=this._toPage({x:n.left,y:n.bottom});var r=this._toPage({x:n.right,y:n.top});this._annotations.push(new e({Type:jd("Annot"),Subtype:jd("Link"),Rect:[i.x,i.y,r.x,r.y],Border:[0,0,0],A:new e({Type:jd("Action"),S:jd("URI"),URI:new $d(t)})}))},t.prototype.setStrokeColor=function(e,t,n){this._out(e," ",t," ",n," RG",_d)},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",_d)}},t.prototype.setFillColor=function(e,t,n){this._out(e," ",t," ",n," rg",_d)},t.prototype.pattern=function(e,t,n){var i=this._pdf.getPattern(e,this,n);this._patResources[i._resourceName]=i,this._out("/Pattern cs",_d),this._out(i._resourceName," scn",_d),this.rect(t.left,t.top,t.width,t.height),this.fill()},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",_d)}},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=ah(this._pdf,e,t);var i,r=n.shading._resourceName;this._shResources[r]=n.shading,n.hasAlpha&&(i=n.opacity._resourceName,this._gsResources[i]=n.opacity,this._out("/"+i+" gs ")),this._out("/"+r+" sh",_d),this.restore()},t.prototype.setDashPattern=function(e,t){this._out(e," ",t," d",_d)},t.prototype.setLineWidth=function(e){this._out(e," w",_d)},t.prototype.setLineCap=function(e){this._out(e," J",_d)},t.prototype.setLineJoin=function(e){this._out(e," j",_d)},t.prototype.setMitterLimit=function(e){this._out(e," M",_d)},t.prototype.save=function(){this._contextStack.push(this._context()),this._out("q",_d)},t.prototype.restore=function(){this._out("Q",_d),this._context(this._contextStack.pop())},t.prototype.moveTo=function(e,t){this._out(e," ",t," m",_d)},t.prototype.lineTo=function(e,t){this._out(e," ",t," l",_d)},t.prototype.bezier=function(e,t,n,i,r,o){this._out(e," ",t," ",n," ",i," ",r," ",o," c",_d)},t.prototype.bezier1=function(e,t,n,i){this._out(e," ",t," ",n," ",i," y",_d)},t.prototype.bezier2=function(e,t,n,i){this._out(e," ",t," ",n," ",i," v",_d)},t.prototype.close=function(){this._out("h",_d)},t.prototype.rect=function(e,t,n,i){this._out(e," ",t," ",n," ",i," re",_d)},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",_d)},t.prototype.nop=function(){this._out("n",_d)},t.prototype.clip=function(){this._out("W n",_d)},t.prototype.clipStroke=function(){this._out("W S",_d)},t.prototype.closeStroke=function(){this._out("s",_d)},t.prototype.fill=function(){this._out("f",_d)},t.prototype.fillStroke=function(){this._out("B",_d)},t.prototype.drawImage=function(e){var t=this._pdf.getImage(e);t&&(this._xResources[t._resourceName]=t,this._out(t._resourceName," Do",_d))},t.prototype.comment=function(e){var t=this;e.split(/\r?\n/g).forEach((function(e){t._out("% ",e,_d)}))},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;var 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}(qd);function lh(e){return e.replace(/^\s*(['"])(.*)\1\s*$/,"$2")}function ch(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(lh)}}function dh(e){function t(t){return e.bold&&(t+="|bold"),e.italic&&(t+="|italic"),t.toLowerCase()}var n=e.fontFamily;var i,r;if(n instanceof Array)for(var o=0;o<n.length&&(i=t(n[o]),!(r=hh[i]));++o);else r=hh[n.toLowerCase()];for(;"function"==typeof r;)r=r();return r||(r="Times-Roman"),r}var hh={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 uh(e,t){e=e.toLowerCase(),hh[e]=function(){return hh[t]},hh[e+"|bold"]=function(){return hh[t+"|bold"]},hh[e+"|italic"]=function(){return hh[t+"|italic"]},hh[e+"|bold|italic"]=function(){return hh[t+"|bold|italic"]}}function ph(e,t){if(1==arguments.length)for(var n in e)Pd(e,n)&&ph(n,e[n]);else switch(e=e.toLowerCase(),hh[e]=t,e){case"dejavu sans":hh["sans-serif"]=t;break;case"dejavu sans|bold":hh["sans-serif|bold"]=t;break;case"dejavu sans|italic":hh["sans-serif|italic"]=t;break;case"dejavu sans|bold|italic":hh["sans-serif|bold|italic"]=t;break;case"dejavu serif":hh.serif=t;break;case"dejavu serif|bold":hh["serif|bold"]=t;break;case"dejavu serif|italic":hh["serif|italic"]=t;break;case"dejavu serif|bold|italic":hh["serif|bold|italic"]=t;break;case"dejavu mono":hh.monospace=t;break;case"dejavu mono|bold":hh["monospace|bold"]=t;break;case"dejavu mono|italic":hh["monospace|italic"]=t;break;case"dejavu mono|bold|italic":hh["monospace|bold|italic"]=t}}uh("Times New Roman","serif"),uh("Courier New","monospace"),uh("Arial","sans-serif"),uh("Helvetica","sans-serif"),uh("Verdana","sans-serif"),uh("Tahoma","sans-serif"),uh("Georgia","sans-serif"),uh("Monaco","monospace"),uh("Andale Mono","monospace");var fh={fill:0,stroke:1,fillAndStroke:2,invisible:3,fillAndClip:4,strokeAndClip:5,fillStrokeClip:6,clip:7};var mh=fh;var gh={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:[]};var vh={butt:0,round:1,square:2};var _h={miter:0,round:1,bevel:2};function bh(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");var s=o("imgDPI",300);Td();var l={Image:function(e){var t=e.src();var 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=dh(ch(e.options.font));n.indexOf(t)<0&&n.push(t)}};function c(){if(!(--d>0)){var n=new Ed({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;var i=function(e){var t=!1;var n=Jo.unit();var i=null;var r;do{r=!1,e=d(e)}while(e&&r);return{root:e,bbox:i};function o(e){return r=!0,e}function a(e){return e.visible()&&e.opacity()>0&&(Ch(e.fill())||Ch(e.stroke()))}function s(e){var t=[];for(var n=0;n<e.length;++n){var i=d(e[n]);null!=i&&t.push(i)}return t}function l(e,i){var r=t;var o=n;e.transform()&&(n=n.multiplyCopy(e.transform().matrix()));var a=e.clip();a&&"function"==typeof a.bbox&&(a=a.bbox())&&(a=a.bbox(n),t=t?ya.intersect(t,a):a);try{return i()}finally{t=r,n=o}}function c(e){if(null==t)return!1;var i=e.rawBBox();return i&&(i=i.bbox(n)),t&&i&&(i=ya.intersect(i,t)),i}function d(t){return l(t,(function(){if(!(t instanceof Us||t instanceof Fs)){var n=c(t);if(!n)return o(null);i=i?ya.union(i,n):n}return kh({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 Fs(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 Us(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);var 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 Us).transform(new Jo(1,0,0,1,-c.x,-c.y)),i.append(e),e=i}else a="A4";xh(e,n.addPage({paperSize:a,margin:o("margin",o("margin"),t),addMargin:s,landscape:o("landscape",o("landscape",!1),t)}),n)}}e.traverse((function(e){kh(l,e);var t=e.fill&&e.fill();t instanceof vl&&t.traverse((function(e){kh(l,e)}))}));var d=2;Md(n,c),Dd(i,c,{jpegQuality:o("jpegQuality",.92),keepPNG:o("keepPNG",!1)})}function wh(e,t){bh(e,(function(e){t("data:application/pdf;base64,"+e.base64())}))}function yh(e,t){bh(e,(function(e){t(new window.Blob([e.get()],{type:"application/pdf"}))}))}function kh(e,t){var n=e[t.nodeType];return n?n.call.apply(n,arguments):t}function xh(e,t,n){e.options._pdfDebug&&t.comment("BEGIN: "+e.options._pdfDebug);var i=e.transform();var 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=Fh(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(gh[o],0);var a=n.lineCap;a&&t.setLineCap(vh[a]);var s=n.lineJoin;s&&t.setLineJoin(_h[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 sl||n instanceof vl)return;var i=n.color;if(i){if(null==(i=Fh(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&&(Ah(i,t,n),t.clip())}(e,t,n),kh({Path:Dh,MultiPath:Eh,Circle:Ih,Arc:zh,Text:Ph,Image:Hh,Group:Bh,Rect:Rh},e,t,n),t.restore(),e.options._pdfDebug&&t.comment("END: "+e.options._pdfDebug)}function Ch(e){return e&&(e instanceof sl||e instanceof vl||e.color&&!/^(none|transparent)$/i.test(e.color)&&(null==e.width||e.width>0)&&(null==e.opacity||e.opacity>0))}function Sh(e,t,n,i){var r=e.fill();if(r instanceof sl){i?t.clipStroke():t.clip();var o=r instanceof cl;var a,s;o?(a={x:r.center().x,y:r.center().y,r:0},s={x:r.center().x,y:r.center().y,r:r.radius()}):(a={x:r.start().x,y:r.start().y},s={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=Fh(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:o?"radial":"linear",start:a,end:s,stops:l};var d=e.rawBBox();var h=d.topLeft(),u=d.getSize();return d={left:h.x,top:h.y,width:u.width,height:u.height},t.gradient(c,d),!0}}function Th(e,t,n,i){var r=e.fill();if(r instanceof vl){i?t.clipStroke():t.clip();var o=e.rawBBox();var a=o.topLeft(),s=o.getSize();var l=e.stroke()?e.stroke().width:0;return t.pattern(r,{left:a.x+l/2,top:a.y+l/2,width:s.width-l,height:s.height-l},Lh),!0}}function Mh(e,t,n){Ch(e.fill())&&Ch(e.stroke())?Sh(e,t,0,!0)||Th(e,t,0,!0)||t.fillStroke():Ch(e.fill())?Sh(e,t,0,!1)||Th(e,t,0,!1)||t.fill():Ch(e.stroke())?t.stroke():t.nop()}function Ah(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){var i=[];for(var 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];var s=a.anchor();if(r){var l=r.controlOut();var 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 Dh(e,t,n){Ah(e,t),Mh(e,t)}function Eh(e,t,n){var i=e.paths;for(var r=0;r<i.length;++r)Ah(i[r],t);Mh(e,t)}function Ih(e,t,n){var i=e.geometry();t.circle(i.center.x,i.center.y,i.radius),Mh(e,t)}function zh(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);Mh(e,t)}function Ph(e,t){var n=ch(e.options.font);var i=e._position;var r;t.transform(1,0,0,-1,i.x,i.y+n.fontSize);var o=function(i){t.beginText(),t.setFont(dh(n),n.fontSize),t.setTextRenderingMode(i),t.showText(e.content(),e._pdfRect?e._pdfRect.width():null)};e.fill()&&e.stroke()?(r=mh.fillAndStroke,"stroke"===e.options.paintOrder&&(o(mh.stroke),r=mh.fill)):e.fill()?r=mh.fill:e.stroke()&&(r=mh.stroke),o(r),t.endText()}function Lh(e,t,n){var i=e.children;for(var r=0;r<i.length;++r)xh(i[r],t,n)}function Bh(e,t,n){e._pdfLink&&t.addLink(e._pdfLink.url,e._pdfLink);var i=e.children;for(var r=0;r<i.length;++r)xh(i[r],t,n)}function Hh(e,t){var n=e.src();if(n){var i=e.rect();var r=i.getOrigin();var o=i.getSize();t.transform(o.width,0,0,-o.height,r.x,r.y+o.height),t.drawImage(n)}}function Rh(e,t,n){var i=e.geometry();var r=i.cornerRadius;var o=r[0];var a=r[1];0===o&&0===a?(t.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),Mh(e,t)):Dh(Rs.fromRect(i,e.options),t)}function Fh(e){var t=_o(e,!0);return t?t.toRGB():null}function Oh(e,t){var n=Co();for(var i in t)"margin"==i&&e.options.pdf&&e.options.pdf._ignoreMargin||e.options.set("pdf."+i,t[i]);return wh(e,n.resolve),n}var Vh=Object.freeze({__proto__:null,BinaryStream:Kc,Document:Ed,TEXT_RENDERING_MODE:fh,clearImageCache:Td,defineFont:ph,exportPDF:Oh,exportPDFToBlob:function(e,t){var n=Co();for(var i in t)"margin"==i&&e.options.pdf&&e.options.pdf._ignoreMargin||e.options.set("pdf."+i,t[i]);return window.Blob&&!io.browser.safari?yh(e,n.resolve):wh(e,n.resolve),n},getFontURL:dh,getPaperOptions:xd,loadFonts:Md,loadImages:Dd,parseFontDef:ch,render:bh,saveAs:function(e,t,n,i){window.Blob&&!io.browser.safari?yh(e,(function(e){to({dataURI:e,fileName:t}),i&&i(e)})):wh(e,(function(e){to({dataURI:e,fileName:t,proxyURL:n}),i&&i(e)}))},toBlob:yh,toDataURL:wh});var Nh=io.browser||{};function $h(e){return Array.prototype.slice.call(e)}var Uh="KENDO-PSEUDO-ELEMENT";var Wh="data-kendo-bullet-type";var jh={};var qh={};qh._root=qh;var Gh=!!("undefined"!=typeof window)&&(Nh.msie||Nh.edge);var Kh=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}(Vs);function Yh(e,t){Object.keys(t).forEach((function(n){e.style[n]=t[n]}))}var Qh="undefined"!=typeof Element&&Element.prototype&&((Xh=Element.prototype).matches?function(e,t){return e.matches(t)}:Xh.webkitMatchesSelector?function(e,t){return e.webkitMatchesSelector(t)}:Xh.mozMatchesSelector?function(e,t){return e.mozMatchesSelector(t)}:Xh.msMatchesSelector?function(e,t){return e.msMatchesSelector(t)}:function(e){return-1!==[].indexOf.call(document.querySelectorAll(e),this)});var Xh;function Zh(e,t){if(e.closest)return e.closest(t);for(;e&&!/^\[object (?:HTML)?Document\]$/.test(String(e));){if(1==e.nodeType&&Qh(e,t))return e;e=e.parentNode}}var Jh=function(e){return e?function t(n){var i=n.cloneNode(!1);if(1==n.nodeType){var r,o=e(n),a=e(i);var 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);var n=e.querySelectorAll("canvas");n.length&&$h(t.querySelectorAll("canvas")).forEach((function(e,t){e.getContext("2d").drawImage(n[t],0,0)}));var i=e.querySelectorAll("input, select, textarea, option");return $h(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 eu(e,t){t||(t={});var n=Co();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+.");ph(au(e.ownerDocument));var i="number"==typeof(r=t.scale||1)?{x:r,y:r}:Array.isArray(r)?{x:r[0],y:r[1]}:{x:r.x,y:r.y};var r;function o(e){var n=new Us;var r=e.getBoundingClientRect();var o,a;return Au(n,[i.x,0,0,i.y,-r.left*i.x,-r.top*i.y]),qh._clipbox=!1,qh._matrix=Jo.unit(),qh._stackingContext={element:e,group:n},!0===t.avoidLinks?qh._avoidLinks="a":qh._avoidLinks=t.avoidLinks,a="k-pdf-export",(o=e).classList?o.classList.add(a):o.className+=" "+a,ju(e,n),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"),n}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");Hl(i,n),n=i.firstElementChild}return n}:function(){return e.cloneNode(!0)}}return fu([e],(function(){var r=t&&t.forcePageBreak;var s=t&&t.paperSize&&"auto"!=t.paperSize;var l=xd((function(e,n){return"paperSize"==e?s?t[e]:"A4":e in t?t[e]:n}));var c=s&&l.paperSize[0];var d=s&&l.paperSize[1];var h=t.margin&&l.margin;var u=Boolean(h);if(r||d){h||(h={left:0,top:0,right:0,bottom:0}),c&&(c/=i.x),d&&(d/=i.y),h.left/=i.x,h.right/=i.x,h.top/=i.y,h.bottom/=i.y;var p=new Us({pdf:{multiPage:!0,paperSize:s?l.paperSize:"auto",_ignoreMargin:u}});!function(e,t,n,i,r,o,s){var l=a(s.template);var c=t.ownerDocument;var d=[];var h=s._destructive?t:Jh(t);var u=c.createElement("KENDO-PDF-DOCUMENT");var p=0;$h(h.querySelectorAll("tfoot")).forEach((function(e){e.parentNode.appendChild(e)})),$h(h.querySelectorAll("ol")).forEach((function(e){$h(e.children).forEach((function(e,t){e.setAttribute("kendo-split-index",t)}))})),Yh(u,{display:"block",position:"absolute",boxSizing:"content-box",left:"-10000px",top:"-10000px"}),i&&(Yh(u,{width:i+"px",paddingLeft:o.left+"px",paddingRight:o.right+"px"}),Yh(h,{overflow:"hidden"}));t.parentNode.insertBefore(u,t),u.appendChild(h),s.beforePageBreak?pu([u],(function(){s.beforePageBreak(u,f)})):pu([u],f);function f(){("-"!=n||r)&&g(h);var t=b();h.parentNode.insertBefore(t,h),t.appendChild(h),l&&d.forEach((function(e,t){var n=l({element:e,pageNum:t+1,totalPages:d.length});n&&e.appendChild(n)})),fu(d,e.bind(null,{pages:d,container:u}))}function m(e){if(s.keepTogether&&Qh(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&&Yh(e,{tableLayout:"fixed"}),!m(e)){var t=bu(e);var i=parseFloat(wu(t,"padding-bottom"));var o=parseFloat(wu(t,"border-bottom-width"));var a=p;p+=i+o;var s=!0;for(var l=e.firstChild;l;l=l.nextSibling)if(1==l.nodeType){if(s=!1,Qh(l,n)){_(l);continue}if(!r){g(l);continue}if(!/^(?:static|relative)$/.test(wu(bu(l),"position")))continue;var c=w(l);1==c||c&&m(l)?_(l):g(l)}else 3==l.nodeType&&r&&(y(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!==h&&v(e))return _(e.parentNode);var t,n,i,r,o;n=(t=Zh(e,"table"))&&t.querySelector("colgroup"),s.repeatHeaders&&(i=t&&t.querySelector("thead"),(r=Zh(e,".k-grid"))&&r.querySelector(".k-auto-scrollable")&&(o=r.querySelector(".k-grid-header")));var a=b();var l=c.createRange();l.setStartBefore(h),l.setEndBefore(e),a.appendChild(l.extractContents()),h.parentNode.insertBefore(a,h),k(e.parentNode),t&&(t=Zh(e,"table"),s.repeatHeaders&&i&&t.insertBefore(i.cloneNode(!0),t.firstChild),n&&t.insertBefore(n.cloneNode(!0),t.firstChild)),s.repeatHeaders&&o&&(r=Zh(e,".k-grid")).insertBefore(o.cloneNode(!0),r.firstChild)}function b(){var e=c.createElement("KENDO-PDF-PAGE");return Yh(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 w(e){var t=e.getBoundingClientRect();if(0===t.width||0===t.height)return 0;var n=h.getBoundingClientRect().top;var i=r-p;return t.height>i?3:t.top-n>i?1:t.bottom-n>i?2:0}function y(e,t){if(/\S/.test(e.data)){var n=e.data.length;var i=c.createRange();i.selectNodeContents(e);var r=w(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:w(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(h),a.appendChild(i.extractContents()),h.parentNode.insertBefore(a,h),k(o.parentNode)}y(o)}}}function k(e){var t=Zh(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,r,c?c-h.left-h.right:null,d?d-h.top-h.bottom:null,h,t)}else n.resolve(o(e))})),n}function tu(e){var t=new Us;return qh._clipbox=!1,qh._matrix=Jo.unit(),qh._stackingContext={element:e,group:t},gu(e,bu(e),t),3==e.firstChild.nodeType?Wu(e,e.firstChild,t):Ou(e,t),vu(),t}var nu=function(){var e=/^((-webkit-|-moz-|-o-|-ms-)?linear-gradient\s*)\(/;var t=/^([-0-9.]+%)/;var n=/^([-0-9.]+px)/;var i=/^(left|right|top|bottom|to|center)\W/;var r=/^([-0-9.]+(deg|grad|rad|turn)|0)/;var o=/^(\s+)/;var a=/^(\()/;var s=/^(\))/;var l=/^(,)/;var c=/^(url)\(/;var d=/^(.*?)\)/;var h={},u={};function p(u){var p=u;if(su(h,p))return h[p];function f(e){!function(){var e=o.exec(u);e&&(u=u.substr(e[1].length))}();var t=e.exec(u);if(t)return u=u.substr(t[1].length),t[1]}function m(){var e=_o(u,!0);var i,r;if(e){var o=/^#[0-9a-f]+/i.exec(u)||/^rgba?\(.*?\)/i.exec(u)||/^..*?\b/.exec(u);return u=u.substr(o[0].length),e=e.toRGB(),(i=f(n))||(r=f(t)),{color:e,length:i,percent:r}}}var g;return(g=f(e))?g=function(e){var n;var o,c;var d=[];var h=!1;if(f(a)){if("0"==(n=f(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),f(l)):("to"==(o=f(i))?o=f(i):o&&/^-/.test(e)&&(h=!0),c=f(i),f(l)),/-moz-/.test(e)&&null==n&&null==o){var p=f(t),g=f(t);h=!0,"0%"==p?o="left":"100%"==p&&(o="right"),"0%"==g?c="top":"100%"==g&&(c="bottom"),f(l)}for(;u&&!f(s);){var v=m();if(!v)break;d.push(v),f(l)}return{type:"linear",angle:n,to:o&&c?o+" "+c:o||c||null,stops:d,reverse:h}}}(g):(g=f(c))&&(g=function(){if(f(a)){var e=f(d);return e=e.replace(/^['"]+|["']+$/g,""),f(s),{type:"url",url:e}}}()),h[p]=g||{type:"none"}}return function(e){return su(u,e)?u[e]:u[e]=iu(e).map(p)}}();var iu=function(){var e={};return function(t,n){n||(n=/^\s*,\s*/);var i=t+n;if(su(e,i))return e[i];var r=[];var o=0,a=0;var s=0;var l=!1;var c;function d(e){return c=e.exec(t.substr(a))}function h(e){return e.replace(/^\s+|\s+$/g,"")}for(;a<t.length;)!l&&d(/^[\(\[\{]/)?(s++,a++):!l&&d(/^[\)\]\}]/)?(s--,a++):!l&&d(/^[\"\']/)?(l=c[0],a++):"'"==l&&d(/^\\\'/)||'"'==l&&d(/^\\\"/)?a+=2:"'"==l&&d(/^\'/)||'"'==l&&d(/^\"/)?(l=!1,a++):d(n)?(!l&&!s&&a>o&&(r.push(h(t.substring(o,a))),o=a+c[0].length),a+=c[0].length):a++;return o<a&&r.push(h(t.substring(o,a))),e[i]=r}}();var ru=function(e){return function(t){var n=e[t];var i;n||((i=/url\((['"]?)([^'")]*?)\1\)\s+format\((['"]?)truetype\3\)/.exec(t))||(i=/url\((['"]?)([^'")]*?\.ttf)\1\)/.exec(t)))&&(n=e[t]=i[2]);return n}}(Object.create(null));var ou=function(e){return function(t){var n=e[t];return null==n&&(n=e[t]=ha("Mapq",{font:t}).height),n}}(Object.create(null));function au(e){null==e&&(e=document);var t={};for(var 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;var l=iu(wu(s,"font-family"));var c=/^([56789]00|bold)$/i.test(wu(s,"font-weight"));var d="italic"==wu(s,"font-style");var h=r(a);h.length>0&&o(e,l,c,d,h[0])}}}(e,t)}}function r(e){var t=wu(e.style,"src");if(t)return iu(t).reduce((function(e,t){var n=ru(t);return n&&e.push(n),e}),[]);var n=ru(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 su(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function lu(e,t){var n=qh;for(e="_counter_"+e;n&&!su(n,e);)n=Object.getPrototypeOf(n);n||(n=qh._root),n[e]=(n[e]||0)+(null==t?1:t)}function cu(e,t){qh[e="_counter_"+e]=null==t?0:t}function du(e,t,n){for(var i=0;i<e.length;){var r=e[i++];var o=parseFloat(e[i]);isNaN(o)?t(r,n):(t(r,o),++i)}}function hu(e){var t=wu(e,"counter-reset");t&&du(iu(t,/^\s+/),cu,0);var n=wu(e,"counter-increment");n&&du(iu(n,/^\s+/),lu,1)}function uu(e,t){var n=_o(e,!0);return n&&(n=n.toRGB(),t?n=n.toCssRgba():0===n.a&&(n=null)),n}function pu(e,t){var n=0;var i=!1;function r(){!i&&--n<=0&&(t(),i=!0)}e.forEach((function(e){var t=e.querySelectorAll("img");for(var i=0;i<t.length;++i){var o=t[i];o.complete||(n++,o.onload=o.onerror=r)}})),n||r()}function fu(e,t){var n=[];function i(e){jh[e]||(jh[e]=!0,n.push(e))}e.forEach((function e(t){/^img$/i.test(t.tagName)&&i(t.src),nu(wu(bu(t),"background-image")).forEach((function(e){"url"==e.type&&i(e.url)})),t.children&&$h(t.children).forEach(e)}));var r=n.length;function o(){--r<=0&&pu(e,t)}0===r&&o(),n.forEach((function(e){var t=jh[e]=new window.Image;/^data:/i.test(e)||(t.crossOrigin="Anonymous"),t.src=e,t.complete?o():(t.onload=o,t.onerror=function(){jh[e]=null,o()})}))}function mu(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 gu(e,t,n){(qh=Object.create(qh))[e.tagName.toLowerCase()]={element:e,style:t};var i=wu(t,"text-decoration");if(i&&"none"!=i){var r=wu(t,"text-decoration-color");i.split(/\s+/g).forEach((function(e){if(!qh[e]&&(qh[e]=r,"underline"==e)){var n=wu(t,"text-underline-offset");"auto"!=n&&(qh["underline-offset"]=parseFloat(n))}}))}(function(e){function t(t){return wu(e,t)}if("none"!=t("transform")||"static"!=t("position")||"auto"!=t("z-index")||t("opacity")<1)return!0})(t)&&(qh._stackingContext={element:e,group:n})}function vu(){qh=Object.getPrototypeOf(qh)}function _u(e){if(null!=qh._clipbox){var t=e.bbox(qh._matrix);qh._clipbox?qh._clipbox=ya.intersect(qh._clipbox,t):qh._clipbox=t}}function bu(e,t){return window.getComputedStyle(e,t||null)}function wu(e,t,n){var i=e.getPropertyValue(t);return null!=i&&""!==i||(Nh.webkit?i=e.getPropertyValue("-webkit-"+t):Nh.mozilla?i=e.getPropertyValue("-moz-"+t):Nh.opera?i=e.getPropertyValue("-o-"+t):Gh&&(i=e.getPropertyValue("-ms-"+t))),arguments.length>2&&(null==i||""===i)?n:i}function yu(e,t,n,i){e.setProperty(t,n,i),Nh.webkit?e.setProperty("-webkit-"+t,n,i):Nh.mozilla?e.setProperty("-moz-"+t,n,i):Nh.opera?e.setProperty("-o-"+t,n,i):Gh&&(e.setProperty("-ms-"+t,n,i),e[t="ms"+t.replace(/(^|-)([a-z])/g,(function(e,t,n){return t+n.toUpperCase()}))]=n)}function ku(e,t){return t="border-"+t,{width:parseFloat(wu(e,t+"-width")),style:wu(e,t+"-style"),color:uu(wu(e,t+"-color"),!0)}}function xu(e,t){var n=e.style.cssText;var i=t();return zl(e,n),i}function Cu(e,t){var n=wu(e,"border-"+t+"-radius").split(/\s+/g).map(parseFloat);return 1==n.length&&n.push(n[0]),Iu({x:n[0],y:n[1]})}function Su(e){var t=e.getBoundingClientRect();return t=Tu(t,"border-*-width",e),t=Tu(t,"padding-*",e)}function Tu(e,t,n){var i,r,o,a,s;return"string"==typeof t?(i=bu(n),r=parseFloat(wu(i,t.replace("*","top"))),o=parseFloat(wu(i,t.replace("*","right"))),a=parseFloat(wu(i,t.replace("*","bottom"))),s=parseFloat(wu(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 Mu(e){return 180*e/Math.PI%360}function Au(e,t){return t=new Jo(t[0],t[1],t[2],t[3],t[4],t[5]),e.transform(t),t}function Du(e,t){e.clip(t)}function Eu(e,t,n,i){var r=new $a([t,n],i).curvePoints(),o=1;for(;o<r.length;)e.curveTo(r[o++],r[o++],r[o++])}function Iu(e){return(e.x<=0||e.y<=0)&&(e.x=e.y=0),e}function zu(e,t,n,i,r){var o=Math.max(0,t.x),a=Math.max(0,t.y);var s=Math.max(0,n.x),l=Math.max(0,n.y);var c=Math.max(0,i.x),d=Math.max(0,i.y);var h=Math.max(0,r.x),u=Math.max(0,r.y);var p=Math.min(e.width/(o+s),e.height/(l+d),e.width/(c+h),e.height/(u+a));return p<1&&(o*=p,a*=p,s*=p,l*=p,c*=p,d*=p,h*=p,u*=p),{tl:{x:o,y:a},tr:{x:s,y:l},br:{x:c,y:d},bl:{x:h,y:u}}}function Pu(e,t,n){var i=bu(e);var r=Cu(i,"top-left");var o=Cu(i,"top-right");var a=Cu(i,"bottom-left");var s=Cu(i,"bottom-right");if("padding"==n||"content"==n){var l=ku(i,"top");var c=ku(i,"right");var d=ku(i,"bottom");var h=ku(i,"left");if(r.x-=h.width,r.y-=l.width,o.x-=c.width,o.y-=l.width,s.x-=c.width,s.y-=d.width,a.x-=h.width,a.y-=d.width,"content"==n){var u=parseFloat(wu(i,"padding-top"));var p=parseFloat(wu(i,"padding-right"));var f=parseFloat(wu(i,"padding-bottom"));var m=parseFloat(wu(i,"padding-left"));r.x-=m,r.y-=u,o.x-=p,o.y-=u,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),Lu(t,r,o,s,a)}function Lu(e,t,n,i,r){var o=zu(e,t,n,i,r);var a=o.tl;var s=o.tr;var l=o.br;var c=o.bl;var d=new Rs({fill:null,stroke:null});return d.moveTo(e.left,e.top+a.y),a.x&&Eu(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&&Eu(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&&Eu(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&&Eu(d,e.left+c.x,e.bottom-c.y,{startAngle:90,endAngle:180,radiusX:c.x,radiusY:c.y}),d.close()}function Bu(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 xo(e).toLowerCase();case"upper-roman":return xo(e).toUpperCase();case"lower-latin":case"lower-alpha":return mu(e-1);case"upper-latin":case"upper-alpha":return mu(e-1).toUpperCase();default:return n}}function Hu(e,t){function n(e,t,n){return n?(n=n.replace(/^\s*(["'])(.*)\1\s*$/,"$2"),function(e){var t=[],n=qh;for(e="_counter_"+e;n;)su(n,e)&&t.push(n[e]),n=Object.getPrototypeOf(n);return t.reverse()}(e).map((function(e){return Bu(e,t)})).join(n)):Bu(function(e){return qh[e="_counter_"+e]}(e)||0,t)}var i=iu(t,/^\s+/);var r,o=[];return i.forEach((function(t){var i;(r=/^\s*(["'])(.*)\1\s*$/.exec(t))?o.push(r[2].replace(/\\([0-9a-f]{4})/gi,(function(e,t){return String.fromCharCode(parseInt(t,16))}))):(r=/^\s*counter\((.*?)\)\s*$/.exec(t))?(i=iu(r[1]),o.push(n(i[0],i[1]))):(r=/^\s*counters\((.*?)\)\s*$/.exec(t))?(i=iu(r[1]),o.push(n(i[0],i[2],i[1]))):(r=/^\s*attr\((.*?)\)\s*$/.exec(t))?o.push(e.getAttribute(r[1])||""):o.push(t)})),o.join("")}function Ru(e){if(e.cssText)return e.cssText;var t=[];for(var n=0;n<e.length;++n)t.push(e[n]+": "+wu(e,e[n]));return t.join(";\n")}function Fu(e,t){if(e.tagName!=Uh){var n=[];if(r(":before",e.firstChild),r(":after",null),n.length>0){var i=e.className;e.className+=" kendo-pdf-hide-pseudo-elements",Ou(e,t),e.className=i,n.forEach((function(t){e.removeChild(t)}))}else Ou(e,t)}else Ou(e,t);function r(t,i){var r=bu(e,t),o=r.content;if(hu(r),o&&"normal"!=o&&"none"!=o&&"0px"!=r.width){var a=e.ownerDocument.createElement(Uh);zl(a,Ru(r)),a.textContent=Hu(e,o),e.insertBefore(a,i),n.push(a)}}}function Ou(e,t){var n=bu(e);var i=ku(n,"top");var r=ku(n,"right");var o=ku(n,"bottom");var a=ku(n,"left");var s=Cu(n,"top-left");var l=Cu(n,"top-right");var c=Cu(n,"bottom-left");var d=Cu(n,"bottom-right");var h=wu(n,"direction");var u=wu(n,"background-color");u=uu(u);var p=nu(wu(n,"background-image"));var f=iu(wu(n,"background-repeat"));var m=iu(wu(n,"background-position"));var g=iu(wu(n,"background-origin"));var v=iu(wu(n,"background-size"));var _,b;Gh&&"ellipsis"==(_=n.textOverflow)&&(b=e.style.textOverflow,e.style.textOverflow="clip"),Nh.msie&&Nh.version<10&&(m=iu(e.currentStyle.backgroundPosition));var w=Tu(e.getBoundingClientRect(),"border-*-width",e);var y,k,x;!function(){var e=wu(n,"clip");var i=/^\s*rect\((.*)\)\s*$/.exec(e);if(i){var r=i[1].split(/[ ,]+/g);var o="auto"==r[0]?w.top:parseFloat(r[0])+w.top;var a="auto"==r[1]?w.right:parseFloat(r[1])+w.left;var s="auto"==r[2]?w.bottom:parseFloat(r[2])+w.top;var l="auto"==r[3]?w.left:parseFloat(r[3])+w.left;var c=new Us;var d=(new Rs).moveTo(l,o).lineTo(a,o).lineTo(a,s).lineTo(l,s).close();Du(c,d),t.append(c),t=c,_u(d)}}();var C=wu(n,"display");if("table-row"==C)for(y=[],k=0,x=e.children;k<x.length;++k)y.push(x[k].getBoundingClientRect());else 1==(y=e.getClientRects()).length&&(y=[e.getBoundingClientRect()]);for(y=function(t){if(/^td$/i.test(e.tagName)){var n=qh.table;if(n&&"collapse"==wu(n.style,"border-collapse")){var i=ku(n.style,"left").width;var r=ku(n.style,"top").width;if(0===i&&0===r)return t;var o=n.element.getBoundingClientRect();var a=n.element.rows[0].cells[0].getBoundingClientRect();if(a.top==o.top||a.left==o.left)return $h(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),k=0;k<y.length;++k)A(y[k],0===k,k==y.length-1);if("A"==e.tagName&&e.href&&!/^#?$/.test(e.getAttribute("href"))&&(!qh._avoidLinks||!Qh(e,qh._avoidLinks))){var S=document.createRange();S.selectNodeContents(e),$h(S.getClientRects()).forEach((function(n){var i=new Us;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=wu(n,"list-style-type");if("none"==i)return;var r=wu(n,"list-style-position");function o(n){xu(e,(function(){e.style.position="relative";var i=e.ownerDocument.createElement(Uh);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),ju(i,t),e.removeChild(i)}))}function a(t){var n=e.parentNode.children;var 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=" ",e.setAttribute(Wh,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=xo(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=mu(t),/^upper/i.test(i)&&(t=t.toUpperCase()),e.innerHTML=t+"."}))}))}}(y[0]),function(){function i(){var n=Pu(e,w,"padding");var i=new Us;Du(i,n),t.append(i),t=i,_u(n)}!function(e){return/^(?:textarea|select|input)$/i.test(e.tagName)}(e)?(/^(hidden|auto|scroll)/.test(wu(n,"overflow"))||/^(hidden|auto|scroll)/.test(wu(n,"overflow-x"))||/^(hidden|auto|scroll)/.test(wu(n,"overflow-y")))&&i():i()}(),function(e,t){var n;if(e._kendoExportVisual){var i=e.getBoundingClientRect();var 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 Us;a.children.push(n);var s=e.getBoundingClientRect();return a.transform(xa().translate(s.left,s.top)),t.append(a),!0}(e,t)||function(e,t){var n=e.getAttribute(Wh);if(!n)return!1;var i=e.getBoundingClientRect();var r=bu(e).color;if("square"===n){var o=i.height/5;t.append(new Xs(new ya([i.right-o,i.top+i.height/2.1],[o,o])).fill(r).stroke(r))}else{var a=i.height/7;var s=[i.right-a,i.top+(i.height+a)/2];var l=new Ra(new Ia(s,a));"circle"===n?l.stroke(r,.5):l.fill(r).stroke(null),t.append(l)}return!0}(e,t)||Uu(e,t),Gh&&"ellipsis"==_&&(e.style.textOverflow=b),t;function T(e,n,i,r,o,a,s,l){if(!(i<=0)){var c,d=new Us;Au(d,l),t.append(d),Iu(a),Iu(s),c=new Rs({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&&h(r,a,[-1,0,0,1,a.x,0]),s.x&&h(o,s,[1,0,0,1,n-s.x,0])}function h(t,n,r){var o=Math.PI/2*t/(t+i);var a={x:n.x-t,y:n.y-i};var s=new Rs({fill:{color:e},stroke:null}).moveTo(0,0);Au(s,r),Eu(s,0,n.y,{startAngle:-90,endAngle:-Mu(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)),Eu(s,0,n.y,{startAngle:-Mu(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 M(t,n,i,r,o,a,s){var l;if(i&&"none"!=i)if("url"==i.type){var c=jh[i.url];c&&c.width>0&&c.height>0&&d(t,n,c.width,c.height,(function(e,t){e.append(new Ns(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));var a=Math.atan(n*Math.tan(r)/i);var s=Math.sin(a),c=Math.cos(a);var d=Math.abs(s)+Math.abs(c);var h=d/2*s;var u=d/2*c;r>Math.PI/2&&r<=3*Math.PI/2&&(h=-h,u=-u);var p=[],f=0;var 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}));var g=[.5-h,.5+u];var v=[.5+h,.5-u];e.append(Rs.fromRect(t).stroke(null).fill(new ll({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,h=i/l;var u=n;if("content-box"==a?(u=Tu(u,"border-*-width",e),u=Tu(u,"padding-*",e)):"padding-box"==a&&(u=Tu(u,"border-*-width",e)),!/^\s*auto(\s+auto)?\s*$/.test(s))if("contain"==s)d=Math.min(u.width/i,u.height/l),i*=d,l*=d;else if("cover"==s)d=Math.max(u.width/i,u.height/l),i*=d,l*=d;else{var p=s.split(/\s+/g);i=/%$/.test(p[0])?u.width*parseFloat(p[0])/100:parseFloat(p[0]),l=1==p.length||"auto"==p[1]?i/h:/%$/.test(p[1])?u.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*(u.width-i):f[0]=parseFloat(f[0]),/%$/.test(f[1])?f[1]=parseFloat(f[1])/100*(u.height-l):f[1]=parseFloat(f[1]);var m=new ya([u.left+f[0],u.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();var b=m.origin.clone();for(;m.origin.y<n.bottom;)m.origin.x=b.x,_(),m.origin.y+=l}}}function A(n,_,b){if(0!==n.width&&0!==n.height){!function(e){var n=new Us;if(Du(n,Lu(e,s,l,d,c)),t.append(n),u){var i=new Rs({fill:{color:u.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=p.length;--r>=0;)M(n,e,p[r],f[r%f.length],m[r%m.length],g[r%g.length],v[r%v.length])}(n);var w=a.width>0&&(_&&"ltr"==h||b&&"rtl"==h);var y=r.width>0&&(b&&"ltr"==h||_&&"rtl"==h);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&&w&&y){n=Tu(n,i.width/2);var k=Pu(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 Rs({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 Rs({stroke:{width:o.width,color:o.color}}).moveTo(n.left,n.bottom-o.width/2).lineTo(n.right,n.bottom-o.width/2)),w&&t.append(new Rs({stroke:{width:a.width,color:a.color}}).moveTo(n.left+a.width/2,n.top).lineTo(n.left+a.width/2,n.bottom)),void(y&&t.append(new Rs({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=zu(n,s,l,d,c);var C=x.tl;var S=x.tr;var A=x.br;var D=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,D,[-1,0,0,-1,n.right,n.bottom]),T(a.color,n.height,a.width,o.width,i.width,E(D),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 Vu(e,t,n){var i=Su(e);var r=new ya([i.left,i.top],[i.width,i.height]);var o=new Ns(t,r);Du(o,Pu(e,i,"content")),n.append(o)}function Nu(e,t){var n=bu(e);var i=bu(t);var r=parseFloat(wu(n,"z-index"));var o=parseFloat(wu(i,"z-index"));var a=wu(n,"position");var s=wu(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 $u(e,t){var n=e.tagName.toLowerCase();if("input"==n&&("checkbox"==e.type||"radio"==e.type))return function(e,t){var n=wu(bu(e),"color");var i=e.getBoundingClientRect();"checkbox"==e.type?(t.append(Rs.fromRect(new ya([i.left+1,i.top+1],[i.width-2,i.height-2])).stroke(n,1)),e.checked&&t.append((new Rs).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 Ra(new Ia([(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 Ra(new Ia([(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=e.parentNode;var r=e.ownerDocument;var o=r.createElement(Uh);var a;if(zl(o,Ru(bu(e))),"input"==n&&(o.style.whiteSpace="pre"),"select"!=n&&"textarea"!=n||(o.style.overflow="auto"),"select"==n)if(e.multiple)for(var s=0;s<e.options.length;++s)a=r.createElement(Uh),zl(a,Ru(bu(e.options[s]))),a.style.display="block",a.textContent=e.options[s].textContent,o.appendChild(a);else a=function(e){return e.selectedOptions&&e.selectedOptions.length>0?e.selectedOptions[0]:e.options[e.selectedIndex]}(e),a&&(o.textContent=a.textContent);else o.textContent=e.value;i.insertBefore(o,e),o.scrollLeft=e.scrollLeft,o.scrollTop=e.scrollTop,e.style.display="none",Uu(o,t),e.style.display="",i.removeChild(o)}function Uu(e,t){switch(qh._stackingContext.element===e&&(qh._stackingContext.group=t),e.tagName.toLowerCase()){case"img":Vu(e,e.src,t);break;case"svg":var n=function(e){var t=new window.XMLSerializer;var n=t.serializeToString(e);if(Nh.mozilla&&(!e.getAttribute("width")||!e.getAttribute("height"))){var i=(new window.DOMParser).parseFromString(n,"image/svg+xml").documentElement;var r=Su(e);i.setAttribute("width",r.width),i.setAttribute("height",r.height),n=t.serializeToString(i)}return n}(e);Vu(e,"data:image/svg+xml;base64,"+Bo(n),t);break;case"canvas":try{Vu(e,e.toDataURL("image/png"),t)}catch(e){}break;case"textarea":case"input":case"select":$u(e,t);break;default:var i=[],r=[],o=[];for(var a=e.firstChild;a;a=a.nextSibling)switch(a.nodeType){case 3:/\S/.test(a.data)&&Wu(e,a,t);break;case 1:var s=bu(a);var l=wu(s,"float");"static"!=wu(s,"position")?o.push(a):"none"!=l?r.push(a):i.push(a)}No(i,Nu).forEach((function(e){ju(e,t)})),No(r,Nu).forEach((function(e){ju(e,t)})),No(o,Nu).forEach((function(e){ju(e,t)}))}}function Wu(e,t,n){if(null!=(i=qh._clipbox)&&!(i?0===i.width()||0===i.height():void 0)){var i;var r=bu(e);if(!(parseFloat(wu(r,"text-indent"))<-500)){var o=t.data;var a=0;var s=o.search(/\S\s*$/)+1;if(s){var l=wu(r,"font-size");var c=wu(r,"line-height");var d=[wu(r,"font-style"),wu(r,"font-variant"),wu(r,"font-weight"),l,wu(r,"font-family")].join(" ");if(l=parseFloat(l),c=parseFloat(c),0!==l&&!isNaN(l)){var h=wu(r,"color");var u=e.ownerDocument.createRange();var p="justify"==wu(r,"text-align");var f=wu(r,"column-count",1);var m=wu(r,"white-space");var g=wu(r,"text-transform");var v=e.getBoundingClientRect().width/l*5;0===v&&(v=500);var _=null;var b=qh.underline;var w=qh["line-through"];var y=qh.overline;var k=qh["underline-offset"];for(b&&x((function(e){var t=l/12;var n=e.bottom;n+=null!=k?k:t;T(t,e,b,n)}));!S(););return void((w||y)&&x((function(e){var t=l/12;T(t,e,w,e.bottom-e.height/2.7),T(t,e,y,e.top)})))}}}}function x(e){u.selectNode(t);var n=$h(u.getClientRects());x=function(e){return n.forEach(e)},x(e)}function C(e){if(Gh||Nh.chrome||Nh.safari){var t=e.getClientRects(),n={top:1/0,right:-1/0,bottom:-1/0,left:1/0},i=!1;for(var 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=a;var i,r=o.substr(a).search(/\S/);if(a+=r,r<0||a>=s)return!0;u.setStart(t,a),u.setEnd(t,a+1),i=C(u);var l=!1;if((p||f>1)&&(r=o.substr(a).search(/\s/))>=0){u.setEnd(t,a+r);var b=C(u);b.bottom==i.bottom&&(i=b,l=!0,a+=r)}if(!l){if(r=function e(n,r,o){u.setEnd(t,r);var a=C(u);return a.bottom!=i.bottom&&n<r?e(n,n+r>>1,r):a.right!=i.right?(i=a,r<o?e(r,r+o>>1,o):r):r}(a,Math.min(s,a+v),s),r==a)return!0;if(a=r,0===(r=u.toString().search(/\s+$/)))return!1;r>0&&(u.setEnd(t,u.startOffset+r),i=C(u))}Gh&&(i=u.getClientRects()[0]);var w=u.toString();if(/^(?:pre|pre-wrap)$/i.test(m)){if(/\t/.test(w)){var y=0;for(r=e;r<u.startOffset;++r){var k=o.charCodeAt(r);9==k?y+=8-y%8:10==k||13==k?y=0:y++}for(;(r=w.search("\t"))>=0;){var x=" ".substr(0,8-(y+r)%8);w=w.substr(0,r)+x+w.substr(r+1)}}}else w=w.replace(/\s+/g," ");l||(_=i.bottom),function(e,t){if(Gh&&!isNaN(c)){var i=ou(d);var 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 Kh(e,new ya([t.left,t.top],[t.width,t.height]),{font:d,fill:{color:h}});n.append(o)}(w,i)}function T(e,t,i,r){if(i){var o=new Rs({stroke:{width:e,color:i}});r-=e,o.moveTo(t.left,r).lineTo(t.right,r),n.append(o)}}}function ju(e,t){var n=bu(e);if(hu(n),!/^(style|script|link|meta|iframe|col|colgroup)$/i.test(e.tagName)&&null!=qh._clipbox){var i=parseFloat(wu(n,"opacity"));var r=wu(n,"visibility");var o=wu(n,"display");if(0!==i&&"hidden"!=r&&"none"!=o){var a=function(e){var t=wu(e,"transform");if("none"==t)return null;var n=/^\s*matrix\(\s*(.*?)\s*\)\s*$/.exec(t);if(n){var i=wu(e,"transform-origin");return{matrix:n=n[1].split(/\s*,\s*/g).map(parseFloat),origin:i=i.split(/\s+/g).map(parseFloat)}}}(n);var s;var l=wu(n,"z-index");(a||i<1)&&"auto"==l&&(l=0),s=function(e,t,n){var i;"auto"!=n?(i=qh._stackingContext.group,n=parseFloat(n)):(i=t,n=0);var r=i.children;for(var o=0;o<r.length&&!(null!=r[o]._dom_zIndex&&r[o]._dom_zIndex>n);++o);var a=new Us;if(i.insert(o,a),a._dom_zIndex=n,i!==t&&qh._clipbox){var s=qh._matrix.invert();var l=qh._clipbox.transformCopy(s);Du(a,Rs.fromRect(l))}return a}(0,t,l),i<1&&s.opacity(i*s.opacity()),gu(e,n,s),a?xu(e,(function(){yu(e.style,"transform","none","important"),yu(e.style,"transition","none","important"),"static"==wu(n,"position")&&yu(e.style,"position","relative","important");var t=e.getBoundingClientRect();var i=t.left+a.origin[0];var r=t.top+a.origin[1];var o=[1,0,0,1,-i,-r];o=qu(o,a.matrix),o=qu(o,[1,0,0,1,i,r]),o=Au(s,o),qh._matrix=qh._matrix.multiplyCopy(o),Fu(e,s)})):Fu(e,s),vu()}}}function qu(e,t){var n=e[0],i=e[1],r=e[2],o=e[3],a=e[4],s=e[5];var l=t[0],c=t[1],d=t[2],h=t[3];return[n*l+i*d,n*c+i*h,r*l+o*d,r*c+o*h,a*l+s*d+t[4],a*c+s*h+t[5]]}window.kendo=window.kendo||{},kendo.deepExtend(kendo,{parseColor:_o,namedColors:ao,Color:bo});!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",h="deactivate",u="activate",p="center",f="left",m="right",g="top",v="bottom",_="absolute",b="hidden",w="body",y="location",k="position",x="visible",C="effects",S="k-active",T=".k-picker-wrap, .k-dropdown-wrap, .k-link",M=e(document.documentElement),A=e(window),D="scroll",E="transform",I=e.extend,z=".kendoPopup",P=["font-size","font-family","font-stretch","font-style","font-weight","line-height"];function L(t,n){return!(!t||!n)&&(t===n||e.contains(t,n))}var B=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");var 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(u)}}),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,u,d,h],options:{name:"Popup",toggleEvent:"click",origin:v+" "+f,position:g+" "+f,anchor:w,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;var t=e.wrapper.data(y);e.wrapper.hide(),t&&e.wrapper.css(t),e.options.anchor!=w&&e._hideActiveClass(),e._closing=!1,e._trigger(h)},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||(M.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},h=l._shouldCorrectWidth,u=l.element,p=l.options,f=e(p.anchor),m=u[0]&&u.hasClass("km-widget"),v=u.find("[role='listbox']");if(!l.visible()){if(p.copyAnchorStyles&&(m&&"font-size"==P[0]&&P.shift(),u.css(t.getComputedStyles(f[0],P))),l.element.parent().data("animating")||l._trigger(c))return;l._activated=!1,p.modal||(M.off(l.downEvent,l._mousedownProxy).on(l.downEvent,l._mousedownProxy),l._toggleResize(!1),l._toggleResize(!0)),l.wrapper=a=t.wrap(u,p.autosize,p._resizeOnWrap,h,p.autowidth).css({overflow:b,display:"block",position:_}),s=u.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==w||l.element.hasClass("k-tooltip")||l._addActiveClass(),s.hide(),u.show(),l.wrapper.show(),s.data(C,r.effects).kendoStop(!0).kendoAnimate(r),u.attr("aria-hidden",!1)}},_updateDimensions:function(){const e=this;const n=e._shouldCorrectWidth;const i=e.element;const r=e.options;e.wrapper=t.wrap(i,r.autosize,r._resizeOnWrap,n,r.autowidth).css({display:"block",position:_}).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._updateDimensions(),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(),e(document.activeElement).parents(".k-list-filter").length&&e(document.activeElement).blur(),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)})),M.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),i.css({overflow:b}),l.kendoAnimate(r),n&&s._animationClose(),s.element.attr("aria-hidden",!0)}},_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:visible").length>0)&&t.close()},_toggleResize:function(e){var t=e?"on":"off";var n=o.resize;o.mobileOS.ios||o.mobileOS.android||o.browser.safari||(n+=" "+D),e&&!this.scrollableParents&&(this.scrollableParents=this._scrollableParents()),this.scrollableParents&&this.scrollableParents.length&&this.scrollableParents[t](D,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")&&(L(r,l)||L(a,l)||s&&L(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,h,u,p,f=this,m=f.element,g=f.wrapper,v=f.options,_=e(v.viewport),b=o.zoomLevel(),w=!!(_[0]==window&&window.innerWidth&&b<=1.02),x=e(v.anchor),C=v.origin.toLowerCase().split(" "),S=v.position.toLowerCase().split(" "),T=f.collisions,M=10002,A=0,D=document.documentElement;(h=v.viewport===window?{top:window.pageYOffset||document.documentElement.scrollTop||0,left:window.pageXOffset||document.documentElement.scrollLeft||0}:_.offset(),w?(u=window.innerWidth,p=window.innerHeight):(u=_.width(),p=_.height()),w&&D.scrollHeight-D.clientHeight>0)&&(u-=(v.isRtl?-1:1)*t.support.scrollbar());if((i=x.parents().filter(g.siblings()))[0])if(c=Math.max(Number(i.css("zIndex")),0))M=c+10;else for(d=(r=x.parentsUntil(i)).length;A<d;A++)(c=Number(e(r[A]).css("zIndex")))&&M<c&&(M=c+10);g.css("zIndex",M),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-=h.top,z.left-=h.left,f.wrapper.data(y)||g.data(y,I({},E));var P=I({},z),L=I({},E),B=v.adjustSize;"fit"===T[0]&&(L.top+=f._fit(P.top,l(g)+B.height,p/b)),"fit"===T[1]&&(L.left+=f._fit(P.left,s(g)+B.width,u/b));var H=I({},L);var R=l(m);var F=l(g);return!g.height()&&R&&(F+=R),"flip"===T[0]&&(L.top+=f._flip(P.top,R,l(x),p/b,C[0],S[0],F)),"flip"===T[1]&&(L.left+=f._flip(P.left,s(m),s(x),u/b,C[1],S[1],s(g))),g.css(L),L.left!=H.left||L.top!=H.top},_align:function(t,n){var i,r=this,o=r.wrapper,c=e(r.options.anchor),d=t[0],h=t[1],u=n[0],f=n[1],g=a(c),_=e(r.options.appendTo),b=s(o)||s(o.find(".k-child-animation-container").children().first()),w=l(o)||l(o.find(".k-child-animation-container").children().first()),y=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)),u===v&&(x-=w),u===p&&(x-=S(w/2)),h===m&&(C+=y),h===p&&(C+=S(y/2)),f===m&&(C-=b),f===p&&(C-=S(b/2)),{top:x,left:C}}});n.plugin(B);var H=t.support.stableSort;var R="kendoTabKeyTrap";var F=r.extend({init:function(t,n){this.element=e(t),this.element.autoApplyNS(R)},trap:function(){this.element.on("keydown",this._keepInTrap.bind(this))},removeTrap:function(){this.element.kendoDestroy(R)},destroy:function(){this.element.kendoDestroy(R),this.element=undefined},shouldTrap:function(){return!0},_keepInTrap:function(e){if(9===e.which&&this.shouldTrap()&&!e.isDefaultPrevented()){var t=this._focusableElements();var n=this._sortFocusableElements(t);var 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(H)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;var 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=F}(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;var r="k-i-";var o="k-svg-i-";var a="k-flip-";var s=`${a}h`;var l=`${a}v`;var c={svg:(e,t)=>new p(e,t),font:(e,t)=>new u(e,t)};var d={default:"",horizontal:s,vertical:l,both:`${s} ${l}`};var h=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(" "))}});var u=h.extend({init:function(e,t){h.fn.init.call(this,e,t)},options:n({},h.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||""),h.fn._wrapper.call(this)}});var p=h.extend({init:function(e,t){e.empty(),h.fn.init.call(this,e,t)},options:n({},h.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)),h.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:u,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 Gu=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"},areaIcon:{name:"area",content:'<path d="M448 125.27c18.64-6.59 32-24.37 32-45.27 0-7.42-1.68-14.44-4.69-20.71a47.8 47.8 0 0 0-9.37-13.23 47.8 47.8 0 0 0-13.23-9.37C446.44 33.68 439.42 32 432 32c-20.9 0-38.68 13.36-45.27 32H128V32H32v96h32v258.73C45.36 393.32 32 411.1 32 432c0 7.42 1.68 14.44 4.69 20.71 2.36 4.94 5.54 9.41 9.37 13.23 3.82 3.83 8.29 7.01 13.23 9.37C65.56 478.32 72.58 480 80 480c11.24 0 21.58-3.86 29.76-10.34l7.87-7.87.04-.04c3.24-4.1 5.83-8.73 7.6-13.75H384v32h96v-96h-32zm-27.84-56.02c.06-.07.12-.13.18-.19q.345-.375.72-.72c.06-.06.12-.12.19-.18C424.09 65.58 427.87 64 432 64c8.82 0 16 7.18 16 16 0 4.23-1.65 8.07-4.34 10.94q-.345.375-.72.72C440.07 94.35 436.23 96 432 96c-8.82 0-16-7.18-16-16 0-4.13 1.58-7.91 4.16-10.75M302.79 96 96 302.78v-45.52L257.26 96zM128 96h84.06L96 212.06V128h32zM64 64h32v32H64zm27.66 378.94q-.345.375-.72.72C88.07 446.35 84.23 448 80 448c-8.82 0-16-7.18-16-16 0-4.13 1.58-7.91 4.16-10.75.06-.07.12-.13.18-.19q.345-.375.72-.72c.06-.06.12-.12.19-.18C72.09 417.58 75.87 416 80 416c8.82 0 16 7.18 16 16 0 4.23-1.65 8.07-4.34 10.94m9.05-54.25a45 45 0 0 0-4.71-1.96v-38.75L347.98 96h38.75a45 45 0 0 0 1.96 4.71L361.4 128zM125.27 416a45 45 0 0 0-1.96-4.71l287.98-287.98c1.52.74 3.1 1.39 4.71 1.96V163L163.42 416zm83.35 0L416 208.62v45.8L254.42 416zM384 416h-84.38L416 299.62V384h-32zm64 32h-32v-32h32z" />',viewBox:"0 0 512 512"},arrowDownIcon:{name:"arrow-down",content:'<path d="M128 224h96V96h64l.001 128H384L256.001 416z" />',viewBox:"0 0 512 512"},arrowDownLeftIcon:{name:"arrow-down-left",content:'<path d="M384 128v160H224v-64L96 304l128 80v-64h192V128" />',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"},arrowShapeIcon:{name:"arrow-shape",content:'<path d="m480 32-4.81 20.87-1.96 8.47-27.13 117.55-45.2-45.19-158.19 158.19L54.57 480 32 457.43l73.31-73.31 95.88-95.88 18.94-18.93-.02-.02L378.3 111.1l-45.19-45.2 117.55-27.13 8.47-1.96z" />',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"},awardNumberOutlineIcon:{name:"award-number-outline",content:'<path d="m171.98 370-.22-.31h.1l.22.32h-.1Zm-17.75 30.23-36.61-3.34-29.67 50.88 44.2-11.8L144 480l29.94-51.85zM296.65 72.21l25.83 36.61 44.61 4.07 4.07 44.61 36.61 25.83L389 224l18.77 40.67-36.61 25.83-4.07 44.62-44.61 4.07-25.82 36.61-40.67-18.77-40.67 18.77-17.08-24.22-.08-.1-8.61-12.11-14.4-1.48h-.1l-.18-.03-.18-.02-29.8-2.72-4.07-44.61-36.61-25.83 18.77-40.67-18.77-40.67 36.61-25.83 4.07-44.61 44.61-4.07 25.83-36.61L256 90.99zM307.45 32 256 55.75 204.55 32l-32.67 46.3-56.43 5.15-5.15 56.43L64 172.55 87.75 224 64 275.45l46.3 32.67 5.15 56.43 56.31 5.13h.1l.22.32 32.47 46L256 392.25 307.45 416l32.67-46.3 56.43-5.15 5.15-56.43 46.3-32.67L424.25 224 448 172.55l-46.3-32.67-5.15-56.43-56.43-5.15zm50.28 368.23L338 428.17 367.93 480l11.85-44.03 44.2 11.8-29.67-50.88zM255.98 174.6V320h32V127.99h-24s-26.1 32-56 32v32c29.9 0 48-17.4 48-17.4Z" />',viewBox:"0 0 512 512"},awardNumberSolidIcon:{name:"award-number-solid",content:'<path d="m394.33 396.89-36.58 3.34-19.73 27.94L367.95 480l11.85-44.03 44.2 11.8zM448 172.55l-46.3-32.67-5.15-56.43-56.43-5.15L307.45 32 256 55.75 204.55 32l-32.67 46.3-56.43 5.15-5.15 56.43L64 172.55 87.75 224 64 275.45l46.3 32.67 5.15 56.43 56.33 5.14h.1l.22.32L204.55 416 256 392.25 307.45 416l32.67-46.3 56.43-5.15 5.15-56.43 46.3-32.67L424.25 224zM288 320h-32V174.6S237.9 192 208 192v-32c29.9 0 56-32 56-32h24zm-133.75 80.23-36.61-3.34-29.67 50.88 44.2-11.8L144.02 480l29.94-51.85z" />',viewBox:"0 0 512 512"},awardStarOutlineIcon:{name:"award-star-outline",content:'<path d="m154.23 400.23-36.61-3.34-29.67 50.88 44.2-11.8L144 480l29.94-51.85zM296.65 72.21l25.83 36.61 44.61 4.07 4.07 44.61 36.61 25.83L389 224l18.77 40.67-36.61 25.83-4.07 44.62-44.61 4.07-25.82 36.61-40.67-18.77-40.67 18.77-17.08-24.22-.08-.1-8.61-12.11-14.4-1.48h-.1l-.18-.03-.18-.02-29.8-2.72-4.07-44.61-36.61-25.83 18.77-40.67-18.77-40.67 36.61-25.83 4.07-44.61 44.61-4.07 25.83-36.61L256 90.99zM307.45 32 256 55.75 204.55 32l-32.67 46.3-56.43 5.15-5.15 56.43L64 172.55 87.75 224 64 275.45l46.3 32.67 5.15 56.43 56.33 5.14h.1l.22.32L204.55 416 256 392.25 307.45 416l32.67-46.3 56.43-5.15 5.15-56.43 46.3-32.67L424.25 224 448 172.55l-46.3-32.67-5.15-56.43-56.43-5.15zm50.28 368.23L338 428.17 367.93 480l11.85-44.03 44.2 11.8-29.67-50.88zm-50.75-155.18 18.4 82.95-69.4-44.25-69.4 44.25 18.4-82.95-61-55.85 80.45-7.2 31.55-78 31.55 78 80.45 7.2z" />',viewBox:"0 0 512 512"},awardStarSolidIcon:{name:"award-star-solid",content:'<path d="m154.25 400.23-36.61-3.34-29.67 50.88 44.2-11.8L144.02 480l29.94-51.85zM448 172.55l-46.3-32.67-5.15-56.43-56.43-5.15L307.45 32 256 55.75 204.55 32l-32.67 46.3-56.43 5.15-5.15 56.43L64 172.55 87.75 224 64 275.45l46.3 32.67 5.15 56.43 56.33 5.14h.1l.22.32L204.55 416 256 392.25 307.45 416l32.67-46.3 56.43-5.15 5.15-56.43 46.3-32.67L424.25 224zm-141 80.5L325.4 336 256 291.75 186.6 336l18.4-82.95-61-55.85 80.45-7.2L256 112l31.55 78 80.45 7.2zm50.75 147.18-19.73 27.94L367.95 480l11.85-44.03 44.2 11.8-29.67-50.88z" />',viewBox:"0 0 512 512"},banknoteOutlineIcon:{name:"banknote-outline",content:'<path d="M256 288c17.67 0 32-14.33 32-32s-14.33-32-32-32-32 14.33-32 32 14.33 32 32 32m192-128v192H64V160zm32-32H32v256h448zm-113.16 80A59 59 0 0 0 384 225.16v61.68A59 59 0 0 0 366.84 304H145.16A59 59 0 0 0 128 286.84v-61.68A59 59 0 0 0 145.16 208zm22.49-32H122.67c0 4.86-1.31 9.41-3.58 13.33a26.8 26.8 0 0 1-9.75 9.75 26.57 26.57 0 0 1-13.33 3.58v106.67c4.86 0 9.41 1.31 13.33 3.58 4.04 2.34 7.41 5.71 9.75 9.75 2.27 3.93 3.58 8.48 3.58 13.33h266.67c0-4.86 1.31-9.41 3.58-13.33 2.34-4.04 5.71-7.41 9.75-9.75 3.93-2.27 8.48-3.58 13.33-3.58V202.66c-4.86 0-9.41-1.31-13.33-3.58a26.8 26.8 0 0 1-9.75-9.75 26.6 26.6 0 0 1-3.59-13.33" />',viewBox:"0 0 512 512"},banknoteSolidIcon:{name:"banknote-solid",content:'<path d="M32 128v256h448V128zm384 181.33c-4.86 0-9.41 1.31-13.33 3.59a26.66 26.66 0 0 0-9.75 9.75 26.4 26.4 0 0 0-3.59 13.33H122.67c0-4.86-1.31-9.41-3.59-13.33a26.66 26.66 0 0 0-9.75-9.75A26.4 26.4 0 0 0 96 309.33V202.67c4.86 0 9.41-1.31 13.33-3.59a26.66 26.66 0 0 0 9.75-9.75c2.28-3.92 3.59-8.47 3.59-13.33h266.66c0 4.86 1.31 9.41 3.59 13.33a26.66 26.66 0 0 0 9.75 9.75c3.92 2.28 8.47 3.59 13.33 3.59zM366.84 208H145.16A59 59 0 0 1 128 225.16v61.68A59 59 0 0 1 145.16 304h221.68A59 59 0 0 1 384 286.84v-61.68A59 59 0 0 1 366.84 208M256 288c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32" />',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"},bathtubeOutlineIcon:{name:"bathtube-outline",content:'<path d="M448 258.73V96c0-35.35-28.65-64-64-64h-16c-23.88 0-44.71 13.08-55.7 32.46-2.27.27-4.5.66-6.68 1.16C277.2 72.14 256 97.59 256 128v32h128v-32c0-25.13-14.47-46.86-35.53-57.33C353.87 66.49 360.65 64 368 64h16c17.64 0 32 14.35 32 32v160H80c-26.51 0-48 21.49-48 48 0 20.9 13.36 38.68 32 45.27V352c0 70.69 57.31 128 128 128h128c70.69 0 128-57.31 128-128v-2.73c18.64-6.59 32-24.37 32-45.27s-13.36-38.68-32-45.27M352 128h-64c0-11.81 6.44-22.16 16-27.7 4.71-2.73 10.17-4.3 16-4.3s11.29 1.57 16 4.3c9.56 5.54 16 15.89 16 27.7m-32 320H192c-52.93 0-96-43.07-96-96h320c0 52.93-43.07 96-96 96m112-128H80c-8.82 0-16-7.18-16-16s7.18-16 16-16h352c8.82 0 16 7.18 16 16s-7.18 16-16 16M268 176s-12 10.66-12 20c0 6.63 5.37 12 12 12s12-5.37 12-12c0-9.34-12-20-12-20m52 0s-12 10.66-12 20c0 6.63 5.37 12 12 12s12-5.37 12-12c0-9.34-12-20-12-20m52 0s-12 10.66-12 20c0 6.63 5.37 12 12 12s12-5.37 12-12c0-9.34-12-20-12-20" />',viewBox:"0 0 512 512"},bathtubeSolidIcon:{name:"bathtube-solid",content:'<path d="M480 304c0 20.9-13.36 38.68-32 45.27V352c0 70.69-57.31 128-128 128H192c-70.69 0-128-57.31-128-128v-2.73C45.36 342.68 32 324.9 32 304c0-26.51 21.49-48 48-48h336V96c0-17.65-14.36-32-32-32h-16c-7.35 0-14.13 2.49-19.53 6.67C369.53 81.14 384 102.87 384 128v32H256v-32c0-30.41 21.2-55.86 49.62-62.38 2.18-.5 4.41-.89 6.68-1.16C323.29 45.08 344.12 32 368 32h16c35.35 0 64 28.65 64 64v162.73c18.64 6.59 32 24.37 32 45.27M256 196c0-9.34 12-20 12-20s12 10.66 12 20c0 6.63-5.37 12-12 12s-12-5.37-12-12m52 0c0-9.34 12-20 12-20s12 10.66 12 20c0 6.63-5.37 12-12 12s-12-5.37-12-12m52 0c0-9.34 12-20 12-20s12 10.66 12 20c0 6.63-5.37 12-12 12s-12-5.37-12-12" />',viewBox:"0 0 512 512"},bedOutlineIcon:{name:"bed-outline",content:'<path d="M448 224V64c0-17.6-14.4-32-32-32H96c-17.6 0-32 14.4-32 32v160c-17.6 0-32 14.4-32 32v224h32c.07-.12.09-27.83.09-64H448v64h32V256c0-17.6-14.4-32-32-32M96.06 64h319.88l.06.06V224h-32v-95.92C384 110.36 369.64 96 351.92 96H160c-17.67 0-32 14.33-32 42v86H96.08C96.11 171.07 96 64.06 96 64.06zM352 224H160v-96h191.95l.05.03zm96 160H64.08c-.02-63.44-.08-127.94-.08-127.94l.06-.06h383.88l.06.06z" />',viewBox:"0 0 512 512"},bedSolidIcon:{name:"bed-solid",content:'<path d="M448 224V64c0-17.6-14.4-32-32-32H96c-17.6 0-32 14.4-32 32v160c-17.6 0-32 14.4-32 32v224h32c.07-.12.09-27.83.09-64H448v64h32V256c0-17.6-14.4-32-32-32m-32 0H96.08C96.11 171.07 96 64.06 96 64.06l.06-.06h319.88l.06.06zm-32-95.92V207H128v-79c0-17.67 14.33-32 32-32h191.92c17.72 0 32.08 14.36 32.08 32.08" />',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"},bicycleIcon:{name:"bicycle",content:'<path d="M400 287c27.02 0 49 21.98 49 49s-21.98 49-49 49-49-21.98-49-49c0-15.41 7.04-29.62 19.31-38.98l8.1-6.18 9.85-2.43c3.8-.94 7.75-1.41 11.74-1.41m-288 0c5.77 0 11.41.99 16.76 2.94l9.53 3.47 7.33 6.94c7.41 7.02 12.39 15.94 14.38 25.8l2 9.86-1.99 9.82c-4.6 22.69-24.8 39.16-48.01 39.16-27.02 0-49-21.98-49-49S84.98 287 112 287M384 96h-64v112H200.68l-18.47-32H192v-32h-62.24l-1.76 1.02V176h17.26l29.17 50.53-35.06 34.28A79.8 79.8 0 0 0 112 256c-44.18 0-80 35.82-80 80s35.82 80 80 80c38.7 0 70.98-27.48 78.39-64h37.89c.37.64.77 1.27 1.18 1.89.16.24.33.48.5.71.2.29.42.57.64.86.18.24.36.47.55.7.24.29.48.58.73.87.22.25.45.51.69.76.23.25.47.5.71.74.45.46.92.9 1.4 1.33a30.01 30.01 0 0 0 2.5 2.02c.42.3.84.6 1.27.88.43.29.87.56 1.32.82.54.32 1.1.63 1.66.92l.16.08c.31.15.62.3.94.45a30.967 30.967 0 0 0 4.92 1.81c1.05.29 2.12.53 3.2.71q.495.09.99.15c.28.04.57.08.86.1 1.15.14 2.32.2 3.5.2 17.67 0 32-14.33 32-32 0-.36 0-.71-.02-1.06 0-.23 0-.46-.03-.68-.05-1.06-.16-2.1-.32-3.12-.04-.27-.08-.53-.13-.79-.04-.27-.09-.53-.15-.79-.05-.26-.11-.51-.17-.77-.23-1.03-.52-2.04-.86-3.03-.08-.25-.17-.5-.26-.74-.17-.49-.36-.97-.57-1.45-.09-.22-.18-.44-.28-.66l51.62-71.37 14.68 20.83C332.36 286.98 320 310.05 320 336c0 44.18 35.82 80 80 80s80-35.82 80-80-35.82-80-80-80c-6.6 0-13.02.8-19.15 2.31L352 217v-89h32zM256.06 303.92 219.15 240h86.53zM190.39 320c-3.33-16.45-11.72-31.06-23.46-42.17l23.71-23.22 37.7 65.3-.05.09z" />',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"},borderRadiusUndefinedIcon:{name:"border-radius-undefined",content:'<path d="M224.12 46.05c.97-8.11 8.14-14.05 16.31-14.05h63.58c96.8 0 176 79.2 176 176v63.58c0 8.16-5.94 15.33-14.05 16.31-9.66 1.16-17.95-6.44-17.95-15.88v-64c0-79.53-64.47-144-144-144h-64c-9.44 0-17.04-8.29-15.88-17.95zM176 32h-32c-8.84 0-16 7.16-16 16s7.16 16 16 16h32c8.84 0 16-7.16 16-16s-7.16-16-16-16m-96 0H48c-8.84 0-16 7.16-16 16s7.16 16 16 16h32c8.84 0 16-7.16 16-16s-7.16-16-16-16m384 384c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16s16-7.16 16-16v-32c0-8.84-7.16-16-16-16m0-96c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16s16-7.16 16-16v-32c0-8.84-7.16-16-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"},borderWidthIcon:{name:"border-width",content:'<path d="M480 192H32V96h448zm0 32H32v64h448zm0 96H32v32h448zm0 64H32v16h448z" />',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"},bugOutlineIcon:{name:"bug-outline",content:'<path d="M480 144v-31.79c0-4.11-1.51-7.89-4.03-10.76-2.51-2.88-6.03-4.85-10.04-5.33-4.55-.55-9.11.88-12.54 3.91A16.05 16.05 0 0 0 448 112v32c0 35.29-28.71 64-64 64 0-25.4-14.79-47.33-36.22-57.67a64 64 0 0 0-13.33-4.7c-3.09-15.66-10.66-29.7-21.33-40.74 4.38-7.22 6.88-15.7 6.88-24.76v-32c0-8.84-7.16-16-16-16-1.63 0-3.2.24-4.68.7-2.54.77-4.81 2.15-6.64 3.98-2.89 2.9-4.68 6.9-4.68 11.32v32c0 2.29-.49 4.48-1.36 6.45-9.86-4.23-20.73-6.58-32.14-6.58-10.41 0-20.37 1.95-29.52 5.51-.63-1.72-.98-3.57-.98-5.51V48c0-4.42-1.79-8.42-4.68-11.32-1.83-1.83-4.1-3.21-6.64-3.98-1.48-.46-3.05-.7-4.68-.7-8.84 0-16 7.16-16 16v32c0 8.31 2.11 16.13 5.82 22.94-11.88 11.5-20.27 26.58-23.43 43.51a63.6 63.6 0 0 0-10.18 3.88C142.78 160.67 128 182.61 128 208c-35.29 0-64-28.71-64-64v-32c0-4.56-1.97-8.93-5.39-11.97A16 16 0 0 0 47.98 96c-.63 0-1.27.04-1.91.12C38.05 97.08 32 104 32 112.21V144c0 52.93 43.07 96 96 96v32H48c-4.42 0-8.42 1.79-11.32 4.68-2.89 2.9-4.68 6.9-4.68 11.32 0 8.84 7.16 16 16 16h80v32c-52.93 0-96 43.07-96 96v31.79c0 4.11 1.51 7.89 4.03 10.76 2.51 2.88 6.03 4.85 10.04 5.33.64.08 1.27.12 1.91.12 3.89 0 7.68-1.42 10.63-4.03A16.05 16.05 0 0 0 64 464v-32c0-35.29 28.71-64 64-64h.99c7.88 63.14 61.74 112 127.01 112s119.13-48.86 127.01-112h.99c35.29 0 64 28.71 64 64v32c0 4.56 1.97 8.93 5.39 11.97 2.95 2.61 6.74 4.03 10.63 4.03.64 0 1.27-.04 1.91-.12 8.02-.96 14.07-7.88 14.07-16.09V432c0-52.93-43.07-96-96-96v-32h80c4.42 0 8.42-1.79 11.32-4.68 2.89-2.9 4.68-6.9 4.68-11.32 0-8.84-7.16-16-16-16h-80v-32c52.93 0 96-43.07 96-96m-225.5-32c21.14 0 39.22 13.32 46.31 32h-92.62c7.09-18.68 25.17-32 46.31-32M352 352q0 2.13-.09 4.26c-.03.52-.05 1.03-.09 1.54 0 .14-.01.28-.02.42-.04.61-.08 1.23-.14 1.84-.05.67-.11 1.33-.18 1.99-.04.48-.1.97-.16 1.45l-.06.54c-.03.21-.05.43-.09.64-.13 1.09-.3 2.18-.48 3.26C343.03 413.85 303.01 448 256 448s-87.04-34.16-94.68-80.06q-.165-.96-.3-1.95c-.1-.64-.19-1.28-.27-1.93v-.04c-.09-.66-.16-1.31-.23-1.97a99 99 0 0 1-.32-3.84q-.06-.84-.09-1.68c-.03-.5-.05-1-.06-1.51-.03-1.01-.05-2.02-.05-3.02V208c0-12.4 6.94-23.46 18.14-28.86 4.31-2.08 8.97-3.14 13.86-3.14h128c4.88 0 9.54 1.06 13.87 3.15C345.05 184.55 352 195.6 352 208z" />',viewBox:"0 0 512 512"},bugSolidIcon:{name:"bug-solid",content:'<path d="M351.09 365.17c-.06.43-.11.85-.17 1.28.08-.49.15-.99.21-1.49 0 .07-.03.14-.04.21m.08-.49c.04-.21.06-.43.09-.64l.06-.54zm-.04.28c-.06.5-.13 1-.21 1.49.06-.43.11-.85.17-1.28.01-.07.04-.14.04-.21m.19-1.46-.06.54c-.03.21-.05.43-.09.64zM384 240v32h80c8.84 0 16 7.16 16 16 0 4.42-1.79 8.42-4.68 11.32-2.9 2.89-6.9 4.68-11.32 4.68h-80v32c52.93 0 96 43.07 96 96v31.79c0 8.21-6.05 15.13-14.07 16.09-.64.08-1.27.12-1.91.12-3.89 0-7.68-1.42-10.63-4.03A16.05 16.05 0 0 1 448 464v-32c0-35.29-28.71-64-64-64h-.99c.58-4.7.92-9.49.97-14.34-.07 4.74-.4 9.41-.97 14.01C375.13 430.99 321.27 480 256 480s-119.13-49.01-127.01-112.33c-.57-4.6-.9-9.27-.97-14.01.05 4.85.39 9.64.97 14.34H128c-35.29 0-64 28.71-64 64v32c0 4.56-1.97 8.93-5.39 11.97A16.05 16.05 0 0 1 47.98 480c-.64 0-1.27-.04-1.91-.12-4.01-.48-7.53-2.45-10.04-5.33A16.27 16.27 0 0 1 32 463.79V432c0-52.93 43.07-96 96-96v-32H48c-8.84 0-16-7.16-16-16 0-4.42 1.79-8.42 4.68-11.32 2.9-2.89 6.9-4.68 11.32-4.68h80v-32c-52.93 0-96-43.07-96-96v-31.79c0-8.21 6.05-15.13 14.07-16.09.64-.08 1.28-.12 1.91-.12 3.9 0 7.69 1.42 10.63 4.03A16.05 16.05 0 0 1 64 112v32c0 35.29 28.71 64 64 64v-.81c0-25.47 14.78-47.47 36.21-57.84 3.25-1.58 6.65-2.88 10.18-3.89.39-.11.78-.22 1.18-.32 2.71-16.66 10.48-31.63 21.69-43.27C193.89 95.31 192 87.88 192 80V48c0-8.84 7.16-16 16-16 1.63 0 3.2.24 4.68.7 2.54.77 4.81 2.15 6.64 3.98 2.89 2.9 4.68 6.9 4.68 11.32v32c0 1.11.11 2.19.33 3.23 9.73-4.11 20.43-6.38 31.67-6.38s21.95 2.28 31.69 6.39c.21-1.01.31-2.05.31-3.11v-32c0-4.42 1.79-8.42 4.68-11.32 1.83-1.83 4.1-3.21 6.64-3.98 1.48-.46 3.05-.7 4.68-.7 8.84 0 16 7.16 16 16v32c0 7.84-1.88 15.25-5.21 21.78 11.18 11.64 18.93 26.58 21.64 43.22 3.95 1.05 7.74 2.47 11.35 4.22 21.43 10.37 36.22 32.36 36.22 57.84v.81c35.29 0 64-28.71 64-64v-32c0-4.56 1.97-8.93 5.39-11.97 3.43-3.03 7.99-4.46 12.54-3.91 4.01.48 7.53 2.45 10.04 5.33 2.52 2.87 4.03 6.65 4.03 10.76V144c0 52.93-43.07 96-96 96m-32.87 124.96c0 .07-.03.14-.04.21-.06.43-.11.85-.17 1.28.08-.49.15-.99.21-1.49m0-.34c0 .07-.03.14-.04.21-.06.43-.11.85-.17 1.28.08-.49.15-.99.21-1.49m.19-1.12-.15 1.18c.04-.21.06-.43.09-.64zm0-.35-.15 1.19c.04-.21.06-.43.09-.65z" />',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"},buildingsOutlineIcon:{name:"buildings-outline",content:'<path d="M144 96h-32v32h32zm64 0h-32v32h32zm79.97 128.24v32h32v-32zM288 288v32h32v-32zm63.97-63.76v32h32v-32zM352 288v32h32v-32zM112 160v32h32v-32zm0 64v32h32v-32zm0 64v32h32v-32zm64-128v32h32v-32zm0 64v32h32v-32zm0 64v32h32v-32zm111.97-63.76v32h32v-32zM288 288v32h32v-32zm63.97-63.76v32h32v-32zM352 288v32h32v-32zM112 160v32h32v-32zm0 64v32h32v-32zm0 64v32h32v-32zm64-128v32h32v-32zm0 64v32h32v-32zm0 64v32h32v-32zm111.97-63.76v32h32v-32zM288 288v32h32v-32zm63.97-63.76v32h32v-32zM352 288v32h32v-32zm0 0v32h32v-32zm-.03-63.76v32h32v-32zM288 288v32h32v-32zm-.03-63.76v32h32v-32zM176 288v32h32v-32zm0-64v32h32v-32zm0-64v32h32v-32zm-64 128v32h32v-32zm0-64v32h32v-32zm0-64v32h32v-32zm240 128v32h32v-32zm-.03-63.76v32h32v-32zM288 288v32h32v-32zm-.03-63.76v32h32v-32zM176 288v32h32v-32zm0-64v32h32v-32zm0-64v32h32v-32zm-64 128v32h32v-32zm0-64v32h32v-32zm0-64v32h32v-32zm240 128v32h32v-32zm-.03-63.76v32h32v-32zM288 288v32h32v-32zm-.03-63.76v32h32v-32zM112 288v32h32v-32zm64 0v32h32v-32zm-64-64v32h32v-32zm64 0v32h32v-32zm-64-64v32h32v-32zm64 0v32h32v-32zm112 128v32h32v-32zm64 0v32h32v-32zm-64.03-63.76v32h32v-32zm64 0v32h32v-32zM448 448V160H256V32H64v416H32v32h448v-32zm-224 0h-32v-96h-64v96H96V64h128zm192 0h-32v-96h-96v96h-32V192h160z" />',viewBox:"0 0 512 512"},buildingsSolidIcon:{name:"buildings-solid",content:'<path d="M448 448V160H256V32H64v416H32v32h448v-32zm-64-128h-32v-32h32zm-32.03-63.76v-32h32v32zM288 288h32v32h-32zm-.03-31.76v-32h32v32zM112 96h32v32h-32zm0 64h32v32h-32zm0 64h32v32h-32zm0 64h32v32h-32zm80 160h-64v-96h64zm16-128h-32v-32h32zm0-64h-32v-32h32zm0-64h-32v-32h32zm0-64h-32V96h32zm80 320v-96h96v96z" />',viewBox:"0 0 512 512"},busIcon:{name:"bus",content:'<path d="m479.16 221.81-28.95-57.89a7.99 7.99 0 0 0-7.15-4.42H40c-4.42 0-8 3.58-8 8v144c0 4.42 3.58 8 8 8h58.73c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h132.75c.11.33.22.67.34 1 6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32c.12-.33.23-.67.34-1H472c4.42 0 8-3.58 8-8v-86.11c0-1.24-.29-2.47-.84-3.58M96 223.5H64v-32h32zm48 96c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m16-96h-32v-32h32zm160-31.74h32v64h-32zm-96 31.74h-32v-32h32zm64 0h-32v-32h32zm85.2 96c-1.74.65-3.61 1-5.57 1s-3.83-.35-5.57-1c-6.08-2.27-10.43-8.14-10.43-15 0-8.82 7.18-16 16-16s16 7.18 16 16c0 6.86-4.35 12.73-10.43 15m10.8-96v-32h48l16 32z" />',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"},carIcon:{name:"car",content:'<path d="m475.08 241.41-5.43-9.51c-9.79-13.82-25.62-23.06-43.65-23.84-.83-.04-1.66-.06-2.5-.06h-68.25L272 160H144l-56.51 32H56c-13.25 0-24 10.75-24 24v80c0 13.25 10.75 24 24 24h42.73c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h134.07c6.61 18.62 24.37 31.95 45.25 31.95s38.53-13.25 45.19-31.78c.02-.06.04-.11.06-.17h49.86c9 0 16.3-7.3 16.3-16.3v-39.2c0-8.23-1.76-16.04-4.92-23.09M144 320c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m64-96h-64v-32h64zm96 .15h-64V192h24l55.6 32zm80.52 81.25c-.73 8.15-7.6 14.55-15.93 14.55-8.83 0-16-7.17-16-16s6.52-15.33 14.78-15.95c.4-.03.81-.05 1.22-.05s.83.02 1.23.05c.84.07 1.67.2 2.47.39 7.05 1.67 12.3 8.02 12.3 15.56 0 .49-.02.97-.07 1.45" />',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"},circleShapeIcon:{name:"circle-shape",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-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"},cleanOutlineIcon:{name:"clean-outline",content:'<path d="M224 368H64c0-8.84 3.58-16.84 9.37-22.63S87.16 336 96 336h32V48c0-8.84 7.16-16 16-16 4.42 0 8.42 1.79 11.32 4.68 2.89 2.9 4.68 6.9 4.68 11.32v288h32c17.67 0 32 14.33 32 32m-23.06 48 10.67 32H76.4l10.67-32zM224 384H64l-32 96h224zm244-64h-20c0-44.46-35.54-80.25-80-80.25s-80 35.79-80 80.25h-20c-6.6 0-12 5.4-12 12v8c0 6.6 5.4 12 12 12h20l12.5 99.97c2 16.01 15.61 28.03 31.75 28.03h71.5c16.14 0 29.75-12.02 31.75-28.03L448 352h20c6.6 0 12-5.15 12-11.75v-8c0-6.6-5.4-12.25-12-12.25m-64.25 128h-71.5L320 352h96zM320 320c0-26.74 21.26-48.25 48-48.25s48 21.51 48 48.25z" />',viewBox:"0 0 512 512"},cleanSolidIcon:{name:"clean-solid",content:'<path d="M224 368H64c0-8.84 3.58-16.84 9.37-22.63S87.16 336 96 336h32V48c0-8.84 7.16-16 16-16 4.42 0 8.42 1.79 11.32 4.68 2.89 2.9 4.68 6.9 4.68 11.32v288h32c17.67 0 32 14.33 32 32m0 16H64l-32 96h224zm256-51.6v7.99c0 6.59-5.4 11.99-12 11.99h-20s-6.92 73.17-16 95.65-15.7 31.42-32 31.97h-64c-17.67 0-27-13.99-32-31.72l-16-95.9h-20c-6.6 0-12-5.39-12-11.99v-7.99c0-6.59 5.4-11.99 12-11.99h19.5c0-44.41 36.04-80.42 80.5-80.42s80.5 36 80.5 80.42H468c6.6 0 12 5.39 12 11.99m-63.5-11.99c0-26.71-21.76-48.45-48.5-48.45s-48.5 21.74-48.5 48.45z" />',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"},comboboxIcon:{name:"combobox",content:'<path d="M240 80v96h16V80zm112 32 32 32 32-32zM240 80v96h16V80zM96 144h112v-32H96zm256-32 32 32 32-32zm-112 64h16V80h-16zM96 144h112v-32H96zm0-32v32h112v-32zm256 0 32 32 32-32zm64 0-32 32-32-32zm64-80H32v448h288V224h160zM64 64h224v128H64zm224 384H64V224h224zm160-256H320V64h128zm-192 96H96v-32h160zm0 128H96v-32h160zm0-64H96v-32h160z" />',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"},concreteTruckIcon:{name:"concrete-truck",content:'<path d="m479.16 270.31-28.95-57.89a7.99 7.99 0 0 0-7.15-4.42H360c-4.42 0-8 3.58-8 8v120h-32v-24c0-4.42-3.58-8-8-8H40c-4.42 0-8 3.58-8 8v48c0 4.42 3.58 8 8 8h10.73c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h37.46c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h101.46c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32H472c4.42 0 8-3.58 8-8v-86.11c0-1.24-.29-2.47-.84-3.58M80 352c0-8.82 7.18-16 16-16s16 7.18 16 16-7.18 16-16 16-16-7.18-16-16m144 16c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m192 0c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m-32-96v-32h48l16 32zm-88 16H192l-96-48-64-79.36L56 112h104l96 44 64 83z" />',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"},cubeIcon:{name:"cube",content:'<path d="M256 32 32 128v256l208 89.14 16 6.86 16-6.86L480 384V128zm-16 406L64 362.9V160l176 73zm16-233L96 138l160-71.18L416 138zm192 157.9L272 438V233l176-73z" />',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"},dashboardOutlineIcon:{name:"dashboard-outline",content:'<path d="M448 64v96H304V64zm-240 .06v192H64v-192zM448 256v192H304V256zm-240 96v96H64v-96zM448 32H304c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32V64c0-17.67-14.33-32-32-32m-240 .06H64c-17.67 0-32 14.33-32 32v192c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32v-192c0-17.67-14.33-32-32-32M448 224H304c-17.67 0-32 14.33-32 32v192c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32V256c0-17.67-14.33-32-32-32m-240 96H64c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32" />',viewBox:"0 0 512 512"},dashboardSolidIcon:{name:"dashboard-solid",content:'<path d="M208 288.06H64c-17.67 0-32-14.33-32-32v-192c0-17.67 14.33-32 32-32h144c17.67 0 32 14.33 32 32v192c0 17.67-14.33 32-32 32M480 160V64c0-17.67-14.33-32-32-32H304c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32M240 448v-96c0-17.67-14.33-32-32-32H64c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32m240 0V256c0-17.67-14.33-32-32-32H304c-17.67 0-32 14.33-32 32v192c0 17.67 14.33 32 32 32h144c17.67 0 32-14.33 32-32" />',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"},decisionIcon:{name:"decision",content:'<path d="m480 207.99-112.3-96v64c-31.62 0-60.21 13.67-80.62 35.26v-67.23h64.17L255 32l-96.25 112.02h64.17v65.16c-20.26-20.39-48.01-33.19-78.62-33.19v-64l-112.3 96 112.3 96v-64c27.88 0 54.08 8.01 76.92 21.17-45.51 14.29-78.52 56.72-78.52 106.83C142.7 429.84 192.98 480 255 480s112.3-50.15 112.3-112.01c0-49.64-32.39-91.74-77.23-106.42 23-13.4 49.47-21.58 77.64-21.58v64zM271.04 448h-32.08v-32h32.08zm32.08-112.01c0 22.6-11.73 32.95-20.35 40.5-7.57 6.65-11.73 10.35-11.73 23.5h-32.08c0-27.6 13.59-39.6 22.61-47.5 6.92-6.05 9.47-8.35 9.47-16.5 0-8.8-7.22-16-16.04-16s-16.04 7.2-16.04 16h-32.08c0-26.5 21.56-48 48.13-48s48.11 21.5 48.11 48" />',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"},devicesOutlineIcon:{name:"devices-outline",content:'<path d="M416 96H96c-17.67 0-32 14.33-32 32v224h240v-32H96V128h320v48h32v-48c0-17.67-14.33-32-32-32M306.14 411.49l-.03-.06c-1.4-3.67-2.11-7.52-2.11-11.43v-16h-16v8c0 4.42-3.58 8-8 8h-48c-4.42 0-8-3.58-8-8v-8H32c0 17.67 14.33 32 32 32h244.32c-.84-1.43-1.57-2.94-2.18-4.51M464 192H336c-6.78 0-12.62 4.28-14.94 10.28-.68 1.77-1.06 3.7-1.06 5.72v192c0 2.01.38 3.94 1.06 5.72 2.32 6 8.16 10.28 14.94 10.28h128c8.8 0 16-7.2 16-16V208c0-8.8-7.2-16-16-16m-64 216c-4.42 0-8-3.58-8-8a7.998 7.998 0 0 1 10.02-7.74c3.44.89 5.98 4.02 5.98 7.74 0 4.42-3.58 8-8 8m64-24H336V208h128z" />',viewBox:"0 0 512 512"},devicesSolidIcon:{name:"devices-solid",content:'<path d="M416 96H96c-17.67 0-32 14.33-32 32v224h240V208c0-3.94.72-7.79 2.14-11.49C310.88 184.24 322.88 176 336 176h112v-48c0-17.67-14.33-32-32-32M306.14 411.49l-.03-.06c-1.4-3.67-2.11-7.52-2.11-11.43v-16h-16v8c0 4.42-3.58 8-8 8h-48c-4.42 0-8-3.58-8-8v-8H32c0 17.67 14.33 32 32 32h244.32c-.84-1.43-1.57-2.94-2.18-4.51M464 192H336c-6.78 0-12.62 4.28-14.94 10.28-.68 1.77-1.06 3.7-1.06 5.72v192c0 2.01.38 3.94 1.06 5.72 2.32 6 8.16 10.28 14.94 10.28h128c8.8 0 16-7.2 16-16V208c0-8.8-7.2-16-16-16m-64 216c-2.21 0-4.21-.9-5.66-2.34A8.01 8.01 0 0 1 392 400a7.998 7.998 0 0 1 10.02-7.74c3.44.89 5.98 4.02 5.98 7.74 0 4.42-3.58 8-8 8m64-24H336V208h128z" />',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"},directionsIcon:{name:"directions",content:'<path d="M480 239.97v-176H288V49.19c0-9.5-7.16-17.19-16-17.19h-32c-8.84 0-16 7.69-16 17.19v14.78h-96l-96 88 96 88h96V272H32v176h192v32h64v-32h96l96-88-96-88h-96v-32.03zM297.35 296 320 318.65 280.65 360 322 401.35 297.35 424 256 382.65 214.65 424 192 401.35 233.35 360 192 318.65 214.65 296 256 337.35zm-41.55-87.88-65.01-65.01 22.86-22.86 42.15 42.17 66.54-66.54 22.87 22.85z" />',viewBox:"0 0 512 512"},discountOutlineIcon:{name:"discount-outline",content:'<path d="M200 160c-22.1 0-40 25.05-40 56s17.9 56 40 56 40-25.05 40-56-17.9-56-40-56m104 0h16L208 352h-16zm8 80c-22.1 0-40 25.05-40 56s17.9 56 40 56 40-25.05 40-56-17.9-56-40-56m-24 56c0-23.55 12.65-40 24-40s24 16.45 24 40-12.65 40-24 40-24-16.45-24-40m-112-80c0-23.55 12.65-40 24-40s24 16.45 24 40-12.65 40-24 40-24-16.45-24-40m79.97-147.05 43.41 25.06h50.12l25.07 43.41 43.41 25.06v50.12l25.07 43.4-25.06 43.41v50.11l-43.4 25.07L349.53 418h-50.12L256 443.07l-43.41-25.06h-50.12L137.4 374.6l-43.41-25.06v-50.12l-25.07-43.4 25.06-43.41V162.5l43.4-25.07 25.06-43.41h50.12zm0-36.95L204 62.02h-60.02l-30 51.99-51.97 30.02v60.02l-29.99 51.98L62.04 308v60.02l51.99 30 30.02 51.97h60.02l51.98 29.99 51.97-30.02h60.02l30-51.99 51.97-30.02v-60.02L480 255.95l-30.02-51.97v-60.02l-51.99-30-30.02-51.97h-60.02z" />',viewBox:"0 0 512 512"},discountSolidIcon:{name:"discount-solid",content:'<path d="M200 256c13.26 0 24-17.91 24-40s-10.74-40-24-40-24 17.91-24 40 10.74 40 24 40m280-.04-30.02-51.97v-60.02l-51.99-30-30.02-51.98h-60.02L255.96 32l-51.97 30.02h-60.02l-30 51.99-51.98 30.02v60.02L32 256.04l30.02 51.97v60.02l51.99 30 30.02 51.98h60.02L256.04 480l51.97-30.02h60.02l30-51.99 51.98-30.02v-60.02zM160 216c0-30.95 17.9-56 40-56s40 25.05 40 56-17.9 56-40 56-40-25.05-40-56m48 136h-16l112-192h16zm104 0c-22.1 0-40-25.05-40-56s17.9-56 40-56 40 25.05 40 56-17.9 56-40 56m0-96c-11.35 0-24 16.45-24 40s12.65 40 24 40 24-16.45 24-40-12.65-40-24-40" />',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"},distanceIcon:{name:"distance",content:'<path d="M432 240c4.28 0 8.29 1.66 11.33 4.7 3.01 3.01 4.67 7.02 4.67 11.3s-1.66 8.29-4.7 11.33c-3.01 3.01-7.02 4.67-11.3 4.67-7.83 0-13.22-5.36-15.1-10.67l-1.89-5.33 1.89-5.34c.78-2.21 2.09-4.28 3.8-5.99 3.01-3.01 7.02-4.67 11.3-4.67m-336 0v32H64v-32zm336-32c-13.26 0-25.26 5.37-33.94 14.06A48 48 0 0 0 386.73 240H128v-32H32v96h96v-32h258.73c6.59 18.64 24.37 32 45.27 32 13.26 0 25.26-5.37 33.94-14.06C474.63 281.26 480 269.26 480 256s-5.37-25.26-14.06-33.94C457.26 213.37 445.26 208 432 208" />',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"},doctorOutlineIcon:{name:"doctor-outline",content:'<path d="M255.98 64c35.29 0 64.01 28.71 64.01 64 0 14.13-4.52 27.53-13.06 38.73-8.3 10.88-20.05 18.96-33.11 22.74-5.73 1.67-11.73 2.52-17.83 2.52s-12.1-.85-17.86-2.52c-13.03-3.78-24.78-11.85-33.08-22.73-8.55-11.21-13.06-24.6-13.06-38.73 0-35.29 28.69-64.01 63.99-64.01m.02-32c-52.99 0-96 43-96 96 0 43.7 29.25 80.6 69.22 92.2 8.49 2.47 17.48 3.79 26.78 3.79s18.28-1.32 26.78-3.79C322.76 208.6 352 171.7 352 128c0-53-43-96-96-96m164.72 317.33A192.9 192.9 0 0 0 352 281.71c-3.17-1.85-6.4-3.6-9.68-5.25-2.08-1.05-4.19-2.06-6.32-3.03l-16-6.49c-5.23-1.85-10.57-3.48-16-4.88-15.34-3.96-31.43-6.06-48-6.06-22.44 0-43.98 3.85-64 10.94q-1.65.585-3.3 1.2l-.72.27c-.97.37-1.93.74-2.89 1.12l-.09.04c-1.7.68-3.39 1.38-5.07 2.11-.67.29-1.34.58-2.01.88-3.35 1.48-6.65 3.07-9.89 4.74-.53.27-1.05.54-1.57.82l-1.56.84c-1.65.89-3.28 1.8-4.9 2.75-2.71 1.57-5.38 3.2-8 4.9a193 193 0 0 0-60.72 62.72C73.97 378.17 64 411.92 64 448c0 17.7 14.31 32 32 32h320c17.69 0 32-14.3 32-32 0-36.08-9.96-69.83-27.28-98.67M96 448c0-29.02 7.86-57.44 22.72-82.2 8.86-14.77 20.17-28.11 33.28-39.35l8-5.34v19.17c-9.56 5.53-16 15.88-16 27.72 0 17.67 14.33 32 32 32s32-14.33 32-32c0-11.84-6.44-22.19-16-27.72v-38.95c1.33-.59 2.68-1.16 4.02-1.7 2.21-.9 4.43-1.74 6.6-2.5l.06-.03c17.06-6.04 35-9.1 53.32-9.1 13.58 0 27.04 1.7 40.01 5.05 2.67.69 5.34 1.45 7.99 2.29v27.39a48 48 0 0 0-17.94 11.33C277.37 342.74 272 354.74 272 368v48c0 8.84 7.16 16 16 16 4.42 0 8.42-1.79 11.32-4.68 2.89-2.9 4.68-6.9 4.68-11.32v-48c0-8.84 7.16-16 16-16 4.42 0 8.42 1.79 11.32 4.68 2.89 2.9 4.68 6.9 4.68 11.32v48c0 8.84 7.16 16 16 16 4.42 0 8.42-1.79 11.32-4.68 2.89-2.9 4.68-6.9 4.68-11.32v-48c0-20.9-13.36-38.68-32-45.27v-13.31c23.49 13.59 43.3 33.09 57.29 56.39C408.15 390.55 416 418.97 416 448z" />',viewBox:"0 0 512 512"},doctorSolidIcon:{name:"doctor-solid",content:'<path d="M352 128.01c0 43.7-29.25 80.6-69.23 92.2-8.49 2.47-17.48 3.79-26.78 3.79s-18.28-1.32-26.78-3.79c-39.98-11.6-69.23-48.5-69.23-92.2 0-53 43-96.01 96-96.01S352 75 352 128.01m68.71 221.33a192.9 192.9 0 0 0-68.72-67.62l-16-7.38v48.4c18.64 6.59 32 24.37 32 45.27v48c0 4.42-1.79 8.42-4.68 11.32-2.9 2.89-6.9 4.68-11.32 4.68-8.84 0-16-7.16-16-16v-48c0-4.42-1.79-8.42-4.68-11.32-2.9-2.89-6.9-4.68-11.32-4.68-8.84 0-16 7.16-16 16v48c0 4.42-1.79 8.42-4.68 11.32-2.9 2.89-6.9 4.68-11.32 4.68-8.84 0-16-7.16-16-16v-48c0-13.26 5.37-25.26 14.06-33.94a48 48 0 0 1 17.94-11.33v-60.67c-15.34-3.96-31.43-6.06-48-6.06-22.44 0-43.98 3.85-64 10.94v73.34c9.56 5.53 16 15.88 16 27.72 0 17.67-14.33 32-32 32s-32-14.33-32-32c0-11.84 6.44-22.19 16-27.72v-58.57c-2.37 1.37-4.7 2.79-7 4.26a192.9 192.9 0 0 0-61.72 63.36c-17.31 28.84-27.28 62.59-27.28 98.67 0 17.7 14.31 32 32 32h320c17.69 0 32-14.3 32-32 0-36.08-9.96-69.83-27.28-98.67" />',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"},drawFreeIcon:{name:"draw-free",content:'<path d="M480 384.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-1.67.56-3.33 1.12-5 1.68l42.99-42.99c3.51-.22 7.03-.32 10.55-.32 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.16m-9.3-252.26-45.29 45.3-90.58-90.6 45.29-45.3c12.4-12.4 32.79-12.4 45.29 0l45.29 45.3c12.4 12.4 12.4 32.8 0 45.3m-67.98 67.8L122.48 480H32v-90.5l280.24-280.3zm-67.89-22.6-22.59-22.6-234.95 235 22.59 22.6z" />',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"},dropdownIcon:{name:"dropdown",content:'<path d="M256 288H96v-32h160zm0 96H96v32h160zm0-64H96v32h160zM96 144h224v-32H96zm320-32h-64l32 32zm64-80v192H320v256H32V32zM288 224H64v224h224zM448 64H64v128h384z" />',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"},educationOutlineIcon:{name:"education-outline",content:'<path d="M256 80 32 175.97l32 13.59v118.72c-9.56 5.53-16 15.88-16 27.72 0 12.57 7.25 23.45 17.79 28.68L32 432h96l-33.58-67.42C104.85 359.3 112 348.48 112 336s-6.44-22.19-16-27.72V203.15l32.06 13.61-.06-.24 16 6.94v164.57c0 15.46 50.15 28 112 28s112-12.54 112-28V223.99l112-48.02zm80 294.31c-4.35 1.48-11 3.31-20.75 5.05-17.19 3.06-37.68 4.67-59.25 4.67s-42.06-1.61-59.25-4.67c-9.75-1.74-16.4-3.57-20.75-5.05V237.33L256 272l80-34.3zm-79.93-137.16-141.98-61.54L256 114.81l142.77 61.17z" />',viewBox:"0 0 512 512"},educationSolidIcon:{name:"education-solid",content:'<path d="M368 258v130.03c0 15.46-50.15 28-112 28s-112-12.54-112-28V258l112 50zM128 432l-33.58-67.42C104.85 359.3 112 348.48 112 336s-6.44-22.19-16-27.72V188l-32-14v134.28c-9.56 5.53-16 15.88-16 27.72 0 12.57 7.25 23.45 17.79 28.68L32 432zm0-215.48L256 272l224-96.03L256 80 32 175.97l96.06 40.79z" />',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"},eraserSolidIcon:{name:"eraser-solid",content:'<path d="m209.34 213.19-22.62-22.62 152.9-152.89c3.13-3.12 7.22-4.68 11.32-4.68s8.18 1.56 11.31 4.68l113.06 113.05c6.25 6.25 6.25 16.38 0 22.63L322.4 326.26l-22.61-22.62M231.64 417l68.13-68.13-135.66-135.68h-.02L50.75 326.52c-24.99 24.98-24.99 65.5-.01 90.48zm-32.08 32.07.07-.07H82.76l.07.07H32.01V481h448v-31.93H199.55zm100.22-146.41-90.43-90.44-.02.02 90.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"},foodOutlineIcon:{name:"food-outline",content:'<path d="M256 48c28.09 0 55.33 5.5 80.96 16.34 24.77 10.48 47.01 25.48 66.12 44.58 19.11 19.11 34.11 41.35 44.58 66.12C458.5 200.67 464 227.91 464 256s-5.5 55.33-16.34 80.96c-10.48 24.77-25.48 47.01-44.58 66.12-19.11 19.11-41.35 34.11-66.12 44.58C311.33 458.5 284.09 464 256 464s-55.33-5.5-80.96-16.34c-24.77-10.48-47.01-25.48-66.12-44.58-19.11-19.11-34.11-41.35-44.58-66.12C53.5 311.33 48 284.09 48 256s5.5-55.33 16.34-80.96c10.48-24.77 25.48-47.01 44.58-66.12 19.11-19.11 41.35-34.11 66.12-44.58C200.67 53.5 227.91 48 256 48m0-16C132.29 32 32 132.29 32 256s100.29 224 224 224 224-100.29 224-224S379.71 32 256 32m-31.93 96h.05l-.05-1zm-16.05 0h.05v-1zm16.05 0V72c0-2.21-.9-4.21-2.34-5.66a8.01 8.01 0 0 0-5.66-2.34c-4.42 0-8 3.58-8 8v56h-16V64c-8.84 0-16 7.16-16 16v72.5c0 18.03 12.07 33.23 28.58 37.97L192.07 424c0 13.25 10.75 24 24 24s24-10.75 24-24l-12.58-233.53c16.05-4.6 27.9-19.1 28.55-36.47q.03-.75.03-1.5V80c0-4.42-1.79-8.42-4.68-11.32-2.9-2.89-6.9-4.68-11.32-4.68v64zm31.97 26 .03-1.5q0 .75-.03 1.5m60.58-83.38-60.15 174.81c-1.44 5.4 3.22 10.57 9.53 10.57h30.98l-9.05 168.02c0 13.25 10.75 24 24 24s24-10.75 24-24V72.34c-.19-10.06-16.69-11.52-19.31-1.72M352 127.99v20.68c1.98 1.78 3.92 3.61 5.82 5.51C385.02 181.37 400 217.54 400 256s-14.98 74.63-42.18 101.82c-1.9 1.9-3.84 3.73-5.82 5.51v20.68c38.86-29.19 64-75.66 64-128.01s-25.14-98.82-64-128.01m-195.24 23.68c.1-.1.2-.2.3-.29.64-.61 1.29-1.21 1.94-1.8.3-.29.61-.56.92-.84.03-.02.05-.05.08-.07v-20.68c-.67.5-1.34 1.01-2 1.53-.54.41-1.07.83-1.6 1.26-1.18.94-2.35 1.89-3.5 2.86-.05.04-.1.08-.15.13-.54.45-1.07.91-1.6 1.37q-1.725 1.485-3.39 3.03c-.5.46-.99.91-1.48 1.37-2.38 2.24-4.69 4.56-6.93 6.94-.41.45-.82.89-1.24 1.34-.51.56-1.02 1.12-1.52 1.69a138 138 0 0 0-2.98 3.43c-.49.58-.98 1.17-1.46 1.75-.54.66-1.08 1.33-1.61 2-.41.52-.82 1.04-1.22 1.57q-2.295 2.955-4.44 6.03c-.31.44-.62.89-.93 1.34-.37.54-.74 1.09-1.11 1.64a154 154 0 0 0-7.26 11.98c-.4.72-.8 1.45-1.18 2.19-.33.62-.65 1.25-.97 1.87-1.45 2.82-2.81 5.7-4.09 8.62-.44 1.01-.87 2.02-1.28 3.03-.08.19-.16.38-.23.56-.2.49-.4.97-.59 1.46-.34.84-.66 1.68-.99 2.54-.18.48-.36.97-.54 1.46-.7 1.91-1.36 3.84-1.99 5.79-.24.74-.48 1.48-.7 2.22-.71 2.32-1.38 4.66-1.98 7.03a150 150 0 0 0-1.82 7.87c-.1.51-.2 1.03-.31 1.55-.28 1.48-.55 2.96-.79 4.45a158.915 158.915 0 0 0-.97 6.83c-.09.71-.17 1.42-.24 2.14-.11 1.05-.22 2.11-.31 3.17-.09 1.02-.17 2.04-.23 3.07-.06.88-.12 1.77-.16 2.67-.04.68-.07 1.36-.09 2.05l-.06 1.73c-.02.67-.03 1.33-.04 2-.01.82-.02 1.63-.02 2.45s.01 1.63.02 2.45c.01.67.02 1.33.04 2l.06 1.73c.02.69.05 1.37.09 2.05.04.9.1 1.79.16 2.67.06 1.03.14 2.05.23 3.07.09 1.06.2 2.12.31 3.17.07.72.15 1.43.24 2.14a158.915 158.915 0 0 0 .97 6.83c.24 1.49.51 2.97.79 4.45.11.52.21 1.04.31 1.55a150.225 150.225 0 0 0 1.82 7.87c.6 2.37 1.27 4.71 1.98 7.03.22.74.46 1.48.7 2.22.63 1.95 1.29 3.88 1.99 5.79.18.49.36.98.54 1.46.33.86.65 1.7.99 2.54.19.49.39.97.59 1.46.07.18.15.37.23.56.41 1.02.84 2.03 1.28 3.03 1.28 2.92 2.64 5.8 4.09 8.62.32.62.64 1.25.97 1.87.38.74.78 1.47 1.18 2.19a154.403 154.403 0 0 0 7.26 11.98c.37.55.74 1.1 1.11 1.64.31.45.62.9.93 1.34 2.3 3.29 4.73 6.5 7.27 9.6.48.58.97 1.17 1.46 1.75a138 138 0 0 0 2.98 3.43c.5.57 1.01 1.13 1.52 1.69.42.45.83.89 1.24 1.34 2.24 2.38 4.55 4.7 6.93 6.94.49.46.98.91 1.48 1.37q1.665 1.545 3.39 3.03c.53.46 1.06.92 1.6 1.37.05.05.1.09.15.13 1.15.97 2.32 1.92 3.5 2.86.53.43 1.06.85 1.6 1.26.66.52 1.33 1.03 2 1.53v-20.68s-.05-.05-.08-.07c-.31-.28-.62-.55-.92-.84-.65-.59-1.3-1.19-1.94-1.8-.1-.09-.2-.19-.3-.29-.87-.82-1.73-1.66-2.58-2.51C126.98 330.63 112 294.46 112 256s14.98-74.63 42.18-101.82c.85-.85 1.71-1.69 2.58-2.51M160 363.33s-.05-.05-.08-.07c-.31-.28-.62-.55-.92-.84-.65-.59-1.3-1.19-1.94-1.8-.1-.09-.2-.19-.3-.29-.87-.82-1.73-1.66-2.58-2.51C126.98 330.63 112 294.46 112 256s14.98-74.63 42.18-101.82c.85-.85 1.71-1.69 2.58-2.51.1-.1.2-.2.3-.29.64-.61 1.29-1.21 1.94-1.8.3-.29.61-.56.92-.84.03-.02.05-.05.08-.07v-20.68c-.67.5-1.34 1.01-2 1.53-.54.41-1.07.83-1.6 1.26-1.18.94-2.35 1.89-3.5 2.86-.05.04-.1.08-.15.13-.54.45-1.07.91-1.6 1.37q-1.725 1.485-3.39 3.03c-.5.46-.99.91-1.48 1.37-2.38 2.24-4.69 4.56-6.93 6.94-.41.45-.82.89-1.24 1.34-.51.56-1.02 1.12-1.52 1.69a138 138 0 0 0-2.98 3.43c-.49.58-.98 1.17-1.46 1.75-.54.66-1.08 1.33-1.61 2-.41.52-.82 1.04-1.22 1.57q-2.295 2.955-4.44 6.03c-.31.44-.62.89-.93 1.34-.37.54-.74 1.09-1.11 1.64a154 154 0 0 0-7.26 11.98c-.4.72-.8 1.45-1.18 2.19-.33.62-.65 1.25-.97 1.87-1.45 2.82-2.81 5.7-4.09 8.62-.44 1.01-.87 2.02-1.28 3.03-.08.19-.16.38-.23.56-.2.49-.4.97-.59 1.46-.34.84-.66 1.68-.99 2.54-.18.48-.36.97-.54 1.46-.7 1.91-1.36 3.84-1.99 5.79-.24.74-.48 1.48-.7 2.22-.71 2.32-1.38 4.66-1.98 7.03a150 150 0 0 0-1.82 7.87c-.1.51-.2 1.03-.31 1.55-.28 1.48-.55 2.96-.79 4.45a158.915 158.915 0 0 0-.97 6.83c-.09.71-.17 1.42-.24 2.14-.11 1.05-.22 2.11-.31 3.17-.09 1.02-.17 2.04-.23 3.07-.06.88-.12 1.77-.16 2.67-.04.68-.07 1.36-.09 2.05l-.06 1.73c-.02.67-.03 1.33-.04 2-.01.82-.02 1.63-.02 2.45s.01 1.63.02 2.45c.01.67.02 1.33.04 2l.06 1.73c.02.69.05 1.37.09 2.05.04.9.1 1.79.16 2.67.06 1.03.14 2.05.23 3.07.09 1.06.2 2.12.31 3.17.07.72.15 1.43.24 2.14a158.915 158.915 0 0 0 .97 6.83c.24 1.49.51 2.97.79 4.45.11.52.21 1.04.31 1.55a150.225 150.225 0 0 0 1.82 7.87c.6 2.37 1.27 4.71 1.98 7.03.22.74.46 1.48.7 2.22.63 1.95 1.29 3.88 1.99 5.79.18.49.36.98.54 1.46.33.86.65 1.7.99 2.54.19.49.39.97.59 1.46.07.18.15.37.23.56.41 1.02.84 2.03 1.28 3.03 1.28 2.92 2.64 5.8 4.09 8.62.32.62.64 1.25.97 1.87.38.74.78 1.47 1.18 2.19a154.403 154.403 0 0 0 7.26 11.98c.37.55.74 1.1 1.11 1.64.31.45.62.9.93 1.34 2.3 3.29 4.73 6.5 7.27 9.6.48.58.97 1.17 1.46 1.75a138 138 0 0 0 2.98 3.43c.5.57 1.01 1.13 1.52 1.69.42.45.83.89 1.24 1.34 2.24 2.38 4.55 4.7 6.93 6.94.49.46.98.91 1.48 1.37q1.665 1.545 3.39 3.03c.53.46 1.06.92 1.6 1.37.05.05.1.09.15.13 1.15.97 2.32 1.92 3.5 2.86.53.43 1.06.85 1.6 1.26.66.52 1.33 1.03 2 1.53 5.1 3.84 10.45 7.37 16 10.58v-18.82c-5.58-3.73-10.93-7.89-16-12.44" />',viewBox:"0 0 512 512"},foodSolidIcon:{name:"food-solid",content:'<path d="M256 32C132.29 32 32 132.29 32 256s100.29 224 224 224 224-100.29 224-224S379.71 32 256 32m-80 362.59c-5.55-3.21-10.9-6.74-16-10.58-.67-.5-1.34-1.01-2-1.53-.54-.41-1.07-.83-1.6-1.26-1.18-.94-2.35-1.89-3.5-2.86-.05-.04-.1-.08-.15-.13-.54-.45-1.07-.91-1.6-1.37q-1.725-1.485-3.39-3.03c-.5-.46-.99-.91-1.48-1.37-2.38-2.24-4.69-4.56-6.93-6.94-.41-.45-.82-.89-1.24-1.34-.51-.56-1.02-1.12-1.52-1.69a138 138 0 0 1-2.98-3.43c-.49-.58-.98-1.17-1.46-1.75-2.54-3.1-4.97-6.31-7.27-9.6-.31-.44-.62-.89-.93-1.34-.37-.54-.74-1.09-1.11-1.64a154 154 0 0 1-7.26-11.98c-.4-.72-.8-1.45-1.18-2.19-.33-.62-.65-1.25-.97-1.87-1.45-2.82-2.81-5.7-4.09-8.62-.44-1-.87-2.01-1.28-3.03-.08-.19-.16-.38-.23-.56-.2-.49-.4-.97-.59-1.46-.34-.84-.66-1.68-.99-2.54-.18-.48-.36-.97-.54-1.46-.7-1.91-1.36-3.84-1.99-5.79-.24-.74-.48-1.48-.7-2.22-.71-2.32-1.38-4.66-1.98-7.03a150 150 0 0 1-1.82-7.87c-.1-.51-.2-1.03-.31-1.55-.28-1.48-.55-2.96-.79-4.45a158.915 158.915 0 0 1-.97-6.83c-.09-.71-.17-1.42-.24-2.14-.11-1.05-.22-2.11-.31-3.17-.09-1.02-.17-2.04-.23-3.07-.06-.88-.12-1.77-.16-2.67-.04-.68-.07-1.36-.09-2.05l-.06-1.73c-.02-.67-.03-1.33-.04-2-.01-.82-.02-1.63-.02-2.45s0-1.63.02-2.45c.01-.67.02-1.33.04-2l.06-1.73c.02-.69.05-1.37.09-2.05.04-.9.1-1.79.16-2.67.06-1.03.14-2.05.23-3.07.09-1.06.2-2.12.31-3.17.07-.72.15-1.43.24-2.14a158.915 158.915 0 0 1 .97-6.83c.24-1.49.51-2.97.79-4.45.11-.52.21-1.04.31-1.55a150.225 150.225 0 0 1 1.82-7.87c.6-2.37 1.27-4.71 1.98-7.03.22-.74.46-1.48.7-2.22.63-1.95 1.29-3.88 1.99-5.79.18-.49.36-.98.54-1.46.33-.86.65-1.7.99-2.54.19-.49.39-.97.59-1.46.07-.18.15-.37.23-.56.41-1.01.84-2.02 1.28-3.03 1.28-2.92 2.64-5.8 4.09-8.62.32-.62.64-1.25.97-1.87.38-.74.78-1.47 1.18-2.19a154.403 154.403 0 0 1 7.26-11.98c.37-.55.74-1.1 1.11-1.64.31-.45.62-.9.93-1.34q2.145-3.075 4.44-6.03c.4-.53.81-1.05 1.22-1.57.53-.67 1.07-1.34 1.61-2 .48-.58.97-1.17 1.46-1.75a138 138 0 0 1 2.98-3.43c.5-.57 1.01-1.13 1.52-1.69.42-.45.83-.89 1.24-1.34 2.24-2.38 4.55-4.7 6.93-6.94.49-.46.98-.91 1.48-1.37q1.665-1.545 3.39-3.03c.53-.46 1.06-.92 1.6-1.37.05-.05.1-.09.15-.13 1.15-.97 2.32-1.92 3.5-2.86.53-.43 1.06-.85 1.6-1.26.66-.52 1.33-1.03 2-1.53v20.68l-.08.07c-.31.28-.62.55-.92.84-.65.59-1.3 1.19-1.94 1.8-.1.09-.2.19-.3.29-.87.82-1.73 1.66-2.58 2.51C126.98 181.37 112 217.54 112 256s14.98 74.63 42.18 101.82c.85.85 1.71 1.69 2.58 2.51.1.1.2.2.3.29.64.61 1.29 1.21 1.94 1.8.3.29.61.56.92.84l.08.07c5.07 4.55 10.42 8.71 16 12.44zm80.07-242.09c0 .5 0 1-.03 1.5-.65 17.37-12.5 31.87-28.55 36.47L240.07 424c0 13.25-10.75 24-24 24s-24-10.75-24-24l12.58-233.53c-16.51-4.74-28.58-19.94-28.58-37.97V80c0-8.84 7.16-16 16-16v64h16V72c0-4.42 3.58-8 8-8 2.21 0 4.21.9 5.66 2.34a8.01 8.01 0 0 1 2.34 5.66v56h16V64c4.42 0 8.42 1.79 11.32 4.68 2.89 2.9 4.68 6.9 4.68 11.32zm79.86 271.52c0 13.25-10.74 24-24 24s-24-10.75-24-24L296.98 256H266c-6.31 0-10.97-5.17-9.53-10.57l60.15-174.81c2.62-9.8 19.12-8.34 19.31 1.72zM352 384.01v-20.68c1.98-1.78 3.92-3.61 5.82-5.51C385.02 330.63 400 294.46 400 256s-14.98-74.63-42.18-101.82c-1.9-1.9-3.84-3.73-5.82-5.51v-20.68c38.86 29.19 64 75.66 64 128.01s-25.14 98.82-64 128.01" />',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="M448 32H64c-17.66 0-32 14.34-32 32v384c0 17.66 14.34 32 32 32h384c17.66 0 32-14.34 32-32V64c0-17.66-14.34-32-32-32m-34.68 253.29C399.56 359.66 334.36 416 256 416c-47.09 0-89.43-20.34-118.71-52.72a157 157 0 0 1-7.33-8.72 41 41 0 0 1-1.01-1.3c-.39-.5-.78-1.02-1.16-1.53-.39-.52-.77-1.03-1.15-1.54-.38-.53-.75-1.05-1.12-1.57-.42-.58-.83-1.18-1.24-1.77-.32-.46-.64-.93-.95-1.39-.36-.52-.71-1.05-1.06-1.58-.36-.54-.71-1.09-1.06-1.64-.35-.54-.7-1.08-1.03-1.63-1.46-2.32-2.85-4.69-4.18-7.09-.54-.98-1.08-1.96-1.6-2.96-.23-.42-.45-.85-.67-1.28-.27-.51-.52-1.02-.78-1.53-.71-1.41-1.4-2.84-2.07-4.28-.25-.54-.5-1.08-.74-1.62-.24-.51-.47-1.02-.69-1.54-2.93-6.66-5.42-13.57-7.43-20.67-.16-.58-.32-1.15-.47-1.73-.35-1.27-.68-2.55-.99-3.85-.16-.64-.32-1.28-.46-1.92-.15-.63-.29-1.27-.43-1.9-.29-1.35-.57-2.7-.83-4.05-.2-1.1-.4-2.2-.59-3.31-.23-1.36-.44-2.72-.64-4.08-.07-.49-.14-.99-.2-1.49-.05-.4-.11-.79-.15-1.18-.07-.52-.13-1.04-.2-1.56-.08-.78-.17-1.57-.25-2.36-.06-.62-.12-1.25-.17-1.87l-.15-1.65-.09-1.26c-.04-.61-.08-1.22-.11-1.82l-.09-1.52-.06-1.37c-.09-2.23-.14-4.47-.14-6.72 0-88.36 71.64-160 160-160 2.25 0 4.49.05 6.72.14l1.37.06 1.52.09c.6.03 1.21.07 1.82.11l1.26.09 1.65.15c.62.05 1.25.11 1.87.17.79.08 1.58.17 2.36.25.52.07 1.04.13 1.56.2.39.04.78.1 1.18.15.5.06 1 .13 1.49.2 1.36.2 2.72.41 4.08.64 1.11.19 2.21.39 3.31.59 1.35.26 2.7.54 4.05.83.63.14 1.27.28 1.9.43.64.14 1.28.3 1.92.46 1.3.31 2.58.64 3.85.99.58.15 1.15.31 1.73.47 7.1 2.01 14.01 4.5 20.67 7.43.52.22 1.03.45 1.54.69a153.549 153.549 0 0 1 5.9 2.81c.51.26 1.02.51 1.53.78.43.22.86.44 1.28.67 1 .52 1.98 1.06 2.96 1.6 2.4 1.33 4.77 2.72 7.09 4.18.55.33 1.09.68 1.63 1.03.55.35 1.1.7 1.64 1.06.53.35 1.06.7 1.58 1.06.46.31.93.63 1.39.95.59.41 1.19.82 1.77 1.24.52.37 1.04.74 1.57 1.12.51.38 1.02.76 1.54 1.15.51.38 1.03.77 1.53 1.16.44.33.87.66 1.3 1.01 3 2.34 5.9 4.78 8.72 7.33l-44.54 44.55c-.41-.35-.83-.7-1.25-1.04a92 92 0 0 0-9.05-6.61q-.825-.54-1.68-1.05c-.07-.05-.14-.09-.21-.13-.57-.35-1.14-.7-1.71-1.02l-.05-.03c-.6-.36-1.21-.71-1.83-1.04-.61-.35-1.23-.68-1.86-1.01-.62-.33-1.25-.65-1.88-.96a79 79 0 0 0-3.83-1.81c-.64-.28-1.29-.55-1.94-.83-.65-.27-1.3-.54-1.96-.8-.53-.2-1.05-.4-1.59-.6-.16-.06-.31-.12-.46-.17-.53-.2-1.07-.39-1.6-.57-.23-.08-.45-.16-.68-.23q-.825-.285-1.65-.54l-.08-.03c-.59-.18-1.17-.36-1.76-.53-.17-.05-.33-.1-.51-.15-.55-.16-1.1-.32-1.66-.47l-.13-.03c-.54-.15-1.08-.29-1.63-.43-.12-.02-.23-.05-.35-.08-.65-.17-1.31-.32-1.97-.47l-.11-.02c-.68-.15-1.38-.3-2.07-.44l-.14-.03c-.65-.13-1.31-.25-1.96-.36-.62-.12-1.25-.22-1.87-.31-.69-.11-1.38-.21-2.08-.31l-1.13-.15-1.55-.18c-.62-.06-1.24-.12-1.86-.17-.69-.07-1.38-.12-2.07-.16-.58-.04-1.16-.08-1.74-.1-.28-.02-.56-.03-.84-.04-.52-.03-1.04-.04-1.57-.05-.19-.01-.39-.01-.59-.01-.61-.02-1.23-.02-1.84-.02-25.95 0-50.34 10.1-68.69 28.45s-28.45 42.74-28.45 68.69c0 .61 0 1.23.02 1.84 0 .2 0 .4.01.59.01.53.02 1.05.05 1.57.01.28.02.56.04.84.02.58.06 1.16.1 1.74.04.69.09 1.38.16 2.07.05.62.11 1.24.17 1.86l.18 1.55.15 1.13c.1.7.2 1.39.31 2.08.09.62.19 1.25.31 1.87.11.65.23 1.31.36 1.96l.03.14c.14.69.29 1.39.44 2.07l.02.11c.15.66.3 1.32.47 1.97.03.12.06.23.08.35.14.55.28 1.09.43 1.63l.03.13c.15.56.31 1.11.47 1.66.05.18.1.34.15.51.17.59.35 1.17.53 1.76l.03.08q.255.825.54 1.65c.07.23.15.45.23.68.18.53.37 1.07.57 1.6.05.15.11.3.17.46.2.54.4 1.06.6 1.59.26.66.53 1.31.8 1.96.28.65.55 1.3.83 1.94.57 1.29 1.18 2.57 1.81 3.83.31.63.63 1.26.96 1.88.33.63.66 1.25 1.01 1.86.33.62.68 1.23 1.04 1.83l.03.05c.32.57.67 1.14 1.02 1.71.04.07.08.14.13.21q.51.855 1.05 1.68a92.38 92.38 0 0 0 6.61 9.05c.34.42.69.84 1.04 1.25 1.72 2.05 3.55 4.03 5.47 5.95 18.35 18.35 42.74 28.45 68.69 28.45s50.34-10.1 68.69-28.45c11.22-11.22 19.35-24.69 23.98-39.4h-86.24V226h150.76c1.85 9.72 2.81 19.75 2.81 30s-.91 19.79-2.68 29.29" />',viewBox:"0 0 512 512"},googleIcon:{name:"google",content:'<path d="M480 256c0 14-1.28 27.71-3.75 41C456.99 401.13 365.71 480 256 480c-65.92 0-125.2-28.48-166.19-73.81-3.57-3.94-6.99-8.01-10.27-12.2-.48-.61-.95-1.21-1.41-1.82-.55-.71-1.09-1.43-1.63-2.15s-1.07-1.44-1.6-2.16c-.53-.73-1.05-1.46-1.57-2.19-.59-.82-1.17-1.65-1.74-2.48-.45-.65-.89-1.3-1.33-1.95-.5-.73-.99-1.47-1.48-2.21-.5-.76-1-1.53-1.49-2.29s-.97-1.52-1.44-2.29a210 210 0 0 1-5.85-9.92c-.76-1.37-1.51-2.75-2.24-4.14-.32-.6-.63-1.2-.94-1.8a220.11 220.11 0 0 1-3.99-8.13c-.35-.76-.7-1.51-1.04-2.27-.33-.72-.65-1.43-.96-2.15-4.1-9.33-7.59-19-10.4-28.95-.23-.8-.45-1.61-.66-2.41-.49-1.79-.95-3.58-1.39-5.39-.22-.9-.44-1.8-.64-2.7-.21-.88-.41-1.77-.6-2.66a211 211 0 0 1-1.99-10.3c-.32-1.9-.62-3.8-.89-5.71-.1-.69-.2-1.39-.29-2.08-.07-.56-.15-1.11-.21-1.66-.1-.72-.18-1.45-.27-2.18-.12-1.1-.24-2.2-.35-3.3-.09-.87-.17-1.75-.25-2.63-.07-.77-.14-1.54-.2-2.31-.04-.58-.09-1.17-.13-1.76-.06-.85-.11-1.7-.16-2.55l-.12-2.12-.09-1.92c-.12-3.12-.19-6.26-.19-9.41C32 132.29 132.29 32 256 32c3.15 0 6.29.07 9.41.19l1.92.09 2.12.12c.85.05 1.7.1 2.55.16.59.04 1.18.09 1.76.13.77.06 1.54.13 2.31.2.88.08 1.76.16 2.63.25 1.1.11 2.2.23 3.3.35.73.09 1.46.17 2.18.27.55.06 1.1.14 1.66.21.69.09 1.39.19 2.08.29 1.91.27 3.81.57 5.71.89a210.69 210.69 0 0 1 10.3 1.99c.89.19 1.78.39 2.66.6.9.2 1.8.42 2.7.64 1.81.44 3.6.9 5.39 1.39.8.21 1.61.43 2.41.66 9.95 2.81 19.62 6.3 28.95 10.4.72.31 1.43.63 2.15.96.76.34 1.51.69 2.27 1.04a220 220 0 0 1 8.13 3.99c.6.31 1.2.62 1.8.94 1.39.73 2.77 1.48 4.14 2.24 3.36 1.86 6.67 3.81 9.92 5.85.77.47 1.53.95 2.29 1.44s1.53.99 2.29 1.49c.74.49 1.48.98 2.21 1.48.65.44 1.3.88 1.95 1.33.83.57 1.66 1.15 2.48 1.74.73.52 1.46 1.04 2.19 1.57.72.53 1.44 1.06 2.16 1.6s1.44 1.08 2.15 1.63c.61.46 1.21.93 1.82 1.41 4.19 3.28 8.26 6.7 12.2 10.27l-62.36 62.36c-.57-.49-1.15-.97-1.74-1.45a130 130 0 0 0-12.68-9.25q-1.155-.765-2.34-1.47c-.1-.07-.2-.13-.3-.19-.8-.49-1.6-.97-2.4-1.43l-.06-.04c-.85-.5-1.7-.99-2.56-1.45q-1.29-.735-2.61-1.41c-.87-.47-1.75-.92-2.63-1.35-1.77-.89-3.56-1.73-5.36-2.53-.9-.39-1.81-.78-2.72-1.17a131 131 0 0 0-4.97-1.96c-.22-.08-.43-.16-.65-.24-.74-.27-1.49-.54-2.24-.79-.32-.11-.63-.22-.95-.32-.77-.27-1.54-.52-2.31-.76l-.11-.04q-1.23-.39-2.46-.75l-.71-.21c-.78-.22-1.55-.44-2.33-.65l-.18-.05c-.76-.2-1.52-.4-2.29-.59-.16-.04-.32-.08-.49-.12-.91-.23-1.83-.44-2.75-.65l-.15-.03c-.96-.22-1.94-.42-2.91-.62l-.19-.04c-.91-.18-1.83-.35-2.74-.51-.87-.16-1.75-.3-2.62-.43-.97-.16-1.94-.3-2.92-.44-.52-.07-1.05-.13-1.58-.2-.72-.09-1.44-.17-2.17-.25-.87-.09-1.73-.18-2.6-.25-.97-.09-1.93-.16-2.9-.22-.81-.06-1.62-.11-2.43-.14l-1.18-.06c-.73-.03-1.46-.05-2.2-.07-.27-.01-.55-.01-.83-.01-.85-.02-1.71-.03-2.57-.03-36.33 0-70.48 14.15-96.17 39.83C134.15 185.52 120 219.67 120 256c0 .86.01 1.72.03 2.57 0 .28 0 .56.01.83.02.74.04 1.47.07 2.2l.06 1.18c.03.81.08 1.62.14 2.43.06.97.13 1.93.22 2.9.07.87.16 1.73.25 2.6.08.73.16 1.45.25 2.17.07.53.13 1.06.2 1.58.14.98.28 1.95.44 2.92.13.87.27 1.75.43 2.62.16.91.33 1.83.51 2.74l.04.19c.2.97.4 1.95.62 2.91l.03.15c.21.92.42 1.84.65 2.75.04.17.08.33.12.49.19.77.39 1.53.59 2.29l.05.18c.21.78.43 1.55.65 2.33l.21.71q.36 1.23.75 2.46l.04.11c.24.77.49 1.54.76 2.31.1.32.21.63.32.95.25.75.52 1.5.79 2.24.08.22.16.43.24.65a130.693 130.693 0 0 0 1.96 4.97c.39.91.78 1.82 1.17 2.72.8 1.8 1.65 3.59 2.53 5.36.43.88.88 1.76 1.35 2.63q.675 1.32 1.41 2.61c.46.86.95 1.71 1.45 2.56l.04.06c.46.8.94 1.6 1.43 2.4.06.1.12.2.19.3q.705 1.185 1.47 2.34c.4.63.81 1.25 1.22 1.87 2.47 3.72 5.15 7.32 8.03 10.81.48.59.96 1.17 1.45 1.74 2.41 2.87 4.97 5.65 7.66 8.34C185.52 377.85 219.67 392 256 392s70.48-14.15 96.17-39.83c15.7-15.71 27.09-34.57 33.57-55.17H265v-83h211.07c2.58 13.61 3.93 27.65 3.93 42" />',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"},handleDragDotsIcon:{name:"handle-drag-dots",content:'<path d="M384 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-48M128 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"},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"},headsetIcon:{name:"headset",content:'<path d="M480 247.65v16.7c0 30.73-24.88 55.65-55.57 55.65h-9.17v.07c-4.44 45.85-28.3 86.02-63.25 112.19-.14 26.39-21.58 47.74-48 47.74-14.41 0-27.33-6.35-36.13-16.4a47.78 47.78 0 0 1-11.87-31.6c0-26.51 21.49-48 48-48 14.5 0 27.5 6.43 36.3 16.6 2.18-1.89 4.3-3.88 6.36-5.94 20.37-20.38 33-46.43 36.4-74.59V320h-15.08c-8.83 0-15.99-7.17-15.99-16.01v-95.98c0-8.84 7.16-16.01 15.99-16.01H384v-.5c0-34.06-13.26-66.07-37.34-90.16C322.57 77.26 290.56 64 256.5 64h-1c-34.06 0-66.07 13.26-90.16 37.34-24.08 24.09-37.34 56.1-37.34 90.16v.5h15.99c8.84 0 16.01 7.17 16.01 16.01v95.98c0 8.84-7.17 16.01-16.01 16.01H87.65C56.92 320 32 295.08 32 264.35v-16.7C32 216.92 56.92 192 87.65 192H96v-.5C96 103.41 167.41 32 255.5 32h1C344.59 32 416 103.41 416 191.5v.5h8.43c30.69 0 55.57 24.92 55.57 55.65M208 240c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 0c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 0c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16" />',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"},hexagonShapeIcon:{name:"hexagon-shape",content:'<path d="m349.62 96 93.33 160-93.33 160H162.38L69.05 256l93.33-160zM368 64H144L32 256l112 192h224l112-192z" />',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"},industrialVehicleIcon:{name:"industrial-vehicle",content:'<path d="M175.87 354.09c-.91 7.12-6.66 12.87-13.78 13.78-10.45 1.33-19.29-7.51-17.96-17.96.91-7.12 6.66-12.87 13.78-13.78 10.45-1.33 19.29 7.51 17.96 17.96m256 0c-.91 7.12-6.66 12.87-13.78 13.78-10.45 1.33-19.29-7.51-17.96-17.96.91-7.12 6.66-12.87 13.78-13.78 10.45-1.33 19.29 7.51 17.96 17.96M384 208v-32h48l16 32zm95.16-1.69-28.95-57.89a7.99 7.99 0 0 0-7.15-4.42H352c0 38-1 155.58-1 160h-31V112H40c-4.42 0-8 3.58-8 8v152l96 32H40c-4.42 0-8 3.58-8 8v48c0 4.42 3.58 8 8 8h74.73c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h165.46c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32H472c4.42 0 8-3.58 8-8V209.89c0-1.24-.29-2.47-.84-3.58" />',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"},inputboxIcon:{name:"inputbox",content:'<path d="M32 160v192c13-.07 448 0 448 0V160zm416 160H64V192h384zM96 240h272v32H96zm320-32v96h-16v-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"},insertFreeTextIcon:{name:"insert-free-text",content:'<path d="M230.4 384V179.2h-76.16l-.64-51.2h204.8v51.2h-76.8V384zm105.64 64H125.27c-6.59 18.64-24.37 32-45.27 32-26.51 0-48-21.49-48-48 0-20.9 13.36-38.68 32-45.27V128H32V32h96v32h258.73c6.59-18.64 24.37-32 45.27-32 26.51 0 48 21.49 48 48 0 20.9-13.36 38.68-32 45.27v130.44h-32V125.27c-13.64-4.82-24.45-15.63-29.27-29.27H128v32H96v258.73c13.64 4.82 24.45 15.63 29.27 29.27h210.77zM416 80c0 8.82 7.18 16 16 16s16-7.18 16-16-7.18-16-16-16-16 7.18-16 16M64 96h32V64H64zm32 336c0-8.82-7.18-16-16-16s-16 7.18-16 16 7.18 16 16 16 16-7.18 16-16m288-176v224l96-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"},instagramBoxIcon:{name:"instagram-box",content:'<path d="M256 192c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m0 0c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m158.86-14.86c-.87-19.03-4.05-29.37-6.72-36.24-3.54-9.11-7.77-15.61-14.6-22.44s-13.33-11.06-22.44-14.6c-6.87-2.68-17.21-5.85-36.24-6.72C314.28 96.2 308.11 96 256 96s-58.28.2-78.86 1.14c-19.03.87-29.37 4.04-36.24 6.72-9.11 3.54-15.61 7.77-22.44 14.6s-11.06 13.33-14.6 22.44c-2.67 6.87-5.85 17.21-6.72 36.24C96.2 197.72 96 203.89 96 256s.2 58.28 1.14 78.86c.87 19.03 4.05 29.36 6.72 36.24 3.54 9.11 7.77 15.61 14.6 22.44s13.33 11.06 22.44 14.6c6.87 2.67 17.21 5.85 36.24 6.72 20.57.94 26.75 1.14 78.86 1.14s58.29-.2 78.86-1.14c19.03-.87 29.37-4.05 36.24-6.72 9.11-3.54 15.61-7.77 22.44-14.6s11.06-13.33 14.6-22.44c2.67-6.88 5.85-17.21 6.72-36.24.94-20.58 1.14-26.75 1.14-78.86s-.2-58.28-1.14-78.86M256 352c-53.02 0-96-42.98-96-96s42.98-96 96-96 96 42.98 96 96-42.98 96-96 96m104-176c-13.25 0-24-10.75-24-24s10.75-24 24-24 24 10.74 24 24-10.75 24-24 24m-104 16c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m158.86-14.86c-.87-19.03-4.05-29.37-6.72-36.24-3.54-9.11-7.77-15.61-14.6-22.44s-13.33-11.06-22.44-14.6c-6.87-2.68-17.21-5.85-36.24-6.72C314.28 96.2 308.11 96 256 96s-58.28.2-78.86 1.14c-19.03.87-29.37 4.04-36.24 6.72-9.11 3.54-15.61 7.77-22.44 14.6s-11.06 13.33-14.6 22.44c-2.67 6.87-5.85 17.21-6.72 36.24C96.2 197.72 96 203.89 96 256s.2 58.28 1.14 78.86c.87 19.03 4.05 29.36 6.72 36.24 3.54 9.11 7.77 15.61 14.6 22.44s13.33 11.06 22.44 14.6c6.87 2.67 17.21 5.85 36.24 6.72 20.57.94 26.75 1.14 78.86 1.14s58.29-.2 78.86-1.14c19.03-.87 29.37-4.05 36.24-6.72 9.11-3.54 15.61-7.77 22.44-14.6s11.06-13.33 14.6-22.44c2.67-6.88 5.85-17.21 6.72-36.24.94-20.58 1.14-26.75 1.14-78.86s-.2-58.28-1.14-78.86M256 352c-53.02 0-96-42.98-96-96s42.98-96 96-96 96 42.98 96 96-42.98 96-96 96m104-176c-13.25 0-24-10.75-24-24s10.75-24 24-24 24 10.74 24 24-10.75 24-24 24m-104 16c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64M448 32H64c-17.66 0-32 14.34-32 32v384c0 17.66 14.34 32 32 32h384c17.66 0 32-14.34 32-32V64c0-17.66-14.34-32-32-32m-1.16 303.16c-.93 20.44-4.17 34.39-8.92 46.61-4.91 12.62-11.47 23.33-22.14 34-10.68 10.68-21.39 17.24-34.01 22.15-12.22 4.75-26.17 7.99-46.61 8.93-20.48.93-27.02 1.15-79.16 1.15s-58.68-.22-79.16-1.15c-20.44-.94-34.39-4.18-46.61-8.93-12.62-4.91-23.33-11.47-34-22.15-10.68-10.67-17.24-21.38-22.15-34-4.75-12.22-7.99-26.17-8.93-46.61C64.22 314.68 64 308.14 64 256s.22-58.68 1.15-79.16c.94-20.44 4.18-34.39 8.93-46.61 4.91-12.62 11.47-23.33 22.15-34 10.67-10.68 21.38-17.24 34-22.15 12.22-4.75 26.17-7.99 46.61-8.92C197.32 64.22 203.86 64 256 64s58.68.22 79.16 1.16c20.44.93 34.39 4.17 46.61 8.92 12.62 4.91 23.33 11.47 34.01 22.15 10.67 10.67 17.23 21.38 22.14 34 4.75 12.22 7.99 26.17 8.92 46.61.94 20.48 1.16 27.02 1.16 79.16s-.22 58.68-1.16 79.16m-38.7-194.26c-3.54-9.11-7.77-15.61-14.6-22.44s-13.33-11.06-22.44-14.6c-6.87-2.68-17.21-5.85-36.24-6.72C314.28 96.2 308.11 96 256 96s-58.28.2-78.86 1.14c-19.03.87-29.37 4.04-36.24 6.72-9.11 3.54-15.61 7.77-22.44 14.6s-11.06 13.33-14.6 22.44c-2.67 6.87-5.85 17.21-6.72 36.24C96.2 197.72 96 203.89 96 256s.2 58.28 1.14 78.86c.87 19.03 4.05 29.36 6.72 36.24 3.54 9.11 7.77 15.61 14.6 22.44s13.33 11.06 22.44 14.6c6.87 2.67 17.21 5.85 36.24 6.72 20.57.94 26.75 1.14 78.86 1.14s58.29-.2 78.86-1.14c19.03-.87 29.37-4.05 36.24-6.72 9.11-3.54 15.61-7.77 22.44-14.6s11.06-13.33 14.6-22.44c2.67-6.88 5.85-17.21 6.72-36.24.94-20.58 1.14-26.75 1.14-78.86s-.2-58.28-1.14-78.86c-.87-19.03-4.05-29.37-6.72-36.24M256 352c-53.02 0-96-42.98-96-96s42.98-96 96-96 96 42.98 96 96-42.98 96-96 96m104-176c-13.25 0-24-10.75-24-24s10.75-24 24-24 24 10.74 24 24-10.75 24-24 24m-104 16c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m0 0c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m0 0c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m158.86-14.86c-.87-19.03-4.05-29.37-6.72-36.24-3.54-9.11-7.77-15.61-14.6-22.44s-13.33-11.06-22.44-14.6c-6.87-2.68-17.21-5.85-36.24-6.72C314.28 96.2 308.11 96 256 96s-58.28.2-78.86 1.14c-19.03.87-29.37 4.04-36.24 6.72-9.11 3.54-15.61 7.77-22.44 14.6s-11.06 13.33-14.6 22.44c-2.67 6.87-5.85 17.21-6.72 36.24C96.2 197.72 96 203.89 96 256s.2 58.28 1.14 78.86c.87 19.03 4.05 29.36 6.72 36.24 3.54 9.11 7.77 15.61 14.6 22.44s13.33 11.06 22.44 14.6c6.87 2.67 17.21 5.85 36.24 6.72 20.57.94 26.75 1.14 78.86 1.14s58.29-.2 78.86-1.14c19.03-.87 29.37-4.05 36.24-6.72 9.11-3.54 15.61-7.77 22.44-14.6s11.06-13.33 14.6-22.44c2.67-6.88 5.85-17.21 6.72-36.24.94-20.58 1.14-26.75 1.14-78.86s-.2-58.28-1.14-78.86M256 352c-53.02 0-96-42.98-96-96s42.98-96 96-96 96 42.98 96 96-42.98 96-96 96m104-176c-13.25 0-24-10.75-24-24s10.75-24 24-24 24 10.74 24 24-10.75 24-24 24m-104 16c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m0 0c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m0 0c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64m158.86-14.86c-.87-19.03-4.05-29.37-6.72-36.24-3.54-9.11-7.77-15.61-14.6-22.44s-13.33-11.06-22.44-14.6c-6.87-2.68-17.21-5.85-36.24-6.72C314.28 96.2 308.11 96 256 96s-58.28.2-78.86 1.14c-19.03.87-29.37 4.04-36.24 6.72-9.11 3.54-15.61 7.77-22.44 14.6s-11.06 13.33-14.6 22.44c-2.67 6.87-5.85 17.21-6.72 36.24C96.2 197.72 96 203.89 96 256s.2 58.28 1.14 78.86c.87 19.03 4.05 29.36 6.72 36.24 3.54 9.11 7.77 15.61 14.6 22.44s13.33 11.06 22.44 14.6c6.87 2.67 17.21 5.85 36.24 6.72 20.57.94 26.75 1.14 78.86 1.14s58.29-.2 78.86-1.14c19.03-.87 29.37-4.05 36.24-6.72 9.11-3.54 15.61-7.77 22.44-14.6s11.06-13.33 14.6-22.44c2.67-6.88 5.85-17.21 6.72-36.24.94-20.58 1.14-26.75 1.14-78.86s-.2-58.28-1.14-78.86M256 352c-53.02 0-96-42.98-96-96s42.98-96 96-96 96 42.98 96 96-42.98 96-96 96m104-176c-13.25 0-24-10.75-24-24s10.75-24 24-24 24 10.74 24 24-10.75 24-24 24m-104 16c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64" />',viewBox:"0 0 512 512"},instagramIcon:{name:"instagram",content:'<path d="M256 160c-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96-42.98-96-96-96m0 160c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64m104-192c-13.25 0-24 10.74-24 24s10.75 24 24 24 24-10.75 24-24-10.75-24-24-24m-104 32c-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96-42.98-96-96-96m0 160c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64m104-192c-13.25 0-24 10.74-24 24s10.75 24 24 24 24-10.75 24-24-10.75-24-24-24m0 0c-13.25 0-24 10.74-24 24s10.75 24 24 24 24-10.75 24-24-10.75-24-24-24m-104 32c-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96-42.98-96-96-96m0 160c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64m190.84-143.16c-.93-20.44-4.17-34.39-8.92-46.61-4.91-12.62-11.47-23.33-22.14-34-10.68-10.68-21.39-17.24-34.01-22.15-12.22-4.75-26.17-7.99-46.61-8.92C314.68 64.22 308.14 64 256 64s-58.68.22-79.16 1.16c-20.44.93-34.39 4.17-46.61 8.92-12.62 4.91-23.33 11.47-34 22.15-10.68 10.67-17.24 21.38-22.15 34-4.75 12.22-7.99 26.17-8.93 46.61C64.22 197.32 64 203.86 64 256s.22 58.68 1.15 79.16c.94 20.44 4.18 34.39 8.93 46.61 4.91 12.62 11.47 23.33 22.15 34 10.67 10.68 21.38 17.24 34 22.15 12.22 4.75 26.17 7.99 46.61 8.93 20.48.93 27.02 1.15 79.16 1.15s58.68-.22 79.16-1.15c20.44-.94 34.39-4.18 46.61-8.93 12.62-4.91 23.33-11.47 34.01-22.15 10.67-10.67 17.23-21.38 22.14-34 4.75-12.22 7.99-26.17 8.92-46.61.94-20.48 1.16-27.02 1.16-79.16s-.22-58.68-1.16-79.16m-31.98 158.02c-.87 19.03-4.05 29.36-6.72 36.24-3.54 9.11-7.77 15.61-14.6 22.44s-13.33 11.06-22.44 14.6c-6.87 2.67-17.21 5.85-36.24 6.72-20.57.94-26.74 1.14-78.86 1.14s-58.29-.2-78.86-1.14c-19.03-.87-29.37-4.05-36.24-6.72-9.11-3.54-15.61-7.77-22.44-14.6s-11.06-13.33-14.6-22.44c-2.67-6.88-5.85-17.21-6.72-36.24C96.2 314.28 96 308.11 96 256s.2-58.28 1.14-78.86c.87-19.03 4.05-29.37 6.72-36.24 3.54-9.11 7.77-15.61 14.6-22.44s13.33-11.06 22.44-14.6c6.87-2.68 17.21-5.85 36.24-6.72C197.72 96.2 203.89 96 256 96s58.28.2 78.86 1.14c19.03.87 29.37 4.04 36.24 6.72 9.11 3.54 15.61 7.77 22.44 14.6s11.06 13.33 14.6 22.44c2.67 6.87 5.85 17.21 6.72 36.24.94 20.58 1.14 26.75 1.14 78.86s-.2 58.28-1.14 78.86M360 128c-13.25 0-24 10.74-24 24s10.75 24 24 24 24-10.75 24-24-10.75-24-24-24m-104 32c-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96-42.98-96-96-96m0 160c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64m0-160c-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96-42.98-96-96-96m0 160c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64m104-192c-13.25 0-24 10.74-24 24s10.75 24 24 24 24-10.75 24-24-10.75-24-24-24" />',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"},labTechnicianOutlineIcon:{name:"lab-technician-outline",content:'<path d="M339.42 80.47C322.88 51.52 291.71 32 256 32s-66.88 19.52-83.42 48.47c-16.29 1.51-29.08 15.19-29.08 31.78v31.83c0 16.66 12.89 30.38 29.28 31.8C189.37 204.63 220.43 224 256 224s66.63-19.37 83.22-48.12c16.39-1.42 29.28-15.14 29.28-31.8v-31.83c0-16.59-12.79-30.27-29.08-31.78M256 64c16.36 0 31.32 6.18 42.65 16.33h-85.3C224.68 70.18 239.64 64 256 64m-64 64c0-5.41.67-10.66 1.95-15.67h30.08v31.66l-.08.01h-29.92a63.5 63.5 0 0 1-2.03-16m64 64c-16.19 0-30.99-6.05-42.28-16h10.23c17.22 0 31.31-13.57 32.05-30.52.74 16.95 14.83 30.52 32.05 30.52h10.23c-11.29 9.95-26.09 16-42.28 16m61.97-48h-29.92l-.08-.01v-31.66h30.08A63.2 63.2 0 0 1 320 128c0 5.41-.7 10.89-2.03 16M464 208h-96c-4.42 0-8.42 1.79-11.32 4.68-2.89 2.9-4.68 6.9-4.68 11.32 0 8.84 7.16 16 16 16v192c0 26.51 21.49 48 48 48 .41 0 .83-.01 1.24-.02 12.77-.32 24.29-5.62 32.7-14.04C458.63 457.26 464 445.26 464 432V240c4.42 0 8.42-1.79 11.32-4.68 2.89-2.9 4.68-6.9 4.68-11.32 0-8.84-7.16-16-16-16m-32 112h-32v-80h32zm-176-32c16.5 0 32.57 2.45 48 7.32V432c0 5.4.38 10.74 1.13 16H96c0-42.72 16.65-82.89 46.88-113.12S213.28 288 256 288m0-32c-106 0-192 86-192 192 0 17.7 14.3 32 32 32h256.03C341.97 466.62 336 450 336 432V273.43C311.64 262.24 284.55 256 256 256" />',viewBox:"0 0 512 512"},labTechnicianSolidIcon:{name:"lab-technician-solid",content:'<path d="M336.42 80.33c1.01 0 2.02.05 3 .14C322.88 51.52 291.71 32 256 32s-66.88 19.52-83.42 48.47c.98-.09 1.99-.14 3-.14zM288.05 176c-17.22 0-31.31-13.57-32.05-30.52-.74 16.95-14.83 30.52-32.05 30.52h-48.37c-.94 0-1.88-.04-2.8-.12C189.37 204.63 220.43 224 256 224s66.63-19.37 83.22-48.12c-.92.08-1.86.12-2.8.12zm-.08-63.67v31.66h48.53v-31.66h-48.53m-112.47 0v31.65h48.53v-31.67H175.5ZM320 431.99V266.93c-20.02-7.09-41.56-10.94-64-10.94-106 0-192 86-192 192 0 17.7 14.3 32 32 32h240.03c-10.06-13.38-16.03-30-16.03-48m144-224h-96c-4.42 0-8.42 1.79-11.32 4.68-2.89 2.9-4.68 6.9-4.68 11.32 0 8.84 7.16 16 16 16v192c0 26.51 21.49 48 48 48 .41 0 .83-.01 1.24-.02 12.77-.32 24.29-5.62 32.7-14.04 8.69-8.68 14.06-20.68 14.06-33.94v-192c4.42 0 8.42-1.79 11.32-4.68 2.89-2.9 4.68-6.9 4.68-11.32 0-8.84-7.16-16-16-16m-32 112h-32v-80h32z" />',viewBox:"0 0 512 512"},laptopOutlineIcon:{name:"laptop-outline",content:'<path d="M480 384c0 8.84-3.58 16.84-9.37 22.63S456.84 416 448 416H64c-17.67 0-32-14.33-32-32h192v8c0 4.42 3.58 8 8 8h48c4.42 0 8-3.58 8-8v-8zm-64-256H96v192h320zm0-32c17.67 0 32 14.33 32 32v224H64V128c0-17.67 14.33-32 32-32z" />',viewBox:"0 0 512 512"},laptopSolidIcon:{name:"laptop-solid",content:'<path d="M480 384c0 8.84-3.58 16.84-9.37 22.63S456.84 416 448 416H64c-17.67 0-32-14.33-32-32h192v8c0 4.42 3.58 8 8 8h48c4.42 0 8-3.58 8-8v-8zm-32-256v224H64V128c0-17.67 14.33-32 32-32h320c17.67 0 32 14.33 32 32" />',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"},lineShapeIcon:{name:"line-shape",content:'<path d="m393.4 96-32 32zm-64 64-32 32zm-64 64-32 32zm-64 64-32 32zm-64 64-32 32zM32 457.4 54.6 480 480 54.6 457.4 32z" />',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"},locationsIcon:{name:"locations",content:'<path d="M256.09 63c-72.95 0-132.08 59.1-132.08 132 0 10.44 2.71 23.05 7.35 37.01 6.91 20.81 18.13 44.6 31.07 68.59 38.99 72.28 93.66 146.4 93.66 146.4s54.56-73.99 93.55-146.21c13.05-24.16 24.35-48.12 31.27-69.05 4.59-13.85 7.26-26.37 7.26-36.74 0-72.9-59.14-132-132.08-132m0 220c-54.19 0-98.06-43.84-98.06-98s43.87-98 98.06-98 98.06 43.84 98.06 98-43.87 98-98.06 98m-123.43 28.82C125.09 322.81 112.41 330 98.04 330c-23.23 0-42.03-18.79-42.03-42s18.79-42 42.03-42q2.385 0 4.71.27c-3.05-8.62-5.45-16.68-7.19-24.22C60.24 223.35 32 252.38 32 288s66.04 126 66.04 126 29.17-39.55 48.73-76.78c-5.04-8.76-9.75-17.24-14.11-25.4m283.98-89.76c-1.73 7.53-4.12 15.57-7.17 24.18 1.48-.16 2.97-.24 4.49-.24 23.22 0 42.03 18.78 42.03 42s-18.8 42-42.03 42c-14.29 0-26.91-7.11-34.48-17.99-4.37 8.17-9.09 16.66-14.14 25.43C384.9 374.6 413.96 414 413.96 414S480 324.45 480 288s-28.13-64.54-63.36-65.94" />',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"},luggageOutlineIcon:{name:"luggage-outline",content:'<path d="M352 176v256H160V176zm0-32H160c-17.67 0-32 14.07-32 31.41v257.18c0 17.34 14.33 31.41 32 31.41h192c17.67 0 32-14.07 32-31.41V175.41c0-17.34-14.33-31.41-32-31.41M288 32l-65.97.19C205.35 32.19 192 45.3 192 62v82h32l-.3-79.88L288 64v80h32V64c0-17.63-14.4-32-32-32m40 448h16c4.42 0 8-3.58 8-8v-16c0-4.42-3.58-8-8-8h-16c-4.42 0-8 3.58-8 8v16c0 4.42 3.58 8 8 8m-160 0h16c4.42 0 8-3.58 8-8v-16c0-4.42-3.58-8-8-8h-16c-4.42 0-8 3.58-8 8v16c0 4.42 3.58 8 8 8m112-272h-48c-4.42 0-8 3.58-8 8v16c0 4.42 3.58 8 8 8h48c4.42 0 8-3.58 8-8v-16c0-4.42-3.58-8-8-8" />',viewBox:"0 0 512 512"},luggageSolidIcon:{name:"luggage-solid",content:'<path d="M352 144H160c-17.67 0-32 14.07-32 31.41v257.18c0 17.34 14.33 31.41 32 31.41v8c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8v-8h128v8c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8v-8c17.67 0 32-14.07 32-31.41V175.41c0-17.34-14.33-31.41-32-31.41m-64 88c0 4.42-3.58 8-8 8h-48c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h48c4.42 0 8 3.58 8 8zm32-168v80h-32V64l-64.3.12.3 79.88h-32V62c0-16.7 13.35-29.81 30.03-29.81L288 32c17.6 0 32 14.37 32 32" />',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"},microphoneOutlineIcon:{name:"microphone-outline",content:'<path d="M309.09 480H202.9c-10.17 0-18.42-7.16-18.42-16s8.25-16 18.42-16h34.68v-45.63c-69.58-4.63-104.35-35.33-121.47-61.4-19.89-30.3-20.12-60.58-20.12-61.85 0-8.84 8.25-16 18.42-16s18.38 7.13 18.42 15.94c0 .54.51 24.23 15.96 47.08 20.11 29.75 56.18 44.84 107.21 44.84s87.1-15.08 107.21-44.84c15.54-22.99 15.95-46.84 15.96-47.08 0-8.84 8.25-15.97 18.42-15.97s18.42 7.2 18.42 16.03c0 1.27-.23 31.55-20.12 61.85-17.12 26.08-51.89 56.77-121.47 61.4V448h34.68c10.17 0 18.42 7.16 18.42 16s-8.25 16-18.42 16zM256 341.33c-35.88 0-63.73-14.09-78.42-39.67-10.48-18.25-10.79-36-10.79-37.96V109.63c0-1.96.3-19.7 10.79-37.96C192.27 46.09 220.12 32 256 32s63.73 14.09 78.42 39.67c10.48 18.25 10.79 36 10.79 37.96V263.7c0 1.96-.3 19.7-10.79 37.96-14.69 25.58-42.54 39.67-78.42 39.67M256 64c-21.71 0-36.43 6.92-44.99 21.16-7.13 11.85-7.38 24.44-7.38 24.57v153.98s.25 12.62 7.38 24.47c8.56 14.24 23.28 21.16 44.99 21.16s36.43-6.92 44.99-21.16c7.13-11.85 7.38-24.44 7.38-24.57V109.63s-.25-12.62-7.38-24.47C292.43 70.92 277.71 64 256 64" />',viewBox:"0 0 512 512"},microphoneSolidIcon:{name:"microphone-solid",content:'<path d="M309.09 480H202.9c-10.17 0-18.42-7.16-18.42-16s8.25-16 18.42-16h34.68v-45.63c-69.58-4.63-104.35-35.33-121.47-61.4-19.89-30.3-20.12-60.58-20.12-61.85 0-8.84 8.25-16 18.42-16s18.38 7.13 18.42 15.94c0 .54.51 24.23 15.96 47.08 20.11 29.75 56.18 44.84 107.21 44.84s87.1-15.08 107.21-44.84c15.54-22.99 15.95-46.84 15.96-47.08 0-8.84 8.25-15.97 18.42-15.97s18.42 7.2 18.42 16.03c0 1.27-.23 31.55-20.12 61.85-17.12 26.08-51.89 56.77-121.47 61.4V448h34.68c10.17 0 18.42 7.16 18.42 16s-8.25 16-18.42 16zM256 341.33c-35.88 0-63.73-14.09-78.42-39.67-10.48-18.25-10.79-36-10.79-37.96V109.63c0-1.96.3-19.7 10.79-37.96C192.27 46.09 220.12 32 256 32s63.73 14.09 78.42 39.67c10.48 18.25 10.79 36 10.79 37.96V263.7c0 1.96-.3 19.7-10.79 37.96-14.69 25.58-42.54 39.67-78.42 39.67" />',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"},mobileOutlineIcon:{name:"mobile-outline",content:'<path d="M384 64v384c0 17.6-14.4 32-32 32H160c-13.57 0-25.24-8.56-29.87-20.56A31.5 31.5 0 0 1 128 448V64c0-4.03.75-7.89 2.13-11.44C134.76 40.56 146.43 32 160 32h192c17.6 0 32 14.4 32 32M160 352h192V64.06l-.06-.06H160.06l-.06.06zm192 32H160v63.94l.06.06h191.88l.06-.06zm-80 32c0-8.84-7.16-16-16-16s-16 7.16-16 16 7.16 16 16 16 16-7.16 16-16" />',viewBox:"0 0 512 512"},mobileOutlineRingingIcon:{name:"mobile-outline-ringing",content:'<path d="M496 256c0 30.67-6.16 59.91-17.33 86.53a15.44 15.44 0 0 1-5.7 6.89 15.5 15.5 0 0 1-8.57 2.58c-11.08 0-18.52-11.29-14.24-21.51C459.9 307.21 465 282 465 256s-5.1-51.21-14.84-74.49c-4.28-10.22 3.16-21.51 14.24-21.51 6.23 0 11.86 3.73 14.27 9.47C489.84 196.09 496 225.33 496 256m-65.96-57.12c-5.89-16.29-30.04-12.02-30.04 5.3 0 1.83.34 3.64.96 5.36 5.28 14.72 8.04 30.37 8.04 46.46s-2.76 31.74-8.04 46.46c-.62 1.72-.96 3.53-.96 5.36 0 17.32 24.15 21.59 30.04 5.3 6.45-17.83 9.96-37.07 9.96-57.12s-3.51-39.29-9.96-57.12M47 256c0-26 5.1-51.21 14.84-74.49C66.12 171.29 58.68 160 47.6 160c-3.12 0-6.08.93-8.57 2.58a15.44 15.44 0 0 0-5.7 6.89C22.16 196.09 16 225.33 16 256s6.16 59.91 17.33 86.53c2.41 5.74 8.04 9.47 14.27 9.47 11.08 0 18.52-11.29 14.24-21.51C52.1 307.21 47 282 47 256m56 0c0-16.09 2.76-31.74 8.04-46.46.62-1.72.96-3.53.96-5.36 0-17.32-24.15-21.59-30.04-5.3C75.51 216.71 72 235.95 72 256s3.51 39.29 9.96 57.12c5.89 16.29 30.04 12.02 30.04-5.3 0-1.83-.34-3.64-.96-5.36-5.28-14.72-8.04-30.37-8.04-46.46M384 64v384c0 17.6-14.4 32-32 32H160c-13.57 0-25.24-8.56-29.87-20.56A31.5 31.5 0 0 1 128 448V64c0-4.03.75-7.89 2.13-11.44C134.76 40.56 146.43 32 160 32h192c17.6 0 32 14.4 32 32M160 352h192V64.06l-.06-.06H160.06l-.06.06zm192 32H160v63.94l.06.06h191.88l.06-.06zm-80 32c0-8.84-7.16-16-16-16s-16 7.16-16 16 7.16 16 16 16 16-7.16 16-16" />',viewBox:"0 0 512 512"},mobileSolidIcon:{name:"mobile-solid",content:'<path d="M352 32H160c-13.57 0-25.24 8.56-29.87 20.56A31.5 31.5 0 0 0 128 64v384c0 4.03.75 7.89 2.13 11.44 4.63 12 16.3 20.56 29.87 20.56h192c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m-96 400c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16m96-80H160V64.06l.06-.06h191.88l.06.06z" />',viewBox:"0 0 512 512"},mobileSolidRingingIcon:{name:"mobile-solid-ringing",content:'<path d="M352 32H160c-13.57 0-25.24 8.56-29.87 20.56A31.5 31.5 0 0 0 128 64v384c0 4.03.75 7.89 2.13 11.44 4.63 12 16.3 20.56 29.87 20.56h192c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m-96 400c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16m96-80H160V64.06l.06-.06h191.88l.06.06zm144-96c0 30.67-6.16 59.91-17.33 86.53a15.44 15.44 0 0 1-5.7 6.89 15.5 15.5 0 0 1-8.57 2.58c-11.08 0-18.52-11.29-14.24-21.51C459.9 307.21 465 282 465 256s-5.1-51.21-14.84-74.49c-4.28-10.22 3.16-21.51 14.24-21.51 6.23 0 11.86 3.73 14.27 9.47C489.84 196.09 496 225.33 496 256m-56 0c0 20.05-3.51 39.29-9.96 57.12-5.89 16.29-30.04 12.02-30.04-5.3 0-1.83.34-3.64.96-5.36 5.28-14.72 8.04-30.37 8.04-46.46s-2.76-31.74-8.04-46.46c-.62-1.72-.96-3.53-.96-5.36 0-17.32 24.15-21.59 30.04-5.3 6.45 17.83 9.96 37.07 9.96 57.12M61.84 330.49C66.12 340.71 58.68 352 47.6 352c-6.23 0-11.86-3.73-14.27-9.47C22.16 315.91 16 286.67 16 256s6.16-59.91 17.33-86.53a15.44 15.44 0 0 1 5.7-6.89c2.49-1.65 5.45-2.58 8.57-2.58 11.08 0 18.52 11.29 14.24 21.51C52.1 204.79 47 230 47 256s5.1 51.21 14.84 74.49m49.2-28.03c.62 1.72.96 3.53.96 5.36 0 17.32-24.15 21.59-30.04 5.3C75.51 295.29 72 276.05 72 256s3.51-39.29 9.96-57.12c5.89-16.29 30.04-12.02 30.04 5.3 0 1.83-.34 3.64-.96 5.36-5.28 14.72-8.04 30.37-8.04 46.46s2.76 31.74 8.04 46.46" />',viewBox:"0 0 512 512"},moneyExchangeIcon:{name:"money-exchange",content:'<path d="m413.46 120-22.91 22.65c26.63 31.53 41.14 70.9 41.14 112.48 0 46.94-18.49 91.08-52.06 124.27-12.32 12.18-26.14 22.36-41.04 30.37-25.68 13.79-54.59 21.11-84.64 21.11-11.62 0-23.07-1.1-34.23-3.25-4.02-1.63-8-3.41-11.9-5.25l13.98-28.82-68.67 6.35-25.11 2.32-.02.02 22.45 33.65 29.42 44.09 12.69-26.18c11.2 3.38 22.8 5.85 34.7 7.34l.45.06c1.46.18 2.95.35 4.43.5.03 0 .06.01.08.01 7.14.72 14.39 1.09 21.73 1.09 116.02 0 210.05-92.98 210.05-207.7 0-51.61-19.03-98.81-50.54-135.13Zm-51.91-43.92L332.13 32l-12.69 26.17c-11.2-3.38-22.79-5.85-34.7-7.33l-.44-.06c-1.47-.18-2.95-.35-4.44-.5-.03 0-.06-.01-.08-.01-7.14-.73-14.39-1.1-21.73-1.1C142.04 49.17 48 142.16 48 256.88c0 51.61 19.04 98.81 50.54 135.13l22.92-22.65c-26.63-31.53-41.14-70.9-41.14-112.48 0-46.95 18.49-91.08 52.05-124.27 12.32-12.18 26.15-22.37 41.04-30.37 25.68-13.8 54.6-21.11 84.64-21.11 11.62 0 23.08 1.09 34.23 3.25 4.02 1.62 8 3.41 11.9 5.25l-13.98 28.81 68.67-6.34 25.11-2.33.02-.02-22.45-33.65ZM297.3 264.3c-4.15-3.65-9.2-6.8-15.2-9.55-5.9-2.7-12.6-5.1-20.1-7.25v-53.8c3.25.4 6.5 1.1 8.85 2.1 3.75 1.65 6.85 3.9 9.4 6.85q3.825 4.35 5.7 10.35c1.3 4 1.9 8.35 1.9 13.1H310c0-14.6-3.75-26.05-11.25-34.45s-18-13.4-31.45-15.05c0 0-2.5-.2-5.3-.4V144h-16v32.75c-5.95.75-11.3 2.15-16.1 4.2-5.3 2.25-9.8 5.15-13.55 8.75s-6.6 7.8-8.6 12.7c-2 4.85-3 10.25-3 16.15 0 6.35 1.1 11.9 3.35 16.75s5.5 9.1 9.75 12.8 9.4 6.9 15.45 9.65c3.9 1.75 8.15 3.4 12.7 4.85v55.45q-2.025-.3-4.05-.75c-3.95-.9-7.6-2.55-10.85-4.9s-5.9-5.5-7.9-9.5-3-9-3-15.05H198c0 8.1 1.3 15.05 3.95 20.85s6.2 10.6 10.65 14.35 9.55 6.65 15.3 8.65 11.7 3.25 17.85 3.75c0 0 .1 0 .25.05V368h16v-32.4c.95-.1 1.55-.15 1.55-.15 7.05-.65 13.45-2.05 19.2-4.15q8.625-3.225 14.7-8.55c4.05-3.55 7.15-7.8 9.3-12.7S310 299.6 310 293.4s-1.1-11.75-3.25-16.55c-2.15-4.75-5.3-8.95-9.45-12.55m-51.35-22.45c-.3-.1-.7-.25-1.05-.45-4.4-2.05-7.95-4.2-10.6-6.45s-4.55-4.8-5.65-7.5c-1.1-2.75-1.7-5.8-1.7-9.25 0-3.7.6-7.05 1.8-10.15 1.2-3.05 3-5.65 5.4-7.85 2.4-2.15 5.45-3.85 9.15-5.05.59-.21 1.2-.37 1.82-.53.28-.07.55-.14.83-.22zm39.5 62.15c-1.5 3.1-3.75 5.7-6.6 7.9-2.9 2.15-6.4 3.85-10.6 5-1.95.55-4.05.95-6.25 1.25V267.6c2.8 1 5.35 2.05 7.65 3.1 4.3 2 7.8 4.15 10.45 6.5 2.7 2.35 4.65 4.85 5.85 7.55q1.8 4.05 1.8 8.85c0 3.85-.75 7.35-2.3 10.4" />',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"},nonStopOutlineIcon:{name:"non-stop-outline",content:'<path d="M288.96 311.91h-15.97l31.94-111.8h15.97zm-46.81-41.28V200h-17.89l-48.2 70.7v18.69h45.48v22.41h20.61v-22.41h13.8v-18.76zm-20.61 0H196l25.54-38.05zm118.33-50.34v-20.18h75.08v15.77c-6.2 6.03-12.5 14.69-18.91 25.98s-11.29 23.29-14.65 35.99c-3.36 12.71-5.01 24.06-4.96 34.06h-21.17q.54-23.505 9.81-47.94c6.17-16.29 14.42-30.85 24.73-43.68zm-205.5 65.97c1.82-2.03 6.15-6.13 12.98-12.31 6.83-6.17 11.55-10.91 14.16-14.19 3.96-4.97 6.85-9.71 8.67-14.24s2.72-9.3 2.72-14.31c0-8.81-3.18-16.18-9.54-22.1-4.77-4.44-10.89-7.23-18.35-8.34-2.49-.37-5.12-.56-7.91-.56-10.17 0-18.65 2.57-25.42 7.68-6.78 5.11-10.81 13.55-12.09 25.29l20.97 2.07.59.06c.03-.44.06-.87.11-1.29.53-5.56 2.04-9.59 4.51-12.09a12.8 12.8 0 0 1 5.02-3.12c1.72-.6 3.63-.9 5.77-.9 4.56 0 8.15 1.28 10.74 3.83 2.6 2.57 3.89 6.22 3.89 10.98 0 4.3-1.5 8.65-4.47 13.07-2.21 3.18-8.2 9.26-17.95 18.23-12.12 11.09-20.22 19.98-24.34 26.69-3.08 5.03-5.24 10.29-6.47 15.76v.04c-.4 1.78-.7 3.58-.91 5.41l-.01.09h75.86V292.2h-42.97c1.13-1.93 2.62-3.91 4.44-5.94M256 64c51.29 0 99.5 19.97 135.76 56.24C428.02 156.5 448 204.72 448 256s-19.97 99.5-56.24 135.76C355.5 428.02 307.28 448 256 448s-99.5-19.97-135.76-56.24C83.98 355.5 64 307.28 64 256s19.97-99.5 56.24-135.76C156.5 83.98 204.72 64 256 64m0-32C132.29 32 32 132.29 32 256s100.29 224 224 224 224-100.29 224-224S379.71 32 256 32" />',viewBox:"0 0 512 512"},nonStopSolidIcon:{name:"non-stop-solid",content:'<path d="M196 270.63h25.54v-38.05zm0 0h25.54v-38.05zM256 32C132.29 32 32 132.29 32 256s100.29 224 224 224 224-100.29 224-224S379.71 32 256 32m-83.09 260.19V312H97.04s.01-.06.01-.09c.21-1.83.51-3.63.91-5.41.01-.02.01-.03.01-.04 1.23-5.47 3.39-10.73 6.47-15.76 4.11-6.71 12.22-15.6 24.34-26.69 9.75-8.97 15.74-15.05 17.95-18.23 2.97-4.41 4.47-8.77 4.47-13.07 0-4.76-1.3-8.41-3.9-10.98-2.59-2.55-6.17-3.83-10.74-3.83-2.13 0-4.05.3-5.77.9-1.93.67-3.6 1.7-5.02 3.12-2.47 2.5-3.98 6.53-4.51 12.09-.05.42-.08.85-.11 1.29l-.59-.06-20.97-2.07q1.92-17.625 12.09-25.29c6.78-5.11 15.25-7.68 25.42-7.68 2.79 0 5.42.19 7.91.56 7.46 1.11 13.58 3.89 18.36 8.33 6.35 5.92 9.54 13.29 9.54 22.1 0 5.02-.91 9.79-2.73 14.32s-4.71 9.27-8.67 14.24c-2.62 3.29-7.34 8.03-14.17 14.2-6.82 6.18-11.16 10.28-12.97 12.31-1.83 2.02-3.31 4-4.43 5.93zm83.04-2.8h-13.79v22.41h-20.62v-22.41h-45.48V270.7l48.21-70.7h17.89v70.63h13.79zm33.01 22.52h-15.97l31.94-111.8h15.98zm107.09-70.05c-6.41 11.29-11.29 23.29-14.65 35.99-3.36 12.71-5.01 24.06-4.96 34.06h-21.18q.555-23.505 9.81-47.94c6.17-16.28 14.41-30.85 24.73-43.68h-49.93v-20.18h75.09v15.77c-6.2 6.03-12.5 14.69-18.91 25.98m-174.51 28.77v-38.05L196 270.63z" />',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"},nurseOutlineIcon:{name:"nurse-outline",content:'<path d="m128 32 31.99 96.01c0 43.7 29.25 80.6 69.23 92.2 8.5 2.47 17.48 3.79 26.78 3.79s18.28-1.32 26.78-3.79c39.98-11.6 69.23-48.5 69.23-92.2L384 32zm178.94 134.74c-8.3 10.88-20.05 18.95-33.11 22.74A63.7 63.7 0 0 1 256 192c-6.1 0-12.1-.85-17.86-2.53-13.03-3.78-24.78-11.85-33.08-22.73-8.55-11.21-13.07-24.6-13.07-38.73h128.02c0 14.13-4.52 27.52-13.07 38.73m22-70.73H183.06L172.39 64h167.22zM256 288c13.58 0 27.04 1.7 40.01 5.05 4.49 1.16 8.97 2.53 13.36 4.08 4.46 1.57 8.91 3.38 13.24 5.37l.12.06c1.76.8 3.5 1.63 5.2 2.49 2.7 1.36 5.37 2.8 7.93 4.3l.1.06c23.5 13.59 43.32 33.09 57.31 56.4 14.86 24.74 22.71 53.16 22.71 82.19H96c0-29.02 7.86-57.44 22.72-82.2 12.75-21.24 30.55-39.51 51.47-52.83l.04-.03c1.92-1.23 3.87-2.41 5.78-3.52l.1-.06c2.19-1.28 4.39-2.49 6.59-3.62a159 159 0 0 1 19.97-8.62c17.06-6.04 35.01-9.12 53.33-9.12m-.01-31.98c-22.44 0-43.98 3.85-64 10.94a191.172 191.172 0 0 0-23.97 10.36c-2.72 1.4-5.39 2.87-8.03 4.41-2.37 1.37-4.7 2.79-7 4.26a192.9 192.9 0 0 0-61.72 63.36c-17.31 28.84-27.28 62.59-27.28 98.67 0 17.7 14.31 32 32 32h320c17.69 0 32-14.3 32-32 0-36.08-9.96-69.83-27.28-98.67a192.9 192.9 0 0 0-68.72-67.62c-3.17-1.85-6.4-3.6-9.68-5.25-2.08-1.05-4.19-2.06-6.32-3.03a186 186 0 0 0-16-6.49c-5.23-1.85-10.57-3.48-16-4.88-15.34-3.96-31.43-6.06-48-6.06m48 96v32h-32v32h-32v-32h-32v-32h32v-32h32v32z" />',viewBox:"0 0 512 512"},nurseSolidIcon:{name:"nurse-solid",content:'<path d="M352 128.01c0 43.7-29.24 80.6-69.22 92.2A95.8 95.8 0 0 1 256 224c-9.3 0-18.28-1.32-26.78-3.79-39.98-11.6-69.22-48.5-69.22-92.2zM448 448c0 17.7-14.31 32-32 32H96c-17.69 0-32-14.3-32-32 0-36.08 9.97-69.83 27.28-98.67A192.9 192.9 0 0 1 153 285.97c2.3-1.47 4.63-2.89 7-4.26 2.64-1.54 5.31-3.01 8.03-4.41A191 191 0 0 1 192 266.94c20.02-7.09 41.56-10.94 64-10.94 16.57 0 32.66 2.1 48 6.06 5.43 1.4 10.77 3.03 16 4.88a186 186 0 0 1 16 6.49c2.13.97 4.24 1.98 6.32 3.03 3.28 1.65 6.51 3.4 9.68 5.25a192.9 192.9 0 0 1 68.72 67.62C438.04 378.17 448 411.92 448 448m-144-96h-32v-32h-32v32h-32v32h32v32h32v-32h32zM128 32l21.33 64.01h213.34L384 32z" />',viewBox:"0 0 512 512"},optimizationIcon:{name:"optimization",content:'<path d="m384.03 109.71-93.79 8.68 13.98-28.8c-3.9-1.85-7.88-3.62-11.9-5.25-11.16-2.15-22.61-3.24-34.24-3.24-30.05 0-58.96 7.31-84.65 21.1-14.9 7.99-28.72 18.17-41.05 30.35-33.57 33.17-52.07 77.28-52.07 124.19 0 41.55 14.51 80.9 41.15 112.4l-22.92 22.64c-31.51-36.29-50.55-83.47-50.55-135.04 0-114.64 94.05-207.56 210.08-207.56 7.34 0 14.59.37 21.74 1.1h.08c1.48.15 2.97.32 4.43.5l.44.06c11.91 1.49 23.5 3.96 34.7 7.33l12.7-26.15zM127.97 402.29l93.79-8.68-13.98 28.8c3.9 1.85 7.88 3.62 11.9 5.25 11.16 2.15 22.61 3.24 34.24 3.24 30.05 0 58.96-7.31 84.65-21.1 14.9-7.99 28.72-18.17 41.05-30.35 33.57-33.17 52.07-77.28 52.07-124.19 0-41.55-14.51-80.9-41.15-112.4l22.92-22.64c31.51 36.29 50.55 83.47 50.55 135.04 0 114.64-94.05 207.56-210.08 207.56-7.34 0-14.59-.37-21.74-1.1h-.08c-1.48-.15-2.97-.32-4.43-.5l-.44-.06c-11.91-1.49-23.5-3.96-34.7-7.33l-12.7 26.15zm230.8-115.34-20.63-15.7c.89-4.95 1.39-10.05 1.39-15.25s-.5-10.3-1.39-15.25l20.63-15.7a8.1 8.1 0 0 0 2.09-10.4L344 185.3a7.88 7.88 0 0 0-9.99-3.35l-23.86 10.1a82.8 82.8 0 0 0-26.25-15.25l-3.14-25.8c-.49-4-3.87-7-7.9-7h-33.71c-4.03 0-7.41 3-7.9 7l-3.23 25.8c-9.7 3.45-18.6 8.65-26.25 15.25l-23.87-10.1c-3.68-1.55-7.95-.1-9.99 3.35l-16.86 29.35c-1.98 3.5-1.09 7.95 2.09 10.4l20.63 15.7c-.79 4.95-1.29 10.05-1.29 15.25s.5 10.3 1.39 15.25l-20.63 15.7c-3.18 2.45-4.07 6.9-2.09 10.4l16.86 29.35a7.88 7.88 0 0 0 9.99 3.35l23.86-10.1c7.66 6.6 16.56 11.8 26.25 15.25l3.24 25.8c.49 4 3.87 7 7.9 7h33.71c4.03 0 7.41-3 7.9-7l3.24-25.8a82.8 82.8 0 0 0 26.25-15.25l23.86 10.1c3.68 1.55 7.95.1 9.99-3.35l16.86-29.35c1.84-3.5.94-7.95-2.29-10.4M256.01 298c-23.07 0-41.77-18.8-41.77-42s18.7-42 41.77-42 41.76 18.8 41.76 42-18.7 42-41.76 42" />',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"},passwordBoxIcon:{name:"password-box",content:'<path d="m167.1 238.55-5.65-5.65L144 250.35V224h-16v26.35l-17.45-17.45-5.65 5.65L122.35 256H96v16h26.35l-17.45 17.45 5.65 5.65L128 277.65V304h16v-26.35l17.45 17.45 5.65-5.65L149.65 272H176v-16h-26.35zm96 0-5.65-5.65L240 250.35V224h-16v26.35l-17.45-17.45-5.65 5.65L218.35 256H192v16h26.35l-17.45 17.45 5.65 5.65L224 277.65V304h16v-26.35l17.45 17.45 5.65-5.65L245.65 272H272v-16h-26.35zM32 160v192c13-.07 448 0 448 0V160zm416 160H64V192h384zm-32-112v96h-16v-96zm-56.9 29.55-5.65-5.65L336 249.35V223h-16v26.35l-17.45-17.45-5.65 5.65L314.35 255H288v16h26.35l-17.45 17.45 5.65 5.65L320 276.65V303h16v-26.35l17.45 17.45 5.65-5.65L341.65 271H368v-16h-26.35z" />',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"},patientOutlineIcon:{name:"patient-outline",content:'<path d="m218.46 113.31-.58.19c.08-.1.17-.2.26-.3zM256 256c-22.44 0-43.98 3.85-64 10.94-7.9 2.79-15.56 6.09-22.95 9.86a179 179 0 0 0-9.05 4.91c-.68.39-1.36.79-2.03 1.2C101.71 316.39 64 377.81 64 448c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32 0-106-86-192-192-192M140.14 384l-.12.66L128.85 448H96c0-42.72 16.65-82.89 46.88-113.12 2.31-2.31 4.68-4.54 7.1-6.68zm46.65-80.33c.79-.38 1.57-.75 2.37-1.11L203.52 384h-30.89zM168.94 448c-1.91.01-4.58.01-7.6.01l5.65-32.01h42.17l5.64 32zm72.9-31H336c8.27 0 15 6.73 15 15s-6.73 15-15 15h-88.88zm139.43 31c1.77-5 2.73-10.39 2.73-16 0-26.51-21.49-48-48-48h-99.98l-16.21-91.91c11.73-2.7 23.85-4.09 36.19-4.09 42.72 0 82.89 16.65 113.12 46.88S416 405.28 416 448zM315.04 52.31a94 94 0 0 0-7.51-5.31c-14.89-9.5-32.57-15-51.53-15-53 0-96 43-96 96s43 96 96 96 96-43 96-96c0-30.74-14.47-58.12-36.96-75.69M278.85 93.8l23.48-9.89a64 64 0 0 1 14.42 23.94l-40.4-13zM256 64c3.21 0 6.37.24 9.46.7l-61.29 25.82C215.8 74.46 234.7 64 256 64m0 128c-34.51 0-62.72-27.45-63.95-61.66l39.03-16.43L318.45 142c-6.4 28.58-31.97 50-62.45 50" />',viewBox:"0 0 512 512"},patientSolidIcon:{name:"patient-solid",content:'<path d="m225.34 81.6-63.35 26.86C171.02 64.82 209.7 32 256 32c18.96 0 36.64 5.5 51.53 15 .04.03.08.05.12.08zm5.74 32.31-69.72 30.2C169.01 189.45 208.49 224 256 224c44.66 0 82.23-30.54 92.94-71.86l-73.62-24zm45.27-19.06 75.26 24.53c-1.6-18.07-8.22-34.7-18.47-48.49L278.85 93.8zM203.52 384h-30.89l15.52-87.65zm0 0h-30.89l15.52-87.65zm-45.97-100.84L140.14 384l-.12.66L123.07 480H96c-17.7 0-32-14.3-32-32 0-1.22.01-2.43.04-3.64.01-.9.03-1.79.06-2.68.01-.14.01-.27.02-.4.03-1.03.07-2.06.13-3.09v-.07c.05-1.06.12-2.11.19-3.16v-.05c.06-.89.13-1.78.2-2.66.02-.31.05-.61.08-.92.08-.95.16-1.89.26-2.83 0-.04.01-.08.01-.12.11-1.02.22-2.05.34-3.07.12-1.01.24-2.01.38-3.02.01-.11.03-.23.04-.34.12-.82.23-1.63.35-2.45.04-.25.08-.49.11-.73.15-.98.31-1.96.48-2.93 0-.03 0-.06.01-.09.17-1.03.36-2.05.55-3.07.17-.96.36-1.93.55-2.88.38-1.85.78-3.69 1.21-5.52.12-.54.25-1.07.38-1.61q.315-1.32.66-2.64c.23-.9.47-1.8.71-2.69.18-.65.36-1.31.55-1.96.21-.73.42-1.47.64-2.2.22-.76.45-1.51.69-2.26.27-.87.54-1.74.83-2.61.28-.87.57-1.73.87-2.59.09-.27.18-.55.28-.82.29-.83.58-1.66.89-2.49.29-.8.58-1.59.89-2.39.14-.4.3-.8.46-1.2a147.335 147.335 0 0 1 2.04-5.07c.37-.88.74-1.75 1.12-2.62.46-1.05.93-2.09 1.41-3.13.41-.91.84-1.81 1.27-2.71.42-.87.84-1.74 1.26-2.6.03-.06.06-.12.09-.17.46-.92.93-1.84 1.4-2.75s.95-1.82 1.44-2.72c.48-.9.98-1.8 1.48-2.69.51-.92 1.03-1.83 1.56-2.74.43-.74.87-1.48 1.31-2.22.19-.31.38-.63.57-.94.92-1.52 1.87-3.02 2.83-4.51.05-.08.1-.17.16-.25.52-.81 1.05-1.61 1.59-2.41.57-.84 1.14-1.69 1.72-2.53.58-.83 1.16-1.65 1.75-2.48.01-.02.02-.04.04-.05 1.18-1.64 2.38-3.27 3.62-4.88 0-.02.02-.03.03-.05.61-.79 1.22-1.57 1.84-2.36.63-.78 1.26-1.57 1.89-2.35.19-.24.38-.47.58-.7 2.41-2.92 4.9-5.76 7.47-8.53a218 218 0 0 1 4.22-4.4c1.32-1.33 2.65-2.63 4-3.93.12-.11.24-.23.36-.34.74-.7 1.49-1.39 2.23-2.08 1.5-1.38 3.02-2.73 4.56-4.06.77-.66 1.55-1.32 2.33-1.97 2.34-1.96 4.73-3.86 7.17-5.71 2.44-1.84 4.92-3.63 7.44-5.36.85-.58 1.69-1.15 2.54-1.71 2.42-1.6 4.87-3.15 7.37-4.64M220.66 480H155.6l11.39-64h42.17zM448 448c0 17.7-14.3 32-32 32h-80c26.51 0 48-21.49 48-48s-21.49-48-48-48h-99.98l-22.05-123.38c1.04-.23 2.09-.46 3.14-.68q3.615-.735 7.29-1.35c.64-.11 1.28-.21 1.92-.31 8.12-1.26 16.42-2.01 24.85-2.22.78-.02 1.56-.03 2.35-.04.82-.01 1.65-.02 2.48-.02 106 0 192 86 192 192m-112-1h-88.98l-5.19-30H336c8.27 0 15 6.73 15 15s-6.73 15-15 15m-196.98-63v.66l.12-.66zm79.12-270.8c-.09.1-.18.2-.26.3l.58-.19z" />',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"},perimeterIcon:{name:"perimeter",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.27V384z" />',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"},pillsOutlineIcon:{name:"pills-outline",content:'<path d="M384 288c-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96-42.98-96-96-96m0 160c-29.77 0-54.85-20.42-61.97-48h123.94c-7.12 27.58-32.2 48-61.97 48m-61.97-80c7.12-27.58 32.2-48 61.97-48s54.85 20.42 61.97 48zm47.49-240.87c0-32.84-17.01-64.79-47.44-82.38C307.15 36.11 290.84 32 274.75 32c-32.79 0-64.67 17.04-82.24 47.53l-50.44 87.51-.07-.04-53 92 .05.03-44.33 76.92C18.53 381.4 34.08 439.51 79.45 465.74c14.94 8.64 31.25 12.75 47.34 12.75 32.78 0 64.65-17.04 82.22-47.52l43.84-76.06.15.09 54-94 49.8-86.45c8.63-14.97 12.72-31.3 12.72-47.42M247 301l-65.72 113.99c-11.19 19.43-32.07 31.5-54.49 31.5-10.93 0-21.76-2.92-31.32-8.45-30.05-17.37-40.37-56-23.02-86.11l44.32-76.92 22.12-36.82M154 210l66.23-114.49C231.44 76.08 252.33 64 274.75 64c10.93 0 21.75 2.92 31.32 8.46 19.4 11.21 31.45 32.16 31.45 54.67 0 10.99-2.92 21.86-8.44 31.44L263 273z" />',viewBox:"0 0 512 512"},pillsSolidIcon:{name:"pills-solid",content:'<path d="m110.52 221.78-65.8 114.17C18.53 381.4 34.08 439.51 79.45 465.74c45.36 26.25 103.37 10.68 129.56-34.77l65.8-114.17zM322.08 44.75C276.72 18.5 218.71 34.08 192.51 79.53l-66.02 114.53 164.3 95.03 66.01-114.54c8.63-14.97 12.72-31.3 12.72-47.42 0-32.84-17.01-64.79-47.44-82.38m62.24 243.08c-48.08 0-88.33 34.02-96.02 80H480c-7.69-45.98-47.6-80-95.68-80M288.3 399.84c7.71 46.06 47.68 80.16 95.85 80.16s88.14-34.1 95.85-80.16z" />',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"},planIcon:{name:"plan",content:'<path d="M160 128c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 .1V160l160-.1V128zM160 240c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 .1V272l160-.1V240zM160 352c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 .1V384l160-.1V352zm0-112V272l160-.1V240zm0-112V160l160-.1V128zm-48-.1c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 0c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0-112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0-112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 .1V160l160-.1V128zm0 112V272l160-.1V240zm0 112V384l160-.1V352zm0 31.9 160-.1V352l-160 .1zm0-112 160-.1V240l-160 .1zm0-143.9V160l160-.1V128zm-48-.1c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16M400 32H112c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h288c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m0 416H112V64h288zm-32-96-160 .1V384l160-.1zm0-112-160 .1V272l160-.1zm0-112-160 .1V160l160-.1zm-208 32c8.84 0 16-7.16 16-16s-7.16-16-16-16-16 7.16-16 16 7.16 16 16 16m0 112c8.84 0 16-7.16 16-16s-7.16-16-16-16-16 7.16-16 16 7.16 16 16 16m0 112c8.84 0 16-7.16 16-16s-7.16-16-16-16-16 7.16-16 16 7.16 16 16 16m0-32c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0-112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0-112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 .1V160l160-.1V128zm0 112V272l160-.1V240zm0 112V384l160-.1V352zm0 0V384l160-.1V352zm0-112V272l160-.1V240zm0-112V160l160-.1V128zm-48-.1c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m0 112c-8.84 0-16 7.16-16 16s7.16 16 16 16 16-7.16 16-16-7.16-16-16-16m48 .1V384l160-.1V352z" />',viewBox:"0 0 512 512"},planeOutlineIcon:{name:"plane-outline",content:'<path d="m236.95 64 .08.05L333.01 240h99c4.28 0 8.29 1.66 11.32 4.7 1.82 1.82 4.84 5.76 4.67 11.8-.23 8.11-8.25 15.5-16.81 15.5h-98.18l-95.98 175.96-.07.05h-27.25l80-176H152.65l-43.61 79.96-.07.05H81.65l43.5-96-43.5-96h27.29l.08.05 43.61 79.95h137.09l-80-176zm.02-31.98h-76.95l80 176h-68.4l-34.51-63.27a32.09 32.09 0 0 0-28.17-16.73H32l58 128-58 128h76.95c11.74 0 22.55-6.42 28.17-16.73l34.51-63.27H240l-80 176h76.95c11.74 0 22.55-6.42 28.17-16.73L352 304.02h79.18c25.65 0 48.06-20.94 48.8-46.58.4-13.82-5.04-26.37-14.04-35.36-8.68-8.69-20.68-14.06-33.94-14.06h-80L265.12 48.75a32.06 32.06 0 0 0-28.15-16.73" />',viewBox:"0 0 512 512"},planeSolidIcon:{name:"plane-solid",content:'<path d="m171.63 304-34.51 63.27A32.09 32.09 0 0 1 108.95 384H32l58-128-58-128h76.92c11.74 0 22.55 6.42 28.17 16.73L171.6 208H240L160 32h76.95c11.74 0 22.55 6.42 28.17 16.73L352 208h80c13.26 0 25.26 5.37 33.94 14.06 9 8.99 14.44 21.54 14.04 35.36-.74 25.64-23.15 46.58-48.8 46.58H352l-86.88 159.27A32.09 32.09 0 0 1 236.95 480H160l80-176z" />',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"},questionSolidIcon:{name:"question-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 32m32 384h-64v-64h64zm23.4-143c-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 96c0 45.2-23.4 65.9-40.6 81" />',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"},rectangleShapeIcon:{name:"rectangle-shape",content:'<path d="M448 128v256H64V128zm32-32H32v320h448z" />',viewBox:"0 0 512 512"},recycleOutlineIcon:{name:"recycle-outline",content:'<path d="m146.517 329.47 25.84-45.02 41.67 23.94c-14.13-25.43-26.83-50.87-58.45-107.33-11.67.21-121.12 3.29-122.1 3.57l41.63 23.93-39.75 69.32c-6.88 10.51-5.21 21.13 2.28 32.22 0 0 12.6 16.99 27.66 36.6 7.52 9.79 15.65 20.22 23.12 29.53l19.96 23.4c.55.42 1.11.84 1.68 1.25 4.2 3.05 8.75 5.72 13.47 7.72 5.12 2.18 10.67 3.19 16.22 3.17l73.45-.3-.34-101.98zm-48.77 52.82c-3.93-4.94-8.23-10.43-12.9-16.43-2.21-2.85-4.51-5.82-6.87-8.89a3069 3069 0 0 1-27.27-36.07c-5.69-8.58-3.55-11.86-1.97-14.27l.27-.39.23-.42 47.67-83.15-6.71-3.85c21.22-.62 43.34-1.23 56.1-1.55 11.17 20.03 19.8 35.91 27 49.29l-6.85-3.96zm37.75 33.51c-10.62-2.49-21.46-11.15-27.73-18.82l29.57-51.52h59.56l.24 70.1zm-27.12 3.83c.49.44 1.06.85 1.68 1.25-.57-.41-1.13-.83-1.68-1.25m-19.96-23.4c7.62 9.46 14.55 17.73 19.49 22.95.15.15.31.3.47.45zm390.14-105.83c-.67-5.52-2.54-10.82-5.34-15.63l-36.86-63.46-88.349 51.12 33.039 57.46-51.949.06.019-48.01c-15.03 24.91-30.79 48.59-64.04 104.11 6 9.99 63.22 103.24 63.94 103.95l.04-47.97 79.97-.13c12.55.72 20.93-6.02 26.83-18.03 0 0 8.471-19.38 17.991-42.19 4.75-11.39 9.75-23.63 14.109-34.74L478.318 308c.09-.7.17-1.39.25-2.08.549-5.16.599-10.43-.011-15.52m-35.19 64.76c-1.37 3.33-2.799 6.8-4.299 10.37-8.66 20.77-16.541 38.9-17.731 41.6-4.609 9.2-8.519 8.98-11.399 8.81l-.471-.03h-.48l-95.93.16v7.74c-11.109-18.07-22.65-36.93-29.29-47.81a3672 3672 0 0 1 29.32-47.95v7.91l129.06-.15h9.051c-2.32 5.85-4.951 12.32-7.831 19.35m15.59-35.36-59.449.07-29.681-51.59 60.73-35.13 30.921 53.26c3.12 10.43 1.009 24.14-2.521 33.39m19.361-11.8c.14-.65.209-1.35.25-2.08-.08.69-.16 1.38-.25 2.08m-10.361 28.94c4.41-11.31 8.13-21.45 10.201-28.33.059-.2.11-.4.16-.61zm-112.37-213.08-30.85-73.69c-4.17-11.85-13.62-16.99-26.99-17.81 0 0-21.16-.36-45.91-.36-12.35 0-25.59.09-37.53.35l-30.73 1.57q-1.005.27-2.01.57c-4.99 1.47-9.87 3.45-14.34 5.97-4.85 2.73-9.02 6.51-12.39 10.93l-44.48 58.38 81.21 61.82 40.41-52.57 20.03 47.89-44.38 18.44c28.8 4.29 56.751 9.71 120.84 19.02 6.93-9.37 71.12-97.98 71.49-98.92zm-167.01 25.36-55.82-42.48 37.33-49c8.44-6.89 21.92-10.22 31.84-10.52l22.92 54.8zm132.64 37.94c-22.709-3.35-40.59-6.17-55.59-8.61l7.31-3.03-53.22-127.29c6.31-.11 13.29-.18 20.9-.22 3.61-.02 7.36-.03 11.24-.03 22.52 0 42.32.3 45.25.35 10.28.71 11.59 4.41 12.54 7.12l.15.45.19.44 37.021 88.4 7.15-2.98c-12.441 17.19-25.43 35.09-32.941 45.4M183.577 33.92q-1.005.27-2.01.57c.69-.25 1.37-.45 2.01-.57m.62-.09c-.21.02-.41.05-.62.09l30.73-1.57c-12.15.28-22.96.74-30.11 1.48" />',viewBox:"0 0 512 512"},recycleSolidIcon:{name:"recycle-solid",content:'<path d="m213.04 315.69-41.41-24-72.65 126.57c-3.21 5.25-3.67 9.15-1.12 13.88l-60.38-94.82c-7.46-11.1-7.09-25.15-.19-35.66l37.82-65.91-41.52-24.06c.98-.26 109.88-3.56 121.57-3.48 31.5 56.46 43.8 82.05 57.88 107.48m-44.68 14.36-45.47 78.1c-6.53 10.66 1.16 23.98 13.62 23.98h79.61V330.05zm87.48 45.98c5.8 10.21 63.33 103.25 64.04 103.97v-48.11h76.07c12.57.75 24.93-5.95 30.79-17.97l53.24-100.87c-2.82 4.58-7.85 7.17-14.01 7h-146.1v-47.99c-14.95 24.93-30.95 48.4-64.03 103.97m102.27-72.07 90.47-.04c12.51.27 20.1-13.11 13.78-23.9l-40.42-68.96-88.08 51.52zm-21.43-103.33c6.31-9.9 61.69-104.24 61.99-105.21l-42.56 22.52-35.62-67.15c-5.21-11.45-16.92-19.23-30.3-18.78l-114.15.21c5.37.34 10.02 3.57 12.75 9.09l68.39 128.98-42.45 22.46c29.05 1.53 57.3 4.69 121.95 7.88m-111.62-56.56-42.38-79.85c-5.62-11.17-21-11.61-27.59-.97l-42.08 67.96 86.81 53.64z" />',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"},replaceFreeTextIcon:{name:"replace-free-text",content:'<path d="M336.04 448H125.27c-6.59 18.64-24.37 32-45.27 32-26.51 0-48-21.49-48-48 0-20.9 13.36-38.68 32-45.27V128H32V32h96v32h258.73c6.59-18.64 24.37-32 45.27-32 26.51 0 48 21.49 48 48 0 20.9-13.36 38.68-32 45.27v130.44h-32V125.27c-13.64-4.82-24.45-15.63-29.27-29.27H128v32H96v258.73c13.64 4.82 24.45 15.63 29.27 29.27h210.77zM416 80c0 8.82 7.18 16 16 16s16-7.18 16-16-7.18-16-16-16-16 7.18-16 16M64 96h32V64H64zm32 336c0-8.82-7.18-16-16-16s-16 7.18-16 16 7.18 16 16 16 16-7.18 16-16m185.6-48V179.2h76.8V128H153.6l.64 51.2h76.16V384zM400 320v96h32v-32l48 48-48 48v-32h-32c-17.65 0-32-14.35-32-32v-96c0-17.65 14.35-32 32-32h80v32z" />',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"},rowCollapseIcon:{name:"row-collapse",content:'<path d="M256 416v-64h64l-80-128-80 128h64v64zM32 224h32v96H32zm384 0h32v96h-32zM32 0v160h416V0zm128 128H64V32h96zm128 0h-96V32h96zm128 0h-96V32h96zM64 448h64v32H64zm-32-64h32v96H32zm160 64h96v32h-96zm224-64h32v96h-32zm-64 64h64v32h-64z" />',viewBox:"0 0 512 512"},rowExpandIcon:{name:"row-expand",content:'<path d="M32 0h416v480H32zm384 448V160H64v288zM320 32v96h96V32zm-32 0h-96v96h96zM64 32v96h96V32zm192 192v64h64l-80 128-80-128h64v-64" />',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"},rulerOutlineAltIcon:{name:"ruler-outline-alt",content:'<path d="M443.298 136.759 375.24 68.702A16.03 16.03 0 0 0 363.891 64a16 16 0 0 0-11.34 4.702L68.702 352.551c-6.266 6.267-6.266 16.423 0 22.69l68.057 68.057a16.03 16.03 0 0 0 11.35 4.702 16 16 0 0 0 11.34-4.702l283.849-283.849c6.266-6.267 6.266-16.423 0-22.69m-295.189 272.51-45.378-45.378 22.719-22.719 22.689 22.689 11.36-11.36-22.679-22.689 22.729-22.729 22.689 22.679 11.359-11.36-22.679-22.689 22.73-22.729 22.689 22.679 11.359-11.359-22.689-22.689 22.739-22.73 22.679 22.69 11.37-11.37-22.689-22.689 22.729-22.729 22.689 22.689 11.37-11.37-22.689-22.689 22.729-22.729 22.689 22.689 11.37-11.37-22.689-22.679 22.017-22.027 22.689 22.689 11.37-11.37-22.69-22.679 23.201-23.21 45.378 45.378z" />',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"},rulerSolidAltIcon:{name:"ruler-solid-alt",content:'<path d="m352.545 68.7-34.543 34.543 22.691 22.691-11.37 11.371-22.692-22.691-22.019 22.019 22.691 22.691-11.36 11.361-22.692-22.691-22.731 22.731 22.691 22.691-11.37 11.371-22.691-22.691-22.732 22.731 22.691 22.691-11.36 11.361-22.691-22.691-22.732 22.731 22.692 22.691-11.371 11.371-22.691-22.691-22.731 22.731 22.691 22.691-11.361 11.361-22.691-22.691-22.731 22.731 22.691 22.691-11.371 11.371-22.691-22.692L68.7 352.545c-6.267 6.267-6.267 16.424 0 22.691l68.064 68.064c6.267 6.267 16.424 6.267 22.691 0L443.3 159.455c6.267-6.267 6.267-16.424 0-22.691L375.236 68.7c-6.267-6.267-16.424-6.267-22.691 0" />',viewBox:"0 0 512 512"},rulerSolidIcon:{name:"ruler-solid",content:'<path d="M448.37 192h-48.72v32h-16.04v-32h-31.06v32h-16.03v-32h-32.06v32h-16.04v-32h-32.06v32h-16.03v-32h-32.06v32h-16.04v-32h-32.06v32h-16.03v-32h-32.06v32H96.04v-32H48c-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-16" />',viewBox:"0 0 512 512"},rulerTriangleOutlineIcon:{name:"ruler-triangle-outline",content:'<path d="M112 210.4V399h190.9zm32 76.6 81 80h-81zm-32-76.6V399h190.9zm32 76.6 81 80h-81zm-32-76.6V399h190.9zm32 76.6 81 80h-81zm-32-76.6V399h190.9zm32 76.6 81 80h-81zm-32-76.6V399h190.9zm32 76.6 81 80h-81zM32 31v448h448zm304 400v16h-32v-16h-16v16h-32v-16h-16v16h-32v-16h-16v16h-32v-16h-16v16h-32v-16H96v16H64v-32h16v-16H64v-32h16v-16H64v-32h16v-16H64v-32h16v-16H64v-32h16v-16H64v-32h16v-16H64v-50.8L402.8 447H352v-16zm-224-32h190.9L112 210.4zm32-112 81 80h-81zm-32-76.6V399h190.9zm32 76.6 81 80h-81z" />',viewBox:"0 0 512 512"},rulerTriangleSolidIcon:{name:"ruler-triangle-solid",content:'<path d="M480 479 32 31v80h32v16H32v32h32v16H32v32h32v16H32v32h32v16H32v32h32v16H32v32h32v16H32v32h32v16H32v64h64v-32h16v32h32v-32h16v32h32v-32h16v32h32v-32h16v32h32v-32h16v32h32v-32h16v32h32v-32h16v32zm-368-80V210.42L302.94 399z" />',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"},scaleIcon:{name:"scale",content:'<path d="m224 128 57.4 57.4L128 338.7l45.3 45.3 153.3-153.4L384 288V128zm32 256v64H64V256h64v-32H32v256h256v-96zM160 32v160h32V64h256v256H320v32h160V32z" />',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"},securityCheckOutlineIcon:{name:"security-check-outline",content:'<path d="M345.35 175.89 368 197.64 224 335.89l-80-76.81 22.65-21.75L224 292.44l121.35-116.56ZM256.48 67.8l159.46 79.95v.13l.06.03v44.15c0 47.99-1.48 101.73-12.46 136.53-1.11 3.52-2.07 6.78-3 9.93-1.82 6.17-3.53 11.99-5.09 15.08-11.07 21.87-33.95 43.17-66.16 61.6-28.61 16.37-57.29 26.48-71.88 31.05-.43.14-.91.29-1.41.44-.52-.16-1-.31-1.45-.45-14.55-4.57-43.23-14.67-71.85-31.04-32.21-18.43-55.08-39.73-66.16-61.6-1.56-3.09-3.28-8.91-5.09-15.08-.93-3.15-1.89-6.41-3-9.93-10.98-34.79-12.46-88.54-12.46-136.56v-44.15l.06-.03v-.1l.48-.25 158.98-79.71.48.24zm0-35.8-.5.25-.5-.25-191.42 95.99-.06.06v64.01c0 58.06 2.42 109.65 13.94 146.16 3.67 11.64 6.07 21.95 10.06 29.83 32.84 64.86 125.01 98.69 156.97 108.72 6.54 2.06 10.56 3.11 11.03 3.24.47-.13 4.49-1.18 11.03-3.24 31.96-10.03 124.13-43.86 156.97-108.72 3.99-7.88 6.39-18.19 10.06-29.83 11.52-36.51 13.94-88.1 13.94-146.16v-64.01l-.06-.03L256.49 32ZM64.5 128.01l-.06-.02.06-.02z" />',viewBox:"0 0 512 512"},securityCheckSolidIcon:{name:"security-check-solid",content:'<path d="M447.94 128.01 256.5 32l-.5.25-.5-.25-191.44 95.98-.06.06v64.01c0 58.05 2.42 109.65 13.94 146.15 3.67 11.65 6.07 21.96 10.06 29.84 32.84 64.86 125.01 98.69 156.97 108.72 6.54 2.06 10.56 3.11 11.03 3.24.47-.13 4.49-1.18 11.03-3.24C298.99 466.73 391.16 432.9 424 368.04c3.99-7.88 6.39-18.19 10.06-29.84C445.58 301.7 448 250.1 448 192.05v-64.01zm-383.4-.02-.08-.01.06-.02zM224 339.33l-80-80 22.65-22.66L224 294.08l121.35-121.41L368 195.33z" />',viewBox:"0 0 512 512"},securityLockOutlineIcon:{name:"security-lock-outline",content:'<path d="M320 240h-16v-48c0-26.5-21.5-48-48-48s-48 21.5-48 48v48h-16c-8.8 0-16 7.2-16 16v96c0 8.8 7.2 16 16 16h128c8.8 0 16-7.2 16-16v-96c0-8.8-7.2-16-16-16m-96-48c0-17.65 14.35-32 32-32s32 14.35 32 32v48h-64zm16 112c0-8.85 7.15-16 16-16s16 7.15 16 16-7.15 16-16 16-16-7.15-16-16m16.48-236.21 159.46 79.95v.13l.06.03v44.15c0 47.99-1.48 101.73-12.46 136.53-1.11 3.52-2.07 6.78-3 9.93-1.82 6.17-3.53 11.99-5.09 15.08-11.07 21.87-33.95 43.17-66.16 61.6-28.61 16.37-57.29 26.48-71.88 31.05-.43.14-.91.29-1.41.44-.52-.16-1-.31-1.45-.45-14.55-4.57-43.23-14.67-71.85-31.04-32.21-18.43-55.08-39.73-66.16-61.6-1.56-3.09-3.28-8.91-5.09-15.08-.93-3.15-1.89-6.41-3-9.93-10.98-34.79-12.46-88.54-12.46-136.56v-44.15l.06-.03v-.1l.48-.25 158.98-79.71.48.24zm.01-35.8-.5.25-.5-.25-191.43 95.99-.06.06v64.01c0 58.06 2.42 109.65 13.94 146.16 3.67 11.64 6.07 21.95 10.06 29.83 32.84 64.86 125.01 98.69 156.97 108.72 6.54 2.06 10.56 3.11 11.03 3.24.47-.13 4.49-1.18 11.03-3.24C298.99 466.73 391.16 432.9 424 368.04c3.99-7.88 6.39-18.19 10.06-29.83C445.58 301.7 448 250.11 448 192.05v-64.01l-.06-.03zM64.51 128l-.06-.02.06-.02z" />',viewBox:"0 0 512 512"},securityLockSolidIcon:{name:"security-lock-solid",content:'<path d="m281.64 172.87-.04-.04.06.08zm4.94 9.67-.02-.04c.03.1.06.21.1.32-.03-.09-.05-.19-.08-.28m.37 1.3v-.05l-.04-.12c-.04-.13-.07-.25-.11-.38l-.03-.09c.08.27.15.54.22.81zm.06.21-.02-.04c.02.06.03.12.05.18zm.05.19-.02-.05c.03.11.05.22.08.32zm.28 1.24c-.05-.24-.1-.47-.16-.7.06.26.12.52.17.78v-.08Zm.24 1.28c-.01-.08-.02-.16-.04-.24l-.04-.18c.05.27.09.53.13.79 0-.13-.03-.25-.05-.37M256 288c-8.85 0-16 7.15-16 16s7.15 16 16 16 16-7.15 16-16-7.15-16-16-16m31.63-100.87c-.04-.26-.08-.52-.13-.79l-.15-.78c-.05-.26-.11-.52-.17-.78-.05-.19-.09-.39-.14-.59-.02-.06-.03-.12-.05-.18-.07-.27-.14-.54-.22-.81-.04-.13-.07-.26-.11-.38-.04-.11-.07-.22-.1-.32a31.8 31.8 0 0 0-4.92-9.63C275.8 165.06 266.48 160 256 160c-17.65 0-32 14.35-32 32v48h64v-48c0-1.65-.13-3.28-.37-4.87m0 0c-.04-.26-.08-.52-.13-.79l-.15-.78c-.05-.26-.11-.52-.17-.78-.05-.19-.09-.39-.14-.59-.02-.06-.03-.12-.05-.18-.07-.27-.14-.54-.22-.81-.04-.13-.07-.26-.11-.38-.04-.11-.07-.22-.1-.32a31.8 31.8 0 0 0-4.92-9.63C275.8 165.06 266.48 160 256 160c-17.65 0-32 14.35-32 32v48h64v-48c0-1.65-.13-3.28-.37-4.87M256 288c-8.85 0-16 7.15-16 16s7.15 16 16 16 16-7.15 16-16-7.15-16-16-16m191.94-159.98v-.04L256.5 32l-.5.25-.5-.25-191.44 95.99-.06.06v64c0 58.05 2.42 109.65 13.94 146.15 3.67 11.65 6.07 21.96 10.06 29.84 32.84 64.86 125.01 98.69 156.97 108.72 6.54 2.06 10.56 3.11 11.03 3.24.47-.13 4.49-1.18 11.03-3.24C298.99 466.73 391.16 432.9 424 368.04c3.99-7.88 6.39-18.19 10.06-29.84C445.58 301.7 448 250.1 448 192.05v-64.03zm-383.42-.01-.06-.02.06-.02zM336 352c0 8.8-7.2 16-16 16H192c-8.8 0-16-7.2-16-16v-96c0-8.8 7.2-16 16-16h16v-48c0-26.5 21.5-48 48-48s48 21.5 48 48v48h16c8.8 0 16 7.2 16 16zm-48.5-165.66-.15-.78c-.05-.26-.11-.52-.17-.78-.05-.19-.09-.39-.14-.59-.02-.06-.03-.12-.05-.18-.07-.27-.14-.54-.22-.81-.04-.13-.07-.26-.11-.38-.04-.11-.07-.22-.1-.32a31.8 31.8 0 0 0-4.92-9.63C275.8 165.06 266.48 160 256 160c-17.65 0-32 14.35-32 32v48h64v-48c0-1.65-.13-3.28-.37-4.87-.04-.26-.08-.52-.13-.79M256 288c-8.85 0-16 7.15-16 16s7.15 16 16 16 16-7.15 16-16-7.15-16-16-16" />',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"},smsOutlineIcon:{name:"sms-outline",content:'<path d="M64 32h384c17.6 0 32 14.4 32 32v288c0 17.6-14.4 32-32 32H128l-96 96V64c0-17.6 14.4-32 32-32m383.94 320 .06-.06V64.06l-.06-.06H64.06l-.06.06v338.69L114.74 352zM144 176c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32m112 0c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32m112 0c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32" />',viewBox:"0 0 512 512"},smsSolidIcon:{name:"sms-solid",content:'<path d="M64 32h384c17.6 0 32 14.4 32 32v288c0 17.6-14.4 32-32 32H128l-96 96V64c0-17.6 14.4-32 32-32m80 144c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32m112 0c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32m112 0c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32" />',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"},speedIcon:{name:"speed",content:'<path d="M190.65 190.94 255.92 304h-.13l.11.18.06-.11.04-.07c5.81.02 11.25 1.6 15.94 4.33a32.1 32.1 0 0 1 9.81 8.85l1.9 2.93a31.8 31.8 0 0 1 4.22 15.89v.08c-.01 4.6-.99 8.97-2.75 12.92-4.96 11.16-16.13 18.95-29.12 19h-.13c-5.8 0-11.25-1.55-15.94-4.25a32.35 32.35 0 0 1-9.96-8.95c-.63-.86-1.21-1.76-1.75-2.68a31.83 31.83 0 0 1-4.35-16.04V336c0-4.64.99-9.05 2.77-13.03.44-1 .93-1.96 1.47-2.9.02-.04.05-.08.07-.12l-68.25-118.22s-.07.03-.1.05c-40.71 18.45-75.08 51.31-93.81 92.66-6.93 14.84-11.93 30.67-14.87 46.97-1.58 8.75-2.57 17.64-2.94 26.59H32.06c-.18-8.3.06-16.42.7-24.36q0-.15.03-.3c6.82-84.15 57.84-147.23 124.3-178.15.12-.05.23-.11.35-.16 55.22-25.58 121.04-28.97 181.01-3.83l-24.41 42.27c-21.92-10.71-46.01-17.02-70.63-17.82-17.84-.98-35.62.9-52.76 5.29m215.34 14c-12.37-11.44-25.43-21.17-38.95-29.27l-25.58 44.3c11.81 8.59 22.58 18.58 31.97 29.75l48.79-28.17a217 217 0 0 0-16.23-16.61m-14.27 71.17a162 162 0 0 1 11.63 25.65c.31.84.6 1.68.89 2.53l62.5-6.57a236.2 236.2 0 0 0-24.99-50.49zM480 367.99c-.38-13.12-1.93-26.17-4.56-39l-63.62 6.69c1.54 10.71 2.06 21.54 1.56 32.31zM255.79 304l.11.18.06-.11.04-.07zm25.96 13.18 1.9 2.93c-.58-1.01-1.21-1.99-1.9-2.93M157.44 165.03c-.12.05-.23.11-.35.16l-.02-.4zm98.52 139.04-.06.11-.11-.18h.13z" />',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"},sustainabilityIcon:{name:"sustainability",content:'<path d="M384.01 109.46 332.14 32l-12.69 26.08a211.4 211.4 0 0 0-34.7-7.31l-.44-.06c-1.46-.18-2.95-.35-4.43-.5h-.08c-7.14-.72-14.39-1.09-21.73-1.09-116.02 0-210.06 92.64-210.06 206.93 0 51.41 19.03 98.45 50.54 134.63l22.91-22.57c-26.63-31.41-41.14-70.63-41.14-112.06 0-46.77 18.49-90.74 52.06-123.81 12.32-12.13 26.14-22.28 41.04-30.25 25.68-13.74 54.6-21.03 84.64-21.03 11.62 0 23.07 1.09 34.23 3.23 4.02 1.62 8 3.39 11.9 5.23l-13.98 28.71 93.79-8.67Zm29.45 11.87-22.91 22.57c26.63 31.41 41.14 70.64 41.14 112.06 0 46.77-18.49 90.74-52.06 123.81-12.32 12.14-26.15 22.29-41.04 30.25-25.68 13.74-54.59 21.03-84.64 21.03-11.62 0-23.08-1.09-34.23-3.23-4.02-1.62-8-3.39-11.9-5.23l13.98-28.71-93.77 8.65 22.43 33.56 29.42 43.92 12.69-26.08a211.4 211.4 0 0 0 34.7 7.31l.44.06c1.46.18 2.95.35 4.43.5h.08c7.14.73 14.39 1.09 21.73 1.09 116.02 0 210.06-92.64 210.06-206.93 0-51.41-19.04-98.45-50.54-134.63ZM256 319.55c-.1-.03-.21-.05-.32-.08l.51.65.59-.77c-.27.07-.53.14-.78.2m52.58-150.96c-20.54-26.17-40.84-45.1-41.69-45.9L256 112.59l-10.89 10.1c-.85.8-21.15 19.73-41.69 45.9-28.81 36.69-43.42 68.78-43.42 95.36 0 20.08 8.38 48.61 48.31 70.49 11.65 6.38 23.25 10.64 31.69 13.25v35.73c0 8.84 7.16 16 16 16s16-7.16 16-16v-35.73c8.44-2.61 20.04-6.87 31.69-13.25 39.93-21.88 48.31-50.41 48.31-70.49 0-26.58-14.61-58.67-43.42-95.36M240 313.86c-19.87-7.53-48-22.96-48-49.91 0-6.56 1.49-13.66 4.08-21.02L240 298.91zm0-66.85-27.91-35.58c8.39-13.13 18.39-25.93 27.91-37zm16.19 72.53-.51-.65c.11.03.22.05.32.08.25-.06.51-.13.78-.2zM272 174.5c3.7 4.29 7.56 8.93 11.42 13.84 5.94 7.57 11.19 14.88 15.73 21.88L272 245.89zm0 139.37v-15.1l43.46-57.1c3.01 8.22 4.54 15.68 4.54 22.28 0 26.95-28.15 42.39-48 49.92m-15.22 5.49-.59.77-.51-.65c.11.03.22.05.32.08.25-.06.51-.13.78-.2" />',viewBox:"0 0 512 512"},sweeperVehicleIcon:{name:"sweeper-vehicle",content:'<path d="m479.16 190.31-28.95-57.89a7.99 7.99 0 0 0-7.15-4.42H328c-4.42 0-8 3.58-8 8v32c0-4.42-3.58-8-8-8H40c-4.42 0-8 3.58-8 8v176c0 4.42 3.58 8 8 8h10.73c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h37.46c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h13.54L272 384h96l-10.81-32h13.54c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32H472c4.42 0 8-3.58 8-8V193.89c0-1.24-.29-2.47-.84-3.58M111.87 338.09c-.91 7.12-6.66 12.87-13.78 13.78-10.45 1.33-19.29-7.51-17.96-17.96.91-7.12 6.66-12.87 13.78-13.78 10.45-1.33 19.29 7.51 17.96 17.96m128 0c-.91 7.12-6.66 12.87-13.78 13.78-10.45 1.33-19.29-7.51-17.96-17.96.91-7.12 6.66-12.87 13.78-13.78 10.45-1.33 19.29 7.51 17.96 17.96m192 0c-.91 7.12-6.66 12.87-13.78 13.78-10.45 1.33-19.29-7.51-17.96-17.96.91-7.12 6.66-12.87 13.78-13.78 10.45-1.33 19.29 7.51 17.96 17.96M384 192v-32h48l16 32z" />',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"},tabletOutlineIcon:{name:"tablet-outline",content:'<path d="M384 32H128c-13.56 0-25.24 8.56-29.88 20.56C96.76 56.1 96 59.96 96 64v384c0 4.02.76 7.88 2.12 11.44 4.64 12 16.32 20.56 29.88 20.56h256c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m0 416H128v-64h256zm0-96H128V64h256zm-112 64c0 8.84-7.16 16-16 16s-16-7.16-16-16 7.16-16 16-16c1.4 0 2.74.18 4.04.52C266.92 402.3 272 408.56 272 416" />',viewBox:"0 0 512 512"},tabletSolidIcon:{name:"tablet-solid",content:'<path d="M384 32H128c-13.56 0-25.24 8.56-29.88 20.56C96.76 56.1 96 59.96 96 64v384c0 4.02.76 7.88 2.12 11.44 4.64 12 16.32 20.56 29.88 20.56h256c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32M256 432c-8.84 0-16-7.16-16-16s7.16-16 16-16c1.4 0 2.74.18 4.04.52C266.92 402.3 272 408.56 272 416c0 8.84-7.16 16-16 16m128-80H128V64h256z" />',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"},therapistOutlineIcon:{name:"therapist-outline",content:'<path d="M443.04 52.31a94 94 0 0 0-7.51-5.31c-14.89-9.5-32.57-15-51.53-15-53 0-96 43-96 96s43 96 96 96 96-43 96-96c0-30.74-14.47-58.12-36.96-75.69M406.85 93.8l23.48-9.89a64 64 0 0 1 14.42 23.94l-40.4-13zM384 64c3.21 0 6.37.24 9.46.7l-61.29 25.82C343.8 74.46 362.7 64 384 64m-37.54 49.31-.58.19c.08-.1.17-.2.26-.3zM384 192c-34.51 0-62.72-27.45-63.95-61.66l39.03-16.43L446.45 142c-6.4 28.58-31.97 50-62.45 50m0 64c-22.44 0-43.98 3.85-64 10.94-7.9 2.79-15.56 6.09-22.95 9.86a179 179 0 0 0-9.05 4.91c-.68.39-1.36.79-2.03 1.2-56.23 33.46-93.93 94.84-93.97 164.99 0 17.71 14.29 32.1 32 32.1h208c26.51 0 48-21.49 48-48V281.71C451.76 265.36 418.97 256 384 256M268.14 384l-.12.66L256.85 448H224c0-42.72 16.65-82.89 46.88-113.12 2.31-2.31 4.68-4.54 7.1-6.68zm46.65-80.33c.79-.38 1.57-.75 2.37-1.11L331.52 384h-30.89zM296.94 448c-1.91.01-4.58.01-7.6.01l5.65-32.01h42.17l5.64 32zm50.87-155.91c11.73-2.7 23.85-4.09 36.19-4.09 22.39 0 44.08 4.57 64 13.28v85.45c-5-1.77-10.39-2.73-16-2.73h-67.98zM433 447h-57.88l-5.28-30H433c8.27 0 15 6.73 15 15s-6.73 15-15 15M128.77 288c13.55 0 26.98 1.7 39.92 5.05 3.14.81 6.28 1.73 9.38 2.73l-.54.7-.27.53c-.68.9-1.24 1.69-1.64 2.27-.43.61-.86 1.22-1.28 1.83l-.09.12-.34.5c-.29.41-.57.83-.85 1.25-.18.27-.36.54-.55.8l-.15.22-.15.23-.13.2-.29.43c-.69 1.02-1.35 2.02-2 3.03-.19.29-.38.59-.58.89l-.08.13c-1.19 1.85-2.28 3.61-3.45 5.52-.08.12-.15.25-.23.38l-.06.09-.15.25-.14.23-.09.15-.11.18-.13.21-.12.21-.32.54c-.42.72-.85 1.44-1.26 2.15a284 284 0 0 0-4.03 7.18c-.62 1.15-1.27 2.37-1.98 3.74l-.08.14-.32.62c-.37.72-.74 1.45-1.11 2.18-.06.12-.12.24-.18.35l-.21.4-.3.63-.06.12c-.36.74-.72 1.49-1.08 2.24l-.02.05-.21.42-.17.37-.41.86c-.39.82-.8 1.69-1.23 2.62l-.06.12-.07.16c-.59 1.31-1.15 2.54-1.67 3.73-.48 1.09-.96 2.22-1.47 3.44-.42.98-.85 2.03-1.31 3.17l-.47.94-.48 1.46c-.14.37-.29.73-.43 1.1-.25.62-.51 1.3-.79 2.06-.36.94-.71 1.88-1.04 2.82-.37 1-.74 2.01-1.12 3.14-.18.5-.39 1.09-.6 1.75-.41 1.18-.75 2.21-1.06 3.18-.44 1.33-.81 2.5-1.06 3.32-.29.92-.64 2.02-.98 3.22-.17.54-.33 1.09-.48 1.63l-.14.49-.09.3-.08.3-.03.12c-.19.68-.39 1.37-.58 2.05l-.11.38-.13.48c-.29 1.09-.58 2.19-.87 3.29-.29 1.12-.59 2.32-.89 3.61v.05l-.03.07c-.17.7-.33 1.39-.49 2.1-.45 1.92-.9 3.96-1.45 6.57v.05l-.05.22-.03.12-.26 1.27-.02.18c-.2 1-.37 1.91-.52 2.79-.23 1.18-.44 2.38-.64 3.51-.07.39-.15.88-.24 1.44-.16.93-.31 1.89-.46 2.86l-.03.21-.07.39-.07.36-.12.95-.05.35c-.03.25-.07.49-.1.74l-.02.16-.06.37-.07.52-.12.87-.08.59-.04.42c-.13 1.01-.25 1.97-.36 2.95v.09l-.02.09-.05.4c-.11.97-.22 1.92-.32 2.87l-.02.21v.09l-.02.09-.18 1.71-.18 1.67v.42c0 .07 0 .15-.02.22-.05.52-.1 1.05-.14 1.59v.16l-.02.16-.06.8c-.06.79-.12 1.58-.17 2.37l-.07 1.06-.07 1.04v.07q-.06 1.005-.12 2.07l-.02.38v.34c-.05.84-.09 1.69-.12 2.56v.1l-.03.6-.02.54c-.05 1.29-.07 2.51-.09 3.64-.03 1.41-.05 2.97-.05 4.9v.66H63.92V301.77c1.93-.86 3.87-1.68 5.83-2.46 1.93-.77 3.88-1.51 5.83-2.2 17.02-6.04 34.92-9.11 53.19-9.11m0-32c-22.39 0-43.88 3.85-63.85 10.94-2.34.83-4.68 1.71-6.98 2.63-5.79 2.31-11.44 4.89-16.93 7.73q-4.065 2.1-8.01 4.41c-.34.19-.67.39-1 .59V480h137.45a63.7 63.7 0 0 1-8.96-32.66c0-1.54 0-2.93.04-4.22.02-1.05.04-2.12.08-3.18l.02-.6v-.14c.04-1.04.08-1.99.13-2.9v-.35c.06-.95.11-1.86.17-2.71v-.07l.07-1.08c.06-.96.14-1.92.21-2.87.04-.48.08-.96.13-1.44.04-.55.09-1.07.14-1.61V426l.18-1.71.03-.27c.11-1.03.23-2.08.35-3.14.12-1.01.24-2 .38-3.06l.03-.3.12-.87c.06-.35.11-.71.16-1.06.06-.46.13-.92.19-1.39l.04-.21.03-.21v-.09l.08-.42c.15-.99.31-1.98.47-2.93.04-.29.09-.58.14-.86.2-1.15.39-2.23.58-3.2.22-1.24.45-2.42.65-3.42l.02-.08v-.08c.47-2.21.91-4.25 1.38-6.24.13-.57.26-1.13.4-1.7l.06-.24c.24-1.04.51-2.1.78-3.15.26-1.01.53-2.02.8-3.03l.06-.2.09-.32c.18-.67.37-1.34.56-2l.09-.33c.2-.68.39-1.36.6-2.03.26-.92.55-1.84.86-2.82.27-.88.58-1.87.94-2.95.3-.95.63-1.92.98-2.92.13-.42.28-.84.43-1.25.29-.85.62-1.79 1.01-2.82.26-.74.57-1.59.92-2.5.24-.65.46-1.22.64-1.65.24-.65.5-1.29.75-1.94l.02-.06.03-.06c.56-1.41 1.08-2.68 1.59-3.87.41-.99.83-1.98 1.28-3 .5-1.14 1.03-2.31 1.6-3.57.54-1.18 1.06-2.26 1.51-3.22l.03-.06.03-.05c.44-.92.88-1.83 1.32-2.74l.14-.26c.08-.16.17-.35.28-.56.46-.92.93-1.83 1.39-2.73.59-1.14 1.15-2.2 1.7-3.21.63-1.17 1.24-2.27 1.72-3.12.57-1.03 1.17-2.09 1.83-3.22.48-.83.98-1.67 1.47-2.5l.22-.36.17-.28c.12-.19.23-.38.35-.57.91-1.5 1.89-3.08 3.08-4.94.18-.28.35-.55.53-.82.55-.85 1.13-1.73 1.77-2.68l.03-.04.48-.72c.47-.68.93-1.37 1.4-2.05l.06-.08.05-.07c.49-.71.99-1.42 1.49-2.13.37-.53.74-1.06 1.14-1.57.58-.81 1.14-1.57 1.69-2.31l.09-.18 1.93-2.5c.66-.85 1.32-1.7 1.99-2.56l.14-.17.14-.18.87-1.08c.32-.39.63-.78.94-1.17.36-.45.72-.89 1.09-1.32 2.69-3.26 5.54-6.52 8.46-9.67l.05-.05c.79-.85 1.6-1.7 2.4-2.55.81-.84 1.62-1.68 2.42-2.5l.07-.07c1.37-1.38 2.79-2.79 4.51-4.44l.27-.26.05-.05c-1.8-1.14-3.62-2.23-5.46-3.3q-4.74-2.775-9.66-5.25a174 174 0 0 0-6.31-3.03c-5.2-2.4-10.53-4.57-15.96-6.49a190 190 0 0 0-15.96-4.88c-15.3-3.96-31.36-6.06-47.89-6.06ZM128 64c27.08 0 51.33 17.15 60.36 42.7A63.7 63.7 0 0 1 192 128c0 14.14-4.52 27.53-13.07 38.74-8.3 10.88-20.05 18.96-33.09 22.74-5.75 1.67-11.76 2.52-17.85 2.52s-12.1-.85-17.86-2.52c-13.03-3.78-24.78-11.86-33.08-22.74-8.55-11.21-13.07-24.6-13.07-38.74 0-7.33 1.22-14.49 3.65-21.33C76.65 81.15 100.91 64 127.98 64Zm0-32c-41.78 0-77.34 26.72-90.52 64-3.55 10.01-5.48 20.78-5.48 32 0 43.71 29.25 80.61 69.22 92.21 8.5 2.47 17.48 3.79 26.78 3.79s18.28-1.32 26.78-3.79C194.76 208.61 224 171.71 224 128c0-11.22-1.93-21.99-5.48-32-13.18-37.28-48.74-64-90.52-64" />',viewBox:"0 0 512 512"},therapistSolidIcon:{name:"therapist-solid",content:'<path d="M224.51 281.7c-3.2-1.9-6.4-3.6-9.7-5.2-2.1-1-4.2-2.1-6.3-3-5.2-2.4-10.5-4.6-15.99-6.5-5.2-1.9-10.5-3.5-15.99-4.9-15.29-4-31.39-6.1-47.88-6.1-22.39 0-43.88 3.9-63.77 10.9-8.2 2.9-16.19 6.4-23.89 10.4-2.7 1.4-5.4 2.9-8 4.4-.3.2-.7.4-1 .6V480h137.44c-5.9-9.9-9-21.2-9-32.7v-4.2c0-1 0-2.1.1-3.2v-.7c0-1 .1-2 .1-2.9v-.4c.1-1 .1-1.9.2-2.7v-.1l.1-1.1c.1-1 .1-1.9.2-2.9 0-.5.1-1 .1-1.4 0-.5.1-1.1.1-1.6v-.1l.2-1.7v-.3c.1-1 .2-2.1.3-3.1s.2-2 .4-3.1v-.3l.1-.9c.1-.4.1-.7.2-1.1.1-.5.1-.9.2-1.4v-.5l.1-.4c.1-1 .3-2 .5-2.9 0-.3.1-.6.1-.9.2-1.1.4-2.2.6-3.2.2-1.2.4-2.4.6-3.4v-.2c.5-2.2.9-4.2 1.4-6.2.1-.6.3-1.1.4-1.7l.1-.2c.2-1 .5-2.1.8-3.1s.5-2 .8-3l.1-.2.1-.3c.2-.7.4-1.3.6-2l.1-.3c.2-.7.4-1.4.6-2 .3-.9.5-1.8.9-2.8q.45-1.35.9-3c.3-1 .6-1.9 1-2.9.1-.4.3-.8.4-1.2.3-.9.6-1.8 1-2.8.3-.7.6-1.6.9-2.5.2-.6.5-1.2.6-1.6.2-.6.5-1.3.7-1.9v-.2c.6-1.4 1.1-2.7 1.6-3.9.4-1 .8-2 1.3-3 .5-1.1 1-2.3 1.6-3.6.5-1.2 1.1-2.3 1.5-3.2v-.1c.4-.9.9-1.8 1.3-2.7l.1-.3.3-.6c.5-.9.9-1.8 1.4-2.7.6-1.1 1.1-2.2 1.7-3.2.6-1.2 1.2-2.3 1.7-3.1.6-1 1.2-2.1 1.8-3.2.5-.8 1-1.7 1.5-2.5l.2-.4.2-.3.3-.6c.9-1.5 1.9-3.1 3.1-4.9.2-.3.3-.5.5-.8.5-.9 1.1-1.7 1.8-2.7l.5-.7c.5-.7.9-1.4 1.4-2l.1-.1v-.1l1.5-2.1c.4-.5.7-1.1 1.1-1.6.6-.8 1.1-1.6 1.7-2.3l.1-.2 1.9-2.5c.7-.9 1.3-1.7 2-2.6l.1-.2.1-.2.9-1.1.9-1.2c.4-.5.7-.9 1.1-1.3 2.7-3.3 5.5-6.5 8.5-9.7.8-.9 1.6-1.7 2.4-2.5s1.6-1.7 2.4-2.5l.1-.1c1.4-1.4 2.8-2.8 4.5-4.4l.3-.3c-1.3-1.3-3.1-2.4-5-3.5Zm-6-185.7c-13.19-37.3-48.68-64-90.46-64S50.78 58.7 37.59 96c-3.5 10-5.5 20.8-5.5 32 0 43.7 29.19 80.6 69.17 92.2 8.5 2.5 17.49 3.8 26.79 3.8s18.29-1.3 26.79-3.8c39.98-11.6 69.17-48.5 69.17-92.2 0-11.2-1.9-22-5.5-32m229.4 319.7h-78.07l11.1 64h66.97c17.69 0 31.99-14.3 31.99-32s-14.29-32-31.99-32M384.04 256h-4.9c-8.4.2-16.69 1-24.89 2.2-.6.1-1.3.2-1.9.3-2.5.4-4.9.9-7.3 1.4-1.1.2-2.1.5-3.1.7L364.04 384H464c5.6 0 10.9 1 15.89 2.7v-105c-28.19-16.4-60.97-25.7-95.86-25.7Zm-46.88 160h-42.18l-11.39 64h65.07l-11.49-64Zm-58.97-128.2c-.9.6-1.7 1.1-2.5 1.7-2.5 1.7-5 3.5-7.4 5.4l-7.2 5.7c-.8.6-1.6 1.3-2.3 2-1.5 1.3-3.1 2.7-4.6 4.1-.7.7-1.5 1.4-2.2 2.1-.1.1-.2.2-.4.3-1.4 1.3-2.7 2.6-4 3.9-1.4 1.4-2.8 2.9-4.2 4.4-2.6 2.8-5.1 5.6-7.5 8.5-.2.2-.4.5-.6.7-.6.8-1.3 1.6-1.9 2.4l-1.8 2.4c-1.2 1.6-2.4 3.2-3.6 4.9-.6.8-1.2 1.6-1.8 2.5-.6.8-1.2 1.7-1.7 2.5s-1.1 1.6-1.6 2.4c-.1.1-.1.2-.2.2-1 1.5-1.9 3-2.8 4.5l-.6.9c-.4.7-.9 1.5-1.3 2.2-.5.9-1.1 1.8-1.6 2.7l-1.5 2.7c-.5.9-1 1.8-1.4 2.7s-.9 1.8-1.4 2.8c0 0-.1.1-.1.2-.4.9-.8 1.7-1.3 2.6-.4.9-.9 1.8-1.3 2.7-.5 1-1 2.1-1.4 3.1-.4.9-.8 1.7-1.1 2.6-.7 1.7-1.4 3.4-2 5.1-.2.4-.3.8-.5 1.2l-.9 2.4c-.3.8-.6 1.7-.9 2.5-.1.3-.2.5-.3.8-.3.9-.6 1.7-.9 2.6s-.6 1.7-.8 2.6c-.2.8-.5 1.5-.7 2.3-.2.7-.4 1.5-.6 2.2-.2.6-.4 1.3-.6 2-.2.9-.5 1.8-.7 2.7s-.5 1.8-.7 2.6c-.1.5-.3 1.1-.4 1.6-.4 1.8-.8 3.7-1.2 5.5-.2 1-.4 1.9-.6 2.9s-.4 2-.6 3.1v.1c-.2 1-.3 2-.5 2.9 0 .2-.1.5-.1.7-.1.8-.2 1.6-.4 2.5v.3c-.1 1-.3 2-.4 3s-.2 2-.3 3.1v.1c-.1.9-.2 1.9-.3 2.8 0 .3-.1.6-.1.9-.1.9-.1 1.8-.2 2.7-.1 1-.1 2.1-.2 3.2v.1c-.1 1-.1 2.1-.1 3.1v.4c0 .9-.1 1.8-.1 2.7v3.8c0 17.6 14.39 31.9 31.99 31.9h27.09l16.99-95.3.1-.7 17.39-100.8c-2.3 1.4-4.8 3-7.2 4.6Zm-11.2 96.9v-.7h.1zm49.18-88.4L300.68 384h30.89l-15.39-87.7Zm0 0L300.68 384h30.89l-15.39-87.7ZM461.31 70.9l-54.78 22.9-2.5 1.1L480 119.4c-1.7-18.1-8.4-34.7-18.69-48.5m-58.37 57.2-44.58-14.2-70.37 30.2c7.7 45.3 47.58 79.9 95.46 79.9 45.08 0 82.96-30.5 93.76-71.9zm32.59-81C420.54 37.5 402.64 32 383.45 32c-46.68 0-85.76 32.8-94.86 76.5l63.87-26.9c.1 0 83.06-34.5 83.06-34.5Z" />',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"},transactionsIcon:{name:"transactions",content:'<path d="M160 95.3h64V128h-64v64L32 112l128-80zM480 400l-128-80v64h-64v32.7h64V480zM308.75 276.85c2.15 4.8 3.25 10.3 3.25 16.55s-1.1 11.75-3.25 16.65-5.25 9.15-9.3 12.7q-6.075 5.325-14.7 8.55c-5.75 2.1-12.15 3.5-19.2 4.15 0 0-.6.05-1.55.15V368h-16v-32.5c-.15-.05-.25-.05-.25-.05q-9.225-.75-17.85-3.75c-5.75-2-10.85-4.9-15.3-8.65s-8-8.55-10.65-14.35-3.95-12.75-3.95-20.85h22.2c0 6.05 1 11.05 3 15.05s4.65 7.15 7.9 9.5 6.9 4 10.85 4.9q2.025.45 4.05.75V262.6c-4.55-1.45-8.8-3.1-12.7-4.85-6.05-2.75-11.2-5.95-15.45-9.65s-7.5-7.95-9.75-12.8-3.35-10.4-3.35-16.75c0-5.9 1-11.3 3-16.15 2-4.9 4.85-9.1 8.6-12.7s8.25-6.5 13.55-8.75c4.8-2.05 10.15-3.45 16.1-4.2V144h16v32.2c2.8.2 5.3.4 5.3.4 13.45 1.65 23.95 6.65 31.45 15.05S312 211.5 312 226.1h-22.15c0-4.75-.6-9.1-1.9-13.1q-1.875-6-5.7-10.35c-2.55-2.95-5.65-5.2-9.4-6.85-2.35-1-5.6-1.7-8.85-2.1v53.8c7.5 2.15 14.2 4.55 20.1 7.25 6 2.75 11.05 5.9 15.2 9.55 4.15 3.6 7.3 7.8 9.45 12.55m-60.8-35V194.4c-.28.08-.55.15-.83.22-.62.16-1.23.32-1.82.53-3.7 1.2-6.75 2.9-9.15 5.05-2.4 2.2-4.2 4.8-5.4 7.85-1.2 3.1-1.8 6.45-1.8 10.15 0 3.45.6 6.5 1.7 9.25 1.1 2.7 3 5.25 5.65 7.5s6.2 4.4 10.6 6.45c.35.2.75.35 1.05.45m39.5 62.15c1.55-3.05 2.3-6.55 2.3-10.4q0-4.8-1.8-8.85c-1.2-2.7-3.15-5.2-5.85-7.55-2.65-2.35-6.15-4.5-10.45-6.5a97 97 0 0 0-7.65-3.1v50.55c2.2-.3 4.3-.7 6.25-1.25 4.2-1.15 7.7-2.85 10.6-5 2.85-2.2 5.1-4.8 6.6-7.9" />',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"},truckIcon:{name:"truck",content:'<path d="m479.16 254.31-28.95-57.89a7.99 7.99 0 0 0-7.15-4.42H360c-4.42 0-8 3.58-8 8v120h-32V136c0-4.42-3.58-8-8-8H40c-4.42 0-8 3.58-8 8v208c0 4.42 3.58 8 8 8h10.73c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h37.46c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32h101.46c6.59 18.64 24.37 32 45.27 32s38.68-13.36 45.27-32H472c4.42 0 8-3.58 8-8v-86.11c0-1.24-.29-2.47-.84-3.58M80 336c0-8.82 7.18-16 16-16s16 7.18 16 16-7.18 16-16 16-16-7.18-16-16m144 16c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m192 0c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m-32-96v-32h48l16 32z" />',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"},upgradeOutlineIcon:{name:"upgrade-outline",content:'<path d="M256 64c51.29 0 99.5 19.97 135.76 56.24C428.02 156.5 448 204.72 448 256s-19.97 99.5-56.24 135.76C355.5 428.02 307.28 448 256 448s-99.5-19.97-135.76-56.24C83.98 355.5 64 307.28 64 256s19.97-99.5 56.24-135.76C156.5 83.98 204.72 64 256 64m0-32C132.29 32 32 132.29 32 256s100.29 224 224 224 224-100.29 224-224S379.71 32 256 32m-32 320h64v-96h96L256 96 128 256h96zm64 32h-64v32h64z" />',viewBox:"0 0 512 512"},upgradeReloadIcon:{name:"upgrade-reload",content:'<path d="m332.13 32-12.69 26.12c-11.2-3.37-22.79-5.84-34.7-7.33l-.44-.06c-1.46-.18-2.95-.35-4.43-.5h-.08c-7.14-.73-14.39-1.1-21.73-1.1-116.01 0-210.05 92.81-210.05 207.31 0 51.51 19.04 98.63 50.54 134.88l22.91-22.62c-26.63-31.47-41.14-70.77-41.14-112.27 0-46.85 18.49-90.91 52.06-124.04 12.32-12.16 26.15-22.33 41.04-30.31 25.68-13.76 54.59-21.07 84.64-21.07 11.62 0 23.08 1.1 34.23 3.24 4.02 1.62 8 3.4 11.9 5.24l-13.98 28.76 93.77-8.66zM224 320h64v-48h80L256 128 144 272h80zm64 32h-64v32h64zM179.81 479.46l12.69-26.12c11.2 3.37 22.79 5.84 34.7 7.33l.44.06c1.46.18 2.95.35 4.43.5h.08c7.14.73 14.39 1.1 21.73 1.1 116.01 0 210.05-92.81 210.05-207.31 0-51.51-19.04-98.63-50.54-134.88l-22.91 22.62c26.63 31.47 41.14 70.77 41.14 112.27 0 46.85-18.49 90.91-52.06 124.04-12.32 12.16-26.15 22.33-41.04 30.31-25.68 13.76-54.59 21.07-84.64 21.07a181.6 181.6 0 0 1-34.23-3.24c-4.02-1.62-8-3.4-11.9-5.24l13.98-28.76-93.77 8.66z" />',viewBox:"0 0 512 512"},upgradeSolidIcon:{name:"upgrade-solid",content:'<path d="M256 32C132.29 32 32 132.29 32 256s100.29 224 224 224 224-100.29 224-224S379.71 32 256 32m32 384h-64v-32h64zm0-160v96h-64v-96h-96L256 96l128 160z" />',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"},usersOutlineIcon:{name:"users-outline",content:'<path d="M397.72 226.28c22.72 0 41.14-18.42 41.14-41.14S420.44 144 397.72 144s-41.14 18.42-41.14 41.14 18.42 41.14 41.14 41.14m0 13.72c-14.9 0-28.89 3.97-40.94 10.91 14.42 8.44 27.69 18.71 39.65 30.68 15.95 15.94 28.87 34.21 38.48 54.41h31.37c7.59 0 13.72-6.13 13.72-13.71 0-45.43-36.85-82.29-82.28-82.29m-283.44-13.72c22.72 0 41.14-18.42 41.14-41.14S137 144 114.28 144s-41.14 18.42-41.14 41.14 18.42 41.14 41.14 41.14m41.91 25.2c-12.28-7.29-26.62-11.48-41.91-11.48C68.86 240 32 276.86 32 322.29c0 7.58 6.13 13.71 13.72 13.71h33.3c9.62-20.2 22.54-38.47 38.48-54.41 11.7-11.7 24.66-21.78 38.69-30.11M257.04 96c27.72 0 50.28 22.56 50.28 50.29 0 11.11-3.55 21.63-10.26 30.43-6.52 8.55-15.75 14.9-26.02 17.88-4.5 1.31-9.2 1.97-14 1.97s-9.5-.66-14.03-1.98c-10.23-2.97-19.46-9.31-25.99-17.87-6.71-8.8-10.26-19.32-10.26-30.43 0-27.73 22.55-50.29 50.28-50.29m0-32c-45.42 0-82.28 36.86-82.28 82.29 0 37.46 25.07 69.09 59.33 79.03 7.28 2.12 14.98 3.25 22.95 3.25s15.67-1.13 22.95-3.25c34.26-9.94 59.33-41.57 59.33-79.03 0-45.43-36.85-82.29-82.28-82.29m0 224c20.96 0 41 4.75 59.56 14.11 22.46 11.33 41.2 28.75 54.17 50.36 11.53 19.2 17.96 41.08 18.73 63.53H124.57c.77-22.45 7.21-44.33 18.73-63.53a133.1 133.1 0 0 1 53.03-49.78c18.87-9.75 39.3-14.69 60.71-14.69m-.01-32c-27.17 0-52.8 6.59-75.39 18.26-27.24 14.08-50.05 35.54-65.78 61.74-14.84 24.72-23.38 53.65-23.38 84.57 0 15.17 12.26 27.43 27.43 27.43h274.24c15.17 0 27.43-12.26 27.43-27.43 0-30.92-8.54-59.85-23.38-84.57-16-26.65-39.32-48.4-67.19-62.46-22.25-11.22-47.37-17.54-73.98-17.54" />',viewBox:"0 0 512 512"},usersSolidIcon:{name:"users-solid",content:'<path d="M356.57 185.14c0-22.71 18.43-41.14 41.14-41.14s41.14 18.43 41.14 41.14-18.43 41.14-41.14 41.14-41.14-18.43-41.14-41.14M397.71 240c-14.9 0-28.89 3.97-40.95 10.91 14.42 8.44 27.69 18.71 39.66 30.68 15.95 15.94 28.87 34.21 38.49 54.41h31.37c7.59 0 13.72-6.13 13.72-13.71 0-45.43-36.86-82.29-82.29-82.29m-283.42-13.71c22.71 0 41.14-18.43 41.14-41.14s-18.43-41.14-41.14-41.14-41.14 18.43-41.14 41.14 18.43 41.14 41.14 41.14m41.92 25.19c-12.28-7.29-26.62-11.48-41.92-11.48C68.86 240 32 276.86 32 322.29c0 7.58 6.13 13.71 13.72 13.71h33.31c9.62-20.2 22.54-38.47 38.49-54.41 11.7-11.7 24.65-21.78 38.69-30.11M256.05 64c-45.43 0-82.29 36.86-82.29 82.29 0 37.46 25.07 69.09 59.34 79.03a82 82 0 0 0 22.95 3.25c7.97 0 15.67-1.13 22.95-3.25 34.27-9.94 59.34-41.57 59.34-79.03 0-45.43-36.86-82.29-82.29-82.29m141.19 272c-16-26.65-39.33-48.4-67.2-62.46-22.25-11.22-47.38-17.54-73.99-17.54s-52.81 6.59-75.4 18.26c-27.24 14.08-50.06 35.54-65.79 61.74-14.84 24.72-23.38 53.65-23.38 84.57 0 15.17 12.26 27.43 27.43 27.43h274.28c15.17 0 27.43-12.26 27.43-27.43 0-30.92-8.54-59.85-23.38-84.57" />',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"},vanIcon:{name:"van",content:'<path d="M144.01 336c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m240.55-14.6c-.73 8.15-7.6 14.55-15.93 14.55-8.83 0-16-7.17-16-16s6.52-15.33 14.78-15.95c.4-.03.81-.05 1.22-.05s.83.02 1.23.05c.84.07 1.67.2 2.47.39 7.05 1.67 12.3 8.02 12.3 15.56 0 .49-.02.97-.07 1.45M224 224v-48h5.02c7.36 0 15.27-.65 20.98 4l44 44zm253.08 47.41c-1.5-3.36-3.33-6.54-5.43-9.51-3.35-4.72-7.4-8.9-12-12.41-3.3-2.51-6.89-4.66-10.71-6.4l-8.09-2.97L333.29 222l-67.44-70.81a32 32 0 0 0-20.21-7.19H54c-13.25 0-22 9.75-22 23v145c0 13.25 10.75 24 24 24h42.74c6.59 18.64 24.37 32 45.27 32s38.69-13.36 45.28-32h134.08c6.61 18.62 24.38 31.95 45.26 31.95s38.53-13.25 45.19-31.78l.06-.17h49.82c.56 0 1.12-.03 1.67-.08 8.21-.84 14.63-7.78 14.63-16.22 0 0 .24-41.24-2.92-48.29" />',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"},walletOutlineIcon:{name:"wallet-outline",content:'<path d="M416 320c0 17.67-14.33 32-32 32s-32-14.33-32-32 14.33-32 32-32 32 14.33 32 32m64-128v256c0 17.68-14.33 32-32 32H64c-17.67 0-32-14.32-32-32V192c0-17.68 14.33-32 32-32h32V64h134.06l.08-.13L249 32l166.14 95.45L396 160h52c17.67 0 32 14.32 32 32m-269.94-31.81h147.81l11.56-20.03-110.86-64zM128 160h48l35.6-64H128zm320 256h-64c-52.8 0-96-43.2-96-96s43.2-96 96-96h64v-32H64v256h384zm0-160h-64c-16.99 0-33.03 6.69-45.17 18.83S320 303.01 320 320s6.69 33.03 18.83 45.17S367.01 384 384 384h64z" />',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"},weightScaleOutlineIcon:{name:"weight-scale-outline",content:'<path d="M448 96h-93.89c-1.37 1.54-3.95 4.38-5.88 6.47-.23.25-.45.49-.65.72-.33.39-.69.78-1.08 1.16-.29.31-.51.54-.62.65l-25.95 25.95C318.39 164.88 290.3 192 256 192c-15.18 0-29.14-5.32-40.13-14.2a47 47 0 0 1-5.75-4.92 48 48 0 0 1-7.03-8.93A63.53 63.53 0 0 1 192 128c0-11.65 3.13-22.58 8.59-32 10.28-17.74 28.82-30.1 50.32-31.79L278 37.12c.71-.71 1.44-1.4 2.19-2.05-7.73-2-15.83-3.07-24.19-3.07-41.8 0-77.36 26.71-90.53 64H64c-17.67 0-32 14.33-32 32v320c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32V128c0-17.67-14.33-32-32-32m0 352H64V128h96c0 53.02 42.98 96 96 96s96-42.98 96-96h96zM323.25 82.37l-36.56 36.56c.86 2.87 1.31 5.92 1.31 9.07 0 17.67-14.33 32-32 32-8.09 0-15.47-3-21.1-7.94a32.5 32.5 0 0 1-4.72-5.15A31.83 31.83 0 0 1 224 128c0-17.67 14.33-32 32-32 2.58 0 5.09.3 7.49.88l37.14-37.14c3.12-3.12 7.22-4.68 11.31-4.68s8.19 1.56 11.31 4.68c6.25 6.25 6.25 16.38 0 22.63" />',viewBox:"0 0 512 512"},weightScaleSolidIcon:{name:"weight-scale-solid",content:'<path d="M480 128v320c0 17.67-14.33 32-32 32H64c-17.67 0-32-14.33-32-32V128c0-17.67 14.33-32 32-32h101.47C178.64 58.71 214.2 32 256 32c8.36 0 16.46 1.07 24.19 3.07-.75.65-1.48 1.34-2.19 2.05l-27.09 27.09c-21.5 1.69-40.04 14.05-50.32 31.79a63.6 63.6 0 0 0-8.59 32c0 13.32 4.09 25.7 11.09 35.95 1.94 3.18 4.28 6.18 7.03 8.93 1.8 1.81 3.72 3.45 5.75 4.92 10.99 8.88 24.95 14.2 40.13 14.2 34.3 0 62.39-27.12 63.93-61.05L345.88 105c.11-.11.33-.34.62-.65.39-.38.75-.77 1.08-1.16.2-.23.42-.47.65-.72 1.93-2.09 4.51-4.93 5.88-6.47H448c17.67 0 32 14.33 32 32M323.25 82.37l-36.56 36.56c.86 2.87 1.31 5.92 1.31 9.07 0 17.67-14.33 32-32 32-8.09 0-15.47-3-21.1-7.94a32.5 32.5 0 0 1-4.72-5.15A31.83 31.83 0 0 1 224 128c0-17.67 14.33-32 32-32 2.58 0 5.09.3 7.49.88l37.14-37.14c3.12-3.12 7.22-4.68 11.31-4.68s8.19 1.56 11.31 4.68c6.25 6.25 6.25 16.38 0 22.63" />',viewBox:"0 0 512 512"},whatsappBoxIcon:{name:"whatsapp-box",content:'<path d="M374.09 137.91C342.54 106.37 300.61 89 256 89s-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09m-175.77 29.07c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02Zm175.77-29.07C342.54 106.37 300.61 89 256 89s-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09m-175.77 29.07c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02Zm175.77-29.07C342.54 106.37 300.61 89 256 89s-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09m-175.77 29.07c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02Zm175.77-29.07C342.54 106.37 300.61 89 256 89s-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09m-175.77 29.07c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02ZM448 32H64c-17.66 0-32 14.34-32 32v384c0 17.66 14.34 32 32 32h384c17.66 0 32-14.34 32-32V64c0-17.66-14.34-32-32-32M256 448c-34.31 0-66.51-9-94.39-24.76L64 448l26.38-94.81C73.62 324.68 64 291.47 64 256c0-106.04 85.96-192 192-192s192 85.96 192 192-85.96 192-192 192m0-359c-44.61 0-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09C342.54 106.37 300.61 89 256 89m-57.68 77.98c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02Zm175.77-29.07C342.54 106.37 300.61 89 256 89s-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09m-175.77 29.07c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02Zm175.77-29.07C342.54 106.37 300.61 89 256 89s-86.54 17.37-118.09 48.91C106.37 169.46 89 211.39 89 256c0 29.78 7.93 59.01 22.93 84.52l5.38 9.15-17.67 63.5 65.55-16.63 8.73 4.94C198.82 415.56 227.2 423 256 423c44.61 0 86.54-17.37 118.09-48.91C405.63 342.54 423 300.61 423 256s-17.37-86.54-48.91-118.09m-175.77 29.07c.06 0 .12 0 .18.01.15.01.3.01.45.02.38.02.77.04 1.16.09 2.83.34 5.82 1.64 8.7 8.04 4.21 9.36 13.39 32.75 14.56 35.11 1.18 2.37 1.97 5.14.39 8.29-1.56 3.15-2.34 5.12-4.71 7.88-2.36 2.77-4.97 6.17-7.09 8.29-2.37 2.35-4.83 4.91-2.08 9.65 2.76 4.72 12.24 20.21 26.28 32.74 18.06 16.12 33.26 21.12 37.99 23.48s7.49 1.97 10.24-1.19c2.76-3.16 11.8-13.81 14.95-18.53 2.42-3.62 4.82-4.02 7.75-3.31.13.04.26.07.39.1.05 0 .1.03.15.04.28.09.57.17.86.27.44.15.89.31 1.36.48.3.11.68.26 1.15.45.16.07.34.14.53.23.16.07.32.14.49.21.21.1.44.2.67.3.71.32 1.51.68 2.38 1.08h.01c.52.24 1.07.5 1.65.77.29.14.58.27.88.41 8.6 4.06 21.11 10.24 24.45 11.92 4.72 2.36 7.85 3.54 9.03 5.51 1.18 1.98 1.17 11.44-2.75 22.48s-23.16 21.69-31.81 22.48c-8.64.78-16.75 3.92-56.56-11.83-47.9-18.95-78.15-68.21-80.51-71.36-2.35-3.16-19.24-25.63-19.24-48.89s12.18-34.69 16.5-39.42c4.31-4.74 9.42-5.92 12.56-5.92l7.34.09 1.7.02Z" />',viewBox:"0 0 512 512"},whatsappIcon:{name:"whatsapp",content:'<path d="M260.65 345.28c46.56 18.38 56.03 14.72 66.13 13.81 10.12-.92 32.61-13.36 37.2-26.24 4.59-12.89 4.6-23.93 3.21-26.24-1.38-2.31-5.04-3.68-10.56-6.44s-32.61-16.12-37.67-17.96c-5.05-1.84-8.72-2.75-12.4 2.77-3.68 5.51-14.23 17.94-17.44 21.62s-6.43 4.15-11.95 1.39c-5.52-2.75-23.26-8.58-44.32-27.38-16.38-14.62-27.44-32.69-30.66-38.2-3.21-5.52-.34-8.51 2.42-11.26 2.47-2.48 5.52-6.44 8.28-9.67 2.76-3.22 3.67-5.51 5.5-9.2 1.84-3.67.92-6.9-.45-9.66s-12.08-30.05-16.99-40.96c-4.13-9.2-8.47-9.38-12.4-9.53l-10.56-.14c-3.68 0-9.65 1.39-14.69 6.91-5.05 5.52-19.29 18.87-19.29 46.02s19.75 53.38 22.5 57.06c2.76 3.68 38.12 61.18 94.14 83.3m106.54-38.67c1.39 2.31 1.38 13.35-3.21 26.24-4.59 12.88-27.08 25.32-37.2 26.24-10.1.91-19.57 4.57-66.13-13.81-56.02-22.12-91.38-79.62-94.14-83.3-2.75-3.68-22.5-29.91-22.5-57.06s14.24-40.5 19.29-46.02c5.04-5.52 11.01-6.91 14.69-6.91l10.56.14c3.93.15 8.27.33 12.4 9.53 4.91 10.91 15.62 38.2 16.99 40.96s2.29 5.99.45 9.66c-1.83 3.69-2.74 5.98-5.5 9.2-2.76 3.23-5.81 7.19-8.28 9.67-2.76 2.75-5.63 5.74-2.42 11.26 3.22 5.51 14.28 23.58 30.66 38.2 21.06 18.8 38.8 24.63 44.32 27.38 5.52 2.76 8.74 2.29 11.95-1.39s13.76-16.11 17.44-21.62c3.68-5.52 7.35-4.61 12.4-2.77 5.06 1.84 32.15 15.2 37.67 17.96s9.18 4.13 10.56 6.44m-106.54 38.67c-56.02-22.12-91.38-79.62-94.14-83.3-2.75-3.68-22.5-29.91-22.5-57.06s14.24-40.5 19.29-46.02c5.04-5.52 11.01-6.91 14.69-6.91l10.56.14c3.93.15 8.27.33 12.4 9.53 4.91 10.91 15.62 38.2 16.99 40.96s2.29 5.99.45 9.66c-1.83 3.69-2.74 5.98-5.5 9.2-2.76 3.23-5.81 7.19-8.28 9.67-2.76 2.75-5.63 5.74-2.42 11.26 3.22 5.51 14.28 23.58 30.66 38.2 21.06 18.8 38.8 24.63 44.32 27.38 5.52 2.76 8.74 2.29 11.95-1.39s13.76-16.11 17.44-21.62c3.68-5.52 7.35-4.61 12.4-2.77 5.06 1.84 32.15 15.2 37.67 17.96s9.18 4.13 10.56 6.44c1.39 2.31 1.38 13.35-3.21 26.24-4.59 12.88-27.08 25.32-37.2 26.24-10.1.91-19.57 4.57-66.13-13.81m106.54-38.67c1.39 2.31 1.38 13.35-3.21 26.24-4.59 12.88-27.08 25.32-37.2 26.24-10.1.91-19.57 4.57-66.13-13.81-56.02-22.12-91.38-79.62-94.14-83.3-2.75-3.68-22.5-29.91-22.5-57.06s14.24-40.5 19.29-46.02c5.04-5.52 11.01-6.91 14.69-6.91l10.56.14c3.93.15 8.27.33 12.4 9.53 4.91 10.91 15.62 38.2 16.99 40.96s2.29 5.99.45 9.66c-1.83 3.69-2.74 5.98-5.5 9.2-2.76 3.23-5.81 7.19-8.28 9.67-2.76 2.75-5.63 5.74-2.42 11.26 3.22 5.51 14.28 23.58 30.66 38.2 21.06 18.8 38.8 24.63 44.32 27.38 5.52 2.76 8.74 2.29 11.95-1.39s13.76-16.11 17.44-21.62c3.68-5.52 7.35-4.61 12.4-2.77 5.06 1.84 32.15 15.2 37.67 17.96s9.18 4.13 10.56 6.44m-3.46 26.17c-4.58 12.87-27.02 25.3-37.12 26.22-10.08.91-19.53 4.57-65.98-13.8-55.89-22.11-91.18-79.57-93.93-83.25-2.74-3.68-22.44-29.9-22.44-57.04s14.21-40.47 19.25-45.99c5.03-5.52 10.99-6.91 14.66-6.91l10.54.14c3.92.16 8.25.34 12.37 9.52 4.89 10.91 15.58 38.19 16.95 40.95s2.29 5.99.45 9.66c-1.82 3.68-2.73 5.98-5.48 9.19-2.75 3.23-5.79 7.19-8.26 9.67-2.75 2.74-5.62 5.73-2.42 11.25 3.22 5.51 14.25 23.57 30.59 38.19 21.01 18.79 38.71 24.62 44.22 27.37 5.51 2.76 8.71 2.3 11.92-1.39s13.73-16.1 17.4-21.61c3.67-5.52 7.33-4.61 12.37-2.77s32.07 15.19 37.58 17.95c5.51 2.75 9.17 4.13 10.54 6.43 1.38 2.31 1.37 13.34-3.21 26.22M256 64c51.28 0 99.5 19.97 135.76 56.24C428.02 156.5 448 204.72 448 256s-19.97 99.5-56.24 135.76C355.5 428.02 307.28 448 256 448c-33.11 0-65.74-8.56-94.37-24.74l-11.18-6.32-72.84 18.48 19.62-70.53-6.89-11.71c-17.25-29.33-26.36-62.93-26.36-97.17 0-51.28 19.97-99.5 56.24-135.76C156.48 83.99 204.72 64 256 64m-.02-31.99c-123.71 0-224 100.29-224 224 0 41.38 11.22 80.13 30.78 113.39L31.98 480.01l113.88-28.89c32.52 18.39 70.09 28.89 110.12 28.89 123.71 0 224-100.29 224-224s-100.29-224-224-224" />',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"},xLogoBoxIcon:{name:"x-logo-box",content:'<path d="M448 32H64c-17.66 0-32 14.34-32 32v384c0 17.66 14.34 32 32 32h384c17.66 0 32-14.34 32-32V64c0-17.66-14.34-32-32-32m0 416H312.04l-88.02-141L95.06 448H64.04l145.98-158L64 64h135.05l88.97 140L416 64h32L302.55 222.49zM270.45 226.89 185.08 96h-66.05l121.99 189 84.89 131h66.1L283.42 247.48z" />',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;var 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))}});var 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=Gu,t.ui.icon=n.renderIcon}(window.kendo.jQuery);kendo;window.kendo.jQuery,window.kendo.util=window.kendo.util||{},kendo.deepExtend(kendo.util,{LRUCache:ia,TextMetrics:da,measureText:ha,objectKey:aa,hashKey:sa,normalizeText:oa,encodeBase64:Bo}),function(e){window.kendo=window.kendo||{};let t=kendo.deepExtend({},Vh);kendo.deepExtend(kendo,{drawing:e.extend(!0,{},Wc,{Segment:cs,pdf:t}),pdf:t,geometry:hs}),kendo.drawing.exportPDF=function(e,t){let n=Oh(e,t);return kendo.convertPromiseToDeferred(n)},kendo.drawing.exportImage=function(e,t){let n=$c(e,t);return kendo.convertPromiseToDeferred(n)},kendo.drawing.exportSVG=function(e,t){let n=Uc(e,t);return kendo.convertPromiseToDeferred(n)},kendo.drawing.drawText=tu,kendo.drawing.Color=bo,kendo.dataviz.drawing=kendo.drawing,kendo.dataviz.geometry=hs}(window.kendo.jQuery),function(e){var t=".kendo";var n=window.kendo;var i=n.deepExtend;var r=n.drawing.util;var o=r.defined;var a=r.limitValue;var s=r.eventCoordinates;var l=n._outerWidth;var c=n._outerHeight;var d=`<div class="k-tooltip-button">${n.ui.icon(e('<a href="#" title="Close"></a>'),{icon:"x"})}</div>`;var h=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;var o=t.offset||0;var l=this.surface;var c=l._instance._elementOffset();var d=l.getSize();var h=l._instance._offset;var u=e.bbox();var p=n.width;var f=n.height;var m=0,g=0;if(u.origin.translate(c.left,c.top),h&&u.origin.translate(-h.x,-h.y),"cursor"==r&&i){var v=s(i);m=v.x-p/2,g=v.y-f-o}else"left"==r?(m=u.origin.x-p-o,g=u.center().y-f/2):"right"==r?(m=u.bottomRight().x+o,g=u.center().y-f/2):"bottom"==r?(m=u.center().x-p/2,g=u.bottomRight().y+o):(m=u.center().x-p/2,g=u.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;var 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"});const n=l(t);const 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;var 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;var t=e._current;t&&t.options.autoHide&&(e._timeout=setTimeout((function(){e.hide()}),t.options.hideDelay||0))}});n.drawing.SurfaceTooltip=h,n.dataviz.drawing.SurfaceTooltip=h}(window.kendo.jQuery),function(){var e=window.kendo;var t=e.drawing;var n=t.Surface;var i=e.ui.Widget;var 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;var n=t.drawing;n.drawDOM=function(n,i){"string"==typeof i?.template&&(i.template=t.template(i.template));let r=eu(e(n)[0],i);return t.convertPromiseToDeferred(r)},n.drawDOM.drawText=tu,n.drawDOM.getFontFaces=au}(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",h=".k-upload-button-wrap",u="aria-invalid",p=/^[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,f=["http:","https:","ftp:","ftps:"],m=":input:not(:button,[type=submit],[type=reset],[disabled],[readonly])",g=":checkbox:not([disabled],[readonly])",v="[type=number],[type=range]",_="blur",b="name",w="form",y="novalidate",k="validate",x="change",C="validateInput",S=function(e,t){return"string"==typeof t&&(t=new RegExp("^(?:"+t+")$")),t.test(e)},T=function(e,t){return!!e.length&&null!=e[0].attributes[t]};function M(e){return e.replace(/&/g,"&").replace(/"/g,'"').replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function A(t){return e.parseHTML?e(e.parseHTML(t)):e(t)}function D(n,i){var r,a=e();for(var 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 E(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 I=({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};var z=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||I),o.element.is(w)&&o.element.attr(y,y);const l=o.element.attr("id");o._shouldSearchDocument=o.element.is(w)&&null!=l&&e(`:input[form='${l}']`).length>0,o._containerElement=o._shouldSearchDocument?e(document):o.element,o._inputSelector=o._buildSelector(m,s),o._checkboxSelector=o._buildSelector(g,s),o._errors={},o._attachEvents(),o._isValidated=!1,o._validateOnInit()&&o.validate()},events:[k,x,C],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){let t=this._containerElement,n=!e.attr("name")&&!e.is(":checked"),i=e.attr("name"),r=i&&i.indexOf("'")>-1?'"':"'",o=e.attr("name")&&!t.find("input[name="+r+e.attr("name")+r+"]:checked").length,a=e.filter("[type=checkbox]").length&&(n||o),s=e.filter("[type=file]").parents(h).children("input").length,l=e.filter("[type=radio]").length&&!t.find("input[name="+r+e.attr("name")+r+"]:checked").length,c=e.val();if(s){let t=!1;return e.filter("[type=file]").parents(h).children("input").each((function(n){e.val()&&(t=!0)})),!(T(e,"required")&&!t)}return!(T(e,"required")&&(!c||""===c||0===c.length||a||l))},pattern:function(e){return!e.filter("[type=text],[type=email],[type=url],[type=tel],[type=search],[type=password]").filter("[pattern]").length||""===e.val()||S(e.val(),e.attr("pattern"))},min:function(e){return!e.filter(v+",["+t.attr("type")+"=number]").filter("[min]").length||""===e.val()||(parseFloat(e.attr("min"))||0)<=t.parseFloat(e.val())},max:function(e){return!e.filter(v+",["+t.attr("type")+"=number]").filter("[max]").length||""===e.val()||(parseFloat(e.attr("max"))||0)>=t.parseFloat(e.val())},step:function(e){if(e.filter(v+",["+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||S(i,n)}(e,"[type=email],["+t.attr("type")+"=email]",p)},url:function(e){if(e.filter("[type=url],["+t.attr("type")+"=url]").length&&""!==e.val())try{const t=new URL(e.val());return f.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},_buildSelector:function(e,t){if(!this._shouldSearchDocument)return e+t;const n=this.element.attr("id");return`#${n} `+e+t+`,[form="${n}"]`},_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(x)},_attachEvents:function(){const t=this,n=t._containerElement;t.element.is(w)&&t.element.on("submit"+i,t._submit.bind(t)),t.options.validateOnBlur&&(n.is(m)?(n.on(_+i,(function(){t._checkElement(t.element)})),n.is(g)&&n.on("click"+i,(function(){t._checkElement(t.element)}))):(n.on(_+i,t._inputSelector,(function(){t._checkElement(e(this))})),n.on("click"+i,t._checkboxSelector,(function(){t._checkElement(e(this))}))))},validate:function(){let t;let n;let i=!1;let r;let o=this._containerElement;let a=this.value();if(this._errors={},this.element.is(m))i=this.validateInput(this.element);else{let a=!1;for(t=o.find(this._inputSelector),o.find(h).each((function(){let n=e(e(this).parents(".k-upload")[0]),i=e(this).find("input:hidden[type='file']").first();i.length&&n.length&&!n.hasClass("k-disabled")&&Array.prototype.push.call(t,i[0])})),n=0,r=t.length;n<r;n++)this.validateInput(t.eq(n))||(a=!0);i=!a}return this.options.validationSummary&&!a&&this.showValidationSummary(),this.trigger(k,{valid:i,errors:this.errors()}),a!==i&&this.trigger(x),i},validateInput:function(n){if(n=e(n),!t.isEmpty(n.closest(".k-otp"))){let e=n.closest(".k-otp");n=e.find("input[data-role='otpinput']")}this._isValidated=!0;const i=this,o=i._errorTemplate,l=i._checkValidity(n),d=l.valid,h="."+r,p=n.attr(b)||"",f=i._findMessageContainer(p).add(n.next(h).filter((function(){let n=i._shouldSearchDocument?e(document):e(this);return!n.filter("["+t.attr("for")+"]").length||n.attr(t.attr("for"))===p}))).addClass("k-hidden"),m=d?"":i._extractMessage(n,l.key),g=d?"":A(o({message:M(m),field:p})),v=!n.attr(u),_=n.is(".k-input-inner"),w=n.parent(".k-input");let y;if(n.removeAttr(u),!n.hasClass("k-hidden")||"otpinput"!=n.attr("data-role")&&"upload"!=n.attr("data-role")||(y=t.widgetInstance(n)),n.hasClass("k-hidden")&&"signature"==n.attr("data-role")&&(y=t.widgetInstance(n.closest(".k-signature"))),n.is("[type=radio]")&&(y=t.widgetInstance(n.closest(".k-radio-list"))),n.is("[type=checkbox]")&&(y=t.widgetInstance(n.closest(".k-checkbox-list"))),d||n.data("captcha_validating"))delete i._errors[p];else{i._errors[p]=m;let e=f.attr("id");if(i._decorateMessageContainer(g,p),e&&g.attr("id",e),0!==f.length)f.replaceWith(g);else{y=y||t.widgetInstance(n);let e=n.parent().get(0);let i=n.next().get(0);let r=n.prev().get(0);!y&&n.is("[type=radio]")&&(y=t.widgetInstance(n.closest(".k-radio-list"))),!y&&n.is("[type=checkbox]")&&(y=t.widgetInstance(n.closest(".k-checkbox-list"))),y&&y.wrapper&&(y.element!==y.wrapper||["Signature","RadioGroup","CheckBoxGroup"].indexOf(y.options.name)>-1)?g.insertAfter(y.wrapper):e&&"LABEL"===e.nodeName?g.insertAfter(e):i&&E(i,n[0])?g.insertAfter(i):r&&E(r,n[0])?g.insertAfter(n):_&&w.length?g.insertAfter(w):g.insertAfter(n)}g.removeClass("k-hidden"),n.attr(u,!0)}if(v!==d&&this.trigger(C,{valid:d,input:n,error:m,field:p}),y=y&&"Signature"==y.options.name?y:t.widgetInstance(n),(!y||!y._inputWrapper&&!y.wrapper||n.is("[type=checkbox]")||n.is("[type=radio]"))&&(n.toggleClass(a,!d),n.toggleClass(s,d)),y){let e=y.options.name;let t=y._inputWrapper||y.wrapper;let r=y._inputLabel;"OTPInput"==e?d?(y._removeInvalidState.bind(i),y._removeInvalidState(t,!0)):(y._addInvalidState.bind(i),y._addInvalidState(t,!0)):!t||n.is("[type=checkbox]")||n.is("[type=radio]")||(t.toggleClass(a,!d),t.toggleClass(s,d)),r&&r.toggleClass(c,!d)}if(v!==d){let e=g?g.attr("id"):f.attr("id");i._associateMessageContainer(n,e),this.options.validationSummary&&this.options.validateOnBlur&&this.showValidationSummary()}return d},hideMessages:function(){const e="."+r,t=this._containerElement;this._disassociateMessageContainers(),t.is(m)?t.next(e).addClass("k-hidden"):t.find(e).addClass("k-hidden")},reset:function(){const e=this,t=e._containerElement,n=t.find("."+a),i=t.find("."+c);e._errors=[],e.hideMessages(),e.hideValidationSummary(),n.removeAttr(u),n.removeClass(a),i.removeClass(c)},_findMessageContainer:function(n){let i,r=t.ui.validator.messageLocators,o=e();for(let e=0,t=this.element.length;e<t;e++){let t=this._shouldSearchDocument?document:this.element[e];o=o.add(D(t.getElementsByTagName("*"),n))}for(i in r)o=o.add(r[i].locate(this._containerElement,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(b);t.ui.Validator.prototype.options.messages[n]||(i=t.isFunction(r)?r(e):r),r=t.isFunction(r)?r(e):r;const a=e.parent().closest("[name='"+o+"']");const s=a.length?a:e;return t.format(s.attr(t.attr(n+"-msg"))||s.attr("validationMessage")||i||r||s.attr("title")||"",o,s.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(){const t=this._containerElement.find(this._inputSelector);let n=[];let i=[];for(let r=0,o=t.length;r<o;r++){let o=e(t[r]);T(o,b)&&(-1===n.indexOf(o.attr(b))||0===o.closest(".k-checkbox-list").length&&0===o.closest(".k-radio-list").length)&&(o.parents(".k-checkbox-wrap").length?(i.push(o.attr(b)),n.push(o.attr(b))):i.includes(o.attr(b))||n.push(o.attr(b)))}return n},_associateMessageContainer:function(e,n){var i=t.getWidgetFocusableElement(e);i&&n&&t.toggleAttribute(i,"aria-describedby",n)},_disassociateMessageContainers:function(){var t,n,i=this,o=i.element.find("."+a).addBack();for(var s=0;s<o.length;s+=1)(t=e(o[s])).is("input")&&(n=i._findMessageContainer(t.attr(b)).add(t.next("."+r)).attr("id"),i._associateMessageContainer(t,n))},_errorsByName:function(){var e=this,t=e._getInputNames(),n=[];for(var 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=A(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(z)}(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,h="press",u="hold",p="select",f="start",m="move",g="end",v="cancel",_="tap",b="doubleTap",w="release",y="gesturechange",k="gestureend",x="gesturetap";var C={api:0,touch:0,mouse:9,pointer:9};var 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 M(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]}});var D=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(h,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(u,this.pressEvent)},move:function(e){var t=this;var 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(w,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){var n=t.eventMap.up.split(" "),i=0,r=n.length;for(;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 M=l.surface[0],A=l.preventIfMoving.bind(l);E((function(e){M.addEventListener(e,A,!0)}))}l.bind([h,u,_,b,f,m,g,w,v,"gesturestart",y,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=y;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(){var e=this.touches;for(;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=M(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 D(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=M(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})}});var 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,u,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(){var e=this.touches;for(;e.length>0;)e.pop().dispose()},_start:function(t){var n,i,r=this,o=0,a=r.filter,s=M(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 D(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=M(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=M,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,h=e.extend,u=n.getOffset,p={},f={},m={},g=n.elementUnderCursor,v="keyup",_="change",b="dragstart",w="hold",y="drag",k="dragend",x="dragcancel",C="hintDestroyed",S="dragenter",T="dragleave",M="drop";function A(e,t){return parseInt(e.css(t),10)||0}function D(e,t){return Math.min(Math.max(e,t.min),t.max)}function E(e,t){var i=u(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=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())}});var z=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))}});var P=l.extend({init:function(e){var t=this;l.fn.init.call(t),t.x=new z(h({horizontal:!0},e)),t.y=new z(h({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(_)}});var L=l.extend({init:function(e){h(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))}});var B=a.extend({init:function(t){var n,i,r,o,a=this;h(a,{elastic:!0},t),r=a.elastic?.5:0,o=a.movable,a.x=n=new L({axis:"x",dimension:a.dimensions.x,resistance:r,movable:o}),a.y=i=new L({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,h=a.dimensions.maxScale;o.scale<=d&&c<1&&(c+=.8*(1-c)),o.scale*c>=h&&(c=h/o.scale);var u=o.x+a.offset.left,p=o.y+a.offset.top;t={x:(u-s.x)*c+l.x-u,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()}})}});var H;H=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 R=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(H(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){h(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=H(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 F(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,M],options:{name:"DropTarget",group:"default"},destroy:function(){F(f,this)},_trigger:function(e,t){var n=p[this.options.group];if(n)return this.trigger(e,h({},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(M,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(){F(m,this)},options:{name:"DropTargetArea",group:"default",filter:null}});var 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&&!t.allowTouchActions&&i.element.find(i.options.filter).css("touch-action","none"),i._afterEndHandler=i._afterEnd.bind(i),i._captureEscape=i._captureEscape.bind(i)},events:[w,b,y,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,allowTouchActions:!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=D(i.top,a.y),i.left=D(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=u(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=u(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(w,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,h(n,{dropTarget:e(t.targetElement)}))}i._trigger(S,h(n,{dropTarget:e(r)})),t=h(i,{targetElement:r})}else t&&(t._trigger(T,h(n,{dropTarget:e(t.targetElement)})),t=null)})),this._trigger(y,h(n,{dropTarget:t,elementUnderCursor:i}))},_autoScroll:function(){var e=this._scrollableParent[0],t=this._scrollVelocity,n=this._scrollCompenstation;if(e){var i=this._elementUnderCursor(this._lastEvent);var a,s;this._processMovement(this._lastEvent,i);var l=e===U()[0];l?(a=r.body.scrollHeight>o.height(),s=r.body.scrollWidth>o.width()):(a=e.offsetHeight<=e.scrollHeight,s=e.offsetWidth<=e.scrollWidth);var c=e.scrollTop+t.y;var d=a&&c>0&&c<e.scrollHeight;var h=e.scrollLeft+t.x;var u=s&&h>0&&h<e.scrollWidth;d?e.scrollTop+=t.y:a&&c<0&&(e.scrollTop=0),u?e.scrollLeft+=t.x:s&&h<0&&(e.scrollLeft=0),this.hint&&l&&(u||d)&&(d&&(n.top+=t.y),u&&(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(h({},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,h({},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){var o,a,s=0,l=n&&n.length,c=r&&r.length;for(;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;var o=e(t)[0];for(;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};var 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=I,n.containerBoundaries=E,h(n.ui,{Pane:B,PaneDimensions:P,Movable:R}),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,h=i.Transition,u=i.Animation,p=Math.abs,f="km-scroller-release",m="km-scroller-refresh",g="change",v="scroll";var _=u.extend({init:function(e){var t=this;u.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)}});var b=u.extend({init:function(e){var t=this;u.fn.init.call(t),o(t,e,{transition:new h({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),u.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(),u.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:h.easeOutExpo})}});var w=u.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}}});var y=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)}});var 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),h=new t.TapCapture(n),u=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()}}),y=new c({movable:u,dimensions:f,userEvents:b,elastic:r.options.elastic}),k=new _({movable:u,dimensions:f,userEvents:b,tapCapture:h}),x=new w({moveTo:function(e){r.scrollTo(e.x,e.y)}});u.bind(g,(function(){r.scrollTop=-u.y,r.scrollLeft=-u.x,r.trigger(v,{scrollTop:r.scrollTop,scrollLeft:r.scrollLeft})})),r.options.mousewheelScrolling&&n.on("DOMMouseScroll mousewheel",this._wheelScroll.bind(this)),o(r,{movable:u,dimensions:f,zoomSnapBack:k,animatedScroller:x,userEvents:b,pane:y,tapCapture:h,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 y({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;var 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;var i=n.ui.Widget;var r=n.html;var o=n.ui,a=n.keys,s="select",l="click",c="remove";var d=".kendoChip";var h="k-chip-remove-action",u="k-selected",p="k-disabled";var 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(u,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,"."+h,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;var 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;var 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;var 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;var 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";var h=t.html;var u={widget:"k-chip-list",item:"k-chip",selected:"k-selected",disabled:"k-disabled",enabledItemSelector:"k-chip:not(.k-disabled)"};var p=i.extend({init:function(t,n){var r=this;n=n||{},i.fn.init.call(r,t,n),h.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=u;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;var 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(){var t,n,i,r,o=this,a=o.options.items;for(var 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+u.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+u.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+u.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+u.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+u.item),i=t.keyCode;i!==r.LEFT&&i!==r.RIGHT||this._focusNavigatableItem(i,n)},_focusNavigatableItem:function(e,t){var n=this;var i=n._getNavigatableItem(e,t);i&&(n._applyTabIndex(n.items().index(i)),i.trigger("focus"))},_getFirstNavigatableItem:function(){return this.items().filter(l+u.enabledItemSelector).first()},_getLastNavigatableItem:function(){return this.items().filter(l+u.enabledItemSelector).last()},_getNavigatableItem:function(e,t){var n;return n=t||this._getFirstNavigatableItem(),e===r.LEFT&&t&&(n=t.prevAll(l+u.enabledItemSelector).first()),e===r.RIGHT&&t&&(n=t.nextAll(l+u.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+u.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",h=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"}))},u=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:h,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"}),u.css(f,0).appendTo(m.groupContainer))},dragleave:function(e){t.ui.icon(e.draggable.hint.find(".k-drag-status"),{icon:"cancel"}),u.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"),h=m.indicator(a),f=m._dropCuePositions,g=f[f.length-1],v="after",_=s||!g?0:g.element.parent().position().left;var b=o({},m.options.sort,r.data(c));var w=b.dir;(r.hasClass("k-chip")||m._canDrag(r))&&(g?(i=m._dropCuePosition(t.getOffset(u).left+_+parseInt(g.element.css("marginLeft"),10)*(s?-1:1)+parseInt(g.element.css("marginRight"),10)))&&m._canDrop(e(h),i.element,i.left)&&(i.before&&(v="before"),i.element[v](h||m.buildIndicator(a,l,w,d).wrapper),m._setIndicatorSortOptions(a,b),m._change()):(p(m._messageContainer),m._list.element.show(),m._list.add(m.buildIndicator(a,l,w,d).element),m._setIndicatorSortOptions(a,b),m._change()))}}).kendoDraggable({filter:"div.k-chip",hint:h,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(),u.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;var n=t.dataSource.group()||[];var i=r("field");var s=r("title");const l=t.options._groupableFieldsData;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;var c=r.dir;var d=t.element.find(t.options.filter).filter((function(){return e(this).attr(i)===a}));if(!d.length&&l){const e=l.filter((function(e){return e.field===a}))[0]||{};var h=t.buildIndicator(a,e.title,c,e.id)}else h=t.buildIndicator(a,d.attr(s),c,d.attr("id"));t._list.add(h.element),t._list.element.show(),t._setIndicatorSortOptions(a,o({},t.options.sort,{dir:c,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");var 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=this;var s;var c;var d;return r=r||(a.options.sort||{}).dir||l,c=(d=(s=e("<div/>").kendoChip({icon:"sort-"+("asc"==(r||"asc")?"asc-small":"desc-small"),iconClass:"k-chip-icon",label:`${t.htmlEncode(i||n)}`,removable:!0,size:a.options.size||"medium",remove:a.removeHandler.bind(a),click:a.clickHandler.bind(a),actions:a.options.enableContextMenu?[{icon:"more-vertical",iconClass:"k-groupable-context-menu"}]:null}).data("kendoChip")).wrapper).find(".k-chip-icon").first(),d.attr(`data-${t.ns}field`,n),d.attr(`data-${t.ns}title`,i||""),o&&d.attr(`data-${t.ns}id`,o),c.attr("title",`(sorted ${"asc"==r?"ascending":"descending"})`),c.attr(`data-${t.ns}dir`,r),s},_setIndicatorSortOptions:function(t,n){e(this.indicator(t)).data(c,n)},aggregates:function(){var n;var i;var 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||{};var s=r.data(c)||{};var 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(u.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&&u.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))&&!this.dataSource?._requestInProgress},_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(){u.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;var 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";var 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;var 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};var h="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[h?"left":"top"]+=h?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;var t=s._draggable;var n=s._index(e);var 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.options.allowDropAfterLastItem||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;var 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;var i=e(t.currentTarget);var 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={},h=c.options.dropFilter.trimStart();if(h&&">"==h[0]&&(h=h.substring(1)),l=e(t.currentTarget).closest(h),!(!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 u=r(c._dropTarget).left;var p=n(c._dropTarget);t.pageX>u+p/2?(d.left=u+p,o+=1):d.left=u}else{var f=r(c._dropTarget).top;var 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.allowDropAfterLastItem||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",h="resizeend";var u=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,h,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(h,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(u)}(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",h="sort",u="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,allowTouchActions:!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),allowTouchActions:r.allowTouchActions})},_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},h=this.options.axis,u=this.options.moveOnDragEnter,p={item:s,list:this,draggableEvent:t};if("x"!==h&&"y"!==h){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&&u||!u&&i.left<0?r="prev":(d.x>0&&u||!u&&i.left>0)&&(r="next"):d.y<0&&u||!u&&i.top<0?r="prev":(d.y>0&&u||!u&&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(h,c,d[h],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:h,item:s,oldIndex:d,newIndex:f,draggableEvent:t},f>=0?i=this.trigger(l,r):(n=a.parents(m).getKendoSortable(),r.action=u,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)?h:u,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){var i,r,o,a=e(this.options.connectWith);for(var 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}))},_resetCursor:function(){this._originalCursorType&&(e(document.body).css("cursor",this._originalCursorType),this._originalCursorType=null)},_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"));var n=/inline|table-cell/.test(e.css("display"));var 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",h="unselect",u="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",w="end",y="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=y.replaceAll("k-i","k-svg-i"),x=k.split(",").map((e=>e+" *")).join(","),C=`input,a,textarea,.k-multiselect-wrap,select,button,${y},${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,M=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,h],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=this.element;var n,i=t.length,r=!1;for(e=e[0],n=0;n<i;n++)if(t[n]===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,h=l&&t.event.shiftKey,u=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(u),i=i.add(r.relatedTarget(i)),l?h?(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(u))):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+"."+u)).removeClass(u);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(u):o.hasClass(l)||o.hasClass(u)||this._collidesWithActiveElement(r,e)||r.addClass(l),this._currentlyActive.push(r[0])):o.hasClass(l)?r.removeClass(l):t&&o.hasClass(u)&&r.removeClass(u).addClass(d)},_collidesWithActiveElement:function(e,t){if(!this.options.ignoreOverlapped)return!1;var i=this._currentlyActive;var r=e[0].getBoundingClientRect();var o;var a=!1;var s=n.support.isRtl(e)?"right":"left";var l={};t.right=t.left+t.width,t.bottom=t.top+t.height;for(var c=0;c<i.length;c++)if(z(r,o=i[c].getBoundingClientRect())){if(l[s]="left"===s?o.right:o.left,(r=M({},r,l)).left>r.right)return!0;a=!z(r,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");var i={};return this.element.find("["+t+"]").each((function(n,r){var o=e(r).attr(t);var a=i[o];a||(a=i[o]=[]),a.push(e(r))})),i},selectedSingleItems:function(){var t=this;var 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(h,{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}});const D=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===w&&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);let n=t.find(i.cellSelectorValid).last();let 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,h=d.resetOnStart;if(r._lastActive=i,!a&&!s)return r.clear(!0),o.target===b&&r.start(i),o.target===w&&r.end(i),r._clearFlags(),void r.trigger(c);if(!a&&s)return o.target===w?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===w&&!d.reverse&&+a>+l?(r.clear(!0),h?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===w?(r.clear(!0),h?(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===w&&r.range(r._start,i),void r.trigger(c));h?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;var 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(D)}(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";var 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;var t=e.element;var n=e.options.widget.wrapper.find(".k-input-inner");if(n.length>0){var i=e.element.find("> .k-floating-label").height();var r=n.position().left+Number.parseInt(n.css("padding-left"));var 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;var n=t.element;var i=e.disable;var 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;let Ku=kendo.jQuery;function Yu({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,h=(r=r||i,n.layoutFlow),u=h?"vertical"==h?"horizontal":"vertical":"horizontal",p=`<span class="k-input-separator k-input-separator-${"vertical"==h?"horizontal":"vertical"}"></span>`;s&&c&&((o=t.children(".k-input-prefix"))[0]||(n._isInInlineAIPrompt&&(u=h||"horizontal"),o=Ku(`<span class="k-input-prefix k-input-prefix-${u}" />`),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&&Ku(p).insertAfter(o)),l&&d&&((a=t.children(".k-input-suffix"))[0]||(a=Ku(`<span class="k-input-suffix k-input-suffix-${u}" />`).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&&Ku(p).insertBefore(a)),e._prefixContainer=o,e._suffixContainer=a}!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",h="input",u="k-focus",p="k-disabled",f="k-readonly",m="k-hidden",g="aria-disabled";var 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.options.inputMode=o.inputMode||s.element.attr("inputmode")||"text",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("inputmode",s.options.inputMode).attr("autocomplete","off"),o.icon&&s._icon(),Yu({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,h],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;var n=t.element;var i=t.wrapper;var r=e.disable;var 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(h+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(h,{value:t,originalEvent:e})},_label:function(){var t=this;var i=t.element;var r=t.options;var a=i.attr("id");var s;var l;null!==r.label&&(s=!!o(r.label)&&r.label.floating,l=o(r.label)?r.label.content:r.label,s&&(t._floatingLabelContainer=t.wrapper.wrap("<span></span>").parent(),t.floatingLabel=new n.ui.FloatingLabel(t._floatingLabelContainer,{widget:t})),n.isFunction(l)&&(l=l.call(t)),l||(l=""),a||(a=r.name+"_"+n.guid(),i.attr("id",a)),t._inputLabel=e("<label class='"+(s?"k-floating-label":"k-label k-input-label")+"' for='"+a+"'>"+l+"</label>'")[s?"insertAfter":"insertBefore"](t.wrapper))},_focusin:function(){this.wrapper.addClass(u)},_focusout:function(){this.wrapper.removeClass(u)},_change:function(e){var t=this;var n=t.element.val();t._value=n,t.trigger(s,{value:n,originalEvent:e}),n?t._showClear():t._hideClear()},_wrapper:function(){var e=this.element;var t=e[0];var n;(n=e.wrap("<span class='k-input k-textbox'></span>").parent())[0].style.cssText=t.style.cssText,t.style.width="100%",this.wrapper=n.addClass(t.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){var t=window.kendo,n=t.ui.Widget,i=".k-icon,.k-svg-icon";var r="k-avatar",o="k-avatar-bordered";var a="icon",s="image",l="text";var 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;!function(e,t){var n=window.kendo;var i=n.ui.Widget;var r=n.ui;var o=({icon:t})=>n.ui.icon(e("<span class='k-badge-icon'></span>"),{icon:t});var a=({icon:e})=>`<span class='k-badge-icon k-svg-icon k-icon'>${e}</span>`;var 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;var t=e.options.text;var i=e.options.template;var r=e.options.data;var 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;var n=["k-badge"];var i=e.options._classNames;var r=e._themeColor;var o=e._shape;var a=e._sizes;var s=e._size;var l=a[s]===t?s:a[s];var c=e._fillMode;var d=e._rounded;var h=e._roundings;var u=h[d]===t?d:h[d];var p=e._cutoutBorder;var f=e._align;var m=e._position;var 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-"+u),"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;var 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=this;var r;return 0===arguments.length||e===t?i._icon:(i._icon=e,0===e.indexOf("<svg")?(r=n.template(a),void i.element.html(r({icon:e}))):(r=n.template(o),void i.element.html(r({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){var t=window.kendo,n=t.html.HTMLBase,i="k-button-icon";var 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,h=l.spriteCssClass,u=l.imageUrl;(h||u||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"),u?((r=s.children("img.k-image").first())[0]||(r=e('<img alt="icon" class="k-image" />').prependTo(s)),r.attr("src",u),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)):h&&((n=s.children("span.k-sprite").first())[0]||(n=e('<span class="k-sprite"></span>').prependTo(s)),n.addClass(h+" "+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,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",h="disabled",u="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(h),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(u)},_blur:function(){var e=this;e.element.removeClass(u),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(h,!e),e&&n._tabindex();try{i.trigger("blur")}catch(e){}},_badge:function(n){var i=this;var r=n||i.options.badge;var a;null!==r&&r!==t&&(r.constructor!==Object&&(r={text:r}),r.position!==t&&""!==r.position||(r.position="edge",r.align!==t&&""!==r.align||(r.align="top end")),r._classNames=["k-button-badge"],i.element.addClass("k-badge-container"),a=e("<span />").appendTo(i.element),i.badge=new o.Badge(a,r))}});!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;var Qu=()=>"<span class='k-appbar-spacer'></span>";!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r="resize";var 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(){var n=this.options.items;var i;var r="";var o;for(var a=0;a<n.length;a++)if("spacer"==(i=n[a]).type)o=e(t.template(Qu)({})).addClass(i.className),i.width&&(o.addClass("k-appbar-spacer-sized"),o.css("width","string"==typeof i.width?i.width:i.width+"px")),r+=o[0].outerHTML;else{if(!i.template)throw new Error("Having a template for the contentItem is mandatory");i.className?r+="<div class='k-appbar-section "+i.className+"'>":r+="<div class='k-appbar-section'>",r+=t.template(i.template)({}),r+="</div>"}this.element.html(r)},_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,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",h="k-disabled",u="k-readonly",p="aria-disabled";var 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.inputMode=o.inputMode||a.element.attr("inputmode")||"text",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"),a.element.attr("inputmode",a.options.inputMode),Yu({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,maxRows: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){let t=this;let r=t.options;let o=n.cssProperties.getValidClass({widget:r.name,propName:"resize",value:r.resize});let a=n.cssProperties.getValidClass({widget:r.name,propName:"overflow",value:r.overflow});let s=n.cssProperties.getValidClass({widget:r.name,propName:"layoutFlow",value:r.layoutFlow});i.fn._applyCssClasses.call(t),o||"none"!==r.resize&&"auto"!==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=this;var t;var n={};for(t in e.attributes)n[e.attributes[t]]=e.options[e.attributes[t]];e.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()},updateAutoHeight:function(){const e=this.element;const t=this.options;if("auto"===t.resize&&t.maxRows){const n=getComputedStyle(e[0]);const i=parseInt(n.lineHeight,10)||16;const r=(parseInt(n.paddingTop,10)||0)+(parseInt(n.paddingBottom,10)||0);const o=t.rows*i+r;const a=t.maxRows*i+r;e.css({height:o+"px"});const s=e[0].scrollHeight;e.css({maxHeight:a+"px",height:s+"px"})}},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;var n=t.element;var i=t.wrapper;var r=e.disable;var o=e.readonly;n.off(a),o||r?(n.attr(l,r).attr(c,o).attr(p,r),i.toggleClass(h,r).toggleClass(u,o)):(n.prop(l,!1).prop(c,!1).attr(p,!1),i.removeClass(h).removeClass(u),n.on("focusin"+a,t._focusin.bind(t)),n.on("focusout"+a,t._focusout.bind(t)),n.on("input"+a,t._input.bind(t)))},_label:function(){var t=this;var i=t.element;var r=t.options;var a=i.attr("id");var s;var l;null!==r.label&&(s=!!o(r.label)&&r.label.floating,l=o(r.label)?r.label.content:r.label,s&&(t._floatingLabelContainer=t.wrapper.wrap("<span></span>").parent(),t.floatingLabel=new n.ui.FloatingLabel(t._floatingLabelContainer,{widget:t}),t._floatingLabelContainer.addClass("k-textarea-container")),n.isFunction(l)&&(l=l.call(t)),l||(l=""),a||(a=r.name+"_"+n.guid(),i.attr("id",a)),t._inputLabel=e("<label class='"+(s?"k-floating-label":"k-label k-input-label")+"' for='"+a+"'>"+l+"</label>'")[s?"insertAfter":"insertBefore"](t.wrapper))},_focusin:function(){this.wrapper.addClass(d)},_focusout:function(){var e=this;var t=e._value;var n=e.element.val();e.wrapper.removeClass(d),null===t&&(t=""),t!==n&&(e._value=n,e.trigger(s))},_input:function(){this.updateAutoHeight()},_wrapper:function(){var e=this.element;var t=e[0];var n;(n=e.wrap("<span class='k-input k-textarea'></span>").parent())[0].style.cssText=t.style.cssText,t.style.width="",this.wrapper=n.addClass(t.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;const Xu="start";const Zu="end";const Ju="result";const ep="error";const tp={lang:"en-US",continuous:!1,interimResults:!1,maxAlternatives:1,events:{[Xu]:null,[Zu]:null,[Ju]:null,[ep]:null}};function np(){return window?window.SpeechRecognition||window.webkitSpeechRecognition:void 0}class ip{constructor(e){this.recognition=null,this.isListening=!1,this.options={...tp},this.handleResult=e=>{this.triggerOnResult(e)},this.handleError=e=>{this.triggerOnError(e)},this.handleEnd=()=>{this.triggerOnEnd(),this.isListening=!1},this.handleStart=()=>{this.triggerOnStart(),this.isListening=!0},this.init(e)}init(e){const t=np();if(!t)return console.error("Speech recognition is not supported in this browser."),void(this.recognition=null);this.recognition=new t,this.setOptions(e),this.bindEvents()}destroy(){this.unbindEvents(),this.isListening=!1}bindEvents(){this.recognition&&(this.recognition.onresult=this.handleResult,this.recognition.onerror=this.handleError,this.recognition.onend=this.handleEnd,this.recognition.onstart=this.handleStart)}unbindEvents(){this.recognition&&(this.recognition.onresult=null,this.recognition.onerror=null,this.recognition.onend=null,this.recognition.onstart=null,this.recognition.abort(),this.recognition=null)}setOptions(e){if(!this.recognition)return;const t={...this.options.events,...e.events};this.options={...this.options,...e,events:t};const{lang:n,continuous:i,interimResults:r,maxAlternatives:o}=this.options;Object.assign(this.recognition,{lang:n,continuous:i,interimResults:r,maxAlternatives:o})}triggerOnStart(){this.options.events[Xu]&&this.options.events[Xu]()}triggerOnEnd(){this.options.events[Zu]&&this.options.events[Zu]()}triggerOnResult(e){this.options.events[Ju]&&this.options.events[Ju](e)}triggerOnError(e){this.options.events[ep]&&this.options.events[ep](e)}start(){this.recognition&&!this.isListening&&this.recognition.start()}stop(){this.recognition&&this.isListening&&this.recognition.stop()}abort(){this.recognition&&this.isListening&&this.recognition.abort()}isSupported(){return!!np()}isActive(){return this.isListening}}!function(e){const t=window.kendo,n=t.ui,i=n.Button;const r=i.extend({init:function(t,n){i.fn.init.call(this,t,e.extend({icon:this.options.icon},n)),e(t).addClass("k-speech-to-text-button").attr("aria-live","polite"),this._isListening=!1,this._initSpeechRecognition(),this._updateIcon()},_initSpeechRecognition:function(){if("webSpeech"!==this.options.integrationMode)return;if(!ip)return void this.enable(!1);const e=this;this.speechRecognition=new ip({lang:this.options.lang,interimResults:this.options.interimResults,maxAlternatives:this.options.maxAlternatives,continuous:this.options.continuous,events:{start:function(){e._handleStart()},end:function(){e._handleEnd()},result:function(t){e._handleResult(t)},error:function(t){e._handleError(t)}}}),this.speechRecognition.isSupported()||(this.enable(!1),this.trigger("error",{error:this.options.messages.unsupported}))},_handleStart:function(){this._isListening=!0,this.element.addClass("k-listening"),this._updateIcon(),this.trigger("start")},_handleEnd:function(){this._isListening=!1,this.element.removeClass("k-listening"),this._updateIcon(),this.trigger("end")},_handleResult:function(e){const t=e.results;const n=t[t.length-1];const i=[];for(let e=0;e<n.length;e++)i.push({transcript:n[e].transcript,confidence:n[e].confidence});this.trigger("result",{isFinal:n.isFinal,alternatives:i})},_handleError:function(e){this._isListening=!1,this.element.removeClass("k-listening"),this._updateIcon();const t=e&&(e.error||e.message)||"Unknown error";this.trigger("error",{error:t})},options:{name:"SpeechToTextButton",icon:"microphone-outline",stopIcon:"stop-sm",integrationMode:"webSpeech",lang:"en-US",continuous:!1,interimResults:!1,maxAlternatives:1,messages:{unsupported:"Speech recognition is not supported in this browser.",notInitialized:"Speech recognition engine not initialized.",start:"Start speech recognition",stop:"Stop speech recognition"}},events:["start","end","result","error","click"],_updateIcon:function(){const e=this.element.find(".k-icon, .k-svg-icon");const n=this.isListening()?this.options.stopIcon:this.options.icon;const i=this.isListening()?this.options.messages.stop:this.options.messages.start;e.length&&t.ui.icon(e,{icon:n}),this.element.attr("aria-label",i)},isListening:function(){return!!this._isListening},_click:function(e){if(i.fn._click.call(this,e),!e.isDefaultPrevented())if("webSpeech"===this.options.integrationMode){if(!this.speechRecognition||!this.speechRecognition.isSupported())return void this.trigger("error",{error:this.options.messages.unsupported});this.isListening()?this.speechRecognition.stop():this.speechRecognition.start()}else if("none"===this.options.integrationMode){const e=this.isListening()?"end":"start";const t={sender:this};this.trigger(e,t),this._isListening=!this.isListening(),this._updateIcon()}},startRecognition:function(){this.options.enable&&(this.speechRecognition?this.speechRecognition.isSupported()?this.isListening()||this.speechRecognition.start():this.trigger("error",{error:this.options.messages.unsupported}):this.trigger("error",{error:this.options.messages.notInitialized}))},stopRecognition:function(){this.speechRecognition&&this.isListening()&&this.speechRecognition.stop()},abortRecognition:function(){this.speechRecognition&&this.isListening()&&this.speechRecognition.abort()},destroy:function(){this.speechRecognition&&(this.speechRecognition.stop(),"function"==typeof this.speechRecognition.destroy&&this.speechRecognition.destroy(),this.speechRecognition=null),e(this.element).removeClass("k-speech-to-text-button"),i.fn.destroy.call(this)}});t.cssProperties.registerPrefix("SpeechToTextButton","k-button-"),t.cssProperties.registerValues("SpeechToTextButton",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}]),n.plugin(r)}(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",h="k-progress-end",u="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,w=e.extend,y={progressStatus:"<span class='k-progress-status-wrap "+h+"'><span class='k-progress-status'></span></span>",noProgressStatus:"<span class='k-progress-status-wrap "+h+"'></span>",announceElement:'<span aria-live="polite" class="k-sr-only k-progress-announce"></span>'};var 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(y.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;var t=e.wrapper=e.element;var n=e.options;var i=n.orientation;var 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(y.progressStatus).find("."+d),n.type===g.VALUE?e.progressStatus.text(l):e.progressStatus.text(e._calculatePercentage(l).toFixed()+"%")):e.wrapper.prepend(y.noProgressStatus)},value:function(e){return this._value(e)},_value:function(e){var n=this;var i=n.options;var r;if(e===t)return i.value;"boolean"!=typeof e?(e=n._roundValue(e),isNaN(e)||(r=n._validateValue(e))!==i.value&&(n.wrapper.removeClass(s),i.value=r,n._isStarted=!0,n._updateProgress())):e||(n.wrapper.addClass(s),n.wrapper.removeAttr("aria-valuenow"),i.value=!1,n.announce&&n.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;var t=e.options;var 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=this;var i=t.options;var a=i.chunkCount;var s=parseInt(100/a*100,10)/100;var l=parseInt(100*e,10)/100;var c=b.floor(l/s);var d;d=i.orientation===r&&!i.reverse||i.orientation===o&&i.reverse?t.wrapper.find("li."+m).slice(0,c):0===c?n.jQuery():t.wrapper.find("li."+m).slice(-1*c),t.wrapper.find("."+u).removeClass(u+" "+f),d.addClass(u+" "+f)},_updateProgressWrapper:function(e){var t=this;var n=t.options;var i=t.wrapper.find("."+c);var r=t._isStarted?t._animation.duration:0;var 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=this;var n=t.options;var i=parseFloat(e.elem.style[t._progressProperty],10);var r;n.showStatus&&(r=1e4/parseFloat(t.progressWrapper[0].style[t._progressProperty]),t.progressWrapper.find(".k-progress-status-wrap").css(t._progressProperty,r+"%")),n.type!==g.CHUNK&&i<=98&&t.progressWrapper.removeClass(l)},_onProgressAnimateComplete:function(e){var t=this;var n=t.options;var i=parseFloat(t.progressWrapper[0].style[t._progressProperty]);var r;n.type!==g.CHUNK&&i>98&&t.progressWrapper.addClass(l),n.showStatus&&(r=n.type===g.VALUE?e:n.type==g.PERCENT?t._calculatePercentage(e).toFixed()+"%":b.floor(t._calculatePercentage(e))+"%",t.progressStatus.text(r)),e===n.min&&t.progressWrapper.hide()},_onProgressUpdateAlways:function(e){var t=this;var 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;var t=e.options;var n=e.wrapper;var i=100/t.chunkCount;var 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;var t=e.options;var n=e.wrapper.find("."+m).last();var i=parseFloat(n[0].style[e._progressProperty]);var 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(y.progressStatus),t.progressStatus=t.wrapper.find("."+d)):t.progressWrapper.prepend(y.noProgressStatus)},_calculateChunkSize:function(){var e=this;var t=e.options.chunkCount;var n=e.wrapper.find("ul.k-reset");return(parseInt(n.css(e._progressProperty),10)-(t-1))/t},_calculatePercentage:function(e){var n=this;var i=n.options;var r=e!==t?e:i.value;var o=i.min;var a=i.max;return n._onePercent=b.abs((a-o)/100),b.abs((r-o)/n._onePercent)},_progressAnimation:function(){var e=this;var t=e.options;var n=t.animation;e._animation=!1===n?{duration:0}:w({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",h="complete",u="cancel",p="clear",f="pause",m="resume",g="progress",v="remove",_="validationErrors",b="invalidMaxFileSize",w="invalidMinFileSize",y="invalidFileExtension",k="k-hover",x="k-focus",C="k-progressbar",S="."+C,T="tabindex";var M="upload",A="exclamation-circle",D="check";var 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,h,u,p,g,v,f,m],options:{name:"Upload",enabled:!0,multiple:!0,directory:!1,showFileList:!0,uniqueFileUids:!1,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;var 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");var 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");var 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(){var t;var n=[];var i=this.wrapper.find(".k-file");for(var 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=this;var r=i.wrapper.find(".k-file");var o;"function"==typeof t&&r.each((function(r,a){o=e(a).data("fileNames"),t(o)&&i._removeFileByDomElement(a,n)}))},_removeFileByDomElement:function(t,n){var i=this;var 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(u,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;var i=e(t.target);var r=F(n._inputFiles(i),n._isAsyncNonBatch()||n.options.uniqueFileUids);O(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;var i=t.createReader();var r=[];var 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;var 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=e.originalEvent.dataTransfer;var n=this;var i=t.files;var r;if(G(e),n.options.directoryDrop&&t.items){r=t.items.length,n.droppedFolderCounter=0,n.droppedFolderFiles=[];for(var o=0;o<r;o++)if(t.items[o].webkitGetAsEntry){var a=t.items[o].webkitGetAsEntry();a.isDirectory?n._traverseFileTree(a,!0):a.isFile&&n.droppedFolderFiles.push(t.files[o])}else n._proceedDroppedItems(i)}else n._proceedDroppedItems(i)},_proceedDroppedItems:function(t){var n=this;var i=F(H(t),n._isAsyncNonBatch()||n.options.uniqueFileUids);t.length>0&&!n.wrapper.hasClass("k-disabled")&&(!n.multiple&&i.length>1&&i.splice(1,i.length-1),O(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;var n=0;for(e=F(e,!0),n=0;n<e.length;n++){var i=e[n];var 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];var r=$(n.fileNames);var o=t.getFileGroup(i.extension,!0);var a=i[_];var s=a&&a.length>0;var l=s?" k-file-invalid k-file-error":"";var 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 h="";return h+="<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(h+="<span class='k-upload-actions'></span></div>")},_prepareDefaultMultipleFileEntriesTemplate:function(n){var i=n.fileNames;var r=this._filesContainValidationErrors(i);var o=$(i);var a="";var s,l;for(a+="<li class='k-file"+(r?" k-file-invalid k-file-error":"")+"'><div class='k-file-multiple'>"+this._createProgressbarWapper()+this._createFileIconWrapper("copy"),i.sort((function(e,t){return e[_]?-1:t[_]?1:0})),a+="<span class='k-multiple-files-wrapper'>",s=0;s<i.length;s++){var c=$([l=i[s]]);let e=t.htmlEncode(l.name,!0);a+="<span class='k-file-info'>",l[_]&&l[_].length>0?a+="<span class='k-file-name k-file-name-invalid' title='"+e+"'>"+e+"</span>":a+="<span class='k-file-name' title='"+e+"'>"+e+"</span>",a+="<span class='k-file-size'>"+c+"</span></span>"}return a+=r?"<span class='k-file-validation-message' aria-live='polite'>"+t.htmlEncode(this.localization.invalidFiles)+"</span>":"<span class='k-file-summary'>Total: "+i.length+" files, "+o+"</span>",e(a+="</span><span class='k-upload-actions'></span></div>")},_enqueueFile:function(n,i){var r=this;var o;var a;var s=i.fileNames[0].uid;var l=e(".k-upload-files",r.wrapper);var c=r.options.template;var d;var h;var u=c?".k-progress":S;var p;var f;return 0===l.length&&(l=e("<ul class='k-upload-files'></ul>").appendTo(r.wrapper),r.options.showFileList||l.hide(),r.wrapper.removeClass("k-upload-empty")),o=e(".k-file",l),c?(d=r._prepareTemplateData(n,i),c=t.template(c),(a=e("<li class='k-file'>"+c(d)+"</li>")).find(".k-upload-action").addClass("k-button k-icon-button k-button-md k-rounded-md k-button-flat k-button-flat-base")):a=1===i.fileNames.length?r._prepareDefaultSingleFileEntryTemplate(i):r._prepareDefaultMultipleFileEntriesTemplate(i),(f=(p=e(u,a[0])).length>0)&&r._progressbarInit(p),a.attr(t.attr("uid"),s).appendTo(l).data(i),!r._async&&f&&p.data("kendoProgressBar").value(100),!r.multiple&&o.length>0&&(h={files:o.data("fileNames"),headers:{}},r.trigger(v,h)||r._module.onRemove({target:e(o,r.wrapper)},h)),a},_removeFileEntry:function(t){var n=this;var i=t.closest(".k-upload-files");var r;t.remove(),r=e(".k-file",i),e(".k-file-success, .k-file-error",i).length===r.length&&this._hideActionButtons(),0===r.length?(i.remove(),n.wrapper.addClass("k-upload-empty"),n._hideHeaderUploadstatus()):n._updateHeaderUploadStatus()},_fileAction:function(n,i,r){var o={remove:"x",cancel:"cancel",retry:"arrow-rotate-cw-small",pause:"pause-sm"};var a;let s=t.htmlEncode(this.localization[i]);if(o.hasOwnProperty(i))if(r||this._clearFileAction(n),this.options.template)if((a=n.find(".k-upload-action").first()).find(".k-icon,.k-svg-icon").length){if(a.next(".k-upload-action").length){let n=t.ui.icon(e(`<span title="${s}" aria-label="${s}"></span>`),{icon:o[i],iconClass:"k-button-icon"+("retry"==i?" k-i-retry":"")});a.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:o[i],iconClass:"k-button-icon"+("retry"==i?" k-i-retry":"")});a.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(o[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");var r=i.find(".k-icon,.k-svg-icon");var o=i.closest(".k-file");var a=o.data("fileNames");var s=n._filesContainValidationErrors(a);var 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(u,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:Q(t).data("fileNames"),percentComplete:n})},_onUploadSuccess:function(e,n,i){var r=this;var o=Q(e);var a=o.data("fileNames");var s=o.find(".k-file-summary");var 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;var i=n._module;var o=Q(e);var 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;var 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;var i=e(S,t);var 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;var i=e(".k-actions",n.wrapper);var r=e(".k-upload-selected",n.wrapper);var 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;var r=i.localization;var o=e(".k-dropzone",i.wrapper);var 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:M})):(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=this;var i=e(".k-upload-status",this.wrapper);var r=e(".k-file",n.wrapper).not(".k-file-success, .k-file-error");var o=e(".k-file-error",n.wrapper);var a=e(".k-file",n.wrapper).find(".k-i-play-sm,.k-svg-i-play-sm");var s;!a.length||a.length!==r.length&&n.options.async.concurrent?(0===r.length||o.length>0)&&(i=e(".k-upload-status",n.wrapper),(s=e(".k-icon,.k-svg-icon",i).removeClass()).length&&(t.ui.icon(s,{icon:0!==o.length?A:D}),i.html(s).append(t.htmlEncode(n.localization.headerStatusUploaded)))):(s=e(".k-icon,.k-svg-icon",i).removeClass()).length&&(t.ui.icon(s,{icon:"pause-sm"}),i.html(s).append(t.htmlEncode(n.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;var i=n._ns;var r=e(".k-dropzone",n.wrapper).on("dragenter"+i,G).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>")),K(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;var 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,G).on("dragover"+r,(function(e){e.originalEvent&&(e.originalEvent.dataTransfer.dropEffect="copy"),e.preventDefault()})).on("drop"+r,n._onDrop.bind(n)),K(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;var i=n._ns;K(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"),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:q,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;var r=!!n.attr("id")&&e("[for='"+n.attr("id")+"']").length>0;var o=t.htmlEncode(this.localization.select);var 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(h)},_inputFiles:function(e){return B(e)}});var 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;var r=e(t.target);var o=i._filesContainValidationErrors(n);i._addInput(r);var a={fileNames:n};o?r.remove():a.relatedInput=r;var s=i._enqueueFile(L(r),a);o&&i._hideUploadProgress(s),i._fileAction(s,v)},onRemove:function(e){var t=Q(e);var 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;var r=e(t.target);var o=i._filesContainValidationErrors(n);var 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=this.upload;var o=e(r.element);var a=r.options.async.saveField||t.attr("name");var s,l,c,d;return r._addInput(t),t.attr("name",a),i?(t.remove(),l={fileNames:n}):(c=this.createFrame(r.name+"_"+E._frameId++),this.registerFrame(c),d=this.createForm(r.options.async.saveUrl,c.attr("name")).append(o),l={frame:c,relatedInput:o,fileNames:n}),s=r._enqueueFile(L(t),l),c&&c.data({form:d,file:s}),s},performUpload:function(t){var n={files:t.data("fileNames")};var r=t.data("frame");var o=this.upload;var a=t.find(".k-file-validation-message");var s=t.find(".k-file-summary");var 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 h in n.data=e.extend({},n.data,i()),n.data){var p=d.find("input[name='"+h+"']");0===p.length&&(p=e("<input>",{type:"hidden",name:h}).prependTo(d)),p.val(n.data[h])}o._fileAction(t,u),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;var n=t.upload;e(".k-file",this.element).each((function(){var i=e(this);var r=Y(i);var 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};j(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=Q(e);this.performUpload(t)},onRemove:function(e,t,n){var i=this;var r=i.upload;var o=Q(e);var a=o.data("frame");a?(i.unregisterFrame(a),r._removeFileEntry(o),i.cleanupFrame(a)):o.hasClass("k-file-success")?W(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 L(t){return e.map(B(t),(function(e){return e.name})).join(", ")}function B(e){var t=e[0];return t.files?H(t.files):[{name:(n=t.value,i=n.lastIndexOf("\\"),-1!=i?n.substr(i+1):n),extension:R(t.value),size:null}];var n,i}function H(n){return e.map(n,(function(e){return i=(n=e).name||n.fileName,{name:t.htmlEncode(i),extension:R(i),size:"number"==typeof n.size?n.size:n.fileSize,rawFile:n};var n,i}))}function R(e){var t=e.match(o);return t?t[0]:""}function F(n,i){var r=t.guid();return e.map(n,(function(e){return e.uid=i?t.guid():r,e}))}function O(t,n){var i=function(t){var n=e.map(t,(function(e){return("."===e.substring(0,1)?e:"."+e).toLowerCase()}));return n}(n.allowedExtensions);var r=n.maxFileSize;var o=n.minFileSize;for(var a=0;a<t.length;a++)V(t[a],i),N(t[a],o,r)}function V(t,n){n.length>0&&n.indexOf(t.extension.toLowerCase())<0&&(t.validationErrors=t.validationErrors||[],-1===e.inArray(y,t.validationErrors)&&t.validationErrors.push(y))}function N(t,n,i){0!==n&&t.size<n&&(t.validationErrors=t.validationErrors||[],-1===e.inArray(w,t.validationErrors)&&t.validationErrors.push(w)),0!==i&&t.size>i&&(t.validationErrors=t.validationErrors||[],-1===e.inArray(b,t.validationErrors)&&t.validationErrors.push(b))}function $(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 U(t){return!t.multiple&&e(".k-file",t.wrapper).length>1}function W(t,n,i,o){if(n._supportsRemove()){var a=t.data("fileNames");var 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){U(n)&&n._removeFileEntry(t),n.trigger(d,{operation:"remove",files:a,XMLHttpRequest:e}),r("Server response: "+e.responseText)})):n._removeFileEntry(t)}else!U(n)&&o||n._removeFileEntry(t)}function j(e,t,n){var i=!1,r="";try{r=JSON.parse(q(e)),i=!0}catch(e){n()}i&&t(r)}function q(e){return void 0!==e&&""!==e||(e="{}"),e}function G(e){e.originalEvent&&(e.originalEvent.dataTransfer.dropEffect="copy"),e.stopPropagation(),e.preventDefault()}function K(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 Y(e){return e.is(".k-file-progress, .k-file-success, .k-file-error:not(.k-file-invalid)")}function Q(t){return e(t.target).closest(".k-file")}P.prototype={onSelect:function(t,n){var i=this.upload;var r=this;var o=e(t.target);var a=this.prepareUpload(o,n);var s;var l;e.each(a,(function(t){s=i._filesContainValidationErrors(e(this.data("fileNames"))),i.options.async.autoUpload?s?(i._fileAction(this,v),i._showHeaderUploadStatus(!1)):i.options.async.chunkSize?(r.prepareChunk(this),l=this.prev(),(i.options.async.concurrent||0===t&&!l.length||0===t&&l.hasClass("k-file-success"))&&r.performUpload(this)):r.performUpload(this):(i._fileAction(this,v),s?i._updateHeaderUploadStatus():(i._showActionButtons(),this.addClass("k-toupload"))),s&&i._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=this.upload;var i;var r;var o=t.length;var a;var s;var l=[];if(!0===n.options.async.batch)i=e.map(t,(function(e){return e.name})).join(", "),(n.directory||n.options.directoryDrop)&&e(t).each((function(){(this.rawFile.webkitRelativePath||this.rawFile.relativePath)&&(this.name=this.rawFile.webkitRelativePath||this.rawFile.relativePath)})),(s=n._enqueueFile(i,{fileNames:t})).data("files",t),l.push(s);else for(r=0;r<o;r++)i=(a=t[r]).name,(n.directory||n.options.directoryDrop)&&(a.rawFile.webkitRelativePath||a.rawFile.relativePath)&&(a.name=a.rawFile.webkitRelativePath||a.rawFile.relativePath),(s=n._enqueueFile(i,{fileNames:[a]})).data("files",[a]),l.push(s);return l},performUpload:function(t){var n,r=this.upload,o=this.createFormData(),a=this.createXHR(),s={files:t.data("fileNames"),XMLHttpRequest:a};var c=t.find(".k-file-validation-message");var d=t.find(".k-file-summary");var h=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,u,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"):h.length>0&&h.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;var a=o.upload;var s=i.data("files")[0];var 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;var n=t.upload;e(".k-toupload",this.element).filter((function(){var t=e(this);var i=Y(t);var r=n._filesContainValidationErrors(t.data("fileNames"));return!i&&!r})).each((function(i){var r=e(this);var 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=Q(e);this.upload.options.async.chunkSize&&(this.cancelled[t.data("uid")]=!0),this.stopUploadRequest(t),this.removeFileEntry(t)},onPause:function(e){var t=Q(e).data("uid");var 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=Q(e);var 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=Q(e);var 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;var r=Q(e);var o=this.upload.options.async;o.chunkSize&&(this.retries[r.data("uid")]=o.maxAutoRetries+1),r.hasClass("k-file-success")?W(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;var i;var r=t.length;var o;var a=this.upload;if(a.options.async.chunkSize){o=t[0].uid,n=this._getCurrentChunk(t[0].rawFile,o),e.append(a.options.async.saveField||a.name,n);var s=JSON.stringify(this.metaData[o]);e.append("metadata",s)}else for(i=0;i<r;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?j(i.responseText,(function(t){var o=r.upload.options.async.batch;var a=r.upload.options.async.chunkSize;var s=r.upload.options.async.concurrent;var 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;var n=this.upload.options.async.concurrent;var 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=Math.round(100*t.loaded/t.total);var r=n.data("uid");var o;this.upload.options.async.chunkSize&&(i=(o=this.metaData[r])&&o.totalChunks?Math.round(o.chunkIndex/o.totalChunks*100):100),this.upload._onFileProgress({target:e(n,this.upload.wrapper)},i)},stopUploadRequest:function(e){e.data("request")&&e.data("request").abort()},prepareChunk:function(e){var t=e.data("files")[0];var n=t.rawFile;var i=t.uid;var 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=this.position[t];var i;var r=this.upload.options.async;var o=r.chunkSize||r.bufferChunkSize;return this.position[t]||(this.position[t]=0),this.position[t]+=o,(i=this._getChunker(e))?e[i](n,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){var t=window.kendo,n=t.ui.Widget,i=".kendoButtonMenu",r=t.ui,o=t.keys,a=t.htmlEncode,s=t.sanitizeLink,l=e.extend,c=".",d="id",h="next",u="k-disabled",p="k-hidden",f="aria-disabled",m="tabindex",g="click",v="menuClick",_="menuOpen",b="menuClose",w="keydown",y="focus",k={down:{origin:"bottom left",position:"top left"},up:{origin:"top left",position:"bottom left"}};var x="k-menu-popup",C="k-menu-group",S="k-item k-menu-item",T="k-menu-item",M="k-menu-link-text",A="k-link k-menu-link",D="k-sprite",E="k-image";var I={text:null,icon:null,url:null,attributes:null,enabled:!0,hidden:!1,id:null,imageUrl:null,spriteCssClass:null};var z=({imageUrl:e})=>""+(e?`<img alt="icon" class="${E}" src="${a(e)}" />`:"");var P=({spriteCssClass:e})=>""+(e?`<span class="${D} ${a(e)}"></span>`:"");var L=({icon:e})=>`${e?t.ui.icon(a(e)):""}`;var B=({text:e})=>""+(e?`<span class="${M}">${a(e)}</span>`:"");var H=({imageUrl:e,spriteCssClass:t,icon:n,text:i})=>`<span class="${A}">${z({imageUrl:e})}${P({spriteCssClass:t})}${L({icon:n})}${B({text:i})}</span>`;var R=({url:e,imageUrl:t,spriteCssClass:n,icon:i,text:r,attributes:o})=>`<a href="${s(e)}" ${o&&o.target?`target="${o.target}"`:""} class="${A}">${z({imageUrl:t})}${P({spriteCssClass:n})}${L({icon:i})}${B({text:r})}</a>`;function F(t,n){var i=n===h?e.fn.next:e.fn.prev;var r=n===h?e.fn.first:e.fn.last;var o=i.call(t);var a=":kendoFocusable";return o.length||(o=r.call(t.parent().find(c+T))),o.is(a)||!o.length?o:o.find(a).length?r.call(o.find(a)):F(o,n)}var O=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:[v,_,b],_renderList:function(){var n=this,i=n.options.items,r=n.element.addClass(x),o=n.mainButton.attr(d)||t.guid(),a=e('<ul role="menu"></ul>').addClass(C);n.list=a.appendTo(r),n.list.attr(d,o+"_buttonmenu"),i.forEach(n._renderListItem.bind(n)),n.list.find(c+T+":first-child").addClass("k-first"),n.list.find(c+T+":last-child").addClass("k-last")},_renderListItem:function(n){var i,r,o=this,a=n.attributes?n.attributes.id:null;i=(n=l({},I,n,{enabled:n.enable&&n.enabled})).id||a||t.guid(),r=e('<li id="'+i+'" role="menuitem" class="'+S+'">'+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(H)(e)},_initPopup:function(){var e=this,t=e.options,n=t.direction||"down";e._popup=new r.Popup(e.element,l({},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)},k[n]))},_popupOpenHandler:function(e){this.trigger(_)?e.preventDefault():this.list.find(c+T).attr(m,0)},_popupCloseHandler:function(e){this.trigger(b)&&e.preventDefault(),this.list.find(c+T).attr(m,-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(g+i,c+T,e._click.bind(e)).on(w+i,c+T,e.listItemKeydown.bind(e)),e.mainButton.on(w+i,e._keydown.bind(e))},_keydown:function(t){if(!e(t.target).is(c+u)&&!e(t.target).parents(c+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?F(i,h).trigger(y):t.keyCode===o.UP?F(i,"prev").trigger(y):i.is(c+u)||t.keyCode!==o.SPACEBAR&&t.keyCode!==o.ENTER?t.keyCode===o.HOME?n.list.find(":kendoFocusable").filter(c+T).first().trigger(y):t.keyCode===o.END&&n.list.find(":kendoFocusable").filter(c+T).last().trigger(y):i.trigger(g)},_click:function(t){var n=this,i=e(t.target).closest(c+T),r=i.attr(d);n._clickHandlers[r]&&n._clickHandlers[r](t),n.trigger(v,{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(f):t.attr(f,!e)},_hide:function(e,t){(t=t&&t.length?this.list.find(t):this.items()).toggleClass(p,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(.${p})`).length&&this._popup.open())},close:function(){this._popup.close()},items:function(){return this.list.children(c+T)},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(O)}(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",h="aria-label",u="aria-expanded",p="disabled",f="k-disabled",m="k-focus",g="click",v="open",_="close",b="focus";var w="k-split-button k-button-group";var y=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="'+w+'"></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(u,!n&&null),t.attr("aria-controls",n?n.list.attr(c):null),t.attr(h)||t.attr(h,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(u,!0))},menuCloseHandler:function(e){var t=this;t.trigger(_,{target:t.element})?e.preventDefault():(t.element.attr(u,!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(y)}(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",h="aria-expanded",u="disabled",p="k-disabled",f="click",m="open",g="close",v="focus";var _="k-menu-button";var b=n.extend({init:function(i,r){var o=this;r.enabled=!1!==r.enabled&&!e(i).prop(u),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(h,!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(h,!0))},menuCloseHandler:function(e){var t=this;t.trigger(g,{target:t.element})?e.preventDefault():(t.element.attr(h,!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(u,!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.Button,r="click",o="toggle",a="aria-pressed",s="k-selected";var 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,toggleIcon:"",applySelectedState:!0,applyToggleIcon:!1},toggle:function(e){let n=this;e===t&&(e=!this._selected),this._selected=e,!0===e?(this.element.attr(a,!0),this.options.applySelectedState&&this.element.addClass(s),this.options.applyToggleIcon&&this.options.toggleIcon&&n._updateIcon(n.options.toggleIcon)):!1===e&&(this.element.attr(a,!1),this.options.applySelectedState&&this.element.removeClass(s),this.options.applyToggleIcon&&n._updateIcon(n.options.icon))},_updateIcon:function(e){let t=this.element.find(".k-icon, .k-svg-icon");t.length&&n.ui.icon(t,{icon:e})},_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;var n=t.ui;var i=n.Widget;var r=n.ToggleButton;var o=n.Button;var a=t.keys;var s=".kendoButtonGroup";var l="k-button";var c="k-selected";var d="k-disabled";var h="select";var u="aria-disabled";var p=".";var f="none";var m="single";var g="multiple";var v="focus";var _=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(u,!0).addClass(d),n._buttons.forEach((e=>{e.enable(!1)}))),n.options.selection!==f&&n.select(n.options.index),n._attachEvents()},events:[h],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(u,!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),h={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,h)),h.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="+t.sanitizeLink(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(h,{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,r=n._activeElement,o=n.support.touch&&n.support.mobileOS,a=Array.isArray,s=n.data.HierarchicalDataSource,l="mousedown",c="click",d=e.extend,h=e.each,u=n.htmlEncode,p=n.template,f=n.keys,m=i.Widget,g=/^(ul|a|div)$/i,v=".kendoMenu",_="open",b="k-menu",w="k-link k-menu-link",y=".k-link",k=".k-menu-expand-arrow",x="k-last",C="close",S="timer",T="k-first",M="k-image",A="select",D="zIndex",E="activate",I="deactivate",z="touchstart"+v+" MSPointerDown"+v+" pointerdown"+v,P=n.support.pointers,L=n.support.msPointers,B=L||P,H="change",R="error",F=n.support.touch?"touchstart":"",O=P?"pointerover":L?"MSPointerOver":"mouseenter",V=P?"pointerout":L?"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",icon:"dataIconField",iconClass:"dataIconClassField",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="";var n=e.attr||{};for(var i in n)n.hasOwnProperty(i)&&"class"!==i&&(t+=i+'="'+n[i]+'" ');return t},imageCssAttributes:function(e){var t="";var n=e&&e.toJSON?e.toJSON():{};for(var i in n.class?n.class+=" "+M:n.class=M,n)n.hasOwnProperty(i)&&(t+=i+'="'+n[i]+'" ');return t},contentCssAttributes:function(e){var t="";var n=e.contentAttr||{};var 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 w},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:" "}};function he(t,n){try{return e.contains(t,n)}catch(e){return!1}}function ue(t){(t=e(t)).attr(n.attr("omit-wrap"))||(t.addClass("k-item k-menu-item").children("img").addClass(M),t.children("a").addClass(w).children("img").addClass(M),t.filter(":not([disabled])"),t.filter(".k-separator").removeClass("k-menu-item").addClass("k-separator-horizontal").empty().append(" "),t.filter("li[disabled]").addClass(Y).prop("disabled",!1).attr("aria-disabled",!0),t.filter("[role]").length||t.attr(le,"menuitem"),t.children(y).length||t.contents().filter((function(){return!(this.nodeName.match(g)||3===this.nodeType&&!n.trim(this.nodeValue))})).wrapAll("<span class='"+w+"' 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 we(e){var t=e?"[data-group='"+e+"']":"[data-group]";return"ul"+t+",div"+t}function ye(t,n){var i=t.find(be());var r=[];return i.each((function(i,o){var a=(o=e(o)).data(W);var s=t;for(;a;)(s=n.find(we(a)+":visible")).length&&r.push(s),(o=s.find(be()))&&o.length&&o.length>1?(r.push(...ye(s,n)),a=null):a=o.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(we(i)):e([])}function Ce(e,t){var n=0;var i=e.parentNode;for(;i&&!isNaN(i[t]);)n+=i[t],i=i.parentNode;return n}function Se(e){return B&&e.originalEvent&&e.originalEvent.pointerType in oe}function Te(e){e.contents().filter((function(){return"LI"!=this.nodeName})).remove()}var Me=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,autoSize:!1,iconPosition:"before"},_initData:function(){var e=this;e.dataSource&&(e.element.empty(),e.append(e.dataSource.view(),e.element))},_attachMenuEventsHandlers:function(){var t=this;var n=t.element;var i=t.options;var 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(F+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;var 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=this;var r="horizontal"==t.orientation;var o,a;const s=n.support.isRtl(i.wrapper);if(i._openedPopups={},t.scrollable){i._scrollWrapper=i.element.wrap(`<div class="k-menu-scroll-wrapper${"vertical"===t.orientation?" k-menu-scroll-wrapper-vertical":""}"></div>`).parent(),r&&Te(i.element);let n=r?s?"right":"left":"up";let d=r?s?"left":"right":"down";switch(o=e(i.templates.scrollButton({direction:n})),a=e(i.templates.scrollButton({direction:d})),t.scrollable.scrollButtonsPosition){case"start":a.prependTo(i._scrollWrapper),o.prependTo(i._scrollWrapper);break;case"end":o.appendTo(i._scrollWrapper),a.appendTo(i._scrollWrapper);break;default:o.prependTo(i._scrollWrapper),a.appendTo(i._scrollWrapper)}i._initScrolling(i.element,o,a,r,s);var l=i.element.outerWidth();var c=i.element[0].style.width;c="auto"===c?"":c,r&&e(window).on($,(function(){setTimeout((function(){i._setOverflowWrapperWidth(l,c),i._toggleScrollButtons(i.element,o,a,r)}),300)})),i._setOverflowWrapperWidth(l,c),i._toggleScrollButtons(i.element,o,a,r)}},_overflowWrapper:function(){return this._scrollWrapper||this._popupsWrapper},_setOverflowWrapperWidth:function(e,t){var n=this;var i=n._scrollWrapper.css("width");n._scrollWrapper.css({width:""});var r=n._scrollWrapper.outerWidth();n._scrollWrapper.css({width:i});var o=n.element.outerWidth();var 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.scrollable.scrollButtonsPosition!=t.options.scrollable.scrollButtonsPosition)||e.orientation!=t.options.orientation)&&(t._detachMenuEventsHandlers(),t._destroyOverflow(),t._initOverflow(e),t._attachMenuEventsHandlers())},_destroyOverflow:function(){var n=this;var 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(we()).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;var c=l.options.scrollable;var d=l.isNumeric(c.distance)?c.distance:50;var h=d/2;var u="-="+d;var p="+="+d;var f="-="+2*d;var m="+="+2*d;var g=!1;var _=!1;var 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)};var w=function(e){g||_||(b(e.data.direction),g=!0)};var y=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:u},w).on(n.eventMap.down+v,{direction:s&&a?m:f},y),r.on(O+v,{direction:s&&a?u:p},w).on(n.eventMap.down+v,{direction:s&&a?f:m},y),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);var o=(n>0?"+=":"-=")+Math.abs(n)*h;var 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);const 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();const 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);var 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 h(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 h(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 h(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,h={firstLevel:r.hasClass(b),horizontal:r.hasClass(b+"-horizontal"),expanded:!0,length:r.children().length};return i&&!r.length&&(r=e(l.renderGroup({group:h,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:h,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(){ue(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);var 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(H,(function(){e.find(k).children().removeClass("k-i-loading"),n._loading&&(n.open(e),n._loading=!1)}))},_createPopup:function(e,t){let i=this;let 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(D,t.data(D)),t.removeData(D),i.options.scrollable&&t.parent().siblings(re).css({zIndex:""}),(o||B||n.support.mouseAndTouchPresent)&&t.removeClass(G));e.sender.element.find("."+K).length&&i._removeFocusItem()}},t)).data(q)},open:function(i){var r=this;var o=r.options;var a="horizontal"==o.orientation;var s=o.direction;var l=n.support.isRtl(r.wrapper);var c=r._overflowWrapper();i=(c||r.element).find(i);var h=r.dataSource&&r.dataSource.getByUid(i.data(n.ns+"uid"));if(h&&h.hasChildren&&!h.loaded()&&!r._loading)return r._loading=!0,i.find(k).children().addClass("k-i-loading"),h.load(),void r._openAfterLoad(i,h);/^(top|bottom|default)$/.test(s)&&(s=l?a?(s+" left").replace("default","bottom"):"left":a?(s+" right").replace("default","bottom"):"right");var u=">.k-popup:visible,>.k-animation-container > .k-child-animation-container > .k-menu-popup:visible";var p=function(){e(this).data(q)&&r.close(e(this).closest("li.k-item"),!0)};return i.siblings().find(u).each(p),c&&i.find(u).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 h=i.find("> .k-menu-popup, > .k-animation-container > .k-child-animation-container > .k-menu-popup").filter(":hidden").first();var u;var p;if(!h[0]&&c&&(h=(p=r._getPopup(i))&&p.element),!h.is(":visible")&&h[0]&&!1===r._triggerEvent({item:i[0],type:_})){const p=h.children(".k-menu-scroll-wrapper").length?h.children(".k-menu-scroll-wrapper"):h;const _=r._groupElementsInitialSpace.find((({element:e})=>p.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:""}));const C=i[0].getBoundingClientRect();const S=(_&&_.inlineHeight||x)<=window.innerHeight-C.top;const T=o.scrollable||o.autoSize;const M=o.autoSize&&!S?"auto":"visible";h.css({maxHeight:T?"":x,overflow:M}),i.data(D,i.css(D));var f=r.nextItemZIndex++;i.css(D,f),r.options.scrollable&&i.parent().siblings(re).css({zIndex:++f}),u=h.data(q);var m,g=i.parent().hasClass(b),v=g&&a,w=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),y=o.animation.open.effects,k=y!==t?y:"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=h.data(q)).options.origin=w.origin,u.options.position=w.position,u.options.animation.open.effects=k):(u=r._createPopup(h,{origin:w.origin,position:w.position,collision:m,anchor:i,appendTo:c||i,animation:{open:d(!0,{effects:k},o.animation.open),close:o.animation.close}}),h.closest(X).removeAttr(le)),h.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;const s=a.children(".k-menu-scroll-wrapper");const l=s.length?e(s.children("ul")):e(a.children("ul"));let c=o._getNeededSpaceForChildren(l,i);let 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;let n=t.popup;let i=t._overflowWrapper();e(ye(n.element,i)).each((function(e,n){let r=i.find(be(n.data(U)));t.close(r)}))},_scrollButtonsMouseLeave:function(){let t=this;let 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"}));let 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(ye(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;var r=i._overflowWrapper();var 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=i._getPopup(o);if(n&&(a=o.data(W),!r||!a||!i._openedPopups[a.toString()]||i._forceClose)){if(!i._forceClose&&function(t){var n=!1;return e.isEmptyObject(i._openedPopups)||e(ye(t,r)).each((function(e,t){return!(n=!!i._openedPopups[t.data(U).toString()])})),n}(n.element))return;n.close(),n.element.attr("aria-hidden",!0),r&&i._forceClose&&t.last().is(o[0])&&delete i._forceClose}var a}),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);var n=this._overflowWrapper();if(!t&&n){var i=e.data(W);if(i)t=n.find(we(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==F)},_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()&&(he(o,n._activeElement())||!t||he(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((t=>{let i;let r=!1;let o=t.closest(".k-animation-container")||t.closest(".k-popup");return o=e(o),o&&o.length&&!o.is(":visible")&&(r=!0,o.show()),i={element:t,width:n._outerWidth(t),height:n._outerHeight(t),inlineHeight:t.style&&t.style.height?t.style.height:""},r&&o.hide(),i})),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);var 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(){ue(this)}))},_mouseenter:function(t){var n=this;var i=e(t.currentTarget);var r=n._itemHasChildren(i);var a=i.data(W)||i.closest(J).data(U);var s=Se(t);var 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))||!he(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;var 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;var r=e(t.currentTarget);var a=r.data(W);var s=r.children(J).length||a;var 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)||he(t.currentTarget,t.relatedTarget||t.target)||!s||he(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;var i=n._overflowWrapper();var 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;var i=n._overflowWrapper();e(ye(t,i)).each((function(){var e=i.find(be(this.data(U)));n.close(e,!0)}))},_innerPopup:function(e){var t=ye(e,this._overflowWrapper());return t[t.length-1]||e},_closeParentPopups:function(e){var t=this;var n=t._overflowWrapper();var 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],h=c[0]?c[0].nodeName.toUpperCase():"",u="INPUT"==h||"SELECT"==h||"BUTTON"==h||"LABEL"==h,p=c.closest(y),f=c.closest(ee),m=f[0],g=p.attr("href"),v=c.attr("href"),b=e("<a href='#' />").attr("href"),w=!!g&&g!==b,k=w&&!!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)||u||t.preventDefault(),t.handled=!0,r=f.children(J),S){var T=f.data(W);T&&(r=S.find(we(T)))}if(o=r.is(":visible"),a=l.openOnClick&&o&&s._isRootItem(f),l.closeOnClick&&(!w||k)&&(!r.length||a)){f.removeClass(G).css("height"),s._oldFocusItem=s._findRootParent(f);var M=s._parentsUntil(p,s.element,ee);return s._forceClose=!!S,s.close(M),void(s.clicked=!1)}w&&t.enterKey&&p[0].click(),(s._isRootItem(f)&&!1!==l.openOnClick||l.openOnClick.subMenuItems||n.support.touch||Se(t)&&s._isRootItem(f.closest(ee)))&&(w||u||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=[];var r=function(e){for(;e.parentNode&&!n.is(e.parentNode);)i.push(e.parentNode),e=e.parentNode};var o=t[0]||t;r(o);var a=i[i.length-1];for(;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);var 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();var 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;var r=e(n.target).closest("span").parent().hasClass("k-menu-expand-arrow")?i._lastClickedElement:n.target;he((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(we(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=e.parent();var r=!!i.hasClass(b)&&"horizontal"==t.options.orientation;var o=r?"scrollLeft":"scrollTop";var a=r?n._outerWidth:n._outerHeight;var s=i[o]();var l=a(e);var c=e[0][r?"offsetLeft":"offsetTop"];var d=a(i);var h=i.siblings(re);var u=h.length?a(h.first()):0;var p;if(s+d<c+l+u?p=c+l-d+u:s>c-u&&(p=c-u),!isNaN(p)){var f={};f[o]=p,i.finish().animate(f,"fast","linear",(function(){t._toggleScrollButtons(i,h.first(),h.last(),r)}))}}},_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");var 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:"icon"},{field:"iconClass"},{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(H,this._refreshHandler),this.dataSource.bind(R,this._errorHandler)},_unbindDataSource:function(){var e=this.dataSource;e&&(e.unbind(H,this._refreshHandler),e.unbind(R,this._errorHandler))},_error:function(){},findByUid:function(e){return(this._overflowWrapper()||this.element).find("["+n.attr("uid")+"="+e+"]")},refresh:function(e){var t=this;var n=e.node;var i=e.action;var r=n?t.findByUid(n.uid):t.element;var o=e.items;var a=e.index;var s=t._updateItem.bind(t);var 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;var n=t.findByUid(e.uid);var i=n.next();var 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=u(t)),`<span class='k-menu-link-text' role='none'>${t}</span>`}))),t.templates={content:p((e=>{var t=e.item;var n=r("content")(t);var 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;var i=this.options.iconPosition;var o=r("url")(t);var a=r("imageUrl")(t);var s=r("icon")(t);var l=r("iconClass")(t);var c=this.templates.sprite(t);var d=(s||l)&&""==c?n.ui.icon({icon:s,iconClass:l}):"";var h=r("imageAttr")(t);var u=o?"a":"span";return`<${u} class='${de.textClass(t)}' role='none' ${o?`href='${n.sanitizeLink(o)}'`:""} >`+(a?`<img ${de.imageCssAttributes(h)} alt='' src='${a}' />`:"")+("before"==i?d:"")+c+this.options.template(e)+("after"==i?d:"")+e.arrow(e)+`</${u}>`})),item:p((t=>{var i=t.item,o=t.menu,a=t.group,s=t.subGroup;var l=r("content")(i);var 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){var t="",n=0,i=e.items,r=i?i.length:0,o=d({length:r},e.group);for(;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))}});var Ae=Me.extend({init:function(t,i){var r=this;Me.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;Me.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(),Me.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(),Me.fn.destroy.call(e),e.popup&&e.popup.destroy()},open:function(i,r,o){var a=this;const s="horizontal"===a.options.orientation;let l=null;if("number"==typeof(i=e(i)[0])&&(a._initialInlineHeight?e(a.element).css({height:a._initialInlineHeight}):e(a.element).css({height:""})),o&&(l=e(i)),he(a.element[0],e(i)[0])||a._itemHasChildren(e(i)))Me.fn.open.call(a,i);else{if(!1!==a._triggerEvent({item:a.element,type:_,target:l}))return;if(a.popup.visible()&&a.options.filter&&(a.popup.close(!0),a.popup.element.parent().kendoStop(!0)),a._triggerFocusOnActivate||(a._triggerFocusOnActivate=a._focusMenu.bind(a)),a.bind(E,a._triggerFocusOnActivate),r!==t){var c=a._overflowWrapper();if(c){var d=c.offset();i-=d.left,r-=d.top}a.popup.wrapper.hide(),a._configurePopupScrolling(i,r),a.popup.open(i,r)}else a.popup.options.anchor=i||a.popup.anchor||a.target,a.popup.element.kendoStop(!0),a._configurePopupScrolling(),a.popup.open();a._initPopupScrolling(a.popup,s),a.popup.element.siblings(re).hide(),j.off(a.popup.downEvent,a.popup._mousedownProxy),j.on(n.support.mousedown+v+a._marker,a._closeProxy)}return a},_focusMenu:function(){var e=this;e.unbind(E,e._triggerFocusOnActivate),e.element.trigger("focus")},_configurePopupScrolling:function(e,n){var i=this;var r=i.popup;var 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;var o=r.add(r.parent(Z));o.width(this._initialWidth||"");var a=t._location(i);var s=e(window).width();var l=a.width;var c=Math.max(a.left,0);var d=i?0:Ce(this._overflowWrapper()[0],"scrollLeft");var h=n.getShadows(r);var u=s-h.left-h.right;u+d>l+c||o.css({overflow:"hidden",width:u-c+d+"px"})},close:function(){var t=this;he(t.element[0],e(arguments[0])[0])||t._itemHasChildren(arguments[0])?Me.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),he(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=he(n.element[0],i[0])||s&&he(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.options.keyboardAlignToAnchor&&(e.popup.options.anchor=t.target),e.open(t.target,null,!0))})))},_triggerEvent:function(n){var i=this,r=e(i.popup.options.anchor)[0],o=i._eventOrigin,a=n.target;return i._eventOrigin=t,i.trigger(n.type,d({type:n.type,item:n.item||this.element[0],target:a??r},o?{event:o}:{}))},_popup:function(){var t=this;var n=t._overflowWrapper();var 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(ye(t.sender.element,n)).each((function(e,t){var n=t.data(q);n&&n.close(!0)}))}:e.noop}).data(q),t._targetChild=he(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()||[];Me.fn._focus.call(this,e),r()===e.currentTarget&&this._moveFocus(t,this.wrapper.children().filter(":visible").not(".k-separator").first())}});i.plugin(Me),i.plugin(Ae)}(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",h="k-split-button",u="k-menu-button",p="k-toolbar-separator k-separator",f="k-spacer",m="k-selected",g="k-disabled",v="k-hidden",_="k-force-hidden",b="k-group-start",w="k-group-end",y="k-menu-link",k="k-menu-item",x="k-toolbar-overflow-button",C="k-toolbar-item",S="k-menu-link-toggle",T="k-dropdownlist",M="k-input-button",A="k-focus",D="[tabindex=-1]",E="toolbar-tool",I="aria-checked",z="aria-label",P="change",L="click",B="toggle",H="open",R="close",F="focus",O="keydown",V="spacer",N="role",$="ref-",U="separator",W="overflow",j="tabindex",q="input",G="select",K="group",Y="data-uid",Q="[data-role]",X="[data-toggle]",Z="[data-role=buttonmenu]",J="[ref-toolbar-tool]",ee=":kendoFocusable:not([class*='pager'])",te="overflowOpen",ne="overflowClose",ie="never",re="auto",oe="always",ae=n.attr("uid"),se="",le="_",ce=" ",de=".",he=",",ue="id",pe="uid",fe="kendoDropDownButton",me="kendoSplitButton",ge="kendoToggleButton",ve="kendoButtonGroup";n.toolbar={};var _e={button:"Button",splitButton:"SplitButton",dropDownButton:"DropDownButton",buttonGroup:"ButtonGroup",popupButton:"Button",open:"Button"};var be={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"};var we=["Button","SplitButton","DropDownButton","ButtonGroup","Switch","ColorPicker"];var ye=`<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>`;var ke='<div role="separator"> </div>';var xe=i.extend({init:function(t,r){if(i.fn.init.call(this,t,r),r=this.options,this._isRtl=n.support.isRtl(t),this.uid=n.guid(),(t=this.wrapper=this.element).attr(ae,this.uid),t.addClass("k-toolbar"),t.attr(N,l),r.resizable?(this.hasOverflowButton=["section","menu"].includes(this.options.overflow?.mode),this._resizable()):r.overflow=e.extend({},r.overflow,{mode:"none"}),r.tools&&r.tools.length>0&&(r.items=this._extendToolsOptions()),r.items&&r.items.length&&this._items(),this._scrollable(),this._attachEvents(),this._tabIndex(),this._applyCssClasses(),r.resizable)if(this.hasOverflowButton){let e=this.element.find("> .k-toolbar-items").length>0?this.element.find("> .k-toolbar-items")[0].offsetWidth:this.element.innerWidth();this._shrink(e),this.overflowAnchorSeparator?.appendTo(this.wrapper),this.overflowAnchor?.appendTo(this.wrapper),this._toggleOverflowAnchor()}else this._toggleScrollButtons();n.notify(this)},events:[L,B,H,R,te,ne,P],options:{name:"ToolBar",items:[],resizable:!0,navigateOnTab:!1,evaluateTemplates:!1,size:"medium",fillMode:"solid",overflow:{mode:"menu",scrollButtons:"auto",scrollButtonsPosition:"split",scrollDistance:200}},destroy:function(){var t=this;t.options.resizable&&(n.unbindResize(t._resizeHandler),t.overflowMenu?.destroy?.(),t.overflowSection?.destroy?.()),"scroll"==t.options.overflow?.mode&&(t.element.find("> .k-toolbar-items").unbind("scroll"+s),t._removeScrollableClasses()),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())})),t.element.off(s),t.element.removeAttr(Y),n.destroy(t.element.children()),i.fn.destroy.call(t)},add:function(e){this._add(e),this.options.resizable&&this.resize(!0)},_scrollableAllowed:function(){const e=this.options;return e.overflow&&"scroll"==e.overflow.mode&&!e.overflow.scrollDistance&&(e.overflow.scrollDistance=200),"scroll"==e.overflow?.mode&&!isNaN(e.overflow.scrollDistance)},_getScrollButtonHtml:function(t,i){return n.html.renderButton(e(`<span class="k-toolbar-${t}"></span>`),{icon:i,type:"",size:this.options.size})},_getChildrenWidth:function(t){let n=0;return t.children().each((function(){n+=a(e(this))})),Math.floor(n)},_removeScrollableClasses:function(){const e=this;const t="hidden"===e.options.overflow.scrollButtons;e.element.removeClass("k-toolbar-scrollable"),t&&(e.element.removeClass("k-toolbar-scrollable-overlay"),e.element.removeClass("k-toolbar-scrollable-start"),e.element.removeClass("k-toolbar-scrollable-end"),e.element.removeClass("k-toolbar-items-scroll"))},_scrollable:function(){const e=this,t=e.element,i=e.options,r=i.overflow.scrollButtonsPosition,o="hidden"===i.overflow.scrollButtons;if(e._scrollableAllowed()){let a,l;e.element.addClass("k-toolbar-scrollable");let c=!0;e.element.wrapInner(`<div class="k-toolbar-items ${c?"k-toolbar-items-scroll":""}"></div>`);const d=t.find("> .k-toolbar-items");const h=e.element[0].offsetWidth;const u=d[0].scrollWidth;const p=e._getChildrenWidth(d)>d.outerWidth();const f=u>h||p;if(f&&!e._scrollableModeActive&&o)e.element.addClass("k-toolbar-items-scroll"),e.element.addClass("k-toolbar-scrollable-overlay"),e._scrollableModeActive=!0,e._toggleScrollButtons();else if(!f&&o||e._scrollableModeActive)e._scrollableModeActive&&!f&&o?(e._scrollableModeActive=!1,e._removeScrollableClasses(),e._scrollPrevButton&&e._scrollPrevButton.off().remove(),e._scrollNextButton&&e._scrollNextButton.off().remove()):!e._scrollableModeActive&&o?e._removeScrollableClasses():e._toggleScrollButtons();else{e._nowScrollingTabs=!1,e._isRtl=n.support.isRtl(e.element);const t=n.support.touch?"touchstart":"mousedown";const o=n.support.touch?"touchend":"mouseup";const c=n.support.browser;const d=e._isRtl&&!c.msie&&!c.edge;const h=e._isRtl?"caret-alt-right":"caret-alt-left";const u=e._isRtl?"caret-alt-left":"caret-alt-right";const p=this._getScrollButtonHtml("prev",h);const f=this._getScrollButtonHtml("next",u);switch(r){case"split":e.element.prepend(p),e.element.append(f);break;case"start":e.element.prepend(f),e.element.prepend(p);break;case"end":e.element.append(p),e.element.append(f)}a=e._scrollPrevButton=e.element.children(".k-toolbar-prev"),l=e._scrollNextButton=e.element.children(".k-toolbar-next"),a.on(t+s,(function(){e._nowScrollingTabs=!0,e._scrollTabsByDelta(i.overflow.scrollDistance*(d?1:-1))})),l.on(t+s,(function(){e._nowScrollingTabs=!0,e._scrollTabsByDelta(i.overflow.scrollDistance*(d?-1:1))})),a.add(l).on(o+s,(function(){e._nowScrollingTabs=!1,e._toggleScrollButtons()})),e._scrollableModeActive=!0,e._toggleScrollButtons()}}},_scrollTabsByDelta:function(e){const t=this;const i=t.element.find("> .k-toolbar-items");let r=n.scrollLeft(i);const o=n.support.browser;t._isRtl&&(o.mozilla||o.webkit&&o.version>=85)&&(r*=-1);const a={scrollLeft:r+e};i.finish().animate(a,"fast","linear",(function(){t._nowScrollingTabs&&!jQuery.fx.off&&t._scrollTabsByDelta(e)}))},_toggleScrollButtons:function(e){const t=this;if(!t._scrollableAllowed())return;let i=t.element.find("> .k-toolbar-items"),r=Math.floor(n.scrollLeft(i)),o=t.options.overflow.scrollButtons;const a=Math.abs(r-(i[0].scrollWidth-i[0].offsetWidth))<=1;const s=0===r;if("hidden"!==o){if(t._scrollPrevButton.toggleClass(g,s),t._scrollNextButton.toggleClass(g,a),"auto"===o){const n=e||i[0].scrollWidth-i[0].offsetWidth<=1;t._scrollPrevButton.toggleClass(v,n),t._scrollNextButton.toggleClass(v,n)}}else t.element.toggleClass("k-toolbar-scrollable-start",s),t.element.toggleClass("k-toolbar-scrollable-end",a)},enable:function(t,i){var r,o,a=this,s=this._getUid(t),l=this._getItem(t,s),c=this._getOverflowItem(t,s),d=l.component;function h(e){e.component?(o=d.wrapper,r=o.hasClass(A)||o.is(":focus"),d.enable(i),o.find("[disabled]").removeAttr("disabled"),o.removeAttr("disabled"),r&&o.addClass(A).trigger(F)):e.buttonsPopupItem.length>0&&n.widgetInstance(e.buttonsPopupItem.closest(".k-menu-popup")).enable(i,e.buttonsPopupItem)}void 0===i&&(i=!0),this.overflowSection&&c&&h(c),l&&(h(l),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(de+m)},hide:function(t){var n,i,r=this,o=this._getUid(t),a=r._getItem(t,o),s=r._getOverflowItem(t,o);function l(e,t){(n=e.templateEl.add(e.toolbarEl).add(e.buttonsPopupItem).add(e.menuItem)).addClass(v),n.addClass(_),i=e.toolbarEl.parent().closest(de+d),i.data(ve)&&(0===i.children(":not(.k-hidden)").length?r.hide(i):r._groupVisibleButtons(i)),n.find("[tabindex=0]").addBack("[tabindex=0]").length>0&&r._resetTabIndex(r._getAllItems(t).first())}(a||s)&&(this.overflowSection&&s&&l(s,!0),a&&(l(a),this.overflowMenu&&this.overflowMenu.element.find("[data-parentuid="+o+"]").each(((t,n)=>{e(n).addClass(_),e(n).addClass(v)}))),this.options.resizable&&this.resize(!0))},remove:function(t){var n,i=this,r=this._getUid(t),o=this._getItem(t,r),a=this._getOverflowItem(t,r);function s(t){t.component&&((n=t.toolbarEl.closest('[data-role="buttongroup"]')).length>0&&0===t.toolbarEl.siblings().length?(n.data(ve).destroy(),n.remove(),t.toolbarEl=e(se)):t.component.destroy()),t.templateEl.length>0?t.templateEl.remove():t.toolbarEl.length>0&&t.toolbarEl.remove(),t.buttonsPopupItem.length>0&&t.buttonsPopupItem.remove()}(o||a)&&(this.overflowSection&&a&&s(a),o&&(s(o),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,o=this._getUid(t),a=this._getItem(t,o),s=this._getOverflowItem(t,o);function l(e){(n=e.templateEl.add(e.toolbarEl).add(e.buttonsPopupItem)).removeClass(_),n.removeClass(v),i=e.toolbarEl.parent().closest(de+d),i.data(ve)&&(i.hasClass("k-hidden")&&i.children(":not(.k-hidden)").length>0?r.show(i):r._groupVisibleButtons(i))}this.overflowSection&&s&&l(s),a&&(l(a),a.menuItem.removeClass(_),this.overflowMenu&&this.overflowMenu.element.find("[data-parentuid="+o+"]").each(((t,n)=>{e(n).removeClass(_)}))),this.options.resizable&&this.resize(!0)},toggle:function(n,i){var r=this._getItem(n),o=this._getOverflowItem(n),a=r.menuItem;function s(t){const n=t.toolbarEl;const r=n.data(ge);if(!t.component&&0===a.find(de+S).length)return;const o=n.data(K);if(t.component){const t=n.closest(de+d).data(ve);if(t&&n.hasClass(m)!==i&&t._toggleIndex(n.index()),r.toggle(i),i){n.closest(".k-toolbar,.k-toolbar-popup").find("[data-group="+o+"]").each(((t,i)=>{i!==n[0]&&e(i).data(ge).toggle(!1)}))}}}if(i===t&&(i=!0),this.overflowSection&&o&&s(o),r&&(s(r),a)){const t=r.toolbarEl.data(K);if(a.attr(I,i).find(de+S).toggleClass(m,i),i&&this.overflowMenu){this.overflowMenu.element.find("[data-group="+t+"]").each(((t,n)=>{n!==a[0]&&e(n).attr(I,!1).find(de+S).removeClass(m)}))}}},toggleTools:function(t){var i=this,r=i.element.find(X),o=i.element.find(ee).not(D);r.each((function(r,o){var a=e(o),s=null,l=a.data(B),c=t&&t[l];a.is(Q)&&(s=n.widgetInstance(a)),s&&s.enable?s.enable(c||!1):i.enable(a,c)})),i.element.find(X+"[disabled]").removeAttr("disabled"),i.element.find(ee).not(D).attr("tabindex",-1),o.attr(j,0)},_generateToolElement:function(e,t,i,r){let o;return e||t?o=this._addTemplate(r):n.ui[r.component]?o=this._addCustomWidget(r):i?o=this._addDefaultTool(i,r):r.type===V?this._addSpacer():r.type===U&&this._addSeparator(r),o},_add:function(e){var t=this._processOptions(e),n=t.template,i=t.overflowTemplate,r=_e[t.type];let o;if(t.overflow===oe&&"menu"!=this.options.overflow?.mode||(o=this._generateToolElement(n,i,r,t),o&&t.overflow!==oe&&(this.overflowAnchor&&this.overflowAnchorSeparator?o.insertBefore(this.overflowAnchorSeparator):o.appendTo(this.element),o.find("[disabled]").removeAttr("disabled"),o.is("[disabled]")&&o.removeAttr("disabled"))),"section"==this.options.overflow?.mode&&t.overflow!==ie){if(t.type===V)return this._addSpacer(this._overflowSectionContentElement());if(t.type===U)return;let e=this._generateToolElement(n,i,r,t);e&&(this._overflowSectionContentElement().append(e),t.overflow!==oe&&e.addClass(v),e.find("[disabled]").removeAttr("disabled"),e.is("[disabled]")&&e.removeAttr("disabled"),e.attr("ref-section-tool",o?.attr("data-uid")||""))}},_addAttributes:function(e,t){var n=e.attributes,i=se;n||(n={}),e.hidden&&(i=v+ce+_),e.align&&(i=i+" k-align-"+e.align),n&&(n.class&&(i=i+ce+n.class,delete n.class),t.attr(n)),t.addClass(i),t.attr(ae,e.uid),e.id&&t.attr(ue,e.id),e.overflow===ie&&t.attr("data-overflow",ie),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[z]),t.componentOptions||(t.componentOptions={}),t.componentOptions.size=this.options.size,i=new n.ui[t.component](a,t.componentOptions),we.indexOf(t.component)>-1?(i.wrapper.addClass(be[t.component]).attr($+E,""),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;let o=this;return(n.overflow!==oe||o.overflowSection&&n.overflow!==ie)&&(i=o._addToolbarTool(t,e.extend(!0,{},n))),o.overflowMenu&&n.overflow!==ie&&(n.overflowComponent?(delete(r=e.extend(!0,{},n,n.overflowComponent))["data-command"],o._addMenuItem("Button",r)):o._addMenuItem(t,e.extend(!0,{},n))),i},_addMenuItem:function(n,i){var r,o=this,a=i.selected;return delete i.selected,i.id&&(i.id=i.id+le+W),i.showIcon===l&&(delete i.imageUrl,delete i.icon),i.showText===l?(i.attributes||(i.attributes={}),i.attributes[z]=i.text,i.text=se):i.text!==t&&i.text!==se||(i.text=" ",i.encoded=!1),o.overflowMenu?.append(i),r=o.overflowMenu.element.find(de+k).last(),"ToggleButton"===n||"Button"===n&&!0===i.togglable?(r.find(de+y).addClass(S),a&&r.find(de+y).addClass(m),i.group&&r.attr("data-group",i.group)):i.menuButtons?i.menuButtons.forEach((e=>{e.overflow=i.overflow,o._addMenuItem(null,e)})):i.buttons&&(r.remove(),r=null,i.buttons.forEach((t=>{var n=t.attributes;t.overflow=i.overflow,t.attributes=e.extend(n,i.attributes),o._addMenuItem("Button",t)}))),"DropDownButton"===n&&(r.addClass(g),r.attr("aria-disabled",!0)),r&&(o._addAttributes(i,r),i.overflow===re&&r.addClass(v),(i.click||i.toggle)&&o.overflowMenu.bind(G,(e=>{e.item===r[0]&&this._onMenuItemSelect(e,i.click,i.toggle)}))),r},_addPopupButton:function(t){var n,i,r=this,o=e(ye),a=t.popupComponent;return o.attr(z,t.text),n=e("<div/>").appendTo(e("<body>")).kendoPopup({anchor:o}).data("kendoPopup"),o.on(L+" touchend",(e=>{n.toggle(),e.preventDefault()})),(i=new a(n.element)).bind(t.commandOn,(e=>{r.trigger(P,{target:o,value:e.value||e}),n.close()})),{widgetElement:o,chooser:i,popup:n}},_addSeparator:function(t){var n=e(ke),i=e("<li role='separator' class='k-separator k-menu-separator k-hidden'></li>");const r=t.id;if(n.addClass(p),n.attr(N,U),this.overflowAnchor&&this.overflowAnchorSeparator?n.insertBefore(this.overflowAnchorSeparator):n.appendTo(this.element),this._addAttributes(t,n),t.id&&(t.id=t.id+le+W),this._addAttributes(t,i),this.overflowMenu&&this.overflowMenu.element.append(i),this.overflowSection){const n=e(ke).addClass(p).addClass(v).attr(N,U).attr("ref-section-tool",t.uid);let i=r?e.extend(!0,t,{id:r+le+"section-overflow"}):t;this._addAttributes(i,n),this._overflowSectionContentElement().append(n)}},_addSpacer:function(t){var n=e("<div> </div>");n.addClass(f),this.overflowAnchor&&this.overflowAnchorSeparator?n.insertBefore(this.overflowAnchorSeparator):n.appendTo(t||this.element)},_overflowSectionContentElement:function(){return this.overflowSection?.element.find(".k-toolbar-items-list")},_addTemplate:function(t){var i,o,a=t.template,s=t.overflowTemplate,l=e(se);return s&&this.overflowMenu&&t.overflow!==ie&&(s=r(s)?s(t)[0]:s,this.overflowMenu.append({}),o=this.overflowMenu.element.find(de+k).last().find(de+y).html(s).parent()),a&&t.overflow!==oe&&(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(v)),i&&(l=i.find(q+he+G),this._addAttributes(t,i)),o&&(l.add(o.find(q+he+G)),this._addAttributes(t,o)),!this.options.navigateOnTab&&l.length>0&&(i.attr(j,0),i.attr($+E,""),l.attr(j,-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='"+n.sanitizeLink(i.url)+"'>")),i.showIcon===W&&(delete i.imageUrl,delete i.icon),i.showText!==W?s.text(i.text):s.attr(z,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(Y,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===W&&(delete e.imageUrl,delete e.icon),e.showText===W&&(e.attributes||(e.attributes={}),e.attributes[z]=e.text,delete e.text)}))),i.id&&(s.attr(ue,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(be[t]),this._addAttributes(i,o),i.url&&s.removeAttr(N),l?(o.find(de+c).attr($+E,""),this._groupVisibleButtons(o)):r.element.attr($+E,""),"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,t=e.options;e.element.on(O+s,e._keydown.bind(e)).on("focusin"+s,e._focusIn.bind(e)).on("focusout"+s,e._focusOut.bind(e)),"section"==t.overflow?.mode&&e.overflowSection&&e._overflowSectionContentElement().on(O+s,e._keydown.bind(e)),"scroll"==t.overflow?.mode&&e.element.find("> .k-toolbar-items").bind("scroll",(function(t){e._nowScrollingTabs||e._toggleScrollButtons()}))},_attachWidgetEvents:function(t){var n=this;t.bind(L,n._onClick.bind(n)),t.bind(B,n._onToggle.bind(n)),t.bind(G,n._onSelect.bind(n)),t.bind(H,n._onOpen.bind(n)),t.bind(R,n._onClose.bind(n)),t.wrapper.find(de+c).each(((t,i)=>{var r=e(i);r.data("kendoButton")&&r.data("kendoButton").bind(L,(e=>{n.trigger(L,{id:e.id,target:e.target,originalEvent:e.originalEvent||e.event})}))}))},_childrenWidth:function(){var t=parseInt(this.element.css("gap"),10)||0;var n=t;return(this.element.find("> .k-toolbar-items").length>0?this.element.find("> .k-toolbar-items"):this.element).children(":visible:not(."+f+")").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(de+c);n.length>0&&(this._resetTabIndex(n),n.addClass(A))},_focusOut:function(e){this.wrapper.find(de+c+de+A).removeClass(A)},_getAllItems:function(e,t){return(1==e?this._overflowSectionContentElement():this.wrapper).find(J+(t?":not(.k-disabled)":"")).filter(":visible").filter(((e,t)=>"hidden"!==t.style.visibility))},_getOverflowItem:function(e,t){return this._getItem(e,t,this._overflowSectionContentElement())},_getItem:function(t,i,r){var o,a,s=i||this._getUid(t),l=e(Z);return s?(o="[data-uid="+s+"]",{toolbarEl:a=(r||this.element).find(o),templateEl:a.closest(de+C+he+de+h),component:n.widgetInstance(a),menuItem:this.overflowMenu?this.overflowMenu.element.find(o):e(se),buttonsPopupItem:l.find(o)}):{toolbarEl:(r||this.element).find(t),templateEl:e(se),menuItem:this.overflowMenu?this.overflowMenu.element.find(t):e(se),buttonsPopupItem:e(se)}},_getNextElement:function(t,n){const i=e(t).closest(".k-toolbar-popup").length>0;var r=this._getAllItems(i,!0),o=-1===r.index(t)?r.index(t.parentElement):r.index(t),a=r[o+n];return a||(a=-1===n?r.last():r.first()),a},_getUid:function(t){var n;return(n=this.element.find(t)).length||(n=e(Z).find(t)),!n.length&&this.overflowMenu&&(n=this.overflowMenu.element.find(t)),!n.length&&this.overflowSection&&(n=this._overflowSectionContentElement().find(t)),n.length?n.data(pe)||n.closest(J).data(pe):null},_groupVisibleButtons:function(e){var t,n=e.children();n.removeClass(w).removeClass(b),(t=n.filter(":not('."+v+"')")).first().addClass(b),t.last().addClass(w)},_hideItem:function(t){var n=this;t.addClass(v),this.overflowSection&&this._overflowSectionContentElement().find(`[ref-section-tool=${t.data("uid")}]`).removeClass(v),n.overflowMenu&&(t.hasClass(h)||t.hasClass(u)?((t.hasClass(h)?(t=t.children().eq(0)).data(me):t.data(fe)).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(pe)+"']").addClass(v)},_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(de+C),a=n.is(de+x);const s=n.closest(".k-toolbar-popup").length>0;if(!this.options.navigateOnTab&&!n.is(J)&&i===o.ESC&&r.length>0)return t.stopPropagation(),void this._keyDeactivateTemplate(r);n.is(J)&&(!this.options.navigateOnTab&&i===o.ENTER&&n.hasClass(C)?this._keyActivateTemplate(n):s&&i===o.ESC?(this.overflowSection.close(),this.element.trigger(F)):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(ee+":not('"+de+M+"')"+he+de+T);const n=e.find(".k-pager");n.length>0?n.trigger(F):t.length>0&&(e.attr(j,-1),t.attr(j,0),t.first().trigger(F))},_keyDeactivateTemplate:function(e){var t,i=e.find(Q),r=e.find(ee+":not('"+de+M+"')"+he+de+T);if(i.length>0&&(t=n.widgetInstance(i))){if(t.overflowMenu&&t.overflowMenu.visible())return;e.attr(j,0),e.trigger(F),e.find(ee).attr(j,-1)}r.length>0&&(e.attr(j,0),e.trigger(F),r.attr(j,-1))},_keyFocusFirst:function(e,t){const n=e.closest(".k-toolbar-popup").length>0;var i=this._getAllItems(n,!0);e.is(de+T)||e.is(q)||(this._resetTabIndex(i.first()),i.first().trigger(F),t.preventDefault())},_keyFocusLast:function(e,t){const n=e.closest(".k-toolbar-popup").length>0;var i,r=this._getAllItems(n,!0);e.is(de+T)||e.is(q)||(0===(i=r.last()).width()&&(i=r.eq(r.length-2)),this._resetTabIndex(i),i.trigger(F),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(F),n.preventDefault()},_keyOpenOverflow:function(e,t){t===o.SPACEBAR&&e.preventDefault(),(this.overflowMenu||this.overflowSection).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(P,{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),h=e.isPlainObject(t),u=h&&Object.keys(t).length;return d?{type:"buttonGroup",buttons:t.map((e=>c._mapTool(e,i,r)))}:(o=h&&(1===u||2===u)&&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[z],a.buttons=a.buttons.map((e=>c._mapTool(e,i,r)))):"splitButton"===a.type?(delete a.attributes[z],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(ue),a=r.find(de+S),s=r.data(K);o&&o.indexOf(le+W)>-1&&(o=o.replace(le+W,se)),a.length?(s&&this.overflowMenu.element.find("[data-group="+s+"]").each(((t,n)=>{var i=e(n);i.attr(I,!1),i.find(de+S).removeClass(m)})),n=!!s||!a.hasClass(m),a.toggleClass(m,n),r.attr(I,n),(i=this.element.find("[data-uid="+r.data(pe)+"]")).length&&(i.closest(de+d).length?i.closest(de+d).data(ve).select(i):(s&&this.element.find("[data-group="+s+"]").each(((t,n)=>{e(n).data(ge).toggle(!1)})),i.data(ge).toggle(!0))),this.trigger(B,{id:r.attr(ue),target:r,checked:n})):this.trigger(L,{id:o,target:r})},_onClick:function(e){var t=e.target,n=t.hasClass("k-toolbar-toggle-button"),i=t.data(K);n||this.trigger(L,{id:e.id,target:e.target,originalEvent:e.originalEvent||e.event}),i&&this.element.find("[data-group="+i+"]").length>1&&t.hasClass(m)&&e.preventDefault()},_onClose:function(e){this.trigger(R,{widget:e.sender})&&e.preventDefault()},_onMenuItemSelect:function(t,n,i){var r=e(t.item),o=r.find(de+S).length>0,a=r.attr(ue);a&&a.indexOf(le+W)>-1&&(a=a.replace(le+W,se)),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(de+m).length>0})}))},_onOpen:function(e){this.trigger(H,{widget:e.sender})&&e.preventDefault()},_onSelect:function(t){let i=this;var r=this.overflowMenu?this.overflowMenu.element:e(se);t.sender.element.children().each(((t,o)=>{var a=e(o),s=`[data-uid=${a.data(pe)}]`,l=a.hasClass(m);if(r.find(s).attr(I,l).find(de+S).toggleClass(m,l),i.overflowSection){let e=i.element.find(s);let t=i.overflowSection.element.find(s);let r=n.widgetInstance(e[0]==o?t:e);r?.toggle?.(l)}})),this.trigger(B,{id:t.target.attr(ue),target:t.target,checked:t.target.hasClass(m)})},_onToggle:function(t){var i,r=this,o=t.target,a=o.data(K);if(r.overflowMenu&&(i=r.overflowMenu.element.find("[data-uid="+o.attr(Y)+"]"),r.overflowMenu.element.find("[data-group="+a+"]").attr(I,!1).find(de+S).removeClass(m),i.attr(I,!0).find(de+S).addClass(m)),r.overflowSection){let e=r.element.find("[data-uid="+o.attr(Y)+"]");i=r.overflowSection.element.find("[data-uid="+o.attr(Y)+"]");let a=n.widgetInstance(e[0]==t.target[0]?i:e);a?.toggle?.(t.checked)}a&&r.element.find("[data-group="+a+"]").each(((t,n)=>{n!==o[0]&&e(n).data(ge).toggle(!1)})),this.trigger(B,{id:t.id,target:t.target,checked:t.checked,originalEvent:t.originalEvent||t.event})},_processInner(e,t){var i;for(var r=0;r<e.length;r++)(i=e[r]).attributes||(e[r].attributes={}),e[r].attributes[Y]=n.guid(),e[r].attributes["data-parentuid"]=t,i.id&&(e[r].attributes[ue]=e[r].id),i.hidden&&(e[r].attributes.class||(e[r].attributes.class=se),e[r].attributes.class+=ce+v+ce+_);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===V?i.overflow=ie:i.overflow||(i.overflow=re),i.enable!==t&&(i.enabled=i.enable),i},_renderOverflow:function(){var t=this,i=t._isRtl?"left":"right";const r=t.options.overflow?.mode;"section"!==r&&"menu"!==r||(t.overflowAnchorSeparator=e(`<div class="k-toolbar-separator k-toolbar-button-separator k-separator" ${N}="${U}"></div>`),t.overflowAnchor=e("<button class='k-toolbar-overflow-button' title='More tools'>"),t.overflowAnchor.attr($+E,""),t.element.append(t.overflowAnchorSeparator),t.element.append(t.overflowAnchor),t.overflowAnchor.kendoButton({icon:"menu"==r?"more-vertical":"more-horizontal",fillMode:"flat",size:t.options.size,click:function(e){"section"==r&&t.overflowSection.open()}}),t.options.navigateOnTab||t.overflowAnchor.attr(j,-1),"section"==r&&(t.overflowSection=new n.ui.Popup(e(`<div class="k-toolbar-popup"><div class="k-toolbar-items-list ${n.getValidCssClass("k-toolbar-items-list-","fill",t.options.fillMode)} ${n.getValidCssClass("k-toolbar-items-list-","size",t.options.size)}"></div></div>`),{anchor:t.element,origin:"bottom left",position:"top left",open:function(e){if(t.trigger(te))return e.preventDefault();t.overflowSection.element.width(t.element.outerWidth())},activate:function(e){let n=t._getAllItems(!0,!0).first();t._resetTabIndex(n),n.trigger(F)},close:function(e){t.trigger(ne)?e.preventDefault():(t._resetTabIndex(t.overflowAnchor),t.overflowAnchor.trigger(F))}})),"menu"==r&&(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(te)&&e.preventDefault()},close:function(e){t.trigger(ne)?e.preventDefault():(t._resetTabIndex(t.overflowAnchor),t.overflowAnchor.trigger(F))}}),t.overflowMenu.element.attr(ae,this.uid),setTimeout((()=>{t.overflowMenu.bind(G,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(P,{target:t,value:e.target.files[0]}),a._resetOpen(t,i)})).appendTo(r),t.off(O).on(O,(e=>{e.keyCode===n.keys.ENTER&&o.trigger(L)}))},_resetTabIndex:function(e){if(!0!==this.options.navigateOnTab){(e.closest(".k-toolbar-popup").length>0?this._overflowSectionContentElement():this.wrapper).find(ee).attr(j,-1),e.attr(j,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(),this.overflowSection?.close(),o.length>0&&o.each(((t,i)=>{n.widgetInstance(e(i)).close()})),this.hasOverflowButton?(this._shrink(i),this._stretch(i),this._toggleOverflowAnchor()):this._toggleScrollButtons())},_shrink:function(t){var n,i,r;let o=this.element.find("> .k-toolbar-items").length>0?this.element.find("> .k-toolbar-items"):this.element;if(t<this._childrenWidth())for(var a=(i=o.children(":visible:not([data-overflow='never'], ."+x+")")).length-1;a>=0&&(n=i.eq(a),!(t>this._childrenWidth()));a--)(r=n.find("[tabindex=0]")||n.is("[tabindex=0]")?n:e(se)).length>0&&(r.attr(j,-1),this.element.children(de+x).attr(j,0)),this._hideItem(n)},_showItem:function(t,n){var i=this,r=parseInt(this.element.css("gap"),10)||0;t.removeClass(v);var o=a(t,!0)+r;return t.addClass(v),!(!t.length||!(t.hasClass(f)||n>this._childrenWidth()+o))&&(t.removeClass(v),!0!==this.options.navigateOnTab?t.find(ee).attr(j,-1):t.is("[tabindex=-1]")&&t.removeAttr(j),this.overflowSection&&this._overflowSectionContentElement().find(`[ref-section-tool=${t.data("uid")}]`).addClass(v),this.overflowMenu&&(t.hasClass(h)||t.hasClass(u)?((t.hasClass(h)?(t=t.children().eq(0)).data(me):t.data(fe)).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(pe)+"']");t.hasClass(_)||t.removeClass(v)},_stretch:function(e){var t,n,i=this.element.children(de+x);let r=this.element.find("> .k-toolbar-items").length>0?this.element.find("> .k-toolbar-items"):this.element;if(e>this._childrenWidth()){n=r.children(de+v+":not("+de+_+")");for(var o=0;o<n.length&&(t=n.eq(o),!(e<this._childrenWidth())&&this._showItem(t,e));o++);}!this.options.navigateOnTab&&i.is("[tabindex=0]")&&(i.attr(j,-1),this._resetTabIndex(this._getAllItems().first()))},_tabIndex:function(){var e=this.wrapper.find(ee+":not('"+D+"')"),t=e.first();!0!==this.options.navigateOnTab?(e.attr(j,-1),t.attr(j,0)):this.wrapper.find(".k-toolbar-item").removeAttr(j)},_toggleOverflowAnchor:function(){this.hasOverflowButton&&((this.overflowMenu?.element||this._overflowSectionContentElement()).children(":not(."+v+", .k-popup)").length>0?(this.overflowAnchor.removeClass(v),this.overflowAnchorSeparator.removeClass(v)):(this.overflowAnchor.addClass(v),this.overflowAnchorSeparator.addClass(v)))}});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(xe)}(window.kendo.jQuery);kendo;const rp="object";const op=".";const ap="click";const sp="focus";const lp="blur";const cp="change";const dp="rtl";const hp=13,up=38,pp=40,fp=35,mp=36,gp=32;const vp={AMP:/&/g,LT:/</g,GT:/>/g,QUOTE:/"/g,APOSTROPHE:/'/g,CURLY:/__CURLY__/g,SHARP:/__SHARP__/g,ARGUMENT_NAME:/^\w+/,ENCODE:/\$\{([^}]*)\}/g,ESCAPED_CURLY:/\\\}/g,ESCAPED_SHARP:/\\#/g,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,CHROMIUM_EDGE:/(edg)[ /]([\w.]+)/i};const _p=e=>"function"==typeof e;const bp=$.extend;function wp(e,t){const n=kendo?.data?.ObservableArray;const i=kendo?.data?.LazyObservableArray;const r=kendo?.data?.DataSource;const o=kendo?.data?.HierarchicalDataSource;for(const a in t){if("__proto__"===a||"constructor"===a||"prototype"===a)continue;const s=t[a];const l=typeof s;let c=null;if(l===rp&&null!==s&&(c=s.constructor),!c||c===Array||c===n||c===i||c===r||c===o||c===RegExp||_p(globalThis.ArrayBuffer)&&c===ArrayBuffer||s instanceof HTMLElement)"undefined"!==l&&(e[a]=s);else if(s instanceof Date)e[a]=new Date(s.getTime());else if(_p(s.clone))e[a]=s.clone();else{const t=e[a];e[a]=typeof t===rp&&t||{},wp(e[a],s)}}return e}const yp=()=>{try{return crypto.randomUUID()}catch(e){kp(`crypto.randomUUID is not supported. Using fallback method. ${e}`,"warn");return crypto.getRandomValues(new Uint8Array(16)).reduce(((e,t,n)=>(4!==n&&6!==n&&8!==n&&10!==n||(e+="-"),e+=t.toString(16).padStart(2,"0"))),"")}};const kp=(e,t)=>{const n=window.console||console||{};!kendo.suppressLog&&void 0!==n&&n.log&&n[t||"log"](e)};const xp=(e,t)=>(t?e:Cp(e)).replace(/((https?:\/\/[^\s]+)|(www\.[^\s]+))/gi,(e=>{let t=e.trim();const n=e.trim();/^www\./i.test(t)&&(t="https://"+t);try{t=new URL(t).href;let e="noopener noreferrer";return`<a href="${t}" target="${"_blank"}"${e?` rel="${e}"`:""}>${n}</a>`}catch(t){return e}}));const Cp=(e,t)=>{!0===t&&(e=function(e){const t={"&":"&","<":"<",">":">",""":'"',"'":"'"};return e.replace(/&(?:amp|lt|gt|quot|#39);/g,(function(e){return t[e]}))}(e));return(""+e).replace(vp.AMP,"&").replace(vp.LT,"<").replace(vp.GT,">").replace(vp.QUOTE,""").replace(vp.APOSTROPHE,"'")};const Sp={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"]};const Tp=(e,t)=>{const n=Object.keys(Sp);const i="file";if(void 0===e||!e.length)return i;for(let i=0;i<n.length;i+=1){const r=Sp[n[i]];const o=e.toLowerCase();if(r.indexOf(o)>-1||r.indexOf("."+o)>-1)return t?"file-"+n[i]:n[i]}return i};const Mp=(e,t)=>{const n=(e=>{let t={};let n=[];let i=[];const r={edge:vp.EDGE,webkit:vp.WEBKIT,safari:vp.SAFARI,opera:vp.OPERA,msie:vp.MSIE,mozilla:vp.MOZILLA};for(let o in r)if(r.hasOwnProperty(o)&&(n=e.match(r[o]),n)){t[o]=!0,t[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,t.version=parseInt(document.documentMode||n[2],10),t.chrome&&(i=e.match(vp.CHROMIUM_EDGE),i&&(t.chromiumEdge=!0));break}return t})(navigator.userAgent);const i=n.webkit;const r=n.mozilla;const o=n.safari;const a=n.version;let s,l;if(e instanceof $&&void 0!==t)e.each((function(e,n){Mp(n,t)}));else if(s=e instanceof $?e[0]:e,s){if(l=(e=>$(e).closest(".k-rtl").length>0)(e),void 0===t){let e;return e=l&&i&&(a<85||o)?s.scrollWidth-s.clientWidth-s.scrollLeft:Math.abs(s.scrollLeft),e}s.scrollLeft=l&&i&&(a<85||o)?s.scrollWidth-s.clientWidth-t:l&&(r||i)&&t>0?-t:t}};const Ap=(e,t)=>{let n=Mp(e);const i={scrollLeft:n+t};e.finish().animate(i,"fast","linear");const r=e[0].scrollWidth-e[0].clientWidth;const o=Math.min(Math.max(n+t,0),r);return{atStart:0===o,atEnd:o>=r}};const Dp="function";const Ep="string";const Ip="aria-labelledby";const zp="aria-label";const Pp=["themeColor","fillMode","shape","size","rounded","positionMode"];class Lp{constructor(){this.constructor._extendSetupDone||this._setupExtendedClass()}_setupExtendedClass(){this.constructor.extend=Lp.extend,this.constructor.fn=this.constructor.prototype,this.constructor._extendSetupDone=!0}static extend(e){const t=this;class n extends t{constructor(...t){e.init?(super(),e.init.apply(this,t)):super(...t)}}for(const i in e)"init"!==i&&(null!=e[i]&&e[i].constructor===Object?n.prototype[i]={...t.prototype[i],...e[i]}:n.prototype[i]=e[i]);return n.extend=this.extend,n.fn=n.prototype,n}_initOptions(e){this.options=((e,...t)=>{for(let n=0;n<t.length;n++)wp(e,t[n]);return e})({},this.options,e)}}const Bp=function(){this._defaultPrevented=!0};const Hp=function(){return!0===this._defaultPrevented};let Rp=class extends Lp{constructor(){super(),this._events={}}bind(e,t,n){if(void 0===t){for(const t in e)this.bind(t,e[t]);return this}const i=typeof e===Ep?[e]:e;const r=typeof t===Dp;for(let e=0;e<i.length;e++){const o=i[e];let a=r?t:t[o];if(a){if(n){const e=a;a=(...t)=>{this.unbind(o,a),e.apply(this,t)},a.original=e}(this._events[o]=this._events[o]||[]).push(a)}}return this}one(e,t){return this.bind(e,t,!0)}first(e,t){const n=typeof e===Ep?[e]:e;const i=typeof t===Dp;for(let e=0;e<n.length;e++){const r=n[e];const o=i?t:t[r];if(o){(this._events[r]=this._events[r]||[]).unshift(o)}}return this}trigger(e,t={}){const n=this._events[e];if(n){t.sender=this,t._defaultPrevented=!1,t.preventDefault=Bp,t.isDefaultPrevented=Hp;const e=n.slice();for(let n=0;n<e.length;n++)e[n].call(this,t);return!0===t._defaultPrevented}return!1}unbind(e,t){if(void 0===e)this._events={};else{const n=this._events[e];if(n)if(t)for(let e=n.length-1;e>=0;e--)n[e]!==t&&n[e].original!==t||n.splice(e,1);else this._events[e]=[]}return this}};let Fp=class extends Rp{constructor(e,t){super(),void 0===E||E()||(this._showWatermarkOverlay=z),this.element=(kendo?.jQuery||$)?.(e),this.element?.handler&&this.element.handler(this);const n=t?.dataSource;let i;t&&(i=(this.componentTypes||{})[t.componentType]),n&&(t={...t,dataSource:{}}),this.options={...this.options,...this.defaults,...i,...t},n&&(this.options.dataSource=n),kendo?.attr&&!this.element?.attr?.(kendo.attr("role"))&&this.element?.attr?.(kendo.attr("role"),(this.options.name||"").toLowerCase()),this.element?.data?.("kendo"+this.options.prefix+this.options.name,this),this.bind(this.events,this.options)}get events(){return[]}get options(){return this._options||{prefix:""}}set options(e){this._options=e}_hasBindingTarget(){return!!this.element?.[0]?.kendoBindingTarget}_tabindex(e){e=e||this.wrapper;const t=this.element;const n="tabindex";const i=e?.attr?.(n)||t?.attr?.(n);t?.removeAttr?.(n),e?.attr?.(n,isNaN(i)?0:i)}setOptions(e){this._clearCssClasses(e),this._setEvents(e),Object.assign(this.options,e),this._applyCssClasses()}_setEvents(e){for(let t=0;t<this.events.length;t++){const n=this.events[t];this.options[n]&&e[n]&&(this.unbind(n,this.options[n]),this._events?.[n]&&delete this._events[n])}this.bind(this.events,e)}resize(e){const t=this.getSize();const 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 kendo?.dimensions?.(this.element)||{width:0,height:0}}size(e){if(!e)return this.getSize();this.setSize(e)}setSize(){}_resize(){}destroy(){this.element?.removeData?.("kendo"+this.options.prefix+this.options.name),this.element?.removeData?.("handler"),this.unbind()}_destroy(){this.destroy()}_applyCssClasses(e){const t=Object.getPrototypeOf(this).constructor.prototype.options;const n=this.options;const i=e||this.wrapper||this.element;const r=[];if(kendo?.cssProperties?.propertyDictionary?.[t?.name]){for(let e=0;e<Pp.length;e++){const i=Pp[e];const o=this.options._altname||t.name;if(t.hasOwnProperty(i))if("themeColor"===i){const e=kendo.cssProperties.getValidClass({widget:o,propName:"fillMode",value:n.fillMode});e?.length&&r.push(kendo.cssProperties.getValidClass({widget:o,propName:i,value:n[i],fill:n.fillMode}))}else r.push(kendo.cssProperties.getValidClass({widget:o,propName:i,value:n[i]}))}i?.addClass?.(r.join(" "))}}_ariaLabel(e){const t=this.element;const n=t?.attr?.("id");const i=$?.(`label[for="${n}"]`);const r=t?.attr?.(zp);const o=t?.attr?.(Ip);if(e?.[0]!==t?.[0])if(r)e?.attr?.(zp,r);else if(o)e?.attr?.(Ip,o);else if(i?.length){const t=i?.attr?.("id")||this._generateLabelId(i,n||kendo?.guid?.());e?.attr?.(Ip,t)}}_clearCssClasses(e,t){const n=Object.getPrototypeOf(this).constructor.prototype.options;const i=this.options;const r=t||this.wrapper||this.element;if(kendo?.cssProperties?.propertyDictionary?.[n?.name])for(let t=0;t<Pp.length;t++){const o=Pp[t];const a=this.options._altname||n.name;n.hasOwnProperty(o)&&e.hasOwnProperty(o)&&("themeColor"===o?r?.removeClass?.(kendo.cssProperties.getValidClass({widget:a,propName:o,value:i[o],fill:i.fillMode})):("fillMode"===o&&r?.removeClass?.(kendo.cssProperties.getValidClass({widget:a,propName:"themeColor",value:i.themeColor,fill:i.fillMode})),r?.removeClass?.(kendo.cssProperties.getValidClass({widget:a,propName:o,value:i[o]}))))}}_generateLabelId(e,t){const n=t+"_label";return e?.attr?.("id",n),n}};class Op extends Fp{dataItems(){return this.dataSource?this.dataSource.flatView():[]}}Lp.fn=Lp.prototype,Rp.fn=Rp.prototype,Fp.fn=Fp.prototype,Op.fn=Op.prototype;const Vp=Array.prototype.slice;const Np=".kendoChat";const $p="k-active",Up="k-chat-file",Wp="k-chat-file-info",jp="k-chat-file-name",qp="k-chat-file-size",Gp="k-chat-file-wrapper",Kp="k-bubble",Yp="k-bubble-content",Qp="k-bubble-expandable",Xp="k-bubble-expandable-indicator",Zp="k-button-icon",Jp="k-chat-bubble",ef="k-chat-bubble-text",tf="k-chat-send",nf="k-disabled",rf="k-chat-download-button",of="k-chat-download-button-wrapper",af="k-expanded",sf="k-generating",lf="k-chat-header",cf="k-hidden",df="k-message",hf="k-message-author",uf="k-message-box",pf="k-message-box-wrapper",ff="k-message-group",mf="k-message-group-content",gf="k-message-group-full-width",vf="k-message-group-receiver",_f="k-message-group-sender",bf="k-avatars",wf="k-message-list-content",yf="k-message-pinned",kf="k-message-reference",xf="k-message-reference-content",Cf="k-message-reference-receiver",Sf="k-message-reference-sender",Tf="k-message-removed",Mf="k-message-time",Af="k-chat-message-toolbar",Df="k-no-avatar",Ef="k-selected",If="k-focus",zf="k-spacer",Pf="k-suggestion",Lf="k-suggestion-group",Bf="k-suggestion-scrollwrap",Hf="k-timestamp",Rf="k-typing-indicator",Ff="k-message-list",Of="k-chat";const Vf="paperclip",Nf="more-vertical",$f="chevron-down",Uf="chevron-left",Wf="chevron-right",jf="chevron-up",qf="download",Gf="pin",Kf="undo",Yf="copy",Qf="trash",Xf="paper-plane",Zf="stop-sm",Jf="x";const em="ref-chat-file-button",tm="ref-chat-file-menu-button",nm="ref-chat-file-wrapper",im="ref-chat-file-close-button",rm="ref-chat-bubble-expandable-indicator",om="ref-chat-message-reference-pin-wrapper",am="ref-chat-message-reference-reply-wrapper",sm="ref-chat-pinned-message-close-button",lm="ref-chat-reply-message-close-button",cm="ref-chat-left-scroll-button",dm="ref-chat-right-scroll-button",hm="ref-chat-message-box-send-button",um="ref-chat-message-box-speech-to-text-button",pm="ref-chat-suggestion-group",fm="ref-chat-file-upload-input";const mm="sendMessage",gm="suggestionClick",vm="unpin",_m="input",bm="toolbarAction",wm="fileMenuAction",ym="contextMenuAction",km="download";const xm="standard",Cm="full";const Sm="reply",Tm="copy",Mm="pin",Am="delete",Dm="download";const Em=200;const Im=(e,t,n=!0)=>`<li class="${Up}" data-uid="${Cp(e.uid)}">\n ${kendo.ui.icon({icon:Tp(e.extension,!0),size:"xxlarge"})}\n <div class="${Wp}">\n <span class="${jp}">${Cp(e.name)}</span>\n <span class="${qp}">${Cp((e=>isNaN(e)?e:(e/=1024)<1024?e.toFixed(2)+" KB":(e/1024).toFixed(2)+" MB")(e.size))}</span>\n </div>\n ${t?new kendo.ui.Button(`<button class="" ${im}>`,{icon:Jf,fillMode:"flat"}).wrapper[0].outerHTML:""}\n ${n&&!t?`<button ${tm}></button>`:""}\n </li>`;const zm=(e,t,n,i,r,o,a)=>{const s=e.isDeleted;const l=r&&!e.isTyping?[Qp,af]:[];const c=t?Bm({text:t.text,files:t.files,isOwnMessage:t.isOwnMessage,isPinMessage:!1,renderCloseButton:!1,renderFileMenuButton:!1}):"";let d="";return d=s?e.isOwnMessage?Cp(i.selfMessageDeleted):Cp(i.otherMessageDeleted):xp(e.text||"",a),'<div class="'+df+(s?" "+Tf:"")+'" data-uid="'+Cp(e.uid)+'"><time class="'+Mf+'">'+kendo.toString(kendo.parseDate(e.timestamp),o)+'</time><div class="'+Jp+" "+Kp+" "+l.join(" ")+'"><div class="'+Yp+'"><span class="'+ef+'">'+c+(e.isTyping&&!e.isOwnMessage?'<div class="'+Rf+'"><span></span><span></span><span></span></div>':d)+"</span>"+(s?"":Lm(e.files,n,i))+"</div>"+(r&&!e.isTyping?'<span class="'+Xp+'" '+rm+">"+kendo.ui.icon({icon:jf})+"</span>":"")+"</div>"+(s?"":'<div class="'+Af+'"></div>')+"</div>"};const Pm=({message:e,author:t,isOwnMessage:n,replyMessage:i,downloadAll:r,messages:o,expandable:a,fullWidth:s,messageTimeFormat:l,timestampTemplate:c,showTimestamp:d,messageTemplate:h=zm,skipSanitization:u})=>{const p=t&&t.imageUrl;const f=ff+" "+(n?_f:vf)+(p?"":" "+Df)+(s?" "+gf:"");let m="";if(d&&e.timestamp){const t=kendo.parseDate(e.timestamp);if(_p(c))m=c({date:t,message:e});else{const e=((e,t=new Date)=>{if(!e)return"";const n=new Date(t);n.setHours(0,0,0,0);const i=new Date(e);i.setHours(0,0,0,0);const r=n.getTime()-i.getTime();const o=Math.floor(r/864e5);return 0===o?"Today":1===o?"Yesterday":o<=6?`Last ${kendo.toString(i,"dddd")}`:kendo.toString(i,"dddd, MMMM dd, yyyy")})(t);m='<div class="'+Hf+'">'+e+"</div>"}}return(d&&m?m:"")+'<div class="'+f+'">'+(p?(({url:e,text:t})=>new kendo.ui.Avatar("<div>",{type:"image",image:e,alt:Cp(t??"")}).wrapper[0].outerHTML)({url:t.imageUrl,text:t.imageAltText}):"")+'<div class="'+mf+'"><span class="'+hf+'">'+Cp(t.name)+"</span>"+h(e,i,r,o,a,l,u)+"</div></div>"};const Lm=(e,t,n,i)=>{if(!e?.length)return"";let r=`<ul class="${Gp}" ${nm}>`;return e.forEach((e=>{r+=Im(e,i,!0)})),r+="</ul>",t&&e.length>1&&(r+=`<div class="${of}">\n ${new kendo.ui.Button(`<button class="${rf}">${n.downloadAll}</button>`,{icon:qf,fillMode:"flat"}).wrapper[0].outerHTML}\n </div>`),r};const Bm=({text:e,files:t,isOwnMessage:n,isPinMessage:i,isDeleted:r,renderCloseButton:o,renderFileMenuButton:a,messages:s})=>{const l=n?Sf:Cf;const c=i?yf:"";const d=i?sm:lm;const h=i?om:am;let u=xp(e||"");return u||(u=t?.length?Im(t[0],null,a):""),r&&(u=Cp(n?s.selfMessageDeleted:s.otherMessageDeleted)),'<div class="'+kf+" "+l+" "+c+'" '+h+">"+(i?kendo.ui.icon({icon:Gf,size:"xlarge"}):"")+'<div class="'+xf+'">'+u+'</div><span class="'+zf+'"></span>'+(o?new kendo.ui.Button("<button "+d+">",{icon:Jf,fillMode:"flat"}).wrapper[0].outerHTML:"")+"</div>"};const Hm=e=>e?.length?`<div class="${Lf}" ${pm}>${e.map((e=>`<span class="${Pf}">${Cp(e.text)}</span>`)).join("")}</div>`:"";const Rm=(e,t)=>'<div class="'+Bf+'">'+new kendo.ui.Button("<button "+cm+">",{icon:t?Wf:Uf}).wrapper[0].outerHTML+e+new kendo.ui.Button("<button "+dm+">",{icon:t?Uf:Wf}).wrapper[0].outerHTML+"</div>";const Fm=`${Np}navigation`;let Om=null;let Vm=!1;const Nm=(e,t)=>{const n=t.messages;const i=e.find(`.${bf}`);i.length&&i.attr("role","log").attr("aria-live","polite").attr("aria-label",n.messageListLabel),$m(e);e.find(`.${Lf}`).each(((e,t)=>{const n=$(t);n.attr("role","group");n.find(`.${Pf}`).each(((e,t)=>{$(t).attr("role","button").attr("tabindex","0")}))}));e.find(".k-input-suffix > .k-button").each(((e,t)=>{const i=$(t);i.attr("role")||"button"===i[0].nodeName.toLowerCase()||i.attr("role","button"),i.attr("aria-label")||i.attr("title")||(i.hasClass(tf)?i.attr("aria-label",n.sendButton):i.hasClass("k-chat-upload")&&i.attr("aria-label",n.fileButton)),i.hasClass(tf)&&i.hasClass("k-disabled")&&i.attr("aria-disabled","true")}));e.find(`.${rf}`).each(((e,t)=>{const i=$(t);i.attr("role")||"button"===i[0].nodeName.toLowerCase()||i.attr("role","button"),i.attr("aria-label")||i.attr("title")||i.attr("aria-label",n.downloadAll)}));e.find(`[${sm}]`).each(((e,n)=>{const i=$(n);i.attr("role")||"button"===i[0].nodeName.toLowerCase()||i.attr("role","button"),i.attr("aria-label")||i.attr("title")||(i.attr("aria-label",t.messages.pinnedMessageCloseButton),i.attr("title",t.messages.pinnedMessageCloseButton))})),Ym(e,t);e.find(`[${tm}]`).each(((e,n)=>{const i=$(n);i.attr("aria-label",t.messages.fileMenuButton),i.attr("title",t.messages.fileMenuButton)}));e.find(`.${Xp}`).each(((e,t)=>{const n=$(t);n.attr("role","button").attr("tabindex","0");const i=n.closest(`.${Kp}`).hasClass(af)?"Collapse message":"Expand message";n.attr("aria-label",i)})),Qm(e);e.find(`.${uf}`).find("textarea").attr("aria-label",n.messageBoxLabel)};const $m=e=>{const t=e.find(`.${Kp}`);const n=t.filter((function(){return 0===$(this).find(`.${Rf}`).length}));const i=t.filter((function(){return $(this).find(`.${Rf}`).length>0}));n.attr("tabindex","0"),i.attr("tabindex","-1"),n.off(`${sp}${Fm} ${lp}${Fm} ${ap}${Fm}`).on(`${sp}${Fm}`,(function(){const e=$(this);Om&&t.removeClass(Ef),t.removeClass(If),Om&&e.addClass(Ef),e.addClass(If),Om=!1})).on(`${lp}${Fm}`,(function(){Om&&!Vm&&$(this).removeClass(Ef),$(this).removeClass(If)})).on(`${ap}${Fm}`,(function(e){$(e.target).closest(tm)||$(this).trigger(sp)}))};const Um=(e,t)=>{const n=t?"Collapse message":"Expand message";e.attr("aria-label",n)};const Wm=(e,t)=>{if(0===e.length||t<0||t>=e.length)return;const n=e.eq(t);n.attr("data-keyboard-focus","true"),n.focus(),n.removeAttr("data-keyboard-focus")};const jm=(e,t,n)=>{const i=$(e.target);if(i.find(`.${Rf}`).length>0)return null;const r=n.find(`.${Kp}`).filter((function(){return 0===$(this).find(`.${Rf}`).length}));const o=r.index(i);switch(t){case up:e.preventDefault(),((e,t)=>{t>0&&Wm(e,t-1)})(r,o);break;case pp:e.preventDefault(),((e,t)=>{t<e.length-1&&Wm(e,t+1)})(r,o);break;case mp:e.preventDefault(),(e=>{Wm(e,0)})(r);break;case fp:e.preventDefault(),(e=>{Wm(e,e.length-1)})(r)}return null};const qm=(e,t)=>{if(t===hp||t===gp){e.preventDefault(),$(e.target).trigger(ap);const t=$(e.target);const n=t.closest(`.${Kp}`).hasClass(af);Um(t,!n)}};const Gm=(e,t,n,i)=>{t!==hp||e.shiftKey||(e.preventDefault(),i._sendMessage())};const Km=(e,t)=>{t!==hp&&t!==gp||(e.preventDefault(),$(e.target).trigger(ap))};const Ym=(e,t)=>{e.find(`[${lm}]`).each(((e,n)=>{const i=$(n);i.attr("role")||"button"===i[0].nodeName.toLowerCase()||i.attr("role","button"),i.attr("aria-label")||i.attr("title")||(i.attr("aria-label",t.messages.replyMessageCloseButton),i.attr("title",t.messages.replyMessageCloseButton))}))};const Qm=e=>{const t=e.find(`[${cm}]`);const n=e.find(`[${dm}]`);t.attr("aria-label","Scroll Left"),t.attr("title","Scroll Left"),n.attr("aria-label","Scroll Right"),n.attr("title","Scroll Right")};class Xm extends Fp{static options={name:"MessageBox"};constructor(e,t){super(e,bp(!0,{},Xm.options,t)),this.chatElement=t.chatElement,this._files=[],this._generating=!1,this._wrapper(),this._initTextArea(),!1!==t.fileAttachment&&this._initUpload(),!1!==t.speechToText&&this._initSpeechToTextButton(),this._attachEvents(),this._typing=!1,this._files=[]}_wrapper(){const e=this.options;const t=e.suggestionsTemplate(e.suggestions);if(this.wrapper=$(`<div class="${pf}"></div>`),e.suggestions.length){const n=e.suggestionsScrollable?Rm(t,"rtl"===e.dir):t;this.suggestions=this.wrapper.append(n)}this.wrapper.find(`[${cm}]`).addClass(nf),this.chatElement.append(this.wrapper)}updateAttachmentList(){const e=this.getAttachmentListContainer();const t=this.options.filesTemplate(this._files,!1,{},!0);0===e.length?this.textAreaInstance._prefixContainer.append(t):e.replaceWith(t),this.textAreaInstance._prefixContainer.find(`[${im}]`).each(((e,t)=>{const n=$(t);n.attr("role")||"button"===n[0].nodeName.toLowerCase()||n.attr("role","button"),n.attr("aria-label")||n.attr("title")||(n.attr("aria-label","Remove selected file"),n.attr("title","Remove selected file"))})),this.toggleSendButton(this._files.length>0)}getAttachmentListContainer(){return this.textAreaInstance._prefixContainer.find(`[${nm}]`)}clearAttachmentList(){this._files=[];const e=this.getAttachmentListContainer();e.length>0&&e.remove(),this.toggleSendButton(!1)}setReplyMessage(e,t){const n=this.getReplyMessageContainer();const i=this.options.messageReferenceTemplate({text:e.text,files:e.files,isOwnMessage:t,renderCloseButton:!0,renderFileMenuButton:!1});0===n.length?this.textAreaInstance._prefixContainer.prepend(i):n.replaceWith(i)}removeReplyMessage(){const e=this.getReplyMessageContainer();e.length>0&&e.remove()}getReplyMessageContainer(){return this.textAreaInstance._prefixContainer.find(`[${am}]`)}toggleSendButton(e){const t=this.wrapper.find(`[${hm}]`);e?t.removeClass(nf):this._generating||t.addClass(nf)}toggleSendButtonGenerating(e){const t=this.wrapper.find(`[${hm}]`);t.toggleClass(sf,e).toggleClass(nf,!e),this._generating=e,e?(t.attr("aria-disabled",!1),t.html(kendo.ui.icon({icon:Zf,iconClass:Zp}))):(t.attr("aria-disabled",!0),t.html(kendo.ui.icon({icon:Xf,iconClass:Zp})))}_attachEvents(){this.element.on("input"+Np,this._input.bind(this)),this.wrapper.on(ap+Np,`[${hm}]`,this._sendButtonClick.bind(this)).on(ap+Np,`[${em}]`,this._fileButtonClick.bind(this)).on(ap+Np,`[${lm}]`,this._replyMessageCloseButtonClick.bind(this)).on(ap+Np,`[${pm}]`,this._suggestionClick.bind(this)).on(ap+Np,`[${cm}]`,this._leftScrollButtonClick.bind(this)).on(ap+Np,`[${dm}]`,this._rightScrollButtonClick.bind(this)).on(ap+Np,`[${im}]`,this._fileCloseButtonClick.bind(this))}_initTextArea(){const e=this.options;const t=e.messages||{};const n="inputId_"+yp();const i=!1!==e.speechToText;const r=!1!==e.fileAttachment;const o=this.element.kendoTextArea({resize:"auto",maxRows:5,placeholder:t.placeholder,suffixOptions:{template:()=>(({messages:e,speechToTextButtonEnabled:t,fileAttachmentButtonEnabled:n})=>{const i=t?`<button title="${e.speechToTextButton}" aria-label="${e.speechToTextButton}" ${um}></button>`:"";const r=n?kendo.html.renderButton(`<button title="${e.fileButton}" aria-label="${e.fileButton}" ${em}></button>`,{icon:Vf,size:"medium",fillMode:"clear"}):"";const o=kendo.html.renderButton(`<button title="${e.sendButton}" aria-label="${e.sendButton}" class="${tf} ${nf}" ${hm}></button>`,{icon:Xf,size:"medium",rounded:"full",fillMode:"solid",themeColor:"primary"});return i+r+(n?`<input type="file" ${fm} id="input_${yp()}" class="k-hidden" />`:"")+`<span class="${zf}"></span>`+o})({messages:t,speechToTextButtonEnabled:i,fileAttachmentButtonEnabled:r}),separator:!1},prefixOptions:{template:()=>"",separator:!1}}).data("kendoTextArea");o.element.attr("id",n),o.wrapper.addClass(uf).appendTo(this.wrapper),this.textAreaInstance=o}_initUpload(){const e=this.wrapper.find(`[${fm}]`).kendoUpload({multiple:!0,async:!1,uniqueFileUids:!0,select:this._uploadSelect.bind(this)}).data("kendoUpload");e.wrapper.addClass(cf),this.uploadInstance=e}_uploadSelect(e){e.preventDefault();const t=e.files;this._files=[...this._files,...t],this.updateAttachmentList()}_initSpeechToTextButton(){const e=this.options;const t={fillMode:"clear",result:this._speechToTextResult.bind(this)};const n=(e=>typeof e===rp&&null!==e)(e.speechToText)?{...t,...e.speechToText}:t;this.speechToTextButtonInstance=this.wrapper.find(`[${um}]`).kendoSpeechToTextButton(n).data("kendoSpeechToTextButton")}_speechToTextResult(e){const t=this.textAreaInstance;let n=t.value();let i="";e.alternatives&&e.alternatives[0]&&(i=e.alternatives[0].transcript,n+=" "+i,t.value(n)),n.length>0&&this.toggleSendButton(!0)}_input(){const e=this.element.val();const t=e.length>0;this.toggleSendButton(t),this.trigger("input",{value:e})}_sendButtonClick(e){e.preventDefault(),this._sendMessage()}_fileButtonClick(e){e.preventDefault(),this.trigger("fileButtonClick")}_fileCloseButtonClick(e){e.preventDefault();const t=$(e.currentTarget).closest(`${op}${Up}`).data("uid");this._files=this._files.filter((e=>e.uid!==t)),this.updateAttachmentList()}_replyMessageCloseButtonClick(e){e.preventDefault(),this.trigger("replyMessageCloseButtonClick")}_suggestionClick(e){e.preventDefault();const t=$(e.target).closest(op+Pf).text();this.trigger("suggestionClick",{text:t}),this.textAreaInstance.value(t),this.toggleSendButton(!0)}_sendMessage(){const e=this.element.val();if(this._generating)return void this.trigger("sendMessage",{generating:!0});if(!e.length&&!this._files?.length)return;const t={text:e,files:this._files};this.trigger("sendMessage",t),this.textAreaInstance.value(""),this.textAreaInstance.updateAutoHeight(),this.clearAttachmentList()}_leftScrollButtonClick(e){e.preventDefault();const t=$(e.currentTarget);const n=this.wrapper.find(`${op}${Lf}`);const i=this.options.dir===dp;const r=Ap(n,i?Em:-200);this.wrapper.find(`[${dm}]`).removeClass(nf),(i?r.atEnd:r.atStart)&&t.addClass(nf)}_rightScrollButtonClick(e){e.preventDefault();const t=$(e.currentTarget);const n=this.wrapper.find(`${op}${Lf}`);const i=this.options.dir===dp;const r=Ap(n,i?-200:Em);this.wrapper.find(`[${cm}]`).removeClass(nf),(i?r.atStart:r.atEnd)&&t.addClass(nf)}destroy(){this.textAreaInstance&&this.textAreaInstance.destroy(),this.speechToTextButtonInstance&&this.speechToTextButtonInstance.destroy(),this.wrapper.remove()}}class Zm extends Fp{static options={name:"MessageToolbar"};constructor(e,t){super(e,bp(!0,{},Zm.options,t)),this.extendItemsConfig(),this.create(),this.attachEvents()}create(){this.element.data("kendoMessageToolbar")&&this.destroy(),this.toolbar=new kendo.ui.ToolBar(this.element,this.options)}extendItemsConfig(){this.options.items&&this.options.items.forEach((e=>{e.attributes=e.attributes||{};let t=e.attributes["aria-label"];e.attributes["data-command"]=e.name.toLowerCase(),e.attributes["aria-label"]=t??e.name,e.type="button",e.fillMode="flat",e.overflow="never"}))}destroy(){this.toolbar&&(this.toolbar.destroy(),this.toolbar=null),this.element.empty()}attachEvents(){this.toolbar.bind(ap,this.onClick.bind(this))}onClick(e){const t=e.target.closest(op+df);const n=e.target.data("command");n&&this.executeCommand(n,e.target,t)}executeCommand(e,t,n){this.trigger("execute",{type:e,item:t,message:n})}}class Jm extends Fp{static options={name:"ChatFileMenu",items:[]};constructor(e,t){super(e,bp(!0,{},Jm.options,t)),this.setCommandAttributes(),this.createDropdownButton()}createDropdownButton(){this.dropdownButton=new kendo.ui.DropDownButton(this.element,{items:this.options.items,fillMode:"flat",icon:Nf}),this.dropdownButton.bind("click",this.onClick.bind(this)).bind("open",this.onOpen.bind(this)).bind("close",this.onClose.bind(this))}setCommandAttributes(){this.options.items.forEach((e=>{e.attributes=e.attributes||{},e.attributes["data-command"]=e.name.toLowerCase(),e.id=e.name.toLowerCase()}))}destroy(){this.dropdownButton&&(this.dropdownButton.destroy(),this.dropdownButton=null),super.destroy()}onClick(e){const t=e.id;const n=$(e.sender.element).closest(op+Up);const i=$(e.sender.element).closest(op+df);t&&this.executeCommand(t,$(e.sender.element),n,i)}onOpen(e){let t=!0;const n=$(e.sender.element);(n.closest(op+Tf).length||n.find(op+Rf).length)&&(e.preventDefault(),t=!1),this.setActive(n,t)}onClose(e){const t=$(e.sender.element);const n=t.closest(op+df);this.setActive(t,!1),this.trigger("close",{message:n})}executeCommand(e,t,n,i){this.trigger("execute",{type:e,item:t,file:n,message:i})}setActive(e,t){const n=e.closest(op+Kp);t?n.addClass($p):n.removeClass($p)}}class eg extends Fp{static options={name:"ChatView"};constructor(e,t){super(e,bp(!0,{},eg.options,t)),this._dataManager=this.options.dataManager,this._list(),this._attachEvents()}get events(){return[]}destroy(){super.destroy(),this.element.find("[data-role='chatfilemenu']").each((function(){const e=$(this).data("kendoChatFileMenu");e&&e.destroy()})),this.element.empty(),this.element.off(Np),this.list=null}_list(){this.element.addClass(bf).attr("role","log").attr("aria-label",this.options.messages.messageListLabel),this.list=$("<div>").addClass(wf).appendTo(this.element)}_attachEvents(){this.element.on(ap+Np,this._listClick.bind(this)).on(ap+Np,op+df,this._messageClick.bind(this)).on(ap+Np,op+Pf,this._suggestionClick.bind(this)).on(ap+Np,`[${cm}]`,this._leftScrollButtonClick.bind(this)).on(ap+Np,`[${dm}]`,this._rightScrollButtonClick.bind(this)).on(ap+Np,op+rf,this._downloadAllClick.bind(this))}renderMessage(e){const t=this.options.messages;const n=this.options.allowMessageCollapse;const i=this.options.messageWidthMode===Cm;const r={id:e.authorId,name:e.authorName,imageUrl:e.authorImageUrl,imageAltText:e.authorImageAltText};const o=r.id===this.options.authorId;const a=this.getReplyMessage(e);const s=this.options.messageTimeFormat;const l=this.options.skipSanitization;if(this._handleExistingMessageUpdate({message:e,author:r,isOwnMessage:o,replyMessage:a,componentMessages:t,expandable:n,messageTimeFormat:s,skipSanitization:l}))return;const c=this._findTargetMessageGroup();if(this._canGroupWithLastMessage(c,r.id)&&c.length)this._addMessageToExistingGroup({message:e,author:r,isOwnMessage:o,replyMessage:a,componentMessages:t,expandable:n,targetGroupElement:c,messageTimeFormat:s,skipSanitization:l});else{const c=this._shouldShowTimestamp(e);this._createNewMessageGroup({message:e,author:r,isOwnMessage:o,replyMessage:a,componentMessages:t,expandable:n,fullWidth:i,messageTimeFormat:s,showTimestamp:c,skipSanitization:l})}}_shouldShowTimestamp(e){if(!e.timestamp)return!1;const t=this.list.find(op+df).filter((function(){return 0===$(this).find(op+Rf).length})).last();if(!t.length)return!0;const n=this.dataItem(t);if(!n||!n.timestamp)return!0;const i=kendo.parseDate(e.timestamp);const r=kendo.parseDate(n.timestamp);if(!i||!r)return!1;const o=new Date(i);o.setHours(0,0,0,0);const a=new Date(r);return a.setHours(0,0,0,0),o.getTime()!==a.getTime()}_initMessageToolbar(e){const t=this.options;const n=t.messageToolbarActions;if(!n||!n.length||!e.length)return void e.remove();new Zm(e,{items:n,dir:t.dir,messages:t.messages,resizable:!1}).bind("execute",(e=>this.trigger("messageToolbarExecute",e)))}_initFileMenus(e){const t=this.options.fileActions;const n=e.find(`[${tm}]`);t&&t.length&&e.length?n.each(((e,n)=>{const i=$(n);if(!i.data("kendoDropDownButton")){new Jm(i,{items:t}).bind("execute",(e=>this.trigger("fileMenuExecute",e)))}})):n.remove()}_handleExistingMessageUpdate({message:e,author:t,isOwnMessage:n,replyMessage:i,componentMessages:r,expandable:o,messageTimeFormat:a,skipSanitization:s}){const l=this.list.find(op+df+`[data-uid="${Cp(e.uid)}"]`);if(l.length){const c=this.options.messageTemplate;const d=$(c({...e,isOwnMessage:n,author:t},i,!0,r,o,a,s));return l.replaceWith(d),this._initMessageToolbar(d.find(op+Af)),this._initFileMenus(d),!0}return!1}_findTargetMessageGroup(){let e=this.list.children(op+ff).last();let t=e;const n=e.find(op+df);if(1===n.length){n.first().find(op+Rf).length>0&&(t=e.prev(op+ff))}return t}_canGroupWithLastMessage(e,t){const n=e.find(op+df).filter((function(){return 0===$(this).find(op+Rf).length})).last();const i=this.dataItem(n);return i&&i.authorId===t}_addMessageToExistingGroup({message:e,author:t,isOwnMessage:n,replyMessage:i,componentMessages:r,expandable:o,targetGroupElement:a,messageTimeFormat:s,skipSanitization:l}){const c=this.options.messageTemplate;const d=a.find(op+mf);const h=$(c({...e,isOwnMessage:n,author:t},i,!0,r,o,s,l));d.append(h),this._initMessageToolbar(h.find(op+Af)),this._initFileMenus(h),this._moveTypingIndicatorsToEnd()}_createNewMessageGroup({message:e,author:t,isOwnMessage:n,replyMessage:i,componentMessages:r,expandable:o,fullWidth:a,messageTimeFormat:s,showTimestamp:l=!1,skipSanitization:c}){const d=this.options.messageGroupTemplate;const h=this.options.timestampTemplate;const u=this.options.messageTemplate;const p=$(d({message:e,author:t,isOwnMessage:n,replyMessage:i,downloadAll:!0,messages:r,expandable:o,fullWidth:a,messageTimeFormat:s,timestampTemplate:h,showTimestamp:l,messageTemplate:u,skipSanitization:c}));return this.list.append(p),this._initMessageToolbar(p.find(op+Af)),this._initFileMenus(p),this._moveTypingIndicatorsToEnd(),p}_moveTypingIndicatorsToEnd(){const e=this;const t=this.options.messageGroupTemplate;const n=this.options.messageWidthMode===Cm;e.list.find(op+df).filter((function(){return $(this).find(op+Rf).length>0})).each((function(){const i=$(this);const r=i.closest(op+ff);if(1===r.find(op+df).length)r.detach().appendTo(e.list);else{i.remove();const r=e.dataItem(i);const o={id:r.authorId,name:r.authorName,imageUrl:r.authorImageUrl,imageAltText:r.authorImageAltText};const a=$(t({message:r,author:o,isOwnMessage:o.id===e.options.authorId,fullWidth:n,messageTimeFormat:e.options.messageTimeFormat,showTimestamp:!1,timestampTemplate:e.options.timestampTemplate,messageTemplate:e.options.messageTemplate}));e.list.append(a)}}))}dataItem(e){const t=e&&e.data("uid");return t?this._dataManager.getMessageByUid(t):null}fileDataItem(e,t){const n=t&&t.data("uid");return n?this._dataManager.getFileByUid(e,n):null}getReplyMessage(e){if(!e?.replyToId)return null;const t=this._dataManager.getMessageById(e.replyToId);return t.isOwnMessage=t?.authorId===this.options.authorId,t}renderSuggestedActions(){const e=this.options;const t=this._dataManager.getLastMessage()?.suggestedActions||[];const n=e.suggestedActionsTemplate(t);const i=e.suggestedActionsScrollable?Rm(n,"rtl"===e.dir):n;this._removeSuggestedActions(),this.list.append(t.length?i:""),this.list.find(`[${cm}]`).addClass(nf)}removeMessage(e){const t=this.list.find(op+df+`[data-uid="${Cp(e)}"]`);if(!t.length)return!1;const n=t.closest(op+ff);return 1===n.find(op+df).length?n.remove():t.remove(),!0}clearMessages(){this.list.find(op+ff).remove(),this.list.find(op+Hf).remove(),this._removeSuggestedActions()}scrollToBottom(){this.element.scrollTop(this.element.prop("scrollHeight"))}scrollToMessage(e){if(!e)return!1;const t=this.list.find(op+df+`[data-uid="${Cp(e)}"]`);return!!t.length&&((e,t,n={})=>{if(!e.length||!t.length)return!1;const{duration:i=0,easing:r="linear",position:o="center",offset:a=0,onComplete:s}=n;const l=e.height();const c=e.scrollTop();const d=e.offset();const h=t.offset();const u=t.outerHeight();const p=h.top-d.top+c;let f;switch(o){case"top":f=p+a;break;case"bottom":f=p-l+u+a;break;default:f=p-l/2+u/2+a}const m=e[0].scrollHeight-e[0].clientHeight;return f=Math.min(Math.max(f,0),m),e.finish().animate({scrollTop:f},i,r,s),!0})(this.element,t,{position:"top"})}_leftScrollButtonClick(e){e.preventDefault();const t=$(e.currentTarget);const n=this.element.find(`${op}${Lf}`);const i=this.options.dir===dp;const r=Ap(n,i?Em:-200);this.element.find(`[${dm}]`).removeClass(nf),(i?r.atEnd:r.atStart)&&t.addClass(nf)}_rightScrollButtonClick(e){e.preventDefault();const t=$(e.currentTarget);const n=this.element.find(`${op}${Lf}`);const i=this.options.dir===dp;const r=Ap(n,i?-200:Em);this.element.find(`[${cm}]`).removeClass(nf),(i?r.atStart:r.atEnd)&&t.addClass(nf)}_removeSuggestedActions(){this.list.find(op+Lf).remove(),this.list.find(op+Bf).remove()}_listClick(e){const t=$(e.target);t.hasClass(df)||t.parents(op+df).length||this._clearSelection(t)}_suggestionClick(e){const t=$(e.currentTarget);t.length&&this.trigger("suggestedActionClick",{text:t.text()})}_messageClick(e){const t=$(e.target);const n=t.closest(`[${rm}]`);if(this._allowMessageClick(t))return;if(this._clearSelection(t),n.length){const e=n.closest(op+Kp);const t=e.hasClass(af);return e.toggleClass(af,!t),n.html(kendo.ui.icon({icon:t?$f:jf})),void this.trigger("expandableToggle",{indicator:n,isExpanded:!t})}$(e.currentTarget).find(op+Kp).addClass(Ef)}_allowMessageClick(e){const t=[`[${tm}]`,op+Af,op+Rf,op+rf].join(", ");return e.closest(t).length>0||e.children(t).length>0||e.is(t)}_clearSelection(e){const t=this.element.find(op+Ef);e.closest(`[${rm}]`).length||t.each(((e,t)=>{$(t).removeClass(Ef)}))}_downloadAllClick(e){const t=$(e.currentTarget).closest(op+df);t.length&&this.trigger("downloadAllFiles",{messageElement:t})}_refreshDataManager(e){this._dataManager=e}}class tg{static options={autoSync:!0,schema:{model:{id:"id",fields:{id:{type:"string"},text:{type:"string"},authorId:{type:"string"},authorName:{type:"string"},authorImageUrl:{type:"string"},authorImageAltText:{type:"string"},replyToId:{type:"string",defaultValue:null},isDeleted:{type:"boolean",defaultValue:!1},isPinned:{type:"boolean",defaultValue:!1},isTyping:{type:"boolean",defaultValue:!1},timestamp:{type:"date"},files:{parse:e=>e||[]}}}}};constructor(e){this.dataSource=this.createDataSource(e)}createDataSource(e){let t;return e.dataSource instanceof kendo.data.DataSource?this.options=bp(!0,{},tg.options,e.dataSource.options):e.dataSource instanceof Array?this.options=bp(!0,{},tg.options,{data:e.dataSource}):this.options=bp(!0,{},tg.options,e.dataSource),this.mapFields(this.options.schema.model.fields,e),t=kendo.data.DataSource.create(this.options),t}mapFields(e,t){const n={text:"textField",authorId:"authorIdField",authorName:"authorNameField",authorImageUrl:"authorImageUrlField",authorImageAltText:"authorImageAltTextField",id:"idField",timestamp:"timestampField",files:"filesField",replyToId:"replyToIdField",isDeleted:"isDeletedField",isPinned:"isPinnedField",isTyping:"isTypingField"};for(const i in e)e.hasOwnProperty(i)&&n[i]&&(e[i].from=t[n[i]])}removeMessage(e){return!!e&&(e.set("isDeleted",!0),!0)}updateMessage(e,t){if(!e)return null;e instanceof kendo.data.ObservableObject||(e=this.getMessageById(e.id));for(let n in t)t.hasOwnProperty(n)&&e.set(n,t[n]);return e}getMessageById(e){return e?this.dataSource.get(e):null}getMessageByUid(e){return this.dataSource.getByUid(e)}getFileByUid(e,t){if(!e||!t)return null;return e.files.find((e=>e.uid===t))||null}postMessage(e,t){let n;return"string"==typeof e&&(e={text:e}),n={timestamp:new Date,files:[],...e,authorId:e.authorId?.toString()||t},this.dataSource.add(n)}pinMessage(e){return!!e&&(this.getPinnedMessage()?.set("isPinned",!1),e.set("isPinned",!0))}clearPinnedMessage(){this.getPinnedMessage()?.set("isPinned",!1)}getPinnedMessage(){return this.dataSource.data().find((e=>e.isPinned))||null}getView(){return this.dataSource.view()}getDataSource(){return this.dataSource}getLastMessage(){const e=this.getView();return e.length?e[e.length-1]:null}}class ng extends Fp{static options={name:"ChatMessageMenu",filter:`${op}${Jp}`,dataSource:[],keyboardAlignToAnchor:!0};constructor(e,t){super(e,bp(!0,{},ng.options,t)),this.setCommandAttributes(),this.create(),this.attachEvents()}create(){this.menu=new kendo.ui.ContextMenu(this.element,this.options)}destroy(){this.menu&&(this.menu.destroy(),this.menu=null,this.element.remove())}attachEvents(){this.menu.bind("select",this.onSelect.bind(this)).bind("open",this.onOpen.bind(this)).bind("close",this.onClose.bind(this))}setCommandAttributes(){this.options.dataSource.forEach((e=>{e.attr=e.attr||{},e.attr["data-command"]=e.name.toLowerCase()}))}onSelect(e){const t=$(e.item);const n=$(e.target).closest(op+df);const i=t.data("command");i&&this.executeCommand(i,t,n)}onOpen(e){let t=!0;const n=$(e.target);const i=$(e.event?.target).length?$(e.event.target):n;const r=n.closest(op+Tf).length>0;const o=n.find(op+Rf).length>0;const a=i.closest(`[${tm}]`).length>0;const s=n.closest(op+df);(r||o||a||!s.length)&&(e.preventDefault(),t=!1),n.toggleClass($p,t),this.trigger("open",{message:s})}onClose(e){const t=$(e.target);const n=t.closest(op+df);t.removeClass($p),this.trigger("close",{message:n})}executeCommand(e,t,n){this.trigger("execute",{type:e,item:t,message:n})}toggleDeleteVisibility(e){const t=this.element.find("[data-command='delete']");t.length&&t.toggleClass(cf,!e)}}class ig extends Fp{static options={name:"Chat",autoBind:!0,allowMessageCollapse:!1,authorId:null,suggestionsScrollable:!1,suggestedActionsScrollable:!1,speechToText:!0,fileAttachment:!0,messageToolbarActions:[],messageActions:[{name:Sm,text:"Reply",icon:Kf},{name:Tm,text:"Copy",icon:Yf},{name:Mm,text:"Pin",icon:Gf},{name:Am,text:"Delete",icon:Qf}],fileActions:[{name:Dm,text:"Download",icon:qf}],suggestions:[],headerItems:[],dir:"ltr",messageTimeFormat:"ddd MMM dd yyyy",width:null,height:null,messages:{messageListLabel:"Message list",placeholder:"Type a message...",sendButton:"Send message",speechToTextButton:"Toggle speech to text",fileButton:"Attach file",downloadAll:"Download all",selfMessageDeleted:"You removed this message.",otherMessageDeleted:"This message was removed by its sender.",stopGeneration:"Stop generation",messageBoxLabel:"Type your message here",pinnedMessageCloseButton:"Unpin message",replyMessageCloseButton:"Remove reply",fileMenuButton:"File menu"},messageWidthMode:xm,messageTemplate:zm,messageGroupTemplate:Pm,messageReferenceTemplate:Bm,filesTemplate:Lm,suggestionsTemplate:Hm,suggestedActionsTemplate:Hm,timestampTemplate:null,textField:"text",authorIdField:"authorId",authorNameField:"authorName",authorImageUrlField:"authorImageUrl",authorImageAltTextField:"authorImageAltText",idField:"id",timestampField:"timestamp",filesField:"files",replyToIdField:"replyToId",isDeletedField:"isDeleted",isPinnedField:"isPinned",isTypingField:"isTyping",skipSanitization:!1};static mergeContextMenuActions(e,t,n){const i=e[n];if(Array.isArray(i)){const r=t[n]||[];const o={};for(const e of r)o[e.name]={...e};e[n]=i.map((e=>e.name in o?{...o[e.name],...e}:{...e}))}else e[n]=t[n]||[]}constructor(e,t,n){t=t||{},ig.mergeContextMenuActions(t,ig.options,"messageActions"),ig.mergeContextMenuActions(t,ig.options,"fileActions"),super(e,bp(!0,{},ig.options,t)),this.options.messageActions=t.messageActions,this.options.fileActions=t.fileActions,n&&(this._events=n),this._init(t),kendo.notify(this)}get events(){return[mm,gm,vm,_m,bm,wm,ym,km]}_init(e){this.currentMessageReplyId=null,this._hasHeader=!!e.headerItems?.length,this._user(),this._wrapper(),this._dataSource(),this._view(),this.options.autoBind&&this.dataSource.fetch(),e?.toolbar&&kp("The 'toolbar' option has been deprecated.","warn"),this._messageBox(),this._createMenus(),this._attachEvents(),Nm(this.wrapper,this.options),$m(this.wrapper),this.scrollToBottom()}setOptions(e){super.setOptions(e),this.destroy(),this._init(e)}destroy(){this.dataSource&&(this._unbindDataSource(),this.dataSource=null),this.view&&(this.view.unbind(),this.view.destroy(),this.view=null),this.messageBox&&(this.messageBox.unbind(),this.messageBox.destroy(),this.messageBox=null),this.messageContextMenu&&this.messageContextMenu.destroy(),this.wrapper&&(this.wrapper.off(),this.wrapper.empty(),this.wrapper=null),super.destroy()}_attachEvents(){const e=this;this.view.bind("suggestedActionClick",(function(t){const n={text:t.text};e.trigger(mm,{message:n}),e.postMessage(n)})).bind("messageToolbarExecute",(function(t){const n=e.dataItem(t.message);e.trigger(bm,{type:t.type,message:n})})).bind("fileMenuExecute",(function(t){e.commandExecute(t)})).bind("downloadAllFiles",(function(t){const n=e.dataItem(t.messageElement);e.trigger(km,{files:n.files,message:n})})).bind("expandableToggle",(function(e){Um(e.indicator,e.isExpanded)})),this.messageBox.bind("input",(function(t){e.trigger(_m,{value:t.value})})).bind("sendMessage",(function(t){const n=t.generating;if(n)e.trigger(mm,{generating:n});else{const n={text:t.text,files:t.files};e.trigger(mm,{message:n}),e.postMessage(n),e.clearReplyState()}})).bind("suggestionClick",(function(t){e.trigger(gm,{text:t.text})})).bind("fileButtonClick",(function(){e.messageBox.wrapper.find(`[${fm}]`).trigger("click")})).bind("replyMessageCloseButtonClick",(function(){e.clearReplyState()})),this.messageContextMenu.bind("execute",this.commandExecute.bind(this)).bind("open",this.messageContextMenuOpen.bind(this)),this.wrapper.on(ap+Np,`[${sm}]`,(()=>{this.trigger(vm,{message:this._dataManager.getPinnedMessage()}),this.clearPinnedMessage()})),this.wrapper.on(ap+Np,`[${om}]`,(e=>{if($(e.target).closest(`[${sm}]`).length)return;if($(e.target).is("a"))return;e.preventDefault(),e.stopPropagation();const t=this._dataManager.getPinnedMessage();t&&t.uid&&this.scrollToMessage(t.uid)})),this.wrapper.on(ap+Np,`[${am}]`,(e=>{if($(e.target).is("a"))return;e.preventDefault(),e.stopPropagation();const t=$(e.currentTarget).closest(op+df);const n=this.dataItem(t);if(n&&n.replyToId){const e=this._dataManager.getMessageById(n.replyToId);e&&e.uid&&this.scrollToMessage(e.uid)}})),this.wrapper.on("keydown"+Np,(e=>{((e,t,n)=>{if(!$(e.target).closest(t).length)return null;const i=$(e.target);const r=e.keyCode||e.which;Om=!0,Vm=e.shiftKey,i.hasClass(Kp)&&jm(e,r,t),i.hasClass(Pf)&&Km(e,r),i.hasClass(Xp)&&qm(e,r),i.hasClass("k-input-inner")&&Gm(e,r,t,n),i.closest(".k-input-suffix .k-button").length&&Km(e,r)})(e,this.wrapper,this.messageBox)})),this.wrapper.on(`focus${Np}`,`.${Kp}`,(e=>{const t=$(e.target);if(!(t.find(`.${Rf}`).length>0)&&"true"===t.attr("data-keyboard-focus")){const e=t.closest(`.${df}`);const n=this.dataItem(e);n&&n.uid&&this.scrollToMessage(n.uid)}}))}_dataSource(){const e=this;const t=e.options;e._refreshHandler=e.refresh.bind(e),e._dataManager=new tg(t),e.dataSource=e._dataManager.getDataSource(),e.dataSource.bind(cp,e._refreshHandler)}_unbindDataSource(){this.dataSource.unbind(cp,this._refreshHandler),this._dataManager=null}setDataSource(e){const t=this;t.dataSource&&t._unbindDataSource(),t.view.clearMessages(),t.options.dataSource=e,t._dataSource(),t.options.autoBind&&t.dataSource.fetch(),this.view&&this.view._refreshDataManager(t._dataManager)}_user(){const e=this.options;e.authorId?this.options.authorId=e.authorId.toString():this.options.authorId=yp()}getUserId(){return this.options.authorId}_wrapper(){const e=this.options;const t=e.height;const n=e.width;const i=e.headerItems;const r="<div class='"+Ff+"'></div>";var o;this.wrapper=this.element.addClass(Of).attr("dir",e.dir).append(r),this._hasHeader&&this.wrapper.prepend((o=i,new kendo.ui.AppBar(`<div class="${lf}">`,{items:o,positionMode:"sticky"}).element[0].outerHTML)),t&&this.wrapper.css({height:t,minHeight:t}),n&&this.wrapper.css({width:n,minWidth:n})}_view(){const e=bp(!0,{},this.options,{dataManager:this._dataManager});const t=this.wrapper.find(op+Ff+"");this.view=new eg(t,e)}_messageBox(){const e=bp(!0,{},this.options,{chatElement:this.wrapper});this.messageBox=new Xm($("<textarea></textarea>"),e)}_createMenus(){const e=this.options.messageActions;this.messageContextMenu=new ng($("<ul></ul>"),{dataSource:e})}commandExecute(e){const t=this.dataItem(e.message);const n=this.fileDataItem(t,e.file);const i=e.type;if(n){if(i===Dm)this.trigger(km,{files:[n],message:t});this.trigger(wm,{type:i,file:n,message:t})}else{switch(i){case Sm:this.messageReply(t);break;case Tm:this.messageCopy(t);break;case Mm:this.messagePin(t);break;case Am:this.messageDelete(t)}this.trigger(ym,{type:i,message:t})}}messageReply(e){const t=e.authorId===this.getUserId();this.currentMessageReplyId=e.id,this.messageBox.setReplyMessage(e,t),Ym(this.wrapper,this.options)}messageCopy(e){navigator&&navigator.clipboard&&navigator.clipboard.writeText(e.text)}messagePin(e){this._dataManager.pinMessage(e)}messageDelete(e){this.removeMessage(e)}messageContextMenuOpen(e){const t=this.dataItem(e.message);if(!t)return;const n=t.authorId===this.getUserId();this.messageContextMenu.toggleDeleteVisibility(n)}dataItem(e){return this.view.dataItem(e)}fileDataItem(e,t){return this.view.fileDataItem(e,t)}clearMessages(){this.view.clearMessages()}postMessage(e){this.currentMessageReplyId&&(e.replyToId=this.currentMessageReplyId);return this._dataManager.postMessage(e,this.getUserId())}removeMessage(e){return this._dataManager.removeMessage(e)}updateMessage(e,t){return this._dataManager.updateMessage(e,t)}getMessageByUid(e){return this._dataManager.getMessageByUid(e)}renderMessage(e){this.view.renderMessage(e),$m(this.wrapper)}renderPinnedMessage(e){const t=e.authorId===this.getUserId();const n=$(this.options.messageReferenceTemplate({text:e.text,files:e.files,isDeleted:e.isDeleted,isOwnMessage:t,messages:this.options.messages,isPinMessage:!0,renderCloseButton:!0,renderFileMenuButton:!1}));this.wrapper.find(`[${om}]`).remove(),this._hasHeader?n.insertAfter(this.wrapper.find(op+lf)):this.wrapper.prepend(n),this.view._initFileMenus(n)}clearPinnedMessage(){this._dataManager.clearPinnedMessage(),this.wrapper.find(op+yf).remove()}clearReplyState(){this.messageBox.removeReplyMessage(),this.currentMessageReplyId=null}scrollToBottom(){this.view.scrollToBottom()}scrollToMessage(e){return this.view.scrollToMessage(e)}toggleSendButtonGenerating(e){this.messageBox.toggleSendButtonGenerating(e)}refresh(e){const t=this;const n=t.dataSource.view();const i=n.find((e=>e.isPinned));const r=e.changedItems||[];if(e&&e.action||(n.forEach((e=>{t.renderMessage(e)})),t.scrollToBottom()),i&&t.renderPinnedMessage(i),"sync"===e.action){const e=r.length?r[0]:n[n.length-1];t.renderMessage(e),r.length||t.scrollToBottom()}t.view.renderSuggestedActions(),Nm(t.wrapper,t.options),$m(t.wrapper)}}kendo.chat={},bp(kendo.chat,{ChatView:{},Component:{},Components:{},Templates:{},getTemplate:()=>kp("The getTemplate method is deprecated. Use one of the built-in templates or append elements manually.","warn"),getComponent:()=>kp("The getComponent method is deprecated. Use one of the built-in templates or append elements manually.","warn"),registerTemplate:()=>kp("The registerTemplate method is deprecated. Use one of the built-in templates or append elements manually.","warn"),registerComponent:()=>kp("The registerComponent method is deprecated. Use one of the built-in templates or append elements manually.","warn")}),function(e,t=kendo.ui,n=""){const i=e.options?.name||e.fn.options.name;let r;t[i]=e,t.roles[i.toLowerCase()]=e,e.prototype.options={...e.prototype.options,...e.options},e.fn.options={...e.fn.options,...e.options},r="getKendo"+n+i;const o="kendo"+n+i;const a={name:o,widget:e,prefix:n||""};kendo.widgets.push(a);const s=window.jQuery||jQuery||kendo?.jQuery;s.fn[o]=function(t){let n=this;let i;return"string"==typeof t?(i=Vp.call(arguments,1),this.each((function(){const e=s.data(this,o);let r;let a;if(!e)throw new Error(kendo.format("Cannot call method '{0}' of {1} before it is initialized",t,o));if(r=e[t],!_p(r))throw new Error(kendo.format("Cannot find method '{0}' of {1}",t,o));if(a=r.apply(e,i),void 0!==a)return n=a,!1}))):this.each((function(){return new e(this,t)})),n},s.fn[o].widget=e,s.fn[r]=function(){return this.data(o)}}(ig);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=n.sanitizeLink,l=".kendoBreadcrumb",c="aria-hidden",d="click",h="blur",u="keydown",p="change",f=".";var m={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"};var g=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(d+l,"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:[p,d],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(l)},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(p,{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(f+m.item),o=r.prevAll().addBack(),a=n._getItems(o),s=n._path(a),l=n._segments[r.index()];i.navigational||t.preventDefault(),n.trigger(d,{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(c,!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(c,!0),i.hide(),o.show(),n.val(""),t._update(a),r.removeClass(m.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(m.textbox)||e.closest(f+m.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(m.focused)},_wrapperBlur:function(t){e(t.target).removeClass(m.focused)},_wrapper:function(){var t=this,n=this.element,i=n.is("input"),r=e('<div class="'+m.inputWrapper+'"><span class="'+m.textboxWrapper+'"></span></div>');t.wrapper=i?n.wrap(e("<nav />")).parent():n,i?(t.element.wrap(r).addClass(m.textbox),t.inputWrapper=t.wrapper.find(f+m.inputWrapper).hide()):t.inputWrapper=t.wrapper.append(r).find(f+m.inputWrapper).hide(),t.wrapper.addClass(m.widget),t.wrapper.attr("aria-label","Breadcrumb"),t.overlay=t.wrapper.append(e("<ol />").addClass(m.overlay)).find(f+m.overlay)},_editable:function(){var t=this,n=t.element.is("input");t.input=n?t.element:e("<input />"),t.inputWrapper.find(f+m.textboxWrapper.split(" ")[0]).append(t.input),t.input.addClass(m.textbox).attr(c,!0),t.input.on(h+l,t._blur.bind(t,!1)).on(u+l,t._keydown.bind(t)),t.wrapper.on("focus"+l,t._wrapperFocus.bind(t)).on(h+l,t._wrapperBlur.bind(t)).on(u+l,t._wrapperKeydown.bind(t)).on(d+l,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,h=d.messages,u=c.options.delimiterIcon,p="",f="",g=""===c.value(),v=c._segments;for("chevron-right"==u&&c.isRtl()&&(u="chevron-left"),a=0,s=v.length;a<s;a++)i=v[a],l=a===v.length-1,i!==t&&(p?f+=i.text||i||"":f="/","string"==typeof i?(i={type:p?"item":"rootitem",href:d.navigational?f:"#",text:i,showIcon:!p,showText:!!p,icon:p?"":d.rootIcon,itemClass:p?"":"k-breadcrumb-root-item",linkClass:p?"":m.rootLink,delimiterIcon:u,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:u,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+=" "+m.rootLink)),"rootitem"===i.type&&""===i.text&&(i.title=h.rootTitle),f+=f.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)}):"";const r=t.renderDelimiter?n.ui.icon(e('<span class="k-breadcrumb-delimiter-icon" aria-hidden="true"></span>'),{icon:a(t.delimiterIcon),size:"xsmall"}):"";const o=t.showText?`<span class="k-breadcrumb-item-text">${!1!==t.encoded?a(t.text):t.text}</span>`:"";const l=`<a href="${s(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":""}">${l}${r}</li>`},_displayOverflowIcons:function(e){var t=this.wrapper.find(f+m.rootItem);e?t.find(f+m.delimiter).addClass(m.overflowIcon).removeClass(m.hidden):t.find(f+m.overflowIcon).removeClass(m.overflowIcon).last().addClass(m.hidden)},_shrinkItems:function(){var t,i,r=this,o=r.wrapper,a=r.overlay,s=r.overlay.find(f+m.item+":not(.k-breadcrumb-root-item)"),l=n._outerWidth(r.overlay.find(f+m.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(f+m.delimiter).hide(),i.find(f+m.link).hide(),r._displayOverflowIcons(!0)}t&&t.find(f+m.delimiter).show()}},_showItem:function(e,t,i){return!!(e.length&&i>t+n._outerWidth(e,!0))&&(e.find(f+m.link).show(),e.prev().find(f+m.delimiter).show(),!0)},_stretchItems:function(){var t,i,r=this,o=r.wrapper,a=r.overlay,s=r.overlay.find(f+m.item+":not(.k-breadcrumb-root-item)"),l=n._outerWidth(r.overlay.find(f+m.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(g)}(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",h="readonly",u="aria-readonly",p="aria-hidden",f="checked",m=a.click+r,g=a.pointers?"pointerup":"touchend",v="keydown"+r,_=".",b=n.htmlEncode;var w=n.template((({styles:e})=>`<span class="${e.widget}" role="switch"></span>`));var y=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>`));var k=n.template((({styles:e})=>`<span class='${e.thumbWrapper}'><span class='${e.thumb}'></span></span>`));var 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(w({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(y({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(h),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(h,!0),i.attr(u,!0)):(n.prop(h,!1),i.removeAttr(u)),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;const rg=window.kendo;const og=rg.jQuery;const ag=rg.ui.Widget;const sg=rg.isFunction;var lg=ag.extend({options:{name:"Label",widget:null},init:function(e,t){var n=this;e=e||og("<label></label>"),ag.fn.init.call(n,e,t),t=og.extend(!0,{},t),n.widget=t.widget,t.floating&&n._floatingLabel(),n._label()},destroy:function(){this.floatingLabel&&this.floatingLabel.destroy(),ag.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;var n=!1;("string"==typeof e||og.isPlainObject(e)&&!1===e.floating)&&(n=!0),e=og.isPlainObject(e)?e:{content:e},ag.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;var t=e.widget.element;var n=e.options;var i=t.attr("id");var r=n.content;var o=n.floating||!1;sg(r)&&(r=r.call(e)),r||(r=""),i||(i=n.name+"_"+rg.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;var t=og.extend({},e.options);delete t.name,(t.floating||!1)&&(e._floatingLabelContainer=e.widget.wrapper.wrap("<span></span>").parent(),e.floatingLabel=new rg.ui.FloatingLabel(e._floatingLabelContainer,og.extend({},t)))}});rg.ui.plugin(lg);!function(e){const t=kendo.htmlEncode;const n=kendo.ui.Widget;const i=kendo.template;const r=e.extend;const o=kendo.guid();const a="k-disabled";const s="aria-disabled";const l=/^#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/;const c="k-actionsheet-view";const d="k-actionsheet-content";const h=e=>{const t=e.startButton?'<div class="k-actionsheet-actions">'+kendo.html.renderButton(`<button ${kendo.attr("ref-actionsheet-start-button")} aria-label="${e.startButton.text||"Start"}"></button>`,{icon:"chevron-left",fillMode:"flat",size:"large",...e.startButton})+"</div>":"";e.closeButton&&kendo.html.renderButton(`<button ${kendo.attr("ref-actionsheet-close-button")}></button>`,{icon:"x",fillMode:"flat",size:"large"});const n=e.subtitle||""===e.subtitle?`<div class="k-actionsheet-subtitle k-text-center">${e.subtitle||""}</div>`:"";return'<div class="k-text-center k-actionsheet-titlebar" >'+(e.title||""===e.title?'<div class="k-actionsheet-titlebar-group k-hbox">'+t+`<div id="${o}" class="k-actionsheet-title">`+`<div class="k-text-center">${e.title}</div>`+n+"</div>"+(e.closeButton?'<div class="k-actionsheet-actions">'+kendo.html.renderButton(`<button ${kendo.attr("ref-actionsheet-close-button")} aria-label="${e.closeButton.text||"Close"}"></button>`,{icon:"x",fillMode:"flat",size:"large",...e.closeButton})+"</div>":"")+"</div>":"")+"</div>"};const u=({disabled:e,icon:n,text:i,description:r})=>`<span role="button" tabindex="0" class="k-actionsheet-item ${e?a:""}"><span class="k-actionsheet-action">`+(n?`<span class="k-icon-wrap">${n}</span>`:"")+'<span class="k-actionsheet-item-text">'+`<span class="k-actionsheet-item-title">${t(i)}</span>`+(r?'<span class="k-actionsheet-item-description">'+t(r)+"</span>":"")+"</span></span></span>";const p={text:"",description:"",iconClass:"",iconSize:0,iconColor:"",click:e.noop,group:"top",disabled:!1};const f={text:"",icon:"",iconClass:"",click:e.noop,disabled:!1};function m(t){var n;var i={};return t.iconClass||t.icon?(n=e(kendo.html.renderIcon({icon:t.icon,iconClass:t.iconClass+" k-actionsheet-item-icon"})),t.iconColor&&l.test(t.iconColor)?i.color=t.iconColor:t.iconColor&&n.addClass("k-text-"+t.iconColor),t.iconSize&&(i.fontSize=t.iconSize+"px"),Object.keys(i).length&&n.css(i),n):""}function g(e){return r({},p,e)}function v(e){return r({},f,e)}const _=n.extend({init:function(e,t){const i=this;t=t||{},n.fn.init.call(i,e,t),t=r(!0,{},i.options,t),i._hasItems=t.items&&t.items.length,i._hasActionButtons=t.actionButtons&&t.actionButtons.length,i.index=t.index||1,i.ref=i.options.ref,i._mapItems(),i._mapActionButtons(),i._createContent(),i._createHeader(),i._createFooter(),i._wrapInView()},options:{id:"actionsheet-view",name:"ActionSheetView",headerTemplate:null,contentTemplate:null,footerTemplate:null,actionButtons:[],title:null,items:[],actionButtonsAlignment:"stretched",actionButtonsOrientation:"horizontal",closeButton:!1,startButton:!1,ref:"actionsheet-view",addAnimationClass:!1},_hasOtherView:function(){const e=this.element.children(`.${c}`);return e.length&&e.last()},_mapItems:function(){var e=this;e._hasItems&&(e.options.items=e.options.items.map(g))},_mapActionButtons:function(){var e=this;e._hasActionButtons&&(e.options.actionButtons=e.options.actionButtons.map(v))},_createContent:function(t){const n=this;const r=n.options;const o=e(`<div class='${d}'></div>`);const a=n._hasOtherView();a&&a.length?n.element.append(o):n.element.wrapInner(o);const s=n._content=n.element.children("."+d);if(n._hasItems)return s.empty(),void n._items();(r.contentTemplate||t)&&s.html(i(t||r.contentTemplate)(r))},_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);var n=t.top;var i=t.bottom;e._createItems(n),n&&n.length&&i&&i.length&&e._content.append('<hr class="k-hr" />'),e._createItems(i)}},_createItems:function(t){var n;var o;var a;var s;var l=this._content;var c=e("<div class='k-list-ul' role='group'></div>");var d;if(t&&t.length)for(l.append(c),a=i(u),n=0;n<t.length;n++)d=m(o=t[n]),s=e(a(r({},o,{icon:d&&d.prop("outerHTML")}))),c.append(s),o.click&&s.data("action",o.click)},_createHeader:function(){var t=this;var n=t.options;if(!n.title&&""!==n.title&&!n.headerTemplate)return;const r=t._hasOtherView();t._header=e(i(n.headerTemplate||h)(n)),r&&r.length?t._content.before(t._header):t.element.prepend(t._header)},_createFooter:function(t){const n=this;const r=n.options;let o;if(n._hasActionButtons||r.footerTemplate||t){if(o=n._footer=e("<div class='k-actionsheet-footer'></div>"),o.insertAfter(n._content),n._hasActionButtons)return o.addClass(`k-actions k-actions-${r.actionButtonsAlignment} k-actions-${r.actionButtonsOrientation}`),void n._createActionButtons();(r.footerTemplate||t)&&n._footer.append(i(t||r.footerTemplate)(r))}},_createActionButtons:function(){var t=this.options.actionButtons;var n=this._footer;var i;for(var r=0;r<t.length;r++){var o=t[r];var l=!0!==o.disabled;i=e(kendo.html.renderButton(`<button ref-actionsheet-action-button>${o.text||""}</button>`,e.extend({size:"large"},o))),n.append(i),i.toggleClass(a,!l),i.attr("disabled",!l),l?i.removeAttr(s):i.attr(s,!l),o.click&&i.data("action",o.click)}},_wrapInView:function(){const t=this;t.wrapper&&t.wrapper.hasClass(c)||(t.wrapper=t._content.add(t._footer).add(t._header).wrapAll(e(`<div ref-${t.options.ref} class='${c}${t.options.addAnimationClass?" k-actionsheet-view-animated":""}'></div>`)).parent())},destroy:function(){const e=this;n.fn.destroy.call(e),e._content&&(e._content.remove(),e._content=null),e._footer&&(e._footer.remove(),e._footer=null),e._header&&(e._header.remove(),e._header=null),e.wrapper&&(e.wrapper.remove(),e.wrapper=null)}});kendo.ui.plugin(_)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo;var n=t.ui.Widget;var i=t.ui;var r=".kendoActionSheet";var o=i.Popup;var a=t.keys;var s=t.isFunction;var l=o.TabKeyTrap;var c=e(document.documentElement);var d="open";var h="close";var u="activate";var p="deactivate";var f=":kendoFocusable:not([tabindex='-1'])";var m="k-actionsheet-container";var g="k-actionsheet-bottom";var v="k-actionsheet-fullscreen";var _=`.k-actionsheet-item:not(.${b}),.k-actions .k-button[ref-actionsheet-action-button]:not(.${b})`;var b="k-disabled";var w="k-hidden";var y=e.extend;var k=n.extend({init:function(e,i){var o=this;i=i||{},n.fn.init.call(o,e,i),i.appendTo&&o.element.appendTo(i.appendTo),o._wrapper(),o._hasViews()?o._initMultiViews():o._initView(),o._toggleViewAnimationVariable(),o._popup(),o._applyAria(),o._tabKeyTrap=new l(o.wrapper),o.downEvent=t.applyEventMap("down",t.guid()),o.clickEvent=t.applyEventMap("click",t.guid()),o._mousedownProxy=o._mousedown.bind(o),o._clickProxy=o._click.bind(o),o.wrapper.on("keydown"+r,o,o._keydown.bind(o))},events:[d,h,u,p],options:{name:"ActionSheet",title:null,subtitle:null,items:[],popup:null,fullscreen:!1,footerTemplate:null,headerTemplate:null,contentTemplate:null,actionButtons:[],actionButtonsAlignment:"stretched",actionButtonsOrientation:"horizontal",animation:{open:{effects:"slideIn:up",transition:!0,duration:200}},closeButton:!1,startButton:!1,adaptive:!1,focusOnActivate:!0,closeOnClick:!0,views:[],activeView:1},_addView:function(e){const t=this;const n=t.options;const i=t.views&&t.views.length+1>1;const r=e||{headerTemplate:n.headerTemplate,contentTemplate:n.contentTemplate,footerTemplate:n.footerTemplate,actionButtons:n.actionButtons,actionButtonsAlignment:n.actionButtonsAlignment,actionButtonsOrientation:n.actionButtonsOrientation,title:n.title,items:n.items,subtitle:n.subtitle,startButton:n.startButton,closeButton:n.closeButton,ref:n.ref};r.addAnimationClass=i,r.index=t.views.length+1;const o=t._initView(r);return t._toggleViewAnimationVariable(),t._addViewsAnimation(),o},_setCurrentActiveView:function(e){const t=this;t.views&&t.views.length>1&&t.element.css("--kendo-actionsheet-view-current",e)},_removeView:function(e){const t=this;const n=t.views.indexOf(e);t.views.length&&(t.views.splice(n,1),e._content&&Array.prototype.splice.call(t._content,n,1),e._footer&&Array.prototype.splice.call(t._footer,n,1),e._header&&Array.prototype.splice.call(t._header,n,1),e.destroy(),t.views.forEach(((e,n)=>{1===t.views.length&&(e.wrapper.removeClass("k-actionsheet-view-animated"),e.wrapper.css({transitionProperty:"",transitionDuration:""})),e.index=n+1}))),t._toggleViewAnimationVariable()},_toggleViewAnimationVariable:function(){const e=this;const t=e.element;e.views&&e.views.length>1?t.css("--kendo-actionsheet-view-current",e.options.activeView):t.css("--kendo-actionsheet-view-current","")},_addViewsAnimation:function(){const e=this;if(e.views&&e.views.length>1){const t={duration:500};e.wrapper.find(".k-actionsheet-view").addClass("k-actionsheet-view-animated").css({transitionProperty:"transform",transitionDuration:`${t.duration}ms`})}},_hasViews:function(){return this.options.views&&this.options.views.length},setOptions:function(e){const t=this;n.fn.setOptions.call(t,e),t.views.forEach((e=>e.destroy())),t.popup.wrapper.length&&t.element.unwrap().unwrap(),t.popup.destroy(),t.popup=null,t._popup(),e.views&&e.views.length?t._initMultiViews():t._initView(),t._toggleViewAnimationVariable(),t._applyAria()},_wrapper:function(){var t=this;var n=t.element;var i;var r=1==t.options.fullscreen?v:g;n.addClass("k-actionsheet "+r+(t.options.adaptive?" k-adaptive-actionsheet":" k-actionsheet-jq")),t.wrapper=i=n.wrap("<div class='"+m+" "+w+"'></div>").parent(),i.prepend(e("<div></div>").addClass("k-overlay"))},_wrapInView:function(){this.element.wrapInner("<div class='k-actionsheet-view'></div>")},_applyAria:function(){var e=this;var t=e.element;var 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(){const e=this;const n=e.options;n.open=null,n.close=null,n.activate=null,n.deactivate=null,e.popup=new o(e.element,y(n.popup,n,{name:"Popup",isRtl:t.support.isRtl(n.anchor),omitOriginOffsets:!0,appendTo:e.wrapper,modal:!0,animation:!!n.adaptive&&n.animation,position:"top center",anchor:n.anchor||e.wrapper})),n.focusOnActivate&&e.popup.bind(u,e._openHandler.bind(e)),e.popup.bind(u,(t=>{e.trigger(u,t)})),e.popup.bind(p,(t=>{e.wrapper.addClass(w),c.off(e.downEvent,e._mousedownProxy),c.off(e.clickEvent,e._clickProxy),e.trigger(p,t)})),e.popup.bind(d,(t=>{e.trigger(d,t)})),e.popup.bind(h,(t=>{var n=e._closeButtonPressed;e._closeButtonPressed=!1,e.trigger(h,y({},t,{closeButton:n}))}))},_initView:function(e){const n=this;const i=n.options;const r=e||{headerTemplate:i.headerTemplate,contentTemplate:i.contentTemplate,footerTemplate:i.footerTemplate,actionButtons:i.actionButtons,actionButtonsAlignment:i.actionButtonsAlignment,actionButtonsOrientation:i.actionButtonsOrientation,title:i.title,items:i.items,subtitle:i.subtitle,startButton:i.startButton,closeButton:i.closeButton,addAnimationClass:i.views.length>1,ref:i.ref};const o=new t.ui.ActionSheetView(n.element,r);return e&&n.views?(n.views.push(o),o._content&&(Array.isArray(n._content)?n._content.push(o._content):n._content=[n._content,o._content]),o._footer&&(Array.isArray(n._footer)?n._footer.push(o._footer):n._footer=[n._footer,o._footer]),o._header&&(Array.isArray(n._header)?n._header.push(o._header):n._header=[n._header,o._header]),o):(n.views=[o],n._content=o._content,n._footer=o._footer,n._header=o._header,o)},_initMultiViews:function(){const e=this;e.options.views.forEach((t=>{e._initView(t)})),e._addViewsAnimation(),e._toggleViewAnimationVariable()},destroy:function(){var e=this;for(e.close(),n.fn.destroy.call(e);e.views.length;)e._removeView(e.views[0]);e._content=null,e._footer=null,e._header=null,e.element.off(r),e.wrapper.off(r),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%"}),c.off(t.downEvent,t._mousedownProxy).on(t.downEvent,t._mousedownProxy),c.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(f).first();e.length&&e.trigger("focus")},_focusLastFocusableElement:function(){var e=this.element.find(f).last();e.length&&e.trigger("focus")},_hasItems:function(){return this.views.find((e=>e._hasItems))},_openHandler:function(){const e=this._hasItems();if(e){var t=e._content.find(".k-actionsheet-item")[0];t&&t.focus()}else this._focusFirstFocusableElement()},_isActionableButton:function(t){return e(t).closest(_).length>0},_triggerAction:function(t){var n=e(t.target).closest(_).data("action");s(n)&&n(t),t.isDefaultPrevented()||this.close()},_keydown:function(n){var i=this;var r=t.keys;var o=n.keyCode;var a=e(n.target);if(o==r.ESC)n.stopPropagation(),i.close();else if(i._isActionableButton(a)&&x(n))i._triggerAction(n);else if(n.keyCode===t.keys.TAB){var s=this.wrapper.find(f);var l=s.first();var 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(n){var i=this;var r=t.eventTarget(n);i._isActionableButton(r)&&i._triggerAction(n),i.options.startButton&&e(r).closest("[data-ref-actionsheet-start-button]").length>0&&i.options.startButton.click.call(this,n)},_mousedown:function(n){const i=this;const r=i.element[0];const o=i.wrapper;var a=t.eventTarget(n);if(i.altTarget&&i.altTarget.is(e(a)))return;const s=e(a).closest(`.${m}`);!(s.length>0&&!s.is(o))&&(!function(t,n){return!(!t||!n)&&(t===n||e.contains(t,n))}(r,a)&&i.options.closeOnClick||e(a).closest(`[${t.attr("ref-actionsheet-close-button")}]`,e(r).find("k-actionsheet-titlebar")).length>0)&&(i._closeButtonPressed=!0,i.close())}});function x(e){return e.keyCode==a.ENTER||e.keyCode==a.SPACEBAR}i.plugin(k)}(window.kendo.jQuery);kendo;let cg=kendo.jQuery;const dg="k-loading",hg="k-input-inner",ug="aria-busy";function pg(){const e=this;const t=cg("<span></span>").addClass("k-icon k-i-loading k-input-loading-icon").attr("role","presentation");e._loading=t,e._showBusy=gg.bind(e),e._hideBusy=vg.bind(e),e._toggleLoader=fg.bind(e),e._showBusyHandler=mg.bind(e)}function fg(e){const t=this;const n=t.wrapper.hasClass(dg);const i=t.wrapper.find(".k-input-values");const r="multiselect"===t.options.name.toLowerCase();if(t._loading)if(e&&!n)if(t.wrapper.addClass(dg),t._suffixContainer){const e=t.wrapper.find(".k-input-separator");cg(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(hg)?t.element:t.wrapper.find(`.${hg}`);t._loading.insertAfter(e)}else n&&(t.wrapper.removeClass(dg),t._loading.remove())}function mg(){const e=this;if(e._focused)e._focused.attr(ug,!0);else{(e.element.hasClass(hg)?e.element:e.wrapper.find(`.${hg}`)).attr(ug,!0)}e._toggleLoader(!0),e._hideClear()}function gg(e){const t=this;e&&e.isDefaultPrevented()||(t._request=!0,t._busy||(t._busy=setTimeout(t._showBusyHandler,100)))}function vg(){const e=this;if(clearTimeout(e._busy),e._toggleLoader(!1),e._busy=null,e._request&&(e._request=!1),e._focused)e._focused.attr(ug,!1);else{(e.element.hasClass(hg)?e.element:e.wrapper.find(`.${hg}`)).attr(ug,!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,h=n._outerWidth,u=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",w=".k-list-item",y="open",k="close",x="cascade",C="select",S="click",T="mouseenter",M="activate",A="deactivate",D="dataBinding",E="dataBound",I="selectedItemChange",z="selected",P="requestStart",L="requestEnd",B="focus",H=e.extend,R=Array.isArray,F=l.browser,O="k-hidden",V="width",N="text",$=F.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";var 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",filterInputPlaceholder:"Filter"},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=pg.bind(e),e._initLoader()},focus:function(){this._focused.trigger(B)},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;var i=t.options;var 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;var i=e(t.header);var 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")||this.options.messages.filterInputPlaceholder,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=this;var i;var r=e(t.columnsHeader);n.destroy(r),r.remove();var a="<div class='k-table-header'><div class='k-table-header-wrap'><table class='k-table' role='presentation'>";var s="<colgroup>";var l="<tr class='k-table-row'>";for(var c=0;c<this.options.columns.length;c++){var d=this.options.columns[c];var h=d.title||d.field||"";var u=d.headerTemplate||(()=>h);var p="function"!=typeof u?n.template(u):u;var f=d.width;var m=parseInt(f,10);var 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>",i=e(a+="</thead></table></div></div>"),n.applyStylesFromKendoAttributes(i,["width"]),t.columnsHeader=r=i,t.list.prepend(r)},_noData:function(){var t=this;var i=e(t.noData);var 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;var i=e(t.footer);var r=t.options.footerTemplate;var 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;var r=i.options;var o=r.virtual;var a={change:i._listChange.bind(i)};var s=i._listBound.bind(i);var l=i._focused;var d=i.element.attr("id");var h=e('label[for="'+i.element.attr("id")+'"]');var u=l.attr(j);return!u&&h.length&&(u=h.attr("id")||i._generateLabelId(h,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(D)},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:u,listSize:i._listSize},t,o,a)).template||(t.template=e=>c(n.getter(t.dataTextField)(e))),t},_initList:function(e){var t=this;var i=e&&e.skipValueUpdate;var 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;var r=i.options;var o=r.filterFields&&t&&t.logic&&t.filters&&t.filters.length;var a=i.dataSource;var s=H({},a.filter()||{});var l=t||s.filters&&s.filters.length&&!t;var 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 h=H({},{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(h))},_pushFilterExpression:function(e,t){re(t)&&""!==t.value&&e.filters.push(t)},_clearFilterExpressions:function(e){if(e.filters){var t;for(var 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;var 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=this;var n=t.options;var i=e.word;var r=n.filterFields;var o=n.dataTextField;var a;if(r&&r.length){a={logic:"or",filters:[],fromFilter:!0};for(var s=0;s<r.length;s++)this._pushFilterExpression(a,t._buildExpression(i,r[s]))}else a=t._buildExpression(i,o);t._open=e.open,t._filterSource(a)},_buildExpression:function(e,t){var n=this.options;var i=n.ignoreCase;var 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;var 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;var 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;var t=e.element;var i=e.options;var r=n.getter;var o=t.attr(n.attr("text-field"));var 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=this;var n=e.selectedIndex;var i=e.options.value;var r=e.value();var o;e._isSelect&&!e.listView.bound()&&i&&(r=i),e._isValueChanged(r)||e._valueBeforeCascade!==t&&e._isValueChanged(e._valueBeforeCascade)&&e._userTriggered?o=!0:n===t||n===e._oldIndex||e.listView.isFiltered()||e.options.virtual||(o=!0),o&&(null===e._old||""===e._old||""===r?e._valueBeforeCascade=e._old=r:e.dataItem()?e._valueBeforeCascade=e._old=e.options.dataValueField?e.dataItem()[e.options.dataValueField]:e.dataItem():e._valueBeforeCascade=e._old=null,e._oldIndex=n,e._typing||e.element.trigger(f),e.trigger(f)),e.typing=!1},_data:function(){return this.dataSource.view()},_enable:function(){var e=this,i=e.options,r=e.element.is("[disabled]");i.enable!==t&&(i.enabled=i.enable),!i.enabled||r?e.enable(!1):e.readonly(n.isPresent(i.readonly)?i.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=this;var i=n.list;var o=n.options.height;var a=n.popup.visible();var s=this.options.columns&&this.options.columns.length;var l;if(t||n.options.noDataTemplate){if(l=i.parent().add(i.closest(".k-animation-container").add(i.closest(".k-child-animation-container"))).show(),!i.parent().is(":visible"))return void l.hide();o=n.listView.content[0].scrollHeight>o?o:"auto",l.height(o),"auto"!==o&&(o-=n._offsetHeight(),s&&(o=o-(r(e(n.footer))||0)-(r(e(n.columnsHeader))||0))),s?n.listView.content.outerHeight(o):n.listView.content.parent().outerHeight(o),a||i.parent().hide()}return o},_openHandler:function(e){var t;this._adjustListWidth(),this.trigger(y)?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)||h(o),e&&F.msie&&(t+=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight)+parseFloat(e.borderLeftWidth)+parseFloat(e.borderRightWidth)),r="border-box"!==i.css("box-sizing")?t-(h(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;var n=!e.focus();var 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();var i=this.listView.content.prev(b);var r=0;var 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);var i=n.support.scrollbar();this.columnsHeader.css(t?"padding-left":"padding-right","auto"!==e?i:0)}},_refreshScroll:function(){var e=this.listView;var 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(M,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._unboundClick&&(e.input?e.input.off(S):e.element&&e.element.off(S),e._unboundClick=!1),e.popup&&(e._cachedFilterValue=e.filterInput?e.filterInput.val():null,e.popup.destroy(),e.popup.wrapper&&e.popup.wrapper.remove(),e._removeFilterHeader(),e._removeStaticHeader()),e.popup=new i.Popup(e.list.parent().addClass("k-list-container"),H({},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.popup.wrapper&&e.popup.wrapper.remove(),e._removeFilterHeader(),e._removeStaticHeader(),e.list.add(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.adaptiveTitle||e.options.label?`<div class="k-text-center">${e.options.adaptiveTitle||e.options.label}</div>`:"")+(e.options.adaptiveSubtitle?`<div class="k-actionsheet-subtitle k-text-center">${e.options.adaptiveSubtitle||""}</div>`:"")+"</div>"+(t.closeButton?'<div class="k-actionsheet-actions">'+n.html.renderButton(`<button tabindex="-1" ${n.attr("ref-actionsheet-close-button")}></button>`,{icon:"check",fillMode:"flat",size:"large",themeColor:"primary"})+"</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:H({},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=this;var t;e._addFilterHeader(),e.filterInput&&e._cachedFilterValue&&e.filterInput.val(e._cachedFilterValue),e.popup.element.prepend(e.header).on("mousedown"+this.ns,this._listMousedown.bind(this)),e.listView&&(t=e.listView.value(),e.listView._clean&&e.listView._clean(),e.tagList&&e.options.virtual&&e.tagList.empty(),e.listView.destroy(),e.listView.content&&this.ul.unwrap(),e._initList({skipValueUpdate:!0}),e.listView.value(t))},_toggleHover:function(t){e(t.currentTarget).toggleClass(g,t.type===T)},_toggle:function(e,n){var i=this;var 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(B),i._prevent=!1),i[e?y: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(L,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}H(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=this;var n;t.options.dataSource=e,t._dataSource(),t.listView.bound()&&(t._initialIndex=null,t.listView._current=null),t.listView.setDataSource(t.dataSource),t.options.autoBind&&t.dataSource.fetch(),(n=t._parentWidget())&&t._cascadeSelect(n)},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;var i=n.element;var 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(L,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=this;var n=t.listView;var i=e.keyCode;var r=i===s.DOWN;var o=t.options.virtual;var a;var l;var c;var h;var u;if(i===s.UP||r){if(e.altKey)t.toggle(r);else{if(!n.bound()&&!t.ul[0].firstChild)return t._fetch||(t.dataSource.one(f,(function(){t._fetch=!1,t._move(e)})),t._fetch=!0,t._filterSource()),e.preventDefault(),!0;c=t._focus(),t._fetch||c&&!c.hasClass(v)||(r?(h=t._nextItem(),(o&&h<=0||!t._focus()&&!h)&&t._lastItem()):(h=t._prevItem(),(o&&h>=n.dataSource.total()-1||!t._focus()&&!h)&&t._firstItem())),u=t._getNormalizedSelectCandidate(t._get(t._focus())||h||0),t._select(u,!0).done((function(){var e=function(){t.popup.visible()||t._blur(),null===t._cascadedValue?t._cascadedValue=t.value():t._cascadedValue=t.dataItem()?t.dataItem()[t.options.dataValueField]||t.dataItem():null};t.trigger(C,{dataItem:t._getNormalizedDataItem(u),item:t._focus()})?t._select(c).done(e):e()}))}e.preventDefault(),l=!0}else if(i===s.ENTER||i===s.TAB){t.popup.visible()&&e.preventDefault(),c=t._focus(),a=t.dataItem(),t.popup.visible()||a&&t.text()===t._text(a)||(c=null);var p=t.filterInput&&t.filterInput[0]===d();var m;if(c){var g=!0;if((a=n.dataItemByIndex(n.getElementIndex(c)))&&(g=t._value(a)!==Z.unifyType(t.value(),typeof t._value(a))),g&&t.trigger(C,{dataItem:a,item:c}))return;m=t._select(c)}else t.input&&((t._syncValueAndText()||t._isSelect)&&t._accessor(t.input.val()),t.listView.value(t.input.val()));t._focusElement&&t._focusElement(t.wrapper),p&&i===s.TAB?t.wrapper.focusout():m&&"function"==typeof m.done?m.done((function(){t._blur()})):t._blur(),t.close(),l=!0}else if(i===s.ESC)t.popup.visible()&&(e.preventDefault(),e.stopPropagation()),t.close(),l=!0;else if(t.popup.visible()&&(i===s.PAGEDOWN||i===s.PAGEUP)){e.preventDefault();var _=i===s.PAGEDOWN?1:-1;n.scrollWith(_*n.screenHeight()),l=!0}return l},_fetchData:function(){var e=this;var 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,h=d[0],u=e.length,p="",f=0;for(n&&(p=n);f<u;f++)r="<option",o=e[f],a=l._text(o),(s=l._value(o))!==t&&(-1!==(s+="").indexOf('"')&&(s=s.replace(U,""")),r+=' value="'+s+'"'),r+=">",a!==t&&(r+=c(a)),p+=r+="</option>";d.html(p),i!==t&&(h.value=i,h.value&&!i&&(h.selectedIndex=-1)),-1!==h.selectedIndex&&(r=ie(h))&&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);var 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=this;var t=e.options;var n;if(t.cascadeFrom){if(!(n=e._parentWidget()))return;e._cascadeHandlerProxy=e._cascadeHandler.bind(e),e._cascadeFilterRequests=[],t.autoBind=!1,n.bind("set",(function(){e.one("set",(function(t){e._selectedValue=t.value||e._accessor()}))})),n.first(x,e._cascadeHandlerProxy),n.listView.bound()?(e._toggleCascadeOnFocus(),e._cascadeSelect(n)):(n.one(E,(function(){e._toggleCascadeOnFocus(),n.popup.visible()&&n._focused.trigger(B)})),n.value()||e.enable(!1))}},_toggleCascadeOnFocus:function(){var e=this;var t=e._parentWidget();var n=$&&t instanceof i.DropDownList?"blur":"focusout";t._focused.add(t.filterInput).on(B,(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();var 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;var 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;var r=e.dataItem();var o=r?r[i.options.cascadeFromParentField]||e._value(r):null;var 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";var 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");var 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,M,A,D,E,I],setDataSource:function(e){var t=this;var i=e||{};var r;i=Array.isArray(i)?{data:i}:i,i=n.data.DataSource.create(i),t.dataSource?(t.dataSource.unbind(f,t._refreshHandler),r=t.value(),t.value([]),t.bound(!1),t.value(r)):t._refreshHandler=t.refresh.bind(t),t.setDSFilter(i.filter()),t.dataSource=i.bind(f,t._refreshHandler),t._fixedHeader()},_touchHandlers:function(){var t,n,i=this,r=this.options.columns&&this.options.columns.length?".k-table-row":w,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=this;var r=i._optionID;var o;if(n===t)return i._current;n=ne(i._get(n)),n=e(this.element[0].children[n]),i._current&&(i._current.removeClass(m).removeAttr(p),i.trigger(A)),(o=!!n[0])&&(n.addClass(m),i.scroll(n),n.attr("id",r)),i._current=o?n:null,i.trigger(M)},focusIndex:function(){return this.focus()?this.focus().index():t},skipUpdate:function(e){this._skipUpdate=e},select:function(n){var i=this;var r=i.options.selectable;var o="multiple"!==r&&!1!==r;var a=i._selectedIndices;var s=[this.element.find(".k-selected").index()];var l=[];var c;var d;if(n===t)return a.slice();1===(n=i._get(n)).length&&-1===n[0]&&(n=[]);var h=e.Deferred().resolve();var u=i.isFiltered();return u&&!o&&i._deselectFiltered(n)?h:o&&!u&&-1!==e.inArray(ne(n),a)&&-1!==e.inArray(ne(n),s)?(i._dataItems.length&&i._view.length&&(i._dataItems=[i._view[a[0]].item]),h):(c=(d=i._deselect(n)).removed,(n=d.indices).length&&(o&&(n=[ne(n)]),l=i._select(n)),(l.length||c.length)&&(i._valueComparer=null,i.trigger(f,{added:l,removed:c})),h)},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 u?e.slice(0):[e],this._values=e,this._valueComparer=null},value:function(n){var i=this;var r=i._valueDeferred;var o;return n===t?i._values.slice():(i.setValue(n),r&&"resolved"!==r.state()||(i._valueDeferred=r=e.Deferred()),i.bound()&&(o=i._valueIndices(i._values),"multiple"===i.options.selectable&&i.select(-1),i.select(o),r.resolve()),i._skipUpdate=!1,r)},items:function(){return this.element.children(w)},_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=this;var i=0;var r;var o=[];if(!n._valueComparer||n._valueType!==e){for(n._valueType=e;i<t.length;i++)o.push(J(t[i],e));r=(e,t)=>{for(var n=0;n<o.length;n++)if(e===t[n])return n;return-1},n._valueComparer=function(e){return r(e,o)}}return n._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=this;var i=n.element[0].children;var r=n.options.selectable;var o=n._selectedIndices;var a=n._dataItems;var s=n._values;var l=[];var c=0;var d=0;var h,u;if(t=t.slice(),!0!==r&&t.length){if("multiple"===r)for(;c<t.length;)if(h=t[c],e(i[h]).hasClass(v)){for(;d<o.length;){if((u=o[d])===h){e(i[u]).removeClass(v).attr(Q,!1);var p=this._view[h].item;var f=this._dataItemPosition(p,this._values);l.push({position:f,dataItem:p}),a.splice(d,1),o.splice(d,1),t.splice(c,1),s.splice(d,1),c-=1,d-=1;break}d++}c++}else c++}else{for(;c<o.length;c++)e(i[o[c]]).removeClass(v).attr(Q,!1),l.push({position:c,dataItem:a[c]});n._values=[],n._dataItems=[],n._selectedIndices=[]}return{indices:t,removed:l}},_deselectFiltered:function(t){var n=this.element[0].children;var i,r,o;var a=[];var s=0;for(;s<t.length;s++)r=t[s],i=this._view[r].item,(o=this._dataItemPosition(i,this._values))>-1&&(a.push(this.removeAt(o)),e(n[r]).removeClass(v));return!!a.length&&(this.trigger(f,{added:[],removed:a}),!0)},_select:function(t){var n=this;var i=n.element[0].children;var r=n._view;var o,a;var s=[];var l=0;for(-1!==ne(t)&&n.focus(t);l<t.length;l++)o=r[a=t[l]],-1!==a&&o&&(o=o.item,n._selectedIndices.push(a),n._dataItems.push(o),n._values.push(n._valueGetter(o)),e(i[a]).addClass(v).attr(Q,!0),s.push({dataItem:o}));return s},getElementIndex:function(t){return e(t).data("offset-index")},_get:function(e){return"number"==typeof e?e=[e]:R(e)||(e=[(e=this.getElementIndex(e))!==t?e:-1]),e},_templates:function(){var e;var t=this.options;var 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){var n=[];var i=0;for(;i<e.length;i++)e[i]!==t&&n.push(e[i]);return n},_valueIndices:function(e,t){var n=this._view;var i=0;var r;if(t=t?t.slice():[],!e.length)return[];for(;i<n.length;i++)-1!==(r=this._dataItemPosition(n[i].item,e))&&(t[r]=i);return this._normalizeIndices(t)},_firstVisibleItem:function(){var t=this.element[0];var n=this.content[0].scrollTop;var i=e(t.children[0]).height();var r=Math.floor(n/i)||0;if(0==t.childElementCount)return null;var o=t.children[r]||t.lastChild;var a=o.offsetTop<n;for(;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" `;var n=e.item;var i=0!==e.index;var r=e.selected;var o=this.isGrouped();var a=this.options.columns&&this.options.columns.length;var 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){var t="";for(var i=0;i<this.options.columns.length;i++){var r=this.options.columns[i].width;var a=parseInt(r,10);var 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="";var i;var r=0;var o=0;var a;var s=[];var l=this.dataSource.view();var c=this.value();var d,h,u;var p=this.isGrouped();if(p)for(r=0;r<l.length;r++)for(d=l[r],h=!0,u=0;u<d.items.length;u++)a={selected:this._selected(d.items[u],c),item:d.items[u],group:d.value,newGroup:h,isLastGroupedItem:u===d.items.length-1,index:o},s[o]=a,o+=1,t+=this._renderItem(a),h=!1;else for(r=0;r<l.length;r++)a={selected:this._selected(l[r],c),item:l[r],index:r},s[r]=a,t+=this._renderItem(a);this._view=s,i=e(t),n.applyStylesFromKendoAttributes(i,["width","background-color"]),this.element.empty().append(i),p&&s.length&&this._renderHeader()},_selected:function(e,t){return(!this.isFiltered()||"multiple"===this.options.selectable)&&-1!==this._dataItemPosition(e,t)},setDSFilter:function(e){this._lastDSFilter=H({},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=this;var n=e&&e.action;var i=t.options.skipUpdateOnBind;var r="itemchange"===n;var o;t.trigger(D),t._fixedHeader(),t._render(),t.bound(!0),r||"remove"===n?(o=function(e,t){var n=t.length;var i=e.length;var r;var o;var a,s;var l=[];var c=[];if(i)for(a=0;a<i;a++){for(r=e[a],o=!1,s=0;s<n;s++)if(r===t[s]){o=!0,l.push({index:a,item:r});break}o||c.push(r)}return{changed:l,unchanged:c}}(t._dataItems,e.items)).changed.length&&(r?t.trigger(I,{items:o.changed}):t.value(t._getValues(o.unchanged))):t.isFiltered()||t._skipUpdate||t._emptySearch?(t.focus(0),(t._skipUpdate||t._emptySearch&&t._selectedIndices.length)&&(t._skipUpdate=!1,t._selectedIndices=t._valueIndices(t._values,t._selectedIndices))):i||n&&"add"!==n||t.value(t._values),t._valueDeferred&&t._valueDeferred.resolve(),t.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;var 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 _g(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",h="k-selected",u="k-focus",p="k-hover",f="change",m="click",g="listBound",v="itemChange",_="activate",b="deactivate",w=".k-table-group-row",y=".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){var r="";for(var o=0;o<e.columns.length;o++){var a=e.columns[o].width;var l=parseInt(a,10);var 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(u,r.current),i.toggleClass(h,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 M(e){return e&&"resolved"!==e.state()}var A=a.extend({init:function(t,i){var r=this,a=i.columns&&i.columns.length?"k-table-body k-table-scroller":"k-list-content k-virtual-content";var s,l,c;r.bound(!1),r._fetching=!1,o.fn.init.call(r,t,i),r.options.itemHeight||(r.options.itemHeight=(s=i.listSize,(l=e('<div class="k-list '+s+' 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"}),l.appendTo(document.body),c=parseFloat(n.getComputedStyles(l.find(".k-list-item")[0],["height"]).height),l.remove(),c)),i=r.options,r.element.attr("role","listbox");var d="."+a.split(" ").join(".");var h=r.element.closest(d);if(r.content=r.wrapper=h.length?h:r.element.wrap("<div unselectable='on' class='"+a+"'></div>").parent(),r.options.columns&&r.options.columns.length){var u=r.element.closest(".k-data-table").find(".k-table-thead");var f=e('<tr class="k-table-group-row"><th class="k-table-th" colspan="'+r.options.columns.length+'"></th></tr>');u.append(f),r.header=f.find(".k-table-th"),r.element.addClass("k-table-list k-virtual-table")}else r.header=r.content.before("<div class='k-list-group-sticky-header'></div>").prev(),r.element.addClass("k-list-ul");i.ariaLabel?this.element.attr("aria-label",i.ariaLabel):i.ariaLabelledBy&&this.element.attr("aria-labelledby",i.ariaLabelledBy),r.element.on("mouseenter"+y,"li:not(.k-loading-item)",(function(){e(this).addClass(p)})).on("mouseleave"+y,"li",(function(){e(this).removeClass(p)})),r._values=x(r.options.value),r._selectedDataItems=[],r._selectedIndexes=[],r._rangesList={},r._promisesList=[],r._optionID=n.guid(),r._templates(),r.setDataSource(i.dataSource),r.content.on("scroll"+y,n.throttle((function(){r._renderItems(),r._triggerListBound()}),i.delay)),r._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(y),this.dataSource.unbind(f,this._refreshHandler),o.fn.destroy.call(this)},setDataSource:function(e){var t=this;var i=e||{};var r;i=Array.isArray(i)?{data:i}:i,i=n.data.DataSource.create(i),t.dataSource?(t.dataSource.unbind(f,t._refreshHandler),t._clean(),t.bound(!1),t._deferValueSet=!0,r=t.value(),t.value([]),t.mute((function(){t.value(r)}))):t._refreshHandler=t.refresh.bind(t),t.dataSource=i.bind(f,t._refreshHandler),t.setDSFilter(i.filter()),0!==i.view().length?t.refresh():t.options.autoBind&&i.fetch()},skip:function(){return this.dataSource.currentRangeStart()},_triggerListBound:function(){var e=this;var 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(h)}},refresh:function(e){var t=this;var n=e&&e.action;var i="itemchange"===n;var r=this.isFiltered();var o;t._mute||(t._deferValueSet=!1,t._fetching?(t._renderItems&&t._renderItems(!0),t._triggerListBound()):(r&&t.focus(0),t._createList(),n||!t._values.length||r||t.options.skipUpdateOnBind||t._emptySearch?(t.bound(!0),t._highlightSelectedItems(),t._triggerListBound()):(t._selectingValue=!0,t.bound(!0),t.value(t._values,!0).done((function(){t._selectingValue=!1,t._triggerListBound()})))),(i||"remove"===n)&&(o=function(e,t){var n=t.length;var i=e.length;var r;var o;var a,s;var l=[];var c=[];if(i)for(a=0;a<i;a++){for(r=e[a],o=!1,s=0;s<n;s++)if(r===t[s]){o=!0,l.push({index:a,item:r});break}o||c.push(r)}return{changed:l,unchanged:c}}(t._selectedDataItems,e.items)).changed.length&&(i?t.trigger("selectedItemChange",{items:o.changed}):t.value(t._getValues(o.unchanged))),t._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){var t,n=this,i=n._dataView,r=n._valueGetter,o=n.options.mapValueTo,a=[];for(var 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(_g(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(h)}this._triggerChange(i,r),this._valueDeferred&&this._valueDeferred.resolve()}else this.select([-1])},deferredRange:function(t){var n=this.dataSource;var i=this.itemCount;var r=this._rangesList;var o=e.Deferred();var a=[];var s=Math.floor(t/i)*i;var l=Math.ceil(t/i)*i;var c=l===s?[l]:[s,l];return e.each(c,(function(t,o){var s=o+i;var l=r[o];var c;l&&l.end===s?c=l.deferred:(c=e.Deferred(),r[o]={end:s,deferred:c},n._multiplePrefetch(o,i,(function(){c.resolve()}))),a.push(c)})),e.when.apply(e,a).done((function(){o.resolve()})),o},prefetch:function(t){var n=this,i=this.itemCount,r=!n._promisesList.length;return M(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;var r=i.itemCount;var o=i._getSkip(t,r);var 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("."+u)).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("."+u).removeClass(u),void(this._focusedIndex=t);if(i.length){i.hasClass(u)&&(c=!1),this._focusedIndex!==t&&((a=this._getElementByIndex(this._focusedIndex)).removeClass(u).removeAttr("id"),c&&this.trigger(b)),this._focusedIndex=r,i.addClass(u).attr("id",l);var h=this._getElementLocation(r);"top"===h?this.scrollTo(r*s):"bottom"===h?this.scrollTo(r*s+s-this._screenHeight):"outScreen"===h&&this.scrollTo(r*s),c&&this.trigger(_)}else this._focusedIndex=r,this.items().removeClass(u),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=this._focusedIndex;var t;return!isNaN(e)&&e>0?(e-=1,this.focus(e),(t=this.focus())&&t.hasClass("k-loading-item")&&(e+=1,this.focus(e)),e):(e=this.dataSource.total()-1,this.focus(e),e)},focusNext:function(){var e=this._focusedIndex;var t=this.dataSource.total()-1;var n;return!isNaN(e)&&e<t?(e+=1,this.focus(e),(n=this.focus())&&n.hasClass("k-loading-item")&&(e-=1,this.focus(e)),e):(e=0,this.focus(e),e)},_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=M(l._activeDeferred),h=this.isFiltered(),u=[];if(n===t)return l._selectedIndexes.slice();if(l._selectDeferred&&"resolved"!==l._selectDeferred.state()||(l._selectDeferred=e.Deferred()),i=l._getIndecies(n),o=c&&!h&&k(i)===k(this._selectedIndexes),(u=l._deselectCurrentValues(i)).length||!i.length||o)return l._triggerChange(u),l._valueDeferred&&l._valueDeferred.resolve().promise(),l._selectDeferred.resolve().promise();1===i.length&&-1===i[0]&&(i=[]),r=i,s=l._deselect(i),u=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(u,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){var n,i=this._dataView,r=this._valueGetter;for(var 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;var 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){var n,i,r=[],o=this.options.itemHeight+"px",a=this.options.columns&&this.options.columns.length?c:l;for(;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;var 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=this,t=e.content.get(0),n=e.options,i=e.dataSource;var r,o,a;var s;e.bound()&&e._clean(),e._saveInitialRanges(),e._buildValueGetter(),e.setScreenHeight(),e.itemCount=(r=e._screenHeight,o=n.listScreens,a=n.itemHeight,Math.ceil(r*o/a)),e.itemCount>i.total()&&(e.itemCount=i.total()),e._items=e._generateItems(e.element[0],e.itemCount),e._setHeight(n.itemHeight*i.total()),e.options.type=(i.group()||[]).length?"group":"flat","flat"===e.options.type?e.header.closest(w).length?e.header.closest(w).hide():e.header.hide():e.header.closest(w).length?e.header.closest(w).show():e.header.show(),e.getter=e._getter((function(){e._renderItems(!0)})),e._onScroll=function(t,n){var i=e._listItems(e.getter);return e._fixedHeader(t,i(t,n))},e._renderItems=e._whenChanged(function(e,t){return function(n){return t(e.scrollTop,n)}}(t,e._onScroll),(s=e._reorderList(e._items,T.bind(e)),function(e,t){return s(e.items,e.index,t),e})),e._renderItems(),e._calculateGroupPadding(e._screenHeight),e._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]){var d=o[s]=[];var h=t.view();for(var u=0,p=h.length;u<p;u++){var f=h[u];for(var 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 h=0;h<this._selectedDataItems.length;h++)if(d(this._selectedDataItems[h])===d(e)){a=!0;break}}else if(!this.isFiltered()&&n.length&&e)for(var u=0;u<n.length;u++)if(C(e)?n[u]===e:n[u]===d(e)){n.splice(u,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;var t=function(e,t){var n=(e.listScreens-1-e.threshold)*t;var 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=this;var o=t.length;var a=-1/0;var s,l;return i=(s=i,l=this.templates,function(t,i){for(var r=0,o=t.length;r<o;r++)s(t[r],i[r],l),i[r].item&&this.trigger(v,{item:e(t[r]),data:i[r].item,ns:n.ui})}).bind(this),function(e,n,s){var l=n-a;var c,d;s||Math.abs(l)>=o?(c=t,d=e):(c=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,l),d=l>0?e.slice(-l):e.slice(0,-l)),i(c,d,r.bound()),a=n}},_bufferSizes:function(){var e=this.options;return t=this._screenHeight,n=e.listScreens,i=e.oppositeBuffer,{down:t*i,up:t*(n-1-i)};var t,n,i},_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+y,"."+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,u=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],u));else(i=s[c])!==t&&(o=this._getElementByIndex(i),f=this._deselectSingleItem(o,c,i,u));f&&(n.splice(d,1),a.push(f),u++,d--),d++}}}else{for(var g=0;g<s.length;g++)s[g]!==t?this._getElementByIndex(s[g]).removeClass(h):l[g]&&this._getElementByDataItem(l[g]).removeClass(h),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(h))return e.removeClass(h),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=this.element[0].children;var i,r,o;var a=this._values;var s=[];var l=0;var c;if("multiple"!==this.options.selectable||!this.isFiltered())return[];if(-1===t[0])return e(n).removeClass(h),s=e.map(this._selectedDataItems.slice(0),(function(e,t){return{dataItem:e,position:t}})),this._selectedIndexes=[],this._selectedDataItems=[],this._values=[],s;for(;l<t.length;l++){for(o=-1,r=t[l],this.dataItemByIndex(r)&&(i=this._valueGetter(this.dataItemByIndex(r))),c=0;c<a.length;c++)if(i==a[c]){o=c;break}o>-1&&(s.push(this.removeAt(o)),e(n[r]).removeClass(h))}return s},_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(h),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);var t=n.support.scrollbar();var i=this.content.parent().parent().find(".k-table-header");var 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,h=n.keys,u=".kendoDropDownList",p=u+"FocusEvent",f="disabled",m="readonly",g="change",v="k-focus",_="k-disabled",b="aria-disabled",w="aria-readonly",y="click"+u+" touchend"+u,k="mouseenter"+u+" mouseleave"+u,x="tabindex",C="filter",S="accept";var T=s.extend({init:function(i,r){var o=this;var a=r&&r.index;var l,c;o.ns=u,r=Array.isArray(r)?{dataSource:r}:r,s.fn.init.call(o,i,r),r=o.options,i=o.element.on("focus"+u,o._focusHandler.bind(o)),!n.isPresent(r.readonly)&&i.attr("readonly")?r.readonly=!0:n.isPresent(r.readonly)||(r.readonly=!1),o._focusInputHandler=o._focusInput.bind(o),o.optionLabel=e(),o._optionLabel(),o._inputTemplate(),o._reset(),o._prev="",o._word="",o._wrapper(),o._tabindex(),o.wrapper.data(x,o.wrapper.attr(x)),o._span(),o._popup(),o._mobile(),o._dataSource(),o._ignoreCase(),r.label&&this._label(),o._aria(),o._enable(),o._oldIndex=o.selectedIndex=-1,a!==t&&(r.index=a),o._initialIndex=r.index,o.requireValueMapper(o.options),o._initList(),o.listView.one("dataBound",o._attachAriaActiveDescendant.bind(o)),o.listView.bind("dataBound",(()=>o._refreshFloatingLabel())),o._cascade(),o.one("set",(function(e){!e.sender.listView.bound()&&o.hasOptionLabel()&&o._textAccessor(o._optionLabelText())})),r.autoBind?o.dataSource.fetch():-1===o.selectedIndex&&((c=r.text||"")||((l=r.optionLabel)&&0===r.index?c=l:o._isSelect&&(c=i.children(":selected").text())),o._textAccessor(c)),e(o.element).parents("fieldset").is(":disabled")&&o.enable(!1),o.listView.bind("click",(function(e){e.preventDefault()})),n.notify(o),o._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,readonly:null,size:"medium",fillMode:"solid",rounded:"medium",label:null,popupFilter:!0,adaptiveTitle:null,adaptiveSubtitle:null},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(u),e.wrapper.off(p),e.element.off(u),e._arrow.off(),e._arrow=null,e._arrowIcon=null,e.optionLabel.off(),e.filterInput&&e.filterInput.off(p)},open:function(){var e=this;var t=!!e.dataSource.filter()&&e.dataSource.filter().filters.length>0;var 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;var t=this._prevent;if(e&&!this._hasActionSheet()){var i=this.filterInput[0]===c();var 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;var 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=this;var i;var r=n.options.ignoreCase;if((e=null===e?"":e)===t)return n._textAccessor();"string"==typeof e?(i=r?e.toLowerCase():e,n._select((function(e){return e=n._text(e),r&&(e=(e+"").toLowerCase()),e===i})).done((function(){n._textAccessor(n.dataItem()||e),n._refreshFloatingLabel()}))):n._textAccessor(e)},_clearFilter:function(){e(this.filterInput).val(""),s.fn._clearFilter.call(this)},value:function(e){var n=this;var i=n.listView;var 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;var r=t.options;var o=r.optionLabel;var 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(y,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;var 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];var r=n._optionLabelDataItem();var 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=this;var t=e._initialIndex;var n=e._state===C;var i=e.dataSource.flatView();var r;e._presetValue=!1,e._renderFooter(),e._renderNoData(),e._toggleNoData(!i.length),e._resizePopup(!0),e.popup.position(),e._buildOptions(i),n||(e._open&&e.toggle(e._allowOpening()),e._open=!1,e._fetch||(i.length?(!e.listView.value().length&&t>-1&&null!==t&&e.select(t),e._initialIndex=null,(r=e.listView.selectedDataItems()[0])&&e.text()!==e._text(r)&&e._selectValue(r)):e._textAccessor()!==e._optionLabelText()&&(e.listView.value(""),e._selectValue(null),e._oldIndex=e.selectedIndex))),e._hideBusy(),e.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;var 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(e){const t=this;let n=!(t.filterInput&&!t._touchEnabled())||e.currentTarget!==t.filterInput[0];t.popup&&t._hasActionSheet()&&(n=!0,t.popup.unbind("close"),t.popup.bind("close",(function(){t._change()}))),t._prevent=n},_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;var i=t.element;var r=e.disable;var o=e.readonly;var a=t.wrapper.add(t.filterInput).off(u);var 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(w,!1).on("keydown"+u,t,t._keydown.bind(t)).on(n.support.mousedown+u,t._wrapperMousedown.bind(t)).on("paste"+u,t._filterPaste.bind(t)),t.wrapper.on("click"+u,t._wrapperClick.bind(t)),t.filterInput?a.on("input"+u,t._search.bind(t)):a.on("keypress"+u,t._keypress.bind(t))),i.attr(f,r).attr(m,o),a.attr(b,r).attr(w,o)},_keydown:function(e){var t=this;var n=e.keyCode;var i=e.altKey;var r;var o;var a=t.popup.visible();if(t.filterInput&&(r=t.filterInput[0]===c()),n===h.LEFT?(n=h.UP,o=!0):n===h.RIGHT&&(n=h.DOWN,o=!0),!o||!r)if(e.keyCode=n,(i&&n===h.UP||n===h.ESC)&&t._focusElement(t.wrapper),t._state===C&&n===h.ESC&&(t._clearFilter(),t._open=!1,t._state=S),n===h.ENTER&&t._typingTimeout&&t.filterInput&&a)e.preventDefault();else if(n!==h.SPACEBAR||r||(t.toggle(!a),e.preventDefault()),!(o=t._move(e))){if(!a||!t.filterInput){var s=t._focus();if(n===h.HOME?(o=!0,t._firstItem()):n===h.END&&(o=!0,t._lastItem()),o){if(t.trigger("select",{dataItem:t._getElementDataItem(t._focus()),item:t._focus()}))return void t._focus(s);t._select(t._focus(),!0).done((function(){a||t._blur()})),e.preventDefault()}}i||o||!t.filterInput||t._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=this;var t=e.dataSource.flatView();var n=t.length+(e.hasOptionLabel()?1:0);var i=function(e,t){for(var n=0;n<e.length;n++)if(e.charAt(n)!==t)return!1;return!0}(e._word,e._last);var r=e.selectedIndex;var o;var a;r=-1===r?0:A(r+=i?1:0,n),t=t.toJSON?t.toJSON():t.slice(),t=e._shuffleData(t,r);for(var s=0;s<n&&(a=e._text(t[s]),!i||!e._matchText(a,e._last))&&!e._matchText(a,e._word);s++);s!==n&&(o=e._focus(),e._select(A(r+s,n)).done((function(){var t=function(){e.popup.visible()||e._change()};e.trigger("select",{dataItem:e._getElementDataItem(e._focus()),item:e._focus()})?e._select(o).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;var 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)})))},_touchEnabled:function(){return l.mobileOS&&(l.touch||l.MSPointers||l.pointers)},_focusElement:function(e){var t=c();var n=this.wrapper;var i=this.filterInput;var r=e===i?n:i;var o=this._touchEnabled();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;var 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;var o="function"==typeof t;var 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;var n=this.listView;var i=n.focus();var 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;var 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;var i=n.options.optionLabel;var r=n.listView.select();var o="";var 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;var r=this.valueTemplate;var o=this._optionLabelText();var 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;var i={};return n?(M(i,n.split("."),e),M(i,this.options.dataValueField.split("."),t),i=new d(i)):i=e,i}});function M(e,t,n){var i,r=0,o=t.length-1;for(;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.caret,r=n.keys,o=n.html,a=n.ui,s=a.Widget,l=n._activeElement,c=n._extractFormat,d=n.parseFloat,h=n.support.placeholder,u=n.getCulture,p="change",f="disabled",m="readonly",g="k-input-inner",v="spin",_=".kendoNumericTextBox",b="mouseenter"+_+" "+("mouseleave"+_),w="k-focus",y="k-hover",k="focus",x=".",C="k-selected",S="k-disabled",T="k-invalid",M="aria-disabled",A=/^(-)?(\d*)$/,D=null,E=e.isPlainObject,I=e.extend;var z=s.extend({init:function(i,r){var o,a,l,d,h=this,u=r&&r.step!==t;var p;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"),r.inputMode=r.inputMode||i.attr("inputmode")||"text",o=h.min(i.attr("min")),a=h.max(i.attr("max")),l=h._parse(i.attr("step")),r.min===D&&o!==D&&(r.min=o),r.max===D&&a!==D&&(r.max=a),u||l===D||(r.step=l),h._initialOptions=I({},r),p=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!==D?r.min*r.factor:r.min).attr("aria-valuemax",r.max!==D?r.max*r.factor:r.max),r.format=c(r.format),(d=r.value)==D&&(d="number"==p?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(),Yu({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:D,autoAdjust:!0,enable:!0,restrictDecimals:!1,min:D,max:D,value:D,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(M,i)):(a.removeClass(S).on(b,t._toggleHover),o.prop(f,!1).prop(m,!1).attr(M,!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!==D?n.options.min*n.options.factor:n.options.min,"aria-valuemax":n.options.max!==D?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=D),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!==D&&r?(n!==D&&e<n?e=n:i!==D&&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[","],h=0;d&&(r=new RegExp("\\"+d,"g"),o=new RegExp("(-)?("+c.symbol+")?([\\d\\"+d+"]+)(\\"+c[x]+")?(\\d+)?")),o&&(n=o.exec(l)),n&&(h=n[0].replace(r,"").length,-1!=l.indexOf("(")&&t._value<0&&h++),t._focusin(),i(t.element[0],h),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||u(this.options.culture)},_focusin:function(){var e=this;e.wrapper.addClass(w),e._toggleText(!1),e.element.trigger("focus")},_focusout:function(){var e=this;clearTimeout(e._focusing),e.wrapper.removeClass(w).removeClass(y),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,s=i.wrapper.find(x+g);i.element.attr("inputmode",r.inputMode),(t=s.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!==D?r.min*r.factor:r.min,"aria-valuemax":r.max!==D?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;var t=e.val();var n=this.options.min;var r=this._format(this.options.format);var o=r[x];var 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;var n=e[x];var i=t.options.decimals;var r="*";return n===x&&(n="\\"+n),i===D&&(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;var n=e.target;var i=n.value;var r=t._format(t.options.format);t._isPasted=!0,setTimeout((function(){var e=t._parse(n.value);e===D?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(y,"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:L)(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===D&&(l=d.decimals),(i=(e=r._parse(e,c))!==D)&&(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),h||e||t.val(this.options.placeholder),t.attr("title",this.element.attr("title")||t.val())},_label:function(){var i=this;var r=i.element;var o=i.options;var a=r.attr("id");var s;var l;null!==o.label&&(s=!!E(o.label)&&o.label.floating,l=E(o.label)?o.label.content:o.label,s&&(i._floatingLabelContainer=i.wrapper.wrap("<span></span>").parent(),i.floatingLabel=new n.ui.FloatingLabel(i._floatingLabelContainer,{widget:i})),n.isFunction(l)&&(l=l.call(i)),l||(l=""),a||(a=o.name+"_"+n.guid(),r.attr("id",a)),i._inputLabel=e("<label class='"+(s?"k-floating-label":"k-label k-input-label")+"' for='"+a+"'>"+l+"</label>'")[s?"insertAfter":"insertBefore"](i.wrapper),i.element.attr("disabled")===t&&i.element.attr("readonly")===t&&i._inputLabel.on("click"+_,i.focus.bind(i)))},_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";var 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 L(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.keys,a=n.htmlEncode,s=n.template,l="caret-alt-to-left",c="caret-alt-to-right",d="caret-alt-left",h="caret-alt-right",u="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",w=Number.MAX_VALUE,y=!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(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 C(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 S(e,t){C(e,l,1,t<=1)}function T(e,t){C(e,d,Math.max(1,t-1),t<=1)}function M(e,t,n){C(e,h,Math.min(n,t+1),t>=n)}function A(e,t,n){C(e,c,n,t>=n)}var D=r.extend({init:function(t,i){var o,s,g=this;var w="";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()),y=n.support.isRtl(t),g._numericWrap=g.element.find(".k-pager-numbers-wrap"),y?(l=p,c=u,d=m,h=f,g._numericWrap.length&&g._numericWrap.empty()):(l=u,c=p,d=f,h=m),i.size&&(w=n.getValidCssClass("k-button-","size",i.size),"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(x(l,i.messages.first,"k-pager-first",g._id,w)),S(g._numericWrap,o)),g._numericWrap.find("[class*='-i-"+d+"']").length||(g._numericWrap.append(x(d,i.messages.previous,null,g._id,w)),T(g._numericWrap,o))),i.numeric){if(g.element.find(".k-pager-input").length)g._decoratePagerInput(g.element.find(".k-pager-input"),s),g._initNumericInputTextBox();else{let t=g._decoratePagerInput(e("<span class='k-pager-input'></span>"),s);g._numericWrap.append(t),g._initNumericInputTextBox()}i.input||(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.list.empty().append(g.selectTemplate({text:0,tabindex:i.navigatalbe?0:-1,navigatable:i.navigatable,title:n.format(i.messages.pageButtonLabel,0)})),g._pagerInputWrap.hide())}if(i.previousNext&&(g._numericWrap.find("[class*='-i-"+h+"']").length||(g._numericWrap.append(x(h,i.messages.next,null,g._id,w)),M(g._numericWrap,o,s)),g._numericWrap.find("[class*='-i-"+c+"']").length||(g._numericWrap.append(x(c,i.messages.last,"k-pager-last",g._id,w)),A(g._numericWrap,o,s))),i.pageSizes){if(!g.element.find(".k-pager-sizes").length){var k=i.pageSizes.length?i.pageSizes:["all",5,10,20];var C=e.map(k,(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(C.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,adaptiveMode:i.adaptiveMode}),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 '+w+' 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)).addClass("k-pager"),i.size&&g.element.addClass(n.getValidCssClass("k-pager-","size",i.size)),i.responsive&&g.element.addClass("k-pager-responsive"),i.autoBind&&g.refresh(),g._resizeHandler=g.resize.bind(g,!0),e(window).on("resize"+_,g._resizeHandler),g._navigatable(),g._lastWidth=1,g.resize(),n.notify(g)},_initNumericInputTextBox:function(){let e=this,t=e.options;e._numericTextBox=e._numericWrap.find(".k-pager-input input").kendoNumericTextBox({spinners:!1,size:t.size,min:1,format:"n0",change:function(t){let n=this.value();(n<1||n>e.totalPages())&&(n=e.page()),setTimeout((function(){e.page(n)}),100)}}).data("kendoNumericTextBox"),e._numericTextBox.element.on("focus"+_,(()=>e._restoreTabIndexes())),e._numericTextBox.wrapper.find(".k-input-spinner").remove(),e._pagerInputWrap=e.element.find(".k-pager-input")},_decoratePagerInput:function(t,i){let r=this.options;return e(t).append("<span>"+a(r.messages.page)+"</span>"+`<input aria-label='${this.options.messages.page}'/><span>`+a(n.format(r.messages.of,i))+"</span>"),t},destroy:function(){var t=this;r.fn.destroy.call(t),t.element.off(_),t.dataSource.unbind(v,t._refreshHandler),t._refreshHandler=null;let i=t.element.find(".k-pager-input");i.length&&i.remove(),e(window).off("resize"+_,this._resizeHandler),n.destroy(t.element),t.element=t.list=null},events:[v],options:{name:"Pager",adaptiveMode:"none",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",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;var r=parseInt(this.element.css("gap"));switch(e){case 0:return i._toggleButtons(t,n);case 1:return i._toggleRefresh(t,n-r);case 2:return i._togglePagerInfo(t,n-r);case 3:return i._toggleInputSizesLabel(t,n-r);case 4:return i._togglePageSizesLabel(t,n-r);case 5:return i._togglePageSizesDropDown(t,n-r)}},_calculateNeededWidth:function(){let t=0;const i=parseInt(this.element.css("gap"));const r=parseInt(this.element.css("padding-left"));const o=parseInt(this.element.css("padding-right"));return this.element.children().each((function(){const i=e(this);const r=i.hasClass("k-pager-info");r&&i.removeClass("k-pager-info"),t+=i.is(":visible")?n._outerWidth(i):0,r&&i.addClass("k-pager-info")})),t+=i*(this.element.children(":visible").length-1),t+r+o},_resize:function(e){var t=this;const n=e.width;if(t.element.is(":visible")&&t._lastWidth&&t.options.responsive){if(t._lastWidth<n)for(let e=5;e>=0;e--){const i=t._calculateNeededWidth();if(n<i)break;if(t._adaptiveStep(e,!1,n-i))break}else if(t._lastWidth>n)for(let e=0;e<6&&!(n-3>t._calculateNeededWidth());e++)t._adaptiveStep(e,!0);t._lastWidth=n}},_toggleButtons:function(e,t){if(this.options.input||!this._numericWrap||!this.list||!this._numericTextBox)return;const i=n._outerWidth(this._pagerInputWrap,!0);e?(this._pagerInputWrap.show(),this.list.hide()):t&&this.list.width()-i<t&&(this._pagerInputWrap.hide(),this.list.show())},_toggleRefresh:function(e,t){if(!this.options.refresh)return;const i=this.element.find(".k-pager-refresh");if(e)i.hide();else if(t&&n._outerWidth(i)<t)i.show();else if(i.is(":hidden"))return!0},_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._numericTextBox)return;const n=this.element.find(".k-pager-input").children();const i=n.eq(0);if(e)i.hide();else if(t&&n.eq(0).width()<t)i.show();else if(i.is(":hidden"))return!0},_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)n.show();else if(n.is(":hidden"))return!0},_togglePageSizesDropDown:function(e,t){if(!this.options.pageSizes)return;const i=this.element.find(".k-pager-sizes .k-picker");if(e)i.hide();else if(t&&n._outerWidth(i)<t)i.show();else if(!i.is(":visible"))return!0},_createDataSource:function(e){this.dataSource=n.data.DataSource.create(e.dataSource)},refresh:function(e){var t,i,r,o=this,s=1,l=o.page(),c="",d=o.options,h=o.pageSize(),u=o._collapsedTotal(),p=o.dataSource._isGroupPaged()?o.dataSource.groupsTotal(!0):o.dataSource.total(),f=o.totalPages(),m=o.linkTemplate,g=d.navigatable,v=o.numericSelectItemTemplate,_=d.size?n.getValidCssClass("k-button-","size",d.size):"",b=d.buttonCount;if(!e||"itemchange"!=e.action){if(d.numeric&&!d.input){for(l>b&&(s=0===(r=l%b)?l-b+1:l-r+1),i=Math.min(s+b-1,f),s>1&&(c+=k({template:m,navigatable:g,size:_,idx:s-1,text:"...",numeric:!1,title:d.messages.morePages})),t=s;t<=i;t++)c+=k({template:t==l?o.selectTemplate:m,navigatable:g,idx:t,text:t,size:_,numeric:!0,title:n.format(d.messages.pageButtonLabel,t)});i<f&&(c+=k({template:m,navigatable:g,idx:t,size:_,text:"...",numeric:v,title:d.messages.morePages})),""===c&&(c=o.selectTemplate({text:0,size:_,tabindex:g?0:-1,navigatable:g,title:n.format(d.messages.pageButtonLabel,0)})),o.list.html(c)}if(d.info&&(c=p>0?n.format(d.messages.display,o.dataSource.options.endless?1:Math.min((l-1)*(o.dataSource.pageSize()||0)+1,u),Math.min(l*h,u),p):d.messages.empty,o.element.find(".k-pager-info").html(c)),o._numericTextBox&&(o._numericTextBox.value(l),p>0!=!o._numericTextBox.wrapper.hasClass("k-disabled")&&o._numericTextBox.enable(p>0),o._numericTextBox.wrapper.prev().html("<span>"+a(d.messages.page)+"</span>"),o._numericTextBox.wrapper.next().html("<span>"+a(n.format(d.messages.of,f))+"</span>")),d.previousNext&&(S(o.element,l),T(o.element,l),M(o.element,l,f),A(o.element,l,f)),d.pageSizes){var y=h;o.element.find(".k-pager-sizes option[value='all']").length>0&&(h===this.dataSource.total()||h==w)&&(h="all",y=d.messages.allPages),o.element.find(".k-pager-sizes select").val(h).filter("["+n.attr("role")+"=dropdownlist]").kendoDropDownList("value",h).kendoDropDownList("text",y)}o._restoreFocus(s,i,f),o._excludeChildrenFromTab(),o._updateAria(),f?(o._lastWidth=n._outerWidth(o.element)+12,o.resize(!0)):o._lastWidth&&(o._lastWidth=n._outerWidth(o.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()},_refreshClick:function(e){e.preventDefault(),this.dataSource.read()},_change:function(e){var n=e.currentTarget.value;var i=parseInt(n,10);var 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=this;var i=e(t.target);var r;var a=!1;var s;i[0]===n.element[0]&&t.keyCode==o.ENTER&&(n._restoreTabIndexes(),n.element.find(g).first().trigger("focus"),a=!0),i[0]!==n.element[0]&&t.keyCode==o.ESC&&(n.element.trigger("focus"),a=!0),i[0]===n.element[0]&&t.keyCode==o.HOME&&(n.page(1),a=!0),i[0]===n.element[0]&&t.keyCode==o.END&&(n.page(n.totalPages()),a=!0),i[0]!==n.element[0]||t.keyCode!=(y?o.LEFT:o.RIGHT)&&t.keyCode!=o.PAGEDOWN||(n.page(n.page()+1),a=!0),i[0]!==n.element[0]||t.keyCode!=(y?o.RIGHT:o.LEFT)&&t.keyCode!=o.PAGEUP||(n.page(n.page()-1||1),a=!0),i[0]!==n.element[0]&&t.keyCode==o.TAB&&(n.options._isToolbarItem&&n._restoreTabIndexes(),s=(r=n.element.find(g)).index(i),t.shiftKey?s-1<0?r.last().trigger("focus"):r.eq(s-1).trigger("focus"):s+1<r.length?r.eq(s+1).trigger("focus"):r.first().trigger("focus"),a=!0),a&&(t.preventDefault(),t.stopPropagation())},_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(D)}(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",h=".k-notification-actions .k-icon",u="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",w="bottom",y="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"})}};var M=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;var 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:y;switch(e){case"down":i=w+" "+s,r=_+" "+s,delete a.paddingBottom;break;case y:i=_+" "+y,r=_+" "+b,delete a.paddingRight;break;case b:i=_+" "+b,r=_+" "+y,delete a.paddingLeft;break;case"up":i=_+" "+s,r=w+" "+s,delete a.paddingTop;break;default:null!==t?(i=w+" "+s,r=_+" "+s,delete a.paddingBottom):(i=_+" "+s,r=w+" "+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(h),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(."+u+")").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(h).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(u),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(h))}),i):o(t.find(h)))},_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(h).off(k),e.remove()}})),this._triggerHide(e)},_triggerHide:function(e){this.trigger(c,{element:e})},show:function(i,o,a){var s,c,h=this,u=h.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:u.button},s=e.isPlainObject(i)?r(c,i):r(c,{content:i}),f.addClass(d+"-"+o).toggleClass(d+"-closable",u.button).attr({"data-role":"alert",title:u.title}).css({width:u.width,height:u.height}).append(h._getCompiled(o,a)(s)),h.options.button&&f.append(h.addActions("close")),f.find(".k-notification-content").attr("id",m),f.attr("aria-describedby",m),e(u.appendTo)[0]?h._showStatic(f,u):h._showPopup(f,u),h.trigger(l,{element:f})),h},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(."+u+")");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(h).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(M)}(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",h="show",u="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",w={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"}},y={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 M(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._shown=!1,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;const 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?y[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-"+y[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 D=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:[h,u,f,p,m],_mouseenter:function(t){M(e(t.currentTarget))},_saveTitle:function(e){M(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(h),n.popup._hovered=undefined},close:function(){n.trigger(u)},copyAnchorStyles:!1,animation:r.animation},w[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;const 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(D)}(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,h=n.ui.Selectable,u=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"> </td>')),w=f((e=>`<td class="k-calendar-td k-alt">${e.weekNumber}</td>`)),y=n._outerWidth,k=".kendoCalendar",x="click"+k,C="keydown"+k,S="id",T="slideIn",M="month",A="century",D="change",E="navigate",I="value",z="k-disabled",P="k-focus",L="k-other-month",B="k-empty",H="td:has(.k-link)",R="start",F="td:has(.k-link):not(."+z+"):not(."+B+")",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,H,fe).on(C,"table.k-calendar-table",a._move.bind(a)).on(x+" touchend",F,(function(t){var n=t.currentTarget.firstChild,i=ye(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(F).first(),i=e(t.currentTarget).closest("tr").find(F).last();a._isMultipleSelection()&&(a.selectable._lastActive=i,a.selectable.selectRange(n,i),a.selectable.trigger(D,{event:t})),a._isRangeSelection()&&(a.rangeSelectable._lastActive=i,a.rangeSelectable.range(n,i),a.rangeSelectable.change()),a._current=a._value=ye(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:R},selectable:"single",selectDates:[],start:M,depth:M,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:[D,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):we(t._value,t._current)&&we(t._value,e)||(t.value(e),t.trigger(D)))},navigate:function(n,i){i=isNaN(i)?ee[i]:i;var r,o,a,s,c=this,d=c.options,h=d.culture,u=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,w=c.element.children(".k-calendar-view");if(n||(n=v),c._current=n=new J(+le(n,u,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,u)<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,u,p,h)+"</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:u,max:p,date:n,url:d.url,dates:d.dates,format:d.format,showOtherMonthDays:d.showOtherMonthDays,centuryCellsFormat:d.centuryCellsFormat,culture:h,disableDates:d.disableDates,isWeekColumnVisible:d.weekNumber,messages:d.messages,contentClasses:c.options.contentClasses},c[o.name]))),c._aria();var y=m&&m.data("start")===r.data("start");c._animate({from:m,to:r,vertical:b,future:_,replace:y}),w.removeClass("k-calendar-monthview k-calendar-yearview k-calendar-decadeview k-calendar-centuryview"),w.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;var i={};e.each(t._selectDates,(function(e,t){i[n.calendar.views[0].toDateString(t)]=t})),t.selectable.clear();var r=t._table.find(H).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 h.parseOptions(e).single},_isMultipleSelection:function(){let e=this.options.selectable;return h.parseOptions(e).multiple},_isRangeSelection:function(){let e=this.options.selectable;return h.parseOptions(e).range},_selectable:function(){let e=this,t=e.options.selectable,n=h.parseOptions(t);(e._isMultipleSelection()||e._isRangeSelection())&&(e.rangeSelectable&&(e.rangeSelectable.destroy(),e.rangeSelectable=null),n.range?(e.rangeSelectable=new u(e.wrapper,{widget:e,filter:".k-calendar-monthview table "+F,cellSelector:H,cellSelectorValid:F,change:e._onSelect.bind(e),reverse:e.options.allowReverse,resetOnStart:!0,ns:k}),e.element.addClass("k-calendar-range")):e.selectable=new h(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) "+F,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(F)))},_onRelatedTarget:function(e){var t=this;t.selectable.options.multiple&&e.is(F)&&(t._current=ye(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,u=t.sender._useStart,p=h.parseOptions(l.options.selectable);if(l._isRangeSelection())return n=t.sender.range(),i=l.selectRange()||{},s=i.target,n.start&&n.start.length&&(r=ye(n.start.find("span"))),n.end&&n.end.length&&(o=ye(n.end.find("span"))),s="end"===s?R:"end",l._range={start:u?i.start:r,end:d?i.end:o,target:s},l._preventChange||l.trigger(D),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(F)?l._toggleSelection(e(c.event.currentTarget)):(l._cellsBySelector(F).each((function(t,n){var i=ye(e(n).find("span"));l._deselect(i)})),l._addSelectedCellsToArray()):c.event.shiftKey?l._rangeSelection(l._cell):e(c.event.currentTarget).is(H)?l.value(ye(e(c.event.currentTarget).find("span"))):(l._selectDates=[],l._addSelectedCellsToArray()),l.trigger(D)):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=ye(e.find("span"));e.hasClass("k-selected")?this._selectDates.push(t):this._deselect(t)},_rangeSelection:function(e,t){var n,i=this,r=t||ye(i.selectable.value().first().find("span")),o=ye(e.find("span"));i.selectable._lastActive||i._value?r=i.selectable._lastActive?ye(i.selectable._lastActive.find("span")):new Date(+i._value):i.selectable._lastActive=t?i._cellByDate(i._view.toDateString(t),F):i.selectable.value().first(),i._selectDates=[],n=ue(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:ye(e.first().find(H).first().find("span")),end:ye(e.last().find(H).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=ye(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=ye(this._cellsBySelector(F).first().find("span"));return+e<=+ye(this._cellsBySelector(F).last().find("span"))&&+e>=+t},_isNavigatable:function(e,t){var n=this;var i=n.options.disableDates;var r;return"month"==n._view.name?!i(e):(r=n.wrapper.find("."+P).index(),n.wrapper.find(".k-calendar-table td").eq(r+t).is(F)||!i(e))},_dateInViews:function(e){let t=this.element.find(".k-calendar-view table"),n=ye(t.first().find(H).first().find("span")),i=ye(t.last().find(H).last().find("span"));return+(e=new Date(e.toDateString()))<=+i&&+e>=+n},_move:function(n){var i,r,o,s,l,c,d=this,h=d.options,u=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),u==a.RIGHT&&!_||u==a.LEFT&&_?(i=1,r=!0):u==a.LEFT&&!_||u==a.RIGHT&&_?(i=-1,r=!0):u==a.UP?(i=0===f?-7:-4,r=!0):u==a.DOWN?(i=0===f?7:4,r=!0):u==a.SPACEBAR?(i=0,r=!0):u==a.HOME||u==a.END?(s=p[o=u==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===u&&(d._todayClick(n),r=!0),n.ctrlKey||n.metaKey){if(u==a.RIGHT&&!_||u==a.LEFT&&_)d.navigateToFuture(),r=!0;else if(u==a.LEFT&&!_||u==a.RIGHT&&_)d.navigateToPast(),r=!0;else if(u==a.UP)d.navigateUp(),r=!0;else if(u==a.DOWN)d._click(e(d._cell[0].firstChild)),r=!0;else if((u==a.ENTER||u==a.SPACEBAR)&&d._isMultipleSelection()){d._keyboardToggleSelection(n);var w=ye(e(d._cell[0]).find("span"));d._setCurrent(w)}}else n.shiftKey?((i!==t||o)&&(o||p.setDate(v,i),ce(v,m,g)||(v=le(v,h.min,h.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=ye((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))):(u==a.ENTER||u==a.SPACEBAR?("month"==p.name&&d._isMultipleSelection()?(d.value(ye(e(d._cell.find("span")))),d.selectable._lastActive=e(d._cell[0]),d.trigger(D)):d.rangeSelectable?d.rangeSelectable.change():d._click(e(d._cell[0].firstChild)),r=!0):u==a.PAGEUP?(r=!0,d.navigateToPast()):u==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,h.min,h.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=ue(n=r.selectable._lastActive?ye(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),F),void r.trigger(D);r.selectable.options.filter=r.wrapper.find("table").length>1&&+t>+r._current?"table.k-calendar-table:eq(1) "+F:"table.k-calendar-table:eq(0) "+F,r._setCurrent(t),r._current=t,r._rangeSelection(r._cellByDate(r._view.toDateString(t),F),t),r.trigger(D),r.selectable.options.filter="table.k-calendar-table:eq(0) "+F},_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(D,{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;var n=e.from;var i=e.to;var r=t._active;var 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=y(e),l=y(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(."+L+")").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,H),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()?H:"td:not(."+L+")"),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=ye(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;var 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=ye(n._table.find("td:not(."+L+"):not(."+B+")").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(D))},_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)||" "}</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=this;var r=i._cell;var o=i.view().valueType();var a=t||i.current();var s;return s="month"===o?n.toString(a,"MMMM"):"date"===o?n.toString(a,"D"):r.text(),r.attr("aria-label",e({current:a,valueType:o,text:s})),r.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:M,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,h=e.format,u=e.culture,p=e.url,f=e.showHeader,m=e.showOtherMonthDays,g=e.isWeekColumnVisible,v=p&&s[0],_=ve(u),b=_.firstDay,w=_.days,y=de(w.names,b),k=de(w.namesShort,b),x=ie.firstVisibleDay(a,_),C=t.first(a),S=t.last(a),T=t.toDateString,M=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,u)+"</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="'+y[i]+'">'+k[i]+"</th>";return c(M,0),M=+M,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(L),i(e)&&r.push(z),+e===M&&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,h,u)),a=" k-action-link"),{date:e,dates:s,ns:n.ns,title:n.toString(e,"D",u),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(B),{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){he(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"];var l=t.getFullYear(),c=l+9;return 10!==a&&11!==a||s.push(B),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){he(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,h=e.isWeekColumnVisible,u=e.perRow||4,p=e.showOtherMonthDays,f=e.lastDayOfMonth,m=e.weekNumber||w,g=e.content||v,y=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(h&&(x+=m(l(o)));n<d;n++)n>0&&n%u==0&&(x+='</tr><tr role="row" class="k-calendar-tr">',h&&(x+=m(p||+o<=+f?l(o):{weekNumber:" "}))),o=ge(o.getFullYear(),o.getMonth(),o.getDate()),c(o,0),-1===(t=s(o,n,e.disableDates)).cssClass.indexOf(L)||p?ce(o,i,r)&&-1===t.cssClass.indexOf(B)?x+=g(t):x+=y(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 he(e,t,n){t=t instanceof J?t.getFullYear():e.getFullYear()+n*t,e.setFullYear(t)}function ue(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());var 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=M),(i===t||i>n)&&(e.depth=M),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){var t=[];for(var 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 we(e,t){return e instanceof Date&&t instanceof Date&&(e=e.getTime(),t=t.getTime()),e===t}function ye(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=we,ie.restrictValue=le,ie.isInRange=ce,ie.normalize=_e,ie.viewsEnum=ee,ie.disabled=be,ie.toDateObject=ye,ie.getToday=se,ie.createDate=ge,n.calendar=ie}(window.kendo.jQuery);kendo;var bg=function(e){return e?new Date(e.getTime()):null};var wg=function(e,t){var n=bg(e);return 0===t&&23===n.getHours()&&n.setHours(n.getHours()+2),n};var yg=function(e,t){var n=bg(e);return n.setDate(n.getDate()+t),wg(n,e.getHours())};var kg=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),wg(s,i)};var xg=function(e){var t=kg(e.getFullYear(),e.getMonth()+1,1,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());return yg(t,-1)};var Cg=function(e,t){var n=bg(e);var i=(12+(n.getMonth()+t)%12)%12;return n.setMonth(n.getMonth()+t),function(e,t){return e.getMonth()!==t?xg(Cg(e,-1)):e}(wg(n,e.getHours()),i)};var Sg;!function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"}(Sg||(Sg={}));var Tg=function(e,t,n){void 0===n&&(n=Sg.Forward);var i=bg(e);var r=(t-i.getDay()+7*n)%7;return i.setDate(i.getDate()+r),wg(i,e.getHours())};var Mg;!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"}(Mg||(Mg={}));var Ag=function(e){return kg(e.getFullYear(),e.getMonth(),1,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())};var Dg=function(e){return kg(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0)};var Eg=function(e,t){return!e&&!t||e&&t&&e.getTime()===t.getTime()};var Ig={rules:{},titles:{},zones:{}};var zg={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11};var Pg={Sun:0,Mon:1,Tue:2,Wed:3,Thu:4,Fri:5,Sat:6};var Lg=function(e,t,n){var i=t[3];var r=t[4];var o=t[5];var a;var s="u"===o[3]?6e4*-n:0;if(isNaN(r)){if(0===r.indexOf("last")){a=new Date(Date.UTC(e,zg[i]+1,1,o[0]-24,o[1],o[2])+s);var l=Pg[r.substr(4,3)];var c=a.getUTCDay();a.setUTCDate(a.getUTCDate()+l-c-(l>c?7:0))}else if(r.indexOf(">=")>=0){a=new Date(Date.UTC(e,zg[i],r.substr(5),o[0],o[1],o[2],0)+s);l=Pg[r.substr(0,3)];c=a.getUTCDay();a.setUTCDate(a.getUTCDate()+l-c+(l<c?7:0))}}else a=new Date(Date.UTC(e,zg[i],r,o[0],o[1],o[2])+s);return a};var Bg=(new Date).getTime();var Hg=function(e,t,n){void 0===t&&(t=Bg),void 0===n&&(n=0);var i=Ig.rules[e];if(!i){var r=e.split(":");var 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];var 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(Lg(a,e,n))),"number"!=typeof t&&(t=Number(Lg(a,t,n))),e-t}));var s=i[i.indexOf(t)-1]||i[i.length-1];return isNaN(s)?s:null};var Rg="The required {0} timezone information is not provided!";var Fg=/\{(\d+)}?\}/g;var Og=function(e){var t=[];for(var 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(Fg,(function(e,t){return i[parseInt(t,10)]}))};var Vg=function(e,t){if(void 0===t&&(t=(new Date).getTime()),"Etc/UTC"===e||"Etc/GMT"===e)return[0,"-","UTC",null];var n=function(e){var t=Ig.zones;if(!t)throw new Error(Og(Rg,e));var n=t[e];var i="string"==typeof n?t[n]:n;if(!i)throw new Error(Og(Rg,e));return i}(e);var i=n.length-1;for(;i>=0;i--){var r=n[i][3];if(r&&t>r)break}var o=n[i+1];if(!o)throw new Error(Og(Rg,e));return o};var Ng=function(e,t){var n=t.getTime();var i=Vg(e,n);return{rule:Hg(i[1],n,i[0]),zone:i}};var $g=function(e,t){return void 0===t&&(t=2),(e<0?"-":"")+new Array(t).concat([Math.abs(e)]).join("0").slice(-t)};var Ug=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=Ng(e,t),i=n.rule,r=n.zone;return parseFloat(i?r[0]-i[6]:r[0])};var Wg=function(e,t){return new Date(e.getTime()+6e4*t)};var jg=function(e,t){return new Date(e.getTime()+36e5*t)};var qg=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"];var Gg=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Kg(e,t){var n=Ug(t,e);var i=jg(e,-1);return n<Ug(t,i)}function Yg(e,t){var n=Kg(e,t)?1:0;return jg(e,n)}function Qg(e,t,n){if(t===n)return e;var i=Ug(t,e);var r=Ug(n,e);var o=i-r;var a=Wg(e,o);var s=Ug(n,a);return Wg(e,o+(r-s))}!function(){function e(e,t){this._utcDate=bg(e),this.timezone=t;var n=Ug(t,e);this.timezoneOffset=n;var i=Yg(e,t);this._localDate=Qg(i,t,"Etc/UTC")}Object.defineProperty(e.prototype,"cachedLocalDate",{get:function(){return this._localDate},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"cachedUTCDate",{get:function(){return this._utcDate},enumerable:!1,configurable:!0}),e.fromLocalDate=function(t,n){void 0===n&&(n="");var i=Qg(t,"Etc/UTC",n);var r=Kg(i,n);var o=Ug(n,i);var a=0;r&&(a=o>0?-1:1);var s=jg(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 bg(this._localDate)},e.prototype.toUTCDate=function(){return bg(this._utcDate)},e.prototype.toTimezone=function(t){if(this.timezone===t)return this.clone();var n=Ug(this.timezone,this._utcDate);var i=Wg(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=Yg(new Date(this._utcDate.getTime()),this.timezone);n.setTime(n.getTime()+t);var i=Yg(n,this.timezone);return e.fromUTCDate(i,this.timezone)},e.prototype.stripTime=function(){var t=this._utcDate;var 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=this._utcDate,qg[t.getUTCDay()]+" "+Gg[t.getUTCMonth()]);var t;var n=this.toTimeString();return"".concat(e," ").concat(this.getDate()," ").concat(this.getFullYear()," ").concat(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=$g(this.getHours());var t=$g(this.getMinutes());var n=$g(this.getSeconds());var i="".concat(e,":").concat(t,":").concat(n);var r=function(e){var t=e<=0?"+":"-";var n=Math.abs(e);var i=$g(Math.floor(n/60));var r=$g(n%60);return"GMT".concat(t).concat(i).concat(r)}(this.timezoneOffset);var o=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=Ng(e,t),i=n.zone,r=n.rule;var 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);var s=$g(a,2);var l=a>0?"+":"";var c=Math.abs(Math.trunc(i[0]%60));var d=0===c?"":$g(c,2);return o.replace("%z","".concat(l).concat(s).concat(d))}return o}(this.timezone,this._utcDate);return o&&(o=" (".concat(o,")")),"".concat(i," ").concat(r).concat(o)},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 Xg=function(e,t){return Xg=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])},Xg(e,t)};function Zg(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}Xg(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Jg=function(){return Jg=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},Jg.apply(this,arguments)};Object.create;Object.create;"function"==typeof SuppressedError&&SuppressedError;var ev=function(){this.symbols="",this.partMap=[]};var tv="_",nv=68,iv="d",rv="en";var ov="Delete",av="Backspace",sv=" ";var lv=function(e){return new Array(Math.max(e,0)).fill("0").join("")};var cv=function(e){return e.replace(/^0*/,"")};var dv=function(e,t){return e[t.pattern[0]]=t.type,e};var hv=function(e){return null!=e};var uv=function(){return!!document};var pv=function(e){return hv(e)&&"number"==typeof e&&!Number.isNaN(e)};var fv=function(e){return parseInt(e,10)};var mv=function(e){return pv(fv(e))&&/^[0-9]+$/.test(e)};var gv=function(e,t,n){return Math.min(n,Math.max(t,e))};var vv=function(){var e=[];for(var t=0;t<arguments.length;t++)e[t]=arguments[t];return Object.assign.apply(Object,e)};var _v=(bv="setFullYear",function(e,t){var n=bg(e);return n[bv](t),n});var bv;var wv=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)};var yv=function(e){return hv(e)&&e.getTime&&pv(e.getTime())};var kv=/d|M|H|h|m|s/;var xv=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?nv:a,l=e.value,c=void 0===l?null:l,d=e.autoCorrectParts,h=void 0===d||d,u=e.toggleDayPeriod,p=void 0!==u&&u,f=e.autoSwitchParts,m=void 0===f||f;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:h,toggleDayPeriod:p,autoSwitchParts:m}),c)this._value=bg(c);else{this._value=this.getDefaultDate();var g=this.dateFormatString(this.value,this.format).symbols;for(var v=0;v<g.length;v++)this.setExisting(g[v],!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:!1,configurable:!0}),Object.defineProperty(e.prototype,"localeId",{get:function(){var e=rv;var t=Object.keys(this.intl.cldr);for(var n=0;n<t.length;n++){var i=t[n];var r=this.intl.cldr[i];if(r.name&&r.calendar&&r.numbers&&r.name!==rv){e=r.name;break}}return e},enumerable:!1,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,this.toggleDayPeriod=e.toggleDayPeriod,this.autoSwitchParts=e.autoSwitchParts},e.prototype.setValue=function(e){e?Eg(e,this._value)?Eg(e,this._value)&&this.dayPeriods&&this.setExisting("a",!0):(this._value=bg(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 bg(this.value)},e.prototype.createDefaultDate=function(){return kg(2e3,0,31)},e.prototype.getDefaultDate=function(){return Dg(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;var n=this.intl.formatDate(this.value,t,this.localeId);var i=this.dateFormatString(this.value,t);if(!this.autoCorrectParts&&this._partiallyInvalidDate.startDate){var r="";var o=this.intl.formatDate(this.value,t,this.localeId);var a=this.getFormattedInvalidDates(t);for(var 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=(fv(this.getInvalidDatePartValue(l))+1).toString();if(c.length>2)r+=a[l][s];else if(this.getInvalidDatePartValue(l))r+=lv(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+=lv(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;var 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){var t=this.dateFormatString(this.value,this.format).symbols;for(var 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(hv(e)&&hv(t)&&0!==t){var n=bg(this.value);var i=!1;var r;var o="M"===e;var a="d"===e||"E"===e;var s=this.getExisting(e);if(this.autoCorrectParts||!a&&!o){var l=n.getHours();switch(e){case"y":n.setFullYear(n.getFullYear()+t);break;case"M":n=Cg(this.value,t);break;case"d":case"E":n.setDate(n.getDate()+t);break;case"h":case"H":n.setHours(n.getHours()+t),i=!0;break;case"m":n.setMinutes(n.getMinutes()+t),i=!0;break;case"s":n.setSeconds(n.getSeconds()+t),i=!0;break;case"S":n.setMilliseconds(n.getMilliseconds()+t);break;case"a":this.toggleDayPeriod?n.setHours(l>=12?l-12:l+12):n.setHours(n.getHours()+12*t),i=!0}}else{var c=this._partiallyInvalidDate.invalidDateParts||{};var d=this.getInvalidDatePartValue(e);var h=c.y.value||n.getFullYear();var u=c.M.value||n.getMonth();var p=c.d.value||c.E.value||n.getDate();var f=c.h.value||c.H.value||n.getHours();var m=c.m.value||n.getMinutes();var g=c.s.value||n.getSeconds();var v=c.S.value||n.getMilliseconds();switch(e){case"y":h+=t;break;case"M":u+=t;break;case"d":case"E":p+=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=gv(u%11+1+11,0,11);else{var _=hv(d)?u:(t-1)%12;u=gv(_,0,11)}u=gv(u,0,11)}u=gv(u,0,11)}else if("d"===e)if(s){if(p<=0||p>31)return this.setExisting(e,!1),void this.resetInvalidDateSymbol(e)}else if(!s){if(hv(d)&&(p<=0||p>31))return this.setExisting(e,!1),void this.resetInvalidDateSymbol(e);if(t<0){var b=hv(d)?p:31-Math.abs(t%31)+1;p=gv(b,1,31)}else{b=hv(d)?p:t%31;p=gv(b,1,31)}p=gv(p,1,31)}var w=kg(h,u,p,f,m,g,v);var y=o||a?this.modifyDateSymbolWithValue(n,e,o?u:p):null;var k=wv(w,h,u,p,f,m,g,v);this.getValue()&&wv(w,h,u,p,f,m,g,v)?(n=bg(w),this.markDatePartsAsExisting()):o&&y?y.getMonth()===u?this.getExisting("d")?k?(n=bg(w),this.resetInvalidDateSymbol(e)):(r=!0,this.setInvalidDatePart(e,{value:u,date:bg(y),startDateOffset:t,startDate:bg(this.value)}),this.setExisting(e,!1)):k?(this.resetInvalidDateSymbol(e),n=bg(w),this.getExisting("M")&&this.getExisting("y")&&(this.setExisting("d",!0),this.resetInvalidDateSymbol("d"))):(this.resetInvalidDateSymbol(e),n=bg(y)):(r=!0,this.setInvalidDatePart(e,{value:u,date:bg(y),startDateOffset:t,startDate:bg(this.value)}),this.setExisting(e,!1)):a&&y&&(y.getDate()===p?this.getExisting("M")?k?(n=bg(w),this.resetInvalidDateSymbol(e)):(r=!0,this.setInvalidDatePart(e,{value:p,date:bg(y),startDateOffset:t,startDate:bg(this.value)}),this.setExisting(e,!1)):k?(n=bg(w),this.resetInvalidDateSymbol(e),this.getExisting("d")&&this.getExisting("y")&&(this.setExisting("M",!0),this.resetInvalidDateSymbol("M"))):(this.resetInvalidDateSymbol(e),n=bg(y)):(r=!0,this.setInvalidDatePart(e,{value:p,date:bg(this.value),startDateOffset:t,startDate:bg(this.value)}),this.setExisting(e,!1)))}this.shouldNormalizeCentury()&&(n=this.normalizeCentury(n)),i&&!this.cycleTime&&(n.getDate(),this._value.getDate()),r||(this.setExisting(e,!0),this._value=n,this.getValue()&&this.resetInvalidDate())}},e.prototype.parsePart=function(e){var t=e.symbol,n=e.currentChar,i=e.resetSegmentValue,r=e.cycleSegmentValue,o=e.rawTextValue,a=e.isDeleting,s=e.originalFormat;var l=!r;var c=this.dateFormatString(this.value,this.format);var d=c.partMap.filter((function(e){return"literal"===e.type})).map((function(e,t){return{datePartIndex:t,type:e.type,pattern:e.pattern,literal:""}}));var h=c.partMap.map((function(e){return{type:e.type,pattern:e.pattern,text:""}}));for(var u=0;u<d.length;u++){var p=d[u];for(var f=0;f<p.pattern.length;f++)d[u+f]&&(d[u+f].literal=p.pattern[f]);u+=p.pattern.length-1}for(u=0;u<h.length;u++){p=h[u];for(f=0;f<p.pattern.length;f++)h[u+f]&&(h[u+f].text=p.pattern[f]);u+=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),vv(m,{value:null,switchToNext:!1});for(u=0;u<d.length;u++){var g=d[u].literal;var v=o.startsWith(g);var _=o.endsWith(g);var b=o.indexOf(g+g)>=0;if(v||_||b)return this.resetLeadingZero(),this.setExisting(t,!1),this.resetInvalidDateSymbol(t),vv(m,{value:null,switchToNext:!1})}}var w=this.intl.formatDate(this.value,this.format,this.localeId);var y=c.symbols;var k=!1;var x="";var C="";var S="";var T="";var M="";var A="";var D="";for(u=0;u<h.length;u++)D+=h[u].text;var E=this.format===y||this.format===D||this.format===s||this.format.length===s.length;var I=(E?D:s).indexOf(t);var z=(E?D:s).lastIndexOf(t)-I+1;var P=s.length-o.length;if(l||!l&&!this.autoCorrectParts){var L=0;for(u=0;u<w.length;u++)if(y[u]===t){var B=this.getExisting(t);if("y"===t)if(!this.hasInvalidDatePart()&&this.getExisting("y"))C+=w[u];else{var H=this.getInvalidDatePartValue(t);hv(H)?(C+=(H||"").toString()[L]||"",L++):C+=B?w[u]:"0"}else C+=B?w[u]:"0";P>0?S.length+P<z&&(S+=o[u]||""):S+=o[u]||"",k=!0}else k?(A+=w[u],M+=w[u]):(x+=w[u],T+=w[u]);if(E&&(D.length<o.length?S+=n:!a&&(s.length,o.length),S.length>z))return vv(m,{value:null,switchToNext:!1});if(!E||E&&!this.autoCorrectParts){C="",S="",x="",A="",k=!1;var R=0;for(u=0;u<s.length;u++)if(s[u]===t){B=this.getExisting(t);if("y"===t)if(!this.hasInvalidDatePart()&&this.getExisting("y"))C+=w[u];else{H=this.getInvalidDatePartValue(t);hv(H)?(C+=(H||"").toString()[R]||"",R++):C+=B?w[u]:"0"}else C+=B?w[u]||"":"0";P>0?S.length+P<z&&(S+=o[u]||""):S+=o[u]||"",k=!0}else k?A+=o[u-P]||"":x+=o[u]||"";s.length<o.length&&(S+=n)}}if(!l)if(this.autoCorrectParts){C="",S="",x="",A="",k=!1;for(u=0;u<w.length;u++){if(y[u]===t)C+=(B=this.getExisting(t))?w[u]:"0",k=!0;else k?A+=w[u]:x+=w[u]}}else C=i?S:C;var F=null;var O=this.matchMonth(n);var V=this.matchDayPeriod(n,t);var N="0"===n;var $=this.leadingZero||{};N?("0"===S&&(S=C),0!==fv(i?n:(l?S:C)+n)||this.isAbbrMonth(c.partMap,t)||"a"===t||this.incrementLeadingZero(t)):this.resetLeadingZero();var U=this.partPattern(c.partMap,t);var W=U?U.pattern:null;var j=this.patternLength(W)||W.length;if(l&&a&&!S)return this.setExisting(t,!1),vv(m,{value:null,switchToNext:!1});var q=C.length-3;var G=!0;var K=l?S:C;for(u=Math.max(0,q);u<=C.length&&G;u++){K=i?n:l?S:C.substring(u)+n,this.autoSwitchParts&&"h"===t&&"12"===C.substring(u)&&(K=K.replace("12","0")),!l&&this.autoCorrectParts||(G=!1,K=cv(K),K=lv(j-K.length)+K);var Y=parseInt(K,10);var Q=x+K+A;(F=this.intl.parseDate(Q,this.format,this.localeId))&&this.value&&c.partMap.every((function(e){return"year"!==e.type&&"month"!==e.type&&"day"!=e.type}))&&(F.setFullYear(this.value.getFullYear()),F.setMonth(this.value.getMonth()),F.setDate(this.value.getDate()));var X=!1;l&&!yv(F)&&this.autoCorrectParts&&(F=this.intl.parseDate(T+K+M,this.format,this.localeId),X=!0);var Z=!isNaN(parseInt(n,10))||l&&a&&""===n;if(!F&&!isNaN(Y)&&Z&&this.autoCorrectParts){if("M"===t&&!O){var J=Y-1;J>-1&&J<12&&((F=bg(this.value)).setMonth(J),F.getMonth()!==J&&(F=xg(Cg(F,-1))))}"y"===t&&(F=kg(parseInt(K,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&&yv(F)||!l&&F)&&this.date&&F.getDate()!==this.value.getDate()&&(F=xg(Cg(F,-1))))}if(l&&yv(F)||!l&&F){var ee=this.isPeekDateOverflowingDatePart({useBasePrefixAndSuffix:X,middle:K,patternValue:W,basePrefix:T,baseSuffix:M,prefix:x,suffix:A,symbol:t,patternLength:j,leadingZero:$});var te=ee.switchToNext;return this.shouldNormalizeCentury()&&(F=this.normalizeCentury(F)),"H"===t&&F.getHours()>=12&&this.setExisting("a",!0),this._value=F,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")):"y"===t&&this.markDatePartsAsExisting(),this.hasInvalidDatePart()||(this.markDatePartsAsExisting(),ee.peekedDate||!ee.switchToNext||this.autoCorrectParts||"M"===t||"d"===t&&30===ee.parsedPeekedValue&&1===this.value.getMonth()&&(te=!1))),vv(m,{value:this.value,switchToNext:te})}}if(O&&(F=this.intl.parseDate(x+O+A,this.format,this.localeId)))return this._value=F,this.setExisting(t,!0),vv(m,{value:this.value,switchToNext:!1});if(V&&(F=this.intl.parseDate(x+V+A,this.format)||this.intl.parseDate(T+V+M,this.format)))return this._value=F,this.setExisting(t,!0),vv(m,{value:this.value,switchToNext:!0});if(N&&"a"!==t&&this.setExisting(t,!1),!this.autoCorrectParts){var ne=void 0;var ie=l?S:K;var re=fv(ie);if(pv(re)&&mv(ie)){if("d"===t&&(re<=0||re>31)||"M"===t&&(re<=0||re>11)){if(l)return vv(m,{value:null,switchToNext:!1});re=fv(ie=n)}if(!pv(re)||!mv(ie))return vv(m,{value:null,switchToNext:!1});ne="M"===t?re-1:re;var oe="y"===t;var ae="M"===t;var se="d"===t;var le=bg(this._value);var ce=this._partiallyInvalidDate.invalidDateParts||{};var de=oe?ne:ce.y.value||le.getFullYear();var he=ae?ne:ce.M.value||le.getMonth();var ue=se?ne:ce.d.value||ce.E.value||le.getDate();var pe=ce.h.value||ce.H.value||le.getHours();var fe=ce.m.value||le.getMinutes();var me=ce.s.value||le.getSeconds();var ge=ce.S.value||le.getMilliseconds();var ve=kg(de,he,ue,pe,fe,me,ge);var _e=wv(ve,de,he,ue,pe,fe,me,ge);var be=oe||ae||se?this.modifyDateSymbolWithValue(le,t,oe?de:ae?he:ue):null;var we=!1;if(ae&&be?be.getMonth()===he?this.getExisting("d")?_e?(le=bg(ve),this.resetInvalidDateSymbol(t)):(we=!0,this.setInvalidDatePart(t,{value:he,date:bg(be),startDate:bg(this.value)}),this.setExisting(t,!1)):_e?(this.resetInvalidDateSymbol(t),le=bg(ve),this.getExisting("M")&&this.getExisting("y")&&(this.setExisting("d",!0),this.resetInvalidDateSymbol("d"))):(this.resetInvalidDateSymbol(t),le=bg(be)):(we=!0,this.setInvalidDatePart(t,{value:he,date:bg(be),startDate:bg(this.value)}),this.setExisting(t,!1)):se&&be?be.getDate()===ue?this.getExisting("M")?_e?(le=bg(ve),this.resetInvalidDateSymbol(t)):(we=!0,this.setInvalidDatePart(t,{value:ue,date:bg(be),startDate:bg(this.value)}),this.setExisting(t,!1)):_e?(le=bg(ve),this.resetInvalidDateSymbol(t),this.getExisting("d")&&this.getExisting("y")&&(this.setExisting("M",!0),this.resetInvalidDateSymbol("M"))):(this.resetInvalidDateSymbol(t),le=bg(be)):(we=!0,this.setInvalidDatePart(t,{value:ue,date:bg(this.value),startDate:bg(this.value)}),this.setExisting(t,!1)):oe&&be&&(be.getFullYear()===de?this.getExisting("d")&&this.getExisting("M")?_e?(le=bg(ve),this.resetInvalidDateSymbol(t)):(we=!0,this.setInvalidDatePart(t,{value:de,date:bg(be),startDate:bg(this.value)}),this.setExisting(t,!1)):_e?(this.resetInvalidDateSymbol(t),le=bg(ve),this.getExisting("M")&&this.getExisting("d")&&(this.setExisting("y",!0),this.resetInvalidDateSymbol("y"))):(this.resetInvalidDateSymbol(t),le=bg(be)):(we=!0,this.setInvalidDatePart(t,{value:de,date:bg(be),startDate:bg(this.value)}),this.setExisting(t,!1))),!we){if(this.setExisting(t,!0),l&&!yv(F)){var ye=this.intl.parseDate(T+K+M,this.format,this.localeId);yv(ye)&&(this._value=ye)}else this._value=le;this.getValue()&&this.resetInvalidDate()}te=!1;if("M"===t)te=re>=2||ie.length>=2;else if(E)te=this.isPeekDateOverflowingDatePart({useBasePrefixAndSuffix:!this.autoCorrectParts,middle:K,patternValue:W,basePrefix:T,baseSuffix:M,prefix:x,suffix:A,symbol:t,patternLength:j,leadingZero:$}).switchToNext;else te=ie.length>z;return vv(m,{value:null,switchToNext:te,hasInvalidDatePart:we})}}return vv(m,{value:null,switchToNext:!1})},e.prototype.symbolMap=function(e){return this.intl.splitDateFormat(this.format,this.localeId).reduce(dv,{})[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(!hv(e))return e;var t=function(e){return!hv(e)||isNaN(e.getTime())?0:Number(e.getFullYear().toString().slice(-2))}(e);var n=this.getNormalizedCenturyBase(t);return _v(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 lv(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");var t=this.intl.splitDateFormat(this.format,this.localeId);for(var 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");var t=this.intl.splitDateFormat(this.format);for(var 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:kv.test(e)?2:0},e.prototype.dateFormatString=function(e,t){var n=this.intl.splitDateFormat(t,this.localeId);var i=[];var r=[];for(var o=0;o<n.length;o++){var a=this.intl.formatDate(e,{pattern:n[o].pattern},this.localeId).length;for(;a>0;)i.push(this.symbols[n[o].pattern[0]]||tv),r.push(n[o]),a--}var s=new ev;return s.symbols=i.join(""),s.partMap=r,s},e.prototype.merge=function(e,t){var n="";var i="";var r=t.symbols;var o=!1;var a=0;var s=this.getFormattedInvalidDates(r);for(var 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];var h=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 u=this.getInvalidDatePartValue(d).toString();if("M"===d)if(u=(fv(this.getInvalidDatePartValue(d))+1).toString(),c.length>2)n=s[d][l]+n;else u=(fv(this.getInvalidDatePartValue(d))+1).toString(),n=lv(c.length-u.length)+u+n,h=c.length-1,a=u.length-c.length;else n=lv(c.length-u.length)+u+n,h=c.length-1,a=u.length-c.length}else n=this.dateFieldName(t.partMap[l])+n;for(;i.length<n.length;)i=r[l]+i;0!==h&&(l=l-h+(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]&&hv(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;var t=!1;return Object.keys(this._partiallyInvalidDate.invalidDateParts).forEach((function(n){e._partiallyInvalidDate.invalidDateParts[n]&&hv(e._partiallyInvalidDate.invalidDateParts[n].value)&&(t=!0)})),t},e.prototype.modifyDateSymbolWithOffset=function(e,t,n){var i=bg(e);var r=!1;switch(t){case"y":i.setFullYear(i.getFullYear()+n);break;case"M":i=Cg(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=bg(e);switch(t){case"y":i.setFullYear(n);break;case"M":i=Cg(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){var n=e.partMap[t];var i=[];for(var 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;var h=this.peek(n,i);var u=t?"".concat(r).concat(h).concat(o):"".concat(a).concat(h).concat(s);var p=this.intl.parseDate(u,this.format,this.localeId);var f=((this.leadingZero||{})[l]||0)+cv(n).length>=c;return{peekedDate:p,peekedDateString:u,peekedValue:h,parsedPeekedValue:fv(h),switchToNext:null===p||(d[l]?i.length<=n.length:f)}},e}();var Cv=8,Sv=46,Tv=9,Mv=13,Av=37,Dv=38,Ev=39,Iv=40,zv=35,Pv=36;var Lv={events:{}};var Bv=function(){function e(e){this.options=vv({},Lv,e)}return e.prototype.destroy=function(){this.options={}},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](vv(n,t,{sender:this})),n.defaultPrevented)},e}();var Hv;var Rv;!function(e){e.None="none",e.Caret="caret",e.Selection="selection"}(Hv||(Hv={}));var Fv="dragStart";var Ov="drop";var Vv="touchstart";var Nv="mousedown";var $v="mouseup";var Uv="click";var Wv="input";var jv="keydown";var qv="focus";var Gv="blur";var Kv="paste";var Yv="DOMMouseScroll";var Qv="mousewheel";var Xv="valueChange";var Zv="inputEnd";var Jv="blurEnd";var e_="focusEnd";var t_="change";var n_={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:(Rv={},Rv[Xv]=null,Rv[Wv]=null,Rv[Zv]=null,Rv[qv]=null,Rv[e_]=null,Rv[Gv]=null,Rv[Jv]=null,Rv[jv]=null,Rv[Qv]=null,Rv[t_]=null,Rv),selectNearestSegmentOnFocus:!1,selectPreviousSegmentOnBackspace:!1,enableMouseWheel:!1,allowCaretMode:!1,autoSwitchParts:!0,autoSwitchKeys:[],twoDigitYearMax:nv,autoCorrectParts:!0,autoFill:!1,toggleDayPeriod:!1};var i_=function(e){function t(t,n){var i=e.call(this,n)||this;return i.dateObject=null,i.currentText="",i.currentFormat="",i.interactionMode=Hv.None,i.previousElementSelection={start:0,end:0},i.init(t,n),i}return Zg(t,e),Object.defineProperty(t.prototype,"value",{get:function(){return this.dateObject&&this.dateObject.getValue()},enumerable:!1,configurable:!0}),t.prototype.init=function(e,t){var n=yv(this.options.value)?bg(this.options.value):new Date(t.formattedValue);yv(n)||(n=null),this.element=e,this.options=vv({},n_,t,{steps:Jg(Jg({},n_.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=Hv.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(Fv,this.onElementDragStart),this.onElementDrop=this.onElementDrop.bind(this),this.element.addEventListener(Ov,this.onElementDrop),this.onElementClick=this.onElementClick.bind(this),this.element.addEventListener(Uv,this.onElementClick),this.onElementMouseDown=this.onElementMouseDown.bind(this),this.element.addEventListener(Nv,this.onElementMouseDown),this.element.addEventListener(Vv,this.onElementMouseDown),this.onElementMouseUp=this.onElementMouseUp.bind(this),this.element.addEventListener($v,this.onElementMouseUp),this.onElementInput=this.onElementInput.bind(this),this.element.addEventListener(Wv,this.onElementInput),this.onElementKeyDown=this.onElementKeyDown.bind(this),this.element.addEventListener(jv,this.onElementKeyDown),this.onElementFocus=this.onElementFocus.bind(this),this.element.addEventListener(qv,this.onElementFocus),this.onElementBlur=this.onElementBlur.bind(this),this.element.addEventListener(Gv,this.onElementBlur),this.onElementChange=this.onElementChange.bind(this),this.element.addEventListener(t_,this.onElementChange),this.onElementPaste=this.onElementPaste.bind(this),this.element.addEventListener(Kv,this.onElementPaste),this.onElementMouseWheel=this.onElementMouseWheel.bind(this),this.element.addEventListener(Yv,this.onElementMouseWheel),this.element.addEventListener(Qv,this.onElementMouseWheel)},t.prototype.unbindEvents=function(){this.element.removeEventListener(Fv,this.onElementDragStart),this.element.removeEventListener(Ov,this.onElementDrop),this.element.removeEventListener(Vv,this.onElementMouseDown),this.element.removeEventListener(Nv,this.onElementMouseDown),this.element.removeEventListener($v,this.onElementMouseUp),this.element.removeEventListener(Uv,this.onElementClick),this.element.removeEventListener(Wv,this.onElementInput),this.element.removeEventListener(jv,this.onElementKeyDown),this.element.removeEventListener(qv,this.onElementFocus),this.element.removeEventListener(Gv,this.onElementBlur),this.element.removeEventListener(t_,this.onElementChange),this.element.removeEventListener(Kv,this.onElementPaste),this.element.removeEventListener(Yv,this.onElementMouseWheel),this.element.removeEventListener(Qv,this.onElementMouseWheel)},t.prototype.setOptions=function(e,t){void 0===t&&(t=!1),this.options=vv({},this.options,e,{steps:Jg(Jg({},n_.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===Hv.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;var i=hv(this.options.placeholder)&&!this.dateObject.hasValue()&&!this.focusedPriorToMouseDown;var 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||{};var r=i.keyCode===Cv||i.key===av;var o=i.keyCode===Sv||i.key===ov;var a=this.interactionMode;!this.options.allowCaretMode||a===Hv.Caret||o||r||(this.resetSegmentValue=!0),this.options.allowCaretMode?this.interactionMode=Hv.Caret:this.interactionMode=Hv.Selection;var s=this.isInCaretMode();if(s&&this.keyDownEvent.key===sv)this.restorePreviousInputEventState();else{var l=this.dateObject&&this.dateObject.getValue();var c=this.dateObject?this.dateObject.value:null;var d=this.dateObject.getTextAndFormat(),h=d.text,u=d.format;this.currentFormat=u;var p=function(e){var t=e.oldText,n=e.newText,i=e.formatPattern,r=e.selectionStart,o=e.isInCaretMode,a=e.keyEvent;var s=r+t.length-n.length;var l=t[s];var c=t.substring(0,s);var d=n.substring(0,r);var h=[];if(c===d&&r>0)return h.push([i[r-1],d[r-1]]),h;if(0===c.indexOf(d)&&o&&(a.key===ov||a.key===av)||0===c.indexOf(d)&&!o&&(0===d.length||i[d.length-1]!==i[d.length])){var u="";o||1!==d.length||h.push([i[0],d[0]]);for(var p=d.length;p<c.length;p++)i[p]!==u&&i[p]!==tv&&(u=i[p],h.push([u,""]));return h}if(o&&(0===d.indexOf(c)||i[r-1]===tv)||!o&&(0===d.indexOf(c)||i[r-1]===tv)){var f=i[0];for(p=Math.max(0,c.length-1);p<i.length;p++)if(i[p]!==tv){f=i[p];break}return[[f,d[r-1]]]}return" "===d[d.length-1]||d[d.length-1]===l&&"_"===i[s]?[[i[r-1],tv]]:[[i[r-1],d[r-1]]]}({oldText:s&&(r||o||a===Hv.Caret)?this.previousElementValue:h,newText:this.elementValue,formatPattern:this.currentFormat,selectionStart:this.selection.start,isInCaretMode:s,keyEvent:this.keyDownEvent});if(p&&p.length&&p[0]&&p[0][1]!==tv&&(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]===tv||p[0][1]===tv))return void this.restorePreviousInputEventState()}var f=1===p.length&&p[0][1]===tv;var m=[];var g=!1;var 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 w=this.options.format===this.currentFormat||hv(this.options.format)&&this.options.format.length>1;var y=m[m.length-1];var k=y&&!hv(y.value);var x=s&&(r||o)&&k;var C=!!y&&y.resetPart;var S=this.dateObject.getValue();var T=!Eg(l,S);var M=this.dateObject.value;var A;var D=this.selection;if(s){var E=p&&p.length>0?p[0][0]:null;var I=this.dateObject.getLeadingZero()[E];p.length&&p[0][0]!==tv?g?(this.forceUpdateWithSelection(),this.switchDateSegment(1)):C?(A=this.currentFormat[D.start])?(this.forceUpdate(),this.setSelection(this.selectionBySymbol(A))):this.restorePreviousInputEventState():x?(this.forceUpdate(),p.length&&p[0][0]!==tv&&this.setSelection(this.selectionBySymbol(p[0][0]))):k?"0"===e.data&&I||(hv(l)&&!hv(S)?this.restorePreviousInputEventState():!hv(l)&&hv(S)?this.forceUpdateWithSelection():hv(l)&&hv(S)?T?this.forceUpdateWithSelection():this.restorePreviousInputEventState():hv(l)||hv(S)?c!==M||this.restorePreviousInputEventState():this.forceUpdateWithSelection()):k||w||this.forceUpdateWithSelection():(this.options.autoSwitchParts||p[0][1]!==tv)&&this.setSelection(this.selectionBySymbol(p[0][0]))}else s||(this.forceUpdate(),p.length&&p[0][0]!==tv&&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):y&&y.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=Hv.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=Hv.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;var r=e;if(this.keyDownEvent=e,this.previousElementValue=this.element.value,this.previousElementSelection={start:n,end:i},this.keyEventMatchesAutoSwitchKeys(e)){var o=e.keyCode===Tv;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];var d=this.getStepFromSymbol(c);var h=!1;var u=this.elementValue;if(!(e.altKey||e.ctrlKey||e.metaKey||e.keyCode===Tv)){switch(e.keyCode){case Av:this.switchDateSegment(-1),h=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Dv:this.modifyDateSegmentValue(d,c,r),u!==this.elementValue&&this.triggerInputEnd({event:e,error:null,newElementValue:this.elementValue,oldElementValue:u}),h=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Ev:this.switchDateSegment(1),h=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Iv:this.modifyDateSegmentValue(-d,c,r),u!==this.elementValue&&this.triggerInputEnd({event:e,error:null,newElementValue:this.elementValue,oldElementValue:u}),h=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Mv:break;case Pv:this.selectNearestSegment(0),h=!0,this.switchedPartOnPreviousKeyAction=!1,this.resetSegmentValue=!0;break;case zv:this.selectNearestSegment(this.elementValue.length),h=!0,this.switchedPartOnPreviousKeyAction=!1,this.resetSegmentValue=!0;break;default:return}h&&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(),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;hv(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:!1,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:iv},enumerable:!1,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:iv},enumerable:!1,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:!1,configurable:!0}),t.prototype.setSelection=function(e){this.element&&document.activeElement===this.element&&(this.element.setSelectionRange(e.start,e.end),uv()&&(/iPad|iPhone|iPod/.test(navigator.userAgent)||navigator.maxTouchPoints&&navigator.maxTouchPoints>2&&/Macintosh/i.test(navigator.userAgent))&&this.element.scrollIntoView({block:"nearest",inline:"nearest"}),e.start!==e.end&&(this.interactionMode=Hv.Selection))},t.prototype.selectionBySymbol=function(e){var t=-1;var n=0;for(var 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){var t={start:e,end:e};for(var n=e,i=e-1;n<this.currentFormat.length||i>=0;n++,i--){if(n<this.currentFormat.length&&this.currentFormat[n]!==tv){t=this.selectionBySymbol(this.currentFormat[n]);break}if(i>=0&&this.currentFormat[i]!==tv){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;var i=this.currentFormat[n-1];var r="";var o="";if(e<0){for(var a=n+e;a>=0;a--)if((o=this.currentFormat[a])!==tv&&o!==i){n=a,r=o;break}}else for(a=n+e;a<this.currentFormat.length;a++)if((o=this.currentFormat[a])!==tv&&o!==i){n=a,r=o;break}if(r)return this.forceUpdate(),this.setSelection(this.selectionBySymbol(r)),void(this.interactionMode=Hv.Selection)}this.interactionMode=Hv.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=Hv.None);var d=this.currentFormat[l];var h=l+e;for(;h>0&&h<this.currentFormat.length&&(this.currentFormat[h]===d||this.currentFormat[h]===tv);)h+=e;if(this.currentFormat[h]!==tv){var u=h;for(;u>=0&&u<this.currentFormat.length&&this.currentFormat[u]===this.currentFormat[h];)u+=e;h>u&&(u+1!==l||h+1!==c)?(this.setSelection({start:u+1,end:h+1}),this.resetSegmentValue=!0):h<u&&(h!==l||u!==c)&&(this.setSelection({start:h,end:u}),this.resetSegmentValue=!0),this.interactionMode=Hv.None}},t.prototype.modifyDateSegmentValue=function(e,t,n){if(void 0===t&&(t=""),void 0===n&&(n={}),this.dateObject&&!this.options.readonly){var i=this.value;var r=1;var o=this.caret();if("S"===(t=t||this.currentFormat[o[0]])&&(!this.options.steps.millisecond||1===this.options.steps.millisecond)){var a=function(e){var t=e&&e.match(/S+(\1)/);return t?t[0].length:0}(this.inputFormat);s=a,r=Math.pow(10,3-s)}var s;this.dateObject.modifyPart(t,r*e),this.tryTriggerValueChange({oldValue:i,event:n}),this.forceUpdate(),this.setSelection(this.selectionBySymbol(t))}},t.prototype.tryTriggerValueChange=function(e){if(void 0===e&&(e={oldValue:null,event:{}}),!Eg(this.value,e.oldValue))return this.triggerValueChange(e)},t.prototype.triggerValueChange=function(e){return void 0===e&&(e={oldValue:null,event:{}}),this.trigger(Xv,vv(e,{value:this.value}))},t.prototype.triggerInput=function(e){return void 0===e&&(e={event:{}}),this.trigger(Wv,vv(e,{value:this.value}))},t.prototype.triggerInputEnd=function(e){return void 0===e&&(e={event:{},error:null,oldElementValue:"",newElementValue:""}),this.trigger(Zv,vv(e,{value:this.value}))},t.prototype.triggerFocus=function(e){return void 0===e&&(e={event:{}}),this.trigger(qv,vv({},e))},t.prototype.triggerFocusEnd=function(e){return void 0===e&&(e={event:{}}),this.trigger(e_,vv({},e))},t.prototype.triggerBlur=function(e){return void 0===e&&(e={event:{}}),this.trigger(Gv,vv({},e))},t.prototype.triggerBlurEnd=function(e){return void 0===e&&(e={event:{}}),this.trigger(Jv,vv({},e))},t.prototype.triggerChange=function(e){return void 0===e&&(e={event:{}}),this.trigger(t_,vv(e,{value:this.value}))},t.prototype.triggerKeyDown=function(e){return void 0===e&&(e={event:{}}),this.trigger(jv,vv({},e))},t.prototype.triggerMouseWheel=function(e){return void 0===e&&(e={event:{}}),this.trigger(Qv,vv({},e))},t.prototype.forceUpdate=function(){this.setTextAndFormat(),this.refreshElementValue()},t.prototype.forceUpdateWithSelection=function(){var e=this.selection,t=e.start,n=e.end;var 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&&!yv(e))throw new Error("The 'value' should be a valid JavaScript Date instance.")},t.prototype.refreshElementValue=function(){var e=this.element;var t=this.isActive?this.inputFormat:this.displayFormat;var n=this.dateObject.getTextAndFormat(t),i=n.text,r=n.format;this.currentFormat=r,this.currentText=i;var o=this.options.hasPlaceholder||hv(this.options.placeholder);var a=!this.isActive&&o&&!this.dateObject.hasValue();o&&hv(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;var i=[e,e];var r=this.element;if(!n||!this.options.disabled&&!this.options.readonly){try{void 0!==r.selectionStart&&(n&&(uv()&&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){var t=-1;var n=0;for(var 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 xv(vv({},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,toggleDayPeriod:this.options.toggleDayPeriod,autoSwitchParts:this.options.autoSwitchParts}},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=this.dateObject;var t=new Date;var n,i,r,o,a,s;(e.date||e.month||e.year||e.hours||e.minutes||e.seconds)&&(r=e.year?e.value.getFullYear():t.getFullYear(),i=e.month?e.value.getMonth():t.getMonth(),n=e.date?e.value.getDate():t.getDate(),o=e.hours?e.value.getHours():t.getHours(),a=e.minutes?e.value.getMinutes():t.getMinutes(),s=e.seconds?e.value.getSeconds():t.getSeconds(),e.setValue(new Date(r,i,n,o,a,s)),this.refreshElementValue(),this.triggerValueChange())},t}(Bv);!function(e,t){var n=window.kendo;var i=n.ui;var r=i.Widget;var o=".kendoDateInput";var a={}.toString;var s=e.isPlainObject;var l="k-focus";var c="k-disabled";var d="k-invalid";var h="disabled";var u="readonly";var p="change";var 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),i.inputMode=i.inputMode||t.attr("inputmode")||"text";var s=t.parent().attr("class")||"";var c=s.indexOf("picker")>=0&&s.indexOf("rangepicker")<0;var 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 i_(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,toggleDayPeriod:i.toggleDayPeriod}),a._emptyMask=this.element.val(),i.value&&a.value(i.value),a.element.addClass("k-input-inner").attr("autocomplete","off").attr("inputmode",i.inputMode).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,toggleDayPeriod:!0},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 i_(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,toggleDayPeriod:t.options.toggleDayPeriod})},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;var i=t.options;var 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;var n=t.element;var i=e.disable;var r=e.readonly;var o=t.wrapper;t._unbindInput(),r||i?(i&&(o.addClass(c),n.attr(h,i),n&&n.length&&n[0].removeAttribute(u)),r&&n.attr(u,r)):(o.removeClass(c),n&&n.length&&(n[0].removeAttribute(h),n[0].removeAttribute(u)),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;var n=t.element;var i=n.attr("form");var r=i?e("#"+i):n.closest("form");var 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,h=n._activeElement,u="<div />",p=".kendoDatePicker",f="click"+p,m=c.mouseAndTouchPresent?n.applyEventMap("up",p.slice(1)):f,g="open",v="close",_="change",b="disabled",w="readonly",y="k-focus",k="k-selected",x="k-disabled",C="mouseenter"+p+" mouseleave"+p,S="mousedown"+p,T="navigate",M="id",A="month",D="aria-disabled",E="aria-readonly",I="aria-expanded",z="aria-hidden",P="aria-activedescendant",L=n.calendar,B=L.isInRange,H=L.restrictValue,R=L.isEqualDatePart,F=e.extend,O=Date;function V(t){var n=t.parseFormats,i=t.format;L.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(u).attr(z,"true").addClass("k-calendar-container");a.options=t=t||{},r=t.id;const c=t._buttons;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,F(t.popup,t,{name:"Popup",isRtl:n.support.isRtl(t.anchor)})):a.popup=new i.ActionSheet(l,{adaptive:!0,title:t.adaptiveTitle||"Set dates",subtitle:t.adaptiveSubtitle,closeButton:{icon:"check",themeColor:"primary"},actionButtons:c,focusOnActivate:!1,fullscreen:a.smallScreenMQL.mediaQueryList.matches,open:t.open,close:t.close,popup:F(t.popup,t,{name:"Popup",isRtl:n.support.isRtl(t.anchor)})})),r&&(r+="_dateview",l.attr(M,r),a._dateViewID=r),a.div=l,a.value(t.value)};$.prototype={_calendar:function(){var t=this;var r=t.calendar;var o=t.options;var a;if(!r){var s="auto"!=o.adaptiveMode||this.bigScreenMQL.mediaQueryList.matches?this.options.size:"large";a=e(u).attr(M,n.guid()).appendTo(o.omitPopup?o.dateDiv:t.popup._content||t.popup.element).on(S,N).on(f,"td:has(.k-link)",t._click.bind(t)),t.calendar=r=new i.Calendar(a,{componentType:o.componentType,size:s,messages:o.messages}),t._setOptions(o),a.addClass(n.getValidCssClass("k-calendar-","size",s)),r.navigate(t._value||t._current,o.start),t.value(t._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;var n=t.options;var i=e.disableDates;i&&(e.disableDates=L.disabled(i)),t.options=F(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=this;var t;e._calendar(),t=e.popup._hovered,e.popup._hovered=!0,e.popup.open(),setTimeout((function(){e.popup._hovered=t}),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(+H(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")),c.options.inputMode=r.inputMode||c.element.attr("inputmode")||"text",c.element.attr("inputmode",c.options.inputMode),V(r),c._initialOptions=F({},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,adaptiveTitle:null,adaptiveSubtitle:null},_createDateView:function(){var e,t=this,n=t.options,i=t.element;t.dateView&&(t.dateView.popup&&t.dateView.popup.wrapper&&t.dateView.popup.wrapper.remove(),t.dateView.destroy(),t.dateView=null),t.dateView=new $(F({},n,{id:i.attr(M),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;var 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(w,o).attr(D,a).attr(E,o)):(r.removeClass(x).on(C,t._toggleHover),i&&i.length&&(i[0].removeAttribute(b),i[0].removeAttribute(w)),i.attr(D,!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(y)})),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;var i=t.options;var 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(y)},_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]===h()||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;var 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&&R(c,o)?c=H(c,o,a):B(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,toggleDayPeriod:!0,inputMode:e.inputMode}))},_updateARIA:function(e){var t=this;var 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";var h=t.ui.Widget.extend({init:function(i,r){var o=this;var s;n.fn.init.call(this,i,r),r=o.options,o._element(i),o._wrapper(i),o._navigatable(),o.position(),o._mode(),r.mini&&o._miniMode(),o._initDrawerItems(),r.mini&&r.mode!=a&&o._setBodyOffset(),s=this.userEvents=new t.UserEvents(r.mode!=a?e(document.body):this.drawerContainer,{fastTap:!0,allowSelection:!0}),o.tap=function(t){e.contains(o.drawerItemsWrapper.filter("."+d)[0],t.event.target)&&o._itemClick(t),r.autoCollapse&&o.visible&&!o.trigger("hide",{sender:this})&&(o.hide(),t.preventDefault())},this.options.swipeToOpen?(s.bind("start",(function(e){o._start(e)})),s.bind("move",(function(e){o._update(e)})),s.bind("end",(function(e){o._end(e)})),s.bind("tap",o.tap)):s.bind("press",o.tap),r.minHeight&&r.mode==a&&o.drawerContainer.css("min-height",r.minHeight),o._showWatermarkOverlay&&o._showWatermarkOverlay(o.drawerContainer[0]),r.expanded&&(o._removeTransition(),o.show())},_element:function(){var t=this;var n=t.element;var 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;var 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;var o=t.guid();var 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=this;var i=!1;var r=n._current;var a;t.keyCode==o.UP&&(i=!0,(a=r.prevAll("[data-role='drawer-item']").first()).length?n._setCurrent(a):n._setCurrent(r.parent().find("[data-role='drawer-item']").last())),t.keyCode==o.DOWN&&(i=!0,(a=r.nextAll("[data-role='drawer-item']").first()).length?n._setCurrent(a):n._setCurrent(r.parent().find("[data-role='drawer-item']").first())),t.keyCode==o.HOME&&(i=!0,n._setCurrent(n.drawerItemsWrapper.find("[data-role='drawer-item']").eq(0))),t.keyCode==o.END&&(i=!0,n._setCurrent(n.drawerItemsWrapper.find("[data-role='drawer-item']").last())),t.keyCode!=o.SPACEBAR&&t.keyCode!=o.ENTER||(i=!0,n.tap({event:{target:r[0]},preventDefault:e.noop})),t.keyCode==o.ESC&&(i=!0,n.hide()),i&&t.preventDefault()},_wrapper:function(){var e=this.options;var t=this.drawerElement;var n=this.element;var i=this.contentElement;var r=this.drawerItemsWrapper=t;var o=this.drawerWrapper=r.wrapAll("<div class='k-drawer-wrapper'></div>").parent();var 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;var t=e.find("[data-role='drawer-item']");var 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=this.options;var n=this.drawerContainer;var i;t.mode==a?n.addClass("k-drawer-"+a):(n.addClass("k-drawer-"+s),(i=this.overlayContainer=e('<div class="k-overlay"></div>')).hide(),n.prepend(i))},_miniMode:function(){var t=this.options;var n=this.drawerContainer;var i=t.mini.width;var r=this._miniTemplate=t.mini.template;var o=this.drawerItemsWrapper;var 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;var t=this.drawerContainer;var n=this.options;var i=t.hasClass("k-drawer-expanded");var r=this._miniTemplate;var 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;var t=e.drawerWrapper;var n=e.drawerContainer;var i=this.options;var r=this.drawerItemsWrapper;var o=this._miniTemplate;var 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;var n=t.options;var 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;this.drawerWrapper;var i=this.drawerItemsWrapper;var 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;var n=this.options;var i=this.drawerWrapper.width()>n.width/2;var 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=this.options;var n=t.mini&&t.mini.width||this.minWidth||0;var i=this.drawerWrapper;var r;var o;o=i.width()+(this.leftPositioned?e.x.delta:-e.x.delta),r=Math.min(Math.max(o,n),t.width),e.event.preventDefault(),e.event.stopPropagation(),i.width(r)},_push:function(e){var t=this.options;var n=t.mini&&t.mini.width||this.minWidth||0;var i=this.drawerWrapper;var r;var o;o=i.width()+(this.leftPositioned?e.x.delta:-e.x.delta),r=Math.min(Math.max(o,n),t.width),e.event.preventDefault(),e.event.stopPropagation(),i.width(r)},_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=this;var i;e(t.event.target).find(".k-drawer-item").length>0?i=e(t.event.target).find(".k-drawer-item"):e(t.event.target).closest(".k-drawer-item").length>0?i=e(t.event.target).closest(".k-drawer-item"):e(t.event.target).hasClass(".k-drawer-item")&&(i=e(t.event.target)),n.drawerItemsWrapper.find(".k-drawer-item").removeClass("k-selected"),n._selectItem(i),n.options.navigatable&&n._setCurrent(i)},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(h)}(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,h=n.ui,u=h.Widget,p=h.Selectable,f=h.RangeSelectable,m=n.template,g=r.mobileOS,v=".kendoMultiViewCalendar",_="click",b="id",w="month",y=".",k=" ",x="century",C="change",S="navigate",T="value",M="k-focus",A="k-selected",D="k-hover",E="k-disabled",I="k-calendar-nav-today",z="k-empty",P="k-calendar-view",L="td:has(.k-link):not(."+z+"):not(.k-alt)",B="td:has(.k-link):not(."+E+"):not(."+z+"):not(.k-alt)",H="blur",R="focus",F=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=u.extend({init:function(t,r){var o=this;var a;var s;u.fn.init.call(o,t,r),t=o.wrapper=o.element,r=o.options,o.options.disableDates=i.disabled(o.options.disableDates),s=n.getCulture(r.culture),r.format=n._extractFormat(r.format||s.calendars.standard.patterns.d),o._templates(),o._header(),o._wrapper(),(a=t.addClass(`k-calendar k-calendar-range ${n.getValidCssClass("k-calendar-","size",o.options.size||"medium")}`+(r.weekNumber?" k-week-number":"")).on("keydown"+v,y+P,o._move.bind(o)).on(R+v,y+P,o._focus.bind(o)).on(H+v,y+P,o._blur.bind(o)).on(_+v,B,(function(t){var n=t.currentTarget.firstChild;-1!=e(n).data("href").indexOf("#")&&t.preventDefault(),o._click(e(n))})).attr(b))||(a=n.guid()),o._cellID=a+"_cell_selected",o._calendarWidth=o.element.width(),o._range=r.range,o._range&&o._range.start&&!o._range.end&&(o._range.target=U),o._initViews({viewName:r.start,value:r.value}),o._selectable(),o._footer(o.footer),o._selectDates=[],o.value(r.value),o._addSelectedCellsToArray(),o._isMultipleSelection()&&(o._selectDates=r.selectDates.length?r.selectDates:o._selectDates,o._restoreSelection()),o._isRangeSelection()&&o.selectRange(o._range),n.notify(o)},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:w,depth:w,messages:{weekColumnHeader:""},size:"medium",orientation:"horizontal"},events:[C,S],setOptions:function(e){var t=this;i.normalize(e),e.disableDates=i.disabled(e.disableDates),u.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,u.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;var o=r.options;var a=o.min;var 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===w&&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(y+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(y+z).length,s=[];1===t?o.children().filter(y+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,h=s.options,u=s._visibleRange(),p=h.culture,f=h.min,m=h.max;"decade"===l.name||l.name===x?(t=re(d,l.name,h.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,h.views-1),f,m,p)+"</span>"),i=l.name===x,c.toggleClass(E,i).attr(X,i),r=l.compare(u.start,s.options.min)<1,a=l.compare(u.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(D),s[N].toggleClass(E,a).attr(X,a),s[N].hasClass(E)&&s[N].removeClass(D))},_move:function(i){var r=this;var l=r.options;var c=i.keyCode;var h=r._index;var u=l.min;var p=l.max;var f=r.element.find(y+M);var m=f.closest(W);var g=new ee(+(r._current||a(f.find("span"))));var v=n.support.isRtl(r.wrapper);var _=!1;var b,k,x,T,D,I;if(c==d.RIGHT&&!v||c==d.LEFT&&v?(b=1,k=!0):c==d.LEFT&&!v||c==d.RIGHT&&v?(b=-1,k=!0):c==d.UP?(b=0===h?-7:-4,k=!0):c==d.DOWN?(b=0===h?7:4,k=!0):c==d.SPACEBAR?(b=0,k=!0):c==d.HOME?(k=!0,(x=m.find(B).eq(0)).hasClass(M)?(m=m.prev()).length?r._focusCell(m.find(B).eq(0)):(_=r[V]&&!r[V].hasClass(E),r._navigate(V,-1),r._focusCell(r.element.find(W).first().find(B).first())):r._focusCell(x)):c==d.END?(k=!0,(x=m.find(B).last()).hasClass(M)?(m=m.next()).length?r._focusCell(m.find(B).last()):(_=r[N]&&!r[N].hasClass(E),r._navigate(N,1),r._focusCell(r.element.find(W).last().find(B).last())):r._focusCell(x)):84===c&&(r._todayClick(i),k=!0),i.ctrlKey||i.metaKey)c==d.RIGHT&&!v||c==d.LEFT&&v?(_=r[N]&&!r[N].hasClass(E),r._navigate(N,1),k=!0):c==d.LEFT&&!v||c==d.RIGHT&&v?(_=r[V]&&!r[V].hasClass(E),r._navigate(V,-1),k=!0):c==d.UP?(_=!r._title.hasClass(E),r.navigateUp(),r._focusCell(r._cellByDate(r._current)),k=!0):c==d.DOWN?(r._currentView.name===w?r.value(g):(r.navigateDown(g),r._focusCell(r._cellByDate(r._current)),_=!0),k=!0):c!=d.ENTER&&c!=d.SPACEBAR||r._isMultipleSelection()&&r._toggleSelection(i);else if(i.shiftKey&&!r._isSingleSelection()){if(b!==t){if(r._currentView.setDate(g,b),r._currentView.name!==w)return;l.disableDates(g)&&(g=r._nextNavigatable(g,b)),u=s(u.getFullYear(),u.getMonth(),u.getDate()),o(g,u,p)&&(r._dateInViews(g)||(b>0?(_=r[N]&&!r[N].hasClass(E),r._navigate(N,1)):(_=r[V]&&!r[V].hasClass(E),r._navigate(V,-1))),x=r._cellByDate(g),r._current=g,r.selectable&&(r._selectRange(a((r.selectable._lastActive||f).find("span")),g),r.selectable._lastActive||(r.selectable._lastActive=f),r.trigger(C),r._focusCell(x)),r.rangeSelectable&&(T=a((r.rangeSelectable._lastActive||f).find("span")),r._dateInViews(T)?(r.rangeSelectable._end&&r.rangeSelectable._end.is(y+M)?r.rangeSelectable._lastActive=r.rangeSelectable._start:r.rangeSelectable._lastActive=r._cellByDate(T),r.rangeSelectable.range(r.rangeSelectable._lastActive,x)):+T>+g?(r.rangeSelectable._end=r.rangeSelectable._lastActive,r.rangeSelectable.selectFrom(x)):r.rangeSelectable.selectTo(x),r.rangeSelectable.change(),r._focusCell(x)))}}else c==d.ENTER||c==d.SPACEBAR?(r._currentView.name===w?(I=!f.hasClass(A)||r.element.find(y+A).length>1,r.value(g),r.selectable&&(r.selectable._lastActive=r._cellByDate(g),I&&r.selectable.trigger(C,{event:i})),r.rangeSelectable&&r.rangeSelectable.change()):r._click(e(r._cell[0].firstChild)),k=!0):c!=d.PAGEUP&&c!=d.PAGEDOWN||(k=!0,D=m.find(B).index(f),(m=c==d.PAGEUP?m.prev():m.next()).length||(c==d.PAGEUP?(_=r[V]&&!r[V].hasClass(E),r.navigateToPast(),m=r.element.find(W).first()):(_=r[N]&&!r[N].hasClass(E),r.navigateToFuture(),m=r.element.find(W).last())),(x=m.find(B).eq(D)).length?r._focusCell(x):r._focusCell(m.find(B).last())),b&&(r._currentView.setDate(g,b),u=s(u.getFullYear(),u.getMonth(),u.getDate()),o(g,u,p)&&(r.selectable&&l.disableDates(g)&&(g=r._nextNavigatable(g,b)),r._dateInViews(g)||(b>0?(_=r[N]&&!r[N].hasClass(E),r._navigate(N,1)):(_=r[V]&&!r[V].hasClass(E),r._navigate(N,-1))),x=r._cellByDate(g),r._current=g,r._focusCell(x)));return _&&r.trigger(S),k&&i.preventDefault(),r._current},_visualizeSelectedDatesInView:function(){var t=this;var i={};var r;e.each(t._selectDates,(function(e,t){i[n.calendar.views[0].toDateString(t)]=t})),t.selectable.clear(),r=t.element.find(W).find(L).filter((function(t,r){return i[e(r.firstChild).attr(n.attr(T))]})),r.length>0&&t.selectable._selectElement(r,!0)},_nextNavigatable:function(e,t){var n=this;var i=!0;var r=n._currentView;var a=n.options.min;var s=n.options.max;var l=n.options.disableDates;var 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;var o=r.options;var 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 "+B,cellSelector:L,cellSelectorValid:B,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 "+B,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(B)&&e.length>1&&this._focusCell(e.first(),!0)},_getFirstViewDate:function(e){var t=this;var n=t.options;var i=[];var r;var o;var a=new Date(+t._current);var s;for(s=0;s<n.views;s++){if(r=e.first(a),+(o=e.last(a))>+n.max){+r<=+n.max&&i.push({start:r,end:new Date(+n.max)});break}i.push({start:r,end:o}),a=new Date(+re(o,e.name,1))}for(a=new Date(+t._current),s=0;s<n.views;s++){if(r=e.first(a),o=e.last(a),+r<+n.min){+o>=+n.min&&i.push({start:new Date(+n.min),end:o});break}i.push({start:r,end:o}),a=new Date(+re(r,e.name,-1))}for(r=i[0].start,s=0;s<n.views+1&&i[s];s++)+r>+i[s].start&&(r=i[s].start);return new Date(+r)},_canRenderNextView:function(e){var t=e.getFullYear();var n=e.getMonth();var i=e.getDate();var r=this.options.max;var o=r.getFullYear();var 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=this;var r=n.options;var o=i.viewsEnum[t.viewName];var a=i.views[o];var s;n._current=new ee(+i.restrictValue(t.value,r.min,r.max)),n._views=[],n._index=o,(s=n._getFirstViewDate(a)).setDate(1),n._firstViewValue=new Date(+s);for(var l=0;l<r.views&&((s=l?re(s,a.name,1):s).setDate(1),n._canRenderNextView(s));l++)n._table=e(a.content(e.extend({min:r.min,max:r.max,date:s,url:r.url,dates:r.dates,format:r.format,culture:r.culture,disableDates:r.disableDates,showHeader:r.showViewHeader,isWeekColumnVisible:r.weekNumber,showOtherMonthDays:r.showOtherMonthDays,centuryCellsFormat:r.centuryCellsFormat,messages:r.messages,contentClasses:"k-calendar-table"},n[a.name]))),n._table.appendTo(n.tablesWrapper),n._views.push(n._table);n._currentView=a,n.tablesWrapper.attr("class","k-calendar-view k-calendar-"+a.name+`view ${"vertical"!=n.options.orientation?"k-hstack":"k-vstack"} k-align-items-start k-justify-content-center`),n._updateHeader(),n._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 "+B).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(M)&&e.preventDefault()},_visibleRange:function(){var e=this.element.find(y+P+k+W);return{start:a(e.first().find(L).first().find("span")),end:a(e.last().find(L).last().find("span"))}},_dateInViews:function(e){var t=this.element.find(y+P+k+W);var n=a(t.first().find(L).first().find("span"));var i=a(t.last().find(L).last().find("span"));if(e)return+(e=new Date(e.toDateString()))<=+i&&+e>=+n},_fillRange:function(e,t){var r=this;var o;r._selectDates=[],o=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());var 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)}}(r._selectDates,o,e,r.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=this;var i=t.element;var r;var o=i.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",t.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",t.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",t.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(i)),t.header=o,o.on(F+v+" "+O+" "+R+v+" "+H+v,".k-button",ie).on(_,(function(){return!1})).on(_+v,".k-button.k-calendar-title",t._calendarTitleClick.bind(t)).on(_+v,".k-button.k-calendar-nav-prev",t._prevViewClick.bind(t)).on(_+v,".k-button.k-calendar-nav-next",t._nextViewClick.bind(t)),r=o.find(".k-button"),t._title=r.filter(".k-calendar-title"),t._navContainer=o.find(".k-calendar-nav"),t[V]=r.filter(".k-calendar-nav-prev"),t[N]=r.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;var t=e.content;var i=e.weekNumber;var 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;var i=t.options;var r=!1!==i.footer?n.template(t.options.footer||(e=>n.toString(e,"D",i.culture)),{useWithBlock:!1}):null;var o=c();var a=t.element;var 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=this;var r=n._index+1;var o=new ee(+n._current);var a=new ee(+n._current);var s;e=n[e],s=n._cellByDate(o).closest(W).index(),t>0?s=1-s:s+=1,e&&e.hasClass(E)||(r>3?o.setFullYear(o.getFullYear()+t*s*100):i.views[r].setDate(o,t*s),n.navigate(o),n._dateInViews(a)?(n._focusCell(n._cellByDate(a)),n._current=a):(r>3?a.setFullYear(a.getFullYear()+100*t):i.views[r].setDate(a,t),n._focusCell(n._cellByDate(a)),n._current=a))},_toggle:function(e){var n=this;var i=n.options;var r="range"!==i.selectable&&n.options.disableDates(c());var 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;var r=t.options;var o=new Date(+t._current);var 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(M)},_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(B).first()),this._focusCell(t)},_focusCell:function(e){var t=this;var n=t._cellID;t._cell&&t._cell.length&&(t._cell[0].removeAttribute(Z),t._cell.removeClass(M),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(M),e.length&&t._currentView.name==w&&(t._current=a(e.find("span")))},_todayClick:function(e){var t=this;var n=t.options.disableDates;var i=c();var 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==w&&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;var r=i.options;var a=r.min;var 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=this;var r=i._cellByDate(t||i.current());var o=i.view().valueType();var a=t||i.current();var s;return i._focusCell(r),s=o===w?n.toString(a,"MMMM"):"date"===o?n.toString(a,"D"):r.text(),r.attr(Z,e({current:a,valueType:o,text:s})),r.attr(b)},clearSelection:function(){var e=this;e.selectable&&e.element.find(y+A).removeClass(A).removeAttr("aria-selected"),e.rangeSelectable&&e.rangeSelectable.clear(!0)},_restoreSelection:function(){var e=this;var t;if(e._currentView.name===e.options.depth){if(e._preventChange=!0,e._isRangeSelection()){if(!(t=e.selectRange())||!t.start)return void(e._preventChange=!1);e.selectRange(t)}e._isSingleSelection()&&e.value()&&e.selectable.value(e._cellByDate(e.value())),e._isMultipleSelection()&&e._visualizeSelectedDatesInView(),e._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=this;var i;if(e===t)return n._value;e=n._validateValue(e),n.clearSelection(),e&&!n._dateInViews(e)&&n.navigate(e),null!==e&&n._currentView.name===w&&(i=n._cellByDate(e),n.selectable&&n.selectable.value(i),n.rangeSelectable&&(n.rangeSelectable.start(i),n.rangeSelectable._lastActive=i))},selectDates:function(n){var i=this;var r;var o;if(n===t)return i._selectDates;o=n.map((function(e){return e.getTime()})).filter((function(e,t,n){return n.indexOf(e)===t})).map((function(e){return new Date(e)})),r=e.grep(o,(function(e){if(e)return+i._validateValue(new Date(e.setHours(0,0,0,0)))==+e})),i._selectDates=r.length>0?r:0===o.length?o:i._selectDates,i._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(B))}});function ie(t){e(this).hasClass("k-disabled")||e(this).toggleClass(D,F.indexOf(t.type)>-1||t.type==R)}function re(e,t,n){var r;return t===w?((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;!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,h=n.data.DataSource,u="aria-disabled",p="aria-readonly",f="change",m="disabled",g="readonly",v="k-focus",_="k-disabled",b=".kendoAutoComplete",w="mouseenter"+b+" mouseleave"+b;function y(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"),i.inputMode=i.inputMode||t.attr("inputmode")||"text",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(e){o._hasActionSheet()?o.element.attr("readonly",!0):o.options.readonly||o.element.removeAttr("readonly"),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,inputmode:i.inputMode}),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),Yu({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,adaptiveTitle:null,adaptiveTitleSubtitle: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._unboundClick=!0,e.element.on("click",(function(){e.popup.toggle()})),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=h.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(u,o).attr(p,r)):(i.removeClass(_).on(w,t._toggleHover),n.prop(m,!1).prop(g,!1).attr(u,!1).attr(p,!1)),t._toggleCloseVisibility()},close:function(){var e=this;var 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)[y(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(),h=i.element[0],u=o(h)[0],p=i._separator(),f=s.split(p),m=y(u,s,p),g=u,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):""),u<=0&&(u=(v?s.toLocaleLowerCase(v):s.toLowerCase()).indexOf(v?e.toLocaleLowerCase(v):e.toLowerCase())+1),n=(n=s.substring(0,u).lastIndexOf(i._defaultSeparator()))>-1?u-(n+i._defaultSeparator().length):u,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=u+(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||""));h===a()&&o(h,u,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;var n=this;var i=n.element;var 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=this;var n=e.popup;var i=e.options;var r=e.dataSource.flatView();var o=r.length;var s=e.dataSource._group?e.dataSource._group.length:0;var l=e.element[0]===a()||e.filterInput&&e.filterInput[0]===a();var c;e._renderFooter(),e._renderNoData(),e._toggleNoData(!o),e._toggleHeader(!!s&&!!o),e._resizePopup(),n.position(),o&&(i.suggest&&l&&e._inputValue()&&e.suggest(r[0]),e._highlightFirst()),e._open&&(e._open=!1,c=e._allowOpening()?"open":"close",e._typingTimeout&&!l&&(c="close"),o&&(e._resetFocusItem(),i.virtual&&e.popup.unbind("activate",e._resetFocusItemHandler).one("activate",e._resetFocusItemHandler)),n[c](),e._typingTimeout=t),e._touchScroller&&e._touchScroller.reset(),e._hideBusy(),e.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();var 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(y(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;var t=e._unifySeparators().value();var n=t!==c.unifyType(e._old,typeof t);var i=n&&!e._typing;var r=e._oldText!==t;var 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;var n=e.keyCode;var i=t.listView;var r=t.popup.visible();var 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;var n=t.ui;var i=e.extend;var r="visibility";var o="k-drag-status";var a=`<span class="${o}"></span>`;var 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=this.options;var o=this.source;var a=this.dropTarget=e(t.eventTarget(n));var l=a.closest(i.allowedContainers);var c,d,h,u,p;var f,m,g;var v,_,b;l.length?o[0]==a[0]||i.contains(o[0],a[0])||n.clickMoveClick&&n.currentTarget.hasClass("k-drag-cell")&&0===a.closest(".k-drag-cell").length||n.clickMoveClick&&n.currentTarget.hasClass("k-treeview-leaf")&&0===a.closest(".k-treeview-leaf").length?b="cancel":(b="insert-middle",(c=(v=i.itemFromTarget(a)).item).length?(this._removeTouchHover(),d=t._outerHeight(c),u=v.content,i.reorderable?(p=d/(u.length>0?4:2),h=t.getOffset(c).top,f=n.y.location<h+p,m=h+d-p<n.y.location,g=u.length&&!f&&!m):(g=!0,f=!1,m=!1),this.hovered=!!g&&l,this.dropHint.css(r,g?"hidden":"visible"),this._lastHover&&this._lastHover[0]!=u[0]&&this._lastHover.removeClass(s),this._lastHover=u.toggleClass(s,g),g?b="plus":((_=c.position()).top+=f?0:d,this.dropHint.css(_)[f?"prependTo":"appendTo"](i.dropHintContainer(c)),f&&v.first&&(b="insert-top"),m&&v.last&&(b="insert-bottom"))):a[0]!=this.dropHint[0]&&(this._lastHover&&this._lastHover.removeClass(s),b=e.contains(this.element[0],l[0])?"cancel":"plus")):(b="cancel",this._removeTouchHover()),this.options.drag({originalEvent:n.originalEvent,source:o,target:a,pageY:n.y.location,pageX:n.x.location,status:b,setStatus:function(e){b=e}}),0!==b.indexOf("insert")&&this.dropHint.css(r,"hidden"),this._hintStatus(b)},dragcancel:function(){this.dropHint&&this.dropHint.remove()},dragend:function(n){var i,o,a,l,c="over",d=this.source,h=this.dropHint,u=this.dropTarget||e(t.eventTarget(n));h&&"visible"==h.css(r)?(c=this.options.dropPositionFrom(h),i=h.closest(this.options.itemSelector),l=!0):u&&((i=u.closest(this.options.itemSelector)).length||(i=u.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:u[0],position:c},a=this.options.drop(o),h.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;var 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}});var 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"]}});var 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,h=s.sanitizeLink,u=e.extend,p=s.template,f=Array.isArray,m=l.Widget,g=c.HierarchicalDataSource,v=s.keys,_=".kendoTreeView",b=".kendoTreeViewTemp",w="select",y="check",k="navigate",x="change",C="error",S="checked",T="indeterminate",M="dragstart",A="progress",D="drag",E="drop",I="dragend",z="dataBound",P="itemsLoaded",L="loadCompleted",B="requestEnd",H="click",R="undefined",F="k-hover",O="k-treeview",V=".k-treeview-item",N="k-icon",$="<span></span>",U="string",W="aria-checked",j="aria-selected",q="aria-disabled",G="aria-expanded",K="aria-activedescendant",Y="aria-busy",Q="k-disabled",X={text:"dataTextField",url:"dataUrlField",spriteCssClass:"dataSpriteCssClassField",imageUrl:"dataImageUrlField",attr:"dataAttrField",imageAttr:"dataImageAttrField",contentAttr:"dataContentAttrField",linkAttr:"dataLinkAttrField"},Z=function(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&1===e.nodeType&&typeof e.nodeName===U};const J="k-treeview-item",ee="k-image",te="k-treeview-leaf-text";function ne(e){return function(t){var n=t.children(".k-animation-container");return n.length||(n=t),n.children(e)}}function ie(e){return e.find(".k-checkbox-wrap:first input[type=checkbox]")}function re(e){return function(t,n){var i,r=(n=n.closest(V)).parent();return r.parent().is("li")&&(i=r.parent()),this._dataSourceMove(t,r,i,(function(t,i){var r=this.dataItem(n);var o=r&&n.parent().children().length!==r.parent().length?r.parent().indexOf(r):n.index();return this._insert(t.data(),i,o+e)}))}}function oe(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'>${$}</span>`).prependTo(n):i.length&&i.children().length||(r.parent().remove(),i.remove(),t.removeAttr(G)),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){var n;for(;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=ne(".k-treeview-group"),r=ne(".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;f(t)&&(t={dataSource:t}),t&&typeof t.loadOnDemand==R&&f(t.dataSource)&&(t.loadOnDemand=!1),m.prototype.init.call(r,e,t),e=r.element,t=r.options,r._dataSourceUids={},i=e.is("ul")&&e||e.hasClass(O)&&e.children("ul"),(n=!o&&i.length)&&(t.dataSource.list=i),r._animation(),r._accessors(),r._templates(),e.hasClass(O)?(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(A,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+_,".k-treeview-leaf.k-selected",(function(e){e.preventDefault()})).on(i+_,n,(function(){e(this).addClass(F)})).on("mouseleave"+_,n,(function(){e(this).removeClass(F)})).on(H+_,n,t._clickHandler).on("dblclick"+_,".k-treeview-leaf:not(.k-disabled)",t._toggleButtonClick.bind(t)).on(H+_,`.k-treeview-toggle .${N}`,t._toggleButtonClick.bind(t)).on("keydown"+_,t,t._keydown.bind(t)).on("keypress"+_,t._keypress.bind(t)).on("focus"+_,t._focus.bind(t)).on("blur"+_,t._blur.bind(t)).on("mousedown"+_,`.k-treeview-leaf,.k-checkbox-wrap :checkbox,.k-treeview-toggle .${N}`,t._mousedown.bind(t)).on("change"+_,".k-checkbox-wrap :checkbox",t._checkboxChange.bind(t)).on("click"+_,".k-request-retry",t._retryRequest.bind(t)).on("click"+_,".k-link.k-disabled",(function(e){e.preventDefault()})).on("click"+_,(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"),h=this.options.checkboxes,u=e.children("li");for(n=0;n<u.length;n++)o=(r=l[n]).uid,(i=u.eq(n)).attr("role","treeitem").attr(c,o).attr(j,i.hasClass("k-selected")),r.expanded="true"===i.attr(d),r.hasChildren&&i.attr(G,r.expanded),h&&(a=ie(i),r.checked=a.prop(S),a.attr("id","_"+o),a.next(".k-checkbox-label").attr("for","_"+o),i.attr(W,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;var 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(M,{sourceNode:e[0]})},drag:function(e){i.trigger(D,{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(E,{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;var n=e.destination;var r=e.position;function o(t){i.options.checkboxes&&i.options.checkboxes.checkChildren&&i.updateIndeterminate(),i.current(t),i.element.focus(),i.trigger(I,{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(H+_+b,(function(t){t.preventDefault(),e.off(H+_+b)}))},_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==U?n.template=p(n.template):n.template||(n.template=({item:e})=>{let n=i("text")(e);let 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(J,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);let r=i("imageAttr")(e.item);let o=i("spriteCssClass")(e.item);let 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;let o=i("url")(n),a=o?"a":"span",s=o?' href="'+h(o)+'"':"";let l=`<div class="${r.cssClass(t.group,n)}">`;return n.hasChildren&&(l+=`<span class='${r.toggleButtonClass(n)}'>`+r.toggleIcon(e($),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;var 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(ee,e)},contentCssAttributes:function(e){return t.templates.setDefaultClasses(te,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(x,e._refreshHandler),e.dataSource.bind(C,e._errorHandler),e.dataSource.bind(P,e._loadCompletedHandler),e.dataSource.bind(B,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(L,{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(L,{nodes:[]})}},_unbindDataSource:function(){var e=this.dataSource;e&&(e.unbind(x,this._refreshHandler),e.unbind(A,this._progressHandler),e.unbind(C,this._errorHandler),e.unbind(P,this._loadCompletedHandler),e.unbind(B,this._requestEndHandler))},_dataSource:function(e){var t=this,n=t.options.dataSource;n=f(n)?{data:n}:n,t._unbindDataSource(),n.fields||(n.fields=[{field:"text"},{field:"url"},{field:"spriteCssClass"},{field:"imageUrl"}]),t.dataSource=n=g.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:[M,D,E,I,z,L,"expand","collapse",w,x,k,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 X)t=i[X[e]],n=r.attr(s.attr(e+"-field")),!t&&n&&(t=n),t||(t=e),f(t)||(t=[t]),i[X[e]]=t},_fieldAccessor:function(t){var n=this.options[X[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){m.fn.setOptions.call(this,e),this._animation(),this._dragging(),this._accessors(),this._templates()},_trigger:function(e,t){return this.trigger(e,{node:t.closest(V)[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[S]=t},_setIndeterminate:function(e){var t,n,r,o=i(e),a=!0;if(o.length&&(n=(t=ie(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(W,a?t[0].checked:"mixed"),ie(e).data(T,!a).prop(T,!a).prop(S,a&&t[0].checked)}},updateIndeterminate:function(e){e=e||this.wrapper;var t=i(e).children();var n;var r;var o;if(t.length){for(n=0;n<t.length;n++)this.updateIndeterminate(t.eq(n));if(e.is(".k-treeview"))return;r=this._setIndeterminate(e),o=this.dataItem(e),r&&r.prop(S)?o.checked=!0:o&&delete o.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(T)?this.dataItem(i).set(S,n.prop(S)):this.dataItem(i).set(S,!1),this._skip=!1,this._bubbleIndeterminate(i,!0))}},_checkboxChange:function(t){var n=e(t.target);var i=n.prop(S);var r=n.closest(V);var o=this.dataItem(r);this._preventChange||(o.checked!=i&&(o.set(S,i),r.attr(W,i),this._trigger(y,r)),n.is(":focus")&&(this._trigger(k,r),this.focus()))},_toggleButtonClick:function(t){var n=e(t.currentTarget).closest(V);n.is("[aria-disabled='true']")||this.toggle(n)},_mousedown:function(t){var n=this;var i=e(t.currentTarget);var r=e(t.currentTarget).closest(V);var o=s.support.browser;r.is("[aria-disabled='true']")||((o.msie||o.edge)&&i.is(":checkbox")&&(i.prop(T)?(n._preventChange=!1,i.prop(S,!i.prop(S)),i.trigger(x),i.on(H+_,(function(e){e.preventDefault()})),n._preventChange=!0):(i.off(H+_),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(Q)},_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(Q)},parent:function(t){var n,i,r=/\bk-treeview\b(?!-)/,o=/\bk-treeview-item\b/;typeof t==U&&(t=this.element.find(t)),Z(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==v.RIGHT||d&&o==v.LEFT?l?i=r._nextVisible(a):a.find(".k-treeview-leaf").first().hasClass(Q)||r.expand(a):!d&&o==v.LEFT||d&&o==v.RIGHT?l&&!a.find(".k-treeview-leaf").first().hasClass(Q)?r.collapse(a):(i=r.parent(a),r._enabled(i)||(i=t)):o==v.DOWN?i=r._nextVisible(a):o==v.UP?i=r._previousVisible(a):o==v.HOME?i=r._nextVisible(e()):o==v.END?i=r._previousVisible(e()):o!=v.ENTER||a.find(".k-treeview-leaf").first().hasClass(Q)?o==v.SPACEBAR&&c.length&&(a.find(".k-treeview-leaf").first().hasClass(Q)||(c.prop(S,!c.prop(S)).data(T,!1).prop(T,!1),r._checkboxChange({target:c})),i=a):a.find(".k-treeview-leaf").first().hasClass("k-selected")||r._trigger(w,a)||r.select(a),i&&(n.preventDefault(),a[0]!=i[0]&&(r._trigger(k,i),r.current(i),r.scrollTo(i))))},_keypress:function(e){var t=this;var n=t.current().get(0);var i;var r=e.key;1===r.length&&(t._match||(t._match=""),t._match+=r,clearTimeout(t._matchTimer),t._matchTimer=setTimeout((function(){t._match=""}),300),(i=n&&t._matchNextByText(Array.prototype.indexOf.call(t.element.find(".k-treeview-item"),n),t._match)).length||(i=t._matchNextByText(-1,t._match)),i.get(0)&&i.get(0)!==n&&(t._trigger(k,i),t.current(i)))},_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(V)},_click:function(t){var n=e(t.currentTarget),i=r(n.closest(V)),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(w,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(V)},_group:function(e){var t=this,n=e.hasClass(O),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)},oe(o),r._updateNodeClasses(o,n,i),r._group(o)}))},_checkboxes:function(){var t=this.options;var n=t.checkboxes;var i;n&&(i=(i=s.html.renderCheckBox(e("<input/>"),e.extend({},t,{rounded:"medium"}))).replace(">",""),typeof(n=u({template:({item:e})=>i+` id="_${e.uid}" aria-hidden="true" type="checkbox" tabindex="-1"`+(n.name?'name="'+n.name+'"':"")+" "+(!1===e.enabled?"disabled":"")+" "+(e.checked?"checked":"")+"/>"},t.checkboxes)).template==U&&(n.template=p(n.template)),t.checkboxes=n)},_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(O),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");var 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");var 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){var i=this.element.find(t);for(var r=0;r<i.length;r++)n.call(this,r,e(i[r]).closest(V))},dataItem:function(t){var n=e(t).closest(V).attr(s.attr("uid")),i=this.dataSource;return i&&i.getByUid(n)},_dataItem:function(t){var n=e(t).closest(V).attr(s.attr("uid"));return this.dataSource&&this._dataSourceUids[n]},_insertNode:function(t,n,r,o,a){var l,c,d,h,u,p,f=this,m=i(r),g=m.children().length+1,v={firstLevel:r.hasClass(O),expanded:!a,length:g},_="",b=function(e,t){e.appendTo(t)};for(d=0;d<t.length;d++)(h=t[d]).index=n+d,_+=f._renderItem({group:v,item:h});if((c=e(_)).length){for(m.length||(m=e(f._renderGroup({group:v})),s.applyStylesFromKendoAttributes(m,["display"]),m.appendTo(r),r.attr(G,!0)),o(c,m),r.hasClass("k-treeview-item")&&(oe(r),f._updateNodeClasses(r,v,{expanded:!a})),u=c.prev().first(),p=c.next().last(),f._updateNodeClasses(u,{},{expanded:"true"==u.attr(s.attr("expanded"))}),f._updateNodeClasses(p,{},{expanded:"true"==p.attr(s.attr("expanded"))}),d=0;d<t.length;d++)(h=t[d]).hasChildren&&(l=h.children.data()).length&&f._insertNode(l,h.index,c.eq(d),b,!h.expanded);return c}},_updateNodes:function(t,n){var i=this;var o,a,c,d,h,u;var p={treeview:i.options,item:d};var f="expanded"!=n&&"checked"!=n;function m(e,t){e.is(".k-treeview-group")&&e.find(".k-treeview-item:not([aria-disabled])").attr(W,t),e.find(".k-checkbox-wrap input[type=checkbox]:not([disabled])").prop(S,t).data(T,!1).prop(T,!1)}if("selected"==n)d=t[0],(a=i.findByUid(d.uid)).find(".k-treeview-leaf").first().removeClass("k-hover").toggleClass("k-selected",d[n]).end(),d[n]&&i.current(a),a.attr(j,!!d[n]);else{var g=e.map(t,(function(e){return i.findByUid(e.uid).children("div")}));for(o=0;o<t.length;o++)p.item=d=t[o],a=(c=g[o]).parent(),f&&(s.unbind&&s.unbind(c),c.children(".k-treeview-leaf").html(i.templates.itemContent(p))),n==S?(m(c,h=d[n]),a.attr(W,h),i.options.checkboxes.checkChildren&&(m(a.children(".k-treeview-group"),h),i._setChecked(d.children,h),i._bubbleIndeterminate(a))):"expanded"==n?i._toggle(a,d,d[n]):"enabled"==n&&(a.find(".k-checkbox-wrap input[type=checkbox]").prop("disabled",!d[n]),u=!r(a).is(":visible"),a.removeAttr(q),d[n]||(d.selected&&d.set("selected",!1),d.expanded&&d.set("expanded",!1),u=!0,a.attr(j,!1).attr(q,!0)),i._updateNodeClasses(a,{},{enabled:d[n],expanded:!u})),c.length&&this.trigger("itemChange",{item:c,data:d,ns:l})}},_appendItems:function(e,t,n){var r=i(n).children();var o=!this._expanded(n);if(this.element===n){var a=this.dataSource.data();var s=this.dataSource.view();var 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;var s=this.options;var c=s.loadOnDemand;var 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 oe(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");var r=this.root.children(".k-treeview-item");for(var o=0;o<t.length;o++)this.trigger("itemChange",{item:r.eq(o),data:t[o],ns:l})},refresh:function(e){var n=e.node;var i=e.action;var r=e.items;var o=this.wrapper;var a=this.options;var s=a.loadOnDemand;var l=a.checkboxes&&a.checkboxes.checkChildren;var c;if(!this._skip){for(c=0;c<r.length;c++)this._dataSourceUids[r[c].uid]=r[c];if(e.field){if(!r[0]||!r[0].level)return;return this._updateNodes(r,e.field)}if(n&&(o=this.findByUid(n.uid),this._progress(o,!1)),l&&"remove"!=i){var d=!1;for(c=0;c<r.length;c++)if("checked"in r[c]){d=!0;break}if(!d&&n&&n.checked)for(c=0;c<r.length;c++)r[c].checked=!0}if("add"==i?this._appendItems(e.index,r,o):"remove"==i?this._remove(this.findByUid(r[0].uid),!1):"itemchange"==i?this._updateNodes(r):"itemloaded"==i?this._refreshChildren(o,r,e.index):(this._refreshRoot(r),this.element.attr(Y,!1)),"remove"!=i)for(c=0;c<r.length;c++)(!s||r[c].expanded||r[c]._loaded)&&r[c].load();this.wrapper.find(">ul").attr("role","tree"),this.trigger(z,{node:n?o:t}),this.dataSource.filter()&&this.options.checkboxes.checkChildren&&this.updateIndeterminate(o)}},_error:function(t){var n=t.node&&this.findByUid(t.node.uid);var i=this.templates.retry({messages:this.options.messages});n?(this._progress(n,!1),this._expanded(n,!1),o(n).replaceWith(l.icon(e($),{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(V)).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(K),e.attr("id",t),this.root.attr(K,t)},select:function(t){var n=this,i=n.element;if(!arguments.length)return i.find(".k-selected").closest(V);t=e(t,i).closest(V),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(x)},_toggle:function(e,t,n){var i=this.options;var o=r(e);var a=n?"expand":"collapse";var s;o.data("animating")||(s=t&&t.loaded(),n&&!s?(i.loadOnDemand&&this._progress(e,!0),o.remove(),t.load()):(this._updateNodeClasses(e,{},{expanded:n}),n||o.css("height",o.height()).css("height"),o.kendoStop(!0,!0).kendoAnimate(u({reset:!0},i.animation[a],{complete:function(){n&&o.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;m.fn.destroy.call(e),e.wrapper.off(_),e.wrapper.find(".k-checkbox-wrap :checkbox").off(_),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=s.attr("expanded");var o;var a=t;var l=a?"expand":"collapse";if(e.children().hasClass("k-hidden")&&e.children().removeClass("k-hidden"),1==arguments.length)return o=this._dataItem(e),"true"===e.attr(i)||o&&o.expanded;o=this.dataItem(e),r(e).data("animating")||!n&&this._trigger(l,e)||(a?(e.attr(i,"true"),e.attr(G,"true")):(e.removeAttr(i),e.attr(G,"false")),o&&(o.set("expanded",a),a=o.expanded))},_progress:function(t,n){var i=this.element;var r=this.templates.loading({messages:this.options.messages});1==arguments.length?((n=t)?i.html(r):i.empty(),this.element.attr(Y,n)):(o(t).replaceWith(e($).toggleClass("k-i-loading",n).toggleClass("k-icon",n)),t.attr(Y,n))},text:function(e,t){var n=this.dataItem(e),i=this.options[X.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;var 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 g||(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=t;var o;return((o=t)instanceof s.jQuery||window.jQuery&&o instanceof window.jQuery||Z(t))&&(n=this._objectOrSelf(t).dataSource,i=e(t).attr(s.attr("uid")),(r=n.getByUid(i))&&(r=n.remove(r))),r},_insert:function(e,t,n){t instanceof s.data.ObservableArray?t=t.toJSON():f(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:re(1),insertBefore:re(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;var 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(K)&&a.root.removeAttr(K),i=t.parent().parent(),r=t.prev(),o=t.next(),t[n?"detach":"remove"](),i.hasClass("k-treeview-item")&&(oe(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(V)},findByUid:function(t){var n=this.element.find(".k-treeview-item");var i=s.attr("uid");var r;for(var o=0;o<n.length;o++)if(n[o].getAttribute(i)==t){r=n[o];break}return e(r)},expandPath:function(t,n){var i=this;var r=t.slice(0);var o=n||e.noop;function a(t){var n=e.Deferred();var r=i.dataSource.get(t);var o=s.attr("expanded");var a;return r?(a=i.findByUid(r.uid),r.loaded()?(r.set("expanded",!0),a.attr(o,!0),a.attr(G,!0),n.resolve()):(i._progress(a,!0),r.load().then((function(){r.set("expanded",!0),a.attr(o,!0),a.attr(G,!0),n.resolve()})))):n.resolve(),n.promise()}a(r[0]).then((function e(){r.shift(),r.length?a(r[0]).then(e):o.call(i)}))},_parentIds:function(e){var t=e&&e.parentNode();var n=[];for(;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 h=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=e.node;var i=e.action;var r=e.items;var o=this.wrapper;var a=this.options;var s=a.loadOnDemand;var l=a.checkboxes&&a.checkboxes.checkChildren;var c;if(!this._skip){if(e.field){if(!r[0]||!r[0].level)return;return this._updateNodes(r,e.field)}if(n&&(o=this.findByUid(n.uid),this._progress(o,!1)),l&&"remove"!=i){var d=!1;for(c=0;c<r.length;c++)if("checked"in r[c]){d=!0;break}if(!d&&n&&n.checked)for(c=0;c<r.length;c++)r[c].checked=!0}if("add"==i?this._appendItems(e.index,r,o):"remove"==i?this._remove(this.findByUid(r[0].uid),!1):"itemchange"==i?this._updateNodes(r):"itemloaded"==i?this._refreshChildren(o,r,e.index):this._refreshRoot(r),"remove"!=i)for(c=0;c<r.length;c++)s&&!r[c].expanded||r[c].load();this.wrapper.find(">ul").attr("role","tree"),this.trigger("dataBound",{node:n?o:t}),this.dropdowntree._treeViewDataBound({node:n?o: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,h=n.keyCode,u=d.current(),p=d._expanded(u),f=u.find(".k-checkbox-wrap").first().find(":checkbox"),m=i.support.isRtl(d.element);n.target==n.currentTarget&&(!m&&h==o.RIGHT||m&&h==o.LEFT?p?r=d._nextVisible(u):u.find(".k-treeview-leaf").first().hasClass(a)||d.expand(u):!m&&h==o.LEFT||m&&h==o.RIGHT?p&&!u.find(".k-treeview-leaf").first().hasClass(a)?d.collapse(u):(r=d.parent(u),d._enabled(r)||(r=t)):h==o.DOWN?r=d._nextVisible(u):h!=o.UP||n.altKey?h==o.HOME?r=d._nextVisible(e()):h==o.END?r=d._previousVisible(e()):h!=o.ENTER||u.find(".k-treeview-leaf").first().hasClass(a)?h==o.SPACEBAR&&f.length&&!u.find(".k-treeview-leaf").first().hasClass(a)?(f.prop(l,!f.prop(l)).data(c,!1).prop(c,!1),d._checkboxChange({target:f}),r=u):n.altKey&&h===o.UP||h===o.ESC?d._closePopup():h===o.TAB&&(n.preventDefault(),d._closePopup()):u.find(".k-treeview-leaf").first().hasClass("k-selected")||d._trigger(s,u)||d.select(u):r=d._previousVisible(u),r&&(n.preventDefault(),u[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=h}(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,h=e.extend,u=n._activeElement,p=".kendoDropDownTree",f=n.keys,m=n.support,g="k-hidden",v="width",_=m.browser,b=n._outerWidth,w=".",y="disabled",k="readonly",x="k-disabled",C="aria-disabled",S="k-focus",T="mouseenter"+p+" mouseleave"+p,M="tabindex",A="click",D="open",E="close",I="change",z=/"/g,P=".k-chip";function L(t){if(Array.isArray(t)){var i=t.length;var 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 B=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(M,this.wrapper.attr(M)),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.wrapper&&r.popup.wrapper.remove(),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=pg.bind(e),e._initLoader()},_label:function(){var t=this;var i=t.options;var 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;const 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.",filterInputPlaceholder:"Filter"},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,adaptiveTitle:null,adaptiveSubtitle: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=this.options;var n;if(clearTimeout(this._typingTimeout),!t.enforceMinLength&&!e.length||e.length>=t.minLength){if(n=this._getFilter(e),this.trigger("filtering",{filter:n})||Array.isArray(this.options.dataTextField))return;this._filtering=!0,this.treeview.dataSource.filter(n)}},_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(_g(n.options,i,n._useValueMapper.bind(n,i,e)))}},_useValueMapper:function(t,n,i){const r=this;const 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;const 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;const 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;var 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;var i=e(t.header);var 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;var i=e(t.noData);var 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;var t=e.noData;t&&t.html(e.noDataTemplate({instance:e}))},_footer:function(){var t=this;var i=e(t.footer);var 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;var 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;var 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,h({},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.options.adaptiveTitle||(r.label?r.label.element.text():r.options.label||r.options.placeholder||"Select")}</div>`+(r.options.adaptiveSubtitle?`<div class="k-actionsheet-subtitle k-text-center">${r.options.adaptiveSubtitle||""}</div>`:"")+"</div>"+(e.closeButton?'<div class="k-actionsheet-actions">'+n.html.renderButton(`<button tabindex="-1" ${n.attr("ref-actionsheet-close-button")}></button>`,{icon:"check",fillMode:"flat",size:"large",themeColor:"primary"})+"</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:h({},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="";var i=-1;var r=this.value();var 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}));var 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.dataSource._requestInProgress||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;var t="";var n=null;var 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,""")),o+=' value="'+e+'"'),r&&(o+=" selected"),o+=">",i!==t&&(o+=n.htmlEncode(i)),o+"</option>"},_selectValue:function(e){var t="";var 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;var i={};return n?(H(i,n.split(w),e),H(i,this.options.dataValueField.split(w),t),i=new d(i)):i=e,i},_textAccessor:function(n,i){var r=this.valueTemplate;var 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;var t=this.options;var i=e.attr(n.attr("text-field"));var 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=L(t.dataTextField),this._value=L(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);var t=this.value()&&!this._isMultipleSelection()||this.value().length;var 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(D)?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,h({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.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")||this.options.messages.filterInputPlaceholder,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(h({},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");var 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){var t=this.treeview.dataItems();for(var 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=this._value(e);var i;if(!this._isNullorUndefined(n)){if(this._isNullorUndefined(t))return!1;var r=this._value(t);return r?n==r:n==t}return!!(i=this._text(e))&&(this._text(t)?i==this._text(t):i==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;var i=n.element;var r=t.disable;var o=t.readonly;var a=n.wrapper.add(n.filterInput).off(p);var s=n.wrapper.off(T);n._isMultipleSelection()&&n.tagList.off(A+p),o||r?r?(a.removeAttr(M),s.addClass(x)):(a.attr(M,a.data(M)),s.removeClass(x),a.on("focusin"+p,n._focusinHandler.bind(n)).on("focusout"+p,n._focusoutHandler.bind(n))):(i.prop(y,!1).prop(k,!1),s.removeClass(x).on(T,n._toggleHover),n._clear.on("click"+p,n._clearClick.bind(n)),a.attr(M,a.data(M)).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(y,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(w+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())?D: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=e.keyCode;var n=e.altKey;var i;var r;var o,a;var s=this.popup.visible();if(this.filterInput&&(i=this.filterInput[0]===u()),this.wrapper&&(r=this.wrapper[0]===u()),r){if(t===f.ESC)return this._clearTextAndValue(),void e.preventDefault();if(this._isMultipleSelection()){if(t===f.LEFT)return this._focusPrevTag(),void e.preventDefault();if(t===f.RIGHT)return this._focusNextTag(),void e.preventDefault();if(t===f.HOME)return this._focusFirstTag(),void e.preventDefault();if(t===f.END)return this._focusLastTag(),void e.preventDefault();if(t===f.DELETE)return(o=this.tagList.find(w+S).first()).length&&(a=this._tags[o.index()],this._removeTag(a)),void e.preventDefault();if(t===f.BACKSPACE)return((o=this.tagList.find(w+S).first()).length||(o=this._focusLastTag()).length)&&(a=this._tags[o.index()],this._removeTag(a)),void e.preventDefault()}}return i&&(t===f.ESC&&this._clearFilter(),t!==f.UP||n||(this.wrapper.trigger("focus"),e.preventDefault()),_.msie&&_.version<10&&(t!==f.BACKSPACE&&t!==f.DELETE||this._search()),t===f.TAB)||n&&t===f.UP||t===f.ESC?(this.close(),this.wrapper.trigger("focus"),void e.preventDefault()):void(t===f.ENTER&&this._typingTimeout&&this.filterInput&&s?e.preventDefault():(t!==f.SPACEBAR||i||(this._toggle(!s),e.preventDefault()),n&&t===f.DOWN&&!s&&(this.open(),e.preventDefault()),t===f.DOWN&&s&&(this.filterInput&&!i?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()),t===f.TAB&&s&&(this.close(),this.wrapper.trigger("focus"),e.preventDefault())))},_focusPrevTag:function(){var e=this.tagList.find(w+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(w+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(w+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 H(e,t,n){var i,r=0,o=t.length-1;for(;r<o;++r)(i=t[r])in e||(e[i]={}),e=e[i];e[t[o]]=n}i.plugin(B),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 R=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>',h({},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=this._dropdowntree;var i;return e===t||null===e?(e="object"==typeof(i=n._values.slice()[0])?i:n._accessor()||i)===t||null===e?"":e:(n._valueMethodCalled=!0,0===e.length?(n._clearTextAndValue(),void(n._valueMethodCalled=!1)):(n._selectItemByValue(e),n._toggleCloseVisibility(),void n._refreshFloatingLabel()))},_clearValue:function(){var e=this._dropdowntree;var t=e.treeview.select();var n=e._values.length;var 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))}});var F=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;var 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;var i=t.options;var a=i.valueTemplate;var s="multiple"===i.tagMode;var 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"> '+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;var 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){var n=this._dropdowntree;var i=this._getNewValues(e,t);for(var 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){var n=[];for(var i=0;i<e.length;i++)-1===t.indexOf(e[i])&&n.push(e[i]);return n},_clearValue:function(){var e=this._dropdowntree;var t=e._tags.slice();for(var 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=R,n.ui.DropDownTree.MultipleSelection=F}(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,h=n._activeElement,u=n.keys,p=".kendoComboBox",f=p+"FocusEvent",m="click"+p,g="mousedown"+p,v="disabled",_="readonly",b="change",w="k-focus",y="k-disabled",k="aria-disabled",x="aria-readonly",C="filter",S="accept",T="rebind",M="mouseenter"+p+" mouseleave"+p,A=/(\r\n|\n|\r)/gm,D=[16,17,18,19,20,33,34,37,39,45,91,92,144,145];var 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)),!n.isPresent(i.readonly)&&t.attr("readonly")?i.readonly=!0:n.isPresent(i.readonly)||(i.readonly=!1),i.placeholder=i.placeholder||t.attr("placeholder"),i.inputMode=i.inputMode||t.attr("inputmode")||"text",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),Yu({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:"",readonly:null,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,adaptiveTitle:null,adaptiveSubtitle: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._unboundClick=!0,e.input.on("click",e._arrowClick.bind(e)),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;var 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&&h()===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;var t=e.text();var n=t&&t!==e._oldText&&t!==e.options.placeholder;var i=e.selectedIndex;var r=-1===i;if(e.filterInput&&h()===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(){const e=this;e._hasActionSheet()?e.input.attr("readonly",!0):e.options.readonly||e.input.removeAttr("readonly"),e.wrapper.addClass(w),e._placeholder(!1)},_inputFocusout:function(t){var n=this;var 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(w),clearTimeout(n._typingTimeout),n._typingTimeout=null,r&&n.text(n.text());var o=n._focus();var a=this.listView.dataItemByIndex(this.listView.getElementIndex(o));var 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?y:"").removeClass(n?"":y),o.attr(v,n).attr(_,i).attr(k,n).attr(x,i)):(r.removeClass(y).on(M,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;var t=e._state;var n=!!e.dataSource.filter()&&e.dataSource.filter().filters.length>0;var 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;var n=e.options.text;var 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;var n=t.listView;var i=t._initialIndex;var 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;var n=e.input[0]===h()||e.filterInput&&e.filterInput[0]===h();var i=e.dataSource.flatView();var r=e.listView.skip();var o=i.length;var a=e.dataSource._group?e.dataSource._group.length:0;var 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();var i="";var 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=this;var n=l(this.input);var i;if(n&&n.length&&(i=n[0]),this._prev=this.input[0].value=e,i&&-1===this.selectedIndex){var r=c.mobileOS;r.wp||r.android?setTimeout((function(){t.input[0].setSelectionRange(i,i)}),0):this.input[0].setSelectionRange(i,i)}},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=this;var i=n.input[0];var r=n.text();var o=l(i)[0];var s=n._last;var c;var d=n.dataSource.options.accentFoldingFiltering;s!=u.BACKSPACE&&s!=u.DELETE?("string"!=typeof(e=e||"")&&(e[0]&&(e=n.dataSource.view()[a.inArray(e[0],n.ul[0])]),e=e?n._text(e):""),o<=0&&(o=(d?r.toLocaleLowerCase(d):r.toLowerCase()).indexOf(d?e.toLocaleLowerCase(d):e.toLowerCase())+1),e?(e=e.toString(),(c=(d?e.toLocaleLowerCase(d):e.toLowerCase()).indexOf(d?r.toLocaleLowerCase(d):r.toLowerCase()))>-1&&(r+=e.substring(c+r.length))):r=r.substring(0,o),r.length===o&&e||(i.value=r,i===h()&&l(i,o,r.length))):n._last=t},text:function(e){e=null===e?"":e;var n=this;var i=n.filterInput&&n.filterInput[0]===h()?n.filterInput[0]:n.input[0];var r=n.options.ignoreCase;var o=e;var s;var l;if(e===t)return i.value;!1!==n.options.autoBind||n.listView.bound()?(s=n.dataItem())&&n._text(s).replace&&n._text(s).replace(A,"")===e&&(l=n._value(s))===a.unifyType(n._old,typeof l)?n._triggerCascade():(r&&(o=o.toLowerCase()),n.dataItem()&&n._text(n.dataItem())===e||(n._select((function(e){return e=n._text(e),r&&(e=(e+"").toLowerCase()),e===o})).done((function(){n.selectedIndex<0&&(i.value=e,n.options.syncValueAndText&&n._accessor(e),n._isValueChanged(e)&&(n._cascadeTriggered=!0,n._triggerCascade()),n._refreshFloatingLabel()),n._prev=i.value})),n._toggleCloseVisibility())):n._setText(e)},toggle:function(e){this._toggle(e,!0)},value:function(e){var n=this;var i=n.options;var 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;var n=e.item;var i=t.listView.dataItemByIndex(t.listView.getElementIndex(n));var 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;var i=n.options;var r=n.dataSource;var 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",h=a.name||"",u=r.options;h&&(h='name="'+h+'_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:u.size,fillMode:u.fillMode,shape:"none",rounded:"none"}),l.append("<input "+h+'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&&(n.isPresent(E._isServerRendered)&&E._isServerRendered||(e[0].maxLength=t)),e.addClass(a.className).css({width:"",height:a.style.height,position:""}).attr({role:"combobox","aria-expanded":!1,inputmode:u.inputMode}).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=D.indexOf(n)>-1;if(t._last=n,clearTimeout(t._typingTimeout),t._typingTimeout=null,n===u.HOME)t._firstItem();else if(n===u.END)t._lastItem();else if(n===u.ENTER||n===u.TAB&&t.popup.visible()){var s=t.listView.focus();var l=t.dataItem();var 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&&h()===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==u.TAB||t._move(e)||o||r||e.ctrlKey?t.options.clearOnEscape&&n===u.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]!==h()||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();var 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;var t=e.filterInput&&e.filterInput[0]===h()?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",h=".k-chip",u="accept",p="filter",f="rebind",m="open",g="close",v="change",_="select",b="deselect",w="aria-disabled",y="aria-readonly",k="aria-expanded",x="aria-hidden",C="aria-activedescendant",S="k-focus",T="k-selected",M="k-hover",A="k-disabled",D="k-no-click",E="disabled",I="readonly",z=".kendoMultiSelect",P="click"+z,L="keydown"+z,B="mouseenter"+z,H="mouseleave"+z,R=B+" "+H,F=/"/g,O=Array.isArray,V=["font-family","font-size","font-stretch","font-style","font-weight","letter-spacing","text-transform","line-height"];var 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.options.inputMode=a.options.inputMode||a.element.attr("inputmode")||"text",!n.isPresent(a.options.readonly)&&a.element.attr("readonly")?a.options.readonly=!0:n.isPresent(a.options.readonly)||(a.options.readonly=!1),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(),Yu({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,readonly:null,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,downArrow:!1,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,adaptiveTitle:null,adaptiveSubtitle: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"),placeholder:e.options.placeholder}),e.popup.bind("activate",(()=>{e.filterInput.val(e.input.val()),e.filterInput.trigger("focus")})),e.popup.bind("deactivate",(()=>{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)},_updateSelectedVirtualDataItemsIndexes:function(){const e=this;const n=e.listView;const i=n?._selectedIndexes;const r=n?._selectedDataItems;const o=e?._customOptions||{};const a=e._optionsMap||{};i&&r&&i.forEach(((n,i)=>{const s=e.options.dataValueField;const l=r[i];const c=a[l[s]];o[l[s]]=c!==t?c:o[l[s]]}))},_activateItem:function(){this.popup.visible()&&r.fn._activateItem.call(this),this.currentTag(null)},_listOptions:function(t){var i=this;var a=r.fn._listOptions.call(i,e.extend(t,{selectedItemChange:i._selectedItemChange.bind(i),selectable:"multiple"}));var s=this.options.itemTemplate||this.options.template;var 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();var i=this._optionsMap;var 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=e.items;var n;var i;for(i=0;i<t.length;i++)n=t[i],this.tagList.children(h).eq(n.index).children("span").first().html(this.tagTextTemplate(n.item))},_wrapperMousedown:function(t){var i=this;var r="input"!==t.target.nodeName.toLowerCase();var o=e(t.target);var a=o.closest(".k-input-button, .k-chip").children("[class*='-i-caret-alt-down']")[0];var 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(){const e=this;e._hasActionSheet()?e.input.attr("readonly",!0):e.options.readonly||e.input.removeAttr("readonly"),e._placeholder(!1,!0),e.wrapper.addClass(S)},_inputFocusout:function(e){var t=this;t.filterInput&&e.relatedTarget===t.filterInput[0]||(clearTimeout(t._typingTimeout),t.wrapper.removeClass(S),t.tagList.children(h).removeClass(S),t._placeholder(!t.listView.selectedDataItems()[0],!0),t.close(),t._state===p&&(t._state=u,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=this;var r=i._state;var o=e.index();var a=i.listView;var s=a.value()[o];var l=i.listView.selectedDataItems()[o];var c=i._customOptions[s];var d=a.element[0].children;var h;if(i.trigger(b,{dataItem:l,item:e}))i._close();else{c!==t||r!==u&&r!==p||(c=i._optionsMap[s]);var f=function(){i.currentTag(null),n&&i._change(),i._refreshTagListAria(),i._close()};c===t&&a.select().length?(i.persistTagList=!1,a.select(a.select()[o]).done(f)):((h=i.element[0].children[c])&&(h.selected=!1),a.removeAt(o),a._removedAddedIndexes&&a._removedAddedIndexes.splice(o,1),d[c]&&d[c].classList.remove("k-selected"),"single"!==i.options.tagMode?e.remove():i._updateTagListHTML(),f())}},_tagListClick:function(t){t.preventDefault(),t.stopPropagation();var n=e(t.currentTarget);n.is("[class*='-i-x-circle']")&&this._removeTag(n.closest(h),!0)},_clearValue:function(){var t=this;"single"===t.options.tagMode?t._clearSingleTagValue():t.tagList.children(h).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=u)},_clearSingleTagValue:function(){var e=this;var t=e.dataItems();var n=e.tagList.children(h);var i=e.persistTagList;for(var 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;var 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(D,r),s.attr(E,i).attr(I,r).attr(w,i).attr(y,r),n.element.prop(E,i)):(o.removeClass(A).removeClass(D).on(R,n._toggleHover).on("mousedown"+z+" touchend"+z,n._wrapperMousedown.bind(n)).on(P,n._focusHandler.bind(n)),n.input.on(L,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(w,!1).attr(y,!1),n.element.prop(E,!1),a.on(B,h,(function(){e(this).addClass(M)})).on(H,h,(function(){e(this).removeClass(M)})).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===u&&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;var 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(),"dataItem"===e.options?.virtual?.mapValueTo&&e._updateSelectedVirtualDataItemsIndexes(),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;var 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;var i=n.listView;var r=i.value().slice();var o=n.options.maxSelectedItems;var 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;var 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;var 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=this;var o=i.keyCode;var a=r._currentTag;var l=r.listView;var c=r.input.val();var d=n.support.isRtl(r.wrapper);var p=r.popup.visible();var f=0;var m;var g=!1;if(o!==s.ENTER&&(this._multipleSelection=!1),o===s.DOWN){if(i.preventDefault(),!p)return r.open(),l.focus()||l.focusFirst(),void i.stopPropagation();l.focus()?(!r._activeItem&&i.shiftKey&&(r._activeItem=l.focus(),f=-1),m=l.getElementIndex(r._getActiveItem().first()),l.focusNext(),l.focus()?i.shiftKey&&!r.options.virtual&&(this._multipleSelection=!0,r._selectRange(m,l.getElementIndex(l.focus().first())+f)):l.focusLast()):l.focusFirst(),g=!0}else if(o===s.UP)p&&(!r._activeItem&&i.shiftKey&&(r._activeItem=l.focus(),f=1),m=l.getElementIndex(r._getActiveItem().first()),l.focusPrev(),l.focus()?i.shiftKey&&!r.options.virtual&&(this._multipleSelection=!0,r._selectRange(m,l.getElementIndex(l.focus().first())+f)):r.close()),g=!0,i.preventDefault();else if(o===s.LEFT&&!d||o===s.RIGHT&&d)c||(a=a?a.prev(h):r.tagList.children(h).last())[0]&&r.currentTag(a),g=!0;else if(o===s.RIGHT&&!d||o===s.LEFT&&d)!c&&a&&(a=a.next(h),r.currentTag(a[0]?a:null)),g=!0;else if(i.ctrlKey&&!i.altKey&&o===s.A&&p&&!r.options.virtual)this._multipleSelection=!0,this._getSelectedIndices().length===l.items().length&&(r._activeItem=null),l.items().length&&r._selectRange(0,l.items().length-1),g=!0;else if(o===s.ENTER&&p){if(!l.focus())return void i.stopPropagation();if(i.preventDefault(),this._multipleSelection&&(this._multipleSelection=!1,l.focus().hasClass(T)))return r._close(),void i.stopPropagation();r._select(l.focus()).done((function(){r._change(),r._close()})),g=!0}else if(o===s.SPACEBAR&&i.ctrlKey&&p)r._activeItem&&l.focus()&&l.focus()[0]===r._activeItem[0]&&(r._activeItem=null),e(l.focus()).hasClass(T)||(r._activeItem=l.focus()),r._select(l.focus()).done((function(){r._change()})),g=!0,i.preventDefault();else if(o===s.SPACEBAR&&i.shiftKey&&p&&!r.options.virtual){var v=l.getElementIndex(r._getActiveItem());var _=l.getElementIndex(l.focus());v!==t&&_!==t&&r._selectRange(v,_),g=!0,i.preventDefault()}else if(o===s.ESC)p?i.preventDefault():(r.tagList.children(h).each((function(t,n){r._removeTag(e(n),!1)})),r._change()),r.close(),g=!0;else if(o===s.HOME)p?l.focus()?(i.ctrlKey&&i.shiftKey&&!r.options.virtual&&r._selectRange(l.getElementIndex(l.focus()[0]),0),l.focusFirst()):r.close():c||(a=r.tagList.children(h).first()[0])&&r.currentTag(e(a)),g=!0;else if(o===s.END)p?l.focus()?(i.ctrlKey&&i.shiftKey&&!r.options.virtual&&r._selectRange(l.getElementIndex(l.focus()[0]),l.element.children().length-1),l.focusLast()):r.close():c||(a=r.tagList.children(h).last()[0])&&r.currentTag(e(a)),g=!0;else if(o!==s.DELETE&&o!==s.BACKSPACE||c)if(!r.popup.visible()||o!==s.PAGEDOWN&&o!==s.PAGEUP)clearTimeout(r._typingTimeout),r._search(),g=!0;else{i.preventDefault();var b=o===s.PAGEDOWN?1:-1;l.scrollWith(b*l.screenHeight()),g=!0}else{if(r._state=u,"single"===r.options.tagMode)return r._clearSingleTagValue(),r._change(),r._close(),void i.stopPropagation();o!==s.BACKSPACE||a||(a=r.tagList.children(h).last()),a&&a[0]&&r._removeTag(a,!0),g=!0}g&&i.stopPropagation()},_placeholder:function(e,i){var r=this;var o=r.input;var a=l();var s=r.options.placeholder;var c=o.val();var d=o[0]===a;var h=c.length;d&&!r.options.autoClose&&c!==s||(h=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],h,h)},_option:function(e,i,r){var o="<option";return e!==t&&(-1!==(e+="").indexOf('"')&&(e=e.replace(F,""")),o+=' value="'+e+'"'),r&&(o+=" selected"),o+=">",i!==t&&(o+=n.htmlEncode(i)),o+"</option>"},_render:function(e){var t=this.listView.selectedDataItems();var n=this.listView.value();var i=e.length;var r;var o="";var a;var s;var l;n.length!==t.length&&(t=this._buildSelectedItems(n));var c={};var d={};for(l=0;l<i;l++)a=e[l],s=this._value(a),-1!==(r=this._selectedItemIndex(s,t))&&t.splice(r,1),d[s]=l,o+=this._option(s,this._text(a),-1!==r);if(t.length)for(l=0;l<t.length;l++)a=t[l],c[s=this._value(a)]=i,d[s]=i,i+=1,o+=this._option(s,this._text(a),!0);this._customOptions=c,this._optionsMap=d,this.element.html(o)},_buildSelectedItems:function(e){var t=this.options.dataValueField;var n=this.options.dataTextField;var i=[];var r;for(var o=0;o<e.length;o++)(r={})[t]=e[o],r[n]=e[o],i.push(r);return i},_selectedItemIndex:function(e,t){var n=this._value;var i=0;for(;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=this;var r=i.dataSource.total();var o=i.tagList;var a=i._value;var s;var l;var c;if(this.persistTagList)return this.updatePersistTagList(e,t),void i._refreshTagListAria();if("multiple"===i.options.tagMode){for(c=t.length-1;c>-1;c--)s=t[c],o.children(h).length&&(o[0].removeChild(o[0].children[s.position]),i._setOption(a(s.dataItem),!1));for(c=0;c<e.length;c++)l=e[c],i.tagList.append(i.tagTemplate(l.dataItem)),i._setOption(a(l.dataItem),!0);n.applyStylesFromKendoAttributes(i.tagList,["background-color"])}else{for((!i._maxTotal||i._maxTotal<r)&&(i._maxTotal=r),this._updateTagListHTML(),c=t.length-1;c>-1;c--)i._setOption(a(t[c].dataItem),!1);for(c=0;c<e.length;c++)i._setOption(a(e[c].dataItem),!0)}i._refreshTagListAria(),i._refreshFloatingLabel(),i._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;var i=t.value();var r=t.dataSource.total();t.tagList.children(h).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;var r=i.listView;var o=r.dataItemByIndex(r.getElementIndex(t));var 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=u,r.skipUpdate(!0))}))):n},_selectIndices:function(t){let n=this.listView;let i=this;n.select(t).done((function(){t.forEach((function(t){var r=n.dataItemByIndex(t);var o=n.element.children()[t];var a=e(o).hasClass("k-selected");i.trigger(a?_:b,{dataItem:r,item:e(o)})})),i._change()}))},_selectRange:function(e,t){var n=this;var i=this.options.maxSelectedItems;var r=this._getSelectedIndices().slice();var o=[];var a;if(r.length-1==t-e)return n._selectIndices(r);if(e<t)for(a=e;a<=t;a++)o.push(a);else for(a=e;a>=t;a--)o.push(a);for(null!==i&&o.length>i&&(o=o.slice(0,i)),a=0;a<o.length;a++){var s=o[a];-1==this._getSelectedIndices().indexOf(s)?r.push(s):r.splice(r.indexOf(s),1)}return r.length?(n.persistTagList=!1,n._selectIndices(r)):void 0},_input:function(){var t=this;var n=t.element;var i=n[0].accessKey;var 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"),r.attr("inputmode",t.options.inputMode),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=this;var i=t.options;var r=i.tagTemplate;var s=i.dataSource;var l="multiple"===i.tagMode;var c=i.messages.singleTag;var d;var h;t.element[0].length&&!s&&(i.dataTextField=i.dataTextField||"text",i.dataValueField=i.dataValueField||"value"),h=({values:e})=>`${e.length} ${o(c)}`,d=l?e=>o(n.getter(i.dataTextField)(e)):h,t.tagTextTemplate=r=r?n.template(r):d,t.tagTemplate=function(n){return a.renderChip('<span unselectable="on"></span>',e.extend({},i,{fillMode:"solid",rounded:"medium",enabled:!0,themeColor:"base",text:r(n),attr:{unselectable:"on","aria-selected":!0,role:"option","aria-keyshortcuts":l?"Enter Delete":"Enter"},removable:l,removableAttr:{unselectable:"on","aria-hidden":!0,"aria-label":t.options.messages.deleteTag,title:t.options.messages.deleteTag},icon:l?"":"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;var 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){var n=t.columns;var i=e.support.scrollbar();for(var 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,h=Math,u=n.support,p=u.pointers,f=u.msPointers,m="change",g="slide",v=".slider",_="touchstart"+v+" mousedown"+v,b=p?"pointerdown"+v:f?"MSPointerDown"+v:_,w="touchend"+v+" mouseup"+v,y=p?"pointerup":f?"MSPointerUp"+v:w,k="moveSelection",x="keydown"+v,C="click"+v,S="mouseover"+v,T="focus"+v,M="blur"+v,A=".k-draghandle",D=".k-slider-track",E=".k-tick",I="k-selected",z="k-focus",P="k-disabled",L="disabled",B="tabindex",H=n.getTouches,R="aria-valuetext",F="aria-valuenow";var 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(D),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;var i=(t._maxSelection-2)/((n.max-n.min)/n.smallStep);var r=t._calculateItemsWidth(h.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=h.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(){var t=this.options,n=this.wrapper.find(E),i=t.min,r=n.length;for(var 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]-h.floor(e[t]),e[t]=h.floor(e[t]);return n=h.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(h.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=h.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=h.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(h.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,h=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!==h&&h!==t||(h=a)));var u="<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='"+(h||e.max)+"'></span>":"")+"</div>";return u}(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-hidden="true" tabindex="-1">'+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();var n=0;return(t=t.split("."))[1]&&(n=t[1].length),n>10?10:n}(e=parseFloat(e,10)),n=h.pow(10,t||0),h.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=h.max(h.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(L,!1),i=function(t){var n=H(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+", "+D).on(b,i).end().on(y,(function(){o._drag._end()})),o.wrapper.find(A).attr(B,0).on(w,(function(){o._setTooltipTimeout()})).on(C,(function(e){o._focusWithMouse(e.target),e.preventDefault()})).on(T,o._focus.bind(o)).on(M,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(w,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(L,L),t.wrapper.find(".k-button").off(_).on(_,(function(t){t.preventDefault(),e(this).addClass("k-active")})).off(w).on(w,(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+", "+D).off(b).off(y),t.wrapper.find(A).attr(B,-1).off(w).off(x).off(C).off(T).off(M),t.options.enabled=!1},_mouseDownHandler:function(e,t,n){let i=this;i._clearTooltipTimeout(),(1===e.which||u.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(F,e).attr(R,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=h.max(h.min(e,n.max),n.min),t._update(e))},_nextValueByIndex:function(e){var t=this._values.length;return this._values[h.max(0,h.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+", "+D).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=h.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=h.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,h=0,u=l.element,p=n.getOffset(u),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,h=p.left+(i.left-p.left)/2):(d=p.top+(i.top-p.top)/2,h=i.left),s=o(t.eq(0))+16):(d=p.top,h=p.left,s=o(u)+16),c._isHorizontal?(h-=parseInt((g-c._outerSize(u))/2,10),d-=v+8+(m.length?m.height():0)):(d-=parseInt((v-c._outerSize(u))/2,10),h-=g+8+(m.length?m.width():0)),c._isHorizontal?(d+=r=l._flip(d,v,s,a(f)+l._scrollOffset.top),h+=l._fit(h,g,o(f)+l._scrollOffset.left)):(r=l._flip(h,g,s,o(f)+l._scrollOffset.left),d+=l._fit(d,v,a(f)+l._scrollOffset.top),h+=r),r>0&&m&&(m.removeClass(),m.addClass("k-callout k-callout-"+(c._isHorizontal?"n":"w"))),l.tooltipDiv.css({top:d,left:h})},_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(L,!1),i=function(t){var n=H(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),h=e(t.target);if(h.hasClass("k-draghandle"))return r.wrapper.find("."+z).removeClass(z+" "+I),void h.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+", "+D).on(b,i).end().on(y,(function(){r._activeDragHandle&&r._activeDragHandle._end()})),r.wrapper.find(A).attr(B,0).on(w,(function(){r._setTooltipTimeout()})).on(C,(function(e){r._focusWithMouse(e.target),e.preventDefault()})).on(T,r._focus.bind(r)).on(M,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(L,L),e.wrapper.find(E+", "+D).off(b).off(y),e.wrapper.find(A).attr(B,-1).off(w).off(x).off(C).off(T).off(M),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();var 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(F,e),r.eq(1).attr(F,t),r.attr(R,n)},_setValueInRange:function(e,t){var n=this.options;e=h.max(h.min(e,n.max),n.min),t=h.max(h.min(t,n.max),n.min),e==n.max&&t==n.max&&this._setZIndex("firstHandle"),this._update(h.min(e,t),h.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");var i=n[0].value;var 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+", "+D).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=h.ceil(W(r/n.smallStep)),s=h.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=h.abs(e-n),o[t._sizeFn](i),r=h.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,r=i.Widget,o=n.parseColor,a=n.ui.Popup.TabKeyTrap,s=e.extend,l=".kendoColorTools",c="keydown"+l;var 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&&(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){h(this,"select",e)},_triggerChange:function(e){h(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 h(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);var i=c(e.g,0,255);var r=c(e.b,0,255);var o=c(e.a,0,1);var a=c(t.r,0,255);var s=c(t.g,0,255);var 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 h(e,t){var n=t[0]-e[0];var 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=function(l,d,h,u,p){var f=(h+u)/2;var m=i({},t,{s:d/e.width,v:1-f/e.height});var g=a(o(function(e){var t=c(e.h,0,359.9);var n=c(e.s,0,1);var i=c(e.v,0,1);var o=c(e.a,0,1);return r.fromHSV(t,n,i,o).toCssRgba()}(m)).toBytes(),o(n).toBytes());return h+.5>u?g<l+1&&g>l-1?f:null:p(g,l)?s(l,d,h,u-(u-h)/2,p):s(l,d,h+(u-h)/2,u,p)};var l=function(e,t){return e>t};var u=function(e,t){return e<t};var p=function(t,n,i){var r=[];for(var o=0;o<=e.width;o+=e.width/n){var a=s(t,o,0,e.height,i?u:l);null!==a&&r.push([o,a])}return r};var f=(g=h,m=function(e,t,n,i){var r=.1;var o=g(t||e,n||e);var a=o.angle+(i?Math.PI:0);var s=o.length*r;return[e[0]+Math.cos(a)*s,e[1]+Math.sin(a)*s]},function(e,t,n){var i=m(n[t-1],n[t-2],e);var r=m(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])});var m;var g;var v=d(p(4.5,16,!1),f)+d(p(4.5,16,!0),f)+d(p(7,16,!1),f)+d(p(7,16,!0),f);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",h="keydown.kendoColorTools",u=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(h,r.keydown.bind(r)),i.fn.init.call(r)},_template:t.template((({options:e,ns:t})=>{let n=a(e.size);let i=a(e.tabindex);let 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){let r=a(e.messages.hex);o=`<div class="k-vstack${e._showAdaptiveView?" k-flex-1":""}" 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="${r}"/><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)}" inputmode="decimal"/><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)}" inputmode="decimal"/><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)}" inputmode="decimal"/><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}" inputmode="decimal"/><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(h),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}});var g=u.extend({init:function(n,i){var r,o=this;u.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,_showAdaptiveView:!1},_template:t.template((e=>`<div class="k-colorgradient-canvas ${e._showAdaptiveView?"k-vstack":"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 ${e._showAdaptiveView?"k-vstack":"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(),h=this._hsvHandle.position();return l&&c?(null==e&&(e=o._hueSlider.value()),null==t&&(t=h.left/l),null==n&&(n=1-h.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=this,n=e.wrapper.find(".k-hsv-rectangle"),i=n.find(".k-draghandle").attr("tabIndex",0).on(h,(o=e._hsvKeydown,a=e,function(){return o.apply(a,arguments)})),r=this.value();var o,a;function s(t,n){var i,r,o=this.offset,a=t-o.left,s=n-o.top,l=this.width,c=this.height;i=(a=a<0?0:a>l?l:a)/l,r=1-(s=s<0?0:s>c?c:s)/c,e._svChange(i,r)}r&&r.indexOf("rgba")>-1&&(r=r.replace("rgba","RGBA")),this._hsvDragAriaTemplate||(this._hsvDragAriaTemplate=t.template(this.options.hsvDragARIATemplate)),i.attr("aria-label",this._hsvDragAriaTemplate(r||"")),e._hsvEvents=new t.UserEvents(n,{global:!0,press:function(e){this.offset=t.getOffset(n),this.width=n.width(),this.height=n.height(),i.trigger("focus"),s.call(this,e.x.location,e.y.location)},start:function(){n.addClass("k-dragging"),i.trigger("focus")},move:function(e){e.preventDefault(),s.call(this,e.x.location,e.y.location)},end:function(){n.removeClass("k-dragging")}}),e._hsvRect=n,e._hsvHandle=i},_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))}const o=e.options._showAdaptiveView?"horizontal":"vertical";function a(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:o,slide:r,change:r}).data("kendoSlider"),i.attr("aria-label","opacity"),e._opacitySlider=i.kendoSlider({min:0,max:100,tickPlacement:"none",showButtons:!1,orientation:o,slide:a,change:a}).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>")),h="";h+=l({messages:n.options.messages,ratio:s}),h+=d({messages:n.options.messages,ratio:s,limit:4.5,level:"AA"}),h+=d({messages:n.options.messages,ratio:s,limit:7,level:"AAA"}),n._contrastTool.find(".k-contrast-ratio, div").remove(),n._contrastTool.append(h),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 ${t.options._showAdaptiveView?"right":"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()},_addSizeClass:function(e){const t=this.options;this.wrapper.removeClass("k-colorgradient-lg k-colorgradient-md k-colorgradient-sm");let n=e||t.size;if(n){let e="k-colorgradient-";switch(n){case"large":e+="lg";break;case"small":e+="sm";break;default:e+="md"}this.wrapper.addClass(e)}},_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,this._addSizeClass()},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,u.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",h="focus"+d,u="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",size:"medium"},_attachEvents:function(){var e=this;e.wrapper.on(u,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(h,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),h=e.keyCode;if(d&&(i=Array.prototype.indexOf.call(d.parentNode.children,d)),h==r.LEFT)t=d?d.previousSibling:a[a.length-1];else if(h==r.RIGHT)t=d?d.nextSibling:a[0];else if(h==r.DOWN)n=d&&d.parentNode.nextSibling?d.parentNode.nextSibling.children[i]:null,t=d?n:a[0];else if(h==r.UP)n=d&&d.parentNode.previousSibling?d.parentNode.previousSibling.children[i]:null,t=d?n:a.get[a.length-1];else if(h==r.ENTER){if(g(e),d)return this._select(d),void this.trigger("forceSelect",{value:this.value()})}else h==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()||"")))},_addSizeClass:function(e){const t=this.options;this.wrapper.removeClass("k-colorpalette-lg k-colorpalette-md k-colorpalette-sm");let n=e||t.size;if(n){let e="k-colorpalette-";switch(n){case"large":e+="lg";break;case"small":e+="sm";break;default:e+="md"}this.wrapper.addClass(e)}},_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._addSizeClass(),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,h=n.colorpicker.ColorSelector,u=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=h.extend({init:function(e,n){var i=this;n&&!1===n.autoupdate&&(n._standalone=!1),h.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;h.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,_showAdaptiveView:!1},setBackgroundColor:function(e){var t=this;t._view&&t._view.setBackgroundColor&&t._view.setBackgroundColor(e)},_attachEvents:function(){var t=this;var n,i;t.wrapper.on(d,(n=t._keydown,i=t,function(){return n.apply(i,arguments)})).on(c,".k-button[data-command]",(function(){t._clearColor=!0,t._updateUI(null),t._view.value(null)})).on(c,".k-coloreditor-apply",(function(){t._clearColor?t._select(null):t._select(t._view.color())})).on(c,".k-coloreditor-cancel",(function(){delete t._clearColor,t._updateUI(t.color()),t._cancel()})).on(c,".k-button[data-view]",(function(n){var i=e(n.target).closest("[data-view]");i.is("."+f)||(t.wrapper.find(".k-button[data-view]").removeClass(f).attr(g,!1),i.addClass(f).attr(g,!0),t._changeView(i.data("view")))}))},_select:function(e){h.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;const l=a._showAdaptiveView?"large":a.size;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,size:l}),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==u.ESC&&this._cancel()},_template:function(){var e=this.options,n=o({},e,{fillMode:"flat",themeColor:"base",rounded:"medium",size:e._showAdaptiveView?"large":e.size});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-start k-actions-horizontal">'+i.renderButton(`<button class="k-coloreditor-apply" title="${a(e.messages.apply)}">${a(e.messages.apply)}</button>`,o({},t,{fillMode:"solid",themeColor:"primary"}))+i.renderButton(`<button class="k-coloreditor-cancel" title="${a(e.messages.cancel)}">${a(e.messages.cancel)}</button>`,o({},t,{fillMode:"solid"}))+"</div>":"")))(e,n)},_addSizeClass:function(e){const t=this.options;this.wrapper.removeClass("k-coloreditor-lg k-coloreditor-md k-coloreditor-sm");let n=e||t.size;if(n){let e="k-coloreditor-";switch(n){case"large":e+="lg";break;case"small":e+="sm";break;default:e+="md"}this.wrapper.addClass(e)}},_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,this._addSizeClass()}});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,h=n.FlatColorPicker;var u=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"}));var 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._bindMediaQueries(),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()},_adaptiveView:function(){const e=this;e._popup?e._popup.fullscreen?e._showAdaptiveView||(e._popup.wrapper&&e._popup.wrapper.remove(),e._popup.destroy(),e._popup=null):(e._popup.destroy(),e._popup=null,e._getPopup()):e._getPopup(),e._toggleAdaptiveModeSizeClasses(e._showAdaptiveView)},_toggleSizeClassesForElement:function(e,t,n){if(e&&e.length){if(e.data("handler")&&e.data("handler")._addSizeClass)return t?e.data("handler")._addSizeClass(t):e.data("handler")._addSizeClass();e.is("."+n)||(e=e.closest("."+n)),e.removeClass(`${n}-sm ${n}-md ${n}-lg`),t&&e.addClass(`${n}-${t}`)}},_toggleAdaptiveModeSizeClasses:function(e){const t=this;const n=t._popup&&t._popup.wrapper;const i="large";const r="k-coloreditor",o="k-colorgradient",a="k-colorpalette";const s=n&&n.length&&n.find("."+r);const l=n&&n.length&&n.find("."+o);const c=n&&n.length&&n.find("."+a);e?(t._toggleSizeClassesForElement(s,i),t._toggleSizeClassesForElement(l,i),t._toggleSizeClassesForElement(c,i)):(t._toggleSizeClassesForElement(s),t._toggleSizeClassesForElement(l),t._toggleSizeClassesForElement(c))},_bindMediaQueries:function(){const e=this;"auto"===e.options.adaptiveMode?(e.largeMQL=t.mediaQuery("large"),e.mediumMQL=t.mediaQuery("medium"),e.smallMQL=t.mediaQuery("small"),e.smallMQL.onEnter((()=>{e._showAdaptiveView=!0,e._adaptiveView(),e._popup.fullscreen(!0)})),e.mediumMQL.onEnter((()=>{e._showAdaptiveView=!0,e._adaptiveView(),e._popup.fullscreen(!1)})),e.largeMQL.onEnter((()=>{e._showAdaptiveView=!1,e._adaptiveView()}))):(e.smallMQL&&e.smallMQL.destroy(),e.mediumMQL&&e.mediumMQL.destroy(),e.largeMQL&&e.largeMQL.destroy(),e._showAdaptiveView=!1)},_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",adaptiveMode:"none",adaptiveTitle:null,adaptiveSubtitle:null},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))},_actionFooterButtons:function(){const e=[{command:"cancel",text:"Cancel",size:"large",fillMode:this.options.fillMode,themeColor:"base"},{command:"apply",text:"Apply",size:"large",fillMode:this.options.fillMode,themeColor:"primary"}];let n="";return e.forEach((e=>{const i=e.command;const r=e.text;delete e.command,delete e.text,n+=t.html.renderButton(`<button data-command=${i}>${r}</button>`,e)})),n},_actionSheetApply:function(){const e=this._selector;e._clearColor?e._select(null):e._select(e._view.color())},_actionSheetCancel:function(){const e=this._selector;delete e._clearColor,e._updateUI(e.color()),e._cancel()},_getPopup:function(){var n=this,i=n._popup;const a=n._showAdaptiveView;if(!i){var s=n.options;var l;l=h,s.autoupdate=!0!==s.buttons&&!a,s._showAdaptiveView=a,delete s.select,delete s.change,delete s.cancel,s._otOfPicker=!1;var c=t.guid();var d=e(`<div id="${c}" class=${a?"":"k-colorpicker-popup"}></div>`).appendTo(document.body);var u=n._selector=new l(e("<div></div>").appendTo(d),{...s,buttons:!a&&s.buttons,value:a?n._value:n.options.value});n.wrapper.attr("aria-controls",c),a?(n._popup=i=d.kendoActionSheet({adaptive:!0,closeButton:{icon:"check",themeColor:"primary"},hideOverflowContent:!0,title:s.adaptiveTitle?t.htmlEncode(s.adaptiveTitle):"Choose Color",subtitle:s.adaptiveSubtitle?t.htmlEncode(s.adaptiveSubtitle):"",footerTemplate:n._actionFooterButtons()}).data("kendoActionSheet"),i._footer.addClass("k-actions k-actions-horizontal k-actions-stretched"),i._footer.on("click","button[data-command]",(function(t){switch(e(t.currentTarget).data("command")){case"apply":n._actionSheetApply();break;case"cancel":n._actionSheetCancel()}}))):n._popup=i=d.kendoPopup({anchor:n.wrapper,adjustSize:{width:5,height:0}}).data("kendoPopup"),u.bind({select:function(e){n._updateUI(o(e.value),!0)},change:function(e){n.options.buttons||a?n._select(u.color()):n._updateUI(o(e.value),!0),(n.options.buttons||a||"palette"===n._selector.options.view&&n.options.closeOnSelect)&&n.close()},cancel:function(){n.close()}}),i.bind({close:function(t){if(n.trigger("close"))return void t.preventDefault();n.wrapper.removeClass("k-focus");var i=u.color();n.options.buttons&&a?n._select(n.color()):n._select(i),(i=n.color())&&i.h&&(n._cachedHue=i.h);const r=a?".k-actionsheet":".k-colorpicker-popup";event&&event instanceof MouseEvent&&0===e(event.target).parents(r).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();a&&function(e){const t=e._view;t&&(t._hueSlider&&t._hueSlider.resize(),t._opacitySlider&&t._opacitySlider.resize())}(u),t&&(t=t.toHSV(),e=r.fromHSV(n._cachedHue||0,t.s,t.v,t.a),t=t.equals(e)?e:t),u.value(t),u.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(u),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),h=n._outerHeight,u=i.Widget,p=/^(a|div)$/i,f=/^(a|div|button)$/i,m=".kendoTabStrip",g="href",v="prev",_="next",b="show",w="k-link",y="k-link-text",k="k-last",x="click",C="k-image",S="k-first",T="select",M="activate",A="k-tabstrip-content",D="contentUrl",E="mouseenter",I="contentLoad",z="k-disabled",P="k-active",L="k-focus",B="k-hover",H="EMPTY_URL",R=".k-item.k-tabstrip-item:not(."+z+")",F=".k-item.k-tabstrip-item",O=".k-tabstrip-items > "+R+":not(."+P+")",V="aria-hidden",N="aria-controls",$="aria-disabled",U="aria-selected",W="aria-labelledby",j={content:e=>`<div class='k-tabstrip-content' ${e.contentAttributes(e)} tabindex='0'>${e.content(e.item)}</div>`,textWrapper:({tag:e,item:t,contentUrl:i,textAttributes:r,image:o,sprite:a,text:s})=>`<${e(t)} class='${w}' ${i(t)} ${r(t)}>${o(t)}${a(t)}`+((t.icon||t.iconClass)&&"before"===t.iconPosition?n.ui.icon({icon:t.icon||"none",iconClass:t.iconClass}):"")+`<span class='${y}'>${s(t)}</span>`+((t.icon||t.iconClass)&&"after"===t.iconPosition?n.ui.icon({icon:t.icon||"none",iconClass:t.iconClass}):"")+`</${e(t)}>`,item:e=>j.itemWrapper(e,`${e.textWrapper(e)}`),itemWrapper:(e,t)=>`<li class='${e.wrapperCssClass(e.group,e.item)}' ${e.itemAttributes(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:()=>"",itemActionsWrapperTemplate:()=>'<span class="k-item-actions"></span>',itemActionTemplate:({element:t,icon:i,iconClass:r,attributes:o})=>{let a=o?o.toJSON?o.toJSON():o:{};return n.html.renderButton(t||e("<button unselectable='on'></button>").attr(a),{icon:i,iconClass:r,themeColor:"base",fillMode:"flat"})}},q={wrapperCssClass:function(e,t){var n=["k-item","k-tabstrip-item"],i=t.index;const r=t.attributes&&t.attributes.class||"";return!1===t.enabled&&n.push("k-disabled"),0===i&&n.push("k-first"),i==e.length-1&&n.push("k-last"),r.split(" ").forEach((function(e){e&&!n.includes(e)&&n.push(e)})),n.join(" ")},itemAttributes:function(e){const t=e.attributes||{};return Object.entries(t).map((([e,t])=>"class"===e||"role"===e||"aria-selected"===e?"":`${e}='${n.htmlEncode(t)}'`)).join(" ")},textAttributes:function(e){return e.url?" href='"+n.sanitizeLink(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?"":" "},contentUrl:function(e){return e.contentUrl?n.attr("content-url")+'="'+e.contentUrl+'"':""}};function G(t,n){t.children("img").addClass(C),t.children("a").addClass(w).children("img").addClass(C),t.filter("li[disabled]").addClass(z).attr($,"true").prop("disabled",!1),t.filter(":not([class*=k-state])").children("a").filter(":focus").parent().addClass(P),t.attr("role","tab"),t.each((function(){var t=e(this);t.attr(U,t.is("."+P));const i=n._enableDOMDataSource?f:p;t.children("."+w).length||t.contents().filter((function(){return!(this.nodeName.match(i)||3==this.nodeType&&!s(this.nodeValue))})).wrapAll("<span UNSELECTABLE='on' class='"+w+"'/>").wrapAll("<span UNSELECTABLE='on' class='"+y+"'/>")}))}function K(e){const t=e.children(".k-item.k-tabstrip-item");t.filter(".k-first:not(:first-child)").removeClass(S),t.filter(".k-last:not(:last-child)").removeClass(k),t.filter(":first-child").addClass(S),t.length>1&&t.filter(":last-child").addClass(k)}function Y(e,t){return`<span aria-hidden='true' 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 Q(){return e.ajaxSettings.xhr()}var X=u.extend({init:function(e,t){var i,r=this;u.fn.init.call(r,e,t),r._animations(r.options),t=r.options,n.isPresent(X._enableDOMDataSource)&&(t._enableDOMDataSource=X._enableDOMDataSource),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||t._enableDOMDataSource)&&r.dataSource.fetch(),r._removeAdditionalWrapperClasses(),r._tabSizes(),r._tabPosition(),r._scrollable(),r._tabAlignment(),r._sortable(),r._processContentUrls(),r._attachEvents(),r.options.value&&(i=r.options.value),r._initialActivate(),r.value(i),n.notify(r),t._enableDOMDataSource&&t.contentUrls&&(r._contentUrls=t.contentUrls.map((function(e){return e||H})),r._updateContentElements(t._enableDOMDataSource)),r._showWatermarkOverlay&&r._showWatermarkOverlay(r.element[0])},events:[T,M,b,"error",I,"change","dataBinding","dataBound"],options:{name:"TabStrip",dataEncodedField:"",dataTextField:"",dataContentField:"",dataImageUrlField:"",dataUrlField:"",dataSpriteCssClass:"",dataContentUrlField:"",dataIconField:"icon",dataIconPositionField:"iconPosition",tabPosition:"top",tabAlignment:"start",size:"medium",tabTemplate:null,animation:{open:{effects:"expand:vertical fadeIn",duration:200},close:{duration:200}},closable:!1,collapsible:!1,navigatable:!0,contentUrls:!1,applyMinHeight:!0,scrollable:{distance:200,scrollButtonsPosition:"split",scrollButtons:"auto"},sortable:!1,_enableDOMDataSource:!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"+m,t._keyDownProxy):t.tabGroup.off("keydown"+m,t._keyDownProxy),u.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("."+P),d=s.index(e);o=l(a?o:l({reverse:!0},r),{hide:!0}),n.size(r.effects)?(c.kendoRemoveClass(P,{duration:o.duration}),e.kendoRemoveClass(B,{duration:o.duration})):(c.removeClass(P),e.removeClass(B));var u=t.contentAnimators;if(t.inRequest&&(t.xhr.abort(),t.inRequest=!1),0===u.length)return t.tabGroup.find("."+P),e.addClass(P),t._current(e,!0),t.trigger("change"),t._scrollableModeActive&&t._scrollTabsToItem(e),!1;var p=u.filter("."+P),f=t.contentHolder(d),m=f.closest(".k-tabstrip-content");if(t.tabsHeight=h(t.tabGroup)+parseInt(t.wrapper.css("border-top-width"),10)+parseInt(t.wrapper.css("border-bottom-width"),10),0===f.length)return p.removeClass(P).attr(V,!0).kendoStop(!0,!0).kendoAnimate(o),!1;e.attr("data-animating",!0);var g=!(!e.children("."+w).data(D)&&!t._contentUrls[d])&&f.is(":empty"),v=function(){c.attr(U,!1),e.attr(U,!0),t.tabGroup.attr("aria-activedescendant",e.attr("id")),t._current(e,!0),m.addClass(P).removeAttr(V).kendoStop(!0,!0).kendoAnimate(l({init:function(){t.trigger(b,{item:e[0],contentElement:f[0]}),n.resize(f)}},r,{complete:function(){t.element.css("min-height",y),e.removeAttr("data-animating"),t.trigger(M,{item:e[0],contentElement:f[0]}),n.resize(f)}}))},_=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)};var y=t.element.css("min-height");return t.options.applyMinHeight&&t.element.css("min-height",t.element.outerHeight()),p.removeClass(P),t.tabGroup.find("."+P),n.size(r.effects)?e.kendoAddClass(P,{duration:r.duration}):e.addClass(P),p.attr(V,!0),p.length?p.kendoStop(!0,!0).kendoAnimate(l({complete:_},o)):_(),!0}},ajaxRequest:function(t,i,r,o){t=this.tabGroup.find(t);var a=this,s=t.find("."+w);o=o||s.data(D)||a._contentUrls[t.index()]||s.attr(g),a.inRequest=!0;var l={type:"GET",cache:!1,url:o,dataType:"html",data:{},xhr:Q,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(I,{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)})),K(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;var o=e(this.tabGroup.children()[i]).attr(N);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(P,{duration:r.duration}):e.removeClass(P),e.attr(U,!1),t.tabGroup.removeAttr("aria-activedescendant"),t.contentAnimators.filter("."+P).kendoStop(!0,!0).kendoAnimate(o).removeClass(P).attr(V,!0)},_removeAdditionalWrapperClasses:function(){this.wrapper.removeClass("k-tabstrip-sm k-tabstrip-md k-tabstrip-lg"),this.tabGroup.removeClass("k-tabstrip-items-start k-tabstrip-items-center k-tabstrip-items-end k-tabstrip-items-justify k-tabstrip-items-stretched")},destroy:function(){var e=this;const t=e.options.scrollable&&"hidden"===e.options.scrollable.scrollButtons;u.fn.destroy.call(e),e._refreshHandler&&e.dataSource.unbind("change",e._refreshHandler),e.options.scrollable&&t&&e.tabGroup.unbind("scroll"+m),e._removeAdditionalWrapperClasses(),e.wrapper.off(m),e.tabGroup.off(m),e._scrollableModeActive&&!t&&(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(N)+"']");return a(r.tabs,(function(t){var a=r.contents[t];var 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())})),K(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(N)+"']");return a(r.tabs,(function(t){var a=r.contents[t];var 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())})),K(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),h=n.getter(a.dataImageUrlField),u=n.getter(a.dataUrlField),p=n.getter(a.dataSpriteCssClass),f=n.getter(a.dataIconField),m=n.getter(a.dataIconPositionField),g=[],v=o.dataSource.view();const _=o._enableDataSourceFromDOM;const b=o.dataSource._pristineData;for((e=e||{}).action&&(v=e.items),t=0,r=v.length;t<r;t++){if(i={text:v[t]&&v[t].text||l(v[t])},a.tabTemplate&&(i.model=v[t],i.template=a.tabTemplate),a.dataEncodedField&&(i.encoded=s(v[t])),a.dataContentField&&(i.content=c(v[t])),a.dataContentUrlField&&(i.contentUrl=d(v[t])),a.dataUrlField&&(i.url=u(v[t])),a.dataImageUrlField&&(i.imageUrl=h(v[t])),a.dataSpriteCssClass&&(i.spriteCssClass=p(v[t])),v[t].actions){const e="object"==typeof v[t].actions?Array.from(v[t].actions):v[t].actions;i.actions=e}(f(v[t])||v[t].iconClass)&&(i.icon=f(v[t]),i.iconClass=v[t].iconClass,i.iconPosition=m(v[t])??"before"),i.enabled=v[t].enabled,i.closable=v[t].closable??a.closable,b&&(i.attributes=b[t].attributes),v[t].content&&(i.content=v[t].content),g[t]=i}if("add"==e.action)e.index<o.tabGroup.children().length?o.insertBefore(g,o.tabGroup.children().eq(e.index)):o.append(g);else if("remove"==e.action)for(t=0;t<v.length;t++)o.remove(e.index);else"itemchange"==e.action?(t=o.dataSource.view().indexOf(v[0]),e.field===a.dataTextField&&o.tabGroup.children().eq(t).find(".k-link").text(v[0].get(e.field)),e.field===a.dataUrlField&&(o._contentUrls[t]=v[0].get(e.field))):_&&n.isPresent(o.dataSource)?(o._wrapExistingDOMItems(),o._updateContentElements(),o._enableDataSourceFromDOM=!1):(o.trigger("dataBinding"),o.remove("li"),o._contentUrls=[],o.append(g),o.trigger("dataBound"))},_wrapExistingDOMItems:function(){const e=this;const t=e.tabGroup.children("li");e.dataSource.view().forEach(((i,r)=>{const o=t.eq(r);const a=o.find("."+w);const s=a.find("."+y);const l=n.isPresent(i.actions)&&i.actions.length||i.closable||!i.closable&&e.options.closable;i.contentUrl&&a.attr("data-content-url",i.contentUrl),e.options.contentUrls||e._contentUrls.push(i.contentUrl||H),(i.icon||i.iconClass)&&("before"===i.iconPosition&&a.prepend(n.ui.icon({icon:i.icon||"none",iconClass:i.iconClass})),"after"===i.iconPosition&&a.append(n.ui.icon({icon:i.icon||"none",iconClass:i.iconClass})));let c="";if(i.imageUrl&&(c+=j.image({imageUrl:i.imageUrl})),i.spriteCssClass&&(c+=j.sprite({spriteCssClass:i.spriteCssClass})),a.prepend(c),l&&e._initTabActions(o,i),i.text){const e=i.encoded?n.htmlEncode(i.text):i.text;s.text(e)}if(o.attr("data-content")&&!i.contentUrl){e.contentElements.eq(r).text(i.content)}i.hasOwnProperty("enabled")?i.enabled?o.removeClass(z).attr($,!0):o.addClass(z).removeAttr($,!1):o.hasClass(z)&&o.addClass(z).removeAttr($,!1)}))},reload:function(t){t=this.tabGroup.find(t);var n=this;var i=n._contentUrls;return t.each((function(){var t=e(this),r=t.find("."+w).data(D)||i[t.index()],o=n.contentHolder(t.index());r&&n.ajaxRequest(t,o,null,r)})),n},remove:function(t){var i=this;var r=typeof t;var o;return"string"===r?t=i.tabGroup.find(t):"number"===r&&(t=i.tabGroup.children().eq(t)),o=t.map((function(){var t=e(this).index();var r=i.contentElement(t);return n.destroy(r),i._removeUrlItem(t),r})),t.remove(),o.empty(),o.remove(),i._updateContentElements(),i.resize(!0),i},select:function(t){var n=this;return 0===arguments.length?n.tabGroup.children("li."+P):(isNaN(t)||(t=n.tabGroup.children().get(t)),t=n.tabGroup.find(t),e(t).each((function(t,i){(i=e(i)).hasClass(P)||n.trigger(T,{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)}))},_initTabActions:function(t,n){const i=this;const r=e(t);let o=[];let a=n.closable;let s={icon:"x",attributes:{"ref-close-button":!0},action:i._handleClose};if(n.actions&&(o=Array.from(n.actions)),a&&o.push(s),o?.length){const t=e(j.itemActionsWrapperTemplate());const n=r.find("button");o.forEach(((r,o)=>{const s=a&&o>n.length-1;n.length&&!s&&(r.element=n.eq(o));const l=e(j.itemActionTemplate(r));n.length||t.append(l),s&&n.length&&n.parent().append(l),c(r?.action)&&(!n.length||s?l.bind(x,r.action.bind(i)):n.eq(o).bind(x,r.action.bind(i)))})),n.length?n.wrapAll(t):r.append(t)}return r[0]},_handleClose:function(t){const n=this;const i=e(t.currentTarget).closest(".k-item");i.hasClass(P)&&(i.prev().length>0?n.activateTab(i.prev()):n.activateTab(i.next())),n.remove(i)},_tabAlignment:function(){const e=this;let t=e.options.tabAlignment;e._scrollableModeActive&&(t="start"),e.tabGroup.addClass("k-tabstrip-items-"+t)},_active:function(){var e=this;setTimeout((function(){var t=e.tabGroup.children().filter("."+P);(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 t=this,n=t.options;t.tabGroup.on(x+m,".k-disabled .k-link",!1).on(x+m," > "+R,t._itemClick.bind(t)),t.wrapper.on("focus"+m,(function(){t.tabGroup.trigger("focus")})),n.scrollable&&"hidden"===n.scrollable.scrollButtons&&t.tabGroup.bind("scroll",(function(e){t._toggleScrollButtons()})),t.tabGroup.on(E+m+" mouseleave"+m,O,t._toggleHover).on("focus"+m,t._active.bind(t)).on("blur"+m,(function(){t._current(null)})),t._keyDownProxy=t._keydown.bind(t),n.navigatable&&t.tabGroup.on("keydown"+m,t._keyDownProxy),e(window).on("resize"+m,t._resize.bind(t))},_click:function(e){var t,n,i=this,r=e.find("."+w),o=r.attr(g),a=i.options.collapsible,s=e.index(),l=i.contentHolder(s),c=e.parent().children().filter("."+L);if(e.closest(".k-tabstrip")[0]==i.wrapper[0]){if(e.is("."+z+(a?"":",."+P)))return c.removeClass(L),i._focused=e,e.addClass(L),i._current(e),i._scrollableModeActive&&i._scrollTabsToItem(e),!0;if(n=r.data(D)||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(T,{item:e[0],contentElement:l[0]}))return!0;if(!1!==t)return a&&e.is("."+P)?(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){s._appendUrlItem(t[i].contentUrl||null);const r=X.renderItem({group:s.tabGroup,item:l(n,{index:i})});return n.closable=n.closable??s.options.closable,e(s._initTabActions(r,n))})),r=o(t,(function(t,i){if("string"==typeof t.content||t.contentUrl){let r=e(X.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(N)+"']");a=t}else a=e("<div class='"+A+"'/>");r=r.add(a)})),G(i,s.options)),{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(L),e&&!n&&e.addClass(L),this._focused=e},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e.dataSource.unbind("change",e._refreshHandler):e._refreshHandler=e.refresh.bind(e);const t=e.options.dataSource||e._createDataSourceFromDOM();e.dataSource=n.data.DataSource.create(t).bind("change",e._refreshHandler)},_createDataSourceFromDOM:function(){const n=this;const i=[];const r=n.options._enableDOMDataSource;const o=["text","content","icon","iconPosition","iconClass","spriteCssClass","imageUrl","contentUrl","encoded","closable","actions","enabled"];const a=["icon","iconClass","text","action"];if(!r)return n.options.dataSource;const s=n.tabGroup.children("li");const l=n.contentElements;return n._enableDataSourceFromDOM=s.length>0,s.each((function(r,s){const c=e(s);const d=c.find("button");const h={};o.forEach((function(i){let o=c.data(i);if("text"!==i||o||(o=c.find(".k-link-text").text().trim()),"content"===i&&!o){const t=e(l[r]);t.length&&(o=t.html())}"closable"===i&&o===t&&(o=n.options.closable),o!==t&&(h[i]=o)})),h.iconPosition===t&&(h.iconPosition="before"),d.length&&(h.actions=[],n._decorateActions(d,a,h)),i.push(h)})),i},_decorateActions:function(i,r,o){i.each((function(i,a){const s=e(a);const l={};r.forEach((function(e){let i=s.data(e);if("text"!==e||i||(i=n.htmlEncode(s.text().trim())),"action"===e&&"string"==typeof i){let e=window[i];"function"==typeof e&&(i=e)}i!==t&&(l[e]=i)}),this),o.actions.push(l)}))},_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(R)[e]()},_getItem:function(e){return this.tabGroup.children(F)[e]()},_initialActivate:function(){var e=this,t=e.tabGroup.children("li."+P),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===v?"last":"first",e?((e=e[t]())[0]||(e=this.tabGroup.children(F)[n]()),e.hasClass(z)&&e.addClass(L),(e.hasClass(z)||e.hasClass(P))&&(this._focused=e),e):this._endItem(n)},_itemClick:function(t){var i=this.tabGroup[0];if(!t.target.closest(".k-item-actions")){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?v:_;else if(i===r.LEFT&&s)t=a?_:v;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=v;else t=_;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.k-tabstrip-item").each((function(n,i){var r=t._contentUrls[n];"string"==typeof r&&e(i).find(">."+w).data(D,r)})):t._contentUrls.length=t.tabGroup.find("li.k-item.k-tabstrip-item").length},_removeUrlItem:function(e){this._contentUrls.splice(e,1)},_resize:function(){this._scrollable()},_getChildrenWidth:function(t){let n=0;return t.children().each((function(){n+=d(e(this))})),Math.floor(n)},_getChildrenHeight:function(t){let n=0;return t.children().each((function(){n+=h(e(this))})),Math.floor(n)},_scrollable:function(){const e=this,t=e.options,i=t.scrollable.scrollButtonsPosition,r=t.scrollable.scrollButtons,o="top"==t.tabPosition||"bottom"==t.tabPosition,a="hidden"===r,s="visible"===r;let l,c,d,h;if(e._scrollableAllowed()){e.wrapper.addClass("k-tabstrip-scrollable"),l=o?e.wrapper[0].offsetWidth:e.wrapper[0].offsetHeight,c=o?e.tabGroup[0].scrollWidth:e.tabGroup[0].scrollHeight;const r=o?e._getChildrenWidth(e.tabGroup)>e.tabGroup.outerWidth():e._getChildrenHeight(e.tabGroup)>e.tabGroup.outerHeight();const u=c>l||r;if(u&&!e._scrollableModeActive&&a)e.tabGroup.addClass("k-tabstrip-items-scroll"),e.wrapper.addClass("k-tabstrip-scrollable-overlay"),e._scrollableModeActive=!0,e._toggleScrollButtons();else if(!u&&!s||e._scrollableModeActive)!e._scrollableModeActive||u||s?e._scrollableModeActive||s?e._toggleScrollButtons():e._removeScrollableClasses():(e._scrollableModeActive=!1,e._removeScrollableClasses(),e._scrollPrevButton&&e._scrollPrevButton.off().remove(),e._scrollNextButton&&e._scrollNextButton.off().remove());else{e._nowScrollingTabs=!1,e._isRtl=n.support.isRtl(e.element);const r=n.support.touch?"touchstart":"mousedown";const a=n.support.touch?"touchend":"mouseup";const s=n.support.browser;const l=e._isRtl&&!s.msie&&!s.edge;const c=o?"caret-alt-right":"caret-alt-down";const u=Y("prev",o?"caret-alt-left":"caret-alt-up");const p=Y("next",c);switch(i){case"split":e.tabWrapper.prepend(u),e.tabWrapper.append(p);break;case"start":e.tabWrapper.prepend(p),e.tabWrapper.prepend(u);break;case"end":e.tabWrapper.append(u),e.tabWrapper.append(p)}d=e._scrollPrevButton=e.tabWrapper.children(".k-tabstrip-prev"),h=e._scrollNextButton=e.tabWrapper.children(".k-tabstrip-next"),d.on(r+m,(function(){e._nowScrollingTabs=!0,e._scrollTabsByDelta(t.scrollable.distance*(l?1:-1))})),h.on(r+m,(function(){e._nowScrollingTabs=!0,e._scrollTabsByDelta(t.scrollable.distance*(l?-1:1))})),d.add(h).on(a+m,(function(){e._nowScrollingTabs=!1})),e._scrollableModeActive=!0,e._toggleScrollButtons()}}},_removeScrollableClasses:function(){const e=this;const t="hidden"===e.options.scrollable.scrollButtons;e.wrapper.removeClass("k-tabstrip-scrollable"),t&&(e.wrapper.removeClass("k-tabstrip-scrollable-overlay"),e.wrapper.removeClass("k-tabstrip-scrollable-start"),e.wrapper.removeClass("k-tabstrip-scrollable-end"),e.tabGroup.removeClass("k-tabstrip-items-scroll"))},_scrollableAllowed:function(){var e=this.options;return e.scrollable&&!e.scrollable.distance&&(e.scrollable={distance:200}),e.scrollable&&!isNaN(e.scrollable.distance)},_scrollTabsToItem:function(e){var t,i=this,r=i.tabGroup,o="top"==i.options.tabPosition||"bottom"==i.options.tabPosition,a=o?n.scrollLeft(r):r.scrollTop(),s=o?d(e):h(e),l=o?i._isRtl?e.position().left:e.position().left-r.children().first().position().left:e.position().top,c=o?r[0].offsetWidth:r[0].offsetHeight,u=n.support.browser;i._isRtl&&o&&(u.mozilla||u.webkit&&u.version>=85)&&(a*=-1),i._isRtl&&o?l<0?t=a+l-(c-a):l+s>c&&(t=a+l-s):a+c<l+s?t=l+s-c:a>l&&(t=l);var p=o?{scrollLeft:t}:{scrollTop:t};r.finish().animate(p,"fast","linear",(function(){i._toggleScrollButtons()}))},_scrollTabsByDelta:function(e){const t=this;const i=t.tabGroup;const r="top"==t.options.tabPosition||"bottom"==t.options.tabPosition;let o=r?n.scrollLeft(i):i.scrollTop();const a=n.support.browser;t._isRtl&&r&&(a.mozilla||a.webkit&&a.version>=85)&&(o*=-1);var s=r?{scrollLeft:o+e}:{scrollTop:o+e};i.finish().animate(s,"fast","linear",(function(){t._nowScrollingTabs&&!jQuery.fx.off?t._scrollTabsByDelta(e):t._toggleScrollButtons()}))},_sortable:function(){var e=this,t=e.options,i=t.tabPosition,r=t.scrollable&&"hidden"===t.scrollable.scrollButtons,o="left"===i||"right"===i?"y":"x";e.options.sortable&&(e.sortable=new n.ui.Sortable(e.tabGroup,{filter:"li.k-item.k-tabstrip-item",axis:o,holdToDrag:r,allowTouchActions:r,container:e.tabWrapper,hint:e=>`<div id='hint' class='k-tabstrip k-tabstrip-${i}'>\n <div class= 'k-tabstrip-items-wrapper k-hstack'>\n <ul class='k-tabstrip-items k-reset'>\n <li class='k-item k-tabstrip-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)},_tabSizes:function(){let e;switch(this.options.size){case"small":e="k-tabstrip-sm";break;case"medium":e="k-tabstrip-md";break;case"large":e="k-tabstrip-lg"}this.wrapper.addClass(e)},_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(B,t.type==E)},_toggleDisabled:function(t,n){(t=this.tabGroup.find(t)).each((function(){e(this).toggleClass(z,!n).attr($,!n)}))},_toggleScrollButtons:function(){var e=this,t=e.tabGroup,i=Math.floor(n.scrollLeft(t)),r=Math.floor(t.scrollTop()),o=e.options.scrollable.scrollButtons,a="top"==e.options.tabPosition||"bottom"==e.options.tabPosition;const s=(a?Math.abs(i-(t[0].scrollWidth-t[0].offsetWidth)):Math.abs(r-(t[0].scrollHeight-t[0].offsetHeight)))<=1;const l=0===(a?i:r);"hidden"!==o?(e._scrollPrevButton.toggleClass("k-disabled",l),e._scrollNextButton.toggleClass("k-disabled",s)):(e.wrapper.toggleClass("k-tabstrip-scrollable-start",l),e.wrapper.toggleClass("k-tabstrip-scrollable-end",s))},_updateClasses:function(){var n,i,r,o=this;var 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 k-tabstrip-item")).length&&(r=(i=n.filter("."+P).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(A).eq(r).addClass(P).css({display:"block"}),n.length&&(G(n,o.options),i=n.filter("."+P).index(),o.tabGroup.attr("aria-activedescendant",n.eq(i).attr("id")),K(o.tabGroup),o._updateContentElements(!0))},_updateContentElements:function(t){var i=this,r=i._contentUrls,o=i.tabGroup.children(".k-item.k-tabstrip-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(N,r),i=a.id=s(e(a),n,!0),this.setAttribute(W,i)),this.setAttribute("id",r)})):(o.each((function(t){var n,o=a.eq(t),l=s(o,t);this.setAttribute(N,l),n=this.id=s(e(this),t,!0),!o.length&&r[t]?(e("<div class='"+A+"'/>").appendTo(i.wrapper).attr("id",l),r[t]==H&&(i._contentUrls[t]=null)):o.attr("id",l),o.attr("role","tabpanel"),o.attr("tabindex","0"),o.attr(W,n),o.filter(":not(."+P+")").attr(V,!0)})),i._removeEmptyUrls()),i.options._enableDOMDataSource&&t&&(o.each((function(t){let n=(a=i.wrapper.children("div:not(.k-tabstrip-items-wrapper)")).eq(t),o=s(n,t);this.setAttribute(N,o),!n.length&&r[t]&&(e("<div class='"+A+"'/>").appendTo(i.wrapper).attr("id",o),r[t]==H&&(i._contentUrls[t]=null)),n.attr("role","tabpanel"),n.attr("tabindex","0"),n.attr(W,undefined),n.filter(":not(."+P+")").attr(V,!0)})),i._removeEmptyUrls()),i.contentElements=i.contentAnimators=i.wrapper.children("div:not(.k-tabstrip-items-wrapper)"),i.tabsHeight=h(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"))},_removeEmptyUrls:function(){let e=this;e._contentUrls.length&&e._contentUrls.forEach((function(t,n){e._contentUrls[n]=t==H?null:t}))},_wrapper:function(){var e=this;e.element.is("ul")?e.wrapper=e.element.wrapAll("<div />").parent():e.wrapper=e.element}});l(X,{renderItem:function(e){e=l({tabStrip:{},group:{}},e);var t=j.empty,i=e.item,r=l(e,{image:i.imageUrl?j.image:t,sprite:i.spriteCssClass?j.sprite:t,textWrapper:j.textWrapper,itemActions:j.itemActionsWrapperTemplate},q);return i.template?j.itemWrapper(r,n.template(i.template)(i.model)):j.item(r)},renderContent:function(e){return j.content(l(e,q))}}),n.ui.plugin(X)}(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",h=t.support.mobileOS,u=h.ios&&!h.appMode&&h.flatVersion>=700;var p="k-pane",f="k-pane-wrapper",m="k-collapsible-pane";var 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,u&&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();var 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="kendoActionSheet",c="init",d="open",h="refresh",u="change",p=".kendoFilterMenu",f=".k-table-th",m="Is equal to",g="Is not equal to",v={number:"numerictextbox",date:"datepicker"},_={string:"text",number:"number",date:"date"},b=n.isFunction,w=i.Widget;var y=({actionsCssClass:e,messages:t,size:i})=>`<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",size:i})+n.html.renderButton(`<button title="${t.clear}">${o(t.clear)}</button>`,{type:"reset",icon:"filter-clear",size:i})+"</div>";var k=({field:e,format:t,ns:n,messages:i,extra:r,operators:a,type:s,role:l,values:c,componentType:d,isAdaptive:h})=>`<div class="k-filter-menu-container"><div class="k-filter-help-text">${o(i.info)}</div><label><input type="radio" class="k-radio ${h?"k-radio-lg":"k-radio-md"}" data-${n}bind="checked: filters[0].value" value="true" name="filters[0].value"/>${o(i.isTrue)}</label><label><input type="radio" class="k-radio ${h?"k-radio-lg":"k-radio-md"}" data-${n}bind="checked: filters[0].value" value="false" name="filters[0].value"/>${o(i.isFalse)}</label>${h?"":y({messages:i})}</div>`;var x=({field:e,format:t,ns:i,messages:r,extra:a,operators:s,type:l,role:c,values:d,componentType:h,isAdaptive:u})=>{var p=n.guid(),f=n.guid();return`<div class="k-filter-menu-container"><div><ul class="k-radio-list k-reset"><li><input type="radio" class="k-radio ${u?"k-radio-lg":"k-radio-md"}" id="${p}" ${u?'data-size="large"':""} data-${i}bind="checked: filters[0].value" value="true" name="filters[0].value" /><label class="k-radio-label" for="${p}">${o(r.isTrue)}</label></li><li><input type="radio" class="k-radio ${u?"k-radio-lg":"k-radio-md"}" id="${f}" data-${i}bind="checked: filters[0].value" value="false" name="filters[0].value" /><label class="k-radio-label" for="${f}">${o(r.isFalse)}</label></li></ul>${u?"":y({actionsCssClass:"k-columnmenu-actions",messages:r})}</div></div>`};var C=({field:e,format:t,ns:n,messages:i,extra:r,operators:a,type:s,role:l,values:c,componentType:d,isAdaptive:h})=>`<div class="k-filter-menu-container"><div class="k-filter-help-text">${o(i.info)}</div><label><span class="k-textbox k-input ${h?"k-input-lg":"k-input-md"} k-input-md k-rounded-md k-input-solid"><input class="k-input-inner" ${h?'data-size="large"':""} data-${n}bind="value: filters[0].value adaptiveMode: ${h?"auto":"none"}" name="filters[0].value"/></span></label>${h?"":y({messages:i})}</div>`;var S=({field:e,format:t,ns:i,messages:r,extra:a,operators:s,type:l,role:c,values:d,componentType:h,isAdaptive:u})=>'<div class="k-filter-menu-container">'+("classic"===h?`<div class="k-filter-help-text">${o(r.info)}</div>`:"")+`<select title="${r.operator}" data-${i}bind="value: filters[0].operator" ${u?'data-size="large"':""} data-${i}adaptive-mode="${u?"auto":"none"}" 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" ${u?'data-size="large"':""} data-${i}adaptive-mode="${u?"auto":"none"}" data-${i}value-field="value" data-${i}source='${n.stringify(d).replace(/\'/g,"'")}' 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" ${u?'data-size="large"':""} class="k-input-inner" type="text" data-${i}adaptive-mode="${u?"auto":"none"}" ${c?`data-${i}role="${c}"`:""} />`)+(a?(({ns:e,messages:t,componentType:n,isAdaptive:i})=>"modern"===n?`<ul data-${e}role="buttongroup" data-bind="events: { select: onLogicChange }"><li data-${e}value="and">${o(t.and)}</li><li data-${e}value="or">${o(t.or)}</li></ul>`:`<select title="${t.logic}" class="k-filter-and" ${i?'data-size="large"':""} data-${e}adaptive-mode="${i?"auto":"none"}" data-${e}bind="value: logic" data-${e}role="dropdownlist"><option value="and">${o(t.and)}</option><option value="or">${o(t.or)}</option></select>`)({ns:i,messages:r,componentType:h,isAdaptive:u})+`<select title="${r.additionalOperator}" ${u?'data-size="large"':""} data-${i}bind="value: filters[1].operator" data-${i}adaptive-mode="${u?"auto":"none"}" 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" ${u?'data-size="large"':""} data-${i}text-field="text" data-${i}adaptive-mode="${u?"auto":"none"}" data-${i}value-field="value" data-${i}source='${n.stringify(d).replace(/\'/g,"'")}' 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" ${u?'data-size="large"':""} class="k-input-inner" type="text" data-${i}adaptive-mode="${u?"auto":"none"}" ${c?`data-${i}role="${c}"`:""}/>`):"")+`${u?"":y({messages:r})}</div>`;var T=({field:e,title:t,format:i,ns:r,messages:s,extra:l,operators:c,filterMenuGuid:d,type:h,role:u,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"> </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>`;var M=({field:e,title:t,format:i,ns:r,messages:s,extra:l,operators:c,filterMenuGuid:d,type:h,role:u,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"> </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 A(t,n){t.filters&&(t.filters=e.grep(t.filters,(function(e){return A(e,n),e.filters?e.filters.length:e.field!=n})))}function D(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 E=w.extend({init:function(t,i){var r,o,a,s,l=this,c="string";for(o in(i=i||{}).componentType=i.componentType||"classic",w.fn.init.call(l,t,i),r=l.operators=i.operators||{},t=l.element,i=l.options,l.dataSource=B.create(i.dataSource),l.field=i.field||t.attr(n.attr("field")),(s=e(t.closest(f))).length?l.appendTo=s.find(i.appendTo):l.appendTo=e(i.appendTo),l.link=l._createLink()||e(),l.model=l.dataSource.reader.model,l._bindMediaQueries(),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(e){const t={field:l.field,operator:o||"eq",value:""};if(!l.form)return t;const i=l.form.find(".k-filter-menu-container").children().find("input");const r=i.first();const a=i.last();if(r.is(a)&&e)return t;const s=e?a:r;const c=n.widgetInstance(s);return c?{field:l.field,operator:o||"eq",value:c.value()}:t},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=b(r),a=n.attr("role");i.pane=i.options.pane,i.pane&&(i._isMobile=!0),o||(t=r||v[i.type]),i._isMobile?i._createMobileForm(t):i._createForm(t),i.form.on("submit"+p,i._submit.bind(i)).on("reset"+p,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 ${i._showAdaptiveView?"k-input-lg":"k-input-md"} k-rounded-md k-input-solid'></span>`)),i.refresh(),i.trigger(c,{field:i.field,container:i.form}),i.options.cycleForm&&n.cycleForm(i.form)},_adaptiveView:function(){const e=this;e.popup&&(e.popup.close(),e.popup.wrapper&&e.popup.wrapper.remove(),e.popup.destroy(),e.popup=null)},_createForm:function(t){var i=this,r=i.options,a=i.operators||{},c=i.type;const d=i._showAdaptiveView;if(a=a[c]||r.operators[c],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:c,role:t,values:D(r.values),componentType:i.options.componentType,isAdaptive:d})),r.appendToElement)i.element.append(i.form),i.popup=i.element.closest(".k-column-menu.k-popup").data(s);else if(d){const t=e("<div></div>").append(i.form).appendTo("body");i.popup=t[l]({anchor:i.link,copyAnchorStyles:!1,open:i._open.bind(i),activate:i._activate.bind(i),adaptive:!0,closeButton:!0,title:r.adaptiveTitle||"Filter by "+i.field,subtitle:r.adaptiveSubtitle,actionButtons:[{text:"Clear",icon:"filter-clear"},{text:"Filter",icon:"filter",themeColor:"primary"}],close:function(){i.options.closeCallback&&i.options.closeCallback(i.element)}}).data(l),i.popup.fullscreen(i.smallMQL.mediaQueryList.matches)}else 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"+p,i._keydown.bind(i))},_getTemplate:function(){var e=this,t=b(e.options.ui);return"boolean"===e.type?t?C:"modern"===e.options.componentType?x:k:S},_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?M:T)({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:_[s],values:D(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()})),i.view.bind("transitionEnd",(function(e){"show"===e.type&&i.trigger(d,{field:i.field,container:i.form})}))},_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"+p,t._click.bind(t)),e},_bindMediaQueries:function(){const e=this;"auto"===e.options.adaptiveMode?(e.largeMQL=n.mediaQuery("large"),e.mediumMQL=n.mediaQuery("medium"),e.smallMQL=n.mediaQuery("small"),e.smallMQL.onEnter((()=>{e._showAdaptiveView=!0,e.popup&&e.popup.visible()&&e.popup.fullscreen?e.popup.fullscreen(!0):e._adaptiveView()})),e.mediumMQL.onEnter((()=>{e._showAdaptiveView=!0,e.popup&&e.popup.visible()&&e.popup.fullscreen?e.popup.fullscreen(!1):e._adaptiveView()})),e.largeMQL.onEnter((()=>{e._showAdaptiveView=!1,e._adaptiveView()}))):(e.smallMQL&&e.smallMQL.destroy(),e.mediumMQL&&e.mediumMQL.destroy(),e.largeMQL&&e.largeMQL.destroy(),e._showAdaptiveView=!1)},refresh:function(){var e=this,t=e.dataSource.filter()||{filters:[],logic:"and"};var i=[e._defaultFilter()];var r=e._defaultFilter().operator;(e.options.extra||"isnull"!==r&&"isnullorempty"!==r&&"isnotnullorempty"!==r&&"isnotnull"!==r&&"isempty"!==r&&"isnotempty"!==r)&&i.push(e._defaultFilter(!0)),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");var i=e.form.find("["+t+"='buttongroup']").data("kendoButtonGroup");var 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");var i=e.sender.current().attr(t);this.set("logic",i)},destroy:function(){var e=this;w.fn.destroy.call(e),e.form&&(n.unbind(e.form),n.destroy(e.form),e.form.off(p),e.popup&&(e.popup.destroy(),e.popup=null),e.form=null),e.view&&(e.view.purge(),e.view=null),e.link.off(p),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(A(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;var n=t.view.element;if("boolean"===t.type){var i=n.find("[type='radio']:checked");var 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();var 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=!1;var n=!1;var i;return e.filters[0]&&(t="isnull"==(i=e.filters[0].operator)||"isnotnull"==i||"isnotempty"==i||"isempty"==i||"isnullorempty"==i||"isnotnullorempty"==i),e.filters[1]&&(n="isnull"==(i=e.filters[1].operator)||"isnotnull"==i||"isnotempty"==i||"isempty"==i||"isnullorempty"==i||"isnotnullorempty"==i),!this.options.extra&&t||this.options.extra&&(t||n)},_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&&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(){const t=this;t.form.find(":kendoFocusable").first().trigger("focus"),t.popup&&t.popup.wrapper.find("[ref-actionsheet-action-button]").bind("click",(function(n){e(n.currentTarget).hasClass("k-button-solid-primary")?t.form.trigger("submit"):t.form.trigger("reset")})),t.trigger(d,{field:t.field,container:t.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:[c,"change",d],options:{name:"FilterMenu",extra:!0,appendToElement:!1,adaptiveMode:"none",adaptiveTitle:null,adaptiveSubtitle:null,type:"string",operators:{string:{eq:m,neq:g,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:m,neq:g,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:m,neq:g,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:m,neq:g,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}});var I=".kendoFilterMultiCheck";function z(t,n){t.filters&&(t.filters=e.grep(t.filters,(function(e){return z(e,n),e.filters?e.filters.length:e.field==n&&"eq"==e.operator})))}function P(n){return"and"==n.logic&&n.filters.length>1?[]:n.filters?e.map(n.filters,(function(e){return P(e)})):n.value!==t?[n.value]:[]}function L(e,i){var r=n.getter(i,!0),o=[],a=0,s={};for(;a<e.length;){var l=e[a++],c=r(l);c===t||s.hasOwnProperty(c)||(o.push(l),s[c]=!0)}return o}var B=n.data.DataSource;var H=({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>`;var R=w.extend({init:function(t,i){var r;w.fn.init.call(this,t,i),i=this.options,this.element=e(t);var o=this.field=this.options.field||this.element.attr(n.attr("field"));var a=i.checkSource;var s,l;this._foreignKeyValues()?(this.checkSource=B.create(i.values),this.checkSource.fetch()):i.forceUnique?(delete(a=e.extend(!0,{},i.dataSource.options)).pageSize,this.checkSource=B.create(a),this.checkSource.reader.data=(s=this.checkSource.reader.data,l=this.field,function(e){return L(s(e),l)})):this.checkSource=B.create(a),this.dataSource=i.dataSource,this.model=this.dataSource.reader.model,this._bindMediaQueries(),this._parse=function(e){return e+""},this.model&&this.model.fields&&(o=this.model.fields[this.field])&&("number"==o.type?this._parse=function(e){return"string"==typeof e&&("null"===e.toLowerCase()||this._foreignKeyValues()&&""===e)?null:parseFloat(e)}:o.parse&&(this._parse=o.parse.bind(o)),this.type=o.type||"string"),(r=e(t.closest(f))).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)},_bindMediaQueries:function(){const e=this;"auto"===e.options.adaptiveMode?(e.largeMQL=n.mediaQuery("large"),e.mediumMQL=n.mediaQuery("medium"),e.smallMQL=n.mediaQuery("small"),e.smallMQL.onEnter((()=>{e._showAdaptiveView=!0,e.popup&&e.popup.visible()&&e.popup.fullscreen?e.popup.fullscreen(!0):e._adaptiveView()})),e.mediumMQL.onEnter((()=>{e._showAdaptiveView=!0,e.popup&&e.popup.visible()&&e.popup.fullscreen?e.popup.fullscreen(!1):e._adaptiveView()})),e.largeMQL.onEnter((()=>{e._showAdaptiveView=!1,e._adaptiveView()}))):(e.smallMQL&&e.smallMQL.destroy(),e.mediumMQL&&e.mediumMQL.destroy(),e.largeMQL&&e.largeMQL.destroy(),e._showAdaptiveView=!1)},_adaptiveView:function(){const e=this;e.popup&&(e.popup.close(),e.popup.wrapper&&e.popup.wrapper.remove(),e.popup.destroy(),e.popup=null)},_createLink:function(){var e=this.element;var t=this.appendTo.length?e.find(this.appendTo):e;var i=e.addClass("k-filterable").find(".k-grid-filter-menu");var 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"+p,this._click.bind(this))},_init:function(){var e=this;var t=this.options.forceUnique;var 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(L(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"+I,this._keydown.bind(this)).on("submit"+I,this._filter.bind(this)).on("reset"+I,this._reset.bind(this)),this.trigger(c,{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;var t=this.searchTextBox[0].value;var 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];var o=r.textContent||r.innerText;e&&(o=o.toLowerCase()),r.parentNode.style.display=o.indexOf(t)>=0?"":"none",i++}},_activate:function(){const t=this;t.form.find(":kendoFocusable").first().trigger("focus"),t.popup?.position(),t.popup&&t.popup.wrapper.find("[ref-actionsheet-action-button]").bind("click",(function(n){e(n.currentTarget).hasClass("k-button-solid-primary")?t.form.trigger("submit"):t.form.trigger("reset")})),t.trigger(d,{field:t.field,container:t.form})},_createForm:function(){var t=this.options;var i="";var r=this;const a=r._showAdaptiveView;if(this._isMobile||(i+="<div class='k-filter-menu-container'>",t.search&&(i+=`<span class='k-searchbox k-textbox k-input${a?" k-input-lg":" 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>"),a||(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(H)({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 c=this.view.element;this.container=c.find(".k-multicheck-wrap"),c.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()})),r.view.bind("transitionEnd",(function(e){"show"===e.type&&r.trigger(d,{field:r.field,container:r.form})}))}else if(t.appendToElement)this.popup=this.element.closest(".k-column-menu.k-popup").data(s),this.element.append(this.form);else if(a){const n=e("<div></div>").append(r.form).appendTo("body");r.popup=n[l]({anchor:r._link,copyAnchorStyles:!1,open:r._open.bind(r),activate:r._activate.bind(r),adaptive:!0,closeButton:!0,title:t.adaptiveTitle||"Filter by "+r.field,subtitle:t.adaptiveSubtitle,actionButtons:[{text:"Clear",icon:"filter-clear"},{text:"Filter",icon:"filter",themeColor:"primary"}],close:function(){r.options.closeCallback&&r.options.closeCallback(r.element)}}).data(l),r.popup.fullscreen(r.smallMQL.mediaQueryList.matches)}else 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"+I,this._input.bind(this)),this.clearSearchButton=this.form.find(".k-searchbox .k-clear-value"),this.clearSearchButton.on("click"+I,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;var i=n.template(t.itemTemplate({field:"all",mobile:this._isMobile,isAdaptive:this._showAdaptiveView}));var 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+I,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;var i=n.template(t.itemTemplate({field:"isNull",mobile:this._isMobile,valueField:"value",isAdaptive:this._showAdaptiveView}));var r=e(i({isNull:t.messages.isNull,value:null}));this.container.append(r)},refresh:function(e){var t=this.options.forceUnique;var n=this.dataSource;var 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(L(this.dataSource.data(),this.field)),this.container.empty()),this.container.is(":empty")&&this.createCheckBoxes(),this.checkValues(i),this.trigger(h))},getFilterArray:function(){var t=e.extend(!0,{},{filters:[],logic:"and"},this.dataSource.filter());return z(t,this.field),P(t)},createCheckBoxes:function(){var e=this.options;var t;var i={field:this.field,format:e.format,mobile:this._isMobile,type:this.type,isAdaptive:this._showAdaptiveView};var r=F.bind(this);this.options.forceUnique?this._foreignKeyValues()?(t=this.checkSource.data(),i.valueField="value",i.field="text"):t=this.checkSource._isServerGrouped()?L(this.checkSource._flatData(this.checkSource.data()),this.field):this.checkSource.data():t=this.checkSource.view(),"boolean"===this.type&&(this.createIsNullItem(),t=t.filter(r));var o=n.template(e.itemTemplate(i));var a=n.render(o,t);this.container.on(u+I,":checkbox",this.updateCheckAllState.bind(this)),this.container.prepend(a),e.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")){var o=n._parse(e(i).val());for(var 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"};var 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;w.fn.destroy.call(e),e.form&&(n.unbind(e.form),n.destroy(e.form),e.form.off(I),e.popup&&(e.popup.destroy(),e.popup=null),e.form=null,e.container&&(e.container.off(I),e.container=null),e.checkBoxAll&&e.checkBoxAll.off(I)),e.view&&(e.view.purge(),e.view=null),e._link&&e._link.off(p),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(I),this.searchTextBox=null),this.clearSearchButton&&(this.clearSearchButton.off(I),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,isAdaptive:l})=>{var c="";return r===t&&(r=e),"date"==s&&(c=":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${c}}`,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${l?" k-checkbox-lg":" k-checkbox-md"} k-rounded-md' value='${o(n.format(`{0${c}}`,n.getter(r)(t)))}'/></span><span>${o(n.format(a||"{0}",n.getter(e)(t)))}</span></label></li>`},checkAll:!0,search:!1,adaptiveMode:"none",adaptiveTitle:null,adaptiveSubtitle:null,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:[c,h,"change",d]});function F(e){return null!==e[this.field]}e.extend(R.fn,{_click:E.fn._click,_keydown:E.fn._keydown,_reset:E.fn._reset,_closeForm:E.fn._closeForm,_removeFilter:E.fn._removeFilter,clear:E.fn.clear,_merge:E.fn._merge}),i.plugin(E),i.plugin(R)}(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",h="k-disabled",u="aria-disabled",p="aria-expanded",f="aria-hidden",m="k-expanded",g="k-hidden",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>";var w=n.extend({init:function(i,r){var o=this;var 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=this;var i=n.element;var r=i[0];var o;var a;var s=i.attr("id");s||(s=t.guid(),i.attr("id",s)),o=i.wrap("<div class='k-expander"+(n.options.expanded?" "+m:"")+"'></div>").parent(),a=t.template(b)({title:n.options.title,subTitle:n.options.subTitle,iconClass:n.options.expanded?n.options.expandIconClass:n.options.collapseIconClass,useBareTemplate:n.options.useBareTemplate,ns:t.ns,elementId:s+"_wrapper"}),n.header=e(a),o.prepend(n.header),n._indicator=o.find(v+" span"),n.options.hideExpanderIndicator&&o.find(v).hide(),o[0].style.cssText=r.style.cssText,r.style.width="100%",n.wrapper=o.addClass(n.options.disabled?h:""),n.contentWrapper=n.element.wrap('<div id="'+s+'_wrapper"></div>').parent().addClass("k-expander-content-wrapper").toggleClass(g,!n.options.expanded).data("olddisplay","block"),n.header.attr(u,n.options.disabled).attr(p,n.options.expanded),n.options.useBareTemplate||o.addClass(r.className),n.options.height&&n.wrapper.css("height",n.options.height),n.options.headerClass&&n.header.addClass(n.options.headerClass),n.options.wrapperClass&&n.header.addClass(n.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;var n=t._indicator.is(t.collapseIconSelector);var 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(h,!e),this.header.attr(u,!e)},_blur:function(){this.header&&this.wrapper.removeClass(_)},_focus:function(){this.wrapper&&this.wrapper.addClass(_)}});i.plugin(w)}(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",h="asc",u="desc",p="change",f="init",m="open",g="select",v="stick",_="unstick",b="kendoPopup",w="kendoTabStrip",y="kendoMenu",k="kendoActionSheet",x="kendoExpansionPanel",C=".kendoColumnMenu",S=!1,T=r.Widget;function M(e){return n.trim(e).replace(/ /gi,"")}function A(e){return this.columns.indexOf(e.title)>=0||this.columns.indexOf(e.field)>=0}function D(e){var t=[];for(var n=0;n<e.length;n++)e[n].columns?t=t.concat(D(e[n].columns)):t.push(e[n]);return t}var E=T.extend({init:function(t,i){var r,o=this;(i=i||{}).componentType=i.componentType||"classic",T.fn.init.call(o,t,i),t=o.element,i=o.options,o.owner=i.owner,o.dataSource=i.dataSource,S=n.support.isRtl(o.element.parents(".k-grid")),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._bindMediaQueries(),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._columns(),e._showAdaptiveView||(e._filter(),e._lockColumns(),e._reorderColumns(),e._stickyColumns(),e._clearAllFilters()),e._sort(),e._sizeColumns(),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:"Columns",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,adaptiveTitle:"",adaptiveSubtitle:"",animations:{left:"slide"},adaptiveMode:"none",encodeTitles:!1,componentType:"classic",appendTo:null,_actionsheet:null},_bindMediaQueries:function(){const e=this;"auto"===e.options.adaptiveMode&&"modern"===e.options.componentType?(e.largeMQL=n.mediaQuery("large"),e.mediumMQL=n.mediaQuery("medium"),e.smallMQL=n.mediaQuery("small"),e.smallMQL.onEnter((()=>{e._showAdaptiveView=!0,e.wrapper?.addClass("k-column-menu-lg"),e.popup&&e.popup.visible()&&e.popup.fullscreen?e.popup.fullscreen(!0):e._adaptiveView()})),e.mediumMQL.onEnter((()=>{e._showAdaptiveView=!0,e.wrapper?.addClass("k-column-menu-lg"),e.popup&&e.popup.visible()&&e.popup.fullscreen?e.popup.fullscreen(!1):e._adaptiveView()})),e.largeMQL.onEnter((()=>{e._showAdaptiveView=!1,e.wrapper?.removeClass("k-column-menu-lg"),e._adaptiveView()}))):(e.smallMQL&&e.smallMQL.destroy(),e.mediumMQL&&e.mediumMQL.destroy(),e.largeMQL&&e.largeMQL.destroy(),e._showAdaptiveView=!1)},_adaptiveView:function(){const e=this;e.popup&&(e.popup.close(),e.popup.wrapper&&e.popup.wrapper.remove(),e.popup.destroy(),e.popup=null)},_adaptiveItemClick:function(t){t.preventDefault(),t.stopPropagation();const i=this;const r=i.options;let o=i._columnMenuAdaptiveView;let a=i._ownerColumns();let s;let l=!1;i._hasGroups()&&(a=i._groupColumns(a),s=i._flattenMenuCols(a),s.length!==i.owner.columns.length&&i._syncMenuCols(s,i.owner.columns));const c={uid:n.guid(),ns:n.ns,messages:r.messages,sortable:r.sortable,filterable:r.filterable,columns:a,showColumns:r.columns,hasLockableColumns:r.hasLockableColumns,hasStickableColumns:r.hasStickableColumns,encodeTitles:r.encodeTitles,omitWrapAttribute:n.attr("omit-wrap"),reorderable:r.reorderable,groupable:r.groupable,autoSize:r.autoSize,hideAutoSizeColumn:r.hideAutoSizeColumn,clearAllFilters:r.clearAllFilters,isAdaptive:!0};const d=i.field||e(t.currentTarget).text().split(" / ").pop();const h=e(t.currentTarget).closest(".k-expander").find("[ref]").attr("ref");const u=i._getContentTemplates()[h];const p={...i._getHeaderConfig(r.adaptiveTitle||d,r.messages)[h],...i._getFooterConfig(r.messages)[h],contentTemplate:u&&u(c),ref:`${h}-view`};function f(){o=i._columnMenuAdaptiveView=i.popup._addView(p),i._columnMenuAdaptiveView.field=i.field,l=!0}if(!o&&i._showAdaptiveView?f():(o&&o.ref!==`${h}-view`||o.field!==d)&&(i.popup._removeView(o),f()),!l)return void setTimeout((()=>{i.popup._setCurrentActiveView(o.index)}));if(h.includes("column"))i.options.hasLockableColumns&&i._updateLockedColumns(),i.options.hasStickableColumns&&i._updateStickyColumns(),i.options.reorderable&&i._updateReorderColumns(),i.options.groupable&&i._updateGroupColumns(),i._updateColumnsMenu();else if("filter"===h&&!u){const e=D(i.owner.columns)?.find((e=>e.title===d||e.field===d));const t={...r};e.filterable&&(t.filterable=e.filterable),t.field=e.field,i._filter(".k-actionsheet-content",t)}"column-position"===h&&(i._lockColumns(),i._reorderColumns(),i._stickyColumns(),i._sizeColumns()),i._bindHandlers(h),o?._content.attr("data-field",d);(i.popup&&i.popup.wrapper?.find("[data-ref-actionsheet-start-button]")).bind("click"+C,(function(e){e.preventDefault(),i.popup._setCurrentActiveView(o.index-1)})),setTimeout((()=>{i.popup._setCurrentActiveView(o.index)}))},_getHeaderConfig:function(e,t){return{filter:{title:`${t.filter} by ${e}`,closeButton:!0,startButton:{text:"Back"}},"columns-visibility":{title:t.columnVisibility,subtitle:"Selected fields are visible",closeButton:!0,startButton:{text:"Back"}},"column-position":{title:`Set ${e} Position`,closeButton:!0,startButton:{text:"Back"}}}},_getFooterConfig:function(e){return{filter:{actionButtons:[{text:i(e.clear),icon:"filter-clear"},{text:i(e.apply),icon:"filter",themeColor:"primary"}]},"columns-visibility":{actionButtons:[{text:i(e.reset),icon:"arrow-rotate-ccw"},{text:i(e.apply),themeColor:"primary",icon:"check"}]}}},_getContentTemplates:function(){const e=this.options.componentType;return{modern:{full:U,sort:L,"columns-visibility":this._showAdaptiveView?R:B,"column-chooser":H,"column-position":$,group:F,lockableColumns:O,stickableColumns:V,reorderableColumns:N}}[e]},_bindHandlers:function(t){const i=this;const r=i._getWrapper();const o={clearButton:i._showAdaptiveView?".k-actions .k-button:not(.k-button-solid-primary)":".k-columns-item .k-button:not(.k-button-solid-primary)",applyButton:i._showAdaptiveView?".k-actions .k-button.k-button-solid-primary":".k-columns-item .k-button.k-button-solid-primary",checkbox:".k-column-list-wrapper .k-checkbox",columnChooserClear:".k-column-list-wrapper .k-button:not(.k-button-solid-primary)",columnChooserApply:".k-column-list-wrapper .k-button.k-button-solid-primary"};i._isModernComponentType()||i._isTabbedComponentType()?(r.on("click"+C,o.columnChooserClear,(function(e){i._updateColumnsMenu()})),r.on("click"+C,o.columnChooserApply,(function(){i._applyColumnVisibility()})),r.on("click"+C,o.clearButton,(function(e){if(t)switch(t){case"filter":i.filterMenu.form.trigger("reset");break;case"columns-visibility":e.preventDefault(),i._updateColumnsMenu()}else i._showAdaptiveView&&e.preventDefault(),i._updateColumnsMenu()})),r.on("click"+C,o.applyButton,(()=>{if(t)switch(t){case"filter":i.filterMenu.form.trigger("submit");break;case"columns-visibility":i._applyColumnVisibility()}else i._applyColumnVisibility()})),r.on("click"+C,o.checkbox,(function(){i._updateColumnsMenu(!0)}))):i.menu.bind(g,(function(t){var r,o,s,l=e(t.item),c=n.attr("uid"),d=a(D(i.owner.columns),(function(e){var t=!0,n=M(e.title||"");return!1!==e.menu&&(e.field||n.length)||(t=!1),t}));i._isMobile&&t.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?i.owner.showColumn(o):i.owner.hideColumn(o),i._preventMenuCloseOnColumnVisibilityChange=!0))}))},_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);const c=o._showAdaptiveView;o._hasGroups()&&(s=o._groupColumns(s),(t=o._flattenMenuCols(s)).length!==o.owner.columns.length&&o._syncMenuCols(t,o.owner.columns)),i=a.contentTemplate?n.template(a.contentTemplate):o._isModernComponentType()?n.template(U):o._isTabbedComponentType()?n.template(W):n.template(G);const d={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,isAdaptive:c};if(a.contentTemplate&&(d._defaultContents=o._getContentTemplates.bind(o),d._defaultHeaders=o._getHeaderConfig.bind(o),d._defaultFooters=o._getFooterConfig.bind(o)),r=e(i(d)),n.applyStylesFromKendoAttributes(r,["display"]),o.wrapper.empty().append(r),c){let t=[{title:a.adaptiveTitle||"Column Menu",subtitle:a.adaptiveSubtitle||"",closeButton:!0}];const n=e("<div></div>").append(o.wrapper).appendTo("body");const i=o.options._actionsheet;i&&(t=[]),o.popup=n[k]({anchor:o.link,adaptive:!0,copyAnchorStyles:!1,closeButton:!0,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._columnMenuAdaptiveView&&o._columnMenuAdaptiveView.wrapper&&(o._closeApply(),o.popup._removeView(o._columnMenuAdaptiveView),o._columnMenuAdaptiveView=null),o.menu&&(o.menu._closing=e.sender.element),o.options.closeCallback&&o.options.closeCallback(o.element)},views:t,...i}).data(k),o.popup.fullscreen(o.smallMQL.mediaQueryList.matches)}else 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){o.menu&&(o.menu._closing=e.sender.element),o.options.closeCallback&&o.options.closeCallback(o.element)}}).data(b);if((o._isModernComponentType()||o._isTabbedComponentType()||l)&&(c?o.popup.element.find(".k-column-menu").removeClass("k-grid-columnmenu-popup k-popup"):o.popup.element.addClass("k-grid-columnmenu-popup"),o.popup.element.removeClass("k-column-menu-popup")),o._isModernComponentType()||o._isTabbedComponentType()||a.contentTemplate?o._createExpanders():o.menu=o.wrapper.children()[y]({orientation:"vertical",closeOnClick:!1,autoSize:!0,open:function(){o._updateMenuItems()}}).data(y),a.contentTemplate||o._isTabbedComponentType()&&(o.tabStrip=r[w]({applyMinHeight:!1,animation:{open:{effects:"fadeIn"}}}).data(w),o.tabStrip.activateTab(o.tabStrip.tabGroup.find("li:first"))),c){let e;(o._isModernComponentType()||a.contentTemplate)&&(e=".k-columnmenu-item-wrapper [data-expander-header]"),o.popup.element.find(e).bind("click"+C,o._adaptiveItemClick.bind(o))}},_closeApply:function(e){const t=this;const n=t._columnMenuAdaptiveView;const i=/(.*?)-view/;if(n){const r=(e||n.ref).match(i)[1];"filter"===r?n._hasChanges&&t.filterMenu.form.trigger("submit"):"columns-visibility"!==r&&"column-chooser"!==r||t._applyColumnVisibility(!0)}},_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.is("[ref-toolbar-tool]")?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"+C,e._click.bind(e)),o},_createMultiHeaderTitle:function(e){const t=this;const n=e.parentIds.split(" ").map((e=>t.owner.thead.find(`[id='${e}']`)?.text()));return n.push(e.title||e.field),n.join(" / ")},_createExpanders:function(){var r=this;var o=r.options;var a=r.options.columnsExpanderOptions||{};var s={expanded:!1,headerClass:"k-columnmenu-item",useBareTemplate:!0,expandIconClass:r._showAdaptiveView?"chevron-right":t,collapseIconClass:r._showAdaptiveView?"chevron-right":t};const l=D(r.owner.columns);if(o.contentTemplate){const t=r.wrapper.find(".k-columns-item:not([ref='column-chooser'])");t.length&&t.each((function(t,n){const i=e(n).data("index");const o=l[i];const c=o&&o.parentIds?r._createMultiHeaderTitle(o):o.title||o.field;e(n)[x](e.extend(!0,{},s,a,{title:c}))}))}r._isModernComponentType()&&(r.wrapper.find("[ref='columns-visibility']")[x](e.extend(!0,{},s,a,{title:n.ui.icon("columns")+"<span>"+i(o.messages.columnVisibility)+"</span>"})),r.wrapper.find(".k-column-menu-filter")[x](e.extend(!0,{},s,{title:n.ui.icon("filter")+"<span>"+i(o.messages.filter)+"</span>"})).attr("ref","filter")),r.wrapper.find(".k-column-menu-position")[x](e.extend(!0,{},s,{title:n.ui.icon("set-column-position")+"<span>"+i(o.messages.setColumnPosition)+"</span>"})).attr("ref","column-position")},_syncMenuCols:function(e,t){var n=t.length;var i;var r=e.map((function(e){return e.field}));for(var o=0;o<n;o++)i=t[o],r.indexOf(i.field)<0&&(i.menu=!1)},_flattenMenuCols:function(e){var t=[];var n=e.length;for(var 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=[];var i=this.options.columns.groups;var r=i.length;var o;var a;var s;var l;var c;for(o=0;o<r;o++)a=i[o],s=A.bind(a),l={title:a.title,groupHeader:!0},c=e.filter(s),n.push(l),t?l.columns=c:n=n.concat(c);return n},_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(Y)({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 Q(i.wrapper.children(),{pane:i.pane,columnMenu:i}),i.menu.element.on("transitionend"+C,(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;T.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(C),e.menu.destroy()),e.wrapper.off(C),e.popup&&e.popup.destroy(),e.view&&e.view.purge(),e.link.off(C),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"+C))},_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;var 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;var 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){var i=this;var r;var o;var s;var l=a(D(i.owner.columns),(function(e){var t=!0,n=M(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}}));var c=i._getRenderedList();var d=i._getRenderedListElements(c);var h=function(e,t){var i=n.attr("index");var r=n.attr("field");var o={};var a;var s;var l;var c;var d;for(var h=0;h<e.length;h++)s=t.eq(h),l=parseInt(s.attr(i),10),c=s.attr(r),d=s.attr("title"),o[a=c||d]?o[a].push(l):o[a]=[l];return o}(d,c.find("input[type=checkbox]"));var u=function(e){var t={};var n;for(var i=0;i<e.length;i++)t[n=JSON.stringify(e[i])]?t[n].push(i):t[n]=[i];return t}(l);var p;for(var f=0;f<l.length;f++)if(o=(s=l[f]).field?s.field:s.title,r=e.inArray(f,u[JSON.stringify(s)]),p=e(),h[o]){for(var m=0;m<h[o].length;m++)p=p.add(d.eq(h[o][m]));t(f,s,p.find((g="field",v=o,"["+n.attr(g)+"='"+(v||"").replace(/'/g,'"')+"']")).closest(i._isModernComponentType()?"label":"li").eq(r),c)}var g,v},_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"+C).on("keydown"+C,(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._showAdaptiveView||(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)||e.find(`.${t}`).length>0},_ownerColumns:function(e){var t,n=D(this.owner.columns),i=a(n,(function(e){var t=!0,n=M(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"+C,".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")||i._checkItemClass(r,"k-svg-i-sort-asc-small")?n=h:(i._checkItemClass(r,"k-sort-desc")||i._checkItemClass(r,"k-svg-i-sort-desc-small"))&&(n=u),(n||t.allowUnsort)&&(i._getSortItemsContainer(r).find(".k-sort-"+(n==h?u:h)).removeClass(d),i._sortDataSource(r,n,t),i._isMobile||i._preventClose||i.close())},_getSortItemsContainer:function(e){return this._isModernComponentType()||this._isTabbedComponentType()?e.parents(".k-columnmenu-item-wrapper").first():e.parent()},_sortDataSource:function(e,n,i){var r,o,a=this,s=a.options.sortable,l=null===s.compare?t:s.compare,c=a.dataSource,h=c.sort()||[];var u=(!1===i.allowSelectedState||e.hasClass(d))&&s&&(!1!==s.allowUnsort||i.allowUnsort);if(n=u?t:n,!a.trigger("sort",{sort:{field:a.field,dir:n,compare:l},preventClose:i.hasCtrlKey&&i.isMixed})){if(u?e.removeClass(d):!1!==i.allowSelectedState&&e.addClass(d),"multiple"===s.mode||i.isMixed){for(r=0,o=h.length;r<o;r++)if(h[r].field===a.field){h.splice(r,1);break}h.push({field:a.field,dir:n,compare:l})}else h=[{field:a.field,dir:n,compare:l}];c.sort(h)}},_columns:function(){var e=this;e.options.columns&&(e._updateColumnsMenu(),e._updateColumnsMenuHandler=e._updateColumnsMenu.bind(e),e.owner.bind(["columnHide","columnShow"],e._updateColumnsMenuHandler),e._updateColumnsLockedStateHandler=e._updateColumnsLockedState.bind(e),e.owner.bind(["columnUnlock","columnLock"],e._updateColumnsLockedStateHandler),e._bindHandlers())},_applyColumnVisibility:function(t){var i=this;var r=n.attr("field");var o=n.attr("uid");const s=i._getWrapper();var l=s.find(".k-column-list-item input["+r+"]");i._showAdaptiveView||l.length||(l=s.find(".k-columns-item input["+r+"]"));var c=a(D(this.owner.columns),(function(e){var t=!0,n=M(e.title||"");return!1!==e.menu&&(e.field||n.length)||(t=!1),t}));var d=l.length;var h;var u;var p;var f;for(i.owner.unbind("columnShow",i._updateColumnsMenuHandler),i.owner.unbind("columnHide",i._updateColumnsMenuHandler),h=0;h<d;h++)p=e(l[h]),u=c.map((function(e){return e.headerAttributes.id})).indexOf(p.attr(o)),f=c[u],p.is(":checked")&&f.hidden?i.owner.showColumn(f):p.is(":not(:checked)")&&!f.hidden&&i.owner.hideColumn(f);t||i._showAdaptiveView||i.popup.close(),i.owner.bind(["columnHide","columnShow"],i._updateColumnsMenuHandler)},_sizeColumns:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+C,".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"+C,".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;const c=l._showAdaptiveView;var d=n.attr("field"),h=n.attr("locked"),u=n.attr("uid"),p={},f=0,m=0;e=!0===e;const g=l._getWrapper();var v=a(D(this.owner.columns),(function(e,t){var n=!0,i=M(e.title||"");return!1!==e.menu&&(e.field||i.length)||(n=!1),n&&(p[t]=f,f++),n})),_=a(this._ownerColumns(),(function(t){return e?g.find("[role='menuitemcheckbox'] ["+u+"='"+t.uid+"']").prop("checked"):!t.hidden&&!1!==t.matchesMedia})),b=a(_,(function(e){return e.originalField})),w=a(b,(function(e){return!0===e.locked})),y=a(b,(function(e){return!0!==e.locked})),k=a(this.owner.columns,(function(e){return!1===e.menu})),x=a(k,(function(e){return e.hidden})),C=a(k,(function(e){return!e.hidden}));const S=g.find("[role='menuitemcheckbox']");S.attr("aria-checked",!1);const T=c?".k-column-list-item input["+d+"]":".k-columns-item input["+d+"]";var A=g.find(T);if(S.length&&!A.length)A=g.find(".k-column-list-item input["+d+"]");var E;for(A.prop("disabled",!1),e||A.prop("checked",!1),t=0,i=A.length;t<i;t++)s="true"===(r=A.eq(t)).attr(h),!1,E=r.data("kendoSwitch"),m=v.map((function(e){return e.headerAttributes.id})).indexOf(r.attr(u)),o=e?r.prop("checked"):!v[m].hidden&&!1!==v[m].matchesMedia,r.prop("checked",o),E&&(E.enable(!0),E.check(o)),r.closest("[role='menuitemcheckbox']").attr("aria-checked",o),o&&l._disableCheckbox(r,s,{columnsNotInMenu:k,hiddenColumnsNotInMenu:x,visibleColumnsNotInMenu:C,lockedCount:w,nonLockedCount:y},E)},_disableCheckbox:function(e,t,n,i){const{lockedCount:r,nonLockedCount:o}=n;t&&r&&1===r.length&&(e.prop("disabled",!0),i&&i.enable(!1)),!t&&o&&1===o.length&&(e.prop("disabled",!0),i&&i.enable(!1))},_updateColumnsLockedState:function(){var e,t,i,r;var o=n.attr("field");var a=n.attr("locked");var s=function(e,t){var n={};var i,r,o;for(i=0,r=e.length;i<r;i++)n[(o=e[i])[t]]=o;return n}(this._ownerColumns(),"field");const l=this._showAdaptiveView?".k-column-list-wrapper input[type=checkbox]":".k-columns-item input[type=checkbox]";var c=this._getWrapper().find(l);for(e=0,t=c.length;e<t;e++)(r=s[(i=c.eq(e)).attr(o)])&&i.attr(a,r.locked?.toString());this._updateColumnsMenu()},_filter:function(t,n){var i=this,r="kendoFilterMenu";n=n||i.options;const a=i._getWrapper();!1!==n.filterable&&(n.filterable.multi&&(r="kendoFilterMultiCheck",n.filterable.dataSource&&(n.filterable.checkSource=n.filterable.dataSource,delete n.filterable.dataSource)),i.filterMenu=a.find(t||".k-filterable")[r](o(!0,{},{appendToElement:!0,dataSource:n.dataSource,values:n.values,field:i.field||n.field,title:i.title,adaptiveMode:i._showAdaptiveView?"auto":"none",change:function(e){i.trigger("filtering",{filter:e.filter,field:e.field})&&e.preventDefault()},componentType:i.options.componentType,cycleForm:!i._isModernComponentType()&&!i._isTabbedComponentType()},n.filterable)).data(r),i.filterMenu&&i._columnMenuAdaptiveView&&(i.filterMenu.form.on(p,(function(e){i._columnMenuAdaptiveView._hasChanges=!0})),i.filterMenu.form.on("input",(function(e){i._columnMenuAdaptiveView._hasChanges=!0}))),i._isMobile&&i.menu.bind(g,(function(t){e(t.item).hasClass("k-filter-item")&&i.pane.navigate(i.filterMenu.view,i.options.animations.left)})))},_lockColumns:function(){var e=this;const t=e._getWrapper();e._isModernComponentType()||e._isTabbedComponentType()?t.on("click"+C,".k-lock, .k-unlock",e._lockableHandler.bind(e)):e.menu.bind(g,e._lockableHandler.bind(e))},_lockableHandler:function(t){var n=this;var 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())},_getWrapper:function(){const e=this;let t;return t=e._columnMenuAdaptiveView?e._showAdaptiveView?e._columnMenuAdaptiveView.wrapper:e.wrapper:e.popup&&e._showAdaptiveView?e.popup.wrapper:e.wrapper,t},_reorderColumns:function(){var e=this;const t=e._getWrapper();e._isModernComponentType()||e._isTabbedComponentType()?t.on("click"+C,".k-move-prev, .k-move-next",e._reorderHandler.bind(e)):e.menu.bind(g,e._reorderHandler.bind(e))},_reorderHandler:function(t){var n=this;var 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"+C,".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);if(n.owner.groupable){const e=n.owner.groupable.descriptors().find((e=>e.field===n.field));(i.hasClass("k-group")&&!e||i.hasClass("k-ungroup")&&e)&&(n.owner._handleSpaceKey(n.element,!0),n._isMobile||n.close())}},_stickyColumns:function(){var e=this;const t=e._showAdaptiveView&&e._columnMenuAdaptiveView?e._columnMenuAdaptiveView.wrapper:e.wrapper;e._isModernComponentType()||e._isTabbedComponentType()?t.on("click"+C,".k-stick, .k-unstick",e._stickableHandler.bind(e)):e.menu.bind(g,e._stickableHandler.bind(e))},_stickableHandler:function(t){var n=this;var i=t.item?e(t.item):e(t.target);var r=n.field;var o=n.owner.columns;var 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(){const e=this;var t=this.field;var n=this.owner.columns;const i=e._showAdaptiveView&&e._columnMenuAdaptiveView?e._columnMenuAdaptiveView.wrapper:e.wrapper;var r=a(n,(function(e){return e.field==t||e.title==t}))[0];if(r){var o=!0===r.locked;var s=a(n,(function(e){return!e.hidden&&(e.locked&&o||!e.locked&&!o)})).length;var l=!1===r.lockable;var c=i.find(".k-lock").removeClass("k-disabled").removeAttr("aria-disabled");var d=i.find(".k-unlock").removeClass("k-disabled").removeAttr("aria-disabled");(o||1==s||l)&&c.addClass("k-disabled").attr("aria-disabled","true"),o&&1!=s&&!l||d.addClass("k-disabled").attr("aria-disabled","true"),this._updateColumnsLockedState()}},_updateStickyColumns:function(){const e=this;var t=this.field;var n=this.owner.columns;const i=e._showAdaptiveView&&e._columnMenuAdaptiveView?e._columnMenuAdaptiveView.wrapper:e.wrapper;var r=a(n,(function(e){return e.field==t||e.title==t}))[0];if(r){var o=!0===r.sticky;var s=!0===r.stickable;var l=!0===r.locked;var c=a(n,(function(e){return!e.hidden&&(e.locked&&l||!e.locked&&!l)})).length;var d=i.find(".k-stick").removeClass("k-disabled").removeAttr("aria-disabled");var h=i.find(".k-unstick").removeClass("k-disabled").removeAttr("aria-disabled");(o||!s||l&&1===c)&&d.addClass("k-disabled").attr("aria-disabled","true"),o&&s||h.addClass("k-disabled").attr("aria-disabled","true")}},_updateReorderColumns:function(){const e=this;const t=e._showAdaptiveView&&e._columnMenuAdaptiveView?e._columnMenuAdaptiveView.wrapper:e.wrapper;var n=this.element,i=n.index(),r=n.parent().children().length;var o=t.find(".k-move-prev").removeClass("k-disabled").removeAttr("aria-disabled");var a=t.find(".k-move-next").removeClass("k-disabled").removeAttr("aria-disabled");0===this.element.index()&&o.addClass("k-disabled").attr("aria-disabled","true"),i+1===r&&a.addClass("k-disabled").attr("aria-disabled","true")},_updateGroupColumns:function(){const e=this;const t=e._showAdaptiveView&&e._columnMenuAdaptiveView?e._columnMenuAdaptiveView.wrapper:e.wrapper;var n=this.element,i=t.find(".k-menu-item.k-group"),r=t.find(".k-menu-item.k-ungroup");this.owner.groupable._canDrag(n)?(i.removeClass("k-hidden"),r.addClass("k-hidden")):(i.addClass("k-hidden"),r.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.is("[ref-toolbar-tool]")||i.link[i._filterExist(i.dataSource.filter())?"addClass":"removeClass"]("k-active")},_filterExist:function(e){var t=!1;var n;if(e){for(var i=0,r=(e=e.filters).length;i<r;i++)(n=e[i]).field==this.field?t=!0:n.filters&&(t=t||this._filterExist(n));return t}}});function I(e,t,r,o){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 ${o?"k-checkbox-lg":"k-checkbox-md"} k-rounded-md" type="checkbox" title="${t?i(e.title):e.title}" data-${r}field="${e.field.replace(/\"/g,""")}" 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("")}const z=({messages:e,hideAutoSizeColumn:t})=>`<div class="k-columnmenu-item-wrapper">${t?"":`<div class="k-columnmenu-item k-auto-size-column" ref="auto-size" tabindex="0">${n.ui.icon("max-width")}${i(e.autoSizeColumn)}</div>`}\n<div class="k-columnmenu-item k-auto-size-all" ref="auto-size-all" tabindex="0">${n.ui.icon("display-inline-flex")}${i(e.autoSizeAllColumns)}</div></div>`;const P=({messages:e})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-clear-all-filters" ref="clear-all-filters" tabindex="0">${n.ui.icon("filter-clear")}${i(e.clearAllFilters)}</div></div>`;const L=({messages:e})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-sort-asc" tabindex="0" ref="sort-asc">${n.ui.icon("sort-asc-small")}${i(e.sortAscending)}</div><div class="k-columnmenu-item k-sort-desc" tabindex="0" ref="sort-asc">${n.ui.icon("sort-desc-small")}${i(e.sortDescending)}</div></div>`;const B=({columns:e,messages:t,encodeTitles:r,ns:o,isAdaptive:a,ref:s})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item-content k-columns-item" ref="columns-visibility"><div class="k-column-list-wrapper"><div class="k-column-list ${a?"k-column-list-lg":"k-column-list-md"}" role="menu">${I(e,r,o,a)}</div>${a?"":"<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>`;const H=({columns:e,messages:t,encodeTitles:r,ns:o,isAdaptive:a})=>`<div class="k-column-list-wrapper" ref="column-chooser"><div class="k-column-list ${a?"k-column-list-lg":"k-column-list-md"}" role="menu">${I(e,r,o,a)}</div>${a?"":"<div class='k-actions k-actions-stretched k-actions-horizontal k-column-menu-footer'>"+n.html.renderButton(`<button>${i(t.apply)}</button>`,{themeColor:"primary",icon:"check"})+n.html.renderButton(`<button>${i(t.reset)}</button>`,{icon:"undo"})+"</div>"}</div>`;const R=({columns:e,messages:t,encodeTitles:n,ns:i,isAdaptive:r,ref:o})=>`<div class="k-column-list-wrapper" ref="columns-visibility"><div class="k-column-list k-column-list-lg" role="menu">${I(e,n,i,r)}</div></div>`;const F=({messages:e})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-group" tabindex="0" ref="group">${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" ref="ungroup">${n.ui.icon("ungroup")}${i(e.ungroupColumn)}</div></div>`;const O=({messages:e})=>`<div class="k-columnmenu-item k-lock" ref="lock-column" tabindex="0">${n.ui.icon("lock")}${i(e.lock)}</div><div class="k-columnmenu-item k-unlock" ref="unlock-column" tabindex="0">${n.ui.icon("unlock")}${i(e.unlock)}</div>`;const V=({messages:e})=>`<div class="k-columnmenu-item k-stick" tabindex="0" ref="stick-column">${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>`;const N=({messages:e})=>`<div class="k-columnmenu-item k-move-prev" tabindex="0" ref="reorder-prev">${n.ui.icon("caret-alt-"+(S?"right":"left"))}${i(e.movePrev)}</div><div class="k-columnmenu-item k-move-next" tabindex="0" ref="reorder-next">${n.ui.icon("caret-alt-"+(S?"left":"right"))}${i(e.moveNext)}</div>`;const $=({hasLockableColumns:e,hasStickableColumns:t,messages:n,reorderable:i})=>`<div class="k-columnmenu-item-wrapper"><div class="k-column-menu-position">${e?O({messages:n}):""}${t?V({messages:n}):""}${i?N({messages:n}):""}</div></div>`;var U=({autoSize:e,hideAutoSizeColumn:t,sortable:n,filterable:i,clearAllFilters:r,showColumns:o,messages:a,columns:s,hasLockableColumns:l,hasStickableColumns:c,encodeTitles:d,ns:h,reorderable:u,groupable:p,isAdaptive:f})=>`${n?L({messages:a}):""}${o?B({columns:s,messages:a,encodeTitles:d,ns:h,isAdaptive:f}):""}${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?F({messages:a}):""}${e?z({messages:a,hideAutoSizeColumn:t}):""}${r?P({messages:a}):""}${l||c||u?$({hasLockableColumns:l,hasStickableColumns:c,messages:a,reorderable:u}):""}`;var W=({sortable:e,filterable:t,clearAllFilters:i,showColumns:r,messages:o,columns:a,hasLockableColumns:s,hasStickableColumns:l,encodeTitles:c,ns:d,reorderable:h,groupable:u,autoSize:p,hideAutoSizeColumn:f})=>`<div>\n <ul>\n ${t?`<li>${n.ui.icon("filter")}</li>`:""}\n ${e||s||l||h||u||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" ref="filter"><div class="k-columnmenu-item-content k-column-menu-filter"><div class="k-filterable"></div></div></div></div>':""}\n ${e||s||l||h||u||p?function(e,t,n,i,r,o,a,s,l){var c="<div>";return e&&(c+=L({messages:a})),r&&(c+=F({messages:a})),(t||n||i)&&(c+=$({hasLockableColumns:t,hasStickableColumns:n,messages:a,reorderable:i})),o&&(c+=z({messages:a,hideAutoSizeColumn:s})),l&&(c+=P({messages:a})),c+"</div>"}(e,s,l,h,u,p,o,f,i):""}\n ${r?`<div>${B({columns:a,messages:o,encodeTitles:c,ns:d})}</div>`:""}\n </div>`;const j=({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" ref="columns-visability"><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,""")}" 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>':""}`;const q=({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" ref="lock-column"><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" ref="unlock-column"><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" ref="stick-column"><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" ref="unstick-column"><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" ref="reorder-prev"><span class="k-link k-menu-link">${n.ui.icon("caret-alt-"+(S?"right":"left"))}<span class="k-menu-link-text">${i(e.movePrev)}</span></span></li><li class="k-item k-menu-item k-move-next" ref="reorder-next"><span class="k-link k-menu-link">${n.ui.icon("caret-alt-"+(S?"left":"right"))}<span class="k-menu-link-text">${i(e.moveNext)}</span></span></li>`)({messages:e}):""}</ul></li>`;var G=({uid:e,sortable:t,filterable:r,showColumns:o,messages:a,columns:s,hasLockableColumns:l,hasStickableColumns:c,encodeTitles:d,ns:h,omitWrapAttribute:u,reorderable:p,groupable:f})=>`<ul id="${e}">${t?(({messages:e,showColumns:t,filterable:r})=>`<li class="k-item k-menu-item k-sort-asc" ref="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" ref="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?j({columns:s,messages:a,encodeTitles:d,ns:h,omitWrapAttribute:u,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" ref="filter" 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" ref="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" ref="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?q({messages:a,hasLockableColumns:l,hasStickableColumns:c,reorderable:p}):""}\n</ul>`;const K=({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,""")}" 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,""")}" 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 Y=({messages:e,title:t,sortable:r,filterable:o,showColumns:a,hasLockableColumns:s,hasStickableColumns:l,hasGroups:c,columns:d,groups:h,ns:u,reorderable:p,groupable:f})=>`<div data-${u}role="view" class="k-grid-column-menu"><div data-${u}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-"+(S?"right":"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-"+(S?"left":"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?K({messages:e,hasGroups:c,columns:d,groups:h,ns:u}):""}<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>`;var Q=T.extend({init:function(e,t){var n=this;T.fn.init.call(n,e,t),n._createCheckBoxes(),n.element.on("click"+C,"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;var i=e(t);var r=n.options.columnMenu.view.state||{columns:{}};var o=i.prop("id");if(!i.hasClass("k-filter-item")){var a;var s;var 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;var n=t.options.columnMenu;var i=n.view;var 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;var 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");var i=e.options.columnMenu.view.state||{columns:{}};var r=n.prop("id");i.columns[r]?i.columns[r]=!1:i.columns[r]=!0,e.trigger(g,{item:n})}})},_destroyCheckBoxes:function(){var e=this.element.find(".k-columns-item").find("[type='checkbox']");var t;for(var n=0;n<e.length;n++)(t=e.eq(n).data("kendoSwitch"))&&t.destroy()},close:function(){this.options.pane.navigate("")},destroy:function(){var e=this;T.fn.destroy.call(e),e.element.off(C),e._destroyCheckBoxes()}});r.plugin(E)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo;var i=n.ui;var r=i.Widget;var o="dir";var a="asc";var s="single";var l="mixed";var c="field";var d="desc";var h=".kendoColumnSorter";var u=".k-link";var p="aria-sort";var 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(u))[0]||(n=i.element.wrapInner('<a class="k-link" href="#"/>').find(u)),i.link=n,i.element.on("click"+h,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(h),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,h,u=this,f=u.dataSource.sort()||[],m=u.element,g=m.attr(n.attr(c)),v=(u.dataSource._sortFields||{})[g];var _,b,w,y;m.removeAttr(n.attr(o)),m.removeAttr(p),v&&(r=v.dir,m.attr(n.attr(o),r),h=v.index),m.is("th")&&v&&(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}(m),s&&(m.attr(n.attr("index"))?(_=m.closest("table"),b=_.find("tr:not(.k-filter-row)"),w=n.attr("index"),y=b.find("th["+w+"]:visible"),l=[].sort.call(y,(function(n,i){n=e(n),i=e(i);var r=n.attr(w);var o=i.attr(w);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(m)):l=m.parent().children(":visible").index(m),l>-1&&s.find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(l).toggleClass("k-sorted",r!==t))),m.toggleClass("k-sorted",r!==t),m.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(u.link),m.attr(p,"ascending")):r===d?(e('<span class="k-sort-icon">'+n.ui.icon("sort-desc-small")+"</span>").appendTo(u.link),m.attr(p,"descending")):m.attr(p,"none"),u.options.showIndexes&&f.length>1&&h&&e('<span class="k-sort-order" />').html(h).appendTo(u.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,h=d.attr(n.attr(c)),u=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))&&(u=this._toggleSortDirection(u),!this.trigger("change",{sort:{field:h,dir:u,compare:f}}))){if(p.mode===s||p.mode===l&&!g)m=[{field:h,dir:u,compare:f}];else if("multiple"===p.mode||p.mode===l&&g){for(i=0,r=m.length;i<r;i++)if(m[i].field===h){m.splice(i,1);break}m.push({field:h,dir:u,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";var 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;var 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,t){var n=window.kendo,i=n.ui.Widget,r=n.ui.TextBox,o="k-hidden",a=n.ui,s=n.keys,l="k-otp-input",c="k-otp-separator",d="k-input-inner",h=".kendoOtpInput",u="change",p="k-input-group",f="k-invalid",m=/^[0-9]\d*$/,g="right",v="left",_="focus";var b=i.extend({init:function(t,r){var o=this;i.fn.init.call(o,t,r),r=e.extend(!0,{},r),o.options.value=r.value||o.element.val(),o.options.separator=n.isPresent(r.separator)?r.separator:null,o.options.inputMode=r.inputMode||e(t).attr("inputmode")||"text",o._wrapper(),o._renderGroups(o.options.items),o._attachHandlers(),o.value(o.options.value),o.element.on(u+h,o._change.bind(o))},events:[u],options:{name:"OTPInput",type:"text",value:"",placeholder:"",separator:null,readonly:!1,enable:!0,space:!1,size:"medium",rounded:"medium",fillMode:"solid"},enable:function(t){let i=this._inputs;n.isEmpty(i)||e(i).each((function(){this.getKendoTextBox().enable(t)}))},readonly:function(t){let i=this._inputs;n.isEmpty(i)||e(i).each((function(){this.getKendoTextBox().readonly(t)}))},focus:function(){let e=this._inputs;n.isEmpty(e)||e[0].focus().select()},value:function(n){let i=this,r=i._groupLength,o=i.options.type;if(n===t)return i._value;if(null===n&&(i.element.val(n),i._value=n,i._emptyValues()),r>0&&n){if(i._emptyValues(),!i._validate(o,n))return;let t=n.toString().split("");t.length>r&&(t=t.splice(0,r)),i._inputs.forEach((function(n,i){let r=t.at(i);e(n).val(r)}));let a="";i._inputs.forEach((function(t){a=a+=e(t).val()})),i.element.val(a),i._value=a}},destroy:function(){let t=this,r=t._inputs;if(!n.isEmpty(r)){r.forEach((function(t){let n=e(t)[0];e(n).getKendoTextBox().destroy()})),r.map((function(t){return e(t)[0].closest(`.${l}`)})).forEach((function(t){e(t).remove()})),t.wrapper.find(`.${p}`).remove(),t.wrapper.find(`.${c}`).remove(),t.element.unwrap().removeClass(o).removeAttr("type").removeAttr("aria-hidden"),i.fn.destroy.call(t)}},setOptions:function(e){let t=this;t.destroy(),n.deepExtend(t.options,e),t.init(t.element,t.options)},_change:function(e){let t=this,n=t.element.val();t._value=n,t.trigger(u,{value:n})},_wrapper:function(){let e,t=this,i=t.element;let r=n.cssProperties.defaultValues.size[t.options.size];e=i.addClass(o).attr("type","hidden").attr("aria-hidden",!0).wrap(`<div class='k-otp k-otp-${r||"md"}' role="group" ></div>`).parent(),t.wrapper=e},_renderGroups:function(t){let i=this,r=i.options.separator,o=[];if(i._inputs=[],n.isInteger(t)){i._groupLength=t;for(let n=0;n<t;n++){let t=i._renderInput(n+1);o.push(t),i._inputs.push(e(t).find(`.${d}`))}if(i.options.space)i.wrapper.append(o);else{let t=e(`<div class="${p} k-input-group-solid"></div>`).append(o);i.wrapper.append(t)}o=[]}else if(Array.isArray(t)){i._groupLength=t.reduce(((e,{groupLength:t})=>e+t),0);let a=0;t.forEach((function(s,l){if(s.groupLength){for(let t=0;t<s.groupLength;t++){++a;let t=i._renderInput(a);o.push(t),i._inputs.push(e(t).find(`.${d}`))}if(i.options.space)l!=t.length-1&&o.push(i._renderSeparator()),i.wrapper.append(o);else{let a=e(`<div class="${p} k-input-group-solid"></div>`).append(o);i.wrapper.append(a),n.isPresent(r)&&l!=t.length-1&&i.wrapper.append(i._renderSeparator())}o=[]}})),a=0}},_renderInput:function(t){let n,i=this,o=i.options.inputMode;n=e("<input>").addClass(d).attr("inputmode",o).attr("type","password"==i.options.type?"password":"text").attr("aria-label","numeric"==i.options.type?`Enter Otp Numerical Character ${t}`:`Enter Otp Character ${t}`).attr("placeholder",i.options.placeholder).attr("autocomplete","off").attr("maxlength",1);let a=e.extend({},{maxLength:1,size:i.options.size,rounded:i.options.rounded,fillMode:i.options.fillMode,enable:i.options.enable,readonly:i.options.readonly});let s=new r(n,a).wrapper;return s.removeClass(d).addClass(l),s},_renderSeparator:function(){let t=this.options.separator;let i=e(`<div class="${c}"></div>`);return n.isPresent(t)&&(n.isFunction(t)?i.append(t()):i.append(t)),i},_input:function(n){let i=this,r=n.currentTarget,o=i._inputs.length,a=i._oldValue,s=n.currentTarget.value,c=i.options.type;if(!i._validate(c,s))return i._blinkInvalidState(r),e(r).val(""),a!=t&&(e(r).val(a),delete i._oldValue),void e(r).trigger(_);let h=e(i.wrapper).find(`.${l}`),p=h.find(":focus"),f=h.find(`.${d}`).index(p);let m=i._inputs.map((function(t){return e(t).val()})).join("");m!=i._value&&(i.element.val(""),i.element.val(m),i._value=m,i.trigger(u,{value:m})),i._moveFocus(undefined,f,o,g)},_attachHandlers:function(){let e=this,t=e._inputs,i=`.${d}`;n.isEmpty(t)||e.wrapper.on("focus"+h,i,e._focus.bind(e)).on("beforeinput"+h,i,e._beforeInput.bind(e)).on("input"+h,i,e._input.bind(e)).on("keydown"+h,i,e._keyDown.bind(e)).on("paste"+h,i,e._paste.bind(e))},_beforeInput:function(n){let i=this,r=n.currentTarget;if(r&&e(r).val()!=t){let t=e(r).val();i._oldValue=t}},_focus:function(t){let n=t.currentTarget;n&&e(n).select()},_validate:function(e,t){return"number"!=e||m.test(t)},_paste:function(t){let i,r=this,o=r._inputs,a=r.options.readonly,s=n.support.isRtl(r.element),c=e(r.wrapper).find(`.${l}`),d=r.options.type,h=(t.clipboardData||t.originalEvent.clipboardData||window.clipboardData).getData("text");if(t.preventDefault(),h&&1!=a){if(!r._validate(d,h))return this._blinkInvalidState.bind(r),void this._blinkInvalidState(r.wrapper);if(r.value(h),r.trigger(u,{newValue:r._value}),s){if(r._value.length==r._inputs.length)i=r._shiftFocus(c,0,v);else{let t=o.map((function(t){return e(t)})).filter((function(e){let t=e.val();return""==t||n.isBlank(t)}));let r=e(t)[0];i=e(r).closest(`.${l}`)}e(i).find("input").trigger(_)}else{if(r._value.length==r._inputs.length)i=r._shiftFocus(c,c.length-2,g);else{let t=o.map((function(t){return e(t)})).filter((function(e){let t=e.val();return""==t||n.isBlank(t)}));let r=e(t).first()[0];i=e(r).closest(`.${l}`)}e(i).find("input").trigger(_)}}},_keyDown:function(t){let i,r=this,o=t.keyCode||t.which,a=t.currentTarget,c=r._inputs.length,h=e(r.wrapper).find(`.${l}`),p=h.find(":focus"),f=""!=p.val(),m=h.find(`.${d}`).index(p),b=n.support.isRtl(r.element);if(!(t.target!=a||t.ctrlKey||o>=112&&o<=123||o>=96&&o<=111||t.shiftKey&&o==s.TAB||o==s.TAB))if(o===s.LEFT&&!b||t.keyCode===s.RIGHT&&b)i=r._shiftFocus(h,m,v),r._moveFocus(i,m,c,v),t.preventDefault();else if(o===s.LEFT&&b||t.keyCode===s.RIGHT&&!b)i=r._shiftFocus(h,m,g),r._moveFocus(i,m,c,g),t.preventDefault();else if(o===s.DELETE){if(t.preventDefault(),!e(p).is("[readonly]")){p.val("");let t=r._inputs.map((function(t){return e(t).val()})).join("");f&&(r._value=t,r.trigger(u,{value:t})),r.element.val(""),r.element.val(t)}}else if(o==s.BACKSPACE&&(t.preventDefault(),i=r._shiftFocus(h,m,v),!e(p).is("[readonly]"))){p.val("");let t=r._inputs.map((function(t){return e(t).val()})).join("");f&&(r._value=t,r.trigger(u,{value:t})),r.element.val(""),r.element.val(t),(m>0&&!b||m==h.length-1&&b||m>0&&!b||m>0&&b)&&i.find("input").trigger(_)}},_shiftFocus:function(t,n,i){switch(i){case g:return n+1===t.length?t.eq(0):e(t[n+1]);case v:return 0===n?t.eq(t.length-1):e(t[n-1]);default:return null}},_moveFocus:function(t,n,i,r){let o=this,a=e(o.wrapper).find(`.${l}`);r==g?n!=i-1&&o._shiftFocus(a,n,g).find("input").trigger(_):r==v&&n>0&&o._shiftFocus(a,n,v).find("input").trigger(_)},_emptyValues:function(){this._inputs.forEach((function(t){e(t).val("")}))},_blinkInvalidState:function(t){let n=this,i=e(t).hasClass("k-otp");n._addInvalidState.bind(n),n._addInvalidState(t,i),clearTimeout(n._invalidStateTimeout),n._invalidStateTimeout=setTimeout((function(){n._removeInvalidState.bind(n),n._removeInvalidState(t,i)}),100)},_addInvalidState:function(t,i=!1){let r=this._inputs;if(i){if(!n.isEmpty(r)){let t=r.map((function(t){return e(t).closest(`.${l}`)}));e(t).each((function(){e(this).addClass(f)}))}}else e(t).closest(`.${l}`).addClass(f)},_removeInvalidState:function(t=!1){let i=this,r=i._inputs;if(t){if(!n.isEmpty(r)){let t=r.map((function(t){return e(t).closest(`.${l}`)}));e(t).each((function(){e(this).removeClass(f)}))}}else e(i).closest(`.${l}`).removeClass(f);i._invalidStateTimeout=null}});n.cssProperties.registerPrefix("OTPInput","k-input-"),a.plugin(b)}(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";var d="equalSet";var h=["url","email","number","date","boolean"];function u(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=u(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,h)>=0)m[p]=n;else if(!o(i)){var g=t.getCulture();if("number"==typeof i&&g.name.length){var v=g.numberFormat;var _=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,h)>=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","OTPInput","Upload"];var g={hidden:function(t,n){let i=p(n);e('<input type="hidden"/>').attr(i).appendTo(t)},number:function(n,i){let 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)},file:function(n,i){let o=p(i);e('<input type="file"/>').attr(o).appendTo(n).kendoUpload(r({},i.editorOptions)),e("<span "+t.attr("for")+'="'+i.field+'" class="k-invalid-msg k-hidden"/>').appendTo(n)},date:function(n,i){let o=p(i);let a=i.format;let s=o.min;let l=o.max;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,min:s,max:l})),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);var 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);var 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,"'"):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);var r=n.editor;var o="kendo"+r;var a=n.editorOptions;var 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)}};var v={number:function(t,n){let i=p(n);i=f(t,i),e('<input type="number"/>').attr(i).appendTo(t)},file:function(n,i){let o=p(i);o=f(n,o),e('<input type="file"/>').attr(o).appendTo(n).kendoUpload(r({},i.editorOptions)),e("<span "+t.attr("for")+'="'+i.field+'" class="k-invalid-msg k-hidden"/>').appendTo(n)},date:function(t,n){let i=p(n);i=f(t,i),e('<input type="date"/>').attr(i).appendTo(t)},string:function(t,n){let 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){let 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 w=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),h=d?n.field:n,p=s.options.model||{},f=d&&n.values?"values":u(i),g=d&&"string"==typeof n.editor&&"hidden"===n.editor,_=d&&!g&&n.editor,b=d&&-1!==e.inArray(n.editor,m),w=_?n.editor:c[g?"hidden":f],y=s.element.find("["+t.attr("container-for")+"="+h.replace(l,"\\$1")+"]");w=w||c.string,b?w=c.kendoEditor:_&&"string"==typeof n.editor&&(w=function(e){e.append(n.editor)}),d?(n.editorOptions||(n.editorOptions={}),n.editorOptions=r({},{size:s.options.size},n.editorOptions),o=n):o={field:h,editorOptions:{size:s.options.size}},w(y=y.length?y: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"),h=n.field.replace(l,"\\$1"),u=new RegExp("(value|checked)\\s*:\\s*"+h+"\\s*(,|$)");s[n.field]=n.value,(i=e(":input["+d+'*="'+h+'"]',r.element).filter("["+t.attr("validate")+"!='false']").filter((function(){return u.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,h=c.options.fields||[],u=c._container=c.options.clearContainer?c.element.empty():c.element,p=c.options.model||{},f={};for(Array.isArray(h)||(h=[h]),n=0,i=h.length;n<i;n++)r=h[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")===w.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))}))}(u),c.validatable&&c.validatable.destroy(),t.bind(u,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(u,{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")}});w.antiForgeryTokenName="__RequestVerificationToken",n.plugin(w)}(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,h=e.extend,u=e.each,p=i.template,f="body",m=".kendoWindow",g=".kendoWindowModal",v=".k-window",_=".k-window-title",b=_+"bar",w=".k-window-content",y=".k-resize-handle",k=".k-overlay",x="k-window-minimized",C="k-content-frame",S="k-i-loading",T="k-hover",M="k-focus",A="k-window-maximized",D="k-display-inline-flex",E=":visible",I="k-hidden",z="hidden",P="cursor",L="open",B="activate",H="deactivate",R="close",F="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){var n={top:t.offsetTop,left:t.offsetLeft},i=t.offsetParent;for(;i;){n.top+=i.offsetTop,n.left+=i.offsetLeft;var r=e(i).css("overflowX");var 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,h,u,p,f,g,y=this,k={},x=a&&a.actions&&!a.actions.length;r.fn.init.call(y,n,a),h=(a=y.options).position,n=y.element,u=a.content,f=e(window),x&&(a.actions=[]),y.appendTo=e(a.appendTo),y.containment=a.draggable.containment?e(a.draggable.containment).first():null,u&&!s(u)&&(u=a.content={url:u}),n.find("script").filter(se).remove(),n.parent().is(y.appendTo)||y.containment||h.top!==t&&h.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})),h.top===t&&(h.top=k.top),h.left===t&&(h.left=k.left)),re(a.visible)&&null!==a.visible||(a.visible=n.is(E)),l=y.wrapper=n.closest(v),n.is(".k-window-content")&&l[0]||(n.addClass("k-window-content"),n.attr("tabindex",0),y._createWindow(n,a),l=y.wrapper=n.closest(v),y.title(y.options.title),y._dimensions(),a._footerTemplate&&y.wrapper.append(i.template(a._footerTemplate)(a._footerMessages))),a.themeColor&&"none"!==a.themeColor&&l.addClass(i.getValidCssClass("k-window-","themeColor",a.themeColor)),y.minTop=y.minLeft=-1/0,y.maxTop=y.maxLeft=1/0,y._position(),u&&y.refresh(u),a.visible&&y.toFront(null,!a.modal),p=l.children(w),a.visible&&a.modal&&y._overlay(l.is(E)).css({opacity:.5}),l.on("mouseenter"+m,Z,y._buttonEnter.bind(y)).on("mouseleave"+m,Z,y._buttonLeave.bind(y)).on("click"+m,"> "+Z,y._windowActionHandler.bind(y)).on("keydown"+m,y,y._keydown.bind(y)).on("focus"+m,y._focus.bind(y)).on("blur"+m,y._blur.bind(y)),p.on("keydown"+m,y,y._keydownContent.bind(y)),p.find("."+C)[0]&&!f.data(ee)&&(f.on("blur"+m,(function(){var t=e(document.activeElement).parent(w);t.length&&i.widgetInstance(t)._focus()})),f.on("focus"+m,(function(){e(w).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")&&y.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,y.toFront.bind(y)),y.touchScroller=i.touchScroller(n),y._resizeHandler=y._onDocumentResize.bind(y),y._marker=i.guid().substring(0,8),e(window).on("resize"+m+y._marker,y._resizeHandler),a.visible&&(y.trigger(L),y.trigger(B)),i.notify(y),this.options.modal&&(this._tabKeyTrap=new o(l),this._tabKeyTrap.trap(),this._tabKeyTrap.shouldTrap=function(){return l.data("isFront")}),y._showWatermarkOverlay&&y._showWatermarkOverlay(y.wrapper[0])},_buttonEnter:function(t){e(t.currentTarget).addClass(T)},_buttonLeave:function(t){e(t.currentTarget).removeClass(T)},_focus:function(){this.wrapper.addClass(M)},_blur:function(){this.wrapper.removeClass(M)},_dimensions:function(){var e=this.wrapper;var t=this.options;var n=t.width;var i=t.height;var r=t.maxHeight;var o=t.size;var a=["minWidth","minHeight","maxWidth","maxHeight"];var s="content-box"==e.css("box-sizing");var l=s?oe(e,"border-left-width")+oe(e,"border-right-width"):0;var c=s?oe(e,"border-top-width")+oe(e,"border-bottom-width"):0;var 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 h=0;h<a.length;h++){var u=t[a[h]]||"";u!=1/0&&e.css(a[h],u)}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(D).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;var i=this.wrapper;this.resizing&&(i.off("dblclick"+m).children(y).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)),u("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 he(this,e.dragHandle||b,e.clickMoveClick))},_actions:function(){var t=this.options;var r=t.actions;var o=t.pinned;var a=this.wrapper.children(b).find(".k-window-titlebar-actions");var s=["minimize","maximize"];var l={maximize:"window",refresh:"arrow-rotate-cw",custom:"gear"};var c;r=e.map(r,(function(e){return e=o&&"pin"===e.toLowerCase()?"unpin":e,c=l[e.toLowerCase()]||"",{name:s.indexOf(e.toLowerCase())>-1?"window-"+e:e,icon:"close"==e.toLowerCase()?"x":c}})),a.html(i.render(n.action,r))},setOptions:function(t){var n=this;var o=n.options.size;var a=this.containment&&!n._isPinned?this.containment:e(document);var s=JSON.parse(JSON.stringify(t));n.wrapper.removeClass(i.getValidCssClass("k-window-","themeColor",n.options.themeColor)),h(t.position,n.options.position),h(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:[L,B,H,R,"minimize","maximize",F,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,h=e.keyCode,u=l.wrapper,p=10,f=c.isMaximized,m=c.isMinimized;h==d.ESC&&l._closable()&&(e.stopPropagation(),l._close(!1)),e.target!=e.currentTarget||l._closing||(e.altKey&&82==h&&l.refresh(),e.altKey&&80==h&&(l.options.pinned?l.unpin():l.pin()),e.altKey&&h==d.UP?m?(l.restore(),l.wrapper.trigger("focus")):f||(l.maximize(),l.wrapper.trigger("focus")):e.altKey&&h==d.DOWN&&(m||f?f&&(l.restore(),l.wrapper.trigger("focus")):(l.minimize(),l.wrapper.trigger("focus"))),t=i.getOffset(u),l.containment&&!l._isPinned&&(t=l.options.position),!c.draggable||e.ctrlKey||e.altKey||f||(l._updateBoundaries(),h==d.UP?(t.top=ae(t.top-p,l.minTop,l.maxTop),n=u.css("top",t.top)):h==d.DOWN?(t.top=ae(t.top+p,l.minTop,l.maxTop),n=u.css("top",t.top)):h==d.LEFT?(t.left=ae(t.left-p,l.minLeft,l.maxLeft),n=u.css("left",t.left)):h==d.RIGHT&&(t.left=ae(t.left+p,l.minLeft,l.maxLeft),n=u.css("left",t.left))),c.resizable&&e.ctrlKey&&!f&&!m&&(h==d.UP?(n=!0,o=u.outerHeight()-p):h==d.DOWN?(n=!0,o=l.containment&&!l._isPinned?Math.min(u.outerHeight()+p,l.containment.height-t.top-oe(u,"padding-top")-oe(u,"borderBottomWidth")-oe(u,"borderTopWidth")):u.outerHeight()+p):h==d.LEFT?(n=!0,r=u.outerWidth()-p):h==d.RIGHT&&(n=!0,r=l.containment&&!l._isPinned?Math.min(u.outerWidth()+p,l.containment.width-t.left-oe(u,"borderLeftWidth")-oe(u,"borderRightWidth")):u.outerWidth()+p),n&&(a=ae(r,c.minWidth,c.maxWidth),s=ae(o,c.minHeight,c.maxHeight),isNaN(a)||(u.outerWidth(a),l.options.width=a+"px"),isNaN(s)||(u.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");var i=this._actionForIcon(n);return i?(t.preventDefault(),this[i](),!1):void 0}},_modals:function(){var t,n=this,i=e(v+E),r=[];for(var 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(w).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(w),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(w),c=this.containment&&!r._isPinned?this.containment:e(document);if(!r.trigger(L)){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(B)},_removeOverlay:function(n){var r=this._modals();var o=this.options;var a=o.modal&&!r.length;var 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(R,{userTriggered:!t}),i._closing=!n,r.is(E)&&!n&&(o.visible=!1,e(v).each((function(t,n){var i=e(n).children(w);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(D).hide().css("opacity",""),e.trigger(H),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,h=t&&t.target||null;if(e(v).each((function(t,i){var r=e(i),s=r.css(G),l=r.children(w);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(h)){i||setTimeout((function(){r.wrapper.trigger("focus")}),l?l.duration:0);var u=s?r.containment.scrollTop():e(window).scrollTop(),p=parseInt(o.position().top,10);!r.options.pinned&&p>0&&p<u&&(u>0?e(window).scrollTop(p):o.css("top",u))}return o=null,r},toggleMaximization:function(){return this._closing?this:this[this.options.isMaximized?"restore":"maximize"]()},restore:function(){var t=this;var n=t.options;var i=n.minHeight;var r=t.restoreOptions;var 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)),h(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(y).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);h(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;var 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;var 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(h(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(h(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;var d=l?oe(o,"border-top-width")+oe(o,"border-bottom-width"):0;var h=l?oe(o,"padding-top"):0;r.containment&&!r._isPinned?(t=r.containment.innerWidth()-c,n=r.containment.innerHeight()-(d+h)):(t=a.width()/s-c,n=a.height()/s-(d+h)),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=h(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(h({},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(F)),c.toggleClass("k-window-iframecontent",!!r),a},_triggerRefresh:function(){this.trigger(F)},_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(F)}},_showLoading:function(){this.wrapper.find(J).addClass(S)},_ajaxRequest:function(t){this._loadingIconTimeout=setTimeout(this._showLoading.bind(this),100),e.ajax(h({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(w).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:">"+y,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 he(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;var r=n.owner;var 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");var l=a.css("margin-left");if(!te.test(s)||!te.test(l)){var c=le(o[0]);var d=c.left-n.containerOffset.left-n.initialPosition.left;var h=c.top-n.containerOffset.top-n.initialPosition.top;n._relativeElMarginLeft=d>1?d:0,n._relativeElMarginTop=h>1?h:0,n.initialPosition.left+=n._relativeElMarginLeft,n.initialPosition.top+=n._relativeElMarginTop}}o.children(y).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,h=d.position,u=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},w=Math.max(t.x.location,0),y=Math.max(t.y.location,0);u.indexOf("e")>=0?(n=l.containment&&w-m.width>=l.maxLeft-b.left+p.left+_?l.maxLeft+_-f.left+m.width-b.left:w-f.left-p.left,c.outerWidth(ae(n,d.minWidth,d.maxWidth))):u.indexOf("w")>=0&&(n=ae((a=f.left+m.width+p.left)-w,d.minWidth,d.maxWidth),h.left=a-n-p.left-_-(s._relativeElMarginLeft||0)+b.left,l.containment&&h.left<=l.minLeft&&(h.left=l.minLeft,n=ae(a-_-h.left-p.left+b.left,d.minWidth,d.maxWidth)),c.css({left:h.left,width:n}));var k=y;l.options.pinned&&(k-=e(window).scrollTop()),u.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))):u.indexOf("n")>=0&&(r=ae((o=f.top+m.height+p.top)-k,d.minHeight,d.maxHeight),h.top=o-r-p.top-(s._relativeElMarginTop||0)+b.top,h.top<=l.minTop&&l.containment&&(h.top=l.minTop,r=ae(o-h.top-p.top+b.top,d.minHeight,d.maxHeight)),c.css({top:h.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(y).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}},he.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(y).hide(),e(f).css(P,t.currentTarget.css(P)))},drag:function(t){var n=this.owner;var i=n.options.position;var r=n.options.draggable.axis;var o;var a;this._preventDragging||n.isMaximized()||(r&&"x"!==r.toLowerCase()||(o=t.x.client-n.startPosition.left,n.containment&&!n._isPinned&&(o+=n.containment.scrollLeft()),i.left=ae(o,n.minLeft,n.maxLeft)),r&&"y"!==r.toLowerCase()||(a=t.y.client-n.startPosition.top,n.containment&&!n._isPinned&&(a+=n.containment.scrollTop()),i.top=ae(a,n.minTop,n.maxTop)),e(n.wrapper).css("transform","translate("+(i.left-n.initialPointerPosition.left)+"px, "+(i.top-n.initialPointerPosition.top)+"px)"))},_finishDrag:function(){var t=this.owner;t.wrapper.children(y).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){var t=window.kendo,n=t.ui,i=n.Widget;var 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){var n=this.options.grid.items;var i;var r;var o;for(var a=0;a<n.length;a++)r=n[a],o=e("<div></div>"),i=r.shape.toLowerCase(),o.css({"grid-column":t.format("{0} / span {1}",r.colStart,r.colSpan),"grid-row":t.format("{0} / span {1}",r.rowStart,r.rowSpan)}).addClass("k-skeleton").addClass(t.format("k-skeleton-{0}","rectangle"===i?"rect":i)),o.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(){var e=["circle","rect","text"];var t=["wave","pulse"];for(var 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;var n=e.options;var i=n.grid;var 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,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,h=r.Widget,u=i.data.HierarchicalDataSource,p=/^(ul|a|div)$/i,f=".kendoPanelBar",m="href",g="k-link",v="."+g,_="error",b=".k-panelbar-item",w=".k-panelbar-group:visible",y="k-image",k="change",x="expand",C="select",S="click",T="k-panelbar-content",M="activate",A="collapse",D="dataBound",E="mouseenter",I="contentLoad",z="k-expanded",P="> .k-panelbar-group",L="> .k-panelbar-content",B="k-focus",H="k-disabled",R="k-selected",F="."+R,O=b+":not(.k-disabled)",V="> "+O+" > "+v+", .k-panelbar-group > "+O+" > "+v,N=b+".k-disabled > .k-link",$="> li > "+F+", .k-panelbar-group > li > "+F,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+=" "+H:!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+=" "+R),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?"":" "},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,h.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,M,k,_,D,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(){h.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);var h=r("imageUrl")(n);var u=r("spriteCssClass")(n);var p=r("icon")(n);var f=r("iconClass")(n);f=f?" "+f:"";c=c(n);var m=d||c?"a":"span";return`<${m} class='${a(n)}' ${c}${l(d)}>`+(h?`<img class='k-panelbar-item-icon k-image' alt='' src='${h}' />`:"")+(u?`<span class='k-sprite ${u}'></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:h,contentUrl:u,textClass:p,textAttributes:f})=>`<li aria-selected='false' role='treeitem' ${d(n)}class='${h(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:h,contentUrl:u,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:h,contentUrl:u,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),h.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(L));if(!a.hasClass(H)&&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(L));!o.hasClass(H)&&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;var 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;var 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);var l=this.element.children(".k-panelbar-item");for(var 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){var n=this.element.find(".k-panelbar-item");var r=i.attr("uid");var o;for(var a=0;a<n.length;a++)if(n[a].getAttribute(r)==t){o=n[a];break}return e(o)},refresh:function(e){var n=this.options;var i=e.node;var r=e.action;var o=e.items;var a=this.wrapper;var 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(D,{node:i?a:t})},_error:function(e){var t=e.node&&this.findByUid(e.node.uid);var 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=u.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};var 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 h=0;h<d.length;h++)0===o.length||0===t?s.append(d[h]):d[h].insertAfter(o[t-1]);l.dataItem(r)&&(l.dataItem(r).hasChildren=!0,l.updateArrow(r))},_updateItems:function(t,n){var i=this;var o,s,l,c;var d={panelBar:i.options,item:c,group:{}};var h="expanded"!=n;if("selected"==n)if(t[0][n]){var u=i.findByUid(t[0].uid);u.hasClass(H)||i.select(u,!0)}else i.clearSelection();else{var p=e.map(t,(function(e){return i.findByUid(e.uid)}));for(o=0;o<t.length;o++)d.item=c=t[o],d.panelBar=i,s=(l=p[o]).parent(),h&&(d.group={firstLevel:s.hasClass("k-panelbar"),expanded:l.parent().hasClass(z),length:l.children().length},l.children(".k-link").remove(),l.prepend(i.templates.itemWrapper(a(d,{arrow:c.hasChildren||c.content||c.contentUrl?i.templates.arrow:i.templates.empty},Q)))),"expanded"==n?i._toggleItem(l,!c[n],!c[n]||"true"):"enabled"==n&&(i.enable(l,c[n]),c[n]||c.selected&&c.set("selected",!1)),l.length&&this.trigger("itemChange",{item:l.find(".k-link").first(),data:c,ns:r})}},_toggleDisabled:function(e,t){(e=this.element.find(e)).toggleClass(H,!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(H))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(w);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(B)),e(n).length&&(o=n[0].id||o,n.attr("id",o).children(v).addClass(B),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(w),n=e.nextAll(":visible").first();return t[0]&&(n=t.children().first()),n[0]||(n=e.parent(w).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(w).children().last())[0]&&(n=t);else(n=e.parent(w).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 u){if(t instanceof u&&(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 h=l.dataItem(n);h?(h.hasChildren=!0,n.attr(W,h.expanded).not("."+z).children("ul").attr(j,!h.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."+H).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){var t=e.length,n=0;for(;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(y),(o=t.children("a").addClass(g))[0]&&(o.attr("href",l),o.children("img").addClass(y)),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(F))[0]&&(a&&a.attr(q,!1).children(F).removeClass(R),o.addClass(R),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."+H).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");var h=this.dataItem(c);if(!d.length&&(o.options.loadOnDemand&&h&&h.hasChildren||this._hasChildItems(c)||c.content||c.contentUrl)&&(d=o._addGroupElement(c)),i=c.find(P).add(c.find(L)),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 u=i.is(G);o._triggerEvent(u?A:x,c)||(n=o._toggleItem(c,u))}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;var h=c&&c.loaded();return c&&!i&&c.expanded!==d?(c.set("expanded",d),r=c.hasChildren||!!c.content||!!c.contentUrl):(!c||i&&"true"!==i||h||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(M,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;var o=t.find(P).add(t.find(L));return o.is(G)&&(r=!0),o.is(G)||0===o.length||((n=t.siblings()).find(P).add(n.find(L)).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(R),e.addClass(R),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,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=".",h="id",u="left",p="right",f="bottom",m="aria-disabled",g="aria-expanded",v="role",_="click",b="expand",w="collapse",y="mouseenter"+r+" mouseleave"+r;var 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"};var 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"}):"");var 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,w],_offsetMap:{start:u,end:p,top:"top",bottom:f},_reversedOffsetMap:{start:p,end:u},_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(h):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(h);e||(e=n.guid()),this._list.attr(h,e+"-list")},_getPopupPosition:function(){var e,t,n=this.options.align,i=s.isRtl(this.element),r=i?p:u,o=i?u: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(w)&&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(y,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),h=n._list.children(),u=h.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(u===h.length-1)return void h.first().trigger("focus");e(h[u+1]).trigger("focus")}if(!l&&r===a.UP||l&&r===a.DOWN){if(0===u)return void h.last().trigger("focus");e(h[u-1]).trigger("focus")}r!==a.ESC&&r!==a.TAB||(s.close(),o.trigger("focus")),r===a.HOME&&h.first().trigger("focus"),r===a.END&&h.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){const t="assistant";class n{constructor(e,t={}){this.aiprompt=e,this.options=t,this.buttonDefinitions=this._createButtonDefinitions()}static getBuiltInActionDefinitions(){return{copy:{command:"copy",icon:"copy",fillMode:"flat",themeColor:"primary",text:null},retry:{command:"retry",icon:"arrow-rotate-cw",fillMode:"flat",text:null},ratePositive:{command:"ratePositive",icon:"thumb-up-outline",fillMode:"flat",iconButton:!0,text:null},rateNegative:{command:"rateNegative",icon:"thumb-down-outline",fillMode:"flat",iconButton:!0,text:null},stop:{command:"stop",icon:"stop",fillMode:"flat",text:null}}}static processOutputActions(e){if(!e)return null;const t=n.getBuiltInActionDefinitions();return e.map((e=>"string"==typeof e?"rating"===e?[t.ratePositive,t.rateNegative]:"spacer"===e?{type:"spacer"}:t[e]||{command:e,type:"button"}:kendo.isPresent(e.command)&&"rating"==e.command?[t.ratePositive,t.rateNegative]:e)).flat()}_createButtonDefinitions(){const e=this;const t=n.getBuiltInActionDefinitions();return{copy:{...t.copy,getMessage:()=>e.view.options.messages.copyOutput,handler:(t,n)=>e._handleCopyAction(t,n)},retry:{...t.retry,getMessage:()=>e.view.options.messages.retryGeneration,handler:(t,n)=>e._handleRetryAction(t,n)},ratePositive:{...t.ratePositive,getMessage:()=>e.view.options.messages.ratePositive,handler:(t,n)=>e._handleRatePositiveAction(t,n)},rateNegative:{...t.rateNegative,getMessage:()=>e.view.options.messages.rateNegative,handler:(t,n)=>e._handleRateNegativeAction(t,n)},stop:{...t.stop,getMessage:()=>e.view.options.messages.stopGeneration,handler:(t,n)=>e._handleStopAction(t,n)}}}initializeButtons(e,t=null){const n=this;t&&t.forEach((t=>{if("spacer"===t.type)return;const i=`[data-action-command="${t.command}"]`;n._initializeButton(e,i,t)}))}_initializeButton(e,t,n){const i=this;const r=i.buttonDefinitions[n.command];e.find(t).kendoButton({icon:n.icon||r?.icon,fillMode:n.fillMode||r?.fillMode||"flat",themeColor:n.themeColor||r?.themeColor||"base",rounded:n.rounded,click:function(e){const t=i.aiprompt.outputManager.getOutputFromElement(e.target);const o={command:n.command,outputId:t.id,output:t.output||t.text||t||"",prompt:t.prompt||"",button:e.sender.element};r?.handler&&!i.aiprompt.trigger("outputAction",o)?r.handler(e,t):r||i.aiprompt.trigger("outputAction",o)}})}_handleCopyAction(e,t){const n=this.aiprompt._events&&this.aiprompt._events.outputCopy&&this.aiprompt._events.outputCopy.length>0;n&&kendo.logToConsole("The outputCopy event is deprecated. Use the outputAction event instead.","warn");const i={output:t};n&&this.aiprompt.trigger("outputCopy",i)||navigator.clipboard&&"function"==typeof navigator.clipboard.writeText&&navigator.clipboard.writeText(t.output||t.text||t||"")}_handleRetryAction(e,n){const{prompt:i,output:r}=this.aiprompt.outputManager.extractOutputData(n);const o=this;const a={prompt:i,output:n,isRetry:!0,history:[{role:t,contents:[{$type:"text",text:r}]}]};const s=o.aiprompt?._selectedView?.service;s&&(a.service=s),o.aiprompt.trigger("promptRequest",a)||o.aiprompt?.options.service&&o.aiprompt?.transport?.read({prompt:i,history:a.history,isRetry:!0,service:a.service})}_handleRatePositiveAction(t,n){this.aiprompt._events&&this.aiprompt._events.outputRating&&this.aiprompt._events.outputRating.length>0&&kendo.logToConsole("The outputRating event is deprecated. Use the outputAction event instead.","warn"),this.aiprompt.trigger("outputRating",{rateType:"positive",output:n}),kendo.ui.icon(t.sender.element.find(".k-icon"),"thumb-up");const i=e(t.target).siblings("[data-action-command='rateNegative'], [ref-rate-negative]");kendo.ui.icon(i.find(".k-icon"),"thumb-down-outline")}_handleRateNegativeAction(t,n){this.aiprompt._events&&this.aiprompt._events.outputRating&&this.aiprompt._events.outputRating.length>0&&kendo.logToConsole("The outputRating event is deprecated. Use the outputAction event instead.","warn"),this.aiprompt.trigger("outputRating",{rateType:"negative",output:n}),kendo.ui.icon(t.sender.element.find(".k-icon"),"thumb-down");const i=e(t.target).siblings("[data-action-command='ratePositive'], [ref-rate-positive]");kendo.ui.icon(i.find(".k-icon"),"thumb-up-outline")}_handleStopAction(t,n){this.aiprompt.trigger("promptRequestCancel",{output:n}),e(t.target).siblings(".k-hidden").removeClass("k-hidden"),e(t.target).addClass("k-hidden")}destroy(){this.aiprompt=null,this.options=null,this.buttonDefinitions=null}}kendo.ui.AIPromptOutputActionManager=n}(window.kendo.jQuery),function(){const e="k-prompt-view",t="k-prompt-expander",n="k-suggestion-group",i="k-suggestion",r="k-card",o="k-card-list",a="k-card-header",s="k-card-title",l="k-card-subtitle",c="k-card-body",d="k-card-actions",h="k-actions k-actions-start k-actions-horizontal",u="k-spacer";const p="ref-prompt-input",f="ref-prompt-suggestions-button",m="ref-generate-output-button",g="ref-output-body";class v{static createPromptView({suggestions:t,promptSuggestionItemTemplate:n,messages:i}){const r=t?.length?v._createSuggestionsSection(t,n,i):"";return`<div class="${e}">\n <textarea ${p}></textarea>\n ${r}\n </div>`}static createPromptFooter({messages:e}){return`<div class="${h} k-prompt-actions">\n <button ${m}>${e.generateOutput}</button>\n </div>`}static createSuggestionItem({suggestion:e}){return`<span role="listitem" class="${i}">${e}</span>`}static createOutputCard({output:e,showOutputRating:t,messages:n,showOutputSubtitleTooltip:i,encodedPromptOutputs:o,isStreaming:a,outputActions:s,outputTemplate:l}){const c=v._generateContentHtml({output:e,outputTemplate:l,encodedPromptOutputs:o});const d=v._generateActionsHtml({outputActions:s,showOutputRating:t,messages:n,isStreaming:a});const h=e.id?` data-id="${e.id}"`:"";return`<div role="listitem" tabindex="0" class="${r}"${h}>\n ${e.skipHeader?"":v._createCardHeader(e,n,i)}\n ${e.skipBody?"":v._createCardBody(c,e.isLoading)}\n ${e.skipActions?"":d}\n </div>`}static createOutputView({promptOutputs:t,showOutputRating:n,messages:i,showOutputSubtitleTooltip:r,encodedPromptOutputs:a,outputActions:s,outputTemplate:l}){const c=t?t.map((e=>v.createOutputCard({output:e,showOutputRating:n,messages:i,showOutputSubtitleTooltip:r,encodedPromptOutputs:a,outputActions:s,outputTemplate:l}))).join(""):"";return`<div class="${e}">\n <div role="list" class="${o}">\n ${c}\n </div>\n </div>`}static _createSuggestionsSection(e,i,r){const o=e.map((e=>i({suggestion:e}))).join("");return`<div class="${t}">\n <button ${f} aria-expanded="true">${r.promptSuggestions}</button>\n <div class="k-prompt-expander-content" role="list">\n <div class="${n}">\n ${o}\n </div>\n </div>\n </div>`}static _createCardHeader(e,t,n){const i=n?`title="${kendo.htmlEncode(e.prompt)}"`:"";return`<div class="${a}">\n <div class="${s}">${t.outputTitle}</div>\n <div class="${l}" ${i}>${kendo.htmlEncode(e.prompt)}</div>\n </div>`}static _createCardBody(e,t){return`<div class="${c}" ${g}>\n ${e}\n </div>`}static _generateContentHtml({output:e,outputTemplate:t,encodedPromptOutputs:n}){if(t&&"function"==typeof t&&!e.isLoading&&e.output)return t({output:e,content:e.output});const i=e.output||"";return`<p ref-output-content${e.isLoading?' data-loading="true"':' data-loading="false"'}>${n?kendo.htmlEncode(i):i}</p>`}static _generateActionsHtml({outputActions:e,showOutputRating:t,messages:n,isStreaming:i}){return e||(e=t?["copy","retry","spacer","rating"]:["copy","retry"]),v._createCustomActions(e,t,n,i)}static _createCustomActions(e,t,n,i){const r=e.filter((e=>"stop"!==e.command));const o=r.some((e=>"ratePositive"===e.command||"rateNegative"===e.command));let a=[...r];if(t&&!o){a.some((e=>"spacer"===e.type))||a.push({type:"spacer"}),a.push({command:"ratePositive",text:n.ratePositive,type:"button"},{command:"rateNegative",text:n.rateNegative,type:"button"})}const s=a.map((e=>v._createActionButton(e,n,i))).join("");return`<div class="${h} ${d}">\n ${s}\n </div>`}static _createActionButton(e,t,n){if("spacer"===e.type)return`<span class="${u}"></span>`;const i=e.text||v._getActionText(e.command,t);const r=e.title||i;return`<button data-action-command="${e.command}" title="${r}">${e.iconButton?"":i}</button>`}static _getActionText(e,t){return{copy:t.copyOutput,retry:t.retryGeneration,ratePositive:t.ratePositive,rateNegative:t.rateNegative}[e]||e}}kendo.ui.AIPromptTemplateBuilder=v}(window.kendo.jQuery),function(e){kendo.ui.AIPromptSpeechManager=class{constructor(e,t={}){this.view=e,this.aiprompt=e.aiprompt,this.options=this._processSettings(t),this._speechButton=null}_processSettings(t){const n={integrationMode:"webSpeech",lang:"en-US",continuous:!1,interimResults:!1,maxAlternatives:1};return!1===t||null===t?{enabled:!1,options:null}:!0===t?{enabled:!0,options:n}:"object"==typeof t?{enabled:!0,options:e.extend({},n,t)}:{enabled:!0,options:n}}isEnabled(){return this.options.enabled}getTextAreaSuffixOptions(){return this.isEnabled()?{suffixOptions:{template:function(){return'<button ref-speech-to-text-button title="Speech to Text"></button>'},separator:!1}}:{}}initialize(e){if(!this.isEnabled()||!e)return!1;const t=e.wrapper.find("button[ref-speech-to-text-button]");return 0!==t.length&&(this._speechButton=t.kendoSpeechToTextButton({...this.options.options,fillMode:"flat"}).getKendoSpeechToTextButton(),this._speechButton.bind("result",(t=>this._handleResult(t,e))),this.aiprompt.speechToTextButton=this._speechButton,!0)}_handleResult(e,t){if(e.isFinal||!this.options.options.interimResults){const n=e.alternatives[0]?.transcript||"";const i=t.value();let r=i?i+" "+n:n;const o=t.options.maxlength;o&&r.length>o&&(r=r.substring(0,o)),t.value(r)}}startRecognition(){this._speechButton&&this._speechButton.startRecognition()}stopRecognition(){this._speechButton&&this._speechButton.stopRecognition()}abortRecognition(){this._speechButton&&this._speechButton.abortRecognition()}isListening(){return!!this._speechButton&&this._speechButton.isListening()}destroy(){this._speechButton&&(this._speechButton.destroy(),this._speechButton=null)}}}(window.kendo.jQuery),function(e){class t{constructor(e,t){this.id=e.id,this.data=e,this._element=null,this._bodyElement=null,this._aiprompt=t.aiprompt,this._isLoading=e.isLoading||!1}get isLoading(){return this._isLoading}set isLoading(e){const t=this._isLoading;this._isLoading=e,this.data.isLoading=e,!0===e?this.showSkeleton():!1===e&&(this.hideSkeleton(),(t||this.data.output)&&this.applyFinalTemplate())}getElement(){return this._element}setElement(e){return this._element=e,this}updateContent(e){if(!this._element||0===this._element.length)return this;this.data.content=e,this.data.output=e;const t=this._element.find(".k-card-body");const n=t.find("[ref-output-content]");if(e&&e.trim()&&n.length>0){t.find(".k-skeleton").remove(),n.attr("data-loading","false").show();const i=this._aiprompt.options.encodedPromptOutputs;n.html(i?kendo.htmlEncode(e):e)}return this}showSkeleton(){return this.showHeaderSkeleton(),this.showBodySkeleton(),this.showActionSkeleton(),this}hideSkeleton(){return this.hideHeaderSkeleton(),this.hideBodySkeleton(),this.hideActionSkeleton(),this}applyFinalTemplate(){if(!this._element||0===this._element.length)return this;const e=this._element.find(".k-card-body");const t=e.find("[ref-output-content]");let n=this._aiprompt?.options?.outputTemplate;if(!n)return this;if("string"==typeof n&&(n=kendo.template(n)),n&&"function"==typeof n&&this.data.output){const t=n({output:this.data,content:this.data.output});e.html(t)}else t.length>0&&t.attr("data-loading","false").show();return this}showHeaderSkeleton(){if(!this._element||0===this._element.length)return this;const t=this._element.find(".k-card-header");if(0===t.length)return this;if(t.children().hide(),0===t.find(".k-skeleton").length){const n=e('<span class="k-skeleton k-skeleton-text k-skeleton-pulse"></span>');n.css("width","60%").css("height","24px"),t.prepend(n)}return this}hideHeaderSkeleton(){if(!this._element||0===this._element.length)return this;const e=this._element.find(".k-card-header");return 0===e.length||(e.find(".k-skeleton").remove(),e.children().removeClass("k-hidden").show()),this}showBodySkeleton(){if(!this._element||0===this._element.length)return this;const t=this._element.find(".k-card-body");if(t.find("[ref-output-content]").attr("data-loading","true").hide(),0===t.find(".k-skeleton").length){const n=e('<span class="k-skeleton k-skeleton-rect k-skeleton-pulse"></span>');n.css("height","80px"),t.prepend(n)}return this}hideBodySkeleton(){if(!this._element||0===this._element.length)return this;return this._element.find(".k-card-body").find(".k-skeleton").remove(),this.applyFinalTemplate(),this}showActionSkeleton(){if(!this._element||0===this._element.length)return this;const t=this._element.find(".k-card-actions");if(t.length>0&&(t.children().hide(),0===t.find(".k-skeleton").length)){const n=e('<span class="k-skeleton k-skeleton-text k-skeleton-pulse"></span>');n.css("width","100%").css("height","32px"),t.prepend(n)}return this}hideActionSkeleton(){if(!this._element||0===this._element.length)return this;const e=this._element.find(".k-card-actions");return e.length>0&&(e.find(".k-skeleton").remove(),e.children().removeClass("k-hidden").show()),this}toggleActionButtons(e,t){if(!this._element||0===this._element.length)return this;if(t){const t=this._element.find("[data-action-command]");e?t.addClass("k-hidden"):t.removeClass("k-hidden")}else{const t=this._element.find("[ref-copy-button], [ref-retry-button]");e?t.addClass("k-hidden"):t.removeClass("k-hidden")}return this}destroy(){this._element=null,this._bodyElement=null,this._aiprompt=null,this.data=null,this.id=null,this._isLoading=!1}}kendo.ui.AIPromptOutputObject=t,kendo.ui.AIPromptOutputManager=class{constructor(e){this.aiprompt=e}createOutputObject(e){return new t(e,this)}getLastOutputObject(){if(this.aiprompt.promptOutputs.length>0){const e=this.aiprompt.promptOutputs[0];return this.aiprompt.outputObjects.get(e.id)}return null}updatePromptOutputContent(e,t){let n;return n=t?this.aiprompt.outputObjects.get(t):this.getLastOutputObject(),n?(n.updateContent(e),n):null}stopLoading(e){let t=this.aiprompt.outputObjects.get(e);t?t.isLoading=!1:(t=this.getLastOutputObject(),t&&(t.isLoading=!1))}stopAllLoading(){this.aiprompt.outputObjects.forEach((e=>{e.isLoading=!1}))}getOutputFromElement(t){let n=e(t).closest(".k-card").data("id");let i=this.aiprompt.promptOutputs.find((e=>e.id==n));return!i&&this.aiprompt.outputObjects&&(i=this.aiprompt.outputObjects.get(n)),i}extractOutputData(e){return e?e.data?{prompt:e.data.prompt,output:e.data.output}:{prompt:e.prompt,output:e.output}:{prompt:null,output:null}}destroy(){this.aiprompt&&this.aiprompt.outputObjects&&(this.aiprompt.outputObjects.forEach((e=>{e&&(e._element=null,e._bodyElement=null,e._aiprompt=null,e.data=null)})),this.aiprompt.outputObjects.clear()),this.aiprompt=null}}}(window.kendo.jQuery),function(e){let t=kendo.ui.Widget;const n="user";const i={PROMPT_VIEW:"k-prompt-view",PROMPT_EXPANDER:"k-prompt-expander",SUGGESTION_GROUP:"k-suggestion-group",SUGGESTION:"k-suggestion",CARD:"k-card",CARD_LIST:"k-card-list"};const r="ref-prompt-suggestions-button",o="ref-prompt-input",a="ref-generate-output-button";let s=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,i.service=i.options.service},options:{name:"AIPromptBaseView",buttonText:"",buttonIcon:""},render:function(){this._renderContent(),this._renderFooter()},_renderContentElement:function(){let t=this;let n=e("<div></div>").addClass("k-prompt-content");return t.contentElement=n,t.element.append(n),t.contentElement},_renderFooterElement:function(){let t=this;let n=e("<div></div>").addClass("k-prompt-footer");return t.footerElement=n,t.element.append(n),t.footerElement},_ajaxRequest:function(t,n,i){let r=this;let o=r.service;let a=r._getAjaxData(t,n,i);const s={url:"string"==typeof o?o:o.url,type:"POST",contentType:"application/json",data:JSON.stringify(a),success:e=>r._ajaxSuccessHandler(e,n,t)};return o?.headers&&(s.headers=o.headers),kendo.ui.progress(r.contentElement,!0),e.ajax(s)},_ajaxSuccessHandler:function(e,t,n){const i=this;const r=i.service?.outputGetter||i._getResponseMessageText;const o={id:kendo.guid(),output:r(e),prompt:n,isRetry:t,activeView:1};if(i.aiprompt.trigger("promptResponse",{output:o.output,prompt:o.prompt,outputId:o.id,isRetry:o.isRetry,response:o.response}),i.aiprompt.addPromptOutput(o),i.aiprompt.activeView(o.activeView),!t){const e=i.footerElement?.find(`button[${a}]`);e?.removeClass("k-disabled")}kendo.ui.progress(i.contentElement,!1)},_getResponseMessageText:function(e){return e?.Message?.Text||"An error occurred while processing the request."},_getAjaxData:function(t,i,r){const o=this.service;let a=[{role:{value:n},text:t}];if(r?.length&&(a=r.concat(a)),"string"==typeof o)return a;if(kendo.isPresent(o.data)&&Object.keys(o.data).length)return o.data.messages=a,o.data;if(kendo.isFunction(o?.data))return o.data(t,i,r);if(e.isPlainObject(o)&&kendo.isPresent(o.url))return a;throw new Error("Invalid AIPrompt service configuration.")},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()),e.aiprompt.speechToTextButton=null}});kendo.ui.AIPromptPromptView=s.extend({init:function(e,t){let n=this;s.fn.init.call(n,e,t),n.promptSuggestions=n.options.promptSuggestions,n.promptSuggestionItemTemplate=n.options.promptSuggestionItemTemplate?kendo.template(n.options.promptSuggestionItemTemplate):kendo.ui.AIPromptTemplateBuilder.createSuggestionItem,n.speechManager=new kendo.ui.AIPromptSpeechManager(n,n.options.speechToText)},options:{name:"AIPromptPromptView",buttonIcon:"sparkles"},_renderContent:function(){let e=this;let t=e.promptSuggestions;let n=e.promptSuggestionItemTemplate;let i;i=e.options.viewTemplate?kendo.template(e.options.viewTemplate)({suggestions:t,promptSuggestionItemTemplate:n,messages:e.options.messages}):kendo.ui.AIPromptTemplateBuilder.createPromptView({suggestions:t,promptSuggestionItemTemplate:n,messages:e.options.messages}),e._renderContentElement(),e.contentElement.append(i)},_renderFooter:function(){let e=this;let t;t=e.options.footerTemplate?kendo.template(e.options.footerTemplate)({messages:e.options.messages}):kendo.ui.AIPromptTemplateBuilder.createPromptFooter({messages:e.options.messages}),e._renderFooterElement(),e.footerElement.append(t)},setTextAreaValue:function(e){let t=this;const n=t.contentElement.find(`textarea[${o}]`).getKendoTextArea();n?n.value(e):t.contentElement.find(`textarea[${o}]`).val(e)},_focusSuggestion(e){e&&e.length&&(this.contentElement.find(`.${i.SUGGESTION_GROUP} .${i.SUGGESTION}[tabindex=0]`).attr("tabindex","-1"),e.attr("tabindex","0").trigger("focus"))},startSpeechRecognition:function(){this.speechManager.startRecognition()},stopSpeechRecognition:function(){this.speechManager.stopRecognition()},abortSpeechRecognition:function(){this.speechManager.abortRecognition()},isSpeechListening:function(){return this.speechManager.isListening()},initializeComponents:function(){let t=this;let n=t.promptSuggestions;const s=t.footerElement.find(`button[${a}]`);let l=e.extend({resize:"vertical",placeholder:t.options.messages.promptPlaceholder},t.options.promptTextArea||{});t.speechManager.isEnabled()&&(l=e.extend(!0,l,t.speechManager.getTextAreaSuffixOptions()));const c=t.contentElement.find(`textarea[${o}]`).kendoTextArea(l).getKendoTextArea();if(t.speechManager.isEnabled()&&t.speechManager.initialize(c),s.kendoButton({icon:"sparkles",themeColor:"primary",rounded:"full",click:function(e){const n=t.contentElement.find(`textarea[${o}]`).getKendoTextArea();const i={prompt:n?n.value():t.contentElement.find(`textarea[${o}]`).val(),isRetry:!1,history:[]};t.service&&(i.service=t.service),t.aiprompt.trigger("promptRequest",i)||t.service&&t.aiprompt.transport.read({prompt:i.prompt,history:i.history,isRetry:!1,service:t.service})}}),n?.length){t.contentElement.find(`.${i.SUGGESTION_GROUP} .${i.SUGGESTION}`).first().attr("tabindex","0");let n=kendo.guid();let o=t.contentElement.find(`.${i.PROMPT_EXPANDER} button[${r}]`);t.contentElement.find(`.${i.PROMPT_EXPANDER} button[${r}]`).attr("aria-controls",n),o.next(`.${i.PROMPT_EXPANDER_CONTENT}`).attr("id",n),t.contentElement.find(`.${i.PROMPT_EXPANDER} button[${r}]`).kendoButton({icon:"chevron-up",fillMode:"flat",click:function(t){let n=e(t.target).closest(".k-prompt-expander").find(".k-prompt-expander-content");let 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-suggestion-group .k-suggestion",(function(n){t.setTextAreaValue(e(n.target).text())})),t.contentElement.on("keydown",".k-suggestion-group .k-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=e(n.target);let r=i.siblings();let o,a;40===n.keyCode&&(o=i.next(),t._focusSuggestion(o)),38===n.keyCode&&(a=i.prev(),t._focusSuggestion(a)),36===n.keyCode&&(a=r.first(),t._focusSuggestion(a)),35===n.keyCode&&(o=r.last(),t._focusSuggestion(o)),13!==n.keyCode&&32!==n.keyCode||t.setTextAreaValue(e(n.target).text())}}))}kendo.isFunction(t.options.initializeComponents)&&t.options.initializeComponents({view:t})},render:function(){let e=this;e._renderContent(),e._renderFooter(),e.initializeComponents()},destroy:function(){let e=this;e.speechManager&&(e.speechManager.destroy(),e.speechManager=null),s.fn.destroy.call(e)}}),kendo.ui.AIPromptOutputView=s.extend({init:function(e,t){let n=this;s.fn.init.call(n,e,t),n.promptOutputs=n.aiprompt&&n.aiprompt.promptOutputs?n.aiprompt.promptOutputs:[],n.showOutputRating=n.options.showOutputRating,n.isStreaming=n.options.isStreaming||!1,n.outputActions=n.options.outputActions,n.outputTemplate=n.options.outputTemplate,n.outputActionManager=n.options.outputActionManager},options:{name:"AIPromptOutputView",buttonIcon:"comment",isStreaming:!1,promptOutputs:[]},startStreaming:function(){this.isStreaming=!0,this._showStopButton()},stopStreaming:function(){this.isStreaming=!1,this._hideStopButton()},_showStopButton:function(){let e=this;(e.stopGenerationButton||e._initStopGenerationButton())&&e.stopGenerationButton.show()},_hideStopButton:function(){let e=this;e.stopGenerationButton&&e.stopGenerationButton.hide()},renderPromptOutput:function(t){let n=this;let i=n.options.showOutputRating;let r=n.options.encodedPromptOutputs;let o=n.options.messages;let a=n.isStreaming||!1;let s=n.outputActions;if(!(n.cardListContainer&&0!==n.cardListContainer.length||(n.outputsContainer&&(n.cardListContainer=n.outputsContainer.find(".k-card-list")),n.cardListContainer&&0!==n.cardListContainer.length)))return;a&&!n.stopGenerationButton&&n._initStopGenerationButton();const l=n.aiprompt.outputObjects.get(t.id);if(l){const c=kendo.ui.AIPromptTemplateBuilder.createOutputCard({output:t,showOutputRating:i,messages:o,showOutputSubtitleTooltip:!0,encodedPromptOutputs:r,isStreaming:a,outputActions:s,outputTemplate:n.outputTemplate});const d=e(c);l._element=d,l._bodyElement=d.find(".k-card-body"),n.cardListContainer.prepend(d),t.isLoading?l.showSkeleton():t.output&&l.applyFinalTemplate(),n.initializeComponents(d)}else{let l=e(kendo.ui.AIPromptTemplateBuilder.createOutputCard({output:t,showOutputRating:i,messages:o,showOutputSubtitleTooltip:!0,encodedPromptOutputs:r,isStreaming:a,outputActions:s,outputTemplate:n.outputTemplate}));n.cardListContainer.prepend(l),n.initializeComponents(l)}},updatePromptOutputContent:function(e,t){const n=this.aiprompt.outputObjects.get(e);n&&n.updateContent(t)},_initStopGenerationButton:function(){let t=this;let n=t.contentElement;if(!n||0===n.length)return!1;if(t.stopGenerationButton)return!0;let i=e("<button class='k-prompt-stop-fab k-generating'></button>");return i.attr({"aria-label":t.options.messages.stopGeneration,title:t.options.messages.stopGeneration}),n.prepend(i),t.stopGenerationButton=i.kendoFloatingActionButton({_classNames:["k-prompt-stop-fab","k-generating"],icon:"stop-sm",positionMode:"absolute",align:"bottom end",rounded:"full",click:function(e){t.stopStreaming(),t.aiprompt.trigger("promptRequestCancel",{})}}).getKendoFloatingActionButton(),t.stopGenerationButton.hide(),!0},_renderContent:function(){let t=this;let n=t.promptOutputs;let i=t.options.showOutputRating;let r=t.options.showOutputSubtitleTooltip;let o=t.options.messages;let a=t.options.encodedPromptOutputs;let s=t.outputActions;let l;l=t.viewTemplate?kendo.template(t.viewTemplate)({promptOutputs:n,showOutputRating:i,messages:o,showOutputSubtitleTooltip:r,encodedPromptOutputs:a,outputActions:s,outputTemplate:t.outputTemplate}):kendo.ui.AIPromptTemplateBuilder.createOutputView({promptOutputs:n,showOutputRating:i,messages:o,showOutputSubtitleTooltip:r,encodedPromptOutputs:a,outputActions:s,outputTemplate:t.outputTemplate}),t.outputsContainer=e(l),t.cardListContainer=t.outputsContainer.find(".k-card-list"),t._renderContentElement(),t.contentElement.append(t.outputsContainer),t._initStopGenerationButton()},initializeComponents:function(e){let t=this;e=e||t.contentElement,t.outputActionManager.initializeButtons(e,t.outputActions),e.find('[data-loading="true"]').hide(),e.find('[data-loading="false"]').show(),t.aiprompt&&t.aiprompt.outputObjects&&t.aiprompt.outputObjects.forEach(((n,i)=>{const r=e.find(`.k-card[data-id="${i}"]`);if(r.length>0){if(n._element=r,n._bodyElement=r.find(".k-card-body"),t.outputTemplate&&"function"==typeof t.outputTemplate&&n.data&&n.data.output&&!n.data.isLoading){const e=t.outputTemplate({output:n.data,content:n.data.output});n._bodyElement.html(e)}const e=r.find(".k-button");!(e.length>0&&e.first().data("kendoButton"))&&e.length>0&&t.outputActionManager.initializeButtons(r,t.outputActions)}}))},_initializeCardButtons:function(e){this.outputActionManager.initializeButtons(e,this.outputActions)},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"))}))},destroy:function(){s.fn.destroy.call(this)}}),kendo.ui.AIPromptCommandsView=s.extend({options:{name:"AIPromptCommandsView",buttonText:"",buttonIcon:"more-horizontal",promptCommands:[]},initializeComponents:function(){let t=this;let n=t.options.promptCommands;let i=e("<div></div>").kendoPanelBar({animation:!1,dataSource:n,selectable:!1,select:function(n){let i=e(n.item);let 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=s.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;let 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="promptResponse",a=["copy","retry"],s="focus";let l="k-prompt";let c={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"}};let d=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.options.outputActions=i.outputActions&&i.outputActions.length>0?i.outputActions:a,r.promptOutputs=r.options.promptOutputs||[],r.outputObjects=new Map,r.outputManager=new t.ui.AIPromptOutputManager(r),r.outputActions=t.ui.AIPromptOutputActionManager.processOutputActions(r.options.outputActions),r.outputActionManager=new t.ui.AIPromptOutputActionManager(r,{outputActions:r.outputActions}),Array.isArray(r.promptOutputs)&&r.promptOutputs.length>0&&r.promptOutputs.forEach((e=>{e.id||(e.id=t.guid());const n=r.outputManager.createOutputObject(e);r.outputObjects.set(e.id,n)})),r._initLayout(),r._initViews(),r._initToolbar(),r.activeView(r.options.activeView),r.options.service&&(r.transport=new t.data.AiTransport({service:r.options.service,success:r._serviceSuccess.bind(r),requestStart:()=>t.ui.progress(r.element,!0)})),t.notify(r)},options:{name:"AIPrompt",enabled:!0,toolbarItems:[],promptOutputs:[],encodedPromptOutputs:!0,activeView:0,views:[],popup:null,speechToText:!1,promptTextArea: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:"",stopGeneration:"Stop Generation"},showOutputRating:!0,service:null,suffixTemplate:null,outputTemplate:null,outputActions:["copy","retry","spacer","rating"]},events:["commandExecute","promptRequest",o,"promptRequestCancel","outputRating","outputCopy","outputAction"],_serviceSuccess:function(e){const n=this;const i=n.viewsArray.findIndex((e=>"output"===e.name));e.activeView=i,n.trigger(o,{output:e.output,prompt:e.prompt,outputId:e.id,isRetry:e.isRetry||!1,response:e.response})||(n.addPromptOutput(e),n.activeView(e.activeView),t.ui.progress(n.element,!1))},_initializeView:function(e){let n=this.views[e];let i;if(n){let e=n.type;if("string"==typeof e&&(e=t.getter(n.type)(window)),!e)throw new Error("There is no such view");i=new e(this.element,r(!0,{promptSuggestions:this.options.promptSuggestions,promptCommands:this.options.promptCommands,promptOutputs:this.promptOutputs,showOutputRating:this.showOutputRating,messages:this.options.messages,showOutputSubtitleTooltip:this.options.showOutputSubtitleTooltip,encodedPromptOutputs:this.options.encodedPromptOutputs,promptSuggestionItemTemplate:this.options.promptSuggestionItemTemplate,service:this.options.service,speechToText:this.options.speechToText,promptTextArea:this.options.promptTextArea,outputActions:this.outputActions,outputActionManager:this.outputActionManager,outputTemplate:this.options.outputTemplate},n))}return i},_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];let r="object"==typeof i;let o=i;r&&(i={...i},o="string"!=typeof i.type?i.name:i.type);let a=c[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(s)}},addPromptOutput:function(e){"string"==typeof e&&(e={output:e}),e.id=e.id||t.guid();const n=this.outputManager.createOutputObject(e);this.promptOutputs.unshift(e),this.outputObjects.set(e.id,n),this._selectedView&&"function"==typeof this._selectedView.renderPromptOutput&&(this._selectedView.renderPromptOutput(e),e.isLoading&&this.startStreaming())},removePromptOutput:function(e){const t=this;let n=e;const i=e=>{t.promptOutputs.find((t=>t.id===e))&&(t.promptOutputs=t.promptOutputs.filter((t=>t.id!==e))),t.outputObjects.delete(e)};n instanceof jQuery?(n=e.data("id"),e.remove(),i(n)):(t.element.find("[data-id='"+n+"']").remove(),i(n))},clearOutput:function(){const t=this;const n=t.element.find("[data-id]");n.each((function(){const n=e(this).data("id");t.outputObjects.delete(n)})),n.remove(),t.promptOutputs=[]},_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(l),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:t.themeColor||"primary",rounded:"full",togglable:!0,attributes:{title:t.title},toggle:function(){e.activeView(t.name)}})))},_initToolbar:function(){let t=this;let 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(s)},updatePromptOutputContent:function(e,t){return this.outputManager.updatePromptOutputContent(e,t)},startStreaming:function(){let e=this;e._selectedView&&"function"==typeof e._selectedView.startStreaming&&e._selectedView.startStreaming()},stopStreaming:function(){let e=this;e._selectedView&&"function"==typeof e._selectedView.stopStreaming&&e._selectedView.stopStreaming(),e.outputManager&&e.outputManager.stopAllLoading()},setOptions:function(n){let i=this;let o=i.element;let a=i.options;let s=r({},a,n);t.destroy(o),e(o).empty(),i.init(o,s)},destroy:function(){let e=this;e.toolbar&&(e.toolbar.destroy(),e.toolbar=null),e._selectedView&&(e._selectedView.destroy(),e._selectedView=null),e.outputManager&&(e.outputManager.destroy(),e.outputManager=null),e.outputActionManager&&(e.outputActionManager.destroy(),e.outputActionManager=null),e.promptOutputs=null,e.outputObjects&&(e.outputObjects.clear(),e.outputObjects=null),e.transport&&(e.transport=null),e.element.off(".kendoAIPrompt"),n.fn.destroy.call(e)}});i.plugin(d)}(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",h="Is not equal to",u=["isnull","isnotnull","isempty","isnotempty","isnullorempty","isnotnullorempty"];function p(t){var n="string"==typeof t?t:t.operator;return e.inArray(n,u)>-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=this.wrapper=e("<div />").addClass("k-filtercell-wrapper").appendTo(i);var h,u,f,m,g=this,v=r,_=g.operators=r.operators||{},b=g.input=e("<input/>").attr(n.attr("bind"),"value: value").appendTo(d);var w=r?r.suggestDataSource:null;w&&(r=e.extend({},r,{suggestDataSource:{}})),o.fn.init.call(g,i[0],r),w&&(g.options.suggestDataSource=w),r=g.options,h=g.dataSource=r.dataSource,g.model=h.reader.model,m=r.type=c;var y=(n.getter("reader.model.fields",!0)(h)||{})[r.field];if(y&&y.type&&(m=r.type=y.type),r.values&&(r.type=m=l),_=_[m]||r.operators[m],!v.operator)for(f in _){r.operator=f;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)),m==c&&g.initSuggestDataSource(r),null!==r.inputWidth&&(b.addClass("k-sized-input"),b.width(r.inputWidth)),b.attr("aria-label",g._setInputAriaLabel()),b.attr("title",g._getColumnTitle()),b.attr(n.attr("size"),g.options.size||"medium"),g._setInputType(r,m),m!=s&&!1!==r.showOperators?g._createOperatorDropDown(_):(e('<div unselectable="on" />').css("display","none").text("eq").appendTo(d),d.addClass("k-operator-hidden")),g._createClearIcon(),n.bind(this.wrapper,u),m==c&&(r.template||g.setAutoCompleteSource()),m==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'/>");var d=r.wrapper;var h=n.guid();var u=e("<label/>").text(n.htmlEncode(t.messages.isTrue)).append(a);a.attr(n.attr("bind"),"checked:value").attr("name",h).val("true");var p=u.clone().text(n.htmlEncode(t.messages.isFalse));a.clone().val("false").appendTo(p),d.append([u,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:""},_setInputAriaLabel(){return`${this._getColumnTitle()} Filter`},_setOperatorsAriaLabel(){return`Filter cell operator for ${this._getColumnTitle()}`},_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._setOperatorsAriaLabel()),s.appendTo(this.filterCellOperatorWrapper),this.filterCellOperatorWrapper.append(" "),this.filterCellOperatorWrapper.appendTo(this.wrapper),this.operatorDropDown=s.kendoDropDownList({dataSource:r,size:this.options.size||"medium",dataTextField:"text",dataValueField:"value",adaptiveMode:this.options.adaptiveMode,open:function(){("auto"==this.options.adaptiveMode&&this.largeMQL.mediaQueryList.matches||"none"==this.options.adaptiveMode)&&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._setOperatorsAriaLabel()).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){var n=e(t),r=[],o=0,a={};for(;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});var 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:[]};var 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;var i=n.getValidCssClass("k-button-","size",this.options.size||"medium");var 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",adaptiveMode:"none",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:h,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:h,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:h,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:h,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;var n=t.promise();var 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;var 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",h=".k-dialog-wrapper",u=".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",w=":visible",y="zIndex",k="body",x="initOpen",C="touchstart",S="touchmove",T="open",M="close",A="show",D="hide",E={small:"k-window-sm",medium:"k-window-md",large:"k-window-lg"},I="hidden",z="overflow",P="original-overflow-rule",L="tap-y",B=Math.ceil;function H(e){return void 0!==e}function R(e,t,n){return Math.max(Math.min(parseInt(e,10),n===1/0?n:parseInt(n,10)),parseInt(t,10))}function F(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),H(r.visible)&&null!==r.visible||(r.visible=i.is(w)),s.wrapperTemplate===t&&(s.wrapperTemplate=n.wrapper),s._createDialog(),a=s.wrapper=i.closest(".k-dialog"),s.dialogWrapper=a.closest(h),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;var 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(){var e=this.wrapper,t=this.options,n=t.width,i=t.height,r=t.size,o=["minWidth","minHeight","maxWidth","maxHeight"];for(var 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(R(n,t.minWidth,t.maxWidth))),i&&(i.toString().indexOf("%")>0?e.height(i):e.outerHeight(R(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:B(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:B(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){(F(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;var i=t.options;var 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";var r=e(n.actionbar({buttonLayout:i}));this._addButtons(r),t.append(r)},_addButtons:function(t){var i,r,o=this,a=o._actionClick.bind(o),s=o._actionKeyHandler.bind(o),l=o.options.actions,c=l.length;for(var h=0;h<c;h++)i=l[h],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;var n=t.find(p);var 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(w)&&this._runActionBtn(e.currentTarget)},_actionKeyHandler:function(e){F(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;var 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(){H(this._initOpenTriggered)||(this._initOpenTriggered=!0,this.trigger(x))},toFront:function(){var t=this,n=t.dialogWrapper,i=+n.css(y),r=i;return t.center(),e(u+","+h).each((function(t,n){var r=e(n).css(y);isNaN(r)||(i=Math.max(+r,i))})),(!n[0].style.zIndex||r<i)&&n.css(y,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(w)&&!t.trigger(M,{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();var t=this.options;t.modal&&!e.length&&t.modal.preventScroll?this._enableDocumentScrolling():e.length&&t.modal.preventScroll&&this._stopDocumentScrolling()},_stopDocumentScrolling:function(){var t=this;var n=e("body");t._storeOverflowRule(n),n.css(z,I);var r=e("html");var 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(L,t.changedTouches[0].pageY)},_touchMove:function(t){var n=t.target;var i=e(t.target);var r=t.changedTouches[0].pageY-e(this).data(L)>0;var 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;var n=e(document.body);var r=e("html");var o=r[0];t._restoreOverflowRule(n),t._restoreOverflowRule(r),i.support.mobileOS.ios&&(r.removeData(L),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(D),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;var n=e(u+","+h).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(w)}));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);var 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;var 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 H(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,M,A,D],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}});var 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(D,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"}}});var $=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,t){var n=window.kendo,i=n.ui,r=".kendoForm",o=i.Widget,a=e.extend,s=n.htmlEncode,l="validate",c="validateField",d="change",h="click"+r,u="submit",p="clear",f="equalSet",m="group",g="aria-describedby",v="data-stop",_="data-role",b=".",w="[data-role='otpinput']";var y={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"};var k="horizontal",x="vertical";function C(e,t){let n=e.attr("class").split(" ").filter((function(e){return 0!==e.indexOf(t)}));return e.attr("class",n.join(" ").trim())}function S(e,t,n){(t||n)&&("number"==typeof n&&(n+="px"),"number"==typeof t&&(t+="px"),e.css("grid-gap",n+" "+t))}function T(e,t){if(!e||0===e.length)return null;for(let n=0;n<e.length;n++){let i=e[n];let r=i.minWidth||0;let o=i.maxWidth||1/0;if(t>=r&&t<=o)return i.value}return null}var M=o.extend({init:function(i,r){var a=this;if(o.fn.init.call(a,i,r),a.options=n.deepExtend({},a.options,r),r&&r.formData&&(a.options.formData=r.formData),a._wrapper(),a._grids=[],a._responsiveGrids=[],a._colSpans=[],!e.isEmptyObject(a.options.grid)){let e=n.guid();a.element.children().eq(0).attr(n.attr("id"),e),a.options.grid.gutter===t&&(a.options.grid.gutter={cols:32,rows:0}),a._saveGrid(e,a.options.grid)}a._setFields(),a._setModel(),a._renderContainers(),a.options.renderButtons&&a._renderButtons(),a._editable(),a._renderBoolLabels(),a._renderFieldsHints(),a._setEvents(),a._applyCssClasses(),a._applyGrids(),a._resizeHandler=n.onResize(n.throttle((function(){a.resize(!0)}),300)),a.resize(!0)},events:[c,l,d,u,p],options:{name:"Form",orientation:x,validatable:{validateOnBlur:!0,validationSummary:!1,errorTemplate:null},buttonsTemplate:null,messages:{submit:"Submit",clear:"Clear",optional:"(Optional)"},layout:"",grid:{},clearButton:!0,formData:{},items:[],formatLabel:null,focusFirst:!1,renderButtons:!0,size:"medium"},_applyGrids:function(){const t=this;if(t._grids&&t._grids.length)for(let i=0;i<t._grids.length;i++){let r=t._grids[i],o=r.id,a=r.grid,s=e(`[${n.attr("id")}="${o}"]`),l=a.gutter,c=a.cols;!l||"number"!=typeof l&&"string"!=typeof a.gutter||s.css("grid-gap",a.gutter),S(s,(l||{}).cols,(l||{}).rows),c&&"number"==typeof c&&s.addClass(`k-grid-cols-${c}`)}},_resizeResponsiveGrids:function(t){const i=t.width;const r=this._responsiveGrids;if(r&&r.length)for(let t=0;t<r.length;t++){let o=r[t];let a=o.grid.cols;let s=o.grid.gutter;let l="number"==typeof a?a:T(a,i);let c=e(`[${n.attr("id")}="${o.id}"]`);Array.isArray(a)&&C(c,"k-grid-cols-"),l&&(c.addClass(`k-grid-cols-${l}`),l=null);let d="number"==typeof s.cols?s.cols:T(s.cols,i);let h="number"==typeof s.rows?s.rows:T(s.rows,i);c.css("grid-gap",""),(d||h)&&S(c,d||0,h||0)}},_resizeResponsiveColSpans:function(t){const i=t.width;const r=this._colSpans;if(r&&r.length)for(let t=0;t<r.length;t++){let o=r[t];let a=e(`[${n.attr("id")}="${o.id}"]`);let s=T(o.colSpans,i);C(a,"k-col-span-"),s&&a.addClass(`k-col-span-${s}`)}},_saveGrid:function(t,n){if(!n||e.isEmptyObject(n))return;const i=this;i._grids.push({id:t,grid:n});let r=n.cols||{},o=n.gutter||{};let a={};Array.isArray(r)&&(a.cols=r),a.gutter={},a.gutter="string"==typeof o||"number"==typeof o?{cols:o,rows:o}:{cols:o.cols,rows:o.rows},e.isEmptyObject(a)||i._responsiveGrids.push({id:t,grid:a})},_saveColSpans:function(e,t){t&&Array.isArray(t)&&this._colSpans.push({id:e,colSpans:t})},_resize:function(e){this._resizeResponsiveGrids(e),this._resizeResponsiveColSpans(e)},_noLabelfieldTemplate:({styles:e,colSpan:t,hidden:n,field:i})=>`<div class='${s(e.field)}${t?` k-col-span-${s(t)}`:""}${n?` ${s(e.hidden)}`:""}'><span class='${s(e.label)} ${s(e.emptyLabel)}'></span><div class='k-form-field-wrap' data-container-for='${s(i)}'></div></div>`,_fieldTemplate:({styles:e,colSpan:t,hidden:i,field:r,label:o,id:a,optional:l,fieldId:c})=>`<div ${c?n.attr("id")+"="+c:""} class='${s(e.field)}${t?` k-col-span-${s(t)}`:""}${i?` ${s(e.hidden)}`:""}'>`+(o&&!i?`<label class='${s(e.label)}' for='${s(a)}' id='${s(a)}-form-label'>`+(void 0!==o.encoded&&!1===o.encoded?o.text||o:s(o.text||o))+(o.optional?`<span class='${s(e.optional)}'>${s(l)}</span>`:"")+"</label>":"")+`<div class='k-form-field-wrap' data-container-for='${s(r)}'></div></div>`,_boolLabelTemplate:({styles:e,colSpan:t,hidden:n,field:i,label:r,id:o,optional:a})=>`<label class='k-checkbox-label' for='${s(o)}' id='${s(o)}-form-label'>`+(void 0!==r.encoded&&!1===r.encoded?r.text||r:s(r.text||r))+(r.optional?`<span class='${s(e.optional)}'>${s(a)}</span>`:"")+"</label>",_groupTemplate:({styles:e,colSpan:t,label:n,id:i})=>`<fieldset class='${s(e.fieldset)}${t?` k-col-span-${s(t)}`:""}'><legend class='${s(e.legend)}'>${s(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=M.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){var t=[].concat(e),n=t.shift(),i=[],r=[].push;for(;n;)n.items?r.apply(t,n.items):r.call(i,n),n=t.shift();return i},_defaultLabel:function(e){var t=this.options.formatLabel;if(e.length)return n.isFunction(t)?t(e):e.split(/(.*[a-z])(?=[A-Z])/).join(" ").trim()+":"},_formatLabel:function(n,i){return(e.isPlainObject(i)?i.text:i)!==t?i:this._defaultLabel(n)},_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,t,r,o,s,l=this,c=l._flattenFields(l._defaultFields()),d=l.options.formData||{};for(var h in l._fields=[],c)t=d[(e=c[h]).field],r="string"==typeof e.editor?e.editor:n.type(t&&n.parseDate(t.toString())||t),"Upload"==e.editor&&(r="file"),o=n.isFunction(e.editor)?e.editor:i.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=a(!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:o,attributes:s,isHidden:l._isHidden(e.editor)||l._isAntiForgeryToken(e.name||e.field)}),l._fields[h]=e},_setModel:function(){var e=this,t=e.options,i=t.formData||{};if(t.formData instanceof n.data.ObservableObject)e._model=i;else{var r=n.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(_,"editable")},_removeEditableMvvmAttributes:function(){this.wrapper.attr(v,!0).attr(_,"form")},_getItemTemplate:function(e){return e===m?this._groupTemplate:this._fieldTemplate},_isHidden:function(e){return"string"==typeof e&&"hidden"===e},_isAntiForgeryToken:function(e){return e===i.Editable.antiForgeryTokenName},_renderField:function(e){var t,i=this,r=M.styles,o=i.options.orientation===k,a=i._model.fields&&i._model.fields[e.field]&&i._model.fields[e.field].type,s=a&&"boolean"===a;t=s&&o&&!e.editor?i._noLabelfieldTemplate:i._fieldTemplate;let l=n.guid();return i._saveColSpans(l,e.colSpan),n.template(t)({styles:r,id:e.id||e.field||"",fieldId:l,field:e.field||"",label:s&&!e.editor?null:i._formatLabel(e.field,e.label),colSpan:"number"==typeof e.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+y.field);n.length&&n.toggleClass(y.fieldError,t)},_renderBoolLabels:function(){var e,t,i=this,r=M.styles,o=i._fields;for(var a=0;a<o.length;a+=1)e=o[a],(t=i.wrapper.find("[name='"+e.name+"']:not([type='hidden'])"))&&e.label&&!e.isHidden&&"boolean"===e.type&&!e.editor&&t.parent().after(n.template(i._boolLabelTemplate)({styles:r,id:e.id||e.field||"",optional:i.options.messages.optional,label:i._formatLabel(e.field,e.label)}))},_renderFieldsHints:function(){var t,i,r,o,a,s=this,l=s._fields;for(var c=0;c<l.length;c+=1)t=l[c],(r=s.wrapper.find(`[name='${t.name}'],[id='${t.name}']`))&&t.hint&&!t.isHidden&&(a=e(n.template(s._hintTemplate)({message:t.hint||"",id:t.id})),s._associateHintContainer(r,a.attr("id")),(i=n.widgetInstance(r))&&(r=(o=i.element.next("label[for='"+i.element.attr("id")+"']")).length?o:i.wrapper),s.validator._errorsByName(t.name).length&&(a.toggleClass(y.hidden),n.removeAttribute(r,g,a.attr("id"))),a.insertAfter(r))},_associateHintContainer:function(e,t){var i=n.getWidgetFocusableElement(e);i&&t&&n.toggleAttribute(i,g,t)},_toggleHint:function(e,t){var n,i=e.closest(b+y.field);i.length&&(n=i.find(b+y.fieldHint)).length&&(n.toggleClass(y.hidden,t),this._associateHintContainer(e,n.attr("id")))},_renderGroup:function(t){var i,r,o,a=this,s=t.type;o=r=e(n.template(a._getItemTemplate(s))({styles:y,label:t.label||"",colSpan:t.colSpan})),o=a._setupLayoutContainer(r,{grid:t.grid,layout:t.layout,id:t.id})||r;for(var l=0;l<t.items.length;l+=1)i=t.items[l],o.append(a._renderField(i));return r},_renderContainers:function(){var e,i,r=this,o=r._defaultFields(),s="grid"===r.options.layout?r.layoutWrapper:r.wrapper;for(var l=0;l<o.length;l+=1){if((e=o[l]).type===m){if(e.grid){let i=n.guid();e.grid&&e.grid.gutter===t&&(e.grid=a(!0,{},{gutter:{cols:16,rows:0}},e.grid)),r._saveGrid(i,e.grid),r._saveColSpans(i,e.colSpan),e.id=i}i=r._renderGroup(e)}else i=r._renderField(e);s.append(i)}},_buttonsTemplate:function(){var t,i,r,o=this.options,a=o.messages,l=M.styles;return null!==o.buttonsTemplate?t=n.template(o.buttonsTemplate)({styles:l,messages:a}):(t=i=e("<button class='"+l.submit+"'>"+s(a.submit)+"</button>").kendoButton({type:"submit",themeColor:"primary",size:o.size}),o.clearButton&&(r=e("<button class='"+l.clear+"'>"+s(a.clear)+"</button>").kendoButton({size:o.size}),t=i.add(r))),t},_renderButtons:function(){var t,n=this,i=n.wrapper,r=n.options,o=M.styles,a=r.orientation===k,s=i.find(b+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,i){var r,o=i.layout,a=i.grid,s=[],l=i.id;return"string"==typeof o&&""!==o&&(r=e("<div></div>").appendTo(t).addClass(y.layout),s.push("k-d-"+o)),"grid"===o&&"object"==typeof a&&("number"==typeof a.cols?s.push("k-grid-cols-"+a.cols):"string"==typeof a.cols&&r.css("grid-template-columns",a.cols),r.attr(n.attr("id"),l)),r&&r.addClass(s.join(" ").trim()),r},_setEvents:function(){var e=this;e.validator.bind("validateInput",e._validateField.bind(e)).bind(l,e._validate.bind(e)),e.wrapper.on(u+r,e._submit.bind(e)).on(p+r,e._clear.bind(e)).on(h+r,b+y.clear,e._clear.bind(e)),e._changeHandler||(e._changeHandler=e._change.bind(e)),e._model.bind(d,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(c,n)&&e.preventDefault()},_validate:function(e){var t={model:this._model.toJSON(),valid:e.valid,errors:e.errors};this.trigger(l,t)},_change:function(e){var t=e.field,n={field:t,value:this._model[t]};this.trigger(d,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(p)},validate:function(){var e=this.validator;if(e)return e.validate()},clear:function(){var e=this,t=e._fields,i=e._model,r=e.editable,o=e.validator.options.validateOnBlur;e.validator.reset(),o&&i.unbind("set").unbind(f);for(var a=0;a<t.length;a+=1){var s=t[a].field;var l=e.wrapper.find("[name='"+s+"']");var c=n.widgetInstance(l);var d=l.is("input[type=hidden]");(l.is("[data-role='checkboxgroup']")||l.is("[data-role='radiogroup']")||d)&&!l.is(w)||l.val(""),!c&&l.is(w)&&(c=n.widgetInstance(l)),!c&&l.hasClass("k-hidden")&&(c=n.widgetInstance(l.closest(".k-signature"))),c&&(n.ui.Upload&&c instanceof n.ui.Upload?c.clearAllFiles():n.ui.OtpInput&&c instanceof n.ui.OtpInput?(c._emptyValues(),c.value(null)):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+y.fieldError).removeClass(y.fieldError),o&&i.bind("set",r._validateProxy).bind(f,r._validateProxy)},setOptions:function(e){var t=this;t.destroy(),t.wrapper.removeClass(y.horizontal).removeAttr(v).empty(),t.init(t.element,e)},destroy:function(){var e=this;e.wrapper.off(r),e._model&&(e._model.unbind(d,e._changeHandler),e._changeHandler=null),o.fn.destroy.call(e.editable),o.fn.destroy.call(e),e.editable&&(e.editable.destroy(),e.editable=null)}});n.cssProperties.registerPrefix("Form","k-form-"),i.plugin(M),a(!0,M,{styles:y})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui;var o="k-loader",a="k-loader-canvas",s="k-loader-segment";var l={pulsing:{className:"pulsing-2",segments:2},"infinite-spinner":{className:"spinner-3",segments:3},"converging-spinner":{className:"spinner-4",segments:4}};var 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,h=l[d]===t?d:l[d],u=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&&""!==u&&i.push("k-loader-"+u),"string"==typeof d&&""!==d&&i.push("k-loader-"+(e.isPlainObject(h)?h.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;var 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 r_=kendo.jQuery;function o_(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=r_.extend({},r,t);const e=kendo.html.renderLoaderContainer(r_("<div></div>"),r);const o=n.wrapper.width();const a=r_("<div class='k-loading-pdf-mask'></div>");const 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;var o="action";var 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");var 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)");var 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;var i=t.Class.extend({init:function(e){this.options=e,this.grid=e.grid}});var 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()}});var 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)}});var a=i.extend({exec:function(){this.grid.addRow()}});var 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)}});var l=i.extend({exec:function(){var e=this.grid,t=this.options.target.closest("tr");e.removeRow(t)}});var c=i.extend({exec:function(){var e=this.grid,t=this.options.withHeaders;e.copySelectionToClipboard(t)}});var 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)}});var h=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)}});var u=i.extend({exec:function(){this.grid.clearSelection()}});var 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)}});var f=i.extend({exec:function(){this.grid.saveAsPDF()}});var 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:h,ClearSelectionCommand:u,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,h=n.keys,u=n.type,p=e.isPlainObject,f=e.extend,m=e.map,g=e.grep,v=Array.isArray,_=e.inArray,b=Array.prototype.push,w=n.isFunction,y=n.htmlEncode,k=e.isEmptyObject,x=e.contains,C=Math,S=".",T="progress",M="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",D=":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)",L="th.k-header:not(.k-group-cell):not(.k-hierarchy-cell)",B="a[class*='-i-caret-alt-down']",H="a[class*='-i-caret-alt-right']",R=H,F="k-grid-stack",O=".kendoGrid",V="edit",N="beforeEdit",$="save",U="remove",W="detailInit",j="filterMenuInit",q="columnMenuInit",G="filterMenuOpen",K="columnMenuOpen",Y="cellClose",Q="changing",X="change",Z="columnHide",J="columnShow",ee="saveChanges",te="dataBound",ne="detailExpand",ie="detailCollapse",re="itemchange",oe="page",ae="paging",se="paste",le="scroll",ce="sync",de="loadStart",he="loadEnd",ue="requestEnd",pe="k-focus",fe="k-highlighted",me="k-hover",ge="k-active",ve=":kendoFocusable",_e=".k-command-cell,.k-select-checkbox,.k-grid-stack-cell[tabindex]",be="k-selected",we="k-checkbox",ye="input[data-role='checkbox'].k-select-checkbox."+we,ke="k-grid-norecords",xe="k-link",Ce="k-icon",Se="k-svg-icon",Te="k-sort-order",Me="k-sorted",Ae="k-header",De="k-grid-column-menu",Ee="k-grid-filter-menu",Ie="k-grid-content-sticky",ze="k-grid-header-sticky",Pe="k-grid-footer-sticky",Le="k-grid-no-left-border",Be="k-grid-column-template",He="k-grouping-row",Re="resize",Fe="rowResize",Oe="columnResize",Ve="columnReorder",Ne="columnLock",$e="columnUnlock",Ue="columnStick",We="columnUnstick",je="rowReorder",qe="navigate",Ge="click",Ke="mousedown",Ye="mouseup",Qe="mouseenter",Xe="mouseleave",Ze="mousemove",Je="dblclick",et="height",tt="width",nt="auto",it="tabIndex",rt="function",ot="string",at="bottom",st="container-for",lt="field",ct="input",dt="incell",ht="inline",ut="overflow",pt="sort",ft="group-sort",mt="Collapse",gt="Expand",vt="id",_t="px",bt="tr",wt="div",yt="aria-label",kt="aria-owns",xt="aria-rowcount",Ct="aria-colcount",St="aria-colindex",Tt="aria-rowindex",Mt="aria-expanded",At="aria-checked",Dt="aria-activedescendant",Et="role",It="none",zt="row",Pt="rowgroup",Lt="columnheader",Bt="gridcell",Ht=/(\}|\#)/gi,Rt="[\\x20\\t\\r\\n\\f]",Ft=(new RegExp("(\\s*left\\s*:\\s*\\d*px;?)*","ig"),new RegExp("(\\s*right\\s*:\\s*\\d*px;?)*","ig"),new RegExp("(^|"+Rt+")(k-group-cell|k-hierarchy-cell)("+Rt+"|$)")),Ot=new RegExp("(^|"+Rt+")(k-filter-row)("+Rt+"|$)"),Vt=({className:e,attr:t,text:i})=>`<button type="button" class="${e}" ${t}>${n.htmlEncode(i)}</button>`,Nt=(e,t,n)=>`<span class="k-checkbox-wrap"><input tabindex="-1" class="k-select-checkbox ${we} ${e} k-rounded-md" data-role="checkbox" aria-label="${t}" aria-checked="false" type="checkbox"></span>${n?`<label class="k-checkbox-label">${n}</label>`:""}`,$t=({size:e})=>Nt(e,"Select row"),Ut=({size:e,label:t})=>Nt(e,"Select all rows",t),Wt=()=>n.ui.icon("reorder"),jt=({text:e})=>`<span class="k-cell-inner"><span class="k-link"><span class="k-column-title">${e}</span></span></span>`,qt=!1,Gt=n.support.browser;var Kt=Gt.msie&&11===Gt.version;var Yt=/Mac OS/.test(navigator.userAgent);var Qt="k-content",Xt="k-scroll-container",Zt="k-cell-inner";var Jt;var en=["copySelection","copySelectionNoHeaders","paste","separator","create","edit","destroy","select","separator","reorderRow","exportPDF","exportExcel","separator"];var tn=["sortAsc","sortDesc","separator"];var nn=["moveGroupPrevious","moveGroupNext","separator"];const rn=[".k-grid-edit-command",".k-grid-remove-command",".k-grid-save-changes",".k-grid-cancel-changes",".k-grid-cancel-command",".k-grid-save-command"].join(", ");const on=function(e){return{sort:[{command:"clear-sort",text:e.clearButtons?e.clearButtons.clearSorting:"Clear Sorting",size:"large",fillMode:"solid",themeColor:"base",icon:"x"},{command:"done",text:e.applyButtons?e.applyButtons.applySorting:"Done",size:"large",themeColor:"primary",icon:"check"}],group:[{command:"clear-group",text:e.clearButtons?e.clearButtons.clearGrouping:"Clear Grouping",size:"large",fillMode:"solid",themeColor:"base",icon:"x"},{command:"done",text:e.applyButtons?e.applyButtons.applyGrouping:"Done",size:"large",themeColor:"primary",icon:"check"}],filter:[{command:"clear-filter",text:e.clearButtons?e.clearButtons.clearFiltering:"Clear All Filters",size:"large",fillMode:"solid",themeColor:"base",icon:"filter-clear"}],"column-chooser":[{text:e.clearButtons?e.clearButtons.columnChooserReset:"Reset",icon:"arrow-rotate-ccw"},{text:e.applyButtons?e.applyButtons.columnChooserApply:"Apply",themeColor:"primary",icon:"check"}]}};i.Pager&&(Jt=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 an=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(X,t._refreshHandler),t.dataSource=e,t.dataSource.bind(X,t._refreshHandler),t.dataSource.options.useRanges=!0,t.dataSource.options.virtual=!0},options:{name:"VirtualScrollable",itemHeight:e.noop,prefetch:!0,maxScrollHeight:25e4},events:[ae,oe,le,de,he],destroy:function(){var e=this;l.fn.destroy.call(e),e.dataSource.unbind(X,e._refreshHandler),e.wrapper.add(e.verticalScrollbar).off(O),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:nt,overflow:"hidden"}).css(qt?"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"+O+" mousewheel"+O,i._wheelScroll.bind(i)),i._wrapper(),(n.support.kineticScrollNeeded||n.support.touch)&&(i.wrapper.css("touch-action",It),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"+O,i._scroll.bind(i))},_wrapper:function(){Kt&&(this.wrapper.css({"overflow-y":le}),this.element.css(qt?"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),h=c?C.ceil(l/o):C.floor(l/o),u=C.max(d+h,0);t._preventScroll?t._preventScroll=!1:(t._prevScrollTop=t._scrollTop,t._scrollTop=i-s*o,t._scrollbarTop=i,t._scrolling=n,t._fetch(d,u,c)||(t.wrapper[0].scrollTop=t._scrollTop),t.trigger(le),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;var t=this.wrapper;var 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;var 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;var 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=this._rangeStart||this.dataSource.skip()||0;var n=this.dataSource.pageSize();var i;return(i=e>t?e-t:t-e-1)>n?n:i},scrollIntoView:function(e){var t=this.wrapper[0];var n=t.clientHeight;var i=this._isScrolledToBottom()?t.scrollTop:this._scrollTop||t.scrollTop;var r=e[0].offsetTop;var 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;var h=r.verticalScrollbar;var u=Gt.webkit?1:0;var 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=h.scrollTop()-l*a),r._page(l,s)):n>=l+s&&!i?(d=!0,l=C.min(t,p-s),h.scrollTop()>=h[0].scrollHeight-h[0].offsetHeight-u?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=w(i)?i:e.noop,r.trigger(ae,{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(de),a.range(t,n,(function(){r.trigger(he),i(),r.trigger(oe)}),"page")):(o||r.trigger(de),r._timeout=setTimeout((function(){r._scrolling||(o&&r.trigger(de),a.range(t,n,(function(){r.trigger(he),i(),r.trigger(oe)})))}),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];var d=o._isScrolledToBottom();r=o.itemHeight=o.options.itemHeight()||0;var h=c.scrollWidth>c.offsetWidth?l:0;i=(s._isGroupPaged()?s.groupsTotal(!0):s.total())*r+h;var u=e(new Array(C.floor(i/a)+1).join("<div></div>")).css({width:"1px",height:`${a}px`});i%a&&(u=u.add(e("<div></div>").css({width:"1px",height:i%a+"px"}))),o.verticalScrollbar.empty().append(u),!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;var r=(e||{}).action;var o=t._isScrolledToBottom()||!r||r!==re&&r!==U&&r!==ce;t.trigger(he),clearTimeout(t._timeout),t.repaintScrollbar(o),t.drag&&t.drag.cancel(),void 0===i||t._fetching||((!r||r!==ce&&r!==re&&"expandGroup"!==r)&&(t._rangeStart=n.skip()),1!==n.page()||r&&(r===ce||r===re||"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 sn(e){if(!e||!Array.isArray(e.filters))return[];const t=[];return e.filters.forEach((function e(n){n.logic&&n.filters?n.filters.forEach(e):n.field&&n.operator&&t.push({...n})})),t}function ln(e){if(!e||!Array.isArray(e))return[];const t=[];return e.forEach((function e(n){t.push({...n}),n.items&&Array.isArray(n.items)&&n.items.forEach((t=>{t.items&&e(t)}))})),t}function cn(e){return e&&Array.isArray(e)?e:[]}function dn(e,t){return"["+n.attr(e)+"="+t+"]"}function hn(e){return new Array(e+1).join('<td class="k-group-cell k-table-group-td k-table-td"> </td>')}function un(e){var t,n=" ";if(e){if(typeof e===ot)return e;for(t in e)""!==e[t]&&(n+=t+'="'+e[t]+'"')}return n}function pn(e,t){return t?e.map((e=>({...e,filters:e?.filters?.map((e=>{const n=e.field;return t&&t[n]&&"date"===t[n].type.toLowerCase()?{...e,value:new Date(e.value)}:e}))})))||[]:e}var fn={aiassistant:{text:"",icon:"sparkles",rounded:"full",className:"k-grid-ai-assistant-tool",fillMode:"solid",themeColor:"primary"},create:{text:"Add",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"},selectall:{text:"Select all"},destroy:{text:"Delete",className:"k-grid-remove-command",iconClass:"k-i-trash"},edit:{text:"Edit",className:"k-grid-edit-command",iconClass:"k-i-pencil"},update:{text:"Save",className:"k-grid-save-command",iconClass:"k-i-save"},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"}},columnchooser:{text:"Columns",type:"button",icon:"columns",overflow:"never",className:"k-grid-column-chooser",attr:{"aria-haspopup":"menu"}},sort:{text:"Sort",type:"button",icon:"arrows-swap",overflow:"never",className:"k-grid-sort-tool",attr:{"aria-haspopup":"menu"},clearButton:!0},filter:{text:"Filter",type:"button",icon:"filter",overflow:"never",className:"k-grid-filter-tool",attr:{"aria-haspopup":"menu"},clearButton:!0},group:{text:"Group",type:"button",icon:"group",overflow:"never",className:"k-grid-group-tool",attr:{"aria-haspopup":"menu"},clearButton:!0}};const mn=n.guid();function gn(e){return{id:mn,prompt:"",output:e.outputPlaceholder,skipHeader:!0,skipActions:!0}}function vn(t,n){e("th, th .k-grid-filter-menu, th .k-link",t).add(document.body).css("cursor",n)}function _n(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 bn(t,n,i){return e(t).add(n).find(i)}function wn(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(Ge+O,".k-grid-"+(a||"").replace(/\s/g,""),{commandName:a},o.click.bind(e)))}function yn(e,i,r,o,a){return m(e,(function(e){var s;(e=typeof e===ot?{field:e}:e).parentIds=a,e.attributes instanceof Function&&(e._attributesFunction=e.attributes),!zn(e)||r?(e.attributes=ki(e.attributes),e.footerAttributes=ki(e.footerAttributes),e.headerAttributes=ki(e.headerAttributes),s=!0):!zn(e)&&r||(e.attributes=Ci(e.attributes),e.footerAttributes=Ci(e.footerAttributes),e.headerAttributes=Ci(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=yn(e.columns,i,s,e.locked,a?a+" "+l:l)),f({encoded:i,hidden:s,locked:o},e)}))}function kn(e,t){var n=[];return xn(e,t,n),n[n.length-1]}function xn(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]),xn(e,t[i].columns,n))return!0;n.splice(r,n.length-r)}}return!1}function Cn(e,t){Tn(e,t,t)}function Sn(e){e.attr(it,1)}function Tn(e,t,n){var i=n?Ci:ki;e.hidden=!t,e.attributes=i(e.attributes),e.footerAttributes=i(e.footerAttributes),e.headerAttributes=i(e.headerAttributes)}function Mn(e,t){An(e),Tn(e,t,e._hideByMedia?e.matchesMedia:t)}function An(e){e.matchesMedia=Dn(e)}function Dn(e){return e&&(Bn(e.media)||!Bn(e.media)&&n.matchesMedia(e.media))}function En(){return this.style.display!==It&&!this.classList.contains("k-hidden")}function In(t){return e(t)[0].style.display!==It&&!e(t)[0].classList.contains("k-hidden")}function zn(e){return Pn([e]).length>0}function Pn(e){return g(e,(function(e){var t=!e.hidden&&!1!==e.matchesMedia;return t&&e.columns&&(t=Pn(e.columns).length>0),t}))}function Ln(e){var t=[];var n;for(var i=0;i<e.length;i++){if(!Bn((n=e[i]).media)){if(!Bn(n.minScreenWidth))throw new Error("Using 'media' and 'minScreenWidth' options at the same time is not supported.");t.push(n)}n.columns&&(t=t.concat(Ln(n.columns)))}return t}function Bn(e){return void 0===e}function Hn(t){return e(t).map((function(){return this.toArray()}))}function Rn(e,t){for(var n=0;n<e.length;n++)if(e[n].field==t)return e[n]}function Fn(t,n,i,r,o,a,s,l){var c=Vn(t);var d=Vn([n]);if(c>d){var h=new Array(s+1).join('<th class="k-group-cell k-header k-table-th" scope="col"> </th>');var u=a.children(":not(.k-filter-row)");e(new Array(c-d+1).join("<tr class='k-table-row'>"+h+"</tr>")).insertAfter(u.last())}!function(e,t){var n=e.find("tr:not(.k-filter-row) th:not(.k-group-cell,.k-hierarchy-cell)");for(var i=0;i<n.length;i++)n[i].rowSpan+=t}(a,c-d),Nn(i,r,o,a,l)}function On(t,i,r){var o;r=r||0;var a=i;i=pi(i);var s={};var l=t.find(">tr:not(.k-filter-row)");var c=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")};for(var d=0,h=i.length;d<h;d++)s[(o=$n(i[d],a)).row]||(s[o.row]=l.eq(o.row).find(S+Ae).filter(c)),s[o.row].eq(o.cell).attr(n.attr("index"),r+d);return i.length}function Vn(e){var t=0;for(var n=0;n<e.length;n++)if(e[n].columns){var i=Vn(e[n].columns);i>t&&(t=i)}return 1+t}function Nn(t,n,i,r,o){var a=jn(t[0],n);var s=i.find(">tr:not(.k-filter-row)").eq(a.row).children("th.k-header:not(.k-group-cell)");var l=e();var c=a.cell;var d;for(d=0;d<t.length;d++)l=l.add(s.eq(c+d));r.find(">tr:not(.k-filter-row)").eq(a.row)[o](l);var h=[];for(d=0;d<t.length;d++)t[d].columns&&(h=h.concat(t[d].columns));h.length&&Nn(h,n,i,r,o)}function $n(e,t,n,i){var r;var 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=$n(e,t[o].columns,n+1,i)))break;i[n]++}return r}function Un(e,t){let n=e;let i=n.match(/class=["][^"]+/g);if(i){const e=i[0].split('"').pop();n=n.replace(e,e+(t?"":" k-table-td "))}else n=n.replace("<td","<td class='k-table-td'");return n}function Wn(e,t,n,i,r){if(t.columns)return(t=t.columns)[i?0:t.length-1];var o=kn(t,e);var a;a=o?o.columns:e;var s=_(t,a);0===s&&i?s++:s==a.length-1&&!i||!n.locked&&!t.columns&&!i?s--:(s>0||0===s&&!i)&&s++,t=function(e,t,n,i){var r;var o=!!n.locked;var a;do{r=e[t],t+=i?1:-1,a=!!r.locked}while(r&&t>-1&&t<e.length&&r!=n&&!r.columns&&a===o);return r}(a,s,n,_(n,a)>s);var l=_(t,r);return(!t.columns||l&&l!==a.length-1)&&t&&t!=n&&t.columns?Wn(e,t,n,i,r):null}function jn(e,t,n,i){var r;var 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=jn(e,t[o].columns,n+1,i)))break;t[o].hidden||i[n]++}return r}function qn(e){return Kn(ri(e)).concat(Kn(oi(e)))}function Gn(e,t,n,i){var r=e[n];var o=e[i];var a=kn(r,t);return t=a?a.columns:t,_(o,t)}function Kn(e){var t=[];var n=[];for(var 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(Kn(n))),t}function Yn(e){var t=0;var n;for(var i=0;i<e.length;i++)(n=e[i]).columns?t+=Yn(n.columns):n.hidden&&t++;return t}function Qn(e){var t=0;for(var n=0,i=e.length;n<i;n++)e[n].hidden||(t+=parseInt(e[n].width,10));return t}function Xn(e){var t,n=0;for(var i=0,r=e.length;i<r;i++)(t=e[i].style.width)&&-1==t.indexOf("%")&&(n+=parseInt(t,10));return n}function Zn(t){var n=t.find("tr:not(.k-filter-row)");var i=n.filter((function(){return!e(this).children().length})).remove().length;var r=n.find("th:not(.k-group-cell,.k-hierarchy-cell)");for(var o=0;o<r.length;o++)r[o].rowSpan>1&&(r[o].rowSpan-=i);return n.length-i}function Jn(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&&Jn(l,t,n,i+1,r+e.length)}function ei(e,t,n){e.css({left:t,right:n})}function ti(e,t,n){e[t]=e[t]||{},e[t][n]=e[t][n]||""}function ni(e,t,n,i){ti(e,t,n),""!==e[t][n]?e[t][n]+=" "+i:e[t][n]=i}function ii(e,t,n,i,r){ti(e,t,n),r?delete e[t][n]:e[t][n]=e[t][n].replace(i,"")}function ri(e){return g(e,(function(e){return e.locked}))}function oi(e){return g(e,(function(e){return!e.locked}))}function ai(e){return g(e,(function(e){return e.sticky&&!e.locked}))}function si(e){return g(e,(function(e){return!e.locked&&zn(e)}))}function li(e){return g(e,(function(e){return e.locked&&zn(e)}))}function ci(e){var t=[];for(var n=0;n<e.length;n++)e[n].hidden||(e[n].columns?t=t.concat(ci(e[n].columns)):t.push(e[n]));return t}function di(e){var t=[];for(var n=0;n<e.length;n++)e[n].hidden||(e[n].columns?t=t.concat(ci(e[n].columns)):t.push({field:e[n].field,width:e[n].width,values:e[n].values,title:e[n].title}));return t}function hi(e){var t=[];for(var n=0;n<e.length;n++)e[n].columns&&(t=t.concat(e[n].columns));return t}function ui(e){var t=hi(e);return t=t.filter((function(e){return!e.hidden}))}function pi(e){var t=[];for(var n=0;n<e.length;n++)e[n].columns?t=t.concat(pi(e[n].columns)):t.push(e[n]);return t}function fi(e){var t=[];e=pi(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 mi(e){var t=[];for(var n=0;n<e.length;n++)t.push(e[n]),e[n].columns&&(t=t.concat(mi(e[n].columns)));return t}function gi(e,t){const n=t.multiHeaderSeparator||" / ";const i=mi(e.columns);const r=t.parentIds.split(" ").map((e=>{let t=i.find((t=>t.uid===e));return t&&(t.title||t.field)||""}));return r.push(t.title||t.field),r.join(n)}function vi(e,t){return{field:e.field,title:e.title,format:e.format,editor:e.editor,values:e.values,editorOptions:f(!0,{format:e.format,adaptiveMode:t},e.editorOptions),label:e.title||e.field||""}}function _i(i){var r=i.find(">tr:not(.k-filter-row)");var o=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")};var 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);var 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 bi(t){var n=t.closest("table");var i=e().add(t);var r=t.closest(bt);var o=n.find("tr:not(.k-filter-row)");var a=o.index(r);if(a>0){var s=o.eq(a-1).find("th:not(.k-group-cell,.k-hierarchy-cell)").filter((function(){return!e(this).attr("rowspan")}));var l=0;var c=r.find("th:not(.k-group-cell,.k-hierarchy-cell)").index(t);var d=t.prevAll(":not(.k-group-cell,.k-hierarchy-cell)").filter((function(){return this.colSpan>1}));for(var h=0;h<d.length;h++)l+=d[h].colSpan||1;for(c+=Math.max(l-1,0),l=0,h=0;h<s.length;h++){var u=s.eq(h);if(u.attr("data-colspan")?l+=u[0].getAttribute("data-colspan"):l+=1,c>=h&&c<l){i=bi(u).add(i);break}}}return i}function wi(t){var i=t.closest("thead");var r=e().add(t);var o=t.closest(bt);var a=i.find("tr:not(.k-filter-row)");var s=a.index(o)+t[0].rowSpan;var l=n.attr("colspan");if(s<=a.length-1){var c=o.next();var d=t.prevAll(":not(.k-group-cell,.k-hierarchy-cell)");var h;d=d.filter((function(){return!this.rowSpan||1===this.rowSpan}));var u=0;for(h=0;h<d.length;h++)u+=parseInt(d.eq(h).attr(l),10)||1;var p=c.find("th:not(.k-group-cell,.k-hierarchy-cell)");var f=parseInt(t.attr(l),10)||1;for(h=0;h<f;){c=p.eq(h+u),r=r.add(wi(c));var m=parseInt(c.attr(l),10);m>1&&(f-=m-1),h++}}return r}function yi(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(wt)).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 ki(e){e=e||{};let t={};return t[n.attr("style-display")]="none",f({},e,t)}function xi(e){return!!(e=e||{})[n.attr("style-display")]}function Ci(e){return delete(e=e||{})[n.attr("style-display")],e}function Si(t,i,r,o,a){var s,l=t.find(">colgroup"),c=a?["<col>"]:m(i,(function(e){return(s=e.width)&&0!==parseInt(s,10)?n.format(`<col ${n.attr("style-width")}="{0}" ${e.draggable?"class=k-drag-col":""} />`,typeof s===ot?s:s+_t):e.draggable?"<col class='k-drag-col' />":"<col />"}));a||!r&&!l.find(".k-hierarchy-col").length||c.splice(0,0,'<col class="k-hierarchy-col" />'),l.length&&l.remove(),l=e(new Array(o+1).join('<col class="k-group-col">')+c.join("")),n.applyStylesFromKendoAttributes(l,["width"]),l.is("colgroup")||(l=e("<colgroup/>").append(l)),t.prepend(l)}function Ti(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 Mi(e,t,i,r){let o=i&&i.length&&p(i[0])&&"value"in i[0]?Ti(i)[e]:e;o=null!=o?o:"";let a=!1===r?o:n.htmlEncode(o);return t?n.format(t,a):a}function Ai(e,t,n){var i,r=0,o=e[r];for(;o;){if(i=!!n||o.style.display!==It,n&&o.classList.contains("k-hidden")&&o.classList.remove("k-hidden"),i&&!Ft.test(o.className)&&--t<0){o.style.display=n?"":It;break}o=e[++r]}}function Di(t,n){var i,r,o=0,a=t.length;for(;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(bt).first()),Ai(r[0].cells,n,!1))}function Ei(e){var t=[];var n;for(var i=0;i<e.length&&("field"in(n=e[i])&&"value"in n&&"items"in n);i++)t.push(n),n.hasSubgroups&&(t=t.concat(Ei(n.items)));return t}function Ii(t,n){var i,r,o=0,a=t.length;for(;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),Si(i.find(">form>table"),Pn(undefined),!1,0),r=i.find(bt).first()),Ai(r[0].cells,n,!0))}function zi(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 Pi(e){var t,n,i=0;var 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 Li=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),qt=n.support.isRtl(t),H=qt?"a[class*='-i-caret-alt-left']":R,o._element(),o._ariaId(),o._columns(e.extend(!0,[],o.options.columns)),o._bindMediaQueries(),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(),t._initToolbarItemsPopups(),t._ai(),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._setInitialRtlScrollPosition(),t.options.contextMenu&&t._initContextMenu(),t.lockedContent&&(t.wrapper.addClass("k-grid-lockedcolumns"),t._resizeHandler=function(){t.resize()},e(window).on("resize"+O,t._resizeHandler)),t._initLoader(),n.notify(t),t._showWatermarkOverlay&&t._showWatermarkOverlay(t.wrapper[0])},events:[X,Q,"dataBinding","cancel",te,ne,ie,W,j,G,q,K,V,N,$,U,ee,Y,Fe,Oe,Ve,J,Z,Ne,$e,Ue,We,je,qe,se,"page","sort","filter","group","groupExpand","groupCollapse","kendoKeydown"],setDataSource:function(e){var t=this;var i=t.options.scrollable;var r;t.options.dataSource=e,t._dataSource(),t._pageable(),t._thead(),t._rowResizing(),i&&(i.virtual?(r=t.content.find(">.k-virtual-scrollable-wrap"),n.scrollLeft(r,Ui(r,qt))):(r=t.tbody,n.scrollLeft(t.content,Ui(r,qt)))),t.options.groupable&&t._groupable(),t.virtualScrollable&&t.virtualScrollable.setDataSource(t.options.dataSource),t.options.navigatable&&t._navigatable(),t.options.selectable&&t._selectable(),t.options.autoBind?t.dataSource.fetch():t._footer()},options:{name:"Grid",adaptiveMode:"none",ai:null,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",dataLayoutMode:"columns",stackedLayoutSettings:{},messages:{loader:{loading:"Loading...",exporting:"Exporting..."},editable:{cancelDelete:"Cancel",confirmation:"Are you sure you want to delete this record?",confirmDelete:"Delete"},commands:{create:fn.create.text,cancel:fn.cancel.text,save:fn.save.text,destroy:fn.destroy.text,edit:fn.edit.text,update:fn.update.text,canceledit:fn.canceledit.text,excel:fn.excel.text,pdf:fn.pdf.text,search:fn.search.text,columns:fn.columns.text,select:"Select",selectall:fn.selectall.text,sort:fn.sort.text,filter:fn.filter.text,group:fn.group.text,columnchooser:fn.columnchooser.text,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"},details:{expand:"Expand Details",collapse:"Collapse Details"},ai:{outputPlaceholder:"No AI output available",success:"Operation is successful. Data is:",error:"Operation is not successful. Error:"},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",clearButtons:{clearFiltering:"Clear All Filters",clearSorting:"Clear Sorting",clearGrouping:"Clear Grouping",columnChooserReset:"Reset"},applyButtons:{applySorting:"Done",applyGrouping:"Done",columnChooserApply:"Apply"}},width:null},destroy:function(){var t,i,r=this;if(r._destroyColumnAttachments(),r._unbindToolbarTools(),l.fn.destroy.call(r),this._navigatableTables&&(this._navigatableTables.off(O),this._navigatableTables=null,this._headertables=null),r._resizeHandler&&e(window).off("resize"+O,r._resizeHandler),r._aiAssistant&&(r._aiAssistant?.destroy(),r._aiAssistant=null),r._aiAssistantWindow&&(r._aiAssistantWindow?.destroy(),r._aiAssistantWindow=null),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(se+O,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(X,r._refreshHandler).unbind(T,r._progressHandler).unbind(M,r._errorHandler).unbind(pt,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"+O),r.wrapper.off("contextmenu"+O)),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(O),t[0].kendoBindingTarget=null,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;var 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(),i=this.element;if(t.size){const e=n.getValidCssClass("k-grid-","size",t.size);i.removeClass(e)}n.deepExtend(t,e),e.dataSource?e.dataSource.filter&&(t.dataSource.filter=e.dataSource.filter):t.dataSource=this.dataSource;var r=this.wrapper;var o=this._events;if(this.destroy(),this.options=null,this._isMobile){var a=r.closest(n.roleSelector("pane")).parent();a.after(r),a.remove(),r.removeClass("k-grid-mobile")}r[0]!==i[0]&&(r.before(i),r.remove()),i.empty(),this.init(i,t,o),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(He))||t.hasClass("k-detail-row")||t.hasClass("k-group-footer"))}))},dataItems:function(){var e=n.ui.DataBoundWidget.fn.dataItems.call(this);if(this.lockedContent){var t=e.length,i=new Array(2*t);for(var 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()}))},_setInitialRtlScrollPosition:function(){const e=this;qt&&e.scrollables&&n.scrollLeft(e.scrollables,0)},_attachCustomCommandsEvent:function(){var e,t,n,i=this,r=pi(i.columns||[]);for(t=0,n=r.length;t<n;t++)(e=r[t].command)&&wn(i,i.wrapper,e)},_bindMediaQueries:function(){const e=this;if("auto"===e.options.adaptiveMode){e.largeMQL=n.mediaQuery("large"),e.mediumMQL=n.mediaQuery("medium"),e.smallMQL=n.mediaQuery("small");const t=(t,n)=>{if("popup"!==e._editMode())return;const i=!0===t||!1===t;let r;if(e._editContainer&&(r=e._editContainer&&e._editContainer.data(n)),!r){const t="kendoActionSheet"===n?"kendoWindow":"kendoActionSheet";r=e._editContainer&&e._editContainer.data(t)}i?r&&r.fullscreen&&r.visible()?(e._showAdaptiveView=!0,r.fullscreen(t)):r&&(e._showAdaptiveView=!1,e._destroyEditable(!0)):r&&r.fullscreen&&r.close()};e.smallMQL.onEnter((()=>{t(!0,"kendoActionSheet")})),e.mediumMQL.onEnter((()=>{t(!1,"kendoActionSheet")})),e.largeMQL.onEnter((()=>{t(null,"kendoWindow")}))}else e.smallMQL&&e.smallMQL.destroy(),e.mediumMQL&&e.mediumMQL.destroy(),e.largeMQL&&e.largeMQL.destroy(),e._showAdaptiveView=!1},_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"),h=this._ariaGridId(),u=l.attr(it),p=this._isStackedMode(),f=!p&&this.thead.find(bt).length+this.wrapper.find(".k-grid-footer-wrap table tr").length,m=this._trailingColumns(),g=this.virtualScroll,v=this.options.pageable;l.attr(it,u>=0?u:0),s&&l.attr(Et,s);const _=l.find("tbody");const b=l.find("thead");const w=l.find("tfoot");const y=l.find(bt);_.find(bt).length>0&&_.attr(Et,Pt),b.find(`${bt} th`).length>0&&b.attr(Et,Pt),w.find(bt).length>0&&w.attr(Et,Pt),y.children().length>0&&y.attr(Et,zt),l.find("th").attr(Et,Lt),l.find("td").attr(Et,Bt),v&&this.dataSource.totalPages()>1||g&&g.rows?(o=this._groups()>0?-1:this._hasDetails()?f+2*this.dataSource.total():f+this.dataSource.total(),l.attr(xt,o)):this._hasDetails()&&(o=this._groups()>0?-1:f+2*this.dataSource.total(),l.attr(xt,o)),o&&o>0&&this._ariaRowIndex(),(!p&&g&&g.columns||!l.attr(Ct)&&(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(Ct,m+pi(this.columns).length),this._ariaColumnIndex()),this.pager&&this.pager.element.attr("aria-controls",h),c.attr({role:"toolbar","aria-label":this.options.messages.toolbarLabel,"aria-controls":h}),d.attr({role:"toolbar","aria-label":this.options.messages.groupingHeaderLabel,"aria-controls":h}),t=p?"":this._ariaHeaderFooter("header","thead","th, td",Lt),i=this._ariaHeaderFooter("footer","tfoot","td",Bt),!p&&a.find(".k-grid-content-locked").length>0&&this._ariaLockedContent(),(t||i)&&(r=[t,e=this.tbody.attr(vt)||n.guid(),i].join(" "),this.tbody.attr(vt,e),l.attr(kt,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,h=0,u=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&&h<o&&(h=o),0===a.length&&d<o&&(d=o),null!==r?(i.setAttribute(St,Number(o)+1),t=Number(o)+1+i.getAttribute("colspan")):(i.setAttribute(St,t+1),t+=i.getAttribute("colspan"))};for(2===a.length?(u=Number(a[0].getAttribute("colspan")),p=Number(a[1].getAttribute("colspan"))):1===a.length&&0===a.prev().length?u=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<=h;n++)i=n+o,this.wrapper.find(".k-grid-content-locked tbody > tr > td:nth-child("+(n+1)+")").attr(St,i+1);for(n=u;n<=d-c-p;n++)r=0===u?n+1:n-u+2,i=c+n+o,this.tbody.find("> tr > td:nth-child("+r+")").attr(St,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="";if(s.length>0){c=(o=s.find(t+", tbody")).attr(vt)||n.guid(),s.attr(Et,It);const e=s.find(bt);e.children().length>0&&(e.attr(Et,zt),o.attr(Et,Pt)),s.find(i).attr(Et,r),o.attr({id:c})}return l.length>0&&this._ariaLocked(e,t,i,r),l.find("td").attr(Et,Bt),s.find("td").attr(Et,Bt),c},_ariaId:function(){var e=this.element.attr(vt)||"aria";e&&(this._cellId=e+"_active_cell")},_ariaGridId:function(){var e=this.table,t=e.attr(vt);return t||(t=n.guid(),e.attr(vt,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(bt),d=l.find(bt);l.attr(Et,It),l.find(n+", tbody").attr(Et,It),d.attr(Et,It),l.find(i).attr(Et,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(kt,a.join(" "))}))},_ariaLockedContent:function(){var t=this,n=t.table.find(bt),i=t.wrapper.find(".k-grid-content-locked table"),r=i.find(bt);i.attr(Et,It),i.find("tbody").attr(Et,It),r.attr(Et,It),i.find("td").attr(Et,Bt),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(kt,o.join(" "))}))},_ariaAddHiddenColIndex:function(){var e=this.virtualScroll||{},t=this.columns,n=this.table,i=pi(t).length;e.columns||n.attr(Ct)||(this._ariaColumnIndex(),n.attr(Ct,i))},_ariaRemoveHiddenColIndex:function(){var e=this.virtualScroll||{},t=pi(this.columns).length;e.columns||t!==ci(this.columns).length||(this.wrapper.find("td, th").removeAttr(St),this.table.removeAttr(Ct))},_ariaRowIndex:function(){var e,t,n=!this._isStackedMode()&&this.thead.find(">tr"),i=n?n.length:0,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(Tt,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(Tt,l);for(l=i+a+1,e=0;e<o.length;e++)o.eq(e).attr(Tt,l+e)},_cellsIds:function(e,t,n){var i=[],r=this._ariaGridId();return e.each((function(e,o){var a=o.getAttribute(vt)||r+"_"+t+"_"+n+"_"+e;o.setAttribute(vt,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=this;var o=r.options.columnResizeHandleWidth;var a=r.options.scrollable;var s=r.resizeHandle;var l=3*o/2;var c=0;var h;var u;var p;var f;var m;var g;var v;s&&r.lockedContent&&s.data("th")[0]!==i[0]&&(s.off(O).remove(),s=null),s||(s=r.resizeHandle=e('<div class="k-resize-handle"><div class="k-resize-handle-inner"></div></div>'),t.append(s)),m=n.scrollLeft(t),qt&&(Gt.mozilla||Gt.webkit&&Gt.version>=85)&&(m*=-1),f=parseFloat(t.css("borderLeftWidth")),g=i.offset().left+m-parseFloat(i.css("marginLeft"))-(t.offset().left+f),qt?a&&(c=g<=m?l:0,(h=i.closest(".k-grid-header-wrap, .k-grid-header-locked"))[0].scrollWidth-h[0].offsetWidth,p=parseFloat(h.css("marginLeft")),u=Gt.msie?2*n.scrollLeft(h)+f-p-c:0,g-=-c+(Gt.mozilla?f-p-c:0)+u):g+=i[0].offsetWidth,v=i.offset().top-parseFloat(i.css("marginTop"))-(t.offset().top+parseFloat(t.css("borderTopWidth"))),s.css({top:v,left:g-l,height:d(i),width:3*o-c}).data("th",i).show(),s.off(Je+O).on(Je+O,(function(){r._autoFitLeafColumn(parseInt(i.attr(n.attr("index")),10))}))},_positionColumnResizeHandle:function(){var t=this,i=t.lockedHeader?t.lockedHeader.find("thead").first():e();t.thead&&t.thead.add(i).on(Ze+O,"tr:not(.k-filter-row) > th:not([data-resizable=false])",(function(i){var r=void 0!==i.buttons?i.buttons:i.which||i.button;var 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(wt),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+xe).find(S+Ce+","+S+Se).show(),t.find(S+Te).show(),t.find(S+De).show(),t.find(S+Ee).show())},_hideResizeHandle:function(){this.resizeHandle&&(this.resizeHandle.data("th").removeClass("k-column-active"),this.lockedContent&&!this._isMobile?(this.resizeHandle.off(O).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+xe).find(S+Ce+","+S+Se).hide(),i.find(S+Te).hide(),i.find(S+De).hide(),i.find(S+Ee).hide(),t._createResizeHandle(i.closest(wt),i),t._resizeHandleDocumentClickHandler||(t._resizeHandleDocumentClickHandler=t._resizeHandleDocumentClick.bind(t)),e(document).on("click",t._resizeHandleDocumentClickHandler)}})},resizeColumn:function(t,i){var r=this;var o=!!t.locked;var a=!!t.hidden;var s=this.options;var l=n.support.mobileOS?0:n.support.scrollbar();var d=_(t,o?li(ci(r.columns)):si(ci(r.columns)));var h=o?r.lockedTable:r.table;var u=r.footer||e();var p=t.minResizableWidth||10;var f=c(o?h.find("tbody"):r.tbody);var m;if(!this._isStackedMode()){var g=o?r.lockedHeader.find("table"):r.thead.closest("table");if(a)t.width=i>p?i:p;else{if(r.footer&&r.lockedContent&&(u=o?r.footer.children(".k-grid-footer-locked"):r.footer.children(".k-grid-footer-wrap")),m=s.scrollable?g.find("col:not(.k-group-col,.k-hierarchy-col)").eq(d).add(h.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(d)).add(u.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(d)):h.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(d),s.scrollable){var v=!1;var b=r.wrapper.width()-l;var w=i=i>p?i:p;o&&f-i+w>b&&((w=i+(b-f-2*l))<0&&(w=i),v=!0),w>10&&w>=p&&(m.css("width",w),f&&(w=v?b-2*l:f+(i-t.width),h.add(g).add(u).css("width",w),o||(r._footerWidth=w))),r._scrollVirtualWrapperOnColumnResize()}else i>10&&i>=p&&m.css("width",i);t.width=i,r._applyLockedContainersWidth(),r._syncLockedContentHeight(),r._syncLockedHeaderHeight(),r._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,h,u,p=this,f=p.options,m=this._isMobile,g=n.support.mobileOS?0:n.support.scrollbar();!p._isStackedMode()&&(!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){u=e(t.currentTarget).data("th"),m&&p._hideResizeHandle();let n=u.closest("table"),i=e.inArray(u[0],_i(u.closest("thead")).filter(":visible"));let 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");vn(p.wrapper,"col-resize"),h=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(u),a=pi(_)[i].minResizableWidth||10,s=c(l?d.children("tbody"):p.tbody),Gt.webkit&&p.wrapper.addClass("k-grid-column-resizing"),p._adjustColWidths(d,n,v,s)},resize:function(t){var n=qt?-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=u.closest("table");var m=l?p.lockedTable:p.table;var v=!1;var _=p.wrapper.width()-g;var b=i;l&&s-o+b>_&&((b=o+(_-s-2*g))<0&&(b=i),v=!0),b>10&&b>=a&&(h.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&&h.css("width",i)},resizeend:function(){var e,t,i=c(u);if(vn(p.wrapper,""),Gt.webkit&&p.wrapper.removeClass("k-grid-column-resizing"),u&&o!=i){t=p.lockedHeader?p.lockedHeader.find("thead").first().find(bt).first().add(p.thead.find(bt).first()):u.parent();var r=u.attr(n.attr("index"));r||(r=t.find("th:not(.k-group-cell):not(.k-hierarchy-cell)").index(u)),(e=pi(p.columns)[r]).width=i,p.trigger(Oe,{column:e,oldWidth:o,newWidth:i}),p._applyLockedContainersWidth(!0),p._syncLockedContentHeight(),p._syncLockedHeaderHeight(),p._updateStickyColumns()}p._resetResizeHandleHeader(),p._hideResizeHandle(),u=null}}))},_addLockedRowResizing:function(e){var t=e.index();return this.lockedTable.find(bt).eq(t).add(this.tbody.find(bt).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);a&&(r[a[t]]=n[o])})),this._cachedRowsHeight=r},_rowResizerDblClick:function(){var t,n,i=this,r=i.rowResizer,o=r.data(bt),a=d(o);n=o.hasClass(be)?i.select():o,i.lockedTable?(n=(o=i._addLockedRowResizing(o)).hasClass(be)?i.lockedTable.find(S+be):i.lockedTable.find(bt).eq(o.index())).each(((t,n)=>{var r=n.rowIndex,o=e(n).add(i.tbody.find(bt).eq(r)),a=i._getMinRowHeight(o);o.css(et,a)})):n.css(et,nt),i._clearCachedRowsHeight(n),r.removeClass(me),r.removeClass(ge),a!=(t=d(o))&&i.trigger(Fe,{row:o,rows:n,oldHeight:a,newHeight:t})},_setupRowResizer(e,t,n){e.data(bt,t).css({top:n})},_attachRowResizerEvents:function(){var e=this.rowResizer,t=!1;e.on(Ke+O,(t=>{0===t.button&&(e.removeClass(me),e.addClass(ge))})).on(Ye+O,(t=>{0===t.button&&(e.removeClass(ge),e.addClass(me))})).on(Qe+O,(()=>{t=!0,setTimeout((()=>{t&&e.addClass(me)}),200)})).on(Xe+O,(()=>{t=!1,e.removeClass(me)}))},_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(wt);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(Je+O).on(Je+O,i._rowResizerDblClick.bind(i))),n=i._getResizerTop(r,c),0!==l.length&&o/2>a?l.hasClass(He)||i._setupRowResizer(s,l,n):r.hasClass(He)||i._setupRowResizer(s,r,n+o)},_detachRowResizerEvents:function(){this.rowResizer.off(Ke+O).off(Ye+O).off(Qe+O).off(Xe+O)},_mapResizedRows:function(t,n,i){var r=this;t.each(((t,o)=>{var a;if(n){var s=o.rowIndex,l=i,c=0,h=e(o).add(r.tbody.find(bt).eq(s));h.each(((e,t)=>{var n;t.style.height="",(n=d(t))>c&&(c=n)})),l<c?(l=c,r._clearCachedRowsHeight(h.eq(0))):r._cacheRowHeight(h.eq(0),l),h.css(et,l)}else o.style.height="",a=d(o),i>a?(o.style.height=i+_t,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(Ze+O,".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(bt),a.lockedTable&&(o=a._addLockedRowResizing(o)),o.addClass(me),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(be)?(e=a.select(),o.length>1&&e.length>o.length&&(e=a.lockedTable.find(S+be).not(o),n=!0)):e=o,a._mapResizedRows(e,n,t),o.removeClass(me),a.rowResizer.removeClass(ge),a.rowResizer.addClass(me),a._attachRowResizerEvents(),n&&(e=a.select()),r!=t&&a.trigger(Fe,{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");r.addClass("k-grid-draggable-header"),t._draggableInstance=t.wrapper.kendoDraggable({group:n.guid(),autoScroll:!0,filter:t.content?".k-grid-header:first "+L:"table:first>.k-grid-header "+L,dragstart:function(){r.children(".k-grid-header-wrap").off("scroll"+O+"scrolling").on("scroll"+O+"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"+O+"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:L,allowDropAfterLastItem:!0,dragOverContainers:function(e,n){let i=qn(t.columns);return!1!==i[e].lockable&&Gn(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=qn(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&&Gn(s,t.columns,o,a)>-1},change:function(e){let n=qn(t.columns);let i=n[e.oldIndex];let r=Gn(n,t.columns,e.oldIndex,e.newIndex);t.trigger(Ve,{newIndex:r,oldIndex:_(i,n),column:i}),t.reorderColumn(r,i,"before"===e.position)}}))},_reorderHeader:function(e,t,n,i){var r=this;var o=$n(e[0],r.columns);var a=$n(t,r.columns);var s;var l;var c=[];for(var d=0;d<e.length;d++)e[d].columns&&(c=c.concat(e[d].columns));l=i?bn(i,i,"tr:eq("+o.row+")>th.k-header:not(.k-group-cell,.k-hierarchy-cell)"):bn(r.lockedHeader,r.thead,"tr:eq("+o.row+")>th.k-header:not(.k-group-cell,.k-hierarchy-cell)");var h=ri(e).length;var u=ri([t]).length;var p,f,m,g,v,_;c.length?(h>0&&0===u?(s="prepend",Fn(e,t,c,r.columns,r.lockedHeader.find("thead"),r.thead,this._groups(),s)):0===h&&u>0&&(s=0!==a.cell||!e[0].columns||t.columns||r._group?"append":"prepend",Fn(e,t,c,oi(r.columns),r.thead,r.lockedHeader.find("thead"),this._groups(),s)),(t.columns||o.cell-a.cell>1||a.cell-o.cell>1)&&(t=Wn(r.columns,t,e[0],n,r.columns))&&(h>0&&0===u?r._reorderHeader(c,t,n,r.thead):0===h&&u>0?r._reorderHeader(c,t,n,r.lockedHead):r._reorderHeader(c,t,n))):h!==u&&(p=l[o.cell],f=r.columns,m=h,g=Vn(ri(f)),v=Vn(oi(f)),_=p.rowSpan,p.rowSpan=m?g>v?_-(g-v)||1:_+(v-g):g>v?_+(g-v):_-(v-g)||1),_n(l,o.cell,a.cell,n,e.length)},_reorderContent:function(t,n,i){var r=this;var o=e();var a=t[0];var s=Pn(t);var l=_(a,pi(r.columns));var c=_(n,pi(r.columns));var d=_(s[0],ci(r.columns));var h=_(n,ci(r.columns));var u=ri(r.columns).length;var p=!!n.locked;var f=r.footer||r.wrapper.find(".k-grid-footer");var m,g,v;if(m=g=h,n.hidden){var b=p?ri(r.columns):oi(r.columns);Pn(b).length>0?(m=g=h=this._findClosestVisibleColumnIndex(b,c),v=Pn(b.slice(c)).length>0):p?(h=r.lockedTable.find("colgroup"),m=r.lockedHeader.find("colgroup"),g=e(r.lockedFooter).find(">table>colgroup")):(h=r.tbody.prev(),m=r.thead.prev(),g=f.find(".k-grid-footer-wrap").find(">table>colgroup"))}r._hasFilterRow()&&_n(r.wrapper.find(".k-filter-row td:not(.k-group-cell,.k-hierarchy-cell)"),l,c,i,t.length),d>=0&&_n(bn(r.lockedHeader,r.thead.prev(),P),d,m,v||i,s.length),r.options.scrollable&&d>=0&&!r._hasVirtualColumns()&&_n(bn(r.lockedTable,r.tbody.prev(),P),d,h,v||i,s.length),f&&f.length&&(d>=0&&_n(bn(r.lockedFooter,f.find(".k-grid-footer-wrap"),">table>colgroup>col:not(.k-group-col,.k-hierarchy-col)"),d,g,v||i,s.length),_n(f.find(".k-footer-template>td:not(.k-group-cell,.k-hierarchy-cell)"),l,c,i,t.length));var w=r.tbody.children(":not(.k-grouping-row,.k-detail-row)");r.lockedTable&&(u>c?u<=l&&zi(r.lockedTable.find(">tbody>tr.k-grouping-row:not([hidden])"),r.table.find(">tbody>tr.k-grouping-row:not([hidden])"),t.length):u>l&&zi(r.table.find(">tbody>tr.k-grouping-row:not([hidden])"),r.lockedTable.find(">tbody>tr.k-grouping-row:not([hidden])"),t.length),o=r.lockedTable.find(">tbody>tr:not(.k-grouping-row,.k-detail-row)"));for(var y=0,k=w.length;y<k;y+=1)_n(bn(o[y],w[y],">td:not(.k-group-cell,.k-hierarchy-cell)"),l,c,i,t.length)},_findClosestVisibleColumnIndex:function(e,t){var n=Pn(e.slice(t)).length>0?e.slice(t):e.slice(0,t+1).reverse(),i=Pn(n)[0];return _(i,Pn(this.columns))},_autoFitLeafColumn:function(e){this.autoFitColumn(pi(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?" > [ref-grid-drag-cell]":":not(:has([data-container-for]))"),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+" "+y(t.options.messages.itemsSelected)+"</span>");else if(i&&t.select().length>1&&!t.lockedContent)o.append("<span>"+t.select().length+" "+y(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.replace(/<(\/?)script([^>]*)>/gi,"")+" </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(je,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(je,{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){let t=n.dataItem(e);return t._isMoved=!0,t}));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,h,u,f,m=this,v=m.options,b=m.columns,w=m.lockedHeader?_i(m.lockedHeader.find(">table>thead")).filter(En).length:0,y="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(Kn(b),(function(e){return e===t}))[0]:g(Kn(b),(function(e){return e.field===t}))[0])&&zn(t)){a=pi(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-=w);for(var T=0;T<a.length&&a[T]!==t;T++)a[T].hidden&&i--;v.scrollable?(l=o.find(y).eq(i).add(x.children("colgroup").find(y).eq(i)).add(S.find("colgroup").find(y).eq(i)),s||(h=x.parent(),u=n.scrollLeft(h)),m._hasVirtualColumns()&&(i=_(t,m.virtualCols))):l=x.children("colgroup").find(y).eq(i);var M=o.add(x).add(S);Gt.safari&&r.css("white-space","initial");var A=c(r);l.width(""),M.css("table-layout","fixed"),l.width(nt),M.addClass("k-autofitting"),M.css("table-layout",""),f=c(r);var D=Math.ceil(Math.max(f,c(x.find("tr:not(.k-grouping-row)").eq(0).children(k).eq(i)),c(S.find(bt).eq(0).children(k).eq(i))))+1;if(d&&d>D&&(D=d),l.width(D),t.width=D,Gt.safari&&r.css("white-space",""),v.scrollable){var E,I=o.find("col"),z=0;for(var P=0,L=I.length;P<L;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&&M.each((function(){this.style.width=z+_t}))}M.removeClass("k-autofitting"),u&&n.scrollLeft(h,u),m.trigger(Oe,{column:t,oldWidth:A,newWidth:D}),m._applyLockedContainersWidth(),m._syncLockedContentHeight(),m._syncLockedHeaderHeight(),m._updateStickyColumns()}},reorderColumn:function(e,n,i){var r,o=this,a=kn(n,o.columns),s=a?a.columns:o.columns,l=_(n,s),c=s[e],d=o.virtualScroll||{},h=!!c.locked,u=ri(o.columns).length,p=g(pi(o.columns),(function(e){return e.groupHeaderColumnTemplate}));if(!o._isStackedMode()&&l!==e&&(n.locked||!h||1!=oi(o.columns).length)&&(!n.locked||h||1!=u)){o._hideResizeHandle(),i===t&&(i=e<l);var f=[n];o._reorderHeader(f,c,i),o.lockedHeader&&(Zn(o.thead),Zn(o.lockedHeader)),c.columns&&(c=(c=pi(c.columns))[i?0:c.length-1]),n.columns&&(f=pi(n.columns)),o._reorderContent(f,c,i),r=(r=!!n.locked)!=h,n.locked=h,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&&(h?o.trigger(Ne,{column:n}):o.trigger($e,{column:n}))}},_updateColumnCellIndex:function(){var e=0;this.lockedHeader&&(e=On(this.lockedHeader.find("thead"),ri(this.columns))),On(this.thead,oi(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=ri(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=ri(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(ai(t)),e.sticky=!1,this._updateStickyColumns(),0===this._anyStickyColumns()&&(this._templates(),this._hasFilterRow()&&this._updateStickyFilterCells()))},cellIndex:function(t){var n=0;const i=this._isStackedMode()?"div.k-grid-stack-cell":"td";return this.lockedTable&&!e.contains(this.lockedTable[0],t[0])&&(n=pi(ri(this.columns)).length),e(t).parent().children(i+":not(.k-group-cell,.k-hierarchy-cell)").index(t)+n},_modelForContainer:function(t){(t=e(t)).is(bt)||"popup"===this._editMode()||(t=t.closest(bt));var i=t.attr(n.attr("uid"))||t.find("[ref='popup-edit-form']").attr(n.attr("uid"));return this.dataSource.getByUid(i)},_calculateColumnIndex:function(t){var n=this.cellIndex(t);var i=0;return this._hasVirtualColumns()&&(i=(i=parseInt(e(t).closest(bt).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);i._isEditableEnabled=i._isEditableEnabled!==t?i._isEditableEnabled:!r.readonly;const c=i._isStackedMode();if(i._isEditableEnabled||i._removeEditableClickHandlers(),r&&i._isEditableEnabled){"incell"===i._editMode()?(i.table.add(i.lockedTable).on(Ke+O,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&&(Yt&&i.wrapper.on(Ge+O,".k-edit-cell > input[type='checkbox']",(function(t){e(t.target).trigger("focus")})).on(Ge+O,".k-edit-cell",(function(t){e(t.target).is("input")||e(t.currentTarget).find("input[type='checkbox']").trigger("focus")})).on(Ke+O,"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:c?".k-grid-stack-row:not(.k-grouping-row) div.k-grid-stack-cell":"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];if(i._mousedownOnEditCell=!1,n.hasClass("k-hierarchy-cell")||n.hasClass("k-detail-cell")||n.hasClass("k-group-cell")||n.hasClass("k-edit-cell")||n.hasClass("k-drag-cell")||n.hasClass("k-grid-stack-edit-cell")||n.has(".k-grid-remove-command").length||n.closest("tbody")[0]!==i.tbody[0]&&!r||e(t.target).is(":input"))return;let o;c&&(o=n.parent().children().index(n)),i.editable?i.editable.end()?(e(s()).trigger("blur"),i.closeCell(),i._requestInProgress||i.editCell(n,o)):i._scrollVirtualWrapper():i.editCell(n,o)}}),i.wrapper.on("focusin"+O,(function(){e.contains(this,s())||(clearTimeout(i.timer),i.timer=null)})).on("focusout"+O,(function(t){var n=!0;(Yt&&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._toggleToolbarEditingItemsVisibility()):i._scrollVirtualWrapper())}()}),1))})))):!1!==r.update&&(i._editCommandClickHandler=i._editCommandClick.bind(i),i.wrapper.on(Ge+O,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-edit-command",i._editCommandClickHandler),i._isVirtualInlineEditable()&&i.wrapper.on("focusout"+O,"tr:not(.k-grouping-row) > td",(function(){i.editable&&!i.editable.end()&&i._scrollVirtualWrapper()}))),i._removeCommandClickHandler=i._removeCommandClick.bind(i),i.wrapper.on(Ge+O,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-remove-command",i._removeCommandClickHandler)}},_getLastSelectedItemModel:function(){const e=this;if(!e.options.selectable)return;const t=e.getSelectedData();if(!t||!t.length)return;const n=t[t.length-1];return e.dataSource.getByUid(n.uid)},_removeToolbarClick:function(e){e.event?(e.event.preventDefault(),e.event.stopPropagation()):e.preventDefault();const t=this;const i=this._getLastSelectedItemModel();if(!i)return;const r=t.tbody.children("["+n.attr("uid")+"="+i.uid+"]");t.removeRow(r),t.one(te,(()=>{t._toggleToolbarEditingItemsVisibility()}))},_editToolbarClick:function(e){e.event?(e.event.preventDefault(),e.event.stopPropagation()):e.preventDefault();if("incell"===this._editMode())return;const t=this._getLastSelectedItemModel();t&&this.editRow(t)},_editCommandClick:function(t){let n=e(t.currentTarget);this._belongsToGrid(n)&&(t.preventDefault(),this.editRow(n.closest(bt)))},_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(bt))):(t.stopPropagation(),n._confirmation()||t.preventDefault()),n._toggleToolbarEditingItemsVisibility())},editCell:function(t,n){t=e(t);let i=this,r=0===n||n?n:i._calculateColumnIndex(t),o=pi(i.columns)[r],a=i._modelForContainer(t);const s=i._isStackedMode();const l=s?"k-grid-stack-edit-cell":"k-edit-cell";i.closeCell();const c=s?t.find(".k-grid-stack-content"):t;if(a&&Vi(o,a)&&!o.command){if(i.trigger(N,{model:a}))return;i._attachModelChange(a),i._editContainer=c,i._shouldClearEditableState&&i._clearEditableState(),t.addClass(l);const e=(i._isVirtualIncellEditable()||i._hasVirtualColumns())&&i._editableState;i.editable=c.kendoEditable({fields:vi(o,i._isAdaptive()?"auto":"none"),model:a,size:i.options.size,target:i,change:function(e){i.trigger($,{values:e.values,container:t,model:a})&&e.preventDefault()},skipFocus:e}).data("kendoEditable");let n=t.closest(bt);s||n.addClass("k-grid-edit-row"),!0!==a.new||s||(n.addClass("k-grid-add-row"),delete a.new),i.lockedContent&&(Bi(n[0],i._relatedRow(n).addClass("k-grid-edit-row")[0]),n.hasClass("k-grid-add-row")&&i._relatedRow(n).addClass("k-grid-add-row"),i._syncLockedScroll()),i.trigger(V,{container:t,model:a}),i._toggleToolbarEditingItemsVisibility()}},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();let i=t.find(".k-grid-edit-command").getKendoButton();let r=t.find(".k-grid-remove-command").getKendoButton();let o=t.find(".k-grid-cancel-changes").getKendoButton();let a=t.find(".k-grid-save-changes").getKendoButton();let s=t.find(".k-grid-cancel-command").getKendoButton();let l=t.find(".k-grid-save-command").getKendoButton();n&&n.bind("click",e._createClickHandler),i&&i.bind("click",e._editClickHandler),r&&r.bind("click",e._destroyClickHandler),o&&o.bind("click",e._cancelClickHandler),a&&a.bind("click",e._saveClickHandler),s&&s.bind("click",e._editCancelClickHandler),l&&l.bind("click",e._updateClickHandler)}e._toggleToolbarEditingItemsVisibility()},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,e._toggleToolbarEditingItemsVisibility())},_removeEditableClickHandlers:function(){let e=this,t=e.wrapper.find(".k-grid-toolbar");e.wrapper.off(Ge+O,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-edit-command",e._editCommandClickHandler),e.wrapper.off(Ge+O,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-remove-command",e._removeCommandClickHandler),t.off(Ge+O,".k-grid-add",e._createClickHandler),t.off(Ge+O,".k-grid-edit-command",e._editClickHandler),t.off(Ge+O,".k-grid-remove-command",e._destroyClickHandler);let n=t.find(".k-grid-add").getKendoButton();let i=t.find(".k-grid-edit-command").getKendoButton();let r=t.find(".k-grid-remove-command").getKendoButton();let o=t.find(".k-grid-cancel-changes").getKendoButton();let a=t.find(".k-grid-save-changes").getKendoButton();let s=t.find(".k-grid-cancel-command").getKendoButton();let l=t.find(".k-grid-save-command").getKendoButton();n&&n.unbind("click"),i&&i.unbind("click"),r&&r.unbind("click"),o&&o.unbind("click"),a&&a.unbind("click"),s&&s.unbind("click"),l&&l.unbind("click"),e._editCommandClickHandler=null,e._removeCommandClickHandler=null},_adjustLockedHorizontalScrollBar:function(){var e=this.table,t=e.parent();var 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");var 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=e.offsetHeight;var i=t.offsetHeight;var r;var o;n>i?(r=t.rows[t.rows.length-1],Ot.test(r.className)&&(r=t.rows[t.rows.length-2]),o=n-i):(r=e.rows[e.rows.length-1],Ot.test(r.className)&&(r=e.rows[e.rows.length-2]),o=i-n),r.style.height=r.offsetHeight+o+_t}}(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;const t=e._editContainer&&e._editContainer.length&&e._editContainer.closest(".k-window").length?"kendoWindow":"kendoActionSheet";let n=function(){if(e.editable){let n=e.editView?e.editView.element:e._editContainer;let i=e._editContainer.data(t);n&&(i&&(n=i.wrapper),n.off(Ge+O,".k-grid-cancel-command, button[ref-cancel-button], [ref-actionsheet-action-button]:not(.k-button-solid-primary)",e._editCancelClickHandler),n.off(Ge+O,".k-grid-save-command, button[ref-update-button], [ref-actionsheet-action-button].k-button-solid-primary",e._editUpdateClickHandler)),e._detachModelChange(),e.editable.destroy(),e.editable=null,i&&i.destroy(),e._editContainer=null,e._destroyEditView(),e._editableIsClosing=null}};e.editable&&("popup"!==e._editMode()||e._isMobile?n():e._editableIsClosing?e._editContainer.data(t).bind("deactivate",n):(e._editableIsClosing=!0,e._editContainer.data(t).bind("deactivate",n).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(X,e._modelChangeHandler)},closeCell:function(e){let t,n,r,o,a=this,s=a._editContainer;if(!s)return;if(r=a._modelForContainer(s),e&&a.trigger("cancel",{container:s,model:r}))return;const l=a._isStackedMode();const c=l?"k-grid-stack-edit-cell":"k-edit-cell";const d=s.closest(S+c);a.trigger(Y,{type:e?"cancel":"save",model:r,container:s});const h=l?d.parent().children().index(d):a._calculateColumnIndex(s);if(l?d.removeClass(c):s.removeClass(c),t=pi(a.columns)[h],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.closest(bt).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")}if(a._destroyEditable(),a._displayCell(s,t,r),a._shouldClearEditableState&&a._clearEditableState(),a.trigger("itemChange",{item:n,data:r,ns:i}),a._activeStackedCell&&a._setCurrentStackedCell(s),a.lockedContent){const e=n&&n.data("uid");const t=(a._cachedRowsHeight&&a._cachedRowsHeight[e])??"";Bi(n.css(et,t)[0],a._relatedRow(n).css(et,t)[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(n){var i,r,o,a=this,s=a._editMode();"incell"!==s&&a.cancelRow(),n=e(n),a.lockedContent&&(n=n.add(a._relatedRow(n))),n=n.hide(),a.dataSource._isGroupPaged()&&a._removeGroupIfEmpty(n),(i=a._modelForContainer(n))!=t&&i.hasOwnProperty("_isMoved")&&delete i._isMoved,i&&!a.trigger(U,{row:n,model:i})?(o=a.dataSource.options.schema,a._selectedIds&&o&&o.model&&(r=i[a._getSchemaIdField()],delete a._selectedIds[r]),a.dataSource.remove(i),"inline"!==s&&"popup"!==s||a.dataSource.sync()):"incell"===s&&a._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=r._editMode();let s;if(r.cancelRow(),i){if(t=r.tbody.children("["+n.attr("uid")+"="+i.uid+"]"),r._attachModelChange(i),"popup"===a)r._createPopupEditor(i);else if("inline"===a)r._createInlineEditor(t,i);else if("incell"===a){const n=r._isStackedMode();(n?t.find(".k-grid-stack-cell:not(.k-command-cell):not(.k-drag-cell)"):t.children(A)).each((function(){let t=e(this);const o=n?t.parent().children().index(t):r._calculateColumnIndex(t);let a=pi(r.columns)[o];if(i=r._modelForContainer(t),i&&(!i.editable||i.editable(a.field))&&a.field&&!a.selectable&&!a.draggable)return r.editCell(t,o),!1}))}s=r.editView?r.editView.element:"popup"===a?r._editContainer.parent():r._editContainer,s&&(this._editCancelClickHandler||(this._editCancelClickHandler=this._editCancelClick.bind(this)),s.on(Ge+O,".k-grid-cancel-command, button[ref-cancel-button], [ref-actionsheet-action-button]:not(.k-button-solid-primary)",this._editCancelClickHandler),this._editUpdateClickHandler||(this._editUpdateClickHandler=this._editUpdateClick.bind(this)),s.on(Ge+O,".k-grid-save-command, button[ref-update-button], [ref-actionsheet-action-button].k-button-solid-primary",this._editUpdateClickHandler)),r._toggleToolbarEditingItemsVisibility()}},_editUpdateClick:function(t){t.preventDefault(),t.stopPropagation?t.stopPropagation():t.event&&t.event.stopPropagation&&t.event.stopPropagation();const n=e(t.currentTarget);const i=this.editable?.validatable;i?.one("validate",(()=>{const e=i?.errors()?.length;n.is("[ref-update-button]")&&!e&&(n.addClass("k-disabled"),n.attr("aria-disabled",!0))})),this.saveRow(),this._preventOnCloseEditableChanges="popup"===this._editMode(),this.one(te,(()=>{this._toggleToolbarEditingItemsVisibility()}))},_editCancelClick:function(t){var n=this;var i=n.options.navigatable;var r=n.editable.options.model;var o=n.editView?n.editView.element:n._editContainer;if(t.preventDefault(),t.stopPropagation?t.stopPropagation():t.event&&t.event.stopPropagation&&t.event.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()),Ri(n.table,!0)),this._toggleToolbarEditingItemsVisibility()}},_editFields:function(e,t){var n=[];var i;for(var r=0;r<e.length;r++)(i=e[r]).selectable||i.command||Vi(i,t)&&n.push(vi(i,this._isAdaptive()?"auto":"none"));return n},_createPopupEditor:function(t){var r=this;var o="<div "+n.attr("uid")+'="'+t.uid+'" ref="popup-edit-form"><'+(r._isMobile?'ul class="k-edit-form-container k-listgroup k-listgroup-flush">':'div class="k-edit-form-container">');var a;var s;var l;var c;var d;var h;var u;var m;var g;var v;var _=pi(r.columns);var b;var w=n.guid();var k=r.options.editable;var x=k.template;var C=p(k)?k.window:{};var S=f({},n.Template,r.options.templateSettings);var T;var M;const A=r._isAdaptive();if(!r.trigger(N,{model:t})){if(C=C||{},x)for(typeof x===ot&&(x=n.unescape(x)),o+=n.template(x,S)(t),l=0,c=_.length;l<c;l++)(a=_[l]).command&&(v=Hi(a.command,"edit"))&&(s=v);else for(l=0,c=_.length;l<c;l++)(a=_[l]).selectable||(a.command?a.command&&(v=Hi(a.command,"edit"))&&(s=v):r._isMobile&&(o+='<li class="k-item k-listgroup-item">',Vi(a,t)?(o+='<label class="k-label k-listgroup-form-row">',o+='<span class="k-item-title k-listgroup-form-field-label">'+(a.title&&(r.options.encodeTitles?Yi(a.title,!0):a.title)||a.field||"")+"</span>",o+='<div class="k-listgroup-form-field-wrapper" id="'+a.field+"_"+w+'" '+n.attr("container-for")+'="'+a.field+'"></div>',o+="</label>"):(T={storage:{},count:0},d=n.template(r._cellTmpl(a,T),S),T.count>0&&(d=d.bind(T.storage)),o+='<label class="k-label k-listgroup-form-row k-no-click">',o+='<span class="k-item-title k-listgroup-form-field-label">'+(a.title&&(r.options.encodeTitles?Yi(a.title,!0):a.title)||a.field||"")+"</span>",o+='<span class="k-no-editor k-listgroup-form-field-wrapper">'+d(t)+"</span>",o+="</label>"),o+="</li>"));if(s&&p(s)&&(p(s.text)&&(h=s.text.update,u=s.text.cancel),p(s.iconClass)&&(m=s.iconClass.update,g=s.iconClass.cancel),s.attr&&(b=s.attr)),r._isMobile){o+="</ul></div>";let e=y(r.options.messages.commands.cancel);let t=y(r.options.messages.commands.update);r.editView=r.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>${y(r.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="'+Qt+'">'+o+"</div></div>"),M=r._editContainer=r.editView.element.find("[ref='popup-edit-form']")}else{let n=e(r._createButton({name:"update",text:h,attr:b,iconClass:m,size:"medium",skipCommandClass:!0})).attr("ref-update-button","");let i=e(r._createButton({name:"canceledit",text:u,attr:b,iconClass:g,size:"medium",skipCommandClass:!0})).attr("ref-cancel-button","");o+="</div>",M=r._editContainer=A?e(o).appendTo("body").eq(0).kendoActionSheet({modal:!0,adaptive:!0,title:t.id?"Edit record":"Add new record",fullscreen:r.smallMQL.mediaQueryList.matches,closeButton:!0,actionButtons:[{text:"Cancel",icon:"cancel"},{text:"Save",icon:"save",themeColor:"primary"}],open:function(e){e.sender.element.removeClass("k-popup"),r.editable.element.focus()},close:function(n){if(n.sender.element.trigger("focus"),r._preventOnCloseEditableChanges||!r.trigger("cancel",{container:M,model:t})){var i=r.items().index(e(r.current()).parent());r._preventOnCloseEditableChanges||(r._editableIsClosing=!0,r.cancelRow(!1,!0)),r.options.navigatable&&(r._isStackedMode()?r._setCurrentStackedCell():(r._setCurrent(r.items().eq(i).children().filter(I).first()),Ri(r.table,!0))),r._toggleToolbarEditingItemsVisibility()}else n.preventDefault()}}):e(o).appendTo(r.wrapper).eq(0).kendoWindow(f({modal:!0,resizable:!1,draggable:!0,title:r.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"),r.trigger("cancel",{container:M,model:t}))return void n.preventDefault();var i=r.items().index(e(r.current()).parent());r._editableIsClosing=!0,r.cancelRow(),r._toggleToolbarEditingItemsVisibility(),r._isStackedMode()?r._setCurrentStackedCell():(r._setCurrent(r.items().eq(i).children().filter(I).first()),Ri(r.table,!0))}}},C))}x||r._isMobile?(r.editable=r._editContainer.kendoEditable({fields:r._isMobile&&!x?r._editFields(_,t):null,model:t,clearContainer:!1,target:r,skipFocus:!0}).data("kendoEditable"),A&&r.editable.element.find(".k-edit-form-container").removeClass("k-edit-form-container")):(r.editable=new i.Form(r._editContainer.find(".k-edit-form-container"),{items:r._editFields(_,t),buttonsTemplate:()=>"",formData:t,size:r._isAdaptive()?"large":"medium"}).editable,r._editContainer.append(undefined),A&&r.editable.element.removeClass("k-edit-form-container")),r._openPopUpEditor(A),r.trigger(V,{container:M,model:t})}},_openPopUpEditor:function(e){var t=this;const n=e?"kendoActionSheet":"kendoWindow";var i=t._editContainer?t._editContainer.data(n):null;var r=(t.options.editable||{}).window||{};this._isMobile?this.pane.navigate(this.editView,this._editAnimation):i&&(e||r.position?e&&i.fullscreen(t.smallMQL.mediaQueryList.matches):i.center(),i.open())},_createInlineEditor:function(t,i){var r=this;var o;var a;var s;var l=[];const c=r._isStackedMode();if(r.trigger(N,{model:i}))return;r.lockedContent&&(t=t.add(r._relatedRow(t)));let d=c?t.children(":not(.k-group-cell,.k-hierarchy-cell)").find(".k-grid-stack-cell:not(.k-drag-cell)"):t.children(":not(.k-group-cell,.k-hierarchy-cell,.k-drag-cell)");const h=pi(c?Pn(r.columns):r.columns);r.options.navigatable&&c&&function(e){e.removeAttr(it)}(d),d.each((function(){if(a=e(this),o=h[r._calculateColumnIndex(a)])if(!o.command&&Vi(o,i)){l.push(vi(o,r._isAdaptive()?"auto":"none"));let e=c?a.children(".k-grid-stack-content"):a;e.attr(n.attr("container-for"),o.field),e.empty()}else if(o.command){var t,d,u,f,m;if(s=Hi(o.command,"edit"))a.empty(),p(s)&&(p(s.text)&&(t=s.text.update,d=s.text.cancel),p(s.iconClass)&&(u=s.iconClass.update,f=s.iconClass.cancel),s.attr&&(m=s.attr)),e(r._createButton({name:"update",text:t,attr:m,iconClass:u,skipTabIndex:!0})+r._createButton({name:"canceledit",text:d,attr:m,iconClass:f,skipTabIndex:!0})).appendTo(a)}})),r._editContainer=t,r._editContainer.addClass("k-grid-edit-row"),!0===i.new&&(r._editContainer.addClass("k-grid-add-row"),delete i.new),r._shouldClearEditableState&&r._clearEditableState(),r.editable=new n.ui.Editable(r._editContainer,{target:r,fields:l,size:r.options.size,model:i,skipFocus:r._isVirtualInlineEditable()&&r._editableState&&!!r._editableState.field||r._hasVirtualColumns(),clearContainer:!1}),t.length>1&&(Bi(t[0],t[1]),r._applyLockedContainersWidth(!0)),c&&d.addClass("k-grid-stack-edit-cell"),r.trigger(V,{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=this;var n=this._editContainer;var i=this._modelForContainer(n);var r=e.Deferred();var o;return n&&this.editable?!(o=t.editable&&t.editable.end())||this.trigger($,{container:n,model:i})?(o||t._scrollVirtualWrapper(),r.reject().promise()):(t._clearEditableState(),this.dataSource.sync()):r.resolve().promise()},_displayRow:function(t){var r,o,a,s=this,l=s._modelForContainer(t),c=t.hasClass(be),d=t.hasClass("k-table-alt-row");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(ut,r.content.css(ut)),r.content.css(ut,"hidden"))},close:function(){r.content&&r.content.css(ut,r.content.data(ut))}})).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===ot?t.options.messages.editable.confirmation:n.confirmation;return p(n)&&typeof n.mode===ot&&typeof i!==rt&&typeof i!==ot&&!1!==i&&(i=t.options.messages.editable.confirmation),!1===i||null==i||(typeof i===rt&&(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;var t=e.editable&&e.editable.end();!t&&e.editable||e.trigger(ee)?t||e._scrollVirtualWrapper():e.dataSource.sync()},addRow:function(){var e,t=this,n=t.dataSource,i=t._editMode(),r=t.options.editable.createAt||"",o=n.pageSize(),a=n.view()||[];var s=r.toLowerCase()===at;var l;var c=t._isVirtualEditable();t.editable&&t.editable.end()||!t.editable?("incell"!=i&&t.cancelRow(),e=n.indexOf(a[0]),s&&(e+=a.length,o&&!n.options.serverPaging&&o<=a.length&&(e-=1)),e<0&&(e=n.page()>n.totalPages()?(n.page()-1)*o:0),t.options.navigatable&&"incell"==i&&t._removeCurrent(),c?t._virtualAddRow():((l=n.insert(e,{})).new=!0,t._editModel(l))):t._scrollVirtualWrapper()},_editModel:function(e){var t=this;var i=t.options.editable.createAt||"";var r=t._editMode();if(e){var o=e.uid,a=(t.lockedContent?t.lockedTable:t.table).find("tr["+n.attr("uid")+"="+o+"]");const s=t._isStackedMode()?a.find("td:not(.k-group-cell,.k-hierarchy-cell) .k-grid-stack-cell:not(.k-drag-cell):not(.k-command-cell)"):a.children("td:not(.k-group-cell,.k-hierarchy-cell,.k-drag-cell)");const l=t._firstEditableColumnIndex(a);const c=s.eq(l);"inline"===r&&a.length?t.editRow(a):"popup"===r?t.editRow(e):c.length&&t.editCell(c,l),"bottom"==i.toLowerCase()&&t.lockedContent&&(t.lockedContent[0].scrollTop=t.content[0].scrollTop=t.table[0].offsetHeight)}},_virtualAddRow:function(){var e=this;var t=(e.options.editable.createAt||"").toLowerCase()===at;e._clearEditableState(),t?e._virtualAddRowAtBottom():e._virtualAddRowAtTop()},_virtualAddRowAtTop:function(){var e=this;var t=e.dataSource;var n=e.virtualScrollable;var i;1===t.page()?((i=t.insert(0,{})).new=!0,e._editModel(i),n.scrollToTop()):e._virtualPageToTop((function(){(i=t.insert(0,{})).new=!0,e._editModel(i),n.scrollToTop()}))},_virtualAddRowAtBottom:function(){var e=this;var t=e.dataSource;var n=e.virtualScrollable;var i=t.total();var r;t.at(i-1)instanceof o?((r=t.insert(i,{})).new=!0,e._virtualPageToBottom((function(){e._editModel(r),n.scrollToBottom()}))):e._virtualPageToBottom((function(){(r=t.insert(i,{})).new=!0,e._editModel(r),n.scrollToBottom()}))},_virtualPageToTop:function(e){this._virtualPage(0,this.dataSource.take(),(function(){e()}))},_virtualPageToBottom:function(e){var t=this.dataSource;var n=t.take();var i=t.total();var 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=pi(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(),this._toggleToolbarEditingItemsVisibility()},_clickCancel:function(e){e.preventDefault&&e.preventDefault(),this.cancelChanges(),this._toggleToolbarEditingItemsVisibility()},_clickExcel:function(t){var n=this;var 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})):(t._progress(!1),t._isExport=!1,t._pdfInitialized=!1)},_clickSave:function(e){e.preventDefault&&e.preventDefault(),this.saveChanges(),this.one(te,(()=>{this._toggleToolbarEditingItemsVisibility()}))},_searchInput:function(e){var t=this,n=e.currentTarget;clearTimeout(t._searchTimeOut),t._searchTimeOut=setTimeout((function(){t._searchTimeOut=null;var e=t.options;var i=e.search?e.search.fields:null;var r={filters:[],logic:"or"};var o=n.value;if(i||(i=fi(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],h=d&&d.parse,u={field:s,operator:l||a.string,value:i};(l||o)&&d&&n.isFunction(h)&&null!==h(i)&&f(u,{operator:l||a[d.type],value:h(i)}),o&&d&&n.isFunction(h)&&null===h(i)||e.push(u)},_hasTool:function(e){const t=this.wrapper.find(`.k-grid-toolbar ${e}`);return{present:t.length>0,tool:t}},_initToolbarItemsPopups:function(){const e=this;const t=e._hasTool(".k-toolbar-button.k-grid-column-menu[ref-toolbar-tool]");const n=e._hasTool(".k-toolbar-button.k-grid-sort-tool[ref-toolbar-tool]");const i=e._hasTool(".k-toolbar-button.k-grid-filter-tool[ref-toolbar-tool]");const r=e._hasTool(".k-toolbar-button.k-grid-column-chooser[ref-toolbar-tool]");const o=e._hasTool(".k-toolbar-button.k-grid-group-tool[ref-toolbar-tool]");if(t.present&&e._globalColumnsMenu(t.tool),r.present&&e._columnChooserTool(r.tool),n.present&&(e._toggleBadge(n.tool,e.dataSource.sort()),e._sortToolbarTool(n.tool)),i.present&&(e._toggleBadge(i.tool,e.dataSource.filter()),e._filterToolbarTool(i.tool)),o.present){const t=e.dataSource.group();e._toggleBadge(o.tool,t&&t.length),e._groupToolbarTool(o.tool)}},_unbindToolbarTools:function(){this.wrapper.find("\n .k-toolbar-button.k-grid-column-menu[ref-toolbar-tool],\n .k-toolbar-button.k-grid-sort-tool[ref-toolbar-tool],\n .k-toolbar-button.k-grid-filter-tool[ref-toolbar-tool],\n .k-toolbar-button.k-grid-column-chooser[ref-toolbar-tool],\n .k-toolbar-button.k-grid-group-tool[ref-toolbar-tool],\n .k-toolbar-button.k-grid-ai-assistant-tool[ref-toolbar-tool]\n ").each((function(){e(this).off("click"+O)}))},_ai:function(){const e=this;const t=e._hasTool(".k-toolbar-button.k-grid-ai-assistant-tool[ref-toolbar-tool]");t.present&&e._initAiAssistantWindow(t.tool)},_toolbar:function(){var t,i,r=this,o=r.wrapper,a=r.options.toolbar;if(a){if(r._createClickHandler=r._addClickHandler=r._clickAdd.bind(r),r._editClickHandler=r._editToolbarClick.bind(r),r._destroyClickHandler=r._removeToolbarClick.bind(r),r._editCancelClickHandler=r._editCancelClick.bind(r),r._updateClickHandler=r._editUpdateClick.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===ot||w(a)?(typeof a===ot&&(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})):p(a)&&t.kendoToolBar({navigateOnTab:!r.options.navigatable,size:r.options.size,items:r._processItems(a.items||[]),overflow:a.overflow})),r._checkBoxSelection&&t.on(Ge+O,".k-select-checkbox",r._headerCheckboxClick.bind(r)),t.on(ct+O,".k-grid-search input",this._serachHandler),a.overflow&&"section"===a.overflow.mode){const e=t.data("kendoToolBar");e.bind("overflowOpen",(function(){const t=e.overflowSection.element.find(".k-toolbar-items-list");r._toggleToolbarEditingItemsVisibility(t?.children(rn))}))}r._toggleToolbarEditingItemsVisibility()}},_toggleToolbarEditingItemsVisibility:function(t){const i=this;const r=i.dataSource.hasChanges();const o=i.wrapper.find(".k-grid-toolbar");if(!o.length)return;let a;a=i.options.toolbar&&i.options.toolbar.overflow&&"scroll"===i.options.toolbar.overflow.mode?o.find(".k-toolbar-items").children(rn):t||o.children(rn);const s=i.options.toolbar&&i.options.toolbar.showInactiveTools||!1;const l=i._editMode();const c=i._editContainer&&i._editContainer.length>0&&i._editContainer.is(":visible");const d=s?e=>{e.attr("aria-disabled",!0),e.addClass("k-disabled")}:e=>e.hide();const h=i.select();const u=h.length>0;const p=u&&i._editContainer&&i._editContainer.length>0&&i._editContainer.is(":visible")&&i._editContainer[0].getAttribute(n.attr("uid"))!==h[h.length-1].getAttribute(n.attr("uid"));const f=function({mode:e,hasSelected:t,hasChanges:n,editContainerVisible:i,differentSelectionThanEditing:r,_editableIsClosing:o,_isEditableEnabled:a,options:s}){const l=/\b(k-grid-edit-command|k-grid-remove-command|k-grid-save-changes|k-grid-cancel-changes|k-grid-cancel-command|k-grid-save-command)\b/;const c=[];if(!a||!s.editable)return l;t||(c.push("k-grid-edit-command"),c.push("k-grid-remove-command")),t&&("incell"===e||"inline"===e&&!r)&&c.push("k-grid-edit-command"),n||(c.push("k-grid-save-changes"),c.push("k-grid-cancel-changes")),("inline"!==e||!i||i&&o)&&(c.push("k-grid-save-command"),c.push("k-grid-cancel-command"));let d="";return c.length?(d=c.join("|"),d=`\\b(${d})\\b`,new RegExp(d)):d}({mode:l,hasSelected:u,hasChanges:r,editContainerVisible:c,differentSelectionThanEditing:!p&&!1!==p||p,_editableIsClosing:i._editableIsClosing||!1,_isEditableEnabled:i._isEditableEnabled||!1,options:i.options});a.show().removeClass("k-disabled").attr("aria-disabled","false"),a.each((function(){const t=e(this);const n=t.attr("class");t.hasClass(pe)&&(t.removeClass(pe),Ri(i.table,!0)),n&&f&&f.test(n)&&d(t)}))},_attachToolbarClicks:function(){var e=this.options.editable,t=this.wrapper.find(".k-grid-toolbar");e&&!1!==e.create&&t.on(Ge+O,".k-grid-add",this._createClickHandler).on(Ge+O,".k-grid-cancel-changes",this._cancelClickHandler).on(Ge+O,".k-grid-save-changes",this._saveClickHandler),e&&!1!==e.update&&t.on(Ge+O,".k-grid-edit-command",this._editClickHandler).on(Ge+O,".k-grid-save-command",this._updateClickHandler).on(Ge+O,".k-grid-cancel-command",this._editCancelClickHandler),!1!==e.destroy&&t.on(Ge+O,".k-grid-remove-command",this._destroyClickHandler),t.on(Ge+O,".k-grid-excel",this._excelClickHandler),t.on(Ge+O,".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,h,u="";if("string"==typeof e)l=e.toLowerCase(),e={},"aiassistant"!==l&&(e.text=a[l]||l);else{l=e.name||e.text||"",fn[l.toLowerCase()]&&(l=l.toLowerCase()),"aiassistant"!==l&&(e.text=""===e.text?"":e.text||a[l]||l)}if(s||"search"!==l&&"columns"!==l||(s=!0,o.push({type:"spacer"})),"selectall"===l.toLowerCase()){const t=e.text;e.template=e.template||n.template(Ut)({size:n.getValidCssClass("k-checkbox-","size",i.options.size),label:t})}if("search"===l)c=Yi(e.text||a.search,!0),d=e.icon||e.iconClass||"search",u+=`<span class='k-searchbox k-input ${n.getValidCssClass("k-input-","size",i.options.size)} k-rounded-md k-input-solid k-grid-search'>`,u+=n.ui.icon({icon:d,iconClass:"k-input-icon"}),u+="<input autocomplete='off' placeholder='"+c+"' title='"+c+"' aria-label='"+c+"' class='k-input-inner' />",u+="</span>",o.push({name:"search",overflow:"never",template:u});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");h=(e=f({type:"button"},fn[l],e)).className||"k-grid-"+(l||"").replace(/\s/g,""),e.attributes=i._processAttr(e.attr),delete e.attr,h&&(e.attributes.class===t&&(e.attributes.class=""),e.attributes.class+=" "+h),e.template&&delete e.type,i["_"+l+"ClickHandler"]&&(e.click=i["_"+l+"ClickHandler"]),"canceledit"===l&&(e.click=i._editCancelClickHandler),o.push(e)}})),o},_processAttr:function(e){var t={};return typeof e===ot&&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||Vt,s=typeof i===ot?i:i.name||i.text,l=fn[s]?fn[s].className:"k-grid-"+(s||"").replace(/\s/g,""),c={className:i.skipCommandClass?"":l,text:s,attr:i.skipTabIndex?"":"tabindex=-1",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=un(i.attr)),i.attr instanceof Function){let e=i.attr(i);i.attr=un(e)}typeof i.attr===ot&&(o=i.attr.match(/class="(.+?)"/))&&_(o[1],i.className.split(" "))<0&&(i.className+=" "+o[1])}const e={text:d[s]};"edit"!==s&&"update"!==s||(e.themeColor="primary"),"destroy"===s&&(e.iconClass="k-i-x"),c=f(!0,c,fn[s],e,i)}else{const e={text:d[s]};"edit"!==s&&"update"!==s||(e.themeColor="primary"),"destroy"===s&&(e.iconClass="k-i-x"),c=f(!0,c,fn[s],e)}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(Ge+O,t._groupableClickHandler):t._groupableClickHandler=function(n){var i=e(this),r=i.closest(bt);var o=t._groupRows?t._groupRows[t.wrapper.find(S+He).index(r)]:{};i.is(B)?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(Ge+O,".k-grouping-row "+H+", .k-grouping-row "+B,t._groupableClickHandler):t.table.on(Ge+O,".k-grouping-row "+H+", .k-grouping-row "+B,t._groupableClickHandler),t._attachGroupable()},_toggleGroupableHeader:function(e){const t=this.options.groupable;const n=this.wrapper.find("div.k-grouping-header");t&&!1!==t.enabled&&n.length&&(e?n.removeClass("k-hidden"):n.addClass("k-hidden"))},_attachGroupable:function(){var t=this,r=t.wrapper,o=t.options.groupable,a=L+"["+n.attr("field")+"]",s=t.content?".k-grid-header:first "+a:"table:first>.k-grid-header "+a;const l=t._isStackedMode();if(l&&(s=".k-grid-stack-cell[data-field]"),o&&!1!==o.enabled){r.has("div.k-grouping-header")[0]||e("<div/>").addClass("k-grouping-header").prependTo(r),t.groupable&&t._destroyGroupable(),Gt.chrome&&(r.find("div.k-grouping-header").css("touch-action",It),r.find(s).css("touch-action",It));let n=t.wrapper.children(".k-grid-header");n.addClass("k-grid-draggable-header"),n.attr("draggable",!0),t.groupable=new i.Groupable(r,f({},o,{draggable:!l&&t._draggableInstance,groupContainer:">div.k-grouping-header",dataSource:t.dataSource,draggableElements:!l&&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())},_groupableFieldsData:l&&t.columns})),l&&t._toggleGroupableHeader(t.dataSource.group().length>0),t._addGroupableOptionsToHeader()}},_showUngroupedColumn:function(e){var t=pi(this.columns);var n;for(n=0;n<t.length;n++)t[n].uid==e.colID&&t[n].hideOnGroup&&this.showColumn(t[n])},_hideGroupedColumns:function(e){if(e){var t=pi(this.columns);var n=[];var i;for(i=0;i<e.length;i++)e[i].colID&&n.push(e[i].colID);for(i=0;i<t.length;i++)n.indexOf(t[i].uid)>=0&&t[i].hideOnGroup&&this.hideColumn(t[i])}},_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=Kn(this.columns);var t={};var i=this._headerCells();var r;var o;var a;for(a=0;a<e.length;a++)e[a].field,t[e[a].field]=e[a];for(a=0;a<i.length;a++)(o=t[(r=i.eq(a)).attr(n.attr(lt))])&&o.groupable&&o.groupable.sort&&r.data(ft,o.groupable.sort)},_destroyGroupable:function(){var e=this;e.groupable&&e.groupable.element&&e.groupable.element.kendoGroupable("destroy"),e.groupable=null,e._removeGroupableOptionsFromHeader()},_removeGroupableOptionsFromHeader:function(){var e=this._headerCells();for(var t=0;t<e.length;t++)e.eq(t).removeData(ft)},_continuousItems:function(t,n){if(this.lockedContent){var i=this;var r=i.table.add(i.lockedTable);var o=e(t,r[0]);var a=e(t,r[1]);var s=n?ri(pi(i.columns)).length:1;var l=n?pi(i.columns).length-s:1;var c=[];for(var 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));const u=r._isStackedMode()?"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) div.k-grid-stack-cell":"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)";var d=">"+(i?u:"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(Q,{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(),"incell"!==r._editMode()&&r._toggleToolbarEditingItemsVisibility(),e.event&&r.trigger(X,{cellAggregates:r._cellAggregates})},useAllItems:a&&t&&i,relatedTarget:function(t){if(!i&&a){var n;var o=e();for(var 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"+O,(function(n){var o=r.current();var s=n.target;var l={event:n};var d;var u;if(o)if(n.keyCode===h.SPACEBAR&&!n.shiftKey&&e.inArray(s,c)>-1&&!o.is(".k-grid-stack-edit-cell,.k-edit-cell,.k-header")&&o.parent().is(":not(.k-grouping-row,.k-detail-row,.k-group-footer)")){if(n.preventDefault(),n.stopPropagation(),((d=!(o=i?o:o.parent()).hasClass(be)||r.selectable.value().length>1)||t&&o.hasClass(be)&&n.ctrlKey)&&r.trigger(Q,{target:o,originalEvent:n}))return;if(a&&!i&&(o=o.add(r._relatedRow(o))),t)if(n.ctrlKey){if(o.hasClass(be))return r._deselectCheckRows(o),r._calculateAggregatesForSelected(),void r.trigger(X,{cellAggregates:r._cellAggregates})}else r.selectable.clear();else r.selectable.clear();i||(r.selectable._lastActive=o),r.selectable.value(o),d&&(r._calculateAggregatesForSelected(),r.trigger(X,{cellAggregates:r._cellAggregates}))}else if(!i&&(e(s).is("td")||e(s).is("table")&&_(s,this._navigatableTables))&&(n.shiftKey&&n.keyCode==h.LEFT||n.shiftKey&&n.keyCode==h.RIGHT||n.shiftKey&&n.keyCode==h.UP||n.shiftKey&&n.keyCode==h.DOWN||n.keyCode===h.SPACEBAR&&n.shiftKey)){if(n.preventDefault(),n.stopPropagation(),o=o.parent(),r.trigger(Q,{target:o,originalEvent:n}))return;u=r.selectable.value(),a&&(o=o.add(r._relatedRow(o))),t?(r.selectable._lastActive||(r.selectable._lastActive=o),r.selectable.selectRange(r.selectable._firstSelectee(),o),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}(u,r.selectable.value())||r.trigger(X,l)):o.hasClass(be)||(r.selectable.clear(),r.selectable.value(o),r._calculateAggregatesForSelected(),r.trigger(X,{cellAggregates:r._cellAggregates}))}}))}},_pasteReplaceHandler:function(t){var n,i,r,o,a,s=this,l=[];i=s.select().first(),!s._isStackedMode()&&i.length&&(i.is(bt)&&(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(bt)&&(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,h=t||!1,u=c._getSelectedRowUids(),p=c._getSelectedColumnFields(),f=[],m=ci(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&&h)for(let t=0;t<u.length;t++){const n=u[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=h?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(se,{items:f,type:h?"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-grid-stack-edit-cell input:visible,.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(bt).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(se+O,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(it,0),t.table.add(t.lockedTable).on(Ke+O+" keydown"+O,".k-detail-cell",(function(e){e.target!==e.currentTarget&&e.stopImmediatePropagation()})).on(Ke+O,E+">"+I,$i.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;var r=i.select();var o="\t";var a=i.options.allowCopy;var s=i._isLocked()&&ri(i.columns).length;e.isPlainObject(a)&&a.delimeter&&(o=a.delimeter);var l="";if(r.length){r.eq(0).is(bt)&&(r=r.find("td:not(.k-group-cell)")),r.filter(":visible");var c=[];var d=this.columns.length;var h=i._isLocked()&&ri(i.columns).length;var u=!0;var p=[];var f;var m=ci(this.columns);e.each(r,(function(t,n){if(n=e(n),f=i._getCellField(n,s),-1!==m.findIndex((e=>e.field===f))){var r=n.closest(bt).index();var o=n.index();o-=n.prevAll(":hidden").length,h&&u&&(u=e.contains(i.lockedTable[0],n[0])),i._groups()&&u&&(o-=i._groups()),o=u?o:o+h,f&&(p[o]=f),d>o&&(d=o);var a=n.text();c[r]||(c[r]=[]),c[r][o]=a}}));var g=c.length;if(c=e.each(c,(function(e,t){t&&(c[e]=t.slice(d),g>e&&(g=e))})),n&&p.length){c.splice(g,0,p.map((function(e){return function(e,t){return t.filter((function(t){return t.field===e}))[0].title||e}(e,m)})));var v=c.findIndex((function(e){return e!==t}));c[v]=c[v].slice(d)}e.each(c.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]&&Ri(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 Ln(this.columns)},_attachColumnMediaResizeHandler:function(){var t=this;t._detachColumnMediaResizeHandler(),t._columnMediaResizeHandler=t._onColumnMediaResize.bind(t),e(window).on(Re+O,t._columnMediaResizeHandler)},_detachColumnMediaResizeHandler:function(){this._columnMediaResizeHandler&&e(window).off(Re+O,this._columnMediaResizeHandler)},_onColumnMediaResize:function(){var e=this;e._setColumnsMediaVisibility(e.columns),e._setContentMediaWidth()},_setColumnsMediaVisibility:function(e){var t=e||[];for(var n=0;n<t.length;n++)this._setColumnMediaVisibility(t[n])},_setColumnMediaVisibility:function(e){var t=this;Bn(e.media)?t._setColumnsMediaVisibility(e.columns):Dn(e)?(t._showColumnByMedia(e),e.hidden||t._setColumnsMediaVisibility(e.columns)):t._hideColumnByMedia(e)},_showColumnByMedia:function(e){e.hidden||this.showColumn(e),An(e)},_hideColumnByMedia:function(e){var t=e.hidden;t||(e._hideByMedia=!0,this.hideColumn(e),e._hideByMedia=!1,e.hidden=t),An(e)},_setContentMediaWidth:function(){var t=this;var n=t.options;var i=t._isLocked();var r;if(n.scrollable&&(!0===n.resizable||n.resizable&&!0===n.resizable.columns)){i&&t.lockedFooter?r=t.lockedFooter.children("table"):t.footer&&(r=t.footer.find(">.k-grid-footer-wrap>table")),r&&r[0]||(r=e());var o=i?t.wrapper.find(".k-grid-header-locked").find("table"):t.wrapper.find(".k-grid-header").find("table");var a=i?t.lockedTable:t.table;var s=o.find("th");var l=o.find("colgroup");var d=s.length;var h=s.filter(En).length;var u=s.length-h;var p=0;if(""!==o[0].style.width&&parseFloat(o[0].style.width)!==p){var f=o.css(tt);for(var m=0;m<d;m++)if(In(s[m])){var g;var v=Math.max(m,m-u);var _=l.children()[v];var b=_?_.style.width:"";""!==b?g=parseFloat(b):(o.css(tt,nt),g=c(s.eq(m)),o.css(tt,f)),p+=g}a.css("width",p-1),o.css("width",p),r.css("width",p),t._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){var i=!1;for(var r=0;r<e.length;r++){var o=e[r];var 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;var t=g(pi(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);var n=t.data("column");n.sticky?(p(n.stickyStyle)&&t.css({left:n.stickyStyle.left||"",right:n.stickyStyle.right||""}),t.addClass(ze)):(t.css({left:"",right:""}),t.removeClass(ze))}))},_anyStickyColumns:function(){return!this._isStackedMode()&&ai(this.columns).length},_setStickyColumns:function(e){var t=this;var n=ai(t.columns);var i=function(e){return g(e,(function(e){return e.sticky&&!e.locked&&zn(e)}))}(t.columns);var 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;var r;var o;var a;var s=qt?"right":"left";var l=qt?"left":"right";var 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;var i;for(n=0;n<e.length;n++)(i=e[n]).columns&&(!t&&n&&(t=n),this._setStickyClassAttributes(hi([i]),t)),t&&ni(i,"headerAttributes","class",Le),ni(i,"attributes","class",Ie),ni(i,"headerAttributes","class",ze),ni(i,"footerAttributes","class",Pe)},_setStickyStyleAttributes:function(e,t,i){var r=this;var o;var a;var s;var l;var c;var d;var h;for(o=0;o<e.length;o++)a=e[o],c={left:(s=t.left[o])+"px",right:(l=t.right[o])+"px"},a.columns&&(d=ui([a]),h=r._calculateStickyWidths(d,s,l),r._setStickyStyleAttributes(d,h,i),i&&r._setStickyStyles(d,h)),ni(a,"attributes",n.attr("style-left"),c.left),ni(a,"attributes",n.attr("style-right"),c.right),ni(a,"headerAttributes",n.attr("style-left"),c.left),ni(a,"headerAttributes",n.attr("style-right"),c.right),ni(a,"footerAttributes",n.attr("style-left"),c.left),ni(a,"footerAttributes",n.attr("style-right"),c.right),a.stickyStyle=c},_removeStickyAttributes:function(e){var t;var i=new RegExp("(\\s*"+Ie+")*","ig");var r=new RegExp("(\\s*"+ze+")*","ig");var o=new RegExp("(\\s*"+Pe+")*","ig");var a=new RegExp("(\\s*"+Le+")*","ig");var s;for(t=0;t<e.length;t++)(s=e[t]).columns&&this._removeStickyAttributes(hi([s])),ii(s,"attributes","class",i),ii(s,"attributes",n.attr("style-left"),"",!0),ii(s,"attributes",n.attr("style-right"),"",!0),ii(s,"headerAttributes","class",r),ii(s,"headerAttributes","class",a),ii(s,"headerAttributes",n.attr("style-left"),"",!0),ii(s,"headerAttributes",n.attr("style-right"),"",!0),ii(s,"footerAttributes","class",o),ii(s,"footerAttributes",n.attr("style-left"),"",!0),ii(s,"footerAttributes",n.attr("style-right"),"",!0)},_setStickyStyles:function(t,n){var i=this;var r;var o;var a=pi(oi(i.columns));var s=i.tbody.children(":not(.k-detail-row)");var l;var c;var d;var h;var u;var p;var f;var m;var g;for(r=0;r<t.length;r++)if(c=t[r],h=n.left[r],u=n.right[r],d=a.indexOf(c),(p=i._getColumnHeader(c)).addClass(ze),c.headerAttributes.class&&-1!==c.headerAttributes.class.indexOf(Le)&&p.addClass(Le),ei(p,h,u),!c.columns)for(i.footer&&((f=i.footer.find(".k-grid-footer-wrap tr.k-footer-template").children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(d)).addClass(Pe),ei(f,h,u)),o=0;o<s.length;o++)(l=e(s[o])).hasClass(He)?((m=l.find("."+c.groupHeaderColumnTemplateClass)).addClass(Ie),ei(m,h,u)):((g=l.children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(d)).addClass(Ie),ei(g,h,u))},_removeStickyStyles:function(t){var n=this;var i;var r;var o=pi(oi(n.columns));var a=n.tbody.children(":not(.k-detail-row)");var s;var l;var c;var d;var h;var u;var p;for(i=0;i<t.length;i++)if(l=t[i],c=o.indexOf(l),(d=n._getColumnHeader(l)).removeClass(ze),d.removeClass(Le),ei(d,"",""),l.columns)n._removeStickyStyles(l.columns);else for(l.footerTemplate&&n.footer&&((h=n.footer.find(".k-grid-footer-wrap tr.k-footer-template").children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(c)).removeClass(Pe),ei(h,"","")),r=0;r<a.length;r++)(s=e(a[r])).hasClass(He)?((u=s.find("."+l.groupHeaderColumnTemplateClass)).removeClass(Ie),ei(u,"","")):((p=s.children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(c)).removeClass(Ie),ei(p,"",""))},_getColumnHeader:function(t){return e("#"+t.headerAttributes.id).length?e("#"+t.headerAttributes.id):e("#"+this._cellId)},_sumColumnWidth:function(e){return e.columns?this._sumCurrentWidths(pi([e])):this._sumCurrentWidths([e])},_sumCurrentWidths:function(e){var t=0;var n=0;var i;var r;var o;var a=e.length;for(o=0;o<a;o++)i=e[o],r=this._getColumnHeader(i),!i.hidden&&Dn(i)&&(t+=(n=r.is(":visible")?r.outerWidth():i.width)?parseInt(n,10):0);return t},_belongsToGrid:function(e){return this.wrapper[0]===e.closest(".k-grid")[0]},getSelectedData:function(){var e=this;var t=e.selectable.selectedRanges();var n=Object.keys(t);var i=e.selectable.selectedSingleItems();var r=[];var o=ci(e.columns);for(var 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=ci(i.columns),s={};var 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=this;var i=this.options.excel||{};var r=ci(t.columns);var o=new n.excel.ExcelExporter({});var a={sheets:[{columns:Array.apply(0,Array(r.length)).map((function(){return{autoWidth:!0}})),rows:[],freezePane:{},filter:!1}]};var s=t.selectable.selectedRanges();var l=Object.keys(s);var c=t.selectable.selectedSingleItems();var d;var h=[];var u=t._isLocked()&&ri(t.columns).length;var p=Qi.bind(t);for(d=0;d<l.length;d++)h=h.concat(t._mapSelectionToData(s[l[d]],r,Xi));if(h.length&&t._addRangeSelectionRows(a,o,h,e),(h=c.length?t._mapSelectionToData(c,r,Xi):[]).length&&(u&&(h=h.sort(p)),t._addSingleSelectionRows(a,o,h,e)),a.sheets[0].rows.length){var f=new n.ooxml.Workbook(a);f.options||(f.options={}),f.options.skipCustomHeight=!0,f.toDataURLAsync().then((function(e){n.saveAs({dataURI:e,fileName:a.fileName||i.fileName,proxyURL:i.proxyURL,forceProxy:i.forceProxy})}))}},_addSingleSelectionRows:function(e,t,n,i){var r=0;var o=di(this.columns);var a;const s=t._instance??t;for(r=0;r<n.length;r++)a=n[r],t.data=[a],this._setExporterColumns(s,o,a),this._createExportRows(e,s,i)},_addRangeSelectionRows:function(e,t,n,i){var r=di(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){var o=this;var a="TR"===t[0][0].nodeName;var s;var l={};var c;var d;var h;var u=function(e){var t={};if(e.field&&(!i||i(e)))return t[e.field]=s[e.field],t};var p=o._isLocked()&&ri(o.columns).length;var f;for(var m=0;m<t.length;m++)if(c=t[m],s=o.dataItem(a?c:c.closest(bt)),a)l[s.uid]=e.extend.apply({},n.map(u));else{if(!(h=o._getCellField(c,p,r)))continue;if((d=l[s.uid])||(d=l[s.uid]={}),!(f=Rn(n,h))||i&&!i(f))continue;d[h]=s[h]}return Object.keys(l).map((function(e){return l[e].uid=e,l[e]}))},_getCellField:function(t,i,r){const o=this;const a=i&&e.contains(o.lockedTable[0],t[0]);const s=n.attr("field");const l=n.attr("index");const c=a?0:i;let d=0;return r&&(d=o._trailingColumns()),o._isStackedMode()?o.table.find("div.k-grid-stack-cell["+l+"='"+(t.index()-d)+"']").attr(s):i?o.element.find(".k-grid-header-"+(a?"locked":"wrap")+" th["+l+"='"+(t.index()+c)+"']").attr(s):o.thead&&o.thead.find("th["+l+"='"+(t.index()-d)+"']").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));var 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));var 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={}},clearHighlight:function(){const e=this;e._highlightDescriptors&&delete e._highlightDescriptors,e._highlightedItems&&e._highlightedItems.length&&(e._highlightedItems.removeClass(fe),delete e._highlightedItems),e._hasAIHighlight&&delete e._hasAIHighlight},_getElementsToHightlight:function(e){const t=this;const n=t.columns;const i=[];const r=[];const o=[];let a=e=>`tr[data-uid='${e}']`;const s=(e,t)=>e.length&&e.findIndex((e=>e.field===t));return g(n,(e=>{e.locked?i.push(e):r.push(e)})),Object.entries(e).forEach((([e,n])=>{if(!e)return;const l=t.dataSource.get(e);if(!l)return;let c=t.tbody.find(a(l.uid));!0===n?o.push(c):"object"==typeof n&&Object.keys(n).forEach((e=>{if(!e&&!n[e])return;let d=!1;let h=s(r,e);-1===h&&(h=s(i,e),d=!0),d&&(c=t._relatedRow(c));const u=c.find(`td:eq(${h})`);u.length&&(o.push(u),c=t.tbody.find(a(l.uid)))}))})),o},_restoreHighlight:function(){const e=this._highlightDescriptors;e&&Object.keys(e).length&&this.highlight(e)},_persistHighlight:function(e){const t=this;const n={};const i=e.is("tr");const r=t.options.dataSource?.schema?.model?.id||"id";const o=(i?e:e.closest("tr")).data("uid");const a=t.dataSource.getByUid(o);if(!a)return;const s=a[r];if(i)n[s]=!0;else{const i=t._getCellField(e,t._isLocked(),!0);if(!i)return;n[s]=i}t._highlightDescriptors?t._highlightDescriptors=t._mergeHighlightDescriptor(t._highlightDescriptors,n):t._highlightDescriptors=n},_mergeHighlightDescriptor:function(e,n){const i={};let r,o,a;for(r in e)i[r]=e[r];for(r in n)o=i[r],a=n[r],i[r]=o===t?a:!0===a||("object"==typeof a&&null!==a&&"object"==typeof o&&null!==o?f({},o,a):o);return i},highlight:function(t){const n=this;const i=n.lockedTable;const r=Array.isArray(t)&&!t.length;if(!t&&!r)return n._highlightedItems||e();if(r)return void n.clearHighlight();const o="object"==typeof t&&!Array.isArray(t)?Object.keys(t):[];const a=o.length&&n.dataSource.get(o[0]);let s;a?(n._highlightDescriptors=n._mergeHighlightDescriptor(n._highlightDescriptors||{},t),s=n._getElementsToHightlight(t)):s=Array.isArray(t)?t:[t];s.forEach((function(t){const r=(e=>{const t=e.is("tr");let r;if(e)return t&&i?.length&&(r=n._relatedRow(e),e=e.add(r)),e})(e(t));if(r&&!a&&n._persistHighlight(r),r?.length){if(n._highlightedItems&&-1!==n._highlightedItems.index(r))return;r.addClass(fe),n._highlightedItems?n._highlightedItems=n._highlightedItems.add(r):n._highlightedItems=r}}))},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("."+be)},_initSelectableAggregates:function(){var e=this;e.options.selectable&&(e._selectableAggregatesOptions||(e._selectableAggregatesOptions=e._parseSelectableAggregatesOptions()),e._selectableAggregatesOptions.count&&(e._cellAggregates={count:0}))},_calculateAggregatesForSelected:function(){var i,r,o,a,s,l,c,d,h,p,f,m=this,g=m.options,v=m.getSelectedDataByKeys(),_=m.options.selectable,b=_.cellAggregates,w=ci(m.columns).filter((e=>!e.selectable&&!e.draggable&!e.command)).length,y=fi(g.columns),k=n.ui.Selectable.parseOptions(_).cell,x=[],C=[],S=[];if(b){k&&(v=m.getSelectedData()),b=m._selectableAggregatesOptions;for(let e=0;e<v.length;e++){i=v[e];for(let e=0;e<y.length;e++)switch(r=i[y[e]],u(r)){case"number":x.push(r);break;case"date":C.push(r);break;case"boolean":S.push(r)}}var T;b.count&&(o=k?(T=m.select(),T.filter(((n,i)=>{const r=e(i);const o=r.children(".k-select-checkbox").length>0;const a=r.find("> .k-checkbox-wrap > .k-select-checkbox").length>0;return r.attr("[ref-grid-drag-cell]")===t&&!r.hasClass("k-command-cell")&&!o&&!a}))).length:v.length*w),x.length&&(s=b.max?x.reduce(((e,t)=>Math.max(e,t))):null,a=b.min?x.reduce(((e,t)=>Math.min(e,t))):null,l=b.sum?x.reduce(((e,t)=>e+t)):null,c=b.average?x.reduce(((e,t)=>e+t))/x.length:null),C.length&&(d=b.earliest?C.reduce(((e,t)=>new Date(Math.min(e,t)))):null,h=b.latest?C.reduce(((e,t)=>new Date(Math.max(e,t)))):null),S.length&&(p=b.isTrue?S.filter((e=>!0===e)).length:null,f=b.isFalse?S.filter((e=>!1===e)).length:null),m._cellAggregates={count:o,max:s,min:a,sum:l,average:c,earliest:d,latest:h,isTrue:p,isFalse:f},m.statusBar&&m._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){const t=this;const n=t._isStackedMode();const i=t.wrapper.find(".k-toolbar");const r=i.find(ye);let o=n?i:t.thead.add(t.lockedHeader);let a=n?ye:"tr "+ye;const s=(e,t)=>{if(e.length){const n=t?"Deselect all rows":"Select all rows";e.prop("checked",t).attr(At,t).attr(yt,n)}};if(n)s(r,e);else{s(o.find(a),e),s(r,e)}},_uncheckCheckBoxes:function(){this.table.add(this.lockedTable).find("tbody "+ye).attr(At,!1).prop("checked",!1).attr(yt,"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(be).removeAttr(r).find(ye).attr(At,!1).prop("checked",!1).attr(yt,"Select row")})),i._toggleHeaderCheckState(!1),i._persistSelectedRows()},_checkRows:function(t){t.each((function(){e(this).addClass(be).find(ye).prop("checked",!0).attr(yt,"Deselect row").attr(At,!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,i){var r=e(t).data("headerId");var o;var a;e(t).removeClass(pe),this.table.removeAttr(Dt),r?(r=r.replace(this._cellId,""),e(t).attr(vt,r)):e(t).removeAttr(vt),(o=n.attr(vt))!=this._cellId&&n.data("headerId",o),o?a=o:n.attr(vt,this._cellId),i||n.addClass(pe),this.table.attr(Dt,a||this._cellId),this._current=n},_scrollCurrent:function(){const t=this._current;const n=this.options.scrollable;if(t&&n){var i=t.parent();var r=i.closest("table").parent();var o=r.is(".k-grid-content-locked,.k-grid-header-locked");var a=r.is(".k-grid-content-locked,.k-grid-content,.k-virtual-scrollable-wrap");var 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;let 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(He)){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,h=r.wrapper.find(".k-grid-content.k-auto-scrollable"),u=n._outerHeight(r.tbody.find(`tr:not(.${He})`)),p=d&&d.virtual&&("rows"===d.virtual||!0===d.virtual);let f=o.groupable&&r.wrapper.find(`.${He}:first-child`);let m={};let g=!1;let v=0;if(r._scrolledItems&&(m=r._scrolledItems),p&&0===s.length&&(r.virtualScrollable._alwaysScrollTop=!0),!t||!c)return;const _=a.view();let b=_.find((e=>e[c]==t));if(s.length>0&&(b=r._findGroupedItem(_,t,c),v=n._outerHeight(f[0])),!b&&p)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=h.find(bt);const d=s[s.length-1].offsetTop;const p=o*(l/s.length*d)+(n-o*l-1)*u;return r._scrollingUp=r.virtualScrollable.verticalScrollbar.scrollTop()>p,r._scrollOffset=p,r.virtualScrollable._scrollTo(p),r.virtualScrollable.verticalScrollbar.trigger(le),r.virtualScrollable._programmaticallyScrolling.done((()=>{r.scrollToItem(t)}))}}));const w=b&&b.uid;if(!w)return;let y=e(`[data-uid=${w}]`);let{targetRow:k,rowsToTarget:x,hiddenGroupingRows:S}=r._findClosestGroupingRow(y[0]);if(!y||!k)return;s.length>0&&"none"===y.css("display")&&(y=k,g=!0);const T=g?S*v+u:0;let M=y[0].offsetTop-((x+s.length)*v-T);let A=M;if(p){if(m&&m[t]){const e=Math.floor(r.virtualScrollable.verticalScrollbar.scrollTop());const n=Math.floor(m[t].scrollingDownOffset);const i=Math.floor(m[t].scrollingUpOffset);if(e===i||e===n)return;r._scrollingUp=e>A,A=r._scrollingUp?i??A:n??A}r._scrollOffset&&(r._scrollingUp?(r._scrollOffset===M&&(r._scrollOffset+=u),A=M-r.virtualScrollable._scrollTop+r._scrollOffset):A+=r._scrollOffset),r.virtualScrollable._scrollTo(M,A),m[t]||(m[t]={}),r._scrollingUp?m[t]&&!m[t].scrollingUpOffset&&(m[t].scrollingUpOffset=A):m[t]&&!m[t].scrollingDownOffset&&(m[t].scrollingDownOffset=A)}else h.scrollTop(A);r.virtualScrollable&&(r._scrollOffset&&delete r._scrollOffset,r._scrollingUp&&delete r._scrollingUp),r._scrolledItems=m},current:function(e){return this._setCurrent(e,!0)},_setCurrent:function(t,n,i,r){var o=this._current;if(t=e(t),o&&t&&o.length&&t.length&&o.closest(".k-filter-row").length>0&&0===t.closest(".k-filter-row").length&&this._filterFocusable().attr(it,-1),t.length&&(!o||o[0]!==t[0])){var a=t.parent();var s=a.children(A);var l=parseInt(a.children().first().attr("colspan"),10);this._hasVirtualColumns()&&(this._virtualCellIndex=(l>1?l:0)+s.index(t)),this._updateCurrentAttr(o,t,r),i||this._scrollCurrent(),n||this.trigger(qe,{element:t})}return t&&t.length&&(this._lastCellIndex=t.parent().children(".k-group-cell, .k-grid-stack-content,"+D).index(t)),this._updateSelctCheckbox(o,t),this._current},_removeCurrent:function(){this._current&&(this._current.removeClass(pe),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&&Ri(this.table,!0))},_scrollTo:function(t,i){var r=t.tagName.toLowerCase();var o="td"===r||"th"===r;var a=e(t).closest("table")[0];var s=t[o?"offsetWidth":"offsetHeight"];var l=i[o?"scrollLeft":"scrollTop"];var c=i[o?"clientWidth":"clientHeight"];var d="relative"===e(t).css("position")&&qt&&o?Math.abs(a.offsetLeft-t.offsetLeft):t[o?"offsetLeft":"offsetTop"];var h=d+s;var u=0;var p=0;var f=0;qt&&o&&(Gt.msie||Gt.edge?p=a.offsetLeft:(Gt.mozilla||Gt.webkit&&Gt.version>85)&&(f=a.offsetLeft-n.support.scrollbar())),u=(l=Math.abs(l+p-f))>d?d:h>l+c?s<=c?h-c:d:l,u=Math.abs(u+p)+f,i[o?"scrollLeft":"scrollTop"]=u},_navigatable:function(){var t=this;if(!t.options.navigatable)return;const i=t._isStackedMode();var r=t.table.add(t.lockedTable);var o=!i&&t.thead.parent().add(e(">table",t.lockedHeader));var a=r;t.options.scrollable&&(a=a.add(o)),this._navigatableTables=a,o&&(this._headertables=o),a.off(Ke+O+" focus"+O+" focusout"+O+" keydown"+O),o&&o.find("a.k-link").attr("tabIndex",-1),r.on("keydown"+O,".k-detail-cell",(function(e){e.target!==e.currentTarget&&e.stopImmediatePropagation()})),a.on(n.support.touch?"touchstart"+O:Ke+O,E+">"+I,$i.bind(t)).on("focus"+O,t._tableFocus.bind(t)).on("focusout"+O,t._tableBlur.bind(t)).on("keydown"+O,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(it,0),this._setCurrent(n),e(n).removeClass(pe)},_tableFocus:function(){var e=this.current();var t=this.lockedTable?this.lockedTable:this.table;e&&e.is(":visible")?e.addClass(pe):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(it,0)},_tableBlur:function(){var e=this.current();e&&e.removeClass(pe)},_findCellIndex:function(e,t,n){var i;var 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;var o=r._virtualCellIndex;var a=pi(oi(r.columns));var s=0;e==(qt?h.LEFT:h.RIGHT)&&o!==a.length-1?o=r._findCellIndex(a,o+1):e==(qt?h.RIGHT:h.LEFT)&&o?o=r._findCellIndex(a,o-1,!0):e==h.HOME?o=r._findCellIndex(a,0):e==h.END&&(o=r._findCellIndex(a,a.length-1,!0));for(var l=0;l<o;l++)s+=a[l].width;r._virtualCellIndex=o,i&&(i.preventDefault(),i.stopPropagation());let c=r.content;return r._hasVirtualRows()&&r._hasVirtualColumns()&&(c=r.virtualScrollable.wrapper),n.scrollLeft(c,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")||this._isFocusableGridElement(n));if(t.altKey&&t.keyCode==h.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!==h.F10||(l=this._focusToolbar()),s&&t.keyCode==h.UP&&(l=this._moveUp(n,t.shiftKey,t.ctrlKey)),s&&t.keyCode==h.DOWN&&(l=this._moveDown(n,t.shiftKey,t.ctrlKey)),s&&t.keyCode==(qt?h.LEFT:h.RIGHT)&&(l=this._moveRight(n,t.altKey,t.shiftKey,t.ctrlKey,i)),s&&t.keyCode==(qt?h.RIGHT:h.LEFT)&&(l=this._moveLeft(n,t.altKey,t.shiftKey,t.ctrlKey,i)),s&&t.keyCode==h.PAGEDOWN&&(l=this._handlePageDown()),s&&t.keyCode==h.PAGEUP&&(l=this._handlePageUp()),s&&t.keyCode==h.HOME&&(l=this._handleHome(n,t.ctrlKey)),s&&t.keyCode==h.END&&(l=this._handleEnd(n,t.ctrlKey)),s&&t.keyCode==h.SPACEBAR&&(l=this._handleSpaceKey(n,t.ctrlKey)),t.keyCode!=h.ENTER&&t.keyCode!=h.F2||(l=this._handleEnterKey(n,i,a,t.keyCode==h.F2)),t.keyCode==h.ESC&&(l=this._handleEscKey(n)),t.keyCode==h.TAB&&(l=this._handleTabKey(n,i,t.shiftKey,a)),t.keyCode!==h.DELETE&&t.keyCode!==h.BACKSPACE||(l=this._handleDeletion(t)),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)},_focusFocusable:function(e,t,n,i,r){let o=this._isFocusableGridElement(t)&&t.find(ve);o&&o.length||t.is(ve)&&(o=t),this._containerHasActiveElement(e)&&1!==e.find(ve).length||!t.length||(Ri(this.table,!0),this._setCurrent(t,n,i),1!==o.length||o.is("table")||(o.trigger("focus"),r?.preventDefault()))},_containerHasActiveElement:function(e){return e.find(s()).length},_isFocusableGridElement:function(e){return!!e&&(e.is(_e)||e.has(_e).length)},_moveLeft:function(t,n,i,r,o){var a,s;var l=t.parent();var c=l.parent();return n?l.hasClass(He)?this.collapseGroup(l):this.collapseRow(l):r&&t.is(S+Ae)&&this.options.reorderable?this._moveColumn(t,!0):(s=c.find(E).index(l),(a=this._prevHorizontalCell(c,t,s))[0]||this._containerHasActiveElement(t)||(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]&&Ri(this.table,!0))),this._focusFocusable(t,a)),!0},_moveRight:function(t,n,i,r,o){var a,s;var l=t.parent();var c=l.parent();return n?l.hasClass(He)?this.expandGroup(l):this.expandRow(l):r&&t.is(S+Ae)&&this.options.reorderable?this._moveColumn(t,!1):(s=c.find(E).index(l),(a=this._nextHorizontalCell(c,t,s))[0]||this._containerHasActiveElement(t)||(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]&&Ri(this.table,!0))),this._focusFocusable(t,a)),!0},_moveUp:function(e,t,n){var i=e.parent().parent();var r,o,a,s;t?(r=(r=e.parent()).prevAll(z).first(),r=e.parent().is(z)?r.children().eq(e.index()):r.children(A).last()):n&&e.parent().is(z)&&this._hasReorderableRows()?(o=e.index(),r=(r=e.parent()).prevAll(z).first(),a=this.tbody.children(z).index(r),s=this.tbody.children(z).index(e.parent()),a>=0&&!this.trigger(je,{oldIndex:s,newIndex:a,row:e.parent()})&&(this.reorderRows(e.parent(),a),r=this.tbody.children(z).eq(a).children().eq(o))):(r=this._prevVerticalCell(i,e))[0]||(this._lastCellIndex=0,i=this._verticalContainer(i,!0),(r=this._prevVerticalCell(i,e)).is(":hidden")&&(r=r.nextAll().not(":hidden").first()),r[0]&&Ri(this.table,!0));var l=this._lastCellIndex||0;return this._isStackedMode()?(Ri(this.table,!0),this._setCurrent(r)):this._focusFocusable(e,r),this._lastCellIndex=l,!0},_moveDown:function(e,t,n){var i=e.parent().parent();var r,o,a,s;t?(r=(r=e.parent()).nextAll(z).first(),r=e.parent().is(z)?r.children().eq(e.index()):r.children(A).first()):n&&e.parent().is(z)&&this._hasReorderableRows()?(o=e.index(),r=(r=e.parent()).nextAll(z).first(),a=this.tbody.children(z).index(r),s=this.tbody.children(z).index(e.parent()),a>=0&&!this.trigger(je,{oldIndex:s,newIndex:a,row:e.parent()})&&(this.reorderRows(e.parent(),a+1),r=this.tbody.children(z).eq(a).children().eq(o))):(r=this._nextVerticalCell(i,e))[0]||(this._lastCellIndex=0,i=this._verticalContainer(i),(r=this._nextVerticalCell(i,e))[0]&&Ri(this.table,!0));var l=this._lastCellIndex||0;return this._isStackedMode()?(Ri(this.table,!0),this._setCurrent(this._findVisibleCell(r))):this._focusFocusable(e,this._findVisibleCell(r)),this._lastCellIndex=l,!0},_moveColumn:function(t,n){var i=this.wrapper.data().kendoReorderable.element.find(this._draggableInstance.options.filter+":visible");var r=Pn(qn(this.columns));var o=i.index(e(t));var a=n?-1:1;var s=r[o];var l=Gn(r,this.columns,o,o+a);l>=0&&(this.reorderColumn(l,s,n),this.trigger(Ve,{newIndex:l,oldIndex:o,column:s}))},_handleHome:function(e,t){const n=this;let i=e.parent();const r=i.parent();const o=n.lockedTable&&n.lockedTable.children("tbody")[0]===r[0];const a=r[0]===n.tbody[0];let s;const l=n._hasVirtualColumns();const c=n._hasVirtualRows();const d=0===(c?n.virtualScrollable.wrapper:n.content).scrollLeft();return l&&c&&t?(n._focusVirtualCell(!0,l&&!d),!0):l?(d?n._setCurrent(n.table.find(z).first().children(I).first()):n._forceScrollVirtualColumn(h.HOME,t),!0):c&&t?(n._focusVirtualCell(!0),!0):(t?s=n.lockedTable?n.lockedTable.find(z).first().children(I).first():n.table.find(z).first().children(I).first():(a||o)&&(a&&this.lockedTable&&(i=n._relatedRow(i)),s=i.children(A).first()),s&&s.length?(n._setCurrent(s),!0):void 0)},_setCurrentVirtualCell:function(e){const t=this;e?this._setCurrent(t.table.find(z).first().children(I).first()):this._setCurrent(t.table.find(z).last().children(I).last())},_forceScrollVirtualColumn:function(e,t,n){const i=this;n?(i._shouldFocusInLastRow=!t,i._shouldFocusInFirstRow=t):e===h.HOME?i._shouldFocusInFirstRow=t:i._shouldFocusInLastRow=t,i.one(te,(function(){n&&i.one(te,(function(){i._setCurrentVirtualCell(t)})),i._shouldFocusInLastRow&&(i.content.scrollTop(i.content[0].scrollHeight),delete i._shouldFocusInLastRow),i._shouldFocusInFirstRow&&(i.content.scrollTop(0),delete i._shouldFocusInFirstRow)})),i._scrollToColumn(e)},_focusVirtualCell:function(e,t){const n=this;const i=this.virtualScrollable.verticalScrollbar;const r=Math.ceil(i.scrollTop()+i.innerHeight())>=i[0].scrollHeight;const o=0===this.virtualScrollable.verticalScrollbar.scrollTop();const a=e?o:r;const s=e?h.HOME:h.END;if(a)t?n._forceScrollVirtualColumn(s,e,!0):n._setCurrentVirtualCell(e);else{0===n.dataSource.group().length&&(n.virtualScrollable._alwaysScrollTop=!0);const r=e?0:i[0].scrollHeight;n.one(te,(function(){t?n._forceScrollVirtualColumn(s,e,!0):(n._setCurrentVirtualCell(e),n._shouldFocusInLastRow&&delete n._shouldFocusInLastRow,n._shouldFocusInFirstRow&&delete n._shouldFocusInFirstRow)})),i.scrollTop(r),i.trigger(le)}},_handleEnd:function(e,t){const n=this;let i=e.parent();const r=i.parent();const o=n.lockedTable&&n.lockedTable.children("tbody")[0]===r[0];const a=r[0]===n.tbody[0];let s;const l=n._hasVirtualColumns();const c=n._hasVirtualRows();const d=c?n.virtualScrollable.wrapper:n.content;const u=d.scrollLeft()+d.innerWidth()>=d[0].scrollWidth;return l&&c&&t?(n._focusVirtualCell(!1,l&&!u),!0):l?(u?n._setCurrent(n.table.find(z).last().children(I).last()):n._forceScrollVirtualColumn(h.END,t),!0):c&&t?(n._focusVirtualCell(!1),!0):(t?s=n.table.find(z).last().children(I).last():(a||o)&&(!a&&this.lockedTable&&(i=n._relatedRow(i)),s=i.children(A).last()),s&&s.length?(n._setCurrent(s),!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){const o=this.options.editable&&"incell"==this._editMode();let a=e(s()).closest(".k-grid-stack-edit-cell,.k-edit-cell");let l;const c=this._isStackedMode();const d=r.is(ve);const h=!r.is("table");const u=c&&r.is(".k-grid-stack-cell");const p=!u&&r.closest(".k-grid-stack-cell");const f=this._isFocusableGridElement(t);const m=!ji(t);const g=r;let v;if(c?u?v=r.parent().find(".k-grid-stack-cell").length>1:p&&p.length&&(v=p.find(ve).length>1):v=t.find(ve).length>1,!a[0]&&d&&h&&v&&f&&m){if(!c&&(r.is(":last-child")&&!i||r.is(":first-child")&&i))return Ri(this.table,!0),!0;if(r=i?r.prev(ve):r.next(ve),u&&!r.length){const e=g.parent().find(".k-grid-stack-cell");i&&g.is(":first-child")&&(r=e.last()),!i&&g.is(":last-child")&&(r=e.first())}else if(!r.length&&!u){const e=g.closest(".k-grid-stack-cell");i&&g.is(":first-child")&&(r=e),!i&&g.is(":last-child")&&(r=e.find(ve).first())}return c&&r.is(".k-grid-stack-cell")?this._currentStackedCell(r,!0):r.trigger("focus"),!0}if(c&&!u&&!a[0]||!o||t.is("th")||(this.options.scrollable?this._headertables&&this._headertables.filter(n).length:this.thead&&this.thead.filter(r).length)){if(t.parent().hasClass("k-filter-row")){if(l=this._filterFocusable(),!i&&l[l.length-1]===document.activeElement)return l.first().trigger("focus"),!0;if(i&&l[0]===document.activeElement)return l.last().trigger("focus"),!0}return!1}return a[0]&&a[0]!==t[0]&&(t=a),a=this._tabNext(t,n,i),a[0]!==t[0]&&(!!a.length&&(this._handleEditing(t,a,a.closest("table")),!0))},_handleDeletion:function(n){const i=this;const r=i.current();const o=e(s());const a=i._isStackedMode()?!i._currentStackedCell():!o.is("table");return!(!(i._isEditableEnabled!==t?i._isEditableEnabled&&i.options.editable:i.options.editable)||ji(r)||a||!r.closest("tbody").length||!r.closest(".k-master-row").length)&&(i._removeCommandClick({currentTarget:r,preventDefault:n.preventDefault,stopPropagation:n.stopPropagation}),!0)},_handleEscKey:function(t){const n=s();const i="incell"==this._editMode();const r=this._isStackedMode();const o=e(n);const a=o.is(".k-grid-stack-cell")?e():o.closest(".k-grid-stack-cell");const l=r?o:t;const c=a&&a.length>0;const d=r&&l.is(".k-grid-stack-cell");if(!ji(a.length?a:l))return d||!c&&t.has(n).length&&(!this._isFocusableGridElement(t)||1!==t.find(ve).length)?(Ri(this.table,!0),delete this._activeStackedCell,!0):c?(a.trigger("focus"),!0):!!t.parent().hasClass("k-filter-row")&&(this._filterFocusable().attr(it,-1),Ri(this.table,!0),!0);if(i)this.closeCell(!0),r&&c&&(Sn(a.parent().children(".k-grid-stack-cell")),this._currentStackedCell(a,!0));else{var h=e(t).closest(bt).index();if(n&&n.blur(),this.cancelRow(!0),h>=0){const e=this._currentStackedCell();if(r&&e){const t=this.tbody.find(bt).eq(h).find(".k-grid-stack-cell").eq(e.index);this._setCurrentStackedCell(t)}else{const e=this.items().eq(h).children(I).first();this._setCurrent(e)}}}return r||Ri(this.table,!0),!r},_toggleCurrent:function(e,t,n){const i=this;const r=e.parent();if(e.is(".k-command-cell"))return!1;if(r.is(".k-filter-row"))return!1;if(r.is(S+He))return r.find(".k-icon,.k-svg-icon").first().click(),!0;if(!t&&n){const e=i._isStackedMode()?'[ref="expand-detail-button"], [ref="collapse-detail-button"]':".k-icon,.k-svg-icon";return r.find(e).first().click(),!0}return!1},_handleSpaceKey:function(t,i){var r=this;if(i&&r.groupable&&t.hasClass(Ae)){var o=r.groupable.descriptors();var a=t.attr(n.attr("field"));var 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}},_hasStackedModeDetailsButton:function(e){return e.find('[ref="expand-detail-button"], [ref="collapse-detail-button"]').length>0},_currentStackedCell:function(e,t){const n=this;if(!e||!e.length)return n._activeStackedCell;n._activeStackedCell={cell:e,index:e.index()},t&&e.length&&e.trigger("focus")},_handleEnterKey:function(t,n,i,r){const o=this;var a=this.options.editable&&!1!==this.options.editable.update;var l=i.closest("td");var c=this._hasDetails();var d;const h=o._isStackedMode();const u=h&&r&&"incell"!==o._editMode();const p=h?"k-grid-stack-edit-cell":"k-edit-cell";const f=h&&(i.is(".k-grid-stack-cell")||i.parent().is(".k-grid-stack-cell")||i.closest(".k-grid-stack-cell").length>0);if(i.is("table")||e.contains(t[0],i[0])||(t=l),t.is("th"))return d=t.find(".k-link"),!(t.has(e(s())).length>0)&&(d.length?d.click():t.parent().hasClass("k-filter-row")?(this._filterFocusable().attr(it,0),t.find(":kendoFocusable").first().trigger("focus")):t.find(ye).trigger("focus"),!0);if(!u){if(!f&&this._toggleCurrent(t,a,c))return!0;if(f&&o._hasStackedModeDetailsButton(i))return this._toggleCurrent(t,!1,!0),!0;let e=":kendoFocusable";h&&!f&&Sn(t.find(".k-grid-stack-cell"));var m=(f?i:t).find(e).first();if(m[0]&&(f||!t.hasClass(p)&&t.hasClass("k-focus")))return f?m.trigger("focus"):o._currentStackedCell(m,!0),!0}return!(!a||i.is(":button,.k-button,textarea"))&&(l[0]||(l=t),h&&i.is(".k-grid-stack-cell")&&o._currentStackedCell(i),f&&(l=i.is(".k-grid-stack-cell")?i:i.closest(".k-grid-stack-cell")),this._handleEditing(l,!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(Ae)){var r=[];return Jn([ri(this.columns)[0]],wi(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(A+",[hidden]").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(Ae)){var o=[];var a=ri(this.columns);return Jn([a[a.length-1]],wi(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=ri(this.columns).length;return r&&!e.closest(wt).hasClass("k-grid-content-locked")[0]?i-r:i},_findVisibleCell:function(e){var t=e.index();var n=e.closest("tr").index();var i;if(e.is("[hidden]")){i=e.prevAll(":not([hidden])").first();var r=e.prevUntil(":not([hidden])","[hidden]").length;if(!i.attr("colspan")||i.attr("colspan")>1&&i.attr("colspan")<=r+1){if(0===(i=e.prevAll("[hidden]").last()).length)return e.closest("tr").prevAll().find(`td:nth-of-type(${t+1}):visible`).last();for(;!(i.attr("rowspan")||i.attr("rowspan")>1&&i.attr("rowspan")!=n-i.closest("tr").index()||Math.abs(i.index()-t)==i.attr("colspan"));)if(0===(i=i.closest("tr").prevAll().find("td, th").eq(t).first()).length){i=e;break}}}else i=e;return i},_prevVerticalCell:function(t,n){var i;var r=n.parent();var o=t.children(E);var a=o.index(r);var s=this._currentDataIndex(t,n);if(s||n.hasClass(Ae))return(i=bi(n)).eq(i.length-2);if(s=Math.max(r.children(D).index(n),this._lastCellIndex||0),r.hasClass("k-filter-row")){let e=o.last().children(".k-group-cell").length;return _i(t).filter(En).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),_i(t).eq(Math.max(0,s-e))}this._hasDetails()&&s--}else r=0===a?e():o.eq(a-1);if((i=r.children(D)).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;var r;var o=r=n.closest(bt);var a=e.children(E);var s=a.index(o);var l=this._currentDataIndex(e,n);var c=this.virtualScroll||{};var d;if(-1!=s&&l===t&&n.hasClass(Ae))return wi(n).eq(1);l=l?parseInt(l,10):o.children(D).index(n),l=Math.max(l,this._lastCellIndex||0),-1==s?(o=a.eq(0),c.columns&&(d=parseInt(o.children().first().attr("colspan"),10),l=this._virtualCellIndex-(d>1?d:0)),(this._hasDetails()||o.find(".k-hierarchy-cell").length)&&l++,o.hasClass("k-table-group-row")&&(l+=r.children(".k-group-cell").length)):o=a.eq(s+n[0].rowSpan);let h=(i=o.children(".k-group-cell,"+D)).eq(0);return i.length>l&&(h=i.eq(l)),h.is(".k-group-cell")&&(h=h.nextAll("td").not(".k-group-cell").not(":hidden").first()),h},_verticalContainer:function(e,t){var n=e.parent();var i=this._navigatableTables.length;var r=Math.floor(i/2);var 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();var 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;var 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=Gt.msie,h=a._editContainer,u=a.options.editable&&!1!==a.options.editable.update;const p=a._isStackedMode();const f=t.is(".k-grid-stack-cell");if(i=e(i),"incell"==c){const e=p?"k-grid-stack-edit-cell":"k-edit-cell";o=t.hasClass(e)}else o=f?t.hasClass("k-grid-stack-edit-cell"):t.parent().hasClass("k-grid-edit-row");if(a.editable){if(e.contains(h[0],l[0])&&(l.trigger("blur"),d&&l.trigger("blur")),!a.editable&&!f)return void Ri(a.table);if(!a.editable.end())return p&&f?a._setCurrentStackedCell(t):("incell"==c?a._setCurrent(h):a._setCurrent(h.children().filter(A).first()),void((r=h.find(":kendoFocusable").first()[0])&&r.focus()));"incell"==c?a.closeCell():(a.saveRow(),o=!0)}if(n&&a._setCurrent(n),f||Ri(a.table,!0),u){if(!o&&!n||n)if(c===dt){if(!(p?t.find("[ref='expand-detail-button'], [ref='collapse-detail-button']").length:e(a.current()).hasClass("k-hierarchy-cell"))){const e=a._isStackedMode();const n=e?t:a.current();if(e&&n.is(".k-command-cell"))return;a.editCell(n,e&&n.parent().children().index(n))}}else a.editRow(a.current().parent());a._toggleToolbarEditingItemsVisibility()}},_wrapper:function(){var e=this,t=e.table,i=e.options.height,r=e.options.width,o=e.element;o.is(wt)||(o=o.wrap("<div/>").parent()),e.wrapper=o.addClass("k-grid "+n.getValidCssClass("k-grid-","size",e.options.size)),e._isStackedMode()?e.wrapper.addClass(F):e.wrapper.removeClass(F),i&&(e.wrapper.css(et,i),t.css(et,nt)),r&&e.wrapper.css(tt,r),e._initMobile()},_initContextMenu:function(){var e=this,t=e.options,n=p(t.contextMenu)&&v(t.contextMenu.groups)?{items:t.contextMenu.groups}:{items:nn},r=p(t.contextMenu)&&v(t.contextMenu.body)?{items:t.contextMenu.body}:{items:en},o=p(t.contextMenu)&&v(t.contextMenu.head)?{items:t.contextMenu.head}:{items:tn};var 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;var t=this;if(this._isMobile="auto"!==t.options.adaptiveMode&&!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(et,e.height):this.pane.element.parent().css(et,this.wrapper[0].style.height),this._editAnimation="slide",t.wrapper.on("transitionend"+O,(function(e){e.stopPropagation()})),t.wrapper.on("contextmenu"+O,"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=o_.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;const d=o._isStackedMode();if(s){d||((t=o.wrapper.children(".k-grid-header"))[0]||(t=e('<div class="k-grid-header" />').insertBefore(o.table)),t.css(qt?"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)),d||(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, ."+Xt)&&(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.add(o.thead.parent()).css({width:Qn(ci(si(o.columns)))}),d?o.scrollables=o.content:(r=t.children(".k-grid-header-wrap"),o.scrollables=r.add(o.content));var h=o.wrapper.find(".k-grid-footer");if(h.length&&(o.scrollables=o.scrollables.add(h.children(".k-grid-footer-wrap"))),d||r.off("scroll"+O).on("scroll"+O,(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"+O).on("scroll"+O,(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;var p=o.dataSource.options.pageSize;u&&(o._endlessPageSize=p),o.content.off("scroll"+O).on("scroll"+O,(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+p,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 f=o.content.data("kendoTouchScroller");f&&f.destroy(),(f=n.touchScroller(o.content))&&f.movable&&(o.touchScroller=f,f.movable.bind("change",(function(e){n.scrollLeft(o.scrollables,-e.sender.x),o.lockedContent&&o.lockedContent.scrollTop(-e.sender.y)})),o.one(te,(function(e){e.sender.wrapper.addClass("k-grid-backface")})))}}},_createVirtualScrollable:function(){var e=this;e.virtualScrollable&&e.virtualScrollable.destroy(),e.virtualScrollable=new an(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(ae,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()===ht},_isVirtualIncellEditable:function(){return this.virtualScrollable&&this._editMode()===dt},_isVirtualPopupEditable:function(){return this.virtualScrollable&&"popup"===this._editMode()},_hasVirtualColumns:function(){return!!(this.virtualScroll||{}).columns},_hasVirtualRows:function(){return!!(this.virtualScroll||{}).rows},_scrollVirtualWrapper:function(){var e=this;var 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=this;var n=t._editableState||{};var i=n.model;var r=t.dataSource;var o=t._isVirtualInlineEditable();var a=t._isVirtualIncellEditable();var s=t._hasVirtualColumns();var l;var c;if((o||a||s)&&i&&r._getByUid(i.uid,r.view()))if(t._editMode()===ht)t._shouldClearEditableState=!1,t.editRow(i),s||t._focusEditable();else if(t._editMode()===dt){const r=t._isStackedMode();l=t.tbody.children(dn("uid",i.uid)),(c=r?e(l).find(".k-grid-stack-cell:not(.k-drag-cell):not(.k-command-cell)"+dn(lt,n.field)):e(l).children(dn(lt,n.field)))[0]&&(t._shouldClearEditableState=!1,t.editCell(c,r&&c.parent().children().index(c)),s||t._focusEditable())}t._shouldClearEditableState=!0},_focusEditable:function(){var e=this;var t=(e._editableState||{}).field;var n=e._editContainer;n&&n.length&&!x(n[0],s())&&e._canFocusEditable()&&(e._isVirtualInlineEditable()||e._hasVirtualColumns()?n.find(dn(st,t)).find(ve).eq(0).trigger("focus"):(e._isVirtualIncellEditable()||e._hasVirtualColumns())&&n.find(ve).eq(0).trigger("focus"))},_canFocusEditable:function(){var e=this;return(e._isVirtualIncellEditable()||e._isVirtualInlineEditable()||e._hasVirtualColumns())&&(Wi((e.virtualScrollable||{}).wrapper,e._editContainer)||Wi(e.content,e._editContainer))},_cacheEditableState:function(){var t=this;var i=t._editContainer;var r=i?t._modelForContainer(i):null;var o=t._isVirtualInlineEditable();var a=t._isVirtualIncellEditable();var l=t._hasVirtualColumns();var c;var d;var h;(o||a||l)&&r&&(t._clearEditableState(),c=e(s()),i&&c[0]&&x(i[0],c[0])&&(c.change(),(d=n.widgetInstance(c,n.ui))&&w(d.value)&&c.is(ct)&&(h=c.val(),c.is("[type='checkbox'")&&(h=c.is(":checked")),d.value(h),d.trigger(X))),t._editMode()===ht?t._editableState={model:r,field:c.closest("["+n.attr(st)+"]").attr(n.attr(st))}:t._editMode()===dt&&(t._editableState={model:r,field:i.attr(n.attr(lt))}))},_clearSortClasses:function(){var e=this,t=e.content||e.table,n=e.lockedContent;t&&t.find(P).removeClass(Me),n&&n.find(P).removeClass(Me)},_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(Je+O),this.rowResizer=null,this._clearCachedRowsHeight())},_renderNoRecordsContent:function(){var t=this;if(t.options.noRecords){var i=t.table.parent().children("."+ke);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)"),h=Xn(l),u=Xn(d);a>0&&e&&(h+=c(this.lockedHeader.find(".k-group-cell").first())*a),h>=o&&(h=o-3*s),this.lockedHeader.add(this.lockedContent).width(h),r[0].style.width=r.parent().width()-h-2+_t,i.add(this.table).width(u),this.virtualScrollable&&!Kt&&(o-=s),this.content[0].style.width=o-h-1+_t,this.lockedFooter&&this.lockedFooter.length&&(this.lockedFooter.width(h),t=this.footer.find(".k-grid-footer-wrap"),t[0].style.width=r[0].clientWidth+_t,t.children().first().width(u))}},_setContentHeight:function(){var e,t=this,i=t.options,r=t.wrapper.children(".k-grid-header"),o=n.support.scrollbar();var a=(i.scrollable||{}).height;if(i.scrollable&&t.wrapper.is(":visible")){a&&""===t.content[0].style.height&&(t.content[0].style.height=a),e=t.wrapper.innerHeight(),e-=d(r),t.pager&&t.pager.element.is(":visible")&&(e-=d(t.pager.element)),i.groupable&&(e-=d(t.wrapper.children(".k-grouping-header:not(.k-hidden)"))),i.toolbar&&(e-=d(t.wrapper.children(".k-grid-toolbar"))),t.footerTemplate&&(e-=d(t.wrapper.children(".k-grid-footer"))),t.statusBar&&(e-=d(t.wrapper.children(".k-selection-aggregates")));((s=t.wrapper)[0].style.height||(l=s.height(),s.height(nt),l!=s.height()?(s.height(""),1):(s.height(""),0)))&&(e>2*o?(t.lockedContent&&(o=t.table[0].offsetWidth>t.table.parent()[0].clientWidth?o:0,t.lockedContent.height(e-o)),t.content.height(e)):t.content.height(2*o+1))}var s,l},_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(X,n._refreshHandler).unbind(T,n._progressHandler).unbind(ue,n._requestEndHandler).unbind(M,n._errorHandler).unbind(pt,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(X,n._refreshHandler).bind(T,n._progressHandler).bind(ue,n._requestEndHandler).bind(M,n._errorHandler).bind(pt,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,h,u,p=this,f=p.tbody,m=t.model,g=p.tbody.find("tr["+n.attr("uid")+"="+m.uid+"]"),v=g.hasClass("k-table-alt-row"),_=p._items(f).index(g),b=p.lockedContent;const w=p._isStackedMode();b&&(r=p._relatedRow(g));if((w?g.add(r).find(".k-grid-stack-cell:not(.k-drag-cell):not(.k-command-cell)"):g.add(r).children(".k-edit-cell")).length&&!p.options.rowTemplate){(w?g.add(r).children(":not(.k-group-cell,.k-hierarchy-cell)").find(".k-grid-stack-cell:not(.k-drag-cell):not(.k-command-cell)"):g.add(r).children(":not(.k-group-cell,.k-hierarchy-cell)")).each((function(){if(o=e(this),!(w&&o.hasClass(".k-command-cell")||(a=pi(p.columns)[p._calculateColumnIndex(o)]).field!==t.field)){const e=w?"k-grid-stack-edit-cell":"k-edit-cell";if(o.hasClass(e))o.addClass("k-dirty-cell");else{const e=w?o.find(".k-grid-stack-content"):o;p._displayCell(e,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(be)&&p.select(s),h=c.children(":not(.k-group-cell,.k-hierarchy-cell)"),d=s.children(":not(.k-group-cell,.k-hierarchy-cell)"),_=0,u=p.columns.length;_<u;_++)a=p.columns[_],o=w?d.find().eq(_):d.eq(_),l&&h.eq(_).hasClass(be)&&o.addClass(be);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;if(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();let s=i.options.adaptiveMode;"auto"===i.options.adaptiveMode&&r&&"object"==typeof r&&r.adaptiveMode&&(s=r.adaptiveMode),"object"==typeof r&&r instanceof n.ui.Pager?i.pager=r:i.dataSource._groupPaging?i.pager=new Jt(t,f({},r,{dataSource:i.dataSource,navigatable:a,size:o,adaptiveMode:s})):i.pager=new n.ui.Pager(t,f({},r,{dataSource:i.dataSource,navigatable:a,size:o,adaptiveMode:s})),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(it,-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(qt?"padding-left":"padding-right",a),o):'<tfoot class="k-grid-footer k-table-tfoot">'+t+"</tfoot>"},_actionsheetFooterActionsTemplate:function(e){let t="";return e.forEach((e=>{const i=e.command;const r=e.text;t+=n.html.renderButton(`<button data-command=${i}>${r}</button>`,e)})),t},_isAdaptive:function(){const e=this;return"auto"===e.options.adaptiveMode&&(e.smallMQL.mediaQueryList.matches||e.mediumMQL.mediaQueryList.matches)},_isStackedMode:function(){return"stacked"===this.options.dataLayoutMode},_toolPopup:function(e){return e.popup&&e.popup.wrapper},_filterToolbarTool:function(t){const i=this;const r=pi(i.columns);const o=i.options;const a=e=>{const t=i._isAdaptive()?"[ref-actionsheet-action-button]":"[ref='clear-filter']";return i._toolPopup(e)?.find(t)};const s=i._toolbarOptionsForTool("filter");const l=t.data("kendoColumnMenu");l&&(l.wrapper.off("click"+O),l.element.off("click"+O),l.destroy());const c=!(!o.filterable||!1===i.options.columnMenu.filterable)&&f(!0,{pane:i.pane},o.filterable);if(!c)return;const d={dataSource:i.dataSource,columns:!1,sortable:!1,filterable:c,hideAutoSizeColumn:!0,owner:i,adaptiveMode:i.options.adaptiveMode,encodeTitles:i.options.encodeTitles,componentType:"modern",_actionsheet:{actionButtons:on(i.options.messages).filter,title:"Filter by",closeButton:!0,ref:"filter-view"},closeCallback:function(e){e.removeClass(be);const n=i._toolPopup(t);n.length&&n.find(".k-focus").removeClass("k-focus"),t.element.focus()},init:function(e){if(t.wrapper.attr("ref","filter-tool"),!i._showAdaptiveView)for(var n=0,a=r.length;n<a;n++){const e=r[n];const a=e.field;if(!(o.filterable&&!1!==e.filterable&&!e.draggable&&!e.selectable&&!e.command))continue;const s=t.wrapper.find(`.k-columns-item[data-field="${a}"]`);i._initFilterMenuForColumn(e,s)}},contentTemplate:function({isAdaptive:e}){let t="";for(let e=0;e<r.length;e++){const n=r[e];!(o.filterable&&!1!==n.filterable)||n.command||n.draggable||n.selectable||(t+='<div class="k-columnmenu-item-wrapper">',t+=`<div class="k-columnmenu-item-content k-columns-item" ref="filter" tabindex="0" data-field="${n.field}" data-index=${n.index||e||0}></div>`,t+="</div>")}return s&&!s.clearButton||e||(t+='<div class="k-actions k-actions-stretched k-actions-horizontal k-column-menu-footer">',t+=n.html.renderButton(`<button ref="clear-filter">${on(i.options.messages).filter[0].text}</button>`,{icon:"filter-clear"}),t+="</div>"),t},filtering:function(e){i.trigger("filter",{filter:e.filter,field:e.field})?e.preventDefault():(i._clearEditableState(),i.dataSource.options.endless&&i._resetEndless())}};(t=t.kendoColumnMenu(d).data("kendoColumnMenu")).element.bind("click"+O,(function(n){t.popup&&t.popup._closing||(e(n.currentTarget).addClass(be),a(t)?.toggleClass("k-disabled",!t.dataSource._filter))}));const h=function(e){const t=e.sender.wrapper&&e.sender.wrapper.find(".k-grid-filter-tool")?.data("kendoColumnMenu");const n=t.dataSource._filter;const r=e.field;let o=!e.filter;let s;const l=n&&n.filters;if(o&&l&&l.length&&!l.find((e=>e.filters&&e.filters.length?e.filters[0].field===r:e.field===r)))return;const c=t.wrapper.find(`.k-columns-item[data-field='${r}']`);const d=c?.closest(".k-expander")?.find(".k-columnmenu-item");n&&n.filters.length?s=o?l.filter((e=>e.field!==r)).length>0:!o:o||(s=!0),c.length&&c.data("kendoExpansionPanel").toggle(!1),a(t)?.toggleClass("k-disabled",!s),i._toggleColumnMenuFilterIndicator(d,!o),i._toggleBadge(t.element,s)};i.unbind("filter",h),i.bind("filter",h),t.bind("open",(function(){const e=i._toolPopup(t);if(e.length){e.focus();const n=a(t);const r=t.dataSource._filter&&t.dataSource._filter.filters;r&&r.length&&r.forEach((e=>{const n=e.field||e.filters[0].field;const r=t.wrapper.find(`.k-columns-item[data-field='${n}']`);const o=r?.closest(".k-expander")?.find(".k-columnmenu-item");i._toggleColumnMenuFilterIndicator(o,!0)})),n.length&&(n.off("mousedown"+O),n.on("mousedown"+O,(function(){i.dataSource.filter([]),i._toggleBadge(t.element,!1),t.wrapper.find(".k-columnmenu-indicators").remove(),n.toggleClass("k-disabled",!0),t.popup.close()})))}}))},_initFilterMenuForColumn:function(e,t){const n=this;let i=n._hasFilterMenu();let r;if(t.length){r=t.data("kendoFilterMenu"),r&&r.destroy(),r=t.data("kendoFilterMultiCheck"),r&&r.destroy();var o=e.filterable;var a=f({},i,o,{appendToElement:!0,componentType:"modern",dataSource:n.dataSource,values:e.values,format:e.format,title:e.title||e.field,pane:n.pane,adaptiveMode:n.options.adaptiveMode,change:function(e){n.trigger("filter",{filter:e.filter,field:e.field})?e.preventDefault():(n._clearEditableState(),n.dataSource.options.endless&&n._resetEndless())}});return o&&o.messages&&(a.messages=f(!0,{},i.messages,o.messages)),o&&o.dataSource&&(a.forceUnique=!1,a.checkSource=o.dataSource),o&&o.multi?t.kendoFilterMultiCheck(a).data("kendoFilterMultiCheck"):t.kendoFilterMenu(a).data("kendoFilterMenu")}},_initAiPrompt:function(){const t=this;const i=t.options.ai;const r=i?.aiAssistant||{};const o=t.options.messages?.ai;let a=i?.service;const s={data:e=>(e=>({role:"user",contents:[{$type:"text",text:e}],columns:t.columns}))(e),outputGetter:function(e){const t=e?.status;const n=e?.messages&&"object"==typeof e.messages;let i=[];return t?i.push(o.error+" "+`${e.status} ${e.statusText}`):(i.push(o.success),n?i.push(...e.messages):i.push(o)),i.join("/n")}};const l=(e,t)=>{if(!t._requestInProgress||!t.options.service)return;const n=t.outputObjects;t.updatePromptOutputContent(e.output,c),t.element.find("[data-id='"+c+"']").attr("data-id",e.outputId);const i=n.get(c);n.delete(c),i&&(i.id=e?.outputId,i.data.id=e?.outputId,n.set(e?.outputId,i)),t.promptOutputs=t.promptOutputs.map((e=>(e.id===c&&e.id,e))),t.stopStreaming(),t._requestInProgress=!1};if(i?.service){const e="string"==typeof i.service;const t=e?i.service:i.service.url;t&&(a={...s,...e?{}:i.service,url:t})}const c="skeleton"+n.guid();const d=t._aiAssistant=e("<div></div>").kendoAIPrompt(e.extend(!0,{service:a,speechToText:!0,outputTemplate:e=>{const t=e.output;return t.output?.split("/n").map((e=>{return(t=e).includes(o.error)?`<p class="k-text-error">${n.htmlEncode(t)}</p>`:`<div class="k-card-text">${n.htmlEncode(t)}</div>`;var t})).join("")},views:[{type:"prompt",buttonIcon:"sparkles",themeColor:"primary",footerTemplate:()=>`<div class="k-actions k-actions-start k-actions-horizontal k-prompt-actions">${n.html.renderButton("<button ref-ai-apply-button>Apply</button>",{themeColor:"primary",icon:"table-wizard",fillMode:"solid",rounded:"full"})}</div>`},{type:"output",themeColor:"primary",isStreaming:!0,isLoading:!0}],promptRequest:e=>{d.options.service&&(d.activeView("output"),d.removePromptOutput(mn),d.addPromptOutput({id:c,prompt:e.prompt,output:"",isLoading:!0,isStreaming:!0}),d._requestInProgress=!0,d.transport.options.requestStart=null)},promptResponse:e=>{e.preventDefault();const n=e;l(n,d),n&&n.response&&t._handleAIResponse(n.response),!1!==i.autoClose&&t._aiAssistantWindow?.close()},promptRequestCancel:()=>{d.removePromptOutput(c),d.outputObjects.size||d.addPromptOutput(gn(o)),d._requestInProgress=!1}},r)).data("kendoAIPrompt");d?.transport&&(d.transport.options.error=function(e){e.response.abort(),l({output:e.output,outputId:e.id},d)}),t._aiAssistantWindow.element.append(t._aiAssistant.element),t._aiAssistantWindow.wrapper.addClass("k-grid-assistant-window")},_handleAIResponse:function(e){const t=this;const n=!1!==t.options.columnMenu.sortable&&!1!==t.options.sortable&&f({},t.options.sortable,{allowUnsort:!1});const i=!(!t.options.filterable||!1===t.options.columnMenu.filterable)&&f(!0,{pane:t.pane},t.options.filterable);const r=t.options.groupable&&!1!==t.options.groupable.enabled||t.dataSource._groupPaging;const o=t.dataSource.options.schema;const a=o?.model?.fields;e&&Object.keys(e).forEach((o=>{if("messages"===o)return;let s=e[o];const l=Array.isArray(s);const c=l&&!s.length||!l&&"object"==typeof s&&!Object.keys(s).length;const d=c||!c&&!function(e,t){let n={sort:cn,filter:sn,group:ln}[t];return!!n&&n(e).some((e=>!e.field))}(s,o);if(d){if(c||(s=l?s:[s]),"sort"===o&&n){if(c&&!t.dataSource._sort)return;t.dataSource.sort(s)}if("filter"===o&&i){if(c){if(c&&!t.dataSource._filter)return}else s=pn(s,a);t.dataSource.filter(s)}if("group"===o&&r){if(c&&!t.dataSource._group)return;t.dataSource.group(s)}"highlight"===o&&(t.clearHighlight(),c||(t._hasAIHighlight=s,t._applyAIHighlight(s)))}}))},_bindAIPrompt:function(){const t=this.options.ai;const n=this._aiAssistant;const i=e=>e.find("[ref-ai-apply-button]");n.element.on("input"+O,"[ref-prompt-input]",(t=>{const r=i(n.element);const o=e(t.currentTarget).val();r.toggleClass("k-disabled",!o||""===o.trim())})),t?.aiAssistant?.promptSuggestions&&n.element.on("click"+O,".k-suggestion",(e=>{i(n.element).toggleClass("k-disabled",!1)})),n.element.on("click"+O,"[ref-ai-apply-button]",(()=>{const e=n.element.find("[ref-prompt-input]").getKendoTextArea().value();const t=n._selectedView;const i={prompt:e,isRetry:!1,history:[]};t?.service&&(i.service=t.service),n.trigger("promptRequest",i),n.transport&&n.transport.read({prompt:i.prompt,history:i.history,isRetry:!1,service:t.service})})),n?.speechToTextButton&&n.speechToTextButton.bind("result",(function(){i(n.element).toggleClass("k-disabled",!1)}))},_unbindAIPrompt:function(){const e=this._aiAssistant;e?.element?.off("input"+O),e?.element?.off("click"+O)},_applyAIHighlight:function(e){const t=this;const n=t.dataSource.options.schema;const i=n?.model?.id||"id";const r=n?.model?.fields;e=pn(e,r);const o=t.dataSource.parseHighlightDescriptors(e,i);t.highlight(o)},_initAiAssistantWindow:function(t){const n=this;const i=n.options.ai;const r=i&&!0===i||!1===i;const o=i?.aiAssistantWindow||{};const a=o?.content;const s={modal:!1,resizable:!1,title:"AI Assistant",visible:!1,actions:["Minimize","Maximize","Close"],position:{top:d(t)+t.offset().top,left:t.offset().left+t.outerWidth()/2},width:437,...o,open:function(e){if(o.open&&o.open(e),e._defaultPrevented)return;const t=n._aiAssistant;if(t&&t.element){const e=n.options.messages?.ai;t.outputObjects.size||t.addPromptOutput(gn(e)),t.activeView("prompt");const i=t.element.find("[ref-ai-apply-button]");const r=t.element.find("[ref-prompt-input]").val();n._aiAssistant&&n._bindAIPrompt(),i.toggleClass("k-disabled",!r||""===r.trim())}},close:function(t){if(o.close&&o.close(t),!t._defaultPrevented){if(t.userTriggered){t.sender.element.trigger("focus");var r=n.items().index(e(n.current()).parent());n._toggleToolbarEditingItemsVisibility(),n.options.navigatable&&n.current()&&(n._setCurrent(n.items().eq(r).children().filter(I).first()),Ri(n.table,!0))}n._aiAssistant&&(i?.keepOutputHistory||n._aiAssistant?.clearOutput(),n._unbindAIPrompt())}}};r||(n._aiAssistantWindow=e("<div></div>").kendoWindow(s).data("kendoWindow"),a||n._initAiPrompt()),t.bind("click"+O,(function(e){n._aiAssistantWindow&&(n._aiAssistantWindow.element.is(":visible")?n._aiAssistantWindow.close():n._aiAssistantWindow.open())}))},_toolbarOptionsForTool:function(e){const t=this.options;let n=[];return Array.isArray(t.toolbar)?n=t.toolbar:t.toolbar&&t.toolbar.items&&(n=t.toolbar.items),f({},fn[e],n.find((t=>t.name===e)))},_groupToolbarTool:function(t){const i=this;const r=i.options;const o=e=>{const t=i._isAdaptive()?"[ref-actionsheet-action-button]:not('.k-button-solid-primary')":"[ref='clear-group']";return i._toolPopup(e)?.find(t)};let a;let s;if(!(r.groupable&&!1!==r.groupable.enabled||i.dataSource._groupPaging))return;a=t.data("kendoColumnMenu"),a&&(a.wrapper.off("click"+O),a.element.off("click"+O),a.destroy());const l=i._toolbarOptionsForTool("group");l.reorderButtons=!0;const c=({isAdaptive:t,isFirstItem:i,isLastItem:r})=>`<span class="k-group-menu-item-actions">\n ${l.reorderButtons?`<span class="k-group-menu-item-action k-group-menu-item-up-action ${i?"k-disabled":""}" ${i?"aria-disabled=true":"aria-disabled=false"}>\n ${n.ui.icon(e("<span></span>"),{icon:"chevron-up",size:t?"large":"medium"})}\n </span>\n <span class="k-group-menu-item-action k-group-menu-item-down-action ${r?"k-disabled":""}" ${r?"aria-disabled=true":"aria-disabled=false"}>\n ${n.ui.icon(e("<span></span>"),{icon:"chevron-down",size:t?"large":"medium"})}\n </span>`:`<span class="k-group-menu-item-action k-group-menu-item-drag-action">\n ${n.ui.icon(e("<span></span>"),{icon:"handle-drag-dots",size:t?"large":"medium"})}\n </span>`}\n </span>`;const d=(t,r,o)=>{const a=i._isAdaptive();const s=t.title||t.field||"";return`<div class="k-group-menu-item" data-field="${t.field}" data-index="${o&&o.index||t.index||"0"}" tabindex="0">\n ${o&&o.renderIndicator?c({isAdaptive:a,isFirstItem:o.isFirstItem,isLastItem:o.isLastItem}):""}\n <span class="k-group-item-text">${s}</span>\n <span class="k-spacer"></span>\n <span class="k-group-menu-item-actions">\n <span class="k-group-menu-item-action ${r.actionClass}">\n ${n.ui.icon(e("<span></span>"),{...r,size:a?"large":"medium"})}\n </span>\n </span>\n </div>`};s={dataSource:i.dataSource,columns:!1,sortable:!1,filterable:!1,hideAutoSizeColumn:!1,owner:i,adaptiveMode:i.options.adaptiveMode,encodeTitles:i.options.encodeTitles,componentType:"modern",_actionsheet:{actionButtons:on(i.options.messages).group,title:"Group by",ref:"group-view",closeButton:{icon:"check",themeColor:"primary"}},init:function(e){const n=t.wrapper.find(".k-group-menu");n.attr("ref","group-tool"),t._showAdaptiveView?(n.unwrap(),n.removeClass("k-group-menu-md").addClass("k-group-menu-lg")):t.wrapper.removeClass("k-column-menu"),n.find(".k-group-menu-item").on("click"+O,".k-group-menu-item-remove-action, .k-group-menu-item-add-action",(function(e){i._groupItemClickHandler(e,t,{itemTemplate:d,indicator:c})})),i._syncGroupingTool(e,t,i.dataSource.group(),{itemTemplate:d,indicator:c})},closeCallback:function(e){e.removeClass(be);const n=i._toolPopup(t);n.length&&n.find(".k-focus").removeClass("k-focus"),t.element.focus()},contentTemplate:({columns:e})=>{const t=i._isAdaptive();let r="<div class=\"k-group-menu k-group-menu-md\"><div class='k-group-menu-item-wrap'>";return e.forEach((e=>{!Fi(i,e)||e.command||e._originalObject.selectable||(r+=d(e,{icon:"plus-circle",actionClass:"k-group-menu-item-add-action"}))})),r+="</div>",l&&!l.clearButton||t||(r+=`<div class="k-actions k-actions-stretched k-actions-horizontal k-column-menu-footer">\n ${n.html.renderButton(`<button ref="clear-group">${on(i.options.messages).group[0].text}</button>`,{icon:"x"})}\n </div>`),r+="</div>",r}};let h=i.dataSource.group()||[];t=t.kendoColumnMenu(s).data("kendoColumnMenu");const u=function(e){const t=this;const n=e.sender.wrapper&&e.sender.wrapper.find(".k-grid-group-tool")?.data("kendoColumnMenu");const i=e.groups||t.dataSource.group()||[];const r=o(n);const a=h.length>i.length?h:i;t._syncGroupingTool(e,n,a,{itemTemplate:d,indicator:c}),t._toggleBadge(n.element,i.length>0),r?.toggleClass("k-disabled",!i.length),h=i};i.unbind("group",u),i.bind("group",u),t.element.on("click"+O,(function(n){t.popup&&t.popup._closing||e(n.currentTarget).addClass(be)})),t.bind("open",(function(){const e=o(t);e.length&&(e.off("mousedown"+O),e.on("mousedown"+O,(function(){i.dataSource.group([]),i.groupable.trigger(X,{groups:[]}),i._toggleBadge(t.element,!1),e?.toggleClass("k-disabled",!0),t.popup.close()}))),e?.toggleClass("k-disabled",!i.dataSource.group().length)}))},_toggleReorderButtonsDisabledState:function(e,t,n){const i="k-disabled";if(!e.length)return;const r=e.find(".k-group-menu-item-actions .k-group-menu-item-up-action");if(r.length){t&&!r.hasClass(i)?(r.addClass(i),r.attr("aria-disabled",!0)):!t&&r.hasClass(i)&&(r.removeClass(i),r.attr("aria-disabled",!1));const e=r.next();e.length&&(n&&!e.hasClass(i)?(e.addClass(i),e.attr("aria-disabled",!0)):!n&&e.hasClass(i)&&(e.removeClass(i),e.attr("aria-disabled",!1)))}},_syncGroupingTool:function(t,n,i,r){const o=this;const a=t.groups||o.dataSource.group()||[];const s=()=>n._showAdaptiveView?o._toolPopup(n):n.wrapper;const l="k-group-menu-item-wrap";const c=()=>s()?.find(`.${l}`);const d=".k-group-menu-item";const h=s();let u=c();if(n._draggableInstance&&n._triggeredReordering)delete n._triggeredReordering;else if(u&&u.length&&(i.forEach(((t,i)=>{const s=h.find(d+`[data-field='${t.field}']`);const p=s.data("index");const f=s.find(".k-icon")?.attr("class").includes("plus-circle")?"remove":"add";const m="remove"===f;const g=`k-group-menu-item-${f}-action`;const v=s.parent();u=c();let _=!(!a||!a.length)&&a[0]?.field===t.field;let b=!(!a||!a.length)&&a[a.length-1].field===t.field;o._toggleReorderButtonsDisabledState(s,_,b);const w=!a.find((e=>e.field===t.field));if(!w&&v.is("[ref='group-container']"))return;let y;if(u&&2===u.length)y=m?u.first():u.last();else{y=e(`<div class="${l}" ${m?'ref="group-container':""}"></div>`);const t=m?"prepend":"append";const n=u.first().parent();const i=n.find("[ref='clear-group']");i.length&&!m?i.parent().before(y):n.length&&n[t](y)}const k=pi(o.columns)[p];const x=!w&&a.length>1;const C={renderIndicator:x,index:p,isFirstItem:_,isLastItem:b};const S=e(r.itemTemplate(k,{icon:m?"x-circle":"plus-circle",actionClass:g},C));s.remove();if(2===u.length&&!v.children().length&&(v.data("kendoReorderable")&&v.data("kendoReorderable")?.destroy(),v.remove()),m){if(x){const e=y.children().first();1===e.find(".k-group-menu-item-actions")?.length&&e.prepend(r.indicator({isAdaptive:o._isAdaptive(),isFirstItem:!0,isLastItem:!1}))}y.append(S)}else{const e=y.find(d+`[data-index="${p+1}"]`);if(1===a.length){v.children().first().find(".k-group-menu-item-actions:first-of-type").remove()}e.length?e.before(S):y.append(S)}y.find(S).on("click"+O,".k-group-menu-item-remove-action, .k-group-menu-item-add-action",(function(e){o._groupItemClickHandler(e,n)}))})),u=c(),u&&u.length)){const t=u.first().find(".k-group-menu-item-drag-action");const i=u.first().find(".k-group-menu-item-up-action, .k-group-menu-item-down-action");const r=u.first();const a=r.is("[ref='group-container']")&&r?.length;const s=t.length;const l=i.length;a&&l?i.each((function(){const t=e(this);t.unbind("click"+O),t.bind("click"+O,(e=>o._buttonClickReorderHandler(e,n)))})):a&&s&&(o._groupToolDraggableInstance(n,r),o._groupToolReorderableInstance(n,r))}},_buttonClickReorderHandler:function(t,n){t.preventDefault(),t.stopPropagation();const i=".k-group-menu-item";const r=e(t.currentTarget);const o=r.closest(i);const a=r.hasClass("k-group-menu-item-up-action")?"before":"after";const s="before"===a?o.prev(i):o.next(i);const l={element:o,target:s,position:a};this._handleGroupReordering(l,n)},_groupToolDraggableInstance:function(t,i){const r=this._isMobile;t._draggableInstance=i.kendoDraggable({holdToDrag:r,showHintOnHold:r,preventOsHoldFeatures:r,group:"group-item-draggable",autoScroll:!0,filter:".k-group-menu-item-drag-action",hint:function(t){return e('<div class="k-reorder-clue k-drag-clue">'+n.ui.icon({icon:"cancel",iconClass:"k-drag-status"})+"</div>")},clickMoveClick:!1,cursorOffset:{top:0,left:0}}).data("kendoDraggable")},_groupToolReorderableInstance:function(t,n){const i=this;const r=".k-group-menu-item";n&&n.data("kendoReorderable")&&n.data("kendoReorderable").destroy(),n.kendoReorderable({smartPosition:!1,draggable:t._draggableInstance,dragOverContainers:function(t,n){e(r).eq(n);return!0},dropFilter:"> "+r,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){e.css({transform:"translate(0,-50%)"})},externalDraggable:function(e){var t=e.draggable;if(t)return t},change:function(e){i._handleGroupReordering(e,t)}})},_handleGroupReordering:function(t,n){const i=t.element;const r=t.target;const o="before"===t.position?"insertBefore":"insertAfter";const a=this.groupable.descriptors();i[o](r);const s=i.parent().children();const l=[];for(let t=0;t<s.length;t++){const n=e(s[t]).data("field");const i=a.find((e=>e.field===n));i&&l.push(i)}n._triggeredReordering=!0,this.dataSource.group(l),this.groupable.trigger(X,{groups:l})},_groupItemClickHandler:function(t,n){const i=this;const r=e(t.currentTarget).closest(".k-group-menu-item");const o="remove"===(e(t.currentTarget).find(".k-icon")?.attr("class").includes("plus-circle")?"remove":"add");const a=r.data("index");let s=i.groupable.descriptors();s.length||(s=i.dataSource.group());const l=pi(i.columns)[a];o?s.push({field:l.field,dir:"asc",aggregates:i.groupable.aggregates()||[],colID:l.uid,compare:l.sortable&&l.sortable.compare||i.groupable.sort&&i.groupable.sort.compare}):s=s.filter((e=>e.field!==l.field)),i.dataSource.group(s),i.groupable.trigger(X,{groups:s})},_sortToolbarTool:function(i){const r=this;const o=r.options;const a="k-columnmenu-indicators";const s=r._isAdaptive();const l=e=>{const t=r._isAdaptive()?"[ref-actionsheet-action-button]:not('.k-button-solid-primary')":"[ref='clear-sort']";return r._toolPopup(e)?.find(t)};let c;let d;const h=r._toolbarOptionsForTool("sort");c=i.data("kendoColumnMenu"),c&&(c.wrapper.off("click"+O),c.element.off("click"+O),c.destroy());const u=!1!==o.columnMenu.sortable&&!1!==o.sortable&&f({},o.sortable,{allowUnsort:!1});if(!u)return;d={dataSource:r.dataSource,columns:!1,sortable:u,filterable:!1,hideAutoSizeColumn:!0,owner:r,adaptiveMode:r.options.adaptiveMode,encodeTitles:r.options.encodeTitles,componentType:"modern",_actionsheet:{actionButtons:on(r.options.messages).sort,title:"Sort by",ref:"sort-view",closeButton:{icon:"check",themeColor:"primary"}},init:function(e){i.wrapper.attr("ref","sort-tool")},closeCallback:function(e){e.removeClass(be);const t=r._toolPopup(i);t.length&&t.find(".k-focus").removeClass("k-focus"),i.element.focus()},sort:function(e){const t=e.preventClose;i._preventClose="multiple"===r.options.sortable.mode||t,r.trigger("sort",{sort:e.sort})?e.preventDefault():(r._clearEditableState(),r.dataSource.options.endless&&r._resetEndless())},contentTemplate:function({columns:e,isAdaptive:t}){let i='<div class="k-columnmenu-item-wrapper">';return e.forEach((e=>{!1===e.sortable||e.command||e._originalObject.draggable||e._originalObject.selectable||(i+=`<div class="k-columnmenu-item" tabindex="0" data-field="${e.field}">${e.title||e.field||""}</div>`)})),i+="</div>",h&&!h.clearButton||t||(i+='<div class="k-actions k-actions-stretched k-actions-horizontal k-column-menu-footer">',i+=n.html.renderButton(`<button ref="clear-sort">${on(r.options.messages).sort[0].text}</button>`,{icon:"x"}),i+="</div>"),i}},i=i.kendoColumnMenu(d).data("kendoColumnMenu");const p=function(e){const n=e.sender.wrapper&&e.sender.wrapper.find(".k-grid-sort-tool")?.data("kendoColumnMenu");const i=e.sender.dataSource._sortFields;const o=Array.isArray(e.sort);const s=e.sort.field;const c=e.sender.options.sortable&&("multiple"===e.sender.options.sortable.mode||"mixed"===e.sender.options.sortable.mode);let d;let h=e.sort.dir===t;d=o?e.sort.length:i&&Object.keys(i).length?!h||h&&Object.keys(i).length-1>0:!h,r._toggleBadge(n.element,d);const u=n.wrapper.find(`.k-columnmenu-item[data-field='${s}']`);let p=u.find("."+a);h?p.remove():(c||(p=n.wrapper.find("."+a)),p.length&&p.remove(),u.append(r._renderIndicator(`sort-${e.sort.dir}-small`))),l(n)?.toggleClass("k-disabled",!d)};r.unbind("sort",p),r.bind("sort",p),i.bind("open",(function(){const t=r._toolPopup(i);if(t.length){t.focus();const n=l(i);const o=t.find(".k-columnmenu-item");n.length&&(n.off("mousedown"+O),n.on("mousedown"+O,(function(){r.dataSource.sort([]),r._toggleBadge(i.element,!1),l(i)?.toggleClass("k-disabled",!0),i.wrapper.find(".k-columnmenu-indicators").remove(),i.close()}))),o.length&&(t.off("click"+O),t.on("click"+O,".k-columnmenu-item",(function(t){const n=e(t.currentTarget);const o=n.data("field");const s=r._toggleColumnMenuSortIndicator(n);const l=r.options.sortable&&"mixed"===r.options.sortable.mode;const c=t.originalEvent.ctrlKey;i.field=o,i._sortHandler({item:n,allowUnsort:s,allowSelectedState:!1,isMixed:l,hasCtrlKey:c}),r._toggleSortIndexes(r.dataSource._sortFields&&Object.keys(r.dataSource._sortFields).length>1,i,a)})))}})),i.element.on("click"+O,(function(t){if(i.popup&&i.popup._closing)return;e(t.currentTarget).addClass(be);const n=i.dataSource._sortFields;const o=n&&Object.keys(n).length;const c=Object.keys(n).length>1;o&&Object.keys(n).forEach((e=>{const t=i.wrapper.find(`.k-columnmenu-item[data-field='${e}']`);const o=t.find("."+a);o.length&&o.remove(),t.append(r._renderIndicator(`sort-${n[e].dir}-small`))})),r._toggleSortIndexes(c,i,a,s),l(i)?.toggleClass("k-disabled",!o)}))},_toggleSortIndexes:function(t,n,i){if(!(this.options.sortable&&this.options.sortable.showIndexes))return;const r=n.wrapper.find(`.${i}`);let o=n.dataSource&&n.dataSource._sortFields;r.length&&(t?r.each(((t,n)=>{const i=e(n).closest(".k-columnmenu-item").data("field");const r=o[i];const a=e(n).parent().find(".k-sort-index");a.length?a.text(r.index):r.index?e(n).append(`<span class='k-sort-index'>${r.index}</span>`):e(n).append(`<span class='k-sort-index'>${t+1}</span>`)})):n.wrapper.find(".k-sort-index").remove())},_columnChooserTool:function(t){const n=this;const i="column-chooser";const r=t.data("kendoColumnMenu");r&&(r.wrapper.off("click"+O),r.element.off("click"+O),r.destroy());const o={dataSource:n.dataSource,columns:n.columns,sortable:!1,filterable:!1,hideAutoSizeColumn:!0,owner:n,adaptiveMode:n.options.adaptiveMode,encodeTitles:n.options.encodeTitles,messages:{reset:n.options.messages.clearButtons?n.options.messages.clearButtons.columnChooserReset:"Reset",apply:n.options.messages.applyButtons?n.options.messages.applyButtons.columnChooserApply:"Apply"},componentType:"modern",contentTemplate:function(e){return(0,e._defaultContents()[i])(e)},_actionsheet:{actionButtons:on(n.options.messages)[i],title:"Column visibility",subtitle:"Selected fields are visible",closeButton:!0,ref:`${i}-view`},init:function(e){t.wrapper.attr("ref",i+"-tool"),t._showAdaptiveView?t.popup._content.find(`[ref='${i}']`).unwrap():t.wrapper.removeClass("k-column-menu")},closeCallback:function(e){e.removeClass(be);const i=n._toolPopup(t);i.length&&i.find(".k-focus").removeClass("k-focus"),t&&t._showAdaptiveView&&t._applyColumnVisibility(),t.element.focus()}};(t=t.kendoColumnMenu(o).data("kendoColumnMenu")).element.bind("click",(function(n){t.popup&&t.popup._closing||e(n.currentTarget).addClass(be)})),t.bind("open",(function(){const e=n._toolPopup(t);e.length&&e.find(".k-checkbox")?.first()?.focus()}))},_toggleBadge:function(t,n){const i=t.closest(".k-badge-container");const r=i.length&&i.find(".k-badge");const o=t.data("overflow");if(!r.length&&n){t.wrap(`<div class='k-badge-container' ${o?"data-overflow="+o:""}></div>`).parent().append(e("<span></span>").kendoBadge({round:"full",position:"edge",align:"top end",themeColor:"primary",cutoutBorder:!0}))}else!n&&r.length&&(r.remove(),t.unwrap(".k-badge-container"))},_toggleColumnMenuFilterIndicator:function(e,t){const n=this;const i=e.find(".k-columnmenu-indicators");const r=e.find(".k-spacer");if(t&&r.length){if(i&&i.length)return;r.before(n._renderIndicator("filter"))}else i&&i.length&&i.remove()},_toggleColumnMenuSortIndicator:function(e){const t=this;const n=e.find(".k-columnmenu-indicators");let i;let r=e.find(".k-sort-index").length?"before":"append";if(n&&n.length){const e=n.find(".k-icon");e.length&&e.hasClass("k-svg-i-sort-desc-small")?(n.remove(),i=!0):(e.remove(),n[r](t._renderIndicator("sort-desc-small")),i=!1)}else e[r](t._renderIndicator("sort-asc-small")),i=!1;return i},_renderIndicator:function(t){return e("<span class='k-columnmenu-indicators'></span>").append(n.ui.icon(e("<span></span>"),{icon:t}))},_globalColumnsMenu:function(e){var t,n,i=this,r=pi(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._isAdaptive()&&e.sender.popup.wrapper.find(".k-expanded [ref=columns-visibility]").data("handler").toggle(!1),i.trigger(q,{field:e.field,container:e.container})},open:function(e){i.trigger(K,{field:e.field,container:e.container})},pane:"auto"!==i.options.adaptiveMode&&i.pane,autoSize:o.autoSize,encodeTitles:i.options.encodeTitles,componentType:"modern",adaptiveMode:"auto",columnsExpanderOptions:s},e.kendoColumnMenu(n)}},_columnMenu:function(){var e,i,r,o,a,s,l=this,c=pi(l.columns),d=l.options,h=d.columnMenu,u=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(q,{field:e.field,container:e.container})},b=function(e){l.trigger(K,{field:e.field,container:e.container})},w=function(){Ri(l.table,!0)},y=function(e){l.trigger(Ue,{column:e.column})},k=function(e){l.trigger(We,{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(h&&!l._isStackedMode()){"boolean"==typeof h&&(h={}),l._setColumnsMediaVisibility(c);for(var T=0,M=(s=_i(l.thead)).length;T<M;T++){i=c[T];var A=s.eq(T);if(!1!==i.columnMenu&&!i.command&&(i.field||A.attr("data-"+n.ns+"field"))){(e=A.data("kendoColumnMenu"))&&e.destroy(),o=!1!==i.sortable&&!1!==h.sortable&&!1!==d.sortable&&f({},d.sortable,{compare:(i.sortable||{}).compare}),a=!(!d.filterable||!1===i.filterable||!1===h.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);const t="auto"!==l.options.adaptiveMode&&h.adaptiveMode||l.options.adaptiveMode;r={dataSource:l.dataSource,values:i.values,columns:h.columns,sortable:o,filterable:a,messages:h.messages,owner:l,adaptiveMode:t,adaptiveTitle:i.title||i.field,closeCallback:w,init:_,open:b,stick:y,unstick:k,pane:"auto"!==l.options.adaptiveMode&&l.pane,sort:x,filtering:C,filter:v?":not(.k-column-active)":"",autoSize:h.autoSize,hasLockableColumns:ri(c).length>0&&p&&!u,hasStickableColumns:m&&!u,encodeTitles:l.options.encodeTitles,componentType:h.componentType,appendTo:S+Zt,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!=ot||-1!=e.mode.indexOf("menu"))&&e},_filterable:function(){var e,t,i,r=this,o=pi(r.columns),a=function(e){r.trigger(j,{field:e.field,container:e.container})},s=function(){Ri(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(G,{field:e.field,container:e.container})},d=r._hasFilterMenu();if(d&&!r.options.columnMenu&&!r._isStackedMode())for(var h=0,u=(t=_i(r.thead)).length;h<u;h++)if(i=t.eq(h),!1!==o[h].filterable&&!o[h].command&&(o[h].field||i.attr("data-"+n.ns+"field"))){(e=i.data("kendoFilterMenu"))&&e.destroy(),(e=i.data("kendoFilterMultiCheck"))&&e.destroy();var p=o[h].filterable;var m=f({},d,p,{dataSource:r.dataSource,values:o[h].values,format:o[h].format,closeCallback:s,title:o[h].title||o[h].field,init:a,open:c,pane:r.pane,change:l,appendTo:S+Zt,adaptiveMode:r.options.adaptiveMode});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;var o=pi(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,h=o[c],u=t.options.filterable.operators,p=!1,m=e("<td class='k-table-td' title='"+t.options.messages.filterCellTitle+"'/>"),g=h.field;if(h.hidden&&m.hide(),s.append(m),g&&!1!==h.filterable){var v=h.filterable&&h.filterable.cell||{};(d=t.options.dataSource)instanceof r&&(d=t.options.dataSource.options);var _=f(!0,{},a.messages);if(h.filterable&&f(!0,_,h.filterable.messages),!1===v.enabled){m.html(" ");continue}v.dataSource&&(d=v.dataSource,p=!0),h.filterable&&h.filterable.operators&&(u=h.filterable.operators),i={column:h,dataSource:t.dataSource,suggestDataSource:d,customDataSource:p,field:g,messages:_,size:t.options.size,values:h.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:l,adaptiveMode:t.options.adaptiveMode},e("<span/>").attr(n.attr("field"),g).appendTo(m).kendoFilterCell(i)}else m.html(" ");m.data("column",h)}this._filterFocusable().attr(it,-1)}},_sortable:function(){var e,t,i,r=this,o=pi(r.columns),a=r.options.sortable,s=function(e){r.trigger("sort",{sort:e.sort})?e.preventDefault():r._clearEditableState()};if(a&&!r._isStackedMode()){var l=_i(r.thead);for(var 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")),h=t.attr(n.attr("column-menu")),u=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"!==u,columnMenu:"false"!==h,template:t.attr(n.attr("template")),width:l.eq(i).css(tt)}})),i=!(a.table.find("tbody tr").length>0&&(!d||!d.transport)),a.options.scrollable&&!a._isStackedMode()){var h=t;if(r=ri(t),t=oi(t),r.length>0&&0===t.length)throw new Error("There should be at least one non locked column");!function(e,t){var n=0;var i,r;var o=e.find("th:not(.k-group-cell)");for(i=0,r=t.length;i<r;i++)t[i].locked&&(o.eq(i).insertBefore(o.eq(n)),o=e.find("th:not(.k-group-cell)"),n++)}(a.element.find("tr:has(th)").first(),h),t=r.concat(t)}if(c.length&&t.length&&a._updateColumnIDs(t,c.first()),a.columns=yn(t,i),e.grep(pi(a.columns),(function(e){return e.selectable})).length&&(a._selectedIds={},a._checkBoxSelection=!0,a.wrapper.on(Ge+O,"tbody > tr "+ye,a._checkboxClick.bind(a)),a.wrapper.on(Ge+O,"thead > tr "+ye,a._headerCheckboxClick.bind(a))),(o=e.grep(pi(a.columns),(function(e){return e.draggable}))).length){a._hasDragHandleColumn=!0;for(var u=0;u<o.length;u++)o[u].headerAttributes=e.extend({"aria-label":a.options.messages.dragHandleLabel},o[u].headerAttributes)}a._foreignKeyBindings(Kn(a.columns))},_foreignKeyBindings:function(e){var t=e.length;var n;for(var i=0;i<t;i++)(n=e[i]).dataSource&&this._fetchForeignKeyValues(n)},_fetchForeignKeyValues:function(t){var n=this;var 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){var n=t.find("th:not(.k-group-cell):not(.k-hierarchy-cell)");var i;for(var r=0;r<e.length;r++)(i=n.eq(r).attr(vt))&&(e[r].headerAttributes=f(e[r].headerAttributes,{id:i}));this._updateColumnIDs(hi(e),t.next())}},_headerCheckboxClick:function(t){var n=this,i=e(t.target),r=i.prop("checked");n._belongsToGrid(i)&&(n.trigger(Q,{target:i,originalEvent:t})?t.preventDefault():(r?n.select(n.items()):n.clearSelection(),n._calculateAggregatesForSelected(),n.trigger(X,{cellAggregates:n._cellAggregates})))},_checkboxClick:function(t){var n=this,i=e(t.target).closest(bt),r=!i.hasClass(be);n._belongsToGrid(i)&&(n.trigger(Q,{target:i,originalEvent:t})?t.preventDefault():(r?n.select(i):n._deselectCheckRows(i),n._calculateAggregatesForSelected(),n.trigger(X,{cellAggregates:n._cellAggregates})))},_groups:function(){var e=this.dataSource.group();return e?e.length:0},_getStackedLayoutSettings:function(){const e=this.options.stackedLayoutSettings;const t=e&&e.cols;let n=[];let i="";if(t)if(Array.isArray(t))for(let e=0;e<t.length;e++)if("object"==typeof t[e]){const i=t[e].width;if(!i&&0!==i)continue;"number"==typeof i&&n.push(`${i}px`),"string"==typeof i&&n.push(i)}else"number"==typeof t[e]?n.push(`${t[e]}px`):"string"==typeof t[e]&&n.push(t[e]);else"number"==typeof t&&(i=`k-grid-cols-${t}`);return{colClass:i,colsConfig:n.join(" ")}},_tmpl:function(t,i,r,o){var a,s,l=this,c=f({},n.Template,l.options.templateSettings),d=i.length,h={storage:{},count:0},u=l._hasDetails(),p=l._groups();var m=n.attr("field");var g;var v;var _;let b;return t||(b=t=>{var c=d?` ${n.attr("uid")}="${n.getter("uid")(t)}"`:"";var b=`<tr class="${r?"k-table-row k-table-alt-row ":"k-table-row "}k-master-row"${c}>`;for(p>0&&!o&&(b+=hn(p)),u&&(b+='<td class="k-hierarchy-cell k-table-td" aria-expanded="false">'+n.ui.icon(e(`<a href="#" ${yt}="${gt}" tabindex="-1"></a>`),{icon:"caret-alt-"+(qt?"left":"right")})+"</td>"),a=0;a<d;a++){let e;s=i[a],s.template,g=s.field,_={},l._editMode()&&g&&(s.attributes=s.attributes||{},l.virtualScroll&&(s.attributes[m]=g),e=l._dirtyCellTemplate(g)(t)),s.colSpan&&s.colSpan>0&&xi(s.attributes)?s.attributes=Ci(s.attributes):!s.colSpan&&s.hidden&&(s.attributes=ki(s.attributes)),s.command&&(s.attributes=s.attributes||{},void 0!==(v=s.attributes.class)?v.indexOf("k-command-cell")<0&&(s.attributes.class+=" k-command-cell "):s.attributes.class=" k-command-cell "),s.draggable&&(s.attributes=s.attributes||{},void 0!==s.attributes.class?s.attributes.class.indexOf("k-drag-cell")<0&&(s.attributes.class+=" k-drag-cell "):s.attributes.class=" k-drag-cell ",s.attributes["ref-grid-drag-cell"]||(s.attributes["ref-grid-drag-cell"]=!0),void 0===s.attributes[yt]&&(s.attributes[yt]=l.options.messages.dragHandleLabel),void 0!==s.attributes.style?s.attributes.style.indexOf("cursor: move;")<0&&(s.attributes.style+=" cursor: move;"):s.attributes.style="cursor: move;"),s._attributesFunction&&(_=s._attributesFunction(t));let r=f({},s.attributes,_);e&&(r.class=r.class||"",r.class+=e);let o=un(r);let c="";s.colSpan&&(s.colSpan>1&&(c+=" "+n.attr("virtual")),c+=` colSpan="${s.colSpan}"`),b+=Un(`<td${o}${c}>`),b+=s.selectable?n.template($t)({size:n.getValidCssClass("k-checkbox-","size",l.options.size)}):l._cellTmpl(s,h)(t),b+="</td>"}return b+="</tr>"},l._isStackedMode()&&(b=e=>{i=pi(Pn(i));var t=(d=i.length)?` ${n.attr("uid")}="${n.getter("uid")(e)}"`:"";var c=`<tr class="${r?"k-table-row k-table-alt-row ":"k-table-row "}k-master-row"${t}>`;for(p>0&&!o&&(c+=hn(p)),c+='<td class="k-table-td">\n <div class="k-grid-stack-row">\n ',a=0;a<d;a++){s=i[a],s.template,g=s.field,_={};let t;if(p>0&&l.dataSource.group().find((e=>e.field===g))&&s.hideOnGroup)continue;l._editMode()&&g&&(s.attributes=s.attributes||{},l.virtualScroll&&(s.attributes[m]=g),t=l._dirtyCellTemplate(g)(e)),s.colSpan&&s.colSpan>0&&xi(s.attributes)?s.attributes=Ci(s.attributes):!s.colSpan&&s.hidden&&(s.attributes=ki(s.attributes)),s.attributes.class="k-grid-stack-cell",s.title&&(s.attributes[n.attr("title")]=s.title),s.aggregates&&(s.attributes[n.attr("aggregates")]=s.aggregates);let r=!s.selectable;let o=!s.selectable;s.command&&(s.attributes=s.attributes||{},void 0!==(v=s.attributes.class)?v.indexOf("k-command-cell")<0&&(s.attributes.class+=" k-command-cell"):s.attributes.class="k-command-cell",o=s.title&&" "!==s.title,r=!0),s.draggable&&(o=!1,r=!0,s.attributes=s.attributes||{},void 0!==s.attributes.class?s.attributes.class.indexOf("k-drag-cell")<0&&(s.attributes.class+=" k-drag-cell"):s.attributes.class="k-drag-cell",s.attributes["ref-grid-drag-cell"]||(s.attributes["ref-grid-drag-cell"]=!0),void 0===s.attributes[yt]&&(s.attributes[yt]=l.options.messages.dragHandleLabel),void 0!==s.attributes.style?s.attributes.style.indexOf("cursor: move;")<0&&(s.attributes.style+=" cursor: move;"):s.attributes.style="cursor: move;"),s._attributesFunction&&(_=s._attributesFunction(e));let d=f({},s.attributes,_);t&&(d.class=d.class||"",d.class+=t);let u=un(d);let b="";s.colSpan&&(s.colSpan>1&&(b+=" "+n.attr("virtual")),b+=` colSpan="${s.colSpan}"`);const w=s.parentIds?gi(l,s):s.title||s.field||"";c+=Un(`<div${u}${b} ${s.field?`data-field=${s.field}`:""} data-index=${a}>`,!0),o&&(c+=`<div class="k-grid-stack-header">${w}</div>`),r&&(c+='<div class="k-grid-stack-content">'),c+=s.selectable?n.template($t)({size:n.getValidCssClass("k-checkbox-","size",l.options.size)}):l._cellTmpl(s,h)(e),r&&(c+="</div>"),c+="</div>"}return u&&(c+=`<div class="k-grid-stack-cell">\n <div class="k-grid-stack-content">\n ${n.html.renderButton(`<button tabindex='-1' ref="expand-detail-button">${l.options.messages.details.expand}</button>`,{icon:"plus",fillMode:"flat",themeColor:"primary"})}\n </div>\n </div>`),c+="</div></td></tr>"})),t=n.template(t||b,c),h.count>0?t.bind(h.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?Yi(e.title):e.title)||Yi(e.field||"");return r===rt?o=n.template(i,t)({}):r===ot&&(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,h=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?$t:e.draggable?Wt:i=>{let r=o._dirtyIndicatorTemplate(l)(i);if(d===rt)t.storage["tmpl"+t.count]=s,r+=s(i),t.count++;else if(d===ot)r+=n.template(s,a)(i);else if(h&&h.length&&p(h[0])&&"value"in h[0]&&l){var u=Ti(h)[a.useWithBlock?n.getter(l)(i):l];r+=y(null!=u?u:"")}else{let t="";l&&(t=null==(l=n.getter(l)(i))?"":l),c&&(t=n.format(c.replace(Ht,"$1"),t)),r+=e.encoded?y(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=this;var r=e.map(t,(function(e){return e.hidden?0:parseInt(e.width,10)}));var o=i.virtualScrollable?n.scrollLeft(i.content.find(">.k-virtual-scrollable-wrap")):n.scrollLeft(i.content);var a=c(i.content);var s=Qn(t);var l=[];var d=0;var h=0;var u=0;var p=0;var f=0;var m;for(p=0;p<t.length;p++){if(m=p<r.length-1?r[p+1]:0,!(f+r[p]+2*m<o)){d=1+u;break}r[p]&&u++,f+=r[p]}u=0,f=0;for(var g=t.length-1;g>=0;g--){if(!(f+3*r[g]<s-a-o)){h=1+u;for(var v=p;v<=g;v++)t[v].locked||(l.push(t[v]),t[v].colSpan&&delete t[v].colSpan);l[0].colSpan=d,l[l.length-1].colSpan=h;break}r[g]&&u++,f+=r[g]}return l[0].hidden&&l[0].colSpan--,i.virtualCols=l,l},_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=t._isStackedMode(),l=pi(t.columns),c=pi(ri(t.columns)),d=n.scrollable?pi(oi(t.columns)):l,h=(t.virtualScroll||{}).columns?t._virtualCols(d):d,u=g(Pn(c),(function(e,t){return e.groupHeaderColumnTemplate&&0!==t})),p=g(Pn(h),(function(e){return e.groupHeaderColumnTemplate}));if(n.scrollable&&c.length&&!s){if(n.rowTemplate||n.altRowTemplate)throw new Error("Having both row template and locked columns is not supported");t.rowTemplate=t._tmpl(n.rowTemplate,h,!1,!0),t.altRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,h,!0,!0),t.lockedRowTemplate=t._tmpl(n.rowTemplate,c),t.lockedAltRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,c,!0)}else t.rowTemplate=t._tmpl(n.rowTemplate,s?t.columns:h),t.altRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,s?t.columns:h,!0);t._hasDetails()&&(t.detailTemplate=t._detailTmpl(n.detailTemplate||(()=>""))),(t._group&&!k(a)||!k(a)&&!o.length||g(l,(function(e){return e.footerTemplate})).length)&&(t.footerTemplate=t._footerTmpl(l,a,"footerTemplate","k-footer-template k-table-row")),r&&g(l,(function(e){return e.groupFooterTemplate})).length&&(a=e.map(r,(function(e){return e.aggregates})),t.groupFooterTemplate=t._footerTmpl(h,a,"groupFooterTemplate","k-group-footer k-table-row",c.length),n.scrollable&&c.length&&(t.lockedGroupFooterTemplate=t._footerTmpl(c,a,"groupFooterTemplate","k-group-footer k-table-row"))),r&&(u.length||p.length)?(a=e.map(r,(function(e){return e.aggregates})),t.groupHeaderColumnTemplate=t._groupHeaderTmpl(Pn(h),a,"groupHeaderColumnTemplate","k-table-group-row k-grouping-row k-table-row",c.length,p),n.scrollable&&c.length&&(t.lockedGroupHeaderColumnTemplate=t._groupHeaderTmpl(Pn(c),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='<div class="{0}">{1}</div>';var i=this.options.scrollable&&!this.wrapper[0].style.height?` ${n.attr("style-margin")}="0 auto" ${n.attr("style-position")}="static"`:"";var r={storage:{},count:0};var o=e.extend({},n.Template,this.options.templateSettings);o.paramName;var a;var s;var l;let c;if("function"===(s=typeof(a=this.options.noRecords.template?this.options.noRecords.template:n.format('<div class="k-grid-norecords-template"{1}>{0}</div>',this.options.messages.noRecords,i)))){let e=r.storage["tmpl"+r.count]=a;r.count++,c=i=>n.format(t,ke,e(i))}else"string"===s&&(c=this.options.noRecords.template?n.format(t,ke,a):()=>n.format(t,ke,a));return l=n.template(c,o),r.count>0&&(l=l.bind(r.storage)),l},_footerTmpl:function(e,t,i,r,o){var a,s,l,c,d,h=this,u=f({},n.Template,h.options.templateSettings),p=u.paramName,m={},g=0,v={},_=h._groups(),b=h.dataSource._emptyAggregates(t);const w=h._isStackedMode();let y=n.template((t=>{let y='<tr class="'+r+'">';_>0&&!o&&(y+=hn(_)),h._hasDetails()&&!w&&(y+='<td class="k-hierarchy-cell k-table-td"> </td>');const k=e;if(w){for(y+=Un("<td>"),y+=`<div class="${Be}">`,a=0,s=k.length;a<s;a++)d=k[a],l=d[i],c=typeof l,l&&(c!==rt&&(v=b[d.field]?f({},u,{paramName:p+"['"+d.field+"']"}):{},l=n.template(l,v)),m["tmpl"+g]=l,y+=l(t),g++);y+="</div></td>"}else for(a=0,s=k.length;a<s;a++)d=k[a],l=d[i],c=typeof l,y+=Un("<td"+un(d.footerAttributes)+">"),l?(c!==rt&&(v=b[d.field]?f({},u,{paramName:p+"['"+d.field+"']"}):{},l=n.template(l,v)),m["tmpl"+g]=l,y+=l(t),g++):y+=" ",y+="</td>";return y+="</tr>",y}),u);return g>0?y.bind(m):y},_groupHeaderTmpl:function(e,t,i,r,o,a){var s,l,c,d,h,u,m=this,g=f({},n.Template,m.options.templateSettings),v=g.paramName,b="",w={},y=0,k={},x=m.dataSource._emptyAggregates(t),C=a.length?_(a[0],e):-1;if(C<0)return;const S=m._isStackedMode();return b=n.template((t=>{let _="";var b='<tr data-group-uid="'+t.uid+'" class="'+r+'">';if(!o)for(var T=0;T<t.groupCells;T++)b+='<td class="k-table-td k-group-cell"> </td>';const M=e;if(S){for(_+=`<div class="${Be}">`,s=C,l=M.length;s<l;s++)h=M[s],c=h[i],d=typeof c,c&&(d!==rt&&(k=x[h.field]?f({},g,{paramName:v+"['"+h.field+"']"}):{},c=n.template(c,k)),w["tmpl"+y]=c,_+=w["tmpl"+y](t),y++);_+="</div>"}if(m._hasDetails()&&!S&&(b+='<td class="k-table-td k-hierarchy-cell"> </td>'),C<1&&a.length<=1&&!o)return b+=o?"":qi(M.length,S,_)(t);if(C<1?(C=o?0:1,b+=o?"":qi(C,S,_)(t)):b+=o?function(e){return'<td class="k-table-td" colspan="'+e+'">'+`<p class="k-reset"> </p></td>${new Array(e).join("<td hidden group-header-spanned-hidden></td>")}`}(C):qi(C,S,_)(t),!S)for(s=C,l=M.length;s<l;s++){if(h=M[s],c=h[i],d=typeof c,h.sticky){let e="";if((u=h.groupHeaderColumnTemplateClass||"")||(u=h.groupHeaderColumnTemplateClass="group-header-column-template-"+n.guid()),p(h.stickyStyle)){e=`${h.stickyStyle.left?`${n.attr("style-left")}="${h.stickyStyle.left}"`:""} ${h.stickyStyle.right?`${n.attr("style-right")}="${h.stickyStyle.right}"`:""}`}b+=`<td class="k-table-td ${Ie} ${u}" ${e}>`}else b+="<td class='k-table-td'>";c?(d!==rt&&(k=x[h.field]?f({},g,{paramName:v+"['"+h.field+"']"}):{},c=n.template(c,k)),w["tmpl"+y]=c,b+=w["tmpl"+y](t),y++):b+=" ",b+="</td>"}return b+="</tr>"}),g),y>0?b.bind(w):b},_detailTmpl:function(e){var t=this,i=f({},n.Template,t.options.templateSettings),r=(i.paramName,{}),o=0,a=t._groups(),s=t._isStackedMode(),l=s?t.table.find("col").length:Pn(pi(t.columns)).length,c=typeof e;let d=n.template((t=>{let d='<tr role="row" class="k-detail-row k-table-row">';return a>0&&(d+=hn(a)),s||(d+='<td role="gridcell" class="k-hierarchy-cell k-table-td"></td>'),d+=`<td role="gridcell" class="k-detail-cell k-table-td" ${l?` colspan="${l}"`:""}>`,c===rt?(r["tmpl"+o]=e,d+=e(t),o++):d+=n.template(e,i)(t),d+="</td></tr>",d}),i);return o>0?d.bind(r):d},_hasDetails:function(){return null!==this.options.detailTemplate||(this._events[W]||[]).length},_hasFilterRow:function(){var t=this.options.filterable;var n=t&&typeof t.mode==ot&&-1!=t.mode.indexOf(zt);var i=this.columns;var r=e.grep(i,(function(e){return!1===e.filterable}));return(this._isStackedMode()||i.length&&r.length==i.length)&&(n=!1),n},_details:function(){var t=this;if(t.options.scrollable&&t._hasDetails()&&ri(t.columns).length)throw new Error("Having both detail template and locked columns is not supported");const n=t._isStackedMode();const i=n?'[ref="expand-detail-button"], [ref="collapse-detail-button"]':".k-hierarchy-cell "+H+", .k-hierarchy-cell "+B;t.table.on(Ge+O,i,(function(i){var r=e(this);return n?t._toggleStackedDetails(r):t._toggleDetails(r),i.preventDefault(),!1}))},_setCurrentStackedCell:function(t){const n=this;const i=t?e(t).closest(bt).index():n._currentRowIndex;const r=n._currentStackedCell();if(r&&n.options.navigatable&&i>=0){let e;let t=r&&r.index;e=n.table.find(`${bt}:eq(${i}) .k-grid-stack-cell`).eq(t),e.length&&("-1"!==e.attr("tabindex")&&e.attr("tabindex")||Sn(e.parent().children()),n._currentStackedCell(e,!0))}},_toggleStackedDetails:function(e,t){const i=this;const r=e.closest(".k-grid-stack-cell");const o=r.find(".k-grid-stack-content");const a=e.is('[ref="expand-detail-button"]');const s=e.closest("tr.k-master-row");const l=a?mt:gt;let c;e.remove(),c=a?n.html.renderButton(`<button tabindex='-1' ref="collapse-detail-button" aria-label=${l}>${n.htmlEncode(i.options.messages.details.collapse)}</button>`,{icon:"minus",fillMode:"flat",themeColor:"primary"}):n.html.renderButton(`<button tabindex='-1' ref="expand-detail-button" aria-label=${l}>${n.htmlEncode(i.options.messages.details.expand)}</button>`,{icon:"plus",fillMode:"flat",themeColor:"primary"}),o.append(c),i._addDetailRow(s,a,t),i._setCurrentStackedCell(r)},_addDetailRow:function(t,n,i){const r=this;const o=r.detailTemplate;const a=t.attr(Tt);const s=r._hasDetails();let l=t.next();let c;var d;l.hasClass("k-hidden")&&l.removeClass("k-hidden"),s&&!l.hasClass("k-detail-row")&&(c=r.dataItem(t),l=e(o(c)).addClass(t.hasClass("k-table-alt-row")?"k-table-alt-row":"").insertAfter(t),(a||0===a)&&l.attr(Tt,Number(a)+1),r.trigger(W,{masterRow:t,detailRow:l,data:c,detailCell:l.find(".k-detail-cell")})),r.trigger(n?ne:ie,{masterRow:t,detailRow:l}),i?(d=n,e(l)[0].style.display=d?"":It):l.toggle(n)},_toggleDetails:function(e,t){var i=e.closest("td.k-hierarchy-cell"),r=e.is(H),o=e.closest("tr.k-master-row"),a=r?mt:gt,s=r?"true":"false";r?n.ui.icon(e,{icon:"caret-alt-down"}):n.ui.icon(e,{icon:"caret-alt-"+(qt?"left":"right")}),e.attr(yt,a),i.attr(Mt,s),this._addDetailRow(o,r,t)},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 "+H);i.length&&this._toggleDetails(i,n)},collapseRow:function(t,n){var i=e(t).find("> td "+B);i.length&&this._toggleDetails(i,n)},_createHeaderCells:function(i,r){var o,a,s,l,c,d,h=this,u="",p=h.options.columnMenu,f=(h.options.sortable,h._hasFilterMenu()),m=h.options.messages,g=pi(h.columns),v=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,g);let b="";a.selectable?(b+="<th scope='col'"+un(a.headerAttributes),r&&!i[o].colSpan&&(b+=" rowspan='"+r+"'"),l>-1&&(b+=n.attr("index")+"='"+l+"'"),b+=">"+(s=a.headerTemplate?s:n.template(Ut)({size:n.getValidCssClass("k-checkbox-","size",h.options.size)}))+"</th>"):a.draggable?(b+="<th class='k-header' ref-grid-drag-cell scope='col'"+un(a.headerAttributes),r&&!i[o].colSpan&&(b+=" rowspan='"+r+"'"),l>-1&&(b+=n.attr("index")+"='"+l+"'"),b+=">"+(s=a.headerTemplate?s:"")+"</th>"):a.command?(b+="<th scope='col'"+un(a.headerAttributes),r&&!i[o].colSpan&&(b+=" rowspan='"+r+"'"),l>-1&&(b+=n.attr("index")+"='"+l+"'"),b+=">"+(s&&" "!==s?n.template(jt)({text:s}):s)+"</th>"):(a.field&&(d=n.attr("field")+"='"+a.field+"' "),b+="<th scope='col' "+d,p&&a.field&&!1!==a.menu?b+=" aria-haspopup='menu'":f&&!1!==a.filterable&&!a.command&&(b+=" aria-haspopup='dialog'"),r&&!i[o].colSpan&&(b+=" rowspan='"+r+"'"),i[o].colSpan>1?(b+='colspan="'+(i[o].colSpan-Yn(a.columns))+'" ',b+=n.attr("colspan")+"='"+i[o].colSpan+"'"):1===i[o].colSpan&&(b+=n.attr("colspan")+"='"+i[o].colSpan+"'"),c&&(c=c&&(h.options.encodeTitles?Yi(c,!0):c),b+=n.attr("title")+'="'+c+'" '),a.groupable!==t&&(b+=n.attr("groupable")+"='"+a.groupable+"' "),!Fi(h,a)||a.headerAttributes&&a.headerAttributes.title||(b+="title='",b+=Oi(v,a.field)?m.ungroupHeader:m.groupHeader,b+="' "),a.aggregates&&a.aggregates.length&&(b+=n.attr("aggregates")+"='"+a.aggregates+"'"),l>-1&&(b+=n.attr("index")+"='"+l+"'"),b+=un(a.headerAttributes),b+=">"+(s=n.template(jt)({text:s}))+"</th>"),h.options.resizable?u+=e(b).attr("data-resizable",(!1!==a.resizable).toString()).addClass("k-table-th")[0].outerHTML:u+=e(b).addClass("k-table-th")[0].outerHTML}return u},_appendLockedColumnContent:function(){var t,i,r,o,a,s=this.columns,l=this.table.find("colgroup"),c=l.find(P),d=e(),h=0,u=0;for(t=0,i=s.length;t<i;t++)if(s[t].locked)if(zn(s[t])){for(o=1,s[t].columns&&(o=pi(s[t].columns).length-Yn(s[t].columns)),o=o||1,a=0;a<o;a++)d=d.add(c.eq(t+u+a-h));u+=o-1}else h++;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=this;var i=t.footer;var r=i.find(".k-footer-template>td");var o=i.find(".k-grid-footer-wrap>table>colgroup>col");var a=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>');var s,l;var c=t._groups();var d=e(),h=e();for(a.find("table").addClass(n.getValidCssClass("k-table-","size",this.options.size)),d=d.add(r.filter(".k-group-cell")),s=0,l=pi(ri(t.columns)).length;s<l;s++)d=d.add(r.eq(s+c));for(h=h.add(o.filter(".k-group-col")),s=0,l=Pn(pi(li(t.columns))).length;s<l;s++)h=h.add(o.eq(s+c));d.appendTo(a.find(bt)),h.appendTo(a.find("colgroup")),t.lockedFooter=a.prependTo(i)},_appendLockedColumnHeader:function(t){var i,r,o,a,s,l,c,d,h,u=this,p=this.columns,f=[],m=0,g=e(),v=u._hasFilterRow(),_=0,b=e(),w=0,y=e();a=u.thead.prev().find(P),c=u.thead.find(bt).first().find(".k-header:not(.k-group-cell,.k-hierarchy-cell)"),d=u.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(h=c.eq(i),w=pi(p[i].columns||[]).length,zn(p[i])){var x=null;p[i].columns&&(x=w-Yn(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}Jn([p[i]],wi(h),f,0,0),w=w||1;for(var S=0;S<w;S++)b=b.add(d.eq(_+S));_+=w}p[i].columns&&(m+=Yn(p[i].columns)),zn(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",u.options.size)),(a=l.find("colgroup")).append(u.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++)y=Hn(f[i]),s.eq(i).append(u.thead.find(bt).eq(i).find(".k-group-cell").add(y));var T=Zn(this.thead);return f.length<T&&function(e,t){var n=e.find("tr:not(.k-filter-row) th:not(.k-group-cell,.k-hierarchy-cell)");var i;for(var r=0;r<n.length;r++)(i=n[r].rowSpan)>1&&(n[r].rowSpan=i-t||1)}(l,T-f.length),l.find(".k-filter-row").append(u.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(O).remove(),this.lockedHeader=this.lockedContent=this.lockedFooter=null,this.selectable=null},_thead:function(){var t,i,r=this,o=r.columns,a=r._hasDetails()&&o.length,s=r._hasFilterRow(),l="",c=r.table.find(">thead"),d=r.element.find("thead").first().length>0,h=r.options.messages.expandCollapseColumnHeader;const u=r._isStackedMode();if(!u){if(c.length||(c=e("<thead/>").insertBefore(r.tbody)),c.addClass("k-table-thead"),r.lockedHeader&&r.thead?((i=r.thead.find("tr:has(th):not(.k-filter-row)").html("")).remove(),i=e(),r._removeLockedContainers()):i=d?r.element.find("thead").first().find("tr:has(th):not(.k-filter-row)"):r.element.find("tr:has(th)").first(),i.length){for(t=0;t<o.length;t++){let e=_(o[t],pi(o));let n=_i(i.parent()).filter("th:not(.k-group-cell):not(.k-hierarchy-cell)").eq(e);n.addClass("k-table-th");const r=n[0];const a=r?.childNodes||[];1===a.length&&3===a[0].nodeType&&n.html(jt({text:Yi(n.text())})),o[t].hidden&&e>=0&&(r.style.display=It)}r._updateHeadersAttr(hi(o))}else if(!(i=c.children().first()).length){var p=[{rowSpan:1,cells:[],index:0}];for(r._prepareColumns(p,o),t=0;t<p.length;t++)l+="<tr class='k-table-row'>",a&&(l+='<th class="k-hierarchy-cell k-table-th" scope="col">'+h+"</th>"),l+=r._createHeaderCells(p[t].cells,p[t].rowSpan),l+="</tr>";i=e(l),n.applyStylesFromKendoAttributes(i,["display","left","right"])}if(s){var f=e("<tr/>");f.addClass("k-filter-row k-table-row"),(a||i.find(".k-hierarchy-cell").length)&&f.prepend('<td class="k-table-td k-hierarchy-cell"> </td>');var m=(r.thead||c).find(".k-filter-row");m.length&&(n.destroy(m),m.remove()),c.append(f)}i.children().length?a&&!i.find(".k-hierarchy-cell")[0]&&i.prepend('<th class="k-hierarchy-cell k-table-th" scope="col">'+(h||" ")+"</th>"):(l="",a&&(l+='<th class="k-hierarchy-cell k-table-th" scope="col"> </th>'),l+=r._createHeaderCells(o),i.html(l));const u=i.find("th");u.addClass(Ae),u.length>0&&c.attr(Et,Pt),r.options.scrollable||c.addClass("k-grid-header"),i.find("script").remove().end().prependTo(c),r.thead&&r._destroyColumnAttachments(),r.thead=c}var g;r._sortable(),r._filterable(),r._filterRow(),r._scrollable(),r._columnMenu();var v=this.options.scrollable&&ri(this.columns).length;v&&!u&&(g=r._appendLockedColumnHeader(r.thead.closest(".k-grid-header")),r._appendLockedColumnContent(),r.lockedContent.on("DOMMouseScroll"+O+" mousewheel"+O,r._wheelScroll.bind(r)),n.support.touch&&(r._lockedContentUserEvents=new n.UserEvents(r.lockedContent,{move:function(e){r.content.scrollTop(r.content.scrollTop()+-e.y.delta),e.preventDefault()}})),r._updateLockedCols()),r._updateCols(),u||(r._updateColumnCellIndex(),r._updateFirstColumnClass()),r._resizable(),r._draggable(),r._reorderable(),u||(r._updateHeader(r._groups()),r._updateStickyColumns()),v&&!u&&(g&&r._syncLockedHeaderHeight(),r._applyLockedContainersWidth())},_retrieveFirstColumn:function(t,n){var i=e();if(n.length&&t[0]){var r=t[0];for(;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=oi(n);var r=t._retrieveFirstColumn(n,i);t._isLocked()&&(i=t.lockedHeader.find("thead>tr:not(.k-filter-row):not(:first)"),n=ri(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){var r=i||e[e.length-1];var o=e[r.index+1];var a=0;for(var 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()?Si(e,ci(si(this.columns)),this._hasDetails(),0):Si(e,ci(Pn(this.columns)),this._hasDetails(),0)},_updateColumnSorters:function(){var e=this;var t=_i(e.thead);var n=pi(e.columns);var i;var r;if(e.options.sortable)for(var o=0,a=t.length;o<a;o++)!1!==(i=n[o]).sortable&&!i.command&&i.field&&(r=t.eq(o).data("kendoColumnSorter"))&&r.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(hi(e))}},_updateCols:function(e){const t=this;const n=t._isStackedMode()?t.table:t.thead.parent().add(t.table);e=e||n,this._appendCols(e,this._isLocked())},_updateLockedCols:function(e){this._isLocked()&&Si(e=e||this.lockedHeader.find("table").add(this.lockedTable),ci(li(this.columns)),this._hasDetails(),this._groups())},_appendCols:function(e,t){t?Si(e,ci(si(this.columns)),this._hasDetails(),0):Si(e,ci(Pn(this.columns)),this._hasDetails(),this._groups(),this._isStackedMode())},_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){var t,n,i=this.dataSource._group.length;for(var 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,h,u=this,p="",m=null!=u.lockedContent,v=e.field,b=g(pi(u.columns),(function(e){return e.field==v}))[0]||{},w=Pn(u.columns)[0],y=w?w.groupHeaderColumnTemplate:null,k=b.groupHeaderTemplate?b.groupHeaderTemplate:y,x=(b.title&&(u.options.encodeTitles?Yi(b.title,!0):b.title)||Yi(v,!0))+": "+Mi(e.value,b.format,b.values,b.encoded),C=e.currentItems||e.items,S=u._groups(),T=o.groupFooterTemplate,M=o.groupHeaderColumnTemplate,A=u.dataSource._isGroupPaged(),D=!A||u.dataSource._groupsState[e.uid];if(u.options.editable&&e.items&&e.items[0]&&e.items[0].isNew&&e.items[0].isNew()&&(D=!0),(o.groupFooterTemplate||o.groupHeaderColumnTemplate||b.groupHeaderTemplate||u._isStackedMode())&&(h=u._groupData(e,!1,!(b.groupHeaderTemplate||!Pn(u.columns)[0].groupHeaderColumnTemplate)&&Pn(u.columns)[0])),k&&!a&&(x=typeof k===rt?k(h):n.template(k)(h)),u._skipRerenderItemsCount?r(t,i,x,D,e.uid,A,u._isStackedMode()):e.excludeHeader?e.excludeHeader=!!m&&!l:p+=function({groupHeaderColumnTemplate:e,groupHeaderBuilder:t,colspan:n,templateColspan:i,groupData:r,level:o,text:a,expanded:s,group:l,isGroupPaged:c,stacked:d}){var h;h=e?e(f({},r,{groupCells:o,colspan:i,text:a,expanded:s,isRtl:qt,uid:l.uid})):t(n,o,a,s,l.uid,c,qt,d);return h}({groupHeaderColumnTemplate:M,groupHeaderBuilder:r,colspan:t,templateColspan:S-i,groupData:h,level:i,text:x,expanded:D,group:e,isGroupPaged:A,stacked:u._isStackedMode()}),D)if(e.hasSubgroups)for(c=0,d=C.length;c<d;c++)p+=u._groupRowHtml(C[c],a?t:t-1,i+1,r,o,a,s&&c===C.length-1,l);else p+=u._rowsHtml(C,o);return T&&(s?_(e.value,u._skippedGroups)||u._skippedGroups.push(e.value):(u._skippedGroups.length&&u._skippedGroups[0]===e.value&&u._skippedGroups.shift(),u._skipRerenderItemsCount||(p+=T(h)))),p},collapseGroup:function(t){var i,r,o,a,s,l=this,c=t,d=this.options.groupable.showFooter?0:1,h=e();if(i=(t=e(t)).find(".k-group-cell").length,this.dataSource._isGroupPaged()){var u=t.attr("data-group-uid");var p=l.dataSource._getGroupByUid(u);var f=l.dataSource._calculateGroupsTotal([p],!0);var m;return l.dataSource._groupsState[u]=!1,m=l.dataSource._calculateGroupsTotal([p],!0),l.dataSource._serverGroupsTotal-=f-m,l._progress(!0),void l.dataSource.range(l.dataSource._currentRangeStart,l.dataSource.take(),(function(){l._progress(!1)}),"collapseGroup")}this._isLocked()&&(t.closest(wt).hasClass("k-grid-content-locked")?h=this.tbody.children(bt).eq(t.index()).nextAll(bt):(h=t.nextAll(bt),t=this.lockedTable.find(">tbody>tr").eq(t.index()))),t.find(B).length&&n.ui.icon(t.find(B),{icon:"caret-alt-"+(qt?"left":"right")}),t.find("td[aria-expanded='true']").first().attr(Mt,!1).find("a").attr(yt,gt);var g=[];for(o=0,a=(t=t.nextAll(bt)).length;o<a&&(r=(s=t.eq(o)).find(".k-group-cell").length,s.hasClass(He)?d++:s.hasClass("k-group-footer")&&d--,!(r<=i||s.hasClass("k-group-footer")&&d<0));o++)h.length&&g.push(h[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(),h=[],u=1;if(i=t.find(".k-group-cell").length,this.dataSource._isGroupPaged()){var p=t.attr("data-group-uid");var f=l.dataSource._getGroupByUid(p);var m=l.dataSource._calculateGroupsTotal([f],!0);var g;return l.dataSource._groupsState[p]=!0,f.items&&f.items.length&&(g=l.dataSource._calculateGroupsTotal([f],!0),l.dataSource._serverGroupsTotal+=g-m),l._progress(!0),void l.dataSource.range(l.dataSource._currentRangeStart,l.dataSource.take(),(function(){l._progress(!1)}),"expandGroup")}for(this._isLocked()&&(t.closest(wt).hasClass("k-grid-content-locked")?d=this.tbody.children(bt).eq(t.index()).nextAll(bt):(d=t.nextAll(bt),t=this.lockedTable.find(">tbody>tr").eq(t.index()))),t.find(H).length&&n.ui.icon(t.find(H),{icon:"caret-alt-down"}),t.find("td[aria-expanded='false']").first().attr(Mt,!0).find("a").attr(yt,mt),a=0,s=(t=t.nextAll(bt)).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(He)&&r.find(".k-icon,.k-svg-icon").is(B)&&l.expandGroup(r),r.hasClass("k-master-row")&&r.find(".k-icon,.k-svg-icon").is(B)&&(r.next().show(),d.eq(a+1).show())),r.hasClass(He)&&(c&&h.push(r.is(":visible")),u++),r.hasClass("k-group-footer")){if(c){var v=h.pop();r.toggle(v),d.eq(a).toggle(v)}1==u?(r.show(),d.eq(a).show()):u--}(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(bt).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">'+y(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(bt).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"> </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=Pi(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(Pi(t.eq(0))))},hideColumn:function(t){var n,i,r,o,a,s,l,d,h,u=this,f=0,m=u.footer||u.wrapper.find(".k-grid-footer"),v=u.virtualScroll||{},b=u.columns,w=u.lockedHeader?_i(u.lockedHeader.find(">table>thead")).filter(En).length:0;(Array.isArray(t)?t:[t]).forEach((t=>{if(h=g(pi(u.columns),(function(e){return e.groupHeaderColumnTemplate})),(t="number"==typeof t?b[t]:p(t)?g(Kn(b),(function(e){return e===t}))[0]:g(Kn(b),(function(e){return e.field===t}))[0])&&zn(t)){if(u._isStackedMode())return u._stackedColumnVisibility(t,"hide"),void u.trigger(Z,{column:t});var y=u._columnVisibilitySetter(t);if(t.columns&&t.columns.length){for(a=jn(t,b),y(t,!1),Ai(bn(e(">table>thead",u.lockedHeader),u.thead,">tr:eq("+a.row+")>th"),a.cell,!1),i=0;i<t.columns.length;i++)this.hideColumn(t.columns[i]);return u._ariaAddHiddenColIndex(),void u.trigger(Z,{column:t})}d=_(t,Pn(pi(b))),y(t,!1),u._setParentsVisibility(t,!1),u._templates(),u._updateCols(),u._updateLockedCols();var k=u.thead;if(s=d,u.lockedHeader&&w>d?k=u.lockedHeader.find(">table>thead"):s-=w,_i(k).filter(En).eq(s)[0].style.display=It,Ai(bn(e(">table>thead",u.lockedHeader),u.thead,">tr.k-filter-row>td"),d,!1),m[0]&&(u._updateCols(m.find(">.k-grid-footer-wrap>table")),u._updateLockedCols(m.find(">.k-grid-footer-locked>table")),Ai(m.find(".k-footer-template>td"),d,!1)),v.columns&&!t.locked)return u._updateContentWidth(),void u.trigger(Z,{column:t});if(u.lockedTable&&w>d?Di(u.lockedTable.find(">tbody>tr"),d):Di(u.tbody.children(),d-w),u.lockedTable)u._updateTablesWidth(),u._applyLockedContainersWidth(),u._syncLockedContentHeight(),u._syncLockedHeaderHeight(),u._syncLockedFooterHeight();else{for(r=u.thead?u.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=u.wrapper.find(">.k-grid-header table").first().add(u.wrapper.find(">.k-grid-footer table").first()).add(u.table),u._footerWidth=null,f&&(n.each((function(){this.style.width=f+_t})),u._footerWidth=f,u._setContentWidth())}u._updateFirstColumnClass(),u._updateStickyColumns(),u._ariaAddHiddenColIndex(),h.length>0&&u._renderGroupRows(),u.trigger(Z,{column:t})}}))},_stackedColumnVisibility:function(t,n){const i=this;const r=t.field;let o;if(i.columns.length){for(let e=0;e<i.columns.length;e++)if(i.columns[e].field===r){o=e;break}if(o||0===o){i.table.find(".k-grid-stack-cell[data-index='"+o+"']").each((function(){const t=e(this);t.closest(".k-detail-row").length||t[n]()})),Cn(t,"show"===n)}}},_setParentsVisibility:function(t,i){var r=this.columns;var o;var a=[];var s;var l;var c;var d;var h=this._columnVisibilitySetter(t);var u=i?function(e){return Pn(e.columns).length&&e.hidden}:function(e){return!Pn(e.columns).length&&!e.hidden};if(xn(t,r,a)&&a.length)for(o=a.length-1;o>=0;o--)l=$n(s=a[o],r),c=bn(e(">table>thead",this.lockedHeader),this.thead,">tr:eq("+l.row+")>th:not(.k-group-cell):not(.k-hierarchy-cell)").eq(l.cell),u(s)&&(h(s,i),c[0].style.display=i?"":It),c.filter("["+n.attr("colspan")+"]").length&&(d=parseInt(c.attr(n.attr("colspan")),10),c[0].colSpan=d-Yn(s.columns)||1)},_updateContentWidth:function(){const t=this;t.table.add(t.thead?t.thead.parent():e()).css({width:Qn(ci(si(t.columns)))}),t.refresh()},showColumn:function(t){var n,i,r,o,a,s,l,d,h,u,f,m,v,b=this,w=b.columns,y=b.virtualScroll||{},k=b.footer||b.wrapper.find(".k-grid-footer"),x=b.lockedHeader?_i(b.lockedHeader.find(">table>thead")).length:0;(Array.isArray(t)?t:[t]).forEach((t=>{if(v=g(pi(b.columns),(function(e){return e.groupHeaderColumnTemplate})),"number"==typeof t?(u=t,t=w[t]):p(t)?e.each(Kn(w),(function(e,n){if(n===t)return t=n,u=e,!1})):e.each(Kn(w),(function(e,n){if(n.field===t)return t=n,u=e,!1})),t&&!zn(t)){if(b._isStackedMode())return b._stackedColumnVisibility(t,"show"),void b.trigger(J,{column:t});var C=b._columnVisibilitySetter(t);if(t.columns&&t.columns.length){for(l=$n(t,w),f=Kn(b.options.columns)[u],C(t,!0),Ai(bn(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(J,{column:t})}m=_(t,pi(w)),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=_i(S).eq(s))[0].style.display="",r[0].classList.remove("k-hidden"),Ai(bn(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")),Ai(k.find(".k-footer-template>td"),m,!0)),y.columns&&!t.locked)return b._updateContentWidth(),void b.trigger(J,{column:t});if(b.lockedTable&&x>m?Ii(b.lockedTable.find(">tbody>tr"),m):Ii(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,h=b.thead.prev().find("col"),n=0,i=h.length;n<i;n+=1)if(d=h[n].style.width,h[n].className.indexOf("k-hierarchy-col")>-1)a+=c(h[n]);else if(h[n].className.indexOf("k-group-col")>-1)a+=c(h[n]);else{if(d.indexOf("%")>-1){a=0;break}a+=parseInt(d,10)}b._footerWidth=null,a&&(o.each((function(){this.style.width=a+_t})),b._footerWidth=a,b._setContentWidth())}else o.width("");b._updateFirstColumnClass(),b._updateStickyColumns(),v.length>0&&b._renderGroupRows(),b._ariaRemoveHiddenColIndex(),b.trigger(J,{column:t})}}))},_columnVisibilitySetter:function(e){return Bn((e||{}).media)?Cn:Mn},_buildSkeleton:function(){const e=this.virtualCols?this.virtualCols:ci(this.columns);const t=this.dataSource.pageSize()||this.dataSource.total();const n=this._groups();const i=this._isStackedMode();let r="";let o;let a=i?1:e.length+n;this._hasDetails()&&!i&&a++,this._hasVirtualColumns()&&(o=parseInt(this.content.find(bt).first().find("td").first().attr("colspan"),10));for(var s=0;s<t;s++){r+="<tr class='k-table-row' data-skeleton-row>";for(var l=0;l<a;l++)r+=o&&!l?"<td colspan='"+o+"'><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>";r+="</tr>"}return r},_progress:function(e){var t=this.element;var i=this.options.scrollable&&this.options.scrollable.endless;var r=this.options.loaderType;var o;if(this.options.scrollable&&this.options.scrollable.virtual?t=this.content:this._editContainer&&"popup"===this._editMode()?t=this._editContainer:this.lockedContent||i?t=this.wrapper:this.element.is("table")?t=this.element.parent():this.content&&this.content.length&&(t=this.content),"skeleton"!=r||this._isExport)this._isExport?this._loaderContainer(e,{message:this.options.messages.loader.exporting}):i&&e?n.ui.progress(t,e,{height:this.content.height(),top:this.content.parent()[0].offsetTop,opacity:!0}):n.ui.progress(t,e);else{const n=t.find("tbody");e?(o=this._buildSkeleton(),i&&(this._currentEndlessRows=n.children(":not([data-skeleton-row])")),n.empty().append(o)):i?(t.find("[data-skeleton-row]").remove(),n.prepend(this._currentEndlessRows)):t.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||{},h=e(s.current()),u=!1,p=s._groups(),f=p+ci(Pn(s.columns)).length,m=g(s.columns,(function(e){return e.columns!==t})).length>0,v=0,b=s.dataSource.group()&&s.dataSource.group().length>0;const w=s._isStackedMode();if(i&&"itemchange"===i.action&&(s.editable||s.options.scrollable.endless)&&("popup"!=this._editMode()||"popup"===this._editMode()&&!s._editableIsClosing))return;if(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(X,s._modelChangeHandler),i=i||{},s.trigger("dataBinding",{action:i.action||"rebind",index:i.index,items:i.items}))return;if(i.action===ce&&s._isVirtualEditable()&&(s._destroyEditable(),s._clearEditableState()),!s._endlessFetchInProgress){const e=s._isAdaptive()?"kendoActionSheet":"kendoWindow";c&&(s._isActiveInTable()||s._editContainer&&s._editContainer.data(e))&&(r=(u=h.is("th"))?h.parent().children(":not(.k-group-cell)").index(h[0]):Math.max(s.cellIndex(h),0),u&&m&&(v=h.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),w&&s._toggleGroupableHeader(b))}),250)):s._isExport||(s._progress(!1),w&&s._toggleGroupableHeader(b)),h.length&&(s._currentRowIndex=h.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||w||s._updateHeader(p),s._group=p>0,s._groupRows=Ei(l)),s.content&&(o=n.scrollLeft(s.content));const y=s.dataSource.group()?.some((e=>e.aggregates))&&s.columns?.some((e=>e.groupFooterTemplate||e.groupHeaderTemplate));if("skeleton"!==s.options.loaderType&&i&&"sync"===i.action&&i.partialUpdate&&i.changedItems&&i.changedItems.length&&!y?(s._data=s.dataSource.flatView(),i.changedItems.forEach((e=>{const t=s.tbody.find("["+n.attr("uid")+"="+e.uid+"]");s._editMode()===dt&&s.dataSource.options.autoSync&&s.dataSource.isLocalTransport()&&s.trigger(Y,{type:"save",model:i.changedItems[0],container:t.find(".k-edit-cell")}),s._displayRow(t)})),s._progress(!1),w&&s._toggleGroupableHeader(b),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)if(w&&s.options.navigatable)s._setCurrentStackedCell();else{const e=s._isLocked()&&h.closest(".k-grid-header-locked").length&&u;s._restoreCurrent(r,u,v,e)}if(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._restoreHighlight(),s._hasAIHighlight&&s._applyAIHighlight(s._hasAIHighlight),s.options.persistSelection||(s._selectedIds={}),s._hasReorderableRows()&&(s._draggableRows(),s._reorderableRows()),s.options.selectable&&s.options.selectable.cellAggregates&&s._calculateAggregatesForSelected(),w){const e=s._getStackedLayoutSettings();const t=s.tbody.find(".k-grid-stack-row");e.colClass?t.addClass(e.colClass):e.colsConfig&&t.css("grid-template-columns",e.colsConfig)}s._aria(),s.trigger(te)},_getSchemaIdField:function(){const e=this.dataSource.options.schema.model;return w(e)?e.fn.idField:e&&e.id},_restoreCurrent:function(n,i,r,o){if(!(n===t||n<0)){if(this._removeCurrent(),i){const e=o?this.lockedHeader:this.thead;this._setCurrent(e.find(`tr:eq(${r}) th:not(.k-group-cell)`).eq(n),!1,this._hasVirtualColumns())}else{var a=0;var s=this.virtualScroll||{};this._rowVirtualIndex?a=s.rows?this.virtualScrollable.position(this._rowVirtualIndex):this._rowVirtualIndex:this._currentRowIndex?a=this._currentRowIndex:n=0;var l=e();var c;let t;this.lockedTable&&(l=this._shouldFocusInLastRow?this.lockedTable.find(">tbody>tr").last():this._shouldFocusInFirstRow?this.lockedTable.find(">tbody>tr").first():this.lockedTable.find(">tbody>tr").eq(a)),t=this._shouldFocusInLastRow?this.tbody.children().last():this._shouldFocusInFirstRow?this.tbody.children().first():this.tbody.children().eq(a),l=l.add(t),this._hasVirtualColumns()&&(c=parseInt(l.find("td").first().attr("colspan"),10),n=this._virtualCellIndex-(c>1?c-1:0));var d=l.find(">td:not(.k-group-cell):not(.k-hierarchy-cell)").eq(n);if(!d.length||n<0)return;this._hasVirtualColumns()?this._setCurrent(d,!0,!0):this._setCurrent(d)}this._current&&Ri(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(bt)),i=t.data("uid"),-1===o.indexOf(i)&&o.push(i);return o},_getSelectedColumnFields:function(){var t,i,r=this,o=r.select(),a=ci(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="",h=null!=c.lockedContent,u=c.options.scrollable,p={rowTemplate:c.rowTemplate,altRowTemplate:c.altRowTemplate,groupFooterTemplate:c.groupFooterTemplate,groupHeaderColumnTemplate:c.groupHeaderColumnTemplate};const f=c._isStackedMode();if(u&&u.endless&&!c.dataSource.options.endless&&(c._skipRerenderItemsCount=0,c.content&&(c.content[0].scrollTop=0)),a=c._skipRerenderItemsCount>0,t=h?t-ci(li(c.columns)).length:t,f&&(t=c.table.find("col").length),i>0)for(t=h?t-i:t,c.detailTemplate&&!f&&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,h?Ki:Gi,p,h,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=yi(c.tbody,c.table,d,this.options.size)},_renderGroupRows:function(){var t,i,r,o,a,s,l,c,d,h,u,p,m,v,_,b,w,y=this,k=y._groupRows,x=y.wrapper.find(S+He),C=y._groups(),T=null!=y.lockedContent;x.each((function(x,S){v=e(S),h=v.closest("table").parent(),u=h.is(".k-grid-content-locked"),i=ci(Pn(u?ri(y.columns):oi(y.columns))),_=v.find(".k-group-cell").length,T?(t=u?Gi:Ki,r=u?i.length+C-_:i.length):(t=Gi,r=i.length+C-_),o=x>=k.length?k[x-k.length]:k[x],a=o.field,s=g(pi(y.columns),(function(e){return e.field==a}))[0]||{},w=!(s.groupHeaderTemplate||!Pn(y.columns)[0].groupHeaderColumnTemplate)&&Pn(y.columns)[0],l=s.groupHeaderTemplate?s.groupHeaderTemplate:Pn(y.columns)[0].groupHeaderColumnTemplate,c=(s.title&&(y.options.encodeTitles?Yi(s.title,!0):s.title)||Yi(a,!0))+": "+Mi(o.value,s.format,s.values,s.encoded),d=y._groupData(o,!1,w),b=u?y.lockedGroupHeaderColumnTemplate:y.groupHeaderColumnTemplate,l&&(c=typeof l===rt?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,qt,y._isStackedMode())),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-=Pn(pi(oi(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,Gi,c,!1,o,!0);else s=this._rowsHtml(e,c);l?d.children("tbody").append(s):yi(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].getBoundingClientRect().height;var d=o[n].getBoundingClientRect().height;var h=0;c>d?h=c:c<d&&(h=d),l.push(h)}for(n=0;n<s;n++)a[n].style.display=It;for(n=0;n<r;n++)l[n]&&(i[n].style.height=o[n].style.height=l[n]+_t);for(n=0;n<s;n++)a[n].style.display=""}});function Bi(e,t){var n;var i=e.offsetHeight;var r=t.offsetHeight;i>r?n=i+_t:i<r&&(n=r+_t),n&&(e.style.height=t.style.height=n)}function Hi(e,t){var n,i,r;if(typeof e===ot&&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])===ot&&r===t||r.name===t)return r;return null}function Ri(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 Fi(e,n){return e.options.groupable&&(n.groupable||n.groupable===t)}function Oi(t,n){return!!e.grep(t,(function(e){return e.field===n})).length}function Vi(e,t){return!(!e.field||e.selectable)&&(!(t.editable&&!t.editable(e.field))&&!(e.editable&&!e.editable(t)))}function Ni(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 $i(t){var i=this,r=e(t.currentTarget),o=r.is("th"),a=this.table.add(this.lockedTable),s=this.thead&&this.thead.parent().add(e(">table",this.lockedHeader)),l=Ni(t.target),c=e(t.target).is(".k-checkbox"),d=e(t.target),h=r.closest("table")[0];!i._isStackedMode()&&l&&r.find(n.roleSelector("filtercell")).length?this._setCurrent(r,null,null,!0):h!==a[0]&&h!==a[1]&&h!==s[0]&&h!==s[1]||d.is(H+","+B+",[ref='expand-detail-button'], [ref='collapse-detail-button']")||(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")||t.hasClass("k-select-checkbox")||!i.table||!t.is(ye)&&Ni(n._activeElement())&&e.contains(h,n._activeElement())||Ri(i.table[0],!0)})),o&&!n.support.touch&&t.preventDefault())}function Ui(e,t){if(!t)return 0;var i=0;return n.support.browser.webkit&&(i=e.width()),i}function Wi(t,n){var i;var 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 ji(e){return e&&(e.hasClass("k-edit-cell")||e.parent().hasClass("k-grid-edit-row")||e.hasClass("k-grid-stack-edit-cell"))}function qi(t,i,r){return({colspan:o,text:a,expanded:s,isRtl:l})=>{let c=o+t>0?o+t:0;let d="caret-alt-"+(l?"left":"right");return`<td class="k-table-td" colspan="${o+t}"><p class="k-reset">`+n.ui.icon(e(`<a href="\\#" tabindex="-1" ${yt}="${s?mt:gt}"></a>`),{icon:s?"caret-alt-down":d})+a+`</p>${r||""}</td>${i?"":new Array(c).join("<td hidden group-header-spanned-hidden></td>")}`}}function Gi(t,i,r,o,a,s,l,c,d){return"<tr "+(s?'data-group-uid="'+a+'"':"")+'class="k-table-group-row k-grouping-row k-table-row">'+hn(i)+'<td class="k-table-td" colspan="'+t+'" aria-expanded="'+!!o+'"><p class="k-reset">'+n.ui.icon(e('<a href="#" tabindex="-1" '+yt+'="'+(o?mt:gt)+'"></a>'),{icon:o?"caret-alt-down":"caret-alt-"+(l?"left":"right")})+r+`</p>${d||""}</td>${c?"":new Array(t).join("<td hidden group-header-spanned-hidden></td>")}</tr>`}function Ki(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"> </p></td>${new Array(e).join("<td hidden group-header-spanned-hidden></td>")}</tr>`}function Yi(e,t){return(""+e).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,(function(e){return t?"\\"+e:"""})).replace(/'/g,"'")}function Qi(e,t){return this.dataSource.indexOf(this.dataSource.getByUid(e.uid))-this.dataSource.indexOf(this.dataSource.getByUid(t.uid))}function Xi(e){return!(!1===e.exportable||e.exportable&&!1===e.exportable.excel)}n.ExcelMixin&&n.ExcelMixin.extend(Li.prototype),n.PDFMixin&&(n.PDFMixin.extend(Li.prototype),Li.prototype._drawPDF_autoPageBreak=function(i){var r=this;var o=new e.Deferred;var a=r.dataSource;var s=r.options.pdf.allPages;var l=r.wrapper.find("> table > tbody, .k-grid-content > table > tbody").first();var c=e("<div>").css({position:"absolute",left:-1e4,top:-1e4});var d;r.toggleUnexportableColumns(r.columns),(d=r.wrapper.clone().css({height:nt,width:nt}).appendTo(c)).find(".k-grid-content").css({height:nt,width:nt,overflow:"visible"}),d.find("> table, .k-grid-header table, .k-grid-content > table, .k-grid-footer table").css({height:nt,width:"100%",overflow:"visible"}),d.find(".k-grid-pager, .k-grid-toolbar, .k-grouping-header").remove(),d.find(".k-grid-header, .k-grid-footer, .k-auto-scrollable").css({paddingRight:0});var h=d.find("> table > tbody, .k-grid-content > table > tbody").first().empty();var u=a.page();function p(){c.appendTo(document.body);var t=e.extend({},r.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(d,t).always((function(){c.remove()})).then((function(e){o.resolve(e),r.toggleUnexportableColumns(r.columns,!0)})).fail((function(e){o.reject(e)}))}function f(){var e=a.page();var n=s?a.totalPages():1;h.append(l.children("tr:not(.k-detail-row)")),e<n?a.page(e+1):(a.unbind("change",f),s&&u!==t?(a.one("change",p),a.page(u)):(r.refresh(),p()))}return s?(a.bind("change",f),a.page(1)):f(),o.promise()},Li.prototype.toggleUnexportableColumns=function(e,t){var n=e.length;var i;var r;var o;var a;for(var s=0;s<n;s++)r=(i=e[s]).exportable,t?i._toggledDuringExport?(i._toggledDuringExport=!1,i.hidden?this.showColumn(i):this.hideColumn(i)):i.columns&&this.toggleUnexportableColumns(i.columns,t):("object"==typeof i.exportable&&(r=i.exportable.pdf),o=!i.hidden&&!1!==r,a=i.hidden&&!0===r,(r=o||a)||i.hidden?r&&i.hidden?(i._toggledDuringExport=!0,this.showColumn(i)):r&&i.columns&&this.toggleUnexportableColumns(i.columns):(i._toggledDuringExport=!0,this.hideColumn(i)))},Li.prototype._drawPDF=function(i){var r=this;if(r.options.pdf.paperSize&&r.options.pdf.paperSize!=nt)return r._drawPDF_autoPageBreak(i);var o=new e.Deferred;var a=r.dataSource;var s=r.options.pdf.allPages;var l=new n.drawing.Group;var 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();var h=s?a.totalPages():1;var u={page:e,pageNumber:n,progress:n/h,totalPages:h};r.toggleUnexportableColumns(r.columns,!0),i.notify(u),l.append(u.page),n<h?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(Li),i.plugin(an),f(n.ui.grid,{defaultBodyContextMenu:en,defaultHeadContextMenu:tn,defaultGroupsContextMenu:nn})}(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)",h="progress",u="error",p="k-focus",f="k-selected",m="k-edit-item",g="k-listview-pager",v="k-listview-item",_="role",b="aria-label",w="aria-multiselectable",y="aria-activedescendant",k="edit",x="remove",C="save",S="touchstart",T=".kendoListView",M=n._activeElement,A=n.ui.progress,D=n.data.DataSource;var 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");var 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(h,e._progressHandler).unbind(u,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=D.create(o).bind(i,n._refreshHandler).bind(h,n._progressHandler).bind(u,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;var 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;var n=e.options;var i=n.flex;var r=n.grid;var o=e.element;var a=["k-listview"];var s=e.content;var 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(),h="",u=c.template,p=c.altTemplate,f=c.options.selectable?"option":"listitem",m=M(),g=c._endlessFetchInProgress,b=g?c._skipRerenderItemsCount:0,w=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++)h+=s%2?p(d[s]):u(d[s]);for(g?c.content.append(h):c.content.html(h),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()):w||c.current(i.eq(0))),c.element.attr(y)&&0===c.element.find("#"+c.element.attr(y)).length&&c.element.removeAttr(y),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(u(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(w),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(w,!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(){"endless"===this.options.scrollable&&this._bindScrollable()},_bindScrollable:function(){var e=this;var 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(y)),e&&e[0]&&(o=e[0].id||o,n._scrollTo(e[0]),i.attr(y,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"),h=c.is(":text, :password"),u=n.preventDefault,p=o.find("."+m),f=M(),v=t.options.scrollable;if(!(c.hasClass(g)||!d&&!h&&a!==l.ESC||h&&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")),u(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"))),u(i)),a===l.PAGEUP&&(t.current(null),t.dataSource.page(t.dataSource.page()-1),u(i)),a===l.PAGEDOWN&&(t.current(null),t.dataSource.page(t.dataSource.page()+1),u(i)),a===l.HOME&&(t.current(t._item("first")),u(i)),a===l.END&&(t.current(t._item("last")),u(i)),a===l.ENTER)if(0!==p.length&&(d||h)){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(y)&&t.element.removeAttr(y),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;var 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;var i=n.attr;var r=n.data;var o=n.keys;var a=n.template;var s=n.ui.Widget;var l=r.DataSource;var c=n.ui.Selectable;var d=n.ui.DataBoundWidget;var h=n.Class;var u=e.extend;var p=e.noop;var f="-";var m="kendoListBox";var g="."+m;var v="k-disabled";var _="k-selected";var b=".k-list-item:not(.k-disabled)";var w=".k-list-ul:not(.k-disabled) >"+b;var y="k-listbox-actions";var k=".k-button";var x="k-focus";var C="click"+g;var S="keydown"+g;var T="blur"+g;var M=n._outerWidth;var A=n._outerHeight;var D="change";var E="dataBound";var I="add";var z="remove";var P="reorder";var L="moveUp";var B="moveDown";var H="transferTo";var R="transferFrom";var F="transferAllTo";var O="transferAllFrom";var V="caret-alt-right";var N="caret-alt-left";var $="caret-double-alt-right";var U="caret-double-alt-left";var W="k-ghost";var j="id";var q="tabindex";var G="dragstart";var K="drag";var Y="drop";var Q="dragend";var X="right";var Z="aria-activedescendant";var J="aria-busy";var ee="aria-label";var te=[y+f+"left",y+f+X,y+f+"top",y+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:[D,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=this;var n=e&&e.length?e:[e];var i=n.length;var r=t._getList();var o;for(t._unbindDataSource(),t._unbindDataChange(),o=0;o<i;o++)t._addItem(n[o],r);t._bindDataChange(),t._bindDataSource(),t._syncElement()},_addItem:function(t,n){var i=this;var 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;var 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=this;var t;return isNaN(e._listTabIndex)?(t=e.element.attr(q),e._listTabIndex=isNaN(t)?0:t,e.element.removeAttr(q),e._listTabIndex):e._listTabIndex},_blur:function(){this._target&&(this._target.removeClass(x),this._getList().removeAttr(Z)),this._target=null},_click:function(t){var i=this;var r=e(t.currentTarget);var o=i._target;var a=i._getList();var s=n._activeElement();var 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=this;var n;return n=t._target?t._target:t.items().filter(b).first(),e===o.UP&&t._target&&(n=t._target.prevAll(b).first()),e===o.DOWN&&t._target&&(n=t._target.nextAll(b).first()),n.length?n:null},_scrollIntoView:function(e){if(e){e[0]&&(e=e[0]);var t=this._getList().parent()[0];var n=e.offsetTop;var i=t.scrollTop;var r=t.clientHeight;var o=n+e.offsetHeight;i>n?i=n:o>i+r&&(i=o-r),t.scrollTop=i}},_keyDown:function(e){var t=this;var n=e.keyCode;var i=t._getNavigatableItem(n);var r;if((!e.shiftKey||e.ctrlKey||n!==o.DOWN&&n!==o.UP)&&(t._shiftSelecting=!1),n==o.DELETE)t._executeCommand(z),t._target&&(t._target.removeClass(x),t._getList().removeAttr(Z),t._target=null),r=!0;else if(n===o.DOWN||n===o.UP){if(!i)return void e.preventDefault();if(e.shiftKey&&!e.ctrlKey)t._target&&t._target.removeClass(x),t._shiftSelecting||(t.clearSelection(),t._shiftSelecting=!0),t._target&&i.hasClass("k-selected")?t._target.removeClass(_):"single"==t.options.selectable?t.select(i):t.select(i.add(t._target)),t._updateToolbar(),t._updateAllToolbars(),t.trigger(D);else{if(e.shiftKey&&e.ctrlKey)return t._executeCommand(n===o.DOWN?B:L),t._scrollIntoView(t._target),void e.preventDefault();e.shiftKey||e.ctrlKey||(t._target&&t._target.removeClass(x),"multiple"===t.options.selectable&&t.clearSelection(),t.select(i),t._updateToolbar(),t._updateAllToolbars(),t.trigger(D))}i&&t._target&&t._target[0]!==i[0]&&t._target.removeClass(x),t._target=i,t._target?(t._target.addClass(x),t._scrollIntoView(t._target),t._getList().attr(Z,t._target.attr(j))):t._getList().removeAttr(Z),r=!0}else n==o.SPACEBAR?(e.ctrlKey&&t._target?(t._target.hasClass(_)?t._target.removeClass(_):t.select(t._target),t.trigger(D)):(t.clearSelection(),t.select(t._target),t.trigger(D)),t._updateToolbar(),t._updateAllToolbars(),r=!0):e.ctrlKey&&n==o.RIGHT?(e.shiftKey?t._executeCommand(F):t._executeCommand(H),t._target=t.select().length?t.select():null,r=!0):e.ctrlKey&&n==o.LEFT?(e.shiftKey?t._executeCommand(O):t._executeCommand(R),r=!0):n===o.F10&&t.toolbar&&(t.toolbar.element.find(k).not("[tabindex=-1]").trigger("focus"),r=!0);r&&e.preventDefault()},focus:function(){n.focusElement(this._getList())},_createDraggable:function(){var t=this;var i=t.options.draggable;var r;if(i){if(r=i.hint,!t.options.selectable)throw new Error("Dragging requires selection to be enabled");r||(r=re),t._draggable=new n.ui.Draggable(t.wrapper,{filter:i.filter?i.filter:"ul.k-list-ul>li.k-list-item",hint:n.isFunction(r)?r:e(r),dragstart:t._dragstart.bind(t),dragcancel:t._clear.bind(t),drag:t._drag.bind(t),dragend:t._dragend.bind(t)})}},_dragstart:function(t){var i=this;var r=i.draggedElement=t.currentTarget;var o=i.options.draggable.placeholder;var 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);var 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=this;var i=n._findElementUnderCursor(t);var r=e(i);var o=n._getList();var a;var s;return e.contains(o[0],i)?(a=n.items(),i=r.is("li")?i:r.closest("li")[0],(s=a.filter(i)[0]||a.has(i)[0])?(s=e(s)).hasClass(v)?null:{element:s,listBox:n}:null):o[0]==i||o.parent()[0]==i?{element:e(o),appendToBottom:!0,listBox:n}:n._searchConnectedListBox(r)},_getElementCenter:function(e){var t=e.length?n.getOffset(e):null;return t&&(t.top+=A(e)/2,t.left+=M(e)/2),t},_searchConnectedListBox:function(t){var n;var i;var r;var o=t;var a;return(a=t.hasClass("k-list-scroller k-selectable")?t:t.closest(".k-list-scroller.k-selectable")).length&&(n=a.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||o.hasClass("k-list-scroller k-selectable")||o.hasClass("k-list-content")?{element:n._getList(),listBox:n,appendToBottom:!0}:null):null},_drag:function(t){var n=this;var i=n.draggedElement;var r=n._findTarget(t);var o=t.x.location,a=t.y.location;var s={dataItems:[n.dataItem(i)],items:e(i),draggableEvent:t};var l;var c;var d;if(n.trigger(K,s))t.preventDefault();else if(r){if(l=this._getElementCenter(r.element),c={left:Math.round(o-l.left),top:Math.round(a-l.top)},r.appendToBottom)return void n._movePlaceholder(r,null,i);c.top<0?d="prev":c.top>0&&(d="next"),d&&r.element[0]!=n.placeholder[0]&&n._movePlaceholder(r,d,i)}else n.placeholder.parent().length&&n.placeholder.remove()},_movePlaceholder:function(t,i,r){var o=this;var a=o.placeholder;var 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;var i=n.draggedElement;var r=n.items();var o=r.not(n.draggedElement).index(n.placeholder);var a=r.not(n.placeholder).index(n.draggedElement);var s=n.dataItem(i);var l={dataItems:[s],items:e(i)};var c=n.placeholder.closest(".k-listbox").find("[data-role='listbox']").getKendoListBox();if(n.trigger(Y,u({},l,{draggableEvent:t})))return t.preventDefault(),void this._clear();o>=0?o===a||n.trigger(P,u({},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,u({},l,{draggableEvent:t})),n._updateToolbar(),n._updateAllToolbars()},reorder:function(t,n){var i=this;var r=i.dataSource;var o=i.dataItem(t);var a=r.at(n);var s=i.items()[n];var l=e(t);o&&s&&a&&(i._removeElement(l),i._insertElementAt(l,n),i._updateToolbar())},remove:function(t){var n=this;var i=n._getItems(t);var r=i.length;var o;for(n._unbindDataSource(),n._unbindDataChange(),o=0;o<r;o++)n._removeItem(e(i[o]));n._bindDataChange(),n._bindDataSource(),n._syncElement(),n._updateToolbar(),n._updateAllToolbars()},_removeItem:function(e){var t=this;var n=t.dataSource;var i=t.dataItem(e);var r=n.transport;if(i&&n){if("string"==typeof i){var o=n._data;for(var 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");var 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=[];var i=e(t);var r=i.length;var o;for(o=0;o<r;o++)n.push(this.dataItem(i.eq(o)));return n},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(w),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=this;var r=!!ie(n)||!!n;var o=i._getItems(t);var a=o.length;var s;for(s=0;s<a;s++)i._enableItem(e(o[s]),r);i._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;var t=e.options;var 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(D,e._changeHandler),e._data.trigger(D))},_unbindDataChange:function(){var e=this.dataSource;e._data&&e._changeHandler&&e._data.unbind(D,e._changeHandler)},_bindDataSource:function(){var e=this;var t=e.dataSource;e._dataChangeHandler=e.refresh.bind(e),t&&t.bind(D,e._dataChangeHandler)},_unbindDataSource:function(){var e=this.dataSource;e&&e.unbind(D,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=this.options;var t;t=e.template&&"string"==typeof e.template?n.template(e.template):e.template?e.template:n.template((t=>`${n.getter(e.dataTextField)(t)}`)),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:t,toolbar:`<div role='toolbar' class='${y}'></div>`}},refresh:function(){var e=this;var t=e.dataSource.view();var n=e.templates.itemTemplate;var i="";for(var 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(){var e="";var t=this.dataSource.view();for(var 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,""")),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=this;var t=e.items();var n=e.dataSource.view();var i=n.length;var r;for(r=0;r<i;r++)e._setItemId(t.eq(r),n[r].uid)},_selectable:function(){var e=this;var t=e.options.selectable;var 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(D)},_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;var n=t.options.toolbar;var i=n.position||X;var r=n.tools||[];var 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,u({},n,{listBox:t,messages:o})),t.wrapper.addClass(y+f+i)}},_destroyToolbar:function(){var e=this;e.toolbar&&(e.toolbar.destroy(),e.toolbar=null)},_executeCommand:function(e){var t=this;var 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=e("select[data-role='listbox']");var n=t.length;var i;var r;for(r=0;r<n;r++)(i=e(t[r]).data(m))&&i._updateToolbar()}});n.ui.plugin(ae);var se=h.extend({init:function(){this._commands=[]},register:function(e,t){this._commands.push({commandName:e,commandType:t})},create:function(e,t){var n=this._commands;var i=n.length;var r=e?e.toLowerCase():"";var o;var a;var s;for(s=0;s<i;s++)if((a=n[s]).commandName.toLowerCase()===r){o=a;break}if(o)return new o.commandType(t)}});se.current=new se;var le=h.extend({init:function(e){var t=this;t.options=u({},t.options,e),t.listBox=t.options.listBox},options:{listBox:null},getItems:function(){return e(this.listBox.select())},execute:p,canExecute:p});var ce=le.extend({execute:function(){var e=this.listBox;var 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=this;var n=t.listBox;var i=t.options;var r=t.getItems();var o=i.offset;var a=ne(r);var s=e.makeArray([].sort.call(r,t.itemComparer));var l=i.moveAction;var c;if(!n.trigger(P,{dataItems:n._dataItems(s),items:e(s),offset:o}))for(;s.length>0&&a.length>0;)c=s[l](),n.reorder(c,a[l]()+o)},options:{offset:0,moveAction:"pop"},itemComparer:function(t,n){var i=e(t).index();var r=e(n).index();return i===r?0:i>r?1:-1}});var he=de.extend({options:{offset:-1,moveAction:"shift"},canExecute:function(){var e=ne(this.getItems());return e.length>0&&e[0]>0}});se.current.register(L,he);var ue=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(B,ue);var pe=le.extend({options:{filter:b},execute:function(){var e=this;var t=e.getSourceListBox();var n=e.getItems().filter(e.options.filter);var i=t?t._dataItems(n):[];var r=e.getDestinationListBox();var 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;var i=this.getSourceListBox();var r=i?i.items().filter(n).last():null;var 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(D),n._scrollIntoView(t))},getSourceListBox:p,getDestinationListBox:p});var 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(H,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(R,me);var ge=fe.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.wrapper.find(w).length>0},getItems:function(){var t=this.getSourceListBox();return t?t.items():e()},getUpdatedSelection:p,updateSelection:p});se.current.register(F,ge);var ve=me.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.wrapper.find(w).length>0},getItems:function(){var t=this.getSourceListBox();return t?t.items():e()},getUpdatedSelection:p,updateSelection:p});se.current.register(O,ve);var _e=h.extend({init:function(t,n){var i=this;i.element=e(t).addClass(y),i.options=u({},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=this;var i=n.support.isRtl(t.element);var r=t.options.tools;var o=r.length;var a=t.options.messages.tools;var s=t.element;var l;var c;for(_e.defaultTools=n.deepExtend({},_e.defaultTools,{transferTo:{icon:i?N:V},transferFrom:{icon:i?V:N},transferAllTo:{icon:i?U:$},transferAllFrom:{icon:i?$:U}}),c=0;c<o;c++)(l=u({},_e.defaultTools[r[c]],{text:a[r[c]]}))&&s.append(e(t.templates.tool(l)));t.element.append(s)},_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=this;var t=e.options.tools;var n=t.length;var i;var r=e.element.find(k).not("[tabindex=-1]");for(i=0;i<n;i++)e._updateToolState(t[i]);e._tabindex(r)},_updateToolState:function(e){var t=se.current.create(e,{listBox:this.listBox});var 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:L,icon:"caret-alt-up"},moveDown:{command:B,icon:"caret-alt-down"},transferTo:{command:H,icon:V},transferFrom:{command:R,icon:N},transferAllTo:{command:F,icon:$},transferAllFrom:{command:O,icon:U}},u(ae,{ToolBar:_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",h="apply",u="error",p="click",f=".kendoFileBrowser",m=".kendoSearchBox",g="name",v="size",_="type",b={field:_,dir:"asc"},w=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>`)),y=({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:[u,d,h],destroy:function(){var e=this;i.fn.destroy.call(e),e.dataSource.unbind(u,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(y),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,h=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(h,e.response[i._getFieldName(h)]),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;var n=this.dataSource;var i=n.view();for(var 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(w({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(h)},_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(u,e._errorHandler):e._errorHandler=e._error.bind(e),e.dataSource=n.data.DataSource.create(l).bind(u,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(u,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+"/")}});var 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",h="size",u="type",p={field:u,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(u))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,u=d,p=h;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(u,e.response[r._getFieldName(u)]),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,h=e("<img />",{alt:s}),u="?";o._uploading||(h.hide().on("load"+c,(function(){e(this).prev().remove().end().addClass("k-image k-file-image").fadeIn()})),r.find(".k-i-loading").after(h),a(l)?l=l(i.path(),encodeURIComponent(s)):(l.indexOf("?")>=0&&(u="&"),l=l+u+"path="+encodeURIComponent(i.path()+s),o._override&&(l+="&_="+(new Date).getTime(),delete o._override)),h.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[u]}">`+("d"===t[u]?`<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[u]?`<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[h])}</span>`:"")+"</div>"}))}});n.ui.plugin(m)}(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",h="contentLoad",u="error",p="resizing",f="layoutChange",m="pane",g="k-focus",v="."+(T="k-"+m),_="k-scrollable",b="k-pane-static",w="k-splitter",y="k-splitbar",k="flex-basis",x="horizontal",C="vertical",S=Number.MAX_SAFE_INTEGER,T="k-pane",M="click",A="resize",D="px";function E(e){return s.test(e)}function I(e){return a.test(e)||/^\d+$/.test(e)}function z(e){return!E(e)&&!I(e)}function P(e,t){var n=parseInt(e,10);return E(e)&&(n=Math.floor(n*t/100)),n}function L(e,t){return function(n,i){var r=this.element.find(n).data(m);if(1==arguments.length)return r[e];(((this.options.panes||[]).find((e=>e.uid==r.uid))||{})[e]=i,r[e]=i,r.isFluid=z(r.size),t)&&this.element.data("kendo"+this.options.name).resize(!0)}}var B=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()!=C),a.orientation=r?x:C,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(`${w} k-splitter-flex ${w}-${a.orientation}`),a.element.closest(T).removeClass(b).addClass("k-pane-flex"),a._initPanes(),a.resizing=new F(a),a.element.triggerHandler("init"+l)},events:[c,d,h,u,A,p,f],_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({preventScroll:!0})})).on("focus"+l,(function(t){e(t.currentTarget).addClass(g)})).on("blur"+l,(function(n){e(n.currentTarget).removeClass(g),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(M+l,t._arrowClick(d)).end().children(".k-expand-next, .k-expand-prev").on(M+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:x,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,h=o===l.increase,u=o===l.decrease;h||u?(t.ctrlKey?(n=s[u?"next":"prev"](),a&&a.isResizing()&&a.end(),n[r._dimension]()?r._triggerAction(d,s[u?"prev":"next"]()):r._triggerAction(c,n)):a&&a.move((u?-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||[];var 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=z(t[i].size),r.style.order=2*i,n._initPane(r,t[i]))})),this.resize()},_getDefaultPaneConfig:function(){return{scrollable:!0,resizable:!0,size:"auto",uid:t.guid()}},_updatePaneOrderStyles:function(t){e(t||this.element).children().each((function(e,t){if("script"!=t.nodeName.toLowerCase()){t.data(m).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").attr("data-uid",n.uid).addClass(T);let i=!n.resizable&&!n.collapsible||n.fixedSize;t.css(k,n.size).data(m,n).toggleClass(b,Boolean(i)).toggleClass(_,Boolean(n.scrollable)),this.ajaxRequest(t)},ajaxRequest:function(e,n,i){var r,o=this;r=(e=o.element.find(e)).data(m),(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(h,{pane:e[0]})},error:function(t,n){o.trigger(u,{pane:e[0],status:n,xhr:t})}}):e.removeClass(_).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(m);var 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))}},_updatePaneOrders:function(){this._getPaneElements().forEach(((t,n)=>{var i=e(t).data(m);i&&(i.order=2*n,t.style.order=2*n)}))},_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,h=r.collapsible,u=r.collapsed,p=o.attr("id");p||(p=t.guid(),o.attr("id",p));const f=t.support.isRtl(e);const m=f?"caret-alt-right":"caret-alt-left";const 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&&!u).toggleClass("k-splitbar-static-"+s,!l&&!c&&!h).html(a("collapse-prev","caret-alt-up",c&&!d&&!u&&s==C)+a("collapse-prev",m,c&&!d&&!u&&s==x)+a("expand-prev","caret-alt-down",c&&d&&!u&&s==C)+a("expand-prev",g,c&&d&&!u&&s==x)+a("resize-handle",null,l&&s==C)+a("resize-handle",null,l&&s==x)+a("collapse-next","caret-alt-down",h&&!u&&!d&&s==C)+a("collapse-next",g,h&&!u&&!d&&s==x)+a("expand-next","caret-alt-up",h&&u&&!d&&s==C)+a("expand-next",m,h&&u&&!d&&s==x)),i.labelId?e.attr("aria-labelledby",i.labelId):i.label&&e.attr("aria-label",i.label),s==x&&e.attr("aria-orientation",C),l||c||h||e.removeAttr("tabindex")},_updateSplitBars:function(){var t=this;this.element.children(".k-splitbar").each((function(){var n=e(this),i=n.prevAll(v).first(),r=i.data(m),o=n.nextAll(v).first().data(m);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(v):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(v),o=n.orientation==x,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 h=0,u=e();r.each((function(){var t,n=e(this),i=n.data(m)||{};if(n.removeClass("k-collapsed"),i.collapsed)t=i.collapsedSize?P(i.collapsedSize,c):0,n.css("overflow","hidden").addClass("k-collapsed");else{if(i.isFluid||z(i.size))return u=u.add(this),void d.push(!1);t=P(i.size,c)}return h+=t,d.push(t),n.css(k,t+D),t})),c-=h;var p=u.length,g=Math.floor(c/p);u.slice(0,p-1).css(k,g+D).end().eq(p-1).css(k,c-(p-1)*g+D),d.forEach((function(e,t){!1===e&&(d[t]=g)})),n._resetAriaValueNow(a,d);var _=o?"offsetWidth":"offsetHeight";if(0===p){var b=r.filter((function(){return!(e(this).data(m)||{}).collapsed})).last();b.length&&b[l](c+b[0][_])}n._detachEvents(),n._attachEvents(),n.wrapper.removeClass("k-splitter-resizing"),t.resize(r),n.trigger(f)}},toggle:function(e,t){var n;n=(e=this.element.find(e)).data(m),(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){const i=this;return n.length&&(i.options.panes.splice(t,0,e),i._initPane(n,e),i._removeSplitBars(),i._updatePaneOrders(),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:L("size",!0),min:L("min"),max:L("max"),_getPaneElement:function(e){return this._getPaneElements()[e]},_getPaneElements:function(){return Array.from(this.element.children()||[]).filter((t=>e(t).hasClass("k-pane")||e(t).hasClass("k-splitter")))},_dragSplitterBar:function(e,t){const n=this;const{leftPane:i,rightPane:r}=n._getAdjacentPanes(e);const o=i.computedSize+t;const a=o>i.min&&o<i.max;const s=n._getPaneElements().filter((e=>!e.style[k]));const 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;const n=e;const i=e+1;const r=t._getPaneElement(n);const o=t._getPaneElement(i);const a=t._getPane(n);const s=t._getPane(i);const l=t._getPaneOffsetSize(n);const c=t._getPaneOffsetSize(i);const d=l+c;const h=t._getElementClientSize(t.element,t.options.orientation);const u=e=>t._calculatePixelSize(e,h);const{leftPaneMaxSize:p,rightPaneMaxSize:f}=t._getAdjacentPanesMaxSize(n,i);const m=u(s&&s.max);const g=u(a&&a.max);return{leftPane:{index:n,computedSize:l,min:u(a&&a.min)||(m?d-m:0)||0,max:p,size:r.style[k],collapsible:a&&a.collapsible,uid:a.uid},rightPane:{index:i,computedSize:c,min:u(s&&s.min)||(g?d-g:0)||0,max:f,size:o.style[k],collapsible:s&&s.collapsible,uid:s.uid}}},_resizePane:function(e,n){const i=this;const r=function(e,t,n){return Math.min(n,Math.max(t,e))}(e.computedSize+n,e.min,e.max);let o="";if(E(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,e.isFluid=z(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;const r=i._getPaneElement(t);if(!r)return;i._allExpandedPanesHaveSize()||e(r).addClass(b),r.style[k]=n;let o=e(r).data("pane");o.size=n,o.isFluid=z(n),i.trigger(p,{pane:r})},_getPaneSizes:function(e){const t=this;const n=t._getElementClientSize(t.element,t.options.orientation);const 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):S}},_calculatePixelSize:function(e,n){let i=t.parseFloat(e);return E(e)&&(i=n*i/100),i},_getPaneOffsetSize:function(e){const t=this;const 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===x?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===x?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);const{size:o,min:a,max:s}=this._getPaneSizes(t);const 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(B);var H={sizingProperty:"height",sizingDomProperty:"offsetHeight",alternateSizingProperty:"width",positioningProperty:"top",mousePositioningProperty:"pageY"};var R={sizingProperty:"width",sizingDomProperty:"offsetWidth",alternateSizingProperty:"height",positioningProperty:"left",mousePositioningProperty:"pageX"};function F(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===x?R:H),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)})}F.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}`);const{leftPane:i,rightPane:r}=this.owner._dragSplitterBar(n,e);this.owner.trigger(A,{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===x?"offsetLeft":"offsetTop";const s=i.owner._getElementIndex(r,`.${y}`);const l=i.owner._getPaneElement(s);const c=i.owner._getPaneElement(s+1);let d=e(i.orientation===x&&o?c:l);let h=e(i.orientation===x&&o?l:c);if(e(n.initialTarget).closest(".k-expand-next, .k-expand-prev, .k-collapse-next, .k-collapse-prev").length>0||!h.length||!d.length)n.preventDefault();else{var u=d.data(m),p=h.data(m),f=parseInt(d[0][a],10),g=parseInt(h[0][a],10)+h[0][i.sizingDomProperty]-r[0][i.sizingDomProperty],v=parseInt(i._element.css(i.sizingProperty),10),_=function(e){var t=parseInt(e,10);return(I(e)?t:v*t/100)||0};if(!u||!p)return n.preventDefault(),n.sender.draggable.clickMoveClick.cancel(),void i.owner.element.find(".k-ghost-splitbar").remove();var b=_(u.min),w=_(u.max)||g-f,k=_(p.min),C=_(p.max)||g-f;i.previousPane=d,i.nextPane=h,i._maxPosition=Math.min(g-k,f+w),i._minPosition=Math.max(f+b,g-C)}},_max:function(){return this._maxPosition},_min:function(){return this._minPosition},_resize:function(e){let n=this.owner;let i=n.orientation;let r;let o=this.owner;const a=e.currentTarget||e.target;if(!a)return;const s=n._getElementIndex(a,`.${y}`);const l=t.support.isRtl(this._element)?-1:1;r=i===x?e.x.delta*l:e.y.delta;let c=i===x?a.position().left:a.position().top;let d=e.position;Math.abs(c-d)>2&&o._dragSplitterBar(s,r)},_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===x?n.x.initialDelta:n.y.initialDelta;let t=r.orientation===x?i.position().left:i.position().top;let a=n.position;let s=r.orientation===x&&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(A,{leftPane:c,rightPane:d})}return!1}}}(window.kendo.jQuery);kendo;const a_=[{id:"rewrite",text:"Rewrite",icon:"arrow-rotate-cw",prompt:e=>`Rewrite the selected text while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`},{id:"fix-spelling",text:"Fix spelling",icon:"spell-checker",prompt:e=>`Correct any spelling, grammar, or punctuation mistakes in the selected text while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`},{id:"change-tone",text:"Change tone",icon:"tell-a-friend",items:[{id:"change-tone-neutral",text:"Neutral",prompt:e=>`Adjust the tone of the following text to be more neutral while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`},{id:"change-tone-friendly",text:"Friendly",prompt:e=>`Adjust the tone of the following text to be more friendly while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`},{id:"change-tone-casual",text:"Casual",prompt:e=>`Adjust the tone of the following text to be more casual while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`},{id:"change-tone-formal",text:"Formal",prompt:e=>`Adjust the tone of the following text to be more formal while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`}]},{id:"adjust-length",text:"Adjust length",icon:"col-resize",items:[{id:"adjust-length-shorten",text:"Shorten",prompt:e=>`Shorten the following text while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`},{id:"adjust-length-lengthen",text:"Lengthen",prompt:e=>`Lengthen the following text while preserving its original meaning and intent.\n\n Selected Text:\n ${e}`}]}];!function(e){let t=window.kendo,n=t.ui.Widget,i=t.ui.TextArea,r=t.ui.SpeechToTextButton,o=".kendoInlineAIPrompt",a=t.ui,s="promptRequest",l="promptResponse",c="promptRequestCancel",d="commandExecute",h="outputAction",u="show",p="hide",f="k-speech-to-text-button",m="k-generating",g="k-disabled",v="k-prompt-send",_="!k-align-items-start",b="aria-label",w="aria-disabled",y=a_;var k=e.extend;let x=n.extend({init:function(e,i){let r=this;i=i||{},r.options.systemPrompt=i.systemPrompt||r.options.systemPrompt,n.fn.init.call(r,e,i),i.commands&&(r.options.commands=i.commands),r.transport=new t.data.AiTransport({service:r.options.service,success:r._serviceSuccess.bind(r),requestStart:e=>{r._progress(!0)}}),r._initPopup(),r._initContextMenu(),r._bindEvents(),t.notify(r)},options:{name:"InlineAIPrompt",enable:!0,outputActions:null,encodedPromptOutputs:!0,readonly:!1,placeholder:"",speechToText:!1,service:null,isStreaming:!1,systemPrompt:(e,t)=>`You are an advanced AI language assistant.\n A user has selected a portion of their text and provided a query regarding how they want it modified.\n Your task is to accurately respond to their request while preserving the original intent of the text.\n Follow the instructions strictly and provide only the requested output unless explicitly asked to explain your changes.\n\n Selected Text:\n ${e}\n\n User's Request:\n ${t}\n\n Response:`,commands:y,messages:{promptSend:"Prompt Send",stopOutputRetrieval:"Stop Output Retrieval",commandsMenu:"Commands Menu",retryOutputAction:"Retry",copyOutputAction:"Copy",discardOutputAction:"Discard"}},events:[s,l,c,d,h,u,p],value:function(e){let t=this;t._textArea.value(e),t._textArea.trigger("change"),t._togglePromptSend()},enable:function(e){"boolean"==typeof e&&this._textArea.enable(e)},readonly:function(e){"boolean"==typeof e&&this._textArea.readonly(e)},startStreaming:function(){this._progress(!0)},stopStreaming:function(){let e=this;e._progress(!1),e._togglePromptSend(),e._focusOutputActions()},updatePromptOutputContent:function(e){let n=this._popup.element.find(".k-card-body");const i=this.options.encodedPromptOutputs?t.htmlEncode(e):e;n.html(i)},open:function(e,t){let n=this;if("number"==typeof e&&"number"==typeof t)return void n._popup.open(e,t);const i=n._popup.options.anchor;const r=n._popup.options.origin;const o=n._popup.options.position;n._popup.options.anchor=n.element,n._popup.options.origin="bottom center",n._popup.options.position="top center",n._popup.open(),n._popup.options.anchor=i,n._popup.options.origin=r,n._popup.options.position=o,n._textArea.focus()},close:function(){this._popup.close()},_serviceSuccess:function(e){const n=this,i=n.options.responseTemplate,r=()=>"";if(t.isPresent(i)){let o=t.isFunction(i)?i(e):t.template(i||r)({response:e});n._popup.element.find(".k-card-body").html(o)}else{const i=n.options.encodedPromptOutputs?t.htmlEncode(e.output):e.output;n._popup.element.find(".k-card-body").html(i)}n._popup.element.find(".k-card").show(),n.trigger(l,{response:e}),n._progress(!1),n._togglePromptSend(),n._focusOutputActions()},_initTextArea:function(n){const r=this,o=r.options.messages.promptSend;let a,s=k({},{_isInInlineAIPrompt:!0,enable:r.options.enable,readonly:r.options.readonly,size:"medium",rounded:"medium",overflow:"auto",fillMode:"solid",placeholder:r.options.placeholder||"Edit, generate or explain...",maxRows:5,resize:"auto",layoutFlow:"horizontal",prefixOptions:{separator:!1,template:()=>`${r._renderPrefixTemplate()}`},suffixOptions:{separator:!1,template:()=>`\n ${t.html.renderButton(`<button role='button' class='${v} ${g}' ${b}='${o}' ${w}='true'></button>`,{icon:"paper-plane",fillMode:"flat"})}`}});if(a=new i(n,s),a._prefixContainer.addClass(_),a._suffixContainer.addClass(_),e('<span class="k-input-separator k-input-separator-vertical"></span>').insertBefore(e(a.element)),r.options.speechToText||r.options.speechToText&&void 0===s.speechToText){let e=a._prefixContainer.find(`.${f}`);r._initSpeechToTextButton(e)}return a},_renderPrefixTemplate:function(){let e="";const n=this.options.messages.commandsMenu;if(e+=t.html.renderButton(`<button role='button' title='${n}' ${b}='${n}'></button>`,{icon:"menu",fillMode:"flat"}),this.options.speechToText){e+=`<button role='button' title='Speech To Text' ${b}='Start speech recognition' class='${f}' id='${t.guid()}'></button>`}return e},_initSpeechToTextButton:function(e){const t=this;let n=k({},{fillMode:"flat",integrationMode:t.options.speechToText.integrationMode||"webSpeech",lang:"en-US",continuous:!1,interimResults:!1,maxAlternatives:1,result:function(e){if(e.isFinal&&e.alternatives&&e.alternatives.length>0){let n=t._textArea.value()||"",i=n+(n?" ":"")+e.alternatives[0].transcript;t._textArea.value(i),t._textArea.trigger("change"),t._togglePromptSend()}}},t.options.speechToText);t._speechToTextButton=new r(e,n)},_togglePromptSend:function(){let t=this._textArea;(t.value()||"").replace(/\s/g,"").length?e(t._suffixContainer).find(`.${v}`).removeClass(g).attr(w,!1):e(t._suffixContainer).find(`.${v}`).addClass(g).attr(w,!0)},_initPopup:function(){const n=this,i=e(n._template());const r=n.options.popup;t.isPresent(r)&&(r.width&&i.width(r.width),r.height&&i.height(r.height)),i.css({"max-width":"98vw"}),n._popup=new t.ui.Popup(i,{anchor:n.element,appendTo:r?.appendTo||document.body,isRtl:t.support.isRtl(n.element),animation:r?.animation||{open:{effects:"zoom:in",duration:200},close:{effects:"zoom:out",duration:200}},open:function(e){this.element.find(".k-card").hide(),this.element.find(".k-card-body").empty(),this.element.find(".k-input-inner").val(""),n._textArea.value(""),n._textArea.element.removeAttr("style"),n._togglePromptSend(),n.trigger(u,e)},close:function(e){t.ui.progress(n._popup.element,!1),n._aiContextMenu?.close(),n.trigger(p,e)}});let o=n._popup.element.find("textarea").first();n._textArea=n._initTextArea(o)},_input:function(e){let t=this,n=t._textArea,i=e.currentTarget.value;i!=t._textArea.value()&&(n.value(i),n.trigger("change"),t._togglePromptSend())},_template:function(){const e=`<textarea ${b}='Prompt' id='${t.guid()}'></textarea>`;return`<div class="k-child-animation-container">\n <div class="k-prompt-popup k-popup">\n <div class="k-prompt">\n <div class="k-prompt-content">\n <div class="k-prompt-view">\n <div class="k-card">\n <div class="k-card-body" style="max-height: 150px; overflow-y: auto;"></div>\n <div class="k-actions k-actions-start k-actions-horizontal k-card-actions">\n ${this._renderOutputActions()}\n </div>\n </div>\n ${e}\n </div>\n </div>\n </div>\n </div>\n </div>`},_renderOutputActions:function(){let e=this,n=e.options;const i=e.options.messages.copyOutputAction,r=e.options.messages.retryOutputAction,o=e.options.messages.discardOutputAction;if(t.isPresent(n.outputActions)&&n.outputActions.length){let a="";return n.outputActions.forEach((function(n){if("string"==typeof n)switch(n){case"copy":a+=t.html.renderButton(`<button role='button' title='${i}' ${b}='${i}' ${t.attr("action")}='copy'>${i}</button>`,{icon:"copy",fillMode:"flat",themeColor:"primary"});break;case"retry":a+=t.html.renderButton(`<button role='button' title='${r}' ${b}='${r}' ${t.attr("action")}='retry'>${r}</button>`,{icon:"arrow-rotate-cw",fillMode:"flat",themeColor:"primary"});break;case"discard":a+=t.html.renderButton(`<button role='button' title ='${o}' ${b}='${o}' ${t.attr("action")}='discard'>${o}</button>`,{icon:"cancel-outline",fillMode:"flat"})}else a+=t.html.renderButton(`<button role='button' ${null!=n?.title?`title=${n.title} ${b}=${n.title}`:""} ${t.attr("action")}='${n?.command}'>${n?.text||e._isDefaultOutputAction(n?.command)&&e.options.messages[n?.command+"OutputAction"]||n?.command}</button>`,{rounded:n?.rounded||"medium",icon:n?.icon||e._renderDefaultOutputActionIcon(n?.command),fillMode:n?.fillMode||"flat",themeColor:n?.themeColor||"primary"})})),a}if(e.options._isEditor){return`\n ${t.html.renderButton(`<button role='button' title='${i}' ${b}='${i}' ${t.attr("action")}='copy'>${i}</button>`,{icon:"copy",fillMode:"flat",themeColor:"primary"})}\n ${t.html.renderButton(`<button title='Insert' ${b}="Insert" ${t.attr("action")}='insert'>Insert</button>`,{icon:"insert-bottom",fillMode:"flat",themeColor:"primary"})}\n ${t.html.renderButton(`<button title='Replace' ${b}="Replace" ${t.attr("action")}='replace'>Replace</button>`,{icon:"check",fillMode:"flat",themeColor:"primary"})}\n ${t.html.renderButton(`<button title='Discard' ${b}='Discard' ${t.attr("action")}='discard'>Discard</button>`,{icon:"cancel-outline",fillMode:"flat"})}\n `}return`\n ${t.html.renderButton(`<button role='button' title='${i}' ${b}='${i}' ${t.attr("action")}='copy'>${i}</button>`,{icon:"copy",fillMode:"flat",themeColor:"primary"})}\n ${t.html.renderButton(`<button role='button' title='${r}' ${b}='${r}' ${t.attr("action")}='retry'>${r}</button>`,{icon:"arrow-rotate-cw",fillMode:"flat",themeColor:"primary"})}\n ${t.html.renderButton(`<button role='button' title='${o}' ${b}='${o}' ${t.attr("action")}='discard'>${o}</button>`,{icon:"cancel-outline",fillMode:"flat"})}\n `},_renderDefaultOutputActionIcon(e){if(this._isDefaultOutputAction(e))switch(e){case"copy":return"copy";case"discard":return"cancel-outline";case"retry":return"arrow-rotate-cw";default:return}},_isDefaultOutputAction(e){switch(e){case"copy":case"discard":case"retry":return!0;default:return!1}},_initContextMenu:function(){const t=this;if(!t.options.commands||0===t.options.commands?.length)return void t._popup.element.find(".k-input-prefix button").addClass("k-disabled");const n=t.options.commands.map((e=>t._createCommandHtml(e))).join("");const i=e(`<ul>\n ${n}\n </ul>`);e("body").append(i),t._aiContextMenu=i.kendoContextMenu({target:t._popup.element,anchor:t._popup.element,showOn:"click",appendTo:e(document.body),filter:".invalid",select:t._executeCommand.bind(t)}).data("kendoContextMenu")},_createCommandHtml:function(e){const n=this;const i=n._renderCommandIcon(e.icon);const r=e.text;const o=(e.items||[]).map((e=>n._createCommandHtml(e))).join("");return`<li ${t.attr("name")}=${e.id}>${i} ${r}${o?"<ul>"+o+"</ul>":""}</li>`},_renderCommandIcon:function(e){return t.isPresent(e)?t.isFunction(e)?e():t.html.renderIcon({icon:e}):""},_executeCommand:function(e){const n=this;let i=n._findCommand(n.options.commands,e.item.getAttribute(t.attr("name")));let r={query:i.id,selection:""};if(n._clearSelectedCommands(n.options.commands),t.isPresent(n._textArea)){const e=n._textArea.value();t.isPresent(e)&&""!=e&&(r.selection=e)}n.trigger(d,r);const o=r.selection||r.context;if(t.isPresent(i.prompt)){const e=i.prompt(o);n._requestService(e),n._aiContextMenu?.close()}i.selected=!0},_clearSelectedCommands:function(e){const n=this;e.forEach((function(e){t.isPresent(e.items)&&e.items.length>0&&n._clearSelectedCommands(e.items),e.hasOwnProperty("selected")&&delete e.selected}))},_findCommand:function(e,t,n=!1){const i=this;for(let r of e){if(n&&r.selected)return r;if(r.id===t)return r;if(r.items){let e=i._findCommand(r.items,t,n);if(e)return e}}},_bindEvents:function(){const n=this,i=n._popup,r=i.element;n._textArea.element.on("input"+o,n._input.bind(n)),r.find(`.k-input-prefix button[aria-label='${n.options.messages.commandsMenu}']`).on("click",(function(){n._aiContextMenu?.open()})),n._textArea._suffixContainer.find(`.${v}`).on("click",(function(){const e=n._textArea.value();n._requestService(e)})),r.find(".k-card-actions button").on("click",(function(o){let a=r.find(".k-card-body"),s=a.text(),l=t.isPresent(n._textArea)?n._textArea.value():"",c=n._findCommand(n.options.commands,0,!0),d=t.isPresent(c)?c.prompt(l):l;const u=e(o.currentTarget).attr(t.attr("action"));switch(u){case"copy":navigator.clipboard.writeText(s),n.trigger(h,{action:u,content:s});break;case"retry":n._requestService(d),n.trigger(h,{action:u,content:s});break;case"discard":a.empty(),r.find(".k-card").hide(),r.find(".k-input-inner").val(""),n.trigger(h,{action:u,content:s}),i.close();break;default:n.trigger(h,{action:u,content:s})}}))},_stopOutputRetrievalButton:function(e){let n=this;if(e){let e=n.options.messages.stopOutputRetrieval,i=t.html.renderButton(`<button role='button' title='${e}' ${b}='${e}' class='${v} ${m}'></button>`,{icon:"stop-sm",fillMode:"flat"});n._textArea._suffixContainer.find(`.${v}`).replaceWith(i),n._textArea._suffixContainer.find(`.${m}`).on("click",(function(e){n.trigger(c,n)}))}else{let e=n.options.messages.promptSend;let i=t.html.renderButton(`<button role='button' title="${e}" ${b}=${e} class='${v} ${g}'></button>`,{icon:"paper-plane",fillMode:"flat"});n._textArea._suffixContainer.find(`.${m}`).replaceWith(i),n._textArea._suffixContainer.find(`.${v}`).on("click",(function(e){const t=n._textArea.value();n._requestService(t)}))}},_progress:function(e){this._stopOutputRetrievalButton(e),this._toggleSkeleton(e)},_toggleSkeleton:function(t){let n=this;n.skeleton&&n.skeleton.remove(),t?(n.skeleton=e("<span class='k-skeleton k-rounded-md k-skeleton-pulse'></span>").css({width:"100%",height:"100%"}),n._textArea._suffixContainer.find(`.${m}`).wrap(n.skeleton)):n._textArea._suffixContainer.find(`.${v}`).unwrap()},_requestService:function(e){const t=this;const n="";if(!e.trim())return;const i=n;const r=t.options.systemPrompt(i,e);t.trigger(s,{prompt:r}),t.options.isStreaming&&t._popup.element.find(".k-card").show(),t.options.service&&t.transport.read({prompt:r,history:[],isRetry:!1})},_focusOutputActions(){let t=this,n=t._popup.element.find(".k-actions"),i=n.children("button");n.find(e(document.activeElement)).length?0==i.length&&t._textArea.focus():e(i).first().focus()},focus:function(){this.element.trigger("focus")},setOptions:function(e){let n=this;n.destroy(),t.deepExtend(this.options,e),n.init(n.element,e)},destroy:function(){let e=this;e._popup?.close(),e._textArea?.destroy(),e._speechToTextButton?.destroy(),e._aiContextMenu?.destroy(),e.toolbar?.destroy(),e._selectedView?.destroy(),e._popup?.destroy(),e.element.off(o),n.fn.destroy.call(e)}});a.plugin(x)}(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,h=n._outerHeight;const u="formatting-marks-style",p="formatting-marks-overlay",f="formatting-marks-overlay-wrapper";var m="select";var g="k-placeholder";var v="placeholder";var _=["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}};var w=void 0!==document.documentElement.contentEditable;var y={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"]};var k=r.extend({__suppressEditableCheck:!1,init:function(e,i){var o,a,s,c=this,d=n.ui.editor,h=d.Dom;(w||c.__suppressEditableCheck)&&(r.fn.init.call(c,e,i),c.options=l({},c.options,i),s=(e=c.element)[0],a=h.name(s),this._registerHandler(e.closest("form"),"submit",c.update.bind(c,t)),c._isAiPromptEnabled()&&c._addAIPromptElements(),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]),c._isAiPromptEnabled()&&c._initAIPrompt(),c._isInlineAIPromptEnabled()&&c._initInlineAIPrompt())},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"],ai:!1},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=this;var r=null;var o=n.ui.Editor.defaultTools;var a,l;if(!e)throw new Error("kendoEditor.exec(): `name` parameter cannot be empty");if("true"!==i.body.getAttribute("contenteditable")&&"print"!==e&&"pdf"!==e&&"exportAs"!==e)return!1;if(i.keyboard.isTypingInProgress()||(i._focusBody(),i.selectRange(i._range||i.getRange())),(l=i.tools[e]||o[e])||Object.keys(o).map((t=>{t.toLowerCase()===e&&(l=o[t])})),l){if(a=i.getRange(),l.command&&(r=l.command(s({range:a,body:i.body,immutables:!!i.immutables},t))),i.trigger("execute",{name:e,command:r}))return;if(/^(undo|redo)$/i.test(e))i.undoRedoStack[e]();else if(r&&(i.execCommand(r),r.async))return void(r.change=i._commandChange.bind(i));"formattingMarks"!==e&&i._handleSpaceAndNewLines(),i._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()},insertAfterSelection:function(t,i){this.focus();const r=this.getRange();r.collapse(!1);var o=new n.ui.editor.InsertHtmlCommand(e.extend({range:r,html:t},i));o.editor=this,o.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=n.ui.Editor.defaultTools[e];var i=t&&(t.options.finder||t.finder);var r=n.ui.editor.RangeUtils;var o,a;return!!i&&(o=this.getRange(),!(a=r.textNodes(o)).length&&o.collapsed&&(a=[o.startContainer]),i.getFormat?i.getFormat(a):i.isFormatted(a))},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;var t=e?e.val():this._oldValue;var 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;var i=this.body;return e&&t.isAncestorOrSelf(i,e.startContainer)&&t.isAncestorOrSelf(i,e.endContainer)},_createContentElement:function(t){var i=this;var r,s,l;var c=i.textarea;var d=i.options.domain;var h=d||document.domain;var u="";var p='javascript:""';var f;c.hide(),r=e("<iframe />",{title:i.options.messages.editAreaTitle,frameBorder:"0"})[0],e(r).css("display","").addClass("k-content k-iframe").attr("tabindex",c[0].tabIndex).insertBefore(c),(d||h!=location.hostname)&&(p="javascript:document.write('"+(u=`<script ${i.options.nonce?`nonce="${i.options.nonce}"`:""}>document.domain="${h}"<\/script>`)+"')",r.src=p),r.src||(r.src=""),s=r.contentWindow||r,l=s.document||r.contentDocument;const m=i.interSectionObserver=new IntersectionObserver((e=>{for(const t of e)t.isIntersecting&&(i._decorateFormatting(l.body),m.unobserve(r))}));return m.observe(r),f=document.getElementsByTagName("html")[0].getAttribute("lang")||"en",l.open(),l.write("<!DOCTYPE html><html lang='"+f+"'><head><meta charset='utf-8' /><title>Kendo UI Editor content</title>"+`<style ${i.options.nonce?`nonce="${i.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(c)?"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>"+u+e.map(t,(function(e){return`<link rel='stylesheet' href='${e}' ${i.options.nonce?`nonce="${i.options.nonce}"`:""}>`})).join("")+`</head><body id='${i.element.attr("id")}' autocorrect='off' contenteditable='true'></body></html>`),l.close(),s},_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]"),h=n.ui.editor.Dom;if(d.length){if(!(i=d.getKendoDropDownList()))return;if(o=(r=i.dataSource).data(),t&&i.list.css("background-color",h.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=h.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='${u+"-"+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("#"+u+"-"+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("#"+u+"-"+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))},_addAIPromptElements:function(){const t=this;const n=e("<div/>");const i=e("<div/>");t.splitterElement=n,t.aiPromptElement=i,n.insertBefore(t.element),i.appendTo(n),t.element.appendTo(n)},_initInlineAIPrompt:function(){const t=this;const i=e("<div/>").insertAfter(t.element);const r=t._mapCommands(t.options.ai?.inlineAIPrompt?.commands||t.options.ai?.commands||n.ui.InlineAIPrompt.fn.options.commands);t.inlineAIPrompt=i.kendoInlineAIPrompt({popup:{width:"768px"},service:t.options.ai?.service,commands:r,_isEditor:!0,systemPrompt:t.options.ai?.inlineAIPrompt?.systemPrompt,commandExecute:e=>{e.context=t.getRange().toString()},outputAction:e=>{"insert"===e.action&&t.insertAfterSelection(e.content),"replace"===e.action&&t.paste(e.content)}}).data("kendoInlineAIPrompt")},_mapCommands:function(e,t=null){const n=this;return e.map(((e,i)=>{const r=t?`${t}-${i}`:`${i}`;const o={id:r,text:e.text,icon:e.icon};return e.prompt&&(o.prompt=e.prompt),e.items&&(o.items=n._mapCommands(e.items,r)),o}))},_isAiPromptEnabled(){return this.options.ai&&0!=this.options.ai.aiPrompt},_isInlineAIPromptEnabled(){return this.options.ai&&0!=this.options.ai.inlineAIPrompt},_initAIPrompt:function(){const t=this;const i=t.options.ai?.aiPrompt?.commands||t.options.ai?.commands||t._mapCommands(n.ui.InlineAIPrompt.fn.options.commands);t.aiPrompt=t.aiPromptElement.kendoAIPrompt(e.extend({service:t.options.ai?.service,speechToText:!1,promptTextArea:{rows:5,suffixOptions:{template:()=>"<div ref-select-context-buttongroup></div>"}},views:[{type:"prompt",buttonIcon:"",themeColor:"base",initializeComponents:e=>{e.view.contentElement.find("[ref-select-context-buttongroup]").kendoButtonGroup({index:t._contextSelection,items:[{text:"Use with selection",icon:"box-sizing"},{text:"Use full content",icon:"form-element"}],selection:"multiple",fillMode:"flat",select:e=>{let n=e.sender._buttons[0];let i=e.sender._buttons[1];e.indices.length>1&&(e.target[0]==n.element[0]?(i.toggle(!1),e.sender._toggleIndex(1)):(n.toggle(!1),e.sender._toggleIndex(0))),t._contextSelection=e.indices[0]}})}},{type:"output",themeColor:"base"},{type:"commands",themeColor:"base",promptCommands:i}],promptRequest:e=>{const n=t._contextSelection;let i=e.prompt;i=0===n?t._contextTemplate(i,t.getRange().toString()):1===n?t._contextTemplate(i,t.value()):t._contextTemplate(i,""),e.prompt!=i&&(e.prompt=i)},commandExecute:e=>{const n=e.item.prompt;n&&t.aiPrompt.transport.read({prompt:n(t.value()),history:[],isRetry:!1})}},t.options.ai?.aiPrompt)).data("kendoAIPrompt"),t.aiPromptSplitter=t.splitterElement.kendoSplitter({panes:[e.extend({size:"50%",collapsible:!0,collapsed:!0,min:"360px"},t.options.ai?.pane),{}]}).data("kendoSplitter"),t._isInlineAIPromptEnabled()&&t.bind("select",t._selectionChangeHandler.bind(t))},_contextTemplate:function(e,t){const n=`You are an advanced AI language assistant.\n A user has selected a portion of their text and provided a query regarding how they want it modified.\n Your task is to accurately respond to their request while preserving the original intent of the text.\n Follow the instructions strictly and provide only the requested output unless explicitly asked to explain your changes.\n\n ${t?"Selected Text:":""}\n ${t}\n\n User's Request:\n ${e}\n\n Response:`;return this.options.ai?.aiPrompt?.systemPrompt?this.options.ai?.aiPrompt?.systemPrompt(e,t):n},_selectionChangeHandler:function(){const e=this,t=e.getRange(),i=t.getBoundingClientRect(),r=e.wrapper[0].getBoundingClientRect();if(0===n.ui.editor.RangeUtils.textNodes(t).length)return void e.inlineAIPrompt._popup.close();e.inlineAIPrompt._popup.open();const o=e.inlineAIPrompt._popup.element.outerHeight();const a=e.inlineAIPrompt._popup.element.outerWidth();let s=window.scrollY+r.top+i.top+i.height;let l=window.scrollX+r.left+i.left+i.width/2-a/2;e.inlineAIPrompt._popup.close(!0),window.innerHeight-i.bottom<o?s-=o:s+=o,l+a>window.innerWidth+window.scrollX&&(l=window.innerWidth+window.scrollX-a),e.inlineAIPrompt._popup.open(l,s)},_getSelectionPosition:function(){this.getRange().getBoundingClientRect()},_initContextMenu:function(){const t=e(`<ul>\n <li>${n.html.renderIcon({icon:"arrow-rotate-cw"})} Rewrite</li>\n <li>${n.html.renderIcon({icon:"spell-checker"})} Fix mistakes</li>\n <li>${n.html.renderIcon({icon:"tell-a-friend"})} Change tone\n <ul>\n <li>Neutral</li>\n <li>Friendly</li>\n <li>Casual</li>\n <li>Formal</li>\n </ul>\n </li>\n <li>${n.html.renderIcon({icon:"apply-format"})} Polish formatting\n <li>${n.html.renderIcon({icon:"col-resize"})} Adjust length\n <li>${n.html.renderIcon({icon:"edit-tools"})} Translate\n </ul>`);e("body").append(t),this._aiContextMenu=t.kendoContextMenu({targe:"imposibru"}).data("kendoContextMenu")},_insertAIResult:function(){this.paste("Test ai result")},_deregisterHandlers:function(){var e=this._handlers;for(var 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=this.body;var t=this.wrapper&&this.wrapper.find("iframe")[0];var i=this.document.documentElement;var r=n._activeElement();var o;!t&&e.scrollHeight>e.clientHeight?(o=e.scrollTop,e.focus(),e.scrollTop=o):r!=e&&r!=t&&(o=i.scrollTop,e.focus(),i.scrollTop=o)},_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=this;var r;var o;var a;if(i.textarea){if(i.window=i._createContentElement(i.options.stylesheets),!(r=i.document=i.window.contentDocument||i.window.document).body){var s=r.createElement("body");s.setAttribute("contenteditable","true"),s.setAttribute("autocorrect","off"),r.getElementsByTagName("html")[0].appendChild(s);var l=setInterval((function(){e(i.document).find("body").length>1&&(e(i.document).find("body").last().remove(),window.clearInterval(l))}),10)}i.body=r.body,o=i.window,a=r,this._registerHandler(r,"mouseup",this._mouseup.bind(this))}else i.window=window,r=i.document=document,i.body=i.element[0],o=i.body,a=i.body,i._wrapSingleTextNodeInParagraph(),setTimeout((()=>{i._decorateFormatting(i.body)}));this._registerHandler(o,"blur",this._blur.bind(this)),i._registerHandler(a,"down",i._mousedown.bind(i));try{r.execCommand("enableInlineTableEditing",null,!1)}catch(e){}n.support.touch&&this._registerHandler(r,{keydown:function(){n._activeElement()!=r.body&&i.window.focus()}}),this._initializePlaceholder(),this._spellCorrect(i),this._registerHandler(i.document,{"mouseover dragenter":function(t){var n=e(i.body).height();e(i.body.parentElement).height()>n&&"html"===t.target.nodeName.toLowerCase()&&(i._cachedHeight=""+i.body.style.height,i.body.style.height="100%")},"mouseout dragleave drop contextmenu":function(e){var n=function(){i._cachedHeight!==t&&e.target===i.body&&(i.body.style.height=i._cachedHeight,delete i._cachedHeight)};"contextmenu"===e.type?setTimeout((function(){n()}),10):n()}}),this._registerHandler(i.body,{keydown:function(e){var t;if((e.keyCode===c.BACKSPACE||e.keyCode===c.DELETE)&&"true"!==i.body.getAttribute("contenteditable"))return!1;if(e.keyCode===c.F10)return i.toolbar.element.find("[tabindex=0]").first().trigger("focus"),i.toolbar.preventPopupHide=!0,void e.preventDefault();if(e.keyCode==c.LEFT||e.keyCode==c.RIGHT){t=i.getRange();var n=e.keyCode==c.LEFT;var r=t[n?"startContainer":"endContainer"];var o=t[n?"startOffset":"endOffset"];var a=o+(n?-1:1);var s=n?a:o;3==r.nodeType&&"\ufeff"==r.nodeValue[s]&&(t.setStart(r,a),t.collapse(!0),i.selectRange(t))}var l=i.tools;var d=i.keyboard.toolFromShortcut(l,e);var h=d?l[d].options:{};if(d&&!h.keyPressCommand)return e.preventDefault(),/^(undo|redo)$/.test(d)||i.keyboard.endTyping(!0),i.trigger("keydown",e),i.exec(d),i._runPostContentKeyCommands(e),!1;i.keyboard.clearTimeout(),i.keyboard.keydown(e)},keypress:function(e){setTimeout((function(){i._runPostContentKeyCommands(e),i._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(){i._selectionChange()}),200)),t.keyCode!==c.BACKSPACE&&t.keyCode!==c.DELETE||i._handleSpaceAndNewLines(),i.keyboard.keyup(t)},click:function(e){var t;"img"===n.ui.editor.Dom.name(e.target)&&((t=i.createRange()).selectNode(e.target),i.selectRange(t))},"cut copy paste drop dragover":function(e){i.clipboard["on"+e.type](e),i._handleSpaceAndNewLines()},focusin:function(){i.body.hasAttribute("contenteditable")&&(e(this).addClass("k-active"),i._showWindow(),i._togglePlaceholder(!1))},focusout:function(){setTimeout((function(){var t=n._activeElement();var r=i.body;var o=i.toolbar;if(o.options.popup){var a=i.windowInstance.element.get(0);a&&!e.contains(a,t)&&a!=t&&(o.preventPopupHide=!1)}t==r||e.contains(r,t)||i._toolbarFocused()||o.preventPopupHide||e(t).hasClass("k-context-menu")||e(t).hasClass("k-colorpalette")||(e(r).removeClass("k-active"),i._hideWindow()),i._togglePlaceholder(!i.value().trim())}),10)}}),i._initializeColumnResizing(),i._initializeRowResizing(),i._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(i){var r,o,a,s=this;if(s.tools=[],[r,o]=s._processToolbarItems(s.options.tools),s._setNativeTools(),a={tools:r,defaultTools:o,parentMessages:s.options.messages,resizable:!0===s.options.resizable||Boolean(s.options.resizable&&s.options.resizable.toolbar&&"none"!==s.options.resizable.toolbar?.mode),toggle:s._handleToolbarClick.bind(this),click:s._handleToolbarClick.bind(this),navigateOnTab:s.options.navigateOnTab,evaluateTemplates:!0,overflow:e.isPlainObject(s.options.resizable?.toolbar)?s.options.resizable.toolbar:t},s.toolbar=new n.ui.ToolBar(i,a),s._bindTools(),s.bind("select",s._refreshTools.bind(s)),i.on("mousedown.kendoEditor",(function(t){const n=e(t.target);const i=n.closest("[ref-toolbar-tool]");i.length&&i.data("command")&&(i.length&&n.is("input")||t.preventDefault())})),!s.textarea){const e=i.width();e&&e>0&&i.width(e),s._initToolbarWindow(i)}},_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={},h={},u=e.extend(!0,{},y);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&&(u=this._resetGroups(u)),Object.keys(u).map((e=>{u[e].includes(l)&&(d[l].gr=e)}))}return Object.values(d).map((e=>{var n=e.gr;delete e.gr,n===t?h[e.name]=e:(h[n]||(h[n]=[]),h[n].push(e))})),r=Object.values(h).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,h,u,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||{},h=b.getToolCssClass(c.name,c.icon),delete(p=e.isPlainObject(i)?e.extend({},i):{}).items,u=e.extend({name:c.name,command:c.command,template:c.template,attributes:{class:c.cssClass},type:"button",icon:h,showText:"overflow",showIcon:"both"},d,p),c.tooltip&&(u.attributes||(u.attributes={}),u.attributes.title=c.tooltip),c.exec&&(u.click=c.exec.bind(m),delete u.exec),"ColorPicker"===u.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",u.componentOptions.palette="palette"===s?f:t,u.componentOptions.views=[s],u.componentOptions.preview="gradient"===s,u.componentOptions.input="gradient"===s,u.componentOptions.buttons="gradient"===s,"gradient"===s&&delete u.componentOptions.columns),"palette"===s&&c.columns&&(u.componentOptions.columns=c.columns)),"DropDownList"!==u.component&&"ComboBox"!==u.component||(u.componentOptions||(u.componentOptions={}),u.componentOptions.dataSource||(m.options[a]&&Array.isArray(m.options[a])?u.componentOptions.dataSource=m.options[a]:u.componentOptions.dataSource=c.items)),u.template&&delete u.type,""!==(l=this._shortcutSequence(a))&&(u.attributes||(u.attributes={}),u.attributes["aria-keyshortcuts"]=l),r[a]=u,[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=".kendoEditor";var a;var s;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(a=n.applyEventMap(i).split(" "),s=0;s<a.length;s++)this._handlers.push({element:t,type:a[s]+o,handler:r}),t.on(a[s]+o,r)},_runPostContentKeyCommands:function(e){const t=this.getRange();const n=this.keyboard.toolsFromShortcut(this.tools,e);for(var i=0;i<n.length;i++){var r=n[i];var o=r.options;if(o.keyPressCommand)new o.command({range:t}).changesContent()&&(this.keyboard.endTyping(!0),this.exec(r.name))}this._wrapSingleTextNodeInParagraph(),this._handleSpaceAndNewLines()},_wrapSingleTextNodeInParagraph:function(){const e=this.body.childNodes;const t=n.ui.editor.Dom;this.textarea||1===e.length&&e[0].nodeType===t.nodeTypes.TEXT_NODE&&t.wrap(e[0],this.document.createElement("p"))},_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(i){var r,o,a,s=this,l=s.toolbar,c=l.element;l.destroy(),c.empty(),s.tools=[],[r,o]=s._processToolbarItems(i),s._setNativeTools(),a={tools:r,defaultTools:o,parentMessages:s.options.messages,resizable:!0===s.options.resizable||Boolean(s.options.resizable&&s.options.resizable.toolbar&&"none"!==s.options.resizable.toolbar?.mode),toggle:s._handleToolbarClick.bind(this),click:s._handleToolbarClick.bind(this),overflow:e.isPlainObject(s.options.resizable?.toolbar)?s.options.resizable.toolbar:t},s.toolbar=new n.ui.ToolBar(c,a),s._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;var n=parseInt(e,10);var 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;var 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){let a=this.toolbar,s=i.name,l=a.overflowAnchor,c=r.closest("[ref-toolbar-tool]"),d=i.options.trackImmutables,h=!0,u=n.ui.editor;if(d===t&&(d=e.inArray(s,u.Immutables.toolsToBeUpdated)>-1),l&&!l.hasClass("k-hidden")){const e=a.overflowMenu,t=e?.element.find(`[data-command="${i.options.name}"]`);h=t?.hasClass("k-hidden")}d&&(o?a.hide(c):h&&a.show(c))},_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;let i=this.options.resizable;let r=e.isPlainObject(i)?i.content===t||!0===i.content:i;let o=e.isPlainObject(i.min)?i.min:{minHeight:i.min};let 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;var 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)-h(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";var T=S;(a.msie||a.edge)&&(T=S=" "),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;var i=t.promise();var 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 h(e){var t,n,i={};for(t=0,n=e.length;t<n;t++)i[e[t]]=!0;return i}var u=h("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=h(f),g=h("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(","),_=h(v),b=h("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected".split(",")),w=["hgroup","ol","ul","dl","object","video","audio","table","colgroup","tbody","thead","tfoot","tr","select","optgroup"];var y=function(e){1==e.nodeType&&e.normalize()};r.msie&&r.version>=8&&(y=function(e){if(1==e.nodeType&&e.firstChild){var t=e.firstChild,n=t;for(y(n);n=n.nextSibling;)y(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,M=/^(\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(","),D=/[<>&]/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"};var 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){var t=[];var n=document.createNodeIterator(e,NodeFilter.SHOW_COMMENT,(function(){return NodeFilter.FILTER_ACCEPT}),!1);var i=n.nextNode();for(;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){var n=e.cloneNode(!1);var i="";var r=e.nextSibling;var o;for(;r&&3==r.nodeType&&r.nodeValue;)i+=r.nodeValue,o=r,r=r.nextSibling,z.remove(o);e.deleteData(t,e.length),n.deleteData(0,t),n.nodeValue+=i,z.insertAfter(n,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:y,blockElements:f,nonListBlockElements:p,inlineElements:v,empty:u,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:D;return e.replace(n,(function(e){var t=e.charCodeAt(0);var 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&&!u[t]&&z.emptyNode(e))}))},emptyTextNode:function(e){return e&&3==e.nodeType&&M.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 w.every((function(n){return!z.is(e,n)||(t=!1,!1)})),t},allWhitespaceContent:function(e){var t=e.firstChild;for(;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};var i=t.parentNode;var r=n(t,"previousSibling");var 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);var 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 u[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=t.ownerDocument;var r=z.windowFromDocument(i).innerHeight;var o=z.scrollContainer(i);var a,s,l,c;z.isDataNode(t)?n?(c=z.create(i,"span",{innerHTML:""}),z.insertBefore(c,t),a=e(c)):a=e(t.parentNode):a=e(t),s=a.offset().top,l=a[0].offsetHeight,!n&&l||(l=parseInt(a.css("line-height"),10)||Math.ceil(1.2*parseInt(a.css("font-size"),10))||15),c&&z.remove(c),l+s>o.scrollTop+r&&(o.scrollTop=l+s-r)},persistScrollTop:function(e){k=z.scrollContainer(e).scrollTop},offset:function(e,t){var n={top:e.offsetTop,left:e.offsetLeft};var i=e.offsetParent;for(;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){var t=e.parentNode;for(;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),h=e.attributes;if(!n)for(i=0,r=h.length;i<r;i++)(l=h[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){var t=e.parentNode;for(;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);var o=z.commonAncestor(r)[0];return e.contains(i,o)&&(i=o),i},closestEditable:function(t,n){var i;var 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){var i=0;var r=e.length;var o=[];var a;for(;i<r;i++)((a=t(e[i]))&&!n||!a&&n)&&o.push(e[i]);return o},ensureTrailingBreaks:function(t){var n=e(t).find("p,td,th");var i=n.length;var 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=e.lastChild;var n=t&&z.name(t);var i;(!n||"br"!=n&&"img"!=n||"br"==n&&"k-br"!=t.className)&&((i=e.ownerDocument.createElement("br")).className="k-br",e.appendChild(i))},reMapTableColumns:function(e,t){z._mapColIndices(e,t)},clearTableMappings:function(t,n){e(t).find("["+n+"]").removeAttr(n)},_mapColIndices:function(e,t){var n={};for(var i=0;i<e.rows.length;i++){var r=e.rows[i].cells;var o=0;for(var 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){var r,o=e.rowSpan,a=e.colSpan;for(var 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=this;var n=0;var i=e.rows;var r=i.length;var o=[];var a=[];var s,l;if(e.tHead)n=(s=e.tHead.rows).length;else for(n=t._getNumberOfHeaderRows(e),s=[],l=0;l<n;l++)s.push(i[l]);for(l=0;l<n;l++)o.push([]);for(l=0;l<r;l++)a.push([]);t._generateIdsForColumns(o,s),t._generateIdsForRows(o,a,n,i),t._assignIds(o,a,n,i)},_generateIdsForColumns:function(e,t){var n=(new Date).getTime();var i=t?t.length:0;var r,o,a,s,l,c,d,h,u,p;for(d=0;d<i;d++)for(r=t[d].cells,a=0,h=0;h<r.length;h++){for(s="table"+d+h+ ++n,(o=r[h]).setAttribute("id",s),l=o.getAttribute("colspan")||1,c=o.getAttribute("rowspan")||1;e[d][h+a];)a+=1;for(u=0;u<c;u++)for(p=0;p<l;p++)e[d+u][h+a+p]=s}},_generateIdsForRows:function(t,n,i,r){var o=(new Date).getTime();var a=r.length;var s,l,c,d,h,u,p,f,m,g,v,_,b;var w=function(e){b.push(e[_])};for(f=i;f<a;f++)for(s=r[f],l=e(s.cells).filter("th"),d=0,m=0;m<l.length;m++){for(h="table"+f+m+ ++o,(c=l[m]).setAttribute("id",h),u=c.getAttribute("colspan")||1,p=c.getAttribute("rowspan")||1;n[f][m+d];)d+=1;for(g=0;g<p;g++)for(v=0;v<u;v++)n[f+g][m+d+v]=h;_=c.getAttribute("col-index"),b=[],t.forEach(w),b=b.filter(this._onlyUnique),c.setAttribute("headers",b.join(" ").trim())}},_assignIds:function(t,n,i,r){var o=r.length;var a,s,l,c,d,h,u;var p=function(e){u.push(e[h])};for(c=i;c<o;c++)for(a=r[c],s=e(a.cells).filter("td"),d=0;d<s.length;d++)l=s[d],h=l.getAttribute("col-index"),u=n[c].slice(),t.forEach(p),u=u.filter(this._onlyUnique),l.setAttribute("headers",u.join(" ").trim())},_getNumberOfColumns:function(t){var n=e(t).find("th, td");var i=0;var r,o,a;for(o=0;o<n.length;o++)r=n[o],(a=Number(r.getAttribute("col-index"))+1)>i&&(i=a);return i},_getNumberOfHeaderColumns:function(e,t){var n=e.rows;var i=0;var r,o,a,s,l;for(a=t;a<n.length;a++)for(o=n[a],s=0;s<o.cells.length;s++)l=o.cells[s],this.is(l,"th")&&(r=Number(l.getAttribute("col-index"))+1)>i&&(i=r);return i},_getNumberOfHeaderRows:function(e){var t=e.rows;var n=e.tHead&&e.tHead.rows?e.tHead.rows.length:0;var i,r,o,a;if(0===n)for(a=(r=t[0]).cells&&r.cells.length;r&&a&&this.is(r.cells[0],"th");){for(i=0;i<a;i++)o=r?r.cells[i]:null,this.is(o,"th")||(r=null);r&&(n+=1,a=(r=this.next(r))&&r.cells&&r.cells.length)}return n},_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;var i=n.ui.editor;var r=i.Dom;var o=e.extend;var a="xx-small,x-small,small,medium,large,x-large,xx-large".split(",");var s=/"/g;var l=/<br[^>]*>/i;var c=/^\d+(\.\d*)?(px)?$/i;var d=/<p>(?: )?<\/p>/i;var h=/(\*?[-#\/\*\\\w]+(?:\[[0-9a-z_-]+\])?)\s*:\s*((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+)/g;var u=/^sizzle-\d+/i;var p=/^k-script-/i;var f=/\s*onerror\s*=\s*(?:'|")?([^'">\s]*)(?:'|")?/i;var m='<br class="k-br">';var g="<span class='k-br'>\ufeff</span>";var v=document.createElement("div");v.innerHTML=" <hr>";var _=3===v.firstChild.nodeType;v=null;var b=n.isFunction;var w={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]*( |\u00a0)/i,"$1").replace(/<\/(table|blockquote)>$/i,"</$1>"+m)},_toEditableImmutables:function(t){var n=i.Immutables.immutable,o=r.emptyTextNode,a=t.firstChild,s=t.lastChild;for(;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){var i=this;for(;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=this.attributes;var t,n,i,r;var o=[];for(n=0,i=e.length;n<i;n++)r=(t=e[n]).nodeName,t.specified&&/^on/i.test(r)&&(this.setAttribute("k-script-"+r,t.value),o.push(r));for(n=0,i=o.length;n<i;n++)this.removeAttribute(o[n])}))},htmlToDom:function(t,i,o){var a=n.support.browser.msie;var s=o||{};var l=s.immutables;return t=w.toEditableHtml(t),b(s.custom)&&(t=s.custom(t)||t),i.innerHTML=t,l&&l.deserialize(i),a&&(r.normalize(i),w._resetOrderedLists(i)),w._preventScriptExecution(i),w._fillEmptyElements(i),w._removeSystemElements(i),w._toEditableImmutables(i),e("table",i).addClass("k-table"),i},domToXhtml:function(o,f){var m=[];var 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 w={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;var 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=[];var 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);var i=e(n).filter((function(e,t){return"style"==t.name}))[0];var 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");var n=a[e.getAttribute("size")];var 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 y(e){var t=function(e){var t=n.trim;var i=t(e);var o;var a,l;var c=[];for(h.lastIndex=0;o=h.exec(i);)a=t(o[1].toLowerCase()),l=t(o[2]),"font-size-adjust"!=a&&"font-stretch"!=a&&(a.indexOf("color")>=0?l=r.toHex(l):a.indexOf("font")>=0?l=l.replace(s,"'"):/\burl\(/g.test(l)&&(l=l.replace(s,"")),c.push({property:a,value:l}));return c}(e);var i;for(i=0;i<t.length;i++)m.push(t[i].property),m.push(":"),m.push(t[i].value),m.push(";")}function k(e){var t=[];var n=e.attributes;var i,o,a;var s,l,c;for(o=0,a=n.length;o<a;o++)s=(i=n[o]).nodeName,l=i.value,c=i.specified,"value"==s&&"value"in e&&e.value||"type"==s&&"text"==l?c=!0:"class"!=s||l?u.test(s)||"complete"==s||"altHtml"==s||"start"==s&&r.is(e,"ul")||"start"==s&&r.is(e,"ol")&&"1"==l||s.indexOf("_moz")>=0?c=!1:p.test(s)?c=!!f.scripts:"data-role"==s&&"resizable"==l&&(r.is(e,"tr")||r.is(e,"td"))&&(c=!1):c=!1,c&&t.push(i);return t}function x(i,o){var a,s,l,d,h;if(o=o||k(i),r.is(i,"img")){var u=i.style.width,f=i.style.height,g=e(i);u&&c.test(u)&&(g.attr("width",parseInt(u,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,h=l.value,"class"==d&&"k-table"==h||(d=d.replace(p,""),m.push(" "),m.push(d),m.push('="'),"style"==d?y(h||i.style.cssText):"src"==d||"href"==d?m.push(n.htmlEncode(i.getAttribute(d,2))):m.push(r.fillAttrs[d]?d:h),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,h,u=t.nodeType;if(g&&i.Immutables.immutable(t))m.push(g.serialize(t));else if(1==u){if(a=r.name(t),(h=e(t)).hasClass("k-element-resize-handle-wrapper")||h.hasClass("k-column-resize-handle-wrapper")||h.hasClass("k-row-resize-handle-wrapper"))return;if(!a||r.insignificant(t))return;if(!f.scripts&&("script"==a||"k:script"==a))return;if(s=w[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==u){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(" ");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==u?(m.push("<![CDATA["),m.push(t.data),m.push("]]>")):8==u&&(t.data.indexOf("[CDATA[")<0?(m.push("\x3c!--"),m.push(t.data),m.push("--\x3e")):(m.push("<!"),m.push(t.data),m.push(">")))}function M(){n.isFunction(f.custom)&&(m=f.custom(m)||m)}return w.script=w["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),M(),m):(C(o),m=m.join(""),M(),""===m.replace(l,"").replace(d,"")?"":m)}};o(i,{Serializer:w})}(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,h=a.normalize;var u={selectionFromWindow:function(e){if(e)return"getSelection"in e?e.getSelection():new v(e.document)},selectionFromRange:function(e){var t=T.documentFromRange(e);return u.selectionFromDocument(t)},selectionFromDocument:function(e){return u.selectionFromWindow(a.windowFromDocument(e))}};var 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){var i,r=e.createDocumentFragment();for(;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){var r,o=n.createDocumentFragment();for(;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;var r=t;for(;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;var o=a.commonAncestor(e,t);var l=e;for(;l&&l.parentNode!=o;)l=l.parentNode;l||(l=o);var c=t;for(;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;var t=e.startContainer;for(;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 h=s(r._current);d==e.startContainer&&h<=e.startOffset&&(e.startOffset-=1),d==e.endContainer&&h<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}});var 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)){var h=!1,u=!1;for(;0===s(r)&&r==r.parentNode.firstChild&&r!=c;)r=r.parentNode,h=!0;for(;s(o)==d(o.parentNode)-1&&o==o.parentNode.lastChild&&o!=c;)o=o.parentNode,u=!0;r==c&&o==c&&h&&u&&(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,h=c?r.parentNode:r,u=t.ownerDocument,p=u.body.createTextRange();3!=r.nodeType&&4!=r.nodeType||(s=o),h||(h=u.body),"img"==h.nodeName.toLowerCase()?(p.moveToElementText(h),p.collapse(!1),e.setEndPoint(n?"StartToStart":"EndToStart",p)):(i=h.insertBefore(a.create(u,"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,h,u,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),u=[c,m.text.length]):(d=!i&&f.previousSibling,h=i&&f.nextSibling,l(h)?u=[h,0]:l(d)?u=[d,d.length]:(p=s(f),u=o.nextSibling&&p==o.childNodes.length-1?[o.nextSibling,0]:[o,p]),a.remove(f)),t[i?"setStart":"setEnd"](...u)}var w=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}}});var y=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 y(this.getSubRange())}});var k=n.extend({init:function(e){this.enumerate=function(){var t=[];var n=r.Immutables&&r.Immutables.immutable;return new y(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}}});var 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){var t=0,n=e.nodeType;for(;e=e.previousSibling;){var i=e.nodeType;3==i&&n==i||t++,n=i}return t},getEditable:function(e){var t=e.commonAncestorContainer;for(;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){var t=[];for(;e!=this.rootNode;)t.push(this.index(e)),e=e.parentNode;return t},toRangePoint:function(e,t,n,i){var r=this.rootNode,o=n.length,a=i;for(;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}});var 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;var c=n?s(n):0;a.remove(t.caret),h(r);var d=r.childNodes[c];if(l(d))e.setStart(d,i);else if(d){var u=a.lastTextNode(d);u?e.setStart(u,u.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;var i=e.collapsed&&!T.isExpandable(e);var 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 h(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){var t=s(e);var n=e;for(;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(h(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;var 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 u=c?l(r)?r.nodeValue.length:r.childNodes.length:0;var p=l(o)?o.nodeValue.length:o.childNodes.length;if(3==r.nodeType)for(;r.previousSibling&&3==r.previousSibling.nodeType;)u+=(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;var m=o.parentNode;var g=this._normalizedIndex(r);var v=this._normalizedIndex(o);h(f),3==r.nodeType&&(r=f.childNodes[g]),h(m),3==o.nodeType&&(o=m.childNodes[v]),c?(3==r.nodeType?e.setStart(r,u):e[d?"setStartAfter":"setStartBefore"](r),e.collapse(!0)):(3==r.nodeType?e.setStart(r,u):e.setStartBefore(r),3==o.nodeType?e.setEnd(o,p):e.setEndAfter(o)),i.caret&&i.removeCaret(e)}});var S=/[\u0009-\u000d]|\u0020|\u00a0|\ufeff|\.|,|;|:|!|\(|\)|\?/;var 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 w(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=u.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;var n=e.cloneRange();for(;0===n.startOffset&&n.startContainer!=t;){var i=a.findNodeIndex(n.startContainer);var r=n.startContainer.parentNode;for(;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){var t=a.editableParent(e.startContainer);var n=a.editableParent(e.endContainer);for(;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();var n=t.startContainer.childNodes[0===t.startOffset?0:t.startOffset-1];var i=t.endContainer.childNodes[t.endOffset];if(!l(n)||!l(i))return t;var r=n.nodeValue;var o=i.nodeValue;if(!r||!o)return t;var a=r.split("").reverse().join("").search(S);var 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;var n=T.documentFromRange(e);if(t==n||t==n.body)return!1;var i=e.cloneRange();var r=t.nodeValue;if(!r)return!1;var o=r.substring(0,i.startOffset);var a=r.substring(i.startOffset);var s=0,l=0;return o&&(s=o.split("").reverse().join("").search(S)),a&&(l=a.search(S)),s&&l}};i(r,{SelectionUtils:u,W3CRange:p,RangeIterator:g,W3CSelection:v,RangeEnumerator:w,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+"]";var d=function(t){return e(t).is("body,.k-editor")};var h=function(e){return e.getAttribute&&"false"==e.getAttribute("contenteditable")};var u=function(e){return r.closestBy(e,h,d)};var p=function(e){return!!u(e.commonAncestorContainer)||!(!u(e.startContainer)&&!u(e.endContainer)||0!==a.editableTextNodes(e).length)};var f=function(e){var t="";var n="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";for(var i=e||10;i>0;--i)t+=n.charAt(Math.round(61*Math.random()));return t};var m=function(e){var t=e?e.options:undefined;t&&t.finder&&t.finder._initOptions({immutables:!0})};var 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=this.options.serialization;var n;switch(typeof t){case"string":return o(t)(e);case"function":return t(e);default:return"<"+(n=r.name(e))+"></"+n+">"}},deserialize:function(n){var i=this;var r=this.options.deserialization;e(c,n).each((function(){var n=this.getAttribute(l);var 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;var o=e.keyCode===i.BACKSPACE;var 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 h=r.closest(c,"li");if(h&&h!==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)&&!u(i))for(;i&&i.children&&i.children[t?0:i.children.length-1];)i=i.children[t?0:i.children.length-1];return u(i)}},_removeImmutable:function(e,t){var n=this.editor;var o=new i.RestorePoint(t,n.body);r.remove(e),i._finishUpdate(n,o)},_nextNode:function(e,t){var n=t?"nextSibling":"previousSibling";var i,o=e;for(;o&&!i&&!r.isChildOfBaseContainer(o);)(i=o[n])&&r.isDataNode(i)&&/^\s|[\ufeff]$/.test(i.nodeValue)&&(i=(o=i)[n]),i||(o=o.parentNode);return i}});g.immutable=h,g.immutableParent=u,g.expandImmutablesIn=function(e){var t=u(e.startContainer);var n=u(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>"}});var 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);var 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;var 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,h=s.options.messages,u=e(n.template(c.template)(h)).appendTo(document.body),p=".k-editor-textarea > textarea";function f(e){e.preventDefault(),u.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(u,{title:h.viewHtml,_footerTemplate:c._footerTemplate,_footerMessages:h,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(u.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(),u.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;var 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)}});var 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,h=i.EditorUtils.registerFormat,u="mousedown.kendoEditor",p="k-marker";var 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;var n=e.parentNode;var i=this.format[0].tags;for(;!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}});var 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=[];var n,i,r,o;if(e.length>1)for(n=0,i=e.length;n<i;n++)r=e[n],o=this.format(r,!0),t.push(o);else r=e[0],this.format(r,!1);this.consolidate(t)},format:function(e,t){var n=this.finder.findSuitable(e);var i=this.attributes;var 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=l.textNodes(e);var n=t.length;var i,r;if(n>0)for(i=0;i<n;i++)(r=this.finder.findFormat(t[i]))&&l.split(e,r,!0)},consolidate:function(e){var t,n;for(;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)}}});var 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=e.attributes;var i=t.trim;var r,o,a,l,c,d,h,u,p;var f,m,g;if(n)for(r=0,o=n.length;r<o;r++){if(l=(a=n[r]).nodeName,c=a.nodeValue,a.specified&&"style"==l)for(u=0,p=(d=i(c||e.style.cssText).split(";")).length;u<p;u++)if((h=d[u]).length){if(m=i((f=h.split(":"))[0].toLowerCase()),g=i(f[1]),m!=this.greedyProperty)continue;return m.indexOf("color")>=0?s.toHex(g):g}if(this.fontAttr&&a.specified&&l==this.fontAttr)return m=a.nodeValue,g=a.nodeValue,m.indexOf("color")>=0?s.toHex(g):g}},getFormatInner:function(t){var n=e(s.isDataNode(t)?t.parentNode:t).parentsUntil("[contentEditable]").addBack().toArray().reverse();var i,r,o;for(i=0,r=n.length;i<r;i++)if(o="className"==this.greedyProperty?n[i].className:this.getInlineCssValue(n[i]))return o;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)}});var 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;var i="apply";this.split(e),n&&"inherit"==this.values.style[n]&&(i="remove"),this[i](t)}});var _=a.extend({init:function(e){a.fn.init.call(this,c(e,{finder:new f(e.format),formatter:function(){return new m(e.format)}}))}});var b=o.extend({update:function(e,t){var n=e.data(this.type);n.close(),n.value(this.finder.getFormat(t))}});var w=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(u,".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())})))}});var y=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(u,(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(u)})),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:w,ColorTool:y}),h("bold",[{tags:["strong","b"]},{tags:["span"],attr:{style:{fontWeight:"bold"}}}]),d("bold",new _({key:"B",ctrl:!0,format:r.bold,ui:{togglable:!0}})),h("italic",[{tags:["em","i"]},{tags:["span"],attr:{style:{fontStyle:"italic"}}}]),d("italic",new _({key:"I",ctrl:!0,format:r.italic,ui:{togglable:!0}})),h("underline",[{tags:["span"],attr:{style:{textDecoration:"underline"}}},{tags:["u"]}]),d("underline",new _({key:"U",ctrl:!0,format:r.underline,ui:{togglable:!0}})),h("strikethrough",[{tags:["del","strike"]},{tags:["span"],attr:{style:{textDecoration:"line-through"}}}]),d("strikethrough",new _({format:r.strikethrough,ui:{togglable:!0}})),h("superscript",[{tags:["sup"]}]),d("superscript",new _({format:r.superscript,ui:{togglable:!0}})),h("subscript",[{tags:["sub"]}]),d("subscript",new _({format:r.subscript,ui:{togglable:!0}})),d("foreColor",new y({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 y({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 w({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 w({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,h=a.InlineFormatter,u=a.InlineFormatFinder,p=l.textNodes,f=l.editableTextNodes,m=a.EditorUtils.registerTool,g=n.keys;var v="http://";var _=/^\w*:\/\//;var b=/[\w\/\$\-_\*\?]/i;var w=r.extend({findSuitable:function(e){return s.parentOfType(e,["a"])}});var y=r.extend({init:function(){this.finder=new w},apply:function(e,t){var n=this.immutables?f(e):p(e);var i,r,o,a,c;if(t.innerText){r=l.documentFromRange(e),i=l.getMarkers(e),e.deleteContents(),a=s.create(r,"a",t),e.insertNode(a),c=a.parentNode,"a"==s.name(c)&&s.insertAfter(a,c),s.emptyNode(c)&&s.remove(c);var d=a;for(var u=0;u<i.length;u++)s.insertAfter(i[u],d),d=i[u];i.length&&(s.insertBefore(r.createTextNode("\ufeff"),i[1]||i[0]),s.insertAfter(r.createTextNode("\ufeff"),i[1]||i[0]),e.setStartBefore(i[0]),e.setEndAfter(i[i.length-1]))}else(o=new h([{tags:["a"]}],t)).finder=this.finder,o.apply(n)}});var k=c.extend({init:function(e){var t=this;e.formatter={toggle:function(e){var n=t.immutables()?f(e):p(e);new h([{tags:["a"]}]).remove(n)}},this.options=e,c.fn.init.call(this,e)}});var x=c.extend({init:function(e){var t;this.options=e,c.fn.init.call(this,e),this.formatter=new y,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);var i=n.length?this.formatter.finder.findSuitable(n[0]):null;var r=n.length&&"img"==s.name(n[0]);var 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);var r=this.editor.options.messages;var 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=this._dialog.element;var r=e("#k-editor-link-url",i).val();var o,a,l;var c=e("#k-editor-link-text",i);r&&r!=v&&(r.indexOf("@")>0&&!/^(\w+:)|(\/\/)/i.test(r)&&(r="mailto:"+r),this.attributes={href:r},(o=e("#k-editor-link-title",i).val())&&(this.attributes.title=o),c.is(":visible")&&((a=n.trim(c.val()))||this._initialText?a&&a!==this._initialText&&(this.attributes.innerText=s.stripBom(a)):this.attributes.innerText=r),l=e("#k-editor-link-target",i).is(":checked"),this.attributes.target=l?"_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="";var n;for(n=0;n<e.length;n++)t+=e[n].nodeValue;return s.stripBom(t||"")},redo:function(){var e=this.lockRange(!0);this.formatter.apply(e,this.attributes),this.releaseRange(e)}});var C=c.extend({init:function(e){c.fn.init.call(this,e),this.formatter=new y},exec:function(){var e=this.detectLink();if(e){var t=this.getRange();var i=new n.ui.editor.Marker;var 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();var t=e.startContainer;var 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}});var S=d.extend({init:function(t){this.options=t,this.finder=new u([{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)}});var T=r.extend({init:function(e){this.traverser=e,this.start=A(),this.end=A(),this.text=""},detectLink:function(){var e=this.traverser.node;var 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=M(e,b);if(n>-1)return this.end.node=t,this.end.offset=n+1,!1},_detectStart:function(e,t){var n=M(e,/\s/);var 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=/\w/.exec(e))?r.index:-1;var r;var o=i;if(-1===i&&(o=e.length),this.text=this.text.substring(o),this.start.node=t,this.start.offset=o+(0|n),i>-1)return!1}});function M(e,t){var n=e.length;for(;n--&&!t.test(e[n]););return n}var A=function(){return{node:null,offset:null,blank:function(){return null===this.node&&null===this.offset}}};var D=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){var l=n.parentNode;for(;!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){}});var E=D.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)}});var I=D.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:w,LinkFormatter:y,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,h=r.RangeUtils;var u=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;var d=a.editableParent(e);var h=this.options&&this.options.immutables;var u=r.Immutables;for(n=0,i=c.length;n<i;n++){if(o=e,s=c[n].tags,l=c[n].attr,h&&s&&"immutable"==s[0]){var p=u.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}});var p=n.extend({init:function(e,t){this.format=e,this.values=t,this.finder=new u(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);var 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);var h=this.finder.findSuitable(d);if(h.length)for(var u=0,p=h.length;u<p;u++)n=l.formatByName(a.name(h[u]),this.format),a.attr(h[u],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){var i=r.Immutables;for(var 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(h.nodes(e),a.htmlIndentSpace,!0);t.finder.isFormatted(n)?t.remove(n):t.apply(n)}});var f=n.extend({init:function(e,t){var n=this;n.format=e,n.values=t,n.finder=new u(e)},apply:function(e){var t=this.format;var n=a.blockParents(e);var i=t[0].tags[0];var o,s,l,c,d;var h;var u;var f;if(n.length)for(o=0,s=n.length;o<s;o++)f=n[o],this.immutables()&&r.Immutables.immutableParent(f)||("li"==(u=a.name(f))?(l=f.parentNode,c=new r.ListFormatter(l.nodeName.toLowerCase(),i),(d=this.editor.createRange()).selectNode(n[o]),c.toggle(d)):i&&("td"==u||f.attributes.contentEditable)?new p(t,this.values).apply(f.childNodes):(h=a.changeTag(f,i),a.attr(h,t[0].attr)));else{var m=new p(t,this.values);m.editor=this.editor,m.apply(e)}},toggle:function(e){var t=h.textNodes(e);t.length||(e.selectNodeContents(e.commonAncestorContainer),(t=h.textNodes(e)).length||(t=a.significantChildNodes(e.commonAncestorContainer))),this.apply(t)},immutables:function(){return this.editor&&this.editor.options.immutables}});var m=s.extend({init:function(e){s.fn.init.call(this,i(e,{finder:new u(e.format),formatter:function(){return new p(e.format)}}))}});i(r,{BlockFormatFinder:u,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,h=r.EditorUtils.registerTool;var u=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];var 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=[];var n,i;for(i=0;i<e.length;i++)(n=this.findFormat(e[i],this.isList))&&o.name(n)==this.tag&&this.matchesType(n)&&t.push(n);if(t.length<1)return!1;if(t.length!=e.length)return!1;for(i=0;i<t.length&&t[i].parentNode==n.parentNode;i++)if(t[i]!=n)return!1;return!0},findSuitable:function(e){var t=this.findFormat(e[0],this.isList);return t&&o.name(t)==this.tag?t:null}});var 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 u(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=d(e);var n,i,r;if(t.length){n=o.parentOfType(t[0],["li"]),i=o.parentOfType(t[t.length-1],["li"]),e.setStartBefore(n),e.setEndAfter(i);for(var s=0,l=t.length;s<l;s++){var c=this.finder.findFormat(t[s]);c&&((r=this._parentLists(c)).length?a.split(e,r.last()[0],!0):a.split(e,c,!0))}}},merge:function(e,t){var n,i=t.previousSibling;for(;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 u({tag:"ul"==r?"ol":"ul"})).findSuitable(e)),t||(t=(t=(i=new u({tag:r})).findSuitable(e))&&n.finder.matchesType(t)?null:t),t},applyOnSection:function(t,n){var i=this.tag;var r=this.attr;var a=o.closestSplittableParent(n);var s=[];var l=this.findSuitableNode(n);var c;function d(){s.push(this)}/table|tbody|thead/.test(o.name(a))?c=e.map(n,(function(e){return o.parentOfType(e,["td"])})):(c=o.significantChildNodes(a),e.grep(c,o.isBlock).length&&(c=e.grep(c,function(e){return this.containsAny(e,n)}.bind(this))),c.length||(c=n));for(var h=0;h<c.length;h++){var u=c[h];(!l||!o.isAncestorOrSelf(l,u))&&this.suitable(u,n)&&(l&&this.isList(u)?(e.each(u.children,d),o.remove(u)):s.push(u))}for(s.length==c.length&&this.breakable(a)&&(s=[a]),l||(l=o.create(a.ownerDocument,i,r),o.isBlock(s[0])&&o.mergeAttributes(s[0],l),o.insertBefore(l,s[0])),this.wrap(l,s);o.isBom(l.nextSibling);)o.remove(l.nextSibling);this.finder.matchesType(l)||(l.removeAttribute("type"),l.style.listStyleType="",o.mergeAttributes(o.create(a.ownerDocument,i,r),l,!0)),l&&""===l.getAttribute("type")&&l.removeAttribute("type"),o.is(l,i)||o.changeTag(l,i),this.merge(i,l)},apply:function(t){var n,i,a,s,l=0,c=[],d=t.length,h=this.immutables()?r.Immutables.immutableParent:e.noop;function u(){n&&c.push({section:n,nodes:i})}for(l=0;l<d;l++)s=h(t[l])||t[l],a=o.closestEditable(s,["td","th","body"]),n&&a==n?i.push(s):(u(),i=[s],n=a);for(u(),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){var t;for(var 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)}});var f=s.extend({init:function(e){e.formatter=new p({tag:e.tag,attr:e.attr}),s.fn.init.call(this,e)}});var m=l.extend({init:function(e){this.options=e,l.fn.init.call(this,i(e,{finder:new u(e)}))},command:function(e){return new f(i(e,{tag:this.options.tag,attr:this.options.attr}))}});i(r,{ListFormatFinder:u,ListFormatter:p,ListCommand:f,ListTool:m}),h("insertUnorderedList",new m({tag:"ul",attr:{style:{listStyleType:""},type:""},ui:{togglable:!0,group:"lists"}})),h("insertOrderedList",new m({tag:"ol",attr:{style:{listStyleType:""},type:""},ui:{togglable:!0,group:"lists"}})),h("insertUpperRomanList",new m({tag:"ol",attr:{style:{listStyleType:"upper-roman"}},altAttr:{type:"I"},ui:{togglable:!0,group:"lists"}})),h("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;var 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;var 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;var r=n.name;var o=this;var 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];var 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}});var h=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);var t=l.mapAll(e,(function(e){return e}));for(var 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);var s=i.previousSibling;var 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));var 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:h}),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:h}))}(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,h="#k-editor-image-url",u="#k-editor-image-title",p="#k-editor-image-width",f="#k-editor-image-height";var 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;var 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,w=_.imageBrowser,y=!!(t.ui.ImageBrowser&&w&&w.transport&&undefined!==w.transport.read),k={title:b.insertImage,visible:!1,resizable:y};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(h).val().replace(/ /g,"%20"),alt:n.find(u).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,y&&(k.width=750),k.minWidth=350,e=this.createDialog("<div/>",k).data("kendoWindow"),i=r._createForm(e,y),e.element.toggleClass("k-filebrowser-dialog",y),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(h).val(c?c.getAttribute("src",2):"http://").end().find(u).val(c?c.alt:"").end().find(p).val(m).end().find(f).val(g).end();var S=e.element;if(y&&(this._imageBrowser=new t.ui.ImageBrowser(S.find(".k-imagebrowser"),n({},w)),this._imageBrowser.bind("change",(function(e){"f"===e.selected.get("type")&&S.find(h).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(h).trigger("focus").select()},_createForm:function(t,n){var r=e("<div/>").appendTo(t.element);var o=this.editor.options.messages;var 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>';var c=o.extend({exec:function(){(this.editor._uploadWidget||this._initializeUploadWidget()).element.click()},_initializeUploadWidget:function(){var t=this;var n=t.editor;var i=n.options.import;var 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;var 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;var l=n.extend({init:function(e){n.fn.init.call(this,e),this.managesUndoRedo=!0},exec:function(){var e=this.editor;var t=this.options;var n=t.range;var r=e.body;var o=new a(n,r);var 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()}});var 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;var 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;var n=t.editor.options.exportAs;var 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;var n=t.options.exportAs;var 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())}});var 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,h=r.BlockFormatFinder,u=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 h([{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();var h=e(r).children("ul,ol")[0];if(h&&s[0])d[0]?(d.append(r),d.append(e(h).children()),o.remove(h)):(s.append(h),h.insertBefore(r,h.firstChild));else for((h=s.children("ul,ol")[0])||(h=o.create(r.ownerDocument,o.name(a),this.getListTypeAttr(a)),s.append(h));r&&r.parentNode==a;)h.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 u([{tags:["p"]}],{style:{marginLeft:30}}).apply(t)}},getListTypeAttr:function(e){var t=e.getAttribute("type");var 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,h=this.finder.findSuitable(t);for(i=0,r=(h=this.mapImmutables(h)).length;i<r;i++){if((c=e(h[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=h[i];d=parseInt(p(n),10)-30,p(n,d)}}});var 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)}});var 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)}});var v=l.extend({init:function(e){l.fn.init.call(this,e),this.finder=new h([{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,h=this.finder.findSuitable(n),u=t.closest(".k-toolbar").data("kendoToolBar");for(s=0,l=h.length;s<l;s++)if(c=h[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 u.enable(t,!0);u.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;var h=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();const n=c.documentFromRange(t);let o,a,d,h,u,p,f,m,g,v;const _=i.emptyElementContent;if(this.expandImmutablesIn(t),v=this.shouldTrim(t),t.deleteContents(),u=this._insertMarker(n,t),r.stripBomNode(u.previousSibling),r.stripBomNode(u.nextSibling),p=r.closestEditableOfType(u,["li"]),f=r.closestEditableOfType(u,"h1,h2,h3,h4,h5,h6".split(",")),m=r.is(u.parentNode,"table")&&u.parentNode,p){if(r.emptyNode(p)){h=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;const a=p.parentNode.children.length;const s=a>=1&&1==p.childNodes.length&&p.children[0];r.insertAfter(h,o),r.remove(1==a?p.parentNode:p),s&&s!==u?(h.appendChild(s),h.appendChild(u)):h.innerHTML=_,d=h}}else f&&this._blankAfter(u)?(h=this._insertParagraphAfter(f),r.remove(u),d=h):m&&(h=this._insertParagraphAfter(m),r.remove(u),d=h);if(!d){p||f||new s([{tags:["p"]}]).apply([u]),t.selectNode(u);const e=f?r.name(f):"p";o=r.parentOfType(u,[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();var n=c.documentFromRange(t);var o=i.emptyElementContent;var 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){var a=!1;for(;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}}}});var u=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=r.create(c.documentFromRange(n),"br");var o=n.startContainer;var a;var s=t.support.browser;var d=s.msie&&s.version<11;var h=r.is(o,"table")&&o;var u;n.deleteContents(),h?r.insertAfter(i,h):(u=e(o).closest(".k-br"),n.insertNode(i),u.length&&r.unwrap(u[0])),l(i.parentNode),d||i.nextSibling&&!r.isWhitespace(i.nextSibling)||(i.nextSibling&&r.isWhitespace(i.nextSibling)&&e(i.nextSibling).remove(),(a=i.cloneNode(!0)).className="k-br",r.insertAfter(a,i)),n.setStartAfter(i),n.collapse(!0),r.scrollTo(i.nextSibling||i,!0),c.selectRange(n)}});n(i,{ParagraphCommand:h,NewLineCommand:u}),d("insertLineBreak",new a({key:13,shift:!0,command:u})),d("insertParagraph",new a({key:13,command:h}))}(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,h=l.textNodes,u=t.keys,p="#k-editor-file-url",f="#k-editor-file-text",m="#k-editor-file-title";var 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;var 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=h(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,w=!!(t.ui.FileBrowser&&b&&b.transport&&undefined!==b.transport.read),y={title:_.insertFile,visible:!1,resizable:w};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),y.close=x,w&&(y.width=750),y.minWidth=350,e=this.createDialog("<div/>",y).data("kendoWindow"),i=r._createForm(e,w),e.element.toggleClass("k-filebrowser-dialog",w),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==u.ENTER?k(e):e.keyCode==u.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(w&&(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);var o=this.editor.options.messages;var 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",h="row",u="col",p="rowgroup",f="colgroup",m="colspan",g="rowspan",v="table",_="thead",b="tbody",w="tr",y="td",k="th",x=i.Tool,C=i.InsertHtmlCommand,S=i.BlockFormatFinder,T=i.BlockFormatTool,M=i.FormatCommand,A=i.EditorUtils.registerTool,D=i.EditorUtils.registerFormat,E=t.ui.Editor.fn.options.formats,I=t.getTouches;var z=t.template;var P=({width:e,content:t})=>`<td style="width:${e}%;">${t}</td>`;var L=new S([{tags:[v]}]);var B=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});var 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(y)[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)}});var H=x.extend({initialize:function(t,n){var r=this;var o=e("<button>"+n.options.messages.tableWizard+"</button>");var 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()}});var R=H.extend({init:function(t){this.cols=8,this.rows=6,H.fn.init.call(this,e.extend(t,{command:B,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),h=t.getOffset(c),u=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"),h.left+=c[0].offsetWidth,h.top+=c[0].offsetHeight,n=(h.left-d.left)/u,i=(h.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;var r=i.find(".k-status");var o=i.find(".k-ct-cell");var a=this.cols;var 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(H.fn._keydown.call(this,e),this._popup.visible()){var i=t.keys;var r=e.keyCode;var o=this._popup.element.find(".k-ct-cell");var a=Math.max(o.filter(".k-selected").last().index(),0);var s=Math.floor(a/this.cols);var l=a%this.cols;var c,d=!1;r!=i.DOWN||e.altKey?r==i.UP?(d=!0,s--):r==i.RIGHT?(d=!0,l++):r==i.LEFT?(d=!0,l--):r==i.TAB&&(c=this._popup.element.find(".k-button")).length>0&&(d=!0,c.trigger("focus")):(d=!0,s++);var h={row:Math.max(1,Math.min(this.rows,s+1)),col:Math.max(1,Math.min(this.cols,l+1))};r==i.ENTER&&n?this._exec(h):this._setTableSize(h),d&&(e.preventDefault(),e.stopImmediatePropagation())}},_open:function(){var e=this._editor.options.messages;H.fn._open.call(this),this.popup().element.find(".k-status").text(e.createTable).end().find(".k-ct-cell").removeClass(c)},_close:function(){H.fn._close.call(this),this.popup().element.off("."+s)}});var F=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){var r,o;for(var 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){var n,i=e.find("td:last-child"),r=parseInt(i.attr("col-index"),10)+i.prop("colSpan")-1;for(var o=t;o<=r;o++)if((n=e.find("[col-index="+o+"]")).length)return n},_adjustColgroups:function(e,t){var n,i,o,a=t.getElementsByTagName(u),s=t.getElementsByTagName(f),l=e.cells,c=l.length;for(;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,u))},_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")}});var O=F.extend({exec:function(){var t,n,o,a,s,l,c=this.lockRange(!0),u=r.closest(c.endContainer,[y,k]),f=r.closest(u,v),m=this.options.position||"after";if(!f||this.immutables()&&i.Immutables.immutableParent(u))this.releaseRange(c);else{this._mapColIndices(f),n=u.parentNode,s=r.findNodeIndex(n,!0),u.rowSpan>1&&"after"===m&&(n=f.rows[s+u.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(w).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,h);"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)}});var V=F.extend({exec:function(){var t,n,o,a,s=this.lockRange(!0),l=r.closest(s.endContainer,[y,k]),c=r.closest(l,v),h=c.getElementsByTagName(u),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,u),"before"==_?r.insertBefore(a,o):r.insertAfter(a,o),this._resizeCells(a,o));(h.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)}});var N=F.extend({exec:function(){var t=this.lockRange();var n=o.mapAll(t,(function(t){return e(t).closest(w)[0]}));var a=r.closest(t.endContainer,[y,k]);var s=n[0];var l=a?a.rowSpan:1;var c=e(n[0]).index();var d=r.closest(s,v);var h=s.parentElement;var u;if(!d||this.immutables()&&i.Immutables.immutableParent(s))this.releaseRange(t);else{for(var p=0;p<l;p++)n.indexOf(h.rows[c+p])<0&&n.push(h.rows[c+p]);if(d.rows.length<=n.length)(u=r.next(d))&&!r.insignificant(u)||(u=r.prev(d)),u&&u.rows&&(u=u.rows[0].cells[0]),r.remove(d),this._resetElementResizing(this.editor);else if(h.rows.length<=n.length)(u=h.nextSibling)||(u=h.previousSibling),r.remove(h);else{this._mapColIndices(d);for(var f=0;f<n.length;f++)s=n[f],r.removeTextSiblings(s),u=(u=r.next(s)||r.prev(s)).cells[0],this._focusElement(t,u),u=null,this._handleRowSpanCells(d,s),r.remove(s);this._clearColIndexAttr(d)}e(d).find("[headers]").length>0?this._associateHeaderIds(d):r.is(h,_)&&e(d).find("[scope]").length>0&&this._adjustColgroups(h.rows[0],d),u&&this._focusElement(t,u),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],h=parseInt(d.getAttribute("col-index"),10)+d.colSpan-1;for(i=0;i<=h;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,h)):e.attr(g,t)}});var $=F.extend({exec:function(){var t,n,o,a,s,l=this.lockRange(),c=r.closest(l.endContainer,[y,k]),d=r.closest(c,v),h=d&&d.rows,p=h&&h[0].cells.length,m=d.getElementsByTagName(u),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<h.length;o+=a.prop("rowSpan")||1)(a=e(h[o]).find("[col-index="+(n+s)+"]")).length&&a.prop("colSpan")<=1?a.remove():this._handleColSpanCells(h[o],n+s);this._clearColIndexAttr(d)}(m.length>0||g.length>0)&&this._adjustColgroups(h[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,u)):e.attr(m,t)}});var U=F.extend({exec:function(){var t,n,o,a,s,l=this.lockRange(),c=r.closest(l.endContainer,[y,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)===u&&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}});var W=F.extend({exec:function(){var t,n,o,a,s,l,c,u=this.lockRange(),f=r.closest(u.endContainer,[y,k]);if(f)if(t=r.closest(f,w),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(u);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(u);e(f).prop(g,this._getRowspan(f)+this._getRowspan(c)).append(r.emptyNode(c)?"":"<br/>"+c.innerHTML),f.getAttribute(d)===h&&f.setAttribute(d,p),e(c).remove(),e(o).find("[headers]").length>0&&this._associateHeaderIds(o),this._clearColIndexAttr(o),this.releaseRange(u)}else this.releaseRange(u);else this.releaseRange(u)},_getRowspan:function(e){return parseInt(e.getAttribute(g),10)||1}});var j=F.extend({exec:function(){var t=this.lockRange(),n=this.options.type,o="row"===n?m:g,a=r.closest(t.endContainer,[y,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,u),t.getAttribute(m)&&"1"!==t.getAttribute(m)||t.setAttribute(d,u),this._adjustColgroups(t.parentNode,n.parentNode)):s.attr(d,t.getAttribute(d)))},_splitCellVertically:function(t,n,i,o){var a=r.closest(t,w),s=parseInt(e(t).attr("col-index"),10),l=r.findNodeIndex(a,!0),c=t.rowSpan,u=t.colSpan,f=Math.floor(c/2),v=e(n).find(w).eq(l+c-f),_=this._findNextTdInRow(v,s+u),b=e(o);f>1&&b.attr(g,f),u>1&&b.attr(m,u),_&&_.length?_.before(b):v.append(b),e(t).prop(i,c-f),t.hasAttribute(d)&&(t.getAttribute(d)===p?(b.attr(d,h),t.getAttribute(g)&&"1"!==t.getAttribute(g)||t.setAttribute(d,h)):b.attr(d,t.getAttribute(d)))}});var 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=!L.isFormatted(t),i=e.closest(".k-toolbar").getKendoToolBar();!0===n?i.hide(e):i.show(e)}});var G=M.extend({exec:function(){var e=this.editor;M.fn.exec.call(this),e.elementResizing&&e.elementResizing._showResizeHandles()}});var K=T.extend({update:function(e,t){var n=!L.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:H,TableCommand:B,InsertTableTool:R,TableFormatTool:K,TableFormatCommand:G,TableModificationTool:q,InsertRowCommand:O,InsertColumnCommand:V,DeleteRowCommand:N,DeleteColumnCommand:$,MergeCellsHorizontallyCommand:U,MergeCellsVerticallyCommand:W,SplitCellCommand:j}),A("createTable",new R({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"})),D("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"}})),D("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"}})),D("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;var d=n.extend({init:function(e){this.editor=e;var t=e.options.pasteCleanup;this.nonSplittableTagsOnPaste=e.options.nonSplittableTagsOnPaste||[],this.cleaners=[new u(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;var t;var 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;var i=n.editor;var r=n._startModification();r&&(e.call(n,i,r.range),setTimeout((function(){t.call(n,i,r.range),n._endModification(r)})))},_removeBomNodes:function(e){var t=r.textNodes(e);for(var 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();var i=new FileReader;if(t instanceof window.File||!t.getAsFile||(t=t.getAsFile()))return 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||{};var 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);var 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"});var s=t.support.browser;var 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 h=i.createRange();h.selectNodeContents(a),i.selectRange(h)}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||{};var 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;var r=o.offset(t,i);var a=this._caretOffset(n,i);var 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=this.editor;var i=o.create(n.document,"span",{innerHTML:"\ufeff"});var r=e.startContainer;var a;if(e.collapsed){var s=o.isDataNode(r);s&&(o.isBom(r)||0===e.startOffset)?o.insertBefore(i,r):s&&e.startOffset===r.length?o.insertAfter(i,r):(e.insertNode(i),a=!0)}else r=r===t?r.childNodes[e.startOffset]:r,o.insertBefore(i,r);var l=o.offset(i,t);var c=i.previousSibling;var d=i.nextSibling;if(o.remove(i),a&&o.isDataNode(c)&&o.isDataNode(d)&&!o.isBom(c)&&!o.isBom(d)){var h=c.length;d.data=c.data+d.data,e.setStart(d,h),o.remove(c),e.collapse(!0),n.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,h=this.editor,u=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| )*)+(<\/?(div|p|li|col|t))/gi,"$3")).replace(/<(a|span)[^>]*><\/\1>/gi,"")),t=(t=t.replace(/<(a|span|font)([^>]*)> <\/\1>/gi,"<$1$2> </$1>")).replace(/^<li/i,"<ul><li").replace(/li>$/g,"li></ul>");var m=this.isBlock(t);h.focus();var g=h.getRange();g.deleteContents(),g.startContainer==h.document&&g.selectNodeContents(h.body);var v=new s;var _=v.addCaret(g);var b=this.splittableParent(m,_);var w=!1;for(i=0;i<u.length;i++){const e=u[i],t=e.tag||e;if(o.is(b,t)){p=!0,f=!1!==e.unwrap;break}}var y=b!=h.body&&!o.is(b,"td")&&!p;n.split&&y&&(m||o.isInline(b))&&(g.selectNode(_),r.split(g,b,!0),w=!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(h.document.createTextNode("\ufeff"))})),g.insertNode(k),b=this.splittableParent(m,_),w){for(;_.parentNode!=b;)o.unwrap(_.parentNode);o.unwrap(_.parentNode)}o.normalize(g.commonAncestorContainer),_.style.display="inline",o.restoreScrollTop(h.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)){var T=S.parent().contents();var M=T.length-1;var A=T.get(M);for(;null!==A.nodeValue&&(" "===A.nodeValue||""===A.nodeValue);)M-=1,A=T.get(M);A!==S.get(0)||S.parents("table").length||o.insertAfter(o.createEmptyNode(h.document,"p"),S[0])}h._handleSpaceAndNewLines(),h.selectRange(g)}});var h=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}});var u=h.extend({init:function(e){h.fn.init.call(this,e),this.replacements=[/<(\/?)script([^>]*)>/i,"<$1telerik:script$2>"]},applicable:function(e){return!this.options.none&&/<script[^>]*>/i.test(e)}});var p=h.extend({init:function(e){h.fn.init.call(this,e);this.replacements=[/<span\s+class="Apple-tab-span"[^>]*>\s*<\/span>/gi," ",/\t/gi," ",/ /gi," "]},applicable:function(e){return/ |class="?Apple-tab-span/i.test(e)}});var f=h.extend({init:function(e){h.fn.init.call(this,e),this.junkReplacements=[/<\?xml[^>]*>/gi,"",/<!--(.|\n)*?-->/g,"",/"/g,"'",/<o:p> <\/o:p>/gi," ",/<\/?(meta|link|style|o:|v:|x:)[^>]*>((?:.|\n)*?<\/(meta|link|style|o:|v:|x:)[^>]*>)?/gi,"",/<\/o>/g,""],this.replacements=this.junkReplacements.concat([/(?:<br> [\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> [\s\r\n]+|<br>)*/g,"$1",/<br><br>/g,"<BR><BR>",/<br>\n/g,"<br/>",/<br>(?!\n)/g," ",/<table([^>]*)>(\s| )+<t/gi,"<table$1><t",/<tr[^>]*>(\s| )*<\/tr>/gi,"",/<tbody[^>]*>(\s| )*<\/tbody>/gi,"",/<table[^>]*>(\s| )*<\/table>/gi,"",/<BR><BR>/g,"<br>",/^\s*( )+/gi,"",/( |<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);var 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=e.innerHTML;var i=o.innerText(e);var r;var a=n.match(/^(?:<span [^>]*texhtml[^>]*>)?<span [^>]*(?:Symbol|Wingdings)[^>]*>([^<]+)/i);var s=a&&a[1];var l=/^[a-z\d]/i.test(s);var c=function(e){return e.replace(/^(?: |[\u00a0\n\r\s])+/,"")};return a&&(r=!0),n=n.replace(/<\/?\w+[^>]*>/g,"").replace(/ /g," "),!r&&/^[\u2022\u00b7\u00a7\u00d8o]\u00a0+/.test(n)||r&&/^.\u00a0+/.test(n)||s&&!l&&t?{tag:"ul",style:this._guessUnorderedListStyle(c(i))}:/^\s*\w+[\.\)][\u00a0 ]{2,}/.test(n)?{tag:"ol",style:this._guessOrderedListStyle(c(i))}: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+[\.\)]( )+ /,""),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),/^( |\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,h,u,p,f,m,g,v=e(t).find(o.blockElements.join(",")),_=-1,b={},w=["p","h1","h2","h3","h4","h5","h6"];for(h=0;h<v.length;h++){u=v[h];var y=(g=e(u).data()).list;if(n=o.name(u),!!!e(u).parents("table").length){var k=this.listType(u,g);if(!(p=k&&k.tag)||w.indexOf(n)<0)u.innerHTML?i&&!c&&i.appendChild(u):o.remove(u);else if(!l.msie){var x=p+y;b[f=g.level||parseFloat(u.style.marginLeft||0)]||(b[f]={}),(!r||r<0)&&(r=f,a=y,s=e(t).find("[data-list='"+a+"']").last()[0],d=this._createList(p,k.style),o.insertBefore(d,u),_=f,b[f][x]=d),c=s===u,m=b[f][x],(f>_||!m)&&(m=this._createList(p,k.style),b[f][x]=m,i.appendChild(m)),i=this._convertToLi(u),m.appendChild(i),c?r=_=-1:_=f}}}},removeAttributes:function(e){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())};for(;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;var r=e(n).closest("table");var 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){var n=e(t).find("p.MsoTitle");for(var 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;var i=this.options;return i.none?(e=h.fn.clean.call(n,e,this.junkReplacements),e=n.stripEmptyAnchors(e)):(e=i.msConvertLists?this.extractListLevels(e):e,e=h.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}});var m=h.extend({init:function(e){h.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)}});var g=h.extend({clean:function(e){var t=o.create(document,"div",{innerHTML:e});return(t=this.cleanDom(t)).innerHTML},cleanDom:function(e){return e}});var 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}});var _=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}});var b=function(){this.text="",this.add=function(e){this.text+=e}};var w=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;var t="";var n=this.lines;this.flashInlineBlockText();for(var i=0,r=n.length,o=r-1;i<r;i++){var a=n[i];for(var 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)}});var y=n.extend({init:function(e){this.callback=e},enumerate:function(e){if(e){var t=this.callback(e);var n=e.firstChild;!t&&n&&this.enumerate(n),this.enumerate(e.nextSibling)}}});var k=h.extend({init:function(e){h.fn.init.call(this,e),this.hasText=!1,this.enumerator=new y(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 w(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()}}});var x=h.extend({clean:function(e){return this.options.custom(e)},applicable:function(){return"function"==typeof this.options.custom}});c(i,{Clipboard:d,Cleaner:h,ScriptCleaner:u,TabCleaner:p,MSWordFormatCleaner:f,WebkitFormatCleaner:m,HtmlTagsCleaner:v,HtmlAttrCleaner:_,HtmlContentCleaner:k,HtmlTextLines:w,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;var h=o.nodeTypes;var u="previousSibling";function p(e,t,n){var i=e?e[t]:null;for(;i&&!n(i);)i=i[t];return i}var f="td,th,caption";var m="table,tbody,thead,tfoot,tr";var g=m+","+f;var v=function(t){return!t.collapsed&&e(t.commonAncestorContainer).is(m)};var _=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)}));var a=r.documentFromRange(t);var l=n.start;var c=n.end;var d=f.split(",");var h=o.parentOfType(l,d);var u=o.parentOfType(c,d);this._removeContent(l,h,!0),this._removeContent(c,u,!1),e(i).each((function(t,n){((n=e(n)).is(f)?n:n.find(f)).each((function(e,t){t.innerHTML=""}))})),h&&!l.previousSibling&&o.insertBefore(a.createTextNode("\ufeff"),l),u&&!c.nextSibling&&o.insertAfter(a.createTextNode("\ufeff"),c),h?t.setStartBefore(l):i[0]&&(h=(h=e(i[0])).is(f)?h:h.find(f).first()).length&&t.setStart(h.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}}});var 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 h=r.getRange();var u=r.body;if(n.startRestorePoint=new a(h,u),v(h))new _(r).remove(h),r.selectRange(h);if(l.webkit&&!h.collapsed&&function(e,t){return t.startContainer===e&&t.endContainer===e&&0===t.startOffset&&t.endOffset==e.childNodes.length}(u,h)&&(u.innerHTML=""),r.immutables&&i.Immutables.immutablesContext(h))new i.BackspaceHandler(r).deleteSelection(h);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)))}});var w=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===h.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;var 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){var t=e.startOffset;var n=e.startContainer;var i=n.nodeValue;var r=0;for(;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=t.startContainer;var r=o.closestEditableOfType(n,["li"]);var a=o.closestEditableOfType(n,"p,h1,h2,h3,h4,h5,h6".split(","));var s=this.editor;var l;if(o.isDataNode(n)){if(t.collapsed&&/^\s[\ufeff]+$/.test(n.nodeValue))return t.setStart(n,0),t.setEnd(n,n.length),s.selectRange(t),!1;this._cleanBomBefore(t)}l=p(a,u,(function(e){return!o.htmlIndentSpace(e)})),t.collapsed&&t.startOffset!==t.endOffset&&t.startOffset<0&&(t.startOffset=0,t.endOffset=0,s.selectRange(t));var c=r&&i.RangeUtils.isStartOf(t,r);var d=r&&e(r).index();var h=c&&d>0;if(h&&(a=r,l=o.prev(r)),a&&l&&o.is(l,"table")&&i.RangeUtils.isStartOf(t,a))return""===a.innerText&&(a.innerHTML="\ufeff"),!0;if(i.RangeUtils.isStartOf(t,a)&&parseInt(a.style.marginLeft,10)>0)return s.exec("outdent"),!0;if(a&&l&&i.RangeUtils.isStartOf(t,a)||h){var f=o.significantChildNodes(a)[0];f=f&&o.isInline(f)&&!o.isImg(f)?f:a;var m=this._addCaret(f);return this._merge(l,a),this._restoreCaret(m),!0}if(c&&0===d){var g=r.firstChild;g||(r.innerHTML=i.emptyElementContent,g=r.firstChild);var v=new i.ListFormatter(o.name(r.parentNode),"p");return t.selectNodeContents(r),v.toggle(t),o.insignificant(g)?t.setStartBefore(g):t.setStart(g,0),s.selectRange(t),!0}var _=n.childNodes[t.startOffset-1];var b=t;var w=_&&o.closestEditableOfType(_,["a"]);var y=p(_||n,u,(function(e){return!o.isDataNode(e)||!o.isBom(e)&&e.length>0}));if((w||(0===t.startOffset||_)&&o.is(y,"a"))&&(w=w||y,(b=s.createRange()).setStart(w,w.childNodes.length),b.collapse(!0)),(w=w||o.closestEditableOfType(_||b.startContainer,["a"]))&&i.RangeUtils.isEndOf(b,w)){var k=new i.UnlinkCommand({range:b,body:s.body,immutables:!!s.immutables});s.execCommand(k),s._selectionChange()}return!1},_handleSelection:function(t){var n=t.commonAncestorContainer;var r=o.closest(n,"table");var a=i.emptyElementContent;var l=this.editor;var c;if(v(t))return new _(l).remove(t),l.selectRange(t),!0;var d=new s;d.add(t,!1),t.commonAncestorContainer===l.body&&this._surroundFullyContent(d,t),l.immutables&&this._handleImmutables(d),this._surroundFullySelectedAnchor(d,t),t.setStartAfter(d.start),t.setEndBefore(d.end);var h=t.startContainer;var u=t.endContainer;return t.deleteContents(),"li"===u.tagName.toLocaleLowerCase()&&o.emptyNode(u)&&(t.selectNode(u),t.deleteContents()),r&&""===e(r).text()&&(t.selectNode(r),t.deleteContents()),n=t.commonAncestorContainer,"p"===o.name(n)&&""===n.innerHTML&&(n.innerHTML=a,t.setStart(n,0)),this._join(h,u),o.insertAfter(l.document.createTextNode("\ufeff"),d.start),d.remove(t),h=t.startContainer,"tr"==o.name(h)&&(h=h.childNodes[Math.max(0,t.startOffset-1)],t.setStart(h,o.getNodeLength(h))),t.collapse(!0),l.selectRange(t),c=h.parentElement||h.parentNode,o.isDataNode(h)&&!o.emptyNode(c)&&this._cleanBomBefore(t),!0},_handleImmutables:function(e){var t=i.Immutables.immutableParent;var n=t(e.start);var 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===h.TEXT_NODE?this._mergeWithTextNode(e,t.firstChild):e.parentNode.appendChild(t.firstChild);o.remove(t)},_mergeWithTextNode:function(e,t){e&&e.nodeType===h.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;var o=this.editor;var s=o.getRange();var l=e.keyCode;var c=t.keys;var d=l===c.BACKSPACE;var h=l==c.DELETE;o.immutables&&o.immutables.keydown(e,s)||(!d&&!h||s.collapsed?d?n="_handleBackspace":h&&(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});var y=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)}});var 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;var t=e.getRange();t.selectNodeContents(e.body),setTimeout((function(){e.selectRange(t)}))},_toSelectableImmutables:function(){var t=this.editor.body,n=i.Immutables.immutable,r=o.emptyTextNode,a=t.firstChild,s=t.lastChild;for(;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});var 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=[];var 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:y,BackspaceHandler:w,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;var a=n.extend({init:function(e){this.async=!0,n.fn.init.call(this,e)},exec:function(){var e=this;var t=e.lockRange(!0);var 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;var 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;var 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=a.nodes(e);var n;for(n=1===t.length?t[0].parentNode:e.startContainer;n&&!o.is(n,"body")&&"editor"!==n.getAttribute("data-role");)o.isBlock(n)?(this.populateStyles(n,"blockStyles"),n=o.is(n,"li")?n.parentNode:null):(this.populateStyles(n,"inlineStyles"),n=n.parentNode)},populateStyles:function(e,t){var n=e.style;var i=e.attributes;var r={tags:[e.tagName],attr:{style:{}}};var o,a,s,l,c;if(n)for(c=0;c<n.length;c++)o=n[a=n[c]],r.attr.style[a]=o;if(i)for(c=0;c<i.length;c++)s=i[c].nodeName,l=i[c].nodeValue,"style"!==s&&("class"===s?r.attr.className=l:r.attr[s]=l);this[t].push(r)}});var c=i.extend({init:function(e){i.fn.init.call(this,e)},exec:function(){var e=this.lockRange(!0);var t=a.getMarkers(e);var n=this.editor;var i=n.inlineStyles;var r=n.blockStyles;var s;(i&&0!==i.length||r&&0!==r.length)&&(3===t.length&&(this.marker.removeCaret(e),this.marker.caret=null),this.removeEmptyElementsFromRange(e),s=a.nodes(e),this.cleanInlineParents(s),o.normalize(e.commonAncestorContainer),2===t.length?(e.setStartAfter(t[0]),e.setEndBefore(t[1])):(e.setStartBefore(s[0]),e.setEndAfter(s[0])),(s=a.nodes(e))&&r&&r.length&&this.applyBlockStyles(s,r),s&&i&&i.length&&this.applyInlineStyles(s,i),this.releaseRange(e))},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=t[0].tags[0];var i=t[0].attr;var r=this.editor.document;var a,s,l,c,d,h;var u,p,f,m,g,v,_,b,w;for(a=0,s=e.length;a<s;a++)if(l=e[a],!o.isWhitespace(l)&&!this.immutableParent(l))if("BODY"!==(d=o.blockParentOrBody(l)).tagName&&d.tagName!==n){if("LI"!==d.tagName&&"TD"!==d.tagName&&"TH"!==d.tagName){for(u=[],p=[],f=l.previousSibling,m=l.nextSibling;f;)o.isMarker(f)||u.push(f),f=f.previousSibling;if(u.length)for((g=d.cloneNode(!0)).innerHTML="",o.insertBefore(g,u[0]),b=0;b<u.length;b++)_=u[b],o.insertAt(g,_,0);for(;m;)o.isMarker(m)||p.push(m),m=m.nextSibling;if(p.length)for((v=d.cloneNode(!0)).innerHTML="",o.insertBefore(v,p[0]),b=0;b<p.length;b++)_=p[b],v.appendChild(_);o.unwrap(d)}c=o.create(r,n,i),o.wrap(l,c)}else d.tagName===n&&o.attr(d,i);if(d&&2===t.length&&"LI"!==d.tagName&&"LI"===n){for(w=[];o.is(c,"li");)w.push(c),c=o.prev(c);for(h=o.create(r,t[1].tags[0],t[1].attr),o.insertBefore(h,w[w.length-1]),h.appendChild(w[0]),a=1,s=w.length;a<s;a++)o.insertBefore(w[a],h.firstChild)}else d&&2===t.length&&"LI"!==d.tagName&&(h=o.create(r,t[1].tags[0],t[1].attr),o.wrap(c,h))},applyInlineStyles:function(e,t){var n=this.editor.document;var i,r,a,s,l,c;for(s=0;s<t.length;s++)i=t[s],r=o.create(n,i.tags[0],i.attr),a&&r.appendChild(a),a=r;if(a)for(s=0;s<e.length;s++)if(c=e[s],!o.isWhitespace(c)&&!this.immutableParent(c)){for(l=a.cloneNode(!0),o.insertBefore(l,c);l.children&&l.children.length;)l=l.children[0];l.appendChild(c)}},immutables:function(){return this.editor&&this.editor.options.immutables},immutableParent:function(e){return this.immutables()&&t.Immutables.immutableParent(e)}});var d=n.extend({init:function(e){n.fn.init.call(this,e)},command:function(e){return new l(e)}});var h=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:h}),s("copyFormat",new d({})),s("applyFormat",new h({}))}(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,h=i.EditorUtils,u=h.registerTool,p=h.registerFormat,f=i.RangeUtils;const 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)}});const 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"}}}]),u("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;const a=function(e,t,n,i,r,o){const a=e.cloneRange(),s=a.startContainer;let l,c,d,h,u;return null!=r&&(a.setStart(s,r),a.setEnd(s,r+1)),l=a.getBoundingClientRect(),o?(u=o.getBoundingClientRect(),c=l.left-u.left-l.width/2,d=l.top-u.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),h=t.createElementNS("http://www.w3.org/2000/svg","text"),h.setAttributeNS(null,"x",c),h.setAttributeNS(null,"y",d),h.setAttributeNS(null,"fill","#6098f2"),h.setAttributeNS(null,"font-size",`${Math.ceil(l.height+l.width)}px`),h.textContent=n,h};const 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)};const l=function(e){e._formattingMarksOverlay.empty()};const c=function(e){e._updateFormattingMarksOverlayHeight(),s.call(e)};const 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;var n=t.Math;var i=n.min;var r=n.max;var o=t.parseFloat;var a=e.jQuery;var s=a.extend;var l=e.ui.editor;var c=/(\d+)(\.?)(\d*)%/;var d=/(\d+)(\.?)(\d*)px/;var h="string";function u(e){return typeof e===h&&c.test(e)}var p={constrain:function(e){var t=e.value;var n=e.min;var 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 u(e)?o(e):o(e)/t*100},inPercentages:u,inPixels:function(e){return typeof e===h&&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;var n=t.extend;var i=t.noop;var r=e.ui.editor;var o=e.Class;var a="keydown";var s="mouseleave";var l="mouseup";var c="table";var 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;var 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;var 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;var i=n.options.handle;var r=t(e.currentTarget);var o=n.resizeHandle;var 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;var 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;var t=e.options;var n=t.eventNamespace;var i=t.handle.classNames.marker;var 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)}});var h=o.extend({create:function(e,n){var i=this;var r=n.name;var o=n.eventNamespace;t(e.body).on("mouseenter"+o,c,(function(t){var o=t.currentTarget;var 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;var 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=e[r];var s;a&&a.resizingInProgress()&&(s=t(o.target).parents(c)[0])&&(a._forceResizing(o),i._destroyResizing(e,n),i._initResizing(e,s,n))}))},dispose:function(e,n){t(e.body).off(n.eventNamespace)},_initResizing:function(t,n,i){var r=i.name;var 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)}});h.current=new h,d.create=function(e,t){h.current.create(e,t)},d.dispose=function(e,t){h.current.dispose(e,t)},n(r,{TableElementResizing:d})}(window.kendo),function(e){var t=window.Math.abs;var n=e.jQuery;var i=n.extend;var r=e.ui.editor;var o=r.Dom;var a=r.TableElementResizing;var s=r.ResizingUtils;var l=s.constrain;var c=s.calculatePercentageRatio;var d=s.getScrollBarWidth;var h=s.inPercentages;var u=s.toPercentages;var p=s.toPixels;var f=e._outerWidth;var m=".kendoEditorColumnResizing";var g="k-column-resize-handle";var v="k-column-resize-marker";var _="body";var b="tbody";var w="thead";var y="tr";var k="col-index";var x=",";var C="width";var 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;var r=i.handle.width;var o=e.offset().left+(i.rtl?0:f(e));var a=t.clientX+n(e[0].ownerDocument).scrollLeft();return a>o-r&&a<o+r},setResizeHandlePosition:function(t){var i=this;var r=n(i.element.tHead||i.element.tBodies[0]);var o=i.options;var a=o.rtl;var s=o.handle.width;var l=n(o.rootElement);var c=l.is(_)?0:l.scrollTop();var h=l.is(_)?0:e.scrollLeft(l);var u=a?0:f(t);var p=a?d(l[0]):0;var m=t.offset().left-(l.offset().left+parseFloat(l.css("borderLeftWidth")))-parseFloat(t.css("marginLeft"));var g=r.offset().top-(l.offset().top+parseFloat(l.css("borderTopWidth")))-parseFloat(r.css("marginTop"));var v=e.support.browser;a&&(v.mozilla||v.webkit&&v.version>=85)&&(h*=-1),i.resizeHandle.css({top:g+c,left:m+u+(h-p)-s/2,position:"absolute"})},setResizeHandleDimensions:function(){var e=this;var t=n(e.element).children(w);var i=n(e.element).children(b);var 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;var r=n(n(t.currentTarget).data(i.options.handle.dataAttribute));var o=i.options;var a=n(o.rootElement);var s=o.handle?o.handle.width:0;var c=o.min;var h=o.rtl;var u=f(r);var p=r.offset().left-(a.offset().left+parseFloat(a.css("borderLeftWidth")))-parseFloat(r.css("marginLeft"));var m=f(r.next());var g=n(i.resizeHandle);var v=a.is(_)?0:e.scrollLeft(a);var b=h?d(a[0]):0;var w=g.offset().left-(a.offset().left+parseFloat(a.css("borderLeftWidth")))-parseFloat(g.css("marginLeft"));var y=e.support.browser;h&&(y.mozilla||y.webkit&&y.version>=85)&&(v*=-1);var k=l({value:w+(v-b)+t.x.delta,min:p+(v-b)-(h?m:0)+c,max:p+u+(v-b)+(h?0:m)-s-c});g.css({left:k})},resize:function(e){var t=this;var i=n(n(e.currentTarget).data(t.options.handle.dataAttribute));var r=t.options;var a=r.rtl?-1:1;var s=r.min;var c=a*e.x.initialDelta;var d;var h;var u;var p;var m;o.reMapTableColumns(t.element,k),p=parseInt(i.attr(k),10),i.prop("colSpan")>1&&(i=n(t.element).find("["+k+"="+(p+i.prop("colSpan")-1)+"]").eq(0),p=parseInt(i.attr(k),10)),m=n(t.element).find("["+k+"="+(p+1)+"]:not([colspan])"),t._setTableComputedWidth(),t._setColumnsComputedWidth(),u=f(i),h=f(m),d=l({value:u+c,min:s,max:u+h-s}),t._resizeColumn(i[0],d),t._resizeTopAndBottomColumns(i[0],d),t._resizeAdjacentColumns(parseInt(i.attr(k),10),h,u,u-d),o.clearTableMappings(t.element,k)},_setTableComputedWidth:function(){var e=this.element;""===e.style[C]&&(e.style[C]=p(f(n(e))))},_setColumnsComputedWidth:function(){var e=n(this.element.tHead||this.element.tBodies[0]);var t=f(e);var i=e.children(y).children("td");var r=i.length;var o=i.map((function(){return f(n(this))}));var a;for(a=0;a<r;a++)h(i[a].style[C])?i[a].style[C]=u(c(o[a],t)):i[a].style[C]=p(o[a])},_resizeTopAndBottomColumns:function(e,t){var i=this;var r=n(e).attr(k);var o=n(i.element).children(b+x+w).children(y).children(i.options.tags.join(x)).filter((function(){return n(this).attr(k)===r&&this!==e}));var a=o.length;var s;for(s=0;s<a;s++)i._resizeColumn(o[s],t)},_resizeColumn:function(e,t){var i=n(this.element.tHead||this.element.tBodies[0]);h(e.style[C])?e.style[C]=u(c(t,f(i))):e.style[C]=p(t)},_resizeAdjacentColumns:function(e,t,i,r){var o=this;var a=n(o.element).children(b+x+w).children(y).children(o.options.tags.join(x)).filter((function(){return parseInt(n(this).attr(k),10)===e+1}));var s=a.length;var l;for(l=0;l<s;l++)o._resizeAdjacentColumn(a[l],t,i,r)},_resizeAdjacentColumn:function(e,n,i,r){var o=this.options.min;var a;a=l({value:n+r,min:o,max:t(i+n-o)}),this._resizeColumn(e,a)}});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;var n=e.jQuery;var i=n.extend;var r=e.ui.editor;var o=r.TableElementResizing;var a=r.ResizingUtils;var s=a.getScrollBarWidth;var l=a.constrain;var c=a.calculatePercentageRatio;var d=a.inPercentages;var h=a.toPercentages;var u=a.toPixels;var p=e._outerHeight;var f=".kendoEditorRowResizing";var m="k-row-resize-handle";var g="k-row-resize-marker";var v="body";var _="tr";var b="tbody";var w="thead";var y="height";var 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[y];var r=e.offset().top+p(e);var o=t.clientY+n(e[0].ownerDocument).scrollTop();return o>r-i&&o<r+i},setResizeHandlePosition:function(t){var i=this.options;var r=i.handle[y];var o=n(i.rootElement);var a=o.is(v)?0:o.scrollTop();var l=o.is(v)?0:e.scrollLeft(o);var c=i.rtl?s(o[0]):0;var d=t.offset().left-(o.offset().left+parseFloat(o.css("borderLeftWidth")))-parseFloat(t.css("marginLeft"));var h=t.offset().top-(o.offset().top+parseFloat(o.css("borderTopWidth")))-parseFloat(t.css("marginTop"));var u=e.support.browser;i.rtl&&(u.mozilla||u.webkit&&u.version>=85)&&(l*=-1),this.resizeHandle.css({top:h+p(t)+a-r/2,left:d+(l-c),position:"absolute"})},setResizeHandleDimensions:function(){var e=this;var t=n(e.element.tHead||e.element.tBodies[0]);e.resizeHandle.css({width:t.width(),height:e.options.handle[y]})},setResizeHandleDragPosition:function(e){var t=this;var i=t.options;var r=i.min;var o=n(t.element).children(w);var a=n(t.element).children(b);var s=o.length>0?o:a;var c=n(t.resizeHandle);var d=n(e.currentTarget).data(i.handle.dataAttribute);var h=n(d);var u=n(i.rootElement);var f=u.is(v)?0:u.scrollTop();var m=s.offset().top-(u.offset().top+parseFloat(u.css("borderTopWidth")))-parseFloat(s.css("marginTop"));var g=h.offset().top-(u.offset().top+parseFloat(u.css("borderTopWidth")))-parseFloat(h.css("marginTop"));var _=c.offset().top-(Math.max(0,u.offset().top)+parseFloat(u.css("borderTopWidth")))-parseFloat(c.css("marginTop"));var k=l({value:_+f+e.y.delta,min:g+f+r,max:m+p(o)+p(a)+f-i.handle[y]-r});c.css({top:k})},resize:function(e){var i=this;var r=i.options;var o=n(e.currentTarget).data(r.handle.dataAttribute);var a=p(n(o));var s=n(i.element);var c=p(s);var h=s.children(w);var f=h.length>0?h.height():0;var m=s.children(b).height();var g=o.style[y];var v=l({value:a+e.y.initialDelta,min:r.min,max:t(f+m-r.min)});i._setRowsHeightInPixels(),o.style[y]=u(v),i._setTableHeight(c+(v-a)),d(g)&&i._setRowsHeightInPercentages()},_setRowsHeightInPixels:function(){var e=n(this.element).children(b+","+w).children(_);var t=e.length;var i=e.map((function(){return p(n(this))}));var r;for(r=0;r<t;r++)e[r].style[y]=u(i[r])},_setRowsHeightInPercentages:function(){var e=this;var t=n(e.element).children(w);var i=t.length>0?t.height():0;var r=n(e.element).children(b).height();var o=n(e.element).children(w+","+b).children(_);var a=o.length;var s=o.map((function(){return p(n(this))}));var l;for(l=0;l<a;l++)o[l].style[y]=h(c(s[l],i+r))},_setTableHeight:function(e){var t=this.element;d(t.style[y])?t.style[y]=h(c(e,n(t).parent().height())):t.style[y]=u(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;var n=t.extend;var i=t.noop;var r=e.ui.editor;var o=e.Class;var a=e.ui.Draggable;var s=e.Observable;var l=r.ResizingUtils.getScrollBarWidth;var c=e._outerWidth;var d=e._outerHeight;var h=".kendoEditorElementResizeHandle";var u="k-element-resize-handle";var p="dragStart";var f="drag";var m="dragEnd";var g="halfInside";var v="mouseover";var _="mouseout";var b="east";var w="north";var y="northeast";var k="northwest";var x="south";var C="southeast";var S="southwest";var T="west";var M=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(h).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='"+u+"'></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+h,e._onMouseOver.bind(e)).on(_+h,e._onMouseOut.bind(e))},_onMouseOver:function(){this.trigger(v)},_onMouseOut:function(){this.trigger(_)},_addStyles:function(){t(this.element).children("."+u).addClass("k-resize-"+this.options.direction)},_initPositioningStrategy:function(){var e=this;var 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;var 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})}});var A=o.extend({init:function(){this._items=[]},register:function(e,t){this._items.push({name:e,type:t})},create:function(e){var t=this._items;var n=t.length;var i=e.name?e.name.toLowerCase():"";var r;var o;var a;for(a=0;a<n;a++)if((o=t[a]).name.toLowerCase()===i){r=o;break}if(r)return new r.type(e)}});var D=A.extend({});D.current=new D;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;var t=e.calculatePosition();var n=e.applyHandleOffset(t);return e.applyScrollOffset(n)},calculatePosition:i,applyHandleOffset:function(e){var n=this.options;var 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=this.options;var r=t(i.rootElement);var o=i.rtl?l(r[0]):0;var a=e.support.browser;var s;return r.is("body")?n:(s=e.scrollLeft(r)||0,i.rtl&&(a.mozilla||a.webkit&&a.version>=85)&&(s*=-1),{top:n.top+(r.scrollTop()||0),left:n.left+s-o})}});E.create=function(e){return D.current.create(e)};var I=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e)/2,left:n.left+c(e)+i}}});D.current.register(b,I);var z=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top,left:n.left+c(e)/2+i}}});D.current.register(w,z);var P=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top,left:n.left+c(e)+i}}});D.current.register(y,P);var L=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top,left:n.left+i}}});D.current.register(k,L);var B=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e),left:n.left+c(e)/2+i}}});D.current.register(x,B);var H=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e),left:n.left+c(e)+i}}});D.current.register(C,H);var R=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e),left:n.left+i}}});D.current.register(S,R);var F=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement);var n=e.position();var i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e)/2,left:n.left+i}}});D.current.register(T,F);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;var n=t.deltaX.adjustment*t.deltaX.modifier;var 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}}});var $=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}}});var j=W.extend({options:{deltaY:{modifier:-1}}});O.current.register(w,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}}});var K=G.extend({options:{deltaX:{modifier:1},deltaY:{modifier:-1}}});O.current.register(y,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:M})}(window.kendo),function(e){var t=window.Math;var n=t.min;var i=t.max;var r=e.jQuery;var o=r.contains;var a=r.extend;var s=e.support.browser;var l=e.ui.editor;var c=e.Class;var d=l.ElementResizeHandle;var h=l.ResizingUtils;var u=h.calculatePercentageRatio;var p=h.constrain;var f=h.inPercentages;var m=h.inPixels;var g=h.toPercentages;var v=h.toPixels;var _=e._outerWidth;var b=e._outerHeight;var w=l.RangeUtils;var y=".kendoEditorElementResizing";var k="k-element-resize-handle-wrapper";var x="k-element-resizing";var C="dragStart";var S="drag";var T="dragEnd";var M="keydown";var A="mousedown";var D="select";var E="tr";var I="tbody";var z="thead";var P="table";var L=["TABLE","IMG"];var B=",";var H="width";var R="height";function F(e){return void 0===e}var O=c.extend({init:function(e,t){var n=this;n.options=a({},n.options,t),n.handles=[],L.indexOf(e.nodeName)>=0&&(n.element=e)},destroy:function(){var e=this;r(e.element).off(y),e.element=null,r(e.options.rootElement).off(M+y),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;var 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;var i=r(n.element);var o=t.toLowerCase();var a=n.options.rtl?-1:1;var s=r(n.element).parent();var l=s[0];var c=s[o]();var d=a*(t===H?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=this;var t=e.handles;var n=e.options;var i=e.options.handles;var r=i.length;var o;if(!(t&&t.length>0)){for(o=0;o<r;o++)e.handles.push(new d(a({appendTo:n.appendHandlesTo,resizableElement:e.element,rootElement:n.rootElement,rtl:n.rtl,editor:e.options.editor},i[o])));e._bindToResizeHandlesEvents()}},_destroyResizeHandles:function(){var e=this;var t=e.handles?e.handles.length:0;for(var n=0;n<t;n++)e.handles[n].destroy();e.handles=[]},_showResizeHandles:function(){var e=(this.handles||[]).length;var t;for(t=0;t<e;t++)this.handles[t].show()},_bindToResizeHandlesEvents:function(){return!1},_onResizeHandleDragStart:function(){var e=this;var 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(M+y)},_disableKeyboard:function(){r(this.options.rootElement).on(M+y,(function(e){e.preventDefault()}))}});var V=O.extend({_bindToResizeHandlesEvents:function(){var e=this;var t=e.handles||[];var n=t.length;var i;var r;for(i=0;i<n;i++)(r=t[i]).bind(C,e._onResizeHandleDragStart.bind(e)),r.bind(S,e._onResizeHandleDrag.bind(e)),r.bind(T,e._onResizeHandleDragEnd.bind(e))},_hasRowsInPixels:function(){var e=r(this.element).children(z+B+I).children(E);for(var 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=this;var a=r(o.element);var s=a[0].style[H];var l=_(a);var c=a.parent().width();var d=o._getMaxDimensionValue(H);var h;var m;var b;var w;0!==e&&(F(o._initialElementWidth)&&(o._initialElementWidth=l),w=p({value:o._initialElementWidth+t,min:o.options.minWidth,max:d}),f(s)?(l+e>c?(m=i(w,c),b=n(w,c)):(m=n(w,c),b=i(w,c)),h=g(u(m,b))):h=v(w),o._setColumnsWidth(),a[0].style[H]=h)},_resizeHeight:function(e,t){var o=this;var a=r(o.element);var s=a[0].style[R];var l=b(a);var c=a.parent().height();var d=o._getMaxDimensionValue(R);var h;var m;var _;var w;var y=o.options.minHeight;var k=o._hasRowsInPixels();0!==e&&(F(o._initialElementHeight)&&(o._initialElementHeight=l),w=p({value:o._initialElementHeight+t,min:y,max:d}),k&&e<0&&o._setRowsHeightInPercentages(),f(s)?(l+e>c?(m=i(w,c),_=n(w,c)):(m=n(w,c),_=i(w,c)),h=g(u(m,_))):h=v(w),a[0].style[R]=h,k&&e<0&&o._setRowsHeightInPixels())},_setColumnsWidth:function(){var e=r(this.element);var t=e.parent()[0];var n=e.closest("td");var i=n.closest(E).children();var o=i.length;var a;if(function(e){var t=e.style.width;return""!==t?!!f(t):!!r(e).hasClass("k-table")}(e[0])&&t===n[0]&&""===t.style[H])for(a=0;a<o;a++)i[a].style[H]=v(r(i[a]).width())},_setRowsHeightInPercentages:function(){var e=this;var t=r(e.element).children(z);var n=t.length>0?t.height():0;var i=r(e.element).children(I).height();var o=r(e.element).children(z+B+I).children(E);var a=o.length;var s=o.map((function(){return b(r(this))}));var l;for(l=0;l<a;l++)o[l].style[R]=g(u(s[l],n+i))},_setRowsHeightInPixels:function(){var e=r(this.element).children(z+B+I).children(E);var t=e.length;var n=e.map((function(){return b(r(this))}));var i;for(i=0;i<t;i++)e[i].style[R]=v(n[i])}});var N=O.extend({_bindToResizeHandlesEvents:function(){var e=this;var t=e.handles||[];var n=t.length;var i;var r;for(i=0;i<n;i++)(r=t[i]).bind(C,e._onResizeHandleDragStart.bind(e)),"north"===r.options.direction||"south"===r.options.direction?r.bind(S,e._onResizeHandleDragVertical.bind(e)):"east"===r.options.direction||"west"===r.options.direction?r.bind(S,e._onResizeHandleDragHorizontal.bind(e)):r.bind(S,e._onResizeHandleDragLocked.bind(e)),r.bind(T,e._onResizeHandleDragEnd.bind(e))},_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=this;var i=r(n.element);var o=_(i);var a;var s;0!==e&&(F(n._initialElementWidth)&&(n._initialElementWidth=o),s=p({value:n._initialElementWidth+t,min:n.options.minWidth,max:n._getMaxDimensionValue(H)}),a=v(s),i[0].style[H]=a,i.attr(H,Math.floor(s)))},_resizeHeight:function(e,t){var n=this;var i=r(n.element);var o=b(i);var a;var s;0!==e&&(F(n._initialElementHeight)&&(n._initialElementHeight=o),s=p({value:n._initialElementHeight+t,min:n.options.minHeight,max:Number.MAX_SAFE_INTEGER}),a=v(s),i[0].style[R]=a,i.attr(R,Math.floor(s)))}});const $=c.extend({create:function(e){let t=this;r(e.body).on("dragstart"+y,(function(){var t=w.nodes(e.getRange()),n=!1;t.forEach((function(e){"IMG"===e.nodeName&&(n=!0)})),n&&t.length>1&&e.elementResizing._destroyResizeHandles()})).on("drop"+y,(function(){setTimeout((function(){var t=w.image(e.getRange());t&&(e.elementResizing._destroyResizeHandles(),e.elementResizing.element=t,e.elementResizing.showResizeHandles())}))})).on(A+y,P+B+"img",(function(n){var i=n.target;var r=n.currentTarget;var a=e.elementResizing;var 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+y,(function(t){var n=e.elementResizing;var i=n?n.element:null;var a=t.target;var 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(y)},_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(D,t._showElementResizeHandlesProxy),t.bind(D,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;var c=new i.BlockFormatFinder([{tags:["table"]}]);var d=new i.BlockFormatFinder([{tags:["td","th"]}]);var h=/([a-z]+|%)$/i;var u="scope";var p="col-index";var f="th";var m="td";var g=l.extend({exec:function(){var e=this;var r=e.editor;var o=e.range=e.lockRange();var a=e.options.tableCellWizard;var s=e._sourceTable=e.options.insertNewTable?t:e._selectedTable(o);var l=e._selectedTableCells=s?e._selectedCells(o):t;var 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){var n=e(t).parent().contents();var i=n.length-1;var r=n.get(i);for(;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){var r=this;var o=e(n.rows).toArray();var s=t.tableProperties;var l=s.rows;var c=n.tHead;var d=r._lastInCollection;var h,u;for(;i.length>1;)i.pop();h=i.length?d(i).parentNode:d(o),r._deleteTableRows(o,o.length-l),o.length<l&&r._addRows(h,l,o),a.reMapTableColumns(n,p),r._updateColumns(o,s.columns,i,h),r._updateTableProperties(n,s),u=t.cellProperties,i[0]&&a.attr(i[0],{id:(u||{}).id||null}),u&&(u.selectAllCells?e(o).children():e(i)).each((function(e,t){r._updateCellProperties(t,u,s)})),r._updateCaption(n,s),c?r._updateHeadersWithThead(n,t):r._updateHeadersNoThead(n,t),r._updateHeaderAssociates(n,s),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();var i=[];var 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=t.getAttribute("headers");var i;return!!(n&&!a.is(t,f)&&(i=n.split(" "))&&i.length>0)&&i.some(r)})).length},_insertCells:function(e,t,n){n=isNaN(n)?-1:n;for(var i=0;i<e;i++)t.insertCell(n).innerHTML=" "},_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=this;var n=t.editor.document;var i=e.tableProperties;var r=a.create(n,"table");var o=0;var s;t._updateTableProperties(r,i),t._updateCaption(r,i),i.headerRows&&i.headerRows>0&&(s=r.createTHead(),t._createTableRows(e,s,o,!0),o+=i.headerRows);var l=r.createTBody();return t._createTableRows(e,l,o,!1),a.reMapTableColumns(r,p),"ids"===i.cellsWithHeaders?a.associateWithIds(r):"scope"===i.cellsWithHeaders&&t._addScopes(r,i.headerRows,i.headerColumns),a.clearTableMappings(r,p),r},_createTableRows:function(e,t,n,i){var r=e.tableProperties;var o=e.cellProperties;var a=r.columns;var s=i?r.headerRows:r.rows;var l=r.headerColumns;for(var c,d=n;d<s;d++){c=t.insertRow();for(var h,u=0;u<a;u++)h=i||l>u?document.createElement(f):document.createElement(m),c.appendChild(h),h.innerHTML=" ",o&&0===d&&0===u&&o.id&&(h.id=o.id),this._updateCellProperties(h,o&&(o.selectAllCells||0===d&&0===u)?o:{},r)}},_addRows:function(t,n,i){var r=e(t).index();var o=t.cells.length;var a=n-i.length;var s=t.parentNode;var l;for(;a;)l=s.insertRow(r+1),this._insertCells(o-l.cells.length,l),a--},_updateColumns:function(t,n,i,r){var o=this;var a=o._lastInCollection;var s=a(t[0].cells);var l=Number(s.getAttribute(p))+s.colSpan;if(l>n&&e(t).each((function(e,t){var i=a(t.cells);var r=Number(i.getAttribute(p))+i.colSpan;for(;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=t.tableProperties;var i=e.rows;var r,o,s,l;for(s=0;s<i.length;s++)for(r=i[s].cells,l=0;l<r.length;l++)o=r[l],!this._isHeadingCell(o)&&(s<n.headerRows||n.headerColumns>o.getAttribute(p))?a.changeTag(o,f,!1):this._isHeadingCell(o)&&s>=n.headerRows&&n.headerColumns<=o.getAttribute(p)&&a.changeTag(o,m,!1)},_updateHeadersWithThead:function(e,t){var n=this;var i=t.tableProperties;var r=e.tHead;var o=0;var s=e.tBodies[0];var l,c,d;if(s||(s=e.createTBody()),i.headerRows&&i.headerRows>0){for(r||(r=e.createTHead());r.rows.length<i.headerRows;)r.appendChild(s.rows[0]);for(;r.rows.length>i.headerRows;)s.appendChild(r.rows[0]);n._swapToHeaderCells(r)}else if(r){for(;r.rows.length>0;)s.appendChild(r.rows[r.rows.length-1]);e.deleteTHead()}for(;s.rows.length>o;){for(l=s.rows[o],d=0;d<l.cells.length;d++)c=l.cells[d],n._isHeadingCell(c)&&i.headerColumns<=c.getAttribute(p)?a.changeTag(c,m,!1):!n._isHeadingCell(c)&&i.headerColumns>c.getAttribute(p)&&a.changeTag(c,f,!1);o+=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=e.rows;var r,o,a,s;for(r=0;r<i.length;r++)for(a=i[r],o=0;o<a.cells.length;o++)s=a.cells[o],r<t?s.setAttribute(u,"col"):s.getAttribute(p)<n&&s.setAttribute(u,"row")},_removeScopes:function(t){e(t).find(f).removeAttr(u),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);var 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="";var 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;var o=n.style;var s=n.rows;var l=n.caption;var 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 h=r._getAlignment(n,!0);var u=r._getTablePosition(n);var f=l?r._getAlignment(l):t;var m=a._getNumberOfHeaderRows(n);var g;g=r.cellsWithHeadersAssociated(n)?"ids":e(n).find("th[scope]").length>0?"scope":"none",a.reMapTableColumns(n,p);var v=a._getNumberOfColumns(n);var _=a._getNumberOfHeaderColumns(n,m);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:u,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&&f.textAlign?f.textAlign+" "+f.verticalAlign:"",headerRows:m,headerColumns:_,cellsWithHeaders:g},selectedCells:[]};return b.rows=r.parseTableRows(s,i,b),b},parseTableRows:function(t,n,i){var r,o,a,s,l=[];for(var 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;var n=e.style;var 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;var 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(h);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}});var v=i.Tool.extend({command:function(e){return e.insertNewTable=this.options.insertNewTable,e.tableCellWizard=!!this.options.tableCellWizard,new g(e)}});var _=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)}});var 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"];var 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)};var 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)};var h={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)};var u={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)};var 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"})};var 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>";var 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>";var 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 h=(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(h),n._tablePropertiesForm=n._createTablePropertiesForm(t,s),n._accessibilityPropertiesForm=n._createAccessibilityPropertiesForm(t,s),t.center(),t.open(),l){var u=h.closest(".k-window").height();h.css("max-height",u)}},_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 h=(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 u=h.closest(".k-window").height();h.css("max-height",u)}},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;var 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;var n=e.tableProperties;var 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||{};var 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;var 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;var i=this.components.tableView;var 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;var i=this.components.tableView;var r=h.dataSource;r[0].tooltip=n.alignLeft,r[1].tooltip=n.alignCenter,r[2].tooltip=n.alignRight,r[3].tooltip=n.alignRemove,this._initAlignmentDropDown(e,h,"alignment",t,i)},_initCellAlignmentDropDown:function(e,t){var n=this.options.messages;var i=this.components.cellView;var r=u.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,u,"alignment",t,i)},_initAccessibilityAlignmentDropDown:function(e,t){var n=this.options.messages;var i=this.components.accessibilityView;var 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;var i="wrapTextValue";t.wrapTextValue=t.wrapText?"wrap":"nowrap";var r=this.components.cellView;var 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,h=s.rightCellPadding,u=l.value(),p=d.value(),f=c.value(),m=h.value();a?(isNaN(l._cachedPadding)||l.value(l._cachedPadding),c.wrapper.closest(i+t).removeClass(n),d.wrapper.closest(i+t).removeClass(n),h.wrapper.closest(i+t).removeClass(n),l.wrapper.closest(i+t).find(".k-form-label").text(o.topPadding)):(u===p&&u===f&&u===m?(c.value(u),d.value(u),h.value(u)):l.value(null),c.wrapper.closest(i+t).addClass(n),d.wrapper.closest(i+t).addClass(n),h.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;var n=t.value();var i=e.sender.value();i<n&&t.value(i),t.max(i)},_onRowsNumberChange:function(e){var t=this.components.accessibilityView.headerRows;var n=t.value();var i=e.sender.value();i<n&&t.value(i),t.max(i)},_createTablePropertiesForm:function(t,n){var i=this;var r=i.options.table;var a=t.element.find("#k-table-properties");var c=i.components.tableView={};var d=r.tableProperties=r.tableProperties||{};var h;return i._addUnit(s,d.widthUnit),i._addUnit(s,d.heightUnit),d.borderStyle=d.borderStyle||"",(h=a.kendoForm({renderButtons:!1,layout:"grid",grid:{cols:4},items:[{colSpan:2,field:"k-editor-table-columns",label:o(n.columns),editor:function(t,n){i._initNumericTextbox(e('<input type="numeric" id="k-editor-table-columns" />').appendTo(t),"columns",d,c,{min:1,value:4,change:i._onColumnsNumberChange.bind(i)})}},{colSpan:2,field:"k-editor-table-rows",label:o(n.rows),editor:function(t,n){i._initNumericTextbox(e('<input type="numeric" id="k-editor-table-rows" />').appendTo(t),"rows",d,c,{min:1,value:4,change:i._onRowsNumberChange.bind(i)})}},{colSpan:1,field:"k-editor-table-width",label:o(n.width),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-width" />').appendTo(t),"width",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-width-type",label:{encoded:!1,text:" "},editor:function(t,r){i._initDropDownList(e(`<input id="k-editor-table-width-type" aria-label="${n.units}" />`).appendTo(t),"widthUnit",d,c,s)}},{colSpan:1,field:"k-editor-table-height",label:o(n.height),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-height" />').appendTo(t),"height",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-height-type",label:{encoded:!1,text:" "},editor:function(t,r){i._initDropDownList(e(`<input id="k-editor-table-height-type" aria-label="${n.units}" />`).appendTo(t),"heightUnit",d,c,s)}},{colSpan:2,field:"k-editor-table-position",label:o(n.position),editor:function(t,n){i._initTablePositionDropDown(e('<input id="k-editor-table-position" class="k-position" />').appendTo(t),d)}},{colSpan:2,field:"k-editor-table-alignment",label:o(n.alignment),editor:function(t,n){i._initTableAlignmentDropDown(e('<input id="k-editor-table-alignment" class="k-align" />').appendTo(t),d)}},{colSpan:2,field:"k-editor-table-cell-spacing",label:o(n.cellSpacing),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cell-spacing" />').appendTo(t),"cellSpacing",d,c,{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,r){i._initCheckbox(e('<input id="k-editor-padding-all-sides" />').appendTo(t),"independentCellPaddings",d,c,{checked:!0,label:o(n.independentCellPaddings),change:i._onPaddingCheckChange.bind(i)})}},{colSpan:1,field:"k-editor-table-cell-padding-top",label:o(n.topPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cell-padding-top" />').appendTo(t),"topCellPadding",d,c,{placeholder:o(n.auto),change:i._onPaddingTopChange.bind(i)})}},{colSpan:1,field:"k-editor-table-cell-padding-right",label:o(n.rightPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cell-padding-right" />').appendTo(t),"rightCellPadding",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cells-padding-bottom",label:o(n.bottomPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cell-padding-bottom" />').appendTo(t),"bottomCellPadding",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cell-padding-left",label:o(n.leftPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cell-padding-left" />').appendTo(t),"leftCellPadding",d,c,{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){i._initColorPicker(e('<input id="k-editor-table-bg" />').appendTo(t),"bgColor",d,c)}},{colSpan:1,field:"k-editor-border-width",label:o(n.borderWidth),editor:function(t,n){i._initNumericTextbox(e('<input id="k-editor-border-width" />').appendTo(t),"borderWidth",d,c)}},{colSpan:1,field:"k-editor-border-color",label:o(n.borderColor),editor:function(t,n){i._initColorPicker(e('<input id="k-editor-border-color" />').appendTo(t),"borderColor",d,c)}},{colSpan:2,field:"k-editor-border-style",label:o(n.borderStyle),editor:function(t,n){i._initBorderStyleDropDown(e('<input id="k-editor-border-style" />').appendTo(t),"borderStyle",d,c,l)}},{colSpan:"full",field:"k-editor-collapse-borders",label:"",editor:function(t,r){i._initCheckbox(e('<input id="k-editor-collapse-borders"/>').appendTo(t),"collapseBorders",d,c,{label:o(n.collapseBorders)})}}]}]}).data("kendoForm")).layoutWrapper.addClass("k-gap-x-4"),h},_createCellPropertiesForm:function(t,n){var i=this;var r=i.options.table;var a=t.element.find("#k-cell-properties");var c=(i.components=i.components||{}).cellView={};var d=r.selectedCells&&r.selectedCells[0]||{borderStyle:"",wrapText:!0};var h;return i._addUnit(s,d.widthUnit),i._addUnit(s,d.heightUnit),(h=a.kendoForm({renderButtons:!1,layout:"grid",grid:{cols:4},items:[{colSpan:"full",field:"k-editor-selectAllCells",label:"",editor:function(t,a){i._initCheckbox(e('<input id="k-editor-selectAllCells" />').appendTo(t),"selectAllCells",r.tableProperties,c,{label:o(n.selectAllCells)})}},{colSpan:1,field:"k-editor-cell-width",label:o(n.width),hint:o(n.applyToColumn),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-cell-width" />').appendTo(t),"width",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-cell-width-type",label:{encoded:!1,text:" "},editor:function(t,r){i._initDropDownList(e(`<input id="k-editor-cell-width-type" aria-label="${n.units}" />`).appendTo(t),"widthUnit",d,c,s)}},{colSpan:1,field:"k-editor-cell-height",label:o(n.height),hint:o(n.applyToRow),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-cell-height" />').appendTo(t),"height",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-cell-height-type",label:{encoded:!1,text:" "},editor:function(t,r){i._initDropDownList(e(`<input id="k-editor-cell-height-type" aria-label="${n.units}" />`).appendTo(t),"heightUnit",d,c,s)}},{colSpan:2,field:"k-editor-cell-alignment",label:o(n.alignment),editor:function(t,n){i._initCellAlignmentDropDown(e('<input id="k-editor-cell-alignment" class="k-align" />').appendTo(t),d)}},{colSpan:2,field:"k-editor-wrap-text",label:"Text control",editor:function(t,n){i._initTextWrapDropDown(e('<input id="k-editor-wrap-text" />').appendTo(t),d)}},{colSpan:"full",field:"k-editor-cell-bg",label:o(n.background),editor:function(t,n){i._initColorPicker(e('<input id="k-editor-cell-bg" />').appendTo(t),"bgColor",d,c)}},{colSpan:2,field:"k-editor-table-cell-margin",label:o(n.cellMargin),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cell-margin" />').appendTo(t),"cellMargin",d,c,{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,a){i._initCheckbox(e('<input id="k-editor-padding-all-sides" />').appendTo(t),"independentCellPaddings",r.tableProperties,c,{checked:!0,label:o(n.independentCellPaddings),change:i._onPaddingCheckChange.bind(i)})}},{colSpan:1,field:"k-editor-table-cells-padding-top",label:o(n.topPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cells-padding-top" />').appendTo(t),"topCellPadding",d,c,{placeholder:o(n.auto),change:i._onPaddingTopChange.bind(i)})}},{colSpan:1,field:"k-editor-table-cells-padding-right",label:o(n.rightPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cells-padding-right" />').appendTo(t),"rightCellPadding",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cells-padding-bottom",label:o(n.bottomPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cells-padding-bottom" />').appendTo(t),"bottomCellPadding",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cells-padding-left",label:o(n.leftPadding),editor:function(t,r){i._initNumericTextbox(e('<input id="k-editor-table-cells-padding-left" />').appendTo(t),"leftCellPadding",d,c,{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,r){i._initNumericTextbox(e('<input id="k-editor-cell-border-width" />').appendTo(t),"borderWidth",d,c,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-cell-border-color",label:o(n.borderColor),editor:function(t,r){i._initColorPicker(e('<input id="k-editor-cell-border-color" />').appendTo(t),"borderColor",d,c,{placeholder:o(n.auto)})}},{colSpan:2,field:"k-editor-cell-border-style",label:o(n.borderStyle),editor:function(t,n){i._initBorderStyleDropDown(e('<input id="k-editor-cell-border-style" />').appendTo(t),"borderStyle",d,c,l)}}]},{colSpan:"full",field:"k-editor-cell-id",label:{text:o(n.id),optional:!0},editor:function(t,n){i._initInput(e('<input id="k-editor-cell-id" />').appendTo(t),"id",d,c)}},{colSpan:"full",field:"k-editor-cell-css-class",label:{text:o(n.cssClass),optional:!0},editor:function(t,n){i._initInput(e('<input id="k-editor-cell-css-class" />').appendTo(t),"className",d,c)}}]}).data("kendoForm")).layoutWrapper.addClass("k-gap-x-4"),h},_createAccessibilityPropertiesForm:function(t,n){var i=this;var r=i.options.table;var a=t.element.find("#k-accessibility-properties");var s=i.components.accessibilityView={};var l=r.tableProperties;var c;return c=a.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){i._initInput(e('<input id="k-editor-id" />').appendTo(t),"id",l,s)}},{colSpan:"full",field:"k-editor-css-class",label:{text:o(n.cssClass),optional:!0},editor:function(t,n){i._initInput(e('<input id="k-editor-css-class" />').appendTo(t),"className",l,s)}},{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){i._initInput(e('<input id="k-editor-table-caption" />').appendTo(t),"captionContent",l,s)}},{colSpan:2,field:"k-editor-accessibility-alignment",label:o(n.captionAlignment),editor:function(t,n){i._initAccessibilityAlignmentDropDown(e('<input id="k-editor-accessibility-alignment" />').appendTo(t),l)}},{colSpan:1,field:"k-editor-table-header-rows",label:o(n.headerRows),editor:function(t,n){i._initNumericTextbox(e('<input id="k-editor-table-header-rows" />').appendTo(t),"headerRows",l,s,{max:l.rows||4})}},{colSpan:1,field:"k-editor-table-header-columns",label:o(n.headerColumns),editor:function(t,n){i._initNumericTextbox(e('<input id="k-editor-table-header-columns" />').appendTo(t),"headerColumns",l,s,{max:l.columns||4})}},{colSpan:2,field:"k-editor-cells-headers",label:o(n.associateCellsWithHeaders),editor:function(t,r){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);i._initAssociationDropDown(o,"cellsWithHeaders",{valuePrimitive:!0},l,s)}},{colSpan:"full",field:"k-editor-accessibility-summary",label:{text:o(n.summary),optional:!0},editor:function(t,r){i._initTextArea(e('<textarea id="k-editor-accessibility-summary"></textarea>').appendTo(t),"summary",l,s,{rows:5,placeholder:n.tableSummaryPlaceholder})}}]}]}).data("kendoForm"),c.layoutWrapper.addClass("k-gap-x-4"),c}});r.ui.editor.TableWizardDialog=g}(window.kendo.jQuery);kendo;!function(e,t){var n=window;var i=n.Math.min;var r=n.kendo;var o=r.caret;var a=r.keys;var s=r.ui;var l=s.Widget;var c=".kendoMaskedTextBox";var d=e.isPlainObject;var h=window.setTimeout;var u="k-disabled";var p="k-invalid";var f="k-focus";var m="disabled";var g="readonly";var v="change";var _="mouseup";var b="drop";var w="keydown";var y="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=this;var a;l.fn.init.call(i,t,n),i._rules=e.extend({},i.rules,i.options.rules),t=i.element,a=t[0],i._wrapper(),i._tokenize(),i._form(),i.options.inputMode=i.options.inputMode||t.attr("inputmode")||"text",i.element.addClass("k-input-inner").attr("autocomplete","off").attr("inputmode",i.options.inputMode).on("focus"+c,(function(){var e=a.value;e?i._togglePrompt(!0):a.value=i._old=i._emptyMask,i._oldValue=e,i.wrapper.addClass(f),i._timeoutId=h((function(){o(t,0,e?i._maskLength:0)}))})).on("focusout"+c,(function(){var e=t.val();clearTimeout(i._timeoutId),a.value=i._old="",e!==i._emptyMask&&(a.value=i._old=e),i.wrapper.removeClass(f),i._change(),i._togglePrompt()})),i.options.mask&&i.options.mask.length>0&&i.element.attr("aria-placeholder",i.options.mask),t.is("[disabled]")||e(i.element).parents("fieldset").is(":disabled")?i.enable(!1):i.readonly(t.is("[readonly]")),i._validationIcon=e(r.ui.icon({icon:"exclamation-circle",iconClass:"k-input-validation-icon k-hidden"})).insertAfter(t),i.value(i.options.value||t.val()),i._label(),i._applyCssClasses(),Yu({widget:i,wrapper:i.wrapper,options:i.options,suffixInsertAfter:i._validationIcon}),i.floatingLabel&&i.floatingLabel.refresh(),r.notify(i)},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;var 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];var 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(w),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(w),k(y)].join(" ");e.element.on(n,e._legacyIEInputHandler.bind(e))}}},_unbindInput:function(){var e=[x,k(w),k(_),k(b),k(y)].join(" ");this.element.off(e)},_editable:function(e){var t=this;var n=t.element;var i=t.wrapper;var r=e.disable;var o=e.readonly;t._unbindInput(),o||r?(n.attr(m,r).attr(g,o),i.toggleClass(u,r)):(n.prop(m,!1).prop(g,!1),i.removeClass(u),t._bindInput())},_change:function(){var e=this;var 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;var n=t._old;var a=t.element[0];var s=a.value;var l=o(a)[1];var c=s.length-n.length;var d=r.support.mobileOS;if(!(t.__dropping&&c<0)){-1===c&&d.android&&"chrome"===d.browser&&(e=!0);var h=i(l,function(e,t){var n=0;for(;n<t.length&&e[n]===t[n];)n++;return n}(s,n));var u=s.substring(h,l);a.value=s.substring(0,h)+t._emptyMask.substring(h);var p=t._mask(h,l,u);var f=t._trimStartPromptChars(s.substring(l),i(c,p-h));var m=t._unmask(f,n.length-f.length);t._mask(p,p,m),e&&(p=t._findCaretPosBackwards(h)),o(a,p),t.__dropping=!1}},_trimStartPromptChars:function(e,t){var n=this.options.promptChar;for(;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;var n=t.element[0];var i=n.value;var r=e.type;t.__pasting="paste"===r,h((function(){"mouseup"===r&&t.__pasting||n.value&&n.value!==i&&t.inputChange(t.__backward)}))},_trackChange:function(){var e=this;e.__changing=!0,h((function(){e.__changing=!1}))},_form:function(){var t=this;var n=t.element;var i=n.attr("form");var r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){h((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;var 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=this.element[0];var l=s.value||this._emptyMask;var c=this.options.promptChar;var d;var h=0;var u;var p;var f;for((e=this._find(e,a))>n&&(n=e),u=this._unmask(l.substring(n),n),d=(i=this._unmask(i,e)).length,i&&(u=u.replace(new RegExp("^_{0,"+d+"}"),"")),i+=u,l=l.split(""),p=i.charAt(h);e<this._maskLength;)l[e]=p||c,p=i.charAt(++h),f===t&&h>d&&(f=e),e=this._find(e+1);return s.value=this._old=l.join(""),r._activeElement()===s&&(f===t&&(f=this._maskLength),o(s,f)),f},_unmask:function(e,t){if(!e)return"";if(this._unmaskedValue===e)return this._unmaskedValue;var n;var i;e=(e+"").split("");var o=0;var a=t||0;var s=this.options.promptChar;var l=e.length;var c=this.tokens.length;var d="";for(;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=this;var n=t.element;var i=t.options;var o=n.attr("id");var a;var s;null!==i.label&&(a=!!d(i.label)&&i.label.floating,s=d(i.label)?i.label.content:i.label,a&&(t._floatingLabelContainer=t.wrapper.wrap("<span></span>").parent(),t.floatingLabel=new r.ui.FloatingLabel(t._floatingLabelContainer,{widget:t})),r.isFunction(s)&&(s=s.call(t)),s||(s=""),o||(o=i.name+"_"+r.guid(),n.attr("id",o)),t._inputLabel=e("<label class='"+(a?"k-floating-label":"k-label k-input-label")+"' for='"+o+"'>"+s+"</label>'")[a?"insertAfter":"insertBefore"](t.wrapper))},_wrapper:function(){var e=this.element;var t=e[0];var 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=h(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(){var e=[];var t=0;var n=(this.options.mask||"").split("");var i=n.length;var o=0;var a;var s;var l="";var c=this.options.promptChar;var d=r.getCulture(this.options.culture).numberFormat;var h=this._rules;for(;o<i;){if(s=h[a=n[o]])e[t]=s,l+=c,t+=1;else{"."===a||","===a?a=d[a]:"$"===a?a=d.currency.symbol:"\\"===a&&(a=n[o+=1]);for(var u=0,p=(a=a.split("")).length;u<p;u++)e[t]=a[u],l+=a[u],t+=1}o++}this.tokens=e,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",h="volume-down",u="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",w="k-mediaplayer-media",y="k-mediaplayer-overlay",k="k-mediaplayer-yt",x=".",C='span[class*="i-play"]',S='span[class*="i-'+l+'"]',T='span[class*="i-'+c+'"]',M='span[class*="i-'+d+'"]',A='span[class*="i-'+h+'"]',D='span[class*="i-'+u+'"]',E=".k-draghandle.k-selected",I=t.ui,z=".kendoMediaPlayer",P=new Date(1970,0,1),L=60*P.getTimezoneOffset(),B=t.ui.Widget,H=Array.isArray,R="mm:ss",F="HH:mm:ss",O=t.template,V=t.keys,N={htmlPlayer:()=>"<video class='"+w+"'> </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")}`};var $=B.extend({init:function(n,i){this.wrapper=e(n),B.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 H(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+w).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+w+" > source").remove(),this.wrapper.find(x+w).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+w).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");var n=this.wrapper.find(x+p);var 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&&H(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();var 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(M)||i.is(A)||i.is(D))){var o=this.mute();this.mute(!o)}},_sliderDragging:function(){this.media()&&(this._isDragging=!0)},_sliderDragChange:function(e){var t=this;var n=e.sender;var i=1e3*L;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;var 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:h}),n.attr("title",this.options.messages.mute),n.attr("aria-label",this.options.messages.mute)):(t.ui.icon(i,{icon:u}),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+L),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+L)),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()?R:F,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();var 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='"+y+"'></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+w)[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";var 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){B.fn.setOptions.call(this,e)},destroy:function(){B.fn.destroy.call(this),this.isPaused()||this.pause(),this.element.off(z),this.element.find(x+y).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;H(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;const n=t.dataSource;const 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 s_=function(e){return null!=e};var l_=function(e){return null==e};var c_=function(e){return Array.isArray(e)};var d_=function(e){return"function"==typeof e};var h_=function(e){return"string"==typeof e};var u_=function(e){return!function(e){return l_(e)||0===e.trim().length}(e)};var p_=function(e){return e&&e.getTime};var f_=function(e){return s_(e.filters)};Object.create;Object.create;"function"==typeof SuppressedError&&SuppressedError;var m_=function(e,t,n){return function(i){return e(i)?t(i):n(i)}};var g_=function(){var e=[];for(var t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return e.reduceRight((function(e,t){return t(e)}),t)}};var v_=function(e){return new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()))};var __=function(e){return p_(e.value)};b_="";var b_;var w_={};var y_=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;w_[void 0]=function(e){return e};var k_=function(e,t){var n=e+t;if(w_[n])return w_[n];var i=[];return e.replace(y_,(function(e,t,n,r){i.push(s_(t)?t:n||r)})),w_[n]=function(e){var n=e;for(var r=0;r<i.length;r++)if(n=n[i[r]],!s_(n)&&t)return n;return n},w_[n]};var x_=function(e){return function(t){return[e,t]}};var C_=function(){return null};var S_=function(e){return function(t){return s_(e(t))}};var T_=function(e){return function(t){return function(e){return s_(e)&&c_(e)&&e.length>0}(e(t))}};var M_=function(e,t){return m_(e,t,C_)};var A_=function(e,t){return function(n){return e(n).map(t).join("~")}};var D_=g_.apply(void 0,[['"',""],[":","-"]].map((function(e){var t=e[0],n=e[1];return function(e){return e.replace(new RegExp(t,"g"),n)}})));var E_=(I_=".",function(e){return e.slice(0,e.indexOf(I_))});var I_;var z_=function(e){var t=e.field,n=e.dir,i=void 0===n?"asc":n;return"".concat(t,"-").concat(i)};var P_=k_("take");var L_=k_("aggregates");var B_=k_("skip");var H_=k_("group");var R_=k_("sort",!0);var F_=A_(R_,z_);var O_=A_(H_,z_);var V_=A_(L_,(function(e){var t=e.field,n=e.aggregate;return"".concat(t,"-").concat(n)}));var N_=g_((function(e){return"datetime'".concat(e,"'")}),E_,D_,JSON.stringify,v_);var $_=g_(x_("page"),(function(e){var t=e.skip,n=e.take;return Math.floor((t||0)/n)+1}));var U_=g_(x_("pageSize"),P_);var W_=g_(x_("group"),O_);var j_=g_(x_("sort"),F_);var q_=g_(x_("aggregate"),V_);M_(S_(B_),$_);M_(S_(P_),U_);M_(T_(H_),W_);M_(S_(L_),q_);g_(M_(T_(R_),j_),(function(e){return Object.assign({},e,{sort:(R_(e)||[]).filter((function(e){var t=e.dir;return u_(t)}))})}));var G_=function(e){var t=e.field,n=e.operator,i=e.value;return"".concat(t,"~").concat(n,"~").concat(i)};m_(__,g_(G_,(function(e){var t=e.field,n=e.value,i=e.ignoreCase,r=e.operator;return{value:N_(n),field:t,ignoreCase:i,operator:r}})),G_);var K_=function(e,t,n){return t[e]=n,t};var Y_=function(e){return function(t){var n=t[e];return s_(n)?n:t[(i=e,i.replace(/(^[A-Z])/g,(function(e,t){return t.toLowerCase()})))];var i}};Y_("Member");Y_("AggregateMethodName");Y_("Value");var Q_=function(e){return function(t){return Object.keys(t).reduce(e.bind(null,t),{})}};var X_=Q_((function(e,t,n){return K_(n.toLowerCase(),t,e[n])}));var Z_=Q_((function(e,t,n){return K_(n,t,X_(e[n]))}));var J_=function(e,t){return s_(e)?e:t};var eb=g_((function(e){var t=e.field,n=e.hasSubgroups,i=e.value,r=e.aggregates,o=e.items;return{aggregates:Z_(r),field:t,items:n?o.map(eb):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:J_(e.Key,J_(e.key,e.value))}}));var tb=function(e){return function(t){return function(n,i,r){return t(n,e(i,r))}}};tb((function(e){return e}));var nb={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}}};var ib={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 s_(e)},isnull:function(e){return l_(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)}};var rb=/^\/Date\((.*?)\)\/$/;var ob=function(e){var t=e.field,n=e.ignoreCase,i=e.value,r=e.operator;t=s_(t)?t:function(e){return e},n=!s_(n)||n;var o=function(e,t,n){if(!s_(t))return e;var i=e;if(h_(t)){var r=rb.exec(t);r?t=new Date(+r[1]):i=function(t){var i=e(t);if(null===i)return i;var r="string"==typeof i?i:i+"";return n?r.toLowerCase():r}}return p_(t)?function(e){var t=i(e);return p_(t)?t.getTime():t}:i}(d_(t)?t:k_(t,!0),i,n);i=function(e,t){if(null!=e&&h_(e)){var n=rb.exec(e);if(n)return new Date(+n[1]).getTime();if(t)return e.toLowerCase()}else if(null!=e&&p_(e))return e.getTime();return e}(i,n);var a=d_(r)?r:ib[r];return function(e){return a(o(e),i,n)}};var ab=function(e){var t=nb[e.logic];return e.filters.filter(s_).map((function(e){return f_(e)?ab(e):ob(e)})).reduce(t.concat,t.identity)};var sb=function(e){return e&&0!==e.filters.length?ab(e):function(){return!0}};tb((function(e){return e}));var lb;!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"}(lb||(lb={}));var cb={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}"'};var db="doesnotcontain",hb="in",ub="neq";function pb(e){var t="";var n=String(e.value);var i=e.field;var r=e.operator;return r===hb?(t+="{",t+=n,t+="}"):(t+=r===ub||r===db?"-":"",t+="Filter(",t+=i+".MEMBERS",t+=function(e){var t=[];for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.forEach((function(t,n){e=e.replace(new RegExp("\\{".concat(n,"\\}"),"g"),t)})),e}(cb[r],i,n),t+=")"),t}function fb(e,t,n){var i="";var r=function(e){var t=[];var n=[];var i=[];var r=0;var o;for(;r<e.length;r++){var a=e[r];var s=a.name;if(o=!1,s.length>1)n.push(a);else{var l=bb(s[0]);for(var c=0,d=i.length;c<d;c++)if(0===i[c].name[0].indexOf(l)){o=!0;break}o||i.push(a),a.expand&&t.push(a)}}return t=t.concat(n),{expanded:t,root:i}}(e=e||[]);var o=r.expanded;var a=function(e){var t=[];return e.forEach((function(e){var n=e.name[0];var i=bb(n);t.some((function(e){return 0===e.indexOf(i)}))||t.push(n)})),t}(r.root);var s=[];var l=o.length;var c=0;var d;var h=[];if(a.length>1||t.length>0){for(s.push(vb(a,t));c<l;c++)h=gb(d=_b(o[c].name,n),a),s.push(vb(h,t));i+=s.join(",")}else{for(;c<l;c++)d=_b(o[c].name,n),h.push(d[0]);i+=a.concat(h).join(",")}return i}function mb(e){var t=e.length;var n=[];var i;for(var r=0;r<t;r++)i=e[r],n.push(void 0!==i.name?i.name:i);return n}function gb(e,t){var n=t.length;t=t.slice(0);for(var i=0;i<e.length;i++){var r=e[i];for(var o=0;o<n;o++){var a=bb(t[o]);if(-1!==r.indexOf(a)){t[o]=r;break}}}return t}function vb(e,t){var n=e.slice(0);return t.length>0&&n.push("{"+mb(t).join(",")+"}"),wb(n)}function _b(e,t){var n=e.length-1;var i=e[n];var 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 bb(e){var t=e.split(".");return t.length>2?t[0]+"."+t[1]:e}function wb(e){var t="CROSSJOIN({";var n;return e.length>2?(n=e.pop(),t+=wb(e)):(t+=e.shift(),n=e.pop()),t+="},{",t+=n,t+="})"}function yb(e){var t='<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Header/><Body><Execute xmlns="urn:schemas-microsoft-com:xml-analysis"><Command><Statement>';var n=e.columnAxes,i=void 0===n?[]:n,r=e.rowAxes,o=void 0===r?[]:r;var a=e.measureAxes,s=void 0===a?[]:a,l=e.sort,c=void 0===l?[]:l,d=e.filter,h=void 0===d?[]:d;var u="rows"===e.measuresAxis;return t+="SELECT NON EMPTY {",!i.length&&o.length&&(!s.length||s.length&&u)&&(i=o,o=[],u=!1),i.length||o.length||(u=!1),i.length?t+=fb(i,u?[]:s,c):s.length&&!u&&(t+=mb(s).join(",")),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON COLUMNS",(o.length||u&&s.length>1)&&(t+=", NON EMPTY {",o.length?t+=fb(o,u?s:[],c):t+=mb(s).join(","),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON ROWS"),h.length?(t+=" FROM ",t+="(",t+=function(e,t){var n="";var i="";for(var r=e.length-1;r>=0;r--)i="SELECT (",i+=pb(e[r]),i+=") ON 0",n=r===e.length-1?i+=" FROM ["+t+"]":i+" FROM ( "+n+" )";return n}(h,e.connection.cube),t+=")"):t+=" FROM ["+e.connection.cube+"]",(t+="</Statement></Command><Properties><PropertyList><Catalog>"+e.connection.catalog+"</Catalog><Format>Multidimensional</Format></PropertyList></Properties></Execute></Body></Envelope>").replace(/&/g,"&")}var kb=function(e,t){return kb=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])},kb(e,t)};function xb(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}kb(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Cb=function(){return Cb=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},Cb.apply(this,arguments)};function Sb(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 Tb(e,t){var n,i,r,o={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(l){return function(s){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(n=1,i&&(r=2&s[0]?i.return:s[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,s[1])).done)return r;switch(i=0,r&&(s=[2&s[0],r.value]),s[0]){case 0:case 1:r=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,i=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!(r=o.trys,(r=r.length>0&&r[r.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!r||s[1]>r[0]&&s[1]<r[3])){o.label=s[1];break}if(6===s[0]&&o.label<r[1]){o.label=r[1],r=s;break}if(r&&o.label<r[2]){o.label=r[2],o.ops.push(s);break}r[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],i=0}finally{n=r=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,l])}}}Object.create;function Mb(e,t,n){if(n||2===arguments.length)for(var i,r=0,o=t.length;r<o;r++)!i&&r in t||(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}Object.create;"function"==typeof SuppressedError&&SuppressedError;function Ab(e){var t=(new DOMParser).parseFromString(e,"text/xml");var n=Array.from(t.querySelectorAll("Axis"));var i=Array.from(t.querySelectorAll("CellData > Cell")).map((function(e){return{fmtValue:Db(e,"FmtValue"),ordinal:parseInt(e.getAttribute("CellOrdinal"),10),value:Db(e,"Value")}}));var r={tuples:[]};var o={tuples:[]};var 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(Db(e,"LNum")||"0",10);var n=parseInt(Db(e,"CHILDREN_CARDINALITY")||"0",10)>0;return{caption:Db(e,"Caption"),children:[],hasChildren:n,hierarchy:e.getAttribute("Hierarchy"),levelName:Db(e,"LName"),levelNum:t,name:Db(e,"UName"),parentName:Db(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 Db(e,t){var n=e.querySelector(t);return n?n.textContent:""}var Eb={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 Ib(e){var t={};var n='<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Header/><Body><Discover xmlns="urn:schemas-microsoft-com:xml-analysis">';return n+="<RequestType>"+(Eb[e.command]||e.command)+"</RequestType>",n+="<Restrictions>"+zb("RestrictionList",e.restrictions,!0)+"</Restrictions>",e.connection&&e.connection.catalog&&(t.Catalog=e.connection.catalog),n+="<Properties>"+zb("PropertyList",t,!1)+"</Properties>",n+="</Discover></Body></Envelope>"}function zb(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 Pb={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:Db(e,"CATALOG_NAME"),description:Db(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:Db(e,"CUBE_NAME"),caption:Db(e,"CUBE_CAPTION"),description:Db(e,"DESCRIPTION"),type:Db(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:Db(e,"DIMENSION_CAPTION"),defaultHierarchy:Db(e,"DEFAULT_HIERARCHY"),description:Db(e,"DESCRIPTION"),name:Db(e,"DIMENSION_NAME"),type:parseInt(Db(e,"DIMENSION_TYPE"),10),uniqueName:Db(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:Db(e,"HIERARCHY_NAME"),caption:Db(e,"HIERARCHY_CAPTION"),description:Db(e,"DESCRIPTION"),uniqueName:Db(e,"HIERARCHY_UNIQUE_NAME"),dimensionUniqueName:Db(e,"DIMENSION_UNIQUE_NAME"),displayFolder:Db(e,"HIERARCHY_DISPLAY_FOLDER"),origin:Db(e,"HIERARCHY_ORIGIN"),defaultMember:Db(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:Db(e,"KPI_NAME"),uniqueName:Db(e,"KPI_NAME"),caption:Db(e,"KPI_CAPTION"),value:Db(e,"KPI_VALUE"),goal:Db(e,"KPI_GOAL"),status:Db(e,"KPI_STATUS"),trend:Db(e,"KPI_TREND"),statusGraphic:Db(e,"KPI_STATUS_GRAPHIC"),trendGraphic:Db(e,"KPI_TREND_GRAPHIC"),description:Db(e,"KPI_DESCRIPTION"),groupName:Db(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:Db(e,"LEVEL_NAME"),caption:Db(e,"LEVEL_CAPTION"),description:Db(e,"DESCRIPTION"),uniqueName:Db(e,"LEVEL_UNIQUE_NAME"),dimensionUniqueName:Db(e,"DIMENSION_UNIQUE_NAME"),displayFolder:Db(e,"LEVEL_DISPLAY_FOLDER"),orderingProperty:Db(e,"LEVEL_ORDERING_PROPERTY"),origin:Db(e,"LEVEL_ORIGIN"),hierarchyUniqueName:Db(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:Db(e,"MEASURE_NAME"),caption:Db(e,"MEASURE_CAPTION"),uniqueName:Db(e,"MEASURE_UNIQUE_NAME"),description:Db(e,"DESCRIPTION"),aggregator:Db(e,"MEASURE_AGGREGATOR"),groupName:Db(e,"MEASUREGROUP_NAME"),displayFolder:Db(e,"MEASURE_DISPLAY_FOLDER"),defaultFormat:Db(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:Db(e,"MEMBER_NAME"),caption:Db(e,"MEMBER_CAPTION"),uniqueName:Db(e,"MEMBER_UNIQUE_NAME"),dimensionUniqueName:Db(e,"DIMENSION_UNIQUE_NAME"),hierarchyUniqueName:Db(e,"HIERARCHY_UNIQUE_NAME"),levelUniqueName:Db(e,"LEVEL_UNIQUE_NAME"),childrenCardinality:Db(e,"CHILDREN_CARDINALITY")}}))}};var Lb=function(e,t){return Sb(void 0,void 0,void 0,(function(){var n;return Tb(this,(function(i){switch(i.label){case 0:return n=Cb({body:yb(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,Ab(i.sent())]}}))}))};var Bb=function(e,t){return Sb(void 0,void 0,void 0,(function(){var n,i;return Tb(this,(function(r){switch(r.label){case 0:return n=Cb({body:Ib(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,Pb[t.command](i)]}}))}))};var Hb=function(e){return"[Measures]"===e.hierarchy};var Rb=function(e,t){return void 0===t&&(t=new Set),(e.children||[]).forEach((function(e){t.add(e.levelName),Rb(e,t)})),t.size};var Fb=function(e){var t=0;return(e.children||[]).forEach((function(e){t+=Fb(e)||1})),t};var Ob=function(e,t){return(t&&t.hierarchy===e.hierarchy?Mb(Mb([],(t.normalizedPath||[]).slice(0,-1),!0),[e.name||null],!1):Mb(Mb([],t&&t.normalizedPath?t.normalizedPath:[],!0),[e.name],!1)).filter(Boolean)};var Vb=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=Rb(e);var c=Fb(e);var d=i||l;var h=r||c;var u=o?o.slice():[];var p=a?a.slice():new Array(h);var f=u.findIndex((function(t){return t&&t.name===e.levelName&&t.level===e.levelNum}));var m=u[f];var g={name:e.levelName,level:e.levelNum,index:t,cells:new Array(h).fill(null)};var v=-1!==t&&-1!==n;var _={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(u[t]&&u[t].cells.length){for(var b=t;b<u.length;b++){u[b].index++}u.splice(t,0,g),u[t].cells[n]=_}else u[t]=g,u[t].cells[n]=_;var w=0;return e.children&&e.children.length?e.children.forEach((function(e){var i=Vb(e,t+1,n+w,d,h,u,p,_),r=i[0],o=i[1],a=i[3];w+=a||1,u=r.slice(),p=o.slice()})):e.normalizedPath&&(p[n]={total:_.total,path:e.normalizedPath}),_.depth=l,_.breadth=c,[u,p,l,c]};var Nb=function(e,t,n){var i;void 0===t&&(t=null),void 0===n&&(n=0);var r=Cb(Cb({},e),{total:!0,hasChildren:!1,children:[]});for(var o=0;o<e.children.length;o++){var a=Nb(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};var $b=function(e){var t={children:[]};var n={};if(e.every((function(e){return 1===e.members.length&&Hb(e.members[0])})))return{children:e.map((function(e){var t=e.members[0];return Cb(Cb({},t),{normalizedPath:[t.name],parentName:t.name,path:[t.hierarchy]})}))};for(var i=0;i<e.length;i++){var r=qb(e[i]);var o="";var a=function(e){var i=r.members[e];var a;if(t.children&&0===t.children.length)a=t;else if(n[o]&&!n[o+i.name]&&0===i.levelNum)a=n[o];else if(n[o+i.parentName]&&i.levelNum>0&&!n[o+i.parentName+i.name])a=n[o+i.parentName];else if(!n[o+i.parentName]&&i.levelNum>0&&!n[o+i.parentName+i.name]){var s=Object.keys(n).find((function(e){return i.parentName===n[e].name}));s&&(a=n[s])}if(a){i.path=(c=i,((d=a)&&d.hierarchy===c.hierarchy?Mb(Mb([],(d.path||[]).slice(0,-1),!0),[(0===c.levelNum?c.hierarchy:c.name)||null],!1):Mb(Mb([],d&&d.path?d.path:[],!0),[0===c.levelNum?c.hierarchy:c.name],!1)).filter(Boolean)),i.normalizedPath=Ob(i,a);var l=a.children.findIndex((function(e){return e.hierarchy!==a.hierarchy}));-1!==l?a.children.splice(l,0,i):a.children.push(i)}var c,d;i.parentName+=i.name,o+=i.parentName,n[o]||(n[o]=i)};for(var s=0;s<r.members.length;s++)a(s)}return qb(Nb(t))};var Ub=function(e,t,n,i,r){var o=Array.from(new Array(r),(function(){return{cells:Array.from(new Array(i),(function(){return null}))}}));var a=function(e){return e.join("|")};var s=function(e){return e.members.map((function(e){return e.name}))};var l=new Map;var 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)));var 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};var Wb=function(e){var t=Vb(e),n=t[0],i=t[1],r=t[2],o=t[3];for(var a=0;a<o;a++){var s=null;for(var 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]};var jb=function(e){var t=Vb(e),n=t[0],i=t[1],r=t[2],o=t[3];for(var a=0;a<o;a++){var s=null;for(var 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){var r=new Array(i);for(var 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]=Cb(Cb({},s),{rowSpan:s.colSpan,colSpan:s.rowSpan})}return[r,t,i,n]}(n,i,r,o)};function qb(e){return JSON.parse(JSON.stringify(e))}var Gb=function(e,t,n){return{hierarchyUniqueName:e,uniqueName:t,caption:t,measure:t,name:t,type:n,kpi:!0}};function Kb(e){var t=e.name;return[Gb(t,e.value,"value"),Gb(t,e.goal,"goal"),Gb(t,e.status,"status"),Gb(t,e.trend,"trend")]}var Yb=function(e){var t;var n=0;for(;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]"})};var Qb=function(e,t){return String(e.name)===String([t.defaultHierarchy?t.defaultHierarchy:t.uniqueName])};var Xb=function(e,t){return String(e.name)===String(t.name)};var Zb=function(e,t){var n=function(n){var i=e[n];var r=i.name.findIndex((function(e){return Qb({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]=Cb(Cb(Cb({},e[o]),i),e[o].expand||i.expand?{expand:!0}:{}),e.splice(n,1))}};for(var i=e.length-1;i>=0;i--)n(i)};var Jb=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 Xb(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,Mb([i,0],t.name,!1))})),e.splice(i,0,t)):e.push(t)};var ew=function(e){var t=e.length&&e[0];var n=t&&t.members[t.members.length-1];if(n&&Hb(n)){var i=[];var r=new Set(e.map((function(e){return e.members[e.members.length-1].caption}))).size;for(var 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};var tw=function(e){return{columns:ew(e.columns.tuples),data:e.data,rows:e.rows.tuples}};function nw(e){var t=[];for(var 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 iw=function(e,t){void 0===t&&(t=[]),e.sort=t};var rw=function(e,t){void 0===t&&(t=[]),e.filter=t};var ow;!function(e){e.toggle="HEADERS_ACTION_TOGGLE",e.expand="HEADERS_ACTION_EXPAND",e.collapse="HEADERS_ACTION_COLLAPSE"}(ow||(ow={}));var aw=function(e,t,n){var i=new Set;return e.children.forEach((function(e){var r=t(e);n&&i.add(String(e.path)),aw(e,t,n||r).map((function(e){i.add(e)}))})),Array.from(i.values())};var sw=function(e,t){switch(t.type){case ow.toggle:var n=e.find((function(e){return String(e.name)===String(t.payload)}));return sw(e,Cb(Cb({},t),{type:n&&n.expand?ow.collapse:ow.expand}));case ow.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?Cb(Cb({},i),{expand:!0}):e}));case ow.collapse:var o=aw(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 Cb(Cb({},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}};var lw;!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"}(lw||(lw={}));var cw=function(e,t){var n;var i;var r;var o;var a;var s;var l;var c;var d;switch(t.type){case lw.toggleSelection:if(!Array.isArray(t.payload)){var h=t.payload;if(2===h.type||"aggregator"in h)return e.measureAxes.some((function(e){return Qb(e,h)}))?cw(e,Cb(Cb({},t),{type:lw.removeMeasureAxis})):cw(e,Cb(Cb({},t),{type:lw.addMeasureAxis}));if("kpi"===h.type){var u=Kb(h);return u.every((function(t){return e.measureAxes.some((function(e){return Qb(e,t)}))}))?cw(e,Cb(Cb({},t),{type:lw.removeMeasureAxes,payload:u})):cw(e,Cb(Cb({},t),{type:lw.addMeasureAxes,payload:u.filter((function(t){return!e.measureAxes.some((function(e){return Qb(e,t)}))}))}))}return t.payload.kpi?e.measureAxes.some((function(e){return Qb(e,h)}))?cw(e,Cb(Cb({},t),{type:lw.removeMeasureAxis})):cw(e,Cb(Cb({},t),{type:lw.addMeasureAxis})):e.columnAxes.some((function(e){return Qb(e,h)}))?cw(e,Cb(Cb({},t),{type:lw.removeColumnAxis})):e.rowAxes.some((function(e){return Qb(e,h)}))?cw(e,Cb(Cb({},t),{type:lw.removeRowAxis})):!e.columnAxes||!e.columnAxes.length||e.rowAxes&&e.rowAxes.length?cw(e,Cb(Cb({},t),{type:lw.addColumnAxis})):cw(e,Cb(Cb({},t),{type:lw.addRowAxis}))}break;case lw.addColumnAxis:i=Mb(Mb([],e.columnAxes||[],!0),[{name:[t.payload.defaultHierarchy||t.payload.uniqueName]}],!1);break;case lw.addColumnAxes:break;case lw.removeColumnAxis:i=Mb([],(e.columnAxes||[]).filter((function(e){return!Qb(e,t.payload)})),!0),Zb(i,t.payload);break;case lw.removeColumnAxes:break;case lw.addRowAxis:n=Mb(Mb([],e.rowAxes||[],!0),[{name:[t.payload.defaultHierarchy||t.payload.uniqueName]}],!1);break;case lw.addRowAxes:break;case lw.removeRowAxis:n=Mb([],(e.rowAxes||[]).filter((function(e){return!Qb(e,t.payload)})),!0),Zb(n,t.payload);break;case lw.removeRowAxes:break;case lw.addMeasureAxis:r=Mb(Mb([],e.measureAxes||[],!0),[{name:[t.payload.defaultHierarchy||t.payload.uniqueName]}],!1);break;case lw.removeMeasureAxis:r=Mb([],(e.measureAxes||[]).filter((function(e){return!Qb(e,t.payload)})),!0);break;case lw.addMeasureAxes:r=Mb(Mb([],e.measureAxes||[],!0),(t.payload||[]).map((function(e){return{name:[e.defaultHierarchy||e.uniqueName]}})),!0);break;case lw.removeMeasureAxes:r=Mb([],(e.measureAxes||[]).filter((function(e){return!t.payload.some((function(t){return Qb(e,t)}))})),!0);break;case lw.remove:e.columnAxes.some((function(e){return Xb(e,t.payload)}))&&(i=Mb([],e.columnAxes.filter((function(e){return!Xb(e,t.payload)})),!0),Zb(i,{uniqueName:t.payload.name})),e.rowAxes.some((function(e){return Xb(e,t.payload)}))&&(n=Mb([],e.rowAxes.filter((function(e){return!Xb(e,t.payload)})),!0),Zb(n,{uniqueName:t.payload.name})),e.measureAxes.some((function(e){return Xb(e,t.payload)}))&&(r=Mb([],e.measureAxes.filter((function(e){return!Xb(e,t.payload)})),!0));break;case lw.setDragItem:s=t.payload;break;case lw.setDropZone:l=t.payload;break;case lw.setDropTarget:d=t.payload;break;case lw.setDropDirection:c=t.payload;break;case lw.drop:if(e.dragItem&&e.dropZone){var p=e.columnAxes.find((function(e){return Xb(e,t.payload)}));var f=e.rowAxes.find((function(e){return Xb(e,t.payload)}));var m=e.measureAxes.find((function(e){return Xb(e,t.payload)}));var g=void 0;switch(p&&(g=p,i=Mb([],e.columnAxes.filter((function(e){return!Xb(e,t.payload)})),!0),Zb(i,{uniqueName:t.payload.name})),f&&(g=f,n=Mb([],e.rowAxes.filter((function(e){return!Xb(e,t.payload)})),!0),Zb(n,{uniqueName:t.payload.name})),m&&(g=m,r=Mb([],e.measureAxes.filter((function(e){return!Xb(e,t.payload)})),!0)),e.dropZone){case"columnAxes":i=i||e.columnAxes.slice(),Jb(i,g,e);break;case"rowAxes":n=n||e.rowAxes.slice(),Jb(n,g,e);break;case"measureAxes":r=r||e.measureAxes.slice(),Jb(r,g,e)}}s=null,l=null,d=null;break;case lw.setSort:o=t.payload;break;case lw.setFilter:a=Array.isArray(t.payload)?t.payload:[t.payload];break;case lw.addFilter:a=(e.filter||[]).slice(),Array.isArray(t.payload)?a.push.apply(a,t.payload):a.push(t.payload);break;case lw.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 lw.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}};var dw;!function(e){e[e.Sum=0]="Sum",e[e.Count=1]="Count",e[e.Min=2]="Min",e[e.Max=3]="Max",e[e.Average=4]="Average"}(dw||(dw={}));var hw=0;var uw=function(e){var t="".concat(dw[e],"_").concat(hw++);switch(e){case dw.Sum:return{init:function(e){t in e==!1&&(e[t]=0)},merge:function(e,n){n[t]+=e[t]},accumulate:function(e,n){e[t]+=n},result:function(e){return e[t]},format:function(e){return e.toFixed(2)}};case dw.Count:return{init:function(e){t in e==!1&&(e[t]=0)},merge:function(e,n){n[t]+=e[t]},accumulate:function(e,n){e[t]+=1},result:function(e){return e[t]},format:function(e){return e.toFixed()}};case dw.Min:return{init:function(e){t in e==!1&&(e[t]=Number.POSITIVE_INFINITY)},merge:function(e,n){n[t]=Math.min(e[t],n[t])},accumulate:function(e,n){e[t]=Math.min(n,e[t])},result:function(e){return Number.isFinite(e[t])?e[t]:NaN},format:function(e){return e.toFixed(2)}};case dw.Max:return{init:function(e){t in e==!1&&(e[t]=Number.NEGATIVE_INFINITY)},merge:function(e,n){n[t]=Math.max(e[t],n[t])},accumulate:function(e,n){e[t]=Math.max(n,e[t])},result:function(e){return Number.isFinite(e[t])?e[t]:NaN},format:function(e){return e.toFixed(2)}};case dw.Average:var n="".concat(t,"_sum");var i="".concat(t,"_count");return{init:function(e){i in e==!1&&(e[n]=0,e[i]=0)},merge:function(e,t){t[n]+=e[n],t[i]+=e[i]},accumulate:function(e,t){e[n]+=t,e[i]+=1},result:function(e){return e[n]/e[i]},format:function(e){return e.toFixed(2)}};default:throw new Error("Invalid aggregate type provided")}};var pw=uw(dw.Sum);var fw=uw(dw.Count);var mw=uw(dw.Min);var gw=uw(dw.Max);var vw=uw(dw.Average);function _w(e,t){"filters"in e?e.filters.map((function(e){return _w(e,t)})):t(e)}var bw=function(e,t){(Array.isArray(e)?e:e.filters).forEach((function(e){return _w(e,t)}))};var ww=function(e,t,n){var i=e.get(t);return i||(i=n||new Map,e.set(t,i)),i};var yw=function(e){var t=e.indexOf("&");return-1!==t?[e.substring(0,t),e.substring(t+1)]:[e,void 0]};var kw=function(e,t,n){e.forEach((function(i,r){if(r!==n){i.size>0&&kw(i,t,n);var o=i.get(n);var a=ww(e,n,{});t.forEach((function(e){e.aggregate.init(a),e.aggregate.merge(o,a)}))}}))};var xw=function(e,t,n,i){e.forEach((function(e,r){var o;r!==i?(o=ww(t,r),xw(e,o,n,i)):(o=ww(t,r,{}),n.forEach((function(t){t.aggregate.init(o),t.aggregate.merge(e,o)})))}))};var Cw=function(e,t,n,i){e.forEach((function(r,o){if(o!==n){r.size>0&&Cw(r,t,n,i);var a=ww(r,n);var s=ww(e,n);xw(a,s,t,i)}}))};var Sw=function(e,t,n,i,r,o){var a=new Map;var s=new Map;var l=t.concat(n);var c=new Set;var d=r.dataField,h=r.columnsData;var u=function(e,t,n){var i=n?Array.isArray(n)?{logic:"and",filters:n}:n:void 0;var r=i?sb(i):function(){return!0};var o=e.concat(t);var a=[];bw(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());var 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=u.hasFilter,f=u.predicate,m=u.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)}));var u="".concat.apply("",o);var g=s.get(u);if(!g){var v=a;var _=function(t){v=ww(v,function(e,t){return e+"&"+t}(t.key,t.displayValue(e)))};t.forEach(_),v=ww(v,h),c.add(v),n.forEach(_),g={},v.set(d,g),s.set(u,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 kw(e,i,d)})),Cw(a,i,h,d),a};var Tw=function(e,t,n){var i=new Map;return xw(e,i,n,t),i};var Mw=function(e,t,n){var i=yw(e),r=i[0],o=i[1];var a=n.slice();if(r&&o){var s=t.find((function(e){return e.key===r}));var l=s?s.caption:"";return a.map((function(t){return t===l?e:t}))}return a};var Aw=function(e,t,n,i,r,o,a){var s=a||new Map;var l=i.map((function(e){return e.caption}));for(;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=Mw(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("-"))){var a=Array.from(c).find((function(e){return e[0]!==n}));var d=a&&a[0];var h=d&&yw(d)[0];var u=h?t-i.findIndex((function(e){return e.key===h})):0;var 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]);var n=e[1];var i=new Map;xw(t,i,r,o),xw(n,i,r,o),d.set(e[0],i)}else d.set(e[0],new Map(e[1]))}));var h=l.slice(0,l.indexOf(e.name));d.forEach((function(e,t){s.set(Mw(t,i,h.concat([t])).join("-"),e)})),d.set(n,c.get(n)),c=d};for(var f=0;f<u;f++)p()}c=c.get(e.name)||s.get(l.slice(0,l.indexOf(e.name)+1).join("-"))}})),c};var Dw=function(e,t,n,i,r,o,a){var s=[];var l=i.dataField,c=i.columnsData;var d=new Map;return t.forEach((function(t){var i=Aw(e,t.members.slice(),c,o,a,l,d);var h=i&&i.get(c);n.forEach((function(e){var n=e.members.slice();var 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=h&&Aw(h,n,l,r,a,l);var d="",u="";if(c&&i){var p=i.aggregate.result(c.get(l));d=String(p),u=i.aggregate.format(p)}s.push({columnTuple:e,data:{fmtValue:u,ordinal:0,value:d},rowTuple:t})}))})),s};var Ew=function(e,t,n){e.forEach((function(e,i){if(!n[i]){var r=ww(t,i);Ew(e,r,n)}}))};var Iw=function(e){var t=new Set;return e.forEach((function(e){1!==e.name.length||yw(e.name[0])[1]||t.add(e.name[0])})),t};var zw=function(e,t,n,i,r){var o=Iw(t);var a=[];var s=function(e,t){var n={members:[]};return e.forEach((function(e){var i=t.find((function(t){return t.key===e}));var r=i?i.caption:"";var 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);var l=function(s){var l=t[s];if(1===l.name.length&&!l.expand&&o.has(l.name[0]))return"continue";var c=new Set(o.keys());var d=[];var h=[];var u=[];var p;l.name.forEach((function(t,o){var s;var f=yw(t),m=f[0],g=f[1];if(p=e.find((function(e){return e.key===m})),g){c.delete(m),h.push(t);var v={children:[],caption:g,hierarchy:m,levelNum:1,levelName:m+" "+m,name:t,parentName:p?p.caption:""};d.push(v)}else if(l.expand&&l.name.length-1===o){c.delete(t),h.push(t);var _=function(e,t,n){var i=[];var r=function(e){return Array.from(e).filter((function(e){return!n[e[0]]}))};var o=new Map(e);var a;var s=function(e){if(a=o.get(t[e]))o=new Map(a);else if(e<t.length-1&&Array.from(o).some((function(n){return yw(n[0])[0]===t[e]}))){var s=[];o.forEach((function(e,t){n[t]||s.push.apply(s,r(new Map(e)))})),o=new Map,s.forEach((function(e){if(o.has(e[0])){var t=o.get(e[0]);var i=e[1];var r=new Map;Ew(t,r,n),Ew(i,r,n),o.set(e[0],r)}else o.set(e[0],new Map(e[1]))}))}else 0!==e&&e!==t.length-1||Array.from(o).some((function(n){return yw(n[0])[0]===t[e]}))&&i.push.apply(i,r(o))};for(var l=0;l<t.length;l++)s(l);return i}(n,h,r);var b=i.find((function(e){return e.field===m}));b&&b.dir&&_.sort(function(e,t){return function(n,i){var r=e.dir;var o=t.sortValue(yw(n[0])[1]);var a=t.sortValue(yw(i[0])[1]);return o<a?"asc"===r?-1:1:o>a?"asc"===r?1:-1:0}}(b,p));for(var w=0;w<_.length;w++){var y=_[w][0];var k={members:[]};u.push(k);var x=yw(y)[1];p=e.find((function(e){return e.key===t}));v={caption:x,children:[],levelName:t+" "+t,levelNum:1,parentName:p?p.caption:"",hierarchy:t,name:y};(s=k.members).push.apply(s,d),k.members.push(v)}}else if(l.expand){var C=(p=e.find((function(e){return e.key===t})))?p.caption:"";c.delete(t),h.push(t);v={children:[],caption:C,hierarchy:t,levelName:C,levelNum:0,name:C,parentName:""};d.push(v)}c.forEach((function(t){u.forEach((function(n){var i=(p=e.find((function(e){return e.key===t})))?p.caption:"";var r={children:[],hasChildren:!0,caption:i,hierarchy:t,levelName:i,levelNum:0,name:i,parentName:""};n.members.push(r)}))})),a.push.apply(a,u)}))};for(var c=0;c<t.length;c++)l(c);return a};var Pw=function(e){return{caption:String(e.name),children:[],hasChildren:!1,hierarchy:"[Measures]",levelName:"[Measures].[MeasuresLevel]",levelNum:0,name:"[Measures].["+e.name+"]",parentName:""}};var Lw=function(e,t){var n=Pw(t);var i=qb(e);return i.members.push(n),i};var Bw=function(e,t){if(t.length<2)return e;var n=e.slice();for(var i=n.length-1;i>=0;i--){var r=n[i];n[i]=Lw(n[i],t[0]);for(var o=1;o<t.length;o++){var a=Lw(r,t[o]);n.splice(i+o,0,a)}}return ew(n)};var Hw=function(e){var t;var n=e.dataTree,i=e.rowSettings,r=e.columnSettings,o=e.rowAxes,a=e.columnAxes,s=e.measures,l=e.sort,c=e.fields;var d=((t={})[c.columnsData]=c.columnsData,t[c.dataField]=c.dataField,t);var h=a.length?zw(r,a,n.get(c.columnsData),l,d):s.map((function(e){return{members:[Pw(e)]}}));var u=a.length>0?Bw(h,s):h;var p=o.length?zw(i,o,n,l,d):[{members:[]}];return{columns:u,data:Dw(n,p,u,c,r,i,s),rows:p}};var Rw=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};var Fw=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:!1,configurable:!0}),Object.defineProperty(e.prototype,"first",{get:function(){return this.root&&this.root.querySelector(this.selectors.join(","))||null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"last",{get:function(){var e=this.elements;return e[e.length-1]||null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"current",{get:function(){return this.elements.find((function(e){return e.matches(":focus")}))},enumerable:!1,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]))};var 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(","));var 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]))};var 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}();var Ow=".k-pivotgrid .k-pivotgrid-values";var Vw=".k-pivotgrid .k-pivotgrid-column-headers";var Nw=".k-pivotgrid .k-pivotgrid-row-headers";var $w=".k-pivotgrid > .k-pivotgrid-empty-cell";var Uw="table.k-pivotgrid-table";var Ww=".k-pivotgrid-cell";var jw=[Ow,Vw,Nw].join(",");var qw=[$w,[Vw,Uw,Ww].join(" "),[Nw,Uw,Ww].join(" "),[Ow,Uw,Ww].join(" ")];var Gw=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()}};var Kw=function(e,t,n){e.offsetLeft<t.scrollLeft&&(n.scrollLeft=e.offsetLeft)};var Yw=function(e,t,n){e.offsetLeft+e.offsetWidth>t.scrollLeft+t.offsetWidth&&e.offsetWidth<t.offsetWidth&&(n.scrollLeft=e.offsetLeft+e.offsetWidth-t.offsetWidth)};var Qw=function(e,t,n){t.scrollTop&&e.offsetTop<t.scrollTop&&(n.scrollTop=e.offsetTop)};var Xw=function(e,t,n){e.offsetTop+e.offsetHeight>t.scrollTop+t.offsetHeight&&e.offsetHeight<t.offsetHeight&&(n.scrollTop=e.offsetTop+e.offsetHeight-t.offsetHeight)};var Zw=function(e,t,n){var i=t.querySelector(Ow);var r=e&&e.closest(jw);i&&r&&e&&n.forEach((function(t){return t(e,r,i)}))};var Jw=function(e){var t=Array.from(e.rows);var n=Array.from(t&&t[0]&&t[0].cells||[]).map((function(e){return e.colSpan})).reduce((function(e,t){return e+t}),0);var 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};var ey=function(e){var t=Jw(e.querySelector([Vw,Uw].join(" ")));var n=Jw(e.querySelector([Nw,Uw].join(" ")));var i=Jw(e.querySelector([Ow,Uw].join(" ")));var r=e.querySelector($w);var o=new Array(n[0].length).fill(r);var a=[];for(var 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};var ty=function(e){return e.ctrlKey||e.metaKey};var ny=function(e,t,n){var i=ey(e);var 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);var o=[r[0]+n[0],r[1]+n[1]];var a=i[o[0]]&&i[o[0]][o[1]];for(;a&&a===t;)a=i[(o=[o[0]+n[0],o[1]+n[1]])[0]]&&i[o[0]][o[1]];return a};var iy={keydown:{ArrowLeft:function(e,t,n){n.preventDefault();var i=ny(t.root,e,[0,-1]);t.focusElement(i,e),Zw(i,t.root,[Yw,Kw,Xw,Qw])},ArrowRight:function(e,t,n){n.preventDefault();var i=ny(t.root,e,[0,1]);t.focusElement(i,e),Zw(i,t.root,[Kw,Yw,Xw,Qw])},ArrowUp:function(e,t,n){n.preventDefault();var i=ny(t.root,e,[-1,0]);t.focusElement(i,e),Zw(i,t.root,[Yw,Kw,Xw,Qw])},ArrowDown:function(e,t,n){n.preventDefault();var i=ny(t.root,e,[1,0]);t.focusElement(i,e),Zw(i,t.root,[Yw,Kw,Qw,Xw])},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:Gw,Space:Gw,Home:function(e,t,n){var i=ey(t.root);var r=ty(n)?i[0]:i.find((function(t){return Boolean(t.find((function(t){return t===e})))}))||[];var o=r[0];o&&(t.focusElement(o,e),Zw(o,t.root,[Yw,Kw,Xw,Qw]),n.preventDefault())},End:function(e,t,n){var i=ey(t.root);var r=ty(n)?i[i.length-1]:i.find((function(t){return Boolean(t.find((function(t){return t===e})))}))||[];var o=r&&r[r.length-1]||null;o&&(t.focusElement(o,e),Zw(o,t.root,[Kw,Yw,Qw,Xw]),n.preventDefault())}}};var ry={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)}}};var oy=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.selectors=qw,t.mouseEvents=ry,t.keyboardEvents=iy,t}return xb(t,e),t}(Fw);var ay=[".k-pivotgrid-configurator-content .k-form-field .k-fields-list-wrapper .k-treeview",".k-pivotgrid-configurator-content .k-chip",".k-pivotgrid-configurator-actions button"];var sy=function(e,t,n,i){n.preventDefault();var r=t.elements;var o=r.indexOf(e)+i;o<0&&(o=r.length-1),t.focusElement(r[o%r.length],e)};var ly=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(),sy(e,t,n,-1)))};var cy={keydown:{Tab:function(e,t,n){sy(e,t,n,n.shiftKey?-1:1)},Escape:function(e,t,n){if(n.target instanceof HTMLElement&&t.root){var i=t.root.previousElementSibling;var r=t.root.nextElementSibling;var 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:ly,Backspace:ly}};var dy={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)}}};var hy=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.selectors=ay,t.mouseEvents=dy,t.keyboardEvents=cy,t}return xb(t,e),t}(Fw);!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,h=n.data.Query.normalizeFilter,u=n.data.Query.normalizeSort,p={}.toString,f=function(e){return e},m=e.map,g=e.extend,v=n.keys,_=n.isFunction,b="resize",w="read",y="change",k="error",x="progress",C="Measures",S="stateReset",T="auto",M="<div></div>",A=".kendoPivotGrid",D="__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:h})=>`<th id="${t}" role="${d}" ${l?`aria-expanded="${h}"`:""} 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>`,L="collapseMember",B="caret-alt-down",H=`.k-i-${B},.k-svg-i-${B}`,R="caret-alt-right",F=({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>`:" ";var 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;var 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;var 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;var s;var 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){var i=n.members;for(var r=0;r<i.length;r++)if(!i[r].measure){var o=!1;for(var a=0;a<e.length;a++)if(0===He(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){var t=[];var n=e.members;for(var 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;const r=(i.reader.data(e)||[]).slice(0);r&&!i._pristineData&&(i._pristineData=r);const o=i._createSettings(t.columnAxes);const a=i._createSettings(t.rowAxes);const s=i.measures();const l={dataTree:Sw(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(Hw(l)),i.trigger(y),n.resolve()}function ae(e){var t=[];for(var 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:pw,average:vw,min:mw,max:gw,count:fw};var 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}};var 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={};var i;if("[object Array]"===p.call(t)){for(var r=0,o=t.length;r<o;r++)"string"==typeof(i=t[r])?n[i]={}:i[e]&&(n[i[e]]=i);t=n}return t},_rootTuples:function(e,n){var i=n.length||1;var r=this.dimensions||[];var o,a,s;var l=0;var c;var d=e.length;var h=[];var u=[];if(d||n.length){for(l=0;l<i;l++){for(o={members:[]},c=0;c<d;c++)s=(a=e[c]).split("&"),o.members[o.members.length]={children:[],caption:(r[a]||{}).caption||"All",name:a,levelName:a,levelNum:"0",hasChildren:!0,parentName:s.length>1?s[0]:t,hierarchy:a};i>1&&(o.members[o.members.length]={children:[],caption:n[l].caption,name:n[l].descriptor.name,levelName:"MEASURES",levelNum:"0",hasChildren:!1,parentName:t,hierarchy:"MEASURES"}),h[h.length]=o}u.push(D)}return{keys:u,tuples:h}},_sortMap:function(t,n){var i=[];var r=[];var o;var s;var l;for(l in t)t[l].directParentName||r.push(e.extend({},{name:l,parentName:t[l].parentName}));if(!r.length)for(l in t)r.push(e.extend({},{name:l,parentName:t[l].parentName}));me(r,t);for(var c=0;c<n.length;c++)fe(n[c].field.split(".").pop(),r,a.create({field:"name",dir:n[c].dir}));o=pe(r);for(var d=0;d<o.length;d++)(s=t[o[d].name]).index=d,i[d]=s;return i},_expandedTuples:function(n,i,r,o){var a=r.length||1;var s=this.dimensions||[];var l;var c;var d;var h;var u;var p;var f=[];var m=[];var g;var v;var _;var b;var w;for(d in o&&o.length&&!e.isEmptyObject(n)&&(n=this._sortMap(n,o)),n){for(h=n[d],u=f[(g=this._findExpandedMember(i,h.uniquePath)).index]||[],p=m[g.index]||[],v=g.member.names,l=0;l<a;l++){for(c={members:[]},w=0;w<v.length;w++)w===g.member.expandedIdx?(c.members[c.members.length]={children:[],caption:h.value,name:h.name,hasChildren:!1,levelNum:1,levelName:h.parentName+h.name,parentName:h.parentName,hierarchy:h.parentName+h.name},0===l&&p.push(st(c,w).join(""))):(_=(b=v[w]).split("&"),c.members[c.members.length]={children:[],caption:(s[b]||{}).caption||"All",name:b,levelName:b,levelNum:"0",hasChildren:!0,parentName:_.length>1?_[0]:t,hierarchy:b});a>1&&(c.members[c.members.length]={children:[],caption:r[l].caption,name:r[l].descriptor.name,levelName:"MEASURES",levelNum:"0",hasChildren:!0,parentName:t,hierarchy:"MEASURES"}),u[u.length]=c}f[g.index]=u,m[g.index]=p}return{keys:m,tuples:f}},_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);var 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){var n=0;var i=e&&e.length;var r=[];var o={};var a={};var s=this.measures||{};var l;var c;for(;n<i;n++)l=s[c=e[n].descriptor.name]||{},r.push(c),l.result&&(o[c]=l.result),l.format&&(a[c]=l.format);return{names:r,formats:a,resultFuncs:o,rowAxis:t}},_toDataArray:function(e,t,n,i){var r=[];var o;var a,s,l,c,d;var h,u,p;var f=1;var m=[];var g;var v=n.length||1;var _=i.length||1;for(t.rowAxis?f=(m=t.names).length:g=t.names,s=0;s<v;s++)for(h=e[n[s]||D],d=0;d<f;d++)for(t.rowAxis&&(g=[m[d]]),l=0;l<_;l++)for(p=i[l]||D,u=h.items[p],o=p===D?h.aggregates:u?u.aggregates:{},c=0;c<g.length;c++)a=g[c],this._addData(r,o[a],t.formats[a],t.resultFuncs[a]);return r},_addData:function(e,t,i,r){var o="";var a;t&&(t=r?r(t):t.accumulator,o=i?n.format(i,t):t),e[a=e.length]={ordinal:a,value:t||"",fmtValue:o}},_matchDescriptors:function(e,n,i){var r;var o;var a;var s=n.names;var l=n.expandedIdx;var c;for(;l>0;)if((r=s[--l].split("&")).length>1&&(o=r[0],a=r[1],(c=(c=i[o](e))!==t&&null!==c?c.toString():c)!=a))return!1;return!0},_calculateAggregate:function(e,t,n){var i={};var r;var o;for(var a=0;a<e.length;a++)o=e[a].descriptor.name,(r=n.aggregates[o]||{}).accumulator=e[a].aggregator(t,r),i[o]=r;return i},_processColumns:function(e,n,i,r,o,a,s,l){var c;var d;var h;var u;var p,f,m,g;var v=o.dataItem;var _=0;for(;_<n.length;_++)d=n[_],this._matchDescriptors(v,d,i)&&(g=d.names.slice(0,d.expandedIdx).join(""),m=f=d.names[d.expandedIdx],h=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),u=a.items[p]||{aggregates:{}},a.items[p]={index:h.index,aggregates:this._calculateAggregate(e,o,u)},l&&(r[p]||s.columnIndex++,r[p]=h))},_measureAggregators:function(e){var t=e.measures||[];var n=this.measures||{};var i=[];var r,o,a,s;var l,c;if(t.length){for(a=0,s=t.length;a<s;a++)if(l=null,o=n[(r=t[a]).name]){if("string"==typeof(c=o.aggregate)){if(!(l=le[c.toLowerCase()]))throw new Error("There is no such aggregate function");o.aggregate=l.aggregate||l,o.result=l.result}i.push({descriptor:r,caption:o.caption,result:o.result,aggregator:ne(o)})}}else i.push({descriptor:{name:"default"},caption:"default",aggregator:function(){return 1}});return i},_buildGetters:function(e){var t={};var i;var r;for(var o=0;o<e.length;o++)(i=(r=e[o]).split("&")).length>1?t[i[0]]=n.getter(i[0],!0):t[r]=n.getter(Z(r),!0);return t},_parseDescriptors:function(e){var t=Oe(e);var n=Re(t.root);var i=t.expanded;var r=[];for(var o=0;o<i.length;o++)r.push(Fe(i[o].name,n));return{root:n,expanded:r}},_filter:function(e,t){if(!t)return e;var i;var r=0;var o=t.filters;for(;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(",");var 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||[];var r="rows"===n.measuresAxis;var o=n.columns||[];var 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={};var l={};var c={};var d;var h={columnIndex:0};var u=this._measureAggregators(n);var p=this._buildGetters(o.root);var f=this._buildGetters(a.root);var m=!1;var g=o.expanded;var v=a.expanded;var _;var b;var w=0!==v.length;var y,k,x,C;var S,T,M,A;var E,I;var z=e.length;var P=0;if(o.root.length||a.root.length)for(m=!0,P=0;P<z;P++)for(b={dataItem:_=e[P],index:P},C=s[D]||{items:{},aggregates:{}},this._processColumns(u,g,p,l,b,C,h,!w),C.aggregates=this._calculateAggregate(u,b,C),s[D]=C,y=0;y<v.length;y++)k=v[y],this._matchDescriptors(_,k,f)?(T=k.names.slice(0,k.expandedIdx).join(""),M=x=k.names[k.expandedIdx],c[S=T+(x=x+"&"+(d=(d=f[x](_))!==t?d.toString():d))]={uniquePath:T+M,parentName:M,name:x,value:d},A=s[S]||{items:{},aggregates:{}},this._processColumns(u,g,p,l,b,A,h,!0),A.aggregates=this._calculateAggregate(u,b,A),s[S]=A):this._processColumns(u,g,p,l,b,{items:{},aggregates:{}},h,!0);return m&&z?(!(u.length>1)||n.columns&&n.columns.length||(o={root:[],expanded:[]}),E=this._asTuples(l,o,r?[]:u,n.sort?n.sort:[]),I=this._asTuples(c,a,r?u:[],n.sort?n.sort:[]),l=E.tuples,c=I.tuples,s=this._toDataArray(s,this._measuresInfo(u,r),I.keys,E.keys)):s=l=c=[],{axes:{columns:{tuples:l},rows:{tuples:c}},data:s}}});var 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})}});var he=l.extend({init:function(t){var n=((t||{}).schema||{}).cube;var 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:we(this.columns()),rows:we(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){var t=[];var n;var i=this.cubeSchema.dimensionsSettings();var r=function(e){return e[this.key]};var o=function(e){return e};for(var a=0;a<e.length;a++)n=e[a].name[0],t.push({key:n,displayValue:r.bind({key:n}),sortValue:o,caption:(i[n]||{}).caption||n});return t},_cubeSchema:function(e){return{dimensionsSettings:function(){return e.dimensions},dimensions:function(){var t=[];var 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=[];var 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);var i=this.options.data||this._pristineData||[];return i.length?typeof t(i[0]):null}.bind(this),members:function(t){var i=this.options.data||this._pristineData||[];var r=[];var o={};var a;var s;var 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(a=n.getter(Z(t),!0);l<i.length;l++)!(s=a(i[l]))&&0!==s&&!1!==s||o[s]||(o[s]=!0,r.push({caption:s+"",name:s+"",childrenCardinality:0,uniqueName:s}));return r}.bind(this)}},read:function(t){const n=this;const i=n.trigger("requestStart",{type:w});const r=n._params(t);const 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:w}),n.trigger(y),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;var 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=h(n.filter),n.filter=(n.filter||{}).filters),n.sort&&(n.sort=u(n.sort)),n},discover:function(t){const n=this;const i=n.transport;const r="odata"===n.options.type;const 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;var n=g({},{sort:t.sort(),measuresAxis:t.measuresAxis(),filter:t.filter()},e);return this._mergeState(n),this.read()}});var ue=l.extend({init:function(t){var n=((t||{}).schema||{}).cube;var i="columns";var r;var o={axes:f,cubes:f,catalogs:f,measures:f,dimensions:f,hierarchies:f,levels:f,members:f};n&&(o=e.extend(o,this._cubeSchema(n)),this.cubeBuilder=new ce(n)),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),r=this.options.measures||[],"[object Object]"===p.call(r)&&(i=r.axis||"columns",r=r.values||[]),this._measures=Q(r),this._measuresAxis=i,this._skipNormalize=0,this._axes={}},_cubeSchema:function(e){return{dimensions:function(){var t=[];var 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=[];var 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=i.levelUniqueName||i.memberUniqueName;var o=this.options.schema.data;var a=_(o)?o:n.getter(o,!0);var s=this.options.data&&a(this.options.data)||this._rawData||[];var l=[];var c;var d;var h=0;var u={};if(r&&(r=r.split(".")[0]),!i.treeOp)return l.push({caption:e.dimensions[r].caption||r,childrenCardinality:"1",dimensionUniqueName:r,hierarchyUniqueName:r,levelUniqueName:r,name:r,uniqueName:r}),l;for(c=n.getter(Z(r),!0);h<s.length;h++)!(d=c(s[h]))&&0!==d||u[d]||(u[d]=!0,l.push({caption:d,childrenCardinality:"0",dimensionUniqueName:r,hierarchyUniqueName:r,levelUniqueName:r,name:d,uniqueName:d}));return l}.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";var i="columns"===t?"rows":"columns";var r=X(e);var o=He(r[r.length-1]);this._lastExpanded=n,r=te(this.axes()[n],r,this.measures());for(var a=0;a<r.length;a++){if(He(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();var 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(y,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;var o,a,s,l;var c=this.columns();var d=this.rows();var h=t.columns&&t.columns.tuples;c.length||!d.length||!h||!this._rowMeasures().length&&this.measures().length||(t={columns:{},rows:t.columns}),c.length||d.length||"rows"!==this.measuresAxis()||!h||(t={columns:{},rows:t.columns}),this._axes={columns:we(this._axes.columns),rows:we(this._axes.rows)},t={columns:we(t.columns),rows:we(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;var l=e.length;var c=be(t,i);var 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;var l=e.length;var 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 u=this._mergeAxes(t,e,l);return this._axes=u.axes,u.data},_readData:function(e){var t=this.reader.axes(e);var n=this.reader.data(e);return this.cubeBuilder&&(this._rawData=n),this._processResult(n,t)},_createTuple:function(e,t,n){var i=e.members;var r=i.length;var o={members:[]};var a,s;var l,c;var d;var h;var u;var p;var f=0;for(t&&(r-=1);f<r;f++)p=i[f],s=Number(p.levelNum),l=p.name,c=p.parentName,u=p.caption||l,d=p.hasChildren,h=p.hierarchy,a=p.levelName,n&&(u="All",0===s?c=p.name:s-=1,d=!0,l=h=a=c),o.members.push({name:l,children:[],caption:u,levelName:a,levelNum:s.toString(),hasChildren:d,hierarchy:h,parentName:n?"":c});return t&&o.members.push({name:t.name,children:[]}),o},_hasRoot:function(e,t,n){if(t.length)return Ce(t,e).tuple;var i=e.members;var r;var o;var a=!0;var s;for(var l=0,c=i.length;l<c;l++)if(r=i[l],s=Number(r.levelNum)||0,o=n[l],!(0===s||o&&r.name===He(o))){a=!1;break}return a},_mergeAxes:function(e,t,n){var i=this._columnMeasures();var r=this._rowMeasures();var o=this.axes();var a,s;var l=be(o.rows.tuples,r);var c=e.rows.tuples.length;var d=be(o.columns.tuples,i);var h=e.columns.tuples.length;"columns"==n?(h=d,s=e.columns.tuples):t=function(e,t){if(!e||!e.length)return t;var n=[];var i=De(e);var r=i.length;var o=Math.max(t.length/r,1);var a,s,l,c;for(s=0;s<o;s++)for(l=r*s,a=0;a<r;a++)c=i[a]+l,n[l+a]=t[c]||{value:"",fmtValue:"",ordinal:c};return n}(s=Ae(e.columns.tuples,i),t);var u=ke(o.columns.tuples,s,i);"rows"==n?(c=be(e.rows.tuples,r),s=e.rows.tuples):t=function(e,t){if(!e||!e.length)return t;var n=[];var i=De(e);var r=i.length;var o=Math.max(t.length/r,1);var a,s,l,c;var d;for(a=0;a<r;a++)for(l=o*a,c=o*i[a],s=0;s<o;s++)d=parseInt(c+s,10),n[parseInt(l+s,10)]=t[d]||{value:"",fmtValue:"",ordinal:d};return n}(s=Ae(e.rows.tuples,r),t);var p=ke(o.rows.tuples,s,r);if(o.columns.tuples=u.tuples,o.rows.tuples=p.tuples,d!==be(o.columns.tuples,i)){a=u.index+ye(u.parsedRoot,u.memberIndex,i);var f=d+h;t=this._mergeColumnData(t,a,c,h,f)}else l!==be(o.rows.tuples,r)&&(a=p.index+ye(p.parsedRoot,p.memberIndex,r),t=this._mergeRowData(t,a,c,h));return 0===o.columns.tuples.length&&0===o.rows.tuples.length&&(t=[]),{axes:o,data:t}},_mergeColumnData:function(e,t,n,i,r){var o=this.data().toJSON();var a,s,l,c=0;var d=Math.max(this._columnMeasures().length,1);for(n=Math.max(n,1),o.length>0&&(c=d,r-=d),a=0;a<n;a++)s=t+a*r,(l=e.splice(0,i)).splice(0,c),[].splice.apply(o,[s,0].concat(l));return o},_mergeRowData:function(e,t,n,i){var r=this.data().toJSON();var o,a,s;var l=Math.max(this._rowMeasures().length,1);for(i=Math.max(i,1),r.length>0&&(n-=l,e.splice(0,i*l)),o=0;o<n;o++)s=e.splice(0,i),a=t*i+o*i,[].splice.apply(r,[a,0].concat(s));return r},_columnMeasures:function(){var e=this.measures();var t=[];return"columns"===this.measuresAxis()&&(0===this.columns().length||e.length>1)&&(t=e),t},_rowMeasures:function(){var e=this.measures();var 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=i.length||1;var o=0;var a=[];var s={};var l=0;var c,d,h;if(e.length){if(this._skipNormalize<=0&&!this._hasRoot(e[0],t,n)){for(this._skipNormalize=0;o<r;o++)a.push(this._createTuple(e[0],i[o],!0)),s[o]=o;e.splice.apply(e,[0,e.length].concat(a).concat(e)),o=r}if(i.length)for(h=c=e[o],d=c.members.length-1;c;){if(l>=r&&(l=0),c.members[d].name!==i[l].name&&(e.splice(o,0,this._createTuple(c,i[l])),s[o]=o),l+=1,c=e[o+=1],r>l&&(!c||lt(h,d-1)!==lt(c,d-1))){for(;l<r;l++)e.splice(o,0,this._createTuple(h,i[l])),s[o]=o,o+=1;c=e[o]}h=c}return s}},_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=e.data;var n=0;var i;var r=[];var o;var 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,a=e.length,t.length===a)return t;for(;r.length<a;)(i=t[n++])&&(o=i.ordinal),r=this._normalizeOrdinals(this._addMissingDataItems(r,e),i,e),e.lastOrdinal=o;return r},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;var 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){var t=[];for(var 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;var n=e.slice();var i=n.shift();var r=1;for(;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 we(e){return e||(e={tuples:[]}),e.tuples||(e.tuples=[]),e}function ye(e,t,n){if(!e)return 0;var i=Math.max(n.length,1);var r=e.members.slice(0,t);var o=r.shift();var a=i;for(;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;var o=t[0].members;var 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=!0;var i,r;for(e=e.members,t=t.members,i=0,r=e.length;i<r;i++)e[i].measure||t[i].measure||(n=n&&He(e[i])===He(t[i]));return n}function Ce(e,t){var n,i,r,o,a=0;var s,l,c;for(n=0,i=e.length;n<i;n++){if(xe(r=e[n],t))return{tuple:r,index:a};for(a++,s=0,l=r.members.length;s<l;s++)if(!(c=r.members[s]).measure&&(a+=(o=Ce(c.children,t)).index,o.tuple))return{tuple:o.tuple,index:a}}return{index:a}}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=e.members;var i,r,o,a="";var s="";var l;for(i=0,r=n.length;i<r;i++){if(o=n[i],l){if(t[a+o.name]){l=t[a+=o.name];continue}return t[a+o.parentName]?t[a+o.parentName]:t[s+o.parentName]?t[s+o.parentName]:t[s]}if(a+=o.name,!(l=t[o.parentName])&&!(l=t[a]))return null;l&&(s+=l.name)}return l}function Me(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[];var n=[];var i={};var r=function(e,t){if(0===t.length)return-1;var n=t[0];var i=e.members;for(var r=0,o=i.length;r<o;r++)if(i[r].name==n.name)return r}(e[0],t);for(var o=0;o<e.length;o++){var a=e[o];a.dataIndex=o,Me(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 De(e){var n=[];var i=(e=e.slice()).shift();var r,o,a,s,l;for(;i;){for(i.dataIndex!==t&&n.push(i.dataIndex),a=0,r=0,o=i.members.length;r<o;r++)s=(l=i.members[r]).children,l.measure?[].splice.apply(e,[0,0].concat(s)):[].splice.apply(e,[a,0].concat(s)),a+=s.length;i=e.shift()}return n}function Ee(e){var t=e.split(".");return t.length>2?t[0]+"."+t[1]:e}function Ie(e,t){var n=e.length-1;var i=e[n];var r;return 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),r&&r.dir?i="ORDER("+i+".Children,"+r.field+".CurrentMember.MEMBER_CAPTION,"+r.dir+")":i+=".Children",e[n]=i,e}function ze(e){var t="CROSSJOIN({";var n;return e.length>2?(n=e.pop(),t+=ze(e)):(t+=e.shift(),n=e.pop()),t+="},{",t+=n,t+="})"}function Pe(e,t){var n=e.slice(0);return t.length>1&&n.push("{"+Le(t).join(",")+"}"),ze(n)}function Le(e){var n=0;var i=e.length;var r=[];var o;for(;n<i;n++)o=e[n],r.push(o.name!==t?o.name:o);return r}function Be(e,t){var n,i,r=-1;for(n=0,i=t.length;n<i;n++)if(He(t[n])===e){r=n;break}return r}function He(e){return e=e.name||e,"[object Array]"===p.call(e)&&(e=e[e.length-1]),e}function Re(e){var t=e.length;var n=[];var i=0;for(;i<t;i++)n.push(e[i].name[0]);return n}function Fe(e,t){var n;var i;var r;var o=0;var a=e.length;var 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){var t=[];var n=[];var i=[];var r;var o,a;var s=0;var l=e.length;var c;var d;var h;for(;s<l;s++)if(c=(r=e[s]).name,h=!1,"[object Array]"!==p.call(c)&&(r.name=c=[c]),c.length>1)n.push(r);else{for(d=Ee(c[0]),o=0,a=i.length;o<a;o++)if(0===i[o].name[0].indexOf(d)){h=!0;break}h||i.push(r),r.expand&&t.push(r)}return{root:i,expanded:t=t.concat(n)}}function Ve(e,t,n){var i="";var r=Oe(e=e||[]);var o=Re(r.root);var a=[];var s=(r=r.expanded).length;var l=0;var c;var d=[];if(o.length>1||t.length>1){for(a.push(Pe(o,t));l<s;l++)d=Fe(c=Ie(r[l].name,n),o).names,a.push(Pe(d,t));i+=a.join(",")}else{for(;l<s;l++)c=Ie(r[l].name,n),d.push(c[0]);i+=o.concat(d).join(",")}return i}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)},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)};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="";var i=e.value;var r=e.field;var 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"};var 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||[];var i=e.rows||[];var r=e.measures||[];var o="rows"===e.measuresAxis;var 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+=Le(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+=Le(r).join(","),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON ROWS"),e.filter?(t+=" FROM ",t+="(",t+=function(e,t){var n,i="";var r=e.filters;var o=r.length;var a;for(a=o-1;a>=0;a--)n="SELECT (",n+=$e(r[a]),n+=") ON 0",i=a==o-1?n+=" FROM ["+t+"]":n+" FROM ( "+i+" )";return i}(e.filter,e.connection.cube),t+=")"):t+=" FROM ["+e.connection.cube+"]",1==r.length&&n.length&&(t+=" WHERE ("+Le(r).join(",")+")"),(t+="</Statement></Command><Properties><PropertyList><Catalog>"+e.connection.catalog+"</Catalog><Format>Multidimensional</Format></PropertyList></Properties></Execute></Body></Envelope>").replace(/\&/g,"&")},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>"}};var 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"))}});var 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;var o=r.setup(t.data,w);n=t.success||e.noop,i=t.error||e.noop,t.parameterMap&&(o=r.parameterMap(o,w));const a="object"==typeof r.options.read&&r.options.read.url?r.options.read:{url:r.options.read};Lb(a,o).then(tw).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 Bb({url:this.options.read},e)}});function Ke(e){return null==e?[]:"[object Array]"!==p.call(e)?[e]:e}function Ye(e){var t={tuples:[]};var i=Ke(n.getter("Tuples.Tuple",!0)(e));var r=n.getter("Caption['#text']");var o=n.getter("UName['#text']");var a=n.getter("LName['#text']");var s=n.getter("LNum['#text']");var l=n.getter("CHILDREN_CARDINALITY['#text']",!0);var c=n.getter("['@Hierarchy']");var d=n.getter("PARENT_UNIQUE_NAME['#text']",!0);for(var h=0;h<i.length;h++){var u=[];var p=Ke(i[h].Member);for(var f=0;f<p.length;f++)u.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:u})}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)}};var Xe=["axes","catalogs","cubes","dimensions","hierarchies","levels","measures"];var Ze=n.data.XmlDataReader.extend({init:function(e){n.data.XmlDataReader.call(this,e),this._extend(e)},_extend:function(e){var t=0;var n=Xe.length;var i;var r;for(;t<n;t++)(r=e[i=Xe[t]])&&r!==f&&(this[i]=r)},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);var t=Ke(n.getter("Axes.Axis",!0)(e));var i;var r={columns:{},rows:{}};for(var o=0;o<t.length;o++)"sliceraxis"!==(i=t[o])["@name"].toLowerCase()&&(r.columns.tuples?r.rows=Ye(i):r.columns=Ye(i));return r},data:function(e){e=n.getter('ExecuteResponse["return"].root',!0)(e);var t=Ke(n.getter("CellData.Cell",!0)(e));var i=[];var r=n.getter("['@CellOrdinal']");var o=n.getter("Value['#text']");var a=n.getter("FmtValue['#text']");for(var 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);var i=Ke(n.getter("row",!0)(e));var r=[];for(var 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:ue,PivotDataSourceV2:he,XmlaTransport:qe,XmlaDataReader:Ze,PivotCubeBuilder:ce,transports:{xmla:qe},readers:{xmla:Ze}});var Je=function(e,t){var n=[];for(var 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(y,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)");var r=i.closest(".k-chip-action");var 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(y,this._refreshHandler),this.dataSource=this.options.dataSource=e,this.fieldMenu&&this.fieldMenu.setDataSource(e),e.first(y,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]();var i=e.defaultHierarchy||e.uniqueName;return!(Be(i,n)>-1)&&!(Be(i,n=this.dataSource["columns"===this.options.setting?"rows":"columns"]())>-1)},add:function(e){let t=this.dataSource[this.options.setting]();let n=0;let i=(e=Array.isArray(e)?e.slice(0):[e]).length;for(;n<i;)-1!==Be(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]();var i=Be(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]();var n=Be(e,t);var i=this.dataSource.sort();var 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;var n=(!0===t||t.allowUnsort)&&"asc"===e.dir;var i=this.dataSource.sort()||[];var r=Je(i,e.field);n&&i.length!==r.length&&(e=null),e&&r.push(e),this.dataSource.sort(r)},refresh:function(){var e="";var n=this.dataSource[this.options.setting]();var i=n.length;var r=0;var o;if(i)for(;r<i;r++)o=(o=n[r]).name===t?{name:o}:o,e+=this.template(g({sortIcon:this._sortIcon(o.name)},o));else e=this.emptyTemplate(this.options.messages.empty);this.element.html(e)},destroy:function(){s.fn.destroy.call(this),this.dataSource.unbind(y,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(),He(e));var 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(y,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");var 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(y,this._refreshHandler),this.dataSource=this.options.dataSource=e,this.fieldMenu&&this.fieldMenu.setDataSource(e),e.first(y,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();let n=0;let i=(e=Array.isArray(e)?e.slice(0):[e]).length;for(;n<i;)-1!==Be(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();var i=Be(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();var n=Be(e,t);var i=this.dataSource.sort();var 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;var i="";var 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(y,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=n.attr("role");var i=this.element.closest("["+t+"=pivotcontainer]").find("["+t+"=pivotgridv2]");var r;e("#"+this.options.configurator).toggleClass("k-hidden"),i.length&&((r=i.getKendoPivotGridV2())._setContentWidth(),r._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")))}});var 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=this.options;var t;switch(this.element.removeClass("k-flex-row k-flex-row-reverse k-flex-column k-flex-column-reverse"),e.configuratorPosition){case"right":default:t="k-flex-row";break;case"left":t="k-flex-row-reverse";break;case"bottom":t="k-flex-column";break;case"top":t="k-flex-column-reverse"}this.element.addClass("k-d-flex k-pos-relative").addClass(t)}});var 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);var i=t.parent().attr(n.attr("key"));var o=t.is(".k-i-chevron-up,.k-svg-i-chevron-up");var a=0!==t.closest(".k-pivotgrid-row-headers").length;var s=i.split(",");var l=o?L: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()};var d=a?r.dataSource._rows:r.dataSource._columns;var h=sw(d,c);r.dataSource._preventRefresh=!0,r._columnBuilder._exportData={},r._rowBuilder._exportData={},a?r.dataSource.rows(h):r.dataSource.columns(h)}})),r.options.autoBind&&r.dataSource.fetch(),r._aria(),r.options.navigatable&&r._initPivotGridNavigation(),r._initLoader(),n.notify(r)},events:[E,I,z,L],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=o_.bind(n)},_initPivotGridNavigation:function(){var e=this;e.navigation=new oy({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");const i=n[0]?Array.from(n[0].children).reduce(((e,t)=>e+(null!==t.getAttribute("colspan")?+t.getAttribute("colspan"):1)),0):[];const r=e.querySelectorAll(".k-pivotgrid-column-headers tr");const o=e.querySelectorAll(".k-pivotgrid-column-headers th");const a=e.querySelectorAll(".k-pivotgrid-values td");const s=e.querySelector(".k-pivotgrid-empty-cell");s.setAttribute("aria-rowspan",r.length.toString()),s.setAttribute("aria-colspan",i.toString());const l=r[0];const 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("-");const i=+n[n.length-1];const r=t.filterAndMap(Array.from(o),(e=>{const t=e.getAttribute("id").split("-");const n=+t[t.length-1];const 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;var t=e.options.dataSource;t=Array.isArray(t)?{data:t}:t,e.dataSource&&this._refreshHandler?e.dataSource.unbind(y,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(y,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=0;var t;return document&&document.createElement&&((t=document.createElement("div")).style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",t.innerHTML=" ",document.body.appendChild(t),e=t.offsetWidth-t.scrollWidth,document.body.removeChild(t)),e}()))},_scrollable:function(){var t=this;var i=t._columnHeadersWrapper;var 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);var 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");var t=this._columnHeadersWrapper.children("table");var 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=this._contentBuilder;var i;var r;return e>=n.columnsCount||e<0||t>=n.rowsCount||t<0?null:(i=t*n.columnsCount+e,{columnTuple:(r=n.hash[i<0?0:i]).columnTuple,rowTuple:r.rowTuple,dataItem:r.data})},refresh:function(){var e=this;var t=e.dataSource;if(!e.trigger(E,{action:"rebind"})){var i=n._activeElement()?n._activeElement().id:null;var 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=this;var a;var l;s.fn.init.call(o,i,r),R=n.support.isRtl(o.element)?"caret-alt-left":"caret-alt-right",o._dataSource(),o._bindConfigurator(),o._wrapper(),o._createLayout(),o._columnBuilder=a=new ht,o._rowBuilder=l=new ut,o._contentBuilder=new pt,o._templates(),o.columnsHeader.add(o.rowsHeader).on("click","span.k-icon,span.k-svg-icon",(function(){var i=e(this);var r=a;var s="expandColumn";var c;var d=i.attr(n.attr("path"));var h={axis:"columns",path:JSON.parse(d)};i.parent().is("td")&&(r=l,s="expandRow",h.axis="rows");var u=i.is(H);var p=r.metadata[d];var f=p.expanded===t;c=u?L:z,h.childrenLoaded=p.maxChildren>p.children,o.trigger(c,h)||(r.metadata[d].expanded=!u,n.ui.icon(i,{icon:u?R:B}),!u&&f?o.dataSource[s](h.path):o.refresh())})),o._scrollable(),o.options.autoBind&&o.dataSource.fetch(),n.notify(o)},events:[E,I,z,L],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;var t=this.options.rowHeaderTemplate;var i=this.options.dataCellTemplate;var r=this.options.kpiStatusTemplate;var o=this.options.kpiTrendTemplate;this._columnBuilder.template=n.template(e||F,{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||F,{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=this._contentBuilder;var i=n.columnIndexes[e||0];var r=n.rowIndexes[t||0];var o;return i&&r?(o=r.index*n.rowLength+i.index,{columnTuple:i.tuple,rowTuple:r.tuple,measure:i.measure||r.measure,dataItem:this.dataSource.view()[o]}):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;var t=e.options.dataSource;t=Array.isArray(t)?{data:t}:t,e.dataSource&&this._refreshHandler?e.dataSource.unbind(y,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(y,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(M).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;var 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>');var r=i.find(".k-pivot-rowheaders");var o=i.find(".k-pivot-table");var a=e(M).addClass("k-grid");t._measureFields(),t.columnFields=e(M).addClass("k-pivot-toolbar k-toolbar k-toolbar-md k-settings-columns"),t.rowFields=e(M).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=this.rowsHeader;var t=e.parent(".k-pivot-rowheaders").width(T);var n;n=Math.max(c(this.measureFields),c(this.rowFields)),n=Math.max(e.children("table").width(),n),t.width(n)},_setSectionsHeight:function(){var e=this.measureFields.height(T).height();var t=this.columnFields.height(T).height();var n=this.rowFields.height(T).innerHeight();var i=this.columnsHeader.height(T).innerHeight();var r=n-this.rowFields.height();var o=t>e?t:e;var 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");var t=this.columnsHeader.children("table");var n=e.children("colgroup").children().length*this.options.columnWidth;var 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;var t=e.content;var i=e.rowsHeader;var r=e.wrapper.innerHeight();var o=n.support.scrollbar();var a=t[0].offsetHeight===t[0].clientHeight;var 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;var 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=[];var n=this.dataSource;var i=n.measures();var 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=this;var t=e.dataSource;var i=t.axes();var r=(i.columns||{}).tuples||[];var o=(i.rows||{}).tuples||[];var a=e._columnBuilder;var s=e._rowBuilder;var l;var c;if(!e.trigger(E,{action:"rebind"})){if(a.measures=e._axisMeasures("columns"),s.measures=e._axisMeasures("rows"),e.columnsHeaderTree.render(a.build(r)),e.rowsHeaderTree.render(s.build(o)),l={indexes:a._indexes,measures:a.measures,metadata:a.metadata},c={indexes:s._indexes,measures:s.measures,metadata:s.metadata},e.contentTree.render(e._contentBuilder.build(t.view(),l,c)),e._resize(),e.touchScroller)e.touchScroller.contentResized();else{var d=n.touchScroller(e.content);d&&d.movable&&(e.touchScroller=d,d.movable.bind("change",(function(t){n.scrollLeft(e.columnsHeader,-t.sender.x),e.rowsHeader.scrollTop(-t.sender.y)})))}e._progress(!1),e.trigger(I)}},_scrollable:function(){var e=this;var t=e.columnsHeader;var 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);var 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))}}});var rt=n.dom.element;var ot=n.dom.html;var at=function(e,t){return{maxChildren:0,children:0,maxMembers:0,members:0,measures:1,levelNum:e,parentMember:0!==t}};var st=function(e,t){var n=[];var i=0;for(;i<=t;i++)n.push(e.members[i].name);return n};var lt=function(e,t){var n="";var i=0;for(;i<=t;i++)n+=e.members[i].name;return n};var 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){var t="";for(var n=0;n<e;n++)t+="<col>";this.table.find("colgroup").append(t)},addRowElements:function(t){var n=this.table.find("tbody");var i;for(var r=0;r<t.length;r++)i=e("<tr class=\"k-pivotgrid-row\" role='presentation'></tr>"),n.append(i),this.addColumCell(i,t[r],r);this.rowsCount=t.length},_getTemplate:function(e,t){let n;const i=e.columnTuple.members;const r=i[i.length-1];const o=this.measures&&this.measures.find((e=>e.name===r.name));const 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=Ub((this.data||[]).slice(),this.columnHeaderLeafs,this.rowHeaderLeafs,this.columnHeaderBreadth,this.rowHeaderDepth);var n=this;var 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}});var 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){var t="";for(var n=0;n<e;n++)t+="<col>";this.table.find("colgroup").append(t)},addRowElements:function(t){var n=this.table.find("tbody");var i;for(var r=0;r<t.length;r++)i=e('<tr class="k-pivotgrid-row" role="row"></tr>'),n.append(i),this.addColumCell(i,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){var o=this;var a;var s;for(var l=0;l<i.cells.length;l++)if(s=i.cells[l]){this._getExportData(r,s,t);const i=s.children&&s.children.length>0;a=e(o.headerTemplate({id:`${o.ariaId}-${"columns"==o.axes?"ch":"rh"}-${r+1}-${l+1}`,rowspan:s.rowSpan,colspan:s.colSpan,key:s.path.join(",")+(s.total?"|[TOTAL]":""),iconClass:s.children&&s.children.length?"up":"down",expandable:s.hasChildren&&!s.total,expanded:i?"true":"false",headerClass:n.format("k-pivotgrid-cell{0}{1}",s.total?" k-pivotgrid-header-total":"",0===s.levelNum?" k-pivotgrid-header-root":""),role:"columns"==o.axes?"columnheader":"rowheader"})),i&&a.addClass("k-pivotgrid-expanded");const c=`<span class="k-pivotgrid-header-title">${s.caption}</span>`;a.append(o.template?o.template({member:s}):c),t.append(a)}},build:function(){var t=$b((this.tuples||[]).slice());var n="columns"==this.axes?Wb(t):jb(t);var i=n[0];var r=n[1];var o=n[2];var a=n[3];var 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}});var ht=o.extend({init:function(){this.measures=1,this.metadata={}},build:function(e){var t=this._tbody(e);var n=this._colGroup();return[rt("table",{className:j},[n,t])]},reset:function(){this.metadata={}},_colGroup:function(){var e=this._rowLength();var t=[];var n=0;for(;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(" ")])])),rt("tbody",{className:K},this.rows)},_normalize:function(){var e=this.rows;var t=e.length;var n=0;var i;var r;var o;var a;var s;for(;n<t;n++)if(1!==(i=e[n]).rowSpan)for(o=0,r=(a=i.children).length;o<r;o++)(s=a[o]).tupleAll&&(s.attr.rowSpan=i.rowSpan)},_rowIndex:function(e){var t=this.rows;var n=t.length;var i=0;for(;i<n&&t[i]!==e;i++);return i},_rowLength:function(){var e=this.rows[0]?this.rows[0].children:[];var t=e.length;var n=0;var 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=this.rootTuple.members[t].name;var r=e.members[t].levelNum;var o=i+r;var a=this.map;var s;var l;var c=a[o];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,a[o]=c,(s=a[i+(Number(r)-1)])&&((l=s.children)[1]&&-1===l[1].attr.className.indexOf("k-alt")?c.notFirst=!0:c.notFirst=s.notFirst),this.rows.splice(this._rowIndex(s)+1,0,c)),c},_measures:function(e,t,n){var i=this.map;var r=i.measureRow;var o;r||(r=rt("tr",{className:U},[]),i.measureRow=r,this.rows.push(r));for(var a=0,s=e.length;a<s;a++)o=e[a],r.children.push(this._cell(n||"",[this._content(o,t)],o));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=t.members;var a=o[i];var s=o[i+1];var l,c,d,h;var u,p;var f=[];var m;var g=0;var v;var _;var b=0;var w=0;if(!a.measure){if(m=n.stringify(st(t,i)),l=this._row(t,i,r),h=(d=a.children).length,(v=this.metadata[m])||(this.metadata[m]=v=at(Number(a.levelNum),i),v.rootLevelNum=Number(this.rootTuple.members[i].levelNum)),this._indexes.push({path:m,tuple:t}),a.hasChildren){!1===v.expanded&&(b=v.maxChildren,l.collapsed+=b,v.children=0,h=0);let t=e("<span></span>");t.attr(n.attr("path"),m),f.push(n.dom.html(n.ui.icon(t,{icon:h?B:R}),!0))}if(f.push(this._content(a,t)),u=this._cell(l.notFirst?" k-first":"",f,a),l.children.push(u),l.colSpan+=1,h){for(p=this._cell(" k-alt",[this._content(a,t)],a),l.children.push(p);g<h;g++)c=this._buildRows(d[g],i,a);_=c.colSpan,b=c.collapsed,u.attr.colSpan=_,v.children=_,v.members=1,l.colSpan+=_,l.collapsed+=b,l.rowSpan=c.rowSpan+1,s&&(s.measure?_=this._measures(s.children,t," k-alt"):(_=(c=this._buildRows(t,i+1)).colSpan,l.collapsed+=c.collapsed,w=c.collapsed),p.attr.colSpan=_,_-=1,v.members+=_,l.colSpan+=_)}else s&&(s.measure?_=this._measures(s.children,t):(_=(c=this._buildRows(t,i+1)).colSpan,l.collapsed+=c.collapsed,w=c.collapsed),v.members=_,_>1&&(u.attr.colSpan=_,l.colSpan+=_-1));return v.maxMembers<v.members+w&&(v.maxMembers=v.members+w),d=v.children+b,v.maxChildren<d&&(v.maxChildren=d),(p||u).tupleAll=!0,l}this._measures(a.children,t)}});var ut=o.extend({init:function(){this.metadata={}},build:function(e){var t=this._tbody(e);var n=this._colGroup();return[rt("table",{className:q},[n,t])]},reset:function(){this.metadata={}},_rowLength:function(){var e=this.rows[0].children;var t=0;var n=0;var i=e[n];for(;i;)t+=i.attr.colSpan||1,i=e[++n];return t},_colGroup:function(){var e=this._rowLength();var t=[];var n=0;for(;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(" ")])])),rt("tbody",{className:K},this.rows)},_normalize:function(){var e=this.rows;var t=e.length;var n=0;var i=this.rootTuple.members;var r=i[0].name;var o=i.length;var a=0;var s;var l;var c;var d=this.map;var h;for(;n<t;n++)for(s=e[n],a=0;a<o;a++)c=this[i[a].name],(l=s.colSpan["dim"+a])&&l.colSpan<c&&(l.attr.colSpan=c-l.colSpan+1);s=d[r],h=d[r+"all"],s&&(s.children[0].attr.className=Y+" k-first"),h&&(h.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=this.map;var o;var a=t.members;var s=a[i];var l=a[i+1];var c=s.children;var d=c.length;var h=Number(s.levelNum);var u=this.rootTuple.members[i].name;var p=st(t,i-1).join("");var f=Number(this.rootTuple.members[i].levelNum);var m=p+(f===h?"":s.parentName||"");var g=r[m+"all"]||r[m];var v=h+1;var _,b;var w,y;var k;var x;var C=[];var S;if(!g||g.hasChild?g=this._row():g.hasChild=!0,s.measure){for(x=g.allCell?"k-grid-footer":"",g.children.push(this._cell(x,[this._content(c[0],t)],c[0])),g.rowSpan=d,S=1;S<d;S++)this._row([this._cell(x,[this._content(c[S],t)],c[S])]);return g}if(r[p+s.name]=g,o=n.stringify(st(t,i)),(k=this.metadata[o])||(this.metadata[o]=k=at(h,i),k.rootLevelNum=f),this._indexes.push({path:o,tuple:t}),s.hasChildren){!1===k.expanded&&(d=0,k.children=0);let t=e("<span></span>");t.attr(n.attr("path"),o),C.push(n.dom.html(n.ui.icon(t,{icon:d?B:R}),!0))}if(C.push(this._content(s,t)),x=g.allCell&&!d?"k-grid-footer":"",(_=this._cell(x,C,s)).colSpan=v,g.children.push(_),g.colSpan["dim"+i]=_,(!this[u]||this[u]<v)&&(this[u]=v),d){for(g.allCell=!1,g.hasChild=!1,S=0;S<d;S++)g!==(w=this._buildRows(c[S],i))&&(g.rowSpan+=w.rowSpan);g.rowSpan>1&&(_.attr.rowSpan=g.rowSpan),k.children=g.rowSpan,(b=this._cell("k-grid-footer",[this._content(s,t)],s)).colSpan=v,(y=this._row([b])).colSpan["dim"+i]=b,y.allCell=!0,r[p+s.name+"all"]=y,l&&(w=this._buildRows(t,i+1),b.attr.rowSpan=w.rowSpan),g.rowSpan+=y.rowSpan,k.members=y.rowSpan}else l&&(g.hasChild=!1,this._buildRows(t,i+1),(b||_).attr.rowSpan=g.rowSpan,k.members=g.rowSpan);return k.maxChildren<k.children&&(k.maxChildren=k.children),k.maxMembers<k.members&&(k.maxMembers=k.members),g}});var pt=o.extend({init:function(){this.columnAxis={},this.rowAxis={}},build:function(e,n,i){var r=n.indexes[0];var 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();var s=this._colGroup();return[rt("table",{className:G},[s,a])]},_colGroup:function(){var e=this.columnAxis.measures.length||1;var t=[];var 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(" ")])])),rt("tbody",{className:K},this.rows)},_indexes:function(e,n){var i=[];var r;var o=e.indexes;var a=e.metadata;var s=e.measures;var l=s.length||1;var c;var d=0;var h=0;var u=0;var p=o.length;var f;var m;var g;if(!p){for(f=0;f<l;f++)i[f]={index:f,measure:s[f],tuple:null};return i}for(;u<p;u++){if(g=0,(m=(c=a[(r=o[u]).path]).children+c.members)&&(m-=l),!1===c.expanded&&c.children!==c.maxChildren&&(g=c.maxChildren),c.parentMember&&c.levelNum===c.rootLevelNum&&(m=-1),m>-1){for(f=0;f<l;f++)c.children||h,i[m+h+f]={children:m,index:d,measure:s[f],tuple:r.tuple},d+=1;for(;i[h]!==t;)h+=1}if(h===n)break;d+=g}return i},_buildRows:function(){var e=this.rowIndexes;var t=e.length;var n=0;for(;n<t;n++){var i=e[n];i&&this.rows.push(this._buildRow(i))}},_buildRow:function(e){var n=e.index*this.rowLength;var i=this.columnIndexes;var r=i.length;var o;var a=[];var s=0;var l;var c,d;var h,u,p;for(;s<r;s++)(o=i[s])!==t&&(h={className:Y},o.children&&(h.className+=" k-alt"),d="",u=this.data[n+o.index],p=o.measure||e.measure,l={columnTuple:o.tuple,rowTuple:e.tuple,measure:p,dataItem:u},""!==u.value&&p&&p.type&&("status"===p.type?d=this.kpiStatusTemplate(l):"trend"===p.type&&(d=this.kpiTrendTemplate(l))),d||(d=this.dataTemplate(l)),(c=rt("td",h,[ot(d)])).value=u.value,a.push(c));return h={className:U},e.children&&(h.className+=" k-grid-footer"),rt("tr",h,a)}});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=this.widget.columnsHeaderTree.children[0];var t=this.widget.rowsHeaderTree.children[0];var n=e.children[0].children.length;var i=t.children[0].children.length;var r=this.widget.options.columnWidth;var o=[];var a;if(i&&this.dataSource.data()[0])for(a=0;a<i;a++)o.push({autoWidth:!0});for(a=0;a<n;a++)o.push({autoWidth:!1,width:r});return o},_cells:function(e,t,n){var i=[];var r=0;var o=e.length;var a;var s,l;var c,d;for(;r<o;r++){for(s=[],a=(l=e[r].children).length,c=0;c<a;c++)d=l[c],s.push({background:"#7a7a7a",color:"#fff",value:d.value,colSpan:d.attr.colSpan||1,rowSpan:d.attr.rowSpan||1});n&&n(s,r),i.push({cells:s,type:t})}return i},_rows:function(){var e=this.widget.columnsHeaderTree.children[0];var t=this.widget.rowsHeaderTree.children[0];var n=e.children[0].children.length;var i=t.children[0].children.length;var r=e.children[1].children;var o=t.children[1].children;var a=this.widget.contentTree.children[0].children[1].children;var 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){var i=0;var r,o;var s=a[t].children;for(;i<n;i++)r=s[i],o=Number(r.value),isNaN(o)&&(o=r.value),e.push({background:"#dfdfdf",color:"#333",value:o,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];const t=this.widget._rowBuilder.table[0];const n=e.children[0].children.length;const i=t.children[0].children.length;const r=this.widget.options.columnWidth;const 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=[];const r=Object.keys(e).length;for(let o=0;o<r;o++){const r=[];const a=e[o].children;const 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];const t=this.widget._rowBuilder.table[0];const n=e.children[0].children.length;const i=t.children[0].children.length;const r=this.widget._columnBuilder._exportData;const o=this.widget._rowBuilder._exportData;const a=this.widget._contentBuilder.hash;const 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];const 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];const 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||{};var 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:Yb,addMultipleMeasures:Bw,averageAggregate:vw,buildKPIMeasures:Kb,cloneDataTree:Tw,compareAxes:Xb,configuratorReducer:cw,createAxisDescriptors:nw,createDataState:tw,createDataTree:Sw,createDiscoverBody:Ib,createFlatSchemaDimensions:Rw,createLocalDataState:Hw,createRequestBody:yb,createTuples:zw,discoverCommands:Eb,fetchData:Lb,fetchDiscover:Bb,headersReducer:sw,maxAggregate:gw,mergeTrees:xw,minAggregate:mw,parseResponse:Ab,readData:Dw,rootFields:Iw,setFilter:rw,setSort:iw,sumAggregate:pw,toColumns:Wb,toData:Ub,toRows:jb,toTree:$b}}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo;var n=t.ui;var i=t.keys;var r=t.htmlEncode;var o="kendoContextMenu";var a=".kendoPivotFieldMenu";var s=".kendoPivotFieldMenuKeyboard";var l="kendoPivotSettingTargetV2";var c=n.Widget;var d=".";var h="k-column-fields";var u="k-filter-item";var p="aria-label",f="kendoExpansionPanel";var 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;var i=n.options;var 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+h).eq(0).data(l),this.measuresSettingTarget=this.element.parent().find(d+h).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;var 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=r.keyCode;var a=n.menu;var s=".k-columnmenu-item:visible,.k-treeview:visible,button.k-button:visible,.k-picker:visible,.k-input input.k-input-inner:visible";var l=n.menu.element.find(s);var c=t._activeElement()==n.menu.element[0];var d=e(t._activeElement()).parents(".k-pivotgrid-column-menu")[0]==n.menu.element[0]?e(t._activeElement()).closest(s):n.menu.element.find(".k-focus:not(.k-expander):not(.k-treeview-item)").last();var h;o==i.TAB?(h=r.shiftKey?l.eq(d[0]?(l.index(d)+l.length-1)%l.length:0):l.eq(d[0]?(l.index(d)+1)%l.length:0),a.element.find(".k-focus").removeClass("k-focus"),h.is(".k-item")?(c||a.element.trigger("focus"),a.element.find(".k-focus").removeClass("k-focus"),a._moveFocus(d,h)):h.trigger("focus"),r.preventDefault(),r.stopImmediatePropagation()):o==i.ENTER&&(d.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=n.treeView.dataSource.get(t.data.uniqueName);var r=t.data.uniqueName;var o=[];var a;var s;var l;var c;var d;n.dataSource.cubeSchema?(o=r?n.dataSource.cubeSchema.members(n.currentMember):n.dataSource.cubeSchema.members(n.currentMember+".[(ALL)]"),a=n.dataSource.filter(),n._getFilterStorage(n.currentMember)&&1==w({filter:a,member:n.currentMember}).length&&!r?o[0].checked=!0:function(t,n,i){var r,o=0,a=i.length;var s=w({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,o),t.success(o)):(c={catalogName:s=n.dataSource.transport.catalog(),cubeName:l=n.dataSource.transport.cube()},d={command:"schemaMembers"},r?(c.memberUniqueName=i.uniqueName.replace(/\&/g,"&"),c.treeOp=1):c.levelUniqueName=n.currentMember+".[(ALL)]",d.connection={catalog:s,cube:l},d.restrictions=c,n.dataSource.discover(d).then((function(e){i&&!i.checked||y(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=this.treeView.dataSource.view();var n=this.dataSource.filter();var i;i=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}(t,n,this.currentMember):function(e,t,n){var i=[];var r;var o=e[0].checked;var a=w({filter:t,member:n,operator:"in"})[0];k(e,i,!0),a&&(o?(t.filters.splice(t.filters.indexOf(a),1),t.filters.length||(t={})):a.value=i.join(","),r=t);i.length&&(r||o||(r={field:n,operator:"in",value:i.join(",")},t&&(t.filters.push(r),r=t)));return r||null}(t,n,this.currentMember),this._includesCache={},i&&(this.dataSource._preventRefresh=!0,this.dataSource.filter(i),this.menu.close())},_resetIncludes:function(t){t.preventDefault();var n=this;var i;for(var r in n._includesCache)(i=e(n._includesCache[r]).find(".k-checkbox")).prop("checked",!i.prop("checked")),n.treeView._checkboxChange({target:i}),delete n._includesCache[r]},_initFilterForm:function(){var e=this.menu.element.find(".kendo-grid-filter-menu-container");var 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();var t=this.options.messages.operators[e];this._filterForm.find("select").attr(p,t)},_filter:function(e){var t=this;var n=v(t._filterValue.val(),t.dataSource,t.currentMember);var 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;var 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;var 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;var n="";var 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;var 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=this;var i=n.dataSource.cubeSchema;var r;var o=e(t.event.target).closest(".k-chip");n.currentMember=o.text(),n.currentMemberIndex=o.index(),n.currentSettingTarget=o.closest(".k-chip-list").data(l),n.menu.popup._hovered=!0,n._getSettingTargets(),n._updateDisabledState(),n.options.filterable&&(n._setFilterForm(n._getFilterStorage(n.currentMember)),r=n.wrapper.find(".k-columnmenu-item-wrapper").last(),i&&"string"!==i.memberType(n.currentMember).toLowerCase()?r.hide():r.show(),n.currentMember!==n._oldCurrentmember&&(n._oldCurrentmember&&n._collapseItems(n.menu.element.find(".k-item.k-expander")),n._oldCurrentmember=n.currentMember,n._includesCache={},this.treeView.dataSource.read()))}}});var 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("."+u);var 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;var n="";var 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=this.dataSource.filter()||{};var n;var i=0;var r;for(t.filters=t.filters||[],r=(n=w({filter:t,member:e})).length;i<r;i++)t.filters.splice(t.filters.indexOf(n[i]),1);return t},_filter:function(e){var t=this;var n=v(t._filterValue.val(),t.dataSource,t.currentMember);if(e.preventDefault(),""!==n){var i={field:t.currentMember,operator:t._filterOperator.value(),value:n};var 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("."+u);var t=this._filterOperator.value();var n=this.options.messages.operators[t];e.find("select").attr(p,n)},_reset:function(e){var t=this;var 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;var 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(M)({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=[];var n;var i=this.treeView.dataSource.view();var r=i[0].checked;var o=this.dataSource.filter();var a=w({filter:o,member:this.currentMember,operator:"in"})[0];k(i,t,!0),a&&(r?(o.filters.splice(o.filters.indexOf(a),1),o.filters.length||(o={})):a.value=t.join(","),n=o),t.length&&(n||r||(n={field:this.currentMember,operator:"in",value:t.join(",")},o&&(o.filters.push(n),n=o))),n&&this.dataSource.filter(n),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={};var i=e.treeView.dataSource.get(t.data.uniqueName);t.data.uniqueName?(n.memberUniqueName=i.uniqueName.replace(/\&/g,"&"),n.treeOp=1):n.levelUniqueName=e.currentMember+".[(ALL)]",e.dataSource.schemaMembers(n).done((function(n){y(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(w({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(u)&&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){var n=[];for(var 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=0;var r;for(i=(e=e.filters).length-1;i>=0;i--)r=e[i].operator,n&&r!==n||e[i].field!==t||e.splice(i,1)}}function w(e){if(!e.filter)return[];var t=e.filter.filters;var n=0;var i=[];var r=t.length;var o;var a=e.isLocal?"neq":"in";for(;n<r;n++)o=t[n].operator,(e.operator||o===a)&&o!==e.operator||t[n].field!==e.member||i.push(t[n]);return i}function y(t,n,i){var r,o=0,a=i.length;if(t=w({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>";var 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>`;var 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 `+u+'"><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};var 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>";var M=({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 uy={number:0,boolean:!1,string:"",date:""};var py=({mainFilterLogicLabel:e,uid:t})=>`<div class='k-filter-toolbar'><div class='k-toolbar' aria-label='${e}' id='${t}'></div></div>`;var fy=({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>`;var my=({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",h=".kendoFilter",u="Is equal to",p="Is not equal to";var 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)}};var 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"))}});var g=a.extend({init:function(t,n){var i=this;var r;a.fn.init.call(i,t,n),i.element=e(t).addClass("k-filter"),i.dataSource=n.dataSource,i.operators=e.extend(i.options.operators,n.operators),i._getFieldsInfo(),i._modelChangeHandler=i._modelChange.bind(i),i._renderMain(),n.expression&&i._addExpressionTree(i.filterModel),i._renderApplyButton(),i.options.expressionPreview&&(i._previewContainer||(i._previewContainer=e('<div class="k-filter-preview"></div>').insertAfter(i.element.children().eq(0))),r=i._createPreview(i.filterModel.toJSON()),i._previewContainer.html(r)),i._attachEvents(),i.hasCustomOperators();var o=e(i.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:u,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:u,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:u,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:u,neq:p}}},applyFilter:function(){var e=this.filterModel.toJSON();this._hasCustomOperators&&this._mapOperators(e),this.dataSource&&(this._hasFieldsFilter(e.filters||[])?(this._removeEmptyGroups(e.filters),this.dataSource.filter(e)):this.dataSource.filter({}))},destroy:function(){this.element.off(h),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){var t=this.element.find("[id="+e.uid+"]");for(var 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);var 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;var a=i.closest(".k-toolbar");var 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"+h,"button.k-button",t).on("keydown"+h,".k-filter-toolbar > .k-toolbar, .k-filter-toolbar > .k-toolbar .k-toolbar-item",n)},_focusToolbar:function(t,n,i){var r=t;var 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=this;var a=n.attr("id");var s=n.closest(".k-filter-toolbar").next("ul.k-filter-lines");var l=i?o._fields[i.field]:o._defaultField;var c;var d="";i?c=i:((c=_(o.filterModel,a)).filters||c.set("filters",[]),c=o._addNewModel(c.filters,l)),s.length||(s=e("<ul class='k-filter-lines' role='group'></ul>").appendTo(n.closest("li")));var h={fields:o._fields,operators:o.operators[l.type],close:o.options.messages.close,fieldsLabel:o.options.messages.fields,uid:c.uid,ns:t.ns,filterExpressionLabel:o.options.messages.filterExpressionLabel};var u=(d=e(t.template(my)(h)).appendTo(s)).find(".k-toolbar").first();var p=l.operators&&l.operators[l.type]?l.operators[l.type]:this.operators[l.type];u.kendoToolBar({resizable:!1,items:[{type:"component",component:"DropDownList",element:`<select data-${r}bind="value: field" title='${o.options.messages.fields}' aria-label='${o.options.messages.fields}' data-auto-width='true'></select>`,attributes:{class:"k-filter-field"},componentOptions:{title:o.options.messages.fields,dataTextField:"text",dataValueField:"value",dataSource:Object.keys(o._fields||{}).map((e=>({value:o._fields[e].name,text:o._fields[e].label})))}},{type:"component",component:"DropDownList",element:`<select data-${r}bind="value: operator" aria-label='${o.options.messages.operators}' title='${o.options.messages.operators}'></select>`,attributes:{class:"k-filter-operator"},componentOptions:{title:o.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:h.close,"aria-label":h.close}}]}),o._addExpressionControls(d.find(".k-toolbar"),l,c),i||o._expressionChange()},_addExpressionControls:function(e,n,i){var r=e.find(".k-toolbar-item.k-filter-operator");var 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];var 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;var i=t.type;var r=t.operators;var o;return r||(r=this.options.operators),o=Object.keys(r[i])[0],e.push({field:t.name}),(n=e[e.length-1]).set("value",t.defaultValue),n.set("operator",o),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(fy)(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="";var i=!1;var r=this._hasFieldsFilter(e.filters||[]);var o="";var a;var s;if(!e.filters||!e.filters.length||!r)return"";n+='<span class="k-filter-preview-bracket">(</span>';for(var l=0;l<e.filters.length;l++)(a=e.filters[l]).filters&&((o=this._createPreview(a))&&(i&&(n+='<span class="k-filter-preview-operator"> '+e.logic.toLocaleUpperCase()+" </span>"),i=!0),n+=o),a.field&&(s=this._fields[a.field],i&&(n+='<span class="k-filter-preview-operator"> '+e.logic.toLocaleUpperCase()+" </span>"),i=!0,n+='<span class="k-filter-preview-field">'+s.label+"</span>",n+='<span class="k-filter-preview-criteria"> '+this._getOperatorText(a.field,a.operator),a.operator.indexOf("is")<0?(n+=" </span>",n+="<span class='k-filter-preview-value'>'"+t.htmlEncode(s.previewFormat?t.toString(a.value,s.previewFormat):a.value)+"'</span>"):n+="</span>");return n+='<span class="k-filter-preview-bracket">)</span>'},_expressionChange:function(){var e=this;var t=e.filterModel.toJSON();var 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;var 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:uy[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=this;var t=e.options.fields.length?e.options.fields:(e.options.dataSource.options.schema.model||{}).fields;var n;if(e._fields={},Array.isArray(t))for(var i=0;i<t.length;i++)n=t[i],e._addField(n);else for(var r in t)n=t[r],e._addField(n,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;var n=t.element.find("[id="+e.sender.uid+"]");if(t._showHideEditor(n,e.sender),"field"===e.field){var i=e.sender.field;var r=e.sender.parent();var o=t._fields[i];var 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};let o=e(t.template(py)(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=this;var r=n.attr("id");var o=n.closest("li");var a;var s;var l=-1;if(o.hasClass("k-filter-group-main"))o=o.find(".k-filter-lines"),i.filterModel.filters&&(i.filterModel.filters.empty(),delete i.filterModel.filters);else{l=e(i.element).find(".k-filter-toolbar > .k-toolbar").index(n),a=(s=_(i.filterModel,r)).parent(),s.unbind("change",i._modelChangeHandler),a.remove(s),a.length||delete a.parent().filters,o.siblings().length||(o=o.parent())}t.destroy(o),o.remove(),i._expressionChange(),l>-1&&i._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;var 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;var i=t._fields[e.field];var 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){var t=".kendoResponsivePanel";var n="open";var i="close";var r="click"+t+" touchstart"+t+" touchend"+t;var o=kendo.ui.Widget;var 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];var i=document.createElement("style");var 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,h=n.mediaQuery,u=n.ui,p=u.Widget,f="open",m="close",g="change",v=".kendoTimePicker",_="click"+v,b="disabled",w="readonly",y="li",k="k-focus",x="k-hover",C="mouseenter"+v+" mouseleave"+v,S="mousedown"+v,T=6e4,M=864e5,A="k-selected",D="k-disabled",E="aria-selected",I="aria-expanded",z="aria-hidden",P="aria-disabled",L="aria-readonly",B="aria-activedescendant",H="id",R=Array.isArray,F=e.extend,O=Date,V=new O,N=({mainSize:e,messages:t,buttonSize:i,isAdaptive:r})=>`<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>'+(r?"":$(i,t))+"</div>",$=(e,t,i)=>i?n.html.renderButton(`<button class="k-time-cancel" title="Cancel changes" aria-label="Cancel changes">${a(t.cancel)}</button>`,{size:e})+n.html.renderButton(`<button class="k-time-accept" title="Set time" aria-label="Set time">${a(t.set)}</button>`,{size:e,themeColor:"primary"}):'<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=h("large"),t.smallScreenMQL=h("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(H,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+=M),o<r&&(o+=M),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";const i="auto"===this.options.adaptiveMode&&!this.bigScreenMQL.mediaQueryList.matches;var r=e.extend({},this.options,{mainSize:n.getValidCssClass("k-timeselector-","size",t),buttonSize:t,isAdaptive:i});this.popupContent=e(n.template(N)(r)).on(S,K),this.list=this.popupContent.find(".k-timeselector");const o=i?".k-actionsheet-footer button.k-time-cancel":".k-time-footer button.k-time-cancel";const a=i?".k-actionsheet-footer button.k-time-accept":".k-time-footer button.k-time-accept";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,o,this._cancelClickHandler.bind(this)),this.popupContent.on("click"+v,a,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),h=Z(a.find(".k-item:visible").eq(0)),u=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?(u.scrollTop(u.scrollTop()-h),t.preventDefault()):o==i.DOWN?(u.scrollTop(u.scrollTop()+h),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;var 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(_,y,t._click.bind(t)).on("mouseenter"+v,y,(function(){e(this).addClass(x)})).on("mouseleave"+v,y,(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(H),i._current[0].removeAttribute(E))),n&&(n=e(n).addClass(A).attr(H,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=Q(this.options.format.toLowerCase(),"t");var i=e.getHours();var r=e.getMinutes();var o=e.getSeconds();var a;var s=n.attr("index");var l=this.ul.find("["+s+'="1"]');var c=this.ul.find("["+s+'="2"]');var d=this.ul.find("["+s+'="3"]');var h=this.ul.find("["+s+'="4"]');t&&(i>=12?(a="PM",i>12&&(i-=12)):(a="AM",0===i&&(i=12))),this._internalScroll=!0,l.length&&this._scrollListToPosition(l,i),c.length&&this._scrollListToPosition(c,r),d.length&&this._scrollListToPosition(d,o),h.length&&this._scrollListToPosition(h,a),this._internalScroll=!1}},_scrollListToPosition:function(e,t){var n=e.find('.k-item[data-value="'+X(t)+'"]');var 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=this;var t;(!e.ul[0].firstChild||e.ul.find("li").length<1)&&e.bind(),e._focusTime&&e.value(e._focusTime),t=e.popup._hovered,e.popup._hovered=!0,e.popup.open(),setTimeout((function(){e.popup._hovered=t}),1),e._current&&e.scroll(e._current[0])},dataBind:function(e){var t,i=this,r=i.options,o=r.format,a=n.toString,s=i.template,l=e.length,c=0,d="";for(;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=this,t=e.options,i=t.format,r=(b=new O,w=new O(b.getFullYear(),b.getMonth(),b.getDate(),0,0,0),y=new O(b.getFullYear(),b.getMonth(),b.getDate(),12,0,0),-1*(w.getTimezoneOffset()-y.getTimezoneOffset())),o=r<0,a=n.parseDate(e._value),s=Y(a||new Date,t.min),l=t.min,c=t.max,d=W(l),h=W(c),u=W(function(e){var t=new Date(2100,0,1);return t.setMinutes(-e),t}(t.interval)),p=t.interval*T,f=n.toString,m=e.template,g=t.useValueToRender?s:new Date(+t.min),v=new O(g),_="";var b,w,y;d==h&&u!==h||d>h&&(h+=M),t.timeView&&"scroll"===t.timeView.list?_=e._createListContent(n.date.splitDateFormat(i),t.interval):e.getDatesInRange(undefined,h,v,c,p,g).forEach((function(e){_+=m(f(e,i,t.culture))})),e._html(_)},_showAllHiddenItems:function(){var t=this.list.find(".k-time-container");var n=t.length;var i;for(var r=0;r<n;r++)(i=e(t[r])).find(".k-item:hidden").show(),this._updateListBottomOffset(i)},_updateListBottomOffset:function(e){var t=Z(e.find(".k-item:visible").eq(0));var n=e.outerHeight()-t;e.find(".k-scrollable-placeholder").css({height:e.find("ul").height()+n})},_updateHoursRange:function(){var t=this;var i=n.attr("index");var r=this.ul.find("["+i+'="1"]');var o=this._minHours;var a=this._maxHours;var s=Q(this.options.format.toLowerCase(),"t");var l;var c;var d=this._findSelectedValue(this.ul.find("["+i+'="4"]'));r.length&&(s&&d?("AM"===d?(o<12&&(c=!0),a<12&&(l=!0)):"PM"===d&&(o>12&&(c=!0,o-=12),a>12&&(l=!0,a-=12)),r.find(".k-item").each((function(n,i){var r=+(i=e(i)).attr("data-value");t._validateMin&&c&&r<o||t._validateMax&&l&&r>a?i.hide():i.show()}))):r.find(".k-item").each((function(n,i){var r=+(i=e(i)).attr("data-value");t._validateMin&&r<o||t._validateMax&&r>a?i.hide():i.show()})),this._updateListBottomOffset(r))},_updateMinutesRange:function(){var t=this;var i=n.attr("index");var r=this.ul.find("["+i+'="2"]');var o=this._minHours;var a=this._maxHours;var s=this._minMinutes;var l=this._maxMinutes;var c=+this._findSelectedValue(this.ul.find("["+i+'="1"]'));var d=Q(this.options.format.toLowerCase(),"t");var h=this._findSelectedValue(this.ul.find("["+i+'="4"]'));d&&"PM"===h&&(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;var i=n.attr("index");var r=this.ul.find("["+i+'="3"]');var o=this._minSeconds;var a=this._minSeconds;var s=this._minMinutes;var l=this._maxMinutes;var 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;var t=this._maxHours;var i=n.attr("index");var 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;var 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(){var e=this.ul.find(".k-time-container.k-content.k-scrollable");var t=e.length;var n;var i;var r;var o;var a;for(var s=0;s<t;s++)i=Z((n=e.eq(s)).find(".k-item:visible").eq(0)),o="translateY("+((r=n.outerHeight())-i)/2+"px)",a=r-i,n.find("ul").css({transform:o,"-ms-transform":o}),n.find(".k-scrollable-placeholder").css({height:n.find("ul").height()+a}),n.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;var 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=Q(this.options.format.toLowerCase(),"t");var i=n.attr("index");var r=this.ul.find("["+i+'="1"]');var o=this.ul.find("["+i+'="2"]');var a=this.ul.find("["+i+'="3"]');var s=this.ul.find("["+i+'="4"]');var l;var c;var d;var h;this.ul.is(":visible")&&(this._currentlySelected||(this._currentlySelected=this._value?new Date(this._value):new Date),r.length&&(l=+this._findSelectedValue(r)),o.length&&(c=+this._findSelectedValue(o)),a.length&&(d=+this._findSelectedValue(a)),s.length&&(h=this._findSelectedValue(s)),e&&("PM"==h&&24==(l+=12)&&(l=12),"AM"===h&&12===l&&(l=0)),l!==t&&this._currentlySelected.setHours(l),c!==t&&this._currentlySelected.setMinutes(c),d!==t&&this._currentlySelected.setSeconds(d))},_findSelectedValue:function(e){var t=(n=e.scrollTop(),i=Z(e.find(".k-item:visible").eq(0)),Math.max(Math.round(n/i),0));var n,i;return e.find(".k-item:visible").eq(t).attr("data-value")},_itemClickHandler:function(t){var n=e(t.originalEvent.currentTarget);var i=n.find(".k-item:visible").index(e(t.currentTarget));var r=Z(n.find(".k-item:visible").eq(0));n.scrollTop(i*r)},getDatesInRange:function(e,t,n,i,r,o){var a=[];for(;;){if(t&&(W(o)>=t||n.getDate()!=o.getDate())){e=W(o),n<o&&(e+=M),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&&!this._ignoreMaxSet)break}return a},_createListContent:function(e,t){var n=e.length;var i="";var r;var o;for(var a=0;a<n;a++)"literal"===(r=e[a]).type||"dayperiod"==r.type?i+=this._literalTemplate(r):(o=this._getValues(r,!0,t),i+=this._itemTemplate(o.values,r,this.options.messages[r.type],o.index));return i},_itemTemplate:function(e,t,i,r){var o="";var a=e.length;var 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=[];var o;var a=0;var s;var l=0;var c=0;for(e.isPlainObject(i)&&(l=i[t.type]||0),"hour"===t.type?(a=t.hour12?1:0,o=1,s=t.hour12?12:23):"minute"===t.type?(o=2,s=59):"second"===t.type&&(o=3,s=59);a<=s;a++)l>0?((0===a||1===a&&l>1&&"hour"===t.type)&&r.push(n?X(c):c),a%l==0&&c+l<=s&&(c+=l,r.push(n?X(c):c))):r.push(n?X(a):a);return{values:r,index:o}},_literalTemplate:function(e){var t=" tt"===e.pattern||"aa"===e.pattern;var 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=F(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;const 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;var t=e.list;var n=t.parent(".k-child-animation-container");var i=n.closest(".k-animation-container");var r=e.options.height;var o=t.add(i);var 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 u.Popup(e.popupContent||t,F(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 u.ActionSheet(r,{adaptive:!0,focusOnActivate:!1,title:n.adaptiveTitle||"Set time",subtitle:n.adaptiveSubtitle,closeButton:{icon:"check",themeColor:"primary"},footerTemplate:"modern"===e.options.componentType?()=>$("auto"!=e.options.adaptiveMode||e.bigScreenMQL.mediaQueryList.matches?e.options.size||"medium":"large",e.options.messages,!0):null,fullscreen:e.smallScreenMQL.mediaQueryList.matches,popup:F(n.popup,{anchor:i,close:n.close,animation:n.animation,isRtl:c.isRtl(n.anchor)}),open:function(){e.popup._footer&&e.popup._footer.addClass("k-actions k-actions-stretched k-actions-horizontal"),n.open&&n.open()},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()}},move:function(t){const n=this,r=t.keyCode,o=n.ul[0],a=r===i.DOWN,s=e(t.target).is(".k-input-inner"),l="modern"===n.options.componentType,c=n.popup.visible();let d=n._current;const h=s&&l&&c;if(r===i.UP||a){if(t.altKey)return void n.toggle(a);if(h)return;d=a?d?d[0].nextSibling:o.firstChild:d?d[0].previousSibling:o.lastChild,d&&n.select(d),n.options.change(n._current.text()),t.preventDefault()}else r!==i.ENTER&&r!==i.TAB&&r!==i.ESC||(t.preventDefault(),d&&n.options.change(d.text(),!0),n.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.inputMode=i.inputMode||t.attr("inputmode")||"text",t.attr("inputmode",i.inputMode),+i.max==+V&&+i.min==+V||(this._specifiedRange=!0),G(i),r._initialOptions=F({},i),r._wrapper(),r.options.timeView&&"scroll"===r.options.timeView.list&&(r.options.height=null),r.bigScreenMQL=h("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",adaptiveTitle:null,adaptiveSubtitle:null,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){R(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;var r=t.max;var 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 u.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,toggleDayPeriod:!0,inputMode:t.inputMode})}},_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?D:"").removeClass(n?"":D),o.attr(b,n).attr(w,i).attr(P,n).attr(L,i)):(a.removeClass(D).on(C,t._toggleHover),o&&o.length&&(o[0].removeAttribute(b),o[0].removeAttribute(w)),o.attr(P,!1).attr(L,!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;var i=t.options;var 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;var 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=this;var t=e.options;var n=e.element;var i,r;e.timeView&&(e.timeView.popup&&e.timeView.popup.wrapper&&e.timeView.popup.wrapper.remove(),e.timeView.destroy(),e.timeView=null),e.timeView=i=new U(F({},t,{id:n.attr(H),size:"auto"!=t.adaptiveMode||e.bigScreenMQL.mediaQueryList.matches?t.size:"large",anchor:e.wrapper,format:t.format,change:function(t,i){i?e._change(t):n.val(t),e.timeView._focusTime=null},open:function(t){e.options.timeView&&"scroll"!==e.options.timeView.list?e.timeView._adjustListWidth():e.timeView._updateTitle(),e.trigger(f)?t.preventDefault():(n.attr(I,!0),r.attr(z,!1),i.current()&&n.attr(B,i._optionID))},close:function(t){e.trigger(m)?t.preventDefault():(n.attr(I,!1),r.attr(z,!0),n[0].removeAttribute(B))},active:function(e){n&&n.length&&n[0].removeAttribute(B),e&&n.attr(B,i._optionID)},specifiedRange:e._specifiedRange,maxSet:+t.max!=+V})),r=i.ul,e._ariaLabel(r)},_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){const t=this,n=e.keyCode,r=t.timeView,o=t.element.val();r.popup.visible()||e.altKey?(r.move(e),t._dateInput&&e.stopImmediatePropagation&&"modern"!==t.options.componentType&&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},_toggleMaxSet:function(e){this.timeView&&(this.timeView._ignoreMaxSet=e)},_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(){let t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){t._toggleMaxSet(!0),t.value(n[0].defaultValue),t.max(t._initialOptions.max),t.min(t._initialOptions.min),t._toggleMaxSet(!1)},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=R(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){var n=String(e);for(;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"]])}]),u.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,h=d.isInRange,u=d.restrictValue,p=d.isEqualDatePart,f=i.getMilliseconds,m=n.ui,g=m.Widget,v="open",_="close",b="change",w=".kendoDateTimePicker",y="click"+w,k=a.mouseAndTouchPresent?n.applyEventMap("up",w.slice(1)):y,x="disabled",C="readonly",S="k-focus",T="k-disabled",M="mouseenter"+w+" mouseleave"+w,A="mousedown"+w,D="month",E="aria-activedescendant",I="aria-expanded",z="aria-hidden",P="aria-disabled",L="aria-readonly",B=Date,H=new B(1800,0,1),R=new B(2099,11,31),F={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";var 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.inputMode=i.inputMode||t.attr("inputmode")||"text",t.attr("inputmode",i.inputMode),+i.max==+R&&+i.min==+H&&+i.startTime==+H&&i.endTime==+R||(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.popup&&a.dateView.popup.wrapper&&a.dateView.popup.wrapper.remove(),a.dateView&&a.dateView.destroy(),a.timeView.popup&&a.timeView.popup.wrapper&&a.timeView.popup.wrapper.remove(),a.timeView&&a.timeView.destroy(),a.popup&&a.popup.wrapper&&a.popup.wrapper.remove(),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,adaptiveTitle:null,adaptiveSubtitle:null,value:null,format:"",timeFormat:"",culture:"",parseFormats:[],dates:[],disableDates:null,startTime:null,endTime:null,min:new B(H),max:new B(R),interval:30,height:200,footer:"",start:D,depth:D,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 B(H)),i&&!p(i,r)&&(i=new B(R)),s._dateIcon.off(w),s._dateIcon.remove(),s._timeIcon.off(w),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(w),r=t._dateIcon.off(w),o=t._timeIcon.off(w),a=t.wrapper.off(w),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(L,s)):(a.removeClass(T).on(M,t._toggleHover),i&&i.length&&(i[0].removeAttribute(x),i[0].removeAttribute(C,!1),i[0].removeAttribute(P,!1),i[0].removeAttribute(L,!1)),i.on("keydown"+w,t._keydown.bind(t)).on("focus"+w,(function(){t.wrapper.addClass(S)})).on("focusout"+w,(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;var i=t.options;var 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(w),e.popup.destroy()),e.element.off(w),e._dateIcon.off(w),e._timeIcon.off(w),e.wrapper.off(w),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=this;var n;t.options.singlePopup?(t.dateView._calendar(),t.timeView.ul.find("li").length<1&&t.timeView.bind(),n=t.popup._hovered,t.popup._hovered=!0,t.popup.open(),"time"===e?t._switchToTimeView():t._switchToDateView(),this._dateIcon.toggle("time"!==e),this._timeIcon.toggle("time"===e),setTimeout((function(){t.popup._hovered=n}),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;var 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=this;var r=i.options;var a=i.timeView;var s=a.options;var l=i._value||i._old;var c;var d;if(n===t)return r[e];if(n=o(n,r.parseFormats,r.culture),s.maxSet=!1,n){if(r.min.getTime()===r.max.getTime()&&(s.dates=[]),r[e]=new B(n.getTime()),i.dateView[e](n),i._dateInput&&i._dateInput[e](n),i._midnight=i._calculateMidnight(r.min,r.max),l&&(c=p(r.min,l),d=p(r.max,l)),c||d){if(s[e]=n,c&&!d&&(s.max=W(r.interval)),d){if(i._midnight)return void a.dataBind([R]);c||(s.min=H,s.maxSet=!0)}}else s.max=R,s.min=H;a.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,w=c.timeView,y=c._value,k=o(t,d.parseFormats,d.culture),x=null===k&&null===y||k instanceof Date&&y instanceof Date;return d.disableDates&&d.disableDates(k)&&(k=null,c._old||c.element.val()||(t=null)),+k==+y&&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=u(k,f,m):h(k,f,m)||(k=null),c._value=k,w.value(k),c.dateView.value(k),k&&(a=c._old,(r=w.options).maxSet=!1,_[0]&&(_=e.grep(_,(function(e){return p(k,e)})))[0]&&(w.dataBind(_),s=!0),s||(p(k,f)&&(r.min=g||f,r.max=v||W(d.interval),i=!0),p(k,m)&&(c._midnight?(w.dataBind([R]),s=!0):(r.max=v||m,r.maxSet=!0,i||(r.min=H),i=!0))),!s&&(!a&&i||a&&!p(a,k))&&(i||(r.max=v||R,r.min=g||H),w.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();var 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 B("startTime"==e?H:R);return r&&(a=new B(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,h,u=this,p=u.element,f=u.options,m=p.attr("id");f.singlePopup&&(f.dateDiv=u.popup.element.find(".k-datetime-calendar-wrap"),c=u.popup.element.find(".k-datetime-time-wrap"),f.omitPopup=d=!0,h=f.timeView),u.dateView&&(u.dateView.destroy(),u.dateView=null),u.dateView=e=new n.DateView(V({},f,{id:m,anchor:u.wrapper,change:function(){var e=u._applyDateValue();f.singlePopup?(u.timeView._currentlySelected||(u.timeView._currentlySelected=new Date),u.timeView._currentlySelected.setFullYear(e.getFullYear()),u.timeView._currentlySelected.setMonth(e.getMonth()),u.timeView._currentlySelected.setDate(e.getDate()),u._switchToTimeView(),u._toggleIcons("time")):(u._change(e),u.close("date"))},close:function(e){u.trigger(_,F)?e.preventDefault():(p.attr(I,!1),r.attr(z,!0))},open:function(e){u.trigger(v,F)?e.preventDefault():(p.val()!==u._oldText&&(l=o(p.val(),f.parseFormats,f.culture),u.dateView[l?"current":"value"](l)),r.attr(z,!1),p.attr(I,!0),u._updateARIA(l))}})),r=e.div,s=f.min.getTime(),u.timeView&&(u.timeView.destroy(),u.timeView=null),u.timeView=t=new i({id:m,adaptiveMode:f.adaptiveMode,adaptiveTitle:f.adaptiveTitle,adaptiveSubtitle:f.adaptiveSubtitle,value:f.value,size:"auto"!=f.adaptiveMode||u.bigScreenMQL.mediaQueryList.matches?f.size:"large",anchor:u.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:u._timeOption("startTime"),max:u._timeOption("endTime"),dates:s===f.max.getTime()?[new Date(s)]:[],parseFormats:f.parseFormats,validateDate:!f.startTime&&!f.endTime,change:function(t,i){t=u._applyTimeValue(t),i?(u._timeSelected=!0,u._change(t)):(p.val(n.toString(t,f.format,f.culture)),e.value(t),u._updateARIA(t))},close:function(e){u.trigger(_,O)?e.preventDefault():(a.attr(z,!0),p.attr(I,!1))},open:function(e){"modern"!==u.options.componentType?t._adjustListWidth():u.timeView._updateTitle(),u.trigger(v,O)?e.preventDefault():(p.val()!==u._oldText&&(l=o(p.val(),f.parseFormats,f.culture),u.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:u._specifiedRange,omitPopup:d,timeDiv:c,timeView:h,messages:u.options.messages}),a=t.ul},_applyDateValue:function(){var e=this;var t=e.options;var i=e.dateView.calendar.value();var r=+i;var o=+t.min;var a=+t.max;var s,l;return r!==o&&r!==a||(s=r===o?o:a,(s=new B(e._value||s)).setFullYear(i.getFullYear(),i.getMonth(),i.getDate()),h(s,o,a)&&(i=s)),e._value&&(l=n.date.setHours(new Date(i),e._value),h(l,o,a)&&(i=l)),i},_applyTimeValue:function(e){var t=this.timeView;var n=this.options;return(e=t._parse(e))<n.min?(e=new B(+n.min),t.options.min=e):e>n.max&&(e=new B(+n.max),t.options.max=e),e},_icons:function(){var t=this;var n=t.element;var 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,toggleDayPeriod:!0,inputMode:e.inputMode}))},_calculateMidnight:function(e,t){return f(e)+f(t)===0},_updateARIA:function(e){var t=this;var 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;var i=t.options;var 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:i.adaptiveTitle||"Select Date and Time",subtitle:i.adaptiveSubtitle,closeButton:{icon:"check",themeColor:"primary"},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(y+w,".k-datetime-buttongroup .k-button",t._groupChangeClick.bind(t)),r.on(y+w,".k-datetime-footer button.k-time-cancel",t._cancelClickHandler.bind(t)),r.on(y+w,".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=this._applyDateValue();var n;t=t||new Date,n=this.timeView._currentlySelected||t,this.timeView._updateCurrentlySelected(),t.setHours(n.getHours()),t.setMinutes(n.getMinutes()),t.setSeconds(n.getSeconds()),t=this._applyTimeValue(t),this._change(t),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;var gy=function(e){return null!=e};var vy=function(e){return gy(e)&&e.getTime&&_y(e.getTime())};var _y=function(e){return gy(e)&&"number"==typeof e&&!Number.isNaN(e)};!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",h="change",u=n.template,p=e.extend,f=n.support,m=f.mobileOS,g="aria-expanded",v="aria-disabled",_="aria-activedescendant",b="k-disabled",w="k-hidden",y="disabled",k="readonly",x="aria-hidden",C="start",S="end",T=".kendoDateRangePicker",M="click"+T,A="mousedown"+T,D=f.mouseAndTouchPresent?n.applyEventMap("up",T.slice(1)):M,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=this;var r=t.calendar;var o=t.options;var a;if(!r){var s=t.popup._content||t.popup.element;"auto"!=o.adaptiveMode||t.bigScreenMQL.mediaQueryList.matches||(s=s.append(e('<div class="k-scrollable-wrap"></div>')).find(".k-scrollable-wrap")),a=e("<div />").attr("id",n.guid()).appendTo(s),t.calendar=r=new i.MultiViewCalendar(a,{size:"auto"!=o.adaptiveMode||t.bigScreenMQL.mediaQueryList.matches?o.size||"medium":"large",orientation:"auto"!=o.adaptiveMode||t.bigScreenMQL.mediaQueryList.matches?"horizontal":"vertical",views:"auto"!=o.adaptiveMode||t.bigScreenMQL.mediaQueryList.matches?2:1}),t._setOptions(o),r.navigate(t._value||t._current,o.start),t._range=t._range||o.range||{},a.on(A,z).on(M,"td:has(.k-link)",t._click.bind(t)),t.calendar.selectRange(t._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;var n=e.keyCode;var i=t.calendar;var r=e.ctrlKey&&n==o.DOWN;var a=n==o.ENTER;var s=!1;if(e.altKey)n==o.DOWN?(t.open(),e.preventDefault(),s=!0):n==o.UP&&(t.close(),e.preventDefault(),s=!0);else if(t.popup.visible()){if(n==o.ESC||r&&i._cell.hasClass("k-selected"))return t.close(),e.preventDefault(),!0;a&&t._range.target==C&&null==t._range.start||a&&t._range.target==C&&null!==t._range.end||"ArrowUp"==e.key||"ArrowDown"==e.kay?t._current=i._move(e):a?t.calendar.trigger(h):t._current=i._move(e),s=!0}return s},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),t.inputMode=t.inputMode||e.attr("inputmode")||"text",i._initialOptions=p({},t),i._buildHTML(),i._range=i.options.range,i._changeTriggered=!1,i._initializeDateViewProxy=i._initializeDateView.bind(i),i.bigScreenMQL=a("large"),i.bigScreenMQL.onChange((()=>{i._initializeDateViewProxy()})),i._initializeDateView(),i._ariaTemplate=u(this.options.ARIATemplate).bind(i),i._reset(),i._aria(),i._inputs.on(D+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,h],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(M,i._expandButtonClick.bind(i)),i._endDateButton=n.attr({role:"button"}).on(M,i._expandButtonClick.bind(i)))},_click:function(){let e=this,n=e.options;e._isFirstClick=e._isFirstClick==t,n.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(w,!t),e===S&&n._endClearButton.toggleClass(w,!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(h),n.range({start:null,end:a.end})),i===S&&(o.value(null),o.trigger(h),n.range({start:a.start,end:null})),n._toggleClearButton(i,!1)},_expandButtonClick:function(t){let n=this;n._preventInputAction||n.dateView.popup.visible()||(n._isFirstClick=!0,n.dateView.open(),e(t.target).closest(".k-input").find(".k-input-inner").trigger("focus"))},_navigatePrevNextDate:function(e){var t,i,r=this,o=r.dateView;var a=r._currentTarget==C?r._startDateInput.dateInputInstance:r._endDateInput.dateInputInstance;var s=a.currentFormat[a.selection.start];var l=a.getStepFromSymbol(s);let c=E(a.elementValue,a.dateObject.format,a.dateObject.localeId);l="ArrowDown"==e.key?-l:+l;var d=n.calendar.isInRange(c,o.options.min,o.options.max);vy(c)&&d&&o.popup.visible()?(e.preventDefault(),a.modifyDateSegmentValue(l,s,e),o.calendar.selectRange({start:r._startDateInput.value(),end:r._endDateInput.value()}),t=r._currentTarget==C?r._startDateInput.value():r._endDateInput.value(),i="ArrowDown"==e.key?t.setDate(t.getDate()-7):t.setDate(t.getDate()+7),r.dateView.calendar._current=new Date(i)):o.calendar?o.calendar.selectRange({start:r._startDateInput.value(),end:r._endDateInput.value()}):o.range({start:r._startDateInput.value(),end:r._endDateInput.value()})},_handleAllowReverseEnter:function(e,t,n,i,r){var o=this,a=o.dateView;o._currentTarget===C&&null===o._startDateInput.value()?(e.target.select(),a.move(e)):o._currentTarget===S&&null===o._endDateInput.value()?(n.value(a._current),t={start:t.start,end:a._current},n.trigger(h),a.range(t),a.close()):o._isFirstClick&&i.value!==a._current?(n.value(a._current),t[o._currentTarget]=a._current,n.trigger(h),a.range(t),a.close()):a.range(t)},_handleStandardEnter:function(e,t,n,i,r){var o=this,a=o.dateView;let s=o._startDateInput.value()>a._current?null:a._current;let l=1==o._isFirstClick?s:o._endDateInput.value();let c=n.value()===o.dateView._current;if(o._currentTarget!=C||c||!o.dateView.popup.visible()||o._backspaceChange)if(o._backspaceChange){let e=n.dateInputInstance.elementValue==n._emptyMask?null:n._oldValue;n.value(e),t[o._currentTarget]=e,a.range(t),n.trigger(h)}else if(o._startDateInput.value()<=o._endDateInput.value()&&null!=o._startDateInput.value()&&null!=o._endDateInput.value())t={start:o._startDateInput.value(),end:l},a.range(t),o._isFirstClick&&n.value(l),o._updateARIA(a._current),n.trigger(h);else if(o._currentTarget==C&&o._endDateInput.value()<=a._current)e.target.select(),a.move(e);else if(o._currentTarget==C&&o._startDateInput.value()>l)o._endDateInput.value(o._startDateInput.value()),n.trigger(h);else{if(o._currentTarget==S&&o._startDateInput.value()>o._endDateInput.value()&&vy(i))t={start:o._startDateInput.value(),end:null},o._endDateInput.value(o._startDateInput.value());else if(null==l){let e="start"==n?t.start:t.end;n.value(e)}else n.value(l),t[o._currentTarget]=l;n.trigger(h),a.range(t)}else n.value(a._current),t={start:a._current,end:t.end},a.range(t),n.trigger(h),o._endDateInput.dateInputInstance.focus();o._backspaceChange=!1},_handleArrowKeys:function(e,t,n,i){let r=this,o=r._currentTarget==C?r._startDateInput.dateInputInstance:r._endDateInput.dateInputInstance,a=o.value;if(!1!==r._isFirstClick||"ArrowDown"!=e.key&&"ArrowUp"!=e.key||e.altKey||e.ctrlKey||r._navigatePrevNextDate(e),!1!==r._isFirstClick||"ArrowRight"!=e.key&&"ArrowLeft"!=e.key||e.shiftKey)!e.shiftKey||"ArrowRight"!=e.key&&"ArrowLeft"!=e.key||(n.move(e),r._updateARIA(n._current));else{let i="ArrowRight"==e.key?-1:1;null!=t&&(n.calendar._current=new Date(a.setDate(a.getDate()+i)),o.switchDateSegment(-i))}},_keydown:function(e){var t,i=this,r=i.dateView,a=!1,s=i.range(),l=i._currentTarget==C?i._startDateInput:i._endDateInput,c=i._currentTarget==C?i._startDateInput.dateInputInstance:i._endDateInput.dateInputInstance,d=E(c.elementValue,c.dateObject.format,c.dateObject.localeId),u=!1;i._preventInputAction?e.stopImmediatePropagation():(r.calendar&&(t=n.calendar.isInRange(d,r.calendar.options.min,r.calendar.options.max)),!e.altKey||"ArrowDown"!=e.key&&"ArrowUp"!=e.key||(i._isFirstClick=!0,"ArrowUp"==e.key&&JSON.stringify(s)!=JSON.stringify(i.dateView.calendar._range)&&(r.range(i.dateView.calendar._range),l.trigger(h))),"Enter"==e.key?(u=!0,i.options.allowReverse?i._handleAllowReverseEnter(e,s,l,c,d):i._handleStandardEnter(e,s,l,d,a),this.dateView&&this.options.autoClose&&e.target.attributes["data-input"].value==S&&this.dateView.close()):e.keyCode==o.ESC?(u=!0,a=r.move(e)):"Backspace"==e.key||"Delete"==e.key?(i._changeTriggered=!1,i._backspaceChange=!0):i._isFirstClick&&vy(d)&&t&&isNaN(parseFloat(e.key))||e.altKey?(a=r.move(e),i._updateARIA(r._current),u=!0):i._isFirstClick&&(vy(d)||t)&&isNaN(parseFloat(e.key))||e.altKey?(u=!0,i._updateARIA(r._current),"ArrowDown"!=e.key&&"ArrowUp"!=e.key||e.altKey||e.ctrlKey||i._navigatePrevNextDate(e),a=r.move(e)):(i._updateARIA(r._current),i._handleArrowKeys(e,d,r,a),isNaN(parseFloat(e.key))||e.altKey||e.ctrlKey||e.shiftKey||setTimeout((function(){d=E(c.elementValue,c.dateObject.format,c.dateObject.localeId);let t=n.calendar.isInRange(d,r.options.min,r.options.max);vy(d)&&t&&r.popup.visible()?(r.calendar.selectRange({start:i._startDateInput.value(),end:i._endDateInput.value()}),r.calendar._current=i._currentTarget==C?i._startDateInput.value():i._endDateInput.value(),a=r.move(e),i._updateARIA(r._current)):vy(d)&&t&&r.range({start:i._startDateInput.value(),end:i._endDateInput.value()})}))),vy(d)&&t&&!u&&isNaN(parseFloat(e.key))&&(a=r.move(e),i._updateARIA(r._current)),a&&e.stopImmediatePropagation&&e.stopImmediatePropagation())},_updateARIA:function(t){var n=this;var 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)))},_isAdaptive:function(){return"auto"===this.options.adaptiveMode&&!this.bigScreenMQL.mediaQueryList.matches},_inputFocus:function(t){let n=this,i=n.range();if(n._currentTarget!==e(t.target).data("input"))if(n._currentTarget=e(t.target).data("input"),i){if(n._isAdaptive()&&!n.options.autoClose&&n.dateView.popup.visible()){const e=n._temporaryInputValues||{};i.start=e.start,i.end=e.end}else i.start=n._startDateInput.value(),i.end=n._endDateInput.value();n.range(i)}else n.range({start:null,end:null})},_updateInputValueAndSelectRange:function(e,t,n,i){var r=this;t.value(n),t.trigger(h),r.dateView.calendar&&r.dateView.calendar.selectRange(i),r.trigger(h)},_startChange:function(e){var t=this;var n=e.sender;var i=n.value();let r;if(t._isAdaptive()&&!t.options.autoClose){r=(t._temporaryInputValues||{}).end}else r=t._endDateInput.value();var o=t.range();if(t.options.disableDates(i)&&(e.sender.value(null),i=null),1==t._backspaceChange){let e=n.dateInputInstance.elementValue==n._emptyMask?null:o.start;n.value(e),t.range({start:e,end:o.end}),t.dateView.range(t.range()),i=e,t._changeTriggered=!1,t._backspaceChange=!1}t.range({start:i,end:r}),e.blur&&!t.options.allowReverse&&t._startDateInput.value()>t._endDateInput.value()&&null!=r&&t.options.min.getTime()===new Date(1900,0,1).getTime()&&(t._changeTriggered=!0,setTimeout((function(){t._updateInputValueAndSelectRange(e,t._startDateInput,o.start,o),t._changeTriggered=!1}))),t._changeTriggered||t.trigger(h),t._backspaceChange=!1,t._toggleClearButton(C,null!==i)},_endChange:function(e){var t=this;var n=e.sender;let i;let r;const o=t._isAdaptive();if(o&&!t._backspaceChange){const e=t._temporaryInputValues||{};r=e.start,i=e.end}else r=t._startDateInput.value(),i=n.value();var a=t.range();if(t.options.disableDates(i)&&(e.sender.value(null),i=null),1==t._backspaceChange){let e=n.dateInputInstance.elementValue==n._emptyMask?null:a.end;n.value(e),t.range({start:a.start,end:a.correctEndDate}),t.dateView.range(t.range()),i=e,t._changeTriggered=!1,t._backspaceChange=!1}t.range({start:r,end:i}),e.blur?!t.options.allowReverse&&t._startDateInput.value()>t._endDateInput.value()&&n.dateInputInstance.previousElementValue!=n._emptyMask&&(t._changeTriggered=!0,setTimeout((function(){t._updateInputValueAndSelectRange(e,t._endDateInput,a.end,a)}))):t._currentTarget===S?r&&t.options.autoClose&&!o?t._endDateInput.dateInputInstance.focus():t._startDateInput.dateInputInstance.focus():i&&t.options.autoClose&&!o?t._startDateInput.dateInputInstance.focus():t._endDateInput.dateInputInstance.focus(),1==e.blur&&this.dateView&&this.options.autoClose&&e.sender.element.attr("data-input")==S&&this.dateView.close(),t._changeTriggered||t.trigger(h),t._backspaceChange=!1,t._toggleClearButton(S,null!==i)},_initializeDateView:function(){var e=this;var n;e.dateView&&(e.dateView.popup&&e.dateView.popup.wrapper&&e.dateView.popup.wrapper.remove(),e.dateView.destroy(),e.dateView=null);const i="auto"===e.options.adaptiveMode&&!e.bigScreenMQL.mediaQueryList.matches;e.dateView=new I(p({},e.options,{id:e.element.attr("id"),anchor:e.wrapper,views:2,selectable:{mode:"range",reverse:e.options.allowReverse,resetOnStart:!e.options.autoClose&&i},value:e._range?.start||e._range?.end,range:e._range,change:function(){var t=this.selectRange();e._isAdaptive()&&(e._temporaryInputValues={start:t.start,end:t.end}),e.range(t),e.trigger(h),e._changeTriggered=!0,e._startDateInput.trigger(h),e._endDateInput.trigger(h),e._changeTriggered=!1},close:function(i){e.trigger(d)?i.preventDefault():(e._inputs.attr(g,!1),n.attr(x,!0),setTimeout((function(){let t=e.range();e._inputs&&e._inputs.removeAttr(_),t&&e.dateView&&e.dateView.calendar&&e.dateView.calendar.rangeSelectable&&e.range(t)}))),e._isFirstClick=t},open:function(t){let i=e.range();let r=e._currentTarget==C?e._startDateInput:e._endDateInput;e.trigger(c)?t.preventDefault():(e._isAdaptive()&&!e.options.autoClose&&(e._temporaryInputValues={startInitial:e._startDateInput.value(),endInitial:e._endDateInput.value()},e.dateView.popup.wrapper.find("[data-ref-actionsheet-close-button]").on("mousedown",(function(){t.preventDefault();const n=e._temporaryInputValues||{};const i=n.start;const r=n.end;e._startDateInput.value(i),e._endDateInput.value(r),e.close()}))),!i||JSON.stringify(e._startDateInput.value())==JSON.stringify(i.start)&&JSON.stringify(e._endDateInput.value())==JSON.stringify(i.end)||null==e._startDateInput.value()&&null==e._endDateInput.value()||(e.dateView.range({start:e._startDateInput.value(),end:e._endDateInput.value()}),r.trigger(h)),e.dateView._current=r.value(),e._inputs.attr(g,!0),n.attr(x,!1),e._updateARIA())},_buttons:!this.options.autoClose&&i&&[{text:"Cancel",click:function(){const t=e._temporaryInputValues||{};const n=t.startInitial;const i=t.endInitial;e._startDateInput.value(n),e._endDateInput.value(i),e.close()}},{text:"Set",themeColor:"primary",click:function(){const t=e._temporaryInputValues||{};const n=t.start;const i=t.end;e._startDateInput.value(n),e._endDateInput.value(i),e.close()}}]})),n=e.dateView.div},_initializeDateInputs:function(){var e=this;var t=e.options;var n=t.range||{};var 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,toggleDayPeriod:!0,inputMode:t.inputMode};e._startDateInput&&(e._startDateInput.destroy(),e._endDateInput.destroy(),e.wrapper.empty(),e._buildHTML(),e._inputs.on(D+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(h,e._startChangeHandler),e._endChangeHandler=e._endChange.bind(e),e._endDateInput.bind(h,e._endChangeHandler),e._inputs.on("focus"+T,e._inputFocus.bind(e))},_buildHTML:function(){var t=this;var i=t.element;var r;t.wrapper||(t.wrapper=i.addClass("k-daterangepicker")),t.options.labels?(r=n.guid(),e('<span class="k-floating-label-container"><input data-input="start" id="'+r+'"/><label for="'+r+'" class="k-floating-label">'+n.htmlEncode(t.options.messages.startLabel)+"</label></span>").appendTo(t.wrapper),r=n.guid(),e('<span> </span><span class="k-floating-label-container"><input data-input="end" id="'+r+'"/><label for="'+r+'" class="k-floating-label">'+n.htmlEncode(t.options.messages.endLabel)+"</label></span>").appendTo(t.wrapper)):e('<input data-input="start" /><span> </span><input data-input="end" />').appendTo(t.wrapper),t._startInput=t.wrapper.find("input").eq(0),t._endInput=t.wrapper.find("input").eq(1),""!==t.options.startField&&(t._startInput.attr(n.attr("bind"),"value: "+t.options.startField),t._startInput.attr("name",t.options.startField)),""!==t.options.endField&&(t._endInput.attr(n.attr("bind"),"value: "+t.options.endField),t._endInput.attr("name",t.options.endField)),t._inputs=t._startInput.add(t._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(y,o).attr(k,r).attr(v,o),n._preventInputAction=!0):(n.wrapper.removeClass(b),e.each(i,(function(e,t){t.removeAttribute(y),t.removeAttribute(k)})),i.attr(v,!1),n._preventInputAction=!1)},destroy:function(){var e=this;e._startDateInput&&(e._startDateInput.unbind(h,e._startChangeHandler),e._startDateInput.destroy(),e._startChangeHandler=null),e._endDateInput&&(e._endDateInput.unbind(h,e._endChangeHandler),e._endDateInput.destroy(),e._endChangeHandler=null),e._startDateButton&&e._startDateButton.off(M,e._expandButtonClick),e._endDateButton&&e._endDateButton.off(M,e._expandButtonClick),e._startDateClear&&e._startDateClear.off(M,e._clearValue),e._endDateClear&&e._endDateClear.off(M,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._isAdaptive()||n._isAdaptive()&&n.options.autoClose)&&(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,h=d.abs,u=d.ceil,p=d.round,f=d.max,m=d.min,g=d.floor,v="change",_="click",b="refresh",w="primary",y="scrollview-page",k="function",x="itemChange",C=".ScrollView",S="keydown",T="focus",M="focusout",A="k-focus",D="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);var n=e-1;var i=n-1;var r=e;var o=t>0&&e+1>=t?-1:e+1;var 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=this.dataSource.view();var t;if(this.dataSource.options.pageSize>1){t=[];for(var n=0;n<e.length;n++)t.push(e[n])}else t=e[0];return t},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(w)))},_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=this;var n;var i;var r=t._current;var o=e.keyCode;o==a.LEFT&&(n=!0,(i=r.prev(".k-link")).length&&t._setCurrent(i)),o==a.RIGHT&&(n=!0,(i=r.next(".k-link")).length&&t._setCurrent(i)),e.keyCode!=a.SPACEBAR&&e.keyCode!=a.ENTER||(n=!0,t._current.trigger("click")),n&&(e.preventDefault(),e.stopPropagation())},_setCurrent:function(t){if(this._focused){var i=this;var r=n.guid();var 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;var 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(M+C,e._blur.bind(e)))},_refresh:function(e){var t="";var n;for(var i=0;i<e.pageCount;i++)t+='<span class="k-link" role="button" aria-label="'+this._ariaTemplate({index:i})+'" aria-pressed="false"></span>';this.element.html(t),(n=this.items().eq(e.page)).addClass(E(w)),n.attr("aria-pressed",!0),this.scrollView._toggleNavigation({currentPage:e.page})},_change:function(e){if(!e.isDefaultPrevented()){var t=this.scrollView._navigationContainer.find(".k-scrollview-nav");var i=this.scrollView.element.width();var r=(i-t.width())/2;var o=t.find(".k-link").eq(0).outerWidth(!0)/2;var a=this.items();var s;a.removeClass(E(w)),s=a.eq(e.nextPage).addClass(E(w)),a.attr("aria-pressed",!1),this._setCurrent(s),s.attr("aria-pressed",!0);var l=this.items().eq(e.nextPage).length>0?this.items().eq(e.nextPage).position().left:0;if(l>i/2||l<n.scrollLeft(t)+i/2){var c=0;c=l>i/2?n.scrollLeft(t)+l-i/2:n.scrollLeft(t)-(i/2-l),c+=r+o,t.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",L="dragStart",B="dragEnd";var H=n.Observable.extend({init:function(t,i){var a=this;var l,c,d,u,p,f;n.Observable.fn.init.call(this),this.element=t,this.container=t.parent(),l=new n.ui.Movable(a.element),c=new r({axis:"x",movable:l,onEnd:function(){a.trigger(P)}}),d=new n.UserEvents(t,{fastTap:!0,start:function(e){2*h(e.x.velocity)>=h(e.y.velocity)?d.capture():d.cancel(),a.trigger(L,e),c.cancel()},allowSelection:!0,end:function(e){a.trigger(B,e)}}),(p=(u=new s({element:a.element,container:a.container})).x).bind(v,(function(){a.trigger(v)})),f=new o({dimensions:u,userEvents:d,movable:l,elastic:!0}),e.extend(a,{duration:i&&i.duration||1,movable:l,transition:c,userEvents:d,dimensions:u,dimension:p,pane:f}),this.bind([P,L,B,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=H;var R=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,h=t?r.easeOutBack:r.easeOutExpo;if(-1===e?d=u: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,h,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,h,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=R;var F=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(){var e,t=this.pages,n=this.element;for(var i=0;i<3;i++)e=new O(n),t.push(e);this.pane.updateDimension()},resizeTo:function(e){var t=this.pages,n=this.pane;for(var 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;var 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,h=d.size().width,u=d.offset(),p=Math.abs(u)>=h/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?u>0&&p&&!m?g=1:u<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 h(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=u(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;var 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=F;var O=n.Class.extend({init:function(t){this.element=e("<li class='"+E(y)+"'></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 H(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 F(r.inner,r.pane,i):new R(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;var t=this.options;e.resizeTo(this.pane.size()),this.page=e.page,(e instanceof R||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 F?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 F?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 F){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-"+y)},_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;var r=i._content.page;n.guid();var o=i.itemsWrapper.children();var 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=h(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=this;var i;var r;var o=t.options.messages;var a=t._navigationContainer=e("<div class='k-scrollview-elements'></div>");var s=t.itemsWrapper;var l=s.attr("id")||n.guid();s.attr("id",l),i=e(`<span class="k-scrollview-prev" role="button" aria-label="${o.previousButtonLabel}" aria-controls="${l}">${n.ui.icon({icon:"chevron-left",size:"xxxlarge"})}</span>`),r=e(`<span class="k-scrollview-next" role="button" aria-label="${o.nextButtonLabel}" aria-controls="${l}">${n.ui.icon({icon:"chevron-right",size:"xxxlarge"})}</span>`),i.hide(),r.hide(),a.append(i),a.append(r),t.element.append(a),t.ariaLiveEl=e("<div aria-live='polite' aria-atomic='true' class='k-sr-only'></div>"),t.element.append(t.ariaLiveEl),a.on(_+C,"span.k-scrollview-prev",t.prev.bind(t)),a.on(_+C,"span.k-scrollview-next",t.next.bind(t))},_navigatable:function(){var t=this;var 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(D,0),i.find(">span.k-scrollview-next").attr(D,0),t.element.on(S+C,t,t._keyDown.bind(t)),t.element.on(T+C,t._focus.bind(t)),t.element.on(M+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;var 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;var n=this._navigationContainer;var i=n.find(">span.k-scrollview-prev");var 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;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]){var o=n[i]=n[i]||[];for(var a=0;a<r.length;a++)o.push(r[a]),e(i+1,r[a])}}(0,e),n}function h(e,n){return e.length?'<table role="presentation" class="'+t.trim("k-scheduler-table "+(n||""))+'"><tr>'+e.join("</tr><tr>")+"</tr></table>":""}var u=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 g(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(){var e=[this._timeSlotCollections||[],this._daySlotCollections||[]];for(var t=0;t<e.length;t++){var n=e[t];for(var 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++){var o=n[r];for(var a=0;a<o.count();a++){var s=o.at(a);var l=s.offsetWidth;var c=s.offsetHeight;var d;var h=s.offsetLeft+l;var u=s.offsetTop+c;if(i||(d=o.at(a+1)),d&&(d.offsetLeft!=s.offsetLeft?h=this._isRtl?s.offsetLeft+(s.offsetLeft-d.offsetLeft):d.offsetLeft:u=d.offsetTop),e>=s.offsetLeft&&e<h&&t>=s.offsetTop&&t<u)return s}}},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=this._timeSlotCollections;var r=this._startSlot(e,i);var o,a;!r.inRange&&e>=r.slot.end&&(o=r.slot.collectionIndex+1,r=null);var s=r;if(e<n&&(s=this._endSlot(n,i)),s&&!s.inRange&&n<=s.slot.start&&(a=s.slot.collectionIndex,n===s.slot.start&&(r&&a>r.slot.collectionIndex||a>o)&&(a-=1),s=null),null===r&&null===s){if(n-e<t.date.MS_PER_DAY)return[];r={inRange:!0,slot:i[o].first()},s={inRange:!0,slot:i[a].last()}}if(null===r){if(s.slot.end<=e)return[];r={inRange:!0,slot:(i[o]||i[s.slot.collectionIndex]).first()}}if(null===s){if(r.slot.start>=n)return[];s={inRange:!0,slot:(i[a]||i[r.slot.collectionIndex]).last()}}return this._continuousRange(f,i,r,s)},daySlotRanges:function(e,n,i){var r=this._daySlotCollections;var 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(m,r,o,a)},_continuousRange:function(e,t,n,i){var r=n.slot;var o=i.slot;var a=r.collectionIndex;var s=o.collectionIndex;var l=[];for(var c=a;c<=s;c++){var d=t[c];var h=d.first();var u=d.last();var p=!1;var f=!1;c==a&&(f=!n.inRange),c==s&&(p=!i.inRange),h.start<r.start&&(h=r),u.start>o.start&&(u=o),a<s&&(c==a?p=!0:c==s?f=!0:p=f=!0),l.push(new e({start:h,end:u,collection:d,head:p,tail:f}))}return l},slotRanges:function(e,n){var i=e._startTime||t.date.toUtcTime(e.start);var 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;var 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;var r=e.isDaySlot;var o=e.collectionIndex;var 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;var o=e.isDaySlot;var a=e.collectionIndex;var 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);var r=!0;var 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);var r=!0;var 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]}});var p=t.Class.extend({init:function(t){e.extend(this,t)},innerHeight:function(){var e=this.collection;var t=this.start.index;var n=this.end.index;var i=0;for(var 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}});var f=p.extend({innerHeight:function(){var e=this.collection;var t=this.start.index;var n=this.end.index;var i=0;for(var 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;var a;var s;var l;var c=this.start;var d=this.end;var h=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"],h?(s=d.offsetLeft,l=c.offsetLeft+c[e+"Width"]):(s=c.offsetLeft,l=d.offsetLeft+d[e+"Width"]);else{var u=n-c.start;u<0&&(u=0);var p=c.end-c.start;o=c.offsetTop+c[e+"Height"]*u/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,h?(s=Math.round(d.offsetLeft+d[e+"Width"]*f/m),l=Math.round(c.offsetLeft+c[e+"Width"]-c[e+"Width"]*u/p)):(s=Math.round(c.offsetLeft+c[e+"Width"]*u/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)}});var m=p.extend({innerWidth:function(){var e=this.collection;var t=this.start.index;var n=this.end.index;var i=0;var r=t!==n?"offsetWidth":"clientWidth";for(var o=t;o<=n;o++)i+=e.at(o)[r];return i}});var g=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 _(e,t,n,this._groupIndex,this._collectionIndex,this._slots.length,i);this._slots.push(r)},addDaySlot:function(e,t,n,i){var r=new b(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]}});var v=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}});var _=v.extend({init:function(e,t,n,i,r,o,a){v.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=e(this.element).offset();var a=this.end-this.start;var s;var l;if(this.isHorizontal){var c=t.support.isRtl(this.element);if(s=n-o.left,l=Math.floor(a*(s/this.offsetWidth)),c)return this.start+a-l}else s=i-o.top,l=Math.floor(a*(s/this.offsetHeight));return this.start+l},endOffset:function(n,i,r){if(r)return this.end;var o=e(this.element).offset();var a=this.end-this.start;var s;var l;if(this.isHorizontal){var c=t.support.isRtl(this.element);if(s=n-o.left,l=Math.floor(a*(s/this.offsetWidth)),c)return this.start+a-l}else s=i-o.top,l=Math.floor(a*(s/this.offsetHeight));return this.start+l}});var b=v.extend({init:function(e,t,n,i,r,o,a){if(v.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=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 u(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=this.groups[e.groupIndex];var r,o;if(n){if(r=i._getCollections(!1),(o=i.daySlotCollectionCount()?t.index-1:t.collectionIndex-1)>=0)return r[o]._slots[r[o]._slots.length-1]}else{r=i._getCollections(i.daySlotCollectionCount()),o=i.daySlotCollectionCount()?0:t.collectionIndex+1;var a=i.daySlotCollectionCount()?t.collectionIndex+1:0;if(r[o]&&r[o]._slots[a])return r[o]._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=i?"leftSlot":"rightSlot";var o={startSlot:t[0].start,endSlot:t[t.length-1].end};var a=this.groups[e.groupIndex];var s=this._isVerticallyGrouped();if(!n){var l=this._normalizeHorizontalSelection(e,t,i);l&&(o.startSlot=o.endSlot=l)}if(this._isGroupedByDate()&&!n){var c=this._changeGroup(e,i);c?o.startSlot=o.endSlot=c:o=this._getNextHorizontalRange(a,r,o)}else o.startSlot=a[r](o.startSlot),o.endSlot=a[r](o.endSlot),n||s||o.startSlot&&o.endSlot||(o.startSlot=o.endSlot=this._changeGroup(e,i));var d;return o.startSlot&&o.endSlot||this._isGroupedByDate()||(d=this._continuousSlot(e,t,i),(d=this._changeGroupContinuously(e,d,n,i))&&(o.startSlot=o.endSlot=d)),o},_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=this.groups[e.groupIndex];var o;var a={startSlot:t[0].start,endSlot:t[t.length-1].end};n||(o=this._normalizeVerticalSelection(e,t,i))&&(a.startSlot=a.endSlot=o);var s=i?"upSlot":"downSlot";return a=this._getNextVerticalRange(r,s,a,n),n||!this._isVerticallyGrouped()||a.startSlot&&a.endSlot||(this._isGroupedByDate()?a.startSlot=a.endSlot=this._changeDate(e,o,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=this;var i=n.options;var r=n.options.timezone;var o=new Date;var a;if(r){var s=t.timezone.offset(o,r);a=t.timezone.convert(o,o.getTimezoneOffset(),s)}else a=o;n.trigger("navigate",{view:n.name||i.name,action:"today",date:a})},_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=this.groups[0];var n;this.inRange(e)?t.daySlotCollectionCount()?t.timeSlotCollectionCount()||(e.isAllDay=!0):e.isAllDay=!1:(n=t.firstSlot(),e.isAllDay=n.isDaySlot,e.start=n.startDate(),e.end=n.endDate()),this.groups[e.groupIndex]||(e.groupIndex=0)},move:function(e,t,n){var i=!1;var r=this.groups[e.groupIndex];var o=this._isGroupedByDate()&&this._isVerticallyGrouped();r.timeSlotCollectionCount()||(e.isAllDay=!0);var s=r.ranges(e.start,e.end,e.isAllDay,!1);var l,c,d,h;if(t===a.DOWN||t===a.UP){if(i=!0,d=t===a.UP,this._updateDirection(e,s,n,d,!0),!(h=this._verticalSlots(e,s,n,d)).startSlot&&!n&&this._changeViewPeriod(e,d,!o))return i}else if((t===a.LEFT||t===a.RIGHT)&&(i=!0,d=t===a.LEFT,this._updateDirection(e,s,n,d,!1),!(h=this._horizontalSlots(e,s,n,d)).startSlot&&!n&&this._changeViewPeriod(e,d,o)))return i;if(i){if(l=h.startSlot,c=h.endSlot,n){var u=e.backward;u&&l?e.start=l.startDate():!u&&c&&(e.end=c.endDate())}else l&&c&&(e.isAllDay=l.isDaySlot,e.start=l.startDate(),e.end=c.endDate());e.events=[]}return i},moveToEventInGroup:function(t,n,i,r){var o=t._continuousEvents||[];var a;var s=r?-1:1;var l=o.length;var c=r?l-1:0;var d,h;if(i.length)if(h=i[i.length-1],r)for(d=0;d<o.length;d++)o[d].uid===h&&(c=d+s);else for(d=o.length-1;d>-1;d--)o[d].uid===h&&(c=d+s);for(;c<l&&c>-1;){if(a=o[c],(!r&&a.start.startDate()>=n.startDate()||r&&a.start.startDate()<=n.startDate())&&a&&-1===e.inArray(a.uid,i)){0;break}c+=s}return a},moveToEvent:function(e,t){var n=e.groupIndex;var i=this.groups[n];var r=i.ranges(e.start,e.end,"month"===this.name||e.isAllDay,!1)[0].start;var o=this.groups.length;var a=t?-1:1;var s=e.events;var l;if(this._isGroupedByDate()){var c=this._getAllEvents();var d=this._getUniqueEvents(c);var h=this._getSortedEvents(d);if(0===s.length){var u=this._getNextEventIndexBySlot(r,h,n);t&&u--,l=h[u]}else{var p=this._getStartIdx(s,h);for(;p<h.length&&p>-1&&(s.length>0&&(r=this._getSelectedSlot(r,h,l,p,a,t)),r);){if((!t&&h[p].start.startDate()>=r.startDate()||t&&h[p].start.startDate()<=r.startDate())&&s[0]!=h[p].uid){l=h[p];break}p+=a}}}else for(;n<o&&n>-1&&(l=this.moveToEventInGroup(i,r,s,t),n+=a,(i=this.groups[n])&&!l);)s=[],r=t?i.lastSlot():i.firstSlot(!0);return l&&(e.events=[l.uid],e.start=l.start.startDate(),e.end=l.end.endDate(),e.isAllDay=l.start.isDaySlot,e.groupIndex=l.start.groupIndex,e.eventElement=l.element[0]),!!l},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){var r=0;var o=t.date.getDate(e.startDate());for(var 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;var 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(){var e=[];var t=this.groups;for(var n=0;n<t.length;n++)t[n]._continuousEvents&&(e=e.concat(t[n]._continuousEvents));return e},_getUniqueEvents:function(e){var t=[];for(var n=0;n<e.length;n++){var i=!1;for(var 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();var o=i.start.startDate();var 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;var n=this.groups[e.groupIndex];n.timeSlotCollectionCount()||(t=!0),this._selectedSlots=[];var i=n.ranges(e.start,e.end,t,!1);var r;var o;for(var a=0;a<i.length;a++){var s=i[a];var l=s.collection;for(var c=s.start.index;c<=s.end.index;c++)r=(o=l.at(c)).element,(d=r).className=d.className.replace(S,"")+" k-selected",this._selectedSlots.push({start:o.startDate(),end:o.endDate(),element:r})}var d;e.backward&&(r=i[0].start.element),this.current(r)},_selectEvents:function(t){var n=!1;var i=t.events;var r=this._getAllEvents();var o,a,s=r.length;if(!i[0]||!r[0])return n;var l=e();for(t.events=[],o=0;o<s;o++)e.inArray(r[o].uid,i)>-1&&(a=r[o],l=l.add(a.element),-1===t.events.indexOf(a.uid)&&t.events.push(a.uid));return l[0]&&(l.addClass("k-selected"),t.eventElement?this.current(t.eventElement):this.current(l.last()[0]),this._selectedSlots=[],n=!0),n},inRange:function(e){var n=this.startDate();var i=t.date.addDays(this.endDate(),1);var r=e.start;var 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;var 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,h=l.date&&"horizontal"===l.orientation?1:0,u=d[t.length-1+h],p=t[t.length-1],f=u[s];for(this._setResourceValue(f,p,n),o=t.length-2;o>=0;o--)for(u=d[o+h],p=t[o],i=0,a=0;a<u.length;a++){if((r=(f=u[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");var n=new y(t).isDark();var i=e.css("background-color");n==new y(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];var a=o.field;var s=t.getter(a)(e);if(null!=s){o.multiple||(s=[s]);var l=o.dataSource.view();for(var c=0;c<s.length;c++){var d=null;var h=s[c];o.valuePrimitive||(h=t.getter(o.dataValueField)(h));for(var u=0;u<l.length;u++)if(l[u].get(o.dataValueField)==h){d=l[u];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:h,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");var 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=e[e.length-2];var n=this.cachedRowLevels||[];var i;this._hasContentToRender=!0;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)};for(var o=e.length-2;o>=0;o--){var a=!1;if(o>0&&r(e,o)&&(a=!0,i=o),n[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 n[e.length-1]=e[e.length-1].splice(t[0].rows.length),this.cachedRowLevels=n,n[n.length-1].length||(this._hasContentToRender=!1),{levelMarker:i||0,rowLevels:e}},createNextLayout:function(){var e=[];var t;var n;var i;var r;for(var o=0;o<this.cachedRowLevels.length;o++)e[o]=this.cachedRowLevels[o];n=(t=this._trimRowLevels(e)).rowLevels.splice(t.levelMarker),i=t.levelMarker,r=n[n.length-1].length,delete this._height;for(var a=i;a<this.rowLevels.length;a++)this.rowLevels[a]=this.rowLevels[a].concat(n[a-i]);if(this.table.find(".k-scheduler-times").last().find("tbody").append(this._times(n,r,this._isMobile()).find("tr")),this._updateDomRowLevels(),i>0)for(a=0;a<i;a++){var s=this.table.find("[data-row-level="+a+"]").last();var l=parseInt(s.attr("rowspan"),10)+r;s.attr("rowspan",l)}this._virtualContent(n,this.columnLevels),this.render(this._cachedEvents)},_tryRenderContent:function(){var e=this;var t=e.table.innerHeight();var n=e.content.find("table").innerHeight();var i=e.content.scrollTop();for(;e._hasContentToRender&&n-t<i;)e.createNextLayout(),n=e.content.find("table").innerHeight()},_isSchedulerHeightSet:function(){var e=this.element;var t;return!!e[0].style.height||(t=e.height(),e.height("auto"),t!=e.height()?(e.height(""),!0):(e.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(){var n=this,i=n.element.find("> .k-scheduler-toolbar"),r=n.element.innerHeight(),a=n._scrollbar=t.support.scrollbar(!0),s=0,l=this._isRtl?"left":"right";for(var 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 h=n.content[0],u=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(h.clientHeight);var p=n.times.find("table");p.length&&p.height(n.content.find("table")[0].clientHeight)}n.table&&(h.offsetWidth-h.clientWidth>0?(n.table.addClass("k-scrollbar-v"),n.datesHeader.css("padding-"+l,u-parseInt(n.datesHeader.children().css("border-"+l+"-width"),10))):n.datesHeader.css("padding-"+l,"0"),h.offsetHeight-h.clientHeight>0||h.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'>​</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">'+h(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=[];var t=this.options.group;var 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 x("rows",e,t,n)},_createColumnsLayout:function(e,t,n,i,r,o){return C("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 C("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;var r=this.groups[t];var 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;var r=this.groups[t];var o=r.ranges(e,e,n,!1)[0].start;var a;if(!(t>=this.groups.length-1))return this._isGroupedByDate()?o:this._isVerticallyGrouped()?r.timeSlotCollectionCount()?(a=r.daySlotCollectionCount(),i=r._collection(a?0:o.collectionIndex,a),n?i.first():i.at(o.collectionIndex)):(i=r._collection(0,!0)).at(o.index):r.timeSlotCollectionCount()?(i=r._collection(0,n),n?i.first():i.at(o.index)):(i=r._collection(o.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){var r=new Array(n).join().split(",");var o=[];var a;for(var s=0;s<t.length;s++){var l=t[s];var c=0;for(a=0;a<l.length;a++){var d=l[a];var u=d.className||"";var p=d.text;var f=this._innerElements(d,"rows");c+=f,d.allDay&&(u="k-scheduler-times-all-day"),i&&-1!==u.indexOf("k-group-cell")&&(p='<span class="k-scheduler-group-text">'+p+"</span>"),r[c-f]+='<th class="k-scheduler-cell '+u+'" rowspan="'+f+'">'+p+"</th>"}}for(a=0;a<n;a++)o.push(r[a]);return n<1?e():e('<div class="k-scheduler-times">'+h(o)+"</div>")},_datesHeader:function(n,i){var r=[];var o;var a;for(var s=0;s<n.length;s++){var l=n[s];var c=[];for(o=0;o<l.length;o++){var d=l[o];var u=this._innerElements(d,"columns","colspan");c.push('<th colspan="'+(d.colspan||u)+'" class="k-scheduler-cell '+(d.className||"")+'">'+d.text+"</th>")}r.push(c.join(""))}var p=[];if(i){var f=n[n.length-1];var m=[];var g=i.cellContent;for(o=0;o<f.length;o++)m.push('<td class="k-scheduler-cell '+(f[o].className||"")+'">'+(g?g(o):" ")+"</td>");p.push(m.join(""))}var v,_;return a=e('<div class="k-scheduler-header"><div class="k-scheduler-header-wrap">'+h(r)+(_="k-scheduler-header-all-day",((v=p).length?`<div ${t.attr("style-position")}="relative">${h(v,_)}</div>`:"")+"</div></div>")),t.applyStylesFromKendoAttributes(a,["position"]),a},_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 y=function(e){var t,n,i,r,o,a=this,s=y.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 k(e){var t=[];for(var n=0;n<e.length;n++){var i=e[n];var r=w(i);var 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 x(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";var s={text:n.text,className:a};r&&!n.minorTicks?s[t]=x(t,n.columns,i,r):s[t]=i,o.push(s)})),o}function C(n,i,r,o,a,s,l){var c=i[0];var d=[];if(c){if(a&&r)e.each(a,(function(e,t){s&&!t.minorTicks?t[n]=C(n,i,t.columns,o,t.columns,s,l):t[n]=C(n,i,null,o,null,null,l)})),d=a;else{var h=c.dataSource.view();h=h.filter((function(e){var n=t.getter(c.dataParentValueField)(e);return null==n||n===l}));for(var u=0;u<h.length;u++){var p=t.getter(c.dataValueField)(h[u]);var f={text:o({text:t.htmlEncode(t.getter(c.dataTextField)(h[u])),color:t.getter(c.dataColorField)(h[u]),field:c.field,title:c.title,name:c.name,value:p}),className:"k-slot-cell k-group-cell",parentValue:l,value:p};f[n]=C(n,i.slice(1),r,o,a,s,p),d.push(f)}}return d}return r}y.prototype={resolveColor:function(e){return"#"==(e=e||"#000").charAt(0)&&(e=e.substr(1,6)),e=(e=e.replace(/ /g,"")).toLowerCase(),e=y.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}},y.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)]}}],y.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 S=/\s*k-selected/;e.extend(n.SchedulerView,{createColumns:function(e){return k(e)},createRows:function(e){return k(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){var i=[];for(var 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,h=n.date.MS_PER_MINUTE,u=n.date.MS_PER_DAY,p="k-current-time",f="k-current-time-arrow",m="k-event-inverse",g=n.date.getMilliseconds,v=".kendoMultiDayView";var _=n.template((({start:e,end:t,title:i})=>`<div title="(${n.format("{0:t} - {1:t}",e,t)}): ${i.replace(/"/g,""")}"><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,""")}"><div class="k-event-template">${t}</div></div>`)),w=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>`)),y=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;var a=o[o.length-1];var s=d(t.start.startDate()).getTime();if(r&&a&&d(a.start.startDate()).getTime()==s){var l=o.length-1;for(;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 M=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=[];var n=e.workWeekStart%7;var 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 h=c.dataSource.options.schema.timezone;if(c.dataSource&&h){var u=n.timezone.offset(t,h);t=n.timezone.convert(t,t.getTimezoneOffset(),u)}}i=this.times.find("."+p),r=this.content.find("."+p);var m=c.group&&"horizontal"!=c.group.orientation?this.groups.length:1;var g=this.times.find("tr").first().find("th").first();var 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 w=n.date.toUtcTime(t);var y=b.timeSlotRanges(w,w+1);if(0===y.length)return;if(y[0].collection.slotByStartDate(t)){var k=i[_]?i.eq(_):e(d).prependTo(this.times);var x=Math.round(y[0].innerRect(t,new Date(t.getTime()+1),!1).top);var 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;var 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=this.groups[t].ranges(i,r,o,e.isAllDay);var l,c,d,h;this._removeResizeHint();for(var u=0;u<s.length;u++){var p=s[u];var f=p.startSlot();if(this._isGroupedByDate()&&o)for(var m=f.index;m<=p.end.index;m++){var g=p.collection._slots[m];l=g.offsetWidth,c=g.clientHeight,d=g.offsetTop,h=a.fn._createResizeHint.call(this,g.offsetLeft,d,l,c),this._resizeHint=this._resizeHint.add(h)}else{if(l=f.offsetWidth,c=f.clientHeight,d=f.offsetTop,o)l=p.innerWidth();else{var v=p.outerRect(i,r,this.options.snap);d=v.top,c=v.bottom-v.top}h=a.fn._createResizeHint.call(this,f.offsetLeft,d,l,c),this._resizeHint=this._resizeHint.add(h)}}var _="t";var 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];var s=n.date.toUtcTime(t.start)+r;var l=s+t.duration();var 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();var d=e();for(var h=0;h<c.length;h++){var u=c[h];var p=u.start;var f;var v={left:p.offsetLeft+2,top:p.offsetTop};if(this._isGroupedByDate()&&o)for(var _=p.index;_<=u.end.index;_++){var b=u.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,f=this._createEventElement(t.clone({start:s,end:l}),!o),t.inverseColor&&f.addClass(m),this._appendMoveHint(f,v),d=d.add(f)}else{if(this._isRtl&&(v.left=.1*p.clientWidth+p.offsetLeft+2),o)v.width=u.innerWidth()-2;else{var w=u.outerRect(s,l,this.options.snap);v.top=w.top,v.height=w.bottom-w.top,v.width=.9*p.clientWidth-2}f=this._createEventElement(t.clone({start:s,end:l}),!o),t.inverseColor&&f.addClass(m),this._appendMoveHint(f,v),d=d.add(f)}}var y=this.content;o&&((y=this.element.find(".k-scheduler-header-wrap:has(.k-scheduler-header-all-day) > div")).length||(y=this.content)),d.appendTo(y)},_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;var 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;var 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;var 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=this._timeSlotInterval();var i=e;var r=this._isGroupedByDate();var o=this.content.find("tr:not(.k-scheduler-header-all-day)");var a,s,l,c;var d=o.length;this._isVerticallyGrouped()&&(r&&(i=t),d=Math.floor(d/i));for(var h=0;h<i;h++){var u=0;var p=0;for(this._isVerticallyGrouped()?u=h:p=h,l=u*d;l<(u+1)*d;){var f=o[l].children;l%d==0&&(s=g(new Date(+this.startTime())));var m=0;if(r)if(this._isVerticallyGrouped())for(c=0;c<e;c++)a=this.groups[c],this._addTimeSlotGroup(a,f,c,s,n,h);else for(a=this.groups[h],c=p;c<e*t;c+=e)this._addTimeSlotGroup(a,f,c,s,n,m),m++;else for(a=this.groups[h],c=p*t;c<(p+1)*t;c++)this._addTimeSlotGroup(a,f,c,s,n,m),m++;s+=n,l++}}},_addTimeSlotGroup:function(e,t,n,i,r,o){var a=t[n];var s=e.getTimeSlotCollection(o);var l=this._dates[o];if(l&&a){var c=Date.UTC(l.getFullYear(),l.getMonth(),l.getDate())+i;var d=c+r;s.addTimeSlot(a,c,d)}},_addDaySlotGroup:function(e,t,i,r,o){var a=t[i];var 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;var r=e;var 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=0;var l;this._isVerticallyGrouped()&&(s=a);var c=n[s].children;var d=0;this._isVerticallyGrouped()||(d=a);var h=0;if(o)if(this._isVerticallyGrouped())for(i=0;i<e;i++)l=this.groups[i].getDaySlotCollection(0),this._addDaySlotGroup(l,c,i,t,a);else for(l=this.groups[a].getDaySlotCollection(0),i=d;i<e*t;i+=e)this._addDaySlotGroup(l,c,i,t,h),h++;else for(l=this.groups[a].getDaySlotCollection(0),i=d*t;i<(d+1)*t;i++)this._addDaySlotGroup(l,c,i,t,h),h++}},_groups:function(){var e=this._groupCount();var t=this._columnCountInResourceView();this.groups=[];for(var i=0;i<e;i++){var r=this._addResourceView(i);for(var 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:()=>"​",groupHeaderTemplate:({text:e})=>e,slotTemplate:()=>" ",allDaySlotTemplate:()=>" ",eventTemplate:_,allDayEventTemplate:b,dateHeaderTemplate:w,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(y),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;var 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;var o=n.y.location!==t?n.y.location:n.y;var 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;var o=e.y.location!==t?e.y.location:e.y;var 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){var t=[];var i=[];var r=this.options;var o=this;var a=o._isGroupedByDate();for(var 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*h,p=d/c||1,f=new Date(+e),m=f.getDate(),v=0,_="";for(a=u/p,s!=l&&(s>l&&(l+=u),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+=u),r>l&&(f=new Date(+t))),i&&(_+=i(f)),_},_content:function(e){var t=this;var 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;var i="";var r=n._dates;i+=n._renderRows(r,e,t),n.content.find("table tbody").append(i)},_renderRows:function(e,t,n){var i=this;var r="vertical"===i._groupOrientation();var o=i._isGroupedByDate();var a=0;var s=e.length;var l=i.options;var c=i.startTime();var d=this.endTime();var h=1;var u=1;var p="";if(this.groupedResources.length){var f=i._recalculateLevels(t,n);u=f.rowCount,h=f.groupsCount}var m=function(t,n,l){var c="";var d=0;var u,p;if(c="<tr"+(l?' class="k-middle-row"':"")+">",o)for(u=0,p=s;u<p;u++){for(d=0;d<h;d++){var f=u;r&&(f=a),c=i._addCellsToContent(c,e,t,f,d,g)}if(r)break}else for(;d<h;d++)for(u=0,p=s;u<p;u++)c=i._addCellsToContent(c,e,t,u,d,g);return c+="</tr>"};for(var g=0;g<u;g++)p+=l.allDaySlot&&r?this._allDayVerticalGroupRow(e,g,h,a):"",p+=this._forTimeRange(c,d,m),r&&a++;return p},_recalculateLevels:function(e,t){var n=this;var i=n._isGroupedByDate();var r=1;var 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;var o='<tr class="k-scheduler-header-all-day">';var a=r._isGroupedByDate();var s=a?0:t;var l=r.allDaySlotTemplate;var 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=this;var l="";var c;var d=this.slotTemplate;var h="vertical"===this._groupOrientation();var u;return n.date.isToday(t[r])&&(l+="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]))&&(l+=" k-nonwork-hour"),e+="<td"+(""!==l?' class="'+l+'"':"")+">",c=n.date.getDate(t[r]),n.date.setTime(c,n.date.getMilliseconds(i)),e+=d({date:c,resources:(u=h&&!s._isGroupedByDate()?a:o,function(){return s._resourceBySlot({groupIndex:u})})}),e+="</td>"},_isWorkDay:function(e){var t=e.getDay();var n=this._workDays;for(var 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");var r=i.offset();var o=0;var 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())||u;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());var r=g(this.endTime())||n.date.MS_PER_DAY;var o=g(e.start);var s=g(e.end)||n.date.MS_PER_DAY;return t&&i<=o&&s<=r},selectionByElement:function(e){var t=e.offset();var 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*h},_timeSlotIndex:function(e){var t=this.options;return(g(e)-g(this.startTime()))/(t.majorTick/t.minorTickCount*h)},_slotIndex:function(e,t){return t?this._dateSlotIndex(e):this._timeSlotIndex(e)},_dateSlotIndex:function(e,t){var i;var r;var 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()+u-(t?0:1))))return 1*i;return-1},_positionAllDayEvent:function(t,n){var i=n.innerWidth();var r=n.start.index;var o=n.end.index;var s=a.collidingEvents(n.events(),r,o);var l=this._headerColumnCount||0;var c=r!==o?3:2;var d=this._allDayHeaderHeight;var h=n.startSlot();t.css({left:h.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 u=a.createRows(s);u.length&&u.length>l&&(this._headerColumnCount=u.length);var p=n.start.offsetTop;for(var f=0,m=u.length;f<m;f++){var g=u[f].events;for(var 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(),h=a.collidingEvents(d,e.start,e.end),u=this.table.find(".k-scheduler-content .k-scheduler-table")[0],p=this.table.find(".k-scheduler-content")[0];i.addEvent(e),h.push(e);var f=(l-c)/(o=a.createColumns(h)).length;for(var 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-(u.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;var o=e._endTime||e.end;var a=n.getComputedStyles(i.start.element,["border-top-width","border-bottom-width"]);var s=i.innerRect(r,o,!1);var 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=i?this.eventTemplate:this.allDayEventTemplate;var s=this.options;var l=s.editable;var h=this._isMobile();var p=l&&!1!==l.destroy&&!h;var f=l&&!1!==l.resize;var m=d(this.startDate());var v=d(this.endDate());var _=g(this.startTime());var b=g(this.endTime());var w=t._time("start");var y=t._time("end");var k=i?s.eventTemplate:s.allDayEventTemplate;var x;_>=b&&(b=g(new Date(this.endTime().getTime()+u-1))),i||t.isAllDay||(v=new Date(v.getTime()+u));var S=t.start;var T=t.end;t.isAllDay&&(T=d(t.end)),!C(d(S),m,v)&&!C(T,m,v)||i&&t.start.getTime()!==t.end.getTime()&&(w<_||w>=b)&&(y>b||y<=_)?x=!0:d(S)<m||i&&0!==w&&t.start.getTime()!==t.end.getTime()&&(w<_||w>=b)?o=!0:(T>v&&!i||i&&0!==y&&t.start.getTime()!==t.end.getTime()&&(y>b||y<=_))&&(r=!0);var M=this.eventResources(t);t._startTime&&w!==n.date.getMilliseconds(t.start)&&(S=new Date(w),S=n.timezone.apply(S,"Etc/UTC")),t._endTime&&y!==n.date.getMilliseconds(t.end)&&(T=new Date(y),T=n.timezone.apply(T,"Etc/UTC"));var A=c({},{ns:n.ns,resizable:f,showDelete:p,middle:x,head:r,tail:o,singleDay:1==this._dates.length,resources:M,inverseColor:!1,messages:s.messages,ariaLabel:this._formatEventAriaLabel(t.title,S,T,t.isAllDay),template:k},t,{start:S,end:T});var D=e(a(A));return n.applyStylesFromKendoAttributes(D,["background-color","border-color"]),D},_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,u-1)),e._date("end")>e._date("start")&&(a=+e._date("end")+(u-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];var i=t.firstSlot().start;var r=t.lastSlot().end-1;var o=n.date.toUtcTime(e.start);var 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=this.datesHeader.find(".k-scheduler-header-wrap > div");var r=this._isGroupedByDate();var o;var a;var s;for(a=0,s=e.length;a<s;a++){var l,c,d,h,p,f,m,g;if(o=e[a],this._isInDateSlot(o))if(c=(l=this.options.enforceAllDaySlot?o.isAllDay||o.duration()>=u:o.isAllDay)&&!this._isVerticallyGrouped()?i:this.content,l){if(this.options.allDaySlot){if(!(g=this.groups[t]))continue;if(g._continuousEvents||(g._continuousEvents=[]),(h=g.slotRanges(o)).length){var v=(p=h[0]).start.index;var _=p.end.index;if(r&&v!==_){f=p.start.start,m=p.end.end;var b=f;var w=f;for(var y=p.start.index;y<=p.end.index;y++){d=this._createEventElement(o,!l,y!==_,y!==v);var k=g.daySlotRanges(b,w,!0)[0];b=w+=n.date.MS_PER_DAY,this._positionAllDayEvent(d,k),T(g,k,d,!0),d.appendTo(c),this._inverseEventColor(d)}}else d=this._createEventElement(o,!l),this._positionAllDayEvent(d,h[0]),T(g,h[0],d,!0),d.appendTo(c),this._inverseEventColor(d)}}}else if(this._isInTimeSlot(o)){if(!(g=this.groups[t]))continue;g._continuousEvents||(g._continuousEvents=[]);var x=(h=g.slotRanges(o)).length;for(var C=0;C<x;C++){p=h[C],f=o.start,m=o.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=o.clone({start:f,end:m,_startTime:o._startTime,_endTime:o.endTime});if(this._isInTimeSlot(S)){var M=p.head;(d=this._createEventElement(o,!l,M,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))}));var 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]);var h=new n.data.Query(e).filter({field:s.field,operator:a.groupEqFilter(d)}).toArray();i.length>1?this._eventsByResource(h,i.slice(1),r,d):r.push(h)}}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;var a=t[0].start;var 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=t?this.previousDate():this.nextDate();var r=e.start;var a=e.end;var s=this._isGroupedByDate()&&this._isVerticallyGrouped();var l=this.groups[e.groupIndex];var c=t?l._timeSlotCollections:l._getCollections(l.daySlotCollectionCount());var d=c[c.length-1]._slots;var h=t||l.daySlotCollectionCount()?d.length-1:0;var p;var f,m;if(f=new Date(i),m=new Date(i),this._isInRange(f,m))return!1;if(e.start=f,e.end=m,s){var v=new Date(d[h].startDate());var _=new Date(d[h].endDate());p=g(_)?g(_):u,o(e.start,g(v)),o(e.end,p),l.daySlotCollectionCount()&&(e.isAllDay=!e.isAllDay)}else p=e.isAllDay||!g(a)?u:g(a),o(e.start,g(r)),o(e.end,p);return this._isVerticallyGrouped()||(e.groupIndex=t?this.groups.length-1:0),e.events=[],!0}}});c(!0,i,{MultiDayView:M,DayView:M.extend({options:{name:"DayView",title:"Day",selectedMobileDateFormat:"{0:MMM d}"},name:"day"}),WeekView:M.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:M.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);var 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";var 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>";var 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;var 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))}});var 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);var 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){var n=[];var i=null;for(var 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{var s=n[a][n[a].length-1]-1;for(var l=0;l<s;l++)n[a].push(0);n[a].push(1)}i=t[r]}return n},_getSumOfItemsForDate:function(e){var t=0;for(var 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;var 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 h=0;h<n[i].length;h++)o[h][l]&&e.push(t.format('<td class="k-scheduler-groupcolumn" rowspan="{0}">{1}</td>',o[h][l],c._groupTemplate({value:n[i][h].text,isMobile:d}),n[i][h].className))}},_renderDateCell:function(){},_renderDates:function(e){var t=this._view;var n=t._groupsByDate.sort((function(e,t){return e.array[0].value.getTime()-t.array[0].value.getTime()}));for(var 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++){var o=e[t].items[r].value;var a=!1;for(var 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){var t=0;for(var 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 h(e){var t=[].concat(e),n=t.shift(),i=[],r=[].push;for(;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){var n=[];for(var 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){var n=[];for(var i=0;i<e.length;i++){var r=e[i];var o=r.start;var a=r.isAllDay?t.date.getDate(r.end):r.end;var s=t.date.getDate(o);var l=6e4*(s.getTimezoneOffset()-a.getTimezoneOffset());var 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 h=1;h<c;h++)o=d.end,(d=r.clone()).start=d.startDate=t.date.getDate(o),d.end=t.date.nextDay(o),h==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){var i=[];var r=this.options.editable;var o=r&&!1!==r.destroy&&!this._isMobile();var a=this._isMobile();var s=this._groupedView._getSumOfItemsForDate(e);var l=this._groupedView._getGroupsInDay(e,n);var c=0;for(var d=0;d<e.length;d++){var h=e[d].value;var u=e[d].items;var p=t.date.isToday(h);for(var f=0;f<u.length;f++){var m=u[f];var g=[];var v=a?[]:g;this._groupedView._renderTaskGroupsCells(v,n,d,f,l,s,h,c),c++,0===f&&(a?(v.push(t.format('<td class="k-scheduler-datecolumn {1}" colspan="2">{0}</td>',this._dateTemplate({date:h,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,u,h,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){var i=this._isMobile();for(var 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();var 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){var t,n=0,i=e.length,r=[];for(;n<i;n++)(t=e[n]).groups?(t=h(t.groups),r=r.concat(t)):r=r.concat(h(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];var a=[];var s=o.dataSource.view();var l=this._isMobile();s=s.filter((function(e){var n=t.getter(o.dataParentValueField)(e);return null==n||r&&n===r.value}));for(var h=0;h<s.length;h++){var u=d(o,s[h]);var p=new t.data.Query(e).filter({field:o.field,operator:n.SchedulerView.groupEqFilter(u)}).toArray();if(p.length){var f=this._tasks(p);var m=r?"":" k-first";var g={text:t.getter(o.dataTextField)(s[h]),value:u,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;var 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> <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>`)),h=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>",u=t.template((({title:e})=>`<div title="${e.replace(/"/g,""")}"><div class="k-event-template">${a(e)}</div></div>`));var 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>`));var 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){var r=this._view;var o=r._isVerticallyGrouped();var a="";for(var 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){var r=this._view;for(var o=0;o<e;o++){var a=0;var 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));var d=n[l].children;var h=0;r._isVerticallyGrouped()||(h=o);for(var u=7*h;u<7*(h+1);u++){var p=d[u];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;var n=e.startSlot().offsetLeft;var r=e.start.offsetTop;var o=e.innerWidth();var a=e.start.clientHeight-2;var s=i.fn._createResizeHint.call(t,n,r,o,a);t._appendResizeHint(s)},_createMoveHint:function(e,t){var n=this._view;var i=e.startSlot();var r=e.endSlot();var 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)}});var 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;var o="";var a=0;if(r._isVerticallyGrouped()){var s=new Date(e);var l=r._groupCount();for(;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){var r=this._view;var o=e[0];var a=[];var s=o.dataSource.view();for(var l=0;l<6*s.length;l++){var c=t.getter(o.dataValueField)(s[l%s.length]);var 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){var a=this._view;var s=n.start.index;var l=n.end.index;for(var c=n.start.index;c<=n.end.index;c++){var d=n.collection._slots[c];var h=t.daySlotRanges(d.start,d.start,!0)[0];var u=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(h,a._createEventElement(u),t)}},_positionEvent:function(e,t,n,i,r,o){var a=this._view;var s=n.start.index;var l=n.end.index;for(var c=n.start.index;c<=n.end.index;c++){var d=n.collection._slots[c];var h=t.daySlotRanges(d.start,d.start,!0)[0];var u=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(h,a._createEventElement(u),t)}},_addDaySlotCollections:function(e,n,i){var r=this._view;var o=r._isVerticallyGrouped();for(var a=0;a<7;a++)for(var s=0;s<6;s++){var l=0;var c=n[o?a:s].children;var d=0;r._isVerticallyGrouped()||(d=a);for(var h=d*e;h<(d+1)*e;h++){var u=7*s+a;var p=c[o?h+s*e:h];var f=o?h:l;var m=r.groups[f];var g;g=0===a?m.addDaySlotCollection(t.date.addDays(i,u),t.date.addDays(i,u+7)):m._daySlotCollections[s],r.addDaySlot(g,p,i,u),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=this._view;var n,r,o,a,s;if(t._isVerticallyGrouped())n=e.startSlot().offsetLeft,r=e.start.offsetTop,o=e.startSlot().offsetWidth,a=e.endSlot().offsetTop+e.startSlot().offsetHeight-e.startSlot().offsetTop-2,s=i.fn._createResizeHint.call(t,n,r,o,a),t._appendResizeHint(s);else for(var l=e.startSlot().index;l<=e.endSlot().index;l++){var c=e.collection._slots[l];n=c.offsetLeft,r=c.offsetTop,o=c.offsetWidth,a=c.offsetHeight-2,s=i.fn._createResizeHint.call(t,n,r,o,a),t._appendResizeHint(s)}},_createMoveHint:function(e,t){var n=this._view;var i=e.startSlot();var r=e.endSlot();for(var o=i.index;o<=r.index;o++){var a=e.collection._slots[o];var 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();var o=this.options.adaptiveSlotHeight;var 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;var a=t[t.length-1].end;var s=o.index===a.index;var l=o.collectionIndex===a.collectionIndex;(r?s&&l||l:s&&l)&&(e.backward=i)}},_changeDate:function(e,t,n){var i=this.groups[e.groupIndex];var r,o;if(n){if(r=i._getCollections(i.daySlotCollectionCount()),(o=t.collectionIndex-1)>=0)return r[o]._slots[r[o]._slots.length-1]}else{if((r=i._getCollections(i.daySlotCollectionCount()))[o=t.collectionIndex+1]&&r[o]._slots[0])return r[o]._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=i?7:1;var o,a;return n&&(r*=-1),o=t.date.addDays(e.start,r),a=t.date.addDays(e.end,r),!this._isInRange(o,a)&&(e.start=o,e.end=a,(!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;var o=this.groups.length-1;var a=this._isVerticallyGrouped();var 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(h),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();var 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 > table td",(function(t){var i=e(t.currentTarget).offset();var 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;var 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();var 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>";var t=1;var n=this._groupedView;var 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=this.options;var n=t.eventHeight;var i=t.eventSpacing;var r=t.moreButtonHeight;var o=this.content.find("table tr td")[0];var a;if("auto"!==n&&o)return a=o.firstChild,Math.round(o.offsetHeight-o.clientHeight+a.offsetTop+a.offsetHeight+2+e*n+(e-1)*i+(2+r)+2)},_initSlotHeight:function(){var e=this.options;var t=e.eventsPerDay;var n=e.eventHeight;var i=this._isMobile();var r=this.content.find("table");var o;i||"number"==typeof n&&(o=this._calcSlotHeight(t),r.find("tr").height(o))},_sortEventMeta:function(e){e.eventMeta.sort((function(e,t){return e.order-t.order}))},_adjustSlotHeight:function(e){var t=this;var n=this.options;var i=n.eventHeight;var r=n.eventSpacing;var o=n.moreButtonHeight;!0===this._canAdjustSlotHeight&&e._daySlotCollections.forEach((function(e){var n=e._events;var a=0;var s=e._slots;var l=s[0];var c=l.element.offsetTop;var 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;var t=e.times;var n=e._isSchedulerHeightSet();var i=e.content[0];t&&!n&&t.height(i.clientHeight)},_createCalendar:function(e){var n=this.startDate();var i=[n];var r="";var o=1;var a=this._isVerticallyGrouped();var s=this._groupedView;var l=this.groupedResources;l.length&&(a||(o=s._horizontalGroupCountForLevel(l.length-1))),this._slotIndices={};var c=s._getCalendarRowsLength(7,42);for(var d=0;d<c;d++){r+="<tr>",i.push(n);var h=7*d;r+=s._createRows(n,h,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){var o=this;var a=o._firstDayOfMonth;var l=o._lastDayOfMonth;var c=o.dayTemplate;var d="";var h="";var u=this._groupedView;var p=function(){return o._resourceBySlot({groupIndex:r})};for(var f=0;f<i;f++)d="",t.date.isToday(e)&&(d+="k-today"),t.date.isInDateRange(e,a,l)||(d+=" k-other-month"),h+="<td ",""!==d&&(h+='class="'+d+'"'),h+=">",h+=u._getContent(c,e,p,f),h+="</td>",o._slotIndices[s(e).getTime()]=n+f,e=u._nextSlotStartDate(e);return h},_layout:function(){var t=this.calendarInfo();var n=function(e,t){return e.slice(t).concat(e.slice(0,t))}(this._isMobile()?t.days.namesShort.map((function(e){return e[0]})):t.days.names,t.firstDay);var i=e.map(n,(function(e){return{text:e}}));var r=this.groupedResources;var o;var a=this._groupedView;if(r.length)if(this._isVerticallyGrouped()){var s=[];for(var l=0;l<6;l++)s.push({text:"<div> </div>",className:"k-hidden k-slot-cell"});o=a._createRowsLayout(r,s,this.groupHeaderTemplate,i),i=a._createVerticalColumnsLayout(r,s,this.groupHeaderTemplate,i)}else i=a._createColumnsLayout(r,i,this.groupHeaderTemplate,i);return{columns:i,rows:o}},_createEventElement:function(n){var i=this.options;var r=i.editable;var 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];var i=n.firstSlot().start;var r=n.lastSlot().end-1;var o=t.date.toUtcTime(e.start);var 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;var h=d;var u=i.collidingEvents(n.events(),d,h);u.push({element:r,start:d,end:h});var p=i.createRows(u);var f=n.collection.at(d);var 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:h,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;var s=this.options.eventSpacing;var l=n.start;n.start.offsetLeft>n.end.offsetLeft&&(l=n.end);var c=n.start.index;var d=n.end.index;var h=l.eventCount;var u=i.collidingEvents(n.events(),c,d);var f=c!==d?3:2;u.push({element:r,start:c,end:d});var m=i.createRows(u);for(var g=0,v=Math.min(m.length,h);g<v;g++){var _=m[g].events;var b="auto"===a?"":l.offsetTop+l.firstChildTop+l.firstChildHeight+2+g*(a+s)+"px";for(var w=0,y=_.length;w<y;w++)_[w].element[0].style.top=b,_[w].element.attr(t.attr("order"),g)}if(m.length>h)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+h*a+(h-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;var S=n.start.index;var 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();var o=this.groups[n].ranges(i,r,!0,e.isAllDay);for(var 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;var o=r+e.duration();var 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();var t=this.content[0].getElementsByTagName("tr");var 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);var a=t.date.MS_PER_DAY;var 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;var i=this._isMobile();var r=this._isGroupedByDate();var 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];var r=this._groupedView._view._isMobile();i&&(i._continuousEvents||(i._continuousEvents=[]),r?e.forEach(function(e){var n=i.slotRanges(e,!0);var r=n[0];var o=r.start.start;var a=r.end.end;var s=new Date(r.start.start);var l=n[n.length-1].end.end;var c=new Date(s);var d=new Date(a);for(;s.getTime()<=l&&e.end>=t.timezone.toLocalDate(s)&&e.start<=t.timezone.toLocalDate(l);){var h=i.daySlotRanges(c.getTime(),d.getTime(),!0)[0];d.setDate(d.getDate()+1),c.setDate(c.getDate()+1),h&&(h.head=null,h.middle=null,h.tail=null,this._groupedView._positionMobileEvent(e,i,h,1,o,a,0)),s=t.date.addDays(s,1)}}.bind(this)):(e.forEach(function(e){var t;var n=e.start;var r=e.end;var o=i.slotRanges(e,!0);var a=o.length;for(var 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]);var h=new t.data.Query(e).filter({field:s.field,operator:i.groupEqFilter(d)}).toArray();n.length>1?r=this._renderGroups(h,n.slice(1),r++,o+1,d):this._renderEvents(h,r++)}}return r},_groupCount:function(){var e=this.groupedResources;var 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:u,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",h="keydown",u="click",p="focus",f=".kendoYearView";var 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"};var 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>`)));var 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(u+f,"td[role='gridcell']",r._calendarCellClick.bind(r)),i.on(h+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(h,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:u,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(u+f,".k-tooltip-title > .k-day",e._tooltipTitleClick.bind(e)),t.popup.element.on(h+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();var 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,h=d.setTime,u=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"},w={SU:0,MO:1,TU:2,WE:3,TH:4,FR:5,SA:6},y=["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){var i,r,o,a=!1,s=e.getHours(),l=function(e){return e<0&&(e=i+e+1),e};for(;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){var i,r,o=!1,a=e.getHours(),s=function(e){return e<0&&(e=i+e),e};for(;e<t;){if(i=q(e)?366:365,null===(r=$(n.yearDays,B(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){var i,r,o,a=n.weekStart,s=!1,l=e.getHours(),c=function(e){return e<0&&(e=53+e),e};for(;e<t;){if(null===(r=$(n.weeks,H(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),u(e,a,-1),p(e,l);break}e.setFullYear(i+1,0,1)}return s},weekDays:function(e,t,n){var i=new Date(e.getTime()+n.offsets.start);var r=i.getDay()-e.getDay();var o=n.weekDays;var a=n.weekStart;var s=function(e,t,n){var i=F(t.getDay(),n);var r=e.length;var o;var a,s;var l;var c=[];var d=0;for(;d<r;d++)if(a=e[d],l=R(t,n),null!==(o=O(t,a,n)))if(l<o)c.push(a);else if(l===o)if(i<(s=F(a.day,n)))c.push(a);else if(i===s)return null;return c}(o,i,a);var l=e.getHours();var c,d;if(null===s)return!1;if((c=s[0])||(("monthly"===n.freq&&!n.positions||n.position>0)&&o.forEach((function(t){var n=new Date(e.getFullYear(),e.getMonth()+1,1);var i=F(t.day,a);n.getDay()<=i&&(!c||F(c.day,a)>i)&&(c=t)})),c||(c=o[0]),u(e,a)),d=c.day,d-=r,c.offset)for(;e<=t&&!N(e,c,a);)R(e,a)===V(e,a)?(e.setMonth(e.getMonth()+1,1),p(e,l)):(e.setDate(e.getDate()+7),p(e,l),u(e,a,-1));return e.getDay()!==d&&u(e,d),!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){var r,o,a,s,l,c=i.interval;for(;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=new Date(e._startPeriod);var i=new Date(t);var r=t.getHours();var o=e.weekStart;var a=e.interval;var s=e.freq;var l=!1;var c=0;var h=0;var u=1;var f;var m;if("hourly"===s)f=i.getTimezoneOffset()-n.getTimezoneOffset(),m=e._startTime.getHours(),i=i.getTime(),r!==m&&(i+=(m-r)*d.MS_PER_HOUR),i-=n,f&&(i-=f*d.MS_PER_MINUTE),0!==(c=L(f=Math.floor(i/d.MS_PER_HOUR),a))&&(this._hour(t,e,c),l=!0);else if("daily"===s)d.setTime(i,-n,!0),0!==(c=L(f=Math.round(i/d.MS_PER_DAY),a))&&(this._date(t,e,c),l=!0);else if("weekly"===s){c=this._getNumberOfWeeksBetweenDates(n,t),F(t.getDay(),o)<F(n.getDay(),o)&&(c+=1),0!==(c=L(c,a))&&(d.setDayOfWeek(t,e.weekStart,-1),t.setDate(t.getDate()+7*c),p(t,r),l=!0)}else"monthly"===s?(f=t.getFullYear()-n.getFullYear(),0!==(c=L(f=t.getMonth()-n.getMonth()+12*f,a))&&(u=e._hasRuleValue?1:t.getDate(),t.setFullYear(t.getFullYear(),t.getMonth()+c,u),p(t,r),l=!0)):"yearly"===s&&(c=L(f=t.getFullYear()-n.getFullYear(),a),e.months||(h=t.getMonth()),e.yearDays||e.monthDays||e.weekDays||(u=t.getDate()),0!==c&&(t.setFullYear(t.getFullYear()+c,h,u),p(t,r),l=!0));return l},_getNumberOfWeeksBetweenDates:function(e,t){var n=(t-e)/6048e5;var 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))}}),M=S.extend({next:function(e,t){S.fn.next(e,t)||this[t.hours?"_hour":"_date"](e,t,1)}}),A=M.extend({setup:function(e,t){e.weekDays||(e.weekDays=[{day:t.getDay(),offset:0}])}}),D=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=D.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 M,weekly:new A,monthly:new D,yearly:new E},z="click",P="change";function L(e,t){var n;return 0!==e&&e<t?n=t-e:(n=e%t)&&(n=t-n),n}function B(e){var t=e.getMonth();return(q(e)?g[t]:v[t])+e.getDate()}function H(e,n){var i,r;return e=new Date(e.getFullYear(),e.getMonth(),e.getDate()),p(e,0),i=e.getFullYear(),n!==t?(u(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 R(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 F(e,t){return e+(e<t?7:0)}function O(e,t,n){var i=t.offset;if(!i)return R(e,n);var r=new Date(e.getFullYear(),e.getMonth()+1,0);var o=R(r,n);var a=F(t.day,n);var s=a<F(new Date(e.getFullYear(),e.getMonth(),1).getDay(),n);var l=a>F(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 R(new Date(e.getFullYear(),e.getMonth()+1,0),t)}function N(e,t,n){return R(e,n)===O(e,t,n)}function $(e,t,n){var i,r=0,o=e.length,a=[];for(;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){var n,i=0,r=e.length;for(;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){var n,i,r,o=0,a=e.length;for(;o<a;o++){if(i=(n=e[o]).length,r=n.substring(i-2).toUpperCase(),(r=w[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){var i=Array.isArray(e)?e:K(e,n),r=t.getTime()-t.getMilliseconds(),o=0,a=i.length;for(;o<a;o++)if(i[o].getTime()===r)return!0;return!1}function Q(e,t){var i=0;var r;var o;var a=[].concat(e);for(r=a.length;i<r;i++)o=a[i],o=n.timezone.convert(o,t||o.getTimezoneOffset(),"Etc/UTC"),a[i]=n.toString(o,"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":u(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){var r=e.length;var o=[];var a;var s;var l;for(var c=0,d=n.length;c<d;c++)(a=n[c])<0?a=r+a:a-=1,s=e[a],l=!i||s.start<i,s&&s.start>=t&&l&&o.push(s);return o}function J(e,t,n){var i=[];var r;for(var o=0;o<e.length;o++)Y(t,(r=e[o]).start,n)||i.push(r);return i}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,y))&&t&&(e=r.apply(e,t)),e}function ie(e,t){var n=e.split(";");var i;var r;var o;var a;var s,l;for(var c=0,d=n.length;c<d;c++)if(r=(i=n[c].split(":"))[0],o=i[1],-1!==r.indexOf("TZID")&&(a=r.substring(r.indexOf("TZID")).split("=")[1]),o)for(s=0,l=(o=o.split(",")).length;s<l;s++)o[s]=ne(o[s],a||t);if(o)return{value:o,tzid:a}}function re(e,i,r){var o={};var a,s;var l,c=0;var d=!1;var h,u,p;var f,m;if(!e)return null;for((p=e.split("\n"))[1]||-1===e.indexOf("DTSTART")&&-1===e.indexOf("DTEND")&&-1===e.indexOf("EXDATE")||(p=e.split(" ")),c=0,l=p.length;c<l;c++)-1!==(u=n.trim(p[c])).indexOf("DTSTART")?o.start=ie(u,i):-1!==u.indexOf("DTEND")?o.end=ie(u,i):-1!==u.indexOf("EXDATE")?o.exdates=ie(u,i):-1!==u.indexOf("RRULE")?h=u.substring(6):n.trim(u)&&(h=u);for(c=0,l=(h=h.split(";")).length;c<l;c++)switch(a=h[c].split("="),s=n.trim(a[1]).split(","),n.trim(a[0]).toUpperCase()){case"FREQ":o.freq=s[0].toLowerCase();break;case"UNTIL":o.until=ne(s[0],i);break;case"COUNT":o.count=parseInt(s[0],10);break;case"INTERVAL":o.interval=parseInt(s[0],10);break;case"BYSECOND":o.seconds=U(s,{start:0,end:60}),d=!0;break;case"BYMINUTE":o.minutes=U(s,{start:0,end:59}),d=!0;break;case"BYHOUR":o.hours=U(s,{start:0,end:23}),d=!0;break;case"BYMONTHDAY":o.monthDays=U(s,{start:-31,end:31}),d=!0;break;case"BYYEARDAY":o.yearDays=U(s,{start:-366,end:366}),d=!0;break;case"BYMONTH":o.months=U(s,{start:1,end:12}),d=!0;break;case"BYDAY":o.weekDays=m=W(s),d=!0;break;case"BYWEEKNO":o.weeks=U(s,{start:-53,end:53}),d=!0;break;case"BYSETPOS":o.positions=U(s,{start:-366,end:366});break;case"WKST":o.weekStart=f=w[s[0]]}return o.freq===t||o.count!==t&&o.until?null:(o.interval||(o.interval=1),f===t&&(o.weekStart=f=n.culture().calendar.firstDay),m&&(o.weekDays=m.sort((function(e,t){var n=e.day,i=t.day;return n<f&&(n+=7),i<f&&(i+=7),n-i}))),o.positions&&!d&&(o.positions=null),o._hasRuleValue=d,o.offsets=r,o)}function oe(e,t){var i=e.value;var o=e.tzid||"";var a=i.length;var s=0;var l;for(;s<a;s++)l=i[s],l=r.convert(l,o||t||l.getTimezoneOffset(),"Etc/UTC"),i[s]=n.toString(l,"yyyyMMddTHHmmssZ");return o&&(o=";TZID="+o),o+":"+i.join(",")+" "}function ae(e,i){var o=e.weekStart;var a="FREQ="+e.freq.toUpperCase();var s=e.exdates||"";var l=e.start||"";var c=e.end||"";var 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){var t,n,i=0,r=e.length,o=[];for(;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,w,y,k,x,C,S,T,M,A,D,E,z,P,L,B,H,R=[];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=(D=a.positions)?0:1,b=a.start,w=a.end,(b||w)&&(e=e.clone({start:b?new Date(b.value[0]):t,end:w?new Date(w.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],M=a.count,a.until&&a.until<r&&(r=new Date(a.until)),y="yearly"===k||"monthly"===k||"weekly"===k,i<S||M||a.interval>1||y||("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),D&&(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":u(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 F=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),h(c,v);var O=new Date(i);if(h(O,v+F),(i>=_||O>_)&&!Y(x,i,o)||D)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;var N=e.endTimezone||e.startTimezone;if(!e.isAllDay&&(o&&V||!o&&!V)){var $=te(i,o)-te(e.start,o);var U=te(c,o)-te(e.end,o);var W=te(i,V)-te(e.start,V);var j=te(c,N)-te(e.end,N);if($!==W){var q=6e4*($-W);P=new Date(i.getTime()-q),B=s-q}if(U!==j){var G=6e4*(U-j);L=new Date(c.getTime()-G),H=l-G}}R.push(e.toOccurrence({start:P||new Date(i),end:L||c,_startTime:B||s,_endTime:H||l})),P=L=B=H=null}else e._startTime=s,e._endTime=l,R.push(e);if(D){if(A.next(i,a),A.limit(i,r,a),i>a._endPeriod&&(z=J(z=Z(R.slice(E),T,D,a.until),x,o),R=R.slice(0,E).concat(z),a._endPeriod=X(i,a),E=R.length),M&&M===E)break}else{if(M&&M===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 R},dayInYear:B,weekInYear:H,weekInMonth:R,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>`:"")));var 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}];var ce=[{day:1,offset:0},{day:2,offset:0},{day:3,offset:0},{day:4,offset:0},{day:5,offset:0}];var de=[{day:0,offset:0},{day:6,offset:0}];var he=s.extend({init:function(e,t){var i;var r=this;var 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){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=[];for(;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;var n=(t._weekDay.element||t._weekDay).val();var i=Number((t._weekDayOffset.element||t._weekDayOffset).val());var r=null;var 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=this;var t=e._value.weekDays;var n=e._value.positions;var i=e._weekDayOffset;var r;var o;var a;var s;t&&(a=t.length,n&&(7===a?(o="day",r=n):5===a?(o="weekday",r=n):2===a&&(o="weekend",r=n)),o||(o=(t=t[0]).day,r=t.offset||""),i[s=i.value?"value":"val"](r),e._weekDay[s](o))},_initWeekDay:function(){var t,i=this;var r=i.options.messages.weekdays;var o=i.options.messages.offsetPositions;var a=i._container.find(".k-recur-weekday");var 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;var t=this._weekDayButtonGroup;if(t&&e.weekDays&&e.weekDays.length){var n,i=e.weekDays,r=i.length,o=[],a=0;for(;a<r;a++)o.push("[data-value='"+i[a].day+"']");n=t.element.find(o.join(",")),t.select(n)}},_initMonthDay:function(){var e=this;var t=e._value;var 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")}});var ue=he.extend({init:function(e,t){var n=this;he.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),he.fn.destroy.call(e)},value:function(e){var n=this;var i=n.options.timezone;var r,o;if(e===t)return n._value.freq?ae(n._value,i):"";n._value=re(e,i)||{},(r=n._value.freq)?(o=n._frequency.element.find("[data-value='"+r+"']"),n._frequency.select(o)):n._frequency.select(0),n._initView(n._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=this;var r=i._value;var o=i.options;var a;var s={frequency:t||"never",firstWeekDay:o.firstWeekDay,messages:o.messages[t],end:o.messages.end};i._weekDayButtonGroup&&(i._weekDayButtonGroup.destroy(),i._container.find(".k-recur-weekday-buttons").empty(),i._weekDayButtonGroup=null),n.destroy(i._container),a=e(se(s)),n.applyStylesFromKendoAttributes(a,["width"]),i._container.html(a),t?(r.freq=t,"weekly"!==t||r.weekDays||(r.weekDays=[{day:o.start.getDay(),offset:0}]),i._weekDayButtons(o.firstWeekDay),i._initInterval(),i._initWeekDays(),i._initMonthDay(),i._initWeekDay(),i._initMonth(),i._initCount(),i._initUntil(),i._period(),i._end()):i._value={}},_initMonth:function(){var t=this;var i=t._value;var r=i.months||[t.options.start.getMonth()+1];var o=t._container.find(".k-recur-month");var a;o[0]&&(a={autoWidth:!0,change:function(){i.months=[Number(this.value())],t.trigger("change")},dataTextField:"text",dataValueField:"value",dataSource:e.map(n.culture().calendar.months.names,(function(e,t){return{text:e,value:t+1}}))},t._month1=new l(o[0],a),t._month2=new l(o[1],a),r&&(r=r[0],t._month1.value(r),t._month2.value(r)))},_end:function(){var e=this;var t=e._value;var n=e._container;var i=e._namespace;var r=function(t){e._toggleEnd(t.currentTarget.value),e.trigger("change")};var o;e._buttonNever=n.find(".k-recur-end-never").on(z+i,r),e._buttonCount=n.find(".k-recur-end-count").on(z+i,r),e._buttonUntil=n.find(".k-recur-end-until").on(z+i,r),t.count?o="count":t.until&&(o="until"),e._toggleEnd(o)},_period:function(){var e=this;var t=e._value;var n="monthly"===t.freq;var i=n?e._toggleMonthDay:e._toggleYear;var r=".k-recur-"+(n?"month":"year")+"-radio";var 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=this;var n,i;var r,o;"count"===e?(t._buttonCount.prop("checked",!0),r=!0,o=!1,n=t._count.value(),i=null):"until"===e?(t._buttonUntil.prop("checked",!0),r=!1,o=!0,n=null,i=t._until.value()):(t._buttonNever.prop("checked",!0),r=o=!1,n=i=null),t._count&&t._count.enable(r),t._until&&t._until.enable(o),t._value.count=n,t._value.until=i},_toggleMonthDay:function(e){var t=this;var n=!1;var i=!0;var r=!1;var o;"monthday"===e?(t._buttonMonthDay.prop("checked",!0),o=[t._monthDay.value()],n=!0,i=!1,r=!0):(t._buttonWeekDay.prop("checked",!0),o=null),t._weekDay.enable(i),t._weekDayOffset.enable(i),t._monthDay.enable(n),t._value.monthDays=o,t._weekDayRule(r)},_toggleYear:function(e){var t=this;var n=!1;var i=!0;var r;"monthday"===e?(n=!0,i=!1,r=t._month1.value()):r=t._month2.value(),t._month1.enable(n),t._month2.enable(i),t._value.months=[r],t._toggleMonthDay(e)}});a.plugin(ue);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>`));var 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>`:"")));var 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));var 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>"));var ve=he.extend({init:function(e,t){var r=this;he.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;var 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),he.fn.destroy.call(this)},_initInterval:function(){var e=this;var 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;var 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;var n=e(t._endLiItem()).insertAfter(t.element.parents("li.k-item"));var 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;var i=e(t._endLiItem()).insertAfter(t._container);var 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;var t=this.options.messages.end;var 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;var i=t.options.messages.frequencies;var 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;var t=e.options.messages.end.patterns;var i=e._value;var 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;var o=null;var 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;var o=r.options.messages;var a=o["repeat"===t?"repeatTitle":"endTitle"];var 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>";var 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;var i=t._value.freq||"never";var r={frequency:i,firstWeekDay:t.options.firstWeekDay,messages:t.options.messages[i]};var o=fe(r);var a=e(o);n.applyStylesFromKendoAttributes(a,["display"]);var s=t._container=t._container||this._pane.view().content.find("li.k-recur-view");var 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;var 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;var 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;var r=i.options.messages.weekdays;var o=i.options.messages.offsetPositions;var a=i._container.find(".k-recur-weekday");var 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;var i=t._value;var r=t.options.start;var o=i.months||[r.getMonth()+1];var a=t._container.find(".k-recur-month");var 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;var t=e._value;var i=e._container;var r=e.options.messages[t.freq];var o=i.find(".k-repeat-rule");var a=i.find(".k-weekday-view");var s=i.find(".k-monthday-view");if(o[0]){var l=t.weekDays?"weekday":"monthday";var c=ge({value:l,dataSource:[{text:r.dayOfMonth,value:"monthday"},{text:r.dayOfWeek,value:"weekday"}],ns:n.ns});var d=function(n){var i=e._weekDay.val();var r=e._weekDayOffset.val();var o=e._monthDay.val();var 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;var t=e._container.find("[ref-recur-until]");var i=e.options.start;var r=e._value;var o=r.until;var a=o&&o<i?o:i;var s=n.format(n.ui.Validator.prototype.options.messages.date,e.options.messages.end.on);var 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;var i="";var r=e.length;var 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,h=n.date.getMilliseconds,u=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=".",w=".kendoTimelineView";var y=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,h(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){var c=this._view;var d="";var h=c.options;var u=function(t){var i="";var r="";var o;var a;return n.date.isToday(e[m])&&(r+="k-today"),(n.date.getMilliseconds(t)<n.date.getMilliseconds(h.workDayStart)||n.date.getMilliseconds(t)>=n.date.getMilliseconds(h.workDayEnd)||!c._isWorkDay(e[m]))&&(r+=" k-nonwork-hour"),i+="<td"+(""!==r?' class="'+r+'"':"")+">",o=n.date.getDate(e[m]),n.date.setTime(o,n.date.getMilliseconds(t)),i+=s({date:o,resources:(a=l?p:f,function(){return c._resourceBySlot({groupIndex:a})})}),i+="</td>"};for(var 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,u);d+="</tr>"}return d},_addTimeSlotsCollections:function(e,t,n,i,r){var o=this._view;var a=n.length;r&&(a=Math.floor(a/e));for(var s=0;s<e;s++){var l=0;var c=o.groups[s];var d;r&&(l=s);var u=0;r||(u=s);var p=n[l*a].children;var f=p.length/(r?1:e);var m=f/t;for(var g=0;g<t;g++){var v=g*m+f*u;d=h(new Date(+o.startTime()));for(var _=0;_<m;_++)o._addTimeSlotToCollection(c,p,_,v,g,d,i),d+=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=this._view;var s;(s=a._createEventElement(n.occurrence,t,r.head||n.head,r.tail||n.tail)).appendTo(o).css({top:0,height:a.options.eventHeight});var l={start:n.occurrence._startTime||n.occurrence.start,end:n.occurrence._endTime||n.occurrence.end,element:s,uid:t.uid,slotRange:r,rowIndex:0,offsetTop:0};e.events[t.uid]=l,a._inverseEventColor(s),a.addContinuousEvent(i,r,s,t.isAllDay),a._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;var r="<div class='"+f+"'></div>";var o=i.datesHeader.find(b+g);var s=Math.round(t[0].innerRect(n,new Date(n.getTime()+1),!1).left);var 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;var 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;var i=e.start;var 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);var 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}});var M=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){var d=this._view;var h="";var u=d.options;var f=function(t,i,r,o,a,s){var c="";var h="";var p;var f=d._isVerticallyGrouped()?m:w;var g;return n.date.isToday(e[w])&&(h+="k-today"),(n.date.getMilliseconds(t)<n.date.getMilliseconds(u.workDayStart)||n.date.getMilliseconds(t)>=n.date.getMilliseconds(u.workDayEnd)||!d._isWorkDay(e[f]))&&(h+=" k-nonwork-hour"),c+="<td"+(""!==h?' class="'+h+'"':"")+">",p=n.date.getDate(e[w]),n.date.setTime(p,n.date.getMilliseconds(t)),c+=l({date:p,resources:(g=s,function(){return d._resourceBySlot({groupIndex:g})})}),c+="</td>"};var m,g=new Date(a),v=d.options.minorTickCount,_=d.options.majorTick*p/v||1;for(var b=0;b<o;b++){h+="<tr>",b%(o/d._dates.length)==0&&(m=b/(o/d._dates.length),g=new Date(d._dates[m]),n.date.setTime(g,n.date.getMilliseconds(a)));for(var w=0,y=t;w<y;w++)if(h+=d._forTimeRange(g,s,f,c,i),c){r(g,_,!1);break}h+="</tr>"}return h},_addTimeSlotsCollections:function(e,t,n,i,r){var o=this._view;var a=n.length;r&&(a/=t);for(var s=0;s<t;s++){var l=0;var c;r&&(l=s);var d=n[l*a].children;var u=r?a:d.length/(t*e);var p=d.length/t;var f;c=h(new Date(+o.startTime()));for(var m=0;m<u;m++){r?(f=0,d=n[m+u*s].children):f=s*p+e*m;for(var g=0;g<e;g++){var v=o.groups[g];o._addTimeSlotToCollection(v,d,g,f,s,c,i)}c+=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){var l=this._view;var c;var d=[];for(var h=r.start.index;h<=r.end.index;h++){(c=l._createEventElement(n.occurrence,t,h!==s,h!==a)).appendTo(o).css({top:0,height:l.options.eventHeight});var u=i._timeSlotCollections[0]._slots[h];var p=i.timeSlotRanges(u.start,u.end,!1)[0];var f={start:h===a?n.occurrence._startTime||n.occurrence.start:u.start,end:h===s?n.occurrence._endTime||n.occurrence.end:u.end,element:c,uid:t.uid,slotRange:p,rowIndex:0,offsetTop:0};e.events[t.uid]=f,d.push(f),l.addContinuousEvent(i,p,c,t.isAllDay),l._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;var r=i.times.find("tr").first().find("th").first();var o=i.times.find("tr").first().find("th").last();var l="<div class='"+f+"'></div>";var c=e(l).prependTo(i.times);var d=Math.round(t[0].innerRect(n,new Date(n.getTime()+1),!1).top);var h={};this._isRtl?(h.right=r.position().left+s(r)-s(o),c.addClass(m+"-left")):(h.left=o.position().left,c.addClass(m+"-right")),h.top=d-a(c)*_/2,c.css(h),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=this._view.groups[e.groupIndex];var r,o;if(t){if(r=i._getCollections(!1),(o=n.index-1)>=0)return r[0]._slots[o]}else if(r=i._getCollections(!1),o=n.index+1,r[0]&&r[0]._slots[o])return r[0]._slots[o]},_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;var l=s._changeGroup(e,a);var 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){var n=this._view;var i=e.start;var r=e.end;for(var o=i.index;o<=r.index;o++){var a=e.collection._slots[o];var 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=M;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=[];var n=e.workWeekStart%7;var 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);var r=0;for(var 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)}}var s=i.group&&"vertical"!=i.group.orientation?this.groups.length:1;for(var l=0;l<s;l++){var c=this.groups[l];if(!c)return;var d=n.date.toUtcTime(t);var h=c.timeSlotRanges(d,d+1);if(0===h.length)return;if(h[0].collection.slotByStartDate(t))if(this._isVerticallyGrouped())this._groupedView._updateCurrentVerticalTimeMarker(h,t);else{var u="<div class='"+f+"'></div>";var p=this.datesHeader.find(b+g);var v=Math.round(h[0].innerRect(t,new Date(t.getTime()+1),!1).left);var w=e(u).prependTo(p).addClass(m+"-down");w.css({left:this._adjustLeftPosition(v-a(w)*_/2),top:p.find("tr").last().prev().position().top}),e(u).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;var 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"+w,".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"+w,".k-scheduler-content > table 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"+w,".k-event",(function(i){t.trigger("edit",{uid:e(this).closest(".k-event").attr(n.attr("uid"))}),i.preventDefault()}))},_touchEditable:function(){var i=this;var 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;var r=e.y.location!==t?e.y.location:e.y;var 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;var r=this.content;var o=r.offset();var a;if(e-=o.left,t-=o.top,this._isRtl){var s=n.support.browser;s.mozilla||s.webkit&&s.version>=85?(e+=r[0].scrollWidth-r[0].offsetWidth,e+=r[0].scrollLeft):s.msie?(e-=n.scrollLeft(r),e+=r[0].scrollWidth-r[0].offsetWidth):s.webkit&&(e+=r[0].scrollLeft)}else e+=r[0].scrollLeft;for(t+=r[0].scrollTop,e=Math.ceil(e),t=Math.ceil(t),a=0;a<this.groups.length;a++)if(i=this._groupedView._getTimeSlotByPosition(e,t,a))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:()=>" ",eventTemplate:y,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"+w,".k-nav-day",(function(t){var i=e(t.currentTarget).closest("th");var 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();var t=this.content.find("table");var n=100;var 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;var t=this.startTime();var i=this.endTime();(i=h(i))===(t=h(t))?i+=u-1:i<t&&(i+=u);var o=[];for(var 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=h(e),l=h(t),c=this.options.minorTickCount,d=this.options.majorTick*p,f=d/c||1,m=new Date(+e),g=0,v="";for(a=u/f,s!=l&&(s>l&&(l+=u),a=(l-s)/f),a=i?1:Math.round(a),o&&(a*=o);g<a;g++){var _=g%(d/f);var b=0===_;var w=c;if(a%c!=0)b&&a-(g+1)<c&&(w=a%c);v+=n(m,b,_<c-1,_===c-1,w,g%o),i||(o?g%o==o-1&&r(m,f,!1):r(m,f,!1))}return v},_layout:function(e){var t=[];var n=[];var i=this;var r=[{text:i.options.messages.defaultRowText}];var o=i._groupedView;var a=[];for(var s=0;s<i.options.minorTickCount;s++)a.push({text:"​",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){var t=e.getDay();var n=this._workDays;for(var i=0;i<n.length;i++)if(n[i]===t)return!0;return!1},_content:function(e){var t=this;var n=t.startTime();var i=this.endTime();var r=1;var o=1;var a=e.length;var s="";var l=this.groupedResources;var c=this.slotTemplate;var 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();var t=this._dates;var i=t.length;this.groups=[];for(var o=0;o<e;o++){var a=this._addResourceView(o);var s=t[0];var l=t[t.length-1||0];var c=h(this.startTime());var u=h(this.endTime());0!==c&&u<=c&&(s=d(s),r(s,c),l=d(l),r(l,u)),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();var i=this._isVerticallyGrouped();var 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];var l=e.getTimeSlotCollection(0);var c=this._dates[r];var d=Date.UTC(c.getFullYear(),c.getMonth(),c.getDate())+o;var h=d+a;l.addTimeSlot(s,d,h,!0)},startDate:function(){return this._startDate},endDate:function(){return this._endDate},visibleEndDate:function(){var e=h(this.startTime());var t=h(this.endTime());var 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);var i=[];var r=0;for(var 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;var o=this._getBottomRowOffset();var a=this._groupedView;var s=a._getVerticalGroupCount(n);n=this._isVerticallyGrouped()?s:1;for(var l=0;l<n;l++){var c=a._getVerticalRowCount(t,l,i);var d=(r+2)*(c=c||1)+o;var h=e(this.times.find("tr")[l]);var u=e(this.content.find("tr")[l]);h.height(d),u.height(d)}this._setContentWidth(),this.refreshLayout(),this._refreshSlots()},_getBottomRowOffset:function(){var e=.5*this.options.eventHeight;var t;var n;return this._isMobile()?(t=30,n=60):(t=15,n=30),e>n?e=n:e<t&&(e=t),e},_positionEvent:function(e){var t=this.options.eventHeight;var n=e.slotRange.innerRect(e.start,e.end,!1);var i=this._adjustLeftPosition(n.left);var r=n.right-n.left;if(r<0&&(r=0),r<this.options.eventMinWidth){var o=e.slotRange.collection;var a=o._slots[o._slots.length-1];var 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]);var h=new n.data.Query(e).filter({field:s.field,operator:o.groupEqFilter(d)}).toArray();i.length>1?this._eventsByResource(h,i.slice(1),r,d):r.push(h)}}else r.push(e)},_isInDateSlot:function(e){var t=e.start;var i=e.end;var 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);var i=e._endTime||n.date.toUtcTime(e.end);var 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;var i=e.end;var o=e._time("start");var a=e._time("end");var s=h(this.startTime());var l=h(this.endTime());var c=null;var p=null;var f=!1;var m=!1;return e.isAllDay&&(t=d(t),o=0,i=d(i),a=u,p=n.date.addDays(i,1)),0===l&&(l=u),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;var r;var o;for(r=0,o=e.length;r<o;r++)if(i=e[r],this._isInDateSlot(i)){var a=i.isAllDay||i.duration()>=u;var s=this.content;if(a||this._isInTimeSlot(i)){var l=this._adjustEvent(i);var c=this.groups[t];if(c._continuousEvents||(c._continuousEvents=[]),this._isInTimeSlot(l.occurrence)){var d=c.slotRanges(l.occurrence,!1)[0];var h=d.start.index;var p=d.end.index;this._groupedView._renderEvent(n,i,l,c,d,s,h,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;var s=this.options.editable;var c=this._isMobile();var d=s&&!1!==s.destroy&&!c;var h=s&&!1!==s.resize;var u=i._time("start");var p=i._time("end");var f=i.start;var m=i.end;var g=this.eventResources(i);i._startTime&&u!==n.date.getMilliseconds(i.start)&&(f=new Date(u),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:h,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});var _=e(a(v));return n.applyStylesFromKendoAttributes(_,["background-color","border-color"]),_},_arrangeRows:function(e,t,n){var i=t.start.index;var r=t.end.index;var a=e.slotRange.innerRect(e.start,e.end,!1);var s=a.right+this.options.eventMinWidth;var 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,h=c.length;d<h;d++){var u=c[d].events;for(var p=0,f=u.length;p<f;p++)n.events[u[p].uid].rowIndex=d}},_groupCount:function(){var e=this.groupedResources;var 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];var r=e.clone({start:e.start,end:e.end});var 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()>=u||this._isInTimeSlot(r))){var a=this._adjustEvent(r);var s=i.slotRanges(a.occurrence,!1);for(var 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];var c=l.startSlot();var d=l.innerRect(i,r,!1);d.top=c.offsetTop;var h=d.right-d.left;if(h<0)for(var u=0;u<l.events().length;u++)if(l.events()[u].uid===e.uid){h=l.events()[u].rectRight-d.left;break}var p=l.endSlot().offsetTop+c.offsetHeight-d.top;var f=this._adjustLeftPosition(d.left);var m=o.fn._createResizeHint.call(this,f,d.top,h,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;var 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];var 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];var 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;var o=r._verticalMethod(i,n);var a=t[0].start;var s=t[t.length-1].end;var l=this.groups[e.groupIndex];var 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";var o=t[0].start;var a=t[t.length-1].end;var s=this.groups[e.groupIndex];var 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=t?this.previousDate():this.nextDate();var i=e.start;var o=e.end;var a,s;if(a=new Date(n),s=new Date(n),this._isInRange(a,s))return!1;e.start=a,e.end=s,this._isHorizontallyGrouped()&&(e.groupIndex=t?this.groups.length-1:0);var l=o-i;return t?(o=0===(o=h(this.endTime()))?u:o,r(e.start,o-l),r(e.end,o)):(i=h(this.startTime()),r(e.start,i),r(e.end,i+l)),e.events=[],!0},move:function(e,t,i){var r=!1;var o=this.groups[e.groupIndex];var a=n.keys;var s=this._groupedView;var l=o.ranges(e.start,e.end,!1,!1);var c,d,h,u;if(t===a.DOWN||t===a.UP){if(r=!0,h=t===a.UP,s._updateDirection(e,l,i,h),u=this._verticalSlots(e,l,i,h),s._changeVerticalViewPeriod(u,i,e,h))return r}else if((t===a.LEFT||t===a.RIGHT)&&(r=!0,h=t===a.LEFT,this._updateDirection(e,l,i,h,!1),u=this._horizontalSlots(e,l,i,h),s._changeHorizontalViewPeriod(u,i,e,h)))return r;if(r){if(c=u.startSlot,d=u.endSlot,i){var p=e.backward;p&&c?e.start=c.startDate():!p&&d&&(e.end=d.endDate())}else c&&d&&(e.start=c.startDate(),e.end=d.endDate());e.events=[]}return r},destroy:function(){var e=this;e.element&&e.element.off(w),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;var n={},i=this.options.group;if(t.length&&"horizontal"===i.orientation&&i.date){var r,a,s,l,c=e.groupIndex,d=this.columnLevels,h=d[d.length-1],u=t[t.length-1],p=h[c];for(this._setResourceValue(p,u,n),s=d.length-2;s>=3;s--)for(h=d[s],u=t[s-3],r=0,l=0;l<h.length;l++){if((a=(p=h[l]).columns.length)>c-r){this._setResourceValue(p,u,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);var 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,h=d.Widget,u=d.DataBoundWidget,p="string",f=d.Popup,m=d.Calendar,g=n.data.DataSource,v=e.isPlainObject,_=e.extend,b=Object.prototype.toString,w=Array.isArray,y=".kendoScheduler",k="click",x="mousedown",C=n.support.pointers?"pointerdown":"touchstart",S=n.support.pointers?"pointermove":"touchmove",T=n.support.pointers?"pointerup":"touchend",M=n.support.mousemove,A="change",D="progress",E="error",I="cancel",z="remove",P="resetSeries",L="save",B="edit",H="disabled",R="k-focus",F=/(?: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){var n,i=e.length,r=0;for(;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];var 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;var t=this.start;var 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);var a=new Date(this.end);var 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");var i=t.find("[name=start]:visible");var r=t.find("[name=end]:visible");if(r[0]&&i[0]){var o,a;var s=n.widgetInstance(i,n.ui);var l=n.widgetInstance(r,n.ui);var c=t.data("kendoEditable");var 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 h=i.attr(n.attr("timezone"));var u=d.startTimezone;var p=d.endTimezone;u=u||p,p=p||u,u&&(o=re(o,u,h),a=re(a,p,h))}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"}}});var 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){var r=e.length,o=[],a=0;for(;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){var t=this.data().slice(0),n=t.shift(),i=e.id;for(;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;var i=new RegExp("(\\,?)"+s.toExceptionString(n,this.reader.timezone));var 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;var n=this.reader.timezone;var i=this.get(e.recurrenceId);var 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){(w(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=(t.fields||t)[i];var o=["url","email","number","date","boolean"];var a=r?r.validation:{};var s=n.attr("type");var l=e.inArray;var c;var d;var h={};for(c in a)d=a[c],l(c,o)>=0?h[s]=c:n.isFunction(d)||(h[c]=v(d)?d.value||c:d),h[n.attr(c+"-msg")]=d.message;return h}function he(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(H,!1);else{var l=a.get(r);a.set(H,!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 ue(e,t,i,r){var o=e.closest(".k-edit-form-container").find("[data-"+n.ns+"bind='value:"+r+"']");var a=o.getKendoDropDownList();a?a.bind(A,(function(e){var n=e.sender.value();he(t,n,i.dataParentValueField,i.dataValueField)})):o.on(A,(function(e){var n=e.target.value;he(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(H);else{a[c].setAttribute(H,H);var h=""+s.get(e.dataValueField);o.indexOf(h)>=0&&(l?o.splice(o.indexOf(h),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();var 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};var o=i.model.isAllDay;var a=n.attr("validate")+"='"+!o+"'";var 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){var s="";var l=t.dataSource.view();for(var 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 h=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+"']");var o=i[r];pe(t,h,o),e.on(A,(function(e){var n=e.target.value;pe(t,h,n)}))}))}},resources:function(t,i,r){var o=de(i,t.field);return function(a){var s="";var l=t.dataSource.view();for(var 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 h=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+"']");var o=i[r];pe(t,h,o),e.on(A,(function(e){var n=e.target.value;pe(t,h,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(){he(s,i[r],t.dataParentValueField,t.dataValueField),ue(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(){he(s,i[r],t.dataParentValueField,t.dataValueField),ue(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)}}};var 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),F.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;var r=i.options.messages;var o=i.options.timezone;var 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}];var s=function(e){return!!e[c.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=this.options.resources[l];var d,h;c.dataSource.view().some(s)&&(d=this.options.resources[l-1])&&(h=d.field),a.push({field:c.field,title:c.title,editor:c.multiple?e.multipleResources(c,t,h):e.resources(c,t,h)})}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>";const 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;const i=e.title;const 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;const 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);var a=this.options.editable.template;var 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}});var 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;var r=i.pane;var o=i.options.messages;var a=i.timezoneView;var s=a?a.content.find(".k-scheduler-timezones"):i.container.find(".k-scheduler-timezones");var c=s.find("input.k-timezone-toggle").data("kendoSwitch");var d=s.find("li.k-item:not(.k-zonepicker)").last();if(i._startTimezone=t.startTimezone||"",i._endTimezone=t.endTimezone||"",!a){var h='<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(h),a.contentElement.append(s.show()),a.element.on(k+y,".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;var 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;var r="";var o=this.options.messages;var a=o.save;var s=o.destroy;var c=o.cancel;var d=o.editor.editorTitle;var h=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 u=this.fields(me.mobile,t);var p=this;var f=[];r+=this._buildEditTemplate(t,u,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="'+h+'">'+h+"</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+y,"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);var e=this._views();var t;for(var n=0,i=e.length;n<i;n++)(t=e.eq(n).data("kendoView"))&&t.purge();e.remove(),this.container=null,this.editable&&(this.editable.options.model.unbind(A,this.toggleDateValidationHandler),this.editable.destroy(),this.editable=null),this.timezoneView=null}}});var _e=ge.extend({destroy:function(){this.close(),this.unbind()},editEvent:function(t){var i=this;var r=i.options.editable;var o="<div "+n.attr("uid")+'="'+t.uid+'" class="k-popup-edit-form k-scheduler-edit-form"><div class="k-edit-form-container">';var a;var s=i.options.messages;var l=s.save;var c=s.cancel;var d=s.destroy;var h=s.resetSeries;var u=this.fields(me.desktop,t);var p=[];var f;var m;o+=this._buildEditTemplate(t,u,p,!1);var g=v(r)?r.window:{};o+='<div class="k-edit-buttons">',o+=this.createButton({name:"update",text:l,attr:m,icon:"save"})+this.createButton({name:"canceledit",text:c,attr:m,icon:"cancel-outline"}),!t.isNew()&&!1!==r.destroy&&t.isRecurrenceHead()&&t.recurrenceException&&(o+=this.createButton({name:"resetSeries",text:h,attr:m})),t.isNew()&&!t.isRecurring()||!1===r.destroy||(o+='<span class="k-spacer"></span>'+this.createButton({name:"delete",text:d,attr:m,icon:"trash",fillMode:"flat",themeColor:"primary"})),a=e(o+="</div></div></div>"),n.applyStylesFromKendoAttributes(a,["display"]);var b=this.container=a.appendTo(i.element).eq(0).kendoWindow(_({modal:!0,resizable:!1,draggable:!0,title:s.editor.editorTitle,visible:!1,close:function(e){e.userTriggered&&i.trigger(I,{container:b,model:t})&&e.preventDefault()}},g));for(var w in i.editable=b.kendoEditable({fields:p,model:t,clearContainer:!1,validateOnBlur:!0,target:i.options.target}).data("kendoEditable"),p)"recurrenceRule"!==p[w].field&&(f=p[w].field,b.find("[name='"+f+"']").attr("aria-labelledby",f+"_label")),"isAllDay"===p[w].field&&b.find("label[for='"+f+"']").attr("id",f+"_label");return i.trigger(B,{container:b,model:t})?i.trigger(I,{container:b,model:t}):(r.window&&r.window.position?b.data("kendoWindow").open():b.data("kendoWindow").center().open(),b.on(k+y,"button.k-scheduler-cancel",(function(e){e.preventDefault(),e.stopPropagation(),i.trigger(I,{container:b,model:t})})),b.on(k+y,"button.k-scheduler-update",(function(e){e.preventDefault(),e.stopPropagation(),i.trigger("save",{container:b,model:t})})),b.on(k+y,"button.k-scheduler-delete",(function(e){e.preventDefault(),e.stopPropagation(),i.trigger(z,{container:b,model:t})})),b.on(k+y,"button.k-scheduler-resetSeries",(function(e){e.preventDefault(),e.stopPropagation(),i.trigger(P,{container:b,model:t})})),n.cycleForm(b),t.bind(A,i.toggleDateValidationHandler)),i.editable},close:function(){var e=this;var 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;var 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=this;var i=n.container.find(".k-scheduler-timezones");var r=i.find("input.k-timezone-toggle");var o=i.find(".k-form-field").last();var a=i.find(".k-scheduler-savetimezone");var s=i.find(".k-scheduler-canceltimezone");var l=n._timezonePopup;var c=function(t){if("startTimezone"===t.field){var n=e.startTimezone;r.prop(H,!n),n||(o.hide(),e.set("endTimezone",""),r.prop("checked",!1))}};var d;n._startTimezone=e.startTimezone,n._endTimezone=e.endTimezone,l||(n._timezonePopup=l=i.kendoWindow({modal:!0,resizable:!1,draggable:!0,title:n.options.messages.editor.timezoneEditorTitle,visible:!1,close:function(i){e.unbind(A,c),i.userTriggered&&n._revertTimezones(e),t&&t.focus()}}),r.on(k,(function(){o.toggle(r.prop("checked")),e.set("endTimezone","")})),a.on(k,(function(e){e.preventDefault(),d.close()})),s.on(k,(function(t){t.preventDefault(),n._revertTimezones(e),d.close()})),e.bind(A,c)),r.prop("checked",e.endTimezone).prop(H,!e.startTimezone),e.endTimezone?o.show():o.hide(),(d=l.data("kendoWindow")).center().open()}});var be=u.extend({init:function(t,i){var r=this;h.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+y+" selectstart"+y,(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;var n=t._selectedView;var i=t.toolbar;var 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"+y,this._resizeHandler)},_unbindResize:function(){e(window).off("resize"+y,this._resizeHandler)},dataItems:function(){var n=this.items();var i=this._data;var r=e.map(n,(function(t){return e(t).attr("data-uid")}));var o;var a;var s={};var l=r.length;for(o=0;o<l;o++)s[r[o]]=null;var c=i.length;for(o=0;o<c;o++){var d=i[o];s[d.uid]!==t&&(s[d.uid]=d)}var h=[];for(a in s)h.push(s[a]);return h},_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){var s;var l=a.dataSource.view();var c=0;for(var d=0;d<l.length;d++){var h=n.getter(a.dataValueField)(l[d]);var u=t+c+d;(s=this._groupsByResource(e.slice(1),u,i,h,a.field))[a.field]=h,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=this;var r=i.view();var a=i._selection;var s=r.groups;var l;if(e===t){var c;var d=r._selectedSlots;return a?(a&&a.events&&(c=i._selectedEvents()),{start:a.start,end:a.end,events:c,slots:d,resources:r._resourceBySlot(a)}):[]}if(!e)return i._selection=null,i._old=null,void r.clearSelection();if(Array.isArray(e)&&(e={events:e.splice(0)}),e.resources){var h;var u=[];var p=[];for(h in r.groupedResources&&i._groupsByResource(r.groupedResources,0,p),e.resources)u.push({field:h,operator:"eq",value:e.resources[h]});l=new n.data.Query(p).filter(u).toArray()}if(e.events&&e.events.length)return i._selectEvents(e.events,l),void i._select();if(s&&e.start&&e.end){var f=o(r._startDate);var m=n.date.addDays(o(r._endDate),1);var g;var v;e.start<m&&f<=e.end&&((g=l&&l.length?s[l[0].groupIndex]:s[0]).timeSlotCollectionCount()||(e.isAllDay=!0),(v=g.ranges(e.start,e.end,e.isAllDay,!1)).length&&(i._selection={start:n.timezone.toLocalDate(v[0].start.start),end:n.timezone.toLocalDate(v[v.length-1].end.end),groupIndex:v[0].start.groupIndex,index:v[0].start.index,isAllDay:v[0].start.isDaySlot,events:[]},i._select()))}},_selectEvents:function(e,t){var i=this;var r;var o=i.view();var a=o.groups;var s=e.length;var l=t&&t.length;var c=i._ctrlKey;for(i._ctrlKey=!0,r=0;r<s;r++)if(a&&l){var d=a[t[0].groupIndex];var h=[];var u=d.timeSlotCollectionCount();var p=d.daySlotCollectionCount();for(var f=0;f<u;f++)h=h.concat(d.getTimeSlotCollection(f).events());for(var m=0;m<p;m++)h=h.concat(d.getDaySlotCollection(m).events());(h=new n.data.Query(h).filter({field:e=>e.element[0].getAttribute("data-uid"),operator:"eq",value:e[r]}).toArray())[0]&&i._createSelection(h[0].element)}else{var g=o.element.find(n.format(".k-event[data-uid={0}], .k-task[data-uid={0}]",e[r]));g.length&&i._createSelection(g[0])}i._ctrlKey=c},_touchHandlers:function(){var e=this;var t;var i;var r;var o;var a;var s=e.wrapper;var l=e._touchMove.bind(e);s.on(C+y,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",(function(n){var r=e.wrapper.find(".k-scheduler-content");e._isTouch(n)&&(r.stop(!0,!1),e._touchPosX=t=e._tapPosition(n,"X"),e._touchPosY=i=e._tapPosition(n,"Y"),e._userTouched=!0,e.view()._scrolling=!1,a=Date.now(),s.on(S+y,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",l))})),s.on("contextmenu"+y,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",(function(t){e._preventFocus=!0})),s.on(T+y,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",(function(c){if(e._isTouch(c)){var d=Date.now()-a;var h=e.wrapper.find(".k-scheduler-content");var u=-e._amplitude*(3e3/d);r=e._tapPosition(c,"X"),o=e._tapPosition(c,"Y"),e._dragging||(e.options.selectable&&(Math.abs(r-t)<=10||Math.abs(o-i)<=10)&&e._mouseDownSelection(c),!n.support.kineticScrollNeeded&&d<200&&Math.abs(r-t)>10&&h.animate({scrollTop:h[0].scrollTop+u}),s.off(S+y,".k-scheduler-header-all-day td, .k-scheduler-content td",l))}}))},_navigation:function(){var e=this,t=e.wrapper;t.on("focus"+y,(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"+y,(function(){e._ctrlKey=e._shiftKey=!1})),t.on("keydown"+y,e._keydown.bind(e)),t.on("keyup"+y,(function(t){e._ctrlKey=t.ctrlKey,e._shiftKey=t.shiftKey}))},_selectable:function(){var e=this;var t=e.wrapper;if(e.options.selectable){t.on(x+y,".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+y,".k-scheduler-header-all-day td, .k-scheduler-content td",(function(i){var r=i.which;var o=i.button;var a=r&&3===r||o&&2==o;e._isTouch(i)||a||t.on(M+y,".k-scheduler-header-all-day td, .k-scheduler-content td",n)})),t.on("mouseup"+y+" mousecancel"+y,(function(){t.off(M+y,".k-scheduler-header-all-day td, .k-scheduler-content td",n)}))}},_mouseDownSelection:function(t){var i=t.which;var 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("."+R).removeClass(R)},_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("."+R).length?this._focusToolbar():this.toolbar&&this.toolbar.find("."+R).removeClass(R)},_select:function(){const t=this,n=t.view(),i=t.wrapper,r=t._selection,o=t._old?t._old.selection:null,a=t._old?t._old.eventsLength:null;let s=n.current();if(r&&(s&&(s.removeAttribute("id"),i.removeAttr("aria-activedescendant")),n.select(r),t._selection.eventElement=null,s=n.current(),s)){s.setAttribute("id",t._ariaId),i.attr("aria-activedescendant",t._ariaId);const h=t._old?t._old.selectionStart.getTime():null;const u=t._old?t._old.selectionEnd.getTime():null;const p=r.start.getTime()!==h||r.end.getTime()!==u;if(o!==s||r.events&&a!==r.events.length||p){var l=e(s).data("uid");if(t._old&&l&&l===e(t._old.selection).data("uid")&&r.events&&t._old.eventsLength===r.events.length)return;var c=t._selectedEvents();var d=n._selectedSlots;t._old={selection:s,eventsLength:c.length,selectionStart:r.start,selectionEnd:r.end},t.trigger(A,{start:r.start,end:r.end,events:c,slots:d,resources:n._resourceBySlot(r)})}}},_selectedEvents:function(){var e=this._selection.events;var t=e.length;var n=0;var i;var r=[];for(;n<t;n++)(i=this.occurrenceByUid(e[n]))&&r.push(i);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;var i=t.wrapper.find(".k-scheduler-content");var r=i[0].scrollHeight>i[0].clientHeight;var o=i[0].scrollWidth>i[0].clientWidth;var a=t._tapPosition(e,"Y");var s=t._tapPosition(e,"X");var l=i[0].scrollTop-Math.round(a-t._touchPosY);var c=i[0].scrollLeft-Math.round(s-t._touchPosX);var d=r&&Math.abs(a-t._touchPosY)>10;var h=o&&Math.abs(a-t._touchPosY)>10;t._dragging||n.support.kineticScrollNeeded||!t._isTouch(e)||(d||h)&&(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();var r=n._selection;if(r){var o=i.selectionByElement(e(t.currentTarget));if(o&&r.groupIndex===o.groupIndex){var a=o.startDate();var 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(R)?(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,h=[c.LEFT,c.RIGHT,c.UP,c.DOWN],u=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?h.indexOf(o)>-1?(t=o===c.UP||o===c.LEFT&&!u||o===c.RIGHT&&u,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("."+R).removeClass(R),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("."+R).removeClass(R),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(R)},_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,B,I,L,"add","dataBinding","dataBound","moveStart","move","moveEnd","resizeStart","resize","resizeEnd","navigate",A],destroy:function(){var t=this;if(h.fn.destroy.call(t),t.dataSource&&(t.dataSource.unbind(A,t._refreshHandler),t.dataSource.unbind(D,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(D,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(y),clearTimeout(t._moveTimer),t._model=null,t.toolbar=null,t.element=null,e(window).off("resize"+y,t._resizeHandler),n.destroy(t.wrapper)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.options.autoBind&&e.fetch?e.fetch():w(e)&&this.view(this._selectedView)},items:function(){var e=this.wrapper.find(".k-scheduler-content");var 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;var i;var r;var o;var a;var s;var l;var c=this;var d;var h;var u=0;var p=[];var f=[];var m=c._isMobile();var g=c.options.editable&&!1!==c.options.editable.move;var v=c.options.editable&&!1!==c.options.editable.resize;(g||v&&m)&&(c._dragging=!1,m&&n.support.mobileOS.android&&(u=5),c._moveDraggable=new n.ui.Draggable(c.element,{distance:u,filter:".k-event",ignore:".k-resize-handle",holdToDrag:m,autoScroll:!0}),g&&c._moveDraggable.bind("dragstart",(function(e){var a=c.view();var u=e.currentTarget;var f=c._isTouch(e);if(c._dragging=!0,!a.options.editable||!1===a.options.editable.move)return c._dragging=!1,void e.preventDefault();if(f&&!u.hasClass("k-event-active"))return c._dragging=!1,c.element.find(".k-event-active").removeClass("k-event-active"),void e.preventDefault();if(s=c.occurrenceByUid(u.attr(n.attr("uid"))),l=s.clone(),s.clone(),l.update(a._eventOptionsForMove(l)),l.inverseColor=c._isInverseColor(u),p=[],c._selection){var m=c._selection.events;for(var g=0;g<m.length;g++){var v=c.occurrenceByUid(m[g]).clone();var _=this.element.find('div.k-event[data-uid="'+v.uid+'"]').eq(0);v.update(a._eventOptionsForMove(v)),_.length&&(v.inverseColor=c._isInverseColor(_)),p.push(v)}}else p.push(l);t=a._slotByPosition(e.x.startLocation,e.y.startLocation),r=a._resourceBySlot(t),h=o=t.startOffset(e.x.startLocation,e.y.startLocation,c.options.snap),i=t,d=t,t&&!c.trigger("moveStart",{event:s})||e.preventDefault()})).bind("drag",(function(r){var u=c.view();var m=u._slotByPosition(r.x.location,r.y.location);var g;var v;var _;if(m){if(a=m.startOffset(r.x.location,r.y.location,c.options.snap),m.isDaySlot!==t.isDaySlot)if(m.isDaySlot!==d.isDaySlot){var b=e(t.element).index();var w=e(m.element).parent().children().eq(b);for(t=u._slotByPosition(w.offset().left,w.offset().top),o=t.startOffset(r.x.location,r.y.location,!0),f=p.map((function(e){return e.clone()})),_=0;_<p.length;_++)p[_].isAllDay!=m.isDaySlot&&(p[_].isAllDay=m.isDaySlot,p[_].end=n.date.getDate(p[_].start),p[_].start=n.date.getDate(p[_].start),m.isDaySlot||(n.date.setTime(p[_].start,n.date.getMilliseconds(u.startTime())),n.date.setTime(p[_].end,n.date.getMilliseconds(u.startTime())+u._timeSlotInterval())))}else t=e.extend(!0,{},d),o=h,p=f;for(g=a-o,_=0;_<p.length;_++)u._updateMoveHint(p[_],m.groupIndex,g);if(v=fe(l,g),c.trigger("move",{event:s,slot:{element:m.element,start:m.startDate(),end:m.endDate(),isDaySlot:m.isDaySlot},resources:u._resourceBySlot(m),start:v.start,end:v.end}))for(_=0;_<p.length;_++)u._updateMoveHint(p[_],m.groupIndex,g);else i=m}})).bind("dragend",(function(t){c.view()._removeMoveHint();var h=a-o;var u=fe(l,h);var m=u.start;var g=u.end;c._dragging=!1;var v=c.view()._resourceBySlot(i);if(!c.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()||d.isDaySlot!==i.isDaySlot||n.stringify(v)!==n.stringify(r))){c._isMultiDrag=p.length>1;for(var _=0;_<p.length;_++){var b=p[_];u=fe(b,h);var w=c.view()._eventOptionsForMove(b);var y=e.extend({isAllDay:b.isAllDay,start:u.start,end:u.end},w,v);c._updateEvent(null,b,y)}c._isMultiDrag&&(c.dataSource.sync(),c._isMultiDrag=!1)}t.currentTarget.removeClass("k-event-active"),this.cancelHold(),p=[],f=[]})).bind("dragcancel",(function(){c.view()._removeMoveHint(),this.cancelHold(),p=[],f=[]})),c._moveDraggable.bind("hold",(function(e){c._isTouch(e)&&(c.element.find(".k-event-active").removeClass("k-event-active"),c.options.selectable&&c._createSelection(e.currentTarget),e.currentTarget.addClass("k-event-active"))})))},_resizable:function(){var t;var i;var r;var o;var a;var s=this;var 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"));var 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));var h=s.view();var u=h._slotByPosition(l.x.location,l.y.location);if(u&&a.groupIndex==u.groupIndex){a=u;var p=t;var f=i;"south"==d?!a.isDaySlot&&a.end-n.date.toUtcTime(o.start)>=h._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>=h._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)>=h._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>=h._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:h._resourceBySlot(a)})?(t=p,i=f):h._updateResizeHint(o,a.groupIndex,t,i)}}},dragend:function(l){var d=e(l.currentTarget);var h=new Date(o.start.getTime());var u=new Date(o.end.getTime());var p=c(d);s._dragging=!1,s.view()._removeResizeHint(),"south"==p?u=n.timezone.toLocalDate(i):"north"==p?h=n.timezone.toLocalDate(t):"east"==p?u=a.isDaySlot?n.date.getDate(n.timezone.toLocalDate(i)):n.timezone.toLocalDate(i):"west"==p&&(a.isDaySlot?((h=new Date(n.timezone.toLocalDate(t))).setHours(0),h.setMinutes(0)):h=n.timezone.toLocalDate(t)),!s.trigger("resizeEnd",{event:r,slot:{element:a.element,start:a.startDate(),end:a.endDate()},start:h,end:u,resources:s.view()._resourceBySlot(a)})&&u.getTime()>=h.getTime()&&(o.start.getTime()==h.getTime()&&o.end.getTime()==u.getTime()||(s.view()._updateEventForResize(r),s._updateEvent(p,r,{start:h,end:u}))),a=null,r=null},dragcancel:function(){s._dragging=!1,s.view()._removeResizeHint(),a=null,r=null}})},_updateEvent:function(e,t,i){var o=this;var 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(L,{event:t})||(n&&n(),o._isMultiDrag||o.dataSource.sync())};var 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=l(t);var n;var i=e.toOccurrence({start:t.start,end:t.end});n=i.uid,s(o.dataSource.add(i),(function(){o._convertDates(e),o._selection&&o._selection.events.push(n)}))}),(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("."+R).removeClass(R),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;var a=o.deleteWindowTitle;var 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=this._editor.editable;var n=this.dataSource;var i;e=e||{},!this.trigger("add",{event:e})&&(t&&t.end()||!t)&&(this.cancelEvent(),e&&e.toJSON&&(e=e.toJSON()),(i=n.add(e))&&(this.cancelEvent(),this._editEvent(i)))},saveEvent:function(){var e=this;var t=e._editor;var n=e.dataSource;if(t){var i=t.editable;var r=t.container;var o=e._modelForContainer(r);var a,s,l;if(r&&i&&i.end()&&!e.trigger(L,{container:r,event:o})){if(!o.isOccurrence()&&o.recurrenceException&&!o.recurrenceRule){for(s=(a=n.data()).length-1;s>=0;s-=1)(l=a[s])&&l.recurrenceId===o.id&&n.remove(l);o.set("recurrenceException","")}o.dirty||o.isOccurrence()||e._convertDates(o,"remove"),n.sync()}}},cancelEvent:function(){var e=this._editor;var t=e.container;var n;t&&((n=this._modelForContainer(t))&&n.isOccurrence()&&(this._convertDates(n,"remove"),this._convertDates(this.dataSource.get(n.recurrenceId),"remove")),this.dataSource.cancelChanges(n),e.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("."+R).removeClass(R),this._bindResize()},_editRecurringDialog:function(e){var t=this;var 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;var 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;var r=e.startTimezone;var o=e.endTimezone;var a=e.start;var 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=this;var t;(t=this._isMobile()&&n.Pane?e._editor=new ve(this.wrapper,_({},this.options,{target:this,timezone:e.dataSource.reader.timezone,resources:e.resources,createButton:this._createButton.bind(this)})):e._editor=new _e(this.wrapper,_({},this.options,{target:this,createButton:this._createButton.bind(this),timezone:e.dataSource.reader.timezone,resources:e.resources}))).bind("cancel",(function(t){e.trigger("cancel",{container:t.container,event:t.model})?t.preventDefault():(e._preventRefresh=!1,e.cancelEvent(),e._attemptRefresh&&e.refresh(),e.focus())})),t.bind("edit",(function(t){e.trigger(B,{container:t.container,event:t.model})&&t.preventDefault()})),t.bind("save",(function(){e._preventRefresh=!1,e.saveEvent()})),t.bind("remove",(function(t){e._preventRefresh=!1,e.removeEvent(t.model)})),t.bind("resetSeries",(function(t){e._confirmation((function(n){e._preventRefresh=!1,n||(e.dataSource._removeExceptions(t.model),e.saveEvent())}),t.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=this;var n=e;var i=t.options.editable;var r;var o;var a;var s;var l;var c;var d=v(i)?i.editRecurringMode:"dialog";r=function(){var e=n.recurrenceId?n:n.toOccurrence();var i=t.dataSource.get(e.recurrenceId);t._convertDates(i),t._removeEvent(e)},o=function(){n.recurrenceId&&(n=t.dataSource.get(n.recurrenceId)),t._removeEvent(n)},a=function(){t.dataSource.remove(n),t.dataSource.sync()},("dialog"!=d||t._isEditorOpened())&&(s=function(){t._confirmation((function(e){e||r()}),n)},l=function(){t._confirmation((function(e){e||o()}),n)},c=function(){t._confirmation((function(e){e||a()}),n)});var h=l||o;var u=s||r;var p=c||a;if(t._isEditorOpened())e.isException()?u():e.isNew()?p():h();else{var f=t.options.messages.recurrenceMessages;t._showRecurringDialog(e,u,h,{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(B,n._viewEditHandler),n._viewEditHandler=function(e){n.editEvent(e.uid)},t.bind(B,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;var 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+"]");var r=t.toolbar.find(".k-views-dropdown");var 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();var n=this._size;var 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=this.options.views;var t;var n;var i;var r;var o;var a;var s;for(this.views={},this._viewsCount=0,a=0,s=e.length;a<s;a++){var l=!1;t=e[a],(r=v(t))?typeof(o=t.type?t.type:t)!==p&&(o=t.name||t.title,l=!0):(o=t,t={}),(n=we[o])&&!l&&(t.type=n.type,n.title=this.options.messages.views[o],"day"===n.type?n.messages={allDay:this.options.messages.allDay}:"agenda"===n.type&&(n.messages={event:this.options.messages.event,date:this.options.messages.date,time:this.options.messages.time})),t=_({title:o},n,r?t:{}),o&&(this.views[o]=t,this._viewsCount++,i&&!t.selected||(i=o))}i&&(this._selectedViewName=i)},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=w(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(D,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(D,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(){var t=this;var n=t.options.resources;var i=[];for(var r=0;r<n.length;r++){var o=n[r];var a=o.field;var s=o.name||a;var 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;var o=w(e)?{data:e}:e;var 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;var 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;var t=e.options;var n=t.height;var 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=this;var i=t.options;var r=t._processDefaults();var{tools:o,navigation:a}=t._processTools();var s=e("<div class='k-scheduler-toolbar'>");var l;t._processHandlers(r),t.wrapper.append(s),t.toolbar=s,s.kendoToolBar({resizable:!1,tools:o,defaultTools:r,parentMessages:i.messages}),!t._isMobile()||a&&0===a.length||(l=e("<div class='k-scheduler-toolbar'>"),t.wrapper.append(l),t.toolbar=t.toolbar.add(l),l.kendoToolBar({resizable:!1,tools:a||[...Q],defaultTools:r,parentMessages:i.messages})),t.toolbar.find(".k-nav-current .k-button-text").attr("data-"+n.ns+"bind","text: formattedDate"),t.toolbar.find(".k-m-date-format").attr("data-"+n.ns+"bind","text: formattedMobileDate"),t.toolbar.find(".k-y-date-format").attr("data-"+n.ns+"bind","text: formattedYear"),n.bind(t.toolbar,t._model),t.toolbar.find(".k-scheduler-search-input").attr({placeholder:i.messages.search,title:i.messages.search}),s.on("input"+y,".k-scheduler-search-input",n.throttle((function(e){t.dataSource.filter({logic:"or",filters:[{field:"title",operator:"contains",value:e.target.value},{field:"description",operator:"contains",value:e.target.value}]})}),250)),s.on(A+y,".k-views-dropdown, .k-scheduler-mobile-views",(function(){var e=this.value;t.trigger("navigate",{view:e,action:"changeView",date:t.date()})||t.view(e)})),t._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(R))},min:n.options.min,max:n.options.max})),n.calendar.element.on("keydown"+y,(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(R))})),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();var 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)}});var we={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 ye="k-scheduler-pdf-export";be.fn._drawPDF=function(t){var n=this.wrapper;var i=n[0].style.cssText;n.css({width:n.width(),height:n.height()}),n.addClass(ye);var r=this;var o=new e.Deferred;var 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(ye),r.resize(!0),r.resize(!0)}))})),o}}var ke=h.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.");h.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(){h.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>`));var Ce=n.template((({zone:e,territory:t})=>`<option value="${e}">${t}</option>`));var Se=h.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.");h.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;var r="";var 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;var 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;var n=t._zonePickerLabel;var 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(){h.fn.destroy.call(this),n.destroy(this.wrapper)},value:function(e){var n=this;var i=n._zone;var r="";var o="";var a;if(e===t)return n._value;(a=n._zonesQuery.filter({field:"zone",operator:"eq",value:e}).data[0])&&(o=a.zone,r=a.other_zone),n._zoneTitle.val(r),n._bindZones(r),i.val(o),(o=i[0].value)&&i.children.length>1?n._zonePickerLabel.show():n._zonePickerLabel.hide(),n._value=o}});d.plugin(Se)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.ContextMenu,i=e.extend,r=t.htmlEncode;var o="action";var 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");var 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)");var 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;var i=t.Class.extend({init:function(e){this.options=e,this.treelist=e.treelist}});var 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)}});var o=i.extend({exec:function(){this.treelist.addRow()}});var a=i.extend({exec:function(){var e=this.treelist,t=this.options.target.closest("tr");e.addRow(t)}});var 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)}});var l=i.extend({exec:function(){var e=this.treelist,t=this.options.target.closest("tr");e.removeRow(t)}});var 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)}});var 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)}});var h=i.extend({exec:function(){this.treelist.clearSelection()}});var u=i.extend({exec:function(){this.treelist.saveAsPDF()}});var p=i.extend({exec:function(){this.treelist.saveAsExcel()}});var 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:h,ExportPDFCommand:u,ExportExcelCommand:p,ToggleItemCommand:f}})}(window.kendo.jQuery);!function(e,t){var n=kendo.data;var i=kendo.htmlEncode;var r=kendo.dom;var o=r.element;var a=r.text;var s=r.html;var l=kendo._outerWidth;var c=e.extend({F10:121},kendo.keys);var d=kendo._outerHeight;var h=kendo.ui;var u=h.DataBoundWidget;var p=n.DataSource;var f=n.ObservableArray;var m=n.Query;var g=n.Model;var v=kendo.support.browser;var _=kendo.template;var b=kendo.toCamelCase;var w=kendo._activeElement;var y=kendo.support.touch;var k=Array.isArray;var x=e.extend;var C=e.map;var S=e.grep;var T=e.inArray;var M=e.isPlainObject;var A=Array.prototype.push;var D="string";var E="change";var I="itemChange";var z="error";var P="progress";var L=".";var B=".kendoTreeList";var H="click";var R="beforeEdit";var F="edit";var O="page";var V="save";var N="saveChanges";var $="expand";var U="collapse";var W="cellClose";var j="remove";var q="td:not(.k-group-cell):not(.k-hierarchy-cell):visible,th:not(.k-group-cell):not(.k-hierarchy-cell):visible";var 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";var K="dataBinding";var Y="dataBound";var Q="cancel";var X="tabIndex";var Z="filterMenuInit";var J="filterMenuOpen";var ee="columnHide";var te="columnShow";var ne="columnReorder";var ie="columnResize";var re="columnMenuInit";var oe="columnMenuOpen";var ae="columnLock";var se="columnUnlock";var le="filter";var ce="navigate";var de="sort";var he="parentId";var ue="dragstart";var pe="drag";var fe="drop";var me="dragend";var ge="tr:visible";var ve="td:visible";var _e="th:visible";var be="k-grid-norecords";var we="tr:not(.k-footer-template):visible";var ye=!1;var ke="k-checkbox";var xe="input[data-role='checkbox']."+ke;var Ce='<input class="'+ke+' k-checkbox-md k-rounded-md" data-role="checkbox" aria-label="Select row" aria-checked="false" type="checkbox">';var Se='<input class="'+ke+' k-checkbox-md k-rounded-md" data-role="checkbox" aria-label="Select all rows" aria-checked="false" type="checkbox">';var Te="k-selected";var Me="[\\x20\\t\\r\\n\\f]";var Ae=new RegExp("(^|"+Me+")(k-filter-row)("+Me+"|$)");var De="[ref-treelist-expand-collapse-icon]";var Ee="aria-label",Ie="aria-activedescendant",ze="[ref-blank-icon]";var Pe={wrapper:"k-treelist k-grid k-grid-md",header:"k-header k-table-th",button:"k-button",alt:"k-table-alt-row",editCell:"k-edit-cell",editRow:"k-grid-edit-row",dirtyCell:"k-dirty-cell",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"};var Le={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>`}};var Be=["create","createChild","edit","destroy","separator","select","separator","exportPDF","exportExcel","separator","expandItem","collapseItem","separator"];var He=["sortAsc","sortDesc","separator"];var Re=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:he},childrenMap:function(){var e=this;var t={};var n=e.data.length;var i;var r;var o;var a=e.options.idField;var s=e.options.parentIdField;if(e._childrenMap)return e._childrenMap;for(var l=0;l<n;l++)r=(i=this.data[l])[a],o=i[s],t[r]=t[r]||[],t[o]=t[o]||[],t[o].push(i);return e._childrenMap=t,t},idsMap:function(){var e=this;var t={};var n=e.data;var i=n.length;var r;var o=e.options.idField;if(e._idMap)return e._idMap;for(var a=0;a<i;a++)t[(r=n[a])[o]]=r;return e.idsMap=t,t},dataMaps:function(){var e=this;var t={};var n=e.data;var i=n.length;var r={};var o;var a;var s;var l=e.options.idField;var c=e.options.parentIdField;if(e._dataMaps)return e._dataMaps;for(var d=0;d<i;d++)a=(o=n[d])[l],s=o[c],r[a]=o,t[a]=t[a]||[],t[s]=t[s]||[],t[s].push(o);return e._dataMaps={children:t,ids:r},e._dataMaps},rootNodes:function(){var e=this;var t=e.data;var n=e.options.defaultParentId;var i=t.length;var r=[];var o;var a=e.options.parentIdField;for(var s=0;s<i;s++)(o=t[s])[a]===n&&r.push(o);return r},removeCollapsedSubtreesFromRootNodes:function(e){e=e||{};var t=this;var n=t.rootNodes();var i=[];var r;t._childrenMap=e.childrenMap=e.childrenMap||t.childrenMap(),e.maxDepth=e.maxDepth||1/0;for(var o=0;o<n.length;o++)r=t.removeCollapsedSubtrees(n[o],e),i=i.concat(r);return i},removeCollapsedSubtrees:function(e,t){var n=[];var i;var r;var o=(t=t||{}).childrenMap||{};var a=t.maxDepth||1/0;var s=o[e[this.options.idField]]||[];var l=xt(e.expanded)?t.expanded:e.expanded;if(n.push(e),s&&l)for(i=0;i<s.length&&!(n.length>=a);i++)r=this.removeCollapsedSubtrees(s[i],t),n=n.concat(r);return n}});var Fe=function(e){this.data=e||[]};(Fe.prototype=new m).constructor=Fe,Fe.process=function(e,n,i){n=n||{};var r=new Fe(e);var o=n.group;var a=m.normalizeGroup(o||[]).concat(m.normalizeSort(n.sort||[]));var s=n.filterCallback;var l=n.filter;var c=n.skip;var d=n.take;var h;var u;var p;var f;var g;return a&&i&&(r=r.sort(a,t,t,i)),l&&(r=r.filter(l),s&&(r=s(r)),h=r.toArray().length),a&&!i&&(r=r.sort(a),o&&(e=r.toArray())),n.processFromRootNodes&&(f=new Re(r.toArray(),n),l&&(p=f.childrenMap()),g=f.removeCollapsedSubtreesFromRootNodes({childrenMap:l||a&&a.length?t:n.childrenMap,expanded:n.expanded,maxDepth:c+d||1/0}),u=f.childrenMap(),r=new Fe(g)),c!==t&&d!==t&&(r=r.range(c,d)),o&&(r=r.group(o,e)),{total:h,data:r.toArray(),childrenMap:u,filteredChildrenMap:p}};var Oe=g.define({id:"id",parentId:he,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=he),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==he&&this.parentIdField!=he&&(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=he,Oe.define=function(e,n){n===t&&(n=e,e=Oe);var i=n.parentId||he;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={};var n=e instanceof g;var 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;var 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){var n=e.length;for(var 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;var i=n._isPageable();var r=i?this._getData():this.data();var o=i?n._getChildrenMap()||n.childrenMap(r):n._childrenMap(r);var a=this._subtree(o,e.id);var s=!xt(t)&&t;var 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;var i=n._createNewModel(t);return n._insertInDataMaps(i),p.fn.insert.call(n,e,i)},_filterCallback:function(e){var t=this;var n,i;var r={};var o=[];var a=e.toArray();var s=t._modelIdField();var l=t._modelParentIdField();var c=t._isPageable();var d=[];var h;for(n=0;n<a.length;n++)if(i=a[n],c){for(d=[],r[i[s]]||(r[i[s]]=!0,d.push(i)),h=t._parentNode(i);h&&!r[h[s]];)r[h[s]]=!0,d.unshift(h),h=t._parentNode(h);d.length&&(o=o.concat(d))}else for(;i&&(r[i[s]]||(r[i[s]]=!0,o.push(i)),!r[i[l]]);)r[i[l]]=!0,(i=this.parentNode(i))&&o.push(i);return new m(o)},_subtree:function(e,t){var n=this;var i=e[t]||[];var r=n._defaultParentId();var o=n._modelIdField();for(var 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={};var n,i,r,o;for(e=this._observeView(e),n=0;n<e.length;n++)r=(i=e[n]).id,o=i.parentId,t[r]=t[r]||[],t[o]=t[o]||[],t[o].push(i);return t},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;var n=t._createTreeView(e);return t._dataMaps=n.dataMaps(),t._dataMaps},_initChildrenMapForParent:function(e){var t=this;var n=t._getData();var i=t._getChildrenMap();var r=t._modelIdField();var o=t._modelParentIdField();var 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 Re(e,x(t,this._defaultTreeModelOptions()))},_defaultTreeModelOptions:function(){var e=this;var 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=this;var i={};var r,o,a;var s=(t=t||{}).filter;var l=t.skip;var c=t.take;var d=xt(l)||xt(c)?1/0:l+c;var h=n._isPageable();var u=t.filteredChildrenMap;var p=t.childrenMap;var f;if(h){if(xt(t.aggregate))return i;f=u||(p||n.childrenMap(n._getData()))}!h&&s&&(e=m.process(e,{filter:s,filterCallback:this._filterCallback.bind(this)}).data);var g=h?f:n._childrenMap(e);for(i[this._defaultParentId()]=new m(this._subtree(g,this._defaultParentId())).aggregate(t.aggregate),a=0;a<e.length&&!(a>=d);a++)r=e[a],o=this._subtree(g,r.id),i[r.id]=new m(o).aggregate(t.aggregate);return i},_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=this._childrenMap(n.data);var o,a,s,l;for(e=r[i]||[],a=0;a<e.length;a++)(s=e[a]).id!==i&&(o=!(!(l=r[s.id])||!l.length),s.loaded()||s.loaded(o||!s.hasChildren),(s.loaded()||!0!==s.hasChildren)&&(s.hasChildren=o),o&&(e=e.slice(0,a+1).concat(l,e.slice(a+1))));return n.data=e,n},_processPageableQuery:function(e,n){var i=this;var r=i._getDataMaps();var o;var a;return i._getData()===e&&r.children&&r.ids||(r=i._initDataMaps(i._getData())),n.childrenMap=r.children||{},n.idsMap=r.ids||{},o=i._processTreeQuery(e,n),i._replaceWithObservedData(o.data,e),i._processDataItemsState(o.data,o.childrenMap),i._replaceItemsInDataMaps(o.data),o.dataToAggregate=i._dataToAggregate(o.data,n),n.filter||i.filter()?(a=o.filteredChildrenMap,i._replaceInMapWithObservedData(a,e),i._setFilteredChildrenMap(a),n.filteredChildrenMap=a,i._calculateCollapsedTotal(o.data)):i._collapsedTotal=t,o},_dataToAggregate:function(e){var t=e[0]||{};return this._parentNodes(t).concat(e)},_replaceItemsInDataMaps:function(e){var n=this;var i=k(e)?e:[e];var r=n._defaultDataItemType();var o=n._defaultParentId();var a=n._modelIdField();var s=n._modelParentIdField();var l=n._getDataMaps();var c;var d;var h;for(var u=0;u<i.length;u++)(c=i[u])instanceof r&&(n._insertInIdsMap(c),h=(d=n._parentNodes(c))&&d.length?d[d.length-1]:t,c[s]===o?n._replaceInMap(l.children,o,c,r):h&&n._replaceInMap(l.children,h[a],c,r))},_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];var a=o?e[t].indexOf(o):-1;-1===a||o instanceof i||(e[t][a]=n)},_replaceWithObservedData:function(e,t){var n=this;var i=n._getDataMaps().ids||{};var r=n._modelIdField();var o=n._defaultDataItemType();var a;var s;var l;var c;var d;for(var h=0;h<e.length;h++)s=(a=e[h])[r],a instanceof o||(i[s]instanceof o?e[h]=i[s]:(l=n._getById(s),c=t.indexOf(l),l&&-1!==c&&(d=t.at(c),e[h]=d)))},_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();var n=this._modelIdField();xt(e[n])||(t[e[n]]=e)},_insertInChildrenMap:function(e,t){var n=this;var i=n._getChildrenMap()||{};var r=n._modelIdField();var o=n._modelParentIdField();var a=e[r];var 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();var i=this._modelIdField();xt(e[i])||(n[e[i]]=t)},_removeFromChildrenMap:function(e){var t=this;var n=t._getChildrenMap()||{};var 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||{};var i=this._modelParentIdField();var 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){var t=this._modelIdField();var n=this._getData();for(var 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;var 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;var 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;var 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 Fe.process(e,x(t,this._defaultTreeModelOptions(),{processFromRootNodes:!0}))},_processDataItemsState:function(e,t){var n=e.length;var i;for(i=0;i<n;i++)this._processDataItemState(e[i],t)},_processDataItemState:function(e,t){var n=this._defaultParentId();if(e.id!==n){var i=t[e.id]||[];var 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";var i=this.options.serverSorting||this.options.serverPaging||this.options.serverFiltering||this.options.serverGrouping||this.options.serverAggregates;var 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){var n=this;var i=n._modelIdField();var r=n._modelParentIdField();var o=e[i];var a=n._isPageable();for(;t;){if(t[r]===o)return!0;t=a?n._parentNode(t):n.parentNode(t)}return!1},_byParentId:function(e,t){var n=[];var i=this.view();var r;if(e===t)return[];for(var o=0;o<i.length;o++)(r=i.at(o)).parentId==e&&n.push(r);return n},_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||he},childNodes:function(e){return this._byParentId(e.id,this._defaultParentId())},allChildNodes:function(e,t){var n=this.data().filter((function(t){return t.parentId===e.id}));for(var 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||{};var t=this;var n=t._defaultParentId();var i=t._modelParentIdField();var r=[];var o=t._nodesWithoutParentInView(e);var a;var s;for(var l=0;l<o.length;l++)(a=o[l])[i]===n?r.push(a):(s=t._rootNode(a))&&-1===r.indexOf(s)&&r.push(s);return r},parentNode:function(e){return this.get(e.parentId)},_parentNode:function(e){var t=this;var n=t._modelParentIdField();var i=t._initIdsMap(t._getData());var r=e[n];return i[r]||t._getById(r)},_parentNodes:function(e){var t=this._parentNode(e);var n=[];for(;t;)n.unshift(t),t=this._parentNode(t);return n},_parentNodesNotInView:function(){var e=this;var t=e.view();var n=[];var i=e._defaultParentId();var r=e._modelIdField();var o=e._modelParentIdField();var a=[];var s;var l;var c;for(var d=0;d<t.length;d++)(l=t[d])[r],c=l[o],e._parentInView(c)||c===i||(s=(a=e._parentNodes(l))&&a.length?a[a.length-1]:e._getById(c))&&-1===n.indexOf(s)&&n.push(s);return n},_nodesWithoutParentInView:function(e){e=e||{};var t=this;var n=t.view();var i=e.childrenMap||t.childrenMap(t._getData());var r=t._modelIdField();var o=t._modelParentIdField();var a;var s=[];for(var l=0;l<n.length;l++)i[(a=n[l])[r]],t._parentInView(a[o])||s.push(a);return s},_parentInView:function(e){var t=this.view();for(var 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;var 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;var 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;var 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);var 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)");var i=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")};var 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=[];var 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){var t,n=0;for(var 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=h.Pager.extend({options:{name:"TreeListPager"},totalPages:function(){var e=this;var t=e.dataSource;return t&&t._filter?h.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}});var 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 h.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 h.Editable(this.wrapper,{fields:this.fields,target:e.target,skipFocus:e.skipFocus||!1,clearContainer:e.clearContainer,model:this.model,change:e.change})},_isEditable:function(e){return kt(e,this.model)},_fields:function(e){var t=[];var n,i,r;for(n=0,i=e.length;n<i;n++)r=e[n],this._isEditable(r)&&t.push({field:r.field,format:r.format,editor:r.editor,editorOptions:x(!0,{format:r.format},r.editorOptions),label:r.title||r.field||""});return t},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}});var 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;var 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 h.Window(this.wrapper,t.window)},_appendTemplate:function(e){var t=this.options.template;typeof t===D&&(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(H+B,"button[data-command='canceledit']",this._cancelProxy),this._saveProxy=this._save.bind(this),this.window.wrapper.on(H+B,"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(B)},_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)}});var 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}});var Ze=u.extend({init:function(t,n,i){if(u.fn.init.call(this,t,n),i&&(this._events=i),ye=kendo.support.isRtl(t),Pe.iconExpand=ye?"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"+B,this._resizeHandler)}this.options.contextMenu&&this._initContextMenu(),kendo.notify(this)},_draggable:function(){var t=this;var n=this.options.editable;var i=t.dataSource;var r=i._modelIdField();var o=i._modelParentIdField();var a=t._isPageable();var s,l;n&&n.move&&(s=n.move.reorderable,!1!==n.move.clickMoveClick&&this._hasDragHandleColumn&&(l=!0),this._dragging=new kendo.ui.HierarchicalDragAndDrop(this.wrapper,{autoScroll:!0,holdToDrag:y,filter:t._hasDragHandleColumn?"[ref-treelist-drag-cell]":"tbody>tr",itemSelector:"tr",allowedContainers:this.table,clickMoveClick:l,hintText:function(t){return(t=t.closest("tr")).children("td").map((function(){return e(this).text().replace(/<(\/?)script([^>]*)>/gi,"")})).toArray().join("<span class='k-drag-separator'></span>")},contains:function(e,t){var n=this.dataItem(t);var i=this.dataItem(e);return i==n||this.dataSource.contains(i,n)}.bind(this),itemFromTarget:function(e){var n=e.closest("tr");var i=n.prev();var r=n.next();var o;var a;return i&&(o=!t.sameLevel(i,n)),r&&(a=!t.sameLevel(r,n)),{item:n,content:n,first:o,last:a}},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(ue,{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 n=this.dataItem(e.destination);var s=this.dataItem(e.source);var l=s[o];var c=i._indexInChildrenMap(s);var d=e.position;if("over"==d){a&&(i._removeFromChildrenMap(s),s[o]=n?n[r]:null,i._initChildrenMapForParent(n),s[o]=l);var h=s.set("parentId",n?n.id:null);a&&h&&(i._removeFromChildrenMap(s),s[o]=l,i._removeFromChildrenMap(s),i._insertInChildrenMap(s,c))}else"before"==d?t.insertBefore(s,n):"after"==d&&t.insertAfter(s,n);e.source=s,e.destination=n,this.trigger(me,e)}.bind(this),reorderable:s,dropHintContainer:function(e){return e.children("td:visible").eq(0)},dropPositionFrom:function(e){const t=e.parent(),n=e.parent().contents(),i=e[0];let r=!1;if(t.find(ze).length)return e.prevAll(ze).length>0?"after":"before";if(t.is("[ref-treelist-drag-cell]"))r=n[0]!==i;else{const e=n.length;for(let t=0;t<e&&n[t]!==i;t++)3===n[t].nodeType&&(r=!0)}return r?"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=this;var r=i.dataSource;var o=r._modelParentIdField();var a=r.indexOf(e);var s=i._isPageable();var l=r._indexInChildrenMap(t);var c;var d=r._getChildrenMap()||{};var h=e[o];i._unbindDataSource(),i._unbindDataChange(),s&&r._removeFromChildrenMap(e),e[o]!=t[o]&&e.set("parentId",t&&t.parentId?t.parentId:null),r._data.splice(a,1),c=r.indexOf(t)+n,s&&(l+=n,d[h].length<=l&&(l=d[h].length),r._insertInChildrenMap(e,l)),r._data.splice(c,0,e),r._destroyed.pop(),i._bindDataChange(),i._bindDataSource(),i.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;var 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");var n=e(this.lockedContent).on("DOMMouseScroll"+B+" mousewheel"+B,this._wheelScroll.bind(this));this.content.on("scroll"+B,(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);var 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"+B,!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=e(this.current());var r=!1;var o,a;this._cancelEditor(),this._render(),this._adjustHeight(),this.options.navigatable&&((this._isActiveInTable()||this.editor)&&(o=(r=i.is("th"))?i.parent().children(":not(.k-group-cell)").index(i[0]):Math.max(this.cellIndex(i),0),a=!r&&i.parent().index()),this._restoreCurrent(o,r,a)),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){var t=e.length,n=new Array(2*t);for(var i=t;--i>=0;)n[i]=n[i+t]=e[i];e=n}return e},_showNoRecordsTemplate:function(){var t=this.options.scrollable&&!this.wrapper[0].style.height?` ${kendo.attr("style-margin")}="0 auto" ${kendo.attr("style-position")}="static"`:"";var n;var i;this._contentTree.render([]),this._hasLockedColumns&&this._lockedContentTree.render([]),n=kendo.format('<div class="k-grid-norecords-template"{1}>{0}</div>',this.options.messages.noRows,t),i=e(kendo.template((()=>kendo.format('<div class="{0}">{1}</div>',be,n)))({})),kendo.applyStylesFromKendoAttributes(i,["margin","position"]),i.insertAfter(this.table)},_showStatus:function(t){var n=this.element.find(".k-status");var 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=this;var t=this.element;var n=t.find(L+Pe.gridContentWrap);var i=t.find(L+Pe.gridHeader);var r=t.find(L+Pe.gridToolbar);var o=t.find(L+Pe.status);var a=e._isPageable()&&e.pager&&e.pager.element.is(":visible")?d(e.pager.element):0;var s;var l=kendo.support.scrollbar();t.css("height",this.options.height);var c,h,u;((c=t)[0].style.height||(h=c.height(),c.height("auto"),u=c.height(),c.height(""),h!=u))&&(s=e.options.hasHeader?t.height()-d(i)-d(r)-d(o)-a:t.height()-d(r)-d(o)-a,n.height(s),this._hasLockedColumns&&(l=this.table[0].offsetWidth>this.table.parent()[0].clientWidth?l:0,this.lockedContent.height(s-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){var i=!1;for(var r=0;r<e.length;r++){var o=e[r];var 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(),u.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(B),this._navigatableTables=null,this._headertables=null),this._current=null,this._resizeHandler&&e(window).off("resize"+B,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(B),this.wrapper&&this.wrapper.off(B),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,R,F,O,V,N,j,$,U,K,Y,Q,ue,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;var 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;var i=this._events;var 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;var o=e.Deferred().resolve().promise();var a=n.loaded();if(r._isIncellEditable()&&r.editor&&(e(w()).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=this;var t=e.dataSource;var n=t._getData();var i;var r=t._defaultPageableQueryOptions();e._renderProgress(!0);var o=t._getChildrenMap()||t.childrenMap(t._getData());t._processDataItemsState(n,o),i=t._processPageableQuery(n,r),r.childrenMap=i.childrenMap,r.filteredChildrenMap=i.filteredChildrenMap,t._aggregateResult=t._calculateAggregates(i.dataToAggregate,r),t.view(i.data),t.filter()||t._calculateCollapsedTotal(),e._refreshPager(),e._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);var 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);var 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"+B:"mousedown"+B,ge+">:visible",t._tableClick.bind(t)).on("focus"+B,t._tableFocus.bind(t)).on("focusout"+B,t._tableBlur.bind(t)).on("keydown"+B,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;var a;var 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&&(yt(this.table,!0),this._current.addClass("k-focus")))},current:function(e){return this._setCurrent(e,!0)},_setCurrent:function(t,n,i){var r=this;var 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;var n=this.options.scrollable;if(t&&n){var i=t.parent();var r=i.closest("table").parent();var o=r.is(".k-grid-content-locked,.k-grid-header-locked");var a=r.is(".k-grid-content-locked,.k-grid-content");var 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;var n=t.current();var i=e(t.table).add(t.header).add(t.lockedTable).add(t.lockedHeader);return n&&i.find(n).length>0?n:i.find(L+Pe.focused)},_scrollTo:function(t,n){var i=t.tagName.toLowerCase();var r="td"===i||"th"===i;var o=e(t).closest("table")[0];var a=t[r?"offsetWidth":"offsetHeight"];var s=n[r?"scrollLeft":"scrollTop"];var l=n[r?"clientWidth":"clientHeight"];var c="relative"===e(t).css("position")&&ye&&r?Math.abs(o.offsetLeft-t.offsetLeft):t[r?"offsetLeft":"offsetTop"];var d=c+a;var h=0;var u=0;var p=0;ye&&r&&(v.msie||v.edge?u=o.offsetLeft:(v.mozilla||v.webkit&&v.version>85)&&(p=o.offsetLeft-kendo.support.scrollbar())),h=(s=Math.abs(s+u-p))>c?c:d>s+l?a<=l?d-l:c:s,h=Math.abs(h+u)+p,n[r?"scrollLeft":"scrollTop"]=h},_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"),h=this.thead.find("tr").length+this.wrapper.find(".k-grid-footer-wrap table tr").length,u=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:h+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",u+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,h=0,u=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&&h<o&&(h=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?(u=Number(a[0].getAttribute("colspan")),p=Number(a[1].getAttribute("colspan"))):1===a.length&&0===a.prev().length?u=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<=h;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=u;n<=d-c-p;n++)r=0===u?n+1:n-u+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;var r=n.parent();var o=t.children(ge);var a=o.index(r);var s=this._currentDataIndex(t,n);var 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;var r=n.parent();var o=e.children(ge);var a=o.index(r);var s=this._currentDataIndex(e,n);var 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){var d=r.children(":not(.k-group-cell):not(.k-hierarchy-cell)");var h=d.filter(":hidden");for(var u=0,p=h.length;u<p;u++)d.index(h[u])<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();var i=this._navigatableTables.length;var r=Math.floor(i/2);var 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;var i=this.current();var r=e(t.target);var 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==(ye?c.RIGHT:c.LEFT)?this._moveColumn(i,!0):o&&t.ctrlKey&&i.is(".k-header")&&this.options.reorderable&&t.keyCode==(ye?c.LEFT:c.RIGHT)?this._moveColumn(i,!1):o&&t.keyCode==(ye?c.LEFT:c.RIGHT)?t.altKey?(this._handleExpand(i),n=!0):n=this._moveRight(i):o&&t.keyCode==(ye?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");var r=ot(st(this.columns));var o=i.index(e(t));var a=n?-1:1;var s=r[o];var 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();var 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;var n=e.parent();var 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=e.parent();var i=n.parent();var r=this.lockedTable&&this.lockedTable.children("tbody")[0]===i[0];var o=i[0]===this.tbody[0];var a;if(t?a=this.lockedTable?this.lockedTable.find(ge+" > td:visible").first():this.table.find(ge+" > td:visible").first():(o||r)&&(o&&this.lockedTable&&(n=this._relatedRow(n)),a=n.children(ve).first()),a&&a.length)return this._setCurrent(a),!0},_handleEnd:function(e,t){var n=e.parent();var i=n.parent();var r=this.lockedTable&&this.lockedTable.children("tbody")[0]===i[0];var o=i[0]===this.tbody[0];var a;if(t?a=this.table.find(we).last().children(ve).last():(o||r)&&(!o&&this.lockedTable&&(n=this._relatedRow(n)),a=n.children(ve).last()),a&&a.length)return this._setCurrent(a),!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=kendo._activeElement();var r;var o=this;var a;var s;var l;var c;return t&&t.parent().hasClass("k-grid-edit-row")?(o._isIncellEditable()?(a=t.parent(),l=t.index(),s=a.index(),c=a.closest("tbody"),o.closeCell(!0),o._setCurrent(c.children().eq(s).children().eq(l),!1,!0)):(r=e(t).parent().index(),i&&i.blur(),this.cancelRow(),r>=0&&this._setCurrent(this.items().eq(r).children(ve).first())),yt(o.table,!0),!0):t.has(i).length?(yt(o.table,!0),!0):!!t.parent().hasClass("k-filter-row")&&(this._filterFocusable().attr(X,-1),yt(this.table,!0),!0)},_handleEnterKey:function(t,n,i){var r=this.options.editable;var o=i.closest("[role=gridcell]");var a,s;return i.is("table")||e.contains(t[0],i[0])||(t=o),t.is("th")?(s=t.find(".k-link"),!(t.has(e(w())).length>0)&&(s.length?s.click():t.parent().hasClass("k-filter-row")?(this._filterFocusable().attr(X,0),t.find(":kendoFocusable").first().trigger("focus")):t.find(xe).trigger("focus"),!0)):(a=t.find(":kendoFocusable").first())[0]&&t.hasClass("k-focus")?(a.trigger("focus"),!0):r&&!i.is(":button,.k-button,textarea")?(o[0]||(o=t),this._handleEditing(o,!1,n),!0):(!r&&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=this;var a,s;if(!(o.options.editable&&o._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(s=this._filterFocusable(),!i&&s[s.length-1]===document.activeElement)return s.first().trigger("focus"),!0;if(i&&s[0]===document.activeElement)return s.last().trigger("focus"),!0}return!1}return a=e(w()).closest(L+Pe.editCell),!o.options._tabCycleStop&&(a[0]&&a[0]!==t[0]&&(t=a),(a=o._tabNext(t,n,i)).length?(o._handleEditing(t,a,a.closest("table")),!0):(o._preventPageSizeRestore=!1,!1))},_tabNext:function(e,t,n){var i=this;var r=!0;var 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=this,l=e(kendo._activeElement()),c=v.msie;var d=s.options.editable&&!1!==s.options.editable.update;var h=s._isIncellEditable();var u=e(n).parents("tr").index();var p=e(n).index();var f=e(t).parents("tr").index();var m=t.index();var g;if(i=e(i),a=h?t.hasClass(Pe.editCell):t.parent().hasClass("k-grid-edit-row"),s.editor){if((r=s.editor.wrapper)&&e.contains(r[0],l[0])&&(v.opera?l.trigger("blur").change().triggerHandler("blur"):(l.trigger("blur"),c&&l.trigger("blur"))),!s.editor)return void yt(s.table);if(!s.editor.end())return h?s._setCurrent(r):s._setCurrent(r.children().filter(ve).first()),void((o=r.find(":kendoFocusable").first()[0])&&o.focus());h?(s._preventPageSizeRestore=!0,s.closeCell(),s._preventPageSizeRestore=!1,0===e(s.table).add(s.lockedTable).find(L+Pe.editCell).length&&s._setCurrent(i.find("tbody").children().eq(f).children().eq(m))):(s.saveRow(),a=!0)}if((n=e(n).length&&0===i.find(n).length?i.find("tbody").children().eq(u).children().eq(p):n)&&s._setCurrent(n),yt(s.table,!0),d)if(!a&&!n||n){if(!s.current())return;var _=s.current().index();h?(s.editCell(s.current()),(g=e(s.table).add(s.lockedTable).find(L+Pe.editCell)[0])?s._current=e(g):s._setCurrent(s._findCurrentCell())):(s.editRow(s.current().parent()),s._setCurrent(s.editor.wrapper.children().eq(_)),s.current().removeClass("k-focus"))}else s.dataSource._restorePageSizeAfterAddChild()},_moveRight:function(e){var t=e.nextAll(ve).first();var n=e.parent();var 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]&&yt(this.table,!0),this._setCurrent(t),!0},_moveLeft:function(e){var t=e.prevAll(ve).first();var n=e.parent();var 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]&&yt(this.table,!0),this._setCurrent(t),!0},_moveUp:function(e,t){var n=e.parent().parent();var i;t?(i=(i=e.parent()).prevAll(we).first(),i=e.parent().is(we)?i.children().eq(e.index()):i.children(q).last()):(i=this._prevVerticalCell(n,e))[0]||(this._lastCellIndex=0,n=this._verticalContainer(n,!0),(i=this._prevVerticalCell(n,e))[0]&&yt(this.table,!0));var r=this._lastCellIndex||0;return this._setCurrent(i),this._lastCellIndex=r,!0},_moveDown:function(e,t){var n=e.parent().parent();var i;t?(i=(i=e.parent()).nextAll(we).first(),i=e.parent().is(we)?i.children().eq(e.index()):i.children(q).first()):(i=this._nextVerticalCell(n,e))[0]||(this._lastCellIndex=0,n=this._verticalContainer(n),(i=this._nextVerticalCell(n,e))[0]&&yt(this.table,!0));var r=this._lastCellIndex||0;return this._setCurrent(i),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())||yt(n.table,!0)})),r&&t.preventDefault())},_tableFocus:function(e){var t=this.current();var 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;var t=L+Pe.retry;e._userEvents=new kendo.UserEvents(e.element,{tap:e._onPress.bind(e),allowSelection:!0}),this.element.on(H+B,t,this._dataSourceFetchProxy).on(H+B,".k-button[data-command]",this._commandClick.bind(this)).on("input"+B,".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=De+",[class*='-i-arrow-rotate-cw']";return e(t).closest(":not(path,svg)").is(n)},_attachCellEditingEventHandlers:function(){var t=this;var n=t.options.editable;var i=t.selectable&&t.selectable.options.multiple;t._isIncellEditable()&&!1!==n.update&&t.wrapper.on(t.options._editCellEvent||H+B,"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(De)?(t.editor||t.dataSource._restorePageSizeAfterAddChild(),void(t._preventPageSizeRestore=!1)):void(t.editor?r.is(":not(.k-command-cell)")&&t.editor.end()&&(i&&e(w()).trigger("blur"),t.closeCell(),t.editCell(r)):t.editCell(r))})).on("mousedown"+B,"tr:not(.k-grouping-row) > td",(function(n){t.editor&&t._isPageable()&&!xt(t.dataSource._addChildPageSize)?t._preventPageSizeRestore=e(n.target).parents(L+Pe.editRow).length>0:t._preventPageSizeRestore=!1})).on("focusin"+B,(function(){e.contains(this,w())||(clearTimeout(t._closeCellTimeout),t._closeCellTimeout=null)})).on("focusout"+B,(function(n){t._closeCellTimeout=setTimeout((function(){!function(n){var i=w();var r=t.editor||{};var 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=this.columns;var n=Array.isArray(this.options.toolbar)?this.options.toolbar:[];var i,r,o,a;if(e){if(e=e.toLowerCase(),Le[e])return Le[e];for(i=0;i<t.length;i++)if(o=t[i].command)for(r=0;r<o.length;r++)if((a=o[r].name)&&a.toLowerCase()==e)return o[r];for(i=0;i<n.length;i++)if((a=n[i].name)&&a.toLowerCase()==e)return n[i]}},_commandClick:function(n){var i=e(n.currentTarget);var r=i.attr("data-command")||i.parent().attr("data-command");var o=this._commandByName(r);var 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;var n=e.currentTarget;clearTimeout(t._searchTimeOut),t._searchTimeOut=setTimeout((function(){t._searchTimeOut=null;var e=t.options;var i=e.search?e.search.fields:null;var r={filters:[],logic:"or"};var 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(H+B,"tbody > tr "+xe,n._checkboxClick.bind(n)),n.element.on(H+B,"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;var 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;var 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(L+Pe.gridToolbar);var n=e.find(L+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(L+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=(M(e)?e.name||"":e).toLowerCase(),o=n[r];if(!(r||M(e)&&e.template))throw new Error("Commands should have name specified");var a;e=x({},Le[r],{name:r,text:(Le[r]||{}).text||o||(a=r,a.charAt(0).toUpperCase()+a.slice(1)),type:e.template?null:"button"},e),"search"===r&&(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(r)&&(e.attributes||(e.attributes={}),e.attributes["data-command"]=r,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;var t=this.toolbar;e&&(Array.isArray(e)?t.kendoToolBar({size:"medium",navigateOnTab:!this.options.navigatable,items:this._processToolbarItems(e)}):M(e)?t.kendoToolBar({size:"medium",navigateOnTab:!this.options.navigatable,items:this._processToolbarItems(e.items||[]),overflow:e.overflow}):t.append(kendo.template(e)({})))},_initContextMenu:function(){var e=this,t=e.options,n=M(t.contextMenu)&&k(t.contextMenu.body)?{items:t.contextMenu.body}:{items:Be},i=M(t.contextMenu)&&k(t.contextMenu.head)?{items:t.contextMenu.head}:{items:He};var r=M(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 h.treelist.ContextMenu("<ul></ul>",n),e.theadContextMenu=new h.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 h.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;var o=n._isPageable();var a=n.dataSource;var s={children:t.filteredChildrenMap||t.childrenMap,ids:t.idsMap};var l=o?s&&s.children&&s.ids?s:a._initDataMaps(a._getData()):{};var c=l.children;var d=l.ids;t.childrenMap=c,t.idsMap=d;var h=n._dataToRender(t);var u=n._renderedModelLevel(h[0],t);var p=kendo.attr("uid");var f;var m=this.select().removeClass("k-selected").map((function(t,n){return e(n).attr(p)}));var g;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})):h.length?(o&&(g=n._viewChildrenMap(t)),this._hideStatus(),f=this._hasFooterTemplate(),n._renderRows(t,h,it(_t(this.columns)),m,c,g,f),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:m,data:h,childrenMap:c,viewChildrenMap:g,hasFooterTemplate:f,visible:!0,level:u,isLockedTable:!0})))):(this._hideStatus(),this._showNoRecordsTemplate()),this._touchScroller&&this._touchScroller.contentResized(),this.items().filter((function(){return e.inArray(e(this).attr(p),m)>=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;var n=t.dataSource._getDataMaps();var 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=this;var n=t.dataSource;var i=n.childrenMap(n.view());var r=n._modelIdField();var o=n._parentNodesNotInView();var a;var s;var l;var c;var d;var h;t._clearRenderMap();for(var u=0;u<o.length;u++){s=(a=o[u])[r],t._markNodeAsNonRenderable(s),i[s]=i[s]||[],(h=n._parentNodes(a).slice()).push(a);for(var p=0;p<h.length-1;p++)l=h[p][r],t._markNodeAsNonRenderable(l),i[l]=i[l]||[],d=(c=h[p+1])[r],t._markNodeAsNonRenderable(d),i[d]=i[d]||[],-1===i[l].indexOf(c)&&i[l].unshift(c)}return i},_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=e[0].rows;var i=n.length;var r;var o=t[0].rows;var a=e.add(t);var s=a.length;var l=[];for(r=0;r<i&&o[r];r++)n[r].style.height&&(n[r].style.height=o[r].style.height="");for(r=0;r<i&&o[r];r++){var c=n[r].offsetHeight;var d=o[r].offsetHeight;var h=0;c>d?h=c:c<d&&(h=d),l.push(h)}for(r=0;r<s;r++)a[r].style.display="none";for(r=0;r<i;r++)l[r]&&(n[r].style.height=o[r].style.height=l[r]+1+"px");for(r=0;r<s;r++)a[r].style.display=""}},_ths:function(t,n){var i=[];var r,l,c,d,h,u;var p;var f;for(var m=0,g=t.length;m<g;m++){if(r=t[m],c=[],d=[Pe.header],r.selectable){f=it(t),p=T(r,f),h={scope:"col",role:"columnheader",className:d.join(" ")},r.headerTemplate&&(l=r.headerTemplate({})),l=r.headerTemplate?l:kendo.template((()=>Se))({}),n&&!r.colSpan&&(h.rowSpan=n),p>-1&&(h[kendo.attr("index")]=p),c.push(s(l)),i.push(o("th",e.extend(!0,{},h,r.headerAttributes),c));continue}if(l=r.headerTemplate?r.headerTemplate({}):r.title||r.field||"",u=r.headerTemplate?s(l):a(l),this.options.sortable?r.draggable||c.push(o("span",{className:Pe.headerCellInner},[o("span",{className:Pe.link},[o("span",{className:Pe.columnTitle},[u])])])):c.push(u),h={"data-field":r.field,"data-title":r.title,style:!0===r.hidden?{display:"none"}:{},className:d.join(" "),role:"columnheader"},this.options.sortable&&!1!==r.sortable){let e=`${r.title||r.field}. ${this.options.messages.sortHeader}`;h["aria-label"]=e,h.title=e}r.columns||(h.rowSpan=n||1),r.headerAttributes&&(1===r.headerAttributes.colSpan&&delete r.headerAttributes.colSpan,r.headerAttributes.class&&(h.className+=" "+r.headerAttributes.class)),r["data-index"]>-1&&(h["data-index"]=r["data-index"]);let g={...r.headerAttributes};delete g.class,h=x(!0,{},h,g),i.push(o("th",h,c))}return i},_cols:function(e){var t=[];var n,i;for(var r=0;r<e.length;r++)!0!==e[r].hidden&&(i={},(n=e[r].width)&&0!==parseInt(n,10)&&(i.style={width:"string"==typeof n?n:n+"px"}),e[r].draggable&&(i.class="k-drag-col"),t.push(o("col",i)));return t},_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]){var r=t[0];for(;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;var n=t.columns||[];var i=t.thead.find(">tr:not(:first, .k-filter-row)");var r;n=_t(n),r=t._retrieveFirstColumn(n,i),t.lockedHeader&&(i=t.lockedHeader.find("thead>tr:not(.k-filter-row):not(:first)"),n=vt(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")}))},_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;var i=[];var r;var o=t?function(e){return ot(e.columns).length&&e.hidden}:function(e){return!ot(e.columns).length&&!e.hidden};if(ut(e,this.columns,i)&&i.length)for(n=i.length-1;n>=0;n--)o(r=i[n])&&(r.hidden=!t)},_prepareColumns:function(t,n,i,r,o){var a=r||t[t.length-1];var s=t[a.index+1];var l=0;for(var 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;var r=[];var a=[];var 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);var 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){var n;var i;var r=kendo.attr("uid");for(var 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=it([n]);var o=e(this.lockedHeader).add(this.thead).find("tr.k-filter-row th");var a;var s;var 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=r.length-1;d>=0;d--)s=c(o,(n=r[d]).headerAttributes.id),a=c(o,i.headerAttributes.id),o.eq(s)[t?"insertBefore":"insertAfter"](o.eq(a))},_applyLockedContainersWidth:function(){if(this._hasLockedColumns){var e=this.options.hasHeader?Ge(this.lockedHeader.find(">table>colgroup>col")):Ge(this.lockedTable.find(">colgroup>col"));var t=this.options.hasHeader?this.thead.parent():this.tbody.parent();var n=Ge(t.find(">colgroup>col"));var i=this.wrapper[0].clientWidth;var 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=this;var i,r,o,a,s,l,c;var d;var h=[];var u=t.level;var p=t.data;var f=this.dataSource;var m=f.aggregates()||{};var g=f._modelIdField();var v=f._modelParentIdField();var _=t.columns;var b=n._isPageable();var w=t.isLockedTable;var y=t.childrenMap||f.childrenMap(f._getData());for(l=0,c=p.length;l<c;l++){if(o=["k-table-row"],d=(i=p[l])[g],a=(s=b?y[d]:i.loaded()?f.childNodes(i):[])&&s.length,(r={role:"row"})[kendo.attr("uid")]=i.uid,!w&&a&&(r["aria-expanded"]=!!i.expanded),t.visible?(!b||b&&!n._skipRenderingMap[d])&&(this._absoluteIndex%2!=0&&o.push(Pe.alt),this._absoluteIndex++):r.style={display:"none"},e.inArray(i.uid,t.selected)>=0&&o.push(Pe.selected),i._edit&&o.push("k-grid-edit-row"),r.className=o.join(" "),!n._skipRenderingMap[d]){var k;var x=n._generateRowOptions(i,r,b,t,u,a);k=n.options.rowTemplate?this._trFromTemplate(x):this._renderRow(x,_,this._td.bind(this)),h.push(k)}if(a&&(n.options.renderAllRows||i.expanded)){if(b&&(s=(t.viewChildrenMap||{})[d]||[]),0===s.length)continue;h=h.concat(this._trs({columns:_,editedColumn:t.editedColumn,editedColumnIndex:t.editedColumnIndex,aggregates:m,selected:t.selected,visible:b?t.visible:t.visible&&!!i.expanded,data:s,childrenMap:t.childrenMap||y,hasFooterTemplate:t.hasFooterTemplate,viewChildrenMap:t.viewChildrenMap,level:u+1,isLockedTable:t.isLockedTable}))}}return t.hasFooterTemplate&&i&&(r={className:Pe.footerTemplate+" k-table-row","data-parentId":i[v]},t.visible||(r.style={display:"none"}),h.push(this._tds({model:m[i[v]],attr:r,level:u,editedColumn:t.editedColumn,editedColumnIndex:t.editedColumnIndex},_,this._footerId))),h},_trFromTemplate:function(t){var n=this.options.rowTemplate;var i=this.options.altRowTemplate;var r;return i=i||n,kendo.isFunction(n)||(n=kendo.template(n)),kendo.isFunction(i)||(i=kendo.template(i)),r=this._absoluteIndex%2!=0?n(t):i(t),e(r).length?this.parseRowTemplate(e(r)[0],t):a(r)},parseRowTemplate:function(t,n){var i=t.nodeName.toLocaleLowerCase();var r=t.childNodes;var s=[];var l;l=this.parseAttributes(t);for(var c=0;c<r.length;c++)/\S/.test(r[c].nodeValue)&&"td"===r[c].nodeName.toLocaleLowerCase()&&s.push(this._createCellElement(r[c]));return n&&!n.visible&&(l.style=l.style||{},l.style=e.extend(!0,l.style,{display:"none"})),this._isTextNode(i)?a(t.nodeValue):o(i,l,s)},_createCellElement:function(t){var n=this.parseAttributes(t);var i=e(t).find("."+Pe.iconHidden).remove();var r=e(t).find(De).remove()[0];var a=[];for(var 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;var n=(t=e(t)[0]).attributes;var i=n.length;var r={};for(var 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=[];var i=t.column;var r=t.column.footerTemplate||e.noop;var a=t.model[i.field]||{};var 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){var i=[];var r;var a=(e.editedColumn||{}).field;var s=this._isIncellEditable();var l=t.length;for(var c=0;c<l;c++){r=t[c];var d=n({model:e.model,column:r,editColumn:!s||s&&r.field===a&&e.editedColumnIndex===c,level:e.level});i.push(d)}return o("tr",e.attr,i)},_td:function(t){var n=[];var i=t.model;var r=t.column;var a=kendo.defaults.iconType;var l;var c={role:"gridcell",class:"k-table-td",style:!0===r.hidden?{display:"none"}:{}};var d=this._isIncellEditable();var h=!1;return r.attributes&&x(!0,c,r.attributes),r.headerAttributes&&r.headerAttributes.id&&(c["aria-describedby"]=r.headerAttributes.id),i._edit&&r.field&&t.editColumn&&(d||!d&&kt(r,i))?(c[kendo.attr("container-for")]=r.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))):(r.expandable&&(n=qe({level:t.level,className:Pe.iconPlaceHolder}),i.hasChildren?(c.ariaExpanded=i.expanded,l=i.expanded?Pe.iconCollapse:Pe.iconExpand):l=Pe.iconPlaceHolder,i._error?l=Pe.refresh:!i.loaded()&&i.expanded&&(l="loading",c["aria-busy"]=!0),n.push(s(kendo.ui.icon(e(`<span ref-treelist-expand-collapse-icon ${l===Pe.iconPlaceHolder?"ref-blank-icon":""} class="k-treelist-toggle ${l===Pe.iconPlaceHolder?"":"loading"===l?"k-i-loading":""}"></span>`),{icon:l,type:a}),!0)),c.style["white-space"]="nowrap"),function(e,t){var n=(e||{}).field||"";return t.dirty&&t.dirtyFields&&t.dirtyFields[n]&&kt(e,t)}(r,i)&&(c.className?c.className+=Pe.dirtyCell:c.className||(c.className=Pe.dirtyCell)),r.draggable&&(c.class+=" k-drag-cell k-touch-action-none",c["ref-treelist-drag-cell"]=!0,void 0===c[Ee]&&(c[Ee]=this.options.messages.dragHandleLabel),c.style.cursor="move"),r.command?(c.className&&-1!==c.className.indexOf("k-command-cell")?c.className+=" k-command-cell":c.className||(c.className="k-command-cell"),h=S(r.command,(function(e){return e===F||e.name===F})).length>0,n=i._edit&&!this._isIncellEditable()&&h?this._buildCommands(["update","canceledit"]):this._buildCommands(r.command)):n.push(this._cellContent(r,i)),c.className=[c.class,c.className].join(" ").trim()),o("td",c,n)},_cellContent:function(e,t){var n;var i=this._isIncellEditable();var r;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),r=i?e.dirtyIndicatorTemplate(t):"",null===n||xt(n)?n=r:(e.format&&(n=kendo.format(e.format,n)),n=r+n)):(null===n||xt(n))&&(n=""),e.template||!e.encoded||i?s(n):a(n))},_evalColumnTemplate:function(e,t){return this._isIncellEditable()?e.dirtyCellTemplate(t):e.template(t)},_createDirtyColumnTemplate:function(e){var t=this;var 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();var i=this.options.messages.commands[n];return(e=x({},Le[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=e(t.currentTarget);var i=this.resizeHandle;var r=n.position();var o;var a=0;var s;var c;var h;var u;var p;var f;var m=l(n);var g=n.closest("div");var _=void 0!==t.buttons?t.buttons:t.which||t.button;var b=this.options.columnResizeHandleWidth||3;var w=3*b/2;if(o=m,void 0===_||0===_){i||(i=this.resizeHandle=e('<div class="k-resize-handle"><div class="k-resize-handle-inner"></div></div>'));var y=je(n.closest("thead")).filter(":visible");if(ye)f=kendo.scrollLeft(g),(v.mozilla||v.webkit&&v.version>=85)&&(f*=-1),p=parseFloat(g.css("borderLeftWidth")),a=(o=n.offset().left+f-parseFloat(n.css("marginLeft"))-(g.offset().left+p))<=f?w:0,u=(s=n.closest(".k-grid-header-wrap, .k-grid-header-locked"))[0].scrollWidth-s[0].offsetWidth,h=parseFloat(s.css("marginLeft")),c=v.msie?2*kendo.scrollLeft(s)+p-h-a:0,o-=(v.webkit&&v.version<85?u-a-h+p:-a)+(v.mozilla?p-h-a:0)+c;else for(var k=0;k<y.length&&y[k]!=n[0];k++)o+=y[k].offsetWidth;g.append(i),i.show().css({top:r.top,left:o-w,height:d(n),width:3*b}).data("th",n);var x=this;i.off("dblclick"+B).on("dblclick"+B,(function(){var t=n.index();e.contains(x.thead[0],n[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,h=s.lockedHeader?je(s.lockedHeader.find(">table>thead")).filter(Ue).length:0;if((t="number"==typeof t?d[t]:M(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 u=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&&h>=n&&!o&&(n-=h);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(u.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)):u.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(n);var g=r.add(u).add(f);var 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(u.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){var b,w=r.find("col"),y=0;for(var k=0,x=w.length;k<x;k+=1){if(!(b=w[k].style.width)||-1!=b.indexOf("%")){y=0;break}y+=parseInt(b,10)}y&&g.each((function(){this.style.width=y+"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();var 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");var 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=e.offsetHeight;var i=t.offsetHeight;var r;var o;n>i?(r=t.rows[t.rows.length-1],Ae.test(r.className)&&(r=t.rows[t.rows.length-2]),o=n-i):(r=e.rows[e.rows.length-1],Ae.test(r.className)&&(r=e.rows[e.rows.length-2]),o=i-n),r.style.height=r.offsetHeight+o+"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"+B,"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=e(n.currentTarget).data("th");var r=e.inArray(i[0],je(i.closest("thead")).filter(":visible"));var o,a;t.wrapper.addClass("k-grid-column-resizing"),t.lockedHeader&&e.contains(t.lockedHeader[0],i[0])?(o=t.lockedHeader,a=t.lockedTable):(o=t.thead.parent(),a=t.table),this.col=a.children("colgroup").find("col").eq(r).add(o.find("col").eq(r)),this.th=i,this.startLocation=n.x.location,this.columnWidth=l(i),this.table=this.col.closest("table"),this.totalWidth=this.table.width()},resize:function(e){var t=ye?-1:1;var 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");var n=S(it(t.columns),(function(t){return t.field==e}));var 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;var i;var r;var o;var a,s,l;var c=this.options.sortable;var d=S(this.columns,(function(e){return e.columns!==t})).length>0;var h=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:h})))},_filterable:function(){var n;var i=this.options.filterable;var r;var o;var a;var s;var l;var c;var d=S(this.columns,(function(e){return e.columns!==t})).length>0;if(i&&!this.options.columnMenu){var h=function(e){this.trigger(Z,{field:e.field,container:e.container})}.bind(this);var u=function(e){this.trigger(J,{field:e.field,container:e.container})}.bind(this);var 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"),a=it(this.columns),i&&typeof i.mode==D&&-1==i.mode.indexOf("menu")&&(i=!1),i)for(r=0,o=n.length;r<o;r++)s=a[r],(c=(l=n.eq(r)).data("kendoFilterMenu"))&&c.destroy(),s.draggable||s.command||!1===s.filterable||s.selectable||l.kendoFilterMenu(x(!0,{},i,s.filterable,{dataSource:this.dataSource,init:h,open:u,change:p,appendTo:L+Pe.headerCellInner}))}},_filterRow:function(){var t=this;if(t._hasFilterRow()){var n;var i=kendo.attr("uid");var r,o=it(t.columns),a=t.options.filterable,s=this._filter.bind(this);for(var l=0;l<o.length;l++){var c,d=o[l],h=t.options.filterable.operators,u=!1,f=this.wrapper.find(".k-grid-header .k-filter-row th["+i+'="'+d.headerAttributes.id+'"]'),m=d.field,g=d.parentColumn;if(delete d.parentColumn,m&&!1!==d.filterable){var v=d.filterable&&d.filterable.cell||{};(r=f.find(".k-filtercell").data("kendoFilterCell"))&&(r.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(" ");continue}v.dataSource&&(c=v.dataSource,u=!0),d.filterable&&d.filterable.operators&&(h=d.filterable.operators),n={column:d,dataSource:t.dataSource,suggestDataSource:c,customDataSource:u,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:h,showOperators:v.showOperators,change:s},e("<span/>").attr(kendo.attr("field"),m).appendTo(f).kendoFilterCell(n),d.parentColumn=g}else f.html(" ")}this._filterFocusable().attr(X,-1)}},_hasFilterRow:function(){var t=this.options.filterable;var n=t&&typeof t.mode==D&&-1!=t.mode.indexOf("row");var i=this.columns;var r=e.grep(i,(function(e){return!1===e.filterable}));return i.length&&r.length==i.length&&(n=!1),n},_change:function(){var e=this;var t;e._checkBoxSelection&&(t=e.selectable.value(),e._uncheckCheckBoxes(),e._checkRows(t),t.length&&t.length===e.items().length?e._toggleHeaderCheckState(!0):e._toggleHeaderCheckState(!1)),this.trigger(E)},_isLocked:function(){return null!==this.lockedHeader},_selectable:function(){var n=this;var i=this.options.selectable;var r;var o=this.table;var a;var s=n._isLocked();var l;var d;i&&(i=kendo.ui.Selectable.parseOptions(i),this._hasLockedColumns&&(o=o.add(this.lockedTable),a=i.multiple&&i.cell),r=">tbody>tr:not(.k-footer-template)",i.cell&&(r+=">td"),this.selectable=new kendo.ui.Selectable(o,{filter:r,aria:!0,multiple:i.multiple,change:this._change.bind(this),useAllItems:a,continuousItems:this._continuousItems.bind(this,r,i.cell),relatedTarget:!i.cell&&this._hasLockedColumns?this._selectableTarget.bind(this):t}),n.options.navigatable&&(l=i.multiple,d=i.cell,o.on("keydown"+B,(function(t){var i=n.current();if(i){var r=t.target;if(t.keyCode===c.SPACEBAR&&!t.shiftKey&&e.inArray(r,o)>-1&&!i.is(".k-header")){if(t.preventDefault(),t.stopPropagation(),i=d?i:i.parent(),s&&!d&&(i=i.add(n._relatedRow(i))),l)if(t.ctrlKey){if(i.hasClass(Pe.selected))return i.removeClass(Pe.selected),void n.trigger(E)}else n.selectable.clear();else n.selectable.clear();d||(n.selectable._lastActive=i),n.selectable.value(i),n.trigger(E)}else!d&&(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(),i=i.parent(),s&&(i=i.add(n._relatedRow(i))),l?(n.selectable._lastActive||(n.selectable._lastActive=i),n.selectable.selectRange(n.selectable._firstSelectee(),i)):(n.selectable.clear(),n.selectable.value(i)),n.trigger(E))}}))))},_continuousItems:function(t,n){if(this.lockedContent){var i=e(t,this.lockedTable);var r=e(t,this.table);var o=n?vt(this.columns).length:1;var a=n?this.columns.length-o:1;var s=[];for(var 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){var n;var i=e();for(var 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));var 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;var 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;var i=this.dataSource;var 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),M(e)&&(x(e,{table:n.table,fields:n.columns}),M(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=this;var n;!this._isIncellEditable()&&this.options.editable&&(typeof e===D&&(e=this.tbody.find(e)),(n=t._isPageable()&&t._isPopupEditable()&&e instanceof Oe?e:this.dataItem(e))&&(t.editor?(n._edit=!0,this._render(),this._cancelEditor()):t._preventPageSizeRestore=!1,"popup"!=this._editMode()&&(n._edit=!0),this.trigger(R,{model:n})?t.dataSource._restorePageSizeAfterAddChild():(this._render(),this._createEditor(n),this.trigger(F,{container:this.editor.wrapper,model:n}))))},_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()),yt(this.table,!0))))},cancelRow:function(){this._isIncellEditable()||(this._cancelEditor(),this._render())},saveRow:function(){var e=this.editor;var t;this._isIncellEditable()||e&&(t={model:e.model,container:e.wrapper},e.end()&&!this.trigger(V,t)&&this.dataSource.sync())},addRow:function(e){var t=this;var n=t.dataSource;var i=t._isPageable();var r=t._isIncellEditable();var o=t._isInlineEditable();var a=this.editor;var s=0;var 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;var r=i.dataSource;e=i.dataSource.insert(t,e),n&&r._setAddChildPageSize();var o=this._itemFor(e);var a;i._isIncellEditable()?(a=o.children("td").eq(i._firstEditableColumnIndex(o)),i.editCell(a)):o&&o[0]?i.editRow(o):(i._isPageable()||i.dataSource.filter())&&(i._isPopupEditable()||i._isInlineEditable())&&i.editRow(e)},_firstEditableColumnIndex:function(e){var t=this.dataItem(e);var n=it(this.columns);var i=n.length;var r;var o;for(o=0;o<i;o++)if(r=n[o],t&&(!t.editable||t.editable(r.field))&&!r.command&&!r.draggable&&r.field&&!0!==r.hidden)return o;return-1},removeRow:function(t){var n=this.dataItem(t);var 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=this;var t;var n=e.editor;n&&(t=n.model,e._destroyEditor(),e._isIncellEditable()?e._shouldRestorePageSize()&&e.dataSource._restorePageSizeAfterAddChild():e.dataSource.cancelChanges(t),t._edit=!1),e._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);let n=it(this.columns);let i=[];let 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();let 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),skipFocus:!0,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;var 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)];var 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=this;var o;r.trigger(R,{model:n})?r.dataSource._restorePageSizeAfterAddChild():(r.closeCell(),n._edit=!0,r._cancelEditor(),r._render({editedColumn:t,editedColumnIndex:i}),o=r.table.add(r.lockedTable).find(L+Pe.editCell).first(),r.editor=r._createIncellEditor(o,{columns:[t],model:n,change:function(t){r.trigger(V,{values:t.values,container:e,model:n})&&t.preventDefault()}}),r.lockedTable&&r._syncLockedContentHeight(),r.current()&&r.current().removeClass("k-focus"),r._current=o,r.trigger(F,{container:e,model:n}))},closeCell:function(e){var t=this;var n=(t.editor||{}).element;var i;var r;n&&n[0]&&t._isIncellEditable()&&(r=t.dataItem(n),e&&t.trigger(Q,{container:n,model:r})||(t.trigger(W,{type:e?Q:V,model:r,container:n}),t._cancelEditor(),n.removeClass(Pe.editCell),i=n.parent().removeClass(Pe.editRow),t.lockedContent&&t._relatedRow(i).removeClass(Pe.editRow),t._render(),t.trigger(I,{item:i,data:r,ns:h}),t.lockedContent&&function(e,t){var n;var i=e.offsetHeight;var r=t.offsetHeight;i>r?n=i+"px":i<r&&(n=r+"px");n&&(e.style.height=t.style.height=n)}(i.css("height","")[0],t._relatedRow(i).css("height","")[0])))},cancelChanges:function(){this.dataSource.cancelChanges()},saveChanges:function(){var e=this;var 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]:M(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;var n=this.thead.prev().children();var i,r=0;for(e=0,t=n.length;e<t;e++){if(!(i=n[e].style.width)||-1!=i.indexOf("%")){r=0;break}r+=parseInt(i,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";var n=this;this._draggableInstance=new h.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 h.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]&<(st(n.columns),n.columns,t.sourceIndex,t.targetIndex)>-1},change:function(e){var t=st(n.columns);var i=t[e.oldIndex];var 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&<(n,this.columns,e,t)>-1},_reorderTrees:function(t,n,i,r,o,a,s,l){var c=e();var d=o.find("tr").eq(r[0].rowIndex);var h=a.children[r[0].rowIndex];var u=d.children();var p;var f=s?t[0]:t[t.length-1];var m;var g;var v;var _;for(var b=0;b<r.length;b++)p=r[b].cellIndex,c=c.add(u.eq(p)),i===a&&s&&(p+=b),i.children[f.rowIndex].children.splice(s?f.cellIndex+b:f.cellIndex+1+b,0,h.children[p]);if(i===a&&s?h.children.splice(r[0].cellIndex+r.length,r.length):h.children.splice(r[0].cellIndex,r.length),(_=n.find("tr").eq(f.rowIndex).find(">th.k-header").eq(f.cellIndex)).length&&c[0]!==_[0]&&c[s?"insertBefore":"insertAfter"](_),l>=r[0].rowIndex+1&&1!=l){for(m=[],b=0;b<r.length;b++)r[b].columns&&(m=m.concat(r[b].columns));if(!m.length)return;for(g=[],b=0;b<t.length;b++)t[b].columns&&(g=g.concat(t[b].columns));if(!g.length&&(n!==o||f.cellIndex-r[0].cellIndex>1||r[0].cellIndex-f.cellIndex>1)&&(g=[v=nt(this.columns,f,r[0],s,this.columns)],!v&&m.length&&n.find("tr").length>r[0].rowIndex+1))return void this._insertTree(m,o,a,n,i);if(!g.length)return;this._reorderTrees(g,n,i,m,o,a,s,l)}},_insertTree:function(t,n,i,r,o){var a=[];var s;var l=e();var c;s=n.find("tr").eq(t[0].rowIndex),c=i.children[t[0].rowIndex];for(var d=0;d<t.length;d++)t[d].columns&&(a=a.concat(t[d].columns)),o.children[t[0].rowIndex].children.splice(d,0,c.children[t[d].rowIndex]),l=l.add(s.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(l),a.length&&this._insertTree(a,n,i,r,o)},_reorderHeader:function(t,n,i){var r=n.columns?gt([n]):1;var a=t.columns?gt([t]):1;var s=tt(n);var l=tt(t);var c=l?this.lockedHeader:this.thead;var d=s?this.lockedHeader:this.thead;var h=l?this._lockedHeaderTree:this._headerTree;var u=s?this._lockedHeaderTree:this._headerTree;var p;var f=c.find("tr:not(.k-filter-row)");var m;if(r===a||r<f.length)this._reorderTrees([t],c,h,[n],d,u,i,r),bt(c,h),wt(d,u);else{if(c!==d){p=r-f.length,f.each((function(e){var t=this.cells;for(var n=0;n<t.length;n++)t[n].colSpan<=1&&t[n].attributes.rowspan&&(h.children[e].children[n].attr.rowSpan+=p,t[n].rowSpan+=p)}));for(var g=0;g<p;g++)h.children.push(o("tr",{role:"row"})),m=c.is("thead")?c:c.find("thead"),this._hasFilterRow()?e("<tr class='k-table-row' role='row'></tr>").insertBefore(m.find("tr.k-filter-row")):m.append("<tr class='k-table-row' role='row'></tr>")}this._reorderTrees([t],c,h,[n],d,u,i,r),wt(d,u)}},reorderColumn:function(n,i,r){var o;var a=i.parentColumn;var s=a?a.columns:this.columns;var l=T(i,s);var c=s[n];var d=!!c.locked;var h=S(this.columns,(function(e){return e.columns!==t})).length>0;var u=_t(s).length;if(l!==n&&(!d||i.locked||1!=u)&&(d||!i.locked||s.length-u!=1)){if(r===t&&(r=n<l),h&&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(),h)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=e(this.lockedHeader).add(this.thead).find("th");var i=this.columns;var r=this.options;var o=r.columnMenu;var a,s,l,c,d;var h=this._columnMenuInit.bind(this);var u=this._columnMenuOpen.bind(this);var p=this._sort.bind(this);var f=this._filter.bind(this);var m=S(this.columns,(function(e){return!1!==e.lockable})).length>0;var g=S(this.columns,(function(e){return e.columns!==t})).length>0;if(g?(i=it(i),n=this.lockedHeader?We(je(this.lockedHeader.find(">table>thead")).add(je(this.thead))):je(this.thead)):n=e(this.lockedHeader).add(this.thead).find("tr:not(.k-filter-row) th"),o){"boolean"==typeof o&&(o={});for(var v=0;v<n.length;v++)(a=i[v]).field&&((s=n.eq(v).data("kendoColumnMenu"))&&s.destroy(),c=!1,!1!==a.sortable&&!1!==o.sortable&&!1!==r.sortable&&(c=x({},r.sortable,{compare:(a.sortable||{}).compare})),d=!1,r.filterable&&!1!==a.filterable&&!1!==o.filterable&&(d=x({pane:this.pane},a.filterable,r.filterable)),l={dataSource:this.dataSource,values:a.values,columns:o.columns,sortable:c,filterable:d,messages:o.messages,owner:this,closeCallback:Je,init:h,open:u,sort:p,filtering:f,pane:this.pane,hasLockableColumns:vt(i).length>0&&m&&!g,appendTo:L+Pe.headerCellInner,reorderable:!!r.reorderable},n.eq(v).kendoColumnMenu(l))}},_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;var t=e.options.pageable;t&&(M(t)||t instanceof Ke)&&!1===t.alwaysVisible&&e.wrapper.find(".k-grid-pager").toggle((e.dataSource.collapsedTotal()||0)>=e.dataSource.pageSize())}});function Je(e){yt(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=ht(t,e);var a;a=o?o.columns:e;var s=T(t,a);0===s&&i&&1!==a.length?s++:s!=a.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;var o=!!n.locked;var a;do{r=e[t],t+=i?1:-1,a=!!r.locked}while(r&&t>-1&&t<e.length&&r!=n&&!r.columns&&a===o);return r}(a,s,n,T(n,a)>s);var l=T(t,r);return(!t.columns||l&&l!==a.length-1)&&t&&t!=n&&t.columns?nt(e,t,n,i,r):null}function it(e){var t=[];for(var 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];var o=e[i];var a=ht(r,t);return t=a?a.columns:t,T(o,t)}function ct(t){var n=t.closest("table");var i=e().add(t);var r=t.closest("tr");var o=n.find("tr");var a=o.index(r);if(a>0){var s=o.eq(a-1).find("th").filter((function(){return!e(this).attr("rowspan")}));var l=0;var c=r.find("th").index(t);var d=t.prevAll().filter((function(){return this.colSpan>1}));for(var h=0;h<d.length;h++)l+=d[h].colSpan||1;for(c+=Math.max(l-1,0),l=0,h=0;h<s.length;h++){var u=s.eq(h);if(u.attr("data-colspan")?l+=u[0].getAttribute("data-colspan"):l+=1,c>=h&&c<l){i=ct(u).add(i);break}}}return i}function dt(t){var n=t.closest("thead");var i=e().add(t);var r=t.closest("tr");var o=n.find("tr");var a=o.index(r)+t[0].rowSpan;var s=kendo.attr("colspan");if(a<=o.length-1){var l=r.next();var c=t.prevAll();var d;c=c.filter((function(){return!this.rowSpan||1===this.rowSpan}));var h=0;for(d=0;d<c.length;d++)h+=parseInt(c.eq(d).attr(s),10)||1;var u=l.find("th");var p=parseInt(t.attr(s),10)||1;for(d=0;d<p;){l=u.eq(d+h),i=i.add(dt(l));var f=parseInt(l.attr(s),10);f>1&&(p-=f-1),d++}}return i}function ht(e,t){var n=[];return ut(e,t,n),n[n.length-1]}function ut(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]),ut(e,t[i].columns,n))return!0;n.splice(r,n.length-r)}}return!1}function pt(e){var t=[];var n=[];for(var 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;var 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);var a={};var s=t.find(">tr:not(.k-filter-row)");var l=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")};for(var 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){var t=0;for(var 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)");var i=n.length;n.each((function(e){var n=this.cells;for(var 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 wt(t,n){var i=t.find("tr");var 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 yt(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;var o=i.dataSource;var a=i.options.pdf.allPages;this._initPDFProgress(n);var s=new kendo.drawing.Group;var l=o.page();function c(){i._drawPDFShadow({width:i.wrapper.width()},{avoidLinks:i.options.pdf.avoidLinks}).done((function(e){var i=o.page();var d=a?o.totalPages():1;var h={page:e,pageNumber:i,progress:i/d,totalPages:d};n.notify(h),s.append(h.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;var r=new e.Deferred;var o=i.dataSource;var a=i.options.pdf.allPages;var s=i.wrapper.find('table[role="treeList"] > tbody');var l=e("<div>").css({position:"absolute",left:-1e4,top:-1e4});var 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();var h=o.page();function u(){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();var n=a?o.totalPages():1;d.append(s.find("tr")),e<n?o.page(e+1):(o.unbind("change",p),a&&h!==t?(o.one("change",u),o.page(h)):(i.refresh(),u()))}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:Be,defaultHeadContextMenu:He}),h.plugin(Ze),h.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;var d=function(e,t){return function(i){var r=(i=n(i)?{data:i}:i)||{};var 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)}};var h=function(e){if(e.filter("[name=end], [name=start], [name=plannedEnd], [name=plannedStart]").length){var t,n,i=e.attr("name"),r=kendo.widgetInstance(e,kendo.ui),o={},a=e;for(;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};var u=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}}}});var p=s.extend({init:function(e){s.fn.init.call(this,i(!0,{},{schema:{modelBase:u,model:u}},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();var 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:h,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:h,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){var t,n=["start","end"];for(var i=0;i<n.length;i++)t=new Date(this.get(n[i]).getTime()+e),this.set(n[i],t)},_offsetPlanned:function(e){var t,n=["plannedStart","plannedEnd"];for(var 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;var 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={field:"parentId",operator:"eq",value:null};var r=this._sort&&this._sort.length?this._sort:{field:"orderId",dir:"asc"};var o,s;if(s=n?this.view():this.data(),e){if((o=e.get("id"))===t||null===o||""===o)return[];i.value=o}return s=new a(s).filter(i).sort(r).toArray()},taskLevel:function(e){var t=0,n=this.taskParent(e);for(;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){var t,n=[],i=this.taskChildren(e,!0);for(var 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;var o=function(e){var t=e.field,n=e.sender;switch(t){case"start":r._resolveSummaryStart(r.taskParent(n)),function(e,t){var n=r.taskAllChildren(e);for(var 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){var n=r.taskAllChildren(e);for(var 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){var n=null===e?null:this.get(e),i=this.taskChildren(n);for(var 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){var n=t.taskChildren(e);var i=n[0].start.getTime();var r;for(var o=1,a=n.length;o<a;o++)(r=n[o].start.getTime())<i&&(i=r);return new Date(i)}))},_resolveSummaryEnd:function(e){var t=this;this._updateSummaryRecursive(e,"end",(function(e){var n=t.taskChildren(e);var i=n[0].end.getTime();var r;for(var o=1,a=n.length;o<a;o++)(r=n[o].end.getTime())>i&&(i=r);return new Date(i)}))},_resolveSummaryPlannedStart:function(e){var t=this;this._updateSummaryRecursive(e,"plannedStart",(function(e){var n,i=t.taskChildren(e),r=null;for(var 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){var n,i=t.taskChildren(e),r=null;for(var 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:u})}(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";var c="k-gantt-delete",d="k-gantt-cancel",h="k-gantt-update",u={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"};var 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;var 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=u,o=this.element,s=t.model,l=this,h=e(n.format('<div class="'+r.formContainer+'" data-uid="'+s.uid+'">')).appendTo(o),p=this.options.messages;h.append(e("<p>"+t.text+"</p>")),i=e('<div class="'+r.buttonsContainer+'">'),h.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=h.kendoWindow({modal:!0,autoFocus:!1,resizable:!1,draggable:!1,title:t.title,visible:!1,deactivate:function(){this.destroy(),l.trigger("close",{window:h})}}).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="'+u.buttonsContainer+'">');i.appendTo(t),i.append(e("<button class='"+h+"'>"+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;var o=s({},n.Template,this.options.templateSettings);var 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=this;var i=this.options.messages;var r=u;var o;var a=this.task;var l=e(n.format('<div {0}="{1}" class="{2} {3}">',n.attr("uid"),a.uid,r.form,r.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:i.editor.editorTitle,visible:!1,actions:["Minimize","Maximize","Close"],close:function(e){e.userTriggered&&t.trigger("cancel",{container:l,model:a})&&e.preventDefault()}},{})),o=this.renderForm?this._initForm():l.kendoEditable({model:a,clearContainer:!1,validateOnBlur:!0,target:t.options.target}).data("kendoEditable"),n.cycleForm(l),this.trigger("edit",{container:l,model:a})?t.trigger("cancel",{container:l,model:a}):l.data("kendoWindow").center().open(),o},_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,h=d.fields,u=this.plannedEditors?c.actualStart:c.start,p=this.plannedEditors?c.actualEnd:c.end;var f=[{field:"title",title:c.title,colSpan:4}];return this.plannedEditors&&(f.push({field:"plannedStart",title:c.plannedStart,colSpan:2,editor:"DateTimePicker",validation:h.plannedStart.validation,editorOptions:{componentType:"modern"}}),f.push({field:"plannedEnd",title:c.plannedEnd,colSpan:2,editor:"DateTimePicker",validation:h.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:u,colSpan:2,editor:"DateTimePicker",validation:h.start.validation,editorOptions:{componentType:"modern"}}),f.push({field:"end",title:p,colSpan:2,editor:"DateTimePicker",validation:h.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(),h={},u=[],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")),u.push(e)):e.predecessorId&&(e.successorId||(e.successorId=o.get("id")),u.push(e))})),(u.length>0||i.length>0||p.length>0)&&(h.updateDependencies={destroyed:i,created:u,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({},h,{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}});var 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=[];var n,i;var r=this.grid;var o=r.dataSource.data();var a=r.editable;if(a&&a.validatable&&!a.validatable.validate())return!1;for(var s=0,l=o.length;s<l;s++)i=(n=o[s]).get("value"),n.id!==t&&null!==i&&i>0&&e.push(o[s]);return this.model[this.resourcesField]=e,!0},_resourceGrid:function(){var e=this;var i=this.options.messages;var r=e.options;var o=this.wrapper;var 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";var 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"),h=kendo.attr("format"),u="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> </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"};var 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=this;var n=(t.editor||{}).element;var i;var o;n&&n[0]&&t._isIncellEditable()&&(o=t.dataItem(n),t._cancelEditor(),n.removeClass(g.editCell),i=n.parent().removeClass(g.editRow),t.lockedContent&&t._relatedRow(i).removeClass(g.editRow),e&&t._render(),t.trigger("itemChange",{item:i,data:o,ns:r}),t.lockedContent&&t._adjustRowHeight(i.css("height","")[0],t._relatedRow(i).css("height","")[0]))},insertAfter:function(e,t){if(e&&t){var n=t.orderId;var 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;var 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=this.element;var t=e.find("."+g.gridContentWrap);var n=e.find("."+g.gridHeader);var i;var r=kendo.support.scrollbar();this._isHeightSet(e)&&(i=e.height()-a(n),t.height(i),this._hasLockedColumns&&(r=this.table[0].offsetWidth>this.table.parent()[0].clientWidth?r:0,this.lockedContent.height(i-r)))},_adjustRowHeight:function(e,t){var n;var i=e.offsetHeight;var 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[h]=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===u&&(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){var t=e.get(r)||[],n=[];for(var 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===u?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;var 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;var n=kendo.dom.element;var i=kendo.dom.text;var r=kendo.dom.html;var o=e.isPlainObject;var a=kendo._outerWidth;var s=kendo._outerHeight;var l=e.extend;var c=!1;var d=kendo.keys;var h=kendo.data.Query;var u=".kendoGanttTimeline";var p="click";var f="mousemove";var m="mouseenter";var g="mouseleave";var v=".";var _=({start:e})=>kendo.toString(e,"ddd M/dd");var b=({start:e,end:t})=>`${kendo.toString(e,"ddd M/dd")} - ${kendo.toString(kendo.date.addDays(t,-1),"ddd M/dd")}`;var w=({start:e})=>kendo.toString(e,"MMM");var y=({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>`;var 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>`;var x=`<table ${kendo.attr("style-visibility")}="hidden"><tbody><tr ${kendo.attr("style-height")}="{0}"><td> </td></tr></tbody></table>`;var 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=[];var 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);var i=this._colgroup();var r=this._headerTree;var o=n("tbody",{className:T.styles.tbody},t);var 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(){var e=this.headerRow[0].children;var t=this._timeSlots();var n;var i;for(var r=0,o=e.length;r<o;r++)i=e[r],(n=t[r]).offsetLeft=i.offsetLeft,n.offsetWidth=i.offsetWidth},render:function(e){var t=e.length;var n=T.styles;var i;var r=this._rowsTable(t);var o=this._columnsTable(t);var a=this._tasksTable(e);var s=this.options.currentTimeMarker;var l=this.options.calculatedSize;var c;this._taskTree.render([r,o,a]),i=this.content.find(v+n.rowsTable),l&&(c=l.row*e.length,this.content.find(v+n.tasksTable).height(c),i.height(c)),this._contentHeight=i.height(),this._rowHeight=l?l.row:this._contentHeight/i.find("tr").length,this.content.find(v+n.columnsTable).height(this._contentHeight),!1!==s&&void 0!==s.updateInterval&&this._renderCurrentTime()},_rowsTable:function(e){var t=[];var r;var o=T.styles;var a=[{className:o.tableRow},{className:o.alt}];for(var s=0;s<e;s++)r=n("tr",a[s%2],[n("td",{className:o.tableCell},[i(" ")])]),t.push(r);return this._createTable(1,t,{className:o.rowsTable+" k-grid-table "+o.table})},_columnsTable:function(){var e=[];var t;var r=T.styles;var o=this._timeSlots();var a=o.length;var s;var l;var c=0;var d;for(var h=0;h<a;h++)s=o[h],d={className:r.tableCell},c+=l=s.span,1!==l&&(d.colspan=l),s.isNonWorking&&(d.className+=" "+r.nonWorking),e.push(n("td",d,[i(" ")]));return t=n("tr",{className:r.tableRow},e),this._createTable(c,[t],{className:r.columnsTable+" "+r.table})},_tasksTable:function(e){var t=[];var i;var r;var o;var a;var s;var l=T.styles;var d=this._taskCoordinates={};var h=this._calculateMilestoneWidth();var u=Math.round(h.width);var p=this.options.resourcesField;var f=[l.resource,l.resourceAlt];var m=this.options.calculatedSize;var g;var v=this._calculateResourcesMargin();var _=this._calculateTaskBorderWidth();var b;var w=this.options.showPlannedTasks;var y=[{className:l.tableRow},{className:l.alt}];var k;for(var x=0,C=e.length;x<C;x++)s=e[x],o=this._taskPosition(s),w&&((a=this._taskPositionPlanned(s)).borderWidth=_),o.borderWidth=_,i=n("tr",y[x%2]),r=n("td",{className:l.tableCell}),s.start<=this.end&&s.end>=this.start&&(k=this._renderTask(e[x],o,a),this.options.navigatable&&(k.children[0].attr.tabIndex=x?-1:0),r.children.push(k),s[p]&&s[p].length&&(g=c?this._tableWidth-o.left:Math.max(o.width||h.clientWidth,0)+o.left,(b={width:this._tableWidth-(g+v)+"px"})[c?"right":"left"]=g+"px",m&&(b.height=m.cell+"px"),r.children.push(n("div",{className:l.resourcesWrap,style:b},this._renderResources(s[p],f[x%2])))),S=x,M=void 0,A=void 0,A=(M=o.left)+o.width,s.isMilestone()&&(A=(M-=u/2)+u),d[s.id]={start:M,end:A,rowIndex:S}),i.children.push(r),t.push(i);var S,M,A;return this._createTable(1,t,{className:T.styles.tasksTable+" "+l.table})},_createTable:function(e,t,i){var r=[];var o;var a;for(var s=0;s<e;s++)r.push(n("col"));return o=n("colgroup",null,r),a=n("tbody",{className:T.styles.tbody},t),i.style||(i.style={}),i.style.width=this._tableWidth+"px",i.role="presentation",n("table",i,[o,a])},_calculateTableWidth:function(){var e=this._timeSlots();var t=0;var n=0;var i;for(var r=0,o=e.length;r<o;r++)n+=i=e[r].span,i>t&&(t=i);return Math.round(n*this.options.slotSize/t)},_calculateMilestoneWidth:function(){var t;var n=T.styles.task+" "+T.styles.taskMilestone;var i;var r=e(`<div class="${n}">`).css({visibility:"hidden",position:"absolute"});return this.content.append(r),t={width:(i=r[0].getBoundingClientRect()).right-i.left,clientWidth:r[0].clientWidth},r.remove(),t},_calculateResourcesMargin:function(){var t;var 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;var n=T.styles.task+" "+T.styles.taskSingle;var i;var r=e(`<div class="${n}">`).css({visibility:"hidden",position:"absolute"});return this.content.append(r),i=kendo.getComputedStyles(r[0],["border-left-width"]),t=parseFloat(i["border-left-width"],10),r.remove(),t},_renderTask:function(t,i,r){var o=this.options.editable;var a=i.left;var s=T.styles;var l=s.taskWrap;var d=this.options.calculatedSize;var h={};var u={className:l,style:{left:a+"px"}};var p=[];var f=0;var m=i.width;var g,v,_,b;var w,y,k,x;return d&&(u.style.height=d.cell+"px"),r&&(b=t.isMilestone()?this._renderPlannedMilestone(i,r):this._renderPlannedSingleTask(i,r,t),p.push(b),c&&r.left<=i.left&&(u.style.left=r.left+"px")),t.summary?(v=this._renderSummary(t,i,r),u.className+=" "+s.taskSummaryWrap):t.isMilestone()?(v=this._renderMilestone(t,i),u.className+=" "+s.taskMilestoneWrap):v=this._renderSingleTask(t,i,r),r&&!t.isMilestone()&&t.plannedStart<t.end&&t.plannedEnd>t.start&&t.plannedEnd<t.end?(m=c?i.left+i.width-r.left:r.left+r.width-i.left,x=c?r.left-i.left:i.left+i.width-(r.left+r.width),k=n("div",{className:s.taskOffset,style:{width:x-2*r.borderWidth+"px"}}),o&&!1!==o.resize&&!1!==o.update&&!t.summary&&(!1!==o.destroy&&k.children.push(n("span",{className:s.taskActions,"aria-hidden":"true"},[n("a",{className:s.link+" "+s.taskDelete,href:"#","aria-label":"Delete"},[n(e(kendo.ui.icon(s.iconDelete))[0])])])),c?k.children.push(n("span",{className:s.taskResizeHandle+" "+s.taskResizeHandleWest,style:{right:i.width-5+"px"}})):k.children.push(n("span",{className:s.taskResizeHandle+" "+s.taskResizeHandleEast}))),y=n("div",{className:s.taskOffsetWrap+" "+s.taskInnerWrap},[v,k]),p.push(y)):r?p.push(n("div",{className:s.taskInnerWrap},[v])):p.push(v),g=n("div",u,p),o&&!1!==o.dependencyCreate&&(r&&t.plannedEnd>t.end&&(f=r.left+r.width-i.left-i.width-3+"px"),g.children.push(n("div",{className:s.taskDot+" "+s.taskDotStart})),c&&(f="auto",r&&t.plannedEnd>t.end&&(w=i.left-r.left+"px")),g.children.push(n("div",{className:s.taskDot+" "+s.taskDotEnd,style:{right:f,left:w}}))),t.summary||t.isMilestone()||!o||!1===o.dragPercentComplete||!1===o.update||null!==this._taskTemplate||(_=Math.round(m*t.percentComplete),h[c?"right":"left"]=_+"px",g.children.push(n("div",{className:s.taskDragHandle,style:h}))),g},_renderSingleTask:function(t,o,a){var s=T.styles;var l;var d=[];var h;var u=this.options.editable;var p=s.task+" "+s.taskSingle;var f=o.width;a&&(t.plannedEnd&&t.plannedEnd<=t.start?p+=" "+s.taskDelayed:t.plannedEnd&&t.plannedEnd>t.end?p+=" "+s.taskAdvanced:t.plannedEnd&&t.plannedEnd<t.end&&(c?f=f+o.left-a.left:f-=o.left+o.width-a.left-a.width)),l=Math.round(f*t.percentComplete),null!==this._taskTemplate?h=r(this._taskTemplate(t)):(h=i(t.title),d.push(n("div",{className:s.taskComplete,style:{width:l+"px"},"aria-hidden":"true"})));var m=n("div",{className:s.taskContent},[n("div",{className:s.taskTemplate},[h])]);return d.push(m),u&&(!1!==u.destroy&&(!a||!t.plannedEnd||t.end<=t.plannedEnd||t.start>=t.plannedEnd)&&m.children.push(n("span",{className:s.taskActions,"aria-hidden":"true"},[n("a",{className:s.link+" "+s.taskDelete,href:"#","aria-label":"Delete"},[n(e(kendo.ui.icon(s.iconDelete))[0])])])),!1!==u.resize&&!1!==u.update&&(m.children.push(n("span",{className:s.taskResizeHandle+" "+s.taskResizeHandleWest})),m.children.push(n("span",{className:s.taskResizeHandle+" "+s.taskResizeHandleEast})))),n("div",{className:p,"data-uid":t.uid,role:"treeitem",style:{width:Math.max(f-2*o.borderWidth,0)+"px"}},d)},_renderMilestone:function(e){var t=T.styles;var 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=T.styles;var o=t.width;var a;var s=r.task+" "+r.taskSummary;return i&&(e.plannedEnd&&e.plannedEnd<=e.start?s+=" "+r.taskDelayed:e.plannedEnd&&e.plannedEnd>e.end?s+=" "+r.taskAdvanced:e.plannedEnd&&e.plannedEnd<e.end&&(c?o=o+t.left-i.left:o-=t.left+t.width-i.left-i.width)),a=Math.round(o*e.percentComplete),n("div",{className:s,"data-uid":e.uid,role:"treeitem","aria-label":e.title,style:{width:o+"px"}},[n("div",{className:r.taskSummaryProgress,style:{width:a+"px"}},[n("div",{className:r.taskSummaryComplete,style:{width:t.width+"px"}})])])},_renderPlannedSingleTask:function(e,t,i){var r=T.styles;var o=[];var 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;var 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){var r=[];var o;for(var a=0,s=e.length;a<s;a++)o=e[a],r.push(n("span",{className:t,style:{color:o.get("color")}},[i(o.get("name"))]));return c&&r.reverse(),r},_taskPosition:function(e){var t=Math.round;var 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;var 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=this._timeSlots();var n;var i=0;return t.length?((n=t[this._slotIndex("start",e)]).end<e?i=n.offsetWidth:n.start<=e&&(i=(e-n.start)/(n.end-n.start)*n.offsetWidth),c&&(i=n.offsetWidth+1-i),n.offsetLeft+i):0},_slotIndex:function(e,t,n){var i=this._timeSlots();var r=0;var o=i.length-1;var a;n&&(i=[].slice.call(i).reverse());do{i[a=Math.ceil((o+r)/2)][e]<t?r=a:(a===o&&a--,o=a)}while(r!==o);return n&&(r=i.length-1-r),r},_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;var o=i.end-i.start;var 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;var n=this._slotIndex("offsetLeft",t,c);return this._timeSlots()[n]},_renderDependencies:function(e){var t=[];var n=this._dependencyTree;for(var i=0,r=e.length;i<r;i++)t.push.apply(t,this._renderDependency(e[i]));n.render(t)},_renderDependency:function(e){var t=this._taskCoordinates[e.predecessorId];var n=this._taskCoordinates[e.successorId];var i;if(!t||!n)return[];for(var r=0,o=(i=this["_render"+["FF","FS","SF","SS"][c?3-e.type:e.type]](t,n)).length;r<o;r++)i[r].attr["data-uid"]=e.uid;return i},_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=this;var r=[];var o=0;var a=0;var s=0;var l=0;var c=n?"start":"end";var d;var h=this._rowHeight;var u=e.rowIndex*h+Math.floor(h/2)-1;var p=t.rowIndex*h+Math.floor(h/2)-1;var f=T.styles;var m=function(){r.push(i._line(f.line+" "+f.lineHorizontal,{left:o+"px",top:a+"px",width:s+"px"}))};var g=function(){r.push(i._line(f.line+" "+f.lineVertical,{left:o+"px",top:a+"px",height:l+"px"}))};return o=e[c],a=u,s=10,(d=t[c]-e[c])>0!==n&&(s=Math.abs(d)+10),n?(o-=s,s-=1,m()):(m(),o+=s-2),p<a?(l=a-p,l+=2,a=p,g()):(l=p-a,l+=2,g(),a+=l-2),s=Math.abs(o-t[c]),n||(o-=s-=1),m(),r},_dependencyFS:function(e,t,n){var i=this;var r=[];var o=0;var a=0;var s=0;var l=0;var c=this._rowHeight;var d=Math.floor(c/2);var h=t.start-e.end;var u=e.rowIndex*c+Math.floor(c/2)-1;var p=t.rowIndex*c+Math.floor(c/2)-1;var f=T.styles;var m=function(){r.push(i._line(f.line+" "+f.lineHorizontal,{left:o+"px",top:a+"px",width:s+"px"}))};var g=function(){r.push(i._line(f.line+" "+f.lineVertical,{left:o+"px",top:a+"px",height:l+"px"}))};return o=e.end,a=u,s=10,n&&(o+=1,h>20&&(s=h-8),s-=1),m(),o+=s-2,h<=20&&(l=n?Math.abs(p-u)-d:d,p<u?(a-=l,l+=2,g()):(g(),a+=l),(s=e.end-t.start+20)<10&&(s=10),o-=s-2,m()),p<u?(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(){var e=this._timeSlots();var t=e.length;var i=[];for(var 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=T.styles;var n;this._dragHint=e.clone().addClass(t.dragHint).css({cursor:"move"}),(n=this._dragHint.find(v+t.taskPlanned)).css({visibility:"hidden"}),c&&e.find(v+t.taskAdvanced).length>0&&(n.css({"margin-right":"auto",width:0}),this._dragHint.find(v+t.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&&(this._dragHint.remove(),this._dragHint=null)},_createResizeHint:function(t){var n=T.styles;var i=this._taskCoordinates[t.id].rowIndex*this._rowHeight;var r;var o=this.options;var l=o.messages;this._resizeHint=e((({styles:e})=>`<div class="${e.marquee}"><div class="${e.marqueeColor}"></div></div>`)({styles:n})).css({top:0,height:this._contentHeight}),this.content.append(this._resizeHint),this._resizeTooltip=e(y({styles:n,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),(r=i-s(this._resizeTooltip))<0&&(r=i+this._rowHeight),this._resizeTooltipTop=r},_updateResizeHint:function(t,n,i){var r=this._offset(c?n:t);var o=this._offset(c?t:n);var a=o-r;var s=i!==c?r:o;var l=this._tableWidth-kendo.support.scrollbar();var d=this._resizeTooltipWidth;var h=this.options;var u=h.messages;var 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(y({styles:T.styles,start:t,end:n,messages:u.views,format:h.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);var l=r.find(v+T.styles.callout);var 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;var r=n.x-t.x;var o=n.y-t.y;var a=Math.sqrt(r*r+o*o);var 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;var o=this.options;var a=this.content;var l=a.offset();var d=kendo.scrollLeft(a);var h=e(n).parents("tr").first();var u=h.offset();var p=o.tooltip&&o.tooltip.template?kendo.template(o.tooltip.template):k;var f=c?i-(l.left+d+kendo.support.scrollbar()):i-(l.left-d);var m=u.top+s(h)-l.top+a.scrollTop();var 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,u,l,f,d)},_removeTaskTooltip:function(){this._taskTooltip&&this._taskTooltip.remove(),this._taskTooltip=null},_createOffsetTooltip:function(t,n,i){var r=T.styles;var o=this.content;var a=o.offset();var l=kendo.scrollLeft(o);var d=n.parents("tr").first();var h=d.offset();var u=c?i-(a.left+l+kendo.support.scrollbar()):i-(a.left-l);var p=h.top+s(d)-a.top+o.scrollTop();var f=this._offsetTooltip=e('<div class="'+r.tooltipWrapper+'" ></div>');var m=Math.round((t.end.getTime()-t.plannedEnd.getTime())/6e4);var g=this.options.messages.plannedTasks;var v=m%60;var _=v+" "+g.minutes;var b;m>=60&&(_=(b=m=Math.floor(m/60))+" "+g.hours,0!==v&&(_+=" "+v+" "+g.minutes),m>=24&&(b=m%24,_=(m=Math.floor(m/24))+" "+g.days,0!==b&&(_+=" "+b+" "+g.hours))),f.css({"z-index":"100002",left:u,top:p}).addClass(r.offsetTooltipDelay).appendTo(o).append((({offsetPrefix:e,offsetText:t})=>`<span>${e}: ${t}</span>`)({offsetPrefix:g.offsetTooltipDelay,offsetText:_})),this._adjustTooltipDimensions(f,h,a,u,l)},_removeOffsetTooltip:function(){this._offsetTooltip&&this._offsetTooltip.remove(),this._offsetTooltip=null},_createPlannedTooltip:function(t,n,i){var r=T.styles;var o=this.content;var a=o.offset();var l=kendo.scrollLeft(o);var d=n.parents("tr").first();var h=d.offset();var u=c?i-(a.left+l+kendo.support.scrollbar()):i-(a.left-l);var p=h.top+s(d)-a.top+o.scrollTop();var f=this._plannedTooltip=e('<div class="'+r.tooltipWrapper+" "+r.plannedTooltip+'" ></div>');var m=this.options.messages.editor;f.css({"z-index":"100002",left:u,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,h,a,u,l)},_removePlannedTooltip:function(){this._plannedTooltip&&this._plannedTooltip.remove(),this._plannedTooltip=null},_adjustTooltipDimensions:function(e,t,n,i,r){var o=this.content;var l=o.width();var c;s(e)<t.top-n.top&&e.css("top",t.top-n.top-s(e)+o.scrollTop()),(c=a(e))+i-r>l&&((i-=c)<r&&(i=r+l-(c+17)),e.css("left",i))},_scrollTo:function(e){var t=e.offset().left;var n=e.width();var i=t+n;var r=e.closest("tr");var o=r.offset().top;var a=o+r.height();var s=this.content;var l=s.offset();var c=l.top;var d=c+s.height();var h=l.left;var u=s.width();var p=h+u;var f=kendo.support.scrollbar();o<c?s.scrollTop(s.scrollTop()+(o-c)):a>d&&s.scrollTop(s.scrollTop()+(a+f-d)),t<h&&n>u&&i<p||i>p&&n<u?kendo.scrollLeft(s,kendo.scrollLeft(s)+(i+f-p)):(i>p&&n>u&&t>h||t<h&&n<u)&&kendo.scrollLeft(s,kendo.scrollLeft(s)+(t-h))},_scrollToDate:function(e){var t=this.start;var n=this.end;var i;e>=t&&e<n&&(i=this._offset(e),kendo.support.isRtl(this.element)&&(i=this._tableWidth-i),kendo.scrollLeft(this.content,i))},_timeSlots:function(){return this._slots&&this._slots.length?this._slots[this._slots.length-1]:[]},_headers:function(e){var t=[];var i;var o;var a;var s;var l=T.styles;for(var c=0,d=e.length;c<d;c++){o=[];for(var h=0,u=(i=e[c]).length;h<u;h++)a=i[h],s=r(a.text),o.push(n("td",{colspan:a.span,className:l.header+(a.isNonWorking?" "+l.nonWorking:"")},[s]));t.push(n("tr",{className:l.tableRow},o))}return t},_hours:function(e,t){var n;var i=[];var r=this.options;var o=r.workDayStart.getHours();var a=r.workDayEnd.getHours();var s;var l;var c=r.hourSpan;for(e=new Date(e),t=new Date(t),r.showWorkHours&&e.setHours(o);e<t;)s=(l=(n=new Date(e)).getHours())>=o&&l<a,n.setHours(n.getHours()+c),l==n.getHours()&&n.setHours(n.getHours()+2*c),r.showWorkHours&&!s||i.push({start:e,end:n,isNonWorking:!s,span:1}),e=n;return i},_days:function(e,t){var n;var i=[];var r;for(e=new Date(e),t=new Date(t);e<t;)n=t<kendo.date.nextDay(e)?t:kendo.date.nextDay(e),r=this._isWorkDay(e),this.options.showWorkDays&&!r||i.push({start:e,end:n,isNonWorking:!r,span:1}),e=n;return i},_weeks:function(e,t){var n;var i=[];var r=this.calendarInfo().firstDay;var o;var a;for(e=new Date(e),t=new Date(t);e<t;)(n=kendo.date.dayOfWeek(kendo.date.addDays(e,1),r,1))>t&&(n=t),(a=(o=this._days(e,n)).length)>0&&i.push({start:o[0].start,end:o[a-1].end,span:a}),e=n;return i},_months:function(e,t){var n;var i;var r=[];var o;var 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,(a=(o=this._days(e,n)).length)>0&&r.push({start:o[0].start,end:o[a-1].end,span:a}),e=n;return r},_years:function(e,t){var n;var i;var 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){var n=[];var i;for(var r=0,o=e.length;r<o;r++)i=e[r],n.push({text:t(i),isNonWorking:!!i.isNonWorking,span:i.span});return n},_isWorkDay:function(e){var t=e.getDay();var n=this._workDays;for(var 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=this._getCurrentTime();var n=this._offset(t);var i=e("<div class='k-current-time'></div>");var r=T.styles;var o=this.element.find(v+r.tasksWrapper);var a=this.element.find(v+r.tasksTable);var s;this.content&&this._timeSlots().length&&(this.content.find(".k-current-time").remove(),t<(s=this._timeSlots()[this._slotIndex("start",t)]).start||t>s.end||(o.length&&a.length&&(n+=a.offset().left-o.offset().left),i.css({left:n+"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-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;var t;var n;var i;var 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=[];var 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=this.options.range;var n=this.calendarInfo().firstDay;var i=e.end;var r;n===i.getDay()&&i.setDate(i.getDate()+7),this.start=kendo.date.getDate(kendo.date.dayOfWeek(e.start,n,-1)),this.end=kendo.date.getDate(kendo.date.dayOfWeek(i,n,1)),t&&t.start&&(this.start=kendo.date.getDate(t.start)),t&&t.end&&(r=new Date(t.end),kendo.date.getDate(r)<t.end?this.end=kendo.date.getDate(new Date(r.setDate(r.getDate()+1))):this.end=kendo.date.getDate(r))},_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=[];var 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:w,resizeTooltipFormat:"dddd, MMM d, yyyy"},range:function(e){var t=this.options.range;var n;this.start=kendo.date.firstDayOfMonth(e.start),this.end=kendo.date.addDays(kendo.date.getDate(kendo.date.lastDayOfMonth(e.end)),1),t&&t.start&&(this.start=kendo.date.getDate(t.start)),t&&t.end&&(n=new Date(t.end),kendo.date.getDate(n)<t.end?this.end=kendo.date.getDate(new Date(n.setDate(n.getDate()+1))):this.end=kendo.date.getDate(n))},_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=[];var 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:w,resizeTooltipFormat:"dddd, MMM d, yyyy"},range:function(e){var t=this.options.range;var n;this.start=kendo.date.firstDayOfMonth(new Date(e.start.setMonth(0))),this.end=kendo.date.firstDayOfMonth(new Date(e.end.setMonth(12))),t&&t.start&&(this.start=kendo.date.firstDayOfMonth(t.start)),t&&t.end&&(n=kendo.date.firstDayOfMonth(t.end),this.end=kendo.date.getDate(new Date(n.setMonth(n.getMonth()+1))))},_createSlots:function(){var t=[];var 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=[];var 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 M=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(u),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;var 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"+u,".k-gantt-tables .k-gantt-tasks .k-task",(function(n){var i=e(n.target);var r=i.closest(".k-table-row");var o=!1;var a;n.keyCode==d.HOME&&(a=t._findFirst(r)),n.keyCode==d.END&&(a=t._findLast(r)),n.keyCode==d.DOWN&&(a=t._findNext(r)),n.keyCode==d.UP&&(a=t._findPrev(r)),a&&(o=!0,a[0]!==i[0]&&(i.closest(".k-gantt-tasks").find(".k-task").attr("tabindex",-1),a.attr("tabindex",0),a.trigger("focus"))),n.keyCode==d.LEFT&&(n.altKey?i.hasClass("k-task-summary")&&(t.trigger("collapse",{uid:i.attr("data-uid")}),setTimeout((function(){t.select().trigger("focus")}),1)):t._scrollTasks(-1),o=!0),n.keyCode==d.RIGHT&&(n.altKey?i.hasClass("k-task-summary")&&(t.trigger("expand",{uid:i.attr("data-uid")}),setTimeout((function(){t.select().trigger("focus")}),1)):t._scrollTasks(1),o=!0),n.keyCode==d.ENTER&&(o=!0,!1!==t.options.editable.update&&(t.trigger("editTask",{uid:i.attr("data-uid")}),n.stopPropagation())),n.keyCode==d.DELETE&&(o=!0,!1!==t.options.editable.update&&(t.trigger("removeTask",{uid:i.attr("data-uid")}),n.stopPropagation())),o&&n.preventDefault()})).on(p+u,v+M.styles.task,(function(n){n.preventDefault();var i=e(this);t.wrapper.find(v+M.styles.task).attr("tabindex","-1"),i.attr("tabindex","0").trigger("focus")}))},_wrapper:function(){var t=M.styles;var n=this;var i=this.options;var r,o,a,l,c;this.wrapper=this.element.addClass(t.wrapper).append("<div class='"+t.gridHeader+"'><div class='"+t.gridHeaderWrap+"'></div></div>").append("<div role='tree' class='"+t.gridContentWrap+"'><div class='"+t.tasksWrapper+"'></div><div class='"+t.dependenciesWrapper+"'></div></div>"),i.rowHeight&&(this._calculatedSize=(r="string"==typeof i.rowHeight?i.rowHeight:i.rowHeight+"px",o=e(kendo.format(x,r)),c=n.wrapper.find(v+t.tasksWrapper),kendo.applyStylesFromKendoAttributes(o,["height","visibility"]),c.append(o),a=s(o.find("tr")),l=o.find("td").height(),o.remove(),{row:a,cell:l}))},_domTrees:function(){var e=M.styles;var t=kendo.dom.Tree;var 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=this.options.views;var t;var n;var i;var r;var a;this.views={};for(var s=0,c=e.length;s<c;s++)t=e[s],(n=o(t))&&!1===t.selectable||(i=n?"string"!=typeof t.type?t.title:t.type:t,(r=C[i])&&(n&&(t.type=r.type),r.title=this.options.messages.views[i]),t=l({title:i},r,n?t:{}),i&&(this.views[i]=t,a&&!t.selected||(a=i)));a&&(this._selectedViewName=a)},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;var 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 h(e).sort({field:"start",dir:"asc"}).toArray()[0].start||new Date;var n=new h(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();var n=this._range(e);var 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){var t=this._tasks;var n=t.length;var i;for(var r=0;r<n;r++)if((i=t[r]).uid===e)return i},_draggable:function(){var e=this;var t;var n;var i;var r;var o=this.options.snap;var a=M.styles;var s=this.options.editable;var l=function(){e.view()._removeDragHint(),t&&t.css("opacity",1),t=null,n=null,e.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=e.view();t=s.currentTarget.closest(v+a.taskWrap),n=e._taskByUid(s.currentTarget.parent().find(v+a.task).attr("data-uid")),e.trigger("moveStart",{task:n})?s.preventDefault():(i=n.start,r=l._timeByPosition(s.x.location,o)-i,l._createDragHint(t),t.css("opacity",.5),clearTimeout(e._tooltipTimeout),e.dragInProgress=!0)})).bind("drag",kendo.throttle((function(t){if(e.dragInProgress){var a=e.view();var s=new Date(a._timeByPosition(t.x.location,o)-r);var l=s;e.trigger("move",{task:n,start:s})||(i=s,c&&(l=new Date(i.getTime()+n.duration())),a._updateDragHint(l))}}),15)).bind("dragend",(function(){e.trigger("moveEnd",{task:n,start:i}),l()})).bind("dragcancel",(function(){l()})).userEvents.bind("select",(function(){S()})))},_resizable:function(){var e=this;var t;var n;var i;var r;var o;var a=this.options.snap;var s=M.styles;var l=this.options.editable;var d=function(){e.view()._removeResizeHint(),t=null,n=null,e.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){o=a.currentTarget.hasClass(s.taskResizeHandleWest),c&&(o=!o),t=a.currentTarget.closest(v+s.taskWrap).find(v+s.task),n=e._taskByUid(t.attr("data-uid")),e.trigger("resizeStart",{task:n})?a.preventDefault():(i=n.start,r=n.end,e.view()._createResizeHint(n),clearTimeout(e._tooltipTimeout),e.dragInProgress=!0)})).bind("drag",kendo.throttle((function(t){if(e.dragInProgress){var s=e.view();var l=s._timeByPosition(t.x.location,a,!o);o?i=l<r?l:r:r=l>i?l:i,e.trigger("resize",{task:n,start:i,end:r})||s._updateResizeHint(i,r,o)}}),15)).bind("dragend",(function(){e.trigger("resizeEnd",{task:n,resizeStart:o,start:i,end:r}),d()})).bind("dragcancel",(function(){d()})).userEvents.bind("select",(function(){S()})))},_percentResizeDraggable:function(){var e=this;var t;var n;var i;var r;var o;var s;var l;var d;var h;var u=M.styles;var p;var f=this.options.editable;var m=function(){e.view()._removePercentCompleteTooltip(),n=null,t=null,e.dragInProgress=!1};var g=function(e){var t=n.siblings(v+u.taskDragHandle);t.length||(t=n.closest(v+u.taskWrap).find(v+u.taskDragHandle)),t.css(c?"right":"left",e),n.find(v+u.taskComplete).width(e)};f&&!1!==f.dragPercentComplete&&!1!==f.update&&(this._percentDraggable=new kendo.ui.Draggable(this.wrapper,{distance:0,filter:v+u.taskDragHandle,holdToDrag:!1}),this._percentDraggable.bind("dragstart",(function(c){e.trigger("percentResizeStart")?c.preventDefault():((n=c.currentTarget.siblings(v+u.task)).length||(n=c.currentTarget.closest(v+u.taskWrap).find(v+u.task)),t=e._taskByUid(n.attr("data-uid")),l=t.percentComplete,i=n.offset(),r=this.element.offset(),o=n.find(v+u.taskComplete).width(),s=a(n),clearTimeout(e._tooltipTimeout),e.dragInProgress=!0)})).bind("drag",kendo.throttle((function(t){if(e.dragInProgress){p=c?-t.x.initialDelta:t.x.initialDelta;var n=Math.max(0,Math.min(s,o+p));l=Math.round(n/s*100),g(n),d=i.top-r.top,h=i.left+n-r.left,c&&(h+=s-2*n),e.view()._updatePercentCompleteTooltip(d,h,l)}}),15)).bind("dragend",(function(){e.trigger("percentResizeEnd",{task:t,percentComplete:l/100}),m()})).bind("dragcancel",(function(){g(o),m()})).userEvents.bind("select",(function(){S()})))},_createDependencyDraggable:function(){var t=this;var n;var i=e();var r=e();var o;var l;var c=M.styles;var d=this.options.editable;var h=function(){n.css("display","").removeClass(c.hovered),n.parent().removeClass(c.origin),n=null,u(!1),r=e(),i=e(),t.view()._removeDependencyDragHint(),t.dragInProgress=!1};var u=function(e){r.hasClass(c.origin)||(r.find(v+c.taskDot).css("display",e?"block":""),i.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(t.trigger("dependencyDragStart"))e.preventDefault();else{(n=e.currentTarget.css("display","block").addClass(c.hovered)).parent().addClass(c.origin);var i=n.offset();var r=t.wrapper.find(v+c.tasksWrapper).offset();o=Math.round(i.left-r.left+s(n)/2),l=Math.round(i.top-r.top+a(n)/2),clearTimeout(t._tooltipTimeout),t.dragInProgress=!0}})).bind("drag",kendo.throttle((function(n){if(t.dragInProgress){t.view()._removeDependencyDragHint();var a=e(kendo.elementUnderCursor(n));var s=t.wrapper.find(v+c.tasksWrapper).offset();var d=n.x.location-s.left;var h=n.y.location-s.top;t.view()._updateDependencyDragHint({x:o,y:l},{x:d,y:h}),u(!1),i=a.hasClass(c.taskDot)?a:e(),r=a.closest(v+c.taskWrap),u(!0)}}),15)).bind("dragend",(function(){if(i.length){var e=n.hasClass(c.taskDotStart);var r=i.hasClass(c.taskDotStart);var o=e?r?3:2:r?1:0;var a=n.siblings(v+c.task);a.length||(a=n.closest(v+c.taskWrap).find(v+c.task));var s=t._taskByUid(a.attr("data-uid"));var l=i.siblings(v+c.task);l.length||(l=i.closest(v+c.taskWrap).find(v+c.task));var d=t._taskByUid(l.attr("data-uid"));s!==d&&t.trigger("dependencyDragEnd",{type:o,predecessor:s,successor:d})}h()})).bind("dragcancel",(function(){h()})).userEvents.bind("select",(function(){S()})))},_selectable:function(){var t=this;var n=M.styles;this.options.selectable&&this.wrapper.on(p+u,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+u,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+u,v+n.tasksWrapper,(function(){t.selectDependency().length>0?t.clearSelection():t.trigger("clear")})).on(p+u,v+n.line,(function(e){e.stopPropagation(),t.selectDependency(this)}))},select:function(e){var t=this.wrapper.find(e);var n=M.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=this.wrapper.find(t);var i;var r=M.styles;return n.length?(this.clearSelection(),this.trigger("clear"),i=e(n).attr("data-uid"),void this.wrapper.find(v+r.line+"[data-uid='"+i+"']").addClass(r.selected)):this.wrapper.find(v+r.line+v+r.selected)},clearSelection:function(){var e=M.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;var n=M.styles;this.options.editable&&(this.wrapper.on(p+u,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"+u,(function(e){var n;var 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"+u,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=this;var n=this.options.tooltip;var i=M.styles;var r;var o=function(e){r=e.clientX};n&&!1===n.visible||(kendo.support.mobileOS?(this.wrapper.on(p+u,v+i.taskDelete,(function(e){e.stopPropagation(),t.view()._removeTaskTooltip()})).on(g+u,v+i.task,(function(n){0===e(n.relatedTarget).parents(v+i.taskWrap,v+i.task).length&&t.view()._removeTaskTooltip()})).on(g+u,v+i.taskOffset,(function(n){0===e(n.relatedTarget).parents(v+i.taskWrap,v+i.task).length&&t.view()._removeOffsetTooltip()})).on(g+u,v+i.taskPlanned,(function(n){0===e(n.relatedTarget).parents(v+i.taskWrap,v+i.task).length&&t.view()._removePlannedTooltip()})),this.touch&&this.touch.bind("tap",(function(n){var r=e(n.touch.target);var o=n.touch.x.client;var a;r.hasClass(i.task)?(a=t._taskByUid(r.attr("data-uid")),t.view()._taskTooltip&&t.view()._removeTaskTooltip(),t.view()._createTaskTooltip(a,r,o)):(a=t._taskByUid(r.closest(v+i.taskWrap).find(v+i.task).attr("data-uid")),t.view()._offsetTooltip&&t.view()._removeOffsetTooltip(),t.view()._createOffsetTooltip(a,r,o))})).bind("doubletap",(function(){t.view()._removeTaskTooltip(),t.view()._removeOffsetTooltip()}))):this.wrapper.on(m+u,v+i.task,(function(){var n=this;var i=t._taskByUid(e(this).attr("data-uid"));t.dragInProgress||(t._tooltipTimeout=setTimeout((function(){t.view()._createTaskTooltip(i,n,r)}),800),e(this).on(f,o))})).on(g+u,v+i.task,(function(){clearTimeout(t._tooltipTimeout),t.view()._removeTaskTooltip(),e(this).off(f,o)})).on(m+u,v+i.taskOffset,(function(){var n=e(this).closest(v+i.taskWrap).find(v+i.task);var a=t._taskByUid(n.attr("data-uid"));t.dragInProgress||(t._offsetTooltipTimeout=setTimeout((function(){t.view()._createOffsetTooltip(a,n,r)}),800),e(this).on(f,o))})).on(g+u,v+i.taskOffset,(function(){clearTimeout(t._offsetTooltipTimeout),t.view()._removeOffsetTooltip(),e(this).off(f,o)})).on(m+u,v+i.taskPlanned,(function(){var n=e(this).closest(v+i.taskWrap).find(v+i.task);var a=t._taskByUid(n.attr("data-uid"));t._plannedTooltipTimeout=setTimeout((function(){t.view()._createPlannedTooltip(a,n,r)}),800),e(this).on(f,o)})).on(g+u,v+i.taskPlanned,(function(){clearTimeout(t._plannedTooltipTimeout),t.view()._removePlannedTooltip(),e(this).off(f,o)})))},_setPlanned:function(e){this.options.showPlannedTasks=e,this.view().options.showPlannedTasks=e}});l(!0,M,{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.ui.TreeList,l=n.htmlEncode,c=n.data.ObservableObject,d=n.data.ObservableArray,h=n.data.Query,u=Array.isArray,p=n.isFunction,f=e.extend,m=e.isPlainObject,g=n._outerWidth,v=n._outerHeight,_=".kendoGantt",b="tabIndex",w="string",y=".",k=({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>`,x=[{data:"add",text:"addChild"},{data:"insert-before",text:"insertBefore"},{data:"insert-after",text:"insertAfter"}];var C={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 S(e){return"["+n.attr("uid")+(e?"='"+e+"']":"]")}function T(t,i){var r=t.parents("["+n.attr("role")+'="gantt"]');var o=[];var a=function(t){return e(t).parentsUntil("body").filter((function(e,t){return"visible"!=n.getComputedStyles(t,["overflow"]).overflow})).add(window)}(r);t.attr(b,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 M=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===w&&(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(_),r&&(this._mediaQuery.removeListener(this._mediaQueryHandler),this._mediaQuery=null),e(window).off("resize"+_,this._resizeHandler),e(this.wrapper).off(_),this.toolbar=null,this.footer=null,n.destroy(this.element)},setOptions:function(t){var i=n.deepExtend({},this.options,t);var r=this._events;if(!t.views){var o=this.view().name;i.views=e.map(this.options.views,(function(e){var t=m(e);var 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"+_,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=M.styles;var n=this.options;var i=n.height;var 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;var 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+C.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=M.styles.toolbar,s=this.options.messages.actions,l={append:{name:"append",type:"dropDownButton",menuButtons:x.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:k({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===w?{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;var n=t.layout.find(".k-splitbar");var i=t._getGanttSplitter();var r=t.treelistWrapper;var o=t.timelineWrapper;var a=y+C.gridContent;var s=t.toolbar;var 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=this;var i=M.styles;var o=y+i.toolbar.viewsDropdown;var a=this.options.toolbar;var s;var l;typeof a===w&&(a=n.template(a).bind(this)),s=p(a)?this._processTools([{template:a({})}]):this._processTools(a),l=e("<div class='"+i.toolbar.headerWrapper+"'>"),this.wrapper.prepend(l),this.toolbar=l,l.kendoToolBar({resizable:!1,tools:s,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))),l.on("change"+_,o,(function(){var n=t.list;var i=e(this).val();n.editable&&n.editable.trigger("validate")||t.trigger("navigate",{view:i})||t.view(i)})),this.toggleSwitch=l.find("input.k-gantt-planned-switch").data("kendoSwitch")},_footer:function(){var t=this.options.editable;if(t&&!1!==t.create){var n=M.styles.toolbar;var i=this.options.messages.actions;var r=e("<div class='"+n.footerWrapper+"'>");this.wrapper.append(r),this.footer=r,r.kendoToolBar({resizable:!1,size:"medium",tools:["append"],defaultTools:{append:f(!0,{},this.defaultCommands.append,{direction:"up",animation:{open:{effects:"slideIn:up"}}})},parentMessages:i})}},_adjustDimensions:function(){var e=this.element;var t=v(this.toolbar);var n=this.footer?v(this.footer):0;var i=e.height();var r=e.width();var o=this.treelistWrapper.is(":visible");var a=this.layout.find(".k-splitbar");var s=a.is(":visible")?g(a):0;var l=o?g(this.treelistWrapper):0;var 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=this.timeline.view();var i=this.list;var r=n.attr("uid");var o="string"==typeof e?e:e.closest("tr"+S()).attr(r);var a;var s;t.content.is(":visible")?(s=t.content.find(S(o)),a=function(){t._scrollTo(s)}):(s=i.element.find(S(o)),a=function(){s.get(0).scrollIntoView()}),0!==s.length&&a()},_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");var n=this.dataSource;var i=this.dataItem(this.select());var r=n.taskParent(i);var 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+C.list);return{columns:e.columns||[],dataSource:this.dataSource,navigatable:e.navigatable,selectable:e.selectable,reorderable:e.reorderable,editable:t,messages:s.prototype.options.messages,resizable:e.resizable,filterable:e.filterable,columnMenu:e.columnMenu,columnResizeHandleWidth:this.options.columnResizeHandleWidth,listWidth:g(n),resourcesField:this.resources.field,rowHeight:this.options.rowHeight}},_attachResourceEditor:function(e){var t;for(var 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,h=n.previousTask,u=n.options.navigatable;if(n._preventItemChange)n._preventItemChange=!1;else{for(s in h)h.hasOwnProperty(s)&&c.set(s,h[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])),u&&(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){if(n.list.tbody){const 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=e.sender.current();var i;n._scrollTo(t),n.timeline.element.find("div.k-task").attr("tabindex","-1"),i=t.closest("tr").attr("data-uid"),n.timeline.element.find("div.k-task[data-uid='"+i+"']").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=M.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;var t=M.styles;var i=function(e){return delete e.name,delete e.prefix,delete e.remove,delete e.edit,delete e.add,delete e.navigate,e}(f(!0,{resourcesField:this.resources.field},this.options));var 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();var r=e.toolbar.find(y+t.toolbar.views);var 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;var i=t.start;var 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;var i=t.start;var 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;var 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||{};var 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;var t=e.dataSource||{};this.resources={field:"resources",dataTextField:"name",dataColorField:"color",dataFormatField:"format"},f(this.resources,e),this.resources.dataSource=n.data.DataSource.create(t)},_assignments:function(){var e=this.options.assignments;var 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"},f(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,f({},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,s=a._createResourceEditor(e("<div>"),i),c=C.popup,d=a.element,h=e(n.format('<div class="'+c.formContainer+'">')).appendTo(d),u=a.options.messages;return h.append(s.wrapper),r=e('<div class="'+c.buttonsContainer+'">'),h.append(r),r.append(e("<button class='"+C.buttonSave+"'>"+l(u.save)+"</button>").kendoButton({name:"save",themeColor:"primary",icon:"save",click:()=>{s.updateModel()&&(s.trigger("save",{model:s.model}),a._updateAssignments(s.model.get("id"),s.model.get(a.resources.field)),o.trigger("close"),o.close())}})),r.append(e("<button class='"+C.buttonCancel+"'>"+l(u.cancel)+"</button>").kendoButton({name:"cancel",icon:"cancel",click:()=>{o.trigger("close"),o.close()}})),this._resourceEditorWindow=o=h.kendoWindow({modal:!0,resizable:!1,draggable:!0,visible:!1,title:u.editor.resourcesEditorTitle,deactivate:()=>{s.destroy(),o.destroy(),o.element.closest(".k-window").remove()}}).data("kendoWindow"),o.center().open(),s},_createResourceEditor:function(e,t){var i=t instanceof c?t:t.model;var r=this.options.messages;var o=this.resources.field;var a={step:.01,min:.01,max:1};var s=this.assignments.dataSource.options.schema.model;var l=this.resources.dataTextField;var d=this.resources.dataSource.view();return s&&s.fields.Units&&s.fields.Units.validation&&f(!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[l]}))),model:i,messages:f({},r.editor)})},view:function(e){return this.timeline.view(e)},range:function(e){var t=this.dataSource;var n=this.view();var 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;var 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){var i=this.assignments.dataSource;var r=this.assignments.dataTaskIdField;var o=this.assignments.dataResourceIdField;var a=!1;var s=new h(i.view()).filter({field:r,operator:"eq",value:e}).toArray();var l;var c;var d;for(;s.length;){l=s[0];for(var u=0,p=n.length;u<p;u++)if(c=n[u],l.get(o)===c.get("id")){d=n[u].get("value"),this._updateAssignment(l,d),n.splice(u,1),a=!0;break}a||this._removeAssignment(l),a=!1,s.shift()}for(var f=0,m=n.length;f<m;f++)(c=n[f]).id!==t&&c.value&&this._createAssignment(c,e);i.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,h=(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===h?(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[h]),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;var 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;var 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;var i=n.dataSource;var r=n.dataTaskIdField;var o=n.dataResourceIdField;var a=n.dataValueField;var 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;var 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;var n=t.view();var i={field:this.assignments.dataTaskIdField,operator:"eq",value:e.get("id")};n=new h(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:l(n.deleteTaskConfirmation),title:l(n.deleteTaskWindowTitle)})},_dependencyConfirm:function(e,t){let n=this.options.messages;this._confirm(e,{model:t,text:l(n.deleteDependencyConfirmation),title:l(n.deleteDependencyWindowTitle)})},_confirm:function(e,t){var n=this.options.editable;!0===n||!1!==n.confirmation?this.showDialog(f(!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=this.dataSource.taskTree();var t=this._scrollToUid;var i;var r;var o=-1;var a=this.select()[0]?this.select().data("uid"):this._selected;this.current&&(r=this.current.closest("tr").attr(n.attr("uid")),o=this.current.index()),this.trigger("dataBinding")||(0!==this.resources.dataSource.data().length&&this._assignResources(e),this._editor&&this._editor.close(),this.clearSelection(),this.list._renderTree(e),this.timeline._render(e),this.timeline._renderDependencies(this.dependencies.view()),t&&(this._scrollTo(t),this.select(S(t))),(t||r)&&o>=0&&(i=this.list.element.find("tr"+S(t||r)+" > td").eq(o),this._current(i)),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){var t=this.resources;var i=this.assignments;var r=function(){var e=i.dataSource.view();var t={field:i.dataTaskIdField};return e=new h(e).group(t).toArray()}();var o=function(e,i){var o=e.get("id");n.setter(t.field)(e,new d([]));for(var a=0,s=r.length;a<s;a++)r[a].value===o&&i(e,r[a].items)};var a=function(e,r){for(var o=0,a=r.length;o<a;o++){var s=r[o];var l=t.dataSource.get(s.get(i.dataResourceIdField));var d=s.get(i.dataValueField);var h=s.get(i.dataResourceIdField);var u=l.get(t.dataFormatField)||"p0";var p=n.toString(d,u);e[t.field].push(new c({id:h,name:l.get(t.dataTextField),color:l.get(t.dataColorField),value:d,formatedValue:p,format:u}))}};for(var s=0,l=e.length;s<l;s++)o(e[s],a)},_wrapResourceData:function(e){var t=this;var n=[];var i;var r=this.resources.dataSource.view();var o=this.assignments.dataSource.view();var a=new h(o).filter({field:t.assignments.dataTaskIdField,operator:"eq",value:e}).toArray();var s=function(e){var n=null;return new h(a).filter({field:t.assignments.dataResourceIdField,operator:"eq",value:e}).select((function(e){n+=e.get(t.assignments.dataValueField)})),n};for(var l=0,c=r.length;l<c;l++)i=r[l],n.push({id:i.get("id"),name:i.get(t.resources.dataTextField),format:i.get(t.resources.dataFormatField)||"p0",value:s(i.id)});return n},_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;var i=M.styles;var r=y+i.gridContent;var a=y+i.gridHeaderWrap;var s=this.timeline.element.find(a);var l=this.timeline.element.find(r);var c=this.list.element.find(a);var 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"+_+" mousewheel"+_,(function(t){var i=l.scrollTop();var r=n.wheelDeltaY(t);r&&(t.preventDefault(),e(t.currentTarget).one("wheel"+_,!1),l.scrollTop(i+-r))}))},_navigatable:function(){var t=this;var r=this.options.navigatable;var o=this.options.editable;var a=M.styles;var s=y+a.gridContent;var l=y+a.listWrapper;var c=y+a.gridHeaderWrap;var d=this.list.element.find(c).find("table");var h=this.list.element.find(s).find("table");var u=d.add(h);var p=S();e(this.wrapper).on("mousedown"+_,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(){T(t.list.content.find("table"),!0)}),2))})).on("keydown"+_,function(t){var n=t.keyCode;var r=this;var o;var s;var l=e(t.target);var c;var d=[r.toolbar,r.layout.find(".k-splitbar"),r.layout.find(".k-gantt-treelist"),r.layout.find(".k-gantt-timeline-pane")];r._tabPressed=!1,r.footer&&d.push(r.footer);for(var h=0;h<d.length;h++)if(e.contains(d[h][0],t.target)||d[h][0]===t.target){c=h;break}if(n===i.F10)r.toolbar.find("[tabindex=0]:visible").first().addClass(a.focused).trigger("focus"),t.preventDefault();else if(n==i.TAB)if(2==c&&(r._tabPressed=!0),t.shiftKey){for(h=c-1;h>=0;h--)if(!d[h].hasClass("k-hidden")){o=l.attr("data-uid"),2===h&&o?(s=r.list.content.find("tr[data-uid='"+o+"']").find("td").last(),r.list.current(s),T(r.list.content.find("table"),!0)):d[h].is(":kendoFocusable")?d[h].trigger("focus"):d[h].find("[tabindex=0]:visible").trigger("focus"),t.preventDefault();break}}else for(h=c+1;h<d.length;h++)if(!d[h].hasClass("k-hidden")){d[h].is(":kendoFocusable")?d[h].trigger("focus"):d[h].find("[tabindex=0]:visible").trigger("focus"),t.preventDefault();break}}.bind(this)),r?h.on("keydown"+_,(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();var 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))})):u.on("focus"+_,(function(){e(t.toolbar.find(y+a.focused)).removeClass(a.focused)})).on("blur"+_,(function(){this==d&&e(this).attr(b,-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(C.plannedTasks),t._setPlanned(!t.options.showPlannedTasks),t._render(this.dataSource.taskTree()),t._renderDependencies(this.dependencies.view()))}});n.PDFMixin&&(n.PDFMixin.extend(M.fn),M.fn._drawPDF=function(){const e=M.styles;const t=this.wrapper.find(y+e.list+" "+y+e.gridContent+">table").width();const n=this.wrapper.find(y+e.list+" "+y+e.gridContent+">table").height();const i=this.wrapper.find(y+e.list+" "+y+e.gridHeader).outerHeight();const r=this.wrapper.find(y+e.timeline+" "+y+e.gridContent+" table").width();const 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(M),f(!0,M,{styles:C})}(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=t.sanitizeLink,c="vertical",d="transitionEnd",h="k-timeline-flag-wrap",u="k-timeline-track-item",p="k-timeline-scrollable-wrap",f=".k-timeline-track-item:not(.k-timeline-flag-wrap)",m=".kendoTimeline",g="change",v=e=>{let t=e.titleField,n=e.subtitleField,i=e.descriptionField,r=e.imagesField,o=e.actionsField,a=e.altField,c=e.data;return'<div class="k-card-inner"><div class="k-card-header">'+(c[t]?`<div class="k-card-title"><span class="k-event-title">${s(c[t])}</span></div>`:"")+(c[n]?`<div class="k-card-subtitle">${s(c[n])}</div>`:"")+'</div><div class="k-card-body"><div class="k-card-description">'+(c[i]?`<p>${s(c[i])}</p>`:"")+(c[r]&&c[r].length>0?`<img src="${s(c[r][0].src)}" ${c[a]?`alt="${s(c[a])}"`:""} class="k-card-media" />`:"")+"</div></div>"+(c[o]&&c[o].length>0?'<div class="k-actions k-card-actions">'+c[o].map((e=>`<a class="k-button k-button-md k-rounded-md k-button-flat k-button-flat-primary" href="${e.url?l(e.url):"#"}"><span class="k-button-text">${s(e.text)}</span></a>`)).join("")+"</div>":"")+"</div>"},_=e=>{let n=e.titleField,i=e.subtitleField,r=e.descriptionField,o=e.imagesField,a=(e.navigatable,e.collapsibleEvents),c=e.actionsField,d=e.altField,h=e.data;return'<div class="k-card-inner"><div class="k-card-header"><div class="k-card-title">'+(h[n]?`<span class="k-event-title">${s(h[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>"+(h[i]?`<div class="k-card-subtitle">${s(h[i])}</div>`:"")+'</div><div class="k-card-body"><div class="k-card-description">'+(h[r]?`<p>${s(h[r])}</p>`:"")+(h[o]&&h[o].length>0?`<img src="${s(h[o][0].src)}" ${h[d]?`alt="${s(h[d])}"`:""} class="k-card-media" />`:"")+"</div></div>"+(h[c]&&h[c].length>0?'<div class="k-actions k-card-actions">'+h[c].map((e=>`<a class="k-button k-button-md k-rounded-md k-button-flat k-button-flat-primary" href="${e.url?l(e.url):"#"}"><span class="k-button-text">${s(e.text)}</span></a>`)).join("")+"</div>":"")+"</div>"},b=e=>{e.itemTemplate;let n=e.dateField,i=e.dateFormat,r=e.showDateLabels,o=e.data,a=0;let 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},w=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,h=e.collapsibleEvents,u=e.dateFormat,p=e.showDateLabels,f=e.navigatable,m=e.altField,g=e.data,v=0,_=0,b=!1;let w="";for(var y=0;y<g.length;y++)if(g[y][i]instanceof Date){var k=g[y][i].getFullYear();k!=_&&(_=k,w+=`<li class="k-timeline-flag-wrap"><span class="k-timeline-flag">${_}</span></li>`),b=v%2==0&&d,w+=`<li class="${b?"k-timeline-event k-reverse":"k-timeline-event"}" data-uid="${s(g[y].uid)}"><div class="k-timeline-date-wrap">`+(p?`<span id="${s(g[y].uid)}-date" class="k-timeline-date">${t.toString(g[y][i],u)}</span>`:"")+'</div><span class="k-timeline-circle"></span>'+`<div class="${h?"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[y].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[y],altField:m,navigatable:f,collapsibleEvents:h})}</div></div></li>`,v++}return w},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 k(e){var t=e.css("transform");return"none"!=t&&""!=t?t.match(/-?[\d\.]+/g)[4]/e.width()*100:0}function x(e,t){return e.offset().left-t.offset().left+e.width()/2}function C(e,t,n){e.css(t,n)}var S=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);var i;this.element=e("<li class='"+(i="timeline-event","k-"+i+"'></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}});var T=t.Observable.extend({init:function(n,i){var o=this;var a,s,l;t.Observable.fn.init.call(this),this.element=n,a=new t.ui.Movable(o.element),s=new r({axis:"x",movable:a,onEnd:function(){o.trigger(d)}}),l=[],e.extend(o,{duration:i&&i.duration||1,movable:a,transition:s,pages:l,eventTemplate:i.eventTemplate,eventHeight:i.eventHeight,dataFieldMappings:i.dataFieldMappings,dateFormat:i.dateFormat}),this.bind([d],i)},initPages:function(){var e,t=this.pages,n=this.element;for(var i=0;i<3;i++)e=new S(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=typeof this.eventTemplate===Function?this.eventTemplate:t.template(this.eventTemplate);var r=this.dataFieldMappings;var o=t.toString(n.date,this.dateFormat);var a;a=i({data:n,titleField:r.title,subtitleField:r.subtitle,descriptionField:r.description,imagesField:r.images,actionsField:r.actions,altField:r.altField}),e.content(a,n.uid,o)},updatePage:function(e,t,n){var i=this.pages;var 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(){var e=this;for(var 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}});var M=t.ui.Widget.extend({init:function(t,i){var r=this;var o=i.orientation||r.options.orientation;n.fn.init.call(this,t,i),this.element.addClass(o===c?"k-timeline k-timeline-vertical":"k-timeline k-timeline-horizontal"),o!=c?r._horizontal():r._vertical(),this.element.on("click",".k-card-actions",(function(t){var n=e(t.target);var i=e(t.target).closest(".k-timeline-event").data("uid");var 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;var n=this.element;var i=this.options;var r=e("<div />");var o=e("<div />");var a=e("<ul role='tablist' tabindex='0' />");var s=e("<div />");var 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(p),s.addClass("k-timeline-events-list"),l.addClass(p),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;var n=this.options;var i=this.element;var r=t._eventsList=e("<ul />");var a=n.navigatable;var 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");var i=n.parent();var 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"+m,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=this.options;var i;var r;r=typeof n.eventTemplate===Function?n.eventTemplate:n.eventTemplate?t.template(n.eventTemplate):t.template(_,{useWithBlock:!1}),i=t.template(w,{useWithBlock:!1})({data:e,dateField:n.dataDateField,titleField:n.dataTitleField,subtitleField:n.dataSubtitleField,descriptionField:n.dataDescriptionField,imagesField:n.dataImagesField,actionsField:n.dataActionsField,itemTemplate:r,alterMode:n.alternatingMode,collapsibleEvents:n.collapsibleEvents,dateFormat:n.dateFormat,showDateLabels:n.showDateLabels,altField:n.dataImagesAltField,navigatable:n.navigatable}),this._eventsList.html(i),n.eventWidth&&this.element.find(".k-card").width(n.eventWidth)},_renderContentHorizontal:function(n){var i=this;var r=i.options;var o;var a;var s=i._dataFieldMappings;a=typeof r.eventTemplate===Function?r.eventTemplate:r.eventTemplate?t.template(r.eventTemplate):t.template(v,{useWithBlock:!1}),o=t.template(b,{useWithBlock:!1})({data:n,itemTemplate:a,dateFormat:r.dateFormat,dateField:r.dataDateField,showDateLabels:r.showDateLabels}),r.initialEventIndex?i._trackWrap.append(e(o).find("."+p).css("transform","translateX(-100%)").parent()):i._scrollableWrap.html(o),i.pane&&i.pane.destroy(),i.pane=new T(i._eventsList,{transitionEnd:this._transitionEnd.bind(this),eventTemplate:a,dataFieldMappings:s,eventHeight:r.eventHeight,dateFormat:r.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=this;var i=e(t.currentTarget);var r;var o=n.dataSource.view()[i.parent().children(":not(.k-timeline-flag-wrap)").index(i)];r=n._forward?n.pane.pages[2].element:n.pane.pages[0].element,n.trigger("change",{eventContainer:r,dataItem:o})||n.open(i)},open:function(t){var n=this;var i=e(t);var o=i.find(".k-timeline-circle");var a=i.parent().children(":not(.k-timeline-flag-wrap)");var s=a.index(i);var l;this.options.navigatable&&(n._removeCurrent(),a.attr("aria-selected",!1),i.attr("aria-selected",!0),n._currentBullet=i);var c=n.dataSource.view()[s];n.currentEventIndex!==s&&(n._currentIndex=i.index(),l=n._forward=n.currentEventIndex<s,n.currentEventIndex=s,n.pane.updatePage(l,c,x(o,n._trackWrap)),n._forward?(clearTimeout(n.navigateTimeOut),n.navigateTimeOut=setTimeout((function(){n.pane.transition.moveTo({location:-n.pane.pages[2].element.width(),duration:800,ease:r.easeOutExpo})}),200)):(clearTimeout(n.navigateTimeOut),n.navigateTimeOut=setTimeout((function(){n.pane.transition.moveTo({location:n.pane.pages[0].element.width(),duration:800,ease:r.easeOutExpo})}),200)),n._repositionEvents())},_navigateToView:function(t){var n=this;var 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;var t=e.element.find(".k-timeline-arrow");var n=t.filter(".k-timeline-arrow-left");var 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;var n=t._end||0;return e?t._firstIndexInView+t.numOfEvents>=t.maxEvents:Math.abs(n)<=1},next:function(){var e=this;var t=e.options;e._validateNavigation(!0)||t.orientation==c||(e._forward=!0,e._navigate()),e._updateArrows()},_navigate:function(){var t=this;var n;var i;var o;var a=t._forward;var s=k(this._trackWrap.find("."+p));var l=a?-e("."+p).width():e("."+p).width();var c=t._currentIndex;var d;var g=t._firstIndexInView;if((s=a?s-100:s+100)>=0&&(s=0),t._end=s,t._tackItemWidth,d=Math.floor(c/t.numOfEvents),a?1===t.numOfEvents?(n=0===g?1:g,i=this._trackWrap.find("."+u).eq(n).nextAll(":not(."+h+")").first(),t._firstIndexInView=i.index()):(n=g+t.numOfEvents-1,i=this._trackWrap.find("."+u).eq(n).nextAll(":not(."+h+")").first(),t._firstIndexInView=g+t.numOfEvents):1===t.numOfEvents?(n=g,i=this._trackWrap.find("."+u).eq(n).prevAll(":not(."+h+")").first(),t._firstIndexInView=i.index()):(n=g,i=(i=this._trackWrap.find("."+u).eq(n).prevAll(":not(."+h+")").first()).length>0?i:this._trackWrap.find("."+u+":not(."+h+")").first(),t._firstIndexInView=g-t.numOfEvents<0?0:g-t.numOfEvents),o=t.dataSource.view()[this._trackWrap.find(f).index(i)],this._trackWrap.find("."+p).css("transform","translateX("+s+"%)"),t._currentIndex!=i.index())t.currentEventIndex=this._trackWrap.find(f).index(i),t._currentIndex=i.index(),t.pane.updatePage(t._forward,o,0!==d||a?x(i.find(".k-timeline-circle"),t._trackWrap)+l:i.find(".k-timeline-circle").offset().left+15),clearTimeout(t.navigateTimeOut),t.navigateTimeOut=setTimeout((function(){a&&t.pane&&t.pane.pages.length>0?t.pane.transition.moveTo({location:-t.pane.pages[2].element.width(),duration:800,ease:r.easeOutExpo}):t.pane.transition.moveTo({location:t.pane.pages[0].element.width(),duration:800,ease:r.easeOutExpo})}),200);else{var v=this._trackWrap.find("."+p);var _=function(){if(1!=t.numOfEvents){var e=t.pane.pages[1];var n=x(i.find(".k-timeline-circle"),t._trackWrap);e.setPageCallout("left",n/e.element.width()*100+"%")}this._transition=null,v.off("transitionend"+m,_)};v.on("transitionend"+m,_)}},previous:function(){var e=this;var t=e.options;e._validateNavigation(!1)||t.orientation==c||(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!=c&&(this._redrawEvents(),this.pane.repositionPages())},_redrawEvents:function(){var e=this;var t=Math.floor(e.element.find("."+p).width()/150);var n;e.element.width()<=480?(e.element.addClass("k-timeline-mobile"),n=100,e.numOfEvents=1,e._tackItemWidth=n,e.element.find("li."+u).css("flex","1 0 "+n+"%"),e._repositionEvents()):(e.element.removeClass("k-timeline-mobile"),t!=e.numOfEvents&&(e.numOfEvents=t,n=100/t,C(e.element.find("li."+u),"flex","1 0 "+n+"%"),e._tackItemWidth=n,e._repositionEvents())),e._updateArrows()},_repositionEvents:function(){var e=this;var t=e._tackItemWidth;var n=null===e._forward?e.pane.pages[1]:e._forward?e.pane.pages[2]:e.pane.pages[0];var i=this._trackWrap.find("."+p);var r=k(i);var o;var a;var s;if(a=1===e.numOfEvents?e.currentEventIndex*t:e._currentIndex*t,n){if(1===e.numOfEvents)return n.setPageCallout("left","50%"),C(i,"transform","translateX(-"+(s=a)+"%)"),e._firstIndexInView=e._currentIndex,void e._updateArrows();a>=Math.abs(r)+100?(s=Math.abs(r)+(a-(Math.abs(r)+100)+t),e._end=-s,C(i,"transform","translateX(-"+s+"%)"),e._firstIndexInView=e._currentIndex-e.numOfEvents+1):a<=Math.abs(r)?(s=a,e._end=-s,C(i,"transform","translateX(-"+s+"%)"),e._firstIndexInView=e._currentIndex):(o=x(i.find("li."+u).eq(e._currentIndex).find(".k-timeline-circle"),e._trackWrap),n.setPageCallout("left",o/n.element.width()*100+"%"),e._firstIndexInView=Math.round(Math.abs(r)/t));var l=this._trackWrap.find("."+p);var c=function(){if(1!=e.numOfEvents){var t=e.pane.pages[1];var n=x(e._trackWrap.find("."+u).eq(e._currentIndex).find(".k-timeline-circle"),e._trackWrap);t.setPageCallout("left",n/t.element.width()*100+"%")}l.off("transitionend"+m,c)};l.on("transitionend"+m,c)}e._updateArrows()},_initHorizontal:function(){var e=this;var n=e._trackWrap.find(".k-timeline-circle").first();var i=e.dataSource.view()[0];var r=e.options.navigatable;var a;e.maxEvents=e._trackWrap.find("."+u).length,e._currentIndex=1,e.pane.initPages(),e.pane.repositionPages(),e.pane.updatePage(e._forward,i,x(n,e._trackWrap)),e._updateArrows(),e._resizeHandlerBound=e._resizeHandler.bind(e),t.jQuery(window).on("resize"+m,e._resizeHandlerBound),e._trackWrap.on("click",f,e._setCurrentEvent.bind(e)),e._trackWrap.on("click",".k-timeline-arrow:not(.k-disabled)",e._navigateToView.bind(e)),r&&(e._trackWrap.find(".k-timeline-track-item.k-timeline-flag-wrap").attr("role","none").attr("aria-hidden",!0),e._trackWrap.find(f).attr("aria-selected",!1).first().attr("aria-selected",!0),e._cardId=t.guid(),e._scrollableWrap.on("focus"+m,(function(){e.pane.pages[1].cardContainer.attr("id",e._cardId),e._currentBullet&&e._currentBullet.addClass("k-focus")})).on("focusout"+m,(function(){e._currentBullet&&e._currentBullet.removeClass("k-focus")})).on("keydown"+m,(function(t){var n;var i=e._currentBullet;var r;var a;e._transition||(t.keyCode==o.LEFT&&(n=!0,(a=i.prevAll(f).first()).length&&((r=x(a,e._trackWrap))<0||r>a.parent().width()?(e._transition=!0,e._removeCurrent(),e.previous(),e.open(a)):e._setCurrentEvent({currentTarget:a}))),t.keyCode==o.RIGHT&&(n=!0,(a=i.nextAll(f).first()).length&&((r=x(a,e._trackWrap))<0||r>a.parent().width()?(e._transition=!0,e._removeCurrent(),e.next(),e.open(a)):e._setCurrentEvent({currentTarget:a}))),n&&t.preventDefault())})),a=e._scrollableWrap.find("."+u).eq(e._currentIndex),e._setCurrent(a),a.removeClass("k-focus"))},_setCurrent:function(e){if(e){var n=t.guid();var 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;var n=t.options;e=a(e)?{data:e}:e,t.dataSource&&t._refresh?t.dataSource.unbind(g,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(g,t._refresh),n.autoBind&&this.dataSource.fetch()},refresh:function(){var e=this;var t=e.options;var n=this.dataSource.view();t.orientation!=c&&(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"+m,this._resizeHandlerBound),this._resizeHandlerBound=null,this.element.off(),i.orientation!=c&&(this.pane&&this.pane.destroy(),this._trackWrap.find("."+p).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(M)}(window.kendo.jQuery);kendo;function by(e){const t=Math.floor(e/26)-1;return(t>=0?by(t):"")+String.fromCharCode(65+e%26)}function wy(e){return/^[a-z_][a-z0-9_]*$/i.test(e)?e:"'"+e.replace(/\x27/g,"\\'")+"'"}function yy(e,t,n,i){let r="";return++t,isFinite(t)?null==i||2&i||(t="$"+t):t="",isFinite(n)?(r=by(n),null==i||1&i||(r="$"+r)):n="",e?wy(e)+"!"+r+t:r+t}class ky{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)!==xy}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;let n=e;if(t===xy||n===xy)return t===n;if((n instanceof Sy||n instanceof Ty&&!(t instanceof Sy))&&(t=e,n=this),t instanceof Sy)return n=n.simplify(),n instanceof Sy&&t.row==n.row&&t.col==n.col&&t.sheet==n.sheet;if(t instanceof Ty){if(n instanceof Ty)return n.topLeft.eq(t.topLeft)&&n.bottomRight.eq(t.bottomRight);if(n instanceof My)return n.single()&&t.eq(n.refs[0])}else if(t instanceof My&&n instanceof My){const e=t.refs;const 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 My([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}}ky.display=yy;const xy=new class extends ky{print(){return"#NULL!"}eq(e){return e===this}forEach(){}};class Cy extends ky{constructor(e){super(),this.name=e,this.ref="name"}clone(){return new Cy(this.name).setSheet(this.sheet,this.hasSheet())}print(){let e=wy(this.name);return this.hasSheet()&&(e=wy(this.sheet)+"!"+e),e}}class Sy extends ky{constructor(e,t,n){super(),this.row=e,this.col=t,this.rel=n||0,this.ref="cell"}clone(){return new Sy(this.row,this.col,this.rel).setSheet(this.sheet,this.hasSheet())}intersect(e){return e instanceof Sy?this.eq(e)?this:xy: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()?wy(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),yy(this._hasSheet&&this.sheet,o,r,a)):i.valid()?yy(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 Ty(this,this)}relative(e,t,n){null==n&&(n=this.rel);let i=2&n?this.row-e:this.row;let r=1&n?this.col-t:this.col;return new Sy(i,r,n).setSheet(this.sheet,this.hasSheet())}height(){return 1}width(){return 1}toString(){return yy(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 xy;s.row+=a}}else if(s.col>=o){if(a<0&&s.col<o-a)return xy;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 Ty extends ky{constructor(e,t){super(),this.ref="range",e._hasSheet&&t._hasSheet&&e.sheet.toLowerCase()!=t.sheet.toLowerCase()&&(this.endSheet=t.sheet),this.topLeft=new Sy(e.row,e.col,e.rel),this.bottomRight=new Sy(t.row,t.col,t.rel),this.normalize()}clone(){return new Ty(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 Sy?this._containsCell(e):e instanceof Ty&&this._containsRange(e)}_intersectRange(e){if(this.sheet!=e.sheet)return xy;let t=this.topLeft.col;let n=this.topLeft.row;let i=this.bottomRight.col;let r=this.bottomRight.row;let o=e.topLeft.col;let a=e.topLeft.row;let s=e.bottomRight.col;let l=e.bottomRight.row;return t<=s&&o<=i&&n<=l&&a<=r?new Ty(new Sy(Math.max(n,a),Math.max(t,o)),new Sy(Math.min(r,l),Math.min(i,s))).setSheet(this.sheet,this.hasSheet()):xy}intersect(e){return e instanceof Sy?this._containsCell(e)?e:xy:e instanceof Ty?this._intersectRange(e).simplify():e instanceof My?e.intersect(this):xy}simplify(){return this.isCell()?new Sy(this.topLeft.row,this.topLeft.col,this.topLeft.rel).setSheet(this.sheet,this.hasSheet()):this}normalize(){let e=this.topLeft,t=this.bottomRight;let n=e.row,i=e.col,r=t.row,o=t.col;let a=2&e.rel,s=1&e.rel;let l=2&t.rel,c=1&t.rel;let d,h=!1;return a===l&&s===c&&(n>r&&(h=!0,d=n,n=r,r=d,d=a,a=l,l=d),i>o&&(h=!0,d=i,i=o,o=d,d=s,s=c,c=d),h&&(this.topLeft=new Sy(n,i,s|a),this.bottomRight=new Sy(r,o,c|l))),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=wy(this.sheet)+(this.endSheet?":"+wy(this.endSheet):"")+"!"+i),i}return"#REF!"}absolute(e,t){return new Ty(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 Ty(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 Ty(this.topLeft,new Sy(this.bottomRight.row,this.topLeft.col))}rightColumn(){return new Ty(new Sy(this.topLeft.row,this.bottomRight.col),this.bottomRight)}topRow(){return new Ty(this.topLeft,new Sy(this.topLeft.row,this.bottomRight.col))}bottomRow(){return new Ty(new Sy(this.bottomRight.row,this.topLeft.col),this.bottomRight)}toRangeRef(){return this}toRow(e){return e+=Math.max(0,this.topLeft.row),new Ty(new Sy(e,this.topLeft.col),new Sy(e,this.bottomRight.col)).setSheet(this.sheet,this.hasSheet())}toColumn(e){return e+=Math.max(0,this.topLeft.col),new Ty(new Sy(this.topLeft.row,e),new Sy(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 Sy(e,t,0).setSheet(this.sheet,this.hasSheet())}forEachRow(e){let t=this.topLeft.row;let n=this.bottomRight.row;let i=this.topLeft.col;let r=this.bottomRight.col;for(let o=t;o<=n;o++)e(new Ty(new Sy(o,i),new Sy(o,r)))}forEachColumn(e){let t=this.topLeft.row;let n=this.bottomRight.row;let i=this.topLeft.col;let r=this.bottomRight.col;for(let o=i;o<=r;o++)e(new Ty(new Sy(t,o),new Sy(n,o)))}intersecting(e){return e.filter((e=>e.toRangeRef().intersects(this)))}union(e,t){let n=this.intersecting(e);let i=this.topLeft.row;let r=this.topLeft.col;let o=this.bottomRight.row;let a=this.bottomRight.col;let 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 Ty(new Sy(i,r),new Sy(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);let r=this.topLeft.col+n(e.left);let o=this.bottomRight.row+n(e.bottom);let a=this.bottomRight.col+n(e.right);return r<0&&a<0||i<0&&o<0?xy:i<=o&&r<=a?new Ty(new Sy(t(i),t(r)),new Sy(t(o),t(a))):xy}move(e,t){return new Ty(new Sy(this.topLeft.row+e,this.topLeft.col+t),new Sy(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);let l=this.bottomRight.adjust(e,t,n,i,r,o,a);return s===xy&&l===xy?xy:(s===xy?(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===xy&&(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 Ty(s,l).setSheet(this.sheet,this.hasSheet()).simplify())}valid(){return this.topLeft.valid()&&this.bottomRight.valid()}}class My extends ky{constructor(e){super(),this.refs=e,this.length=e.length}clone(){return new My(this.refs.slice())}intersect(e){let t=[];for(let n=0;n<this.length;++n){let i=e.intersect(this.refs[n]);i!==xy&&t.push(i)}return t.length>0?new My(t).simplify():xy}simplify(){let e=new My(this.refs.reduce((function(e,t){return(t=t.simplify())!==xy&&e.push(t),e}),[]));return e.empty()?xy:e.single()?e.refs[0]:e}absolute(e,t){return new My(this.refs.map((function(n){return n.absolute(e,t)})))}forEach(e,t){this.refs.forEach((function(n){n instanceof My?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 My(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 My(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 My(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 Ay=new Sy(0,0);const Dy=new Ty(new Sy(0,0),new Sy(1/0,1/0));Dy.print=function(){return"#SHEET"};const Ey={};Ey.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"}},Ey.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"},Ey.workbook={defaultSheetName:"Sheet"};const Iy={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:Ey,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"};const zy={recalc:!0,selection:!0,activeCell:!0,layout:!0,sheetSelection:!0,resize:!0,editorChange:!1,editorClose:!1};const Py=46,Ly=9,By=13,Hy=38,Ry=40,Fy=33,Oy=34,Vy=121,Ny=122,$y=66,Uy=73,Wy=85,jy=78,qy=72,Gy=65,Ky=82;const Yy=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 Qy(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 Xy(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 Zy={};Zy[void 0]=e=>e;const Jy=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;function ek(e,t){const n=e+t;if(Zy[n])return Zy[n];const i=[];return e.replace(Jy,((e,t,n,r)=>{i.push(ak(t)?t:n||r)})),Zy[n]=e=>{let n=e;for(let e=0;e<i.length;e++)if(n=n[i[e]],!ak(n)&&t)return n;return n},Zy[n]}function tk(e){let t=1,n=arguments.length;for(t=1;t<n;t++)nk(e,arguments[t]);return e}function nk(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()):ck(i?.clone)?e[n]=i.clone():"object"===r&&null!==i&&dk(i)?(o=e[n],"object"==typeof o&&null!==o||(e[n]={}),nk(e[n],i)):"undefined"!==r&&(e[n]=i));return e}const ik={};const rk=function(e){if(!isNaN(ik._scrollbar)&&!e)return ik._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=" ",document.body.appendChild(n),ik._scrollbar=t=n.offsetWidth-n.scrollWidth,document.body.removeChild(n),t};const ok=function(e,t){t.parentNode.insertBefore(e,t.nextSibling)};const ak=e=>null!=e;const sk=e=>e&&e.getTime;const lk=e=>"string"==typeof e;const ck=e=>"function"==typeof e;const dk=function(e){if(!e||"[object Object]"!==toString.call(e))return!1;const t=Object.getPrototypeOf(e);return null===t||t.constructor===Object};class hk{constructor(e){if(e instanceof hk)return e;this.code=e}toString(){return"#"+this.code+("NAME"===this.code?"?":"!")}}let uk={};const pk=e=>{if(!e)return uk;uk=e};const fk=()=>pk().localeInfo();let mk={runtime:{FUNCS:Object.create(null)}};let gk=mk.runtime.FUNCS;class vk{constructor(e,t,n,i){this.callback=e,this.formula=t,this.ss=n,this.parent=i}resolve(e){var t=this;e instanceof ky?t.resolveCells([e],(function(){t._resolve(e)})):t._resolve(e)}error(e){return new hk(e)}_resolve(e){e=void 0===e?null:Array.isArray(e)?this.asMatrix(e):Ck(e);var t=this.formula;t.arrayFormulaRange?e=this.asMatrix(e)||this.asMatrix([[e]]):e instanceof Ty&&(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 ky&&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){var n=[];for(var i=0;i<e.length;++i){var r=e[i];r instanceof ky?(r=this.getRefData(r,t),n=n.concat(r)):Array.isArray(r)?n=n.concat(this.cellValues(r,t)):r instanceof bk?n=n.concat(this.cellValues(r.data,t)):n.push(r)}return n}fetchName(e,t){var n=this.formula;var i=this.ss.nameValue(e,n.sheet,n.row,n.col);if(i instanceof yk){i=i.clone(n.sheet,n.row,n.col,!0);var r=new mk.ValidationFormulaContext(this.ss.workbook);i.exec(r,t,this)}else i instanceof ky&&((i=i.absolute(n.row,n.col))instanceof Ty&&this.ss.isMerged(i)&&(i=i.topLeft),i.sheet||(i.sheet=n.sheet)),t(null==i?new hk("NAME"):i)}force(e){return e instanceof ky?this.getRefData(e):e}func(e,t,n){e=e.toLowerCase();var i=gk[e];if(i)return i.call(this,t,n);t(new hk("NAME"))}bool(e){return e instanceof ky&&(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 Ty?1==e.height()&&t.col>=e.topLeft.col&&t.col<=e.bottomRight.col?this.getRefData(new Sy(e.topLeft.row,t.col).setSheet(e.sheet)):1==e.width()&&t.row>=e.topLeft.row&&t.row<=e.bottomRight.row?this.getRefData(new Sy(t.row,e.topLeft.col).setSheet(e.sheet)):new hk("VALUE"):this.asMatrix(e)}asMatrix(e){if(e instanceof bk)return e;let t=this;if(e instanceof Ty){let n=e.topLeft;let i=n.row,r=n.col;let o=t.getRefCells(e);let a=new bk(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 bk(t),i=0;return e.forEach((function(e){let r=0;let o=1;e.forEach((function(e){let a=e instanceof Ty;e instanceof ky&&!a&&(e=t.getRefData(e)),(a||Array.isArray(e))&&(e=t.asMatrix(e)),e instanceof bk?(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 _k(e,t,n){var i=n(e),r=e;for(;++e<t;){var o=n(e);o>i&&(i=o,r=e)}return r}let bk=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];var i=n?n[t]:null;return i instanceof ky?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 hk("N/A")}set(e,t,n){if("__proto__"!==t&&"constructor"!==t&&"prototype"!==t&&"__proto__"!==e&&"constructor"!==e&&"prototype"!==e){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;var t=this.data=new Array(e);for(var n=e;--n>=0;){var i=t[n]=new Array(e);for(var r=e;--r>=0;)i[r]=n==r?1:0}return this}multiply(t){var n=this,i=new e(n.context);for(var r=0;r<n.height;++r)for(var o=0;o<t.width;++o){var a=0;for(var s=0;s<n.width;++s){var l=n.get(r,s);var c=t.get(s,o);if("number"!=typeof l||"number"!=typeof c)throw new hk("VALUE");a+=l*c}i.set(r,o,a)}return i}adds(t,n){var i=this,r=new e(i.context);var o=n?-1:1;for(var 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=this.clone().data;var t=e.length;var n,i,r,o,a=1;for(n=0;n<t;n++){for(i=n;i<t&&!e[i][n];i++);if(i==t)return 0;if(i!=n)for(a=-a,o=n;o<t;o++){var s=e[n][o];e[n][o]=e[i][o],e[i][o]=s}for(r=n+1;r<t;r++)for(o=n+1;o<t;o++)e[r][o]-=e[n][o]*e[r][n]/e[n][n];a*=e[n][n]}return a}inverse(){let t=this.width;let n=this.augment(new e(this.context).unit(t));let i=n.data;let r;for(let e=0;e<t;++e){let n=_k(e,t,(function(t){return i[t][e]}));if(!i[n][e])return null;e!=n&&(r=i[e],i[e]=i[n],i[n]=r);for(let n=e+1;n<t;++n){for(let r=e+1;r<2*t;++r)i[n][r]-=i[e][r]*i[n][e]/i[e][e];i[n][e]=0}}for(let e=0;e<t;++e)for(let n=i[e][e],r=0;r<2*t;++r)i[e][r]/=n;for(let e=t;--e>=0;)for(let n=e;--n>=0;)if(i[n][e])for(let r=2*t;--r>=t;)i[n][r]-=i[e][r]*i[n][e];return n.slice(0,t,t,t)}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){var o=new e(this.context);for(var 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 wk(e,t){if(e.constructor!==t.constructor)return!1;if(e instanceof Sy)return e.sheet==t.sheet&&e.row==t.row&&e.col==t.col&&e.rel==t.rel;if(e instanceof Ty)return wk(e.topLeft,t.topLeft)&&wk(e.bottomRight,t.bottomRight)&&e.endSheet==t.endSheet;if(e instanceof My){var n=e.refs.length;if(n!=t.refs.length)return!1;for(;--n>=0;)if(!wk(e.refs[n],t.refs[n]))return!1}return!0}let yk=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();var a=this.refs;var 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);var i=new vk(this.resolve,this,e,n);var r=0;for(;n;){if(n.formula===this)return this.pending=!1,void i.resolve(new hk("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;var a=this.col;var s=this.sheet.toLowerCase();var 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;var d=this.col;this.absrefs=null;var h=this.refs;var u=l;this.refs=h.map((function(e){var t=f(e);return u||wk(t,e)||(u=!0),t}));var p=this.arrayFormulaRange;if(p&&(this.arrayFormulaRange=f(p),u||wk(p,this.arrayFormulaRange)||(u=!0)),u)return new e(h,this.handler,this.print,this.sheet,o,a,p);function f(e){return e===xy?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 kk(e,t){var n="function arrayArgs(args) { var xargs = [], width = 0, height = 0, arrays = [], i = 0; ";var i="function resolve(args, callback) { var toResolve = [], i = 0; ";var r,o,a="'use strict'; function check(args) { var stack = [], tmp, xargs = [], i = 0, m, err = 'VALUE'; ",s=!1;var l=!1,c=!1;var d;return a+=t.map((function e(t){r=t[0];var a="{ ";if(Array.isArray(r))n+="while (i < args.length) { ",i+="while (i < args.length) { ",a+="xargs.push(tmp = []); stack.push(xargs); xargs = tmp; ",a+="while (i < args.length) { ",a+=t.map(e).join(""),a+="} ",a+="xargs = stack.pop(); ",i+="} ",n+="} ";else if("+"==r)n+="while (i < args.length) { ",i+="while (i < args.length) { ",a+="if (i >= args.length) return new CalcError('N/A'); ",a+="xargs.push(tmp = []); stack.push(xargs); xargs = tmp; ",a+="do { ",a+=t.slice(1).map(e).join(""),a+="} while (i < args.length); ",a+="xargs = stack.pop(); ",i+="} ",n+="} ";else if("?"==r)a+="if (!("+p(t[1])+")) return new CalcError(err); ";else{var s=t[1];if(Array.isArray(s)&&/^#?collect/.test(s[0])){var d=/!$/.test(s[0]);var u=s[2];h(),a+="try {var $"+r+" = this.cellValues(args.slice(i",u&&(a+=", i + "+u),a+=")"+(d?",true":"")+").reduce(function(ret, $"+r+"){ ","#"!=s[0].charAt(0)&&(a+="if ($"+r+" instanceof CalcError) throw $"+r+"; "),a+="if ("+p(s[1])+") ret.push($"+r+"); ",a+="return ret; ",a+="}.bind(this), []); ",a+=u?"i += "+u+"; ":"i = args.length; ",a+="xargs.push($"+r+")} catch(ex) { if (ex instanceof CalcError) return ex; throw ex; } ",i+="toResolve.push(args.slice(i)); "}else if("rest"==s)a+="xargs.push(args.slice(i)); i = args.length; ";else{(l=/^\*/.test(r))&&(c=!0,r=r.substr(1)),a+="var $"+r+" = args[i++]; ";var f=!1;/!$/.test(s)?(s=s.substr(0,s.length-1),f=!0):a+="if ($"+r+" instanceof CalcError) return $"+r+"; ",a+=function(e,t){o=!1;var a="if (!("+p(e)+")) { ";o&&!t&&(a+=" if ($"+r+" instanceof CalcError) return $"+r+"; ");o||(i+="i++; ");n+=l?"var $"+r+" = this._arrayArg(args[i]); if ($"+r+") { xargs.push($"+r+"); width = Math.max(width, $"+r+".width); height = Math.max(height, $"+r+".height); arrays.push(true) } else { xargs.push(args[i]); arrays.push(false); } i++; ":"xargs.push(args[i++]); arrays.push(false); ";return a+="return new CalcError(err); } "}(s,f)+"xargs.push($"+r+"); "}}return a+="} "})).join(""),a+="if (i < args.length) return new CalcError('N/A'); ",a+="return xargs; } ",n+="return { args: xargs, width: width, height: height, arrays: arrays }; } ",s?(i+="this.resolveCells(toResolve, callback); } ",d=new Function("kendo","CalcError","round",a+i+n+" return { resolve: resolve, check: check, arrayArgs: arrayArgs };")):d=new Function("kendo","CalcError","round",a+" return { check: check };"),d=d(mk.kendo,hk,xk),c||delete d.arrayArgs,d;function h(){return o?"$"+r:(s=!0,o=!0,i+="toResolve.push(args[i++]); ","($"+r+" = this.force($"+r+"))")}function u(e){return"("+(e?"(typeof "+h()+" == 'number' ? ($"+r+" = round($"+r+"), true) : false) || ":"(typeof "+h()+" == 'number') || ")+"(typeof $"+r+" == 'boolean' ? ($"+r+" = +$"+r+", true) : false) || (typeof $"+r+" == 'string' && !/^(?:=|true|false)/i.test($"+r+") ? (tmp = kendo.spreadsheet.calc.parse(0, 0, 0, $"+r+"), /^date|number|percent$/.test(tmp.type) ? ($"+r+" = +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 h()+" === "+e})).join(") || (")+")";if("null"==e[0])return"("+p("null")+" ? (($"+r+" = "+e[1]+"), true) : false)";if("between"==e[0]||"[between]"==e[0])return"("+h()+" >= "+e[1]+" && $"+r+" <= "+e[2]+" ? true : ((err = 'NUM'), false))";if("(between)"==e[0])return"("+h()+" > "+e[1]+" && $"+r+" < "+e[2]+" ? true : ((err = 'NUM'), false))";if("(between]"==e[0])return"("+h()+" > "+e[1]+" && $"+r+" <= "+e[2]+" ? true : ((err = 'NUM'), false))";if("[between)"==e[0])return"("+h()+" >= "+e[1]+" && $"+r+" < "+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 u(!0);if("number!"==e)return"(typeof "+h()+" == 'number' ? ($"+r+" = round($"+r+"), true) : false)";if("integer"==e||"date"==e)return"("+u()+" && (($"+r+" |= 0), true))";if("divisor"==e)return"("+u(!0)+" && ($"+r+" == 0 ? ((err = 'DIV/0'), false) : true))";if("number+"==e)return"("+u(!0)+" && ($"+r+" >= 0 ? true : ((err = 'NUM'), false)))";if("integer+"==e)return"("+u()+" && (($"+r+" |= 0) >= 0 ? true : ((err = 'NUM'), false)))";if("number++"==e)return"("+u(!0)+" && ($"+r+" > 0 ? true : ((err = 'NUM'), false)))";if("integer++"==e)return"("+u()+" && (($"+r+" |= 0) > 0 ? true : ((err = 'NUM'), false)))";if("string"==e)return"((typeof "+h()+" == 'string' || typeof $"+r+" == 'boolean' || typeof $"+r+" == 'number') ? ($"+r+" += '', true) : ($"+r+" === undefined ? (($"+r+" = ''), true) : false))";if("boolean"==e)return"(typeof "+h()+" == 'boolean')";if("logical"==e)return"(typeof "+h()+" == 'boolean' || (typeof $"+r+" == 'number' ? ($"+r+" = !!$"+r+", true) : false))";if("matrix"==e)return h(),"((m = this.asMatrix($"+r+")) ? ($"+r+" = m) : false)";if("#matrix"==e)return"((m = this.asMatrix($"+r+")) ? ($"+r+" = m) : false)";if("ref"==e)return"($"+r+" instanceof kendo.spreadsheet.Ref)";if("area"==e)return"($"+r+" instanceof kendo.spreadsheet.CellRef || $"+r+" instanceof kendo.spreadsheet.RangeRef)";if("cell"==e)return"($"+r+" instanceof kendo.spreadsheet.CellRef)";if("null"==e)return"("+h()+" == null)";if("anyvalue"==e)return"("+h()+" != null && i <= args.length)";if("forced"==e)return"("+h()+", i <= args.length)";if("anything"==e)return"(i <= args.length)";if("blank"==e)return"("+h()+" == null || $"+r+" === '')";throw new Error("Can't check for type: "+e)}}function xk(e,t){return e===parseInt(e,10)?e:+e.toPrecision(t||16)}function Ck(e,t){return"number"==typeof e?xk(e,t):e}function Sk(e,t,n){if(n instanceof hk)return n;try{return t.apply(e,n)}catch(e){if(e instanceof hk)return e;throw e}}function Tk(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 bk(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,Sk(this,e,s))}return r(i)}}let t=n.call(this,o);r(Sk(this,e,t))}t?t.call(this,o,a):a.call(this)}}function Mk(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 bk(this);let a=t.width*t.height;let 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 hk){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 hk?r(t):(t.unshift(r),e.apply(this,t))}t?t.call(this,o,a):a.call(this)}}function Ak(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}gk.if=function(e,t){var n=this;var 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);var a=n.asMatrix(r);e(t.map((function(e,t,s){return e instanceof hk?e:n.bool(e)?o?o.get(t,s):i:a?a.get(t,s):r})))}))})):(i=this.force(i))instanceof hk?e(i):n.bool(i)?r(e):o(e)}))},gk["φ"]=function(e){e((1+Math.sqrt(5))/2)};var Dk=Ak(1900,0,-1);var Ek=[31,28,31,30,31,30,31,31,30,31,30,31];var Ik=[[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 zk(e){return e%4?0:e%100?1:e%400?0:1}function Pk(e,t){return zk(e)&&1==t?29:Ek[t]}function Lk(e){return n=(t=(0|e)+Dk)+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:Ik[zk(l)][a]+s};var t,n,i,r,o,a,s,l}function Bk(e,t,n){return Ak(e,t,n)-Dk}var Hk=6e4;var Rk=36e5;function Fk(e){var t=e-(0|e);t<0&&t++;var n=Math.round(864e5*t);var i=Math.floor(n/Rk);n-=i*Rk;var r=Math.floor(n/Hk);n-=r*Hk;var o=Math.floor(n/1e3);return{hours:i,minutes:r,seconds:o,milliseconds:n-=1e3*o}}function Ok(e,t,n,i){return(e+(t+(n+i/1e3)/60)/60)/24}class Vk{constructor(e,t){this.message=e,this.pos=t}toString(){return this.message}}function Nk(){this.node=null}function $k(){}mk.runtime.CalcError=hk,mk.runtime.Formula=yk,mk.runtime.Matrix=bk,mk.runtime.packDate=Bk,mk.runtime.unpackDate=Lk,mk.runtime.packTime=Ok,mk.runtime.unpackTime=Fk,mk.runtime.serialToDate=function(e){var t=Lk(e),n=Fk(e);return new Date(t.year,t.month,t.date,n.hours,n.minutes,n.seconds,n.milliseconds)},mk.runtime.dateToSerial=function(e){var t=Ok(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());return(e=Bk(e.getFullYear(),e.getMonth(),e.getDate()))<0?e-1+t:e+t},mk.runtime.daysInMonth=Pk,mk.runtime.validDate=function(e,t,n){return t>=1&&t<=12&&n>=1&&n<=Pk(e,t-1)},mk.runtime.isLeapYear=zk,mk.runtime.daysInYear=function(e){return zk(e)?366:365},mk.runtime.parseDate=function(e,t){t&&(t=mk.formatting.makeDateFormat(t));const n=pk().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"])},mk.runtime.limitPrecision=xk,mk.runtime.defineBuiltinFunction=function(e,t,n,i){gk[e]=t?Mk(i,n.resolve,n.check,n.arrayArgs):Tk(i,n.resolve,n.check,n.arrayArgs)},mk.runtime.defineAlias=function(e,t){var n=gk[t];if(!n)throw new Error("Function "+t+" is not yet defined");n.kendoSpreadsheetAliases||(n.kendoSpreadsheetAliases=[t]),n.kendoSpreadsheetAliases.push(e),gk[e]=n},mk.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 Vk(n+" (input: "+e+")",t)}function a(e){for(;e-- >0;)n()}},mk.runtime.ParseError=Vk,Nk.prototype={remove:function(){this.node.parentNode&&this.node.parentNode.removeChild(this.node),this.attr={}},attr:{},text:function(){return""}},$k.prototype={nodeName:"#null",attr:{style:{}},children:[],remove:function(){}};let Uk=new $k;function Wk(e,t,n){this.nodeName=e,this.attr=t||{},this.children=n||[]}function jk(e){this.nodeValue=String(e)}function qk(e){this.html=e}function Gk(e){return new qk(e)}function Kk(e,t,n){return new Wk(e,t,n)}function Yk(e){return new jk(e)}function Qk(e){this.root=e,this.children=[]}Wk.prototype=new Nk,Wk.prototype.appendTo=function(e){let t="string"==typeof this.nodeName?document.createElement(this.nodeName):this.nodeName;let n=this.children;for(let e=0;e<n.length;e++)n[e].render(t,Uk);return e.appendChild(t),t},Wk.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;let o=r.length;let a=t.children;let s=a.length;if(Math.abs(s-o)>2)return void this.render({appendChild:function(n){e.replaceChild(n,t.node)}},Uk);for(i=0;i<o;i++)r[i].render(n,a[i]||Uk);for(i=o;i<s;i++)a[i].remove()}this.node=n,this.syncAttributes(t.attr),this.removeAttributes(t.attr)},Wk.prototype.syncAttributes=function(e){let t=this.attr;for(let n in t){let i=t[n];let r=e[n];"style"===n?this.setStyle(i,r):i!==r&&this.setAttribute(n,i,r)}},Wk.prototype.setStyle=function(e,t){let n=this.node;let i;if(t)for(i in e)e[i]!==t[i]&&(n.style[i]=e[i]);else for(i in e)n.style[i]=e[i]},Wk.prototype.removeStyle=function(e){let t=this.attr.style||{};let n=this.node;for(let i in e)void 0===t[i]&&(n.style[i]="")},Wk.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)},Wk.prototype.removeAttribute=function(e){let t=this.node;"style"===e?t.style.cssText="":"className"===e?t.className="":t.removeAttribute(e)},Wk.prototype.setAttribute=function(e,t){let n=this.node;void 0!==n[e]?n[e]=t:n.setAttribute(e,t)},Wk.prototype.text=function(){let e="";for(let t=0;t<this.children.length;++t)e+=this.children[t].text();return e},jk.prototype=new Nk,jk.prototype.nodeName="#text",jk.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},jk.prototype.text=function(){return this.nodeValue},qk.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)}},Qk.prototype={html:Gk,element:Kk,text:Yk,render:function(e){let t=this.children;let n;let i;for(n=0,i=e.length;n<i;n++){let i=t[n];i?i.node&&i.node.parentNode||(i.remove(),i=Uk):i=Uk,e[n].render(this.root,i)}for(n=i;n<t.length;n++)t[n].remove();this.children=e}};const Xk={html:Gk,text:Yk,element:Kk,Tree:Qk,Node:Nk};let Zk=/^\[(black|green|white|blue|magenta|yellow|cyan|red)\]/i;let Jk=/^\[(<=|>=|<>|<|>|=)(-?[0-9.]+)\]/;function ex(e){e=mk.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(Zk);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(Jk);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 tx={unpackDate:mk.runtime.unpackDate,unpackTime:mk.runtime.unpackTime,date:function(e,t,n,i){switch(n){case"d":switch(i){case 1:return t.date;case 2:return ax(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 ax(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=ax(i?e.hours%12||12:e.hours,n,"0"),r&&(a=(e.minutes+(e.seconds+e.milliseconds/1e3)/60)/60);break;case"m":o=ax(e.minutes,n,"0"),r&&(a=(e.seconds+e.milliseconds/1e3)/60);break;case"s":o=ax(e.seconds,n,"0"),r&&(a=e.milliseconds/1e3)}return a&&(o+=tx.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=ax(0|r,n,"0"),o&&(r+=tx.toFixed(o,i).replace(/^0+/,"")),r},fill:function(e){return e},formatInt:function(e,t,n,i,r){t=tx.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=!1;let s=t.length-1;let l=[];let c,d=0;function h(t,n){r&&d&&d%3==0&&/^[0-9]$/.test(t)&&(c=e.numbers.symbols.group+c),n&&"-"===t&&(a=!0,t="0"),c=t+c,d++}for(let e=n.length;--e>=0;){let i=n[e];c="";for(let e=i.length;--e>=0;){let n=i.charAt(e);s<0?"0"==n?h("0"):"?"==n&&h(" "):("0"==t&&"?"==n?h(" "):"0"==n?h(t.charAt(s),!0):h(t.charAt(s)),s--)}if(0===e)for(;s>=0;)h(t.charAt(s--));l.unshift(c)}return a&&(l[0]="-"+l[0]),l},formatDec:function(e,t,n){let i=(e=tx.toFixed(e,n)).indexOf(".");e=i>=0?e.substr(i+1).replace(/0+$/,""):"";let r=0;let o=[];for(let n=0;n<t.length;++n){let i=t[n];let 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=String(e).toLowerCase();let n,i,r;let o=t.indexOf(".");o<0?(o=t.indexOf("e"),o<0?(n=t,i=""):(n=t.substr(0,o),i=t.substr(o))):(n=t.substr(0,o),i=t.substr(o+1));if(r=/(\d*)e([-+]?\d+)/.exec(i)){let e=parseInt(r[2],10);e>=0?(i=function(e,t,n){e+="";for(;e.length<t;)e+=n;return e}(r[1],e,"0"),n+=i.substr(0,e),i=i.substr(e)):(n=ax(n,-e,"0"),i=n.substr(e)+r[1],n=n.substr(0,n.length+e))}return{intpart:n||"0",decpart:i}}(n);let o=r.intpart;let 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 nx(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);let n=!1;let i=!1;let r=!1;let o=0;let a=/[\$\xA2-\xA5\u058F\u060B\u09F2\u09F3\u09FB\u0AF1\u0BF9\u0E3F\u17DB\u20A0-\u20BD\uA838\uFDFC\uFE69\uFF04\uFFE0\uFFE1\uFFE5\uFFE6]/;let s=0;let l=!1;let c=0;let d=[],h=[];let u=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,h.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,w;if("text"===u){if(!("string"==typeof f||f instanceof hk))return!1}else if("num"===u){if("number"!=typeof f)return!1}else if(u){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)}`)}(u,f,u.value))return!1;u.custom||(f=Math.abs(f))}if((o>0||s>0||d.length||h.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=tx.formatInt(m,f,d,c,l),_=parseInt(g[0])<0),h.length&&(v=tx.formatDec(f,h,c)),(d.length||h.length)&&(p.type="number"),n&&(b=tx.unpackDate(f)),i&&(w=tx.unpackTime(f)),(n||i)&&(p.type="date");let y=!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+="-",y=!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+=tx.fill(e.value):"digit"===e.type?(_&&g[0]&&y&&(g[0]=g[0].replace("-","")),k+=e.decimal?v.shift():g.shift()):"date"===e.type?k+=tx.date(m,b,e.part,e.format):"time"===e.type?k+=tx.time(w,e.part,e.format,r,e.fraction):"eltime"===e.type?k+=tx.eltime(f,e.part,e.format,e.fraction):"ampm"===e.type&&(k+=w.hours<12?e.am:e.pm):k+=","}return k&&p.body.push(k),!0}}let ix=nx({cond:"text",body:[{type:"text"}]});let rx=Qy((function(e){let t=ex(e).map(nx);return t.push(ix),function(e,n=fk()){let i={body:[]};for(let r=0;r<t.length&&!t[r](i,e,n);++r);return i}}));let ox=Qy((function(e){let t=ex(e);let n,i=!1,r=!1;for(let e=0;e<t.length;++e){n=t[e];for(let e=0;e<n.body.length;++e)/^(?:date|time|ampm)$/.test(n.body[e].type)&&(i=!0,"ampm"===n.body[e].type&&(r=!0));if(i)break}return i?n.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+=ax("",Math.max(t.fraction,3),"f"));return e}(ax("",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 ax(e,t,n){for(e+="";e.length<t;)e=n+e;return e}function sx(e){let t=e.body;let 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 lx={compile:rx,parse:ex,format:function(e,t,n){let i=rx(t)(e,n);let r=Xk.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(Xk.text(t)):"space"===t.type&&r.children.push(Xk.element("span",{style:{visibility:"hidden"}},[Xk.text(t.value)]))}return r},text:function(e,t,n){return sx(rx(t)(e,n))},textAndColor:function(e,t,n){let i=rx(t)(e,n);return{text:sx(i),color:i.color,type:i.type}},type:function(e,t,n){return rx(t)(e,n).type},adjustDecimals:function(e,t){let n=ex(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+=ax("",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:ax("",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+="."+ax("",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(ax("",e.format,e.part),e):"eltime"===e.type?t("["+ax("",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:ox};const cx=function(e,t,n,i,r){const o={};return o.spreadsheet={calc:e,CalcError:t,Ref:n,CellRef:i,RangeRef:r},o.culture=()=>fk(),o}(mk,hk,ky,Sy,Ty);mk.kendo=cx,mk.formatting=lx;let dx=Object.create(null);let hx=Object.create(null);var ux;(ux=[[":"],[" "],[","],["%"],["^"],["*","/"],["+","-"],["&"],["=","<",">","<=",">=","<>"]]).forEach((function(e,t){e.forEach((function(e){dx[e]=ux.length-t,hx[","===e?";":e]=ux.length-t}))}));let px=dx;let fx={DEC:".",ARG:",",COL:","};function mx(e){fx.DEC=e,fx.ARG=","===e?";":",",fx.COL=","===e?"\\":",",px=","===e?hx:dx}mk.withDecimalSeparator=function(e,t){if(fx.DEC===e)return t();let n=fx.DEC;mx(e);try{return t()}finally{mx(n)}},mk._separators=fx;let gx={type:"bool",value:!0};let vx={type:"bool",value:!1};function _x(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 bx(e){return parseInt(e,10)-1}function wx(e,t,n,i){let r=[];let o=(i=Ex(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 h(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",fx.ARG))t.push({type:"null"}),i.next();else{if(t.push(l(!1)),i.eof()||o("punc",")"))break;s("op",fx.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,fx.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?gx:vx:a(new Cy(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 h(e,t,n){let r=o("op");if(r&&(n||r.value!==fx.ARG)){let o=px[r.value];if(o>t){i.next();let a=h(c(),o,n);return h({type:"binary",op:";"===r.value?",":r.value,left:e,right:a},t,n)}}return e}}function yx(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"."==mk._separators.DEC?JSON.stringify(a.value):JSON.stringify(a.value).replace(".",mk._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,px[a.op])));case"postfix":return c((()=>e(a.exp,a,px[a.op])+a.op));case"binary":return c((()=>{let t=o(e(a.left,a,px[a.op]),a.left instanceof Cy&&":"===a.op);let n=o(e(a.right,a,px[a.op]),a.right instanceof Cy&&":"===a.op);return/^[,;]/.test(a.op)?t+mk._separators.ARG+n:t+a.op+n}));case"func":return a.func+"("+a.args.map((t=>e(t,a,0))).join(mk._separators.ARG+" ")+")";case"matrix":return"{ "+a.value.map((t=>t.map((t=>e(t,a,0))).join(mk._separators.COL))).join("; ")+" }";case"null":return""}throw new Error("Cannot print node "+a.type);function c(e){let t=a.op;let n=px[t]<l||!l&&","===t||"prefix"===s.type&&l===px[t]&&"-"===s.op||"binary"===s.type&&l===px[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 kx(e,t,n){return 0===t.length?n(!0):1===t.length?Tx(e,t[0],(t=>n(e.bool(t)))):Tx(e,t[0],(i=>e.bool(i)?kx(e,t.slice(1),n):n(!1)))}function xx(e,t,n){return 0===t.length?n(!1):1===t.length?Tx(e,t[0],(t=>n(e.bool(t)))):Tx(e,t[0],(i=>e.bool(i)?n(!0):xx(e,t.slice(1),n)))}function Cx(e,t,n){switch(t.func.toLowerCase()){case"if":return function(e,t,n,i,r){return Tx(e,t,(t=>e.func("if",r,[t,t=>Tx(e,n,t),t=>Tx(e,i,t)])))}(e,t.args[0],t.args[1]||gx,t.args[2]||vx,n);case"and":return kx(e,t.args,n);case"or":return xx(e,t.args,n);case"true":return n(!0);case"false":return n(!1)}return Sx(e,t.args,0,(i=>e.func(t.func,n,i)))}function Sx(e,t,n,i,r=[]){return n===t.length?i(r):Tx(e,t[n],(o=>(r[n]=o,Sx(e,t,n+1,i,r))))}function Tx(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 Tx(e,t.exp,(i=>e.func("unary"+t.op,n,[i])))}(e,t,n);case"binary":return function(e,t,n){return Tx(e,t.left,(i=>Tx(e,t.right,(r=>e.func("binary"+t.op,n,[i,r])))))}(e,t,n);case"func":return Cx(e,t,n);case"matrix":return function(e,{value:t},n){let i=[];return function r(o){return o===t.length?n(i):Sx(e,t[o],0,(e=>(i[o]=e,r(o+1))))}(0)}(e,t,n)}throw new Error("Cannot evaluate "+t.type)}let Mx=Object.create(null);function Ax(e){let t=yx(e);let n=t.call(e);let i=Mx[n];return i?i.clone(e.sheet,e.row,e.col):(i=new mk.runtime.Formula(e.refs,function({ast:e}){return function(){return Tx(this,e,(e=>this.resolve(e)))}}(e),t,e.sheet,e.row,e.col),Mx[n]=i.clone(e.sheet,e.row,e.col),i)}function Dx(e){return e}function Ex(e,t){e=function(e,t){let n=[],i=0;let r=e.readWhile;return{next:w,peek:b,eof:x,croak:e.croak,ahead:y,skip:k};function o(e){return/[0-9]/i.test(e)}function a(e){return/[a-z$_]/i.test(e)||function(e){return Yy.test(e)}(e)}function s(e){return a(e)||o(e)||"."===e}function l(e){return e in px}function c(e){return"\\!;(){}[]".indexOf(e)>=0}function d(){let e=!1;let t=r((function(t){return t===fx.DEC?!e&&(e=!0,!0):o(t)}));return t===fx.DEC?{type:"punc",value:fx.DEC}:{type:"num",value:parseFloat(t.replace(fx.DEC,"."))}}function h(t,n){return{type:"sym",value:t,upper:t.toUpperCase(),space:Ix(e.peek()),quote:n}}function u(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=u(t[1],t[2],t[3]);let i=u(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 h(r(s))}function f(){return e.next(),{type:"str",value:e.readEscaped('"')}}function m(){return e.next(),h(e.readEscaped("'"),!0)}function g(){return{type:"op",value:r((function(e,t){return t+e in px}))}}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===fx.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(Ix);let i=e.pos();let o=_();t.forEditor&&o&&(o.begin=i,o.end=e.pos()),n.push(o)}return n[i]}function w(){let e=b();return e&&i++,e}function y(e,t){let n=i,r=[];for(;e-- >0;)r.push(w()||zx);return i=n,t.apply(r,r)}function k(e){i+=e}function x(){return null==b()}}(mk.runtime.InputStream(e),t);let n=e.ahead;let i=e.skip;let r=null;let 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}:Dx;let a=t.forEditor?function(e,t,n){return e.begin=t.begin,e.end=n.end,e}:Dx;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;let i=e.peek();return i&&("sym"!==i.type&&"rc"!==i.type&&"num"!==i.type||(t=n(8,d)||n(6,h)||n(6,u)||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 Sy(n.row,n.col,n.rel);if("num"===n.type)return n.value<=1048577?o(new Sy(bx(n.value),i?-1/0:1/0,2)):null;let r=n.value;let a=/^(\$)?([a-z]+)(\$)?(\d+)$/i.exec(r);if(a){let e=bx(a[4]),t=_x(a[2]);return e<=1048576&&t<=16383?o(new Sy(bx(a[4]),_x(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(bx(r)<=1048576)return o(new Sy(bx(r),i?-1/0:1/0,s?0:2))}else{if(_x(r)<=16383)return o(new Sy(i?-1/0:1/0,_x(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 Ty(t.setSheet(e.value,!0),r.setSheet(n.value,!0)).setSheet(e.value,!0),e,l)}}function h(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 Ty(t.setSheet(e.value,!0),r.setSheet(n.value,!0)).setSheet(e.value,!0),e,o)}}}function u(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 Ty(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 Cy(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 Ty(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 Ix(e){return" \t\r\n ".indexOf(e)>=0}let zx={type:"eof"};let Px=[];let Lx=mk.registerFormatParser=function(e){Px.push(e)};mk.parse=function(e,t,n,i,r){if(i instanceof Date)return{type:"date",value:mk.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);let 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)?wx(e,t,n,i):{type:"string",value:"="+i};for(let e=0;e<Px.length;++e){let t=Px[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=mk.runtime.parseDate(i,r);if(o)return{type:"date",value:mk.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}},mk.parseNameDefinition=function(e,t){let n=wx(null,0,0,e);if(!(n.ast instanceof Cy))throw new mk.runtime.ParseError("Invalid name: "+e);if(n=n.ast,!(t instanceof ky)){let e=wx(n.sheet,0,0,t);t=e.ast instanceof ky?e.ast:/^(?:str|num|bool|error)$/.test(e.ast.type)?e.ast.value:Ax(e)}return{name:n,value:t}},mk.parseFormula=wx,mk.parseReference=function(e,t){if("#sheet"===e.toLowerCase())return Dy;e:{let t;if(t=/^(\$)?([a-z]+)(\$)?(\d+)$/i.exec(e)){let e=bx(t[4]),n=_x(t[2]);if(e<1048576&&n<16384)return new Sy(bx(t[4]),_x(t[2]));break e}let n=Ex(e,{});let i=[];for(;;){let e=n.next();if(e instanceof Sy)e.rel=0;else{if(!(e instanceof Ty))break e;e.topLeft.rel=0,e.bottomRight.rel=0}if(i.push(e),n.eof())break;if(!n.is("op",fx.ARG))break e;n.next()}return 1===i.length?i[0]:new My(i)}if(!t)throw new Error("Cannot parse reference: "+e)},mk.compile=Ax,mk.parseSqref=function(e,t,n){e=Ex(e,{row:t=t||0,col:n=n||0});let i=[];for(;!e.eof();){let r=e.next();if("ref"!==r.type)throw new mk.runtime.ParseError("Expecting a reference but got: "+JSON.stringify(r));i.push(r.absolute(t,n))}return i},mk.tokenize=function(e,t,n){let i=[];for(e=Ex(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}},Lx((function(e,t){let n,i=0,r="";if(t||(t=fk().calendar.patterns.d),n=/^(\d+)([-/.])(\d+)\2(\d{2}(?:\d{2})?)(\s*)/.exec(e)){let o=parseInt(n[1],10);let a=n[2];let s=parseInt(n[3],10);let 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(!mk.runtime.validDate(l,o,s))return null;i=mk.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);let t=parseInt(n[2],10);return{type:"date",format:r+"hh:mm",value:i+mk.runtime.packTime(e,t,0,0)}}if(n=/^(\d+):(\d+)(\.\d+)$/.exec(e)){let e=parseInt(n[1],10);let t=parseInt(n[2],10);let o=1e3*parseFloat(n[3]);return{type:"date",format:r+"mm:ss.00",value:i+mk.runtime.packTime(0,e,t,o)}}if(n=/^(\d+):(\d+):(\d+)$/.exec(e)){let e=parseInt(n[1],10);let t=parseInt(n[2],10);let o=parseInt(n[3],10);return{type:"date",format:r+"hh:mm:ss",value:i+mk.runtime.packTime(e,t,o,0)}}if(n=/^(\d+):(\d+):(\d+)(\.\d+)$/.exec(e)){let e=parseInt(n[1],10);let t=parseInt(n[2],10);let o=parseInt(n[3],10);let a=1e3*parseFloat(n[4]);return{type:"date",format:r+"hh:mm:ss.00",value:i+mk.runtime.packTime(e,t,o,a)}}})),Lx((function(e){let t,n;const i=pk();var r=i.localeInfo().numbers;let o=r.symbols.group;let a=r.symbols.decimal;let s=r.localeCurrency;!s&&i.localeCurrency&&(s=i.localeCurrency());let l=r.currencies[s].symbol;let c=function(e,t){let n=e+t;let i=Bx[n];i||(i="^(\\d+(COM\\d{3})*(DOT\\d+)?)",i=i.replace(/DOT/g,"\\"+t).replace(/COM/g,"\\"+e),i=new RegExp(i),Bx[n]=i);return i}(o,a);let d=new RegExp("^\\s*\\"+l+"\\s*");let h=1;let u="";let p="";let f=!1;let m=!1;if((e=mk.runtime.InputStream(e.replace(/^\s+|\s+$/g,""))).skip(/^-\s*/)&&(h=-1),(t=e.skip(d))&&(f=!0,u+='"'+t[0]+'"'),e.skip(/^-\s*/)){if(h<0)return null;h=-1}if(!(n=e.skip(c)))return null;if(u+="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)&&(u=u.replace("0","#"),u+=",0"),n[3]&&(u+="."+Hx("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),u+=p,f&&(u+=";-"+u),{type:"number",currency:f,format:u,value:h*g}})),Lx((function(e){let t;if(t=/^([0-9]*)\.([0-9]+)(\s*%)$/.exec(e))return{type:"number",value:parseFloat(e)/100,format:"0."+Hx("0",t[2].length)+t[3]}}));let Bx={};function Hx(e,t){let n="";for(;t-- >0;)n+=e;return n}class Rx{constructor(e){this.workbook=e}getRefCells(e,t,n,i,r,o){let a,s,l,c;if(e instanceof Sy)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 hk("REF")}];if(e instanceof Ty){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 hk("REF")}];for(;c<=i;){a=this.workbook.sheetByIndex(c++);let i=a._grid.normalize(e.topLeft);let r=a._grid.normalize(e.bottomRight);let d=a._grid.cellRefIndex(i);let h=a._grid.cellRefIndex(r);let u=a._properties.iterator("value",d,h);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=u.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 My){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 Cy){let o=this.nameValue(e,n,i,r);return o instanceof ky?this.getRefCells(o,t,n,i,r):[{value:null==o?new hk("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 ky&&(r=r.absolute(n,i)),r}getData(e,t,n,i,r){let o=e instanceof Sy;e instanceof Cy&&(o=this.workbook.nameValue(e.name)instanceof Sy);let a=this.getRefCells(e,!1,t,n,i,r).map((function(e){let t=e.value;return t instanceof mk.runtime.Formula&&(t=t.value),t}));return o?a[0]:a}onFormula(e){let t=this.workbook.sheetByName(e.sheet);let 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;let i=r.width;let a=r.height;t.forEach(o,(function(o,s){void 0===e&&(e=o,n=s);let l=o-e;let c=s-n;let d;d=l<a&&c<i?r.get(l,c):new hk("N/A"),t._value(o,s,d)}))}else r instanceof ky&&(r=this.getData(r,e.sheet,n,i),Array.isArray(r)&&(r=r[0]),void 0===r&&(r=null)),r instanceof mk.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 Fx extends Rx{onFormula(){return!0}}mk.ValidationFormulaContext=Fx;let Ox={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 Vx{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;let n=Ox[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;let 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 Nx=/:alphanum$/;let $x={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"};let Ux={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"};let Wx={wheel:"onWheel","*+mousedown":"onMouseDown",contextmenu:"onContextMenu","*+mousedrag":"onMouseDrag","*+mouseup":"onMouseUp","*+dblclick":"onDblClick",mousemove:"onMouseMove"};let jx={pageup:"onPageUp",pagedown:"onPageDown",mouseup:"onMouseUp","*+cut":"onCut","*+paste":"onPaste","*+copy":"onCopy"};let qx={esc:"onEditorEsc",enter:"onEditorBlur","alt+enter":"insertNewline","shift+enter":"onEditorBlur",tab:"onEditorBlur","shift+tab":"onEditorBlur","shift+ctrl+enter":"onEditorArrayFormula"};let Gx=Object.assign({focus:"onEditorBarFocus"},qx);let Kx=Object.assign({focus:"onEditorCellFocus"},qx);let Yx={cell:"range",rowheader:"row",columnheader:"column",topcorner:"sheet",autofill:"autofill"};let Qx=[];let Xx=[];let Zx=[];for(let e in $x)Qx.push(e),Xx.push("shift+"+e);for(let e in Ux)Zx.push(e);jx[Qx]="onAction",jx[Xx]="onShiftAction",jx[Zx]="onEntryAction",Kx[Qx]="onEditorAction",Kx[Xx]="onEditorShiftAction";class Jx{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 Vx(this.container,this,Wx),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 Vx(this.clipboardElement,this,jx),this.barKeyListener=new Vx(this.editor.barElement(),this,Gx),this.inputKeyListener=new Vx(this.editor.cellElement(),this,Kx)):(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;let 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;let n=t.sheetByIndex(e.oldIndex);let i=t.activeSheet();let 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({preventScroll:!0}))}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;let 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();let 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;let 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($x[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();let 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(Nx.test(t)||!r){if(n._activeDrawing=null,i)return void e.preventDefault();r&&this.editor.value(""),this.activateEditor(r)}else this.navigator.navigateInSelection(Ux[t]),e.preventDefault()}}onShiftAction(e,t){this.navigator.modifySelection($x[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=Yx[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);let i=t.getAttribute("data-direction");let r=this._workbook.activeSheet();let 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,Yx[n.type]):"drawing"==n.type&&this.navigator.selectDrawingForContextMenu(n.drawing);let i=this.navigator._sheet.select()instanceof My;let r=!1;let 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();let n=t.draggingInProgress();if(!n)return!1;let i=this.translateCoords(e);let r=n.drawing;let o=i.x-n.startX;let 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};let 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);let 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;let 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;let n="";let 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;let 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;let t=this._autoScrollTarget.y;let n=this.originFrame._grid;let i=this.view.scroller;let r=i.scrollLeft;let 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);let n=this._workbook.activeSheet().filterColumn(t.ref);let 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();let 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({preventScroll:!0})}insertNewline(e){e.preventDefault(),this.editor.insertNewline()}onEditorBlur(e,t){e.defaultPrevented||this.editor.isFiltered()||(e.preventDefault(),this._preventNavigation=!1,this.editor.deactivate(),this._preventNavigation||(this.clipboardElement.focus({preventScroll:!0}),this.navigator.navigateInSelection(Ux[t])),"tab"===t&&e.preventDefault())}onEditorAction(e,t){if(e.defaultPrevented)return;let n=this.editor;let i=this._workbook.activeSheet();this._casualEditing&&/^(?:up|right|down|left)$/.test(t)?(this.deactivateEditor(),this.navigator.moveActiveCell($x[t]),e.preventDefault()):n.canInsertRef(!0)&&(this.navigator.moveActiveCell($x[t]),n.activeEditor().refAtPoint(i),i._setFormulaSelections(n.highlightedRefs()),e.preventDefault())}onEditorShiftAction(e,t){let n=this.editor;let i=this._workbook.activeSheet();n.canInsertRef(!0)&&(this.navigator.modifySelection($x[t.replace("shift+","")],this.appendSelection),n.activeEditor().refAtPoint(i),i._setFormulaSelections(n.highlightedRefs()),e.preventDefault())}resetEditorValue(){let e=this._workbook.activeSheet();let t=e.activeCell();let n=this._workbook._inputForRef(t);let 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?tk(e.options,t):e.options=t,this.view.openDialog(e.name,e.options)}onNameEditorEnter({value:e}){let t;let n=this._workbook;let i=n.activeSheet();let r=void 0!==e?e:this.view.nameEditor.value();if(t=mk.parseReference(r,!0)||n.nameValue(r),t instanceof ky){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({preventScroll:!0})}onNameEditorCancel(){this.clipboardElement.focus({preventScroll:!0})}onNameEditorSelect(e){let t=e.name;let n=this._workbook;let i=n.activeSheet();let r=n.nameValue(t);if(r instanceof ky){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({preventScroll:!0})}onNameEditorDelete(e){this._execute({command:"DeleteNameCommand",options:{name:e.name}}),this.clipboardElement.focus({preventScroll:!0})}}class eC{constructor(e,t,n,i){this.level=e,this.value=t,this.left=n,this.right=i}}const tC={left:void 0,right:void 0,level:0};function nC(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 iC(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 rC(e,t){return e===tC?new eC(1,t,tC,tC):(e.value.start>t.start?e.left=rC(e.left,t):e.right=rC(e.right,t),iC(nC(e)))}function oC(e,t){let n=e;if(n===tC)return n;let i=n.value.start-t.start;if(0===i)if(n.left!==tC&&n.right!==tC){let e=n.left;for(;e.right!==tC;)e=e.right;n.value=e.value,n.left=oC(n.left,n.value)}else n=n.left===tC?n.right:n.left;else i>0?n.left=oC(n.left,t):n.right=oC(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=nC(n),n.right=nC(n.right),n.right.right=nC(n.right.right),n=iC(n),n.right=iC(n.right)),n}tC.left=tC,tC.right=tC;class aC{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 aC(this.start,this.end,this.value)}}class sC{constructor(){this.root=tC}insert(e){this.root=rC(this.root,e)}remove(e){this.root=oC(this.root,e)}findrange(e){let t=this.root;for(;t!==tC;)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 lC(this.root,e),e}intersecting(e,t){let n=[];return cC(this.root,new aC(e,t),n),n}map(e){let t=new sC;return dC(t,this.root,e),t}forEach(e){hC(this.root,e)}clone(){return this.map((function(e){return e.clone()}))}first(){let e=this.root;for(;e.left!==tC;)e=e.left;return e}last(){let e=this.root;for(;e.right!==tC;)e=e.right;return e}}function lC(e,t){e!==tC&&(lC(e.left,t),t.push(e.value),lC(e.right,t))}function cC(e,t,n){if(e===tC)return;let i=e.value;t.start<i.start&&cC(e.left,t,n),i.intersects(t)&&n.push(i),t.end>i.end&&cC(e.right,t,n)}function dC(e,t,n){t!==tC&&(dC(e,t.left,n),e.insert(n(t.value)),dC(e,t.right,n))}function hC(e,t){e!==tC&&(hC(e.left,t),t(e.value),hC(e.right,t))}class uC{constructor(e,t,n){void 0===t?this.tree=e:(this.tree=new sC,this.tree.insert(new aC(e,t,n)))}values(){return this.tree.values()}map(e){return new uC(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 aC(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];let a=t.value;let s=t.start;let 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);let i=[];let 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);let 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];let 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=this.intersecting(e,t);let r=n;let o;for(let n=0,a=i.length;n<a;n++){let a=i[n].start;a<e&&(a=e);let s=i[n].end;s>t&&(s=t),o=r+(s-a),this.value(r,o,i[n].value),r=++o}}iterator(e,t){return new pC(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 pC=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 fC extends uC{constructor(e,t,n){super(e,t,n),this._defaultValue=n,this.tree=new sC,this.range=new aC(e,t,n)}intersecting(e,t){let n=e;let i=this.tree.intersecting(n,t);let r=[];let o;if(!i.length)return[this.range];for(let e=0,t=i.length;e<t;e++)o=i[e],o.start>n&&r.push(new aC(n,o.start-1,this.range.value)),r.push(o),n=o.end+1;return o.end<t&&r.push(new aC(o.end+1,t,this.range.value)),r}insert(e,t,n){let i=n;null==i&&(i=this._defaultValue),i!==this.range.value&&this.tree.insert(new aC(e,t,i))}lastRangeStart(){let e=this.tree.root;if(e===tC)return this.range.start;for(;e.right!==tC;)e=e.right;return e.value.end+1}}class mC{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 gC extends mC{set(e,t,n){this.list.value(e,t,JSON.stringify(n))}parse(e){return JSON.parse(e)}}const vC=[{property:mC,name:"format",value:null,sortable:!0,serializable:!0},{property:class extends mC{constructor(e,t){super(e),this.formats=t}set(e,t,n){n instanceof Date?(n=mk.runtime.dateToSerial(n),this.formats.value(e,t)||this.formats.value(e,t,fk().calendar.patterns.d.replace(/M/g,"m").replace(/'/g,'"').replace(/tt/,"am/pm"))):"number"==typeof n&&(n=mk.runtime.limitPrecision(n)),this.list.value(e,t,n)}},name:"value",value:null,sortable:!0,serializable:!0,depends:"format"},{property:mC,name:"formula",value:null,sortable:!0,serializable:!0},{property:mC,name:"background",value:null,sortable:!0,serializable:!0},{property:gC,name:"vBorders",value:null,sortable:!1,serializable:!1},{property:gC,name:"hBorders",value:null,sortable:!1,serializable:!1},{property:gC,name:"dBorders",value:null,sortable:!1,serializable:!0},{property:mC,name:"color",value:null,sortable:!0,serializable:!0},{property:mC,name:"fontFamily",value:null,sortable:!0,serializable:!0},{property:mC,name:"underline",value:null,sortable:!0,serializable:!0},{property:mC,name:"fontSize",value:null,sortable:!0,serializable:!0},{property:mC,name:"italic",value:null,sortable:!0,serializable:!0},{property:mC,name:"bold",value:null,sortable:!0,serializable:!0},{property:mC,name:"textAlign",value:null,sortable:!0,serializable:!0},{property:mC,name:"indent",value:null,sortable:!0,serializable:!0},{property:mC,name:"verticalAlign",value:null,sortable:!0,serializable:!0},{property:mC,name:"wrap",value:null,sortable:!0,serializable:!0},{property:mC,name:"validation",value:null,sortable:!1,serializable:!0},{property:mC,name:"enable",value:null,sortable:!1,serializable:!0},{property:mC,name:"link",value:null,sortable:!0,serializable:!0},{property:mC,name:"editor",value:null,sortable:!0,serializable:!0},{property:mC,name:"comment",value:null,sortable:!0,serializable:!0},{property:mC,name:"html",value:null,sortable:!0,serializable:!0}];class _C{constructor(e,t,n){n=n||{};let i=e*t-1;this.specs=vC,this.rowCount=e,this.columnCount=t,this.cellCount=i,this.properties={},this.lists={},this.specs.forEach((function(e){let t=e.name;let r=n[t];void 0===r&&(r=e.value),this.lists[t]=new fC(0,i,r),(this.properties[t]=new e.property(this.lists[t],this.lists[e.depends])).spec=e}),this),this.lists.formula.tree.clone=wC,this.lists.validation.tree.clone=wC}_resize(e,t){let n=this;let i=n.rowCount;let 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];let r=i.iterator(t,n),o=r.at;let 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=this.iterators(e,t);let r=this.iterator("hBorders",e,t+1);let o=this.iterator("vBorders",e,t);let a=this.iterator("vBorders",e+this.rowCount,t+this.rowCount);let s,l;function c(e,t,n){let i=t.at(n);i!==t.value&&(s[e]=i)}for(l=e;l<=t;l++){s={};for(let e=0;e<i.length;e++){let t=i[e];let n=t.at(l);n!==t.value&&(s[t.name]=n)}c("borderLeft",o,l),c("borderRight",a,l+this.rowCount),c("borderTop",r,l),(l+1)%this.rowCount&&c("borderBottom",r,l+1),n(s)}}forEachProperty(e){for(let t in this.properties)e(this.properties[t])}}function bC(e){return(e=e.clone()).value=e.value.deepClone(),e}function wC(){let e=this.map(bC);return e.clone=wC,e}const yC=vC.reduce((function(e,t){return t.serializable&&e.push(t.name),e}),["borderTop","borderRight","borderBottom","borderLeft"]);class kC{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:"";let n=this.to?this.to_value:"";let i=this.from?this.from.toString():"";let r=this.to?this.to.toString():"";let o=this.dataType;let a=this.type;let s=this.comparerType;return pk().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=this.from_value.data;let t;let n;let i=[];for(t=0;t<e.length;t++){let r=e[t];if(r)for(n=0;n<r.length;n++)i.push(r[n])}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 kC(r)}deepClone(){let e=new kC(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 ky&&(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;let s=this.row;let 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 kC(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 xC={};xC.compile=function(e,t,n,i){let r;let o;let a;let 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(/^\s*\{\s*/,'"').replace(/\s*\}\s*$/,'"')),i.from=`_matrix(${i.from})`,i.fromIsListValue=!0),"date"===i.dataType&&(a=mk.runtime.parseDate(i.from),a&&(i.from=`DATEVALUE("${i.from}")`,i.fromIsDateValue=!0)),i.from=mk.compile(mk.parseFormula(e,t,n,i.from))),i.to&&("date"===i.dataType&&(s=mk.runtime.parseDate(i.to),s&&(i.to=`DATEVALUE("${i.to}")`,i.toIsDateValue=!0)),i.to=mk.compile(mk.parseFormula(e,t,n,i.to))),o="custom"===i.dataType?xC.validationComparers.custom:"list"===i.dataType?xC.validationComparers.list:xC.validationComparers[i.comparerType],!o)throw pk().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 kC(l)},xC.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}},xC.Validation=kC;const{measureText:CC}=ua;let SC=["color","fontFamily","underline","italic","bold","textAlign","indent","verticalAlign","background","format","link","editor","borderTop","borderRight","borderBottom","borderLeft","comment","html"];let TC=class e{constructor(e,t){this._sheet=t,this._ref=e}clone(){return new e(this._ref.clone(),this._sheet)}skipHiddenCells(){let e=[];let t=this,n=t._sheet;let i=n.isHiddenRow.bind(n);let r=n.isHiddenColumn.bind(n);return t._ref.forEach((function(n){let o=(n=t._normalize(n.toRangeRef())).topLeft,a=n.bottomRight;let s=MC(o.row,a.row,i);let l=MC(o.col,a.col,r);for(let t=0;t<s.length;++t)for(let n=0;n<l.length;++n)e.push(new Ty(new Sy(s[t].begin,l[n].begin),new Sy(s[t].end,l[n].end)))})),n.range(e.length>1?new My(e):e[0])}_normalize(e){return this._sheet._grid.normalize(e)}_set(e,t,n){let i=this;let r=i._sheet;return i._ref.forEach((function(n){let i=n;if(("value"===e||"formula"===e||"link"===e)&&n.topLeft){let e=new Sy(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=mk.parse(this._sheet.name(),r.row,r.col,e,i),this._sheet.batch(function(){let r=null;if("exp"===n.type)r=mk.compile(n);else if("@"!==i){let e=i&&lx.type(n.value,i);"date"===n.type&&"date"!==e?this.format(n.format||fk().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");let o=i&&!t&&lx.type(e,i);if(t)e="="+t;else e:{if(i&&"date"===o){let t=lx.text(e,i);if(n=mk.parse(null,null,null,t,i),t===lx.text(n.value,i)){e=t;break e}}if("date"===o){const t=pk();e=t.toString(mk.runtime.serialToDate(e),fk().calendar.patterns.d,t.locale)}else"percent"===o?e=mk.runtime.limitPrecision(100*e)+"%":"string"==typeof e&&(/^[=']/.test(e)||/^(?:true|false)$/i.test(e)||!/^=/.test(r=e)&&/number|percent/.test(mk.parse(null,0,0,r).type))?e="'"+e:this._sheet._useCultureDecimals()&&"number"==typeof e&&e!==Math.floor(e)&&(e=String(e).replace(".",fk().numbers.symbols.decimal))}return e}var r}enable(e){return void 0===e?!Xy((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 Xy((function(t){this._sheet._forFormulas((function(n){let i=n.arrayFormulaRange;i&&(i=e.intersect(i))!==xy&&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=this._ref.toRangeRef();let t=e.topLeft.row;let n=e.topLeft.col;let i=e.bottomRight.row;let r=e.bottomRight.col;let o,a;for(o=n;o<=r;o++)for(a=t;a<=i;a++){let e=this._sheet._validation(a,o);if(e&&"reject"===e.type&&!1===e.value)return e}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 My)throw new Error("Unsupported for multiple ranges.");if(this._ref===xy){if(void 0!==e)throw new Error("Unsupported for NULLREF.");return[]}let t=this._ref.toRangeRef();let n=t.topLeft.row;let i=t.topLeft.col;let r=t.bottomRight.row;let o=t.bottomRight.col;let a,s;if(void 0===e){e=new Array(t.height());for(let n=0;n<e.length;n++)e[n]=new Array(t.width());for(a=i;a<=o;a++)for(s=n;s<=r;s++)e[s-n][a-i]=this._sheet._value(s,a);return e}for(this._sheet._set(t,"formula",null),a=i;a<=o;a++)for(s=n;s<=r;s++){let t=e[s-n];if(t){let e=t[a-i];void 0!==e&&this._sheet._value(s,a,e)}}return this._sheet.triggerChange({recalc:!0,ref:t}),this}_properties(e,t){if(this._ref instanceof My)throw new Error("Unsupported for multiple ranges.");if(this._ref===xy){if(void 0!==e)throw new Error("Unsupported for NULLREF.");return[]}let n=this._ref.toRangeRef();let i=n.topLeft.row;let r=n.topLeft.col;let o=n.bottomRight.row;let a=n.bottomRight.col;let s,l;let c=this._sheet;if(void 0===e)return e=new Array(n.height()),c.forEach(n,(function(t,n,o){n-=r,(e[t-=i]||(e[t]=[]))[n]=o})),e;{let d;n=n.clone();let h=function(e){let t=d[e];n.topLeft.row=n.bottomRight.row=l,n.topLeft.col=n.bottomRight.col=s,"value"===e&&c._set(n,"formula",null),c._set(n,e,t)};let u=!1;for(s=r;s<=a;s++)if(t||!c.isHiddenColumn(s))for(l=i;l<=o;l++){if(!t&&c.isHiddenRow(l))continue;if(t&&c.isFilteredRow(l))continue;let n=e[l-i];if(n&&(d=n[s-r],d)){const e=Object.keys(d);e.forEach(h),u=u||e.includes("value")}}return c.triggerChange({recalc:!0,ref:this._ref,isValue:u}),this}}clear(e){let t=(e=e||{}).clearAll||!Object.keys(e).length;let n=this._sheet;let 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)&&(SC.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 My)return{code:"cantSortMultipleSelection",message:"Unsupported for multiple ranges."};if(this._ref===xy)return{code:"cantSortNullRef",message:"Unsupported for NULLREF."};let e=this._sheet._getMergedCells(this._ref.toRangeRef());let t=e.primary;let n=e.secondary;let i=null,r=null;let o={};try{this._sheet.forEach(this,(function(a,s){let l=new Sy(a,s).print();let 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 My)}filter(e){if(this._ref instanceof My)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();let 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;let t=[];return e._mergedCells.forEach(function(e){e.intersects(this._ref)&&t.push(e.toString())}.bind(this)),t}getState(e){let t=this._ref.first();let n={ref:t,data:[],origRef:this._ref,rows:this._sheet._rows.getState()};let i;e?i="input"===e?["value","formula"]:"border"===e?["borderLeft","borderTop","borderRight","borderBottom"]:[e]:(i=yC,n.mergedCells=this.intersectingMerged());let r=n.data;return this.forEachCell((function(e,n,o){let a={};let s=e-t.row;let l=n-t.col;r[s]||(r[s]=[]),r[s][l]=a,i.forEach((function(e){let t=void 0===o[e]?null:o[e];(t instanceof mk.runtime.Formula||t instanceof xC.Validation)&&(t=t.deepClone()),a[e]=t}))})),n}setState(e,t){let n=this._sheet;let i=this._ref.first();let r=e.ref.row-i.row;let o=e.ref.col-i.col;let a=t&&!t.isExternal();let s=t&&!a;n.batch(function(){e.mergedCells&&this.unmerge(),t||this._sheet._rows.setState(e.rows);let l=i.row;let 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,h){if(c&&a&&n.isHiddenColumn(e.ref.col+h))return;let u=t?n.range(l,d):n.range(i.row+o,i.col+h);if(u.enable()){for(let e in r)"value"!==e&&(t&&"enable"===e||u._set(e,r[e]));if(!r.formula)if(s)try{null==r.value?u._set("value",null):u.input(r.value)}catch(e){u._set("value",r.value)}else u._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;let t=e._sheet;let n=t._getMergedCells(e._ref.toRangeRef());let i=n.primary;let r=n.secondary;t.batch((function(){e.forEachRow((function(e){let n=e._ref.topLeft.row;let o=t.rowHeight(n);o&&(e.forEachCell((function(e,n,a){let s=new Sy(e,n).print();if(r[s])return;let l=i[s];let c;c=l?t._columns.sum(l.topLeft.col,l.bottomRight.col):t.columnWidth(n);let d=a.value;a.format&&null!=d&&(d=lx.format(d,a.format));let h=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 CC(e,a,{box:o,normalizeText:!1}).height}(d,c,a.fontFamily,a.fontSize,a.wrap);o=Math.max(o,h)})),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 Xy((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 Ty&&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 Ty&&t.height()>1&&((t=t.clone()).topLeft.row++,this._sheet.range(t)._set("hBorders",e))}),this),this}};function MC(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(MC(i+1,t,n));return[{begin:e,end:t}]}SC.forEach((function(e){TC.prototype[e]=function(t){return this._property(e,t)}}));var AC=mk.runtime.Formula;var DC="incompatibleRanges";var EC=TC.FillError=function(e){this.code=e};function IC(e){var t=e.length;var n=(t+1)/2,i=e.reduce((function(e,t){return e+t}),0)/t;var r=0,o=0;for(var 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 zC(e){function t(e){return e.map((function(e){return e.number}))}var n=[];var i=e.map((function(e){return e.formula||e.value}));return function(e,t){var n,i=null,r=0,o=[];for(var a=0;a<e.length;++a)n=PC(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=IC(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){var t=e[1]-e[0];for(var 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=IC(l),s=function(e,t){return i[t].replace(/^(.*\D0*)\d+$/,"$1"+l(e,t))}):s=function(){return null};var d={f:s,begin:e,end:r,len:r-e};for(var h=e;h<r;++h)n[h]=d})),function(t,r){var o=n[r];var a=t/i.length|0;var s=t%i.length;var l=a*o.len+s-o.begin;var c=o.f(l,r);var 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 AC?d.formula=c:d.value=c,d}}function PC(e){if("number"==typeof e)return{type:"number",number:e};if("string"==typeof e){var t=function(e){var t=e.toLowerCase();var n=function(){const e=fk().calendar;return[e.days.format.abbreviated,e.days.format.wide,e.months.format.abbreviated,e.months.format.wide]}();for(var i=0;i<n.length;++i){var r=n[i];for(var o=r.length;--o>=0;){if(r[o].toLowerCase()==t)return{type:r,number:o,value:e}}}}(e);if(t)return t;var n=/^(.*\D0*)(\d+)$/.exec(e);return n?{type:e=e.replace(/^(.*\D0*)\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 AC)return{type:"formula"};throw window.console.error(e),new Error("Cannot fill data")}function LC(e){var t=e.length,n=e[0].length;var i=[];for(var r=0;r<n;++r){i[r]=[];for(var o=0;o<t;++o)i[r][o]=e[o][r]}return i}TC.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());var 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 EC(DC);o.topLeft.col+=r.width(),t=1}else{if(!r.bottomRight.eq(o.bottomRight))throw new EC(DC);if(r.width()==o.width())o.bottomRight.row-=r.height(),t=2;else{if(r.height()!=o.height())throw new EC(DC);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 EC("noFillDirection");t=r.topLeft.col<o.topLeft.col?1:3}var a=1&t;var s=2&t;if(a&&r.height()!=o.height()||!a&&r.width()!=o.width())throw new EC(DC);var l,c=e._properties();a?l=o.width():(c=LC(c),l=o.height());var d=new Array(c.length);var h=null;for(var u=0;u<c.length;++u){var p=c[u];var f=zC(p);var m=d[u]=new Array(l);for(var g=0;g<l;++g){var v=s?-g-1:p.length+g;var _=s?p.length-g%p.length-1:g%p.length;var b=m[s?l-g-1:g]=f(v,_);null!=b.value&&(h=b.value)}}return a||(d=LC(d)),{props:d,direction:t,dest:n,hint:h}},TC.prototype.fillFrom=function(e,t){var n=this._previewFillFrom(e,t);return n.dest._properties(n.props,!0),n.dest};const BC="string";const HC="function";let RC=function(){this._defaultPrevented=!0};let FC=function(){return!0===this._defaultPrevented};let OC=class{constructor(){this._events={}}bind(e,t,n){let i,r,o,a,s,l=this,c=typeof e===BC?[e]:e,d=typeof t===HC;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===BC?[e]:e,l=typeof t===HC;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=RC,t.isDefaultPrevented=FC,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 VC extends OC{constructor(e,t){super(),this.element=e,this.events=[],this.options=t}setOptions(e){this._setEvents(e),tk({},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 NC extends OC{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;let 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();let 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 $C=/&/g,UC=/</g,WC=/"/g,jC=/'/g,qC=/>/g;let GC=class{constructor(e,t){this._value=t,this._count=e,this.values=new uC(0,e-1,t),this._hidden=new uC(0,e-1,0),this.scrollBarSize=rk(),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=[];let i=this.values.iterator(0,this._count-1);for(let r=0;r<this._count;r++){let o=i.at(r);let 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];let 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);let 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);let 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;let i=null;let 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;let s=(a/n.value.value|0)+n.value.start;let l=a-(s-n.value.start)*n.value.value;let c=t-i.start;let 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;let n=this.values.iterator(0,this._count-1);let 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 aC(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()}};let KC=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=this.start();let t;return this.hasHeader||(e+=this.headerSize),this.frozen?(t=this.size(),this.hasHeader?t+=this.headerSize:t-=this.headerSize):t=this._viewSize-e,{offset:e,length:t}}visible(e){let t=this.start();let n;this.frozen?(n=this.size(),this.hasHeader||(n-=this.headerSize)):(n=this._viewSize-t-this.headerSize,t+=e);let i=this._axis.visible(t,t+n-1);return this.frozen&&(i.offset=0),i.start=t,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}};let YC=class e{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(t,n){return new e(this.left+t,this.top+n,this.width,this.height)}resize(t,n){return new e(this.left,this.top,this.width+t,this.height+n)}intersects(t,n){return t instanceof e?this.intersectsRect(t):this.left<t&&t<this.left+this.width&&this.top<n&&n<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 Xk.element("div",{className:e,style:{width:this.width+"px",height:this.height+"px",top:this.top+"px",left:this.left+"px"}})}};class QC{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;let 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 Sy(e%this.rowCount,e/this.rowCount|0)}rowRef(e){return new Ty(new Sy(e,0),new Sy(e,this.columnCount-1))}colRef(e){return new Ty(new Sy(0,e),new Sy(this.rowCount-1,e))}cellRefIndex(e){return this.index(e.row,e.col)}normalize(e){return e instanceof Ty?new Ty(this.normalize(e.topLeft),this.normalize(e.bottomRight)).setSheet(e.sheet,e.hasSheet()):e instanceof My?e.map((function(e){return this.normalize(e)}),this):(e instanceof Sy&&((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);let n=this.normalize(e.bottomRight);return new YC(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 XC(new KC(this._rows,e.row,e.rowCount,this._headerHeight),new KC(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);let 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 Sy(r,e))}trim(e,t){let n=this.normalize(e.topLeft);let i=this.normalize(e.bottomRight);let r=n.row;let o=n.col;for(let e=n.col;e<=i.col;e++){let a=this.index(n.row,e);let s=this.index(i.row,e);let 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 Ty(e.topLeft,new Sy(Math.min(r,e.bottomRight.row),o))}}class XC{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();let 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);let i=this.columns.visible(e);return{rows:n,columns:i,rowOffset:n.offset,columnOffset:i.offset,mergedCellLeft:i.start,mergedCellTop:n.start,ref:new Ty(new Sy(n.values.start,i.values.start),new Sy(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);let 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};let i=this.columns.defaultValue/2;let 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 ZC{constructor(e,t){this._grid=e,this._lists=t}indices(e,t,n,i){let r=ZC.ascendingComparer;return!1===n&&(r=ZC.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);let 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}}ZC.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;let 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 hk)return t instanceof hk?0:1;throw new Error("Cannot compare "+e+" and "+t)},ZC.descendingComparer=function(e,t){return null===e&&null===t?0:null===e?1:null===t?-1:ZC.ascendingComparer(t,e)};class JC{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;let t=e.select().toRangeRef();let n=t.topLeft.col;let i=t.bottomRight.col;let r=null;for(;;){let t=i<e._columns._count;let 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 Ty(new Sy(0,r),new Sy(e._rows._count-1,r)),e.range(t).select())}hideSelectedRows(){this.forEachSelectedRow((function(e,t){e.hideRow(t)}));let e=this._sheet;let t=e.select().toRangeRef();let n=t.topLeft.row;let i=t.bottomRight.row;let r=null;for(;;){let t=i<e._rows._count;let 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 Ty(new Sy(r,0),new Sy(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=this._sheet;let t,n=0;return e.batch((function(){e.select().forEachColumnIndex((function(i){t||(t=i),e.insertColumn(t),++n}))}),{recalc:!0,layout:!0}),{base:t,count:n}}addColumnRight(){let e=this._sheet;let t,n=0;return e.batch((function(){e.select().forEachColumnIndex((function(e){t=e+1,++n}));for(let i=0;i<n;++i)e.insertColumn(t)}),{recalc:!0,layout:!0}),{base:t,count:n}}addRowAbove(){let e=this._sheet;let t,n=0;let i=e.select();return e.batch((function(){i.forEachRowIndex((function(i){t||(t=i),e.insertRow(t),++n}))}),{recalc:!0,layout:!0}),{base:t,count:n}}addRowBelow(){let e=this._sheet;let t,n=0;return e.batch((function(){e.select().forEachRowIndex((function(e){t=e+1,++n}));for(let i=0;i<n;++i)e.insertRow(t)}),{recalc:!0,layout:!0}),{base:t,count:n}}}class eS{constructor(e){this._grid=e}rectIsVertical(e,t,n,i){let r=this._grid.rectangle(e.toRangeRef());let o=this._grid.rectangle(t.toRangeRef());return Math.abs(o[i]-r[i])>Math.abs(r[n]-o[n])}autoFillDest(e,t){let n=e.topLeft;let i=e.bottomRight;let r;let o=t.row>=n.row;let a=t.col>=n.col;let s,l,c,d;if(r=o?a?4:3:a?2:1,4===r)s=n,l=i,d=t.row>l.row||t.col>l.col,d&&(t=new Sy(Math.max(t.row,l.row),Math.max(t.col,l.col))),c=this.rectIsVertical(l,t,"right","bottom")?new Sy(t.row,l.col):new Sy(l.row,t.col);else if(3===r){let e=new Sy(n.col,i.row);t.row>i.row&&this.rectIsVertical(e,t,"left","bottom")?(s=n,c=new Sy(t.row,i.col)):(s=i,c=new Sy(n.row,t.col))}else if(2===r){let e=new Sy(n.row,i.col);t.col>i.col&&!this.rectIsVertical(e,t,"right","top")?(s=n,c=new Sy(i.row,t.col)):(s=i,c=new Sy(t.row,n.col))}else s=i,c=this.rectIsVertical(n,t,"left","top")?new Sy(t.row,n.col):new Sy(n.row,t.col);return this._grid.normalize(new Ty(s,c))}}class tS{constructor(e,t,n,i){this.rangeGetter=n,this.prevLeft=function(n){var r=i(this.range(n));var o=this.range(t.prevVisible(r.topLeft[e]));return i(o).topLeft[e]},this.nextRight=function(n){var r=i(this.range(n));var 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 nS{constructor(e){this._sheet=e,this.autoFillCalculator=new eS(e._grid),this.colEdge=new tS("col",this._sheet._grid._columns,this.columnRange.bind(this),this.union.bind(this)),this.rowEdge=new tS("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 Ty(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=this.determineDirection(e);var n=this._sheet;var i=this._viewPortHeight;var r=n._grid._rows;var o=n._grid._columns;var a=n.currentOriginalSelectionRange();var s=n.select().toRangeRef();var l=n.activeCell();var c=a.topLeft.clone();var d=a.bottomRight.clone();var h=new Sy(d.row,c.col);var u;switch(this.colEdge.boundary(s.topLeft.row,s.bottomRight.row),this.rowEdge.boundary(s.topLeft.col,s.bottomRight.col),t){case"expand-left":c.col=this.colEdge.prevLeft(c.col),u=c;break;case"shrink-right":c.col=this.colEdge.nextLeft(c.col),u=c;break;case"expand-right":d.col=this.colEdge.nextRight(d.col),u=d;break;case"shrink-left":d.col=this.colEdge.prevRight(d.col),u=d;break;case"expand-up":c.row=this.rowEdge.prevLeft(c.row),u=c;break;case"shrink-down":c.row=this.rowEdge.nextLeft(c.row),u=c;break;case"expand-down":d.row=this.rowEdge.nextRight(d.row),u=d;break;case"shrink-up":d.row=this.rowEdge.prevRight(d.row),u=d;break;case"expand-page-up":c.row=r.prevPage(c.row,i);break;case"shrink-page-up":d.row=r.prevPage(d.row,i);break;case"expand-page-down":d.row=r.nextPage(d.row,i);break;case"shrink-page-down":c.row=r.nextPage(c.row,i);break;case"first-col":c.col=o.firstVisible(),d.col=l.bottomRight.col,u=c;break;case"last-col":d.col=o.lastVisible(),c.col=l.topLeft.col,u=d;break;case"first-row":c.row=r.firstVisible(),d.row=l.bottomRight.row,u=c;break;case"last-row":d.row=r.lastVisible(),c.row=l.topLeft.row,u=d;break;case"last":d.row=r.lastVisible(),d.col=o.lastVisible(),c=l.topLeft,u=d;break;case"first":c.row=r.firstVisible(),c.col=o.firstVisible(),d=l.bottomRight,u=c;break;case"expand-word-right":d.col=o.nextUntil(d.col,iS(n,d,!0)),u=d;break;case"shrink-word-right":c.col=o.nextUntil(h.col,iS(n,h,!0)),u=c;break;case"expand-word-left":c.col=o.prevUntil(h.col,iS(n,h,!0)),u=c;break;case"shrink-word-left":d.col=o.prevUntil(d.col,iS(n,d,!0)),u=d;break;case"expand-word-up":c.row=r.prevUntil(c.row,iS(n,c,!1)),u=c;break;case"shrink-word-up":d.row=r.prevUntil(d.row,iS(n,d,!1)),u=d;break;case"expand-word-down":d.row=r.nextUntil(d.row,iS(n,d,!1)),u=d;break;case"shrink-word-down":c.row=r.nextUntil(c.row,iS(n,c,!1)),u=c}var p=new Ty(c,d);this.union(p).intersects(l)?(u&&n.focus(u),this.updateCurrentSelectionRange(p)):this.modifySelection(t.replace("shrink","expand"))}moveActiveCell(e){var t=this._sheet;var n=t.activeCell();var i=n.topLeft;var r=n.bottomRight;var o=t.originalActiveCell();var a=t._grid._rows;var s=t._grid._columns;var l=o.row;var 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,iS(t,r,!0));break;case"word-left":c=s.prevUntil(c,iS(t,r,!0));break;case"word-up":l=a.prevUntil(l,iS(t,r,!1));break;case"word-down":l=a.nextUntil(l,iS(t,r,!1))}t.select(new Sy(l,c))}navigateInSelection(e){var t=this._sheet;var n=t.activeCell().topLeft;var i=t.originalActiveCell();var r=t._grid._rows;var o=t._grid._columns;var a=i.row;var s=i.col;var l=!1;var c=!1;var d,h;var u=n.col;var p=n.row;var f;function m(e){d=e.topLeft,h=e.bottomRight}m(t.currentNavigationRange());var g=!1;var v=!1;for(;!g&&!v;){var _=new Sy(a,s);switch(t.singleCellSelection()&&(l=d.eq(_)&&t._sheetRef.topLeft.eq(_),c=h.eq(_)&&t._sheetRef.bottomRight.eq(_),l||(l=o.firstVisible()===s&&r.firstVisible()===a),c||(c=o.lastVisible()===s&&r.lastVisible()===a)),e){case"next":c?v=!0:h.eq(_)?(m(t.nextNavigationRange()),a=d.row,s=d.col):((s=o.nextVisible(u))===u||s>h.col)&&(s=d.col,a=(f=r.nextVisible(a))===a||f>h.row?d.row:f);break;case"previous":l?(v=!0,this._sheet._workbook._view.element.querySelector(".k-spreadsheet-name-editor .k-input-inner").focus()):d.eq(_)?(m(t.previousNavigationRange()),a=h.row,s=h.col):((s=o.prevVisible(u))===u||s<d.col)&&(s=h.col,a=(f=r.prevVisible(a))===a||f<d.row?h.row:f);break;case"lower":h.eq(_)?(m(t.nextNavigationRange()),a=d.row,s=d.col):((a=r.nextVisible(p))===p||a>h.row)&&(a=d.row,s=(f=o.nextVisible(s))===s||f>h.col?d.col:f);break;case"upper":d.eq(_)?(m(t.previousNavigationRange()),a=h.row,s=h.col):((a=r.prevVisible(p))===p||a<d.row)&&(a=h.row,s=(f=o.prevVisible(s))===s||f<d.col?h.col:f);break;default:throw new Error("Unknown entry navigation: "+e)}g=!this.shouldSkip(a,s),u=s,p=a}g&&(t.singleCellSelection()?t.select(new Sy(a,s)):t.activeCell(new Sy(a,s)))}extendSelection(e,t){var n=this._sheet;var 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 Ty(r.topLeft,e))}else this.resizeAutoFill(e)}shouldSkip(e,t){if(this._sheet.isHiddenRow(e)||this._sheet.isHiddenColumn(t))return!0;var n=new Sy(e,t);var i=!1;return this._sheet.forEachMergedCell((function(e){e.intersects(n)&&!e.collapse().eq(n)&&(i=!0)})),i}resizeAutoFill(e){var t=this._sheet;var n=t.select();var i=t._autoFillOrigin;var r=this.autoFillCalculator.autoFillDest(n,e);var o=this.punch(n,r);var a,s;if(!o){var l=t.range(r)._previewFillFrom(t.range(i));l&&(s=l.direction,a=l.hint)}t.updateAutoFill(r,o,a,s)}determineDirection(e){var t=this._sheet.currentSelectionRange();var n=this._sheet.activeCell();var i=n.topLeft.col===t.topLeft.col;var r=n.bottomRight.col===t.bottomRight.col;var o=n.topLeft.row===t.topLeft.row;var 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 Ty(new Sy(i,e.topLeft.col),e.bottomRight)}else if(t.bottomRight.col<e.bottomRight.col){var r=this.colEdge.nextRight(t.bottomRight.col);n=new Ty(new Sy(e.topLeft.row,r),e.bottomRight)}return n}}function iS(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 rS(e){return null==e?null:mk.runtime.serialToDate(e)}var oS=function(e){return e};class aS{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;var 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=this.dataSource;var n=t.view();var i=this.columns;var r=[];var o=this.sheet;var a,s,l,c,d;var h=function(e){var o;var a=0;for(var l=(e=e.toRangeRef()).topLeft.row;l<=e.bottomRight.row;l++){(o=n[l-1])||(o=t.insert(l-1,{}),n=t.view());var d=0;for(var h=e.topLeft.col;h<=e.bottomRight.col&&h<i.length;h++){var u=r[c][a][d++];o.set(i[h].field,s[h](u))}a++}};for(t.reader.model&&(a=t.reader.model.fields),!i.length&&n.length&&(i=Object.keys(n[0].toJSON())),s=i.map((function(e){var t=e.field;return t&&a&&a[t]&&"date"===a[t].type?rS:oS})),this._skipRebind=!0,(l=o._grid.normalize(e.ref))instanceof My||(l=new My([l])),(d=l.refs).forEach((function(e){r.push(o.range(e).values())})),c=0;c<d.length;c++)d[c].forEach(h);this._boundRowsCount=t.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();var 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 ek(e.field)}));this.sheet.batch(function(){var t=Math.max(e.length,this._boundRowsCount,this.sheet._grid.rowCount-1);for(var 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 sS=function(){function e(){return Dg(new Date)}return{dayOfWeek:Tg,getDate:Dg,isToday:function(t){return Dg(t).getTime()===e().getTime()},addDays:yg,today:e,firstDayOfMonth:Ag}}();const lS={or:{concat:(e,t)=>n=>e(n)||t(n),identity:()=>!1},and:{concat:(e,t)=>n=>e(n)&&t(n),identity:()=>!0}};const cS={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=>ak(e),isnull:e=>(e=>!ak(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)};const dS=/^\/Date\((.*?)\)\/$/;const hS=({field:e,ignoreCase:t,value:n,operator:i,accentFoldingFiltering:r})=>{e=ak(e)?e:e=>e,t=!ak(t)||t;const o=uS(ck(e)?e:ek(e,!0),n,t,r);n=((e,t,n)=>{if(null!=e&&lk(e)){const i=dS.exec(e);if(i)return new Date(+i[1]).getTime();if(t)return n?e.toLocaleLowerCase(n):e.toLowerCase()}else if(null!=e&&sk(e))return e.getTime();return e})(n,t,r);const a=ck(i)?i:cS[i];return e=>a(o(e),n,t)};const uS=(e,t,n,i)=>{if(!ak(t))return e;let r=e;if(lk(t)){const o=dS.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 sk(t)?e=>{const t=r(e);return sk(t)?t.getTime():t}:r};const pS=function(e){const t=e.accentFoldingFiltering;const n=lS[e.logic||"and"];return e.filters.filter(ak).map((e=>{const n=ak(t)?tk({},e,{accentFoldingFiltering:t}):e;return ak(e.filters)?pS(n):hS(n)})).reduce(n.concat,n.identity)};let fS={};const mS=mk.runtime.dateToSerial;const gS=mk.runtime.serialToDate;class vS{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.")}}vS.create=function(e){var t=e.filter;if(!t)throw new Error("Filter type not specified.");var n=fS[t.charAt(0).toUpperCase()+t.substring(1)+"Filter"];if(!n)throw new Error("Filter type not recognized.");return new n(e)};class _S extends vS{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"===lx.type(t,e.format)&&(t=gS(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 bS extends vS{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=pS({logic:this._logic,filters:this._criteria,accentFoldingFiltering:fk().name})}matches(e){return null!==e&&this._matches(e)}value(e){var t=e.value;var n=this._criteria[0].value;var i=n instanceof Date?"date":typeof n;var r=typeof t;return e.format&&(r=lx.type(t,e.format)),r!=i?"string"==i&&(e.format&&(t=lx.text(t,e.format)),t+=""):"date"==r&&(t=gS(t)),t}toJSON(){return{filter:"custom",logic:this._logic,criteria:this._criteria}}}class wS extends vS{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 yS extends vS{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"===lx.type(t,e.format)&&(t=gS(t)));return t}prepare(e){var t=0;var n=0;for(var 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=mS(e)),"number"==typeof e&&e>this._average}belowAverage(e){return e instanceof Date&&(e=mS(e)),"number"==typeof e&&e<this._average}tomorrow(e){if(e instanceof Date){var t=sS.addDays(sS.today(),1);return sS.getDate(e).getTime()===t.getTime()}return!1}today(e){return e instanceof Date&&sS.isToday(e)}yesterday(e){if(e instanceof Date){var t=sS.addDays(sS.today(),-1);return sS.getDate(e).getTime()===t.getTime()}return!1}nextWeek(e){return TS(sS.addDays(sS.today(),7),e)}thisWeek(e){return TS(sS.today(),e)}lastWeek(e){return TS(sS.addDays(sS.today(),-7),e)}nextMonth(e){return SS(e,1)}thisMonth(e){return SS(e,0)}lastMonth(e){return SS(e,-1)}nextQuarter(e){if(e instanceof Date){var t=sS.today();var n=xS(e)-xS(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=sS.today();return 0===xS(e)-xS(t)&&t.getFullYear()===e.getFullYear()}return!1}lastQuarter(e){if(e instanceof Date){var t=sS.today();var n=xS(t)-xS(e);return 1===n&&t.getFullYear()===e.getFullYear()||-3==n&&t.getFullYear()-1===e.getFullYear()}return!1}nextYear(e){return CS(e,1)}thisYear(e){return CS(e,0)}lastYear(e){return CS(e,-1)}yearToDate(e){if(e instanceof Date){var t=sS.today();return e.getFullYear()===t.getFullYear()&&e<=t}return!1}toJSON(){return{filter:"dynamic",type:this._type}}}fS={Filter:vS,ValueFilter:_S,CustomFilter:bS,TopFilter:wS},[1,2,3,4].forEach((function(e){yS.prototype["quarter"+e]=function(t){return t instanceof Date&&xS(t)===e}}));const kS=()=>{fk().calendar.months.format.wide.forEach((function(e,t){yS.prototype[e.toLowerCase()]=function(e){return e instanceof Date&&e.getMonth()===t}}))};function xS(e){var t=e.getMonth()+1;return t>=1&&t<=3?1:t>=4&&t<=6?2:t>=7&&t<=9?3:4}function CS(e,t){if(e instanceof Date){var n=sS.today();return n.setFullYear(n.getFullYear()+t),n.getFullYear()===e.getFullYear()}return!1}function SS(e,t){if(e instanceof Date){var n=sS.firstDayOfMonth(sS.today());return n.setMonth(n.getMonth()+t,1),n.getTime()===sS.firstDayOfMonth(e).getTime()}return!1}function TS(e,t){if(t instanceof Date){var n=sS.dayOfWeek(sS.getDate(e),1);var i=sS.dayOfWeek(sS.getDate(t),1);return n.getTime()===i.getTime()}return!1}var MS;let AS=class{constructor(e){this._sheet=e,this.selection=Ay.toRangeRef(),this.originalSelection=Ay.toRangeRef(),this._activeCell=Ay.toRangeRef(),this.originalActiveCell=Ay}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 TC(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=i.panes;var o,a,s,l,c,d;for(o=0;o<r.length&&(!(a=r[o])._currentView||(s=a._currentView.rows.values,l=a._currentView.columns.values,c=new Ty(new Sy(s.start,l.start),new Sy(s.end,l.end)),(d=e.intersect(c))===xy));o++);d&&d!==xy&&(e=d)}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)}};let DS={};class ES extends OC{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=this.validation(e);let n=this._properties.get("editor",this._grid.cellRefIndex(e));let i;return null!=n?i=DS[n]:t&&t.showButton&&(n="_validation_"+t.dataType,i=DS[n]),"function"==typeof i&&(i=DS[n]=i()),i}}_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 GC(e,n),this._columns=new GC(t,i),this._filteredRows=new uC(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 QC(this._rows,this._columns,e,t,r,o),this._sheetRef=this._grid.normalize(Dy),this._properties=new _C(e,t,this._defaultCellStyle),this._sorter=new ZC(this._grid,this._properties.sortable()),this._viewSelection=new AS(this),this._editSelection=new AS(this),this._formulaSelections=[],this._drawings=[]}resize(e,t){e=Math.max(e,1),t=Math.max(t,1);var n=this._rows._count;var 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(Dy),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){var t=e.length,n=0;for(var 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 nS(this)),this._navigator}axisManager(){return this._axisManager||(this._axisManager=new JC(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 aS({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;var i=n.rowCount;var r=n.normalize(e.topLeft);var o=n.normalize(e.bottomRight);var a=r.col*i+r.row;var s=o.col*i+o.row;var l=t.col*i+t.row;this._properties.copy(a,s,l)}_saveModifiedFormulas(e,t){var n=MS;MS=e;var i=t();return MS=n,i}_restoreModifiedFormulas(e){var t=this._workbook;e.forEach((function(e){var n,i=t.sheetByName(e.sheet);e instanceof mk.runtime.Formula&&(n=i._grid.cellRefIndex(e),i._properties.set("formula",n,n,e)),e instanceof xC.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 Ty&&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&&MS&&MS.push(o)})),i._forValidations((function(i){var o=i.adjust(r,e,t,n);o&&MS&&MS.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))!==xy&&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();var 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;var n=t.columnCount;var i=t.rowCount;if(e+1!==i){var r=this.frozenRows();e<r&&this.frozenRows(r+1);var o=this._mergedCells.slice();for(var a=0;a<n;a++){var s=new Ty(new Sy(e,a),new Sy(e,a));var l=t.normalize(s.topLeft);var c=t.normalize(s.bottomRight);var d=new Ty(new Sy(l.row,l.col),new Sy(i-2,c.col));this._copyRange(d,new Sy(l.row+1,l.col)),new TC(s,this).clear({clearAll:!0,keepBorders:!0})}this._adjustReferences("row",e,1,o)}}),{recalc:!0,layout:!0,insertRow:{index:e},ref:new Ty(new Sy(e,0),new Sy(1/0,1/0))}),t||this.trigger("afterInsertRow",{index:e}),this}isEnabledRow(e){var t=new Ty(new Sy(e,0),new Sy(e,this._grid.columnCount));return new TC(t,this).enable()}deleteRow(e,t){return this.isEnabledRow(e)?this.trigger("deleteRow",{index:e})?void 0:(this.batch((function(){var t=this._grid;var n=t.columnCount;var i=this.frozenRows();e<i&&this.frozenRows(i-1);var r=this._mergedCells.slice();for(var o=0;o<n;o++){var a=new Ty(new Sy(e,o),new Sy(e,o));new TC(a,this).clear({clearAll:!0,keepBorders:!0});var s=t.normalize(a.topLeft);var l=t.normalize(a.bottomRight);var c=new Ty(new Sy(s.row+1,s.col),new Sy(1/0,l.col));this._copyRange(c,s);var d=t.normalize(c.bottomRight);new TC(new Ty(d,d),this).clear()}this._adjustReferences("row",e,-1,r),this._resizeDeleteRow()}),{recalc:!0,layout:!0,deleteRow:{index:e},ref:new Ty(new Sy(e,0),new Sy(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;var n=t.columnCount;if(e+1!==n){var i=this.frozenColumns();e<i&&this.frozenColumns(i+1);var r=this._mergedCells.slice();for(var o=n;o>=e;o--){var a=new Ty(new Sy(0,o),new Sy(1/0,o));if(new TC(a,this).clear({clearAll:!0,keepBorders:!0}),o===e)break;var s=t.normalize(a.topLeft);var l=t.normalize(a.bottomRight);var c=new Ty(new Sy(s.row,s.col-1),new Sy(l.row,l.col-1));this._copyRange(c,s)}this._adjustReferences("col",e,1,r)}}),{recalc:!0,layout:!0,insertColumn:{index:e},ref:new Ty(new Sy(0,e),new Sy(1/0,1/0))}),this}isEnabledColumn(e){var t=new Ty(new Sy(0,e),new Sy(1/0,e));return new TC(t,this).enable()}deleteColumn(e){return this.isEnabledColumn(e)?this.trigger("deleteColumn",{index:e})?void 0:(this.batch((function(){var t=this._grid;var n=t.columnCount;var i=this.frozenColumns();e<i&&this.frozenColumns(i-1);var r=this._mergedCells.slice();for(var o=e;o<n;o++){var a=new Ty(new Sy(0,o),new Sy(1/0,o));if(new TC(a,this).clear({clearAll:!0,keepBorders:!0}),o===n-1)break;var s=t.normalize(a.topLeft);var l=t.normalize(a.bottomRight);var c=new Ty(new Sy(s.row,s.col+1),new Sy(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 Ty(new Sy(0,e),new Sy(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 ky?e:e instanceof TC?e._ref.toRangeRef():("string"==typeof e?r=mk.parseReference(e):(n||(n=1),i||(i=1),r=new Ty(new Sy(e,t),new Sy(e+n-1,t+i-1))),r)}range(e,t,n,i){return new TC(this._ref(e,t,n,i),this)}_getMergedCells(e){var t=this._grid;var n={};var i={};var 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 Ty||(e=e.toRangeRef());var i=n._grid.normalize(e.topLeft);var r=n._grid.normalize(e.bottomRight);var o,a;function s(e){t(a++,o,e)}for(o=i.col;o<=r.col;o++){a=i.row;var l=n._grid.index(a,o);var c=n._grid.index(r.row,o);n._properties.forEach(l,c,s)}}e instanceof Ty||(e=n._ref(e)),e instanceof My?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){var t=this._mergedCells;for(var 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);var i=this._rows.indexVisible(n.top);var r=this._columns.indexVisible(n.left);var o=new Sy(i,r);var 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;var 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=this._selectionState();var i;return e&&(e=this._ref(e),e=this._grid.normalize(e),i=this._grid.isAxis(e)?e:this.unionWithMerged(e)),n.select(e,i,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=[];var 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 TC(this._grid.normalize(this.activeCell()),this)}selection(){return new TC(this._grid.normalize(this._selectionState().selection),this)}selectedHeaders(){var e=this.select();var t={};var n={};var i=!1;var r=!1;var o=this._grid.rowCount-1;var a=this._grid.columnCount-1;return e.forEach((function(e){var s;var l="partial";var c="partial";var d=(e=e.toRangeRef()).bottomRight;var h=e.topLeft;var u=h.col<=0&&d.col>=a;var p=h.row<=0&&d.row>=o;if(p&&(r=!0,c="full"),u&&(i=!0,l="full"),!p)for(s=h.row;s<=d.row;s++)"full"!==t[s]&&(t[s]=l);if(!u)for(s=h.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={};var t=this._rows.toJSON("height",e);var n=this._columns.toJSON("width",{});var i=this._viewSelection;var r=[];var o=this._defaultCellStyle||{};this.forEach(Dy,(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:ky.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=_o(a.color).toCss()),a.background&&(a.background=_o(a.background).toCss()),a.borderTop&&a.borderTop.color&&(a.borderTop.color=_o(a.borderTop.color).toCss()),a.borderBottom&&a.borderBottom.color&&(a.borderBottom.color=_o(a.borderBottom.color).toCss()),a.borderRight&&a.borderRight.color&&(a.borderRight.color=_o(a.borderRight.color).toCss()),a.borderLeft&&a.borderLeft.color&&(a.borderLeft.color=_o(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];var 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];var a=o.index;if(void 0===a&&(a=r),o.formula){var s="string"!=typeof o.formula;var l=s?o.formula.src:o.formula;var c=this._compileFormula(i,a,l);s&&c.setArrayFormulaRange(mk.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(IS.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 h=e.filter.ref;var u=void 0===e.filter.columns?[]:e.filter.columns;h&&(this._filter={ref:this._ref(h),columns:u.map((function(e){return{index:e.index,filter:vS.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();var 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 Sy(n.row,n.col);var r=new Ty(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 xC.Validation?n.clone(this._name(),e,t):(null!=n.from&&(n.from=(n.from+"").replace(/^=/,"")),null!=n.to&&(n.to=(n.to+"").replace(/^=/,"")),xC.compile(this._name(),e,t,n))}_compileFormula(e,t,n){return n=n.replace(/^=/,""),n=mk.parseFormula(this._name(),e,t,n),mk.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=this._grid.normalize(e.topLeft);var r=this._grid.normalize(e.bottomRight);var o,a,s;if("number"==typeof n&&(n=mk.runtime.limitPrecision(n)),n&&"formula"===t)"string"==typeof n&&(n=this._compileFormula(i.row,i.col,n)),n=this._copyValuesInRange(i,r,n,"formula");else if(n&&"validation"===t)n=this._compileValidation(i.row,i.col,n),n=this._copyValuesInRange(i,r,n,"validation");else for(o=i.col;o<=r.col;o++)a=this._grid.index(i.row,o),s=this._grid.index(r.row,o),this._properties.set(t,a,s,n),"formula"===t&&this._properties.set("value",a,s,null)}_get(e,t){var n=this._grid.normalize(e.topLeft);var 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);var i=[];if(n!==xy){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];var 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(zy)}_merge(e){var t=this._mergedCells;var n=this;var i;return this.batch((function(){i=e.map((function(e){if(e instanceof Sy)return e;var i=e.toRangeRef().union(t,(function(e){t.splice(t.indexOf(e),1)}));var r=new TC(i,n);var o=r._get("formula");var a=r.value();var s=r.format();var l=r.background();r.value(null),r.format(null),r.background(null);var c=new TC(i.collapse(),n);return o?c._set("formula",o):c.value(a),c.format(s),c.background(l),t.push(i),i}));var r=n._viewSelection;r.selection=n.unionWithMerged(r.originalSelection),r._activeCell=n.unionWithMerged(r.originalActiveCell)}),{activeCell:!0,selection:!0}),i}_useCultureDecimals(){return this._workbook&&this._workbook.options.useCultureDecimals}withCultureDecimals(e){var t=".";return this._useCultureDecimals()&&(t=fk().numbers.symbols.decimal),mk.withDecimalSeparator(t,e)}drawingBoundingBox(e){var t=e.offsetX;var 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 YC(t,n,e.width,e.height)}refBoundingBox(e){return this._grid.rectangle(e.toRangeRef())}addDrawing(e,t){return e instanceof IS||(e=new IS(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){var t=this._mergedCells;for(var n=t.length;--n>=0;)if(t[n].eq(e))return!0;return!1}}class IS{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 IS(this)}reset(e){var t=e.topLeftCell;"string"==typeof t&&(t=mk.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}}IS.fromJSON=function(e){return new IS(e)};let zS={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 PS(e){return e*(72/25.4)}function LS(e){return PS(10*e)}function BS(e){return 72*e}function HS(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:PS,cm:LS,in:BS}[t[2]](e)}}if(null!=t)return t;throw new Error("Can't parse unit: "+e)}let RS=.8;function FS(e,t,n,i,r){let o=0;let a=[];let s=t;let 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 OS(e,t,n){let i=e._grid;t=i.normalize(t);let r=i.rectangle(t);let 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=[];let s=[];let l=[];let c=e._getMergedCells(t);let d=-1,h=-1;e.forEach(t,(function(i,r,u){let p=i-t.topLeft.row;let f=r-t.topLeft.col;let m=e.rowHeight(i);let g=e.columnWidth(r);n.forScreen||(u.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)),h=Math.max(h,e._columns.index(t.box.right)),!0}))),f||s.push(m),p||l.push(g);let v=new Sy(i,r).print();if(c.secondary[v])return;u.row=p,u.col=f;let _=c.primary[v];if(_?(delete c.primary[v],u.merged=!0,u.rowspan=_.height(),u.colspan=_.width(),n.forScreen&&(u.width=e._columns.sum(_.topLeft.col,_.bottomRight.col),u.height=e._rows.sum(_.topLeft.row,_.bottomRight.row))):(u.rowspan=1,u.colspan=1),!e._grid._columns.sum(r,r+u.colspan-1)||!e._grid._rows.sum(i,i+u.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}(u);(n.emptyCells||b)&&(b?(d=Math.max(d,p+u.rowspan-1),h=Math.max(h,f+u.colspan-1)):u.empty=!0,a.push(u))})),n.forScreen||(s=s.slice(0,d+1),l=l.slice(0,h+1));let u=n.pageWidth;let p=n.pageHeight;let f=n.scale||1;if(n.fitWidth){let e=l.reduce(NS,0);e>u&&(f=u/e)}u=Math.ceil(u/f),p=Math.ceil(p/f);let m=[];let g=FS(s,p||0,n.maxEmpty,n.headerRows,m);let v=FS(l,u||0,n.maxEmpty);let _=0;let b=0;let w=[];return a=a.filter((function(e){return(!e.empty||!(e.row>d||e.col>h))&&(n.headerRows&&e.row<n.headerRows&&w.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=$S(v,e.col+e.colspan),e.bottom=$S(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;let 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){w.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(WS)),{width:_,height:b,cells:a.sort(US),scale:f,xCoords:v,yCoords:g,drawings:o}}function VS(e,t){return e.size===t.size&&e.color===t.color}function NS(e,t){return e+t}function $S(e,t){return t<e.length?e[t]:e[e.length-1]}function US(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 WS(e,t){return e<t?-1:e>t?1:0}function jS(e,t,n,i){let r=Math.ceil(t.width/i.pageWidth);let o=Math.ceil(t.height/i.pageHeight);let a=Math.ceil(i.pageWidth/t.scale);let 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;let c=l+a;let d=r*s;let h=d+s;let u=0,p=0;function f(e){return!(e.right<=l||e.left>=c||e.bottom<=d||e.top>=h)&&(u=Math.max(e.bottom,u),p=Math.max(e.right,p),!0)}let m=t.cells.filter(f);let g=t.drawings.filter((function(e){return f(e.box)}));if(u=Math.min(u,h),p=Math.min(p,c),m.length||g.length){let r=new Us;n.append(r);let o=new Us;r.append(o),o.clip(Rs.fromRect(new ya([l-1,d-1],[p+1,u+1])));let a=Jo.scale(t.scale,t.scale).multiplyCopy(Jo.translate(-l,-d));if((i.hCenter||i.vCenter)&&(a=a.multiplyCopy(Jo.translate(i.hCenter?(c-p)/2:0,i.vCenter?(h-u)/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 Rs).moveTo(t,d).lineTo(t,u).close().stroke(i.guideColor,RS)))})),e=null,t.yCoords.forEach((function(t){(t=Math.min(t,u))!==e&&t>=d&&t<=h&&(e=t,o.append((new Rs).moveTo(l,t).lineTo(p,t).close().stroke(i.guideColor,RS)))}))}let s=QS();m.forEach((function(t){!function(e,t,n){let i=new Us;t.append(i);let r=new ya([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 Xs(t).fill(e.background||"#fff").stroke(null))}e.dBorders&&(2&e.dBorders.type&&i.append((new Rs).moveTo(e.left,e.bottom).lineTo(e.right,e.top).stroke(e.dBorders.color,e.dBorders.size)),1&e.dBorders.type&&i.append((new Rs).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;let n=new Us;n.clip(Rs.fromRect(r)),i.append(n);let a,s=e.format;if(s||"number"!=t||o==Math.floor(o)||(s="0.##############"),s?(a=lx.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){GS||(GS=document.createElement("div"),GS.style.position="fixed",GS.style.left="0px",GS.style.top="0px",GS.style.visibility="hidden",GS.style.overflow="hidden",GS.style.boxSizing="border-box",GS.style.lineHeight="normal",document.body.appendChild(GS));GS.firstChild&&GS.removeChild(GS.firstChild);GS.style.padding="2px 4px",GS.style.color=t,GS.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),GS.style.width=n.width+"px",GS.style.textAlign=n.textAlign||"left",GS.style.textDecoration=n.underline?"underline":"none",qS(n,GS.style),n.wrap?(GS.style.whiteSpace="pre-wrap",GS.style.overflowWrap=GS.style.wordWrap="break-word"):(GS.style.whiteSpace="pre",GS.style.overflowWrap=GS.style.wordWrap="normal");GS.appendChild(document.createTextNode(e));let r=0;switch(n.verticalAlign){case"center":r=n.height-GS.offsetHeight>>1;break;case void 0:case null:case"bottom":r=n.height-GS.offsetHeight}r<0&&(r=0);let o=tu(GS);o.transform(Jo.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 Us;s.vert.forEach((function(e){e.forEach((function(e){e.rendered||(e.rendered=!0,f.append((new Rs).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 Rs).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;let i=n.image;if(null!=i){let r=t.box;let a=e._workbook.imageUrl(i);o.append(new n.Image(a,new ya([r.left,r.top],[r.width,r.height])).opacity(n.opacity))}}))}}}function qS(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"}}}let GS;function KS(e,t,n,i){null==n&&null==i&&(i=t,n={},t=Dy),null==i&&(i=n,t instanceof Range||t instanceof ky||"string"==typeof t?n={}:(n=t,t=Dy)),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 Us;let 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",zS.a4);if(!t)return{};if("string"==typeof t&&(t=zS[t.toLowerCase()],null==t))throw new Error("Unknown paper size");t[0]=HS(t[0]),t[1]=HS(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=HS(n,0),n={left:n,top:n,right:n,bottom:n}):n={left:HS(n.left,0),top:HS(n.top,0),right:HS(n.right,0),bottom:HS(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];let 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=OS(e,e._ref(t),n);jS(e,l,r,n),i(r)}function YS(){}function QS(){let e=new YS;let t=new YS;function n(e){return"__proto__"===e||"constructor"===e||"prototype"===e}function i(e,i,r,o,a,s){if(n(e)||n(i))return;let l=t[i]||(t[i]=new YS);let c=e>0&&l[e-1];c&&VS(c,r)?(l[e]=c,c.bottom=s):l[e]={size:r.size,color:r.color||"#000",x:o,top:a,bottom:s}}function r(t,i,r,o,a,s){if(n(t)||n(i))return;let l=e[t]||(e[t]=new YS);let c=i>0&&l[i-1];c&&VS(c,r)?(l[i]=c,c.right=s):l[i]={size:r.size,color:r.color||"#000",y:o,left:a,right:s}}return{add:function(e,t){if(t){let n=t._properties;let 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&&i(e.row,e.col,e.borderLeft,e.left,e.top,e.bottom),e.borderRight&&i(e.row,e.col+e.colspan,e.borderRight,e.right,e.top,e.bottom),e.borderTop&&r(e.row,e.col,e.borderTop,e.top,e.left,e.right),e.borderBottom&&r(e.row+e.rowspan,e.col,e.borderBottom,e.bottom,e.left,e.right)},horiz:e,vert:t}}ES.prototype.draw=function(e,t,n){let i=this;i._workbook?i.recalc(i._workbook._context,(function(){KS(i,e,t,n)})):KS(i,e,t,n)},YS.prototype={forEach:function(e){Object.keys(this).forEach((function(t){e(this[t],t,this)}),this)}};const XS={Borders:QS,doLayout:OS,applyIndent:qS};const ZS=".";const JS={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"};const eT={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 tT(e){return(e.size||1)+"px solid "+(e.color||"#000")}function nT(e){return/:\/\//.test(e)||(e="http://"+e),e}function iT(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"),Xk.element("a",{href:nT(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:[]};let s=t.background;if(s){let e=s;i&&(e=_o(e).toHSV(),e.v*=.9,e=e.toCssRgba()),e=tT({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=lx.format(l,d),l.__dataType&&(c=l.__dataType)):null!=l&&(l=t.html?Xk.html(l):Xk.text(l)),!a.textAlign)switch(c){case"number":case"date":case"percent":case"currency":a.textAlign="right";break;case"boolean":a.textAlign="center"}XS.applyIndent(t,a);let h=[eT.cell];n&&h.push(n),!1===t.enable&&h.push("k-disabled"),t.merged&&(h.push("k-spreadsheet-merged-cell"),t.enable||e.push(Xk.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&&h.push("k-spreadsheet-has-comment");let u=t.verticalAlign||"bottom";l=u&&l?Xk.element("div",{className:"k-vertical-align-"+u},[r(l)]):r(l),a.background.length?a.background=a.background.join(","):delete a.background;let p=l?[l]:[];let f={style:a};let m=t.validation;m&&!m.value&&(p.push(Xk.element("span",{className:"k-dirty"})),h.push("k-dirty-cell"),f.title=m.message),f.className=h.join(" ");let g=Xk.element("div",f,p);return e.push(g),g}let rT=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;let i=n.scrollLeft;let r=n.scrollTop;r<0&&(r=0),i<0&&(i=0);let o=e.classNames;let a=this._sheet;let s=this._grid;let 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=Xk.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(Xk.element("div",{className:this.headerClassName(t,"row"),style:{width:s.headerWidth+"px",height:i+"px"}},[Xk.element("div",{className:"k-vertical-align-center"},[Xk.text(n+"")])]))}}.bind(this))}if(s.hasColumnHeader){let e=Xk.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=ky.display(null,1/0,i),r=a.columnWidth(i);e.children.push(Xk.element("div",{className:this.headerClassName(i,"col"),style:{position:"absolute",left:t+"px",width:r+"px",height:s.headerHeight+"px"}},[Xk.element("div",{className:"k-vertical-align-center"},[Xk.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),Xk.element("div",{style:s.style,className:d.join(" ")},c)}headerClassName(e,t){let n=this._selectedHeaders;let i;let r;"row"===t?(i=n.rows[e],r=n.allRows):(i=n.cols[e],r=n.allCols);let o=i||(n.all?"full":r?"partial":"none");return o&&(o="k-selection-"+o),o}renderData(t){let n=this._sheet;let i=this._currentView;let r=Xk.element("div",{className:e.classNames.data,style:{position:"relative",left:i.columnOffset+"px",top:i.rowOffset+"px"}});let o=this._currentRect;let a,s=XS.doLayout(n,i.ref,{forScreen:!0});let l=this._grid;let c=n._showGridLines;c&&(a=null,s.xCoords.forEach((function(e){e!==a&&(a=e,r.children.push(Xk.element("div",{className:eT.vaxis,style:{left:e+"px",height:o.height+"px",borderColor:n.gridLinesColor()}})))})),a=null,s.yCoords.forEach((function(e){e!==a&&(a=e,r.children.push(Xk.element("div",{className:eT.haxis,style:{top:e+"px",width:o.width+"px",borderColor:n.gridLinesColor()}})))})));let d=XS.Borders();let h=n.activeCell().toRangeRef();let u=h.topLeft;return s.cells.forEach((function(o){let a=null;let s=o.row+i.ref.topLeft.row;let p=o.col+i.ref.topLeft.col;if(n._activeDrawing){let e=n._activeDrawing.topLeftCell;e&&e.row===s&&e.col===p&&(a="k-spreadsheet-drawing-anchor-cell")}else s===u.row&&p===u.col&&(a=[e.classNames.activeCell].concat(this._activeFormulaColor(),this._directionClasses(h)),n.singleCellSelection()&&a.push(e.classNames.single),a=a.join(" "));if(d.add(o),iT(r.children,o,a,c),o.comment&&n._commentRef&&s===n._commentRef.row&&p===n._commentRef.col){let e=4;let n=o.right+l.left+i.columnOffset+e;let r={top:o.top+l.top+i.rowOffset+"px"};n+200>t.contentWidth?r.right=t.contentWidth-l.left-o.left-i.columnOffset+e+"px":r.left=n+"px";let a=Xk.element("div",{className:"k-tooltip k-spreadsheet-cell-comment",style:r},[Xk.text(o.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)"),r.children.push(Xk.element("div",{className:eT.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)"),r.children.push(Xk.element("div",{className:eT.hborder,style:t}))}}))})),this.renderDrawings(s,r.children),r}renderDrawings(e,t){let n=this._sheet;let i=n._workbook;e.drawings.forEach((function(e){let r=e.drawing;let o=e.box.toDiv("k-spreadsheet-drawing");r.image&&o.children.push(Xk.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(Xk.element("div",{className:"k-spreadsheet-drawing-handle "+t,"data-direction":t}))}))}(o.children)),t.push(o)}))}renderResizeHandle(t){let n=this._sheet.resizeHandlePosition();let i=this._rectangle(n);let r=[e.classNames.resizeHandle];let o;if(n.col!==-1/0){if(this._grid.rows._start>0)return;o={height:this._grid.headerHeight+"px",width:"7px",left:i.right-3.5+"px",top:"0px"},r.push(JS.horizontalResize)}else{if(this._grid.columns._start>0)return;o={height:"7px",width:this._grid.headerWidth+"px",top:i.bottom-3.5+"px",left:"0px"},r.push(JS.verticalResize)}t.push(Xk.element("div",{className:r.join(" "),style:o}))}filterIconRect(e){return new YC(e.right-16-3,e.top+3,16,16)}icon(e){return"function"==typeof this.getIconHTMLString?Xk.element(this.getIconHTMLString(e)):Xk.element("span",{className:JS.icon+" "+e})}renderFilterHeaders(){let e=this;let t=this._sheet;let n=[];let i=JS;let r=t.filter();return r&&this._addDiv(n,r.ref,i.filterRange),t.forEachFilterHeader(this._currentView.ref,function(t){let o=this._rectangle(t);let a=this.filterIconRect(o);let s=this._sheet.filterColumn(t);let l=function(t,n,i){let o={left:n.left+"px",top:n.top+"px"};let a=r&&r.columns.some((function(e){return e.index===i}));let s=t.filterButton;return a&&(s+=" "+t.filterButtonSelected),Xk.element("span",{className:s,style:o},[e.icon(t.iconFilterDefault)])}(i,a,s);n.push(l)}.bind(this)),Xk.element("div",{className:i.filterHeadersWrapper},n)}renderEditorSelection(){let t=e.classNames;let n=this._sheet;let i=[];return n._formulaSelections.forEach(function(e){let n=e.ref;n!==xy&&this._addDiv(i,n,t.selectionHighlight+" "+e.colorClass)}.bind(this)),Xk.element("div",{className:t.selectionWrapper},i)}renderSelection(t){let n=e.classNames;let i=[];let r=[n.selection];let o=this._sheet;let a=o.activeCell().toRangeRef();let 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!==xy&&this._addDiv(i,e,r.join(" "))}.bind(this)),this._renderCustomEditorButton(i,a,t),Xk.element("div",{className:n.selectionWrapper},i)}renderAutoFill(){let t=[];if(this._sheet.autoFillInProgress()){let e=this._sheet.autoFillRef();let n=this._sheet.autoFillPunch();let 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 Sy(e.topLeft.row,e.bottomRight.col),r="k-auto-fill-tr-hint";break;case 3:n=new Sy(e.bottomRight.row,e.topLeft.col),r="k-auto-fill-bl-hint"}let o=this._addDiv(t,n,r);if(o){let e=Xk.element("span",{className:"k-tooltip"},[Xk.text(this._sheet._autoFillHint)]);o.children.push(e)}}}return Xk.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;let r=i._sheet;let o=i._currentView;let a=i._grid.columns._axis._count;let 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";let d=r===a-1||i._buttonOutOfVisiblePane(t,r,n);d&&(c+=" k-spreadsheet-last-column"),i._editorInLastColumn=d;let h=Xk.element("div",{className:c,style:{left:l.left+(d?0:l.width)+"px",top:l.top+"px",height:l.height+"px"}});s.icon&&h.children.push(i.icon(s.icon)),e.push(h)}))}}_activeFormulaColor(){let e;let 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=[];let i=e.classNames;let 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;let r=this._sheet;let o=r.range(e,t)._ref;let a=i.scrollBoundaries(o);let s=i.columns.frozen?0:n.scrollLeft;if(a.right+20>s||t+1===r.frozenColumns())return!0}};rT.classNames=eT;let oT=["font-family","font-size","font-stretch","font-style","font-weight","letter-spacing","text-transform","line-height"];let aT={27:"esc",37:"left",39:"right",35:"end",36:"home",32:"spacebar"};let sT=/(^_|[^a-z0-9]$)/i;class lT extends VC{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(lT.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;let t=window.getSelection();let n=r(t.focusNode,t.focusOffset);let 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();let 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=[];let t;for(let n in mk.runtime.FUNCS)sT.test(n)||(t=n.toUpperCase(),e.push({value:t,text:t}));this.formulaSource=e}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;let i=e;let 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;let n=this;aT[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=this.popup;let t;if(this._isFormula()&&!this._navigated){t=((this._tokenContext()||{}).token||{}).value;const n=this.filter(t);t&&n.length?(e[e.visible()?"position":"open"](),setTimeout((()=>{this.list.focusFirst()}),0)):e.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=this.getPos();let n;n=e.clipboardData.getData("text/plain");let i=this.value();i=i.substr(0,t.begin)+n+i.substr(t.end),this.value(i),this.setPos(t.begin+n.length),this.scale()}_move(e){let t=this.list;let n=this.popup;if(n.visible()){if(e===Ry)return t.focusNext(),!0;if(e===Hy)return t.focusPrev(),!0;if(e===By||e===Ly){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===Fy)return t.focusFirst(),!0;if(e===Oy)return t.focusLast(),!0}return!1}_tokenContext(){let e=this.getPos();let t=this.value();if(!t||!e||!e.collapsed)return null;let n=mk.tokenize(t,this.row(),this.col());let i;for(let t=0;t<n.length;++t)if(i=n[t],dT(i,e)&&/^(?:str|sym|func)$/.test(i.type))return{token:i,nextToken:n[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,oT);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]);ok(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")),ok(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=e;let n=this.getPos();let i,r,o;if(n&&this._isFormula()){if(0===n.begin)return null;for(i=mk.tokenize(this.value(),this.row(),this.col()),o=0;o<i.length;++o){if(r=i[o],dT(r,n))return s(r);if(a(r))return l(i[o-1],r)}return l(r,null)}return null;function a(e){return e.begin>n.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===n.end?l(e,i[o+1]):l(i[o-1],e)}}function l(e,i){if(null==e)return null;if(null==i)return/^(?:op|startexp)$/.test(e.type)||cT(e.value)?{token:e,end:n.end}:null;if(t){if("op"===e.type&&/^(?:punc|op)$/.test(i.type))return{token:e,end:n.end}}else{if("startexp"===e.type)return{token:e,end:n.end};if(/^(?:op|punc)$/.test(e.type)&&/^[,;({]$/.test(e.value))return{token:e,end:n.end};if(/^(?:ref|sym)/.test(e.type))return{token:e,replace:!0,end:e.end};if(/^(?:ref|sym)/.test(i.type))return{token:i,replace:!0,end:i.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();let i=e.token;let 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=this.element;let t,n;this._span||this._textContainer(),this._span.innerHTML=e.innerHTML,t=this._span.offsetWidth+this.options.scalePadding,n=this._span.offsetHeight,t>e.offsetWidth&&(e.style.width=t+"px");n-1>e.offsetHeight&&(e.style.height=n-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();let t=this.value();let n=rT.classNames.series;let i=[];let r=0;let o=[];let a=[];e&&!e.collapsed||(/^=/.test(t)?(a=mk.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(cT(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")):(dT(t,e)||dT(n,e))&&(t.cls.push("k-syntax-paren-match"),n.cls.push("k-syntax-paren-match")):t.cls.push("k-syntax-error")}var a;var s;e&&dT(t,e)&&(t.cls.push("k-syntax-at-point"),t.active=!0),"func"!==t.type||(s=t.value,mk.runtime.FUNCS[s.toLowerCase()])||e&&dT(t,e)||t.cls.push("k-syntax-error")})),a.reverse().forEach((function(e){let n=e.begin,i=e.end;let r=function(e){return String(e).replace($C,"&").replace(UC,"<").replace(qC,">").replace(WC,""").replace(jC,"'")}(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();let t=this.getPos();let 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 cT(e){return"("===e||"["===e||"{"===e}function dT(e,t){return e.begin<=t.begin&&e.end>=t.end}lT.classNames={wrapper:"k-spreadsheet-formula-input",listWrapper:"k-spreadsheet-formula-list"};class hT extends VC{constructor(e,t){super(e,t);const n=e&&e.querySelector(".k-spreadsheet-formula-input:not(.k-spreadsheet-cell-editor)");this.formulaInput=new lT(n,this.options)}destroy(){this.formulaInput&&this.formulaInput.destroy(),this.formulaInput=null}}class uT extends VC{readData(){const e=[];return this._workbook.forEachName((function(t){!t.hidden&&t.value instanceof ky&&e.push({name:t.name})})),e}value(e){if(this.options.combobox.current)return this.options.combobox.current.value(e)}}class pT extends VC{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 fT{constructor(){this.cols=[],this.trs=[],this._height=0,this._width=0}addColumn(e){this._width+=e;let t=Xk.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=Xk.element("tr",t);n.visible=e>0,this.trs.push(n)}addCell(e,t,n,i,r){null==t&&(t=""),t instanceof Xk.Node||(t=Xk.text(t));let o=[t];r&&!r.value&&(o.push(Xk.element("span",{className:"k-dirty"})),i=(i||"")+(i?" ":"")+"k-dirty-cell",n.title=r.message),i&&(n.className=i);let a=Xk.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),Xk.element("table",{style:{left:e+"px",top:t+"px",height:this._height+"px",width:this._width+"px"},className:n,role:"presentation"},[Xk.element("colgroup",null,this.cols),Xk.element("tbody",null,this.trs)])}}function mT(e,t,n){return e>=t&&e<=n}class gT extends OC{constructor(e,t){super();let n=gT.classNames;if(this.element=e,this.options=tk({},{messages:Ey.view},this.options,t),this.events=["update","message"],this._chrome(),this._dialogs=[],this._formulaInput(),this.wrapper=e.querySelector(ZS+n.view),this.container=e.querySelector(ZS+n.fixedContainer),this.scroller=e.querySelector(ZS+n.scroller),this.clipboard=e.querySelector(ZS+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 Xk.Tree(this.container),this.clipboardContents=new Xk.Tree(this.clipboard),this.editor=new NC(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 uT(e,{combobox:this.options.nameBoxRef});let t=this.element.querySelector(".k-spreadsheet-formula-bar");this.formulaBar=new hT(t,{input:this.options.formulaBarInputRef}),this._tabstrip()}_formulaInput(){let e=this.element.querySelector(ZS+gT.classNames.cellEditor);this.formulaInput=new lT(e,{autoScale:!0,input:this.options.formulaCellInputRef})}_sheetsbar(){this.options.sheetsbar&&(this.sheetsbar=new pT(this.element.querySelector(ZS+gT.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;let o=n._grid;let a=o.rows.frozen?0:r.scroller.scrollTop;let s=o.columns.frozen?0:r.scroller.scrollLeft;return e-=r._sheet._grid._headerWidth-s,t-=r._sheet._grid._headerHeight-a,Xy((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;let r=this._sheet._drawings;for(let n=r.length;--n>=0;){let o=r[n];let 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=this._sheet._grid;let r,o;if(e<0||t<0||e>this.scroller.clientWidth||t>this.scroller.clientHeight)r={type:"outside"};else if(e<i._headerWidth&&t<i._headerHeight)r={type:"topcorner"};else if(o=this.paneAt(e,t),o){if(!n){let n=this.drawingAt(e,t,o);if(n)return{type:"drawing",drawing:n.drawing,drx:n.drx,dry:n.dry,pane:o,startX:e,startY:t}}let a=o._grid.rows.indexVisible(t,this.scroller.scrollTop);let s=o._grid.columns.indexVisible(e,this.scroller.scrollLeft);let l="cell";let c=new Sy(a,s);let d=this._sheet.selectionInProgress();this.isAutoFill(e,t,o)?l="autofill":this.isFilterIcon(e,t,o,c)?l="filtericon":!d&&e<i._headerWidth?(l="rowheader",null!==(a=this.isRowResizer(t,o,a))&&(c=new Sy(a,-1/0),l="rowresizehandle")):!d&&t<i._headerHeight?(l="columnheader",null!==(s=this.isColumnResizer(e,o,s))&&(c=new Sy(-1/0,s),l="columnresizehandle")):this.isEditButton(e,t,o)&&(l="editor"),r={type:l,ref:c}}else r={type:"outside"};return r.pane=o,r.x=e,r.y=t,r}paneAt(e,t){return this.panes.filter((function(n){let i=n._grid;return mT(t,i.top,i.bottom)&&mT(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();let 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;let n=t.filter().ref;let i={column:e,range:new TC(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;let n=this.containingPane(e)._grid;let i=n.scrollBoundaries(e);let r=this.scroller;let o=n.rows.frozen?0:r.scrollTop;let 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;let t=e._sheet.activeCell().first();let n=e._sheet.activeCellCustomEditor();let 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();let r=new TC(i,n);let o={...t,name:e,ref:i,range:r};return this.trigger("message",o),o.dialog}.bind(this))}showError(e,t){let n=this._dialogs;let 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;let n=t.focus();let i=rk();let r=this.wrapper.clientWidth-i;let 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(JS.editContainer,this.editor.isActive()),this.wrapper.classList.toggle(JS.horizontalResize,"row"===a),this.wrapper.classList.toggle(JS.verticalResize,"column"===a);let s=t._grid;let l=[];let c={scroller:this.scroller,toplevelElements:l,contentWidth:r,contentHeight:o};this.panes.forEach((function(e){l.push(e.render(c))}));let d=Xk.element("div",{style:{width:s._headerWidth+"px",height:s._headerHeight+"px"},className:gT.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=this._sheet;let t=e.resizeHandlePosition().col!==-1/0;let n;n=t?{height:this.scroller.clientHeight+"px",width:"7px",left:e.resizeHintPosition().x+"px",top:"0px"}:{height:"7px",width:this.scroller.clientWidth+"px",top:e.resizeHintPosition().y+"px",left:"0px"};let i=rT.classNames;return Xk.element("div",{className:i.resizeHint+(t?"":" "+i.resizeHintVertical),style:n},[Xk.element("div",{className:i.resizeHintHandle}),Xk.element("div",{className:i.resizeHintMarker})])}renderClipboardContents(){let e=this._sheet;let t=e._grid;let n=t.normalize(e.select().toRangeRef());let 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 fT;let 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);let s=a.primary;let l=a.secondary;e.forEach(n,(function(e,t,i){let o=new Sy(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=tT(n.borderRight):n.background&&(i.borderRightColor=n.background),n.borderBottom?i.borderBottom=tT(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=lx.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=e.addCell(t,r,s,l,n.validation);let d,h;return n.borderLeft?(h=function(e,t){let n=e.trs[t].children;return n[n.length-2]}(e,t),d=tT(n.borderLeft),h&&d&&(h.attr.style.borderRight=d)):n.background&&(i.borderLeftColor=n.background),n.borderTop?(h=function(e,t){let n=e.trs[t-1];let i=e.trs[t].children.length-1;if(n&&i>=0)return n.children[i]}(e,t),d=tT(n.borderTop),h&&d&&(h.attr.style.borderBottom=d)):n.background&&(i.borderTopColor=n.background),c}(r,e-n.topLeft.row,i);let 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 rT(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}}gT.classNames=JS;const vT=/<table[^>]+>/gim;const _T=e=>(e||"").match(vT)||[];class bT{constructor(e){this._content={},this._externalContent={},this._internalContent={},this.workbook=e,this.origin=xy,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};let t=this.workbook.activeSheet().select();return t===xy&&(e.canCopy=!1),t instanceof My&&(e.canCopy=!1,e.multiSelection=!0),this.menuInvoked&&(e.canCopy=!1,e.menuInvoked=!0),e}canPaste(){let e=this.workbook.activeSheet();let t=this.pasteRef();let 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===xy)return e.select();let t=e.activeCell().first();let n=this.origin.first();let i=n.row-t.row;let r=n.col-t.col;return this.origin.relative(i,r,3)}paste(){let e=this.workbook.activeSheet();let 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=wT();if(-1===e.indexOf("\t")&&-1===e.indexOf("\n"))yT(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++)yT(t,e,n,{value:i[n]})}}return t}(t.plain):wT(),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=wT();let i=[],r=0,o=0;for(let t=0;t<e.rows.length;++t)i.push([]);let a=new mk.runtime.Matrix;let s=new mk.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];let d=l.rowSpan;let h=l.colSpan;for(;i[r][o];)o++;let u=l.getAttribute("style");let p=/mso-ignore:colspan/.test(u);yT(n,r,o,xT(r,o,l,a,s,t)),(d>1||h>1&&!p)&&n.mergedCells.push(new Ty(new Sy(r,o),new Sy(r+d-1,o+h-1)).toString());for(let e=r+d;--e>=r;)for(let t=o+h;--t>=o;)e<i.length&&(i[e][t]=!0,e===r&&t===o||yT(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;const t=t=>t.some((t=>t.includes(e)));return t(_T(this._externalContent.html))||t(_T(this._externalContent.plain))}}function wT(){let e=new Sy(0,0,0);return{ref:e,mergedCells:[],data:[],foreign:!0,origRef:e.toRangeRef()}}function yT(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 kT(e){return e.replace(/^-(?:ms|moz|webkit)-/,"")}function xT(e,t,n,i,r,o){let a=window.getComputedStyle(n),s="string"==typeof o&&o.indexOf("Excel")>-1;let l,c,d;!s&&(l=n.getAttribute("data-sheets-value"))&&(l=JSON.parse(l),l=l[l[1]]),!s&&(c=n.getAttribute("data-sheets-numberformat"))&&(c=JSON.parse(c),c=c[c[1]]),d=n.getAttribute("data-sheets-formula"),s||null!=l||null!=c||null!=d||(l=n.getAttribute("sdval"),c=n.getAttribute("sdnum"),c&&(c=c.replace(/^1033;(?:0;)?/,""))),null==l&&(l=(n.innerText||n.textContent).replace(/\t$/,""));let h=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,a);let u={value:""===l?null:l,formula:d,borderTop:h.borderTop||i.get(e,t)||null,borderBottom:h.borderBottom||i.get(e+1,t)||null,borderLeft:h.borderLeft||r.get(e,t)||null,borderRight:h.borderRight||r.get(e,t+1)||null,fontSize:parseInt(a.fontSize,10)};null!=c&&(u.format=c),i.set(e,t,u.borderTop),i.set(e+1,t,u.borderBottom),r.set(e,t,u.borderLeft),r.set(e,t+1,u.borderRight),"rgb(0, 0, 0)"!==a.backgroundColor&&"rgba(0, 0, 0, 0)"!==a.backgroundColor&&(u.background=a.backgroundColor),"right"!==kT(a.textAlign)&&(u.textAlign=kT(a.textAlign)),"middle"!==a.verticalAlign&&(u.verticalAlign=a.verticalAlign),"normal"!==a.wordWrap&&(u.wrap=!0);const p=n.querySelector("font");return p&&(a=window.getComputedStyle(p)),"rgb(0, 0, 0)"!==a.color&&"rgba(0, 0, 0, 0)"!==a.color&&(u.color=a.color),/^underline/.test(a.textDecoration)&&(u.underline=!0),"italic"==a.fontStyle&&(u.italic=!0),/^(?:bold|[67]00)$/i.test(a.fontWeight)&&(u.bold=!0),u}let CT="autoFill",ST="clear",TT="cut",MT="edit",AT="paste",DT="validation";const ET=()=>{};class IT{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 zT extends IT{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 PT extends IT{constructor(e){super(e),this._drawing=e.drawing}usesImage(e){return this._drawing.image===e}}class LT extends PT{constructor(e){super(e),this._blob=e.blob,this._width=e.width,this._height=e.height}exec(){let e=this.range();let t=e.sheet();let n=this._width;let i=this._height;let 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 BT extends PT{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 HT extends PT{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 RT extends HT{_reorder(){return this.range().sheet()._drawings.length}}class FT extends HT{_reorder(){return 0}}class OT extends IT{constructor(e){super(e),this._target=e.target,this._value=e.value}exec(){this.getState(),this.setState(this._value)}}class VT extends OT{getState(){this._state=this.range().sheet().columnWidth(this._target)}setState(e){this.range().sheet().columnWidth(this._target,e)}}class NT extends OT{getState(){this._state=this.range().sheet().rowHeight(this._target)}setState(e){this.range().sheet().rowHeight(this._target,e)}}class $T extends IT{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 UT extends OT{getState(){this._state=this._range.sheet().showGridLines()}setState(e){this._range.sheet().showGridLines(e)}}class WT extends IT{_setRange(e){IT.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 jT extends WT{exec(){let e=this.range();e.enable()&&(this.getState(),e.clearFormat())}}class qT extends IT{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:ST})?void 0:(e.clearContent(),i=e._getValidationState(),i?this.rejectState(i):void 0)):{reason:"error",type:"intersectsArray"}:{reason:"error",type:"cannotModifyDisabled"}}undo(){let e=this.range().skipHiddenCells();let t=e.sheet();let n=this._state.data;let i=[];let r;n.forEach((function(e){r=[],e.forEach((function(e){r.push(e.value)})),i.push(r)})),t.trigger("changing",{data:i,range:e,changeType:ST})||this.setState(this._state)}}class GT extends WT{constructor(e){e.property=e.property||"input",super(e)}_setRange(e){WT.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;let t=this._state;e.sheet().trigger("changing",{data:t.data[0][0].value,range:e,changeType:MT})||this.setState(this._state)}_exec(){let e=this.options.arrayFormula;let 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:MT}))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 mk.runtime.ParseError)return{title:"Error in formula",body:e+"",reason:"error"};throw e}else t.value(n)}}class KT extends WT{constructor(e){e.property="comment",super(e)}}class YT extends WT{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();let t=this._rowHeight;this.range().setState(this._state);for(let n in t)e.rowHeight(n,t[n])}}class QT extends IT{constructor(e){e.property="format",super(e),this._delta=e.value}exec(){let e=this.range().sheet();let 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=lx.adjustDecimals(o||"0",t),e.range(n,i).format(o))}))}.bind(this))}}class XT extends IT{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 ZT extends IT{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();let 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();let t=e._ref.topLeft;e.unmerge(),this.activate(t)}}class JT extends IT{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 eM extends IT{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 My?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;let t=this._range;e.trigger("changing",{data:this._state.data,range:t,changeType:AT})||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;let n=this._range;this._workbook.trigger("paste",{range:n,clipboardContent:this._clipboardContent})||t.trigger("changing",{data:this._clipboardContent.data,range:n,changeType:AT})?this._event.preventDefault():this._processPaste()}_adjustPasteTarget(e,t,n){let i=this;let r=i._targetRangeRefs;let o=i._sheet;let a=[];let s=function(e,t){let n=0;let i=e.topLeft;let 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};let l,c,d,h,u,p,f;for(p=0;p<r.length;p+=1)d=r[p],u=e[p],h=d.topLeft,f={row:u.rows*t+h.row-1,col:u.cols*n+h.col-1},l=new Ty(h,f),a.push(l);1===a.length?c=o.range(l):(a.sort(s),c=o.range(new My(a))),c.select(),i._range=c,i._state=i._range.getState()}_processPaste(){let e=this;let t=e._sheet;let n=e._clipboardContent;let i=e._range;let r=n.data;let o=r.length;let a=r[0].length;let s=e._targetRangeRefs;let l=e._targetRanges(o,a);let c;let d=this._clipboard.pasteRef();(d.bottomRight.row>=t._rows._count||d.bottomRight.col>=t._columns._count)&&t.resize(Math.max(d.bottomRight.row+1,t._rows._count),Math.max(d.bottomRight.col+1,t._columns._count)),e._adjustPasteTarget(l,o,a),t.batch((function(){for(c=0;c<s.length;c++)e._populateTargetRange(s[c],o,a,l[c])}),{recalc:!0,ref:e._range._ref}),i._adjustRowHeight()}_populateTargetRange(e,t,n,i){let r=e.topLeft;let o,a,s;for(a=0;a<i.rows;a++)for(s=0;s<i.cols;s++)o=this._sheet.range(r.row+t*a,r.col+n*s),o.setState(this._clipboardContent,this._clipboard)}_targetRangeDimensions(e,t,n){let i=e.topLeft;let r=e.bottomRight;let o=r.row-i.row+1;let a=r.col-i.col+1;let s=1;let l=1;return o%t==0&&a%n==0&&(s=o/t,l=a/n),{rows:s,cols:l}}_targetRanges(e,t){let n=this._targetRangeRefs;let i=[];let r;for(r=0;r<n.length;r++)i.push(this._targetRangeDimensions(n[r],e,t));return i}}class tM extends IT{exec(){let e=this.options;let t=this._workbook.activeSheet();(e.range||t.range(e.rowIndex))._adjustRowHeight()}}class nM extends IT{exec(){if(!oM().paste)return{reason:"error",type:"useKeyboard"};this._workbook._view.clipboard.focus({preventScroll:!0}),document.execCommand("paste")}}class iM extends IT{constructor(e){super(e),this._eventType="cut",this._clipboard=e.workbook.clipboard(),this._event=e.event}exec(){let e=this._clipboard.canCopy();let t,n,i=[];if(!e.canCopy)return e.menuInvoked?{reason:"error",type:"useKeyboard"}:e.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(t=r.values(),t.forEach((function(e){n=[],e.forEach((function(){n.push({})})),i.push(n)})),r.sheet().trigger("changing",{data:i,range:r,changeType:TT}))return;this._clipboard.cut()}else this._clipboard.copy()}undo(){let e=this.range();e.sheet().trigger("changing",{data:this._state.data,range:e,changeType:TT})||this.setState(this._state)}}class rM extends iM{constructor(e){super(e),this._eventType="copy",this.undo=ET}}function oM(){return{copy:!!document.queryCommandSupported&&document.queryCommandSupported("copy"),cut:!!document.queryCommandSupported&&document.queryCommandSupported("cut"),paste:!!document.queryCommandSupported&&document.queryCommandSupported("paste")}}class aM extends IT{constructor(e){super(e),this._clipboard=e.workbook.clipboard(),this.cannotUndo=!0}exec(){if(!oM().copy)return{reason:"error",type:"useKeyboard"};document.execCommand("copy")}}class sM extends IT{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:CT}))return;e.dest._properties(e.props,!0)}catch(e){if(e instanceof TC.FillError)return{reason:"error",type:e.code};throw e}}undo(){let e=this.range();let t=this._state;e.sheet().trigger("changing",{data:t.data,range:e,changeType:CT})||this.setState(this._state)}}class lM extends IT{constructor(e){super(e),this._clipboard=e.workbook.clipboard(),this.cannotUndo=!0}exec(){if(!oM().copy)return{reason:"error",type:"useKeyboard"};document.execCommand("cut")}}class cM extends IT{undo(){this.range().filter(this._state)}exec(){let e=this.range();this._state=e.hasFilter(),e.filter(!this._state)}}class dM extends IT{undo(){this.range().sheet().setState(this._state)}exec(){let e=this.range();let t=e.sheet();let n=t.activeCell();let i=this.options.sheet?n.topLeft.col:this.options.column||0;let 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 TC(e._sheetRef,e)}}class hM extends IT{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=this.range();let t=this.column();let n=e.sheet().filter();let i;let r;let o=!1;this.options.valueFilter?r={column:t,filter:new _S(this.options.valueFilter)}:this.options.customFilter&&(r={column:t,filter:new bS(this.options.customFilter)}),this.getState(),n&&n.ref.eq(e._ref)&&n.columns.length?(n.columns.forEach((function(e){e.index===t&&(o=!0)})),i=n.columns.map((function(e){return e.index===t?r:{column:e.index,filter:e.filter}})),o||i.push(r)):i=r,e.filter(i)}}class uM extends hM{exec(){let e=this.range();let t=this.column();this.getState(),e.clearFilter(t)}}class pM extends IT{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 fM extends pM{exec(){let e=this.range().sheet();this._state=e.getAxisState(),"row"===this.axis?e.axisManager().unhideSelectedRows():e.axisManager().unhideSelectedColumns()}}class mM extends IT{exec(){this._expandedRange=this._expand(this.range()),this._state=this._expandedRange.getState(),this._indexes=this._exec(this._expandedRange.sheet())}undo(){let e=this;let t=e._expandedRange;let 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 gM extends mM{_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 vM extends mM{_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 _M extends IT{constructor(e){super(e),this._value=e.value}undo(){let e=this;let 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 bM extends _M{exec(){let e=this._value;let t=this.range().sheet();this._pos="left"===e?t.axisManager().addColumnLeft():t.axisManager().addColumnRight()}_undoOne(e,t){e.deleteColumn(t)}}class wM extends _M{exec(){let e=this._value;let t=this.range().sheet();this._pos="above"===e?t.axisManager().addRowAbove():t.axisManager().addRowBelow()}_undoOne(e,t){e.deleteRow(t)}}class yM extends IT{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:DT}))try{t.withCultureDecimals((function(){e.range().validation(e._value)}))}catch(e){if(e instanceof mk.runtime.ParseError)return{title:"Error in formula",body:e+"",reason:"error"};throw e}}undo(){let e=this.range();let t=this._state;e.sheet().trigger("changing",{data:t.data[0][0].validation,range:e,changeType:DT})||this.setState(this._state)}}class kM extends IT{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 xM extends IT{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(tk(this.options.pdf,{workbook:this.options.workbook,fileName:e}))}}class CM extends IT{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 SM extends CM{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 TM extends CM{exec(){this.getState(),this._workbook.undefineName(this._name),this._workbook.trigger("change",{recalc:!0})}}var MM=Object.freeze({__proto__:null,AddColumnCommand:bM,AddCommand:_M,AddRowCommand:wM,AdjustDecimalsCommand:QT,AdjustRowHeightCommand:tM,ApplyFilterCommand:hM,AutoFillCommand:sM,BorderChangeCommand:XT,BringToFrontCommand:RT,ClearContentCommand:qT,ClearFilterCommand:uM,ColumnWidthCommand:VT,Command:IT,CopyCommand:rM,CutCommand:iM,DefineNameCommand:SM,DeleteColumnCommand:vM,DeleteCommand:mM,DeleteDrawingCommand:BT,DeleteNameCommand:TM,DeleteRowCommand:gM,DrawingCommand:PT,DrawingUpdateCommand:zT,EditCommand:GT,EditValidationCommand:yM,FilterCommand:cM,FreezePanesCommand:JT,GridLinesChangeCommand:UT,HideLineCommand:pM,HyperlinkCommand:$T,InsertCommentCommand:KT,InsertImageCommand:LT,MergeCellCommand:ZT,NameCommand:CM,OpenCommand:kM,PasteCommand:eM,PropertyChangeCommand:WT,PropertyCleanCommand:jT,ReorderDrawingsCommand:HT,RowHeightCommand:NT,SaveAsCommand:xM,SendToBackCommand:FT,SortCommand:dM,TargetValueCommand:OT,TextWrapCommand:YT,ToolbarCopyCommand:aM,ToolbarCutCommand:lM,ToolbarPasteCommand:nM,UnHideLineCommand:fM});class AM extends OC{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 DM=String.fromCharCode;let EM={amp:38,lt:60,gt:62,quot:34,apos:39,nbsp:160};function IM(e){let t=[];for(let n=0;n<e.length;++n)t.push(e.charCodeAt(n));return t}function zM(e,t){t>65535?(t-=65536,e.push(t>>>10&1023|55296,56320|1023&t)):e.push(t)}let PM=IM("<![CDATA[");let LM=IM("]]>");let BM=IM("--\x3e");let HM=IM("!--");let RM=IM("/>");let FM=IM("</");let OM=IM("?>");let VM=IM("?");let NM=IM("<");let $M=IM(">");let UM=IM(";");let WM=IM("=");let jM=IM("&");let qM=IM('"');let GM=IM("'");let KM=IM("#");let YM=IM("x");let QM=IM("X");let XM={};function ZM(e,t){let n=0;let i=[];let 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 XM},stack:i};function o(t){let i=e[n++];240&i^240?224&i^224?192&i^192?t.push(i):zM(t,(31&i)<<6|63&e[n++]):zM(t,(15&i)<<12|(63&e[n++])<<6|63&e[n++]):zM(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 DM.apply(0,s(e))}function c(){s(u)}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 h(e){d(e)||a("Expecting "+e.join(", "))}function u(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(VM)?(k("decl",_(),y()),h(OM)):d(HM)?function(){let t=[];for(;n<e.length;){if(d(BM))return k("comment",DM.apply(0,t));o(t)}}():(t=_(),r=y(t),i.push(r),d(RM)?k("enter",t,r,!0):(h($M),k("enter",t,r),function(t){let i=[];for(;n<e.length;){if(d(FM))return i.length&&k("text",DM.apply(0,i));if(d(PM))for(;n<e.length&&!d(LM);)o(i);else d(NM)?(i.length&&k("text",DM.apply(0,i)),v(),i=[]):d(jM)?w(i):o(i)}a("Unclosed tag "+t)}(t),t!==_()&&a("Bad closing tag"),k("leave",t,r),c(),h($M)),i.pop())}function _(){return m(e[n])||a("Expecting XML name"),l(g)}function b(){let t=d(qM)||d(GM);t||a("Expecting string");let i=[];for(;n<e.length;){if(d(t))return DM.apply(0,i);d(jM)?w(i):o(i)}a("Unfinished string")}function w(e){let t;if(d(KM))t=d(YM)||d(QM)?parseInt(l(f),16):parseInt(l(p),10),isNaN(t)&&a("Bad numeric entity");else{let e=_();t=EM[e],void 0===t&&a("Unknown entity "+e)}zM(e,t),h(UM)}function y(t){let i={$tag:t};for(;n<e.length;){c();let t=e[n];if(63===t||62===t||47===t)break;i[_()]=(h(WM),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(),h(NM),v(),c()}const JM=function(){try{return ZM.apply(this,arguments)}catch(e){if(e!==XM)throw e}};class eA{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 tA={greaterThanOrEqual:"greaterThanOrEqualTo",lessThanOrEqual:"lessThanOrEqualTo"};let nA=null;function iA(e,t,n){let i=new FileReader;i.onload=async function(e){fi.loadAsync(e.target.result).then((async e=>await async function(e,t,n){nA=t.excelImportErrors=[];let i=await async function(e){let t=[];let n=null;return await $A(e,"xl/sharedStrings.xml",{leave:function(){this.is(mA)&&(t.push(n),n=null)},text:function(e){this.is(fA)&&(null==n&&(n=""),n+=e)}}),t}(e);let r=await UA(e,"_rels/workbook.xml");let o=await async function(e,t){let n=[];let i={colorScheme:n};let r=IA(t);e.file(r)&&(await $A(e,r,{enter:function(e,t){this.is(ZA)?n.push(tD("window"===t.val?"FFFFFFFF":"FF000000")):this.is(XA)&&n.push(tD("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]);let a=await async function(e,t){let n={fonts:[],numFmts:{},fills:[],borders:[],namedStyles:[],inlineStyles:[]};let i=null;let r=null;let o=null;let a=null;function s(e){let t={borderId:JA(e.borderId),fillId:JA(e.fillId),fontId:JA(e.fontId),numFmtId:JA(e.numFmtId),pivotButton:eD(e.pivotButton),quotePrefix:eD(e.quotePrefix),xfId:JA(e.xfId)};function n(n){if(null!=e[n])return t[n]=eD(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 tD(e.rgb);if(e.indexed)return QA[JA(e.indexed)];if(e.theme){let i=t.colorScheme[JA(e.theme)];if(!i)return n;let r=_o(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 $A(e,"xl/styles.xml",{enter:function(e,t,c){if(this.is(YA))n.numFmts[t.numFmtId]=t;else if(this.is(qA))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=eD(t.val,!0):"i"===e?i.italic=eD(t.val,!0):"u"===e?i.underline=null==t.val||"single"===t.val:"color"===e&&(i.color=l(t,null));else if(this.is(jA))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,QA[0]));else if(this.is(WA))n.borders.push(o={diagonalUp:+eD(t.diagonalUp,0),diagonalDown:+eD(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,QA[0])}}else this.is(KA)?(a=s(t),n.namedStyles.push(a),c&&(a=null)):this.is(GA)?(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=eD(t.wrapText)),null!=t.indent&&(a.indent=JA(t.indent))):"protection"==e&&(a.protection={locked:eD(t.locked)}))},leave:function(e){this.is(qA)?i=null:this.is(jA)?r=null:this.is(WA)?o=null:"xf"===e&&(a=null)}}),n}(e,o);let s=[];let l=0;await $A(e,"xl/workbook.xml",{enter:function(n,o){if(this.is(uA)){let n=o["r:id"];let l=r.byId[n];let c=o.name;let d=o.state;let h=function(e){let t,n={rows:0,cols:0};return JM(e,{enter:function(e,i){"dimension"===e?(t=mk.parseReference(i.ref),t.bottomRight&&(n.cols=t.bottomRight.col+1,n.rows=t.bottomRight.row+1)):"sheetFormatPr"===e?(i.defaultColWidth&&(n.columnWidth=PA(parseFloat(i.defaultColWidth))),i.defaultRowHeight&&(n.rowHeight=LA(parseFloat(i.defaultRowHeight)))):this.is(dA)&&i.r?n.rows=Math.max(n.rows,+i.r):this.is(rA)&&i.r&&(t=mk.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=h.columnWidth||t.options.columnWidth,t.options.rowHeight=h.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,h.rows),columns:Math.max(t.options.columns||0,h.cols),columnWidth:h.columnWidth,rowHeight:h.rowHeight}})}else this.is(vA)&&o.activeTab&&(l=JA(o.activeTab))},text:function(e){let n=this.is(aA);if(n&&!eD(n.function)&&!eD(n.vbProcedure)){let i=n.localSheetId;let r=null;null!=i&&(r=s[i].options.name);let o=n.name;"_xlnm._FilterDatabase"!==o&&(r&&(o="'"+r.replace(/\'/g,"\\'")+"'!"+o),OA(r,null,(function(){t.defineName(o,e,eD(n.hidden))}),"reading user-defined name: "+o))}}});let c=new eA;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=zA(i,r);let 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 rA=["sheetData","row","c"];let oA=["cols","col"];let aA=["definedNames","definedName"];let sA=["sheetData","row","c","f"];let lA=["mergeCells","mergeCell"];let cA=["sheetViews","sheetView","pane"];let dA=["sheetData","row"];let hA=["sheetViews","sheetView","selection"];let uA=["sheets","sheet"];let pA=["sheetData","row","c","is"];let fA=["t"];let mA=["si"];let gA=["sheetData","row","c","v"];let vA=["bookViews","workbookView"];let _A=["sheetViews","sheetView"];let bA=["hyperlinks","hyperlink"];let wA=["sheetProtection"];let yA=["dataValidations","dataValidation"];let kA=["dataValidations","dataValidation","formula1"];let xA=["dataValidations","dataValidation","formula2"];let CA=["x14:dataValidations","x14:dataValidation"];let SA=["x14:dataValidations","x14:dataValidation","xm:sqref"];let TA=["x14:dataValidations","x14:dataValidation","x14:formula1","xm:f"];let MA=["x14:dataValidations","x14:dataValidation","x14:formula2","xm:f"];let AA=["commentList","comment"];let DA=["authors","author"];let EA=["t"];function IA(e){return/^\//.test(e)?e=e.substr(1):/^xl\//.test(e)||(e="xl/"+e),e}function zA(e,t){let n=new eA;return setTimeout((async function(){await async function(e,t,n,i,r){let o={};let a,s,l,c,d,h;let u=n._columns._count;let p=null;let f=t.replace(/worksheets\//,"worksheets/_rels/");let m=await UA(e,f);let g,v;let _;let b;let w;let y;let k;let x;let C=[];let S=[];if(nA=n._workbook.excelImportErrors,t=IA(t),await $A(e,t,{enter:function(e,t,i){let r;if(this.is(sA))i&&"shared"===t.t&&null!=t.si&&(c=n.range(o[t.si])._get("formula"));else if(this.is(rA)){l=null,c=null,a=t.r,d=null,null==a&&(a=mk.parseReference(p),a.col++,a=a.toString()),p=a,s=t.t;let e=t.s;null!=e&&S.push({ref:a,sty:+e})}else if(this.is(lA))n.range(t.ref).merge();else if(this.is(oA)){let e=JA(t.min)-1;let i=Math.min(u,JA(t.max))-1;let r;if(t.width&&(r=PA(parseFloat(t.width)),0!==r&&n._columns.values.value(e,i,r)),"1"===t.hidden||0===r)for(let t=e;t<=i;t++)n.hideColumn(t);null!=t.style&&S.unshift({ref:new Ty(new Sy(-1/0,e),new Sy(1/0,i)),sty:+t.style})}else if(this.is(dA)){let e=JA(t.r)-1;let i;t.ht&&(i=LA(parseFloat(t.ht)),0!==i&&n._rows.values.value(e,e,i)),"1"!==t.hidden&&0!==i||n.hideRow(e)}else if(this.is(hA)){if(t.activeCell){let e=mk.parseReference(t.activeCell);n.select(e,!0)}}else if(this.is(cA))t.state&&t.state.indexOf("frozen")>-1&&(t.xSplit&&n.frozenColumns(JA(t.xSplit)),t.ySplit&&n.frozenRows(JA(t.ySplit)));else if(this.is(_A))n.showGridLines(eD(t.showGridLines,!0));else if(this.is(bA)){let e=t["r:id"];let i=m.byId[e];i&&n.range(t.ref).link(i)}else this.is(wA)?t.sheet&&n.range(Dy).enable(!1):this.is(["autoFilter"])?(_=t.ref,i&&T()):_&&(this.is(["filterColumn"])?b=parseInt(t.colId,10):this.is(["customFilters"])?(w=eD(t.and)?"and":"or",y=[]):this.is(["customFilter"])?(r=function(e,t){let n={equal:"eq",notEqual:"ne",greaterThan:"gt",greaterThanOrEqual:"gte",lessThan:"lt",lessThanOrEqual:"lte"}[e];if(t=FA(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&&y.push({operator:r.operator,value:r.value})):this.is(["dynamicFilter"])?C.push({column:b,filter:new yS({type:RA(t.type)})}):this.is(["top10"])?C.push({column:b,filter:new wS({value:FA(t.val),type:function(e,t){return e&&t?"topPercent":t?"topNumber":e?"bottomPercent":"bottomNumber"}(eD(t.percent),eD(t.top))})}):this.is(["filters"])?(k=eD(t.blank),x=[]):this.is(["filter"])&&x.push(FA(t.val)))},leave:function(e,t){if(this.is(sA))c||"shared"!==t.t||null==t.si||(c=n.range(o[t.si])._get("formula"));else if(this.is(rA)){if(null!=c){OA(n,d||a,(function(){n.range(d||a).formula(c,h)}),"parsing formula")&&n.range(d||a).value(c).background("#ffaaaa")}else if(null!=l){let e=n.range(a);e._get("formula")||(s&&"n"!==s?"s"===s?l=i[JA(l)]:"b"===s?l="1"===l:"d"===s&&(l=pk().parseDate(l)):l=parseFloat(l),null!=l&&e.value(l))}}else this.is(yA)||this.is(CA)?function(){let e=mk.parseSqref(t.sqref);let i=t.type.toLowerCase();let r=t.operator;/^(?:whole|decimal)$/.test(i)?i="number":"list"===i&&(r="list"),!r&&/^(?:number|date)$/.test(i)&&(r="between"),e.forEach((function(e){OA(n,e,(function(){n.range(e).validation({type:eD(t.showErrorMessage,!0)?"reject":"warning",from:g,to:v,dataType:i,comparerType:tA[r]||r,allowNulls:eD(t.allowBlank),showButton:eD(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():_&&("customFilters"===e?C.push({column:b,filter:new bS({logic:w,criteria:y})}):"filters"===e&&C.push({column:b,filter:new _S({values:x,blanks:k})}))},text:function(e){let t;this.is(gA)||this.is(pA)?l=e:(t=this.is(sA))?(c=e,h="array"===t.t,h?d=t.ref:"shared"===t.t&&(o[t.si]=a)):this.is(kA)||this.is(TA)?g=e:this.is(xA)||this.is(MA)?v=e:this.is(SA)&&(this.stack[this.stack.length-2].sqref=e)}}),S.forEach((({ref:e,sty:t})=>function(e,t,n,i){let r=e.range(t);let o,a,s=n.inlineStyles[i];s.xfId&&(o=n.namedStyles[s.xfId]);u("applyBorder","borderId")&&h(n.borders[a]);u("applyFont","fontId")&&d(n.fonts[a]);u("applyAlignment","textAlign")&&r.textAlign(a);u("applyAlignment","verticalAlign")&&r.verticalAlign(a);u("applyAlignment","indent")&&r.indent(a);u("applyAlignment","wrapText")&&r._property("wrap",a);u("applyFill","fillId")&&c(n.fills[a]);u("applyNumberFormat","numFmtId")&&l(n.numFmts[a]||NA[a]);u("applyProtection","protection")&&r.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]+\]/,""),r.format(t))}function c(e){"solid"===e.type&&r.background(e.color)}function d(e){r.fontFamily(e.name),e.size&&r._property("fontSize",4*e.size/3),e.bold&&r.bold(!0),e.italic&&r.italic(!0),e.underline&&r.underline(!0),e.color&&r.color(e.color)}function h(e){function t(t,n){let i=e[t];if(!i)return;let o=VA[i.style];if(!o)return;let a=i.color;null==a&&(a="#000");let s={size:o,color:a};"diagonal"===t&&(s.type=i.up<<1|i.down),r._property(n,s)}t("left","borderLeft"),t("top","borderTop"),t("right","borderRight"),t("bottom","borderBottom"),t("diagonal","dBorders")}function u(e,t){let n=s[e];if(null!=n&&!n)return!1;if(a=s[t],o&&null==a){if(n=o[e],null!=n&&!n)return!1;a=o[t]}return null!=a}}(n,e,r,t))),m.byType.comments){let i=nD(t,m.byType.comments[0]);await async function(e,t,n){let i=[];let r;let o;await $A(e,t,{enter:function(e,t){this.is(AA)?o={author:i[t.authorId],ref:t.ref,text:""}:this.is(DA)&&(r="")},leave:function(){this.is(AA)?n.range(o.ref).comment(o.text):this.is(DA)&&i.push(r)},text:function(e){this.is(EA)?o.text+=e:this.is(DA)&&(r+=e)}})}(e,i,n)}if(m.byType.drawing){let i=nD(t,m.byType.drawing[0]);await async function(e,t,n){let i=["xdr:twoCellAnchor"];let r=["xdr:ext"];let o=["xdr:oneCellAnchor"];let a=["xdr:from"];let s=["xdr:to"];let l=["xdr:row"];let c=["xdr:col"];let d=["xdr:rowOff"];let h=["xdr:colOff"];let u=["xdr:blipFill","a:blip"];let p=t.replace(/drawings\//,"drawings/_rels/");let f=await UA(e,p);if(f.byType.image){let i=Object.keys(f.byId);for(let r=0;r<i.length;++r){let o=i[r];let a=nD(t,f.byId[o]);let s=BA(a);if(s){let t=await e.file(a).async("arraybuffer");let i=HA(a);let r=i&&!Ir.edge?new window.File([t],i,{type:s}):new window.Blob([t],{type:s});f.byId[o]=n._workbook.addImage(r)}}}let m,g,v,_;await $A(e,t,{enter:function(e,t){if(this.is(i)||this.is(o))m={};else if(this.is(a)||this.is(s))g={};else if(this.is(u)){let e=t["r:embed"];m.image=f.byId[e]}else this.is(r)&&(v=iD(parseFloat(t.cx)),_=iD(parseFloat(t.cy)))},leave:function(){if(this.is(a))m.topLeftCell=new Sy(g.row,g.col),m.offsetX=iD(g.colOffset),m.offsetY=iD(g.rowOffset);else if(this.is(s))m.brCell=new Sy(g.row,g.col),m.brX=iD(g.colOffset),m.brY=iD(g.rowOffset);else if(this.is(i)&&m.image){let e=n._columns.sum(0,m.topLeftCell.col-1)+m.offsetX;let t=n._rows.sum(0,m.topLeftCell.row-1)+m.offsetY;let i=n._columns.sum(0,m.brCell.col-1)+m.brX;let r=n._rows.sum(0,m.brCell.row-1)+m.brY;n.addDrawing({topLeftCell:m.topLeftCell,offsetX:m.offsetX,offsetY:m.offsetY,width:null!=v?v:i-e,height:null!=_?_:r-t,image:m.image,opacity:1})}else this.is(o)&&m.image&&n.addDrawing({topLeftCell:m.topLeftCell,offsetX:m.offsetX,offsetY:m.offsetY,width:v,height:_,image:m.image,opacity:1})},text:function(e){this.is(l)?g.row=parseFloat(e):this.is(c)?g.col=parseFloat(e):this.is(d)?g.rowOffset=parseFloat(e):this.is(h)&&(g.colOffset=parseFloat(e))}})}(e,i,n)}function T(){n.range(_).filter(C),_=null}}(t.zip,t.file,e,t.strings,t.styles),n.resolve()}),0),n}function PA(e){return 7*((256*e+Math.floor(128/7))/256)}function LA(e){return e*(4/3)}function BA(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 HA(e){let t=/[^/]+$/.exec(e);return t&&t[0]}function RA(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 FA(e){let t=parseFloat(e);return isNaN(t)||t!==e?e:t}function OA(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)),nA.push(r),!0}}let VA={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};let NA={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 $A(e,t,n){return new window.Promise((i=>{let r=e.file(t);r?r.async("uint8array").then((e=>{JM(e,n),i()})):i()}))}async function UA(e,t){let n={byId:{},byType:{theme:[]},bytes:{}};await $A(e,IA(t)+".rels",{enter:function(e,t){if("Relationship"===e){n.byId[t.Id]=t.Target;let e=t.Type.match(/\w+$/)[0];let i=n.byType[e]||[];i.push(t.Target),n.byType[e]=i}}});let i=[];let r=[];Object.keys(n.byId).forEach((t=>{let o=n.byId[t];let a=e.file(IA(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 WA=["borders","border"];let jA=["fills","fill"];let qA=["fonts","font"];let GA=["cellXfs","xf"];let KA=["cellStyleXfs","xf"];let YA=["numFmts","numFmt"];let QA=[tD("FF000000"),tD("FFFFFFFF"),tD("FFFF0000"),tD("FF00FF00"),tD("FF0000FF"),tD("FFFFFF00"),tD("FFFF00FF"),tD("FF00FFFF"),tD("FF000000"),tD("FFFFFFFF"),tD("FFFF0000"),tD("FF00FF00"),tD("FF0000FF"),tD("FFFFFF00"),tD("FFFF00FF"),tD("FF00FFFF"),tD("FF800000"),tD("FF008000"),tD("FF000080"),tD("FF808000"),tD("FF800080"),tD("FF008080"),tD("FFC0C0C0"),tD("FF808080"),tD("FF9999FF"),tD("FF993366"),tD("FFFFFFCC"),tD("FFCCFFFF"),tD("FF660066"),tD("FFFF8080"),tD("FF0066CC"),tD("FFCCCCFF"),tD("FF000080"),tD("FFFF00FF"),tD("FFFFFF00"),tD("FF00FFFF"),tD("FF800080"),tD("FF800000"),tD("FF008080"),tD("FF0000FF"),tD("FF00CCFF"),tD("FFCCFFFF"),tD("FFCCFFCC"),tD("FFFFFF99"),tD("FF99CCFF"),tD("FFFF99CC"),tD("FFCC99FF"),tD("FFFFCC99"),tD("FF3366FF"),tD("FF33CCCC"),tD("FF99CC00"),tD("FFFFCC00"),tD("FFFF9900"),tD("FFFF6600"),tD("FF666699"),tD("FF969696"),tD("FF003366"),tD("FF339966"),tD("FF003300"),tD("FF333300"),tD("FF993300"),tD("FF993366"),tD("FF333399"),tD("FF333333"),tD("FF000000"),tD("FFFFFFFF")];let XA=["a:clrScheme","*","a:srgbClr"];let ZA=["a:clrScheme","*","a:sysClr"];function JA(e){return null==e?null:parseInt(e,10)}function eD(e,t){return null==e?t:"true"===e||!0===e||1===e||"1"===e}function tD(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 nD(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 iD(e){return e/9525}const rD=["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 oD(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 aD extends OC{constructor(e,t){super(),this.events=rD,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 AM,this.undoRedoStack.bind(["undo","redo"],this._onUndoRedo.bind(this)),this._context=new Rx(this),this._validationContext=new Fx(this),this._names=Object.create(null),this.fromJSON(this.options)}clipboard(){return this._clipboard||(this._clipboard=new bT(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 TC(e,t._sheet).input()}))}_onUndoRedo(e){e.command.range().select()}execute(e){let t=Object.assign({},{workbook:this},e.options);let n;this.options.getWorkbookCommand&&(n=this.options.getWorkbookCommand(e.command,t)),n=n||new MM[e.command](t);let i=this.activeSheet();t.origin&&n.origin(t.origin),t.operatingRange?n.range(t.operatingRange):n.range(i.selection()),t.editRange&&(n._editRange=t.editRange);let r=n.exec();return r&&"error"===r.reason||n.cannotUndo||this.undoRedoStack.push(n),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(zy))}moveSheetToIndex(e,t){let n=this.sheetIndex(e);let 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=this;let n="number"==typeof(e=e||{}).index?e.index:t._sheets.length;let i;let r=t._sheets;const o=this.options.messages;let a=function(e){e=e||1;let n=o.workbook.defaultSheetName+e;return t.sheetByName(n)?a(e+1):n};if(e.name&&t.sheetByName(e.name))return;this._sheetsSearchCache={},i=e.name||a();let s=new ES(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(i),s._state(e.state),this._bindSheetEvents(s),r.splice(n,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;let n=("string"==typeof e?e:e.name()).toLowerCase();let 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 ky||e.value instanceof mk.runtime.Formula)&&e.value.renameSheet(n,t)}.bind(this)),e._name(t),this.trigger("change",{sheetSelection:!0}),e}removeSheet(e){let t=this;let n=t._sheets;let i=e.name();let 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;let t=Object.keys(e._images);let n=t.length;function i(){--n<=0&&e.activeSheet().triggerChange({layout:!0})}n?t.forEach((function(t){let n=e._images[t];n.blob||oD(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];let i=sD(n,this.options);let 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];let n=t.value;return n=n instanceof ky||n instanceof mk.runtime.Formula?n.print(0,0,!0):n instanceof hk?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;let t=e.toJSON();let n=Object.keys(e._images).filter((function(t){return 1===e.usesImage(t)}));let 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 eA;return e&&!this.trigger("excelImport",{file:e,deferred:t})&&(this._clearSheets(),this._readExcel(e,this,t)),t.promise}_readExcel(e,t,n){iA(e,t,n)}saveAsExcel(e){let t=this;e=tk({},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)}));let r=i.length;let 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=>{oD(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(Dy,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];let r=i.value;if(r instanceof ky&&(!r.sheet||r.sheet&&t===r.sheet.toLowerCase())&&String(r)===n)return i}return{name:n}}defineName(e,t,n){let i=mk.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];let a=o.value;a instanceof ky&&a.sheet.toLowerCase()===e?o.value=a.adjust(null,null,null,null,t,n,i):a instanceof mk.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];let 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;let 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 sD(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];let 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 lD=["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:cD,defineBuiltinFunction:dD,limitPrecision:hD,packDate:uD,unpackDate:pD,daysInMonth:fD,daysInYear:mD,isLeapYear:gD}=mk.runtime;function vD(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 _D(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=Ck(e,15),t=Ck(t,15)):new hk("VALUE")}function bD(e){return(Math.exp(e)+Math.exp(-e))/2}function wD(e){return(Math.exp(e)-Math.exp(-e))/2}function yD(e){return wD(e)/bD(e)}function kD(e,t){for(;t;){var n=e%t;e=t,t=n}return e}function xD(e,t){return Math.abs(e*t)/kD(e,t)}function CD(e,t){var n=[],i=0,r=e[0];for(;i<e.length;)n.push({matrix:e[i++],pred:WD(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 SD(e){return function(t,n,i,r){var o=this;if(r instanceof ky){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 TD(e,t,n){var i=[];var r=e.each((function(e){if(e instanceof hk)return e;"number"==typeof e&&i.push(e)}));return r||(t>i.length?new hk("NUM"):i.sort(n)[t-1])}function MD(e){return e.reduce((function(e,t){return e+t}),0)/e.length}function AD(e,t,n){return null==n&&(n=MD(e)),e.reduce((function(e,t){return e+Math.pow(t-n,2)}),0)/t}function DD(e,t){return Math.sqrt(AD(e,t))}function ED(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)*ED(e,o,n)+(t-o)*ED(e,a,n))/(a-o):new hk("N/A")}function ID(e,t,n){var i=0;var r=MD(e);var o=MD(t);var a=e.length;for(var s=0;s<a;++s)i+=(e[s]-r)*(t[s]-o);return i/n}dD("binary+",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),dD("binary-",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),dD("binary*",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),dD("binary/",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||0==a&&(r="DIV/0",1)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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;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]);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})),dD("binary^",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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)})),dD("binary&",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),dD("binary=",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(r=this.force(r),!(n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 vD(e,t)})),dD("binary<>",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(r=this.force(r),!(n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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!vD(e,t)})),dD("binary<",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(r=this.force(r),!(n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 _D(e,t,((e,t)=>e<t))})),dD("binary<=",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(r=this.force(r),!(n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 _D(e,t,((e,t)=>e<=t))})),dD("binary>",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(r=this.force(r),!(n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 _D(e,t,((e,t)=>e>t))})),dD("binary>=",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(r=this.force(r),!(n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 _D(e,t,((e,t)=>e>=t))})),dD("unary+",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.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 hk("N/A"):n):r instanceof hk?r:new hk("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;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){return e})),dD("unary-",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.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 hk("N/A"):n):r instanceof hk?r:new hk("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;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){return-e})),dD("unary%",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.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 hk("N/A"):n):r instanceof hk?r:new hk("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;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){return e/100})),dD("binary:",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(!(r instanceof Sy))return new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:o instanceof Sy?(t.push(o),2<e.length?new hk("N/A"):t):new hk(i)}},(function(e,t){return new Ty(e,t).setSheet(e.sheet||this.formula.sheet,e.hasSheet())})),dD("binary,",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(!(r instanceof ky))return new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:o instanceof ky?(t.push(o),2<e.length?new hk("N/A"):t):new hk(i)}},(function(e,t){return new My([e,t])})),dD("binary ",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(!(r instanceof ky))return new hk(i);t.push(r);var o=e[n++];return o instanceof hk?o:o instanceof ky?(t.push(o),2<e.length?new hk("N/A"):t):new hk(i)}},(function(e,t){return e.intersect(t)})),dD("not",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:null!=(i=this.force(i))&&1<=e.length||null==i&&(i=0,1)?(t.push(i),1<e.length?new hk("N/A"):t):i instanceof hk?i:new hk("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;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){return!this.bool(e)})),dD("isblank",!1,{check:function(e){var t=[],n=0;var i=e[n++];return 1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("VALUE")},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;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){return e instanceof Sy&&null==(e=this.getRefData(e))})),dD("iserror",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return e instanceof hk})),dD("iserr",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return e instanceof hk&&"N/A"!=e.code})),dD("isna",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return e instanceof hk&&"N/A"==e.code})),dD("islogical",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return"boolean"==typeof e})),dD("isnontext",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return"string"!=typeof e})),dD("istext",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return"string"==typeof e})),dD("isnumber",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("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;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){return"number"==typeof e})),dD("isref",!1,{check:function(e){var t=[],n=0;var i=e[n++];return 1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):new hk("VALUE")},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;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){return e instanceof Sy||e instanceof Ty})),dD("_matrix",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?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 hk("N/A"):n):r instanceof hk?r:new hk("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})),cD[",getname"]=function(e,t){this.fetchName(t[0],e)},dD("abs",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.abs),dD("cos",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.cos),dD("sin",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.sin),dD("acos",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.acos),dD("asin",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.asin),dD("tan",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.tan),dD("atan",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.atan),dD("exp",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.exp),dD("sqrt",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.sqrt),dD("ln",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.log),dD("log",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk(r):2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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)})),dD("log10",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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;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){return Math.log(e)/Math.log(10)})),dD("pi",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return Math.PI})),dD("sqrtpi",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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;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){return Math.sqrt(e*Math.PI)})),dD("degrees",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return 180*e/Math.PI%360})),dD("radians",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return Math.PI*e/180})),dD("cosh",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},bD),dD("acosh",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:"number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n:new hk(r)):o instanceof hk?o:new hk(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;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){return Math.log(e+Math.sqrt(e-1)*Math.sqrt(e+1))})),dD("sinh",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},wD),dD("asinh",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return Math.log(e+Math.sqrt(e*e+1))})),dD("sec",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return 1/Math.cos(e)})),dD("sech",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return 1/bD(e)})),dD("csc",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return 1/Math.sin(e)})),dD("csch",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return 1/wD(e)})),dD("atan2",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||0==o&&(r="DIV/0",1))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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)})),dD("tanh",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},yD),dD("atanh",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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;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){return Math.log(Math.sqrt(1-e*e)/(1-e))})),dD("cot",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||0==o&&(r="DIV/0",1)?o instanceof hk?o:new hk(r):(n.push(o),1<e.length?new hk("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;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){return 1/Math.tan(e)})),dD("coth",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||0==o&&(r="DIV/0",1)?o instanceof hk?o:new hk(r):(n.push(o),1<e.length?new hk("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;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){return 1/yD(e)})),dD("acot",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return Math.PI/2-Math.atan(e)})),dD("acoth",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:"number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n:new hk(r)):o instanceof hk?o:new hk(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;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){return Math.log((e+1)/(e-1))/2})),dD("power",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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)})),dD("mod",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||0==a&&(r="DIV/0",1)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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;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]);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})),dD("quotient",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||0==a&&(r="DIV/0",1)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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;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]);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)})),dD("ceiling",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n:new hk(r)):a instanceof hk?a:new hk(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;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]);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})),dD("ceiling.precise",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),mk.runtime.defineAlias("iso.ceiling","ceiling.precise"),dD("ceiling.math",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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})),dD("floor",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n:new hk(r)):a instanceof hk?a:new hk(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;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]);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})),dD("floor.precise",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),dD("floor.math",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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})),dD("int",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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}}},Math.floor),dD("mround",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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})),dD("round",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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=hD(e*t),n*(e=Math.round(e))/t})),dD("roundup",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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=hD(e*t))<0?Math.floor(e):Math.ceil(e))/t})),dD("rounddown",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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=hD(e*t))<0?Math.ceil(e):Math.floor(e))/t})),dD("even",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){var t=e<0?Math.floor(e):Math.ceil(e);return t%2?t+(t<0?-1:1):t})),dD("odd",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){var t=e<0?Math.floor(e):Math.ceil(e);return t%2?t:t+(t<0?-1:1)})),dD("sign",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return e<0?-1:e>0?1:0})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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=e[0];for(var n=1;n<e.length;++n)t=kD(t,e[n]);return t})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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=e[0];for(var n=1;n<e.length;++n)t=xD(t,e[n]);return t})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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)})),dD("sumproduct",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE";var s=e[o++];if(s instanceof hk)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof hk?s:new hk(a);if(r.push(s),o>=e.length)return new hk("N/A");r.push(t=[]),i.push(r),r=t;do{var l=e[o++];if(l instanceof hk)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 hk?l:new hk(a);r.push(l)}while(o<e.length);return r=i.pop(),o<e.length?new hk("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})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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)})),dD("sumx2my2",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?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 hk?a:new hk(r):(n.push(a),2<e.length?new hk("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})),dD("sumx2py2",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?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 hk?a:new hk(r):(n.push(a),2<e.length?new hk("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})),dD("sumxmy2",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?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 hk?a:new hk(r):(n.push(a),2<e.length?new hk("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})),dD("seriessum",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(o);i.push(a);var s=e[r++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof hk?s:new hk(o);i.push(s);var l=e[r++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))))return l instanceof hk?l:new hk(o);i.push(l);var c=e[r++];return c instanceof hk?c:(n=this.asMatrix(c))&&(c=n)?(i.push(c),4<e.length?new hk("N/A"):i):c instanceof hk?c:new hk(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 hk("VALUE");r+=i*Math.pow(e,t),t+=n})),r})),dD("min",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(e,t){if(t instanceof hk)throw t;return"number"==typeof t&&(t=hD(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof hk)return e;throw e}return n<e.length?new hk("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})),dD("max",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(e,t){if(t instanceof hk)throw t;return"number"==typeof t&&(t=hD(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof hk)return e;throw e}return n<e.length?new hk("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})),dD("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 hk)return e;throw e}return n<e.length?new hk("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})),dD("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=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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})),dD("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 hk)return e;throw e}return n<e.length?new hk("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})),dD("countblank",!1,{check:function(e){var t,n,i=[],r=[],o=0;if(o>=e.length)return new hk("N/A");r.push(t=[]),i.push(r),r=t;do{var a=e[o++];if(a instanceof hk)return a;if(!((n=this.asMatrix(a))&&(a=n)||null!=a&&o<=e.length))return a instanceof hk?a:new hk("VALUE");r.push(a)}while(o<e.length);return r=i.pop(),o<e.length?new hk("N/A"):r},resolve:function(e,t){var n=[],i=0;for(;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 bk?i.each(n,!0):n(i)}}(e),t})),dD("iseven",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return e%2==0})),dD("isodd",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return e%2!=0})),dD("n",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:null!=(i=this.force(i))&&1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):i instanceof hk?i:new hk("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;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){return"boolean"==typeof e?e?1:0:"number"==typeof e?e:0})),dD("na",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return new hk("N/A")})),dD("countifs",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE";var s=e[o++];if(s instanceof hk)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof hk?s:new hk(a);r.push(s);var l=e[o++];if(l instanceof hk)return l;if(!(null!=(l=this.force(l))&&o<=e.length))return l instanceof hk?l:new hk(a);for(r.push(l),r.push(t=[]),i.push(r),r=t;o<e.length;){var c=e[o++];if(c instanceof hk)return c;if(!(n=this.asMatrix(c))||!(c=n))return c instanceof hk?c:new hk(a);r.push(c);var d=e[o++];if(d instanceof hk)return d;if(!(null!=(d=this.force(d))&&o<=e.length))return d instanceof hk?d:new hk(a);r.push(d)}return r=i.pop(),o<e.length?new hk("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),CD(n,(function(){i++})),i})),dD("sumifs",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE";var s=e[o++];if(s instanceof hk)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof hk?s:new hk(a);r.push(s);var l=e[o++];if(l instanceof hk)return l;if(!(n=this.asMatrix(l))||!(l=n))return l instanceof hk?l:new hk(a);r.push(l);var c=e[o++];if(c instanceof hk)return c;if(!(null!=(c=this.force(c))&&o<=e.length))return c instanceof hk?c:new hk(a);for(r.push(c),r.push(t=[]),i.push(r),r=t;o<e.length;){var d=e[o++];if(d instanceof hk)return d;if(!(n=this.asMatrix(d))||!(d=n))return d instanceof hk?d:new hk(a);r.push(d);var h=e[o++];if(h instanceof hk)return h;if(!(null!=(h=this.force(h))&&o<=e.length))return h instanceof hk?h:new hk(a);r.push(h)}return r=i.pop(),o<e.length?new hk("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,jD,t,n);var r=0;return CD(i,(function(t,n){var i=e.get(t,n);i&&(r+=i)})),r})),dD("averageifs",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE";var s=e[o++];if(s instanceof hk)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof hk?s:new hk(a);r.push(s);var l=e[o++];if(l instanceof hk)return l;if(!(n=this.asMatrix(l))||!(l=n))return l instanceof hk?l:new hk(a);r.push(l);var c=e[o++];if(c instanceof hk)return c;if(!(null!=(c=this.force(c))&&o<=e.length))return c instanceof hk?c:new hk(a);for(r.push(c),r.push(t=[]),i.push(r),r=t;o<e.length;){var d=e[o++];if(d instanceof hk)return d;if(!(n=this.asMatrix(d))||!(d=n))return d instanceof hk?d:new hk(a);r.push(d);var h=e[o++];if(h instanceof hk)return h;if(!(null!=(h=this.force(h))&&o<=e.length))return h instanceof hk?h:new hk(a);r.push(h)}return r=i.pop(),o<e.length?new hk("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,jD,t,n);var r=0,o=0;return CD(i,(function(t,n){var i=e.get(t,n);null!=i&&""!==i||(i=0),r+=i,o++})),o?r/o:new hk("DIV/0")})),dD("countif",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:null!=(a=this.force(a))&&2<=e.length?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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=WD(t);var n=0;return e.each((function(e){t(e)&&n++})),n})),dD("sumif",!0,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!(null!=(a=this.force(a))&&i<=e.length))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:s instanceof Sy||s instanceof Ty||(t=this.asMatrix(s))&&(s=t)||null==(s=this.force(s))&&(s=o,1)?(n.push(s),i<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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}}},SD((function(e,t,n){var i=0;return t=WD(t),e.each((function(e,r,o){if(t(e)){var a=n.get(r,o);jD(a)&&(i+=a||0)}})),i}))),dD("averageif",!0,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!(null!=(a=this.force(a))&&i<=e.length))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:s instanceof Sy||s instanceof Ty||(t=this.asMatrix(s))&&(s=t)||null==(s=this.force(s))&&(s=o,1)?(n.push(s),i<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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}}},SD((function(e,t,n){var i=0,r=0;return t=WD(t),e.each((function(e,o,a){if(t(e)){var s=n.get(o,a);jD(s)&&(i+=s||0,r++)}})),r?i/r:new hk("DIV/0")}))),dD("large",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!(n=this.asMatrix(a))||!(a=n))return a instanceof hk?a:new hk(o);i.push(a);var s=e[r++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):i):s instanceof hk?s:new hk(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 TD(e,t,GD)})),dD("small",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!(n=this.asMatrix(a))||!(a=n))return a instanceof hk?a:new hk(o);i.push(a);var s=e[r++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):i):s instanceof hk?s:new hk(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 TD(e,t,qD)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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 DD(e,e.length-1)})),dD("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 hk)throw t;return"number"==typeof t&&(t=hD(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(r)}catch(e){if(e instanceof hk)return e;throw e}return r.length>=1||(i="NUM",0)?n<e.length?new hk("N/A"):t:new hk(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 DD(e,e.length)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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 AD(e,e.length-1)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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 AD(e,e.length)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>0||(r="N/A",0)?i<e.length?new hk("N/A"):n:new hk(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(qD),t%2?e[t>>1]:(e[t>>=1]+e[t-1])/2})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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(qD);var t=null,n=0,i=1,r=null;for(var 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 hk("N/A"):r})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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 bk(this);return i.forEach((function(e,t){r.set(t,0,e)})),r})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>0||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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;var n=e.reduce((function(e,t){if(t<0)throw new hk("NUM");return e*t}),1);return Math.pow(n,1/t)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>0||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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 hk("DIV/0");return e+1/t}),0)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n:new hk(r)):a instanceof hk?a:new hk(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(qD);var i=Math.floor(n*t);i%2&&--i;var r=0;for(var o=i/=2;o<n-i;++o)r+=e[o];return r/(n-2*i)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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(qD),t.sort(qD);var n=-1/0;var i=0;function r(t){var r=0;for(;i<e.length&&e[i]>n&&e[i]<=t;)++r,++i;return r}var o=new bk(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})),dD("rank.eq",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var s=e[i++];return s instanceof hk?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 hk("N/A"):n):s instanceof hk?s:new hk(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?qD:GD);var i=t.indexOf(e);return i<0?new hk("N/A"):i+1})),mk.runtime.defineAlias("rank","rank.eq"),dD("rank.avg",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);try{var a=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var s=e[i++];return s instanceof hk?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 hk("N/A"):n):s instanceof hk?s:new hk(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?qD:GD);var i=t.indexOf(e);if(i<0)return new hk("N/A");for(var r=i;t[r]==e;++r);return(i+r+1)/2})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>=4||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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;var n=MD(e);var i=AD(e,t-1,n);var 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))})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):s instanceof hk?s:new hk(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=ED(e,t,0);return i=i.toFixed(n+1),parseFloat(i.substr(0,i.length-1))})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):s instanceof hk?s:new hk(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=ED(e,t,1);return i=i.toFixed(n+1),parseFloat(i.substr(0,i.length-1))})),mk.runtime.defineAlias("percentrank","percentrank.inc"),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length!=a.length&&(r="N/A",1)?new hk(r):o.length>0||(r="DIV/0",0)?i<e.length?new hk("N/A"):n:new hk(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 ID(e,t,e.length)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length!=a.length&&(r="N/A",1)?new hk(r):o.length>1||(r="DIV/0",0)?i<e.length?new hk("N/A"):n:new hk(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 ID(e,t,e.length-1)})),mk.runtime.defineAlias("covar","covariance.p");var zD=Qy((function(e){for(var t=2,n=1;t<=e;++t)n*=t;return n}));dD("fact",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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;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}}},zD),dD("factdouble",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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;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){for(var t=2+(1&e),n=1;t<=e;t+=2)n*=t;return n})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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 hk("NUM");n+=e,t*=zD(e)})),zD(n)/t}));var PD=Qy((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 LD(e,t){e.sort(qD);var n=e.length;var 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 BD(e,t){return LD(e,t*(e.length-1)+1)}function HD(e,t){return LD(e,t*(e.length+1))}dD("combin",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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}}},PD),dD("combina",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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 PD(e+t-1,e-1)})),dD("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 hk)throw t;return"number"==typeof t&&(t=hD(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(r)}catch(e){if(e instanceof hk)return e;throw e}return r.length>0||(i="DIV/0",0)?n<e.length?new hk("N/A"):t:new hk(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})),dD("averagea",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(t,i){if(i instanceof hk)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 hk)return e;throw e}return n<e.length?new hk("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 hk("DIV/0")})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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)}},BD),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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)}},HD),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var o=e[i++];return o instanceof hk?o:0!==(o=this.force(o))&&1!==o&&2!==o&&3!==o&&4!==o?o instanceof hk?o:new hk("VALUE"):(n.push(o),i<e.length?new hk("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 BD(e,t/4)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var o=e[i++];return o instanceof hk?o:0!==(o=this.force(o))&&1!==o&&2!==o&&3!==o&&4!==o?o instanceof hk?o:new hk("VALUE"):(n.push(o),i<e.length?new hk("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 HD(e,t/4)})),mk.runtime.defineAlias("quartile","quartile.inc"),mk.runtime.defineAlias("percentile","percentile.inc");var RD=["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 FD(e,t,n){var i=[];return function t(r){if(r instanceof ky)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 hk||("number"==typeof t||t instanceof hk)&&i.push(t)}}));else if(Array.isArray(r))for(var o=0;o<r.length;++o)t(r[o]);else r instanceof bk?r.each(t):("number"==typeof r||r instanceof hk&&!(2&n))&&i.push(r)}(t),i}function OD(e,t,n,i){if(i){var r=0;for(var o=0;o<=e;++o)r+=PD(t,o)*Math.pow(n,o)*Math.pow(1-n,t-o);return r}return PD(t,e)*Math.pow(n,e)*Math.pow(1-n,t-e)}function VD(e){var t=pD(uD(e,0,1));return 4==t.day||3==t.day&&mk.runtime.isLeapYear(e)?53:52}function ND(e,t,n){var i=pD(e);var r=pD(t);return n?(31==i.date&&(i.date=30),31==r.date&&(r.date=30)):(1==i.month&&1==r.month&&i.date==fD(i.year,1)&&r.date==fD(r.year,1)&&(r.date=30),i.date==fD(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)}dD("aggregate",!0,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)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 hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?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 hk("N/A"):t):o instanceof hk?o:new hk(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=FD(r,i[0],n);var a=i[1];if(a instanceof Sy&&(a=r.getRefData(a)),"number"!=typeof a)return e(new hk("VALUE"))}else o=FD(r,i,n);r.func(RD[t-1],e,o)}))})),dD("subtotal",!0,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE";var s=e[o++];if(s instanceof hk)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 hk?s:new hk(a);if(r.push(s),o>=e.length)return new hk("N/A");r.push(t=[]),i.push(r),r=t;do{var l=e[o++];if(l instanceof hk)return l;if(!(l instanceof ky||(n=this.asMatrix(l))&&(l=n)))return new hk(a);r.push(l)}while(o<e.length);return r=i.pop(),o<e.length?new hk("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;var i=t>100;i&&(t-=100);var r=[];for(var o=2;o<arguments.length;++o)r.push(arguments[o]);n.resolveCells(r,(function(){var o=FD(n,r,i?1:0);n.func(RD[t-1],e,o)}))})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new hk("N/A"):n:new hk(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})),dD("binom.dist",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!(("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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)}},OD),mk.runtime.defineAlias("binomdist","binom.dist"),dD("binom.inv",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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(OD(i,e,t,!0)>=n)return i;return new hk("N/A")})),mk.runtime.defineAlias("critbinom","binom.inv"),dD("binom.dist.range",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!(("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk("N/A"):n):l instanceof hk?l:new hk(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=0;for(var o=n;o<=i;++o)r+=PD(e,o)*Math.pow(t,o)*Math.pow(1-t,e-o);return r})),dD("negbinom.dist",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>=0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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){var r=0;for(;e>=0;)r+=PD(e+t-1,e)*Math.pow(n,t)*Math.pow(1-n,e),e--;return r}return PD(e+t-1,e)*Math.pow(n,t)*Math.pow(1-n,e)})),mk.runtime.defineAlias("negbinomdist","negbinom.dist"),dD("address",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!(null==(s=this.force(s))&&(s=1,1)||1===s||2===s||3===s||4===s))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!(null==(l=this.force(l))&&(l=!0,1)||"boolean"==typeof l||"number"==typeof l&&(l=!!l,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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 hk("N/A"):n):c instanceof hk?c:new hk(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 Sy(e-1,t-1,n-1);return r&&o.setSheet(r,!0),i?o.print(0,0):o.print()})),dD("areas",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:i instanceof ky?(t.push(i),1<e.length?new hk("N/A"):t):new hk("VALUE")}},(function(e){var t=0;return function e(n){n instanceof Sy||n instanceof Ty?t++:n instanceof My&&n.refs.forEach(e)}(e),t})),dD("choose",!1,{check:function(e){var t,n=[],i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(o);if(i.push(a),r>=e.length)return new hk("N/A");i.push(t=[]),n.push(i),i=t;do{var s=e[r++];if(s instanceof hk)return s;if(!(r<=e.length))return new hk(o);i.push(s)}while(r<e.length);return i=n.pop(),r<e.length?new hk("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;var 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 hk("N/A"):t[e-1]})),dD("column",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:i instanceof Sy||i instanceof Ty||null==(i=this.force(i))?(t.push(i),1<e.length?new hk("N/A"):t):i instanceof hk?i:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e?e instanceof Sy?e.col+1:this.asMatrix(e).mapCol((function(t){return t+e.topLeft.col+1})):this.formula.col+1})),dD("columns",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:r instanceof Sy||r instanceof Ty||(t=this.asMatrix(r))&&(r=t)?(n.push(r),1<e.length?new hk("N/A"):n):new hk("VALUE")}},(function(e){return e instanceof ky?e.width():e.width})),dD("formulatext",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:i instanceof ky?(t.push(i),1<e.length?new hk("N/A"):t):new hk("VALUE")}},(function(e){var t=this.getRefCells(e)[0];return t.formula?t.formula.print(t.row,t.col):new hk("N/A")})),dD("hlookup",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!(null!=(a=this.force(a))&&r<=e.length))return a instanceof hk?a:new hk(o);i.push(a);var s=e[r++];if(s instanceof hk)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof hk?s:new hk(o);i.push(s);var l=e[r++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!((l|=0)>0||(o="NUM",0)))return l instanceof hk?l:new hk(o);i.push(l);var c=e[r++];return c instanceof hk?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 hk("N/A"):i):c instanceof hk?c:new hk(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 hk("N/A"):t.get(n-1,r)})),dD("index",!0,{check:function(e){var t,n,i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!(a instanceof ky||(n=this.asMatrix(a))&&(a=n)))return a instanceof hk?a:new hk(o);i.push(a);var s=e[r++];if(s instanceof hk)return s;if(!(("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(o);i.push(s);var l=e[r++];if(l instanceof hk)return l;if(!(("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk?l:new hk(o);i.push(l);var c=e[r++];return c instanceof hk?c:("number"==typeof(c=this.force(c))||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.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 hk("N/A"):i):c instanceof hk?c:new hk(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 My&&(t=t.refs[r-1]),!n&&!i||!t)return e(new hk("N/A"));if(t instanceof Sy&&(t=t.toRangeRef()),t instanceof Ty){if(n&&i){if(i>t.width()||n>t.height())return e(new hk("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 bk){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 hk("REF"))})),dD("indirect",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){try{var t=this.formula;var n=mk.parseFormula(t.sheet,t.row,t.col,e).ast;if(n instanceof Cy&&(n=this.ss.nameValue(n,t.sheet,t.row,t.col)),!(n instanceof ky))throw 1;return n.absolute(t.row,t.col)}catch(e){return new hk("REF")}})),dD("match",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(null!=(o=this.force(o))&&i<=e.length))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!(t=this.asMatrix(a))||!(a=t))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:-1===(s=this.force(s))||0===s||1===s||null==s&&(s=1,1)?(n.push(s),i<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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=WD(e):-1===n?i=WD("<="+e):1===n&&(i=WD(">="+e)),t.each((function(t){if(null!=t&&i(t))return 0!==n&&e!=t&&--r,!0;r++}),!0)&&r>0?r:new hk("N/A")})),dD("offset",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(o instanceof Sy||o instanceof Ty))return new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!(("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:("number"==typeof(c=this.force(c))||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.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 hk("N/A"):n):c instanceof hk?c:new hk(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 Sy?e:e.topLeft).clone();return o.row+=t,o.col+=n,o.row<0||o.col<0?new hk("VALUE"):i>1||r>1?new Ty(o,new Sy(o.row+i-1,o.col+r-1)).setSheet(e.sheet,e.hasSheet()):o})),dD("row",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:i instanceof Sy||i instanceof Ty||null==(i=this.force(i))?(t.push(i),1<e.length?new hk("N/A"):t):i instanceof hk?i:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e?e instanceof Sy?e.row+1:this.asMatrix(e).mapRow((function(t){return t+e.topLeft.row+1})):this.formula.row+1})),dD("rows",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:r instanceof Sy||r instanceof Ty||(t=this.asMatrix(r))&&(r=t)?(n.push(r),1<e.length?new hk("N/A"):n):new hk("VALUE")}},(function(e){return e instanceof ky?e.height():e.height})),dD("vlookup",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE";var a=e[r++];if(a instanceof hk)return a;if(!(null!=(a=this.force(a))&&r<=e.length))return a instanceof hk?a:new hk(o);i.push(a);var s=e[r++];if(s instanceof hk)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof hk?s:new hk(o);i.push(s);var l=e[r++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!((l|=0)>0||(o="NUM",0)))return l instanceof hk?l:new hk(o);i.push(l);var c=e[r++];return c instanceof hk?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 hk("N/A"):i):c instanceof hk?c:new hk(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 hk("N/A"):t.get(r,n-1)})),dD("date",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)?s instanceof hk?s:new hk(r):(n.push(s),3<e.length?new hk("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;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]);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 uD(e,t-1,n)})),dD("day",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof hk?r:new hk("VALUE"):(n.push(r),1<e.length?new hk("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;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){return pD(e).date})),dD("month",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof hk?r:new hk("VALUE"):(n.push(r),1<e.length?new hk("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;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){return pD(e).month+1})),dD("year",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof hk?r:new hk("VALUE"):(n.push(r),1<e.length?new hk("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;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){return pD(e).year})),dD("weekday",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof hk?r:new hk("VALUE"):(n.push(r),1<e.length?new hk("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;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){return pD(e).day+1})),dD("weeknum",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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=uD(pD(e).year,0,1);var i=pD(n);var r;return 21==t?((r=3-(i.day+6)%7)<0&&(r+=7),n+=r,i.date+=r,i.day=4,t=1):t=1==t?0:2==t?1:(t-10)%7,(r=i.day-t)<0&&(r+=7),n-=r,Math.ceil((e+1-n)/7)})),dD("isoweeknum",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof hk?r:new hk("VALUE"):(n.push(r),1<e.length?new hk("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;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){var t=pD(e);var n=t.day||7;var i=Math.floor((t.ord-n+10)/7);return i<1?VD(t.year-1):53==i&&i>VD(t.year)?1:i})),dD("now",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return mk.runtime.dateToSerial(new Date)})),dD("today",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return 0|mk.runtime.dateToSerial(new Date)})),dD("time",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)?s instanceof hk?s:new hk(r):(n.push(s),3<e.length?new hk("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;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]);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 mk.runtime.packTime(e,t,n,0)})),dD("hour",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return mk.runtime.unpackTime(e).hours})),dD("minute",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return mk.runtime.unpackTime(e).minutes})),dD("second",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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;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){return mk.runtime.unpackTime(e).seconds})),dD("edate",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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;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]);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=pD(e);var i=n.month+t;var r=n.year+Math.floor(i/12);return(i%=12)<0&&(i+=12),n=Math.min(n.date,fD(r,i)),uD(r,i,n)})),dD("eomonth",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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;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]);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=pD(e);var i=n.month+t;var r=n.year+Math.floor(i/12);return(i%=12)<0&&(i+=12),n=fD(r,i),uD(r,i,n)})),dD("workday",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);try{var s=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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);var r=pD(e).day;for(;t>0;)e+=i,(r=(r+i)%7)>0&&r<6&&n.indexOf(e)<0&&--t;return e})),dD("networkdays",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);try{var s=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return i<e.length?new hk("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}var r=0;var o=pD(e).day;for(;e<=t;)o>0&&o<6&&n.indexOf(e)<0&&r++,e++,o=(o+1)%7;return r})),dD("days",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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;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]);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})),mk.runtime._days_360=ND,dD("days360",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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}}},ND),dD("yearfrac",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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 ND(e,t,!1)/360;case 1:return(t-e)/mD(pD(e).year);case 2:return(t-e)/360;case 3:return(t-e)/365;case 4:return ND(e,t,!0)/360}})),dD("datevalue",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){var t=mk.runtime.parseDate(e);return t?mk.runtime.dateToSerial(t):new hk("VALUE")})),dD("timevalue",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){var t=e.toLowerCase().match(/(\d+):(\d+)(:(\d+)(\.(\d+))?)?\s*(am?|pm?)?/);if(t){var n=parseFloat(t[1]);var i=parseFloat(t[2]);var r=t[3]?parseFloat(t[4]):0;var o=t[7];return o&&(n>12||n<1)?new hk("VALUE"):(/^p/.test(o)&&(n+=12),mk.runtime.packTime(n,i,r,0))}return new hk("VALUE")})),dD("mdeterm",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:!(t=this.asMatrix(o))||!(o=t)||o.width!=o.height&&(r="N/A",1)?o instanceof hk?o:new hk(r):(n.push(o),1<e.length?new hk("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 hk("VALUE")}),!0)||e.determinant()})),dD("transpose",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:(t=this.asMatrix(r))&&(r=t)?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e.transpose()})),dD("mmult",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:!(t=this.asMatrix(a))||!(a=t)||a.height!=o.width&&(r="N/A",1)?a instanceof hk?a:new hk(r):(n.push(a),2<e.length?new hk("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)})),dD("munit",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return new bk(this).unit(e)})),dD("minverse",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:!(t=this.asMatrix(o))||!(o=t)||o.width!=o.height&&(r="N/A",1)?o instanceof hk?o:new hk(r):(n.push(o),1<e.length?new hk("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 hk("VALUE")}),!0)||e.inverse()||new hk("VALUE")})),dD("rand",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return Math.random()})),dD("randbetween",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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())})),dD("true",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return!0})),dD("false",!1,{check:function(e){return 0<e.length?new hk("N/A"):[]}},(function(){return!0})),dD("roman",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof hk?r:new hk("VALUE"):(n.push(r),1<e.length?new hk("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;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){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"};let 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];let i="";for(;e>0;)e<n[0]?n.shift():(i+=t[n[0]],e-=n[0]);return i}(e).toUpperCase()})),dD("arabic",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){var t=function(e){e=e.toLowerCase();let t={i:1,v:5,x:10,l:50,c:100,d:500,m:1e3};let 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 hk("VALUE"):t})),dD("base",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!(("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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=e.toString(t).toUpperCase();for(;i.length<n;)i="0"+i;return i})),dD("decimal",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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();var n=0;for(var 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 hk("VALUE");r-=55}n=n*t+r}return n})),dD("char",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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;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){return String.fromCharCode(e)}));var $D=/[\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 UD(e,t){this.link=e,this.text=t}dD("clean",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.replace($D,"")})),dD("code",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.charAt(0)})),mk.runtime.defineAlias("unichar","char"),mk.runtime.defineAlias("unicode","code"),dD("concatenate",!1,{check:function(e){var t,n=[],i=[],r=0;if(r>=e.length)return new hk("N/A");i.push(t=[]),n.push(i),i=t;do{var o=e[r++];if(o instanceof hk)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 hk?o:new hk("VALUE");i.push(o)}while(r<e.length);return i=n.pop(),r<e.length?new hk("N/A"):i},resolve:function(e,t){var n=[],i=0;for(;i<e.length;)n.push(e[i++]);this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;for(;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){var t="";for(var n=0;n<e.length;++n)t+=e[n];return t})),dD("dollar",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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="$#,##0DECIMALS;($#,##0DECIMALS)";var i="";var r=1;for(;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),lx.text(e,n)})),dD("exact",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)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 hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?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 hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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})),dD("find",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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 hk("VALUE"):i+1})),dD("fixed",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!(("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:"boolean"==typeof(s=this.force(s))||null==s&&(s=!1,1)?(n.push(s),3<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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 lx.text(e,r)})),dD("left",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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)})),dD("right",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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)})),dD("len",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.length})),dD("lower",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.toLowerCase()})),dD("upper",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.toUpperCase()})),dD("ltrim",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.replace(/^\s+/,"")})),dD("rtrim",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.replace(/\s+$/,"")})),dD("trim",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.replace(/^\s+|\s+$/,"")})),dD("mid",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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)})),dD("proper",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?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 hk("N/A"):t):i instanceof hk?i:new hk("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;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){return e.toLowerCase().replace(/\b./g,(function(e){return e.toUpperCase()}))})),dD("replace",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!((s|=0)>=0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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 hk("N/A"):n):l instanceof hk?l:new hk(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;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){return e.substr(0,--t)+i+e.substr(t+n)})),dD("rept",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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;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]);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="";for(;t-- >0;)n+=e;return n})),dD("search",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)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 hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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;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]);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 hk("VALUE"):i+1})),dD("substitute",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)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 hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk("N/A"):n):l instanceof hk?l:new hk(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;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){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})),dD("t",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:null!=(i=this.force(i))&&1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):i instanceof hk?i:new hk("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;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){return"string"==typeof e?e:""})),dD("text",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)return r;if(!(null!=(r=this.force(r))&&n<=e.length))return r instanceof hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?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 hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 lx.text(e,t)})),dD("value",!1,{check:function(e){var t=[],n=0;var i=e[n++];return i instanceof hk?i:null!=(i=this.force(i))&&1<=e.length?(t.push(i),1<e.length?new hk("N/A"):t):i instanceof hk?i:new hk("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;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){return"number"==typeof e?e:"boolean"==typeof e?+e:(e=(e+"").replace(/[$€,]/g,""),e=parseFloat(e),isNaN(e)?new hk("VALUE"):e)})),UD.prototype.toString=function(){return this.text},dD("hyperlink",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r instanceof hk)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 hk?r:new hk(i);t.push(r);var o=e[n++];return o instanceof hk?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 hk("N/A"):t):o instanceof hk?o:new hk(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;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]);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 UD(e,t)})),dD("iferror",!1,{check:function(e){var t=[],n=0,i="VALUE";var r=e[n++];if(r=this.force(r),!(n<=e.length))return new hk(i);t.push(r);var o=e[n++];return null!=(o=this.force(o))&&n<=e.length?(t.push(o),n<e.length?new hk("N/A"):t):new hk(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;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]);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 hk?t:e}));var WD=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 jD(e){return"number"==typeof e||"boolean"==typeof e||null==e||""===e}function qD(e,t){return e===t?0:e<t?-1:1}function GD(e,t){return e===t?0:e<t?1:-1}dD("ERF",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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?ZD(e):ZD(t)-ZD(e)})),dD("ERFC",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},JD),dD("GAMMALN",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},eE),dD("GAMMA",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},tE),dD("GAMMA.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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)}},oE),dD("GAMMA.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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)}},aE),dD("NORM.S.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:"boolean"==typeof(a=this.force(a))||"number"==typeof a&&(a=!!a,1)?(n.push(a),2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},sE),dD("NORM.S.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},lE),dD("NORM.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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 sE((e-t)/n,!0)})),dD("NORM.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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)}},cE),dD("BETADIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:"number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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 dE((e-i)/(r-i),t,n)})),dD("BETA.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=0,1)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];return d instanceof hk?d:"number"==typeof(d=this.force(d))&&(d=hD(d),1)||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=mk.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 hk("N/A"):n:new hk(r)):d instanceof hk?d:new hk(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 dE((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)-nE(t,n))}((e-r)/(o-r),t,n)/(o-r)})),dD("BETA.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:"number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.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 hk("N/A"):n):c instanceof hk?c:new hk(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)}},pE),dD("CHISQ.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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)}},fE),dD("CHISQ.DIST.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},mE),dD("CHISQ.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},gE),dD("CHISQ.INV.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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 gE(1-e,t)})),dD("CHISQ.TEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?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 hk(r):2<e.length?new hk("N/A"):n):a instanceof hk?a:new hk(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=e.length,i=e[0].length;var r,o,a=0;for(r=0;r<n;r++)for(o=0;o<i;o++){var s=t[r][o];var l=e[r][o]-s;a+=(l*=l)/s}return mE(a,(n-1)*(i-1))}(e.data,t.data)})),dD("EXPON.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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)})),dD("POISSON.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>=0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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-fE(2*t,2*(e+1),!0);var i=0;for(var r=2;r<=e;r++)i+=Math.log(r);return Math.exp(e*Math.log(t)-t-i)})),dD("F.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!((s|=0)>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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)}},vE),dD("F.DIST.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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-vE(e,t,n,!0)})),dD("F.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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/pE(1-e,n/2,t/2,0,1)-1)})),dD("F.INV.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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/pE(e,n/2,t/2,0,1)-1)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return(o.length>=2||(r="DIV/0",0))&&(a.length>=2||(r="DIV/0",0))?i<e.length?new hk("N/A"):n:new hk(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;var r=bE(e,_E(e)),o=bE(t,_E(t));if(!r||!o)throw new hk("DIV/0");return 2*vE(r/o,n,i,!0)})),dD("FISHER",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];return o instanceof hk?o:("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk(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))})),dD("FISHERINV",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("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)})),dD("T.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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)}},wE),dD("T.DIST.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},yE),dD("T.DIST.2T",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},kE),dD("T.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},xE),dD("T.INV.2T",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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 xE(1-e/2,t)})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:!("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk?l:new hk(r):(n.push(l),1==l&&o.length!=a.length&&(r="N/A",1)?new hk(r):(o.length>=2||(r="DIV/0",0))&&(a.length>=2||(r="DIV/0",0))?i<e.length?new hk("N/A"):n:new hk(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=e.length,o=t.length;var a,s;if(1==i){var l=0,c=0;for(var d=0;d<r;d++){var h=e[d]-t[d];l+=h,c+=h*h}var u=l/r;return a=u/Math.sqrt((c-l*u)/(r*(r-1))),1==n?yE(a,r-1):kE(a,r-1)}var p=_E(e),f=_E(t),m=bE(e,p),g=bE(t,f);if(3==i){var v=m/r,_=g/o,b=v+_;var w=v/b,y=_/b;return s=1/(w*w/(r-1)+y*y/(o-1)),a=XD(p-f)/Math.sqrt(b),1==n?yE(a,s):kE(a,s)}return s=r+o-2,a=XD(p-f)*Math.sqrt(s*r*o/((r+o)*((r-1)*m+(o-1)*g))),1==n?yE(a,s):kE(a,s)})),dD("CONFIDENCE.T",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r):(n.push(s),3<e.length?new hk("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-xE(e/2,n-1)*t/Math.sqrt(n)})),dD("CONFIDENCE.NORM",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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-lE(e/2)*t/Math.sqrt(n)})),dD("GAUSS",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return sE(e,!0)-.5})),dD("PHI",!1,{check:function(e){var t,n=[],i=0;var r=e[i++];return r instanceof hk?r:"number"==typeof(r=this.force(r))&&(r=hD(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=mk.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new hk("N/A"):n):r instanceof hk?r:new hk("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return sE(e)})),dD("LOGNORM.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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*ZD((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))})),dD("LOGNORM.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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(cE(e,t,n))})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk(r):i<e.length?new hk("N/A"):n):l instanceof hk?l:new hk(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=e.length;var o,a=0;for(o=0;o<r;o++){if(t[o]<=0||t[o]>1)throw new hk("NUM");a+=t[o]}if(1!=a)throw new hk("NUM");var s=0;for(o=0;o<r;o++){var l=e[o];l>=n&&l<=i&&(s+=t[o])}return s})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new hk(r):a.length>0&&o.length>0||(r="N/A",0)?i<e.length?new hk("N/A"):n:new hk(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(t),i=_E(e),r=0,o=0;for(var a=0,s=e.length;a<s;a++){var l=t[a]-n;r+=l*(e[a]-i),o+=l*l}return r/o})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new hk(r):a.length>0&&o.length>0||(r="N/A",0)?i<e.length?new hk("N/A"):n:new hk(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(t),i=_E(e);var r=0,o=0;for(var 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})),dD("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 hk)throw i;return n<=e.length&&t.push(i),t}.bind(this),[]);n+=1,t.push(r)}catch(e){if(e instanceof hk)return e;throw e}try{var o=this.cellValues(e.slice(n,n+1),!0).reduce(function(t,i){if(i instanceof hk)throw i;return n<=e.length&&t.push(i),t}.bind(this),[]);n+=1,t.push(o)}catch(e){if(e instanceof hk)return e;throw e}return o.length!=r.length&&(i="N/A",1)?new hk(i):o.length>0&&r.length>0||(i="N/A",0)?n<e.length?new hk("N/A"):t:new hk(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)}},CE),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new hk(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 hk("N/A"):n:new hk(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=CE(e,t);return n*n})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new hk(r):a.length>=3&&o.length>=3||(r="DIV/0",0)?i<e.length?new hk("N/A"):n:new hk(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.length;var i=_E(t),r=_E(e);var o=0,a=0,s=0;for(var 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))})),dD("FORECAST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var s=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return s.length!=a.length&&(r="N/A",1)?new hk(r):s.length>0&&a.length>0||(r="N/A",0)?i<e.length?new hk("N/A"):n:new hk(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){var i=_E(n),r=_E(t);var o=0,a=0;for(var 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 hk("N/A");var d=o/a;return r-d*i+d*e})),dD("LINEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!0,1)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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 hk("N/A"):n):l instanceof hk?l:new hk(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)}},ME),dD("LOGEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!0,1)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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 hk("N/A"):n):l instanceof hk?l:new hk(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 ME.call(this,e.map(Math.log),t,n,i).map(Math.exp)})),dD("TREND",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!((t=this.asMatrix(s))&&(s=t)||null==s))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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 hk("N/A"):n):l instanceof hk?l:new hk(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)}},AE),dD("GROWTH",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!((t=this.asMatrix(s))&&(s=t)||null==s))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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 hk("N/A"):n):l instanceof hk?l:new hk(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 AE.call(this,e.map(Math.log),t,n,i).map(Math.exp)})),dD("FV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))||null==s&&(s=0,1)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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)}},EE),dD("PV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))||null==s&&(s=0,1)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),5<e.length?new hk("N/A"):n):c instanceof hk?c:new hk(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})),dD("PMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),5<e.length?new hk("N/A"):n):c instanceof hk?c:new hk(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)}},IE),dD("NPER",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),5<e.length?new hk("N/A"):n):c instanceof hk?c:new hk(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)})),dD("RATE",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=0,1)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!(0===(c=this.force(c))||1===c||null==c&&(c=0,1)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];return d instanceof hk?d:("number"==typeof(d=this.force(d))&&(d=hD(d),1)||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=mk.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 hk("N/A"):n:new hk(r)):d instanceof hk?d:new hk(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 DE((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)})),dD("IPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=0,1)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];return d instanceof hk?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 hk("N/A"):n:new hk(r)):d instanceof hk?d:new hk(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)}},zE),dD("PPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=0,1)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];return d instanceof hk?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 hk("N/A"):n:new hk(r)):d instanceof hk?d:new hk(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 IE(e,n,i,r,o)-zE(e,t,n,i,r,o)})),dD("CUMPRINC",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>0||(r="NUM",0)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];return d instanceof hk?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 hk("N/A"):n:new hk(r)):d instanceof hk?d:new hk(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);var c=e*n*a/(a-1);return l*n-(l-1)/e*c-(s*n-(s-1)/e*c)})),dD("CUMIPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>0||(r="NUM",0)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];return d instanceof hk?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 hk("N/A"):n:new hk(r)):d instanceof hk?d:new hk(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){var a=0;for(var s=i;s<=r;s++)a+=zE(e,s,t,n,0,o);return a})),dD("NPV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);try{var a=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return a.length>0||(r="N/A",0)?i<e.length?new hk("N/A"):n:new hk(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){var n=0;for(var i=0,r=t.length;i<r;i++)n+=t[i]*Math.pow(1+e,-i-1);return n})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var o=e[i++];return o instanceof hk?o:"number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.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 hk("N/A"):n):o instanceof hk?o:new hk("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 DE((function(t){var n=0,i=0;for(var 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)})),dD("EFFECT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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})),dD("NOMINAL",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];return a instanceof hk?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.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 hk("N/A"):n):a instanceof hk?a:new hk(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)})),dD("XNPV",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var s=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}return a.length!=s.length&&(r="NUM",1)?new hk(r):i<e.length?new hk("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){var i=0;for(var r=0,o=t.length;r<o;r++)i+=t[r]*Math.pow(1+e,(n[0]-n[r])/365);return i})),dD("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 hk)throw n;return("number"==typeof n&&(n=hD(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof hk)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=mk.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 hk)return e;throw e}var s=e[i++];return s instanceof hk?s:"number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk(r):i<e.length?new hk("N/A"):n):s instanceof hk?s:new hk(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 DE((function(n){var i=e[0],r=0;for(var 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)})),dD("ISPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:"number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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)})),dD("DB",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:"number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.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 hk("N/A"):n):c instanceof hk?c:new hk(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})),dD("DDB",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?c:"number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.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 hk("N/A"):n):c instanceof hk?c:new hk(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;var a=-e*(Math.pow(1-o,i-1)-1);var s=(e-a)*o;return s=Math.min(s,Math.max(0,e-a-t))})),dD("SLN",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];return s instanceof hk?s:("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk("N/A"):n):s instanceof hk?s:new hk(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})),dD("SYD",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?l:("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.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 hk("N/A"):n):l instanceof hk?l:new hk(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))})),dD("VDB",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))&&(o=hD(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))&&(a=hD(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>=0||(r="NUM",0)))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>=0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>=0||(r="NUM",0)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];if(d instanceof hk)return d;if(!(("number"==typeof(d=this.force(d))&&(d=hD(d),1)||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=mk.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 hk?d:new hk(r);n.push(d);var h=e[i++];return h instanceof hk?h:"boolean"==typeof(h=this.force(h))||"number"==typeof h&&(h=!!h,1)||null==h&&(h=!1,1)?(n.push(h),c>=l||(r="NUM",0)?7<e.length?new hk("N/A"):n:new hk(r)):h instanceof hk?h:new hk(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){var r=e-t;var o=Math.ceil(i);var a,s=0,c=0,d=!1;for(var h=1;h<=o;h++){if(d)a=s;else{var u=l(e,h);(s=r/(n-h+1))>u?(a=s,d=!0):(a=u,r-=u)}h==o&&(a*=i+1-o),c+=a}return c}var d=Math.floor(i),h=Math.ceil(r);var u=0;if(a)for(var p=d+1;p<=h;p++){var f=l(e,p);p==d+1?f*=Math.min(r,d+1)-i:p==h&&(f*=r+1-h),u+=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),u=c(e,n-i,r-i)}return u})),dD("COUPDAYBS",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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 LE(BE(e,t,n)[0],e,i)})),dD("COUPDAYS",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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=BE(e,t,n);return LE(r[0],r[1],1)}if(3==i)return 365/n;return 360/n})),dD("COUPDAYSNC",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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=BE(e,t,n)[1];return LE(e,r,i)})),dD("COUPPCD",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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 BE(e,t,n)[0]})),dD("COUPNCD",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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 BE(e,t,n)[1]})),dD("COUPNUM",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.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 hk?s:new hk(r);n.push(s);var l=e[i++];return l instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):l instanceof hk?l:new hk(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=pD(e),r=pD(t);return 1+((12*(r.year-i.year)+r.month-i.month)*n/12|0)})),dD("ACCRINTM",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!(null==(l=this.force(l))&&(l=1e3,1)||("number"==typeof l&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l>0||(r="NUM",0))))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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=HE(pD(t).year,r);return n*i*LE(e,t,r)/o})),dD("ACCRINT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!(null==(c=this.force(c))&&(c=1e3,1)||("number"==typeof c&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c>0||(r="NUM",0))))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];if(d instanceof hk)return d;if(!("number"==typeof(d=this.force(d))||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=mk.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 hk?d:new hk(r);n.push(d);var h=e[i++];if(h instanceof hk)return h;if(!(null==(h=this.force(h))&&(h=0,1)||("number"==typeof h||"boolean"==typeof h&&(h=+h,1)||"string"==typeof h&&!/^(?:=|true|false)/i.test(h)&&(t=mk.parse(0,0,0,h),/^date|number|percent$/.test(t.type)&&(h=+t.value,1)))&&(h|=0,1)&&(0===h||1===h||2===h||3===h||4===h)))return h instanceof hk?h:new hk(r);n.push(h);var u=e[i++];return u instanceof hk?u:"boolean"==typeof(u=this.force(u))||"number"==typeof u&&(u=!!u,1)||null==u&&(u=!0,1)?(n.push(u),o<s||(r="NUM",0)?8<e.length?new hk("N/A"):n:new hk(r)):u instanceof hk?u:new hk(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=0,c=r*i/o;var d,h,u,p,f,m;var g=a%2==0?360:365;function v(e,t){return(t-e)*o/g|0}return n<=t?(h=(d=BE(n,t,o))[0],u=d[1],h<=e?c*LE(e,n,a)/LE(h,u,a):(p=(d=BE(e,h,o))[0],c*((m=v(f=d[1],n))+LE(e,f,a)/LE(p,f,a)+(n<u?LE(h,n,a)/LE(h,u,a):0)))):(d=function(e,t,n){var i=pD(t),r=pD(e);var o=i.year-r.year;o>0&&(o=(o-1)*n);var a,s=e,l=12/n;for(;t>s;)a=s,s=PE(e,++o*l);return[a,s]}(t,n,o),h=d[0],u=d[1],m=v(t,n),l=u==n?c*m:c*(m+LE(h,n,a)/LE(h,u,a)),s?(h=(d=BE(e,t,o))[0],u=d[1],l+=c*((m=v(e,t))+LE(e,u,a)/LE(h,u,a))):l)})),dD("DISC",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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:gD(pD(e).year)?366:365;return(i-n)/i*o/LE(e,t,r)})),dD("INTRATE",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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:gD(pD(e).year)?366:365;return(i-n)/n*o/LE(e,t,r)})),dD("RECEIVED",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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:gD(pD(e).year)?366:365;return n/(1-i*LE(e,t,r)/o)})),dD("PRICE",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];if(c instanceof hk)return c;if(!("number"==typeof(c=this.force(c))&&(c=hD(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=mk.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>0||(r="NUM",0)))return c instanceof hk?c:new hk(r);n.push(c);var d=e[i++];if(d instanceof hk)return d;if(!("number"==typeof(d=this.force(d))||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=mk.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 hk?d:new hk(r);n.push(d);var h=e[i++];return h instanceof hk?h:null==(h=this.force(h))&&(h=0,1)||("number"==typeof h||"boolean"==typeof h&&(h=+h,1)||"string"==typeof h&&!/^(?:=|true|false)/i.test(h)&&(t=mk.parse(0,0,0,h),/^date|number|percent$/.test(t.type)&&(h=+t.value,1)))&&(h|=0,1)&&(0===h||1===h||2===h||3===h||4===h)?(n.push(h),o<a||(r="NUM",0)?7<e.length?new hk("N/A"):n:new hk(r)):h instanceof hk?h:new hk(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);var l=BE(e,t,o),c=l[0],d=l[1];var h=LE(c,e,a),u=LE(e,d,a),p=LE(c,d,a);var f=100*n/o,m=i/o,g=u/p;if(1==s)return(r+f)/(1+g*m)-h/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-h/p*f})),dD("PRICEDISC",!1,{check:function(e){var t,n=[],i=0,r="VALUE";var o=e[i++];if(o instanceof hk)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=mk.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof hk?o:new hk(r);n.push(o);var a=e[i++];if(a instanceof hk)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=mk.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof hk?a:new hk(r);n.push(a);var s=e[i++];if(s instanceof hk)return s;if(!("number"==typeof(s=this.force(s))&&(s=hD(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=mk.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof hk?s:new hk(r);n.push(s);var l=e[i++];if(l instanceof hk)return l;if(!("number"==typeof(l=this.force(l))&&(l=hD(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=mk.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof hk?l:new hk(r);n.push(l);var c=e[i++];return c instanceof hk?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=mk.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 hk("N/A"):n:new hk(r)):c instanceof hk?c:new hk(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=LE(e,t,r),a=HE(pD(t).year,r);return i-n*i*o/a}));var KD=300,YD=22204e-20,QD=1e-30,XD=Math.abs;function ZD(e){if(XD(e)>=3.3)return 1-JD(e);var t=e>0?1:-1;-1==t&&(e=-e);var n=0,i=1;for(var 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 JD(e){if(XD(e)<3.3)return 1-ZD(e);var t=1;e<0&&(t=-1,e=-e);var n=e;for(var 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 eE(e){var t=[1.000000000190015,76.18009172947146,-86.50532032941678,24.01409824083091,-1.231739572450155,.001208650973866179,-5395239384953e-18];var 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 tE(e){if(e>0)return Math.exp(eE(e));var t=Math.PI,n=-e;return-t/(n*tE(n)*Math.sin(t*n))}function nE(e,t){return eE(e)+eE(t)-eE(e+t)}function iE(e,t){return Math.exp(nE(e,t))}function rE(e,t){return t<e+1?function(e,t){var n=1/e,i=n,r=e;var o,a=eE(e);for(o=1;o<=KD&&(n+=i*=t/++r,!(XD(i)<XD(n)*YD));o++);return n*Math.exp(-t+e*Math.log(t)-a)}(e,t):1-function(e,t){var n=QD,i=n,r=0,o=1,a=t+1-e;var s=eE(e);for(var l=1;l<=KD;l++){XD(r=a+o*r)<QD&&(r=QD),XD(i=a+o/i)<QD&&(i=QD);var c=i*(r=1/r);if(n*=c,XD(c-1)<YD)break;a+=2,o=-l*(l-e)}return n*Math.exp(-t-s+e*Math.log(t))}(e,t)}function oE(e,t,n,i){return i?rE(t,e/n):Math.pow(e/n,t-1)*Math.exp(-e/n)/(n*tE(t))}function aE(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<KD;s++){var l=oE(o=.5*(i+r),t,n,!0);if(XD(e-l)<1e-16)break;l>e?r=o:i=o}return o}function sE(e,t){return t?.5+.5*ZD(e/Math.sqrt(2)):Math.exp(-e*e/2)/Math.sqrt(2*Math.PI)}function lE(e){var t=[-39.69683028665376,220.9460984245205,-275.9285104469687,138.357751867269,-30.66479806614716,2.506628277459239],n=[-54.47609879822406,161.5858368580409,-155.6989798598866,66.80131188771972,-13.28068155288572],i=[-.007784894002430293,-.3223964580411365,-2.400758277161838,-2.549732539343734,4.374664141464968,2.938163982698783],r=[.007784695709041462,.3224671290700398,2.445134137142996,3.754408661907416];var o=.02425;var a,s;return e<o?(a=Math.sqrt(-2*Math.log(e)),(((((i[0]*a+i[1])*a+i[2])*a+i[3])*a+i[4])*a+i[5])/((((r[0]*a+r[1])*a+r[2])*a+r[3])*a+1)):.97575<e?(a=Math.sqrt(-2*Math.log(1-e)),-(((((i[0]*a+i[1])*a+i[2])*a+i[3])*a+i[4])*a+i[5])/((((r[0]*a+r[1])*a+r[2])*a+r[3])*a+1)):(((((t[0]*(s=(a=e-.5)*a)+t[1])*s+t[2])*s+t[3])*s+t[4])*s+t[5])*a/(((((n[0]*s+n[1])*s+n[2])*s+n[3])*s+n[4])*s+1)}function cE(e,t,n){return t+n*lE(e)}function dE(e,t,n){var i=Math.exp(t*Math.log(e)+n*Math.log(1-e)-nE(t,n));return e<(t+1)/(t+n+2)?i*hE(t,n,e)/t:1-i*hE(n,t,1-e)/n}function hE(e,t,n){var i,r;var o,a,s,l,c,d,h,u;for(h=e-1,a=1,XD(s=1-(d=e+t)*n/(u=e+1))<QD&&(s=QD),c=s=1/s,i=1;i<=KD&&(XD(s=1+(o=i*(t-i)*n/((h+(r=2*i))*(e+r)))*s)<QD&&(s=QD),XD(a=1+o/a)<QD&&(a=QD),c*=(s=1/s)*a,XD(s=1+(o=-(e+i)*(d+i)*n/((e+r)*(u+r)))*s)<QD&&(s=QD),XD(a=1+o/a)<QD&&(a=QD),c*=l=(s=1/s)*a,!(XD(l-1)<YD));i++);return c}function uE(e,t,n){var i=0,r=1,o=0;for(var a=0;a<KD;a++){var s=dE(o=.5*(i+r),t,n);if(XD(e-s)<YD)break;s>e?r=o:i=o}return o}function pE(e,t,n,i,r){return i+(r-i)*uE(e,t,n)}function fE(e,t,n){return oE(e,t/2,2,n)}function mE(e,t){return 1-fE(e,t,!0)}function gE(e,t){return aE(e,t/2,2)}function vE(e,t,n,i){if(i)return dE(t*e/(n+t*e),t/2,n/2);var r=t/n;return r/iE(t/=2,n/=2)*Math.pow(r*e,t-1)/Math.pow(1+r*e,t+n)}function _E(e){var t=0,n=e.length;for(var i=0;i<n;i++)t+=e[i];return t/n}function bE(e,t){var n=0,i=e.length;for(var r=0;r<i;r++){var o=e[r]-t;n+=o*o}return n/(i-1)}function wE(e,t,n){return n?1-.5*dE(t/(e*e+t),t/2,.5):1/(Math.sqrt(t)*iE(.5,t/2))*Math.pow(1+e*e/t,-(t+1)/2)}function yE(e,t){return 1-wE(e,t,!0)}function kE(e,t){return e<0&&(e=-e),2*yE(e,t)}function xE(e,t){var n=uE(2*Math.min(e,1-e),t/2,.5);return n=Math.sqrt(t*(1-n)/n),e>.5?n:-n}function CE(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);var n=_E(e),i=_E(t);var r=0,o=0,a=0;for(var 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 SE(e){var t=e.height,n=0;for(var i=0;i<t;i++)n+=e.data[i][0];return n/t}function TE(e,t){var n=e.height,i=0;for(var r=0;r<n;r++){var o=e.data[r][0]-t;i+=o*o}return i}function ME(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();var a=o.multiply(t).inverse().multiply(o).multiply(e);var 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);var c=e.adds(l,!0);var d=TE(l,n?SE(l):0);var h=TE(c,n?SE(c):0);var u=[];u.push(d,h);var p=d/(d+h);var f=e.height-t.width;var m=Math.sqrt(h/f);var g=[];g.push(p,m);var v=n?d/(t.width-1)/(h/f):p/t.width/((1-p)/f);var _=[];_.push(v,f);var b=o.multiply(t).inverse();var w=[];for(r=b.height-1;r>=0;r--)w.push(Math.sqrt(b.data[r][r]*h/f));return this.asMatrix([s,w,g,_,u])}function AE(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();var 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 DE(e,t,n,i){var r=n||20,o=i||1e-7;var a=t;for(var s=1;s<=r;s++){var l=e(a);var c=l[0]/l[1];if(a-=c,Math.abs(c)<o)return a}return new hk("NUM")}function EE(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 IE(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 zE(e,t,n,i,r,o){if(1==o&&1==t)return 0;var a=EE(e,t-1,IE(e,n,i,r,o),i,o)*e;return o?a/(1+e):a}function PE(e,t){var n=pD(e);var i=n.month+t;var r=n.year+Math.floor(i/12);return(i%=12)<0&&(i+=12),n=Math.min(n.date,fD(r,i)),uD(r,i,n)}function LE(e,t,n){return 1==n||2==n||3==n?t-e:ND(e,t,n)}function BE(e,t,n){var i=pD(e);var r=pD(t).year-i.year;r>0&&(r=(r-1)*n);var o,a=12/n;do{o=PE(t,-++r*a)}while(e<o);return[o,PE(t,- --r*a)]}function HE(e,t){return 3==t?365:1==t?gD(e)?366:365:360}const{packDate:RE,unpackDate:FE,packTime:OE,unpackTime:VE,serialToDate:NE,dateToSerial:$E,defineAlias:UE}=mk.runtime;var WE=Object.freeze({__proto__:null,ALL_PROPERTIES:yC,ALL_REASONS:zy,AddColumnCommand:bM,AddCommand:_M,AddRowCommand:wM,AdjustDecimalsCommand:QT,AdjustRowHeightCommand:tM,ApplyFilterCommand:hM,AutoFillCalculator:eS,AutoFillCommand:sM,Axis:GC,AxisManager:JC,BorderChangeCommand:XT,BringToFrontCommand:RT,CalcError:hk,CellRef:Sy,ClearContentCommand:qT,ClearFilterCommand:uM,Clipboard:bT,ColumnWidthCommand:VT,Command:IT,Context:vk,Controller:Jx,CopyCommand:rM,CustomFilter:bS,CutCommand:iM,Deferred:eA,DefineNameCommand:SM,DeleteColumnCommand:vM,DeleteCommand:mM,DeleteDrawingCommand:BT,DeleteNameCommand:TM,DeleteRowCommand:gM,Drawing:IS,DrawingCommand:PT,DrawingUpdateCommand:zT,DynamicFilter:yS,EditCommand:GT,EditValidationCommand:yM,EventListener:Vx,FIRSTREF:Ay,Filter:vS,FilterCommand:cM,FormulaBar:hT,FormulaContext:Rx,FormulaInput:lT,FreezePanesCommand:JT,Grid:QC,GridLinesChangeCommand:UT,HideLineCommand:pM,HyperlinkCommand:$T,InsertCommentCommand:KT,InsertImageCommand:LT,Matrix:bk,MergeCellCommand:ZT,NULLREF:xy,NameCommand:CM,NameEditor:uT,NameRef:Cy,OpenCommand:kM,Pane:rT,PaneAxis:KC,PaneGrid:XC,PasteCommand:eM,PropertyBag:_C,PropertyChangeCommand:WT,PropertyCleanCommand:jT,Range:TC,RangeList:uC,RangeRef:Ty,RangeTree:sC,Ref:ky,ReorderDrawingsCommand:HT,RowHeightCommand:NT,SHEETREF:Dy,SaveAsCommand:xM,SendToBackCommand:FT,Sheet:ES,SheetDataSourceBinder:aS,SheetEditor:NC,SheetNavigator:nS,SortCommand:dM,Sorter:ZC,SpreadsheetWidget:class extends VC{constructor(e,t){super(e,tk({},Iy,t)),this.events=lD,this.bind(this.events,this.options),pk({locale:this.options.locale,...this.options.intl}),kS(),this._view=new gT(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 aD(this.options,this._view),this._controller=new Jx(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;let n=e.ctrlKey||e.metaKey;if(this.trigger("keydown",e),t===Ny&&e.shiftKey)return this._view.sheetsbar.onAddSelect(),void e.preventDefault();if(e.altKey&&t===Oy){let e=this.sheetIndex(this.activeSheet());let t=this.sheetByIndex(e+1)?.name();t&&this._view.sheetsbar.onSheetSelect(t)}else if(e.altKey&&t===Fy){let e=this.sheetIndex(this.activeSheet());let t=this.sheetByIndex(e-1)?.name();t&&this._view.sheetsbar.onSheetSelect(t)}else{if(e.altKey&&t===Py)return this._view.sheetsbar.onSheetRemove(this.activeSheet()._name()),void e.preventDefault();if(e.altKey&&t===Ky)return this.options.createSheetEditor?.(),void e.preventDefault();if(n&&t===$y)this._handleTypographicalEmphasis("bold");else if(n&&t===Uy)this._handleTypographicalEmphasis("italic");else if(n&&t===Wy)this._handleTypographicalEmphasis("underline");else{if(e.altKey&&t===qy)return this._view.tabstrip?.select("home"),void e.preventDefault();if(e.altKey&&t===jy)return this._view.tabstrip?.select("insert"),void e.preventDefault();if(e.altKey&&t===Gy)return this._view.tabstrip?.select("data"),void e.preventDefault();t===Vy&&(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 TC(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=zy),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 aD(tk({},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(tk({},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:OT,TextWrapCommand:YT,ToolbarCopyCommand:aM,ToolbarCutCommand:lM,ToolbarPasteCommand:nM,TopFilter:wS,UnHideLineCommand:fM,UnionRef:My,ValidationFormulaContext:Fx,ValueFilter:_S,View:gT,Workbook:aD,calc:mk,dateToNumber:function(e){return null==e?null:mk.runtime.dateToSerial(e)},dateToSerial:$E,defineAlias:UE,defineFunction:function(e,t){return e=e.toLowerCase(),gk[e]=t,{args:function(n,i){var r=kk(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())),(gk[e]=Tk(t,r.resolve,r.check,r.arrayArgs)).kendoSpreadsheetArgs=n,this},argsAsync:function(n,i){var r=kk(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())),(gk[e]=Mk(t,r.resolve,r.check,r.arrayArgs)).kendoSpreadsheetArgs=n,this}}},draw:XS,drawCell:iT,formatting:lx,initDynamicFilter:kS,intl:pk,numberToDate:rS,packDate:RE,packTime:OE,registerEditor:function(e,t){DS[e]=t},serialToDate:NE,unpackDate:FE,unpackTime:VE,validation:xC});function jE(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,WE),e.spreadsheet.commonEngine=WE}(kendo),function(e){var t=e.jQuery;var n=e.data.ObservableObject;var 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"}};var 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=L(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";var 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;var 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");var t=this.value||0;return e&&e.length?a(t,e):t}});function l(e,n){var i=[];var r=[];for(var 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=e.currency;var n=t.pattern[1];var i,r;return e.decimals&&(n=n.replace(/n/g,"n"+t["."]+(i="0",r=t.decimals,new Array(r+1).join(i)))),n=(n=e.iso?'"'+t.abbr+'" '+n.replace(/\s*\$\s*/g,""):n.replace(/\$/g,JSON.stringify(t.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;var 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=this.options;var i=t.value();var r=n.categories.slice(0);var a;this.viewModel=new s({currencies:n.currencies.slice(0),allFormats:{numberFormats:n.numberFormats.slice(0),dateFormats:n.dateFormats.slice(0)},categories:r,format:t.format(),category:i instanceof Date?r[2]:r[0],apply:this.apply.bind(this),close:this.close.bind(this),value:i,formatItemTemplate:t=>e.htmlEncode(t.name)}),o.fn.open.call(this),a=this.dialog().element,e.bind(a,this.viewModel);var l=a.find("select.k-format-filter").data("kendoDropDownList");n.currencies.length>10&&l.setOptions({filter:"contains"}),a.find(e.roleSelector("staticlist")).parent().addClass("k-list-wrapper"),a.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;var 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 h=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.confirmationDialog||i;var 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;var 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",h);var u=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;var 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",u);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");var n=this.options.options;var 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");var n=this.options.options;var 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}});var 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;var 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 w=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.mergeDialog||i;var 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",w);var y=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.freezeDialog||i;var 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",y);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;var t=[];if("text"===this.criterion){var n=["equalTo","notEqualTo"];for(var 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}});var x=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.validationDialog||i;var 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=this.options;var i;this.viewModel=new k({type:n.type,defaultHintMessage:n.hintMessage,defaultHintTitle:n.hintTitle,defaultComparers:n.comparers.slice(0),comparerMessages:n.comparerMessages,criteria:n.criteria.slice(0),criterion:n.criterion,ignoreBlank:n.ignoreBlank,showButton:n.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),i=this.dialog().element,this.validatable&&this.validatable.destroy(),e.bind(i,this.viewModel),this.validatable=new e.ui.Validator(i.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 M=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",M);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;var 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 D=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();let a=this;o.fn.open.apply(a,arguments);let s=a.dialog().element;let 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",D);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;var 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;var 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){var n;for(var 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 L(e){return e instanceof z?e.trans():Array.isArray(e)?e.map(L):null!=e&&"object"==typeof e?Object.keys(e).reduce((function(t,n){return t[n]=L(e[n]),t}),{}):e}e.spreadsheet.dialogs.register("insertImage",I),z.prototype.trans=function(){var t=e.spreadsheet.messages.dialogs;for(var 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;var n=["allBorders","insideBorders","insideHorizontalBorders","insideVerticalBorders","outsideBorders","leftBorder","topBorder","rightBorder","bottomBorder","noBorders"];var i={allBorders:"bordersAll",insideBorders:"bordersInside",insideHorizontalBorders:"bordersInsideHorizontal",insideVerticalBorders:"bordersInsideVertical",outsideBorders:"bordersOutside",leftBorder:"borderLeft",topBorder:"borderTop",rightBorder:"borderRight",bottomBorder:"borderBottom",noBorders:"bordersNone"};var 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"};var 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"];var 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;var a=r;var 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;var 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...",formatTypesSamples:{number:"1,499.99",percent:"14.50%",financial:"(1,000.12)",currency:"$1,499.99",date:"4/21/2012",time:"5:49:00 PM",dateTime:"4/21/2012 5:49:00",duration:"168:05:00"},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"};var 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"};var 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"];var s=e.spreadsheet.messages.colorPicker={reset:"Reset color",customColor:"Custom color...",apply:"Apply",cancel:"Cancel"};var l=i.extend({init:function(t,c){let d={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:r.formatTypesSamples.number},{attributes:{"data-value":o.percent,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.percent,sample:r.formatTypesSamples.percent},{attributes:{"data-value":o.financial,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.financial,sample:r.formatTypesSamples.financial},{attributes:{"data-value":o.currency,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.currency,sample:r.formatTypesSamples.currency},{attributes:{"data-value":o.date,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.date,sample:r.formatTypesSamples.date},{attributes:{"data-value":o.time,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.time,sample:r.formatTypesSamples.time},{attributes:{"data-value":o.dateTime,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.dateTime,sample:r.formatTypesSamples.dateTime},{attributes:{"data-value":o.duration,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.duration,sample:r.formatTypesSamples.duration},{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"}};Object.keys(d).forEach((e=>{"validation"!==e&&(d[e].showText="overflow")})),c.tools=c.tools||l.prototype.options.tools[c.toolbarName],c.parentMessages=r,c.defaultTools=d,i.fn.init.call(this,t,c);var h=this._click.bind(this);this.element.addClass("k-spreadsheet-toolbar k-toolbar-md"),this.bind({click:h,toggle:h,change:h})},_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){var n=t,i=this._tools();for(var 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,h=t.component,u=t.toolbarEl,p=e.widgetInstance(u.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(u,c));else if("alignment"===i)o=n.verticalAlign(),a=n.textAlign(),(s=h.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(u.is("button"))return u.attr("data-value",n),void u.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)}h&&h.toggle&&("boolean"==typeof n?m=!!n:"string"==typeof n&&(m=u.data("value")?u.data("value")===n:null!=n),this.toggle(u,m))}});e.cssProperties.propertyDictionary.SpreadsheetToolBar=e.cssProperties.propertyDictionary.ToolBar,e.spreadsheet.ToolBar=l,e.spreadsheet.Menu=e.ui.Menu}(window.kendo);var qE={};var GE=function(e,t){var n=t+":"+e;var i=qE[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=qE[n]=function(e){var t=e.charCodeAt(0);var 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;var n=t.promise();e=jE(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=GE(e.fontFamily,e.fontSize);function r(e){if(null!=e){var t=12;for(var 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?jE(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}));var o=i.map((function(e){return e.title||e.field}));var s=o.map(r);var 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();var 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;var d=e.ui.Calendar.fn.options.max;var h=l.from;var u=l.to;var p=e.spreadsheet.calc.runtime.Formula;/^(?:greaterThan|between)/.test(l.comparerType)&&(c=h instanceof p&&a(h.value)?e.spreadsheet.numberToDate(s.range(h.value.row,h.value.col).value()):e.spreadsheet.numberToDate(h.value)),"between"==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.to.value)),"lessThan"!=l.comparerType&&"lessThanOrEqualTo"!=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.from.value)),i.setOptions({disableDates:function(t){var n,i;return n=h&&h instanceof p&&a(h.value)?s.range(h.value.row,h.value.col).value():h?0|h.value:0,i=u&&u instanceof p&&a(u.value)?s.range(u.value.row,u.value.col).value():u?0|u.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;var 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;var n=e._outerWidth;var i=".";var r=" ";var 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;var 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;var r=n._sheetsGroup();var a=n._sheetsWrapper();var s=e.scrollLeft(r);var l=a.find(i+o.classNames.sheetsBarPrev);var 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=this;var n=o.classNames;var r=t.options;var a;var s;var l=t._sheetsWrapper();a=l.find(i+n.sheetsBarPrev),s=l.find(i+n.sheetsBarNext),e?(a.on("mousedown",(function(e){e.preventDefault(),e.stopPropagation(),t._nowScrollingSheets=!0,t._scrollSheetsByDelta(r.scrollable.distance*(t._isRtl?1:-1))})),s.on("mousedown",(function(e){e.preventDefault(),e.stopPropagation(),t._nowScrollingSheets=!0,t._scrollSheetsByDelta(r.scrollable.distance*(t._isRtl?-1:1))})),a.add(s).on("mouseup",(function(){t._nowScrollingSheets=!1}))):(a.off(),s.off())},_renderHtml:function(n,i){var a;var s=[];var l=e.dom;var c=l.element;var d=this._sheets;var h=this._selectedIndex;var u=o.classNames;for(a=0;a<d.length;a++){var p=d[a];var f=a===h;var m={className:u.sheetsBarKItem+r+u.sheetsBarKTabstripItem+r,role:"tab"};var g=[];if("visible"!==p.state()&&(m.className+="k-hidden "),f&&(m.className+=u.sheetsBarKActive),f&&n)g.push(c("input",{type:"text",value:p.name(),className:u.sheetsBarKTextbox+r+u.sheetsBarEditor,maxlength:50},[]));else{g.push(c("span",{className:u.sheetsBarKLink,title:p.name()},[c("span",{className:u.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:u.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);let a=e._sheets||[];let s=a.filter((e=>"visible"===e.state()));let l=!e._sheets||e._sheets&&s.length<2;let c=r.data("sheetName");let d=!(l||e._sheets&&n==a.length-1);let h=!(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:h}],click:e._onSheetContextMenu.bind(e)})}))},_createSheetsWrapper:function(n,i){var a=e.dom.element;var s=o.classNames;var l=a("div",{className:"k-tabstrip-items-wrapper k-hstack"});var c=[a("ul",{className:s.sheetsBarKReset,role:"tablist"},n),null,null];var d=s.sheetsBarKButton+r+s.sheetsBarKButtonBare+r;return c[1]=a("span",{ariaHidden:"true",tabIndex:-1,className:d+s.sheetsBarPrev},[a(t(e.ui.icon({icon:s.sheetsBarArrowWIcon,iconClass:"k-button-icon"}))[0])]),c[2]=a("span",{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");let 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));let 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));let 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=this;var r=i._sheetsGroup();var o=e.scrollLeft(r);var a=n(t);var s=i._isRtl?t.position().left:t.position().left-r.children().first().position().left;var l=r[0].offsetWidth;var c;i._isRtl?s<0?c=o+s-(l-o):s+a>l&&(c=o+s-a):o+l<s+a?c=s+a-l:o>s&&(c=s),r.finish().animate({scrollLeft:c},"fast","linear",(function(){i._toggleScrollButtons()}))},_sheetsGroup:function(){return this._sheetsWrapper().find("ul")},_sheetsWrapper:function(){return this.element.find(i+o.classNames.sheetsBarItems)},_scrollSheetsByDelta:function(t){var n=this;var i=n._sheetsGroup();var 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",sheetsBarKTabstripItem:"k-tabstrip-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;var n=e.ui.Widget;var 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(h.classNames.details),this._summary=this.element.find("."+h.classNames.detailsSummary).on("click",this._toggle.bind(this));var o=r.expanded?h.classNames.iconCollapseName:h.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?h.classNames.iconExpandName:h.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){var i=!1;var r=t instanceof e.data.HierarchicalDataSource&&t.data();var o=this.values;for(var s=0;s<r.length;s++){var l=r[s];var c=l.text.toString().toLocaleLowerCase(e.culture().name);var d=!0===n||""===n||c.indexOf(n)>=0;var h=a.bind(this)(l.children,n);i=i||h||d,l.hidden=!d&&!h,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){var n=t instanceof e.data.HierarchicalDataSource&&t.data();for(var 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;var 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);var 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;var 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=[];var r=e.spreadsheet.messages.filterMenu;var o=t.column(n);var a=t.sheet();return o.forEachCell((function(t,n,o){var s=!0;a.isHiddenRow(t)&&(s=!1);var l=o.value;var c=o.dataType;var 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){var t={};var n=[];for(var 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=e.sheet();var i=this.filterForColumn(t,n);var r;if((i=i&&i.filter.toJSON())&&"custom"==i.filter){var o=i.criteria[0].value;o instanceof Date?r="date":"string"==typeof o?r="string":"number"==typeof o&&(r="number")}if(!r){var a=this.values(e.row(1),t)[0];"blank"==(r=a&&a.dataType)&&(r=null)}return r},filterForColumn:function(e,t){var n=t.filter();var i;return n&&(i=n.columns.filter((function(t){return t.index===e}))[0]),i},filter:function(e,t){var n=this.filterForColumn(e,t);if(n){var i=n.filter.toJSON();var r=i.filter;delete i.filter;var o={type:r,options:i};var a=i.criteria;return a&&a.length&&(o.operator=a[0].operator),o}}};var h=n.extend({init:function(e,t){n.call(this,e,t),this.element.addClass(h.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={operatingRange:this.options.range,column:this.options.column};var t;var n;"value"===this.viewModel.active?(this.viewModel.valuesChange({sender:this.valuesTreeView}),((t=this.viewModel.valueFilter.toJSON()).blanks||t.values&&t.values.length)&&(e.valueFilter=t)):"custom"===this.viewModel.active&&(n=this.viewModel.customFilter.toJSON()).criteria.length&&null!==n.criteria[0].value&&(e.customFilter=n),(e.valueFilter||e.customFilter)&&this.action({command:"ApplyFilterCommand",options:e})},action:function(e){this.trigger("action",t.extend({},e))},_filterInit:function(){var e=this.options.column;var t=this.options.range;var n=t.sheet();var 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(h.templates.menuItem);var i=e.spreadsheet.messages.filterMenu;var r=[{command:"sort",dir:"asc",text:i.sortAscending,iconClass:"sort-asc"},{command:"sort",dir:"desc",text:i.sortDescending,iconClass:"sort-desc"}];var 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);var 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(h.templates.filterByCondition,h.classNames.filterByCondition,!0,e)},_filterByValue:function(){var t="value"===this.viewModel.active;var n=this._appendTemplate(h.templates.filterByValue,h.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(h.templates.actionButtons,h.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(h.classNames.filterByValue)?this.viewModel.set("active","value"):n.hasClass(h.classNames.filterByCondition)&&this.viewModel.set("active","custom")}});e.spreadsheet.FilterMenu=h,t.extend(!0,h,{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;var 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()};let i=function(r){-1===this.events.indexOf("pdfExport")&&(e.PDFMixin.extend(this),this.saveAsPDF=i,this._drawPDF=n);var o=new t.Deferred;var a=o.promise();var 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;let r=e.ui.Widget;let o=".kendoSpreadsheet";let a=e.spreadsheet.commonEngine;let s=e.spreadsheet.FormulaInput;let l=e.spreadsheet.SheetsBar;function c(e){return e.map((function(e){return'[data-action="'+e+'"]'})).join(",")}function d(e){const t=i.Deferred();e.then((function(e){t.resolve(e)}),(function(e){t.reject(e)})),"function"==typeof e.progress&&e.progress((function(e){t.notify(e)}));const n=t.promise();return n.progress=function(e){return t.progress(e),n},n}let h=c(["cut","copy","paste","insert-left","insert-right","insert-above","insert-below"]);let u=c(["unhide-row","unhide-column"]);let p=a.View.classNames;e.spreadsheet.ContextMenu=e.ui.ContextMenu;let f=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 m{constructor({list:e,popup:t}){this.current={list:e,popup:t},this.clone=function(){return this}}}class g{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;let r=new e.data.DataSource({transport:{read:function(e){let t=n.nameEditor()?.readData()||[];e.success(t)},cache:!1}});let 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 v=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(v.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(){const t=this;const n=function(e,t){const n={};for(let i in e)e.hasOwnProperty(i)&&-1===t.indexOf(i)&&(n[i]=e[i]);return n}(t.options,t.events);let r=i.extend({},n,{sheetsbar:0!=t.options.sheetsbar?t.options.sheetsbar:{},formulaBarInputRef:new m({list:this._formulaBarInputRefList,popup:this._formulaBarInputRefPopup}),formulaCellInputRef:new m({list:this._formulaCellInputRefList,popup:this._formulaCellInputRefPopup}),nameBoxRef:new g({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;let c=i.extend({},{pdfExport:t.options.pdf,excelExport:t.options.excel},l);let d=e.spreadsheet.dialogs.create(n.name,c);const h=function(t,n,i){e.saveAs({dataURI:t,fileName:n,...i})};d&&(d.bind("action",(function(n){if("SaveAsCommand"==n.command){let{sender:r,...o}=n;let 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:h}));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;const s=e.sender.activeSheet().select();const{topLeft:l,bottomRight:c}=s;let d;this._cellContextMenu.close(),this._colHeaderContextMenu.close(),this._rowHeaderContextMenu.close(),this._drawingContextMenu.close(),d="columnheader"==n?this._colHeaderContextMenu:"rowheader"==n?this._rowHeaderContextMenu:"drawing"==n?this._drawingContextMenu:this._cellContextMenu,d.element.find(h).toggle(!a),d.element.find(u).toggle(i),d.element.find("[data-action=unmerge]").toggle(r),setTimeout((function(){d.open(e.originalEvent.pageX,e.originalEvent.pageY)}))},locale:e.cultures.current.name,intl:e.kendoCultureToIntl()});return new e.spreadsheet.commonEngine.SpreadsheetWidget(this.element[0],r)},_createFormulaInputs:function(){let t=this.element.find(".k-spreadsheet-action-bar .k-spreadsheet-formula-input");let n=e.guid();t.attr("aria-controls",n),this._formulaBarInputRefList=new f(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");let o=e.guid();r.attr("aria-controls",o),this._formulaCellInputRefList=new f(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;let n={target:this.element,animation:!1,showOn:"never"};this._cellContextMenu=new e.spreadsheet.ContextMenu(i((({messages:e})=>`\n <ul class="${p.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="${p.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="${p.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="${p.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=this;let n;switch(i(e.item).data("action")){case"cut":n={command:"ToolbarCutCommand",options:{workbook:this.spreadsheetRef.workbook}};break;case"copy":n={command:"ToolbarCopyCommand",options:{workbook:this.spreadsheetRef.workbook}};break;case"paste":n={command:"ToolbarPasteCommand",options:{workbook:this.spreadsheetRef.workbook}};break;case"delete-drawing":n={command:"DeleteDrawingCommand",options:{drawing:this.spreadsheetRef._controller.navigator._sheet._activeDrawing}};break;case"bring-to-front":n={command:"BringToFrontCommand",options:{drawing:this.spreadsheetRef._controller.navigator._sheet._activeDrawing}};break;case"send-to-back":n={command:"SendToBackCommand",options:{drawing:this.spreadsheetRef._controller.navigator._sheet._activeDrawing}};break;case"unmerge":n={command:"MergeCellCommand",options:{value:"unmerge"}};break;case"merge":this.spreadsheetRef.openDialog("merge");break;case"hide-row":n={command:"HideLineCommand",options:{axis:"row"}};break;case"hide-column":n={command:"HideLineCommand",options:{axis:"column"}};break;case"unhide-row":n={command:"UnHideLineCommand",options:{axis:"row"}};break;case"unhide-column":n={command:"UnHideLineCommand",options:{axis:"column"}};break;case"delete-row":n={command:"DeleteRowCommand"};break;case"delete-column":n={command:"DeleteColumnCommand"}}n&&t.spreadsheetRef.executeCommand(n)},_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;let i=t.sheetByName(n);let r=t.sheetIndex(i);let 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;let i=t.sheetByName(n);let r=t.sheets().filter((e=>"visible"===e.state()));let o=r.findIndex((e=>e.name()===n));let 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,r,o){let a=this;a.toolbar&&(a.toolbar.destroy(),a.toolbar.element.empty());let s=r.findIndex((e=>e.id===o));let l=r[s];let c=n[l.id];a._activeToolBar=l.text,a.toolbar=new e.spreadsheet.ToolBar(this.element.find("[ref-header-toolbar]"),{tools:"boolean"==typeof c?t:c,overflow:i.isPlainObject(n.overflow)?n.overflow:t,toolbarName:l.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}),a.spreadsheetRef.executeCommand(e)):a.spreadsheetRef.workbook.undoRedoStack[e.command]()},dialog:function(e){a.spreadsheetRef.openDialog(e.name,e.options)}}),a.toolbar.element.attr("aria-label",l.text)},_initHeader:function(){let t=this;let r=this.options.messages.tabs;let o=i.extend(!0,{file:!0,home:!0,insert:!0,format:!0,data:!0,view:!0},this.options.toolbar);let 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})},_workbookRender:function(e){this.trigger("render",e)&&e.preventDefault()},_workbookChanging:function(e){this.trigger("changing",e)&&e.preventDefault()},_workbookChange:function(e){this.trigger("change",{range:e.range})&&e.preventDefault()},_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(t){const n=i.extend({},this.options.excel,t,{Workbook:e.ooxml.Workbook,saveAs:function(t,n,i){e.saveAs({dataURI:t,fileName:n,...i})}});this.spreadsheetRef.saveAsExcel(n)},draw:function(e,t){this.spreadsheetRef.draw(e,t)},_workbookExcelExport:function(e){this.trigger("excelExport",e)&&e.preventDefault()},_workbookExcelImport:function(e){const t={file:e.file,sender:e.sender,preventDefault:e.preventDefault,isDefaultPrevented:e.isDefaultPrevented,promise:d(e.deferred),_defaultPrevented:e._defaultPrevented};this.trigger("excelImport",t)?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);let 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("render",this._workbookRender.bind(this)),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(v),i.extend(!0,v,{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){var t;var n=0;var i=e.length;for(;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 h(t){var n=e(t).closest(".k-pivot-setting");return n.length?n.data("kendoPivotSettingTarget"):null}var u=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 hy({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;var r=n.options;var a=r.messages;var s="horizontal"==r.orientation;var 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;var r=n.panel.find(".k-column-fields").first();var o=n.panel.find(".k-row-fields");var a=n.panel.find(".k-chip-list").last();var s=this.options;var 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");var i=n.attr(t.attr("uid"));var 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;var 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);var i={type:lw.toggleSelection,payload:n};var r={columnAxes:t.columns._state(),rowAxes:t.rows._state(),measureAxes:t.measures._state()};var o=cw(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;var r=n.dataSource.transport;var o=r.catalog();var a=r.cube();var s={url:r.options.read};var c=n.columns._state();var h=n.rows._state();var u=n.measures._state();var p=c.concat(h).concat(u);var f;var g;e.isEmptyObject(t.data)?n.dataSource.cubeSchema?(f=n.dataSource.cubeSchema.dimensions(),n._checkMembers(p,f),t.success(f)):Bb(s,{connection:{catalog:o,cube:a},restrictions:{catalogName:o,cubeName:a},command:"schemaDimensions"}).then((function(e){n._checkMembers(p,e),l(e),t.success(e)})):(i=n.treeView.dataSource.get(t.data.uniqueName),n.dataSource.cubeSchema?(g=n.dataSource.measures(),n._checkMembers(p,g),t.success(g)):"[KPIs]"===i.uniqueName?Bb(s,n._getKPIOptions(o,a)).then((function(e){t.success(d(e))})):"kpi"==i.type?t.success(m(i)):Bb(s,n._loadFieldsCommand(i,o,a)).then((function(e){n._checkMembers(p,e),t.success(e)})))}}})},_checkMembers:function(e,t){var n={};var 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;var r;var 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(u);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;var 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";var n=h(e.dropTarget);n&&n.validate(this.dataItem(e.sourceNode))&&(t="plus"),e.setStatusClass(t)},drop:function(e){e.preventDefault();var t=h(e.dropTarget);var n=this.dataItem(e.sourceNode);var i,r,o;var a;if(t&&t.validate(n)){if(a=n.defaultHierarchy||n.uniqueName,"kpi"===n.type)for(r=(o=m(n)).length,a=[],i=0;i<r;i++)a.push(c(o[i]));else n.kpi&&(a=[c(n)]);t.add(a)}}}).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;var 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);var n=e(s({name:this.options.messages.columnsLabel,icon:"columns"})).appendTo(t);var i=e('<div class="k-column-fields k-chip-list" />').appendTo(n.find(".k-pivotgrid-target-wrap"));var r=e(s({name:this.options.messages.rowsLabel,icon:"rows"})).appendTo(t);var o=e('<div class="k-column-fields k-chip-list" />').appendTo(r.find(".k-pivotgrid-target-wrap"));var l=e(s({name:this.options.messages.measuresLabel,icon:"sum"})).appendTo(t);var c=e('<div class="k-column-fields k-chip-list" />').appendTo(l.find(".k-pivotgrid-target-wrap"));var 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;var 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 KE=function(e,t,n){var i=function(){n(),e.removeEventListener(t,i,!1)};var r=function(){return e.addEventListener(t,i,!1)};return r(),{remove:r}};var YE=function(e,t){return function(n){var i=n.target;var r=i.document||i.ownerDocument;var o;if((o=t.container?t.container(i):function(e,t){if(e.closest)return e.closest(t);var n=Element.prototype.matches?function(e,t){return e.matches(t)}:function(e,t){return e.msMatchesSelector(t)};var i=e;for(;i;){if(n(i,t))return i;i=i.parentElement}}(i,e),o)&&!(/focus/i.test(n.type)&&o.classList.contains("k-ripple-target")))if(i.classList.contains("k-checkbox")||i.classList.contains("k-radio"))n.target.classList.remove("k-ripple-focus"),"animationend"!==n.type&&n.target.classList.add("k-ripple-focus");else{o.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]}(r),s=a[0],l=a[1];var c={animated:!1,released:!1,blob:l,container:o,ripple:s};var d={focusin:"focusout",keydown:"keyup",mousedown:"mouseup",pointerdown:"pointerup",touchdown:"touchup",animationstart:"animationend"}[n.type];KE(n.currentTarget,d,(function(){return XE(c)})),o.appendChild(s),window.getComputedStyle(s).getPropertyValue("opacity");var h=o.getBoundingClientRect();var u=0;var p=0;/mouse|pointer|touch/.test(n.type)?(u=n.clientX-h.left,p=n.clientY-h.top):(u=h.width/2,p=h.height/2);var f=u-(u<h.width/2?h.width:0);var m=p-(p<h.height/2?h.height:0);var 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: "+u+"px;\n top: "+p+"px;\n ",setTimeout((function(){return QE(c)}),500)}}};var QE=function(e){e.animated=!0,ZE(e)};var XE=function(e){e.released=!0,ZE(e)};var ZE=function(e){if(e.released&&e.animated){var t=e.blob,n=e.ripple,i=e.container;i&&KE(i,"blur",(function(){return i.classList.remove("k-ripple-target")})),t&&(KE(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;var 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;var t=e.element[0];var n=e.options.elements;e.removeListeners();var i=function(e,t){var n=(i=t.map((function(t){var n={events:["mousedown","touchdown"],global:!1};var i=t.selector,r=t.options,o=void 0===r?n:r;var a=YE(i,o);var s=o.events||n.events;var 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([],i));var i;return function(){e&&(n.forEach((function(t){var n=t.events,i=t.options,r=t.activator;var 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 JE=function(e,t){return function(n){return t(e(n))}};var eI=function(e,t,n){return e.addEventListener&&e.addEventListener(t,n)};var tI=function(e,t,n){return e&&e.removeEventListener&&e.removeEventListener(t,n)};var nI=function(){};var iI=function(e){return e.preventDefault()};var rI=/touch/;function oI(e){return e.type.match(rI)?{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 aI=function(e){var t=this;var n=e.press;void 0===n&&(n=nI);var i=e.drag;void 0===i&&(i=nI);var r=e.release;void 0===r&&(r=nI);var o=e.mouseOnly;void 0===o&&(o=!1),this._pressHandler=JE(oI,n),this._dragHandler=JE(oI,i),this._releaseHandler=JE(oI,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||(eI(t.document,"mousemove",t._mousemove),eI(t.document,"mouseup",t._mouseup),t._pressHandler(e))},this._mousemove=function(e){t._dragHandler(e)},this._mouseup=function(e){tI(t.document,"mousemove",t._mousemove),tI(t.document,"mouseup",t._mouseup),t._releaseHandler(e)},this._pointerdown=function(e){e.isPrimary&&0===e.button&&(eI(t.document,"pointermove",t._pointermove),eI(t.document,"pointerup",t._pointerup),eI(t.document,"pointercancel",t._pointerup),eI(t.document,"contextmenu",iI),t._pressHandler(e))},this._pointermove=function(e){e.isPrimary&&t._dragHandler(e)},this._pointerup=function(e){e.isPrimary&&(tI(t.document,"pointermove",t._pointermove),tI(t.document,"pointerup",t._pointerup),tI(t.document,"pointercancel",t._pointerup),tI(t.document,"contextmenu",iI),t._releaseHandler(e))}};var sI={document:{configurable:!0}};aI.supportPointerEvent=function(){return"undefined"!=typeof window&&window.PointerEvent},sI.document.get=function(){return this._element?this._element.ownerDocument:document},aI.prototype.cancelDrag=function(){tI(this.document,"pointermove",this._pointermove),tI(this.document,"pointerup",this._pointerup),tI(this.document,"pointercancel",this._pointerup)},aI.prototype.bindTo=function(e){e!==this._element&&(this._element&&this._unbindFromCurrent(),this._element=e,this._bindToCurrent())},aI.prototype._bindToCurrent=function(){var e=this._element;this._usePointers()?eI(e,"pointerdown",this._pointerdown):(eI(e,"mousedown",this._mousedown),this._mouseOnly||(eI(e,"touchstart",this._touchstart),eI(e,"touchmove",this._touchmove),eI(e,"touchend",this._touchend)))},aI.prototype._unbindFromCurrent=function(){var e=this._element;if(this._usePointers())return tI(e,"pointerdown",this._pointerdown),tI(this.document,"pointermove",this._pointermove),tI(this.document,"pointerup",this._pointerup),tI(this.document,"contextmenu",iI),void tI(this.document,"pointercancel",this._pointerup);tI(e,"mousedown",this._mousedown),this._mouseOnly||(tI(e,"touchstart",this._touchstart),tI(e,"touchmove",this._touchmove),tI(e,"touchend",this._touchend))},aI.prototype._usePointers=function(){return!this._mouseOnly&&aI.supportPointerEvent()},aI.prototype.update=function(e){var t=e.press;void 0===t&&(t=nI);var n=e.drag;void 0===n&&(n=nI);var i=e.release;void 0===i&&(i=nI);var r=e.mouseOnly;void 0===r&&(r=!1),this._pressHandler=JE(oI,t),this._dragHandler=JE(oI,n),this._releaseHandler=JE(oI,i),this._mouseOnly=r},aI.prototype.destroy=function(){this._unbindFromCurrent(),this._element=null},Object.defineProperties(aI.prototype,sI),aI.default=aI;function lI(e,t,n){void 0===n&&(n={});var i=pI;if(n.forceProxy&&!n.proxyURL)throw new Error("No proxyURL is set, but forceProxy is true");n.forceProxy||(dI()&&(i=uI),navigator.msSaveBlob&&(i=hI)),i(e,t,n)}var cI=function(){return document.createElement("a")};var dI=function(){return"download"in cI()};function hI(e,t){var n=e;if("string"==typeof e){var i=e.split(";base64,");var r=i[0];var o=atob(i[1]);var a=new Uint8Array(o.length);for(var s=0;s<o.length;s++)a[s]=o.charCodeAt(s);n=new Blob([a.buffer],{type:r})}navigator.msSaveBlob(n,t)}function uI(e,t){var n=e;window.Blob&&e instanceof Blob&&(n=URL.createObjectURL(e));var i=cI();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 pI(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:fI,AnnotationEditorType:mI,FeatureTest:gI,setLayerDimensions:vI,AnnotationEditorParamsType:_I,PixelsPerInch:bI,DOMSVGFactory:wI,PDFDateString:yI,Util:kI,XfaLayer:xI,getDocument:CI,AnnotationMode:SI,AbortException:TI,TextLayer:MI,fetchData:AI,noContextMenu:DI}=window.pdfjsLib||{AnnotationEditorType:{DISABLE:-1,NONE:0,FREETEXT:3,HIGHLIGHT:9,STAMP:13,INK:15}};const EI=(...e)=>Object.assign(...e);const II=e=>e&&"object"==typeof e&&!Array.isArray(e);const zI=e=>e instanceof HTMLElement;const PI=e=>e&&window&&window.DotNet&&window.DotNet.DotNetObject&&e instanceof DotNet.DotNetObject;const LI=(e,...t)=>{if(!t.length)return e;const n=t.shift();if(II(e)&&II(n))for(const t in n)"__proto__"!==t&&"constructor"!==t&&(n[t]instanceof $I||zI(n[t])||"dotNetInstance"===t||PI(n[t])||n[t]&&n[t].buffer&&n[t].buffer instanceof ArrayBuffer||II(n[t])&&Object.getPrototypeOf(n[t])!==Object.prototype?e[t]=n[t]:II(n[t])?(e[t]&&II(e[t])||EI(e,{[t]:{}}),LI(e[t],n[t])):EI(e,{[t]:n[t]}));return LI(e,...t)};const BI=e=>"string"==typeof e;const HI=e=>Array.from(e);const RI=e=>(e=>void 0!==e)(e)&&(e=>null!==e)(e);const FI=function(){};const OI=(e,t)=>{const n=(t||document).createElement("template");n.innerHTML=e.trim();const i=n.content;return i.childNodes.length>1?i.childNodes:i.firstChild};const VI=e=>(null==e?void 0:e.startsWith("."))?e:`.${e}`;const NI=()=>{let e;let t;const n=new Promise((function(n,i){e=n,t=i}));return n.resolve=e,n.reject=t,n};class $I{constructor(e,t){this.options={events:{}},this.element=e,this.options=t}destroy(){this.element=null}extendOptions(e){this.options=LI(this.options,e)}setOptions(e){this.options=e}trigger(e,t={}){const n={defaultPrevented:!1,preventDefault:()=>{n.defaultPrevented=!0}};return this.options.events&&"function"==typeof this.options.events[e]&&this.options.events[e](EI(n,t,{sender:this})),n.defaultPrevented}}const UI=function(e,t,n={}){let i,r,o,a;let 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}};const WI=1e3/60;const jI="scroll";let qI=class extends $I{constructor(e,t){super(e,t),this.options={events:{[jI]:FI},filter:"",panScrollThrottleDelay:WI,scrollDirectionModifier:-1,scrollThrottleDelay:WI},this.onElementScroll=e=>{const t=this.element;this.shouldTrackScrollEvents()&&(this.state.trackNextElementScroll?this.scrollTo(t.scrollLeft,t.scrollTop):this.state.trackNextElementScroll=!0,this.trigger(jI,{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;const n=this.element.scrollLeft+t*this.state.locationDelta.x;const i=this.element.scrollTop+t*this.state.locationDelta.y;this.scrollTo(n,i)},this.onDragEnd=()=>{},this.extendOptions(t),this.resetState(),this.bindEvents()}destroy(){this.unbindEvents()}initDraggable(){this.destroyDraggable(),this.options.panScrollThrottleDelay>0?this.throttledOnDrag=UI(this.onDrag,this.options.panScrollThrottleDelay):this.throttledOnDrag=this.onDrag,this.draggable=new aI({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=UI(this.onElementScroll,this.options.scrollThrottleDelay):this.throttledOnElementScroll=this.onElementScroll,this.element.addEventListener(jI,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(jI,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 GI=e=>{const t=e.parentElement;e&&t&&t.replaceWith(...Array.from(t.childNodes))};const KI=(e,t)=>{t.classList.add(e)};const YI=e=>`.${e}`;const QI="data-char-index";const XI="data-match-index";class ZI{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(),this.resetState()}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);const 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=>{const t=e.textContent;HI(e.childNodes).forEach((t=>{e.removeChild(t)}));const n=e.ownerDocument.createTextNode(t);e.appendChild(n)}))}))}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),e.textContent="";this.splitTextByChars(t).forEach((e=>{n.appendChild(e)})),GI(n.childNodes[0])}splitTextByChars(e){const t=[];for(let n=0;n<e.length;n++){const i=document.createElement("span");KI(this.options.charClass,i),i.setAttribute(`${QI}`,`${this.state.charIndex}`),i.textContent=e[n],t.push(i),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(YI(`${this.options.charClass}[${QI}='${i}']`))).forEach((e=>{KI(this.options.highlightClass,e),e.setAttribute(XI,n)}))}))}removeMatchHighlights(){this.forEachTextContainer((e=>{Array.from(e.querySelectorAll(YI(this.options.highlightClass))).forEach((e=>{((e,t)=>{t.classList.remove(e)})(this.options.highlightClass,e),e.removeAttribute(XI)}))}))}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(YI(this.options.charClass+"["+XI+"='"+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(YI(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++)GI(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(YI(this.options.highlightMarkClass));n&&(e=n)})),e}}const JI=268435456;const ez=1.25;const tz=(e=3)=>/iPad|iPhone|iPod/.test(navigator.userAgent)||navigator.maxTouchPoints&&navigator.maxTouchPoints>2&&/Macintosh/i.test(navigator.userAgent)?devicePixelRatio:devicePixelRatio*(e||3);const nz=e=>atob(e.replace(/^(data:application\/pdf;base64,)/gi,""));const iz=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};const rz=(e,t)=>{const n=e.querySelectorAll(".k-page");const i=n[0];if(i instanceof HTMLDivElement){const e=(i.offsetHeight+i.offsetTop)*Math.max(0,Math.min(t,n.length-1));const r=i.closest(".k-pdf-viewer-canvas");r&&r.scrollTo({top:e,behavior:"auto"})}};const oz=e=>{const t=e.querySelector(".k-pdf-viewer-canvas");const n=e.querySelector(".k-page:not(.k-blank-page)");return t&&n?Math.floor(Math.round(t.scrollTop)/Math.max(1,n.offsetHeight+n.offsetTop)+.01):0};const az=(e,t)=>{const{maxWidth:n,maxHeight:i,maxArea:r}=(e=>{const t=Dr(e);const n=Ar(e);return t&&t.mozilla||n&&"firefox"===n.browser})(navigator.userAgent)?{maxWidth:32767,maxHeight:32767,maxArea:124992400}:(e=>Dr(e).safari||Ar(e)&&"mobilesafari"===Ar(e).browser)(navigator.userAgent)?{maxWidth:4194303,maxHeight:8388607,maxArea:JI}:{maxWidth:65535,maxHeight:65535,maxArea:JI};let o=e;let 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}};function sz(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 lz(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 cz(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;const dz=(e,t)=>{t.classList.add(e)};const hz=(e,t)=>{t.classList.remove(e)};const uz=(e,t,n)=>Math.min(n,Math.max(t,e));const pz=1.35;const fz=1,mz=2;const gz="pdfjs_internal_editor_";const vz=3,_z=9;const bz=2,wz=3,yz=9,kz=16,xz=20;const Cz=1,Sz=2,Tz=3,Mz=4,Az=5;function Dz(e,t,n,i=!1){return Object.defineProperty(e,t,{value:n,enumerable:!i,configurable:!0,writable:!1}),n}const Ez=Array.from(Array(256).keys(),(e=>e.toString(16).padStart(2,"0")));class Iz{static makeHexColor(e,t,n){return`${Ez[e]}${Ez[t]}${Ez[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 zz="pdfjs_internal_id_";var Pz;class Lz{constructor(e=gz){Pz.set(this,0),this.idPrefix=gz,Object.defineProperty(this,"reset",{value:()=>cz(this,Pz,0,"f")}),this.idPrefix=e}get id(){var e,t;return`${this.idPrefix}${cz(this,Pz,(t=lz(this,Pz,"f"),e=t++,t),"f"),e}`}}var Bz,Hz,Rz,Fz;Pz=new WeakMap;class Oz{constructor(e=128){Bz.set(this,[]),Hz.set(this,!1),Rz.set(this,void 0),Fz.set(this,-1),cz(this,Rz,e,"f")}add({cmd:e,undo:t,post:n,mustExec:i,type:r=NaN,overwriteIfSameType:o=!1,keepUndo:a=!1}){if(i&&e(),lz(this,Hz,"f"))return;const s={cmd:e,undo:t,post:n,type:r};if(-1===lz(this,Fz,"f"))return lz(this,Bz,"f").length>0&&(lz(this,Bz,"f").length=0),cz(this,Fz,0,"f"),void lz(this,Bz,"f").push(s);if(o&&lz(this,Bz,"f")[lz(this,Fz,"f")].type===r)return a&&(s.undo=lz(this,Bz,"f")[lz(this,Fz,"f")].undo),void(lz(this,Bz,"f")[lz(this,Fz,"f")]=s);const l=lz(this,Fz,"f")+1;l===lz(this,Rz,"f")?lz(this,Bz,"f").splice(0,1):(cz(this,Fz,l,"f"),l<lz(this,Bz,"f").length&&lz(this,Bz,"f").splice(l)),lz(this,Bz,"f").push(s)}undo(){if(-1===lz(this,Fz,"f"))return;cz(this,Hz,!0,"f");const{undo:e,post:t}=lz(this,Bz,"f")[lz(this,Fz,"f")];e(),null==t||t(),cz(this,Hz,!1,"f"),cz(this,Fz,lz(this,Fz,"f")-1,"f")}redo(){if(lz(this,Fz,"f")<lz(this,Bz,"f").length-1){cz(this,Fz,lz(this,Fz,"f")+1,"f"),cz(this,Hz,!0,"f");const{cmd:e,post:t}=lz(this,Bz,"f")[lz(this,Fz,"f")];e(),null==t||t(),cz(this,Hz,!1,"f")}}hasSomethingToUndo(){return-1!==lz(this,Fz,"f")}hasSomethingToRedo(){return lz(this,Fz,"f")<lz(this,Bz,"f").length-1}destroy(){cz(this,Bz,null,"f")}}var 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,hP,uP,pP,fP,mP,gP,vP,_P,bP,wP,yP,kP,xP,CP,SP,TP,MP,AP,DP,EP,IP,zP,PP,LP,BP,HP,RP,FP;Bz=new WeakMap,Hz=new WeakMap,Rz=new WeakMap,Fz=new WeakMap;class OP{constructor({container:e=null,viewer:t,pdfViewer:n,eventBus:i,pdfDocument:r,highlightColors:o=""}){Vz.add(this),this.pdfViewer=null,this.annotationEditorMode=mI.NONE,this.viewParameters={},this.isShiftKeyDown=!1,this._eventBus=null,Nz.set(this,new AbortController),$z.set(this,null),Uz.set(this,new Map),Wz.set(this,new Map),jz.set(this,null),qz.set(this,null),Gz.set(this,new Oz),Kz.set(this,0),Yz.set(this,new Set),Qz.set(this,null),Xz.set(this,null),Zz.set(this,new Set),Jz.set(this,!0),eP.set(this,null),tP.set(this,null),nP.set(this,""),iP.set(this,!1),rP.set(this,null),oP.set(this,new Lz),aP.set(this,!1),sP.set(this,!1),lP.set(this,null),cP.set(this,mI.NONE),dP.set(this,new Set),hP.set(this,null),uP.set(this,null),pP.set(this,{isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1,hasSelectedText:!1}),fP.set(this,[0,0]),mP.set(this,null),gP.set(this,null),vP.set(this,null);const a=this._signal=lz(this,Nz,"f").signal;cz(this,gP,e,"f"),cz(this,vP,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}),this._eventBus._on("namedaction",this.onNamedAction.bind(this),{signal:a}),lz(this,Vz,"m",xP).call(this),lz(this,Vz,"m",EP).call(this),lz(this,Vz,"m",TP).call(this),cz(this,jz,r.annotationStorage,"f"),cz(this,nP,o||"","f"),this.viewParameters={realScale:bI.PDF_TO_CSS_UNITS,rotation:0}}destroy(){var e;null===(e=lz(this,Nz,"f"))||void 0===e||e.abort(),cz(this,Nz,null,"f"),this._signal=null;for(const e of lz(this,Wz,"f").values())e.destroy();lz(this,Wz,"f").clear(),lz(this,Uz,"f").clear(),lz(this,Zz,"f").clear(),cz(this,$z,null,"f"),lz(this,dP,"f").clear(),lz(this,Gz,"f").destroy(),lz(this,eP,"f")&&(clearTimeout(lz(this,eP,"f")),cz(this,eP,null,"f")),lz(this,mP,"f")&&(clearTimeout(lz(this,mP,"f")),cz(this,mP,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 fI(this,"direction",getComputedStyle(lz(this,gP,"f")).direction)}get highlightColors(){return fI(this,"highlightColors",lz(this,nP,"f")?new Map:null)}get highlightColorNames(){return fI(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}onNamedAction(e){switch(e.action){case"Print":this.triggerPrinting();break;case"SaveAs":this.downloadOrSave()}}onPageChanging({pageNumber:e}){cz(this,Kz,e-1,"f")}focusMainContainer(){var e;null===(e=lz(this,gP,"f"))||void 0===e||e.focus()}findParent(e,t){for(const n of lz(this,Wz,"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}triggerPrinting(){var e;null===(e=this.pdfViewer)||void 0===e||e.printFile()}downloadOrSave(){var e,t;null===(e=this.pdfViewer)||void 0===e||e.downloadFile({fileName:null===(t=this.pdfViewer)||void 0===t?void 0:t.options.downloadFileName})}disableUserSelect(e=!1){var t;null===(t=lz(this,vP,"f"))||void 0===t||t.classList.toggle("noUserSelect",e)}addShouldRescale(e){lz(this,Zz,"f").add(e)}removeShouldRescale(e){lz(this,Zz,"f").delete(e)}onScaleChanging({scale:e}){this.commitOrRemove(),this.viewParameters.realScale=e*bI.PDF_TO_CSS_UNITS;for(const e of lz(this,Zz,"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;const a=t.toString();const s=lz(this,Vz,"m",_P).call(this,t);const l=this.getTextLayerForAnchor(s);const c=this.getSelectionBoxes(l);if(!c)return;t.empty();const d=lz(this,Vz,"m",bP).call(this,l);const h=lz(this,cP,"f")===mI.NONE;const u=()=>{null==d||d.createAndAddNewEditor({x:0,y:0},!1,{methodOfCreation:e,boxes:c,anchorNode:n,anchorOffset:i,focusNode:r,focusOffset:o,text:a}),h&&this.showAllEditors("highlight",!0)};h?this.switchToMode(mI.HIGHLIGHT,u):u()}showEditorToolBar(e){if(!e)return;const t=this.getMode();t!==mI.HIGHLIGHT&&t!==mI.FREETEXT||this._eventBus.dispatch("kendoAnnotationEditorToolBarShow",{source:this,anchor:e})}hideEditorToolBar(){this._eventBus.dispatch("kendoAnnotationEditorToolBarHide",{source:this})}addToAnnotationStorage(e){e.isEmpty()||!lz(this,jz,"f")||lz(this,jz,"f").has(e.id)||lz(this,jz,"f").setValue(e.id,e)}blur(){if(this.isShiftKeyDown=!1,lz(this,iP,"f")&&(cz(this,iP,!1,"f"),lz(this,Vz,"m",kP).call(this,"main_toolbar")),!this.hasSelection)return;const{activeElement:e}=document;for(const t of lz(this,dP,"f"))if(t.div.contains(e)){cz(this,lP,[t,e],"f"),t._focusEventsAllowed=!1;break}}focus(){if(!lz(this,lP,"f"))return;const[e,t]=lz(this,lP,"f");cz(this,lP,null,"f"),t.addEventListener("focusin",(()=>{e._focusEventsAllowed=!0}),{once:!0,signal:this._signal}),t.focus()}addEditListeners(){lz(this,Vz,"m",TP).call(this),lz(this,Vz,"m",AP).call(this)}removeEditListeners(){lz(this,Vz,"m",MP).call(this),lz(this,Vz,"m",DP).call(this)}dragOver(e){for(const{type:t}of e.dataTransfer.items)for(const n of lz(this,Xz,"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 lz(this,Xz,"f"))if(n.isHandlingMimeForPasting(t.type))return n.paste(t,this.currentLayer),void e.preventDefault()}copy(e){var t;if(e.preventDefault(),null===(t=lz(this,$z,"f"))||void 0===t||t.commitOrRemove(),!this.hasSelection)return;const n=[];for(const e of lz(this,dP,"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 lz(this,Xz,"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)lz(this,Vz,"m",BP).call(this,t);lz(this,Vz,"m",FP).call(this,e)};const 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?(lz(this,Vz,"m",CP).call(this),lz(this,Vz,"m",AP).call(this),lz(this,Vz,"m",IP).call(this,{isEditing:lz(this,cP,"f")!==mI.NONE,isEmpty:lz(this,Vz,"m",RP).call(this),hasSomethingToUndo:lz(this,Gz,"f").hasSomethingToUndo(),hasSomethingToRedo:lz(this,Gz,"f").hasSomethingToRedo(),hasSelectedEditor:!1})):(lz(this,Vz,"m",SP).call(this),lz(this,Vz,"m",DP).call(this),lz(this,Vz,"m",IP).call(this,{isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(e){if(!lz(this,Xz,"f")){cz(this,Xz,e,"f");for(const e of lz(this,Xz,"f"))lz(this,Vz,"m",zP).call(this,e.defaultPropertiesToUpdate)}}getId(){return lz(this,oP,"f").id}get currentLayer(){return lz(this,Wz,"f").get(lz(this,Kz,"f"))}getLayer(e){return lz(this,Wz,"f").get(e)}get currentPageIndex(){return lz(this,Kz,"f")}addLayer(e){lz(this,Wz,"f").set(e.pageIndex,e),lz(this,aP,"f")?e.enable():e.disable()}removeLayer(e){lz(this,Wz,"f").delete(e.pageIndex)}updateMode(e,t=null,n=!1){if(lz(this,cP,"f")!==e){if(cz(this,cP,e,"f"),e===mI.NONE)return this.setEditingState(!1),void lz(this,Vz,"m",LP).call(this);this.setEditingState(!0),lz(this,Vz,"m",PP).call(this),this.unselectAll();for(const t of lz(this,Wz,"f").values())t.updateMode(e);if(t||!n){if(t)for(const e of lz(this,Uz,"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!==lz(this,cP,"f")&&this._eventBus.dispatch("switchannotationeditormode",{source:this,mode:e})}updateParams(e,t){if(lz(this,Xz,"f")){switch(e){case _I.CREATE:return void this.currentLayer.addNewEditor();case _I.HIGHLIGHT_DEFAULT_COLOR:break;case _I.HIGHLIGHT_SHOW_ALL:cz(this,uP,lz(this,uP,"f")||new Map,"f").set(e,t),this.showAllEditors("highlight",t)}for(const n of lz(this,dP,"f"))n.updateParams(e,t);for(const n of lz(this,Xz,"f"))n.updateDefaultParams(e,t)}}showAllEditors(e,t){var n,i;for(const n of lz(this,Uz,"f").values())n.editorType===e&&n.show(t);(null===(i=null===(n=lz(this,uP,"f"))||void 0===n?void 0:n.get(_I.HIGHLIGHT_SHOW_ALL))||void 0===i||i)!==t&&lz(this,Vz,"m",zP).call(this,[[_I.HIGHLIGHT_SHOW_ALL,t]])}enableWaiting(e=!1){if(lz(this,sP,"f")!==e){cz(this,sP,e,"f");for(const t of lz(this,Wz,"f").values())e?t.disableClick():t.enableClick(),t.div.classList.toggle("waiting",e)}}getEditors(e){const t=[];for(const n of lz(this,Uz,"f").values())n.pageIndex===e&&t.push(n);return t}getEditor(e){return lz(this,Uz,"f").get(e)}addEditor(e){lz(this,Uz,"f").set(e.id,e)}removeEditor(e){var t;e.div.contains(document.activeElement)&&(lz(this,eP,"f")&&clearTimeout(lz(this,eP,"f")),cz(this,eP,setTimeout((()=>{this.focusMainContainer(),cz(this,eP,null,"f")}),0),"f")),lz(this,Uz,"f").delete(e.id),this.unselect(e),e.annotationElementId&&lz(this,Yz,"f").has(e.annotationElementId)||null===(t=lz(this,jz,"f"))||void 0===t||t.remove(e.id)}addDeletedAnnotationElement(e){lz(this,Yz,"f").add(e.annotationElementId),this.addChangedExistingAnnotation(e),e.deleted=!0}isDeletedAnnotationElement(e){return lz(this,Yz,"f").has(e)}removeDeletedAnnotationElement(e){lz(this,Yz,"f").delete(e.annotationElementId),this.removeChangedExistingAnnotation(e),e.deleted=!1}setActiveEditor(e){lz(this,$z,"f")!==e&&(cz(this,$z,e,"f"),e&&lz(this,Vz,"m",zP).call(this,e.propertiesToUpdate))}updateUI(e){lz(this,Vz,"a",HP)===e&&lz(this,Vz,"m",zP).call(this,e.propertiesToUpdate)}toggleSelected(e){if(lz(this,dP,"f").has(e))return lz(this,dP,"f").delete(e),e.unselect(),void lz(this,Vz,"m",IP).call(this,{hasSelectedEditor:this.hasSelection});lz(this,dP,"f").add(e),e.select(),lz(this,Vz,"m",zP).call(this,e.propertiesToUpdate),lz(this,Vz,"m",IP).call(this,{hasSelectedEditor:!0})}setSelected(e){for(const t of lz(this,dP,"f"))t!==e&&t.unselect();lz(this,dP,"f").clear(),lz(this,dP,"f").add(e),e.select(),lz(this,Vz,"m",zP).call(this,e.propertiesToUpdate),lz(this,Vz,"m",IP).call(this,{hasSelectedEditor:!0})}isSelected(e){return lz(this,dP,"f").has(e)}get firstSelectedEditor(){return lz(this,dP,"f").values().next().value}unselect(e){e.unselect(),lz(this,dP,"f").delete(e),lz(this,Vz,"m",IP).call(this,{hasSelectedEditor:this.hasSelection})}get hasSelection(){return 0!==lz(this,dP,"f").size}get isEnterHandled(){return 1===lz(this,dP,"f").size&&this.firstSelectedEditor.isEnterHandled}undo(){lz(this,Gz,"f").undo(),lz(this,Vz,"m",IP).call(this,{hasSomethingToUndo:lz(this,Gz,"f").hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:lz(this,Vz,"m",RP).call(this)})}redo(){lz(this,Gz,"f").redo(),lz(this,Vz,"m",IP).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:lz(this,Gz,"f").hasSomethingToRedo(),isEmpty:lz(this,Vz,"m",RP).call(this)})}addCommands(e){lz(this,Gz,"f").add(e),lz(this,Vz,"m",IP).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:lz(this,Vz,"m",RP).call(this)})}delete(){if(this.commitOrRemove(),!this.hasSelection)return;const e=[...lz(this,dP,"f")];this.addCommands({cmd:()=>{for(const t of e)t.remove()},undo:()=>{for(const t of e)lz(this,Vz,"m",BP).call(this,t)},mustExec:!0})}commitOrRemove(){var e;null===(e=lz(this,$z,"f"))||void 0===e||e.commitOrRemove()}hasSomethingToControl(){return lz(this,$z,"f")||this.hasSelection}selectAll(){for(const e of lz(this,dP,"f"))e.commit();lz(this,Vz,"m",FP).call(this,lz(this,Uz,"f").values())}unselectAll(){if((!lz(this,$z,"f")||(lz(this,$z,"f").commitOrRemove(),lz(this,cP,"f")===mI.NONE))&&this.hasSelection){for(const e of lz(this,dP,"f"))e.unselect();lz(this,dP,"f").clear(),lz(this,Vz,"m",IP).call(this,{hasSelectedEditor:!1})}}translateSelectedEditors(e,t,n=!1){if(n||this.commitOrRemove(),!this.hasSelection)return;lz(this,fP,"f")[0]+=e,lz(this,fP,"f")[1]+=t;const[i,r]=lz(this,fP,"f");const o=[...lz(this,dP,"f")];lz(this,mP,"f")&&clearTimeout(lz(this,mP,"f")),cz(this,mP,setTimeout((()=>{cz(this,mP,null,"f"),lz(this,fP,"f")[0]=lz(this,fP,"f")[1]=0,this.addCommands({cmd:()=>{for(const e of o)lz(this,Uz,"f").has(e.id)&&e.translateInPage(i,r)},undo:()=>{for(const e of o)lz(this,Uz,"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),cz(this,Qz,new Map,"f");for(const e of lz(this,dP,"f"))lz(this,Qz,"f").set(e,{savedX:e.x,savedY:e.y,savedPageIndex:e.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!lz(this,Qz,"f"))return!1;this.disableUserSelect(!1);const e=lz(this,Qz,"f");cz(this,Qz,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(lz(this,Uz,"f").has(e.id)){const r=lz(this,Wz,"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(lz(this,Qz,"f"))for(const n of lz(this,Qz,"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 lz(this,$z,"f")===e}getActive(){return lz(this,$z,"f")}getActiveEditor(){return lz(this,$z,"f")}getMode(){return lz(this,cP,"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}){cz(this,qz,lz(this,qz,"f")||new Map,"f").set(e,t)}removeChangedExistingAnnotation({annotationElementId:e}){var t;null===(t=lz(this,qz,"f"))||void 0===t||t.delete(e)}renderAnnotationElement(e){var t;const n=null===(t=lz(this,qz,"f"))||void 0===t?void 0:t.get(e.data.id);if(!n)return;const i=lz(this,jz,"f").getRawValue(n);i&&(lz(this,cP,"f")!==mI.NONE||i.hasBeenModified)&&i.renderAnnotationElement(e)}}var VP;Nz=new WeakMap,$z=new WeakMap,Uz=new WeakMap,Wz=new WeakMap,jz=new WeakMap,qz=new WeakMap,Gz=new WeakMap,Kz=new WeakMap,Yz=new WeakMap,Qz=new WeakMap,Xz=new WeakMap,Zz=new WeakMap,Jz=new WeakMap,eP=new WeakMap,tP=new WeakMap,nP=new WeakMap,iP=new WeakMap,rP=new WeakMap,oP=new WeakMap,aP=new WeakMap,sP=new WeakMap,lP=new WeakMap,cP=new WeakMap,dP=new WeakMap,hP=new WeakMap,uP=new WeakMap,pP=new WeakMap,fP=new WeakMap,mP=new WeakMap,gP=new WeakMap,vP=new WeakMap,Vz=new WeakSet,_P=function({anchorNode:e}){return e.nodeType===Node.TEXT_NODE?e.parentElement:e},bP=function(e){const{currentLayer:t}=this;if(t.hasTextLayer(e))return t;for(const t of lz(this,Wz,"f").values())if(t.hasTextLayer(e))return t;return null},wP=function(){const e=document.getSelection();if(!e||e.isCollapsed)return;const t=lz(this,Vz,"m",_P).call(this,e);const n=this.getTextLayerForAnchor(t);this.getSelectionBoxes(n)&&this.showEditorToolBar(t)},yP=function(){var e,t;const n=document.getSelection();if(!n||n.isCollapsed)return void(lz(this,hP,"f")&&(cz(this,hP,null,"f"),lz(this,Vz,"m",IP).call(this,{hasSelectedText:!1})));const{anchorNode:i}=n;if(i===lz(this,hP,"f"))return;const r=lz(this,Vz,"m",_P).call(this,n);const o=this.getTextLayerForAnchor(r);if(o){if(null===(t=lz(this,rP,"f"))||void 0===t||t.hide(),cz(this,hP,i,"f"),lz(this,Vz,"m",IP).call(this,{hasSelectedText:!0}),(lz(this,cP,"f")===mI.HIGHLIGHT||lz(this,cP,"f")===mI.NONE)&&(lz(this,cP,"f")===mI.HIGHLIGHT&&this.showAllEditors("highlight",!0),!this.isShiftKeyDown)){const e=lz(this,cP,"f")===mI.HIGHLIGHT?lz(this,Vz,"m",bP).call(this,o):null;null==e||e.toggleDrawing();const t=new AbortController;const n=this.combinedSignal(t);const i=n=>{"pointerup"===n.type&&0!==n.button||(t.abort(),null==e||e.toggleDrawing(!0),"pointerup"===n.type&&lz(this,Vz,"m",kP).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 lz(this,hP,"f")&&(null===(e=lz(this,rP,"f"))||void 0===e||e.hide(),cz(this,hP,null,"f"),lz(this,Vz,"m",IP).call(this,{hasSelectedText:!1}))},kP=function(e=""){lz(this,cP,"f")===mI.HIGHLIGHT?this.highlightSelection(e):lz(this,Jz,"f")&&lz(this,Vz,"m",wP).call(this)},xP=function(){document.addEventListener("selectionchange",lz(this,Vz,"m",yP).bind(this),{signal:this._signal})},CP=function(){if(lz(this,tP,"f"))return;cz(this,tP,new AbortController,"f");const e=this.combinedSignal(lz(this,tP,"f"));window.addEventListener("focus",this.focus.bind(this),{signal:e}),window.addEventListener("blur",this.blur.bind(this),{signal:e})},SP=function(){var e;null===(e=lz(this,tP,"f"))||void 0===e||e.abort(),cz(this,tP,null,"f")},TP=function(){},MP=function(){},AP=function(){},DP=function(){},EP=function(){const e=this._signal;document.addEventListener("dragover",this.dragOver.bind(this),{signal:e}),document.addEventListener("drop",this.drop.bind(this),{signal:e})},IP=function(e){if(!e)return;const t=Object.entries(e).some((([e,t])=>lz(this,pP,"f")[e]!==t));t&&(this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(lz(this,pP,"f"),e)}),lz(this,cP,"f")===mI.HIGHLIGHT&&!1===e.hasSelectedEditor&&lz(this,Vz,"m",zP).call(this,[[_I.HIGHLIGHT_FREE,!0]]))},zP=function(e){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:e})},PP=function(){if(!lz(this,aP,"f")){cz(this,aP,!0,"f");for(const e of lz(this,Wz,"f").values())e.enable();for(const e of lz(this,Uz,"f").values())e.enable()}},LP=function(){if(this.unselectAll(),lz(this,aP,"f")){cz(this,aP,!1,"f");for(const e of lz(this,Wz,"f").values())e.disable();for(const e of lz(this,Uz,"f").values())e.disable()}},BP=function(e){const t=lz(this,Wz,"f").get(e.pageIndex);t?t.addOrRebuild(e):(this.addEditor(e),this.addToAnnotationStorage(e))},HP=function(){let e=null;for(e of lz(this,dP,"f"));return e},RP=function(){if(0===lz(this,Uz,"f").size)return!0;if(1===lz(this,Uz,"f").size)for(const e of lz(this,Uz,"f").values())return e.isEmpty();return!1},FP=function(e){for(const e of lz(this,dP,"f"))e.unselect();lz(this,dP,"f").clear();for(const t of e)t.isEmpty()||(lz(this,dP,"f").add(t),t.select());lz(this,Vz,"m",IP).call(this,{hasSelectedEditor:this.hasSelection})},OP.TRANSLATE_SMALL=1,OP.TRANSLATE_BIG=10;class NP{constructor(){VP.set(this,Object.create(null))}getListeners(){return lz(this,VP,"f")}on(e,t,n=null){this._on(e,t,{external:!0,once:null==n?void 0:n.once,signal:null==n?void 0:n.signal})}off(e,t){this._off(e,t)}dispatch(e,t){const n=lz(this,VP,"f")[e];if(!n||0===n.length)return;let i;for(const{listener:r,external:o,once:a}of n.slice(0))a&&this._off(e,r),o?(i||(i=[])).push(r):r(t);if(i){for(const e of i)e(t);i=null}}_on(e,t,n=null){var i;let r=null;if((null==n?void 0:n.signal)instanceof AbortSignal){const{signal:i}=n;if(i.aborted)return;const o=()=>this._off(e,t);r=()=>i.removeEventListener("abort",o),i.addEventListener("abort",o)}((i=lz(this,VP,"f"))[e]||(i[e]=[])).push({listener:t,external:!0===(null==n?void 0:n.external),once:!0===(null==n?void 0:n.once),rmAbort:r})}_off(e,t){var n;const i=lz(this,VP,"f")[e];if(i)for(let e=0,r=i.length;e<r;e++){const r=i[e];if(r.listener===t)return null===(n=r.rmAbort)||void 0===n||n.call(r),void i.splice(e,1)}}}VP=new WeakMap;const $P=0;const UP=1,WP=3;const jP=0,qP=1;const GP=1,KP=3;function YP(e,t,n=0){let i=n;let 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 QP,XP,ZP,JP,eL,tL,nL,iL;class rL{constructor(){QP.add(this),ZP.set(this,!1),JP.set(this,null),eL.set(this,new Map),tL.set(this,new Map)}setTextMapping(e){cz(this,JP,e,"f")}enable(){if(lz(this,ZP,"f"),!lz(this,JP,"f"))throw new Error("Text divs and strings have not been set.");if(cz(this,ZP,!0,"f"),cz(this,JP,lz(this,JP,"f").slice(),"f"),lz(this,JP,"f").sort(lz(XP,XP,"m",nL)),lz(this,eL,"f").size>0){const e=lz(this,JP,"f");for(const[t,n]of lz(this,eL,"f")){document.getElementById(t)?lz(this,QP,"m",iL).call(this,t,e[n]):lz(this,eL,"f").delete(t)}}for(const[e,t]of lz(this,tL,"f"))this.addPointerInTextLayer(e,t);lz(this,tL,"f").clear()}disable(){lz(this,ZP,"f")&&(lz(this,tL,"f").clear(),cz(this,JP,null,"f"),cz(this,ZP,!1,"f"))}removePointerInTextLayer(e){if(!lz(this,ZP,"f"))return void lz(this,tL,"f").delete(e);const t=lz(this,JP,"f");if(!t||0===t.length)return;const{id:n}=e;const i=lz(this,eL,"f").get(n);if(void 0===i)return;const r=t[i];lz(this,eL,"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(!lz(this,ZP,"f"))return lz(this,tL,"f").set(e,t),null;t&&this.removePointerInTextLayer(e);const i=lz(this,JP,"f");if(!i||0===i.length)return null;const r=YP(i,(t=>lz(XP,XP,"m",nL).call(XP,e,t)<0));const o=Math.max(0,r-1);const a=i[o];lz(this,QP,"m",iL).call(this,n,a),lz(this,eL,"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;const s=YP(o,(e=>lz(XP,XP,"m",nL).call(XP,a,e)<0));return 0===s?o[0].before(t):o[s-1].after(t),r}destroy(){cz(this,eL,new Map,"f"),cz(this,tL,new Map,"f"),cz(this,JP,null,"f")}}var oL,aL,sL,lL,cL,dL,hL,uL,pL;XP=rL,ZP=new WeakMap,JP=new WeakMap,eL=new WeakMap,tL=new WeakMap,QP=new WeakSet,nL=function(e,t){const n=e.getBoundingClientRect();const 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;const o=n.y+n.height;const a=n.y+n.height/2;const s=i.y;const l=i.y+i.height;const 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)},iL=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 fL{constructor({pdfPage:e,accessibilityManager:t,styles:n,onAppend:i=null}){oL.add(this),this.pdfPage=null,this.div=null,this.accessibilityManager=null,sL.set(this,null),lL.set(this,null),this.pdfPage=e,this.accessibilityManager=t,cz(this,sL,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 sz(this,arguments,void 0,(function*(e,t=null){var n,i,r;if(lz(this,lL,"f"))return lz(this,lL,"f").update({viewport:e,onBefore:this.hide.bind(this)}),void this.show();this.cancel(),cz(this,lL,new MI({textContentSource:this.pdfPage.streamTextContent(t||{includeMarkedContent:!1,disableNormalization:!0}),container:this.div,viewport:e}),"f");const{textDivs:o}=lz(this,lL,"f");null===(n=this.accessibilityManager)||void 0===n||n.setTextMapping(o),yield lz(this,lL,"f").render();const a=Array.from(this.div.querySelectorAll(".markedContent")||[])||[];if(a.forEach((e=>dz("k-marked-content",e))),a&&a.length>0){const e=document.createElement("div");e.className="endOfContent",this.div.append(e),lz(this,oL,"m",hL).call(this,e)}null===(i=lz(this,sL,"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,n;null===(e=lz(this,lL,"f"))||void 0===e||e.cancel(),cz(this,lL,null,"f"),null===(t=this.accessibilityManager)||void 0===t||t.disable(),null===(n=this.accessibilityManager)||void 0===n||n.destroy(),lz(aL,aL,"m",uL).call(aL,this.div)}destroy(){var e,t;MI.cleanup(),this.cancel(),this.pdfPage=null,null===(e=this.accessibilityManager)||void 0===e||e.destroy(),this.accessibilityManager=null,null===(t=this.div)||void 0===t||t.remove(),this.div=null}}function mL(e){return Math.floor(255*Math.max(0,Math.min(1,e))).toString(16).padStart(2,"0")}function gL(e){return Math.max(0,Math.min(255,255*e))}aL=fL,sL=new WeakMap,lL=new WeakMap,oL=new WeakSet,hL=function(e){const{div:t}=this;lz(aL,aL,"f",cL).set(t,e),lz(aL,aL,"m",pL).call(aL)},uL=function(e){var t;lz(this,aL,"f",cL).delete(e),0===lz(this,aL,"f",cL).size&&(null===(t=lz(this,aL,"f",dL))||void 0===t||t.abort(),cz(this,aL,null,"f",dL))},pL=function(){},cL={value:new Map},dL={value:null};class vL{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=gL(e),e,e]}static G_HTML([e]){const t=mL(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(gL)}static RGB_HTML(e){return`#${e.map(mL).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[gL(1-Math.min(1,e+i)),gL(1-Math.min(1,n+i)),gL(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;const r=1-t;const o=1-n;return["CMYK",i,r,o,Math.min(i,r,o)]}}function _L(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]}class bL{get _colors(){if("undefined"==typeof document)return Dz(this,"_colors",bL._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,_L(i))}t.remove()}(e),Dz(this,"_colors",e)}convert(e){const t=_L(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 bL._colorsMapping.get(e);return t}getHexCode(e){const t=this._colors.get(e);return t?Iz.makeHexColor(...t):e}}function wL(e,t,n){for(const i of n)t.addEventListener(i,e[i].bind(e))}var yL,kL,xL,CL,SL,TL,ML,AL,DL,EL,IL,zL,PL,LL,BL,HL,RL,FL,OL,VL,NL,$L;bL._colorsMapping=new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]);class UL{constructor(e){yL.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=[],xL.set(this,0),CL.set(this,0),this.isAttachedToDOM=!1,this.deleted=!1,SL.set(this,!1),TL.set(this,!1),ML.set(this,null),AL.set(this,!1),DL.set(this,null),EL.set(this,!1),IL.set(this,!1),zL.set(this,null),PL.set(this,0),LL.set(this,0),this._editToolbar=null,this._initialOptions=Object.create(null),this._isVisible=!0,this._uiManager=null,this._focusEventsAllowed=!0,this._l10nPromise=null,BL.set(this,!1),HL.set(this,kL._zIndex++),this.parent=e.parent,this.id=e.id||kL.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 lz(this,xL,"f")}set x(e){cz(this,xL,e,"f")}get y(){return lz(this,CL,"f")}set y(e){cz(this,CL,e,"f")}get editorType(){return Object.getPrototypeOf(this).constructor._type}static get _defaultLineColor(){return fI(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(e){const t=new WL({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 lz(this,BL,"f")}set _isDraggable(e){var t;cz(this,BL,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=lz(this,HL,"f")}setParent(e){null!==e?(this.pageIndex=e.pageIndex,this.pageDimensions=e.pageDimensions):lz(this,yL,"m",$L).call(this),this.parent=e}focusin(e){e&&this._focusEventsAllowed&&(lz(this,AL,"f")?cz(this,AL,!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){lz(this,yL,"m",RL).call(this,this.parentDimensions,e,t)}translateInPage(e,t){cz(this,DL,lz(this,DL,"f")||[this.x,this.y],"f"),lz(this,yL,"m",RL).call(this,this.pageDimensions,e,t),this.div.scrollIntoView({block:"nearest"})}drag(e,t){cz(this,DL,lz(this,DL,"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!!lz(this,DL,"f")&&(lz(this,DL,"f")[0]!==this.x||lz(this,DL,"f")[1]!==this.y)}getBaseTranslation(){const[e,t]=this.parentDimensions;const{_borderLineWidth:n}=kL;const i=n/e;const 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 lz(kL,kL,"m",FL).call(kL,e,t,this.parentRotation)}pageTranslationToScreen(e,t){return lz(kL,kL,"m",FL).call(kL,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;const i=t*e;const r=n*e;return gI.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)}%`,lz(this,TL,"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=lz(this,SL,"f")?-1:0,this._isVisible||this.div.classList.add("k-hidden"),this.setInForeground(),lz(this,yL,"m",NL).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),wL(this,this.div,["pointerdown"]),this.div}pointerdown(e){var t;const{isMac:n}=gI.platform;if(0!==e.button||e.ctrlKey&&n)e.preventDefault();else{if(cz(this,AL,!0,"f"),this._isDraggable)return null===(t=this._uiManager)||void 0===t||t.hideEditorToolBar(),void lz(this,yL,"m",VL).call(this,e);lz(this,yL,"m",OL).call(this,e)}}moveInDOM(){lz(this,zL,"f")&&clearTimeout(lz(this,zL,"f")),cz(this,zL,setTimeout((()=>{var e;cz(this,zL,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;const[r,o]=this.pageDimensions;const[a,s]=this.pageTranslation;const l=e/i;const c=t/i;const d=this.x*r;const h=this.y*o;const u=this.width*r;const p=this.height*o;switch(n){case 0:return[d+l+a,o-h-c-p+s,d+l+u+a,o-h-c+s];case 90:return[d+c+a,o-h+l+s,d+c+p+a,o-h+l+u+s];case 180:return[d-l-u+a,o-h+c+s,d-l+a,o-h+c+p+s];case 270:return[d-c-p+a,o-h-l-u+s,d-c+a,o-h-l+s];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(e,t){const[n,i,r,o]=e;const a=r-n;const 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(){cz(this,IL,!0,"f")}disableEditMode(){cz(this,IL,!1,"f")}isInEditMode(){return lz(this,IL,"f")}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}rebuild(){lz(this,yL,"m",NL).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;const[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=lz(this,ML,"f"))||void 0===e||e.abort(),cz(this,ML,null,"f"),this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),lz(this,zL,"f")&&(clearTimeout(lz(this,zL,"f")),cz(this,zL,null,"f")),lz(this,yL,"m",$L).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 lz(this,EL,"f")}set isEditing(e){cz(this,EL,e,"f"),this.parent&&(e?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}setAspectRatio(e,t){cz(this,TL,!0,"f");const n=e/t;const{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),cz(this,SL,!1,"f")}disable(){this.div&&(this.div.tabIndex=-1),cz(this,SL,!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()}}kL=UL,xL=new WeakMap,CL=new WeakMap,SL=new WeakMap,TL=new WeakMap,ML=new WeakMap,AL=new WeakMap,DL=new WeakMap,EL=new WeakMap,IL=new WeakMap,zL=new WeakMap,PL=new WeakMap,LL=new WeakMap,BL=new WeakMap,HL=new WeakMap,yL=new WeakSet,RL=function([e,t],n,i){[n,i]=this.screenToPageTranslation(n,i),this.x+=n/e,this.y+=i/t,this.fixAndSetPosition()},FL=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]}},OL=function(e){const{isMac:t}=gI.platform;const n=e.target.closest(".k-highlight-editor");const i=e.target.closest(".k-free-text-editor");const r=this._uiManager.getMode();r===_z&&!n||r===vz&&!i||(e.ctrlKey&&!t||e.shiftKey||e.metaKey&&t?this.parent.toggleSelected(this):this.parent.setSelected(this))},VL=function(e){const t=this._uiManager.isSelected(this);this._uiManager.setUpDragSession();const n=new AbortController;const i=this._uiManager.combinedSignal(n);if(t){cz(this,PL,e.clientX,"f"),cz(this,LL,e.clientY,"f");const t=e=>{const{clientX:t,clientY:n}=e;const[i,r]=this.screenToPageTranslation(t-lz(this,PL,"f"),n-lz(this,LL,"f"));cz(this,PL,t,"f"),cz(this,LL,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"),cz(this,AL,!1,"f"),this._uiManager.endDragSession()||lz(this,yL,"m",OL).call(this,e)};window.addEventListener("pointerup",r,{signal:i}),window.addEventListener("blur",r,{signal:i})},NL=function(){if(lz(this,ML,"f")||!this.div)return;cz(this,ML,new AbortController,"f");const e=this._uiManager.combinedSignal(lz(this,ML,"f"));this.div.addEventListener("focusin",this.focusin.bind(this),{signal:e}),this.div.addEventListener("focusout",this.focusout.bind(this),{signal:e})},$L=function(){},UL.idManager=new Lz("annotation_editor_id_"),UL._borderLineWidth=-1,UL._colorManager=new bL,UL._zIndex=1,UL._telemetryTimeout=1e3;class WL extends UL{constructor(e){super(e),this.annotationElementId=e.annotationElementId,this.deleted=!0}serialize(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex}}}const jL=3285377520;const qL=4294901760;const GL=65535;class KL{constructor(e){this.h1=null,this.h2=null,this.h1=e?4294967295&e:jL,this.h2=e?4294967295&e:jL}update(e){let t,n;if("string"==typeof e){t=new Uint8Array(2*e.length),n=0;for(let i=0,r=e.length;i<r;i++){const r=e.charCodeAt(i);r<=255?t[n++]=r:(t[n++]=r>>>8,t[n++]=255&r)}}else{if(!ArrayBuffer.isView(e))throw new Error("Invalid data format, must be a string or TypedArray.");t=e.slice(),n=t.byteLength}const i=n>>2;const r=n-4*i;const o=new Uint32Array(t.buffer,0,i);let a=0,s=0;let l=this.h1,c=this.h2;const d=3432918353,h=461845907;const u=11601,p=13715;for(let e=0;e<i;e++)1&e?(a=o[e],a=a*d&qL|a*u&GL,a=a<<15|a>>>17,a=a*h&qL|a*p&GL,l^=a,l=l<<13|l>>>19,l=5*l+3864292196):(s=o[e],s=s*d&qL|s*u&GL,s=s<<15|s>>>17,s=s*h&qL|s*p&GL,c^=s,c=c<<13|c>>>19,c=5*c+3864292196);switch(a=0,r){case 3:a^=t[4*i+2]<<16;case 2:a^=t[4*i+1]<<8;case 1:a^=t[4*i],a=a*d&qL|a*u&GL,a=a<<15|a>>>17,a=a*h&qL|a*p&GL,1&i?l^=a:c^=a}this.h1=l,this.h2=c}hexdigest(){let e=this.h1,t=this.h2;return e^=t>>>1,e=3981806797*e&qL|36045*e&GL,t=4283543511*t&qL|(2950163797*(t<<16|e>>>16)&qL)>>>16,e^=t>>>1,e=444984403*e&qL|60499*e&GL,t=3301882366*t&qL|(3120437893*(t<<16|e>>>16)&qL)>>>16,e^=t>>>1,(e>>>0).toString(16).padStart(8,"0")+(t>>>0).toString(16).padStart(8,"0")}}var YL,QL,XL,ZL,JL,eB;const tB=Object.freeze({map:null,hash:"",transfer:void 0});class nB{constructor(){YL.add(this),this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null,QL.set(this,!1),XL.set(this,null),ZL.set(this,new Map),this.onSetModified=null,this.onResetModified=null,this.onAnnotationEditor=null}getStorage(){return lz(this,ZL,"f")}getModified(){return lz(this,QL,"f")}getValue(e,t){const n=lz(this,ZL,"f").get(e);return void 0===n?t:Object.assign(t,n)}getRawValue(e){return lz(this,ZL,"f").get(e)}remove(e){if(lz(this,ZL,"f").delete(e),0===lz(this,ZL,"f").size&&this.resetModified(),"function"==typeof this.onAnnotationEditor){for(const e of lz(this,ZL,"f").values())if(e instanceof UL)return;this.onAnnotationEditor(null)}}setValue(e,t){const n=lz(this,ZL,"f").get(e);let i=!1;if(void 0!==n)for(const[e,r]of Object.entries(t))n[e]!==r&&(i=!0,n[e]=r);else i=!0,lz(this,ZL,"f").set(e,t);i&&lz(this,YL,"m",JL).call(this),t instanceof UL&&"function"==typeof this.onAnnotationEditor&&this.onAnnotationEditor(t.constructor._type)}has(e){return lz(this,ZL,"f").has(e)}getAll(){return lz(this,ZL,"f").size>0?function(e){const t=Object.create(null);for(const[n,i]of e)t[n]=i;return t}(lz(this,ZL,"f")):null}setAll(e){for(const[t,n]of Object.entries(e))this.setValue(t,n)}get size(){return lz(this,ZL,"f").size}resetModified(){lz(this,QL,"f")&&(cz(this,QL,!1,"f"),"function"==typeof this.onResetModified&&this.onResetModified())}get print(){return new iB(this)}get serializable(){if(0===lz(this,ZL,"f").size)return tB;const e=new Map,t=new KL(null),n=[];const i=Object.create(null);let r=!1;for(const[n,o]of lz(this,ZL,"f")){const a=o instanceof UL?o.serialize(!1,i):o;a&&(e.set(n,a),t.update(`${n}:${JSON.stringify(a)}`),r||(r=!!a.bitmap))}if(r)for(const t of e.values())t.bitmap&&n.push(t.bitmap);return e.size>0?{map:e,hash:t.hexdigest(),transfer:n}:tB}get editorStats(){var e;let t=null;const n=new Map;for(const i of lz(this,ZL,"f").values()){if(!(i instanceof UL))continue;const r=i.telemetryFinalData;if(!r)continue;const{type:o}=r;n.has(o)||n.set(o,Object.getPrototypeOf(i).constructor),t||(t=Object.create(null));const a=t[o]||(t[o]=new Map);for(const[t,n]of Object.entries(r)){if("type"===t)continue;let i=a.get(t);i||(i=new Map,a.set(t,i));const r=null!==(e=i.get(n))&&void 0!==e?e:0;i.set(n,r+1)}}for(const[e,i]of n)t[e]=i.computeTelemetryFinalData(t[e]);return t}resetModifiedIds(){cz(this,XL,null,"f")}get modifiedIds(){if(lz(this,XL,"f"))return lz(this,XL,"f");const e=[];for(const t of lz(this,ZL,"f").values())t instanceof UL&&t.annotationElementId&&t.serialize()&&e.push(t.annotationElementId);return cz(this,XL,{ids:new Set(e),hash:e.join(",")},"f")}}QL=new WeakMap,XL=new WeakMap,ZL=new WeakMap,YL=new WeakSet,JL=function(){lz(this,QL,"f")||(cz(this,QL,!0,"f"),"function"==typeof this.onSetModified&&this.onSetModified())};class iB extends nB{constructor(e){super(),eB.set(this,void 0);const{map:t,hash:n,transfer:i}=e.serializable;const r=structuredClone(t,i?{transfer:i}:null);cz(this,eB,{map:r,hash:n,transfer:i},"f")}get print(){return null}get serializable(){return lz(this,eB,"f")}get modifiedIds(){return fI(this,"modifiedIds",{ids:new Set,hash:""})}}var rB,oB,aB,sB,lB,cB,dB,hB,uB,pB,fB,mB,gB,vB,_B,bB,wB,yB,kB,xB,CB,SB,TB,MB,AB,DB,EB,IB,zB,PB,LB,BB,HB,RB,FB,OB,VB,NB,$B,UB,WB,jB,qB,GB;eB=new WeakMap;const KB=new WeakSet;function YB(e){return{width:e[2]-e[0],height:e[3]-e[1]}}class QB{static create(e){switch(e.data.annotationType){case bz:return new ZB(e);case xz:switch(e.data.fieldType){case"Tx":return new eH(e);case"Btn":return e.data.radioButton?new nH(e):e.data.checkBox?new tH(e):new iH(e);case"Ch":return new rH(e)}case wz:return new sH(e);case yz:return new lH(e);default:return new XB(e)}}}class XB{constructor(e,{isRenderable:t=!1,ignoreBorder:n=!1,createQuadrilaterals:i=!1}={}){rB.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,oB.set(this,null),aB.set(this,!1),sB.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 XB._hasPopupData(this.data)}updateEdited(e){var t;if(!this.container)return;cz(this,oB,lz(this,oB,"f")||{rect:this.data.rect.slice(0)},"f");const{rect:n}=e;n&&lz(this,rB,"m",lB).call(this,n),null===(t=lz(this,sB,"f"))||void 0===t||t.popup.updateEdited(e)}resetEdited(){var e;lz(this,oB,"f")&&(lz(this,rB,"m",lB).call(this,lz(this,oB,"f").rect),null===(e=lz(this,sB,"f"))||void 0===e||e.popup.resetEdited(),cz(this,oB,null,"f"))}_createContainer(e){const{data:t,parent:{page:n,viewport:i}}=this;const r=document.createElement("section");r.setAttribute("data-annotation-id",t.id),this instanceof JB||(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 oH){const{rotation:e}=t;return t.hasOwnCanvas||0===e||this.setRotation(e,r),r}const{width:a,height:s}=YB(t.rect);if(!e&&t.borderStyle.width>0){o.borderWidth=`${t.borderStyle.width}px`;const e=t.borderStyle.horizontalCornerRadius;const 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 nH){const e=`calc(${a}px * var(--scale-factor)) / calc(${s}px * var(--scale-factor))`;o.borderRadius=e}switch(t.borderStyle.style){case Cz:o.borderStyle="solid";break;case Sz:o.borderStyle="dashed";break;case Tz:case Mz:break;case Az:o.borderBottomStyle="solid"}const i=t.borderColor||null;i?(cz(this,aB,!0,"f"),o.borderColor=kI.makeHexColor(0|i[0],0|i[1],0|i[2])):o.borderWidth=(0).toString()}const l=kI.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]]);const{pageWidth:c,pageHeight:d,pageX:h,pageY:u}=i.rawDims;o.left=100*(l[0]-h)/c+"%",o.top=100*(l[1]-u)/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;const{width:r,height:o}=YB(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];const r=i[0];const o=i.slice(1);n.target.style[t]=vL[`${r}_HTML`](o),this.annotationStorage.setValue(this.data.id,{[t]:vL[`${r}_rgb`](o)})};return fI(this,"_commonActions",{display:e=>{const{display:t}=e.detail;const 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(lz(this,aB,"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;const l=r-n;const{svgFactory:c}=this;const d=c.createElement("svg");d.setAttribute("width",0),d.setAttribute("height",0);const h=c.createElement("defs");d.append(h);const u=c.createElement("clipPath");const p=`clippath_${this.data.id}`;u.setAttribute("id",p),u.setAttribute("clipPathUnits","objectBoundingBox"),h.append(u);for(let n=2,i=e.length;n<i;n+=8){const i=e[n];const o=e[n+1];const d=e[n+2];const h=e[n+3];const p=c.createElement("rect");const f=(d-t)/s;const m=(r-o)/l;const g=(i-d)/s;const v=(o-h)/l;p.setAttribute("x",f),p.setAttribute("y",m),p.setAttribute("width",g),p.setAttribute("height",v),u.append(p),null==a||a.push(`<rect vector-effect="non-scaling-stroke" x="${f}" y="${m}" width="${g}" height="${v}"/>`)}lz(this,aB,"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;const a=document.querySelector(`[data-element-id="${r}"]`);a&&!KB.has(a)||n.push({id:r,exportValue:i,domElement:a})}return n}for(const i of document.getElementsByName(e)){const{exportValue:e}=i;const r=i.getAttribute("data-element-id");r!==t&&(KB.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)}}oB=new WeakMap,aB=new WeakMap,sB=new WeakMap,rB=new WeakSet,lB=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}=YB(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)};class ZB extends XB{constructor(e,t=null){super(e,{isRenderable:!0,ignoreBorder:!!(null==t?void 0:t.ignoreBorder),createQuadrilaterals:!0}),cB.add(this),this.isTooltipOnly=!1,this.isTooltipOnly=e.data.isTooltipOnly}render(){const{data:e,linkService:t}=this;const n=document.createElement("a");n.setAttribute("data-element-id",e.id);let i=!1;return e.url?(t.addLinkAttributes(n,e.url,e.newWindow),i=!0):e.action?(this._bindNamedAction(n,e.action),i=!0):e.attachment?(lz(this,cB,"m",hB).call(this,n,e.attachment,e.attachmentDest),i=!0):e.setOCGState?(lz(this,cB,"m",uB).call(this,n,e.setOCGState),i=!0):e.dest?(this._bindLink(n,e.dest),i=!0):(e.actions&&(e.actions.Action||e.actions["Mouse Up"]||e.actions["Mouse Down"])&&this.enableScripting&&this.hasJSActions&&(this._bindJSAction(n,e),i=!0),e.resetForm?(this._bindResetFormAction(n,e.resetForm),i=!0):this.isTooltipOnly&&!i&&(this._bindLink(n,""),i=!0)),this.container.classList.add("k-link-annotation"),i&&this.container.append(n),this.container}_bindLink(e,t){e.href=this.linkService.getDestinationHash(t),e.onclick=()=>(t&&this.linkService.goToDestination(t),!1),(t||""===t)&&lz(this,cB,"m",dB).call(this)}_bindNamedAction(e,t){e.href=this.linkService.getAnchorUrl(""),e.onclick=()=>(this.linkService.executeNamedAction(t),!1),lz(this,cB,"m",dB).call(this)}_bindJSAction(e,t){e.href=this.linkService.getAnchorUrl("");const n=new Map([["Action","onclick"],["Mouse Up","onmouseup"],["Mouse Down","onmousedown"]]);for(const i of Object.keys(t.actions)){const r=n.get(i);r&&(e[r]=()=>{var e;return null===(e=this.linkService.eventBus)||void 0===e||e.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t.id,name:i}}),!1})}e.onclick||(e.onclick=()=>!1),lz(this,cB,"m",dB).call(this)}_bindResetFormAction(e,t){const n=e.onclick;n||(e.href=this.linkService.getAnchorUrl("")),lz(this,cB,"m",dB).call(this),this._fieldObjects?e.onclick=()=>{var e;null==n||n();const{fields:i,refs:r,include:o}=t;const a=[];if(0!==i.length||0!==r.length){const e=new Set(r);for(const t of i){const n=this._fieldObjects[t]||[];for(const{id:t}of n)e.add(t)}for(const t of Object.values(this._fieldObjects))for(const n of t)e.has(n.id)===o&&a.push(n)}else for(const e of Object.values(this._fieldObjects))a.push(...e);const s=this.annotationStorage;const l=[];for(const e of a){const{id:t}=e;switch(l.push(t),e.type){case"text":{const n=e.defaultValue||"";s.setValue(t,{value:n});break}case"checkbox":case"radiobutton":{const n=e.defaultValue===e.exportValues;s.setValue(t,{value:n});break}case"combobox":case"listbox":{const n=e.defaultValue||"";s.setValue(t,{value:n});break}default:continue}const n=document.querySelector(`[data-element-id="${t}"]`);n&&(KB.has(n)&&n.dispatchEvent(new Event("resetform")))}return this.enableScripting&&(null===(e=this.linkService.eventBus)||void 0===e||e.dispatch("dispatcheventinsandbox",{source:this,detail:{id:"app",ids:l,name:"ResetForm"}})),!1}:n||(e.onclick=()=>!1)}}cB=new WeakSet,dB=function(){this.container.setAttribute("data-internal-link","")},hB=function(e,t,n=null){e.href=this.linkService.getAnchorUrl(""),t.description&&(e.title=t.description),e.onclick=()=>{var e;return null===(e=this.downloadManager)||void 0===e||e.openOrDownloadData(t.content,t.filename,n),!1},lz(this,cB,"m",dB).call(this)},uB=function(e,t){e.href=this.linkService.getAnchorUrl(""),e.onclick=()=>(this.linkService.executeSetOCGState(t),!1),lz(this,cB,"m",dB).call(this)};class JB extends XB{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 gI.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":kI.makeHexColor(t[0],t[1],t[2])}_setTextStyle(e){const t=["left","center","right"];const{fontColor:n}=this.data.defaultAppearanceData;const i=this.data.defaultAppearanceData.fontSize||9;const 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);const t=e/(Math.round(e/(pz*i))||1);o=Math.min(i,a(t/pz))}else{const e=Math.abs(this.data.rect[3]-this.data.rect[1]-2);o=Math.min(i,a(e/pz))}r.fontSize=`calc(${o}px * var(--scale-factor))`,r.color=kI.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 eH extends JB{constructor(e){super(e,{isRenderable:e.renderForms||e.data.hasOwnCanvas||!e.data.hasAppearance&&!!e.data.fieldValue})}setPropertyOnSiblings(e,t,n,i){const r=this.annotationStorage;for(const o of this._getElementsByName(e.name,e.id))o.domElement&&(o.domElement[t]=n),r.setValue(o.id,{[i]:n})}render(){var e,t;const n=this.annotationStorage;const i=this.data.id;this.container.classList.add("k-text-widget-annotation");let r=null;if(this.renderForms){const o=n.getValue(i,{value:this.data.fieldValue});let a=o.value||"";const s=n.getValue(i,{charLimit:this.data.maxLen}).charLimit;s&&a.length>s&&(a=a.slice(0,s));let l=o.formattedValue||(null===(e=this.data.textContent)||void 0===e?void 0:e.join("\n"))||null;l&&this.data.comb&&(l=l.replaceAll(/\s+/g,""));const c={userValue:a,formattedValue:l,lastCommittedValue:null,commitKey:1,focused:!1};this.data.multiLine?(r=document.createElement("textarea"),r.textContent=null!=l?l:a,this.data.doNotScroll&&(r.style.overflowY="hidden")):(r=document.createElement("input"),r.type="text",r.setAttribute("value",null!=l?l:a),this.data.doNotScroll&&(r.style.overflowX="hidden")),this.data.hasOwnCanvas&&(r.hidden=!0),KB.add(r),r.setAttribute("data-element-id",i),r.disabled=this.data.readOnly,r.name=this.data.fieldName,r.tabIndex=0,this._setRequired(r,this.data.required),s&&(r.maxLength=s),r.addEventListener("input",(e=>{n.setValue(i,{value:e.target.value}),this.setPropertyOnSiblings(r,"value",e.target.value,"value"),c.formattedValue=null})),r.addEventListener("resetform",(()=>{var e;const t=null!==(e=this.data.defaultFieldValue)&&void 0!==e?e:"";r.value=c.userValue=t,c.formattedValue=null}));let d=e=>{const{formattedValue:t}=c;null!=t&&(e.target.value=t),e.target.scrollLeft=0};if(this.enableScripting&&this.hasJSActions){r.addEventListener("focus",(e=>{var t;if(c.focused)return;const{target:n}=e;c.userValue&&(n.value=c.userValue),c.lastCommittedValue=n.value,c.commitKey=1,(null===(t=this.data.actions)||void 0===t?void 0:t.Focus)||(c.focused=!0)})),r.addEventListener("updatefromsandbox",(e=>{this.showElementAndHideCanvas(e.target);const t={value(e){var t;c.userValue=null!==(t=e.detail.value)&&void 0!==t?t:"",n.setValue(i,{value:c.userValue.toString()}),e.target.value=c.userValue},formattedValue(e){const{formattedValue:t}=e.detail;c.formattedValue=t,null!=t&&e.target!==document.activeElement&&(e.target.value=t),n.setValue(i,{formattedValue:t})},selRange(e){e.target.setSelectionRange(...e.detail.selRange)},charLimit:e=>{var t;const{charLimit:r}=e.detail;const{target:o}=e;if(0===r)return void o.removeAttribute("maxLength");o.setAttribute("maxLength",r);let a=c.userValue;!a||a.length<=r||(a=a.slice(0,r),o.value=c.userValue=a,n.setValue(i,{value:a}),null===(t=this.linkService.eventBus)||void 0===t||t.dispatch("dispatcheventinsandbox",{source:this,detail:{id:i,name:"Keystroke",value:a,willCommit:!0,commitKey:1,selStart:o.selectionStart,selEnd:o.selectionEnd}}))}};this._dispatchEventFromSandbox(t,e)})),r.addEventListener("keydown",(e=>{var t;c.commitKey=1;let n=-1;if("Escape"===e.key?n=0:"Enter"!==e.key||this.data.multiLine?"Tab"===e.key&&(c.commitKey=3):n=2,-1===n)return;const{value:r}=e.target;c.lastCommittedValue!==r&&(c.lastCommittedValue=r,c.userValue=r,null===(t=this.linkService.eventBus)||void 0===t||t.dispatch("dispatcheventinsandbox",{source:this,detail:{id:i,name:"Keystroke",value:r,willCommit:!0,commitKey:n,selStart:e.target.selectionStart,selEnd:e.target.selectionEnd}}))}));const e=d;d=null,r.addEventListener("blur",(t=>{var n,r;if(!c.focused||!t.relatedTarget)return;(null===(n=this.data.actions)||void 0===n?void 0:n.Blur)||(c.focused=!1);const{value:o}=t.target;c.userValue=o,c.lastCommittedValue!==o&&(null===(r=this.linkService.eventBus)||void 0===r||r.dispatch("dispatcheventinsandbox",{source:this,detail:{id:i,name:"Keystroke",value:o,willCommit:!0,commitKey:c.commitKey,selStart:t.target.selectionStart,selEnd:t.target.selectionEnd}})),e(t)})),(null===(t=this.data.actions)||void 0===t?void 0:t.Keystroke)&&r.addEventListener("beforeinput",(e=>{var t;c.lastCommittedValue=null;const{data:n,target:r}=e;const{value:o,selectionStart:a,selectionEnd:s}=r;let l=a,d=s;switch(e.inputType){case"deleteWordBackward":{const e=o.substring(0,a).match(/\w*[^\w]*$/);e&&(l-=e[0].length);break}case"deleteWordForward":{const e=o.substring(a).match(/^[^\w]*\w*/);e&&(d+=e[0].length);break}case"deleteContentBackward":a===s&&(l-=1);break;case"deleteContentForward":a===s&&(d+=1)}e.preventDefault(),null===(t=this.linkService.eventBus)||void 0===t||t.dispatch("dispatcheventinsandbox",{source:this,detail:{id:i,name:"Keystroke",value:o,change:n||"",willCommit:!1,selStart:l,selEnd:d}})})),this._setEventListeners(r,c,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],(e=>e.target.value))}if(d&&r.addEventListener("blur",d),this.data.comb){const e=(this.data.rect[2]-this.data.rect[0])/s;r.classList.add("comb"),r.style.letterSpacing=`calc(${e}px * var(--scale-factor) - 1ch)`}}else r=document.createElement("div"),r.textContent=this.data.fieldValue,r.style.verticalAlign="middle",r.style.display="table-cell",this.data.hasOwnCanvas&&(r.hidden=!0);return this._setTextStyle(r),this._setBackgroundColor(r),this._setDefaultPropertiesFromJS(r),this.container.append(r),this.container}}class tH extends JB{constructor(e){super(e,{isRenderable:e.renderForms})}render(){const e=this.annotationStorage;const t=this.data;const n=t.id;let i=e.getValue(n,{value:t.exportValue===t.fieldValue}).value;"string"==typeof i&&(i="Off"!==i,e.setValue(n,{value:i})),this.container.classList.add("k-button-widget-annotation","k-checkbox-widget-annotation");const r=document.createElement("input");return KB.add(r),r.setAttribute("data-element-id",n),r.disabled=t.readOnly,this._setRequired(r,this.data.required),r.type="checkbox",r.name=t.fieldName,i&&r.setAttribute("checked",(!0).toString()),r.setAttribute("exportValue",t.exportValue),r.tabIndex=0,r.addEventListener("change",(i=>{const{name:r,checked:o}=i.target;for(const i of this._getElementsByName(r,n)){const n=o&&i.exportValue===t.exportValue;i.domElement&&(i.domElement.checked=n),e.setValue(i.id,{value:n})}e.setValue(n,{value:o})})),r.addEventListener("resetform",(e=>{const n=t.defaultFieldValue||"Off";e.target.checked=n===t.exportValue})),this.enableScripting&&this.hasJSActions&&(r.addEventListener("updatefromsandbox",(t=>{const i={value(t){t.target.checked="Off"!==t.detail.value,e.setValue(n,{value:t.target.checked})}};this._dispatchEventFromSandbox(i,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))),this.enableScripting&&this.hasJSActions&&(r.addEventListener("updatefromsandbox",(t=>{const i={value(t){t.target.checked="Off"!==t.detail.value,e.setValue(n,{value:t.target.checked})}};this._dispatchEventFromSandbox(i,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))),this._setBackgroundColor(r),this._setDefaultPropertiesFromJS(r),this.container.append(r),this.container}}class nH extends JB{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.classList.add("k-button-widget-annotation","k-radio-button-widget-annotation");const e=this.annotationStorage;const t=this.data;const 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(KB.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 iH extends ZB{constructor(e){super(e,{ignoreBorder:e.data.hasAppearance})}render(){const e=super.render();this.container.classList.add("k-button-widget-annotation","k-push-button-widget-annotation");const t=e.lastChild;return this.enableScripting&&this.hasJSActions&&t&&(this._setDefaultPropertiesFromJS(t),t.addEventListener("updatefromsandbox",(e=>{this._dispatchEventFromSandbox({},e)}))),e}}class rH extends JB{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.classList.add("choiceWidgetAnnotation");const e=this.annotationStorage;const t=this.data.id;const n=e.getValue(t,{value:this.data.fieldValue});const i=document.createElement("select");KB.add(i),i.setAttribute("data-element-id",t),i.disabled=this.data.readOnly,this._setRequired(i,this.data.required),i.name=this.data.fieldName,i.tabIndex=0;let r=this.data.combo&&this.data.options.length>0;this.data.combo||(i.size=this.data.options.length,this.data.multiSelect&&(i.multiple=!0)),i.addEventListener("resetform",(()=>{const e=this.data.defaultFieldValue;for(const t of i.options)t.selected=t.value===e}));for(const e of this.data.options){const t=document.createElement("option");t.textContent=e.displayValue,t.value=e.exportValue,n.value.includes(e.exportValue)&&(t.setAttribute("selected",(!0).toString()),r=!1),i.append(t)}let o=null;if(r){const e=document.createElement("option");e.value=" ",e.setAttribute("hidden",(!0).toString()),e.setAttribute("selected",(!0).toString()),i.prepend(e),o=()=>{e.remove(),i.removeEventListener("input",o),o=null},i.addEventListener("input",o)}const a=e=>{const t=e?"value":"textContent";const{options:n,multiple:r}=i;return r?Array.prototype.filter.call(n,(e=>e.selected)).map((e=>e[t])):-1===n.selectedIndex?null:n[n.selectedIndex][t]};let s=a(!1);const l=e=>{const t=e.target.options;return Array.prototype.map.call(t,(e=>({displayValue:e.textContent,exportValue:e.value})))};return this.enableScripting&&this.hasJSActions?(i.addEventListener("updatefromsandbox",(n=>{const r={value(n){null==o||o();const r=n.detail.value;const l=new Set(Array.isArray(r)?r:[r]);for(const e of i.options)e.selected=l.has(e.value);e.setValue(t,{value:a(!0)}),s=a(!1)},multipleSelection(){i.multiple=!0},remove(n){const r=i.options;const o=n.detail.remove;if(r[o].selected=!1,i.remove(o),r.length>0){-1===Array.prototype.findIndex.call(r,(e=>e.selected))&&(r[0].selected=!0)}e.setValue(t,{value:a(!0),items:l(n)}),s=a(!1)},clear(){for(;0!==i.length;)i.remove(0);e.setValue(t,{value:null,items:[]}),s=a(!1)},insert(n){const{index:r,displayValue:o,exportValue:c}=n.detail.insert;const d=i.children[r];const h=document.createElement("option");h.textContent=o,h.value=c,d?d.before(h):i.append(h),e.setValue(t,{value:a(!0),items:l(n)}),s=a(!1)},items(n){const{items:r}=n.detail;for(;0!==i.length;)i.remove(0);for(const e of r){const{displayValue:t,exportValue:n}=e;const r=document.createElement("option");r.textContent=t,r.value=n,i.append(r)}i.options.length>0&&(i.options[0].selected=!0),e.setValue(t,{value:a(!0),items:l(n)}),s=a(!1)},indices(n){const i=new Set(n.detail.indices);for(const e of n.target.options)e.selected=i.has(e.index);e.setValue(t,{value:a(!0)}),s=a(!1)},editable(e){e.target.disabled=!e.detail.editable}};this._dispatchEventFromSandbox(r,n)})),i.addEventListener("input",(n=>{var i;const r=a(!0);const o=a(!1);e.setValue(t,{value:r}),n.preventDefault(),null===(i=this.linkService.eventBus)||void 0===i||i.dispatch("dispatcheventinsandbox",{source:this,detail:{id:t,name:"Keystroke",value:s,change:o,changeEx:r,willCommit:!1,commitKey:1,keyDown:!1}})})),this._setEventListeners(i,null,[["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"],["input","Action"],["input","Validate"]],(e=>e.target.value))):i.addEventListener("input",(function(){e.setValue(t,{value:a(!0)})})),this.data.combo&&this._setTextStyle(i),this._setBackgroundColor(i),this._setDefaultPropertiesFromJS(i),this.container.append(i),this.container}}class oH extends XB{constructor(e){const{data:t,elements:n}=e;super(e,{isRenderable:XB._hasPopupData(t)}),this.elements=[],this.elements=n,this.popup=null}render(){this.container.classList.add("popupAnnotation");const e=this.popup=new aH({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});const 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=>`${zz}${e}`)).join(",")),this.container}}class aH{constructor({container:e,color:t,elements:n,titleObj:i,modificationDate:r,contentsObj:o,richText:a,parent:s,rect:l,parentRect:c,open:d}){var h;pB.add(this),this.trigger=null,fB.set(this,lz(this,pB,"m",RB).bind(this)),mB.set(this,lz(this,pB,"m",NB).bind(this)),gB.set(this,lz(this,pB,"m",VB).bind(this)),vB.set(this,lz(this,pB,"m",OB).bind(this)),_B.set(this,null),bB.set(this,null),wB.set(this,null),yB.set(this,null),kB.set(this,null),xB.set(this,null),CB.set(this,null),SB.set(this,!1),TB.set(this,null),MB.set(this,null),AB.set(this,null),DB.set(this,null),EB.set(this,null),IB.set(this,null),zB.set(this,!1),cz(this,bB,e,"f"),cz(this,EB,i,"f"),cz(this,wB,o,"f"),cz(this,DB,a,"f"),cz(this,xB,s,"f"),cz(this,_B,t,"f"),cz(this,AB,l,"f"),cz(this,CB,c,"f"),cz(this,kB,n,"f"),cz(this,yB,yI.toDateObject(r),"f"),this.trigger=n.flatMap((e=>e.getElementsToTriggerPopup()));for(const e of this.trigger)e.addEventListener("click",lz(this,vB,"f")),e.addEventListener("mouseenter",lz(this,gB,"f")),e.addEventListener("mouseleave",lz(this,mB,"f")),e.classList.add("popupTriggerArea");for(const e of n)null===(h=e.container)||void 0===h||h.addEventListener("keydown",lz(this,fB,"f"));lz(this,bB,"f").hidden=!0,d&&lz(this,pB,"m",OB).call(this),lz(this,xB,"f").popupShow.push((()=>sz(this,void 0,void 0,(function*(){lz(this,bB,"f").hidden&&lz(this,pB,"m",VB).call(this)}))))}render(){if(lz(this,TB,"f"))return;const e=cz(this,TB,document.createElement("div"),"f");if(e.className="popup",lz(this,_B,"f")){const t=e.style.outlineColor=kI.makeHexColor(...lz(this,_B,"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=kI.makeHexColor(...lz(this,_B,"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}=lz(this,EB,"f")),e.append(t),lz(this,yB,"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:lz(this,yB,"f").toLocaleDateString(),time:lz(this,yB,"f").toLocaleTimeString()})),t.append(e)}const i=lz(this,pB,"a",PB);if(i)xI.render({xfaHtml:i,intent:"richText",div:e}),e.lastChild.classList.add("richText","popupContent");else{const t=this._formatContents(lz(this,wB,"f"));e.append(t)}lz(this,bB,"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;cz(this,IB,lz(this,IB,"f")||{contentsObj:lz(this,wB,"f"),richText:lz(this,DB,"f")},"f"),e&&cz(this,MB,null,"f"),t&&(cz(this,DB,lz(this,pB,"m",HB).call(this,t),"f"),cz(this,wB,null,"f")),null===(n=lz(this,TB,"f"))||void 0===n||n.remove(),cz(this,TB,null,"f")}resetEdited(){var e;var t,n;lz(this,IB,"f")&&(t=this,n=this,({contentsObj:{set value(e){cz(t,wB,e,"f")}}.value,richText:{set value(e){cz(n,DB,e,"f")}}.value}=lz(this,IB,"f")),cz(this,IB,null,"f"),null===(e=lz(this,TB,"f"))||void 0===e||e.remove(),cz(this,TB,null,"f"),cz(this,MB,null,"f"))}forceHide(){cz(this,zB,this.isVisible,"f"),lz(this,zB,"f")&&(lz(this,bB,"f").hidden=!0)}maybeShow(){lz(this,zB,"f")&&(lz(this,TB,"f")||lz(this,pB,"m",VB).call(this),cz(this,zB,!1,"f"),lz(this,bB,"f").hidden=!1)}get isVisible(){return!1===lz(this,bB,"f").hidden}}fB=new WeakMap,mB=new WeakMap,gB=new WeakMap,vB=new WeakMap,_B=new WeakMap,bB=new WeakMap,wB=new WeakMap,yB=new WeakMap,kB=new WeakMap,xB=new WeakMap,CB=new WeakMap,SB=new WeakMap,TB=new WeakMap,MB=new WeakMap,AB=new WeakMap,DB=new WeakMap,EB=new WeakMap,IB=new WeakMap,zB=new WeakMap,pB=new WeakSet,PB=function(){const e=lz(this,DB,"f");const t=lz(this,wB,"f");return!(null==e?void 0:e.str)||(null==t?void 0:t.str)&&t.str!==e.str?null:lz(this,DB,"f").html||null},LB=function(){var e,t,n;return(null===(n=null===(t=null===(e=lz(this,pB,"a",PB))||void 0===e?void 0:e.attributes)||void 0===t?void 0:t.style)||void 0===n?void 0:n.fontSize)||0},BB=function(){var e,t,n;return(null===(n=null===(t=null===(e=lz(this,pB,"a",PB))||void 0===e?void 0:e.attributes)||void 0===t?void 0:t.style)||void 0===n?void 0:n.color)||null},HB=function(e){const t=[];const n={str:e,html:{name:"div",attributes:{dir:"auto"},children:[{name:"p",children:t}]}};const i={style:{color:lz(this,pB,"a",BB),fontSize:lz(this,pB,"a",LB)?`calc(${lz(this,pB,"a",LB)}px * var(--scale-factor))`:""}};for(const n of e.split("\n"))t.push({name:"span",value:n,attributes:i});return n},RB=function(e){e.altKey||e.shiftKey||e.ctrlKey||e.metaKey||("Enter"===e.key||"Escape"===e.key&&lz(this,SB,"f"))&&lz(this,pB,"m",OB).call(this)},FB=function(){if(null!==lz(this,MB,"f"))return;const{page:{view:e},viewport:{rawDims:{pageWidth:t,pageHeight:n,pageX:i,pageY:r}}}=lz(this,xB,"f");let o=!!lz(this,CB,"f");let a=lz(this,o?CB:AB,"f");for(const e of lz(this,kB,"f"))if(!a||null!==kI.intersect(e.data.rect,a)){a=e.data.rect,o=!0;break}const s=kI.normalizeRect([a[0],e[3]-a[1]+e[1],a[2],e[3]-a[3]+e[1]]);const l=o?a[2]-a[0]+5:0;const c=s[0]+l;const d=s[1];cz(this,MB,[100*(c-i)/t,100*(d-r)/n],"f");const{style:h}=lz(this,bB,"f");h.left=`${lz(this,MB,"f")[0]}%`,h.top=`${lz(this,MB,"f")[1]}%`},OB=function(){cz(this,SB,!lz(this,SB,"f"),"f"),lz(this,SB,"f")?(lz(this,pB,"m",VB).call(this),lz(this,bB,"f").addEventListener("click",lz(this,vB,"f")),lz(this,bB,"f").addEventListener("keydown",lz(this,fB,"f"))):(lz(this,pB,"m",NB).call(this),lz(this,bB,"f").removeEventListener("click",lz(this,vB,"f")),lz(this,bB,"f").removeEventListener("keydown",lz(this,fB,"f")))},VB=function(){lz(this,TB,"f")||this.render(),this.isVisible?lz(this,SB,"f")&&lz(this,bB,"f").classList.add("focused"):(lz(this,pB,"m",FB).call(this),lz(this,bB,"f").hidden=!1,lz(this,bB,"f").style.zIndex=(parseInt(lz(this,bB,"f").style.zIndex,10)+1e3).toString())},NB=function(){lz(this,bB,"f").classList.remove("focused"),!lz(this,SB,"f")&&this.isVisible&&(lz(this,bB,"f").hidden=!0,lz(this,bB,"f").style.zIndex=(parseInt(lz(this,bB,"f").style.zIndex,10)-1e3).toString())};class sH extends XB{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=mI.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}}class lH extends XB{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0,createQuadrilaterals:!0})}render(){return this.container.classList.add("k-highlight-annotation"),this.container}}class cH{constructor({div:e,accessibilityManager:t,annotationCanvasMap:n,annotationEditorUIManager:i,page:r,viewport:o}){$B.add(this),this.div=null,this.page=null,this.viewport=null,this.zIndex=null,this._annotationEditorUIManager=null,UB.set(this,null),WB.set(this,null),jB.set(this,new Map),this.div=e,cz(this,UB,t,"f"),cz(this,WB,n,"f"),this.page=r,this.viewport=o,this.zIndex=0,this._annotationEditorUIManager=i}hide(){this.div&&(this.div.hidden=!0)}hasEditableAnnotations(){return lz(this,jB,"f").size>0}render(e){var t;const{annotations:n}=e;const i=this.div;vI(i,this.viewport);const r=new Map;const o={data:null,layer:i,linkService:e.linkService,downloadManager:e.downloadManager,imageResourcesPath:e.imageResourcesPath||"",renderForms:!1!==e.renderForms,svgFactory:new wI,annotationStorage:e.annotationStorage||new nB,enableScripting:!0===e.enableScripting,hasJSActions:e.hasJSActions,fieldObjects:e.fieldObjects,parent:this,elements:null};for(const e of n){if(e.noHTML)continue;const n=e.annotationType===kz;if(n){const t=r.get(e.id);if(!t)continue;o.elements=t}else{const{width:t,height:n}=YB(e.rect);if(t<=0||n<=0)continue}o.data=e;const i=QB.create(o);if(!i.isRenderable)continue;if(!n&&e.popupRef){const t=r.get(e.popupRef);t?t.push(i):r.set(e.popupRef,[i])}const a=i.render();e.hidden&&(a.style.visibility="hidden"),lz(this,$B,"m",qB).call(this,a,e.id),i._isEditable&&(lz(this,jB,"f").set(i.data.id,i),null===(t=this._annotationEditorUIManager)||void 0===t||t.renderAnnotationElement(i))}lz(this,$B,"m",GB).call(this)}update({viewport:e}){const t=this.div;this.viewport=e,vI(t,e),lz(this,$B,"m",GB).call(this),t.hidden=!1}getEditableAnnotations(){return Array.from(lz(this,jB,"f").values())}getEditableAnnotation(e){return lz(this,jB,"f").get(e)}destroy(){var e,t;null===(e=lz(this,WB,"f"))||void 0===e||e.clear(),null===(t=this.div)||void 0===t||t.remove(),this.div=null}}var dH,hH,uH,pH;UB=new WeakMap,WB=new WeakMap,jB=new WeakMap,$B=new WeakSet,qB=function(e,t){var n;const i=e.firstChild||e;i.id=`${zz}${t}`,this.div.append(e),null===(n=lz(this,UB,"f"))||void 0===n||n.moveElementInDOM(this.div,e,i,!1)},GB=function(){if(!lz(this,WB,"f"))return;const e=this.div;for(const[t,n]of lz(this,WB,"f")){const i=e.querySelector(`[data-annotation-id="${t}"]`);if(!i)continue;n.className="annotationContent k-annotation-content";const{firstChild:r}=i;r?"CANVAS"===r.nodeName?r.replaceWith(n):r.classList.contains("annotationContent")&&r.classList.contains("k-annotation-content")?r.after(n):r.before(n):i.append(n)}lz(this,WB,"f").clear()};class fH{constructor({pdfPage:e,eventBus:t,linkService:n=null,annotationStorage:i=null,renderForms:r=!0,annotationCanvasMap:o=null,accessibilityManager:a=null,annotationEditorUIManager:s=null,onAppend:l=null}){dH.add(this),this.annotationLayer=null,this.pdfPage=null,this.linkService=null,this.annotationStorage=null,this._annotationCanvasMap=null,this._annotationEditorUIManager=null,this.div=null,this._cancelled=null,this._eventBus=null,this._accessibilityManager=null,hH.set(this,null),uH.set(this,null),this.renderForms=null,this.pdfPage=e,this.linkService=n,this.renderForms=r,this.annotationStorage=i,this._annotationCanvasMap=o,this._accessibilityManager=a,this._annotationEditorUIManager=s,cz(this,hH,l,"f"),this.annotationLayer=null,this.div=null,this._cancelled=!1,this._eventBus=(null==n?void 0:n.eventBus)||t}render(e){return sz(this,arguments,void 0,(function*(e,t="display"){var n,i,r;if(this.div){if(this._cancelled||!this.annotationLayer)return;return void this.annotationLayer.update({viewport:e.clone({dontFlip:!0})})}const[o]=yield Promise.all([this.pdfPage.getAnnotations({intent:t})]);if(this._cancelled)return;if(0===o.length)return void this.hide();const a=null===(n=this.pdfPage._pageInfo)||void 0===n?void 0:n.view;const s=(a[2]||0)+"px";const l=(a[3]||0)+"px";const c=OI(`\n <div class="k-annotation-layer"\n data-main-rotation="0"\n style="width: round(var(--scale-factor) * ${s}, 1px);\n height: round(var(--scale-factor) * ${l}, 1px);">\n </div>\n `);this.div=c,null===(i=lz(this,hH,"f"))||void 0===i||i.call(this,c),this.annotationLayer=new cH({div:c,accessibilityManager:this._accessibilityManager,annotationCanvasMap:this._annotationCanvasMap,annotationEditorUIManager:this._annotationEditorUIManager,page:this.pdfPage,viewport:e.clone({dontFlip:!0})}),yield this.annotationLayer.render({annotations:o,renderForms:this.renderForms,linkService:this.linkService,annotationStorage:this.annotationStorage}),this.linkService.isInPresentationMode&&lz(this,dH,"m",pH).call(this,WP),lz(this,uH,"f")||(cz(this,uH,new AbortController,"f"),null===(r=this._eventBus)||void 0===r||r._on("presentationmodechanged",(e=>{lz(this,dH,"m",pH).call(this,e.state)}),{signal:lz(this,uH,"f").signal}))}))}cancel(){var e;this._cancelled=!0,null===(e=lz(this,uH,"f"))||void 0===e||e.abort(),cz(this,uH,null,"f")}hide(){this.div&&(this.div.hidden=!0)}hasEditableAnnotations(){var e;return!!(null===(e=this.annotationLayer)||void 0===e?void 0:e.hasEditableAnnotations())}destroy(){var e,t,n;this.cancel(),null===(e=this.annotationLayer)||void 0===e||e.destroy(),this.annotationLayer=null,null===(t=lz(this,uH,"f"))||void 0===t||t.abort(),cz(this,uH,null,"f"),null===(n=this.div)||void 0===n||n.remove(),this.div=null}}var mH,gH,vH,_H,bH,wH,yH,kH,xH;hH=new WeakMap,uH=new WeakMap,dH=new WeakSet,pH=function(e){if(!this.div)return;let t=!1;switch(e){case WP:t=!0;break;case UP:break;default:return}for(const e of this.div.childNodes)e.hasAttribute("data-internal-link")||(e.inert=t)};class CH{constructor({pageIndex:e}){mH.add(this),this.pageIndex=0,vH.set(this,null),_H.set(this,0),bH.set(this,new Map),wH.set(this,new Map),this.pageIndex=e}setParent(e){if(lz(this,vH,"f")){if(lz(this,vH,"f")!==e){if(lz(this,bH,"f").size>0)for(const t of lz(this,bH,"f").values())t.remove(),e.append(t);cz(this,vH,e,"f")}}else cz(this,vH,e,"f")}static get _svgFactory(){return fI(this,"_svgFactory",new wI)}highlight(e,t,n,i=!1){var r,o;const a=(cz(this,_H,(o=lz(this,_H,"f"),r=o++,o),"f"),r);const s=lz(this,mH,"m",kH).call(this,e.box);s.classList.add("k-highlight"),e.free;const l=gH._svgFactory.createElement("defs");s.append(l);const c=gH._svgFactory.createElement("path");l.append(c);const d=`path_p${this.pageIndex}_${a}`;c.setAttribute("id",d),c.setAttribute("d",e.toSVGPath()),i&&lz(this,wH,"f").set(a,c);const h=lz(this,mH,"m",xH).call(this,l,d);const u=gH._svgFactory.createElement("use");return s.append(u),s.setAttribute("fill",t),s.setAttribute("fill-opacity",n),u.setAttribute("href",`#${d}`),lz(this,bH,"f").set(a,s),{id:a,clipPathId:`url(#${h})`}}highlightOutline(e){var t,n;const i=(cz(this,_H,(n=lz(this,_H,"f"),t=n++,n),"f"),t);const r=lz(this,mH,"m",kH).call(this,e.box);r.classList.add("k-highlight-outline");const o=gH._svgFactory.createElement("defs");r.append(o);const a=gH._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=gH._svgFactory.createElement("mask");o.append(e),l=`mask_p${this.pageIndex}_${i}`,e.setAttribute("id",l),e.setAttribute("maskUnits","objectBoundingBox");const t=gH._svgFactory.createElement("rect");e.append(t),t.setAttribute("width","1"),t.setAttribute("height","1"),t.setAttribute("fill","white");const n=gH._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=gH._svgFactory.createElement("use");r.append(c),c.setAttribute("href",`#${s}`),l&&c.setAttribute("mask",`url(#${l})`);const d=c.cloneNode();return r.append(d),lz(this,bH,"f").set(i,r),i}finalizeLine(e,t){const n=lz(this,wH,"f").get(e);lz(this,wH,"f").delete(e),this.updateBox(e,t.box),n.setAttribute("d",t.toSVGPath())}updateLine(e,t){lz(this,bH,"f").get(e).firstChild.firstChild.setAttribute("d",t.toSVGPath())}removeFreeHighlight(e){this.remove(e),lz(this,wH,"f").delete(e)}updatePath(e,t){lz(this,wH,"f").get(e).setAttribute("d",t.toSVGPath())}updateBox(e,t){lz(gH,gH,"m",yH).call(gH,lz(this,bH,"f").get(e),t)}show(e,t){lz(this,bH,"f").get(e).classList.toggle("k-hidden",!t)}rotate(e,t){lz(this,bH,"f").get(e).setAttribute("data-main-rotation",t)}changeColor(e,t){lz(this,bH,"f").get(e).setAttribute("fill",t)}changeOpacity(e,t){lz(this,bH,"f").get(e).setAttribute("fill-opacity",t)}addClass(e,t){lz(this,bH,"f").get(e).classList.add(t)}removeClass(e,t){lz(this,bH,"f").get(e).classList.remove(t)}remove(e){null!==lz(this,vH,"f")&&(lz(this,bH,"f").get(e).remove(),lz(this,bH,"f").delete(e))}destroy(){cz(this,vH,null,"f");for(const e of lz(this,bH,"f").values())e.remove();lz(this,bH,"f").clear()}}var SH;gH=CH,vH=new WeakMap,_H=new WeakMap,bH=new WeakMap,wH=new WeakMap,mH=new WeakSet,yH=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+"%"},kH=function(e){const t=gH._svgFactory.create(1,1,!0);return lz(this,vH,"f").append(t),t.setAttribute("aria-hidden",!0),lz(gH,gH,"m",yH).call(gH,t,e),t},xH=function(e,t){const n=gH._svgFactory.createElement("clipPath");e.append(n);const i=`clip_${t}`;n.setAttribute("id",i),n.setAttribute("clipPathUnits","objectBoundingBox");const r=gH._svgFactory.createElement("use");return n.append(r),r.setAttribute("href",`#${t}`),i};class TH{constructor(e){this.pageIndex=null,this._cancelled=null,SH.set(this,null),this.pageIndex=e.pageIndex}render(){return sz(this,arguments,void 0,(function*(e="display"){"display"!==e||lz(this,SH,"f")||cz(this,SH,new CH({pageIndex:this.pageIndex}),"f")}))}cancel(){var e;lz(this,SH,"f")&&(null===(e=lz(this,SH,"f"))||void 0===e||e.destroy(),cz(this,SH,null,"f"))}setParent(e){var t;null===(t=lz(this,SH,"f"))||void 0===t||t.setParent(e)}getDrawLayer(){return lz(this,SH,"f")}destroy(){this.cancel()}}var MH,AH,DH,EH,IH,zH,PH,LH,BH,HH,RH,FH,OH,VH,NH,$H,UH;SH=new WeakMap;const WH=/\r\n?|\n/g;class jH extends UL{constructor(e){super(Object.assign(Object.assign({},e),{name:"k-free-text-editor freeTextEditor"})),MH.add(this),this.editorDiv=null,this.overlayDiv=null,DH.set(this,void 0),EH.set(this,""),IH.set(this,`${this.id}-editor`),zH.set(this,null),PH.set(this,void 0),LH.set(this,null),cz(this,DH,e.color||AH._defaultColor||UL._defaultLineColor,"f"),cz(this,PH,e.fontSize||AH._defaultFontSize,"f")}static initialize(e,t){UL.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 _I.FREETEXT_SIZE:AH._defaultFontSize=t;break;case _I.FREETEXT_COLOR:AH._defaultColor=t}}updateParams(e,t){switch(e){case _I.FREETEXT_SIZE:lz(this,MH,"m",BH).call(this,t);break;case _I.FREETEXT_COLOR:lz(this,MH,"m",HH).call(this,t)}}static get defaultPropertiesToUpdate(){return[[_I.FREETEXT_SIZE,AH._defaultFontSize],[_I.FREETEXT_COLOR,AH._defaultColor||UL._defaultLineColor]]}get propertiesToUpdate(){return[[_I.FREETEXT_SIZE,lz(this,PH,"f")],[_I.FREETEXT_COLOR,lz(this,DH,"f")]]}_translateEmpty(e,t){this._uiManager.translateSelectedEditors(e,t,!0)}getInitialTranslation(){const e=this.parentScale;return[-AH._internalPadding*e,-(AH._internalPadding+lz(this,PH,"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(mI.FREETEXT),super.enableEditMode(),this.overlayDiv.classList.remove("enabled"),this.editorDiv.contentEditable=!0,this._isDraggable=!1,this.div.removeAttribute("aria-activedescendant"),cz(this,zH,new AbortController,"f");const e=this._uiManager.combinedSignal(lz(this,zH,"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",lz(this,IH,"f")),this._isDraggable=!0,null===(e=lz(this,zH,"f"))||void 0===e||e.abort(),cz(this,zH,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())===mI.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=lz(this,EH,"f");const t=cz(this,EH,lz(this,MH,"m",RH).call(this).trimEnd(),"f");if(e===t)return;const n=e=>{cz(this,EH,e,"f"),e?(lz(this,MH,"m",VH).call(this),this._uiManager.rebuild(this),lz(this,MH,"m",FH).call(this)):this.remove()};this.addCommands({cmd:()=>{n(t)},undo:()=>{n(e)},mustExec:!1}),lz(this,MH,"m",FH).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",lz(this,IH,"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(${lz(this,PH,"f")}px * var(--scale-factor))`,i.color=lz(this,DH,"f"),this.div.append(this.editorDiv),this.overlayDiv=document.createElement("div"),this.div.append(this.overlayDiv),wL(this,this.div,["dblclick","keydown"]),this.width){const[e,i]=this.parentDimensions;if(this.annotationElementId){const{position:r}=lz(this,LH,"f");let[o,a]=this.getInitialTranslation();[o,a]=this.pageTranslationToScreen(o,a);const[s,l]=this.pageDimensions;const[c,d]=this.pageTranslation;let h,u;switch(this.rotation){case 0:h=t+(r[0]-c)/s,u=n+this.height-(r[1]-d)/l;break;case 90:h=t+(r[0]-c)/s,u=n-(r[1]-d)/l,[o,a]=[a,-o];break;case 180:h=t-this.width+(r[0]-c)/s,u=n-(r[1]-d)/l,[o,a]=[-o,-a];break;case 270:h=t+(r[0]-c-this.height*l)/s,u=n+(r[1]-d-this.width*s)/l,[o,a]=[-a,o]}this.setAt(h*e,u*i,o,a)}else this.setAt(t*e,n*i,this.width*e,this.height*i);lz(this,MH,"m",VH).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;const{types:n}=t;if(1===n.length&&"text/plain"===n[0])return;e.preventDefault();const i=lz(AH,AH,"m",$H).call(AH,t.getData("text")||"").replaceAll(WH,"\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;const l=[];const c=[];if(a.nodeType===Node.TEXT_NODE){const e=a.parentElement;if(c.push(a.nodeValue.slice(s).replaceAll(WH,"")),e!==this.editorDiv){let t=l;for(const n of this.editorDiv.childNodes)n!==e?t.push(lz(AH,AH,"m",OH).call(AH,n)):t=c}l.push(a.nodeValue.slice(0,s).replaceAll(WH,""))}else if(a===this.editorDiv){let e=l;let t=0;for(const n of this.editorDiv.childNodes)t++===s&&(e=c),e.push(lz(AH,AH,"m",OH).call(AH,n))}cz(this,EH,`${l.join("\n")}${i}${c.join("\n")}`,"f"),lz(this,MH,"m",VH).call(this);const d=new Range;let h=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(h<=t){d.setStart(e,h),d.setEnd(e,h);break}h-=t}r.removeAllRanges(),r.addRange(d)}get contentDiv(){return this.editorDiv}static deserialize(e,t,n){let i=null;if(e instanceof sH){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:mI.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 cz(r,PH,e.fontSize,"f"),cz(r,DH,kI.makeHexColor(...e.color),"f"),cz(r,EH,lz(AH,AH,"m",$H).call(AH,e.value),"f"),r.annotationElementId=e.id||null,cz(r,LH,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=AH._internalPadding*this.parentScale;const n=this.getRect(t,t);const i=UL._colorManager.convert(this.isAttachedToDOM?getComputedStyle(this.editorDiv).color:lz(this,DH,"f"));const r={annotationType:mI.FREETEXT,color:i,fontSize:lz(this,PH,"f"),value:lz(this,MH,"m",NH).call(this),pageIndex:this.pageIndex,rect:n,rotation:this.rotation,structTreeParentId:this._structTreeParentId};return e?r:this.annotationElementId&&!lz(this,MH,"m",UH).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(${lz(this,PH,"f")}px * var(--scale-factor))`,n.color=lz(this,DH,"f"),t.replaceChildren();for(const e of lz(this,EH,"f").split("\n")){const n=document.createElement("div");n.append(e?document.createTextNode(e):document.createElement("br")),t.append(n)}const i=AH._internalPadding*this.parentScale;return e.updateEdited({rect:this.getRect(i,i),popupContent:lz(this,EH,"f")}),t}resetAnnotationElement(e){super.resetAnnotationElement(e),e.resetEdited()}toJSON(){return this.serialize()}}var qH,GH,KH,YH,QH,XH,ZH,JH,eR,tR,nR,iR,rR,oR,aR,sR,lR,cR,dR,hR,uR,pR,fR,mR,gR,vR,_R,bR,wR,yR,kR,xR,CR,SR,TR,MR,AR,DR,ER,IR,zR;AH=jH,DH=new WeakMap,EH=new WeakMap,IH=new WeakMap,zH=new WeakMap,PH=new WeakMap,LH=new WeakMap,MH=new WeakSet,BH=function(e){const t=e=>{this.editorDiv.style.fontSize=`calc(${e}px * var(--scale-factor))`,this.translate(0,-(e-lz(this,PH,"f"))*this.parentScale),cz(this,PH,e,"f"),lz(this,MH,"m",FH).call(this)};const n=lz(this,PH,"f");this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:_I.FREETEXT_SIZE,overwriteIfSameType:!0,keepUndo:!0})},HH=function(e){const t=e=>{cz(this,DH,this.editorDiv.style.color=e,"f")};const n=lz(this,DH,"f");this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:_I.FREETEXT_COLOR,overwriteIfSameType:!0,keepUndo:!0})},RH=function(){const e=[];this.editorDiv.normalize();for(const t of this.editorDiv.childNodes)e.push(lz(AH,AH,"m",OH).call(AH,t));return e.join("\n")},FH=function(){const[e,t]=this.parentDimensions;let n;if(this.isAttachedToDOM)n=this.div.getBoundingClientRect();else{const{currentLayer:e,div:t}=this;const i=t.style.display;const 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()},OH=function(e){return(e.nodeType===Node.TEXT_NODE?e.nodeValue:e.innerText).replaceAll(WH,"")},VH=function(){if(this.editorDiv.replaceChildren(),lz(this,EH,"f"))for(const e of lz(this,EH,"f").split("\n")){const t=document.createElement("div");t.append(e?document.createTextNode(e):document.createElement("br")),this.editorDiv.append(t)}},NH=function(){return lz(this,EH,"f").replaceAll(" "," ")},$H=function(e){return e.replaceAll(" "," ")},UH=function(e){const{value:t,fontSize:n,color:i,pageIndex:r}=lz(this,LH,"f");return this._hasBeenMoved||e.value!==t||e.fontSize!==n||e.color.some(((e,t)=>e!==i[t]))||e.pageIndex!==r},jH._freeTextDefaultContent="",jH._internalPadding=0,jH._defaultColor="#000000",jH._defaultFontSize=10,jH._type="freetext",jH._editorType=mI.FREETEXT;class PR{constructor(e,t=0,n=0,i=!0){qH.add(this),GH.set(this,void 0),KH.set(this,[]),YH.set(this,[]);let r=1/0;let o=-1/0;let a=1/0;let 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;const h=Math.ceil((n+c+t)/l)*l;const u=Math.floor((i-t)/l)*l;const p=Math.ceil((i+d+t)/l)*l;const f=[e,u,p,!0];const m=[h,u,p,!1];lz(this,KH,"f").push(f,m),r=Math.min(r,e),o=Math.max(o,h),a=Math.min(a,u),s=Math.max(s,p)}const c=o-r+2*n;const d=s-a+2*n;const h=r-n;const u=a-n;const p=lz(this,KH,"f").at(i?-1:-2);const f=[p[0],p[2]];for(const e of lz(this,KH,"f")){const[t,n,i]=e;e[0]=(t-h)/c,e[1]=(n-u)/d,e[2]=(i-u)/d}cz(this,GH,{x:h,y:u,width:c,height:d,lastPoint:f},"f")}getOutlines(){lz(this,KH,"f").sort(((e,t)=>e[0]-t[0]||e[1]-t[1]||e[2]-t[2]));const e=[];for(const t of lz(this,KH,"f"))t[3]?(e.push(...lz(this,qH,"m",eR).call(this,t)),lz(this,qH,"m",ZH).call(this,t)):(lz(this,qH,"m",JH).call(this,t),e.push(...lz(this,qH,"m",eR).call(this,t)));return lz(this,qH,"m",QH).call(this,e)}}GH=new WeakMap,KH=new WeakMap,YH=new WeakMap,qH=new WeakSet,QH=function(e){const t=[];const 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];const 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;let 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 BR(i,lz(this,GH,"f"))},XH=function(e){const t=lz(this,YH,"f");let n=0;let i=t.length-1;for(;n<=i;){const r=n+i>>1;const o=t[r][0];if(o===e)return r;o<e?n=r+1:i=r-1}return i+1},ZH=function([,e,t]){const n=lz(this,qH,"m",XH).call(this,e);lz(this,YH,"f").splice(n,0,[e,t])},JH=function([,e,t]){const n=lz(this,qH,"m",XH).call(this,e);for(let i=n;i<lz(this,YH,"f").length;i++){const[n,r]=lz(this,YH,"f")[i];if(n!==e)break;if(n===e&&r===t)return void lz(this,YH,"f").splice(i,1)}for(let i=n-1;i>=0;i--){const[n,r]=lz(this,YH,"f")[i];if(n!==e)break;if(n===e&&r===t)return void lz(this,YH,"f").splice(i,1)}},eR=function(e){const[t,n,i]=e;const r=[[t,n,i]];const o=lz(this,qH,"m",XH).call(this,i);for(let e=0;e<o;e++){const[n,i]=lz(this,YH,"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 LR{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 RR}}class BR extends LR{constructor(e,t){super(),tR.set(this,void 0),nR.set(this,void 0),cz(this,nR,e,"f"),cz(this,tR,t,"f")}toSVGPath(){const e=[];for(const t of lz(this,nR,"f")){let[n,i]=t;e.push(`M${n} ${i}`);for(let r=2;r<t.length;r+=2){const o=t[r];const 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=[];const o=n-e;const a=i-t;for(const t of lz(this,nR,"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 lz(this,tR,"f")}}tR=new WeakMap,nR=new WeakMap;class HR{constructor({x:e,y:t},n,i,r,o,a=0){iR.add(this),oR.set(this,void 0),aR.set(this,[]),sR.set(this,void 0),lR.set(this,void 0),cR.set(this,[]),dR.set(this,new Float64Array(18)),hR.set(this,void 0),uR.set(this,void 0),pR.set(this,void 0),fR.set(this,void 0),mR.set(this,void 0),gR.set(this,void 0),vR.set(this,[]),cz(this,oR,n,"f"),cz(this,gR,r*i,"f"),cz(this,lR,o,"f"),lz(this,dR,"f").set([NaN,NaN,NaN,NaN,e,t],6),cz(this,sR,a,"f"),cz(this,fR,lz(rR,rR,"f",_R)*i,"f"),cz(this,pR,lz(rR,rR,"f",wR)*i,"f"),cz(this,mR,i,"f"),lz(this,vR,"f").push(e,t)}get free(){return!0}isEmpty(){return isNaN(lz(this,dR,"f")[8])}add({x:e,y:t}){var n;cz(this,hR,e,"f"),cz(this,uR,t,"f");const[i,r,o,a]=lz(this,oR,"f");let[s,l,c,d]=lz(this,dR,"f").subarray(8,12);const h=e-c;const u=t-d;const p=Math.hypot(h,u);if(p<lz(this,pR,"f"))return!1;const f=p-lz(this,fR,"f");const m=f/p;const g=m*h;const v=m*u;let _=s;let b=l;s=c,l=d,c+=g,d+=v,null===(n=lz(this,vR,"f"))||void 0===n||n.push(e,t);const w=g/f;const y=-v/f*lz(this,gR,"f");const k=w*lz(this,gR,"f");if(lz(this,dR,"f").set(lz(this,dR,"f").subarray(2,8),0),lz(this,dR,"f").set([c+y,d+k],4),lz(this,dR,"f").set(lz(this,dR,"f").subarray(14,18),12),lz(this,dR,"f").set([c-y,d-k],16),isNaN(lz(this,dR,"f")[6]))return 0===lz(this,cR,"f").length&&(lz(this,dR,"f").set([s+y,l+k],2),lz(this,cR,"f").push(NaN,NaN,NaN,NaN,(s+y-i)/o,(l+k-r)/a),lz(this,dR,"f").set([s-y,l-k],14),lz(this,aR,"f").push(NaN,NaN,NaN,NaN,(s-y-i)/o,(l-k-r)/a)),lz(this,dR,"f").set([_,b,s,l,c,d],6),!this.isEmpty();lz(this,dR,"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]=lz(this,dR,"f").subarray(2,6),lz(this,cR,"f").push(NaN,NaN,NaN,NaN,((s+c)/2-i)/o,((l+d)/2-r)/a),[s,l,_,b]=lz(this,dR,"f").subarray(14,18),lz(this,aR,"f").push(NaN,NaN,NaN,NaN,((_+s)/2-i)/o,((b+l)/2-r)/a),!0):([_,b,s,l,c,d]=lz(this,dR,"f").subarray(0,6),lz(this,cR,"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]=lz(this,dR,"f").subarray(12,18),lz(this,aR,"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=lz(this,cR,"f");const t=lz(this,aR,"f");const n=lz(this,dR,"f").subarray(4,6);const i=lz(this,dR,"f").subarray(16,18);const[r,o,a,s]=lz(this,oR,"f");const[l,c,d,h]=lz(this,iR,"m",yR).call(this);if(isNaN(lz(this,dR,"f")[6])&&!this.isEmpty())return`M${(lz(this,dR,"f")[2]-r)/a} ${(lz(this,dR,"f")[3]-o)/s} L${(lz(this,dR,"f")[4]-r)/a} ${(lz(this,dR,"f")[5]-o)/s} L${l} ${c} L${d} ${h} L${(lz(this,dR,"f")[16]-r)/a} ${(lz(this,dR,"f")[17]-o)/s} L${(lz(this,dR,"f")[14]-r)/a} ${(lz(this,dR,"f")[15]-o)/s} Z`;const u=[];u.push(`M${e[4]} ${e[5]}`);for(let t=6;t<e.length;t+=6)isNaN(e[t])?u.push(`L${e[t+4]} ${e[t+5]}`):u.push(`C${e[t]} ${e[t+1]} ${e[t+2]} ${e[t+3]} ${e[t+4]} ${e[t+5]}`);u.push(`L${(n[0]-r)/a} ${(n[1]-o)/s} L${l} ${c} L${d} ${h} L${(i[0]-r)/a} ${(i[1]-o)/s}`);for(let e=t.length-6;e>=6;e-=6)isNaN(t[e])?u.push(`L${t[e+4]} ${t[e+5]}`):u.push(`C${t[e]} ${t[e+1]} ${t[e+2]} ${t[e+3]} ${t[e+4]} ${t[e+5]}`);return u.push(`L${t[4]} ${t[5]} Z`),u.join(" ")}getOutlines(){var e,t;const n=lz(this,cR,"f");const i=lz(this,aR,"f");const r=lz(this,dR,"f");const o=r.subarray(4,6);const a=r.subarray(16,18);const[s,l,c,d]=lz(this,oR,"f");const h=new Float64Array((null!==(t=null===(e=lz(this,vR,"f"))||void 0===e?void 0:e.length)&&void 0!==t?t:0)+2);for(let e=0,t=h.length-2;e<t;e+=2)h[e]=(lz(this,vR,"f")[e]-s)/c,h[e+1]=(lz(this,vR,"f")[e+1]-l)/d;h[h.length-2]=(lz(this,hR,"f")-s)/c,h[h.length-1]=(lz(this,uR,"f")-l)/d;const[u,p,f,m]=lz(this,iR,"m",yR).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,u,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 RR(e,h,lz(this,oR,"f"),lz(this,mR,"f"),lz(this,sR,"f"),lz(this,lR,"f"))}const g=new Float64Array(lz(this,cR,"f").length+24+lz(this,aR,"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,u,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 RR(g,h,lz(this,oR,"f"),lz(this,mR,"f"),lz(this,sR,"f"),lz(this,lR,"f"))}}rR=HR,oR=new WeakMap,aR=new WeakMap,sR=new WeakMap,lR=new WeakMap,cR=new WeakMap,dR=new WeakMap,hR=new WeakMap,uR=new WeakMap,pR=new WeakMap,fR=new WeakMap,mR=new WeakMap,gR=new WeakMap,vR=new WeakMap,iR=new WeakSet,yR=function(){const e=lz(this,dR,"f").subarray(4,6);const t=lz(this,dR,"f").subarray(16,18);const[n,i,r,o]=lz(this,oR,"f");return[(lz(this,hR,"f")+(e[0]-t[0])/2-n)/r,(lz(this,uR,"f")+(e[1]-t[1])/2-i)/o,(lz(this,hR,"f")+(t[0]-e[0])/2-n)/r,(lz(this,uR,"f")+(t[1]-e[1])/2-i)/o]},bR={value:2},wR={value:lz(rR,rR,"f",_R={value:8})+lz(rR,rR,"f",bR)};class RR extends LR{constructor(e,t,n,i,r,o){super(),kR.add(this),xR.set(this,void 0),CR.set(this,null),SR.set(this,void 0),TR.set(this,void 0),MR.set(this,void 0),AR.set(this,void 0),DR.set(this,void 0),cz(this,DR,e,"f"),cz(this,MR,t,"f"),cz(this,xR,n,"f"),cz(this,AR,i,"f"),cz(this,SR,r,"f"),cz(this,TR,o,"f"),lz(this,kR,"m",zR).call(this,o);const{x:a,y:s,width:l,height:c}=lz(this,CR,"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${lz(this,DR,"f")[4]} ${lz(this,DR,"f")[5]}`];for(let t=6,n=lz(this,DR,"f").length;t<n;t+=6)isNaN(lz(this,DR,"f")[t])?e.push(`L${lz(this,DR,"f")[t+4]} ${lz(this,DR,"f")[t+5]}`):e.push(`C${lz(this,DR,"f")[t]} ${lz(this,DR,"f")[t+1]} ${lz(this,DR,"f")[t+2]} ${lz(this,DR,"f")[t+3]} ${lz(this,DR,"f")[t+4]} ${lz(this,DR,"f")[t+5]}`);return e.push("Z"),e.join(" ")}serialize([e,t,n,i],r){const o=n-e;const a=i-t;let s;let l;switch(r){case 0:s=lz(this,kR,"m",ER).call(this,lz(this,DR,"f"),e,i,o,-a),l=lz(this,kR,"m",ER).call(this,lz(this,MR,"f"),e,i,o,-a);break;case 90:s=lz(this,kR,"m",IR).call(this,lz(this,DR,"f"),e,t,o,a),l=lz(this,kR,"m",IR).call(this,lz(this,MR,"f"),e,t,o,a);break;case 180:s=lz(this,kR,"m",ER).call(this,lz(this,DR,"f"),n,t,-o,a),l=lz(this,kR,"m",ER).call(this,lz(this,MR,"f"),n,t,-o,a);break;case 270:s=lz(this,kR,"m",IR).call(this,lz(this,DR,"f"),n,i,-o,-a),l=lz(this,kR,"m",IR).call(this,lz(this,MR,"f"),n,i,-o,-a)}return{outline:Array.from(s),points:[Array.from(l)]}}get box(){return lz(this,CR,"f")}getNewOutline(e,t){const{x:n,y:i,width:r,height:o}=lz(this,CR,"f");const[a,s,l,c]=lz(this,xR,"f");const d=r*l;const h=o*c;const u=n*l+a;const p=i*c+s;const f=new HR({x:lz(this,MR,"f")[0]*d+u,y:lz(this,MR,"f")[1]*h+p},lz(this,xR,"f"),lz(this,AR,"f"),e,lz(this,TR,"f"),null!=t?t:lz(this,SR,"f"));for(let e=2;e<lz(this,MR,"f").length;e+=2)f.add({x:lz(this,MR,"f")[e]*d+u,y:lz(this,MR,"f")[e+1]*h+p});return f.getOutlines()}}var FR,OR,VR,NR,$R,UR,WR,jR,qR,GR,KR,YR,QR,XR,ZR,JR,eF,tF,nF,iF,rF,oF,aF,sF,lF,cF,dF,hF,uF,pF,fF,mF,gF;xR=new WeakMap,CR=new WeakMap,SR=new WeakMap,TR=new WeakMap,MR=new WeakMap,AR=new WeakMap,DR=new WeakMap,kR=new WeakSet,ER=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},IR=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},zR=function(e){const t=lz(this,DR,"f");let n=t[4];let i=t[5];let r=n;let o=i;let a=n;let s=i;let l=n;let c=i;const d=e?Math.max:Math.min;for(let e=6,h=t.length;e<h;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 h=kI.bezierBoundingBox(n,i,...t.slice(e,e+6));r=Math.min(r,h[0]),o=Math.min(o,h[1]),a=Math.max(a,h[2]),s=Math.max(s,h[3]),c<h[3]?(l=h[2],c=h[3]):c===h[3]&&(l=d(l,h[2]))}n=t[e+4],i=t[e+5]}const h=r-lz(this,SR,"f"),u=o-lz(this,SR,"f"),p=a-r+2*lz(this,SR,"f"),f=s-o+2*lz(this,SR,"f");cz(this,CR,{x:h,y:u,width:p,height:f,lastPoint:[l,c]},"f")};class vF extends UL{constructor(e){super(Object.assign(Object.assign({},e),{name:"k-highlight-editor"})),FR.add(this),this.color="",VR.set(this,null),NR.set(this,0),$R.set(this,void 0),UR.set(this,null),WR.set(this,null),jR.set(this,null),qR.set(this,0),GR.set(this,null),KR.set(this,null),YR.set(this,null),QR.set(this,!1),XR.set(this,null),ZR.set(this,void 0),JR.set(this,null),eF.set(this,""),tF.set(this,void 0),nF.set(this,""),this.color=e.color||OR._defaultColor,cz(this,tF,e.thickness||OR._defaultThickness,"f"),cz(this,ZR,e.opacity||OR._defaultOpacity,"f"),cz(this,$R,e.boxes||null,"f"),cz(this,nF,e.methodOfCreation||"","f"),cz(this,eF,e.text||"","f"),this._isDraggable=!1,e.highlightId>-1?(cz(this,QR,!0,"f"),lz(this,FR,"m",rF).call(this,e),lz(this,FR,"m",lF).call(this)):(cz(this,VR,e.anchorNode,"f"),cz(this,NR,e.anchorOffset,"f"),cz(this,jR,e.focusNode,"f"),cz(this,qR,e.focusOffset,"f"),lz(this,FR,"m",iF).call(this),lz(this,FR,"m",lF).call(this),this.rotate(this.rotation))}get telemetryInitialData(){return{action:"added",type:lz(this,QR,"f")?"free_highlight":"highlight",color:this._uiManager.highlightColorNames.get(this.color),thickness:lz(this,tF,"f"),methodOfCreation:lz(this,nF,"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;UL.initialize(e,t,{}),OR._defaultColor||(OR._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 _I.HIGHLIGHT_DEFAULT_COLOR:OR._defaultColor=t;break;case _I.HIGHLIGHT_THICKNESS:OR._defaultThickness=t}}translateInPage(){}get toolbarPosition(){return lz(this,XR,"f")}updateParams(e,t){switch(e){case _I.HIGHLIGHT_COLOR:lz(this,FR,"m",oF).call(this,t);break;case _I.HIGHLIGHT_THICKNESS:lz(this,FR,"m",aF).call(this,t)}}static get defaultPropertiesToUpdate(){return[[_I.HIGHLIGHT_DEFAULT_COLOR,OR._defaultColor],[_I.HIGHLIGHT_THICKNESS,OR._defaultThickness]]}get propertiesToUpdate(){return[[_I.HIGHLIGHT_COLOR,this.color||OR._defaultColor],[_I.HIGHLIGHT_THICKNESS,lz(this,tF,"f")||OR._defaultThickness],[_I.HIGHLIGHT_FREE,lz(this,QR,"f")]]}disableEditing(){super.disableEditing(),this.div.classList.toggle("k-highlight-editor-disabled",!0)}enableEditing(){super.enableEditing(),this.div.classList.toggle("k-highlight-editor-disabled",!1)}fixAndSetPosition(){return super.fixAndSetPosition(lz(this,FR,"m",uF).call(this))}getBaseTranslation(){return[0,0]}getRect(e,t){return super.getRect(e,t,lz(this,FR,"m",uF).call(this))}onceAdded(){this.parent.addUndoableEditor(this),this.div.focus()}remove(){lz(this,FR,"m",sF).call(this),super.remove()}rebuild(){this.parent&&(super.rebuild(),null!==this.div&&(lz(this,FR,"m",lF).call(this),this.isAttachedToDOM||this.parent.add(this)))}setParent(e){var t,n;let i=!1;this.parent&&!e?lz(this,FR,"m",sF).call(this):e&&(lz(this,FR,"m",lF).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;lz(this,QR,"f")?(e=(e-this.rotation+360)%360,n=lz(OR,OR,"m",cF).call(OR,lz(this,KR,"f").box,e)):n=lz(OR,OR,"m",cF).call(OR,this,e),t.rotate(lz(this,YR,"f"),e),t.rotate(lz(this,JR,"f"),e),t.updateBox(lz(this,YR,"f"),n),t.updateBox(lz(this,JR,"f"),lz(OR,OR,"m",cF).call(OR,lz(this,WR,"f").box,e))}render(){if(this.div)return this.div;const e=super.render();lz(this,eF,"f")&&(e.setAttribute("aria-label",lz(this,eF,"f")),e.setAttribute("role","mark")),lz(this,QR,"f")?e.classList.add("free"):this.div.addEventListener("keydown",lz(this,FR,"m",dF).bind(this),{signal:this._uiManager._signal});const t=cz(this,GR,document.createElement("div"),"f");e.append(t),t.setAttribute("aria-hidden","true"),t.className="k-internal internal",t.style.clipPath=lz(this,UR,"f");const[n,i]=this.parentDimensions;return this.setDims(this.width*n,this.height*i),wL(this,lz(this,GR,"f"),["pointerover","pointerleave"]),this.enableEditing(),e}pointerover(){this.parent.drawLayer.addClass(lz(this,JR,"f"),"hovered")}pointerleave(){this.parent.drawLayer.removeClass(lz(this,JR,"f"),"hovered")}_moveCaret(e){switch(this.parent.unselect(this),e){case 0:case 2:lz(this,FR,"m",hF).call(this,!0);break;case 1:case 3:lz(this,FR,"m",hF).call(this,!1)}}select(){var e,t,n;super.select(),lz(this,JR,"f")&&(null===(e=this.parent)||void 0===e||e.drawLayer.removeClass(lz(this,JR,"f"),"hovered"),null===(t=this.parent)||void 0===t||t.drawLayer.addClass(lz(this,JR,"f"),"selected"),null===(n=this.parent)||void 0===n||n.drawLayer.addClass(lz(this,JR,"f"),"k-selected"))}unselect(){var e,t;super.unselect(),lz(this,JR,"f")&&(null===(e=this.parent)||void 0===e||e.drawLayer.removeClass(lz(this,JR,"f"),"selected"),null===(t=this.parent)||void 0===t||t.drawLayer.removeClass(lz(this,JR,"f"),"k-selected"),lz(this,QR,"f")||lz(this,FR,"m",hF).call(this,!1))}get _mustFixPosition(){return!lz(this,QR,"f")}show(e=this._isVisible){super.show(e),this.parent&&(this.parent.drawLayer.show(lz(this,YR,"f"),e),this.parent.drawLayer.show(lz(this,JR,"f"),e))}static startHighlighting(e,t,{target:n,x:i,y:r}){const{x:o,y:a,width:s,height:l}=n.getBoundingClientRect();const c=new AbortController;const d=e.combinedSignal(c);const h=t=>{c.abort(),lz(this,OR,"m",gF).call(this,e,t)};window.addEventListener("blur",h,{signal:d}),window.addEventListener("pointerup",h,{signal:d}),window.addEventListener("pointerdown",(e=>{e.preventDefault(),e.stopPropagation()}),{capture:!0,passive:!1,signal:d}),window.addEventListener("contextmenu",DI,{signal:d}),n.addEventListener("pointermove",lz(this,OR,"m",mF).bind(this,e),{signal:d}),this._freeHighlight=new HR({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);const{rect:[r,o,a,s],color:l,quadPoints:c}=e;i.color=kI.makeHexColor(...l),cz(i,ZR,e.opacity,"f");const[d,h]=i.pageDimensions;i.width=(a-r)/d,i.height=(s-o)/h;const u=cz(i,$R,[],"f");for(let e=0;e<c.length;e+=8)u.push({x:(c[4]-a)/d,y:(s-(1-c[e+5]))/h,width:(c[e+2]-c[e])/d,height:(c[e+5]-c[e+1])/h});return lz(i,FR,"m",iF).call(i),i}serialize(e=!1){if(this.isEmpty()||e)return null;const t=this.getRect(0,0);const n=UL._colorManager.convert(this.color);return{annotationType:mI.HIGHLIGHT,color:n,opacity:lz(this,ZR,"f"),thickness:lz(this,tF,"f"),quadPoints:lz(this,FR,"m",pF).call(this),outlines:lz(this,FR,"m",fF).call(this,t),pageIndex:this.pageIndex,rect:t,rotation:lz(this,FR,"m",uF).call(this),structTreeParentId:this._structTreeParentId}}static canCreateNewEmptyEditor(){return!1}toJSON(){return this.serialize()}}var _F,bF,wF,yF,kF,xF,CF,SF,TF,MF,AF,DF,EF,IF,zF,PF,LF,BF,HF,RF;OR=vF,VR=new WeakMap,NR=new WeakMap,$R=new WeakMap,UR=new WeakMap,WR=new WeakMap,jR=new WeakMap,qR=new WeakMap,GR=new WeakMap,KR=new WeakMap,YR=new WeakMap,QR=new WeakMap,XR=new WeakMap,ZR=new WeakMap,JR=new WeakMap,eF=new WeakMap,tF=new WeakMap,nF=new WeakMap,FR=new WeakSet,iF=function(){const e=new PR(lz(this,$R,"f"),.001);cz(this,KR,e.getOutlines(),"f"),({x:this.x,y:this.y,width:this.width,height:this.height}=lz(this,KR,"f").box);const t=new PR(lz(this,$R,"f"),.0025,.001,"ltr"===this._uiManager.direction);cz(this,WR,t.getOutlines(),"f");const{lastPoint:n}=lz(this,WR,"f").box;cz(this,XR,[(n[0]-this.x)/this.width,(n[1]-this.y)/this.height],"f")},rF=function({highlightOutlines:e,highlightId:t,clipPathId:n}){cz(this,KR,e,"f");if(cz(this,WR,e.getNewOutline(lz(this,tF,"f")/2+1.5,.0025),"f"),t>=0)cz(this,YR,t,"f"),cz(this,UR,n,"f"),this.parent.drawLayer.finalizeLine(t,e),cz(this,JR,this.parent.drawLayer.highlightOutline(lz(this,WR,"f")),"f");else if(this.parent){const t=this.parent.viewport.rotation;this.parent.drawLayer.updateLine(lz(this,YR,"f"),e),this.parent.drawLayer.updateBox(lz(this,YR,"f"),lz(OR,OR,"m",cF).call(OR,lz(this,KR,"f").box,(t-this.rotation+360)%360)),this.parent.drawLayer.updateLine(lz(this,JR,"f"),lz(this,WR,"f")),this.parent.drawLayer.updateBox(lz(this,JR,"f"),lz(OR,OR,"m",cF).call(OR,lz(this,WR,"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}=lz(this,WR,"f").box;cz(this,XR,[(s[0]-i)/o,(s[1]-r)/a],"f")},oF=function(e){if(!e)return;const t=e=>{var t;this.color=e,null===(t=this.parent)||void 0===t||t.drawLayer.changeColor(lz(this,YR,"f"),e)};const 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:_I.HIGHLIGHT_COLOR,overwriteIfSameType:!0,keepUndo:!0})},aF=function(e){},sF=function(){null!==lz(this,YR,"f")&&this.parent&&(this.parent.drawLayer.remove(lz(this,YR,"f")),cz(this,YR,null,"f"),this.parent.drawLayer.remove(lz(this,JR,"f")),cz(this,JR,null,"f"))},lF=function(e=this.parent){var t,n;null===lz(this,YR,"f")&&(t=this,n=this,({id:{set value(e){cz(t,YR,e,"f")}}.value,clipPathId:{set value(e){cz(n,UR,e,"f")}}.value}=e.drawLayer.highlight(lz(this,KR,"f"),this.color,lz(this,ZR,"f"))),cz(this,JR,e.drawLayer.highlightOutline(lz(this,WR,"f")),"f"),lz(this,GR,"f")&&(lz(this,GR,"f").style.clipPath=lz(this,UR,"f")))},cF=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}},dF=function(e){},hF=function(e){if(!lz(this,VR,"f"))return;const t=window.getSelection();e?t.setPosition(lz(this,VR,"f"),lz(this,NR,"f")):t.setPosition(lz(this,jR,"f"),lz(this,qR,"f"))},uF=function(){return lz(this,QR,"f")?this.rotation:0},pF=function(){if(lz(this,QR,"f"))return null;const[e,t]=this.pageDimensions;const[n,i]=this.pageTranslation;const r=lz(this,$R,"f");const 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;const h=(1-l-d)*t+i;o[a]=o[a+4]=r,o[a+1]=o[a+3]=h,o[a+2]=o[a+6]=r+c*e,o[a+5]=o[a+7]=h+d*t,a+=8}return o},fF=function(e){return lz(this,KR,"f").serialize(e,lz(this,FR,"m",uF).call(this))},mF=function(e,t){this._freeHighlight.add(t)&&e.drawLayer.updatePath(this._freeHighlightId,this._freeHighlight)},gF=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=""},vF._defaultColor=null,vF._defaultOpacity=1,vF._defaultThickness=12,vF._type="highlight",vF._editorType=mI.HIGHLIGHT,vF._freeHighlightId=-1,vF._freeHighlight=null,vF._freeHighlightClipId="";class FF{constructor({uiManager:e,pageIndex:t,div:n,accessibilityManager:i,annotationLayer:r,drawLayer:o,textLayer:a,viewport:s}){_F.add(this),this.drawLayer=null,this.pageIndex=0,this.div=null,this.viewport=null,wF.set(this,void 0),yF.set(this,!1),kF.set(this,null),xF.set(this,null),CF.set(this,null),SF.set(this,new Map),TF.set(this,!1),MF.set(this,!1),AF.set(this,!1),DF.set(this,null),EF.set(this,null),IF.set(this,null);const l=[...lz(bF,bF,"f",zF).values()];if(!bF._initialized){bF._initialized=!0;for(const t of l)t.initialize({},e)}e.registerEditorTypes(l),cz(this,IF,e,"f"),this.pageIndex=t,this.div=n,cz(this,wF,i,"f"),cz(this,kF,r,"f"),this.viewport=s,cz(this,DF,a,"f"),this.drawLayer=o,lz(this,IF,"f").addLayer(this)}hide(){this.div&&(this.div.hidden=!0)}show(){this.div&&!this.isInvisible&&(this.div.hidden=!1)}get isEmpty(){return 0===lz(this,SF,"f").size}get isInvisible(){return this.isEmpty&&lz(this,IF,"f").getMode()===mI.NONE}updateToolbar(){}updateMode(e=lz(this,IF,"f").getMode()){switch(lz(this,_F,"m",RF).call(this),e){case mI.NONE:return this.disableTextSelection(),this.togglePointerEvents(!1),this.toggleAnnotationLayerPointerEvents(!0),void this.disableClick();case mI.INK:this.addInkEditorIfNeeded(!1),this.disableTextSelection(),this.togglePointerEvents(!0),this.disableClick();break;case mI.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 lz(bF,bF,"f",zF).values())t.toggle(`${n._type}Editing`,e===n._editorType);this.div.hidden=!1}hasTextLayer(e){var t;return e===(null===(t=lz(this,DF,"f"))||void 0===t?void 0:t.div)}addInkEditorIfNeeded(e){if(lz(this,IF,"f").getMode()!==mI.INK)return;if(!e)for(const e of lz(this,SF,"f").values())if(e.isEmpty())return void e.setInBackground();this.createAndAddNewEditor({offsetX:0,offsetY:0},!1).setInBackground()}setEditingState(e){lz(this,IF,"f").setEditingState(e)}addCommands(e){lz(this,IF,"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=lz(this,kF,"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 lz(this,SF,"f").values())t.enableEditing(),t.show(!0),t.annotationElementId&&(lz(this,IF,"f").removeChangedExistingAnnotation(t),e.add(t.annotationElementId));if(!lz(this,kF,"f"))return;const t=lz(this,kF,"f").getEditableAnnotations();for(const n of t){if(n.hide(),lz(this,IF,"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;cz(this,AF,!0,"f"),this.div.tabIndex=-1,this.togglePointerEvents(!1);const t=new Map;const n=new Map;for(const i of lz(this,SF,"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(lz(this,kF,"f")){const e=lz(this,kF,"f").getEditableAnnotations();for(const i of e){const{id:e}=i.data;if(lz(this,IF,"f").isDeletedAnnotationElement(e))continue;let r=n.get(e);r?(r.resetAnnotationElement(i),r.show(!1),i.show()):(r=t.get(e),r&&(lz(this,IF,"f").addChangedExistingAnnotation(r),r.renderAnnotationElement(i),r.show(!1)),i.show())}}lz(this,_F,"m",RF).call(this),this.isEmpty&&(this.div.hidden=!0);const{classList:i}=this.div;for(const e of lz(bF,bF,"f",zF).values())i.remove(`${e._type}Editing`);this.disableTextSelection(),this.toggleAnnotationLayerPointerEvents(!0),cz(this,AF,!1,"f")}getEditableAnnotation(e){var t;return(null===(t=lz(this,kF,"f"))||void 0===t?void 0:t.getEditableAnnotation(e))||null}setActiveEditor(e){lz(this,IF,"f").getActive()!==e&&lz(this,IF,"f").setActiveEditor(e)}enableTextSelection(){var e;if(this.div.tabIndex=-1,(null===(e=lz(this,DF,"f"))||void 0===e?void 0:e.div)&&!lz(this,EF,"f")){cz(this,EF,new AbortController,"f");const e=lz(this,IF,"f").combinedSignal(lz(this,EF,"f"));lz(this,DF,"f").div.addEventListener("pointerdown",lz(this,_F,"m",PF).bind(this),{signal:e})}}disableTextSelection(){var e;this.div.tabIndex=0,(null===(e=lz(this,DF,"f"))||void 0===e?void 0:e.div)&&lz(this,EF,"f")&&(lz(this,EF,"f").abort(),cz(this,EF,null,"f"),lz(this,DF,"f").div.classList.remove("highlighting"))}enableClick(){if(lz(this,xF,"f"))return;cz(this,xF,new AbortController,"f");const e=lz(this,IF,"f").combinedSignal(lz(this,xF,"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=lz(this,xF,"f"))||void 0===e||e.abort(),cz(this,xF,null,"f")}attach(e){lz(this,SF,"f").set(e.id,e);const{annotationElementId:t}=e;t&&lz(this,IF,"f").isDeletedAnnotationElement(t)&&lz(this,IF,"f").removeDeletedAnnotationElement(e)}detach(e){var t;lz(this,SF,"f").delete(e.id),null===(t=lz(this,wF,"f"))||void 0===t||t.removePointerInTextLayer(e.contentDiv),!lz(this,AF,"f")&&e.annotationElementId&&lz(this,IF,"f").addDeletedAnnotationElement(e)}remove(e){this.detach(e),lz(this,IF,"f").removeEditor(e),e.div.remove(),e.isAttachedToDOM=!1,lz(this,MF,"f")||this.addInkEditorIfNeeded(!1)}changeParent(e){var t;e.parent!==this&&(e.parent&&e.annotationElementId&&(lz(this,IF,"f").addDeletedAnnotationElement(e.annotationElementId),UL.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),lz(this,IF,"f").addEditor(e),this.attach(e),!e.isAttachedToDOM){const t=e.render();this.div.append(t),e.isAttachedToDOM=!0}e.fixAndSetPosition(),e.onceAdded(),lz(this,IF,"f").addToAnnotationStorage(e)}}moveEditorInDOM(e){var t;if(!e.isAttachedToDOM)return;const{activeElement:n}=document;e.div.contains(n)&&!lz(this,CF,"f")&&(e._focusEventsAllowed=!1,cz(this,CF,setTimeout((()=>{cz(this,CF,null,"f"),e.div.contains(document.activeElement)?e._focusEventsAllowed=!0:(e.div.addEventListener("focusin",(()=>{e._focusEventsAllowed=!0}),{once:!0,signal:lz(this,IF,"f")._signal}),n.focus())}),0),"f")),e._structTreeParentId=null===(t=lz(this,wF,"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 lz(this,IF,"f").getId()}combinedSignal(e){return lz(this,IF,"f").combinedSignal(e)}canCreateNewEmptyEditor(){var e;return null===(e=lz(this,_F,"a",LF))||void 0===e?void 0:e.canCreateNewEmptyEditor()}pasteEditor(e,t){lz(this,IF,"f").updateToolbar(e),lz(this,IF,"f").updateMode(e);const{offsetX:n,offsetY:i}=lz(this,_F,"m",HF).call(this);const r=this.getNextId();const o=lz(this,_F,"m",BF).call(this,Object.assign({parent:this,id:r,x:n,y:i,uiManager:lz(this,IF,"f"),isCentered:!0},t));o&&this.add(o)}deserialize(e){var t,n;return(null===(n=lz(bF,bF,"f",zF).get(null!==(t=e.annotationType)&&void 0!==t?t:e.annotationEditorType))||void 0===n?void 0:n.deserialize(e,this,lz(this,IF,"f")))||null}createAndAddNewEditor(e,t,n={}){const i=this.getNextId();const r=lz(this,_F,"m",BF).call(this,Object.assign({parent:this,id:i,x:e.offsetX,y:e.offsetY,uiManager:lz(this,IF,"f"),isCentered:t},n));return r&&this.add(r),r}addNewEditor(){this.createAndAddNewEditor(lz(this,_F,"m",HF).call(this),!0)}setSelected(e){lz(this,IF,"f").setSelected(e)}toggleSelected(e){lz(this,IF,"f").toggleSelected(e)}isSelected(e){return lz(this,IF,"f").isSelected(e)}unselect(e){lz(this,IF,"f").unselect(e)}pointerup(e){const{isMac:t}=gI.platform;0!==e.button||e.ctrlKey&&t||e.target===this.div&&lz(this,TF,"f")&&(cz(this,TF,!1,"f"),lz(this,yF,"f")?lz(this,IF,"f").getMode()!==mI.STAMP?this.createAndAddNewEditor(e,!1):lz(this,IF,"f").unselectAll():cz(this,yF,!0,"f"))}pointerdown(e){if(lz(this,IF,"f").getMode()===mI.HIGHLIGHT&&this.enableTextSelection(),lz(this,TF,"f"))return void cz(this,TF,!1,"f");const{isMac:t}=gI.platform;if(0!==e.button||e.ctrlKey&&t)return;if(e.target!==this.div)return;cz(this,TF,!0,"f");const n=lz(this,IF,"f").getActive();cz(this,yF,!n||n.isEmpty(),"f")}findNewParent(e,t,n){const i=lz(this,IF,"f").findParent(t,n);return null!==i&&i!==this&&(i.changeParent(e),!0)}destroy(){var e,t;(null===(e=lz(this,IF,"f").getActive())||void 0===e?void 0:e.parent)===this&&(lz(this,IF,"f").commitOrRemove(),lz(this,IF,"f").setActiveEditor(null)),lz(this,CF,"f")&&(clearTimeout(lz(this,CF,"f")),cz(this,CF,null,"f"));for(const e of lz(this,SF,"f").values())null===(t=lz(this,wF,"f"))||void 0===t||t.removePointerInTextLayer(e.contentDiv),e.setParent(null),e.isAttachedToDOM=!1,e.div.remove();this.div=null,lz(this,SF,"f").clear(),lz(this,IF,"f").removeLayer(this)}render({viewport:e}){this.viewport=e,vI(this.div,e);for(const e of lz(this,IF,"f").getEditors(this.pageIndex))this.add(e),e.rebuild();this.updateMode()}update({viewport:e}){lz(this,IF,"f").commitOrRemove(),lz(this,_F,"m",RF).call(this);const t=this.viewport.rotation;const n=e.rotation;if(this.viewport=e,vI(this.div,e),t!==n)for(const e of lz(this,SF,"f").values())e.rotate(n);this.addInkEditorIfNeeded(!1)}get pageDimensions(){const{pageWidth:e,pageHeight:t}=this.viewport.rawDims;return[e,t]}get scale(){return lz(this,IF,"f").viewParameters.realScale}}var OF,VF,NF,$F,UF;bF=FF,wF=new WeakMap,yF=new WeakMap,kF=new WeakMap,xF=new WeakMap,CF=new WeakMap,SF=new WeakMap,TF=new WeakMap,MF=new WeakMap,AF=new WeakMap,DF=new WeakMap,EF=new WeakMap,IF=new WeakMap,_F=new WeakSet,PF=function(e){lz(this,IF,"f").unselectAll();const{target:t}=e;if(t===lz(this,DF,"f").div||t.classList.contains("endOfContent")&&lz(this,DF,"f").div.contains(t)){const{isMac:t}=gI.platform;if(0!==e.button||e.ctrlKey&&t)return;if(lz(this,IF,"f").showAllEditors("highlight",!0),lz(this,IF,"f").getMode()===mI.NONE)return;lz(this,DF,"f").div.addEventListener("pointerup",(()=>{lz(this,DF,"f").div.classList.remove("free"),this.toggleDrawing(!0)}),{once:!0,signal:lz(this,IF,"f")._signal}),e.preventDefault()}},LF=function(){return lz(bF,bF,"f",zF).get(lz(this,IF,"f").getMode())},BF=function(e){const t=lz(this,_F,"a",LF);return t?new t(e):null},HF=function(){const{x:e,y:t,width:n,height:i}=this.div.getBoundingClientRect();const r=Math.max(0,e);const o=Math.max(0,t);const a=(r+Math.min(window.innerWidth,e+n))/2-e;const s=(o+Math.min(window.innerHeight,t+i))/2-t;const[l,c]=this.viewport.rotation%180==0?[a,s]:[s,a];return{offsetX:l,offsetY:c}},RF=function(){cz(this,MF,!0,"f");for(const e of lz(this,SF,"f").values())e.isEmpty()&&e.remove();cz(this,MF,!1,"f")},FF._initialized=!1,zF={value:new Map([jH,vF].map((e=>[e._editorType,e])))};class WF{constructor(e){this.pdfPage=null,this.annotationEditorLayer=null,this._cancelled=null,this.div=null,this.accessibilityManager=null,OF.set(this,null),VF.set(this,null),NF.set(this,null),$F.set(this,null),UF.set(this,null),this.pdfPage=e.pdfPage,this.accessibilityManager=e.accessibilityManager,this.annotationEditorLayer=null,this.div=null,this._cancelled=!1,cz(this,UF,e.uiManager,"f"),cz(this,OF,e.annotationLayer||null,"f"),cz(this,$F,e.textLayer||null,"f"),cz(this,VF,e.drawLayer||null,"f"),cz(this,NF,e.onAppend||null,"f")}render(e){return sz(this,arguments,void 0,(function*(e,t="display"){var n;if("display"!==t)return;if(this._cancelled)return;const i=e.clone({dontFlip:!0});if(this.div)return this.annotationEditorLayer.update({viewport:i}),void this.show();const r=this.div=document.createElement("div");r.className="k-annotation-editor-layer",r.hidden=!0,r.dir=lz(this,UF,"f").direction,null===(n=lz(this,NF,"f"))||void 0===n||n.call(this,r),this.annotationEditorLayer=new FF({uiManager:lz(this,UF,"f"),div:r,accessibilityManager:this.accessibilityManager,pageIndex:this.pdfPage.pageNumber-1,viewport:i,annotationLayer:lz(this,OF,"f"),textLayer:lz(this,$F,"f"),drawLayer:lz(this,VF,"f")});const o={viewport:i,div:r,annotations:null,intent:t};this.annotationEditorLayer.render(o),this.show()}))}cancel(){var e;this._cancelled=!0,this.div&&(null===(e=this.annotationEditorLayer)||void 0===e||e.destroy())}hide(){this.div&&(this.div.hidden=!0)}show(){this.div&&!this.annotationEditorLayer.isInvisible&&(this.div.hidden=!1)}destroy(){var e;null===(e=this.annotationEditorLayer)||void 0===e||e.destroy()}}var jF,qF,GF,KF,YF,QF,XF,ZF,JF,eO,tO,nO,iO,rO,oO,aO,sO;OF=new WeakMap,VF=new WeakMap,NF=new WeakMap,$F=new WeakMap,UF=new WeakMap;const lO={annotationEditorUIManager:null,annotationStorage:null,downloadManager:null,enableScripting:!1,fieldObjectsPromise:null,findController:null,hasJSActionsPromise:null,get linkService(){return null}};const cO=new Map([["canvasWrapper",0],["textLayer",1],["annotationLayer",2],["annotationEditorLayer",3],["xfaLayer",3]]);class dO extends $I{constructor(e,t){super(e,t),jF.add(this),this.eventBus=null,this.zoomLayer=null,this.div=null,this.viewport=null,this.id=1,this._accessibilityManager=null,this._annotationCanvasMap=new Map,this.renderTask=null,this.pdfPageRotate=null,this.rotation=null,this.scale=null,this.pdfViewer=null,this.xfaLayer=null,qF.set(this,SI.ENABLE),GF.set(this,!1),KF.set(this,null),YF.set(this,null),QF.set(this,$P),XF.set(this,qP),ZF.set(this,new WeakMap),JF.set(this,[null,null,null,null]),this.textLayer=null,this.textLayerBuilder=null,this.textAccessibilityManager=null,this.annotationLayer=null,this.drawLayer=null,this.annotationEditorLayer=null,this.options={},this.state={},this.pdfPage=null,this.extendOptions(t),this.div=e,this.viewport=this.options.viewport,this.id=this.options.id||this.options.number||1,cz(this,KF,t.layerProperties||lO,"f"),this.eventBus=t.eventBus,this.initScale(),this.pdfViewer=t.pdfViewer,this.pdfPage=t.pdfPage,cz(this,qF,this.pdfViewer.getAnnotationMode(),"f"),this.resetState()}destroy(){var e,t,n,i,r;this.destroyTextLayer(),this.canvas&&(this.canvas.width=0,this.canvas.height=0,this.canvas.remove(),this.canvas=null),this.canvasForPrint&&(this.canvasForPrint.width=0,this.canvasForPrint.height=0,this.canvasForPrint.remove(),this.canvasForPrint=null),null===(e=this.drawLayer)||void 0===e||e.destroy(),null===(t=this.annotationLayer)||void 0===t||t.destroy(),null===(n=this.annotationEditorLayer)||void 0===n||n.destroy(),null===(i=this.div)||void 0===i||i.remove(),this.div=null,this.pdfViewer=null,null===(r=this.pdfPage)||void 0===r||r.cleanup(),this.pdfPage=null}get isEditing(){return lz(this,GF,"f")}get rawWidth(){var e,t;return null===(t=null===(e=this.viewport)||void 0===e?void 0:e.rawDims)||void 0===t?void 0:t.pageWidth}get rawHeight(){var e,t;return null===(t=null===(e=this.viewport)||void 0===e?void 0:e.rawDims)||void 0===t?void 0:t.pageWidth}setState(e){this.state=LI(this.state||{},e)}resetState(){this.setState({})}initScale(){this.scale=this.options.zoomLevel||this.options.scale||1}createPromise(){return NI()}getViewport(e={scale:1}){return this.pdfPage?this.pdfPage.getViewport(e):{width:0,height:0}}destroyTextLayer(){var e,t;null===(e=this.textLayer)||void 0===e||e.cancel(),null===(t=this.textLayer)||void 0===t||t.destroy(),this.removeTextLayer(),this.textLayer=null}removeTextLayer(){var e,t;this.textLayer&&(null===(e=this.textLayer.div)||void 0===e?void 0:e.parentNode)&&(null===(t=this.textLayer.div)||void 0===t||t.parentNode.removeChild(this.textLayer.div))}getPrintContentAsync(){const e=this.canvasForPrint;const t=this.createPromise();const n=new Image;const i=this.viewport.rawDims;const r=Math.floor(i.pageHeight);const o=Math.floor(i.pageWidth);return n.src=e.toDataURL(),n.width=o,n.height=r,n.onload=()=>{t.resolve(n)},t}loadForPrintAsync({zoomLevel:e=1.25,force:t=!1}){const n=this;const i=this.createPromise();const r=this.pdfViewer.state.zoomLevel;if(this.pdfPage&&r===e&&!t)return i.resolve(n);if(this.pdfPage&&r&&(r!==e||t))return this.renderForPrintAsync().then((()=>{this.setState({isPrintingInProgress:!1}),i.resolve(n)})),i;const o=Math.max(0,this.pdfPage._pageIndex);return this.pdfViewer.state.pdfDocument.getPage(o+1).then((()=>{this.renderForPrintAsync().then((()=>{this.setState({isPrintingInProgress:!1}),i.resolve(n)}))})),i}renderForPrintAsync(){var e,t;const n=this.pdfViewer.getPrintUnits();const{canvasContext:i,canvas:r}=this.pdfViewer.createPageElements({pdfPage:this.pdfPage,zoom:1,printUnits:n});this.canvasForPrint=r,this.setState({isPrintingInProgress:!0});const o=this.pdfViewer.state.pdfDocument.getOptionalContentConfig({intent:"print"});const a={canvasContext:i,transform:[n,0,0,n,0,0],viewport:this.pdfPage.getViewport({scale:1,rotation:this.viewport.rotation}),intent:"print",annotationMode:SI.ENABLE_STORAGE,optionalContentConfigPromise:o,printAnnotationStorage:null===(t=null===(e=this.pdfViewer)||void 0===e?void 0:e.annotationStorage)||void 0===t?void 0:t.print};return this.pdfPage.render(a).promise}isBlank(){return this.element&&this.element.getAttribute("data-blank")}setBlank(e){this.element&&(e?this.element.setAttribute("data-blank",(!0).toString()):this.element.removeAttribute("data-blank"))}get renderingState(){return lz(this,QF,"f")}setPdfPage(e){this.pdfPage=e,this.pdfPageRotate=e.rotate;const t=(this.rotation+this.pdfPageRotate)%360;this.viewport=e.getViewport({scale:this.scale*bI.PDF_TO_CSS_UNITS,rotation:t}),lz(this,jF,"m",tO).call(this),this.reset()}hasEditableAnnotations(){var e;return!!(null===(e=this.annotationLayer)||void 0===e?void 0:e.hasEditableAnnotations())}_resetZoomLayer(e=!1){if(!this.zoomLayer)return;const t=this.zoomLayer.firstChild;lz(this,ZF,"f").delete(t),t.width=0,t.height=0,e&&this.zoomLayer.remove(),this.zoomLayer=null}reset({keepZoomLayer:e=!1,keepAnnotationLayer:t=!1,keepAnnotationEditorLayer:n=!1,keepXfaLayer:i=!1,keepTextLayer:r=!1}={}){var o,a,s,l,c,d,h,u;const p=this.div;if(!p)return;const f=p.childNodes,m=e&&this.zoomLayer||null,g=t&&(null===(o=this.annotationLayer)||void 0===o?void 0:o.div)||null,v=n&&(null===(a=this.annotationEditorLayer)||void 0===a?void 0:a.div)||null,_=i&&(null===(s=this.xfaLayer)||void 0===s?void 0:s.div)||null,b=r&&(null===(l=this.textLayer)||void 0===l?void 0:l.div)||null;for(let e=f.length-1;e>=0;e--){const t=f[e];switch(t){case m:case g:case v:case _:case b:continue}t.remove();const n=lz(this,JF,"f").indexOf(t);n>=0&&(lz(this,JF,"f")[n]=null)}p.removeAttribute("data-loaded"),g&&(null===(c=this.annotationLayer)||void 0===c||c.hide()),v&&(null===(d=this.annotationEditorLayer)||void 0===d||d.hide()),_&&(null===(h=this.xfaLayer)||void 0===h||h.hide()),b&&(null===(u=this.textLayer)||void 0===u||u.hide()),m||(this.canvas&&(lz(this,ZF,"f").delete(this.canvas),this.canvas.width=0,this.canvas.height=0,delete this.canvas),this._resetZoomLayer())}toggleEditingMode(e){this.hasEditableAnnotations()&&(cz(this,GF,e,"f"),this.reset({keepZoomLayer:!0,keepAnnotationLayer:!0,keepAnnotationEditorLayer:!0,keepXfaLayer:!0,keepTextLayer:!0}))}draw(){return sz(this,void 0,void 0,(function*(){const{canvasContext:e,canvas:t,canvasWrapper:n,viewport:i,pageElement:r,styles:o}=this.pdfViewer.createPageElements({pdfPage:this.pdfPage,zoom:this.pdfViewer.options.zoomLevel||1});this.isBlank()?(this.element.replaceWith(r),this.element=this.div=r,this.canvas=t):(this.element=this.div=this.element||this.div||r,this.canvas=this.canvas||t),this.options.styles=o,n.appendChild(t),this.element.appendChild(n),lz(this,jF,"m",eO).call(this,n,"canvasWrapper");const{div:a,pdfPage:s}=this;if(this.textLayer||lz(this,XF,"f")===jP||s.isPureXfa||(this._accessibilityManager||(this._accessibilityManager=new rL),this.textLayer=new fL({styles:this.options.styles,pdfPage:s,accessibilityManager:this._accessibilityManager,onAppend:e=>{lz(this,jF,"m",eO).call(this,e,"textLayer")}})),!this.annotationLayer&&lz(this,qF,"f")!==SI.DISABLE){const{annotationStorage:e,annotationEditorUIManager:t,linkService:n}=lz(this,KF,"f");this._annotationCanvasMap||(this._annotationCanvasMap=new Map),this.annotationLayer=new fH({pdfPage:s,eventBus:this.eventBus||this.pdfViewer.eventBus,annotationStorage:e,renderForms:lz(this,qF,"f")===SI.ENABLE_FORMS,linkService:n,annotationCanvasMap:this._annotationCanvasMap,accessibilityManager:this._accessibilityManager,annotationEditorUIManager:t,onAppend:e=>{lz(this,jF,"m",eO).call(this,e,"annotationLayer")}})}lz(this,ZF,"f").set(t,i);const l={canvasContext:e,viewport:i,annotationMode:lz(this,qF,"f"),annotationCanvasMap:this._annotationCanvasMap,isEditing:lz(this,GF,"f")};const c=this.renderTask=s.render(l);const d=c.promise.then((()=>sz(this,void 0,void 0,(function*(){var e;yield lz(this,jF,"m",sO).call(this,c),yield lz(this,jF,"m",aO).call(this),this.annotationLayer&&(yield lz(this,jF,"m",iO).call(this));const{annotationEditorUIManager:t}=lz(this,KF,"f");t&&(this.drawLayer||(this.drawLayer=new TH({pageIndex:this.id})),yield lz(this,jF,"m",oO).call(this),this.drawLayer.setParent(n),this.annotationEditorLayer||(this.annotationEditorLayer=new WF({uiManager:t,pdfPage:s,accessibilityManager:this._accessibilityManager,annotationLayer:null===(e=this.annotationLayer)||void 0===e?void 0:e.annotationLayer,textLayer:this.textLayer,drawLayer:this.drawLayer.getDrawLayer(),onAppend:e=>{lz(this,jF,"m",eO).call(this,e,"annotationEditorLayer")}})),lz(this,jF,"m",rO).call(this))}))),(e=>{}));return s.isPureXfa,a.setAttribute("data-loaded",!0),this.eventBus.dispatch("pagerender",{source:this,pageNumber:this.id}),d}))}}var hO,uO;qF=new WeakMap,GF=new WeakMap,KF=new WeakMap,YF=new WeakMap,QF=new WeakMap,XF=new WeakMap,ZF=new WeakMap,JF=new WeakMap,jF=new WeakSet,eO=function(e,t){const n=cO.get(t);const i=lz(this,JF,"f")[n];if(lz(this,JF,"f")[n]=e,i)i.replaceWith(e);else{for(let t=n-1;t>=0;t--){const n=lz(this,JF,"f")[t];if(n)return void n.after(e)}this.div.prepend(e)}},tO=function(){const{viewport:e}=this;if(this.pdfPage){if(lz(this,YF,"f")===e.rotation)return;cz(this,YF,e.rotation,"f")}this.div&&e&&vI(this.div,e,!0,!1)},nO=function(e,t){this.eventBus.dispatch(e,{source:this,pageNumber:this.id,error:t})},iO=function(){return sz(this,void 0,void 0,(function*(){let e=null;try{yield this.annotationLayer.render(this.viewport,"display")}catch(t){console.error(`#renderAnnotationLayer: "${t}".`),e=t}finally{lz(this,jF,"m",nO).call(this,"annotationlayerrendered",e)}}))},rO=function(){return sz(this,void 0,void 0,(function*(){let e=null;try{yield this.annotationEditorLayer.render(this.viewport)}catch(t){e=t}finally{lz(this,jF,"m",nO).call(this,"annotationeditorlayerrendered",e)}}))},oO=function(){return sz(this,void 0,void 0,(function*(){try{yield this.drawLayer.render("display")}catch(e){}}))},aO=function(){return sz(this,void 0,void 0,(function*(){if(!this.textLayer)return;let e=null;try{yield this.textLayer.render(this.viewport)}catch(t){if(t instanceof TI)return;e=t}lz(this,jF,"m",nO).call(this,"textlayerrendered",e)}))},sO=function(e){return sz(this,void 0,void 0,(function*(){e===this.renderTask&&(this.renderTask=null),this._resetZoomLayer(!0),this.eventBus.dispatch("pagerendered",{source:this,pageNumber:this.id,cssTransform:!1,timestamp:performance.now(),error:"page render error"})}))};const pO=0,fO=1,mO=2,gO=3,vO=4;class _O{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 sz(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?mO: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 pO:break;case fO:o="_self";break;case mO:o="_blank";break;case gO:o="_parent";break;case vO: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;const 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(",");const t=e[0];const 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||lz(hO,hO,"m",uO).call(hO,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 sz(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 bO;var wO,yO,kO,xO,CO,SO,TO,MO;hO=_O,uO=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"}(bO||(bO={}));const AO="error";const DO="zoomStart";const EO="zoomEnd";const IO="pageRendered";const zO="pagesLoad";const PO="printEnd";const LO="scroll";const BO="annotationEditorToolBarShow";const HO="annotationEditorToolBarHide";const RO=1.25;const FO=1e3/60;class OO extends $I{constructor(e,t){super(e,t),wO.add(this),this.options={pdfServiceType:"pdfjs",pdfjsSetHiddenCanvasStyles:!0,fileData:[],page:1,fileDescriptor:null,downloadFileName:"Document",minZoom:.5,maxZoom:4,zoomRate:.25,zoomLevel:RO,zoomBeforePrint:!1,zoomLevelForPrint:3,renderForms:!1,searchMatchScrollLeftOffset:0,searchMatchScrollTopOffset:-64,pageChangeScrollThreshold:.85,pageWheelThrottleDelay:200,printResolution:100,renderScale:3,loadOnDemand:!1,loadOnDemandPageSize:2,messages:{freeTextEditorPlaceholder:"Start typing",errorMessages:{parseError:"PDF file fails to process.",notFound:"File is not found.",popupBlocked:"Popup is blocked."}},annotations:{highlight:{color:"#ffff00"}},elementSelectors:{pageSelector:"k-page:not(.k-blank-page)",anyPageSelector:"k-page",pagesContainerClass:"k-pdf-viewer-pages",pageCanvasWrapper:"k-canvas-wrapper",documentContainerClass:"k-pdf-viewer-canvas",textLayerClass:"k-text-layer",searchHighlightClass:"k-search-highlight",searchHighlightMarkClass:"k-search-highlight-mark",charClass:"k-text-char",textElementSelector:"span[role='presentation']",renderedPageSelector:"k-page[data-page-number]",enabledTextSelectionClass:"k-enable-text-select",enabledPanningClass:"k-enable-panning"},events:{[IO]:FI,[zO]:FI,[PO]:FI,[DO]:FI,[EO]:FI,[AO]:FI,[LO]:FI,[BO]:FI,[HO]:FI}},this.interactionMode=bO.TextSelection,this.printContainer=null,this._scrollMode=KP,this.isInPresentationMode=!1,this._currentPageNumber=1,this.linkService=null,this.annotationStorage=null,this._annotationStorageModified=!1,this._hasAnnotationEditors=!1,yO.set(this,mI.NONE),this.annotationEditorUIManager=null,kO.set(this,null),xO.set(this,fz),CO.set(this,null),SO.set(this,null),this.state={},this.pdfDocument=null,this.pages=[],this.triggerError=e=>{this.trigger(AO,{error:e})},this.triggerPrintEnd=e=>{this.trigger(PO,e)},this.onPagesLoad=e=>{this.state.pdfDocument=e.pdfDoc,this.state.pdfPages=e.pdfPages,this.clearSearch(),this.initSearchService(),this.enableDocumentScrollEventsTracking(),this.triggerPagesLoad(e)},this.onDocumentScrollerScroll=e=>{const t=this.getCurrentPageIndex();const n=this.pages;const i=n[t];const r=n[t+1];const o=n[t-1];i&&i.isBlank()&&this.drawPageAsync({pageIndex:t}),r&&r.isBlank()&&this.drawPageAsync({pageIndex:t+1}),o&&o.isBlank()&&this.drawPageAsync({pageIndex:t-1}),this.tryTriggerScroll(e)},this.tryTriggerScroll=e=>{let t=!1;const n=this.getCurrentPageIndex()+1;n!==this.state.activePageNumber&&n>=1&&n<=this.state.pdfDocument.numPages&&(t=!0,this.state.activePageNumber=n),this.shouldPreventScroll?this.shouldPreventScroll=!1:this.trigger(LO,{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop,pageNumber:this.state.activePageNumber,isPageChanged:t})},this.printDocumentAsync=()=>{this.initPrintContainer();const e=this.getPagesPrintContentAsync(this.printContainer);const t=NI();return Promise.all(e).then((()=>{setTimeout((()=>{this.openPrintDialog(),t.resolve()}),FO)})),t},this.onDocumentWheel=e=>{if(!e.ctrlKey&&!e.metaKey)return;e.preventDefault(),e.stopPropagation();const t=(e=>{let t=0;return e.wheelDelta?t=-e.wheelDelta/120:e.detail&&(t=e.detail/3),t=t>0?Math.ceil(t):Math.floor(t),t})(e);const n=t<0?1:-1;const i=this.state.zoomLevel+n*this.options.zoomRate;this.triggerZoomStart({zoomLevel:i}),this.zoom({zoomLevel:i}),this.triggerZoomEnd({zoomLevel:i})},this.extendOptions(t),this.throwIfInvalidOptions(),this.wrapper=this.element,this.initEventBus(),cz(this,CO,new AbortController,"f"),this.options.renderForms&&cz(this,xO,mz,"f"),this.resetState(),this.bindEvents(),this.initLinkService(),this.initDocumentContainer(),this.loadFile(this.options.fileDescriptor||{data:this.options.fileData,page:this.options.page})}destroy(){this.destroyEventBus(),this.unbindEvents(),this.clearDocument(),this.destroySearchService(),this.destroyAnnotationEditorUIManager(),this.destroyDocumentScroller()}throwIfInvalidOptions(){if(this.options.minZoom>this.options.maxZoom)throw new Error("The min zoom should be greater than max zoom")}set annotationEditorParams({type:e,value:t}){this.annotationEditorUIManager&&this.annotationEditorUIManager.updateParams(e,t)}get annotationEditorMode(){return this.annotationEditorUIManager?lz(this,yO,"f"):mI.DISABLE}set annotationEditorMode({mode:e,editId:t=null,isFromKeyboard:n=!1}){if(this.annotationEditorUIManager,lz(this,yO,"f")===e)return;if(!this.isValidAnnotationEditorMode(e))return;if(!this.pdfDocument)return;mI.STAMP;const{eventBus:i}=this;const r=()=>{this.cleanupSwitchAnnotationEditorMode(),cz(this,yO,e,"f"),this.annotationEditorUIManager.updateMode(e,t,n),i.dispatch("annotationeditormodechanged",{source:this,mode:e})};if(e===mI.NONE||lz(this,yO,"f")===mI.NONE){const t=e!==mI.NONE;t||this.pdfDocument.annotationStorage.resetModifiedIds();for(const e of this.pages)e.toggleEditingMode(t);const n=lz(this,wO,"m",TO).call(this);if(t&&n){this.cleanupSwitchAnnotationEditorMode(),cz(this,SO,(({pageNumber:e})=>{n.delete(e),0===n.size&&cz(this,kO,setTimeout(r,0),"f")}),"f");const{signal:e}=lz(this,CO,"f");i._on("pagerendered",lz(this,SO,"f"),{signal:e})}}r()}getAnnotationMode(){return lz(this,xO,"f")}getPrintUnits(){return this.options.printResolution/bI.PDF}extendOptions(e){this.options=LI(this.options,e)}setOptions(e){this.options=e}bindEvents(){this.bindPagesWheel()}bindPagesWheel(){const e=this.getDocumentContainer();e&&(this.options.pageWheelThrottleDelay>0?this.throttledPagesWheel=UI(this.onDocumentWheel,this.options.pageWheelThrottleDelay):this.throttledPagesWheel=this.onDocumentWheel,e.addEventListener("wheel",this.throttledPagesWheel))}unbindEvents(){this.unbindPagesWheel()}unbindPagesWheel(){const e=this.getDocumentContainer();e&&(this.throttledPagesWheel&&this.throttledPagesWheel.cancel&&this.throttledPagesWheel.cancel(),e.removeEventListener("wheel",this.throttledPagesWheel))}setState(e){this.state=LI(this.state||{},e)}resetState(){this.setState({activePageNumber:1,visiblePagesCount:1,pagePromises:[],downloadFilePromise:null,pdfDocument:null,zoomLevel:this.options.zoomLevel,zoomLevelType:this.options.zoomLevelType,zoomLevelBeforePrint:null})}initEventBus(){this.eventBus=new NP}destroyEventBus(){}initLinkService(){var e;this.linkService=new _O({eventBus:this.eventBus,externalLinkTarget:mO,externalLinkRel:"noopener noreferrer nofollow",ignoreDestinationZoom:!1}),null===(e=this.linkService)||void 0===e||e.setViewer(this)}initAnnotationEditorUIManager(){this.annotationEditorUIManager=new OP({container:this.getDocumentContainer(),viewer:this.element,pdfViewer:this,pdfDocument:this.state.pdfDocument,eventBus:this.eventBus}),this.setAnnotationEditorUIManagerScale()}setAnnotationEditorUIManagerScale(){var e;null===(e=this.annotationEditorUIManager)||void 0===e||e.onScaleChanging({scale:this.options.zoomLevel})}destroyAnnotationEditorUIManager(){var e;null===(e=this.annotationEditorUIManager)||void 0===e||e.destroy(),this.annotationEditorUIManager=null}bindEventBusAnnotationsEvents(){const e=this.eventBus=this.eventBus||new NP;e._on("switchannotationeditorparams",(e=>{this.annotationEditorParams=e})),e._on("switchannotationeditormode",(t=>{this.annotationEditorUIManager.updateParams(t.type,t.value);const{mode:n,editId:i,isFromKeyboard:r}=t;this.annotationEditorUIManager.annotationEditorMode=t,this.annotationEditorUIManager.updateMode(n,i,r),e.dispatch("annotationeditormodechanged",{source:this,mode:n})})),e._on("kendoAnnotationEditorToolBarShow",(e=>{var t;if(!e)return;const n=this.annotationEditorUIManager.getMode();n!==mI.HIGHLIGHT&&n!==mI.FREETEXT||(n===mI.HIGHLIGHT&&this.addHighlightAnnotation(),this.triggerAnnotationEditorToolBarShow(Object.assign(Object.assign({},e),{annotationEditorMode:n===mI.HIGHLIGHT?"highlight":"freeText",anchor:e.anchor||(null===(t=this.annotationEditorUIManager.firstSelectedEditor)||void 0===t?void 0:t.div)})))})),e._on("kendoAnnotationEditorToolBarHide",(e=>{if(!e)return;const t=this.annotationEditorUIManager.getMode();t!==mI.HIGHLIGHT&&t!==mI.FREETEXT||this.triggerAnnotationEditorToolBarHide(Object.assign(Object.assign({},e),{annotationEditorMode:t===mI.HIGHLIGHT?"highlight":"freeText"}))})),e._on("showannotationeditorui",(t=>{if(t.mode===mI.HIGHLIGHT)e.dispatch("switchannotationeditormode",{source:this,mode:mI.HIGHLIGHT,isFromKeyboard:!1})}))}unbindEventBusAnnotationsEvents(){}loadFile(e){const t=e.data;const n={data:null,url:"",arrayBuffer:null,typedArray:null};if(t&&(t.buffer instanceof ArrayBuffer||t instanceof ArrayBuffer)?n.arrayBuffer=t.buffer||t:BI(t)&&""!==t?(n.data=t,n.url=null):BI(e.url)&&""!==e.url?(n.data=null,n.url=e.url):e.typedArray&&(n.typedArray=e.typedArray),e.data||e.url||e.arrayBuffer||e.typedArray){const e=Object.assign({dom:this.getPagesContainer(),zoom:this.options.zoomLevel},n);this.disableDocumentScrollEventsTracking(),this.clearDocument(),this.initEventBus(),cz(this,CO,new AbortController,"f"),this.bindEvents(),this.initLinkService(),this.initDocumentContainer(),this.loadDocument(e),this.setScaleFactor(this.options.zoomLevel)}}loadDocument(e){const t=this.getDocumentParameters(e);const{zoom:n}=e;this.clearDocumentState(),CI(t).promise.then((e=>{var t;null===(t=this.linkService)||void 0===t||t.setDocument(e),this.initDocumentAnnotationStorage(e),this.initAnnotationEditorUIManager(),this.bindEventBusAnnotationsEvents();const n=[];for(let t=1;t<=e.numPages;t++)n.push(e.getPage(t));return{pagesPromises:n,pdfDoc:e}})).then((({pagesPromises:e,pdfDoc:t})=>(this.state.pagesPromises=e,this.destroyPageComponents(),this.drawPagesFromPromisesAsync(e).then((e=>{this.setHiddenCanvasStyles(),this.onPagesLoad({pdfPages:e,pdfDoc:t,zoom:n})})).catch((e=>{this.triggerError(e)}))))).catch((e=>{this.triggerError(e)})).finally((()=>{var e;null===(e=this.linkService)||void 0===e||e.setDocument(this.pdfDocument)}))}initDocumentAnnotationStorage(e){this.state.pdfDocument=e,this.pdfDocument=e,this.annotationStorage=new nB,Object.defineProperty(Object.getPrototypeOf(this.pdfDocument._transport),"annotationStorage",{get:()=>{var e;return this.state.isPrintingInProgress?null===(e=this.annotationStorage)||void 0===e?void 0:e.print:this.annotationStorage},set:e=>{this.annotationStorage=e},configurable:!0}),this._initializeAnnotationStorageCallbacks(e)}_initializeAnnotationStorageCallbacks(e){if(e!==this.pdfDocument)return;const{annotationStorage:t}=e;t.onSetModified=()=>{this._annotationStorageModified=!0},t.onResetModified=()=>{delete this._annotationStorageModified},t.onAnnotationEditor=e=>{this._hasAnnotationEditors=!!e}}drawPagesFromPromisesAsync(e){return Promise.all(e).then((e=>sz(this,void 0,void 0,(function*(){const t=yield Promise.all(this.drawPagesAsync(e));return this.appendPages(t),e}))))}drawPagesAsync(e){e=e||this.state.pdfPages;if((this.pages||[]).length>0)for(let e=0;e<this.pages.length;e++){const t=this.pages[e].getViewport({scale:this.state.zoomLevel});this.pages[e].viewport=t}else this.initPageComponents(e);const t=[];return e.map(((e,n)=>sz(this,void 0,void 0,(function*(){const i=this.pages[n];if(this.options.loadOnDemand&&n>=this.options.loadOnDemandPageSize&&!i.element){const n=this.createBlankPageElements({pdfPage:e,zoom:this.state.zoomLevel});i&&!i.element&&(i.element=n.pageElement,i.setBlank(!0));const r=NI();t.push(r),r.then((e=>e)),r.resolve(i.element)}else if(this.options.loadOnDemand&&i.isBlank()){const e=NI();t.push(e),e.then((e=>e)),e.resolve(i.element)}else{const e=this.drawPageAsync({pageIndex:n});t.push(e),e.then((e=>e))}})))),t}createBlankPageElements({pdfPage:e,zoom:t}){const n=this.createPageElements({pdfPage:e,zoom:t});return n.canvasWrapper.appendChild(n.canvas),n.pageElement.appendChild(n.canvasWrapper),n}getDocumentParameters(e){let t={verbosity:0,isEvalSupported:!0};return"string"==typeof e.data&&""!==e.data?t.data=nz(e.data):"string"==typeof e.url&&""!==e.url?t.url=e.url:e.arrayBuffer instanceof ArrayBuffer?t=e.arrayBuffer:e.typedArray&&(t=e.typedArray),t}appendPages(e){e.forEach((e=>this.appendPage(e)))}appendPage(e,t=null){const n=this.getPagesContainer();RI(t)?null==n||n.insertBefore(e,n.children[t]):null==n||n.appendChild(e)}drawPageAsync({pageIndex:e=0}){var t;const n=uz(e,0,Math.max(0,this.state.pdfDocument.numPages-1));return null===(t=this.pages[n])||void 0===t?void 0:t.draw().then((()=>(this.triggerPageRendered({page:this.pages[n]}),this.pages[n].element)))}createPageElements({pdfPage:e=null,zoom:t=1,printUnits:n=null}){if(t<=0)return;let i=tz(this.options.renderScale);n&&(i=t||i);const r=null==e?void 0:e.getViewport({scale:i});const{adjustedWidth:o,adjustedHeight:a,adjustRatio:s}=az(r.width,r.height);const l={width:`round(var(--scale-factor) * ${r.width/i}px, 1px)`,height:`round(var(--scale-factor) * ${r.height/i}px, 1px)`};const c=iz("div","k-page",l);const d=iz("canvas","",{width:"100%",height:"100%"});d.height=a,d.width=o,n&&(d.width=Math.floor(d.width*(n||1)),d.height=Math.floor(d.height*(n||1)));const h=d.getContext("2d");const u=OI(`\n <div class="${this.options.elementSelectors.pageCanvasWrapper}"></div>\n `);const p=s*i;return r.width=o,r.height=a,r.scale=p,{canvasContext:h,canvasWrapper:u,canvas:d,viewport:r,scaleNum:i,pageElement:c,styles:l}}triggerPageRendered(e){this.trigger(IO,e)}triggerPagesLoad(e){this.trigger(zO,e)}triggerZoomStart(e){this.trigger(DO,e)}triggerZoomEnd(e){this.trigger(EO,e)}triggerDownload(e){return this.trigger("download",e)}triggerAnnotationEditorToolBarShow(e){this.trigger(BO,e)}triggerAnnotationEditorToolBarHide(e){this.trigger(HO,e)}clearDocument(){this.destroyEventBus(),this.unbindEvents(),this.destroySearchService(),this.destroyAnnotationEditorUIManager(),this.clearDocumentState()}clearDocumentState(){var e;this.clearPagesState(),this.state.pdfDocument=null,this.state.pdfPages=[],null===(e=this.linkService)||void 0===e||e.setDocument(null)}clearPagesState(){this.pages.forEach((e=>e.destroy())),this.clearPagesElements(),this.pages=[]}initPageComponents(e){const t=this.options.zoomLevel;const n=e[0].getViewport({scale:t*bI.PDF_TO_CSS_UNITS});for(let i=1;i<=e.length;i++){const r=i-1;const o=new dO(null,{pdfViewer:this,container:this.element,eventBus:this.eventBus,id:i,scale:t,viewport:n,defaultViewport:n,textLayerMode:qP,annotationMode:this.getAnnotationMode(),layerProperties:this._layerProperties});this.pages.push(o),this.pages[r].setPdfPage(e[r])}}destroyPageComponents(){this.pages.forEach((e=>e.destroy())),this.pages=[]}clearPagesElements(){const e=this.getDocumentContainer();const t=this.getPagesContainer();if(!e||!t||!this.hasDocument())return;this.getPagesElements().forEach((e=>{t.removeChild(e)}))}initDocumentContainer(){this.documentContainer||(this.documentContainer=this.getDocumentContainer(),this.initDocumentScroller(this.documentContainer))}initDocumentScroller(e){!this.documentScroller&&e&&(this.documentScroller=this.createDocumentScroller(e,{filter:VI(this.options.elementSelectors.pageSelector),events:{[LO]:this.onDocumentScrollerScroll}}))}createDocumentScroller(e,t){return new qI(e,t)}destroyDocumentScroller(){this.documentScroller&&(this.documentScroller.destroy(),this.documentScroller=null)}enableDocumentScrollEventsTracking(){var e;null===(e=this.documentScroller)||void 0===e||e.enableScrollEventsTracking()}disableDocumentScrollEventsTracking(){var e;null===(e=this.documentScroller)||void 0===e||e.disableScrollEventsTracking()}getCurrentPageIndex(){return oz(this.element)||0}downloadFile({fileName:e,saveOptions:t={}}){this.downloadDocument({options:{pdf:this.state.pdfDocument},fileName:e||this.options.downloadFileName,saveOptions:t})}downloadDocument({options:e,fileName:t="Document",saveOptions:n={}}){if(e.pdf){let i=e.pdf.getData.bind(e.pdf);let r={};let o={};e.pdf.annotationStorage.size>0&&(i=e.pdf.saveDocument.bind(e.pdf),r={},o=e.pdf.annotationStorage.getAll(),Object.keys(o).forEach((e=>{var t;"function"==typeof(null===(t=o[e])||void 0===t?void 0:t.toJSON)?r[e]=o[e].toJSON():r[e]=o[e]})),Object.keys(o).forEach((t=>{e.pdf.annotationStorage.remove(t)})),Object.keys(r).forEach((t=>{e.pdf.annotationStorage.setValue(t,r[t])}))),i().then((e=>new Blob([e],{type:"application/pdf"}))).then((e=>{this.triggerDownload({blob:e,fileName:t,saveOptions:n})||this.saveFile(e,t,n)})).catch((e=>{this.triggerError(e)})).finally((()=>{var t;if((null===(t=e.pdf)||void 0===t?void 0:t.annotationStorage.size)<=0)return;const n=e.pdf.annotationStorage.getAll();Object.keys(n).forEach((t=>{e.pdf.annotationStorage.remove(t)})),Object.keys(o).forEach((t=>{e.pdf.annotationStorage.setValue(t,o[t])}))}))}}saveFile(e,t,n){try{lI(e,t,n)}catch(e){return!1}return!0}hasDocument(){return RI(this.state.pdfDocument)}zoom(e){e.zoomLevel=this.calculateZoomLevel({zoomLevel:e.zoomLevel,zoomLevelType:e.zoomLevelType,currentZoom:this.options.zoomLevel}),this.options.zoomLevel=e.zoomLevel,this.state.zoomLevel=e.zoomLevel,this.eventBus.dispatch("scalechanging",{source:this,scale:this.options.zoomLevel}),this.reloadFile(this.state.pdfDocument)}calculateZoomLevel({zoomLevel:e,zoomLevelType:t,currentZoom:n}){const i=this.getDocumentContainer();const r=i.querySelector(VI(this.options.elementSelectors.anyPageSelector));let o=uz(e||RO,this.options.minZoom,this.options.maxZoom);if(!RI(r))return o;const a=r.offsetWidth,s=r.offsetHeight;return"ActualWidth"===t||"actualWidth"===t?o=1:"FitToWidth"===t||"fitToWidth"===t?o=i.offsetWidth/(a/n):"FitToPage"!==t&&"fitToPage"!==t||(o=i.offsetHeight/(s/n)),o}reloadFile(e){const t=[];for(let n=1;n<=e.numPages;n++)t.push(e.getPage(n));this.disableDocumentScrollEventsTracking(),this.drawPagesFromPromisesAsync(t).then((t=>{this.setHiddenCanvasStyles(),this.onPagesLoad({pdfPages:t,pdfDoc:e})})).catch((e=>{this.triggerError(e)})),this.setScaleFactor(this.state.zoomLevel)}setHiddenCanvasStyles(){if(!this.options.pdfjsSetHiddenCanvasStyles)return;const e=new CSSStyleSheet;e.replaceSync(".hiddenCanvasElement {\n position: absolute;\n top: 0;\n left: 0;\n width: 0;\n height: 0;\n display: none;\n }"),this.getPagesContainer().ownerDocument.adoptedStyleSheets=[e]}printFile(){this.hasDocument()&&(this.setState({isPrintingInProgress:!0}),this.options.zoomBeforePrint?(this.cacheZoomLevelBeforePrint(),this.loadDocumentForPrintAsync({zoomLevel:this.options.zoomLevelBeforePrint,force:!0}).then((()=>{this.printDocumentAsync().then((()=>{this.trigger(PO)}))})).catch(this.triggerError).finally((()=>{this.setState({isPrintingInProgress:!1}),this.restoreZoomLevelBeforePrint()}))):this.loadDocumentForPrintAsync({zoomLevel:this.state.zoomLevel,force:!0}).then((()=>{this.printDocumentAsync().then((()=>{this.trigger(PO)}))})).catch(this.triggerError).finally((()=>{this.setState({isPrintingInProgress:!1})})))}loadDocumentForPrintAsync({zoomLevel:e=1.25,force:t=!1}){const n=this.pages;const i=[];const r=NI();for(let r=0;r<n.length;r++){const o=n[r].loadForPrintAsync({zoomLevel:e,force:t});i.push(o)}return Promise.all(i).then((()=>{r.resolve()})),r}getPagesPrintContentAsync(e){const t=this.pages;const n=[];for(let i=0;i<t.length;i++){const r=t[i].getPrintContentAsync();r.then((t=>{const n=OI("<div></div>");n.appendChild(t),e.appendChild(n)})),n.push(r)}return n}initPrintContainer(){this.printContainer=OI("<div></div>")}openPrintDialog(){const e=this.pages;const t=e[0].rawWidth*this.getPrintUnits();const n=e[0].rawHeight*this.getPrintUnits();const i=window.open("","","innerWidth="+t+",innerHeight="+n+"location=no,titlebar=no,toolbar=no");if(!i||!i.document)return void this.triggerError({message:this.options.messages.errorMessages.popupBlocked});i.document.body.style.margin="0",i.document.body.appendChild(this.printContainer);const r=()=>{i.removeEventListener("afterprint",r),i.close()};i.addEventListener("afterprint",r),i.focus(),i.print()}cacheZoomLevelBeforePrint(){this.setState({zoomLevelBeforePrint:this.state.zoomLevel})}restoreZoomLevelBeforePrint(){this.state.zoomLevelBeforePrint!==this.state.zoomLevel&&this.zoom({zoomLevel:this.state.zoomLevelBeforePrint,zoomLevelType:this.state.zoomLevelType,currentZoom:this.state.zoomLevel})}searchText(e={text:"",matchCase:!1}){var t;this.initSearchService();return null===(t=this.searchService)||void 0===t?void 0:t.search(e)}clearSearch(){this.destroySearchService()}initSearchService(){const e=Array.from(this.wrapper.querySelectorAll(VI(this.options.elementSelectors.textLayerClass))||[]);if(this.searchService){if(e.every(((e,t)=>e===this.searchService.options.textContainers[t])))return;this.destroySearchService()}this.searchService=new ZI({textContainers:e,highlightClass:this.options.elementSelectors.searchHighlightClass,highlightMarkClass:this.options.elementSelectors.searchHighlightMarkClass,charClass:this.options.elementSelectors.charClass})}destroySearchService(){this.searchService&&(this.searchService.destroy(),this.searchService=null)}goToNextSearchMatch(){if(!this.searchService)return;this.searchService.markNextMatch();const e=this.searchService.getActiveMatchElement();this.scrollToSearchMatch(e)}goToPreviousSearchMatch(){if(!this.searchService)return;this.searchService.markPreviousMatch();const e=this.searchService.getActiveMatchElement();this.scrollToSearchMatch(e)}getPagesContainer(){return this.element.querySelector(VI(this.options.elementSelectors.pagesContainerClass))}getDocumentContainer(){return this.wrapper.querySelector(VI(this.options.elementSelectors.documentContainerClass))}getPagesElements(){const e=this.getDocumentContainer();return e?HI(e.querySelectorAll(VI(this.options.elementSelectors.pageSelector))):[]}scrollToSearchMatch(e){if(!e)return;const t=e.closest(".k-text-char");const n=t?t.closest('span[role="presentation"]'):null;if(!n)return;const i=n.closest(".k-page");if(!i)return;const r=i.offsetLeft+-1*this.documentScroller.element.offsetLeft+n.offsetLeft+this.options.searchMatchScrollLeftOffset;const o=i.offsetTop+-1*this.documentScroller.element.offsetTop+n.offsetTop+this.options.searchMatchScrollTopOffset;this.documentScroller.scrollTo(r,o,{trackScrollEvent:!1})}resetInteractionMode(){this.setInteractionMode({mode:bO.TextSelection})}setInteractionMode(e){this.interactionMode=e.mode,this.interactionMode===bO.TextSelection?(this.disableScrollerEventsTracking(),dz(this.options.elementSelectors.enabledTextSelectionClass,this.documentScroller.element),hz(this.options.elementSelectors.enabledPanningClass,this.documentScroller.element)):this.interactionMode===bO.Pan&&(this.enableScrollerEventsTracking(),hz(this.options.elementSelectors.enabledTextSelectionClass,this.documentScroller.element),dz(this.options.elementSelectors.enabledPanningClass,this.documentScroller.element))}enableScrollerEventsTracking(){this.documentScroller&&this.documentScroller.enablePanEventsTracking()}disableScrollerEventsTracking(){this.documentScroller&&this.documentScroller.disablePanEventsTracking()}setScaleFactor(e){this.element.style.setProperty("--scale-factor",String(e*bI.PDF_TO_CSS_UNITS))}activatePageNumber(e){const t=this.getPageByNumber(e);if(!t)return;const n=e-1;this.state.activePageNumber!==e&&(this.state.activePageNumber=e,t.isBlank()?this.drawPageAsync({pageIndex:n}).then((()=>{this.scrollToPage({pageNumber:e})})):this.scrollToPage({pageNumber:e}))}scrollToPage({pageNumber:e}){const{left:t,top:n}=this.getPageNumberScrollOffset(e);this.scrollDocument({left:t,top:n})}scrollDocument({left:e,top:t}){var n;null===(n=this.documentScroller)||void 0===n||n.scrollTo(e,t,{trackScrollEvent:!1})}getPageNumberScrollOffset(e){if(!this.getPageByNumber(e))return{left:0,top:0};const t=this.pages.slice(0,Math.max(0,e-1)).map((e=>this.getPageScrollOffset(e))).reduce(((e,t)=>e+t),0);return{left:0,top:t}}getPageScrollOffset(e){var t;const n=(null===(t=null==e?void 0:e.element)||void 0===t?void 0:t.getBoundingClientRect().height)||0;const i=getComputedStyle(e.element);return n+(parseFloat(i.marginTop)||0)}getPageByNumber(e){return this.pages&&this.pages[e-1]}addHighlightAnnotation(){var e;null===(e=this.annotationEditorUIManager)||void 0===e||e.highlightSelection()}setHighlightColor(e){this.executeAnnotationCommand({commandType:_I.HIGHLIGHT_COLOR,commandValue:e})}deleteAnnotation(){var e;null===(e=this.annotationEditorUIManager)||void 0===e||e.delete()}resetAnnotationEditorMode(){this.setAnnotationEditorMode({mode:mI.NONE,editId:null,isFromKeyboard:!1})}setAnnotationEditorMode(e){this.annotationEditorMode=e}setFreeTextColor(e){this.executeAnnotationCommand({commandType:_I.FREETEXT_COLOR,commandValue:e})}setFreeTextFontSize(e){this.executeAnnotationCommand({commandType:_I.FREETEXT_SIZE,commandValue:parseFloat(e)})}executeAnnotationCommand({commandType:e,commandValue:t}){this.eventBus.dispatch("switchannotationeditorparams",{source:this,type:e,value:t})}isValidAnnotationEditorMode(e){return Object.values(mI).includes(e)&&e!==mI.DISABLE}cleanupSwitchAnnotationEditorMode(){lz(this,SO,"f")&&(this.eventBus._off("pagerendered",lz(this,SO,"f")),cz(this,SO,null,"f")),null!==lz(this,kO,"f")&&(clearTimeout(lz(this,kO,"f")),cz(this,kO,null,"f"))}_getVisiblePages(){return this.pages}get _layerProperties(){const e=this;return fI(this,"_layerProperties",{get annotationEditorUIManager(){return e.annotationEditorUIManager},get annotationStorage(){var t;return null===(t=e.pdfDocument)||void 0===t?void 0:t.annotationStorage},get linkService(){return e.linkService}})}scrollPageIntoView({pageNumber:e,destArray:t=null,allowNegativeOffset:n=!1,ignoreDestinationZoom:i=!1}){if(!this.pdfDocument)return;const r=Number.isInteger(e)&&this.pages[e-1];if(!r)return;if(this.isInPresentationMode||!t)return void this._setCurrentPageNumber(e,!0);let o=0,a=0;const s=(r.rotation%180!=0?r.rawWidth:r.rawHeight)/r.scale/bI.PDF_TO_CSS_UNITS;if("XYZ"!==t[1].name)return;o=t[2],a=t[3],o=null!==o?o:0,a=null!==a?a:s;const l=[r.viewport.convertToViewportPoint(o,a),r.viewport.convertToViewportPoint(o+0,a+0)];let c=Math.min(l[0][0],l[1][0]);let d=Math.min(l[0][1],l[1][1]);n||(c=Math.max(c,0),d=Math.max(d,0)),lz(this,wO,"m",MO).call(this,r,{left:c,top:d})}_setCurrentPageNumber(e,t=!1){if(this._currentPageNumber===e)return!0;if(!(0<e&&e<=this.state.pdfDocument.numPages))return!1;const n=this._currentPageNumber;return this._currentPageNumber=e,this.eventBus.dispatch("pagechanging",{source:this,pageNumber:e,previous:n}),!0}}yO=new WeakMap,kO=new WeakMap,xO=new WeakMap,CO=new WeakMap,SO=new WeakMap,wO=new WeakSet,TO=function(){const e=[];const t=new Set;this.pages.forEach((e=>{t.add(e.id)}));for(const n of this.pages){const i=n;i.hasEditableAnnotations()?e.push(n):t.delete(i.id)}return 0===e.length?null:(this.drawPagesAsync(this.state.pdfPages),t)},MO=function(e,t=null){const{div:n,id:i}=e;if(this._currentPageNumber!==i&&this._setCurrentPageNumber(i),!t&&!this.isInPresentationMode){const e=n.offsetLeft+n.clientLeft,i=e+n.clientWidth;const{scrollLeft:r,clientWidth:o}=this.element;(this._scrollMode===GP||e<r||i>r+o)&&(t={left:0,top:0})}!function(e,t,n=!1){let i=e.offsetParent;if(!i)return void console.error("offsetParent is not set -- cannot scroll");let r=e.offsetTop+e.clientTop;let o=e.offsetLeft+e.clientLeft;for(;i.clientHeight===i.scrollHeight&&i.clientWidth===i.scrollWidth||n&&(i.classList.contains("markedContent")||i.classList.contains("k-marked-content")||"hidden"===getComputedStyle(i).overflow);)if(r+=i.offsetTop,o+=i.offsetLeft,i=i.offsetParent,!i)return;t&&(void 0!==t.top&&(r+=t.top),void 0!==t.left&&(o+=t.left,i.scrollLeft=o)),i.scrollTop=r}(n,t)},function(e){var t=window.kendo,n=e.extend;var 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;var i=e.Deferred();var r=n.viewer.document.pages[t-1];var 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;t=kendo.Class;var o=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;var 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;const i=t.viewer._isDPLProcessor()?n:{data:n};t.viewer.fromFile(i)},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;var l={Path:"path",MultiPath:"multipath",Rect:"rect",Image:"image",Text:"text"};var 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});var 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});var h=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()};var 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){var t={transform:this._getMatrix(e.transform),stroke:e.strokeOptions,fill:e.fillOptions};var n=new i.MultiPath(t);for(var 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:h}),t(kendo.pdfviewer,{BlankPage:d})}(window.kendo.jQuery);const VO=(e,t)=>{e.interactionMode!==t.mode&&e.setInteractionMode({mode:t.mode}),e.setAnnotationEditorMode(t)};const NO=e=>{e.resetAnnotationEditorMode()};const $O=(e,t)=>{e.setInteractionMode({mode:t})};const UO=jQuery;const WO=3,jO=9;class qO{constructor(e){this.viewer=e,this.widget=e.pdfViewerCommon,this.init()}init(){const e=this.element=UO("<div></div>");e.insertAfter(this.viewer.toolbar.element);const t=this.toolbar=new kendo.ui.ToolBar(e,{fillMode:"flat",tools:[{name:"highlight",command:"highlight",icon:"highlight",type:"button",togglable:!0,showText:"overflow",group:"annotations",fillMode:"flat"},{type:"separator"},{name:"freeText",command:"freeText",icon:"free-text",type:"button",togglable:!0,showText:"overflow",group:"annotations",fillMode:"flat"},{type:"spacer"},{name:"close",command:"close",icon:"x",type:"button",showText:"overflow",fillMode:"flat"}],parentMessages:{highlight:"Highlight",freeText:"Free text",close:"Close"}});t.bind("click",this.onToolbarClick.bind(this)),t.bind("toggle",this.onToolbarClick.bind(this))}onToolbarClick(e){const t=this.widget;const n=UO(e.target).data("command");const i=this.viewer.toolbar;switch(n){case"close":this.destroy(),i.element.find("[tabindex=0]").trigger("focus");break;case"highlight":VO(t,{interactionMode:bO.TextSelection,mode:jO});break;case"freeText":VO(t,{interactionMode:bO.TextSelection,mode:WO})}}destroy(){this.toolbar&&(this.viewer.toolbar.toggle("[title='Annotations']",!1),this.toolbar.unbind("click"),this.toolbar.unbind("toggle"),this.toolbar.destroy(),this.toolbar=null,this.element.remove(),this.element=null,this.viewer.annotationsToolbar=null,NO(this.widget))}}!function(e){var t=window.kendo,n=e.extend,i=t.ui.progress,r=t.Class,o=t.pdfviewer.UploadHelper;var a=r.extend({init:function(e){this.options=e,this.viewer=e.viewer,this.errorMessages=this.viewer.options.messages.errorMessages}});var 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()}});var 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)}});var 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.viewer.pdfViewerCommon.downloadFile({fileName:t})}});var 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}});var h=a.extend({exec:function(){const e=this.viewer;e.toolbar.enable(e.toolbar.element.find("[data-command=AnnotationsCommand]"),!0),$O(e.pdfViewerCommon,bO.TextSelection)}});var u=a.extend({exec:function(){const e=this.viewer;e.toolbar.enable(e.toolbar.element.find("[data-command=AnnotationsCommand]"),!1),e.annotationsToolbar&&e.annotationsToolbar.destroy(),NO(e.pdfViewerCommon),$O(e.pdfViewerCommon,bO.Pan)}});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.changeHandler=e._change.bind(e),e.viewer.searchDialog.searchModel.bind("change",e.changeHandler)},_close:function(){const e=this;e.viewer.pdfViewerCommon.clearSearch(),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.viewer.pdfViewerCommon.searchText({text:n,matchCase:i}),t.matchIndex=t.matches.length?1:0,t._updateSearchModel())},_next:function(){const e=this;e.viewer.pdfViewerCommon.goToNextSearchMatch(),e.matchIndex=e.matchIndex+1>e.matches.length?1:e.matchIndex+1,e._updateSearchModel()},_prev:function(){const e=this;e.viewer.pdfViewerCommon.goToPreviousSearchMatch(),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;const t=e._calculateZoom();if(undefined===t)return;let n=t.zoomLevel;e.viewer.zoomScale!==t.zoomLevel&&(e.viewer._preventRenderEvent=!0,e.viewer._currentPage=e.viewer.pdfViewerCommon.getCurrentPageIndex()+1,e.viewer.pdfViewerCommon.zoom({zoomLevel:t.zoomLevel,zoomLevelType:t.zoomLevelType}),n=e.viewer.pdfViewerCommon.options.zoomLevel,e._triggerZoomEnd(n)),e.viewer.zoomScale=n},_calculateZoom:function(){var e,n=this.options,i=this.viewer,r=i.options,o=n.value||n.scale,a=o,s="";if(i._allowResize=!1,i._autoFit=!1,n.zoomIn?a=o=i.zoomScale+r.zoomRate:n.zoomOut?a=o=i.zoomScale-r.zoomRate:"auto"===o?(i._allowResize=!0,a=i._autoZoomScale):"string"!=typeof o||t.parseFloat(o)?o&&o.toString().match(/^[0-9]+%?$/)?a=o=parseInt(o.replace("%",""),10)/100:e=isNaN(o):s=o,e||(e=o<r.zoomMin||o>r.zoomMax),!e&&!i.trigger("zoomStart",{scale:o}))return n.updateComboBox&&i.toolbar&&i._updateZoomComboBox(o),{zoomLevel:a,zoomLevelType:s}},_triggerZoomEnd:function(e){this.viewer.trigger("zoomEnd",{scale:e})}});var m=a.extend({init:function(e){a.fn.init.call(this,e)},exec:function(){const e=this;e.viewer.document?(i(e.viewer.pageContainerWrapper,!0),setTimeout((()=>{e.viewer.pdfViewerCommon.printFile()}),100)):e.viewer._triggerError({message:this.errorMessages.notFound})}});const g=a.extend({init:function(e){a.fn.init.call(this,e)},exec:function(){const e=this.viewer;e.annotationsToolbar?e.annotationsToolbar.destroy():e.annotationsToolbar=new qO(e)}});n(t.pdfviewer,{OpenCommand:s,PageChangeCommand:l,DownloadCommand:c,EnableSelectionCommand:h,EnablePanCommand:u,ExportCommand:d,PrintCommand:m,OpenSearchCommand:p,ZoomCommand:f,AnnotationsCommand:g})}(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;var 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()}});var h=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;var i=n.options;var r=i.messages.dialogs;var 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})}});var u=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;var i=t.template(n.options.template);var 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;var 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=n.dialog;var i={};var r;(r=e.x.client-t.startPosition.left)&&isNaN(r)&&r.toString().indexOf("px")<0?i.left=r:i.left=Math.max(Math.min(parseInt(r,10),parseInt(t.maxLeft,10)),0),t.css(i)}}),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;var 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:h,SearchDialog:u}})}(window.kendo.jQuery);const GO=jQuery;class KO{constructor(e,t,n){this.viewer=e,this.widget=e.pdfViewerCommon,this.anchor=t,this.editor=n,this.popupOpenHandler=this.onPopupOpen.bind(this),this.init()}init(){const e=this.anchor;const t=GO(`<div data-uid="${kendo.guid()}"></div>`);this.popup=new kendo.ui.Popup(GO('<div class="k-pdf-viewer-annotation-editor-toolbar"></div>'),{anchor:e}),this.popup.element.html(t);(this.popupToolbar=new kendo.ui.ToolBar(t,{fillMode:"flat",tools:[{name:"palette",command:"palette",icon:"palette",type:"button",showText:"overflow",fillMode:"flat"},{name:"remove",command:"remove",icon:"trash",type:"button",showText:"overflow",fillMode:"flat"}],parentMessages:{palette:"Palette",remove:"Remove"}})).bind("click",this.onAnnotationPopupToolbarClick.bind(this)),this.popup.open()}initEditor(){}onAnnotationPopupToolbarClick(e){const t=this.widget;switch(GO(e.target).data("command")){case"palette":this.initEditor();break;case"remove":(e=>{e.deleteAnnotation()})(t),this.destroyPopup()}}onPopupOpen(){this.flatColorPicker._view._hueSlider.resize(),this.flatColorPicker._view._opacitySlider.resize()}anchorExists(){return document.getElementById(this.anchor.id)}destroyPopup(){this.popup&&(this.popup.destroy(),this.popup=null)}destroyEditor(){this.editorPopup&&(this.editorPopup.destroy(),this.editorPopup=null)}destroy(){this.popupToolbar&&(this.popupToolbar.unbind("click"),this.popupToolbar.unbind("toggle"),this.popupToolbar.destroy(),this.popupToolbar=null),this.destroyPopup()}}class YO extends KO{constructor(e,t,n){super(e,t,n)}initEditor(){const e=this.anchor;this.anchorExists()?(this.destroyEditor(),this.editorPopup=new kendo.ui.Popup(GO('\n <div class="k-pdf-viewer-annotation-editor">\n <span class="k-column-menu-group-header">\n <span class="k-column-menu-group-header-text">Color</span>\n </span>\n <div ref-annotation-editor-flat-color-picker></div>\n </div>\n'),{anchor:e,activate:this.popupOpenHandler}),this.initFlatColorPicker(),this.editorPopup.open(),this.destroy()):this.destroy()}initFlatColorPicker(){this.flatColorPicker=new kendo.ui.FlatColorPicker(this.editorPopup.element.find("[ref-annotation-editor-flat-color-picker]"),{format:"rgb",opacity:!0,change:e=>{return t=this.widget,n=e.value,void t.setHighlightColor(n);var t,n}})}onPopupOpen(){const e=this.editor.color;super.onPopupOpen(),this.flatColorPicker.value(e)}}class QO extends KO{constructor(e,t,n){super(e,t,n)}initEditor(){const e=this.anchor;this.anchorExists()?(this.destroyEditor(),this.editorPopup=new kendo.ui.Popup(GO('\n <div class="k-pdf-viewer-annotation-editor">\n <span class="k-column-menu-group-header">\n <span class="k-column-menu-group-header-text">Text style</span>\n </span>\n <form ref-annotation-text-editor-popup-form></form>\n <span class="k-column-menu-group-header">\n <span class="k-column-menu-group-header-text">Color</span>\n </span>\n <div ref-annotation-editor-flat-color-picker></div>\n </div>\n'),{anchor:e,activate:this.popupOpenHandler}),this.initFontSizeForm(),this.initFlatColorPicker(),this.editorPopup.open(),this.destroy()):this.destroy()}initFontSizeForm(){const e=this.editor.propertiesToUpdate[0][1];this.fontSizeForm=new kendo.ui.Form(GO("[ref-annotation-text-editor-popup-form]"),{buttonsTemplate:()=>"",formData:{fontSize:e},layout:"grid",grid:{cols:3},items:[{field:"fontSize",label:"Font size",editor:"DropDownList",colSpan:1,editorOptions:{fillMode:"flat",dataSource:[8,9,10,11,12,13,14,16,20,22,24,26,28,36,48,72],change:e=>{const t=e.sender.value();var n,i;n=this.widget,i=t,n.setFreeTextFontSize(i)}}}]}),this.fontSizeForm.element.find(".k-form-buttons").remove()}initFlatColorPicker(){this.flatColorPicker=new kendo.ui.FlatColorPicker(this.editorPopup.element.find("[ref-annotation-editor-flat-color-picker]"),{format:"rgb",opacity:!0,change:e=>{return t=this.widget,n=e.value,void t.setFreeTextColor(n);var t,n}})}onPopupOpen(){const e=this.editor.propertiesToUpdate[1][1];super.onPopupOpen(),this.flatColorPicker.value(e)}}!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,h="render",u="error",p="keydown"+n,f="update",m="pagechange",g="zoomEnd",v="ZoomCommand",_="click",b="change",w="k-disabled",y="pdfjs",k="dpl",x="k-pdf-viewer",C="k-canvas k-pdf-viewer-canvas k-pos-relative k-overflow-auto",S="k-enable-panning",T="auto",M="ActualWidth",A="FitToWidth",D="FitToPage";var E=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",u,"zoomStart",g],options:{name:"PDFViewer",view:{type:"canvas"},pdfjsProcessing:{file:null,renderForms:!1,loadOnDemand:!0},dplProcessing:{read:{url:null,type:"GET",dataType:"json",pageField:"pageNumber"},upload:{url:null,saveField:"file"},download:{url:null},loadOnDemand:!1},toolbar:{items:[],contextMenu:!1},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"},contextMenu:"Menu",open:"Open",exportAs:"Export",download:"Download",print:"Print",toggleSelection:"Enable Selection",togglePan:"Enable Panning",search:"Search",annotations:"Annotations"},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:{contextMenu:{type:"dropDownButton",name:"contextMenu",showText:"overflow",id:"pdfviewer-toolbar-context-menu",overflow:"never",icon:"menu",fillMode:"flat",menuButtons:[{id:"open",text:"Open",icon:"folder-open",attributes:{"data-command":"OpenCommand"}},{id:"download",text:"Download",icon:"download",attributes:{"data-command":"DownloadCommand"},enable:!1},{id:"print",text:"Print",icon:"print",attributes:{"data-command":"PrintCommand"},enable:!1}]},separator:{type:"separator"},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"},annotations:{togglable:!0,type:"button",showText:"overflow",name:"annotations",icon:"edit-annotations",command:"AnnotationsCommand",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(p,e._keydown.bind(e)),e._allowResize=null===e.options.scale,e._autoZoomScale=ez,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:v,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=ez,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);const n=Array.from(e.toolbar.element.children(":not(.k-hidden):not(:has(.k-pager))"));const 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:not(.k-input-validation-icon)");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:y,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.6.82/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.6.82/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.6.82/pdf.mjs" type="module"><\/script>')},_isDPLProcessor:function(){return this.processingLib===k},_hasPagerTool:function(e){let t=!1;let n;for(let i=0;i<e.length;i++){const r=e[i];if("string"==typeof r?(t="pager"===r.toLowerCase(),n=i):r.type?(t="pager"===r.type.toLowerCase(),n=i):r.name&&(t="pager"===r.name.toLowerCase(),t&&delete r.name,n=i),t)break}return{hasPager:t,index:n}},_renderToolbar:function(){var t=this,n=t.options,r=o({},n.toolbar),a=r.items&&r.items.length?r.items:Object.keys(t.defaultTools);if(t.options.pdfjsProcessing.renderForms&&!r.items.length){const[e,n]=[...t.defaultTools.toggleSelection.buttons];e.selected=!0,n.selected=!1}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",overflow:r.overflow};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(_,t._toolbarClick.bind(t)),t.toolbar.bind(b,t._toolbarClick.bind(t)),r.contextMenu&&t.toolbar.element.find("[data-role=dropdownbutton]").on(_,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.toolbar,r=n.options.messages.toolbar;if(t=t.flatMap((t=>{if("zoom"===t&&(t=n.defaultTools.zoom),"zoom"===t.name){t=e.extend({},n.defaultTools.zoom,t);var i=[{percent:T,text:r.autoWidth},{percent:M,text:r.actualWidth},{percent:A,text:r.fitToWidth},{percent:D,text:r.fitToPage}];var o=t.data.map((e=>({percent:e,text:e+"%"})));var a=n.options.scale?100*n.options.scale+"%":"auto";i=i.concat(o),t.componentOptions.dataSource=i,t.componentOptions.value=a}return t})),i.contextMenu)t=t.filter((e=>"open"!==e&&"download"!==e&&"print"!==e));else{const e=t.findIndex((e=>"contextMenu"===e));-1!==e&&t.splice(e,1);const n=t.findIndex((e=>"separator"===e));-1!==n&&t.splice(n,1)}return 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(t){const n=this.toolbar,i=n.element;const r=e("#pdfviewer-toolbar-context-menu_buttonmenu");let o=i.find("[data-command='DownloadCommand']");let a=i.find("[data-command='PrintCommand']");r.length&&(o=r.find("[data-command='DownloadCommand']"),a=r.find("[data-command='PrintCommand']")),n.enable(i.find("[data-command=EnableSelectionCommand]").parent(),!t),n.enable(i.find("[data-command=ZoomCommand][role=button]").parent(),!t),n.enable(i.find("[data-command='OpenSearchCommand']"),!t),n.enable(o,!t),n.enable(a,!t)},_updatePager:function(e){const t=this;if(e.updatePager){const n="dpl"===t.processingLib?t.document&&t.document.pages?t.document.pages:[]:t.pages??[];const r=new i.data.DataSource({data:n??[],pageSize:1,page:e.page});t.pager.setDataSource(r),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(w):e.element.hasClass(w)&&e.element.removeClass(w)},_updateZoomComboBox:function(e){var t=e===T||e===M||e===D||e===A,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.attr("tabindex",0),t.pageContainerWrapper.append(t.pageContainer),t.wrapper.append(t.pageContainerWrapper))},_triggerError:function(e){var t=this._initErrorDialog();o(e,{dialog:t}),this.pageContainer&&d(this.pageContainer,!1),this.trigger(u,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.pdfScroller&&n.pdfScroller.enablePanEventsTracking(),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(f,{isBlank:!0})},_removeBlankPage:function(){this._blankPage&&(this._blankPage.destroy(),this._blankPage.element.remove(),this._blankPage=null)},_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,i=t.pdfViewerCommon?.getPagesElements();let r=0;t.pages.forEach((function(t){const o=t.element?t.element.width():e(i[t._pageIndex]).width();const a=n/o;a>r&&(r=a)})),t._autoFit?t.zoom(t._autoFit,!0):(r=Math.min(Math.max(r,t.options.zoomMin),ez),r!=t.zoomScale&&(t.zoom(r,!0),t.zoomScale=r,t._allowResize=!0),t.pager&&t.pager.element&&t._resizePager())},_attachContainerEvents:function(){const e=this;e.pageContainer.addClass(S),e.pageContainerWrapper.bind("scroll",e._scroll.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=oz(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(f,{action:m,page:t,total:r,pageChangeFromScroll:!0})}},zoom:function(e,t){var n=this;if(!n._isDPLProcessor())return e?n.execute({command:v,options:{value:e,updateComboBox:!t}}):n.zoomScale},execute:function(e){var t=o({viewer:this},e.options);return new i.pdfviewer[e.command](t).exec()},_loadDPLDocument:function(){var e=this;var 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 qI(e.pageContainer[0].parentNode,{filter:".k-page",events:{}}),e.pdfScroller.enablePanEventsTracking(),d(e.pageContainer,!1)}))},_loadPdfJSDocument:function(e){const t=this;const n=t.options;const i=n.page;let r;r=e||n.pdfjsProcessing.file,r?("string"==typeof r?r={url:r}:r instanceof ArrayBuffer&&(r={data:r}),t._removeBlankPage(),d(t.pageContainer,!0),t.pdfViewerCommon=new OO(t.element[0],{loadOnDemand:t.options.pdfjsProcessing.loadOnDemand,loadOnDemandPageSize:1,zoomLevel:t.zoomScale,renderForms:t.options.pdfjsProcessing.renderForms,fileDescriptor:r,events:{pagesLoad:e=>{t.document=e.pdfDoc,t.pages=e.pdfPages,t.options.pdfjsProcessing.renderForms?$O(t.pdfViewerCommon,0):$O(t.pdfViewerCommon,1),t.activatePage(i,!0),t.trigger(f),t._currentPage>-1&&(t.pdfViewerCommon.scrollToPage({pageNumber:t._currentPage}),t._currentPage=null),d(t.pageContainer,!1)},pageRendered:e=>{t._preventRenderEvent||t.trigger(h,{page:e.page.pdfPage}),t._setPageNumberAttributes(),t._preventRenderEvent=!1},zoomStart:e=>{t._currentPage=t.pdfViewerCommon.getCurrentPageIndex()+1},zoomEnd:e=>{t.zoomScale=e.zoomLevel,t._updateZoomComboBox(e.zoomLevel),t.trigger(g,{scale:e.zoomLevel})},printEnd:e=>{d(t.pageContainerWrapper,!1)},scroll:e=>{e.isPageChanged&&t.trigger(f,{action:m,page:e.pageNumber,total:t.pages.length,pageChangeFromScroll:!0})},error:e=>{t._triggerError({error:e.message,message:t.options.messages.errorMessages.parseError})},annotationEditorToolBarShow:t.onAnnotationEditorToolBarShow.bind(t)}})):t._renderBlankPage()},_enablePanning:function(){this.pdfViewerCommon.documentScroller.enablePanEventsTracking()},_disablePanning:function(){this.pdfViewerCommon.documentScroller.disablePanEventsTracking()},_setPageNumberAttributes:function(){this.pageContainer.find(".k-page").each(((t,n)=>{e(n).attr(i.attr("number"),t+1)}))},loadPage:function(e){const t=this,n=t.pages&&t.pages[e-1];if(n)return t._isDPLProcessor()?n.load(t.zoomScale):Promise.resolve()},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.pdfViewerCommon.activatePageNumber(e),n.trigger(f,{action:m,page:e,total:n.pages.length,updatePager:t})))},_scrollToActivatedPage:function(e,t){const n=this,i=n.pageContainerWrapper;n._preventScroll=!0,rz(i[0],e-1),n.trigger(f,{action:m,page:e,total:n.pages.length,updatePager:t})},_getVisiblePagesCount:function(){var e=this,t=0,n=0,i=e.pageContainer[0].clientHeight,r=0;for(;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;const t=[];for(var n=0;n<=e;n++)t.push(this.loadPage(n));return t},fromFile:function(t){const n=this;if(n._isDPLProcessor())n.zoomScale=n.options.scale||ez,n.zoom(n.zoomScale,!0),n.trigger(f,{action:"zoom",zoom:n.options.scale||"auto"}),n.processor._updateDocument(t),n._loadDPLDocument();else if(n.pdfViewerCommon){n.annotationsToolbar?.destroy(),NO(n.pdfViewerCommon),n.toolbar.toggle("[title='Annotations']",!1),n.toolbar.toggle("[title='Enable Selection']",!1),n.toolbar.toggle("[title='Enable Panning']",!0);const i=e.isPlainObject(t)?t:{url:t};n.pdfViewerCommon.loadFile(i)}else n._loadPdfJSDocument(t)},exportImage:function(e){var t=this;var n=e.page;var r=t.pages[n-1]||t._blankPage;var 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;var n=e.page;var 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()},onAnnotationEditorToolBarShow:function(e){const t=this;const n=e.annotationEditorMode;const i=e.anchor;const r=t.annotationPopup?.popup;const o=e.source.firstSelectedEditor;if(!r||!r.visible()||r._closing||"freeText"!==n)switch(t.annotationPopup&&(t.annotationPopup.destroy(),t.annotationPopup.destroyEditor(),t.annotationPopup=null),n){case"highlight":t.annotationPopup=new YO(t,i,o);break;case"freeText":t.annotationPopup=new QO(t,i,o)}}});r.plugin(E)}(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",h="select",u="selected",p="hovered",f="disabled",m="readonly",g="keydown"+o,v="click"+o,_="mouseenter"+o,b="mouseleave"+o,w="mousemove"+o,y="mousedown"+o,k="focus"+o,x="blur"+o,C="aria-label",S="aria-labelledby",T="aria-valuenow",M="aria-disabled",A="aria-readonly",D="k-rating-precision-part",E="k-rating-precision-complement",I=.5,z="k-rating-item",P="k-focus",L="tabindex",B=".",H="min",R="max";var F="single",O="continuous";var V="item",N="half";var $={item:"itemTemplate",hovered:"hoveredTemplate",selected:"selectedTemplate"};var U={selected:"k-selected",hovered:"k-hover",hoveredPrecise:"k-hover-precise"};var W="part-value",j="data-value",q="value",G="title";var 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"};var Y=({value:e,maxValue:t})=>`<span>${r(e)} / ${r(t)}</span>`;var Q=({styles:e,value:t})=>`<span class="${r(e.item)}" data-value="${r(t)}"></span>`;var X=({icon:e})=>n.ui.icon({icon:e,size:"xlarge"});var 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:[h,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(B+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(H))||t.options.min,h=c(t.element.attr(R))||t.options.max;if(t.wrapper.attr(L,0).attr("role","slider").attr("aria-valuemin",d).attr("aria-valuemax",h).attr(T,t.options.value||(d+h)/2),s)i.attr(C,s);else if(l)i.attr(S,l);else if(a.length){var u=a.attr("id");u||(u=(o||n.guid())+"_label",a.attr("id",u)),i.attr(S,u)}},_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(H))||e.options.min,n.max=c(e.element.attr(R))||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(){var t=this,i=t.container,r=t.options.min,o=t.options.max,a=t.options.itemTemplate?n.template(t.options.itemTemplate):X;for(var 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(B+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(B+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,B+z,e._click.bind(e)).on(_,B+z,e._mouseenter.bind(e)).on(b,B+z,e._mouseleave.bind(e)).on(y,e._mousedown.bind(e)),t&&e.container.on(w,B+z,e._mousemove.bind(e))},_focus:function(){var e,t,n,i=this,r=i.container,o=i.wrapper,a=i.container.find(B+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(B+U.selected).last(),t=r.find(B+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(B+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,h=s.options.precision!=V?I:1,u=c.find(B+z),p=c.find(B+P),f=u.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?u.eq(0):e(u[f-1]),a=g?s._valueMin:d-h,s._select(o,a),t.preventDefault()):r||v===l.UP?(o=g?u.eq(0):e(u[f+1]),a=g?s._valueMin:d+h,s._select(o,a),t.preventDefault()):v===l.HOME?(o=u.eq(0),s._select(o,s._valueMin),t.preventDefault()):v===l.END&&(o=u.eq(u.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=F==n.options.selection,r=n.options.precision==N,o=n.container.find(B+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==u&&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(B+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(h,{target:e}),n._change(e,i),n._focus())},_mouseenter:function(t){var n=this,i=e(t.target),r=i.closest(B+z);n.options.enabled&&!n.options.readonly&&(n.enableMove=!0,i.is(B+z)&&n._updateItemTemplates(p,r))},_mouseleave:function(t){var n,i,r=this,o=r.options.selection,a=r.options.precision==N,s=o==F,l=e(t.target).closest(B+z),c=r.container.find(B+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,u)};if(c.removeClass(U.hovered),s)d(l);else for(var h=0;h<c.length;h+=1){d(e(c[h]))}},_mousemove:function(t){var n,i,r,o=this,a=e(t.target).closest(B+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(B+D),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(D)).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(B+D),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(B+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(H))||t.options.min,r=c(t.element.attr(R))||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":u,r=null===e?t.container.find(B+U.selected).last():t.container.find(B+z+"[data-value='"+Math.ceil(e)+"']");null===e&&t.container.find(B+z).removeClass(U.selected),t._updateItemTemplates(i,r),n&&null!==e&&t._togglePrecisionElements(r,u),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(M),n.attr(L,0)):(t.attr(f,f),n.attr(M,!0),n.removeAttr(L)),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;var o=r.extend({init:function(e){this.options=e,this.filemanager=e.filemanager}});var 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)}});var 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)}))}});var 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");var s=t.filemanager.treeView.widgetComponent.dataSource.getByUid(a);var 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))}});var c=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){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;for(var 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)}}});var d=o.extend({init:function(e){o.fn.init.call(this,e),this._itemsToRemove=[]},exec:function(){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=[];for(var c=0;c<o.length;c++){var d=r.get(o[c]);var h=d.toJSON();h.fileManagerNewItem=!0;var u=i.push({item:d,target:a}).then(e._delete.bind(e));l.push(u),s.add(h)}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))}});var h=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])}});var u=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)}});var 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)}});var 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))}});var 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]}});var 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:h,SearchCommand:u,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",h="keydownAction",u=".kendoFileManagerViewComponent",p=[],f=null;var 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"+u,e._dblClick.bind(e)),t.element.on("mousedown"+u,".k-listview-item:not(.k-edit-item)",e._mousedown.bind(e)),t.element.on(d+u,".k-edit-item",e._keydown.bind(e)),t.element.on(d+u,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(h,{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(){var e=this.listView.select(),t=[];for(var 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(u),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"),h=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&&h.length&&o._progress(l,!1)),h.length){if("itemloaded"==a||l&&"sync"===a)l.find(".k-treeview-item").each((function(e,t){o.remove(t)})),o.append(h,l),i._shouldFocus&&(o.current(l),o.focus());else if("remove"==a)this._remove(h[0].id);else if("itemchange"==a){var u=o.dataSource.get(h[0].id);u?u.set(n.field,h[0][n.field]):o.append(h[0],l)}else o.dataSource.data().length?("sync"===a||undefined===a&&!l)&&(o.items().each((function(e,t){o.remove(t)})),o.append(h),i._shouldFocus&&(o.current(o._nextVisible(e())),o.focus())):o.append(h);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(h,{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);let 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"+u,t._dblClick.bind(t)),n.table.on("mousedown"+u,"tr:not(.k-grid-edit-row)",t._mousedown.bind(t)),n.table.on(d+u,".k-grid-edit-row",t._keydown.bind(t)),n.table.on(d+u,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(h,{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(){var e=this.grid.select(),t=[];for(var 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(u),this.grid.element.off(u),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=this;var n,i,r;e.children instanceof t.data.FileManagerDataSource||(i=(n=e.children=new t.data.FileManagerDataSource(e._childrenOptions)).transport,r=i.parameterMap,i.parameterMap=function(t,n){return"read"!==n&&"create"!==n||(t.target=e.id),r&&(t=r.call(e,t,n)),t},n.parent=function(){return e},n.bind("change",(function(t){t.node=t.node||e,e.trigger("change",t)})),n.bind("error",(function(t){var n=e.parent();n&&(t.node=t.node||e,n.trigger("error",t))})),e._updateChildrenField())},isNew:function(){return this.fileManagerNewItem?(delete this.fileManagerNewItem,!0):this.id===this._defaultId}});var 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";var 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:t})=>e?`<span class="${e}"></span>`:""))},_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");var 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",h="open",u="error",p="change",f="close",m="dataBinding",g="dataBound",v="drop",_="execute",b="command",w="keydownAction",y="tree",k=".";var 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"};var 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"};var 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,h,m,g,u,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",togglable:!0,group:"changeView",command:"ChangeViewCommand",options:"grid"},{name:"listView",showText:"overflow",icon:"grid-layout",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(u,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(u,t._errorHandler).bind(p,t._changeHandler)},_error:function(e){this.trigger(u,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(h,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){var t=this.options.toolbar.items||this.defaultTools,n=!1;for(var 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[y],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[y](r,o,a),i.treeView.bind(c,i._navigate.bind(i)).bind("load",i._load.bind(i)).bind(v,i._drop.bind(i)).bind(w,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"];var 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(h,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"];var 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(h,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(!0),r.uploadDialog=new t.Dialog(s,l),r.uploadDialog.wrapper.addClass(x.uploadDialog),r.uploadDialog.element.append(i.wrapper),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(i=!1){var r=this,o=r.options,a=e("<input type='file' name='file'/>").addClass(x.upload),s=n(!0,{async:{autoUpload:!0,saveUrl:o.uploadUrl}},o.upload);return i||(s.dropZone=r.viewWrapper),r.upload=new t.Upload(a[0],s),r.upload.bind("upload",r._sendUploadPathParameter.bind(r)),r.upload.bind("success",r._success.bind(r)),r.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(h,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(w,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(h,{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();var n=t?t.id:"";this._navigate({path:n})},_buildBreadcrumbPath:function(e){var t=this.breadcrumb,n=[];for(;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(u,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",h=".",u=" ",p="vertical",f="tabindex",m="aria-current",g="aria-disabled",v="aria-invalid";var _="k-step",b="k-step-first",w="k-step-last",y="k-step-done",k="k-step-success",x="k-step-error",C="k-step-current",S="k-focus",T="k-disabled",M="k-step-link",A="k-step-indicator";var D="k-stepper",E="k-stepper-linear",I="k-step-list",z="k-step-list-horizontal",P="k-step-list-vertical";var L=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(h+M).append(t)},_label:function(){var e=n.template(this._labelTemplate)(this.options);this.element.find(h+M).append(e)},_link:function(){var e=this.options;this.element.find(h+M).empty(),this._linkAttributes(),e.indicatorVisible&&this._indicator(),e.labelVisible&&this._label()},_linkAttributes:function(){var e=this.options,t=this.element.find(h+M);t.removeAttr(g+u+v+u+m+u+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(M).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+=u+b),e.isLastStep&&(t+=u+w),e.enabled||(t+=u+T),e.error&&(t+=u+x),e.previous?(t+=u+y,e.error||(t+=u+k)):e.selected&&(t+=u+C,t+=u+S),this.element.removeClass().addClass(t)}});var B=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(h+I),t.options.orientation===p?t._stepList.addClass(P):t._stepList.addClass(z)},_attachEvents:function(){var e=this;e.wrapper.on(l+s,h+_,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(){if(this._steps){var e=this.options.orientation,t=this._steps.length,i=this._stepList,r=i.find(h+_),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 L(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(h+S),n=this.wrapper.find(h+M);e.length>0&&(t.removeClass(S),n.attr(f,"-1"),e.find(h+M).removeAttr(f)[0].focus())},_focusNextStep:function(){var t=e(document.activeElement).closest(h+_).next();this._focusStep(t)},_focusPreviousStep:function(){var t=e(document.activeElement).closest(h+_).prev();this._focusStep(t)},_focusFirstStep:function(){var e=this.wrapper.find(h+b);this._focusStep(e)},_focusLastStep:function(){var e=this.wrapper.find(h+w);this._focusStep(e)},_keydown:function(t){var n=this,i=t.keyCode,o=e(document.activeElement).closest(h+_).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(h+_))):t.preventDefault()},_leaveStepper:function(){var e=this.wrapper.find(h+C);this.wrapper.find(h+M).removeClass(S).attr(f,"-1"),e.addClass(S),e.find(h+M).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(h+_).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(h+_);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(h+M)[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(h+M)[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(h+_),o=r.index(),a=e(r.parent().find(h+_)[o+n]);this._focusStep(a),i&&this._selectHandlerOnKey(t,a)},_wrapper:function(){var e=this,t=e.element;e.wrapper=t,e.wrapper.addClass(D),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:L},n.ui.plugin(B)}(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";var h=i.extend({init:function(t,n){var r=this;i.fn.init.call(r,t,n),r.element=e(t).addClass(h.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=this;var i=n.options.containers;var r=n.element.children();var o=!!r.length;var a;var s;var l;var c;var u;var p;var f;if(n.items=[],n.itemsMap={},o)r.each((function(r,o){a=t.guid();var s=e(o).addClass(h.styles.item).attr({id:a,role:"listitem","aria-keyshortcuts":"Enter"});n._addContainer(s,i[r],r,a)}));else for(var m=0;m<i.length;m++){if(a=t.guid(),p=i[m],s=e("<div></div>").addClass(h.styles.item).attr({id:a,role:"listitem","aria-keyshortcuts":"Enter"}),(c=p.header)&&(c.template||c.text)&&(l=e("<div></div>").addClass(h.styles.itemHeader),n.options.reorderable&&l.addClass(d),f=c.text?"<div class='"+h.styles.itemHeaderTitle+"'>"+c.text+"</div>":null,l.append(f||t.template(c.template)({})),l.appendTo(s)),u=e("<div></div>").addClass(h.styles.itemBody),!p.bodyTemplate)throw new Error("Having a bodyTemplate for the container is mandatory");u.append(t.template(p.bodyTemplate)({})),u.appendTo(s),s.appendTo(n.element),n._addContainer(s,p,m,a)}},_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(){var e=this;for(var 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=parseFloat(e.css("borderRightWidth"));var o=parseFloat(e.css("borderBottomWidth"));var a=e.height();var s=e.width();var l=i?a-6.5-o:0;var c=n?s-4.5-r:0;var d=9;var h=9;var u;n&&i?(h=d=25,l-=12.5,c-=12.5,u=t.support.isRtl(this.element)?"k-cursor-nesw-resize":"k-cursor-nwse-resize"):n&&!i?(h=a,u="k-cursor-ew-resize"):!n&&i&&(d=s,u="k-cursor-ns-resize"),this.resizeHandle.css({top:l,left:c,height:h,width:d}).attr("side",n).attr("down",i).removeClass("k-cursor-nesw-resize k-cursor-nwse-resize k-cursor-ew-resize k-cursor-ns-resize").addClass(u).data("div",e).show()},_createResizeHint:function(t){if(!this.hint){var n=t.css("grid-column-end");var i=t.css("grid-row-end");var r=t.css("order");this.hint=e("<div class='"+h.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();var n=e.outerWidth();var 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);var 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=this;var o=e.attr("id");var a;r.options.resizable&&("horizontal"===n?(a=parseInt(e.css("grid-column-end").replace("span",""),10)+i,r.element.css("grid-template-columns").split(" ").length>=a&&a>0&&(r.itemsMap[o].colSpan=a,e.css({"grid-column-end":t.format("span {0}",a)}),r.trigger(s,{container:e}))):(a=parseInt(e.css("grid-row-end").replace("span",""),10)+i,r.element.css("grid-template-rows").split(" ").length>=a&&a>0&&(r.itemsMap[o].rowSpan=a,e.css({"grid-row-end":t.format("span {0}",a)}),r.trigger(s,{container:e}))))},_reorderItem:function(e,n){if(this.options.reorderable){var i=parseInt(e.css("order"),10);var 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);var 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;var n=t.element.children(":visible");(n=t._sortContainers(n)).each((function(){e(this).appendTo(t.element)}))},_resizable:function(){var t=this;var i;var r;var o;var l;var d;var u;var p=0;var f=0;var m=0;var g=0;var v=0;var _=0;var b=0;var w;t.options.resizable&&(t.element.on("mousemove"+c,a(h.styles.item),(function(n){var i;var r;var o=e(this);var a=o[0].getBoundingClientRect();i=Math.abs(a.right-n.clientX)<16,r=Math.abs(a.bottom-n.clientY)<16,i&&r?t._createResizeHandle(o,!0,!0):i?t._createResizeHandle(o,!0,!1):r&&t._createResizeHandle(o,!1,!0)})),t.resizable=new n.Resizable(t.element,{handle:"div.k-tilelayout-item > .k-resize-handle",start:function(n){var a=e(n.currentTarget);u=a.data("div"),o=u.attr("id"),i=a.attr("side"),r=a.attr("down"),w=t.element.css("grid-template-rows").split(" ").length,i&&(l=t._calculateFractionWidth(),b=t._calculateRightEndSide(l),p=n.x.location,m=u.width(),v=parseInt(u.css("grid-column-end").replace("span",""),10)),r&&(d=(t.element[0].scrollHeight-(w+1)*t.options.gap.rows)/w,f=n.y.location,g=u.height(),_=parseInt(u.css("grid-row-end").replace("span",""),10)),t._isresizing=!0},resize:function(e){var n=0;var a=0;var s=0;var c=0;var h;var w;var y=0;var k=0;var x=0;var C=t.element[0].getBoundingClientRect();var S=!!t.element[0].style.height;t._positionAbsolutely(u),t._createResizeHint(u),"true"==i&&(s=e.x.location-p,h=C.left+b-window.scrollX-e.x.location<t.options.gap.columns,w=m+s<l,h||w?s=0:(x=s/(l+t.options.gap.columns),y=s-Math.floor(x)*(l+t.options.gap.columns),n=v+Math.floor(x)+(y>=l/2?1:0),t.itemsMap[o].colSpan=Math.max(n,1))),"true"==r&&(c=e.y.location-f,h=C.bottom+window.scrollY-e.y.location<t.options.gap.rows,(w=g+c<=d)||h&&S?c=0:(k=c/(d+t.options.gap.rows),y=c-Math.floor(k)*(d+t.options.gap.rows),a=_+Math.floor(k)+(y>=d/2?1:0),t.itemsMap[o].rowSpan=Math.max(a,1))),t._positionHint(n,a),t._positionResizeHandle(u,"true"==i,"true"==r),c&&u.css("height",g+c),s&&u.css("width",m+s)},resizeend:function(){t._isresizing=!1,t._setContainerCoordinates(u,t.itemsMap[o]),t._removeAbsoluteStyles(u),t._removeResizeHint(),t.trigger(s,{container:u})}}))},_calculateFractionWidth:function(){var e=this;var t=e.element.children().first();var 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;var n=this.options.gap.columns;return t*(e+n)+n},_createDropHint:function(n){this.dropHint=e("<div class='"+h.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=this;var i=n.element;var o;var s=a(h.styles.item);var c=a(h.styles.itemHeader);var 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);var n=t.width();var i=t.height();var r=t.clone();return r.find(c).removeClass(d).addClass("k-cursor-grabbing"),r.width(n).height(i)},dragstart:function(t){o=e(t.currentTarget).closest(s),document.body.style.cursor="move"},drag:function(i){var r=t.elementUnderCursor(i);var a=i.sender.hint;var l;var c;var d;var p=n._draggableInstance.currentTarget.closest(s);var f;if(u(a[0],r)){if(a.hide(),r=t.elementUnderCursor(i),!u(o[0],r)){if(n.dropHint&&n.dropHint[0]==r[0])return void a.show();if((l=(l=e(r)).hasClass(h.styles.item)?l:l.closest(s)).hasClass(h.styles.item))if(c=l[0].getBoundingClientRect(),d=i.clientX-c.left>c.right-i.clientX?"right":"left",f=l.css("order"),n.dropHint&&n.dropHint.attr("direction")!==d){var m=n.dropHint.clone();m.css("order",f),n.dropHint.remove(),n.dropHint=m,n._insertDropHint(l,d),n.dropHint.attr("direction",d).attr(t.attr("index"),f)}else if(!n.dropHint){("right"==d?l.next():l.prev())[0]!=o[0]&&(n._createDropHint({order:f,columnEnd:p.css("grid-column-end"),rowEnd:p.css("grid-row-end"),direction:d}),o.hide(),n._insertDropHint(l,d))}}a.show()}},dragend:function(e){if(document.body.style.cursor="auto",!n.dropHint)return e.sender.hint.remove(),void n._removeDropHint();var i=parseInt(n.dropHint.css("order"),10);var r=e.currentTarget.closest(s);var o=n.element.find(s);var a=parseInt(r.css("order"),10);var c=r.attr("id");var d=n.element.children(":visible");var h;var u;var p;var f;i=(d=n._sortContainers(d)).index(n.dropHint[0]),u=Math.max(i,a),h=Math.min(i,a),n.itemsMap[c].order=i,"left"==(f=i>a?"right":"left")?u--:h++;for(var m=h;m<=u;m++)p=o.filter("["+t.attr("index")+"='"+m+"']"),n.itemsMap[p.attr("id")].order+="left"==f?1:-1;r.show(),n._updateContainers(),e.sender.hint.remove(),n._removeDropHint(),n.options.navigatable&&n._updateDOM(),n.trigger(l,{newIndex:i,oldIndex:a,container:r})},dragcancel:function(){document.body.style.cursor="auto",n._removeDropHint(),o&&o.show()}}),i.find(s).kendoDropTarget({group:p,dragenter:function(t){if(!n._isresizing){var i=e(t.dropTarget);var r=n._draggableInstance.currentTarget.closest(s);var a;var l;if(o[0]!=i[0]){if(a=i[0].getBoundingClientRect(),("right"==(l=t.clientX-a.left>a.right-t.clientX?"right":"left")?i.next():i.prev())[0]==o[0])return;n._removeDropHint(),o.hide(),n._createDropHint({order:i.css("order"),columnEnd:r.css("grid-column-end"),rowEnd:r.css("grid-row-end"),direction:l}),o.hide(),n._insertDropHint(i,l)}}}})}}});function u(t,n){try{return e.contains(t,n)||t==n}catch(e){return!1}}n.plugin(h),e.extend(!0,h,{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",h="submit",u="previous",p="next",f="done",m="error",g="contentLoad",v="formValidateFailed",_="k-hidden",b="k-step-link",w="aria-selected",y="aria-hidden",k="aria-label",x="bottom",C="right",S="left",T=".",M="id",A="role",D="data-wizard-";var E="k-wizard",I="k-wizard-horizontal",z="k-wizard-vertical",P="k-wizard-right",L="k-wizard-left",B="k-wizard-steps",H="k-wizard-step",R="k-wizard-content",F="k-wizard-buttons",O="k-wizard-buttons-left",V="k-wizard-buttons-right",N="k-wizard-pager";var $=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,u,p],last:[d,u,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+F);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;var 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+R);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(M,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(D+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",h),this._buttons.push(n)},_buttonsContainer:function(){var t=e("<div>").addClass(F);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(R);!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(R),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(H),this.options.className&&this.element.addClass(this.options.className),this._ariaAttributes(),this.options.selected||(this.element.addClass(_),this.element.attr(y,!0)),this.options.actionBar&&this._buttonsContainer(),this.options.form?this._form():this._content()}});var 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)},setOptions:function(e){var t=this;t.destroy(),t.wrapper.empty(),n.deepExtend(t.options,e),t.init(t.element,e)},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,h=e(this.element.find(T+H).get(i)),u=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],h.hasClass(_)||(r=0===i?0:i-1,this.select(r)),n.destroy(h),h.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=u.step+" "+(a+1)+" "+u.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,"["+D+d+"]",e._resetClickHandler.bind(e)).on(s+a,"["+D+u+"]",e._previousClickHandler.bind(e)).on(s+a,"["+D+p+"]",e._nextClickHandler.bind(e)),e.wrapper.is("form")?(e.wrapper.on(s+a,"["+D+f+"]",t),e.wrapper.on(h+a,e._doneHandler.bind(e))):(e.wrapper.on(s+a,"["+D+f+"]",t),e.wrapper.on(s+a,"["+D+f+"]",e._doneHandler.bind(e)))},_changeStep:function(e){var t=this.wrapper.find(T+H);this.currentStep=e,t.addClass(_),t.attr(y,!0),e.element.removeClass(_),e.element.removeAttr(y)},_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(M)&&(t.wizardId=a.attr(M)),!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(B),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+B);0===e?n.prepend(t):n.find(T+H+":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+R)))?(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(w,!1),n.attr(w,!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(M)||"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(w,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(w,!1),r.element.find(T+b).attr(w,!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+" "+L):e.wrapper.addClass(I)}});n.wizard={Step:$},n.ui.plugin(U)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=e.extend,i=t.Class,r=".k-imageeditor-pane";var 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 h=function(e){return Math.round(1e3*e)/1e3};var u=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}});var p=u.extend({init:function(e){var t=this;u.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(){var n=this,i=n.imageeditor,r=n.imageeditor.canvasContainer,o=e("<div></div>").addClass(a),d=e("<div></div>").addClass(s),h="<span class='"+l+"'></span>",u=["nw","n","ne","w","e","sw","s","se"],p=i.getZoomLevel();for(var f=0;f<u.length;f++){var m=e(h).addClass(c+u[f]).attr("data-orientation",u[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);var v=Math.round(n._model.height*p);var _=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 h=n({},o,{width:o.height,height:o.width});var u=i._calcSize(h,c,s,l);o.set("width",u.width),o.set("height",u.height),i._orientationWidget.select("portrait"===e.value?0:1)}else if(o.lockAspectRatio){var p=e.field;var 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);var g=Math.round(o.height*r);var v=Math.round(o.top*r);var _=Math.round(o.left*r);var 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]);var d=s?Math.max(l[0],l[1]):Math.min(l[0],l[1]);var u=h(c/d);var p=h(o/a);var f={width:Math.round(a*u),height:Math.round(o/u)};return"width"===r?{width:o,height:f.height}:"height"===r?{width:f.width,height:a}:(p>u?o=f.width:p<u&&(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(),u.fn.destroy.call(this)}});var f=u.extend({init:function(e){u.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:" ",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:" ",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:h(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",h(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:u,panes:{crop:p,resize:f}}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.imageeditor,i=e.extend;var r=t.Class.extend({init:function(e){this.options=i({},e,this.options),this.imageeditor=e.imageeditor}});var 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")}});var 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}}});var 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)}))}});var 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)}))}});var 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)})))}});var 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)})))}});var h=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")}});var u=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:h,OpenImageEditorCommand:u}})}(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",h="execute",u=e=>`<canvas role='img' aria-label='${e}'>Canvas element</canvas>`;var 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";var w=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,h],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;var 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;var r=e(t.template(u)(i.options.imageLabel))[0];var 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(h,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(w)}(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",h="required";var u=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=h,e.prop(h,!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(u)}(window.kendo.jQuery);kendo;!function(){var e=window.kendo,t=e.ui,n=t.ToggleInputBase;var 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";var 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";var 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=".",h="select";var u=function(e){return"string"==typeof e};var 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"};var f={item:o((()=>`<span class="${p.item}"></span>`)),anchor:o((({url:e})=>`<a class="${p.item}" href="${t.sanitizeLink(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"})))};var 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:[h],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(u(n[t])){for(var i in n)e.removeClass(n[i]);e.addClass(n[t])}},_items:function(){var e,t=this,n=t.options.items;for(var 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&&u(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(h,{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=t.Observable,r=t.htmlEncode,o=e.extend,a=".",s=".kendoTaskBoardColumn",l="click",c="action";var d={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"};const h=function(e){return{"-webkit-user-select":e?"none":"","-moz-user-select":e?"none":"","-ms-user-select":e?"none":"","user-select":e?"none":""}};function u(e){e.preventDefault()}var p=i.extend({init:function(e,t){var n=this;n._dataItem=t,n.options=o(!0,{},e),n.sortableUniqueClass=n.options.sortableIdentifier+p.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=p.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=p.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=p.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=p.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(){var n=this,i=n.options,r=i.messages,a=i.buttons||n.defaultButtons,s=p.styles,l="<div class='"+s.actions+"'>";for(var 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+p.styles.actionButton,e._actionClick.bind(e)),e.header.on("blur"+s,a+p.styles.input,e._textboxBlur.bind(e)),e.header.on("keyup"+s,a+p.styles.input,(function(n){n.keyCode===t.keys.ENTER&&e._textboxBlur(n)})),e.container&&(e.container.on(l+s,a+p.styles.card+" ["+t.attr("command")+"]",e._actionClick.bind(e)),e.container.on(l+s,a+p.styles.card+" a."+p.styles.cardTitle,u))},_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+p.styles.ignoreDrag+" *",connectWith:a+t.sortableUniqueClass,filter:a+p.styles.card,hint:function(e){return e.clone().addClass(p.styles.dragHint+" "+p.styles.grabbingCursor+i).css({width:e[0].offsetWidth,height:e[0].offsetHeight,...h(!0)})},placeholder:function(t){return e("<div></div>").addClass(p.styles.dragPlaceholder+" "+d.card).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){var n=p.ignoreDragSelectors;var i=e(t.event.target);for(var 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+p.styles.element)}),this.trigger("move",e)},_start:function(e){o(e,{columnElement:e.sender.element.parents(a+p.styles.element)}),this.trigger("moveStart",e),this.element.closest(".k-taskboard").css(h(!0))},_end:function(e){const t=this;let n={command:"MoveCardCommand",options:e};o(e,{columnElement:e.sender.element.parents(a+p.styles.element)}),this.trigger("moveEnd",e),this.element.closest(".k-taskboard").css(h(!1)),"receive"===e.action&&e.newIndex>=0&&t.trigger(c,n)?e.preventDefault():"sort"===e.action&&e.newIndex!==e.oldIndex&&(n.options.newIndex+=1,t.trigger(c,n))},_change:function(e){o(e,{columnElement:e.sender.element.parents(a+p.styles.element)}),this.trigger("change",e)},destroy:function(){var e=this;e.header.off(s),e.container.off(s),e.sortable&&e.sortable.destroy()}});var f=p.extend({_render:function(){var n=this,i=p.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:p,NewColumn:f}}),o(!0,t.ui.taskboard.Column,{styles:d,ignoreDragSelectors:["img"]})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Observable,i=t.htmlEncode,r=e.extend;var 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:"",h=i._resources(i._dataItem),u=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=h[a.dataCategoryField]&&h[a.dataCategoryField].color||i._dataItem.get(a.dataCategoryField))&&c.addClass(s.categoryBorder).css(u,n),c.append(t.template(l)(r(!0,{},{styles:s,cardMenuButton:t.template(d)({styles:s}),selectable:a.states.isSelectable,resources:h,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];var a=o.field;var s=t.getter(a)(e);if(s){o.multiple||(s=[s]);var l=o.dataSource.view();for(var c=0;c<s.length;c++){var d=null;var h=s[c];o.valuePrimitive||(h=t.getter(o.dataValueField)(h));for(var u=0;u<l.length;u++)if(l[u].get(o.dataValueField)==h){d=l[u];break}if(null!==d){var p=t.getter(o.dataColorField)(d);var f={field:o.field,title:o.title,name:o.name,text:t.getter(o.dataTextField)(d),value:h,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";var 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;var 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}});var 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())}});var 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))}});var 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())}))}});var 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())}});var c=r.extend({exec:function(){this.taskboard.columnsDataSource.cancelChanges()}});var 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)}}});var h=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 h=l+1;h<c.length&&(n=c[h]).get(r)<=a.get(r);h++)n.set(r,a.get(r)+1),a=n}});var u=r.extend({exec:function(){var e=this.taskboard,t=this.options.cardElement;e._select(t,!0),t.focus()}});var p=h.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")}))))}});var 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")}))}});var m=h.extend({exec:function(){var e=this,t=e.taskboard,n=t.options,i=n.columnSettings,r=e.options,o=r.column,a=r.card,s=r.newIndex,l=o.get(i.dataStatusField);a.set(n.dataStatusField,l),n.dataOrderField&&e._updateOrder(t._getColumn(l),s),t.dataSource.sync()}});var g=r.extend({exec:function(){var e=this.taskboard,t=this.options;e.trigger("editCard",{card:t.card})||e._openPane(n({pane:"Edit"},t))}});var 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)))}});var _=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})}});var b=r.extend({exec:function(){var e=this.taskboard;e._closePane(),e.dataSource.cancelChanges()}});var w=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:u,MoveFocusCommand:d,SaveChangesCommand:p,DeleteCardCommand:f,MoveCardCommand:m,EditCardCommand:g,AddCardCommand:v,SearchCommand:w}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.Observable,r=t.htmlEncode,o=t.ui.Form,a=".kendoTaskBoardPane";var 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];var a=o.field;var s=t.getter(a)(e);if(s){o.multiple||(s=[s]);var l=o.dataSource.view();for(var c=0;c<s.length;c++){var d=null;var h=s[c];o.valuePrimitive||(h=t.getter(o.dataValueField)(h));for(var u=0;u<l.length;u++)if(l[u].get(o.dataValueField)==h){d=l[u];break}if(null!==d){var p=t.getter(o.dataColorField)(d);var f={field:o.field,title:o.title,name:o.name,text:t.getter(o.dataTextField)(d),value:h,color:p};o.multiple?i[o.field]?i[o.field].push(f):i[o.field]=[f]:i[o.field]=f}}}}return i},_buildButtonsHtml:function(){var i=this,r=i.options,o=r.messages,a=r.buttons||i.defaultButtons,l=s.styles,c="";for(var d=0;d<a.length;d++){var h=a[d];if("string"==typeof(h=e.isPlainObject(h)&&1===Object.keys(h).length&&h.name?h.name:h)){if("spacer"===h){c+='<span class="k-spacer"></span>';continue}h=n(!0,{},i.builtinButtons[h]||{spriteCssClass:h,command:h+"Command"},{text:o[h]||h})}else e.isPlainObject(h)&&h.name&&(h=n(!0,h,{text:o[h.name]}));i._validateRules(h)&&(h.spriteCssClass=h.spriteCssClass||"",c+=t.template(i.buttonTemplate)(n(!0,{},{styles:l,messages:o,primary:!1,options:null},h)))}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()}});var 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"]});var 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),h=!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:h}))}});var 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 h in(i=e.dataSource.add()).set(t.dataStatusField,l),d)i.set(h,d[h]);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";var 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 XO={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"};var ZO=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=".",h="move",u="moveStart",p="moveEnd",f="select",m="execute",g="action",v="change",_="change",b="dataBinding",w="dataBound",y="columnsDataBinding",k="columnsDataBound";var 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:[h,u,p,v,m,f,b,w,y,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){var t=this.options.toolbar.items||this.defaultTools,n=!1;for(var 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,h=i.draggableEvent?i.item:i.target;return i.card&&(h=c.items().filter((function(t,r){return e(r).attr(n.attr("uid"))===i.card.get("uid")}))),h&&h&&h.length?(r=i.columnElement||(h.is(d+x.styles.column)?h:h.parents(d+x.styles.column)),s=c.columnsDataSource.getByUid(r.data(n.ns+"uid")),a=h.is(d+x.styles.card)?h:h.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(y,e))){n._progress(!0),n._columns={},n.columnsContainer.html("");for(var l=0;l<i.length;l++){var d=i[l];var f=d[s]||c;var m;m=n._columns[f]=new a.taskboard.Column(r,d),n.columnsContainer.append(m.element),m.bind(g,n.executeCommand.bind(n)),m.bind(h,n._move.bind(n)),m.bind(p,n._moveEnd.bind(n)),m.bind(u,n._moveStart.bind(n)),m.bind(v,n._changeOrder.bind(n)),n._tabindex(m.element)}"sync"!==e.action&&e.action!==t||n._renderCards(n.dataSource.view()),n._progress(!1),n.trigger(k,e)}},_move:function(e){this.trigger(h,this._extendExecArgs(e))},_moveEnd:function(e){this.trigger(p,this._extendExecArgs(e))},_moveStart:function(e){this.trigger(u,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(w,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(){var e=this.options.resources;for(var 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:ZO}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:"a",ctrlKey:!0},{command:"AddCardCommand",handler:ZO}),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:ZO})),t.isSelectable&&e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.ENTER},{command:"SelectCardCommand",handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.UP},{command:"MoveFocusCommand",options:{value:"up"},handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.DOWN},{command:"MoveFocusCommand",options:{value:"down"},handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.LEFT},{command:"MoveFocusCommand",options:{value:"left"},handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.RIGHT},{command:"MoveFocusCommand",options:{value:"right"},handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.LEFT},{command:"MoveFocusCommand",options:{value:"left"},handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.RIGHT},{command:"MoveFocusCommand",options:{value:"right"},handler:ZO}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.DOWN},{command:"MoveFocusCommand",options:{value:"down"},handler:ZO})},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:XO})}(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",h="error";var u=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,h],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=u.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=u.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(h,{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=u.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=u.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=u.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,h=d._error.bind(d,t),u=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(u).fail(h))},_requestEnd:function(e,t){this.trigger(d,{type:e,data:t})},_error:function(e,t,n,i){this.trigger(h,{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=u.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="'+u.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(u.styles.loading,e),t._inputWrapper.toggleClass(u.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(u.styles.disabled,!e),t.wrapper.toggleClass(u.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(u),i(!0,u,{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;var 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";var r=n.name||"name";var o=n.title||"title";var 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={field:"parentId",operator:"eq",value:null};var o=this._sort&&this._sort.length?this._sort:{};var a,s;if(s=n?this.view():this.data(),e){if((a=e.get("id"))===t||null===a||""===a)return[];i.value=a}return s=new r(s).filter(i).sort(o).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",h=".",u=" ",p="#",f="tabindex",m="uid",g="px",v="plus",_="minus",b="aria-owns",w="aria-selected";var y="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",M="k-orgchart-group-v",A="k-orgchart-group-h",D="k-orgchart-node-group",E="k-orgchart-node-group-container",I="k-orgchart-node-container",z="k-orgchart-node",P="k-orgchart-card",L="k-orgchart-card-menu",B="k-orgchart-button",H="k-focus",R=".k-i-plus,.k-svg-i-plus",F="k-vstack",O="k-hstack";var 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>`;var 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>`;var $=({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">`};var U=({label:e,buttonSign:n})=>t.html.renderButton(`<button aria-label="${i(e)}" tabindex="-1" class="k-orgchart-button"></button>`,{icon:i(n)});var 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>"};var 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>`};var 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>`;var 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(h+E)),t&&t.length?t:null}},jqueryItemElement:function(e){if(e){var t=this._processItem(e);return t.hasClass(P)||(t=t.closest(h+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(H).attr(w,!1),t.attr(f,"0").addClass(H).trigger("focus").attr(w,!0))},_attachEvents:function(){var e=h+P+","+h+E;this.element.on("keydown"+o,e,this._onKeyDown.bind(this)).on(a+o,e,this._onSelect.bind(this)).on(a+o,h+B,this._onButtonClick.bind(this)).on("focus"+o,e,this._onFocus.bind(this)).on("blur"+o,h+H,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(H)?this._shouldRestoreSelection=!0:this._shouldRestoreSelection=!1)},_calculateDimensions:function(){var e=this.element.find(h+this._selector).first();this._buttonHeight||(this._buttonHeight=this.element.find(h+B).first().outerHeight()),this._spacing||(this._spacing=this.element.find(h+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(h+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(h+P).first();this.element.find("[tabindex=0]")[0]!==e[0]&&this.trigger(d,{item:e,dataItems:[this._dataItem(e)]})},_onBlur:function(){this.element.find(h+H).removeClass(H)},_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(R).length>0,a=r.siblings(h+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(h+y).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,h=this.options.cardsColors||t.getSeriesColors(),u=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:h[a-1]||h[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:h[a-1]||h[0]}))),c.append(l),u.append(c),t.applyStylesFromKendoAttributes(u,["border-color"]),u},_renderGroup:function(){return!1},_restoreSelection:function(){var e,t;this._idTabIndex?((t=(e=this.dataSource.get(this._idTabIndex))?this._getToFocus(e):this.element.find(h+this._selector).first()).attr(f,"0"),this._idTabIndex=null):(t=this.element.find(h+this._selector).first()).attr(f,"0"),this._shouldRestoreSelection&&(this._shouldRestoreSelection=!1,this._preventTriggerSelect=!0,t.trigger("focus"),t.addClass(H))},_setHeight:function(){var t,n=this._selector,i=this.element.find(h+B+","+h+n),r=Number.MAX_VALUE,o=0;this._calculateDimensions(),t=this._buttonHeight,this.element.find(h+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)}});var 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(h+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(h+T).hasClass(M)},_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(h+L).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(h+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(h+z).find(h+P),i=this.element.find(p+e.attr(b));!n.length&&t.hasChildren&&t.expanded&&(n=i.find(h+P).first()),0===n.length||n.hasClass(H)||this.trigger(d,{item:n,dataItems:[this._dataItem(n)]})},_keyPrev:function(e){var t,n=this._dataItem(e),i=e.parent().prev(h+z).find(h+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(H)||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(L)){if(i.closest("[tabindex='0']").length>0)return void t.stopPropagation();this._preventTriggerSelect=!0}n.hasClass(P)||(n=n.closest(h+P)),n.hasClass(H)||this.trigger(d,{item:n,dataItems:[this._dataItem(n)]})},_onSelect:function(t){var n=e(t.currentTarget),i=n.hasClass(P)?n:n.closest(h+P);(e(t.target).hasClass(L)?e(t.target):e(t.target).closest(h+L)).length>0||n.hasClass(H)||this.trigger(d,{item:i,dataItems:[this._dataItem(i)]})},_orientation:function(t,n,i){var r=e("<div>").addClass(k+u+x);i&&n>1?(t.addClass(M+u+F),t.find(h+I).addClass(F),0===t.find(h+B).length||1===t.find(h+P).length?(t.find(h+P).before(r.clone()),t.find(h+z).first().find(h+x).addClass(S)):n>1&&t.find(h+P).first().before(r.clone())):(t.addClass(A+u+O),t.find(h+I).addClass(O),n>1&&t.find(h+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,w,y=t.template(U),S=t.template(j),T=o/i.length,M=!0,D=e("<div>").addClass(k+u+x),E=e("<div>").addClass(k+u+C),I=this.options.messages;for(w=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,w,l,r,c),l.hasChildren&&(d.append(D.clone()),p=e(y({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&&(M=!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&&!M&&n.find(h+z).width((T-1)*(b+m)),M},_renderInnerGroup:function(n,i,r,o,a,s){var l,c=this._itemWidth,d=this._spacing,h=i*c+(i-1)*d,u=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&&(u+=o*i*d),(l=e(p({guid:s,level:a+1}))).css({width:h+g,top:m+g}),l.css(f,u+g),this.element.append(l),this._renderGroup(l,n.children,a+1,i,u),l}});var 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(h+P).each((function(e,t){(n=i.getByUid(t.getAttribute("data-uid")))&&r.push(n)}))),r},_calculateItemWidth:function(){var e=this.element.find(h+this._selector).first();return this.element.find(h+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(h+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(h+I).hasClass(F)},_keyCollapse:function(e){var t,n=[];(n=this._dataItems(e)).some((function(e){return e.expanded}))?(e.hasClass(P)&&(e=e.closest(h+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(h+this._selector),dataItems:n}))},_keyEnter:function(e){var t,n=[];e.hasClass(P)&&e.find(h+L).length>0?this.trigger(c,e):(t=e.find(h+P).first(),n=this._dataItems(t),this.trigger(d,{item:t,dataItems:n}))},_keyEscape:function(e){if(e.hasClass(P)){var t=e.closest(h+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(h+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(h+this._selector).first(),this.trigger(d,{item:i,dataItems:this._dataItems(i)})):(e.hasClass(P)&&(e=e.closest(h+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(h+z).find(h+P):e.parent().next(h+D).find(h+E)).length&&r&&o&&(t=n.find(h+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(h+z).find(h+P):e.parent().prev(h+D).find(h+E)).length&&i[0].parentId&&(t=this.dataSource.get(i[0].parentId).get(m),n=this.element.find("[data-uid='"+t+"']").closest(h+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(L)){if(r.closest("[tabindex='0']").length>0)return void t.stopPropagation();this._preventTriggerSelect=!0}r.hasClass(P)||r.hasClass(E)||((i=r.closest(h+P)).length||(i=r.closest(h+E)),r=i),0!==r.length&&(n=this._dataItems(r),r.hasClass(H)||(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(h+P)).length||(i=r.closest(h+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+u+x+u+S);t.addClass(O),n>1&&t.find(h+E).before(r.clone()),i&&n>1?(t.find(h+I).removeClass(O),t.find(h+I).addClass(F)):t.addClass(A)},_renderChildren:function(n,i,r,o,a,s,l){var c,d,h,p,f,m,b,w=t.template(U),y=t.template(N),S=e("<div>").addClass(k+u+x),T=e("<div>").addClass(k+u+C),M=this.options.messages,A=!0,D=t.support.isRtl(this.element)?"right":"left";return n.hasChildren&&(A=!1,a.append(S.clone()),d=e(w({buttonSign:n.expanded?_:v,label:n.expanded?M.collapse:M.expand})),a.append(d),this._calculateDimensions(),m=this._itemWidth,b=this._spacing,n.expanded&&(f=m*r+(r-1)*b,h=i*r*m+s,p=o*(this._itemHeight+this._buttonHeight+b)+b*(o-1)-this._buttonHeight/2,i>0&&(h+=i*r*b),(c=e(y({guid:l,level:o+1}))).css({width:f+g,top:p+g}),c.css(D,h+g),this.element.append(c),this._renderGroup(c,n.children,o+1,r,h))),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,u,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(h+D),this._renderItems(s,p.items,i,d),u=this._renderChildren(p,c,m,i,l,a,d),f&&(f=u);var g=this._itemWidth*m+(m-1)*this._spacing;e.find(h+D).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",h="collapse",u="create",p="dataBinding",f="dataBound",m="delete",g="edit",v="error",_="expand",b="progress",w="save",y="select",k="requestStart",x=".";var C="k-orgchart",S="k-orgchart-group",T="k-orgchart-node-group",M="k-orgchart-node",A="k-orgchart-card",D="k-orgchart-card-menu",E="k-focus",I="k-item",z="k-orgchart-avatar-preview",P="k-orgchart-update",L="k-orgchart-cancel";var B=({edit:e})=>`<li data-action='edit'>${n(e)}</li>`,H=({create:e})=>`<li data-action='create'>${n(e)}</li>`,R=({destroy:e})=>`<li data-action='destroy'>${n(e)}</li>`;var F=({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>";var 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>";var 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,h,u,p,f,m,g,_,"kendoKeydown",w,y],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(F)(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+D,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+=B(e),n+=H(e),n+=R(e)):((t.fields||t.parent)&&(n+=B(e)),t.create&&(n+=H(e)),t.destroy&&(n+=R(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&&(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._form=new t.ui.Form(o,c),r._editWindow.wrapper.on(d,x+P,(function(){r._form.validate()&&(i=!0,r.trigger(w,{dataItem:n})||(r._editWindow.close(),r.saveChanges()))})),r._editWindow.wrapper.on(d,x+L,(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+M).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===u?i.trigger(u,{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+D))},_progress:function(e){t.ui.progress(this.container,e)},_triggerCollapse:function(e){this.trigger(h,{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(y,{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];var r=n.rawFile;var 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(y,this._triggerSelect.bind(this)),this.view.bind(_,this._triggerExpand.bind(this)),this.view.bind(h,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>",h="show",u="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"}};var _=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:[h,u],_addAria:function(){var e=this;var n=e.options;var i;e._isShownOnClick()&&e.wrapper.find("a,input,select,textarea,button").length?(e.wrapper.attr("role","dialog"),e._isDialog=!0,n.header&&(i=t.guid(),e.wrapper.attr("aria-labelledby",i).find(".k-popover-header").attr("id",i)),n.body&&(i=t.guid(),e.wrapper.attr("aria-describedby",i).find(".k-popover-body").attr("id",i))):e.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;var r=i.options.actions;var o=e(n.currentTarget);var 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){var n="";var i;for(var r=0;r<e.length;r++)(i=e[r]).text&&(i.icon||i.iconClass)?n+=t.template(l)({text:i.text,index:t.attr("index")+"="+r,icon:i.icon,iconClass:i.iconClass}):!i.icon&&!i.iconClass||i.text?n+=t.template(s)({text:i.text,index:t.attr("index")+"="+r}):n+=t.template(c)({index:t.attr("index")+"="+r,icon:i.icon,iconClass:i.iconClass});return n}},_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");var i=n.first();var 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(h),i.popup._hovered=undefined},close:function(e){i.options.toggleOnClick&&i._shown?e.preventDefault():i.trigger(u)},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;const JO="arc";const eV="ArrowUp";const tV="ArrowDown";const nV="ArrowLeft";const iV="ArrowRight";const rV="aria-activedescendant";const oV="axisLabelClick";const aV="#000";const sV="bottom";const lV="center";const cV="circle";const dV="cross";const hV="date";const uV="12px sans-serif";const pV=10;const fV=600;const mV="end";const gV="Enter";const vV="Escape";const _V=/\{\d+:?/;const bV="height";const wV="inside";const yV="inherit";const kV="left";const xV=Number.MAX_VALUE;const CV=-Number.MAX_VALUE;const SV="none";const TV="noteClick";const MV="noteHover";const AV="noteLeave";const DV="object";const EV="outside";const IV="right";const zV="roundedRect";const PV="start";const LV="string";const BV="top";const HV="triangle";const RV="square";const FV="rect";const OV="value";const VV="#fff";const NV="width";const $V="x";const UV="y";const WV="pointer";const jV="horizontal";const qV="vertical";var GV=Object.freeze({__proto__:null,ARC:JO,ARIA_ACTIVE_DESCENDANT:rV,ARROW_DOWN:tV,ARROW_LEFT:nV,ARROW_RIGHT:iV,ARROW_UP:eV,AXIS_LABEL_CLICK:oV,BLACK:aV,BOTTOM:sV,CENTER:lV,CIRCLE:cV,COORD_PRECISION:3,CROSS:dV,DATE:hV,DEFAULT_FONT:uV,DEFAULT_HEIGHT:400,DEFAULT_PRECISION:pV,DEFAULT_SERIES_OPACITY:1,DEFAULT_WIDTH:fV,END:mV,ENTER:gV,ESCAPE:vV,FORMAT_REGEX:_V,HEIGHT:bV,HIGHLIGHT_ZINDEX:100,HORIZONTAL:jV,INHERIT:yV,INSIDE:wV,LEFT:kV,MAX_VALUE:xV,MIN_VALUE:CV,NONE:SV,NOTE_CLICK:TV,NOTE_HOVER:MV,NOTE_LEAVE:AV,OBJECT:DV,OUTSIDE:EV,POINTER:WV,RECT:FV,RIGHT:IV,ROUNDED_RECT:zV,SQUARE:RV,START:PV,STRING:LV,TAB:"Tab",TOP:BV,TRIANGLE:HV,VALUE:OV,VERTICAL:qV,WHITE:VV,WIDTH:NV,X:$V,Y:UV});function KV(e){return Array.isArray(e)}function YV(e,t){const n=KV(t)?t:[t];for(let t=0;t<n.length;t++){const i=n[t];-1===e.className.indexOf(i)&&(e.className+=" "+i)}}const QV=/\s+/g;function XV(e,t){e&&e.className&&(e.className=e.className.replace(t,"").replace(QV," "))}function ZV(e){let t=.5;e.options.stroke&&So(e.options.stroke.width)&&e.options.stroke.width%2==0&&(t=0);for(let n=0;n<e.segments.length;n++)e.segments[n].anchor().round(0).translate(t,t);return e}function JV(e,t){return-e.x*t.y+e.y*t.x<0}function eN(e){return"number"==typeof e&&!isNaN(e)}function tN(e){return typeof e===LV}function nN(e){return eN(e)||tN(e)&&isFinite(e)}function iN(e,t){return(e+1)%t}function rN(e,t){let n=e-1;return n<0?t-1:n}function oN(e,t){return 1===t||e%t==0?0:e<0?t+e%t:e>=t?e%t:e}function aN(e){return"function"==typeof e}const sN="object";function lN(e,t){for(let n in t){if("__proto__"===n||"constructor"===n)continue;let i=t[n];let r=typeof i;let o;if(o=r===sN&&null!==i?i.constructor:null,o&&o!==Array)if(i instanceof Date)e[n]=new Date(i.getTime());else if(aN(i.clone))e[n]=i.clone();else{let t=e[n];e[n]=typeof t===sN&&t||{},lN(e[n],i)}else"undefined"!==r&&(e[n]=i)}return e}function cN(e){const t=arguments.length;for(let n=1;n<t;n++)lN(e,arguments[n]);return e}function dN(e){return"object"==typeof e}function hN(e){return eN(e)?e+"px":e}const uN=/width|height|top|left|bottom|right/i;function pN(e){return uN.test(e)}function fN(e,t){const n=tN(t)?[t]:t;if(KV(n)){const t={};const i=window.getComputedStyle(e);for(let e=0;e<n.length;e++){let r=n[e];t[r]=pN(r)?parseFloat(i[r]):i[r]}return t}if(dN(t))for(let n in t)e.style[n]=hN(t[n])}function mN(e,t=0){const n={top:0,right:0,bottom:0,left:0};return"number"==typeof e?n[BV]=n[IV]=n[sV]=n[kV]=e:(n[BV]=e[BV]||t,n[IV]=e[IV]||t,n[sV]=e[sV]||t,n[kV]=e[kV]||t),n}let gN={compile:function(e){return e}};let vN=class{static register(e){gN=e}static compile(e,t){return gN.compile(e,t)}};function _N(e={}){let t;return e.template?e.template=t=vN.compile(e.template):aN(e.content)&&(t=e.content),t}function bN(e={}){let t;return e.ariaTemplate?e.ariaTemplate=t=vN.compile(e.ariaTemplate):aN(e.ariaContent)&&(t=e.ariaContent),t}const wN=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;const yN={};function kN(e){if(yN[e])return yN[e];const t=[];return e.replace(wN,(function(e,n,i,r){t.push(void 0!==n?n:i||r)})),yN[e]=function(e){let n=e;for(let e=0;e<t.length&&n;e++)n=n[t[e]];return n},yN[e]}yN[void 0]=function(e){return e};const xN=(e,t)=>e.filter(t);function CN(e,t){if(e.className){const n=t.split(" ");for(let t=0;t<n.length;t++)if(e.className.indexOf&&-1!==e.className.indexOf(n[t]))return!0}}class SN{constructor(){this._map=new Map}get(e){return this._map.get(e)}set(e,t){this._map.set(e,t)}}function TN(e,t){if(t)return t.includes(e)}function MN(e,t,n){return Wo(e+(t-e)*n,3)}const AN="trigger";class DN{constructor(e,t){this.observer=e,this.handlerMap=cN({},this.handlerMap,t)}trigger(e,t){const{observer:n,handlerMap:i}=this;let r;return i[e]?r=this.callObserver(i[e],t):n[AN]&&(r=this.callObserver(AN,e,t)),r}callObserver(e,...t){return this.observer[e].apply(this.observer,t)}requiresHandlers(e){if(this.observer.requiresHandlers)return this.observer.requiresHandlers(e);for(let t=0;t<e.length;t++)if(this.handlerMap[e[t]])return!0}}function EN(e){return"[object Object]"===Object.prototype.toString.call(e)}function IN(e,t){const n=e.length;const i=[];for(let r=0;r<n;r++){let n=t(e[r]);So(n)&&i.push(n)}return i}const zN=io.browser||{};function PN(e){let t=0;return e.wheelDelta?(t=-e.wheelDelta/120,zN.webkit&&(t/=2*Math.max(window.devicePixelRatio,.625))):e.detail&&(t=e.detail/3),t=t>0?Math.ceil(t):Math.floor(t),t}const{append:LN,bindEvents:BN,defined:HN,deg:RN,elementOffset:FN,elementSize:ON,eventCoordinates:VN,eventElement:NN,hashKey:$N,last:UN,limitValue:WN,objectKey:jN,rad:qN,round:GN,unbindEvents:KN,valueOrDefault:YN}=ua;class QN{static fetchFonts(e,t,n={depth:0}){!e||n.depth>5||!document.fonts||Object.keys(e).forEach((function(i){const r=e[i];"dataSource"!==i&&"$"!==i[0]&&r&&("font"===i?t.push(r):"object"==typeof r&&(n.depth++,QN.fetchFonts(r,t,n),n.depth--))}))}static loadFonts(e,t){let n=[];if(e.length>0&&document.fonts){try{n=e.map((function(e){return document.fonts.load(e)}))}catch(e){eo(e)}Promise.all(n).then(t,t)}else t()}static preloadFonts(e,t){const n=[];QN.fetchFonts(e,n),QN.loadFonts(n,t)}}function XN(e,t){const n=e.prototype;n.options?n.options=cN({},n.options,t):n.options=t}const ZN="k-i-";const JN="k-svg-i-";class e${constructor(e,t){this.element=e,this.options=cN({},this.options,t),this.wrapper()}wrapper(){this.addClasses()}addClasses(){}html(){return this.element.outerHTML}}XN(e$,{name:"",size:"none",themeColor:"none",flip:"default",iconClass:"",stylingOptions:["size","themeColor","fill"]});class t$ extends e${constructor(e,t){super(e,t)}wrapper(){let e=this.element.className.split(" ").find((e=>e.startsWith(ZN)));let t=this.options.icon?`${this.options.icon.startsWith(ZN)?"":ZN}${this.options.icon}`:"";this._className=t,YV(this.element,"k-icon"),YV(this.element,"k-font-icon"),XV(this.element,e),YV(this.element,t),YV(this.element,this.options.iconClass||""),super.wrapper()}}XN(t$,{name:"HTMLFontIcon",icon:null});class n$ extends e${constructor(e,t){e.innerHTML="",super(e,t)}wrapper(){let e=this.options.icon;let t=this.options.iconClass;let n=this.element.className.split(" ").find((e=>e.startsWith(JN)));if(!e&&t){const n=/k-i-(\w+(?:-\w+)*)/;let i=t.match(n);i&&(e=i[1],t=t.replace(i[0],""))}tN(e)&&(e=e.replace("k-i-","").replace(/-./g,(e=>e[1].toUpperCase())),e=this.options.svgIcons[e]||this.options.svgIcons[`${e}Icon`]);let i=e&&e.name?`${JN}${e.name}`:"";if(this._className=i,YV(this.element,"k-svg-icon"),XV(this.element,n),YV(this.element,i),YV(this.element,t||""),this.element.setAttribute("aria-hidden","true"),e&&EN(e)){let t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("viewBox",e.viewBox||""),t.setAttribute("focusable","false"),t.innerHTML=e.content||"",this.element.appendChild(t)}super.wrapper()}}XN(n$,{name:"HTMLSvgIcon",icon:null,svgIcons:{}});const i$={svg:n$,font:t$};function r$(e,t){let n=e;let i=t;return n&&(!dN(n)||n instanceof HTMLElement)&&!tN(n)||(i=n,n=document.createElement("span")),tN(i)&&(i={icon:i}),i.type||(i.type="svg"),i$[i.type]?new i$[i.type](n,i).html():null}function o$(e){let t=xV;let n=CV;for(let i=0,r=e.length;i<r;i++){const r=e[i];null!==r&&isFinite(r)&&(t=Math.min(t,r),n=Math.max(n,r))}return{min:t===xV?void 0:t,max:n===CV?void 0:n}}function a$(e,t){for(let n=0;n<e.length;n++){const i=e[n];if(t(i,n,e))return i}}const s$=Jo;const l$=/matrix\((.*)\)/;function c$(e){const t=getComputedStyle(e).transform;return"none"===t?s$.unit():function(e){const t=e.match(l$);if(null===t||2!==t.length)return s$.unit();const n=t[1].split(",").map((e=>parseFloat(e)));return new s$(...n)}(t)}function d$(e){if(!e)return s$.unit();let t=c$(e);let n=e.parentElement;for(;n;){const e=c$(n);t=t.multiplyCopy(e),n=n.parentElement}return t.b=t.c=t.e=t.f=0,t}function h$(e){return new bo(e).isDark()?VV:aV}const u$={};class p${constructor(e){this._index={},this._values=e?e.slice(0):[];for(let e=0;e<this._values.length;e++)this._index[this._values[e]]=e}values(){return this._values.filter((e=>e!==u$))}has(e){return void 0!==this._index[e]}add(e){this.has(e)||(this._index[e]=this._values.length,this._values.push(e))}delete(e){const t=this._index[e];void 0!==t&&(this._values[t]=u$,delete this._index[e])}clear(){this._index={},this._values=[]}get size(){return this._values.length}}class f${constructor(e){this._set=new Set(e)}values(){return Array.from(this._set)}has(e){return this._set.has(e)}add(e){this._set.add(e)}delete(e){this._set.delete(e)}clear(){this._set.clear()}get size(){return this._set.size}}function m$(e){return(()=>{let e=!1;"function"==typeof Set&&(e=new Set([1]).has(1));return e})()?new f$(e):new p$(e)}function g$(e){throw e}let v$={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 _$(e,t){return Object.prototype.hasOwnProperty.call(e,t)}let b$=class e{constructor(){this.height=0,this.width=0,this.data=[]}clone(){const t=new e;return t.height=this.height,t.width=this.width,t.data=this.data.map((e=>e.slice())),t}get(e,t){const n=this.data[e];return n?n[t]:null}set(e,t,n){let 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(let n=0;n<this.height;++n)for(let i=0;i<this.width;++i){let r=this.get(n,i);if((t||null!=r)&&(r=e(r,n,i),void 0!==r))return r}}map(t,n){const i=new e;return this.each((function(e,n,r){i.set(n,r,t(e,n,r))}),n),i}transpose(){const t=new e;return this.each((function(e,n,i){t.set(i,n,e)})),t}unit(e){this.width=this.height=e;const t=this.data=new Array(e);for(let n=e;--n>=0;){const i=t[n]=new Array(e);for(let t=e;--t>=0;)i[t]=n===t?1:0}return this}multiply(t){const n=this;const i=new e;for(let e=0;e<n.height;++e)for(let r=0;r<t.width;++r){let o=0;for(let i=0;i<n.width;++i){const a=n.get(e,i);const s=t.get(i,r);"number"==typeof a&&"number"==typeof s&&(o+=a*s)}i.set(e,r,o)}return i}inverse(){const t=this.width;const n=this.augment((new e).unit(t));const i=n.data;for(let e=0;e<t;++e){const n=w$(e,t,(function(t){return i[t][e]}));if(!i[n][e])return null;if(e!==n){let t=i[e];i[e]=i[n],i[n]=t}for(let n=e+1;n<t;++n){for(let r=e+1;r<2*t;++r)i[n][r]-=i[e][r]*i[n][e]/i[e][e];i[n][e]=0}}for(let e=0;e<t;++e)for(let n=i[e][e],r=0;r<2*t;++r)i[e][r]/=n;for(let e=t;--e>=0;)for(let n=e;--n>=0;)if(i[n][e])for(let r=2*t;--r>=t;)i[n][r]-=i[e][r]*i[n][e];return n.slice(0,t,t,t)}augment(e){const t=this.clone();const n=t.width;return e.each((function(e,i,r){t.set(i,r+n,e)})),t}slice(t,n,i,r){const o=new e;for(let e=0;e<i;++e)for(let i=0;i<r;++i)o.set(e,i,this.get(t+e,n+i));return o}};function w$(e,t,n){let i=n(e),r=e;for(let o=e+1;o<t;o++){const t=n(e);t>i&&(i=t,r=e)}return r}const y$={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"};function k$(e){return y$[e]||e}const x$=e=>e.replace(/([^ ]+)/g,k$);let C$=1;function S$(){return"kchart"+C$++}function T$(){return S$()}const M$=new WeakMap;const A$=Symbol("id");function D$(e,t,n,i,r){!function(e,t,n,i,r){const o=KV(t)?t:(t||"").split(" ");o.forEach((function(t){!function(e,t,n,i,r){let o=i;let a;n&&aN(n)&&!i?o=n:n&&function(e){return"string"==typeof e}(n)&&aN(o)&&(a=n);const s=function(t){const n=t.target?t.target.closest(a):null;if(!a||a&&t.target&&n){const i=a?n:t.currentTarget;Object.defineProperty(t,"currentTarget",{value:i}),Object.defineProperty(t,"delegateTarget",{value:e}),o(t)}};o[A$]||(o[A$]=T$());let l=M$.get(e);l||(l=new Map,M$.set(e,l));l.set(t+o[A$],s),e.addEventListener(t,s,Boolean(r))}(e,t,n,i,r)}))}(e,t,n,i,r)}function E$(e,t,n,i,r){!function(e,t,n,i){const r=KV(t)?t:(t||"").split(" ");r.forEach((function(t){!function(e,t,n,i){const r=M$.get(e);if(r&&n&&n[A$]){const o=t+n[A$];const a=r.get(o);r.delete(o),a&&e.removeEventListener(t,a,Boolean(i))}}(e,t,n,i)}))}(e,t,n,i)}function I$(){const e=function(e){let t=!1;const 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(let r in n){if(e.match(n[r])){if("windows"===r&&"plugins"in navigator)return!1;t={},t.device=r,t.name=z$(r,i),t[t.name]=!0;break}}return t}(navigator.userAgent);const t={};return t.mobileOS=e,t}function z$(e,t,n){for(let n in t)if(t[n].test(e))return n;return void 0!==n?n:e}function P$(){}function L$(){return(new Date).getTime()}const B$="string";const H$="function";let R$=function(){this._defaultPrevented=!0};let F$=function(){return!0===this._defaultPrevented};let O$=class{constructor(){this._events={}}destroy(){this.unbind()}bind(e,t,n){let i,r,o,a,s,l=this,c=typeof e===B$?[e]:e||[],d=typeof t===H$;if(void 0===t){for(i in e)l.bind(i,e[i]);return l}for(i=0,r=c.length;i<r;i++){let 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===B$?[e]:e,l=typeof t===H$;for(n=0,i=s.length;n<i;n++){let 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){let e=t||{};for(e.sender=r,e._defaultPrevented=!1,e.preventDefault=R$,e.isDefaultPrevented=F$,o=o.slice(),n=0,i=o.length;n<i;n++)o[n].call(r,e);return!0===e._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}_setEvents(e){const t=(this.events||[]).length;for(let n=0;n<t;n++){let t=this.events[n];this.options[t]&&e[t]&&(this.unbind(t,this.options[t]),this._events&&this._events[t]&&delete this._events[t])}this.bind(this.events,e)}};const V$=Object.assign;const N$=e=>{e.preventDefault()};let $$=800,U$=0,W$="press",j$="hold",q$="select",G$="start",K$="move",Y$="end",Q$="cancel",X$="tap",Z$="doubleTap",J$="release",eU="gesturechange",tU="gestureend",nU="gesturetap";let iU={api:0,touch:0,mouse:9,pointer:9};function rU(e){let 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}let oU=class{constructor(e,t){let n=this;n.support=I$(),n.invalidZeroEvents=this.support.mobileOS&&this.support.mobileOS.android,n.axis=e,n._updateLocationData(t),n.startLocation=n.location,n.velocity=n.delta=0,n.timeStamp=L$()}move(e){let t=this,n=e["page"+t.axis],i=L$(),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)}_updateLocationData(e){let t=this,n=t.axis;t.location=e["page"+n],t.client=e["client"+n],t.screen=e["screen"+n]}};let aU=class{constructor(e,t,n){V$(this,{x:new oU("X",n.location),y:new oU("Y",n.location),type:n.type,threshold:e.threshold||iU[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(){this._holdTimeout=setTimeout((()=>this._hold()),this.userEvents.minHold),this._trigger(W$,this.pressEvent)}_tap(e){let t=this;t.userEvents._clicks++,1===t.userEvents._clicks&&(t._clickTimeout=setTimeout((function(){1===t.userEvents._clicks?t._trigger(X$,e):t._trigger(Z$,e),t.userEvents._clicks=0}),300))}_hold(){this._trigger(j$,this.pressEvent)}move(e){let t=this;let 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(lU.current&&lU.current!==t.userEvents)return t.dispose();t._start(e)}t._finished||t._trigger(K$,e)}}end(e){this.endTime=L$(),this._finished||(this._finished=!0,this._trigger(J$,e),this._moved?this._trigger(Y$,e):this.supportDoubleTap?this._tap(e):this._trigger(X$,e),clearTimeout(this._holdTimeout),this.dispose())}dispose(){let e=this.userEvents.touches||[];this._finished=!0,this.pressEvent=null,clearTimeout(this._holdTimeout);const t=e.indexOf(this);e.splice(t,1)}skip(){this.dispose()}cancel(){this.dispose()}isMoved(){return this._moved}_start(e){clearTimeout(this._holdTimeout),this.startTime=L$(),this._moved=!0,this._trigger(G$,e)}_trigger(e,t){const n=t.event;const i={touch:this,x:this.x,y:this.y,target:this.target,event:n};this.userEvents.notify(e,i)&&n.preventDefault()}_withinIgnoreThreshold(){let e=this.x.initialDelta,t=this.y.initialDelta;return Math.sqrt(e*e+t*t)<=this.threshold}};function sU(e){let t=y$.up.split(" "),n=0,i=t.length;for(;n<i;n++)e(t[n])}let lU=class e extends O${constructor(e,t){super();let n=this;let i;const r=I$();if(this.support=r,t=t||{},this.options=t,i=n.filter=t.filter,n.threshold=t.threshold||U$,n.minHold=t.minHold||$$,n.touches=[],n._maxTouches=t.multiTouch?2:1,n.allowSelection=t.allowSelection,n.captureUpIfMoved=t.captureUpIfMoved,n._clicks=0,n.supportDoubleTap=t.supportDoubleTap,V$(n,{element:e,surface:t.surface||e,stopPropagation:t.stopPropagation,pressed:!1}),this._surfaceMoveHandler=this._move.bind(this),D$(n.surface,x$("move"),this._surfaceMoveHandler),this._surfaceEndHandler=this._end.bind(this),D$(n.surface,x$("up cancel"),this._surfaceEndHandler),this._elementStartHandler=this._start.bind(this),D$(e,x$("down"),i,this._elementStartHandler),e.style["touch-action"]=t.touchAction||"none",t.preventDragEvent&&(this._elementDragStartHandler=N$,D$(e,x$("dragstart"),this._elementDragStartHandler)),this._elementSelectHandler=this._select.bind(this),D$(e,x$("mousedown"),i,this._elementSelectHandler),n.captureUpIfMoved){let e=n.surface;n._preventIfMovingProxy=n.preventIfMoving.bind(n),sU((function(t){e.addEventListener(t,n._preventIfMovingProxy,!0)}))}n.bind([W$,j$,X$,Z$,G$,K$,Y$,J$,Q$,"gesturestart",eU,tU,nU,q$],t)}preventIfMoving(e){this._isMoved()&&e.preventDefault()}destroy(){let e=this;const t=this.options;const n=this.element;if(!e._destroyed){if(e._destroyed=!0,e.captureUpIfMoved){let t=e.surface;sU((function(n){t.removeEventListener(n,e._preventIfMovingProxy,!0)}))}E$(e.surface,x$("move"),this._surfaceMoveHandler),E$(e.surface,x$("up cancel"),this._surfaceEndHandler),E$(n,x$("down"),this._elementStartHandler),t.preventDragEvent&&E$(n,x$("dragstart"),this._elementDragStartHandler),E$(n,x$("mousedown"),this._elementSelectHandler),e._disposeAll(),e.unbind(),delete e.surface,delete e.element,delete e.currentTarget}}capture(){e.current=this}cancel(){this._disposeAll(),this.trigger(Q$)}notify(e,t){let n=this.touches;let i=e;if(this._isMultiTouch()){switch(i){case K$:i=eU;break;case Y$:i=tU;break;case X$:i=nU}V$(t,{touches:n},function(e,t){let 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)}}(n[0],n[1]))}return this.trigger(i,V$(t,{type:i}))}press(e,t,n){this._apiCall("_start",e,t,n)}move(e,t){this._apiCall("_move",e,t)}end(e,t){this._apiCall("_end",e,t)}_isMultiTouch(){return this.touches.length>1}_maxTouchesReached(){return this.touches.length>=this._maxTouches}_disposeAll(){let e=this.touches;for(;e.length>0;)e.pop().dispose()}_isMoved(){return xN(this.touches,(function(e){return e.isMoved()})).length}_select(e){this.allowSelection&&!this.trigger(q$,{event:e})||e.preventDefault()}_start(t){if(t.which&&t.which>1||this._maxTouchesReached())return;let n;e.current=null,this.currentTarget=t.currentTarget,this.stopPropagation&&t.stopPropagation();const i=rU(t);for(let e=0;e<i.length&&!this._maxTouchesReached();e++){const t=i[e];if(n=this.filter?t.currentTarget:this.element,n&&0===n.length)continue;const r=new aU(this,n,t);this.touches.push(r),r.press(),this._isMultiTouch()&&this.notify("gesturestart",{})}}_move(e){this._eachTouch("move",e)}_end(e){this._eachTouch("end",e)}_eachTouch(e,t){let n,i,r,o,a={},s=rU(t),l=this.touches;for(n=0;n<l.length;n++)i=l[n],a[i.id]=i;for(n=0;n<s.length;n++)if(r=s[n],o=a[r.id],o){"move"===e&&"pointer"===r.type&&!this.surface.hasPointerCapture(r.id)&&this.surface.setPointerCapture(r.id),o[e](r)}}_apiCall(e,t,n,i){this[e]({api:!0,pageX:t,pageY:n,clientX:t,clientY:n,target:i||this.element,stopPropagation:P$,preventDefault:P$})}static defaultThreshold(e){U$=e}static minHold(e){$$=e}};function cU(e,t){let n=GN(t-e,9);if(0===n){if(0===t)return.1;n=Math.abs(t)}const i=Math.pow(10,Math.floor(Math.log(n)/Math.log(10)));const r=GN(n/i,pV);let o=1;return o=r<1.904762?.2:r<4.761904?.5:r<9.523809?1:2,GN(i*o,pV)}let dU=class e{constructor(e,t){this.x=e||0,this.y=t||0}clone(){return new e(this.x,this.y)}equals(e){return e&&this.x===e.x&&this.y===e.y}rotate(e,t){const n=qN(t);const i=Math.cos(n);const r=Math.sin(n);const{x:o,y:a}=e;const{x:s,y:l}=this;return this.x=GN(o+(s-o)*i+(l-a)*r,3),this.y=GN(a+(l-a)*i-(s-o)*r,3),this}multiply(e){return this.x*=e,this.y*=e,this}distanceTo(e){const t=this.x-e.x;const n=this.y-e.y;return Math.sqrt(t*t+n*n)}static onCircle(t,n,i){const r=qN(n);return new e(t.x-i*Math.cos(r),t.y-i*Math.sin(r))}};let hU=class e{constructor(e,t,n,i){this.x1=e||0,this.y1=t||0,this.x2=n||0,this.y2=i||0}equals(e){return this.x1===e.x1&&this.x2===e.x2&&this.y1===e.y1&&this.y2===e.y2}width(){return this.x2-this.x1}height(){return this.y2-this.y1}translate(e,t){return this.x1+=e,this.x2+=e,this.y1+=t,this.y2+=t,this}move(e,t){const n=this.height();const i=this.width();return void 0!==e&&(this.x1=e,this.x2=this.x1+i),void 0!==t&&(this.y1=t,this.y2=this.y1+n),this}wrap(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}wrapLimit(e,t,n){return this.x1=Math.min(this.x1,Math.max(this.x1-t,e.x1)),this.y1=Math.min(this.y1,Math.max(this.y1-n,e.y1)),this.x2=Math.max(this.x2,Math.min(this.x2+t,e.x2)),this.y2=Math.max(this.y2,Math.min(this.y2+n,e.y2)),this}wrapPoint(t){const n=KV(t);const i=n?t[0]:t.x;const r=n?t[1]:t.y;return this.wrap(new e(i,r,i,r)),this}snapTo(e,t){return t!==$V&&t||(this.x1=e.x1,this.x2=e.x2),t!==UV&&t||(this.y1=e.y1,this.y2=e.y2),this}alignTo(e,t){const n=this.height();const i=this.width();const r=t===BV||t===sV?UV:$V;const o=r===UV?n:i;if(t===lV){const t=e.center();const n=this.center();this.x1+=t.x-n.x,this.y1+=t.y-n.y}else this[r+1]=t===BV||t===kV?e[r+1]-o:e[r+2];return this.x2=this.x1+i,this.y2=this.y1+n,this}shrink(e,t){return this.x2-=e,this.y2-=t,this}expand(e,t){return this.shrink(-e,-t),this}pad(e){const t=mN(e);return this.x1-=t.left,this.x2+=t.right,this.y1-=t.top,this.y2+=t.bottom,this}unpad(e){const t=mN(e);return t.left=-t.left,t.top=-t.top,t.right=-t.right,t.bottom=-t.bottom,this.pad(t)}clone(){return new e(this.x1,this.y1,this.x2,this.y2)}center(){return new dU(this.x1+this.width()/2,this.y1+this.height()/2)}containsPoint(e){return e.x>=this.x1&&e.x<=this.x2&&e.y>=this.y1&&e.y<=this.y2}points(){return[new dU(this.x1,this.y1),new dU(this.x2,this.y1),new dU(this.x2,this.y2),new dU(this.x1,this.y2)]}getHash(){return[this.x1,this.y1,this.x2,this.y2].join(",")}overlaps(e){return!(e.y2<this.y1||this.y2<e.y1||e.x2<this.x1||this.x2<e.x1)}rotate(e){let t=this.width();let n=this.height();const{x:i,y:r}=this.center();const o=uU(0,0,i,r,e);const a=uU(t,0,i,r,e);const s=uU(t,n,i,r,e);const l=uU(0,n,i,r,e);return t=Math.max(o.x,a.x,s.x,l.x)-Math.min(o.x,a.x,s.x,l.x),n=Math.max(o.y,a.y,s.y,l.y)-Math.min(o.y,a.y,s.y,l.y),this.x2=this.x1+t,this.y2=this.y1+n,this}toRect(){return new ya([this.x1,this.y1],[this.width(),this.height()])}hasSize(){return 0!==this.width()&&0!==this.height()}align(e,t,n){return t===$V?this.alignX(e,n):this.alignY(e,n),this}alignX(e,t){const n=this.width();t===kV?(this.x1=e.x1,this.x2=this.x1+n):t===IV?(this.x2=e.x2,this.x1=this.x2-n):t===lV&&(this.x1=e.x1+(e.width()-n)/2,this.x2=this.x1+n)}alignY(e,t){const n=this.height();t===BV?(this.y1=e.y1,this.y2=this.y1+n):t===sV?(this.y2=e.y2,this.y1=this.y2-n):t===lV&&(this.y1=e.y1+(e.height()-n)/2,this.y2=this.y1+n)}};function uU(e,t,n,i,r){const o=qN(r);return new dU(n+(e-n)*Math.cos(o)+(t-i)*Math.sin(o),i-(e-n)*Math.sin(o)+(t-i)*Math.cos(o))}class pU{constructor(e,t,n,i,r){this.center=e,this.innerRadius=t,this.radius=n,this.startAngle=i,this.angle=r}clone(){return new pU(this.center,this.innerRadius,this.radius,this.startAngle,this.angle)}middle(){return this.startAngle+this.angle/2}setRadius(e,t){return t?this.innerRadius=e:this.radius=e,this}point(e,t){const n=qN(e);const i=Math.cos(n);const r=Math.sin(n);const o=t?this.innerRadius:this.radius;const a=GN(this.center.x-i*o,3);const s=GN(this.center.y-r*o,3);return new dU(a,s)}adjacentBox(e,t,n){const i=this.clone().expand(e);const r=i.middle();const o=i.point(r);const a=t/2;const s=n/2;const l=Math.sin(qN(r));const c=Math.cos(qN(r));let d=o.x-a;let h=o.y-s;return Math.abs(l)<.9&&(d+=a*-c/Math.abs(c)),Math.abs(c)<.9&&(h+=s*-l/Math.abs(l)),new hU(d,h,d+t,h+n)}containsPoint(e){const t=this.center;const n=this.innerRadius;const i=this.radius;const r=this.startAngle;const o=this.startAngle+this.angle;const a=e.x-t.x;const s=e.y-t.y;const l=new dU(a,s);const c=this.point(r);const d=new dU(c.x-t.x,c.y-t.y);const h=this.point(o);const u=new dU(h.x-t.x,h.y-t.y);const p=GN(a*a+s*s,3);return(d.equals(l)||JV(d,l))&&!JV(u,l)&&p>=n*n&&p<=i*i}getBBox(){const e=new hU(xV,xV,CV,CV);const t=GN(this.startAngle%360);const n=GN((t+this.angle)%360);const i=this.innerRadius;const r=[0,90,180,270,t,n].sort(fU);const o=r.indexOf(t);const a=r.indexOf(n);let s;s=t===n?r:o<a?r.slice(o,a+1):[].concat(r.slice(0,a+1),r.slice(o,r.length));for(let t=0;t<s.length;t++){let n=this.point(s[t]);e.wrapPoint(n),e.wrapPoint(n,i)}return i||e.wrapPoint(this.center),e}expand(e){return this.radius+=e,this}}function fU(e,t){return e-t}class mU extends pU{constructor(e,t,n,i){super(e,0,t,n,i)}expand(e){return super.expand(e)}clone(){return new mU(this.center,this.radius,this.startAngle,this.angle)}setRadius(e){return this.radius=e,this}}class gU{createRing(e,t){const n=e.startAngle+180;let i=e.angle+n;(0===e.angle||e.angle>0&&n===i)&&(i+=.001);const r=new ba(e.center.x,e.center.y);const o=Math.max(e.radius,0);const a=Math.max(e.innerRadius,0);const s=new $a(r,{startAngle:n,endAngle:i,radiusX:o,radiusY:o});const l=Rs.fromArc(s,t).close();if(a){s.radiusX=s.radiusY=a;const e=s.pointAt(i);l.lineTo(e.x,e.y),l.arc(i,n,a,a,!0)}else l.lineTo(r.x,r.y);return l}}gU.current=new gU;class vU{constructor(e){this.children=[],this.initOptions(e)}initOptions(e){this.options=cN({},this.options,this.initUserOptions(e))}initUserOptions(e){return e}reflow(e){const t=this.children;let n;for(let i=0;i<t.length;i++){let r=t[i];r.reflow(e),n=n?n.wrap(r.box):r.box.clone()}this.box=n||e}destroy(){const e=this.children;this.animation&&this.animation.destroy();for(let t=0;t<e.length;t++)e[t].destroy()}getRoot(){const e=this.parent;return e?e.getRoot():null}getSender(){const e=this.getService();if(e)return e.sender}getService(){let e=this;for(;e;){if(e.chartService)return e.chartService;e=e.parent}}translateChildren(e,t){const n=this.children;const i=n.length;for(let r=0;r<i;r++)n[r].box.translate(e,t)}append(){for(let e=0;e<arguments.length;e++){let t=arguments[e];this.children.push(t),t.parent=this}}renderVisual(){!1!==this.options.visible&&(this.createVisual(),this.addVisual(),this.renderChildren(),this.createAnimation(),this.renderComplete())}addVisual(){this.visual&&(this.visual.chartElement=this,this.parent&&this.parent.appendVisual(this.visual))}renderChildren(){const e=this.children;const t=e.length;for(let n=0;n<t;n++)e[n].renderVisual()}createVisual(){this.visual=new Us({zIndex:this.options.zIndex,visible:YN(this.options.visible,!0)})}createAnimation(){this.visual&&this.options.animation&&(this.animation=kl.create(this.visual,this.options.animation))}appendVisual(e){e.chartElement||(e.chartElement=this),e.options.noclip?this.clipRoot().visual.append(e):void 0!==e.options.zIndex?this.stackRoot().stackVisual(e):this.isStackRoot?this.stackVisual(e):this.visual?this.visual.append(e):this.parent.appendVisual(e)}clipRoot(){return this.parent?this.parent.clipRoot():this}stackRoot(){return this.parent?this.parent.stackRoot():this}stackVisual(e){const t=e.options.zIndex||0;const n=this.visual.children;const i=n.length;let r;for(r=0;r<i;r++){let e=n[r];if(YN(e.options.zIndex,0)>t)break}this.visual.insert(r,e)}traverse(e){const t=this.children;const n=t.length;for(let i=0;i<n;i++){let n=t[i];e(n),n.traverse&&n.traverse(e)}}closest(e){let t=this;let n=!1;for(;t&&!n;)n=e(t),n||(t=t.parent);if(n)return t}renderComplete(){}hasHighlight(){const e=(this.options||{}).highlight;return!(!this.createHighlight||e&&!1===e.visible||!1===this.visible)}toggleHighlight(e,t){const n=(this.options||{}).highlight||{};const i=n.visual;let r=this._highlight;if(!r){const e={fill:{color:VV,opacity:t||.2},stroke:{color:VV,width:1,opacity:t||.2}};if(i){if(r=this._highlight=i(Object.assign(this.highlightVisualArgs(),{createVisual:()=>this.createHighlight(e),sender:this.getSender(),series:this.series,dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,runningTotal:this.runningTotal,total:this.total})),!r)return}else r=this._highlight=this.createHighlight(e);void 0===r.options.zIndex&&(r.options.zIndex=YN(n.zIndex,this.options.zIndex)),this.appendVisual(r)}r.visible(e)}toggleFocusHighlight(e){const t=(this.options||{}).focusHighlight||{};let n=this._focusHighlight;if(e||n){if(!n){const e=h$(this.getRoot().options.background);const i={fill:{opacity:t.opacity,color:t.color},stroke:Object.assign({},{color:e},t.border),zIndex:t.zIndex};n=this._focusHighlight=this.createFocusHighlight(i),this.appendVisual(n)}n.visible(e)}}createGradientOverlay(e,t,n){const i=new Rs(Object.assign({stroke:{color:"none"},fill:this.createGradient(n),closed:e.options.closed},t));return i.segments.elements(e.segments.elements()),i}createGradient(e){if(this.parent)return this.parent.createGradient(e)}supportsPointInactiveOpacity(){return!0}}vU.prototype.options={};const{dotsPattern:_U,verticalStripesPattern:bU,crosshatchPattern:wU,diagonalStripesPattern:yU,gridPattern:kU}=Wc;const xU={dots:_U,verticalStripes:bU,crosshatch:wU,diagonalStripes:yU,grid:kU};function CU(e,t,n){const i=function(e,t){return aN(e)?e(t):e}(e,n);const r=i&&xU[i.type];return r?r(Object.assign({},t,i)):t}class SU extends vU{constructor(e){super(e),this.options.margin=mN(this.options.margin),this.options.padding=mN(this.options.padding)}reflow(e){const t=this.options;const{width:n,height:i,shrinkToFit:r}=t;const o=n&&i;const a=t.margin;const s=t.padding;const l=t.border.width;let c;const d=()=>{this.align(e,$V,t.align),this.align(e,UV,t.vAlign),this.paddingBox=c.clone().unpad(a).unpad(l)};let h=e.clone();o&&(h.x2=h.x1+n,h.y2=h.y1+i),r&&h.unpad(a).unpad(l).unpad(s),super.reflow(h),c=o?this.box=new hU(0,0,n,i):this.box,r&&o?(d(),h=this.contentBox=this.paddingBox.clone().unpad(s)):(h=this.contentBox=c.clone(),c.pad(s).pad(l).pad(a),d()),this.translateChildren(c.x1-h.x1+a.left+l+s.left,c.y1-h.y1+a.top+l+s.top);const u=this.children;for(let e=0;e<u.length;e++){let t=u[e];t.reflow(t.box)}}align(e,t,n){this.box.align(e,t,n)}hasBox(){const e=this.options;return e.border.width||e.background}createVisual(){super.createVisual();this.options.visible&&this.hasBox()&&this.visual.append(Rs.fromRect(this.paddingBox.toRect(),this.visualStyle()))}visualStyle(){const e=this.options;const t=e.border||{};return{stroke:{width:t.width,color:t.color,opacity:YN(t.opacity,e.opacity),dashType:t.dashType},fill:CU(e.pattern,{color:e.background,opacity:e.opacity},void 0),cursor:e.cursor}}}function TU(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)}XN(SU,{align:kV,vAlign:BV,margin:{},padding:{},border:{color:aV,width:0},background:"",shrinkToFit:!1,width:0,height:0,visible:!0});class MU extends SU{constructor(e,t){super(e),this.pointData=t}getElement(){const{options:e,paddingBox:t}=this;const{type:n,rotation:i}=e;const r=t.center();const o=t.width()/2;const a=t.height()/2;if(!e.visible||!this.hasBox())return null;const s=this.visualStyle();let l;if(n===cV)l=new Ra(new Ia([GN(t.x1+o,3),GN(t.y1+a,3)],Math.min(o,a)),s);else if(n===HV)l=Rs.fromPoints([[t.x1+o,t.y1],[t.x1,t.y2],[t.x2,t.y2]],s).close();else if(n===dV)l=new Fs(s),l.moveTo(t.x1,t.y1).lineTo(t.x2,t.y2),l.moveTo(t.x1,t.y2).lineTo(t.x2,t.y1);else{const i=t.toRect();if(n===zV){const t=YN(e.borderRadius,i.width()/5);i.setCornerRadius(t)}l=Rs.fromRect(i,s)}return i&&l.transform(xa().rotate(-i,[r.x,r.y])),l.options.zIndex=e.zIndex,l}createElement(){const e=this.options.visual;const t=this.pointData||{};let n;return n=e?e({value:t.value,dataItem:t.dataItem,sender:this.getSender(),series:t.series,category:t.category,rect:this.paddingBox.toRect(),options:this.visualOptions(),createVisual:()=>this.getElement()}):this.getElement(),n}visualOptions(){const 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}}createVisual(){this.visual=this.createElement(),TU(this.visual,this.options.accessibilityOptions)}}XN(MU,{type:cV,align:lV,vAlign:lV});const AU="radial";const DU={glass:{type:"linear",rotation:0,stops:[{offset:0,color:VV,opacity:0},{offset:.25,color:VV,opacity:.3},{offset:1,color:VV,opacity:0}]},sharpBevel:{type:AU,stops:[{offset:0,color:VV,opacity:.55},{offset:.65,color:VV,opacity:0},{offset:.95,color:VV,opacity:.25}]},roundedBevel:{type:AU,stops:[{offset:.33,color:VV,opacity:.06},{offset:.83,color:VV,opacity:.2},{offset:.95,color:VV,opacity:0}]},roundedGlass:{type:AU,supportVML:!1,stops:[{offset:0,color:VV,opacity:0},{offset:.5,color:VV,opacity:.3},{offset:.99,color:VV,opacity:0}]},sharpGlass:{type:AU,supportVML:!1,stops:[{offset:0,color:VV,opacity:.2},{offset:.15,color:VV,opacity:.15},{offset:.17,color:VV,opacity:.35},{offset:.85,color:VV,opacity:.05},{offset:.87,color:VV,opacity:.15},{offset:.99,color:VV,opacity:0}]},bubbleShadow:{type:AU,center:[.5,.5],radius:.5}};function EU(e,t){if(e.x1===t.x1&&e.y1===t.y1&&e.x2===t.x2&&e.y2===t.y2)return t;const n=Math.min(e.x1,t.x1);const i=Math.max(e.x1,t.x1);const r=Math.min(e.x2,t.x2);const o=Math.max(e.x2,t.x2);const a=Math.min(e.y1,t.y1);const s=Math.max(e.y1,t.y1);const l=Math.min(e.y2,t.y2);const c=Math.max(e.y2,t.y2);const d=[];return d[0]=new hU(i,a,r,s),d[1]=new hU(n,s,i,l),d[2]=new hU(r,s,o,l),d[3]=new hU(i,l,r,c),e.x1===n&&e.y1===a||t.x1===n&&t.y1===a?(d[4]=new hU(n,a,i,s),d[5]=new hU(r,l,o,c)):(d[4]=new hU(r,a,o,s),d[5]=new hU(n,l,i,c)),xN(d,(function(e){return e.height()>0&&e.width()>0}))[0]}class IU extends vU{constructor(e){super(e);const t=this.options;t.width=parseInt(t.width,10),t.height=parseInt(t.height,10),this.gradients={}}reflow(){const{options:e,children:t}=this;let n=new hU(0,0,e.width,e.height);this.box=n.unpad(e.margin);for(let e=0;e<t.length;e++)t[e].reflow(n),n=EU(n,t[e].box)||new hU}createVisual(){this.visual=new Us,this.createBackground()}createBackground(){const e=this.options;const t=e.border||{};const n=this.box.clone().pad(e.margin).unpad(t.width);const i=Rs.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)}getRoot(){return this}createGradient(e){const t=this.gradients;const n=jN(e);const i=DU[e.gradient];let r;if(t[n])r=t[n];else{const o=Object.assign({},i,e);"linear"===i.type?r=new ll(o):(e.innerRadius&&(o.stops=function(e){const t=e.stops;const n=e.innerRadius/e.radius*100;const i=t.length;const r=[];for(let e=0;e<i;e++){let i=Object.assign({},t[e]);i.offset=(i.offset*(100-n)+n)/100,r.push(i)}return r}(o)),r=new cl(o),r.supportVML=!1!==i.supportVML),t[n]=r}return r}cleanGradients(){const e=this.gradients;for(let t in e)e[t]._observers=[]}size(){const e=this.options;return new hU(0,0,e.width,e.height)}}XN(IU,{width:fV,height:400,background:VV,border:{color:aV,width:0},margin:mN(5),zIndex:-2});class zU extends vU{constructor(e){super(e),this._initDirection()}_initDirection(){const e=this.options;e.vertical?(this.groupAxis=$V,this.elementAxis=UV,this.groupSizeField=NV,this.elementSizeField=bV,this.groupSpacing=e.spacing,this.elementSpacing=e.vSpacing):(this.groupAxis=UV,this.elementAxis=$V,this.groupSizeField=bV,this.elementSizeField=NV,this.groupSpacing=e.vSpacing,this.elementSpacing=e.spacing)}reflow(e){this.box=e.clone(),this.reflowChildren()}reflowChildren(){const{box:e,elementAxis:t,groupAxis:n,elementSizeField:i,groupSizeField:r}=this;const{groups:o,groupsSize:a,maxGroupElementsSize:s}=this.groupOptions();const l=o.length;const c=e[n+1]+this.alignStart(a,e[r]());if(l){let d=c;for(let a=0;a<l;a++){let s=o[a];let l=s.groupElements;let c=e[t+1];let h=l.length;for(let e=0;e<h;e++){let o=l[e];let a=this.elementSize(o);let h=d+this.alignStart(a[r],s.groupSize);let u=new hU;u[n+1]=h,u[n+2]=h+a[r],u[t+1]=c,u[t+2]=c+a[i],o.reflow(u),c+=a[i]+this.elementSpacing}d+=s.groupSize+this.groupSpacing}e[n+1]=c,e[n+2]=c+a,e[t+2]=e[t+1]+s}}alignStart(e,t){let n=0;const i=this.options.align;return i===IV||i===sV?n=t-e:i===lV&&(n=(t-e)/2),n}groupOptions(){const{box:e,children:t,elementSizeField:n,groupSizeField:i,elementSpacing:r,groupSpacing:o}=this;const a=GN(e[n]());const s=t.length;const l=[];let c=0;let d=0;let h=0;let u=0;let p=[];for(let f=0;f<s;f++){let s=t[f];s.box||s.reflow(e);let m=this.elementSize(s);this.options.wrap&&GN(d+r+m[n])>a&&(l.push({groupElements:p,groupSize:c,groupElementsSize:d}),u=Math.max(u,d),h+=o+c,c=0,d=0,p=[]),c=Math.max(c,m[i]),d>0&&(d+=r),d+=m[n],p.push(s)}return l.push({groupElements:p,groupSize:c,groupElementsSize:d}),u=Math.max(u,d),h+=c,{groups:l,groupsSize:h,maxGroupElementsSize:u}}elementSize(e){return{width:e.box.width(),height:e.box.height()}}createVisual(){}}XN(zU,{vertical:!0,wrap:!0,vSpacing:0,spacing:0});const PU=Vs;let LU=class extends vU{constructor(e,t){super(t),this.content=e,this.reflow(new hU)}reflow(e){const t=this.options;const n=t.size=ha(this.content,{font:t.font});this.baseline=n.baseline,this.box=new hU(e.x1,e.y1,e.x1+n.width,e.y1+n.height)}createVisual(){const{font:e,color:t,opacity:n,cursor:i,stroke:r,paintOrder:o}=this.options;this.visual=new PU(this.content,this.box.toRect().topLeft(),{font:e,fill:{color:t,opacity:n},cursor:i,stroke:r,paintOrder:o})}};function BU(e){const t=e.origin;const n=e.bottomRight();return new hU(t.x,t.y,n.x,n.y)}XN(LU,{font:uV,color:aV});const HU=/\n/m;class RU extends SU{constructor(e,t,n){super(t),this.content=e,this.data=n,this._initContainer(),!1!==this.options._autoReflow&&this.reflow(new hU)}_initContainer(){const e=this.options;const t=String(this.content).split(HU);const n=new zU({vertical:!0,align:e.align,wrap:!1});const i=cN({},e,{opacity:1,animation:null});this.container=n,this.append(n);for(let e=0;e<t.length;e++){let r=new LU(t[e].trim(),i);n.append(r)}}reflow(e){const t=this.options;const n=t.visual;if(this.container.options.align=t.align,n&&!this._boxReflow){let i=e;i.hasSize()||(this._boxReflow=!0,this.reflow(i),this._boxReflow=!1,i=this.box);const r=this.visual=n(this.visualContext(i));r&&(i=BU(r.clippedBBox()||new ya),r.options.zIndex=t.zIndex),this.box=this.contentBox=this.paddingBox=i}else if(super.reflow(e),t.rotation){const n=mN(t.margin);let i=this.box.unpad(n);this.targetBox=e,this.normalBox=i.clone(),i=this.rotate(),i.translate(n.left-n.right,n.top-n.bottom),this.rotatedBox=i.clone(),i.pad(n)}}createVisual(){const e=this.options;if(this.visual=new Us({transform:this.rotationTransform(),zIndex:e.zIndex,noclip:e.noclip}),this.hasBox()){const e=Rs.fromRect(this.paddingBox.toRect(),this.visualStyle());this.visual.append(e)}}renderVisual(){if(this.options.visible)if(this.options.visual){const e=this.visual;e&&!HN(e.options.noclip)&&(e.options.noclip=this.options.noclip),this.addVisual(),this.createAnimation()}else super.renderVisual()}visualContext(e){const t={text:this.content,rect:e.toRect(),sender:this.getSender(),options:this.options,createVisual:()=>(this._boxReflow=!0,this.reflow(e),this._boxReflow=!1,this.getDefaultVisual())};return this.data&&Object.assign(t,this.data),t}getDefaultVisual(){this.createVisual(),this.renderChildren();const e=this.visual;return delete this.visual,e}rotate(){const e=this.options;return this.box.rotate(e.rotation),this.align(this.targetBox,$V,e.align),this.align(this.targetBox,UV,e.vAlign),this.box}rotationTransform(){const e=this.options.rotation;if(!e)return null;const{x:t,y:n}=this.normalBox.center();const i=this.rotatedBox.center();return xa().translate(i.x-t,i.y-n).rotate(e,[t,n])}}let FU=class e extends vU{constructor(e){super(e),this._textBox=new RU(this.options.text,Object.assign({},this.options,{vAlign:this.options.position})),this.append(this._textBox)}reflow(e){super.reflow(e),this.box.snapTo(e,$V)}static buildTitle(t,n){let i=t;let r;return"string"==typeof t&&(i={text:t}),i=Object.assign({visible:!0},n,i),i&&i.visible&&i.text&&(r=new e(i)),r}static orderTitles(e){const t=[].concat(e);const n=t.filter((e=>e&&e.options.position!==sV));const i=t.filter((e=>e&&e.options.position===sV));return OU(n),OU(i),i.reverse(),n.concat(i)}};function OU(e){for(let t=1;t<e.length;t++){const n=e[t]._textBox;const i=e[t-1]._textBox;i.options.margin=Object.assign(mN(i.options.margin),{bottom:0}),n.options.margin=Object.assign(mN(n.options.margin),{top:0})}}XN(FU,{color:aV,position:BV,align:lV,margin:mN(5),padding:mN(5)});class VU extends RU{constructor(e,t,n,i,r){super(t,r),this.text=t,this.value=e,this.index=n,this.dataItem=i,this.reflow(new hU)}visualContext(e){const t=super.visualContext(e);return t.value=this.value,t.dataItem=this.dataItem,t.format=this.options.format,t.culture=this.options.culture,t}click(e,t){e.trigger(oV,{element:NN(t),value:this.value,text:this.text,index:this.index,dataItem:this.dataItem,axis:this.parent.options})}rotate(){if(this.options.alignRotation!==lV){const e=this.normalBox.toRect();const t=this.rotationTransform();this.box=BU(e.bbox(t.matrix()))}else super.rotate();return this.box}rotationTransform(){const e=this.options;const t=e.rotation;if(!t)return null;if(e.alignRotation===lV)return super.rotationTransform();const n=xa().rotate(t).matrix();const i=this.normalBox.toRect();const r=this.targetBox.toRect();const o=e.rotationOrigin||BV;const a=o===BV||o===sV?$V:UV;const s=o===BV||o===sV?UV:$V;const l=o===BV||o===kV?r.origin:r.bottomRight();const c=i.topLeft().transformCopy(n);const d=i.topRight().transformCopy(n);const h=i.bottomRight().transformCopy(n);const u=i.bottomLeft().transformCopy(n);const p=ya.fromPoints(c,d,h,u);const f={[s]:r.origin[s]-p.origin[s]};const m=Math.abs(c[s]+f[s]-l[s]);const g=Math.abs(d[s]+f[s]-l[s]);let v,_;GN(m,pV)===GN(g,pV)?(v=c,_=d):g<m?(v=d,_=h):(v=c,_=u);const b=v[a]+(_[a]-v[a])/2;return f[a]=r.center()[a]-b,xa().translate(f.x,f.y).rotate(t)}}XN(VU,{_autoReflow:!1});class NU extends SU{constructor(e,t,n){super(t),this.fields=e,this.chartService=n,this.render()}hide(){this.options.visible=!1}show(){this.options.visible=!0}render(){const e=this.options;if(e.visible){const{label:t,icon:n}=e;const i=new hU;const r=()=>this;let o=n.size;let a=this.fields.text;let s,l;if(HN(t)&&t.visible){const e=_N(t);e?a=e(this.fields):t.format&&(a=this.chartService.format.auto(t.format,a)),t.color||(t.color=t.position===wV?"#fff":n.background),this.label=new RU(a,cN({},t)),this.label.aliasFor=r,t.position!==wV||HN(o)||(n.type===cV?o=Math.max(this.label.box.width(),this.label.box.height()):(s=this.label.box.width(),l=this.label.box.height()),i.wrap(this.label.box))}n.width=s||o||7,n.height=l||o||7;const c=new MU(cN({},n));c.aliasFor=r,this.marker=c,this.append(c),this.label&&this.append(this.label),c.reflow(new hU),this.wrapperBox=i.wrap(c.box)}}reflow(e){const{options:t,label:n,marker:i,wrapperBox:r}=this;const o=e.center();const a=t.line.length;const s=t.position;if(t.visible){let l,c,d;TN(s,[kV,IV])?s===kV?(d=r.alignTo(e,s).translate(-a,e.center().y-r.center().y),t.line.visible&&(l=[e.x1,o.y],this.linePoints=[l,[d.x2,o.y]],c=d.clone().wrapPoint(l))):(d=r.alignTo(e,s).translate(a,e.center().y-r.center().y),t.line.visible&&(l=[e.x2,o.y],this.linePoints=[l,[d.x1,o.y]],c=d.clone().wrapPoint(l))):s===sV?(d=r.alignTo(e,s).translate(e.center().x-r.center().x,a),t.line.visible&&(l=[o.x,e.y2],this.linePoints=[l,[o.x,d.y1]],c=d.clone().wrapPoint(l))):(d=r.alignTo(e,s).translate(e.center().x-r.center().x,-a),t.line.visible&&(l=[o.x,e.y1],this.linePoints=[l,[o.x,d.y2]],c=d.clone().wrapPoint(l))),i&&i.reflow(d),n&&(n.reflow(d),i&&(t.label.position===EV&&n.box.alignTo(i.box,s),n.reflow(n.box))),this.contentBox=d,this.targetBox=e,this.box=c||d}}createVisual(){super.createVisual(),this.visual.options.noclip=this.options.noclip,this.options.visible&&this.createLine()}renderVisual(){const e=this.options;const t=e.visual;e.visible&&t?(this.visual=t(Object.assign(this.fields,{sender:this.getSender(),rect:this.targetBox.toRect(),options:{background:e.background,border:e.background,icon:e.icon,label:e.label,line:e.line,position:e.position,visible:e.visible},createVisual:()=>{this.createVisual(),this.renderChildren();const e=this.visual;return delete this.visual,e}})),this.addVisual()):super.renderVisual()}createLine(){const e=this.options.line;if(this.linePoints){const t=Rs.fromPoints(this.linePoints,{stroke:{color:e.color,width:e.width,dashType:e.dashType}});ZV(t),this.visual.append(t)}}click(e,t){const n=this.eventArgs(t);e.trigger(TV,n)||t.preventDefault()}over(e,t){const n=this.eventArgs(t);e.trigger(MV,n)||t.preventDefault()}out(e,t){const n=this.eventArgs(t);e.trigger(AV,n)}eventArgs(e){const t=this.options;return Object.assign(this.fields,{element:NN(e),text:HN(t.label)?t.label.text:"",visual:this.visual})}}XN(NU,{icon:{visible:!0,type:cV},label:{position:wV,visible:!0,align:lV,vAlign:lV},line:{visible:!0},visible:!0,position:BV,zIndex:2});const $U={format:(e,t)=>t,toString:e=>e,parseDate:e=>new Date(e),firstDay:()=>0};let UU=$U;class WU{static register(e){UU=e}static get implementation(){return UU}}const jU=/\{(\d+)(:[^\}]+)?\}/g;class qU{constructor(e){this._intlService=e}get intl(){return this._intlService||WU.implementation}set intl(e){this._intlService=e}auto(e,...t){const n=this.intl;return tN(e)&&e.match(_V)?n.format(e,...t):n.toString(t[0],e)}localeAuto(e,t,n){const i=this.intl;let r;return r=tN(e)&&e.match(_V)?e.replace(jU,(function(e,r,o){let a=t[parseInt(r,10)];return i.toString(a,o?o.substring(1):"",n)})):i.toString(t[0],e,n),r}}class GU{constructor(e,t={}){this._intlService=t.intlService,this.sender=t.sender||e,this.format=new qU(t.intlService),this.chart=e,this.rtl=Boolean(t.rtl)}get intl(){return this._intlService||WU.implementation}set intl(e){this._intlService=e,this.format.intl=e}notify(e,t){this.chart&&this.chart.trigger(e,t)}isPannable(e){const t=((this.chart||{}).options||{}).pannable;return t&&t.lock!==e}}let KU;class YU{static register(e){KU=e}static create(e,t){let n;return n=KU?KU.create(e,t):new lU(e,Object.assign({},{multiTouch:!0,touchAction:"manipulation"},t)),n}}var QU=Object.freeze({__proto__:null,ChartService:GU,DomEventsBuilder:YU,FormatService:qU,IntlService:WU,TemplateService:vN});function XU(e,t){const{tickX:n,tickY:i,position:r}=e;const o=new Rs({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),ZV(o),o}function ZU(e,t){const{lineStart:n,lineEnd:i,position:r}=e;const o=new Rs({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),ZV(o),o}class JU extends vU{constructor(e,t=new GU){super(e),this.chartService=t,this.options.visible||(this.options=cN({},this.options,{labels:{visible:!1},line:{visible:!1},margin:0,majorTickSize:0,minorTickSize:0})),this.options.minorTicks=cN({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.minorTickType!==SV},this.options.minorTicks,{size:this.options.minorTickSize,align:this.options.minorTickType}),this.options.majorTicks=cN({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.majorTickType!==SV},this.options.majorTicks,{size:this.options.majorTickSize,align:this.options.majorTickType}),this.initFields(),this.options._deferLabels||this.createLabels(),this.createTitle(),this.createNotes()}initFields(){}labelsRange(){return{min:this.options.labels.skip,max:this.labelsCount()}}normalizeLabelRotation(e){const t=e.rotation;dN(t)&&(e.alignRotation=t.align,e.rotation=t.angle)}createLabels(){const e=this.options;const t=e.vertical?IV:lV;const n=cN({},e.labels,{align:t,zIndex:e.zIndex});const i=Math.max(1,n.step);if(this.clearLabels(),n.visible){this.normalizeLabelRotation(n),"auto"===n.rotation&&(n.rotation=0,e.autoRotateLabels=!0);const t=this.labelsRange();for(let e=t.min;e<t.max;e+=i){const i={index:e,count:t.max};let r=this.createAxisLabel(e,n,i);r&&(this.append(r),this.labels.push(r))}}}clearLabels(){this.children=xN(this.children,(e=>!(e instanceof VU))),this.labels=[]}clearTitle(){this.title&&(this.children=xN(this.children,(e=>e!==this.title)),this.title=void 0)}clear(){this.clearLabels(),this.clearTitle()}lineBox(){const{options:e,box:t}=this;const n=e.vertical;const i=e.labels.mirror;const r=i?t.x1:t.x2;const o=i?t.y2:t.y1;const a=e.line.width||0;return n?new hU(r,t.y1,r,t.y2-a):new hU(t.x1,o,t.x2-a,o)}createTitle(){const e=this.options;const t=cN({rotation:e.vertical?-90:0,text:"",zIndex:1,visualSize:!0},e.title);if(t.visible&&t.text){const e=new RU(t.text,t);this.append(e),this.title=e}}createNotes(){const e=this.options;const t=e.notes;const n=t.data||[];this.notes=[];for(let i=0;i<n.length;i++){const r=cN({},t,n[i]);r.value=this.parseNoteValue(r.value);const o=new NU({value:r.value,text:r.label.text,dataItem:r},r,this.chartService);o.options.visible&&(HN(o.options.position)?e.vertical&&!TN(o.options.position,[kV,IV])?o.options.position=e.reverse?kV:IV:e.vertical||TN(o.options.position,[BV,sV])||(o.options.position=e.reverse?sV:BV):e.vertical?o.options.position=e.reverse?kV:IV:o.options.position=e.reverse?sV:BV,this.append(o),this.notes.push(o))}}parseNoteValue(e){return e}renderVisual(){super.renderVisual(),this.createPlotBands()}createVisual(){super.createVisual(),this.createBackground(),this.createLine()}gridLinesVisual(){let e=this._gridLines;return e||(e=this._gridLines=new Us({zIndex:-2}),this.appendVisual(this._gridLines)),e}createTicks(e){const t=this.options;const n=this.lineBox();const i=t.labels.mirror;const r=t.majorTicks.visible?t.majorUnit:0;const o={vertical:t.vertical};function a(t,r,a){const s=t.length;const l=Math.max(1,r.step);if(r.visible)for(let c=r.skip;c<s;c+=l)HN(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(XU(o,r)))}a(this.getMajorTickPositions(),t.majorTicks),a(this.getMinorTickPositions(),t.minorTicks,r/t.minorUnit)}createLine(){const e=this.options;const t=e.line;const n=this.lineBox();if(t.width>0&&t.visible){const i=new Rs({stroke:{width:t.width,color:t.color,dashType:t.dashType}});i.moveTo(n.x1,n.y1).lineTo(n.x2,n.y2),e._alignLines&&ZV(i);const r=this._lineGroup=new Us;r.append(i),this.visual.append(r),this.createTicks(r)}}getActualTickSize(){const e=this.options;let 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}createBackground(){const{options:e,box:t}=this;const n=e.background;n&&(this._backgroundPath=Rs.fromRect(t.toRect(),{fill:{color:n},stroke:null}),this.visual.append(this._backgroundPath))}createPlotBands(){const e=this.options;const t=e.plotBands||[];const n=e.vertical;const i=this.plotArea;if(0===t.length)return;const r=this._plotbandGroup=new Us({zIndex:-1});const o=xN(this.pane.axes,(e=>e.options.vertical!==this.options.vertical))[0];for(let e=0;e<t.length;e++){let a=t[e];let s,l;let c=a.label;let d;if(n?(s=(o||i.axisX).lineBox(),l=this.getSlot(a.from,a.to,!0)):(s=this.getSlot(a.from,a.to,!0),l=(o||i.axisY).lineBox()),c&&(c.vAlign=c.position||kV,d=this.createPlotBandLabel(c,a,new hU(s.x1,l.y1,s.x2,l.y2))),0!==s.width()&&0!==l.height()){const e=new ya([s.x1,l.y1],[s.width(),l.height()]);const t=Rs.fromRect(e,{fill:{color:a.color,opacity:a.opacity},stroke:null});r.append(t),d&&r.append(d)}}this.appendVisual(r)}createPlotBandLabel(e,t,n){if(!1===e.visible)return null;let i=e.text;let r;if(HN(e)&&e.visible){const n=_N(e);n?i=n({text:i,item:t}):e.format&&(i=this.chartService.format.auto(e.format,i)),e.color||(e.color=this.options.labels.color)}return r=new RU(i,e),r.reflow(n),r.renderVisual(),r.visual}createGridLines(e){const t=this.options;const{minorGridLines:n,majorGridLines:i,minorUnit:r,vertical:o}=t;const a=e.options.line.visible;const s=i.visible?t.majorUnit:0;const l=e.lineBox();const c=l[o?"y1":"x1"];const d={lineStart:l[o?"x1":"y1"],lineEnd:l[o?"x2":"y2"],vertical:o};const h=[];const u=this.gridLinesVisual();function p(e,t,n){const i=e.length;const r=Math.max(1,t.step);if(t.visible)for(let o=t.skip;o<i;o+=r){let i=GN(e[o]);TN(i,h)||o%n==0||a&&c===i||(d.position=i,u.append(ZU(d,t)),h.push(i))}}return p(this.getMajorTickPositions(),i),p(this.getMinorTickPositions(),n,s/r),u.children}reflow(e){const{options:t,labels:n,title:i}=this;const r=t.vertical;const o=n.length;const a=r?NV:bV;const s=i?i.box[a]():0;const l=this.getActualTickSize()+t.margin+s;const c=((this.getRoot()||{}).box||e)[a]();let d=0;for(let e=0;e<o;e++){let t=n[e].box[a]();t+l<=c&&(d=Math.max(d,t))}this.box=r?new hU(e.x1,e.y1,e.x1+d+l,e.y2):new hU(e.x1,e.y1,e.x2,e.y1+d+l),this.arrangeTitle(),this.arrangeLabels(),this.arrangeNotes()}getLabelsTickPositions(){return this.getMajorTickPositions()}labelTickIndex(e){return e.index}arrangeLabels(){const{options:e,labels:t}=this;const n=this.labelsBetweenTicks();const i=e.vertical;const r=e.labels.mirror;const o=this.getLabelsTickPositions();for(let e=0;e<t.length;e++){const a=t[e];const s=this.labelTickIndex(a);const l=i?a.box.height():a.box.width();const c=o[s];const d=o[s+1];let h,u;if(i){if(n){h=c+(d-c)/2-l/2}else h=c-l/2;u=h}else n?(h=c,u=d):(h=c-l/2,u=h+l);this.positionLabel(a,r,h,u)}}positionLabel(e,t,n,i=n){const r=this.options;const o=r.vertical;const a=this.lineBox();const s=this.getActualTickSize()+r.margin;let l;if(o){let i=a.x2;t?(i+=s,e.options.rotationOrigin=kV):(i-=s+e.box.width(),e.options.rotationOrigin=IV),l=e.box.move(i,n)}else{let r=a.y1;t?(r-=s+e.box.height(),e.options.rotationOrigin=sV):(r+=s,e.options.rotationOrigin=BV),l=new hU(n,r,i,r+e.box.height())}e.reflow(l)}autoRotateLabelAngle(e,t){return e.width()<t?0:e.height()>t?-90:-45}autoRotateLabels(){if(!this.options.autoRotateLabels||this.options.vertical)return!1;const e=this.getMajorTickPositions();const t=this.labels;const n=Math.min(t.length,e.length-1);let i=0;for(let r=0;r<n;r++){const n=Math.abs(e[r+1]-e[r]);const o=t[r].box;const a=this.autoRotateLabelAngle(o,n);if(0!==a&&(i=a),-90===i)break}if(0!==i){for(let e=0;e<t.length;e++)t[e].options.rotation=i,t[e].reflow(new hU);return!0}}arrangeTitle(){const{options:e,title:t}=this;const n=e.labels.mirror;const i=e.vertical;t&&(i?(t.options.align=n?IV:kV,t.options.vAlign=t.options.position):(t.options.align=t.options.position,t.options.vAlign=n?BV:sV),t.reflow(this.box))}arrangeNotes(){for(let e=0;e<this.notes.length;e++){const t=this.notes[e];const n=t.options.value;let i;HN(n)?(this.shouldRenderNote(n)?t.show():t.hide(),i=this.noteSlot(n)):t.hide(),t.reflow(i||this.lineBox())}}noteSlot(e){return this.getSlot(e)}alignTo(e){const t=e.lineBox();const n=this.options.vertical;const i=n?UV:$V;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]}axisLabelText(e,t,n){let i;const r=_N(t);const o=()=>t.format?this.chartService.format.localeAuto(t.format,[e],t.culture):e;if(r){i=r(Object.assign({},n,{get text(){return o()},value:e,format:t.format,culture:t.culture}))}else i=o();return i}slot(e,t,n){const i=this.getSlot(e,t,n);if(i)return i.toRect()}contentBox(){const e=this.box.clone();const t=this.labels;if(t.length){const n=this.options.vertical?UV:$V;if(this.chartService.isPannable(n)){const t=this.maxLabelOffset();e[n+1]-=t.start,e[n+2]+=t.end}else{t[0].options.visible&&e.wrap(t[0].box);const n=t[t.length-1];n.options.visible&&e.wrap(n.box)}}return e}maxLabelOffset(){const{vertical:e,reverse:t}=this.options;const n=this.labelsBetweenTicks();const i=this.getLabelsTickPositions();const r=e?UV:$V;const o=this.labels;const a=t?1:0;const s=t?0:1;let l=0;let c=0;for(let e=0;e<o.length;e++){const t=o[e];const d=this.labelTickIndex(t);let h,u;n?(h=i[d+a],u=i[d+s]):h=u=i[d],l=Math.max(l,h-t.box[r+1]),c=Math.max(c,t.box[r+2]-u)}return{start:l,end:c}}limitRange(e,t,n,i,r){const o=this.options;if(e<n&&r<0&&(!HN(o.min)||o.min<=n)||i<t&&r>0&&(!HN(o.max)||i<=o.max))return null;if(t<n&&r>0||i<e&&r<0)return{min:e,max:t};const a=t-e;let s=e;let l=t;return e<n&&r<0?(s=WN(e,n,i),l=WN(e+a,n+a,i)):t>i&&r>0&&(l=WN(t,n,i),s=WN(t-a,n,i-a)),{min:s,max:l}}valueRange(){return{min:this.seriesMin,max:this.seriesMax}}lineDir(){const{vertical:e,reverse:t}=this.options;return(e?-1:1)*(t?-1:1)}lineInfo(){const{vertical:e}=this.options;const t=this.lineBox();const n=e?t.height():t.width();const i=e?UV:$V;const r=this.lineDir();const o=i+(1===r?1:2).toString();return{axis:i,axisOrigin:o,axisDir:r,lineBox:t,lineSize:n,lineStart:t[o]}}pointOffset(e){const{axis:t,axisDir:n,axisOrigin:i,lineBox:r,lineSize:o}=this.lineInfo();return(n>0?e[t]-r[i]:r[i]-e[t])/o}scaleToDelta(e,t){const n=WN(e,-.999,.999);let i;return i=n>0?t*Math.min(1,n):t-t/(1+n),i}labelsBetweenTicks(){return!this.options.justified}prepareUserOptions(){}}XN(JU,{labels:{visible:!0,rotation:0,mirror:!1,step:1,skip:0},line:{width:1,color:aV,visible:!0},title:{visible:!0,position:lV},majorTicks:{align:EV,size:4,skip:0,step:1},minorTicks:{align:EV,size:3,skip:0,step:1},axisCrossingValue:0,majorTickType:EV,minorTickType:SV,majorGridLines:{skip:0,step:1},minorGridLines:{visible:!1,width:1,color:aV,skip:0,step:1},margin:5,visible:!0,reverse:!1,justified:!0,notes:{label:{text:""}},_alignLines:!0,_deferLabels:!1});const eW="milliseconds";const tW="seconds";const nW="minutes";const iW="hours";const rW="days";const oW="weeks";const aW="months";const sW="years";const lW=1e3;const cW=6e4;const dW=36e5;const hW=864e5;const uW=6048e5;const pW=26784e5;const fW=31536e6;const mW={years:fW,months:pW,weeks:uW,days:hW,hours:dW,minutes:cW,seconds:lW,milliseconds:1};function gW(e,t){return e.getTime()-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*cW}function vW(e,t){return new Date(e.getTime()+t)}function _W(e){let t;return e instanceof Date?t=e:e&&(t=new Date(e)),t}function bW(e,t=0){let n=0;let i=e.getDay();if(!isNaN(i))for(;i!==t;)0===i?i=6:i--,n++;return vW(e,-n*hW)}function wW(e,t){return 0===t&&23===e.getHours()&&(e.setHours(e.getHours()+2),!0)}function yW(e,t,n,i){let r=e;if(e){let o=_W(e);const a=o.getHours();n===sW?(r=new Date(o.getFullYear()+t,0,1),wW(r,0)):n===aW?(r=new Date(o.getFullYear(),o.getMonth()+t,1),wW(r,a)):n===oW?(r=yW(bW(o,i),7*t,rW),wW(r,a)):n===rW?(r=new Date(o.getFullYear(),o.getMonth(),o.getDate()+t),wW(r,a)):n===iW?r=function(e,t){const n=new Date(e);n.setMinutes(0,0,0);const i=(e.getTimezoneOffset()-n.getTimezoneOffset())*cW;return vW(n,i+t*dW)}(o,t):n===nW?(r=vW(o,t*cW),r.getSeconds()>0&&r.setSeconds(0)):n===tW?r=vW(o,t*lW):n===eW&&(r=vW(o,t)),n!==eW&&r.getMilliseconds()>0&&r.setMilliseconds(0)}return r}function kW(e,t,n){return yW(_W(e),0,t,n)}function xW(e,t,n){const i=_W(e);return i&&kW(i,t,n).getTime()===i.getTime()?i:yW(i,1,t,n)}function CW(e,t){return e&&t?e.getTime()-t.getTime():-1}function SW(e,t){return e.getTime()-t}function TW(e){if(KV(e)){let t=[];for(let n=0;n<e.length;n++)t.push(TW(e[n]));return t}if(e)return _W(e).getTime()}function MW(e,t){return e&&t?TW(e)===TW(t):e===t}function AW(e,t,n){return gW(e,t)/mW[n]}function DW(e,t,n,i){const r=_W(e);const o=_W(t);let a;return a=n===aW?r.getMonth()-o.getMonth()+12*(r.getFullYear()-o.getFullYear())+AW(r,new Date(r.getFullYear(),r.getMonth()),rW)/new Date(r.getFullYear(),r.getMonth()+1,0).getDate():n===sW?r.getFullYear()-o.getFullYear()+DW(r,new Date(r.getFullYear(),0),aW,1)/12:n===rW||n===oW?AW(r,o,n):SW(r,t)/mW[n],a/i}function EW(e,t,n){let i;return i=n===sW?t.getFullYear()-e.getFullYear():n===aW?12*EW(e,t,sW)+t.getMonth()-e.getMonth():n===rW?Math.floor(SW(t,e)/hW):Math.floor(SW(t,e)/mW[n]),i}function IW(e,t){let n;return n=tN(t)&&e.parseDate(t)||_W(t),n}function zW(e,t){if(KV(t)){const n=[];for(let i=0;i<t.length;i++)n.push(IW(e,t[i]));return n}return IW(e,t)}function PW(e,t){return eN(e.weekStartDay)?e.weekStartDay:t&&t.firstDay?t.firstDay():0}class LW extends JU{initFields(){this._ticks={}}categoriesHash(){return""}clone(){const e=new LW(Object.assign({},this.options,{categories:this.options.srcCategories}),this.chartService);return e.createLabels(),e}initUserOptions(e){const t=e.categories||[];const n=void 0!==e.min;const i=void 0!==e.max;if(e.srcCategories=e.categories=t,(n||i)&&t.length){const r=n?Math.floor(e.min):0;let o;o=i?e.justified?Math.floor(e.max)+1:Math.ceil(e.max):t.length,e.categories=e.categories.slice(r,o)}return e}rangeIndices(){const e=this.options;const t=e.categories.length||1;const n=eN(e.min)?e.min%1:0;let i;return i=eN(e.max)&&e.max%1!=0&&e.max<this.totalRange().max?t-(1-e.max%1):t-(e.justified?1:0),{min:n,max:i}}range(){const e=this.options;return{min:eN(e.min)?e.min:0,max:eN(e.max)?e.max:this.totalRange().max}}roundedRange(){return this.range()}totalRange(){const e=this.options;return{min:0,max:Math.max(this._seriesMax||0,e.srcCategories.length)-(e.justified?1:0)}}scaleOptions(){const{min:e,max:t}=this.rangeIndices();const n=this.lineBox();return{scale:(this.options.vertical?n.height():n.width())/(t-e||1)*(this.options.reverse?-1:1),box:n,min:e,max:t}}arrangeLabels(){super.arrangeLabels(),this.hideOutOfRangeLabels()}hideOutOfRangeLabels(){const{box:e,labels:t}=this;if(t.length>0){const n=this.options.vertical?UV:$V;const i=e[n+1];const r=e[n+2];const o=t[0];const a=UN(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)}}getMajorTickPositions(){return this.getTicks().majorTicks}getMinorTickPositions(){return this.getTicks().minorTicks}getLabelsTickPositions(){return this.getTicks().labelTicks}tickIndices(e){const{min:t,max:n}=this.rangeIndices();const i=Math.ceil(n);let r=Math.floor(t);const o=[];for(;r<=i;)o.push(r),r+=e;return o}getTickPositions(e){const{vertical:t,reverse:n}=this.options;const{scale:i,box:r,min:o}=this.scaleOptions();const a=r[(t?UV:$V)+(n?2:1)];const s=this.tickIndices(e);const l=[];for(let e=0;e<s.length;e++)l.push(a+GN(i*(s[e]-o),3));return l}getTicks(){const e=this.options;const t=this._ticks;const n=this.rangeIndices();const i=this.lineBox();const r=i.getHash()+n.min+","+n.max+e.reverse+e.justified;if(t._hash!==r){const n=e.minorTicks.visible||e.minorGridLines.visible;t._hash=r,t.labelTicks=this.getTickPositions(1),t.majorTicks=this.filterOutOfRangePositions(t.labelTicks,i),t.minorTicks=n?this.filterOutOfRangePositions(this.getTickPositions(.5),i):[]}return t}filterOutOfRangePositions(e,t){if(!e.length)return e;const n=this.options.vertical?UV:$V;const i=e=>t[n+1]<=e&&e<=t[n+2];const r=e.length-1;let o=0;for(;!i(e[o])&&o<=r;)o++;let a=r;for(;!i(e[a])&&a>=0;)a--;return e.slice(o,a+1)}lineInfo(){const{vertical:e,reverse:t}=this.options;const n=this.lineBox();const i=e?n.height():n.width();const r=e?UV:$V;const o=t?-1:1;const a=r+(1===o?1:2).toString();return{axis:r,axisOrigin:a,axisDir:o,lineBox:n,lineSize:i,lineStart:n[a]}}lineDir(){const{reverse:e}=this.options;return e?-1:1}getSlot(e,t,n){const i=this.options;const{reverse:r,justified:o}=i;const{scale:a,box:s,min:l}=this.scaleOptions();const{axis:c,lineStart:d}=this.lineInfo();const h=s.clone();const u=void 0===t;const p=YN(e,0);let f=YN(t,p);f=Math.max(f-1,p),f=Math.max(p,f);let m=d+(p-l)*a;let g=d+(f+1-l)*a;return u&&o&&(g=m),n&&(m=WN(m,s[c+1],s[c+2]),g=WN(g,s[c+1],s[c+2])),h[c+1]=r?g:m,h[c+2]=r?m:g,h}limitSlot(e){const t=this.options.vertical?UV:$V;const n=this.lineBox();const i=e.clone();return i[t+1]=WN(e[t+1],n[t+1],n[t+2]),i[t+2]=WN(e[t+2],n[t+1],n[t+2]),i}slot(e,t,n){const i=Math.floor(this.options.min||0);let r=e;let o=t;return"string"==typeof r?r=this.categoryIndex(r):eN(r)&&(r-=i),"string"==typeof o?o=this.categoryIndex(o):eN(o)&&(o-=i),super.slot(r,o,n)}pointCategoryIndex(e){const{reverse:t,justified:n,vertical:i}=this.options;const r=i?UV:$V;const{scale:o,box:a,min:s,max:l}=this.scaleOptions();const c=t?l:s;const d=a[r+1];const h=a[r+2];const u=e[r];if(u<d||u>h)return null;let p=c+(u-d)/o;const f=p%1;return n?p=Math.round(p):0===f&&p>0&&p--,Math.floor(p)}getCategory(e){const t=this.pointCategoryIndex(e);return null===t?null:this.options.categories[t]}categoryIndex(e){return this.totalIndex(e)-Math.floor(this.options.min||0)}categoryAt(e,t){const n=this.options;return(t?n.srcCategories:n.categories)[e]}categoriesCount(){return(this.options.categories||[]).length}translateRange(e){const t=this.options;const n=this.lineBox();const i=t.vertical?n.height():n.width();const r=t.categories.length;const o=GN(e/(i/r),pV);return{min:o,max:r+o}}scaleRange(e,t){const n=Math.abs(this.pointOffset(t));const i=this.limitedRangeIndices();const r=i.max-i.min;const o=this.scaleToDelta(e,r);const a=n*o;const s=(1-n)*o;const l=i.min+a;let c=i.max-s;return c-l<.1&&(c=l+.1),{min:l,max:c}}zoomRange(e,t){const{min:n,max:i}=this.totalRange();const r=this.scaleRange(e,t);return{min:WN(r.min,n,i),max:WN(r.max,n,i)}}labelsCount(){const e=this.labelsRange();return e.max-e.min}labelsRange(){const e=this.options;const{justified:t,labels:n}=e;let{min:i,max:r}=this.limitedRangeIndices(!0);const o=Math.floor(i);let a;return t?(i=Math.ceil(i),r=Math.floor(r)):(i=Math.floor(i),r=Math.ceil(r)),a=i>n.skip?n.skip+n.step*Math.ceil((i-n.skip)/n.step):n.skip,{min:a-o,max:(e.categories.length?r+(t?1:0):0)-o}}createAxisLabel(e,t,n){const i=this.options;const r=i.dataItems?i.dataItems[e]:null;const o=YN(i.categories[e],"");n.dataItem=r;const a=this.axisLabelText(o,t,n);return new VU(o,a,e,r,t)}shouldRenderNote(e){const t=this.limitedRangeIndices();return Math.floor(t.min)<=e&&e<=Math.ceil(t.max)}noteSlot(e){const t=this.options;const n=e-Math.floor(t.min||0);return this.getSlot(n)}arrangeNotes(){super.arrangeNotes(),this.hideOutOfRangeNotes()}hideOutOfRangeNotes(){const{notes:e,box:t}=this;if(e&&e.length){const n=this.options.vertical?UV:$V;const i=t[n+1];const r=t[n+2];for(let t=0;t<e.length;t++){const o=e[t];o.box&&(r<o.box[n+1]||o.box[n+2]<i)&&o.hide()}}}pan(e){const t=this.limitedRangeIndices(!0);const{scale:n}=this.scaleOptions();const i=GN(e/n,pV);const r=this.totalRange();const o=t.min+i;const a=t.max+i;return this.limitRange(o,a,0,r.max,i)}pointsRange(e,t){const{reverse:n,vertical:i}=this.options;const r=i?UV:$V;const o=this.limitedRangeIndices(!0);const{scale:a,box:s}=this.scaleOptions();const l=s[r+(n?2:1)];const c=e[r]-l;const d=t[r]-l;const h=o.min+c/a;const u=o.min+d/a;const p=Math.min(h,u);const f=Math.max(h,u);if(f-p>=.01)return{min:p,max:f}}valueRange(){return this.range()}totalIndex(e){const t=this.options;const n=this._categoriesMap?this._categoriesMap.get(e):function(e,t){return e instanceof Date?t.findIndex((t=>MW(t,e))):t.indexOf(e)}(e,t.srcCategories);return n}currentRangeIndices(){const e=this.options;let t=0;let n;return eN(e.min)&&(t=Math.floor(e.min)),n=eN(e.max)?e.justified?Math.floor(e.max):Math.ceil(e.max)-1:this.totalCount()-1,{min:t,max:n}}limitedRangeIndices(e){const t=this.options;let n=eN(t.min)?t.min:0;let i;if(i=eN(t.max)?t.max:eN(t.min)?n+t.categories.length:this.totalRange().max||1,e){const e=this.totalRange();n=WN(n,0,e.max),i=WN(i,0,e.max)}return{min:n,max:i}}totalRangeIndices(){return{min:0,max:this.totalRange().max||1}}indexCategories(){if(!this._categoriesMap){const e=this._categoriesMap=new SN;const t=this.options.srcCategories;for(let n=0;n<t.length;n++)e.set(t[n],n)}}totalCount(){return Math.max(this.options.srcCategories.length,this._seriesMax||0)}}XN(LW,{type:"category",vertical:!1,majorGridLines:{visible:!1,width:1,color:aV},labels:{zIndex:1},justified:!1,_deferLabels:!0});const BW=3e5;const HW={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"};const RW=[eW,tW,nW,iW,rW,oW,aW,sW];const FW="fit";function OW(e,t){t&&(e._range=void 0);let n=e._range;return n||(n=e._range=o$(e),n.min=_W(n.min),n.max=_W(n.max)),n}class VW{constructor(e){this.options=e}displayIndices(){return{min:0,max:1}}displayRange(){return{}}total(){return{}}valueRange(){return{}}valueIndex(){return-1}values(){return[]}totalIndex(){return-1}valuesCount(){return 0}totalCount(){return 0}dateAt(){return null}}class NW{constructor(e,t,n){this.options=n,n.baseUnitStep=n.baseUnitStep||1;const{roundToBaseUnit:i,justified:r}=n;this.start=yW(e,0,n.baseUnit,n.weekStartDay);const o=this.roundToTotalStep(t);const a=!r&&MW(t,o)&&!n.justifyEnd;this.end=this.roundToTotalStep(t,!r,a?1:0);const s=n.min||e;this.valueStart=this.roundToTotalStep(s),this.displayStart=i?this.valueStart:s;const l=n.max;if(l){const e=!r&&MW(l,this.roundToTotalStep(l))?-1:0;this.valueEnd=this.roundToTotalStep(l,!1,e),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))}displayRange(){return{min:this.displayStart,max:this.displayEnd}}displayIndices(){if(!this._indices){const e=this.options;const{baseUnit:t,baseUnitStep:n}=e;const i=DW(this.displayStart,this.valueStart,t,n);const r=DW(this.displayEnd,this.valueStart,t,n);this._indices={min:i,max:r}}return this._indices}total(){return{min:this.start,max:this.end}}totalCount(){return this.totalIndex(this.end)+(this.options.justified?1:0)}valueRange(){return{min:this.valueStart,max:this.valueEnd}}valueIndex(e){const t=this.options;return Math.floor(DW(e,this.valueStart,t.baseUnit,t.baseUnitStep))}totalIndex(e){const t=this.options;return Math.floor(DW(e,this.start,t.baseUnit,t.baseUnitStep))}dateIndex(e){const t=this.options;return DW(e,this.valueStart,t.baseUnit,t.baseUnitStep)}valuesCount(){return this.valueIndex(this.valueEnd)+1}values(){let e=this._values;if(!e){const t=this.options;const n=this.valueRange();this._values=e=[];for(let i=n.min;i<=n.max;)e.push(i),i=yW(i,t.baseUnitStep,t.baseUnit,t.weekStartDay)}return e}dateAt(e,t){const n=this.options;return yW(t?this.start:this.valueStart,n.baseUnitStep*e,n.baseUnit,n.weekStartDay)}roundToTotalStep(e,t,n){const{baseUnit:i,baseUnitStep:r,weekStartDay:o}=this.options;const a=this.start;const s=DW(e,a,i,r);let l=t?Math.ceil(s):Math.floor(s);return n&&(l+=n),yW(a,l*r,i,o)}}function $W(e,t,n){const i=OW(e.categories);const r=(e.max||i.max)-(e.min||i.min);const{autoBaseUnitSteps:o,maxDateGroups:a}=e;const s=e.baseUnit===FW;let l=t?RW.indexOf(t):0;let c=s?RW[l++]:e.baseUnit;let d=r/mW[c];let h=d;let u,p,f;for(;!p||d>=a;){u=u||o[c].slice(0);do{f=u.shift()}while(f&&t===c&&f<n);if(f)p=f,d=h/p;else{if(c===UN(RW)){p=Math.ceil(h/a);break}if(!s){d>a&&(p=Math.ceil(h/a));break}c=RW[l++]||UN(RW),h=r/mW[c],u=null}}e.baseUnitStep=p,e.baseUnit=c}function UW(e){const t=(e.baseUnit||"").toLowerCase();return t!==FW&&!TN(t,RW)&&function(e){const t=e.categories;const n=HN(t)?t.length:0;let i=xV;let r,o;for(let e=0;e<n;e++){const n=t[e];if(n&&r){let e=Math.abs(gW(n,r));0!==e&&(i=Math.min(i,e),o=i>=fW?sW:i>=24192e5?aW:i>=uW?oW:i>=hW?rW:i>=dW?iW:i>=cW?nW:tW)}r=n}e.baseUnit=o||rW}(e),t!==FW&&"auto"!==e.baseUnitStep||$W(e),e}class WW extends LW{clone(){const e=new WW(Object.assign({},this.options),this.chartService);return e.createLabels(),e}categoriesHash(){const e=this.dataRange.total().min;return this.options.baseUnit+this.options.baseUnitStep+e}initUserOptions(e){return e}initFields(){super.initFields();const e=this.chartService;const t=e.intl;let n=this.options;let i=n.categories||[];if(i._parsed||(i=zW(t,i),i._parsed=!0),n=cN({roundToBaseUnit:!0},n,{categories:i,min:IW(t,n.min),max:IW(t,n.max),weekStartDay:PW(n,t)}),e.panning&&e.isPannable(n.vertical?UV:$V)&&(n.roundToBaseUnit=!1),n.userSetBaseUnit=n.userSetBaseUnit||n.baseUnit,n.userSetBaseUnitStep=n.userSetBaseUnitStep||n.baseUnitStep,this.options=n,n.srcCategories=i,i.length>0){const e=OW(i,!0);const t=n.maxDivisions;const r=UW(n);const o=n._forecast;if(o&&(o.before>0&&(e.min=yW(e.min,-o.before,r.baseUnit,r.weekStartDay)),o.after>0&&(e.max=yW(e.max,o.after,r.baseUnit,r.weekStartDay))),this.dataRange=new NW(e.min,e.max,r),t){const i=this.dataRange.displayRange();const r=Object.assign({},n,{justified:!0,roundToBaseUnit:!1,baseUnit:"fit",min:i.min,max:i.max,maxDateGroups:t});const o=this.dataRange.options;$W(r,o.baseUnit,o.baseUnitStep),this.divisionRange=new NW(e.min,e.max,r)}else this.divisionRange=this.dataRange}else n.baseUnit=n.baseUnit||rW,this.dataRange=this.divisionRange=new VW(n);this.rangeLabels=[]}tickIndices(e){const{dataRange:t,divisionRange:n}=this;const i=n.valuesCount();if(!this.options.maxDivisions||!i)return super.tickIndices(e);const r=[];let o=n.values();let a=0;this.options.justified||(o=o.concat(n.dateAt(i)),a=.5);for(let n=0;n<o.length;n++)if(r.push(t.dateIndex(o[n])+a),1!==e&&n>=1){const t=r.length-1;r.splice(n,0,r[t-1]+(r[t]-r[t-1])*e)}return r}shouldRenderNote(e){const t=this.range();const n=this.options.categories||[];return CW(e,t.min)>=0&&CW(e,t.max)<=0&&n.length}parseNoteValue(e){return IW(this.chartService.intl,e)}noteSlot(e){return this.getSlot(e)}translateRange(e){const t=this.options;const{baseUnit:n,weekStartDay:i,vertical:r}=t;const o=this.lineBox();const a=r?o.height():o.width();let s=this.range();const l=a/(s.max-s.min);const c=GN(e/l,pV);if(s.min&&s.max){const e=vW(t.min||s.min,c);const r=vW(t.max||s.max,c);s={min:yW(e,0,n,i),max:yW(r,0,n,i)}}return s}labelsRange(){return{min:this.options.labels.skip,max:this.divisionRange.valuesCount()}}pan(e){if(this.isEmpty())return null;const t=this.options;const n=this.lineBox();const i=t.vertical?n.height():n.width();const{min:r,max:o}=this.dataRange.displayRange();const a=this.dataRange.total();const s=GN(e/(i/(o-r)),pV)*(t.reverse?-1:1);const l=vW(r,s);const c=vW(o,s);const d=this.limitRange(TW(l),TW(c),TW(a.min),TW(a.max),s);return d?(d.min=_W(d.min),d.max=_W(d.max),d.baseUnit=t.baseUnit,d.baseUnitStep=t.baseUnitStep||1,d.userSetBaseUnit=t.userSetBaseUnit,d.userSetBaseUnitStep=t.userSetBaseUnitStep,d):void 0}pointsRange(e,t){if(this.isEmpty())return null;const n=super.pointsRange(e,t);const i=this.dataRange.displayRange();const r=this.dataRange.displayIndices();const o=SW(i.max,i.min)/(r.max-r.min);const a=this.options;return{min:vW(i.min,n.min*o),max:vW(i.min,n.max*o),baseUnit:a.userSetBaseUnit||a.baseUnit,baseUnitStep:a.userSetBaseUnitStep||a.baseUnitStep}}scaleRange(e,t){if(this.isEmpty())return{};const n=this.options;const i=n.userSetBaseUnit===FW;const r=this.dataRange.total();const{min:o,max:a}=this.dataRange.displayRange();const s=Math.abs(this.pointOffset(t));const l=a-o;const c=this.scaleToDelta(e,l);const d=Math.round(s*c);const h=Math.round((1-s)*c);let{baseUnit:u}=this.dataRange.options;let p=new Date(o.getTime()+d);let f=new Date(a.getTime()-h);if(i){const{autoBaseUnitSteps:e,maxDateGroups:t}=n;const i=UN(e[u])*t*mW[u];const s=SW(a,o);const l=SW(f,p);let c=RW.indexOf(u);let d,h;if(l<mW[u]&&u!==eW)u=RW[c-1],d=UN(e[u]),h=(s-(t-1)*d*mW[u])/2,p=vW(o,h),f=vW(a,-h);else if(l>i&&u!==sW){let t=0;do{c++,u=RW[c],t=0,h=2*mW[u];do{d=e[u][t],t++}while(t<e[u].length&&h*d<s)}while(u!==sW&&h*d<s);h=(h*d-s)/2,h>0&&(p=vW(o,-h),f=vW(a,h),p=vW(p,WN(f,r.min,r.max)-f),f=vW(f,WN(p,r.min,r.max)-p))}}return p&&f&&SW(f,p)>0?{min:p,max:f,baseUnit:n.userSetBaseUnit||n.baseUnit,baseUnitStep:n.userSetBaseUnitStep||n.baseUnitStep}:void 0}zoomRange(e,t){const n=this.dataRange.total();const i=this.scaleRange(e,t);return i&&(i.min<n.min&&(i.min=n.min),i.max>n.max&&(i.max=n.max)),i}range(){return this.dataRange.displayRange()}createLabels(){super.createLabels(),this.createRangeLabels()}clearLabels(){super.clearLabels(),this.rangeLabels=[]}arrangeLabels(){this.arrangeRangeLabels(),super.arrangeLabels()}arrangeRangeLabels(){const{options:e,rangeLabels:t}=this;if(0===t.length)return;const n=this.lineBox();const i=e.vertical;const r=e.rangeLabels.mirror||e.labels.mirror;const o=t[0];if(o){const e=i?n.y1-o.box.height()/2:n.x1;this.positionLabel(o,r,e)}const a=t[1];if(a){const e=i?n.y2-a.box.height()/2:n.x2;this.positionLabel(a,r,e)}}autoRotateLabels(){super.autoRotateLabels(),this.autoRotateRangeLabels()}hideOutOfRangeLabels(){super.hideOutOfRangeLabels(),this.hideOverlappingLabels()}hideOverlappingLabels(){const{rangeLabels:e,labels:t}=this;if(0===e.length)return;function n(e,t){return!(t.options.visible&&!t.box.overlaps(e.box))&&(t.options.visible=!1,!0)}const i=e[0];if(i&&i.options.visible)for(let e=0;e<t.length;e++){if(!n(i,t[e]))break}const r=e[1];if(r&&r.options.visible)for(let e=t.length-1;e>0;--e){if(!n(r,t[e]))break}}contentBox(){const e=super.contentBox();const t=this.rangeLabels;for(let n=0;n<t.length;n++){const i=t[n];i.options.visible&&e.wrap(i.box)}return e}createAxisLabel(e,t,n={}){const i=this.options;const r=i.dataItems&&!i.maxDivisions?i.dataItems[e]:null;const o=this.divisionRange.dateAt(e);const a=t.dateFormats[this.divisionRange.options.baseUnit];t.format=t.format||a,n.dataItem=r;const s=this.axisLabelText(o,t,n);if(s)return new VU(o,s,e,r,t)}createRangeLabels(){const{displayStart:e,displayEnd:t}=this.divisionRange;const n=this.options;const i=Object.assign({},n.labels,n.rangeLabels,{align:lV,zIndex:n.zIndex});if(!0!==i.visible)return;this.normalizeLabelRotation(i),i.alignRotation=lV,"auto"===i.rotation&&(i.rotation=0,n.autoRotateRangeLabels=!0);const r=i.dateFormats[this.divisionRange.options.baseUnit];i.format=i.format||r;const o=(e,t,n)=>{if(n){const r=new VU(t,n,e,null,i);this.append(r),this.rangeLabels.push(r)}};o(0,e,this.axisLabelText(e,i,{index:0,count:2}));o(1,t,this.axisLabelText(t,i,{index:1,count:2}))}autoRotateRangeLabels(){const e=this.rangeLabels;if(!this.options.autoRotateRangeLabels||this.options.vertical||2!==e.length)return;const t=(e,t,n)=>{const i=2*Math.abs(t[n+1]-t[n]);const r=this.autoRotateLabelAngle(e.box,i);0!==r&&(e.options.rotation=r,e.reflow(new hU))};const n=this.getMajorTickPositions();t(e[0],n,0),t(e[1],n,n.length-2)}categoryIndex(e){return this.dataRange.valueIndex(e)}slot(e,t,n){const i=this.dataRange;let r=e;let o=t;r instanceof Date&&(r=i.dateIndex(r)),o instanceof Date&&(o=i.dateIndex(o));const a=this.getSlot(r,o,n);if(a)return a.toRect()}getSlot(e,t,n){let i=e;let r=t;return typeof i===DV&&(i=this.categoryIndex(i)),typeof r===DV&&(r=this.categoryIndex(r)),super.getSlot(i,r,n)}valueRange(){const e=OW(this.options.srcCategories);return{min:_W(e.min),max:_W(e.max)}}categoryAt(e,t){return this.dataRange.dateAt(e,t)}categoriesCount(){return this.dataRange.valuesCount()}rangeIndices(){return this.dataRange.displayIndices()}labelsBetweenTicks(){return!this.divisionRange.options.justified}prepareUserOptions(){this.isEmpty()||(this.options.categories=this.dataRange.values())}getCategory(e){const t=this.pointCategoryIndex(e);return null===t?null:this.dataRange.dateAt(t)}totalIndex(e){return this.dataRange.totalIndex(e)}currentRangeIndices(){const e=this.dataRange.valueRange();return{min:this.dataRange.totalIndex(e.min),max:this.dataRange.totalIndex(e.max)}}totalRange(){return this.dataRange.total()}totalRangeIndices(){const e=this.dataRange.total();return{min:this.dataRange.totalIndex(e.min),max:this.dataRange.totalIndex(e.max)}}totalCount(){return this.dataRange.totalCount()}isEmpty(){return!this.options.srcCategories.length}roundedRange(){if(!1!==this.options.roundToBaseUnit||this.isEmpty())return this.range();const e=this.options;const t=OW(e.srcCategories);return new NW(t.min,t.max,Object.assign({},e,{justified:!1,roundToBaseUnit:!0,justifyEnd:!1})).displayRange()}}function jW(e,t){return GN(Math.floor(e/t)*t,pV)}function qW(e,t){return GN(Math.ceil(e/t)*t,pV)}function GW(e){return Math.max(Math.min(e,BW),-3e5)}XN(WW,{type:hV,labels:{dateFormats:HW},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});const KW=Math.pow(10,-9);class YW extends JU{constructor(e,t,n,i){super(Object.assign({},n,{seriesMin:e,seriesMax:t}),i)}initUserOptions(e){const t=function(e,t,n){const i=n.narrowRange;let r=function(e,t,n){if(!e&&!t)return 0;let i;if(e>=0&&t>=0){const 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);let o=function(e,t,n){if(!e&&!t)return 1;let i;if(e<=0&&t<=0){const r=e===t?0:t;let 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);const a=cU(r,o);const s={majorUnit:a};!1!==n.roundToMajorUnit&&(r<0&&QW(r,a,1/3)&&(r-=a),o>0&&QW(o,a,1/3)&&(o+=a));return s.min=jW(r,a),s.max=qW(o,a),s}(e.seriesMin,e.seriesMax,e);return this.totalOptions=function(e,t){return{min:HN(t.min)?Math.min(e.min,t.min):e.min,max:HN(t.max)?Math.max(e.max,t.max):e.max,majorUnit:e.majorUnit}}(t,e),function(e,t){let n=t;let i,r;if(t){!function(e,t){for(let n=0;n<t.length;n++){const i=t[n];null===e[i]&&(e[i]=void 0)}}(t,["min","max"]),i=HN(t.min),r=HN(t.max);const o=i||r;o&&t.min===t.max&&(t.min>0?t.min=0:t.max=1),t.majorUnit?(e.min=jW(e.min,t.majorUnit),e.max=qW(e.max,t.majorUnit)):o&&(n=cN(e,t),e.majorUnit=cU(n.min,n.max))}e.minorUnit=(n.majorUnit||e.majorUnit)/5;const o=cN(e,n);o.min>=o.max&&(i&&!r?o.max=o.min+o.majorUnit:!i&&r&&(o.min=o.max-o.majorUnit));return o}(t,e)}initFields(){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}clone(){return new YW(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)}startValue(){return 0}range(){const e=this.options;return{min:e.min,max:e.max}}getDivisions(e){if(0===e)return 1;const t=this.options;const n=t.max-t.min;return Math.floor(GN(n/e,3))+1}getTickPositions(e,t){const n=this.options;const{axisDir:i,axisOrigin:r,lineBox:o,lineSize:a}=this.lineInfo();const s=e*(a/(n.max-n.min));const l=this.getDivisions(e);const c=[];let d=o[r];let h=0;t&&(h=t/e);for(let e=0;e<l;e++)e%h!=0&&c.push(GN(d,3)),d+=s*i;return c}getMajorTickPositions(){return this.getTickPositions(this.options.majorUnit)}getMinorTickPositions(){return this.getTickPositions(this.options.minorUnit)}getSlot(e,t,n=!1){const i=this.options;const{axis:r,axisDir:o,lineBox:a,lineSize:s,lineStart:l}=this.lineInfo();const c=o*(s/(i.max-i.min));let d=YN(e,t||0);let h=YN(t,e||0);n&&(d=WN(d,i.min,i.max),h=WN(h,i.min,i.max));const u=Math.min(d,h)-i.min;const p=Math.max(d,h)-i.min;const f=new hU(a.x1,a.y1,a.x1,a.y1);return f[r+1]=GW(l+c*(o>0?u:p)),f[r+2]=GW(l+c*(o>0?p:u)),f}getValue(e){const t=this.options;const n=Number(t.max);const i=Number(t.min);const r=this.pointOffset(e);if(r<0||r>1)return null;return GN(i+r*(n-i),pV)}translateRange(e){const t=this.options;const{vertical:n,reverse:i,max:r,min:o}=t;const{lineSize:a}=this.lineInfo();let s=GN(e/(a/(r-o)),pV);return!n&&!i||n&&i||(s=-s),{min:o+s,max:r+s,offset:s}}labelsCount(){return this.getDivisions(this.options.majorUnit)}createAxisLabel(e,t,n){const i=this.options;const r=GN(i.min+e*i.majorUnit,pV);const o=this.axisLabelText(r,t,n);return new VU(r,o,e,null,t)}shouldRenderNote(e){const t=this.range();return t.min<=e&&e<=t.max}pan(e){const t=this.translateRange(e);return this.limitRange(t.min,t.max,this.totalMin,this.totalMax,t.offset)}pointsRange(e,t){const n=this.getValue(e);const i=this.getValue(t);const r=Math.min(n,i);const o=Math.max(n,i);if(this.isValidRange(r,o))return{min:r,max:o}}scaleRange(e,t){const n=Math.abs(this.pointOffset(t));const i=this.options.max-this.options.min;const r=this.scaleToDelta(e,i);const o=n*r;const a=(1-n)*r;const s=GN(this.options.min+o,pV);let l=GN(this.options.max-a,pV);return l-s<KW&&(l=s+KW),{min:s,max:l}}zoomRange(e,t){const{totalMin:n,totalMax:i}=this;const r=this.scaleRange(e,t);return{min:WN(r.min,n,i),max:WN(r.max,n,i),narrowRange:!1}}isValidRange(e,t){return t-e>KW}}function QW(e,t,n){const i=GN(Math.abs(e%t),pV);return 0===i||i>t*(1-n)}XN(YW,{type:"numeric",min:0,max:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:aV},labels:{format:"#.####################"},zIndex:1});class XW extends JU{constructor(e,t,n,i){const r=_W(e);const o=_W(t);const a=i.intl;let s=n||{};s=cN(s||{},{min:IW(a,s.min),max:IW(a,s.max),axisCrossingValue:zW(a,s.axisCrossingValues||s.axisCrossingValue),weekStartDay:PW(s,a)}),s=function(e,t,n){const i=n.min||e;const r=n.max||t;const o=n.baseUnit||(r&&i?function(e){let t=iW;e>=fW?t=sW:e>=pW?t=aW:e>=uW?t=oW:e>=hW&&(t=rW);return t}(gW(r,i)):iW);const a=mW[o];const s=n.weekStartDay||0;const l=kW(TW(i)-1,o,s)||_W(r);const c=xW(TW(r)+1,o,s);const d=n.majorUnit?n.majorUnit:void 0;const h=d||qW(cU(l.getTime(),c.getTime()),a)/a;const u=EW(l,c,o);const p=qW(u,h)-u;const f=Math.floor(p/2);const m=p-f;n.baseUnit||delete n.baseUnit;return n.baseUnit=n.baseUnit||o,n.min=n.min||yW(l,-f,o,s),n.max=n.max||yW(c,m,o,s),n.minorUnit=n.minorUnit||h/5,n.majorUnit=h,n}(r,o,s),super(s,i),this.intlService=a,this.seriesMin=r,this.seriesMax=o;const l=s.weekStartDay||0;this.totalMin=TW(kW(TW(r)-1,s.baseUnit,l)),this.totalMax=TW(xW(TW(o)+1,s.baseUnit,l))}clone(){return new XW(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)}range(){const e=this.options;return{min:e.min,max:e.max}}getDivisions(e){const t=this.options;return Math.floor(EW(t.min,t.max,t.baseUnit)/e+1)}getTickPositions(e){const t=this.options;const{axisDir:n,lineSize:i,lineStart:r}=this.lineInfo();const o=this.getDivisions(e);const a=i/SW(t.max,t.min);const s=t.weekStartDay||0;const l=[r];for(let i=1;i<o;i++){const o=r+SW(yW(t.min,i*e,t.baseUnit,s),t.min)*a*n;l.push(GN(o,3))}return l}getMajorTickPositions(){return this.getTickPositions(this.options.majorUnit)}getMinorTickPositions(){return this.getTickPositions(this.options.minorUnit)}getSlot(e,t,n){return YW.prototype.getSlot.call(this,IW(this.intlService,e),IW(this.intlService,t),n)}getValue(e){const t=YW.prototype.getValue.call(this,e);return null!==t?_W(t):null}labelsCount(){return this.getDivisions(this.options.majorUnit)}createAxisLabel(e,t,n){const i=this.options;const r=e*i.majorUnit;const o=i.weekStartDay||0;let a=i.min;r>0&&(a=yW(a,r,i.baseUnit,o));const s=t.dateFormats[i.baseUnit];t.format=t.format||s;const l=this.axisLabelText(a,t,n);return new VU(a,l,e,null,t)}translateRange(e){const t=this.options;const n=this.lineBox();const{vertical:i,reverse:r}=t;const o=i?n.height():n.width();const a=this.range();const s=o/SW(a.max,a.min);let l=GN(e/s,pV);return!i&&!r||i&&r||(l=-l),{min:vW(t.min,l),max:vW(t.max,l),offset:l}}shouldRenderNote(e){const t=this.range();return CW(e,t.min)>=0&&CW(e,t.max)<=0}pan(e){const t=this.translateRange(e,!0);const n=this.limitRange(TW(t.min),TW(t.max),this.totalMin,this.totalMax,t.offset);if(n)return{min:_W(n.min),max:_W(n.max)}}pointsRange(e,t){const n=this.getValue(e);const i=this.getValue(t);const r=Math.min(n,i);const o=Math.max(n,i);return{min:_W(r),max:_W(o)}}scaleRange(e,t){const n=Math.abs(this.pointOffset(t));const i=this.options.max-this.options.min;const r=this.scaleToDelta(e,i);const o=n*r;const a=(1-n)*r;const s=_W(TW(this.options.min)+o);let l=_W(TW(this.options.max)-a);return l-s<1e3&&(l=_W(TW(s)+1e3)),{min:s,max:l}}zoomRange(e,t){const n=this.scaleRange(e,t);return{min:_W(WN(TW(n.min),this.totalMin,this.totalMax)),max:_W(WN(TW(n.max),this.totalMin,this.totalMax))}}}XN(XW,{type:hV,majorGridLines:{visible:!0,width:1,color:aV},labels:{dateFormats:HW}});const ZW=1e-6;class JW extends JU{constructor(e,t,n,i){const r=cN({majorUnit:10,min:e,max:t},n);const o=r.majorUnit;const a=function(e,t){const n=GN(tj(e,t),pV)%1;let i;i=e<=0?t:0!==n&&(n<.3||n>.9)?Math.pow(t,tj(e,t)+.2):Math.pow(t,Math.ceil(tj(e,t)));return i}(t,o);const s=function(e,t,n){const i=n.majorUnit;let r=e;e<=0?r=t<=1?Math.pow(i,-2):1:n.narrowRange||(r=Math.pow(i,Math.floor(tj(e,i))));return r}(e,t,r);const l=function(e,t,n,i){let{min:r,max:o}=n;HN(n.axisCrossingValue)&&n.axisCrossingValue<=0&&ej();HN(i.max)?i.max<=0&&ej():o=t;HN(i.min)?i.min<=0&&ej():r=e;return{min:r,max:o}}(s,a,r,n);r.max=l.max,r.min=l.min,r.minorUnit=n.minorUnit||GN(o-1,pV),super(r,i),this.totalMin=HN(n.min)?Math.min(s,n.min):s,this.totalMax=HN(n.max)?Math.max(a,n.max):a,this.logMin=GN(tj(l.min,o),pV),this.logMax=GN(tj(l.max,o),pV),this.seriesMin=e,this.seriesMax=t,this.createLabels()}clone(){return new JW(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)}startValue(){return this.options.min}getSlot(e,t,n){const{options:i,logMin:r,logMax:o}=this;const{majorUnit:a,min:s,max:l}=i;const{axis:c,axisDir:d,lineBox:h,lineSize:u,lineStart:p}=this.lineInfo();const f=d*(u/(o-r));let m=YN(e,t||1);let g=YN(t,e||1);if(m<=0||g<=0)return null;n&&(m=WN(m,s,l),g=WN(g,s,l)),m=tj(m,a),g=tj(g,a);const v=Math.min(m,g)-r;const _=Math.max(m,g)-r;const b=new hU(h.x1,h.y1,h.x1,h.y1);return b[c+1]=GW(p+f*(d>0?v:_)),b[c+2]=GW(p+f*(d>0?_:v)),b}getValue(e){const{options:t,logMin:n,logMax:i}=this;const{majorUnit:r}=t;const{axis:o,axisDir:a,lineStart:s,lineSize:l}=this.lineInfo();const c=(i-n)/l;const d=a*(e[o]-s);if(d<0||d>l)return null;const h=n+d*c;return GN(Math.pow(r,h),pV)}range(){const e=this.options;return{min:e.min,max:e.max}}translateRange(e){const{options:t,logMin:n,logMax:i}=this;const{reverse:r,vertical:o,majorUnit:a}=t;const s=this.lineBox();const l=o?s.height():s.width();let c=GN(e/(l/(i-n)),pV);return!o&&!r||o&&r||(c=-c),{min:Math.pow(a,n+c),max:Math.pow(a,i+c),offset:c}}labelsCount(){const e=Math.floor(this.logMax);return Math.floor(e-this.logMin)+1}getMajorTickPositions(){const e=[];return this.traverseMajorTicksPositions((t=>{e.push(t)}),{step:1,skip:0}),e}createTicks(e){const t=this.options;const{majorTicks:n,minorTicks:i,vertical:r}=t;const o=t.labels.mirror;const a=this.lineBox();const 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(XU(s,n))}return n.visible&&this.traverseMajorTicksPositions(l,n),i.visible&&this.traverseMinorTicksPositions(l,i),[]}createGridLines(e){const t=this.options;const{minorGridLines:n,majorGridLines:i,vertical:r}=t;const o=e.lineBox();const a={lineStart:o[r?"x1":"y1"],lineEnd:o[r?"x2":"y2"],vertical:r};const s=[];const l=this.gridLinesVisual();function c(e,t){TN(e,s)||(a.position=e,l.append(ZU(a,t)),s.push(e))}return i.visible&&this.traverseMajorTicksPositions(c,i),n.visible&&this.traverseMinorTicksPositions(c,n),l.children}traverseMajorTicksPositions(e,t){const{lineStart:n,step:i}=this.lineInfo();const{logMin:r,logMax:o}=this;for(let a=Math.ceil(r)+t.skip;a<=o;a+=t.step){e(GN(n+i*(a-r),pV),t)}}traverseMinorTicksPositions(e,t){const{min:n,max:i,minorUnit:r,majorUnit:o}=this.options;const{lineStart:a,step:s}=this.lineInfo();const{logMin:l,logMax:c}=this;for(let d=Math.floor(l);d<c;d++){const c=this._minorIntervalOptions(d);for(let d=t.skip;d<r;d+=t.step){const r=c.value+d*c.minorStep;if(r>i)break;if(r>=n){e(GN(a+s*(tj(r,o)-l),pV),t)}}}}createAxisLabel(e,t,n){const i=Math.ceil(this.logMin+e);const r=Math.pow(this.options.majorUnit,i);const o=this.axisLabelText(r,t,n);return new VU(r,o,e,null,t)}shouldRenderNote(e){const t=this.range();return t.min<=e&&e<=t.max}pan(e){const t=this.translateRange(e);return this.limitRange(t.min,t.max,this.totalMin,this.totalMax,t.offset)}pointsRange(e,t){const n=this.getValue(e);const i=this.getValue(t);return{min:Math.min(n,i),max:Math.max(n,i)}}scaleRange(e,t){const{majorUnit:n}=this.options;const i=tj(this.options.min,n);const r=tj(this.options.max,n);const o=Math.abs(this.pointOffset(t));const a=r-i;const s=this.scaleToDelta(e,a);const l=Math.pow(n,i+o*s);let c=Math.pow(n,r-(1-o)*s);return c-l<ZW&&(c=l+ZW),{min:l,max:c}}zoomRange(e,t){const n=this.scaleRange(e,t);const{totalMin:i,totalMax:r}=this;return{min:WN(n.min,i,r),max:WN(n.max,i,r)}}_minorIntervalOptions(e){const{minorUnit:t,majorUnit:n}=this.options;const i=Math.pow(n,e);return{value:i,minorStep:(Math.pow(n,e+1)-i)/t}}lineInfo(){const e=super.lineInfo();return e.step=e.axisDir*(e.lineSize/(this.logMax-this.logMin)),e}}function ej(){throw new Error("Non positive values cannot be used for a logarithmic axis")}function tj(e,t){return Math.log(e)/Math.log(t)}XN(JW,{type:"log",majorUnit:10,minorUnit:1,axisCrossingValue:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:aV},zIndex:1,_deferLabels:!0});const nj={createGridLines:function(e){const t=this.options;const n=Math.abs(this.box.center().y-e.lineBox().y1);let i=[];let r=!1;let o,a;return t.majorGridLines.visible&&(o=this.majorGridLineAngles(e),r=!0,i=this.renderMajorGridLines(o,n,t.majorGridLines)),t.minorGridLines.visible&&(a=this.minorGridLineAngles(e,r),LN(i,this.renderMinorGridLines(a,n,t.minorGridLines,e,r))),i},renderMajorGridLines:function(e,t,n){return this.renderGridLines(e,t,n)},renderMinorGridLines:function(e,t,n,i,r){const o=this.radiusCallback&&this.radiusCallback(t,i,r);return this.renderGridLines(e,t,n,o)},renderGridLines:function(e,t,n,i){const r={stroke:{width:n.width,color:n.color,dashType:n.dashType}};const o=this.box.center();const a=new Ia([o.x,o.y],t);const s=this.gridLinesVisual();for(let t=0;t<e.length;t++){const n=new Rs(r);i&&(a.radius=i(e[t])),n.moveTo(a.center).lineTo(a.pointAt(e[t]+180)),s.append(n)}return s.children},gridLineAngles:function(e,t,n,i,r){const o=this.intervals(t,n,i,r);const a=e.options;const s=a.visible&&!1!==(a.line||{}).visible;return IN(o,(e=>{const t=this.intervalAngle(e);if(!s||90!==t)return t}))}};class ij extends LW{range(){return{min:0,max:this.options.categories.length}}reflow(e){this.box=e,this.reflowLabels()}lineBox(){return this.box}reflowLabels(){const{labels:e,options:{labels:t}}=this;const n=t.skip||0;const i=t.step||1;const r=new hU;for(let t=0;t<e.length;t++){e[t].reflow(r);const o=e[t].box;e[t].reflow(this.getSlot(n+t*i).adjacentBox(0,o.width(),o.height()))}}intervals(e,t,n,i=!1){const r=this.options;const o=r.categories.length/e||1;const a=360/o;const s=n||1;const l=[];let c=0;for(let e=t||0;e<o;e+=s)c=r.reverse?360-e*a:e*a,c=GN(c,3)%360,i&&TN(c,i)||l.push(c);return l}majorIntervals(){return this.intervals(1)}minorIntervals(){return this.intervals(.5)}intervalAngle(e){return(360+e+this.options.startAngle)%360}majorAngles(){return IN(this.majorIntervals(),(e=>this.intervalAngle(e)))}createLine(){return[]}majorGridLineAngles(e){const t=this.options.majorGridLines;return this.gridLineAngles(e,1,t.skip,t.step)}minorGridLineAngles(e,t){const{minorGridLines:n,majorGridLines:i}=this.options;const r=t?this.intervals(1,i.skip,i.step):null;return this.gridLineAngles(e,.5,n.skip,n.step,r)}radiusCallback(e,t,n){if(t.options.type!==JO){const t=qN(360/(2*this.options.categories.length));const i=Math.cos(t)*e;const r=this.majorAngles();return function(t){return!n&&TN(t,r)?e:i}}}createPlotBands(){const e=this.options.plotBands||[];const t=this._plotbandGroup=new Us({zIndex:-1});for(let n=0;n<e.length;n++){const i=e[n];const r=this.plotBandSlot(i);const o=this.getSlot(i.from);const a=i.from-Math.floor(i.from);r.startAngle+=a*o.angle;const s=Math.ceil(i.to)-i.to;r.angle-=(s+a)*o.angle;const l=gU.current.createRing(r,{fill:{color:i.color,opacity:i.opacity},stroke:{opacity:i.opacity}});t.append(l)}this.appendVisual(t)}plotBandSlot(e){return this.getSlot(e.from,e.to-1)}getSlot(e,t){const n=this.options;const i=n.justified;const r=this.box;const o=this.majorAngles();const a=o.length;const s=360/a;let l=e;n.reverse&&!i&&(l=(l+1)%a),l=WN(Math.floor(l),0,a-1);let c=o[l];i&&(c-=s/2,c<0&&(c+=360));const d=s*(WN(Math.ceil(t||l),l,a-1)-l+1);return new pU(r.center(),0,r.height()/2,c,d)}slot(e,t){const n=this.getSlot(e,t);const i=n.startAngle+180;const r=i+n.angle;return new $a([n.center.x,n.center.y],{startAngle:i,endAngle:r,radiusX:n.radius,radiusY:n.radius})}pointCategoryIndex(e){const t=this.options.categories.length;let n=null;for(let i=0;i<t;i++){if(this.getSlot(i).containsPoint(e)){n=i;break}}return n}}XN(ij,{startAngle:90,labels:{margin:mN(10)},majorGridLines:{visible:!0},justified:!0}),cN(ij.prototype,nj);class rj extends JU{constructor(e,t){super(e,t);const n=this.options;n.minorUnit=n.minorUnit||n.majorUnit/2}getDivisions(e){return YW.prototype.getDivisions.call(this,e)-1}reflow(e){this.box=e,this.reflowLabels()}reflowLabels(){const{options:e,labels:t,options:{labels:n}}=this;const i=n.skip||0;const r=n.step||1;const o=new hU;const a=this.intervals(e.majorUnit,i,r);for(let e=0;e<t.length;e++){t[e].reflow(o);const n=t[e].box;t[e].reflow(this.getSlot(a[e]).adjacentBox(0,n.width(),n.height()))}}lineBox(){return this.box}intervals(e,t,n,i=!1){const r=this.options.min;const o=this.getDivisions(e);const a=[];const s=n||1;for(let n=t||0;n<o;n+=s){const t=(360+r+n*e)%360;i&&TN(t,i)||a.push(t)}return a}majorIntervals(){return this.intervals(this.options.majorUnit)}minorIntervals(){return this.intervals(this.options.minorUnit)}intervalAngle(e){return(540-e-this.options.startAngle)%360}createLine(){return[]}majorGridLineAngles(e){const t=this.options.majorGridLines;return this.gridLineAngles(e,this.options.majorUnit,t.skip,t.step)}minorGridLineAngles(e,t){const n=this.options;const{minorGridLines:i,majorGridLines:r}=n;const o=t?this.intervals(n.majorUnit,r.skip,r.step):null;return this.gridLineAngles(e,n.minorUnit,i.skip,i.step,o)}plotBandSlot(e){return this.getSlot(e.from,e.to)}getSlot(e,t){const{options:n,box:i}=this;const r=n.startAngle;let o=WN(e,n.min,n.max);let a=WN(t||o,o,n.max);if(n.reverse&&(o*=-1,a*=-1),o=(540-o-r)%360,a=(540-a-r)%360,a<o){const e=o;o=a,a=e}return new pU(i.center(),0,i.height()/2,o,a-o)}slot(e,t=e){const n=this.options;const i=360-n.startAngle;const r=this.getSlot(e,t);const o=Math.min(e,t);const a=Math.max(e,t);let s,l;return n.reverse?(s=o,l=a):(s=360-a,l=360-o),s=(s+i)%360,l=(l+i)%360,new $a([r.center.x,r.center.y],{startAngle:s,endAngle:l,radiusX:r.radius,radiusY:r.radius})}getValue(e){const t=this.options;const n=this.box.center();const i=e.x-n.x;const r=e.y-n.y;let o=Math.round(RN(Math.atan2(r,i)));let a=t.startAngle;return t.reverse||(o*=-1,a*=-1),(o+a+360)%360}valueRange(){return{min:0,max:2*Math.PI}}}XN(rj,{type:"polar",startAngle:0,reverse:!1,majorUnit:60,min:0,max:360,labels:{margin:mN(10)},majorGridLines:{color:aV,visible:!0,width:1},minorGridLines:{color:"#aaa"}}),cN(rj.prototype,nj,{createPlotBands:ij.prototype.createPlotBands,majorAngles:ij.prototype.majorAngles,range:YW.prototype.range,labelsCount:YW.prototype.labelsCount,createAxisLabel:YW.prototype.createAxisLabel});const oj={options:{majorGridLines:{visible:!0}},createPlotBands:function(){const{majorGridLines:{type:e},plotBands:t=[]}=this.options;const n=this.plotArea.polarAxis;const i=n.majorAngles();const r=n.box.center();const o=this._plotbandGroup=new Us({zIndex:-1});for(let n=0;n<t.length;n++){const a=t[n];const s={fill:{color:a.color,opacity:a.opacity},stroke:{opacity:a.opacity}};const l=this.getSlot(a.from,a.to,!0);const c=new pU(r,r.y-l.y2,r.y-l.y1,0,360);let d;d=e===JO?gU.current.createRing(c,s):Rs.fromPoints(this.plotBandPoints(c,i),s).close(),o.append(d)}this.appendVisual(o)},plotBandPoints:function(e,t){const n=[];const i=[];const r=[e.center.x,e.center.y];const o=new Ia(r,e.innerRadius);const a=new Ia(r,e.radius);for(let e=0;e<t.length;e++)n.push(o.pointAt(t[e]+180)),i.push(a.pointAt(t[e]+180));return n.reverse(),n.push(n[0]),i.push(i[0]),i.concat(n)},createGridLines:function(e){const t=this.options;const n=this.radarMajorGridLinePositions();const i=e.majorAngles();const r=e.box.center();let o=[];if(t.majorGridLines.visible&&(o=this.renderGridLines(r,n,i,t.majorGridLines)),t.minorGridLines.visible){const e=this.radarMinorGridLinePositions();LN(o,this.renderGridLines(r,e,i,t.minorGridLines))}return o},renderGridLines:function(e,t,n,i){const r={stroke:{width:i.width,color:i.color,dashType:i.dashType}};const{skip:o=0,step:a=0}=i;const s=this.gridLinesVisual();for(let l=o;l<t.length;l+=a){const o=e.y-t[l];if(o>0){const t=new Ia([e.x,e.y],o);if(i.type===JO)s.append(new Ra(t,r));else{const e=new Rs(r);for(let i=0;i<n.length;i++)e.lineTo(t.pointAt(n[i]+180));e.close(),s.append(e)}}}return s.children},getValue:function(e){const t=this.lineBox();const n=this.plotArea.polarAxis;const i=n.majorAngles();const r=n.box.center();const o=e.distanceTo(r);let a=o;if(this.options.majorGridLines.type!==JO&&i.length>1){const t=e.x-r.x;const n=e.y-r.y;const s=(RN(Math.atan2(n,t))+540)%360;i.sort((function(e,t){return aj(e,s)-aj(t,s)}));const l=90-aj(i[0],i[1])/2;const c=180-aj(s,i[0])-l;a=o*(Math.sin(qN(c))/Math.sin(qN(l)))}return this.axisType().prototype.getValue.call(this,new dU(t.x1,t.y2-a))}};function aj(e,t){return 180-Math.abs(Math.abs(e-t)-180)}class sj extends YW{radarMajorGridLinePositions(){return this.getTickPositions(this.options.majorUnit)}radarMinorGridLinePositions(){const e=this.options;let t=0;return e.majorGridLines.visible&&(t=e.majorUnit),this.getTickPositions(e.minorUnit,t)}axisType(){return YW}}cN(sj.prototype,oj);class lj extends JW{radarMajorGridLinePositions(){const e=[];return this.traverseMajorTicksPositions((function(t){e.push(t)}),this.options.majorGridLines),e}radarMinorGridLinePositions(){const e=[];return this.traverseMinorTicksPositions((function(t){e.push(t)}),this.options.minorGridLines),e}axisType(){return JW}}cN(lj.prototype,oj);class cj{constructor(e){this.closed=e}process(e){const t=e.slice(0);const n=[];let i=this.closed;let r=t.length;if(r>2&&(this.removeDuplicates(0,t),r=t.length),r<2||2===r&&t[0].equals(t[1]))return n;let o=t[0];let a=t[1];let s=t[2];for(n.push(new cs(o));o.equals(t[r-1]);)i=!0,t.pop(),r--;if(2===r){const e=this.tangent(o,a,$V,UV);return UN(n).controlOut(this.firstControlPoint(e,o,a,$V,UV)),n.push(new cs(a,this.secondControlPoint(e,o,a,$V,UV))),n}let l,c;if(i){o=t[r-1],a=t[0],s=t[1];const e=this.controlPoints(o,a,s);l=e[1],c=e[0]}else{const e=this.tangent(o,a,$V,UV);l=this.firstControlPoint(e,o,a,$V,UV)}let d=l;for(let e=0;e<=r-3;e++)if(this.removeDuplicates(e,t),r=t.length,e+3<=r){o=t[e],a=t[e+1],s=t[e+2];const i=this.controlPoints(o,a,s);UN(n).controlOut(d),d=i[1];const r=i[0];n.push(new cs(a,r))}if(i){o=t[r-2],a=t[r-1],s=t[0];const e=this.controlPoints(o,a,s);UN(n).controlOut(d),n.push(new cs(a,e[0])),UN(n).controlOut(e[1]),n.push(new cs(s,c))}else{const e=this.tangent(a,s,$V,UV);UN(n).controlOut(d),n.push(new cs(s,this.secondControlPoint(e,a,s,$V,UV)))}return n}removeDuplicates(e,t){for(;t[e+1]&&(t[e].equals(t[e+1])||t[e+1].equals(t[e+2]));)t.splice(e+1,1)}invertAxis(e,t,n){let 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{const r=this.lineFunction(e,t);const o=this.calculateFunction(r,n.x);e.y<=t.y&&n.y<=o||t.y<=e.y&&n.y>=o||(i=!0)}return i}isLine(e,t,n){const i=this.lineFunction(e,t);const r=this.calculateFunction(i,n.x);return e.x===t.x&&t.x===n.x||GN(r,1)===GN(n.y,1)}lineFunction(e,t){const n=(t.y-e.y)/(t.x-e.x);return[e.y-n*e.x,n]}controlPoints(e,t,n){let i=$V;let r=UV;let o=!1;let a=!1;let s;if(this.isLine(e,t,n))s=this.tangent(e,t,$V,UV);else{const l={x:this.isMonotonicByField(e,t,n,$V),y:this.isMonotonicByField(e,t,n,UV)};if(l.x&&l.y)s=this.tangent(e,n,$V,UV),o=!0;else if(this.invertAxis(e,t,n)&&(i=UV,r=$V),l[i])s=0;else{let o;o=n[r]<e[r]&&e[r]<=t[r]||e[r]<n[r]&&t[r]<=e[r]?dj((n[r]-e[r])*(t[i]-e[i])):-dj((n[i]-e[i])*(t[r]-e[r])),s=.01*o,a=!0}}const l=this.secondControlPoint(s,e,t,i,r);if(a){const e=i;i=r,r=e}const c=this.firstControlPoint(s,t,n,i,r);return o&&(this.restrictControlPoint(e,t,l,s),this.restrictControlPoint(t,n,c,s)),[l,c]}restrictControlPoint(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)}tangent(e,t,n,i){const r=t[n]-e[n];const o=t[i]-e[i];let a;return a=0===r?0:o/r,a}isMonotonicByField(e,t,n,i){return n[i]>t[i]&&t[i]>e[i]||n[i]<t[i]&&t[i]<e[i]}firstControlPoint(e,t,n,i,r){const o=t[i];const a=.333*(n[i]-o);return this.point(o+a,t[r]+a*e,i,r)}secondControlPoint(e,t,n,i,r){const o=t[i];const a=n[i];const s=.333*(a-o);return this.point(a-s,n[r]-s*e,i,r)}point(e,t,n,i){const r=new ba;return r[n]=e,r[i]=t,r}calculateFunction(e,t){const n=e.length;let i=0;for(let r=0;r<n;r++)i+=Math.pow(t,r)*e[r];return i}}function dj(e){return e<=0?-1:1}var hj=Object.freeze({__proto__:null,Axis:JU,AxisLabel:VU,Box:hU,BoxElement:SU,CategoryAxis:LW,ChartElement:vU,CurveProcessor:cj,DateCategoryAxis:WW,DateValueAxis:XW,FloatElement:zU,FontLoader:QN,Gradients:DU,HashMap:SN,InstanceObserver:DN,LogarithmicAxis:JW,Matrix:b$,Note:NU,NumericAxis:YW,Observable:O$,Point:dU,PolarAxis:rj,RadarCategoryAxis:ij,RadarLogarithmicAxis:lj,RadarNumericAxis:sj,Ring:pU,RootElement:IU,Sector:mU,ShapeBuilder:gU,ShapeElement:MU,Text:LU,TextBox:RU,Title:FU,UserEvents:lU,absoluteDateDiff:gW,addClass:YV,addDuration:yW,addTicks:vW,alignPathToPixel:ZV,append:LN,applyEventMap:x$,autoMajorUnit:cU,autoTextColor:h$,bindEvents:BN,ceilDate:xW,clockwise:JV,constants:GV,convertableToNumber:nN,createHashSet:m$,createPatternFill:CU,cycleDown:rN,cycleIndex:oN,cycleUp:iN,dateComparer:CW,dateDiff:SW,dateEquals:MW,dateIndex:DW,deepExtend:cN,defaultErrorHandler:g$,defined:HN,deg:RN,duration:EW,elementOffset:FN,elementScale:d$,elementSize:ON,elementStyles:fN,eventCoordinates:VN,eventElement:NN,eventMap:y$,find:a$,firstDay:PW,floorDate:kW,getAriaTemplate:bN,getSpacing:mN,getSupportedFeatures:I$,getTemplate:_N,getter:kN,grep:xN,hasClasses:CN,hasOwnProperty:_$,hashKey:$N,inArray:TN,interpolateValue:MN,isArray:KV,isFunction:aN,isNumber:eN,isObject:dN,isPlainObject:EN,isString:tN,keys:v$,last:UN,limitValue:WN,logToConsole:eo,lteDateIndex:function(e,t){let n=0;let i=t.length-1;let r;for(;n<=i;){r=Math.floor((n+i)/2);const o=t[r];if(o<e)n=r+1;else{if(!(o>e)){for(;MW(t[r-1],e);)r--;return r}i=r-1}}return t[r]<=e?r:r-1},map:IN,mousewheelDelta:PN,noop:P$,now:L$,objectKey:jN,off:E$,on:D$,parseDate:IW,parseDates:zW,rad:qN,rectToBox:BU,removeClass:XV,renderIcon:r$,round:GN,services:QU,setDefaultOptions:XN,sparseArrayLimits:o$,startOfWeek:bW,styleValue:hN,toDate:_W,toTime:TW,unbindEvents:KN,valueOrDefault:YN});class uj{constructor(e){this._axis=e,this.options=e.options}value(e){const t=this._axis;return t.getCategory?t.getCategory(e):t.getValue(e)}slot(e,t,n=!0){return this._axis.slot(e,t,n)}range(){return this._axis.range()}valueRange(){return this._axis.valueRange()}}function pj(e,t){for(let n=0;n<t.length;n++)if(t[n].options.name===e)return t[n].prepareUserOptions(),new uj(t[n])}class fj{constructor(e){this.visual=e.visual,this.chartsVisual=e.chartContainer.visual,this._pane=e}findAxisByName(e){return pj(e,this._pane.axes)}}class mj{constructor(e){this._plotArea=e,this.visual=e.visual,this.backgroundVisual=e._bgVisual}}function gj(e){const t=e.length;let n=0;for(let i=0;i<t;i++){eN(e[i])&&n++}return n}const vj={min:function(e){const t=e.length;let n=xV;for(let i=0;i<t;i++){const t=e[i];eN(t)&&(n=Math.min(n,t))}return n===xV?e[0]:n},max:function(e){const t=e.length;let n=CV;for(let i=0;i<t;i++){const t=e[i];eN(t)&&(n=Math.max(n,t))}return n===CV?e[0]:n},sum:function(e){const t=e.length;let n=0;for(let i=0;i<t;i++){const t=e[i];eN(t)&&(n+=t)}return n},sumOrNull:function(e){let t=null;return gj(e)&&(t=vj.sum(e)),t},count:function(e){const t=e.length;let n=0;for(let i=0;i<t;i++){const t=e[i];null!=t&&n++}return n},avg:function(e){const t=gj(e);let n=e[0];return t>0&&(n=vj.sum(e)/t),n},first:function(e){const t=e.length;for(let n=0;n<t;n++){const t=e[n];if(null!=t)return t}return e[0]}};function _j(e,t){if(null===t)return t;return kN(e)(t)}class bj{constructor(){this._valueFields={},this._otherFields={},this._nullValue={},this._undefinedValue={}}register(e,t=[OV],n={}){for(let i=0;i<e.length;i++){const r=e[i];this._valueFields[r]=t,this._otherFields[r]=n,this._nullValue[r]=this._makeValue(t,null),this._undefinedValue[r]=this._makeValue(t,void 0)}}canonicalFields(e){return this.valueFields(e).concat(this.otherFields(e))}valueFields(e){return this._valueFields[e.type]||[OV]}otherFields(e){return this._otherFields[e.type]||[OV]}bindPoint(e,t,n){const i=e.data;const r=void 0!==n?n:i[t];const o={valueFields:{value:r}};const a=this.valueFields(e);const s=this._otherFields[e.type];let l,c;if(null===r)c=this._nullValue[e.type];else if(void 0===r)c=this._undefinedValue[e.type];else if(Array.isArray(r)){const e=r.slice(a.length);c=this._bindFromArray(r,a),l=this._bindFromArray(e,s)}else if("object"==typeof r){const t=this.sourceFields(e,a);const n=this.sourceFields(e,s);c=this._bindFromObject(r,a,t),l=this._bindFromObject(r,s,n)}return void 0!==c&&(1===a.length?o.valueFields.value=c[a[0]]:o.valueFields=c),o.fields=l||{},o}_makeValue(e,t){const n={};const i=e.length;for(let r=0;r<i;r++){n[e[r]]=t}return n}_bindFromArray(e,t){const n={};if(t){const i=Math.min(t.length,e.length);for(let r=0;r<i;r++)n[t[r]]=e[r]}return n}_bindFromObject(e,t,n=t){const i={};if(t){const r=t.length;for(let o=0;o<r;o++){const r=t[o];const a=n[o];null!==a&&(i[r]=_j(a,e))}}return i}sourceFields(e,t){const n=[];if(t){const i=t.length;for(let r=0;r<i;r++){const i=t[r];const o=i===OV?"field":i+"Field";n.push(null!==e[o]?e[o]||i:null)}}return n}}bj.current=new bj;const wj=/percent(?:\w*)\((\d+)\)/;const yj=new RegExp("^stddev(?:\\((\\d+(?:\\.\\d+)?)\\))?$");class kj{constructor(e,t,n){this.initGlobalRanges(e,t,n)}initGlobalRanges(e,t,n){const i=t.data;const r=yj.exec(e);if(r){this.valueGetter=this.createValueGetter(t,n);const e=this.getAverage(i);const o=this.getStandardDeviation(i,e,!1);const a=r[1]?parseFloat(r[1]):1;const s={low:e.value-o*a,high:e.value+o*a};this.globalRange=function(){return s}}else if(e.indexOf&&e.indexOf("stderr")>=0){this.valueGetter=this.createValueGetter(t,n);const e=this.getStandardError(i,this.getAverage(i));this.globalRange=function(t){return{low:t-e,high:t+e}}}}createValueGetter(e,t){const n=e.data;const i=bj.current;const r=i.valueFields(e);const o=HN(n[0])?n[0]:{};let a;if(KV(o)){a=kN("["+(t?r.indexOf(t):0)+"]")}else if(eN(o))a=kN();else if(typeof o===DV){a=kN(i.sourceFields(e,r)[r.indexOf(t)])}return a}getErrorRange(e,t){let n,i,r;if(!HN(t))return null;if(this.globalRange)return this.globalRange(e);if(KV(t))n=e-t[0],i=e+t[1];else if(eN(r=parseFloat(t)))n=e-r,i=e+r;else{if(!(r=wj.exec(t)))throw new Error("Invalid ErrorBar value: "+t);{const t=e*(parseFloat(r[1])/100);n=e-Math.abs(t),i=e+Math.abs(t)}}return{low:n,high:i}}getStandardError(e,t){return this.getStandardDeviation(e,t,!0)/Math.sqrt(t.count)}getStandardDeviation(e,t,n){const i=e.length;const r=n?t.count-1:t.count;let o=0;for(let n=0;n<i;n++){const i=this.valueGetter(e[n]);eN(i)&&(o+=Math.pow(i-t.value,2))}return Math.sqrt(o/r)}getAverage(e){const t=e.length;let n=0;let i=0;for(let r=0;r<t;r++){const t=this.valueGetter(e[r]);eN(t)&&(n+=t,i++)}return{value:n/i,count:i}}}const xj=io.browser||{};const Cj=600;const Sj="fadeIn";const Tj=.8;const Mj=xj.msie?.001:0;const Aj="errorLow";const Dj="errorHigh";const Ej="xErrorLow";const Ij="xErrorHigh";const zj="yErrorLow";const Pj="yErrorHigh";const Lj="zero";const Bj="interpolate";const Hj="gap";const Rj="above";const Fj="below";const Oj="smooth";const Vj="step";const Nj="area";const $j="bar";const Uj="boxPlot";const Wj="bubble";const jj="bullet";const qj="candlestick";const Gj="column";const Kj="donut";const Yj="funnel";const Qj="pyramid";const Xj="heatmap";const Zj="horizontalWaterfall";const Jj="line";const eq="ohlc";const tq="pie";const nq="polarArea";const iq="polarLine";const rq="polarScatter";const oq="radarArea";const aq="radarColumn";const sq="radarLine";const lq="rangeArea";const cq="rangeBar";const dq="rangeColumn";const hq="scatter";const uq="scatterLine";const pq="verticalArea";const fq="verticalBoxPlot";const mq="verticalBullet";const gq="verticalLine";const vq="verticalRangeArea";const _q="waterfall";const bq=[$j,Gj,eq,qj,Uj,fq,jj,dq,cq,_q,Zj];const wq="exponentialTrendline";const yq="linearTrendline";const kq="logarithmicTrendline";const xq="movingAverageTrendline";const Cq="polynomialTrendline";const Sq="powerTrendline";const Tq=[wq,yq,kq,xq,Cq,Sq];const Mq="legendItemClick";const Aq="legendItemHover";const Dq="legendItemLeave";const Eq="seriesClick";const Iq="seriesHover";const zq="seriesOver";const Pq="seriesLeave";const Lq="plotAreaClick";const Bq="plotAreaHover";const Hq="plotAreaLeave";const Rq="drag";const Fq="dragEnd";const Oq="dragStart";const Vq="zoomStart";const Nq="zoom";const $q="zoomEnd";const Uq="selectStart";const Wq="select";const jq="selectEnd";const qq="render";const Gq="showTooltip";const Kq="hideTooltip";const Yq="paneRender";const Qq="graphics-symbol";const Xq="k-chart-point";const Zq="Point";const Jq="checkbox";const eG="k-chart-legend-item";const tG="Legend item";const nG="log";const iG="category";const rG="insideEnd";const oG="insideBase";const aG="outsideEnd";const sG="wheel";const lG=150;const cG="drilldown";const dG="drilldown";const hG="pattern";var uG=Object.freeze({__proto__:null,ABOVE:Rj,AREA:Nj,BAR:$j,BELOW:Fj,BORDER_BRIGHTNESS:Tj,BOTTOM:"bottom",BOX_PLOT:Uj,BUBBLE:Wj,BULLET:jj,CANDLESTICK:qj,CATEGORY:iG,CHART_POINT_CLASSNAME:Xq,CHART_POINT_ROLE:Qq,CHART_POINT_ROLE_DESCRIPTION:Zq,COLUMN:Gj,DONUT:Kj,DRAG:Rq,DRAG_END:Fq,DRAG_START:Oq,DRILLDOWN:cG,DRILLDOWN_FIELD:dG,EQUALLY_SPACED_SERIES:bq,ERROR_HIGH_FIELD:Dj,ERROR_LOW_FIELD:Aj,FADEIN:Sj,FUNNEL:Yj,GAP:Hj,GLASS:"glass",HEATMAP:Xj,HIDE_TOOLTIP:Kq,HORIZONTAL_WATERFALL:Zj,INITIAL_ANIMATION_DURATION:Cj,INSIDE_BASE:oG,INSIDE_END:rG,INTERPOLATE:Bj,LEGEND_ITEM_ARIA_ROLE_DESCRIPTION:tG,LEGEND_ITEM_CLASSNAME:eG,LEGEND_ITEM_CLICK:Mq,LEGEND_ITEM_HOVER:Aq,LEGEND_ITEM_LEAVE:Dq,LEGEND_ITEM_ROLE:Jq,LINE:Jj,LINE_MARKER_SIZE:8,LOGARITHMIC:nG,MIN_MOVING_AVERAGE_PERIOD:2,MOUSEWHEEL:sG,MOUSEWHEEL_DELAY:lG,MOUSEWHEEL_ZOOM_RATE:.3,OHLC:eq,OUTSIDE_END:aG,PANE_RENDER:Yq,PATTERN_FIELD:hG,PIE:tq,PLOT_AREA_CLICK:Lq,PLOT_AREA_HOVER:Bq,PLOT_AREA_LEAVE:Hq,POLAR_AREA:nq,POLAR_LINE:iq,POLAR_SCATTER:rq,PYRAMID:Qj,RADAR_AREA:oq,RADAR_COLUMN:aq,RADAR_LINE:sq,RANGE_AREA:lq,RANGE_BAR:cq,RANGE_COLUMN:dq,RENDER:qq,SCATTER:hq,SCATTER_LINE:uq,SELECT:Wq,SELECT_END:jq,SELECT_START:Uq,SERIES_CLICK:Eq,SERIES_HOVER:Iq,SERIES_LEAVE:Pq,SERIES_OVER:zq,SHOW_TOOLTIP:Gq,SMOOTH:Oj,START_SCALE:Mj,STEP:Vj,TOOLTIP_OFFSET:5,TRENDLINE_EXPONENTIAL:wq,TRENDLINE_LINEAR:yq,TRENDLINE_LOGARITHMIC:kq,TRENDLINE_MOVING_AVERAGE:xq,TRENDLINE_POLYNOMIAL:Cq,TRENDLINE_POWER:Sq,TRENDLINE_SERIES:Tq,VERTICAL_AREA:pq,VERTICAL_BOX_PLOT:fq,VERTICAL_BULLET:mq,VERTICAL_LINE:gq,VERTICAL_RANGE_AREA:vq,WATERFALL:_q,X_ERROR_HIGH_FIELD:Ij,X_ERROR_LOW_FIELD:Ej,Y_ERROR_HIGH_FIELD:Pj,Y_ERROR_LOW_FIELD:zj,ZERO:Lj,ZOOM:Nq,ZOOM_END:$q,ZOOM_START:Vq});class pG extends vU{constructor(e,t,n,i,r,o){super(o),this.low=e,this.high=t,this.isVertical=n,this.chart=i,this.series=r}reflow(e){const t=this.options.endCaps;const n=this.isVertical;const i=this.getAxis().getSlot(this.low,this.high);const r=e.center();const o=this.getCapsWidth(e,n);const a=n?r.x:r.y;const s=a-o;const l=a+o;let c;n?(c=[new dU(r.x,i.y1),new dU(r.x,i.y2)],t&&c.push(new dU(s,i.y1),new dU(l,i.y1),new dU(s,i.y2),new dU(l,i.y2)),this.box=new hU(s,i.y1,l,i.y2)):(c=[new dU(i.x1,r.y),new dU(i.x2,r.y)],t&&c.push(new dU(i.x1,s),new dU(i.x1,l),new dU(i.x2,s),new dU(i.x2,l)),this.box=new hU(i.x1,s,i.x2,l)),this.linePoints=c}getCapsWidth(e,t){const n=t?e.width():e.height();return Math.min(Math.floor(n/2),4)||4}createVisual(){const e=this.options;const t=e.visual;t?this.visual=t({low:this.low,high:this.high,rect:this.box.toRect(),sender:this.getSender(),options:{endCaps:e.endCaps,color:e.color,line:e.line},createVisual:()=>{this.createDefaultVisual();const e=this.visual;return delete this.visual,e}}):this.createDefaultVisual()}createDefaultVisual(){const{options:e,linePoints:t}=this;const n={stroke:{color:e.color,width:e.line.width,dashType:e.line.dashType}};super.createVisual();for(let e=0;e<t.length;e+=2){const i=new Rs(n).moveTo(t[e].x,t[e].y).lineTo(t[e+1].x,t[e+1].y);ZV(i),this.visual.append(i)}}}XN(pG,{animation:{type:Sj,delay:Cj},endCaps:!0,line:{width:2},zIndex:1});class fG extends pG{getAxis(){return this.chart.seriesValueAxis(this.series)}}function mG(e){for(let t=0;t<e.length;t++)if(HN(e[t].zIndex))return!0}function gG(e,t){null!==t&&e.push(t)}function vG(e){return gj(e)===e.length}function _G(e,t,n){const i=t.visible;if(HN(i))return i;const r=e.pointVisibility;return r?r[n]:void 0}function bG(e){const t=e.data;const n=[];let i=0;let r=0;for(let o=0;o<t.length;o++){const t=bj.current.bindPoint(e,o);let a=t.valueFields.value;tN(a)&&(a=parseFloat(a)),eN(a)?(t.visible=!1!==_G(e,t.fields,o),t.value=Math.abs(a),n.push(t),t.visible&&(i+=t.value),0!==a&&r++):n.push(null)}return{total:i,points:n,count:r}}function wG(e){const t=e.length;let n=0;for(let i=0;i<t;i++)n=Math.max(n,e[i].data.length);return n}function yG(e,t){return e&&t?e.toLowerCase()===t.toLowerCase():e===t}function kG(e,t,n={},i=!1){const r=n.defaults=n.defaults||{};const o=n.depth=n.depth||0;let a=!1;if(n.excluded=n.excluded||[],o>5)return null;for(let o in e)if(!TN(o,n.excluded)&&_$(e,o)){const s=e[o];aN(s)?(a=!0,i||(e[o]=YN(s(t),r[o]))):dN(s)&&(i||(n.defaults=r[o]),n.depth++,a=kG(s,t,n,i)||a,n.depth--)}return a}function xG(e,t){const n=[];const i=[].concat(t);for(let t=0;t<e.length;t++){const r=e[t];TN(r.type,i)&&n.push(r)}return n}const CG=new WeakMap;function SG(e,t,n){if(null===t||"object"!=typeof t)return IW(n,e);let i=CG.get(t);return i||(i=IW(n,e),CG.set(t,i)),i}function TG(e){const t=e.overlay;return t&&t.gradient&&"none"!==t.gradient}function MG(e){return HN(e)&&null!==e}function AG(e,t){const n=e.type;const i=t instanceof Date;return!n&&i||yG(n,hV)}function DG(e){return 1===e.length?e[0]:e}const EG=/area/i;function IG(e,t){const n=bj.current.bindPoint(e,null,t).valueFields;for(let e in n)if(nN(n[e]))return!0}function zG({start:e,dir:t,min:n,max:i,getter:r,hasItem:o,series:a}){let s,l;let c=e;do{c+=t,o(c)&&(l=r(c),s=IG(a,l.item))}while(n<=c&&c<=i&&!s);if(s)return l}function PG(e,t,n,i,r){const{min:o,max:a}=t;const s=o>0&&o<n;const l=a+1<n;if(s||l){const t=function(e){return e.missingValues?e.missingValues:EG.test(e.type)||e.stack?Lj:Bj}(e);let c,d;if(t!==Bj)s&&(c=i(o-1)),l&&(d=i(a+1));else{let t,h;s&&(t=i(o-1),h=IG(e,t.item),c=h?t:zG({start:o,dir:-1,min:0,max:n-1,getter:i,hasItem:r,series:e})),l&&(t=i(a+1),h=IG(e,t.item),d=h?t:zG({start:a,dir:1,min:0,max:n-1,getter:i,hasItem:r,series:e}))}c&&(e._outOfRangeMinPoint=c),d&&(e._outOfRangeMaxPoint=d)}}function LG(e,t){return t.forEach((t=>{const n=t&&t.options;const i=t&&(t.box||t.wrapperBox);n&&i&&!1!==n.noclip&&!1!==n.visible&&e.wrap(i)})),e}class BG extends vU{constructor(e,t){super(t),this.plotArea=e,this.chartService=e.chartService,this.categoryAxis=e.seriesCategoryAxis(t.series[0]),this.valueAxisRanges={},this.points=[],this.categoryPoints=[],this.seriesPoints=[],this.seriesOptions=[],this._evalSeries=[],this.render()}render(){this.traverseDataPoints(this.addValue.bind(this))}pointOptions(e,t){let n=this.seriesOptions[t];if(!n){const i=this.pointType().prototype.defaults;this.seriesOptions[t]=n=cN({},i,{vertical:!this.options.invertAxes},e)}return n}plotValue(e){if(!e)return 0;if(this.options.isStacked100&&eN(e.value)){const t=e.categoryIx;const n=this.categoryPoints[t];const i=[];let r=0;for(let t=0;t<n.length;t++){const o=n[t];if(o){const t=e.series.stack;const n=o.series.stack;if(t&&n&&t.group!==n.group)continue;eN(o.value)&&(r+=Math.abs(o.value),i.push(Math.abs(o.value)))}}if(r>0)return e.value/r}return e.value}plotRange(e,t=0){const n=this.categoryPoints[e.categoryIx];if(this.options.isStacked){let i=this.plotValue(e);const r=i>=0;let o=t;let a=!1;const s=void 0!==e.series.stack?e.series.stack:this.options.defaultStack;const l=e=>!0===e||typeof e===DV&&!e.group;if(s)for(let c=0;c<n.length;c++){const d=n[c];if(e===d)break;const h=void 0!==d.series.stack?d.series.stack:this.options.defaultStack;if(!h)continue;if(typeof s===LV&&s!==h)continue;if(l(s)&&!l(h))continue;if(s.group&&s.group!==h.group)continue;const u=this.plotValue(d);(u>=0&&r||u<0&&!r)&&(0!==t&&0===u||(o+=u,i+=u,a=!0,this.options.isStacked100&&(i=Math.min(i,1))))}return a&&(o-=t),[o,i]}const i=e.series;const r=this.seriesValueAxis(i);const o=this.categoryAxisCrossingValue(r);return[o,nN(e.value)?e.value:o]}stackLimits(e,t){let n=xV;let i=CV;for(let r=0;r<this.categoryPoints.length;r++){const o=this.categoryPoints[r];if(o)for(let r=0;r<o.length;r++){const a=o[r];if(a&&(a.series.stack===t||a.series.axis===e)){const e=this.plotRange(a,0)[1];void 0!==e&&isFinite(e)&&(i=Math.max(i,e),n=Math.min(n,e))}}}return{min:n,max:i}}updateStackRange(){const{isStacked:e,series:t}=this.options;const n={};if(e)for(let e=0;e<t.length;e++){const i=t[e];const r=i.axis;const o=r+i.stack;let a=n[o];if(!a){a=this.stackLimits(r,i.stack);const e=this.errorTotals;e&&(e.negative.length&&(a.min=Math.min(a.min,o$(e.negative).min)),e.positive.length&&(a.max=Math.max(a.max,o$(e.positive).max))),a.min!==xV||a.max!==CV?n[o]=a:a=null}a&&(this.valueAxisRanges[r]=a)}}addErrorBar(e,t,n){const{value:i,series:r,seriesIx:o}=e;const a=e.options.errorBars;const s=t.fields[Aj];const l=t.fields[Dj];let c;eN(s)&&eN(l)?c={low:s,high:l}:a&&void 0!==a.value&&(this.seriesErrorRanges=this.seriesErrorRanges||[],this.seriesErrorRanges[o]=this.seriesErrorRanges[o]||new kj(a.value,r,OV),c=this.seriesErrorRanges[o].getErrorRange(i,a.value)),c&&(e.low=c.low,e.high=c.high,this.addPointErrorBar(e,n))}addPointErrorBar(e,t){const n=!this.options.invertAxes;const i=e.options.errorBars;let{series:r,low:o,high:a}=e;if(this.options.isStacked){const n=this.stackedErrorRange(e,t);o=n.low,a=n.high}else{const e={categoryIx:t,series:r};this.updateRange({value:o},e),this.updateRange({value:a},e)}const s=new fG(o,a,n,this,r,i);e.errorBars=[s],e.append(s)}stackedErrorRange(e,t){const n=this.plotRange(e,0)[1]-e.value;const i=e.low+n;const 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}}addValue(e,t){const{categoryIx:n,series:i,seriesIx:r}=t;let o=this.categoryPoints[n];o||(this.categoryPoints[n]=o=[]);let a=this.seriesPoints[r];a||(this.seriesPoints[r]=a=[]);const s=this.createPoint(e,t);s&&(Object.assign(s,t),s.owner=this,s.noteText=e.fields.noteText,void 0===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)}evalPointOptions(e,t,n){const i=n.categoryIx;const r=n.category;const o=n.series;const a=n.seriesIx;const s={defaults:o._defaults,excluded:["data","aggregate","_events","tooltip","content","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint","drilldownSeriesFactory","ariaTemplate","ariaContent"]};let l=this._evalSeries[a];void 0===l&&(this._evalSeries[a]=l=kG(e,{},s,!0));let c=e;return l&&(c=cN({},c),kG(c,{value:t,category:r,index:i,series:o,dataItem:o.data[i]},s)),c}updateRange(e,t){const n=t.series.axis;const i=e.value;let r=this.valueAxisRanges[n];isFinite(i)&&null!==i&&(r=this.valueAxisRanges[n]=r||{min:xV,max:CV},r.min=Math.min(r.min,i),r.max=Math.max(r.max,i))}seriesValueAxis(e){const t=this.plotArea;const n=e.axis;const i=n?t.namedValueAxes[n]:t.valueAxis;if(!i)throw new Error("Unable to locate value axis with name "+n);return i}reflow(e){const t=this.categorySlots=[];const n=this.points;const i=this.categoryAxis;let r=0;this.traverseDataPoints(((e,o)=>{const{categoryIx:a,series:s}=o;const l=this.seriesValueAxis(s);const c=n[r++];let d=t[a];if(d||(t[a]=d=this.categorySlot(i,a,l)),c){const e=this.plotRange(c,l.startValue());const t=this.valueSlot(l,e);if(t){const n=this.pointSlot(d,t);c.aboveAxis=this.aboveAxis(c,l),c.stackValue=e[1],this.options.isStacked100&&(c.percentage=this.plotValue(c)),this.reflowPoint(c,n)}else c.visible=!1}})),this.reflowCategories(t),!this.options.clip&&this.options.limitPoints&&this.points.length&&this.limitPoints(),this.box=e}valueSlot(e,t){return e.getSlot(t[0],t[1],!this.options.clip)}limitPoints(){const e=this.categoryPoints;const t=e[0].concat(UN(e));for(let e=0;e<t.length;e++)t[e]&&this.limitPoint(t[e])}limitPoint(e){const t=this.categoryAxis.limitSlot(e.box);t.equals(e.box)||e.reflow(t)}aboveAxis(e,t){const n=this.categoryAxisCrossingValue(t);const i=e.value;return t.options.reverse?i<n:i>=n}categoryAxisCrossingValue(e){const t=this.categoryAxis;const n=e.options;return[].concat(n.axisCrossingValues||n.axisCrossingValue)[t.axisIndex||0]||0}reflowPoint(e,t){e.reflow(t)}reflowCategories(){}pointSlot(e,t){const n=this.options.invertAxes;const i=n?t:e;const r=n?e:t;return new hU(i.x1,r.y1,i.x2,r.y2)}categorySlot(e,t){return e.getSlot(t)}traverseDataPoints(e){const t=this.options.series;const n=wG(t);const i=t.length;for(let n=0;n<i;n++)this._outOfRangeCallback(t[n],"_outOfRangeMinPoint",n,e);for(let r=0;r<n;r++){const o=this.categoryAxis.categoryAt(r);for(let a=0;a<i;a++){const i=t[a];e(this.plotArea.bindPoint(i,r),{category:o,categoryIx:r,categoriesCount:n,series:i,seriesIx:a})}}for(let n=0;n<i;n++)this._outOfRangeCallback(t[n],"_outOfRangeMaxPoint",n,e)}_outOfRangeCallback(e,t,n,i){const r=e[t];if(r){const t=r.categoryIx;i(this.plotArea.bindPoint(e,t,r.item),{category:r.category,categoryIx:t,series:e,seriesIx:n,dataItem:r.item})}}formatPointValue(e,t){return null===e.value?"":this.chartService.format.auto(t,e.value)}pointValue(e){return e.valueFields.value}}XN(BG,{series:[],invertAxes:!1,isStacked:!1,clip:!0,limitPoints:!0});const HG={click:function(e,t){return e.trigger(Eq,this.eventArgs(t))},hover:function(e,t){return e.trigger(Iq,this.eventArgs(t))},over:function(e,t){return e.trigger(zq,this.eventArgs(t))},out:function(e,t){return e.trigger(Pq,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:NN(e),originalEvent:e,point:this}}};const RG={createNote:function(){const e=this.options.notes;const t=this.noteText||e.label.text;!1!==e.visible&&null!=t&&(this.note=new NU({value:this.value,text:t,dataItem:this.dataItem,category:this.category,series:this.series},this.options.notes,this.owner.chartService),this.append(this.note))}};class FG extends vU{constructor(e,t){super(t),this.value=e,this.aboveAxis=YN(this.options.aboveAxis,!0),this.tooltipTracking=!0,this._id=S$()}initOptions(e){this.options=Object.assign({},e)}render(){const{markers:e}=this.options;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))}createLabel(){const e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))}createLabelElement(e){return new RU(this.getLabelText(e),Object.assign({},{align:lV,vAlign:lV,zIndex:YN(e.zIndex,this.series.zIndex)},e,{margin:Object.assign({},{left:5,right:5},e.margin)}),this.pointData())}getLabelText(e){let t=_N(e);return t?t(this.pointData()):e.format?this.formatValue(e.format):this.value}getAriaLabelText(){const e=this.options.labels;const t=bN(e);return t?t(this.pointData()):this.getLabelText(e)}markerBorder(){const e=this.options.markers;const t=e.background;const n=Object.assign({},{color:this.color},e.border);return void 0===n.color&&(n.color=new bo(t).brightness(Tj).toHex()),n}createVisual(){}createMarker(){const e=this.options.markers;return new MU({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:YN(e.zIndex,this.series.zIndex),animation:e.animation,visual:e.visual,accessibilityOptions:Object.assign({},{ariaLabel:this.getAriaLabelText(this.options.labels)},this.options.accessibility)},{dataItem:this.dataItem,value:this.value,series:this.series,category:this.category})}markerBox(){return this.marker||(this.marker=this.createMarker(),this.marker.reflow(this._childBox)),this.marker.box}reflow(e){const{options:t,aboveAxis:n}=this;const i=t.vertical;this.render(),this.box=e;const 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(let e=0;e<this.errorBars.length;e++)this.errorBars[e].reflow(r);if(this.note){let e=this.markerBox();if(!t.markers.visible||!t.markers.size){const t=e.center();e=new hU(t.x,t.y,t.x,t.y)}this.note.reflow(e)}}reflowLabel(e){const{options:t,label:n}=this;let i=t.labels.position;n&&(i=i===Rj?BV:i,i=i===Fj?sV:i,n.reflow(e),n.box.alignTo(this.markerBox(),i),n.reflow(n.box))}createHighlight(){const e=this.options.highlight.markers;const t=this.markerBorder().color;const n=this.options.markers;const i=n.size+(n.border.width||0)+(e.border.width||0);const r=new MU({type:n.type,width:i,height:i,rotation:n.rotation,background:e.color||t,border:{color:e.border.color,width:e.border.width,opacity:YN(e.border.opacity,1)},opacity:YN(e.opacity,1)});return r.reflow(this._childBox),r.getElement()}highlightVisual(){return(this.marker||{}).visual}highlightVisualArgs(){const e=this.marker;let t,n;if(e)n=e.paddingBox.toRect(),t=e.visual;else{const e=this.options.markers.size;const t=e/2;const i=this.box.center();n=new ya([i.x-t,i.y-t],[e,e])}return{options:this.options,rect:n,visual:t}}createFocusHighlight(){const e=this.options.markers;const t=this.options.focusHighlight;const n=e.size+(e.border.width||0);const i=new MU({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()}tooltipAnchor(){const e=this.markerBox();const t=this.owner.pane.clipBox();if(!t||t.overlaps(e)){const t=e.x2+5;const n=kV;let i,r;return this.aboveAxis?(i=e.y1,r=sV):(i=e.y2,r=BV),{point:new dU(t,i),align:{horizontal:n,vertical:r}}}}formatValue(e){return this.owner.formatPointValue(this,e)}overlapsBox(e){return this.markerBox().overlaps(e)}clipElements(){this.options.visible=!1}unclipElements(){this.label&&(this.label.options.noclip=!0),this.note&&(this.note.options.noclip=!0)}unclipBox(){return LG(this.markerBox().clone(),[this.label,this.note])}labelBox(){return this.label?this.label.box:new hU}noteBox(){return this.note?this.note.box:new hU}pointData(){return{dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,stackValue:this.stackValue,series:this.series}}focusVisual(){this.marker&&(this.marker.visual&&this.marker.visual.options.set("id",this._id),this.toggleFocusHighlight(!0))}clearFocusFromVisual(){this.marker&&(this.marker.visual&&this.marker.visual.options.set("id",""),this.toggleFocusHighlight(!1))}getIndex(){return void 0!==this.categoryIx?this.categoryIx:this.pointIx}}FG.prototype.defaults={vertical:!0,markers:{visible:!0,background:VV,size:8,type:cV,border:{width:2},opacity:1},labels:{visible:!1,position:Rj,margin:mN(3),padding:mN(4),animation:{type:Sj,delay:Cj}},notes:{label:{}},highlight:{markers:{border:{color:"#fff",width:2}},zIndex:100},errorBars:{line:{width:1}},accessibility:{tabIndex:0,role:Qq,className:Xq,ariaRoleDescription:Zq}},cN(FG.prototype,HG),cN(FG.prototype,RG);class OG extends vU{constructor(e,t,n){super(),this.linePoints=e,this.series=t,this.seriesIx=n}points(){return this.toGeometryPoints(this.linePoints)}toGeometryPoints(e){const t=[];for(let n=0,i=e.length;n<i;n++)e[n]&&!1!==e[n].visible&&t.push(e[n]._childBox.toRect().center());return t}createVisual(){const e=this.series.visual;e?(this.visual=e({points:this.toGeometryPoints(this.linePoints),series:this.series,sender:this.getSender(),createVisual:()=>(this.segmentVisual(),this.visual)}),this.visual&&!HN(this.visual.options.zIndex)&&(this.visual.options.zIndex=this.series.zIndex)):this.segmentVisual()}segmentVisual(){const{options:e,series:t}=this;let{color:n,_defaults:i}=t;aN(n)&&i&&(n=i.color);const r=Rs.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}aliasFor(e,t){return this.parent.getNearestPoint(t.x,t.y,this.seriesIx)}}XN(OG,{closed:!1});const VG={calculateStepPoints:function(e){const t=this.parent.plotArea.seriesCategoryAxis(this.series);const{justified:n,vertical:i,reverse:r}=t.options;const o=i?$V:UV;const a=i?UV:$V;const s=r?2:1;const l=s;let c=NG(e[0],o,s,a,l);const d=[c];for(let t=1;t<e.length;t++){const n=NG(e[t],o,s,a,l);if(c[o]!==n[o]){const e=new ba;e[o]=c[o],e[a]=n[a],d.push(e,n)}c=n}return n?c!==UN(d)&&d.push(c):d.push(NG(UN(e),o,s,a,r?1:2)),d}};function NG(e,t,n,i,r){const o=e.box;const a=new ba;return a[t]=o[t+n],a[i]=o[i+r],a}class $G extends OG{points(){return this.calculateStepPoints(this.linePoints)}}cN($G.prototype,VG);class UG extends OG{segmentVisual(){const e=this.series;const t=e._defaults;let n=e.color;aN(n)&&t&&(n=t.color);const i=new cj(this.options.closed).process(this.points());const r=new Rs({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}}const WG={renderSegments:function(){const{options:e,seriesPoints:t}=this;const n=e.series;const i=t.length;let r;this._segments=[];for(let e=0;e<i;e++){const i=n[e];const o=this.sortPoints(t[e]);const a=o.length;let s=[];for(let t=0;t<a;t++){const n=o[t];n?s.push(n):this.seriesMissingValues(i)!==Bj&&(s.length>1&&(r=this.createSegment(s,i,e,r),this._addSegment(r)),s=[])}s.length>1&&(r=this.createSegment(s,i,e,r),this._addSegment(r))}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){const t=e.missingValues;return!t&&this.options.isStacked?Lj:t||Bj},getNearestPoint:function(e,t,n){const i=new dU(e,t);const r=this.seriesPoints[n];let o=xV;let a;for(let e=0;e<r.length;e++){const t=r[e];if(t&&void 0!==t.value&&null!==t.value&&!1!==t.visible){const e=t.box.center().distanceTo(i);e<o&&(a=t,o=e)}}return a}};class jG extends kl{setup(){this._setEnd(this.options.box.x1)}step(e){const t=this.options.box;this._setEnd(MN(t.x1,t.x2,e))}_setEnd(e){const t=this.element;const n=t.segments;const i=n[1].anchor();const r=n[2].anchor();t.suspend(),i.setX(e),t.resume(),r.setX(e)}}XN(jG,{duration:Cj}),yl.current.register("clip",jG);const qG={createAnimation:function(){const e=this.getRoot();const t=(e&&e.options||{}).transitions;if(e&&!1!==t){const n=this.parent&&this.parent.clipBox||e.size();const i=Rs.fromRect(n.toRect());const r=t&&!0!==t?t.loading:t;this.visual.clip(i),this.animation=new jG(i,Object.assign({},{box:n},r)),mG(this.options.series)&&this._setChildrenAnimation(i)}},_setChildrenAnimation:function(e){const t=this.animationPoints();for(let n=0;n<t.length;n++){const i=t[n];i&&i.visual&&HN(i.visual.options.zIndex)&&i.visual.clip(e)}}};class GG extends BG{render(){super.render(),this.updateStackRange(),this.renderSegments()}pointType(){return FG}createPoint(e,t){const{series:n,seriesIx:i}=t;const r=this.seriesMissingValues(n);let o=e.valueFields.value;if(null==o){if(r!==Lj)return null;o=0}let a=this.pointOptions(n,i);a=this.evalPointOptions(a,o,t);let s=e.fields.color||n.color;aN(n.color)&&(s=a.color);const l=new FG(o,a);return l.color=s,this.append(l),l}plotRange(e){let t=this.plotValue(e);if(this.options.isStacked){const n=e.categoryIx;const i=this.categoryPoints[n];for(let n=0;n<i.length;n++){const r=i[n];if(e===r)break;t+=this.plotValue(r),this.options.isStacked100&&(t=Math.min(t,1))}}return[t,t]}createSegment(e,t,n){const i=t.style;let r;return r=i===Vj?$G:i===Oj?UG:OG,new r(e,t,n)}animationPoints(){const e=this.points;const t=[];for(let n=0;n<e.length;n++)t.push((e[n]||{}).marker);return t.concat(this._segments)}supportsPointInactiveOpacity(){return!1}}cN(GG.prototype,WG,qG);class KG extends OG{constructor(e,t,n,i,r){super(e,t,n),this.prevSegment=i,this.stackPoints=r}createVisual(){const e=this.series;const t=e._defaults;const n=e.line||{};let i=e.color;aN(i)&&t&&(i=t.color),this.visual=new Us({zIndex:e.zIndex}),this.createFill({fill:CU(e.pattern,{color:i,opacity:e.opacity}),stroke:null}),n.width>0&&!1!==n.visible&&this.createStroke({stroke:cN({color:i,opacity:e.opacity,lineCap:"butt"},n)})}strokeSegments(){let e=this._strokeSegments;return e||(e=this._strokeSegments=this.createStrokeSegments()),e}createStrokeSegments(){return this.segmentsFromPoints(this.points())}stackSegments(){return this.prevSegment?this.prevSegment.createStackSegments(this.stackPoints):this.createStackSegments(this.stackPoints)}createStackSegments(e){return this.segmentsFromPoints(this.toGeometryPoints(e)).reverse()}segmentsFromPoints(e){return e.map((e=>new cs(e)))}createStroke(e){const t=new Rs(e);t.segments.push.apply(t.segments,this.strokeSegments()),this.visual.append(t)}hasStackSegment(){return this.prevSegment||this.stackPoints&&this.stackPoints.length}createFill(e){const t=this.strokeSegments();const n=t.slice(0);const i=this.hasStackSegment();if(i){const e=this.stackSegments();LN(n,e)}const r=new Rs(e);r.segments.push.apply(r.segments,n),!i&&t.length>1&&this.fillToAxes(r),this.visual.append(r)}fillToAxes(e){const t=this.parent;const n=t.options.invertAxes;const i=t.seriesValueAxis(this.series);const r=t.categoryAxisCrossingValue(i);const o=i.getSlot(r,r,!0);const a=this.strokeSegments();const s=a[0].anchor();const l=UN(a).anchor();let 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)}}class YG extends KG{createStrokeSegments(){return this.segmentsFromPoints(this.calculateStepPoints(this.linePoints))}createStackSegments(e){return this.segmentsFromPoints(this.calculateStepPoints(e)).reverse()}}cN(YG.prototype,VG);class QG extends KG{createStrokeSegments(){const e=new cj(this.options.closed);const t=this.points();return e.process(t)}createStackSegments(){const e=this.strokeSegments();const t=[];for(let n=e.length-1;n>=0;n--){const i=e[n];t.push(new cs(i.anchor(),i.controlOut(),i.controlIn()))}return t}}class XG extends GG{createSegment(e,t,n,i){const r=this.options.isStacked;const o=(t.line||{}).style;let a;let s;if(r&&n>0&&i){"gap"!==this.seriesMissingValues(t)?(s=i.linePoints,a=i):s=this._gapStackPoints(e,n,o)}let l;return l=o===Vj?YG:o===Oj?QG:KG,new l(e,t,n,a,s)}reflow(e){super.reflow(e);const t=this._stackPoints;if(t)for(let e=0;e<t.length;e++){const n=t[e];const i=this.categoryAxis.getSlot(n.categoryIx);n.reflow(i)}}_gapStackPoints(e,t,n){const i=this.seriesPoints;let r=e[0].categoryIx;let o=e.length;r<0&&(r=0,o--);const a=r+o;const s=this.seriesOptions[0]._outOfRangeMinPoint?1:0;const l=[];this._stackPoints=this._stackPoints||[];for(let e=r;e<a;e++){const o=e+s;let c=t;let d;do{c--,d=i[c][o]}while(c>0&&!d);if(d)n!==Vj&&e>r&&!i[c][o-1]&&l.push(this._previousSegmentPoint(e,o,o-1,c)),l.push(d),n!==Vj&&e+1<a&&!i[c][o+1]&&l.push(this._previousSegmentPoint(e,o,o+1,c));else{const t=this._createGapStackPoint(e);this._stackPoints.push(t),l.push(t)}}return l}_previousSegmentPoint(e,t,n,i){const r=this.seriesPoints;let o=i;let a;for(;o>0&&!a;)o--,a=r[o][n];return a?a=r[o][t]:(a=this._createGapStackPoint(e),this._stackPoints.push(a)),a}_createGapStackPoint(e){const t=this.pointOptions({},0);const n=new FG(0,t);return n.categoryIx=e,n.series={},n}seriesMissingValues(e){return e.missingValues||Lj}supportsPointInactiveOpacity(){return!1}}class ZG{constructor(){this.axisRanges={}}update(e){const t=this.axisRanges;for(let n in e){const i=e[n];let r=t[n];t[n]=r=r||{min:xV,max:CV},r.min=Math.min(r.min,i.min),r.max=Math.max(r.max,i.max)}}reset(e){this.axisRanges[e]=void 0}query(e){return this.axisRanges[e]}}class JG extends vU{constructor(e,t,n){super(t),this.textBox=new RU(e,this.options,n),this.append(this.textBox)}createVisual(){this.textBox.options.noclip=this.options.noclip}reflow(e){const t=this.options;const{vertical:n,aboveAxis:i}=t;const r=this.children[0];const o=r.options;const a=r.box;const s=r.options.padding;let l=e;if(o.align=n?lV:kV,o.vAlign=n?BV:lV,t.position===rG)n?(o.vAlign=BV,!i&&a.height()<e.height()&&(o.vAlign=sV)):o.align=i?IV:kV;else if(t.position===lV)o.vAlign=lV,o.align=lV;else if(t.position===oG)n?o.vAlign=i?sV:BV:o.align=i?kV:IV;else if(t.position===aG)if(n)if(i){const t=(a.width()-e.width()-s.left-s.right)/2;l=new hU(e.x1-t,e.y1-a.height(),e.x2+t,e.y1)}else l=new hU(e.x1,e.y2,e.x2,e.y2+a.height());else o.align=lV,l=i?new hU(e.x2,e.y1,e.x2+a.width(),e.y2):new hU(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)}alignToClipBox(e){const t=this.options.vertical?UV:$V;const n=t+"1";const i=t+"2";const r=this.children[0];const o=this.parent.box;if(o[n]<e[n]||e[i]<o[i]){const t=r.paddingBox.clone();t[n]=Math.max(o[n],e[n]),t[i]=Math.min(o[i],e[i]),this.reflow(t)}}}XN(JG,{position:aG,margin:mN(3),padding:mN(4),color:aV,background:"",border:{width:1,color:""},aboveAxis:!0,vertical:!1,animation:{type:Sj,delay:Cj},zIndex:2});const eK={addAccessibilityAttributesToVisual:function(){this._id=this._id||T$();const e=Object.assign({},{ariaLabel:this.getAriaLabelText()},this.options.accessibility);TU(this.visual,e)},getAriaLabelText(){const e=this.options.labels;const t=bN(e);return t?t(this.pointData()):this.getLabelText(e)},focusVisual(){this.visual.options.set("id",this._id),this.toggleFocusHighlight(!0)},clearFocusFromVisual(){this.visual.options.set("id",""),this.toggleFocusHighlight(!1)}};class tK extends vU{constructor(e,t){super(),this.options=t,this.color=t.color||VV,this.aboveAxis=YN(this.options.aboveAxis,!0),this.value=e}render(){this._rendered||(this._rendered=!0,this.createLabel(),this.createNote(),this.errorBar&&this.append(this.errorBar))}createLabel(){const e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))}createLabelElement(e){return new JG(this.getLabelText(e),cN({vertical:this.options.vertical},e),this.pointData())}getLabelText(e){let t=_N(e);return t?t(this.pointData()):this.formatValue(e.format)}formatValue(e){return this.owner.formatPointValue(this,e)}reflow(e){this.render();const 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(let t=0;t<this.errorBars.length;t++)this.errorBars[t].reflow(e)}createVisual(){const{box:e,options:t}=this;const n=t.visual;if(!1!==this.visible)if(super.createVisual(),this.addAccessibilityAttributesToVisual(),n){const i=this.rectVisual=n({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:e.toRect(),createVisual:()=>{const e=new Us;return this.createRect(e),e},options:t});i&&this.visual.append(i)}else e.width()>0&&e.height()>0&&this.createRect(this.visual)}createRect(e){const t=this.options;const n=t.border;const i=HN(n.opacity)?n.opacity:t.opacity;const r=this.box.toRect();r.size.width=Math.round(r.size.width);const o=this.rectVisual=Rs.fromRect(r,{fill:CU(t.pattern,{color:this.color,opacity:t.opacity}),stroke:{color:this.getBorderColor(),width:n.width,opacity:i,dashType:n.dashType}});const a=this.box.width();const s=this.box.height();if((t.vertical?a:s)>6&&(ZV(o),(a<1||s<1)&&(o.options.stroke.lineJoin="round")),e.append(o),TG(t)){const n=this.createGradientOverlay(o,{baseColor:this.color},cN({end:t.vertical?void 0:[0,1]},t.overlay));e.append(n)}}createHighlight(e){return ZV(Rs.fromRect(this.box.toRect(),e))}highlightVisual(){return this.rectVisual}highlightVisualArgs(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}}createFocusHighlight(e){const t=this.options.focusHighlight.border.width;return ZV(Rs.fromRect(this.box.pad(t/2).toRect(),e))}getBorderColor(){const e=this.color;const t=this.options.border;const n=t._brightness||Tj;let i=t.color;return HN(i)||(i=new bo(e).brightness(n).toHex()),i}tooltipAnchor(){const{options:e,box:t,aboveAxis:n}=this;const i=this.owner.pane.clipBox()||t;let r=kV;let o=BV;let a,s;if(e.vertical)a=Math.min(t.x2,i.x2)+5,n?s=Math.max(t.y1,i.y1):(s=Math.min(t.y2,i.y2),o=sV);else{const l=Math.max(t.x1,i.x1);const c=Math.min(t.x2,i.x2);e.isStacked?(o=sV,n?(r=IV,a=c):a=l,s=Math.max(t.y1,i.y1)-5):(n?a=c+5:(a=l-5,r=IV),s=Math.max(t.y1,i.y1))}return{point:new dU(a,s),align:{horizontal:r,vertical:o}}}overlapsBox(e){return this.box.overlaps(e)}unclipBox(){const e=this.label&&this.label.textBox;return LG(this.box.clone(),[e,this.note])}labelBox(){const e=this.label&&this.label.textBox;return e?e.box:new hU}noteBox(){return this.note?this.note.box:new hU}pointData(){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}}getIndex(){return this.categoryIx}}function nK(e,t){e.forEach(t)}function iK(e,t){const n=e.length;for(let i=n-1;i>=0;i--)t(e[i],i-n-1)}cN(tK.prototype,HG),cN(tK.prototype,RG),cN(tK.prototype,eK),tK.prototype.defaults={border:{width:1},vertical:!0,overlay:{gradient:"glass"},labels:{visible:!1,format:"{0}"},opacity:1,notes:{label:{}},accessibility:{role:Qq,className:Xq,ariaRoleDescription:Zq}};class rK extends vU{constructor(e){super(e),this.forEach=e.rtl?iK:nK}reflow(e){const{vertical:t,gap:n,spacing:i}=this.options;const r=this.children;const o=r.length;const a=t?UV:$V;const s=o+n+i*(o-1);const l=(t?e.height():e.width())/s;let c=e[a+1]+l*(n/2);this.forEach(r,((t,n)=>{const r=(t.box||e).clone();r[a+1]=c,r[a+2]=c+l,t.reflow(r),n<o-1&&(c+=l*i),c+=l}))}}XN(rK,{vertical:!1,gap:0,spacing:0});class oK extends vU{reflow(e){const t=this.options.vertical?$V:UV;const n=this.children;const i=n.length;let r=this.box=new hU;for(let o=0;o<i;o++){const i=n[o];if(!1!==i.visible){const n=i.box.clone();n.snapTo(e,t),0===o&&(r=this.box=n.clone()),i.reflow(n),r.wrap(n)}}}}XN(oK,{vertical:!0});class aK extends BG{render(){super.render(),this.updateStackRange()}pointType(){return tK}clusterType(){return rK}stackType(){return oK}stackLimits(e,t){return super.stackLimits(e,t)}createPoint(e,t){const{categoryIx:n,series:i,seriesIx:r}=t;const{options:o,children:a}=this;const s=HN(i.stack)?i.stack:o.defaultStack;const l=this.pointValue(e);let c=this.pointOptions(i,r);const d=c.labels;s&&d.position===aG&&(d.position=rG),c.isStacked=s;let h=e.fields.color||i.color;l<0&&c.negativeColor&&(h=c.negativeColor),c=this.evalPointOptions(c,l,t),aN(i.color)&&(h=c.color);const u=new(this.pointType())(l,c);u.color=h;let p=a[n];if(!p){p=new(this.clusterType())({vertical:o.invertAxes,gap:o.gap,spacing:o.spacing,rtl:!o.invertAxes&&(this.chartService||{}).rtl}),this.append(p)}if(o.isStacked){this.getStackWrap(s,p).append(u)}else p.append(u);return u}getStackWrap(e,t){const n=typeof e===DV?e.group||!0:e;const i=t.children;let r;if(typeof n===LV||!0===n)for(let e=0;e<i.length;e++)if(i[e]._stackGroup===n){r=i[e];break}if(!r){r=new(this.stackType())({vertical:!this.options.invertAxes}),r._stackGroup=n,t.append(r)}return r}categorySlot(e,t,n){const i=this.options;const r=e.getSlot(t);const o=n.startValue();if(i.isStacked){const e=n.getSlot(o,o,!0);const t=i.invertAxes?$V:UV;r[t+1]=r[t+2]=e[t+1]}return r}reflowCategories(e){const t=this.children;const n=t.length;for(let i=0;i<n;i++)t[i].reflow(e[i])}createAnimation(){this._setAnimationOptions(),super.createAnimation(),mG(this.options.series)&&this._setChildrenAnimation()}_setChildrenAnimation(){const e=this.points;for(let t=0;t<e.length;t++){const n=e[t];const i=n.visual;i&&HN(i.options.zIndex)&&(n.options.animation=this.options.animation,n.createAnimation())}}_setAnimationOptions(){const e=this.options;const t=e.animation||{};let n;if(e.isStacked){const t=this.seriesValueAxis(e.series[0]);n=t.getSlot(t.startValue())}else n=this.categoryAxis.getSlot(0);t.origin=new ba(n.x1,n.y1),t.vertical=!e.invertAxes}}XN(aK,{animation:{type:$j}});class sK extends vU{constructor(e,t){super(t),this.value=e}getLabelText(e){return this.formatValue(e.format)}reflow(e){const{options:t,value:n,owner:i}=this;const r=i.seriesValueAxis(t);const o=r.getSlot(n.open,n.close);const a=r.getSlot(n.low,n.high);o.x1=a.x1=e.x1,o.x2=a.x2=e.x2,this.realBody=o;const s=a.center().x;const 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()}reflowNote(){this.note&&this.note.reflow(this.box)}createVisual(){super.createVisual(),this.addAccessibilityAttributesToVisual(),this._mainVisual=this.mainVisual(this.options),this.visual.append(this._mainVisual),this.createOverlay()}mainVisual(e){const t=new Us;return this.createBody(t,e),this.createLines(t,e),t}createBody(e,t){const n=Rs.fromRect(this.realBody.toRect(),{fill:CU(t.pattern,{color:this.color,opacity:t.opacity}),stroke:null});t.border.width>0&&n.options.set("stroke",{color:this.getBorderColor(t),width:t.border.width,dashType:t.border.dashType,opacity:YN(t.border.opacity,t.opacity)}),ZV(n),e.append(n),TG(t)&&e.append(this.createGradientOverlay(n,{baseColor:this.color},cN({end:t.vertical?void 0:[0,1]},t.overlay)))}createLines(e,t){this.drawLines(e,t,this.lines,t.line)}drawLines(e,t,n,i){if(!n)return;const r={stroke:{color:i.color||this.color,opacity:YN(i.opacity,t.opacity),width:i.width,dashType:i.dashType,lineCap:"butt"}};for(let t=0;t<n.length;t++){const i=Rs.fromPoints(n[t],r);ZV(i),e.append(i)}}getBorderColor(e){let t=e.border.color;return HN(t)||(t=new bo(this.color).brightness(this.options.border._brightness).toHex()),t}createOverlay(){const e=Rs.fromRect(this.box.toRect(),{fill:{color:VV,opacity:0},stroke:null});this.visual.append(e)}createHighlight(){const e=this.options.highlight;const t=this.color;this.color=e.color||this.color;const n=this.mainVisual(cN({},this.options,{line:{color:this.getBorderColor(e)}},e));return this.color=t,n}highlightVisual(){return this._mainVisual}highlightVisualArgs(){return{options:this.options,rect:this.box.toRect(),visual:this._mainVisual}}tooltipAnchor(){const e=this.box;const t=this.owner.pane.clipBox()||e;return{point:new dU(e.x2+5,Math.max(e.y1,t.y1)+5),align:{horizontal:kV,vertical:BV}}}formatValue(e){return this.owner.formatPointValue(this,e)}overlapsBox(e){return this.box.overlaps(e)}pointData(){return{dataItem:this.dataItem,value:this.value,meanPoints:this.meanPoints,medianPoints:this.medianPoints,whiskerPoints:this.whiskerPoints,stackValue:this.stackValue,series:this.series}}getIndex(){return this.categoryIx}}sK.prototype.createFocusHighlight=tK.prototype.createFocusHighlight,XN(sK,{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:Qq,className:Xq,ariaRoleDescription:Zq}}),cN(sK.prototype,HG),cN(sK.prototype,RG),cN(sK.prototype,eK);class lK extends BG{reflowCategories(e){const t=this.children;const n=t.length;for(let i=0;i<n;i++)t[i].reflow(e[i])}addValue(e,t){const{categoryIx:n,category:i,series:r,seriesIx:o}=t;const{children:a,options:s}=this;const l=e.valueFields;const c=vG(this.splitValue(l));const d=r.data[n];let h=this.categoryPoints[n];let u;h||(this.categoryPoints[n]=h=[]),c&&(u=this.createPoint(e,t));let p=a[n];p||(p=new rK({vertical:s.invertAxes,gap:s.gap,spacing:s.spacing,rtl:!s.invertAxes&&(this.chartService||{}).rtl}),this.append(p)),u&&(this.updateRange(l,t),p.append(u),u.categoryIx=n,u.category=i,u.series=r,u.seriesIx=o,u.owner=this,u.dataItem=d,u.noteText=e.fields.noteText),this.points.push(u),h.push(u)}pointType(){return sK}createPoint(e,t){const{series:n}=t;const i=this.pointType();const r=e.valueFields;let o=cN({},n);let a=e.fields.color||n.color;o=this.evalPointOptions(o,r,t),n.type!==qj&&n.type!==eq||r.open>r.close&&(a=e.fields.downColor||n.downColor||n.color),aN(n.color)&&(a=o.color),o.vertical=!this.options.invertAxes;const s=new i(r,o);return s.color=a,s}splitValue(e){return[e.low,e.open,e.close,e.high]}updateRange(e,t){const n=t.series.axis;const i=this.splitValue(e);let r=this.valueAxisRanges[n]||{min:xV,max:CV};this.valueAxisRanges[n]={min:Math.min.apply(Math,i.concat([r.min])),max:Math.max.apply(Math,i.concat([r.max]))}}formatPointValue(e,t){const n=e.value;return this.chartService.format.auto(t,n.open,n.high,n.low,n.close,e.category)}animationPoints(){return this.points}}cN(lK.prototype,qG);class cK extends sK{constructor(e,t){super(e,t),this.createNote()}reflow(e){const{options:t,value:n,owner:i}=this;const r=i.seriesValueAxis(t);let o,a;this.boxSlot=a=r.getSlot(n.q1,n.q3),this.realBody=a,this.reflowBoxSlot(e),this.whiskerSlot=o=r.getSlot(n.lower,n.upper),this.reflowWhiskerSlot(e);const s=r.getSlot(n.median);if(n.mean){const t=r.getSlot(n.mean);this.meanPoints=this.calcMeanPoints(e,t)}this.whiskerPoints=this.calcWhiskerPoints(a,o),this.medianPoints=this.calcMedianPoints(e,s),this.box=o.clone().wrap(a),this.reflowNote()}reflowBoxSlot(e){this.boxSlot.x1=e.x1,this.boxSlot.x2=e.x2}reflowWhiskerSlot(e){this.whiskerSlot.x1=e.x1,this.whiskerSlot.x2=e.x2}calcMeanPoints(e,t){return[[[e.x1,t.y1],[e.x2,t.y1]]]}calcWhiskerPoints(e,t){const 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]]]}calcMedianPoints(e,t){return[[[e.x1,t.y1],[e.x2,t.y1]]]}renderOutliers(e){const t=this.value;const n=t.outliers||[];const i=3*Math.abs(t.q3-t.q1);const r=[];let o=e.markers||{};for(let a=0;a<n.length;a++){const s=n[a];o=s<t.q3+i&&s>t.q1-i?e.outliers:e.extremes;let l=cN({},o.border);HN(l.color)||(HN(this.color)?l.color=this.color:l.color=new bo(o.background).brightness(Tj).toHex());const c=new MU({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}reflowOutliers(e){const t=this.owner.seriesValueAxis(this.options);const n=this.box.center();for(let i=0;i<e.length;i++){const r=e[i].value;const o=t.getSlot(r);this.options.vertical?o.move(n.x):o.move(void 0,n.y),this.box=this.box.wrap(o),e[i].reflow(o)}}mainVisual(e){const t=super.mainVisual(e);const n=this.renderOutliers(e);for(let e=0;e<n.length;e++){const i=n[e].getElement();i&&t.append(i)}return t}createLines(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)}getBorderColor(){return(this.options.border||{}).color?this.options.border.color:this.color?this.color:super.getBorderColor()}}XN(cK,{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:dV,background:VV,border:{width:2,opacity:1},opacity:0},extremes:{visible:!0,size:8,type:cV,background:VV,border:{width:2,opacity:1},opacity:0}}),cN(cK.prototype,HG);class dK extends cK{reflowBoxSlot(e){this.boxSlot.y1=e.y1,this.boxSlot.y2=e.y2}reflowWhiskerSlot(e){this.whiskerSlot.y1=e.y1,this.whiskerSlot.y2=e.y2}calcMeanPoints(e,t){return[[[t.x1,e.y1],[t.x1,e.y2]]]}calcWhiskerPoints(e,t){const 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]]]}calcMedianPoints(e,t){return[[[t.x1,e.y1],[t.x1,e.y2]]]}}class hK extends lK{addValue(e,t){const{categoryIx:n,category:i,series:r,seriesIx:o}=t;const{children:a,options:s}=this;const l=e.valueFields;const c=vG(this.splitValue(l));const d=r.data[n];let h=this.categoryPoints[n];let u;h||(this.categoryPoints[n]=h=[]),c&&(u=this.createPoint(e,t));let p=a[n];p||(p=new rK({vertical:s.invertAxes,gap:s.gap,spacing:s.spacing,rtl:!s.invertAxes&&(this.chartService||{}).rtl}),this.append(p)),u&&(this.updateRange(l,t),p.append(u),u.categoryIx=n,u.category=i,u.series=r,u.seriesIx=o,u.owner=this,u.dataItem=d),this.points.push(u),h.push(u)}pointType(){return this.options.invertAxes?dK:cK}splitValue(e){return[e.lower,e.q1,e.median,e.q3,e.upper]}updateRange(e,t){const n=t.series.axis;let i=this.splitValue(e).concat(this.filterOutliers(e.outliers));HN(e.mean)&&(i=i.concat(e.mean));let r=this.valueAxisRanges[n]||{min:xV,max:CV};this.valueAxisRanges[n]={min:Math.min.apply(Math,i.concat([r.min])),max:Math.max.apply(Math,i.concat([r.max]))}}formatPointValue(e,t){const n=e.value;return this.chartService.format.auto(t,n.lower,n.q1,n.median,n.q3,n.upper,n.mean,e.category)}filterOutliers(e){const t=(e||[]).length;const n=[];for(let i=0;i<t;i++){const t=e[i];HN(t)&&null!==t&&n.push(t)}return n}supportsPointInactiveOpacity(){return!1}}class uK extends pG{getAxis(){const e=this.chart.seriesAxes(this.series);return this.isVertical?e.y:e.x}}class pK extends vU{constructor(e,t){super(t),this.plotArea=e,this.chartService=e.chartService,this._initFields(),this.render()}_initFields(){this.xAxisRanges={},this.yAxisRanges={},this.points=[],this.seriesPoints=[],this.seriesOptions=[],this._evalSeries=[]}render(){this.traverseDataPoints(this.addValue.bind(this))}addErrorBar(e,t,n){const i=e.value[t];const r=t+"Value";const o=t+"ErrorLow";const a=t+"ErrorHigh";const{seriesIx:s,series:l}=n;const c=e.options.errorBars;const d=n[o];const h=n[a];if(eN(i)){let n;eN(d)&&eN(h)&&(n={low:d,high:h}),c&&HN(c[r])&&(this.seriesErrorRanges=this.seriesErrorRanges||{x:[],y:[]},this.seriesErrorRanges[t][s]=this.seriesErrorRanges[t][s]||new kj(c[r],l,t),n=this.seriesErrorRanges[t][s].getErrorRange(i,c[r])),n&&this.addPointErrorBar(n,e,t)}}addPointErrorBar(e,t,n){const{low:i,high:r}=e;const{series:o,options:{errorBars:a}}=t;const s=n===UV;const l={};t[n+"Low"]=i,t[n+"High"]=r,t.errorBars=t.errorBars||[];const c=new uK(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)}addValue(e,t){const{x:n,y:i}=e;const r=t.seriesIx;const o=this.options.series[r];const a=this.seriesMissingValues(o);const s=this.seriesPoints[r];let l=e;let c;MG(n)&&MG(i)||(l=this.createMissingValue(l,a)),l&&(c=this.createPoint(l,t),c&&(Object.assign(c,t),this.addErrorBar(c,$V,t),this.addErrorBar(c,UV,t)),this.updateRange(l,t.series)),this.points.push(c),s.push(c)}seriesMissingValues(e){return e.missingValues}createMissingValue(){}updateRange(e,t){const n=this.chartService.intl;const{xAxis:i,yAxis:r}=t;let{x:o,y:a}=e;let s=this.xAxisRanges[i];let l=this.yAxisRanges[r];MG(o)&&(s=this.xAxisRanges[i]=s||{min:xV,max:CV},tN(o)&&(o=IW(n,o)),s.min=Math.min(s.min,o),s.max=Math.max(s.max,o)),MG(a)&&(l=this.yAxisRanges[r]=l||{min:xV,max:CV},tN(a)&&(a=IW(n,a)),l.min=Math.min(l.min,a),l.max=Math.max(l.max,a))}evalPointOptions(e,t,n){const{series:i,seriesIx:r}=n;const o={defaults:i._defaults,excluded:["data","tooltip","content","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint","drilldownSeriesFactory","ariaTemplate","ariaContent"]};let a=this._evalSeries[r];HN(a)||(this._evalSeries[r]=a=kG(e,{},o,!0));let s=e;return a&&(s=cN({},e),kG(s,{value:t,series:i,dataItem:n.dataItem},o)),s}pointType(){return FG}pointOptions(e,t){let n=this.seriesOptions[t];if(!n){const i=this.pointType().prototype.defaults;this.seriesOptions[t]=n=cN({},i,{markers:{opacity:e.opacity},tooltip:{format:this.options.tooltip.format},labels:{format:this.options.labels.format}},e)}return n}createPoint(e,t){const n=t.series;let i=this.pointOptions(n,t.seriesIx);let r=t.color||n.color;i=this.evalPointOptions(i,e,t),aN(n.color)&&(r=i.color);const o=new FG(e,i);return o.color=r,this.append(o),o}seriesAxes(e){const{xAxis:t,yAxis:n}=e;const i=this.plotArea;const r=t?i.namedXAxes[t]:i.axisX;const 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}}reflow(e){const t=this.points;const n=!this.options.clip;let i=0;this.traverseDataPoints(((e,r)=>{const o=t[i++];const a=this.seriesAxes(r.series);const s=a.x.getSlot(e.x,e.x,n);const l=a.y.getSlot(e.y,e.y,n);if(o)if(s&&l){const e=this.pointSlot(s,l);o.reflow(e)}else o.visible=!1})),this.box=e}pointSlot(e,t){return new hU(e.x1,t.y1,e.x2,t.y2)}traverseDataPoints(e){const{options:{series:t},seriesPoints:n}=this;for(let i=0;i<t.length;i++){const r=t[i];n[i]||(n[i]=[]);for(let t=0;t<r.data.length;t++){const{valueFields:n,fields:o}=this.plotArea.bindPoint(r,t);e(n,cN({pointIx:t,series:r,seriesIx:i,dataItem:r.data[t],owner:this},o))}}}formatPointValue(e,t){const n=e.value;return this.chartService.format.auto(t,n.x,n.y)}animationPoints(){const e=this.points;const t=[];for(let n=0;n<e.length;n++)t.push((e[n]||{}).marker);return t}}XN(pK,{series:[],tooltip:{format:"{0}, {1}"},labels:{format:"{0}, {1}"},clip:!0}),cN(pK.prototype,qG);class fK extends FG{constructor(e,t){super(e,t),this.category=e.category}createHighlight(){const e=this.options.highlight;const t=e.border;const n=this.options.markers;const i=this.box.center();const r=(n.size+n.border.width+t.width)/2;const o=new Us;const a=new Ra(new Ia([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}]})});const s=new Ra(new Ia([i.x,i.y],r),{stroke:{color:t.color||new bo(n.background).brightness(Tj).toHex(),width:t.width,opacity:t.opacity,dashType:t.dashType},fill:CU(this.options.pattern,{color:n.background,opacity:e.opacity})});return o.append(a,s),o}createFocusHighlight(e){const t=this.options.focusHighlight;const n=this.options.markers;const i=this.box.center();const r=(n.size+n.border.width)/2+t.border.width/2;return new Ra(new Ia([i.x,i.y],r),e)}}fK.prototype.defaults=cN({},fK.prototype.defaults,{labels:{position:lV},highlight:{opacity:1,border:{color:"#fff",width:2,opacity:1}}}),fK.prototype.defaults.highlight.zIndex=void 0;class mK extends pK{_initFields(){this._maxSize=CV,super._initFields()}addValue(e,t){null!==e.size&&(e.size>0||e.size<0&&t.series.negativeValues.visible)?(this._maxSize=Math.max(this._maxSize,Math.abs(e.size)),super.addValue(e,t)):(this.points.push(null),this.seriesPoints[t.seriesIx].push(null))}reflow(e){this.updateBubblesSize(e),super.reflow(e)}pointType(){return fK}createPoint(e,t){const n=t.series;const i=n.data.length;const r=t.pointIx*(Cj/i);const o={delay:r,duration:Cj-r,type:Wj};let a=t.color||n.color;e.size<0&&n.negativeValues.visible&&(a=YN(n.negativeValues.color,a));let s=cN({labels:{animation:{delay:r,duration:Cj-r}}},this.pointOptions(n,t.seriesIx),{markers:{type:cV,border:n.border,opacity:n.opacity,animation:o}});s=this.evalPointOptions(s,e,t),aN(n.color)&&(a=s.color),s.markers.background=a;const l=new fK(e,s);return l.color=a,this.append(l),l}updateBubblesSize(e){const{options:{series:t}}=this;const n=Math.min(e.width(),e.height());for(let e=0;e<t.length;e++){const i=t[e];const r=this.seriesPoints[e];const o=(i.minSize||Math.max(.02*n,10))/2;const a=(i.maxSize||.2*n)/2;const s=Math.PI*o*o;const l=(Math.PI*a*a-s)/this._maxSize;for(let e=0;e<r.length;e++){const t=r[e];if(t){const e=Math.abs(t.value.size)*l;const n=Math.sqrt((s+e)/Math.PI);const i=YN(t.options.zIndex,0)+(1-n/a);cN(t.options,{zIndex:i,markers:{size:2*n,zIndex:i},labels:{zIndex:i+1}})}}}}formatPointValue(e,t){const n=e.value;return this.chartService.format.auto(t,n.x,n.y,n.size,e.category)}createAnimation(){}createVisual(){}}XN(mK,{tooltip:{format:"{3}"},labels:{format:"{3}"}});class gK extends MU{}cN(gK.prototype,HG);class vK extends vU{constructor(e,t){super(t),this.aboveAxis=this.options.aboveAxis,this.color=t.color||VV,this.value=e}render(){const e=this.options;this._rendered||(this._rendered=!0,HN(this.value.target)&&(this.target=new gK({type:e.target.shape,background:e.target.color||this.color,opacity:e.opacity,zIndex:e.zIndex,border:e.target.border,vAlign:BV,align:IV}),this.target.value=this.value,this.target.dataItem=this.dataItem,this.target.series=this.series,this.append(this.target)),this.createLabel(),this.createNote())}createLabel(){const e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))}createLabelElement(e){return new JG(this.getLabelText(e),e,this.pointData())}getLabelText(e){let t=_N(e);return t?t(this.pointData()):this.formatValue(e.format)}reflow(e){this.render();const{options:t,target:n,owner:i}=this;const r=t.invertAxes;const o=i.seriesValueAxis(this.options);const a=i.categorySlot(i.categoryAxis,t.categoryIx,o);const s=o.getSlot(this.value.target);const l=r?s:a;const c=r?a:s;if(n){const e=new hU(l.x1,c.y1,l.x2,c.y2);n.options.height=r?e.height():t.target.line.width,n.options.width=r?t.target.line.width:e.width(),n.reflow(e)}const d=this.label;d&&(d.options.aboveAxis=this.aboveAxis,d.reflow(e)),this.note&&this.note.reflow(e),this.box=e}createVisual(){super.createVisual(),this.addAccessibilityAttributesToVisual();const e=this.options;const t=Rs.fromRect(this.box.toRect(),{fill:CU(e.pattern,{color:this.color,opacity:e.opacity}),stroke:null});e.border.width>0&&t.options.set("stroke",{color:e.border.color||this.color,width:e.border.width,dashType:e.border.dashType,opacity:YN(e.border.opacity,e.opacity)}),this.bodyVisual=t,ZV(t),this.visual.append(t)}createAnimation(){this.bodyVisual&&(this.animation=kl.create(this.bodyVisual,this.options.animation))}createHighlight(e){return Rs.fromRect(this.box.toRect(),e)}highlightVisual(){return this.bodyVisual}highlightVisualArgs(){return{rect:this.box.toRect(),visual:this.bodyVisual,options:this.options}}formatValue(e){return this.owner.formatPointValue(this,e)}pointData(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series}}overlapsBox(e){return this.box.overlaps(e)}getIndex(){return this.categoryIx}}vK.prototype.tooltipAnchor=tK.prototype.tooltipAnchor,vK.prototype.createFocusHighlight=tK.prototype.createFocusHighlight,XN(vK,{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:Qq,className:Xq,ariaRoleDescription:Zq}}),cN(vK.prototype,HG),cN(vK.prototype,RG),cN(vK.prototype,eK);class _K extends BG{constructor(e,t){!function(e){const t=e.series;for(let e=0;e<t.length;e++){const n=t[e];const i=n.data;!i||KV(i[0])||dN(i[0])||(n.data=[i])}}(t),super(e,t)}reflowCategories(e){const t=this.children;const n=t.length;for(let i=0;i<n;i++)t[i].reflow(e[i])}plotRange(e){const t=e.series;const n=this.seriesValueAxis(t);const i=this.categoryAxisCrossingValue(n);return[i,e.value.current||i]}createPoint(e,t){const{categoryIx:n,series:i}=t;const{options:r,children:o}=this;const a=e.valueFields;let s=cN({vertical:!r.invertAxes,overlay:i.overlay,categoryIx:n,invertAxes:r.invertAxes},i);let l=e.fields.color||i.color;s=this.evalPointOptions(s,a,t),aN(i.color)&&(l=s.color);const c=new vK(a,s);c.color=l;let d=o[n];return d||(d=new rK({vertical:r.invertAxes,gap:r.gap,spacing:r.spacing,rtl:!r.invertAxes&&(this.chartService||{}).rtl}),this.append(d)),d.append(c),c}updateRange(e,t){const{current:n,target:i}=e;const r=t.series.axis;let o=this.valueAxisRanges[r];HN(n)&&!isNaN(n)&&HN(i&&!isNaN(i))&&(o=this.valueAxisRanges[r]=o||{min:xV,max:CV},o.min=Math.min(o.min,n,i),o.max=Math.max(o.max,n,i))}formatPointValue(e,t){return this.chartService.format.auto(t,e.value.current,e.value.target)}pointValue(e){return e.valueFields.current}aboveAxis(e){return e.value.current>0}createAnimation(){const e=this.points;this._setAnimationOptions();for(let t=0;t<e.length;t++){const n=e[t];n.options.animation=this.options.animation,n.createAnimation()}}}_K.prototype._setAnimationOptions=aK.prototype._setAnimationOptions,XN(_K,{animation:{type:$j}});class bK{constructor(e,t){this.chartService=e,this.options=cN({},this.options,t)}getStyle(e,t){let{background:n,border:{color:i}}=e;if(t){const e=t.color||t.options.color;n=YN(n,e),i=YN(i,e)}const r=void 0!==e.padding?mN(e.padding):{};return"object"==typeof e.padding&&(r.top=void 0!==e.padding.top?r.top:void 0,r.right=void 0!==e.padding.right?r.right:void 0,r.bottom=void 0!==e.padding.bottom?r.bottom:void 0,r.left=void 0!==e.padding.left?r.left:void 0),{backgroundColor:n,borderColor:i,font:e.font,color:e.color,opacity:e.opacity,borderWidth:hN(e.border.width),paddingTop:hN(r.top),paddingBottom:hN(r.bottom),paddingLeft:hN(r.left),paddingRight:hN(r.right)}}show(e,t,n){if(!this.chartService)return;e.format=t.format;const i=this.getStyle(t,n);e.style=i;const r=new bo(i.backgroundColor);HN(t.color)||r.isDark()||(e.className="k-chart-tooltip-inverse"),this.chartService.notify(Gq,e),this.visible=!0}hide(){this.chartService&&this.chartService.notify(Kq),this.visible=!1}destroy(){delete this.chartService}}XN(bK,{border:{width:1},opacity:1});class wK extends bK{constructor(e,t,n){super(e,n),this.crosshair=t,this.formatService=e.format,this.initAxisName()}initAxisName(){const e=this.crosshair.axis;let t;t=e.plotArea.categoryAxis?e.getCategory?"categoryAxis":"valueAxis":e.options.vertical?"yAxis":"xAxis",this.axisName=t}showAt(e){const{crosshair:{axis:t},options:n}=this;let i=t[n.stickyMode?"getCategory":"getValue"](e);let r=i;n.format?r=this.formatService.auto(n.format,i):t.options.type===hV&&(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)}hide(){this.chartService.notify(Kq,{crosshair:this.crosshair,axisName:this.axisName,axisIndex:this.crosshair.axis.axisIndex})}getAnchor(){const{crosshair:e,options:{position:t,padding:n}}=this;const i=!e.axis.options.vertical;const r=e.line.bbox();let o,a,s;return i?(o=lV,t===sV?(a=BV,s=r.bottomLeft().translate(0,n)):(a=sV,s=r.topLeft().translate(0,-n))):(a=lV,t===kV?(o=IV,s=r.topLeft().translate(-n,0)):(o=kV,s=r.topRight().translate(n,0))),{point:s,align:{horizontal:o,vertical:a}}}}XN(wK,{padding:10});class yK extends vU{constructor(e,t,n){super(n),this.axis=t,this.stickyMode=t instanceof LW;const i=this.options.tooltip;i.visible&&(this.tooltip=new wK(e,this,cN({},i,{stickyMode:this.stickyMode})))}showAt(e){this.point=e,this.moveLine(),this.line.visible(!0),this.tooltip&&this.tooltip.showAt(e)}hide(){this.line.visible(!1),this.tooltip&&this.tooltip.hide()}moveLine(){const{axis:e,point:t}=this;const n=e.options.vertical;const i=this.getBox();const r=n?UV:$V;const o=new ba(i.x1,i.y1);let a;if(a=n?new ba(i.x2,i.y1):new ba(i.x1,i.y2),t)if(this.stickyMode){const n=e.getSlot(e.pointCategoryIndex(t));o[r]=a[r]=n.center()[r]}else o[r]=a[r]=t[r];this.box=i,this.line.moveTo(o).lineTo(a)}getBox(){const e=this.axis;const t=e.pane.axes;const n=t.length;const i=e.options.vertical;const r=e.lineBox().clone();const o=i?$V:UV;let a;for(let e=0;e<n;e++){const n=t[e];n.options.vertical!==i&&(a?a.wrap(n.lineBox()):a=n.lineBox().clone())}return r[o+1]=a[o+1],r[o+2]=a[o+2],r}createVisual(){super.createVisual();const e=this.options;this.line=new Rs({stroke:{color:e.color,width:e.width,opacity:e.opacity,dashType:e.dashType},visible:!1}),this.moveLine(),this.visual.append(this.line)}destroy(){this.tooltip&&this.tooltip.destroy(),super.destroy()}}XN(yK,{color:aV,width:2,zIndex:-1,tooltip:{visible:!1}});class kK extends vU{constructor(e,t){super(e),this.pane=t}shouldClip(){const e=this.children;const t=e.length;for(let n=0;n<t;n++)if(!0===e[n].options.clip)return!0;return!1}_clipBox(){return this.pane.chartsBox()}createVisual(){if(this.visual=new Us({zIndex:0}),this.shouldClip()){const e=(this.clipBox=this._clipBox()).toRect();const t=Rs.fromRect(e);ZV(t),this.visual.clip(t),this.unclipLabels()}}stackRoot(){return this}unclipLabels(){const{children:e,clipBox:t}=this;for(let n=0;n<e.length;n++){const i=e[n].points||[];const r=i.length;for(let e=0;e<r;e++){const n=i[e];if(n&&!1!==n.visible&&n.overlapsBox&&n.overlapsBox(t))if(n.unclipElements)n.unclipElements();else{const{label:e,note:i}=n;e&&e.options.visible&&(e.alignToClipBox&&e.alignToClipBox(t),e.options.noclip=!0),i&&i.options.visible&&(i.options.noclip=!0)}}}}unclipBox(){const{children:e}=this;const t=this._clipBox();const n=t.clone();for(let i=0;i<e.length;i++){const r=e[i].points||[];const o=r.length;for(let e=0;e<o;e++){const i=r[e];if(i&&i.unclipBox&&i.overlapsBox&&!1!==i.visible){if(!i.overlapsBox(t)){i.clipElements&&i.clipElements();continue}const e=i.unclipBox();if(n.overlaps(e)){const t=i.labelBox?i.labelBox():new hU;const r=i.noteBox?i.noteBox():new hU;const o=Math.max(t.height(),r.height());const a=Math.max(t.width(),r.width());n.wrapLimit(e,a,o)}}}}return n}destroy(){super.destroy(),delete this.parent}}kK.prototype.isStackRoot=!0;let xK=class e extends SU{constructor(e){super(e),this.id="pane"+CK++,this.createTitle(),this.content=new vU,this.chartContainer=new kK({},this),this.append(this.content),this.axes=[],this.charts=[]}createTitle(){let t=this.options.title;dN(t)&&(t=cN({},t,{align:t.position,position:BV})),this.title=FU.buildTitle(t,e.prototype.options.title),this.title&&this.append(this.title)}appendAxis(e){this.content.append(e),this.axes.push(e),e.pane=this}appendAxisAt(e,t){this.content.append(e),this.axes.splice(t,0,e),e.pane=this}appendChart(e){this.chartContainer.parent!==this.content&&this.content.append(this.chartContainer),this.charts.push(e),this.chartContainer.append(e),e.pane=this}empty(){const e=this.parent;if(e){for(let t=0;t<this.axes.length;t++)e.removeAxis(this.axes[t]);for(let t=0;t<this.charts.length;t++)e.removeChart(this.charts[t])}this.axes=[],this.charts=[],this.content.destroy(),this.content.children=[],this.chartContainer.children=[]}reflow(e){let t;UN(this.children)===this.content&&(t=this.children.pop()),super.reflow(e),t&&this.children.push(t),this.title&&(this.contentBox.y1+=this.title.box.height())}unclipBox(){return this.chartContainer.unclipBox()}visualStyle(){const e=super.visualStyle();return e.zIndex=-10,e}renderComplete(){this.options.visible&&this.createGridLines()}stackRoot(){return this}clipRoot(){return this}createGridLines(){const e=this.axes;const t=e.concat(this.parent.axes);const n=[];const i=[];for(let r=0;r<e.length;r++){const o=e[r];const a=o.options.vertical;const s=a?n:i;for(let e=0;e<t.length;e++)if(0===s.length){const n=t[e];a!==n.options.vertical&&LN(s,o.createGridLines(n))}}}refresh(){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()}chartsBox(){const e=this.axes;const t=e.length;const n=new hU;for(let i=0;i<t;i++){const t=e[i];const r=t.options.vertical?UV:$V;const o=t.lineBox();n[r+1]=o[r+1],n[r+2]=o[r+2]}if(0===n.x2){const e=this.parent.axes;const t=e.length;for(let i=0;i<t;i++){const t=e[i];if(!t.options.vertical){const e=t.lineBox();n.x1=e.x1,n.x2=e.x2}}}return n}clipBox(){return this.chartContainer.clipBox}notifyRender(){const e=this.getService();e&&e.notify(Yq,{pane:new fj(this),index:this.paneIndex,name:this.options.name})}};let CK=1;xK.prototype.isStackRoot=!0,XN(xK,{zIndex:-1,shrinkToFit:!0,title:{align:kV},visible:!0});const SK=e=>!1!==e.options.visible;class TK extends vU{constructor(e,t,n){super(t),this.initFields(e,t),this.series=e,this.initSeries(),this.charts=[],this.options.legend=this.options.legend||{},this.options.legend.data=[],this.axes=[],this.crosshairs=[],this.chartService=n,this.originalOptions=t,this.originalSeries=e,this._bindCache=new WeakMap,this.createPanes(),this.render(),this.createCrosshairs()}initFields(){}initSeries(){const e=this.series;for(let t=0;t<e.length;t++)e[t].index=t}bindPoint(e,t,n){let i=this._bindCache.get(e);i||(i=[],this._bindCache.set(e,i));let r=i[t];return r||(r=i[t]=bj.current.bindPoint(e,t,n)),r}createPanes(){const e=this.options.title||{};const t=this.options.paneDefaults;const n=this.options.panes||[];const i=Math.max(n.length,1);const r=[];const o=cN({title:{color:e.color}},t);for(let e=0;e<i;e++){const t=cN({},o,n[e]);tN(t.title)&&(t.title=cN({text:t.title},o.title));const i=new xK(t);i.paneIndex=e,r.push(i),this.append(i)}this.panes=r}crosshairOptions(e){return e.options.crosshair}createCrosshairs(e=this.panes){for(let t=0;t<e.length;t++){const n=e[t];for(let e=0;e<n.axes.length;e++){const t=n.axes[e];const i=this.crosshairOptions(t);if(i&&i.visible){const e=new yK(this.chartService,t,i);this.crosshairs.push(e),n.content.append(e)}}}}removeCrosshairs(e){const t=this.crosshairs;const n=e.axes;for(let e=t.length-1;e>=0;e--)for(let i=0;i<n.length;i++)if(t[e].axis===n[i]){t.splice(e,1);break}}hideCrosshairs(){const e=this.crosshairs;for(let t=0;t<e.length;t++)e[t].hide()}findPane(e){const t=this.panes;let n;for(let i=0;i<t.length;i++)if(t[i].options.name===e){n=t[i];break}return n||t[0]}findPointPane(e){const t=this.panes;let n;for(let i=0;i<t.length;i++)if(t[i].box.containsPoint(e)){n=t[i];break}return n}appendAxis(e){this.findPane(e.options.pane).appendAxis(e),this.axes.push(e),e.plotArea=this}removeAxis(e){const t=[];for(let n=0;n<this.axes.length;n++){const i=this.axes[n];e!==i?t.push(i):i.destroy()}this.axes=t}appendChart(e,t){this.charts.push(e),t?t.appendChart(e):this.append(e)}removeChart(e){const t=[];for(let n=0;n<this.charts.length;n++){const i=this.charts[n];i!==e?t.push(i):i.destroy()}this.charts=t}addToLegend(e){const t=e.length;const n=this.options.legend;const i=n.labels||{};const r=n.inactiveItems||{};const o=r.labels||{};const a=[];for(let n=0;n<t;n++){const t=e[n];const s=!1!==t.visible;if(!1===t.visibleInLegend)continue;let l=t.name;const c=s?_N(i):_N(o)||_N(i);c&&(l=c({text:MG(l)?l:"",series:t}));const d=t._defaults;let h=t.color;let u,p;aN(h)&&d&&(h=d.color),s?(u={},p=h):(u={color:o.color,font:o.font},p=r.markers.color),MG(l)&&""!==l&&a.push({text:l,labels:u,markerColor:p,series:t,active:s})}LN(n.data,a)}groupAxes(e){const t=[];const n=[];for(let i=0;i<e.length;i++){const r=e[i].axes;for(let e=0;e<r.length;e++){const i=r[e];i.options.vertical?n.push(i):t.push(i)}}return{x:t,y:n,any:t.concat(n)}}groupSeriesByPane(){const e=this.series;const t={};for(let n=0;n<e.length;n++){const i=e[n];const r=this.seriesPaneName(i);t[r]?t[r].push(i):t[r]=[i]}return t}filterVisibleSeries(e){const t=[];for(let n=0;n<e.length;n++){const i=e[n];!1!==i.visible&&t.push(i)}return t}reflow(e){const t=this.options.plotArea;const n=this.panes;const i=mN(t.margin);this.box=e.clone().unpad(i),this.reflowArea(n),this.ensureLabelsFit(n)&&this.reflowArea(n)}reflowArea(e){this.reflowPanes(),this.detachLabels(),this.reflowAxes(e),this.reflowCharts(e)}ensureLabelsFit(e){let t=!1;return e.forEach((e=>{const n=e.unclipBox();const i=e.chartContainer._clipBox();const r=mN(e.options.padding||{});n.y1<i.y1+r.top&&(t=!0,r.top=i.y1-n.y1+r.top),n.y2>i.y2-r.bottom&&(t=!0,r.bottom=n.y2-i.y2+r.bottom),n.x1<i.x1+r.left&&(t=!0,r.left=i.x1-n.x1+r.left),n.x2>i.x2-r.right&&(t=!0,r.right=n.x2-i.x2+r.right),t&&(e.options.padding=r)})),t}redraw(e){const t=[].concat(e);this.initSeries();const n=this.getRoot();n&&n.cleanGradients();for(let e=0;e<t.length;e++)this.removeCrosshairs(t[e]),t[e].empty();this._bindCache=new WeakMap,this.render(t),this.detachLabels(),this.reflowAxes(this.panes),this.reflowCharts(t),this.createCrosshairs(t);for(let e=0;e<t.length;e++)t[e].refresh()}axisCrossingValues(e,t){const n=e.options;const i=[].concat(n.axisCrossingValues||n.axisCrossingValue);const r=t.length-i.length;const o=i[0]||0;for(let e=0;e<r;e++)i.push(o);return i}alignAxisTo(e,t,n,i){const r=e.getSlot(n,n,!0);const o=e.options.reverse?2:1;const a=t.getSlot(i,i,!0);const s=t.options.reverse?2:1;const l=e.box.translate(a[$V+s]-r[$V+o],a[UV+s]-r[UV+o]);e.pane!==t.pane&&l.translate(0,e.pane.box.y1-t.pane.box.y1),e.reflow(l)}alignAxes(e,t){const n=e[0];const i=t[0];const r=this.axisCrossingValues(n,t);const o=this.axisCrossingValues(i,e);const a={};const s={};const l={};const c={};for(let l=0;l<t.length;l++){const c=t[l];const d=c.pane;const h=d.id;const u=!1!==c.options.visible;const p=DK(e,d)||n;let f=r;if(p!==n&&(f=this.axisCrossingValues(p,t)),this.alignAxisTo(c,p,o[l],f[l]),c.options._overlap)continue;GN(c.lineBox().x1)===GN(p.lineBox().x1)&&(a[h]&&c.reflow(c.box.alignTo(a[h].box,kV).translate(-c.options.margin,0)),u&&(a[h]=c)),GN(c.lineBox().x2)===GN(p.lineBox().x2)&&(c._mirrored||(c.options.labels.mirror=!c.options.labels.mirror,c._mirrored=!0),this.alignAxisTo(c,p,o[l],f[l]),s[h]&&c.reflow(c.box.alignTo(s[h].box,IV).translate(c.options.margin,0)),u&&(s[h]=c));const m=DK(t,d)||i;m!==c&&(c.alignTo(m),c.reflow(c.box))}for(let a=0;a<e.length;a++){const s=e[a];const d=s.pane;const h=d.id;const u=!1!==s.options.visible;const p=DK(t,d)||i;let f=o;p!==i&&(f=this.axisCrossingValues(p,e)),this.alignAxisTo(s,p,r[a],f[a]),s.options._overlap||(GN(s.lineBox().y1)===GN(p.lineBox().y1)&&(s._mirrored||(s.options.labels.mirror=!s.options.labels.mirror,s._mirrored=!0),this.alignAxisTo(s,p,r[a],f[a]),l[h]&&s.reflow(s.box.alignTo(l[h].box,BV).translate(0,-s.options.margin)),u&&(l[h]=s)),GN(s.lineBox().y2,3)===GN(p.lineBox().y2,3)&&(c[h]&&s.reflow(s.box.alignTo(c[h].box,sV).translate(0,s.options.margin)),u&&(c[h]=s)),0!==a&&(s.alignTo(n),s.reflow(s.box)))}}shrinkAxisWidth(e){const t=this.groupAxes(e).any;const n=AK(t);let i=0;for(let t=0;t<e.length;t++){const r=e[t];r.axes.length>0&&(i=Math.max(i,n.width()-r.contentBox.width()))}if(0!==i)for(let e=0;e<t.length;e++){const n=t[e];n.options.vertical||n.reflow(n.box.shrink(i,0))}}shrinkAxisHeight(e){let t;for(let n=0;n<e.length;n++){const i=e[n];const r=i.axes;const o=Math.max(0,AK(r).height()-i.contentBox.height());if(0!==o){for(let e=0;e<r.length;e++){const t=r[e];t.options.vertical&&t.reflow(t.box.shrink(0,o))}t=!0}}return t}fitAxes(e){const t=this.groupAxes(e).any;let n=0;for(let t=0;t<e.length;t++){const i=e[t];const r=i.axes;const o=i.contentBox;if(r.length>0){const e=AK(r);const t=Math.max(o.y1-e.y1,o.y2-e.y2);n=Math.max(n,o.x1-e.x1);for(let e=0;e<r.length;e++){const n=r[e];n.reflow(n.box.translate(0,t))}}}for(let e=0;e<t.length;e++){const i=t[e];i.reflow(i.box.translate(n,0))}}reflowAxes(e){const t=this.groupAxes(e);for(let t=0;t<e.length;t++)this.reflowPaneAxes(e[t]);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))}autoRotateAxisLabels(e){const{panes:t}=this;const n=EK(t);let i;for(let e=0;e<n.length;e++){n[e].autoRotateLabels()&&(i=!0)}if(i){for(let e=0;e<t.length;e++)this.reflowPaneAxes(t[e]);e.x.length>0&&e.y.length>0&&(this.alignAxes(e.x,e.y),this.shrinkAxisWidth(t))}}reflowPaneAxes(e){const t=e.axes;const n=t.length;if(n>0)for(let i=0;i<n;i++)t[i].reflow(e.contentBox)}reflowCharts(e){const t=this.charts;const n=t.length;const i=this.box;for(let r=0;r<n;r++){const n=t[r].pane;n&&!TN(n,e)||t[r].reflow(i)}}reflowPanes(){const{box:e,panes:t}=this;const n=t.length;let i=e.height();let r=0;let o=e.y1;for(let o=0;o<n;o++){const n=t[o];const a=n.options.height;if(n.options.width=e.width(),n.options.height){if(a.indexOf&&a.indexOf("%")){const t=parseInt(a,10)/100;n.options.height=t*e.height()}n.reflow(e.clone()),i-=n.options.height}else r++}for(let e=0;e<n;e++){const n=t[e];n.options.height||(n.options.height=i/r)}for(let i=0;i<n;i++){const n=t[i];const r=e.clone().move(e.x1,o);n.reflow(r),o+=n.options.height}}backgroundBox(){const e=this.axes;const t=e.length;let n;for(let i=0;i<t;i++){const r=e[i];for(let i=0;i<t;i++){const t=e[i];if(r.options.vertical!==t.options.vertical){const e=r.lineBox().clone().wrap(t.lineBox());n=n?n.wrap(e):e}}}return n||this.box}chartsBoxes(){const e=this.panes;const t=[];for(let n=0;n<e.length;n++)t.push(e[n].chartsBox());return t}addBackgroundPaths(e){const t=this.chartsBoxes();for(let n=0;n<t.length;n++)e.paths.push(Rs.fromRect(t[n].toRect()))}backgroundContainsPoint(e){const t=this.chartsBoxes();for(let n=0;n<t.length;n++)if(t[n].containsPoint(e))return!0}createVisual(){super.createVisual();const e=this.options.plotArea;let{opacity:t,background:n,border:i={}}=e;var r;""!==(r=n)&&null!==r&&"none"!==r&&"transparent"!==r&&HN(r)||(n=VV,t=0);const o=this._bgVisual=new Fs({fill:{color:n,opacity:t},stroke:{color:i.width?i.color:"",width:i.width,dashType:i.dashType},zIndex:-1});this.addBackgroundPaths(o),this.appendVisual(o)}pointsByCategoryIndex(e){const t=this.charts;const n=[];if(null!==e)for(let i=0;i<t.length;i++){if("_navigator"===t[i].pane.options.name)continue;const r=t[i].categoryPoints[e];if(r&&r.length)for(let e=0;e<r.length;e++){const t=r[e];t&&HN(t.value)&&null!==t.value&&n.push(t)}}return n}pointsBySeriesIndex(e){return this.filterPoints((function(t){return t.series.index===e}))}pointsByPointIndex(e){return this.filterPoints((function(t){return t.getIndex()===e}))}pointsBySeriesName(e){return this.filterPoints((function(t){return t.series.name===e}))}filterPoints(e){const t=this.charts;const n=[];for(let i=0;i<t.length;i++){const r=t[i].points;for(let t=0;t<r.length;t++){const i=r[t];i&&!1!==i.visible&&e(i)&&n.push(i)}}return n}findPoint(e){const t=this.charts;for(let n=0;n<t.length;n++){const i=t[n].points;for(let t=0;t<i.length;t++){const n=i[t];if(n&&!1!==n.visible&&e(n))return n}}}paneByPoint(e){const t=this.panes;for(let n=0;n<t.length;n++){const i=t[n];if(i.box.containsPoint(e))return i}}detachLabels(){const e=this.groupAxes(this.panes);const t=e.x;const n=e.y;this.detachAxisGroupLabels(n,t),this.detachAxisGroupLabels(t,n)}detachAxisGroupLabels(e,t){let n=0;for(let i=0;i<e.length;i++){const r=e[i];const o=r.pane;const a=DK(t,o)||t[0];const s=i+n;const l=this.createLabelAxis(r,s,a);if(l){n++;const e=o.axes.indexOf(r)+n;o.appendAxisAt(l,e)}}}createLabelAxis(e,t,n){const i=e.options.labels;const r=i.position;const o=r!==mV&&r!==PV;const a=i.visible;if(o||!1===a)return null;const s=this.groupAxes(this.panes);const l=n.options.vertical?s.x:s.y;const c=this.axisCrossingValues(n,l);const d=r===mV;const h=n.range();const u=d?h.max:h.min;if(WN(c[t],h.min,h.max)-u==0)return null;c.splice(t+1,0,u),n.options.axisCrossingValues=c;const 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}isTrendline(e){return e&&TN(e.type,Tq)}trendlineFactory(){}createTrendlineSeries(){const e=[];return this.series=this.series.map((t=>{if(!this.isTrendline(t))return t;const n=this.seriesByName(t.for);if(!n)throw new Error(`Invalid Configuration: Unable to locate linked series "${t.for}" for trendline "${t.name}".`);const i=bj.current.valueFields(n);const r=UN(i);const o=this.trendlineFactory(Object.assign({},{field:r},t),n);return o&&(!1===n.visible&&(o.visible=!1),o.color===yV&&(o.color=n.color),e.push(o)),o})).filter((e=>null!==e)),e}seriesByName(e){return this.series.find((t=>t.name===e))}getFirstPoint(){for(let e=0;e<this.series.length;e++){const t=this.pointsBySeriesIndex(e).find(SK);if(t)return t}}getPointBelow(e){return this._getNextPoint(e,this._pointsByVertical,1)}getPointAbove(e){return this._getNextPoint(e,this._pointsByVertical,-1)}getPointToTheRight(e){return this._getNextPoint(e,this._pointsByHorizontal,1)}getPointToTheLeft(e){return this._getNextPoint(e,this._pointsByHorizontal,-1)}_getNextPoint(e,t,n){let i=t.call(this,e).filter(SK);let r=i.indexOf(e)+n;const o=n=>{let i;let r=0;do{r+=n,i=t.call(this,e,r).filter(SK)}while(0===i.length);return i};return r<0?(i=o(-1),i.at(-1)):r>=i.length?(i=o(1),i.at(0)):i[r]}_pointsByVertical(e){return this.pointsByPointIndex(e.getIndex())}_pointsByHorizontal(e,t=0){let n=oN(e.series.index+t,this.series.length);return this.pointsBySeriesIndex(n)}}function MK(e){return!e.pane.axes.some((t=>t.options.vertical===e.options.vertical&&t!==e&&!1!==t.options.visible))}function AK(e){const t=e.length;let n;for(let i=0;i<t;i++){const t=e[i];const r=!1!==t.options.visible;if(r||MK(t)){const e=r?t.contentBox():t.lineBox();n?n.wrap(e):n=e.clone()}}return n||new hU}function DK(e,t){for(let n=0;n<e.length;n++){const i=e[n];if(i&&i.pane===t)return i}}const EK=e=>e.reduce(((e,t)=>e.concat(t.axes)),[]);XN(TK,{series:[],plotArea:{margin:{}},background:"",border:{color:aV,width:0},paneDefaults:{title:{}},legend:{inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}}});const IK={hover:function(e,t){this._dispatchEvent(e,t,Bq)},click:function(e,t){this._dispatchEvent(e,t,Lq)}};class zK{constructor(e,t,n){const i=t.canonicalFields(e);const r=t.valueFields(e);const o=t.sourceFields(e,i);const a=this._seriesFields=[];const s=n.query(e.type);const l=e.aggregate||s;this._series=e,this._binder=t;for(let e=0;e<i.length;e++){const t=i[e];let n;if(dN(l))n=l[t];else{if(0!==e&&!TN(t,r))break;n=l}n&&a.push({canonicalName:t,name:o[e],transform:aN(n)?n:vj[n]})}}aggregatePoints(e,t){const{_series:n,_seriesFields:i}=this;const r=this._bindPoints(e||[]);const o=r.dataItems[0];let a=null;if(o&&!eN(o)&&!KV(o)){const e=function(){};e.prototype=o,a=new e}for(let e=0;e<i.length;e++){const o=i[e];const s=this._bindField(r.values,o.canonicalName);const l=o.transform(s,n,r.dataItems,t);if(null!==l&&dN(l)&&void 0===l.length&&!(l instanceof Date)){a=l;break}void 0!==l&&(null===a&&(a={}),PK(o.name,a,l))}return a}_bindPoints(e){const{_binder:t,_series:n}=this;const i=[];const r=[];for(let o=0;o<e.length;o++){const a=e[o];i.push(t.bindPoint(n,a)),r.push(n.data[a])}return{values:i,dataItems:r}}_bindField(e,t){const n=[];const i=e.length;for(let r=0;r<i;r++){const i=e[r];const o=i.valueFields;let a;a=void 0!==o[t]?o[t]:i.fields[t],n.push(a)}return n}}function PK(e,t,n){let i=t;let r=e;if(e.indexOf(".")>-1){const t=e.split(".");for(;t.length>1;)r=t.shift(),void 0===i[r]&&(i[r]={}),i=i[r];r=t.shift()}i[r]=n}class LK{constructor(){this._defaults={}}register(e,t){for(let n=0;n<e.length;n++)this._defaults[e[n]]=t}query(e){return this._defaults[e]}}LK.current=new LK;class BK extends tK{createLabel(){const e=this.options.labels;const t=cN({},e,e.from);const n=cN({},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))}reflow(e){this.render();const{labelFrom:t,labelTo:n,value:i}=this;this.box=e,t&&(t.options.aboveAxis=i.from>i.to,t.reflow(e)),n&&(n.options.aboveAxis=i.to>i.from,n.reflow(e)),this.note&&this.note.reflow(e)}}BK.prototype.defaults=cN({},BK.prototype.defaults,{labels:{format:"{0} - {1}"},tooltip:{format:"{1}"}});class HK extends aK{pointType(){return BK}pointValue(e){return e.valueFields}formatPointValue(e,t){return null===e.value.from&&null===e.value.to?"":this.chartService.format.auto(t,e.value.from,e.value.to)}plotRange(e){return e?[e.value.from,e.value.to]:0}updateRange(e,t){const n=t.series.axis;const{from:i,to:r}=e;let o=this.valueAxisRanges[n];null!==e&&eN(i)&&eN(r)&&(o=this.valueAxisRanges[n]=o||{min:xV,max:CV},o.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))}aboveAxis(e){const t=e.value;return t.from<t.to}}HK.prototype.plotLimits=BG.prototype.plotLimits;class RK extends FG{aliasFor(){return this.parent}}const FK="auto";class OK extends vU{constructor(e,t){super(),this.value=e,this.options=t,this.aboveAxis=YN(this.options.aboveAxis,!0),this.tooltipTracking=!0,this._id=T$(),this.initLabelsFormat()}render(){if(this._rendered)return;this._rendered=!0;const{markers:e,labels:t}=this.options;const n=this.value;const i=this.fromPoint=new RK(n,cN({},this.options,{labels:t.from,markers:e.from}));const r=this.toPoint=new RK(n,cN({},this.options,{labels:t.to,markers:e.to}));this.copyFields(i),this.copyFields(r),this.append(i),this.append(r)}reflow(e){this.render();const{from:t,to:n}=e;this.positionLabels(t,n),this.fromPoint.reflow(t),this.toPoint.reflow(n),this.box=this.fromPoint.markerBox().clone().wrap(this.toPoint.markerBox())}createHighlight(){const e=new Us;return e.append(this.fromPoint.createHighlight()),e.append(this.toPoint.createHighlight()),e}highlightVisual(){return this.visual}highlightVisualArgs(){return{options:this.options,from:this.fromPoint.highlightVisualArgs(),to:this.toPoint.highlightVisualArgs()}}createFocusHighlight(){const e=new Us;return e.append(this.fromPoint.createFocusHighlight()),e.append(this.toPoint.createFocusHighlight()),e}tooltipAnchor(){const e=this.owner.pane.clipBox();if(!e||e.overlaps(this.box)){const e=this.box;const t=e.center();const n=kV;let i,r,o;return this.options.vertical?(i=t.x,r=e.y1-5,o=sV):(i=e.x2+5,r=t.y,o=lV),{point:new dU(i,r),align:{horizontal:n,vertical:o}}}}formatValue(e){return this.owner.formatPointValue(this,e)}overlapsBox(e){return this.box.overlaps(e)}unclipElements(){this.fromPoint.unclipElements(),this.toPoint.unclipElements()}initLabelsFormat(){const 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}"})))}positionLabels(e,t){const{labels:n,vertical:i}=this.options;if(n.position===FK){let r,o;i?t.y1<=e.y1?(o=Rj,r=Fj):(o=Fj,r=Rj):t.x1<=e.x1?(o=kV,r=IV):(o=IV,r=kV),n.from&&n.from.position||(this.fromPoint.options.labels.position=r),n.to&&n.to.position||(this.toPoint.options.labels.position=o)}}copyFields(e){e.dataItem=this.dataItem,e.category=this.category,e.series=this.series,e.color=this.color,e.owner=this.owner}focusVisual(){this.fromPoint.focusVisual()}clearFocusFromVisual(){this.toPoint.clearFocusFromVisual()}getIndex(){return this.categoryIx}}cN(OK.prototype,HG),cN(OK.prototype,RG),OK.prototype.defaults={markers:{visible:!1,background:VV,size:8,type:cV,border:{width:2},opacity:1},labels:{visible:!1,margin:mN(3),padding:mN(4),animation:{type:Sj,delay:Cj},position:FK},notes:{label:{}},highlight:{markers:{border:{color:VV,width:2}},zIndex:100},tooltip:{format:"{0} - {1}"},accessibility:{role:Qq,className:Xq,ariaRoleDescription:Zq}};class VK extends KG{createStrokeSegments(){return this.segmentsFromPoints(this.toGeometryPoints(this.toPoints()))}stackSegments(){let e=this.fromSegments;return this.fromSegments||(e=this.fromSegments=this.segmentsFromPoints(this.toGeometryPoints(this.fromPoints().reverse()))),e}createStroke(e){const t=new Rs(e);const n=new Rs(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)}hasStackSegment(){return!0}fromPoints(){return this.linePoints.map((e=>e.fromPoint))}toPoints(){return this.linePoints.map((e=>e.toPoint))}}class NK extends VK{createStrokeSegments(){return this.createCurveSegments(this.toPoints())}stackSegments(){let e=this.fromSegments;return this.fromSegments||(e=this.fromSegments=this.createCurveSegments(this.fromPoints().reverse())),e}createCurveSegments(e){return(new cj).process(this.toGeometryPoints(e))}}class $K extends VK{createStrokeSegments(){return this.segmentsFromPoints(this.calculateStepPoints(this.toPoints()))}stackSegments(){let e=this.fromSegments;return this.fromSegments||(e=this.fromSegments=this.segmentsFromPoints(this.calculateStepPoints(this.fromPoints())),e.reverse()),e}}cN($K.prototype,VG);class UK extends BG{render(){super.render(),this.renderSegments()}pointType(){return OK}createPoint(e,t){const{series:n,seriesIx:i}=t;let r=e.valueFields;if(!MG(r.from)&&!MG(r.to)){if(this.seriesMissingValues(n)!==Lj)return null;r={from:0,to:0}}let o=this.pointOptions(n,i);o=this.evalPointOptions(o,r,t);let a=e.fields.color||n.color;aN(n.color)&&(a=o.color);const s=new OK(r,o);return s.color=a,this.append(s),s}createSegment(e,t,n){const i=(t.line||{}).style;let r;return r="smooth"===i?NK:"step"===i?$K:VK,new r(e,t,n)}plotRange(e,t){return e?[e.value.from,e.value.to]:[t,t]}valueSlot(e,t){const n=e.getSlot(t[0],t[0],!this.options.clip);const i=e.getSlot(t[1],t[1],!this.options.clip);if(n&&i)return{from:n,to:i}}pointSlot(e,t){const{from:n,to:i}=t;let r,o;return this.options.invertAxes?(r=new hU(n.x1,e.y1,n.x2,e.y2),o=new hU(i.x1,e.y1,i.x2,e.y2)):(r=new hU(e.x1,n.y1,e.x2,n.y2),o=new hU(e.x1,i.y1,e.x2,i.y2)),{from:r,to:o}}addValue(e,t){const n=e.valueFields;eN(n.from)||(n.from=n.to),eN(n.to)||(n.to=n.from),super.addValue(e,t)}updateRange(e,t){if(null!==e&&eN(e.from)&&eN(e.to)){const n=t.series.axis;const i=this.valueAxisRanges[n]=this.valueAxisRanges[n]||{min:xV,max:CV};const{from:r,to:o}=e;i.min=Math.min(i.min,r,o),i.max=Math.max(i.max,r,o)}}formatPointValue(e,t){const n=e.value;return this.chartService.format.auto(t,n.from,n.to)}animationPoints(){const e=this.points;const t=[];for(let n=0;n<e.length;n++){const i=e[n];i&&(t.push((i.fromPoint||{}).marker),t.push((i.toPoint||{}).marker))}return t.concat(this._segments)}}cN(UK.prototype,WG,qG);class WK extends sK{reflow(e){const{options:t,value:n,owner:i}=this;const r=i.seriesValueAxis(t);const o=[];const a=[];const s=[];const l=r.getSlot(n.low,n.high);const c=r.getSlot(n.open,n.open);const d=r.getSlot(n.close,n.close);c.x1=d.x1=l.x1=e.x1,c.x2=d.x2=l.x2=e.x2;const h=l.center().x;o.push([c.x1,c.y1]),o.push([h,c.y1]),a.push([h,d.y1]),a.push([d.x2,d.y1]),s.push([h,l.y1]),s.push([h,l.y2]),this.lines=[o,a,s],this.box=l.clone().wrap(c.clone().wrap(d)),this.reflowNote()}createBody(){}}class jK extends lK{pointType(){return WK}}class qK extends vU{constructor(e,t,n){super(),this.from=e,this.to=t,this.series=n}linePoints(){const e=this.from;const{from:{box:t},to:{box:n}}=this;const i=[];if(e.isVertical){const r=e.aboveAxis?t.y1:t.y2;i.push([t.x1,r],[n.x2,r])}else{const r=e.aboveAxis?t.x2:t.x1;i.push([r,t.y1],[r,n.y2])}return i}createVisual(){super.createVisual();const e=this.series.line||{};const t=Rs.fromPoints(this.linePoints(),{stroke:{color:e.color,width:e.width,opacity:e.opacity,dashType:e.dashType}});ZV(t),this.visual.append(t)}}XN(qK,{animation:{type:Sj,delay:Cj}});class GK extends aK{render(){super.render(),this.createSegments()}traverseDataPoints(e){const t=this.options.series;const n=wG(t);const i=!this.options.invertAxes;for(let r=0;r<t.length;r++){const o=t[r];let a=0;let s=0;for(let t=0;t<n;t++){const n=bj.current.bindPoint(o,t);const l=n.valueFields.value;const c=n.fields.summary;let d=a;let h;c?"total"===c.toLowerCase()?(n.valueFields.value=a,d=0,h=a):(n.valueFields.value=s,h=d-s,s=0):eN(l)&&(s+=l,a+=l,h=a),e(n,{category:this.categoryAxis.categoryAt(t),categoryIx:t,series:o,seriesIx:r,total:a,runningTotal:s,from:d,to:h,isVertical:i})}}}updateRange(e,t){super.updateRange({value:t.to},t)}aboveAxis(e){return e.value>=0}plotRange(e){return[e.from,e.to]}createSegments(){const e=this.options.series;const t=this.seriesPoints;const n=this.segments=[];for(let i=0;i<e.length;i++){const r=e[i];const o=t[i];if(o){let e;for(let t=0;t<o.length;t++){const i=o[t];if(i&&e){const t=new qK(e,i,r);n.push(t),this.append(t)}e=i}}}}}function KK(e,t,n){const i=e[String(t)];return i?i(n):null}function YK(e,t){let n=0;let i=0;let r=0;let o=0;let a=0;let s,l;let c=Number.MAX_VALUE;let d=Number.MIN_VALUE;for(let s=0;s<e.length;s++){const l=e[s];const{xValue:h,yValue:u}=t(l);isFinite(h)&&null!==h&&isFinite(u)&&null!==u&&(c=Math.min(h,c),d=Math.max(h,d),a++,n+=h,i+=u,r+=Math.pow(h,2),o+=h*u)}return a>0&&(s=(a*o-n*i)/(a*r-Math.pow(n,2)),l=(i-s*n)/a),{slope:s,intercept:l,count:a,xMin:c,xMax:d}}const QK=(e,t)=>e.every((({valueFields:e})=>!MG(e[t])||e[t]>0));function XK(e,t){const n=[];const i=t.totalRangeIndices();const r=t.currentRangeIndices();const o={min:Math.floor(Math.max(r.min-1,i.min)),max:Math.ceil(Math.min(r.max+2,i.max))};for(let i=o.min;i<o.max;i++){const r=i+1;n[i]={category:t.categoryAt(i,!0),value:e(r)}}return n}const ZK=e=>({categoryIx:t,valueFields:n})=>({xValue:t+1,yValue:Math.log(n[e])});const JK=e=>({categoryIx:t,valueFields:n})=>({xValue:t+1,yValue:n[e]});const eY=e=>({categoryIx:t,valueFields:n})=>({xValue:Math.log(t+1),yValue:n[e]});function tY(e,t,n){const i=[];const r=[];const o=Math.max(2,n)-1;let a=0;let s=0;for(let n=0;n<e.length;n++){const l=e[n];const{xValue:c,yValue:d}=t(l);if(isFinite(d)&&null!==d?(r.push(d),s+=d,a=Math.max(n,a)):r.push(null),n>=o){const e=r.filter((e=>null!==e)).length;const t=r.shift()||0;if(e>0){const n=s/e;i.push([c,n]),s-=t;continue}}i.push([c,null])}return i.slice(0,a+1)}const nY=e=>({categoryIx:t,valueFields:n})=>({xValue:t,yValue:n[e]});function iY(e,t,n){let i=Math.min(Math.max(n||1,1),6)+1;let r=new b$;let o=new b$;let a=0;let s=Number.MAX_VALUE;let l=Number.MIN_VALUE;let c=e=>e;let d=[];for(let n=0;n<e.length;n++){const c=e[n];let{xValue:d,yValue:h}=t(c);if(isFinite(d)&&null!==d&&isFinite(h)&&null!==h){s=Math.min(d,s),l=Math.max(d,l),a++,o.set(n,0,h),r.set(n,0,1),r.set(n,1,d);for(let e=2;e<=i;e++)r.set(n,e,Math.pow(r.get(n,1),e))}else r.set(n,0,0)}return r.width=Math.min(i,a),a>0&&(d=function(e,t){const n=e.transpose();const i=n.multiply(e).inverse().multiply(n).multiply(t);const r=[];for(let e=0;e<i.height;e++)r.push(i.get(e,0));return r}(r,o),c=e=>d.reduce(((t,n,i)=>t+n*Math.pow(e,i)),0)),{coefficients:d,count:a,valueMapper:c,xMin:s,xMax:l}}const rY=e=>({categoryIx:t,valueFields:n})=>({xValue:t+1,yValue:n[e]});const oY=e=>({categoryIx:t,valueFields:n})=>({xValue:Math.log(t+1),yValue:Math.log(n[e])});const aY={};aY[wq]=function(e){const{options:t,categoryAxis:n,seriesValues:i}=e;const r=function({seriesValues:e,categoryAxis:t,options:n}){const i=e();if(!QK(i,n.field))return null;let{slope:r,intercept:o,count:a}=YK(i,ZK(n.field));if(a>0){const e=Math.exp(o);const n=r;return XK((t=>e*Math.exp(n*t)),t)}return null}({seriesValues:i,categoryAxis:n,options:t});return r?Object.assign({},t,{type:"line",data:r,categoryField:"category",field:"value"}):null},aY[yq]=function(e){const{options:t,categoryAxis:n,seriesValues:i}=e;const r=function({seriesValues:e,categoryAxis:t,options:n}){const{slope:i,intercept:r,count:o}=YK(e(),JK(n.field));if(o>0)return XK((e=>i*e+r),t);return null}({seriesValues:i,categoryAxis:n,options:t});return r?Object.assign({},t,{type:"line",data:r,categoryField:"category",field:"value"}):null},aY[kq]=function(e){const{options:t,categoryAxis:n,seriesValues:i}=e;const r=function({seriesValues:e,categoryAxis:t,options:n}){let{slope:i,intercept:r,count:o}=YK(e(),eY(n.field));if(o>0){const e=i;const n=r;return XK((t=>e*Math.log(t)+n),t)}return null}({seriesValues:i,categoryAxis:n,options:t});return r?Object.assign({},t,{type:"line",data:r,categoryField:"category",field:"value"}):null},aY[xq]=function(e){const{options:t}=e;const n=function(e){const{categoryAxis:t}=e;const n=function({options:e,categoryAxis:t,seriesValues:n}){const i=(e.trendline||{}).period||2;const r=t.totalRangeIndices();const o=t.currentRangeIndices();const a={min:Math.floor(Math.max(o.min-i,r.min)),max:Math.ceil(Math.min(o.max+i+2,r.max))};return tY(n(a),nY(e.field),i)}(e);const i=[];if(n.forEach((([e,n])=>{i[e]={category:t.categoryAt(e,!0),value:n}})),i.length>0)return i;return null}(e);return n?Object.assign({},t,{type:"line",data:n,categoryField:"category",field:"value"}):null},aY[Cq]=function(e){const{options:t,categoryAxis:n,seriesValues:i}=e;const r=function({seriesValues:e,categoryAxis:t,options:n}){const i=(n.trendline||{}).order;const{count:r,valueMapper:o}=iY(e(),rY(n.field),i);if(r>0)return XK((e=>o(e)),t);return null}({seriesValues:i,categoryAxis:n,options:t});return r?Object.assign({},t,{type:"line",data:r,categoryField:"category",field:"value"}):null},aY[Sq]=function(e){const{options:t,categoryAxis:n,seriesValues:i}=e;const r=function({seriesValues:e,categoryAxis:t,options:n}){const i=e();if(!QK(i,n.field))return null;let{slope:r,intercept:o,count:a}=YK(i,oY(n.field));if(a>0){const e=Math.exp(o);const n=r;return XK((t=>e*Math.pow(t,n)),t)}return null}({seriesValues:i,categoryAxis:n,options:t});return r?Object.assign({},t,{type:"line",data:r,categoryField:"category",field:"value"}):null};const sY=[Nj,pq,lq,vq];const lY=[Jj,gq].concat(sY);class cY extends TK{initFields(e){if(this.namedCategoryAxes={},this.namedValueAxes={},this.valueAxisRangeTracker=new ZG,this._seriesPointsCache={},this._currentPointsCache={},e.length>0){this.invertAxes=TN(e[0].type,[$j,jj,gq,pq,vq,cq,Zj,fq]);for(let t=0;t<e.length;t++){const n=e[t].stack;if(n&&"100%"===n.type){this.stack100=!0;break}}}}render(e=this.panes){this.series=[...this.originalSeries],this.createCategoryAxes(e),this.aggregateCategories(e),this.createTrendlineSeries(e),this.createCategoryAxesLabels(e),this.createCharts(e),this.createValueAxes(e)}removeAxis(e){const t=e.options.name;super.removeAxis(e),e instanceof LW?delete this.namedCategoryAxes[t]:(this.valueAxisRangeTracker.reset(t),delete this.namedValueAxes[t]),e===this.categoryAxis&&delete this.categoryAxis,e===this.valueAxis&&delete this.valueAxis}trendlineFactory(e,t){const n=this.seriesCategoryAxis(e);const i=this.seriesValues.bind(this,t.index);const r=KK(aY,e.type,{options:e,categoryAxis:n,seriesValues:i});return r?(r.categoryAxis=t.categoryAxis,r.valueAxis=t.valueAxis,this.filterSeries(r,n)):r}trendlineAggregateForecast(){return this.series.map((e=>(e.trendline||{}).forecast)).filter((e=>void 0!==e)).reduce(((e,t)=>({before:Math.max(e.before,t.before||0),after:Math.max(e.after,t.after||0)})),{before:0,after:0})}seriesValues(e,t){const n=[];let i=this.srcSeries[e];const r=this.seriesCategoryAxis(i);yG(r.options.type,hV)&&(this._seriesPointsCache={},this._currentPointsCache={},r.options.dataItems=[],i=this.aggregateSeries(i,r,r.totalRangeIndices()));const o=t?t.min:0;const a=t?t.max:i.data.length;for(let e=o;e<a;e++){const t=this.bindPoint(i,e);n.push({categoryIx:e,category:t.fields.category,valueFields:t.valueFields})}return n}createCharts(e){const t=this.groupSeriesByPane();for(let n=0;n<e.length;n++){const i=e[n];const r=t[i.options.name||"default"]||[];this.addToLegend(r);const o=this.filterVisibleSeries(r);if(!o)continue;const a=this.groupSeriesByCategoryAxis(o);for(let e=0;e<a.length;e++)this.createChartGroup(a[e],i)}}createChartGroup(e,t){this.createAreaChart(xG(e,[Nj,pq]),t),this.createRangeAreaChart(xG(e,[lq,vq]),t),this.createBarChart(xG(e,[Gj,$j]),t),this.createRangeBarChart(xG(e,[dq,cq]),t),this.createBulletChart(xG(e,[jj,mq]),t),this.createCandlestickChart(xG(e,qj),t),this.createBoxPlotChart(xG(e,[Uj,fq]),t),this.createOHLCChart(xG(e,eq),t),this.createWaterfallChart(xG(e,[_q,Zj]),t),this.createLineChart(xG(e,[Jj,gq]),t)}aggregateCategories(e){const t=[...this.series];const n=[];this._currentPointsCache={},this._seriesPointsCache=this._seriesPointsCache||{};for(let i=0;i<t.length;i++){let r=t[i];if(!this.isTrendline(r)){const t=this.seriesCategoryAxis(r);const n=this.findPane(t.options.pane);r=(yG(t.options.type,hV)||r.categoryField)&&TN(n,e)?this.aggregateSeries(r,t,t.currentRangeIndices()):this.filterSeries(r,t)}n.push(r)}this._seriesPointsCache=this._currentPointsCache,this._currentPointsCache=null,this.srcSeries=t,this.series=n}filterSeries(e,t){const n=(e.data||{}).length;if(t._seriesMax=Math.max(t._seriesMax||0,n),!HN(t.options.min)&&!HN(t.options.max))return e;const i=t.currentRangeIndices();const r=TN(e.type,lY);const o=cN({},e);return o.data=(o.data||[]).slice(i.min,i.max+1),r&&PG(o,i,n,(n=>({item:e.data[n],category:t.categoryAt(n,!0),categoryIx:n-i.min})),(t=>HN(e.data[t]))),o}clearSeriesPointsCache(){this._seriesPointsCache={}}seriesSourcePoints(e,t){const n=`${e.index};${t.categoriesHash()}`;if(this._seriesPointsCache&&this._seriesPointsCache[n])return this._currentPointsCache[n]=this._seriesPointsCache[n],this._seriesPointsCache[n];const i=t.options;const r=i.srcCategories;const o=yG(i.type,hV);const a=e.data;const s=[];o||t.indexCategories();for(let n=0;n<a.length;n++){let i=bj.current.bindPoint(e,n).fields.category;if(o&&(i=SG(i,a[n],this.chartService.intl)),void 0===i&&(i=r[n]),null!=i){const e=t.totalIndex(i);s[e]=s[e]||{items:[],category:i},s[e].items.push(n)}}return this._currentPointsCache[n]=s,s}aggregateSeries(e,t,n){if(!e.data.length)return e;const i=this.seriesSourcePoints(e,t);const r=cN({},e);const o=new zK(cN({},e),bj.current,LK.current);const a=r.data=[];const s=t.options.dataItems||[];const l=e=>{const r=e-n.min;let a=i[e];if(a||(a=i[e]={}),a.categoryIx=r,!a.item){const n=t.categoryAt(e,!0);a.category=n,a.item=o.aggregatePoints(a.items,n)}return a};for(let e=n.min;e<=n.max;e++){const t=l(e);a[t.categoryIx]=t.item,t.items&&t.items.length&&(s[t.categoryIx]=t.item)}return TN(r.type,lY)&&PG(r,n,t.totalCount(),l,(e=>i[e])),t.options.dataItems=s,r}appendChart(e,t){const n=e.options.series;const i=this.seriesCategoryAxis(n[0]);let r=i.options.categories;let o=Math.max(0,wG(n)-r.length);if(o>0)for(r=i.options.categories=i.options.categories.slice(0);o--;)r.push("");this.valueAxisRangeTracker.update(e.valueAxisRanges),super.appendChart(e,t)}seriesPaneName(e){const t=this.options;const n=e.axis;const i=[].concat(t.valueAxis);const r=xN(i,(function(e){return e.name===n}))[0];const o=((t.panes||[{}])[0]||{}).name||"default";return(r||{}).pane||o}seriesCategoryAxis(e){const t=e.categoryAxis;const n=t?this.namedCategoryAxes[t]:this.categoryAxis;if(!n)throw new Error("Unable to locate category axis with name "+t);return n}stackableChartOptions(e,t){const n=e.some((e=>e.stack));const i=e.some((e=>e.stack&&"100%"===e.stack.type));const r=t.options.clip;return{defaultStack:e[0].stack,isStacked:n,isStacked100:i,clip:r}}groupSeriesByCategoryAxis(e){const t=[];const n={};for(let i=0;i<e.length;i++){const r=e[i].categoryAxis||"$$default$$";_$(n,r)||(n[r]=!0,t.push(r))}const i=[];for(let n=0;n<t.length;n++){const r=hY(e,t[n],n);0!==r.length&&i.push(r)}return i}createBarChart(e,t){if(0===e.length)return;const n=e[0];const i=new aK(this,Object.assign({series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing},this.stackableChartOptions(e,t)));this.appendChart(i,t)}createRangeBarChart(e,t){if(0===e.length)return;const n=e[0];const i=new HK(this,{series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing});this.appendChart(i,t)}createBulletChart(e,t){if(0===e.length)return;const n=e[0];const i=new _K(this,{series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}createLineChart(e,t){if(0===e.length)return;const n=new GG(this,Object.assign({invertAxes:this.invertAxes,series:e},this.stackableChartOptions(e,t)));this.appendChart(n,t)}createAreaChart(e,t){if(0===e.length)return;const n=new XG(this,Object.assign({invertAxes:this.invertAxes,series:e},this.stackableChartOptions(e,t)));this.appendChart(n,t)}createRangeAreaChart(e,t){if(0===e.length)return;const n=new UK(this,{invertAxes:this.invertAxes,series:e,clip:t.options.clip});this.appendChart(n,t)}createOHLCChart(e,t){if(0===e.length)return;const n=e[0];const i=new jK(this,{invertAxes:this.invertAxes,gap:n.gap,series:e,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}createCandlestickChart(e,t){if(0===e.length)return;const n=e[0];const i=new lK(this,{invertAxes:this.invertAxes,gap:n.gap,series:e,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}createBoxPlotChart(e,t){if(0===e.length)return;const n=e[0];const i=new hK(this,{invertAxes:this.invertAxes,gap:n.gap,series:e,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}createWaterfallChart(e,t){if(0===e.length)return;const n=e[0];const i=new GK(this,{series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing});this.appendChart(i,t)}axisRequiresRounding(e,t){const n=xG(this.series,bq);for(let e=0;e<this.series.length;e++){const t=this.series[e];if(TN(t.type,sY)){const e=t.line;e&&e.style===Vj&&n.push(t)}}for(let i=0;i<n.length;i++){const r=n[i].categoryAxis||"";if(r===e||!r&&0===t)return!0}}aggregatedAxis(e,t){const n=this.series;for(let i=0;i<n.length;i++){const r=n[i].categoryAxis||"";if((r===e||!r&&0===t)&&n[i].categoryField)return!0}}createCategoryAxesLabels(){const e=this.axes;for(let t=0;t<e.length;t++)e[t]instanceof LW&&e[t].createLabels()}createCategoryAxes(e){const t=this.invertAxes;const n=[].concat(this.options.categoryAxis);const i=[];for(let r=0;r<n.length;r++){let o=n[r];if(TN(this.findPane(o.pane),e)){const{name:e,categories:a=[]}=o;let s;if(o=cN({vertical:t,reverse:!t&&this.chartService.rtl,axisCrossingValue:t?xV:0},o),HN(o.justified)||(o.justified=this.isJustified()),this.axisRequiresRounding(e,r)&&(o.justified=!1),AG(o,a[0])?(o._forecast=this.trendlineAggregateForecast(),s=new WW(o,this.chartService)):s=new LW(o,this.chartService),n[r].categories=s.options.srcCategories,e){if(this.namedCategoryAxes[e])throw new Error(`Category axis with name ${e} is already defined`);this.namedCategoryAxes[e]=s}s.axisIndex=r,i.push(s),this.appendAxis(s)}}const r=this.categoryAxis||i[0];this.categoryAxis=r,t?this.axisY=r:this.axisX=r}isJustified(){const e=this.series;for(let t=0;t<e.length;t++){if(!TN(e[t].type,sY))return!1}return!0}createValueAxes(e){const t=this.valueAxisRangeTracker;const n=t.query();const i=[].concat(this.options.valueAxis);const r=this.invertAxes;const o={vertical:!r,reverse:r&&this.chartService.rtl};const a=[];this.stack100&&(o.roundToMajorUnit=!1,o.labels={format:"P0"});for(let r=0;r<i.length;r++){const s=i[r];if(TN(this.findPane(s.pane),e)){const e=s.name;const i=yG(s.type,nG)?{min:.1,max:1}:{min:0,max:1};const l=t.query(e)||n||i;let c;0===r&&l&&n&&(l.min=Math.min(l.min,n.min),l.max=Math.max(l.max,n.max)),c=yG(s.type,nG)?JW:YW;const d=new c(l.min,l.max,cN({},o,s),this.chartService);if(e){if(this.namedValueAxes[e])throw new Error(`Value axis with name ${e} is already defined`);this.namedValueAxes[e]=d}d.axisIndex=r,a.push(d),this.appendAxis(d)}}const s=this.valueAxis||a[0];this.valueAxis=s,r?this.axisX=s:this.axisY=s}_dispatchEvent(e,t,n){const i=e._eventCoordinates(t);const r=new dU(i.x,i.y);const o=this.pointPane(r);const a=[];const s=[];if(!o)return;const l=o.axes;for(let e=0;e<l.length;e++){const t=l[e];t.getValue?gG(s,t.getValue(r)):gG(a,t.getCategory(r))}0===a.length&&gG(a,this.categoryAxis.getCategory(r)),a.length>0&&s.length>0&&e.trigger(n,{element:NN(t),originalEvent:t,category:DG(a),value:DG(s)})}pointPane(e){const t=this.panes;for(let n=0;n<t.length;n++){const i=t[n];if(i.contentBox.containsPoint(e))return i}}updateAxisOptions(e,t){dY(this.options,e,t),dY(this.originalOptions,e,t)}_pointsByVertical(e,t=0){return this.invertAxes?this._siblingsBySeriesIndex(e.series.index,t):this._siblingsByPointIndex(e.getIndex())}_pointsByHorizontal(e,t=0){if(this.invertAxes)return this._siblingsByPointIndex(e.getIndex());const n=this._siblingsBySeriesIndex(e.series.index,t);return this.chartService.rtl?n.reverse():n}_siblingsByPointIndex(e){const t=this.charts;const n=[];for(let i=0;i<t.length;i++){let r=t[i];if(r.pane&&"_navigator"===r.pane.options.name)continue;let o=r.points.filter((t=>t&&!1!==t.visible&&t.getIndex()===e));n.push(...o.sort(this._getSeriesCompareFn(o[0])))}return n}_siblingsBySeriesIndex(e,t){const n=oN(e+t,this.series.length);return this.pointsBySeriesIndex(n)}_getSeriesCompareFn(e){const t=this._isInStackedSeries(e);return t&&this.invertAxes||!t&&!this.invertAxes?(e,t)=>e.box.center().x-t.box.center().x:(e,t)=>e.box.center().y-t.box.center().y}_isInStackedSeries(e){const t=TN(e.series.type,[Nj,pq,lq,vq,Jj,gq,sq,oq]);const n=TN(e.series.type,[Gj,$j]);return t||n&&e.options.isStacked}}function dY(e,t,n){cN([].concat(t instanceof LW?e.categoryAxis:e.valueAxis)[t.axisIndex],n)}function hY(e,t,n){return xN(e,(function(e){return 0===n&&!e.categoryAxis||e.categoryAxis===t}))}XN(cY,{categoryAxis:{},valueAxis:{}}),cN(cY.prototype,IK);class uY{constructor(){this._points=[]}destroy(){this._points=[]}show(e,t){const n=[].concat(e);this.hide();for(let e=0;e<n.length;e++){const i=n[e];i&&i.toggleHighlight&&i.hasHighlight()&&(this.togglePointHighlight(i,!0,t),this._points.push(i))}}togglePointHighlight(e,t,n){const i=(e.options.highlight||{}).toggle;if(i){const r={category:e.category,series:e.series,dataItem:e.dataItem,value:e.value,stackValue:e.stackValue,preventDefault:pY,visual:e.highlightVisual(),show:t};i(r),r._defaultPrevented||e.toggleHighlight(t,n)}else e.toggleHighlight(t,n)}hide(){const e=this._points;for(;e.length;)this.togglePointHighlight(e.pop(),!1)}isHighlighted(e){const t=this._points;for(let n=0;n<t.length;n++){if(e===t[n])return!0}return!1}}function pY(){this._defaultPrevented=!0}function fY(e,t){const n=(t||"").toLowerCase();const i=e.event;return"none"===n&&!(i.ctrlKey||i.shiftKey||i.altKey)||i[n+"Key"]}function mY(e){const t={};for(let n=0;n<e.length;n++){const i=e[n];i.axis.options.name&&(t[i.axis.options.name]={min:i.range.min,max:i.range.max})}return t}class gY{constructor(e,t){this.plotArea=e,this.options=cN({},this.options,t)}start(e){return this._active=fY(e,this.options.key),this._active}move(e){if(this._active){const t=this.axisRanges=this._panAxes(e,$V).concat(this._panAxes(e,UV));if(t.length)return this.axisRanges=t,mY(t)}}end(){const e=this._active;return this._active=!1,e}pan(){const{plotArea:e,axisRanges:t}=this;if(t.length){for(let n=0;n<t.length;n++){const i=t[n];e.updateAxisOptions(i.axis,i.range)}e.redraw(e.panes)}}destroy(){delete this.plotArea}_panAxes(e,t){const n=this.plotArea;const i=-e[t].delta;const r=(this.options.lock||"").toLowerCase();const o=[];if(0!==i&&(r||"").toLowerCase()!==t){const e=n.axes;for(let n=0;n<e.length;n++){const r=e[n];if(t===$V&&!r.options.vertical||t===UV&&r.options.vertical){const e=r.pan(i);e&&(e.limitRange=!0,o.push({axis:r,range:e}))}}}return o}}gY.prototype.options={key:"none",lock:"none"};class vY{constructor(e,t){this.chart=e,this.options=cN({},this.options,t),this.createElement()}createElement(){const e=this._marquee=document.createElement("div");e.className="k-marquee";const t=document.createElement("div");t.className="k-marquee-color",e.appendChild(t)}removeElement(){this._marquee.parentNode&&this._marquee.parentNode.removeChild(this._marquee)}setStyles(e){fN(this._marquee,e)}start(e){if(fY(e,this.options.key)){const t=this.chart;const n=t._eventCoordinates(e);const i=this._zoomPane=t._plotArea.paneByPoint(n);const r=i?i.chartsBox().clone():null;if(i&&r){const t=this._elementOffset();return r.translate(t.left,t.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}_elementOffset(){const e=this.chart.element;const{paddingLeft:t,paddingTop:n}=fN(e,["paddingLeft","paddingTop"]);const i=FN(e);return{left:t+i.left,top:n+i.top}}move(e){this._zoomPane&&this.setStyles(this._selectionPosition(e))}end(e){if(this._zoomPane){const t=this._elementOffset();const n=this._selectionPosition(e);n.left-=t.left,n.top-=t.top;const i={x:n.left,y:n.top};const r={x:n.left+n.width,y:n.top+n.height};return this._updateAxisRanges(i,r),this.removeElement(),delete this._zoomPane,mY(this.axisRanges)}}zoom(){const e=this.axisRanges;if(e&&e.length){const t=this.chart._plotArea;for(let n=0;n<e.length;n++){const i=e[n];t.updateAxisOptions(i.axis,i.range)}t.redraw(t.panes)}}destroy(){this.removeElement(),delete this._marquee,delete this.chart}_updateAxisRanges(e,t){const n=(this.options.lock||"").toLowerCase();const i=[];const r=this._zoomPane.axes;for(let o=0;o<r.length;o++){const a=r[o];const s=a.options.vertical;if((n!==$V||s)&&(n!==UV||!s)&&HN(a.axisIndex)){const n=a.pointsRange(e,t);n&&i.push({axis:a,range:n})}}this.axisRanges=i}_selectionPosition(e){const t=this._zoomPaneClipBox;const n={x:e.x.startLocation,y:e.y.startLocation};const{x:{location:i},y:{location:r}}=e;const o=(this.options.lock||"").toLowerCase();let a=Math.min(n.x,i);let s=Math.min(n.y,r);let l=Math.abs(n.x-i);let c=Math.abs(n.y-r);return o===$V&&(a=t.x1,l=t.width()),o===UV&&(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}}}vY.prototype.options={key:"shift",lock:"none"};class _Y{constructor(e,t){this.chart=e,this.options=cN({rate:.3},this.options,t)}updateRanges(e,t){const n=(this.options.lock||"").toLowerCase();const i=[];const r=this.chart._plotArea.axes;for(let o=0;o<r.length;o++){const a=r[o];const s=a.options.vertical;if((n!==$V||s)&&(n!==UV||!s)&&a.zoomRange){const n=WN(this.options.rate,.01,.9);const r=a.zoomRange(-e*n,t);r&&i.push({axis:a,range:r})}}return this.axisRanges=i,mY(i)}zoom(){const e=this.axisRanges;const t=this.chart._plotArea;if(e&&e.length&&t.updateAxisOptions){for(let n=0;n<e.length;n++){const i=e[n];t.updateAxisOptions(i.axis,i.range)}t.redraw(t.panes)}}destroy(){delete this.chart}}class bY extends vU{constructor(e,t){super(e),this.chartService=t}render(){const{children:e,options:t}=this;const n=t.vertical;var i;this.visual=new Qs(null,{spacing:n?0:t.spacing,lineSpacing:n?t.spacing:0,orientation:n?qV:jV,reverse:t.rtl,alignItems:n?(i=t.rtl,i?mV:PV):lV});for(let t=0;t<e.length;t++){let n=e[t];n.reflow(new hU),n.renderVisual()}}reflow(e){this.visual.rect(e.toRect()),this.visual.reflow();const t=this.visual.clippedBBox();this.box=t?BU(t):new hU}renderVisual(){this.addVisual()}createVisual(){}}const wY=10;class yY extends MU{visualStyle(){const e=this.markerOptions();const t=e.border;return{stroke:{width:t.width,color:t.color,opacity:YN(t.opacity,e.opacity),dashType:t.dashType},fill:{color:e.background,opacity:e.opacity},cursor:e.cursor}}markerOptions(){return this.options}markerHighlightOptions(){const e=this.markerOptions();const t=e.highlight.border.width;return cN({},e,{background:e.border.color},e.highlight,e.type===dV?{background:e.highlight.border.color,border:{color:e.highlight.background,width:t/2},width:e.width,height:e.height,margin:{top:0,left:0}}:{})}createHighlight(){const e=new MU(this.markerHighlightOptions());const t=this.paddingBox.clone();return e.reflow(t.pad(e.options.border.width)),this.highlight=[e.getElement()],this.highlight}}XN(yY,{border:{width:2},width:8,height:8,background:VV,margin:{top:-1,left:-1},vAlign:BV,align:kV,highlight:{width:wY,height:wY,border:{color:VV,width:2}}});class kY extends MU{getElement(){const e=new Us;const t=new Fs(this.visualStyle());const{paddingBox:n}=this;const 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}}XN(kY,{width:15,height:15,align:IV,vAlign:sV,margin:{right:-2,bottom:2}});class xY extends MU{getElement(){const e=new Us;const t=new Fs({stroke:{color:this.options.border.color,opacity:this.options.opacity,width:this.options.height,dashType:this.options.dashType}});const n=this.paddingBox;const i=n.center().y;return t.moveTo(n.x1,i).lineTo(n.x2,i),e.append(t),e}createHighlight(){return this.highlight=[this.createHighlightLine(),this.createHighlightMarker()],this.highlight}createHighlightLine(){const e=cN({},{border:{color:this.options.border.color,opacity:this.options.border.opacity,dashType:this.options.border.dashType}},this.options.highlight);const t=new kY(e);return t.reflow(this.parent.paddingBox.clone()),this.highlightLine=t.getElement(),this.highlightLine}createHighlightMarker(){const e=cN({},{background:this.options.background},this.options.highlight.markers);const t=new MU(e);const n=this.parent.paddingBox;const i=e.border.width;const r=this.parent.box.clone();return r.pad({left:i-n.x1,top:i-n.y1}),t.reflow(r),this.highlightMarker=t.getElement(),this.highlightMarker}}XN(xY,{border:{width:0},type:FV,align:kV,vAlign:lV,highlight:{border:{width:2},markers:{type:cV,width:wY,height:wY,border:{width:2,color:VV},align:kV,vAlign:BV}}});class CY extends MU{createHighlight(){const e=cN({},{background:this.options.background},this.options.highlight.markers);const t=new MU(e);const n=this.paddingBox.clone();const i=this.parent.box.clone();return n.align(i,$V,kV),n.align(i,UV,BV),t.reflow(n),this.highlight=[t.getElement()],this.highlight}}XN(CY,{highlight:{markers:{type:cV,width:wY,height:wY,border:{width:2,color:VV},margin:{top:-3,left:-3}}}});class SY extends SU{constructor(e){super(e),this.createContainer(),e.rtl?(this.createLabel(),this.createMarker()):(this.createMarker(),this.createLabel()),this._id=T$(),this.options.accessibility.ariaChecked=e.active}createContainer(){this.container=new zU({vertical:!1,wrap:!1,align:lV,spacing:this.options.spacing}),this.append(this.container)}createMarker(){this.markerWrap=new SU({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))}createMarkerArea(){const e=this.options;const{markerColor:t,line:n={}}=e;const i={border:{color:n.color||t,opacity:n.opacity,dashType:n.dashType}};return this._createLine(i)||this._createMarkerLine(i,n)||this._createSquare()}markerOptions(){const e=this.options;const{markers:t={},markerColor:n}=e;const{border:i={}}=t;return t.zIndex=void 0,cN({},t,{border:{color:i.color||n},highlight:e.highlight.markers})}_highlightOptions(){const e=this.options;return cN({markers:{type:e.markers.type}},e.highlight)}_createLine(e){const t=this.options;return t.type!==Jj||t.markers.visible||(this._line=new xY(cN({},{background:t.markerColor,highlight:this._highlightOptions()},e,t.line)),this.markerWrap.append(this._line)),this._line}_createMarkerLine(e,t){return this.options.type===Jj&&(this._markerLineArea=new kY(cN({},{border:{width:t.height}},e)),this.markerWrap.append(this._markerLineArea)),this._markerLineArea}_reduceSize(e,t,n=.6){"number"==typeof e[t]&&(e[t]=e[t]*n)}_createSquare(){const e=this.options;if(e.type===Nj){let t=e.pattern||(e.series||{}).pattern;t&&("function"==typeof t&&(t=t(e.series)),t=Object.assign({},t),this._reduceSize(t,"gap"),this._reduceSize(t,"width"),this._reduceSize(t,"radius")),this._square=new CY(Object.assign({},{border:e.border,vAlign:e.markers.visible?sV:lV,highlight:this._highlightOptions()},e.area,{pattern:t,background:e.area.background||e.markerColor})),this.markerWrap.append(this._square)}return this._square}_createMarker(){return new yY(this.markerOptions())}_highlightMarkers(){this.options.active&&this._toggleHighlight(!0)}_restoreMarkers(){this._toggleHighlight(!1)}_toggleHighlight(e){if(!this.options.highlight.visible)return;const t=this._marker||this._square||this._line;if(t&&t===this._line&&this._line.visual.visible(!e),t){let n=t.highlight;n||(n=t.createHighlight(),n.forEach((e=>e&&this.markerWrap.appendVisual(e)))),n.forEach((t=>t&&t.visible(e)))}}createLabel(){const e=this.options;const t=cN({},e.labels);this.container.append(new RU(e.text,t))}getAriaLabelText(){return this.options.text}focusVisual(){this.visual.options.set("id",this._id),this.toggleFocusHighlight(!0),this._highlightMarkers()}clearFocusFromVisual(){this.visual.options.set("id",""),this.toggleFocusHighlight(!1),this._restoreMarkers()}renderComplete(){super.renderComplete();const e=this.options.cursor||{};const t=this._itemOverlay=Rs.fromRect(this.container.box.toRect(),{fill:{color:VV,opacity:0},stroke:null,cursor:e.style||e});this.appendVisual(t)}click(e,t){const n=this.eventArgs(t);!e.trigger(Mq,n)&&t&&"contextmenu"===t.type&&t.preventDefault()}over(e,t){const n=this.eventArgs(t);return e.trigger(Aq,n)||(e._legendItemHover(n.seriesIndex,n.pointIndex),this._highlightMarkers()),!0}out(e,t){e._unsetActivePoint(),this._restoreMarkers(),e.trigger(Dq,this.eventArgs(t))}eventArgs(e){const t=this.options;return{element:NN(e),text:t.text,series:t.series,seriesIndex:t.series.index,pointIndex:t.pointIndex}}createVisual(){super.createVisual();const e=this.options;if(this.options.visible){const t=cN({ariaLabel:void 0!==e.accessibility.ariaLabel?e.accessibility.ariaLabel:e.text},e.accessibility);TU(this.visual,t)}}renderVisual(){const e=this.options;const t=e.visual;t?(this.visual=t({active:e.active,series:e.series,sender:this.getSender(),pointIndex:e.pointIndex,options:{type:e.type,markers:cN({background:this.options.markerColor},this.markerOptions()),labels:e.labels},createVisual:()=>{this.createVisual(),this.renderChildren(),this.renderComplete();const e=this.visual;return delete this.visual,e}}),this._marker=this._markerLineArea=this._square=this._line=null,this.addVisual()):super.renderVisual()}createFocusHighlight(e){const t=e.stroke.width;return Rs.fromRect(this.container.box.pad(t/2).toRect(),e)}}XN(SY,{accessibility:{role:Jq,className:eG,ariaRoleDescription:tG},markers:{},highlight:{visible:!0,markers:{}}});const TY="custom";let MY=class extends vU{constructor(e,t={}){super(e),this.chartService=t,TN(this.options.position,[BV,IV,sV,kV,TY])||(this.options.position=IV),this.createContainers(),this.createLegendTitle(e.title),this.createItems()}createContainers(){const e=this.options;const{position:t,align:n}=e;let i=t;let r=lV;t===TY?i=kV:TN(t,[BV,sV])?(i=n===PV?kV:n===mV?IV:lV,r=t):n&&(n===PV?r=BV:n===mV&&(r=sV)),this.container=new SU({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 SU({vAlign:r,align:i,zIndex:e.zIndex,shrinkToFit:!0}):this.itemsContainer=this.container,this.append(this.container)}createItems(){const e=this.getService();const t=this.options;const n=this.isVertical();const i=new bY({vertical:n,spacing:t.spacing,rtl:e.rtl},e);let r=t.data;t.reverse&&(r=r.slice(0).reverse());const o=r.length;for(let n=0;n<o;n++){let o=r[n];const{markers:a={},dashType:s,legendItem:l,opacity:c}=o.series||{};const d=cN({visible:!1!==a.visible,type:cV},a);delete d.size;const h=cN({},{markers:d,labels:t.labels,rtl:e.rtl,line:Object.assign({},{dashType:s},t.line),area:Object.assign({},{opacity:c},t.area),opacity:c,accessibility:t.accessibility,focusHighlight:t.focusHighlight},t.item,l,o,{markers:t.markers});i.append(new SY(h))}i.render(),this.itemsContainer.append(i)}isVertical(){const{orientation:e,position:t}=this.options;return t===TY&&e!==jV||(HN(e)?e!==jV:TN(t,[kV,IV]))}hasItems(){return this.container.children[0].children.length>0}getItems(){return this.itemsContainer.children[0].children}reflow(e){const t=this.options;const n=e.clone();this.hasItems()?(t.position===TY?(this.containerCustomReflow(n),this.box=n):this.containerReflow(n),this.hasTitle()&&this.title.reflow(new hU(this.container.box.x1,this.title.box.y1,this.container.box.x2,this.title.box.y2))):this.box=n}containerReflow(e){const{options:t,container:n}=this;const{position:i,width:r,height:o}=t;const a=i===BV||i===sV?$V:UV;const s=this.isVertical();const l=e.clone();let c=e.clone();i!==kV&&i!==IV||(c.y1=l.y1=0),s&&o?(c.y2=c.y1+o,c.align(l,UV,n.options.vAlign)):!s&&r&&(c.x2=c.x1+r,c.align(l,$V,n.options.align)),n.reflow(c),c=n.box;const d=c.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}containerCustomReflow(e){const{options:t,container:n}=this;const{offsetX:i,offsetY:r,width:o,height:a}=t;const s=this.isVertical();let 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 hU(i,r,i+l.width(),r+l.height()))}renderVisual(){this.hasItems()&&super.renderVisual()}createLegendTitle(e){let t=cN({},{color:aV,position:BV,align:lV},e);let n=t.text;if(e&&!1!==e.visible&&e.text){if(HN(t)&&t.visible){const e=_N(t);e?n=e({text:n}):t.format&&(n=this.chartService.format.auto(t.format,n))}this.title=new RU(n,t),this.createTitleLayout(),this.appendTitleLayoutContent()}}createTitleLayout(){this.layout=new zU({vertical:!0,wrap:!1}),this.container.append(this.layout)}hasTitle(){return Boolean(this.options.title&&!1!==this.options.title.visible&&this.options.title.text)}appendTitleLayoutContent(){this.options.title.position===sV?(this.layout.append(this.itemsContainer),this.layout.append(this.title)):(this.layout.append(this.title),this.layout.append(this.itemsContainer))}};XN(MY,{position:IV,data:[],offsetX:0,offsetY:0,margin:mN(2),padding:mN(5),border:{color:aV,width:0},item:{cursor:WV,spacing:6},spacing:6,background:"",zIndex:1,markers:{},line:{width:20,height:2,cursor:WV,opacity:1},area:{type:RV,align:IV,width:15,height:15}});class AY{constructor(){this._registry=[]}register(e,t){this._registry.push({type:e,seriesTypes:t})}create(e,t,n){const i=this._registry;let r=i[0];let o;for(let t=0;t<i.length;t++){const n=i[t];o=xG(e,n.seriesTypes);const a=xG(e,Tq);if(o.length-a.length>0){r=n;break}}return new r.type(o,t,n)}}AY.current=new AY;function DY(e){const t=document.createElement("div");return e&&(t.className=e),t}function EY(e){let t=e;for(;t&&!CN(t,"k-handle");)t=t.parentNode;return t}class IY{constructor(e,t,n,i){const r=e.element;this.options=cN({},this.options,n),this.chart=e,this.observer=i,this.chartElement=r,this.categoryAxis=t,this._dateAxis=this.categoryAxis instanceof WW,this.initOptions(),this.visible=this.options.visible&&r.offsetHeight,this.visible&&(this.createElements(),this.set(this._index(this.options.from),this._index(this.options.to)),this.bindEvents())}onPane(e){return this.categoryAxis.pane===e}createElements(){const e=this.options;const t=this.wrapper=DY("k-selector k-pointer-events-none");fN(t,{top:e.offset.top,left:e.offset.left,width:e.width,height:e.height,direction:"ltr"});const n=this.selection=DY("k-selection k-pointer-events-none");this.leftMask=DY("k-mask k-pointer-events-none"),this.rightMask=DY("k-mask k-pointer-events-none"),t.appendChild(this.leftMask),t.appendChild(this.rightMask),t.appendChild(n);const i=this.body=DY("k-selection-bg k-pointer-events-none");n.appendChild(i);const r=this.leftHandle=DY("k-handle k-left-handle k-pointer-events-auto");const o=this.rightHandle=DY("k-handle k-right-handle k-pointer-events-auto");r.appendChild(DY()),o.appendChild(DY()),n.appendChild(r),n.appendChild(o),this.chartElement.appendChild(t);const a=fN(n,["borderLeftWidth","borderRightWidth","height"]);const s=fN(r,"height").height;const l=fN(o,"height").height;e.selection={border:{left:a.borderLeftWidth,right:a.borderRightWidth}},fN(r,{top:(a.height-s)/2}),fN(o,{top:(a.height-l)/2}),t.style.cssText=t.style.cssText}bindEvents(){!1!==this.options.mousewheel&&(this._mousewheelHandler=this._mousewheel.bind(this),BN(this.chartElement,{[sG]:this._mousewheelHandler})),this._domEvents=YU.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)})}initOptions(){const{options:e,categoryAxis:t}=this;const n=t.pane.chartsBox();const i=this.chart.chartService.intl;this._dateAxis&&cN(e,{min:IW(i,e.min),max:IW(i,e.max),from:IW(i,e.from),to:IW(i,e.to)});const{paddingLeft:r,paddingTop:o}=fN(this.chartElement,["paddingLeft","paddingTop"]);this.options=cN({},{width:n.width(),height:n.height()+.1,padding:{left:r,top:o},offset:{left:n.x1+r,top:n.y1+o},from:e.min,to:e.max},e)}destroy(){this._domEvents&&(this._domEvents.destroy(),delete this._domEvents),clearTimeout(this._mwTimeout),this._state=null,this.wrapper&&(this._mousewheelHandler&&(KN(this.chartElement,{[sG]:this._mousewheelHandler}),this._mousewheelHandler=null),this.chartElement.removeChild(this.wrapper),this.wrapper=null)}_rangeEventArgs(e){return{axis:this.categoryAxis.options,from:this._value(e.from),to:this._value(e.to)}}_pointInPane(e,t){const n=this.categoryAxis.pane.box;const i=this.chart._toModelCoordinates(e,t);return n.containsPoint(i)}_start(e){const t=this.options;const n=NN(e);if(this._state||!n)return;const i=VN(e);if(!this._pointInPane(i.x,i.y))return;const r=EY(n);const o=this.body.getBoundingClientRect();const 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)}};const s=this._rangeEventArgs({from:this._index(t.from),to:this._index(t.to)});this.trigger(Uq,s)&&(this._state=null)}_press(e){let t;t=this._state?this._state.moveTarget:EY(NN(e)),t&&YV(t,"k-handle-active")}_move(e){if(!this._state)return;const{_state:t,options:n,categoryAxis:i}=this;const{range:r,moveTarget:o}=t;const a=i.options.reverse;const s=this._index(n.from);const l=this._index(n.to);const c=this._index(n.min);const d=this._index(n.max);const h=t.startLocation-e.x.location;const u=r.from,p=r.to;const f=r.to-r.from;const m=fN(this.wrapper,"width").width/(i.categoriesCount()-1);const g=Math.round(h/m)*(a?-1:1);if(!o&&!t.inBody)return;const v=o&&CN(o,"k-left-handle");const _=o&&CN(o,"k-right-handle");t.inBody?(r.from=Math.min(Math.max(c,s-g),d-f),r.to=Math.min(r.from+f,d)):v&&!a||_&&a?(r.from=Math.min(Math.max(c,s-g),d-1),r.to=Math.max(r.from+1,r.to)):(v&&a||_&&!a)&&(r.to=Math.min(Math.max(c+1,l-g),d),r.from=Math.min(r.to-1,r.from)),r.from===u&&r.to===p||(this.move(r.from,r.to),this.trigger(Wq,this._rangeEventArgs(r)))}_end(){if(this._state){const e=this._state.moveTarget;e&&XV(e,"k-handle-active");const t=this._state.range;this.set(t.from,t.to),this.trigger(jq,this._rangeEventArgs(t)),delete this._state}}_tap(e){const{options:t,categoryAxis:n}=this;const i=this.chart._eventCoordinates(e);const r=n.pointCategoryIndex(new dU(i.x,n.box.y1));const o=this._index(t.from);const a=this._index(t.to);const s=this._index(t.min);const l=this._index(t.max);const c=a-o;const d=o+c/2;const h={};const u=3===e.event.which;let p=Math.round(d-r);this._state||u||(this.chart._unsetActivePoint(),n.options.justified||p--,h.from=Math.min(Math.max(s,o-p),l-c),h.to=Math.min(h.from+c,l),this._start(e),this._state&&(this._state.range=h,this.trigger(Wq,this._rangeEventArgs(h)),this._end()))}_mousewheel(e){let t=PN(e);if(this._start(e),this._state){const n=this._state.range;e.preventDefault(),e.stopPropagation(),Math.abs(t)>1&&(t*=3),this.options.mousewheel.reverse&&(t*=-1),this.expand(t)&&this.trigger(Wq,{axis:this.categoryAxis.options,delta:t,originalEvent:e,from:this._value(n.from),to:this._value(n.to)}),this._mwTimeout&&clearTimeout(this._mwTimeout),this._mwTimeout=setTimeout((()=>{this._end()}),lG)}}_gesturestart(e){const t=this.options;const n=e.touches[0];if(!this._pointInPane(n.pageX,n.pageY))return;this._state={range:{from:this._index(t.from),to:this._index(t.to)}};const i=this._rangeEventArgs(this._state.range);this.trigger(Uq,i)?this._state=null:e.preventDefault()}_gestureend(){this._state&&(this.trigger(jq,this._rangeEventArgs(this._state.range)),delete this._state)}_gesturechange(e){if(!this._state)return;const{chart:t,_state:n,options:i,categoryAxis:r}=this;const o=n.range;const a=t._toModelCoordinates(e.touches[0].x.location).x;const s=t._toModelCoordinates(e.touches[1].x.location).x;const l=Math.min(a,s);const c=Math.max(a,s);e.preventDefault(),o.from=r.pointCategoryIndex(new dU(l))||i.min,o.to=r.pointCategoryIndex(new dU(c))||i.max,this.move(o.from,o.to),this.trigger(Wq,this._rangeEventArgs(o))}_index(e){let t=e;return e instanceof Date&&(t=this.categoryAxis.categoryIndex(e)),t}_value(e){let t=e;return this._dateAxis&&(t=this.categoryAxis.categoryAt(e),t>this.options.max&&(t=this.options.max)),t}_slot(e){const t=this.categoryAxis;const n=this._index(e);return t.getSlot(n,n,!0)}move(e,t){const n=this.options;const i=this.categoryAxis.options.reverse;const{offset:r,padding:o,selection:{border:a}}=n;const s=i?t:e;const l=i?e:t;const c="x"+(i?2:1);let d=this._slot(s);const h=GN(d[c]-r.left+o.left);fN(this.leftMask,{width:h}),fN(this.selection,{left:h}),d=this._slot(l);const u=GN(n.width-(d[c]-r.left+o.left));fN(this.rightMask,{width:u});let p=n.width-u;p!==n.width&&(p+=a.right),fN(this.rightMask,{left:p}),fN(this.selection,{width:Math.max(n.width-(h+u)-a.right,0)})}set(e,t){const n=this.options;const i=this._index(n.min);const r=this._index(n.max);const o=WN(this._index(e),i,r);const a=WN(this._index(t),o+1,r);n.visible&&this.move(o,a),n.from=this._value(o),n.to=this._value(a)}expand(e){const t=this.options;const n=this._index(t.min);const i=this._index(t.max);const r=t.mousewheel.zoom;const o=this._index(t.from);const a=this._index(t.to);let s={from:o,to:a};const l=cN({},s);if(this._state&&(s=this._state.range),r!==IV&&(s.from=WN(WN(o-e,0,a-1),n,i)),r!==kV&&(s.to=WN(WN(a+e,s.from+1,i),n,i)),s.from!==l.from||s.to!==l.to)return this.set(s.from,s.to),!0}zoom(e,t){const n=this.options;const i=this._index(n.min);const r=this._index(n.max);const o=this._index(n.from);const a=this._index(n.to);let s={from:o,to:a};const l=cN({},s);const{reverse:c}=this.categoryAxis.options;const d=$V+(c?"2":"1");const h=this.categoryAxis.lineBox();const u=Math.abs(h[d]-t[$V]);const p=h.width();const f=GN(u/p,2);const m=GN(f*e);const g=GN((1-f)*e);if(this._state&&(s=this._state.range),s.from=WN(WN(o-m,0,a-1),i,r),s.to=WN(WN(a+g,s.from+1,r),i,r),s.from!==l.from||s.to!==l.to)return this.set(s.from,s.to),!0}trigger(e,t){return(this.observer||this.chart).trigger(e,t)}}XN(IY,{visible:!0,mousewheel:{zoom:"both"},min:CV,max:xV});let zY=class extends bK{show(e){if(!e||!e.tooltipAnchor||this._current&&this._current===e)return;const t=cN({},this.options,e.options.tooltip);const n=e.tooltipAnchor();n?(this._current=e,super.show({point:e,anchor:n},t,e)):this.hide()}hide(){delete this._current,super.hide()}};let PY=class extends bK{constructor(e,t){super(e.chartService,t),this.plotArea=e,this.formatService=e.chartService.format}showAt(e,t){const n=xN(e,(function(e){const t=e.series.tooltip;return!(t&&!1===t.visible)}));if(n.length>0){const i=n[0];const r=this.plotArea.categoryAxis.getSlot(i.categoryIx);const 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)}}_slotAnchor(e,t){return this.plotArea.categoryAxis.options.vertical||(e.x=t.center().x),{point:e,align:{horizontal:"left",vertical:"center"}}}_defaultAnchor(e,t){const n=e.owner.pane.chartsBox();const i=this.plotArea.categoryAxis.options.vertical;const r=n.center();const o=t.center();let a;return a=i?new dU(r.x,o.y):new dU(o.x,r.y),{point:a,align:{horizontal:"center",vertical:"center"}}}};XN(PY,{categoryFormat:"{0:d}"});class LY extends kl{setup(){const{element:e,options:t}=this;if(e.bbox()){this.origin=t.origin;const n=t.vertical?UV:$V;const i=this.fromScale=new ba(1,1);i[n]=Mj,e.transform(xa().scale(i.x,i.y))}else this.abort()}step(e){const t=MN(this.fromScale.x,1,e);const n=MN(this.fromScale.y,1,e);this.element.transform(xa().scale(t,n,this.origin))}abort(){super.abort(),this.element.transform(null)}}XN(LY,{duration:Cj}),yl.current.register($j,LY);class BY extends kl{setup(){const e=this.center=this.element.bbox().center();this.element.transform(xa().scale(Mj,Mj,e))}step(e){this.element.transform(xa().scale(e,e,this.center))}}XN(BY,{easing:"easeOutElastic"}),yl.current.register(Wj,BY);class HY extends kl{setup(){this.fadeTo=this.element.opacity(),this.element.opacity(0)}step(e){this.element.opacity(e*this.fadeTo)}}XN(HY,{duration:200,easing:"linear"}),yl.current.register(Sj,HY);class RY extends kl{setup(){this.element.transform(xa().scale(Mj,Mj,this.options.center))}step(e){this.element.transform(xa().scale(e,e,this.options.center))}}XN(RY,{easing:"easeOutElastic",duration:Cj}),yl.current.register(tq,RY);class FY extends pK{render(){super.render(),this.renderSegments()}createSegment(e,t,n){let i;return i=t.style===Oj?UG:OG,new i(e,t,n)}animationPoints(){return super.animationPoints().concat(this._segments)}createMissingValue(e,t){if(t===Lj){const t={x:e.x,y:e.y};return MG(t.x)||(t.x=0),MG(t.y)||(t.y=0),t}}}function OY(e,t,n){const i=[];let{xMin:r,xMax:o}=t;const a=(n||{}).forecast;a&&(a.before>0&&(r-=a.before),a.after>0&&(o+=a.after));const s=(n||{}).samplingInterval;let l=YN(s,cU(r,o)/10);s<=0&&(l=o-r);for(let t=r;t<=o;t+=l)i.push([t,e(t)]);return i}cN(FY.prototype,WG);const VY=e=>({valueFields:t})=>({xValue:t.x,yValue:Math.log(t[e])});const NY=e=>({valueFields:t})=>({xValue:t.x,yValue:t[e]});function $Y(e,t){let n=Number.MAX_VALUE;let i=Number.MIN_VALUE;for(let r=0;r<e.length;r++){const o=e[r];const{xValue:a,yValue:s}=t(o);isFinite(a)&&null!==a&&isFinite(s)&&null!==s&&(n=Math.min(a,n),i=Math.max(a,i))}return{xMin:n,xMax:i}}const UY=e=>({valueFields:t})=>({xValue:t.x,yValue:t[e]});const WY=e=>({valueFields:t})=>({xValue:Math.log(t.x),yValue:t[e]});const jY=e=>({valueFields:t})=>({xValue:Math.log(t.x),yValue:Math.log(t[e])});const qY={};qY[wq]=function(e){const{options:t,seriesValues:n}=e;const i=function({seriesValues:e,options:t}){const n=e();if(!QK(n,t.field))return null;let{slope:i,intercept:r,count:o,xMin:a,xMax:s}=YK(n,VY(t.field));const l={xMin:a,xMax:s};if(o>0){const e=Math.exp(r);const n=i;return OY((t=>e*Math.exp(n*t)),l,t.trendline)}return null}({seriesValues:n,options:t});return i?Object.assign({},t,{type:"scatterLine",data:i}):null},qY[yq]=function(e){const{options:t,seriesValues:n}=e;const i=function({seriesValues:e,options:t}){let{slope:n,intercept:i,count:r,xMin:o,xMax:a}=YK(e(),NY(t.field));const s={xMin:o,xMax:a};if(r>0)return OY((e=>n*e+i),s,t.trendline);return null}({seriesValues:n,options:t});return i?Object.assign({},t,{type:"scatterLine",data:i}):null},qY[kq]=function(e){const{options:t,seriesValues:n}=e;const i=function({seriesValues:e,options:t}){const n=e();if(!QK(n,"x"))return null;let{slope:i,intercept:r,count:o}=YK(n,WY(t.field));let a=$Y(n,UY(t.field));if(o>0){const e=i;const n=r;return OY((t=>e*Math.log(t)+n),a,t.trendline)}return null}({seriesValues:n,options:t});return i?Object.assign({},t,{type:"scatterLine",data:i}):null},qY[xq]=function(e){const{options:t}=e;const n=function({options:e,seriesValues:t}){const n=(e.trendline||{}).period||2;const i=tY(t({before:n,after:n}),NY(e.field),n);if(i.length>0)return i;return null}(e);return n?Object.assign({},t,{type:"scatterLine",data:n}):null},qY[Cq]=function(e){const{options:t,seriesValues:n}=e;const i=function({seriesValues:e,options:t}){const n=(t.trendline||{}).order;const i=NY(t.field);const{count:r,valueMapper:o,xMin:a,xMax:s}=iY(e(),i,n);const l={xMin:a,xMax:s};if(r>0)return OY(o,l,t.trendline);return null}({seriesValues:n,options:t});return i?Object.assign({},t,{type:"scatterLine",data:i}):null},qY[Sq]=function(e){const{options:t,seriesValues:n}=e;const i=function({seriesValues:e,options:t}){const n=e();if(!QK(n,"x"))return null;let{slope:i,intercept:r,count:o}=YK(n,jY(t.field));let a=$Y(n,NY(t.field));if(o>0){const e=Math.exp(r);const n=i;return OY((t=>e*Math.pow(t,n)),a,t.trendline)}return null}({seriesValues:n,options:t});return i?Object.assign({},t,{type:"scatterLine",data:i}):null};class GY extends TK{initFields(){this.namedXAxes={},this.namedYAxes={},this.xAxisRangeTracker=new ZG,this.yAxisRangeTracker=new ZG}render(e=this.panes){this.series=[...this.originalSeries],this.createTrendlineSeries();const t=this.groupSeriesByPane();for(let n=0;n<e.length;n++){const i=e[n];const r=t[i.options.name||"default"]||[];this.addToLegend(r);const o=this.filterVisibleSeries(r);o&&(this.createScatterChart(xG(o,hq),i),this.createScatterLineChart(xG(o,uq),i),this.createBubbleChart(xG(o,Wj),i))}this.createAxes(e)}appendChart(e,t){this.xAxisRangeTracker.update(e.xAxisRanges),this.yAxisRangeTracker.update(e.yAxisRanges),super.appendChart(e,t)}removeAxis(e){const t=e.options.name;super.removeAxis(e),e.options.vertical?(this.yAxisRangeTracker.reset(t),delete this.namedYAxes[t]):(this.xAxisRangeTracker.reset(t),delete this.namedXAxes[t]),e===this.axisX&&delete this.axisX,e===this.axisY&&delete this.axisY}seriesPaneName(e){const t=this.options;const n=e.xAxis;const i=[].concat(t.xAxis);const r=xN(i,(function(e){return e.name===n}))[0];const o=e.yAxis;const a=[].concat(t.yAxis);const s=xN(a,(function(e){return e.name===o}))[0];const l=(t.panes||[{}])[0].name||"default";return(r||{}).pane||(s||{}).pane||l}createScatterChart(e,t){e.length>0&&this.appendChart(new pK(this,{series:e,clip:t.options.clip}),t)}createScatterLineChart(e,t){e.length>0&&this.appendChart(new FY(this,{series:e,clip:t.options.clip}),t)}createBubbleChart(e,t){e.length>0&&this.appendChart(new mK(this,{series:e,clip:t.options.clip}),t)}createXYAxis(e,t,n){const i=e.name;const r=t?this.namedYAxes:this.namedXAxes;const o=t?this.yAxisRangeTracker:this.xAxisRangeTracker;const a=cN({reverse:!t&&this.chartService.rtl},e,{vertical:t});const s=yG(a.type,nG);const l=o.query();const c=s?{min:.1,max:1}:{min:0,max:1};const d=o.query(i)||l||c;const h=[a.min,a.max];const u=this.series;for(let e=0;e<u.length;e++){const i=u[e];const r=i[t?"yAxis":"xAxis"];if(r===a.name||0===n&&!r){const e=bj.current.bindPoint(i,0).valueFields;h.push(e[t?"y":"x"]);break}}let p;0===n&&l&&(d.min=Math.min(d.min,l.min),d.max=Math.max(d.max,l.max));for(let e=0;e<h.length;e++)if(h[e]instanceof Date){p=!0;break}let f;f=yG(a.type,hV)||!a.type&&p?XW:s?JW:YW;const m=new f(d.min,d.max,a,this.chartService);if(m.axisIndex=n,i){if(r[i])throw new Error(`${t?"Y":"X"} axis with name ${i} is already defined`);r[i]=m}return this.appendAxis(m),m}createAxes(e){const t=this.options;const n=[].concat(t.xAxis);const i=[];const r=[].concat(t.yAxis);const o=[];for(let t=0;t<n.length;t++){TN(this.findPane(n[t].pane),e)&&i.push(this.createXYAxis(n[t],!1,t))}for(let t=0;t<r.length;t++){TN(this.findPane(r[t].pane),e)&&o.push(this.createXYAxis(r[t],!0,t))}this.axisX=this.axisX||i[0],this.axisY=this.axisY||o[0]}_dispatchEvent(e,t,n){const i=e._eventCoordinates(t);const r=new dU(i.x,i.y);const o=this.axes;const a=o.length;const s=[];const l=[];for(let e=0;e<a;e++){const t=o[e];const n=t.options.vertical?l:s;const i=t.getValue(r);null!==i&&n.push(i)}s.length>0&&l.length>0&&e.trigger(n,{element:NN(t),originalEvent:t,x:DG(s),y:DG(l)})}updateAxisOptions(e,t){const n=e.options.vertical;const i=this.groupAxes(this.panes);const r=(n?i.y:i.x).indexOf(e);KY(this.options,r,n,t),KY(this.originalOptions,r,n,t)}trendlineFactory(e,t){const n=this.seriesValues.bind(this,t.index);const i=KK(qY,e.type,{options:e,seriesValues:n});return i&&(i.xAxis=t.xAxis,i.yAxis=t.yAxis),i}seriesValues(e){const t=[];const n=this.series[e];for(let e=0;e<n.data.length;e++){const i=this.bindPoint(n,e);t.push({pointIx:e,valueFields:i.valueFields})}return t}}function KY(e,t,n,i){cN([].concat(n?e.yAxis:e.xAxis)[t],i)}XN(GY,{xAxis:{},yAxis:{}}),cN(GY.prototype,IK);class YY extends vU{constructor(e,t,n){super(n),this.value=e,this.sector=t}render(){this._rendered||!1===this.visible||(this._rendered=!0,this.createLabel())}createLabel(){const e=this.options.labels;const t=this.owner.chartService;let n=this.getLabelText(e);if(e.visible&&(n||0===n)){if(e.position===lV||e.position===rG)e.color||(e.color=h$(this.options.color)),e.background||(e.background=this.options.color);else{const n=t.theme.seriesDefaults.labels;e.color=e.color||n.color,e.background=e.background||n.background}this.label=new RU(n,cN({},e,{align:lV,vAlign:"",animation:{type:Sj,delay:this.animationDelay}}),this.pointData()),this.append(this.label)}}getLabelText(e){let t=_N(e);return t?t(this.pointData()):this.owner.chartService.format.auto(e.format,this.value)}reflow(e){this.render(),this.box=e,this.reflowLabel()}reflowLabel(){const{options:{labels:e},label:t}=this;const n=this.sector.clone();const i=e.distance;const r=n.middle();if(t){const o=t.box.height();const a=t.box.width();let s;if(e.position===lV)n.radius=Math.abs((n.radius-o)/2)+o,s=n.point(r),t.reflow(new hU(s.x,s.y-o/2,s.x,s.y));else if(e.position===rG)n.radius=n.radius-o/2,s=n.point(r),t.reflow(new hU(s.x,s.y-o/2,s.x,s.y));else{let e;s=n.clone().expand(i).point(r),s.x>=n.center.x?(e=s.x+a,t.orientation=IV):(e=s.x-a,t.orientation=kV),t.reflow(new hU(e,s.y-o,s.x,s.y))}}}createVisual(){const{sector:e,options:t}=this;if(super.createVisual(),this.addAccessibilityAttributesToVisual(),this.value)if(t.visual){const n=(e.startAngle+180)%360;const i=t.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,center:new ba(e.center.x,e.center.y),radius:e.radius,innerRadius:e.innerRadius,startAngle:n,endAngle:n+e.angle,options:t,sender:this.getSender(),createVisual:()=>{const e=new Us;return this.createSegmentVisual(e),e}});i&&this.visual.append(i)}else this.createSegmentVisual(this.visual)}createSegmentVisual(e){const{sector:t,options:n}=this;const i=n.border||{};const r=i.width>0?{stroke:{color:i.color,width:i.width,opacity:i.opacity,dashType:i.dashType}}:{};const o=n.color;const a=CU(n.pattern,{color:o,opacity:n.opacity});const s=this.createSegment(t,cN({fill:a,stroke:{opacity:n.opacity},zIndex:n.zIndex},r));e.append(s),TG(n)&&e.append(this.createGradientOverlay(s,{baseColor:o,fallbackFill:a},cN({center:[t.center.x,t.center.y],innerRadius:t.innerRadius,radius:t.radius,userSpace:!0},n.overlay)))}createSegment(e,t){return t.singleSegment?new Ra(new Ia(new ba(e.center.x,e.center.y),e.radius),t):gU.current.createRing(e,t)}createAnimation(){const{options:e,sector:{center:t}}=this;cN(e,{animation:{center:[t.x,t.y],delay:this.animationDelay}}),super.createAnimation()}createHighlight(e){const t=this.options.highlight||{};const n=t.border||{};return this.createSegment(this.sector,cN({},e,{fill:{color:t.color,opacity:t.opacity},stroke:{opacity:n.opacity,width:n.width,color:n.color,dashType:n.dashType}}))}highlightVisual(){return this.visual.children[0]}highlightVisualArgs(){const e=this.sector;return{options:this.options,radius:e.radius,innerRadius:e.innerRadius,center:new ba(e.center.x,e.center.y),startAngle:e.startAngle,endAngle:e.angle+e.startAngle,visual:this.visual}}createFocusHighlight(e){const t=this.options.focusHighlight.border.width;const n=this.createSegment(this.sector,cN({},e,{stroke:{width:2*t}}));const i=new Fs;return i.paths.push(Rs.fromRect(n.bbox())),i.paths.push(this.createSegment(this.sector,{})),n.clip(i),n}tooltipAnchor(){const e=this.sector.clone().expand(5);const t=e.middle();return{point:e.point(t),align:ZY(t+180)}}formatValue(e){return this.owner.formatPointValue(this,e)}pointData(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}}getIndex(){return this.index}}const QY=GN(qN(30),pV);const XY=GN(qN(60),pV);function ZY(e){const t=qN(e);const n=GN(Math.sin(t),pV);const i=GN(Math.cos(t),pV);let r;let o;return r=Math.abs(n)>XY?lV:i<0?IV:kV,o=Math.abs(n)<QY?lV:n<0?sV:BV,{horizontal:r,vertical:o}}XN(YY,{color:VV,overlay:{gradient:"roundedBevel"},border:{width:.5},labels:{visible:!1,distance:35,font:uV,margin:mN(.5),align:cV,zIndex:1,position:aG},animation:{type:tq},highlight:{visible:!0,border:{width:1}},visible:!0,accessibility:{role:Qq,className:Xq,ariaRoleDescription:Zq}}),cN(YY.prototype,HG),cN(YY.prototype,eK);const JY={createLegendItem:function(e,t,n){const i=this.options.legend||{};const r=i.labels||{};const o=i.inactiveItems||{};const a=o.labels||{};if(n&&!1!==n.visibleInLegend){const i=!1!==n.visible;const s=i?_N(r):_N(a)||_N(r);let l=n.category;let c,d;s&&(l=s({text:l,series:n.series,dataItem:n.dataItem,percentage:n.percentage,value:e})),i?(c={},d=t.color):(c={color:a.color,font:a.font},d=(o.markers||{}).color),MG(l)&&""!==l&&this.legendItems.push({active:i,pointIndex:n.index,text:l,series:n.series,markerColor:d,pattern:t.pattern,labels:c})}}};class eQ extends vU{constructor(e,t){super(t),this.plotArea=e,this.chartService=e.chartService,this.points=[],this.legendItems=[],this.render()}render(){this.traverseDataPoints(this.addValue.bind(this))}traverseDataPoints(e){const{options:t,plotArea:{options:{seriesColors:n=[]}}}=this;const i=n.length;const r=t.series;const o=r.length;for(let a=0;a<o;a++){const s=r[a];const l=s.data;const{total:c,points:d,count:h}=bG(s);const u=360/c;let p;let f;isFinite(u)||(p=360/h),f=HN(s.startAngle)?s.startAngle:t.startAngle,a!==o-1&&s.labels.position===aG&&(s.labels.position=lV);for(let t=0;t<d.length;t++){const r=d[t];if(!r)continue;const{fields:h,value:m,visible:g}=r;const v=0!==m?p||m*u:0;const _=1!==l.length&&Boolean(h.explode);aN(s.color)||(s.color=h.color||n[t%i]),e(m,new pU(null,0,0,f,v),{owner:this,category:HN(h.category)?h.category:"",pattern:HN(h.pattern)?h.pattern:s.pattern,index:t,series:s,seriesIx:a,dataItem:l[t],percentage:0!==c?m/c:0,explode:_,visibleInLegend:h.visibleInLegend,visible:g,zIndex:o-a,animationDelay:this.animationDelay(t,a,o)}),!1!==g&&(f+=v)}}}evalSegmentOptions(e,t,n){const i=n.series;kG(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"]})}addValue(e,t,n){const i=cN({},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)return;const r=new YY(e,t,i);Object.assign(r,n),this.append(r),this.points.push(r)}reflow(e){const{options:t,points:n,seriesConfigs:i=[]}=this;const r=n.length;const o=e.clone();const a=Math.min(o.width(),o.height());const s=a/2;const l=a-.85*a;const c=new hU(o.x1,o.y1,o.x1+a,o.y1+a);const d=c.center();const h=o.center();const u=t.series.length;const p=[];const f=[];let m=YN(t.padding,l);this.targetBox=e,m=m>s-5?s-5:m,c.translate(h.x-d.x,h.y-d.y);const g=s-m;const v=new dU(g+c.x1+m,g+c.y1+m);for(let e=0;e<r;e++){const t=n[e];const r=t.sector;const o=t.seriesIx;if(r.radius=g,r.center=v,i.length){const e=i[o];r.innerRadius=e.innerRadius,r.radius=e.radius}o===u-1&&t.explode&&(r.center=r.clone().setRadius(.15*r.radius).point(r.middle())),t.reflow(c);const a=t.label;a&&a.options.position===aG&&o===u-1&&(a.orientation===IV?f.push(a):p.push(a))}p.length>0&&(p.sort(this.labelComparator(!0)),this.leftLabelsReflow(p)),f.length>0&&(f.sort(this.labelComparator(!1)),this.rightLabelsReflow(f)),this.box=c}leftLabelsReflow(e){const t=this.distanceBetweenLabels(e);this.distributeLabels(t,e)}rightLabelsReflow(e){const t=this.distanceBetweenLabels(e);this.distributeLabels(t,e)}distanceBetweenLabels(e){const t=UN(this.points);const n=t.sector;const i=e.length-1;const r=n.radius+t.options.labels.distance;const o=[];let a=e[0].box;let s=GN(a.y1-(n.center.y-r-a.height()-a.height()/2));o.push(s);for(let t=0;t<i;t++){const n=e[t+1].box;a=e[t].box,s=GN(n.y1-a.y2),o.push(s)}return s=GN(n.center.y+r-e[i].box.y2-e[i].box.height()/2),o.push(s),o}distributeLabels(e,t){const n=e.length;let i,r,o;for(let t=0;t<n;t++)for(o=-e[t],i=r=t;o>0&&(i>=0||r<n);)o=this._takeDistance(e,t,--i,o),o=this._takeDistance(e,t,++r,o);this.reflowLabels(e,t)}_takeDistance(e,t,n,i){let r=i;if(e[n]>0){const i=Math.min(e[n],r);r-=i,e[n]-=i,e[t]+=i}return r}reflowLabels(e,t){const n=UN(this.points);const i=n.sector;const r=n.options.labels;const o=t.length;const a=r.distance;let s=i.center.y-(i.radius+a)-t[0].box.height();let l;e[0]+=2;for(let n=0;n<o;n++){const o=t[n];const c=o.box;s+=e[n],l=this.hAlignLabel(c.x2,i.clone().expand(a),s,s+c.height(),o.orientation===IV),o.orientation===IV?(r.align!==cV&&(l=i.radius+i.center.x+a),o.reflow(new hU(l+c.width(),s,l,s))):(r.align!==cV&&(l=i.center.x-i.radius-a),o.reflow(new hU(l-c.width(),s,l,s))),s+=c.height()}}createVisual(){const{options:{connectors:e},points:t}=this;const n=t.length;super.createVisual(),this._connectorLines=[];for(let i=0;i<n;i++){const n=t[i];const{sector:r,label:o}=n;const a=r.middle();const s=(n.options.connectors||{}).color||e.color;if(o){const t=new Rs({stroke:{color:s,width:e.width},animation:{type:Sj,delay:n.animationDelay}});if(o.options.position===aG){const i=o.box;const s=r.center;let l=r.point(a);let c=new dU(i.x1,i.center().y);let d,h,u;l=r.clone().expand(e.padding).point(a),t.moveTo(l.x,l.y),o.orientation===IV?(h=new dU(i.x1-e.padding,i.center().y),u=tQ(s,l,c,h),c=new dU(h.x-4,h.y),u=u||c,u.x=Math.min(u.x,c.x),this.pointInCircle(u,r.center,r.radius+4)||u.x<r.center.x?(d=r.center.x+r.radius+4,n.options.labels.align!==Gj?d<c.x?t.lineTo(d,l.y):t.lineTo(l.x+8,l.y):t.lineTo(d,l.y),t.lineTo(c.x,h.y)):(u.y=h.y,t.lineTo(u.x,u.y))):(h=new dU(i.x2+e.padding,i.center().y),u=tQ(s,l,c,h),c=new dU(h.x+4,h.y),u=u||c,u.x=Math.max(u.x,c.x),this.pointInCircle(u,r.center,r.radius+4)||u.x>r.center.x?(d=r.center.x-r.radius-4,n.options.labels.align!==Gj?d>c.x?t.lineTo(d,l.y):t.lineTo(l.x-8,l.y):t.lineTo(d,l.y),t.lineTo(c.x,h.y)):(u.y=h.y,t.lineTo(u.x,u.y))),t.lineTo(h.x,h.y),this._connectorLines.push(t),this.visual.append(t)}}}}renderVisual(){if(super.renderVisual(),a$(this.options.series,(e=>e.autoFit))){const e=this.targetBox;const t=this.box.center();const n=this.visual.bbox();if(!n)return;const i=n.bottomRight();const r=Math.min((t.y-e.y1)/(t.y-n.origin.y),(e.y2-t.y)/(i.y-t.y),(t.x-e.x1)/(t.x-n.origin.x),(e.x2-t.x)/(i.x-t.x));r<1&&this.visual.transform(xa().scale(r,r,[t.x,t.y]))}}labelComparator(e){const t=e?-1:1;return function(e,n){return((e.parent.sector.middle()+270)%360-(n.parent.sector.middle()+270)%360)*t}}hAlignLabel(e,t,n,i,r){const{radius:o,center:{x:a,y:s}}=t;const l=Math.min(Math.abs(s-n),Math.abs(s-i));return l>o?e:a+Math.sqrt(o*o-l*l)*(r?1:-1)}pointInCircle(e,t,n){return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<Math.pow(n,2)}formatPointValue(e,t){return this.chartService.format.auto(t,e.value)}animationDelay(e){return 70*e}stackRoot(){return this}}function tQ(e,t,n,i){const r=(i.x-n.x)*(e.y-n.y)-(i.y-n.y)*(e.x-n.x);const o=(i.y-n.y)*(t.x-e.x)-(i.x-n.x)*(t.y-e.y);let a;if(0!==o){const n=r/o;a=new dU(e.x+n*(t.x-e.x),e.y+n*(t.y-e.y))}return a}XN(eQ,{startAngle:90,connectors:{width:2,color:"#939393",padding:8},inactiveItems:{markers:{},labels:{}}}),cN(eQ.prototype,JY),eQ.prototype.isStackRoot=!0;class nQ extends TK{render(){this.createPieChart(this.series)}createPieChart(e){const t=e[0];const n=new eQ(this,{series:e,padding:t.padding,startAngle:t.startAngle,connectors:t.connectors,legend:this.options.legend});this.appendChart(n)}appendChart(e,t){super.appendChart(e,t),LN(this.options.legend.data,e.legendItems)}getPointBelow(e){return this.getPointToTheRight(e)}getPointAbove(e){return this.getPointToTheLeft(e)}}class iQ extends YY{reflowLabel(){const{options:{labels:e},label:t}=this;const n=this.sector.clone();const i=n.middle();if(t){const r=t.box.height();if(e.position===lV){n.radius-=(n.radius-n.innerRadius)/2;const e=n.point(i);t.reflow(new hU(e.x,e.y-r/2,e.x,e.y))}else super.reflowLabel()}}createSegment(e,t){return gU.current.createRing(e,t)}}XN(iQ,{overlay:{gradient:"roundedGlass"},labels:{position:lV},animation:{type:tq}}),cN(iQ.prototype,HG);class rQ extends eQ{addValue(e,t,n){const i=cN({},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)return;const r=new iQ(e,t,i);Object.assign(r,n),this.append(r),this.points.push(r)}reflow(e){const t=this.options;const n=e.clone();const i=Math.min(n.width(),n.height());const r=i/2;const o=i-.85*i;const a=t.series;const s=a.length;let l=YN(t.padding,o);l=l>r-5?r-5:l;let c=r-l;let d=0;let h;for(let e=0;e<s;e++){const t=a[e];0===e&&HN(t.holeSize)&&(h=t.holeSize,c-=t.holeSize),HN(t.size)?c-=t.size:d++,HN(t.margin)&&e!==s-1&&(c-=t.margin)}if(!HN(h)){h=.75*((r-l)/(s+.75)),c-=h}let u=h;let p=0;let f,m;this.seriesConfigs=[];for(let e=0;e<s;e++){const t=a[e];f=YN(t.size,c/d),u+=p,m=u+f,this.seriesConfigs.push({innerRadius:u,radius:m}),p=t.margin||0,u=m}super.reflow(e)}animationDelay(e,t,n){return 50*e+Cj*(t+1)/(n+1)}}XN(rQ,{startAngle:90,connectors:{width:2,color:"#939393",padding:8}});class oQ extends nQ{render(){this.createDonutChart(this.series)}createDonutChart(e){const t=e[0];const n=new rQ(this,{series:e,padding:t.padding,connectors:t.connectors,legend:this.options.legend});this.appendChart(n)}getPointBelow(e){return this._getNextPoint(e,this._pointsByVertical,-1)}getPointAbove(e){return this._getNextPoint(e,this._pointsByVertical,1)}}class aQ extends TK{initFields(){this.valueAxisRangeTracker=new ZG}render(){this.addToLegend(this.series),this.createPolarAxis(),this.createCharts(),this.createValueAxis()}alignAxes(){const e=this.valueAxis;const t=e.range();const n=e.options.reverse?t.max:t.min;const i=e.getSlot(n);const r=this.polarAxis.getSlot(0).center;const o=e.box.translate(r.x-i.x1,r.y-i.y1);e.reflow(o)}createValueAxis(){const e=this.valueAxisRangeTracker.query();const t=this.valueAxisOptions({roundToMajorUnit:!1,zIndex:-1});let n,i;t.type===nG?(n=lj,i={min:.1,max:1}):(n=sj,i={min:0,max:1});const r=e||i;const o=new n(r.min,r.max,t,this.chartService);this.valueAxis=o,this.appendAxis(o)}reflowAxes(){const{options:{plotArea:e},valueAxis:t,polarAxis:n,box:i}=this;const r=.15*Math.min(i.width(),i.height());const o=mN(e.padding||{},r);const a=i.clone().unpad(o);const s=a.clone();s.y2=s.y1+Math.min(s.width(),s.height()),s.align(a,UV,lV);const l=s.clone().shrink(0,s.height()/2);n.reflow(s),t.reflow(l);const c=t.lineBox().height()-t.box.height();t.reflow(t.box.unpad({top:c})),this.axisBox=s,this.alignAxes(s)}backgroundBox(){return this.box}detachLabels(){}}class sQ extends pK{pointSlot(e,t){const n=e.center.y-t.y1;const i=dU.onCircle(e.center,e.startAngle,n);return new hU(i.x,i.y,i.x,i.y)}}XN(sQ,{clip:!1});class lQ extends FY{}lQ.prototype.pointSlot=sQ.prototype.pointSlot,XN(lQ,{clip:!1});class cQ extends QG{fillToAxes(e){const t=this._polarAxisCenter();e.lineTo(t.x,t.y)}_polarAxisCenter(){return this.parent.plotArea.polarAxis.box.center()}strokeSegments(){let e=this._strokeSegments;if(!e){const t=this._polarAxisCenter();const n=new cj(!1);const i=this.points();i.push(t),e=this._strokeSegments=n.process(i),e.pop()}return e}}class dQ extends KG{fillToAxes(e){const t=this.parent.plotArea.polarAxis.box.center();const n=new cs([t.x,t.y]);e.segments.unshift(n),e.segments.push(n)}}class hQ extends lQ{createSegment(e,t,n){let i;return i=(t.line||{}).style===Oj?new cQ(e,t,n):new dQ(e,t,n),i}createMissingValue(e,t){let n;return MG(e.x)&&t!==Bj&&(n={x:e.x,y:e.y},t===Lj&&(n.y=0)),n}seriesMissingValues(e){return e.missingValues||Lj}_hasMissingValuesGap(){const e=this.options.series;for(let t=0;t<e.length;t++)if(this.seriesMissingValues(e[t])===Hj)return!0}sortPoints(e){if(e.sort(uQ),this._hasMissingValuesGap())for(let t=0;t<e.length;t++){const n=e[t];if(n){MG(n.value.y)||this.seriesMissingValues(n.series)!==Hj||delete e[t]}}return e}}function uQ(e,t){return e.value.x-t.value.x}class pQ extends aQ{createPolarAxis(){const e=new rj(this.options.xAxis,this.chartService);this.polarAxis=e,this.axisX=e,this.appendAxis(e)}render(){this.series=[...this.originalSeries],this.createTrendlineSeries(),super.render()}valueAxisOptions(e){return cN(e,{majorGridLines:{type:JO},minorGridLines:{type:JO}},this.options.yAxis)}createValueAxis(){super.createValueAxis(),this.axisY=this.valueAxis}trendlineFactory(e,t){const n=GY.prototype.trendlineFactory.call(this,e,t);return n&&(n.type=iq),n}appendChart(e,t){this.valueAxisRangeTracker.update(e.yAxisRanges),TK.prototype.appendChart.call(this,e,t)}createCharts(){const e=this.filterVisibleSeries(this.series);const t=this.panes[0];this.createLineChart(xG(e,[iq]),t),this.createScatterChart(xG(e,[rq]),t),this.createAreaChart(xG(e,[nq]),t)}createLineChart(e,t){if(0===e.length)return;const n=new lQ(this,{series:e});this.appendChart(n,t)}createScatterChart(e,t){if(0===e.length)return;const n=new sQ(this,{series:e});this.appendChart(n,t)}createAreaChart(e,t){if(0===e.length)return;const n=new hQ(this,{series:e});this.appendChart(n,t)}_dispatchEvent(e,t,n){const i=e._eventCoordinates(t);const r=new dU(i.x,i.y);const o=this.axisX.getValue(r);const a=this.axisY.getValue(r);null!==o&&null!==a&&e.trigger(n,{element:NN(t),x:o,y:a})}createCrosshairs(){}}XN(pQ,{xAxis:{},yAxis:{}}),cN(pQ.prototype,IK,{seriesValues:GY.prototype.seriesValues});class fQ extends GG{pointSlot(e,t){const n=e.center.y-t.y1;const i=dU.onCircle(e.center,e.middle(),n);return new hU(i.x,i.y,i.x,i.y)}renderSegments(){if(super.renderSegments(),this._segments&&this._segments.length>1){const e=function(e){const t=[];for(let n=0;n<e.length;n++){const i=e[n];t[i.seriesIx]=t[i.seriesIx]||[],t[i.seriesIx].push(i)}return t}(this._segments);for(let t=0;t<e.length;t++){const n=e[t];if(n&&n.length>1){const e=n[0].linePoints[0];const t=UN(n);const i=UN(t.linePoints);const r=0===e.categoryIx;const o=i.categoryIx===i.categoriesCount-1;r&&o&&UN(n).linePoints.push(e)}}}}createSegment(e,t,n){let i;i=t.style===Oj?UG:OG;const r=new i(e,t,n);const o=this.seriesMissingValues(t);return e.length!==t.data.length&&o!==Bj||(r.options.closed=!0),r}}XN(fQ,{clip:!1,limitPoints:!1});class mQ extends QG{fillToAxes(){}}class gQ extends KG{fillToAxes(){}}class vQ extends fQ{createSegment(e,t,n,i){const r=this.options.isStacked;const o=(t.line||{}).style;let a;let s;let l;return r&&n>0&&i&&(s=i.linePoints.slice(0),a=i),o===Oj?(l=new mQ(e,t,n,a,s),l.options.closed=!0):(e.push(e[0]),l=new gQ(e,t,n,a,s)),l}seriesMissingValues(e){return e.missingValues||Lj}}class _Q extends iQ{constructor(e,t){super(e,null,t)}getIndex(){return this.categoryIx}}XN(_Q,{overlay:{gradient:"none"},labels:{distance:10}});class bQ extends vU{constructor(e){super(e),this.forEach=e.rtl?iK:nK}reflow(e){const{options:t,children:n}=this;const{gap:i,spacing:r}=t;const o=n.length;const a=o+i+r*(o-1);const s=e.angle/a;let l=e.startAngle+s*(i/2);this.forEach(n,(t=>{const 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}))}}XN(bQ,{gap:1,spacing:0});class wQ extends vU{reflow(e){const{options:{reverse:t},children:n}=this;const i=n.length;const r=t?i-1:0;const o=t?-1:1;this.box=new hU;for(let t=r;t>=0&&t<i;t+=o){const i=n[t].sector;i.startAngle=e.startAngle,i.angle=e.angle}}}class yQ extends aK{pointType(){return _Q}clusterType(){return bQ}stackType(){return wQ}categorySlot(e,t){return e.getSlot(t)}pointSlot(e,t){const n=e.clone();const i=e.center.y;return n.radius=i-t.y1,n.innerRadius=i-t.y2,n}reflowPoint(e,t){e.sector=t,e.reflow()}createAnimation(){this.options.animation.center=this.box.toRect().center(),super.createAnimation()}}yQ.prototype.reflow=BG.prototype.reflow,XN(yQ,{clip:!1,limitPoints:!1,animation:{type:"pie"}});class kQ extends aQ{createPolarAxis(){const e=new ij(this.options.categoryAxis,this.chartService);this.polarAxis=e,this.categoryAxis=e,this.appendAxis(e),this.aggregateCategories(),this.createTrendlineSeries(),this.createCategoryAxesLabels()}valueAxisOptions(e){return this._hasBarCharts&&cN(e,{majorGridLines:{type:JO},minorGridLines:{type:JO}}),this._isStacked100&&cN(e,{roundToMajorUnit:!1,labels:{format:"P0"}}),cN(e,this.options.valueAxis)}aggregateCategories(){cY.prototype.aggregateCategories.call(this,this.panes)}createCategoryAxesLabels(){cY.prototype.createCategoryAxesLabels.call(this,this.panes)}filterSeries(e){return e}trendlineFactory(e,t){const n=cY.prototype.trendlineFactory.call(this,e,t);return n&&(n.type=sq),n}createCharts(){const e=this.filterVisibleSeries(this.series);const t=this.panes[0];this.createAreaChart(xG(e,[oq]),t),this.createLineChart(xG(e,[sq]),t),this.createBarChart(xG(e,[aq]),t)}chartOptions(e){const t={series:e};const n=e[0];if(n){const i=this.filterVisibleSeries(e);const 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}createAreaChart(e,t){if(0===e.length)return;const n=new vQ(this,this.chartOptions(e));this.appendChart(n,t)}createLineChart(e,t){if(0===e.length)return;const n=new fQ(this,this.chartOptions(e));this.appendChart(n,t)}createBarChart(e,t){if(0===e.length)return;const n=e[0];const i=this.chartOptions(e);const r=this.filterVisibleSeries(e);const o=r.some((e=>e.stack));const a=r.some((e=>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;const s=new yQ(this,i);this.appendChart(s,t),this._hasBarCharts=!0}seriesCategoryAxis(){return this.categoryAxis}_dispatchEvent(e,t,n){const i=e._eventCoordinates(t);const r=new dU(i.x,i.y);const o=this.categoryAxis.getCategory(r);const a=this.valueAxis.getValue(r);null!==o&&null!==a&&e.trigger(n,{element:NN(t),category:o,value:a})}createCrosshairs(){}_pointsByVertical(e){return super._pointsByVertical(e).sort(this._getSeriesCompareFn())}_getSeriesCompareFn(){return(e,t)=>t.value-e.value}}cN(kQ.prototype,IK,{appendChart:cY.prototype.appendChart,aggregateSeries:cY.prototype.aggregateSeries,seriesSourcePoints:cY.prototype.seriesSourcePoints,seriesValues:cY.prototype.seriesValues}),XN(kQ,{categoryAxis:{categories:[]},valueAxis:{}});class xQ extends vU{constructor(e,t,n){super(t),this.value=e,this.options.index=n.index}getLabelText(e){let t=_N(e);return t?t(this.pointData()):e.format?this.formatValue(e.format):this.value}reflow(e){const t=this.points;const n=this.children[0];const i=Math.min(t[0].x,t[3].x);const r=Math.max(t[1].x,t[2].x);this.box=new hU(i,t[0].y,r,t[2].y),n&&n.reflow(new hU(e.x1,t[0].y,e.x2,t[2].y))}createVisual(){const e=this.options;let t;super.createVisual(),this.addAccessibilityAttributesToVisual(),t=e.visual?e.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,points:this.points,options:e,sender:this.getSender(),createVisual:()=>this.createPath()}):this.createPath(),t&&this.visual.append(t)}createPath(){const e=this.options;const t=e.border;return Rs.fromPoints(this.points,{fill:CU(e.pattern,{color:e.color,opacity:e.opacity}),stroke:{color:t.color,opacity:t.opacity,width:t.width}}).close()}createHighlight(e){return Rs.fromPoints(this.points,e)}highlightVisual(){return this.visual.children[0]}highlightVisualArgs(){const e=Rs.fromPoints(this.points).close();return{options:this.options,path:e}}createFocusHighlight(e){const t=this.options.focusHighlight.border.width;const n=Rs.fromPoints(this.points,cN({},e,{stroke:{width:2*t}})).close();const i=new Fs;return i.paths.push(Rs.fromRect(this.box.clone().pad(t).toRect())),i.paths.push(Rs.fromPoints(this.points)),n.clip(i),n}tooltipAnchor(){const e=this.box;return{point:new dU(e.center().x,e.y1),align:{horizontal:"center",vertical:"top"}}}formatValue(e){return this.owner.formatPointValue(this,e)}pointData(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}}getIndex(){return this.index}}XN(xQ,{color:VV,border:{width:1},labels:{format:""},accessibility:{role:Qq,className:Xq,ariaRoleDescription:Zq}}),cN(xQ.prototype,HG),cN(xQ.prototype,eK);class CQ extends vU{constructor(e,t){super(t),this.plotArea=e,this.chartService=e.chartService,this.points=[],this.labels=[],this.legendItems=[],this.render()}formatPointValue(e,t){return this.plotArea.chartService.format.auto(t,e.value)}render(){const{options:e,plotArea:{options:{seriesColors:t=[]}}}=this;const n=e.series[0];const i=n.data;if(!i)return;const{total:r,points:o}=bG(n);for(let e=0;e<o.length;e++){const a=o[e];if(!a)continue;let s=a.fields;aN(n.color)||(n.color=s.color||t[e%t.length]),s=cN({index:e,owner:this,series:n,seriesIx:0,dataItem:i[e],percentage:a.value/r},s,{visible:a.visible});const l=a.valueFields.value;const c=this.createSegment(l,s);const d=this.createLabel(l,s);c&&d&&c.append(d)}}evalSegmentOptions(e,t,n){const i=n.series;kG(e,{value:t,series:i,dataItem:n.dataItem,index:n.index},{defaults:i._defaults,excluded:["data","content","template","toggle","visual","ariaTemplate","ariaContent"]})}createSegment(e,t){const n=cN({},t.series);if(n.pattern=t.pattern||n.pattern,this.evalSegmentOptions(n,e,t),this.createLegendItem(e,n,t),!1!==t.visible){const i=new xQ(e,n,t);return Object.assign(i,t),this.append(i),this.points.push(i),i}}createLabel(e,t){const{series:n,dataItem:i}=t;const r=cN({},this.options.labels,n.labels);let o=e;if(r.visible){const a=_N(r);const 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=h$(n.color),r.background||(r.background=n.color)),this.evalSegmentOptions(r,e,t);const l=new RU(o,cN({vAlign:r.position},r),s);return this.labels.push(l),l}}labelPadding(){const e=this.labels;const t={left:0,right:0};for(let n=0;n<e.length;n++){const i=e[n].options.align;if(i!==lV){const r=e[n].box.width();i===kV?t.left=Math.max(t.left,r):t.right=Math.max(t.right,r)}}return t}dynamicSlopeReflow(e,t,n){const{options:i,points:r}=this;const o=r.length;const a=r[0];let s=a;for(let e=0;e<r.length;e++)r[e].percentage>s.percentage&&(s=r[e]);let l=a.percentage/s.percentage*t;let c=(t-l)/2;let d=0;for(let a=0;a<o;a++){const s=r[a].percentage;const h=r[a+1];const u=h?h.percentage:s;const p=r[a].points=[];const f=i.dynamicHeight?n*s:n/o;let m;m=s?(t-l*(u/s))/2:u?0:t/2,m=WN(m,0,t),p.push(new ba(e.x1+c,e.y1+d)),p.push(new ba(e.x1+t-c,e.y1+d)),p.push(new ba(e.x1+t-m,e.y1+f+d)),p.push(new ba(e.x1+m,e.y1+f+d)),c=m,d+=f+i.segmentSpacing,l=WN(t-2*m,0,t)}}constantSlopeReflow(e,t,n){const{options:i,points:r}=this;const o=r.length;const a=i.neckRatio<=1;const s=a?i.neckRatio*t:t;let l=a?0:(t-t/i.neckRatio)/2;const c=((a?t:t-2*l)-s)/2;let d=0;for(let a=0;a<o;a++){const s=r[a].points=[];const h=r[a].percentage;const u=i.dynamicHeight?c*h:c/o;const p=i.dynamicHeight?n*h:n/o;s.push(new ba(e.x1+l,e.y1+d)),s.push(new ba(e.x1+t-l,e.y1+d)),s.push(new ba(e.x1+t-l-u,e.y1+p+d)),s.push(new ba(e.x1+l+u,e.y1+p+d)),l+=u,d+=p+i.segmentSpacing}}reflow(e){const t=this.points;const n=t.length;if(!n)return;const i=this.options;const r=e.clone().unpad(this.labelPadding());const o=r.height()-i.segmentSpacing*(n-1);const a=r.width();i.dynamicSlope?this.dynamicSlopeReflow(r,a,o):this.constantSlopeReflow(r,a,o);for(let i=0;i<n;i++)t[i].reflow(e)}}XN(CQ,{neckRatio:.3,width:300,dynamicSlope:!1,dynamicHeight:!0,segmentSpacing:0,labels:{visible:!1,align:lV,position:lV,zIndex:1}}),cN(CQ.prototype,JY);class SQ extends CQ{constructor(e,t){t.dynamicSlope=!1,t.neckRatio=1e6,super(e,t)}}class TQ extends vU{constructor(e,t){super(),this.options=t,this.color=t.color||VV,this.value=e}render(){this._rendered||(this._rendered=!0,this.createMarker(),this.createLabel(),this.createNote())}createLabel(){const e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))}createLabelElement(e){let t=e.color;return t||(t=h$(this.color)),new RU(this.getLabelText(e),cN({align:lV,vAlign:lV,margin:{left:5,right:5},zIndex:YN(e.zIndex,this.series.zIndex)},e,{color:t}),this.pointData())}getLabelText(e){let t=_N(e);return t?t(this.pointData()):this.formatValue(e.format)}formatValue(e){return this.owner.formatPointValue(this,e)}reflow(e){this.render();const t=this.label;this.box=e,t&&t.reflow(this.markerBox()),this.note&&this.note.reflow(e),this.marker.reflow(this.markerBox())}createVisual(){super.createVisual(),this.addAccessibilityAttributesToVisual()}markerBox(){const e=this.options.markers;const t=e.border;const n=this.box.toRect();const i=YN(e.type,"rect")===zV;let r=YN(t.width,i?1:0);const o=Math.round(r/2);if(e.size){const t=n.center();n.size.width=n.size.height=e.size,n.origin.x=Math.round(t.x-n.size.width/2),n.origin.y=Math.round(t.y-n.size.height/2)}return n.size.width-=r,n.size.height-=r,n.origin.y+=o+.5,n.origin.x+=o+.5,BU(n)}markerBorder(){const e=this.options;const t=e.markers.border;const n=YN(t.opacity,e.opacity);return{color:t.color||this.color,width:t.width,opacity:n,dashType:t.dashType}}createMarker(){const e=this.options;const t=e.markers;const n=new MU({type:YN(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:YN(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)}createHighlight(e){const t=this.options;const n=this.options.highlight.markers||this.options.markers;const i=new MU({type:YN(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:YN(t.zIndex,this.series.zIndex)});i.reflow(this.markerBox());const r=i.getElement();return r.options.fill=e.fill,r.options.stroke=e.stroke,r}highlightVisual(){return this.rectVisual}highlightVisualArgs(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}}createFocusHighlight(){const e=this.options.markers;const t=this.options.focusHighlight;const n=new MU({type:YN(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()}tooltipAnchor(){const e=this.box.center().x;const t=this.box.y1-5;return{point:new dU(e,t),align:{horizontal:lV,vertical:sV}}}overlapsBox(e){return this.box.overlaps(e)}unclipElements(){}pointData(){return{x:this.value.x,y:this.value.y,value:this.value.value,dataItem:this.dataItem,series:this.series}}}cN(TQ.prototype,HG),cN(TQ.prototype,RG),cN(TQ.prototype,eK),TQ.prototype.defaults={markers:{type:"rect",borderRadius:4,border:{color:"transparent"}},padding:{top:1},labels:{visible:!1,padding:3},opacity:1,notes:{label:{}},accessibility:{role:Qq,className:Xq,ariaRoleDescription:Zq}};class MQ extends vU{constructor(e,t){super(t),this.plotArea=e,this.chartService=e.chartService,this._initFields(),this.render()}_initFields(){this.points=[],this.seriesOptions=[],this.valueRange={min:xV,max:CV},this._evalSeries=[]}render(){this.setRange(),this.traverseDataPoints(this.addValue.bind(this))}setRange(){const{options:{series:e}}=this;for(let t=0;t<e.length;t++){const n=e[t];for(let e=0;e<n.data.length;e++){const{valueFields:t}=this.plotArea.bindPoint(n,e);HN(t.value)&&null!==t.value&&(this.valueRange.min=Math.min(this.valueRange.min,t.value),this.valueRange.max=Math.max(this.valueRange.max,t.value))}}}addValue(e,t){let n;e&&HN(e.value)&&null!==e.value&&(n=this.createPoint(e,t),n&&Object.assign(n,t)),this.points.push(n)}evalPointOptions(e,t,n){const{series:i,seriesIx:r}=n;const o={defaults:i._defaults,excluded:["data","tooltip","content","template","visual","toggle","drilldownSeriesFactory","ariaTemplate","ariaContent"]};let a=this._evalSeries[r];HN(a)||(this._evalSeries[r]=a=kG(e,{},o,!0));let s=e;return a&&(s=cN({},e),kG(s,{value:t,series:i,dataItem:n.dataItem,min:this.valueRange.min,max:this.valueRange.max},o)),s}pointType(){return TQ}pointOptions(e,t){let n=this.seriesOptions[t];if(!n){const i=this.pointType().prototype.defaults;this.seriesOptions[t]=n=cN({},i,{markers:{opacity:e.opacity},tooltip:{format:this.options.tooltip.format},labels:{format:this.options.labels.format}},e)}return Object.assign({},n)}createPoint(e,t){const n=t.series;let i=this.pointOptions(n,t.seriesIx);let r=t.color||n.color;if(i.pattern=t.pattern||i.pattern,i=this.evalPointOptions(i,e,t),aN(n.color))r=i.color;else if(0!==this.valueRange.max){const t=((e,t=.05)=>{const n=_o(e);const i=1-t;return e=>{const t=n.toHSL();const r=100-t.l;const o=i-e;return t.l+=Math.min(o*r,r),t.toCss()}})(r);r=t(e.value/this.valueRange.max)}const o=new TQ(e,i);return o.color=r,this.append(o),o}seriesAxes(e){const{xAxis:t,yAxis:n}=e;const i=this.plotArea;const r=t?i.namedXAxes[t]:i.axisX;const 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}}reflow(e){const t=this.points;const n=!this.options.clip;let i=0;this.traverseDataPoints(((e,r)=>{const o=t[i++];const{xAxis:a,yAxis:s}=this.seriesAxes(r.series);const l=a.categoryIndex(e.x);const c=s.categoryIndex(e.y);const d=a.getSlot(l,l,n);const h=s.getSlot(c,c,n);if(o)if(d&&h){const e=this.pointSlot(d,h);o.reflow(e)}else o.visible=!1})),this.box=e}pointSlot(e,t){return new hU(e.x1,t.y1,e.x2,t.y2)}traverseDataPoints(e){const{options:{series:t}}=this;for(let n=0;n<t.length;n++){const i=t[n];const{xAxis:r,yAxis:o}=this.seriesAxes(i);const a=r.currentRangeIndices();const s=o.currentRangeIndices();for(let t=0;t<i.data.length;t++){const{valueFields:l,fields:c}=this.plotArea.bindPoint(i,t);const d=r.totalIndex(l.x);const h=o.totalIndex(l.y);const u=a.min<=d&&d<=a.max;const p=s.min<=h&&h<=s.max;u&&p&&e(l,cN({pointIx:t,series:i,seriesIx:n,dataItem:i.data[t],owner:this},c))}}}formatPointValue(e,t){const n=e.value;return this.chartService.format.auto(t,n.x,n.y,n.value)}animationPoints(){const e=this.points;const t=[];for(let n=0;n<e.length;n++)t.push((e[n]||{}).marker);return t}}XN(MQ,{series:[],tooltip:{format:"{0}, {1}: {2}"},labels:{format:"{2}"},clip:!0});class AQ extends TK{initFields(){this.namedXAxes={},this.namedYAxes={}}render(e=this.panes){this.bindCategories(),this.createAxes(e),this.createCharts(e),this.createAxisLabels()}bindCategories(){const e=this.srcSeries||this.series;for(let t=0;t<e.length;t++){const n=e[t];const i=n.data||[];const{xAxis:r,yAxis:o}=this.seriesAxes(n);const a=m$(r.categories||[]);const s=m$(o.categories||[]);for(let e=0;e<i.length;e++){const{x:t,y:i}=bj.current.bindPoint(n,e).valueFields;a.has(t)||a.add(t),s.has(i)||s.add(i)}r.categories=a.values(),o.categories=s.values()}}createCharts(e){const t=this.groupSeriesByPane();for(let n=0;n<e.length;n++){const i=e[n];const r=t[i.options.name||"default"]||[];this.addToLegend(r);const o=this.filterVisibleSeries(r);o&&this.createHeatmapChart(xG(o,[Xj]),i)}}createHeatmapChart(e,t){const n=new MQ(this,{series:e});this.appendChart(n,t)}seriesPaneName(e){const t=this.options;const n=e.xAxis;const i=[].concat(t.xAxis);const r=xN(i,(function(e){return e.name===n}))[0];const o=e.yAxis;const a=[].concat(t.yAxis);const s=xN(a,(function(e){return e.name===o}))[0];const l=(t.panes||[{}])[0].name||"default";return(r||{}).pane||(s||{}).pane||l}seriesAxes(e){let t;let n;const i=this.options;const r=[].concat(i.xAxis);const o=e.xAxis;t=o?r.find((e=>e.name===o)):r[0];const a=[].concat(i.yAxis);const s=e.yAxis;if(n=s?a.find((e=>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}}createAxisLabels(){const e=this.axes;for(let t=0;t<e.length;t++)e[t].createLabels()}createXYAxis(e,t,n){const i=e.name;const r=t?this.namedYAxes:this.namedXAxes;const o=Object.assign({axisCrossingValue:0},e,{vertical:t,reverse:t||this.chartService.rtl?!e.reverse:e.reverse,justified:!1});const a=o.categories?o.categories[0]:null;const s=[o.min,o.max,a];const l=this.series;for(let e=0;e<l.length;e++){const i=l[e];const r=i[t?"yAxis":"xAxis"];if(r===o.name||0===n&&!r){const e=bj.current.bindPoint(i,0).valueFields;s.push(e[t?"y":"x"]);break}}let c;for(let e=0;e<s.length;e++)if(s[e]instanceof Date){c=!0;break}let d;d=yG(o.type,hV)||!o.type&&c?WW:LW;const h=new d(o,this.chartService);if(h.axisIndex=n,i){if(r[i])throw new Error(`${t?"Y":"X"} axis with name ${i} is already defined`);r[i]=h}return this.appendAxis(h),h.indexCategories(),h}createAxes(e){const t=this.options;const n=[].concat(t.xAxis);const i=[];const r=[].concat(t.yAxis);const o=[];for(let t=0;t<n.length;t++){TN(this.findPane(n[t].pane),e)&&i.push(this.createXYAxis(n[t],!1,t))}for(let t=0;t<r.length;t++){TN(this.findPane(r[t].pane),e)&&o.push(this.createXYAxis(r[t],!0,t))}this.axisX=this.axisX||i[0],this.axisY=this.axisY||o[0]}removeAxis(e){const t=e.options.name;super.removeAxis(e),e.options.vertical?delete this.namedYAxes[t]:delete this.namedXAxes[t],e===this.axisX&&delete this.axisX,e===this.axisY&&delete this.axisY}_dispatchEvent(e,t,n){const i=e._eventCoordinates(t);const r=new dU(i.x,i.y);const o=this.axes;const a=o.length;const s=[];const l=[];for(let e=0;e<a;e++){const t=o[e];gG(t.options.vertical?l:s,t.getCategory(r))}s.length>0&&l.length>0&&e.trigger(n,{element:NN(t),originalEvent:t,x:DG(s),y:DG(l)})}updateAxisOptions(e,t){const n=e.options.vertical;const i=this.groupAxes(this.panes);const r=(n?i.y:i.x).indexOf(e);EQ(this.options,r,n,t),EQ(this.originalOptions,r,n,t)}crosshairOptions(e){return Object.assign({},e.options.crosshair,{zIndex:0})}_pointsByVertical(e,t=0){const n=this.axisX.options.reverse?-1*t:t;const i=this.axisX.children;let r=this._getPointAxisXIndex(e)+n;r=oN(r,i.length);const o=i[r].value;const a=this.filterPoints((e=>DQ(e.pointData().x,o))).sort(((e,t)=>this._getPointAxisYIndex(e)-this._getPointAxisYIndex(t)));return this.axisY.options.reverse?a.reverse():a}_pointsByHorizontal(e,t=0){const n=this.axisY.options.reverse?-1*t:t;const i=this.axisY.children;let r=this._getPointAxisYIndex(e)+n;r=oN(r,i.length);const o=i[r].value;const a=this.filterPoints((e=>DQ(e.pointData().y,o))).sort(((e,t)=>this._getPointAxisXIndex(e)-this._getPointAxisXIndex(t)));return this.axisX.options.reverse?a.reverse():a}_getPointAxisXIndex(e){return this._getPointAxisIndex(this.axisX,e.pointData().x)}_getPointAxisYIndex(e){return this._getPointAxisIndex(this.axisY,e.pointData().y)}_getPointAxisIndex(e,t){return e.children.findIndex((e=>DQ(t,e.value)))}}function DQ(e,t){return e instanceof Date&&t instanceof Date?MW(e,t):e===t}function EQ(e,t,n,i){cN([].concat(n?e.yAxis:e.xAxis)[t],i)}XN(AQ,{xAxis:{},yAxis:{}}),cN(AQ.prototype,IK);const IQ="color";const zQ="first";const PQ="max";const LQ="min";const BQ="noteText";AY.current.register(cY,[$j,Gj,Jj,gq,Nj,pq,qj,eq,jj,mq,Uj,fq,dq,cq,_q,Zj,lq,vq,...Tq]),AY.current.register(GY,[hq,uq,Wj,...Tq]),AY.current.register(nQ,[tq]),AY.current.register(oQ,[Kj]),AY.current.register(class extends TK{render(){this.createChart(CQ,xG(this.series,[Yj])),this.createChart(SQ,xG(this.series,[Qj]))}createChart(e,t){const n=t[0];if(!n)return;const 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)}appendChart(e,t){super.appendChart(e,t),LN(this.options.legend.data,e.legendItems)}_pointsByVertical(e){return this.pointsBySeriesIndex(e.series.index)}getPointToTheRight(e){return this.getPointBelow(e)}getPointToTheLeft(e){return this.getPointAbove(e)}},[Yj,Qj]),AY.current.register(pQ,[nq,iq,rq,...Tq]),AY.current.register(kQ,[oq,aq,sq,...Tq]),AY.current.register(AQ,[Xj]),bj.current.register([$j,Gj,Jj,gq,Nj,pq],[OV],[iG,IQ,BQ,Aj,Dj,dG,hG]),bj.current.register([dq,cq,lq,vq],["from","to"],[iG,IQ,BQ,dG,hG]),bj.current.register([_q,Zj],[OV],[iG,IQ,BQ,"summary",dG,hG]),bj.current.register([nq,iq,rq],[$V,UV],[IQ,dG,hG]),bj.current.register([oq,aq,sq],[OV],[iG,IQ,dG,hG]),bj.current.register([Yj,Qj],[OV],[iG,IQ,"visibleInLegend","visible",dG,hG]),LK.current.register([$j,Gj,Jj,gq,Nj,pq,_q,Zj],{value:PQ,color:zQ,noteText:zQ,errorLow:LQ,errorHigh:PQ}),LK.current.register([dq,cq,lq,vq],{from:LQ,to:PQ,color:zQ,noteText:zQ}),LK.current.register([oq,aq,sq],{value:PQ,color:zQ}),bj.current.register([hq,uq,Wj],[$V,UV],[IQ,BQ,Ej,Ij,zj,Pj]),bj.current.register([Wj],[$V,UV,"size"],[IQ,iG,BQ,hG]),bj.current.register([Xj],[$V,UV,OV],[IQ,BQ,hG]),bj.current.register([qj,eq],["open","high","low","close"],[iG,IQ,"downColor",BQ,hG]),LK.current.register([qj,eq],{open:PQ,high:PQ,low:LQ,close:PQ,color:zQ,downColor:zQ,noteText:zQ}),bj.current.register([Uj,fq],["lower","q1","median","q3","upper","mean","outliers"],[iG,IQ,BQ,dG,hG]),LK.current.register([Uj,fq],{lower:PQ,q1:PQ,median:PQ,q3:PQ,upper:PQ,mean:PQ,outliers:zQ,color:zQ,noteText:zQ}),bj.current.register([jj,mq],["current","target"],[iG,IQ,"visibleInLegend",BQ,dG,hG]),LK.current.register([jj,mq],{current:PQ,target:PQ,color:zQ,noteText:zQ}),bj.current.register([tq,Kj],[OV],[iG,IQ,"explode","visibleInLegend","visible",dG,hG]);const HQ=[iG,OV,$V,UV];const RQ="mousedown";const FQ="mousemove";const OQ="contextmenu";const VQ="mouseleave";const NQ="keydown";const $Q="focus";const UQ="blur";const WQ="k-chart-overlay-top";let jQ=class{constructor(e,t,n,i={}){this.observers=[],this.addObserver(i.observer),this.chartService=new GU(this,i),this.chartService.theme=n,this._initElement(e);const r=cN({},this.options,t);this._originalOptions=cN({},r),this._theme=n,this._initTheme(r,n),this._focusState={},this._initHandlers(),this._createSurface=i.createSurface||Fc.create.bind(Fc),this._initSurface(),this.bindCategories(),QN.preloadFonts(t,(()=>{this.fontLoaded=!0,this._destroyed||(this.trigger("init"),this._redraw(),this._attachEvents(),this._restoreOverlayElement())}))}_initElement(e){this._setElementClass(e),e.style.position="relative",e.tabIndex=e.getAttribute("tabindex")?e.getAttribute("tabindex"):0,e.setAttribute("role","graphics-document document");for(let t=e.childNodes.length-1;t>=0;t--){const n=e.childNodes[t];CN(n,"k-chart-overlay")?this.overlayElement=n:e.removeChild(n)}this.element=e}_setElementClass(e){YV(e,"k-chart")}_restoreOverlayElement(){this.overlayElement&&(this._hasSeriesData()?this.overlayElement.style.display="none":(!this.options.title||this.options.title&&this.options.title.position!==sV?YV(this.overlayElement,WQ):XV(this.overlayElement,WQ),this.overlayElement.style.display=""),this.overlayElement.parentElement!==this.element&&this.element.appendChild(this.overlayElement))}_hasSeriesData(){const e=this.options.series||[];const t=e.length>0&&e.some((e=>e.data&&e.data.length>0));return t}_initTheme(e,t){const n=[];const i=e.series||[];for(let e=0;e<i.length;e++)n.push(Object.assign({},i[e]));e.series=n,function(e){const t=HQ;for(let n=0;n<t.length;n++){const 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,tN(e.title)&&(e.title={text:e.title}),this.options=cN({},t,e),this.applySeriesColors()}getSize(){const 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)}}resize(e){const t=this.getSize();const n=this._size;const 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&&a$(this._selections,(e=>!e.visible))&&(this._destroySelections(),this._setupSelection())}_resize(){this._noTransitionsRedraw()}redraw(e){if(this.applyDefaults(this.options),this.applySeriesColors(),e){const t=this._model._plotArea;const n=t.findPane(e);t.redraw(n)}else this._redraw()}getAxis(e){return pj(e,this._plotArea.axes)}findAxisByName(e){return this.getAxis(e)}findPaneByName(e){const t=this._plotArea.panes;for(let n=0;n<t.length;n++)if(t[n].options.name===e)return new fj(t[n])}findPaneByIndex(e){const t=this._plotArea.panes;if(t[e])return new fj(t[e])}plotArea(){return new mj(this._plotArea)}toggleHighlight(e,t){const n=this._plotArea;const i=(n.srcSeries||n.series||[])[0];let r;if(aN(t))r=n.filterPoints(t);else{let e,o;dN(t)?(e=t.series,o=t.category):e=o=t,r=i.type===Kj?qQ(n.pointsBySeriesName(e),o):TN(i.type,[tq,Yj,Qj])?qQ((n.charts[0]||{}).points,o):n.pointsBySeriesName(e)}r&&this.togglePointsHighlight(e,r)}togglePointsHighlight(e,t){const n=this._highlight;for(let i=0;i<t.length;i++)n.togglePointHighlight(t[i],e)}showTooltip(e){const t=this._sharedTooltip();const{_tooltip:n,_plotArea:i}=this;let r,o;if(aN(e)?(r=i.findPoint(e),r&&t&&(o=r.categoryIx)):t&&HN(e)&&(o=i.categoryAxis.categoryIndex(e)),t){if(o>=0){const e=this._plotArea.pointsByCategoryIndex(o);n.showAt(e)}}else r&&n.show(r)}hideTooltip(){this._tooltip.hide()}_initSurface(){const e=this.surface;const t=this._surfaceWrap();const n=this.options.chartArea||{};n.width&&ON(t,{width:n.width}),n.height&&ON(t,{height:n.height}),e&&e.options.type===this.options.renderAs?(this.surface.clear(),this.surface.resize()):(this._destroySurface(),this.surface=this._createSurface(t,{type:this.options.renderAs}),this.surface.bind("mouseenter",this._surfaceMouseenterHandler),this.surface.bind("mouseleave",this._surfaceMouseleaveHandler)),this.element._kendoExportVisual=this._kendoExportVisual.bind(this)}_surfaceWrap(){return this.element}_redraw(){const 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();const t=this.options.transitions;!1!==t&&e.traverse((function(e){if(e.animation){const n=t&&!0!==t?t.loading:t;e.animation.options=Object.assign({},e.animation.options,n),e.animation.setup()}})),this._initSurface(),this.surface.draw(e.visual),!1!==t&&e.traverse((function(e){e.animation&&e.animation.play()})),this._tooltip=this._createTooltip(),this._highlight=new uY,this._setupSelection(),this._createPannable(),this._createZoomSelection(),this._createMousewheelZoom(),this._setComputedStyles(),this.trigger(qq),XQ(this._plotArea.panes),this._navState||this._cancelDomEvents(),this._redrawFocusHighlight()}_setComputedStyles(){const e=this.titleHeight();this.element.style.setProperty("--kendo-chart-computed-title-height",`${e}px`)}_redrawFocusHighlight(){if(this._destroyed)return;const{_focusState:{legendInFocus:e,preserveHighlight:t}}=this;e&&t&&(this._focusElement(this._getFocusedLegendItem(),!1),this._focusState.preserveHighlight=!1)}_setElementAccessibilityAttributes(){let e=this.options.title;let t=tN(e)?e:e.description||e.text;t&&this.element.setAttribute("aria-roledescription",t)}_kendoExportVisual(e){if(e&&e.width&&e.height){const t=this._originalOptions.chartArea||{};const n={width:t.width||e.width,height:t.height||e.height};return this.exportVisual(n)}return this.exportVisual()}exportVisual(e){let t;if(e&&(e.width||e.height||e.options)){const n=this.options;const i=cN({},e.options,{chartArea:{width:e.width,height:e.height}});QQ(this._originalOptions,i),this.options=cN({},this._originalOptions,i),this._initTheme(this.options,this._theme),this.bindCategories();const r=this._getModel();r.renderVisual(),XQ(r._plotArea.panes),t=r.visual,this.options=n}else t=this.surface.exportVisual();return t}_sharedTooltip(){return this._plotArea instanceof cY&&this.options.tooltip&&this.options.tooltip.shared}_createPannable(){const e=this.options;!1!==e.pannable&&(this._pannable=new gY(this._plotArea,e.pannable))}_createZoomSelection(){const e=this.options.zoomable;const t=(e||{}).selection;!1!==e&&!1!==t&&(this._zoomSelection=new vY(this,t))}_createMousewheelZoom(){const e=this.options.zoomable;const t=(e||{}).mousewheel;!1!==e&&!1!==t&&(this._mousewheelZoom=new _Y(this,t))}_toggleDragZoomEvents(){const e=this.options.pannable;const t=this.options.zoomable;const n=(t||{}).selection;const i=(t||{}).mousewheel;const r=!(e||!1!==t&&!1!==n||this.requiresHandlers([Oq,Rq,Fq]));const o=(!1===t||!1===i)&&!this.requiresHandlers([Vq,Nq,$q]);const 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)}_toggleDomEvents(e,t){const n=this.domEvents;n&&(n.toggleDrag&&n.toggleDrag(e),n.toggleZoom&&n.toggleZoom(t))}_createTooltip(){const{options:{tooltip:e}}=this;let t;return t=this._sharedTooltip()?this._createSharedTooltip(e):new zY(this.chartService,e),t}_createSharedTooltip(e){return new PY(this._plotArea,e)}applyDefaults(e,t){!function(e,t){const n=(t||{}).axisDefaults||{};let i,r,o;function a(e){const t=(e||{}).color||r.color;const o=cN({},n,n[i],r,r[i],{line:{color:t},labels:{color:t},title:{color:t}},e);return delete o[i],o}for(let t=0;t<HQ.length;t++)i=HQ[t]+"Axis",r=e.axisDefaults||{},o=[].concat(e[i]),o=o.map(a),e[i]=o.length>1?o:o[0]}(e,t),function(e,t){const n=e.series;const i=n.length;const r=e.seriesDefaults;const o=cN({},e.seriesDefaults);const a=t?cN({},t.seriesDefaults):{};const s=cN({},a);GQ(o),GQ(s);for(let t=0;t<i;t++){const i=n[t].type||e.seriesDefaults.type;const l=cN({data:[]},s,a[i],{tooltip:e.tooltip},o,r[i]);n[t]._defaults=l,n[t]=cN({},l,n[t]),n[t].data=n[t].data||[]}}(e,t)}applySeriesColors(){const e=this.options;const t=e.series;const n=e.seriesColors||[];for(let e=0;e<t.length;e++){const i=t[e];const r=n[e%n.length];const o=i._defaults;i.color=i.color||r,o&&(o.color=o.color||r)}}_getModel(){const e=this.options;const t=this._createPlotArea();const n=new IU(this._modelOptions());n.chart=this,n._plotArea=t;const i=FU.buildTitle(e.title);const r=FU.buildTitle(e.subtitle,{align:e.title.align,position:e.title.position});if(n.append.apply(n,FU.orderTitles([i,r])),e.legend&&e.legend.visible){const e=new MY(t.options.legend,this.chartService);n.append(e),n._legend=e}return n.append(t),n.reflow(),this._setTitleBox(i,r),n}_setTitleBox(e,t){if(!e&&!t)return;this._titleBox=(e||t).box.clone();const n=e?e.options.position:"";const i=t?t.options.position:"";const r=i!==sV;n===i&&t?this._titleBox.wrap(t.box):e&&t&&r&&(this._titleBox=t.box.clone())}_modelOptions(){const e=this.options;const t=this.getSize();return cN({transitions:e.transitions,width:t.width||fV,height:t.height||400},e.chartArea)}_createPlotArea(e){const t=this.options;return AY.current.create(e?[]:t.series,t,this.chartService)}_setupSelection(){const{_plotArea:{axes:e}}=this;const t=this._selections=[];for(let n=0;n<e.length;n++){const i=e[n];const r=i.options;if(i instanceof LW&&r.select&&!r.vertical){const e=i.range();const n=new IY(this,i,cN({min:e.min,max:e.max},r.select));t.push(n)}}}_selectStart(e){return this.trigger(Uq,e)}_select(e){return this.trigger(Wq,e)}_selectEnd(e){return this.trigger(jq,e)}_initHandlers(){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._mousemoveThrottled=oo(this._mousemove.bind(this),20)}addObserver(e){e&&this.observers.push(e)}removeObserver(e){const t=this.observers.indexOf(e);t>=0&&this.observers.splice(t,1)}requiresHandlers(e){const t=this.observers;for(let n=0;n<t.length;n++)if(t[n].requiresHandlers(e))return!0}trigger(e,t={}){t.sender=this,e===Gq?t.anchor.point=this._toDocumentCoordinates(t.anchor.point):e===zq?this._updateDrilldownPoint(t.point):e===Pq?this._resetDrilldownPoint():e===Eq?(this._focusPoint(t.point),this._startDrilldown(t.point)):e===Mq&&this._focusLegendItem(t);const n=this.observers;let i=!1;for(let r=0;r<n.length;r++)n[r].trigger(e,t)&&(i=!0);return i}titleHeight(){return this._titleBox?this._titleBox.height():0}_attachEvents(){const e=this.element;this._touchAction=e.style.touchAction,BN(e,{[OQ]:this._clickHandler,[sG]:this._mousewheelHandler,[VQ]:this._mouseleaveHandler,[NQ]:this._keydownHandler,[RQ]:this._mousedownHandler,[$Q]:this._focusHandler,[UQ]:this._blurHandler}),this._shouldAttachMouseMove()&&BN(e,{[FQ]:this._mousemoveThrottled}),this.domEvents=YU.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()}_mouseleave(e){this._hoveredPoint&&(this._hoveredPoint.out(this,e),this._hoveredPoint=null),this._plotAreaHovered&&(this._plotAreaHovered=!1,this.trigger(Hq)),this._hasInactiveOpacity()&&this._activeChartInstance&&(this._applySeriesOpacity(this._activeChartInstance.children,null,!0),this._updateSeriesOpacity(null,!0))}_cancelDomEvents(){this.domEvents&&this.domEvents.cancel&&this.domEvents.cancel()}_gesturestart(e){this._mousewheelZoom&&!this._stopChartHandlers(e)&&(this._gestureDistance=e.distance,this._unsetActivePoint(),this._clearFocusedElement(),this.surface.suspendTracking())}_gestureend(e){this._zooming&&!this._stopChartHandlers(e)&&(this.surface&&this.surface.resumeTracking(),this._zooming=!1,this.trigger($q,{}))}_gesturechange(e){const t=this._mousewheelZoom;if(t&&!this._stopChartHandlers(e)){e.preventDefault();const n=this._gestureDistance;let i=-e.distance/n+1;if(Math.abs(i)>=.1){i=Math.round(10*i),this._gestureDistance=e.distance;const n={delta:i,axisRanges:KQ(this._plotArea.axes),originalEvent:e};if(this._zooming||!this.trigger(Vq,n)){const r=this._eventCoordinates(e);this._zooming||(this._zooming=!0);(n.axisRanges=t.updateRanges(i,r))&&!this.trigger(Nq,n)&&t.zoom()}}}}_mouseout(e){if(e.element){const t=this._drawingChartElement(e.element,e);t&&t.leave&&t.leave(this,e.originalEvent)}}_start(e){const t=this._eventCoordinates(e);!this._stopChartHandlers(e)&&this._plotArea.backgroundContainsPoint(t)&&(this.requiresHandlers([Oq,Rq,Fq])&&this._startNavigation(e,t,Oq),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(Vq,{axisRanges:KQ(this._plotArea.axes),originalEvent:e}))}_move(e){let{_navState:t,_pannable:n}=this;if(!this._stopChartHandlers(e)){if(n){const t=n.move(e);t&&!this.trigger(Rq,{axisRanges:t,originalEvent:e})&&n.pan()}else if(t){const n={};const i=t.axes;for(let t=0;t<i.length;t++){const r=i[t];if(r.options.name){const t=r.options.vertical?e.y:e.x;const i=t.startLocation-t.location;0!==i&&(n[r.options.name]=r.translateRange(i))}}t.axisRanges=n,this.trigger(Rq,{axisRanges:n,originalEvent:e})}this._zoomSelection&&this._zoomSelection.move(e)}}_end(e){if(this._stopChartHandlers(e))return;const t=this._pannable;if(t&&t.end(e)?(this.surface.resumeTracking(),this.trigger(Fq,{axisRanges:KQ(this._plotArea.axes),originalEvent:e}),this._suppressHover=!1,this.chartService.panning=!1):this._endNavigation(e,Fq),this._zoomSelection){const t=this._zoomSelection.end(e);t&&!this.trigger(Nq,{axisRanges:t,originalEvent:e})&&(this._zoomSelection.zoom(),this.trigger($q,{axisRanges:t,originalEvent:e}))}}_stopChartHandlers(e){const t=this._selections||[];if(!t.length)return!1;const n=this._eventCoordinates(e);const i=this._plotArea.paneByPoint(n);if(i)for(let e=0;e<t.length;e++)if(t[e].onPane(i))return!0}_mousewheelZoomRate(){const e=(this.options.zoomable||{}).mousewheel||{};return YN(e.rate,.3)}_mousewheel(e){const t=PN(e);const n=this._mousewheelZoom;const i=this._eventCoordinates(e);if(!this._stopChartHandlers(e)&&this._plotArea.backgroundContainsPoint(i))if(n){const r={delta:t,axisRanges:KQ(this._plotArea.axes),originalEvent:e};!this._zooming&&this.trigger(Vq,r)||(e.preventDefault(),this._zooming||(this._unsetActivePoint(),this._clearFocusedElement(),this.surface.suspendTracking(),this._zooming=!0),this._mwTimeout&&clearTimeout(this._mwTimeout),r.axisRanges=n.updateRanges(t,i),r.axisRanges&&!this.trigger(Nq,r)&&n.zoom(),this._mwTimeout=setTimeout((()=>{this.trigger($q,r),this._zooming=!1,this.surface&&this.surface.resumeTracking()}),lG))}else{let n=this._navState;if(!n){this._startNavigation(e,i,Vq)||(n=this._navState)}if(n){const r=n.totalDelta||t;n.totalDelta=r+t;const o=this._navState.axes;const a={};for(let e=0;e<o.length;e++){const t=o[e];const n=t.options.name;n&&(a[n]=t.scaleRange(-r*this._mousewheelZoomRate(),i))}this.trigger(Nq,{delta:t,axisRanges:a,originalEvent:e}),this._mwTimeout&&clearTimeout(this._mwTimeout),this._mwTimeout=setTimeout((()=>{this._endNavigation(e,$q)}),lG)}}}_startNavigation(e,t,n){const i=this._model._plotArea;const r=i.findPointPane(t);const o=i.axes.slice(0);if(!r)return;const a=KQ(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})}_endNavigation(e,t){this._navState&&(this.trigger(t,{axisRanges:this._navState.axisRanges,originalEvent:e}),this._suppressHover=!1,this._navState=null)}_getChartElement(e,t){const n=this.surface.eventTarget(e);if(n)return this._drawingChartElement(n,e,t)}_drawingChartElement(e,t,n){let i=e;let r;for(;i&&!r;)r=i.chartElement,i=i.parent;if(r)return r.aliasFor&&(r=r.aliasFor(t,this._eventCoordinates(t))),n&&(r=r.closest(n),r&&r.aliasFor&&(r=r.aliasFor())),r}_eventCoordinates(e){const t=VN(e);return this._toModelCoordinates(t.x,t.y)}_elementPadding(){if(!this._padding){const{paddingLeft:e,paddingTop:t}=fN(this.element,["paddingLeft","paddingTop"]);this._padding={top:t,left:e}}return this._padding}_toDocumentCoordinates(e){const t=this._elementPadding();const n=FN(this.element);return{left:GN(e.x+t.left+n.left),top:GN(e.y+t.top+n.top)}}_toModelCoordinates(e,t){const n=this.element;const i=FN(n);const r=this._elementPadding();const o=d$(n).invert();const a=new ba(e-i.left-r.left,t-i.top-r.top).transform(o);return new dU(a.x,a.y)}_tap(e){const t=this.surface.eventTarget(e);const n=this._drawingChartElement(t,e);const i=this._sharedTooltip();this._startHover(t,e)||i||this._unsetActivePoint(),i&&this._trackSharedTooltip(this._eventCoordinates(e),e,!0),this._propagateClick(n,e),this.handlingTap=!0,setTimeout((()=>{this.handlingTap=!1}),0)}_click(e){const t=this._getChartElement(e);this._propagateClick(t,e)}_propagateClick(e,t){let n=e;for(;n;)n.click&&n.click(this,t),n=n.parent}_isLegendBeforeChart(){const{options:{legend:{position:e}},_legend:t}=this;return t&&t.hasItems()&&(e===BV||e===kV)}_focus(){this._preventInitialPointFocus||(this._isLegendBeforeChart()?this._focusFirstLegendItem():this._focusFirstPoint()),this._preventInitialPointFocus=!1}_keydown(e){const{_focusState:{legendInFocus:t,focusedElement:n},_legend:i}=this;if("Tab"===e.key){this._clearFocusedElement();const n=this._isLegendBeforeChart();t&&n!==e.shiftKey?this._navigatePoints(e):!t&&n===e.shiftKey&&i.hasItems()&&this._navigateLegend(e)}else e.key===vV?(n&&e.stopPropagation(),this._tooltip&&this._tooltip.visible?this._hideTooltip():this._blur()):e.key===gV?n&&(this._focusState.preserveHighlight=!0,this._propagateClick(n,e),this._focusElement(n)):t?this._navigateLegend(e):this._navigatePoints(e)}_navigatePoints(e){const{_focusState:t,_plotArea:n}=this;if(t.legendInFocus=!1,!t.focusedElement)return this._focusFirstPoint(),void e.preventDefault();const i=n=>{t.focusedPoint=n,this._focusElement(t.focusedPoint),this._displayTooltip(n),e.preventDefault()};switch(e.key){case iV:i(n.getPointToTheRight(t.focusedPoint));break;case nV:i(n.getPointToTheLeft(t.focusedPoint));break;case tV:i(n.getPointBelow(t.focusedPoint));break;case eV:i(n.getPointAbove(t.focusedPoint))}}_navigateLegend(e){const{_focusState:t,_legend:n,chartService:{rtl:i}}=this;if(t.legendInFocus=!0,!t.focusedElement)return this._focusFirstLegendItem(),void e.preventDefault();const r=n.getItems().length;const o=n=>{t.focusedLegendItemIndex=n(t.focusedLegendItemIndex,r),this._focusElement(this._getFocusedLegendItem()),e.preventDefault()};switch(e.key){case eV:case nV:o(i?iN:rN);break;case tV:case iV:o(i?rN:iN)}}_focusFirstPoint(){const e=this._focusState.focusedPoint=this._plotArea.getFirstPoint();e&&(this._focusElement(e),this._displayTooltip(e))}_hasFocus(){return this.element.ownerDocument.activeElement===this.element}_mousedown(){this._hasFocus()||(this._preventInitialPointFocus=!0)}_focusChart(){this._hasFocus()||(this._preventInitialPointFocus=!0,this.element.focus())}_focusPoint(e){this._focusState.focusedPoint=e,this._focusChart(),this._focusElement(e,!0)}_focusFirstLegendItem(){const{_focusState:e}=this;e.focusedLegendItemIndex=0,this._focusElement(this._getFocusedLegendItem()),e.legendInFocus=!0,this._hideTooltip()}_focusLegendItem(e){const{_focusState:t}=this;t.focusedLegendItemIndex=this._legend.getItems().findIndex((t=>t.options.series.index===e.seriesIndex&&t.options.pointIndex===e.pointIndex)),t.legendInFocus=!0,this._focusChart(),this._focusElement(this._getFocusedLegendItem(),!0)}_getFocusedLegendItem(){const{_focusState:e,_legend:t}=this;return t.getItems()[e.focusedLegendItemIndex]}_focusElement(e,t){const{_focusState:n}=this;if(this._clearFocusedElement(),e&&(n.focusedElement=e,this._setElementActiveDescendant(e),!t))if(e.focusVisual(),n.legendInFocus){const t=e.options;this._showSeriesInactiveOpacity(t.series.index,t.pointIndex)}else this._showInactiveOpacity(e)}_clearFocusedElement(){const{_focusState:e}=this;e&&(e.focusedElement&&e.focusedElement.clearFocusFromVisual&&(e.focusedElement.clearFocusFromVisual(),this._clearElementActiveDescendant()),e.focusedElement=null)}_setElementActiveDescendant(e){"canvas"===this.options.renderAs&&(this._pseudoFocusedElement=this._createPseudoFocusedElement(e),this.element.append(this._pseudoFocusedElement)),this.element.setAttribute(rV,e._id)}_clearElementActiveDescendant(){this._pseudoFocusedElement&&(this._pseudoFocusedElement.remove(),this._pseudoFocusedElement=null),this.element.removeAttribute(rV)}_createPseudoFocusedElement(e){const t=document.createElement("div");const 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);const i=n.ariaChecked;return HN(i)&&t.setAttribute("aria-checked",i),t}_blur(){this._focusState.legendInFocus=!1,this._clearFocusedElement(),this._hideInactiveOpacity()}_startHover(e,t){if(this._suppressHover)return!1;let n=this._drawingChartElement(e,t,(function(e){return(e.hover||e.over)&&!(e instanceof TK)}));const 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}_displayTooltip(e){cN({},this.options.tooltip,e.options.tooltip).visible&&(this._sharedTooltip()&&e.box?this._trackSharedTooltip(e.box.center(),{}):this._tooltip.show(e))}_hideTooltip(){this._tooltip&&this._tooltip.hide()}_displayInactiveOpacity(e,t,n){const 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{let t;if(!i.supportsPointInactiveOpacity())return void this._highlight.show(e);t=this._getInactivePoints(e,i),t&&t.length&&this._highlight.show(t,1-this._getInactiveOpacityForSeries(e.series))}}_getInactivePoints(e,t){return this._getAllPointsOfType(t,e.constructor).filter((t=>t!==e))}_getAllPointsOfType(e,t){let n=[];for(let i=0;i<e.children.length;i++){const r=e.children[i];r.constructor===t?n.push(r):r.children&&r.children.length&&(n=n.concat(this._getAllPointsOfType(r,t)))}return n}_updateHoveredPoint(e,t){const 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))}_updateDrilldownPoint(e){if(!e||!e.series)return;const{fields:t}=bj.current.bindPoint(e.series,null,e.dataItem);t.drilldown&&(this._drilldownState={cursor:this.element.style.cursor},this.element.style.cursor="pointer")}_resetDrilldownPoint(){this._drilldownState&&(this.element.style.cursor=this._drilldownState.cursor,this._drilldownState=null)}_startDrilldown(e){if(!e||!e.series)return;const t=e.series;const{fields:n}=bj.current.bindPoint(t,null,e.dataItem);const i=n.drilldown;if(i){const n={series:t,point:e,value:i,sender:this};this.trigger(cG,n)}}_updateSeriesOpacity(e,t){const n=this._plotArea;const i=n.series.length;for(let r=0;r<i;r++){const i=n.series[r];const o=this._getDefaultOpacityForSeries(i);const a=this._getInactiveOpacityForSeries(i);t||i===e.series?(i.opacity=o,i.line&&(i.line.opacity=o)):(i.defaultOpacity=o,i.opacity=a,i.line&&(i.line.opacity=a))}}_applySeriesOpacity(e,t,n,i){for(let r=0;r<e.length;r++){const o=e[r];const a=o.series||i;if(a&&(a.highlight||{}).visible&&o.visual){const e=i?i.opacity:o.series.opacity;(a!==t||n)&&o.visual.opacity(n?1:e)}o.children&&o.children.length&&this._applySeriesOpacity(o.children,t,n,o.series)}}_chartInstanceFromPoint(e){let t=e.parent;for(;t&&!t.plotArea;)t=t.parent;return t}_showInactiveOpacity(e){const t=this._plotArea.series.length>1;this._hasInactiveOpacity()?this._displayInactiveOpacity(e,t):this._highlight.show(e)}_hideInactiveOpacity(e){const 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)}_hasInactiveOpacity(){let e=void 0!==this.options.seriesDefaults.highlight.inactiveOpacity;let t=this.options.series.filter((e=>void 0!==e.highlight.inactiveOpacity)).length>0;return e||t}_getInactiveOpacityForSeries(e){let t=this.options.seriesDefaults.highlight.inactiveOpacity;return e.highlight.inactiveOpacity||t||e.opacity||1}_getDefaultOpacityForSeries(e){return e.defaultOpacity||e.opacity||1}_mouseover(e){const t=this._startHover(e.element,e.originalEvent);t&&t.tooltipTracking&&!this._mouseMoveTrackHandler&&!this._sharedTooltip()&&(this._mouseMoveTrackHandler=this._mouseMoveTracking.bind(this),BN(document,{[FQ]:this._mouseMoveTrackHandler}))}_mouseMoveTracking(e){const{options:t,_tooltip:n,_highlight:i,_activePoint:r}=this;const o=this._eventCoordinates(e);if(this._plotArea.box.containsPoint(o)){if(r&&r.tooltipTracking&&r.series&&r.parent.getNearestPoint){const a=r.parent.getNearestPoint(o.x,o.y,r.seriesIx);if(a&&a!==r&&(this._activePoint=a,!a.hover(this,e))){cN({},t.tooltip,a.options.tooltip).visible&&n.show(a),i.show(a)}}}else KN(document,{[FQ]:this._mouseMoveTrackHandler}),this._unsetActivePoint(),this._clearFocusedElement(),this._mouseMoveTrackHandler=null,this._hideInactiveOpacity(r)}_mousemove(e){const t=this._eventCoordinates(e);const n=this._plotArea;if(this._trackCrosshairs(t),n.hover){const i=n.backgroundContainsPoint(t);i?(this._plotAreaHovered=!0,this._plotArea.hover(this,e)):this._plotAreaHovered&&!i&&(this._plotAreaHovered=!1,this.trigger(Hq))}this._sharedTooltip()&&this._trackSharedTooltip(t,e)}_trackCrosshairs(e){const t=this._plotArea.crosshairs;for(let n=0;n<t.length;n++){const i=t[n];i.box.containsPoint(e)?i.showAt(e):i.hide()}}_trackSharedTooltip(e,t,n){if(this._suppressHover)return;const{options:{tooltip:i},_plotArea:r,_plotArea:{categoryAxis:o},_tooltip:a,_highlight:s}=this;if(r.backgroundContainsPoint(e)){const l=o.pointCategoryIndex(e);if(l!==this._tooltipCategoryIx||!this._sharedHighlight&&n){const n=r.pointsByCategoryIndex(l);const o=n.map((function(e){return e.eventArgs(t)}));const c=o[0]||{};c.categoryPoints=o,n.length>0&&!this.trigger(Iq,c)?(i.visible&&a.showAt(n,e),s.show(n),this._sharedHighlight=!0):a.hide(),this._tooltipCategoryIx=l}else n&&this._sharedHighlight&&(s.hide(),a.hide(),this._sharedHighlight=!1)}else this._sharedHighlight&&(s.hide(),a.hide(),this._tooltipCategoryIx=null,this._sharedHighlight=!1)}hideElements(e){const t=this._plotArea;this._mousemoveThrottled.cancel(),t.hideCrosshairs(),this._unsetActivePoint(e)}_unsetActivePoint(e){const{_highlight:t}=this;this._activePoint=null,this._hoveredPoint=null,e&&e.keepTooltipOpen||this._hideTooltip(),this._tooltipCategoryIx=null,this._sharedHighlight=!1,t&&t.hide()}_deferRedraw(){this._redraw()}_clearRedrawTimeout(){this._redrawTimeout&&(clearInterval(this._redrawTimeout),this._redrawTimeout=null)}bindCategories(){const e=this.options;const t=[].concat(e.categoryAxis);for(let e=0;e<t.length;e++){const n=t[e];!1!==n.autoBind&&this.bindCategoryAxisFromSeries(n,e)}}bindCategoryAxisFromSeries(e,t){const n=new Set;const i=this.options.series.filter((n=>n.categoryAxis===e.name||!n.categoryAxis&&0===t));const r=i.some((e=>Boolean(e.categoryField)));const o=i.filter((e=>e.data&&e.data.length>0));const a=o.map((e=>bj.current.bindPoint(e,0).fields.category));const s=a.reduce(((t,n)=>t||AG(e,n)),!1);if(o.filter(((e,t)=>e.categoryField||HN(a[t]))).forEach((e=>e.data.forEach(((t,i)=>{let r=bj.current.bindPoint(e,i).fields.category;if(s){const e=SG(r,t,this.chartService.intl);r=e?e.getTime():void 0}n.add(r)})))),n.size>0){let t=Array.from(n.values());s&&(t=t.sort().map((e=>e&&new Date(e)))),e.categories=t}else r&&(e.categories=[])}_isBindable(e){const t=bj.current.valueFields(e);let n=!0;for(let i=0;i<t.length;i++){let r=t[i];if(r===OV?r="field":r+="Field",!HN(e[r])){n=!1;break}}return n}_noTransitionsRedraw(){const e=this.options;let t;!1!==e.transitions&&(t=e.transitions,e.transitions=!1),this._redraw(),t&&(e.transitions=t)}_legendItemHover(e,t){this._showSeriesInactiveOpacity(e,t)}_showSeriesInactiveOpacity(e,t){const{_plotArea:n,_highlight:i}=this;const r=(n.srcSeries||n.series)[e];let o;if(o=TN(r.type,[tq,Kj,Yj,Qj])?n.findPoint((function(n){return n.series.index===e&&n.index===t})):n.pointsBySeriesIndex(e),this._hasInactiveOpacity()&&r.visible&&o){const e=n.series.length>1;const t=o.length?o[0]:o;this._displayInactiveOpacity(t,e,o)}else i.show(o)}_shouldAttachMouseMove(){return this._plotArea.crosshairs.length||this._tooltip&&this._sharedTooltip()||this.requiresHandlers([Bq,Hq])}updateMouseMoveHandler(){KN(this.element,{[FQ]:this._mousemoveThrottled}),this._shouldAttachMouseMove()&&BN(this.element,{[FQ]:this._mousemoveThrottled})}applyOptions(e,t){QQ(this._originalOptions,e),this._originalOptions=cN(this._originalOptions,e),this.options=cN({},this._originalOptions),t&&(this._theme=t,this.chartService.theme=t),this._initTheme(this.options,this._theme),this._toggleDragZoomEvents()}setOptions(e,t){this.applyOptions(e,t),this.bindCategories(),this.redraw(),this.updateMouseMoveHandler(),this._restoreOverlayElement()}setDirection(e){this.chartService.rtl=Boolean(e),this.surface&&"svg"===this.surface.type&&this._destroySurface()}setIntlService(e){this.chartService.intl=e}noTransitionsRedraw(){this._noTransitionsRedraw()}destroy(){this._destroyed=!0,KN(this.element,{[OQ]:this._clickHandler,[sG]:this._mousewheelHandler,[FQ]:this._mousemoveThrottled,[VQ]:this._mouseleaveHandler,[RQ]:this._mousedownHandler,[NQ]:this._keydownHandler,[$Q]:this._focusHandler,[UQ]:this._blurHandler}),this.domEvents&&(this.domEvents.destroy(),delete this.domEvents),this._mouseMoveTrackHandler&&KN(document,{[FQ]:this._mouseMoveTrackHandler}),this._focusState=null,this.element._kendoExportVisual=null,this._destroyView(),this._destroySurface(),this._clearRedrawTimeout()}_destroySurface(){const e=this.surface;e&&(e.unbind("mouseenter",this._surfaceMouseenterHandler),e.unbind("mouseleave",this._surfaceMouseleaveHandler),e.destroy(),this.surface=null)}_destroySelections(){const e=this._selections;if(e)for(;e.length>0;)e.shift().destroy()}_destroyView(){const 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)}};function qQ(e,t){if(e)for(let n=0;n<e.length;n++)if(e[n].category===t)return[e[n]]}function GQ(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 KQ(e){const t={};for(let n=0;n<e.length;n++){const i=e[n];const r=i.options.name;r&&(t[r]=i.range())}return t}const YQ=["data","categories"];function QQ(e,t){for(let n in t)if(!TN(n,YQ)&&_$(t,n)){const i=t[n];const r=e[n];if(HN(r)){const o=null===i;o||!HN(i)?(delete e[n],o&&delete t[n]):r&&dN(i)&&dN(r)&&QQ(r,i)}}}function XQ(e){for(let t=0;t<e.length;t++)e[t].notifyRender()}XN(jQ,{renderAs:"",chartArea:{},legend:{visible:!0,labels:{},accessibility:{},focusHighlight:{border:{opacity:1,color:aV,width:2}}},categoryAxis:{},seriesDefaults:{type:Gj,data:[],highlight:{visible:!0},labels:{},negativeValues:{visible:!1},accessibility:{},focusHighlight:{border:{opacity:1,width:2},zIndex:200}},series:[],seriesColors:null,tooltip:{visible:!1},transitions:!0,valueAxis:{narrowRange:!1},plotArea:{},title:{},xAxis:{},yAxis:{},panes:[{}],pannable:!1,zoomable:!1});class ZQ extends PY{_slotAnchor(e,t){const n=this.plotArea.categoryAxis.options.vertical;const i=n?{horizontal:"left",vertical:"center"}:{horizontal:"center",vertical:"bottom"};let r;return r=n?new dU(this.plotArea.box.x2,t.center().y):new dU(t.center().x,-2),{point:r,align:i}}_defaultAnchor(e,t){return this._slotAnchor({},t)}}const JQ=[$j,jj];function eX(e){const t=[];for(let n=0;n<e.length;n++){const i=e[n];t[n]=i.style.display,i.style.display="none"}return t}function tX(e,t){for(let n=0;n<e.length;n++)e[n].style.display=t[n]}function nX(e){return eN(e)?[e]:e}let iX=class extends jQ{_setElementClass(e){YV(e,"k-sparkline")}_initElement(e){super._initElement(e),this._initialWidth=Math.floor(ON(e).width)}_resize(){const e=this.element;const t=eX(e.childNodes);this._initialWidth=Math.floor(ON(e).width),tX(e.childNodes,t),super._resize()}_modelOptions(){const e=this.options;const t=this._surfaceWrap();const n=eX(t.childNodes);const i=document.createElement("span");i.innerHTML=" ",t.appendChild(i);const r=cN({width:this._autoWidth,height:ON(t).height,transitions:e.transitions},e.chartArea,{inline:!0,align:!1});return ON(t,{width:r.width,height:r.height}),t.removeChild(i),tX(t.childNodes,n),this.surface&&this.surface.resize(),r}_surfaceWrap(){if(!this.stage){const e=this.stage=document.createElement("span");this.element.appendChild(e)}return this.stage}_createPlotArea(e){const t=super._createPlotArea(e);return this._autoWidth=this._initialWidth||this._calculateWidth(t),t}_calculateWidth(e){const t=this.options;const n=mN(t.chartArea.margin);const i=e.charts;const r=this._surfaceWrap();let o=0;for(let e=0;e<i.length;e++){const t=i[e];const n=(t.options.series||[])[0];if(!n)continue;if(n.type===$j)return 150;if(n.type===jj)return 150;if(n.type===tq)return ON(r).height;const a=t.categoryAxis;if(a){const e=a.categoriesCount()*(!t.options.isStacked&&TN(n.type,[Gj,mq])?t.seriesOptions.length:1);o=Math.max(o,e)}}let a=o*t.pointWidth;return a>0&&(a+=n.left+n.right),a}_createSharedTooltip(e){return new ZQ(this._plotArea,e)}static normalizeOptions(e){let t=nX(e);return t=KV(t)?{seriesDefaults:{data:t}}:cN({},t),t.series||(t.series=[{data:nX(t.data)}]),cN(t,{seriesDefaults:{type:t.type}}),(TN(t.series[0].type,JQ)||TN(t.seriesDefaults.type,JQ))&&(t=cN({},{categoryAxis:{crosshair:{visible:!1}}},t)),t}};XN(iX,{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}]});class rX extends kl{setup(){this._initialOpacity=parseFloat(fN(this.element,"opacity").opacity)}step(e){fN(this.element,{opacity:String(MN(this._initialOpacity,0,e))})}abort(){super.abort(),fN(this.element,{display:"none",opacity:String(this._initialOpacity)})}cancel(){super.abort(),fN(this.element,{opacity:String(this._initialOpacity)})}}function oX(e,t){const n=document.createElement("div");return n.className=e,t&&(n.style.cssText=t),n}class aX{constructor(e,t,n){this.options=cN({},this.options,n),this.container=e,this.chartService=t;const i=fN(e,["paddingLeft","paddingTop"]);this.chartPadding={top:i.paddingTop,left:i.paddingLeft},this.createElements(),e.appendChild(this.element)}createElements(){const e=this.element=oX("k-navigator-hint","display: none; position: absolute; top: 1px; left: 1px;");const t=this.tooltip=oX("k-tooltip k-chart-tooltip");const n=this.scroll=oX("k-scroll");t.innerHTML=" ",e.appendChild(t),e.appendChild(n)}show(e,t,n){const{element:i,options:r,scroll:o,tooltip:a}=this;const s=_W(TW(e)+TW(t-e)/2);const l=.4*n.width();const c=n.center().x-l;const d=(n.center().x-c)/(r.max-r.min);const h=s-r.min;let u=this.chartService.intl.format(r.format,e,t);const p=_N(r);this.clearHideTimeout(),this._visible||(fN(i,{visibility:"hidden",display:"block"}),this._visible=!0),p&&(u=p({from:e,to:t})),a.innerHTML=u,fN(a,{left:n.center().x-a.offsetWidth/2,top:n.y1});const f=fN(a,["marginTop","borderTopWidth","height"]);fN(o,{width:l,left:c+h*d,top:n.y1+f.marginTop+f.borderTopWidth+f.height/2}),fN(i,{visibility:"visible"})}clearHideTimeout(){this._hideTimeout&&clearTimeout(this._hideTimeout),this._hideAnimation&&this._hideAnimation.cancel()}hide(){this.clearHideTimeout(),this._hideTimeout=setTimeout((()=>{this._visible=!1,this._hideAnimation=new rX(this.element),this._hideAnimation.setup(),this._hideAnimation.play()}),this.options.hideDelay)}destroy(){this.clearHideTimeout(),this.container&&this.container.removeChild(this.element),delete this.container,delete this.chartService,delete this.element,delete this.tooltip,delete this.scroll}}XN(aX,{format:"{0:d} - {1:d}",hideDelay:500});const sX="_navigator";const lX=sX;const cX="_default";var dX=Object.freeze({__proto__:null,DEFAULT_PANE:cX,NAVIGATOR_AXIS:lX,NAVIGATOR_PANE:sX});let hX=class e{constructor(e){this.chart=e;const t=this.options=cN({},this.options,e.options.navigator);const n=t.select;n&&(n.from=this.parseDate(n.from),n.to=this.parseDate(n.to)),HN(t.hint.visible)||(t.hint.visible=t.visible),this.chartObserver=new DN(this,{[Rq]:"_drag",[Fq]:"_dragEnd",[Nq]:"_zoom",[$q]:"_zoomEnd"}),e.addObserver(this.chartObserver)}parseDate(e){return IW(this.chart.chartService.intl,e)}clean(){this.selection&&(this.selection.destroy(),this.selection=null),this.hint&&(this.hint.destroy(),this.hint=null)}destroy(){this.chart&&(this.chart.removeObserver(this.chartObserver),delete this.chart),this.clean()}redraw(){this._redrawSelf(),this.initSelection()}initSelection(){const{chart:e,options:t}=this;const n=this.mainAxis();const{min:i,max:r}=n.roundedRange();const{from:o,to:a,mousewheel:s}=t.select;const l=(c=n,uX.prototype=c,new uX);var c;0!==n.categoriesCount()&&(this.clean(),l.box=n.box,this.selection=new IY(e,l,{min:i,max:r,from:o||i,to:a||r,mousewheel:YN(s,{zoom:"left"}),visible:t.visible},new DN(this,{selectStart:"_selectStart",select:"_select",selectEnd:"_selectEnd"})),t.hint.visible&&(this.hint=new aX(e.element,e.chartService,{min:i,max:r,template:_N(t.hint),format:t.hint.format})))}setRange(){const e=this.chart._createPlotArea(!0).namedCategoryAxes[lX];const{min:t,max:n}=e.roundedRange();const i=this.options.select||{};let r=i.from||t;r<t&&(r=t);let o=i.to||n;o>n&&(o=n),this.options.select=cN({},i,{from:r,to:o}),this.filterAxes()}_redrawSelf(e){const t=this.chart._plotArea;t&&t.redraw(UN(t.panes),e)}redrawSlaves(){const e=this.chart;const t=e._plotArea;const n=t.panes.filter((e=>e.options.name!==sX));t.srcSeries=e.options.series,t.options.categoryAxis=e.options.categoryAxis,t.clearSeriesPointsCache(),t.redraw(n)}_drag(e){const{chart:t,selection:n}=this;const i=t._eventCoordinates(e.originalEvent);const r=this.mainAxis();const o=r.roundedRange();const a=r.pane.box.containsPoint(i);const s=t._plotArea.categoryAxis;const l=e.axisRanges[s.options.name];const c=this.options.select;let d;if(!l||a||!n)return;d=c.from&&c.to?TW(c.to)-TW(c.from):TW(n.options.to)-TW(n.options.from);const h=_W(WN(TW(l.min),o.min,TW(o.max)-d));const u=_W(WN(TW(h)+d,TW(o.min)+d,o.max));this.options.select={from:h,to:u},this.options.liveDrag&&(this.filterAxes(),this.redrawSlaves()),n.set(h,u),this.showHint(h,u)}_dragEnd(){this.filterAxes(),this.filter(),this.redrawSlaves(),this.hint&&this.hint.hide()}readSelection(){const{selection:{options:{from:e,to:t}},options:{select:n}}=this;n.from=e,n.to=t}filterAxes(){const{options:{select:e={}},chart:t}=this;const n=t.options.categoryAxis;const{from:i,to:r}=e;for(let e=0;e<n.length;e++){const t=n[e];t.pane!==sX&&(t.min=i,t.max=r)}}filter(){const{chart:e,options:{select:t}}=this;if(!e.requiresHandlers(["navigatorFilter"]))return;const n=this.mainAxis();const i={from:t.from,to:t.to};if("category"!==n.options.type){const n=new WW(cN({baseUnit:"fit"},e.options.categoryAxis[0],{categories:[t.from,t.to]}),e.chartService).options;i.from=yW(n.min,-n.baseUnitStep,n.baseUnit),i.to=yW(n.max,n.baseUnitStep,n.baseUnit)}this.chart.trigger("navigatorFilter",i)}_zoom(e){const{chart:{_plotArea:{categoryAxis:t}},selection:n,options:{select:i,liveDrag:r}}=this;const o=this.mainAxis();let a=e.delta;if(!n)return;const s=o.categoryIndex(n.options.from);const l=o.categoryIndex(n.options.to);const c=this.chart._eventCoordinates(e.originalEvent);e.originalEvent.preventDefault(),Math.abs(a)>1&&(a*=3),l-s>1?(n.zoom(a,c),this.readSelection()):(t.options.min=i.from,i.from=t.scaleRange(-e.delta*this.chart._mousewheelZoomRate(),c).min),r&&(this.filterAxes(),this.redrawSlaves()),n.set(i.from,i.to),this.showHint(this.options.select.from,this.options.select.to)}_zoomEnd(e){this._dragEnd(e)}showHint(e,t){const n=this.chart._plotArea;this.hint&&this.hint.show(e,t,n.backgroundBox())}_selectStart(e){return this.chart._selectStart(e)}_select(e){return this.showHint(e.from,e.to),this.chart._select(e)}_selectEnd(e){return this.hint&&this.hint.hide(),this.readSelection(),this.filterAxes(),this.filter(),this.redrawSlaves(),this.chart._selectEnd(e)}mainAxis(){const e=this.chart._plotArea;if(e)return e.namedCategoryAxes[lX]}select(e,t){const 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}}static setup(t={},n={}){if(t.__navi)return;t.__navi=!0;const i=cN({},n.navigator,t.navigator);const r=t.panes=[].concat(t.panes);const o=cN({},i.pane,{name:sX});i.visible||(o.visible=!1,o.height=.1),"top"!==t.navigator.position?r.push(o):r.unshift(o),r.forEach((e=>{e.name=e.name||cX})),e.attachAxes(t,i),e.attachSeries(t,i,n)}static attachAxes(e,t){const n=t.series||[];const i=e.categoryAxis=[].concat(e.categoryAxis);const r=e.valueAxis=[].concat(e.valueAxis);i.concat(r).forEach((e=>{e.pane=e.pane||cX}));const o=0===xG(n,bq).length;const a=cN({type:"date",pane:sX,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]}});const s=t.categoryAxis;i.push(cN({},a,{maxDateGroups:200},s,{name:lX,title:null,baseUnit:"fit",baseUnitStep:"auto",labels:{visible:!1},majorTicks:{visible:!1}}),cN({},a,s,{name:lX+"_labels",maxDateGroups:20,baseUnitStep:"auto",labels:{position:""},plotBands:[],autoBaseUnitSteps:{minutes:[]},_overlap:!0}),cN({},a,s,{name:lX+"_ticks",maxDateGroups:200,majorTicks:{width:.5},plotBands:[],title:null,labels:{visible:!1,mirror:!0},_overlap:!0})),r.push(cN({name:lX,pane:sX,majorGridLines:{visible:!1},visible:!1},t.valueAxis))}static attachSeries(e,t,n){const i=e.series=e.series||[];const r=[].concat(t.series||[]);const o=n.seriesColors;const a=t.seriesDefaults;for(let e=0;e<r.length;e++)i.push(cN({color:o[e%o.length],categoryField:t.dateField,visibleInLegend:!1,tooltip:{visible:!1}},a,r[e],{axis:lX,categoryAxis:lX,autoBind:t.autoBindElements}))}};function uX(){}class pX extends jQ{applyDefaults(e,t){const n=ON(this.element).width||fV;let i=t;const r={seriesDefaults:{categoryField:e.dateField},axisDefaults:{categoryAxis:{name:"default",majorGridLines:{visible:!1},labels:{step:2},majorTicks:{visible:!1},maxDateGroups:Math.floor(n/28)}}};i&&(i=cN({},i,r)),hX.setup(e,i),super.applyDefaults(e,i)}_setElementClass(e){YV(e,"k-chart k-stockchart")}setOptions(e){this.destroyNavigator(),super.setOptions(e)}noTransitionsRedraw(){const e=this.options.transitions;this.options.transitions=!1,this._fullRedraw(),this.options.transitions=e}_resize(){this.noTransitionsRedraw()}_redraw(){const e=this.navigator;!this._dirty()&&e&&e.options.partialRedraw?e.redrawSlaves():this._fullRedraw()}_dirty(){const e=this.options;const t=[].concat(e.series,e.navigator.series);const n=xN(t,(function(e){return e&&e.visible})).length;const i=this._seriesCount!==n;return this._seriesCount=n,i}_fullRedraw(){let e=this.navigator;e||(e=this.navigator=new hX(this),this.trigger("navigatorCreated",{navigator:e})),e.clean(),e.setRange(),super._redraw(),e.initSelection()}_trackSharedTooltip(e){const t=this._plotArea.paneByPoint(e);t&&t.options.name===sX?this._unsetActivePoint():super._trackSharedTooltip(e)}bindCategories(){super.bindCategories(),this.copyNavigatorCategories()}copyNavigatorCategories(){const e=[].concat(this.options.categoryAxis);let t;for(let n=0;n<e.length;n++){const i=e[n];i.name===lX?t=i.categories:t&&i.pane===sX&&(i.categories=t)}}destroyNavigator(){this.navigator&&(this.navigator.destroy(),this.navigator=null)}destroy(){this.destroyNavigator(),super.destroy()}_stopChartHandlers(e){const t=this._eventCoordinates(e);const n=this._plotArea.paneByPoint(t);return super._stopChartHandlers(e)||n&&n.options.name===sX}_toggleDragZoomEvents(){this._dragZoomEnabled||(this.element.style.touchAction="none",this._dragZoomEnabled=!0)}}XN(pX,{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}});const fX=150;const mX="arrowPointer";const gX="barPointer";const vX=.5;const _X=Math.PI/180;const bX="inside";const wX="linear";const yX="outside";const kX="radialPointer";const xX="radialRangePointer";function CX(e,t){const n=e.getOrigin();const i=e.getSize();const r=mN(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}const{Group:SX,Path:TX,Text:MX}=Wc;function AX(e,t){const n=e.box;const i=e.children[0].box;const r=t.border||{};const o=t.background||"";const a=TX.fromRect(new ya([n.x1,n.y1],[n.width(),n.height()]),{stroke:{}});const s=new MX(e.text,new ba(i.x1,i.y1),{font:t.font,fill:{color:t.color}});const l=CX(s.bbox().clone(),t.padding);const c=TX.fromRect(l,{stroke:{color:r.width?r.color:"",width:r.width,opacity:r.opacity,dashType:r.dashType,lineJoin:"round",lineCap:"round"},fill:{color:o}});const d=new SX;return d.append(a),d.append(c),d.append(s),d}function DX(e,t,n){const i=HN(e.from)?e.from:CV;const r=HN(e.to)?e.to:xV;return e.from=Math.max(Math.min(r,i),t),e.to=Math.min(Math.max(r,i),n),e}function EX(e,t){const n=mN(t);return n.left=-n.left,n.top=-n.top,n.right=-n.right,n.bottom=-n.bottom,CX(e,n)}const{Path:IX,Surface:zX}=Wc;class PX{constructor(e,t,n,i={}){this.element=e,this.theme=n,this.contextService=new GU(this,i),this._originalOptions=cN({},this.options,t),this.options=cN({},this._originalOptions),this._initTheme(n),this.redraw()}destroy(){this.surface&&(this.surface.destroy(),this.surface=null),delete this.element,delete this.surfaceElement}value(e){const t=this.pointers[0];if(0===arguments.length)return t.value();t.value(e),this._setValueOptions(e)}_draw(){const e=this.surface;e.clear(),e.draw(this._visuals)}exportVisual(){return this._visuals}allValues(e){const t=this.pointers;const n=[];if(0===arguments.length){for(let e=0;e<t.length;e++)n.push(t[e].value());return n}if(KV(e))for(let n=0;n<e.length;n++)eN(e[n])&&t[n].value(e[n]);this._setValueOptions(e)}_setValueOptions(e){const t=[].concat(this.options.pointer);const n=[].concat(e);for(let e=0;e<n.length;e++)t[e].value=n[e]}resize(){this.noTransitionsRedraw()}noTransitionsRedraw(){const e=this.options.transitions;this._toggleTransitions(!1),this.redraw(),this._toggleTransitions(e)}redraw(){const e=this._surfaceSize();const t=new ya([0,0],[e.width,e.height]);this._initSurface(),this.gaugeArea=this._createGaugeArea(),this._createModel();const n=EX(t.bbox(),this._gaugeAreaMargin);this.reflow(n)}setOptions(e,t){this._originalOptions=cN(this._originalOptions,e),this.options=cN({},this._originalOptions),this._initTheme(t),this.redraw()}setDirection(e){this.contextService.rtl=Boolean(e),this.surface&&"svg"===this.surface.type&&(this.surface.destroy(),this.surface=null)}setIntlService(e){this.contextService.intl=e}_initTheme(e){let t=e||this.theme||{};this.theme=t,this.options=cN({},t,this.options);const n=this.options;const i=n.pointer;if(KV(i)){const e=[];for(let n=0;n<i.length;n++)e.push(cN({},t.pointer,i[n]));n.pointer=e}}_createGaugeArea(){const e=this.options.gaugeArea;const t=this.surface.size();const n=e.border||{};let i=new ya([0,0],[t.width,t.height]);this._gaugeAreaMargin=e.margin||5,n.width>0&&(i=EX(i,n.width));return IX.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}})}_initSurface(){const{options:e,surface:t}=this;const n=this._surfaceElement();const i=this._surfaceSize();ON(n,i),t&&t.options.type===e.renderAs?(this.surface.clear(),this.surface.resize()):(t&&t.destroy(),this.surface=zX.create(n,{type:e.renderAs}))}_surfaceSize(){const e=this.options;const t=this._getSize();return e.gaugeArea&&cN(t,e.gaugeArea),t}_surfaceElement(){return this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element.appendChild(this.surfaceElement)),this.surfaceElement}getSize(){return this._getSize()}_getSize(){const e=this.element;const t=this._defaultSize();let n=e.offsetWidth;let i=e.offsetHeight;return n||(n=t.width),i||(i=t.height),{width:n,height:i}}_defaultSize(){return{width:200,height:200}}_toggleTransitions(e){this.options.transitions=e;for(let t=0;t<this.pointers.length;t++)this.pointers[t].options.animation.transitions=e}}XN(PX,{plotArea:{},theme:"default",renderAs:"",pointer:{},scale:{},gaugeArea:{}});const{Path:LX,Group:BX}=Wc;const HX=ba;function RX(e,t){const{position:n,tickX:i,tickY:r}=e;let o,a;e.vertical?(o=new HX(i,n),a=new HX(i+t.size,n)):(o=new HX(n,r),a=new HX(n,r+t.size));return new LX({stroke:{color:t.color,width:t.width}}).moveTo(o).lineTo(a)}function FX(e,t,n,i){const r=t.length;if(i.visible){const{mirror:o,lineBox:a}=n;for(let 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(RX(n,i)))}}class OX extends YW{constructor(e,t){let n=e||{};!HN(n.reverse)&&!1===n.vertical&&(t||{}).rtl&&(n=Object.assign({},n,{reverse:!0})),super(0,1,n,t),this.options.minorUnit=this.options.minorUnit||this.options.majorUnit/10}initUserOptions(e){let t=cN({},this.options,e);return t=cN({},t,{labels:{mirror:t.mirror}}),t.majorUnit=t.majorUnit||cU(t.min,t.max),t}initFields(){}render(){const e=this.elements=new BX;const t=this.renderLabels();const n=this.renderLine();const i=this.renderTicks();const r=this.renderRanges();return e.append(n,t,i,r),e}renderRanges(){const e=this.options;const{min:t,max:n,vertical:i,labels:{mirror:r}}=e;const o=e.ranges||[];const a=new BX;const s=o.length;const l=e.rangeSize||e.minorTicks.size/2;for(let e=0;e<s;e++){const s=DX(o[e],t,n);const c=this.getSlot(s.from,s.to);const d=i?this.lineBox():c;const h=i?c:this.lineBox();i?d.x1-=l*(r?-1:1):h.y2+=l*(r?-1:1),a.append(LX.fromRect(new ya([d.x1,h.y1],[d.x2-d.x1,h.y2-h.y1]),{fill:{color:s.color,opacity:s.opacity},stroke:{}}))}return a}renderLabels(){const{labels:e,options:t}=this;const n=new BX;for(let i=0;i<e.length;i++)n.append(AX(e[i],t.labels));return n}renderLine(){const e=this.options.line;const t=this.lineBox();const n=new BX;if(e.width>0&&e.visible){const i=new LX({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}renderTicks(){const e=new BX;const t=this.options;const n=t.majorTicks.visible?t.majorUnit:0;const i={vertical:t.vertical,mirror:t.labels.mirror,lineBox:this.lineBox()};return FX(e,this.getMajorTickPositions(),i,t.majorTicks),FX(e,this.getMinorTickPositions(),i,cN({},{skipUnit:n/t.minorUnit},t.minorTicks)),e}}XN(OX,{min:0,max:50,majorTicks:{size:15,align:bX,color:aV,width:vX,visible:!0},minorTicks:{size:10,align:bX,color:aV,width:vX,visible:!0},line:{width:vX},labels:{position:bX,padding:2},mirror:!1,_alignLines:!1});class VX{constructor(e,t){const{min:n,max:i}=e.options;const r=this.options=cN({},this.options,t);r.fill=r.color,this.scale=e,HN(r.value)?r.value=WN(r.value,n,i):r.value=n}value(e){const t=this.options;const n=t.value;if(0===arguments.length)return n;const{min:i,max:r}=this.scale.options;t._oldValue=HN(t._oldValue)?t.value:i,t.value=WN(e,i,r),this.elements&&this.repaint()}}XN(VX,{color:aV});class NX extends VX{constructor(e,t){super(e,t),this.options=cN({track:{visible:HN(t.track)}},this.options)}reflow(){const{options:e,scale:t}=this;const{mirror:n,vertical:i}=t.options;const r=t.lineBox();const o=e.track.size||e.size;const a=e.size/2;const s=mN(e.margin);let l=i?s[n?"left":"right"]:s[n?"bottom":"top"];let c,d,h;l=n?-l:l,i?(h=new hU(r.x1+l,r.y1,r.x1+l,r.y2),n?h.x1-=o:h.x2+=o,e.shape!==gX&&(d=new hU(r.x2+l,r.y1-a,r.x2+l,r.y2+a),c=d)):(h=new hU(r.x1,r.y1-l,r.x2,r.y1-l),n?h.y2+=o:h.y1-=o,e.shape!==gX&&(d=new hU(r.x1-a,r.y1-l,r.x2+a,r.y1-l),c=d)),this.trackBox=h,this.pointerRangeBox=d,this.box=c||h.clone().pad(e.border.width)}getElementOptions(){const e=this.options;return{fill:{color:e.color,opacity:e.opacity},stroke:HN(e.border)?{color:e.border.width?e.border.color||e.color:"",width:e.border.width,dashType:e.border.dashType,opacity:e.opacity}:null}}_margin(){const{scale:e,options:t}=this;const{mirror:n,vertical:i}=e.options;const r=mN(t.margin);return i?r[n?"left":"right"]:r[n?"bottom":"top"]}}XN(NX,{shape:gX,track:{border:{width:1}},color:aV,border:{width:1},opacity:1,margin:mN(3),animation:{type:gX},visible:!0});class $X extends kl{setup(){const e=this.options;const{margin:t,from:n,to:i,vertical:r}=e;const o=r?"x1":"y1";e.mirror===r?(n[o]-=t,i[o]-=t):(n[o]+=t,i[o]+=t);const a=this.fromScale=new ba(n.x1,n.y1);const s=this.toScale=new ba(i.x1,i.y1);0!==e.duration&&(e.duration=Math.max(a.distanceTo(s)/e.duration*1e3,1))}step(e){const t=MN(this.fromScale.x,this.toScale.x,e);const n=MN(this.fromScale.y,this.toScale.y,e);this.element.transform(xa().translate(t,n))}}XN($X,{easing:wX,duration:250}),yl.current.register(mX,$X);const UX=ba;const WX=Rs;class jX extends NX{constructor(e,t){super(e,t),HN(this.options.size)||(this.options.size=.6*this.scale.options.majorTicks.size)}pointerShape(){const{scale:e,options:{size:t}}=this;const n=t/2;const i=e.options.mirror?-1:1;let r;return r=e.options.vertical?[new UX(0,0-n),new UX(0-i*t,0),new UX(0,0+n)]:[new UX(0-n,0),new UX(0,0+i*t),new UX(0+n,0)],r}repaint(){const{scale:e,options:t}=this;const n=new $X(this.elements,cN(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()}render(){const{scale:e,options:t}=this;const n=this.getElementOptions();const i=this.pointerShape(t.value);t.animation.type=mX;const r=new WX({stroke:n.stroke,fill:n.fill}).moveTo(i[0]).lineTo(i[1]).lineTo(i[2]).close();const o=e.getSlot(t.value);return r.transform(xa().translate(o.x1,o.y1)),this.elements=r,r}}class qX extends kl{setup(){const e=this.options;const t=this.axis=e.vertical?UV:$V;const n=this.to=e.newPoints[0][t];const 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)}step(e){const t=MN(this.from,this.to,e);this._set(t)}_set(e){const t="set"+this.axis.toUpperCase();const n=this.options.newPoints;n[0][t](e),n[1][t](e)}}XN(qX,{easing:wX,speed:250}),yl.current.register(gX,qX);const{Group:GX,Path:KX}=Wc;class YX extends NX{constructor(e,t){super(e,t),HN(this.options.size)||(this.options.size=.3*this.scale.options.majorTicks.size)}pointerShape(e){const{scale:t,options:n}=this;const{mirror:i,vertical:r}=t.options;const o=i===r?-1:1;const a=n.size*o;const s=t.getSlot(t.options.min);const l=t.getSlot(e);const c=r?UV:$V;const d=r?$V:UV;const h=this._margin()*o;const u=new ba;u[c]=s[c+"1"],u[d]=s[d+"1"];const p=new ba;p[c]=l[c+"1"],p[d]=l[d+"1"],r?(u.translate(h,0),p.translate(h,0)):(u.translate(0,h),p.translate(0,h));const f=p.clone();const m=u.clone();return r?(f.translate(a,0),m.translate(a,0)):(f.translate(0,a),m.translate(0,a)),[u,p,f,m]}repaint(){const{scale:e,options:t}=this;const n=this.pointerShape(t.value);const i=this.pointerPath;const r=this.pointerShape(t._oldValue);i.moveTo(n[0]).lineTo(n[1]).lineTo(n[2]).lineTo(n[3]).close();const o=new qX(i,cN(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()}render(){const e=new GX;const t=this.getElementOptions();this.options.track.visible&&e.append(this.renderTrack());const n=this.pointerPath=new KX({stroke:t.stroke,fill:t.fill});return e.append(n),this.elements=e,e}renderTrack(){const e=this.options.track;const t=e.border||{};const n=this.trackBox.clone().pad(t.width||0);return KX.fromRect(n.toRect(),{fill:{color:e.color,opacity:e.opacity},stroke:{color:t.width?t.color||e.color:"",width:t.width,dashType:t.dashType}})}}const QX=Us;class XX extends PX{reflow(e){const t=this.pointers;const n=e.origin.x;const i=e.origin.y;const r=new hU(n,i,n+e.width(),i+e.height());this.scale.reflow(r),this._shrinkScaleWidth(r);for(let e=0;e<t.length;e++)t[e].reflow();this.bbox=this._getBox(r),this._alignElements(),this._shrinkElements(),this._buildVisual(),this._draw()}_buildVisual(){const e=new QX;const t=this.scale.render();const n=this.pointers;e.append(this.gaugeArea),e.append(t);for(let t=0;t<n.length;t++){const i=n[t];e.append(i.render()),i.value(i.options.value)}this._visuals=e}_createModel(){const e=this.options;const t=this.scale=new OX(e.scale,this.contextService);this.pointers=[];let n=e.pointer;n=KV(n)?n:[n];for(let i=0;i<n.length;i++){const r=cN({},n[i],{animation:{transitions:e.transitions}});const o="arrow"===r.shape?jX:YX;this.pointers.push(new o(t,r))}}_defaultSize(){const e=this.options.scale.vertical;return{width:e?60:200,height:e?200:60}}_getBox(e){const{scale:t,pointers:n}=this;const i=e.center();let r=n[0].box.clone().wrap(t.box);for(let e=0;e<n.length;e++)r.wrap(n[e].box.clone());let o;return t.options.vertical?(o=r.width()/2,r=new hU(i.x-o,e.y1,i.x+o,e.y2)):(o=r.height()/2,r=new hU(e.x1,i.y-o,e.x2,i.y+o)),r}_alignElements(){const{scale:e,pointers:t}=this;const n=e.box;const i=t[0].box.clone().wrap(e.box);const r=this.bbox;for(let e=0;e<t.length;e++)i.wrap(t[e].box.clone());let o;e.options.vertical?(o=r.center().x-i.center().x,e.reflow(new hU(n.x1+o,r.y1,n.x2+o,r.y2))):(o=r.center().y-i.center().y,e.reflow(new hU(n.x1,n.y1+o,n.x2,n.y2+o)));for(let e=0;e<t.length;e++)t[e].reflow(this.bbox)}_shrinkScaleWidth(e){const{scale:t}=this;if(!t.options.vertical){const n=t.contentBox().width()-e.width();n>0&&(t.box.shrink(n,0),t.box.alignTo(e,"center"),t.reflow(t.box))}}_shrinkElements(){const{scale:e,pointers:t}=this;const n=e.box.clone();const i=e.options.vertical?"y":"x";const r=t[0].box;for(let e=0;e<t.length;e++)r.wrap(t[e].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(let e=0;e<t.length;e++)t[e].reflow(this.bbox)}}XN(XX,{transitions:!0,gaugeArea:{background:""},scale:{vertical:!0}});const ZX=180;const{Arc:JX,Path:eZ,Group:tZ}=Wc;function nZ(e,t,n,i){const r=new tZ;const o=e.center;const a=e.getRadiusX();if(i.visible)for(let n=0;n<t.length;n++){const s=e.pointAt(t[n]);const l=new ba(o.x+a-i.size,o.y).rotate(t[n],o);r.append(new eZ({stroke:{color:i.color,width:i.width}}).moveTo(s).lineTo(l))}return r}function iZ(e,t,n,i){return{from:e,to:t,color:n,opacity:i}}class rZ extends YW{constructor(e,t){super(0,1,e,t)}initUserOptions(e){const t=cN({},this.options,e);return t.majorUnit=t.majorUnit||cU(t.min,t.max),t.minorUnit=t.minorUnit||t.majorUnit/10,t}initFields(){}render(e,t){const n=this.renderArc(e,t);this.bbox=n.bbox(),this.labelElements=this.renderLabels(),this.ticks=this.renderTicks(),this.ranges=this.renderRanges()}reflow(e){const t=e.center();const n=Math.min(e.height(),e.width())/2;if(!HN(this.bbox))return this.render(t,n);this.bbox=this.arc.bbox(),this.radius(this.arc.getRadiusX()),this.repositionRanges(),this.renderLabels()}slotAngle(e){const{min:t,max:n,reverse:i,startAngle:r,endAngle:o}=this.options;const a=o-r;let s;return s=i?o-(e-t)/(n-t)*a:(e-t)/(n-t)*a+r,s+ZX}hasRanges(){const e=this.options.ranges;return e&&e.length}ticksSize(){const{majorTicks:e,minorTicks:t}=this.options;let n=0;return e.visible&&(n=e.size),t.visible&&(n=Math.max(t.size,n)),n}labelsCount(){let e=super.labelsCount();const t=this.options;return t.endAngle-t.startAngle>=360&&t.max%t.majorUnit==0&&(e-=1),e}renderLabels(){const e=this.options;const t=this.arc.clone();let n=t.getRadiusX();const i=this.tickAngles(t,e.majorUnit);const r=e.rangeSize=e.rangeSize||.1*n;const o=new tZ;let a=.05*n;HN(e.rangeDistance)?a=e.rangeDistance:e.rangeDistance=a;const s=e.labels;const l=s.position===bX;const c=HN(this.labelElements);l&&(n-=this.ticksSize(),this.hasRanges()&&!c&&(n-=r+a),t.setRadiusX(n).setRadiusY(n));const d=this.labels;const h=d.length;const u=mN(s.padding);const p=(u.left+u.right)/2;const f=(u.top+u.bottom)/2;for(let n=0;n<h;n++){const r=d[n];const a=r.box.width()/2;const s=r.box.height()/2;const h=i[n];const u=(h-ZX)*_X;const m=t.pointAt(h);const g=m.x+Math.cos(u)*(a+p)*(l?1:-1);const v=m.y+Math.sin(u)*(s+f)*(l?1:-1);r.reflow(new hU(g-a,v-s,g+a,v+s));const _=new ba(r.box.x1,r.box.y1);let b;if(c){b=this.labelElements.children[n];const e=b.bbox().origin;const t=b.transform()||xa();t.translate(_.x-e.x,_.y-e.y),b.transform(t)}else b=AX(r,e.labels),o.append(b);this.bbox=ya.union(this.bbox,b.bbox())}return o}repositionRanges(){const e=this.ranges.children;if(e.length>0){const{rangeDistance:t,rangeSize:n}=this.options;let i=this.getRangeRadius();this.options.labels.position===bX&&(i+=n+t);const r=i+n/2;for(let t=0;t<e.length;t++)e[t]._geometry.setRadiusX(r).setRadiusY(r);this.bbox=ya.union(this.bbox,this.ranges.bbox())}}renderRanges(){const e=this.rangeSegments();const t=e.length;const n=new tZ;if(t){const{rangeSize:i,reverse:r,rangeDistance:o}=this.options;const a=this.getRangeRadius();this.radius(this.radius()-i-o);for(let i=0;i<t;i++){const t=e[i];const o=this.slotAngle(t[r?"to":"from"]);const s=this.slotAngle(t[r?"from":"to"]);s-o!=0&&n.append(this.createRange(o,s,a,t))}}return n}createRange(e,t,n,i){const r=this.options.rangeSize;const o=new $a(this.arc.center,{radiusX:n+r/2,radiusY:n+r/2,startAngle:e,endAngle:t});return new JX(o,{stroke:{width:r,color:i.color,opacity:i.opacity,lineCap:i.lineCap}})}rangeSegments(){const e=this.options;const t=e.ranges||[];const n=t.length;const i=[];if(n){const{min:r,max:o,rangePlaceholderColor:a}=e;i.push(iZ(r,o,a));for(let e=0;e<n;e++){const n=DX(t[e],r,o);const s=i.length;for(let e=0;e<s;e++){const t=i[e];if(t.from<=n.from&&n.from<=t.to){i.push(iZ(n.from,n.to,n.color,n.opacity)),t.from<=n.to&&n.to<=t.to&&i.push(iZ(n.to,t.to,a,n.opacity)),t.to=n.from;break}}}}return i}getRangeRadius(){const{arc:e,options:t}=this;const{rangeSize:n,rangeDistance:i,majorTicks:{size:r}}=t;let o;return o=t.labels.position===yX?e.getRadiusX()-r-i-n:e.getRadiusX()-n,o}renderArc(e,t){const n=this.options;return this.arc=new $a(e,{radiusX:t,radiusY:t,startAngle:n.startAngle+ZX,endAngle:n.endAngle+ZX})}renderTicks(){const{arc:e,options:t}=this;const n=e.clone();this.majorTickAngles=this.tickAngles(e,t.majorUnit),this.majorTicks=nZ(n,this.majorTickAngles,t.majorUnit,t.majorTicks);const i=new tZ;i.append(this.majorTicks);const r=t.majorTicks.size;const o=t.minorTicks.size;if(this._tickDifference=r-o,t.labels.position===yX){const e=n.getRadiusX();n.setRadiusX(e-r+o).setRadiusY(e-r+o)}return this.minorTickAngles=this.normalizeTickAngles(this.tickAngles(e,t.minorUnit)),this.minorTicks=nZ(n,this.minorTickAngles,t.minorUnit,t.minorTicks),i.append(this.minorTicks),i}normalizeTickAngles(e){const t=this.options;const n=t.majorUnit/t.minorUnit;for(let t=e.length-1;t>=0;t--)t%n==0&&e.splice(t,1);return e}tickAngles(e,t){const n=this.options;const i=n.reverse;const r=n.max-n.min;const o=e.endAngle-e.startAngle;let a=r/t;let s=e.startAngle;let l=o/a;i&&(s+=o,l=-l),o>=360&&n.max%t==0&&(a-=1);const c=[];for(let e=0;e<a;e++)c.push(GN(s,3)),s+=l;return GN(s)<=e.endAngle&&c.push(s),c}radius(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)}repositionTicks(e,t,n){const i=n&&this._tickDifference||0;let r=this.arc;const o=r.getRadiusX();n&&this.options.labels.position===yX&&0!==i&&(r=this.arc.clone(),r.setRadiusX(o-i).setRadiusY(o-i));for(let n=0;n<e.length;n++){const i=r.pointAt(t[n]);const o=e[n].segments;const a=i.x-o[0].anchor().x;const s=i.y-o[0].anchor().y;e[n].transform((new xa).translate(a,s))}}}XN(rZ,{min:0,max:100,majorTicks:{size:15,align:bX,color:aV,width:vX,visible:!0},minorTicks:{size:10,align:bX,color:aV,width:vX,visible:!0},startAngle:-30,endAngle:210,labels:{position:bX,padding:2}});class oZ extends kl{constructor(e,t){super(e,t);const n=this.options;n.duration=Math.max(Math.abs(n.newAngle-n.oldAngle)/n.duration*1e3,1)}step(e){const t=this.options;const n=MN(t.oldAngle,t.newAngle,e);this.element.transform(xa().rotate(n,t.center))}}XN(oZ,{easing:wX,duration:fX}),yl.current.register(kX,oZ);const{Circle:aZ,Group:sZ,Path:lZ}=Wc;class cZ extends VX{setAngle(e){this.elements.transform(xa().rotate(e,this.center))}repaint(){const{scale:e,options:t}=this;const n=e.slotAngle(t._oldValue);const i=e.slotAngle(t.value);!1===t.animation.transitions?this.setAngle(i):new oZ(this.elements,cN(t.animation,{oldAngle:n,newAngle:i})).play()}render(){const{scale:e,options:t}=this;const n=new sZ;return!1!==t.animation&&cN(t.animation,{startAngle:0,center:e.arc.center,reverse:e.options.reverse}),n.append(this._renderNeedle(),this._renderCap()),this.elements=n,this.setAngle(_X),n}reflow(e){const t=this.center=e.center;const n=WN(this.options.length||1,.1,1.5);const i=this.radius=e.getRadiusX()*n;const r=this.capSize=Math.round(i*this.options.cap.size);this.bbox=ya.fromPoints(new ba(t.x-r,t.y-r),new ba(t.x+r,t.y+r))}_renderNeedle(){const e=this.scale.options.minorTicks.size;const t=this.center;const n=this.options.color;const i=new lZ({fill:{color:n},stroke:{color:n,width:vX}});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}_renderCap(){const e=this.options;const t=e.cap.color||e.color;const n=new Ia(this.center,this.capSize);return new aZ(n,{fill:{color:t},stroke:{color:t}})}}XN(cZ,{cap:{size:.05},arrow:{width:16,height:14},animation:{type:kX,duration:fX}});const dZ=Us;class hZ extends PX{reflow(e){const t=this.pointers;this.scale.reflow(e),this._initialPlotArea=this.scale.bbox;for(let e=0;e<t.length;e++)t[e].reflow(this.scale.arc),this._initialPlotArea=ya.union(this._initialPlotArea,t[e].bbox);this.fitScale(e),this.alignScale(e),this._buildVisual(this.gaugeArea,t,this.scale),this._draw()}_buildVisual(e,t,n){const i=this._visuals=new dZ;i.append(e),i.append(n.ticks),i.append(n.ranges),this._buildPointers(t),i.append(n.labelElements)}_buildPointers(e){for(let t=0;t<e.length;t++){const n=e[t];n.render(),this._visuals.append(n.elements),n.value(n.options.value)}}fitScale(e){const t=this.scale.arc;const n=this._initialPlotArea;const i=Math.abs(this.getDiff(n,e));let r=GN(i,3);let o=GN(-i,3);let a,s,l,c,d;let h=0;let u=0;for(;!(!(u++<100)||(h=d===l?h+1:0,h>5)||r!==c&&(a=this.getPlotBox(r,e,t),0<=a&&a<=2)||o!==c&&(l=this.getPlotBox(o,e,t),0<=l&&l<=2)||(c=a>0&&l>0?2*r:a<0&&l<0?2*o:GN((r+o)/2||1,3),s=this.getPlotBox(c,e,t),0<=s&&s<=2));)d=l,s>0?(o=c,l=s):(r=c,a=s)}getPlotBox(e,t,n){const i=this.scale;const r=this.pointers;const o=n.getRadiusX();const a=n.clone();a.setRadiusX(o+e).setRadiusY(o+e),i.arc=a,i.reflow(t),this.plotBbox=i.bbox;for(let e=0;e<r.length;e++)r[e].reflow(a),this.plotBbox=ya.union(this.plotBbox,r[e].bbox);return this.getDiff(this.plotBbox,t)}getDiff(e,t){return Math.min(t.width()-e.width(),t.height()-e.height())}alignScale(e){const t=this.plotBbox.center();const n=e.center();const i=t.x-n.x;const r=t.y-n.y;const{scale:o,pointers:a}=this;o.arc.center.x-=i,o.arc.center.y-=r,o.reflow(e);for(let e=0;e<a.length;e++)a[e].reflow(o.arc),this.plotBbox=ya.union(o.bbox,a[e].bbox)}_createModel(){const e=this.options;const t=e.pointer;const n=this.scale=new rZ(e.scale,this.contextService);this.pointers=[];const i=KV(t)?t:[t];for(let t=0;t<i.length;t++){const r=new cZ(n,cN({},i[t],{animation:{transitions:e.transitions}}));this.pointers.push(r)}}}XN(hZ,{transitions:!0,gaugeArea:{background:""}});class uZ extends rZ{rangeSegments(){const{min:e,max:t,rangePlaceholderColor:n,rangeLineCap:i}=this.options;return[{from:e,to:t,color:n,lineCap:i}]}hasRanges(){return!0}placeholderRangeAngle(e){const t=this.ranges.children[0].geometry();this.options.reverse?t.setEndAngle(e):t.setStartAngle(e)}addRange(e,t,n){const i=this.options.reverse;const r=this.slotAngle(i?t:e);const o=this.slotAngle(i?e:t);const a=this.createRange(r,o,this.getRangeRadius(),n);return this.ranges.append(a),a}}XN(uZ,{min:0,max:100,majorTicks:{visible:!1},minorTicks:{visible:!1},labels:{visible:!1},startAngle:0,endAngle:180,rangeLineCap:"round"});class pZ extends kl{constructor(e,t){super(e,t);const n=this.options;const i=Math.abs(n.newAngle-n.oldAngle)/n.duration*1e3;n.duration=WN(i,fX,800);const r=e.elements.options.get("stroke.color");const o=e.currentColor();r!==o&&(this.startColor=new bo(r),this.color=new bo(o))}step(e){const{options:t,startColor:n,color:i}=this;const r=MN(t.oldAngle,t.newAngle,e);if(this.element.angle(r),i){const t=GN(MN(n.r,i.r,e));const r=GN(MN(n.g,i.g,e));const o=GN(MN(n.b,i.b,e));this.element.stroke(new bo(t,r,o).toHex())}}}XN(pZ,{easing:wX,duration:fX}),yl.current.register(xX,pZ);class fZ extends VX{repaint(){const{scale:e,options:t}=this;const n=e.slotAngle(t._oldValue);const i=e.slotAngle(t.value);this.animation&&this.animation.abort(),!1===t.animation.transitions?(this.angle(i),this.stroke(this.currentColor())):(this.animation=new pZ(this,cN(t.animation,{oldAngle:n,newAngle:i})),this.animation.play())}angle(e){const t=this.elements.geometry();this.scale.options.reverse?t.setStartAngle(e):t.setEndAngle(e),this.scale.placeholderRangeAngle(e)}stroke(e){this.elements.stroke(e)}render(){if(this.elements)return;const{scale:e,options:t}=this;!1!==t.animation&&cN(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})}currentColor(){const{min:e,max:t}=this.scale.options;const{colors:n,color:i,value:r}=this.options;const o=eN(r)?r:e;if(n)for(let i=0;i<n.length;i++){const{color:r,from:a=e,to:s=t}=n[i];if(a<=o&&o<=s)return r}return i}reflow(){this.render(),this.bbox=this.elements.bbox()}}XN(fZ,{animation:{type:xX,duration:fX}});class mZ extends hZ{_initTheme(e){super._initTheme(e),this.options.color=this.options.color||(this.theme.pointer||{}).color}_createModel(){const e=this.options;const t=this.scale=new uZ(e.scale,this.contextService);const n=new fZ(t,cN({},{colors:e.colors,color:e.color,value:e.value,opacity:e.opacity,animation:{transitions:e.transitions}}));this.pointers=[n]}_buildPointers(e){for(let t=0;t<e.length;t++){const n=e[t];n.render(),n.value(n.options.value)}}_setValueOptions(e){this.options.value=e}currentColor(){const e=this.pointers[0];if(e)return e.currentColor()}centerLabelPosition(e,t){const n=this.getSize();const i=this.scale.arc.center;let r=i.x-e/2;let o=i.y-t/2;if(e<n.width){const t=r+e;r=Math.max(r,0),t>n.width&&(r-=t-n.width)}if(t<n.height){const e=this.scale.bbox;const n=e.bottomRight().y;const i=o+t;o=Math.max(o,e.origin.y),i>n&&(o-=i-n)}return{left:r,top:o}}}class gZ extends mZ{_createModel(){const e=this.options.scale;"number"!=typeof e.startAngle&&(e.startAngle=90),e.endAngle=e.startAngle+360,super._createModel()}}class vZ{constructor(e){this.setOptions(e),this.initProperties()}initProperties(){}setOptions(e){this.options=Object.assign({},this.options,e),this.quietZoneLength=this.options.addQuietZone?2*this.options.quietZoneLength:0}encode(e,t,n){const i=HN(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}}initValue(){}addQuietZone(){this.pattern.push(this.options.quietZoneLength||10)}addData(){}invalidCharacterError(e){throw new Error(`Character "${e}" is not valid for symbology ${this.name}.`)}}XN(vZ,{quietZoneLength:10,addQuietZone:!0,addCheckSum:!0});const _Z=Object.assign;class bZ extends vZ{initProperties(){super.initProperties(),_Z(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"})}initValue(e,t){this.pattern=[],this.value=e,this.width=t,this.totalUnits=0}addData(){const e=this.value;this.addPattern(this.START);for(let t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.addCheckSum(),this.addPattern(this.STOP),this.setBaseUnit()}setBaseUnit(){this.baseUnit=this.width/(this.totalUnits+this.quietZoneLength)}addCheckSum(){const e=this.value;let t=e.length;const n=this.getWeightedSum(e,t,this.cCheckSumTotal)%this.checkSumMod;if(this.checksum=String(n),this.addPattern(this.characterMap[n]),t++,t>=this.kCheckSumMinLength){let i=(n+this.getWeightedSum(e,t,this.kCheckSumTotal))%this.checkSumMod;this.checksum+=i,this.addPattern(this.characterMap[i])}}getWeightedSum(e,t,n){let i=0;for(let r=0;r<e.length;r++)i+=this.weightedValue(this.getValue(e.charAt(r)),t,r,n);return i}weightedValue(e,t,n,i){return((t-n)%i||i)*e}getValue(e){return isNaN(e)?(e!==this.DASH&&this.invalidCharacterError(e),this.DASH_VALUE):parseInt(e,10)}addCharacter(e){const t=this.getValue(e);const n=this.characterMap[t];this.addPattern(n)}addPattern(e){let t;for(let n=0;n<e.length;n++)t=parseInt(e.charAt(n),10),this.pattern.push(t),this.totalUnits+=t}}XN(bZ,{addCheckSum:!0});const wZ=Object.assign;class yZ extends vZ{initProperties(){super.initProperties(),wZ(this,{minBaseUnitLength:.7})}addData(){const e=this.value;this.addStart();for(let t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.pushCheckSum(),this.addStop(),this.prepareValues()}addCharacter(e){const t=this.characterMap[e];t||this.invalidCharacterError(e),this.addBase(t)}addBase(){}}class kZ extends yZ{initProperties(){super.initProperties(),wZ(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"}}})}initValue(e,t,n){this.width=t,this.height=n,this.value=e,this.dataLength=e.length,this.pattern=[],this.patternString=""}prepareValues(){const e=this.minBaseUnitLength;const t=this.minRatio;const n=Math.ceil(Math.max(.15*this.width,24));let i;let r=this.maxRatio;if(this.height<n)throw new Error(`Insufficient height for Code39 encoding: the current height is ${this.height}px and the minimum height is ${n}px.`);for(i=this.getBaseUnit(r);i<e&&r>t;)r=parseFloat((r-.1).toFixed(1)),i=this.getBaseUnit(r);if(i<e){let n=Math.ceil(this.getBaseWidth(t)*e);throw new Error(`Insufficient width for Code39 encoding: the current width is ${this.width}px and the minimum width for value "${this.value}" is ${n}px.`)}this.ratio=r,this.baseUnit=i,this.patternString=this.patternString.substring(0,this.patternString.length-1),this.pattern=this.pattern.concat(this.patternString.replace(/ratio/g,r).split(this.splitCharacter))}getBaseUnit(e){return this.width/this.getBaseWidth(e)}getBaseWidth(e){const t=3*(e+2);return this.quietZoneLength+t*(this.dataLength+2)+this.gapWidth*(this.dataLength+1)}addStart(){this.addPattern(this.characterMap.START.pattern),this.addCharacterGap()}addBase(e){this.addPattern(e.pattern),this.addCharacterGap()}addStop(){this.addPattern(this.characterMap.START.pattern)}addPattern(e){for(let t=0;t<e.length;t++)this.patternString+=this.patternMappings[e.charAt(t)]}addCharacterGap(){this.patternString+=this.gapWidth+this.splitCharacter}}XN(kZ,{addCheckSum:!1});const xZ={addCharacter(e){this.characterMap[e]?this.addBase(this.characterMap[e]):e.charCodeAt(0)>127?this.invalidCharacterError(e):this.addExtended(e.charCodeAt(0))},addExtended(e){let t;for(let n=0;n<this.extendedMappings.length;n++)if(t=this.extendedMappings[n].call(this,e),t){for(let e=0;e<t.length;e++){const n=t[e];this.addBase(n)}return void(this.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){let t;let n;if(this.specialAsciiCodes[e]){t=[];for(let n=0;n<this.specialAsciiCodes[e].length;n++)t.push(this.characterMap[this.shiftCharacters[3]]),t.push(this.characterMap[this.specialAsciiCodes[e][n]])}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"]};const CZ=Object.assign;class SZ extends yZ{initProperties(){super.initProperties(),CZ(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"}})}initValue(e,t,n){this.value=e,this.width=t,this.height=n,this.pattern=[],this.values=[],this.dataLength=e.length}prepareValues(){let 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){const e=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 ${e}px.`)}}setBaseUnit(){this.baseUnit=this.width/(9*(this.dataLength+2+2)+this.quietZoneLength+1)}addStart(){let e=this.characterMap.START.pattern;this.addPattern(e)}addStop(){this.addStart(),this.pattern.push(this.characterMap.TERMINATION_BAR)}addBase(e){this.addPattern(e.pattern),this.values.push(e.value)}pushCheckSum(){const e=this._getCheckValues();let t;this.checksum=e.join("");for(let n=0;n<e.length;n++)t=this.characterMap[this._findCharacterByValue(e[n])],this.addPattern(t.pattern)}_getCheckValues(){const e=this.values;const t=e.length;let n=0;let i;let r;let o;for(o=t-1;o>=0;o--)n+=this.weightedValue(e[o],t-o,this.cCheckSumTotal);for(i=n%this.checkSumMod,n=this.weightedValue(i,1,this.kCheckSumTotal),o=t-1;o>=0;o--)n+=this.weightedValue(e[o],t-o+1,this.kCheckSumTotal);return r=n%this.checkSumMod,[i,r]}_findCharacterByValue(e){for(let t in this.characterMap)if(this.characterMap[t].value===e)return t}weightedValue(e,t,n){return(t%n||n)*e}addPattern(e){let t;for(let n=0;n<e.length;n++)t=parseInt(e.charAt(n),10),this.pattern.push(t)}}const TZ=/^\d+$/;const MZ=Object.assign;const AZ=/^\d+$/;const DZ=/^[a-z0-9]+$/i;const EZ=Object.assign;class IZ{constructor(e){this.encoding=e,this.initProperties()}initProperties(){}addStart(){}is(){}isCode(){return!1}move(){}pushState(){}}class zZ extends IZ{constructor(e,t){super(e),this.states=t,this._initMoves(t)}initProperties(){super.initProperties(),cN(this,{FNC4:"FNC4",SHIFT:98})}addStart(){this.encoding.addPattern(this.START)}is(e,t){let n=e.charCodeAt(t);return this.isCode(n)}move(e){let t=0;for(;!this._moves[t].call(this,e)&&t<this._moves.length;)t++}pushState(e){let t,n=this.states,i=e.value,r=i.length;if(TN("C",n)){let t=i.substr(e.index).match(/\d{4,}/g);t&&(r=i.indexOf(t[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++}_initMoves(e){this._moves=[],TN(this.FNC4,e)&&this._moves.push(this._moveFNC),TN(this.shiftKey,e)&&this._moves.push(this._shiftState),this._moves.push(this._moveState)}_moveFNC(e){if(e.fnc)return e.fnc=!1,e.previousState===this.key}_shiftState(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}_moveState(){return this.encoding.addPattern(this.MOVE),!0}}const PZ={};PZ.A=class extends zZ{initProperties(){super.initProperties(),EZ(this,{key:"A",shiftKey:"B",MOVE:101,START:103})}isCode(e){return 0<=e&&e<96}getValue(e){return e<32?e+64:e-32}},PZ.B=class extends zZ{initProperties(){super.initProperties(),EZ(this,{key:"B",shiftKey:"A",MOVE:100,START:104})}isCode(e){return 32<=e&&e<128}getValue(e){return e-32}},PZ.C=class extends IZ{initProperties(){super.initProperties(),EZ(this,{key:"C",MOVE:99,START:105})}addStart(){this.encoding.addPattern(this.START)}is(e,t){let n=BZ(e,t,4);return(t+4<=e.length||2===e.length)&&AZ.test(n)}move(){this.encoding.addPattern(this.MOVE)}pushState(e){let t;for(;(t=BZ(e.value,e.index,2))&&AZ.test(t)&&2===t.length;)this.encoding.addPattern(parseInt(t,10)),e.index+=2}getValue(e){return e}},PZ.FNC4=class extends IZ{constructor(e,t){super(e),this._initSubStates(t)}initProperties(){super.initProperties(),EZ(this,{key:"FNC4",dependentStates:["A","B"]})}addStart(e){let t=e.value.charCodeAt(0)-128,n=this._getSubState(t);this.encoding[n].addStart()}is(e,t){let n=e.charCodeAt(t);return this.isCode(n)}isCode(e){return 128<=e&&e<256}pushState(e){let t=this._initSubState(e),n=this.encoding,i=t.value.length;let r;if(e.index+=i,i<3)for(;t.index<i;t.index++)r=t.value.charCodeAt(t.index),t.state=this._getSubState(r),t.previousState!==t.state&&(t.previousState=t.state,n[t.state].move(t)),n.addPattern(n[t.state].MOVE),n.addPattern(n[t.state].getValue(r));else t.state!==t.previousState&&n[t.state].move(t),this._pushStart(t),n.pushData(t,this.subStates),e.index<e.value.length&&this._pushStart(t);e.fnc=!0,e.state=t.state}_pushStart(e){this.encoding.addPattern(this.encoding[e.state].MOVE),this.encoding.addPattern(this.encoding[e.state].MOVE)}_initSubState(e){const 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}_initSubStates(e){this.subStates=[];for(let t=0;t<e.length;t++)TN(e[t],this.dependentStates)&&this.subStates.push(e[t])}_getSubState(e){for(let t=0;t<this.subStates.length;t++)if(this.encoding[this.subStates[t]].isCode(e))return this.subStates[t]}_getAll(e,t){let n;let i="";let r=t;for(;(n=e.charCodeAt(r++))&&this.isCode(n);)i+=String.fromCharCode(n-128);return i}},PZ.FNC1=class extends IZ{constructor(e,t){super(e),this.states=t}initProperties(){super.initProperties(),EZ(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})}addStart(){this.encoding[this.startState].addStart()}is(){return TN(this.key,this.states)}pushState(e){let t,n,i,r=this.encoding,o=e.value.replace(/\s/g,""),a=new RegExp("["+this.startAI+this.endAI+"]","g"),s=e.index,l={state:this.startState};r.addPattern(this.START);for(;;){if(l.index=0,i=o.charAt(s)===this.startAI?2:0,t=i>0?this.getBySeparator(o,s):this.getByLength(o,s),t.ai.length)n=s+i+t.id.length+t.ai.length;else if(n=o.indexOf(this.startAI,s+1),n<0){if(s+t.ai.max+t.id.length+i<o.length)throw new Error("Separators are required after variable length identifiers");n=o.length}if(l.value=o.substring(s,n).replace(a,""),this.validate(t,l.value),r.pushData(l,this.dependentStates),n>=o.length)break;s=n,l.state!==this.startState&&(r[this.startState].move(l),l.state=this.startState),t.ai.length||r.addPattern(this.START)}e.index=e.value.length}validate(e,t){let n=t.substr(e.id.length),i=e.ai;if(!i.type&&!AZ.test(n))throw new Error("Application identifier "+e.id+" is numeric only but contains non numeric character(s).");if("alphanumeric"===i.type&&!DZ.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(e,t){let n;let i;for(let r=2;r<=4;r++)if(n=BZ(e,t,r),i=this.getApplicationIdentifier(n)||this.getApplicationIdentifier(n.substring(0,n.length-1)),i)return{id:n,ai:i};this.unsupportedAIError(n)}unsupportedAIError(e){throw new Error("'"+e+"' is not a supported Application Identifier")}getBySeparator(e,t){let 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}}getApplicationIdentifier(e){let t=this.applicationIdentifiers,n=t.multiKey;if(t[e])return t[e];for(let t=0;t<n.length;t++){if(n[t].ids&&TN(e,n[t].ids))return n[t].type;if(n[t].ranges){let i=n[t].ranges;for(let r=0;r<i.length;r++)if(i[r][0]<=e&&e<=i[r][1])return n[t].type}}}};class LZ extends vZ{constructor(e){super(e),this._initStates()}initProperties(){super.initProperties(),EZ(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})}_initStates(){for(let e=0;e<this.states.length;e++)this[this.states[e]]=new PZ[this.states[e]](this,this.states)}initValue(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}addData(){let 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())}pushData(e,t){for(;this[e.state].pushState(e),!(e.index>=e.value.length);)if(e.shifted){let t=e.state;e.state=e.previousState,e.previousState=t,e.shifted=!1}else e.previousState=e.state,e.state=this.getNextState(e,t),this[e.state].move(e)}addStart(e){this[e.state].addStart(e),this.position=1}addCheckSum(){this.checksum=this.checkSum%103,this.addPattern(this.checksum)}addStop(){this.addPattern(this.STOP)}setBaseUnit(){this.baseUnit=this.width/(this.totalUnits+this.quietZoneLength)}addPattern(e){const t=this.characterMap[e].toString();let n;for(let e=0;e<t.length;e++)n=parseInt(t.charAt(e),10),this.pattern.push(n),this.totalUnits+=n;this.checkSum+=e*this.position++}getNextState(e,t){for(let 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))}}function BZ(e,t,n){return e.substring(t,t+n)}const HZ=Object.assign;class RZ extends vZ{initProperties(){super.initProperties(),HZ(this,{characterMap:["12121212","12121221","12122112","12122121","12211212","12211221","12212112","12212121","21121212","21121221"],START:"21",STOP:"121",checkSumType:"",checkSums:FZ})}initValue(e,t){this.pattern=[],this.value=e,this.checkSumLength=0,this.width=t}setBaseUnit(){this.baseUnit=this.width/(12*(this.value.length+this.checkSumLength)+this.quietZoneLength+7)}addData(){const e=this.value;this.addPattern(this.START);for(let t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.addCheckSum(),this.addPattern(this.STOP),this.setBaseUnit()}addCharacter(e){const t=this.characterMap[e];t||this.invalidCharacterError(e),this.addPattern(t)}addPattern(e){for(let t=0;t<e.length;t++)this.pattern.push(parseInt(e.charAt(t),10))}addCheckSum(){const e=this.checkSums[this.checkSumType].call(this.checkSums,this.value);this.checksum=e.join("");for(let t=0;t<e.length;t++)this.checkSumLength++,this.addPattern(this.characterMap[e[t]])}}const FZ={Modulo10(e){let 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(e){let t,n,i=0,r=e.length;for(let n=0;n<r;n++)t=((r-n)%6||6)+1,i+=t*e.charAt(n);return n=(11-i%11)%11,10!==n?[n]:[1,0]},Modulo11Modulo10(e){let t,n=this.Modulo11(e);return t=e+n[0],n.concat(this.Modulo10(t))},Modulo10Modulo10(e){let t,n=this.Modulo10(e);return t=e+n[0],n.concat(this.Modulo10(t))}};const OZ=Object.assign;class VZ extends vZ{initProperties(){super.initProperties(),OZ(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]}})}initValue(e,t,n){const 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}addData(){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)}addSide(e,t){for(let n=0;n<e.length;n++)t&&parseInt(this.keyTable[t].charAt(n),10)?this.addPieces(Array.prototype.slice.call(this.characterMap.digits[e.charAt(n)]).reverse(),!0):this.addPieces(this.characterMap.digits[e.charAt(n)],!0)}addPieces(e,t){for(let n=0;n<e.length;n++)t?this.pattern.push({y1:0,y2:.95*this.options.height,width:e[n]}):this.pattern.push(e[n])}calculateChecksum(){let e=0,t=0,n=this.value.split("").reverse().join("");for(let 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}}const NZ=Object.assign;const $Z={code11:bZ,code39:kZ,code39extended:class extends kZ{initProperties(){super.initProperties(),cN(this,xZ,{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}}})}},code93:SZ,code93extended:class extends SZ{initProperties(){super.initProperties(),cN(this,xZ,{name:"Code 93 extended",pushCheckSum:function(){const e=this._getCheckValues();let t;this.checksum=e.join("");for(let n=0;n<e.length;n++)if(t=e[n],this.shiftValuesAsciiCodes[t])this.addExtended(this.shiftValuesAsciiCodes[t]);else{const e=this._findCharacterByValue(t);this.addPattern(this.characterMap[e].pattern)}}})}},code128:class extends LZ{initProperties(){super.initProperties(),EZ(this,{name:"Code 128",states:["C","B","A","FNC4"]})}},code128a:class extends LZ{initProperties(){super.initProperties(),EZ(this,{name:"Code 128 A",states:["A"]})}},code128b:class extends LZ{initProperties(){super.initProperties(),EZ(this,{name:"Code 128 B",states:["B"]})}},code128c:class extends LZ{initProperties(){super.initProperties(),EZ(this,{name:"Code 128 C",states:["C"]})}},"gs1-128":class extends LZ{initProperties(){super.initProperties(),EZ(this,{name:"Code GS1-128",states:["FNC1","C","B"]})}},msimod10:class extends RZ{initProperties(){super.initProperties(),HZ(this,{name:"MSI Modulo10",checkSumType:"Modulo10"})}},msimod11:class extends RZ{initProperties(){super.initProperties(),HZ(this,{name:"MSI Modulo11",checkSumType:"Modulo11"})}},msimod1010:class extends RZ{initProperties(){super.initProperties(),HZ(this,{name:"MSI Modulo10 Modulo10",checkSumType:"Modulo10Modulo10"})}},msimod1110:class extends RZ{initProperties(){super.initProperties(),HZ(this,{name:"MSI Modulo11 Modulo10",checkSumType:"Modulo11Modulo10"})}},postnet:class extends vZ{initProperties(){super.initProperties(),MZ(this,{name:"Postnet",START:"2",VALID_CODE_LENGTHS:[5,9,11],DIGIT_SEPARATOR:"-",characterMap:["22111","11122","11212","11221","12112","12121","12211","21112","21121","21211"]})}initValue(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()}addData(){const e=this.value;this.addPattern(this.START);for(let t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.addCheckSum(),this.addPattern(this.START),this.pattern.pop()}addCharacter(e){const t=this.characterMap[e];this.checkSum+=parseInt(e,10),this.addPattern(t)}addCheckSum(){this.checksum=(10-this.checkSum%10)%10,this.addCharacter(this.checksum)}setBaseUnit(){this.baseUnit=this.width/(10*(this.value.length+1)+3+this.quietZoneLength)}validate(e){if(TZ.test(e)||this.invalidCharacterError(e.match(/[^0-9]/)[0]),!TN(e.length,this.VALID_CODE_LENGTHS))throw new Error("Invalid value length. Valid lengths for the Postnet symbology are "+this.VALID_CODE_LENGTHS.join(",")+".")}addPattern(e){let t;for(let n=0;n<e.length;n++)t=this.height-this.baseHeight*e.charAt(n),this.pattern.push({width:1,y1:t,y2:this.height}),this.pattern.push(1)}},ean8:class extends VZ{initProperties(){super.initProperties(),NZ(this,{name:"EAN 8"})}initValue(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)}},ean13:VZ};function UZ(e,t){const n=e.style.display;"canvas"===t&&(e.style.display="block");const i={width:e.clientWidth,height:e.clientHeight};return e.style.display=n,i}XN(class{constructor(e,t,n=g$){this.options=cN({},this.options,t),this.element=e,this.onError=n,this._initElement(),this._initSurface(),this._setOptions(t),t&&HN(t.value)&&this.redraw()}destroy(){this._destroySurface()}_initElement(){YV(this.element,"k-barcode")}_initSurface(){const{options:e,surface:t}=this;t&&t.options.type===e.renderAs||(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())}_createSurface(){return Fc.create(this.surfaceElement,{type:this.options.renderAs})}_destroySurface(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())}_initSurfaceElement(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.surfaceElement.style.position="relative",this.element.appendChild(this.surfaceElement))}_destroySurfaceElement(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)}setOptions(e){this._setOptions(e),this._initSurface(),this.redraw()}redraw(){let e=this._getSize();this.surface.clear(),this.surface.setSize({width:e.width,height:e.height}),this.createVisual(),this.surface.draw(this.visual)}getSize(){return{width:this.element.offsetWidth,height:this.element.offsetHeight}}_resize(){this.redraw()}createVisual(){this.visual=this._render()}_render(){const e=this.options;const t=e.value;const n=e.text;const i=mN(n.margin);const r=this._getSize();const o=e.border||{};const a=this.encoding;const s=new hU(0,0,r.width,r.height).unpad(o.width).unpad(e.padding);let l=s.height();let c;let d;let h;const u=new Us;this.contentBox=s,u.append(this._getBackground(r)),n.visible&&(h=ha(t,{font:n.font}).height,l-=h+i.top+i.bottom);try{c=a.encode(t,s.width(),l)}catch(e){return this.onError(e),u}return n.visible&&(d=t,e.checksum&&HN(a.checksum)&&(d+=" "+a.checksum),u.append(this._getText(d))),this.barHeight=l,this._bandsGroup=this._getBands(c.pattern,c.baseUnit),u.append(this._bandsGroup),u}exportVisual(){return this._render()}_getSize(){const e=UZ(this.element,this.options.renderAs);const t=new wa(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}value(e){if(!HN(e))return this.options.value;this.options.value=String(e),this.redraw()}_getBands(e,t){const n=this.contentBox;let i=n.x1;let r;let o;const a=new Us;for(let s=0;s<e.length;s++){if(o=dN(e[s])?e[s]:{width:e[s],y1:0,y2:this.barHeight},r=o.width*t,s%2){const e=ya.fromPoints(new ba(i,o.y1+n.y1),new ba(i+r,o.y2+n.y1));const t=Rs.fromRect(e,{fill:{color:this.options.color},stroke:null});a.append(t)}i+=r}return a}_getBackground(e){const t=this.options;const n=t.border||{};const i=new hU(0,0,e.width,e.height).unpad(n.width/2);return Rs.fromRect(i.toRect(),{fill:{color:t.background},stroke:{color:n.width?n.color:"",width:n.width,dashType:n.dashType}})}_getText(e){const t=this.options.text;const n=this._textbox=new RU(e,{font:t.font,color:t.color,align:"center",vAlign:"bottom",margin:t.margin});return n.reflow(this.contentBox),n.renderVisual(),n.visual}_setOptions(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),!$Z[this.type])throw new Error(`Encoding '${this.type}' is not supported.`);this.encoding=new $Z[this.type],this.options=cN({},this.options,e)}},{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}});const WZ=Object.assign;function jZ(e,t){let n=[];let i=0;for(;i<e.length;)n.push(e.substring(i,i+t)),i+=t;return n}function qZ(e,t){let n=Number(e).toString(2);return n.length<t&&(n=new Array(t-n.length+1).join(0)+n),n}function GZ(e){return parseInt(e,2)}class KZ{constructor(e){this.matrix=e,this.row=e.length-1,this.column=e.length-1,this.startColumn=this.column,this.dir=-1,this.c=0}move(){this.row+=this.dir*this.c,this.c^=1,this.column=this.startColumn-this.c}getNextCell(){for(;void 0!==this.matrix[this.row][this.column];)this.move(),(this.row<0||this.row>=this.matrix.length)&&(this.dir=-this.dir,this.startColumn-=8!==this.startColumn?2:3,this.column=this.startColumn,this.row=this.dir<0?this.matrix.length-1:0);return{row:this.row,column:this.column}}getNextRemainderCell(){if(this.move(),void 0===this.matrix[this.row][this.column])return{row:this.row,column:this.column}}}class YZ{constructor(e,t){this.dataString=e,this.version=t}}const QZ="alphanumeric";const XZ=/^\d+/;const ZZ="A-Z0-9 $%*+./:-";const JZ=new RegExp("^[A-Z $%*+./:-]+");const eJ=new RegExp("^["+ZZ+"]+");const tJ=new RegExp("^[^"+ZZ+"]+");function nJ(e,t,n,i,r){let o,a,s=XZ.exec(e),l=s?s[0]:"",c=JZ.exec(e),d=c?c[0]:"",h=eJ.exec(e),u=h?h[0]:"";return l&&(l.length>=t||e.length===l.length||l.length>=n&&!eJ.test(e.charAt(l.length)))?(o="numeric",a=l):u&&(e.length===u.length||u.length>=i||r===QZ)?(o=QZ,a=l||d):(o="byte",a=u?u+tJ.exec(e.substring(u.length))[0]:tJ.exec(e)[0]),{mode:o,modeString:a}}class iJ{constructor(){this.initProperties()}initProperties(){WZ(this,{modeIndicator:"",bitsInCharacterCount:[]})}getVersionIndex(e){return e<10?0:e>26?2:1}getBitsCharacterCount(e){return this.bitsInCharacterCount[this.getVersionIndex(e||40)]}getModeCountString(e,t){return this.modeIndicator+qZ(e,this.getBitsCharacterCount(t))}encode(){}getStringBitsLength(){}getValue(){}}const rJ="numeric";const oJ="alphanumeric";const aJ="byte";let sJ={[rJ]:new class extends iJ{initProperties(){super.initProperties(),WZ(this,{bitsInCharacterCount:[10,12,14],modeIndicator:"0001"})}getValue(e){return parseInt(e,10)}encode(e,t){let n=jZ(e,3),i=this.getModeCountString(e.length,t);let r;for(r=0;r<n.length-1;r++)i+=qZ(n[r],10);return i+qZ(n[r],1+3*n[r].length)}getStringBitsLength(e,t){let n=e%3;return 4+this.getBitsCharacterCount(t)+10*Math.floor(e/3)+3*n+(0===n?0:1)}},[oJ]:new class extends iJ{initProperties(){super.initProperties(),WZ(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"})}getValue(e){return this.characters[e]}encode(e,t){let n,i=jZ(e,2),r=this.getModeCountString(e.length,t);let o;for(o=0;o<i.length-1;o++)n=45*this.getValue(i[o].charAt(0))+this.getValue(i[o].charAt(1)),r+=qZ(n,11);return n=2===i[o].length?45*this.getValue(i[o].charAt(0))+this.getValue(i[o].charAt(1)):this.getValue(i[o].charAt(0)),r+qZ(n,1+5*i[o].length)}getStringBitsLength(e,t){return 4+this.getBitsCharacterCount(t)+11*Math.floor(e/2)+e%2*6}},[aJ]:new class extends iJ{initProperties(){super.initProperties(),WZ(this,{bitsInCharacterCount:[8,16,16],modeIndicator:"0100"})}getValue(e){let t=e.charCodeAt(0);if(t<=127||160<=t&&t<=255)return t;throw new Error(`Unsupported character in QR Code: "${e}".`)}encode(e,t){let n=this,i=n.getModeCountString(e.length,t);for(let t=0;t<e.length;t++)i+=qZ(n.getValue(e.charAt(t)),8);return i}getStringBitsLength(e,t){return 4+this.getBitsCharacterCount(t)+8*e}}};const lJ=[{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}}];function cJ(e,t){let n=0,i=lJ.length-1,r=Math.floor(lJ.length/2);do{e<lJ[r][t].totalDataCodewords?i=r:n=r,r=n+Math.floor((i-n)/2)}while(i-n>1);return e<=lJ[n][t].totalDataCodewords?r+1:i+1}class dJ{getEncodingResult(e,t){let n=function(e){let t,n=[],i=0;let r=e;for(n.push(nJ(r,8,5,8,t)),t=n[0].mode,r=r.substr(n[0].modeString.length);r.length>0;){let e=nJ(r,17,9,16,t);e.mode!==t?(t=e.mode,n.push(e),i++):n[i].modeString+=e.modeString,r=r.substr(e.modeString.length)}return n}(e),i=function(e){let t,n=0;for(let i=0;i<e.length;i++)t=sJ[e[i].mode],n+=t.getStringBitsLength(e[i].modeString.length);return Math.ceil(n/8)}(n),r=cJ(i,t),o=function(e,t){let n,i="";for(let r=0;r<e.length;r++)n=sJ[e[r].mode],i+=n.encode(e[r].modeString,t);return i}(n,r);return new YZ(o,r)}}class hJ{constructor(){this.initProperties(),this.mode=sJ[this.encodingMode]}initProperties(){WZ(this,{encodingMode:"byte",utfBOM:"111011111011101110111111",initialModeCountStringLength:20,ranges:[128,2048,65536,2097152,67108864]})}getEncodingResult(e,t){let n=this.encode(e),i=cJ(this.getDataCodewordsCount(n),t),r=this.mode.getModeCountString(n.length/8,i)+n;return new YZ(r,i)}getDataCodewordsCount(e){let t=e.length;return Math.ceil((this.initialModeCountStringLength+t)/8)}encode(e){let t=this.utfBOM;for(let n=0;n<e.length;n++)t+=this.encodeCharacter(e.charCodeAt(n));return t}encodeCharacter(e){let t=this.getBytesCount(e),n=t-1,i="";if(1===t)i=qZ(e,8);else{let r=8-t;for(let t=0;t<n;t++)i=qZ(e>>6*t&63|128,8)+i;i=(e>>6*n|255>>r<<r).toString(2)+i}return i}getBytesCount(e){let t=this.ranges;for(let n=0;n<t.length;n++)if(e<t[n])return n+1}}let uJ="0000",pJ={1:0},fJ={0:1},mJ={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},gJ=[1,0,1,1,1],vJ=[1,0,1],_J={L:"01",M:"00",Q:"11",H:"10"},bJ=["11101100","00010001"],wJ=[(e,t)=>(e+t)%2==0,(e,t)=>e%2==0,(e,t)=>t%3==0,(e,t)=>(e+t)%3==0,(e,t)=>(Math.floor(e/2)+Math.floor(t/3))%2==0,(e,t)=>e*t%2+e*t%3==0,(e,t)=>(e*t%2+e*t%3)%2==0,(e,t)=>((e+t)%2+e*t%3)%2==0];const yJ=[[1,0],[1,25,0]];function kJ(e,t,n,i){for(let r=0;r<e.length;r++)e[r][n][i]=t}function xJ(e,t,n,i){for(let r=0;r<wJ.length;r++)e[r][n][i]=wJ[r](n,i)?1^t:parseInt(t,10)}function CJ(e,t){let n=[];for(let i=e.length-2;i>=0;i--)n[i]=e[i]^t[i];return n}function SJ(e,t){let n=[];for(let i=0;i<e.length;i++)for(let 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]=pJ[fJ[n[i+r]]^fJ[(e[i]+t[r])%255]];return n}function TJ(e,t){let n=[],i=e.length-1;do{n[i]=fJ[(e[i]+t)%255],i--}while(void 0!==e[i]);return n}function MJ(e,t){let n,i,r=yJ[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=TJ(a,pJ[o[o.length-1]]),a.splice(0,1),o=CJ(n,o);for(i=o.length-1;i>=0;i--)l[t-1-i]=qZ(o[i],8);return l}function AJ(e,t,n){let i=GZ(t),r=t.length-1,o=e<<r,a=qZ(e,n-r),s=function(e,t){let n=t.toString(2).length,i=e.toString(2).length;let r=e;do{r^=t<<i-n,i=r.toString(2).length}while(i>=n);return r}(o,i);return s=a+qZ(s,r),s}function DJ(e,t){return parseInt(e.charAt(t),10)}function EJ(e,t){let n,i,r=e[0],o=0,a=t.length;for(n=0,i=8;n<=8;n++)6!==n&&kJ(e,DJ(t,a-1-o++),n,i);for(n=8,i=7;i>=0;i--)6!==i&&kJ(e,DJ(t,a-1-o++),n,i);for(o=0,i=r.length-1,n=8;i>=r.length-8;i--)kJ(e,DJ(t,a-1-o++),n,i);for(kJ(e,1,r.length-8,8),n=r.length-7,i=8;n<r.length;n++)kJ(e,DJ(t,a-1-o++),n,i)}function IJ(e,t){let n,i,r,o=e[0].length,a=o-11,s=o-11;for(let o=0;o<t.length;o++)n=Math.floor(o/3),i=o%3,r=DJ(t,t.length-o-1),kJ(e,r,0+n,a+i),kJ(e,r,s+i,0+n)}function zJ(e,t,n,i){let r,o=t.length+2,a=t.length+1;for(let s=0;s<t.length;s++)for(let l=s;l<o-s;l++)r=t[s],kJ(e,r,n+l,i+s),kJ(e,r,n+s,i+l),kJ(e,r,n+a-l,i+a-s),kJ(e,r,n+a-s,i+a-l)}function PJ(e,t,n,i){let r=n,o=i,a=e[0];do{kJ(e,0,r,i),kJ(e,0,n,o),r+=t[0],o+=t[1]}while(r>=0&&r<a.length)}function LJ(e,t,n,i,r){t[e][i]=(t[e][i]<<1^r)%128,93===t[e][i]&&(n[e]+=40)}function BJ(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 HJ(e,t){let 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 RJ(e,t,n){let i=function(e){return e&&e.toLowerCase().indexOf("utf_8")>=0?new hJ:new dJ}(n),r=i.getEncodingResult(e,t),o=r.version,a=lJ[o-1][t],s=function(e,t){let n,i,r,o,a,s=0,l=[],c=[],d=t.groups;for(let h=0;h<d.length;h++){r=d[h][0];for(let u=0;u<r;u++){i=d[h][1],n=[],o=[];for(let t=1;t<=i;t++)a=e.substring(s,s+8),n.push(a),o[i-t]=GZ(a),s+=8;l.push(n),c.push(MJ(o,t.errorCodewordsPerBlock))}}return[l,c]}(function(e,t){let n=8*t,i=0,r=0;let o=e;for(;o.length<n&&i<4;)o+=uJ.charAt(i++);for(o.length%8!=0&&(o+=new Array(9-o.length%8).join("0"));o.length<n;)o+=bJ[r],r^=1;return o}(r.dataString,a.totalDataCodewords),a),l=function(e){let t=[],n=17+4*e;for(let e=0;e<wJ.length;e++){t[e]=new Array(n);for(let i=0;i<n;i++)t[e][i]=new Array(n)}return t}(o);!function(e){let t=e[0].length;zJ(e,gJ,0,0),PJ(e,[-1,-1],7,7),zJ(e,gJ,t-7,0),PJ(e,[1,-1],t-8,7),zJ(e,gJ,0,t-7),PJ(e,[-1,1],7,t-8)}(l),function(e,t){if(t<2)return;let n,i,r=e[0],o=r.length,a=Math.floor(t/7),s=[6],l=0;for((n=mJ[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(let t=0;t<s.length;t++)for(let n=0;n<s.length;n++)void 0===r[s[t]][s[n]]&&zJ(e,vJ,s[t]-2,s[n]-2)}(l,o),function(e){let t=1,n=e[0].length;for(let i=8;i<n-8;i++)kJ(e,t,6,i),kJ(e,t,i,6),t^=1}(l),o>=7&&IJ(l,qZ(0,18)),EJ(l,qZ(0,15)),function(e,t){let n,i,r,o=new KZ(e[0]);for(let a=0;a<t.length;a++)for(n=t[a],i=0;n.length>0;){for(let t=0;t<n.length;t++)for(let a=0;a<8;a++)r=o.getNextCell(),xJ(e,n[t][i].charAt(a),r.row,r.column);for(i++;n[0]&&i===n[0].length;)n.splice(0,1)}for(;r=o.getNextRemainderCell();)xJ(e,0,r.row,r.column)}(l,s);let c=function(e){let 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(let n=0;n<l;n++)for(let c=0;c<l;c++)for(let 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),LJ(d,a,i,0,t[n][c]),LJ(d,a,i,1,t[c][n]),BJ(d,i,r,t[n][c],s,0),BJ(d,i,r,t[c][n],s,1);let c,d=l*l,h=Number.MAX_VALUE;for(n=0;n<i.length;n++)i[n]+=HJ(o[n],d),i[n]<h&&(h=i[n],c=n);return c}(l),d=l[c];return o>=7&&IJ([d],function(e){return AJ(e,"1111100100101",18)}(o)),EJ([d],function(e){let t,n="";if(0===GZ(e))return"101010000010010";t=AJ(GZ(e),"10100110111",15);for(let e=0;e<t.length;e++)n+=t.charAt(e)^"101010000010010".charAt(e);return n}(_J[t]+qZ(c,3))),d}!function(){let e;let t;for(t=1;t<255;t++)e=2*fJ[t-1],e>255&&(e^=285),fJ[t]=e,pJ[e]=t;e=2*fJ[t-1]^285,fJ[t]=e,fJ[-1]=0}(),function(){for(let e=2;e<=68;e++){let t=yJ[e-1],n=[e,0];yJ[e]=SJ(t,n)}}();const FJ=Math.round;const OJ=[[0,1],[1,1],[1,2],[2,2],[2,1],[3,1],[3,0],[2,0],[2,-1],[1,-1],[1,0]];const VJ=[[0,1],[1,1],[1,0]];const NJ=200,$J="L",UJ="#fff",WJ="#000",jJ=1,qJ=7;XN(class{constructor(e,t,n=g$){this.options=cN({},this.options,t),this.element=e,this.wrapper=this.element,this.onError=n,this._initElement(),this._initSurface(),this.setOptions(t)}destroy(){this._destroySurface()}_initElement(){YV(this.element,"k-qrcode")}_initSurface(){const{options:e,surface:t}=this;t&&t.options.type===e.renderAs||(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())}_createSurface(){return Fc.create(this.surfaceElement,{type:this.options.renderAs})}_destroySurface(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())}_initSurfaceElement(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.surfaceElement.style.position="relative",this.element.appendChild(this.surfaceElement))}_destroySurfaceElement(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)}redraw(){let e=this._getSize();this.surface.clear(),this.surface.setSize({width:e,height:e}),this.createVisual(),this.surface.draw(this.visual)}getSize(){const e=this.element;const t=e.clientWidth;const n=e.clientHeight;const i={width:0,height:0};return t>0&&(i.width=t),n&&(i.height=n),i}_resize(){this.redraw()}createVisual(){this.visual=this._render()}exportVisual(){return this._render()}_render(){let e,t,n,i,r,o,a=this._value,s=this.options.border||{},l=this.options.padding||0,c=s.width||0;s.width=c;let d=new Us;try{a&&(n=RJ(a,this.options.errorCorrection,this.options.encoding),i=this._getSize(),o=i-2*(c+l),e=this._calculateBaseUnit(o,n.length),r=n.length*e,t=c+l+(o-r)/2,d.append(this._renderBackground(i,s)),d.append(this._renderMatrix(n,e,t)),this._hasCustomLogo()?d.append(this._renderLogo(i,e)):this._isSwiss()&&d.append(this._renderSwissCode(i,e)))}catch(e){this.onError(e)}return d}_renderLogo(e,t){let n;let i;let r=FJ(e/2);let o=this._getLogoSize(t*qJ);let a=this.options.overlay.imageUrl;let s={x:r-o.width/2,y:r-o.height/2};return i=new ya(new ba(s.x,s.y),new wa(o.width,o.height)),n=new Ns(a,i),n}_renderSwissCode(e,t){let n=this._getLogoSize(t*qJ);n=Math.max(n.width,n.height);let i=n/4;let r=i/2;let o=e/2;let a={};let s=new Us;return a.x=a.y=Math.ceil(o-t-n/2),s.append(this._renderShape(a,Math.ceil(n+2*t),VJ,"#fff")),a.x=a.y=o-n/2,s.append(this._renderShape(a,n,VJ,this.options.color)),a.x=o+r-n/2,a.y=o+r+i-n/2,s.append(this._renderShape(a,i,OJ,"#fff")),s}_renderShape(e,t,n,i){let r=new Fs({fill:{color:i},stroke:null});r.moveTo(e.x,e.y);for(let i=0;i<n.length;i++)r.lineTo(e.x+t*n[i][0],e.y+t*n[i][1]);return r.close(),r}_getSize(){let e;if(this.options.size)e=parseInt(this.options.size,10);else{const t=UZ(this.element,this.options.renderAs);const n=Math.min(t.width,t.height);e=n>0?n:NJ}return e}_calculateBaseUnit(e,t){let n=Math.floor(e/t);if(n<jJ){const n=Math.ceil(t*jJ);this.onError(new Error(`Insufficient size for QR Code: the current size is ${e}px and the minimum size is ${n}px.`))}else n*t>=e&&n-1>=jJ&&n--;return n}_renderMatrix(e,t,n){let i=new Fs({fill:{color:this.options.color},stroke:null});for(let r=0;r<e.length;r++){let o=n+r*t;let a=0;for(;a<e.length;){for(;0===e[r][a]&&a<e.length;)a++;if(a<e.length){let s=a;for(;1===e[r][a];)a++;let l=FJ(n+s*t);let c=FJ(o);let d=FJ(n+a*t);let h=FJ(o+t);i.moveTo(l,c).lineTo(l,h).lineTo(d,h).lineTo(d,c).close()}}}return i}_renderBackground(e,t){const n=new hU(0,0,e,e).unpad(t.width/2);return Rs.fromRect(n.toRect(),{fill:{color:this.options.background},stroke:{color:t.color,width:t.width}})}setOptions(e){let t=e||{};this.options=WZ(this.options,t),void 0!==e.value&&(this._value=String(this.options.value)),this._initSurface(),this.redraw()}value(e){if(void 0===e)return this._value;this._value=String(e),this.redraw()}_hasCustomLogo(){return Boolean(this.options.overlay.imageUrl)}_isSwiss(){return"swiss"===this.options.overlay.type}_getLogoSize(e){let t=this.options.overlay.width;let n=this.options.overlay.height;return t||n?t&&!n?n=t:!t&&n&&(t=n):t=n=e,{width:t,height:n}}},{name:"QRCode",renderAs:"svg",encoding:"ISO_8859_1",value:"",errorCorrection:$J,background:UJ,color:WJ,size:"",padding:0,border:{color:"",width:0},overlay:{type:"image",imageUrl:"",width:0,height:0}});const GJ={WGS84:{a:6378137,b:6356752.314245179,f:.0033528106647474805,e:.08181919084262149}};function KJ(e){return e*e}let YJ=Math,QJ=YJ.abs,XJ=YJ.atan,ZJ=YJ.atan2,JJ=YJ.cos,e1=YJ.sin,t1=YJ.tan;class n1{constructor(e,t){this.initProperties(),1===arguments.length?(this.lat=e[0],this.lng=e[1]):(this.lat=e,this.lng=t)}initProperties(){cN(this,{DISTANCE_ITERATIONS:100,DISTANCE_CONVERGENCE:1e-12,DISTANCE_PRECISION:2,FORMAT:"{0:N6}{1:N6}"})}toArray(){return[this.lat,this.lng]}equals(e){return e&&e.lat===this.lat&&e.lng===this.lng}clone(){return new n1(this.lat,this.lng)}round(e){return this.lng=GN(this.lng,e),this.lat=GN(this.lat,e),this}wrap(){return this.lng=this.lng%180,this.lat=this.lat%90,this}distanceTo(e,t){return this.greatCircleTo(e,t).distance}destination(e,t,n){let i=qN(t);let r=n||GJ.WGS84;let o=qN(this.lat);let a=qN(this.lng);let s=e/r.a;let l=YJ.asin(e1(o)*JJ(s)+JJ(o)*e1(s)*JJ(i));let c=a+ZJ(e1(i)*e1(s)*JJ(o),JJ(s)-e1(o)*e1(l));return new n1(RN(l),RN(c))}greatCircleTo(e,t){let n=n1.create(n);let i=t||GJ.WGS84;if(!n||this.clone().round(8).equals(n.clone().round(8)))return{distance:0,azimuthFrom:0,azimuthTo:0};let r=i.a;let o=i.b;let a=i.f;let s=qN(n.lng-this.lng);let l=XJ((1-a)*t1(qN(this.lat)));let c=e1(l);let d=JJ(l);let h=XJ((1-a)*t1(qN(n.lat)));let u=e1(h);let p=JJ(h);let f=s;let m;let g=this.DISTANCE_ITERATIONS;let v=!1;let _;let b;let w;let y;let k;let x;let C;for(;!v&&g-- >0;){_=e1(f),b=JJ(f),w=YJ.sqrt(KJ(p*_)+KJ(d*u-c*p*b)),k=c*u+d*p*b,C=ZJ(w,k);let e=d*p*_/w;y=1-KJ(e),x=0,0!==y&&(x=k-2*c*u/y),m=f;let t=a/16*y*(4+a*(4-3*y));f=s+(1-t)*a*e*(C+t*w*(x+t*k*(2*KJ(x)-1))),v=QJ(f-m)<=this.DISTANCE_CONVERGENCE}let S=y*(KJ(r)-KJ(o))/KJ(o);let T=1+S/16384*(4096+S*(S*(320-175*S)-768));let M=S/1024*(256+S*(S*(74-47*S)-128));let A=M*w*(x+M/4*(k*(2*KJ(x)-1)-M/6*x*(4*KJ(w)-3)*(4*KJ(x)-3)));let D=ZJ(p*_,d*u-c*p*b);let E=ZJ(d*_,-c*p+d*u*b);return{distance:GN(o*T*(C-A),this.DISTANCE_PRECISION),azimuthFrom:RN(D),azimuthTo:RN(E)}}toString(){return String(this.lat)+","+String(this.lng)}static fromLngLat(e){return new n1(e[1],e[0])}static fromLatLng(e){return new n1(e[0],e[1])}static create(e,t){if(HN(e))return e instanceof n1?e.clone():1===arguments.length&&2===e.length?n1.fromLatLng(e):new n1(e,t)}}let i1=Math,r1=i1.atan,o1=i1.exp,a1=i1.pow,s1=i1.sin,l1=i1.log,c1=i1.tan,d1=ba;let h1=i1.PI,u1=h1/2,p1=h1/4,f1=h1/180;let m1=GJ.WGS84;class g1{constructor(e){this.initProperties(),this._initOptions(e)}_initOptions(e){this.options=cN({},this.options,e)}initProperties(){cN(this,{MAX_LNG:180,MAX_LAT:85.0840590501,INVERSE_ITERATIONS:15,INVERSE_CONVERGENCE:1e-12})}forward(e,t){let n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=WN(e.lat,-n.MAX_LAT,n.MAX_LAT),s=t?WN(e.lng,-n.MAX_LNG,n.MAX_LNG):e.lng,l=qN(s-o)*r,c=n._projectLat(a);return new d1(l,c)}_projectLat(e){let t=this.options.datum,n=t.e,i=t.a,r=qN(e),o=c1(p1+r/2),a=n*s1(r),s=a1((1-a)/(1+a),n/2);return i*l1(o*s)}inverse(e,t){let n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=e.x/(f1*r)+o,s=WN(n._inverseY(e.y),-n.MAX_LAT,n.MAX_LAT);return t&&(a=WN(a,-n.MAX_LNG,n.MAX_LNG)),new n1(s,a)}_inverseY(e){let t,n=this,i=n.options.datum,r=i.a,o=i.e,a=o/2,s=o1(-e/r),l=u1-2*r1(s);for(t=0;t<=n.INVERSE_ITERATIONS;t++){let e=o*s1(l),t=a1((1-e)/(1+e),a),i=u1-2*r1(s*t)-l;if(l+=i,i1.abs(i)<=n.INVERSE_CONVERGENCE)break}return RN(l)}}XN(g1,{centralMeridian:0,datum:m1});class v1 extends g1{initProperties(){super.initProperties(),cN(this,{MAX_LAT:85.0511287798})}_projectLat(e){let t=this.options.datum.a,n=qN(e),i=c1(p1+n/2);return t*l1(i)}_inverseY(e){let t=this.options.datum.a,n=o1(-e/t);return RN(u1-2*r1(n))}}class _1{constructor(){let e=this._proj=new v1;let t=this.c=2*h1*e.options.datum.a;this._tm=xa().translate(.5,.5).scale(1/t,-1/t),this._itm=xa().scale(t,-t).translate(-.5,-.5)}toPoint(e,t,n){return this._proj.forward(e,n).transform(this._tm).scale(t||1)}toLocation(e,t,n){let i=e.clone().scale(1/(t||1)).transform(this._itm);return this._proj.inverse(i,n)}}Object.assign;const b1=(e,t)=>e.bind(t);let w1=e=>{const t=document.createElement("div");return t.innerHTML=e,t.firstChild};let y1=e=>{for(;e.firstChild;)e.removeChild(e.firstChild)};let k1=(e,t)=>{t.insertBefore(e,t.firstChild)};let x1=e=>e.replace(/([a-z][A-Z])/g,(function(e){return e.charAt(0)+"-"+e.charAt(1).toLowerCase()}));let C1=e=>{let t;return t=e&&String(e).endsWith("px")?e:String(e)+"px",t};const S1=(e,t)=>{const n=e.prototype;n.events?t.forEach((e=>{n.events.indexOf(e)<0&&n.events.push(e)})):n.events=t};const T1=e=>{let t=[];if(e){let n=x1(e).split("-");for(let e=0;e<n.length;e++)t.push("k-pos-"+n[e])}return t.join(" ")};class M1 extends O${constructor(e,t){super(),this.element=e,this._initOptions(t),this.items=[],YV(this.element,"k-widget k-attribution")}_initOptions(e){this.options=cN({},this.options,e)}filter(e,t){this._extent=e,this._zoom=t,this._render()}add(e){let t=e;HN(e)&&("string"==typeof e&&(t={text:e}),this.items.push(t),this._render())}remove(e){let t=[];for(let n=0;n<this.items.length;n++){let i=this.items[n];i.text!==e&&t.push(i)}this.items=t,this._render()}clear(){this.items=[],y1(this.element)}_render(){let e=[];for(let t=0;t<this.items.length;t++){let n=this.items[t];let i=this._itemText(n);""!==i&&e.push(i)}if(e.length>0){y1(this.element);((e,t)=>{const 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()}else this.hideElement()}hideElement(){this.element.style.display="none"}showElement(){this.element.style.display=""}_itemText(e){let t="";let n=this._inZoomLevel(e.minZoom,e.maxZoom);let i=this._inArea(e.extent);return n&&i&&(t+=e.text),t}_inZoomLevel(e,t){let n=!0;let i=YN(e,-Number.MAX_VALUE);let r=YN(t,Number.MAX_VALUE);return n=this._zoom>i&&this._zoom<r,n}_inArea(e){let t=!0;return e&&(t=e.contains(this._extent)),t}}XN(M1,{name:"Attribution",separator:" | "});const A1={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 D1(e,t){const n='<button type="button" class="k-button k-button-square k-rounded-full k-button-flat k-button-flat-base k-icon-button '+A1[e].className+'" aria-label="move '+e+'">'+r$({icon:`caret-alt-${e}`,iconClass:"k-button-icon",svgIcons:t.svgIcons,type:t.type})+"</button>";return w1(n)}class E1 extends O${constructor(e,t){super(),this.element=e,this._initOptions(t);const n=D1("up",t.icons);const i=D1("right",t.icons);const r=D1("down",t.icons);const o=D1("left",t.icons);this.element.appendChild(n),this.element.appendChild(i),this.element.appendChild(r),this.element.appendChild(o),YV(this.element,"k-widget k-navigator"),D$(this.element,"click",".k-button",b1(this._click,this));let a=this.element.parentNode.closest("[data-role]");this._keyroot=a||this.element,this._tabindex(this._keyroot),this._keydownHandler=b1(this._keydown,this),D$(this._keyroot,"keydown",this._keydownHandler)}destroy(){this.dispose()}dispose(){E$(this._keyroot,"keydown",this._keydownHandler)}_tabindex(e){const t=e||this.wrapper||this.element;let n=this.element,i="tabindex",r=t.getAttribute(i)||n.getAttribute(i);n.removeAttribute(i),t.setAttribute(i,isNaN(r)?0:r)}_initOptions(e){this.options=cN({},this.options,e)}_pan(e,t){let n=this.options.panStep;this.trigger("pan",{x:e*n,y:t*n})}_click(e){let t=0;let n=0;let 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()}_keydown(e){switch(e.which){case v$.UP:this._pan(0,1),e.preventDefault();break;case v$.DOWN:this._pan(0,-1),e.preventDefault();break;case v$.RIGHT:this._pan(1,0),e.preventDefault();break;case v$.LEFT:this._pan(-1,0),e.preventDefault()}}}function I1(e,t,n){const i='<button type="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+'">'+r$({icon:t,iconClass:"k-button-icon",svgIcons:n.svgIcons,type:n.type})+"</button>";return w1(i)}XN(E1,{name:"Navigator",panStep:1}),S1(E1,["pan"]);const z1="change";class P1 extends O${constructor(e,t,n){super(),this.element=e,this._initOptions(t);const i=I1("in","plus",n);const r=I1("out","minus",n);this.element.appendChild(i),this.element.appendChild(r),this.element.setAttribute("role","group"),YV(this.element,"k-widget k-zoom-control k-button-group k-group-horizontal"),this._clickHandler=this._click.bind(this),D$(this.element,"click",".k-button",this._clickHandler);let o=this.element.parentNode.closest("[data-role]");this._keyroot=o||this.element,this._tabindex(this._keyroot),this._keydownHandler=this._keydown.bind(this),D$(this._keyroot,"keydown",this._keydownHandler)}destroy(){this.element&&E$(this.element,"click",this._clickHandler),this._keyroot&&E$(this._keyroot,"keydown",this._keydownHandler)}_tabindex(e){const t=e||this.wrapper||this.element;let n=this.element,i="tabindex",r=t.getAttribute(i)||n.getAttribute(i);n.removeAttribute(i),t.setAttribute(i,isNaN(r)?0:r)}_initOptions(e){this.options=cN({},this.options,e)}_change(e){let t=this.options.zoomStep;this.trigger(z1,{delta:e*t})}_click(e){let t=1;CN(e.currentTarget,"k-zoom-out")&&(t=-1),this._change(t),e.preventDefault()}_keydown(e){switch(e.which){case v$.NUMPAD_PLUS:case 187:case 61:this._change(1);break;case v$.NUMPAD_MINUS:case 189:case 173:this._change(-1)}}}XN(P1,{name:"ZoomControl",zoomStep:1}),S1(P1,[z1]);let L1=Math,B1=L1.max,H1=L1.min;class R1{constructor(e,t){let n=n1.create(e);let i=n1.create(t);n.lng+180>i.lng+180&&n.lat+90<i.lat+90?(this.se=n,this.nw=i):(this.se=i,this.nw=n)}contains(e){let t=this.nw,n=this.se,i=YN(e.lng,e[1]),r=YN(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(){let e=this.nw;let t=this.se;let n=e.lng+(t.lng-e.lng)/2;let i=e.lat+(t.lat-e.lat)/2;return new n1(i,n)}containsAny(e){let t=!1;for(let n=0;n<e.length;n++)t=t||this.contains(e[n]);return t}include(e){let t=this.nw,n=this.se,i=YN(e.lng,e[1]),r=YN(e.lat,e[0]);t.lng=H1(t.lng,i),t.lat=B1(t.lat,r),n.lng=B1(n.lng,i),n.lat=H1(n.lat,r)}includeAll(e){for(let t=0;t<e.length;t++)this.include(e[t])}edges(){let e=this.nw,t=this.se;return{nw:this.nw,ne:new n1(e.lat,t.lng),se:this.se,sw:new n1(t.lat,e.lng)}}toArray(){let e=this.nw,t=this.se;return[e,new n1(e.lat,t.lng),t,new n1(t.lat,e.lng)]}overlaps(e){return this.containsAny(e.toArray())||e.containsAny(this.toArray())}static create(e,t){return e instanceof R1?e:e&&t?new R1(e,t):e&&4===e.length&&!t?new R1([e[0],e[1]],[e[2],e[3]]):void 0}static get World(){return new R1([90,-180],[-90,180])}}const F1="centerChange";class O1{constructor(e,t){this.widgetService=e,this.options=cN({},this.options,t),this.offset={x:0,y:0}}show(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)}hide(){this.widgetService&&this.widgetService.notify("hideTooltip"),this.visible=!1,this.location=null}get anchor(){return this._anchor}set anchor(e){const 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}}destroy(){this.widgetService=null}}XN(O1,{border:{width:1},opacity:1});class V1{constructor(e,t){this.support=I$(),this._initOptions(t),this.map=e;let n=document.createElement("div");YV(n,"k-layer"),n.style.zIndex=this.options.zIndex,n.style.opacity=this.options.opacity,this.element=n,e.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()}destroy(){this._deactivate()}_initOptions(e){this.options=cN({},this.options,e)}show(){this.reset(),this._activate(),this._applyExtent(!0)}hide(){this._deactivate(),this._setVisibility(!1)}reset(){this._beforeReset(),this._reset()}_reset(){this._applyExtent()}_beforeReset(){}_resize(){}_panEnd(){this._applyExtent()}_applyExtent(){let e=this.options;let t=this.map.zoom();let n=!HN(e.minZoom)||t>=e.minZoom;let i=!HN(e.maxZoom)||t<=e.maxZoom;let r=R1.create(e.extent);let o=!r||r.overlaps(this.map.extent());this._setVisibility(n&&i&&o)}_setVisibility(e){this.element.style.display=e?"":"none"}_activate(){let 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(){let e=this.map;e.unbind("beforeReset",this._beforeReset),e.unbind("reset",this._reset),e.unbind("resize",this._resize),e.unbind("panEnd",this._panEnd)}_updateAttribution(){const e=this.map.attribution;e&&e.add(this.options.attribution)}_readData(){return this.options.data||[]}_hasData(){return this._data&&this._data.length>0}_layerIndex(){return(this.map.layers||[]).indexOf(this)}}let N1=Math,$1=ba;function U1(e){return aN(e)?e:vN.compile(e)}function W1(e){return new $1(GN(e.x),GN(e.y))}function j1(e){let t=e;return"string"!=typeof e&&(t+="px"),t}class q1 extends V1{constructor(e,t){super(e,t),"string"==typeof this.options.subdomains&&(this.options.subdomains=this.options.subdomains.split(""));let n=this._viewType();this._view=new n(this.element,this.options)}destroy(){super.destroy(),this._view.destroy(),this._view=null}_beforeReset(){let e=this.map;let t=e.locationToLayer(e.extent().nw).round();this._view.viewOrigin(t)}_reset(){super._reset(),this._updateView(),this._view.reset()}_viewType(){return G1}_activate(){super._activate(),this.support.mobileOS||(this._pan||(this._pan=oo(this._render.bind(this),100)),this.map.bind("pan",this._pan))}_deactivate(){super._deactivate(),this._pan&&this.map.unbind("pan",this._pan)}_updateView(){let 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(){this._render()}_panEnd(e){super._panEnd(e),this._render()}_render(){this._updateView(),this._view.render()}}XN(q1,{tileSize:256,subdomains:["a","b","c"],urlTemplate:"",zIndex:1});class G1{constructor(e,t){this.element=e,this._initOptions(t),this.pool=new Y1}_initOptions(e){this.options=cN({},this.options,e)}center(e){this._center=e}extent(e){this._extent=e}viewOrigin(e){this._viewOrigin=e}zoom(e){this._zoom=e}pointToTileIndex(e){return new $1(N1.floor(e.x/this.options.tileSize),N1.floor(e.y/this.options.tileSize))}tileCount(){let e=this.size(),t=this.pointToTileIndex(this._extent.nw),n=this._extent.nw,i=this.indexToPoint(t).translate(-n.x,-n.y);return{x:N1.ceil((N1.abs(i.x)+e.width)/this.options.tileSize),y:N1.ceil((N1.abs(i.y)+e.height)/this.options.tileSize)}}size(){let e=this._extent.nw,t=this._extent.se.clone().translate(-e.x,-e.y);return{width:t.x,height:t.y}}indexToPoint(e){let t=e.x,n=e.y;return new $1(t*this.options.tileSize,n*this.options.tileSize)}subdomainText(){let e=this.options.subdomains;return e[this.subdomainIndex++%e.length]}destroy(){y1(this.element),this.pool.empty()}reset(){this.pool.reset(),this.subdomainIndex=0,this.render()}render(){let 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}),e.visible||e.show()}createTile(e){let t=this.tileOptions(e);let n=this.pool.get(this._center,t);return n.element.parentNode||this.element.append(n.element),n}tileOptions(e){let 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:W1(r),zoom:this._zoom,size:this.options.tileSize,subdomain:this.subdomainText(),urlTemplate:this.options.urlTemplate,errorUrlTemplate:this.options.errorUrlTemplate}}wrapIndex(e){let t=N1.pow(2,this._zoom);return{x:this.wrapValue(e.x,t),y:WN(e.y,0,t-1)}}wrapValue(e,t){let n=N1.abs(e)%t;let i=e;return i=e>=0?n:t-(0===n?t:n),i}}class K1{constructor(e,t){this.id=e,this.visible=!0,this._initOptions(t),this.createElement(),this.show()}destroy(){const e=this.element;const t=e?e.parentNode:null;e&&(t&&t.removeChild(e),this.element=null)}_initOptions(e){this.options=cN({},this.options,e)}createElement(){let e=document.createElement("img");const 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}show(){let e=this.element;e.style.top=j1(this.options.offset.y),e.style.left=j1(this.options.offset.x);let t=this.url();t&&e.setAttribute("src",t),e.style.visibility="visible",this.visible=!0}hide(){this.element.style.visibility="hidden",this.visible=!1}url(){return U1(this.options.urlTemplate)(this.urlOptions())}errorUrl(){return U1(this.options.errorUrlTemplate)(this.urlOptions())}urlOptions(){let 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}}}XN(K1,{urlTemplate:"",errorUrlTemplate:""});class Y1{constructor(){this._items=[]}get(e,t){return this._items.length>=this.options.maxSize&&this._remove(e),this._create(t)}empty(){let e=this._items;for(let t=0;t<e.length;t++)e[t].destroy();this._items=[]}reset(){let e=this._items;for(let t=0;t<e.length;t++)e[t].hide()}_create(e){let t=this._items;let n;let i=$N(e.point.toString()+e.offset.toString()+e.zoom+e.urlTemplate);for(let e=0;e<t.length;e++)if(t[e].id===i){n=t[e];break}return n?n.show():(n=new K1(i,e),this._items.push(n)),n}_remove(e){let t=this._items;let n=-1;let i=-1;for(let r=0;r<t.length;r++){let 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))}}XN(Y1,{maxSize:100});const Q1=Object.assign;const X1="change";let Z1=class extends O${constructor(e,t){super();let n=this,i=e[0]||e;n.capture=!1,i.addEventListener?(y$.down.split(" ").forEach((function(e){i.addEventListener(e,b1(n._press,n),!0)})),y$.up.split(" ").forEach((function(e){i.addEventListener(e,b1(n._release,n),!0)}))):(y$.down.split(" ").forEach((function(e){i.attachEvent(e,b1(n._press,n))})),y$.up.split(" ").forEach((function(e){i.attachEvent(e,b1(n._release,n))}))),n.bind(["press","release"],t||{})}captureNext(){this.capture=!0}cancelCapture(){this.capture=!1}_press(e){this.trigger("press"),this.capture&&e.preventDefault()}_release(e){let t=this;t.trigger("release"),t.capture&&(e.preventDefault(),t.cancelCapture())}};let J1=class extends O${constructor(e){super();let t=this;t.forcedEnabled=!1,Q1(t,e),t.scale=1,t.horizontal?(t.measure="offsetWidth",t.scrollSize="scrollWidth",t.axis="x"):(t.measure="offsetHeight",t.scrollSize="scrollHeight",t.axis="y")}makeVirtual(){Q1(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})}virtualSize(e,t){this._virtualMin===e&&this._virtualMax===t||(this._virtualMin=e,this._virtualMax=t,this.update())}outOfBounds(e){return e>this.max||e<this.min}forceEnabled(){this.forcedEnabled=!0}getSize(){return this.container[this.measure]}getTotal(){return this.element[this.scrollSize]}rescale(e){this.scale=e}update(e){let 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(X1,t))}};let e0=class extends O${constructor(e){super();let t=this;t.x=new J1(Q1({horizontal:!0},e)),t.y=new J1(Q1({horizontal:!1},e)),t.container=e.container,t.forcedMinScale=e.minScale,t.maxScale=e.maxScale||100,t.bind(X1,e)}rescale(e){this.x.rescale(e),this.y.rescale(e),this.refresh()}centerCoordinates(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}}refresh(){let 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(X1)}};let t0=class extends O${constructor(e){super(),Q1(this,e)}outOfBounds(){return this.dimension.outOfBounds(this.movable[this.axis])}dragMove(e){let t=this,n=t.dimension,i=t.axis,r=t.movable,o=r[i]+e;if(!n.enabled)return;let a=e;(o<n.min&&e<0||o>n.max&&e>0)&&(a*=t.resistance),r.translateAxis(i,a),t.trigger(X1,t)}};let n0=class{constructor(e){let t,n,i,r,o=this;Q1(o,{elastic:!0},e),i=o.elastic?.5:0,r=o.movable,o.x=t=new t0({axis:"x",dimension:o.dimensions.x,resistance:i,movable:r}),o.y=n=new t0({axis:"y",dimension:o.dimensions.y,resistance:i,movable:r}),o.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart(e){o.gesture=e,o.offset=FN(o.dimensions.container)},press(e){const t=e.event.target.closest("a");t&&t.matches("[data-navigate-on-press=true]")&&e.sender.cancel()},gesturechange(e){let i,a=o.gesture,s=a.center,l=e.center,c=e.distance/a.distance,d=o.dimensions.minScale,h=o.dimensions.maxScale;r.scale<=d&&c<1&&(c+=.8*(1-c)),r.scale*c>=h&&(c=h/r.scale);let u=r.x+o.offset.left,p=r.y+o.offset.top;i={x:(u-s.x)*c+l.x-u,y:(p-s.y)*c+l.y-p},r.scaleWith(c),t.dragMove(i.x),n.dragMove(i.y),o.dimensions.rescale(r.scale),o.gesture=e,e.preventDefault()},move(e){e.event.target.tagName.match(/textarea|input/i)||(t.dimension.enabled||n.dimension.enabled?(t.dragMove(e.x.delta),n.dragMove(e.y.delta),e.preventDefault()):e.touch.skip())},end(e){e.preventDefault()}})}};let i0=function(e,t,n){return"translate3d("+e+"px,"+t+"px,0) scale("+n+")"};let r0=class extends O${constructor(e){super();let t=this;t.element=e,t.element.style.transformOrigin="left top",t.x=0,t.y=0,t.scale=1;const n=i0(t.x,t.y,t.scale);t.element.style.transform=n,t._saveCoordinates(n)}translateAxis(e,t){this[e]+=t,this.refresh()}scaleTo(e){this.scale=e,this.refresh()}scaleWith(e){this.scale*=e,this.refresh()}translate(e){this.x+=e.x,this.y+=e.y,this.refresh()}moveAxis(e,t){this[e]=t,this.refresh()}moveTo(e){Q1(this,e),this.refresh()}refresh(){let e,t=this,n=t.x,i=t.y;t.round&&(n=Math.round(n),i=Math.round(i)),e=i0(n,i,t.scale),e!==t.coordinates&&(t.element.style.transform=e,t._saveCoordinates(e),t.trigger(X1))}_saveCoordinates(e){this.coordinates=e}};const o0=Us;class a0 extends V1{constructor(e,t){super(e,t),this._pan=b1(this._pan,this),this.surface=Fc.create(this.element,{width:e.scrollElement.clientWidth,height:e.scrollElement.clientHeight}),this._initRoot(),this.movable=new r0(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))}destroy(){super.destroy(),this.surface.destroy()}_reset(){super._reset(),this._translateSurface(),this._data=this._readData(),this._hasData()&&this._load(this._data)}_initRoot(){this._root=new o0,this.surface.draw(this._root)}_beforeReset(){this.surface.clear(),this._initRoot()}_resize(){this.surface.size(this.map.size())}_readData(){const e=super._readData();return"FeatureCollection"===e.type?e.features:"GeometryCollection"===e.type?e.geometries:e}_load(e){this._data=e,this._clearMarkers(),this._loader||(this._loader=new s0(this.map,this.options.style,this));let t=new o0;for(let n=0;n<e.length;n++){let i=this._loader.parse(e[n]);i&&t.append(i)}this._root.clear(),this._root.append(t)}shapeCreated(e){let t=!1;if(e instanceof Ra&&this.map.options.renderPointsAsMarkers&&(t=HN(this._createMarker(e))),!t){let n={layer:this,shape:e};t=this.map.trigger("shapeCreated",n)}return t}featureCreated(e){e.layer=this,this.map.trigger("shapeFeatureCreated",e)}_createMarker(e){let t=this.map.markers.bind({location:e.location},e.dataItem);return t&&this._markers.push(t),t}_clearMarkers(){for(let e=0;e<this._markers.length;e++)this.map.markers.remove(this._markers[e]);this._markers=[]}_pan(){this._panning||(this._panning=!0,this.surface.suspendTracking())}_panEnd(e){super._panEnd(e),this._translateSurface(),this.surface.resumeTracking(),this._panning=!1}_translateSurface(){let e=this.map;let t=e.locationToView(e.extent().nw);this.surface.translate&&(this.surface.translate(t),this.movable.moveTo({x:t.x,y:t.y}))}_eventArgs(e){return{layer:this,layerIndex:this._layerIndex(),shape:e.element,shapeIndex:(this._data||[]).indexOf(e.element.dataItem),originalEvent:e.originalEvent}}_handler(e){return t=>{t.element&&this.map.trigger(e,this._eventArgs(t))}}_mouseenter(e){if(!e.element)return;this.map.trigger("shapeMouseEnter",this._eventArgs(e));const t=e.element;const n=this._tooltipAnchor(e);this.map._tooltip.show(n,this._tooltipContext(t))}_tooltipContext(e){return{type:"shape",layerIndex:this._layerIndex(),className:"k-map-shape-tooltip",dataItem:e.dataItem,location:e.location}}_tooltipAnchor(e){const t=this.map.eventOffset(e.originalEvent);return{top:t.y,left:t.x}}_activate(){super._activate(),this._panHandler=b1(this._pan,this),this.map.bind("pan",this.panHandler)}_deactivate(){super._deactivate(),this.map.unbind("pan",this._panHandler)}}XN(a0,{autoBind:!0,zIndex:100});class s0{constructor(e,t,n){this.observer=n,this.locator=e,this.style=t}parse(e){let t=new o0;let 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(e){let t=!1;return this.observer&&this.observer.shapeCreated&&(t=this.observer.shapeCreated(e)),t}_featureCreated(e,t){this.observer&&this.observer.featureCreated&&this.observer.featureCreated({group:e,dataItem:t,properties:t.properties})}_loadGeometryTo(e,t,n){let i=t.coordinates;let r;let o;switch(t.type){case"LineString":o=this._loadPolygon(e,[i],n),this._setLineFill(o);break;case"MultiLineString":for(r=0;r<i.length;r++)o=this._loadPolygon(e,[i[r]],n),this._setLineFill(o);break;case"Polygon":this._loadPolygon(e,i,n);break;case"MultiPolygon":for(r=0;r<i.length;r++)this._loadPolygon(e,i[r],n);break;case"Point":this._loadPoint(e,i,n);break;case"MultiPoint":for(r=0;r<i.length;r++)this._loadPoint(e,i[r],n)}}_setLineFill(e){let t=e.segments;(t.length<4||!t[0].anchor().equals(UN(t).anchor()))&&(e.options.fill=null)}_loadShape(e,t){return this._shapeCreated(t)||e.append(t),t}_loadPolygon(e,t,n){let i=this._buildPolygon(t);return i.dataItem=n,i.location=this.locator.viewToLocation(i.bbox().center()),this._loadShape(e,i)}_buildPolygon(e){let t=new(e.length>1?Fs:Rs)(this.style);for(let n=0;n<e.length;n++)for(let i=0;i<e[n].length;i++){let r=this.locator.locationToView(n1.fromLngLat(e[n][i]));0===i?t.moveTo(r.x,r.y):t.lineTo(r.x,r.y)}return t}_loadPoint(e,t,n){let i=n1.fromLngLat(t);let r=this.locator.locationToView(i);let o=new Ia(r,10);let a=new Ra(o,this.style);return a.dataItem=n,a.location=i,this._loadShape(e,a)}}class l0 extends a0{_readData(){return this.options.data||[]}_load(e){if(this._data=e,this.surface.clear(),0===e.length)return;let t=this.options;let n=kN(t.valueField);let i=e.slice(0);i.sort((function(e,t){return n(t)-n(e)}));let r=this._scaleType();let o;let a=kN(this.options.locationField);for(let e=0;e<i.length;e++){let s=i[e];let l=a(s);let c=n(s);if(HN(l)&&HN(c)){o||(o=new r([0,c],[t.minSize,t.maxSize])),l=n1.create(l);let e=this.map.locationToView(l);let n=o.map(c);let i=this._createSymbol({center:e,size:n,style:t.style,dataItem:s,location:l});i.dataItem=s,i.location=l,i.value=c,this._drawSymbol(i)}}}_scaleType(){let e=this.options.scale;return aN(e)?e:c0[e]}_createSymbol(e){let t=this.options.symbol;return aN(t)||(t=d0[t]),t(e)}_drawSymbol(e){let t={layer:this,shape:e};this.map.trigger("shapeCreated",t)||this.surface.draw(e)}_tooltipContext(e){return{type:"bubble",layerIndex:this._layerIndex(),className:"k-map-bubble-tooltip",dataItem:e.dataItem,location:e.location,value:e.value}}_tooltipAnchor(e){const t=e.element.bbox().center();return{top:t.y,left:t.x}}}XN(l0,{locationField:"location",valueField:"value",minSize:0,maxSize:100,scale:"sqrt",symbol:"circle",zIndex:200});let c0={sqrt:class{constructor(e,t){this._domain=e,this._range=t;let n=Math.sqrt(e[1])-Math.sqrt(e[0]);let i=t[1]-t[0];this._ratio=i/n}map(e){let t=(Math.sqrt(e)-Math.sqrt(this._domain[0]))*this._ratio;return this._range[0]+t}}};let d0={circle:function(e){let t=new Ia(e.center,e.size/2);return new Ra(t,e.style)},square:function(e){let t=new Rs(e.style);let n=e.size/2;let 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}};const h0="click";const u0="mouseenter";const p0="mouseleave";const f0=Object.assign;const m0="k-marker";const g0="."+m0;class v0 extends V1{constructor(e,t){super(e,t),this._markerClickHandler=b1(this._markerClick,this),D$(this.element,h0,g0,this._markerClickHandler),this.items=[],this._load(this._readData())}destroy(){super.destroy(),E$(this.element,h0,this._markerClickHandler),this.clear()}add(e){if(!KV(e))return this._addOne(e);for(let t=0;t<e.length;t++)this._addOne(e[t])}remove(e){e.destroy();let t=(this.items||[]).indexOf(e);t>-1&&this.items.splice(t,1)}clear(){for(let e=0;e<this.items.length;e++)this.items[e].destroy();this.items=[]}update(e){let t=e.location();if(t){e.showAt(this.map.locationToView(t));let n={marker:e,layer:this};this.map.trigger("markerActivate",n)}}_reset(){super._reset();let e=this.items;for(let t=0;t<e.length;t++)this.update(e[t])}bind(e,t){let n=_0.create(e,this.options);n.dataItem=t;let i={marker:n,layer:this};if(!this.map.trigger("markerCreated",i))return this.add(n),n}_addOne(e){let t=_0.create(e,this.options);return t.addTo(this),t}_readData(){return this.options.data||[]}_load(e){this._data=e,this.clear();let t=kN(this.options.locationField);let n=kN(this.options.titleField);for(let i=0;i<e.length;i++){let r=e[i];this.bind({location:t(r),title:n(r)},r)}}_markerClick(e){const t=e.currentTarget._kendoNode;let n={layer:this,layerIndex:this._layerIndex(),marker:t,markerIndex:(this.items||[]).indexOf(t),originalEvent:e};this.map.trigger("markerClick",n)}_markerMouseEnter(e){const t=this._createMarkerEventArgs(e);this.map.trigger("markerMouseEnter",t)}_markerMouseLeave(e){const t=this._createMarkerEventArgs(e);this.map.trigger("markerMouseLeave",t)}_createMarkerEventArgs(e){const t=e.marker;return f0({},{layer:this,layerIndex:this._layerIndex(),marker:t,markerIndex:(this.items||[]).indexOf(t)},e)}}XN(v0,{zIndex:1e3,autoBind:!0,locationField:"location",titleField:"title",template:""});class _0{constructor(e){this.options=e||{}}destroy(){this.layer=null,this.unbindEvents(),this.hide()}addTo(e){this.layer=e.markers||e,this.layer.items.push(this),this.layer.update(this)}location(e){return e?(this.options.location=n1.create(e).toArray(),this.layer&&this.layer.update(this),this):n1.create(this.options.location)}showAt(e){this.render(),this._anchor={left:Math.round(e.x),top:Math.round(e.y)},this.element.style.left=C1(this._anchor.left),this.element.style.top=C1(this._anchor.top)}hide(){this.element&&(this.element.remove(),this.element=null)}bindEvents(){this.element&&(this._mouseEnterHandler=b1(this._mouseEnter,this),D$(this.element,u0,g0,this._mouseEnterHandler),this._mouseLeaveHandler=b1(this._mouseLeave,this),D$(this.element,p0,g0,this._mouseLeaveHandler))}unbindEvents(){this.element&&(E$(this.element,u0,this._mouseEnterHandler),E$(this.element,p0,this._mouseLeaveHandler))}render(){if(!this.element){let e=this.options;let t=this.layer;let n=document.createElement("span");if(YV(n,m0),this.options.template){const e=this._compileTemplate(this.options.template)(this.dataItem);const t=w1(e);n.appendChild(t)}else if(e.svgIcon)r$(n,{icon:e.svgIcon,iconClass:"k-icon-xxl",svgIcons:this.options.icons.svgIcons,type:"svg"});else{let t={icon:"map-marker",iconClass:"k-icon-xxl",svgIcons:this.options.icons.svgIcons,type:this.options.icons.type};e.shape?"pinTarget"===e.shape?(t.icon="map-marker-target",r$(n,t)):"pin"===e.shape?r$(n,t):YV(n,"k-icon k-icon-xxl k-i-marker-"+x1(e.shape||"pin")):r$(n,t)}e.title&&n.setAttribute("title",e.title);const i=e.attributes||{};Object.keys(i).forEach((function(e){n.setAttribute(e,i[e])})),n._kendoNode=this,n.style.zIndex=e.zIndex,this.element=n,t&&t.element.appendChild(this.element),this.bindEvents()}}_mouseEnter(e){const 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())}_tooltipContext(){return{type:"marker",layerIndex:this.layer._layerIndex(),className:"k-map-marker-tooltip",dataItem:this.dataItem,title:this.options.title,location:this.location()}}_mouseLeave(e){const t=this._createEventArgs(e);this.layer._markerMouseLeave(t)}_createEventArgs(e){return{marker:this,originalEvent:e}}_compileTemplate(e){return vN.compile(e,{paramName:"dataItem",useWithBlock:!1})}static create(e,t){return e instanceof _0?e:new _0(cN({},t,e))}}const b0=Object.assign;function w0(e){window.requestAnimationFrame(e)}let y0=class{constructor(){let e=this;e._tickProxy=b1(e._tick,e),e._started=!1}tick(){}done(){}onEnd(){}onCancel(){}start(){this.enabled()&&(this.done()?this.onEnd():(this._started=!0,w0(this._tickProxy)))}enabled(){return!0}cancel(){this._started=!1,this.onCancel()}_tick(){let e=this;e._started&&(e.tick(),e.done()?(e._started=!1,e.onEnd()):w0(e._tickProxy))}};let k0=class extends y0{constructor(e){super(),b0(this,e)}done(){return this.timePassed()>=this.duration}timePassed(){return Math.min(this.duration,L$()-this.startDate)}moveTo(e){let 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=L$(),t.start()}_easeProxy(e){let t=this;return function(){t.movable.moveAxis(t.axis,e(t.timePassed(),t.initial,t.delta,t.duration))}}static easeOutExpo(e,t,n,i){return e===i?t+n:n*(1-Math.pow(2,-10*e/i))+t}};let x0=Object.assign,C0=Math.abs,S0="change",T0="scroll";let M0=class extends y0{constructor(e){super(e);let t=this;x0(t,e),t.userEvents.bind("gestureend",t.start.bind(this)),t.tapCapture.bind("press",t.cancel.bind(this))}enabled(){return this.movable.scale<this.dimensions.minScale}done(){return this.dimensions.minScale-this.movable.scale<.01}tick(){let e=this.movable;e.scaleWith(1.1),this.dimensions.rescale(e.scale)}onEnd(){let e=this.movable;e.scaleTo(this.dimensions.minScale),this.dimensions.rescale(e.scale)}};let A0=class extends y0{constructor(e){super();let t=this;x0(t,e,{transition:new k0({axis:e.axis,movable:e.movable,onEnd(){t._end()}})}),t.tapCapture.bind("press",(function(){t.cancel()})),t.userEvents.bind("end",b1(t.start,t)),t.userEvents.bind("gestureend",b1(t.start,t)),t.userEvents.bind("tap",b1(t.onEnd,t))}onCancel(){this.transition.cancel()}freeze(e){this.cancel(),this._moveTo(e)}onEnd(){let e=this;e.paneAxis.outOfBounds()?e._snapBack():e._end()}done(){return C0(this.velocity)<1}start(e){let 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),super.start()):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(),super.start()))}tick(){let 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(){this.tapCapture.cancelCapture(),this.end()}_snapBack(){let e=this,t=e.dimension,n=e.movable[e.axis]>t.max?t.max:t.min;e._moveTo(n)}_moveTo(e){this.transition.moveTo({location:e,duration:500,ease:k0.easeOutExpo})}};let D0=class extends y0{constructor(e){super(e);x0(this,e,{origin:{},destination:{},offset:{}})}tick(){this._updateCoordinates(),this.moveTo(this.origin)}done(){return C0(this.offset.y)<5&&C0(this.offset.x)<5}onEnd(){this.moveTo(this.destination),this.callback&&this.callback.call()}setCoordinates(e,t){this.offset={},this.origin=e,this.destination=t}setCallback(e){e&&aN(e)?this.callback=e:e=void 0}_updateCoordinates(){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}}};let E0=class{constructor(e){let t=this,n="x"===e.axis;const i=w1('<div class="km-touch-scrollbar km-'+(n?"horizontal":"vertical")+'-scrollbar" />');x0(t,e,{element:i,elementSize:0,movable:new r0(i),scrollMovable:e.movable,alwaysVisible:e.alwaysVisible,size:n?"width":"height"}),t.scrollMovable.bind(S0,t.refresh.bind(t)),t.container.appendChild(i),e.alwaysVisible&&t.show()}refresh(){let 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)}show(){this.element.style.opacity=.7,this.element.style.visibility="visible"}hide(){this.alwaysVisible||(this.element.style.opacity=0)}};let I0=class extends O${constructor(e,t){super();let n=this;this.element=e,this._initOptions(t);const i=(()=>{const{mobileOS:e}=I$();return e.ios||e.android})(navigator.userAgent);n._native=n.options.useNative&&i;const r=w1('<div class="km-scroll-header"/>');if(n._native)return YV(e,"km-native-scroller"),k1(r,e),void x0(n,{scrollElement:e,fixedContainer:e.children[0]});e.style.overflow="hidden",YV(e,"km-scroll-wrapper");((e,t)=>{for(e.appendChild(t);e.firstChild!==t;)t.appendChild(e.firstChild)})(e,w1('<div class="km-scroll-container"/>')),k1(r,e);let o=e.children[1],a=new Z1(e),s=new r0(o),l=new e0({element:o,container:e,forcedEnabled:n.options.zoom}),c=this.options.avoidScrolling,d=new lU(e,{touchAction:"none",allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:n.options.zoom,supportDoubleTap:n.options.supportDoubleTap,start(e){l.refresh();let t=C0(e.x.velocity),i=C0(e.y.velocity),r=2*t>=i,o=2*i>=t;!n.fixedContainer.contains(e.event.target)&&!c(e)&&n.enabled&&(l.x.enabled&&r||l.y.enabled&&o)?d.capture():d.cancel()}}),h=new n0({movable:s,dimensions:l,userEvents:d,elastic:n.options.elastic}),u=new M0({movable:s,dimensions:l,userEvents:d,tapCapture:a}),p=new D0({moveTo(e){n.scrollTo(e.x,e.y)}});s.bind(S0,(function(){n.scrollTop=-s.y,n.scrollLeft=-s.x,n.trigger(T0,{scrollTop:n.scrollTop,scrollLeft:n.scrollLeft})})),n.options.mousewheelScrolling&&(this._wheelScrollHandler=this._wheelScroll.bind(this),D$(e,"wheel",this._wheelScrollHandler)),x0(n,{movable:s,dimensions:l,zoomSnapBack:u,animatedScroller:p,userEvents:d,pane:h,tapCapture:a,pulled:!1,enabled:!0,scrollElement:o,scrollTop:0,scrollLeft:0,fixedContainer:e.children[0]}),n._initAxis("x"),n._initAxis("y"),n._wheelEnd=function(){n._wheel=!1,n.userEvents.end(0,n._wheelY)},l.refresh(),n.options.pullToRefresh&&n._initPullToRefresh()}_initOptions(e){this.options=cN({},this.options,e)}_wheelScroll(e){if(e.ctrlKey)return;this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);let t=(e=>{const t=e.wheelDeltaY;let n;return e.wheelDelta?(void 0===t||t)&&(n=e.wheelDelta):e.detail&&e.axis===e.VERTICAL_AXIS&&(n=10*-e.detail),n})(e);t&&(this._wheelY+=t,this.userEvents.move(0,this._wheelY)),e.preventDefault()}makeVirtual(){this.dimensions.y.makeVirtual()}virtualSize(e,t){this.dimensions.y.virtualSize(e,t)}height(){return this.dimensions.y.size}scrollHeight(){return this.scrollElement.scrollHeight}scrollWidth(){return this.scrollElement.scrollWidth}_resize(){this._native||this.contentResized()}setOptions(e){let t=this;this._initOptions(e),e.pullToRefresh&&t._initPullToRefresh()}reset(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))}contentResized(){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(){let e=this.dimensions;e.refresh(),this._scale(e.fitScale),this.movable.moveTo(e.centerCoordinates())}enable(){this.enabled=!0}disable(){this.enabled=!1}scrollTo(e,t){this._native?(this.scrollElement.scrollLeft(C0(e)),this.scrollElement.scrollTop(C0(t))):(this.dimensions.refresh(),this.movable.moveTo({x:e,y:t}))}animatedScrollTo(e,t,n){let 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(){}destroy(){E$(this.element,"wheel",this._wheelScrollHandler),this.userEvents&&this.userEvents.destroy()}_scale(e){this.dimensions.rescale(e),this.movable.scaleTo(e)}_initPullToRefresh(){}_dragEnd(){}_paneChange(){}_initAxis(e){let t=this,n=t.movable,i=t.dimensions[e],r=t.tapCapture,o=t.pane[e],a=new E0({axis:e,movable:n,dimension:i,container:t.element,alwaysVisible:t.options.visibleScrollHints});i.bind(S0,(function(){a.refresh()})),o.bind(S0,(function(){a.show()})),t[e+"inertia"]=new A0({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(){a.hide(),t.trigger("scrollEnd",{axis:e,scrollTop:t.scrollTop,scrollLeft:t.scrollLeft})}})}};XN(I0,{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:()=>!1,pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}}),S1(I0,["pull",T0,"resize"]);class z0{constructor(e,t={}){this.sender=t.sender||e,this.widget=e,this.rtl=Boolean(t.rtl)}notify(e,t){this.widget&&this.widget.trigger(e,t)}}let P0=Math,L0=P0.min,B0=P0.pow,H0=ba,R0="marker",F0="location",O0="wheel";const V0={bubble:l0,shape:a0,tile:q1,[R0]:v0};let N0=class extends O${constructor(e,t={},n={},i={}){super(),this._init(e,t,n,i)}destroy(){this.scroller.destroy(),this._tooltip&&this._tooltip.destroy(),this.navigator&&this.navigator.destroy(),this.attribution&&this.attribution.destroy(),this.zoomControl&&this.zoomControl.destroy(),KV(this.markers)?this.markers.forEach((e=>{e.destroy()})):this.markers.destroy();for(let e=0;e<this.layers.length;e++)this.layers[e].destroy();E$(this.element,O0,this._mousewheelHandler),super.destroy()}_init(e,t={},n={},i={}){this.support=I$(),this.context=i,this.initObserver(i),this.initServices(i),this._notifyObserver("init"),this._initOptions(t),this._setEvents(t),this.crs=new _1,this._initElement(e),this._viewOrigin=this._getOrigin(),this._tooltip=this._createTooltip(),this._initScroller(),this._initMarkers(),this._initControls(),this._initLayers(),this._reset();const r=oo(this._mousewheel.bind(this),50);this._mousewheelHandler=e=>{e.preventDefault(),r(e)},D$(this.element,O0,this._mousewheelHandler)}_initOptions(e){this.options=cN({},this.options,e)}_initElement(e){this.element=e,YV(e,"k-map"),e.style.position="relative",e.setAttribute("data-role","map"),y1(e);const t=w1("<div />");this.element.appendChild(t)}initServices(e={}){this.widgetService=new z0(this,e)}initObserver(e={}){this.observers=[],this.addObserver(e.observer)}addObserver(e){e&&this.observers.push(e)}removeObserver(e){const t=this.observers.indexOf(e);t>=0&&this.observers.splice(t,1)}requiresHandlers(e){const t=this.observers;for(let n=0;n<t.length;n++)if(t[n].requiresHandlers(e))return!0}trigger(e,t={}){t.sender=this;const n=this.observers;let i=!1;for(let r=0;r<n.length;r++)n[r].trigger(e,t)&&(i=!0);return i||super.trigger(e,t),i}_notifyObserver(e,t={}){t.sender=this;const n=this.observers;let i=!1;for(let r=0;r<n.length;r++)n[r].trigger(e,t)&&(i=!0);return i}zoom(e){let t=this.options;let n;if(HN(e)){const i=P0.round(WN(e,t.minZoom,t.maxZoom));t.zoom!==i&&(t.zoom=i,this.widgetService.notify("zoomChange",{zoom:t.zoom}),this._reset()),n=this}else n=t.zoom;return n}center(e){let t;if(e){const n=n1.create(e);const i=n1.create(this.options.center);n.equals(i)||(this.options.center=n.toArray(),this.widgetService.notify(F1,{center:this.options.center}),this._reset()),t=this}else t=n1.create(this.options.center);return t}extent(e){let t;return e?(this._setExtent(e),t=this):t=this._getExtent(),t}setOptions(e={}){const t=this.element;this.destroy(),y1(t),this._init(t,e,{},this.context),this._reset()}locationToLayer(e,t){let n=!this.options.wraparound;const i=n1.create(e);return this.crs.toPoint(i,this._layerSize(t),n)}layerToLocation(e,t){let n=!this.options.wraparound;const i=H0.create(e);return this.crs.toLocation(i,this._layerSize(t),n)}locationToView(e){const t=n1.create(e);let n=this.locationToLayer(this._viewOrigin);return this.locationToLayer(t).translateWith(n.scale(-1))}viewToLocation(e,t){const n=this.locationToLayer(this._getOrigin(),t);const i=H0.create(e).clone().translateWith(n);return this.layerToLocation(i,t)}eventOffset(e){let t;let n;let i=FN(this.element);if(e.x&&e.x[F0]||e.y&&e.y[F0])t=e.x[F0]-i.left,n=e.y[F0]-i.top;else{let r=e.originalEvent||e;t=YN(r.pageX,r.clientX)-i.left,n=YN(r.pageY,r.clientY)-i.top}return new ba(t,n)}eventToView(e){let t=this.eventOffset(e);return this.locationToView(this.viewToLocation(t))}eventToLayer(e){return this.locationToLayer(this.eventToLocation(e))}eventToLocation(e){let t=this.eventOffset(e);return this.viewToLocation(t)}viewSize(){let e=this.element;let t=this._layerSize();let n=e.clientWidth;return this.options.wraparound||(n=L0(t,n)),{width:n,height:L0(t,e.clientHeight)}}exportVisual(){return this._reset(),!1}hideTooltip(){this._tooltip&&this._tooltip.hide()}_setOrigin(e,t){let n,i=this.viewSize();const r=this._origin=n1.create(e);return n=this.locationToLayer(r,t),n.x+=i.width/2,n.y+=i.height/2,this.options.center=this.layerToLocation(n,t).toArray(),this.widgetService.notify(F1,{center:this.options.center}),this}_getOrigin(e){let t,n=this.viewSize();return!e&&this._origin||(t=this.locationToLayer(this.center()),t.x-=n.width/2,t.y-=n.height/2,this._origin=this.layerToLocation(t)),this._origin}_setExtent(e){let t=R1.create(e);let n=t.se.clone();this.options.wraparound&&n.lng<0&&e.nw.lng>0&&(n.lng=180+(180+n.lng));const i=new R1(t.nw,n);this.center(i.center());let r=this.element.clientWidth;let o=this.element.clientHeight;let a;for(a=this.options.maxZoom;a>=this.options.minZoom;a--){let e=this.locationToLayer(i.nw,a);let t=this.locationToLayer(i.se,a);let n=P0.abs(t.x-e.x);let s=P0.abs(t.y-e.y);if(n<=r&&s<=o)break}this.zoom(a)}_getExtent(){let e=this._getOrigin();let t=this.locationToLayer(e);let n=this.viewSize();t.x+=n.width,t.y+=n.height;let i=this.layerToLocation(t);return new R1(e,i)}_zoomAround(e,t){this._setOrigin(this.layerToLocation(e,t),t),this.zoom(t)}_initControls(){let 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))}_createControlElement(e,t){let n=e.position||t;let i="."+T1(n).replace(" ",".");let r=this.element.querySelector(".k-map-controls"+i)||[];if(0===r.length){let e=document.createElement("div");YV(e,"k-map-controls "+T1(n)),r=e,this.element.appendChild(r)}let o=document.createElement("div");return r.appendChild(o),o}_createAttribution(e){let t=this._createControlElement(e,"bottomRight");this.attribution=new M1(t,e)}_createNavigator(e){let t=this._createControlElement(e,"topLeft");let n=this.navigator=new E1(t,cN({},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)}_navigatorPan(e){let t=this.scroller;let n=t.scrollLeft+e.x;let i=t.scrollTop-e.y;let r=this._virtualSize;let o=this.element.clientWidth;let a=this.element.clientHeight;n=WN(n,r.x.min,r.x.max-o),i=WN(i,r.y.min,r.y.max-a),this.scroller.one("scroll",b1(this._scrollEnd,this)),this.scroller.scrollTo(-n,-i)}_navigatorCenter(){this.center(this.options.center)}_createZoomControl(e){let t=this._createControlElement(e,"topLeft");let n=this.zoomControl=new P1(t,e,this.options.icons);this._zoomControlChange=this._zoomControlChange.bind(this),n.bind("change",this._zoomControlChange)}_zoomControlChange(e){this.trigger("zoomStart",{originalEvent:e})||(this.zoom(this.zoom()+e.delta),this.trigger("zoomEnd",{originalEvent:e}))}_initScroller(){let e=this.support.mobileOS?.93:.9;let t=!1!==this.options.zoomable;let n=this.scroller=new I0(this.element.children[0],{friction:e,velocityMultiplier:5,zoom:t,mousewheelScrolling:!1,supportDoubleTap:!0});n.bind("scroll",b1(this._scroll,this)),n.bind("scrollEnd",b1(this._scrollEnd,this)),n.userEvents.bind("gesturestart",b1(this._scaleStart,this)),n.userEvents.bind("gestureend",b1(this._scale,this)),n.userEvents.bind("doubleTap",b1(this._doubleTap,this)),n.userEvents.bind("tap",b1(this._tap,this)),this.scrollElement=n.scrollElement}_initLayers(){let e=this.options.layers,t=this.layers=[];for(let n=0;n<e.length;n++){let i=e[n];const r=this._createLayer(i);t.push(r)}}_createLayer(e){let t=e.type||"shape";let n=this.options.layerDefaults[t];let i=t===R0?cN({},this.options.markerDefaults,e,{icons:this.options.icons}):cN({},n,e);let r=new(0,V0[t])(this,i);return t===R0&&(this.markers=r),r}_createTooltip(){return new O1(this.widgetService,this.options.tooltip)}_initMarkers(){const e=(this.options.layers||[]).filter((e=>e&&e.type===R0));e.length>0||(this.markers=new v0(this,cN({},this.options.markerDefaults,{icons:this.options.icons})),this.markers.add(this.options.markers))}_scroll(e){let t=this.locationToLayer(this._viewOrigin).round();let n=e.sender.movable;let i=new ba(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()})}_scrollEnd(e){this._scrollOffset&&this._panComplete()&&(this._scrollOffset=null,this._panEndTimestamp=L$(),this.trigger("panEnd",{originalEvent:e,origin:this._getOrigin(),center:this.center()}))}_panComplete(){return L$()-(this._panEndTimestamp||0)>50}_scaleStart(e){if(this.trigger("zoomStart",{originalEvent:e})){let t=e.touches[1];t&&t.cancel()}}_scale(e){let t=this.scroller.movable.scale;let n=this._scaleToZoom(t);let i=new ba(e.center.x,e.center.y);let r=this.viewToLocation(i,n);let o=this.locationToLayer(r,n).translate(-i.x,-i.y);this._zoomAround(o,n),this.trigger("zoomEnd",{originalEvent:e})}_scaleToZoom(e){let t=this._layerSize()*e/this.options.minSize;let n=P0.log(t)/P0.log(2);return P0.round(n)}_reset(){this.attribution&&this.attribution.filter(this.center(),this.zoom()),this._viewOrigin=this._getOrigin(!0),this._resetScroller(),this.hideTooltip(),this.trigger("beforeReset"),this.trigger("reset")}_resetScroller(){let e=this.scroller;let t=e.dimensions.x;let n=e.dimensions.y;let i=this._layerSize();let r=this.extent().nw;let o=this.locationToLayer(r).round();e.movable.round=!0,e.reset(),e.userEvents.cancel();let a=this.zoom();e.dimensions.forcedMinScale=B0(2,this.options.minZoom-a),e.dimensions.maxScale=B0(2,this.options.maxZoom-a);let s={min:-o.x,max:i-o.x};let l={min:-o.y,max:i-o.y};if(this.options.wraparound&&(s.max=20*i,s.min=-s.max),!1===this.options.pannable){let e=this.viewSize();s.min=l.min=0,s.max=e.width,l.max=e.height}t.makeVirtual(),n.makeVirtual(),t.virtualSize(s.min,s.max),n.virtualSize(l.min,l.max),this._virtualSize={x:s,y:l}}_renderLayers(){}_layerSize(e){const t=YN(e,this.options.zoom);return this.options.minSize*B0(2,t)}_tap(e){if(!this._panComplete())return;let t=this.eventOffset(e);this.hideTooltip(),this.trigger("click",{originalEvent:e,location:this.viewToLocation(t)})}_doubleTap(e){if(!1!==this.options.zoomable&&!this.trigger("zoomStart",{originalEvent:e})){let t=this.zoom()+1;let n=this.eventOffset(e);let i=this.viewToLocation(n);let r=this.locationToLayer(i,t).translate(-n.x,-n.y);this._zoomAround(r,t),this.trigger("zoomEnd",{originalEvent:e})}}_mousewheel(e){let t=PN(e)>0?-1:1;let n=this.options;let i=this.zoom();let r=WN(i+t,n.minZoom,n.maxZoom);if(!1!==n.zoomable&&r!==i&&!this.trigger("zoomStart",{originalEvent:e})){let t=this.eventOffset(e);let n=this.viewToLocation(t);let i=this.locationToLayer(n,r).translate(-t.x,-t.y);this._zoomAround(i,r),this.trigger("zoomEnd",{originalEvent:e})}}_toDocumentCoordinates(e){const t=FN(this.element);return{left:GN(e.x+t.left),top:GN(e.y+t.top)}}};XN(N0,{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}),S1(N0,["beforeReset","click","markerActivate","markerClick","markerCreated","markerMouseEnter","markerMouseLeave","pan","panEnd","reset","shapeClick","shapeCreated","shapeFeatureCreated","shapeMouseEnter","shapeMouseLeave","zoomEnd","zoomStart"]);const $0=(e,t)=>e.map(t).reduce(((e,t)=>e+t),0);const U0=(e,t)=>e.y0===t.y0?e.index-t.index:e.y0+e.y1-t.y0-t.y1;const W0=(e,t)=>U0(e.source,t.source);const j0=(e,t)=>U0(e.target,t.target);const q0=e=>e.value;function G0(e){e.forEach((e=>{e.targetLinks.forEach((e=>{e.source.sourceLinks.sort(j0)})),e.sourceLinks.forEach((e=>{e.target.targetLinks.sort(W0)}))}))}const K0=(e,t)=>"left"===e.align?e.depth:"right"===e.align?t-e.height:e.sourceLinks.length?e.depth:t;let Y0=class{constructor(e){const{offset:t={},align:n}=e.nodesOptions;this.data={nodes:e.nodes.map((e=>cN({},{offset:t,align:n},e))),links:e.links.map((e=>cN({},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}calculate(){const{nodes:e,links:t}=this.data;this.connectLinksToNodes(e,t),this.calculateNodeValues(e);const n=this.calculateNodeHeights(e);if(n)return{nodes:[],links:[],columns:[],circularLinks:n};this.calculateNodeDepths(e);const i=this.calculateNodeColumns(e);return this.calculateNodeBreadths(i),this.applyNodesOffset(e),this.calculateLinkBreadths(e),Object.assign({},this.data,{columns:i})}connectLinksToNodes(e,t){const n=new Map;e.forEach(((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((e=>{e.source=n.get(e.sourceId),e.target=n.get(e.targetId),e.source.sourceLinks.push(e),e.target.targetLinks.push(e)}))}calculateNodeValues(e){e.forEach((e=>{e.value=Math.max($0(e.sourceLinks,q0),$0(e.targetLinks,q0))}))}calculateNodeDepths(e){let t=new Set(e);let n=new Set;let i=0;for(;t.size;){const e=Array.from(t);for(let t=0;t<e.length;t++){const r=e[t];r.depth=i;for(let e=0;e<r.sourceLinks.length;e++){const t=r.sourceLinks[e];n.add(t.target)}}i++,t=n,n=new Set}}calculateNodeHeights(e){const t=e.length;let n=new Set(e);let i=new Set;let r=0;const o=e=>{e.height=r,e.targetLinks.forEach((e=>{i.add(e.source)}))};for(;n.size;){if(n.forEach(o),r++,r>t)return!0;n=i,i=new Set}return!1}calculateNodeColumns(e){const t=(n=e,i=e=>e.depth,Math.max.apply(null,n.map(i)));var n,i;const r=(this.width-this.offsetX-this.nodeWidth)/t;const o=new Array(t+1);for(let n=0;n<e.length;n++){const i=e[n];const a=Math.max(0,Math.min(t,K0(i,t)));i.x0=this.offsetX+a*r,i.x1=i.x0+this.nodeWidth,i.layer=a,o[a]=o[a]||[],o[a].push(i)}return o}calculateNodeBreadths(e){const t=(n=e,i=e=>(this.height-this.offsetY-(e.length-1)*this.nodePadding)/$0(e,q0),Math.min.apply(null,n.map(i)));var n,i;if(e.forEach((e=>{let n=this.offsetY;e.forEach((e=>{e.y0=n,e.y1=n+e.value*t,n=e.y1+this.nodePadding,e.sourceLinks.forEach((e=>{e.width=e.value*t}))})),n=(this.height-n+this.nodePadding)/(e.length+1),e.forEach(((e,t)=>{e.y0+=n*(t+1),e.y1+=n*(t+1)}))})),!1!==this.autoLayout){const t=void 0!==this.loops?this.loops:e.length-1;const n=this.targetColumnIndex||1;for(let i=0;i<t;i++)this.reverse?(this.uncurlLinksToRight(e,n),this.uncurlLinksToLeft(e,n)):(this.uncurlLinksToLeft(e,n),this.uncurlLinksToRight(e,n))}e.forEach(G0)}applyNodesOffset(e){e.forEach((e=>{const t=(e.offset?e.offset.left:0)||0;const n=(e.offset?e.offset.top:0)||0;e.x0+=t,e.x1+=t,e.y0+=n,e.y1+=n}))}calculateLinkBreadths(e){e.forEach((e=>{const{sourceLinks:t,targetLinks:n}=e;let i=e.y0;let r=i;t.forEach((e=>{e.x0=e.source.x1,e.y0=i+e.width/2,i+=e.width})),n.forEach((e=>{e.x1=e.target.x0,e.y1=r+e.width/2,r+=e.width}))}))}uncurlLinksToRight(e,t){const n=e.length;for(let i=t;i<n;i++){const t=e[i];t.forEach((e=>{let t=0;let n=0;e.targetLinks.forEach((i=>{let r=i.value*(e.layer-i.source.layer);t+=this.targetTopPos(i.source,e)*r,n+=r}));let i=0===t?0:t/n-e.y0;e.y0+=i,e.y1+=i,G0([e])})),t.sort(U0),this.arrangeNodesVertically(t)}}uncurlLinksToLeft(e,t){for(let n=e.length-1-t;n>=0;n--){const t=e[n];for(let e=0;e<t.length;e++){const n=t[e];let i=0;let r=0;n.sourceLinks.forEach((e=>{let t=e.value*(e.target.layer-n.layer);i+=this.sourceTopPos(n,e.target)*t,r+=t}));let o=0===i?0:i/r-n.y0;n.y0+=o,n.y1+=o,G0([n])}t.sort(U0),this.arrangeNodesVertically(t)}}arrangeNodesVertically(e){const t=e.length-1;this.arrangeUp(e,this.height,t),this.arrangeDown(e,this.offsetY,0)}arrangeDown(e,t,n){let i=t;for(let t=n;t<e.length;t++){const n=e[t];const r=Math.max(0,i-n.y0);n.y0+=r,n.y1+=r,i=n.y1+this.nodePadding}}arrangeUp(e,t,n){let i=t;for(let t=n;t>=0;--t){const n=e[t];const r=Math.max(0,n.y1-i);n.y0-=r,n.y1-=r,i=n.y0-this.nodePadding}}sourceTopPos(e,t){let n=t.y0-(t.targetLinks.length-1)*this.nodePadding/2;for(let i=0;i<t.targetLinks.length;i++){const r=t.targetLinks[i];if(r.source===e)break;n+=r.width+this.nodePadding}for(let i=0;i<e.sourceLinks.length;i++){const r=e.sourceLinks[i];if(r.target===t)break;n-=r.width}return n}targetTopPos(e,t){let n=e.y0-(e.sourceLinks.length-1)*this.nodePadding/2;for(let i=0;i<e.sourceLinks.length;i++){const r=e.sourceLinks[i];if(r.target===t)break;n+=r.width+this.nodePadding}for(let i=0;i<t.targetLinks.length;i++){const r=t.targetLinks[i];if(r.source===e)break;n-=r.width}return n}};const Q0=e=>new Y0(e).calculate();function X0(e,t,n,i,r,o){const a=(o-t)*(n-e);const s=(i-t)*(r-e);return a>s?1:a===s?0:-1}function Z0(e,t){const n=X0(e.x0,e.y0,e.x1,e.y1,t.x1,t.y1);const i=X0(e.x0,e.y0,e.x1,e.y1,t.x0,t.y0);const r=X0(e.x0,e.y0,t.x0,t.y0,t.x1,t.y1);const o=X0(e.x1,e.y1,t.x0,t.y0,t.x1,t.y1);return n!==i&&r!==o}class J0{constructor(e){this.options=cN({},this.options,e),this.createVisual()}createVisual(){this.visual=this.createElement()}exportVisual(){return this.visual}createElement(){const e=this.options.visual;let t;return t=e?e({sender:this.getSender(),options:this.visualOptions(),createVisual:()=>this.getElement()}):this.getElement(),t}getSender(){return this}}let e2=class extends J0{getElement(){return Rs.fromRect(this.getRect(),this.visualOptions())}getRect(){const e=this.options.node;return new ya([e.x0,e.y0],[e.x1-e.x0,e.y1-e.y0])}getLabelText(e){let t=e.labels.ariaTemplate;if(t)return t({node:e.node})}visualOptions(){const e=cN({},this.options,this.options.node);const 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}}createFocusHighlight(){if(this.options.navigatable)return this._highlight=Rs.fromRect(this.getRect(),{stroke:this.options.focusHighlight.border,visible:!1}),this._highlight}focus(e){if(this._highlight){const{highlight:t=!0}=e||{};t&&this._highlight.options.set("visible",!0);const n=this.options.node.id;this.visual.options.set("id",n),this.options.root()&&this.options.root().setAttribute(rV,n)}}blur(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(rV))}};const t2=(e,t,n)=>e.color||t[n%t.length];const n2=(e,t,n,i)=>{const r=cN({},t,t.node);return cN({},{color:t2(e,n,i)},r,{node:e},{visual:e.visual,opacity:e.opacity,offset:e.offset,color:e.color})};const i2=(e,t,n,i,r)=>{const o=1-r;const a=o*o;const s=r*r;return e*a*o+3*t*r*a+3*n*s*o+i*s*r};const r2=(e,t)=>{const n=e.width/2;const i=t?e.x1:e.x0;const r=t?e.x0:e.x1;const o=t?e.y1:e.y0;const a=t?e.y0:e.y1;const s=(i+r)/2;const l=[s,i2(o,o,a,a,.5)];const c=.4999;const d=[i2(i,s,s,r,c),i2(o,o,a,a,c)];const h=function(e,t,n,i,r){let o=(e+n)/2;let a=(t+i)/2;let s,l;if(t===i)s=0,l=r/2;else if(e===n)s=r/2,l=0;else{let o=-1/((i-t)/(n-e));s=r/2/Math.sqrt(1+o*o),l=o*s}return{P1:{x:o-s,y:a-l},P2:{x:o+s,y:a+l}}}(l[0],l[1],d[0],d[1],e.width);const u=[s,i2(o+n,o+n,a+n,a+n,.5)];const p=h.P1.y>h.P2.y?h.P1:h.P2;const f=(o>a?1:-1)*n;const m=function(e,t,n,i,r){const o=(e.x+t.x)/2,a=(e.y+t.y)/2;const s=t.x-e.x;let l=-(t.y-e.y);let c=s;const d=Math.sqrt(l*l+c*c);l=l/d*n,c=c/d*n;const h=o+l,u=a+c;const p=o-l,f=a-c;const m=r.x-i.x;const g=r.y-i.y;const v=g*(h-p)-m*(u-f);if(Math.abs(v)<1e-10)return null;const _=(m*(f-i.y)-g*(p-i.x))/v;const b=((h-p)*(f-i.y)-(u-f)*(p-i.x))/v;if(_>=0&&_<=1&&b>=0&&b<=1)return{x:p+_*(h-p)};return null}(p,{x:u[0],y:u[1]},n,{x:u[0],y:u[1]},{x:Math.max(1,u[0]+f),y:u[1]})||{x:(u[0]+p.x)/2};const g=i;const v=r;return s-(m.x-.125*g-.125*v)/.75};let o2=class extends J0{getElement(){const e=this.options.link;const{x0:t,x1:n,y0:i,y1:r}=e;const o=(t+n)/2;return new Rs(this.visualOptions()).moveTo(t,i).curveTo([o,i],[o,r],[n,r])}getLabelText(e){let t=e.labels.ariaTemplate;if(t)return t({link:e.link})}visualOptions(){const e=this.options;const t=this.options.link;const n=this.getLabelText(e);return{stroke:{width:e.link.width,color:t.color||e.color,opacity:HN(t.opacity)?t.opacity:e.opacity},role:"graphics-symbol",ariaRoleDescription:"Link",ariaLabel:n}}createFocusHighlight(){if(!this.options.navigatable)return;const{link:e}=this.options;const{x0:t,x1:n,y0:i,y1:r}=e;const o=(t+n)/2;const a=e.width/2;const s=r2(e,this.options.rtl);this._highlight=new Rs({stroke:this.options.focusHighlight.border,visible:!1}).moveTo(t,i+a).lineTo(t,i-a).curveTo([o+s,i-a],[o+s,r-a],[n,r-a]).lineTo(n,r+a).curveTo([o-s,r+a],[o-s,i+a],[t,i+a])}focus(e){if(this._highlight){const{highlight:t=!0}=e||{};t&&this._highlight.options.set("visible",!0);const n=`${this.options.link.sourceId}->${this.options.link.targetId}`;this.visual.options.set("id",n),this.options.root()&&this.options.root().setAttribute(rV,n)}}blur(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(rV))}};const a2="inside";const s2="before";const l2="after";class c2 extends J0{getElement(){const e=cN({},this.options,this.options.node.label);const{node:t,diagramMinX:n,diagramMaxX:i,text:r,offset:o,rtl:a}=e;let s=e.position;if(a&&s!==a2&&(s=s===s2?l2:s2),!e.visible||!r)return null;const l=new hU(t.x0,t.y0,t.x1,t.y1);const c=this.visualOptions();a&&!c.align&&(c.align="right");const d=new RU(r,c);d.reflow(new hU);const h=d.box;const u=l.center().y-h.height()/2;const p=t.x1+h.width()>i;const f=t.x0-h.width()<n;let m=s===s2||s===a2&&p?s2:l2;a&&(m=s===l2||s===a2&&f?l2:s2);const g=[m===s2?t.x0-h.width():t.x1,u];const v=new hU(g[0],g[1],g[0]+h.width(),g[1]+h.height());return v.translate(o.left||0,o.top||0),d.reflow(v),d.renderVisual(),d.visual}visualOptions(){const e=cN({},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}}}XN(c2,{position:a2});const d2=(e,t,n,i,r)=>cN({},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});class h2 extends J0{getElement(){const e=this.options;const{drawingRect:t,text:n}=e;if(!1===e.visible||!n)return null;const i=FU.buildTitle(n,e);return i.reflow(t),i.renderVisual(),i.visual}createElement(){return this.getElement()}}XN(h2,{align:lV,border:{width:0},margin:mN(5),padding:mN(5)});const u2=(e,t)=>e.node.x0-t.node.x0!=0?e.node.x0-t.node.x0:e.node.y0-t.node.y0;const p2=(e,t)=>e.node.x1-t.node.x1!=0?e.node.x1-t.node.x1:t.node.y0-e.node.y0;class f2 extends J0{getElement(){const e=this.options;const{drawingRect:t,rtl:n,nodes:i=[],item:r,position:o}=e;if(!1===e.visible||!i.length)return null;const a=e.labels||{};let s;a.content&&(s=_N(a));const l=i.map((e=>{const t=e.label&&e.label.text||"";return{text:s?s({text:t,node:e}):t,area:{background:void 0!==r.areaBackground?r.areaBackground:e.color,opacity:void 0!==r.areaOpacity?r.areaOpacity:e.opacity},node:e}}));l.sort((e=>e?p2:u2)(n));const c=n&&o!==kV&&o!==IV;const d=new MY(Object.assign({},e,{data:l,reverse:c}),{rtl:n});return d.reflow(t),d.renderVisual(),d.visual}createElement(){return this.getElement()}}XN(f2,{markers:{visible:!1},item:{type:Nj,cursor:WV,opacity:1},position:sV,align:lV,accessibility:{role:"presentation",ariaLabel:null,ariaRoleDescription:null},border:{width:0}});const m2="link";const g2="node";class v2 extends O${constructor(e,t,n){super(),this._initTheme(n),this._setOptions(t),this._initElement(e),this._initSurface(),t&&t.data&&(this._redraw(),this._initResizeObserver(),this._initNavigation(e))}destroy(){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}_initElement(e){this.element=e,YV(e,["k-chart","k-sankey"]),e.setAttribute("role","graphics-document");const{title:t}=this.options;t.text&&e.setAttribute("aria-label",t.text),t.description&&e.setAttribute("aria-roledescription",t.description)}_initSurface(){this.surface||(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())}_initNavigation(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})}firstFocusableNode(){return this.columns[0][0]}_initResizeObserver(){const e=new ResizeObserver((e=>{e.forEach((e=>{const{width:t,height:n}=e.contentRect;e.target!==this.element||this.size&&this.size.width===t&&this.size.height===n||(this.size={width:t,height:n},this.surface.setSize(this.size),this.resize=!0,this._redraw())}))}));this._resizeObserver=e,e.observe(this.element)}_createSurface(){return Fc.create(this.surfaceElement,{mouseenter:this._mouseenter.bind(this),mouseleave:this._mouseleave.bind(this),mousemove:this._mousemove.bind(this),click:this._click.bind(this)})}_initTheme(e){let t=e||this.theme||{};this.theme=t,this.options=cN({},t,this.options)}setLinksOpacity(e){this.linksVisuals.forEach((t=>{this.setOpacity(t,e,t.linkOptions.opacity)}))}setLinksInactivityOpacity(e){this.linksVisuals.forEach((t=>{this.setOpacity(t,e,t.linkOptions.highlight.inactiveOpacity)}))}setOpacity(e,t,n){e.options.set("stroke",Object.assign({},e.options.stroke,{opacity:HN(n)?n:t}))}trigger(e,t){let n=t.element.dataItem;const i=t.element.type;const r=Object.assign({},t,{type:e,targetType:i,dataItem:n});return super.trigger(e,r)}_mouseenter(e){const t=e.element;const n=t.type===m2;const i=t.type===g2;const r=Boolean(t.chartElement&&t.chartElement.options.node);if(n&&this.trigger("linkEnter",e)||i&&this.trigger("nodeEnter",e))return;const{highlight:o}=this.options.links;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){const e=this.nodesVisuals.get(t.chartElement.options.node.id);this.highlightLinks(e,o)}}_mouseleave(e){const t=e.element;const n=t.type===m2;const i=t.type===g2;const r=Boolean(t.chartElement&&t.chartElement.options.node);const o=e.originalEvent.relatedTarget;n&&o&&"text"===o.nodeName||((n||i)&&(this.tooltipTimeOut&&(clearTimeout(this.tooltipTimeOut),this.tooltipTimeOut=null),this.tooltipShown=!1,this.trigger("tooltipHide",e)),n&&this.trigger("linkLeave",e)||i&&this.trigger("nodeLeave",e)||(n||i||r)&&this.linksVisuals.forEach((e=>{this.setOpacity(e,this.options.links.opacity,e.linkOptions.opacity)})))}_mousemove(e){const{followPointer:t,delay:n}=this.options.tooltip;const i=e.element;const r=i.type;if(r!==m2&&r!==g2||this.tooltipShown&&!t)return;const o=e.originalEvent;const a=this.element.getBoundingClientRect();const s=o.clientX-a.left<a.width/2;const l=o.clientY-a.top<a.height/2;if(e.tooltipData={popupOffset:{left:o.pageX,top:o.pageY},popupAlign:{horizontal:s?"left":"right",vertical:l?"top":"bottom"}},r===g2){const{sourceLinks:t,targetLinks:n}=i.dataItem;const r=n.length?n:t;e.nodeValue=r.reduce(((e,t)=>e+t.value),0)}this.tooltipTimeOut&&(clearTimeout(this.tooltipTimeOut),this.tooltipTimeOut=null);const c=t&&this.tooltipShown?0:n;this.tooltipTimeOut=setTimeout((()=>{this.trigger("tooltipShow",e),this.tooltipShown=!0,this.tooltipTimeOut=null}),c)}_click(e){const t=e.element;const n=t.dataItem;const i=t.type===m2;const r=t.type===g2;const 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){const t={sourceId:n.source.id,targetId:n.target.id,value:n.value};this.sameLink(o.link,t)||(this._focusState={node:n.source,link:t},this._focusLink({highlight:!1})),this.trigger("linkClick",e)}}sameNode(e,t){return e&&t&&e.id===t.id}sameLink(e,t){return e&&t&&e.sourceId===t.sourceId&&e.targetId===t.targetId}_focusNode(e){this._cleanFocusHighlight();const t=this._focusState.node;this.models.map.get(t.id).focus(e)}_focusLink(e){this._cleanFocusHighlight();const t=this._focusState.link;this.models.map.get(`${t.sourceId}-${t.targetId}`).focus(e)}_focusNextNode(e=1){const t=this._focusState.node;const n=this.columns.findIndex((e=>e.find((e=>e.id===t.id))));const i=this.columns[n];const r=i.findIndex((e=>e.id===t.id));const o=i[r+e];o&&(this._focusState.node=o,this._focusNode())}_focusNextLink(e=1){const t=this._focusState.node;const n=this._focusState.link;const i=t.sourceLinks.findIndex((e=>e.sourceId===n.sourceId&&e.targetId===n.targetId));const r=t.targetLinks.findIndex((e=>e.sourceId===n.sourceId&&e.targetId===n.targetId));if(-1!==i){const n=t.sourceLinks[i+e];n&&(this._focusState.link=n,this._focusLink())}else if(-1!==r){const n=t.targetLinks[r+e];n&&(this._focusState.link=n,this._focusLink())}}_focusSourceNode(){const e=this._focusState.link;const t=this.models.map.get(e.sourceId);this._focusState={node:t.options.node,link:null},this._focusNode()}_focusTargetNode(){const e=this._focusState.link;const t=this.models.map.get(e.targetId);this._focusState={node:t.options.node,link:null},this._focusNode()}_focusSourceLink(){const e=this._focusState.node.sourceLinks[0];e&&(this._focusState.link=e,this._focusLink())}_focusTargetLink(){const e=this._focusState.node.targetLinks[0];e&&(this._focusState.link=e,this._focusLink())}_focus(){this._skipFocusHighlight||(this._focusState.link?this._focusLink():this._focusNode()),this._skipFocusHighlight=!1}_blur(){this._cleanFocusHighlight()}_onDown(){this._hasFocus()||(this._skipFocusHighlight=!0)}_hasFocus(){return this.element.ownerDocument.activeElement===this.element}_cleanFocusHighlight(){this.models.nodes.forEach((e=>e.blur())),this.models.links.forEach((e=>e.blur()))}_keydown(e){let t=this["on"+e.key];const n=this.options.rtl;n&&"ArrowLeft"===e.key?t=this.onArrowRight:n&&"ArrowRight"===e.key&&(t=this.onArrowLeft),t&&t.call(this,e)}onEscape(e){e.preventDefault(),this._focusState={node:this.firstFocusableNode(),link:null},this._focusNode()}onArrowDown(e){e.preventDefault(),this._focusState.link?this._focusNextLink(1):this._focusNextNode(1)}onArrowUp(e){e.preventDefault(),this._focusState.link?this._focusNextLink(-1):this._focusNextNode(-1)}onArrowLeft(e){e.preventDefault(),this._focusState.link?this._focusSourceNode():this._focusTargetLink()}onArrowRight(e){e.preventDefault(),this._focusState.link?this._focusTargetNode():this._focusSourceLink()}highlightLinks(e,t){e&&(this.setLinksInactivityOpacity(t.inactiveOpacity),e.links.forEach((e=>{this.setOpacity(e,t.opacity,e.linkOptions.highlight.opacity)})))}_destroySurface(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())}_destroyResizeObserver(){this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)}_initSurfaceElement(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element.appendChild(this.surfaceElement))}_destroySurfaceElement(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)}setOptions(e,t){this._setOptions(e),this._initTheme(t),this._initSurface(),this._redraw()}_redraw(){this.surface.clear();const{width:e,height:t}=this._getSize();this.size={width:e,height:t},this.surface.setSize(this.size),this.createVisual(),this.surface.draw(this.visual)}_getSize(){return this.element.getBoundingClientRect()}createVisual(){this.visual=this._render()}titleBox(e,t){if(!e||!1===e.visible||!e.text)return null;return new h2(Object.assign({},{drawingRect:t},e)).exportVisual().chartElement.box}legendBox(e,t,n){if(!e||!1===e.visible)return null;return new f2(Object.assign({},{nodes:t},e,{drawingRect:n})).exportVisual().chartElement.box}calculateSankey(e,t){const{title:n,legend:i,data:r,nodes:o,labels:a,nodeColors:s,disableAutoLayout:l,disableKeyboardNavigation:c,rtl:d}=t;const h=!l;const u=((o.focusHighlight||{}).border||{}).width||0;const p=c?0:u/2;const f=new hU(0,0,e.width,e.height);f.unpad(p);const m=this.titleBox(n,f);let g=f.clone();if(m){const t=m.height();n.position===BV?(f.unpad({top:t}),g=new hU(0,t,e.width,e.height)):(f.shrink(0,t),g=new hU(0,0,e.width,e.height-t))}const v=this.legendBox(i,r.nodes,g);const _=i&&i.position||f2.prototype.options.position;v&&(_===kV&&f.unpad({left:v.width()}),_===IV&&f.shrink(v.width(),0),_===BV&&f.unpad({top:v.height()}),_===sV&&f.shrink(0,v.height()));const{nodes:b,circularLinks:w}=Q0(Object.assign({},e,{offsetX:0,offsetY:0,width:f.width(),height:f.height()}));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:m};const y=new hU;const k=b.reduce(((e,t)=>Math.min(e,t.x0)),1/0);const x=b.reduce(((e,t)=>Math.max(e,t.x1)),0);b.forEach(((e,t)=>{if(d){const{x0:t,x1:n}=e;e.x0=x-n,e.x1=x-t}const n=n2(e,o,s,t);const i=new e2(n);y.wrap(BU(i.exportVisual().rawBBox()));const r=new c2(d2(e,a,d,k,x)).exportVisual();r&&y.wrap(BU(r.rawBBox()))}));let C=f.x1;let S=f.y1;let T=f.width()+C;let M=f.height()+S;if(T-=y.x2>f.width()?y.x2-f.width():0,M-=y.y2>f.height()?y.y2-f.height():0,C+=y.x1<0?-y.x1:0,S+=y.y1<0?-y.y1:0,!1===h)return{sankey:Q0(Object.assign({},e,{offsetX:C,offsetY:S,width:T,height:M,autoLayout:!1})),legendBox:v,titleBox:m};if(this.resize&&h&&this.permutation)return this.resize=!1,{sankey:Q0(Object.assign({},e,{offsetX:C,offsetY:S,width:T,height:M},this.permutation)),legendBox:v,titleBox:m};const A=Q0(Object.assign({},e,{offsetX:C,offsetY:S,width:T,height:M,autoLayout:!1})).columns.length;const D=[];const E=(t,n)=>{let i=(e=>{let t=0;const n=e.length;for(let i=0;i<n;i++){const r=e[i];for(let o=i+1;o<n;o++){const n=e[o];Z0(r,n)&&(t+=Math.min(r.value,n.value))}}return t})(Q0(Object.assign({},e,{offsetX:C,offsetY:S,width:T,height:M,loops:2,targetColumnIndex:t,reverse:n})).links);return D.push({crosses:i,reverse:n,targetColumnIndex:t}),0===i};for(let e=1;e<=A-1&&(!E(e,!1)&&!E(e,!0));e++);const I=Math.min.apply(null,D.map((e=>e.crosses)));const z=D.find((e=>e.crosses===I));this.permutation={targetColumnIndex:z.targetColumnIndex,reverse:z.reverse};return{sankey:Q0(Object.assign({},e,{offsetX:C,offsetY:S,width:T,height:M},this.permutation)),legendBox:v,titleBox:m}}_render(e,t){const n=e||this.options;const i=t||this;const{labels:r,nodes:o,links:a,nodeColors:s,title:l,legend:c,rtl:d,disableKeyboardNavigation:h}=n;let u=n.data;const{width:p,height:f}=i.size;const m=Object.assign({},u,{width:p,height:f,nodesOptions:o,title:l,legend:c});const{sankey:g,titleBox:v,legendBox:_}=this.calculateSankey(m,n);d&&(e=>{const{nodes:t,links:n}=e;const i=Math.min(...t.map((e=>e.x0)));const r=Math.max(...t.map((e=>e.x1)))-i;t.forEach((e=>{const t=r-(e.x1-2*i);const n=r-(e.x0-2*i);e.x0=t,e.x1=n})),n.forEach((e=>{const t=r-(e.x1-2*i);const n=r-(e.x0-2*i);e.x1=t,e.x0=n}))})(g);const{nodes:b,links:w,columns:y}=g;i.columns=y.map((e=>{const t=e.slice();return t.sort(((e,t)=>e.y0-t.y0)),t}));const k=new Us({clip:Rs.fromRect(new ya([0,0],[p,f]))});if(v){const e=new h2(Object.assign({},l,{drawingRect:v})).exportVisual();k.append(e)}if(g.circularLinks)return k;const x=new Map;i.nodesVisuals=x;const C={nodes:[],links:[],map:new Map};i.models=C;const S=[];b.forEach(((e,t)=>{const n=n2(e,o,s,t);n.root=()=>i.element,n.navigatable=!0!==h;const r=new e2(n);const a=r.exportVisual();a.links=[],a.type=g2,e.color=n.color,e.opacity=n.opacity,a.dataItem=Object.assign({},u.nodes[t],{color:n.color,opacity:n.opacity,sourceLinks:e.sourceLinks.map((e=>({sourceId:e.sourceId,targetId:e.targetId,value:e.value}))),targetLinks:e.targetLinks.map((e=>({sourceId:e.sourceId,targetId:e.targetId,value:e.value})))}),x.set(e.id,a),C.nodes.push(r),C.map.set(e.id,r),k.append(a),r.createFocusHighlight(),r._highlight&&S.push(r._highlight)}));const T=w.slice().sort(((e,t)=>t.value-e.value));const M=[];i.linksVisuals=M,T.forEach((e=>{const{source:t,target:n}=e;const r=x.get(t.id);const o=x.get(n.id);const s=((e,t,n,i)=>{const r=cN({},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=()=>i.element,s.navigatable=!0!==h,s.rtl=d;const l=new o2(s);const c=l.exportVisual();c.type=m2,c.dataItem={source:Object.assign({},r.dataItem),target:Object.assign({},o.dataItem),value:e.value},c.linkOptions=s,M.push(c),r.links.push(c),o.links.push(c),C.links.push(l),C.map.set(`${t.id}-${n.id}`,l),l.createFocusHighlight(),l._highlight&&S.push(l._highlight),k.append(c)}));const A=b.reduce(((e,t)=>Math.min(e,t.x0)),1/0);const D=b.reduce(((e,t)=>Math.max(e,t.x1)),0);if(b.forEach((e=>{const t=d2(e,r,d,A,D);const n=new c2(t).exportVisual();n&&k.append(n)})),_){const e=new f2(Object.assign({},c,{rtl:d,drawingRect:_,nodes:b})).exportVisual();k.append(e)}if(0!==S.length){const e=new Us;e.append(...S),k.append(e)}return k}exportVisual(e){const t=e&&e.options?cN({},this.options,e.options):this.options;const n={size:{width:HN(e&&e.width)?e.width:this.size.width,height:HN(e&&e.height)?e.height:this.size.height}};return this._render(t,n)}_setOptions(e){this.options=cN({},this.options,e)}}const _2={opacity:1,width:2,color:aV};XN(v2,{title:{position:BV},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:{border:Object.assign({},_2)},labels:{ariaTemplate:({node:e})=>e.label.text}},links:{colorType:"static",opacity:.4,highlight:{opacity:.8,inactiveOpacity:.2},focusHighlight:{border:Object.assign({},_2)},labels:{ariaTemplate:({link:e})=>`${e.source.label.text} to ${e.target.label.text}`}},tooltip:{followPointer:!1,delay:200}});const b2=(e,t,n)=>{const i=new Set;const r=new Map;const o=new Map;e.forEach((e=>{t.forEach((t=>{i.add(t.value(e))}));for(let i=0;i<t.length-1;i++){const a=t[i].value(e);const s=t[i+1].value(e);const l=`${a}_${s}`;const c=n.value(e);const d=r.get(l);void 0!==d?r.set(l,d+c):(r.set(l,c),o.set(l,{source:a,target:s}))}}));const a=new Map;const s=Array.from(i).map(((e,t)=>(a.set(e,t),{id:t,label:{text:String(e)}})));const l=Array.from(r).map((([e,t])=>{const{source:n,target:i}=o.get(e);return{sourceId:a.get(n),targetId:a.get(i),value:t}}));return{nodes:s,links:l}};const w2=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});const y2="12px";const k2="16px";const x2=[{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"}}];const C2=x2[0].value;const S2="line";const T2="scatter";const M2=["column","bar",S2,T2];const A2={type:S2,width:0};function D2(e){return e&&M2.includes(e)}const E2=["string","date","number"];const I2=["number"];const z2={bar:[{axisType:"category",types:E2},{axisType:"value",types:I2}],column:[{axisType:"category",types:E2},{axisType:"value",types:I2}],line:[{axisType:"category",types:E2},{axisType:"value",types:I2}],pie:[{axisType:"category",types:E2},{axisType:"value",types:I2,count:1}],scatter:[{axisType:"category",types:E2},{axisType:"value",types:I2}]};function P2(e,t){return`${t||""} ${e||""}`.trim()}function L2(e){const t=(e||"").indexOf(" ");return{size:e&&e.substring(0,t),name:e&&e.substring(t+1)}}const B2=(e,t,n)=>{const{size:i}=L2(n);return e?P2(e,i||t):""};const H2=(e,t,n)=>{const{name:i}=L2(n);return e?P2(i||t,e):""};const R2=e=>null!=e;const F2=e=>{const t=structuredClone(e[0]);return t.forEach(((t,n)=>{if(!R2(t.value))for(let i=0;i<e.length;i++){const r=e[i][n].value;if(R2(r)){t.value=r;break}}})),t};const O2=(e,t)=>{const n=[];const i=F2(e);t.types.forEach((e=>{i.forEach(((t,i)=>{typeof t.value===e&&n.push(i)}))}));const r=n.findIndex((t=>{const n=e.map((e=>e[t].value));return new Set(n).size===n.length}));return Math.max(r,0)};const V2=(e,t)=>{const n=[];const i=F2(e);return t.forEach((e=>{e.types.forEach((e=>{i.forEach(((t,i)=>{typeof t.value===e&&n.push(i)}))}))})),n};const N2=()=>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});const $2=(e,t,n)=>{const i=N2();i.seriesType=t,i.data=e||[],i.legend={visible:!0,position:"bottom"};const r=z2[t];if(!r||!e.length)return i;const o=e[0].slice();i.columns=e[0].map((e=>String(e.field)));const a=r.find((e=>"category"===e.axisType));let s=-1;a&&(s=n&&n.categoryAxis?i.columns.indexOf(n.categoryAxis):O2(e,a));const l=r.filter((e=>"value"===e.axisType));let c=V2(e,l);c.includes(s)&&(c.length>1?c=c.filter((e=>e!==s)):s=-1);const d=[];c.forEach((n=>{const i=o[n];const r=[];e.forEach((e=>{r.push(e[n].value)})),d.push(Object.assign({},{name:i.field,type:t,data:r,stack:!1,labels:{visible:!1}},t===T2?A2:{}))}));const h=s>-1?e.map((e=>String(R2(e[s].value)?e[s].value:" "))):[];return d.length&&(i.series=d.map(((e,t)=>Object.assign({},e,{id:t}))),i.initialSeries=structuredClone(i.series)),i.categoryAxis=[{categories:h,labels:{visible:!0,rotation:"auto"}}],i.categoryField=i.columns[s],i};const U2=(e,t,n)=>{const i=N2();i.seriesType=t,i.data=e||[];const r=z2[t];if(!r||!e.length)return i;const o=e[0].map((e=>e.field));const a=r.find((e=>"category"===e.axisType));let s=-1;a&&(s=n&&n.categoryAxis?o.indexOf(n.categoryAxis):O2(e,a));const l=r.filter((e=>"value"===e.axisType));let c=[];c=n&&n.valueAxis?[o.indexOf(n.valueAxis)]:V2(e,l),c.includes(s)&&c.length>1&&(c=c.filter((e=>e!==s))),"number"==typeof l[0].count&&(c=c.slice(0,l[0].count));const d=s>-1?e.map((e=>String(e[s].value))):[];const h=[];return e.forEach((e=>{const t={};c.forEach((n=>{const i=e[n];t[i.field]=i.value||0,t[e[s].field]=e[s].value||" "})),h.push(t)})),i.columns=o,i.categoryAxis=[{categories:d,title:{text:""}}],i.series=[{id:0,data:h,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 W2(e,t){return(D2(t)?$2:U2)(e,t)}function j2(e,t){const 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(let t=0;t<n.series.length;t++)n.series[t].color=e.series[t].color,n.series[t].labels=e.series[t].labels;return e.series.every((e=>e.labels&&e.labels.visible))&&D2(n.seriesType)&&D2(e.seriesType)&&n.series.forEach((e=>{e.labels=e.labels||{},e.labels.visible=!0})),n}function q2(e,t,n){const i=Object.assign({},e);switch(t){case w2.seriesType:return W2(i.data,n);case w2.stacked:return i.series=i.series.map((e=>Object.assign({},e,{stack:n}))),i.stack=n,i;case w2.categoryAxisX:if(i.seriesType&&D2(i.seriesType)){return j2(i,$2(i.data,i.seriesType,{categoryAxis:n}))}if("pie"===i.seriesType){return j2(i,U2(i.data,i.seriesType,{categoryAxis:n}))}return i;case w2.valueAxisY:if("pie"===i.seriesType){return j2(i,U2(i.data,i.seriesType,{categoryAxis:i.categoryField,valueAxis:n}))}return i;case w2.seriesChange:return i.series=n,i;case w2.areaMarginLeft:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{left:n})}),i;case w2.areaMarginRight:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{right:n})}),i;case w2.areaMarginTop:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{top:n})}),i;case w2.areaMarginBottom:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{bottom:n})}),i;case w2.areaBackground:return i.area=Object.assign({},i.area,{background:n}),i;case w2.titleText:return i.title=Object.assign({},i.title,{text:n}),i;case w2.titleFontName:return i.title=Object.assign({},i.title,{font:B2(n,"20px",i.title&&i.title.font)}),i;case w2.titleFontSize:return i.title=Object.assign({},i.title,{font:H2(n,C2,i.title&&i.title.font)}),i;case w2.titleColor:return i.title=Object.assign({},i.title,{color:n}),i;case w2.subtitleText:return i.subtitle=Object.assign({},i.subtitle,{text:n}),i;case w2.subtitleFontName:return i.subtitle=Object.assign({},i.subtitle,{font:B2(n,"16px",i.subtitle&&i.subtitle.font)}),i;case w2.subtitleFontSize:return i.subtitle=Object.assign({},i.subtitle,{font:H2(n,C2,i.subtitle&&i.subtitle.font)}),i;case w2.subtitleColor:return i.subtitle=Object.assign({},i.subtitle,{color:n}),i;case w2.seriesColor:return i.series=i.series.map((e=>Object.assign({},e,{color:n.seriesName===e.name?n.color:e.color}))),i;case w2.seriesLabel:return i.series=i.series.map((e=>n.all||n.seriesName===e.name?Object.assign({},e,{labels:{visible:n.visible}}):e)),i;case w2.legendVisible:return i.legend=Object.assign({},i.legend,{visible:n}),i;case w2.legendFontName:{const e=i.legend||{};return i.legend=Object.assign({},e,{labels:Object.assign({},e.labels,{font:B2(n,y2,e.labels&&e.labels.font)})}),i}case w2.legendFontSize:{const e=i.legend||{};return i.legend=Object.assign({},e,{labels:Object.assign({},e.labels,{font:H2(n,C2,e.labels&&e.labels.font)})}),i}case w2.legendColor:{const e=i.legend||{};return i.legend=Object.assign({},e,{labels:Object.assign({},e.labels,{color:n})}),i}case w2.legendPosition:return i.legend=Object.assign({},i.legend,{position:n}),i;case w2.categoryAxisTitleText:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{text:n})}))),i;case w2.categoryAxisTitleFontName:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{font:B2(n,k2,e.title&&e.title.font)})}))),i;case w2.categoryAxisTitleFontSize:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{font:H2(n,C2,e.title&&e.title.font)})}))),i;case w2.categoryAxisTitleColor:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{color:n})}))),i;case w2.categoryAxisLabelsFontName:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{font:B2(n,y2,e.labels&&e.labels.font)})}))),i;case w2.categoryAxisLabelsFontSize:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{font:H2(n,C2,e.labels&&e.labels.font)})}))),i;case w2.categoryAxisLabelsColor:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{color:n})}))),i;case w2.categoryAxisLabelsRotation:{const e=R2(n)?n:"auto";return i.categoryAxis=(i.categoryAxis||[]).map((t=>Object.assign({},t,{labels:Object.assign({},t.labels,{rotation:e})}))),i}case w2.categoryAxisReverseOrder:return i.categoryAxis=(i.categoryAxis||[]).map((e=>Object.assign({},e,{reverse:n}))),i;case w2.valueAxisTitleText:return i.valueAxis&&0!==i.valueAxis.length?i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{text:n})}))):i.valueAxis=[{title:{text:n}}],i;case w2.valueAxisTitleFontName:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{font:B2(n,k2,e.title&&e.title.font)})}))),i;case w2.valueAxisTitleFontSize:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{font:H2(n,C2,e.title&&e.title.font)})}))),i;case w2.valueAxisTitleColor:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{title:Object.assign({},e.title,{color:n})}))),i;case w2.valueAxisLabelsFormat:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{format:n})}))),i;case w2.valueAxisLabelsFontName:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{font:B2(n,y2,e.labels&&e.labels.font)})}))),i;case w2.valueAxisLabelsFontSize:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{font:H2(n,C2,e.labels&&e.labels.font)})}))),i;case w2.valueAxisLabelsColor:return i.valueAxis=(i.valueAxis||[]).map((e=>Object.assign({},e,{labels:Object.assign({},e.labels,{color:n})}))),i;case w2.valueAxisLabelsRotation:{const e=R2(n)?n:"auto";return i.valueAxis=(i.valueAxis||[]).map((t=>Object.assign({},t,{labels:Object.assign({},t.labels,{rotation:e})}))),i}default:return i}}const G2=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"});const K2=Object.freeze({getWizardDataFromDataRows:function(e){const t=[];return e.forEach((e=>{const{dataItem:n,dataColumns:i}=e;const r=[];i.forEach((e=>{r.push({field:e.title||e.field,value:kN(e.field)(n)})})),t.push(r)})),t},ActionTypes:w2,createInitialState:function(e,t,n){const i=W2(e,n&&n.seriesType||t);return void 0!==(n&&n.stack)?q2(i,w2.stacked,n.stack):i},createState:W2,fontNames:x2,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:D2,mergeStates:j2,parseFont:L2,updateState:q2,messages:G2});const Y2=1.5;const Q2=.4;const X2="#000";const Z2="Arial, Helvetica, sans-serif";const J2="11px "+Z2;const e3="12px "+Z2;const t3="16px "+Z2;const n3="transparent";const i3="#fff";const r3={type:Jj};const o3={type:Nj};const a3=Object.assign({},o3,{markers:{visible:!1},highlight:{visible:!1}});const s3=()=>({icon:{border:{width:1}},label:{font:e3,padding:3},line:{length:10,width:2},legendItem:a3,visible:!0});const l3=()=>({highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:o3,opacity:.4});const c3=()=>({highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:o3,opacity:.4});const d3=()=>({outliersField:"",meanField:"",border:{_brightness:.8,width:1},downColor:i3,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:a3});const h3=()=>({gap:Y2,spacing:Q2,target:{color:"#ff0000"},legendItem:a3});const u3=()=>({width:2,legendItem:r3});const p3=()=>({line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:o3,opacity:.5});const f3=()=>({markers:{visible:!1},legendItem:r3,width:2});const m3=()=>({gap:.5,line:{color:X2,width:1},legendItem:a3,spacing:Q2});const g3=()=>({labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:a3});const v3=g3;const _3=e=>Object.assign({color:yV,trendline:{},markers:{visible:!1},width:1,dashType:"longDash",legendItem:r3},e);const b3=e=>({visible:!0,labels:{font:J2},overlay:e.gradients?{}:{gradient:"none"},area:l3(),rangeArea:c3(),verticalRangeArea:c3(),bar:{gap:Y2,spacing:Q2,legendItem:a3},boxPlot:d3(),bubble:{border:{width:0},labels:{background:n3},legendItem:a3,opacity:.6},bullet:h3(),candlestick:{border:{_brightness:.8,width:1},downColor:i3,gap:1,highlight:{border:{opacity:1,width:2},line:{width:2}},line:{color:X2,width:1},legendItem:a3,spacing:.3},column:{gap:Y2,spacing:Q2,legendItem:a3},heatmap:{labels:{color:"",background:n3,visible:!0},highlight:{border:{width:0}},legendItem:a3},pie:{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:a3},donut:{margin:1,legendItem:a3},funnel:g3(),pyramid:v3(),horizontalWaterfall:m3(),line:u3(),notes:s3(),ohlc:{gap:1,highlight:{line:{opacity:1,width:3}},line:{width:1},legendItem:a3,spacing:.3},radarArea:p3(),radarLine:f3(),radarColumn:{legendItem:a3},polarArea:p3(),polarLine:f3(),polarScatter:{legendItem:r3},rangeBar:{gap:Y2,spacing:Q2,legendItem:a3},rangeColumn:{gap:Y2,spacing:Q2,legendItem:a3},scatter:{legendItem:r3},scatterLine:{width:1,legendItem:r3},verticalArea:l3(),verticalBoxPlot:d3(),verticalBullet:h3(),verticalLine:u3(),waterfall:m3(),linearTrendline:_3(),exponentialTrendline:_3({style:"smooth"}),logarithmicTrendline:_3({style:"smooth"}),polynomialTrendline:_3({style:"smooth"}),powerTrendline:_3({style:"smooth"}),movingAverageTrendline:_3()});const w3=(e={})=>({axisDefaults:{labels:{font:e3},notes:s3(),title:{font:t3,margin:5}},categoryAxis:{majorGridLines:{visible:!0}},navigator:{pane:{height:90,margin:{top:10}}},seriesDefaults:b3(e),title:{font:t3},subtitle:{font:e3},legend:{labels:{font:e3}}});const y3="--kendo-chart-series-";const k3=e=>e.ownerDocument.defaultView.getComputedStyle(e);const x3={};const C3=(e,t)=>{let n=k3(e).getPropertyValue(t);return/^color-mix/i.test(n)&&(n=((e,t)=>{if(x3[e])return x3[e];const n=t.style.color;t.style.color=e;const i=k3(t).color;return t.style.color=n,x3[e]=i,i})(n,e)),n};const S3=(e,t)=>parseFloat(k3(e).getPropertyValue(t));const T3=(e,t,n,i)=>{const r=k3(e);return[r.getPropertyValue(t),r.getPropertyValue(n),r.getPropertyValue(i)||r.fontFamily].join(" ")};const M3=e=>{const t=k3(e);const n=[];let i=1;let r=t.getPropertyValue(`${y3}${i}`);for(;r||i<=30;)n.push(r),i++,r=t.getPropertyValue(`${y3}${i}`);return n};const A3=e=>T3(e,"--kendo-font-weight","--kendo-chart-font-size","--kendo-font-family");const D3=e=>T3(e,"--kendo-chart-pane-title-font-weight","--kendo-chart-pane-title-font-size","--kendo-font-family");const E3=e=>C3(e,"--kendo-chart-text");const I3=e=>({color:E3(e),font:T3(e,"--kendo-font-weight","--kendo-chart-title-font-size","--kendo-font-family")});const z3=e=>{const t=E3(e);return{labels:{color:t,font:A3(e)},title:{color:t}}};const P3=e=>{const t=C3(e,"--kendo-chart-inactive");return Object.assign({},{inactiveItems:{labels:{color:t},markers:{color:t}}},z3(e))};const L3=e=>{const t=E3(e);return{pointer:{color:C3(e,"--kendo-chart-gauge-pointer")},scale:{labels:{color:t},rangePlaceholderColor:C3(e,"--kendo-chart-gauge-track"),minorTicks:{color:t},majorTicks:{color:t},line:{color:t}}}};const B3=e=>{const t=C3(e,"--kendo-chart-major-lines");const n=C3(e,"--kendo-chart-text");const i=T3(e,"--kendo-font-weight","--kendo-chart-label-font-size","--kendo-font-family");const r=C3(e,"--kendo-chart-bg");const o=(e=>({icon:{background:C3(e,"--kendo-chart-notes-bg"),border:{color:C3(e,"--kendo-chart-notes-border")}},line:{color:C3(e,"--kendo-chart-notes-lines")},label:{font:A3(e)}}))(e);const a=S3(e,"--kendo-chart-area-opacity");const s=C3(e,"--kendo-color-surface");const l=C3(e,"--kendo-chart-primary-bg");const c=()=>({downColor:t,mean:{color:s},median:{color:s},whiskers:{color:l}});const d=()=>({line:{color:t}});const h=()=>({opacity:a,highlight:{inactiveOpacity:S3(e,"--kendo-chart-area-inactive-opacity")}});const u=()=>({highlight:{inactiveOpacity:S3(e,"--kendo-chart-line-inactive-opacity")}});const p=()=>({target:{color:n}});return{axisDefaults:{crosshair:{color:C3(e,"--kendo-chart-crosshair-bg")},labels:{color:n,font:i},line:{color:t},majorGridLines:{color:t},minorGridLines:{color:C3(e,"--kendo-chart-minor-lines")},notes:structuredClone(o),title:{color:n,font:A3(e)}},chartArea:{background:r},legend:P3(e),seriesColors:M3(e),seriesDefaults:{area:h(),verticalArea:h(),radarArea:h(),boxPlot:c(),verticalBoxPlot:c(),bullet:p(),verticalBullet:p(),horizontalWaterfall:d(),waterfall:d(),line:u(),verticalLine:u(),candlestick:{downColor:n,line:{color:n}},errorBars:{color:C3(e,"--kendo-chart-error-bars-bg")},icon:{border:{color:t}},labels:{background:r,color:n,font:i,opacity:a},notes:structuredClone(o)},subtitle:{color:n,font:D3(e)},title:I3(e),paneDefaults:{title:{font:D3(e)}}}};var H3=Object.freeze({__proto__:null,Aggregates:vj,AreaChart:XG,AreaSegment:KG,AxisGroupRangeTracker:ZG,Bar:tK,BarChart:aK,BarLabel:JG,BoxPlot:cK,BoxPlotChart:hK,BubbleChart:mK,Bullet:vK,BulletChart:_K,Candlestick:sK,CandlestickChart:lK,CategoricalChart:BG,CategoricalErrorBar:fG,CategoricalPlotArea:cY,Chart:jQ,ChartAxis:uj,ChartContainer:kK,ChartPane:fj,ChartPlotArea:mj,ClipAnimation:jG,ClusterLayout:rK,Crosshair:yK,CrosshairTooltip:wK,DefaultAggregates:LK,DonutChart:rQ,DonutPlotArea:oQ,DonutSegment:iQ,ErrorBarBase:pG,ErrorRangeCalculator:kj,Highlight:uY,Legend:MY,LegendItem:SY,LegendLayout:bY,LineChart:GG,LinePoint:FG,LineSegment:OG,MousewheelZoom:_Y,OHLCChart:jK,OHLCPoint:WK,Pane:xK,Pannable:gY,PieAnimation:RY,PieChart:eQ,PieChartMixin:JY,PiePlotArea:nQ,PieSegment:YY,PlotAreaBase:TK,PlotAreaEventsMixin:IK,PlotAreaFactory:AY,PointEventsMixin:HG,RangeAreaChart:UK,RangeAreaPoint:OK,RangeBar:BK,RangeBarChart:HK,ScatterChart:pK,ScatterErrorBar:uK,ScatterLineChart:FY,Selection:IY,SeriesAggregator:zK,SeriesBinder:bj,SharedTooltip:PY,SplineAreaSegment:QG,SplineSegment:UG,StackWrap:oK,Tooltip:zY,WaterfallChart:GK,WaterfallSegment:qK,XYPlotArea:GY,ZoomSelection:vY,anyHasZIndex:mG,appendIfNotNull:gG,areNumbers:vG,bindSegments:bG,categoriesCount:wG,constants:uG,countNumbers:gj,createOutOfRangePoints:PG,equalsIgnoreCase:yG,evalOptions:kG,filterSeriesByType:xG,findAxisByName:pj,getField:_j,hasGradientOverlay:TG,hasValue:MG,isDateAxis:AG,parseDateCategory:SG,segmentVisible:_G,singleItemOrArray:DG,unclipBox:LG});window.kendo.dataviz=window.kendo.dataviz||{},kendo.deepExtend(kendo.dataviz,kendo.deepExtend({},hj)),kendo.dataviz.Gradients=DU;const R3=kendo.jQuery;let F3=kendo.dataviz;let O3=kendo.drawing;let V3=QU;for(let e in hj)_$(e)&&(F3[e]=hj[e]);F3.SASS_THEMES=["sass","default-v2","bootstrap-v4","material-v2"],F3.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 O3.exportSVG(this.exportVisual(),e)},exportImage:function(e){return O3.exportImage(this.exportVisual(e),e)},exportPDF:function(e){return O3.exportPDF(this.exportVisual(),e)},svg:function(){if(O3.svg.Surface)return O3.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(O3.canvas.Surface){var e=R3("<div />").css({display:"none",width:this.element.width(),height:this.element.height()}).appendTo(document.body);var t=new O3.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")}},V3.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}}),V3.TemplateService.register({compile:kendo.template}),F3.inArray=function(e,t){if(t)return-1!==t.indexOf(e)},F3.Point2D=dU,F3.Box2D=hU,F3.mwDelta=function(e){return PN(e.originalEvent)};kendo;!function(e){var t;kendo.dataviz.autoTheme=function(n){if(!n&&t)return t;var i={chart:w3()};var r=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(){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>';for(var 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 o(e,t){s(e,a(t,"backgroundColor"))}function a(e,t){return r.find(".k-var--"+e).css(t)}function s(e,t){var n=i;var r=e.split(".");var o=r.shift();for(;r.length>0;)n=n[o]=n[o]||{},o=r.shift();n[o]=t}function l(e,t){var n=parseFloat(a(t,"opacity"));!isNaN(n)&&n<1&&e.forEach((function(e){s("chart.seriesDefaults."+e+".highlight.inactiveOpacity",n)}))}var c,d;return function(){o("chart.axisDefaults.crosshair.color","chart-crosshair-background"),o("chart.axisDefaults.labels.color","normal-text-color"),o("chart.axisDefaults.line.color","chart-major-lines"),o("chart.axisDefaults.majorGridLines.color","chart-major-lines"),o("chart.axisDefaults.minorGridLines.color","chart-minor-lines"),o("chart.axisDefaults.notes.icon.background","chart-notes-background"),o("chart.axisDefaults.notes.icon.border.color","chart-notes-border"),o("chart.axisDefaults.notes.line.color","chart-notes-lines"),o("chart.axisDefaults.title.color","normal-text-color"),o("chart.chartArea.background","background"),o("chart.legend.inactiveItems.labels.color","chart-inactive"),o("chart.legend.inactiveItems.markers.color","chart-inactive"),o("chart.legend.labels.color","normal-text-color"),o("chart.seriesDefaults.boxPlot.downColor","chart-major-lines"),o("chart.seriesDefaults.boxPlot.mean.color","base"),o("chart.seriesDefaults.boxPlot.median.color","base"),o("chart.seriesDefaults.boxPlot.whiskers.color","primary"),o("chart.seriesDefaults.bullet.target.color","primary"),o("chart.seriesDefaults.candlestick.downColor","normal-text-color"),o("chart.seriesDefaults.candlestick.line.color","normal-text-color"),o("chart.seriesDefaults.errorBars.color","chart-error-bars-background"),o("chart.seriesDefaults.horizontalWaterfall.line.color","chart-major-lines"),o("chart.seriesDefaults.icon.border.color","chart-major-lines"),o("chart.seriesDefaults.labels.background","background"),o("chart.seriesDefaults.labels.color","normal-text-color"),o("chart.seriesDefaults.notes.icon.background","chart-notes-background"),o("chart.seriesDefaults.notes.icon.border.color","chart-notes-border"),o("chart.seriesDefaults.notes.line.color","chart-notes-lines"),o("chart.seriesDefaults.verticalBoxPlot.downColor","chart-major-lines"),o("chart.seriesDefaults.verticalBoxPlot.mean.color","base"),o("chart.seriesDefaults.verticalBoxPlot.median.color","base"),o("chart.seriesDefaults.verticalBoxPlot.whiskers.color","primary"),o("chart.seriesDefaults.verticalBullet.target.color","primary"),o("chart.seriesDefaults.waterfall.line.color","chart-major-lines"),o("chart.title.color","normal-text-color"),o("chart.subtitle.color","normal-text-color"),o("diagram.shapeDefaults.fill.color","primary"),o("diagram.shapeDefaults.content.color","primary-contrast"),o("diagram.shapeDefaults.connectorDefaults.fill.color","normal-text-color"),o("diagram.shapeDefaults.connectorDefaults.stroke.color","primary-contrast"),o("diagram.shapeDefaults.connectorDefaults.hover.fill.color","primary-contrast"),o("diagram.shapeDefaults.connectorDefaults.hover.stroke.color","normal-text-color"),o("diagram.editable.resize.handles.stroke.color","normal-text-color"),o("diagram.editable.resize.handles.fill.color","normal-background"),o("diagram.editable.resize.handles.hover.stroke.color","normal-text-color"),o("diagram.editable.resize.handles.hover.fill.color","normal-text-color"),o("diagram.selectable.stroke.color","normal-text-color"),o("diagram.connectionDefaults.stroke.color","normal-text-color"),o("diagram.connectionDefaults.content.color","normal-text-color"),o("diagram.connectionDefaults.selection.handles.fill.color","primary-contrast"),o("diagram.connectionDefaults.selection.handles.stroke.color","normal-text-color"),o("diagram.connectionDefaults.selection.stroke.color","normal-text-color"),o("gauge.pointer.color","gauge-pointer"),o("gauge.scale.labels.color","normal-text-color"),o("gauge.scale.minorTicks.color","normal-text-color"),o("gauge.scale.majorTicks.color","normal-text-color"),o("gauge.scale.line.color","normal-text-color"),o("gauge.scale.rangePlaceholderColor","gauge-track");var e=parseFloat(a("chart-area-opacity","opacity"));isNaN(e)||(s("chart.seriesDefaults.area.opacity",e),s("chart.seriesDefaults.radarArea.opacity",e),s("chart.seriesDefaults.verticalArea.opacity",e),s("chart.seriesDefaults.labels.opacity",e)),l(["area","verticalArea"],"chart-area-inactive-opacity"),l(["line","verticalLine"],"chart-line-inactive-opacity")}(),s("diagram.connectionDefaults.selection.handles.width",8),s("diagram.connectionDefaults.selection.handles.height",8),function(){function e(e){return a(e,"fontWeight")+" "+a(e,"fontSize")+" "+a(e,"fontFamily")}var t=e("chart-font");var n=e("chart-title-font");var i=e("chart-pane-title-font");var r=e("chart-label-font");s("chart.axisDefaults.labels.font",r),s("chart.axisDefaults.notes.label.font",t),s("chart.axisDefaults.title.font",t),s("chart.legend.labels.font",t),s("chart.seriesDefaults.labels.font",r),s("chart.seriesDefaults.notes.label.font",t),s("chart.title.font",n),s("chart.subtitle.font",i),s("chart.paneDefaults.title.font",i)}(),c=e(".k-var--series div").toArray(),d=e(".k-var--series-unset").css("backgroundColor"),s("chart.seriesColors",c.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);var r=e(n).css("backgroundColor");return r!==d&&(t[i]=r),t}),[])),r.remove(),t=i,i}}(window.kendo.jQuery);!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=window.kendo,n=t.dataviz.ui,i=t.deepExtend;var r="#000",o="#fff";var a=w3({gradients:!0});var s={scale:{labels:{font:"12px Arial,Helvetica,sans-serif"}}};var 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"]}}};var 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 h(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";var t="#7f7f7f";var n="#bdbdbd";var i="#c8c8c8";var r=["#008fd3","#99d101","#f39b02","#f05662","#c03c53","#acacac"];var a=r[0];var 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:h(r,["#cbe8f5","#eaf5cb","#fceacc","#fbdcdf","#f2d7dc","#eeeeee"])}})}(),function(){var e="#4e4e4e";var t="#7f7f7f";var n="#bdbdbd";var i="#c8c8c8";var r=["#0072c6","#5db2ff","#008a17","#82ba00","#ff8f32","#ac193d"];var a=r[0];var 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:h(r,["#cbe2f3","#deeffe","#cbe7d0","#e5f0cb","#fee8d5","#eed0d7"])}})}(),function(){var e="#32364c";var t="#7f7f7f";var n="#bdbdbd";var i="#dfe0e1";var r=["#ff4350","#ff9ea5","#00acc1","#80deea","#ffbf46","#ffd78c"];var a=r[0];var 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:h(r,["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"])}})}(),d("default-v2",{chart:{},gauge:{},diagram:{},treeMap:{colors:h(["#ff6358","#ffd246","#78d237","#28b4c8","#2d73f5","#aa46be"],["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"])}}),c.sass=c["default-v2"],function(){var e="#292b2c";var 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:h(t,["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"])}})}()}(window.kendo.jQuery);kendo;!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=kendo.dataviz;var n=kendo.ui;var i=n.Widget;var r=Os;var o=Vo;var a=Us;class s extends kl{constructor(){super(...arguments);var e=this.options;var t=this.options.endColor;var n=this.options.startColor;var 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;var n=t.options;var i=t.startColor;var r=t.color;var o=MN(n.oldAngle,n.newAngle,e);if(this.element.geometry().setEndAngle(o),r){var a=GN(MN(i.r,r.r,e));var s=GN(MN(i.g,r.g,e));var l=GN(MN(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,n){var i=t.ui.themes||{};var r=e.theme||"";var o=r.toLowerCase();if(-1!=t.SASS_THEMES.indexOf(o)){n.addClass("k-gauge");const e=L3(n[0]);return n.removeClass("k-gauge"),e}return(i[r]||i[o]||{}).gauge}(this.options,this.element),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;var t=e.options;var 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;var t;var 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;let n;let i;let 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;var t=this._getCenter();var n=this._getColor(this.value())||this.theme.pointer.color;var i=Math.min(t.x,t.y)-5-this.options.pointerWidth;var r=new Ia([t.x,t.y],i+this.options.pointerWidth/2);var o=this.circle=new Ra(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;var i=n.colors;var r=n.color;var o=t.isNumber(e)?e:0;if(i)for(var a=0;a<i.length;a++){var s=i[a];var l=s.color;var 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;var a=new $a([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=this._getSize();var i=this._getCenter();var r=i.x-e/2;var o=i.y-t/2;var a;var s;return e<n.width&&(a=r+e,r=Math.max(r,0),a>n.width&&(r-=a-n.width)),t<n.height&&(s=o+t)>n.height&&(o-=s-n.height),{left:r,top:o}},_getCenter:function(){var e=this._getSize();return new t.Point(e.width/2,e.height/2)},_getSize:function(){var e=this.element;var t=200,n=200;var i=e[0].offsetWidth;var 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;var n=this.surface;var i=this._surfaceElement();var r=this._getSize();t.elementSize(i,r),n?(this.surface.clear(),this.surface.resize()):this.surface=Fc.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;var o=kendo.geometry.Point,a=kendo.geometry.Rect,s=kendo.geometry.transform;var l=function(){};var 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];var a=r/this.options.scale;var l=o/this.options.scale;var c=n[0]||6*a;var d=n[1]||6*l;var h=a/c;var u=l/d;var p=Math.min(h,u);var 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;var i=this.size,r=i[0],o=i[1];var l=r/this.options.scale;var c=o/this.options.scale;var d=(null==e?void 0:e.width)||6*l;var h=(null==e?void 0:e.height)||6*c;var u=d/l;var p=h/c;var f=Math.min(u,p);var m=new a([0,0],[d,h]);var g=new t.Group({clip:t.Path.fromRect(m)});var v=new t.Group({transform:s().scale(f,f)});var _=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:h},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;var 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);var n=e.pageX;var r=e.pageY;var 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);var i=this.points[this.points.length-1];var 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",h="close",u="click";var 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,h],setOptions:function(n){var i=this.options;var r;var o=t.getValidCssClass("k-button-","size",i.size);var a=this.element.add(this._dialogPadEl).find("."+o);var s=e(this._pad.element).add(this._dialogPad.element);a.removeClass(o),this._clearCssClasses(i),this.element.removeClass(t.getValidCssClass("k-signature-","size",i.size)),t.deepExtend(i,n),this.options=i,this.element.width(i.width),this.element.height(i.height),this._dialogPadEl.width(i.width*i.popupScale),this._dialogPadEl.height(i.height*i.popupScale),r=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,r),this.enable(i.enable),this.readonly(i.readonly),this._hideLine(this.element),this._hideLine(this._dialogPadEl),this._applyCssClasses(this.element),this.element.find(".k-signature-maximize").toggle(i.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",i.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(u+l,".k-signature-clear",(function(){e.reset(),e.trigger(c)})).on(u+l,".k-signature-maximize",(function(){e._dialog.open(),e._dialog.wrapper.find(".k-signature-minimize").trigger("focus")}))},_createInput:function(){var t=this;var n=t.element.attr("name");var i=t.element.attr("autocomplete");var 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;var n=e.extend(!0,{},t.options,{onChange:function(){var e=o(t.element,!1);var 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=this;var r;n._dialogEl=e("<div>").appendTo(n.element),n._dialog=new i(n._dialogEl,{title:!1,closable:!1,open:function(){n.trigger(d)},close:function(){n.trigger(h)}}),n._dialogEl.removeAttr("tabindex").on("keydown",(function(e){e.keyCode===t.keys.ESC&&n._dialog.close()})),n._dialogPadEl=e("<div>").appendTo(n._dialog.element),n._createElements(n._dialogPadEl,"mini",!0,this.options.popupScale),r=n._dialogPadEl.find(".k-signature-canvas")[0],n._dialogPad=new s(r,e.extend(!0,{},n.options,{scale:n.options.popupScale,onChange:function(){var e=o(n.element,!1);var t=a(n.element,!1);n._dialogPad.exportImage({width:e*n.options.exportScale,height:t*n.options.exportScale}).then((function(e){n._pad.loadImage(e),n._value=e,n._input.val(e),n.trigger(c)}))},onDraw:function(){n._dialogEl.find(".k-button").hide()},onDrawEnd:function(){n._dialogEl.find(".k-button").show()}})),n._dialog.close(),n._dialogEl.on(u+l,".k-signature-clear",(function(){n.reset()})).on(u+l,".k-signature-minimize",(function(){n._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";o=t.html;var h=({value:e})=>`<li class='k-item' data-value='${i(e)}'><span>${i(e)}</span></li>`;var u=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(),"auto"!==i.options.adaptiveMode&&i._buttons(!0),i._attchHandlers(),i._shortCuts(),i._columns(),i._popup()},options:{name:"TimeSelector",columns:[],shortcuts:[],adaptiveMode:"none",adaptiveTitle:null,adaptiveSubtitle:null,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(){var e=this._listsContainer.find(".k-time-container.k-content.k-scrollable");var t=e.length;var n;var i;var r;var o;var a;for(var s=0;s<t;s++)i=p((n=e.eq(s)).find(".k-item:visible").eq(0)),o="translateY("+((r=n.outerHeight())-i)/2+"px)",a=r-i,n.find("ul").css({transform:o,"-ms-transform":o}),n.find(".k-scrollable-placeholder").css({height:n.find("ul").height()+a}),n.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;var r=this._listsContainer.find(".k-time-container.k-content.k-scrollable");var o=function(e){var t;var 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];var 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),h=p(o.find(".k-item:visible").eq(0)),u=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?(u.scrollTop(u.scrollTop()-h),n.preventDefault()):r==c.DOWN?(u.scrollTop(u.scrollTop()+h),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);var i=n.find(".k-item:visible").index(e(t.currentTarget));var r=p(n.find(".k-item:visible").eq(0));n.scrollTop(i*r)},_listScrollHandler:function(t){var n=this;var 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=e.scrollTop(),i=p(e.find(".k-item:visible").eq(0)),Math.max(Math.round(n/i),0));var n,i;return e.find(".k-item:visible").eq(t).attr("data-value")},_updateCurrentlySelected:function(){var t=this;var 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+'"]');var i=p(n);e.scrollTop(e.find(".k-item:visible").index(n)*i)},_renderList:function(n,r){if(r){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]}));var a="";for(var s=r.min;s<=r.max;s+=r.step)a+=h({value:t.format(r.selectorFormat,s)});o.find("ul").html(a),o.appendTo(n)}},_columns:function(){var e=this;var t;var n=e.options;if(e._listsContainer)for(var i=0;i<n.columns.length;i++)t=n.columns[i],e._renderList(e._listsContainer,t)},_shortCuts:function(){var n=this;var i=n.options;var r;if(n._shortcuts)for(var a=0;a<i.shortcuts.length;a++)r=i.shortcuts[a],e(o.renderButton(`<button class="k-button ${t.getValidCssClass("k-button-","size",n.options.size||"medium")} k-button-solid k-button-solid-base k-rounded-md">`+r.text+"</button>",{rounded:i.rounded})).attr(t.attr("value"),r.value).appendTo(n._shortcuts)},_buttons:function(t){const n=this;const r=n.options;const a=e("<div class='k-actions k-actions-stretched k-actions-horizontal k-timeduration-footer'>"+o.renderButton('<button class="k-time-cancel k-button">'+i(r.messages.cancel)+"</button>",{rounded:r.rounded,size:r.size})+o.renderButton('<button class="k-time-accept k-button k-button-solid k-button-solid-primary">'+i(r.messages.set)+"</button>",{rounded:r.rounded,size:r.size})+"</div>");return t&&a.appendTo(n._timeSelectorWrapper),a},_wrappers:function(){var n=this;var 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:i.adaptiveTitle||"Set time",subtitle:i.adaptiveSubtitle,closeButton:{icon:"check",themeColor:"primary"},footerTemplate:e._buttons.bind(e),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))}}))}});function p(e){return e.length&&e[0].getBoundingClientRect().height}n.plugin(u)}(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",h="change",u="k-focus",p="aria-expanded",f="mouseenter"+(S=".kendoTimeDurationPicker")+" mouseleave"+S,m="k-disabled",g="aria-hidden",v="aria-disabled",_="aria-readonly",b="disabled",w="readonly",y="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 M=r.extend({init:function(i,o){var c=this;var d;o=o||{},r.fn.init.call(c,i,o),c._columns=(d=o.columns,a(d,(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}))),c.options.columns=c._columns,c.options.readonly=o.readonly!==t?o.readonly:Boolean(c.element.attr("readonly")),c.options.enable=o.enable!==t?o.enable:!Boolean(c.element.is("[disabled]")||e(i).parents("fieldset").is(":disabled")),c.options.inputMode=o.inputMode||c.element.attr("inputmode")||"text",c.bigScreenMQL=l("large"),"auto"==c.options.adaptiveMode&&c.bigScreenMQL.onChange((()=>{c._timeSelector&&(c._timeSelector.popup&&c._timeSelector.popup.wrapper&&c._timeSelector.popup.wrapper.remove(),c._timeSelector.destroy(),c._timeSelector=null),c._popupView()})),c._wrapper(),c._button(),c._applyCssClasses(),c._input(),c._popupView(),c._buildMask(),c._validation(),c._editable({readonly:c.options.readonly,disable:!c.options.enable}),c._ariaLabel(c._timeSelector._listsContainer),c.options.value&&(c.value(o.value),c._old=c._maskedInput.val()),c._canUpdateLast=!0,n.notify(c)},options:{name:"TimeDurationPicker",columns:[],separator:",",shortcuts:[],value:null,adaptiveMode:"none",adaptiveTitle:null,adaptiveSubtitle:null,size:"medium",fillMode:"solid",rounded:"medium",messages:{set:"Set",cancel:"Cancel",days:"Days",hours:"Hours",minutes:"Minutes",milliseconds:"Milliseconds",seconds:"Seconds"}},events:[c,d,h],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(w,i).attr(v,n).attr(_,i)):(o.removeClass(m).on(f,t._toggleHover),r&&r.length&&(r.removeAttr(b),r.removeAttr(w)),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;var 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,adaptiveTitle:t.adaptiveTitle,adaptiveSubtitle:t.adaptiveSubtitle,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(h)}}))},_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=this.options.columns;var t;var n="";var i;var r=0;this._emtpyMask="",this._maskParts=[];for(var o=0;o<e.length;o++)i={},t=e[o].format,o&&(n=this.options.separator),n+=t.replace(/#/g,"_"),this._emtpyMask+=n,i.end=this._emtpyMask.length-1,i.mask=t.replace(/#/g,"_"),i.symbolsLength=i.mask.match(/_/g).length,i.start=this._emtpyMask.indexOf(i.mask,r),i.numberEnd=this._emtpyMask.lastIndexOf(k)+1,i.numberStart=this._emtpyMask.indexOf(k,i.start),r+=i.mask.length,this._maskParts.push(i);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",inputmode:t.options}).addClass("k-input-inner").insertBefore(t.element);let i=t.options.inputMode;i&&t._maskedInput.attr("inputmode",i),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]);var 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(h))},_focusout:function(){this._updateValueFromInput(),this._triggerChange(),this._canUpdateLast=!0,this.wrapper.removeClass(u)},_focus:function(){var e=this;e._mouseOnInput||setTimeout((function(){e._selectNearestSection(0)}),10),e._mouseOnInput=!1,e.wrapper.addClass(u)},_selectNearestSection:function(e){var t;for(var 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;var i=e.indexOf(n,t);var 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=this._emtpyMask.split(this.options.separator);var n;e+="";for(var i=0;i<t.length;i++)(n=t[i].match(/_/g).length)>e.length?t[i]=t[i].replace(k.repeat(n),"0".repeat(n-e.length)+e):(t[i]=t[i].replace(k.repeat(n),e.substring(0,n)),e=e.substring(n,n.length));return t.join(this.options.separator)},_clearParts:function(e,t,n){var i=e.split(this.options.separator);var r=0;var o;for(var a=0;a<i.length;a++)o=r+i[a].length,(r<=t&&o>=t||r<=n&&o>=n)&&(i[a]=this._getEmptyPart(r)),r+=i[a].length+1;return i.join(this.options.separator)},_updatePart:function(e,t){var i=this._getEmptyPart(this._old.indexOf(e));var r=e.substring(i.indexOf(k),i.lastIndexOf(k)+1);var 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=this.options.separator;var i=e.caret!=t?e.caret:x(this._maskedInput[0])[0];var r=this._maskedInput.val();var o;e.next?(o=r.indexOf(n,i))<0?o=r.length-1:o++:(o=r.lastIndexOf(n,i))<0?o=0:o--,this._selectNearestSection(o)},_keydown:function(e){var t=e.keyCode;var n=this.options.separator;var i;var r;var o;var a;var s;if(this._backward=t===C.BACKSPACE,t==C.LEFT||t==C.RIGHT){if(e.preventDefault(),i=x(this._maskedInput[0])[0],a=(r=this._maskedInput.val()).indexOf(n,i),s=r.lastIndexOf(n,i),a<0&&t==C.RIGHT||s<0&&t==C.LEFT)return;o=t==C.LEFT?s-1:a+1,this._selectNearestSection(o),t==C.LEFT&&(this._canUpdateLast=!0)}else this._timeSelector.popup.visible()?this._timeSelector._scrollerKeyDownHandler(e):t==C.UP||t==C.DOWN?(e.preventDefault(),e.altKey&&this._timeSelector.toggle()):t==C.ENTER&&(this._updateValueFromInput(),this._triggerChange())},_updateValueFromTimeSelector:function(){var e=this;var t=function(e){var t;var 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}}(e._value);var n="";var i=this._columns[s];var r;var o;var a;for(var s=0;s<this._columns.length;s++)o=t[(i=this._columns[s]).name]+"",r=this._maskParts[s],s&&(n+=e.options.separator),t[i.name]?(a=r.symbolsLength-o.length,n+=r.mask.replace(k.repeat(r.symbolsLength),"0".repeat(a<0?0:a)+o)):n+=r.mask;e._maskedInput.val(n),e._old=n},_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(y),this._validationIcon.removeClass("k-hidden")},_removeInvalidState:function(){this.wrapper.removeClass(y),this._validationIcon.addClass("k-hidden")},_updateValueFromInput:function(){var e=this._maskedInput.val();var t={};var i=!0;var r;var o;var a;for(var s=0;s<this._columns.length;s++){if(r=this._columns[s],o=this._maskParts[s],a=e.substring(o.numberStart,o.numberEnd).replace(/_/g,""),!((a=n.parseInt(a||0))>=r.min&&a<=r.max)){i=!1;break}t[r.name]=a}i?(this._value=function(e){return 864e5*(e.days||0)+36e5*(e.hours||0)+6e4*(e.minutes||0)+1e3*(e.seconds||0)+(e.milliseconds||0)}(t),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=this;var t=e._old;var i=e.options.separator;var r=e._maskedInput[0].value;var o=x(e._maskedInput)[0];var a=t.length-r.length;var s;var l;var c;var d;var h;var u;var p;var f;var m;var g;var v;if(s=e._isPasted?e._pasted:r.substring(o-1,o),l=/\d/.test(s),e._isPasted&&e._replaceEntire&&l)return e._old=e._fillParts(parseInt(s)),e._maskedInput.val(e._old),e._selectNearestSection(0),void(e._isPasted=e._replaceEntire=!1);if(e._isPasted&&(a=0),e._isPasted=!1,s===i&&!e._backward)return e._maskedInput.val(e._old),void e._switchPart({caret:o,next:!0});if(!r&&e._backward)return e._old=e._emtpyMask,e._maskedInput.val(e._old),void e._selectNearestSection(o);if(!l&&!e._backward)return e._maskedInput.val(e._old),void e._selectNearestSection(o);if(!a||a>0){if(d=r.substring(o,r.length),m=(h=r.substring(0,o))+(u=e._emtpyMask.substring(h.length,t.indexOf(d)))+d,g=e._getPartValue(e._old,o),v=e._old.indexOf(i,e._old.indexOf(g)+1),e._backward){if(u.split(i).length>1)e._old=this._clearParts(m,o,o+u.length);else{if((p=this._getEmptyPart(o))==g)return e._maskedInput.val(e._old),void e._switchPart({caret:o});e._old=e._replacePart(m,p,o)}return e._maskedInput.val(e._old),void e._selectNearestSection(o)}if(v<0&&-1===g.indexOf(k)&&!e._canUpdateLast)return e._maskedInput.val(e._old),void e._selectNearestSection(o);l&&(f="0"===(c=e._updatePart(g,s))[c.search(/[0-9]/)],m=e._replacePart(m,c,o),e._maskedInput.val(m),v>0&&!f?e._selectNearestSection(v+1,!0):e._selectNearestSection(o),e._canUpdateLast=!(v<0&&!f)),e._old=m}else a<0&&(e._maskedInput.val(e._old),e._selectNearestSection(e._old.length-1))}}});n.cssProperties.registerPrefix("TimeDurationPicker","k-input-"),n.cssProperties.registerValues("TimeDurationPicker",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),i.plugin(M)}(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",h="k-pane-pinned",u="k-pane-unpinned",p="k-pane-tabbed",f="k-splitter",m="k-splitbar",g="horizontal",v="vertical",_="k-hidden",b="k-button",w="k-pane",y="k-dock-manager-pane-container",k="k-pane-actions",x="k-dock-indicator",C="k-dock-navigator",S="k-docking-preview",T="k-selected",M="k-active",A="k-tabstrip",D="split",E="tab",I="height",z="width",P="top",L="bottom",B="left",H="right",R="middle",F="click",O="pin",V="unpin",N="unshift",$=`<div class="${w} k-pane-flex ${d}"></div>`,U=e=>`.${w}[${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="${y}" />`).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:D,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:L,top:"100%",left:"50%",transform:"translate(-50%, -100%)",previewTop:(e,t)=>e-t,previewLeft:()=>0,rotate:"180deg"},{name:B,top:"50%",left:0,transform:"translate(0, -50%)",previewTop:()=>0,previewLeft:()=>0,rotate:"270deg"},{name:H,top:"50%",left:"100%",transform:"translate(-100%, -50%)",previewTop:()=>0,previewLeft:(e,t)=>e-t,rotate:"90deg"},{name:R,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;const 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;const i=e.unpinnedContainer.width();e.unpinnedContainer.width(i+n)}})},_bindEvents:function(){const e=this;e.element.on(F+r,`.k-dock-manager-toolbar .${b}`,e._toolbarButtonClick.bind(e)),e.element.on(F+r,`.${y}`,e._hideUnpinnedPanes.bind(e)),e.element.on(F+r,`.${b}[${G}="pin"], .${b}[${G}="unpin"]`,e._pinPaneClick.bind(e)),e.element.on(F+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;const n=t.unpinnedContainer.find(`.${w}`).filter(":visible");const 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;const i=e(t.currentTarget).attr(j);const r=n.unpinnedContainer.find(`.${w}`).filter(":visible");const 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;const n=t._toolbar.outerWidth();const i=t._findPaneByUid(e);const r=i.unpinnable.unpinnedSize;t.unpinnedContainer.removeClass(_).css({left:`${n}px`}),t.unpinnedContainer.find(`.${w}`).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;const r=e(t.currentTarget);const o=r.parent().is("li");const a=r.attr(G);const s=o?r.parent():e(t.currentTarget).closest(`.${w}`);const l=i._findPaneByUid(s.attr(j));const c=l.unpinnable.unpinned;const d=i._findPaneByUid(l.parentUid);i.panesContainer.find(`.${w}[${j}="${d.uid}"], .${f}[${j}="${d.uid}"]`);const p={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(`.${w}`).removeClass(h).addClass(u),"pin"!==a?(i.trigger(V,p),i._showUnpinnedPane(l.uid)):i.trigger(O,p)},_closePane:function(t){const n=this;const i=e(t.currentTarget);const r=i.parent().is("li")?i.parent():e(t.currentTarget).closest(`.${w}`);const o=n._findPaneByUid(r.attr(j));const a=n._findPaneByUid(o.parentUid);n.panesContainer.find(`.${w}[${j}="${a.uid}"], .${f}[${j}="${a.uid}"]`);const s=a.panes.indexOf(o);const 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();const 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!==D||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;const n=t._findPaneByUid(e.parentUid);const i=n.panes.indexOf(e);t.panesContainer.find(`[${j}="${e.uid}"]`).parent();n.panes.splice(i,1),t._refreshRootPane()},_refreshToolbar:function(){const t=this;const i=t._unpinnedPanes();const 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];const 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;const t=e.element.find(`[${j}="${e.options.rootPane.uid}"]`);e._refreshPane(t,e.options.rootPane)},_createSplitPane:function(i,r){const o=this;const a=e("<div ref-dock-splitter/>").attr(j,r.uid);const 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};const 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)),r.splitter.bind("resizing",(({pane:e})=>n.resize(e)))},_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;const o=e("<div />");const a=e("<ul/>");const 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);const 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(M),o.kendoTabStrip({animation:!1}))},_createContentPane:function(t,i){const r=this;const o="function"==typeof i.content?n.template(i.content)({}):i.content;const 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);const p=i.unpinnable&&i.unpinnable.unpinned;!c||c.type!==E||p?(t.addClass(p?u:h).removeClass(d).attr(j,i.uid),r._addActions(s.find(`.${k}`),i),t.append(s)):t.append(o)},_createUnpinnedPane:function(t){const n=this;const 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;const 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);const 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-item",hint:function(e){const t=e.is("li");const n=e.closest(`.${w}`);const r=i._findPaneByUid((t?e:n).attr(j));const 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;const i=e(t.currentTarget);const r=i.closest(`.${w}`);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;const n=t.element.find(`.${x}:hover`);const 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;const i=e(t.elementUnderCursor).closest(`.${w}[${j}]`);const r=n._findPaneByUid(i.attr(j));const o=e(Y);const a=i.attr(j);const s=n.hoveredPane&&n.hoveredPane.attr(j);const l={pane:n.draggedPane.pane,draggableEvent:t};const c=t.currentTarget.closest(`.${w}`).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(`.${w}`);const n=t.prev();const i=t.next();if(t.hide(),n.is(`.${m}`))return n.hide();i.hide()},_hideTab:function(e){const t=e.is(`.${M}`);const n=e.closest(`.${A}`).data("kendoTabStrip");e.hide(),t&&n.activateTab("li:visible:first")},_getActionButtons:function(t){const n=t.find("button");const 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;const r=e(t.currentTarget);const o=!r.parent().is(`.${C}`);const a=r.attr(q);const s=r.attr(j);const l=i.indicators.filter((e=>e.name===a))[0];const c=e(`<div class="${S}"/>`);const d=o?i.panesContainer:i.hoveredPane;const h=i._toolbar?i._toolbar.outerWidth():0;const u=d.outerWidth();const p=d.outerHeight();const f=s&&d.find(`.${S}[${j}="${s}"]`);const m=n.guid();let g=i.draggedPane.width;let v=i.draggedPane.height;if(f&&f.length)return f.show();a===R&&(g=u,v=p),a!==P&&a!==L||(v>p/2&&(v=p/2),g=u),a!==B&&a!==H||(g>u/2&&(g=u/2),v=p);const _={position:"absolute","z-index":1e5,top:l.previewTop(p,v),left:l.previewLeft(u,g)+(o?h: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:u,height:p}},_hideDockPreview:function(){this.element.find(`.${S}`).hide()},_updateLayout:function(e){const t=this;const n=t.draggedPane.target.is("li");const i=!e.parent().is(`.${C}`);const r=n?t.draggedPane.target:t.draggedPane.pane;const o=t._findPaneByUid(t.hoveredPane.attr(j));const a=t._findPaneByUid(r.attr(j));const s=e.attr(q);const l=t._findPaneByUid(a.parentUid);const c=l.panes.indexOf(a);const d=t.element.find(`[${j}="${t.options.rootPane.uid}"]`);l.panes.splice(c,1),s==R?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==R?t.trigger(Z,{pane:a,paneElement:r}):t.trigger(X,{pane:a,paneElement:r})},_splitDock:function(e,t,n,i){const r=this;const o=i?r.options.rootPane:r._findPaneByUid(e.parentUid);const a=o.panes.indexOf(e);const s=n===P||n===B?N:"push";const l=a+(s===N?0:1);const c=n===P||n===L?I:z;const d={type:D,orientation:n===P||n===L?v:g,panes:[]};const h=`${r.draggedPane.preview[c]}px`;return t.size=h,i?(d.panes.push(o),n===P||n===B?d.panes.unshift(t):d.panes.push(t),void(r.options.rootPane=d)):(n===P||n===L)&&o.orientation===v||(n===B||n===H)&&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);const i=n.panes.indexOf(e);const 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;const r=i._getSiblings(e);const o=t===P||t===L?I:z;const a=i.draggedPane.container[o];const s=i.draggedPane[o];const l=a-s;const c=[];let d=l;t!==R&&(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="px";let o;return function(e){return s.test(e)}(n)&&(r="%"),"string"==typeof n&&(o=+n.replace(r,"")),`${o*i}${r}`},_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){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;let o=i.extend({init:function(e){this.options=e,this.propertyGrid=e.propertyGrid}});let 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);let n=[r.field,JSON.stringify(t[r.field]),r.description].filter((e=>undefined!==e)).join("\t");navigator.clipboard.writeText(n)}}});let 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()}});let 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},h=o.table.width();function u(e){let n;let i=t.wrapper.find(".k-form").data("kendoForm").options.formData.columnsize;let r=t.wrapper.find("#columnsize").data("kendoNumericTextBox").value();i!=r?(i>r?(n=i-r,o.table.width(h-n)):(n=r-i,o.table.width(h+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(h),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",u).end().find(".k-dialog-close").on("click",p).end().find(".k-form-field input").on("keydown",(function(e){e.keyCode==r.ENTER?u(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")}});let 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)}});let 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()}});let h=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")}});let u=o.extend({exec:function(){this.propertyGrid.saveAsExcel()}});let 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:h,ExcelExport:u,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,h=n.TreeList,u=Array.isArray,p=e.isPlainObject,f="change",m="expand",g="collapse",v="groupExpand",_="groupCollapse",b="a[class*='-i-caret-alt-down']",w="k-grouping-row",y="tr",k="td";const x=["copy","copyName","copyDeclaration","separator","reset","separator","resize","separator","expandItem","collapseItem","separator"];const 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 M=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;let r=this.sort()||{};let o=e||{filters:[],logic:"or"};let a=this._childrenMap(this.data())[this._defaultParentId()]||[],s=new t.data.Query(a).sort(r).group({field:n}).toArray();let 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()};let 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}});const D=h.extend({init:function(e,n){const i=this;i._processOptions(n),i.options=r(!0,{},i.options,n),i._processedModel=i._processModel(),i._createDataSource(),h.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||" "}</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:p(e.toolbar)&&(e.toolbar.items=e.toolbar.items||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 M({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&&u(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);const 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");let 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"});let 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(y,{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> </span>")]);return a(y,{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;let 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];let 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;let r=this.toolbar;if(i)if(Array.isArray(i)||p(i)){i=p(i)?i:{items:i};let t=e._processToolbarItems(i.items);t=e._verifyItems(t),r.kendoToolBar({size:"medium",resizable:!0,navigateOnTab:!n.navigatable,items:t,overflow:i.overflow}),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();let 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();let 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)&&u(t.contextMenu.body)?{items:t.contextMenu.body}:{items:x};let 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=u(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(y);let 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("."+w)){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;let 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> </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 M({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("."+w)&&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),h.fn.destroy.call(this)}});function E(){let e=this;let t=this._depth();let n=this.data;let i=[];let 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 Ti(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;let 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=this;let r=this._depth();let o=this.hierarchy.itemLevel;let a=this.hierarchy.itemId;let s=this._hasFooterTemplate();let l=0;let c;for(let d=0;d<e.length;d++){let h=e[d];let u=o(h,d);s&&(u>l?n.push({id:c,level:l}):u<l&&t.push(...i._hierarchyFooterRows(n,u,r)),l=u,c=a(h,d)),t.push(...i._dataRow(h,u+1,r))}if(s){t.push(...this._hierarchyFooterRows(n,0,r));let i=e.length?this.aggregates[e[0].parentId]:{};t.push(this._hierarchyFooter(i,0,r))}}});t.getAllMethods(Ti).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||{};let 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(D.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(D)}(window.kendo.jQuery);kendo;!function(e){const t=window.kendo;const n=t.dataviz;const i=t.ui.Widget;const 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({},H3));var i=".kendoChart";var r=n.Class;var o=n._outerWidth;var a=n._outerHeight;var s=n.dataviz;var l=n.ui.Widget;var c=n.data.DataSource;var d=n.deepExtend;var h=Array.isArray;var u=e.extend;var p=n.template;var f=n.htmlEncode;var m="mouseleave"+i;var g=uG;var v=g.LEGEND_ITEM_CLICK;var _=g.LEGEND_ITEM_HOVER;var b=g.LEGEND_ITEM_LEAVE;var w=g.SERIES_CLICK;var y=g.SERIES_HOVER;var k=g.SERIES_OVER;var x=g.SERIES_LEAVE;var C=g.PANE_RENDER;var S=g.PLOT_AREA_CLICK;var T=g.PLOT_AREA_HOVER;var M=g.PLOT_AREA_LEAVE;var A=g.DRAG;var D=g.DRAG_END;var E=g.DRAG_START;var I=g.DRILLDOWN;var z="drilldownLevelChange";var P=g.ZOOM_START;var L=g.ZOOM;var B=g.ZOOM_END;var H=g.SELECT_START;var R=g.SELECT;var F=g.SELECT_END;var O=g.RENDER;var V=e(document.documentElement);var N="change";var $="dataBound";var U="leave";var W=g.PIE;var j=g.DONUT;var q=g.FUNNEL;var G=n.Observable;YU.register({create:function(e,t){return new n.UserEvents(e,d({global:!0,multiTouch:!0,fastTap:!0},t))}});var K=n.ConvertClass(DN).extend({handlerMap:{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown"}});var 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,w,y,k,x,"axisLabelClick",v,_,b,C,S,T,M,E,A,D,P,L,B,H,R,F,"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;var 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._destroyNoData(),t._initNoData(),t._instance.updateMouseMoveHandler(),t._instance._restoreOverlayElement()},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){var t=this._plotArea.panes;for(var 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){var t=this._plotArea;var n=t.srcSeries||t.series;for(var 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;var 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=this._plotArea;var n=t.srcSeries||t.series;var i;if(HN(e.index))i=n[e.index];else if(HN(e.name))for(var r=0;r<n.length;r++)if(n[r].name===e.name){i=n[r];break}return i},_attachEvents:function(){this.element.on(m,this._mouseleave.bind(this))},_mouseleave:function(t){var n=this._instance;var i=this._tooltip;var 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())){this.element.addClass("k-chart");const e=d(w3(),B3(this.element[0]));return this.element.removeClass("k-chart"),e}if(HN(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 jQ(this.element[0],e,t,{observer:new DN(this,{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown"}),sender:this,rtl:this._isRtl(),createSurface:n.drawing.Surface.create})},_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||{};var i=e+t;var 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){var t=this._events;for(var n=0;n<e.length;n++)if(HN(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&&HN(a.visible))a.visible=!a.visible;else{var s=o.pointVisibility=o.pointVisibility||{};var l=s[n];s[n]=!!HN(l)&&!l}}else o.visible=!o.visible,this._seriesVisibility.save(o);i._noTransitionsRedraw()},_createTooltip:function(){return new ne(this.element,u({},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);const 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=[],h=this._seriesVisibility;for(h.read(),t=0;t<s;t++)n=a[t],r._isBindable(n)&&c?(i=J(n,l),d=d.concat(i),h.applyByGroup(i,e)):(n=u({},n),d.push(n),h.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({}))}this._instance&&!this._instance.overlayElement&&(this._instance.overlayElement=t[0])},_destroyNoData:function(){this._noData&&(n.destroy(this._noData),this._noData.remove(),delete this._noData,delete this._noDataContent),this._instance&&delete this._instance.overlayElement},_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=(this._instance?this._instance._originalOptions:{}).series||[],l=a.length;for(e=0;e<l;e++)t=a[e],r._isBindable(t)&&(n=t._groupIx,i=HN(n)?(o[n]||{}).items:o,!1!==t.autoBind&&(t.data=i,s[e]&&(s[e].data=i.slice())))},_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=_j(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=bj.current.valueFields(e),r=!0;for(n=0;n<i.length;n++)if("value"===(t=i[n])?t="field":t+="Field",!HN(e[t])){r=!1;break}return r},_isRtl:function(){return n.support.isRtl(this.element)&&"rtl"===this.element.css("direction")}});var 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(HN(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})=>`${HN(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){var t=e.series;for(var n=0;n<t.length;n++)this.saveState(t[n])}},saveState:function(e){HN(e._groupValue)?this.groups[e._groupValue]=e.visible:this.index[e.index]=e.visible}});var 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){var o="";for(var 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+":":" "}</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;var n=t.point;var i=t.align;var r=n.left;var 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),h=window.pageYOffset||document.documentElement.scrollTop||0,u=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]);var m=new te.Point(l,s).transform(f);l=m.x,s=m.y}else s+=t._fit(s-h,i.height,a(d)/c),l+=t._fit(l-u,i.width,o(d)/c);return{top:s,left:l}},show:function(r){var o=this;var 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;var i=xN(t,(function(e){return HN(e.series.name)})).length;var r=e.series.length>1;var 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;var i=this.chartElement[0];n&&n!==i&&!e.contains(i,n)&&this.trigger(U)},_hideElement:function(){var e=this;var 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 HN(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}});var 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()}});var 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;var t=e._plotArea.groupSeriesByPane()[this.name||"default"];var n=[];if(t)for(var i=0;i<t.length;i++)n.push(new oe(e,t[i]));return n}});var 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();var 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;var i=n._plotArea;if(t.data=e,t.categoryField){var r=i.seriesCategoryAxis(t);var o=[].concat(n.options.categoryAxis);n._instance.bindCategoryAxisFromSeries(o[r.axisIndex],r.axisIndex)}n._noTransitionsRedraw(),this._clearFields()}return t.data},findPoint:function(e){var t=this.points();for(var 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):h(t)?t:[t]:this.points(),this._chart._instance.togglePointsHighlight(e,t)},toggleVisibility:function(e,t){var i=this._chart;var r=this._seriesOptions();if(n.isFunction(t))if(TN(r.type,[W,j,q])){var o=this._filterData(t);for(var 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){var t=this._seriesOptions().data;var n=t.length;var i=[];for(var r=0;r<n;r++)e(t[r])&&i.push(t[r]);return i},_filterPoints:function(e,t){var n=[];var i=e.length;for(var 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(e){const t=window.kendo,n=t.ui.Widget,i=t.data.DataSource,r=t.keys,o=K2.fontSizes,a=K2.fontNames,s=K2.isCategorical,l=K2.updateState,c=K2.mergeStates,d=K2.ActionTypes,h=K2.getWizardDataFromDataRows,u=".kendoChartWizard",p=t.ui,f=e.extend,m=t.deepExtend,g="resizing",v="resize",_="maximize",b="restore",w="click",y="keydown",k="open",x="close",C="activate",S="change",T="dataBinding",M="dataBound",A="exportPDF",D="exportSVG",E="exportImage",I=".",z="ref",P="ref*=",L="data-action",B="[data-action]",H="data-role",R="data-role=",F="data-chart-type",O="k-selected",V="outline",N="flat",$=/(?=[A-Z])/;const U="k-chart-wizard",W="k-chart-wizard-preview-pane",j="k-preview-pane-header",q="k-preview-pane-content",G="k-chart-wizard-property-pane",K="k-chart-wizard-splitter",Y="k-expander",Q="k-grid-cols-2 k-gap-x-4",X="k-col-span-2";const Z="numerictextbox",J="colorpicker",ee="textbox",te="combobox",ne="checkbox",ie="dropdownlist",re="switch";const oe={icon:"export",fillMode:N,items:[{id:"export-pdf",icon:"file-pdf"},{id:"export-svg",icon:"file"},{id:"export-png",icon:"file-image"}]};const ae={bar:{content:{bar:"chart-bar-clustered",stackedBar:"chart-bar-stacked",hundredStackedBar:"chart-bar-stacked100"}},pie:{content:{pie:"chart-pie"}},column:{content:{column:"chart-column-clustered",stackedColumn:"chart-column-stacked",hundredStackedColumn:"chart-column-stacked100"}},line:{content:{line:"chart-line",stackedLine:"chart-line-stacked",hundredStackedLine:"chart-line-stacked100"}},scatter:{content:{scatter:"chart-scatter"}}};const se=e=>[{legend:e.chartArea.margins.default,layoutClass:Q,editors:[{label:{text:e.chartArea.margins.left,for:"left"},field:{id:"left",role:Z,placeholder:e.chartArea.margins.auto,action:"areaMarginLeft"}},{label:{text:e.chartArea.margins.right,for:"right"},field:{id:"right",role:Z,placeholder:e.chartArea.margins.auto,action:"areaMarginRight"}},{label:{text:e.chartArea.margins.top,for:"top"},field:{id:"top",role:Z,placeholder:e.chartArea.margins.auto,action:"areaMarginTop"}},{label:{text:e.chartArea.margins.bottom,for:"bottom"},field:{id:"bottom",role:Z,placeholder:e.chartArea.margins.auto,action:"areaMarginBottom"}}]},{legend:e.chartArea.background.default,editors:[{label:{text:e.chartArea.background.color,for:"background"},field:{id:"background",role:J,action:"areaBackground"}}]}];const le=e=>[{layoutClass:Q,editors:[{label:{text:e.title.applyTo,for:"apply-to-title"},field:{id:"apply-to-title",role:ie,action:"activateTitle"},className:X},{label:{text:e.title.label,for:"title-text"},field:{id:"title-text",role:ee,action:"titleText"},className:X},{label:{text:e.title.font,for:"title-font"},field:{id:"title-font",role:te,placeholder:e.title.fontPlaceholder,action:"titleFontName"},className:X},{label:{text:e.title.size,for:"title-size"},field:{id:"title-size",role:te,placeholder:e.title.sizePlaceholder,action:"titleFontSize"}},{label:{text:e.title.color,for:"title-color"},field:{id:"title-color",role:J,action:"titleColor"}}]}];const ce=e=>[{editors:[{label:{text:e.series.applyTo,for:"apply-to-series"},field:{id:"apply-to-series",role:ie,action:"activateSeries"}},{label:{text:e.series.color,for:"series-color"},field:{id:"series-color",role:J,action:"seriesColor"}},{field:{id:"show-labels",type:"checkbox",role:ne,action:"seriesLabel"}}]}];const de=e=>[{layoutClass:Q,editors:[{nowrap:!0,label:{text:e.legend.showLegend,for:"show-legend"}},{nowrap:!0,field:{id:"show-legend",role:re,action:"legendVisible"}},{label:{text:e.legend.font,for:"legend-font"},field:{id:"legend-font",placeholder:e.legend.fontPlaceholder,role:te,action:"legendFontName"},className:X},{label:{text:e.legend.size,for:"legend-size"},field:{id:"legend-size",role:te,placeholder:e.legend.sizePlaceholder,action:"legendFontSize"}},{label:{text:e.title.color,for:"legend-color"},field:{id:"legend-color",role:J,action:"legendColor"}},{label:{text:e.legend.position.default,for:"legend-position"},field:{id:"legend-position",role:ie,action:"legendPosition"},className:X}]}];const he=e=>[{legend:e.categoryAxis.title.text,layoutClass:Q,editors:[{field:{id:"category-axis-title",role:ee,placeholder:e.categoryAxis.title.placeholder,action:"categoryAxisTitleText"},className:X},{label:{text:e.categoryAxis.title.font,for:"category-axis-title-font"},field:{id:"category-axis-title-font",role:te,placeholder:e.categoryAxis.title.fontPlaceholder,action:"categoryAxisTitleFontName"},className:X},{label:{text:e.categoryAxis.title.size,for:"category-axis-title-size"},field:{id:"category-axis-title-size",role:te,placeholder:e.categoryAxis.title.sizePlaceholder,action:"categoryAxisTitleFontSize"}},{label:{text:e.categoryAxis.title.color,for:"category-axis-title-color"},field:{id:"category-axis-title-color",role:J,action:"categoryAxisTitleColor"}}]},{layoutClass:Q,legend:e.categoryAxis.labels.text,editors:[{label:{text:e.categoryAxis.labels.font,for:"category-axis-labels-font"},field:{id:"category-axis-labels-font",role:te,placeholder:e.categoryAxis.labels.fontPlaceholder,action:"categoryAxisLabelsFontName"},className:X},{label:{text:e.categoryAxis.labels.size,for:"category-axis-labels-size"},field:{id:"category-axis-labels-size",role:te,placeholder:e.categoryAxis.labels.sizePlaceholder,action:"categoryAxisLabelsFontSize"}},{label:{text:e.categoryAxis.labels.color,for:"category-axis-labels-color"},field:{id:"category-axis-labels-color",role:J,action:"categoryAxisLabelsColor"}},{label:{text:e.categoryAxis.labels.rotation.text,for:"category-axis-labels-rotation"},field:{id:"category-axis-labels-rotation",role:Z,placeholder:e.categoryAxis.labels.rotation.auto,action:"categoryAxisLabelsRotation"}},{field:{id:"category-axis-labels-reverse-order",role:ne,action:"categoryAxisReverseOrder"},className:X}]}];const ue=e=>[{legend:e.valueAxis.title.text,layoutClass:Q,editors:[{field:{id:"value-axis-title",role:ee,placeholder:e.valueAxis.title.placeholder,action:"valueAxisTitleText"},className:X},{label:{text:e.categoryAxis.title.font,for:"value-axis-title-font"},field:{id:"value-axis-title-font",role:te,placeholder:e.valueAxis.title.fontPlaceholder,action:"valueAxisTitleFontName"},className:X},{label:{text:e.valueAxis.title.size,for:"value-axis-title-size"},field:{id:"value-axis-title-size",role:te,placeholder:e.valueAxis.title.sizePlaceholder,action:"valueAxisTitleFontSize"}},{label:{text:e.valueAxis.title.color,for:"value-axis-title-color"},field:{id:"value-axis-title-color",role:J,action:"valueAxisTitleColor"}}]},{layoutClass:Q,legend:e.valueAxis.labels.text,editors:[{label:{text:e.valueAxis.labels.labelFormat.default,for:"value-axis-label-format"},field:{id:"value-axis-label-format",role:ie,action:"valueAxisLabelsFormat"},className:X},{label:{text:e.valueAxis.labels.font,for:"value-axis-label-font"},field:{id:"value-axis-label-font",role:te,placeholder:e.valueAxis.labels.fontPlaceholder,action:"valueAxisLabelsFontName"},className:X},{label:{text:e.valueAxis.labels.size,for:"value-axis-label-size"},field:{id:"value-axis-label-size",role:te,placeholder:e.valueAxis.labels.sizePlaceholder,action:"valueAxisLabelsFontSize"}},{label:{text:e.valueAxis.labels.color,for:"value-axis-labels-color"},field:{id:"value-axis-labels-color",role:J,action:"valueAxisLabelsColor"}},{label:{text:e.valueAxis.labels.rotation.text,for:"value-axis-labels-rotation"},field:{id:"value-axis-labels-rotation",role:Z,placeholder:e.valueAxis.labels.rotation.auto,action:"valueAxisLabelsRotation"}}]}];function pe(e,t){return K2.createState(e,t)}const fe=()=>'<div class="k-chart-types-wrapper"></div>',me=(e,n,i)=>`<div class="k-icon-text-wrapper" ${i??""}>${e}${t.htmlEncode(n)}</div>`,ge=(e,n)=>`<div class="k-icon-background-area" tabindex="0">${t.ui.icon({icon:e,size:n})}</div>`,ve=()=>'<form class="k-form k-form-md"></form>',_e=(e,t)=>`<fieldset class="k-form-fieldset">\n ${e?`<legend class="k-form-legend">${e}</legend>`:""}\n ${t}\n </fieldset>`,be=e=>`<div ref=${e}></div>`,we=e=>`<div class="k-form-field-wrap">${e}</div>`,ye=(e,t)=>`<div class="k-form-field${t?" "+t:""}">\n ${e}\n </div>`,ke=(e,t)=>`\n ${e}\n ${t}`,xe=(e,t,n)=>`<label for="${t}" class="k-label${n?" "+n:""}">${e}</label>`,Ce=e=>`<div class="k-form-layout k-d-grid${" "+e}"></div>`,Se=e=>`<input ${e.id?`id="${e.id}"`:""} ${H}=${e.role} ${L}=${e.action} ${e.type?`type="${e.type}"`:""} ${e.placeholder?`placeholder="${t.htmlEncode(e.placeholder)}"`:""}/>`;const Te={fillMode:V,view:"gradient",buttons:!1,format:"rgb",opacity:!0},Me={filter:"contains",suggest:!0,dataTextField:"text",dataValueField:"value"},Ae={step:1,fillMode:V},De={fillMode:V,animation:!1,dataTextField:"text",dataValueField:"value",index:0},Ee={dataTextField:"name",dataContentField:"content"},Ie={columns:[{id:1,field:"reoreder",draggable:!0,editable:()=>!1,width:"40px"},{id:2,field:"name"},{id:3,field:"remove",editable:()=>!1,width:"40px",template:()=>`<button ${L}="remove" tabindex="0"></button>`}],pageable:!1,scrollable:!1,navigatable:!1,editable:{confirmation:!1,mode:"incell"},reorderable:{rows:!0}};const ze=(e,t)=>{let n=[];e.forEach((e=>{const t=n.find((t=>t.uid===e.uid));t?f(t,e):n.push(e)}));const i=n.map((e=>({dataItem:e,dataColumns:t})));return h(i)};const Pe=n.extend({init:function(e,i){let r=this;i=i||{},r.options=m({},r.options,i),n.fn.init.call(r,e,i),r._initial=!0,r._dataSource(),t.notify(r)},options:{name:"ChartWizard",dataSource:[],dataColumns:[],defaultState:{},state:{},window:{actions:["Maximize","Close"],resizable:!0,visible:!0,modal:!0,scrollable:!1,animation:!1,width:700,height:550},exportOptions:{fileName:"chart",pdf:{margin:"1cm"},image:{width:800,height:600}},messages:{window:{title:"Chart Preview"},export:"Export",exportPDF:"PDF File",exportSVG:"SVG File",exportPNG:"PNG File",tab:{chart:"Chart",data:"Data",format:"Format"},chart:{bar:{expandText:"Bar Chart",bar:"Bar",stackedBar:"Stacked Bar",hundredStackedBar:"100% Stacked Bar"},pie:{expandText:"Pie Chart",pie:"Pie"},column:{expandText:"Column Chart",column:"Column",stackedColumn:"Stacked Column",hundredStackedColumn:"100% Stacked Column"},line:{expandText:"Line Chart",line:"Line",stackedLine:"Stacked Line",hundredStackedLine:"100% Stacked Line"},scatter:{expandText:"Scatter Chart",scatter:"Scatter"}},data:{configuration:{expandText:"Configuration",series:{title:"Series",add:"Add"},valueAxis:"Value Axis",categoryAxis:"Category Axis",xAxis:"X Axis"}},format:{chartArea:{expandText:"Chart Area",margins:{default:"Margins",auto:"Auto",left:"Left",right:"Right",top:"Top",bottom:"Bottom"},background:{default:"Background",color:"Color"}},title:{expandText:"Title",applyTo:"Apply to",chartTitle:"Chart Title",chartSubtitle:"Chart Subtitle",label:"Title",font:"Font",fontPlaceholder:"(inherited font)",size:"Size",sizePlaceholder:"px",color:"Color"},series:{expandText:"Series",applyTo:"Apply to",allSeries:"All Series",color:"Color",showLabels:"Show Labels"},legend:{expandText:"Legend",showLegend:"Show Legend",font:"Font",fontPlaceholder:"(inherited font)",size:"Size",sizePlaceholder:"px",color:"Color",position:{default:"Position",top:"Top",bottom:"Bottom",left:"Left",right:"Right"}},categoryAxis:{expandText:"Category Axis",title:{text:"Title",placeholder:"Axis Title",font:"Font",fontPlaceholder:"(inherited font)",size:"Size",sizePlaceholder:"px",color:"Color"},labels:{text:"Labels",font:"Font",fontPlaceholder:"(inherited font)",size:"Size",sizePlaceholder:"px",color:"Color",rotation:{text:"Rotation",auto:"Auto"},reverseOrder:"Reverse Order"}},valueAxis:{expandText:"Value Axis",title:{text:"Title",placeholder:"Axis Title",font:"Font",fontPlaceholder:"(inherited font)",size:"Size",sizePlaceholder:"px",color:"Color"},labels:{text:"Labels",labelFormat:{default:"Label Format",text:"Text",number:"Number",currency:"Currency",percent:"Percent"},font:"Font",fontPlaceholder:"(inherited font)",size:"Size",sizePlaceholder:"px",color:"Color",rotation:{text:"Rotation",auto:"Auto"}}},xAxis:{expandText:"X Axis"},yAxis:{expandText:"Y Axis"}}}},events:[g,T,M,v,w,y,k,x,S,A,D,E],open:function(){this.window.open()},close:function(){this.window.close()},_attachEvents:function(){const e=this;e.splitter.bind(g,(({pane:e})=>{t.resize(e)})),e.splitter.bind(v,(e=>{e.sender.element.find(".k-pane").each(((e,n)=>{t.resize(n)}))})),e.window.bind(C,e._windowActivateHandler.bind(e)),e.window.bind(v,e._windowResizeHandler.bind(e)),e.window.bind(_,e._windowActivateHandler.bind(e)),e.window.bind(b,e._windowActivateHandler.bind(e)),e.window.bind(x,(function(){e.trigger(x)})),e.window.bind(k,(function(){e.trigger(k)})),e.tabStrip.contentElements.on(w+u,".k-icon-text-wrapper",e._handleChartTypeClick.bind(e)),e.tabStrip.contentElements.on(y+u,".k-icon-text-wrapper",e._handleChartTypeKeydown.bind(e))},_dataSource:function(){const e=this;let t=e.options.dataSource;e.dataSource&&e._refreshHandler?e.dataSource.unbind(S,e._refreshHandler):e._refreshHandler=e._refresh.bind(e),t&&t instanceof i?e.dataSource=t.bind(S,e._refreshHandler):(t=Array.isArray(t)?{data:t}:t,e.dataSource=i.create(t).bind(S,e._refreshHandler)),e.dataSource.data().length?e._refresh():e.dataSource._requestInProgress||e.dataSource.fetch()},_refreshContent:function(){const e=this;const n=e.options;const i=e._getChartStateInstance(n);const r=e.previewPane.find(I+j);e.window.setOptions({title:t.htmlEncode(n.messages.window.title),...n.window}),e._oldType=null,e._setChartContainerHeight(),e.chartState=f(e.chartState,i),e.chart.setOptions(e.chartState),e._detachEvents(),t.destroy(r),r.empty(),e._createExportButton(r),t.destroy(e.propertyPane),e.propertyPane.empty(),e._seriesGrid=null,e._seriesValueAxisDDL=null,e._initPropertyPane(),e._attachEvents(),!e.window.wrapper.is(":visible")&&n.window.visible&&e.window.open(),n.position||e.window.center()},_refresh:function(e){const t=this;let n=Array.from(t.dataSource.data());t.trigger(T,{data:n}),n=t._data=t._getWizardData(n),t._initial?(t._initWindow(),t._initSplitter(),t._initPreviewPane(),t._initPropertyPane(),t._attachEvents(),t._initial=!1):t._refreshContent(),t.trigger(M,{data:n})},_getWizardData:function(e){let t=e;const n=this.options.dataColumns?this.options.dataColumns.map((e=>"string"==typeof e?{field:e}:e)):[];return e.length&&e[0].dataItem&&e[0].dataColumns?t=h(e):e.length&&!Array.isArray(e[0])&&n.length&&(t=ze(e,n)),t},setDataSource:function(e){const t=this;const n=t.options;e&&(n.dataSource=e,t._dataSource())},setDataColumns:function(e){const t=this.options;e.length&&(t.dataColumns=e)},_detachEvents:function(){const e=this;e.splitter.unbind(g),e.splitter.unbind(v),e.window.unbind(C),e.window.unbind(v),e.window.unbind(x),e.window.unbind(k),e.window.unbind(_),e.window.unbind(b),e.tabStrip.contentElements.off(w+u),e.tabStrip.contentElements.off(y+u)},_setChartContainerHeight:function(){this.previewPane.find(I+q).css({height:this.previewPane.height()-50})},_windowActivateHandler:function(){this._setChartContainerHeight(),this.chart.resize()},_windowResizeHandler:function(){this._setChartContainerHeight()},_handleChartTypeKeydown:function(e){e.keyCode===r.ENTER&&this._handleChartTypeClick(e)},_handleChartTypeClick:function(t){const n=this;const i=e(t.currentTarget);const r=n._getRefAttributeValue(i.closest(".k-expander-content")[0])[0];const o=i.attr(F);const a=n.chartState;let s=null;let l=null;o.includes("hundredstacked")?(l=d.stacked,s={type:"100%"}):o.includes("stacked")&&(l=d.stacked,s={type:"normal"}),n._executeAction(s,{element:i},a.data,r,l),i.closest(".k-tabstrip-content").find(I+O).removeClass(O),i.addClass(O),n._toggleFieldsForSeriesPanel(r),n._toggleFormatPanels(),n._refreshEditors()},_refreshEditors:function(){const t=this;t.propertyPane.find(B+":not('.k-button')").each(((n,i)=>{const r=e(i);const o=r.data("handler");const a=r.attr("id");const s=e(i).closest(`[${z}]`);const l=r.attr(H);const c=t._getRefAttributeValue(s[0])[0];if(o&&o.setOptions){const e=t._getOptionsForPanel(a)[c][l];if(e&&e.options)if(l===ne)o.check(e.options.checked);else if("series"===c)o.setOptions(e.options),e.options&&e.options.enable&&o.enable(e.options.enable);else{let t=e.options.value;t&&"string"!=typeof t&&t.value&&(t=t.value),o.value(t)}if(l===te){const e=t._getFontState(r);e&&e.value&&o.value(e.value)}}})),t._seriesGrid&&t._seriesGrid.setDataSource(t.chartState.series)},_initWindow:function(){const e=this;const n=e.options.messages;const i=e.options.window;const r=!i.position;e.window=e.element.kendoWindow({title:t.htmlEncode(n.window.title),...i}).data("kendoWindow"),r&&e.window.center(),e.window.element.attr("tabindex","-1"),e.wrapper=e.window.wrapper.addClass(U)},_initSplitter:function(){const t=this;t.splitter=e("<div>").kendoSplitter({orientation:"horizontal"}).data("kendoSplitter"),t.previewPane=t.splitter.append({scrollable:!1}),t.propertyPane=t.splitter.append({size:"300px",collapsible:!0}),t.splitter.wrapper.addClass(K),t.window.content(t.splitter.wrapper)},_initPreviewPane:function(){const t=this;const n=t.options;t.previewPane.addClass(W);const i=e("<div></div>").addClass(j);const r=e("<div></div>").addClass(q);t.options.window.visible&&r.css({height:t.previewPane.height()-50});const o=e("<div id='chart'>");t._createExportButton(i),r.append(o),t.previewPane.append(i.add(r)),t._initChart(o,n)},_getChartStateInstance:function(e,t){const n=t?{}:e.defaultState;const i=Object.keys(e.state).length;return function(e,t,n,i){var r=pe(e,n&&n.seriesType||t);return i&&(r=m({},r,i)),void 0!==(n&&n.stack)?l(r,d.stacked,n.stack):r}((i?e.state.data:this._data)||[],i&&!t&&e.state.seriesType||"bar",n,e.state)},_initChart:function(e,t){const n=this;const i=t.defaultState&&"pie"===t.defaultState.seriesType||t.state&&"pie"===t.state.seriesType;let r=n._getChartStateInstance(t,i);const o=r.area;if(r.chartArea=o,r.transitions=!1,n.chartState=r,n.chart=e.kendoChart(r).data("kendoChart"),n.chart.wrapper.css({width:"100%",height:"100%"}),i){const e=n._getChartStateInstance(t);n.chartState=f(n.chartState,e),n.chart.setOptions(n.chartState)}n._initialState||(n._initialState=n.chart.options)},_createExportButton:function(n){this._configureExportButton(oe);const i=e(`<button>${t.htmlEncode(this.options.messages.export)}</button>`).kendoDropDownButton(oe);n.append(i)},_configureExportButton:function(e){const n=this;const i=n.options.messages;const r={"export-pdf":function(){n.trigger(A,{chart:n.chart,exportOptions:n.options.exportOptions})||n.chart.exportPDF(n.options.exportOptions.pdf).done((function(e){t.saveAs({dataURI:e,fileName:n.options.exportOptions.fileName})}))},"export-svg":function(){n.trigger(D,{chart:n.chart,exportOptions:n.options.exportOptions})||n.chart.exportSVG(n.options.exportOptions.fileName).done((function(e){t.saveAs({dataURI:e,fileName:n.options.exportOptions.fileName})}))},"export-png":function(){n.trigger(E,{chart:n.chart,exportOptions:n.options.exportOptions})||n.chart.exportImage(n.options.exportOptions.image).done((function(e){t.saveAs({dataURI:e,fileName:n.options.exportOptions.fileName})}))}};e.items.forEach((e=>{const n=e.id.split("-");const o=n[0]+n[1].toUpperCase();e.text=t.htmlEncode(i[o]),e.click=r[e.id]}))},_preventLabelPointerEvents:function(){this.propertyPane.find(".k-label").addClass("k-pointer-events-none")},_initPropertyPane:function(){const n=this;const i=Ee;i.dataSource=Object.values(n.options.messages.tab).map((e=>({name:t.htmlEncode(e)}))),n._createTabsContent(i.dataSource),n.tabStrip=e("<div>").kendoTabStrip({...i,activate:function(i){if(e(i.contentElement).find(`[${P}'data']`).length){const r=e(i.contentElement).find("#category-axis").parent().siblings(".k-form-legend");r.length&&"scatter"===n.chart.options.seriesType?r.text(t.htmlEncode(n.options.messages.data.configuration.xAxis)):r.length&&r.text(t.htmlEncode(n.options.messages.data.configuration.categoryAxis))}n._seriesGrid&&n._seriesGrid.wrapper.is(":visible")&&(n._seriesGrid._draggableRows(),n._seriesGrid._reorderableRows())}}).data("kendoTabStrip"),n.propertyPane.addClass(G),n.propertyPane.append(n.tabStrip.wrapper),n._expansionPanels(),n._prepareDataTab(),n._prepareFormatTab(),n._initStaticEditors(),n.tabStrip.activateTab(n.tabStrip.tabGroup.children().first()),n.options.window.visible&&n.chart.resize()},_createTabsContent:function(e){const t=this;e.forEach((e=>{e.content=t._createExpansionPanelContent(e.name)??""}))},_createExpansionPanelContent:function(e){const t=this;let n="";const i=t.options.messages.tab;if(e===i.chart){Object.keys(ae).forEach((e=>{n+=t._createChartTypesPanel(ae[e].content,`${e}-chart-panel`,e)}))}else if(e===i.data){const e=(e=>[{legend:e.configuration.categoryAxis,editors:{id:"category-axis",role:ie,action:"categoryAxisX"}},{legend:e.configuration.valueAxis,editors:{id:"value-axis",role:ie,action:"valueAxisY"}},{legend:e.configuration.series.title,editors:{custom:`<div class="k-grid" ${L}="seriesChange"></div>`}}])(t.options.messages.data);n+=t._createFormPanel(e,"configuration-data-panel")}else if(e===i.format){[{ref:"chartarea",getData:se},{ref:"title",getData:le},{ref:"series",getData:ce},{ref:"legend",getData:de},{ref:"categoryaxis",getData:he},{ref:"valueaxis",getData:ue}].forEach((e=>{const i=e.getData(t.options.messages.format);n+=t._createFormPanel(i,`${e.ref}-format-panel`)}))}return n},_createChartTypesPanel:function(n,i,r){const o=this.options.messages.chart;const a=e(be(i));const s=e(fe());return Object.keys(n).forEach((e=>{const i=t.htmlEncode(o[r][e]);const a=`${F}=${e.toLowerCase()}`;s.append(me(ge(n[e],"xlarge"),i,a))})),a.append(s),a[0].outerHTML},_createFormPanel:function(n,i){const r=e(be(i));const o=e(ve());return n.forEach((n=>{const i=n.legend;const r=n.layoutClass;const a=n.editors;let s="";if(a instanceof Array){let n="";if(a.forEach((e=>{const i=e.nowrap;const r=e.label?xe(t.htmlEncode(e.label.text),e.label.for,!i&&"k-form-label"):"";const o=e.className;let a;a=e.field&&e.field.custom?e.field.custom:e.field?Se(e.field):"",n+=i?ke(r,a):ye(ke(r,we(a)),o)})),r){const t=e(Ce(r));t.append(n),s=t[0].outerHTML}else s=n}else s=a&&a.custom?a.custom:Se(a);i?o.append(_e(t.htmlEncode(i),s)):o.append(s)})),r.append(o),r[0].outerHTML},_ensureSizeValue:function(e,t){const n=/^\d+$/;const i=e.toString();let r=o.find((e=>e.text===i));if(!r){if(!n.test(i)||isNaN(parseInt(i,10)))return!1;r={text:i,value:i+"px"},o.push(r),o.sort(((e,t)=>parseInt(e.text,10)-parseInt(t.text,10))),t(o)}return!0},_executeAction:function(e,t,n,i,r){const o=this;const a=t.element.data("action");const s={state:o.chartState,action:r??d[a],change:e};n&&(s.data=n,s.type=i??o.chartState.seriesType);const h=function({state:e,data:t,type:n,action:i,change:r}){let o=e;return t&&n&&(o=c(e,pe(t,n))),i&&null!=r&&(o=l(o,i,r)),o.transitions=!1,o}(s);return h.chartArea=h.area,o.chart.setOptions(h),o.chartState=h,h},_seriesDropDownChange:function(e){const t=this;t._seriesChange=!0,e.preventChange=!0;const n=t._handlePropertyChange(e);delete t._seriesChange,t._seriesGrid&&t._seriesGrid.setDataSource(n.series)},_prepareDataTab:function(){const e=this.element.find(`[${P}'data'] > form`);const t=e.find(".k-grid").closest(".k-form-fieldset");const n=e.find("#value-axis").closest(".k-form-fieldset");this._dynamicConfigurationFields={grid:t.clone(),valueAxis:n.clone(),container:e},t.remove(),n.remove()},_resetFontValue:function(e,t){return!(!e||!t)&&(t.font="",!0)},_getFontField:function(e,t,n){let i;return i=n?t&&t.font:e&&e.font,this._valueReset=this._resetFontValue(n,e),i},_getFontValue:function(e,t,n,i){const r=this;let o;const a="initial"===n;const s=r._initialState[e.active];const l=r.chartState[e.active];if(o=Array.isArray(l)?r._getFontField(l[0],s,a,i):r._getFontField(l,s,a,i),!o&&e.subfield){const t=e.subfield.toLowerCase();o=Array.isArray(l)?r._getFontField(l[0][t],s[t],a,i):r._getFontField(l[t],s[t],a,i)}return o&&(o=r._parseFont(o)[t]),o},_createFontCombobox:function(e){const t=this;const n=t._getFontState(e);const i=e.kendoComboBox({dataSource:n.dataSource,value:n.value,change:function(e){const i=e.sender._fontState;const r="name"===i.type;const s=i.subfield&&"legend"!==n.active;const l=`${i.active}${i.subfield&&s?`${i.subfield}`:""}Font`;let c=r?"Size":"Name";let d=e.sender.value();const h=e.sender.wrapper.closest(".k-form").find(`[${L}*=${l+c}]`).data("kendoComboBox");c=c.toLowerCase();const u=!d;if(u){if(t._getFontValue(i,i.type,"initial"),t._valueReset)return e.sender.value(""),h.value(""),t.chart.setOptions(t.chartState)}else{if(r||(d=d.replace("px","")),""!==d&&!r&&!t._ensureSizeValue(d,e.sender.setDataSource.bind(e.sender)))return;t._handlePropertyChange(e)}if(!u&&!h.value()){let e=t._getFontValue(i,c);let n;r?t._ensureSizeValue(e,h.setDataSource.bind(h))&&(n=o.find((t=>t.text===e.toString()))):(e=e.replace(/^['"]*([a-zA-Z0-9\s]+)['"]*$/g,"$1"),n=a.find((t=>t.value.includes(e)))),n&&n.value&&(h.value(n.text),t._handlePropertyChange({sender:h,preventChange:!0},n.value))}},...Me}).data("kendoComboBox");return i._fontState=n,i},_createDropDownList:function(t,n,i){const r=this;return e(t).kendoDropDownList({...De,...n,change:i||function(e){r._handlePropertyChange(e)}}).data("kendoDropDownList")},_createSwitch:function(e,t,n){const i=this;return e.kendoSwitch({...t,change:n||function(e){i._handlePropertyChange(e)}}).data("kendoSwitch")},_createCheckBox:function(e,t,n){const i=this;return e.kendoCheckBox({...t,change:n||function(e){i._handlePropertyChange(e)}}).data("kendoCheckBox")},_createColorPicker:function(e,t,n){const i=this;const r=t??{};const o=void 0===r.enable||r.enable;delete r.enabled;const a=e.kendoColorPicker({...Te,...r,change:n||function(e){i._handlePropertyChange(e)},select:n||function(e){i._handlePropertyChange(e,e.value)}}).data("kendoColorPicker");return a.enable(o),a},_createNumericTextBox:function(e,t,n){const i=this;return e.kendoNumericTextBox({...Ae,...t,change:n||function(e){i._handlePropertyChange(e)},spin:n||function(e){i._handlePropertyChange(e)}}).data("kendoNumericTextBox")},_createTextBox:function(t,n){const i=this;const r=t.kendoTextBox({...n});return r.on("input"+u,(function(t){const n={element:e(t.target)};i._handlePropertyChange({sender:n},e(t.target).val())})),r.data("kendoTextBox")},_getFieldValue:function(e){const t=e.split($);const n=t.indexOf("Font");const i=t.slice(0,n);const r=t[n+1].toLowerCase();let o;let a;return 1===i.length?o=i[0]:i.length>1&&(a=i.pop(),o=i.join("")),{type:r,field:o,subfield:"legend"===o?"Labels":a}},_getFontState:function(e){const t=this;const n=t.chartState;const i=e.data("action");const r=t._getFieldValue(i);const s=r.field;const l=r.subfield&&r.subfield.toLowerCase();let c=n[s]&&n[s].font;!c&&l&&(c=n[s]&&n[s][l]&&n[s][l].font);let d=null;let h=[];return"name"===r.type?(h=a,d=c&&h.find((e=>e.value===t._parseFont(c).name))||null):(h=o,d=c&&h.find((e=>e.value===t._parseFont(c).size))||null),{dataSource:h,value:d,type:r.type,active:s,subfield:r.subfield}},_parseFont:function(t){const n=e("<span></span>");return n.css("font",t),{fontWeight:n.css("fontWeight"),size:parseInt(parseFloat(n.css("fontSize"))),name:n.css("fontFamily")}},_addSeries:function(e){const t=this._seriesGrid;const n=this._removedSeries.pop();const i=t.options.dataSource;i.push(n),t.setDataSource(i)},_removeSeries:function(e){const t=e.target.closest("tr");this._seriesGrid.removeRow(t)},_gridDataBoundHandler:function(t){const n=this;const i={add:this._addSeries.bind(n),remove:this._removeSeries.bind(n)};t.wrapper.find(".k-grid-header").remove(),t.wrapper.find(B).each(((r,o)=>{const a=e(o);a.data("kendoButton")&&(a.data("kendoButton").destroy(),a.removeAttr("disabled"));const s=a.data("action");const l=!!("remove"===s&&t._data.length>1);const c=!!("add"===s&&n._removedSeries&&n._removedSeries.length>0);const d=l||c;a.kendoButton({icon:"add"===s?"plus":"trash",enabled:d,fillMode:N,click:i[s]})}))},_initGrid:function(e){const n=this;const i=n.options.messages.data.configuration.series;const r=e.kendoGrid({...Ie,toolbar:[{template:()=>`<button ${L}='add' tabindex="0">${t.htmlEncode(i.add)}</button>`}],dataBound:function(e){const t=e.sender;n._preventChange=!0,n._seriesReordering?t._data.length===n._reorderedData.length&&(n._seriesReordering=!1,n._executeAction(n._reorderedData,t),delete n._reorderedData,n.trigger(S,{state:n.chartState})):(n._executeAction(t.options.dataSource,t),n.trigger(S,{state:n.chartState})),n._preventChange=!1,n._gridDataBoundHandler(t)},cellClose:function(e){"save"===e.type&&n._handleSeriesEdit(e)},remove:function(e){n._handleSeriesRemove(e)},rowReorder:function(e){n._seriesReordering=!0,n._reorderedData=function(e,t,n){const i=e.options.dataSource;const r=i.splice(t,1);return i.splice(n,0,r[0]),i}(e.sender,e.oldIndex,e.newIndex-1)},dataSource:n.chartState.series}).data("kendoGrid");n._seriesGrid=r},_handleSeriesEdit:function(e){const t=this;const n=e.sender;const i=n.options.dataSource;const r=n.dataSource.indexOf(e.model);const o={...i[r],name:e.model.name};i.splice(r,1,o),t._executeAction(i,n),t.trigger(S,{state:t.chartState})},_handleSeriesRemove:function(e){const t=this;const n=e.sender.options.dataSource;let i;const r=n.find(((t,n)=>(i=n,t.name===e.model.name)));n.splice(i,1),t._removedSeries?t._removedSeries.unshift(r):t._removedSeries=[r]},_toggleFieldsForSeriesPanel:function(t){const n=this;const i=e(n._dynamicConfigurationFields.grid[0].outerHTML);const r=e(n._dynamicConfigurationFields.valueAxis[0].outerHTML);const o=n._dynamicConfigurationFields.container;const a=s(t);if(i&&r&&!(n._oldType===t||s(n._oldType)&&a)){if(a)n._seriesValueAxisDDL&&n._seriesValueAxisDDL.wrapper&&n._seriesValueAxisDDL.wrapper.data&&n._seriesValueAxisDDL.destroy(),delete n._seriesValueAxisDDL,o.find("[data-action=valueAxisY]").closest(".k-form-fieldset").remove(),o.append(i),n._initGrid(i.find(".k-grid"));else{n._seriesGrid&&n._seriesGrid.wrapper&&n._seriesGrid.wrapper.data&&n._seriesGrid.destroy(),delete n._seriesGrid,o.find(".k-grid").closest(".k-form-fieldset").remove(),o.append(r);const e=r.find(`[${R}${ie}]`);n._seriesValueAxisDDL=n._createDropDownList(e,{value:n.chartState.valueField||"",dataSource:n.chartState.columns.map((e=>({text:e,value:e})))},n._seriesDropDownChange.bind(n))}n._oldType=t,n._preventLabelPointerEvents()}},_initStaticEditors:function(){const t=this;t.element.find(".k-form").each(((n,i)=>{const r=e(i).closest(`[${z}]`);const o=e(r).find(`[${H}]`);const a=t._getRefAttributeValue(r[0])[0];t._initEditors(o,a)})),t._toggleFieldsForSeriesPanel(t.chartState.seriesType),t._toggleFormatPanels()},_initEditors:function(t,n){const i=this;t.each(((t,r)=>{const o=e(r);const a=o.attr("id");const s=o.data("role");const l=i._getOptionsForPanel(a)[n][s];const c=l?l.options:l;const d=l?l.handler:l;"combobox"===s?i._createFontCombobox(o,c,d):"dropdownlist"===s?i._createDropDownList(o,c,d):"colorpicker"===s?i._createColorPicker(o,c,d):"numerictextbox"===s?i._createNumericTextBox(o,c,d):"switch"===s?i._createSwitch(o,c,d):"checkbox"===s?i._createCheckBox(o,c,d):"textbox"===s&&i._createTextBox(o,c,d)}))},_prepareFormatTab:function(){const e=this;const t=e.element.find(`[${P}'categoryaxis'] > form`);const n=e.element.find(`[${P}'valueaxis'] > form`);e._dynamicFormatPanels={categoryAxis:t,valueAxis:n,container:t.closest(I+Y).parent()},e._initialAxesPanelsContent={categoryAxis:t.clone(),valueAxis:n.clone()},t.closest(I+Y).remove(),n.closest(I+Y).remove()},_toggleFormatPanels:function(){const n=this;const i=n.options.messages.format;const r=n.chartState.seriesType;const o=n._dynamicFormatPanels.categoryAxis;const a=n._dynamicFormatPanels.valueAxis;const s=n._dynamicFormatPanels.container;const l=n._initialAxesPanelsContent.categoryAxis.html();const c=n._initialAxesPanelsContent.valueAxis.html();if(o.empty().append(l),a.empty().append(c),"pie"!==r){let l=t.htmlEncode(i.categoryAxis.expandText);let c=t.htmlEncode(i.valueAxis.expandText);if("scatter"===r&&(l=t.htmlEncode(i.xAxis.expandText),c=t.htmlEncode(i.yAxis.expandText)),0===s.find(e(a)).length){const t=e(be("categoryaxis-format-panel")).append(o);const n=e(be("valueaxis-format-panel")).append(a);s.append(t),s.append(n),e(t).kendoExpansionPanel({title:l}),e(n).kendoExpansionPanel({title:c})}else o.closest(I+Y).find(".k-expander-title").text(l),a.closest(I+Y).find(".k-expander-title").text(c);o.closest(I+Y).length&&o.closest(`[${z}]`).add(a.closest(`[${z}]`)).each(((t,i)=>{const r=e(i).find(`[${H}]`);const o=n._getRefAttributeValue(i)[0];n._initEditors(r,o)}))}else if(s.find(a).length){const e=o.closest(I+Y);const n=a.closest(I+Y);t.destroy(e),t.destroy(n),e.remove(),n.remove()}n._preventLabelPointerEvents()},_handlePropertyChange:function(e,t){const n=this;const i=t||""===t?t:e.sender.value();const r=n._executeAction(i,e.sender);return!e.preventChange&&n.trigger(S,{state:n.chartState}),r},_getOptionsForPanel:function(e){const n=this;const i=n.chartState;const r=n.options.messages;const o=(e=>[{value:"bottom",text:e.position.bottom},{value:"top",text:e.position.top},{value:"left",text:e.position.left},{value:"right",text:e.position.right}])(r.format.legend).map((e=>({...e,text:t.htmlEncode(e.text)})));const a=(e=>[{value:"",text:e.labels.labelFormat.text},{value:"n0",text:e.labels.labelFormat.number},{value:"c0",text:e.labels.labelFormat.currency},{value:"p0",text:e.labels.labelFormat.percent}])(r.format.valueAxis).map((e=>({...e,text:t.htmlEncode(e.text)})));const l=(e=>[{value:"title",text:e.format.title.chartTitle},{value:"subtitle",text:e.format.title.chartSubtitle}])(r).map((e=>({...e,text:t.htmlEncode(e.text)})));const c=e.includes("title")?"title":"labels";const d=e.includes("category");return{configuration:{dropdownlist:{options:{value:i[d?"categoryField":"valueField"],dataSource:i.columns.map((e=>({text:e,value:e})))},handler:n._seriesDropDownChange.bind(n)}},chartarea:{numerictextbox:{options:{value:i.chartArea&&i.chartArea.margin[e]?i.chartArea.margin[e]:null,min:0,max:1e3}},colorpicker:{options:{value:i.chartArea.background&&i.chartArea.background.color||""}}},title:{dropdownlist:{options:{dataSource:l,value:n._activeTitle&&l.find((e=>e.value===n._activeTitle.value))},handler:n._titleFieldChange.bind(n)},textbox:{options:{value:n._activeTitle&&i[n._activeTitle].text}},colorpicker:{options:{value:n._activeTitle&&i[n._activeTitle].color}}},series:{dropdownlist:{options:{dataSource:[{name:t.htmlEncode(r.format.series.allSeries)},...i.series],dataTextField:"name",dataValueField:"name",enable:s(i.seriesType),value:n._activeSeries&&i.series.find((e=>e.name===n._activeSeries))},handler:n._activeSeriesChange.bind(n)},colorpicker:{options:{value:n._activeSeries?i.series.find((e=>e.name===n._activeSeries)).color:"",enable:!1},handler:n._changeSeriesColor.bind(n)},checkbox:{options:{label:r.format.series.showLabels,checked:n._activeSeries?i.series.find((e=>e.name===n._activeSeries)).labels.visible:i.series.every((e=>e.labels?.visible))},handler:n._showLabels.bind(n)}},legend:{dropdownlist:{options:{dataSource:o,value:i.legend&&i.legend.position&&o.find((e=>e.value===i.legend.position))}},colorPicker:{options:{value:i.legend&&i.legend.labels&&i.legend.labels.color||""}},switch:{options:{checked:i.legend&&i.legend.visible}}},categoryaxis:{textbox:{options:{value:i.categoryAxis[0][c]&&i.categoryAxis[0][c].text||""}},numerictextbox:{options:{value:i.categoryAxis[c]&&i.categoryAxis[c].rotation,min:-360,max:360}},checkbox:{options:{label:r.format.categoryAxis[c].reverseOrder,checked:i.categoryAxis[0].reverse||!1}},colorpicker:{options:{value:i.categoryAxis[0][c]&&i.categoryAxis[0][c].color||""}}},valueaxis:{dropdownlist:{options:{dataSource:a,value:i.valueAxis[c]&&i.valueAxis[c].labelFormat&&a.find((e=>e.value===i.valueAxis[c].labelFormat))}},textbox:{options:{value:i.valueAxis[c]&&i.valueAxis[c].text||""}},numerictextbox:{options:{value:i.valueAxis[0][c]&&"number"==typeof i.valueAxis[0][c].rotation?i.valueAxis[0][c].rotation:null,min:-360,max:360}},colorpicker:{options:{value:i.valueAxis[0][c]&&i.valueAxis[0][c].color||""}}}}},_titleFieldChange:function(t){const n=this;const i=n._applyTo(t);const r=t.sender.wrapper.closest(".k-form");r.find(`[${R}${ee}]`).data("kendoTextBox").value(n.chartState[i].text),r.find(`[${R}${J}]`).data("kendoColorPicker").value(n.chartState[i].color??""),r.find(`[${R}${te}]`).each(((t,r)=>{const s=e(r).data("action").includes("FontName")?"name":"size";const l=n._parseFont(n.chartState[i].font)[s].toString();const c=e(r).data("kendoComboBox");let d;if(l){const e=new RegExp(`${l.replaceAll('"',"").split(",")[0]}`,"g");d="name"===s?a.find((t=>e.test(t.text))):o.find((e=>e.text===l.toString())),d&&n._handlePropertyChange({sender:c},d?d.value:null)}n._activeTitle=i,c._fontState.active=i,c.value(d?d.text:null)}))},_activeSeriesChange:function(e){const t=this;const n=e.sender.value();const i=e.sender.wrapper.closest(".k-form").find(`[${R}${J}]`).data("kendoColorPicker");if(n!==t.options.messages.format.series.allSeries){const e=t.chart.options.series.find((e=>e.name===n));i.enable(!0),e&&i.value(e.color),i._currentActiveSeries=n,t._activeSeries=n}else i.value(""),i.enable(!1),i._currentActiveSeries=null,t._activeSeries=null},_applyTo:function(t){const n=t.sender.value();return t.sender.wrapper.closest(".k-form").find(B).each(((i,r)=>{const o=e(r);if(!o.is(t.sender.element)){const e=o.data("action").split($);e.shift();const t=n+e.join("");o.attr(L,t).data("action",t)}})),n},_showLabels:function(e){const t=e.sender.check();const n=e.sender.wrapper.closest(".k-form").find(`[${R}${J}]`).data("kendoColorPicker");this._handlePropertyChange(e,{seriesName:n._currentActiveSeries,all:!n._currentActiveSeries,visible:t})},_changeSeriesColor:function(e){const t=e.value;this._handlePropertyChange(e,{seriesName:e.sender._currentActiveSeries,color:t})},_getRefAttributeValue:function(e){return e.getAttribute(`${z}`).split("-")},_expansionPanels:function(){const n=this;let i="";let r=0;n.tabStrip.contentElements.children().each(((o,a)=>{const s=n._getRefAttributeValue(a)[1];i===s?r++:r=0;const l=Object.keys(n.options.messages[s]);const c=e(a).kendoExpansionPanel({title:t.htmlEncode(n.options.messages[s][l[r]].expandText),complete:()=>{n._seriesGrid&&n._seriesGrid.wrapper.is(":visible")&&(n._seriesGrid._draggableRows(),n._seriesGrid._reorderableRows())}}).data("kendoExpansionPanel");c.wrapper.removeClass(),c.wrapper.addClass(Y),i=s}))},setOptions:function(e){if(!e)return;const t=this;const n=null!==e.dataSource&&void 0!==e.dataSource;const i=null!==e.dataColumns&&void 0!==e.dataColumns;null!==e.state&&void 0!==e.state&&delete t.options.state,n&&delete t.options.dataSource,i&&delete t.options.dataColumns,m(t.options,e),i&&t.setDataColumns(e.dataColumns),n?t.setDataSource(t.options.dataSource):t._refreshContent()},destroy:function(){const e=this;t.destroy(e.previewPane),t.destroy(e.propertyPane),e.element.empty(),n.fn.destroy.call(e),e.element.off(u),e.wrapper.off(u),e._detachEvents(),e.splitter&&e.splitter.destroy(),e.chart&&e.chart.destroy(),e.tabStrip&&e.tabStrip.destroy(),e.window&&e.window.destroy(),e.chart=e.tabStrip=e.window=e.splitter=e.propertyPane=e.chartState=e.previewPane=null,e._dynamicConfigurationFields=e._dynamicFormatPanels=e._initialAxesPanelsContent=e._initialState=e._oldType=e._seriesGrid=null}});p.plugin(Pe),f(t.ui.ChartWizard,{generateDataRows:ze,getWizardDataFromDataRows:h})}(window.kendo.jQuery);kendo;kendo;!function(){var e=window.kendo;var t=e.ui.Widget;var n=e.htmlEncode;var i="__style";var r=`${i}="display: flex; align-items: center;"`;var o=e=>`<span ${i}="margin: 0 3px">${e}</span>`;var a=e=>`<div ${i}="width: 15px; height: 15px; background-color: ${e}; display: inline-flex; margin-left: 3px"></div>`;var 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>`}};var 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();const 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;const n=t.template;const i=t.ui.Widget;const r=t.dataviz;const o=t.htmlEncode;const a=t.support.isRtl;const{Tooltip:s,ContentTemplates:l}=r.SankeyTooltip;const 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);this._createSankey(this.options,e),this.options=this._instance.options},_createSankey:function(e,t){this._instance=new v2(this.element[0],e,t)},_getThemeOptions:function(e){var t=(e||{}).theme;if(t&&-1!==r.SASS_THEMES.indexOf(t.toLowerCase())){this.element.addClass("k-chart");const e=(e=>({labels:{color:E3(e),font:A3(e),stroke:{color:C3(e,"--kendo-chart-bg")}},links:{color:C3(e,"--kendo-color-subtle")},nodeColors:M3(e),title:I3(e),legend:z3(e)}))(this.element[0]);return this.element.removeClass("k-chart"),e}if(HN(t)){var n=r.ui.themes||{};const e=(n[t]||n[t.toLowerCase()]||{}).chart||{};const{seriesColors:i,axisDefaults:o,seriesDefaults:a,legend:s,title:l}=e;const{line:c,labels:d}=o;return{nodeColors:i,links:c,labels:{...d,stroke:{color:a.labels.background}},legend:s,title:l}}},_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;const{nodeTemplate:c,linkTemplate:d,offset:h}=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 u=n(("node"===i.targetType?c:d)||l[i.targetType]);const p=o(t.format(this.options.messages.tooltipUnits,HN(i.nodeValue)?i.nodeValue:i.dataItem.value));this._tooltip.setContent(u({dataItem:i.dataItem,value:p,rtl:a})),this._tooltip.setPosition(i.tooltipData.popupAlign,i.tooltipData.popupOffset,h),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:b2})}(window.kendo.jQuery);kendo;!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=window.kendo;var n=t.ui.Widget;var i=t.dataviz;var r=t.drawing;function o(e,t){var n=i.ui.themes||{};var r=e.theme||"";var o=r.toLowerCase();if(-1!=i.SASS_THEMES.indexOf(o)){t.addClass("k-gauge");const e=L3(t[0]);return t.removeClass("k-gauge"),e}return(n[r]||n[o]||{}).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.element)),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.element)),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()}});var 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 hZ}});var h=a.extend({options:{name:"LinearGauge",scale:{vertical:!0}},_gaugeType:function(){return XX}});var u=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);var n=this._instance;var 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 mZ}});var p=u.extend({options:{name:"CircularGauge"},_gaugeType:function(){return gZ}});function f(e){u.fn[e]=function(t){var n=this;var 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(h),i.ui.plugin(d),i.ui.plugin(u),i.ui.plugin(p),t.deepExtend(i,{Gauge:a,LinearScale:OX,RadialScale:rZ,RadialPointer:cZ,LinearPointer:NX,BarLinearPointer:YX,ArrowLinearPointer:jX,LinearGauge:h,RadialGauge:d,ArcGauge:u,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 h=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 HN(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))}});var u={};var p=h.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(){}});var 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){var t,n=this;for(var 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"]};u.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}}),u.code39extended=u.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}}})),u.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){var t;for(var 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"}}),u.code93extended=u.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(){}});var 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){var t=this,n=0;for(;!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});var 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){var t;for(;(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;var o;if(e.index+=r,r<3)for(;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){var t=this;for(var n=0;n<t.subStates.length;n++)if(t.encoding[t.subStates[n]].isCode(e))return t.subStates[n]},_getAll:function(e,t){var n,i="";for(;(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){var n,i,r=this;for(var 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){var r=n[i].ranges;for(var 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 _=h.extend({init:function(e){h.fn.init.call(this,e),this._initStates()},_initStates:function(){var e=this;for(var 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){var n=this;for(;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){var t,n=this,i=n.characterMap[e].toString();for(var 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});u.code128a=_.extend({name:"Code 128 A",states:["A"]}),u.code128b=_.extend({name:"Code 128 B",states:["B"]}),u.code128c=_.extend({name:"Code 128 C",states:["C"]}),u.code128=_.extend({name:"Code 128",states:["C","B","A","FNC4"]}),u["gs1-128"]=_.extend({name:"Code GS1-128",states:["FNC1","C","B"]});var b=h.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){var t,n=0,i=e.length;for(var 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:""});u.msimod10=b.extend({name:"MSI Modulo10",checkSumType:"Modulo10"}),u.msimod11=b.extend({name:"MSI Modulo11",checkSumType:"Modulo11"}),u.msimod1110=b.extend({name:"MSI Modulo11 Modulo10",checkSumType:"Modulo11Modulo10"}),u.msimod1010=b.extend({name:"MSI Modulo10 Modulo10",checkSumType:"Modulo10Modulo10"}),u.code11=h.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;var 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){var i=0;for(var 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){var t;for(var 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}}),u.postnet=h.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){var t,n=this;for(var 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"]}),u.ean13=h.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){var n=this;for(var 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){var n=this;for(var 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(){var e=0,t=0,n=this.value.split("").reverse().join("");for(var 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]}}),u.ean8=u.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 w=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=Fc.create(r.surfaceWrap[0],{type:r.options.renderAs}),r._setOptions(i),i&&HN(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=mN(o.margin),s=n._getSize(),l=i.border||{},c=n.encoding,d=new hU(0,0,s.width,s.height).unpad(l.width).unpad(i.padding),h=d.height();var u=new Us;return n.contentBox=d,u.append(n._getBackground(s)),o.visible&&(h-=ha(r,{font:o.font}).height+a.top+a.bottom),e=c.encode(r,d.width(),h),o.visible&&(t=r,i.checksum&&HN(c.checksum)&&(t+=" "+c.checksum),u.append(n._getText(t))),n.barHeight=h,this._bandsGroup=this._getBands(e.pattern,e.baseUnit),u.append(this._bandsGroup),u},exportVisual:function(){return this._render()},_getSize:function(){var e=this,t=e.element,n=new wa(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(!HN(e))return t.options.value;t.options.value=e+"",t.redraw()},_getBands:function(e,t){var n,i,r=this,o=r.contentBox,s=o.x1;var l=new Us;for(var 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=ya.fromPoints(new ba(s,i.y1+o.y1),new ba(s+n,i.y2+o.y1));var h=Rs.fromRect(d,{fill:{color:r.options.color},stroke:null});l.append(h)}s+=n}return l},_getBackground:function(e){var t=this.options,n=t.border||{};var i=new hU(0,0,e.width,e.height).unpad(n.width/2);return Rs.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 RU(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),!u[t.type])throw new Error("Encoding "+t.type+"is not supported.");t.encoding=new u[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(w.fn),s.ui.plugin(w),t.deepExtend(s,{encodings:u,Encoding:h})}(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},h={0:1},u=[[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}],w=/^\d+/,y="A-Z0-9 $%*+./:-",k=new RegExp("^[A-Z $%*+./:-]+"),x=new RegExp("^["+y+"]+"),C=new RegExp("^[^"+y+"]+"),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]],M=[[0,1],[1,1],[1,0]];function A(e){return parseInt(e,2)}function D(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){var n=[],i=0;for(;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+D(e,this.getBitsCharacterCount(t))},encode:function(){},getStringBitsLength:function(){},getValue:function(){},modeIndicator:"",bitsInCharacterCount:[]});var z={};z[s]=I.extend({bitsInCharacterCount:[10,12,14],modeIndicator:"0001",getValue:function(e){return parseInt(e,10)},encode:function(e,t){var n=E(e,3),i=this.getModeCountString(e.length,t);for(var r=0;r<n.length-1;r++)i+=D(n[r],10);return i+D(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){var n=this,i=E(e,2),r=n.getModeCountString(e.length,t);for(var o=0;o<i.length-1;o++)r+=D(45*n.getValue(i[o].charAt(0))+n.getValue(i[o].charAt(1)),11);return r+D(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){var n=this.getModeCountString(e.length,t);for(var i=0;i<e.length;i++)n+=D(this.getValue(e.charAt(i)),8);return n},getStringBitsLength:function(e,t){return 4+this.getBitsCharacterCount(t)+8*e}});var P={};for(var L in z)P[L]=new z[L];var B=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 H(e,t,n,i){for(var r=0;r<e.length;r++)e[r][n][i]=t}function R(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 F=function(e,t){var n,i,r,o=new B(e[0]);for(var 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(),R(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();)R(e,0,r.row,r.column)};var O=function(e,t){var n=8*t,i=0,r=0;for(;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){var n=[];for(var i=e.length-2;i>=0;i--)n[i]=e[i]^t[i];return n};var N=function(e,n){var i=[];for(var 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[h[i[r+o]]^h[(e[r]+n[o])%255]];return i};function $(e,n){var i=[],r=e.length-1;do{i[r]=h[(e[r]+n)%255],r--}while(e[r]!==t);return i}!function(){var e;for(var t=1;t<255;t++)(e=2*h[t-1])>255&&(e^=285),h[t]=e,d[e]=t;e=2*h[t-1]^285,h[t]=e,h[-1]=0}(),function(){for(var e=2;e<=68;e++){var t=u[e-1],n=[e,0];u[e]=N(t,n)}}();var U=function(e,t){var n,i,r=u[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]=D(o[i],8);return l};var W=function(e,t){var n,i,r,o,a,s=0,l=[],c=[],d=t.groups;for(var h=0;h<d.length;h++){r=d[h][0];for(var u=0;u<r;u++){i=d[h][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]};var j=function(e,t,n,i,r){var o,a,d=w.exec(e),h=d?d[0]:"",u=k.exec(e),p=u?u[0]:"",f=x.exec(e),m=f?f[0]:"";return h&&(h.length>=t||e.length==h.length||h.length>=n&&!x.test(e.charAt(h.length)))?(o=s,a=h):m&&(e.length==m.length||m.length>=i||r==l)?(o=l,a=h||p):(o=c,a=m?m+C.exec(e.substring(m.length))[0]:C.exec(e)[0]),{mode:o,modeString:a}};var 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};var G=function(e){var t=0;for(var n=0;n<e.length;n++)t+=P[e[n].mode].getStringBitsLength(e[n].modeString.length);return Math.ceil(t/8)};var 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};var Y=function(e,t){var n="";for(var i=0;i<e.length;i++)n+=P[e[i].mode].encode(e[i].modeString,t);return n};var 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};var X=function(e,t,n){var i=A(t),r=t.length-1,o=e<<r,a=D(e,n-r),s=Z(o,i);return s=a+D(s,r)};var 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){var t=[],n=17+4*e;for(var 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};var 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&&H(e,J(t,a-1-o++),n,i);for(n=8,i=7;i>=0;i--)6!==i&&H(e,J(t,a-1-o++),n,i);for(o=0,i=r.length-1,n=8;i>=r.length-8;i--)H(e,J(t,a-1-o++),n,i);for(H(e,1,r.length-8,8),n=r.length-7,i=8;n<r.length;n++)H(e,J(t,a-1-o++),n,i)};var ne=function(e){return X(e,"1111100100101",18)};var ie=function(e,t){var n,i,r,o=e[0].length,a=o-11,s=o-11;for(var l=0;l<t.length;l++)n=Math.floor(l/3),i=l%3,H(e,r=J(t,t.length-l-1),0+n,a+i),H(e,r,s+i,0+n)};var re=function(e,t,n,i){var r,o=t.length+2,a=t.length+1;for(var s=0;s<t.length;s++)for(var l=s;l<o-s;l++)H(e,r=t[s],n+l,i+s),H(e,r,n+s,i+l),H(e,r,n+a-l,i+a-s),H(e,r,n+a-s,i+a-l)};var oe=function(e,t,n,i){var r=n,o=i,a=e[0];do{H(e,0,r,i),H(e,0,n,o),r+=t[0],o+=t[1]}while(r>=0&&r<a.length)};var 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)};var 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 h=0;h<l.length;h++)o[l[d]][l[h]]===t&&re(e,g,l[d]-2,l[h]-2)}};var le=function(e){var t=1,n=e[0].length;for(var i=8;i<n-8;i++)H(e,t,6,i),H(e,t,i,6),t^=1};var 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]),he(d,i,r,t[n][c],s,0),he(d,i,r,t[c][n],s,1);var h,u=l*l,p=Number.MAX_VALUE;for(n=0;n<i.length;n++)i[n]+=ue(o[n],u),i[n]<p&&(p=i[n],h=n);return h};function de(e,t,n,i,r){t[e][i]=(t[e][i]<<1^r)%128,93==t[e][i]&&(n[e]+=40)}function he(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 ue(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};var 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)}};var 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){var t=this.utfBOM;for(var 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=D(e,8);else{var r=8-t;for(var o=0;o<n;o++)i=D(e>>6*o&63|128,8)+i;i=(e>>6*n|255>>r<<r).toString(2)+i}return i},getBytesCount:function(e){var t=this.ranges;for(var 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};var 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,D(0,18)),te(l,D(0,15)),F(l,s);var c=ce(l),d=l[c];r>=7&&ie([d],ne(r));var h=v[t]+D(c,3);return te([d],Q(h)),d};var _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};var 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=Fc.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 Us;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;var r=S(e/2);var o=this._getLogoSize(7*t);var a=this.options.overlay.imageUrl;var 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 Ns(a,i)},_renderSwissCode:function(e,t){var n=this._getLogoSize(7*t);var i=(n=Math.max(n.width,n.height))/4;var r=i/2;var o=e/2;var a={};var s=new Us;return a.x=a.y=Math.ceil(o-t-n/2),s.append(this._renderShape(a,Math.ceil(n+2*t),M,"#fff")),a.x=a.y=o-n/2,s.append(this._renderShape(a,n,M,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 Fs({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){var i=new Fs({fill:{color:this.options.color},stroke:null});for(var r=0;r<e.length;r++){var o=n+r*t;var a=0;for(;a<e.length;){for(;0===e[r][a]&&a<e.length;)a++;if(a<e.length){var s=a;for(;1==e[r][a];)a++;var l=S(n+s*t);var c=S(o);var d=S(n+a*t);var h=S(o+t);i.moveTo(l,c).lineTo(l,h).lineTo(d,h).lineTo(d,c).close()}}}return i},_renderBackground:function(e,t){var n=new hU(0,0,e,e).unpad(t.width/2);return Rs.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;var 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:B,fillData:F,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:h,generatorPolynomials:u}})}(window.kendo.jQuery);kendo;!function(){window.kendo.dataviz=window.kendo.dataviz||{};var e=window.kendo;var t=e.dataviz;var n=t.ui.Chart;var i=e.deepExtend;var r=lX;var o=sX;var a="change";var 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(t,n){this._initNavigatorOptions(t),this._instance=new pX(this.element[0],t,n,{observer:new DN(this,{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown",navigatorFilter:"_onNavigatorFilter",navigatorCreated:"_onNavigatorCreated"}),sender:this,rtl:this._isRtl(),createSurface:e.drawing.Surface.create})},_initNavigatorOptions:function(t){var n=t.navigator||{};var r=e.support;var o=r.touch;var 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,h=d&&d.from&&d.to;if(s&&h){var u=[].concat(a.filter||[]);var p=e.parseDate(d.from);var f=e.parseDate(d.to);var m=new t.DateCategoryAxis(i({baseUnit:"fit"},c,{categories:[p,f]}),e);a.filter=l(m.range().min,f).concat(u)}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;var n=t.autoBind;var i=t.dataSource;i&&(this._navigatorDataChangedHandler=this._navigatorDataChangedHandler||this._onNavigatorDataChanged.bind(this),this._navigatorDataSource=e.data.DataSource.create(i).bind(a,this._navigatorDataChangedHandler),HN(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(TN("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:dX,Navigator:hX,NavigatorHint:aX,StockChart:s}),t.ui.plugin(s)}(window.kendo.jQuery);kendo;window.kendo.dataviz=window.kendo.dataviz||{};const N3=window.kendo.jQuery;var $3=kendo.dataviz;var U3=$3.ui.Chart;var W3=N3.extend;var j3=U3.extend({init:function(e,t){var n=t;n instanceof kendo.data.ObservableArray&&(n={seriesDefaults:{data:n}}),U3.fn.init.call(this,e,iX.normalizeOptions(n))},_createChart:function(e,t){this._instance=new iX(this.element[0],e,t,{observer:new DN(this,{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown"}),sender:this,rtl:this._isRtl(),createSurface:kendo.drawing.Surface.create})},_createTooltip:function(){return new q3(this.element,W3({},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}]}});$3.ui.plugin(j3);var q3=$3.Tooltip.extend({options:{animation:{duration:0}},_hideElement:function(){this.element&&this.element.hide().remove()}});$3.Sparkline=j3,$3.SparklineTooltip=q3;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){var i=e.toHyphens(t).split("-");for(var 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();var t={i:1,v:5,x:10,l:50,c:100,d:500,m:1e3};var n=0,i=0;for(var 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){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"};var 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];var i="";for(;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(){var n="";for(var 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,h=c.dataviz,u=c.deepExtend,p=c.drawing.util,f=p.defined,m=p.deg,g=p.rad,v=p.round,_=p.valueOrDefault,b=c.util.sqr;var w=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 w(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||h.map.datums.WGS84;var a=g(this.lat);var l=g(this.lng);var d=t/c.dataviz.map.datums.WGS84.a;var u=e.asin(s(a)*r(d)+r(a)*s(d)*r(n));var p=l+i(s(n)*s(d)*r(a),r(d)-s(a)*s(u));return new w(m(u),m(p))},greatCircleTo:function(o,a){if(o=w.create(o),a=a||h.map.datums.WGS84,!o||this.clone().round(8).equals(o.clone().round(8)))return{distance:0,azimuthFrom:0,azimuthTo:0};var c=a.a;var d=a.b;var u=a.f;var p=g(o.lng-this.lng);var f=n((1-u)*l(g(this.lat)));var _=s(f);var y=r(f);var k=n((1-u)*l(g(o.lat)));var x=s(k);var C=r(k);var S=p;var T;var M=this.DISTANCE_ITERATIONS;var A=!1;var D;var E;var I;var z;var P;var L;var B;for(;!A&&M-- >0;){D=s(S),E=r(S),I=e.sqrt(b(C*D)+b(y*x-_*C*E)),B=i(I,P=_*x+y*C*E);var H=y*C*D/I;L=0,0!==(z=1-b(H))&&(L=P-2*_*x/z),T=S;var R=u/16*z*(4+u*(4-3*z));S=p+(1-R)*u*H*(B+R*I*(L+R*P*(2*b(L)-1))),A=t(S-T)<=this.DISTANCE_CONVERGENCE}var F=z*(b(c)-b(d))/b(d);var O=1+F/16384*(4096+F*(F*(320-175*F)-768));var V=F/1024*(256+F*(F*(74-47*F)-128));var N=V*I*(L+V/4*(P*(2*b(L)-1)-V/6*L*(4*b(I)-3)*(4*b(L)-3)));var $=i(C*D,y*x-_*C*E);var U=i(y*D,-_*C+y*x*E);return{distance:v(d*O*(B-N),this.DISTANCE_PRECISION),azimuthFrom:m($),azimuthTo:m(U)}}});w.fn.toString=function(){return c.format(this.FORMAT,this.lat,this.lng)},w.fromLngLat=function(e){return new w(e[1],e[0])},w.fromLatLng=function(e){return new w(e[0],e[1])},w.create=function(e,t){if(f(e))return e instanceof w?e.clone():1===arguments.length&&2===e.length?w.fromLatLng(e):new w(e,t)};var y=d.extend({init:function(e,t){e=w.create(e),t=w.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;var t=this.se;var n=e.lng+(t.lng-e.lng)/2;var i=e.lat+(t.lat-e.lat)/2;return new w(i,n)},containsAny:function(e){var t=!1;for(var 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 w(e.lat,t.lng),se:this.se,sw:new w(t.lat,e.lng)}},toArray:function(){var e=this.nw,t=this.se;return[e,new w(e.lat,t.lng),t,new w(t.lat,e.lng)]},overlaps:function(e){return this.containsAny(e.toArray())||e.containsAny(this.toArray())}});y.World=new y([90,-180],[-90,180]),y.create=function(e,t){return e instanceof y?e:e&&t?new y(e,t):e&&4===e.length&&!t?new y([e[0],e[1]],[e[2],e[3]]):void 0},u(h,{map:{Extent:y,Location:w}})}(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;var 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:" | ",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){var t=[];for(var 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(){var e=[];var t=n(this.options.itemTemplate);for(var i=0;i<this.items.length;i++){var r=this.items[i];var 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="";var n=this._inZoomLevel(e.minZoom,e.maxZoom);var 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;var n=t.ui.Widget;var 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");var 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;var i=0;var 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;var n=t.ui.Widget;var 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");var 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,h=s.geometry,u=h.Point,p=c.map.Location,f=s.drawing.util,m=f.rad,g=f.deg,v=f.limitValue;var _=e.PI,b=_/2,w=_/4,y=_/180;var k={a:6378137,b:6356752.314245179,f:.0033528106647474805,e:.08181919084262149};var 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 u(l,c)},_projectLat:function(e){var t=this.options.datum,n=t.e,s=t.a,l=m(e),c=a(w+l/2),d=n*r(l),h=i((1-d)/(1+d),n/2);return s*o(c*h)},inverse:function(e,t){var n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=e.x/(y*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,h=d/2,u=n(-o/c),p=b-2*t(u);for(a=0;a<=s.INVERSE_ITERATIONS;a++){var f=d*r(p),m=i((1-f)/(1+f),h),v=b-2*t(u*m)-p;if(p+=v,e.abs(v)<=s.INVERSE_CONVERGENCE)break}return g(p)}});var C=x.extend({MAX_LAT:85.0511287798,_projectLat:function(e){var t=this.options.datum.a,n=m(e),i=a(w+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))}});var S=l.extend({forward:function(e){return new u(e.lng,e.lat)},inverse:function(e){return new p(e.y,e.x)}});var T=l.extend({init:function(){var e=this._proj=new C;var t=this.c=2*_*e.options.datum.a;this._tm=h.transform().translate(.5,.5).scale(1/t,-1/t),this._itm=h.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)}});var M=l.extend({init:function(){this._proj=new x},toPoint:function(e){return this._proj.forward(e)},toLocation:function(e){return this._proj.inverse(e)}});var 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:M,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;var 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;var t=this.map.zoom();var n=!a(e.minZoom)||t>=e.minZoom;var i=!a(e.maxZoom)||t<=e.maxZoom;var r=o.create(e.extent);var 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,h=d.Location,u=d.layers.Layer;var p=u.extend({init:function(t,n){this._pan=this._pan.bind(this),u.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(){u.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(){u.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));var t=new s;for(var 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){u.fn._panEnd.call(this,e),this._translateSurface(),this.surface.resumeTracking(),this._panning=!1},_translateSurface:function(){var e=this.map;var 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(){u.fn._activate.call(this),this.map.bind("pan",this._pan)},_deactivate:function(){u.fn._deactivate.call(this),this.map.unbind("pan",this._pan)}});var f=t.extend({init:function(e,t,n){this.observer=n,this.locator=e,this.style=t},parse:function(e){var t=new s;var 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=t.coordinates;var r;var o;switch(t.type){case"LineString":o=this._loadPolygon(e,[i],n),this._setLineFill(o);break;case"MultiLineString":for(r=0;r<i.length;r++)o=this._loadPolygon(e,[i[r]],n),this._setLineFill(o);break;case"Polygon":this._loadPolygon(e,i,n);break;case"MultiPolygon":for(r=0;r<i.length;r++)this._loadPolygon(e,i[r],n);break;case"Point":this._loadPoint(e,i,n);break;case"MultiPoint":for(r=0;r<i.length;r++)this._loadPoint(e,i[r],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){var t=new(e.length>1?a.MultiPath:a.Path)(this.style);for(var n=0;n<e.length;n++)for(var i=0;i<e[n].length;i++){var r=this.locator.locationToView(h.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=h.fromLngLat(t);var r=this.locator.locationToView(i);var s=new o.Circle(r,10);var 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;var 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;var i=t(n.valueField);(e=e.slice(0)).sort((function(e,t){return i(t)-i(e)}));var r=this._scaleType();var o;for(var s=0;s<e.length;s++){var c=e[s];var d=t(n.locationField)(c);var h=t(n.valueField)(c);if(a(d)&&a(h)){o||(o=new r([0,h],[n.minSize,n.maxSize])),d=l.create(d);var u=this.map.locationToView(d);var p=o.map(h);var f=this._createSymbol({center:u,size:p,style:n.style,dataItem:c,location:d});f.dataItem=c,f.location=d,f.value=h,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)}});var d=e.Class.extend({init:function(e,t){this._domain=e,this._range=t;var n=Math.sqrt(e[1])-Math.sqrt(e[0]);var 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);var n=e.size/2;var 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,h=n.drawing.util,u=h.round,p=h.limitValue;var 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;var 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()}});var 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);var 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)}});var 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)}});var 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(){var e=this._items;for(var t=0;t<e.length;t++)e[t].destroy();this._items=[]},reset:function(){var e=this._items;for(var t=0;t<e.length;t++)e[t].hide()},_create:function(e){var t=this._items;var n;var i=c.hashKey(e.point.toString()+e.offset.toString()+e.zoom+e.urlTemplate);for(var r=0;r<t.length;r++)if(t[r].id===i){n=t[r];break}return n?n.show():(n=new g(i,e),this._items.push(n)),n},_remove:function(e){var t=this._items;var n=-1;var i=-1;for(var 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(u(e.x),u(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;var 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++){var i=t[n];for(var 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()}});var 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,h=d.Location,u=d.layers.Layer;var p=u.extend({init:function(e,t){u.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(){u.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(){u.fn._reset.call(this);var e=this.items;for(var 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();var t=r.getter(this.options.locationField);var n=r.getter(this.options.titleField);for(var 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)}});var 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=h.create(e).toArray(),this.layer&&this.layer.update(this),this):h.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;let 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;var t=e.options.title;var 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,h=d.Point,u=l.map,p=u.Extent,f=u.Location,m=u.crs.EPSG3857,g=o.util.renderPos,v=o.drawing.util,_=v.defined,b=v.limitValue,w=v.valueOrDefault;var y=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=h.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=h.create(e)).clone().translateWith(n),this.layerToLocation(e,t)},eventOffset:function(e){var t;var n;var i;var 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=w(a.pageX,a.clientX)-r.left,i=w(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;var t=this._layerSize();var 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);var 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());var r=this.element.width();var o=this.element.height();for(var a=this.options.maxZoom;a>=this.options.minZoom;a--){var s=this.locationToLayer(e.nw,a);var l=this.locationToLayer(e.se,a);var c=n.abs(l.x-s.x);var d=n.abs(l.y-s.y);if(c<=r&&d<=o)break}this.zoom(a)},_getExtent:function(){var e=this._getOrigin();var t=this.locationToLayer(e);var 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;var r="."+g(i).replace(" ",".");var 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");var 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;var n=t.scroller;var i=n.scrollLeft+e.x;var r=n.scrollTop-e.y;var o=this._virtualSize;var a=this.element.height();var 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");var 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;var t=!1!==this.options.zoomable;var 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(){var e=this.options.layers,t=this.layers=[];for(var n=0;n<e.length;n++){var i=e[n];var r=i.type||"shape";var o=this.options.layerDefaults[r];var a=l.map.layers[r];t.push(new a(this,s({},o,i)))}},_initMarkers:function(){this.markers=new u.layers.MarkerLayer(this,this.options.markerDefaults),this.markers.add(this.options.markers)},_scroll:function(e){var t=this.locationToLayer(this._viewOrigin).round();var n=e.sender.movable;var 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;var n=this._scaleToZoom(t);var i=new d.Point(e.center.x,e.center.y);var r=this.viewToLocation(i,n);var 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;var 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;var t=e.dimensions.x;var n=e.dimensions.y;var i=this._layerSize();var o=this.extent().nw;var 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};var 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];var r=i.type||"shape";var o=this.options.layerDefaults[r];var a=l.map.layers[r];t.push(new a(this,s({},o,i)))}},_layerSize:function(e){return e=w(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;var n=this.eventOffset(e);var i=this.viewToLocation(n);var 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;var n=this.options;var i=this.zoom();var r=b(i+t,n.minZoom,n.maxZoom);if(!1!==n.zoomable&&r!==i&&!this.trigger("zoomStart",{originalEvent:e})){var o=this.eventOffset(e);var a=this.viewToLocation(o);var s=this.locationToLayer(a,r).translate(-o.x,-o.y);this._zoomAround(s,r),this.trigger("zoomEnd",{originalEvent:e})}}});l.ui.plugin(y)}(window.kendo.jQuery);kendo;const G3="width";const K3="height";const Y3="x";const Q3="y";const X3="transparent";const Z3="start";const J3="end";const e4={none:"none",arrowStart:"ArrowStart",filledCircle:"FilledCircle",arrowEnd:"ArrowEnd"};var t4;!function(e){e.None="none",e.ArrowStart="ArrowStart",e.FilledCircle="FilledCircle",e.ArrowEnd="ArrowEnd"}(t4||(t4={}));const n4=Math.PI/180;const i4=1e-6;const r4="change";const o4={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"};const a4=10,s4="Auto",l4="Top",c4="Right",d4="Left",h4="Bottom",u4="dragStart",p4="drag",f4="dragEnd",m4="itemRotate",g4="itemBoundsChange",v4="mouseEnter",_4="mouseLeave",b4="zoomStart",w4="zoomEnd",y4="pan",k4="rotated",x4="source",C4="target",S4={"-1":x4,1:C4};const T4="Connection Editing";const M4="cascading",A4=9007199254740992,D4="select",E4="none",I4=Number.MAX_VALUE,z4=-Number.MAX_VALUE,P4="transformed";const L4=e=>Math.abs(e)<i4;const B4=e=>void 0!==e;const H4=B4;const R4=e=>"function"==typeof e;const F4=e=>null==e;const O4=e=>e===Object(e);const V4=(e,t)=>Object.hasOwnProperty.call(e,t);const N4=e=>"[object String]"===Object.prototype.toString.call(e);const $4=e=>!isNaN(parseFloat(e))&&isFinite(e);const U4=e=>{if(null===e)return!0;if(Array.isArray(e)||N4(e))return 0===e.length;for(const t in e)if(V4(e,t))return!1;return!0};const W4=(e,t)=>{if(O4(t))for(const n in t)n&&(e[n]=t[n])};const j4=(e,t)=>{const n=[];for(let i=0;i<e;++i)n[i]=t;return n};const q4=(e,t)=>{const n=Math.floor(Math.random()*t)+e;return parseInt(n.toString(),10)};const G4=(e,t)=>{if(t(e),e.childNodes)for(let n=0;n<e.childNodes.length;n++){const i=e.childNodes[n];G4(i,t)}};const K4=(e,t)=>{if(e===t)return 0;const n=t.x-e.x;const i=e.y-t.y;const r=Math.atan(n/i);return i>=0?n<0?r+2*Math.PI:r:r+Math.PI};const Y4=e=>e?e<0?-1:1:0;const Q4=(e,t)=>180*K4(e,t)/Math.PI;const X4=(e,t,n)=>{for(let i=0;i<e.length;i++)t.call(n,e[i],i,e)};const Z4=(e,t)=>{for(let n=0;n<e.length;++n)if(t(e[n]))return e[n];return null};const J4=(e,t)=>{let n=e.indexOf(t);for(;-1!==n;)e.splice(n,1),n=e.indexOf(t);return e};const e6=(e,t)=>(e||[]).includes(t);const t6=(e,t)=>e.indexOf(t);const n6=(e,t)=>t.indexOf(e);const i6=(e,t)=>e.filter(t);const r6=(e,t,n,i)=>{let r=void 0!==n;for(let o=0;o<e.length;o++){const a=e[o];r?n=t.call(i,n,a,o,e):(n=a,r=!0)}if(!r)throw new Error("Reduce of empty array with no initial value");return n};const o6=(e,t,n)=>e.find(t.bind(n))||void 0;const a6=(e,t,n)=>0===e.length?null:F4(t)?e[0]:o6(e,t,n);const s6=(e,t,n)=>(e.splice(n,0,t),e);const l6=(e,t,n)=>{let i=!0;let r;for(let o=0;o<e.length&&(r=e[o],i=i&&t.call(n,r,o,e),i);o++);return i};const c6=e=>{e.splice(0,e.length)};const d6=(e,t,n)=>{if(F4(e))throw new Error("First array is not specified.");if(F4(t))throw new Error("Second array is not specified.");if(e.length!==t.length)throw new Error("The two arrays should have equal length");const i=[];for(let n=0;n<e.length;n++)i.push({x:e[n],y:t[n]});F4(n)?i.sort(((e,t)=>e.x-t.x)):i.sort(((e,t)=>n(e.x,t.x))),c6(e),c6(t);for(let n=0;n<i.length;n++)e.push(i[n].x),t.push(i[n].y)};const h6=(e,t)=>{e.push(...t)};const u6=()=>{};const p6="string";const f6="function";const m6=function(){this._defaultPrevented=!0};const g6=function(){return!0===this._defaultPrevented};class v6{constructor(){this.options={},this.events=[],this._events={}}destroy(){this.unbind()}bind(e,t,n){if(!t&&O4(e)&&!Array.isArray(e)){for(const t in e)e[t]&&this.bind(t,e[t]);return this}const i=typeof e===p6?[e]:e,r=typeof t===f6;let o,a;for(let e=0,s=i.length;e<s;e++){const s=i[e];a=r?t:t[s],a&&(n&&(o=a,a=(...e)=>{this.unbind(s,a),o.apply(this,e)},a.original=o),this._events[s]=this._events[s]||[],this._events[s].push(a))}return this}one(e,t){return this.bind(e,t,!0)}first(e,t){const n=typeof e===p6?[String(e)]:Array.from(e),i=typeof t===f6;let r;for(let e=0,o=n.length;e<o;e++){const o=n[e];r=i?t:t[o],r&&(this._events[o]=this._events[o]||[],this._events[o].unshift(r))}return this}trigger(e,t){let n=this._events[e];if(n){const e=t||{};e.sender=this,e._defaultPrevented=!1,e.preventDefault=m6,e.isDefaultPrevented=g6,n=n.slice();for(let t=0,i=n.length;t<i;t++)n[t].call(this,e);return!0===e._defaultPrevented}return!1}unbind(e,t){const n=this._events[e];if(void 0===e)this._events={};else if(n)if(t)for(let e=n.length-1;e>=0;e--)n[e]!==t&&n[e].original!==t||n.splice(e,1);else this._events[e]=[];return this}_setEvents(e){const t=(this.events||[]).length;for(let n=0;n<t;n++){const t=this.events[n];this.options[t]&&e[t]&&(this.unbind(t,this.options[t]),this._events&&this._events[t]&&delete this._events[t])}this.bind(this.events,e)}}var _6=Object.freeze({__proto__:null,DFT:G4,Observable:v6,addRange:h6,all:l6,bisort:d6,clear:c6,contains:e6,defined:H4,deserializePoints:e=>{const t=e.split(";");const n=[];if(t.length%2!=0)throw new Error("Not an array of points.");for(let e=0;e<t.length;e+=2)n.push({x:parseInt(t[e],10),y:parseInt(t[e+1],10)});return n},find:o6,findAngle:Q4,findRadian:K4,first:a6,fold:r6,forEach:X4,getAny:Z4,getMatrixAngle:e=>null===e||0===e.d?0:180*Math.atan2(e.b,e.d)/Math.PI,getMatrixScaling:e=>[Math.sqrt(e.a*e.a+e.c*e.c),Math.sqrt(e.b*e.b+e.d*e.d)],grep:i6,has:V4,inArray:n6,indexOf:t6,initArray:j4,insert:s6,isBoolean:e=>"[object Boolean]"===Object.prototype.toString.call(e),isDefined:B4,isEmpty:U4,isFunction:R4,isNearZero:L4,isNumber:$4,isObject:O4,isString:N4,isType:(e,t)=>Object.prototype.toString.call(e)==="[object "+t+"]",isUndefined:F4,noop:u6,randomInteger:q4,remove:J4,serializePoints:e=>{const t=[];for(let n=0;n<e.length;n++){const i=e[n];t.push(i.x+";"+i.y)}return t.join(";")},sign:Y4,simpleExtend:W4});function b6(e,t,n){if(void 0===e||void 0===t)return[];if(n&&Y4(t-e)!==Y4(n))throw new Error("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 new Error("Infinite range defined.");const i=[];let r,o=-1;const a=function(e){let t=1;for(;e*t%1;)t*=10;return t}(Math.abs(n));if(n*=a,(e*=a)>(t*=a)&&n>0&&(n=-n),n<0)for(;(r=e+n*++o)>=t;)i.push(r/a);else for(;(r=e+n*++o)<=t;)i.push(r/a);return i}const w6={easeInOut:e=>-Math.cos(e*Math.PI)/2+.5};class y6{constructor(){this.adapters=[],this.target=0,this.tick=0,this.interval=20,this.duration=800,this.lastTime=null,this.handlers=[],this.timerDelegate=()=>{},this.intervalId=null,this.caller=null,this.timerDelegate=()=>{this.onTimerEvent()}}addAdapter(e){this.adapters.push(e)}onComplete(e){this.handlers.push(e)}removeHandler(e){this.handlers=this.handlers.filter((t=>t!==e))}trigger(){this.handlers&&X4(this.handlers,(e=>e.call(null!==this.caller?this.caller:this)))}onStep(){}seekTo(e){this.seekFromTo(this.tick,e)}seekFromTo(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(){this.intervalId&&(window.clearInterval(this.intervalId),this.intervalId=null,this.trigger())}play(e){0!==this.adapters.length&&(null!==e&&(this.caller=e),this.initState(),this.seekFromTo(0,1))}reverse(){this.seekFromTo(1,0)}initState(){if(0!==this.adapters.length)for(let e=0;e<this.adapters.length;e++)this.adapters[e].initState()}propagate(){const e=w6.easeInOut(this.tick);for(let t=0;t<this.adapters.length;t++)this.adapters[t].update(e)}onTimerEvent(){const e=(new Date).getTime();const t=e-this.lastTime;this.lastTime=e;const 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()}}}function k6(e){F4(e)&&(e=10);let t="";const n="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";for(let i=e;i>0;--i)t+=n.charAt(Math.round(61*Math.random()));return t}class x6{constructor(){this._buckets={},this.length=0,this._stringsMap=new Map,this._stringsCounter=0}add(e,t){const n=this._createGetBucket(e);return B4(t)&&(n.value=t),n}get(e){return this._bucketExists(e)?this._createGetBucket(e):null}set(e,t){this.add(e,t)}containsKey(e){return this._bucketExists(e)}remove(e){if(this._bucketExists(e)){const t=this._hash(e);return delete this._buckets[t],this.length--,e}}forEach(e){const t=this._hashes();for(let n=0,i=t.length;n<i;n++){const i=t[n];const r=this._buckets[i];F4(r)||e(r)}}clone(){const e=new x6;const t=this._hashes();for(let n=0,i=t.length;n<i;n++){const i=t[n];const r=this._buckets[i];F4(r)||e.add(r.key,r.value)}return e}_hashes(){const e=[];for(const t in this._buckets)Object.prototype.hasOwnProperty.call(this._buckets,t)&&e.push(t);return e}_bucketExists(e){const t=this._hash(e);return B4(this._buckets[t])}_createGetBucket(e){const t=this._hash(e);let n=this._buckets[t];return F4(n)&&(n={key:e},this._buckets[t]=n,this.length++),n}_hash(e){if(N4(e)||$4(e))return this._hashString(String(e));if(O4(e))return this._objectHashId(e);throw new Error("Unsupported key type.")}_hashString(e){let t=0;return 0===e.length?t:this._stringsMap.has(e)?this._stringsMap.get(e):(this._stringsCounter++,this._stringsMap.set(e,this._stringsCounter),t=this._stringsCounter,t)}_objectHashId(e){let t=e._hashId;return F4(t)&&(t=k6(),e._hashId=t),t}}class C6 extends v6{constructor(e){if(super(),this._hashTable=new x6,this.length=0,B4(e))if(Array.isArray(e))for(let t=0;t<e.length;t++)this.add(e[t]);else e.forEach((function(e,t){this.add(e,t)}),this)}add(e,t){let n=this._hashTable.get(e);n||(n=this._hashTable.add(e),this.length++,this.trigger("changed")),n.value=t}set(e,t){this.add(e,t)}get(e){const t=this._hashTable.get(e);if(t)return t.value;throw new Error("Cannot find key "+e)}containsKey(e){return this._hashTable.containsKey(e)}remove(e){if(this.containsKey(e))return this.trigger("changed"),this.length--,this._hashTable.remove(e)}forEach(e,t){this._hashTable.forEach((function(n){e.call(t,n.key,n.value)}))}forEachValue(e,t){this._hashTable.forEach((function(n){e.call(t,n.value)}))}forEachKey(e,t){this._hashTable.forEach((function(n){e.call(t,n.key)}))}keys(){const e=[];return this.forEachKey((function(t){e.push(t)})),e}}const S6={_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);const r=n.x-t.x,o=n.y-t.y;let 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,a<0?i(n,e):(a=(n.x-e.x)*o-(n.y-e.y)*r,a*a/(r*r+o*o)))},distanceToLine:function(e,t,n){return Math.sqrt(this._distanceToLineSquared(e,t,n))},distanceToPolyline:function(e,t){let n=Number.MAX_VALUE;if(F4(t)||0===t.length)return Number.MAX_VALUE;for(let i=0;i<t.length-1;i++){const r=t[i];const o=t[i+1];const a=this._distanceToLineSquared(e,r,o);a<n&&(n=a)}return Math.sqrt(n)}};class T6{constructor(e,t){this.r=e,this.angle=t}}class M6 extends ba{constructor(e,t){super(e,t)}clone(){return new M6(this.x,this.y)}plus(e){return new M6(this.x+e.x,this.y+e.y)}minus(e){return new M6(this.x-e.x,this.y-e.y)}offset(e){return new M6(this.x-e,this.y-e)}times(e){return new M6(this.x*e,this.y*e)}normalize(){return 0===this.length()?new M6: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 M6(t.x-e.x,t.y-e.y).times(.5).plus(e)}toPolar(e){let t=1;e&&(t=180/Math.PI);const n=Math.atan2(Math.abs(this.y),Math.abs(this.x));const i=Math.PI/2;const r=this.length();if(0===this.x){if(0===this.y)return new T6(0,0);if(this.y>0)return new T6(r,t*i);if(this.y<0)return new T6(r,3*t*i)}else if(this.x>0){if(0===this.y)return new T6(r,0);if(this.y>0)return new T6(r,t*n);if(this.y<0)return new T6(r,t*(4*i-n))}else{if(0===this.y)return new T6(r,2*i);if(this.y>0)return new T6(r,t*(2*i-n));if(this.y<0)return new T6(r,t*(2*i+n))}}isOnLine(e,t){if(e.x>t.x){const n=t;t=e,e=n}const n=new A6(e.x,e.y).inflate(3,3),i=new A6(t.x,t.y).inflate(3,3);let r,o;return!!n.union(i).contains(this)&&(e.x===t.x||e.y===t.y||(e.y<t.y?(r=n.x+(i.x-n.x)*(this.y-(n.y+n.height))/(i.y+i.height-(n.y+n.height)),o=n.x+n.width+(i.x+i.width-(n.x+n.width))*(this.y-n.y)/(i.y-n.y)):(r=n.x+(i.x-n.x)*(this.y-n.y)/(i.y-n.y),o=n.x+n.width+(i.x+i.width-(n.x+n.width))*(this.y-(n.y+n.height))/(i.y+i.height-(n.y+n.height))),this.x>r&&this.x<o))}parse(e){const 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 M6(n,i)}}class A6{constructor(e,t,n,i){this.x=e||0,this.y=t||0,this.width=n||0,this.height=i||0}contains(e){return e.x>=this.x&&e.x<=this.x+this.width&&e.y>=this.y&&e.y<=this.y+this.height}inflate(e,t){return void 0===t&&(t=e),this.x-=e,this.y-=t,this.width+=2*e+1,this.height+=2*t+1,this}offset(e,t){let n=e,i=t;return e instanceof M6&&(n=e.x,i=e.y),this.x+=n,this.y+=i,this}union(e){const t=Math.min(this.x,e.x);const n=Math.min(this.y,e.y);const i=Math.max(this.x+this.width,e.x+e.width);const r=Math.max(this.y+this.height,e.y+e.height);return new A6(t,n,i-t,r-n)}center(){return new M6(this.x+this.width/2,this.y+this.height/2)}top(){return new M6(this.x+this.width/2,this.y)}right(){return new M6(this.x+this.width,this.y+this.height/2)}bottom(){return new M6(this.x+this.width/2,this.y+this.height)}left(){return new M6(this.x,this.y+this.height/2)}topLeft(){return new M6(this.x,this.y)}topRight(){return new M6(this.x+this.width,this.y)}bottomLeft(){return new M6(this.x,this.y+this.height)}bottomRight(){return new M6(this.x+this.width,this.y+this.height)}clone(){return new A6(this.x,this.y,this.width,this.height)}isEmpty(){return!this.width&&!this.height}equals(e){return this.x===e.x&&this.y===e.y&&this.width===e.width&&this.height===e.height}rotatedBounds(e){const 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(e){const t=this.center(),n=this.bottomRight().rotate(e,t);return[this.topLeft().rotate(e,t),this.topRight().rotate(e,t),n,this.bottomLeft().rotate(e,t)]}toString(e){return e=e||" ",this.x+e+this.y+e+this.width+e+this.height}scale(e,t,n,i,r){let o=this.topLeft();const a=this.center();o.rotate(r,a).rotate(r,i);const s=n.minus(o);const l=new M6(s.x*e,s.y*t);const c=s.minus(l);o=o.plus(c),o.rotate(r,i).rotate(r,a),this.x=o.x,this.y=o.y,this.width*=e,this.height*=t}zoom(e){return this.x*=e,this.y*=e,this.width*=e,this.height*=e,this}overlaps(e){const t=this.bottomRight();const n=e.bottomRight();return!(t.x<e.x||t.y<e.y||n.x<this.x||n.y<this.y)}static toRect(e){return e instanceof A6||(e=new A6(e.x,e.y,e.width,e.height)),e}static empty(){return new A6(0,0,0,0)}static fromPoints(e,t){if(isNaN(e.x)||isNaN(e.y)||isNaN(t.x)||isNaN(t.y))throw new Error("Some values are NaN.");return new A6(Math.min(e.x,t.x),Math.min(e.y,t.y),Math.abs(e.x-t.x),Math.abs(e.y-t.y))}}class D6{constructor(e){this.container=A6.toRect(e)}align(e,t){const n=t.toLowerCase().split(" ");for(let t=0;t<n.length;t++)e=this._singleAlign(e,n[t]);return e}_singleAlign(e,t){return R4(this[t])?this[t](e):e}left(e){return this._align(e,this._left)}center(e){return this._align(e,this._center)}right(e){return this._align(e,this._right)}stretch(e){return this._align(e,this._stretch)}top(e){return this._align(e,this._top)}middle(e){return this._align(e,this._middle)}bottom(e){return this._align(e,this._bottom)}_left(e,t){t.x=e.x}_center(e,t){t.x=(e.width-t.width)/2||0}_right(e,t){t.x=e.width-t.width}_top(e,t){t.y=e.y}_middle(e,t){t.y=(e.height-t.height)/2||0}_bottom(e,t){t.y=e.height-t.height}_stretch(e,t){t.x=0,t.y=0,t.height=e.height,t.width=e.width}_align(e,t){return e=A6.toRect(e),t(this.container,e),e}}class E6{constructor(){this._tail=null,this._head=null,this.length=0}enqueue(e){const 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(){if(this.length<1)throw new Error("The queue is empty.");const e=this._head.value;return this._head=this._head.next,this.length--,e}contains(e){let t=this._head;for(;t;){if(t.value===e)return!0;t=t.next}return!1}}const I6="object";function z6(e,t){for(const n in t){if("__proto__"===n||"constructor"===n)continue;const i=t[n];const r=typeof i;let o;if(o=r===I6&&null!==i?i.constructor:null,o&&o!==Array)if(i instanceof Date)e[n]=new Date(i.getTime());else if("function"==typeof i.clone)e[n]=i.clone();else{const t=e[n];e[n]=typeof t===I6&&t||{},z6(e[n],i)}else"undefined"!==r&&(e[n]=i)}return e}function P6(e,...t){const n=t.length;for(let i=0;i<n;i++)z6(e,t[i]);return e}const L6={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};class B6{constructor(){this.defaultOptions={...L6,grid:{...L6.grid}}}gridLayoutComponents(e){if(!e)throw new Error("No components supplied.");X4(e,(function(e){e.calcBounds()})),e.sort((function(e,t){return t.bounds.width-e.bounds.width}));const t=this.options.grid.width,n=this.options.grid.componentSpacingX,i=this.options.grid.componentSpacingY,r=this.options.grid.offsetX,o=[],a=[];let s=0,l=r,c=this.options.grid.offsetY;for(;e.length>0;){l>=t&&(l=r,c+=s+i,s=0);const d=e.pop();this.moveToOffset(d,new M6(l,c));for(let e=0;e<d.nodes.length;e++)a.push(d.nodes[e]);for(let e=0;e<d.links.length;e++)o.push(d.links[e]);const h=d.bounds;let u=h.height;(u<=0||isNaN(u))&&(u=0);let p=h.width;(p<=0||isNaN(p))&&(p=0),u>=s&&(s=u),l+=p+n}return{nodes:a,links:o}}moveToOffset(e,t){let n,i;const r=e.bounds,o=t.x-r.x,a=t.y-r.y;for(n=0;n<e.nodes.length;n++){const t=e.nodes[n];let i=t.bounds();0===i.width&&0===i.height&&0===i.x&&0===i.y&&(i=new A6(0,0,0,0)),i.x+=o,i.y+=a,t.bounds(i)}for(n=0;n<e.links.length;n++){const t=e.links[n];if(t.points){const e=[];const n=t.points;for(i=0;i<n.length;i++){const t=n[i];t.x+=o,t.y+=a,e.push(t)}t.points=e}}return this.currentHorizontalOffset+=r.width+this.options.grid.offsetX,new M6(o,a)}transferOptions(e){this.options=P6({},this.defaultOptions),F4(e)||(this.options=P6(this.options,e||{}))}}class H6{constructor(e,t){if(F4(e))throw new Error("No diagram given");this.diagram=e,this.nodeMap=new C6,this.linkMap=new C6,this.capture(t||e)}capture(e){let t,n,i,r,o,a,s;if(e&&"Graph"===e.type){for(r=0;r<e.nodes.length;r++)t=e.nodes[r],i=t.associatedShape,this.nodeMap.set(i.visual.id,new A6(t.x,t.y,t.width,t.height));for(r=0;r<e.links.length;r++)a=e.links[r],o=a.associatedConnection,this.linkMap.set(o.visual.id,a.points())}else if(e instanceof Array)for(n=e,r=0;r<n.length;r++)t=n[r],i=t.associatedShape,i&&this.nodeMap.set(i.visual.id,new A6(t.x,t.y,t.width,t.height));else if(Object.prototype.hasOwnProperty.call(e,"links")&&Object.prototype.hasOwnProperty.call(e,"nodes")){for(n=e.nodes,s=e.links,r=0;r<n.length;r++)t=n[r],i=t.associatedShape,i&&this.nodeMap.set(i.visual.id,new A6(t.x,t.y,t.width,t.height));for(r=0;r<s.length;r++)a=s[r],o=a.associatedConnection,o&&this.linkMap.set(o.visual.id,a.points)}else{const e=this.diagram.shapes;const t=this.diagram.connections;for(r=0;r<e.length;r++)i=e[r],this.nodeMap.set(i.visual.id,i.bounds());for(r=0;r<t.length;r++)o=t[r],this.linkMap.set(o.visual.id,o.points())}}}let R6=class e{constructor(e,t){if(this.links=[],this.outgoing=[],this.incoming=[],this.weight=1,this.data=null,this.type="Node",this.isVirtual=!1,B4(e)?this.id=e:this.id=k6(),B4(t)){this.associatedShape=t;const e=t.bounds();this.width=e.width,this.height=e.height,this.x=e.x,this.y=e.y}else this.associatedShape=null;this.shortForm="Node '"+this.id+"'"}isIsolated(){return U4(this.links)}bounds(e){if(!B4(e))return new A6(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(e){return Z4(this.links,(t=>t.getComplement(this)===e))}getChildren(){if(0===this.outgoing.length)return[];const e=[];for(let t=0,n=this.outgoing.length;t<n;t++){const n=this.outgoing[t];e.push(n.getComplement(this))}return e}getParents(){if(0===this.incoming.length)return[];const e=[];for(let t=0,n=this.incoming.length;t<n;t++){const n=this.incoming[t];e.push(n.getComplement(this))}return e}clone(){const t=new e;return B4(this.weight)&&(t.weight=this.weight),B4(this.balance)&&(t.balance=this.balance),B4(this.owner)&&(t.owner=this.owner),t.associatedShape=this.associatedShape,t.x=this.x,t.y=this.y,t.width=this.width,t.height=this.height,t}adjacentTo(e){return null!==this.isLinkedTo(e)}removeLink(e){e.source===this&&(J4(this.links,e),J4(this.outgoing,e),e.source=null),e.target===this&&(J4(this.links,e),J4(this.incoming,e),e.target=null)}hasLinkTo(e){return Z4(this.outgoing,(function(t){return t.target===e}))}degree(){return this.links.length}incidentWith(e){return e6(this.links,e)}getLinksWith(e){return l6(this.links,(function(t){return t.getComplement(this)===e}),this)}getNeighbors(){const e=[];return X4(this.incoming,(function(t){e.push(t.getComplement(this))}),this),X4(this.outgoing,(function(t){e.push(t.getComplement(this))}),this),e}};class F6{constructor(e,t,n,i){if(F4(e))throw new Error("The source of the new link is not set.");if(F4(t))throw new Error("The target of the new link is not set.");let r,o;r=N4(e)?new R6(e):e,o=N4(t)?new R6(t):t,this.source=r,this.target=o,this.source.links.push(this),this.target.links.push(this),this.source.outgoing.push(this),this.target.incoming.push(this),B4(n)?this.id=n:this.id=k6(),B4(i)?this.associatedConnection=i:this.associatedConnection=null,this.type="Link",this.shortForm="Link '"+this.source.id+"->"+this.target.id+"'"}getComplement(e){if(this.source!==e&&this.target!==e)throw new Error("The given node is not incident with this link.");return this.source===e?this.target:this.source}getCommonNode(e){return this.source===e.source||this.source===e.target?this.source:this.target===e.source||this.target===e.target?this.target:null}isBridging(e,t){return this.source===e&&this.target===t||this.source===t&&this.target===e}getNodes(){return[this.source,this.target]}incidentWith(e){return this.source===e||this.target===e}adjacentTo(e){return e6(this.source.links,e)||e6(this.target.links,e)}changeSource(e){J4(this.source.links,this),J4(this.source.outgoing,this),e.links.push(this),e.outgoing.push(this),this.source=e}changeTarget(e){J4(this.target.links,this),J4(this.target.incoming,this),e.links.push(this),e.incoming.push(this),this.target=e}changesNodes(e,t){this.source===e?this.changeSource(t):this.target===e&&this.changeTarget(t)}reverse(){const e=this.source;const t=this.target;return this.source=t,J4(e.outgoing,this),this.source.outgoing.push(this),this.target=e,J4(t.incoming,this),this.target.incoming.push(this),this}directTo(e){if(this.source!==e&&this.target!==e)throw new Error("The given node is not incident with this link.");this.target!==e&&this.reverse()}createReverseEdge(){const e=this.clone();return e.reverse(),e.reversed=!0,e}clone(){return new F6(this.source,this.target)}}class O6{constructor(e){this.links=[],this.nodes=[],this._nodeMap=new C6,this.diagram=null,this._root=null,this.bounds=new A6,this._hasCachedRelationships=!1,this.type="Graph",this.componentIndex=0,B4(e)?N4(e)?this.id=e:(this.diagram=e,this.id=e.id):this.id=k6()}cacheRelationships(e){if(F4(e)&&(e=!1),!this._hasCachedRelationships||e){for(let e=0,t=this.nodes.length;e<t;e++){const t=this.nodes[e];t.children=this.getChildren(t),t.parents=this.getParents(t)}this._hasCachedRelationships=!0}}assignLevels(e,t,n){if(!e)throw new Error("Start node not specified.");F4(t)&&(t=0),this.cacheRelationships(),F4(n)&&(n=new C6,X4(this.nodes,(function(e){n.add(e,!1)}))),n.set(e,!0),e.level=t;const i=e.children;for(let e=0,r=i.length;e<r;e++){const r=i[e];r&&!n.get(r)&&this.assignLevels(r,t+1,n)}}root(e){if(F4(e)){if(this._root)return this._root;{const e=a6(this.nodes,(function(e){return 0===e.incoming.length}));return e||a6(this.nodes)}}this._root=e}getConnectedComponents(){this.componentIndex=0,this.setItemIndices();const e=j4(this.nodes.length,-1);for(let t=0;t<this.nodes.length;t++)-1===e[t]&&(this._collectConnectedNodes(e,t),this.componentIndex++);const t=[];let n;for(n=0;n<this.componentIndex;++n)t[n]=new O6;for(n=0;n<e.length;++n){t[e[n]].addNodeAndOutgoings(this.nodes[n])}return t.sort((function(e,t){return t.nodes.length-e.nodes.length})),t}_collectConnectedNodes(e,t){e[t]=this.componentIndex;const n=this.nodes[t];X4(n.links,(function(t){const i=t.getComplement(n).index;-1===e[i]&&this._collectConnectedNodes(e,i)}),this)}calcBounds(){if(this.isEmpty())return this.bounds=new A6,this.bounds;let e=null;for(let t=0,n=this.nodes.length;t<n;t++){const n=this.nodes[t];e=e?e.union(n.bounds()):n.bounds()}return this.bounds=e,this.bounds}getSpanningTree(e){const t=new O6;const n=new C6;let i,r;const o=e.clone();t.root(o),o.level=0,o.id=e.id,n.add(e,t.root()),e.level=0;const a=[];const s=[];t._addNode(t.root()),a.push(e),s.push(e);let l=1;for(;s.length>0;){const e=s.pop();for(let o=0;o<e.links.length;o++){const c=e.links[o].getComplement(e);if(e6(a,c))continue;c.level=e.level+1,l<c.level+1&&(l=c.level+1),e6(s,c)||s.push(c),e6(a,c)||a.push(c),n.containsKey(e)?i=n.get(e):(i=e.clone(),i.level=e.level,i.id=e.id,n.add(e,i)),n.containsKey(c)?r=n.get(c):(r=c.clone(),r.level=c.level,r.id=c.id,n.add(c,r));const d=new F6(i,r);t.addLink(d)}}const c=[];for(let e=0;e<l;e++)c.push([]);return X4(t.nodes,(function(e){c[e.level].push(e)})),t.treeLevels=c,t.cacheRelationships(),t}takeRandomNode(e,t){if(F4(e)&&(e=[]),F4(t)&&(t=4),0===this.nodes.length)return null;if(1===this.nodes.length)return e6(e,this.nodes[0])?null:this.nodes[0];const n=this.nodes.filter((function(n){return!e6(e,n)&&n.degree()<=t}));return U4(n)?null:n[q4(0,n.length)]}isEmpty(){return U4(this.nodes)}isHealthy(){return l6(this.links,(function(e){return e6(this.nodes,e.source)&&e6(this.nodes,e.target)}),this)}getParents(e){if(!this.hasNode(e))throw new Error("The given node is not part of this graph.");return e.getParents()}getChildren(e){if(!this.hasNode(e))throw new Error("The given node is not part of this graph.");return e.getChildren()}addLink(e,t,n){if(F4(e))throw new Error("The source of the link is not defined.");if(F4(t)){if(B4(e.type)&&"Link"===e.type)return void this.addExistingLink(e);throw new Error("The target of the link is not defined.")}let i=this.getNode(e);F4(i)&&(i=this.addNode(e));let r=this.getNode(t);F4(r)&&(r=this.addNode(t));const o=new F6(i,r);return B4(n)&&(o.owner=n),this.links.push(o),o}removeAllLinks(){for(;this.links.length>0;){const e=this.links[0];this.removeLink(e)}}addExistingLink(e){if(!this.hasLink(e)){if(this.links.push(e),this.hasNode(e.source.id)){const t=this.getNode(e.source.id);e.changeSource(t)}else this.addNode(e.source);if(this.hasNode(e.target.id)){const t=this.getNode(e.target.id);e.changeTarget(t)}else this.addNode(e.target)}}hasLink(e){if(N4(e))return Z4(this.links,(function(t){return t.id===e}));if("Link"===e.type)return e6(this.links,e);throw new Error("The given object is neither an identifier nor a Link.")}getNode(e){const t=e.id||e;if(this._nodeMap.containsKey(t))return this._nodeMap.get(t)}hasNode(e){const t=e.id||e;return this._nodeMap.containsKey(t)}_addNode(e){this.nodes.push(e),this._nodeMap.add(e.id,e)}_removeNode(e){J4(this.nodes,e),this._nodeMap.remove(e.id)}removeNode(e){let t=e;if(N4(e)&&(t=this.getNode(e)),!B4(t))throw new Error("The identifier should be a Node or the Id (string) of a node.");{const e=t.links;t.links=[];for(let t=0,n=e.length;t<n;t++){const n=e[t];this.removeLink(n)}this._removeNode(t)}}areConnected(e,t){return Z4(this.links,(function(n){return n.source===e&&n.target===t||n.source===t&&n.target===e}))}removeLink(e){J4(this.links,e),J4(e.source.outgoing,e),J4(e.source.links,e),J4(e.target.incoming,e),J4(e.target.links,e)}addNode(e,t,n){let i=null;if(!B4(e))throw new Error("No Node or identifier for a new Node is given.");if(N4(e)){if(this.hasNode(e))return this.getNode(e);i=new R6(e)}else{if(this.hasNode(e))return this.getNode(e);i=e}return B4(t)&&i.bounds(t),B4(n)&&(i.owner=n),this._addNode(i),i}addNodeAndOutgoings(e){this.hasNode(e)||this._addNode(e);const t=e.outgoing;e.outgoing=[],X4(t,(function(e){this.addExistingLink(e)}),this)}setItemIndices(){let 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(e){const t=new O6;const n=B4(e)&&!0===e;n&&(t.nodeMap=new C6,t.linkMap=new C6);const i=new C6;return X4(this.nodes,(function(e){const r=e.clone();i.set(e,r),t._addNode(r),n&&t.nodeMap.set(r,e)})),X4(this.links,(function(e){if(i.containsKey(e.source)&&i.containsKey(e.target)){const r=t.addLink(i.get(e.source),i.get(e.target));n&&t.linkMap.set(r,e)}})),t}linearize(e){return O6.Utils.linearize(this,e)}depthFirstTraversal(e,t){if(F4(e))throw new Error("You need to supply a starting node.");if(F4(t))throw new Error("You need to supply an action.");if(!this.hasNode(e))throw new Error("The given start-node is not part of this graph");const n=this.getNode(e);this._dftIterator(n,t,[])}_dftIterator(e,t,n){t(e),n.push(e);const i=e.getChildren();for(let e=0,r=i.length;e<r;e++){const r=i[e];e6(n,r)||this._dftIterator(r,t,n)}}breadthFirstTraversal(e,t){if(F4(e))throw new Error("You need to supply a starting node.");if(F4(t))throw new Error("You need to supply an action.");if(!this.hasNode(e))throw new Error("The given start-node is not part of this graph");const n=this.getNode(e);const i=new E6;const r=[];for(i.enqueue(n);i.length>0;){const e=i.dequeue();t(e),r.push(e);const n=e.getChildren();for(let e=0,t=n.length;e<t;e++){const t=n[e];e6(r,t)||i.contains(t)||i.enqueue(t)}}}_stronglyConnectedComponents(e,t,n,i,r,o,a){n.add(t,a),i.add(t,a),a++,o.push(t);const s=t.getChildren();let l;for(let c=0,d=s.length;c<d;c++)l=s[c],n.containsKey(l)?e6(o,l)&&i.add(t,Math.min(i.get(t),n.get(l))):(this._stronglyConnectedComponents(e,l,n,i,r,o,a),i.add(t,Math.min(i.get(t),i.get(l))));if(i.get(t)===n.get(t)){const n=[];do{l=o.pop(),n.push(l)}while(l!==t);(!e||n.length>1)&&r.push(n)}}findCycles(e){F4(e)&&(e=!0);const t=new C6;const n=new C6;const i=[];const r=[];for(let o=0,a=this.nodes.length;o<a;o++){const a=this.nodes[o];t.containsKey(a)||this._stronglyConnectedComponents(e,a,t,n,i,r,0)}return i}isAcyclic(){return U4(this.findCycles())}isSubGraph(e){const t=e.linearize();const n=this.linearize();return l6(t,(function(e){return e6(n,e)}))}makeAcyclic(){if(this.isEmpty()||this.nodes.length<=1||this.links.length<=1)return[];if(2===this.nodes.length){const e=[];if(this.links.length>1){const t=this.links[0].source;for(let n=0,i=this.links.length;n<i;n++){const i=this.links[n];if(i.source===t)continue;const r=i.reverse();e.push(r)}}return e}const e=this.clone(!0);const t=this.nodes.length;const n=new C6;const i=function(e){return 0===e.outgoing.length?2-t:0===e.incoming.length?t-2:e.outgoing.length-e.incoming.length};const r=function(e){const t=i(e);n.containsKey(t)||n.set(t,[]),n.get(t).push(e)};X4(e.nodes,(function(e){r(e)}));let o=[];const a=[];for(;e.nodes.length>0;){let s,l,c;if(n.containsKey(2-t)){const o=n.get(2-t);for(;o.length>0;){l=o.pop();for(let e=0;e<l.links.length;e++){const t=l.links[e];s=t.getComplement(l),c=i(s),J4(n.get(c),s),s.removeLink(t),r(s)}e._removeNode(l),a.unshift(l)}}if(n.containsKey(t-2)){const a=n.get(t-2);for(;a.length>0;){s=a.pop();for(let e=0;e<s.links.length;e++){const t=s.links[e];l=t.getComplement(s),c=i(l),J4(n.get(c),l),l.removeLink(t),r(l)}o.push(s),e._removeNode(s)}}if(e.nodes.length>0)for(let a=t-3;a>2-t;a--)if(n.containsKey(a)&&n.get(a).length>0){const t=n.get(a).pop();for(let e=0;e<t.links.length;e++){const o=t.links[e];const a=o.getComplement(t);c=i(a),J4(n.get(c),a),a.removeLink(o),r(a)}o.push(t),e._removeNode(t);break}}o=o.concat(a);const s=new C6;for(let t=0;t<this.nodes.length;t++)s.set(e.nodeMap.get(o[t]),t);const l=[];return X4(this.links,(function(e){s.get(e.source)>s.get(e.target)&&(e.reverse(),l.push(e))})),l}}O6.Predefined={EightGraph:()=>O6.Utils.parse(["1->2","2->3","3->4","4->1","3->5","5->6","6->7","7->3"]),Mindmap:()=>O6.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:()=>O6.Utils.parse(["1->2","2->3","3->1"]),BinaryTree:e=>(F4(e)&&(e=5),O6.Utils.createBalancedTree(e,2)),Linear:e=>(F4(e)&&(e=10),O6.Utils.createBalancedTree(e,1)),Tree:(e,t)=>O6.Utils.createBalancedTree(e,t),Forest:(e,t,n)=>O6.Utils.createBalancedForest(e,t,n),Workflow:()=>O6.Utils.parse(["0->1","1->2","2->3","1->4","4->3","3->5","5->6","6->3","6->7","5->4"]),Grid(e,t){const n=new O6;if(e<=0&&t<=0)return n;for(let i=0;i<e+1;i++){let e=null;for(let r=0;r<t+1;r++){const t=new R6(i.toString()+"."+r.toString());if(n.addNode(t),e&&n.addLink(e,t),i>0){const e=n.getNode((i-1).toString()+"."+r.toString());n.addLink(e,t)}e=t}}return n}},O6.Utils={parse(e){let t;const n=new O6,i=e.slice();for(let e=0,r=i.length;e<r;e++){const r=i[e];if(N4(r)){if(r.indexOf("->")<0)throw new Error("The link should be specified as 'a->b'.");const e=r.split("->");if(2!==e.length)throw new Error("The link should be specified as 'a->b'.");t=new F6(e[0],e[1]),n.addLink(t)}if(O4(r)){if(!t)throw new Error("Specification found before Link definition.");P6(t,r)}}return n},linearize(e,t){if(F4(e))throw new Error("Expected an instance of a Graph object in slot one.");F4(t)&&(t=!1);const n=[];for(let i=0,r=e.links.length;i<r;i++){const r=e.links[i];n.push(r.source.id+"->"+r.target.id),t&&n.push({id:r.id})}return n},_addShape:(e,t,n,i)=>(F4(t)&&(t=new M6(0,0)),F4(n)&&(n=k6()),i=P6({width:20,height:20,id:n,radius:10,fill:"#778899",data:"circle",undoable:!1,x:t.x,y:t.y},i),e.addShape(i)),_addConnection:(e,t,n,i)=>e.connect(t,n,i),createDiagramFromGraph(e,t,n,i){if(F4(e))throw new Error("The diagram surface is undefined.");if(F4(t))throw new Error("No graph specification defined.");F4(n)&&(n=!0),F4(i)&&(i=!1);const r=e.element.clientWidth||200;const o=e.element.clientHeight||200;const a=[];let s,l;for(let n=0,c=t.nodes.length;n<c;n++){s=t.nodes[n];let c=s.position;F4(c)&&(c=B4(s.x)&&B4(s.y)?new M6(s.x,s.y):new M6(q4(10,r-20),q4(10,o-20)));const d={};"0"===s.id||i&&P6(d,{width:150*Math.random()+20,height:80*Math.random()+50,data:"rectangle",fill:{color:"#778899"}}),l=this._addShape(e,c,s.id,d);const h=l.bounds();B4(h)&&(s.x=h.x,s.y=h.y,s.width=h.width,s.height=h.height),a[s.id]=l}for(let n=0;n<t.links.length;n++){const i=t.links[n];const r=a[i.source.id];if(F4(r))continue;const o=a[i.target.id];F4(o)||this._addConnection(e,r,o,{id:i.id})}if(n){new V6(e).layoutGraph(t,{limitToView:!1});for(let e=0;e<t.nodes.length;e++)s=t.nodes[e],l=a[s.id],l.bounds(new A6(s.x,s.y,s.width,s.height))}},createBalancedTree(e,t){F4(e)&&(e=3),F4(t)&&(t=3);const n=new O6;let i,r=-1,o=[];if(e<=0||t<=0)return n;const a=new R6((++r).toString());n.addNode(a),n.root(a),o.push(a);for(let a=0;a<e;a++){i=[];for(let e=0;e<o.length;e++){const a=o[e];for(let e=0;e<t;e++){const e=new R6((++r).toString());n.addLink(a,e),i.push(e)}}o=i}return n},createBalancedForest(e,t,n){F4(e)&&(e=3),F4(t)&&(t=3),F4(n)&&(n=5);const i=new O6;let r,o=-1,a=[];if(e<=0||t<=0||n<=0)return i;for(let s=0;s<n;s++){const n=new R6((++o).toString());i.addNode(n),a=[n];for(let n=0;n<e;n++){r=[];for(let e=0;e<a.length;e++){const n=a[e];for(let e=0;e<t;e++){const e=new R6((++o).toString());i.addLink(n,e),r.push(e)}}a=r}}return i},createRandomConnectedGraph(e,t,n){F4(e)&&(e=40),F4(t)&&(t=4),F4(n)&&(n=!1);const i=new O6;let r=-1;if(e<=0)return i;const o=new R6((++r).toString());if(i.addNode(o),1===e)return i;if(e>1){for(let n=1;n<e;n++){const e=i.takeRandomNode([],t);if(!e)break;const r=i.addNode(n.toString());i.addLink(e,r)}if(!n&&e>1){const n=q4(1,e);for(let e=0;e<n;e++){const e=i.takeRandomNode([],t);const n=i.takeRandomNode([],t);e&&n&&!i.areConnected(e,n)&&i.addLink(e,n)}}return i}},randomDiagram(e,t,n,i,r){const o=O6.Utils.createRandomConnectedGraph(t,n,i);O6.Utils.createDiagramFromGraph(e,o,!1,r)}};class V6 extends B6{constructor(e){if(super(),F4(e))throw new Error("Diagram is not specified.");this.diagram=e}layout(e){this.transferOptions(e);const t=new N6(this.diagram).convert(e);if(t.isEmpty())return;const n=t.getConnectedComponents();if(U4(n))return;for(let t=0;t<n.length;t++){const i=n[t];this.layoutGraph(i,e)}const i=this.gridLayoutComponents(n);return new H6(this.diagram,i)}layoutGraph(e,t){B4(t)&&this.transferOptions(t),this.graph=e;const n=9*this.options.nodeDistance;this.temperature=n;const i=this._expectedBounds();this.width=i.width,this.height=i.height;for(let e=0;e<this.options.iterations;e++)this.refineStage=e>=5*this.options.iterations/6,this.tick(),this.temperature=this.refineStage?n/30:n*(1-e/(2*this.options.iterations))}tick(){let 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++){const t=this.graph.nodes[e];const 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(e){const t=Math.random()*this.options.nodeDistance/4;const n=2*Math.random()*Math.PI;e.x+=t*Math.cos(n),e.y-=t*Math.sin(n)}_InverseSquareForce(e,t,n){let i;if(this.refineStage){const e=t.x-n.x;const r=t.y-n.y;const o=t.width/2;const a=t.height/2;const s=n.width/2;const l=n.height/2;i=Math.pow(e,2)/Math.pow(o+s+this.options.nodeDistance,2)+Math.pow(r,2)/Math.pow(a+l+this.options.nodeDistance,2)}else i=Math.pow(e,2)/Math.pow(this.options.nodeDistance,2);return 4*i/3}_SquareForce(e,t,n){return 1/this._InverseSquareForce(e,t,n)}_repulsion(e){e.dx=0,e.dy=0,X4(this.graph.nodes,(function(t){if(t===e)return;for(;e.x===t.x&&e.y===t.y;)this._shake(t);const n=e.x-t.x;const i=e.y-t.y;const r=Math.sqrt(n*n+i*i);const o=2*this._SquareForce(r,e,t);e.dx+=n/r*o,e.dy+=i/r*o}),this)}_attraction(e){const t=e.target;const n=e.source;if(n===t)return;for(;n.x===t.x&&n.y===t.y;)this._shake(t);const i=n.x-t.x;const r=n.y-t.y;const o=Math.sqrt(i*i+r*r);const a=5*this._InverseSquareForce(o,n,t);const s=i/o*a;const l=r/o*a;t.dx+=s,t.dy+=l,n.dx-=s,n.dy-=l}_expectedBounds(){const e=this.graph.nodes.length;if(0===e)return;const t=r6(this.graph.nodes,(function(e,t){const n=t.width*t.height;return n>0?e+=Math.sqrt(n):0}),0,this)/e*Math.ceil(Math.sqrt(e));return{width:4*(t*Math.sqrt(1.5)),height:4*(t/Math.sqrt(1.5))}}}class N6{constructor(e){this.nodeMap=new C6,this.shapeMap=new C6,this.nodes=[],this.edges=[],this.edgeMap=new C6,this.finalNodes=[],this.finalLinks=[],this.ignoredConnections=[],this.ignoredShapes=[],this.hyperMap=new C6,this.hyperTree=new O6,this.finalGraph=null,this.diagram=e}convert(e){if(F4(this.diagram))throw new Error("No diagram to convert.");return this.options=P6({ignoreInvisible:!0,ignoreContainers:!0,layoutContainerChildren:!1},e||{}),this.clear(),this._renormalizeShapes(),this._renormalizeConnections(),this.finalNodes=new C6(this.nodes),this.finalLinks=new C6(this.edges),this.finalGraph=new O6,this.finalNodes.forEach((function(e){this.finalGraph.addNode(e)}),this),this.finalLinks.forEach((function(e){this.finalGraph.addExistingLink(e)}),this),this.finalGraph}mapConnection(e){return this.edgeMap.get(e.id)}mapShape(e){return this.nodeMap.get(e.id)}getEdge(e,t){return a6(e.links,(function(n){return n.getComplement(e)===t}))}clear(){this.finalGraph=null,this.hyperTree=!this.options.ignoreContainers&&this.options.layoutContainerChildren?new O6:null,this.hyperMap=!this.options.ignoreContainers&&this.options.layoutContainerChildren?new C6:null,this.nodeMap=new C6,this.shapeMap=new C6,this.nodes=[],this.edges=[],this.edgeMap=new C6,this.ignoredConnections=[],this.ignoredShapes=[],this.finalNodes=[],this.finalLinks=[]}listToRoot(e){const t=[];let n=e.container;if(!n)return t;for(t.push(n);n.parentContainer;)n=n.parentContainer,t.push(n);return t.reverse(),t}firstNonIgnorableContainer(e){return e.isContainer&&!this.isIgnorableItem(e)?e:e.parentContainer?this.firstNonIgnorableContainer(e.parentContainer):null}isContainerConnection(e,t){return!(!e.isContainer||!this.isDescendantOf(e,t))||t.isContainer&&this.isDescendantOf(t,e)}isDescendantOf(e,t){if(!e.isContainer)throw new Error("Expecting a container.");if(e===t)return!1;if(e6(e.children,t))return!0;const n=[];for(let i=0,r=e.children.length;i<r;i++){const r=e.children[i];r.isContainer&&this.isDescendantOf(r,t)&&n.push(r)}return n.length>0}isIgnorableItem(e){return this.options.ignoreInvisible?(!e.isCollapsed||!this._isVisible(e))&&!(!e.isCollapsed&&this._isVisible(e)):e.isCollapsed&&!this._isTop(e)}isShapeMapped(e){return e.isCollapsed&&!this._isVisible(e)&&!this._isTop(e)}leastCommonAncestor(e,t){if(!e)throw new Error("Parameter should not be null.");if(!t)throw new Error("Parameter should not be null.");if(!this.hyperTree)throw new Error("No hypertree available.");const n=this.listToRoot(e);const i=this.listToRoot(t);let r=null;if(U4(n)||U4(i))return this.hyperTree.root().data;let o=n[0];let a=i[0];let s=0;for(;o===a&&(r=n[s],s++,!(s>=n.length||s>=i.length));)o=n[s],a=i[s];return r?this.hyperTree.nodes.filter((function(e){return e.data.container===r})):this.hyperTree.root().data}_isTop(e){return!e.parentContainer}_isVisible(e){return!!e.visible()&&(e.parentContainer?this._isVisible(e.parentContainer):e.visible())}_isCollapsed(e){return!(!e.isContainer||!e.isCollapsed)||e.parentContainer&&this._isCollapsed(e.parentContainer)}_renormalizeShapes(){if(!this.options.ignoreContainers)throw new Error("Containers are not supported yet, but stay tuned.");for(let e=0,t=this.diagram.shapes.length;e<t;e++){const t=this.diagram.shapes[e];if(this.options.ignoreInvisible&&!this._isVisible(t)||t.isContainer){this.ignoredShapes.push(t);continue}const n=new R6(t.id,t);n.isVirtual=!1,this.nodeMap.add(t.id,n),this.nodes.push(n)}}_renormalizeConnections(){if(0!==this.diagram.connections.length)for(let e=0,t=this.diagram.connections.length;e<t;e++){const t=this.diagram.connections[e];if(this.isIgnorableItem(t)){this.ignoredConnections.push(t);continue}let n=t.sourceConnector?t.sourceConnector.shape:null;let i=t.targetConnector?t.targetConnector.shape:null;if(!n||!i){this.ignoredConnections.push(t);continue}if(e6(this.ignoredShapes,n)&&!this.shapeMap.containsKey(n)){this.ignoredConnections.push(t);continue}if(e6(this.ignoredShapes,i)&&!this.shapeMap.containsKey(i)){this.ignoredConnections.push(t);continue}this.shapeMap.containsKey(n)&&(n=this.shapeMap[n]),this.shapeMap.containsKey(i)&&(i=this.shapeMap[i]);const r=this.mapShape(n);const o=this.mapShape(i);if(r===o||this.areConnectedAlready(r,o))this.ignoredConnections.push(t);else{if(null===r||null===o)throw new Error("A shape was not mapped to a node.");if(!this.options.ignoreContainers)throw new Error("Containers are not supported yet, but stay tuned.");{if(r.isVirtual||o.isVirtual){this.ignoredConnections.push(t);continue}const e=new F6(r,o,t.id,t);this.edgeMap.add(t.id,e),this.edges.push(e)}}}}areConnectedAlready(e,t){return Z4(this.edges,(function(n){return n.source===e&&n.target===t||n.source===t&&n.target===e}))}}function $6(e,t,n,i,r){const o=(t.x-e.x)*(i.y-n.y)-(t.y-e.y)*(i.x-n.x);if(L4(o))return;const a=((e.y-n.y)*(i.x-n.x)-(e.x-n.x)*(i.y-n.y))/o;const s=((e.y-n.y)*(t.x-e.x)-(e.x-n.x)*(t.y-e.y))/o;return r&&(a<0||a>1||s<0||s>1)?void 0:new M6(e.x+a*(t.x-e.x),e.y+a*(t.y-e.y))}const U6={lines:(e,t,n,i)=>$6(e,t,n,i),segments:(e,t,n,i)=>$6(e,t,n,i,!0),rectWithLine:(e,t,n)=>U6.segments(t,n,e.topLeft(),e.topRight())||U6.segments(t,n,e.topRight(),e.bottomRight())||U6.segments(t,n,e.bottomLeft(),e.bottomRight())||U6.segments(t,n,e.topLeft(),e.bottomLeft()),rects(e,t,n){let i=t.topLeft(),r=t.topRight(),o=t.bottomLeft(),a=t.bottomRight();const s=t.center();n&&(i=i.rotate(n,s),r=r.rotate(n,s),o=o.rotate(n,s),a=a.rotate(n,s));let l=e.contains(i)||e.contains(r)||e.contains(o)||e.contains(a)||U6.rectWithLine(e,i,r)||U6.rectWithLine(e,i,o)||U6.rectWithLine(e,r,a)||U6.rectWithLine(e,o,a);if(!l){if(i=e.topLeft(),r=e.topRight(),o=e.bottomLeft(),a=e.bottomRight(),n){const e=360-n;i=i.rotate(e,s),r=r.rotate(e,s),o=o.rotate(e,s),a=a.rotate(e,s)}l=t.contains(i)||t.contains(r)||t.contains(o)||t.contains(a)}return l}};const W6=(e,t)=>e.map(t);class j6{constructor(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(e){const t=new j6;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}}class q6{constructor(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(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(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(e){return new q6(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(e){return new M6(this.a*e.x+this.c*e.y+this.e,this.b*e.x+this.d*e.y+this.f)}applyRect(e){return A6.fromPoints(this.apply(e.topLeft()),this.apply(e.bottomRight()))}toString(){return"matrix("+this.a+" "+this.b+" "+this.c+" "+this.d+" "+this.e+" "+this.f+")"}static fromSVGMatrix(e){const t=new q6;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}static fromMatrixVector(e){const t=new q6;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}static fromList(e){if(6!==e.length)throw new Error("The given list should consist of six elements.");const t=new q6;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}static translation(e,t){const n=new q6;return n.a=1,n.b=0,n.c=0,n.d=1,n.e=e,n.f=t,n}static unit(){return new q6(1,0,0,1,0,0)}static rotation(e,t,n){const i=new q6;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}static scaling(e,t){const n=new q6;return n.a=e,n.b=0,n.c=0,n.d=t,n.e=0,n.f=0,n}static parse(e){let t,n;if(e){if("matrix"===(e=e.trim()).slice(0,6).toLowerCase()){if(n=e.slice(7,e.length-1).trim(),t=n.split(","),6===t.length)return q6.fromList(W6(t,(function(e){return parseFloat(e)})));if(t=n.split(" "),6===t.length)return q6.fromList(W6(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&&(t=e.split(","),6===t.length))return q6.fromList(W6(t,(function(e){return parseFloat(e)})));if(e.indexOf(" ")>0&&(t=e.split(" "),6===t.length))return q6.fromList(W6(t,(function(e){return parseFloat(e)})))}return t}}function G6(e,t){let n,i,r;do{n=2*Math.random()-1,i=2*Math.random()-1,r=n*n+i*i}while(!r||r>1);return e+t*n*Math.sqrt(-2*Math.log(r)/r)}class K6{constructor(e,t,n){this.point=e,this.left=t,this.right=n}}let Y6=class extends v6{constructor(e){super(),this._hashTable=new x6,this.length=0,B4(e)&&(e instanceof x6?e.forEach((function(e){this.add(e)})):e instanceof C6&&e.forEach((function(e,t){this.add({key:e,value:t})}),this))}contains(e){return this._hashTable.containsKey(e)}add(e){this._hashTable.get(e)||(this._hashTable.add(e,e),this.length++,this.trigger("changed"))}get(e){return this.contains(e)?this._hashTable.get(e).value:null}hash(e){return this._hashTable._hash(e)}remove(e){this.contains(e)&&(this._hashTable.remove(e),this.length--,this.trigger("changed"))}forEach(e,t){const n=t?e.bind(t):e;this._hashTable.forEach((function(e){n(e.value)}))}toArray(){const e=[];return this.forEach((function(t){e.push(t)})),e}};class Q6{constructor(e,t){this.width=e,this.height=t}static Empty(){return new Q6(0,0)}}class X6{constructor(e,t,n){this.x=t||0,this.y=n||0,this.angle=e}toString(){return this.x&&this.y?`rotate(${this.angle},${this.x},${this.y})`:`rotate(${this.angle})`}toMatrix(){return q6.rotation(this.angle,this.x,this.y)}center(){return new M6(this.x,this.y)}invert(){return new X6(360-this.angle,this.x,this.y)}static create(e){return new X6(e.angle,e.x,e.y)}static parse(e){const t=e.slice(1,e.length-1).split(",");const n=parseFloat(t[0]);const i=parseFloat(t[1]);const r=parseFloat(t[2]);return new X6(n,i,r)}}X6.ZERO=new X6(0);class Z6{constructor(e,t){this.x=e,this.y=t}toMatrix(){return q6.scaling(this.x,this.y)}toString(){return`scale(${this.x},${this.y})`}invert(){return new Z6(1/this.x,1/this.y)}}class J6{constructor(e,t){this.x=e,this.y=t}toMatrixVector(){return new j6(0,0,0,0,this.x,this.y)}toMatrix(){return q6.translation(this.x,this.y)}toString(){return`translate(${this.x},${this.y})`}plus(e){this.x+=e.x,this.y+=e.y}times(e){this.x*=e,this.y*=e}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}normalize(){0!==this.Length&&this.times(1/this.length())}invert(){return new J6(-this.x,-this.y)}}class e5{constructor(e,t,n,i,r,o){this.translate=new J6(e,t),void 0!==n&&void 0!==i&&(this.scale=new Z6(n,i)),void 0!==r&&(this.rotate=o?new X6(r,o.x,o.y):new X6(r))}toString(){const e=function(e){return e?e.toString():""};return e(this.translate)+e(this.rotate)+e(this.scale)}render(e){e._transform=this,e._renderTransform()}toMatrix(){let e=q6.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(){const e=this.rotate?this.rotate.invert():void 0,t=e?e.toMatrix():q6.unit(),n=this.scale?this.scale.invert():void 0,i=n?n.toMatrix():q6.unit();let r=new M6(-this.translate.x,-this.translate.y);r=t.times(i).apply(r);const o=new J6(r.x,r.y);const a=new e5;return a.translate=o,a.rotate=e,a.scale=n,a}}function t5(e,t){const n=this.options;let i=!1;let r,o;for(let a=0;a<t.length;a++)o=t[a],r=e[o],$4(r)&&n[o]!==r&&(n[o]=r,i=!0);return i}let n5=class{constructor(e){this.options=P6({},this.options,e),this.id=this.options.id,this._originSize=A6.empty(),this._transform=new e5}visible(e){return this.drawingContainer().visible(e)}redraw(e){e&&e.id&&(this.id=e.id)}position(e,t){const n=this.options;if(!H4(e))return new M6(n.x,n.y);H4(t)?(n.x=e,n.y=t):e instanceof M6&&(n.x=e.x,n.y=e.y),this._transform.translate=new J6(n.x,n.y),this._renderTransform()}rotate(e,t){return H4(e)&&(this._transform.rotate=new X6(e,t.x,t.y),this._renderTransform()),this._transform.rotate||X6.ZERO}drawingContainer(){return this.drawingElement}_renderTransform(){const e=this._transform.toMatrix();this.drawingContainer().transform(new Jo(e.a,e.b,e.c,e.d,e.e,e.f))}_hover(){}_diffNumericOptions(e,t){return t5.call(this,e,t)}_measure(e){let t;if(!this._measured||e){const e=this._boundingBox()||new ya([0,0],[0,0]);const n=e.topLeft();t=new A6(n.x,n.y,e.width(),e.height()),this._originSize=t,this._originWidth=t.width,this._originHeight=t.height,this._measured=!0}else t=this._originSize;return t}_boundingBox(){return this.drawingElement.rawBBox()}};function i5(e){return{x:e.x||0,y:e.y||0,width:e.width||0,height:e.height||0}}function r5(e){if(e){let t=e;return N4(t)&&(t={color:t}),t.color&&(t.color=o5(t.color)),t}}function o5(e){let t;return t=e!==X3?new bo(e).toHex():e,t}function a5(e,t){return new cs(new ba(e,t))}function s5(e){if(e)return new ya([e.x,e.y],[e.width,e.height])}function l5(e,t=0){const n={top:0,right:0,bottom:0,left:0};return"number"==typeof e?n.top=n.right=n.bottom=n.left=e:(n.top=e.top||t,n.right=e.right||t,n.bottom=e.bottom||t,n.left=e.left||t),n}const c5=(e,t,n)=>{const i=t.length;for(let r=0;r<i;r++){const o=t[(r+i-1)%i];const a=t[r];const s=t[(r+1)%i];const l=Array.isArray(n)?n[r]:n;const c={x:o.x-a.x,y:o.y-a.y};const d={x:s.x-a.x,y:s.y-a.y};const h=Math.hypot(c.x,c.y);const u=Math.hypot(d.x,d.y);const p=(c.x*d.x+c.y*d.y)/(h*u);const f=Math.acos(Math.max(-1,Math.min(1,p)));const m=l/Math.tan(f/2);const g=Math.min(m,h-.001,u-.001);const v={x:a.x+c.x/h*g,y:a.y+c.y/h*g};const _={x:a.x+d.x/u*g,y:a.y+d.y/u*g};0===r?e.moveTo(v.x,v.y):e.lineTo(v.x,v.y);const b=c.x*d.y-c.y*d.x<0;e.arcTo([_.x,_.y],l,l,!1,b)}e.close()};const d5=(e,t,n,i)=>{const r=e.bbox();if(!r.size.width||!r.size.height)return;const o=n+i;const a=(t+i)/r.size.width;const s=o/r.size.height;e.transform(new ka(new Jo(a,0,0,s,-r.origin.x*a,-r.origin.y*s)))};function h5(e,t){const n=e.length;const i=[];for(let r=0;r<n;r++){const o=e[(r+n-1)%n];const a=e[r];const s=e[(r+1)%n];const l=Array.isArray(t)?t[r]:t;const c={x:o.x-a.x,y:o.y-a.y};const d={x:s.x-a.x,y:s.y-a.y};const h=Math.hypot(c.x,c.y);const u=Math.hypot(d.x,d.y);const p={x:c.x/h,y:c.y/h};const f={x:d.x/u,y:d.y/u};const m=Math.acos(Math.max(-1,Math.min(1,p.x*f.x+p.y*f.y)));const g=l/Math.sin(m/2)-l;let v={x:p.x+f.x,y:p.y+f.y};const _=Math.hypot(v.x,v.y);v={x:v.x/_,y:v.y/_};const b={x:-v.x,y:-v.y};i.push({x:a.x+b.x*g,y:a.y+b.y*g})}return i}const u5={stroke:{color:"gray",width:1},fill:{color:X3}};class p5 extends n5{constructor(e){super(e=P6({},u5,e)),(e=this.options).fill=r5(e.fill),e.stroke=r5(e.stroke)}fill(e,t){this._fill({color:o5(e),opacity:t})}stroke(e,t,n){this._stroke({color:o5(e),width:t,opacity:n})}redraw(e){if(e){const t=e.stroke;const n=e.fill;t&&this._stroke(r5(t)),n&&this._fill(r5(n)),super.redraw(e)}}_hover(e){const t=this.options;const n=t.hover;if(n&&n.fill){const i=e?r5(n.fill):t.fill;this._setFill(i)}}_setFill(e){this.drawingElement.fill(e.color,e.opacity)}_evalStrokeOptions(e){const t=this.options;P6(t,{stroke:e});let n=null;return(e=t.stroke).width>0&&(n={color:e.color,width:e.width,opacity:e.opacity,dashType:e.dashType}),n}_evalFillOptions(e){const t=this.options;return P6(t,{fill:e||{}}),t.fill}_stroke(e){const t=this._evalStrokeOptions(e);this.drawingElement.options.set("stroke",t)}_fill(e){const t=this._evalFillOptions(e);if(t.gradient){const e=t.gradient;const n="radial"===e.type?cl:ll;this.drawingElement.fill(new n(e))}else this.drawingElement.fill(t.color,t.opacity)}}const f5={stroke:{color:X3,width:0},fill:{color:"black"}};class m5 extends p5{constructor(e){super(e=P6({},f5,e));const t=this.options.anchor||{};this.anchor=new ba(t.x,t.y),this.createElement()}createElement(){}_transformToPath(e,t){const n=t.transform();return e&&n&&(e=e.transformCopy(n)),e}redraw(e){e&&(e.position&&(this.options.position=e.position),super.redraw(e))}}const g5={path:"M 0 0 L 10 5 L 0 10 L 3 5 z",anchor:{x:10,y:5}};class v5 extends m5{constructor(e){super(e=P6({},g5,e))}createElement(){const e=this.options;this.drawingElement=Rs.parse(e.path,{fill:e.fill,stroke:e.stroke})}positionMarker(e){const t=this._linePoints(e);const n=t.start;const i=t.end;const r=xa();if(n&&r.rotate(function(e,t){const n=t.x-e.x;const i=t.y-e.y;return Io(Math.atan2(i,n))}(n,i),i),i){const e=this.anchor;const t=i.clone().translate(-e.x,-e.y);r.translate(t.x,t.y)}this.drawingElement.transform(r)}_linePoints(e){const t=this.options;const n=e.segments;let i,r,o;if(t.position===Z3){if(o=n[0],o){r=o.anchor(),i=o.controlOut();const e=n[1];!i&&e&&(i=e.anchor())}}else if(o=n[n.length-1],o){r=o.anchor(),i=o.controlIn();const e=n[n.length-2];!i&&e&&(i=e.anchor())}if(r)return{start:this._transformToPath(i,e),end:this._transformToPath(r,e)}}}let _5=class{constructor(e,t){this._translate=(e,t)=>{const n=this._viewBox;return H4(e)&&H4(t)&&(n.x=e,n.y=t,this.surface.translate({x:e,y:t})),{x:n.x,y:n.y}},this.element=e,this.surface=Fc.create(e,t),R4(this.surface.translate)&&(this.translate=this._translate),this.drawingElement=new Us,this._viewBox=new A6(0,0,t.width,t.height),this.size(this._viewBox)}bounds(){const e=this.drawingElement.clippedBBox();return new A6(0,0,e.width(),e.height())}size(e){const t=this._viewBox;return H4(e)&&(t.width=e.width,t.height=e.height,this.surface.setSize(e)),{width:t.width,height:t.height}}draw(){this.surface.draw(this.drawingElement)}append(e){return this.drawingElement.append(e.drawingContainer()),this}remove(e){this.drawingElement.remove(e.drawingContainer())}insertBefore(){}clear(){this.drawingElement.clear()}destroy(e){this.surface.destroy(),e&&(!function(e){for(;e.firstChild;)e.removeChild(e.firstChild)}(this.element),this.element.remove())}};const b5={_setScale:function(){const e=this.options;const t=this._originWidth;const n=this._originHeight;let i=e.width/t;let r=e.height/n;$4(i)||(i=1),$4(r)||(r=1),this._transform.scale=new Z6(i,r)},_setTranslate:function(){const e=this.options;const t=e.x||0;const n=e.y||0;this._transform.translate=new J6(t,n)},_initSize:function(){const e=this.options;let t=!1;!1!==e.autoSize&&(B4(e.width)||B4(e.height))&&(this._measure(!0),this._setScale(),t=!0),(B4(e.x)||B4(e.y))&&(this._setTranslate(),t=!0),t&&this._renderTransform()},_updateSize:function(e){let t=!1;return!1!==this.options.autoSize&&this._diffNumericOptions(e,[G3,K3])&&(t=!0,this._measure(!0),this._setScale()),this._diffNumericOptions(e,[Y3,Q3])&&(t=!0,this._setTranslate()),t&&this._renderTransform(),t}};class w5 extends p5{constructor(e){super(e),this._setScale=b5._setScale.bind(this),this._setTranslate=b5._setTranslate.bind(this),this._initSize=b5._initSize.bind(this),this._updateSize=b5._updateSize.bind(this),this._initCircle(),this._initSize()}redraw(e){if(e){const t=this.options;e.center&&(P6(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),super.redraw.call(this,e)}}_initCircle(){const e=this.options;let t=e.width;let n=e.height;let i=e.radius;H4(i)||(H4(t)||(t=n),H4(n)||(n=t),e.radius=i=Math.min(t,n)/2);const r=e.center||{x:i,y:i};this._center=new ba(r.x,r.y),this._circle=new Ia(this._center,i),this.drawingElement=new Ra(this._circle,{stroke:e.stroke}),this._fill()}}const y5={radius:4,anchor:{x:0,y:0}};class k5 extends m5{constructor(e){super(e=P6({},y5,e))}createElement(){const e=this.options;this.drawingElement=new Ra(new Ia(this.anchor,e.radius),{fill:e.fill,stroke:e.stroke})}positionMarker(e){const t=this.options.position;const n=e.segments;let i;let r;i=t===Z3?n[0]:n[n.length-1],i&&(r=this._transformToPath(i.anchor(),e),this.drawingElement.transform(xa().translate(r.x,r.y)))}}class x5 extends p5{constructor(e){super(e),this._initPath(),this._setPosition()}_setPosition(){const e=this.options;const t=e.x;const n=e.y;(H4(t)||H4(n))&&this.position(t||0,n||0)}redraw(e){e&&(super.redraw(e),this._diffNumericOptions(e,[G3,K3])&&this._drawPath(),this._diffNumericOptions(e,[Y3,Q3])&&this._setPosition())}_initPath(){const e=this.options;this.drawingElement=new Rs({stroke:e.stroke}),this._fill(),this._drawPath()}_drawPath(){const{width:e,height:t}=i5(this.options);const n=this.drawingElement;const i=[{x:0,y:0},{x:e,y:0},{x:e,y:t},{x:0,y:t}];this.options.cornerRadius>0?c5(n,i,this.options.cornerRadius):((e,t)=>{const n=t.length;for(let i=0;i<n;i++){const n=t[i];0===i?e.moveTo(n.x,n.y):e.lineTo(n.x,n.y)}e.close()})(n,i)}}class C5 extends x5{_initPath(){const e=this.options;this.drawingElement=new Fs({stroke:e.stroke}),this._fill(),this._drawPath()}}const S5={shapesOffsetRatio:.025};class T5 extends C5{constructor(e){super({...S5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.cornerRadius;const r=this.options.stroke.width||0;const o=n*this.options.shapesOffsetRatio-i/2;const a=t/2;const s=n/2;c5(e,[{x:a,y:s-o},{x:0,y:0},{x:t,y:0}],[i/3,i,i]);c5(e,[{x:a,y:s+o},{x:t,y:n},{x:0,y:n}],[i/3,i,i]),d5(e,t,n,r)}}class M5 extends x5{_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=t/2;const r=Math.min(t,n)/2;e.moveTo([i,0]).arcTo([i,n],r,r,!1,!0).arcTo([i,0],r,r,!1,!0)}}const A5={slantRatio:.15};class D5 extends x5{constructor(e){super({...A5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const{slantRatio:r,cornerRadius:o}=this.options;const a=t*r;c5(e,[{x:a,y:0},{x:t,y:0},{x:t-a,y:n},{x:0,y:n}],o),d5(e,t,n,i)}}const E5={ellipseRxRatio:.5,ellipseRyRatio:.2};class I5 extends x5{constructor(e){super({...E5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=t*this.options.ellipseRxRatio;const o=n*this.options.ellipseRyRatio;const a=o;const s=o;e.moveTo([t,a]).arcTo([0,a],r,s,!1,!0).arcTo([t,a],r,s,!1,!0).lineTo([t,n]).arcTo([0,n],r,s,!1,!0).lineTo([0,a]),d5(this.drawingElement,t,n,i)}}const z5={ellipseRadiusXRatio:.165,ellipseRadiusYRatio:.5};class P5 extends C5{constructor(e){super({...z5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=t*this.options.ellipseRadiusXRatio;const r=i;const o=n*this.options.ellipseRadiusYRatio;const a=i;e.moveTo(a,0).lineTo(t,0).arc(270,90,r,o,!0).lineTo(a,n).arcTo([a,0],r,o,!1,!0).close()}}class L5 extends x5{_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=h5([{x:0,y:n/2},{x:t/2,y:0},{x:t,y:n/2},{x:t/2,y:n}],this.options.cornerRadius);c5(e,r,this.options.cornerRadius),d5(e,t,n,i)}}const B5={arcRadiusXRatio:.17,arcRadiusYRatio:.3};class H5 extends x5{constructor(e){super({...B5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const{arcRadiusXRatio:r,arcRadiusYRatio:o,cornerRadius:a}=this.options;const s=t*r;const l=n*o;e.moveTo([0,a]).arcTo([a,0],a,a,!0,!1).lineTo([t-s,0]).arcTo([t-s,n],s,l,!1,!1).lineTo([a,n]).arcTo([0,n-a],a,a,!0,!1).close(),d5(this.drawingElement,t,n,i)}}const R5={ellipseRatio:.1407};class F5 extends x5{constructor(e){super({...R5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=t*this.options.ellipseRatio;const r=i;const o=i;const a=n/2;e.moveTo([t-r,n]).arcTo([t-r,0],o,a,!1,!0).arcTo([t-r,n],o,a,!1,!0).lineTo([r,n]).arcTo([r,0],o,a,!1,!0).lineTo([t-r,0])}}const O5={sideCutRatio:.35,arcRadiusYRatio:.3,arcRadiusXRatio:.08};class V5 extends x5{constructor(e){super({...O5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=n*this.options.arcRadiusYRatio;const o=t*this.options.arcRadiusXRatio;const a=t-o;const s=t*this.options.sideCutRatio;e.moveTo([s,0]).lineTo([a,0]).arcTo([a,n],o,r,!1,!0).lineTo([a,n]).lineTo([s,n]).lineTo([0,n/2]).close(),d5(this.drawingElement,t,n,i)}}const N5=5/6;const $5=1/6;const U5={waveRatio:.37};const W5={...U5,docsXRatio:.14,docsYRatio:.2};const j5=(e,t,n,i,r,o)=>{const a=i*r;e.moveTo(t[0]+n,t[1]+i).curveTo([t[0]+n,t[1]+i],[t[0]+n*N5,t[1]+i-a],[t[0]+n/2,t[1]+i]).curveTo([t[0]+n*$5,t[1]+i+a],[t[0],t[1]+i],[t[0],t[1]+i]).lineTo(t[0],t[1]+o).arcTo([t[0]+o,t[1]],o,o,!0,!1).lineTo(t[0]+n-o,t[1]).arcTo([t[0]+n,t[1]+o],o,o,!0,!1).lineTo(t[0]+n,t[1]+i).close()};class q5 extends x5{constructor(e){super({...U5,...e})}_drawPath(){const{width:e,height:t}=i5(this.options);const n=this.options.stroke.width||0;const{waveRatio:i,cornerRadius:r}=this.options;const o=t*i*.5;j5(this.drawingElement,[0,0],e,t-o,i,r),d5(this.drawingElement,e,t,n)}}class G5 extends q5{constructor(e){super({...W5,...e})}_initPath(){this.drawingElement=new Us,this._fill(),this._drawPath()}_fill(e){const t=this._evalFillOptions(e);if(t.gradient){const e=t.gradient;const n="radial"===e.type?cl:ll;this.drawingElement.children.forEach((t=>{t.fill(new n(e))}))}else this.drawingElement.children.forEach((e=>{e.fill(t.color,t.opacity)}))}_drawPath(){const{width:e,height:t}=i5(this.options);const n=this.options.stroke.width||0;const{waveRatio:i,docsXRatio:r,docsYRatio:o,stroke:a,fill:s,cornerRadius:l}=this.options;const c=e*r;const d=t*o;const h=this.drawingElement;const u=new Fs({stroke:a,fill:s});const p=new Fs({stroke:a,fill:s});const f=t*i*.5;j5(u,[c,0],e-c,t-d-f,i,l),j5(p,[0,d],e-c,t-d-f,i,l),h.append(u),h.append(p),d5(this.drawingElement,e,t,n)}}class K5 extends x5{_drawPath(){const{width:e,height:t}=i5(this.options);const n=t/2;this.drawingElement.moveTo(n,0).lineTo(e-2*n,0).arcTo([e-2*n,t],n,n,!1,!1).lineTo(n,t).arcTo([n,0],n,n,!1,!1).close()}}class Y5 extends x5{_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=this.options.cornerRadius||0;const o=h5([{x:t/2,y:0},{x:t,y:n},{x:0,y:n}],r);c5(e,o,r),d5(e,t,n,i)}}class Q5 extends n5{constructor(e){super(e=P6({autoSize:!1},e)),this.children=[],this._childrenChange=!1,this._setScale=b5._setScale.bind(this),this._setTranslate=b5._setTranslate.bind(this),this._initSize=b5._initSize.bind(this),this._updateSize=b5._updateSize.bind(this),this.drawingElement=new Us,this._initSize()}append(e){this.drawingElement.append(e.drawingContainer()),this.children.push(e),this._childrenChange=!0}remove(e){this._remove(e)&&(this._childrenChange=!0)}_remove(e){const t=this.children.indexOf(e);if(t>=0)return this.drawingElement.removeAt(t),this.children.splice(t,1),!0}clear(){this.drawingElement.clear(),this.children=[],this._childrenChange=!0}toFront(e){let t;for(let n=0;n<e.length;n++)t=e[n],this._remove(t)&&this.append(t)}toBack(e){this._reorderChildren(e,0)}toIndex(e,t){this._reorderChildren(e,t)}_reorderChildren(e,t){const n=this.drawingElement;const i=n.children.slice(0);const r=this.children;const o=$4(t);let a,s,l,c,d;for(a=0;a<e.length;a++)d=e[a],c=d.drawingContainer(),s=r.indexOf(d),s>=0&&(i.splice(s,1),r.splice(s,1),l=o?t:t[a],i.splice(l,0,c),r.splice(l,0,d));n.clear(),n.append(...i)}redraw(e){e&&(this._childrenChange?(this._childrenChange=!1,this._updateSize(e)||this._initSize()):this._updateSize(e),super.redraw(e))}_boundingBox(){const e=this.children;let t;let n,i;for(let r=0;r<e.length;r++)n=e[r],n.visible()&&!1!==n._includeInBBox&&(i=n.drawingContainer().clippedBBox(null),i&&(t=t?ya.union(t,i):i));return t}}let X5=class extends n5{constructor(e){super(e),this._initImage()}redraw(e){e&&(e.source&&this.drawingElement.src(e.source),this._diffNumericOptions(e,[G3,K3,Y3,Q3])&&this.drawingElement.rect(this._rect()),super.redraw(e))}_initImage(){const e=this.options;const t=this._rect();this.drawingElement=new Ns(e.source,t)}_rect(){const e=i5(this.options);const t=new ba(e.x,e.y);const n=new wa(e.width,e.height);return new ya(t,n)}};const Z5={leftLineOffsetRatio:.13,topLineOffsetRatio:.23};class J5 extends C5{constructor(e){super({...Z5,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const{leftLineOffsetRatio:i,topLineOffsetRatio:r}=this.options;const o=t*i;const a=n*r;c5(e,[{x:0,y:0},{x:t,y:0},{x:t,y:n},{x:0,y:n}],this.options.cornerRadius),e.moveTo(o,0).lineTo(o,n).moveTo(0,a).lineTo(t,a)}}class e8 extends Q5{constructor(e,t){super(t),this.drawingElement=new Qs(s5(e),t),this._initSize()}rect(e){if(e)this.drawingElement.rect(s5(e));else{const e=this.drawingElement.rect();if(e)return new A6(e.origin.x,e.origin.y,e.size.width,e.size.height)}}reflow(){this.drawingElement.reflow()}redraw(e){P6(this.drawingElement.options,e),super.redraw.call(this,e)}}const t8={_getPath:function(e){let t=this.drawingElement;if(t instanceof Fs&&(t=e===Z3?t.paths[0]:t.paths[t.paths.length-1]),t&&t.segments.length)return t},_normalizeMarkerOptions:function(e){const t=e.startCap;const n=e.endCap;N4(t)&&(e.startCap={type:t}),N4(n)&&(e.endCap={type:n})},_removeMarker:function(e){const t=this._markers[e];t&&(this.drawingContainer().remove(t.drawingElement),delete this._markers[e])},_createMarkers:function(){const e=this.options;this._normalizeMarkerOptions(e),this._markers={},this._markers[Z3]=this._createMarker(e.startCap,Z3),this._markers[J3]=this._createMarker(e.endCap,J3)},_createMarker:function(e,t){const n=(e||{}).type;const i=this._getPath(t);let r,o;if(i)return n===t4.FilledCircle?r=k5:n===t4.ArrowStart||n===t4.ArrowEnd?r=v5:this._removeMarker(t),r?(o=new r(P6({},e,{position:t})),o.positionMarker(i),this.drawingContainer().append(o.drawingElement),o):void 0;this._removeMarker(t)},_positionMarker:function(e){const t=this._markers[e];if(t){const n=this._getPath(e);n?t.positionMarker(n):this._removeMarker(e)}},_capMap:{start:"startCap",end:"endCap"},_redrawMarker:function(e,t,n){this._normalizeMarkerOptions(n);const i=this.options;const r=this._capMap[t];const o=(i[r]||{}).type;const a=n[r];let s=!1;return a?(i[r]=P6({},i[r],a),a.type&&o!==a.type?(this._removeMarker(t),this._markers[t]=this._createMarker(i[r],t),s=!0):this._markers[t]&&this._markers[t].redraw(a)):e&&!this._markers[t]&&i[r]&&(this._markers[t]=this._createMarker(i[r],t),s=!0),s},_redrawMarkers:function(e,t){!this._redrawMarker(e,Z3,t)&&e&&this._positionMarker(Z3),!this._redrawMarker(e,J3,t)&&e&&this._positionMarker(J3)}};class n8 extends p5{constructor(e){super(e),this._capMap=t8._capMap,this.container=new Us,this._getPath=t8._getPath.bind(this),this._normalizeMarkerOptions=t8._normalizeMarkerOptions.bind(this),this._removeMarker=t8._removeMarker.bind(this),this._createMarkers=t8._createMarkers.bind(this),this._createMarker=t8._createMarker.bind(this),this._positionMarker=t8._positionMarker.bind(this),this._redrawMarker=t8._redrawMarker.bind(this),this._redrawMarkers=t8._redrawMarkers.bind(this),this._initPath(),this._createMarkers()}drawingContainer(){return this.container}redraw(e){if(e){const t=(e=e||{}).from;const 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),super.redraw(e)}}_initPath(){const e=this.options;const t=this.drawingElement=new Rs({stroke:e.stroke});this._fill(),this._drawPath(),this.container.append(t)}_drawPath(){const e=this.options;const t=this.drawingElement;const n=e.from||new M6;const i=e.to||new M6;t.segments.elements([a5(n.x,n.y),a5(i.x,i.y)])}}const i8={topSlantRatio:.2};class r8 extends x5{constructor(e){super({...i8,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const{topSlantRatio:r,cornerRadius:o}=this.options;c5(e,[{x:0,y:n*r},{x:t,y:0},{x:t,y:n},{x:0,y:n}],o),d5(e,t,n,i)}}const o8={baseShrinkRatio:.5};class a8 extends x5{constructor(e){super({...o8,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=t*this.options.baseShrinkRatio;c5(e,[{x:0,y:0},{x:t,y:0},{x:t-r/2,y:n},{x:r/2,y:n}],this.options.cornerRadius),d5(e,t,n,i)}}class s8 extends x5{_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=h5([{x:0,y:0},{x:t,y:0},{x:t/2,y:n}],this.options.cornerRadius);c5(e,r,this.options.cornerRadius),d5(e,t,n,i)}}class l8 extends C5{_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=t/2;const r=n/2;const o=Math.min(t,n)/2-this.options.stroke.width;e.moveTo(i,0).arcTo([i,n],o,o,!1,!0).arcTo([i,0],o,o,!1,!0).moveTo(0,r).lineTo(t,r).moveTo(i,0).lineTo(i,n)}}const c8={ellipseRxRatio:.5,ellipseRyRatio:.13,bottomEdgeYRatio:.76};class d8 extends x5{constructor(e){super({...c8,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=t*this.options.ellipseRxRatio;const o=n*this.options.ellipseRyRatio;const a=o;const s=a;const l=a;const c=n*this.options.bottomEdgeYRatio;const d=t/2;const h=n;e.moveTo([0,a]).arcTo([t,l],r,o,!1,!1).lineTo([t,c]).lineTo([d,h]).lineTo([0,c]).lineTo([0,s]).close(),d5(this.drawingElement,t,n,i)}}class h8 extends p5{constructor(e){super(e=P6({autoSize:!0},e)),this._capMap=t8._capMap,this.container=new Us,this._setScale=b5._setScale.bind(this),this._setTranslate=b5._setTranslate.bind(this),this._initSize=b5._initSize.bind(this),this._updateSize=b5._updateSize.bind(this),this._getPath=t8._getPath.bind(this),this._normalizeMarkerOptions=t8._normalizeMarkerOptions.bind(this),this._removeMarker=t8._removeMarker.bind(this),this._createMarkers=t8._createMarkers.bind(this),this._createMarker=t8._createMarker.bind(this),this._positionMarker=t8._positionMarker.bind(this),this._redrawMarker=t8._redrawMarker.bind(this),this._redrawMarkers=t8._redrawMarkers.bind(this),this._createElements(),this._initSize()}drawingContainer(){return this.container}data(e){const t=this.options;if(!e)return t.data;t.data!==e&&(t.data=e,this._setData(e),this._initSize(),this._redrawMarkers(!0,{}))}redraw(e){if(e){super.redraw(e);const t=this.options;const n=e.data;H4(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(){const e=this.options;this.drawingElement=Rs.parse(e.data||"",{stroke:e.stroke}),this._fill(),this.container.append(this.drawingElement),this._createMarkers()}_setData(e){const t=this.drawingElement;const n=Rs.parse(e||"");const i=n.paths.slice(0);n.paths.elements([]),t.paths.elements(i)}}class u8 extends p5{constructor(e){super(e=P6({points:[]},e)),this._capMap=t8._capMap,this.container=new Us,this._getPath=t8._getPath.bind(this),this._normalizeMarkerOptions=t8._normalizeMarkerOptions.bind(this),this._removeMarker=t8._removeMarker.bind(this),this._createMarkers=t8._createMarkers.bind(this),this._createMarker=t8._createMarker.bind(this),this._positionMarker=t8._positionMarker.bind(this),this._redrawMarker=t8._redrawMarker.bind(this),this._redrawMarkers=t8._redrawMarkers.bind(this),this._initPath(),this._createMarkers()}drawingContainer(){return this.container}points(e){const t=this.options;if(!e)return t.points;t.points=e,this._updatePath()}redraw(e){if(e){const t=e.points;super.redraw.call(this,e),t&&this._pointsDiffer(t)?(this.points(t),this._redrawMarkers(!0,e)):this._redrawMarkers(!1,e)}}_initPath(){const e=this.options;this.drawingElement=new Rs({stroke:e.stroke}),this._fill(),this.container.append(this.drawingElement),e.points&&this._updatePath()}_pointsDiffer(e){const t=this.options.points;let n=t.length!==e.length;if(!n)for(let 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(){const e=this.drawingElement;const t=this.options.points;const n=[];let i;for(let e=0;e<t.length;e++)i=t[e],n.push(a5(i.x,i.y));e.segments.elements(n)}}const p8={sideLineOffsetRatio:.1};class f8 extends C5{constructor(e){super({...p8,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=t*this.options.sideLineOffsetRatio;const r=i;const o=t-i;c5(e,[{x:0,y:0},{x:t,y:0},{x:t,y:n},{x:0,y:n}],this.options.cornerRadius),e.moveTo(r,0).lineTo(r,n).moveTo(o,0).lineTo(o,n)}}const m8={horizontalInsetRatio:1/6};class g8 extends x5{constructor(e){super({...m8,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=t*this.options.horizontalInsetRatio;c5(e,[{x:r,y:0},{x:t-r,y:0},{x:t,y:n/2},{x:t-r,y:n},{x:r,y:n},{x:0,y:n/2}],this.options.cornerRadius),d5(e,t,n,i)}}class v8 extends x5{}const _8={shapesOffsetRatio:.015};class b8 extends C5{constructor(e){super({..._8,...e})}_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=this.options.stroke.width||0;const r=this.options.cornerRadius;const o=this.options.shapesOffsetRatio*n;const a=n/2;c5(e,[{x:t/2,y:0},{x:t,y:a-o},{x:0,y:a-o}],[r/3,r,r]);c5(e,[{x:t/2,y:n},{x:0,y:a+o},{x:t,y:a+o}],[r/3,r,r]),d5(e,t,n,i)}}class w8 extends C5{_drawPath(){const e=this.drawingElement;const{width:t,height:n}=i5(this.options);const i=t/2;const r=n/2;const o=.5*Math.min(t,n);const a=r-o;const s=r+o;const l=i-o/Math.SQRT2;const c=r-o/Math.SQRT2;const d=i+o/Math.SQRT2;const h=r+o/Math.SQRT2;e.moveTo(i,a).arcTo([i,s],o,o,!1,!0).arcTo([i,a],o,o,!1,!0).moveTo(l,c).lineTo(d,h).moveTo(d,c).lineTo(l,h)}}const y8=e=>(e&&e.color&&(e=P6({},e,{fill:{color:e.color}})),e);const k8={fontSize:15,fontFamily:"sans-serif",lineSpacing:0,textWrap:"nowrap",padding:l5(0),relativePadding:l5(0),stroke:{width:0},fill:{color:"black"},autoSize:!0};class x8 extends p5{constructor(e){e=P6({},k8,e),super(e=y8(e)),this.textElements=[],this.alignable=!0,this._setScale=b5._setScale.bind(this),this._setTranslate=b5._setTranslate.bind(this),this._initSize=b5._initSize.bind(this),this._updateSize=b5._updateSize.bind(this),this._font(),this._initText(),this._initSize()}_initText(){const e=this.options;this.textElements.length=0,this.drawingElement=new Vs(H4(e.text)?e.text:"",new ba,{font:e.font}),this.textElements.push(this.drawingElement),this._fill(),this._stroke()}_fill(e){const t=this._evalFillOptions(e);if(t.gradient){const e=t.gradient;const n="radial"===e.type?cl:ll;this.textElements.forEach((t=>{t.fill(new n(e))}))}else this._setFill(t)}_setFill(e){this.textElements.forEach((t=>{t.fill(e.color,e.opacity)}))}_stroke(e){const t=this._evalStrokeOptions(e);this.textElements.forEach((e=>e.options.set("stroke",t)))}_font(){const e=this.options;if(e.fontFamily&&H4(e.fontSize)){const t=[];e.fontStyle&&t.push(e.fontStyle),e.fontWeight&&t.push(e.fontWeight),t.push(e.fontSize+($4(e.fontSize)?"px":"")),t.push(e.fontFamily),e.font=t.join(" ")}else delete e.font}content(e){return this.drawingElement.content(e)}redraw(e){if(e){let t=!1;const n=this.options;e=y8(e),super.redraw(e),(e.fontFamily||H4(e.fontSize)||e.fontStyle||e.fontWeight)&&(P6(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()}}}class C8{constructor(e,t,n,i){this.x1=e,this.y1=t,this.x2=n,this.y2=i}width(){return this.x2-this.x1}height(){return this.y2-this.y1}pad(e){const t={...e};return this.x1-=t.left,this.x2+=t.right,this.y1-=t.top,this.y2+=t.bottom,this}unpad(e){const t={...e};return t.left=-t.left,t.top=-t.top,t.right=-t.right,t.bottom=-t.bottom,this.pad(t)}toRect(){return new ya([this.x1,this.y1],[this.width(),this.height()])}}const S8=(e="")=>{const t={justifyContent:"center",alignContent:"center"};return e.includes("left")&&(t.justifyContent="start"),e.includes("right")&&(t.justifyContent="end"),e.includes("top")&&(t.alignContent="start"),e.includes("bottom")&&(t.alignContent="end"),t};class T8 extends x8{constructor(){super(...arguments),this.alignable=!1}content(e){return void 0!==e&&(this.options.text=e,this._initText()),this.options.text}_initText(){this.textElements.length=0,this.alignable=!1;const e=this.drawingElement=this.drawingElement||new Us;e.children.length&&e.clear();const t=this.options;const{shapeSize:n}=t;const i=new C8(0,0,n.width,n.height);const r=function(e,t){const n=l5(t,0);return{left:e.width*n.left,top:e.height*n.top,right:e.width*n.right,bottom:e.height*n.bottom}}(n,t.relativePadding);i.unpad(r),i.unpad(t.padding);const o=i.toRect();const a=new Qs(o,{...S8(t.align),lineSpacing:t.lineSpacing});this._textLines(o?o.size.width:void 0).forEach((n=>{const i=new Vs(n,new ba(0,0),{font:t.font});this.textElements.push(i),(a||e).append(i)})),a&&(a.reflow(),e.append(a)),this._fill(),this._stroke()}_textLines(e){const{text:t=""}=this.options;if(void 0===e)return[t];const n={font:this.options.font};const i=ha;const r=t.split(" ");const o=[];let a="";return r.forEach((t=>{for(;i(t,n).width>e;){let r="";for(let o=1;o<=t.length;o++){const a=t.substring(0,o);if(i(a,n).width>e)break;r=a}if(!r)break;a&&(o.push(a),a=""),o.push(r),t=t.substring(r.length)}const r=a?`${a} ${t}`:t;i(r,n).width>e&&a?(o.push(a),a=t):a=r})),a&&o.push(a),o}}class M8 extends B6{constructor(e){if(super(),F4(e))throw new Error("Diagram is not specified.");this.diagram=e}layout(e){this.transferOptions(e);const t=new N6(this.diagram).convert(e);if(t.isEmpty())return;const n=t.getConnectedComponents();if(U4(n))return;for(let t=0;t<n.length;t++){const i=n[t];this.layoutGraph(i,e)}const i=this.gridLayoutComponents(n);return new H6(this.diagram,i)}_initRuntimeProperties(){for(let e=0;e<this.graph.nodes.length;e++){const 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(e){const t=[];let n,i,r;const o=new C6;let a=0;let s,l,c;for(X4(e.nodes,(function(e){0===e.incoming.length&&(o.set(e,0),t.push(e))}));t.length>0;)for(l=t.shift(),n=0;n<l.outgoing.length;n++)r=l.outgoing[n],c=r.target,s=o.containsKey(c)?Math.max(o.get(l)+1,o.get(c)):o.get(l)+1,o.set(c,s),s>a&&(a=s),e6(t,c)||t.push(c);const d=o.keys();d.sort((function(e,t){const n=o.get(e);const i=o.get(t);return Y4(i-n)}));for(let e=0;e<d.length;++e){const t=d[e];let n=Number.MAX_VALUE;if(0!==t.outgoing.length){for(i=0;i<t.outgoing.length;++i)r=t.outgoing[i],n=Math.min(n,o.get(r.target));n>1&&o.set(t,n-1)}}let h;for(this.layers=[],n=0;n<a+1;n++)h=[],h.linksTo={},this.layers.push(h);for(o.forEach((function(e,t){e.layer=t,this.layers[t].push(e)}),this),i=0;i<this.layers.length;i++)for(h=this.layers[i],n=0;n<h.length;n++)h[n].gridPosition=n}layoutGraph(e,t){if(F4(e))throw new Error("No graph given or graph analysis of the diagram failed.");B4(t)&&this.transferOptions(t),this.graph=e,e.setItemIndices();const n=e.makeAcyclic();this._initRuntimeProperties(),this._prepare(e),this._dummify(),this._optimizeCrossings(),this._swapPairs(),this.arrangeNodes(),this._moveThingsAround(),this._dedummify(),X4(n,(function(e){e.points&&e.points.reverse()}))}setMinDist(e,t,n){const i=e.layer;const r=e.layerIndex;if(!Number.isInteger(i)||!Number.isInteger(r)||i<0||r<0)throw new Error("Invalid layer or index value.");this.minDistances[i][r]=n}getMinDist(e,t){let n=0;const i=e.layerIndex,r=t.layerIndex,o=e.layer,a=Math.min(i,r),s=Math.max(i,r);for(let e=a;e<s;++e)n+=this.minDistances[o][e];return n}placeLeftToRight(e){const t=new C6;let n,i;for(let r=0;r<this.layers.length;++r){const o=e[r];if(!o)continue;for(n=0;n<o.length;n++)i=o[n],t.containsKey(i)||this.placeLeft(i,t,r);let a=Number.POSITIVE_INFINITY;for(n=0;n<o.length;n++){i=o[n];const e=this.rightSibling(i);e&&this.nodeLeftClass.get(e)!==r&&(a=Math.min(a,t.get(e)-t.get(i)-this.getMinDist(i,e)))}if(a===Number.POSITIVE_INFINITY){const e=[];for(n=0;n<o.length;n++){i=o[n];const a=[];h6(a,this.upNodes.get(i)),h6(a,this.downNodes.get(i));for(let n=0;n<a.length;n++){const o=a[n];this.nodeLeftClass.get(o)<r&&e.push(t.get(o)-t.get(i))}}e.sort(),a=0===e.length?0:e.length%2==1?e[this.intDiv(e.length,2)]:(e[this.intDiv(e.length,2)-1]+e[this.intDiv(e.length,2)])/2}for(n=0;n<o.length;n++)i=o[n],t.set(i,t.get(i)+a)}return t}placeRightToLeft(e){const t=new C6;let n,i;for(let r=0;r<this.layers.length;++r){const o=e[r];if(!o)continue;for(n=0;n<o.length;n++)i=o[n],t.containsKey(i)||this.placeRight(i,t,r);let a=Number.NEGATIVE_INFINITY;for(n=0;n<o.length;n++){i=o[n];const e=this.leftSibling(i);e&&this.nodeRightClass.get(e)!==r&&(a=Math.max(a,t.get(e)-t.get(i)+this.getMinDist(e,i)))}if(a===Number.NEGATIVE_INFINITY){const e=[];for(n=0;n<o.length;n++){i=o[n];const a=[];h6(a,this.upNodes.get(i)),h6(a,this.downNodes.get(i));for(let n=0;n<a.length;n++){const o=a[n];this.nodeRightClass.get(o)<r&&e.push(t.get(i)-t.get(o))}}e.sort(),a=0===e.length?0:e.length%2==1?e[this.intDiv(e.length,2)]:(e[this.intDiv(e.length,2)-1]+e[this.intDiv(e.length,2)])/2}for(n=0;n<o.length;n++)i=o[n],t.set(i,t.get(i)+a)}return t}_getLeftWing(){const e={value:null};const t=this.computeClasses(e,1);return this.nodeLeftClass=e.value,t}_getRightWing(){const e={value:null};const t=this.computeClasses(e,-1);return this.nodeRightClass=e.value,t}computeClasses(e,t){let n=0;const i=e.value=new C6;for(let e=0;e<this.layers.length;++e){n=e;const r=this.layers[e];for(let e=1===t?0:r.length-1;e>=0&&e<r.length;e+=t){const t=r[e];if(i.containsKey(t))n=i.get(t);else if(i.set(t,n),t.isVirtual){const e=this._nodesInLink(t);for(let t=0;t<e.length;t++){const r=e[t];i.set(r,n)}}}}const r=[];for(let e=0;e<this.layers.length;e++)r.push(null);return i.forEach((function(e,t){null===r[t]&&(r[t]=[]),r[t].push(e)})),r}_isVerticalLayout(){return"up"===this.options.subtype.toLowerCase()||"down"===this.options.subtype.toLowerCase()||"vertical"===this.options.subtype.toLowerCase()}_isHorizontalLayout(){return"right"===this.options.subtype.toLowerCase()||"left"===this.options.subtype.toLowerCase()||"horizontal"===this.options.subtype.toLowerCase()}_isIncreasingLayout(){return"right"===this.options.subtype.toLowerCase()||"down"===this.options.subtype.toLowerCase()}_moveThingsAround(){let e,t,n,i,r,o;for(t=0;t<this.layers.length;++t)i=this.layers[t],i.sort(this._gridPositionComparer.bind(this));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],n.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 C6,this.upNodes=new C6,X4(this.graph.nodes,(function(e){this.downNodes.set(e,[]),this.upNodes.set(e,[])}),this),X4(this.graph.links,(function(e){const t=e.source;const n=e.target;let 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++){const e=i[o];if(!e.isVirtual)continue;const a=this.downNodes.get(e)[0];if(a.isVirtual)for(r=o+1;r<i.length;++r){if(n=i[r],!n.isVirtual)continue;const e=this.downNodes.get(n)[0];if(e.isVirtual&&a.gridPosition>e.gridPosition){const n=a.gridPosition;a.gridPosition=e.gridPosition,e.gridPosition=n;const i=a.layerIndex;const r=e.layerIndex;this.layers[t+1][i]=e,this.layers[t+1][r]=a,a.layerIndex=r,e.layerIndex=i}}}const a=this._getLeftWing();const s=this._getRightWing();const l=this.placeLeftToRight(a);const c=this.placeRightToLeft(s);const d=new C6;X4(this.graph.nodes,(function(e){d.set(e,(l.get(e)+c.get(e))/2)}));const h=new C6;const u=new C6;for(t=0;t<this.layers.length;++t){i=this.layers[t];let e=-1;for(r=0;r<i.length;++r)n=i[r],h.set(n,0),u.set(n,!1),n.isVirtual&&(-1===e||e===r-1||(h.set(i[e],0),d.get(n)-d.get(i[e])===this.getMinDist(i[e],n)?u.set(i[e],!0):u.set(i[e],!1)),e=r)}X4([1,-1],(function(t){for(let n=1===t?0:this.layers.length-1;n>=0&&n<this.layers.length;n+=t){const i=this.layers[n];let r=this._firstVirtualNode(i);let o=null;let 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(d,null,o,t,a),e=0;e<a.length-1;++e)this.setMinDist(a[e],a[e+1],d.get(a[e+1])-d.get(a[e]));o&&this.setMinDist(a[a.length-1],o,d.get(o)-d.get(a[a.length-1]))}for(;o;){const n=this.nextVirtualNode(i,o);if(n){if(h.get(o)===t){r=o.layerIndex;const s=n.layerIndex;for(a=[],e=r+1;e<s;e++)a.push(i[e]);a.length>0&&this._sequencer(d,o,n,t,a),u.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(d,o,null,t,a),e=0;e<a.length-1;++e)this.setMinDist(a[e],a[e+1],d.get(a[e+1])-d.get(a[e]));this.setMinDist(o,a[0],d.get(a[0])-d.get(o))}}o=n}this.adjustDirections(n,t,h,u)}}),this);const p=this._isIncreasingLayout()?0:this.layers.length-1;const f=this._isIncreasingLayout()?1:-1;let m=0;function g(e,t){let n=Number.MIN_VALUE;for(let i=0;i<e.length;++i){const r=e[i];n=t._isVerticalLayout()?Math.max(n,r.height):Math.max(n,r.width)}return n}for(e=p;v=e,(_=this)._isIncreasingLayout()?v<_.layers.length:v>=0;e+=f){i=this.layers[e];const t=g(i,this);for(r=0;r<i.length;++r)n=i[r],this._isVerticalLayout()?(n.x=d.get(n),n.y=m+t/2):(n.x=m+t/2,n.y=d.get(n));m+=this.options.layerSeparation+t}var v,_}adjustDirections(e,t,n,i){if(e+t<0||e+t>=this.layers.length)return;let r=null,o=null;const a=this.layers[e+t];for(let s=0;s<a.length;++s){const l=a[s];if(l.isVirtual){const s=this.getNeighborOnLayer(l,e);if(s.isVirtual){if(r){let c=i.get(o);const d=this.layers[e];const h=o.layerIndex;const u=s.layerIndex;for(let e=h+1;e<u;++e)d[e].isVirtual&&(c=c&&i.get(d[e]));if(c){n.set(r,t);const e=r.layerIndex;const i=l.layerIndex;for(let r=e+1;r<i;++r)a[r].isVirtual&&n.set(a[r],t)}}r=l,o=s}}}}getNeighborOnLayer(e,t){let n=this.upNodes.get(e)[0];return n.layer===t?n:(n=this.downNodes.get(e)[0],n.layer===t?n:null)}_sequencer(e,t,n,i,r){if(1===r.length&&this._sequenceSingle(e,t,n,i,r[0]),r.length>1){const 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(e,t,n,i,r){const o=-1===i?this.downNodes.get(r):this.upNodes.get(r);const 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(e,t,n,i,r){const o=r.length,a=this.intDiv(o,2);const s=[];let l,c,d,h,u,p;for(l=0;l<a;++l){for(c=0,h=-1===i?this.downNodes.get(r[l]):this.upNodes.get(r[l]),d=0;d<h.length;++d)u=h[d],e.get(u)>=e.get(r[l])?c++:(c--,s.push({k:e.get(u)+this.getMinDist(r[l],r[a-1]),v:2}));s.push({k:e.get(r[l])+this.getMinDist(r[l],r[a-1]),v:c})}t&&s.push({k:e.get(t)+this.getMinDist(t,r[a-1]),v:Number.MAX_VALUE}),s.sort(this._positionDescendingComparer.bind(this));const f=[];for(l=a;l<o;++l){for(c=0,h=-1===i?this.downNodes.get(r[l]):this.upNodes.get(r[l]),d=0;d<h.length;++d)u=h[d],e.get(u)<=e.get(r[l])?c++:(c--,f.push({k:e.get(u)-this.getMinDist(r[l],r[a]),v:2}));f.push({k:e.get(r[l])-this.getMinDist(r[l],r[a]),v:c})}n&&f.push({k:e.get(n)-this.getMinDist(n,r[a]),v:Number.MAX_VALUE}),f.sort(this._positionAscendingComparer.bind(this));let m=0,g=0;const v=this.getMinDist(r[a-1],r[a]);for(;e.get(r[a])-e.get(r[a-1])<v;)if(m<g){if(0===s.length){e.set(r[a-1],e.get(r[a])-v);break}p=s.shift(),m+=p.v,e.set(r[a-1],p.k),e.set(r[a-1],Math.max(e.get(r[a-1]),e.get(r[a])-v))}else{if(0===f.length){e.set(r[a],e.get(r[a-1])+v);break}p=f.shift(),g+=p.v,e.set(r[a],p.k),e.set(r[a],Math.min(e.get(r[a]),e.get(r[a-1])+v))}for(l=a-2;l>=0;l--)e.set(r[l],Math.min(e.get(r[l]),e.get(r[a-1])-this.getMinDist(r[l],r[a-1])));for(l=a+1;l<o;l++)e.set(r[l],Math.max(e.get(r[l]),e.get(r[a])+this.getMinDist(r[l],r[a])))}placeLeft(e,t,n){let i=Number.NEGATIVE_INFINITY;X4(this._getComposite(e),(function(e){const 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),X4(this._getComposite(e),(function(e){t.set(e,i)}))}placeRight(e,t,n){let i=Number.POSITIVE_INFINITY;X4(this._getComposite(e),(function(e){const 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),X4(this._getComposite(e),(function(e){t.set(e,i)}))}leftSibling(e){const t=this.layers[e.layer],n=e.layerIndex;return 0===n?null:t[n-1]}rightSibling(e){const t=this.layers[e.layer];const n=e.layerIndex;return n===t.length-1?null:t[n+1]}_getComposite(e){return e.isVirtual?this._nodesInLink(e):[e]}arrangeNodes(){let 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],r.upstreamPriority=r.upstreamLinkCount,r.downstreamPriority=r.downstreamLinkCount;for(let t=0;t<2;t++){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)}let o=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],o=Math.min(o,r.gridPosition);if(o<0)for(t=0;t<this.layers.length;t++)for(i=this.layers[t],n=0;n<i.length;n++)r=i[n],r.gridPosition=r.gridPosition-o}layoutLayer(e,t){let n;let i;i=e?this.layers[n=t+1]:this.layers[n=t-1];const r=[];for(let e=0;e<i.length;e++)r.push(i[e]);r.sort((function(e,t){const n=(e.upstreamPriority+e.downstreamPriority)/2;const i=(t.upstreamPriority+t.downstreamPriority)/2;return Math.abs(n-i)<1e-4?0:n<i?1:-1})),X4(r,(function(e){let t=e.gridPosition;const n=this.calcBaryCenter(e);const 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(e,t,n){const i=t6(t,e);if(i===t.length-1)return e.gridPosition=e.gridPosition+.5,!0;const r=t[i+1];const 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(e,t,n){const i=t6(t,e);if(0===i)return e.gridPosition=e.gridPosition-.5,!0;const r=t[i-1];const 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(e,t){this.nodeToLinkMap.set(e,t),this.linkToNodeMap.containsKey(t)||this.linkToNodeMap.set(t,[]),this.linkToNodeMap.get(t).push(e)}_nodesInLink(e){return this.linkToNodeMap.get(this.nodeToLinkMap.get(e))}_dummify(){this.linkToNodeMap=new C6,this.nodeToLinkMap=new C6;const e=this.graph.links.slice(0);const t=this.layers;let n,i,r,o,a,s,l,c;const d=function(e,n,i){t[e].linksTo[n]=t[e].linksTo[n]||[],t[e].linksTo[n].push(i)};for(c=0;c<e.length;c++){const h=e[c];const u=h.source;const p=h.target;const f=u.layer;const m=p.layer;const g=u.gridPosition;const v=p.gridPosition;const _=(v-g)/Math.abs(m-f);let b=u;if(f-m>1){for(l=f-1;l>m;l--){for(r=new R6,r.x=u.x,r.y=u.y,r.width=u.width/100,r.height=u.height/100,n=t[l],i=(l-m)*_+g,i>n.length&&(i=n.length),g>=t[f].length-1&&v>=t[m].length-1?i=n.length:0===g&&0===v&&(i=0),r.layer=l,r.uBaryCenter=0,r.dBaryCenter=0,r.upstreamLinkCount=0,r.downstreamLinkCount=0,r.gridPosition=i,r.isVirtual=!0,s6(n,r,i),a=i+1;a<n.length;a++)o=n[a],o.gridPosition=o.gridPosition+1;s=new F6(b,r),s.depthOfDumminess=0,d(l-1,l,s),b=r,this.graph._addNode(r),this.graph.addLink(s),r.index=this.graph.nodes.length-1,this.mapVirtualNode(r,h)}d(m-1,m,s),h.changeSource(b),h.depthOfDumminess=f-m-1}else if(f-m<-1){for(l=f+1;l<m;l++){for(r=new R6,r.x=u.x,r.y=u.y,r.width=u.width/100,r.height=u.height/100,n=t[l],i=(l-f)*_+g,i>n.length&&(i=n.length),g>=t[f].length-1&&v>=t[m].length-1?i=n.length:0===g&&0===v&&(i=0),r.layer=l,r.uBaryCenter=0,r.dBaryCenter=0,r.upstreamLinkCount=0,r.downstreamLinkCount=0,r.gridPosition=i,r.isVirtual=!0,i=Math.floor(i),s6(n,r,i),a=i+1;a<n.length;a++)o=n[a],o.gridPosition=o.gridPosition+1;s=new F6(b,r),s.depthOfDumminess=0,d(l-1,l,s),b=r,this.graph._addNode(r),this.graph.addLink(s),r.index=this.graph.nodes.length-1,this.mapVirtualNode(r,h)}d(m-1,m,h),h.changeSource(b),h.depthOfDumminess=m-f-1}else d(f,m,h)}}_dedummify(){let e=!0;for(;e;){e=!1;for(let t=0;t<this.graph.links.length;t++){const n=this.graph.links[t];if(!n.depthOfDumminess)continue;const i=[];i.unshift({x:n.target.x,y:n.target.y}),i.unshift({x:n.source.x,y:n.source.y});let r=n;const o=n.depthOfDumminess;for(let e=0;e<o;e++){const e=r.source.incoming[0];i.unshift({x:e.source.x,y:e.source.y}),r=e}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(){let e,t=-1;let n=0;for(;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(e){if(0===e)return;const t=this.layers[e];let n,i,r;const o=new Y6;const a=this.layers[e-1];for(n=0;n<a.length;n++)o.add(a[n]);for(n=0;n<t.length;n++){const e=t[n];let a=0;let s=0;for(i=0;i<e.incoming.length;i++)r=e.incoming[i],o.contains(r.source)&&(s++,a+=r.source.gridPosition);for(i=0;i<e.outgoing.length;i++)r=e.outgoing[i],o.contains(r.target)&&(s++,a+=r.target.gridPosition);s>0?(e.uBaryCenter=a/s,e.upstreamLinkCount=s):(e.uBaryCenter=n,e.upstreamLinkCount=0)}}calcDownData(e){if(e===this.layers.length-1)return;const t=this.layers[e];let n,i,r;const o=new Y6;const a=this.layers[e+1];for(n=0;n<a.length;n++)o.add(a[n]);for(n=0;n<t.length;n++){const e=t[n];let a=0;let s=0;for(i=0;i<e.incoming.length;i++)r=e.incoming[i],o.contains(r.source)&&(s++,a+=r.source.gridPosition);for(i=0;i<e.outgoing.length;i++)r=e.outgoing[i],o.contains(r.target)&&(s++,a+=r.target.gridPosition);s>0?(e.dBaryCenter=a/s,e.downstreamLinkCount=s):(e.dBaryCenter=n,e.downstreamLinkCount=0)}}optimizeLayerCrossings(e,t){let n;let i;i=e?this.layers[n=t+1]:this.layers[n=t-1];const r=i.slice(0);e?this.calcUpData(n):this.calcDownData(n),i.sort(((e,t)=>{const n=this.calcBaryCenter(e),i=this.calcBaryCenter(t);if(Math.abs(n-i)<1e-4)return e.degree()===t.degree()?this.compareByIndex(e,t):e.degree()<t.degree()?1:-1;const r=1e3*(i-n);return r>0?-1:r<0?1:this.compareByIndex(e,t)}));let o,a=0;for(o=0;o<i.length;o++)i[o]!==r[o]&&a++;if(a>0){let e=0;for(o=0;o<i.length;o++){i[o].gridPosition=e++}}return a}_swapPairs(){const e=this.options.layeredIterations;let t=0;for(;!(t++>e);){const e=t%4<=1;const n=t%4==1;for(let t=e?0:this.layers.length-1;e?t<=this.layers.length-1:t>=0;t+=e?1:-1){const i=this.layers[t];let r=!1;let o=!0;let a=0;for(let s=0;s<i.length-1;s++){let l=0;let c=0;let d=0;if(o?(0!==t&&(l=this.countLinksCrossingBetweenTwoLayers(t-1,t)),t!==this.layers.length-1&&(c=this.countLinksCrossingBetweenTwoLayers(t,t+1)),e?l*=2:c*=2,d=l+c):d=a,0===d)continue;let h=i[s];let u=i[s+1];let p=h.gridPosition;let f=u.gridPosition;i[s]=u,i[s+1]=h,h.gridPosition=f,u.gridPosition=p,l=0,0!==t&&(l=this.countLinksCrossingBetweenTwoLayers(t-1,t)),c=0,t!==this.layers.length-1&&(c=this.countLinksCrossingBetweenTwoLayers(t,t+1)),e?l*=2:c*=2;const m=l+c;let g=!1;g=n?m>=d:m>d,g?(h=i[s],u=i[s+1],p=h.gridPosition,f=u.gridPosition,i[s]=u,i[s+1]=h,h.gridPosition=f,u.gridPosition=p,a=d,o=!1):(r=!0,o=!0)}r&&(t!==this.layers.length-1&&this.calcUpData(t+1),0!==t&&this.calcDownData(t-1))}}}countLinksCrossingBetweenTwoLayers(e,t){const n=this.layers[e].linksTo[t];let i,r,o,a,s,l,c,d;let h=0;const u=n.length;for(c=0;c<u;c++)for(i=n[c],d=c+1;d<u;d++){r=n[d],i.target.layer===t?(o=i.source,a=i.target):(o=i.target,a=i.source),r.target.layer===t?(s=r.source,l=r.target):(s=r.target,l=r.source);const e=o.gridPosition;const c=a.gridPosition;(e-s.gridPosition)*(c-l.gridPosition)<0&&h++}return h}calcBaryCenter(e){const t=e.upstreamLinkCount;const n=e.downstreamLinkCount;const i=e.uBaryCenter;const r=e.dBaryCenter;return t>0&&n>0?(i+r)/2:t>0?i:n>0?r:0}_gridPositionComparer(e,t){return e.gridPosition<t.gridPosition?-1:e.gridPosition>t.gridPosition?1:0}_positionAscendingComparer(e,t){return e.k<t.k?-1:e.k>t.k?1:0}_positionDescendingComparer(e,t){return e.k<t.k?1:e.k>t.k?-1:0}_firstVirtualNode(e){for(let t=0;t<e.length;t++)if(e[t].isVirtual)return t;return-1}compareByIndex(e,t){const n=e.index;const i=t.index;return n<i?1:n>i?-1:0}intDiv(e,t){return(e-e%t)/t}nextVirtualNode(e,t){for(let n=t.layerIndex+1;n<e.length;++n)if(e[n].isVirtual)return e[n];return null}}class A8{constructor(e){this.center=null,this.options=e}layout(e,t){if(this.graph=e,this.graph.nodes&&0!==this.graph.nodes.length){if(!e6(this.graph.nodes,t))throw new Error("The given root is not in the graph.");this.center=t,this.graph.cacheRelationships(),this.layoutSwitch()}}layoutLeft(e){this.setChildrenDirection(this.center,"Left",!1),this.setChildrenLayout(this.center,"Default",!1);let t,n,i,r=0,o=0;for(n=0;n<e.length;n++){i=e[n],i.TreeDirection="Left";const t=this.measure(i,Q6.Empty.bind(this));o=Math.max(o,t.width),r+=t.height+this.options.verticalSeparation}r-=this.options.verticalSeparation;const a=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];const r=new M6(a-i.Size.width,t);this.arrange(i,r),t+=i.Size.height+this.options.verticalSeparation}}layoutRight(e){this.setChildrenDirection(this.center,"Right",!1),this.setChildrenLayout(this.center,"Default",!1);let t,n,i,r=0,o=0;for(n=0;n<e.length;n++){i=e[n],i.TreeDirection="Right";const t=this.measure(i,Q6.Empty.bind(this));o=Math.max(o,t.width),r+=t.height+this.options.verticalSeparation}r-=this.options.verticalSeparation;const a=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];const r=new M6(a,t);this.arrange(i,r),t+=i.Size.height+this.options.verticalSeparation}}layoutUp(e){this.setChildrenDirection(this.center,"Up",!1),this.setChildrenLayout(this.center,"Default",!1);let t,n,i,r=0;for(i=0;i<e.length;i++){n=e[i],n.TreeDirection="Up";r+=this.measure(n,Q6.Empty.bind(this)).width+this.options.horizontalSeparation}r-=this.options.horizontalSeparation;let 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;const r=new M6(o,t);this.arrange(n,r),o+=n.Size.width+this.options.horizontalSeparation}}layoutDown(e){let t,n;this.setChildrenDirection(this.center,"Down",!1),this.setChildrenLayout(this.center,"Default",!1);let i=0;for(n=0;n<e.length;n++){t=e[n],t.treeDirection="Down";i+=this.measure(t,Q6.Empty.bind(this)).width+this.options.horizontalSeparation}i-=this.options.horizontalSeparation;let r=this.center.x+this.center.width/2-i/2;const o=this.center.y+this.options.verticalSeparation+this.center.height;for(n=0;n<e.length;n++){t=e[n];const i=new M6(r,o);this.arrange(t,i),r+=t.Size.width+this.options.horizontalSeparation}}layoutRadialTree(){this.setChildrenDirection(this.center,"Radial",!1),this.setChildrenLayout(this.center,"Default",!1),this.previousRoot=null;const e=this.options.startRadialAngle*n4;const t=this.options.endRadialAngle*n4;if(t<=e)throw new Error("Final angle should not be less than the start angle.");this.maxDepth=0,this.origin=new M6(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(e,t){F4(t)&&(t=0),this.setChildrenDirection(this.center,"Down",!1),this.setChildrenLayout(this.center,"Default",!1),this.setChildrenLayout(this.center,"Underneath",!1,t);let n,i,r=0;for(i=0;i<e.length;i++){n=e[i],n.TreeDirection="Down";r+=this.measure(n,Q6.Empty.bind(this)).width+this.options.horizontalSeparation}r-=this.options.horizontalSeparation,r-=e[e.length-1].width,r+=e[e.length-1].associatedShape.bounds().width;let o=this.center.x+this.center.width/2-r/2;const a=this.center.y+this.options.verticalSeparation+this.center.height;for(i=0;i<e.length;i++){n=e[i];const t=new M6(o,a);this.arrange(n,t),o+=n.Size.width+this.options.horizontalSeparation}}calculateAngularWidth(e,t){t>this.maxDepth&&(this.maxDepth=t);const n=0===t?0:Math.sqrt(2e6)/t;let i=0;if(e.children.length>0){for(let n=0,r=e.children.length;n<r;n++){const r=e.children[n];i+=this.calculateAngularWidth(r,t+1)}i=Math.max(n,i)}else i=n;return e.sectorAngle=i,i}sortChildren(e){let t,n=0;if(e.parents.length>1)throw new Error("Node is not part of a tree.");const i=e.parents[0];if(i){const t=new M6(i.x,i.y);const r=new M6(e.x,e.y);n=this.normalizeAngle(Math.atan2(t.y-r.y,t.x-r.x))}const r=e.children.length;if(0===r)return null;const o=[];const a=[];for(t=0;t<r;++t){const i=e.children[t];const r=new M6(i.x,i.y);a[t]=t,o[t]=this.normalizeAngle(-n+Math.atan2(r.y-r.y,r.x-r.x))}d6(o,a);const s=[];const l=e.children;for(t=0;t<r;++t)s.push(l[a[t]]);return s}normalizeAngle(e){for(;e>2*Math.PI;)e-=2*Math.PI;for(;e<0;)e+=2*Math.PI;return e}radialLayout(e,t,n,i){const r=i-n;const o=r/2;const a=e.sectorAngle;let s=0;const l=this.sortChildren(e);for(let e=0,i=l.length;e<i;e++){const i=l[e];const c=i;const d=c.sectorAngle/a;i.children.length>0&&this.radialLayout(i,t+this.options.radialSeparation,n+s*r,n+(s+d)*r),this.setPolarLocation(i,t,n+s*r+d*o),c.angle=d*r,s+=d}}setPolarLocation(e,t,n){e.x=this.origin.x+t*Math.cos(n),e.y=this.origin.y+t*Math.sin(n),e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height)}setChildrenDirection(e,t,n){const i=e.treeDirection;this.graph.depthFirstTraversal(e,(e=>{e.treeDirection=t})),n||(e.treeDirection=i)}setChildrenLayout(e,t,n,i){F4(i)&&(i=0);const r=e.childrenLayout;i>0?(this.graph.assignLevels(e),this.graph.depthFirstTraversal(e,(e=>{e.level>=i+1&&(e.childrenLayout=t)}))):(this.graph.depthFirstTraversal(e,(e=>{e.childrenLayout=t})),n||(e.childrenLayout=r))}measure(e,t){let n,i=0,r=0;let o=new Q6(0,0);if(!e)throw new Error("Node is not defined.");const a=e.associatedShape.bounds();const s=a.width;const l=a.height;if(1!==e.parents.length)throw new Error("Node not in a spanning tree.");const c=e.parents[0];if("Undefined"===e.treeDirection&&(e.treeDirection=c.treeDirection),U4(e.children))o=new Q6(Math.abs(s)<i4?50:s,Math.abs(l)<i4?25:l);else if(1===e.children.length){switch(e.treeDirection){case"Radial":n=this.measure(e.children[0],t),i=s+this.options.radialSeparation*Math.cos(e.AngleToParent)+n.width,r=l+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":n=this.measure(e.children[0],t),i=s+n.width+this.options.underneathHorizontalOffset,r=l+this.options.underneathVerticalTopOffset+n.height;break;case"Default":n=this.measure(e.children[0],t),i=s+this.options.horizontalSeparation+n.width,r=Math.max(l,n.height);break;default:throw new Error("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(s,n.width+this.options.underneathHorizontalOffset),r=l+this.options.underneathVerticalTopOffset+n.height;break;case"Default":n=this.measure(e.children[0],t),r=l+this.options.verticalSeparation+n.height,i=Math.max(s,n.width);break;default:throw new Error("Unhandled TreeDirection in the Down layout measuring.")}break;default:throw new Error("Unhandled TreeDirection in the layout measuring.")}o=new Q6(i,r)}else{let a,c;switch(e.treeDirection){case"Left":case"Right":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(i=s,r=l+this.options.underneathVerticalTopOffset,a=0;a<e.children.length;a++)c=e.children[a],n=this.measure(c,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=s,r=0,a=0;a<e.children.length;a++)c=e.children[a],n=this.measure(c,t),i=Math.max(i,s+this.options.horizontalSeparation+n.width),r+=n.height+this.options.verticalSeparation;r-=this.options.verticalSeparation;break;default:throw new Error("Unhandled TreeDirection in the Right layout measuring.")}break;case"Up":case"Down":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(i=s,r=l+this.options.underneathVerticalTopOffset,a=0;a<e.children.length;a++)c=e.children[a],n=this.measure(c,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,a=0;a<e.children.length;a++)c=e.children[a],n=this.measure(c,t),i+=n.width+this.options.horizontalSeparation,r=Math.max(r,n.height+this.options.verticalSeparation+l);i-=this.options.horizontalSeparation;break;default:throw new Error("Unhandled TreeDirection in the Down layout measuring.")}break;default:throw new Error("Unhandled TreeDirection in the layout measuring.")}o=new Q6(i,r)}return e.SectorAngle=Math.sqrt(i*i/4+r*r/4),e.Size=o,o}arrange(e,t){const n=e.associatedShape.bounds();let i,r,o,a,s;const l=n.width;const c=n.height;if(U4(e.children))e.x=t.x,e.y=t.y,e.BoundingRectangle=new A6(t.x,t.y,l,c);else{let n,d;let h;switch(e.treeDirection){case"Left":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=t,e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),d=t.y+c+this.options.underneathVerticalTopOffset,i=0;i<a.children.length;i++)a=a.children[i],n=h.x-a.associatedShape.width-this.options.underneathHorizontalOffset,r=new M6(n,d),this.arrange(a,r),d+=a.Size.height+this.options.underneathVerticalSeparation;break;case"Default":for(h=new M6(t.x+e.Size.width-l,t.y+(e.Size.height-c)/2),e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),n=h.x-this.options.horizontalSeparation,d=t.y,i=0;i<e.children.length;i++)a=e.children[i],r=new M6(n-a.Size.width,d),this.arrange(a,r),d+=a.Size.height+this.options.verticalSeparation;break;default:throw new Error("Unsupported TreeDirection")}break;case"Right":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=t,e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),n=t.x+l+this.options.underneathHorizontalOffset,d=t.y+c+this.options.underneathVerticalTopOffset,i=0;i<e.children.length;i++)a=e.children[i],r=new M6(n,d),this.arrange(a,r),d+=a.Size.height+this.options.underneathVerticalSeparation;break;case"Default":for(h=new M6(t.x,t.y+(e.Size.height-c)/2),e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),n=t.x+l+this.options.horizontalSeparation,d=t.y,i=0;i<e.children.length;i++)a=e.children[i],r=new M6(n,d),this.arrange(a,r),d+=a.Size.height+this.options.verticalSeparation;break;default:throw new Error("Unsupported TreeDirection")}break;case"Up":if(h=new M6(t.x+(e.Size.width-l)/2,t.y+e.Size.height-c),e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),Math.abs(h.x-t.x)<i4){for(s=0,i=0;i<e.children.length;i++)o=e.children[i],s+=o.Size.width+this.options.horizontalSeparation;s-=this.options.horizontalSeparation,n=t.x+(l-s)/2}else n=t.x;for(i=0;i<e.children.length;i++)a=e.children[i],d=h.y-this.options.verticalSeparation-a.Size.height,r=new M6(n,d),this.arrange(a,r),n+=a.Size.width+this.options.horizontalSeparation;break;case"Down":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=t,e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),n=t.x+this.options.underneathHorizontalOffset,d=t.y+c+this.options.underneathVerticalTopOffset,i=0;i<e.children.length;i++)a=e.children[i],r=new M6(n,d),this.arrange(a,r),d+=a.Size.height+this.options.underneathVerticalSeparation;break;case"Default":if(h=new M6(t.x+(e.Size.width-l)/2,t.y),e.x=h.x,e.y=h.y,e.BoundingRectangle=new A6(e.x,e.y,e.width,e.height),Math.abs(h.x-t.x)<i4){for(s=0,i=0;i<e.children.length;i++)o=e.children[i],s+=o.Size.width+this.options.horizontalSeparation;s-=this.options.horizontalSeparation,n=t.x+(l-s)/2}else n=t.x;for(i=0;i<e.children.length;i++)a=e.children[i],d=h.y+this.options.verticalSeparation+c,r=new M6(n,d),this.arrange(a,r),n+=a.Size.width+this.options.horizontalSeparation;break;default:throw new Error("Unsupported TreeDirection")}break;case"None":break;default:throw new Error("Unsupported TreeDirection")}}}layoutSwitch(){if(!this.center)return;if(U4(this.center.children))return;let e=this.options.subtype;let t,n,i,r;F4(e)&&(e="Down");const o=this.center.children;switch(e.toLowerCase()){case"radial":case"radialtree":this.layoutRadialTree();break;case"mindmaphorizontal":case"mindmap":t=this.center.children,1===this.center.children.length?this.layoutRight(t):(r=o.length/2,n=i6(this.center.children,(function(e){return t6(o,e)<r})),i=i6(this.center.children,(function(e){return t6(o,e)>=r})),this.layoutLeft(n),this.layoutRight(i));break;case"mindmapvertical":t=this.center.children,1===this.center.children.length?this.layoutDown(t):(r=o.length/2,n=i6(this.center.children,(function(e){return t6(o,e)<r})),i=i6(this.center.children,(function(e){return t6(o,e)>=r})),this.layoutUp(n),this.layoutDown(i));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 new Error("The tip-over level should be a positive integer.");this.tipOverTree(this.center.children,this.options.tipOverTreeStartLevel)}}}class D8 extends B6{constructor(e){if(super(),F4(e))throw new Error("No diagram specified.");this.diagram=e}layout(e){this.transferOptions(e);const t=new N6(this.diagram);this.graph=t.convert();const n=this.layoutComponents();return new H6(this.diagram,n)}layoutComponents(){if(this.graph.isEmpty())return;const e=this.graph.getConnectedComponents();if(U4(e))return;const t=new A8(this.options);const n=[];for(let i=0;i<e.length;i++){const r=e[i];const o=this.getTree(r);if(!o)throw new Error("Failed to find a spanning tree for the component.");const a=o.root;const s=o.tree;t.layout(s,a),n.push(s)}return this.gridLayoutComponents(n)}getTree(e){let t=null;if(this.options.roots&&this.options.roots.length>0)for(let n=0,i=e.nodes.length;n<i;n++){const i=e.nodes[n];for(let e=0;e<this.options.roots.length;e++){if(this.options.roots[e]===i.associatedShape){t=i;break}}}if(!t&&(t=e.root(),!t))throw new Error("Unable to find a root for the tree.");return this.getTreeForRoot(e,t)}getTreeForRoot(e,t){const n=e.getSpanningTree(t);return F4(n)||n.isEmpty()?null:{tree:n,root:n.root()}}}class E8{constructor(e,t){this.diagram=e,this.options=P6({},this.options,t),this.visual=new Q5,this.diagram._adorners.push(this)}refresh(){}}class I8{constructor(e,t,n){this.item=e,this._undoSource=t,this._undoTarget=n,this._redoSource=e.source(),this._redoTarget=e.target(),this.title=T4}undo(){this.item._updateConnector(this._undoSource,x4),this.item._updateConnector(this._undoTarget,C4),this.item.updateModel()}redo(){this.item._updateConnector(this._redoSource,x4),this.item._updateConnector(this._redoTarget,C4),this.item.updateModel()}}function z8(e){return e.options.name.toLowerCase()===s4.toLowerCase()}function P8(e,t){let n,i,r=A4;for(let o=0;o<t.length;o++)if(i=t[o],!z8(i)){const t=e.distanceTo(i.position());t<r&&(r=t,n=i)}return n}function L8(e,t){const n=[];let i,r;const o=e.drawingContainer().children;const a=o.length;for(i=0;i<t.length;i++){r=t[i];for(let e=0;e<a;e++)if(o[e]===r.drawingContainer()){n.push(e);break}}return n}function B8(e){const t={};return H4((e=e||{}).text)&&null!==e.text&&(t.text=e.text),H4(e.x)&&null!==e.x&&(t.x=e.x),H4(e.y)&&null!==e.y&&(t.y=e.y),H4(e.width)&&null!==e.width&&(t.width=e.width),H4(e.height)&&null!==e.height&&(t.height=e.height),H4(e.type)&&null!==e.type&&(t.type=e.type),t}var H8;!function(e){e.Terminator="Terminator",e.Process="Process",e.Decision="Decision",e.PredefinedProcess="PredefinedProcess",e.Document="Document",e.MultipleDocuments="MultipleDocuments",e.ManualInputOutput="ManualInputOutput",e.Preparation="Preparation",e.ManualOperation="ManualOperation",e.InternalStorage="InternalStorage",e.Display="Display",e.DirectAccessStorage="DirectAccessStorage",e.Database="Database",e.OnPageConnector="OnPageConnector",e.OffPageConnector="OffPageConnector",e.DataInputOutput="DataInputOutput",e.SummingJunction="SummingJunction",e.LogicalOr="LogicalOr",e.Merge="Merge",e.Extract="Extract",e.DataStorage="DataStorage",e.Delay="Delay",e.Sort="Sort",e.Collate="Collate"}(H8||(H8={}));const R8=[{name:"top"},{name:"bottom",position:function(e){const t=e.bounds().height;const n=t*e.shapeVisual.options.waveRatio;const i=e.getPosition("top");return i.y+=t-.4*n,i}},{name:"left"},{name:"right"},{name:"auto"}];const F8=[{name:"top"},{name:"bottom"},{name:"left",position:function(e){const t=e.getPosition("left");const n=e.bounds();return t.x+=n.width/4-.6*e.shapeVisual.options.cornerRadius*(n.width/n.height),t}},{name:"right",position:function(e){const t=e.getPosition("right");const n=e.bounds();return t.x-=n.width/4-.6*e.shapeVisual.options.cornerRadius*(n.width/n.height),t}},{name:"auto"}];const O8={[H8.Extract]:F8,[H8.Merge]:F8,[H8.Document]:R8,[H8.MultipleDocuments]:R8,[H8.DataInputOutput]:[{name:"top"},{name:"bottom"},{name:"left",position:function(e){const t=e.getPosition("left");return t.x+=e.bounds().width*e.shapeVisual.options.slantRatio/2-e.shapeVisual.options.cornerRadius/5,t}},{name:"right",position:function(e){const t=e.getPosition("right");return t.x-=e.bounds().width*e.shapeVisual.options.slantRatio/2-e.shapeVisual.options.cornerRadius/5,t}},{name:"auto"}],[H8.ManualOperation]:[{name:"top"},{name:"bottom"},{name:"left",position:function(e){const t=e.getPosition("left");return t.x+=e.bounds().width*e.shapeVisual.options.baseShrinkRatio/(4+e.shapeVisual.options.cornerRadius/10),t}},{name:"right",position:function(e){const t=e.getPosition("right");return t.x-=e.bounds().width*e.shapeVisual.options.baseShrinkRatio/(4+e.shapeVisual.options.cornerRadius/10),t}},{name:"auto"}],[H8.ManualInputOutput]:[{name:"top",position:function(e){const t=e.getPosition("top");return t.y+=e.bounds().height*e.shapeVisual.options.topSlantRatio/2,t}},{name:"bottom"},{name:"left"},{name:"right"},{name:"auto"}],[H8.DataStorage]:[{name:"top"},{name:"bottom"},{name:"left"},{name:"right",position:function(e){const t=e.bounds().width;const n=e.getPosition("right");return n.x-=t*e.shapeVisual.options.ellipseRadiusXRatio,n}},{name:"auto"}]};class V8{constructor(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(let e=0;e<this.shapes.length;e++)this.redoRotates.push(this.redoAngle)}undo(){let e,t;for(e=0;e<this.shapes.length;e++)t=this.shapes[e],t.rotate(this.undoRotates[e],this.center,!1),"layout"in t&&t.layout(t),t.updateModel();this.adorner&&(this.adorner._initialize(),this.adorner.refresh())}redo(){let e,t;for(e=0;e<this.shapes.length;e++)t=this.shapes[e],t.rotate(this.redoRotates[e],this.center,!1),"layout"in t&&t.layout(t),t.updateModel();this.adorner&&(this.adorner._initialize(),this.adorner.refresh())}}const N8={width:7,height:7,fill:{color:"Yellow"},hover:{}};class $8{constructor(e,t){this.options=P6({},N8,t),this.connections=[],this.shape=e}position(){return this.options.position?this.options.position(this.shape):this.shape.getPosition(this.options.name)}toJSON(){return{shapeId:this.shape.toString(),connector:this.options.name}}static parse(e,t){const n=t.split(":"),i=n[0],r=n[1]||s4;for(let t=0;t<e.shapes.length;t++){const n=e.shapes[t];if(n.options.id===i)return n.getConnector(r.trim())}}}const U8=[{name:l4},{name:h4},{name:d4},{name:c4},{name:s4,position:function(e){return e.getPosition("center")}}];const W8=function(e){const t={type:"rectangle",path:"",autoSize:!0,visual:null,x:0,y:0,minWidth:20,minHeight:20,width:100,height:100,cornerRadius:0,hover:{},editable:{connect:!0,tools:[]},connectors:U8,rotation:{angle:0}};return W4(t,e),t};let j8={compile:function(e,t){return e}};class q8{static register(e){j8=e}static compile(e,t={}){return j8.compile(e,t)}}function G8(e={}){let t;return e.visual?e.visual=t=q8.compile(e.visual,e):e.template?e.template=t=q8.compile(e.template,e):R4(e.content)&&(t=e.content),t}function K8(){const e=function(e){let t=!1;const 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(const r in n){if(!Object.prototype.hasOwnProperty.call(n,r))continue;if(e.match(n[r])){if("windows"===r&&"plugins"in navigator)return!1;t={},t.device=r,t.name=Y8(r,i),t[t.name]=!0;break}}return t}(navigator.userAgent);const t={};return t.mobileOS=e,t}function Y8(e,t,n){for(const n in t)if(t[n].test(e))return n;return void 0!==n?n:e}const Q8=Object.assign;const X8=()=>(new Date).getTime();const Z8=(e,t)=>{e.classList.add(t)};const J8=e=>{const t=document.createElement("div");return t.innerHTML=e,t.firstChild};const e9=(e,t)=>{t.insertBefore(e,t.firstChild)};const t9={hover:{},cursor:o4.grip,content:{align:"center middle"},selectable:!0,serializable:!0,enable:!0};class n9 extends v6{constructor(e){super(),this.dataItem=(e||{}).dataItem,this.options=P6({id:k6()},t9,e),this.isSelected=!1,this.visual=new Q5({id:this.options.id,autoSize:this.options.autoSize}),this.id=this.options.id,this._template()}_getCursor(e){return this.adorner?this.adorner._getCursor(e):this.options.cursor}visible(e){if(F4(e))return this.visual.visible();this.visual.visible(e)}bounds(e){return F4(e),null}refresh(){this.visual.redraw()}position(e){this.options.x=e.x,this.options.y=e.y,this.visual.position(e)}toString(){return this.options.id}serialize(){const e=P6({},{options:this.options});return this.dataItem&&(e.dataItem=this.dataItem.toString()),e}_content(e){if(void 0!==e){const t=this.options;N4(e)?t.content.text=e:P6(t.content,e);const n=t.content;this._contentVisual?this._updateContentVisual(n):this._createContentVisual(n)}return this.options.content.text}_createContentVisual(e){if(e.text){e.shapeSize=this.bounds();const t="wrap"!==e.textWrap?x8:T8;this._contentVisual=new t(e),this._contentVisual._includeInBBox=!1,this.visual.append(this._contentVisual)}}_updateContentVisual(e){this._contentVisual.redraw(e)}_hitTest(e){const t=this.bounds();return this.visible()&&t.contains(e)&&this.options.enable}_template(){if(this.options.content.template){const e=this.dataItem||{};const t=G8(Q8({},this.options.content,{dataItem:this.dataItem||this.options.dataItem}));R4(t)?this.options.content.text=t(e):N4(t)&&(this.options.content.text=t)}}_canSelect(){return!1!==this.options.selectable}toJSON(){return{id:this.options.id}}}const i9={Terminator:K5,Process:v8,Decision:L5,PredefinedProcess:f8,Document:q5,MultipleDocuments:G5,ManualInputOutput:r8,Preparation:g8,ManualOperation:a8,InternalStorage:J5,Display:V5,DirectAccessStorage:F5,Database:I5,OnPageConnector:M5,OffPageConnector:d8,DataInputOutput:D5,SummingJunction:w8,LogicalOr:l8,Merge:s8,Extract:Y5,DataStorage:P5,Delay:H5,Sort:b8,Collate:T5};class r9 extends n9{constructor(e,t){super(e),this.name="Shape",this.options=P6({},this.options,W8({connectors:void 0}),e),this.diagram=t,this.updateOptionsFromModel(),e=this.options,this.connectors=[],this.type=e.type,this.createShapeVisual(),this.updateBounds(),this.content(this.content()),this._createConnectors()}_setOptionsFromModel(e){const t=B8(e||this.dataItem);this.options=P6({},this.options,t),this.redrawVisual()}updateOptionsFromModel(e,t){if(this.diagram&&this.diagram._isEditable){const n=B8(e||this.dataItem);if(e&&t)if(e6(["x","y","width","height"],t)){const n=this.bounds();n[t]=e[t],this.bounds(n)}else this.options.visual?this._redrawVisual():n.type&&(this.options=P6({},this.options,n),this._redrawVisual()),this.options.content&&(this._template(),this.content(this.options.content));else this.options=P6({},this.options,n)}}_redrawVisual(){this.visual.clear(),this._contentVisual=null,this.options.dataItem=this.dataItem,this.createShapeVisual(),this.updateBounds()}redrawVisual(){this._redrawVisual(),this.options.content&&(this._template(),this.content(this.options.content))}updateModel(e){const t=this.diagram;t&&t._isEditable&&t.updateShapeModel(this,e)}updateBounds(){const e=this.visual._measure(!0);const t=this.options;this.bounds(new A6(t.x,t.y,e.width,e.height)),this._rotate(),this._alignContent()}content(e){const t=this._content(e);return this._alignContent(),t}_alignContent(){const e=this.options.content||{};const t=this._contentVisual;if(t&&e.align&&!1!==t.alignable){const n=this.visual._measure();const i=new D6(n);const r=t.drawingElement.bbox(null);const o=new A6(0,0,r.width(),r.height());const a=i.align(o,e.align);t.position(a.topLeft())}}_createConnectors(){const e=this.options,t=e.connectors||O8[e.type]||U8,n=t.length,i=e.connectorDefaults;let r,o;for(o=0;o<n;o++)r=new $8(this,P6({},i,t[o])),this.connectors.push(r)}bounds(e){let t;if(e)if(N4(e))switch(e){case P4:t=this._transformedBounds();break;case"absolute":{t=this._transformedBounds();const e=this.diagram._pan;t.x+=e.x,t.y+=e.y;break}case k4: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(e){const t=this.options;const n=e.topLeft();const i=t.x=n.x;const r=t.y=n.y;const o=t.width=Math.max(e.width,t.minWidth);const a=t.height=Math.max(e.height,t.minHeight);this._bounds=new A6(i,r,o,a),this.visual.redraw({x:i,y:r,width:o,height:a})}position(e){if(!e)return this._bounds.topLeft();this.bounds(new A6(e.x,e.y,this._bounds.width,this._bounds.height))}clone(){const e=this.serialize();return e.options.id=k6(),this.diagram&&this.diagram._isEditable&&H4(this.dataItem)&&(e.options.dataItem=this.diagram.options.cloneDataItem(this.dataItem)),new r9(e.options,void 0)}select(e){const t=this.diagram;let n,i;if(F4(e)&&(e=!0),this._canSelect()&&this.isSelected!==e)return n=[],i=[],this.isSelected=e,this.isSelected?(t._selectedItems.push(this),n.push(this)):(J4(t._selectedItems,this),i.push(this)),t._internalSelection||t._selectionChanged(n,i),!0}rotate(e,t,n){const i=this.visual.rotate();if(void 0!==e){!1!==n&&this.diagram&&this.diagram.undoRedoService&&e!==i.angle&&this.diagram.undoRedoService.add(new V8(this.diagram._resizingAdorner,[this],[i.angle]),!1);const r=this.bounds(),o=new M6(r.width/2,r.height/2);let a,s;t&&(a=e-i.angle,s=r.center().rotate(a,t).minus(o),this._rotationOffset=this._rotationOffset.plus(s.minus(r.topLeft())),this.position(s)),this.visual.rotate(e,o),this.options.rotation.angle=e,this.diagram&&this.diagram._connectorsAdorner&&this.diagram._connectorsAdorner.refresh(),this.refreshConnections(),this.diagram&&this.diagram.trigger(m4,{item:this})}return i}connections(e){const t=[];let n,i,r,o,a;for(n=0;n<this.connectors.length;n++)for(a=this.connectors[n],o=a.connections,i=0;i<o.length;i++)if(r=o[i],"out"===e){const e=r.source();e.shape&&e.shape===this&&t.push(r)}else if("in"===e){const e=r.target();e.shape&&e.shape===this&&t.push(r)}else t.push(r);return t}refreshConnections(){this.connections().forEach((function(e){e.refresh()}))}getConnector(e){let t,n;if(!N4(e))return e instanceof M6?P8(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],n.options.name.toLocaleLowerCase()===e)return n}getPosition(e){const t=this.bounds(),n=e.charAt(0).toLowerCase()+e.slice(1);return R4(t[n])?this._transformPoint(t[n]()):t.center()}redraw(e){if(e){let t=this.options;let n;this.shapeVisual.redraw(this._visualOptions(e)),this._diffNumericOptions(e,[G3,K3,Y3,Q3])&&(this.bounds(new A6(t.x,t.y,t.width,t.height)),n=!0),e.connectors&&(t.connectors=e.connectors,this._updateConnectors()),t=P6(t,e),(e.rotation||n)&&this._rotate(),t.content&&this.content(t.content)}}_updateConnectors(){const e=this.connections();let t;let n;let i;this.connectors=[],this._createConnectors();for(let r=0;r<e.length;r++)t=e[r],n=t.source(),i=t.target(),n.shape&&n.shape===this?t.source(this.getConnector(n.options.name)||null):i.shape&&i.shape===this&&t.target(this.getConnector(i.options.name)||null),t.updateModel()}_diffNumericOptions(e,t){return t5.call(this,e,t)}_visualOptions(e){return{cornerRadius:e.cornerRadius,data:e.path,source:e.source,hover:e.hover,fill:e.fill,stroke:e.stroke,dataItem:this.dataItem||(null==e?void 0:e.dataItem)}}_triggerBoundsChange(){this.diagram&&this.diagram.trigger(g4,{item:this,bounds:this._bounds.clone()})}_transformPoint(e){const t=this.rotate(),n=this.bounds().topLeft();return t.angle&&e.rotate(t.angle,t.center().plus(n)),e}_transformedBounds(){const e=this.bounds(),t=e.topLeft(),n=e.bottomRight();return A6.fromPoints(this.diagram.modelToView(t),this.diagram.modelToView(n))}_rotatedBounds(){const e=this.bounds().rotatedBounds(this.rotate().angle),t=e.topLeft(),n=e.bottomRight();return A6.fromPoints(t,n)}_rotate(){const e=this.options.rotation;e&&e.angle&&this.rotate(e.angle),this._rotationOffset=new M6}_hover(e){const t=this.options,n=t.hover;let i=t.stroke,r=t.fill;e&&B4(n.stroke)&&(i=P6({},i,n.stroke)),e&&B4(n.fill)&&(r=n.fill),this.shapeVisual.redraw({stroke:i,fill:r}),t.editable&&t.editable.connect&&this.diagram._showConnectors(this,e)}_hitTest(e){if(this.visible()){const t=this.bounds(),n=this.rotate().angle;let i;if(e.isEmpty&&!e.isEmpty())return U6.rects(e,t,n||0);if(i=e.clone().rotate(n,t.center()),t.contains(i))return this}}toJSON(){return{shapeId:this.options.id}}createShapeVisual(){const e=this.options;const t=this._visualOptions(e);const n=e.visual?q8.compile(e.visual,e):e.visual;const i=(e.type+"").toLocaleLowerCase();let r;t.width=e.width,t.height=e.height,R4(n)?r=n.call(this,e):t.data?(r=new h8(t),function(e){const t=e.drawingContainer().clippedBBox(null);0===t.origin.x&&0===t.origin.y||e.position(-t.origin.x,-t.origin.y)}(r)):r="rectangle"===i?new x5(t):"circle"===i?new w5(t):"text"===i?new x8(t):"image"===i?new X5(t):i9[e.type]?new i9[e.type](t):new h8(t),this.shapeVisual=r,this.visual.append(this.shapeVisual)}}class o9 extends E8{constructor(e,t){t=P6({handles:{}},t),super(e.diagram,t),this.connection=e;const n=this.connection.diagram;this._ts=n.toolService;const i=this.connection.sourcePoint();const r=this.connection.targetPoint();this.spVisual=new w5(P6(this.options.handles,{center:i})),this.epVisual=new w5(P6(this.options.handles,{center:r})),this.visual.append(this.spVisual),this.visual.append(this.epVisual)}_getCursor(){return o4.move}start(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(e,t){switch(e){case-1:this.connection.source(t);break;case 1:this.connection.target(t);break;default:{const e=t.minus(this.startPoint);this.startPoint=t,this.connection.sourceConnector||this.connection.source(this.connection.sourcePoint().plus(e)),this.connection.targetConnector||this.connection.target(this.connection.targetPoint().plus(e));break}}return this.refresh(),!0}stop(e){const t=this.diagram.toolService,n=t.hoveredItem;let i;return i=t._hoveredConnector?t._hoveredConnector._c:n&&n instanceof r9?n.getConnector(s4)||n.getConnector(e):e,-1===this.handle?this.connection.source(i):1===this.handle&&this.connection.target(i),this.handle=void 0,this._ts._connectionManipulation(),new I8(this.connection,this._initialSource,this._initialTarget)}_hitTest(e){const t=this.connection.sourcePoint();const n=this.connection.targetPoint();const i=this.options.handles.width/2+a4;const r=this.options.handles.height/2+a4;const o=t.distanceTo(e);const a=n.distanceTo(e);const s=new A6(t.x,t.y).inflate(i,r).contains(e);const l=new A6(n.x,n.y).inflate(i,r).contains(e);let c=0;return s&&(!l||o<a)?c=-1:l&&(!s||a<o)&&(c=1),c}refresh(){this.spVisual.redraw({center:this.diagram.modelToLayer(this.connection.sourcePoint())}),this.epVisual.redraw({center:this.diagram.modelToLayer(this.connection.targetPoint())})}}class a9{constructor(e){this.options=P6({},e.options),this._c=e,this.visual=new w5(this.options),this.refresh()}_hover(e){const t=this.options,n=t.hover;let i=t.stroke,r=t.fill;e&&B4(n.stroke)&&(i=P6({},i,n.stroke)),e&&B4(n.fill)&&(r=n.fill),this.visual.redraw({stroke:i,fill:r})}refresh(){const e=this._c.shape.diagram.modelToView(this._c.position()),t=e.minus(this._c.shape.bounds("transformed").topLeft()),n=new A6(e.x,e.y,0,0);n.inflate(this.options.width/2,this.options.height/2),this._visualBounds=n,this.visual.redraw({center:new M6(t.x,t.y)})}_hitTest(e){const t=this._c.shape.diagram.modelToView(e);return this._visualBounds.contains(t)}}class s9 extends E8{constructor(e,t){super(e,t),this._refreshHandler=e=>{e.item===this.shape&&this.refresh()}}show(e){this._visible=!0,this.shape=e,this.diagram.bind(g4,this._refreshHandler),this.connectors=[],this._clearVisual();const t=e.connectors.length;for(let n=0;n<t;n++){const t=new a9(e.connectors[n]);this.connectors.push(t),this.visual.append(t.visual)}this.visual.visible(!0),this.refresh()}_clearVisual(){this.diagram._cachedTouchTarget?this._keepCachedTouchTarget():this.visual.clear()}_keepCachedTouchTarget(){const e=this.visual.children;const t=e.length;const n=n6(this.diagram._cachedTouchTarget,e);for(let i=t-1;i>=0;i--)i!==n&&this.visual.remove(e[i])}destroy(){this.diagram.unbind(g4,this._refreshHandler),this.shape=void 0,this._visible=void 0,this.visual.visible(!1)}_hitTest(e){let t,n;for(n=0;n<this.connectors.length;n++)if(t=this.connectors[n],t._hitTest(e)){t._hover(!0),this.diagram.toolService._hoveredConnector=t;break}}refresh(){if(this.shape){let e=this.shape.bounds();e=this.diagram.modelToLayer(e),this.visual.position(e.topLeft()),this.connectors.forEach((function(e){e.refresh()}))}}}function l9(e){const t=e.options.editable;return t&&!1!==t.drag}class c9{constructor(e,t,n){this.shapes=e,this.undoStates=t,this.title="Transformation",this.redoStates=[],this.adorner=n;for(let e=0;e<this.shapes.length;e++){const t=this.shapes[e];this.redoStates.push(t.bounds())}}undo(){for(let e=0;e<this.shapes.length;e++){const t=this.shapes[e];t.bounds(this.undoStates[e]),"layout"in t&&t.layout(t,this.redoStates[e],this.undoStates[e]),t.updateModel()}this.adorner&&(this.adorner.refreshBounds(),this.adorner.refresh())}redo(){for(let e=0;e<this.shapes.length;e++){const t=this.shapes[e];t.bounds(this.redoStates[e]),"layout"in t&&t.layout(t,this.undoStates[e],this.redoStates[e]),t.updateModel()}this.adorner&&(this.adorner.refreshBounds(),this.adorner.refresh())}}const d9={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:X3}},offset:10};class h9 extends E8{constructor(e,t){super(e,t=P6({},d9,t)),this._manipulating=!1,this.map=[],this.shapes=[],this.shapeStates=[],this._initSelection(),this._createHandles(),this.redraw(),this.diagram.bind("select",(()=>{this._initialize()})),this._refreshHandler=()=>{this._internalChange||(this.refreshBounds(),this.refresh())},this._rotatedHandler=()=>{1===this.shapes.length&&(this._angle=this.shapes[0].rotate().angle),this._refreshHandler()},this.diagram.bind(g4,this._refreshHandler).bind(m4,this._rotatedHandler),this.refreshBounds(),this.refresh()}_initSelection(){const e=this.diagram.options.selectable;const t=P6({},this.options.selectable,e);this.rect=new x5(t),this.visual.append(this.rect)}_resizable(){return this.options.editable&&!1!==this.options.editable.resize}_handleOptions(){return(this.options.editable.resize||{}).handles||this.options.handles}_createHandles(){let 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 x5(e),t.drawingElement._hover=this._hover.bind(this),this.map.push({x:i,y:n,visual:t}),this.visual.append(t))}bounds(e){if(!e)return this._bounds;this._innerBounds=e.clone(),this._bounds=this.diagram.modelToLayer(e).inflate(this.options.offset,this.options.offset)}_hitTest(e){const t=this.map.length;let n,i,r,o,a=this.diagram.modelToLayer(e);if(this._angle&&(a=a.clone().rotate(this._angle,this._bounds.center())),this._resizable())for(n=0;n<t;n++)if(o=this.map[n],i=new M6(o.x,o.y),r=this._getHandleBounds(i),r.offset(this._bounds.x,this._bounds.y),r.contains(a))return i;if(this._bounds.contains(a))return new M6(0,0)}_getHandleBounds(e){if(this._resizable()){const t=this._handleOptions(),n=t.width,i=t.height,r=new A6(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(e){let t=this._hitTest(e);if(t&&t.x>=-1&&t.x<=1&&t.y>=-1&&t.y<=1&&this._resizable()){const e=this._angle;if(e&&(t.rotate(e,new M6(0,0)),t=new M6(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?o4.move:o4.select}_initialize(){let e,t;const n=this.diagram.select();for(this.shapes=[],e=0;e<n.length;e++)t=n[e],t instanceof r9&&(this.shapes.push(t),t._rotationOffset=new M6);this._angle=1===this.shapes.length?this.shapes[0].rotate().angle:0,this._startAngle=this._angle,this._rotates(),this._positions(),this.refreshBounds(),this.refresh(),this.redraw()}_rotates(){let e,t;for(this.initialRotates=[],e=0;e<this.shapes.length;e++)t=this.shapes[e],this.initialRotates.push(t.rotate().angle)}_positions(){let e,t;for(this.initialStates=[],e=0;e<this.shapes.length;e++)t=this.shapes[e],this.initialStates.push(t.bounds())}_hover(e,t){if(this._resizable()){const n=this._handleOptions(),i=n.hover;let r=n.stroke,o=n.fill;e&&B4(i.stroke)&&(r=P6({},r,i.stroke)),e&&B4(i.fill)&&(o=i.fill),t.stroke(r.color,r.width,r.opacity),t.fill(o.color,o.opacity)}}start(e){this._sp=e,this._cp=e,this._lp=e,this._manipulating=!0,this._internalChange=!0,this.shapeStates=[];for(let e=0;e<this.shapes.length;e++){const t=this.shapes[e];this.shapeStates.push(t.bounds())}}redraw(){let e,t;const n=this._resizable();for(e=0;e<this.map.length;e++)t=this.map[e],t.visual.visible(n)}angle(e){return H4(e)&&(this._angle=e),this._angle}rotate(){const e=this._innerBounds.center();let t=this.angle();this._internalChange=!0;for(let n=0;n<this.shapes.length;n++){const i=this.shapes[n];t=(t+this.initialRotates[n]-this._startAngle)%360,i.rotate(t,e)}this.refresh()}move(e,t){let n,i,r,o,a,s,l,c,d,h,u,p=new M6,f=new M6,m=0;if(-2===e.y&&-1===e.x){for(o=this._innerBounds.center(),this._angle=this._truncateAngle(Q4(o,t)),s=0;s<this.shapes.length;s++)a=this.shapes[s],l=(this._angle+this.initialRotates[s]-this._startAngle)%360,a.rotate(l,o),Object.prototype.hasOwnProperty.call(a,"layout")&&a.layout(a),this._rotating=!0;this.refresh()}else{if(this.shouldSnap()){const e=this._truncateDistance(t.minus(this._lp));if(0===e.x&&0===e.y)return void(this._cp=t);n=e,this._lp=new M6(this._lp.x+e.x,this._lp.y+e.y)}else n=t.minus(this._cp);for(this.isDragHandle(e)?(f=p=n,i=!0):(this._angle&&n.rotate(this._angle,new M6(0,0)),-1===e.x?p.x=n.x:1===e.x&&(f.x=n.x),-1===e.y?p.y=n.y:1===e.y&&(f.y=n.y)),i||(d=function(e,t){let 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),h=(this._innerBounds.width+n.x*e.x)/this._innerBounds.width,u=(this._innerBounds.height+n.y*e.y)/this._innerBounds.height),s=0;s<this.shapes.length;s++){if(a=this.shapes[s],r=a.bounds(),i){if(!l9(a))continue;c=this._displaceBounds(r,p,f,i)}else{c=r.clone(),c.scale(h,u,d,this._innerBounds.center(),a.rotate().angle);const e=c.center();e.rotate(-this._angle,r.center()),c=new A6(e.x-c.width/2,e.y-c.height/2,c.width,c.height)}if(c.width>=a.options.minWidth&&c.height>=a.options.minHeight){const e=r;a.bounds(c),Object.prototype.hasOwnProperty.call(a,"layout")&&a.layout(a,e,c),e.width===c.width&&e.height===c.height||a.rotate(a.rotate().angle),m+=1}}m&&(m===s?(c=this._displaceBounds(this._innerBounds,p,f,i),this.bounds(c)):this.refreshBounds(),this.refresh()),this._positions()}this._cp=t}isDragHandle(e){return 0===e.x&&0===e.y}cancel(){const e=this.shapes;const t=this.shapeStates;for(let n=0;n<e.length;n++)e[n].bounds(t[n]);this.refreshBounds(),this.refresh(),this._manipulating=void 0,this._internalChange=void 0,this._rotating=void 0}_truncatePositionToGuides(e){return this.diagram.ruler?this.diagram.ruler.truncatePositionToGuides(e):e}_truncateSizeToGuides(e){return this.diagram.ruler?this.diagram.ruler.truncateSizeToGuides(e):e}_truncateAngle(e){const t=this.snapOptions();const n=Math.max(t.angle||10,5);return t?Math.floor(e%360/n)*n:e%360}_truncateDistance(e){if(e instanceof M6)return new M6(this._truncateDistance(e.x),this._truncateDistance(e.y));{const t=this.snapOptions()||{};const n=Math.max(t.size||10,5);return t?Math.floor(e/n)*n:e}}snapOptions(){return((this.diagram.options.editable||{}).drag||{}).snap||{}}shouldSnap(){const e=this.diagram.options.editable;const t=(e||{}).drag;const n=(t||{}).snap;return!1!==e&&!1!==t&&!1!==n}_displaceBounds(e,t,n,i){const r=e.topLeft().plus(t),o=e.bottomRight().plus(n);let a,s=A6.fromPoints(r,o);return i||(a=s.center(),a.rotate(-this._angle,e.center()),s=new A6(a.x-s.width/2,a.y-s.height/2,s.width,s.height)),s}stop(){let e,t,n;if(this._cp!==this._sp)if(this._rotating)e=new V8(this,this.shapes,this.initialRotates),this._rotating=!1;else if(this._diffStates()){if(this.diagram.ruler)for(t=0;t<this.shapes.length;t++){n=this.shapes[t];let e=n.bounds();e=this._truncateSizeToGuides(this._truncatePositionToGuides(e)),n.bounds(e),this.refreshBounds(),this.refresh()}for(t=0;t<this.shapes.length;t++)n=this.shapes[t],n.updateModel();e=new c9(this.shapes,this.shapeStates,this),this.diagram._syncShapeChanges()}return this._manipulating=void 0,this._internalChange=void 0,this._rotating=void 0,e}_diffStates(){const e=this.shapes;const t=this.shapeStates;for(let n=0;n<e.length;n++)if(!e[n].bounds().equals(t[n]))return!0;return!1}refreshBounds(){const e=1===this.shapes.length?this.shapes[0].bounds().clone():this.diagram.boundingBox(this.shapes,!0);this.bounds(e)}refresh(){let e,t;if(this.shapes.length>0){t=this.bounds(),this.visual.visible(!0),this.visual.position(t.topLeft()),this.map.forEach((t=>{e=this._getHandleBounds(new M6(t.x,t.y)),t.visual.position(e.topLeft())})),this.visual.position(t.topLeft());const n=new M6(t.width/2,t.height/2);if(this.visual.rotate(this._angle,n),this.rect.redraw({width:t.width,height:t.height}),this.rotationThumb){const e=this.options.editable.rotate.thumb;this._rotationThumbBounds=new A6(t.center().x,t.y+e.y,0,0).inflate(e.width),this.rotationThumb.redraw({x:t.width/2-e.width/2})}}else this.visual.visible(!1)}}const u9={stroke:{color:"#778899",width:1,dashType:"dash"},fill:{color:X3}};class p9{constructor(e){const t=e.options.selectable;this.options=P6({},u9,t),this.visual=new x5(this.options),this.diagram=e}start(e){this._sp=this._ep=e,this.refresh(),this.diagram._adorn(this,!0)}end(){this._sp=this._ep=void 0,this.diagram._adorn(this,!1)}bounds(e){return e&&(this._bounds=e),this._bounds}move(e){this._ep=e,this.refresh()}refresh(){if(this._sp){const e=A6.fromPoints(this.diagram.modelToLayer(this._sp),this.diagram.modelToLayer(this._ep));this.bounds(A6.fromPoints(this._sp,this._ep)),this.visual.position(e.topLeft()),this.visual.redraw({height:e.height+1,width:e.width+1})}}}class f9{constructor(){}}class m9 extends f9{constructor(e){super(),this.connection=e}hitTest(e){return!!this.getBounds().inflate(a4).contains(e)&&S6.distanceToPolyline(e,this.connection.allPoints())<a4}getBounds(){const e=this.connection.allPoints(),t=e[0],n=e[e.length-1];let i=Math.max(t.x,n.x),r=Math.min(t.x,n.x),o=Math.min(t.y,n.y),a=Math.max(t.y,n.y);for(let t=1;t<e.length-1;++t)i=Math.max(i,e[t].x),r=Math.min(r,e[t].x),o=Math.min(o,e[t].y),a=Math.max(a,e[t].y);return new A6(r,o,i-r,a-o)}}const g9="topLeft";const v9="bottomRight";class _9 extends m9{constructor(e){super(e),this.SAME_SIDE_DISTANCE_RATIO=5,this._connectorSides=[{name:l4,axis:Q3,boundsPoint:g9,secondarySign:1},{name:d4,axis:Y3,boundsPoint:g9,secondarySign:1},{name:h4,axis:Q3,boundsPoint:v9,secondarySign:-1},{name:c4,axis:Y3,boundsPoint:v9,secondarySign:-1}],this.connection=e}routePoints(e,t,n,i){let r;return r=n&&i?this._connectorPoints(e,t,n,i):this._floatingPoints(e,t,n),r}route(){const e=this.connection._resolvedSourceConnector;const t=this.connection._resolvedTargetConnector;const n=this.connection.sourcePoint();const i=this.connection.targetPoint();const r=this.routePoints(n,i,e,t);this.connection.points(r)}_connectorSide(e,t){const n=e.position();const i=e.shape.bounds(k4);const r={topLeft:i.topLeft(),bottomRight:i.bottomRight()};const o=this._connectorSides;let a=Number.MAX_VALUE;let s;let l;let c;let d;for(let e=0;e<o.length;e++)d=o[e],c=d.axis,s=Math.round(Math.abs(n[c]-r[d.boundsPoint][c])),s<a?(a=s,l=d):s===a&&(n[c]-t[c])*d.secondarySign>(n[l.axis]-t[l.axis])*l.secondarySign&&(l=d);return l.name}_sameSideDistance(e){const t=e.shape.bounds(k4);return Math.min(t.width,t.height)/this.SAME_SIDE_DISTANCE_RATIO}_connectorPoints(e,t,n,i){const r=this._connectorSide(n,t);const o=this._connectorSide(i,e);const a=t.x-e.x;const s=t.y-e.y;const l=this._sameSideDistance(n);let c=[];let d,h;return r===l4||r===h4?o===l4||o===h4?r===o?(h=r===l4?Math.min(e.y,t.y)-l:Math.max(e.y,t.y)+l,c=[new M6(e.x,h),new M6(t.x,h)]):c=[new M6(e.x,e.y+s/2),new M6(t.x,e.y+s/2)]:c=[new M6(e.x,t.y)]:o===d4||o===c4?r===o?(d=r===d4?Math.min(e.x,t.x)-l:Math.max(e.x,t.x)+l,c=[new M6(d,e.y),new M6(d,t.y)]):c=[new M6(e.x+a/2,e.y),new M6(e.x+a/2,e.y+s)]:c=[new M6(t.x,e.y)],c}_floatingPoints(e,t,n){const i=n?this._connectorSide(n,t):null;const r=this._startHorizontal(e,t,i);const o=[e,e,t,t];const a=t.x-e.x;const s=t.y-e.y;const l=o.length;let c=1;let d;let h;for(;c<l-1;++c)r?c%2!=0?(d=a/(l/2),h=0):(d=0,h=s/((l-1)/2)):c%2!=0?(d=0,h=s/(l/2)):(d=a/((l-1)/2),h=0),o[c]=new M6(o[c-1].x+d,o[c-1].y+h);return c--,o[l-2]=r&&c%2!=0||!r&&c%2==0?new M6(o[l-1].x,o[l-2].y):new M6(o[l-2].x,o[l-1].y),[o[1],o[2]]}_startHorizontal(e,t,n){let i;return i=null!==n&&(n===c4||n===d4)||Math.abs(e.x-t.x)>Math.abs(e.y-t.y),i}}class b9 extends m9{constructor(e){super(e),this.connection=e}route(){}}class w9{constructor(e){this.toolService=e,this.type="ConnectionTool"}tryActivate(e,t){const 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(e,t,n){const i=this.toolService;const r=this._c;i.selectSingle(r,t);const o=r.adorner;let a,s;o&&(a=o._hitTest(e),s=S4[a]),l9(r)&&o&&!i.diagram.trigger(u4,{shapes:[],connections:[r],connectionHandle:s,point:e,meta:t,nativeEvent:n})?(this.handle=a,this.handleName=s,o.start(e)):(i.startPoint=e,i.end(e,t,n))}move(e,t,n){const i=this._c.adorner;if(l9(this._c)&&i)return i.move(this.handle,e),this.toolService.diagram.trigger(p4,{shapes:[],connections:[this._c],connectionHandle:this.handleName,point:e,meta:t,nativeEvent:n}),!0}end(e,t,n){const i=this._c;const r=i.adorner;const o=this.toolService.diagram;if(r&&l9(i)){const a=r.stop(e);o.trigger(f4,{shapes:[],connections:[i],connectionHandle:this.handleName,point:e,meta:t,nativeEvent:n})?a.undo():(o.undoRedoService.add(a,!1),i.updateModel(),o._syncConnectionChanges())}}getCursor(){return o4.move}}class y9{constructor(e){this.toolService=e,this.type="ConnectionTool"}tryActivate(){return this.toolService._hoveredConnector}start(e,t,n){const i=this.toolService,r=i.diagram,o=i._hoveredConnector,a=r._createConnection({},o._c,e);l9(a)&&!r.trigger(u4,{shapes:[],connections:[a],connectionHandle:C4,point:e,meta:t,nativeEvent:n})&&r._addConnection(a)?(i._connectionManipulation(a,o._c.shape,!0),i._removeHover(),i.selectSingle(i.activeConnection,t),"touchmove"===t.type&&(r._cachedTouchTarget=o.visual)):(a.source(null),i.end(e,t,n))}move(e,t,n){const i=this.toolService;const r=i.activeConnection;return r.target(e),i.diagram.trigger(p4,{shapes:[],connections:[r],connectionHandle:C4,point:e,meta:t,nativeEvent:n}),!0}end(e,t,n){const i=this.toolService,r=i.diagram,o=i.activeConnection,a=i.hoveredItem,s=i._hoveredConnector,l=r._cachedTouchTarget;let c;o&&(c=s&&s._c!==o.sourceConnector?s._c:a&&a instanceof r9?a.getConnector(s4)||a.getConnector(e):e,o.target(c),r.trigger(f4,{shapes:[],connections:[o],connectionHandle:C4,point:e,meta:t,nativeEvent:n})?(r.remove(o,!1),r.undoRedoService.pop()):(o.updateModel(),r._syncConnectionChanges()),i._connectionManipulation(),l&&(r._connectorsAdorner.visual.remove(l),r._cachedTouchTarget=null))}getCursor(){return o4.arrow}}class k9{constructor(e){this.toolService=e}start(){}move(){}end(){}tryActivate(){return!1}getCursor(){return o4.arrow}}function x9(e){return!1===e.ctrlKey&&!1===e.altKey&&!1===e.shiftKey}class C9{constructor(e){this.toolService=e}tryActivate(){return!0}start(e,t,n){const i=this.toolService,r=i.diagram,o=i.hoveredItem;o&&(i.selectSingle(o,t),o.adorner&&(this.adorner=o.adorner,this.handle=this.adorner._hitTest(e))),this.handle||(this.handle=r._resizingAdorner._hitTest(e),this.handle&&(this.adorner=r._resizingAdorner)),this.adorner&&(this.adorner.isDragHandle(this.handle)&&r.trigger(u4,{shapes:this.adorner.shapes,connections:[],point:e,nativeEvent:n,meta:t})?(i.startPoint=e,i.end(e,t,n)):this.adorner.start(e))}move(e,t,n){this.adorner&&(this.adorner.move(this.handle,e),this.adorner.isDragHandle(this.handle)&&this.toolService.diagram.trigger(p4,{shapes:this.adorner.shapes,connections:[],point:e,meta:t,nativeEvent:n}))}end(e,t,n){const i=this.toolService.diagram,r=this.adorner;let o;r&&(r.isDragHandle(this.handle)&&i.trigger(f4,{shapes:r.shapes,connections:[],point:e,meta:t,nativeEvent:n})?r.cancel():(o=r.stop(),o&&i.undoRedoService.add(o,!1))),this.adorner=void 0,this.handle=void 0}getCursor(e){return this.toolService.hoveredItem?this.toolService.hoveredItem._getCursor(e):o4.arrow}}const S9={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"};function T9(e){return S9[e]||e}const M9=e=>e.replace(/([^ ]+)/g,T9);const A9=Go;const D9=function(e,t,n){return"translate3d("+e+"px,"+t+"px,0) scale("+n+")"};class E9 extends v6{constructor(e,t){super();const n=e[0]||e;this.element=n,this.capture=!1,this._pressHandler=this._press.bind(this),this._releaseHandler=this._release.bind(this),S9.down.split(" ").forEach((e=>{n.addEventListener(e,this._pressHandler,!0)})),S9.up.split(" ").forEach((e=>{n.addEventListener(e,this._releaseHandler,!0)})),this.bind(["press","release"],t||{})}captureNext(){this.capture=!0}cancelCapture(){this.capture=!1}_press(e){this.trigger("press"),this.capture&&e.preventDefault()}_release(e){this.trigger("release"),this.capture&&(e.preventDefault(),this.cancelCapture())}destroy(){const e=this.element;S9.down.split(" ").forEach((t=>{e.removeEventListener(t,this._pressHandler,!0)})),S9.up.split(" ").forEach((t=>{e.removeEventListener(t,this._releaseHandler,!0)}))}}class I9 extends v6{constructor(e){super(),this.forcedEnabled=!1,Q8(this,e),this.scale=1,this.horizontal?(this.measure="offsetWidth",this.scrollSize="scrollWidth",this.axis="x"):(this.measure="offsetHeight",this.scrollSize="scrollHeight",this.axis="y")}makeVirtual(){Q8(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})}virtualSize(e,t){this._virtualMin===e&&this._virtualMax===t||(this._virtualMin=e,this._virtualMax=t,this.update())}outOfBounds(e){return e>this.max||e<this.min}forceEnabled(){this.forcedEnabled=!0}getSize(){return this.container[this.measure]}getTotal(){return this.element[this.scrollSize]}rescale(e){this.scale=e}update(e){const t=this.virtual?this._virtualMax:this.getTotal(),n=t*this.scale,i=this.getSize();(0!==t||this.forcedEnabled)&&(this.max=this.virtual?-this._virtualMin:0,this.size=i,this.total=n,this.min=Math.min(this.max,i-n),this.minScale=i/t,this.centerOffset=(n-i)/2,this.enabled=this.forcedEnabled||n>i,e||this.trigger(r4,this))}}class z9 extends v6{constructor(e){super(),this.x=new I9(Q8({horizontal:!0},e)),this.y=new I9(Q8({horizontal:!1},e)),this.container=e.container,this.forcedMinScale=e.minScale,this.maxScale=e.maxScale||100,this.bind(r4,e)}rescale(e){this.x.rescale(e),this.y.rescale(e),this.refresh()}centerCoordinates(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}}refresh(){this.x.update(),this.y.update(),this.enabled=this.x.enabled||this.y.enabled,this.minScale=this.forcedMinScale||Math.min(this.x.minScale,this.y.minScale),this.fitScale=Math.max(this.x.minScale,this.y.minScale),this.trigger(r4)}}class P9 extends v6{constructor(e){super(),Q8(this,e)}outOfBounds(){return this.dimension.outOfBounds(this.movable[this.axis])}dragMove(e){const t=this.dimension,n=this.axis,i=this.movable,r=i[n]+e;if(!t.enabled)return;let o=e;(r<t.min&&e<0||r>t.max&&e>0)&&(o*=this.resistance),i.translateAxis(n,o),this.trigger(r4,this)}}class L9{constructor(e){let t,n;Q8(this,{elastic:!0},e);const i=this.elastic?.5:0;const r=this.movable;this.x=t=new P9({axis:"x",dimension:this.dimensions.x,resistance:i,movable:r}),this.y=n=new P9({axis:"y",dimension:this.dimensions.y,resistance:i,movable:r}),this.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart(e){this.gesture=e,this.offset=A9(this.dimensions.container)},press(e){const t=e.event.target.closest("a");t&&t.matches("[data-navigate-on-press=true]")&&e.sender.cancel()},gesturechange(e){const i=this.gesture,o=i.center,a=e.center,s=this.dimensions.minScale,l=this.dimensions.maxScale;let c=e.distance/i.distance;r.scale<=s&&c<1&&(c+=.8*(1-c)),r.scale*c>=l&&(c=l/r.scale);const d=r.x+this.offset.left,h=r.y+this.offset.top;const u={x:(d-o.x)*c+a.x-d,y:(h-o.y)*c+a.y-h};r.scaleWith(c),t.dragMove(u.x),n.dragMove(u.y),this.dimensions.rescale(r.scale),this.gesture=e,e.preventDefault()},move(e){e.event.target.tagName.match(/textarea|input/i)||(t.dimension.enabled||n.dimension.enabled?(t.dragMove(e.x.delta),n.dragMove(e.y.delta),e.preventDefault()):e.touch.skip())},end(e){e.preventDefault()}})}}class B9 extends v6{constructor(e){super(),this.element=e,this.element.style.transformOrigin="left top",this.x=0,this.y=0,this.scale=1;const t=D9(this.x,this.y,this.scale);this.element.style.transform=t,this._saveCoordinates(t)}translateAxis(e,t){this[e]+=t,this.refresh()}scaleTo(e){this.scale=e,this.refresh()}scaleWith(e){this.scale*=e,this.refresh()}translate(e){this.x+=e.x,this.y+=e.y,this.refresh()}moveAxis(e,t){this[e]=t,this.refresh()}moveTo(e){Q8(this,e),this.refresh()}refresh(){let e=this.x,t=this.y;this.round&&(e=Math.round(e),t=Math.round(t));const n=D9(e,t,this.scale);n!==this.coordinates&&(this.element.style.transform=n,this._saveCoordinates(n),this.trigger(r4))}_saveCoordinates(e){this.coordinates=e}}function H9(e){window.requestAnimationFrame(e)}class R9{constructor(){this._tickProxy=()=>this._tick(),this._started=!1}tick(){}done(){return!1}onEnd(){}onCancel(){}start(){this.enabled()&&(this.done()?this.onEnd():(this._started=!0,H9(this._tickProxy)))}enabled(){return!0}cancel(){this._started=!1,this.onCancel()}_tick(){this._started&&(this.tick(),this.done()?(this._started=!1,this.onEnd()):H9(this._tickProxy))}}class F9 extends R9{constructor(e){super(),Q8(this,e)}done(){return this.timePassed()>=this.duration}timePassed(){return Math.min(this.duration,X8()-this.startDate)}moveTo(e){const t=this.movable;this.initial=t[this.axis],this.delta=e.location-this.initial,this.duration="number"==typeof e.duration?e.duration:300,this.tick=this._easeProxy(e.ease),this.startDate=X8(),this.start()}_easeProxy(e){return function(){this.movable.moveAxis(this.axis,e(this.timePassed(),this.initial,this.delta,this.duration))}}static easeOutExpo(e,t,n,i){return e===i?t+n:n*(1-Math.pow(2,-10*e/i))+t}}const O9=new WeakMap;const V9=Symbol("id");function N9(e,t,n,i,r){!function(e,t,n,i,r){const o=Array.isArray(t)?t:(t||"").split(" ");o.forEach((function(t){!function(e,t,n,i,r){let o=i;let a;n&&R4(n)&&!i?o=n:n&&function(e){return"string"==typeof e}(n)&&R4(o)&&(a=n);const s=function(t){const n=t.target?t.target.closest(a):null;if(!a||a&&t.target&&n){const i=a?n:t.currentTarget;Object.defineProperty(t,"currentTarget",{value:i}),Object.defineProperty(t,"delegateTarget",{value:e}),o(t)}};o[V9]||(o[V9]=function(){let e="";let t;let n;for(t=0;t<32;t++)n=Math.floor(16*Math.random()),8!==t&&12!==t&&16!==t&&20!==t||(e+="-"),e+=(12===t?4:16===t?n%4+8:n).toString(16);return e}());let l=O9.get(e);l||(l=new Map,O9.set(e,l));l.set(t+o[V9],s),e.addEventListener(t,s,Boolean(r))}(e,t,n,i,r)}))}(e,t,n,i,r)}function $9(e,t,n,i){!function(e,t,n,i){const r=Array.isArray(t)?t:(t||"").split(" ");r.forEach((function(t){!function(e,t,n,i){const r=O9.get(e);if(r&&n&&n[V9]){const o=t+n[V9];const a=r.get(o);r.delete(o),a&&e.removeEventListener(t,a,Boolean(i))}}(e,t,n,i)}))}(e,t,n,i)}const U9=e=>{e.preventDefault()};const W9=()=>{};const j9="press",q9="hold",G9="select",K9="start",Y9="move",Q9="end",X9="cancel",Z9="tap",J9="doubleTap",e7="release",t7="gesturechange",n7="gestureend",i7="gesturetap";const r7={api:0,touch:0,mouse:9,pointer:9};let o7=800,a7=0;function s7(e){const 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}class l7{constructor(e,t){this.support=K8(),this.invalidZeroEvents=this.support.mobileOS&&this.support.mobileOS.android,this.axis=e,this._updateLocationData(t),this.startLocation=this.location,this.velocity=this.delta=0,this.timeStamp=X8()}move(e){const t=e["page"+this.axis],n=X8(),i=n-this.timeStamp||1;!t&&this.invalidZeroEvents||(this.delta=t-this.location,this._updateLocationData(e),this.initialDelta=t-this.startLocation,this.velocity=this.delta/i,this.timeStamp=n)}_updateLocationData(e){const t=this.axis;this.location=e["page"+t],this.client=e["client"+t],this.screen=e["screen"+t]}}class c7{constructor(e,t,n){Q8(this,{x:new l7("X",n.location),y:new l7("Y",n.location),type:n.type,threshold:e.threshold||r7[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(){this._holdTimeout=setTimeout((()=>this._hold()),this.userEvents.minHold),this._trigger(j9,this.pressEvent)}_tap(e){this.userEvents._clicks++,1===this.userEvents._clicks&&(this._clickTimeout=setTimeout((()=>{1===this.userEvents._clicks?this._trigger(Z9,e):this._trigger(J9,e),this.userEvents._clicks=0}),300))}_hold(){this._trigger(q9,this.pressEvent)}move(e){const t="api"!==e.type&&this.userEvents._shouldNotMove;if(!this._finished&&!t){if(this.x.move(e.location),this.y.move(e.location),!this._moved){if(this._withinIgnoreThreshold())return;if(h7.current&&h7.current!==this.userEvents)return this.dispose();this._start(e)}this._finished||this._trigger(Y9,e)}}end(e){this.endTime=X8(),this._finished||(this._finished=!0,this._trigger(e7,e),this._moved?this._trigger(Q9,e):this.supportDoubleTap?this._tap(e):this._trigger(Z9,e),clearTimeout(this._holdTimeout),this.dispose())}dispose(){const e=this.userEvents.touches||[];this._finished=!0,this.pressEvent=null,clearTimeout(this._holdTimeout);const t=e.indexOf(this);e.splice(t,1)}skip(){this.dispose()}cancel(){this.dispose()}isMoved(){return this._moved}_start(e){clearTimeout(this._holdTimeout),this.startTime=X8(),this._moved=!0,this._trigger(K9,e)}_trigger(e,t){const n=t.event;const i={touch:this,x:this.x,y:this.y,target:this.target,event:n};this.userEvents.notify(e,i)&&n.preventDefault()}_withinIgnoreThreshold(){const e=this.x.initialDelta,t=this.y.initialDelta;return Math.sqrt(e*e+t*t)<=this.threshold}}function d7(e){const t=S9.up.split(" "),n=t.length;for(let i=0;i<n;i++)e(t[i])}class h7 extends v6{constructor(e,t){super();const n=K8();this.support=n,t=t||{},this.options=t;const i=this.filter=t.filter;if(this.threshold=t.threshold||a7,this.minHold=t.minHold||o7,this.touches=[],this._maxTouches=t.multiTouch?2:1,this.allowSelection=t.allowSelection,this.captureUpIfMoved=t.captureUpIfMoved,this._clicks=0,this.supportDoubleTap=t.supportDoubleTap,Q8(this,{element:e,surface:t.surface||e,stopPropagation:t.stopPropagation,pressed:!1}),this._surfaceMoveHandler=this._move.bind(this),N9(this.surface,M9("move"),this._surfaceMoveHandler),this._surfaceEndHandler=this._end.bind(this),N9(this.surface,M9("up cancel"),this._surfaceEndHandler),this._elementStartHandler=this._start.bind(this),N9(e,M9("down"),i,this._elementStartHandler),e.style["touch-action"]=t.touchAction||"none",t.preventDragEvent&&(this._elementDragStartHandler=U9,N9(e,M9("dragstart"),this._elementDragStartHandler)),this._elementSelectHandler=this._select.bind(this),N9(e,M9("mousedown"),i,this._elementSelectHandler),this.captureUpIfMoved){const e=this.surface;this.preventIfMovingProxy=this.preventIfMoving.bind(this),d7((t=>{e.addEventListener(t,this.preventIfMovingProxy,!0)}))}this.bind([j9,q9,Z9,J9,K9,Y9,Q9,e7,X9,"gesturestart",t7,n7,i7,G9],t)}preventIfMoving(e){this._isMoved()&&e.preventDefault()}destroy(){const e=this.options;const t=this.element;if(!this._destroyed){if(this._destroyed=!0,this.captureUpIfMoved){const e=this.surface;d7((t=>{e.removeEventListener(t,this.preventIfMovingProxy,!0)}))}$9(this.surface,M9("move"),this._surfaceMoveHandler),$9(this.surface,M9("up cancel"),this._surfaceEndHandler),$9(t,M9("down"),this._elementStartHandler),e.preventDragEvent&&$9(t,M9("dragstart"),this._elementDragStartHandler),$9(t,M9("mousedown"),this._elementSelectHandler),this._disposeAll(),this.unbind(),delete this.surface,delete this.element,delete this.currentTarget}}capture(){h7.current=this}cancel(){this._disposeAll(),this.trigger(X9)}notify(e,t){const n=this.touches;let i=e;if(this._isMultiTouch()){switch(i){case Y9:i=t7;break;case Q9:i=n7;break;case Z9:i=i7}Q8(t,{touches:n},function(e,t){const 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)}}(n[0],n[1]))}return this.trigger(i,Q8(t,{type:i}))}press(e,t,n){this._apiCall("_start",e,t,n)}move(e,t){this._apiCall("_move",e,t)}end(e,t){this._apiCall("_end",e,t)}_isMultiTouch(){return this.touches.length>1}_maxTouchesReached(){return this.touches.length>=this._maxTouches}_disposeAll(){const e=this.touches;for(;e.length>0;)e.pop().dispose()}_isMoved(){return function(e,t){const n=e.length;const i=[];for(let r=0;r<n;r++)t(e[r])&&i.push(e[r]);return i}(this.touches,(function(e){return e.isMoved()})).length}_select(e){this.allowSelection&&!this.trigger(G9,{event:e})||e.preventDefault()}_start(e){if(e.which&&e.which>1||this._maxTouchesReached())return;let t;h7.current=null,this.currentTarget=e.currentTarget,this.stopPropagation&&e.stopPropagation();const n=s7(e);for(let e=0;e<n.length&&!this._maxTouchesReached();e++){const i=n[e];if(t=this.filter?i.currentTarget:this.element,t&&0===t.length)continue;const r=new c7(this,t,i);this.touches.push(r),r.press(),this._isMultiTouch()&&this.notify("gesturestart",{})}}_move(e){this._eachTouch("move",e)}_end(e){this._eachTouch("end",e)}_eachTouch(e,t){const n={},i=s7(t),r=this.touches;let o,a,s,l;for(o=0;o<r.length;o++)a=r[o],n[a.id]=a;for(o=0;o<i.length;o++)if(s=i[o],l=n[s.id],l){"move"===e&&"pointer"===s.type&&!this.surface.hasPointerCapture(s.id)&&this.surface.setPointerCapture(s.id),l[e](s)}}_apiCall(e,t,n,i){this[e]({api:!0,pageX:t,pageY:n,clientX:t,clientY:n,target:i||this.element,stopPropagation:W9,preventDefault:W9})}static defaultThreshold(e){a7=e}static minHold(e){o7=e}}const u7=Object.assign,p7=Math.abs,f7="change",m7="scroll";class g7 extends R9{constructor(e){super(),u7(this,e),this.userEvents.bind("gestureend",this.start.bind(this)),this.tapCapture.bind("press",this.cancel.bind(this))}enabled(){return this.movable.scale<this.dimensions.minScale}done(){return this.dimensions.minScale-this.movable.scale<.01}tick(){const e=this.movable;e.scaleWith(1.1),this.dimensions.rescale(e.scale)}onEnd(){const e=this.movable;e.scaleTo(this.dimensions.minScale),this.dimensions.rescale(e.scale)}}class v7 extends R9{constructor(e){super(),u7(this,e,{transition:new F9({axis:e.axis,movable:e.movable,onEnd:()=>{this._end()}})}),this.tapCapture.bind("press",(()=>{this.cancel()})),this.userEvents.bind("end",(()=>this.start())),this.userEvents.bind("gestureend",(()=>this.start())),this.userEvents.bind("tap",(()=>this.onEnd()))}onCancel(){this.transition.cancel()}freeze(e){this.cancel(),this._moveTo(e)}onEnd(){this.paneAxis.outOfBounds()?this._snapBack():this._end()}done(){return p7(this.velocity)<1}start(e){let t;this.dimension.enabled&&(this.paneAxis.outOfBounds()?this.transition._started?(this.transition.cancel(),this.velocity=Math.min(e.touch[this.axis].velocity*this.velocityMultiplier,55),super.start()):this._snapBack():(t=e?2===e.touch.id?0:e.touch[this.axis].velocity:0,this.velocity=Math.max(Math.min(t*this.velocityMultiplier,55),-55),this.tapCapture.captureNext(),super.start()))}tick(){const e=this.dimension,t=this.paneAxis.outOfBounds()?.5:this.friction,n=this.velocity*=t;let i=this.movable[this.axis]+n;!this.elastic&&e.outOfBounds(i)&&(i=Math.max(Math.min(i,e.max),e.min),this.velocity=0),this.movable.moveAxis(this.axis,i)}_end(){this.tapCapture.cancelCapture(),this.end()}end(){}_snapBack(){const e=this.dimension,t=this.movable[this.axis]>e.max?e.max:e.min;this._moveTo(t)}_moveTo(e){this.transition.moveTo({location:e,duration:500,ease:(...e)=>{F9.easeOutExpo.apply(null,e)}})}}class _7 extends R9{constructor(e){super(),u7(this,e,{origin:{},destination:{},offset:{}})}moveTo(e){}tick(){this._updateCoordinates(),this.moveTo(this.origin)}done(){return p7(this.offset.y)<5&&p7(this.offset.x)<5}onEnd(){this.moveTo(this.destination),this.callback&&this.callback.call()}setCoordinates(e,t){this.offset={},this.origin=e,this.destination=t}setCallback(e){e&&R4(e)?this.callback=e:e=void 0}_updateCoordinates(){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}}}class b7{constructor(e){const t="x"===e.axis;const n=J8('<div class="km-touch-scrollbar km-'+(t?"horizontal":"vertical")+'-scrollbar" />');u7(this,e,{element:n,elementSize:0,movable:new B9(n),scrollMovable:e.movable,alwaysVisible:e.alwaysVisible,size:t?"width":"height"}),this.scrollMovable.bind(f7,this.refresh.bind(this)),this.container.appendChild(n),e.alwaysVisible&&this.show()}refresh(){const e=this.axis,t=this.dimension,n=t.size,i=this.scrollMovable,r=n/t.total;let o=Math.round(n*r),a=Math.round(-i[e]*r);this.element.style.display=r>=1?"none":"",a+o>n?o=n-a:a<0&&(o+=a,a=0),this.elementSize!==o&&(this.element.style[this.size]=o+"px",this.elementSize=o),this.movable.moveAxis(e,a)}show(){this.element.style.opacity=.7,this.element.style.visibility="visible"}hide(){this.alwaysVisible||(this.element.style.opacity=0)}}const w7={name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:()=>!1,pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}};class y7 extends v6{constructor(e,t){super(),this.element=e=e[0]||e,this._initOptions(t),this.events.push("pull",m7,"resize");const n=(()=>{const{mobileOS:e}=K8();return e.ios||e.android})();this._native=this.options.useNative&&n;const i=J8('<div class="km-scroll-header"/>');if(this._native)return Z8(e,"km-native-scroller"),e9(i,e),void u7(this,{scrollElement:e,fixedContainer:e.children[0]});e.style.overflow="hidden",Z8(e,"km-scroll-wrapper");((e,t)=>{for(e.appendChild(t);e.firstChild!==t;)t.appendChild(e.firstChild)})(e,J8('<div class="km-scroll-container"/>')),e9(i,e);const r=e.children[1],o=new E9(e),a=new B9(r),s=new z9({element:r,container:e,forcedEnabled:this.options.zoom}),l=this.options.avoidScrolling,c=new h7(e,{touchAction:"none",allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:this.options.zoom,supportDoubleTap:this.options.supportDoubleTap,start:e=>{s.refresh();const t=p7(e.x.velocity),n=p7(e.y.velocity),i=2*t>=n,r=2*n>=t;!this.fixedContainer.contains(e.event.target)&&!l(e)&&this.enabled&&(s.x.enabled&&i||s.y.enabled&&r)?c.capture():c.cancel()}}),d=new L9({movable:a,dimensions:s,userEvents:c,elastic:this.options.elastic}),h=new g7({movable:a,dimensions:s,userEvents:c,tapCapture:o}),u=new _7({moveTo:e=>{this.scrollTo(e.x,e.y)}});a.bind(f7,(()=>{this.scrollTop=-a.y,this.scrollLeft=-a.x,this.trigger(m7,{scrollTop:this.scrollTop,scrollLeft:this.scrollLeft})})),this.options.mousewheelScrolling&&(this._wheelScrollHandler=this._wheelScroll.bind(this),N9(e,"wheel",this._wheelScrollHandler)),u7(this,{movable:a,dimensions:s,zoomSnapBack:h,animatedScroller:u,userEvents:c,pane:d,tapCapture:o,pulled:!1,enabled:!0,scrollElement:r,scrollTop:0,scrollLeft:0,fixedContainer:e.children[0]}),this._initAxis("x"),this._initAxis("y"),this._wheelEnd=()=>{this._wheel=!1,this.userEvents.end(0,this._wheelY)},s.refresh(),this.options.pullToRefresh&&this._initPullToRefresh(),this.bind(this.events,this.options)}_initOptions(e){this.options=P6({},this.options,w7,e)}_wheelScroll(e){if(e.ctrlKey)return;this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout((()=>this._wheelEnd()),50);const t=(e=>{const t=e.wheelDeltaY;let n;return e.wheelDelta?(void 0===t||t)&&(n=e.wheelDelta):e.detail&&e.axis===e.VERTICAL_AXIS&&(n=10*-e.detail),n})(e);t&&(this._wheelY+=t,this.userEvents.move(0,this._wheelY)),e.preventDefault()}makeVirtual(){this.dimensions.y.makeVirtual()}virtualSize(e,t){this.dimensions.y.virtualSize(e,t)}height(){return this.dimensions.y.size}scrollHeight(){return this.scrollElement.scrollHeight}scrollWidth(){return this.scrollElement.scrollWidth}_resize(){this._native||this.contentResized()}setOptions(e){this._initOptions(e),e.pullToRefresh&&this._initPullToRefresh()}reset(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))}contentResized(){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(){const e=this.dimensions;e.refresh(),this._scale(e.fitScale),this.movable.moveTo(e.centerCoordinates())}enable(){this.enabled=!0}disable(){this.enabled=!1}scrollTo(e,t){this._native?(this.scrollElement.scrollLeft(p7(e)),this.scrollElement.scrollTop(p7(t))):(this.dimensions.refresh(),this.movable.moveTo({x:e,y:t}))}animatedScrollTo(e,t,n){let 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(){}destroy(){$9(this.element,"wheel",this._wheelScrollHandler),this.userEvents&&this.userEvents.destroy(),this.tapCapture&&this.tapCapture.destroy()}_scale(e){this.dimensions.rescale(e),this.movable.scaleTo(e)}_initPullToRefresh(){}_dragEnd(){}_paneChange(){}_initAxis(e){const t=this.movable,n=this.dimensions[e],i=this.tapCapture,r=this.pane[e],o=new b7({axis:e,movable:t,dimension:n,container:this.element,alwaysVisible:this.options.visibleScrollHints});n.bind(f7,(()=>{o.refresh()})),r.bind(f7,(()=>{o.show()})),this[e+"inertia"]=new v7({axis:e,paneAxis:r,movable:t,tapCapture:i,userEvents:this.userEvents,dimension:n,elastic:this.options.elastic,friction:this.options.friction||.96,velocityMultiplier:this.options.velocityMultiplier||10,end:()=>{o.hide(),this.trigger("scrollEnd",{axis:e,scrollTop:this.scrollTop,scrollLeft:this.scrollLeft})}})}}function k7(){var e;return/Macintosh|iPhone|iPad/i.test((null===(e=null===window||void 0===window?void 0:window.navigator)||void 0===e?void 0:e.userAgent)||"")}class x7 extends k9{constructor(e){super(e);const t=this.toolService.diagram,n=t.canvas;const i=t._mobileOS()?.93:.9;const r=t.scroller=this.scroller=new y7(t.scrollable,{friction:i,velocityMultiplier:5,mousewheelScrolling:!1,zoom:!1,scroll:this._move.bind(this)});n.translate&&(this.movableCanvas=new B9(n.element));const o=function(e,t,n){e.makeVirtual(),e.virtualSize(t||-2e4,n||2e4)};o(r.dimensions.x),o(r.dimensions.y),r.disable()}tryActivate(e,t){const n=this.toolService;const i=n.diagram.options.pannable;const r=t.metaKey&&k7();let o=t.ctrlKey||r;return H4(i.key)&&(i.key&&"none"!==i.key?(o=t[i.key+"Key"],o=o||"ctrl"===i.key&&r):o=x9(t)&&!H4(n.hoveredItem)),!1!==i&&o&&!H4(n.hoveredAdorner)&&!H4(n._hoveredConnector)}start(){this.scroller.enable()}move(){}_move(e){const t=this.toolService.diagram,n=t.canvas;let i=new M6(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(y4,{pan:i})}end(){this.scroller.disable()}getCursor(){return o4.move}}class C7{constructor(e){this.toolService=e}tryActivate(e,t){const n=this.toolService;const i=n.diagram.options.selectable;let r=i&&!1!==i.multiple;return r&&(r=i.key&&"none"!==i.key?t[i.key+"Key"]:x9(t)),r&&!H4(n.hoveredItem)&&!H4(n.hoveredAdorner)}start(e){const t=this.toolService.diagram;t.deselect(),t.selector.start(e)}move(e){this.toolService.diagram.selector.move(e)}end(e,t){const n=this.toolService.diagram,i=this.toolService.hoveredItem;const r=n.selector.bounds();i&&i.isSelected||t.ctrlKey||n.deselect(),r.isEmpty()||n.selectArea(r),n.selector.end()}getCursor(){return o4.arrow}}function S7(e,t){return t.charCodeAt(0)===e||t.toUpperCase().charCodeAt(0)===e}class T7{constructor(e,t,n){this.item=e,this._redoSource=t,this._redoTarget=n,H4(t)&&(this._undoSource=e.source()),H4(n)&&(this._undoTarget=e.target()),this.title=T4}undo(){void 0!==this._undoSource&&this.item._updateConnector(this._undoSource,x4),void 0!==this._undoTarget&&this.item._updateConnector(this._undoTarget,C4),this.item.updateModel()}redo(){void 0!==this._redoSource&&this.item._updateConnector(this._redoSource,x4),void 0!==this._redoTarget&&this.item._updateConnector(this._redoTarget,C4),this.item.updateModel()}}const M7={hover:{stroke:{}},startCap:E4,endCap:E4,points:[],selectable:!0,fromConnector:s4,toConnector:s4};class A7 extends n9{constructor(e,t,n){super(n=P6({},M7,n)),this.name="Connection",this.updateOptionsFromModel(),this._initRouter(),this.path=new u8(this.options),this.path.fill(X3),this.visual.append(this.path),this._sourcePoint=this._targetPoint=new M6,this._setSource(e),this._setTarget(t),this.content(this.options.content),this.definers=[],H4(n)&&n.points&&this.points(n.points)}_setOptionsFromModel(e){this.updateOptionsFromModel(e||this.dataItem)}updateOptionsFromModel(e){if(this.diagram&&this.diagram._isEditable){const t=this.diagram._dataMap;const n=function(e){const t={};return H4((e=e||{}).text)&&null!==e.text&&(t.content=e.text),H4(e.type)&&null!==e.type&&(t.type=e.type),H4(e.from)&&null!==e.from&&(t.from=e.from),H4(e.fromConnector)&&null!==e.fromConnector&&(t.fromConnector=e.fromConnector),H4(e.fromX)&&null!==e.fromX&&(t.fromX=e.fromX),H4(e.fromY)&&null!==e.fromY&&(t.fromY=e.fromY),H4(e.to)&&null!==e.to&&(t.to=e.to),H4(e.toConnector)&&null!==e.toConnector&&(t.toConnector=e.toConnector),H4(e.toX)&&null!==e.toX&&(t.toX=e.toX),H4(e.toY)&&null!==e.toY&&(t.toY=e.toY),t}(e||this.dataItem);if(e){if(H4(n.from)){let e=t[n.from];e&&H4(n.fromConnector)&&(e=e.getConnector(n.fromConnector)),this.source(e)}else H4(n.fromX)&&H4(n.fromY)&&this.source(new M6(n.fromX,n.fromY));if(H4(n.to)){let e=t[n.to];e&&H4(n.toConnector)&&(e=e.getConnector(n.toConnector)),this.target(e)}else H4(n.toX)&&H4(n.toY)&&this.target(new M6(n.toX,n.toY));H4(n.type)&&this.type()!==n.type&&(this.points([]),this.type(n.type)),this.dataItem=e,this._template(),this.redraw(this.options)}else this.options=P6({},n,this.options)}}updateModel(e){this.diagram&&this.diagram._isEditable&&this.diagram.updateConnectionModel(this,e)}sourcePoint(){return this._resolvedSourceConnector?this._resolvedSourceConnector.position():this._sourcePoint}_setSource(e){const t=e instanceof r9;const n=this.options.fromConnector||s4;let i;t&&!e.getConnector(n)||(void 0!==e&&(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 $8?(i=e.shape.dataItem,i&&this._setFromOptions(i.id),this.sourceConnector=e,this.sourceConnector.connections.push(this)):e instanceof M6?(this._setFromOptions(null,e),this._sourcePoint=e,this.sourceConnector&&this._clearSourceConnector()):t&&(i=e.dataItem,i&&this._setFromOptions(i.id),this.sourceConnector=e.getConnector(n),this.sourceConnector.connections.push(this)))}source(e,t){return B4(e)&&(t&&this.diagram&&this.diagram.undoRedoService.addCompositeItem(new T7(this,e)),this._setSource(e),this.refresh()),this.sourceConnector?this.sourceConnector:this._sourcePoint}_setFromOptions(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(e){if(!e)return this._sourceDefiner||(this._sourceDefiner=new K6(this.sourcePoint(),null,null)),this._sourceDefiner;if(!(e instanceof K6))throw new Error("The sourceDefiner needs to be a PathDefiner.");e.left=null,this._sourceDefiner=e,this.source(e.point)}targetPoint(){return this._resolvedTargetConnector?this._resolvedTargetConnector.position():this._targetPoint}_setTarget(e){const t=e instanceof r9;const n=this.options.toConnector||s4;let i;t&&!e.getConnector(n)||(void 0!==e&&(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 $8?(i=e.shape.dataItem,i&&this._setToOptions(i.id),this.targetConnector=e,this.targetConnector.connections.push(this)):e instanceof M6?(this._setToOptions(null,e),this._targetPoint=e,this.targetConnector&&this._clearTargetConnector()):t&&(i=e.dataItem,i&&this._setToOptions(i.id),this.targetConnector=e.getConnector(n),this.targetConnector.connections.push(this)))}target(e,t){return B4(e)&&(t&&this.diagram&&this.diagram.undoRedoService.addCompositeItem(new T7(this,void 0,e)),this._setTarget(e),this.refresh()),this.targetConnector?this.targetConnector:this._targetPoint}_setToOptions(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(e){if(!e)return this._targetDefiner||(this._targetDefiner=new K6(this.targetPoint(),null,null)),this._targetDefiner;if(!(e instanceof K6))throw new Error("The sourceDefiner needs to be a PathDefiner.");e.right=null,this._targetDefiner=e,this.target(e.point)}_updateConnectors(){this._updateConnector(this.source(),"source"),this._updateConnector(this.target(),"target")}_updateConnector(e,t){const n=this.diagram;if(e instanceof $8&&!n.getShapeById(e.shape.id)){const i=e.shape.dataItem;const r=e.options.name;const o=()=>{const o=n._dataMap[i.id];e=o.getConnector(r),this[t](e,!1),this.updateModel()};if(n._dataMap[i.id])o();else{const e=n._inactiveShapeItems.getByUid(i.uid);e&&n._deferredConnectionUpdates.push(e.onActivate(o))}}else this[t](e,!1)}content(e){const t=this.options.content.text;const n=this._content(e);return H4(e)&&(t!==n&&(this._contentVisual._measured=!1),this._alignContent()),n}_createContentVisual(e){let t;const n=e.visual;const i=e.template;const r=Q8({},e,{dataItem:this.dataItem||e.dataItem});const o=G8(r);if(n){t=R4(o)?o.call(this,r):null}else if(i){const e=R4(o)?o.call(this,r.dataItem):null;R4(e)?t=e:N4(e)&&(t=new x8(Q8({},r,{text:e})))}else e.text&&(t=new x8(r));return t&&(this._contentVisual=t,t._includeInBBox=!1,this.visual.append(t)),t}_updateContentVisual(e){R4(e.visual)?(this.visual.remove(this._contentVisual),this._createContentVisual(e)):this._contentVisual.redraw(e)}_alignContent(){if(this._contentVisual){let e=5;const t=this.allPoints();let n=Math.floor(t.length/2);let i=n-1;for(;i>0&&t[i].equals(t[n]);)i--,n++;let r=t[n];let o=t[i];const a=this._contentVisual._measure();const s=a.width;const l=a.height;let c=t.length%2==0;const d=o.distanceTo(r);let h;if(c&&t.length>2&&d>0&&(o.y===r.y&&d<s||o.x===r.x&&d<l)&&(c=!1,e=0),c){const t=Io(Math.atan2(r.y-o.y,r.x-o.x));h=new M6((r.x-o.x)/2+o.x,(r.y-o.y)/2+o.y),90===Math.abs(t)?(h.x+=e,h.y-=l/2):t%180==0?(h.x-=s/2,h.y-=l+e):t<-90||0<t&&t<90?h.y-=l:(t<0||t>90)&&(h.x-=s,h.y-=l)}else{const n=Math.floor(t.length/2);h=t[n].clone(),o=t[n-1],r=t[n+1];const i=o.x<=h.x&&r.x<=h.x?e:-a.width-e;const s=o.y<=h.y&&r.y<=h.y?e:-a.height-e;h.x+=i,h.y+=s}this._contentVisual.position(h)}}select(e){const t=this.diagram;let n,i;if(this._canSelect()&&this.isSelected!==e)return this.isSelected=e,n=[],i=[],this.isSelected?(this.adorner=new o9(this,this.options.selection),t._adorn(this.adorner,!0),t._selectedItems.push(this),n.push(this)):this.adorner&&(t._adorn(this.adorner,!1),J4(t._selectedItems,this),this.adorner=void 0,i.push(this)),this.adorner&&this.adorner.refresh(),t._internalSelection||t._selectionChanged(n,i),!0}bounds(e){if(!e||N4(e))return this._bounds;this._bounds=e}type(e){const t=this.options;if(!e)return t.type;e!==t.type&&(t.type=e,this._initRouter(),this.refresh())}_initRouter(){const e=(this.options.type||"").toLowerCase();this._router=e===M4?new _9(this):new b9(this)}points(e){if(!e){const e=[];if(B4(this.definers))for(let t=0;t<this.definers.length;t++)e.push(this.definers[t].point);return e}this.definers=[];for(let t=0;t<e.length;t++){const n=e[t];if(n instanceof M6)this.definers.push(new K6(n));else{if(!Object.prototype.hasOwnProperty.call(n,"x")||!Object.prototype.hasOwnProperty.call(n,"y"))throw new Error("A Connection point needs to be a Point or an object with x and y properties.");this.definers.push(new K6(new M6(n.x,n.y)))}}}allPoints(){const e=[this.sourcePoint()];if(this.definers)for(let t=0;t<this.definers.length;t++)e.push(this.definers[t].point);return e.push(this.targetPoint()),e}refresh(){this._resolveConnectors(),this._refreshPath(),this._alignContent(),this.adorner&&this.adorner.refresh()}_resolveConnectors(){let e,t,n,i;const r=this.source(),o=this.target();r instanceof M6?e=r:r instanceof $8&&(n=z8(r)?r.shape.connectors:[r]),o instanceof M6?t=o:o instanceof $8&&(i=z8(o)?o.shape.connectors:[o]),e?i&&(this._resolvedTargetConnector=P8(e,i)):n&&(t?this._resolvedSourceConnector=P8(t,n):i&&this._resolveAutoConnectors(n,i))}_resolveAutoConnectors(e,t){let n=A4;let i=A4;let r,o;let a,s;let l,c;let d,h;let u,p;let f;for(u=0;u<e.length;u++)if(d=e[u],!z8(d))for(a=d.position(),p=0;p<t.length;p++)h=t[p],z8(h)||(s=h.position(),f=Math.round(a.distanceTo(s)),f<n&&this.diagram&&this._testRoutePoints(a,s,d,h)&&(n=f,r=d,o=h),f<i&&(l=d,c=h,i=f));r&&(l=r,c=o),this._resolvedSourceConnector=l,this._resolvedTargetConnector=c}_testRoutePoints(e,t,n,i){const r=this._router;let o=!0;if(r instanceof _9){const a=r.routePoints(e,t,n,i),s=this._getRouteExclude(e,t,n.shape,i.shape);let l,c,d;a.unshift(e),a.push(t);for(let e=1;e<a.length;e++)if(l=a[e-1],c=a[e],d=new A6(Math.min(l.x,c.x),Math.min(l.y,c.y),Math.abs(l.x-c.x),Math.abs(l.y-c.y)),d.width>0&&(d.x++,d.width-=2),d.height>0&&(d.y++,d.height-=2),!d.isEmpty()&&this.diagram._shapesQuadTree.hitTestRect(d,s)){o=!1;break}}return o}_getRouteExclude(e,t,n,i){const r=[];return this._isPointInsideShape(e,n)&&r.push(n),this._isPointInsideShape(t,i)&&r.push(i),r}_isPointInsideShape(e,t){const n=t.bounds(),i=t.rotate().angle,r=n.x,o=n.y;const a=e.clone().rotate(i,n.center());const s=a.x;const l=a.y;return s>r&&s<r+n.width&&l>o&&l<o+n.height}redraw(e){if(e){this.options=P6({},this.options,e);const t=this.options.points;H4(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(){const e=this.serialize();return this.diagram&&this.diagram._isEditable&&H4(this.dataItem)&&(e.options.dataItem=this.diagram.options.cloneDataItem(this.dataItem)),new A7(this.from,this.to,e.options)}serialize(){const e=this.from.toJSON?this.from.toJSON:this.from.toString(),t=this.to.toJSON?this.to.toJSON:this.to.toString();const n=P6({},{options:this.options,from:e,to:t});return H4(this.dataItem)&&(n.dataItem=this.dataItem.toString()),n.options.points=this.points(),n}_hitTest(e){if(this.visible()){const t=new M6(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(e){let t=(this.options.stroke||{}).color;e&&B4(this.options.hover.stroke.color)&&(t=this.options.hover.stroke.color),this.path.redraw({stroke:{color:t}})}_refreshPath(){H4(this.path)&&(this._drawPath(),this.bounds(this._router.getBounds()))}_drawPath(){this._router&&this._router.route();const e=this.sourcePoint();const t=this.targetPoint();const n=this.points();this.path.redraw({points:[e].concat(n,[t])})}_clearSourceConnector(){this.sourceConnector=void 0,this._resolvedSourceConnector=void 0}_clearTargetConnector(){this.targetConnector=void 0,this._resolvedTargetConnector=void 0}_removeFromSourceConnector(){this.sourceConnector&&J4(this.sourceConnector.connections,this)}_removeFromTargetConnector(){this.targetConnector&&J4(this.targetConnector.connections,this)}toJSON(){let e,t,n;return this.from&&this.from.toJSON?e=this.from.toJSON():(n=this._sourcePoint,e={x:n.x,y:n.y}),this.to&&this.to.toJSON?t=this.to.toJSON():(n=this._targetPoint,t={x:n.x,y:n.y}),{from:e,to:t}}}const D7=Wo;class E7{constructor(e){this.diagram=e,this.tools=[new x7(this),new w9(this),new y9(this),new C7(this),new C9(this)],this.activeTool=void 0}start(e,t,n){return t=P6({},t),this.activeTool&&this.activeTool.end(e,t),this._updateHoveredItem(e,t,n),this._activateTool(e,t),this.activeTool.start(e,t,n),this._updateCursor(e),this.diagram.focus(),this.diagram.canvas.surface.suspendTracking(),this.startPoint=e,!0}move(e,t,n){t=P6({},t);let i=!0;return this.activeTool&&(i=this.activeTool.move(e,t,n)),i&&this._updateHoveredItem(e,t,n),this._updateCursor(e),!0}end(e,t,n){return t=P6({},t),this.activeTool&&this.activeTool.end(e,t,n),this.diagram.canvas.surface.resumeTracking(),this.activeTool=void 0,this._updateCursor(e),!0}keyDown(e,t){const n=this.diagram;if(!(t=P6({ctrlKey:!1,metaKey:!1,altKey:!1},t)).ctrlKey&&!t.metaKey||t.altKey){if(46===e||8===e){const e=this.diagram._triggerRemove(n.select());return e.length&&(this.diagram.remove(e,!0),this.diagram._syncChanges(),this.diagram._destroyToolBar()),!0}if(27===e)return this._discardNewConnection(),n.deselect(),n._destroyToolBar(),!0}else{if(S7(e,"a"))return n.selectAll(),n._destroyToolBar(),!0;if(S7(e,"z"))return n.undo(),n._destroyToolBar(),!0;if(S7(e,"y"))return n.redo(),n._destroyToolBar(),!0;S7(e,"c")?(n.copy(),n._destroyToolBar()):S7(e,"x")?(n.cut(),n._destroyToolBar()):S7(e,"v")?(n.paste(),n._destroyToolBar()):S7(e,"l")?(n.layout(),n._destroyToolBar()):S7(e,"d")&&(n._destroyToolBar(),n.copy(),n.paste())}}wheel(e,t,n){const i=this.diagram;let r=i.zoom();const o=t.delta,a=i.options,s=a.zoomRate,l={point:e,meta:t,zoom:r,nativeEvent:n};if(!i.trigger(b4,l))return o<0?r+=s:r-=s,r=D7(Math.max(a.zoomMin,Math.min(a.zoomMax,r)),2),l.zoom=r,i.zoom(r,l),i.trigger(w4,l),!0}setTool(e,t){e.toolService=this,this.tools[t]=e}selectSingle(e,t){const n=this.diagram;const i=n.options.selectable;if(i&&!e.isSelected&&!1!==e.options.selectable){const r=t.ctrlKey&&!1!==i.multiple;n.select(e,{addToSelection:r})}}_discardNewConnection(){this.newConnection&&(this.diagram.remove(this.newConnection),this.newConnection=void 0)}_activateTool(e,t){for(let n=0;n<this.tools.length;n++){const i=this.tools[n];if(i.tryActivate(e,t)){this.activeTool=i;break}}}_updateCursor(e){const t=this.diagram.element;const n=this.activeTool?this.activeTool.getCursor(e):this.hoveredAdorner?this.hoveredAdorner._getCursor(e):this.hoveredItem?this.hoveredItem._getCursor(e):o4.arrow;t.style.cursor=n}_connectionManipulation(e,t,n){this.activeConnection=e,this.disabledShape=t,this.newConnection=n?this.activeConnection:void 0}_updateHoveredItem(e,t,n){const i=this._hitTest(e);const r=this.diagram;i===this.hoveredItem||this.disabledShape&&i===this.disabledShape||(this.hoveredItem&&(r.trigger(_4,{item:this.hoveredItem,nativeEvent:n,point:e,meta:t}),this.hoveredItem._hover(!1)),i&&i.options.enable?(r.trigger(v4,{item:i,nativeEvent:n,point:e,meta:t}),this.hoveredItem=i,this.hoveredItem._hover(!0)):this.hoveredItem=void 0)}_removeHover(){this.hoveredItem&&(this.hoveredItem._hover(!1),this.hoveredItem=void 0)}_hitTest(e){const t=this.diagram;let n,i,r;if(this._hoveredConnector&&(this._hoveredConnector._hover(!1),this._hoveredConnector=void 0),t._connectorsAdorner._visible&&(n=t._connectorsAdorner._hitTest(e),n))return n;if(n=this.diagram._resizingAdorner._hitTest(e),n){if(this.hoveredAdorner=t._resizingAdorner,0!==n.x||0!==n.y)return;n=void 0}else this.hoveredAdorner=void 0;if(!this.activeTool||"ConnectionTool"!==this.activeTool.type){const o=[];for(r=0;r<t._selectedItems.length;r++)i=t._selectedItems[r],i instanceof A7&&o.push(i);n=this._hitTestItems(o,e)}return n||this._hitTestElements(e)}_hitTestElements(e){const t=this.diagram;const n=this._hitTestItems(t.shapes,e);const i=this._hitTestItems(t.connections,e);let r;if((!this.activeTool||"ConnectionTool"!==this.activeTool.type)&&n&&i&&!function(e,t){let n,i,r;for(let o=0;o<e.connectors.length;o++)if(n=e.connectors[o],i=n.position(),r=new A6(i.x,i.y),r.inflate(a4,a4),r.contains(t))return n}(n,e)){const e=t.mainLayer;r=n6(n.visual,e.children)>n6(i.visual,e.children)?n:i}return r||n||i}_hitTestItems(e,t){let n,i,r;for(n=e.length-1;n>=0;n--)if(i=e[n],r=i._hitTest(t),r)return r}}class I7{constructor(e,t){this.connection=e,this.diagram=t,this.title="New connection"}undo(){this.diagram.remove(this.connection,!1)}redo(){this.diagram._addConnection(this.connection,!1)}}class z7{constructor(e,t){this.shape=e,this.diagram=t,this.title="New shape"}undo(){this.diagram.deselect(),this.diagram.remove(this.shape,!1)}redo(){this.diagram._addShape(this.shape,!1)}}class P7{constructor(e){this.units=[],this.title="Composite unit",void 0!==e&&this.units.push(e)}add(e){this.units.push(e)}undo(){for(let e=0;e<this.units.length;e++)this.units[e].undo()}redo(){for(let e=0;e<this.units.length;e++)this.units[e].redo()}}class L7{constructor(e){this.connection=e,this.diagram=e.diagram,this.targetConnector=e.targetConnector,this.title="Delete connection"}undo(){this.diagram._addConnection(this.connection,!1)}redo(){this.diagram.remove(this.connection,!1)}}class B7{constructor(e){this.shape=e,this.diagram=e.diagram,this.title="Deletion"}undo(){this.diagram._addShape(this.shape,!1),this.shape.select(!1)}redo(){this.shape.select(!1),this.diagram.remove(this.shape,!1)}}class H7{constructor(e){this.layoutState=e,this.diagram=e.diagram}initState(){this.froms=[],this.tos=[],this.subjects=[];this.layoutState.nodeMap.forEach(((e,t)=>{const n=this.diagram.getShapeById(e);n&&(this.subjects.push(n),this.froms.push(n.bounds().topLeft()),this.tos.push(t.topLeft()))}),this)}update(e){if(!(this.subjects.length<=0))for(let t=0;t<this.subjects.length;t++)this.subjects[t].position(new M6(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))}}class R7{constructor(e,t,n){F4(n)?this.animate=!1:this.animate=Boolean(n),this._initialState=e,this._finalState=t,this.title="Diagram layout"}undo(){this.setState(this._initialState)}redo(){this.setState(this._finalState)}setState(e){const t=e.diagram;if(this.animate){e.linkMap.forEach((function(e,n){const i=t.getShapeById(e);i.visible(!1),i&&i.points(n)}));const n=new y6;n.addAdapter(new H7(e)),n.onComplete((function(){e.linkMap.forEach((function(e){t.getShapeById(e).visible(!0)}))})),n.play()}else e.nodeMap.forEach((function(e,n){const i=t.getShapeById(e);i&&i.position(n.topLeft())})),e.linkMap.forEach((function(e,n){const i=t.getShapeById(e);i&&i.points(n)}))}}class F7{constructor(e,t,n){this.initial=e,this.finalPos=t,this.diagram=n,this.title="Pan Unit"}undo(){this.diagram.pan(this.initial)}redo(){this.diagram.pan(this.finalPos)}}class O7{constructor(e,t,n){this.diagram=e,this.indices=n,this.items=t,this.title="Rotate Unit"}undo(){this.diagram._toIndex(this.items,this.indices)}redo(){this.diagram.toBack(this.items,!1)}}class V7{constructor(e,t,n){this.diagram=e,this.indices=n,this.items=t,this.title="Rotate Unit"}undo(){this.diagram._toIndex(this.items,this.indices)}redo(){this.diagram.toFront(this.items,!1)}}class N7 extends v6{constructor(e={}){super(),this.events=["undone","redone"],this.bind(this.events,e),this.stack=[],this.index=0,this.capacity=100}begin(){this.composite=new P7}cancel(){this.composite=void 0}commit(e){this.composite.units.length>0&&this._restart(this.composite,e),this.composite=void 0}addCompositeItem(e){this.composite?this.composite.add(e):this.add(e)}add(e,t){this._restart(e,t)}pop(){this.index>0&&(this.stack.pop(),this.index--)}count(){return this.stack.length}undo(){this.index>0&&!this.trigger("undo",{unit:this.stack[this.index-1]})&&(this.index--,this.stack[this.index].undo(),this.trigger("undone"))}redo(){this.stack.length>0&&this.index<this.stack.length&&!this.trigger("redo",{unit:this.stack[this.index]})&&(this.stack[this.index].redo(),this.index++,this.trigger("redone"))}_restart(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(){this.stack=[],this.index=0}}class $7{constructor(e){this.dataItem=e,this.callbacks=[]}onActivate(e){return new Promise((t=>{this.callbacks.push({callback:e,resolve:t})}))}activate(){const e=this.callbacks;let t;for(let n=0;n<e.length;n++)t=this.callbacks[n],t.callback(this.dataItem),t.resolve();this.callbacks=[]}}class U7{constructor(){this.items={}}add(e){for(let t=0;t<e.length;t++)this.items[e[t].uid]=new $7(e[t])}forEach(e){for(const t in this.items)Object.prototype.hasOwnProperty.call(this.items,t)&&e(this.items[t])}getByUid(e){return this.items[e]}remove(e){delete this.items[e.uid]}destroy(){this.items={}}}class W7{constructor(){this.shapes=[]}_add(e,t){this.shapes.push({bounds:t,shape:e}),e._quadNode=this}insert(e,t){this._add(e,t)}remove(e){const t=this.shapes;const n=t.length;for(let i=0;i<n;i++)if(t[i].shape===e){t.splice(i,1);break}}hitTestRect(e,t){const n=this.shapes;const i=n.length;for(let r=0;r<i;r++)if(this._testRect(n[r].shape,e)&&!e6(t,n[r].shape))return!0}_testRect(e,t){const n=e.rotate().angle;const i=e.bounds();let r;return r=n?U6.rects(t,i,-n):i.overlaps(t),r}}class j7 extends W7{constructor(e){super(),this.children=[],this.rect=e}inBounds(e){const t=this.rect;const n=t.bottomRight();const i=e.bottomRight();return t.x<=e.x&&t.y<=e.y&&i.x<=n.x&&i.y<=n.y}overlapsBounds(e){return this.rect.overlaps(e)}insert(e,t){let n=!1;const i=this.children;const r=i.length;if(this.inBounds(t)){if(!r&&this.shapes.length<4)this._add(e,t);else{r||this._initChildren();for(let r=0;r<i.length;r++)if(i[r].insert(e,t)){n=!0;break}n||this._add(e,t)}n=!0}return n}_initChildren(){const e=this.rect,t=this.children,n=this.shapes,i=e.center(),r=e.width/2,o=e.height/2;let a,s;for(t.push(new j7(new A6(e.x,e.y,r,o)),new j7(new A6(i.x,e.y,r,o)),new j7(new A6(e.x,i.y,r,o)),new j7(new A6(i.x,i.y,r,o))),s=n.length-1;s>=0;s--)for(a=0;a<t.length;a++)if(t[a].insert(n[s].shape,n[s].bounds)){n.splice(s,1);break}}hitTestRect(e,t){let n;const i=this.children;const r=i.length;let o=!1;if(this.overlapsBounds(e))if(super.hitTestRect(e,t))o=!0;else for(n=0;n<r;n++)if(i[n].hitTestRect(e,t)){o=!0;break}return o}}class q7{constructor(e){this.ROOT_SIZE=1e3;const t=this._boundsChange.bind(this);e.bind(g4,t),e.bind(m4,t),this.initRoots()}initRoots(){this.rootMap={},this.root=new W7}clear(){this.initRoots()}_boundsChange(e){e.item._quadNode&&e.item._quadNode.remove(e.item),this.insert(e.item)}insert(e){const t=e.bounds(k4);const n=this.ROOT_SIZE;const i=this.getSectors(t);const r=i[0][0];const 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 j7(new A6(r*n,o*n,n,n))),this.rootMap[r][o].insert(e,t))}remove(e){e._quadNode&&e._quadNode.remove(e)}inRoot(e){return e[0].length>1||e[1].length>1}getSectors(e){const t=this.ROOT_SIZE;const n=e.bottomRight();const i=Math.floor(n.x/t);const r=Math.floor(n.y/t);const o=[[],[]];for(let n=Math.floor(e.x/t);n<=i;n++)o[0].push(n);for(let n=Math.floor(e.y/t);n<=r;n++)o[1].push(n);return o}hitTestRect(e,t){const n=this.getSectors(e);let i,r,o,a;let s;if(this.root.hitTestRect(e,t))return!0;for(i=0;i<n[0].length;i++)for(o=n[0][i],r=0;r<n[1].length;r++)if(a=n[1][r],s=(this.rootMap[o]||{})[a],s&&s.hitTestRect(e,t))return!0;return!1}}function G7(e,t,n){let i;for(let r=0;r<n.length;r++)i=n[r],t&&!H4(t[i])&&(t[i]=e[i])}const K7={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:W8({undoable:!0,connectors:void 0}),connectionDefaults:{editable:{tools:[]},type:M4},shapes:[],connections:[]};const Y7=["contextmenu","dblclick","pointerdown","pointermove","pointerup","pointercancel","pointerleave","touchstart","touchmove","touchend","touchcancel"];const Q7=[w4,b4,y4,D4,m4,g4,r4,"click",v4,_4,"toolBarClick","save","cancel","edit","remove","undo","redo","add","dataBound",...Y7,u4,p4,f4];function X7(e){const t=[];const n=[];let i,r;for(r=0;r<e.length;r++)i=e[r],i instanceof r9?n.push(i):t.push(i);return{shapes:n,connections:t}}function Z7(e,t=!1){let n=e.offsetHeight;if(t){const t=getComputedStyle(e);n+=parseFloat(t.marginTop)+parseFloat(t.marginBottom)}return n}class J7 extends v6{constructor(e,t,n){super(),this._clipboard=[],this._connectionsDataMap={},this._dataMap={},this._inactiveShapeItems=new U7,this._selectedItems=[],this.shapes=[],this.connections=[],this._deferredConnectionUpdates=[],this._domEvent=e=>{const t=this._meta(e);const n=this._eventPositions(e);const i=this.toolService._hitTest(n);this.trigger(e.type,{nativeEvent:e,item:i,point:n,meta:t})},this.element=e,this.options=P6({createToolBar:u6,destroyToolBar:u6},K7,t),this.events=Q7,this._initTheme(n),this._initElements(),this._extendLayoutOptions(this.options),this._initDefaults(t),this._interactionDefaults(),this._initCanvas(),this.mainLayer=new Q5({id:"main-layer"}),this.canvas.append(this.mainLayer),this._shapesQuadTree=new q7(this),this._pan=new M6,this._adorners=[],this.adornerLayer=new Q5({id:"adorner-layer"}),this.canvas.append(this.adornerLayer),this._createHandlers(),this._initialize(),this._resizingAdorner=new h9(this,{editable:this.options.editable}),this._connectorsAdorner=new s9(this),this._adorn(this._resizingAdorner,!0),this._adorn(this._connectorsAdorner,!0),this.selector=new p9(this),this._clipboard.length=0,this.pauseMouseHandlers=!1}_createShape(e,t){(t=P6({},this.options.shapeDefaults,t)).dataItem=e;return new r9(t,this)}_createConnection(e,t,n){const i=P6({},this.options.connectionDefaults);i.dataItem=e;return new A7(t||new M6,n||new M6,i)}_initElements(){this.element.innerHTML="",this.element.style.position="relative",this.element.setAttribute("tabindex","0"),this.element.classList.add("k-diagram"),this.scrollable=document.createElement("div"),this.element.appendChild(this.scrollable),this.wrapper=this.element}_initDefaults(e){const t=this.options;const n=t.editable;const i=t.shapeDefaults;const r=t.connectionDefaults;const o=(e||{}).shapeDefaults;!1===n?(i.editable=!1,r.editable=!1):(G7(n,i.editable,["drag","remove","connect"]),G7(n,r.editable,["drag","remove"])),o&&o.connectors&&(t.shapeDefaults.connectors=o.connectors)}_interactionDefaults(){const e=this.options;const t=e.selectable;const n=e.pannable;const i=this._mobileOS();t&&!H4(t.multiple)&&(e.selectable=P6({multiple:!i},e.selectable)),n&&!H4(n.key)&&(e.pannable=P6({key:i?"none":"ctrl"},e.pannable))}_initCanvas(){const e=document.createElement("div");e.classList.add("k-layer"),this.scrollable.appendChild(e);const t=this.viewport();this.canvas=new(this.options.Canvas||_5)(e,{width:t.width||600,height:t.height||600})}_createHandlers(){const e=this.element;this._wheelHandler=this._wheelHandler||this._wheel.bind(this),this._keydownHandler=this._keydownHandler||this._keydown.bind(this),this._mobileOS()&&this._mobileOS().browser.mobilesafari?e.addEventListener("mousewheel",this._wheelHandler):e.addEventListener("wheel",this._wheelHandler),e.addEventListener("keydown",this._keydownHandler),this._userEvents=new h7(this.scrollable,{multiTouch:!0,fastTap:!0,tap:this._tap.bind(this),start:this._dragStart.bind(this),move:this._drag.bind(this),end:this._dragEnd.bind(this),gesturestart:this._gestureStart.bind(this),gesturechange:this._gestureChange.bind(this),gestureend:this._gestureEnd.bind(this),doubleTap:this._doubleTap.bind(this),supportDoubleTap:!0}),this.toolService=new E7(this),this._mouseoverHandler=this._mouseoverHandler||this._mouseover.bind(this),this._mouseoutHandler=this._mouseoutHandler||this._mouseout.bind(this),this._mouseMoveHandler=this._mouseMoveHandler||this._mouseMove.bind(this),this._mouseDownHandler=this._mouseDownHandler||this._mouseDown.bind(this),this._mouseUpHandler=this._mouseUpHandler||this._mouseUp.bind(this),this.scrollable.addEventListener("mouseover",this._mouseoverHandler),this.scrollable.addEventListener("mouseout",this._mouseoutHandler),this.scrollable.addEventListener("mousemove",this._mouseMoveHandler),this.scrollable.addEventListener("mousedown",this._mouseDownHandler),this.scrollable.addEventListener("mouseup",this._mouseUpHandler),Y7.forEach((e=>{this.scrollable.addEventListener(e,this._domEvent)})),this._initResizeObserver(),this.bind(b4,this._destroyToolBar.bind(this)),this.bind(y4,this._destroyToolBar.bind(this))}_initResizeObserver(){const e=new ResizeObserver((e=>{e.forEach((e=>{const{width:t,height:n}=e.contentRect;e.target!==this.element||this.size&&this.size.width===t&&this.size.height===n||(this.size={width:t,height:n},this._resize(),this.trigger("resize",this.size))}))}));this._resizeObserver=e,e.observe(this.element)}_destroyResizeObserver(){this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)}_dragStart(e){this._pauseMouseHandlers=!0;const t=this._eventPositions(e,!0);this.toolService.start(t,this._meta(e),e.event)&&(this._destroyToolBar(),e.preventDefault())}_drag(e){const t=this._eventPositions(e);this.toolService.move(t,this._meta(e),e.event)&&e.preventDefault()}_dragEnd(e){this._pauseMouseHandlers=!1;const t=this._eventPositions(e);this.toolService.end(t,this._meta(e),e.event)&&(this.options.createToolBar(),e.preventDefault())}_mouseMove(e){if(!this._pauseMouseHandlers){const t=this._eventPositions(e);this.toolService._updateHoveredItem(t,this._meta(e),e),this.toolService._updateCursor(t)}}_mouseDown(){this._pauseMouseHandlers=!0}_mouseUp(){this._pauseMouseHandlers=!1}_tap(e){const t=this.toolService;const n=this.options.selectable;const i=this._eventPositions(e);const r=this.focus();const o=this._meta(e);if(t._updateHoveredItem(i,o,e.event),t.hoveredItem){const a=t.hoveredItem;if(this.trigger("click",{nativeEvent:e.event,item:a,point:i,meta:o}),n&&!1!==a.options.selectable){const e=!1!==n.multiple;const t=zr||o.ctrlKey||o.metaKey&&k7();a.isSelected?t?(this._destroyToolBar(),a.select(!1)):this.options.createToolBar(r):(this._destroyToolBar(),this.select(a,{addToSelection:e&&t}),this.options.createToolBar(r))}}else n&&(this._destroyToolBar(),this.deselect())}_keydown(e){this.toolService.keyDown(e.keyCode,this._meta(e))&&e.preventDefault()}_wheel(e){const t=function(e){let t=0;return e.wheelDelta?(t=-e.wheelDelta/40,t=t>0?Math.ceil(t):Math.floor(t)):e.detail&&(t=e.detail),t}(e),n=this._eventPositions(e),i=P6(this._meta(e),{delta:t});this.toolService.wheel(n,i,e)&&e.preventDefault()}_meta(e){return{ctrlKey:(e=e.event||e).ctrlKey,metaKey:e.metaKey,altKey:e.altKey,shiftKey:e.shiftKey,type:e.type}}_eventPositions(e,t){let n;if(e.touch){const i=t?"startLocation":"location";n=new M6(e.x[i],e.y[i])}else n=new M6(e.pageX,e.pageY);return this.documentToModel(n)}_gestureStart(e){this._destroyToolBar(),this.scroller.disable();const t=this.documentToModel(new M6(e.center.x,e.center.y));const n={point:t,zoom:this.zoom()};this.trigger(b4,n)||(this._gesture=e,this._initialCenter=t)}_gestureChange(e){const t=this._gesture;const n=this._initialCenter;const i=this.documentToView(new M6(e.center.x,e.center.y));const r=e.distance/t.distance;let o=this._zoom;let a=!1;Math.abs(r-1)>=.05&&(this._zoom=o=this._getValidZoom(o*r),this.options.zoom=o,this._gesture=e,a=!0);const s=n.times(o);const l=i.minus(s);(a||this._pan.distanceTo(l)>=5)&&(this._panTransform(l),this._updateAdorners()),e.preventDefault()}_doubleTap(e){const t=this._eventPositions(e);const n=this.options;const i=n.zoomRate;let r=this.zoom()+i;const o={point:t,meta:this._meta(e),zoom:r};this.trigger(b4,o)||(r=Wo(Math.max(n.zoomMin,Math.min(n.zoomMax,r)),2),o.zoom=r,this.zoom(r,o),this.trigger(w4,o))}_gestureEnd(){!1!==this.options.pannable&&this.scroller.enable(),this.trigger(w4,{point:this._initialCenter,zoom:this.zoom()})}_resize(){const e=this.viewport();this.canvas&&this.canvas.size(e),this.scrollable&&this.toolBar&&(this.scrollable.style.height=e.height+"px")}_mouseover(e){const t=e.target._kendoNode;t&&t.srcElement._hover&&t.srcElement._hover(!0,t.srcElement)}_mouseout(e){const t=e.target._kendoNode;t&&t.srcElement._hover&&t.srcElement._hover(!1,t.srcElement)}_initTheme(e){this.options=P6({},e,this.options),!0===this.options.editable&&(this.options.editable=(e||{}).editable)}_createOptionElements(){const e=this.options;const t=e.shapes.length;t&&this._createShapes(),e.connections.length&&this._createConnections(),t&&e.layout&&this.layout(e.layout)}_createShapes(){const e=this.options.shapes;let t,n;for(n=0;n<e.length;n++)t=e[n],this.addShape(t)}_createConnections(){const e=this.options,t=e.connectionDefaults,n=e.connections;let i,r,o,a;for(a=0;a<n.length;a++)i=n[a],r=this._findConnectionTarget(i.from),o=this._findConnectionTarget(i.to),this.options.connect?this.options.connect(r,o,P6({},t,i)):this.connect(r,o,P6({},t,i))}_findConnectionTarget(e){const t=N4(e=e||{})?e:e.shapeId||e.id;let n;return t?(n=this.getShapeById(t),e.connector&&(n=n.getConnector(e.connector))):n=new M6(e.x||0,e.y||0),n}destroy(){super.destroy(),this._destroyResizeObserver(),this._userEvents&&this._userEvents.destroy(),this.clear(),this.element.removeEventListener("mousewheel",this._wheelHandler),this.element.removeEventListener("wheel",this._wheelHandler),this.element.removeEventListener("keydown",this._keydownHandler),this.scrollable.removeEventListener("mouseover",this._mouseoverHandler),this.scrollable.removeEventListener("mouseout",this._mouseoutHandler),this.scrollable.removeEventListener("mousemove",this._mouseMoveHandler),this.scrollable.removeEventListener("mousedown",this._mouseDownHandler),this.scrollable.removeEventListener("mouseup",this._mouseUpHandler),Y7.forEach((e=>{this.scrollable.removeEventListener(e,this._domEvent)})),this.canvas.destroy(!0),this.canvas=void 0,this.destroyScroller(),this._destroyGlobalToolBar(),this._destroyToolBar(),this._inactiveShapeItems.destroy()}destroyScroller(){const e=this.scroller;e&&(e.destroy(),e.element.remove(),this.scroller=null)}save(){const e={shapes:[],connections:[]};let t,n,i;for(t=0;t<this.shapes.length;t++)i=this.shapes[t],i.options.serializable&&e.shapes.push(i.options);for(t=0;t<this.connections.length;t++)n=this.connections[t],e.connections.push(P6({},n.options,n.toJSON()));return e}focus(){if(this.element!==this.element.ownerDocument.activeElement){const e=this.element,t=[],n=[],i=e.ownerDocument.documentElement;let r,o=e;do{o=o.parentNode,o.scrollHeight>o.clientHeight&&(t.push(o),n.push(o.scrollTop))}while(o!==i);for(e.focus({preventScroll:!0}),r=0;r<t.length;r++)t[r].scrollTop=n[r];return!0}}load(e){this.clear(),this.setOptions(e),this._createShapes(),this._createConnections()}setOptions(e){P6(this.options,e)}clear(){this.select(!1),this.mainLayer.clear(),this._shapesQuadTree.clear(),this._initialize()}connected(e,t){for(let n=0;n<this.connections.length;n++){const i=this.connections[n];if(i.from===e&&i.to===t)return!0}return!1}addConnection(e,t){return!1!==t&&this.undoRedoService.add(new I7(e,this),!1),e.diagram=this,e._setOptionsFromModel(),e.refresh(),this.mainLayer.append(e.visual),this.connections.push(e),this.trigger(r4,{added:[e],removed:[]}),e}addShape(e,t){let n,i=this.options.shapeDefaults;if(e instanceof r9)n=e,this._parseBounds(n.bounds());else{if(e.prototype)return;i=P6({},i,e||{}),n=new r9(i,this),this._parseBounds(n.bounds())}return!1!==t&&this.undoRedoService.add(new z7(n,this),!1),this.shapes.push(n),n.diagram!==this&&(this._shapesQuadTree.insert(n),n.diagram=this),this.mainLayer.append(n.visual),this.trigger(r4,{added:[n],removed:[]}),n}remove(e,t){const n=X7(e=Array.isArray(e)?e.slice(0):[e]);const i=n.shapes;const r=n.connections;let o;for(H4(t)||(t=!0),t&&this.undoRedoService.begin(),this._suspendModelRefresh(),o=i.length-1;o>=0;o--)this._removeItem(i[o],t,r);for(o=r.length-1;o>=0;o--)this._removeItem(r[o],t);this._resumeModelRefresh(),t&&this.undoRedoService.commit(!1),this.trigger(r4,{added:[],removed:e})}_addConnection(e,t){return this.options._addConnection?this.options._addConnection(e,t):this.trigger("add",{connection:e})?void 0:(this.addConnection(e,t),e._updateConnectors(),e)}_addShape(e,t){return this.options._addShape?this.options._addShape(e,t):this.trigger("add",{shape:e})?void 0:this.addShape(e,t)}_parseBounds(e){e.x="string"==typeof e.x?parseFloat(e.x):e.x,e.y="string"==typeof e.y?parseFloat(e.y):e.y}_shouldRefresh(){return!this._suspended}_suspendModelRefresh(){this._suspended=(this._suspended||0)+1}_resumeModelRefresh(){this._suspended=Math.max((this._suspended||0)-1,0)}_triggerRemove(e){const t=[];let n,i,r;for(let o=0;o<e.length;o++)n=e[o],r=n.options.editable,i=n instanceof r9?{shape:n}:{connection:n},r&&!1!==r.remove&&!this.trigger("remove",i)&&t.push(n);return t}_addConnections(e,t){const n=e.length;for(let i=0;i<n;i++){const n=e[i];this._addConnectionDataItem(n,t)}}_addConnectionDataItem(e,t){if(!this._connectionsDataMap[e.uid]){let n=this._validateConnector(e.from);H4(n)&&null!==n||(n=new M6(e.fromX,e.fromY));let i=this._validateConnector(e.to);if(H4(i)&&null!==i||(i=new M6(e.toX,e.toY)),H4(n)&&H4(i)){const r=P6({},this.options.connectionDefaults);r.dataItem=e;const o=new A7(n,i,r);this._connectionsDataMap[e.uid]=o,this.addConnection(o,t)}}}_validateConnector(e){let t;return H4(e)&&null!==e&&(t=this._dataMap[e]),t}_addDataItems(e,t){let n,i,r,o;for(i=0;i<e.length;i++)n=e[i],r=this._addDataItemByUid(n),o=this._addDataItemByUid(t),o&&!this.connected(o,r)&&this.connect(o,r)}connect(e,t,n){const i=P6({},this.options.connectionDefaults,n);const r=new A7(e,t,i);return this.addConnection(r)}undo(){this.undoRedoService.undo()}redo(){this.undoRedoService.redo()}select(e,t){if(!B4(e))return this._selectedItems;{const n=[];let i,r,o=[];for((t=P6({addToSelection:!1},t)).addToSelection||this.deselect(),this._internalSelection=!0,e instanceof Array?o=e:e instanceof n9&&(o=[e]),i=0;i<o.length;i++)r=o[i],r.select(!0)&&n.push(r);this._selectionChanged(n,[]),this._internalSelection=!1}}selectAll(){this.select(this.shapes.concat(this.connections))}selectArea(e){let t,n,i;this._internalSelection=!0;const r=[];if(e instanceof A6)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(e){this._internalSelection=!0;const t=[];let n,i,r=[];for(e instanceof Array?r=e:e instanceof n9?r.push(e):B4(e)||(r=this._selectedItems.slice(0)),i=0;i<r.length;i++)n=r[i],n.select(!1)&&t.push(n);this._selectionChanged([],t),this._internalSelection=!1}toFront(e,t){e||(e=this._selectedItems.slice());const n=this._getDiagramItems(e);let i;if(!H4(t)||t){i=L8(this.mainLayer,n.visuals);const t=new V7(this,e,i);this.undoRedoService.add(t)}else this.mainLayer.toFront(n.visuals),this._fixOrdering(n,!0)}toBack(e,t){e||(e=this._selectedItems.slice());const n=this._getDiagramItems(e);let i;if(!H4(t)||t){i=L8(this.mainLayer,n.visuals);const t=new O7(this,e,i);this.undoRedoService.add(t)}else this.mainLayer.toBack(n.visuals),this._fixOrdering(n,!1)}bringIntoView(e,t){const n=this.viewport();const i=new D6(n);let r;if(0===n.width||0===n.height)return;"none"===(t=P6({animate:!1,align:"center middle"},t)).align&&(t.align="center middle"),e instanceof n9?r=e.bounds(P4):Array.isArray(e)?r=this.boundingBox(e):e instanceof A6&&(r=e.clone());const o=r.clone();r.zoom(this._zoom),(r.width>n.width||r.height>n.height)&&(this._zoom=this._getValidZoom(Math.min(n.width/o.width,n.height/o.height)),r=o.clone().zoom(this._zoom)),this._zoomMainLayer();const a=r.clone();i.align(r,t.align);const s=r.topLeft().minus(a.topLeft());this.pan(s.times(-1),t.animate)}alignShapes(e){let t,n,i;F4(e)&&(e="Left");const r=this.select();if(0===r.length)return;switch(e.toLowerCase()){case"left":case"top":t=I4;break;case"right":case"bottom":t=z4}for(i=0;i<r.length;i++)if(n=r[i],n instanceof r9)switch(e.toLowerCase()){case"left":t=Math.min(t,n.options.x);break;case"top":t=Math.min(t,n.options.y);break;case"right":t=Math.max(t,n.options.x);break;case"bottom":t=Math.max(t,n.options.y)}const o=[];const a=[];for(i=0;i<r.length;i++)if(n=r[i],n instanceof r9)switch(a.push(n),o.push(n.bounds()),e.toLowerCase()){case"left":case"right":n.position(new M6(t,n.options.y));break;case"top":case"bottom":n.position(new M6(n.options.x,t))}const s=new c9(a,o);this.undoRedoService.add(s,!1)}zoom(e,t){if(e){let n=t?t.point:new M6(0,0);if(e=this._zoom=this._getValidZoom(e),!F4(n)){n=new M6(Math.round(n.x),Math.round(n.y));const t=n.times(e);const i=this.modelToView(n).minus(t);this._storePan(new M6(Math.round(i.x),Math.round(i.y)))}t&&(t.zoom=e),this._panTransform(),this.canvas.surface.hideTooltip&&this.canvas.surface.hideTooltip(),this._updateAdorners()}return this._zoom}_getPan(e){return this.canvas.translate||(e=e.plus(this._pan)),e}pan(e,t){if(!(e instanceof M6))return this._pan.times(-1);{const n=this.scroller;e=(e=this._getPan(e)).times(-1),t?n.animatedScrollTo(e.x,e.y,(()=>{this._updateAdorners()})):(n.scrollTo(e.x,e.y),this._updateAdorners())}}viewport(){const e=this.element;const t=function(e){const t=getComputedStyle(e);return e.clientWidth-parseFloat(t.paddingLeft)-parseFloat(t.paddingRight)}(e);let n=function(e){const t=getComputedStyle(e);return e.clientHeight-parseFloat(t.paddingTop)-parseFloat(t.paddingBottom)}(e);return this.toolBar&&(n-=Z7(this.toolBar.element)),new A6(0,0,t,n)}copy(){if(this.options.copy.enabled){this._clipboard.length=0,this._copyOffset=1;for(let e=0;e<this._selectedItems.length;e++){const t=this._selectedItems[e];this._clipboard.push(t)}}}cut(){if(this.options.copy.enabled){this._clipboard.length=0,this._copyOffset=0;for(let e=0;e<this._selectedItems.length;e++){const t=this._selectedItems[e];this._clipboard.push(t)}this.remove(this._clipboard,!0)}}paste(){if(this._clipboard.length>0){let e,t,n;const i={};const r=X7(this._clipboard);const o=r.connections;const a=r.shapes;const s={x:this._copyOffset*this.options.copy.offsetX,y:this._copyOffset*this.options.copy.offsetY};for(this.deselect(),n=0;n<a.length;n++)e=a[n],t=e.clone(),i[e.id]=t,t.position(new M6(e.options.x+s.x,e.options.y+s.y)),t.diagram=this,t=this._addShape(t),t&&t.select();for(n=0;n<o.length;n++)e=o[n],t=this._addConnection(e.clone()),t&&(this._updateCopiedConnection(t,e,"source",i,s),this._updateCopiedConnection(t,e,"target",i,s),t.select(!0),t.updateModel());this._syncChanges(),this._copyOffset+=1}}_syncChanges(){this.options._syncChanges&&this.options._syncChanges()}_syncConnectionChanges(){this.options._syncConnectionChanges&&this.options._syncConnectionChanges()}_syncShapeChanges(){this.options._syncShapeChanges&&this.options._syncShapeChanges()}_updateCopiedConnection(e,t,n,i,r){let o,a,s;const l=t[n]();l instanceof $8&&i[l.shape.id]?(s=i[l.shape.id],this.getShapeById(s.id)?e[n](s.getConnector(l.options.name)):(a=this._inactiveShapeItems.getByUid(s.dataItem.uid),a&&(o=t=>{s=this._dataMap[t.id],e[n](s.getConnector(l.options.name)),e.updateModel()},this._deferredConnectionUpdates.push(a.onActivate(o))))):e[n](new M6(t[n+"Point"]().x+r.x,t[n+"Point"]().y+r.y))}boundingBox(e,t){let n,i=A6.empty();const r=B4(e)?this._getDiagramItems(e):{shapes:this.shapes};if(r.shapes.length>0){let e=r.shapes[0];i=e.bounds(k4);for(let o=1;o<r.shapes.length;o++)e=r.shapes[o],n=e.bounds(k4),!0===t&&(n.x-=e._rotationOffset.x,n.y-=e._rotationOffset.y),i=i.union(n)}return i}_containerOffset(){const e=function(e){const t=e.getBoundingClientRect();const n=e.ownerDocument;const i=n.defaultView.scrollX||n.documentElement.scrollLeft||0;const r=n.defaultView.scrollY||n.documentElement.scrollTop||0;return{top:t.top+r,left:t.left+i}}(this.element);return this.toolBar&&(e.top+=Z7(this.toolBar.element)),e}documentToView(e){const t=this._containerOffset();return new M6(e.x-t.left,e.y-t.top)}viewToDocument(e){const t=this._containerOffset();return new M6(e.x+t.left,e.y+t.top)}viewToModel(e){return this._transformWithMatrix(e,this._matrixInvert)}modelToView(e){return this._transformWithMatrix(e,this._matrix)}modelToLayer(e){return this._transformWithMatrix(e,this._layerMatrix)}layerToModel(e){return this._transformWithMatrix(e,this._layerMatrixInvert)}documentToModel(e){const 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(e){return this.viewToDocument(this.modelToView(e))}_transformWithMatrix(e,t){let n=e;if(e instanceof M6)t&&(n=t.apply(e));else{const i=this._transformWithMatrix(e.topLeft(),t),r=this._transformWithMatrix(e.bottomRight(),t);n=A6.fromPoints(i,r)}return n}layout(e){let t;let n;switch(this._layouting=!0,F4(e)&&(e=this.options.layout),t=F4(e)||F4(e.type)?"Tree":e.type,t.toLowerCase()){case"tree":n=new D8(this);break;case"layered":n=new M8(this);break;case"forcedirected":case"force":case"spring":case"springembedder":n=new V6(this);break;default:throw new Error("Layout algorithm '"+t+"' is not supported.")}const i=new H6(this);const r=n.layout(e);if(r){const t=new R7(i,r,e?e.animate:null);this.undoRedoService.add(t)}this._layouting=!1,this._redrawConnections()}getShapeById(e){let t;return t=a6(this.shapes,(function(t){return t.visual.id===e})),t||(t=a6(this.connections,(function(t){return t.visual.id===e})),t)}getShapeByModelId(e){let t;return t=this._isEditable?this._dataMap[e]:a6(this.shapes,(function(t){return(t.dataItem||{}).id===e})),t}getShapeByModelUid(e){let t;return t=this._isEditable?a6(this.shapes,(function(t){return(t.dataItem||{}).uid===e})):this._dataMap[e],t}_extendLayoutOptions(e){e.layout&&(e.layout=P6({},L6,e.layout))}_selectionChanged(e,t){(e.length||t.length)&&this.trigger(D4,{selected:e,deselected:t})}_getValidZoom(e){return Math.min(Math.max(e,this.options.zoomMin),this.options.zoomMax)}_panTransform(e){const t=e||this._pan;this.canvas.translate?(this.scroller.scrollTo(t.x,t.y),this._zoomMainLayer()):(this._storePan(t),this._transformMainLayer())}_finishPan(){this.trigger(y4,{total:this._pan,delta:Number.NaN})}_storePan(e){this._pan=e,this._storeViewMatrix()}_zoomMainLayer(){const e=this._zoom;const t=new e5(0,0,e,e);t.render(this.mainLayer),this._storeLayerMatrix(t),this._storeViewMatrix()}_transformMainLayer(){const e=this._pan,t=this._zoom;const n=new e5(e.x,e.y,t,t);n.render(this.mainLayer),this._storeLayerMatrix(n),this._storeViewMatrix()}_storeLayerMatrix(e){this._layerMatrix=e.toMatrix(),this._layerMatrixInvert=e.invert().toMatrix()}_storeViewMatrix(){const e=this._pan,t=this._zoom;const n=new e5(e.x,e.y,t,t);this._matrix=n.toMatrix(),this._matrixInvert=n.invert().toMatrix()}_toIndex(e,t){const n=this._getDiagramItems(e);this.mainLayer.toIndex(n.visuals,t),this._fixOrdering(n,!1)}_fixOrdering(e,t){const n=t?this.shapes.length-1:0,i=t?this.connections.length-1:0;let r,o;for(r=0;r<e.shapes.length;r++)o=e.shapes[r],J4(this.shapes,o),s6(this.shapes,o,n);for(r=0;r<e.cons.length;r++)o=e.cons[r],J4(this.connections,o),s6(this.connections,o,i)}_getDiagramItems(e){let t,n=e;const i={};for(i.visuals=[],i.shapes=[],i.cons=[],e?Array.isArray(e)||(n=[e]):n=this._selectedItems.slice(),t=0;t<n.length;t++){const e=n[t];e instanceof r9?(i.shapes.push(e),i.visuals.push(e.visual)):e instanceof A7&&(i.cons.push(e),i.visuals.push(e.visual))}return i}_addDataItemByUid(e){if(!H4(e))return;let t=this._dataMap[e.uid];if(t)return t;const n=P6({},this.options.shapeDefaults);return n.dataItem=e,t=new r9(n,this),this.addShape(t),this._dataMap[e.uid]=t,t}_addItem(e){e instanceof r9?this.addShape(e):e instanceof A7&&this.addConnection(e)}_toolBarClick(e){this.trigger("toolBarClick",e),this._destroyToolBar()}_normalizePointZoom(e){return e.times(1/this.zoom())}_initialize(){this.shapes.length=0,this.connections.length=0,this._selectedItems.length=0,Object.keys(this._dataMap).forEach((e=>{delete this._dataMap[e]})),Object.keys(this._connectionsDataMap).forEach((e=>{delete this._connectionsDataMap[e]})),this._deferredConnectionUpdates.length=0,this.undoRedoService=new N7({undone:this._syncChanges.bind(this),redone:this._syncChanges.bind(this)}),this.undoRedoService.bind("undo",(e=>{this.trigger("undo",e)})),this.undoRedoService.bind("redo",(e=>{this.trigger("redo",e)})),this.id=k6()}_redrawConnections(){const e=this.connections;for(let t=0;t<e.length;t++)e[t].refresh()}_adorn(e,t){void 0!==t&&e&&(t?(this._adorners.push(e),this.adornerLayer.append(e.visual)):(J4(this._adorners,e),this.adornerLayer.remove(e.visual)))}_showConnectors(e,t){t?this._connectorsAdorner.show(e):this._connectorsAdorner.destroy()}_updateAdorners(){const e=this._adorners;for(let t=0;t<e.length;t++){const n=e[t];n.refreshBounds&&n.refreshBounds(),n.refresh()}}_refresh(){for(let e=0;e<this.connections.length;e++)this.connections[e].refresh()}_removeItem(e,t,n){e.select(!1),e instanceof r9?(this._removeShapeDataItem(e),this._removeShape(e,t,n)):e instanceof A7&&(this._removeConnectionDataItem(e),this._removeConnection(e,t)),this.mainLayer.remove(e.visual)}_removeConnectionDataItem(e){this._isEditable&&(this.options._removeConnectionDataItem(e.dataItem),delete this._connectionsDataMap[e.dataItem.uid])}_removeShapeDataItem(e){this._isEditable&&(this.options._removeShapeDataItem(e.dataItem),delete this._dataMap[e.dataItem.id])}_removeShape(e,t,n){let i,r,o;const a=[],s=[];for(this.toolService._removeHover(),t&&this.undoRedoService.addCompositeItem(new B7(e)),J4(this.shapes,e),this._shapesQuadTree.remove(e),i=0;i<e.connectors.length;i++){o=e.connectors[i];for(let e=0;e<o.connections.length;e++)r=o.connections[e],n&&e6(n,r)||(r.sourceConnector===o?a.push(r):r.targetConnector===o&&s.push(r))}for(i=0;i<a.length;i++)a[i].source(null,t),a[i].updateModel();for(i=0;i<s.length;i++)s[i].target(null,t),s[i].updateModel()}_removeConnection(e,t){e.sourceConnector&&J4(e.sourceConnector.connections,e),e.targetConnector&&J4(e.targetConnector.connections,e),t&&this.undoRedoService.addCompositeItem(new L7(e)),J4(this.connections,e)}_removeShapeConnections(e){const t=e.connections();let n;if(t)for(n=0;n<t.length;n++)this._removeItem(t[n],!1)}_destroyToolBar(){this.options.destroyToolBar()}_destroyGlobalToolBar(){this.toolBar&&(this.toolBar=null)}_mobileOS(){return zr}exportDOMVisual(){const e=this.canvas._viewBox;const t=xa().translate(-e.x,-e.y);const n=new ya([0,0],[e.width,e.height]);const i=Rs.fromRect(n);const r=new Us({transform:t});const o=new Us({clip:i});const a=this.canvas.drawingElement.children[0];return o.append(r),r.children.push(a),o}exportVisual(){const e=1/this._zoom;const t=xa().scale(e,e);const n=new Us({transform:t});const i=this.mainLayer.drawingElement;return n.children.push(i),n}updateConnectionModel(e,t){if(this.options.updateConnectionModel)return this.options.updateConnectionModel(e,t)}updateShapeModel(e,t){if(this.options.updateShapeModel)return this.options.updateShapeModel(e,t)}}!function(){var e=window.kendo,t=e.dataviz.diagram={};e.deepExtend(t,{init:function(n){e.init(n,t.ui)},Utils:_6,Range:b6,Ticker:y6})}(),function(){var e=window.kendo,t=e.dataviz.diagram;e.deepExtend(t,{init:function(n){e.init(n,t.ui)},Point:M6,Intersect:U6,Geometry:S6,Rect:A6,Size:Q6,RectAlign:D6,Matrix:q6,MatrixVector:j6,normalVariable:G6,randomId:k6,Dictionary:C6,HashTable:x6,Queue:E6,Set:Y6,Node:R6,Link:F6,Graph:O6,PathDefiner:K6})}();const{isFunction:eee}=_6;!function(){var e=window.kendo,t=e.drawing,n=e.dataviz.diagram;e.deepExtend(n,{init:function(t){e.init(t,n.ui)},diffNumericOptions:t5,Markers:e4,Element:n5,Scale:Z6,Translation:J6,Rotation:X6,Circle:w5,Group:Q5,Rectangle:x5,Canvas:class extends _5{constructor(e,n){super(e,n=n||{}),this.surface=t.Surface.create(e,n),this.translate=eee(this.surface.translate)?this._translate:void 0,this._viewBox=new A6(0,0,n.width,n.height),this.size(this._viewBox)}},Path:h8,Layout:e8,Line:n8,MarkerBase:m5,ArrowMarker:v5,CircleMarker:k5,Polyline:u8,CompositeTransform:e5,TextBlock:x8,Terminator:K5,Process:v8,Decision:L5,PredefinedProcess:f8,Document:q5,ManualInputOutput:r8,Preparation:g8,ManualOperation:a8,InternalStorage:J5,Display:V5,DirectAccessStorage:F5,Database:I5,OnPageConnector:M5,OffPageConnector:d8,DataInputOutput:D5,SummingJunction:w8,LogicalOr:l8,Merge:s8,Extract:Y5,DataStorage:P5,Delay:H5,Sort:b8,Collate:T5,MultipleDocuments:G5,Image:X5,VisualBase:p5})}(),function(){var e=window.kendo,t=e.dataviz.diagram;t.Cursors=o4,e.deepExtend(t,{CompositeUnit:P7,TransformUnit:c9,PanUndoUnit:F7,AddShapeUnit:z7,AddConnectionUnit:I7,DeleteShapeUnit:B7,DeleteConnectionUnit:L7,ConnectionEditAdorner:o9,ConnectionTool:y9,ConnectorVisual:a9,UndoRedoService:N7,ResizingAdorner:h9,Selector:p9,ToolService:E7,ConnectorsAdorner:s9,LayoutUndoUnit:R7,ConnectionEditUnit:T7,ToFrontUnit:V7,ToBackUnit:O7,ConnectionRouterBase:f9,PolylineRouter:b9,CascadingRouter:_9,SelectionTool:C7,ScrollerTool:x7,PointerTool:C9,ConnectionEditTool:w9,RotateUnit:V8})}(),function(){var e=window.kendo,t=e.dataviz.diagram;e.deepExtend(t,{init:function(n){e.init(n,t.ui)},SpringLayout:V6,TreeLayout:D8,GraphAdapter:N6,LayeredLayout:M8,LayoutBase:B6,LayoutState:H6})}(),function(){const e=window.kendo.dataviz;const t=e=>e.ownerDocument.defaultView.getComputedStyle(e);const n={};const i=(e,i)=>{let r=t(e).getPropertyValue(i);return/^color-mix/i.test(r)&&(r=((e,i)=>{if(n[e])return n[e];const r=i.style.color;i.style.color=e;const o=t(i).color;return i.style.color=r,n[e]=o,o})(r,e)),r};e.diagramTheme=e=>{const t=i(e,"--kendo-chart-primary-bg");const n=i(e,"--kendo-chart-primary-contrast");const r=i(e,"--kendo-chart-text");return{shapeDefaults:{fill:{color:t},content:{color:n},connectorDefaults:{fill:{color:r},stroke:{color:n},hover:{fill:{color:n},stroke:{color:r}}}},editable:{resize:{handles:{stroke:{color:r},fill:{color:i(e,"--kendo-color-surface")},hover:{stroke:{color:r},fill:{color:r}}}}},selectable:{stroke:{color:r}},connectionDefaults:{stroke:{color:r},content:{color:r},selection:{handles:{fill:{color:n},stroke:{color:r},width:8,height:8},stroke:{color:r}}}}}}(),function(e){var t=kendo.dataviz,n=t.diagram,i=kendo.ui.Widget,r=kendo.deepExtend,o=kendo._outerWidth,a=kendo._outerHeight,s=e.extend,l=kendo.data.HierarchicalDataSource,c=n.Canvas,d=(n.Rect,n.Point),h=kendo.drawing.util.defined,u=e.isPlainObject,p=kendo.data.DataSource;q8.register({compile:function(e){return kendo.template(e,{paramName:"dataItem"})}});var f=".kendoDiagram",m="click",g="change",v="error",_=({className:e,icon:t,themeColor:n,text:i})=>kendo.html.renderButton(`<button class="${e}" href="#">${i}</button>`,{icon:t,themeColor:n});function b(e){e.preventDefault()}function w(e,t){h(t[e])&&t.set(e,null)}n.DefaultConnectors=U8;var y={cancel:{text:"Cancel",icon:"cancel-outline",className:"k-diagram-cancel"},update:{text:"Save",imageClass:"save",className:"k-diagram-update",icon:"save",themeColor:"primary"}};n.shapeDefaults=W8;var k=i.extend({init:function(t,n={}){var r=this;kendo.destroy(t),i.fn.init.call(r,t,n);const o=r._initTheme();const a=h(n.connectionsDataSource);this._isEditable=a;const s={...r.options,_syncChanges:r._syncChanges.bind(r),_syncShapeChanges:r._syncShapeChanges.bind(r),_syncConnectionChanges:r._syncConnectionChanges.bind(r),_removeConnectionDataItem:r._removeConnectionDataItem.bind(r),_removeShapeDataItem:r._removeShapeDataItem.bind(r),_addConnection:r._addConnection.bind(r),_addShape:r._addShape.bind(r),updateConnectionModel:r.updateConnectionModel.bind(r),updateShapeModel:r.updateShapeModel.bind(r),cloneDataItem:M,connect:a?r.connect.bind(r):undefined,createToolBar:r._createToolBar.bind(r),destroyToolBar:r._destroyToolBar.bind(r),Canvas:c,shapeDefaults:{...n.shapeDefaults},connectionDefaults:{...n.connectionDefaults}};const l=new J7(t,s,o);r.events.forEach((function(e){l.bind(e,(function(t){t.sender=r,r.trigger(e,t)}))})),r.widget=l,r.wrapper=e(l.wrapper),r.scrollable=e(l.scrollable),r.shapes=l.shapes,r.connections=l.connections,r._connectionsDataMap=l._connectionsDataMap,r._dataMap=l._dataMap,r._inactiveShapeItems=l._inactiveShapeItems,r._copyOffset=0,r._selectedItems=l._selectedItems,r.options=l.options,r._clipboard=l._clipboard,r.id=l.id,r.undoRedoService=l.undoRedoService,r.toolService=l.toolService,r._resizingAdorner=l._resizingAdorner,r._connectorsAdorner=l._connectorsAdorner,r.selector=l.selector,r.mainLayer=l.mainLayer,r._fetchFreshData(),r._createGlobalToolBar(),r.widget._createOptionElements(),r.widget.zoom(r.options.zoom),r.widget.canvas.draw()},options:r({},K7),events:[...Q7],shapes:[],connections:[],dataSource:null,connectionsDataSource:null,connect:function(e,t,n){let i;if(this.connectionsDataSource&&this._isEditable){const r=this.connectionsDataSource.add({});i=this.widget._connectionsDataMap[r.uid],i.source(e),i.target(t),i.redraw(n),i.updateModel()}else i=this.widget.connect(e,t,n);return i},connected:function(e,t){return this.widget.connected(e,t)},addConnection:function(e,t){return this.widget.addConnection(e,t)},addShape:function(e,t){return this.widget.addShape(e,t)},remove:function(e,t){return this.widget.remove(e,t)},undo:function(){return this.widget.undo()},redo:function(){return this.widget.redo()},select:function(e,t){return this.widget.select(e,t)},deselect:function(e){this.widget.deselect(e)},toFront:function(e,t){return this.widget.toFront(e,t)},toBack:function(e,t){return this.widget.toBack(e,t)},bringIntoView:function(e,t){return this.widget.bringIntoView(e,t)},boundingBox:function(e,t){return this.widget.boundingBox(e,t)},layout:function(e){return this.widget.layout(e)},getShapeById:function(e){return this.widget.getShapeById(e)},getConnectionByModelId(e){let t;return this.connectionsDataSource&&(t=a6(this.connections,(function(t){return(t.dataItem||{}).id===e}))),t},getConnectionByModelUid(e){let t;return this.connectionsDataSource&&(t=this.widget._connectionsDataMap[e]),t},copy:function(){this.widget.copy()},cut:function(){this.widget.cut()},alignShapes:function(e){return this.widget.alignShapes(e)},createShape:function(){if(this.editor&&this.editor.end()||!this.editor){var e=this.dataSource;var t=(e.view()||[]).length;var n=A(e,{});var i=this.widget._createShape(n,{});if(!this.trigger("add",{shape:i}))e.insert(t,n),this.widget._inactiveShapeItems.getByUid(n.uid).element=i,this.edit(i)}},createConnection:function(){if(this.editor&&this.editor.end()||!this.editor){var e=this.connectionsDataSource;var t=(e.view()||[]).length;var n=A(e,{});var i=this.widget._createConnection(n);this.trigger("add",{connection:i})||(this.widget._connectionsDataMap[n.uid]=i,e.insert(t,n),this.addConnection(i,!1),this.edit(i))}},exportVisual:function(){return this.widget.exportVisual()},exportDOMVisual:function(){return this.widget.exportDOMVisual()},_syncChanges(){this._syncShapeChanges(),this._syncConnectionChanges()},_syncShapeChanges(){this.dataSource&&this._isEditable&&this.dataSource.sync()},_syncConnectionChanges(){this.connectionsDataSource&&this._isEditable&&Promise.all(this.widget._deferredConnectionUpdates).then((()=>{this.connectionsDataSource.sync(),this.widget._deferredConnectionUpdates.length=0}))},editModel:function(e,t){var n,i;this.cancelEdit();var o=this.widget.options.editable;if("shape"==t)n=o.shapeEditors,i=o.shapeTemplate;else{if("connection"!=t)return;var a=T.bind(this);n=r({},{from:a,to:a},o.connectionEditors),i=o.connectionTemplate}this.editor=new S(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 r9?"shape":"connection";this.editModel(e.dataItem,t)}},cancelEdit:function(){this.editor&&(this._getEditDataSource().cancelChanges(this.editor.model),this._destroyEditor())},clear(){this.widget.clear()},saveEdit:function(){this.editor&&this.editor.end()&&!this.trigger("save",this._editArgs())&&this._getEditDataSource().sync()},updateConnectionModel:function(e,t){if(this.connectionsDataSource){const n=this.connectionsDataSource.getByUid(e.dataItem.uid);n&&(this._suspendModelRefresh(),h(e.options.fromX)&&null!==e.options.fromX?(w("from",n),w("fromConnector",n),n.set("fromX",e.options.fromX),n.set("fromY",e.options.fromY)):(n.set("from",e.options.from),h(n.fromConnector)&&n.set("fromConnector",e.sourceConnector?e.sourceConnector.options.name:null),w("fromX",n),w("fromY",n)),h(e.options.toX)&&null!==e.options.toX?(w("to",n),w("toConnector",n),n.set("toX",e.options.toX),n.set("toY",e.options.toY)):(n.set("to",e.options.to),h(n.toConnector)&&n.set("toConnector",e.targetConnector?e.targetConnector.options.name:null),w("toX",n),w("toY",n)),h(e.options.type)&&h(n.type)&&n.set("type",e.options.type),e.dataItem=n,this._resumeModelRefresh(),t&&this._syncConnectionChanges())}},updateShapeModel:function(e,t){const n=e._bounds;const i=e.dataItem;i&&(this._suspendModelRefresh(),h(i.x)&&n.x!==i.x&&i.set("x",n.x),h(i.y)&&n.y!==i.y&&i.set("y",n.y),h(i.width)&&n.width!==i.width&&i.set("width",n.width),h(i.height)&&n.height!==i.height&&i.set("height",n.height),e.dataItem=i,this._resumeModelRefresh(),t&&this._syncShapeChanges())},destroy:function(){this.diagram=null,this.element=null,this.options=null,this._toolBar&&this._toolBar.destroy(),this._popup&&this._popup.destroy(),this._destroyGlobalToolBar(),this._destroyToolBar(),this.widget&&(this.widget.destroy(),this.widget=null)},documentToModel:function(e){return this.widget.documentToModel(e)},documentToView:function(e){return this.widget.documentToView(e)},focus:function(){return this.widget.focus()},getShapeByModelId:function(e){return this.widget.getShapeByModelId(e)},getShapeByModelUid:function(e){return this.widget.getShapeByModelUid(e)},layerToModel:function(e){return this.widget.layerToModel(e)},load:function(e){this.widget.load(e)},modelToDocument:function(e){return this.widget.modelToDocument(e)},modelToLayer:function(e){return this.widget.modelToLayer(e)},modelToView:function(e){return this.widget.modelToView(e)},pan:function(e,t){return this.widget.pan(e,t)},paste:function(){this.widget.paste()},save:function(){return this.widget.save()},selectAll:function(){this.widget.selectAll()},selectArea:function(e){this.widget.selectArea(e)},setDataSource(e){this.options.dataSource=e,this._dataSource(),!1!==this.options.autoBind&&this.dataSource.fetch()},setConnectionsDataSource(e){this.options.connectionsDataSource=e,this._connectionDataSource(),!1!==this.options.autoBind&&this.connectionsDataSource.fetch()},viewToDocument:function(e){return this.widget.viewToDocument(e)},viewToModel:function(e){return this.widget.viewToModel(e)},viewport:function(){return this.widget.viewport()},zoom:function(e,t){return this.widget.zoom(e,t)},_initTheme:function(){var e=this;var n=((e.options||{}).theme||"").toLowerCase();var i=t.ui.themes||{};var r;return-1!=t.SASS_THEMES.indexOf(n)?(e.element.addClass("k-diagram"),r=t.diagramTheme(e.element[0]),e.element.removeClass("k-diagram")):r=(i[n]||{}).diagram,r},items:function(){return e()},_createGlobalToolBar:function(){this.widget;var e=this.widget.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 x(this,{tools:t||{},click:this._toolBarClick.bind(this),modal:!1}),this.widget.toolBar={element:this.toolBar.element[0]},this.toolBar.element.css({textAlign:"left"}),this.element.prepend(this.toolBar.element),this.widget._resize())}},_toolBarClick:function(e){this.trigger("toolBarClick",e),this._destroyToolBar()},_createToolBar:function(e){const t=this;const n=this.widget;if(!this.singleToolBar&&1===t.select().length){var i=t.select()[0];if(i&&!1!==i.options.editable){var r=i.options.editable||{};var s=r.tools;if(this._isEditable&&s&&0===s.length&&(i instanceof r9?s=["edit","rotateClockwise","rotateAnticlockwise"]:i instanceof A7&&(s=["edit"]),r&&!1!==r.remove&&s.push("delete")),s&&s.length){var l;this.singleToolBar=new x(this,{tools:s,click:this._toolBarClick.bind(this),modal:!0,popupZIndex:parseInt(t.element.closest(".k-window").css("zIndex"),10)+10});var c=o(this.singleToolBar._popup.element);var h=a(this.singleToolBar._popup.element);if(i instanceof r9){var u=n.modelToView(i.bounds("rotated"));l=new d(u.x,u.y).minus(new d((c-u.width)/2,h+20))}else if(i instanceof A7){var p=n.modelToView(i.bounds());l=new d(p.x,p.y).minus(new d((c-p.width-20)/2,h+20))}l?(n.canvas.translate||(l=l.minus(new d(n.scroller.scrollLeft,n.scroller.scrollTop))),l=this.viewToDocument(l),l=new d(Math.max(l.x,0),Math.max(l.y,0)),this.singleToolBar.showAt(l),e&&this.singleToolBar._popup.one("close",b)):this._destroyToolBar()}}}},_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)},_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.widget._connectionsDataMap[e.uid]||this.widget._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},_fetchFreshData(){this._dataSource(),this._isEditable&&this._connectionDataSource(),!1!==this.options.autoBind&&(this._isEditable?(this._loadingShapes=!0,this._loadingConnections=!0,this.dataSource.fetch(),this.connectionsDataSource.fetch()):this.dataSource.fetch())},_dataSource(){if(h(this.options.connectionsDataSource)){this.widget._isEditable=!0;const e=this.options.dataSource||{};const t=Array.isArray(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=p.create(t).bind("change",this._shapesRefreshHandler).bind("requestStart",this._shapesRequestStartHandler).bind("error",this._shapesErrorHandler)}else this._treeDataSource(),this.widget._isEditable=!1},_connectionDataSource(){const e=this.options.connectionsDataSource;if(e){const t=Array.isArray(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=p.create(t).bind("change",this._connectionsRefreshHandler).bind("requestStart",this._connectionsRequestStartHandler).bind("error",this._connectionsErrorHandler)}},_shapesRequestStart(e){"read"===e.type&&(this._loadingShapes=!0)},_connectionsRequestStart(e){"read"===e.type&&(this._loadingConnections=!0)},_error(){this._loadingShapes=!1},_connectionsError(){this._loadingConnections=!1},_refreshShapes(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():this.refresh()},_shouldRefresh(){return this.widget._shouldRefresh()},_suspendModelRefresh(){this.widget._suspendModelRefresh()},_resumeModelRefresh(){this.widget._resumeModelRefresh()},refresh(){this._loadingShapes=!1,this._loadingConnections||this._rebindShapesAndConnections()},_rebindShapesAndConnections(){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(){this._loadingConnections=!1,this._loadingShapes||this._rebindShapesAndConnections()},_redrawConnections(){this.widget._redrawConnections()},_removeShapes(e){const t=this.widget._dataMap;let n,i;for(i=0;i<e.length;i++)n=e[i],t[n.id]&&(this.remove(t[n.id],!1),t[n.id]=null)},_syncShapes(){const e=this._inactiveShapeItems;e.forEach((t=>{const n=t.dataItem;const i=t.element;n.isNew()||(i?(i._setOptionsFromModel(),this.addShape(i,t.undoable),this.widget._dataMap[n.id]=i):this._addDataItem(n),t.activate(),e.remove(n))}))},_updateShapes(e,t){for(let n=0;n<e.length;n++){const i=e[n];const r=this.widget._dataMap[i.id];r&&r.updateOptionsFromModel(i,t)}},_addShapes(e){for(let t=0;t<e.length;t++)this._addDataItem(e[t],!1)},_addDataItem(e,t){if(!H4(e))return;let n=this.widget._dataMap[e.id];if(n)return n;const i=r({},this.widget.options.shapeDefaults);return i.dataItem=e,n=new r9(i,this.widget),this.addShape(n,!1!==t),this.widget._dataMap[e.id]=n,n},_refreshConnections(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(e){for(let t=0;t<e.length;t++)this.remove(this.widget._connectionsDataMap[e[t].uid],!1),this.widget._connectionsDataMap[e[t].uid]=null},_updateConnections(e){for(let t=0;t<e.length;t++){const n=e[t];this.widget._connectionsDataMap[n.uid].updateOptionsFromModel(n)}},_addConnections(e,t){this.widget._addConnections(e,t)},_addShape(e,t){const n=this.dataSource;let i;if(n&&this._isEditable){if(i=A(n,M(e.dataItem)),e.dataItem=i,e.updateModel(),!this.trigger("add",{shape:e})){this.dataSource.add(i);const n=this.widget._inactiveShapeItems.getByUid(i.uid);return n.element=e,n.undoable=t,e}}else if(!this.trigger("add",{shape:e}))return this.addShape(e,t)},_addConnection(e,t){const n=this.connectionsDataSource;let i;if(n&&this._isEditable){if(i=A(n,M(e.dataItem)),e.dataItem=i,e.updateModel(),!this.trigger("add",{connection:e}))return this.widget._connectionsDataMap[i.uid]=e,n.add(i),this.addConnection(e,t),e._updateConnectors(),e}else if(!this.trigger("add",{connection:e}))return this.addConnection(e,t),e._updateConnectors(),e},_treeDataSource(){let e=this.widget.options.dataSource;if(e=Array.isArray(e)?{data:e}:e,e instanceof p&&!(e instanceof l))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.");e.fields||(e.fields=[{field:"text"},{field:"url"},{field:"spriteCssClass"},{field:"imageUrl"}]),this.dataSource&&this._refreshHandler&&this._unbindDataSource(),this._refreshHandler=this._refreshSource.bind(this),this._errorHandler=this._error.bind(this),this.dataSource=l.create(e).bind(g,this._refreshHandler).bind(v,this._errorHandler)},_unbindDataSource(){this.dataSource.unbind(g,this._refreshHandler).unbind(v,this._errorHandler)},_refreshSource(e){const t=e.node,n=e.action,i=e.items,r=this.options;let o,a;if(e.field)for(o=0;o<i.length;o++)this.widget._dataMap[i[o].uid]&&this.widget._dataMap[i[o].uid].redrawVisual();else{if("remove"===n)this._removeDataItems(e.items,!0);else for(n&&"itemloaded"!==n||this._bindingRoots||(this._bindingRoots=!0,a=!0),n||t||this.clear(),this.widget._addDataItems(i,t),o=0;o<i.length;o++)i[o].load();r.layout&&(a||"remove"===n||"add"===n)&&this.layout(r.layout),a&&(this.trigger("dataBound"),this._bindingRoots=!1)}},_removeDataItems(e,t){let n,i,r,o;for(e=Array.isArray(e)?e:[e];e.length;)if(n=e.shift(),r=this.widget._dataMap[n.uid],r&&(this.widget._removeShapeConnections(r),this.widget._removeItem(r,!1),delete this.widget._dataMap[n.uid],t&&n.hasChildren&&n.loaded()))for(i=n.children.data(),o=0;o<i.length;o++)e.push(i[o])},_removeConnectionDataItem(e){this.connectionsDataSource.remove(e)},_removeShapeDataItem(e){this.dataSource.remove(e)},_destroyEditor:function(){this.editor&&(this.editor.close(),this.editor=null)}});t.ExportMixin.extend(k.fn,!0),kendo.PDFMixin&&kendo.PDFMixin.extend(k.fn);var x=kendo.Observable.extend({init:function(e,t){kendo.Observable.fn.init.call(this),this.diagram=e,this.options=r({},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||!h(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){u(e)||(e={name:e});var t=e.name+"Tool";this[t]?this[t](e):this._tools.push(r({},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={};var 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));var i=n.action;i&&this[i]&&this[i](n),this.trigger("click",this.eventData(i,t.target))},eventData:function(e,t){var n,i=this.selectedElements(),r=i.length,o=[],a=[];for(var s=0;s<r;s++)(n=i[s])instanceof r9?o.push(n):a.push(n);return{shapes:o,connections:a,action:e,target:t}},delete:function(){var e=this.diagram.widget._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.widget._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()}});var C=kendo.Observable.extend({init:function(e,t){kendo.Observable.fn.init.call(this),this.options=s(!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=[];var 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}});var S=C.extend({init:function(e,t){C.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(){var e="";for(var 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(_)(y[e])},_attachButtonEvents:function(){this._cancelClickHandler=this._cancelClick.bind(this),this.window.element.on(m+f,"button.k-diagram-cancel",this._cancelClickHandler),this._updateClickHandler=this._updateClick.bind(this),this.window.element.on(m+f,"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(m+f,"a.k-diagram-cancel",this._cancelClickHandler),this.window.element.off(m+f,"a.k-diagram-update",this._updateClickHandler),this._cancelClickHandler=null,this._editUpdateClickHandler=null,this.window=null,C.fn.destroy.call(this)}});function T(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 M(e){var t=e;return e instanceof kendo.data.Model&&((t=e.toJSON())[e.idField]=e._defaultId),t}function A(e,t){return e.reader.model?new e.reader.model(t):new kendo.data.ObservableObject(t)}t.ui.plugin(k),r(n,{Shape:r9,Connection:A7,Connector:$8,DiagramToolBar:x,QuadNode:j7,QuadRoot:W7,ShapesQuadTree:q7,PopupEditor:S})}(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,h=i.getter,u=i.dataviz;var p=".kendoTreeMap",f="change",m="dataBound",g="itemCreated",v=Number.MAX_VALUE,_="mouseover"+p,b="mouseleave"+p;var w=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,u.ui)},options:{name:"TreeMap",theme:"sass",autoBind:!0,textField:"text",valueField:"value",colorField:"color"},events:[m,g],_initTheme:function(e){var t=((u.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 y,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=e.node;var n=e.items;var a=this.options;var s,l;if(t){if(n.length){var c=this._getByUid(t.uid);for(c.children=[],n=new i.data.Query(n)._sortForGrouping(a.valueField,"desc"),l=0;l<n.length;l++)s=n[l],c.children.push(this._wrapItem(s));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(),s=this._wrapItem(n[0]),this._layout.createRoot(s,o(this.element),r(this.element),"vertical"===this.options.type),this._view.createRoot(s),this._root=s,this._colorIdx=0;for(l=0;l<n.length;l++)n[l].load();t&&this.trigger(m,{node:t})},_setColors:function(e){var t=this.options.colors;var i=t[this._colorIdx%t.length];var r,o;n(i)&&(r=function(e,t,n){var i=D(e);var r=D(t);var o=z(e)-z(t)<0;var a=[];a.push(e);for(var s=0;s<n;s++){var l={r:M(i.r,r.r,s,n,o),g:M(i.g,r.g,s,n,o),b:M(i.b,r.b,s,n,o)};a.push(A(l))}return a.push(t),a}(i[0],i[1],e.length));var a=!1;for(var s=0;s<e.length;s++)T((o=e[s]).color)||(o.color=r?r[s]:i),o.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){var t=[this._root];var n;for(;t.length;){if((n=t.pop()).dataItem.uid===e)return n;n.children&&(t=t.concat(n.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;var 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=t.children(".k-treemap-wrap").children();var r,o;this._layout.compute(e.children,e.coord,{text:this._view.titleSize(e,t)});for(var a=0;a<e.children.length;a++)r=e.children[a],o=n.filter("["+i.attr("uid")+"='"+r.dataItem.uid+"']"),this._view.setItemSize(r,o),this._resizeItems(r,o)}},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()}});var y=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=t.width*t.height;var i,r=0,o=[];for(i=0;i<e.length;i++)o[i]=parseFloat(e[i].value),r+=o[i];for(i=0;i<o.length;i++)e[i].area=n*o[i]/r;var a=this.layoutHorizontal()?t.height:t.width;var s=[e[0]];var 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;var i=0,r=0,o=v;for(var 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){var r=P(this._totalArea(e)/n),o=i.top,a=0;for(var 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){var t=0;for(var n=0;n<e.length;n++)t+=e[n].area;return t}});var 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);var 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);var n=e.children;if(n){var i=t.find(".k-treemap-wrap");for(var r=0;r<n.length;r++){var o=n[r];var 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)}});var 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;var 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=t.width*t.height;var i=0;var r=[];var o;for(o=0;o<e.length;o++){var a=e[o];r[o]=parseFloat(e[o].value),i+=r[o],a.vertical=this.vertical}for(o=0;o<r.length;o++)e[o].area=n*r[o]/i;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){var i=0;for(var r=0;r<e.length;r++){var o=e[r];var 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){var i=0;for(var r=0;r<e.length;r++){var o=e[r];var 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){var t=0;for(var n=0;n<e.length;n++)t+=e[n].area;return t}});var C=k.extend({htmlSize:function(e){var t=this._getByUid(e.dataItem.uid);var 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:h(e,!0)(t)}function T(e){return void 0!==e}function M(e,n,i,r,o){var a=t.min(t.abs(e),t.abs(n));var s=t.max(t.abs(e),t.abs(n));var 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 D(e){var t=function(e){var t=e.length;var 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=D(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}u.ui.plugin(w)}(window.kendo.jQuery);kendo;kendo;kendo;return kendo}));
|
||
//# sourceMappingURL=kendo.all.min.js.map
|