@esvndev/es-react-table-interface 1.4.1 → 1.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -643,4 +643,4 @@ var e,t,n="function"==typeof Symbol?Symbol:{},a=n.iterator||"@@iterator",r=n.toS
643
643
  /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */
644
644
  var a,r,i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",l=i.toStringTag||"@@toStringTag";function s(e,n,i,o){var l=n&&n.prototype instanceof d?n:d,s=Object.create(l.prototype);return t(s,"_invoke",function(e,t,n){var i,o,l,s=0,d=n||[],h=!1,u={p:0,n:0,v:a,a:p,f:p.bind(a,4),d:function(e,t){return i=e,o=0,l=a,u.n=t,c}};function p(e,t){for(o=e,l=t,r=0;!h&&s&&!n&&r<d.length;r++){var n,i=d[r],p=u.p,f=i[2];e>3?(n=f===t)&&(l=i[(o=i[4])?5:(o=3,3)],i[4]=i[5]=a):i[0]<=p&&((n=e<2&&p<i[1])?(o=0,u.v=t,u.n=i[1]):p<f&&(n=e<3||i[0]>t||t>f)&&(i[4]=e,i[5]=t,u.n=f,o=0))}if(n||e>1)return c;throw h=!0,t}return function(n,d,f){if(s>1)throw TypeError("Generator is already running");for(h&&1===d&&p(d,f),o=d,l=f;(r=o<2?a:l)||!h;){i||(o?o<3?(o>1&&(u.n=-1),p(o,l)):u.n=l:u.v=l);try{if(s=2,i){if(o||(n="next"),r=i[n]){if(!(r=r.call(i,l)))throw TypeError("iterator result is not an object");if(!r.done)return r;l=r.value,o<2&&(o=0)}else 1===o&&(r=i.return)&&r.call(i),o<2&&(l=TypeError("The iterator does not provide a '"+n+"' method"),o=1);i=a}else if((r=(h=u.n<0)?l:e.call(t,u))!==c)break}catch(e){i=a,o=1,l=e}finally{s=1}}return{value:r,done:h}}}(e,i,o),!0),s}var c={};function d(){}function h(){}function u(){}r=Object.getPrototypeOf;var p=[][o]?r(r([][o]())):(t(r={},o,function(){return this}),r),f=u.prototype=d.prototype=Object.create(p);function m(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,u):(e.__proto__=u,t(e,l,"GeneratorFunction")),e.prototype=Object.create(f),e}return h.prototype=u,t(f,"constructor",u),t(u,"constructor",h),h.displayName="GeneratorFunction",t(u,l,"GeneratorFunction"),t(f),t(f,l,"Generator"),t(f,o,function(){return this}),t(f,"toString",function(){return"[object Generator]"}),(e.exports=n=function(){return{w:s,m:m}},e.exports.__esModule=!0,e.exports.default=e.exports)()}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports}(Rot);var Yot={exports:{}},qot={exports:{}},Uot={exports:{}};!function(e){var t=Wot.exports,n=Fot.exports;e.exports=function e(a,r){function i(e,n,o,l){try{var s=a[e](n),c=s.value;return c instanceof t?r.resolve(c.v).then(function(e){i("next",e,o,l)},function(e){i("throw",e,o,l)}):r.resolve(c).then(function(e){s.value=e,o(s)},function(e){return i("throw",e,o,l)})}catch(e){l(e)}}var o;this.next||(n(e.prototype),n(e.prototype,"function"==typeof Symbol&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),n(this,"_invoke",function(e,t,n){function a(){return new r(function(t,a){i(e,n,t,a)})}return o=o?o.then(a,a):a()},!0)},e.exports.__esModule=!0,e.exports.default=e.exports}(Uot),function(e){var t=Rot.exports,n=Uot.exports;e.exports=function(e,a,r,i,o){return new n(t().w(e,a,r,i),o||Promise)},e.exports.__esModule=!0,e.exports.default=e.exports}(qot),function(e){var t=qot.exports;e.exports=function(e,n,a,r,i){var o=t(e,n,a,r,i);return o.next().then(function(e){return e.done?e.value:o.next()})},e.exports.__esModule=!0,e.exports.default=e.exports}(Yot);var Got={exports:{}};!function(e){e.exports=function(e){var t=Object(e),n=[];for(var a in t)n.unshift(a);return function e(){for(;n.length;)if((a=n.pop())in t)return e.value=a,e.done=!1,e;return e.done=!0,e}},e.exports.__esModule=!0,e.exports.default=e.exports}(Got);var Kot={exports:{}};!function(e){var t=fqe.exports.default;e.exports=function(e){if(null!=e){var n=e["function"==typeof Symbol&&Symbol.iterator||"@@iterator"],a=0;if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length))return{next:function(){return e&&a>=e.length&&(e=void 0),{value:e&&e[a++],done:!e}}}}throw new TypeError(t(e)+" is not iterable")},e.exports.__esModule=!0,e.exports.default=e.exports}(Kot),function(e){var t=Wot.exports,n=Rot.exports,a=Yot.exports,r=qot.exports,i=Uot.exports,o=Got.exports,l=Kot.exports;function s(){var c=n(),d=c.m(s),h=(Object.getPrototypeOf?Object.getPrototypeOf(d):d.__proto__).constructor;function u(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===h||"GeneratorFunction"===(t.displayName||t.name))}var p={throw:1,return:2,break:3,continue:3};function f(e){var t,n;return function(a){t||(t={stop:function(){return n(a.a,2)},catch:function(){return a.v},abrupt:function(e,t){return n(a.a,p[e],t)},delegateYield:function(e,r,i){return t.resultName=r,n(a.d,l(e),i)},finish:function(e){return n(a.f,e)}},n=function(e,n,r){a.p=t.prev,a.n=t.next;try{return e(n,r)}finally{t.next=a.n}}),t.resultName&&(t[t.resultName]=a.v,t.resultName=void 0),t.sent=a.v,t.next=a.n;try{return e.call(this,t)}finally{a.p=t.prev,a.n=t.next}}}return(e.exports=s=function(){return{wrap:function(e,t,n,a){return c.w(f(e),t,n,a&&a.reverse())},isGeneratorFunction:u,mark:c.m,awrap:function(e,n){return new t(e,n)},AsyncIterator:i,async:function(e,t,n,i,o){return(u(t)?r:a)(f(e),t,n,i,o)},keys:o,values:l}},e.exports.__esModule=!0,e.exports.default=e.exports)()}e.exports=s,e.exports.__esModule=!0,e.exports.default=e.exports}(jot);var Qot={exports:{}};!function(e){function t(e,t,n,a,r,i,o){try{var l=e[i](o),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(a,r)}e.exports=function(e){return function(){var n=this,a=arguments;return new Promise(function(r,i){var o=e.apply(n,a);function l(e){t(o,r,i,l,s,"next",e)}function s(e){t(o,r,i,l,s,"throw",e)}l(void 0)})}},e.exports.__esModule=!0,e.exports.default=e.exports}(Qot);var Xot=pqe.exports.default,Jot=sqe.exports.default;Object.defineProperty(Bot,"__esModule",{value:!0}),Bot._r=function(e,t){if("production"!==process.env.NODE_ENV)return hlt(e,t)},Bot._u=function(e){if("production"!==process.env.NODE_ENV)return flt(e)},Bot.render=function(e,t){if($ot)return void function(e,t){clt(!0);var n=t[dlt]||$ot(t);clt(!1),n.render(e),t[dlt]=n}(e,t);hlt(e,t)},Bot.unmount=function(e){return mlt.apply(this,arguments)};var $ot,elt=Jot(jot.exports),tlt=Jot(Qot.exports),nlt=Jot(fqe.exports),alt=Jot(gUe.exports),rlt=Xot(v.default),ilt=(0,alt.default)({},rlt),olt=ilt.version,llt=ilt.render,slt=ilt.unmountComponentAtNode;try{Number((olt||"").split(".")[0])>=18&&($ot=ilt.createRoot)}catch(rKe){}function clt(e){var t=ilt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&"object"===(0,nlt.default)(t)&&(t.usingClientEntryPoint=e)}var dlt="__rc_react_root__";function hlt(e,t){null==llt||llt(e,t)}function ult(e){return plt.apply(this,arguments)}function plt(){return plt=(0,tlt.default)((0,elt.default)().mark(function e(t){return(0,elt.default)().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Promise.resolve().then(function(){var e;null===(e=t[dlt])||void 0===e||e.unmount(),delete t[dlt]}));case 1:case"end":return e.stop()}},e)})),plt.apply(this,arguments)}function flt(e){slt(e)}function mlt(){return(mlt=(0,tlt.default)((0,elt.default)().mark(function e(t){return(0,elt.default)().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(void 0===$ot){e.next=2;break}return e.abrupt("return",ult(t));case 2:flt(t);case 3:case"end":return e.stop()}},e)}))).apply(this,arguments)}var vlt={};function glt(e){return e&&"#fff"!==e&&"#ffffff"!==e&&"rgb(255, 255, 255)"!==e&&"rgba(255, 255, 255, 1)"!==e&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&"transparent"!==e}Object.defineProperty(vlt,"__esModule",{value:!0}),vlt.getTargetWaveColor=function(e){const{borderTopColor:t,borderColor:n,backgroundColor:a}=getComputedStyle(e);if(glt(t))return t;if(glt(n))return n;if(glt(a))return a;return null},vlt.isValidWaveColor=glt;var wlt=sqe.exports;Object.defineProperty(Tot,"__esModule",{value:!0}),Tot.default=void 0;var ylt=wlt(dqe.exports),blt=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Clt(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),xlt=wlt(wt.exports),Elt=wlt(e7e),klt=wlt(Hot),Mlt=Bot,Slt=ert,Alt=zot,_lt=vlt;function Clt(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Clt=function(e){return e?n:t})(e)}function Zlt(e){return Number.isNaN(e)?0:e}const Hlt=e=>{const{className:t,target:n,component:a}=e,r=blt.useRef(null),[i,o]=blt.useState(null),[l,s]=blt.useState([]),[c,d]=blt.useState(0),[h,u]=blt.useState(0),[p,f]=blt.useState(0),[m,v]=blt.useState(0),[g,w]=blt.useState(!1),y={left:c,top:h,width:p,height:m,borderRadius:l.map(e=>`${e}px`).join(" ")};function b(){const e=getComputedStyle(n);o((0,_lt.getTargetWaveColor)(n));const t="static"===e.position,{borderLeftWidth:a,borderTopWidth:r}=e;d(t?n.offsetLeft:Zlt(-parseFloat(a))),u(t?n.offsetTop:Zlt(-parseFloat(r))),f(n.offsetWidth),v(n.offsetHeight);const{borderTopLeftRadius:i,borderTopRightRadius:l,borderBottomLeftRadius:c,borderBottomRightRadius:h}=e;s([i,l,h,c].map(e=>Zlt(parseFloat(e))))}if(i&&(y["--wave-color"]=i),blt.useEffect(()=>{if(n){const e=(0,klt.default)(()=>{b(),w(!0)});let t;return"undefined"!=typeof ResizeObserver&&(t=new ResizeObserver(b),t.observe(n)),()=>{klt.default.cancel(e),t?.disconnect()}}},[]),!g)return null;const x=("Checkbox"===a||"Radio"===a)&&n?.classList.contains(Alt.TARGET_CLS);return blt.createElement(Elt.default,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:(e,t)=>{if(t.deadline||"opacity"===t.propertyName){const e=r.current?.parentElement;(0,Mlt.unmount)(e).then(()=>{e?.remove()})}return!1}},({className:e},n)=>blt.createElement("div",{ref:(0,Slt.composeRef)(r,n),className:(0,xlt.default)(t,e,{"wave-quick":x}),style:y}))};Tot.default=(e,t)=>{const{component:n}=t;if("Checkbox"===n&&!e.querySelector("input")?.checked)return;const a=document.createElement("div");a.style.position="absolute",a.style.left="0px",a.style.top="0px",e?.insertBefore(a,e?.firstChild),(0,Mlt.render)(blt.createElement(Hlt,(0,ylt.default)({},t,{target:e})),a)};var Ilt=sqe.exports;Object.defineProperty(Zot,"__esModule",{value:!0}),Zot.default=void 0;var Dlt=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Tlt(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),Nlt=Ilt(ZJe),Olt=Ilt(Hot),Llt=D5e,Vlt=Ilt($Je),zlt=zot,Plt=Ilt(Tot);function Tlt(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Tlt=function(e){return e?n:t})(e)}Zot.default=(e,t,n)=>{const{wave:a}=Dlt.useContext(Llt.ConfigContext),[,r,i]=(0,Vlt.default)(),o=(0,Nlt.default)(o=>{const l=e.current;if(a?.disabled||!l)return;const s=l.querySelector(`.${zlt.TARGET_CLS}`)||l,{showEffect:c}=a||{};(c||Plt.default)(s,{className:t,token:r,component:n,event:o,hashId:i})}),l=Dlt.useRef();return e=>{Olt.default.cancel(l.current),l.current=(0,Olt.default)(()=>{o(e)})}};var Blt=sqe.exports;Object.defineProperty(Mot,"__esModule",{value:!0}),Mot.default=void 0;var jlt=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Klt(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),Wlt=Blt(wt.exports),Rlt=Blt(Sot),Flt=ert,Ylt=D5e,qlt=w7e,Ult=Blt(Aot),Glt=Blt(Zot);function Klt(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Klt=function(e){return e?n:t})(e)}const Qlt=e=>{const{children:t,disabled:n,component:a}=e,{getPrefixCls:r}=(0,jlt.useContext)(Ylt.ConfigContext),i=(0,jlt.useRef)(null),o=r("wave"),[,l]=(0,Ult.default)(o),s=(0,Glt.default)(i,(0,Wlt.default)(o,l),a);if(jlt.default.useEffect(()=>{const e=i.current;if(!e||1!==e.nodeType||n)return;const t=t=>{!(0,Rlt.default)(t.target)||!e.getAttribute||e.getAttribute("disabled")||e.disabled||e.className.includes("disabled")||e.className.includes("-leave")||s(t)};return e.addEventListener("click",t,!0),()=>{e.removeEventListener("click",t,!0)}},[n]),!jlt.default.isValidElement(t))return t??null;const c=(0,Flt.supportRef)(t)?(0,Flt.composeRef)(t.ref,i):i;return(0,qlt.cloneElement)(t,{ref:c})};"production"!==process.env.NODE_ENV&&(Qlt.displayName="Wave"),Mot.default=Qlt;var Xlt={},Jlt=sqe.exports;Object.defineProperty(Xlt,"__esModule",{value:!0}),Xlt.default=Xlt.GroupSizeContext=void 0;var $lt=Jlt(dqe.exports),est=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=ist(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),tst=Jlt(wt.exports),nst=Q2e,ast=D5e,rst=G3e;function ist(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(ist=function(e){return e?n:t})(e)}const ost=Xlt.GroupSizeContext=est.createContext(void 0);Xlt.default=e=>{const{getPrefixCls:t,direction:n}=est.useContext(ast.ConfigContext),{prefixCls:a,size:r,className:i,...o}=e,l=t("btn-group",a),[,,s]=(0,rst.useToken)();let c="";switch(r){case"large":c="lg";break;case"small":c="sm"}if("production"!==process.env.NODE_ENV){(0,nst.devUseWarning)("Button.Group")(!r||["large","small","middle"].includes(r),"usage","Invalid prop `size`.")}const d=(0,tst.default)(l,{[`${l}-${c}`]:c,[`${l}-rtl`]:"rtl"===n},i,s);return est.createElement(ost.Provider,{value:r},est.createElement("div",(0,$lt.default)({},o,{className:d})))};var lst={},sst=sqe.exports;Object.defineProperty(lst,"__esModule",{value:!0}),lst._ButtonVariantTypes=lst._ButtonColorTypes=void 0,lst.convertLegacyProps=function(e){if("danger"===e)return{danger:!0};return{type:e}},lst.isString=pst,lst.isTwoCNChar=void 0,lst.isUnBorderedButtonVariant=function(e){return"text"===e||"link"===e},lst.spaceChildren=function(e,t){let n=!1;const a=[];return cst.default.Children.forEach(e,e=>{const t=typeof e,r="string"===t||"number"===t;if(n&&r){const t=a.length-1,n=a[t];a[t]=`${n}${e}`}else a.push(e);n=r}),cst.default.Children.map(a,e=>function(e,t){if(null==e)return;const n=t?" ":"";if("string"!=typeof e&&"number"!=typeof e&&pst(e.type)&&ust(e.props.children))return(0,dst.cloneElement)(e,{children:e.props.children.split("").join(n)});if(pst(e))return ust(e)?cst.default.createElement("span",null,e.split("").join(n)):cst.default.createElement("span",null,e);if((0,dst.isFragment)(e))return cst.default.createElement("span",null,e);return e}(e,t))};var cst=sst(f.default),dst=w7e;const hst=/^[\u4E00-\u9FA5]{2}$/,ust=lst.isTwoCNChar=hst.test.bind(hst);function pst(e){return"string"==typeof e}lst._ButtonVariantTypes=["outlined","dashed","solid","filled","text","link"],lst._ButtonColorTypes=["default","primary","danger"];var fst={},mst=sqe.exports;Object.defineProperty(fst,"__esModule",{value:!0}),fst.default=void 0;var vst=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=wst(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),gst=mst(wt.exports);function wst(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(wst=function(e){return e?n:t})(e)}const yst=(0,vst.forwardRef)((e,t)=>{const{className:n,style:a,children:r,prefixCls:i}=e,o=(0,gst.default)(`${i}-icon`,n);return vst.default.createElement("span",{ref:t,className:o,style:a},r)});fst.default=yst;var bst={},xst={exports:{}},Est={},kst={};Object.defineProperty(kst,"__esModule",{value:!0});kst.default={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"};var Mst=pqe.exports.default,Sst=sqe.exports.default;Object.defineProperty(Est,"__esModule",{value:!0}),Est.default=void 0;var Ast=Sst(dqe.exports),_st=Mst(f.default),Cst=Sst(kst),Zst=Sst(vqe),Hst=function(e,t){return _st.createElement(Zst.default,(0,Ast.default)({},e,{ref:t,icon:Cst.default}))},Ist=_st.forwardRef(Hst);"production"!==process.env.NODE_ENV&&(Ist.displayName="LoadingOutlined"),Est.default=Ist,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const n=function(e){return e&&e.__esModule?e:{default:e}}(Est);const a=n;t.default=a,e.exports=a}(xst,xst.exports);var Dst=sqe.exports;Object.defineProperty(bst,"__esModule",{value:!0}),bst.default=void 0;var Nst=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Pst(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),Ost=Dst(xst.exports),Lst=Dst(wt.exports),Vst=Dst(e7e),zst=Dst(fst);function Pst(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Pst=function(e){return e?n:t})(e)}const Tst=(0,Nst.forwardRef)((e,t)=>{const{prefixCls:n,className:a,style:r,iconClassName:i}=e,o=(0,Lst.default)(`${n}-loading-icon`,a);return Nst.default.createElement(zst.default,{prefixCls:n,className:o,style:r,ref:t},Nst.default.createElement(Ost.default,{className:i}))}),Bst=()=>({width:0,opacity:0,transform:"scale(0)"}),jst=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"});bst.default=e=>{const{prefixCls:t,loading:n,existIcon:a,className:r,style:i}=e,o=!!n;return a?Nst.default.createElement(Tst,{prefixCls:t,className:r,style:i}):Nst.default.createElement(Vst.default,{visible:o,motionName:`${t}-loading-icon-motion`,motionLeave:o,removeOnLeave:!0,onAppearStart:Bst,onAppearActive:jst,onEnterStart:Bst,onEnterActive:jst,onLeaveStart:jst,onLeaveActive:Bst},({className:e,style:n},a)=>Nst.default.createElement(Tst,{prefixCls:t,className:r,style:{...i,...n},ref:a,iconClassName:e}))};var Wst={},Rst={};Object.defineProperty(Rst,"__esModule",{value:!0}),Rst.default=void 0;const Fst=(e,t)=>({[`> span, > ${e}`]:{"&:not(:last-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}});Rst.default=e=>{const{componentCls:t,fontSize:n,lineWidth:a,groupBorderColor:r,colorErrorHover:i}=e;return{[`${t}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${t}`]:{"&:not(:last-child)":{[`&, & > ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:e.calc(a).mul(-1).equal(),[`&, & > ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,"&:hover, &:focus, &:active":{zIndex:2},"&[disabled]":{zIndex:0}},[`${t}-icon-only`]:{fontSize:n}},Fst(`${t}-primary`,r),Fst(`${t}-danger`,i)]}};var Yst={},qst={},Ust=["b"],Gst=["v"],Kst=function(e){return Math.round(Number(e||0))},Qst=function(){CQe(t,Dqe);var e=DQe(t);function t(n){return gs(this,t),e.call(this,function(e){if(e instanceof Dqe)return e;if(e&&"object"===fs(e)&&"h"in e&&"b"in e){var t=e,n=t.b;return FGe(FGe({},ps(t,Ust)),{},{v:n})}return"string"==typeof e&&/hsb/.test(e)?e.replace(/hsb/,"hsv"):e}(n))}return ys(t,[{key:"toHsbString",value:function(){var e=this.toHsb(),t=Kst(100*e.s),n=Kst(100*e.b),a=Kst(e.h),r=e.a,i="hsb(".concat(a,", ").concat(t,"%, ").concat(n,"%)"),o="hsba(".concat(a,", ").concat(t,"%, ").concat(n,"%, ").concat(r.toFixed(0===r?0:2),")");return 1===r?i:o}},{key:"toHsb",value:function(){var e=this.toHsv(),t=e.v;return FGe(FGe({},ps(e,Gst)),{},{b:t,a:this.a})}}]),t}(),Xst=function(e){return e instanceof Qst?e:new Qst(e)},Jst=Xst("#1677ff"),$st=function(e){var t=e.offset,n=e.targetRef,a=e.containerRef,r=e.color,i=e.type,o=a.current.getBoundingClientRect(),l=o.width,s=o.height,c=n.current.getBoundingClientRect(),d=c.width/2,h=c.height/2,u=(t.x+d)/l,p=1-(t.y+h)/s,f=r.toHsb(),m=u,v=(t.x+d)/l*360;if(i)switch(i){case"hue":return Xst(FGe(FGe({},f),{},{h:v<=0?0:v}));case"alpha":return Xst(FGe(FGe({},f),{},{a:m<=0?0:m}))}return Xst({h:f.h,s:u<=0?0:u,b:p>=1?1:p,a:f.a})},ect=function(e,t){var n=e.toHsb();switch(t){case"hue":return{x:n.h/360*100,y:50};case"alpha":return{x:100*e.a,y:50};default:return{x:100*n.s,y:100*(1-n.b)}}},tct=function(e){var t=e.color,n=e.prefixCls,a=e.className,r=e.style,i=e.onClick,o="".concat(n,"-color-block");return f.default.createElement("div",{className:yt(o,a),style:r,onClick:i},f.default.createElement("div",{className:"".concat(o,"-inner"),style:{background:t}}))};function nct(t){var n=t.targetRef,a=t.containerRef,r=t.direction,i=t.onDragChange,o=t.onDragChangeComplete,l=t.calculate,s=t.color,c=t.disabledDrag,d=Os(e.useState({x:0,y:0}),2),h=d[0],u=d[1],p=e.useRef(null),f=e.useRef(null);e.useEffect(function(){u(l())},[s]),e.useEffect(function(){return function(){document.removeEventListener("mousemove",p.current),document.removeEventListener("mouseup",f.current),document.removeEventListener("touchmove",p.current),document.removeEventListener("touchend",f.current),p.current=null,f.current=null}},[]);var m=function(e){var t=function(e){var t="touches"in e?e.touches[0]:e,n=document.documentElement.scrollLeft||document.body.scrollLeft||window.pageXOffset,a=document.documentElement.scrollTop||document.body.scrollTop||window.pageYOffset;return{pageX:t.pageX-n,pageY:t.pageY-a}}(e),o=t.pageX,l=t.pageY,s=a.current.getBoundingClientRect(),c=s.x,d=s.y,u=s.width,p=s.height,f=n.current.getBoundingClientRect(),m=f.width,v=f.height,g=m/2,w=v/2,y=Math.max(0,Math.min(o-c,u))-g,b=Math.max(0,Math.min(l-d,p))-w,x={x:y,y:"x"===r?h.y:b};if(0===m&&0===v||m!==v)return!1;null==i||i(x)},v=function(e){e.preventDefault(),m(e)},g=function(e){e.preventDefault(),document.removeEventListener("mousemove",p.current),document.removeEventListener("mouseup",f.current),document.removeEventListener("touchmove",p.current),document.removeEventListener("touchend",f.current),p.current=null,f.current=null,null==o||o()};return[h,function(e){document.removeEventListener("mousemove",p.current),document.removeEventListener("mouseup",f.current),c||(m(e),document.addEventListener("mousemove",v),document.addEventListener("mouseup",g),document.addEventListener("touchmove",v),document.addEventListener("touchend",g),p.current=v,f.current=g)}]}var act=function(e){var t=e.size,n=void 0===t?"default":t,a=e.color,r=e.prefixCls;return f.default.createElement("div",{className:yt("".concat(r,"-handler"),vs({},"".concat(r,"-handler-sm"),"small"===n)),style:{backgroundColor:a}})},rct=function(e){var t=e.children,n=e.style,a=e.prefixCls;return f.default.createElement("div",{className:"".concat(a,"-palette"),style:FGe({position:"relative"},n)},t)},ict=e.forwardRef(function(e,t){var n=e.children,a=e.x,r=e.y;return f.default.createElement("div",{ref:t,style:{position:"absolute",left:"".concat(a,"%"),top:"".concat(r,"%"),zIndex:1,transform:"translate(-50%, -50%)"}},n)}),oct=function(t){var n=t.color,a=t.onChange,r=t.prefixCls,i=t.onChangeComplete,o=t.disabled,l=e.useRef(),s=e.useRef(),c=e.useRef(n),d=BQe(function(e){var t=$st({offset:e,targetRef:s,containerRef:l,color:n});c.current=t,a(t)}),h=Os(nct({color:n,containerRef:l,targetRef:s,calculate:function(){return ect(n)},onDragChange:d,onDragChangeComplete:function(){return null==i?void 0:i(c.current)},disabledDrag:o}),2),u=h[0],p=h[1];return f.default.createElement("div",{ref:l,className:"".concat(r,"-select"),onMouseDown:p,onTouchStart:p},f.default.createElement(rct,{prefixCls:r},f.default.createElement(ict,{x:u.x,y:u.y,ref:s},f.default.createElement(act,{color:n.toRgbString(),prefixCls:r})),f.default.createElement("div",{className:"".concat(r,"-saturation"),style:{backgroundColor:"hsl(".concat(n.toHsb().h,",100%, 50%)"),backgroundImage:"linear-gradient(0deg, #000, transparent),linear-gradient(90deg, #fff, hsla(0, 0%, 100%, 0))"}})))},lct=function(t){var n=t.colors,a=t.children,r=t.direction,i=void 0===r?"to right":r,o=t.type,l=t.prefixCls,s=e.useMemo(function(){return n.map(function(e,t){var a=Xst(e);return"alpha"===o&&t===n.length-1&&(a=new Qst(a.setA(1))),a.toRgbString()}).join(",")},[n,o]);return f.default.createElement("div",{className:"".concat(l,"-gradient"),style:{position:"absolute",inset:0,background:"linear-gradient(".concat(i,", ").concat(s,")")}},a)},sct=function(t){var n=t.prefixCls,a=t.colors,r=t.disabled,i=t.onChange,o=t.onChangeComplete,l=t.color,s=t.type,c=e.useRef(),d=e.useRef(),h=e.useRef(l),u=function(e){return"hue"===s?e.getHue():100*e.a},p=BQe(function(e){var t=$st({offset:e,targetRef:d,containerRef:c,color:l,type:s});h.current=t,i(u(t))}),m=Os(nct({color:l,targetRef:d,containerRef:c,calculate:function(){return ect(l,s)},onDragChange:p,onDragChangeComplete:function(){o(u(h.current))},direction:"x",disabledDrag:r}),2),v=m[0],g=m[1],w=f.default.useMemo(function(){if("hue"===s){var e=l.toHsb();return e.s=1,e.b=1,e.a=1,new Qst(e)}return l},[l,s]),y=f.default.useMemo(function(){return a.map(function(e){return"".concat(e.color," ").concat(e.percent,"%")})},[a]);return f.default.createElement("div",{ref:c,className:yt("".concat(n,"-slider"),"".concat(n,"-slider-").concat(s)),onMouseDown:g,onTouchStart:g},f.default.createElement(rct,{prefixCls:n},f.default.createElement(ict,{x:v.x,y:v.y,ref:d},f.default.createElement(act,{size:"small",color:w.toHexString(),prefixCls:n})),f.default.createElement(lct,{colors:y,type:s,prefixCls:n})))};function cct(e){return m.useMemo(function(){return[(e||{}).slider||sct]},[e])}var dct=[{color:"rgb(255, 0, 0)",percent:0},{color:"rgb(255, 255, 0)",percent:17},{color:"rgb(0, 255, 0)",percent:33},{color:"rgb(0, 255, 255)",percent:50},{color:"rgb(0, 0, 255)",percent:67},{color:"rgb(255, 0, 255)",percent:83},{color:"rgb(255, 0, 0)",percent:100}],hct=e.forwardRef(function(t,n){var a=t.value,r=t.defaultValue,i=t.prefixCls,o=void 0===i?"rc-color-picker":i,l=t.onChange,s=t.onChangeComplete,c=t.className,d=t.style,h=t.panelRender,u=t.disabledAlpha,p=void 0!==u&&u,m=t.disabled,v=void 0!==m&&m,g=Os(cct(t.components),1)[0],w=function(t,n){var a=Os(KQe(t,{value:n}),2),r=a[0],i=a[1];return[e.useMemo(function(){return Xst(r)},[r]),i]}(r||Jst,a),y=Os(w,2),b=y[0],x=y[1],E=e.useMemo(function(){return b.setA(1).toRgbString()},[b]),k=function(e,t){a||x(e),null==l||l(e,t)},M=function(e){return new Qst(b.setHue(e))},S=function(e){return new Qst(b.setA(e/100))},A=yt("".concat(o,"-panel"),c,vs({},"".concat(o,"-panel-disabled"),v)),_={prefixCls:o,disabled:v,color:b},C=f.default.createElement(f.default.Fragment,null,f.default.createElement(oct,In({onChange:k},_,{onChangeComplete:s})),f.default.createElement("div",{className:"".concat(o,"-slider-container")},f.default.createElement("div",{className:yt("".concat(o,"-slider-group"),vs({},"".concat(o,"-slider-group-disabled-alpha"),p))},f.default.createElement(g,In({},_,{type:"hue",colors:dct,min:0,max:359,value:b.getHue(),onChange:function(e){k(M(e),{type:"hue",value:e})},onChangeComplete:function(e){s&&s(M(e))}})),!p&&f.default.createElement(g,In({},_,{type:"alpha",colors:[{percent:0,color:"rgba(255, 0, 4, 0)"},{percent:100,color:E}],min:0,max:100,value:100*b.a,onChange:function(e){k(S(e),{type:"alpha",value:e})},onChangeComplete:function(e){s&&s(S(e))}}))),f.default.createElement(tct,{color:b.toRgbString(),prefixCls:o})));return f.default.createElement("div",{className:A,style:d,ref:n},"function"==typeof h?h(C):C)});"production"!==process.env.NODE_ENV&&(hct.displayName="ColorPicker");var uct=H(Object.freeze({__proto__:null,default:hct,Color:Qst,ColorBlock:tct}));Object.defineProperty(qst,"__esModule",{value:!0}),qst.toHexFormat=qst.getHex=qst.AggregationColor=void 0;var pct=uct;const fct=(e,t)=>e?.replace(/[^\w/]/g,"").slice(0,t?8:6)||"";qst.toHexFormat=fct;const mct=(e,t)=>e?fct(e,t):"";qst.getHex=mct;class vct{metaColor;colors;cleared=!1;constructor(e){if(e instanceof vct)return this.metaColor=e.metaColor.clone(),this.colors=e.colors?.map(e=>({color:new vct(e.color),percent:e.percent})),void(this.cleared=e.cleared);const t=Array.isArray(e);t&&e.length?(this.colors=e.map(({color:e,percent:t})=>({color:new vct(e),percent:t})),this.metaColor=new pct.Color(this.colors[0].color.metaColor)):this.metaColor=new pct.Color(t?"":e),(!e||t&&!this.colors)&&(this.metaColor=this.metaColor.setA(0),this.cleared=!0)}toHsb(){return this.metaColor.toHsb()}toHsbString(){return this.metaColor.toHsbString()}toHex(){return mct(this.toHexString(),this.metaColor.a<1)}toHexString(){return this.metaColor.toHexString()}toRgb(){return this.metaColor.toRgb()}toRgbString(){return this.metaColor.toRgbString()}isGradient(){return!!this.colors&&!this.cleared}getColors(){return this.colors||[{color:this,percent:0}]}toCssString(){const{colors:e}=this;if(e){const t=e.map(e=>`${e.color.toRgbString()} ${e.percent}%`).join(", ");return`linear-gradient(90deg, ${t})`}return this.metaColor.toRgbString()}equals(e){return!(!e||this.isGradient()!==e.isGradient())&&(this.isGradient()?this.colors.length===e.colors.length&&this.colors.every((t,n)=>{const a=e.colors[n];return t.percent===a.percent&&t.color.equals(a.color)}):this.toHexString()===e.toHexString())}}qst.AggregationColor=vct;var gct={},wct={},yct={},bct=f.default.forwardRef(function(e,t){var n=e.prefixCls,a=e.forceRender,r=e.className,i=e.style,o=e.children,l=e.isActive,s=e.role,c=e.classNames,d=e.styles,h=Os(f.default.useState(l||a),2),u=h[0],p=h[1];return f.default.useEffect(function(){(a||l)&&p(!0)},[a,l]),u?f.default.createElement("div",{ref:t,className:yt("".concat(n,"-content"),vs(vs({},"".concat(n,"-content-active"),l),"".concat(n,"-content-inactive"),!l),r),style:i,role:s},f.default.createElement("div",{className:yt("".concat(n,"-content-box"),null==c?void 0:c.body),style:null==d?void 0:d.body},o)):null});bct.displayName="PanelContent";var xct=["showArrow","headerClass","isActive","onItemClick","forceRender","className","classNames","styles","prefixCls","collapsible","accordion","panelKey","extra","header","expandIcon","openMotion","destroyInactivePanel","children"],Ect=f.default.forwardRef(function(e,t){var n=e.showArrow,a=void 0===n||n,r=e.headerClass,i=e.isActive,o=e.onItemClick,l=e.forceRender,s=e.className,c=e.classNames,d=void 0===c?{}:c,h=e.styles,u=void 0===h?{}:h,p=e.prefixCls,m=e.collapsible,v=e.accordion,g=e.panelKey,w=e.extra,y=e.header,b=e.expandIcon,x=e.openMotion,E=e.destroyInactivePanel,k=e.children,M=ps(e,xct),S="disabled"===m,A=null!=w&&"boolean"!=typeof w,_=vs(vs(vs({onClick:function(){null==o||o(g)},onKeyDown:function(e){"Enter"!==e.key&&e.keyCode!==wJe.ENTER&&e.which!==wJe.ENTER||null==o||o(g)},role:v?"tab":"button"},"aria-expanded",i),"aria-disabled",S),"tabIndex",S?-1:0),C="function"==typeof b?b(e):f.default.createElement("i",{className:"arrow"}),Z=C&&f.default.createElement("div",In({className:"".concat(p,"-expand-icon")},["header","icon"].includes(m)?_:{}),C),H=yt("".concat(p,"-item"),vs(vs({},"".concat(p,"-item-active"),i),"".concat(p,"-item-disabled"),S),s),I=FGe({className:yt(r,"".concat(p,"-header"),vs({},"".concat(p,"-collapsible-").concat(m),!!m),d.header),style:u.header},["header","icon"].includes(m)?{}:_);return f.default.createElement("div",In({},M,{ref:t,className:H}),f.default.createElement("div",I,a&&Z,f.default.createElement("span",In({className:"".concat(p,"-header-text")},"header"===m?_:{}),y),A&&f.default.createElement("div",{className:"".concat(p,"-extra")},w)),f.default.createElement(PXe,In({visible:i,leavedClassName:"".concat(p,"-content-hidden")},x,{forceRender:l,removeOnLeave:E}),function(e,t){var n=e.className,a=e.style;return f.default.createElement(bct,{ref:t,prefixCls:p,className:n,classNames:d,style:a,styles:u,isActive:i,forceRender:l,role:v?"tabpanel":void 0},k)}))}),kct=["children","label","key","collapsible","onItemClick","destroyInactivePanel"];function Mct(e,t,n){return Array.isArray(e)?function(e,t){var n=t.prefixCls,a=t.accordion,r=t.collapsible,i=t.destroyInactivePanel,o=t.onItemClick,l=t.activeKey,s=t.openMotion,c=t.expandIcon;return e.map(function(e,t){var d=e.children,h=e.label,u=e.key,p=e.collapsible,m=e.onItemClick,v=e.destroyInactivePanel,g=ps(e,kct),w=String(null!=u?u:t),y=null!=p?p:r,b=null!=v?v:i,x=!1;return x=a?l[0]===w:l.indexOf(w)>-1,f.default.createElement(Ect,In({},g,{prefixCls:n,key:w,panelKey:w,isActive:x,accordion:a,openMotion:s,expandIcon:c,header:h,collapsible:y,onItemClick:function(e){"disabled"!==y&&(o(e),null==m||m(e))},destroyInactivePanel:b}),d)})}(e,n):$Ke(t).map(function(e,t){return function(e,t,n){if(!e)return null;var a=n.prefixCls,r=n.accordion,i=n.collapsible,o=n.destroyInactivePanel,l=n.onItemClick,s=n.activeKey,c=n.openMotion,d=n.expandIcon,h=e.key||String(t),u=e.props,p=u.header,m=u.headerClass,v=u.destroyInactivePanel,g=u.collapsible,w=u.onItemClick,y=!1;y=r?s[0]===h:s.indexOf(h)>-1;var b=null!=g?g:i,x={key:h,panelKey:h,header:p,headerClass:m,isActive:y,prefixCls:a,destroyInactivePanel:null!=v?v:o,openMotion:c,accordion:r,children:e.props.children,onItemClick:function(e){"disabled"!==b&&(l(e),null==w||w(e))},expandIcon:d,collapsible:b};return"string"==typeof e.type?e:(Object.keys(x).forEach(function(e){void 0===x[e]&&delete x[e]}),f.default.cloneElement(e,x))}(e,t,n)})}var Sct="".concat("accept acceptCharset accessKey action allowFullScreen allowTransparency\n alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge\n charSet checked classID className colSpan cols content contentEditable contextMenu\n controls coords crossOrigin data dateTime default defer dir disabled download draggable\n encType form formAction formEncType formMethod formNoValidate formTarget frameBorder\n headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity\n is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media\n mediaGroup method min minLength multiple muted name noValidate nonce open\n optimum pattern placeholder poster preload radioGroup readOnly rel required\n reversed role rowSpan rows sandbox scope scoped scrolling seamless selected\n shape size sizes span spellCheck src srcDoc srcLang srcSet start step style\n summary tabIndex target title type useMap value width wmode wrap"," ").concat("onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown\n onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick\n onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown\n onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel\n onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough\n onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata\n onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError").split(/[\s\n]+/);function Act(e,t){return 0===e.indexOf(t)}function _ct(e){var t=e;if(!Array.isArray(t)){var n=fs(t);t="number"===n||"string"===n?[t]:[]}return t.map(function(e){return String(e)})}var Cct=f.default.forwardRef(function(e,t){var n=e.prefixCls,a=void 0===n?"rc-collapse":n,r=e.destroyInactivePanel,i=void 0!==r&&r,o=e.style,l=e.accordion,s=e.className,c=e.children,d=e.collapsible,h=e.openMotion,u=e.expandIcon,p=e.activeKey,m=e.defaultActiveKey,v=e.onChange,g=e.items,w=yt(a,s),y=KQe([],{value:p,onChange:function(e){return null==v?void 0:v(e)},defaultValue:m,postState:_ct}),b=Os(y,2),x=b[0],E=b[1];XGe(!c,"[rc-collapse] `children` will be removed in next major version. Please use `items` instead.");var k=Mct(g,c,{prefixCls:a,accordion:l,openMotion:h,expandIcon:u,collapsible:d,destroyInactivePanel:i,onItemClick:function(e){return E(function(){return l?x[0]===e?[]:[e]:x.indexOf(e)>-1?x.filter(function(t){return t!==e}):[].concat(IKe(x),[e])})},activeKey:x});return f.default.createElement("div",In({ref:t,className:w,style:o,role:l?"tablist":void 0},function(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];t=!1===n?{aria:!0,data:!0,attr:!0}:!0===n?{aria:!0}:FGe({},n);var a={};return Object.keys(e).forEach(function(n){(t.aria&&("role"===n||Act(n,"aria-"))||t.data&&Act(n,"data-")||t.attr&&Sct.includes(n))&&(a[n]=e[n])}),a}(e,{aria:!0,data:!0})),k)}),Zct=Object.assign(Cct,{Panel:Ect}),Hct=Zct.Panel,Ict=H(Object.freeze({__proto__:null,default:Zct,Panel:Hct})),Dct={},Nct=sqe.exports;Object.defineProperty(Dct,"__esModule",{value:!0}),Dct.default=void 0;var Oct=Nct(dqe.exports),Lct=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Bct(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),Vct=Nct(wt.exports),zct=Nct(Ict),Pct=Q2e,Tct=D5e;function Bct(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Bct=function(e){return e?n:t})(e)}const jct=Lct.forwardRef((e,t)=>{if("production"!==process.env.NODE_ENV){(0,Pct.devUseWarning)("Collapse.Panel").deprecated(!("disabled"in e),"disabled",'collapsible="disabled"')}const{getPrefixCls:n}=Lct.useContext(Tct.ConfigContext),{prefixCls:a,className:r,showArrow:i=!0}=e,o=n("collapse",a),l=(0,Vct.default)({[`${o}-no-arrow`]:!i},r);return Lct.createElement(zct.default.Panel,(0,Oct.default)({ref:t},e,{prefixCls:o,className:l}))});Dct.default=jct;var Wct={};Object.defineProperty(Wct,"__esModule",{value:!0}),Wct.prepareComponentToken=Wct.genBaseStyle=Wct.default=void 0;var Rct=u1e,Fct=y4e,Yct=fnt,qct=G3e;const Uct=e=>{const{componentCls:t,contentBg:n,padding:a,headerBg:r,headerPadding:i,collapseHeaderPaddingSM:o,collapseHeaderPaddingLG:l,collapsePanelBorderRadius:s,lineWidth:c,lineType:d,colorBorder:h,colorText:u,colorTextHeading:p,colorTextDisabled:f,fontSizeLG:m,lineHeight:v,lineHeightLG:g,marginSM:w,paddingSM:y,paddingLG:b,paddingXS:x,motionDurationSlow:E,fontSizeIcon:k,contentPadding:M,fontHeight:S,fontHeightLG:A}=e,_=`${(0,Rct.unit)(c)} ${d} ${h}`;return{[t]:{...(0,Fct.resetComponent)(e),backgroundColor:r,border:_,borderRadius:s,"&-rtl":{direction:"rtl"},[`& > ${t}-item`]:{borderBottom:_,"&:last-child":{[`\n &,\n & > ${t}-header`]:{borderRadius:`0 0 ${(0,Rct.unit)(s)} ${(0,Rct.unit)(s)}`}},[`> ${t}-header`]:{position:"relative",display:"flex",flexWrap:"nowrap",alignItems:"flex-start",padding:i,color:p,lineHeight:v,cursor:"pointer",transition:`all ${E}, visibility 0s`,[`> ${t}-header-text`]:{flex:"auto"},"&:focus":{outline:"none"},[`${t}-expand-icon`]:{height:S,display:"flex",alignItems:"center",paddingInlineEnd:w},[`${t}-arrow`]:{...(0,Fct.resetIcon)(),fontSize:k,transition:`transform ${E}`,svg:{transition:`transform ${E}`}},[`${t}-header-text`]:{marginInlineEnd:"auto"}},[`${t}-collapsible-header`]:{cursor:"default",[`${t}-header-text`]:{flex:"none",cursor:"pointer"}},[`${t}-collapsible-icon`]:{cursor:"unset",[`${t}-expand-icon`]:{cursor:"pointer"}}},[`${t}-content`]:{color:u,backgroundColor:n,borderTop:_,[`& > ${t}-content-box`]:{padding:M},"&-hidden":{display:"none"}},"&-small":{[`> ${t}-item`]:{[`> ${t}-header`]:{padding:o,paddingInlineStart:x,[`> ${t}-expand-icon`]:{marginInlineStart:e.calc(y).sub(x).equal()}},[`> ${t}-content > ${t}-content-box`]:{padding:y}}},"&-large":{[`> ${t}-item`]:{fontSize:m,lineHeight:g,[`> ${t}-header`]:{padding:l,paddingInlineStart:a,[`> ${t}-expand-icon`]:{height:A,marginInlineStart:e.calc(b).sub(a).equal()}},[`> ${t}-content > ${t}-content-box`]:{padding:b}}},[`${t}-item:last-child`]:{borderBottom:0,[`> ${t}-content`]:{borderRadius:`0 0 ${(0,Rct.unit)(s)} ${(0,Rct.unit)(s)}`}},[`& ${t}-item-disabled > ${t}-header`]:{"\n &,\n & > .arrow\n ":{color:f,cursor:"not-allowed"}},[`&${t}-icon-position-end`]:{[`& > ${t}-item`]:{[`> ${t}-header`]:{[`${t}-expand-icon`]:{order:1,paddingInlineEnd:0,paddingInlineStart:w}}}}}}};Wct.genBaseStyle=Uct;const Gct=e=>{const{componentCls:t}=e,n=`> ${t}-item > ${t}-header ${t}-arrow`;return{[`${t}-rtl`]:{[n]:{transform:"rotate(180deg)"}}}},Kct=e=>{const{componentCls:t,headerBg:n,paddingXXS:a,colorBorder:r}=e;return{[`${t}-borderless`]:{backgroundColor:n,border:0,[`> ${t}-item`]:{borderBottom:`1px solid ${r}`},[`\n > ${t}-item:last-child,\n > ${t}-item:last-child ${t}-header\n `]:{borderRadius:0},[`> ${t}-item:last-child`]:{borderBottom:0},[`> ${t}-item > ${t}-content`]:{backgroundColor:"transparent",borderTop:0},[`> ${t}-item > ${t}-content > ${t}-content-box`]:{paddingTop:a}}}},Qct=e=>{const{componentCls:t,paddingSM:n}=e;return{[`${t}-ghost`]:{backgroundColor:"transparent",border:0,[`> ${t}-item`]:{borderBottom:0,[`> ${t}-content`]:{backgroundColor:"transparent",border:0,[`> ${t}-content-box`]:{paddingBlock:n}}}}}},Xct=e=>({headerPadding:`${e.paddingSM}px ${e.padding}px`,headerBg:e.colorFillAlter,contentPadding:`${e.padding}px 16px`,contentBg:e.colorBgContainer});Wct.prepareComponentToken=Xct,Wct.default=(0,qct.genStyleHooks)("Collapse",e=>{const t=(0,qct.mergeToken)(e,{collapseHeaderPaddingSM:`${(0,Rct.unit)(e.paddingXS)} ${(0,Rct.unit)(e.paddingSM)}`,collapseHeaderPaddingLG:`${(0,Rct.unit)(e.padding)} ${(0,Rct.unit)(e.paddingLG)}`,collapsePanelBorderRadius:e.borderRadiusLG});return[Uct(t),Kct(t),Qct(t),Gct(t),(0,Yct.genCollapseMotion)(t)]},Xct);var Jct=sqe.exports;Object.defineProperty(yct,"__esModule",{value:!0}),yct.default=void 0;var $ct=Jct(dqe.exports),edt=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=pdt(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),tdt=Jct(hqe.exports),ndt=Jct(wt.exports),adt=Jct(Ict),rdt=Jct(B9e),idt=Jct(XJe),odt=Jct(k9e),ldt=w7e,sdt=Q2e,cdt=D5e,ddt=Jct(Btt),hdt=Jct(Dct),udt=Jct(Wct);function pdt(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(pdt=function(e){return e?n:t})(e)}const fdt=edt.forwardRef((e,t)=>{const{getPrefixCls:n,direction:a,collapse:r}=edt.useContext(cdt.ConfigContext),{prefixCls:i,className:o,rootClassName:l,style:s,bordered:c=!0,ghost:d,size:h,expandIconPosition:u="start",children:p,expandIcon:f}=e,m=(0,ddt.default)(e=>h??e??"middle"),v=n("collapse",i),g=n(),[w,y,b]=(0,udt.default)(v);if("production"!==process.env.NODE_ENV){(0,sdt.devUseWarning)("Collapse")("left"!==u&&"right"!==u,"deprecated","`expandIconPosition` with `left` or `right` is deprecated. Please use `start` or `end` instead.")}const x=edt.useMemo(()=>"left"===u?"start":"right"===u?"end":u,[u]),E=f??r?.expandIcon,k=edt.useCallback((e={})=>{const t="function"==typeof E?E(e):edt.createElement(tdt.default,{rotate:e.isActive?90:void 0,"aria-label":e.isActive?"expanded":"collapsed"});return(0,ldt.cloneElement)(t,()=>({className:(0,ndt.default)(t?.props?.className,`${v}-arrow`)}))},[E,v]),M=(0,ndt.default)(`${v}-icon-position-${x}`,{[`${v}-borderless`]:!c,[`${v}-rtl`]:"rtl"===a,[`${v}-ghost`]:!!d,[`${v}-${m}`]:"middle"!==m},r?.className,o,l,y,b),S={...(0,odt.default)(g),motionAppear:!1,leavedClassName:`${v}-content-hidden`},A=edt.useMemo(()=>p?(0,rdt.default)(p).map((e,t)=>{if(e.props?.disabled){const n=e.key??String(t),{disabled:a,collapsible:r}=e.props,i={...(0,idt.default)(e.props,["disabled"]),key:n,collapsible:r??(a?"disabled":void 0)};return(0,ldt.cloneElement)(e,i)}return e}):null,[p]);return w(edt.createElement(adt.default,(0,$ct.default)({ref:t,openMotion:S},(0,idt.default)(e,["rootClassName"]),{expandIcon:k,prefixCls:v,className:M,style:{...r?.style,...s}}),A))});"production"!==process.env.NODE_ENV&&(fdt.displayName="Collapse"),yct.default=Object.assign(fdt,{Panel:hdt.default});var mdt=sqe.exports;Object.defineProperty(wct,"__esModule",{value:!0}),wct.default=void 0;var vdt=mdt(yct);wct.default=vdt.default;var gdt={};Object.defineProperty(gdt,"__esModule",{value:!0}),gdt.getRoundNumber=gdt.getGradientPercentColor=gdt.getColorAlpha=gdt.generateColor=gdt.genAlphaColor=void 0;var wdt=uct,ydt=qst;const bdt=e=>e instanceof ydt.AggregationColor?e:new ydt.AggregationColor(e);gdt.generateColor=bdt;const xdt=e=>Math.round(Number(e||0));gdt.getRoundNumber=xdt;gdt.getColorAlpha=e=>xdt(100*e.toHsb().a);gdt.genAlphaColor=(e,t)=>{const n=e.toRgb();if(!n.r&&!n.g&&!n.b){const n=e.toHsb();return n.a=t||1,bdt(n)}return n.a=t||1,bdt(n)};gdt.getGradientPercentColor=(e,t)=>{const n=[{percent:0,color:e[0].color},...e,{percent:100,color:e[e.length-1].color}];for(let e=0;e<n.length-1;e+=1){const a=n[e].percent,r=n[e+1].percent,i=n[e].color,o=n[e+1].color;if(a<=t&&t<=r){const e=r-a;if(0===e)return i;const n=(t-a)/e*100,l=new wdt.Color(i),s=new wdt.Color(o);return l.mix(s,n).toRgbString()}}return""};var Edt=sqe.exports;Object.defineProperty(gct,"__esModule",{value:!0}),gct.isBright=gct.default=void 0;var kdt=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Idt(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),Mdt=uct,Sdt=Edt(wt.exports),Adt=Edt(DJe),_dt=Edt(wct),Cdt=t3e,Zdt=G3e,Hdt=gdt;function Idt(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Idt=function(e){return e?n:t})(e)}const Ddt=e=>e.map(e=>(e.colors=e.colors.map(Hdt.generateColor),e)),Ndt=(e,t)=>{const{r:n,g:a,b:r,a:i}=e.toRgb(),o=new Mdt.Color(e.toRgbString()).onBackground(t).toHsv();return i<=.5?o.v>.5:.299*n+.587*a+.114*r>192};gct.isBright=Ndt;const Odt=({label:e})=>`panel-${e}`;gct.default=({prefixCls:e,presets:t,value:n,onChange:a})=>{const[r]=(0,Cdt.useLocale)("ColorPicker"),[,i]=(0,Zdt.useToken)(),[o]=(0,Adt.default)(Ddt(t),{value:Ddt(t),postState:Ddt}),l=`${e}-presets`,s=(0,kdt.useMemo)(()=>o.reduce((e,t)=>{const{defaultOpen:n=!0}=t;return n&&e.push(Odt(t)),e},[]),[o]),c=o.map(t=>({key:Odt(t),label:kdt.default.createElement("div",{className:`${l}-label`},t?.label),children:kdt.default.createElement("div",{className:`${l}-items`},Array.isArray(t?.colors)&&t.colors?.length>0?t.colors.map((t,r)=>kdt.default.createElement(Mdt.ColorBlock,{key:`preset-${r}-${t.toHexString()}`,color:(0,Hdt.generateColor)(t).toRgbString(),prefixCls:e,className:(0,Sdt.default)(`${l}-color`,{[`${l}-color-checked`]:t.toHexString()===n?.toHexString(),[`${l}-color-bright`]:Ndt(t,i.colorBgElevated)}),onClick:()=>{return e=t,void a?.(e);var e}})):kdt.default.createElement("span",{className:`${l}-empty`},r.presetEmpty))}));return kdt.default.createElement("div",{className:l},kdt.default.createElement(_dt.default,{defaultActiveKey:s,ghost:!0,items:c}))},Object.defineProperty(Yst,"__esModule",{value:!0}),Yst.prepareToken=Yst.prepareComponentToken=void 0;var Ldt=qst,Vdt=gct,zdt=G3e;Yst.prepareToken=e=>{const{paddingInline:t,onlyIconSize:n,paddingBlock:a}=e;return(0,zdt.mergeToken)(e,{buttonPaddingHorizontal:t,buttonPaddingVertical:a,buttonIconOnlyFontSize:n})};Yst.prepareComponentToken=e=>{const t=e.contentFontSize??e.fontSize,n=e.contentFontSizeSM??e.fontSize,a=e.contentFontSizeLG??e.fontSizeLG,r=e.contentLineHeight??(0,zdt.getLineHeight)(t),i=e.contentLineHeightSM??(0,zdt.getLineHeight)(n),o=e.contentLineHeightLG??(0,zdt.getLineHeight)(a),l=(0,Vdt.isBright)(new Ldt.AggregationColor(e.colorBgSolid),"#fff")?"#000":"#fff";return{fontWeight:400,defaultShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlTmpOutline}`,primaryShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlOutline}`,dangerShadow:`0 ${e.controlOutlineWidth}px 0 ${e.colorErrorOutline}`,primaryColor:e.colorTextLightSolid,dangerColor:e.colorTextLightSolid,borderColorDisabled:e.colorBorder,defaultGhostColor:e.colorBgContainer,ghostBg:"transparent",defaultGhostBorderColor:e.colorBgContainer,paddingInline:e.paddingContentHorizontal-e.lineWidth,paddingInlineLG:e.paddingContentHorizontal-e.lineWidth,paddingInlineSM:8-e.lineWidth,onlyIconSize:e.fontSizeLG,onlyIconSizeSM:e.fontSizeLG-2,onlyIconSizeLG:e.fontSizeLG+2,groupBorderColor:e.colorPrimaryHover,linkHoverBg:"transparent",textTextColor:e.colorText,textTextHoverColor:e.colorText,textTextActiveColor:e.colorText,textHoverBg:e.colorFillTertiary,defaultColor:e.colorText,defaultBg:e.colorBgContainer,defaultBorderColor:e.colorBorder,defaultBorderColorDisabled:e.colorBorder,defaultHoverBg:e.colorBgContainer,defaultHoverColor:e.colorPrimaryHover,defaultHoverBorderColor:e.colorPrimaryHover,defaultActiveBg:e.colorBgContainer,defaultActiveColor:e.colorPrimaryActive,defaultActiveBorderColor:e.colorPrimaryActive,solidTextColor:l,contentFontSize:t,contentFontSizeSM:n,contentFontSizeLG:a,contentLineHeight:r,contentLineHeightSM:i,contentLineHeightLG:o,paddingBlock:Math.max((e.controlHeight-t*r)/2-e.lineWidth,0),paddingBlockSM:Math.max((e.controlHeightSM-n*i)/2-e.lineWidth,0),paddingBlockLG:Math.max((e.controlHeightLG-a*o)/2-e.lineWidth,0)}};var Pdt=sqe.exports;Object.defineProperty(Wst,"__esModule",{value:!0}),Wst.default=void 0;var Tdt=u1e,Bdt=y4e,jdt=G3e,Wdt=Pdt(Rst),Rdt=Yst;const Fdt=e=>{const{componentCls:t,iconCls:n,fontWeight:a}=e;return{[t]:{outline:"none",position:"relative",display:"inline-flex",gap:e.marginXS,alignItems:"center",justifyContent:"center",fontWeight:a,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",background:"transparent",border:`${(0,Tdt.unit)(e.lineWidth)} ${e.lineType} transparent`,cursor:"pointer",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,userSelect:"none",touchAction:"manipulation",color:e.colorText,"&:disabled > *":{pointerEvents:"none"},[`> span, ${t}-icon`]:{display:"inline-flex"},"> a":{color:"currentColor"},"&:not(:disabled)":{...(0,Bdt.genFocusStyle)(e)},[`&${t}-two-chinese-chars::first-letter`]:{letterSpacing:"0.34em"},[`&${t}-two-chinese-chars > *:not(${n})`]:{marginInlineEnd:"-0.34em",letterSpacing:"0.34em"},"&-icon-end":{flexDirection:"row-reverse"}}}},Ydt=(e,t,n)=>({[`&:not(:disabled):not(${e}-disabled)`]:{"&:hover":t,"&:active":n}}),qdt=e=>({minWidth:e.controlHeight,paddingInlineStart:0,paddingInlineEnd:0,borderRadius:"50%"}),Udt=e=>({borderRadius:e.controlHeight,paddingInlineStart:e.calc(e.controlHeight).div(2).equal(),paddingInlineEnd:e.calc(e.controlHeight).div(2).equal()}),Gdt=e=>({cursor:"not-allowed",borderColor:e.borderColorDisabled,color:e.colorTextDisabled,background:e.colorBgContainerDisabled,boxShadow:"none"}),Kdt=(e,t,n,a,r,i,o,l)=>({[`&${e}-background-ghost`]:{color:n||void 0,background:t,borderColor:a||void 0,boxShadow:"none",...Ydt(e,{background:t,...o},{background:t,...l}),"&:disabled":{cursor:"not-allowed",color:r||void 0,borderColor:i||void 0}}}),Qdt=e=>({[`&:disabled, &${e.componentCls}-disabled`]:{...Gdt(e)}}),Xdt=e=>({[`&:disabled, &${e.componentCls}-disabled`]:{cursor:"not-allowed",color:e.colorTextDisabled}}),Jdt=(e,t,n,a)=>({...(a&&["link","text"].includes(a)?Xdt:Qdt)(e),...Ydt(e.componentCls,t,n)}),$dt=(e,t,n,a,r)=>({[`&${e.componentCls}-variant-solid`]:{color:t,background:n,...Jdt(e,a,r)}}),eht=(e,t,n,a,r)=>({[`&${e.componentCls}-variant-outlined, &${e.componentCls}-variant-dashed`]:{borderColor:t,background:n,...Jdt(e,a,r)}}),tht=e=>({[`&${e.componentCls}-variant-dashed`]:{borderStyle:"dashed"}}),nht=(e,t,n,a)=>({[`&${e.componentCls}-variant-filled`]:{boxShadow:"none",background:t,...Jdt(e,n,a)}}),aht=(e,t,n,a,r)=>({[`&${e.componentCls}-variant-${n}`]:{color:t,boxShadow:"none",...Jdt(e,a,r,n)}}),rht=e=>({color:e.defaultColor,boxShadow:e.defaultShadow,...$dt(e,e.solidTextColor,e.colorBgSolid,{background:e.colorBgSolidHover},{background:e.colorBgSolidActive}),...tht(e),...nht(e,e.colorFillTertiary,{background:e.colorFillSecondary},{background:e.colorFill}),...aht(e,e.textTextColor,"link",{color:e.colorLinkHover,background:e.linkHoverBg},{color:e.colorLinkActive}),...Kdt(e.componentCls,e.ghostBg,e.defaultGhostColor,e.defaultGhostBorderColor,e.colorTextDisabled,e.colorBorder)}),iht=e=>({color:e.colorPrimary,boxShadow:e.primaryShadow,...eht(e,e.colorPrimary,e.colorBgContainer,{color:e.colorPrimaryTextHover,borderColor:e.colorPrimaryHover,background:e.colorBgContainer},{color:e.colorPrimaryTextActive,borderColor:e.colorPrimaryActive,background:e.colorBgContainer}),...tht(e),...nht(e,e.colorPrimaryBg,{background:e.colorPrimaryBgHover},{background:e.colorPrimaryBorder}),...aht(e,e.colorLink,"text",{color:e.colorPrimaryTextHover,background:e.colorPrimaryBg},{color:e.colorPrimaryTextActive,background:e.colorPrimaryBorder}),...Kdt(e.componentCls,e.ghostBg,e.colorPrimary,e.colorPrimary,e.colorTextDisabled,e.colorBorder,{color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})}),oht=e=>({color:e.colorError,boxShadow:e.dangerShadow,...$dt(e,e.dangerColor,e.colorError,{background:e.colorErrorHover},{background:e.colorErrorActive}),...eht(e,e.colorError,e.colorBgContainer,{color:e.colorErrorHover,borderColor:e.colorErrorBorderHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive}),...tht(e),...nht(e,e.colorErrorBg,{background:e.colorErrorBgFilledHover},{background:e.colorErrorBgActive}),...aht(e,e.colorError,"text",{color:e.colorErrorHover,background:e.colorErrorBg},{color:e.colorErrorHover,background:e.colorErrorBgActive}),...aht(e,e.colorError,"link",{color:e.colorErrorHover},{color:e.colorErrorActive}),...Kdt(e.componentCls,e.ghostBg,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder,{color:e.colorErrorHover,borderColor:e.colorErrorHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})}),lht=e=>{const{componentCls:t}=e;return{[`${t}-color-default`]:rht(e),[`${t}-color-primary`]:iht(e),[`${t}-color-dangerous`]:oht(e)}},sht=e=>({...eht(e,e.defaultBorderColor,e.defaultBg,{color:e.defaultHoverColor,borderColor:e.defaultHoverBorderColor,background:e.defaultHoverBg},{color:e.defaultActiveColor,borderColor:e.defaultActiveBorderColor,background:e.defaultActiveBg}),...aht(e,e.textTextColor,"text",{color:e.textTextHoverColor,background:e.textHoverBg},{color:e.textTextActiveColor,background:e.colorBgTextActive}),...$dt(e,e.primaryColor,e.colorPrimary,{background:e.colorPrimaryHover,color:e.primaryColor},{background:e.colorPrimaryActive,color:e.primaryColor}),...aht(e,e.colorLink,"link",{color:e.colorLinkHover,background:e.linkHoverBg},{color:e.colorLinkActive})}),cht=(e,t="")=>{const{componentCls:n,controlHeight:a,fontSize:r,lineHeight:i,borderRadius:o,buttonPaddingHorizontal:l,iconCls:s,buttonPaddingVertical:c,motionDurationSlow:d,motionEaseInOut:h,buttonIconOnlyFontSize:u,opacityLoading:p}=e;return[{[t]:{fontSize:r,lineHeight:i,height:a,padding:`${(0,Tdt.unit)(c)} ${(0,Tdt.unit)(l)}`,borderRadius:o,[`&${n}-icon-only`]:{width:a,paddingInline:0,[`&${n}-compact-item`]:{flex:"none"},[`&${n}-round`]:{width:"auto"},[s]:{fontSize:u}},[`&${n}-loading`]:{opacity:p,cursor:"default"},[`${n}-loading-icon`]:{transition:`width ${d} ${h}, opacity ${d} ${h}`}}},{[`${n}${n}-circle${t}`]:qdt(e)},{[`${n}${n}-round${t}`]:Udt(e)}]},dht=e=>{const t=(0,jdt.mergeToken)(e,{fontSize:e.contentFontSize,lineHeight:e.contentLineHeight});return cht(t,e.componentCls)},hht=e=>{const t=(0,jdt.mergeToken)(e,{controlHeight:e.controlHeightSM,fontSize:e.contentFontSizeSM,lineHeight:e.contentLineHeightSM,padding:e.paddingXS,buttonPaddingHorizontal:e.paddingInlineSM,buttonPaddingVertical:e.paddingBlockSM,borderRadius:e.borderRadiusSM,buttonIconOnlyFontSize:e.onlyIconSizeSM});return cht(t,`${e.componentCls}-sm`)},uht=e=>{const t=(0,jdt.mergeToken)(e,{controlHeight:e.controlHeightLG,fontSize:e.contentFontSizeLG,lineHeight:e.contentLineHeightLG,buttonPaddingHorizontal:e.paddingInlineLG,buttonPaddingVertical:e.paddingBlockLG,borderRadius:e.borderRadiusLG,buttonIconOnlyFontSize:e.onlyIconSizeLG});return cht(t,`${e.componentCls}-lg`)},pht=e=>{const{componentCls:t}=e;return{[t]:{[`&${t}-block`]:{width:"100%"}}}};Wst.default=(0,jdt.genStyleHooks)("Button",e=>{const t=(0,Rdt.prepareToken)(e);return[Fdt(t),dht(t),hht(t),uht(t),pht(t),lht(t),sht(t),(0,Wdt.default)(t)]},Rdt.prepareComponentToken,{unitless:{fontWeight:!0,contentLineHeight:!0,contentLineHeightSM:!0,contentLineHeightLG:!0}});var fht={},mht={};function vht(e,t,n){const{focusElCls:a,focus:r,borderElCls:i}=n,o=i?"> *":"",l=["hover",r?"focus":null,"active"].filter(Boolean).map(e=>`&:${e} ${o}`).join(",");return{[`&-item:not(${t}-last-item)`]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal()},"&-item":{[l]:{zIndex:2},...a?{[`&${a}`]:{zIndex:2}}:{},[`&[disabled] ${o}`]:{zIndex:0}}}}function ght(e,t,n){const{borderElCls:a}=n,r=a?`> ${a}`:"";return{[`&-item:not(${t}-first-item):not(${t}-last-item) ${r}`]:{borderRadius:0},[`&-item:not(${t}-last-item)${t}-first-item`]:{[`& ${r}, &${e}-sm ${r}, &${e}-lg ${r}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${t}-first-item)${t}-last-item`]:{[`& ${r}, &${e}-sm ${r}, &${e}-lg ${r}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}Object.defineProperty(mht,"__esModule",{value:!0}),mht.genCompactItemStyle=function(e,t={focus:!0}){const{componentCls:n}=e,a=`${n}-compact`;return{[a]:{...vht(e,a,t),...ght(n,a,t)}}};var wht={};function yht(e,t){return{[`&-item:not(${t}-last-item)`]:{marginBottom:e.calc(e.lineWidth).mul(-1).equal()},"&-item":{"&:hover,&:focus,&:active":{zIndex:2},"&[disabled]":{zIndex:0}}}}Object.defineProperty(wht,"__esModule",{value:!0}),wht.genCompactItemVerticalStyle=function(e){const t=`${e.componentCls}-compact-vertical`;return{[t]:{...yht(e,t),...(n=e.componentCls,a=t,{[`&-item:not(${a}-first-item):not(${a}-last-item)`]:{borderRadius:0},[`&-item${a}-first-item:not(${a}-last-item)`]:{[`&, &${n}-sm, &${n}-lg`]:{borderEndEndRadius:0,borderEndStartRadius:0}},[`&-item${a}-last-item:not(${a}-first-item)`]:{[`&, &${n}-sm, &${n}-lg`]:{borderStartStartRadius:0,borderStartEndRadius:0}}})}};var n,a},Object.defineProperty(fht,"__esModule",{value:!0}),fht.default=void 0;var bht=mht,xht=wht,Eht=G3e,kht=Yst;const Mht=e=>{const{componentCls:t,colorPrimaryHover:n,lineWidth:a,calc:r}=e,i=r(a).mul(-1).equal(),o=e=>({[`${t}-compact${e?"-vertical":""}-item${t}-primary:not([disabled])`]:{"& + &::before":{position:"absolute",top:e?i:0,insetInlineStart:e?0:i,backgroundColor:n,content:'""',width:e?"100%":a,height:e?a:"100%"}}});return{...o(),...o(!0)}};fht.default=(0,Eht.genSubStyleComponent)(["Button","compact"],e=>{const t=(0,kht.prepareToken)(e);return[(0,bht.genCompactItemStyle)(t),(0,xht.genCompactItemVerticalStyle)(t),Mht(t)]},kht.prepareComponentToken);var Sht=sqe.exports;Object.defineProperty(kot,"__esModule",{value:!0}),kot.default=void 0;var Aht=Sht(dqe.exports),_ht=Fht(f.default),Cht=Sht(wt.exports),Zht=Sht(XJe),Hht=ert,Iht=Q2e,Dht=Sht(Mot),Nht=D5e,Oht=Sht(H3e),Lht=Sht(Btt),Vht=Ttt,zht=Fht(Xlt),Pht=lst,Tht=Sht(fst),Bht=Sht(bst),jht=Sht(Wst),Wht=Sht(fht);function Rht(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(Rht=function(e){return e?n:t})(e)}function Fht(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=Rht(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}const Yht={default:["default","outlined"],primary:["primary","solid"],dashed:["default","dashed"],link:["primary","link"],text:["default","text"]},qht=_ht.default.forwardRef((e,t)=>{const{loading:n=!1,prefixCls:a,color:r,variant:i,type:o,danger:l=!1,shape:s="default",size:c,styles:d,disabled:h,className:u,rootClassName:p,children:f,icon:m,iconPosition:v="start",ghost:g=!1,block:w=!1,htmlType:y="button",classNames:b,style:x={},autoInsertSpace:E,autoFocus:k,...M}=e,S=o||"default",[A,_]=(0,_ht.useMemo)(()=>{if(r&&i)return[r,i];const e=Yht[S]||[];return l?["danger",e[1]]:e},[o,r,i,l]),C="danger"===A?"dangerous":A,{getPrefixCls:Z,direction:H,button:I}=(0,_ht.useContext)(Nht.ConfigContext),D=E??I?.autoInsertSpace??!0,N=Z("btn",a),[O,L,V]=(0,jht.default)(N),z=(0,_ht.useContext)(Oht.default),P=h??z,T=(0,_ht.useContext)(zht.GroupSizeContext),B=(0,_ht.useMemo)(()=>function(e){if("object"==typeof e&&e){let t=e?.delay;return t=Number.isNaN(t)||"number"!=typeof t?0:t,{loading:t<=0,delay:t}}return{loading:!!e,delay:0}}(n),[n]),[j,W]=(0,_ht.useState)(B.loading),[R,F]=(0,_ht.useState)(!1),Y=(0,_ht.useRef)(),q=(0,Hht.useComposeRef)(t,Y),U=1===_ht.Children.count(f)&&!m&&!(0,Pht.isUnBorderedButtonVariant)(_);(0,_ht.useEffect)(()=>{let e=null;return B.delay>0?e=setTimeout(()=>{e=null,W(!0)},B.delay):W(B.loading),function(){e&&(clearTimeout(e),e=null)}},[B]),(0,_ht.useEffect)(()=>{if(!Y.current||!D)return;const e=Y.current.textContent||"";U&&(0,Pht.isTwoCNChar)(e)?R||F(!0):R&&F(!1)}),(0,_ht.useEffect)(()=>{k&&Y.current&&Y.current.focus()},[]);const G=_ht.default.useCallback(t=>{j||P?t.preventDefault():e.onClick?.(t)},[e.onClick,j,P]);if("production"!==process.env.NODE_ENV){const e=(0,Iht.devUseWarning)("Button");e(!("string"==typeof m&&m.length>2),"breaking",`\`icon\` is using ReactNode instead of string naming in v4. Please check \`${m}\` at https://ant.design/components/icon`),e(!(g&&(0,Pht.isUnBorderedButtonVariant)(_)),"usage","`link` or `text` button can't be a `ghost` button.")}const{compactSize:K,compactItemClassnames:Q}=(0,Vht.useCompactItemContext)(N,H),X={large:"lg",small:"sm",middle:void 0},J=(0,Lht.default)(e=>c??K??T??e),$=J?X[J]??"":"",ee=j?"loading":m,te=(0,Zht.default)(M,["navigate"]),ne=(0,Cht.default)(N,L,V,{[`${N}-${s}`]:"default"!==s&&s,[`${N}-${S}`]:S,[`${N}-dangerous`]:l,[`${N}-color-${C}`]:C,[`${N}-variant-${_}`]:_,[`${N}-${$}`]:$,[`${N}-icon-only`]:!f&&0!==f&&!!ee,[`${N}-background-ghost`]:g&&!(0,Pht.isUnBorderedButtonVariant)(_),[`${N}-loading`]:j,[`${N}-two-chinese-chars`]:R&&D&&!j,[`${N}-block`]:w,[`${N}-rtl`]:"rtl"===H,[`${N}-icon-end`]:"end"===v},Q,u,p,I?.className),ae={...I?.style,...x},re=(0,Cht.default)(b?.icon,I?.classNames?.icon),ie={...d?.icon||{},...I?.styles?.icon||{}},oe=m&&!j?_ht.default.createElement(Tht.default,{prefixCls:N,className:re,style:ie},m):_ht.default.createElement(Bht.default,{existIcon:!!m,prefixCls:N,loading:j}),le=f||0===f?(0,Pht.spaceChildren)(f,U&&D):null;if(void 0!==te.href)return O(_ht.default.createElement("a",(0,Aht.default)({},te,{className:(0,Cht.default)(ne,{[`${N}-disabled`]:P}),href:P?void 0:te.href,style:ae,onClick:G,ref:q,tabIndex:P?-1:0}),oe,le));let se=_ht.default.createElement("button",(0,Aht.default)({},M,{type:y,className:ne,style:ae,onClick:G,disabled:P,ref:q}),oe,le,Q&&_ht.default.createElement(Wht.default,{prefixCls:N}));return(0,Pht.isUnBorderedButtonVariant)(_)||(se=_ht.default.createElement(Dht.default,{component:"Button",disabled:j},se)),O(se)}),Uht=qht;Uht.Group=zht.default,Uht.__ANT_BUTTON=!0,"production"!==process.env.NODE_ENV&&(Uht.displayName="Button"),kot.default=Uht,function(e){var t=sqe.exports;Object.defineProperty(e,"__esModule",{value:!0});var n={};e.default=void 0;var a=t(kot),r=lst;Object.keys(r).forEach(function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(n,t)||t in e&&e[t]===r[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return r[t]}}))}),e.default=a.default}(Eot);var Ght={},Kht={};Object.defineProperty(Kht,"__esModule",{value:!0}),Kht.isPresetSize=function(e){return["small","middle","large"].includes(e)},Kht.isValidGapNumber=function(e){if(!e)return!1;return"number"==typeof e&&!Number.isNaN(e)};var Qht={},Xht=sqe.exports;Object.defineProperty(Qht,"__esModule",{value:!0}),Qht.SpaceContextProvider=Qht.SpaceContext=void 0;var Jht=Xht(f.default);const $ht=Qht.SpaceContext=Jht.default.createContext({latestIndex:0});Qht.SpaceContextProvider=$ht.Provider;var eut={};Object.defineProperty(eut,"__esModule",{value:!0}),eut.default=void 0;var tut=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=aut(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),nut=Qht;function aut(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(aut=function(e){return e?n:t})(e)}eut.default=({className:e,index:t,children:n,split:a,style:r})=>{const{latestIndex:i}=tut.useContext(nut.SpaceContext);return null==n?null:tut.createElement(tut.Fragment,null,tut.createElement("div",{className:e,style:r},n),t<i&&a&&tut.createElement("span",{className:`${e}-split`},a))},function(e){var t=sqe.exports;Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"SpaceContext",{enumerable:!0,get:function(){return c.SpaceContext}}),e.default=void 0;var n=t(dqe.exports),a=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=u(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),r=t(wt.exports),i=t(B9e),o=Kht,l=D5e,s=t(Ttt),c=Qht,d=t(eut),h=t(Ftt);function u(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(u=function(e){return e?n:t})(e)}const p=a.forwardRef((e,t)=>{const{getPrefixCls:s,space:u,direction:p}=a.useContext(l.ConfigContext),{size:f=u?.size??"small",align:m,className:v,rootClassName:g,children:w,direction:y="horizontal",prefixCls:b,split:x,style:E,wrap:k=!1,classNames:M,styles:S,...A}=e,[_,C]=Array.isArray(f)?f:[f,f],Z=(0,o.isPresetSize)(C),H=(0,o.isPresetSize)(_),I=(0,o.isValidGapNumber)(C),D=(0,o.isValidGapNumber)(_),N=(0,i.default)(w,{keepEmpty:!0}),O=void 0===m&&"horizontal"===y?"center":m,L=s("space",b),[V,z,P]=(0,h.default)(L),T=(0,r.default)(L,u?.className,z,`${L}-${y}`,{[`${L}-rtl`]:"rtl"===p,[`${L}-align-${O}`]:O,[`${L}-gap-row-${C}`]:Z,[`${L}-gap-col-${_}`]:H},v,g,P),B=(0,r.default)(`${L}-item`,M?.item??u?.classNames?.item);let j=0;const W=N.map((e,t)=>{null!=e&&(j=t);const n=e?.key||`${B}-${t}`;return a.createElement(d.default,{className:B,key:n,index:t,split:x,style:S?.item??u?.styles?.item},e)}),R=a.useMemo(()=>({latestIndex:j}),[j]);if(0===N.length)return null;const F={};return k&&(F.flexWrap="wrap"),!H&&D&&(F.columnGap=_),!Z&&I&&(F.rowGap=C),V(a.createElement("div",(0,n.default)({ref:t,className:T,style:{...F,...u?.style,...E}},A),a.createElement(c.SpaceContextProvider,{value:R},W)))}),m=p;m.Compact=s.default,"production"!==process.env.NODE_ENV&&(m.displayName="Space"),e.default=m}(Ght);var rut=sqe.exports;Object.defineProperty(xot,"__esModule",{value:!0}),xot.default=void 0;var iut=rut(dqe.exports),out=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=fut(t);if(n&&n.has(e))return n.get(e);var a={__proto__:null},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var o=r?Object.getOwnPropertyDescriptor(e,i):null;o&&(o.get||o.set)?Object.defineProperty(a,i,o):a[i]=e[i]}return a.default=e,n&&n.set(e,a),a}(f.default),lut=rut(u9e.exports),sut=rut(wt.exports),cut=rut(Eot),dut=D5e,hut=rut(Ght),uut=Ttt,put=rut(cqe);function fut(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(fut=function(e){return e?n:t})(e)}const mut=e=>{const{getPopupContainer:t,getPrefixCls:n,direction:a}=out.useContext(dut.ConfigContext),{prefixCls:r,type:i="default",danger:o,disabled:l,loading:s,onClick:c,htmlType:d,children:h,className:u,menu:p,arrow:f,autoFocus:m,overlay:v,trigger:g,align:w,open:y,onOpenChange:b,placement:x,getPopupContainer:E,href:k,icon:M=out.createElement(lut.default,null),title:S,buttonsRender:A=e=>e,mouseEnterDelay:_,mouseLeaveDelay:C,overlayClassName:Z,overlayStyle:H,destroyPopupOnHide:I,dropdownRender:D,...N}=e,O=n("dropdown",r),L=`${O}-button`,V={menu:p,arrow:f,autoFocus:m,align:w,disabled:l,trigger:l?[]:g,onOpenChange:b,getPopupContainer:E||t,mouseEnterDelay:_,mouseLeaveDelay:C,overlayClassName:Z,overlayStyle:H,destroyPopupOnHide:I,dropdownRender:D},{compactSize:z,compactItemClassnames:P}=(0,uut.useCompactItemContext)(O,a),T=(0,sut.default)(L,P,u);"overlay"in e&&(V.overlay=v),"open"in e&&(V.open=y),V.placement="placement"in e?x:"rtl"===a?"bottomLeft":"bottomRight";const B=out.createElement(cut.default,{type:i,danger:o,disabled:l,loading:s,onClick:c,htmlType:d,href:k,title:S},h),j=out.createElement(cut.default,{type:i,danger:o,icon:M}),[W,R]=A([B,j]);return out.createElement(hut.default.Compact,(0,iut.default)({className:T,size:z,block:!0},N),W,out.createElement(put.default,V,R))};mut.__ANT_BUTTON=!0,xot.default=mut;var vut=sqe.exports;Object.defineProperty(lqe,"__esModule",{value:!0});var gut=lqe.default=void 0,wut=vut(cqe),yut=vut(xot);const but=wut.default;but.Button=yut.default,gut=lqe.default=but;var xut=function(e){return e.handleModal,e.openModal,e.windowSize,e.viewId,f.default.createElement("div",null)},Eut=function(e){return S(void 0,[e],void 0,function(e){var t,n,a,r,i,o,l,s,c,d,h,u,p,f,m=e.stateId,v=e.group,g=e.setGroupColumns,w=e.setSettingTable;return A(this,function(e){switch(e.label){case 0:return m?(t=[{keyCode:"viewId",key:"viewId",ope:"==",value:m,predicate:";"}],[4,vi({ParaJson:JSON.stringify({Filter:JSON.stringify(t),Order:"",PageNumber:1,PageSize:200,ViewId:"sys_table_config_viewId",StateId:"sys_table_config_viewId"})})]):[3,2];case 1:n=e.sent(),a=null!==(l=null===(o=U(n))||void 0===o?void 0:o[0])&&void 0!==l?l:{},r=JSON.parse(Q(null==a?void 0:a.groupData)?"{}":null==a?void 0:a.groupData),(i={showGroupIcon:null===(s=null==r?void 0:r.showGroupIcon)||void 0===s||s,hiddenColumnGroup:null===(c=null==r?void 0:r.hiddenColumnGroup)||void 0===c||c,isGroup:null!==(h=null!==(d=null==v?void 0:v.groupAble)&&void 0!==d?d:null==r?void 0:r.isGroup)&&void 0!==h&&h,isGroupClient:null!==(u=null==r?void 0:r.isGroupClient)&&void 0!==u&&u}).isGroup?(null==v?void 0:v.groupColumns)||g(null!==(f=null===(p=JSON.parse(Q(null==r?void 0:r.tableGroup)?"[]":null==r?void 0:r.tableGroup))||void 0===p?void 0:p.map(function(e){return e.field}))&&void 0!==f?f:[]):g([]),w(i),e.label=2;case 2:return[2]}})})},kut=function(e){var t=localStorage.getItem("grid".concat(e)),n=t?JSON.parse(t):null;return{storageSearchTerm:null==n?void 0:n.searchSettings.key,storageQueryFilter:null==n?void 0:n.filterSettings.columns.map(function(e){return{key:e.fieldOriginal,keyCode:e.fieldOriginal,value:e.value,ope:xe[e.operator],predicate:Ee[e.predicate]}})}},Mut=window.localStorage.getItem("i18nextLng"),Sut=Mut||"vi",Aut=require("@public/assets/data/locales/".concat(Sut,".json")),_ut={ascend:"asc",descend:"desc",asc:"asc",desc:"desc"},Cut=function(e){return S(void 0,[e],void 0,function(e){var t,n,a,r,i,o,l,s,c,d,h,u,p,f=e.id,m=e.more,v=e.more1;return A(this,function(e){switch(e.label){case 0:return f&&K(null==v?void 0:v.dataSource)?(null==v||v.setIsLoading(!0),t=_([],null!==(c=null==v?void 0:v.querySelectDefault)&&void 0!==c?c:[],!0),null===(d=null==v?void 0:v.paramToolbar)||void 0===d||d.map(function(e){var n,a,r,i,o,l,s,c;"daterange"===e.type&&(null===(n=e.data)||void 0===n?void 0:n.length)>0?(t=t.filter(function(t){return t.key!==e.keyCode}),t.unshift({key:e.keyCode,value:X(e.data[0],">="),ope:">=",predicate:";"}),t.unshift({key:e.keyCode,value:X(e.data[1],"<="),ope:"<=",predicate:";"})):"listDate"===e.type&&(null===(r=null===(a=e.data)||void 0===a?void 0:a.type)||void 0===r?void 0:r.length)>0?(t=t.filter(function(t){return t.key!==e.keyCode}),t.unshift({key:e.keyCode,value:X(null===(o=null===(i=e.data)||void 0===i?void 0:i.type)||void 0===o?void 0:o[0],">="),ope:">=",predicate:";"}),t.unshift({key:e.keyCode,value:X(null===(s=null===(l=e.data)||void 0===l?void 0:l.type)||void 0===s?void 0:s[1],"<="),ope:"<=",predicate:";"})):"select"===e.type&&e.isMulti&&(null===(c=e.data)||void 0===c?void 0:c.length)>0?(t=t.filter(function(t){return t.key!==e.keyCode}),e.data.forEach(function(n){t.unshift({key:e.keyCode,value:n,ope:"==",predicate:";"})})):"select"!==e.type||e.isMulti||K(e.data)||(t=t.filter(function(t){return t.key!==e.keyCode}),t.unshift({key:e.keyCode,value:e.data,ope:"==",predicate:";"}))}),(null==m?void 0:m.queryGroup)&&Array.isArray(null==m?void 0:m.queryGroup)&&(null===(h=null==m?void 0:m.queryGroup)||void 0===h?void 0:h.length)>0&&(n=m.queryGroup.map(function(e){return e.key}),t=t.filter(function(e){return!n.some(function(t){return t===e.key})}),t=_(_([],t,!0),m.queryGroup,!0)),a=_(_([],null==v?void 0:v.queryFilter,!0),t,!0).filter(function(e){return!K(e.value)&&""!==e.value}).map(function(e){return{keyCode:e.key,value:e.value,ope:e.ope,predicate:e.predicate}}),r=null===(u=null==v?void 0:v.queryOrder)||void 0===u?void 0:u.map(function(e){return"".concat(e.field,",").concat(_ut[e.order])}).join(";"),i={ParaJson:JSON.stringify({Filter:JSON.stringify(a),Order:r,PageNumber:null==v?void 0:v.currentPage,PageSize:null==v?void 0:v.rowsPerPage,Keyword:null==v?void 0:v.searchTerm,ViewId:f,StateId:f,FieldGroup:null!==(p=null==m?void 0:m.fieldGroup)&&void 0!==p?p:void 0,LastLevel:(null==m?void 0:m.lastLevel)?1:void 0}),HasWorkflow:null==v?void 0:v.hasWorkflow},Q(null==v?void 0:v.productCode)||(i=k(k({},i),{ParaView:JSON.stringify({ProductCode:null==v?void 0:v.productCode,Code:null==v?void 0:v.stateId,OrganizationId:j(),ViewId:f}),IsGetView:!0})),[4,vi(i).then(function(e){return e}).catch(function(e){return e})]):[3,2];case 1:if(null==(o=e.sent())?void 0:o.errorMessage)return sYe(null==o?void 0:o.errorMessage),null==v||v.setIsLoading(!1),null==v||v.setDataView({Data:[],Total:0}),[2];l=function(){var e,t,n,a,r,i,l,s,c,d,h;if(K(m)||m&&m.lastLevel){var u=JSON.parse(null!==(t=null===(e=null==o?void 0:o[0])||void 0===e?void 0:e.dataJson)&&void 0!==t?t:"[]"),p=JSON.parse(null!==(a=null===(n=null==o?void 0:o[0])||void 0===n?void 0:n.workflow)&&void 0!==a?a:"[]");"01"!==(null===(r=null==o?void 0:o[0])||void 0===r?void 0:r.status)&&sYe("Lấy dữ liệu không thành công!! StateId: ".concat(f));var g={Data:null===(s=JSON.parse(null!==(l=null===(i=null==u?void 0:u[0])||void 0===i?void 0:i.Data)&&void 0!==l?l:"[]"))||void 0===s?void 0:s.map(function(e,t){var n,a,r,i;if(null==v?void 0:v.hasWorkflow){var o=null==p?void 0:p[null===(n=e.id)||void 0===n?void 0:n.toLowerCase()];e.currentProcessCode=null==o?void 0:o.WorkflowStateCode,e.currentProcess=null!==(a=null==o?void 0:o.ProcessStatus)&&void 0!==a?a:"",e.approverId=null==o?void 0:o.ApproverId,e.approver=null==o?void 0:o.ApproverName,e.deadlineStatus=null==o?void 0:o.DeadlineStatus,e.timeLeft=null==o?void 0:o.TimeLeft,e.durationUnit=null==o?void 0:o.DurationUnit,e.hasPermissionApprove=null!==(i=null===(r=null==o?void 0:o.ApproverId)||void 0===r?void 0:r.includes(null!=T?T:""))&&void 0!==i&&i,e.numberOfComments=null==o?void 0:o.NumberOfComments}return e.STT=t+1,e.children=1!==(null==e?void 0:e.isGroupServer)||(null==m?void 0:m.lastLevel)?void 0:[],e}),Total:null!==(d=null===(c=null==u?void 0:u[0])||void 0===c?void 0:c.Total)&&void 0!==d?d:0};return K(m)?g:(G(null==v?void 0:v.dataView.Data,"id",null==m?void 0:m.id).children=g.Data,null==v?void 0:v.dataView)}return m&&!m.lastLevel?(G(null==v?void 0:v.dataView.Data,"id",null==m?void 0:m.id).children=null===(h=U(o))||void 0===h?void 0:h.map(function(e){return k(k({},e),{children:1===(null==e?void 0:e.isGroupServer)?[]:void 0})}),null==v?void 0:v.dataView):{Data:[],Total:0}},s=l(),setTimeout(function(){(null==v?void 0:v.callback)&&(null==v||v.callback({total:s.Total})),null==v||v.setIsLoading(!1),null==v||v.setDataView(k({},s))},150),e.label=2;case 2:return[2]}})})},Zut=function(a){var r,i,o,l,s,c,d,h,u,p,m,v,g,w,y,b,x,E,M,C,Z=a.toolbarTemplate,H=a.paramToolbar,I=a.currentPageDefault,D=a.queryOrderDefault,N=a.rowsPerPageDefault,O=a.queryKeyDataView,L=a.isSelectMulti,V=a.canContextMenuItems,z=a.handleContextMenuClick,P=a.rowSelected,T=a.dataSourceFilter,W=a.listContextHide,R=a.querySelectDefault,F=a.t,Y=a.contextMenuOpen,J=a.stateId,ne=a.viewIdTable,ae=a.height,re=a.hasIndex,ie=a.dataSelected,oe=a.showColumnChoose,le=a.typeCheckbox,se=a.format,ce=a.rowSelection,de=a.dataSource,he=a.columns,ue=a.totalCount,pe=a.breakText,fe=a.pageSizeOptions,me=a.handleDoubleContextMenuClick,ve=a.allowResizing,ge=a.summary,we=a.hasWorkflow,ye=a.apiWorkflow,be=a.allowFilterClient,ke=a.rowClassName,Me=a.showToolbar,Se=a.allowPaging,Ae=a.checkInit,_e=a.checkInitSub,Ce=a.printApi,Ze=a.showUltilities,He=a.ultilities,Ie=a.onChangeParam,De=a.initAbility,Ne=a.stateChildId,Oe=a.onDataChange,Le=a.group,Ve=process.env.REACT_APP_PRODUCT_CODE,ze=null==Ze||Ze,Pe=kut(J),Te=Pe.storageSearchTerm,Be=Pe.storageQueryFilter,je=localStorage.getItem("sub"),We="".concat(je,"_").concat(window.location.pathname),Re=e.useState(null==B?void 0:B[We]),Fe=Re[0],Ye=Re[1],qe=window.localStorage.getItem("i18nextLng"),Ue=qe||"vi",Ge=require("@public/assets/data/locales/".concat(Ue,".json")),Ke=e.useState(""),Qe=Ke[0],Xe=Ke[1],Je=e.useState({}),$e=Je[0],et=Je[1],tt=e.useState(!1),nt=tt[0],at=tt[1],rt=e.useState({Data:[],Total:0}),it=rt[0],ot=rt[1],lt=e.useState(null!=I?I:1),st=lt[0],ct=lt[1],dt=e.useState(null!=N?N:200),ht=dt[0],ut=dt[1],pt=e.useState(null!=Te?Te:""),ft=pt[0],mt=pt[1],vt=e.useState(null!=D?D:[]),gt=vt[0],wt=vt[1],yt=e.useState(null!=Be?Be:[]),bt=yt[0],xt=yt[1],Et=e.useState([]),kt=Et[0],Mt=Et[1],St=e.useState([]),At=St[0],_t=St[1],Ct=e.useState(!0),Zt=Ct[0],Ht=Ct[1],It=Array.isArray(ie)?ie:K(ie)||$(ie)?[]:[ie],Dt=e.useState(It),Nt=Dt[0],Ot=Dt[1],Lt=e.useState(null!==(r=null==Le?void 0:Le.groupColumns)&&void 0!==r?r:[]),Vt=Lt[0],zt=Lt[1],Pt=e.useState({}),Tt=Pt[0],Bt=Pt[1],jt=e.useState(!1),Wt=jt[0],Rt=jt[1],Ft=function(){Rt(!Wt)},Yt=e.useState(!1),qt=Yt[0],Ut=Yt[1],Gt=e.useState("Edit"),Kt=Gt[0],Qt=Gt[1],Xt=function(){Ut(!qt)},Jt=function(){return{innerWidth:window.innerWidth,innerHeight:window.innerHeight}},$t=e.useState(Jt()),en=$t[0],tn=$t[1];e.useEffect(function(){var e=function(){tn(Jt())};return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}},[]),e.useEffect(function(){K(he)&&S(void 0,void 0,void 0,function(){var e,t,n,a;return A(this,function(r){switch(r.label){case 0:return J?(e=[{keyCode:"parentView",key:"parentView",ope:"==",value:J,predicate:";"}],[4,vi({ParaJson:JSON.stringify({Filter:JSON.stringify(e),Order:"",PageNumber:1,PageSize:200,ViewId:"sys_table_config_viewId",StateId:"sys_table_config_viewId"}),ParaView:JSON.stringify({ProductCode:Ve,Code:J,OrganizationId:j()})})]):[3,2];case 1:t=r.sent(),Mt(null!==(a=null===(n=t&&Array.isArray(t)?t:[])||void 0===n?void 0:n.map(function(e){var t;return k(k({},e),{viewId:e.code,viewName:e.name,value:e.code,key:e.code,label:null!==(t=e.name)&&void 0!==t?t:e.code})}))&&void 0!==a?a:[]),r.label=2;case 2:return[2]}})})},[Zt]),e.useEffect(function(){Eut({stateId:J,group:Le,setGroupColumns:zt,setSettingTable:Bt})},[]);var nn,an=q(ft,500);e.useEffect(function(){clearTimeout(nn),nn=setTimeout(function(){Cut({id:null!=Fe?Fe:J,more1:{columns:he,currentPage:st,dataSource:de,dataView:it,hasWorkflow:we,paramToolbar:H,productCode:Ve,queryFilter:bt,queryOrder:gt,querySelectDefault:R,rowsPerPage:ht,searchTerm:ft,setDataView:ot,setIsLoading:at,stateId:J}}),Ie&&Ie({keyword:an,pageNumber:st,pageSize:ht,queryFilter:bt,queryOrder:gt})},200)},_(_([an,st,bt,gt,ht,ne,J],null!=O?O:[],!0),[Fe],!1)),e.useEffect(function(){var e,t;(null==kt?void 0:kt.length)>0&&!kt.some(function(e){var t,n;return e.viewId===(null===(n=JSON.parse(null!==(t=localStorage.getItem("screenView"))&&void 0!==t?t:"{}"))||void 0===n?void 0:n[We])})&&(Ye(J),localStorage.setItem("screenView",JSON.stringify(k(k({},B),((e={})[We]=J,e))))),(K(kt)||0===kt.length)&&(Ye(J),localStorage.setItem("screenView",JSON.stringify(k(k({},B),((t={})[We]=J,t)))))},[Zt,kt]);var rn=function(e){!K(e)&&(ee(e)&&0===e||te(e)&&e)&&(clearTimeout(nn),nn=setTimeout(function(){Cut({id:null!=Fe?Fe:J,more1:{columns:he,currentPage:st,dataSource:de,dataView:it,hasWorkflow:we,paramToolbar:H,productCode:Ve,queryFilter:bt,queryOrder:gt,querySelectDefault:R,rowsPerPage:ht,searchTerm:ft,setDataView:ot,setIsLoading:at,stateId:J}})},200))};e.useEffect(function(){rn(Ae)},[Ae]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit1)},[null==_e?void 0:_e.checkInit1]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit2)},[null==_e?void 0:_e.checkInit2]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit3)},[null==_e?void 0:_e.checkInit3]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit4)},[null==_e?void 0:_e.checkInit4]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit5)},[null==_e?void 0:_e.checkInit5]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit6)},[null==_e?void 0:_e.checkInit6]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit7)},[null==_e?void 0:_e.checkInit7]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit8)},[null==_e?void 0:_e.checkInit8]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit9)},[null==_e?void 0:_e.checkInit9]),e.useEffect(function(){rn(null==_e?void 0:_e.checkInit10)},[null==_e?void 0:_e.checkInit10]),e.useEffect(function(){Oe&&Oe(it.Data,function(e){return ot(function(t){return k(k({},t),{Data:e})})})},[it.Data]);var on=e.useState([]),ln=on[0],sn=on[1],cn=function(e){return S(void 0,void 0,void 0,function(){var t;return A(this,function(n){switch(n.label){case 0:return[4,mi({ParaJson:JSON.stringify({ViewId:e})})];case 1:return t=n.sent(),sn(null!=t?t:[]),[2]}})})};e.useEffect(function(){var e;if(null===(e=null==ln?void 0:ln[0])||void 0===e?void 0:e.dataJson){var t=yi(ln,F,{hasIndex:null==re||re,breakText:pe,hasWorkflow:we,levelGroup:Vt.length});_t(t)}},[ln,Vt]),e.useEffect(function(){Fe&&K(he)&&cn(null!=Fe?Fe:ne)},[Fe]);var dn=e.useState(!1),hn=dn[0],un=dn[1],pn=function(){un(!hn)},fn=e.useState(!1),mn=fn[0],vn=fn[1],gn=function(){vn(!mn)},wn=e.useState(),yn=wn[0],bn=wn[1],xn=null==De?void 0:De.can("ADD_VIEW",J),En=null==De?void 0:De.can("EDIT_VIEW",J),kn=null==De?void 0:De.can("DELETE_VIEW",J),Mn=null==De?void 0:De.can("OPEN","PermissionViewFunction"),Sn=_([],null==kt?void 0:kt.map(function(e,t){return{key:"2-2-".concat(t.toString()),label:f.default.createElement("span",{className:"".concat(Fe===e.viewId?"menuitem-child-selected":"")},e.label),onClick:function(){var t;cn(e.viewId),Cut(e.viewId),Ye(e.viewId),localStorage.setItem("screenView",JSON.stringify(k(k({},B),((t={})[We]=e.viewId,t))))}}}),!0),An=[{key:"31",type:"group",label:f.default.createElement("div",{style:{color:"#000000",fontWeight:500}},"Tiện ích"),children:[{key:"1-1",type:"item",label:F("ExportExcel"),onClick:function(){return gn()},className:!1===(null==He?void 0:He.showExport)?"custom-hidden":""},{key:"1-2",type:"item",label:F("Print"),onClick:function(){return function(){if(!$(null==Nt?void 0:Nt[0])&&Ne&&(null==Ne?void 0:Ne.length)>0){var e=Ne[0],t=null==e?void 0:e.querySelectDefault;vi({ParaJson:JSON.stringify({Filter:JSON.stringify(t),Order:"",PageNumber:1,PageSize:1e3,Keyword:"",ViewId:e.stateId,StateId:e.stateId})}).then(function(e){var t=U(e);bn(k(k({},ie),{detail:t})),pn()}).catch(function(){return sYe("".concat(F("getDataError")))})}}()},disabled:Q(null===(i=null==Nt?void 0:Nt[0])||void 0===i?void 0:i.id),className:!1===(null==He?void 0:He.showPrint)?"custom-hidden":""}].filter(function(e){var t;return!(null===(t=null==e?void 0:e.className)||void 0===t?void 0:t.includes("custom-hidden"))})}],_n=[{key:"1",type:"group",label:f.default.createElement("div",{style:{color:"#000000",fontWeight:500}},"Danh sách View"),children:Sn},{type:"divider"},{key:"2",type:"group",label:f.default.createElement("div",{style:{color:"#000000",fontWeight:500}},"View"),children:[!0===xn&&!0===En&&!0===kn&&{key:"2-1",label:"Cài đặt View",className:!1===(null==He?void 0:He.showSetting)?"custom-hidden":"",children:[(!0===xn||!0===En)&&{key:"2-1-1",label:F("Thêm - Sửa View"),onClick:function(){Xt(),Qt("Edit")}},!0===kn&&{key:"2-1-2",label:F("Xóa View"),onClick:function(){Xt(),Qt("Del")}}].filter(Boolean)},!0===Mn&&{key:"2-3",label:"Phân quyền View",className:!1===(null==He?void 0:He.showSetting)?"custom-hidden":"",onClick:function(){Ft()}}].filter(function(e){var t;return!(null===(t=null==e?void 0:e.className)||void 0===t?void 0:t.includes("custom-hidden"))})}],Cn=ze?[{template:f.default.createElement("div",{title:"Danh sách View"},f.default.createElement(gut,{menu:{items:_n},className:"me-0",trigger:["click"]},f.default.createElement(Qr,{fontSize:20,color:"#000000",className:"ms-50"}))),position:"Top",align:"right"},{template:f.default.createElement("div",{title:"Tiện ích"},f.default.createElement(gut,{menu:{items:An},className:"me-0",trigger:["click"]},f.default.createElement(ei,{fontSize:20,color:"#000000",className:"ms-50"}))),position:"Top",align:"right"}]:[];return f.default.createElement("div",{className:"App"},f.default.createElement("div",{style:{padding:"0rem"}},f.default.createElement(t.GridComponent,{id:J,key:J,sortMultiple:!0,loading:nt,lang:Ue,locale:null===(o=null==Ge?void 0:Ge.gridTable)||void 0===o?void 0:o.table,showToolbar:Me,columns:null!==(l=null!=he?he:At)&&void 0!==l?l:[],dataSource:null!==(s=null!=de?de:null==it?void 0:it.Data)&&void 0!==s?s:[],height:ae,groupAble:null!==(c=null==Tt?void 0:Tt.isGroup)&&void 0!==c&&c,groupColumns:(null==Tt?void 0:Tt.isGroup)?Vt:[],groupSetting:(null==Tt?void 0:Tt.isGroup)?{client:null!==(d=null==Tt?void 0:Tt.isGroupClient)&&void 0!==d&&d,hiddenColumnGroup:null!==(p=null!==(u=null===(h=null==Le?void 0:Le.groupSetting)||void 0===h?void 0:h.hiddenColumnGroup)&&void 0!==u?u:null==Tt?void 0:Tt.hiddenColumnGroup)&&void 0!==p&&p,onGroup:function(e){var t;zt(null!==(t=null==e?void 0:e.columnGrouped)&&void 0!==t?t:[])},showGroupIcon:null===(g=null!==(v=null===(m=null==Le?void 0:Le.groupSetting)||void 0===m?void 0:m.showGroupIcon)&&void 0!==v?v:null==Tt?void 0:Tt.showGroupIcon)||void 0===g||g,unClearableLevel:null===(w=null==Le?void 0:Le.groupSetting)||void 0===w?void 0:w.unClearableLevel}:{},expandable:{expandIconColumnIndex:0},onExpandClick:function(e){var t,n=e.rowData;e.expandedKeys;var a=e.key,r=Vt.findIndex(function(e){return e===(null==n?void 0:n.field)}),i=Vt[r+1];Cut({id:null!=Fe?Fe:J,more1:{columns:he,currentPage:st,dataSource:de,dataView:it,hasWorkflow:we,paramToolbar:H,productCode:Ve,queryFilter:bt,queryOrder:gt,querySelectDefault:R,rowsPerPage:ht,searchTerm:ft,setDataView:ot,setIsLoading:at,stateId:J},more:{queryGroup:[{key:null==n?void 0:n.field,ope:"==",value:null!==(t=null==n?void 0:n[null==n?void 0:n.field])&&void 0!==t?t:"",predicate:";"}],fieldGroup:K(i)?"":"[".concat(i,"]"),lastLevel:K(i),id:a}})},pagination:!1!==Se&&{total:null!==(y=null!=ue?ue:null==it?void 0:it.Total)&&void 0!==y?y:0,pageSize:ht,pageSizeOptions:null!=fe?fe:[20,50,100,200,500,1e3],onChange:function(e,t){ct(e),ut(t)},locale:null===(b=null==Ge?void 0:Ge.gridTable)||void 0===b?void 0:b.pager,showTotal:function(e,t){var n,a,r;return"".concat(t[0],"-").concat(t[1]," / ").concat(e," ").concat(F?F(null!==(r=null===(a=null===(n=null==Ge?void 0:Ge.gridTable)||void 0===n?void 0:n.pager)||void 0===a?void 0:a.items)&&void 0!==r?r:"items"):"items")}},toolbarItems:_(_([{template:f.default.createElement(us,{callback:function(e){mt(null!=e?e:"")},width:250,placeholder:F("Search"),isChangeValueOnEnter:!0}),position:"left"}],null!=Z?Z:[],!0),Cn,!0),recordDoubleClick:function(e){me&&me(e)},format:null!=se?se:{thousandSeparator:",",decimalSeparator:".",decimalScale:2},allowResizing:null==ve||ve,summary:ge,rowClassName:ke,showColumnChoose:null==oe||oe,contextMenuItems:V,contextMenuClick:function(e){z&&(z(e),function(e){var t,a=null===(t=e.rowInfo)||void 0===t?void 0:t.rowData;a&&(et(a),"VIEW_COMMENT"===e.item.id?Xe("comment"):"VIEW_PROCESS"===e.item.id?Xe("diagram"):"APPROVE_PROCESS"===e.item.id?Xe("approve"):"RESET_PROCESS"===e.item.id&&(null==ye?void 0:ye.checkInitProcess)&&n.messageBoxConfirmResetWorkflow(F,null==ye?void 0:ye.initProcessApi,a,J,function(){(null==ye?void 0:ye.handleOnReset)&&(null==ye||ye.handleOnReset(a))}))}(e))},contextMenuOpen:Y,contextMenuHidden:null!==(x=null==W?void 0:W.list)&&void 0!==x?x:[],rowSelected:function(e){P&&P(e),Ot(e.selected)},onFilter:!0===be?void 0:function(e){var t,n=null!==(t=null==e?void 0:e.map(function(e){(null!=he?he:At).some(function(t){return t.field===e.field&&("date"===t.type||"datetime"===t.type)})&&(e.value=X(e.value,xe[e.operator]));var t=G(null!=he?he:At,"field",e.field);return{key:t.fieldOriginal,keyCode:t.fieldOriginal,value:e.value,ope:xe[e.operator],predicate:Ee[e.predicate]}}))&&void 0!==t?t:[];xt(n)},onSorter:function(e){Array.isArray(e)?wt(e):K(null==e?void 0:e.field)?wt([]):wt([e])},selectionSettings:{type:L?"multiple":"single",mode:null!=le?le:void 0,columnWidth:50,hideSelectAll:!1,defaultSelectedRowKeys:null!==(M=null===(E=null==It?void 0:It.map(function(e){var t;return null!==(t=null==e?void 0:e.rowId)&&void 0!==t?t:null==e?void 0:e.id}))||void 0===E?void 0:E.filter(function(e){return!Q(e)}))&&void 0!==M?M:[]},editAble:!1,rowSelection:ce,t:F,dataSourceFilter:T,onFilterClick:function(e,t){var n=[{value:"equal",label:F("Equal"),key:"=="},{value:"greaterthan",label:F("Greater than"),key:">"},{value:"greaterthanorequal",label:F("Greater Than Or Equal"),key:">="},{value:"lessthan",label:F("Less Than"),key:"<"},{value:"lessthanorequal",label:F("Less Than Or Equal"),key:"<="},{value:"notequal",label:F("Not Equal"),key:"!="}];"building"===e.key&&t(e.key,n)}})),f.default.createElement(xut,{viewId:J,windowSize:en,openModal:Wt,handleModal:Ft}),f.default.createElement(iqe,{handleModalOrder:Xt,openModalOrder:qt,typeModal:null!=Kt?Kt:"Edit",windowSize:en,viewId:J,setLoadView:Ht,initAbility:De}),ze&&f.default.createElement(rX,{t:F,openModal:hn,handleModal:pn,data:yn,defaultPrintSetting:null!==(C=null==Ce?void 0:Ce.defaultPrintSetting)&&void 0!==C?C:li,getListGeneralSettingApi:null==Ce?void 0:Ce.getListGeneralSettingApi,deleteGeneralSettingApi:null==Ce?void 0:Ce.deleteGeneralSettingApi,updateGeneralSettingApi:null==Ce?void 0:Ce.updateGeneralSettingApi,printDocumentApi:null==Ce?void 0:Ce.printDocumentApi,CDN_URL_VIEW:ui||"",DOCUMENT_URL_VIEW:"".concat(si,"/api/generalsetting/document"),uploadFileApi:null==Ce?void 0:Ce.uploadFileApi}),ze&&f.default.createElement(Qye,{stateid:J,openModal:mn,dataItem:function(){var e=_([],null!=R?R:[],!0);null==H||H.map(function(t){var n,a,r,i,o,l,s,c;"daterange"===t.type&&(null===(n=t.data)||void 0===n?void 0:n.length)>0?(e.unshift({key:t.keyCode,value:X(t.data[0],">="),ope:">=",predicate:";"}),e.unshift({key:t.keyCode,value:X(t.data[1],"<="),ope:"<=",predicate:";"})):"listDate"===t.type&&(null===(r=null===(a=t.data)||void 0===a?void 0:a.type)||void 0===r?void 0:r.length)>0?(e.unshift({key:t.keyCode,value:X(null===(o=null===(i=t.data)||void 0===i?void 0:i.type)||void 0===o?void 0:o[0],">="),ope:">=",predicate:";"}),e.unshift({key:t.keyCode,value:X(null===(s=null===(l=t.data)||void 0===l?void 0:l.type)||void 0===s?void 0:s[1],"<="),ope:"<=",predicate:";"})):"select"===t.type&&t.isMulti&&(null===(c=t.data)||void 0===c?void 0:c.length)>0?t.data.forEach(function(n){e.unshift({key:t.keyCode,value:n,ope:"==",predicate:";"})}):"select"!==t.type||t.isMulti||K(t.data)||e.unshift({key:t.keyCode,value:t.data,ope:"==",predicate:";"})});var t=_(_([],bt,!0),e,!0).filter(function(e){return!K(e.value)&&""!==e.value}).map(function(e){return{keyCode:e.key,value:e.value,ope:e.ope,predicate:e.predicate}}),n=null==gt?void 0:gt.map(function(e){return"".concat(e.field,",").concat(_ut[e.order])}).join(";");return{Filter:JSON.stringify(t),Order:n,PageNumber:st,PageSize:ht,Keyword:ft,ViewId:ne,StateId:J}},handleModal:gn,typeModal:"",windowSize:en,columns:At}),f.default.createElement(n.WorkflowModal,{type:Qe,setType:Xe,data:$e,listData:[],t:F,checkInitProcess:null==ye?void 0:ye.checkInitProcess,getProcessApi:null==ye?void 0:ye.getProcessApi,approveProcessApi:null==ye?void 0:ye.approveProcessApi,approveMultiProcessApi:null==ye?void 0:ye.approveMultiProcessApi,checkInitComment:null==ye?void 0:ye.checkInitComment,getCommentPagingApi:null==ye?void 0:ye.getCommentPagingApi,addCommentApi:null==ye?void 0:ye.addCommentApi,deleteCommentApi:null==ye?void 0:ye.deleteCommentApi,pagingUserApi:null==ye?void 0:ye.getUserCorePagingApi,uploadFileApi:null==ye?void 0:ye.uploadFileApi,CDN_URL_VIEW:ui||"",token:pi()||"",saveUrl:"".concat(si,"/api/file/upload-mutil"),approverId:null==ye?void 0:ye.approverId,approverName:null==ye?void 0:ye.approverName,onApproveCompleted:null==ye?void 0:ye.onApproveCompleted,pagingEmployeeApi:null==ye?void 0:ye.pagingEmployeeApi}))},Hut=function(e){var n,a,r,i,o,l,s,c,d,h,u,p,m,v,g,w,y,b=e.toolbarTemplate,x=e.isLoading,E=e.lang,k=e.localeLanguage,M=e.headerColumns,S=e.dataView,A=e.isSelectMulti,C=e.canContextMenuItems,Z=e.handleContextMenuClick,H=e.rowSelected,I=e.dataSourceFilter,D=e.listContextHide,N=e.setGroupColumns,O=e.t,L=e.contextMenuOpen,V=e.stateId,z=e.groupColumns,P=e.height,T=e.settingTable,B=e.rowsPerPage,j=e.showColumnChoose,W=e.typeCheckbox,R=e.format,F=e.rowSelection,Y=e.dataSource,q=e.columns,U=e.totalCount,G=e.setCurrentPage,J=e.pageSizeOptions,$=e.handleDoubleContextMenuClick,ee=e.allowResizing,te=e.summary,ne=e.searchInput,ae=e.allowFilterClient,re=e.setRowsPerPage,ie=e.rowClassName,oe=e.showToolbar,le=e.allowPaging,se=e.setQueryFilter,ce=e.setQueryOrder,de=e.selected,he=e.group;return f.default.createElement("div",{style:{padding:"0rem"}},f.default.createElement(t.GridComponent,{key:V,sortMultiple:!0,loading:x,lang:E,locale:null===(n=null==k?void 0:k.gridTable)||void 0===n?void 0:n.table,showToolbar:oe,columns:null!==(a=null!=q?q:M)&&void 0!==a?a:[],dataSource:null!==(r=null!=Y?Y:null==S?void 0:S.Data)&&void 0!==r?r:[],height:P,groupAble:null!==(i=null==T?void 0:T.isGroup)&&void 0!==i&&i,groupColumns:(null==T?void 0:T.isGroup)?z:[],groupSetting:(null==T?void 0:T.isGroup)?{client:null!==(o=null==T?void 0:T.isGroupClient)&&void 0!==o&&o,hiddenColumnGroup:null!==(c=null!==(s=null===(l=null==he?void 0:he.groupSetting)||void 0===l?void 0:l.hiddenColumnGroup)&&void 0!==s?s:null==T?void 0:T.hiddenColumnGroup)&&void 0!==c&&c,onGroup:function(e){var t;N(null!==(t=null==e?void 0:e.columnGrouped)&&void 0!==t?t:[])},showGroupIcon:null===(u=null!==(h=null===(d=null==he?void 0:he.groupSetting)||void 0===d?void 0:d.showGroupIcon)&&void 0!==h?h:null==T?void 0:T.showGroupIcon)||void 0===u||u,unClearableLevel:null===(p=null==he?void 0:he.groupSetting)||void 0===p?void 0:p.unClearableLevel}:{},expandable:{expandIconColumnIndex:0},onExpandClick:function(){},pagination:!1!==le&&{total:null!==(m=null!=U?U:null==S?void 0:S.Total)&&void 0!==m?m:0,pageSize:B,pageSizeOptions:null!=J?J:[20,50,100,200,500,1e3],onChange:function(e,t){G(e),re(t)},locale:null===(v=null==k?void 0:k.gridTable)||void 0===v?void 0:v.pager,showTotal:function(e,t){var n,a,r;return"".concat(t[0],"-").concat(t[1]," / ").concat(e," ").concat(O?O(null!==(r=null===(a=null===(n=null==k?void 0:k.gridTable)||void 0===n?void 0:n.pager)||void 0===a?void 0:a.items)&&void 0!==r?r:"items"):"items")}},toolbarItems:_([ne()],null!=b?b:[],!0),recordDoubleClick:function(e){$&&$(e)},format:null!=R?R:{thousandSeparator:",",decimalSeparator:".",decimalScale:2},allowResizing:null==ee||ee,summary:te,rowClassName:ie,showColumnChoose:null==j||j,contextMenuItems:C,contextMenuClick:function(e){Z&&Z(e)},contextMenuOpen:L,contextMenuHidden:null!==(g=null==D?void 0:D.list)&&void 0!==g?g:[],rowSelected:function(e){H&&H(e)},onFilter:!0===ae?void 0:function(e){var t,n=null!==(t=null==e?void 0:e.map(function(e){return(null!=q?q:M).some(function(t){return t.field===e.field&&("date"===t.type||"datetime"===t.type)})&&(e.value=X(e.value,xe[e.operator])),{key:e.field,keyCode:e.field,value:e.value,ope:xe[e.operator],predicate:Ee[e.predicate]}}))&&void 0!==t?t:[];se(n)},onSorter:function(e){Array.isArray(e)?ce(e):K(null==e?void 0:e.field)?ce([]):ce([e])},selectionSettings:{type:A?"multiple":"single",mode:null!=W?W:void 0,columnWidth:50,hideSelectAll:!1,defaultSelectedRowKeys:null!==(y=null===(w=null==de?void 0:de.map(function(e){var t;return null!==(t=null==e?void 0:e.rowId)&&void 0!==t?t:null==e?void 0:e.id}))||void 0===w?void 0:w.filter(function(e){return!Q(e)}))&&void 0!==y?y:[]},showEmptyText:!1,editAble:!1,rowSelection:F,t:O,dataSourceFilter:I,onFilterClick:function(e,t){var n=[{value:"equal",label:O("Equal"),key:"=="},{value:"greaterthan",label:O("Greater than"),key:">"},{value:"greaterthanorequal",label:O("Greater Than Or Equal"),key:">="},{value:"lessthan",label:O("Less Than"),key:"<"},{value:"lessthanorequal",label:O("Less Than Or Equal"),key:"<="},{value:"notequal",label:O("Not Equal"),key:"!="}];"building"===e.key&&t(e.key,n)}}))},Iut=function(t){var n,a=t.toolbarTemplate,r=t.paramToolbar,i=t.currentPageDefault,o=t.queryOrderDefault,l=t.rowsPerPageDefault,s=t.queryKeyDataView,c=t.isSelectMulti,d=t.canContextMenuItems,h=t.handleContextMenuClick,u=t.rowSelected,p=t.dataSourceFilter,m=t.listContextHide,v=t.querySelectDefault,g=t.t,w=t.contextMenuOpen,y=t.stateId,b=t.viewIdTable,x=t.height,E=t.dataSelected,M=t.showColumnChoose,S=t.typeCheckbox,A=t.format,C=t.rowSelection,Z=t.dataSource,H=t.columns,I=t.totalCount,D=t.pageSizeOptions,N=t.handleDoubleContextMenuClick,O=t.allowResizing,L=t.summary,V=t.allowFilterClient,z=t.index,P=t.rowClassName,T=t.showToolbar,B=t.allowPaging,j=t.checkInit,W=t.checkInitSub,R=t.callback,F=t.onDataChange,Y=t.group,U=t.windowSize,G=t.stateChildId,Q=t.titleChild,X=e.useState(!1),J=X[0],ne=X[1],ae=function(){ne(!J)},re=kut(y),ie=re.storageSearchTerm,oe=re.storageQueryFilter,le=e.useState(!1),se=le[0],ce=le[1],de=e.useState({Data:[],Total:0}),he=de[0],ue=de[1],pe=e.useState(null!=i?i:1),fe=pe[0],me=pe[1],ve=e.useState(null!=l?l:200),ge=ve[0],we=ve[1],ye=e.useState(null!=ie?ie:""),be=ye[0],xe=ye[1],Ee=e.useState(null!=o?o:[]),ke=Ee[0],Me=Ee[1],Se=e.useState(null!=oe?oe:[]),Ae=Se[0],_e=Se[1],Ce=Array.isArray(E)?E:K(E)||$(E)?[]:[E],Ze=e.useState([]),He=Ze[0],Ie=Ze[1],De=e.useState({}),Ne=De[0],Oe=De[1];e.useEffect(function(){Eut({stateId:y,group:Y,setGroupColumns:Ie,setSettingTable:Oe})},[]);var Le,Ve=q(be,500);e.useEffect(function(){clearTimeout(Le),Le=setTimeout(function(){Cut({id:y,more1:{columns:H,currentPage:fe,dataSource:Z,dataView:he,hasWorkflow:!1,paramToolbar:r,productCode:"",queryFilter:Ae,queryOrder:ke,querySelectDefault:v,rowsPerPage:ge,searchTerm:be,setDataView:ue,setIsLoading:ce,stateId:y,callback:R}})},200)},_([Ve,fe,Ae,ke,ge,b,y],null!=s?s:[],!0));var ze=function(e){!K(e)&&(ee(e)&&0===e||te(e)&&e)&&(clearTimeout(Le),Le=setTimeout(function(){Cut({id:y,more1:{columns:H,currentPage:fe,dataSource:Z,dataView:he,hasWorkflow:!1,paramToolbar:r,productCode:"",queryFilter:Ae,queryOrder:ke,querySelectDefault:v,rowsPerPage:ge,searchTerm:be,setDataView:ue,setIsLoading:ce,stateId:y,callback:R}})},200))};e.useEffect(function(){ze(j)},[j]),e.useEffect(function(){ze(null==W?void 0:W.checkInit1)},[null==W?void 0:W.checkInit1]),e.useEffect(function(){ze(null==W?void 0:W.checkInit2)},[null==W?void 0:W.checkInit2]),e.useEffect(function(){ze(null==W?void 0:W.checkInit3)},[null==W?void 0:W.checkInit3]),e.useEffect(function(){ze(null==W?void 0:W.checkInit4)},[null==W?void 0:W.checkInit4]),e.useEffect(function(){ze(null==W?void 0:W.checkInit5)},[null==W?void 0:W.checkInit5]),e.useEffect(function(){ze(null==W?void 0:W.checkInit6)},[null==W?void 0:W.checkInit6]),e.useEffect(function(){ze(null==W?void 0:W.checkInit7)},[null==W?void 0:W.checkInit7]),e.useEffect(function(){ze(null==W?void 0:W.checkInit8)},[null==W?void 0:W.checkInit8]),e.useEffect(function(){ze(null==W?void 0:W.checkInit9)},[null==W?void 0:W.checkInit9]),e.useEffect(function(){ze(null==W?void 0:W.checkInit10)},[null==W?void 0:W.checkInit10]),e.useEffect(function(){F&&F(he.Data,function(e){return ue(function(t){return k(k({},t),{Data:e})})})},[he.Data]);var Pe=function(){return{template:f.default.createElement(us,{callback:function(e){xe(null!=e?e:"")},width:250,placeholder:g("Search"),isChangeValueOnEnter:!0}),position:"left"}};return f.default.createElement("div",{className:"position-relative"},f.default.createElement("span",{style:{position:"absolute",top:-32,right:0}},f.default.createElement($r,{style:{marginLeft:10},fontSize:20,strokeWidth:3,title:g("Extend"),onClick:ae,className:"cursor-pointer"})),f.default.createElement(Hut,{toolbarTemplate:a,isLoading:se,lang:Sut,localeLanguage:Aut,headerColumns:H,dataView:he,isSelectMulti:c,canContextMenuItems:d,handleContextMenuClick:h,rowSelected:u,dataSourceFilter:p,listContextHide:m,setGroupColumns:Ie,t:g,contextMenuOpen:w,stateId:y,groupColumns:He,height:x,settingTable:Ne,rowsPerPage:ge,showColumnChoose:M,typeCheckbox:S,format:A,rowSelection:C,dataSource:Z,columns:H,totalCount:I,setCurrentPage:me,pageSizeOptions:D,handleDoubleContextMenuClick:N,allowResizing:O,summary:L,searchInput:Pe,allowFilterClient:V,setRowsPerPage:we,rowClassName:P,showToolbar:T,allowPaging:B,setQueryFilter:_e,setQueryOrder:Me,selected:Ce,group:Y}),f.default.createElement(ja,{isOpen:J,toggle:ae,className:"modal-dialog-centered modal-fullsize modal-tabs",contentClassName:"p-0",backdrop:"static",keyboard:!1},f.default.createElement(dYe,{typeModal:"View",title:"".concat(Q," / ").concat("".concat(g(null===(n=null==G?void 0:G[null!=z?z:0])||void 0===n?void 0:n.stateName))),handleModal:ae}),f.default.createElement(aqe,{autoHide:!0,autoHeight:!0,autoHeightMax:(null==U?void 0:U.innerHeight)-110,autoHeightMin:(null==U?void 0:U.innerHeight)-110},f.default.createElement(qa,{className:"p-1"},f.default.createElement(Hut,{toolbarTemplate:a,isLoading:se,lang:Sut,localeLanguage:Aut,headerColumns:H,dataView:he,isSelectMulti:c,canContextMenuItems:d,handleContextMenuClick:h,rowSelected:u,dataSourceFilter:p,listContextHide:m,setGroupColumns:Ie,t:g,contextMenuOpen:w,stateId:y,groupColumns:He,height:U.innerHeight-130,settingTable:Ne,rowsPerPage:ge,showColumnChoose:M,typeCheckbox:S,format:A,rowSelection:C,dataSource:Z,columns:H,totalCount:I,setCurrentPage:me,pageSizeOptions:D,handleDoubleContextMenuClick:N,allowResizing:O,summary:L,searchInput:Pe,allowFilterClient:V,setRowsPerPage:we,rowClassName:P,showToolbar:T,allowPaging:B,setQueryFilter:_e,setQueryOrder:Me,selected:Ce,group:Y}))),f.default.createElement("div",{className:"d-flex justify-content-end p-1",style:{boxShadow:"0 4px 24px 0 rgb(34 41 47 / 10%)"}},f.default.createElement(Hn,{color:"secondary",onClick:ae,outline:!0},g("Close")))))},Dut=function(n){var a,r=n.listFile,i=n.height,o=n.t,l=null===(a=Array.isArray(JSON.parse(r))?JSON.parse(r):[])||void 0===a?void 0:a.map(function(e){var t,n,a,r,i,o,l,s;return{id:null!==(t=null==e?void 0:e.id)&&void 0!==t?t:null==e?void 0:e.Id,name:null!==(n=null==e?void 0:e.name)&&void 0!==n?n:null==e?void 0:e.Name,path:null!==(a=null==e?void 0:e.path)&&void 0!==a?a:null==e?void 0:e.Path,size:null!==(r=null==e?void 0:e.size)&&void 0!==r?r:null==e?void 0:e.Size,status:null!==(i=null==e?void 0:e.status)&&void 0!==i?i:null==e?void 0:e.Status,title:null!==(o=null==e?void 0:e.title)&&void 0!==o?o:null==e?void 0:e.Title,type:null!==(l=null==e?void 0:e.type)&&void 0!==l?l:null==e?void 0:e.Type,virtualPath:null!==(s=null==e?void 0:e.virtualPath)&&void 0!==s?s:null==e?void 0:e.VirtualPath}}),s=[{headerText:"STT",field:"#",align:"center",fixed:"left",width:70},{field:"title",type:"string",headerText:o("Title")},{field:"name",headerText:o("File name")},{field:"size",headerText:o("Size"),template:function(t){var n,a,r=(null!==(a=null===(n=t.rowData)||void 0===n?void 0:n.Size)&&void 0!==a?a:0)/Math.pow(1024,2);return f.default.createElement(e.Fragment,null,r.toFixed(2)," MB")}}];return f.default.createElement(e.Fragment,null,f.default.createElement(t.GridComponent,{id:"parent",key:"parent",rowKey:"id",dataSource:l,columns:null!=s?s:[],scroll:i,t:o,format:{decimalSeparator:Y.decimalSeparatorDisplay,thousandSeparator:Y.thousandSeparatorDisplay,decimalScale:ae("quantity")}}))};function Nut(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},a=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})),a.forEach(function(t){vs(e,t,n[t])})}return e}class Out{static isBrowser(){return"undefined"!=typeof window}static isOpera(){return Out.isBrowser()&&(!!window.opera||navigator.userAgent.indexOf(" OPR/")>=0)}static isFirefox(){return Out.isBrowser()&&"undefined"!=typeof InstallTrigger}static isSafari(){return!!Out.isBrowser()&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}static isIE(){
645
645
  /*@cc_on!@*/
646
- return Out.isBrowser()&&!!document.documentMode}static isEdge(){return Out.isBrowser()&&!Out.isIE()&&!!window.StyleMedia}static isChrome(){return Out.isBrowser()&&!!window.chrome&&!!window.chrome.webstore}static isBlink(){return Out.isBrowser()&&(Out.isChrome()||Out.isOpera())&&!!window.CSS}static getUserAgent(){return"undefined"==typeof navigator?"":navigator.userAgent}static isAndroid(){return Out.isBrowser()&&Out.getUserAgent().match(/Android/i)}static isBlackBerry(){return Out.isBrowser()&&Out.getUserAgent().match(/BlackBerry/i)}static isIOS(){return Out.isBrowser()&&Out.getUserAgent().match(/iPhone|iPad|iPod/i)}static isOpera(){return Out.isBrowser()&&Out.getUserAgent().match(/Opera Mini/i)}static isWindows(){return Out.isBrowser()&&Out.isWindowsDesktop()||Out.isWindowsMobile()}static isWindowsMobile(){return Out.isBrowser()&&Out.getUserAgent().match(/IEMobile/i)}static isWindowsDesktop(){return Out.isBrowser()&&Out.getUserAgent().match(/WPDesktop/i)}static isMobile(){return Out.isBrowser()&&(Out.isWindowsMobile()||Out.isBlackBerry()||Out.isAndroid()||Out.isIOS())}}const Lut=e=>Object.keys(e).reduce((t,n)=>"data-"===n.substr(0,5)?Nut({},t,{[n]:e[n]}):t,{});class Vut extends f.default.Component{static isA(e){return!!e&&e.type===f.default.createElement(Vut,null).type}constructor(e){super(e),vs(this,"ref",f.default.createRef()),vs(this,"onMouseMove",e=>{if(this.state.active){const t=this.ref.current;this.props.events.emit("resize",{index:this.props.index,domElement:t,event:e}),this.props.onResize&&this.props.onResize({component:this,domElement:t}),e.stopPropagation(),e.preventDefault()}}),vs(this,"onMouseDown",e=>{this.setState({active:!0}),this.props.onStartResize&&this.props.onStartResize({domElement:this.ref.current,component:this})||this.props.events.emit("startResize",{index:this.props.index,event:e})}),vs(this,"onMouseUp",e=>{this.state.active&&(this.setState({active:!1}),this.props.onStopResize&&this.props.onStopResize({domElement:this.ref.current,component:this}),this.props.events.emit("stopResize",{index:this.props.index,event:e}))}),this.state={active:!1},this.document=e.document}componentDidMount(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}componentWillUnmount(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}render(){const e=[Out.isMobile()?"reflex-thin":"",...this.props.className.split(" "),this.state.active?"active":"","reflex-splitter"].join(" ").trim();return f.default.createElement("div",In({},Lut(this.props),{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id,ref:this.ref}),this.props.children)}}vs(Vut,"propTypes",{children:gt.oneOfType([gt.arrayOf(gt.node),gt.node]),onStartResize:gt.func,onStopResize:gt.func,className:gt.string,propagate:gt.bool,onResize:gt.func,style:gt.object}),vs(Vut,"defaultProps",{document:"undefined"!=typeof document?document:null,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});class zut{constructor(){this._events={}}on(e,t){return e.split(" ").forEach(e=>{this._events[e]=this._events[e]||[],this._events[e].push(t)}),this}off(e,t){if(null!=e)return e.split(" ").forEach(e=>{e in this._events!=!1&&(t?this._events[e].splice(this._events[e].indexOf(t),1):this._events[e]=[])}),this;this._events={}}emit(e){if(void 0!==this._events[e])for(var t=this._events[e].slice(),n=0;n<t.length;++n){var a=t[n].apply(this,Array.prototype.slice.call(arguments,1));if(void 0!==a)return a}}}Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(e,t){if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),a=n.length>>>0;if(0===a)return!1;var r=0|t,i=Math.max(r>=0?r:a-Math.abs(r),0);function o(e,t){return e===t||"number"==typeof e&&"number"==typeof t&&isNaN(e)&&isNaN(t)}for(;i<a;){if(o(n[i],e))return!0;i++}return!1}}),Math.sign||(Math.sign=function(e){return(e>0)-(e<0)||+e});class Put extends f.default.Component{constructor(e){super(e),vs(this,"onWindowResize",()=>{this.setState({flexData:this.computeFlexData()})}),vs(this,"onStartResize",e=>{const t=e.event.changedTouches?e.event.changedTouches[0]:e.event;if("horizontal"===this.props.orientation)document.body.classList.add("reflex-row-resize"),this.previousPos=t.clientY;else document.body.classList.add("reflex-col-resize"),this.previousPos=t.clientX;this.elements=[this.children[e.index-1],this.children[e.index+1]],this.emitElementsEvent(this.elements,"onStartResize")}),vs(this,"onResize",e=>{const t=e.event.changedTouches?e.event.changedTouches[0]:e.event,n=this.getOffset(t,e.domElement);if("horizontal"===this.props.orientation)this.previousPos=t.clientY;else this.previousPos=t.clientX;if(n){const t=this.computeAvailableOffset(e.index,n);t&&(this.elements=this.dispatchOffset(e.index,t),this.adjustFlex(this.elements),this.setState({resizing:!0},()=>{this.emitElementsEvent(this.elements,"onResize")}))}}),vs(this,"onStopResize",e=>{document.body.classList.remove("reflex-row-resize"),document.body.classList.remove("reflex-col-resize");const t=this.elements?this.elements.map(e=>e.ref):[],n=this.children.filter(e=>!Vut.isA(e)&&t.includes(e.ref));this.emitElementsEvent(n,"onStopResize"),this.setState({resizing:!1})}),vs(this,"onElementSize",e=>new Promise(t=>{try{const n=e.index,a=this.getSize(this.children[n]),r=e.size-a,i=e.direction,o=n+i,l=this.computeAvailableOffset(o,i*r);this.elements=null,l&&(this.elements=this.dispatchOffset(o,l),this.adjustFlex(this.elements)),this.setState(this.state,()=>{this.emitElementsEvent(this.elements,"onResize"),t()})}catch(e){console.log(e)}})),this.events=new zut,this.children=[],this.state={flexData:[]},this.ref=f.default.createRef()}componentDidMount(){const e=this.computeFlexData(),{windowResizeAware:t}=this.props;t&&window.addEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:t,flexData:e}),this.events.on("element.size",this.onElementSize),this.events.on("startResize",this.onStartResize),this.events.on("stopResize",this.onStopResize),this.events.on("resize",this.onResize)}componentWillUnmount(){this.events.off(),window.removeEventListener("resize",this.onWindowResize)}getValidChildren(e=this.props){return this.toArray(e.children).filter(e=>!!e)}componentDidUpdate(e,t){const n=this.getValidChildren(this.props);if(n.length!==this.state.flexData.length||e.orientation!==this.props.orientation||this.flexHasChanged(e)){const e=this.computeFlexData(n,this.props);this.setState({flexData:e})}this.props.windowResizeAware!==this.state.windowResizeAware&&(this.props.windowResizeAware?window.addEventListener("resize",this.onWindowResize):window.removeEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:this.props.windowResizeAware}))}flexHasChanged(e){const t=this.getValidChildren(e).map(e=>e.props.flex||0);return!this.getValidChildren().map(e=>e.props.flex||0).every((e,n)=>e===t[n])}getSize(e){var t,n,a;const r=null==e||null===(t=e.ref)||void 0===t?void 0:t.current;return"horizontal"===this.props.orientation?null!==(n=null==r?void 0:r.offsetHeight)&&void 0!==n?n:0:null!==(a=null==r?void 0:r.offsetWidth)&&void 0!==a?a:0}getOffset(e,t){const{top:n,bottom:a,left:r,right:i}=t.getBoundingClientRect();switch(this.props.orientation){case"horizontal":{const t=e.clientY-this.previousPos;if(t>0){if(e.clientY>=n)return t}else if(e.clientY<=a)return t;break}default:{const t=e.clientX-this.previousPos;if(t>0){if(e.clientX>r)return t}else if(e.clientX<i)return t}}return 0}adjustFlex(e){const t=e.reduce((t,n)=>{const a=n.props.index;return t+(n.props.flex-this.state.flexData[a].flex)/e.length},0);e.forEach(e=>{this.state.flexData[e.props.index].flex+=t})}computeAvailableOffset(e,t){const n=this.computeAvailableStretch(e,t),a=this.computeAvailableShrink(e,t);return Math.min(n,a)*Math.sign(t)}checkPropagate(e,t){if(t>0){if(e<this.children.length-2){const t=this.children[e+2];return Vut.isA(t)&&t.props.propagate}}else if(e>2){const t=this.children[e-2];return Vut.isA(t)&&t.props.propagate}return!1}computeAvailableStretch(e,t){var n;const a=t<0?e+1:e-1,r=this.children[a],i=this.getSize(r),o=(null!==(n=null==r?void 0:r.props.maxSize)&&void 0!==n?n:0)-i;if(o<Math.abs(t)&&this.checkPropagate(e,-1*t)){const n=Math.sign(t)*(Math.abs(t)-o);return o+this.computeAvailableStretch(t<0?e+2:e-2,n)}return Math.min(o,Math.abs(t))}computeAvailableShrink(e,t){var n;const a=t>0?e+1:e-1,r=this.children[a],i=this.getSize(r)-Math.max(null!==(n=null==r?void 0:r.props.minSize)&&void 0!==n?n:0,0);if(i<Math.abs(t)&&this.checkPropagate(e,t)){const n=Math.sign(t)*(Math.abs(t)-i);return i+this.computeAvailableShrink(t>0?e+2:e-2,n)}return Math.min(i,Math.abs(t))}computePixelFlex(e=this.props.orientation){return this.ref.current?"horizontal"===e?0===this.ref.current.offsetHeight?(console.warn("Found ReflexContainer with height=0, this will cause invalid behavior..."),console.warn(this.ref.current),0):1/this.ref.current.offsetHeight:0===this.ref.current.offsetWidth?(console.warn("Found ReflexContainer with width=0, this will cause invalid behavior..."),console.warn(this.ref.current),0):1/this.ref.current.offsetWidth:(console.warn("Unable to locate ReflexContainer dom node"),0)}addOffset(e,t){const n=this.getSize(e),a=e.props.index,r=Math.max(n+t,0),i=this.state.flexData[a].flex,o=i>0?i*r/n:this.computePixelFlex()*r;this.state.flexData[a].flex=!isFinite(o)||isNaN(o)?0:o}dispatchStretch(e,t){const n=t<0?e+1:e-1;if(n<0||n>this.children.length-1)return[];const a=this.children[n],r=this.getSize(a),i=Math.min(a.props.maxSize,r+Math.abs(t))-r;if(this.addOffset(a,i),i<Math.abs(t)){const n=e-2*Math.sign(t),r=Math.sign(t)*(Math.abs(t)-i);return[a,...this.dispatchStretch(n,r)]}return[a]}dispatchShrink(e,t){const n=t>0?e+1:e-1;if(n<0||n>this.children.length-1)return[];const a=this.children[n],r=this.getSize(a),i=Math.max(a.props.minSize,r-Math.abs(t))-r;if(this.addOffset(a,i),Math.abs(i)<Math.abs(t)){const n=e+2*Math.sign(t),r=Math.sign(t)*(Math.abs(t)+i);return[a,...this.dispatchShrink(n,r)]}return[a]}dispatchOffset(e,t){return[...this.dispatchStretch(e,t),...this.dispatchShrink(e,t)]}emitElementsEvent(e,t){this.toArray(e).forEach(e=>{e.props[t]&&e.props[t]({domElement:e.ref.current,component:e})})}computeFlexData(e=this.getValidChildren(),t=this.props){const n=this.computePixelFlex(t.orientation),a=e.map(e=>{const t=e.props;return{maxFlex:(t.maxSize||Number.MAX_VALUE)*n,sizeFlex:(t.size||Number.MAX_VALUE)*n,minFlex:(t.minSize||1)*n,constrained:void 0!==t.flex,flex:t.flex||0,type:e.type}}),r=(e,t=0)=>{let n=!1;const a=(e=>e.reduce((e,t)=>Vut.isA(t)||t.constrained?e:e+1,0))(e),i=(e=>e.reduce((e,t)=>!Vut.isA(t)&&t.constrained?e-t.flex:e,1))(e),o=e.map(e=>{if(Vut.isA(e))return e;const t=e.constrained?e.flex:i/a,r=Math.min(e.sizeFlex,Math.min(e.maxFlex,Math.max(e.minFlex,t))),o=e.constrained||r!==t;return n=n||o,Nut({},e,{flex:r,constrained:o})});return n&&t<this.props.maxRecDepth?r(o,t+1):o};return r(a).map(e=>({flex:Vut.isA(e)?0:e.flex,ref:f.default.createRef()}))}toArray(e){return e?Array.isArray(e)?e:[e]:[]}render(){const e=[this.state.resizing?"reflex-resizing":"",...this.props.className.split(" "),this.props.orientation,"reflex-container"].join(" ").trim();return this.children=f.default.Children.map(this.getValidChildren(),(e,t)=>{if(t>this.state.flexData.length-1)return f.default.createElement("div",null);const n=this.state.flexData[t],a=Nut({},e.props,{maxSize:e.props.maxSize||Number.MAX_VALUE,orientation:this.props.orientation,minSize:e.props.minSize||1,events:this.events,flex:n.flex,ref:n.ref,index:t});return f.default.cloneElement(e,a)}),f.default.createElement("div",In({},Lut(this.props),{style:this.props.style,className:e,ref:this.ref}),this.children)}}vs(Put,"propTypes",{windowResizeAware:gt.bool,orientation:gt.oneOf(["horizontal","vertical"]),maxRecDepth:gt.number,className:gt.string,style:gt.object}),vs(Put,"defaultProps",{orientation:"horizontal",windowResizeAware:!1,maxRecDepth:100,className:"",style:{}});class Tut extends f.default.Component{static isA(e){return!!e&&("development"===process.env.NODE_ENV?e.type===f.default.createElement(Tut,null).type:e.type===Tut)}constructor(e){super(e),vs(this,"ref",f.default.createRef()),vs(this,"onMouseMove",e=>{if(this.state.active){const t=this.ref.current;this.props.events.emit("resize",{index:this.props.index,domElement:t,event:e}),this.props.onResize&&this.props.onResize({component:this,domElement:t}),e.stopPropagation(),e.preventDefault()}}),vs(this,"onMouseDown",e=>{this.setState({active:!0}),this.props.onStartResize&&this.props.onStartResize({domElement:this.ref.current,component:this})||this.props.events.emit("startResize",{index:this.props.index,event:e})}),vs(this,"onMouseUp",e=>{this.state.active&&(this.setState({active:!1}),this.props.onStopResize&&this.props.onStopResize({domElement:this.ref.current,component:this}),this.props.events.emit("stopResize",{index:this.props.index,event:e}))}),this.state={active:!1},this.document=e.document}componentDidMount(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}componentWillUnmount(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}render(){const e=[...this.props.className.split(" "),this.state.active?"active":"","reflex-handle"].join(" ").trim();return f.default.createElement("div",In({},Lut(this.props),{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id,ref:this.ref}),this.props.children)}}vs(Tut,"propTypes",{children:gt.oneOfType([gt.arrayOf(gt.node),gt.node]),onStartResize:gt.func,onStopResize:gt.func,className:gt.string,propagate:gt.bool,onResize:gt.func,style:gt.object}),vs(Tut,"defaultProps",{document:"undefined"==typeof document?null:document,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});var But="Expected a function",jut=/^\s+|\s+$/g,Wut=/^[-+]0x[0-9a-f]+$/i,Rut=/^0b[01]+$/i,Fut=/^0o[0-7]+$/i,Yut=parseInt,qut="object"==typeof C&&C&&C.Object===Object&&C,Uut="object"==typeof self&&self&&self.Object===Object&&self,Gut=qut||Uut||Function("return this")(),Kut=Object.prototype.toString,Qut=Math.max,Xut=Math.min,Jut=function(){return Gut.Date.now()};function $ut(e,t,n){var a,r,i,o,l,s,c=0,d=!1,h=!1,u=!0;if("function"!=typeof e)throw new TypeError(But);function p(t){var n=a,i=r;return a=r=void 0,c=t,o=e.apply(i,n)}function f(e){var n=e-s;return void 0===s||n>=t||n<0||h&&e-c>=i}function m(){var e=Jut();if(f(e))return v(e);l=setTimeout(m,function(e){var n=t-(e-s);return h?Xut(n,i-(e-c)):n}(e))}function v(e){return l=void 0,u&&a?p(e):(a=r=void 0,o)}function g(){var e=Jut(),n=f(e);if(a=arguments,r=this,s=e,n){if(void 0===l)return function(e){return c=e,l=setTimeout(m,t),d?p(e):o}(s);if(h)return l=setTimeout(m,t),p(s)}return void 0===l&&(l=setTimeout(m,t)),o}return t=tpt(t)||0,ept(n)&&(d=!!n.leading,i=(h="maxWait"in n)?Qut(tpt(n.maxWait)||0,t):i,u="trailing"in n?!!n.trailing:u),g.cancel=function(){void 0!==l&&clearTimeout(l),c=0,a=s=r=l=void 0},g.flush=function(){return void 0===l?o:v(Jut())},g}function ept(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function tpt(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==Kut.call(e)}(e))return NaN;if(ept(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ept(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(jut,"");var n=Rut.test(e);return n||Fut.test(e)?Yut(e.slice(2),n?2:8):Wut.test(e)?NaN:+e}var npt=function(e,t,n){var a=!0,r=!0;if("function"!=typeof e)throw new TypeError(But);return ept(n)&&(a="leading"in n?!!n.leading:a,r="trailing"in n?!!n.trailing:r),$ut(e,t,{leading:a,maxWait:t,trailing:r})},apt=["client","offset","scroll","bounds","margin"];function rpt(e){var t=[];return apt.forEach(function(n){e[n]&&t.push(n)}),t}function ipt(e,t){var n={};if(t.indexOf("client")>-1&&(n.client={top:e.clientTop,left:e.clientLeft,width:e.clientWidth,height:e.clientHeight}),t.indexOf("offset")>-1&&(n.offset={top:e.offsetTop,left:e.offsetLeft,width:e.offsetWidth,height:e.offsetHeight}),t.indexOf("scroll")>-1&&(n.scroll={top:e.scrollTop,left:e.scrollLeft,width:e.scrollWidth,height:e.scrollHeight}),t.indexOf("bounds")>-1){var a=e.getBoundingClientRect();n.bounds={top:a.top,right:a.right,bottom:a.bottom,left:a.left,width:a.width,height:a.height}}if(t.indexOf("margin")>-1){var r=getComputedStyle(e);n.margin={top:r?parseInt(r.marginTop):0,right:r?parseInt(r.marginRight):0,bottom:r?parseInt(r.marginBottom):0,left:r?parseInt(r.marginLeft):0}}return n}var opt=function(t){return function(n){var a,r;return r=a=function(a){function r(){for(var e,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return(e=a.call.apply(a,[this].concat(r))||this).state={contentRect:{entry:{},client:{},offset:{},scroll:{},bounds:{},margin:{}}},e._animationFrameID=null,e._resizeObserver=null,e._node=null,e._window=null,e.measure=function(n){var a=ipt(e._node,t||rpt(e.props));n&&(a.entry=n[0].contentRect),e._animationFrameID=e._window.requestAnimationFrame(function(){null!==e._resizeObserver&&(e.setState({contentRect:a}),"function"==typeof e.props.onResize&&e.props.onResize(a))})},e._handleRef=function(t){var n;null!==e._resizeObserver&&null!==e._node&&e._resizeObserver.unobserve(e._node),e._node=t,e._window=(n=e._node)&&n.ownerDocument&&n.ownerDocument.defaultView||window;var a=e.props.innerRef;a&&("function"==typeof a?a(e._node):a.current=e._node),null!==e._resizeObserver&&null!==e._node&&e._resizeObserver.observe(e._node)},e}On(r,a);var i=r.prototype;return i.componentDidMount=function(){this._resizeObserver=null!==this._window&&this._window.ResizeObserver?new this._window.ResizeObserver(this.measure):new MQe(this.measure),null!==this._node&&(this._resizeObserver.observe(this._node),"function"==typeof this.props.onResize&&this.props.onResize(ipt(this._node,t||rpt(this.props))))},i.componentWillUnmount=function(){null!==this._window&&this._window.cancelAnimationFrame(this._animationFrameID),null!==this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)},i.render=function(){var t=this.props;t.innerRef,t.onResize;var a=Dn(t,["innerRef","onResize"]);return e.createElement(n,In({},a,{measureRef:this._handleRef,measure:this.measure,contentRect:this.state.contentRect}))},r}(e.Component),a.propTypes={client:gt.bool,offset:gt.bool,scroll:gt.bool,bounds:gt.bool,margin:gt.bool,innerRef:gt.oneOfType([gt.object,gt.func]),onResize:gt.func},r}}()(function(e){var t=e.measure,n=e.measureRef,a=e.contentRect;return(0,e.children)({measure:t,measureRef:n,contentRect:a})});opt.displayName="Measure",opt.propTypes.children=gt.func;const lpt=e=>e?Array.isArray(e)?e:[e]:[];class spt extends f.default.Component{constructor(e){super(e),vs(this,"onResize",e=>{const{resizeHeight:t,resizeWidth:n}=this.props,{height:a,width:r}=e.bounds;this.setDimensions(Nut({},t&&{height:a},n&&{width:r}))}),this.setDimensions=npt(e=>{this.setState(e)},this.props.propagateDimensionsRate/1e3),this.state={height:"100%",width:"100%"}}renderChildren(){const{propagateDimensions:e}=this.props,t=lpt(this.props.children).filter(e=>!!e);return f.default.Children.map(t,t=>this.props.withHandle||Tut.isA(t)?f.default.cloneElement(t,Nut({dimensions:e&&this.state},t.props,{index:this.props.index-1,events:this.props.events})):e?f.default.cloneElement(t,Nut({},t.props,{dimensions:this.state})):t)}render(){return f.default.createElement(opt,{bounds:!0,onResize:this.onResize},({measureRef:e})=>f.default.createElement("div",{ref:e,className:"reflex-size-aware"},f.default.createElement("div",{style:this.state},this.renderChildren())))}}class cpt extends f.default.Component{constructor(e){super(e),this.state={size:e.size}}static getDerivedStateFromProps(e,t){return e.size!==t.size?Nut({},t,{size:e.size}):null}async componentDidUpdate(e,t,n){if(t.size!==this.state.size){const e=lpt(this.props.direction);for(let t of e)await this.props.events.emit("element.size",{index:this.props.index,size:this.props.size,direction:t})}}renderChildren(){const e=lpt(this.props.children).filter(e=>!!e);return f.default.Children.map(e,e=>this.props.withHandle||Tut.isA(e)?f.default.cloneElement(e,Nut({},e.props,{index:this.props.index-1,events:this.props.events})):e)}render(){const e=[...this.props.className.split(" "),this.props.orientation,"reflex-element"].join(" ").trim(),t=Nut({},this.props.style,{flexGrow:this.props.flex,flexShrink:1,flexBasis:"0%"});return f.default.createElement("div",In({},Lut(this.props),{ref:this.props.innerRef,className:e,style:t}),this.props.propagateDimensions?f.default.createElement(spt,this.props):this.renderChildren())}}vs(cpt,"propTypes",{propagateDimensions:gt.bool,resizeHeight:gt.bool,resizeWidth:gt.bool,className:gt.string,size:gt.number}),vs(cpt,"defaultProps",{propagateDimensionsRate:100,propagateDimensions:!1,resizeHeight:!0,resizeWidth:!0,direction:[1],className:""});var dpt=f.default.forwardRef((e,t)=>f.default.createElement(cpt,In({innerRef:t},e)));E("body.reflex-col-resize {\n cursor: col-resize; }\n\nbody.reflex-row-resize {\n cursor: row-resize; }\n\n.reflex-container {\n justify-content: flex-start;\n /* align items in Main Axis */\n align-items: stretch;\n /* align items in Cross Axis */\n align-content: stretch;\n /* OLD - iOS 6-, Safari 3.1-6 */\n /* OLD - Firefox 19- (buggy but mostly works) */\n /* TWEENER - IE 10 */\n /* NEW - Chrome */\n display: flex;\n position: relative;\n height: 100%;\n width: 100%; }\n\n.reflex-container.horizontal {\n flex-direction: column;\n min-height: 1px; }\n\n.reflex-container.vertical {\n flex-direction: row;\n min-width: 1px; }\n\n.reflex-container > .reflex-element {\n position: relative;\n overflow: auto;\n height: 100%;\n width: 100%; }\n\n.reflex-container.reflex-resizing > .reflex-element {\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none; }\n\n.reflex-container > .reflex-element > .reflex-size-aware {\n height: 100%;\n width: 100%; }\n\n.reflex-container > .reflex-splitter {\n background-color: #eeeeee;\n z-index: 100; }\n\n.reflex-container > .reflex-splitter.active,\n.reflex-container > .reflex-splitter:hover {\n background-color: #c6c6c6;\n transition: all 1s ease; }\n\n.horizontal > .reflex-splitter {\n border-bottom: 1px solid #c6c6c6;\n border-top: 1px solid #c6c6c6;\n cursor: row-resize;\n width: 100%;\n height: 2px; }\n\n.reflex-element.horizontal .reflex-handle {\n cursor: row-resize;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none; }\n\n.reflex-container.horizontal > .reflex-splitter:hover,\n.reflex-container.horizontal > .reflex-splitter.active {\n border-bottom: 1px solid #eeeeee;\n border-top: 1px solid #eeeeee; }\n\n.reflex-container.vertical > .reflex-splitter {\n border-right: 1px solid #c6c6c6;\n border-left: 1px solid #c6c6c6;\n cursor: col-resize;\n height: 100%;\n width: 2px; }\n\n.reflex-element.vertical .reflex-handle {\n cursor: col-resize;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none; }\n\n.reflex-container.vertical > .reflex-splitter:hover,\n.reflex-container.vertical > .reflex-splitter.active {\n border-right: 1px solid #eeeeee;\n border-left: 1px solid #eeeeee; }\n\n.reflex-container > .reflex-splitter.reflex-thin {\n box-sizing: border-box;\n -moz-background-clip: padding;\n -webkit-background-clip: padding;\n background-clip: padding-box;\n opacity: 0.2;\n z-index: 100; }\n\n.reflex-container > .reflex-splitter.reflex-thin.active\n.reflex-container > .reflex-splitter.reflex-thin:hover {\n transition: all 1.5s ease;\n opacity: 0.5; }\n\n.reflex-container.horizontal > .reflex-splitter.reflex-thin {\n border-bottom: 8px solid rgba(255, 255, 255, 0);\n border-top: 8px solid rgba(255, 255, 255, 0);\n height: 17px !important;\n cursor: row-resize;\n margin: -8px 0;\n width: 100%; }\n\n.reflex-container.horizontal > .reflex-splitter.reflex-thin.active,\n.reflex-container.horizontal > .reflex-splitter.reflex-thin:hover {\n border-bottom: 8px solid #e4e4e4;\n border-top: 8px solid #e4e4e4; }\n\n.reflex-container.vertical > .reflex-splitter.reflex-thin {\n border-right: 8px solid rgba(255, 255, 255, 0);\n border-left: 8px solid rgba(255, 255, 255, 0);\n width: 17px !important;\n cursor: col-resize;\n margin: 0 -8px;\n height: 100%; }\n\n.reflex-container.vertical > .reflex-splitter.reflex-thin.active,\n.reflex-container.vertical > .reflex-splitter.reflex-thin:hover {\n border-right: 8px solid #e4e4e4;\n border-left: 8px solid #e4e4e4; }");var hpt=function(e){var t=e.breadCrumbTitle,n=e.breadCrumbParent,a=e.breadCrumbActive;return f.default.createElement("div",{className:"content-header row"},f.default.createElement("div",{className:"content-header-left col-md-9 col-12"},f.default.createElement("div",{className:"row breadcrumbs-top"},f.default.createElement("div",{className:"col-12"},t?f.default.createElement("h2",{className:"content-header-title float-start mb-0"},t):"",f.default.createElement("div",{className:"breadcrumb-wrapper vs-breadcrumbs d-sm-block d-none col-12"},f.default.createElement(pn,{className:"breadcrumb-nowrap"},f.default.createElement(wn,{tag:"li"},f.default.createElement("a",{href:"/"},f.default.createElement(Xr,{fontSize:20}))),n&&n.length>0&&(null==n?void 0:n.map(function(e,t){return f.default.createElement(wn,{key:t,tag:"li"},e.link?f.default.createElement("a",{href:e.link},e.title):e.title)})),f.default.createElement(wn,{tag:"li",active:!0},a)))))))};hpt.propTypes={breadCrumbActive:gt.string.isRequired,breadCrumbParent:gt.object};var upt=0;function ppt(e,t){var n=t;return n.unshift(void 0),new(Function.prototype.bind.apply(e,n))}function fpt(e,t){for(var n=t,a=e.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r<a.length&&!Ept(n);r++)n=n[a[r]];return n}function mpt(e,t,n){var a,r,i=e.replace(/\[/g,".").replace(/\]/g,"").split("."),o=n||{},l=o,s=i.length;for(a=0;a<s;a++)r=i[a],a+1===s?l[r]=void 0===t?{}:t:xpt(l[r])&&(l[r]={}),l=l[r];return o}function vpt(e,t){delete e[t]}var gpt="undefined"!=typeof window?window:{};function wpt(e){return!xpt(e)&&e.constructor==={}.constructor}function ypt(e,t){if(!xpt(t))for(var n=e,a=t,r="deepMerge",i=0,o=Object.keys(t);i<o.length;i++){var l=o[i];xpt(n[r])||-1===n[r].indexOf(l)||!wpt(a[l])&&!Array.isArray(a[l])?n[l]=a[l]:bpt(n[l],n[l],a[l],!0)}}function bpt(e,t,n,a){var r=e&&"object"==typeof e?e:{},i=arguments.length;a&&(i-=1);for(var o=function(e){if(!l[e])return"continue";var t=l[e];Object.keys(t).forEach(function(e){var n,i=r[e],o=t[e];Array.isArray(o)&&Array.isArray(i)&&(o.length,i.length);a&&(wpt(o)||Array.isArray(o))?wpt(o)?(n=i||{},Array.isArray(n)&&n.hasOwnProperty("isComplexArray")?bpt(n,{},o,a):r[e]=bpt(n,{},o,a)):(n=i||[],r[e]=bpt([],n,o,n&&n.length||o&&o.length)):r[e]=o})},l=arguments,s=1;s<i;s++)o(s);return r}function xpt(e){return null==e}function Ept(e){return void 0===e}function kpt(e){return e+"_"+upt++}function Mpt(e,t){return e===t||!(e===document||!e)&&Mpt(e.parentNode,t)}function Spt(e){try{throw new Error(e)}catch(e){throw e.message+"\n"+e.stack}}function Apt(e){var t=e+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function _pt(){return false}var Cpt,Zpt={latn:{_digits:"0123456789",_type:"numeric"}},Hpt={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"∞",nan:"NaN",exponential:"E"},Ipt=[0,1,2,3,4,5,6,7,8,9],Dpt=function(){function e(){}return e.getMainObject=function(e,t){return fpt("main."+t,e)},e.getNumberingSystem=function(e){return fpt("supplemental.numberingSystems",e)||this.numberingSystems},e.reverseObject=function(e,t){for(var n={},a=0,r=t||Object.keys(e);a<r.length;a++){var i=r[a];n.hasOwnProperty(e[i])||(n[e[i]]=i)}return n},e.getSymbolRegex=function(e){var t=e.map(function(e){return e.replace(/([.*+?^=!:${}()|[\]/\\])/g,"\\$1")}).join("|");return new RegExp(t,"g")},e.getSymbolMatch=function(e){for(var t={},n=0,a=Object.keys(Hpt);n<a.length;n++){var r=a[n];t[e[r]]=Hpt[r]}return t},e.constructRegex=function(e){for(var t=e.length,n="",a=0;a<t;a++)n+=a!==t-1?e[a]+"|":e[a];return n},e.convertValueParts=function(e,t,n){return e.replace(t,function(e){return n[e]})},e.getDefaultNumberingSystem=function(e){var t={};return t.obj=fpt("numbers",e),t.nSystem=fpt("defaultNumberingSystem",t.obj),t},e.getCurrentNumericOptions=function(e,t,n,a){var r={},i=this.getDefaultNumberingSystem(e);if(!Ept(i.nSystem)||a){var o=a?fpt("obj.mapperDigits",i):fpt(i.nSystem+"._digits",t);Ept(o)||(r.numericPair=this.reverseObject(o,Ipt),r.numberParseRegex=new RegExp(this.constructRegex(o),"g"),r.numericRegex="["+o[0]+"-"+o[9]+"]",n&&(r.numericRegex=o[0]+"-"+o[9],r.symbolNumberSystem=fpt(a?"numberSymbols":"symbols-numberSystem-"+i.nSystem,i.obj),r.symbolMatch=this.getSymbolMatch(r.symbolNumberSystem),r.numberSystem=i.nSystem))}return r},e.getNumberMapper=function(e,t,n){var a={mapper:{}},r=this.getDefaultNumberingSystem(e);if(!Ept(r.nSystem)){a.numberSystem=r.nSystem,a.numberSymbols=fpt("symbols-numberSystem-"+r.nSystem,r.obj),a.timeSeparator=fpt("timeSeparator",a.numberSymbols);var i=fpt(r.nSystem+"._digits",t);if(!Ept(i))for(var o=0,l=Ipt;o<l.length;o++){var s=l[o];a.mapper[s]=i[s]}}return a},e.nPair="numericPair",e.nRegex="numericRegex",e.numberingSystems=Zpt,e}(),Npt={DJF:"Fdj",ERN:"Nfk",ETB:"Br",NAD:"$",ZAR:"R",XAF:"FCFA",GHS:"GH₵",XDR:"XDR",AED:"د.إ.‏",BHD:"د.ب.‏",DZD:"د.ج.‏",EGP:"ج.م.‏",ILS:"₪",IQD:"د.ع.‏",JOD:"د.ا.‏",KMF:"CF",KWD:"د.ك.‏",LBP:"ل.ل.‏",LYD:"د.ل.‏",MAD:"د.م.‏",MRU:"أ.م.",OMR:"ر.ع.‏",QAR:"ر.ق.‏",SAR:"ر.س.‏",SDG:"ج.س.",SOS:"S",SSP:"£",SYP:"ل.س.‏",TND:"د.ت.‏",YER:"ر.ي.‏",CLP:"$",INR:"₹",TZS:"TSh",EUR:"€",AZN:"₼",RUB:"₽",BYN:"Br",ZMW:"K",BGN:"лв.",NGN:"₦",XOF:"CFA",BDT:"৳",CNY:"¥",BAM:"КМ",UGX:"USh",USD:"$",CZK:"Kč",GBP:"£",DKK:"kr.",KES:"Ksh",CHF:"CHF",MVR:"ރ.",BTN:"Nu.",XCD:"EC$",AUD:"$",BBD:"$",BIF:"FBu",BMD:"$",BSD:"$",BWP:"P",BZD:"$",CAD:"$",NZD:"$",FJD:"$",FKP:"£",GIP:"£",GMD:"D",GYD:"$",HKD:"$",IDR:"Rp",JMD:"$",KYD:"$",LRD:"$",MGA:"Ar",MOP:"MOP$",MUR:"Rs",MWK:"MK",MYR:"RM",PGK:"K",PHP:"₱",PKR:"Rs",RWF:"RF",SBD:"$",SCR:"SR",SEK:"kr",SGD:"$",SHP:"£",SLL:"Le",ANG:"NAf.",SZL:"E",TOP:"T$",TTD:"$",VUV:"VT",WST:"WS$",ARS:"$",BOB:"Bs",BRL:"R$",COP:"$",CRC:"₡",CUP:"$",DOP:"$",GTQ:"Q",HNL:"L",MXN:"$",NIO:"C$",PAB:"B/.",PEN:"S/",PYG:"₲",UYU:"$",VES:"Bs.S",IRR:"ريال",GNF:"FG",CDF:"FC",HTG:"G",XPF:"FCFP",HRK:"kn",HUF:"Ft",AMD:"֏",ISK:"kr",JPY:"¥",GEL:"₾",CVE:"​",KZT:"₸",KHR:"៛",KPW:"₩",KRW:"₩",KGS:"сом",AOA:"Kz",LAK:"₭",MZN:"MTn",MKD:"ден",MNT:"₮",BND:"$",MMK:"K",NOK:"kr",NPR:"रु",AWG:"Afl.",SRD:"$",PLN:"zł",AFN:"؋",STN:"Db",MDL:"L",RON:"lei",UAH:"₴",LKR:"රු.",ALL:"Lekë",RSD:"дин.",TJS:"смн",THB:"฿",TMT:"m.",TRY:"₺",UZS:"сўм",VND:"₫",TWD:"NT$"};!function(e){var t=[28607,28636,28665,28695,28724,28754,28783,28813,28843,28872,28901,28931,28960,28990,29019,29049,29078,29108,29137,29167,29196,29226,29255,29285,29315,29345,29375,29404,29434,29463,29492,29522,29551,29580,29610,29640,29669,29699,29729,29759,29788,29818,29847,29876,29906,29935,29964,29994,30023,30053,30082,30112,30141,30171,30200,30230,30259,30289,30318,30348,30378,30408,30437,30467,30496,30526,30555,30585,30614,30644,30673,30703,30732,30762,30791,30821,30850,30880,30909,30939,30968,30998,31027,31057,31086,31116,31145,31175,31204,31234,31263,31293,31322,31352,31381,31411,31441,31471,31500,31530,31559,31589,31618,31648,31676,31706,31736,31766,31795,31825,31854,31884,31913,31943,31972,32002,32031,32061,32090,32120,32150,32180,32209,32239,32268,32298,32327,32357,32386,32416,32445,32475,32504,32534,32563,32593,32622,32652,32681,32711,32740,32770,32799,32829,32858,32888,32917,32947,32976,33006,33035,33065,33094,33124,33153,33183,33213,33243,33272,33302,33331,33361,33390,33420,33450,33479,33509,33539,33568,33598,33627,33657,33686,33716,33745,33775,33804,33834,33863,33893,33922,33952,33981,34011,34040,34069,34099,34128,34158,34187,34217,34247,34277,34306,34336,34365,34395,34424,34454,34483,34512,34542,34571,34601,34631,34660,34690,34719,34749,34778,34808,34837,34867,34896,34926,34955,34985,35015,35044,35074,35103,35133,35162,35192,35222,35251,35280,35310,35340,35370,35399,35429,35458,35488,35517,35547,35576,35605,35635,35665,35694,35723,35753,35782,35811,35841,35871,35901,35930,35960,35989,36019,36048,36078,36107,36136,36166,36195,36225,36254,36284,36314,36343,36373,36403,36433,36462,36492,36521,36551,36580,36610,36639,36669,36698,36728,36757,36786,36816,36845,36875,36904,36934,36963,36993,37022,37052,37081,37111,37141,37170,37200,37229,37259,37288,37318,37347,37377,37406,37436,37465,37495,37524,37554,37584,37613,37643,37672,37701,37731,37760,37790,37819,37849,37878,37908,37938,37967,37997,38027,38056,38085,38115,38144,38174,38203,38233,38262,38292,38322,38351,38381,38410,38440,38469,38499,38528,38558,38587,38617,38646,38676,38705,38735,38764,38794,38823,38853,38882,38912,38941,38971,39001,39030,39059,39089,39118,39148,39178,39208,39237,39267,39297,39326,39355,39385,39414,39444,39473,39503,39532,39562,39592,39621,39650,39680,39709,39739,39768,39798,39827,39857,39886,39916,39946,39975,40005,40035,40064,40094,40123,40153,40182,40212,40241,40271,40300,40330,40359,40389,40418,40448,40477,40507,40536,40566,40595,40625,40655,40685,40714,40744,40773,40803,40832,40862,40892,40921,40951,40980,41009,41039,41068,41098,41127,41157,41186,41216,41245,41275,41304,41334,41364,41393,41422,41452,41481,41511,41540,41570,41599,41629,41658,41688,41718,41748,41777,41807,41836,41865,41894,41924,41953,41983,42012,42042,42072,42102,42131,42161,42190,42220,42249,42279,42308,42337,42367,42397,42426,42456,42485,42515,42545,42574,42604,42633,42662,42692,42721,42751,42780,42810,42839,42869,42899,42929,42958,42988,43017,43046,43076,43105,43135,43164,43194,43223,43253,43283,43312,43342,43371,43401,43430,43460,43489,43519,43548,43578,43607,43637,43666,43696,43726,43755,43785,43814,43844,43873,43903,43932,43962,43991,44021,44050,44080,44109,44139,44169,44198,44228,44258,44287,44317,44346,44375,44405,44434,44464,44493,44523,44553,44582,44612,44641,44671,44700,44730,44759,44788,44818,44847,44877,44906,44936,44966,44996,45025,45055,45084,45114,45143,45172,45202,45231,45261,45290,45320,45350,45380,45409,45439,45468,45498,45527,45556,45586,45615,45644,45674,45704,45733,45763,45793,45823,45852,45882,45911,45940,45970,45999,46028,46058,46088,46117,46147,46177,46206,46236,46265,46295,46324,46354,46383,46413,46442,46472,46501,46531,46560,46590,46620,46649,46679,46708,46738,46767,46797,46826,46856,46885,46915,46944,46974,47003,47033,47063,47092,47122,47151,47181,47210,47240,47269,47298,47328,47357,47387,47417,47446,47476,47506,47535,47565,47594,47624,47653,47682,47712,47741,47771,47800,47830,47860,47890,47919,47949,47978,48008,48037,48066,48096,48125,48155,48184,48214,48244,48273,48303,48333,48362,48392,48421,48450,48480,48509,48538,48568,48598,48627,48657,48687,48717,48746,48776,48805,48834,48864,48893,48922,48952,48982,49011,49041,49071,49100,49130,49160,49189,49218,49248,49277,49306,49336,49365,49395,49425,49455,49484,49514,49543,49573,49602,49632,49661,49690,49720,49749,49779,49809,49838,49868,49898,49927,49957,49986,50016,50045,50075,50104,50133,50163,50192,50222,50252,50281,50311,50340,50370,50400,50429,50459,50488,50518,50547,50576,50606,50635,50665,50694,50724,50754,50784,50813,50843,50872,50902,50931,50960,50990,51019,51049,51078,51108,51138,51167,51197,51227,51256,51286,51315,51345,51374,51403,51433,51462,51492,51522,51552,51582,51611,51641,51670,51699,51729,51758,51787,51816,51846,51876,51906,51936,51965,51995,52025,52054,52083,52113,52142,52171,52200,52230,52260,52290,52319,52349,52379,52408,52438,52467,52497,52526,52555,52585,52614,52644,52673,52703,52733,52762,52792,52822,52851,52881,52910,52939,52969,52998,53028,53057,53087,53116,53146,53176,53205,53235,53264,53294,53324,53353,53383,53412,53441,53471,53500,53530,53559,53589,53619,53648,53678,53708,53737,53767,53796,53825,53855,53884,53913,53943,53973,54003,54032,54062,54092,54121,54151,54180,54209,54239,54268,54297,54327,54357,54387,54416,54446,54476,54505,54535,54564,54593,54623,54652,54681,54711,54741,54770,54800,54830,54859,54889,54919,54948,54977,55007,55036,55066,55095,55125,55154,55184,55213,55243,55273,55302,55332,55361,55391,55420,55450,55479,55508,55538,55567,55597,55627,55657,55686,55716,55745,55775,55804,55834,55863,55892,55922,55951,55981,56011,56040,56070,56100,56129,56159,56188,56218,56247,56276,56306,56335,56365,56394,56424,56454,56483,56513,56543,56572,56601,56631,56660,56690,56719,56749,56778,56808,56837,56867,56897,56926,56956,56985,57015,57044,57074,57103,57133,57162,57192,57221,57251,57280,57310,57340,57369,57399,57429,57458,57487,57517,57546,57576,57605,57634,57664,57694,57723,57753,57783,57813,57842,57871,57901,57930,57959,57989,58018,58048,58077,58107,58137,58167,58196,58226,58255,58285,58314,58343,58373,58402,58432,58461,58491,58521,58551,58580,58610,58639,58669,58698,58727,58757,58786,58816,58845,58875,58905,58934,58964,58994,59023,59053,59082,59111,59141,59170,59200,59229,59259,59288,59318,59348,59377,59407,59436,59466,59495,59525,59554,59584,59613,59643,59672,59702,59731,59761,59791,59820,59850,59879,59909,59939,59968,59997,60027,60056,60086,60115,60145,60174,60204,60234,60264,60293,60323,60352,60381,60411,60440,60469,60499,60528,60558,60588,60618,60648,60677,60707,60736,60765,60795,60824,60853,60883,60912,60942,60972,61002,61031,61061,61090,61120,61149,61179,61208,61237,61267,61296,61326,61356,61385,61415,61445,61474,61504,61533,61563,61592,61621,61651,61680,61710,61739,61769,61799,61828,61858,61888,61917,61947,61976,62006,62035,62064,62094,62123,62153,62182,62212,62242,62271,62301,62331,62360,62390,62419,62448,62478,62507,62537,62566,62596,62625,62655,62685,62715,62744,62774,62803,62832,62862,62891,62921,62950,62980,63009,63039,63069,63099,63128,63157,63187,63216,63246,63275,63305,63334,63363,63393,63423,63453,63482,63512,63541,63571,63600,63630,63659,63689,63718,63747,63777,63807,63836,63866,63895,63925,63955,63984,64014,64043,64073,64102,64131,64161,64190,64220,64249,64279,64309,64339,64368,64398,64427,64457,64486,64515,64545,64574,64603,64633,64663,64692,64722,64752,64782,64811,64841,64870,64899,64929,64958,64987,65017,65047,65076,65106,65136,65166,65195,65225,65254,65283,65313,65342,65371,65401,65431,65460,65490,65520,65549,65579,65608,65638,65667,65697,65726,65755,65785,65815,65844,65874,65903,65933,65963,65992,66022,66051,66081,66110,66140,66169,66199,66228,66258,66287,66317,66346,66376,66405,66435,66465,66494,66524,66553,66583,66612,66641,66671,66700,66730,66760,66789,66819,66849,66878,66908,66937,66967,66996,67025,67055,67084,67114,67143,67173,67203,67233,67262,67292,67321,67351,67380,67409,67439,67468,67497,67527,67557,67587,67617,67646,67676,67705,67735,67764,67793,67823,67852,67882,67911,67941,67971,68e3,68030,68060,68089,68119,68148,68177,68207,68236,68266,68295,68325,68354,68384,68414,68443,68473,68502,68532,68561,68591,68620,68650,68679,68708,68738,68768,68797,68827,68857,68886,68916,68946,68975,69004,69034,69063,69092,69122,69152,69181,69211,69240,69270,69300,69330,69359,69388,69418,69447,69476,69506,69535,69565,69595,69624,69654,69684,69713,69743,69772,69802,69831,69861,69890,69919,69949,69978,70008,70038,70067,70097,70126,70156,70186,70215,70245,70274,70303,70333,70362,70392,70421,70451,70481,70510,70540,70570,70599,70629,70658,70687,70717,70746,70776,70805,70835,70864,70894,70924,70954,70983,71013,71042,71071,71101,71130,71159,71189,71218,71248,71278,71308,71337,71367,71397,71426,71455,71485,71514,71543,71573,71602,71632,71662,71691,71721,71751,71781,71810,71839,71869,71898,71927,71957,71986,72016,72046,72075,72105,72135,72164,72194,72223,72253,72282,72311,72341,72370,72400,72429,72459,72489,72518,72548,72577,72607,72637,72666,72695,72725,72754,72784,72813,72843,72872,72902,72931,72961,72991,73020,73050,73080,73109,73139,73168,73197,73227,73256,73286,73315,73345,73375,73404,73434,73464,73493,73523,73552,73581,73611,73640,73669,73699,73729,73758,73788,73818,73848,73877,73907,73936,73965,73995,74024,74053,74083,74113,74142,74172,74202,74231,74261,74291,74320,74349,74379,74408,74437,74467,74497,74526,74556,74586,74615,74645,74675,74704,74733,74763,74792,74822,74851,74881,74910,74940,74969,74999,75029,75058,75088,75117,75147,75176,75206,75235,75264,75294,75323,75353,75383,75412,75442,75472,75501,75531,75560,75590,75619,75648,75678,75707,75737,75766,75796,75826,75856,75885,75915,75944,75974,76003,76032,76062,76091,76121,76150,76180,76210,76239,76269,76299,76328,76358,76387,76416,76446,76475,76505,76534,76564,76593,76623,76653,76682,76712,76741,76771,76801,76830,76859,76889,76918,76948,76977,77007,77036,77066,77096,77125,77155,77185,77214,77243,77273,77302,77332,77361,77390,77420,77450,77479,77509,77539,77569,77598,77627,77657,77686,77715,77745,77774,77804,77833,77863,77893,77923,77952,77982,78011,78041,78070,78099,78129,78158,78188,78217,78247,78277,78307,78336,78366,78395,78425,78454,78483,78513,78542,78572,78601,78631,78661,78690,78720,78750,78779,78808,78838,78867,78897,78926,78956,78985,79015,79044,79074,79104,79133,79163,79192,79222,79251,79281,79310,79340,79369,79399,79428,79458,79487,79517,79546,79576,79606,79635,79665,79695,79724,79753,79783,79812,79841,79871,79900,79930,79960,79990];e.getHijriDate=function(e){var n=e.getDate(),a=e.getMonth(),r=e.getFullYear(),i=a+1,o=r;i<3&&(o-=1,i+=12);var l=Math.floor(o/100),s=l-Math.floor(l/4)-2,c=Math.floor(365.25*(o+4716))+Math.floor(30.6001*(i+1))+n-s-1524,d=c+(s=(l=Math.floor((c-1867216.25)/36524.25))-Math.floor(l/4)+1)+1524,h=Math.floor((d-122.1)/365.25),u=Math.floor(365.25*h),p=Math.floor((d-u)/30.6001);n=d-u-Math.floor(30.6001*p),(a=Math.floor((d-u)/20.6001))>13&&(h+=1,a-=12),a-=1,r=h-4716;var f=c-24e5,m=10631/30,v=c-1948084,g=Math.floor(v/10631);v-=10631*g;var w=Math.floor((v-.1335)/m),y=30*g+w;v-=Math.floor(w*m+.1335);var b=Math.floor((v+28.5001)/29.5);13===b&&(b=12);for(var x=v-Math.floor(29.5001*b-29),E=0;E<t.length&&!(t[E]>f);E++);var k=E+16260,M=Math.floor((k-1)/12),S=M+1,A=k-12*M,_=f-t[E-1]+1;return(_+"").length>2&&(_=x,A=b,S=y),{year:S,month:A,date:_}},e.toGregorian=function(e,n,a){var r=a+t[12*(e-1)+1+(n-1)-16260-1]-1+24e5,i=Math.floor(r+.5),o=Math.floor((i-1867216.25)/36524.25),l=(o=i+1+o-Math.floor(o/4))+1524,s=Math.floor((l-122.1)/365.25),c=Math.floor(365.25*s),d=Math.floor((l-c)/30.6001),h=l-c-Math.floor(30.6001*d),u=d-(d>13.5?13:1),p=s-(u>2.5?4716:4715);return p<=0&&u--,new Date(p+"/"+u+"/"+h)}}(Cpt||(Cpt={}));var Opt=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Lpt="stand-alone",Vpt=["sun","mon","tue","wed","thu","fri","sat"],zpt={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Ppt={M:"month",d:"day",E:"weekday",c:"weekday",y:"year",m:"minute",h:"hour",H:"hour",s:"second",L:"month",a:"designator",z:"timeZone",Z:"timeZone",G:"era",f:"milliseconds"},Tpt=function(){function e(){}return e.dateFormat=function(e,t,n){var a=this,r=rft.getDependables(n,e,t.calendar);fpt("parserObject.numbers",r);var i=r.dateObject,o={isIslamic:rft.islamicRegex.test(t.calendar)},l=t.format||rft.getResultantPattern(t.skeleton,r.dateObject,t.type,!1,"");if(o.dateSeperator=rft.getDateSeparator(r.dateObject),Ept(l))Spt("Format options or type given must be invalid");else{l=rft.ConvertDateToWeekFormat(l),o.pattern=l,o.numMapper=Dpt.getNumberMapper(r.parserObject,Dpt.getNumberingSystem(n));for(var s=0,c=l.match(Opt)||[];s<c.length;s++){var d=c[s],h=d.length,u=d[0];switch("K"===u&&(u="h"),u){case"E":case"c":o.weekday=r.dateObject[rft.days][Lpt][rft.monthIndex[h]];break;case"M":case"L":o.month=r.dateObject[rft.month][Lpt][rft.monthIndex[h]];break;case"a":o.designator=fpt("dayPeriods.format.wide",i);break;case"G":var p=h<=3?"eraAbbr":4===h?"eraNames":"eraNarrow";o.era=fpt("eras."+p,r.dateObject);break;case"z":o.timeZone=fpt("dates.timeZoneNames",r.parserObject)}}}return function(e){return isNaN(e.getDate())?null:a.intDateFormatter(e,o)}},e.intDateFormatter=function(e,t){for(var n="",a=t.pattern.match(rft.dateParseRegex),r=this.getCurrentDateValue(e,t.isIslamic),i=0,o=a;i<o.length;i++){var l=o[i],s=l.length,c=l[0];"K"===c&&(c="h");var d=void 0,h="",u=void 0,p=void 0,f="";switch(c){case"M":case"L":d=r.month,s>2?n+=t.month[d]:u=!0;break;case"E":case"c":n+=t.weekday[Vpt[e.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(u=!0,"d"===c)d=r.date;else if("f"===c){u=!1,p=!0;var m=(h=(h=e[zpt[c]]().toString()).substring(0,s)).length;if(s!==m){if(s>3)continue;for(var v=0;v<s-m;v++)h="0"+h.toString()}f+=h}else d=e[zpt[c]]();"h"===c&&(d=d%12||12);break;case"y":p=!0,f+=r.year,2===s&&(f=f.substr(f.length-2));break;case"a":var g=e.getHours()<12?"am":"pm";n+=t.designator[g];break;case"G":var w=e.getFullYear()<0?0:1,y=t.era[w];xpt(y)&&(y=t.era[w?0:1]),n+=y||"";break;case"'":n+="''"===l?"'":l.replace(/'/g,"");break;case"z":var b=e.getTimezoneOffset(),x=s<4?"+H;-H":t.timeZone.hourFormat;x=x.replace(/:/g,t.numMapper.timeSeparator),0===b?n+=t.timeZone.gmtZeroFormat:(p=!0,f=this.getTimeZoneValue(b,x)),f=t.timeZone.gmtFormat.replace(/\{0\}/,f);break;case":":n+=t.numMapper.numberSymbols.timeSeparator;break;case"/":n+=t.dateSeperator;break;case"W":u=!0,d=rft.getWeekOfYear(e);break;default:n+=l}u&&(p=!0,f=this.checkTwodigitNumber(d,s)),p&&(n+=Dpt.convertValueParts(f,rft.latnParseRegex,t.numMapper.mapper))}return n},e.getCurrentDateValue=function(e,t){return t?Cpt.getHijriDate(e):{year:e.getFullYear(),month:e.getMonth()+1,date:e.getDate()}},e.checkTwodigitNumber=function(e,t){var n=e+"";return 2===t&&2!==n.length?"0"+n:n},e.getTimeZoneValue=function(e,t){var n=this,a=t.split(";")[e>0?1:0],r=Math.abs(e);return a.replace(/HH?|mm/g,function(e){var t=e.length,a=-1!==e.indexOf("H");return n.checkTwodigitNumber(Math.floor(a?r/60:r%60),t)})},e}(),Bpt={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},jpt=["infinity","nan","group","decimal","exponential"],Wpt=function(){function e(){}return e.numberFormatter=function(e,t,n){var a,r=this,i=bpt({},t),o={},l={},s=rft.getDependables(n,e,"",!0);s.numericObject,l.numberMapper=Dpt.getNumberMapper(s.parserObject,Dpt.getNumberingSystem(n),!0),l.currencySymbol=rft.getCurrencySymbol(s.numericObject,i.currency||tft,t.altSymbol),l.percentSymbol=l.numberMapper.numberSymbols.percentSign,l.minusSymbol=l.numberMapper.numberSymbols.minusSign;var c=l.numberMapper.numberSymbols;if(t.format&&!rft.formatRegex.test(t.format))o=rft.customFormat(t.format,l,s.numericObject);else{bpt(i,rft.getProperNumericSkeleton(t.format||"N")),i.isCurrency="currency"===i.type,i.isPercent="percent"===i.type,a=rft.getSymbolPattern(i.type,l.numberMapper.numberSystem,s.numericObject,i.isAccount),i.groupOne=this.checkValueRange(i.maximumSignificantDigits,i.minimumSignificantDigits,!0),this.checkValueRange(i.maximumFractionDigits,i.minimumFractionDigits,!1,!0),Ept(i.fractionDigits)||(i.minimumFractionDigits=i.maximumFractionDigits=i.fractionDigits),Ept(i.useGrouping)&&(i.useGrouping=!0),i.isCurrency&&(a=a.replace(/\u00A4/g,rft.defaultCurrency));var d=a.split(";");if(o.nData=rft.getFormatData(d[1]||"-"+d[0],!0,l.currencySymbol),o.pData=rft.getFormatData(d[0],!1,l.currencySymbol),i.useGrouping&&(i.groupSeparator=c[jpt[2]],i.groupData=this.getGroupingDetails(d[0])),Ept(i.minimumFractionDigits)&&(i.minimumFractionDigits=o.nData.minimumFraction),Ept(i.maximumFractionDigits)){var h=o.nData.maximumFraction;i.maximumFractionDigits=Ept(h)&&i.isPercent?0:h}var u=i.minimumFractionDigits,p=i.maximumFractionDigits;Ept(u)||Ept(p)||u>p&&(i.maximumFractionDigits=u)}return bpt(o.nData,i),bpt(o.pData,i),function(e){return isNaN(e)?c[jpt[1]]:isFinite(e)?r.intNumberFormatter(e,o,l):c[jpt[0]]}},e.getGroupingDetails=function(e){var t={},n=e.match(rft.negativeDataRegex);if(n&&n[4]){var a=n[4],r=a.lastIndexOf(",");if(-1!==r){var i=a.split(".")[0];t.primary=i.length-r-1;var o=a.lastIndexOf(",",r-1);-1!==o&&(t.secondary=r-1-o)}}return t},e.checkValueRange=function(e,t,n,a){var r=a?"f":"s",i=0,o=Bpt["l"+r],l=Bpt["m"+r];if(Ept(e)||(this.checkRange(e,o,a),i++),Ept(t)||(this.checkRange(t,l,a),i++),2===i){if(!(e<t))return!0;Spt(l+"specified must be less than the"+o)}else n&&1===i&&Spt("Both"+l+"and"+l+"must be present");return!1},e.checkRange=function(e,t,n){var a=n?[0,20]:[1,21];(e<a[0]||e>a[1])&&Spt(t+"value must be within the range"+a[0]+"to"+a[1])},e.intNumberFormatter=function(e,t,n){var a;if(!Ept(t.nData.type)){e<0?(e*=-1,a=t.nData):a=0===e&&t.zeroData||t.pData;var r="";return a.isPercent&&(e*=100),a.groupOne?r=this.processSignificantDigits(e,a.minimumSignificantDigits,a.maximumSignificantDigits):(r=this.processFraction(e,a.minimumFractionDigits,a.maximumFractionDigits),a.minimumIntegerDigits&&(r=this.processMinimumIntegers(r,a.minimumIntegerDigits))),"scientific"===a.type&&(r=(r=e.toExponential(a.maximumFractionDigits)).replace("e",n.numberMapper.numberSymbols[jpt[4]])),r=r.replace(".",n.numberMapper.numberSymbols[jpt[3]]),a.useGrouping&&(r=this.groupNumbers(r,a.groupData.primary,a.groupSeparator||",",n.numberMapper.numberSymbols[jpt[3]]||".",a.groupData.secondary)),r=Dpt.convertValueParts(r,rft.latnParseRegex,n.numberMapper.mapper),"N/A"===a.nlead?a.nlead:a.nlead+r+a.nend}},e.processSignificantDigits=function(e,t,n){var a=e+"";return a.length<t?e.toPrecision(t):+(a=e.toPrecision(n))+""},e.groupNumbers=function(e,t,n,a,r){for(var i=!xpt(r)&&0!==r,o=e.split(a),l=o[0],s=l.length,c="";s>t;)c=l.slice(s-t,s)+(c.length?n+c:""),s-=t,i&&(t=r,i=!1);return o[0]=l.slice(0,s)+(c.length?n:"")+c,o.join(a)},e.processFraction=function(e,t,n){var a=(e+"").split(".")[1],r=a?a.length:0;if(t&&r<t){var i="";if(0!==r){i+=e;for(var o=0;o<t-r;o++)i+="0";return i}return i=e.toFixed(t),e.toFixed(t)}return!xpt(n)&&(r>n||0===n)?e.toFixed(n):e+""},e.processMinimumIntegers=function(e,t){var n=e.split("."),a=n[0],r=a.length;if(r<t){for(var i=0;i<t-r;i++)a="0"+a;n[0]=a}return n.join(".")},e}(),Rpt="stand-alone",Fpt=/^[0-9]*$/,Ypt={minute:"setMinutes",hour:"setHours",second:"setSeconds",day:"setDate",month:"setMonth",milliseconds:"setMilliseconds"},qpt=function(){function e(){}return e.dateParser=function(e,t,n){var a,r=this,i=rft.getDependables(n,e,t.calendar),o=Dpt.getCurrentNumericOptions(i.parserObject,Dpt.getNumberingSystem(n),!1,!1),l={},s=t.format||rft.getResultantPattern(t.skeleton,i.dateObject,t.type,!1,""),c="";if(Ept(s))Spt("Format options or type given must be invalid");else{s=rft.ConvertDateToWeekFormat(s),l={isIslamic:rft.islamicRegex.test(t.calendar),pattern:s,evalposition:{},culture:e};for(var d=s.match(rft.dateParseRegex)||[],h=d.length,u=0,p=0,f=!1,m=o.numericRegex,v=Dpt.getNumberMapper(i.parserObject,Dpt.getNumberingSystem(n)),g=0;g<h;g++){var w=d[g],y=w.length,b="K"===w[0]?"h":w[0],x=void 0,E=void 0,k=Ppt[b],M=2===y?"":"?";switch(f&&(u=p,f=!1),b){case"E":case"c":var S;S=i.dateObject[rft.days][Rpt][rft.monthIndex[y]];var A=Dpt.reverseObject(S);c+="("+Object.keys(A).join("|")+")";break;case"M":case"L":case"d":case"m":case"s":case"h":case"H":case"f":if(E=!0,("M"===b||"L"===b)&&y>2){var _;_=i.dateObject.months[Rpt][rft.monthIndex[y]],l[k]=Dpt.reverseObject(_),c+="("+Object.keys(l[k]).join("|")+")"}else if("f"===b){if(y>3)continue;x=!0,c+="("+m+m+"?"+m+"?)"}else x=!0,c+="("+m+m+M+")";"h"===b&&(l.hour12=!0);break;case"W":c+="("+m+(1===y?"?":"")+m+")";break;case"y":E=x=!0,c+=2===y?"("+m+m+")":"("+m+"{"+y+",})";break;case"a":E=!0;var C=fpt("dayPeriods.format.wide",i.dateObject);l[k]=Dpt.reverseObject(C),c+="("+Object.keys(l[k]).join("|")+")";break;case"G":E=!0;var Z=y<=3?"eraAbbr":4===y?"eraNames":"eraNarrow";l[k]=Dpt.reverseObject(fpt("eras."+Z,i.dateObject)),c+="("+Object.keys(l[k]).join("|")+"?)";break;case"z":E=0!==(new Date).getTimezoneOffset(),l[k]=fpt("dates.timeZoneNames",i.parserObject);var H=l[k],I=(a=y<4)?"+H;-H":H.hourFormat;I=I.replace(/:/g,v.timeSeparator),c+="("+this.parseTimeZoneRegx(I,H,m)+")?",f=!0,p=a?6:12;break;case"'":c+="("+w.replace(/'/g,"")+")?";break;default:c+="([\\D])"}E&&(l.evalposition[k]={isNumber:x,pos:g+1+u,hourOnly:a}),g!==h-1||xpt(c)||(l.parserRegex=new RegExp("^"+c+"$","i"))}}return function(e){var t=r.internalDateParse(e,l,o);if(xpt(t)||!Object.keys(t).length)return null;if(l.isIslamic){var n={},a=t.year,i=t.day,s=t.month,c=a?a+"":"",d=2===c.length;a&&s&&i&&!d||(n=Cpt.getHijriDate(new Date)),d&&(a=parseInt((n.year+"").slice(0,2)+c,10));var h=Cpt.toGregorian(a||n.year,s||n.month,i||n.date);t.year=h.getFullYear(),t.month=h.getMonth()+1,t.day=h.getDate()}return r.getDateObject(t)}},e.getDateObject=function(e,t){var n=t||new Date;n.setMilliseconds(0);var a=e.year,r=e.designator,i=e.timeZone;if(!Ept(a)){if((a+"").length<=2)a+=100*Math.floor(n.getFullYear()/100);n.setFullYear(a)}for(var o=0,l=["hour","minute","second","milliseconds","month","day"];o<l.length;o++){var s=l[o],c=e[s];if(Ept(c)&&"day"===s&&n.setDate(1),!Ept(c))if("month"===s){if((c-=1)<0||c>11)return new Date("invalid");var d=n.getDate();n.setDate(1),n[Ypt[s]](c);var h=new Date(n.getFullYear(),c+1,0).getDate();n.setDate(d<h?d:h)}else{if("day"===s){var u=new Date(n.getFullYear(),n.getMonth()+1,0).getDate();if(c<1||c>u)return null}n[Ypt[s]](c)}}if(!Ept(r)){var p=n.getHours();"pm"===r?n.setHours(p+(12===p?0:12)):12===p&&n.setHours(0)}if(!Ept(i)){var f=i-n.getTimezoneOffset();0!==f&&n.setMinutes(n.getMinutes()+f)}return n},e.internalDateParse=function(e,t,n){var a=e.match(t.parserRegex),r={hour:0,minute:0,second:0};if(xpt(a))return null;for(var i=0,o=Object.keys(t.evalposition);i<o.length;i++){var l=o[i],s=t.evalposition[l],c=a[s.pos];if(s.isNumber)r[l]=this.internalNumberParser(c,n);else if("timeZone"!==l||Ept(c))c="month"!==l||t.isIslamic||"en"!==t.culture&&"en-GB"!==t.culture&&"en-US"!==t.culture?c:c[0].toUpperCase()+c.substring(1).toLowerCase(),r[l]=t[l][c];else{var d=s.pos,h=void 0,u=a[d+1],p=!Ept(u);s.hourOnly?h=60*this.getZoneValue(p,u,a[d+4],n):(h=60*this.getZoneValue(p,u,a[d+7],n),h+=this.getZoneValue(p,a[d+4],a[d+10],n)),xpt(h)||(r[l]=h)}}return t.hour12&&(r.hour12=!0),r},e.internalNumberParser=function(e,t){return e=Dpt.convertValueParts(e,t.numberParseRegex,t.numericPair),Fpt.test(e)?+e:null},e.parseTimeZoneRegx=function(e,t,n){var a,r,i=t.gmtFormat,o="("+n+")("+n+")";return a=e.replace("+","\\+"),r=(a=-1!==e.indexOf("HH")?a.replace(/HH|mm/g,"("+o+")"):a.replace(/H|m/g,"("+o+"?)")).split(";").map(function(e){return i.replace("{0}",e)}),a=r.join("|")+"|"+t.gmtZeroFormat},e.getZoneValue=function(e,t,n,a){var r=e?t:n;if(!r)return 0;var i=this.internalNumberParser(r,a);return e?-i:i},e}(),Upt=/^([^0-9]*)(([0-9,]*[0-9]+)(\.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$/,Gpt=/,/g,Kpt=["minusSign","infinity"],Qpt=function(){function e(){}return e.numberParser=function(e,t,n){var a,r,i=this,o=rft.getDependables(n,e,"",!0),l={custom:!0};if(rft.formatRegex.test(t.format)||!t.format?(bpt(l,rft.getProperNumericSkeleton(t.format||"N")),l.custom=!1,l.fractionDigits||t.maximumFractionDigits&&(l.maximumFractionDigits=t.maximumFractionDigits)):bpt(l,rft.customFormat(t.format,null,null)),fpt("numbers",o.parserObject),a=Dpt.getCurrentNumericOptions(o.parserObject,Dpt.getNumberingSystem(n),!0,!1),l.symbolRegex=Dpt.getSymbolRegex(Object.keys(a.symbolMatch)),l.infinity=a.symbolNumberSystem[Kpt[1]],r=rft.getSymbolPattern(l.type,a.numberSystem,o.numericObject,l.isAccount)){var s=(r=r.replace(/\u00A4/g,rft.defaultCurrency)).split(";");l.nData=rft.getFormatData(s[1]||"-"+s[0],!0,""),l.pData=rft.getFormatData(s[0],!0,"")}return function(e){return i.getParsedNumber(e,l,a)}},e.getParsedNumber=function(e,t,n){var a,r,i,o,l,s;if(-1!==e.indexOf(t.infinity))return 1/0;e=Dpt.convertValueParts(e,t.symbolRegex,n.symbolMatch),0===(e=-1!==(e=Dpt.convertValueParts(e,n.numberParseRegex,n.numericPair)).indexOf("-")?e.replace("-.","-0."):e).indexOf(".")&&(e="0"+e);var c=e.match(Upt);if(xpt(c))return NaN;o=c[1],i=c[2];var d=c[5];return l=c[6],r=(a=t.custom?o===t.nData.nlead&&l===t.nData.nend:-1!==o.indexOf(t.nData.nlead)&&-1!==l.indexOf(t.nData.nend))?t.nData.isPercent:t.pData.isPercent,i=i.replace(Gpt,""),d&&(i+=d),s=+i,("percent"===t.type||r)&&(s/=100),(t.custom||t.fractionDigits)&&(s=parseFloat(s.toFixed(t.custom?a?t.nData.maximumFractionDigits:t.pData.maximumFractionDigits:t.fractionDigits))),t.maximumFractionDigits&&(s=this.convertMaxFracDigits(i,t,s,a)),a&&(s*=-1),s},e.convertMaxFracDigits=function(e,t,n,a){var r=e.split(".");return r[1]&&r[1].length>t.maximumFractionDigits&&(n=+n.toFixed(t.custom?a?t.nData.maximumFractionDigits:t.pData.maximumFractionDigits:t.maximumFractionDigits)),n},e}(),Xpt=function(){function e(e){this.ranArray=[],this.boundedEvents={},xpt(e)||(this.context=e)}return e.prototype.on=function(e,t,n,a){if(!xpt(t)){var r=n||this.context;this.notExist(e)?this.boundedEvents[e]=[{handler:t,context:r}]:xpt(a)?this.isHandlerPresent(this.boundedEvents[e],t)||this.boundedEvents[e].push({handler:t,context:r}):-1===this.ranArray.indexOf(a)&&(this.ranArray.push(a),this.boundedEvents[e].push({handler:t,context:r,id:a}))}},e.prototype.off=function(e,t,n){if(!this.notExist(e)){var a=fpt(e,this.boundedEvents);if(t){for(var r=0;r<a.length;r++)if(n){if(a[r].id===n){a.splice(r,1);var i=this.ranArray.indexOf(n);-1!==i&&this.ranArray.splice(i,1);break}}else if(t===a[r].handler){a.splice(r,1);break}}else delete this.boundedEvents[e]}},e.prototype.notify=function(e,t,n,a){if(this.notExist(e))n&&n.call(this,t);else{t&&(t.name=e);var r=fpt(e,this.boundedEvents).slice(0);if(window.Blazor)return this.blazorCallback(r,t,n,a,0);for(var i=0,o=r;i<o.length;i++){var l=o[i];l.handler.call(l.context,t)}n&&n.call(this,t)}},e.prototype.blazorCallback=function(e,t,n,a,r){var i=this,o=r===e.length-1;if(r<e.length){var l=e[r],s=l.handler.call(l.context,t);if(s&&"function"==typeof s.then){if(!n)return s;s.then(function(s){if(s="string"==typeof s&&i.isJson(s)?JSON.parse(s,i.dateReviver):s,bpt(t,t,s,!0),!n||!o)return i.blazorCallback(e,t,n,a,r+1);n.call(l.context,t)}).catch(function(e){a&&a.call(l.context,"string"==typeof e&&i.isJson(e)?JSON.parse(e,i.dateReviver):e)})}else{if(!n||!o)return this.blazorCallback(e,t,n,a,r+1);n.call(l.context,t)}}},e.prototype.dateReviver=function(e,t){return _pt&&"string"==typeof t&&null!==t.match(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}/)?new Date(t):t},e.prototype.isJson=function(e){try{JSON.parse(e)}catch(e){return!1}return!0},e.prototype.destroy=function(){this.boundedEvents=this.context=void 0},e.prototype.notExist=function(e){return!1===this.boundedEvents.hasOwnProperty(e)||this.boundedEvents[e].length<=0},e.prototype.isHandlerPresent=function(e,t){for(var n=0,a=e;n<a.length;n++){if(a[n].handler===t)return!0}return!1},e}(),Jpt=new Xpt,$pt={},eft="en-US",tft="USD",nft=["numericObject","dateObject"],aft=function(){function e(e){e&&(this.culture=e)}return e.prototype.getDateFormat=function(e){return Tpt.dateFormat(this.getCulture(),e||{type:"date",skeleton:"short"},$pt)},e.prototype.getNumberFormat=function(e){return e&&!e.currency&&(e.currency=tft),Wpt.numberFormatter(this.getCulture(),e||{},$pt)},e.prototype.getDateParser=function(e){return qpt.dateParser(this.getCulture(),e||{skeleton:"short",type:"date"},$pt)},e.prototype.getNumberParser=function(e){return Qpt.numberParser(this.getCulture(),e||{format:"N"},$pt)},e.prototype.formatNumber=function(e,t){return this.getNumberFormat(t)(e)},e.prototype.formatDate=function(e,t){return this.getDateFormat(t)(e)},e.prototype.parseDate=function(e,t){return this.getDateParser(t)(e)},e.prototype.parseNumber=function(e,t){return this.getNumberParser(t)(e)},e.prototype.getDatePattern=function(e,t){return rft.getActualDateTimeFormat(this.getCulture(),e,$pt,t)},e.prototype.getNumberPattern=function(e,t){return rft.getActualNumberFormat(this.getCulture(),e,$pt,t)},e.prototype.getFirstDayOfWeek=function(){return rft.getWeekData(this.getCulture(),$pt)},e.prototype.getCulture=function(){return this.culture||eft},e}();var rft,ift={"en-US":{d:"M/d/y",D:"EEEE, MMMM d, y",f:"EEEE, MMMM d, y h:mm a",F:"EEEE, MMMM d, y h:mm:s a",g:"M/d/y h:mm a",G:"M/d/yyyy h:mm:ss tt",m:"MMMM d",M:"MMMM d",r:"ddd, dd MMM yyyy HH':'mm':'ss 'GMT'",R:"ddd, dd MMM yyyy HH':'mm':'ss 'GMT'",s:"yyyy'-'MM'-'dd'T'HH':'mm':'ss",t:"h:mm tt",T:"h:m:s tt",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'",U:"dddd, MMMM d, yyyy h:mm:ss tt",y:"MMMM yyyy",Y:"MMMM yyyy"}};!function(e){e.negativeDataRegex=/^(('[^']+'|''|[^*#@0,.E])*)(\*.)?((([#,]*[0,]*0+)(\.0*[0-9]*#*)?)|([#,]*@+#*))(E\+?0+)?(('[^']+'|''|[^*#@0,.E])*)$/,e.customRegex=/^(('[^']+'|''|[^*#@0,.])*)(\*.)?((([0#,]*[0,]*[0#]*[0#\ ]*)(\.[0#]*)?)|([#,]*@+#*))(E\+?0+)?(('[^']+'|''|[^*#@0,.E])*)$/,e.latnParseRegex=/0|1|2|3|4|5|6|7|8|9/g;var t=/[0-9]/g;e.defaultCurrency="$";var n=["infinity","nan","group","decimal"],a=/G|M|L|H|c|'| a|yy|y|EEEE|E/g,r={G:"",M:"m",L:"m",H:"h",c:"d","'":'"'," a":" AM/PM",yy:"yy",y:"yyyy",EEEE:"dddd",E:"ddd"};e.dateConverterMapper=/dddd|ddd/gi;e.islamicRegex=/^islamic/;var i={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};e.formatRegex=/(^[ncpae]{1})([0-1]?[0-9]|20)?$/i,e.currencyFormatRegex=/(^[ca]{1})([0-1]?[0-9]|20)?$/i,e.curWithoutNumberRegex=/(c|a)$/gi;var o={$:"isCurrency","%":"isPercent","-":"isNegative",0:"nlead",1:"nend"};function l(t,n,a,r,i){var o,l=a||"date";if(i)o=h({skeleton:t},i).format||h({skeleton:"d"},"en-US").format;else{if(-1!==e.basicPatterns.indexOf(t)){if(o=fpt(l+"Formats."+t,n),"dateTime"===l){var s=fpt("dateFormats."+t,n),c=fpt("timeFormats."+t,n);o=o.replace("{1}",s).replace("{0}",c)}}else o=fpt("dateTimeFormats.availableFormats."+t,n);Ept(o)&&"yMd"===t&&(o="M/d/y")}return o}function s(t,n,a,r){var i={},o=a||"gregorian";if(i.parserObject=Dpt.getMainObject(t,n)||e.defaultObject,r)i.numericObject=fpt("numbers",i.parserObject);else{var l="dates.calendars."+o;i.dateObject=fpt(l,i.parserObject)}return i}function c(e,t,n,a){return fpt(e+"Formats-numberSystem-"+t+(a?".accounting":".standard"),n)||(a?fpt(e+"Formats-numberSystem-"+t+".standard",n):"")}function d(t){t.match(e.dateConverterMapper);return t}function h(e,t){var n=e.format||e.skeleton,a=fpt((t||"en-US")+"."+n,ift);return a||(a=fpt("en-US."+n,ift)),a&&(a=d(a),e.format=a.replace(/tt/,"a")),e}function u(t){var n=t.match(e.formatRegex),a={},r=n[1].toUpperCase();return a.isAccount="A"===r,a.type=e.patternMatcher[r],t.length>1&&(a.fractionDigits=parseInt(n[2],10)),a}function p(n,a,r,i){var o=i?{}:{nlead:"",nend:""},l=n.match(e.customRegex);if(l){i||(o.nlead=f(l[1],r),o.nend=f(l[10],r),o.groupPattern=l[4]);var s=l[7];if(s&&a){var c=s.match(t);xpt(c)?o.minimumFraction=0:o.minimumFraction=c.length,o.maximumFraction=s.length-1}}return o}function f(t,n){return t?t.replace(e.defaultCurrency,n):""}function m(e,t,n){return fpt("currencies."+t+(n?"."+n:".symbol"),e)||fpt("currencies."+t+".symbol-alt-narrow",e)||"$"}function v(t,a,r){var i={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},o=t.match(e.customRegex);if(xpt(o)||""===o[5]&&"N/A"!==t)return i.type=void 0,i;i.nlead=o[1],i.nend=o[10];var l=o[6],s=!!l.match(/\ $/g),d=-1!==l.replace(/\ $/g,"").indexOf(" ");i.useGrouping=-1!==l.indexOf(",")||d,l=l.replace(/,/g,"");var h=o[7];if(-1!==l.indexOf("0")&&(i.minimumIntegerDigits=l.length-l.indexOf("0")),xpt(h)||(i.minimumFractionDigits=h.lastIndexOf("0"),i.maximumFractionDigits=h.lastIndexOf("#"),-1===i.minimumFractionDigits&&(i.minimumFractionDigits=0),(-1===i.maximumFractionDigits||i.maximumFractionDigits<i.minimumFractionDigits)&&(i.maximumFractionDigits=i.minimumFractionDigits)),xpt(a)?bpt(i,g([i.nlead,i.nend],"%","%")):(bpt(i,g([i.nlead,i.nend],"$",a.currencySymbol)),i.isCurrency||bpt(i,g([i.nlead,i.nend],"%",a.percentSymbol))),!xpt(r)){var u=c(i.type,a.numberMapper.numberSystem,r,!1);i.useGrouping&&(i.groupSeparator=d?" ":a.numberMapper.numberSymbols[n[2]],i.groupData=Wpt.getGroupingDetails(u.split(";")[0])),i.nlead=i.nlead.replace(/'/g,""),i.nend=s?" "+i.nend.replace(/'/g,""):i.nend.replace(/'/g,"")}return i}function g(e,t,n){for(var a={nlead:e[0],nend:e[1]},r=0;r<2;r++){var i=e[r],l=i.indexOf(t);if(-1!==l&&(l<i.indexOf("'")||l>i.lastIndexOf("'"))){a[o[r]]=i.substr(0,l)+n+i.substr(l+1),a[o[t]]=!0,a.type=a.isCurrency?"currency":"percent";break}}return a}function w(e,t,n){e+=".";for(var a=0;a<t;a++)e+="0";if(t<n)for(var r=n-t,i=0;i<r;i++)e+="#";return e}function y(e,t){for(var n=e.split("."),a="",r=0;r<t;r++)a+="0";return n[1]?a+"."+n[1]:a}function b(e){var t=e.split("."),n=t[0],a=3-n.length%3;e="";for(var r=(n=(a&&1===a?"#":2===a?"##":"")+n).length-1;r>0;r-=3)e=","+n[r-2]+n[r-1]+n[r]+e;return e=e.slice(1),t[1]?e+"."+t[1]:e}e.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,e.basicPatterns=["short","medium","long","full"],e.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhuʻl-Q.",12:"Dhuʻl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabiʻ I",4:"Rabiʻ II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Shaʻban",9:"Ramadan",10:"Shawwal",11:"Dhuʻl-Qiʻdah",12:"Dhuʻl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"€","symbol-alt-narrow":"€"},GBP:{displayName:"British Pound","symbol-alt-narrow":"£"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"×",perMille:"‰",infinity:"∞",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"¤#,##0.00",accounting:"¤#,##0.00;(¤#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},e.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"∞"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},e.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},e.month="months",e.days="days",e.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},e.getResultantPattern=l,e.getDependables=s,e.getSymbolPattern=c,e.ConvertDateToWeekFormat=d,e.compareBlazorDateFormats=h,e.getProperNumericSkeleton=u,e.getFormatData=p,e.changeCurrencySymbol=f,e.getCurrencySymbol=m,e.customFormat=function(e,t,n){for(var a={},r=e.split(";"),i=["pData","nData","zeroData"],o=0;o<r.length;o++)a[i[o]]=v(r[o],t,n);return xpt(a.nData)&&(a.nData=bpt({},a.pData),a.nData.nlead=xpt(t)?"-"+a.nData.nlead:t.minusSymbol+a.nData.nlead),a},e.customNumberFormat=v,e.isCurrencyPercent=g,e.getDateSeparator=function(e){var t=(fpt("dateFormats.short",e)||"").match(/[d‏M‏]([^d‏M])[d‏M‏]/i);return t?t[1]:"/"},e.getActualDateTimeFormat=function(e,t,n,i){var o=s(n,e,t.calendar),c=t.format||l(t.skeleton,o.dateObject,t.type);if(i){if(c=c.replace(a,function(e){return r[e]}),-1!==c.indexOf("z")){var d=c.match(/z/g).length,h=void 0,u={timeZone:{}};u.numMapper=Dpt.getNumberMapper(o.parserObject,Dpt.getNumberingSystem(n)),u.timeZone=fpt("dates.timeZoneNames",o.parserObject);var p=(new Date).getTimezoneOffset(),f=d<4?"+H;-H":u.timeZone.hourFormat;f=f.replace(/:/g,u.numMapper.timeSeparator),0===p?h=u.timeZone.gmtZeroFormat:(h=Tpt.getTimeZoneValue(p,f),h=u.timeZone.gmtFormat.replace(/\{0\}/,h)),c=c.replace(/[z]+/,'"'+h+'"')}c=c.replace(/ $/,"")}return c},e.getActualNumberFormat=function(t,n,a,r){var i,o=s(a,t,"",!0),l={custom:!0};o.numericObject;var d={},h=(n.format||"").match(e.currencyFormatRegex);!e.formatRegex.test(n.format)||u(n.format||"N");var f,v={};if(h){v.numberMapper=Dpt.getNumberMapper(o.parserObject,Dpt.getNumberingSystem(a),!0);var g=m(o.numericObject,n.currency||tft,n.altSymbol),x=c("currency",v.numberMapper.numberSystem,o.numericObject,/a/i.test(n.format)),E=(x=x.replace(/\u00A4/g,g)).split(";");d.hasNegativePattern=E.length>1,d.nData=p(E[1]||"-"+E[0],!0,g),d.pData=p(E[0],!1,g),h[2]||n.minimumFractionDigits||n.maximumFractionDigits||(i=p(x.split(";")[0],!0,"",!0).minimumFraction)}if(e.formatRegex.test(n.format)||!n.format){if(bpt(l,u(n.format||"N")),l.custom=!1,f="###0",l.fractionDigits||n.minimumFractionDigits||n.maximumFractionDigits||i){l.fractionDigits&&(n.minimumFractionDigits=n.maximumFractionDigits=l.fractionDigits),f=w(f,i||l.fractionDigits||n.minimumFractionDigits||0,n.maximumFractionDigits||0)}if(n.minimumIntegerDigits&&(f=y(f,n.minimumIntegerDigits)),n.useGrouping&&(f=b(f)),"currency"===l.type||(l.type,0)){var k=f;f=d.pData.nlead+k+d.pData.nend,d.hasNegativePattern&&(f+=";"+d.nData.nlead+k+d.nData.nend)}"percent"===l.type&&(f+=" %")}else f=n.format.replace(/'/g,'"');return Object.keys(v).length>0&&(f=r?f:function(e,t){if(-1!==e.indexOf(",")){var n=e.split(",");e=n[0]+fpt("numberMapper.numberSymbols.group",t)+n[1].replace(".",fpt("numberMapper.numberSymbols.decimal",t))}else e=e.replace(".",fpt("numberMapper.numberSymbols.decimal",t));return e}(f,v)),f},e.fractionDigitsPattern=w,e.minimumIntegerPattern=y,e.groupingPattern=b,e.getWeekData=function(e,t){var n="sun",a=fpt("supplemental.weekData.firstDay",t),r=e;return/en-/.test(r)&&(r=r.slice(3)),r=r.slice(0,2).toUpperCase()+r.substr(2),a&&(n=a[r]||a[r.slice(0,2)]||"sun"),i[n]},e.replaceBlazorCurrency=function(e,t,n){var a=fpt(n||"",Npt);if(t!==a)for(var r=0,i=e;r<i.length;r++){var o=i[r];o.nend=o.nend.replace(t,a),o.nlead=o.nlead.replace(t,a)}},e.getWeekOfYear=function(e){var t,n=new Date(e.getFullYear(),0,1),a=n.getDay();a=a>=0?a:a+7;var r=Math.floor((e.getTime()-n.getTime()-6e4*(e.getTimezoneOffset()-n.getTimezoneOffset()))/864e5)+1;if(a<4){if((t=Math.floor((r+a-1)/7)+1)>52){var i=new Date(e.getFullYear()+1,0,1).getDay();t=(i=i>=0?i:i+7)<4?1:53}}else t=Math.floor((r+a-1)/7);return t}}(rft||(rft={}));var oft=/^(.*?):[ \t]*([^\r\n]*)$/gm,lft=function(){function e(e,t,n,a){this.mode=!0,this.emitError=!0,this.options={},"string"==typeof e?(this.url=e,this.type=t?t.toUpperCase():"GET",this.mode=!!xpt(n)||n):"object"==typeof e&&(this.options=e,ypt(this,this.options)),this.type=this.type?this.type.toUpperCase():"GET",this.contentType=void 0!==this.contentType?this.contentType:a}return e.prototype.send=function(e){var t=this;this.data=xpt(e)?this.data:e;var n={cancel:!1,httpRequest:null};return new Promise(function(e,a){t.httpRequest=new XMLHttpRequest,t.httpRequest.onreadystatechange=function(){t.stateChange(e,a)},xpt(t.onLoad)||(t.httpRequest.onload=t.onLoad),xpt(t.onProgress)||(t.httpRequest.onprogress=t.onProgress),xpt(t.onAbort)||(t.httpRequest.onabort=t.onAbort),xpt(t.onError)||(t.httpRequest.onerror=t.onError),xpt(t.onUploadProgress)||(t.httpRequest.upload.onprogress=t.onUploadProgress),t.httpRequest.open(t.type,t.url,t.mode),xpt(t.data)||null===t.contentType||t.httpRequest.setRequestHeader("Content-Type",t.contentType||"application/json; charset=utf-8"),t.beforeSend&&(n.httpRequest=t.httpRequest,t.beforeSend(n)),n.cancel||t.httpRequest.send(xpt(t.data)?null:t.data)})},e.prototype.successHandler=function(e){return this.onSuccess&&this.onSuccess(e,this),e},e.prototype.failureHandler=function(e){return this.onFailure&&this.onFailure(this.httpRequest),e},e.prototype.stateChange=function(e,t){var n=this.httpRequest.responseText;if(this.dataType&&"json"===this.dataType.toLowerCase())if(""===n)n=void 0;else try{n=JSON.parse(n)}catch(e){}4===this.httpRequest.readyState&&(this.httpRequest.status>=200&&this.httpRequest.status<=299||304===this.httpRequest.status?e(this.successHandler(n)):this.emitError?t(new Error(this.failureHandler(this.httpRequest.statusText))):e())},e.prototype.getResponseHeader=function(e){var t,n;t={};for(var a=oft.exec(this.httpRequest.getAllResponseHeaders());a;)t[a[1].toLowerCase()]=a[2],a=oft.exec(this.httpRequest.getAllResponseHeaders());return xpt(n=t[e.toLowerCase()])?null:n},e}(),sft=/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini|mobile/i,cft=/msie|trident/i,dft=/Trident\/7\./,hft=/(ipad|iphone|ipod touch)/i,uft=/(ipad|iphone|ipod touch);.*os 7_\d|(ipad|iphone|ipod touch);.*os 8_\d/i,pft=/android/i,fft=/trident|windows phone|edge/i,mft=/(version)[ /]([\w.]+)/i,vft={OPERA:/(opera|opr)(?:.*version|)[ /]([\w.]+)/i,EDGE:/(edge)(?:.*version|)[ /]([\w.]+)/i,CHROME:/(chrome|crios)[ /]([\w.]+)/i,PANTHOMEJS:/(phantomjs)[ /]([\w.]+)/i,SAFARI:/(safari)[ /]([\w.]+)/i,WEBKIT:/(webkit)[ /]([\w.]+)/i,MSIE:/(msie|trident) ([\w.]+)/i,MOZILLA:/(mozilla)(?:.*? rv:([\w.]+)|)/i};"undefined"!=typeof window&&(window.browserDetails=window.browserDetails||{});var gft=function(){function e(){}return e.extractBrowserDetail=function(){for(var t={culture:{}},n=[],a=0,r=Object.keys(vft);a<r.length;a++){var i=r[a];if(n=e.userAgent.match(vft[i])){if(t.name="opr"===n[1].toLowerCase()?"opera":n[1].toLowerCase(),t.name="crios"===n[1].toLowerCase()?"chrome":t.name,t.version=n[2],t.culture.name=t.culture.language=navigator.language,e.userAgent.match(dft)){t.name="msie";break}var o=e.userAgent.match(mft);"safari"===t.name&&o&&(t.version=o[2]);break}}return t},e.getEvent=function(t){var n={start:{isPointer:"pointerdown",isTouch:"touchstart",isDevice:"mousedown"},move:{isPointer:"pointermove",isTouch:"touchmove",isDevice:"mousemove"},end:{isPointer:"pointerup",isTouch:"touchend",isDevice:"mouseup"},cancel:{isPointer:"pointercancel",isTouch:"touchcancel",isDevice:"mouseleave"}};return e.isPointer?n[t].isPointer:e.isTouch?n[t].isTouch+(e.isDevice?"":" "+n[t].isDevice):n[t].isDevice},e.getTouchStartEvent=function(){return e.getEvent("start")},e.getTouchEndEvent=function(){return e.getEvent("end")},e.getTouchMoveEvent=function(){return e.getEvent("move")},e.getTouchCancelEvent=function(){return e.getEvent("cancel")},e.getValue=function(t,n){var a=window.browserDetails;return"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===e.isTouch&&(a.isIos=!0,a.isDevice=!0,a.isTouch=!0,a.isPointer=!0),void 0===a[t]?a[t]=n.test(e.userAgent):a[t]},Object.defineProperty(e,"userAgent",{get:function(){return e.uA},set:function(t){e.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(e,"info",{get:function(){return Ept(window.browserDetails.info)?window.browserDetails.info=e.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isIE",{get:function(){return e.getValue("isIE",cft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isTouch",{get:function(){return Ept(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isPointer",{get:function(){return Ept(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isMSPointer",{get:function(){return Ept(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isDevice",{get:function(){return e.getValue("isDevice",sft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isIos",{get:function(){return e.getValue("isIos",hft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isIos7",{get:function(){return e.getValue("isIos7",uft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isAndroid",{get:function(){return e.getValue("isAndroid",pft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isWebView",{get:function(){return Ept(window.browserDetails.isWebView)?(window.browserDetails.isWebView=!(Ept(window.cordova)&&Ept(window.PhoneGap)&&Ept(window.phonegap)&&"object"!==window.forge),window.browserDetails.isWebView):window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isWindows",{get:function(){return e.getValue("isWindows",fft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchStartEvent",{get:function(){return Ept(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=e.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchMoveEvent",{get:function(){return Ept(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=e.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchEndEvent",{get:function(){return Ept(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=e.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchCancelEvent",{get:function(){return Ept(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=e.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),e.uA="undefined"!=typeof navigator?navigator.userAgent:"",e}(),wft=function(){function e(){}return e.addOrGetEventData=function(e){return"__eventList"in e?e.__eventList.events:(e.__eventList={},e.__eventList.events=[])},e.add=function(t,n,a,r,i){var o,l,s,c,d=e.addOrGetEventData(t);i?(l=a,s=i,o=function(){var e=this,t=arguments;clearTimeout(c),c=setTimeout(function(){return c=null,l.apply(e,t)},s)}):o=a,r&&(o=o.bind(r));for(var h=n.split(" "),u=0;u<h.length;u++)d.push({name:h[u],listener:a,debounce:o}),gft.isIE?t.addEventListener(h[u],o):t.addEventListener(h[u],o,{passive:!1});return o},e.remove=function(t,n,a){for(var r=e.addOrGetEventData(t),i=n.split(" "),o=function(e){var n,o=-1;r&&0!==r.length&&r.some(function(t,r){return t.name===i[e]&&t.listener===a&&(o=r,n=t.debounce,!0)}),-1!==o&&r.splice(o,1),n&&t.removeEventListener(i[e],n)},l=0;l<i.length;l++)o(l)},e.clearEvents=function(t){var n,a;a=bpt([],a,n=e.addOrGetEventData(t));for(var r=0;r<a.length;r++)t.removeEventListener(a[r].name,a[r].debounce),n.shift()},e.trigger=function(t,n,a){for(var r=0,i=e.addOrGetEventData(t);r<i.length;r++){var o=i[r];o.name===n&&o.debounce.call(this,a)}},e}(),yft=/^svg|^path|^g/;function bft(e,t){var n=yft.test(e)?document.createElementNS("http://www.w3.org/2000/svg",e):document.createElement(e);return void 0===t||(n.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(n.className=t.className),void 0!==t.id&&(n.id=t.id),void 0!==t.styles&&n.setAttribute("style",t.styles),void 0!==t.attrs&&Hft(n,t.attrs)),n}function xft(e,t){for(var n=kft(t),a=0,r=e;a<r.length;a++)for(var i=r[a],o=0,l=n;o<l.length;o++){var s=l[o];if(wpt(i)){var c=fpt("attributes.className",i);xpt(c)?mpt("attributes.className",s,i):new RegExp("\\b"+s+"\\b","i").test(c)||mpt("attributes.className",c+" "+s,i)}else i.classList.contains(s)||i.classList.add(s)}return e}function Eft(e,t){for(var n=kft(t),a=0,r=e;a<r.length;a++){var i=r[a],o=wpt(i);if(o?fpt("attributes.className",i):""!==i.className)for(var l=0,s=n;l<s.length;l++){var c=s[l];if(o){var d=fpt("attributes.className",i).split(" "),h=d.indexOf(c);-1!==h&&d.splice(h,1),mpt("attributes.className",d.join(" "),i)}else i.classList.remove(c)}}return e}function kft(e){var t=[];return"string"==typeof e?t.push(e):t=e,t}function Mft(e){var t=e;return""===t.style.visibility&&t.offsetWidth>0}function Sft(e,t,n){for(var a=document.createDocumentFragment(),r=0,i=e;r<i.length;r++){var o=i[r];a.appendChild(o)}return t.insertBefore(a,t.firstElementChild),n&&_ft(t),e}function Aft(e,t,n){for(var a=document.createDocumentFragment(),r=0,i=e;r<i.length;r++){var o=i[r];a.appendChild(o)}return t.appendChild(a),n&&_ft(t),e}function _ft(e){e.querySelectorAll("script").forEach(function(e){var t=document.createElement("script");t.text=e.innerHTML,document.head.appendChild(t),Cft(t)})}function Cft(e){var t=e.parentNode;if(t)return t.removeChild(e)}function Zft(e){var t=e.parentNode;wft.clearEvents(e),t.removeChild(e)}function Hft(e,t){for(var n=e,a=0,r=Object.keys(t);a<r.length;a++){var i=r[a];if(wpt(n)){var o=i;"tabindex"===i&&(o="tabIndex"),n.attributes[o]=t[i]}else n.setAttribute(i,t[i])}return n}function Ift(e,t,n){return void 0===t&&(t=document),e=Nft(e),t.querySelector(e)}function Dft(e,t,n){return void 0===t&&(t=document),e=Nft(e),t.querySelectorAll(e)}function Nft(e){var t=/(!|"|\$|%|&|'|\(|\)|\*|\/|:|;|<|=|\?|@|\]|\^|`|{|}|\||\+|~)/g;if(e.match(/#[0-9]/g)||e.match(t)){for(var n=e.split(","),a=0;a<n.length;a++){for(var r=n[a].split(" "),i=0;i<r.length;i++)if(r[i].indexOf("#")>-1&&!r[i].match(/\[.*\]/)){var o=r[i].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var l=r[i].split(".");l[0]=l[0].replace(/#/,"[id='")+"']",r[i]=l.join(".")}}n[a]=r.join(" ")}return n.join(",")}return e}function Oft(e,t){var n=e;if("function"==typeof n.closest)return n.closest(t);for(;n&&1===n.nodeType;){if(Vft(n,t))return n;n=n.parentNode}return null}function Lft(e,t){void 0!==t&&Object.keys(t).forEach(function(n){e.style[n]=t[n]})}function Vft(e,t){var n=e.matches||e.msMatchesSelector||e.webkitMatchesSelector;return n?n.call(e,t):-1!==[].indexOf.call(document.querySelectorAll(t),e)}var zft=new RegExp("]"),Pft=function(){function e(e,t){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Xpt(this),Ept(t)||(this.element="string"==typeof t?document.querySelector(t):t,xpt(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),Ept(e)||this.setProperties(e,!0),this.isDestroyed=!1}return e.prototype.setProperties=function(e,t){var n=this.isProtectedOnChange;this.isProtectedOnChange=!!t,ypt(this,e),!0!==t&&(ypt(this.changedProperties,e),this.dataBind()),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=n},e.callChildDataBind=function(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){var r=a[n];if(t[r]instanceof Array)for(var i=0,o=t[r];i<o.length;i++){var l=o[i];void 0!==l.dataBind&&l.dataBind()}else t[r].dataBind()}},e.prototype.clearChanges=function(){this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.childChangedProperties={}},e.prototype.dataBind=function(){if(e.callChildDataBind(this.childChangedProperties,this),Object.getOwnPropertyNames(this.changedProperties).length){var t=this.isProtectedOnChange,n=this.changedProperties,a=this.oldProperties;this.clearChanges(),this.isProtectedOnChange=!0,this.onPropertyChanged(n,a),this.isProtectedOnChange=t}},e.prototype.serverDataBind=function(e){},e.prototype.saveChanges=function(e,t,n){this.isProtectedOnChange||(this.oldProperties[e]=n,this.changedProperties[e]=t,this.finalUpdate(),this.finalUpdate=function(e){var t,n=new Uint16Array(5);(window.msCrypto||window.crypto).getRandomValues(n);var a="ej2"+function(e){for(var t="",n=0;n<5;n++)t+=(n?",":"")+e[n];return t}(n),r=function(n){n.source===window&&"string"==typeof n.data&&n.data.length<=32&&n.data===a&&(e(),t())};return window.addEventListener("message",r,!1),window.postMessage(a,"*"),t=function(){window.removeEventListener("message",r),e=r=a=void 0}}(this.dataBind.bind(this)))},e.prototype.addEventListener=function(e,t){this.modelObserver.on(e,t)},e.prototype.removeEventListener=function(e,t){this.modelObserver.off(e,t)},e.prototype.trigger=function(e,t,n,a){var r=this;if(!0!==this.isDestroyed){var i=this.isProtectedOnChange;this.isProtectedOnChange=!1;var o=this.modelObserver.notify(e,t,n,a);if(zft.test(e)){var l=fpt(e,this);if(l){if(window.Blazor){var s=l.call(this,t);s&&"function"==typeof s.then?n?s.then(function(e){n&&(e="string"==typeof e&&r.modelObserver.isJson(e)?JSON.parse(e):e,n.call(r,e))}).catch(function(e){a&&(e="string"==typeof e&&r.modelObserver.isJson(e)?JSON.parse(e):e,a.call(r,e))}):o=s:n&&n.call(this,t)}else l.call(this,t),n&&n.call(this,t)}else n&&n.call(this,t)}return this.isProtectedOnChange=i,o}},e.prototype.addInstance=function(){var e="e-"+this.getModuleName().toLowerCase();xft([this.element],["e-lib",e]),xpt(this.element.ej2_instances)?mpt("ej2_instances",[this],this.element):this.element.ej2_instances.push(this)},e.prototype.destroy=function(){var e=this;this.element.ej2_instances=this.element.ej2_instances.filter(function(t){return t!==e}),Eft([this.element],["e-"+this.getModuleName()]),0===this.element.ej2_instances.length&&Eft([this.element],["e-lib"]),this.clearChanges(),this.modelObserver.destroy(),this.isDestroyed=!0},e}();function Tft(e,t,n,a){return e.properties.hasOwnProperty(t)&&e.properties[t]instanceof a||(e.properties[t]=ppt(a,[e,t,n])),e.properties[t]}function Bft(e,t,n,a,r,i){for(var o=[],l=n?n.length:0,s=0;s<l;s++){var c=a;if(i&&(c=a(n[s],e)),r){var d=ppt(c,[e,t,{},!0]);d.setProperties(n[s],!0),o.push(d)}else o.push(ppt(c,[e,t,n[s],!1]))}return o}function jft(e,t){return function(){return this.properties.hasOwnProperty(t)||(this.properties[t]=e),this.properties[t]}}function Wft(e,t){return function(n){if(this.properties[t]!==n){var a=this.properties.hasOwnProperty(t)?this.properties[t]:e;this.saveChanges(t,n,a),this.properties[t]=n}}}function Rft(e,t,n){return function(){return Tft(this,t,e,n)}}function Fft(e,t,n){return function(a){Tft(this,t,e,n).setProperties(a)}}function Yft(e,t,n){return function(){var a=this;if(!this.properties.hasOwnProperty(t)){var r=Bft(this,t,e,n,!1);this.properties[t]=r}var i=void 0!==this.controlParent&&this.controlParent.ignoreCollectionWatch||this.ignoreCollectionWatch;return this.properties[t].hasOwnProperty("push")||i||["push","pop"].forEach(function(e){var r={value:Uft(e,t,n,a.properties[t]).bind(a),configurable:!0};Object.defineProperty(a.properties[t],e,r)}),this.properties[t].hasOwnProperty("isComplexArray")||Object.defineProperty(this.properties[t],"isComplexArray",{value:!0}),this.properties[t]}}function qft(e,t,n){return function(a){this.isComplexArraySetter=!0;var r=Bft(this,t,e,n,!1),i=Bft(this,t,a,n,!0);this.isComplexArraySetter=!1,this.saveChanges(t,i,r),this.properties[t]=i}}function Uft(e,t,n,a){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var i=this.propName?this.getParentKey()+"."+t+"-":t+"-";switch(e){case"push":for(var o=0;o<n.length;o++){Array.prototype[e].apply(a,[n[o]]);var l=Gft(i+(a.length-1),n[o],!this.controlParent,e);this.serverDataBind(l,n[o],!1,e)}break;case"pop":Array.prototype[e].apply(a);var s=Gft(i+a.length,null,!this.controlParent,e);this.serverDataBind(s,{ejsAction:"pop"},!1,e)}return a}}function Gft(e,t,n,a){var r=e;if(n&&((r={})[e]=t,t&&"object"==typeof t)){r[e].ejsAction=a}return r}function Kft(e){return function(t,n){var a={set:Wft(e,n),get:jft(e,n),enumerable:!0,configurable:!0};Object.defineProperty(t,n,a),emt(t,n,"prop",e)}}function Qft(e,t){return function(n,a){var r={set:Fft(e,a,t),get:Rft(e,a,t),enumerable:!0,configurable:!0};Object.defineProperty(n,a,r),emt(n,a,"complexProp",e,t)}}function Xft(e,t){return function(n,a){var r={set:qft(e,a,t),get:Yft(e,a,t),enumerable:!0,configurable:!0};Object.defineProperty(n,a,r),emt(n,a,"colProp",e,t)}}function Jft(){return function(e,t){var n={set:function(e){var n=this.properties[t];if(n!==e){var a=tmt(this,t);!1===Ept(n)&&a.context.removeEventListener(a.prefix,n),a.context.addEventListener(a.prefix,e),this.properties[t]=e}},get:jft(void 0,t),enumerable:!0,configurable:!0};Object.defineProperty(e,t,n),emt(e,t,"event")}}function $ft(e){}function emt(e,t,n,a,r){Ept(e.propList)&&(e.propList={props:[],complexProps:[],colProps:[],events:[],propNames:[],complexPropNames:[],colPropNames:[],eventNames:[]}),e.propList[n+"s"].push({propertyName:t,defaultValue:a,type:r}),e.propList[n+"Names"].push(t)}function tmt(e,t){if(!1===e.hasOwnProperty("parentObj"))return{context:e,prefix:t};var n=fpt("propName",e);return n&&(t=n+"-"+t),tmt(fpt("parentObj",e),t)}var nmt,amt=(nmt=function(e,t){return nmt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},nmt(e,t)},function(e,t){function n(){this.constructor=e}nmt(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),rmt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},imt=function(e){function t(t){var n=e.call(this,t,void 0)||this;return n.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},n}var n;return amt(t,e),n=t,t.prototype.animate=function(e,t){t=t||{};var a=this.getModel(t);if("string"==typeof e)for(var r=0,i=Array.prototype.slice.call(Dft(e,document));r<i.length;r++){var o=i[r];a.element=o,n.delayAnimation(a)}else a.element=e,n.delayAnimation(a)},t.stop=function(e,t){e.style.animation="",e.removeAttribute("e-animate");var n=e.getAttribute("e-animation-id");if(n){var a=parseInt(n,10);cancelAnimationFrame(a),e.removeAttribute("e-animation-id")}t&&t.end&&t.end.call(this,t)},t.delayAnimation=function(e){"Disable"===umt?(e.begin&&e.begin.call(this,e),e.end&&e.end.call(this,e)):e.delay?setTimeout(function(){n.applyAnimation(e)},e.delay):n.applyAnimation(e)},t.applyAnimation=function(e){var t=this;e.timeStamp=0;var n=0,a=0,r=0,i=e.duration;e.element.setAttribute("e-animate","true");var o=function(l){try{if(l){r=0===r?l:r,e.timeStamp=l+e.timeStamp-r,r=l,!n&&e.begin&&e.begin.call(t,e),n+=1;var s=e.timeStamp/n;e.timeStamp<i&&e.timeStamp+s<i&&e.element.getAttribute("e-animate")?(e.element.style.animation=e.name+" "+e.duration+"ms "+e.timingFunction,e.progress&&e.progress.call(t,e),requestAnimationFrame(o)):(cancelAnimationFrame(a),e.element.removeAttribute("e-animation-id"),e.element.removeAttribute("e-animate"),e.element.style.animation="",e.end&&e.end.call(t,e))}else a=requestAnimationFrame(o),e.element.setAttribute("e-animation-id",a.toString())}catch(n){cancelAnimationFrame(a),e.element.removeAttribute("e-animation-id"),e.fail&&e.fail.call(t,n)}};o()},t.prototype.getModel=function(e){return{name:e.name||this.name,delay:e.delay||this.delay,duration:void 0!==e.duration?e.duration:this.duration,begin:e.begin||this.begin,end:e.end||this.end,fail:e.fail||this.fail,progress:e.progress||this.progress,timingFunction:this.easing[e.timingFunction]?this.easing[e.timingFunction]:e.timingFunction||this.easing[this.timingFunction]}},t.prototype.onPropertyChanged=function(e,t){},t.prototype.getModuleName=function(){return"animation"},t.prototype.destroy=function(){},rmt([Kft("FadeIn")],t.prototype,"name",void 0),rmt([Kft(400)],t.prototype,"duration",void 0),rmt([Kft("ease")],t.prototype,"timingFunction",void 0),rmt([Kft(0)],t.prototype,"delay",void 0),rmt([Jft()],t.prototype,"progress",void 0),rmt([Jft()],t.prototype,"begin",void 0),rmt([Jft()],t.prototype,"end",void 0),rmt([Jft()],t.prototype,"fail",void 0),t=n=rmt([$ft],t)}(Pft);function omt(e,t,n){var a=function(e){var t={selector:e&&e.selector?e.selector:null,ignore:e&&e.ignore?e.ignore:null,rippleFlag:e&&e.rippleFlag,isCenterRipple:e&&e.isCenterRipple,duration:e&&e.duration?e.duration:350};return t}(t);return!1===a.rippleFlag||void 0===a.rippleFlag&&!hmt?function(){}:(e.setAttribute("data-ripple","true"),wft.add(e,"mousedown",lmt,{parent:e,rippleOptions:a}),wft.add(e,"mouseup",smt,{parent:e,rippleOptions:a,done:n}),wft.add(e,"mouseleave",cmt,{parent:e,rippleOptions:a}),gft.isPointer&&wft.add(e,"transitionend",cmt,{parent:e,rippleOptions:a}),function(){e.removeAttribute("data-ripple"),wft.remove(e,"mousedown",lmt),wft.remove(e,"mouseup",smt),wft.remove(e,"mouseleave",cmt),wft.remove(e,"transitionend",cmt)})}function lmt(e){var t=e.target,n=this.rippleOptions.selector,a=n?Oft(t,n):t;if(!(!a||this.rippleOptions&&Oft(t,this.rippleOptions.ignore))){var r=a.getBoundingClientRect(),i=e.pageX-document.body.scrollLeft,o=e.pageY-(!document.body.scrollTop&&document.documentElement?document.documentElement.scrollTop:document.body.scrollTop),l=Math.max(Math.abs(i-r.left),Math.abs(i-r.right)),s=Math.max(Math.abs(o-r.top),Math.abs(o-r.bottom)),c=Math.sqrt(l*l+s*s),d=2*c+"px",h=i-r.left-c,u=o-r.top-c;this.rippleOptions&&this.rippleOptions.isCenterRipple&&(h=0,u=0,d="100%"),a.classList.add("e-ripple");var p=bft("div",{className:"e-ripple-element",styles:"width: "+d+";height: "+d+";left: "+h+"px;top: "+u+"px;transition-duration: "+this.rippleOptions.duration.toString()+"ms;"});a.appendChild(p),window.getComputedStyle(p).getPropertyValue("opacity"),p.style.transform="scale(1)",a!==this.parent&&wft.add(a,"mouseleave",cmt,{parent:this.parent,rippleOptions:this.rippleOptions})}}function smt(e){dmt(e,this)}function cmt(e){dmt(e,this)}function dmt(e,t){var n=t.rippleOptions.duration,a=e.target,r=t.rippleOptions.selector,i=r?Oft(a,r):a;if(i&&(!i||-1!==i.className.indexOf("e-ripple"))){var o=Dft(".e-ripple-element",i),l=o[o.length-1];l&&(l.style.opacity="0.5"),t.parent!==i&&wft.remove(i,"mouseleave",cmt),setTimeout(function(){l&&l.parentNode&&l.parentNode.removeChild(l),i.getElementsByClassName("e-ripple-element").length||i.classList.remove("e-ripple"),t.done&&t.done(e)},n)}}var hmt=!1,umt="",pmt=function(){function e(e){this.loadedModules=[],this.parent=e}return e.prototype.inject=function(e,t){var n=e.length;if(0!==n){this.loadedModules.length&&this.clearUnusedModule(e);for(var a=0;a<n;a++)for(var r=e[a],i=0,o=t;i<o.length;i++){var l=o[i],s=r.member;if(l.prototype.getModuleName()===r.member&&!this.isModuleLoaded(s)){var c=ppt(l,r.args),d=this.getMemberName(s);r.isProperty?mpt(d,l,this.parent):mpt(d,c,this.parent);var h=r;h.member=d,this.loadedModules.push(h)}}}else this.clean()},e.prototype.clean=function(){for(var e=0,t=this.loadedModules;e<t.length;e++){var n=t[e];n.isProperty||fpt(n.member,this.parent).destroy()}this.loadedModules=[]},e.prototype.clearUnusedModule=function(e){for(var t=this,n=e.map(function(e){return t.getMemberName(e.member)}),a=0,r=this.loadedModules.filter(function(e){return-1===n.indexOf(e.member)});a<r.length;a++){var i=r[a];i.isProperty||fpt(i.member,this.parent).destroy(),this.loadedModules.splice(this.loadedModules.indexOf(i),1),vpt(this.parent,i.member)}},e.prototype.getMemberName=function(e){return e[0].toLowerCase()+e.substring(1)+"Module"},e.prototype.isModuleLoaded=function(e){for(var t=0,n=this.loadedModules;t<n.length;t++){if(n[t].member===this.getMemberName(e))return!0}return!1},e}(),fmt=function(){function e(e,t,n,a){this.isComplexArraySetter=!1,this.properties={},this.changedProperties={},this.childChangedProperties={},this.oldProperties={},this.finalUpdate=function(){},this.callChildDataBind=fpt("callChildDataBind",Pft),this.parentObj=e,this.controlParent=this.parentObj.controlParent||this.parentObj,this.propName=t,this.isParentArray=a,this.setProperties(n,!0)}return e.prototype.updateChange=function(e,t){!0===e?this.parentObj.childChangedProperties[t]=e:delete this.parentObj.childChangedProperties[t],this.parentObj.updateChange&&this.parentObj.updateChange(e,this.parentObj.propName)},e.prototype.updateTimeOut=function(){if(this.parentObj.updateTimeOut)this.parentObj.finalUpdate(),this.parentObj.updateTimeOut();else{var e=setTimeout(this.parentObj.dataBind.bind(this.parentObj));this.finalUpdate=function(){clearTimeout(e)}}},e.prototype.clearChanges=function(){this.finalUpdate(),this.updateChange(!1,this.propName),this.oldProperties={},this.changedProperties={}},e.prototype.setProperties=function(e,t){!0===t?(ypt(this,e),this.updateChange(!1,this.propName),this.clearChanges()):ypt(this,e)},e.prototype.dataBind=function(){if(this.callChildDataBind(this.childChangedProperties,this),this.isParentArray){var e=this.parentObj[this.propName].indexOf(this);Object.keys(this.changedProperties).length&&(mpt(this.propName+"."+e,this.changedProperties,this.parentObj.changedProperties),mpt(this.propName+"."+e,this.oldProperties,this.parentObj.oldProperties))}else this.parentObj.changedProperties[this.propName]=this.changedProperties,this.parentObj.oldProperties[this.propName]=this.oldProperties;this.clearChanges()},e.prototype.saveChanges=function(e,t,n,a){this.controlParent.isProtectedOnChange||(a||this.serverDataBind(e,t,!0),this.oldProperties[e]=n,this.changedProperties[e]=t,this.updateChange(!0,this.propName),this.finalUpdate(),this.updateTimeOut())},e.prototype.serverDataBind=function(e,t,n,a){},e.prototype.getParentKey=function(e){var t="",n=this.propName;if(this.isParentArray){t=this.parentObj[this.propName].indexOf(this);var a=this.parentObj[this.propName].length;a=e?a:a>0?a-1:0,n+=t=-1!==t?"-"+t:"-"+a}return this.controlParent!==this.parentObj&&(n=this.parentObj.getParentKey()+"."+this.propName+t),n},e}(),mmt=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],vmt=function(){function e(e){var t;this.isValidated=!1,this.version="20.2",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats/i,this.errors={noLicense:'This application was built using a trial version of Syncfusion Essential Studio. Please include a valid license to permanently remove this license validation message. You can also obtain a free 30 day evaluation license to temporarily remove this message during the evaluation period. Please refer to this <a class="e-license"href="https://help.syncfusion.com/common/essential-studio/licensing">help topic</a> for more information.',trailExpired:'Your Syncfusion trial license has expired. Please refer to this <a class="e-license"href="https://help.syncfusion.com/common/essential-studio/licensing/licensing-errors#trial-expired">help topic</a> for more information.',versionMismatched:'The included Syncfusion license (v##LicenseVersion) is invalid for version ##Requireversion. Please refer to this <a class="e-license" href="https://help.syncfusion.com/es/licensing/version-mismatch/">help topic</a> for more information.',platformMismatched:'The included Syncfusion license is invalid (Platform mismatch). Please refer to this <a class="e-license" href="https://help.syncfusion.com/common/essential-studio/licensing/licensing-errors#platform-mismatch">help topic</a> for more information.',invalidKey:'The included Syncfusion license is invalid. Please refer to this <a class="e-license" href="https://help.syncfusion.com/common/essential-studio/licensing/licensing-errors#invalid-key">help topic</a> for more information.'},this.manager=(t=null,{setKey:function(e){t=e},getKey:function(){return t}}),this.npxManager={getKey:function(){return"npxKeyReplace"}},this.manager.setKey(e)}return e.prototype.validate=function(){if(!this.isValidated&&gpt&&!fpt(wmt(mmt),gpt)&&!fpt("Blazor",gpt)){var e=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var t=this.getInfoFromKey();if(t&&t.length)for(var n=0,a=t;n<a.length;n++){var r=a[n];if(!this.platform.test(r.platform)||r.invalidPlatform)e=this.errors.platformMismatched;else if(-1===r.version.indexOf(this.version))e=(e=(e=this.errors.versionMismatched).replace("##LicenseVersion",r.version)).replace("##Requireversion",this.version+".x");else if(r.expiryDate){var i=new Date(r.expiryDate),o=new Date;if(!(i!==o&&i<o))break;e=this.errors.trailExpired}}else e=this.errors.invalidKey}else e=this.errors.noLicense;if(e&&"undefined"!=typeof document&&!xpt(document)){var l=bft("div",{innerHTML:e+'<span id="license-banner-error" class=".e-license-banner"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20"><line x1="5" y1="5" x2="15" y2="15" stroke="yellow" stroke-width="2.5" stroke-miterlimit="10" stroke-linecap="round"></line><line x1="15" y1="5" x2="5" y2="15" stroke="yellow" stroke-width="2.5" stroke-linecap="round" stroke-miterlimit="10"></line></svg></span>',styles:'position:fixed;top:0;left:0;right:0;font-family:"Segoe UI";font-size:16px;background:repeating-linear-gradient(45deg,#d70f0f,#d70f0f 10px,#e12121 10px,#e12121 17px);color:#ffffff;z-index:999999999;text-align:center;padding:10px 50px 10px 25px;'});l.setAttribute("id","js-licensing"),document.body.appendChild(l),document.getElementById("license-banner-error").addEventListener("click",function(){document.getElementById("js-licensing").remove()})}this.isValidated=!0,mpt(wmt(mmt),this.isValidated,gpt)}},e.prototype.getDecryptedData=function(e){try{return atob(e)}catch(e){return""}},e.prototype.getInfoFromKey=function(){try{var e="",t=[5439488,7929856,5111808,6488064,4587520,7667712,5439488,6881280,5177344,7208960,4194304,4456448,6619136,7733248,5242880,7077888,6356992,7602176,4587520,7274496,7471104,7143424],n=[],a=[],r=!1,i=!1;this.manager.getKey()?e=this.manager.getKey():(i=!0,e=this.npxManager.getKey().split("npxKeyReplace")[1]);for(var o=e.split(";"),l=0,s=o;l<s.length;l++){var c=s[l],d=this.getDecryptedData(c);if(d){var h=0,u="";if(i){var p=d[d.length-1],f=[];for(m=0;m<d.length;m++)f[m]=d[m].charCodeAt(0)-p.charCodeAt(0);for(m=0;m<f.length;m++)u+=String.fromCharCode(f[m])}else for(var m=0;m<d.length;m++,h++){h===t.length&&(h=0);var v=d.charCodeAt(m);u+=String.fromCharCode(v^t[h]>>16)}this.platform.test(u)?(n=u.split(";"),r=!1,n.length>3&&a.push({platform:n[0],version:n[1],expiryDate:n[2]})):u&&u.split(";").length>3&&(r=!0)}}return r&&!a.length?[{invalidPlatform:r}]:a.length?a:null}catch(e){return null}},e}(),gmt=new vmt;function wmt(e){for(var t="",n=0,a=e;n<a.length;n++){var r=a[n];t+=String.fromCharCode(r)}return t}var ymt,bmt=function(e){e&&function(e){gmt=new vmt(e)}(e),gmt.validate()},xmt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Emt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},kmt=0,Mmt=0,Smt=function(e){function t(t,n){var a=e.call(this,t,n)||this;return a.randomId=function(){if("undefined"!=typeof window){var e=new Uint16Array(5);return(window.msCrypto||window.crypto).getRandomValues(e)}}(),a.isStringTemplate=!1,a.needsID=!1,a.isReactHybrid=!1,xpt(a.enableRtl)&&a.setProperties({enableRtl:false},!0),xpt(a.locale)&&a.setProperties({locale:eft},!0),a.moduleLoader=new pmt(a),a.localObserver=new Xpt(a),Jpt.on("notifyExternalChange",a.detectFunction,a,a.randomId),bmt(),Ept(n)||a.appendTo(),a}return xmt(t,e),t.prototype.requiredModules=function(){return[]},t.prototype.destroy=function(){this.isDestroyed||(this.enablePersistence&&this.setPersistData(),this.localObserver.destroy(),this.refreshing||(Eft([this.element],["e-control"]),this.trigger("destroyed",{cancel:!1}),e.prototype.destroy.call(this),this.moduleLoader.clean(),Jpt.off("notifyExternalChange",this.detectFunction,this.randomId)))},t.prototype.refresh=function(){this.refreshing=!0,this.moduleLoader.clean(),this.destroy(),this.clearChanges(),this.localObserver=new Xpt(this),this.preRender(),this.injectModules(),this.render(),this.refreshing=!1},t.prototype.accessMount=function(){this.mount&&!this.isReactHybrid&&this.mount()},t.prototype.getRootElement=function(){return this.isReactHybrid?this.actualElement:this.element},t.prototype.getLocalData=function(){var e=this.getModuleName()+this.element.id;return window.localStorage.getItem(e)},t.prototype.appendTo=function(t){if(xpt(t)||"string"!=typeof t?xpt(t)||(this.element=t):this.element=Ift(t,document),!xpt(this.element)){var n="e-"+this.getModuleName().toLowerCase();xft([this.element],["e-control",n]),this.isProtectedOnChange=!1,this.needsID&&!this.element.id&&(this.element.id=this.getUniqueID(this.getModuleName())),this.enablePersistence&&(this.mergePersistData(),window.addEventListener("unload",this.setPersistData.bind(this)));var a=fpt("ej2_instances",this.element);a&&-1!==a.indexOf(this)||e.prototype.addInstance.call(this),this.preRender(),this.injectModules(),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),e.prototype.dataBind.call(this)},t.prototype.on=function(e,t,n){if("string"==typeof e)this.localObserver.on(e,t,n);else for(var a=0,r=e;a<r.length;a++){var i=r[a];this.localObserver.on(i.event,i.handler,i.context)}},t.prototype.off=function(e,t){if("string"==typeof e)this.localObserver.off(e,t);else for(var n=0,a=e;n<a.length;n++){var r=a[n];this.localObserver.off(r.event,r.handler)}},t.prototype.notify=function(e,t){!0!==this.isDestroyed&&this.localObserver.notify(e,t)},t.prototype.getInjectedModules=function(){return this.injectedModules},t.Inject=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.prototype.injectedModules||(this.prototype.injectedModules=[]);for(var n=0;n<e.length;n++)-1===this.prototype.injectedModules.indexOf(e[n])&&this.prototype.injectedModules.push(e[n])},t.prototype.createElement=function(e,t,n){return bft(e,t)},t.prototype.triggerStateChange=function(e,t){this.isReactHybrid&&(this.setState(),this.currentContext={calls:e,args:t})},t.prototype.injectModules=function(){this.injectedModules&&this.injectedModules.length&&this.moduleLoader.inject(this.requiredModules(),this.injectedModules)},t.prototype.detectFunction=function(e){var t=Object.keys(e);t.length&&(this[t[0]]=e[t[0]])},t.prototype.mergePersistData=function(){var e;xpt(e=window.localStorage.getItem(this.getModuleName()+this.element.id))||""===e||this.setProperties(JSON.parse(e),!0)},t.prototype.setPersistData=function(){this.isDestroyed||window.localStorage.setItem(this.getModuleName()+this.element.id,this.getPersistData())},t.prototype.renderReactTemplates=function(){},t.prototype.clearTemplate=function(e,t){},t.prototype.getUniqueID=function(e){return this.isHistoryChanged()&&(kmt=0),ymt=this.pageID(location.href),Mmt=history.length,e+"_"+ymt+"_"+kmt++},t.prototype.pageID=function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++){t=(t<<5)-t+e.charCodeAt(n),t&=t}return Math.abs(t)},t.prototype.isHistoryChanged=function(){return ymt!==this.pageID(location.href)||Mmt!==history.length},t.prototype.addOnPersist=function(e){for(var t=this,n={},a=0,r=e;a<r.length;a++){var i,o=r[a];Ept(i=fpt(o,this))||mpt(o,this.getActualProperties(i),n)}return JSON.stringify(n,function(e,n){return t.getActualProperties(n)})},t.prototype.getActualProperties=function(e){return e instanceof fmt?fpt("properties",e):e},t.prototype.ignoreOnPersist=function(e){return JSON.stringify(this.iterateJsonProperties(this.properties,e))},t.prototype.iterateJsonProperties=function(e,t){for(var n={},a=function(a){if(-1===t.indexOf(a)){var i=e[a];if("object"!=typeof i||i instanceof Array)n[a]=i;else{var o=t.filter(function(e){return new RegExp(a+".").test(e)}).map(function(e){return e.replace(a+".","")});n[a]=r.iterateJsonProperties(r.getActualProperties(i),o)}}},r=this,i=0,o=Object.keys(e);i<o.length;i++){a(o[i])}return n},Emt([Kft(!1)],t.prototype,"enablePersistence",void 0),Emt([Kft()],t.prototype,"enableRtl",void 0),Emt([Kft()],t.prototype,"locale",void 0),t=Emt([$ft],t)}(Pft);"undefined"!=typeof window&&window.addEventListener("popstate",function(){kmt=0});var Amt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),_mt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Cmt={left:0,top:0,bottom:0,right:0},Zmt={isDragged:!1},Hmt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Amt(t,e),_mt([Kft(0)],t.prototype,"left",void 0),_mt([Kft(0)],t.prototype,"top",void 0),t}(fmt);!function(e){function t(t,a){var r=e.call(this,a,t)||this;return r.dragLimit=n.getDefaultPosition(),r.borderWidth=n.getDefaultPosition(),r.padding=n.getDefaultPosition(),r.diffX=0,r.prevLeft=0,r.prevTop=0,r.dragProcessStarted=!1,r.eleTop=0,r.tapHoldTimer=0,r.externalInitialize=!1,r.diffY=0,r.parentScrollX=0,r.parentScrollY=0,r.droppables={},r.bind(),r}var n;Amt(t,e),n=t,t.prototype.bind=function(){this.toggleEvents(),gft.isIE&&xft([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return bpt({},Cmt)},t.prototype.toggleEvents=function(e){var t;Ept(this.handle)||(t=Ift(this.handle,this.element));var n=this.enableTapHold&&gft.isDevice&&gft.isTouch?this.mobileInitialize:this.initialize;e?wft.remove(t||this.element,gft.touchStartEvent,n):wft.add(t||this.element,gft.touchStartEvent,n,this)},t.prototype.mobileInitialize=function(e){var t=this,n=e.currentTarget;this.tapHoldTimer=setTimeout(function(){t.externalInitialize=!0,t.removeTapholdTimer(),t.initialize(e,n)},this.tapHoldThreshold),wft.add(document,gft.touchMoveEvent,this.removeTapholdTimer,this),wft.add(document,gft.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),wft.remove(document,gft.touchMoveEvent,this.removeTapholdTimer),wft.remove(document,gft.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(e,t){return xpt(e)?null:e[{vertical:"scrollHeight",horizontal:"scrollWidth"}[t]]>e[{vertical:"clientHeight",horizontal:"clientWidth"}[t]]&&("vertical"===t?e.scrollTop>0:e.scrollLeft>0)?("vertical"===t?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?e.scrollTop:e.scrollTop-this.parentScrollY),this.tempScrollHeight=e.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?e.scrollLeft:e.scrollLeft-this.parentScrollX),this.tempScrollWidth=e.scrollWidth),xpt(e)?e:this.getScrollableParent(e.parentNode,t)):this.getScrollableParent(e.parentNode,t)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(e,t){if(this.currentStateTarget=e.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=e.currentTarget||t,this.dragProcessStarted=!1,this.abort){var n=this.abort;"string"==typeof n&&(n=[n]);for(var a=0;a<n.length;a++)if(!xpt(Oft(e.target,n[a])))return void(this.isDragStarted()&&this.isDragStarted(!0))}this.preventDefault&&!Ept(e.changedTouches)&&"touchstart"!==e.type&&e.preventDefault(),this.element.setAttribute("aria-grabbed","true");var r=this.getCoordinates(e);if(this.initialPosition={x:r.pageX,y:r.pageY},!this.clone){var i=this.element.getBoundingClientRect();this.getScrollableValues(),e.clientX===e.pageX&&(this.parentScrollX=0),e.clientY===e.pageY&&(this.parentScrollY=0),this.relativeXPosition=r.pageX-(i.left+this.parentScrollX),this.relativeYPosition=r.pageY-(i.top+this.parentScrollY)}this.externalInitialize?this.intDragStart(e):(wft.add(document,gft.touchMoveEvent,this.intDragStart,this),wft.add(document,gft.touchEndEvent,this.intDestroy,this)),this.toggleEvents(!0),"touchstart"!==e.type&&this.isPreventSelect&&document.body.classList.add("e-prevent-select"),this.externalInitialize=!1,wft.trigger(document.documentElement,gft.touchStartEvent,e)}},t.prototype.intDragStart=function(e){this.removeTapholdTimer();var t=!Ept(e.changedTouches);if(!t||1===e.changedTouches.length){var n,a=this.getCoordinates(e),r=getComputedStyle(this.element);this.margin={left:parseInt(r.marginLeft,10),top:parseInt(r.marginTop,10),right:parseInt(r.marginRight,10),bottom:parseInt(r.marginBottom,10)};var i=this.element;if(this.clone&&this.dragTarget){var o=Oft(e.target,this.dragTarget);xpt(o)||(i=o)}this.isReplaceDragEle&&(i=this.currentStateCheck(e.target,i)),this.offset=this.calculateParentPosition(i),this.position=this.getMousePosition(e,this.isDragScroll);var l=this.initialPosition.x-a.pageX,s=this.initialPosition.y-a.pageY;if(Math.sqrt(l*l+s*s)>=this.distance||this.externalInitialize){var c=this.getHelperElement(e);if(!c||xpt(c))return;t&&e.preventDefault();var d=this.helperElement=c;if(this.parentClientRect=this.calculateParentPosition(d.offsetParent),this.dragStart){var h={event:e,element:i,target:this.getProperTargetElement(e),bindEvents:null,dragElement:d};this.trigger("dragStart",h)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),n={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var u=getComputedStyle(i),p=parseFloat(u.marginTop);this.clone&&0!==p&&(n.top+=p),this.eleTop=isNaN(parseFloat(u.top))?0:parseFloat(u.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(n.top-=this.parentScrollY,n.left-=this.parentScrollX);var f=this.getProcessedPositionValue({top:n.top-this.diffY+"px",left:n.left-this.diffX+"px"});this.dragElePosition={top:n.top,left:n.left},Lft(d,this.getDragPosition({position:"absolute",left:f.left,top:f.top})),wft.remove(document,gft.touchMoveEvent,this.intDragStart),wft.remove(document,gft.touchEndEvent,this.intDestroy),this.bindDragEvents(d)}}},t.prototype.bindDragEvents=function(e){Mft(e)?(wft.add(document,gft.touchMoveEvent,this.intDrag,this),wft.add(document,gft.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,e)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(e){for(this.top=e.offsetTop,this.left=e.offsetLeft,this.width=e.offsetWidth,this.height=e.offsetHeight;e.offsetParent;)e=e.offsetParent,this.top+=e.offsetTop,this.left+=e.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(e){return this.queryPositionInfo?this.queryPositionInfo(e):e},t.prototype.calculateParentPosition=function(e){if(xpt(e))return{left:0,top:0};var t=e.getBoundingClientRect(),n=getComputedStyle(e);return{left:t.left+window.pageXOffset-parseInt(n.marginLeft,10),top:t.top+window.pageYOffset-parseInt(n.marginTop,10)}},t.prototype.intDrag=function(e){if(Ept(e.changedTouches)||1===e.changedTouches.length){var t,n;this.clone&&e.changedTouches&&gft.isDevice&&gft.isTouch&&e.preventDefault(),this.position=this.getMousePosition(e,this.isDragScroll);var a=this.getDocumentWidthHeight("Height");a<this.position.top&&(this.position.top=a);var r=this.getDocumentWidthHeight("Width");if(r<this.position.left&&(this.position.left=r),this.drag){var i=this.getProperTargetElement(e);this.trigger("drag",{event:e,element:this.element,target:i})}var o=this.checkTargetElement(e);if(o.target&&o.instance){var l=!0;this.hoverObject&&(this.hoverObject.instance!==o.instance?this.triggerOutFunction(e,o):l=!1),l&&(o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intOver(e,o.target),this.hoverObject=o)}else this.hoverObject&&this.triggerOutFunction(e,o);var s=this.droppables[this.scope].helper;this.parentClientRect=this.calculateParentPosition(this.helperElement.offsetParent);var c=this.parentClientRect.left,d=this.parentClientRect.top,h=this.getCoordinates(e),u=h.pageX,p=h.pageY,f=this.position.left-this.diffX,m=this.position.top-this.diffY,v=getComputedStyle(s);if(this.dragArea){if(this.pageX!==u||this.skipDistanceCheck){var g=s.offsetWidth+(parseFloat(v.marginLeft)+parseFloat(v.marginRight));t=this.dragLimit.left>f&&f>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset<f+g&&f>0?f-(f-this.dragLimit.right)+window.pageXOffset-g:f<0?this.dragLimit.left:f}if(this.pageY!==p||this.skipDistanceCheck){var w=s.offsetHeight+(parseFloat(v.marginTop)+parseFloat(v.marginBottom));n=this.dragLimit.top>m&&m>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset<m+w&&m>0?m-(m-this.dragLimit.bottom)+window.pageYOffset-w:m<0?this.dragLimit.top:m}}else t=f,n=m;var y,b,x=d+this.borderWidth.top,E=c+this.borderWidth.left;this.dragProcessStarted&&(xpt(n)&&(n=this.prevTop),xpt(t)&&(t=this.prevLeft)),this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,y=n-x<0?this.dragLimit.top:n-x,b=t-E<0?this.dragElePosition.left:t-E):(y=n-x,b=t-E);var k=parseFloat(getComputedStyle(this.element).marginTop);if(k>0&&(this.clone&&(y+=k,m<0&&(k+m>=0?y=k+m:y-=k),y=this.dragLimit.bottom<y?this.dragLimit.bottom:y),n-x<0))if(m+k+(s.offsetHeight-x)>=0){var M=this.dragLimit.top+m-x;M+k+x<0?y-=k+x:y=M}else y-=k+x;this.enableScrollHandler&&!this.clone&&(y-=this.parentScrollY,b-=this.parentScrollX);var S=this.getProcessedPositionValue({top:y+"px",left:b+"px"});Lft(s,this.getDragPosition(S)),this.elementInViewport(s)||!this.enableAutoScroll||this.helperElement.classList.contains("e-treeview")||this.helperElement.scrollIntoView();var A=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===A.length&&(A=this.getPathElements(e));var _=this.getScrollParent(A,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(_,y):this.elementInViewport(this.helperElement)||(0===(A=[].slice.call(document.querySelectorAll(":hover"))).length&&(A=this.getPathElements(e)),_=this.getScrollParent(A,!0),this.getScrollPosition(_,y))}this.dragProcessStarted=!0,this.prevLeft=t,this.prevTop=n,this.position.left=t,this.position.top=n,this.pageX=u,this.pageY=p}},t.prototype.getScrollParent=function(e,t){for(var n,a=t?e.reverse():e,r=a.length-1;r>=0;r--)if(("auto"===(n=window.getComputedStyle(a[r])["overflow-y"])||"scroll"===n)&&a[r].scrollHeight>a[r].clientHeight)return a[r];if("visible"===(n=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(e,t){e&&e===document.scrollingElement?e.clientHeight-e.getBoundingClientRect().top-this.helperElement.clientHeight<t&&e.getBoundingClientRect().height>t?e.scrollTop+=this.helperElement.clientHeight:e.scrollHeight-e.clientHeight>t&&(e.scrollTop-=this.helperElement.clientHeight):e&&e!==document.scrollingElement&&(e.clientHeight+e.getBoundingClientRect().top-this.helperElement.clientHeight<t?e.scrollTop+=this.helperElement.clientHeight:e.getBoundingClientRect().top>t-this.helperElement.clientHeight&&(e.scrollTop-=this.helperElement.clientHeight))},t.prototype.getPathElements=function(e){var t=e.clientX>0?e.clientX:0,n=e.clientY>0?e.clientY:0;return document.elementsFromPoint(t,n)},t.prototype.triggerOutFunction=function(e,t){this.hoverObject.instance.intOut(e,t.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(e){var t=bpt({},e);return this.axis&&("x"===this.axis?delete t.top:"y"===this.axis&&delete t.left),t},t.prototype.getDocumentWidthHeight=function(e){var t=document.body,n=document.documentElement;return Math.max(t["scroll"+e],n["scroll"+e],t["offset"+e],n["offset"+e],n["client"+e])},t.prototype.intDragStop=function(e){if(this.dragProcessStarted=!1,Ept(e.changedTouches)||1===e.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(e.type)){if(this.dragStop){var t=this.getProperTargetElement(e);this.trigger("dragStop",{event:e,element:this.element,target:t,helper:this.helperElement})}this.intDestroy(e)}else this.element.setAttribute("aria-grabbed","false");var n=this.checkTargetElement(e);n.target&&n.instance&&(n.instance.dragStopCalled=!0,n.instance.dragData[this.scope]=this.droppables[this.scope],n.instance.intDrop(e,n.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(e){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),wft.remove(document,gft.touchMoveEvent,this.intDragStart),wft.remove(document,gft.touchEndEvent,this.intDragStop),wft.remove(document,gft.touchEndEvent,this.intDestroy),wft.remove(document,gft.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(e,t){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(e){return e&&(Zmt.isDragged=!Zmt.isDragged),Zmt.isDragged},t.prototype.setDragArea=function(){var e,t,n,a=0,r=0;if(n="string"===typeof this.dragArea?Ift(this.dragArea):this.dragArea){var i=n.getBoundingClientRect();e=n.scrollWidth?n.scrollWidth:i.right-i.left,t=n.scrollHeight?n.scrollHeight:i.bottom-i.top;for(var o=["Top","Left","Bottom","Right"],l=getComputedStyle(n),s=0;s<o.length;s++){var c=o[s],d=l["border"+c+"Width"],h=l["padding"+c],u=c.toLowerCase();this.borderWidth[u]=isNaN(parseFloat(d))?0:parseFloat(d),this.padding[u]=isNaN(parseFloat(h))?0:parseFloat(h)}a=i.top,r=i.left,this.dragLimit.left=r+this.borderWidth.left+this.padding.left,this.dragLimit.top=n.offsetTop+this.borderWidth.top+this.padding.top,this.dragLimit.right=r+e-(this.borderWidth.right+this.padding.right),this.dragLimit.bottom=a+t-(this.borderWidth.bottom+this.padding.bottom)}},t.prototype.getProperTargetElement=function(e){var t,n=this.getCoordinates(e),a=this.helperElement.style.pointerEvents||"";return Mpt(e.target,this.helperElement)||-1!==e.type.indexOf("touch")?(this.helperElement.style.pointerEvents="none",t=document.elementFromPoint(n.clientX,n.clientY),this.helperElement.style.pointerEvents=a):t=e.target,t},t.prototype.currentStateCheck=function(e,t){return xpt(this.currentStateTarget)||this.currentStateTarget===e?xpt(t)?e:t:this.currentStateTarget},t.prototype.getMousePosition=function(e,t){var n,a,r=void 0!==e.srcElement?e.srcElement:e.target,i=this.getCoordinates(e),o=xpt(r.offsetParent);return t?(n=this.clone?i.pageX:i.pageX+(o?0:r.offsetParent.scrollLeft)-this.relativeXPosition,a=this.clone?i.pageY:i.pageY+(o?0:r.offsetParent.scrollTop)-this.relativeYPosition):(n=this.clone?i.pageX:i.pageX+window.pageXOffset-this.relativeXPosition,a=this.clone?i.pageY:i.pageY+window.pageYOffset-this.relativeYPosition),{left:n-(this.margin.left+this.cursorAt.left),top:a-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(e){return e.type.indexOf("touch")>-1?e.changedTouches[0]:e},t.prototype.getHelperElement=function(e){var t;return this.clone?this.helper?t=this.helper({sender:e,element:this.target}):(t=bft("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(t)):t=this.element,t},t.prototype.setGlobalDroppables=function(e,t,n){this.droppables[this.scope]=e?null:{draggable:t,helper:n,draggedElement:this.element}},t.prototype.checkTargetElement=function(e){var t=this.getProperTargetElement(e),n=this.getDropInstance(t);if(!n&&t&&!xpt(t.parentNode)){var a=Oft(t.parentNode,".e-droppable")||t.parentElement;a&&(n=this.getDropInstance(a))}return{target:t,instance:n}},t.prototype.getDropInstance=function(e){var t,n=e&&e.ej2_instances;if(n)for(var a=0,r=n;a<r.length;a++){var i=r[a];if("droppable"===i.getModuleName()){t=i;break}}return t},t.prototype.destroy=function(){this.toggleEvents(!0),e.prototype.destroy.call(this)},_mt([Qft({},Hmt)],t.prototype,"cursorAt",void 0),_mt([Kft(!0)],t.prototype,"clone",void 0),_mt([Kft()],t.prototype,"dragArea",void 0),_mt([Kft()],t.prototype,"isDragScroll",void 0),_mt([Kft()],t.prototype,"isReplaceDragEle",void 0),_mt([Kft(!0)],t.prototype,"isPreventSelect",void 0),_mt([Jft()],t.prototype,"drag",void 0),_mt([Jft()],t.prototype,"dragStart",void 0),_mt([Jft()],t.prototype,"dragStop",void 0),_mt([Kft(1)],t.prototype,"distance",void 0),_mt([Kft()],t.prototype,"handle",void 0),_mt([Kft()],t.prototype,"abort",void 0),_mt([Kft()],t.prototype,"helper",void 0),_mt([Kft("default")],t.prototype,"scope",void 0),_mt([Kft("")],t.prototype,"dragTarget",void 0),_mt([Kft()],t.prototype,"axis",void 0),_mt([Kft()],t.prototype,"queryPositionInfo",void 0),_mt([Kft(!1)],t.prototype,"enableTailMode",void 0),_mt([Kft(!1)],t.prototype,"skipDistanceCheck",void 0),_mt([Kft(!0)],t.prototype,"preventDefault",void 0),_mt([Kft(!1)],t.prototype,"enableAutoScroll",void 0),_mt([Kft(!1)],t.prototype,"enableTapHold",void 0),_mt([Kft(750)],t.prototype,"tapHoldThreshold",void 0),_mt([Kft(!1)],t.prototype,"enableScrollHandler",void 0),t=n=_mt([$ft],t)}(Pft);var Imt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Dmt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o};!function(e){function t(t,n){var a=e.call(this,n,t)||this;return a.mouseOver=!1,a.dragData={},a.dragStopCalled=!1,a.bind(),a}Imt(t,e),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){wft.add(this.element,gft.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,t){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,t){if(!this.mouseOver){var n=this.dragData[this.scope];this.trigger("over",{event:e,target:t,dragData:n}),this.mouseOver=!0}},t.prototype.intOut=function(e,t){this.mouseOver&&(this.trigger("out",{evt:e,target:t}),this.mouseOver=!1)},t.prototype.intDrop=function(e,t){if(this.dragStopCalled){this.dragStopCalled=!1;var n,a=!0,r=this.dragData[this.scope],i=!!r&&(r.helper&&Mft(r.helper));i&&(n=this.isDropArea(e,r.helper,t),this.accept&&(a=Vft(r.helper,this.accept))),i&&this.drop&&n.canDrop&&a&&this.trigger("drop",{event:e,target:n.target,droppedElement:r.helper,dragData:r}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,t,n){var a={canDrop:!0,target:n||e.target},r="touchend"===e.type;if(r||a.target===t){t.style.display="none";var i=r?e.changedTouches[0]:e,o=document.elementFromPoint(i.clientX,i.clientY);a.canDrop=!1,a.canDrop=Mpt(o,this.element),a.canDrop&&(a.target=o),t.style.display=""}return a},t.prototype.destroy=function(){wft.remove(this.element,gft.touchEndEvent,this.intDrop),e.prototype.destroy.call(this)},Dmt([Kft()],t.prototype,"accept",void 0),Dmt([Kft("default")],t.prototype,"scope",void 0),Dmt([Jft()],t.prototype,"drop",void 0),Dmt([Jft()],t.prototype,"over",void 0),Dmt([Jft()],t.prototype,"out",void 0),t=Dmt([$ft],t)}(Pft);var Nmt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Omt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Lmt={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,space:32,escape:27,pageup:33,pagedown:34,end:35,home:36,leftarrow:37,uparrow:38,rightarrow:39,downarrow:40,insert:45,delete:46,f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123,semicolon:186,plus:187,comma:188,minus:189,dot:190,forwardslash:191,graveaccent:192,openbracket:219,backslash:220,closebracket:221,singlequote:222},Vmt=function(e){function t(t,a){var r=e.call(this,a,t)||this;return r.keyPressHandler=function(e){for(var t=e.altKey,a=e.ctrlKey,i=e.shiftKey,o=e.which,l=0,s=Object.keys(r.keyConfigs);l<s.length;l++)for(var c=s[l],d=0,h=r.keyConfigs[c].split(",");d<h.length;d++){var u=h[d],p=n.getKeyConfigData(u.trim());t===p.altKey&&a===p.ctrlKey&&i===p.shiftKey&&o===p.keyCode&&(e.action=c,r.keyAction&&r.keyAction(e))}},r.bind(),r}var n;return Nmt(t,e),n=t,t.prototype.destroy=function(){this.unwireEvents(),e.prototype.destroy.call(this)},t.prototype.onPropertyChanged=function(e,t){},t.prototype.bind=function(){this.wireEvents()},t.prototype.getModuleName=function(){return"keyboard"},t.prototype.wireEvents=function(){this.element.addEventListener(this.eventName,this.keyPressHandler)},t.prototype.unwireEvents=function(){this.element.removeEventListener(this.eventName,this.keyPressHandler)},t.getKeyConfigData=function(e){if(e in this.configCache)return this.configCache[e];var t=e.toLowerCase().split("+"),a={altKey:-1!==t.indexOf("alt"),ctrlKey:-1!==t.indexOf("ctrl"),shiftKey:-1!==t.indexOf("shift"),keyCode:null};return t[t.length-1].length>1&&Number(t[t.length-1])?a.keyCode=Number(t[t.length-1]):a.keyCode=n.getKeyCode(t[t.length-1]),n.configCache[e]=a,a},t.getKeyCode=function(e){return Lmt[e]||e.toUpperCase().charCodeAt(0)},t.configCache={},Omt([Kft({})],t.prototype,"keyConfigs",void 0),Omt([Kft("keyup")],t.prototype,"eventName",void 0),Omt([Jft()],t.prototype,"keyAction",void 0),t=n=Omt([$ft],t)}(Pft),zmt=function(){function e(e,t,n){this.controlName=e,this.localeStrings=t,this.setLocale(n||eft)}return e.prototype.setLocale=function(t){var n=this.intGetControlConstant(e.locale,t);this.currentLocale=n||this.localeStrings},e.load=function(e){this.locale=bpt(this.locale,e,{},!0)},e.prototype.getConstant=function(e){return xpt(this.currentLocale[e])?this.localeStrings[e]||"":this.currentLocale[e]},e.prototype.intGetControlConstant=function(e,t){return e[t]?e[t][this.controlName]:null},e.locale={},e}(),Pmt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Tmt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Bmt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Pmt(t,e),Tmt([Kft(50)],t.prototype,"swipeThresholdDistance",void 0),t}(fmt),jmt=/(Up|Down)/;!function(e){function t(t,n){var a=e.call(this,n,t)||this;return a.touchAction=!0,a.tapCount=0,a.startEvent=function(e){if(!0===a.touchAction){var t=a.updateChangeTouches(e);void 0!==e.changedTouches&&(a.touchAction=!1),a.isTouchMoved=!1,a.movedDirection="",a.startPoint=a.lastMovedPoint={clientX:t.clientX,clientY:t.clientY},a.startEventData=t,a.hScrollLocked=a.vScrollLocked=!1,a.tStampStart=Date.now(),a.timeOutTapHold=setTimeout(function(){a.tapHoldEvent(e)},a.tapHoldThreshold),wft.add(a.element,gft.touchMoveEvent,a.moveEvent,a),wft.add(a.element,gft.touchEndEvent,a.endEvent,a),wft.add(a.element,gft.touchCancelEvent,a.cancelEvent,a)}},a.moveEvent=function(e){var t=a.updateChangeTouches(e);a.movedPoint=t,a.isTouchMoved=!(t.clientX===a.startPoint.clientX&&t.clientY===a.startPoint.clientY);var n={};a.isTouchMoved&&(clearTimeout(a.timeOutTapHold),a.calcScrollPoints(e),n=bpt(n,{},{startEvents:a.startEventData,originalEvent:e,startX:a.startPoint.clientX,startY:a.startPoint.clientY,distanceX:a.distanceX,distanceY:a.distanceY,scrollDirection:a.scrollDirection,velocity:a.getVelocity(t)}),a.trigger("scroll",n),a.lastMovedPoint={clientX:t.clientX,clientY:t.clientY})},a.cancelEvent=function(e){clearTimeout(a.timeOutTapHold),clearTimeout(a.timeOutTap),a.tapCount=0,a.swipeFn(e),wft.remove(a.element,gft.touchCancelEvent,a.cancelEvent)},a.endEvent=function(e){a.swipeFn(e),a.isTouchMoved||"function"==typeof a.tap&&(a.trigger("tap",{originalEvent:e,tapCount:++a.tapCount}),a.timeOutTap=setTimeout(function(){a.tapCount=0},a.tapThreshold)),a.modeclear()},a.swipeFn=function(e){clearTimeout(a.timeOutTapHold),clearTimeout(a.timeOutTap);var t=a.updateChangeTouches(e),n=t.clientX-a.startPoint.clientX,r=t.clientY-a.startPoint.clientY;n=Math.floor(n<0?-1*n:n),r=Math.floor(r<0?-1*r:n),a.isTouchMoved=n>1||r>1,/Firefox/.test(gft.userAgent)&&0===t.clientX&&0===t.clientY&&"mouseup"===e.type&&(a.isTouchMoved=!1),a.endPoint=t,a.calcPoints(e);var i={originalEvent:e,startEvents:a.startEventData,startX:a.startPoint.clientX,startY:a.startPoint.clientY,distanceX:a.distanceX,distanceY:a.distanceY,swipeDirection:a.movedDirection,velocity:a.getVelocity(t)};if(a.isTouchMoved){var o=void 0,l=a.swipeSettings.swipeThresholdDistance;o=bpt(o,a.defaultArgs,i);var s=!1,c=a.element,d=a.isScrollable(c),h=jmt.test(a.movedDirection);(l<a.distanceX&&!h||l<a.distanceY&&h)&&(s=!d||a.checkSwipe(c,h)),s&&a.trigger("swipe",o)}a.modeclear()},a.modeclear=function(){a.modeClear=setTimeout(function(){a.touchAction=!0},"function"!=typeof a.tap?0:20),a.lastTapTime=(new Date).getTime(),wft.remove(a.element,gft.touchMoveEvent,a.moveEvent),wft.remove(a.element,gft.touchEndEvent,a.endEvent),wft.remove(a.element,gft.touchCancelEvent,a.cancelEvent)},a.bind(),a}Pmt(t,e),t.prototype.onPropertyChanged=function(e,t){},t.prototype.bind=function(){this.wireEvents(),gft.isIE&&this.element.classList.add("e-block-touch")},t.prototype.destroy=function(){this.unwireEvents(),e.prototype.destroy.call(this)},t.prototype.wireEvents=function(){wft.add(this.element,gft.touchStartEvent,this.startEvent,this)},t.prototype.unwireEvents=function(){wft.remove(this.element,gft.touchStartEvent,this.startEvent)},t.prototype.getModuleName=function(){return"touch"},t.prototype.isScrollable=function(e){var t=getComputedStyle(e),n=t.overflow+t.overflowX+t.overflowY;return!!/(auto|scroll)/.test(n)},t.prototype.tapHoldEvent=function(e){var t;this.tapCount=0,this.touchAction=!0,wft.remove(this.element,gft.touchMoveEvent,this.moveEvent),wft.remove(this.element,gft.touchEndEvent,this.endEvent),t={originalEvent:e},this.trigger("tapHold",t),wft.remove(this.element,gft.touchCancelEvent,this.cancelEvent)},t.prototype.calcPoints=function(e){var t=this.updateChangeTouches(e);this.defaultArgs={originalEvent:e},this.distanceX=Math.abs(Math.abs(t.clientX)-Math.abs(this.startPoint.clientX)),this.distanceY=Math.abs(Math.abs(t.clientY)-Math.abs(this.startPoint.clientY)),this.distanceX>this.distanceY?this.movedDirection=t.clientX>this.startPoint.clientX?"Right":"Left":this.movedDirection=t.clientY<this.startPoint.clientY?"Up":"Down"},t.prototype.calcScrollPoints=function(e){var t=this.updateChangeTouches(e);this.defaultArgs={originalEvent:e},this.distanceX=Math.abs(Math.abs(t.clientX)-Math.abs(this.lastMovedPoint.clientX)),this.distanceY=Math.abs(Math.abs(t.clientY)-Math.abs(this.lastMovedPoint.clientY)),(this.distanceX>this.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=t.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=t.clientY<this.lastMovedPoint.clientY?"Up":"Down",this.vScrollLocked=!0)},t.prototype.getVelocity=function(e){var t=e.clientX,n=e.clientY,a=Date.now(),r=t-this.startPoint.clientX,i=n-this.startPoint.clientX,o=a-this.tStampStart;return Math.sqrt(r*r+i*i)/o},t.prototype.checkSwipe=function(e,t){var n=["scroll","offset"],a=t?["Height","Top"]:["Width","Left"];return e[n[0]+a[0]]<=e[n[1]+a[0]]||(0===e[n[0]+a[1]]||e[n[1]+a[0]]+e[n[0]+a[1]]>=e[n[0]+a[0]])},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},Tmt([Jft()],t.prototype,"tap",void 0),Tmt([Jft()],t.prototype,"tapHold",void 0),Tmt([Jft()],t.prototype,"swipe",void 0),Tmt([Jft()],t.prototype,"scroll",void 0),Tmt([Kft(350)],t.prototype,"tapThreshold",void 0),Tmt([Kft(750)],t.prototype,"tapHoldThreshold",void 0),Tmt([Qft({},Bmt)],t.prototype,"swipeSettings",void 0),t=Tmt([$ft],t)}(Pft);var Wmt=new RegExp("\\n|\\r|\\s\\s+","g"),Rmt=new RegExp(/'|"/g),Fmt=new RegExp("if ?\\("),Ymt=new RegExp("else if ?\\("),qmt=new RegExp("else"),Umt=new RegExp("for ?\\("),Gmt=new RegExp("(/if|/for)"),Kmt=new RegExp("\\((.*)\\)",""),Qmt=new RegExp("^[0-9]+$","g"),Xmt=new RegExp("[\\w\"'.\\s+]+","g"),Jmt=new RegExp('"(.*?)"',"g"),$mt=new RegExp("[\\w\"'@#$.\\s-+]+","g"),evt=new RegExp("\\${([^}]*)}","g"),tvt=/^\..*/gm,nvt=/\\/gi,avt=/\\\\/gi,rvt=new RegExp("[\\w\"'@#$.\\s+]+","g"),ivt=/\window\./gm;function ovt(e,t,n){var a="data",r=function(e,t,n,a){var r=0,i=[],o=e.match(/class="([^"]+|)\s{2}/g),l="";o&&o.forEach(function(t){l=t.replace(/\s\s+/g," "),e=e.replace(t,l)});return e.replace(Wmt,"").replace(Jmt,"'$1'").replace(evt,function(e,o,l,s){var c=/@|#|\$/gm,d=o.match(Kmt);if(d){var h=d[1];if(Ymt.test(o))o='";} '+o.replace(d[1],h.replace(Xmt,function(e){return lvt(e=e.trim(),!Rmt.test(e)&&-1===i.indexOf(e),t,i,a)}))+'{ \n str = str + "';else if(Fmt.test(o))o='"; '+o.replace(d[1],h.replace($mt,function(e){return dvt(e,t,i,a)}))+'{ \n str = str + "';else if(Umt.test(o)){var u=d[1].split(" of ");o='"; '+o.replace(d[1],function(e){return i.push(u[0]),i.push(u[0]+"Index"),"var i"+(r+=1)+"=0; i"+r+" < "+lvt(u[1],!0,t,i,a)+".length; i"+r+"++"})+"{ \n "+u[0]+"= "+lvt(u[1],!0,t,i,a)+"[i"+r+"]; \n var "+u[0]+"Index=i"+r+'; \n str = str + "'}else{var p=o.split("("),f=n&&n.hasOwnProperty(p[0])?"this.":"global";f=/\./.test(p[0])?"":f;var m=d[1].split(",");0===d[1].length||/data/.test(m[0])||/window./.test(m[0])||(d[1]="global"===f?t+"."+d[1]:d[1]);var v=/@|\$|#/gm,g=/\]\./gm;if(ivt.test(o)&&g.test(o)||v.test(o))/@|\$|#|\]\./gm.test(o)&&(o='"+ '+("global"===f?"":f)+o.replace(d[1],h.replace(rvt,function(e){return dvt(e,t,i,a)}))+'+ "');else o='" + '+("global"===f?"":f)+o.replace(h,lvt(d[1].replace(/,( |)data.|,/gi,","+t+".").replace(/,( |)data.window/gi,",window"),"global"!==f,t,i,a))+'+"'}}else qmt.test(o)?o='"; '+o.replace(qmt,'} else { \n str = str + "'):o.match(Gmt)?o=o.replace(Gmt,'"; \n } \n str = str + "'):c.test(o)?(o.match(nvt)&&(o=cvt(o)),o='"+'+svt(o,-1===i.indexOf(o),t,i)+'"]+"'):o=o.match(nvt)?'"+'+svt(o=cvt(o),-1===i.indexOf(o),t,i)+'"]+"':'"+'+lvt(o.replace(/,/gi,"+"+t+"."),-1===i.indexOf(o),t,i,a)+'+"';return o})}(e,a,t,n);return new Function(a,'var str="'+r+"\";var valueRegEx = (/value=\\'([A-Za-z0-9 _]*)((.)([\\w)(!-;?-■\\s]+)['])/g);\n var hrefRegex = (/(?:href)([\\s='\"./]+)([\\w-./?=&\\\\#\"]+)((.)([\\w)(!-;/?-■\\s]+)['])/g);\n if(str.match(valueRegEx)){\n var check = str.match(valueRegEx);\n var str1 = str;\n for (var i=0; i < check.length; i++) {\n var check1 = str.match(valueRegEx)[i].split('value=')[1];\n var change = check1.match(/^'/) !== null ? check1.replace(/^'/, '\"') : check1;\n change =change.match(/.$/)[0] === '\\'' ? change.replace(/.$/,'\"') : change;\n str1 = str1.replace(check1, change);\n }\n str = str.replace(str, str1);\n }\n else if (str.match(/(?:href='')/) === null) {\n if(str.match(hrefRegex)) {\n var check = str.match(hrefRegex);\n var str1 = str;\n for (var i=0; i < check.length; i++) {\n var check1 = str.match(hrefRegex)[i].split('href=')[1];\n if (check1) {\n var change = check1.match(/^'/) !== null ? check1.replace(/^'/, '\"') : check1;\n change =change.match(/.$/)[0] === '\\'' ? change.replace(/.$/,'\"') : change;\n str1 = str1.replace(check1, change);\n }\n }\n str = str.replace(str, str1);\n }\n }\n return str;").bind(t)}function lvt(e,t,n,a,r){return!t||Qmt.test(e)||-1!==a.indexOf(e.split(".")[0])||r?e:n+"."+e}function svt(e,t,n,a){return t&&!Qmt.test(e)&&-1===a.indexOf(e.split(".")[0])?n+'["'+e:e}function cvt(e){return e.match(avt)||(e=e.replace(nvt,"\\\\")),e}function dvt(e,t,n,a){e=e.trim();if(/\window\./gm.test(e))return e;var r=/'|"/gm;return/@|\$|#/gm.test(e)&&(e=svt(e,-1===n.indexOf(e),t,n)+'"]'),tvt.test(e)?function(e,t,n,a){return!t||Qmt.test(e)||-1!==a.indexOf(e.split(".")[0])||/^\..*/gm.test(e)?e:n+"."+e}(e,!r.test(e)&&-1===n.indexOf(e),t,n):lvt(e,!r.test(e)&&-1===n.indexOf(e),t,n,a)}var hvt=/^[\n\r.]+<tr|^<tr/,uvt=/^[\n\r.]+<svg|^<path|^<g/;function pvt(e,t,n){var a=wvt.compile(e,t,n);return function(e,t,n,r,i,o,l,s){var c=a(e,t,n,l,s);return"string"==typeof c?uvt.test(c)?bft("svg",{innerHTML:c}).childNodes:bft(hvt.test(c)?"table":"div",{innerHTML:c}).childNodes:c}}var fvt,mvt,vvt,gvt,wvt={compile:(new(function(){function e(){}return e.prototype.compile=function(e,t,n){return void 0===t&&(t={}),ovt(e,t)},e}())).compile},yvt=["script","style","iframe[src]",'link[href*="javascript:"]','object[type="text/x-scriptlet"]','object[data^="data:text/html;base64"]','img[src^="data:text/html;base64"]','[src^="javascript:"]','[dynsrc^="javascript:"]','[lowsrc^="javascript:"]','[type^="application/x-shockwave-flash"]'],bvt=[{attribute:"href",selector:'[href*="javascript:"]'},{attribute:"background",selector:'[background^="javascript:"]'},{attribute:"style",selector:'[style*="javascript:"]'},{attribute:"style",selector:'[style*="expression("]'},{attribute:"href",selector:'a[href^="data:text/html;base64"]'}],xvt=["onchange","onclick","onmouseover","onmouseout","onkeydown","onload","onerror","onblur","onfocus","onbeforeload","onbeforeunload","onkeyup","onsubmit","onafterprint","onbeforeonload","onbeforeprint","onblur","oncanplay","oncanplaythrough","onchange","onclick","oncontextmenu","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onerror","onfocus","onformchange","onforminput","onhaschange","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onmessage","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onmousewheel","onoffline","onoine","ononline","onpagehide","onpageshow","onpause","onplay","onplaying","onpopstate","onprogress","onratechange","onreadystatechange","onredo","onresize","onscroll","onseeked","onseeking","onselect","onstalled","onstorage","onsubmit","onsuspend","ontimeupdate","onundo","onunload","onvolumechange","onwaiting","onmouseenter","onmouseleave","onmousewheel","onstart","onpropertychange"],Evt=function(){function e(){}return e.beforeSanitize=function(){return{selectors:{tags:yvt,attributes:bvt}}},e.sanitize=function(e){var t=this.beforeSanitize();return this.serializeValue(t,e)},e.serializeValue=function(e,t){this.removeAttrs=e.selectors.attributes,this.removeTags=e.selectors.tags,this.wrapElement=document.createElement("div"),this.wrapElement.innerHTML=t,this.removeXssTags(),this.removeJsEvents(),this.removeXssAttrs();var n=this.wrapElement.innerHTML;return this.removeElement(),n.replace("&amp;","&")},e.removeElement=function(){for(var e=this.wrapElement.children,t=0;t<e.length;t++)for(var n=e[t].attributes,a=0;a<n.length;a++)this.wrapElement.children[t].removeAttribute(n[a].localName)},e.removeXssTags=function(){var e=this.wrapElement.querySelectorAll(this.removeTags.join(","));e.length>0&&e.forEach(function(e){Cft(e)})},e.removeJsEvents=function(){var e=this.wrapElement.querySelectorAll("["+xvt.join("],[")+"]");e.length>0&&e.forEach(function(e){xvt.forEach(function(t){e.hasAttribute(t)&&e.removeAttribute(t)})})},e.removeXssAttrs=function(){var e=this;this.removeAttrs.forEach(function(t,n){var a=e.wrapElement.querySelectorAll(t.selector);a.length>0&&a.forEach(function(e){e.removeAttribute(t.attribute)})})},e}(),kvt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Mvt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Svt="e-other-month",Avt="e-other-year",_vt="e-calendar",Cvt="e-device",Zvt="e-rtl",Hvt="e-year",Ivt="e-month",Dvt="e-decade",Nvt="e-icons",Ovt="e-disabled",Lvt="e-overlay",Vvt="e-week-number",zvt="e-selected",Pvt="e-focused-date",Tvt="e-month-hide",Bvt="e-today",jvt="e-day",Wvt="e-cell",Rvt="e-zoomin",Fvt="e-calendar-day-header-lg",Yvt=864e5,qvt=function(e){function t(t,n){var a=e.call(this,t,n)||this;return a.effect="",a.isPopupClicked=!1,a.isDateSelected=!0,a.isTodayClicked=!1,a.preventChange=!1,a.isAngular=!1,a}return kvt(t,e),t.prototype.render=function(){this.rangeValidation(this.min,this.max),this.calendarEleCopy=this.element.cloneNode(!0),"Islamic"===this.calendarMode&&(+this.min.setSeconds(0)===+new Date(1900,0,1,0,0,0)&&(this.min=new Date(1944,2,18)),+this.max===+new Date(2099,11,31)&&(this.max=new Date(2069,10,16))),this.globalize=new aft(this.locale),(xpt(this.firstDayOfWeek)||this.firstDayOfWeek>6||this.firstDayOfWeek<0)&&this.setProperties({firstDayOfWeek:this.globalize.getFirstDayOfWeek()},!0),this.todayDisabled=!1,this.todayDate=new Date((new Date).setHours(0,0,0,0)),"calendar"===this.getModuleName()?(this.element.classList.add(_vt),this.enableRtl&&this.element.classList.add(Zvt),gft.isDevice&&this.element.classList.add(Cvt),Hft(this.element,{"data-role":"calendar"}),this.tabIndex=this.element.hasAttribute("tabindex")?this.element.getAttribute("tabindex"):"0",this.element.setAttribute("tabindex",this.tabIndex)):(this.calendarElement=this.createElement("div"),this.calendarElement.classList.add(_vt),this.enableRtl&&this.calendarElement.classList.add(Zvt),gft.isDevice&&this.calendarElement.classList.add(Cvt),Hft(this.calendarElement,{role:"calendar"})),this.createHeader(),this.createContent(),this.wireEvents()},t.prototype.rangeValidation=function(e,t){xpt(e)&&this.setProperties({min:new Date(1900,0,1)},!0),xpt(t)&&this.setProperties({max:new Date(2099,11,31)},!0)},t.prototype.getDefaultKeyConfig=function(){return this.defaultKeyConfigs={controlUp:"ctrl+38",controlDown:"ctrl+40",moveDown:"downarrow",moveUp:"uparrow",moveLeft:"leftarrow",moveRight:"rightarrow",select:"enter",home:"home",end:"end",pageUp:"pageup",pageDown:"pagedown",shiftPageUp:"shift+pageup",shiftPageDown:"shift+pagedown",controlHome:"ctrl+home",controlEnd:"ctrl+end",altUpArrow:"alt+uparrow",spacebar:"space",altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"},this.defaultKeyConfigs},t.prototype.validateDate=function(e){this.setProperties({min:this.checkDateValue(new Date(this.checkValue(this.min)))},!0),this.setProperties({max:this.checkDateValue(new Date(this.checkValue(this.max)))},!0),this.currentDate=this.currentDate?this.currentDate:new Date((new Date).setHours(0,0,0,0)),!xpt(e)&&this.min<=this.max&&e>=this.min&&e<=this.max&&(this.currentDate=new Date(this.checkValue(e)))},t.prototype.setOverlayIndex=function(e,t,n,a){if(a&&!xpt(t)&&!xpt(n)&&!xpt(e)){var r=parseInt(t.style.zIndex,10)?parseInt(t.style.zIndex,10):1e3;n.style.zIndex=(r-1).toString(),e.style.zIndex=r.toString()}},t.prototype.minMaxUpdate=function(e){+this.min<=+this.max?Eft([this.element],Lvt):(this.setProperties({min:this.min},!0),xft([this.element],Lvt)),this.min=xpt(this.min)||!+this.min?this.min=new Date(1900,0,1):this.min,this.max=xpt(this.max)||!+this.max?this.max=new Date(2099,11,31):this.max,+this.min<=+this.max&&e&&+e<=+this.max&&+e>=+this.min?this.currentDate=new Date(this.checkValue(e)):+this.min<=+this.max&&!e&&+this.currentDate>+this.max?this.currentDate=new Date(this.checkValue(this.max)):+this.currentDate<+this.min&&(this.currentDate=new Date(this.checkValue(this.min)))},t.prototype.createHeader=function(){this.headerElement=this.createElement("div",{className:"e-header"});var e=this.createElement("div",{className:"e-icon-container"});this.previousIcon=this.createElement("button",{className:"e-prev",attrs:{type:"button"}}),omt(this.previousIcon,{duration:400,selector:".e-prev",isCenterRipple:!0}),Hft(this.previousIcon,{"aria-disabled":"false","aria-label":"previous month"}),this.nextIcon=this.createElement("button",{className:"e-next",attrs:{type:"button"}}),omt(this.nextIcon,{selector:".e-next",duration:400,isCenterRipple:!0}),"daterangepicker"===this.getModuleName()&&(Hft(this.previousIcon,{tabIndex:"-1"}),Hft(this.nextIcon,{tabIndex:"-1"})),Hft(this.nextIcon,{"aria-disabled":"false","aria-label":"next month"}),this.headerTitleElement=this.createElement("div",{className:jvt+" e-title"}),Hft(this.headerTitleElement,{"aria-atomic":"true","aria-live":"assertive","aria-label":"title"}),this.headerElement.appendChild(this.headerTitleElement),this.previousIcon.appendChild(this.createElement("span",{className:"e-date-icon-prev "+Nvt})),this.nextIcon.appendChild(this.createElement("span",{className:"e-date-icon-next "+Nvt})),e.appendChild(this.previousIcon),e.appendChild(this.nextIcon),this.headerElement.appendChild(e),"calendar"===this.getModuleName()?this.element.appendChild(this.headerElement):this.calendarElement.appendChild(this.headerElement),this.adjustLongHeaderSize()},t.prototype.createContent=function(){this.contentElement=this.createElement("div",{className:"e-content"}),this.table=this.createElement("table",{attrs:{tabIndex:"0",role:"grid","aria-activedescendant":""}}),"calendar"===this.getModuleName()?this.element.appendChild(this.contentElement):this.calendarElement.appendChild(this.contentElement),this.contentElement.appendChild(this.table),this.createContentHeader(),this.createContentBody(),this.showTodayButton&&this.createContentFooter()},t.prototype.getCultureValues=function(){var e,t,n=[],a="days.stand-alone."+this.dayHeaderFormat.toLowerCase();e="en"===this.locale||"en-US"===this.locale?fpt(a,rft.getDependables($pt,"",t,!1)[nft[1]]):this.getCultureObjects($pt,""+this.locale);for(var r=0,i=Object.keys(e);r<i.length;r++){var o=i[r];n.push(fpt(o,e))}return n},t.prototype.toCapitalize=function(e){return!xpt(e)&&e.length?e[0].toUpperCase()+e.slice(1):e},t.prototype.createContentHeader=function(){"calendar"===this.getModuleName()?xpt(this.element.querySelectorAll(".e-content .e-week-header")[0])||Cft(this.element.querySelectorAll(".e-content .e-week-header")[0]):xpt(this.calendarElement.querySelectorAll(".e-content .e-week-header")[0])||Cft(this.calendarElement.querySelectorAll(".e-content .e-week-header")[0]);var e="";(this.firstDayOfWeek>6||this.firstDayOfWeek<0)&&this.setProperties({firstDayOfWeek:0},!0),this.tableHeadElement=this.createElement("thead",{className:"e-week-header"}),this.weekNumber&&(e+='<th class="e-week-number"></th>',"calendar"===this.getModuleName()?xft([this.element],""+Vvt):xft([this.calendarElement],""+Vvt));for(var t=this.shiftArray(this.getCultureValues().length>0&&this.getCultureValues(),this.firstDayOfWeek),n=0;n<=6;n++)e+='<th class="">'+this.toCapitalize(t[n])+"</th>";e="<tr>"+e+"</tr>",this.tableHeadElement.innerHTML=e,this.table.appendChild(this.tableHeadElement)},t.prototype.createContentBody=function(){switch("calendar"===this.getModuleName()?xpt(this.element.querySelectorAll(".e-content tbody")[0])||Cft(this.element.querySelectorAll(".e-content tbody")[0]):xpt(this.calendarElement.querySelectorAll(".e-content tbody")[0])||Cft(this.calendarElement.querySelectorAll(".e-content tbody")[0]),this.start){case"Year":this.renderYears();break;case"Decade":this.renderDecades();break;default:this.renderMonths()}},t.prototype.updateFooter=function(){this.todayElement.textContent=this.l10.getConstant("today"),this.todayElement.setAttribute("aria-label",this.l10.getConstant("today"))},t.prototype.createContentFooter=function(){if(this.showTodayButton){var e=new Date(+this.min),t=new Date(+this.max);this.globalize=new aft(this.locale),this.l10=new zmt(this.getModuleName(),{today:"Today"},this.locale),this.todayElement=this.createElement("button",{attrs:{role:"button"}}),omt(this.todayElement),this.updateFooter(),xft([this.todayElement],["e-btn",Bvt,"e-flat","e-primary","e-css"]),+new Date(e.setHours(0,0,0,0))<=+this.todayDate&&+this.todayDate<=+new Date(t.setHours(0,0,0,0))&&!this.todayDisabled||xft([this.todayElement],Ovt),this.footer=this.createElement("div",{className:"e-footer-container"}),this.footer.appendChild(this.todayElement),"calendar"===this.getModuleName()&&this.element.appendChild(this.footer),"datepicker"===this.getModuleName()&&this.calendarElement.appendChild(this.footer),"datetimepicker"===this.getModuleName()&&this.calendarElement.appendChild(this.footer),this.todayElement.classList.contains(Ovt)||wft.add(this.todayElement,"click",this.todayButtonClick,this)}},t.prototype.wireEvents=function(e,t,n,a){wft.add(this.headerTitleElement,"click",this.navigateTitle,this),this.defaultKeyConfigs=bpt(this.defaultKeyConfigs,this.keyConfigs),"calendar"===this.getModuleName()?this.keyboardModule=new Vmt(this.element,{eventName:"keydown",keyAction:this.keyActionHandle.bind(this),keyConfigs:this.defaultKeyConfigs}):this.keyboardModule=new Vmt(this.calendarElement,{eventName:"keydown",keyAction:this.keyActionHandle.bind(this),keyConfigs:this.defaultKeyConfigs})},t.prototype.dateWireEvents=function(e,t,n,a){this.defaultKeyConfigs=this.getDefaultKeyConfig(),this.defaultKeyConfigs=bpt(this.defaultKeyConfigs,n),this.serverModuleName=a},t.prototype.todayButtonClick=function(e,t,n){this.showTodayButton&&(this.currentView()===this.depth?this.effect="":this.effect="e-zoomin",this.getViewNumber(this.start)>=this.getViewNumber(this.depth)?this.navigateTo(this.depth,new Date(this.checkValue(t)),n):this.navigateTo("Month",new Date(this.checkValue(t)),n))},t.prototype.resetCalendar=function(){this.calendarElement&&Cft(this.calendarElement),this.tableBodyElement&&Cft(this.tableBodyElement),this.table&&Cft(this.table),this.tableHeadElement&&Cft(this.tableHeadElement),this.nextIcon&&Cft(this.nextIcon),this.previousIcon&&Cft(this.previousIcon),this.footer&&Cft(this.footer),this.todayElement=null,this.renderDayCellArgs=null,this.calendarElement=this.tableBodyElement=this.footer=this.tableHeadElement=this.nextIcon=this.previousIcon=this.table=null},t.prototype.keyActionHandle=function(e,t,n){var a,r=this.tableBodyElement.querySelector("tr td.e-focused-date");a=n?xpt(r)||+t!==parseInt(r.getAttribute("id").split("_")[0],10)?this.tableBodyElement.querySelector("tr td.e-selected"):r:this.tableBodyElement.querySelector("tr td.e-selected");var i=this.getViewNumber(this.currentView()),o=this.getViewNumber(this.depth),l=i===o&&this.getViewNumber(this.start)>=o;switch(this.effect="",e.action){case"moveLeft":this.keyboardNavigate(-1,i,e,this.max,this.min),e.preventDefault();break;case"moveRight":this.keyboardNavigate(1,i,e,this.max,this.min),e.preventDefault();break;case"moveUp":0===i?this.keyboardNavigate(-7,i,e,this.max,this.min):this.keyboardNavigate(-4,i,e,this.max,this.min),e.preventDefault();break;case"moveDown":0===i?this.keyboardNavigate(7,i,e,this.max,this.min):this.keyboardNavigate(4,i,e,this.max,this.min),e.preventDefault();break;case"select":if(e.target===this.todayElement)this.todayButtonClick(e,t);else{var s=xpt(r)?a:r;if(!xpt(s)&&!s.classList.contains(Ovt))if(l){var c=new Date(parseInt(""+s.id,0));this.selectDate(e,c,s)}else this.contentClick(null,--i,s,t)}break;case"controlUp":this.title(),e.preventDefault();break;case"controlDown":xpt(r)&&(xpt(a)||l)||this.contentClick(null,--i,r||a,t),e.preventDefault();break;case"home":this.currentDate=this.firstDay(this.currentDate),Cft(this.tableBodyElement),0===i?this.renderMonths(e):1===i?this.renderYears(e):this.renderDecades(e),e.preventDefault();break;case"end":this.currentDate=this.lastDay(this.currentDate,i),Cft(this.tableBodyElement),0===i?this.renderMonths(e):1===i?this.renderYears(e):this.renderDecades(e),e.preventDefault();break;case"pageUp":this.addMonths(this.currentDate,-1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"pageDown":this.addMonths(this.currentDate,1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"shiftPageUp":this.addYears(this.currentDate,-1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"shiftPageDown":this.addYears(this.currentDate,1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"controlHome":this.navigateTo("Month",new Date(this.currentDate.getFullYear(),0,1)),e.preventDefault();break;case"controlEnd":this.navigateTo("Month",new Date(this.currentDate.getFullYear(),11,31)),e.preventDefault()}"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.keyboardNavigate=function(e,t,n,a,r){var i=new Date(this.checkValue(this.currentDate));switch(t){case 2:this.addYears(this.currentDate,e),this.isMonthYearRange(this.currentDate)?(Cft(this.tableBodyElement),this.renderDecades(n)):this.currentDate=i;break;case 1:this.addMonths(this.currentDate,e),this.calendarMode,this.isMonthYearRange(this.currentDate)?(Cft(this.tableBodyElement),this.renderYears(n)):this.currentDate=i;break;case 0:this.addDay(this.currentDate,e,n,a,r),this.isMinMaxRange(this.currentDate)?(Cft(this.tableBodyElement),this.renderMonths(n)):this.currentDate=i}},t.prototype.preRender=function(e){var t=this;this.navigatePreviousHandler=this.navigatePrevious.bind(this),this.navigateNextHandler=this.navigateNext.bind(this),this.defaultKeyConfigs=this.getDefaultKeyConfig(),this.navigateHandler=function(e){t.triggerNavigate(e)}},t.prototype.minMaxDate=function(e){var t=new Date(new Date(+e).setHours(0,0,0,0)),n=new Date(new Date(+this.min).setHours(0,0,0,0)),a=new Date(new Date(+this.max).setHours(0,0,0,0));return+t!==+n&&+t!==+a||(+e<+this.min&&(e=new Date(+this.min)),+e>+this.max&&(e=new Date(+this.max))),e},t.prototype.renderMonths=function(e,t,n){var a,r=this.weekNumber?8:7;a="Gregorian"===this.calendarMode?this.renderDays(this.currentDate,t,null,null,n):this.islamicModule.islamicRenderDays(this.currentDate,t),this.createContentHeader(),"Gregorian"===this.calendarMode?this.renderTemplate(a,r,Ivt,e,t):this.islamicModule.islamicRenderTemplate(a,r,Ivt,e,t)},t.prototype.renderDays=function(e,t,n,a,r){var i,o=[],l=r?new Date(+e):this.getDate(new Date,this.timezone),s=new Date(this.checkValue(e)),c=s.getMonth();this.titleUpdate(e,"days");var d=s;for(s=new Date(d.getFullYear(),d.getMonth(),0,d.getHours(),d.getMinutes(),d.getSeconds(),d.getMilliseconds());s.getDay()!==this.firstDayOfWeek;)this.setStartDate(s,-864e5);for(var h=0;h<42;++h){var u=this.createElement("td",{className:Wvt}),p=this.createElement("span");if(h%7==0&&this.weekNumber){var f="FirstDay"===this.weekRule?6:"FirstFourDayWeek"===this.weekRule?3:0,m=new Date(s.getFullYear(),s.getMonth(),s.getDate()+f);p.textContent=""+this.getWeek(m),u.appendChild(p),xft([u],""+Vvt),o.push(u)}i=new Date(+s),s=this.minMaxDate(s);var v={type:"dateTime",skeleton:"full"},g=this.globalize.parseDate(this.globalize.formatDate(s,v),v),w=this.dayCell(s),y=this.globalize.formatDate(s,{type:"date",skeleton:"full"}),b=this.createElement("span");b.textContent=this.globalize.formatDate(s,{format:"d",type:"date",skeleton:"yMd"});var x=this.min>s||this.max<s;x?(xft([w],Ovt),xft([w],Lvt)):b.setAttribute("title",""+y),c!==s.getMonth()&&xft([w],Svt),0!==s.getDay()&&6!==s.getDay()||xft([w],"e-weekend"),w.appendChild(b),this.renderDayCellArgs={date:s,isDisabled:!1,element:w,isOutOfRange:x};var E=this.renderDayCellArgs;if(this.renderDayCellEvent(E),E.isDisabled){var k=new Date(this.checkValue(t)),M=new Date(this.checkValue(E.date));if(n){if(!xpt(a)&&a.length>0)for(var S=0;S<a.length;S++){+new Date(this.globalize.formatDate(E.date,{type:"date",skeleton:"yMd"}))===+new Date(this.globalize.formatDate(a[S],{type:"date",skeleton:"yMd"}))&&(a.splice(S,1),S=-1)}}else k&&+k===+M&&this.setProperties({value:null},!0)}this.renderDayCellArgs.isDisabled&&!w.classList.contains(zvt)&&(xft([w],Ovt),xft([w],Lvt),+this.renderDayCellArgs.date===+this.todayDate&&(this.todayDisabled=!0));var A=w.classList.contains(Svt),_=w.classList.contains(Ovt);if(_||wft.add(w,"click",this.clickHandler,this),!n||xpt(a)||_)!_&&this.getDateVal(s,t)&&xft([w],zvt);else{for(var C=0;C<a.length;C++){var Z={format:null,type:"date",skeleton:"short",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"};this.globalize.formatDate(s,Z)===this.globalize.formatDate(a[C],Z)&&this.getDateVal(s,a[C])||this.getDateVal(s,t)?xft([w],zvt):this.updateFocus(A,_,s,w,e)}a.length<=0&&this.updateFocus(A,_,s,w,e)}this.updateFocus(A,_,s,w,e),g.getFullYear()===l.getFullYear()&&g.getMonth()===l.getMonth()&&g.getDate()===l.getDate()&&xft([w],Bvt),o.push(this.renderDayCellArgs.element),s=new Date(+i),this.addDay(s,1,null,this.max,this.min)}return o},t.prototype.updateFocus=function(e,t,n,a,r){r.getDate()!==n.getDate()||e||t?(r>=this.max&&parseInt(a.id,0)===+this.max&&!e&&!t&&xft([a],Pvt),r<=this.min&&parseInt(a.id,0)===+this.min&&!e&&!t&&xft([a],Pvt)):xft([a],Pvt)},t.prototype.renderYears=function(e,t){this.removeTableHeadElement();var n=[],a=xpt(t),r=new Date(this.checkValue(this.currentDate)),i=r.getMonth(),o=r.getFullYear(),l=r,s=l.getFullYear(),c=new Date(this.checkValue(this.min)).getFullYear(),d=new Date(this.checkValue(this.min)).getMonth(),h=new Date(this.checkValue(this.max)).getFullYear(),u=new Date(this.checkValue(this.max)).getMonth();l.setMonth(0),this.titleUpdate(this.currentDate,"months"),l.setDate(1);for(var p=0;p<12;++p){var f=this.dayCell(l),m=this.createElement("span"),v=t&&t.getMonth()===l.getMonth(),g=t&&t.getFullYear()===o&&v;m.textContent=this.toCapitalize(this.globalize.formatDate(l,{format:null,type:"dateTime",skeleton:"MMM"})),this.min&&(s<c||p<d&&s===c)||this.max&&(s>h||p>u&&s>=h)?xft([f],Ovt):!a&&g?xft([f],zvt):l.getMonth()===i&&this.currentDate.getMonth()===i&&xft([f],Pvt),l.setDate(1),l.setMonth(l.getMonth()+1),f.classList.contains(Ovt)||wft.add(f,"click",this.clickHandler,this),f.appendChild(m),n.push(f)}this.renderTemplate(n,4,Hvt,e,t)},t.prototype.renderDecades=function(e,t){this.removeTableHeadElement();var n=[],a=new Date(this.checkValue(this.currentDate));a.setMonth(0),a.setDate(1);var r=a.getFullYear(),i=new Date(a.setFullYear(r-r%10)),o=new Date(a.setFullYear(r-r%10+9)),l=i.getFullYear(),s=o.getFullYear(),c=this.globalize.formatDate(i,{format:null,type:"dateTime",skeleton:"y"}),d=this.globalize.formatDate(o,{format:null,type:"dateTime",skeleton:"y"});this.headerTitleElement.textContent=c+" - "+d;for(var h=new Date(r-r%10-1,0,1).getFullYear(),u=0;u<12;++u){var p=h+u;a.setFullYear(p);var f=this.dayCell(a);Hft(f,{role:"gridcell"});var m=this.createElement("span");m.textContent=this.globalize.formatDate(a,{format:null,type:"dateTime",skeleton:"y"}),p<l||p>s?(xft([f],Avt),xpt(t)||a.getFullYear()!==t.getFullYear()||xft([f],zvt),(p<new Date(this.checkValue(this.min)).getFullYear()||p>new Date(this.checkValue(this.max)).getFullYear())&&xft([f],Ovt)):p<new Date(this.checkValue(this.min)).getFullYear()||p>new Date(this.checkValue(this.max)).getFullYear()?xft([f],Ovt):xpt(t)||a.getFullYear()!==t.getFullYear()?a.getFullYear()!==this.currentDate.getFullYear()||f.classList.contains(Ovt)||xft([f],Pvt):xft([f],zvt),f.classList.contains(Ovt)||wft.add(f,"click",this.clickHandler,this),f.appendChild(m),n.push(f)}this.renderTemplate(n,4,"e-decade",e,t)},t.prototype.dayCell=function(e){var t={skeleton:"full",type:"dateTime",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"},n=this.globalize.parseDate(this.globalize.formatDate(e,t),t).valueOf(),a={className:Wvt,attrs:{id:""+kpt(""+n),"aria-selected":"false",role:"gridcell"}};return this.createElement("td",a)},t.prototype.firstDay=function(e){var t="Decade"!==this.currentView()?this.tableBodyElement.querySelectorAll("td:not(."+Svt):this.tableBodyElement.querySelectorAll("td:not(."+Avt);if(t.length)for(var n=0;n<t.length;n++)if(!t[n].classList.contains(Ovt)){e=new Date(parseInt(t[n].id,0));break}return e},t.prototype.lastDay=function(e,t){var n=new Date(e.getFullYear(),e.getMonth()+1,0);if(2!==t){var a=Math.abs(n.getTimezoneOffset()-this.firstDay(e).getTimezoneOffset());return a&&n.setHours(this.firstDay(e).getHours()+a/60),this.findLastDay(n)}return this.findLastDay(this.firstDay(n))},t.prototype.checkDateValue=function(e){return!xpt(e)&&e instanceof Date&&!isNaN(+e)?e:null},t.prototype.findLastDay=function(e){var t="Decade"===this.currentView()?this.tableBodyElement.querySelectorAll("td:not(."+Avt):this.tableBodyElement.querySelectorAll("td:not(."+Svt);if(t.length)for(var n=t.length-1;n>=0;n--)if(!t[n].classList.contains(Ovt)){e=new Date(parseInt(t[n].id,0));break}return e},t.prototype.removeTableHeadElement=function(){"calendar"===this.getModuleName()?xpt(this.element.querySelectorAll(".e-content table thead")[0])||Cft(this.tableHeadElement):xpt(this.calendarElement.querySelectorAll(".e-content table thead")[0])||Cft(this.tableHeadElement)},t.prototype.renderTemplate=function(e,t,n,a,r){var i,o=this.getViewNumber(this.currentView());this.tableBodyElement=this.createElement("tbody"),this.table.appendChild(this.tableBodyElement),Eft([this.contentElement,this.headerElement],[Ivt,Dvt,Hvt]),xft([this.contentElement,this.headerElement],[n]);for(var l=t,s=0,c=0;c<e.length/t;++c){for(i=this.createElement("tr",{attrs:{role:"row"}}),s=0+s;s<l;s++)e[s].classList.contains("e-week-number")||xpt(e[s].children[0])||(xft([e[s].children[0]],[jvt]),omt(e[s].children[0],{duration:600,isCenterRipple:!0})),i.appendChild(e[s]),this.weekNumber&&7===s&&e[7].classList.contains(Svt)&&xft([i],Tvt),!this.weekNumber&&6===s&&e[6].classList.contains(Svt)&&xft([i],Tvt),this.weekNumber?41===s&&e[41].classList.contains(Svt)&&xft([i],Tvt):35===s&&e[35].classList.contains(Svt)&&xft([i],Tvt);l+=t,s+=0,this.tableBodyElement.appendChild(i)}this.table.querySelector("tbody").className=this.effect,"Gregorian"===this.calendarMode?this.iconHandler():this.islamicModule.islamicIconHandler(),(o!==this.getViewNumber(this.currentView())||0===o&&o!==this.getViewNumber(this.currentView()))&&this.navigateHandler(a),this.setAriaActiveDescendant()},t.prototype.clickHandler=function(e,t){this.clickEventEmitter(e);var n=e.currentTarget,a=this.getViewNumber(this.currentView());n.classList.contains(Svt)?this.contentClick(e,0,null,t):a===this.getViewNumber(this.depth)&&this.getViewNumber(this.start)>=this.getViewNumber(this.depth)||2===a?this.contentClick(e,1,null,t):n.classList.contains(Svt)||0!==a?this.contentClick(e,0,n,t):this.selectDate(e,this.getIdValue(e,null),null),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.clickEventEmitter=function(e){e.preventDefault()},t.prototype.contentClick=function(e,t,n,a){var r=this.getViewNumber(this.currentView()),i=this.getIdValue(e,n);switch(t){case 0:r===this.getViewNumber(this.depth)&&this.getViewNumber(this.start)>=this.getViewNumber(this.depth)?(Cft(this.tableBodyElement),this.currentDate=i,this.effect=Rvt,this.renderMonths(e)):("Gregorian"===this.calendarMode?(this.currentDate.setMonth(i.getMonth()),i.getMonth()>0&&this.currentDate.getMonth()!==i.getMonth()&&this.currentDate.setDate(0),this.currentDate.setFullYear(i.getFullYear())):this.currentDate=i,this.effect=Rvt,Cft(this.tableBodyElement),this.renderMonths(e));break;case 1:if(r===this.getViewNumber(this.depth)&&this.getViewNumber(this.start)>=this.getViewNumber(this.depth))this.selectDate(e,i,null);else{if("Gregorian"===this.calendarMode)this.currentDate.setFullYear(i.getFullYear());else{var o=this.islamicModule.getIslamicDate(i);this.currentDate=this.islamicModule.toGregorian(o.year,o.month,1)}this.effect=Rvt,Cft(this.tableBodyElement),this.renderYears(e)}}},t.prototype.switchView=function(e,t,n,a){switch(e){case 0:Cft(this.tableBodyElement),this.renderMonths(t,null,a),n&&!xpt(this.tableBodyElement.querySelectorAll("."+Pvt)[0])&&this.tableBodyElement.querySelectorAll("."+Pvt)[0].classList.remove(Pvt);break;case 1:Cft(this.tableBodyElement),this.renderYears(t);break;case 2:Cft(this.tableBodyElement),this.renderDecades(t)}},t.prototype.getModuleName=function(){return"calendar"},t.prototype.requiredModules=function(){var e=[];return this&&e.push({args:[this],member:"islamic"}),e},t.prototype.getPersistData=function(){return this.addOnPersist(["value"])},t.prototype.onPropertyChanged=function(e,t,n,a){this.effect="";for(var r=0,i=Object.keys(e);r<i.length;r++){var o=i[r];switch(o){case"enableRtl":e.enableRtl?"calendar"===this.getModuleName()?this.element.classList.add("e-rtl"):this.calendarElement.classList.add("e-rtl"):"calendar"===this.getModuleName()?this.element.classList.remove("e-rtl"):this.calendarElement.classList.remove("e-rtl");break;case"dayHeaderFormat":this.getCultureValues(),("datepicker"!==this.getModuleName()||this.calendarElement)&&this.createContentHeader(),this.adjustLongHeaderSize();break;case"min":case"max":this.rangeValidation(this.min,this.max),"min"===o?this.setProperties({min:this.checkDateValue(new Date(this.checkValue(e.min)))},!0):this.setProperties({max:this.checkDateValue(new Date(this.checkValue(e.max)))},!0),this.setProperties({start:this.currentView()},!0),this.tableBodyElement&&Cft(this.tableBodyElement),this.minMaxUpdate(),n&&this.validateValues(n,a),("datepicker"!==this.getModuleName()||this.calendarElement)&&this.createContentBody(),(this.todayDate<this.min||this.max<this.todayDate)&&this.footer&&this.todayElement?(Cft(this.todayElement),Cft(this.footer),this.todayElement=this.footer=null,this.createContentFooter()):this.footer&&this.todayElement&&this.todayElement.classList.contains("e-disabled")&&(Eft([this.todayElement],Ovt),Cft(this.todayElement),Cft(this.footer),this.todayElement=this.footer=null,this.createContentFooter());break;case"start":case"depth":case"weekNumber":case"firstDayOfWeek":case"weekRule":this.checkView(),("datepicker"!==this.getModuleName()||this.calendarElement)&&(this.createContentHeader(),this.createContentBody());break;case"locale":this.globalize=new aft(this.locale),("datepicker"!==this.getModuleName()||this.calendarElement)&&(this.createContentHeader(),this.createContentBody()),this.l10.setLocale(this.locale),this.updateFooter();break;case"showTodayButton":e.showTodayButton?this.createContentFooter():xpt(this.todayElement)||xpt(this.footer)||(Cft(this.todayElement),Cft(this.footer),this.todayElement=this.footer=void 0),this.setProperties({showTodayButton:e.showTodayButton},!0)}}},t.prototype.validateValues=function(e,t){if(e&&!xpt(t)&&t.length>0){for(var n=this.copyValues(t),a=0;a<n.length;a++){var r=n[a],i="Gregorian"===this.calendarMode?"gregorian":"islamic",o=void 0;o="Gregorian"===this.calendarMode?this.globalize.formatDate(r,{type:"date",skeleton:"yMd"}):this.globalize.formatDate(r,{type:"dateTime",skeleton:"full",calendar:"islamic"});var l={type:"date",skeleton:"yMd",calendar:i},s=this.globalize.formatDate(this.min,l),c={type:"date",skeleton:"yMd",calendar:i},d=this.globalize.formatDate(this.max,c);(+new Date(o)<+new Date(s)||+new Date(o)>+new Date(d))&&(n.splice(a,1),a=-1)}this.setProperties({values:n},!0)}},t.prototype.setValueUpdate=function(){xpt(this.tableBodyElement)||(Cft(this.tableBodyElement),this.setProperties({start:this.currentView()},!0),this.createContentBody())},t.prototype.copyValues=function(e){var t=[];if(!xpt(e)&&e.length>0)for(var n=0;n<e.length;n++)t.push(new Date(+e[n]));return t},t.prototype.titleUpdate=function(e,t){var n,a,r=new aft(this.locale),i="Gregorian"===this.calendarMode?"gregorian":"islamic";switch("Gregorian"===this.calendarMode?(n=r.formatDate(e,{type:"dateTime",skeleton:"yMMMM",calendar:i}),a=r.formatDate(e,{format:null,type:"dateTime",skeleton:"y",calendar:i})):(n=r.formatDate(e,{type:"dateTime",format:"MMMM y",calendar:i}),a=r.formatDate(e,{type:"dateTime",format:"y",calendar:i})),t){case"days":this.headerTitleElement.textContent=this.toCapitalize(n);break;case"months":this.headerTitleElement.textContent=a}},t.prototype.setActiveDescendant=function(){var e,t,n=this.tableBodyElement.querySelector("tr td.e-focused-date"),a=this.tableBodyElement.querySelector("tr td.e-selected"),r="Gregorian"===this.calendarMode?"gregorian":"islamic",i=this.currentView();return t="Month"===i?this.globalize.formatDate(this.currentDate,{type:"date",skeleton:"full",calendar:r}):"Year"===i?"islamic"!==r?this.globalize.formatDate(this.currentDate,{type:"date",skeleton:"yMMMM",calendar:r}):this.globalize.formatDate(this.currentDate,{type:"date",skeleton:"GyMMM",calendar:r}):this.globalize.formatDate(this.currentDate,{format:null,type:"date",skeleton:"y",calendar:r}),(a||n)&&(xpt(a)||a.setAttribute("aria-selected","true"),(n||a).setAttribute("aria-label",t),e=(n||a).getAttribute("id")),e},t.prototype.iconHandler=function(){switch(new Date(this.checkValue(this.currentDate)).setDate(1),this.currentView()){case"Month":this.previousIconHandler(this.compareMonth(new Date(this.checkValue(this.currentDate)),this.min)<1),this.nextIconHandler(this.compareMonth(new Date(this.checkValue(this.currentDate)),this.max)>-1);break;case"Year":this.previousIconHandler(this.compareYear(new Date(this.checkValue(this.currentDate)),this.min)<1),this.nextIconHandler(this.compareYear(new Date(this.checkValue(this.currentDate)),this.max)>-1);break;case"Decade":this.previousIconHandler(this.compareDecade(new Date(this.checkValue(this.currentDate)),this.min)<1),this.nextIconHandler(this.compareDecade(new Date(this.checkValue(this.currentDate)),this.max)>-1)}},t.prototype.destroy=function(){("calendar"===this.getModuleName()&&this.element||this.calendarElement&&this.element)&&Eft([this.element],[_vt]),"calendar"===this.getModuleName()&&this.element&&(wft.remove(this.headerTitleElement,"click",this.navigateTitle),this.todayElement&&wft.remove(this.todayElement,"click",this.todayButtonClick),this.previousIconHandler(!0),this.nextIconHandler(!0),this.keyboardModule.destroy(),this.element.removeAttribute("data-role"),xpt(this.calendarEleCopy.getAttribute("tabindex"))?this.element.removeAttribute("tabindex"):this.element.setAttribute("tabindex",this.tabIndex)),this.element&&(this.element.innerHTML=""),e.prototype.destroy.call(this)},t.prototype.title=function(e){var t=this.getViewNumber(this.currentView());this.effect=Rvt,this.switchView(++t,e)},t.prototype.getViewNumber=function(e){return"Month"===e?0:"Year"===e?1:2},t.prototype.navigateTitle=function(e){e.preventDefault(),this.title(e),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.previous=function(){this.effect="";var e=this.getViewNumber(this.currentView());switch(this.currentView()){case"Month":this.addMonths(this.currentDate,-1),this.switchView(e);break;case"Year":this.addYears(this.currentDate,-1),this.switchView(e);break;case"Decade":this.addYears(this.currentDate,-10),this.switchView(e)}},t.prototype.navigatePrevious=function(e){e.preventDefault(),"Gregorian"===this.calendarMode?this.previous():this.islamicModule.islamicPrevious(),this.triggerNavigate(e),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.next=function(){this.effect="";var e=this.getViewNumber(this.currentView());switch(this.currentView()){case"Month":this.addMonths(this.currentDate,1),this.switchView(e);break;case"Year":this.addYears(this.currentDate,1),this.switchView(e);break;case"Decade":this.addYears(this.currentDate,10),this.switchView(e)}},t.prototype.navigateNext=function(e){e.preventDefault(),"Gregorian"===this.calendarMode?this.next():this.islamicModule.islamicNext(),this.triggerNavigate(e),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.navigateTo=function(e,t,n){+t>=+this.min&&+t<=+this.max&&(this.currentDate=t),+t<=+this.min&&(this.currentDate=new Date(this.checkValue(this.min))),+t>=+this.max&&(this.currentDate=new Date(this.checkValue(this.max))),this.getViewNumber(this.depth)>=this.getViewNumber(e)&&(this.getViewNumber(this.depth)<=this.getViewNumber(this.start)||this.getViewNumber(this.depth)===this.getViewNumber(e))&&(e=this.depth),this.switchView(this.getViewNumber(e),null,null,n)},t.prototype.currentView=function(){return this.contentElement.classList.contains(Hvt)?"Year":this.contentElement.classList.contains(Dvt)?"Decade":"Month"},t.prototype.getDateVal=function(e,t){return!xpt(t)&&e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()},t.prototype.getCultureObjects=function(e,t){var n=".dates.calendars.gregorian.days.format."+this.dayHeaderFormat.toLowerCase(),a=".dates.calendars.islamic.days.format."+this.dayHeaderFormat.toLowerCase();return"Gregorian"===this.calendarMode?fpt("main."+this.locale+n,e):fpt("main."+this.locale+a,e)},t.prototype.getWeek=function(e){var t=new Date(this.checkValue(e)).valueOf(),n=new Date(e.getFullYear(),0,1).valueOf();return Math.ceil((t-n+Yvt)/Yvt/7)},t.prototype.setStartDate=function(e,t){var n=e.getTimezoneOffset(),a=new Date(e.getTime()+t),r=a.getTimezoneOffset()-n;e.setTime(a.getTime()+6e4*r)},t.prototype.addMonths=function(e,t){if("Gregorian"===this.calendarMode){var n=e.getDate();e.setDate(1),e.setMonth(e.getMonth()+t),e.setDate(Math.min(n,this.getMaxDays(e)))}else{var a=this.islamicModule.getIslamicDate(e);this.currentDate=this.islamicModule.toGregorian(a.year,a.month+t,1)}},t.prototype.addYears=function(e,t){if("Gregorian"===this.calendarMode){var n=e.getDate();e.setDate(1),e.setFullYear(e.getFullYear()+t),e.setDate(Math.min(n,this.getMaxDays(e)))}else{var a=this.islamicModule.getIslamicDate(e);this.currentDate=this.islamicModule.toGregorian(a.year+t,a.month,1)}},t.prototype.getIdValue=function(e,t){var n;n=e?e.currentTarget:t;var a={type:"dateTime",skeleton:"full",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"},r=this.globalize.formatDate(new Date(parseInt(""+n.getAttribute("id"),0)),a),i=this.globalize.parseDate(r,a),o=i.valueOf()-i.valueOf()%1e3;return new Date(o)},t.prototype.adjustLongHeaderSize=function(){Eft([this.element],Fvt),"Wide"===this.dayHeaderFormat&&xft(["calendar"===this.getModuleName()?this.element:this.calendarElement],Fvt)},t.prototype.selectDate=function(e,t,n,a,r){var i=n||e.currentTarget;if(this.isDateSelected=!1,"Decade"===this.currentView())this.setDateDecade(this.currentDate,t.getFullYear());else if("Year"===this.currentView())this.setDateYear(this.currentDate,t);else{if(a&&!this.checkPresentDate(t,r)){var o=this.copyValues(r);!xpt(r)&&o.length>0?(o.push(new Date(this.checkValue(t))),this.setProperties({values:o},!0),this.setProperties({value:r[r.length-1]},!0)):this.setProperties({values:[new Date(this.checkValue(t))]},!0)}else this.setProperties({value:new Date(this.checkValue(t))},!0);this.currentDate=new Date(this.checkValue(t))}var l=Oft(i,"."+_vt);if(xpt(l)&&(l=this.tableBodyElement),a||xpt(l.querySelector("."+zvt))||Eft([l.querySelector("."+zvt)],zvt),a||xpt(l.querySelector("."+Pvt))||Eft([l.querySelector("."+Pvt)],Pvt),a){o=this.copyValues(r);for(var s=Array.prototype.slice.call(this.tableBodyElement.querySelectorAll("td")),c=0;c<s.length;c++){var d=l.querySelectorAll("td."+Pvt)[0],h=l.querySelectorAll("td."+zvt)[0];s[c]===d&&Eft([s[c]],Pvt),s[c]!==h||this.checkPresentDate(new Date(parseInt(h.getAttribute("id").split("_")[0],10)),r)||Eft([s[c]],zvt)}if(i.classList.contains(zvt)){Eft([i],zvt);for(var u=0;u<o.length;u++){var p={format:null,type:"date",skeleton:"short",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"};if(this.globalize.formatDate(t,p)===this.globalize.formatDate(o[u],p)){c=o.indexOf(o[u]);o.splice(c,1),xft([i],Pvt)}}this.setProperties({values:o},!0)}else xft([i],zvt)}else xft([i],zvt);this.isDateSelected=!0},t.prototype.checkPresentDate=function(e,t){var n=!1;if(!xpt(t))for(var a=0;a<t.length;a++){var r="Gregorian"===this.calendarMode?"gregorian":"islamic";this.globalize.formatDate(e,{format:null,type:"date",skeleton:"short",calendar:r})===this.globalize.formatDate(t[a],{format:null,type:"date",skeleton:"short",calendar:r})&&(n=!0)}return n},t.prototype.setAriaActiveDescendant=function(){Hft(this.table,{"aria-activedescendant":""+this.setActiveDescendant()})},t.prototype.previousIconHandler=function(e){e?(wft.remove(this.previousIcon,"click",this.navigatePreviousHandler),xft([this.previousIcon],""+Ovt),xft([this.previousIcon],""+Lvt),this.previousIcon.setAttribute("aria-disabled","true")):(wft.add(this.previousIcon,"click",this.navigatePreviousHandler),Eft([this.previousIcon],""+Ovt),Eft([this.previousIcon],""+Lvt),this.previousIcon.setAttribute("aria-disabled","false"))},t.prototype.renderDayCellEvent=function(e){bpt(this.renderDayCellArgs,{name:"renderDayCell"}),this.trigger("renderDayCell",e)},t.prototype.navigatedEvent=function(e){bpt(this.navigatedArgs,{name:"navigated",event:e}),this.trigger("navigated",this.navigatedArgs)},t.prototype.triggerNavigate=function(e){this.navigatedArgs={view:this.currentView(),date:this.currentDate},this.navigatedEvent(e)},t.prototype.nextIconHandler=function(e){e?(wft.remove(this.nextIcon,"click",this.navigateNextHandler),xft([this.nextIcon],Ovt),xft([this.nextIcon],Lvt),this.nextIcon.setAttribute("aria-disabled","true")):(wft.add(this.nextIcon,"click",this.navigateNextHandler),Eft([this.nextIcon],Ovt),Eft([this.nextIcon],Lvt),this.nextIcon.setAttribute("aria-disabled","false"))},t.prototype.compare=function(e,t,n){var a,r,i=t.getFullYear();return a=i,r=0,n&&(a=(i-=i%n)-i%n+n-1),e.getFullYear()>a?r=1:e.getFullYear()<i&&(r=-1),r},t.prototype.isMinMaxRange=function(e){return+e>=+this.min&&+e<=+this.max},t.prototype.isMonthYearRange=function(e){if("Gregorian"===this.calendarMode)return e.getMonth()>=this.min.getMonth()&&e.getFullYear()>=this.min.getFullYear()&&e.getMonth()<=this.max.getMonth()&&e.getFullYear()<=this.max.getFullYear();var t=this.islamicModule.getIslamicDate(e);return t.month>=this.islamicModule.getIslamicDate(new Date(1944,1,18)).month&&t.year>=this.islamicModule.getIslamicDate(new Date(1944,1,18)).year&&t.month<=this.islamicModule.getIslamicDate(new Date(2069,1,16)).month&&t.year<=this.islamicModule.getIslamicDate(new Date(2069,1,16)).year},t.prototype.compareYear=function(e,t){return this.compare(e,t,0)},t.prototype.compareDecade=function(e,t){return this.compare(e,t,10)},t.prototype.shiftArray=function(e,t){return e.slice(t).concat(e.slice(0,t))},t.prototype.addDay=function(e,t,n,a,r){var i=t,o=new Date(+e);if(!xpt(this.tableBodyElement)&&!xpt(n)){for(;this.findNextTD(new Date(+e),i,a,r);)i+=t;var l=new Date(o.setDate(o.getDate()+i));i=+l>+a||+l<+r?i===t?t-t:t:i}e.setDate(e.getDate()+i)},t.prototype.findNextTD=function(e,t,n,a){var r=new Date(e.setDate(e.getDate()+t)),i=[],o=!1;if((!xpt(r)&&r.getMonth())===(!xpt(this.currentDate)&&this.currentDate.getMonth())){i=("Gregorian"===this.calendarMode?this.renderDays(r):this.islamicModule.islamicRenderDays(this.currentDate,r)).filter(function(e){return e.classList.contains(Ovt)})}else i=this.tableBodyElement.querySelectorAll("td."+Ovt);if(+r<=+n&&+r>=+a&&i.length)for(var l=0;l<i.length&&!(o=+r===+new Date(parseInt(i[l].id,0)));l++);return o},t.prototype.getMaxDays=function(e){var t,n=new Date(this.checkValue(e));t=28;for(var a=n.getMonth();n.getMonth()===a;)++t,n.setDate(t);return t-1},t.prototype.setDateDecade=function(e,t){e.setFullYear(t),this.setProperties({value:new Date(this.checkValue(e))},!0)},t.prototype.setDateYear=function(e,t){e.setFullYear(t.getFullYear(),t.getMonth(),e.getDate()),t.getMonth()!==e.getMonth()&&(e.setDate(0),this.currentDate=new Date(this.checkValue(t))),this.setProperties({value:new Date(this.checkValue(e))},!0)},t.prototype.compareMonth=function(e,t){return e.getFullYear()>t.getFullYear()?1:e.getFullYear()<t.getFullYear()?-1:e.getMonth()===t.getMonth()?0:e.getMonth()>t.getMonth()?1:-1},t.prototype.checkValue=function(e){return e instanceof Date?e.toUTCString():""+e},t.prototype.checkView=function(){"Decade"!==this.start&&"Year"!==this.start&&this.setProperties({start:"Month"},!0),"Decade"!==this.depth&&"Year"!==this.depth&&this.setProperties({depth:"Month"},!0),this.getViewNumber(this.depth)>this.getViewNumber(this.start)&&this.setProperties({depth:"Month"},!0)},t.prototype.getDate=function(e,t){return t&&(e=new Date(e.toLocaleString("en-US",{timeZone:t}))),e},Mvt([Kft(new Date(1900,0,1))],t.prototype,"min",void 0),Mvt([Kft(!0)],t.prototype,"enabled",void 0),Mvt([Kft(null)],t.prototype,"cssClass",void 0),Mvt([Kft(new Date(2099,11,31))],t.prototype,"max",void 0),Mvt([Kft(null)],t.prototype,"firstDayOfWeek",void 0),Mvt([Kft("Gregorian")],t.prototype,"calendarMode",void 0),Mvt([Kft("Month")],t.prototype,"start",void 0),Mvt([Kft("Month")],t.prototype,"depth",void 0),Mvt([Kft(!1)],t.prototype,"weekNumber",void 0),Mvt([Kft("FirstDay")],t.prototype,"weekRule",void 0),Mvt([Kft(!0)],t.prototype,"showTodayButton",void 0),Mvt([Kft("Short")],t.prototype,"dayHeaderFormat",void 0),Mvt([Kft(!1)],t.prototype,"enablePersistence",void 0),Mvt([Kft(null)],t.prototype,"keyConfigs",void 0),Mvt([Kft(null)],t.prototype,"serverTimezoneOffset",void 0),Mvt([Jft()],t.prototype,"created",void 0),Mvt([Jft()],t.prototype,"destroyed",void 0),Mvt([Jft()],t.prototype,"navigated",void 0),Mvt([Jft()],t.prototype,"renderDayCell",void 0),t=Mvt([$ft],t)}(Smt);!function(e){function t(t,n){return e.call(this,t,n)||this}kvt(t,e),t.prototype.render=function(){if("Islamic"===this.calendarMode&&void 0===this.islamicModule&&Spt("Requires the injectable Islamic modules to render Calendar in Islamic mode"),this.isMultiSelection&&"object"==typeof this.values&&!xpt(this.values)&&this.values.length>0){for(var t=[],n=[],a=0;a<this.values.length;a++)-1===t.indexOf(+this.values[a])&&(t.push(+this.values[a]),n.push(this.values[a]));this.setProperties({values:n},!0);for(var r=0;r<this.values.length;r++)if(!this.checkDateValue(this.values[r]))if("string"==typeof this.values[r]&&this.checkDateValue(new Date(this.checkValue(this.values[r])))){var i=new Date(this.checkValue(this.values[r]));this.values.splice(r,1),this.values.splice(r,0,i)}else this.values.splice(r,1);this.setProperties({value:this.values[this.values.length-1]},!0),this.previousValues=this.values.length}if(this.validateDate(),this.minMaxUpdate(),"calendar"===this.getModuleName()&&(this.setEnable(this.enabled),this.setClass(this.cssClass)),e.prototype.render.call(this),"calendar"===this.getModuleName()){var o=Oft(this.element,"form");o&&wft.add(o,"reset",this.formResetHandler.bind(this)),this.setTimeZone(this.serverTimezoneOffset)}this.renderComplete()},t.prototype.setEnable=function(e){e?Eft([this.element],Ovt):xft([this.element],Ovt)},t.prototype.setClass=function(e,t){xpt(t)||(t=t.replace(/\s+/g," ").trim()),xpt(e)||(e=e.replace(/\s+/g," ").trim()),xpt(t)||""===t||Eft([this.element],t.split(" ")),xpt(e)||xft([this.element],e.split(" "))},t.prototype.isDayLightSaving=function(){var e=new Date(this.value.getFullYear(),6,1).getTimezoneOffset(),t=new Date(this.value.getFullYear(),0,1).getTimezoneOffset();return this.value.getTimezoneOffset()<Math.max(t,e)},t.prototype.setTimeZone=function(e){if(!xpt(this.serverTimezoneOffset)&&this.value){var t=e+(new Date).getTimezoneOffset()/60;t=this.isDayLightSaving()?t--:t,this.value=new Date(this.value.getTime()+60*t*60*1e3)}},t.prototype.formResetHandler=function(){this.setProperties({value:null},!0)},t.prototype.validateDate=function(){"string"==typeof this.value&&this.setProperties({value:this.checkDateValue(new Date(this.checkValue(this.value)))},!0),e.prototype.validateDate.call(this,this.value),!xpt(this.value)&&this.min<=this.max&&this.value>=this.min&&this.value<=this.max&&(this.currentDate=new Date(this.checkValue(this.value))),isNaN(+this.value)&&this.setProperties({value:null},!0)},t.prototype.minMaxUpdate=function(){"calendar"===this.getModuleName()&&(!xpt(this.value)&&this.value<=this.min&&this.min<=this.max?(this.setProperties({value:this.min},!0),this.changedArgs={value:this.value}):!xpt(this.value)&&this.value>=this.max&&this.min<=this.max&&(this.setProperties({value:this.max},!0),this.changedArgs={value:this.value})),"calendar"===this.getModuleName()||xpt(this.value)?e.prototype.minMaxUpdate.call(this,this.value):!xpt(this.value)&&this.value<this.min&&this.min<=this.max?e.prototype.minMaxUpdate.call(this,this.min):!xpt(this.value)&&this.value>this.max&&this.min<=this.max&&e.prototype.minMaxUpdate.call(this,this.max)},t.prototype.generateTodayVal=function(t){var n=new Date;return xpt(this.timezone)||(n=e.prototype.getDate.call(this,n,this.timezone)),t&&xpt(this.timezone)?(n.setHours(t.getHours()),n.setMinutes(t.getMinutes()),n.setSeconds(t.getSeconds()),n.setMilliseconds(t.getMilliseconds())):n=new Date(n.getFullYear(),n.getMonth(),n.getDate(),0,0,0,0),n},t.prototype.todayButtonClick=function(t){if(this.showTodayButton){var n=this.generateTodayVal(this.value);if(this.setProperties({value:n},!0),this.isTodayClicked=!0,this.todayButtonEvent=t,this.isMultiSelection){var a=this.copyValues(this.values);e.prototype.checkPresentDate.call(this,n,this.values)||(a.push(n),this.setProperties({values:a}))}e.prototype.todayButtonClick.call(this,t,new Date(+this.value))}},t.prototype.keyActionHandle=function(t){e.prototype.keyActionHandle.call(this,t,this.value,this.isMultiSelection)},t.prototype.preRender=function(){var t=this;this.changeHandler=function(e){t.triggerChange(e)},this.checkView(),e.prototype.preRender.call(this,this.value)},t.prototype.createContent=function(){this.previousDate=this.value,this.previousDateTime=this.value,e.prototype.createContent.call(this)},t.prototype.minMaxDate=function(t){return e.prototype.minMaxDate.call(this,t)},t.prototype.renderMonths=function(t,n,a){e.prototype.renderMonths.call(this,t,this.value,a)},t.prototype.renderDays=function(t,n,a,r,i){var o=e.prototype.renderDays.call(this,t,this.value,this.isMultiSelection,this.values,i);return this.isMultiSelection&&e.prototype.validateValues.call(this,this.isMultiSelection,this.values),o},t.prototype.renderYears=function(t){"Gregorian"===this.calendarMode?e.prototype.renderYears.call(this,t,this.value):this.islamicModule.islamicRenderYears(t,this.value)},t.prototype.renderDecades=function(t){"Gregorian"===this.calendarMode?e.prototype.renderDecades.call(this,t,this.value):this.islamicModule.islamicRenderDecade(t,this.value)},t.prototype.renderTemplate=function(t,n,a,r){"Gregorian"===this.calendarMode?e.prototype.renderTemplate.call(this,t,n,a,r,this.value):this.islamicModule.islamicRenderTemplate(t,n,a,r,this.value),this.changedArgs={value:this.value,values:this.values},this.changeHandler()},t.prototype.clickHandler=function(t){var n=t.currentTarget;if(this.isPopupClicked=!0,n.classList.contains(Svt))if(this.isMultiSelection){var a=this.copyValues(this.values);a.push(this.getIdValue(t,null)),this.setProperties({values:a},!0),this.setProperties({value:this.values[this.values.length-1]},!0)}else this.setProperties({value:this.getIdValue(t,null)},!0);var r=this.currentView();e.prototype.clickHandler.call(this,t,this.value),this.isMultiSelection&&this.currentDate!==this.value&&!xpt(this.tableBodyElement.querySelectorAll("."+Pvt)[0])&&"Year"===r&&this.tableBodyElement.querySelectorAll("."+Pvt)[0].classList.remove(Pvt)},t.prototype.switchView=function(t,n,a,r){e.prototype.switchView.call(this,t,n,this.isMultiSelection,r)},t.prototype.getModuleName=function(){return e.prototype.getModuleName.call(this),"calendar"},t.prototype.getPersistData=function(){e.prototype.getPersistData.call(this);return this.addOnPersist(["value","values"])},t.prototype.onPropertyChanged=function(t,n){this.effect="",this.rangeValidation(this.min,this.max);for(var a=0,r=Object.keys(t);a<r.length;a++){switch(r[a]){case"value":this.isDateSelected&&("string"==typeof t.value?this.setProperties({value:new Date(this.checkValue(t.value))},!0):t.value=new Date(this.checkValue(t.value)),isNaN(+this.value)&&this.setProperties({value:n.value},!0),this.update());break;case"values":if(this.isDateSelected){if("string"==typeof t.values||"number"==typeof t.values)this.setProperties({values:null},!0);else{for(var i=this.copyValues(this.values),o=0;o<i.length;o++){var l=i[o];this.checkDateValue(l)&&!e.prototype.checkPresentDate.call(this,l,i)&&i.push(l)}this.setProperties({values:i},!0),this.values.length>0&&this.setProperties({value:t.values[t.values.length-1]},!0)}this.validateValues(this.isMultiSelection,this.values),this.update()}break;case"isMultiSelection":this.isDateSelected&&(this.setProperties({isMultiSelection:t.isMultiSelection},!0),this.update());break;case"enabled":this.setEnable(this.enabled);break;case"cssClass":"calendar"===this.getModuleName()&&this.setClass(t.cssClass,n.cssClass);break;default:e.prototype.onPropertyChanged.call(this,t,n,this.isMultiSelection,this.values)}}this.preventChange=this.isAngular&&this.preventChange?!this.preventChange:this.preventChange},t.prototype.destroy=function(){if(e.prototype.destroy.call(this),"calendar"===this.getModuleName()){var t=Oft(this.element,"form");t&&wft.remove(t,"reset",this.formResetHandler.bind(this))}},t.prototype.navigateTo=function(t,n,a){this.minMaxUpdate(),e.prototype.navigateTo.call(this,t,n,a)},t.prototype.currentView=function(){return e.prototype.currentView.call(this)},t.prototype.addDate=function(t){if("string"!=typeof t&&"number"!=typeof t){var n=this.copyValues(this.values);if("object"==typeof t&&t.length>0)for(var a=t,r=0;r<a.length;r++)this.checkDateValue(a[r])&&!e.prototype.checkPresentDate.call(this,a[r],n)&&(!xpt(n)&&n.length>0?n.push(a[r]):n=[new Date(+a[r])]);else this.checkDateValue(t)&&!e.prototype.checkPresentDate.call(this,t,n)&&(!xpt(n)&&n.length>0?n.push(t):n=[new Date(+t)]);this.setProperties({values:n},!0),this.isMultiSelection&&this.setProperties({value:this.values[this.values.length-1]},!0),this.validateValues(this.isMultiSelection,n),this.update(),this.changedArgs={value:this.value,values:this.values},this.changeHandler()}},t.prototype.removeDate=function(e){if("string"!=typeof e&&"number"!=typeof e&&!xpt(this.values)&&this.values.length>0){var t=this.copyValues(this.values);if("object"==typeof e&&e.length>0)for(var n=e,a=0;a<n.length;a++)for(var r=0;r<t.length;r++)+t[r]===+n[a]&&t.splice(r,1);else for(r=0;r<t.length;r++)+t[r]===+e&&t.splice(r,1);this.setProperties({values:t},!1),this.update(),this.isMultiSelection&&this.setProperties({value:this.values[this.values.length-1]},!0),this.changedArgs={value:this.value,values:this.values},this.changeHandler()}},t.prototype.setTodayDate=function(t){var n=new Date(+t);this.setProperties({value:n},!0),e.prototype.todayButtonClick.call(this,null,n,!0)},t.prototype.update=function(){this.validateDate(),this.minMaxUpdate(),e.prototype.setValueUpdate.call(this)},t.prototype.selectDate=function(t,n,a){e.prototype.selectDate.call(this,t,n,a,this.isMultiSelection,this.values),this.isMultiSelection&&!xpt(this.values)&&this.values.length>0&&this.setProperties({value:this.values[this.values.length-1]},!0),this.changedArgs={value:this.value,values:this.values},this.changeHandler(t)},t.prototype.changeEvent=function(e){((this.value&&this.value.valueOf())!==(this.previousDate&&+this.previousDate.valueOf())||this.isMultiSelection)&&(this.isAngular&&this.preventChange?this.preventChange=!1:this.trigger("change",this.changedArgs),this.previousDate=new Date(+this.value))},t.prototype.triggerChange=function(e){!xpt(this.todayButtonEvent)&&this.isTodayClicked&&(e=this.todayButtonEvent,this.isTodayClicked=!1),this.changedArgs.event=e||null,this.changedArgs.isInteracted=!xpt(e),xpt(this.value)||this.setProperties({value:this.value},!0),this.isMultiSelection||+this.value===Number.NaN||+this.value===+this.previousDate&&(null!=this.previousDate||isNaN(+this.value))?xpt(this.values)||this.previousValues===this.values.length||(this.changeEvent(e),this.previousValues=this.values.length):this.changeEvent(e)},Mvt([Kft(null)],t.prototype,"value",void 0),Mvt([Kft(null)],t.prototype,"values",void 0),Mvt([Kft(!1)],t.prototype,"isMultiSelection",void 0),Mvt([Jft()],t.prototype,"change",void 0),t=Mvt([$ft],t)}(qvt);var Uvt,Gvt,Kvt=!1;function Qvt(e,t,n,a,r){if(mvt=void 0,mvt=r,Kvt=!!a,!e)return{left:0,top:0};t||(t="left"),n||(n="top"),gvt=e.ownerDocument,vvt=e;return function(e,t,n){switch(fvt=vvt.getBoundingClientRect(),t+e){case"topcenter":Xvt(ogt(),n),Jvt(agt(),n);break;case"topright":Xvt(igt(),n),Jvt(agt(),n);break;case"centercenter":Xvt(ogt(),n),Jvt(ngt(),n);break;case"centerright":Xvt(igt(),n),Jvt(ngt(),n);break;case"centerleft":Xvt(rgt(),n),Jvt(ngt(),n);break;case"bottomcenter":Xvt(ogt(),n),Jvt(tgt(),n);break;case"bottomright":Xvt(igt(),n),Jvt(tgt(),n);break;case"bottomleft":Xvt(rgt(),n),Jvt(tgt(),n);break;default:Xvt(rgt(),n),Jvt(agt(),n)}return n}(t.toLowerCase(),n.toLowerCase(),{left:0,top:0})}function Xvt(e,t){t.left=e}function Jvt(e,t){t.top=e}function $vt(){return gvt.documentElement.scrollTop||gvt.body.scrollTop}function egt(){return gvt.documentElement.scrollLeft||gvt.body.scrollLeft}function tgt(){return Kvt?fvt.bottom:fvt.bottom+$vt()}function ngt(){return agt()+fvt.height/2}function agt(){return Kvt?fvt.top:fvt.top+$vt()}function rgt(){return fvt.left+egt()}function igt(){var e=vvt&&vvt.classList.contains("e-date-range-wrapper")?mvt?mvt.width:0:mvt&&fvt.width>=mvt.width?mvt.width:0;return fvt.right+egt()-e}function ogt(){return rgt()+fvt.width/2}function lgt(e,t,n,a,r,i,o,l,s){if(void 0===o&&(o=null),void 0===l&&(l={X:!0,Y:!0}),t&&e&&r&&i&&(l.X||l.Y)){var c,d={TL:null,TR:null,BL:null,BR:null},h={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(e).display){var u=e.style.visibility;e.style.visibility="hidden",e.style.display="block",c=e.getBoundingClientRect(),e.style.removeProperty("display"),e.style.visibility=u}else c=e.getBoundingClientRect();var p={posX:r,posY:i,offsetX:n,offsetY:a,position:{left:0,top:0}};Gvt=o,Uvt=t.ownerDocument,function(e,t,n,a,r){n.position=Qvt(e,n.posX,n.posY,a,r),t.TL=Qvt(e,"left","top",a,r),t.TR=Qvt(e,"right","top",a,r),t.BR=Qvt(e,"left","bottom",a,r),t.BL=Qvt(e,"right","bottom",a,r)}(t,d,p,s,c),sgt(h,p,c),l.X&&dgt(t,h,d,p,c,!0),l.Y&&d.TL.top>-1&&hgt(t,h,d,p,c,!0),function(e,t,n){var a=0,r=0;if(null!=e.offsetParent&&("absolute"===getComputedStyle(e.offsetParent).position||"relative"===getComputedStyle(e.offsetParent).position)){var i=Qvt(e.offsetParent,"left","top",!1,n);a=i.left,r=i.top}e.style.top=t.position.top+t.offsetY-r+"px",e.style.left=t.position.left+t.offsetX-a+"px"}(e,p,c)}}function sgt(e,t,n){e.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},e.TR={top:e.TL.top,left:e.TL.left+n.width},e.BL={top:e.TL.top+n.height,left:e.TL.left},e.BR={top:e.TL.top+n.height,left:e.TL.left+n.width}}function cgt(e,t){var n=!1,a=!1;return e-Egt()<wgt()&&(n=!0),t>ygt()&&(a=!0),{leftSide:n,rightSide:a}}function dgt(e,t,n,a,r,i){var o=cgt(t.TL.left,t.TR.left);n.TL.left-Egt()<=wgt()&&(o.leftSide=!1),n.TR.left>ygt()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&("right"===a.posX?a.posX="left":a.posX="right",a.offsetX=a.offsetX+r.width,a.offsetX=-1*a.offsetX,a.position=Qvt(e,a.posX,a.posY,!1),sgt(t,a,r),i&&dgt(e,t,n,a,r,!1))}function hgt(e,t,n,a,r,i){var o=ugt(t.TL.top,t.BL.top);n.TL.top-xgt()<=ggt()&&(o.topSide=!1),n.BL.top>=bgt()&&e.getBoundingClientRect().bottom<window.innerHeight&&(o.bottomSide=!1),(o.topSide&&!o.bottomSide||!o.topSide&&o.bottomSide)&&("top"===a.posY?a.posY="bottom":a.posY="top",a.offsetY=a.offsetY+r.height,a.offsetY=-1*a.offsetY,a.position=Qvt(e,a.posX,a.posY,!1,r),sgt(t,a,r),i&&hgt(e,t,n,a,r,!1))}function ugt(e,t){var n=!1,a=!1;return e-xgt()<ggt()&&(n=!0),t>bgt()&&(a=!0),{topSide:n,bottomSide:a}}function pgt(){return Gvt.getBoundingClientRect().width}function fgt(){return Gvt.getBoundingClientRect().height}function mgt(){return Gvt.getBoundingClientRect().left}function vgt(){return Gvt.getBoundingClientRect().top}function ggt(){return Gvt?vgt():0}function wgt(){return Gvt?mgt():0}function ygt(){return Gvt?Egt()+mgt()+pgt():Egt()+Mgt()}function bgt(){return Gvt?xgt()+vgt()+fgt():xgt()+kgt()}function xgt(){return Uvt.documentElement.scrollTop||Uvt.body.scrollTop}function Egt(){return Uvt.documentElement.scrollLeft||Uvt.body.scrollLeft}function kgt(){return window.innerHeight}function Mgt(){var e=window.innerWidth,t=document.documentElement.getBoundingClientRect();return e-(e-(xpt(document.documentElement)?0:t.width))}var Sgt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Agt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},_gt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Sgt(t,e),Agt([Kft("left")],t.prototype,"X",void 0),Agt([Kft("top")],t.prototype,"Y",void 0),t}(fmt),Cgt="e-popup",Zgt="e-rtl",Hgt="e-popup-open",Igt="e-popup-close",Dgt=function(e){function t(t,n){return e.call(this,n,t)||this}return Sgt(t,e),t.prototype.onPropertyChanged=function(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){switch(a[n]){case"width":Lft(this.element,{width:Apt(e.width)});break;case"height":Lft(this.element,{height:Apt(e.height)});break;case"zIndex":Lft(this.element,{zIndex:e.zIndex});break;case"enableRtl":this.setEnableRtl();break;case"position":case"relateTo":this.refreshPosition();break;case"offsetX":var r=e.offsetX-t.offsetX;this.element.style.left=(parseInt(this.element.style.left,10)+r).toString()+"px";break;case"offsetY":var i=e.offsetY-t.offsetY;this.element.style.top=(parseInt(this.element.style.top,10)+i).toString()+"px";break;case"content":this.setContent();break;case"actionOnScroll":"none"!==e.actionOnScroll?this.wireScrollEvents():this.unwireScrollEvents()}}},t.prototype.getModuleName=function(){return"popup"},t.prototype.resolveCollision=function(){this.checkCollision()},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.prototype.destroy=function(){this.element.classList.remove(Cgt,Zgt,Hgt,Igt),this.element.classList.contains("e-popup-open")&&this.unwireEvents(),e.prototype.destroy.call(this)},t.prototype.render=function(){this.element.classList.add(Cgt);var e={};1e3!==this.zIndex&&(e.zIndex=this.zIndex),"auto"!==this.width&&(e.width=Apt(this.width)),"auto"!==this.height&&(e.height=Apt(this.height)),Lft(this.element,e),this.fixedParent=!1,this.setEnableRtl(),this.setContent()},t.prototype.wireEvents=function(){gft.isDevice&&wft.add(window,"orientationchange",this.orientationOnChange,this),"none"!==this.actionOnScroll&&this.wireScrollEvents()},t.prototype.wireScrollEvents=function(){if(this.getRelateToElement())for(var e=0,t=this.getScrollableParent(this.getRelateToElement());e<t.length;e++){var n=t[e];wft.add(n,"scroll",this.scrollRefresh,this)}},t.prototype.unwireEvents=function(){gft.isDevice&&wft.remove(window,"orientationchange",this.orientationOnChange),"none"!==this.actionOnScroll&&this.unwireScrollEvents()},t.prototype.unwireScrollEvents=function(){if(this.getRelateToElement())for(var e=0,t=this.getScrollableParent(this.getRelateToElement());e<t.length;e++){var n=t[e];wft.remove(n,"scroll",this.scrollRefresh)}},t.prototype.getRelateToElement=function(){var e=""===this.relateTo||xpt(this.relateTo)?document.body:this.relateTo;return this.setProperties({relateTo:e},!0),"string"==typeof this.relateTo?document.querySelector(this.relateTo):this.relateTo},t.prototype.scrollRefresh=function(e){if("reposition"===this.actionOnScroll?xpt(this.element)||this.element.offsetParent===e.target||this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&null==e.target.parentElement||this.refreshPosition():"hide"===this.actionOnScroll&&this.hide(),"none"!==this.actionOnScroll&&this.getRelateToElement()){var t=this.isElementOnViewport(this.getRelateToElement(),e.target);t||this.targetInvisibleStatus?t&&(this.targetInvisibleStatus=!1):(this.trigger("targetExitViewport"),this.targetInvisibleStatus=!0)}},t.prototype.isElementOnViewport=function(e,t){for(var n=this.getScrollableParent(e),a=0;a<n.length;a++)if(!this.isElementVisible(e,n[a]))return!1;return!0},t.prototype.isElementVisible=function(e,t){var n=this.checkGetBoundingClientRect(e);if(!n.height||!n.width)return!1;if(xpt(this.checkGetBoundingClientRect(t))){var a=window,r={top:a.scrollY,left:a.scrollX,right:a.scrollX+a.outerWidth,bottom:a.scrollY+a.outerHeight},i=Qvt(e),o={top:i.top,left:i.left,right:i.left+n.width,bottom:i.top+n.height},l={top:r.bottom-o.top,left:r.right-o.left,bottom:o.bottom-r.top,right:o.right-r.left};return l.top>0&&l.left>0&&l.right>0&&l.bottom>0}var s=t.getBoundingClientRect();return!(n.bottom<s.top||n.bottom>s.bottom||n.right>s.right||n.left<s.left)},t.prototype.preRender=function(){},t.prototype.setEnableRtl=function(){this.reposition(),this.enableRtl?this.element.classList.add(Zgt):this.element.classList.remove(Zgt)},t.prototype.setContent=function(){if(!xpt(this.content))if(this.element.innerHTML="","string"==typeof this.content)this.element.textContent=this.content;else{var e=this.getRelateToElement(),t=this.content.props;e.classList.contains("e-dropdown-btn")&&!xpt(t)||this.element.appendChild(this.content)}},t.prototype.orientationOnChange=function(){var e=this;setTimeout(function(){e.refreshPosition()},200)},t.prototype.refreshPosition=function(e,t){xpt(e)||this.checkFixedParent(e),this.reposition(),t||this.checkCollision()},t.prototype.reposition=function(){var e,t,n=this.getRelateToElement();if("number"==typeof this.position.X&&"number"==typeof this.position.Y)e={left:this.position.X,top:this.position.Y};else if("string"==typeof this.position.X&&"number"==typeof this.position.Y||"number"==typeof this.position.X&&"string"==typeof this.position.Y){var a=void 0,r=this.element.style.display;this.element.style.display="block",this.element.classList.contains("e-dlg-modal")&&(a=this.element.parentElement.style.display,this.element.parentElement.style.display="block"),t=this.getAnchorPosition(n,this.element,this.position,this.offsetX,this.offsetY),e="string"==typeof this.position.X?{left:t.left,top:this.position.Y}:{left:this.position.X,top:t.top},this.element.style.display=r,this.element.classList.contains("e-dlg-modal")&&(this.element.parentElement.style.display=a)}else if(n){r=this.element.style.display;this.element.style.display="block",e=this.getAnchorPosition(n,this.element,this.position,this.offsetX,this.offsetY),this.element.style.display=r}else e={left:0,top:0};xpt(e)||(this.element.style.left=e.left+"px",this.element.style.top=e.top+"px")},t.prototype.checkGetBoundingClientRect=function(e){try{return e.getBoundingClientRect()}catch(e){return null}},t.prototype.getAnchorPosition=function(e,t,n,a,r){var i=this.checkGetBoundingClientRect(t),o=this.checkGetBoundingClientRect(e);if(xpt(i)||xpt(o))return null;var l=e,s={left:0,top:0};switch(t.offsetParent&&"BODY"===t.offsetParent.tagName&&"BODY"===e.tagName?s=Qvt(e):(t.classList.contains("e-dlg-modal")&&"BODY"!==l.tagName&&(t=t.parentElement),s=function(e,t){var n=!1,a={left:0,top:0},r=e;if(!e||!t)return a;for(xpt(t.offsetParent)&&"fixed"===t.style.position&&(n=!0);(t.offsetParent||n)&&e&&t.offsetParent!==e;)a.left+=e.offsetLeft,a.top+=e.offsetTop,e=e.offsetParent;for(e=r;(t.offsetParent||n)&&e&&t.offsetParent!==e;)a.left-=e.scrollLeft,a.top-=e.scrollTop,e=e.parentElement;return a}(l,t)),n.X){default:case"left":break;case"center":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.left+=window.innerWidth/2-i.width/2:"container"===this.targetType?s.left+=o.width/2-i.width/2:s.left+=o.width/2;break;case"right":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.left+=window.innerWidth-i.width:"container"===this.targetType?s.left+=o.width-i.width:s.left+=o.width}switch(n.Y){default:case"top":break;case"center":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.top+=window.innerHeight/2-i.height/2:"container"===this.targetType?s.top+=o.height/2-i.height/2:s.top+=o.height/2;break;case"bottom":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.top+=window.innerHeight-i.height:"container"===this.targetType?s.top+=o.height-i.height:s.top+=o.height}return s.left+=a,s.top+=r,s},t.prototype.callFlip=function(e){var t=this.getRelateToElement();lgt(this.element,t,this.offsetX,this.offsetY,this.position.X,this.position.Y,this.viewPortElement,e,this.fixedParent)},t.prototype.callFit=function(e){if(0!==function(e,t,n,a){void 0===t&&(t=null);var r=Qvt(e,"left","top");n&&(r.left=n),a&&(r.top=a);var i=[];Gvt=t,Uvt=e.ownerDocument;var o=e.getBoundingClientRect(),l=r.top,s=r.left,c=r.left+o.width,d=ugt(l,r.top+o.height),h=cgt(s,c);return d.topSide&&i.push("top"),h.rightSide&&i.push("right"),h.leftSide&&i.push("left"),d.bottomSide&&i.push("bottom"),i}(this.element,this.viewPortElement).length)if(xpt(this.viewPortElement)){var t=function(e,t,n,a){if(void 0===t&&(t=null),void 0===n&&(n={X:!1,Y:!1}),!n.Y&&!n.X)return{left:0,top:0};var r=e.getBoundingClientRect();if(Gvt=t,Uvt=e.ownerDocument,a||(a=Qvt(e,"left","top")),n.X){var i=Gvt?pgt():Mgt(),o=wgt(),l=ygt(),s=o-a.left,c=a.left+r.width-l;r.width>i?a.left=s>0&&c<=0?l-r.width:c>0&&s<=0?o:s>c?l-r.width:o:s>0?a.left+=s:c>0&&(a.left-=c)}if(n.Y){var d=Gvt?fgt():kgt(),h=ggt(),u=bgt(),p=h-a.top,f=a.top+r.height-u;r.height>d?a.top=p>0&&f<=0?u-r.height:f>0&&p<=0?h:p>f?u-r.height:h:p>0?a.top+=p:f>0&&(a.top-=f)}return a}(this.element,this.viewPortElement,e);e.X&&(this.element.style.left=t.left+"px"),e.Y&&(this.element.style.top=t.top+"px")}else{var n=this.checkGetBoundingClientRect(this.element),a=this.checkGetBoundingClientRect(this.viewPortElement);if(xpt(n)||xpt(a))return null;e&&!0===e.Y&&(a.top>n.top?this.element.style.top="0px":a.bottom<n.bottom&&(this.element.style.top=parseInt(this.element.style.top,10)-(n.bottom-a.bottom)+"px")),e&&!0===e.X&&(a.right<n.right?this.element.style.left=parseInt(this.element.style.left,10)-(n.right-a.right)+"px":a.left>n.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(a.left-n.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,t=this.collision.Y;"none"===e&&"none"===t||("flip"===e&&"flip"===t?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===t?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===t&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===t&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,t){var n=this;if(this.wireEvents(),1e3===this.zIndex||!xpt(t)){var a=xpt(t)?this.element:t;this.zIndex=function(e){var t=e.parentElement,n=[];for(;t&&"BODY"!==t.tagName;){var a=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==a&&"static"!==r&&n.push(a),t=t.parentElement}for(var i=[],o=0;o<document.body.children.length;o++)if(!e.isEqualNode(document.body.children[o])){a=document.defaultView.getComputedStyle(document.body.children[o],null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(document.body.children[o],null).getPropertyValue("position");"auto"!==a&&"static"!==r&&i.push(a)}i.push("999");var l=[];if(!xpt(e.parentElement)&&"BODY"!==e.parentElement.tagName){var s=[].slice.call(e.parentElement.children);for(o=0;o<s.length;o++)if(!e.isEqualNode(s[o])){a=document.defaultView.getComputedStyle(s[o],null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(s[o],null).getPropertyValue("position");"auto"!==a&&"static"!==r&&l.push(a)}}var c=n.concat(i,l),d=Math.max.apply(Math,c)+1;return d>2147483647?2147483647:d}(a),Lft(this.element,{zIndex:this.zIndex})}e=xpt(e)||"object"!=typeof e?this.showAnimation:e,"none"===this.collision.X&&"none"===this.collision.Y||(Eft([this.element],Igt),xft([this.element],Hgt),this.checkCollision(),Eft([this.element],Hgt),xft([this.element],Igt)),xpt(e)?(Eft([this.element],Igt),xft([this.element],Hgt),this.trigger("open")):(e.begin=function(){n.isDestroyed||(Eft([n.element],Igt),xft([n.element],Hgt))},e.end=function(){n.isDestroyed||n.trigger("open")},new imt(e).animate(this.element))},t.prototype.hide=function(e){var t=this;e=xpt(e)||"object"!=typeof e?this.hideAnimation:e,xpt(e)?(Eft([this.element],Hgt),xft([this.element],Igt),this.trigger("close")):(e.end=function(){t.isDestroyed||(Eft([t.element],Hgt),xft([t.element],Igt),t.trigger("close"))},new imt(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function(e,t){var n=getComputedStyle(e),a=[],r=/(auto|scroll)/,i=e.parentElement;for(;i&&"HTML"!==i.tagName;){var o=getComputedStyle(i);"absolute"===n.position&&"static"===o.position||!r.test(o.overflow+o.overflowY+o.overflowX)||a.push(i),i=i.parentElement}t||a.push(document);return a}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var t=e.parentElement;t&&"HTML"!==t.tagName;){var n=getComputedStyle(t);"fixed"===n.position&&!xpt(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top)?Apt(window.scrollY-parseInt(this.element.style.top)):Apt(parseInt(this.element.style.top)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),t=t.parentElement,!xpt(this.element)&&xpt(this.element.offsetParent)&&"fixed"===n.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},Agt([Kft("auto")],t.prototype,"height",void 0),Agt([Kft("auto")],t.prototype,"width",void 0),Agt([Kft(null)],t.prototype,"content",void 0),Agt([Kft("container")],t.prototype,"targetType",void 0),Agt([Kft(null)],t.prototype,"viewPortElement",void 0),Agt([Kft({X:"none",Y:"none"})],t.prototype,"collision",void 0),Agt([Kft("")],t.prototype,"relateTo",void 0),Agt([Qft({},_gt)],t.prototype,"position",void 0),Agt([Kft(0)],t.prototype,"offsetX",void 0),Agt([Kft(0)],t.prototype,"offsetY",void 0),Agt([Kft(1e3)],t.prototype,"zIndex",void 0),Agt([Kft(!1)],t.prototype,"enableRtl",void 0),Agt([Kft("reposition")],t.prototype,"actionOnScroll",void 0),Agt([Kft(null)],t.prototype,"showAnimation",void 0),Agt([Kft(null)],t.prototype,"hideAnimation",void 0),Agt([Jft()],t.prototype,"open",void 0),Agt([Jft()],t.prototype,"close",void 0),Agt([Jft()],t.prototype,"targetExitViewport",void 0),t=Agt([$ft],t)}(Smt);function Ngt(e){for(var t,n=e.childNodes,a=0;a<n.length;a++)if(3===(t=n[a]).nodeType)return t;return null}var Ogt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Lgt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o};new Xpt;var Vgt,zgt="e-rtl",Pgt="e-btn",Tgt="e-primary",Bgt="e-icon-btn",jgt=function(e){function t(t,n){return e.call(this,t,n)||this}return Ogt(t,e),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=omt(this.element,{selector:"."+Pgt}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&xft([this.element],this.cssClass.split(" ")),this.isPrimary&&this.element.classList.add(Tgt),this.content){var e=this.enableHtmlSanitizer?Evt.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss(),this.enableRtl&&this.element.classList.add(zgt),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),"Top"!==this.iconPosition&&"Bottom"!==this.iconPosition||this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add(Bgt);var t=this.element.childNodes[0];!t||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,t)}},t.prototype.wireEvents=function(){this.isToggle&&wft.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&wft.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var t=[Tgt,zgt,Bgt,"e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(t=t.concat(this.cssClass.split(" "))),e.prototype.destroy.call(this),Eft([this.element],t),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var n=this.element.querySelector("span.e-btn-icon");n&&Cft(n),this.unWireEvents()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,t){for(var n=this.element.querySelector("span.e-btn-icon"),a=0,r=Object.keys(e);a<r.length;a++){switch(r[a]){case"isPrimary":e.isPrimary?this.element.classList.add(Tgt):this.element.classList.remove(Tgt);break;case"disabled":this.controlStatus(e.disabled);break;case"iconCss":n?e.iconCss?(n.className="e-btn-icon "+e.iconCss,this.element.textContent.trim()&&("Left"===this.iconPosition?n.classList.add("e-icon-left"):n.classList.add("e-icon-right"))):Cft(n):this.setIconCss();break;case"iconPosition":Eft([this.element],["e-top-icon-btn","e-bottom-icon-btn"]),(n=this.element.querySelector("span.e-btn-icon"))&&Cft(n),this.setIconCss();break;case"cssClass":t.cssClass&&Eft([this.element],t.cssClass.split(" ")),e.cssClass&&xft([this.element],e.cssClass.split(" "));break;case"enableRtl":e.enableRtl?this.element.classList.add(zgt):this.element.classList.remove(zgt);break;case"content":Ngt(this.element)||this.element.classList.remove(Bgt),this.enableHtmlSanitizer&&(e.content=Evt.sanitize(e.content)),this.element.innerHTML=e.content,this.setIconCss();break;case"isToggle":e.isToggle?wft.add(this.element,"click",this.btnClickHandler,this):(wft.remove(this.element,"click",this.btnClickHandler),Eft([this.element],["e-active"]))}}},t.prototype.click=function(){this.element.click()},t.prototype.focusIn=function(){this.element.focus()},Lgt([Kft("Left")],t.prototype,"iconPosition",void 0),Lgt([Kft("")],t.prototype,"iconCss",void 0),Lgt([Kft(!1)],t.prototype,"disabled",void 0),Lgt([Kft(!1)],t.prototype,"isPrimary",void 0),Lgt([Kft("")],t.prototype,"cssClass",void 0),Lgt([Kft("")],t.prototype,"content",void 0),Lgt([Kft(!1)],t.prototype,"isToggle",void 0),Lgt([Kft()],t.prototype,"locale",void 0),Lgt([Kft(!1)],t.prototype,"enableHtmlSanitizer",void 0),Lgt([Jft()],t.prototype,"created",void 0),t=Lgt([$ft],t)}(Smt),Wgt="e-rtl",Rgt="e-disabled",Fgt="e-input",Ygt="e-multi-line-input",qgt="e-input-group",Ugt="e-float-input",Ggt="e-float-line",Kgt="e-float-text",Qgt="e-float-text-content",Xgt="e-clear-icon",Jgt="e-clear-icon-hide",$gt="e-label-top",ewt="e-label-bottom",twt="e-no-float-label",nwt="e-input-custom-tag",awt="e-float-custom-tag";!function(e){var t,n=!0;function a(e){r(e.floatLabelType,e.element),e.element.addEventListener("focus",function(){var e=u(this);(e.classList.contains("e-input-group")||e.classList.contains("e-outline")||e.classList.contains("e-filled"))&&e.classList.add("e-input-focus")}),e.element.addEventListener("blur",function(){var e=u(this);(e.classList.contains("e-input-group")||e.classList.contains("e-outline")||e.classList.contains("e-filled"))&&e.classList.remove("e-input-focus")}),e.element.addEventListener("input",function(){r(t,e.element)})}function r(e,t){var n=t.value;""!==n&&!xpt(n)&&t.parentElement?t.parentElement.classList.add("e-valid-input"):"Always"!==e&&t.parentElement&&t.parentElement.classList.remove("e-valid-input")}function i(){var e=u(this).getElementsByClassName("e-float-text")[0];xpt(e)||(xft([e],$gt),e.classList.contains(ewt)&&Eft([e],ewt))}function o(){var e=u(this);if(e.getElementsByTagName("textarea")[0]?""===e.getElementsByTagName("textarea")[0].value:""===e.getElementsByTagName("input")[0].value){var t=e.getElementsByClassName("e-float-text")[0];xpt(t)||(t.classList.contains($gt)&&Eft([t],$gt),xft([t],ewt))}}function l(e){e.addEventListener("focus",i),e.addEventListener("blur",o)}function s(e,t,n){var a=xpt(n)?bft:n;"Auto"===e.floatLabelType&&l(e.element),xpt(t.container)?(t.container=m(e,Ugt,awt,"div",a),e.element.parentNode&&e.element.parentNode.insertBefore(t.container,e.element)):(xpt(e.customTag)||t.container.classList.add(awt),t.container.classList.add(Ugt));var r=a("span",{className:Ggt}),i=a("label",{className:Kgt});if(xpt(e.element.id)||""===e.element.id||(i.id="label_"+e.element.id.replace(/ /g,"_"),Hft(e.element,{"aria-labelledby":i.id})),xpt(e.element.placeholder)||""===e.element.placeholder||(i.innerText=v(e.element.placeholder),e.element.removeAttribute("placeholder")),xpt(e.properties)||xpt(e.properties.placeholder)||""===e.properties.placeholder||(i.innerText=v(e.properties.placeholder)),i.innerText||t.container.classList.add(twt),t.container.classList.contains("e-float-icon-left")){var o=t.container.querySelector(".e-input-in-wrap");o.appendChild(e.element),o.appendChild(r),o.appendChild(i)}else t.container.appendChild(e.element),t.container.appendChild(r),t.container.appendChild(i);h(e.element.value,i),"Always"===e.floatLabelType&&(i.classList.contains(ewt)&&Eft([i],ewt),xft([i],$gt)),"Auto"===e.floatLabelType&&(e.element.addEventListener("input",function(t){h(e.element.value,i,e.element)}),e.element.addEventListener("blur",function(t){h(e.element.value,i)})),xpt(e.element.getAttribute("id"))||i.setAttribute("for",e.element.getAttribute("id"))}function c(e,t){"Always"===e&&t.classList.contains("e-outline")&&t.classList.add("e-valid-input")}function d(e,t,n){e&&!n?Eft([t],Jgt):xft([t],Jgt)}function h(e,t,n){(void 0===n&&(n=null),e)?(xft([t],$gt),t.classList.contains(ewt)&&Eft([t],ewt)):(null==n||n!==document.activeElement)&&(t.classList.contains($gt)&&Eft([t],$gt),xft([t],ewt))}function u(e){var t=xpt(e.parentNode)?e:e.parentNode;return t&&t.classList.contains("e-input-in-wrap")&&(t=t.parentNode),t}function p(e,t,a){(null==n||n)&&t.addEventListener("click",function(n){e.classList.contains(Rgt)||e.readOnly||(n.preventDefault(),e!==document.activeElement&&e.focus(),e.value="",xft([t],Jgt))}),e.addEventListener("input",function(n){d(e.value,t)}),e.addEventListener("focus",function(n){d(e.value,t,e.readOnly)}),e.addEventListener("blur",function(e){setTimeout(function(){xft([t],Jgt)},200)})}function f(e,t){if(u(e).classList.contains(Ugt)&&"Auto"===t){var n=u(e).getElementsByClassName("e-float-text")[0];h(e.value,n,e)}}function m(e,t,n,a,r){var i,o=xpt(r)?bft:r;return xpt(e.customTag)?i=o(a,{className:t}):(i=o(e.customTag,{className:t})).classList.add(n),i.classList.add("e-control-wrapper"),i}function v(e){var t="";if(!xpt(e)&&""!==e){var n=document.createElement("span");n.innerHTML='<input placeholder="'+e+'"/>',t=n.children[0].placeholder}return t}function g(e,t,n){xpt(n)||""===n||Eft(t,n.split(" ")),xpt(e)||""===e||xft(t,e.split(" "))}function w(e,t){xpt(t.getElementsByClassName("e-float-text-content")[0])||(t.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&t.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(e.clientWidth<t.getElementsByClassName("e-float-text-content")[0].clientWidth||e.clientWidth===t.getElementsByClassName("e-float-text-content")[0].clientWidth)&&t.getElementsByClassName("e-float-text-content")[0].classList.add("e-float-text-overflow"))}function y(e,t){e=v(e);var n=u(t);n.classList.contains(Ugt)?xpt(e)||""===e?(n.classList.add(twt),n.getElementsByClassName("e-float-text-content")[0]?n.getElementsByClassName(Kgt)[0].children[0].textContent="":n.getElementsByClassName(Kgt)[0].textContent=""):(n.getElementsByClassName("e-float-text-content")[0]?n.getElementsByClassName(Kgt)[0].children[0].textContent=e:n.getElementsByClassName(Kgt)[0].textContent=e,n.classList.remove(twt),t.removeAttribute("placeholder")):xpt(e)||""===e?(t.removeAttribute("placeholder"),t.removeAttribute("aria-placeholder")):Hft(t,{placeholder:e,"aria-placeholder":e})}function b(e,t,n){e?Hft(t,{readonly:""}):t.removeAttribute("readonly"),xpt(n)||f(t,n)}function x(e,t){e?xft(t,Wgt):Eft(t,Wgt)}function E(e,t,n,a){var r={disabled:"disabled","aria-disabled":"true"},i=!xpt(a);e?(t.classList.remove(Rgt),M(r,t),i&&Eft([a],Rgt)):(t.classList.add(Rgt),S(r,t),i&&xft([a],Rgt)),xpt(n)||f(t,n)}function k(e,t,n,a,r){var i=xpt(r)?bft:r;e?n.clearButton=function(e,t,n,a){var r=(xpt(a)?bft:a)("span",{className:Xgt}),i=t.container;return xpt(n)?(t.container.classList.contains(Ugt)?t.container.querySelector("."+Kgt):e).insertAdjacentElement("afterend",r):i.appendChild(r),!xpt(i)&&i.classList.contains(Ugt)&&xft([i],qgt),xft([r],Jgt),p(e,r),r.setAttribute("aria-label","close"),r}(t,n,a,i):(Zft(n.clearButton),n.clearButton=null)}function M(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){var r=a[n],i=u(t);"disabled"===r&&t.classList.remove(Rgt),"disabled"===r&&i.classList.contains(qgt)&&i.classList.remove(Rgt),"placeholder"===r&&i.classList.contains(Ugt)?i.getElementsByClassName(Kgt)[0].textContent="":t.removeAttribute(r)}}function S(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){var r=a[n],i=u(t);"disabled"===r&&t.classList.add(Rgt),"disabled"===r&&i.classList.contains(qgt)&&i.classList.add(Rgt),"placeholder"===r&&i.classList.contains(Ugt)?i.getElementsByClassName(Kgt)[0].textContent=e[r]:t.setAttribute(r,e[r])}}function A(e,t){if(e.container.classList.contains("e-outline")&&e.container.getElementsByClassName("e-float-text")[0]){var n=t("span",{className:Qgt});n.innerHTML=e.container.getElementsByClassName("e-float-text")[0].innerHTML,e.container.getElementsByClassName("e-float-text")[0].innerHTML="",e.container.getElementsByClassName("e-float-text")[0].appendChild(n)}}function _(e,t,n){var a=[];a.push(n);var r=xpt(n)?t.querySelectorAll(".e-input-group-icon"):a;if(e&&r.length>0)for(var i=0;i<r.length;i++)r[i].addEventListener("mousedown",C,!1),r[i].addEventListener("mouseup",Z,!1);else if(r.length>0)for(i=0;i<r.length;i++)r[i].removeEventListener("mousedown",C,this),r[i].removeEventListener("mouseup",Z,this)}function C(){for(var e=this.parentElement;!e.classList.contains("e-input-group");)e=e.parentElement;!function(e,t){e.classList.contains("e-disabled")||e.querySelector("input").readOnly||t.classList.add("e-input-btn-ripple")}(e,this)}function Z(){var e=this;setTimeout(function(){e.classList.remove("e-input-btn-ripple")},500)}function H(e,t){var n=t("span",{className:e});return n.classList.add("e-input-group-icon"),n}function I(e,t,n,a){var r=xpt(a)?bft:a,i=H(e,r);t.classList.add("e-float-icon-left");var o=t.querySelector(".e-input-in-wrap");if(xpt(o)){o=r("span",{className:"e-input-in-wrap"}),n.parentNode.insertBefore(o,n);var l=t.querySelectorAll(n.tagName+" ~ *");o.appendChild(n);for(var s=0;s<l.length;s++)o.appendChild(l[s])}return o.parentNode.insertBefore(i,o),t.classList.contains(qgt)||t.classList.add(qgt),_(!0,t,i),i}function D(e,t,n){var a=H(e,xpt(n)?bft:n);return t.classList.contains(qgt)||t.classList.add(qgt),(t.classList.contains("e-float-icon-left")?t.querySelector(".e-input-in-wrap"):t).appendChild(a),_(!0,t,a),a}function N(e,t){"hidden"===t.type?e.classList.add("e-hidden"):e.classList.contains("e-hidden")&&e.classList.remove("e-hidden")}e.createInput=function(e,r){var i=xpt(r)?bft:r,o={container:null,buttons:[],clearButton:null};if(t=e.floatLabelType,n=e.bindClearAction,xpt(e.floatLabelType)||"Never"===e.floatLabelType?(o.container=m(e,qgt,nwt,"span",i),e.element.parentNode.insertBefore(o.container,e.element),xft([e.element],Fgt),o.container.appendChild(e.element)):s(e,o,i),a(e),xpt(e.properties)||xpt(e.properties.showClearButton)||!e.properties.showClearButton||"TEXTAREA"===e.element.tagName||(k(e.properties.showClearButton,e.element,o,!0,i),o.clearButton.setAttribute("role","button"),o.container.classList.contains(Ugt)&&xft([o.container],qgt)),!xpt(e.buttons)&&"TEXTAREA"!==e.element.tagName)for(var l=0;l<e.buttons.length;l++)o.buttons.push(D(e.buttons[l],o.container,i));return xpt(e.element)||"TEXTAREA"!==e.element.tagName||xft([o.container],Ygt),N(o.container,e.element),o=function(e,t){if(!xpt(e.properties))for(var n=0,a=Object.keys(e.properties);n<a.length;n++){switch(a[n]){case"cssClass":g(e.properties.cssClass,[t.container]),c(e.floatLabelType,t.container);break;case"enabled":E(e.properties.enabled,e.element,e.floatLabelType,t.container);break;case"enableRtl":x(e.properties.enableRtl,[t.container]);break;case"placeholder":y(e.properties.placeholder,e.element);break;case"readonly":b(e.properties.readonly,e.element)}}return t}(e,o),A(o,i),o},e.bindInitialEvent=a,e.wireFloatingEvents=l,e.wireClearBtnEvents=p,e.setValue=function(e,t,n,a){if(t.value=e,xpt(t.getAttribute("value"))&&w(t,t.parentElement),xpt(n)||"Auto"!==n||f(t,n),!xpt(a)&&a){var i=u(t);if(!xpt(i)){var o=i.getElementsByClassName(Xgt)[0];xpt(o)||(t.value&&i.classList.contains("e-input-focus")?Eft([o],Jgt):xft([o],Jgt))}}r(n,t)},e.setCssClass=g,e.calculateWidth=w,e.setWidth=function(e,t){"number"==typeof e?t.style.width=Apt(e):"string"==typeof e&&(t.style.width=e.match(/px|%|em/)?e:Apt(e)),w(t.firstChild,t)},e.setPlaceholder=y,e.setReadonly=b,e.setEnableRtl=x,e.setEnabled=E,e.setClearButton=k,e.removeAttributes=M,e.addAttributes=S,e.removeFloating=function(e){var t=e.container;if(!xpt(t)&&t.classList.contains(Ugt)){var n=t.querySelector("textarea")?t.querySelector("textarea"):t.querySelector("input"),a=t.querySelector("."+Kgt).textContent,r=null!==t.querySelector(".e-clear-icon");Cft(t.querySelector("."+Ggt)),Cft(t.querySelector("."+Kgt)),function(e,t,n){xft([e],t),Eft([e],n)}(t,[qgt],[Ugt]),function(e){e.removeEventListener("focus",i),e.removeEventListener("blur",o)}(n),Hft(n,{placeholder:a}),n.classList.add(Fgt),r||"INPUT"!==n.tagName||n.removeAttribute("required")}},e.addFloating=function(e,n,a,r){var i=xpt(r)?bft:r,o=Oft(e,"."+qgt);if(t=n,"Never"!==n){var l=o.tagName,d={element:e,floatLabelType:n,customTag:l="DIV"!==l&&"SPAN"!==l?l:null,properties:{placeholder:a}},h=o.querySelector(".e-clear-icon"),u={container:o};e.classList.remove(Fgt),s(d,u,i),A(u,i),w(d.element,u.container);var p=o.classList.contains("e-float-icon-left");if(xpt(h))if(p)h=o.querySelector(".e-input-in-wrap").querySelector(".e-input-group-icon");else h=o.querySelector(".e-input-group-icon");if(xpt(h))p&&(h=o.querySelector(".e-input-group-icon")),xpt(h)&&o.classList.remove(qgt);else{var f=o.querySelector("."+Ggt),m=o.querySelector("."+Kgt),v=p?o.querySelector(".e-input-in-wrap"):o;v.insertBefore(e,h),v.insertBefore(f,h),v.insertBefore(m,h)}}c(n,e.parentElement)},e.createSpanElement=A,e.setRipple=function(e,t){for(var n=0;n<t.length;n++)_(e,t[n].container)},e.addIcon=function(e,t,n,a,r){var i="string"==typeof t?t.split(","):t;if("append"===e.toLowerCase())for(var o=0,l=i;o<l.length;o++){D(l[o],n,r)}else for(var s=0,c=i;s<c.length;s++){I(c[s],n,a,r)}n.getElementsByClassName("e-input-group-icon")[0]&&n.getElementsByClassName("e-float-text-overflow")[0]&&n.getElementsByClassName("e-float-text-overflow")[0].classList.add("e-icon")},e.prependSpan=I,e.appendSpan=D,e.validateInputType=N}(Vgt||(Vgt={}));var rwt=function(){function e(e){return this.subQuery=null,this.isChild=!1,this.distincts=[],this.queries=[],this.key="",this.fKey="","string"==typeof e?this.fromTable=e:e&&e instanceof Array&&(this.lookups=e),this.expands=[],this.sortedColumns=[],this.groupedColumns=[],this.subQuery=null,this.isChild=!1,this.params=[],this.lazyLoad=[],this}return e.prototype.setKey=function(e){return this.key=e,this},e.prototype.using=function(e){return this.dataManager=e,this},e.prototype.execute=function(e,t,n,a){return(e=e||this.dataManager)?e.executeQuery(this,t,n,a):lwt.throwError('Query - execute() : dataManager needs to be is set using "using" function or should be passed as argument')},e.prototype.executeLocal=function(e){return(e=e||this.dataManager)?e.executeLocal(this):lwt.throwError('Query - executeLocal() : dataManager needs to be is set using "using" function or should be passed as argument')},e.prototype.clone=function(){var t=new e;return t.queries=this.queries.slice(0),t.key=this.key,t.isChild=this.isChild,t.dataManager=this.dataManager,t.fromTable=this.fromTable,t.params=this.params.slice(0),t.expands=this.expands.slice(0),t.sortedColumns=this.sortedColumns.slice(0),t.groupedColumns=this.groupedColumns.slice(0),t.subQuerySelector=this.subQuerySelector,t.subQuery=this.subQuery,t.fKey=this.fKey,t.isCountRequired=this.isCountRequired,t.distincts=this.distincts.slice(0),t.lazyLoad=this.lazyLoad.slice(0),t},e.prototype.from=function(e){return this.fromTable=e,this},e.prototype.addParams=function(e,t){return"function"==typeof t?this.params.push({key:e,fn:t}):this.params.push({key:e,value:t}),this},e.prototype.distinct=function(e){return this.distincts="string"==typeof e?[].slice.call([e],0):e.slice(0),this},e.prototype.expand=function(e){return this.expands="string"==typeof e?[].slice.call([e],0):e.slice(0),this},e.prototype.where=function(e,t,n,a,r){t=t?t.toLowerCase():null;var i=null;return"string"==typeof e?i=new iwt(e,t,n,a,r):e instanceof iwt&&(i=e),this.queries.push({fn:"onWhere",e:i}),this},e.prototype.search=function(e,t,n,a,r){"string"==typeof t&&(t=[t]),n&&"none"!==n||(n="contains");var i=lwt.fnOperators[n];return this.queries.push({fn:"onSearch",e:{fieldNames:t,operator:n,searchKey:e,ignoreCase:a,ignoreAccent:r,comparer:i}}),this},e.prototype.sortBy=function(e,t,n){return this.sortByForeignKey(e,t,n)},e.prototype.sortByForeignKey=function(t,n,a,r){var i,o,l=xpt(r)?"ascending":r;if("string"==typeof t&&lwt.endsWith(t.toLowerCase()," desc")&&(t=t.replace(/ desc$/i,""),n="descending"),n&&"string"!=typeof n||(l=n?n.toLowerCase():"ascending",n=lwt.fnSort(n)),a){i=e.filterQueries(this.queries,"onSortBy");for(var s=0;s<i.length;s++)if("string"==typeof(o=i[s].e.fieldName)){if(o===t)return this}else if(o instanceof Array)for(var c=0;c<o.length;c++)if(o[c]===t||t.toLowerCase()===o[c]+" desc")return this}return this.queries.push({fn:"onSortBy",e:{fieldName:t,comparer:n,direction:l}}),this},e.prototype.sortByDesc=function(e){return this.sortBy(e,"descending")},e.prototype.group=function(e,t,n){return this.sortBy(e,null,!0),this.queries.push({fn:"onGroup",e:{fieldName:e,comparer:t||null,format:n||null}}),this},e.prototype.page=function(e,t){return this.queries.push({fn:"onPage",e:{pageIndex:e,pageSize:t}}),this},e.prototype.range=function(e,t){return this.queries.push({fn:"onRange",e:{start:e,end:t}}),this},e.prototype.take=function(e){return this.queries.push({fn:"onTake",e:{nos:e}}),this},e.prototype.skip=function(e){return this.queries.push({fn:"onSkip",e:{nos:e}}),this},e.prototype.select=function(e){return"string"==typeof e&&(e=[].slice.call([e],0)),this.queries.push({fn:"onSelect",e:{fieldNames:e}}),this},e.prototype.hierarchy=function(e,t){return this.subQuerySelector=t,this.subQuery=e,this},e.prototype.foreignKey=function(e){return this.fKey=e,this},e.prototype.requiresCount=function(){return this.isCountRequired=!0,this},e.prototype.aggregate=function(e,t){return this.queries.push({fn:"onAggregates",e:{field:t,type:e}}),this},e.filterQueries=function(e,t){return e.filter(function(e){return e.fn===t})},e.filterQueryLists=function(e,t){for(var n=e.filter(function(e){return-1!==t.indexOf(e.fn)}),a={},r=0;r<n.length;r++)a[n[r].fn]||(a[n[r].fn]=n[r].e);return a},e}(),iwt=function(){function e(t,n,a,r,i){return void 0===r&&(r=!1),this.ignoreAccent=!1,this.isComplex=!1,"string"==typeof t?(this.field=t,this.operator=n.toLowerCase(),this.value=a,this.ignoreCase=r,this.ignoreAccent=i,this.isComplex=!1,this.comparer=lwt.fnOperators.processOperator(this.operator)):(t instanceof e&&a instanceof e||a instanceof Array)&&(this.isComplex=!0,this.condition=n.toLowerCase(),this.predicates=[t],a instanceof Array?[].push.apply(this.predicates,a):this.predicates.push(a)),this}return e.and=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return e.combinePredicates([].slice.call(t,0),"and")},e.prototype.and=function(t,n,a,r,i){return e.combine(this,t,n,a,"and",r,i)},e.or=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return e.combinePredicates([].slice.call(t,0),"or")},e.prototype.or=function(t,n,a,r,i){return e.combine(this,t,n,a,"or",r,i)},e.fromJson=function(e){if(e instanceof Array){for(var t=[],n=0,a=e.length;n<a;n++)t.push(this.fromJSONData(e[n]));return t}var r=e;return this.fromJSONData(r)},e.prototype.validate=function(e){var t,n,a=this.predicates?this.predicates:[];if(!this.isComplex&&this.comparer)return this.comparer.call(this,lwt.getObject(this.field,e),this.value,this.ignoreCase,this.ignoreAccent);t="and"===this.condition;for(var r=0;r<a.length;r++)if(n=a[r].validate(e),t){if(!n)return!1}else if(n)return!0;return t},e.prototype.toJson=function(){var e,t;if(this.isComplex){e=[],t=this.predicates;for(var n=0;n<t.length;n++)e.push(t[n].toJson())}return{isComplex:this.isComplex,field:this.field,operator:this.operator,value:this.value,ignoreCase:this.ignoreCase,ignoreAccent:this.ignoreAccent,condition:this.condition,predicates:e}},e.combinePredicates=function(t,n){if(1===t.length){if(!(t[0]instanceof Array))return t[0];t=t[0]}return new e(t[0],n,t.slice(1))},e.combine=function(t,n,a,r,i,o,l){return n instanceof e?e[i](t,n):"string"==typeof n?e[i](t,new e(n,a,r,o,l)):lwt.throwError("Predicate - "+i+" : invalid arguments")},e.fromJSONData=function(t){for(var n=t.predicates||[],a=n.length,r=[],i=0;i<a;i++)r.push(this.fromJSONData(n[i]));return t.isComplex?new e(r[0],t.condition,r.slice(1)):new e(t.field,t.operator,t.value,t.ignoreCase,t.ignoreAccent)},e}(),owt={GroupGuid:"{271bbba0-1ee7}"},lwt=function(){function e(){}return e.getValue=function(e,t){return"function"==typeof e?e.call(t||{}):e},e.endsWith=function(e,t){return e.slice&&e.slice(-t.length)===t},e.startsWith=function(e,t){return e.slice(0,t.length)===t},e.fnSort=function(t){return"ascending"===(t=t?e.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},e.fnAscending=function(e,t){return xpt(e)&&xpt(t)||null==t?-1:"string"==typeof e?e.localeCompare(t):null==e?1:e-t},e.fnDescending=function(e,t){return xpt(e)&&xpt(t)?-1:null==t?1:"string"==typeof e?-1*e.localeCompare(t):null==e?-1:t-e},e.extractFields=function(e,t){for(var n={},a=0;a<t.length;a++)n=this.setValue(t[a],this.getObject(t[a],e),n);return n},e.select=function(e,t){for(var n=[],a=0;a<e.length;a++)n.push(this.extractFields(e[a],t));return n},e.group=function(t,n,a,r,i,o,l){r=r||1;var s=t,c="GroupGuid";if(s.GroupGuid===owt[c]){for(var d=function(e){if(xpt(i))s[e].items=h.group(s[e].items,n,a,s.level+1,null,o,l),s[e].count=s[e].items.length;else{var t,r=i.filter(function(t){return t.key===s[e].key});t=i.indexOf(r[0]),s[e].items=h.group(s[e].items,n,a,s.level+1,i[t].items,o,l),s[e].count=i[t].count}},h=this,u=0;u<s.length;u++)d(u);return s.childLevels+=1,s}var p={},f=[];f.GroupGuid=owt[c],f.level=r,f.childLevels=0,f.records=s;for(var m=function(e){var t=v.getVal(s,e,n);if(xpt(o)||(t=o(t,n)),!p[t]&&(p[t]={key:t,count:0,items:[],aggregates:{},field:n},f.push(p[t]),!xpt(i))){var r=i.filter(function(e){return e.key===p[t].key});p[t].count=r[0].count}p[t].count=xpt(i)?p[t].count+=1:p[t].count,(!l||l&&a.length)&&p[t].items.push(s[e])},v=this,g=0;g<s.length;g++)m(g);if(a&&a.length){var w=function(t){for(var n={},r=void 0,o=a,l=0;l<a.length;l++)if(r=e.aggregates[a[l].type],xpt(i))r&&(n[o[l].field+" - "+o[l].type]=r(f[t].items,o[l].field));else{var s=i.filter(function(e){return e.key===f[t].key});r&&(n[o[l].field+" - "+o[l].type]=r(s[0].items,o[l].field))}f[t].aggregates=n};for(g=0;g<f.length;g++)w(g)}if(l&&f.length&&a.length)for(g=0;g<f.length;g++)f[g].items=[];return s.length&&f||s},e.buildHierarchy=function(e,t,n,a,r){var i,o={};for(a.result&&(a=a.result),a.GroupGuid&&this.throwError("DataManager: Do not have support Grouping in hierarchy"),i=0;i<a.length;i++){(o[l=this.getObject(e,a[i])]||(o[l]=[])).push(a[i])}for(i=0;i<n.length;i++){var l=this.getObject(r||e,n[i]);n[i][t]=o[l]}},e.getFieldList=function(e,t,n){if(void 0===n&&(n=""),null==t)return this.getFieldList(e,[],n);for(var a=e,r=0,i=Object.keys(e);r<i.length;r++){var o=i[r];"object"!=typeof a[o]||a[o]instanceof Array?t.push(n+o):this.getFieldList(a[o],t,n+o+".")}return t},e.getObject=function(e,t){if(!e)return t;if(t){if(-1===e.indexOf("."))return t[e];for(var n=t,a=e.split("."),r=0;r<a.length&&null!=n;r++)n=n[a[r]];return n}},e.setValue=function(e,t,n){var a,r,i=e.toString().split("."),o=n||{},l=o,s=i.length;for(a=0;a<s;a++)r=i[a],a+1===s?l[r]=void 0===t?void 0:t:xpt(l[r])&&(l[r]={}),l=l[r];return o},e.sort=function(e,t,n){if(e.length<=1)return e;var a=parseInt((e.length/2).toString(),10),r=e.slice(0,a),i=e.slice(a);return r=this.sort(r,t,n),i=this.sort(i,t,n),this.merge(r,i,t,n)},e.ignoreDiacritics=function(t){return"string"!=typeof t?t:t.split("").map(function(t){return t in e.diacritics?e.diacritics[t]:t}).join("")},e.merge=function(e,t,n,a){for(var r,i=[];e.length>0||t.length>0;)r=e.length>0&&t.length>0?a?a(this.getVal(e,0,n),this.getVal(t,0,n),e[0],t[0])<=0?e:t:e[0][n]<e[0][n]?e:t:e.length>0?e:t,i.push(r.shift());return i},e.getVal=function(e,t,n){return n?this.getObject(n,e[t]):e[t]},e.toLowerCase=function(e){return e?"string"==typeof e?e.toLowerCase():e.toString():0===e||!1===e?e.toString():""},e.callAdaptorFunction=function(e,t,n,a){if(t in e){var r=e[t](n,a);xpt(r)||(n=r)}return n},e.getAddParams=function(t,n,a){var r={};return e.callAdaptorFunction(t,"addParams",{dm:n,query:a,params:a.params,reqParams:r}),r},e.isPlainObject=function(e){return!!e&&e.constructor===Object},e.isCors=function(){var e=null;try{e=new window.XMLHttpRequest}catch(e){}return!!e&&"withCredentials"in e},e.getGuid=function(e){var t;return(e||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(e,n){if("crypto"in window&&"getRandomValues"in crypto){var a=new Uint8Array(1);window.crypto.getRandomValues(a),t=a[0]%16|0}else t=16*Math.random()|0;return"0123456789abcdef"[19===n?3&t|8:t]})},e.isNull=function(e){return null==e},e.getItemFromComparer=function(t,n,a){var r,i,o,l=0,s="string"==typeof e.getVal(t,0,n);if(t.length)for(;xpt(r)&&l<t.length;)r=e.getVal(t,l,n),o=t[l++];for(;l<t.length;l++)xpt(i=e.getVal(t,l,n))||(s&&(r=+r,i=+i),a(r,i)>0&&(r=i,o=t[l]));return o},e.distinct=function(t,n,a){a=!xpt(a)&&a;var r,i=[],o={};return t.forEach(function(l,s){(r="object"==typeof t[s]?e.getVal(t,s,n):t[s])in o||(i.push(a?t[s]:r),o[r]=1)}),i},e.processData=function(e,t){var n=this.prepareQuery(e),a=new wwt(t);e.requiresCounts&&n.requiresCount();var r=a.executeLocal(n),i={result:e.requiresCounts?r.result:r,count:r.count,aggregates:JSON.stringify(r.aggregates)};return e.requiresCounts?i:r},e.prepareQuery=function(t){var n=this,a=new rwt;(t.select&&a.select(t.select),t.where)&&e.parse.parseJson(t.where).filter(function(e){if(xpt(e.condition))a.where(e.field,e.operator,e.value,e.ignoreCase,e.ignoreAccent);else{var t=[];e.field?t.push(new iwt(e.field,e.operator,e.value,e.ignoreCase,e.ignoreAccent)):t=t.concat(n.getPredicate(e.predicates)),"or"==e.condition?a.where(iwt.or(t)):"and"==e.condition&&a.where(iwt.and(t))}});t.search&&e.parse.parseJson(t.search).filter(function(e){return a.search(e.key,e.fields,e.operator,e.ignoreCase,e.ignoreAccent)});return t.aggregates&&t.aggregates.filter(function(e){return a.aggregate(e.type,e.field)}),t.sorted&&t.sorted.filter(function(e){return a.sortBy(e.name,e.direction)}),t.skip&&a.skip(t.skip),t.take&&a.take(t.take),t.group&&t.group.filter(function(e){return a.group(e)}),a},e.getPredicate=function(e){for(var t=[],n=0;n<e.length;n++){var a=e[n];if(a.field)t.push(new iwt(a.field,a.operator,a.value,a.ignoreCase,a.ignoreAccent));else{for(var r=[],i=this.getPredicate(a.predicates),o=0,l=Object.keys(i);o<l.length;o++){var s=l[o];r.push(i[s])}t.push("or"==a.condition?iwt.or(r):iwt.and(r))}}return t},e.serverTimezoneOffset=null,e.timeZoneHandling=!0,e.throwError=function(e){try{throw new Error(e)}catch(e){throw e.message+"\n"+e.stack}},e.aggregates={sum:function(t,n){for(var a,r=0,i="number"!=typeof e.getVal(t,0,n),o=0;o<t.length;o++)a=e.getVal(t,o,n),isNaN(a)||null===a||(i&&(a=+a),r+=a);return r},average:function(t,n){return e.aggregates.sum(t,n)/t.length},min:function(t,n){var a;return"function"==typeof n&&(a=n,n=null),e.getObject(n,e.getItemFromComparer(t,n,a||e.fnAscending))},max:function(t,n){var a;return"function"==typeof n&&(a=n,n=null),e.getObject(n,e.getItemFromComparer(t,n,a||e.fnDescending))},truecount:function(e,t){return new wwt(e).executeLocal((new rwt).where(t,"equal",!0,!0)).length},falsecount:function(e,t){return new wwt(e).executeLocal((new rwt).where(t,"equal",!1,!0)).length},count:function(e,t){return e.length}},e.operatorSymbols={"<":"lessthan",">":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},e.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},e.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof"},e.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains"},e.diacritics={"Ⓐ":"A","A":"A","À":"A","Á":"A","Â":"A","Ầ":"A","Ấ":"A","Ẫ":"A","Ẩ":"A","Ã":"A","Ā":"A","Ă":"A","Ằ":"A","Ắ":"A","Ẵ":"A","Ẳ":"A","Ȧ":"A","Ǡ":"A","Ä":"A","Ǟ":"A","Ả":"A","Å":"A","Ǻ":"A","Ǎ":"A","Ȁ":"A","Ȃ":"A","Ạ":"A","Ậ":"A","Ặ":"A","Ḁ":"A","Ą":"A","Ⱥ":"A","Ɐ":"A","Ꜳ":"AA","Æ":"AE","Ǽ":"AE","Ǣ":"AE","Ꜵ":"AO","Ꜷ":"AU","Ꜹ":"AV","Ꜻ":"AV","Ꜽ":"AY","Ⓑ":"B","B":"B","Ḃ":"B","Ḅ":"B","Ḇ":"B","Ƀ":"B","Ƃ":"B","Ɓ":"B","Ⓒ":"C","C":"C","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","Ç":"C","Ḉ":"C","Ƈ":"C","Ȼ":"C","Ꜿ":"C","Ⓓ":"D","D":"D","Ḋ":"D","Ď":"D","Ḍ":"D","Ḑ":"D","Ḓ":"D","Ḏ":"D","Đ":"D","Ƌ":"D","Ɗ":"D","Ɖ":"D","Ꝺ":"D","DZ":"DZ","DŽ":"DZ","Dz":"Dz","Dž":"Dz","Ⓔ":"E","E":"E","È":"E","É":"E","Ê":"E","Ề":"E","Ế":"E","Ễ":"E","Ể":"E","Ẽ":"E","Ē":"E","Ḕ":"E","Ḗ":"E","Ĕ":"E","Ė":"E","Ë":"E","Ẻ":"E","Ě":"E","Ȅ":"E","Ȇ":"E","Ẹ":"E","Ệ":"E","Ȩ":"E","Ḝ":"E","Ę":"E","Ḙ":"E","Ḛ":"E","Ɛ":"E","Ǝ":"E","Ⓕ":"F","F":"F","Ḟ":"F","Ƒ":"F","Ꝼ":"F","Ⓖ":"G","G":"G","Ǵ":"G","Ĝ":"G","Ḡ":"G","Ğ":"G","Ġ":"G","Ǧ":"G","Ģ":"G","Ǥ":"G","Ɠ":"G","Ꞡ":"G","Ᵹ":"G","Ꝿ":"G","Ⓗ":"H","H":"H","Ĥ":"H","Ḣ":"H","Ḧ":"H","Ȟ":"H","Ḥ":"H","Ḩ":"H","Ḫ":"H","Ħ":"H","Ⱨ":"H","Ⱶ":"H","Ɥ":"H","Ⓘ":"I","I":"I","Ì":"I","Í":"I","Î":"I","Ĩ":"I","Ī":"I","Ĭ":"I","İ":"I","Ï":"I","Ḯ":"I","Ỉ":"I","Ǐ":"I","Ȉ":"I","Ȋ":"I","Ị":"I","Į":"I","Ḭ":"I","Ɨ":"I","Ⓙ":"J","J":"J","Ĵ":"J","Ɉ":"J","Ⓚ":"K","K":"K","Ḱ":"K","Ǩ":"K","Ḳ":"K","Ķ":"K","Ḵ":"K","Ƙ":"K","Ⱪ":"K","Ꝁ":"K","Ꝃ":"K","Ꝅ":"K","Ꞣ":"K","Ⓛ":"L","L":"L","Ŀ":"L","Ĺ":"L","Ľ":"L","Ḷ":"L","Ḹ":"L","Ļ":"L","Ḽ":"L","Ḻ":"L","Ł":"L","Ƚ":"L","Ɫ":"L","Ⱡ":"L","Ꝉ":"L","Ꝇ":"L","Ꞁ":"L","LJ":"LJ","Lj":"Lj","Ⓜ":"M","M":"M","Ḿ":"M","Ṁ":"M","Ṃ":"M","Ɱ":"M","Ɯ":"M","Ⓝ":"N","N":"N","Ǹ":"N","Ń":"N","Ñ":"N","Ṅ":"N","Ň":"N","Ṇ":"N","Ņ":"N","Ṋ":"N","Ṉ":"N","Ƞ":"N","Ɲ":"N","Ꞑ":"N","Ꞥ":"N","NJ":"NJ","Nj":"Nj","Ⓞ":"O","O":"O","Ò":"O","Ó":"O","Ô":"O","Ồ":"O","Ố":"O","Ỗ":"O","Ổ":"O","Õ":"O","Ṍ":"O","Ȭ":"O","Ṏ":"O","Ō":"O","Ṑ":"O","Ṓ":"O","Ŏ":"O","Ȯ":"O","Ȱ":"O","Ö":"O","Ȫ":"O","Ỏ":"O","Ő":"O","Ǒ":"O","Ȍ":"O","Ȏ":"O","Ơ":"O","Ờ":"O","Ớ":"O","Ỡ":"O","Ở":"O","Ợ":"O","Ọ":"O","Ộ":"O","Ǫ":"O","Ǭ":"O","Ø":"O","Ǿ":"O","Ɔ":"O","Ɵ":"O","Ꝋ":"O","Ꝍ":"O","Ƣ":"OI","Ꝏ":"OO","Ȣ":"OU","Ⓟ":"P","P":"P","Ṕ":"P","Ṗ":"P","Ƥ":"P","Ᵽ":"P","Ꝑ":"P","Ꝓ":"P","Ꝕ":"P","Ⓠ":"Q","Q":"Q","Ꝗ":"Q","Ꝙ":"Q","Ɋ":"Q","Ⓡ":"R","R":"R","Ŕ":"R","Ṙ":"R","Ř":"R","Ȑ":"R","Ȓ":"R","Ṛ":"R","Ṝ":"R","Ŗ":"R","Ṟ":"R","Ɍ":"R","Ɽ":"R","Ꝛ":"R","Ꞧ":"R","Ꞃ":"R","Ⓢ":"S","S":"S","ẞ":"S","Ś":"S","Ṥ":"S","Ŝ":"S","Ṡ":"S","Š":"S","Ṧ":"S","Ṣ":"S","Ṩ":"S","Ș":"S","Ş":"S","Ȿ":"S","Ꞩ":"S","Ꞅ":"S","Ⓣ":"T","T":"T","Ṫ":"T","Ť":"T","Ṭ":"T","Ț":"T","Ţ":"T","Ṱ":"T","Ṯ":"T","Ŧ":"T","Ƭ":"T","Ʈ":"T","Ⱦ":"T","Ꞇ":"T","Ꜩ":"TZ","Ⓤ":"U","U":"U","Ù":"U","Ú":"U","Û":"U","Ũ":"U","Ṹ":"U","Ū":"U","Ṻ":"U","Ŭ":"U","Ü":"U","Ǜ":"U","Ǘ":"U","Ǖ":"U","Ǚ":"U","Ủ":"U","Ů":"U","Ű":"U","Ǔ":"U","Ȕ":"U","Ȗ":"U","Ư":"U","Ừ":"U","Ứ":"U","Ữ":"U","Ử":"U","Ự":"U","Ụ":"U","Ṳ":"U","Ų":"U","Ṷ":"U","Ṵ":"U","Ʉ":"U","Ⓥ":"V","V":"V","Ṽ":"V","Ṿ":"V","Ʋ":"V","Ꝟ":"V","Ʌ":"V","Ꝡ":"VY","Ⓦ":"W","W":"W","Ẁ":"W","Ẃ":"W","Ŵ":"W","Ẇ":"W","Ẅ":"W","Ẉ":"W","Ⱳ":"W","Ⓧ":"X","X":"X","Ẋ":"X","Ẍ":"X","Ⓨ":"Y","Y":"Y","Ỳ":"Y","Ý":"Y","Ŷ":"Y","Ỹ":"Y","Ȳ":"Y","Ẏ":"Y","Ÿ":"Y","Ỷ":"Y","Ỵ":"Y","Ƴ":"Y","Ɏ":"Y","Ỿ":"Y","Ⓩ":"Z","Z":"Z","Ź":"Z","Ẑ":"Z","Ż":"Z","Ž":"Z","Ẓ":"Z","Ẕ":"Z","Ƶ":"Z","Ȥ":"Z","Ɀ":"Z","Ⱬ":"Z","Ꝣ":"Z","ⓐ":"a","a":"a","ẚ":"a","à":"a","á":"a","â":"a","ầ":"a","ấ":"a","ẫ":"a","ẩ":"a","ã":"a","ā":"a","ă":"a","ằ":"a","ắ":"a","ẵ":"a","ẳ":"a","ȧ":"a","ǡ":"a","ä":"a","ǟ":"a","ả":"a","å":"a","ǻ":"a","ǎ":"a","ȁ":"a","ȃ":"a","ạ":"a","ậ":"a","ặ":"a","ḁ":"a","ą":"a","ⱥ":"a","ɐ":"a","ꜳ":"aa","æ":"ae","ǽ":"ae","ǣ":"ae","ꜵ":"ao","ꜷ":"au","ꜹ":"av","ꜻ":"av","ꜽ":"ay","ⓑ":"b","b":"b","ḃ":"b","ḅ":"b","ḇ":"b","ƀ":"b","ƃ":"b","ɓ":"b","ⓒ":"c","c":"c","ć":"c","ĉ":"c","ċ":"c","č":"c","ç":"c","ḉ":"c","ƈ":"c","ȼ":"c","ꜿ":"c","ↄ":"c","ⓓ":"d","d":"d","ḋ":"d","ď":"d","ḍ":"d","ḑ":"d","ḓ":"d","ḏ":"d","đ":"d","ƌ":"d","ɖ":"d","ɗ":"d","ꝺ":"d","dz":"dz","dž":"dz","ⓔ":"e","e":"e","è":"e","é":"e","ê":"e","ề":"e","ế":"e","ễ":"e","ể":"e","ẽ":"e","ē":"e","ḕ":"e","ḗ":"e","ĕ":"e","ė":"e","ë":"e","ẻ":"e","ě":"e","ȅ":"e","ȇ":"e","ẹ":"e","ệ":"e","ȩ":"e","ḝ":"e","ę":"e","ḙ":"e","ḛ":"e","ɇ":"e","ɛ":"e","ǝ":"e","ⓕ":"f","f":"f","ḟ":"f","ƒ":"f","ꝼ":"f","ⓖ":"g","g":"g","ǵ":"g","ĝ":"g","ḡ":"g","ğ":"g","ġ":"g","ǧ":"g","ģ":"g","ǥ":"g","ɠ":"g","ꞡ":"g","ᵹ":"g","ꝿ":"g","ⓗ":"h","h":"h","ĥ":"h","ḣ":"h","ḧ":"h","ȟ":"h","ḥ":"h","ḩ":"h","ḫ":"h","ẖ":"h","ħ":"h","ⱨ":"h","ⱶ":"h","ɥ":"h","ƕ":"hv","ⓘ":"i","i":"i","ì":"i","í":"i","î":"i","ĩ":"i","ī":"i","ĭ":"i","ï":"i","ḯ":"i","ỉ":"i","ǐ":"i","ȉ":"i","ȋ":"i","ị":"i","į":"i","ḭ":"i","ɨ":"i","ı":"i","ⓙ":"j","j":"j","ĵ":"j","ǰ":"j","ɉ":"j","ⓚ":"k","k":"k","ḱ":"k","ǩ":"k","ḳ":"k","ķ":"k","ḵ":"k","ƙ":"k","ⱪ":"k","ꝁ":"k","ꝃ":"k","ꝅ":"k","ꞣ":"k","ⓛ":"l","l":"l","ŀ":"l","ĺ":"l","ľ":"l","ḷ":"l","ḹ":"l","ļ":"l","ḽ":"l","ḻ":"l","ſ":"l","ł":"l","ƚ":"l","ɫ":"l","ⱡ":"l","ꝉ":"l","ꞁ":"l","ꝇ":"l","lj":"lj","ⓜ":"m","m":"m","ḿ":"m","ṁ":"m","ṃ":"m","ɱ":"m","ɯ":"m","ⓝ":"n","n":"n","ǹ":"n","ń":"n","ñ":"n","ṅ":"n","ň":"n","ṇ":"n","ņ":"n","ṋ":"n","ṉ":"n","ƞ":"n","ɲ":"n","ʼn":"n","ꞑ":"n","ꞥ":"n","nj":"nj","ⓞ":"o","o":"o","ò":"o","ó":"o","ô":"o","ồ":"o","ố":"o","ỗ":"o","ổ":"o","õ":"o","ṍ":"o","ȭ":"o","ṏ":"o","ō":"o","ṑ":"o","ṓ":"o","ŏ":"o","ȯ":"o","ȱ":"o","ö":"o","ȫ":"o","ỏ":"o","ő":"o","ǒ":"o","ȍ":"o","ȏ":"o","ơ":"o","ờ":"o","ớ":"o","ỡ":"o","ở":"o","ợ":"o","ọ":"o","ộ":"o","ǫ":"o","ǭ":"o","ø":"o","ǿ":"o","ɔ":"o","ꝋ":"o","ꝍ":"o","ɵ":"o","ƣ":"oi","ȣ":"ou","ꝏ":"oo","ⓟ":"p","p":"p","ṕ":"p","ṗ":"p","ƥ":"p","ᵽ":"p","ꝑ":"p","ꝓ":"p","ꝕ":"p","ⓠ":"q","q":"q","ɋ":"q","ꝗ":"q","ꝙ":"q","ⓡ":"r","r":"r","ŕ":"r","ṙ":"r","ř":"r","ȑ":"r","ȓ":"r","ṛ":"r","ṝ":"r","ŗ":"r","ṟ":"r","ɍ":"r","ɽ":"r","ꝛ":"r","ꞧ":"r","ꞃ":"r","ⓢ":"s","s":"s","ß":"s","ś":"s","ṥ":"s","ŝ":"s","ṡ":"s","š":"s","ṧ":"s","ṣ":"s","ṩ":"s","ș":"s","ş":"s","ȿ":"s","ꞩ":"s","ꞅ":"s","ẛ":"s","ⓣ":"t","t":"t","ṫ":"t","ẗ":"t","ť":"t","ṭ":"t","ț":"t","ţ":"t","ṱ":"t","ṯ":"t","ŧ":"t","ƭ":"t","ʈ":"t","ⱦ":"t","ꞇ":"t","ꜩ":"tz","ⓤ":"u","u":"u","ù":"u","ú":"u","û":"u","ũ":"u","ṹ":"u","ū":"u","ṻ":"u","ŭ":"u","ü":"u","ǜ":"u","ǘ":"u","ǖ":"u","ǚ":"u","ủ":"u","ů":"u","ű":"u","ǔ":"u","ȕ":"u","ȗ":"u","ư":"u","ừ":"u","ứ":"u","ữ":"u","ử":"u","ự":"u","ụ":"u","ṳ":"u","ų":"u","ṷ":"u","ṵ":"u","ʉ":"u","ⓥ":"v","v":"v","ṽ":"v","ṿ":"v","ʋ":"v","ꝟ":"v","ʌ":"v","ꝡ":"vy","ⓦ":"w","w":"w","ẁ":"w","ẃ":"w","ŵ":"w","ẇ":"w","ẅ":"w","ẘ":"w","ẉ":"w","ⱳ":"w","ⓧ":"x","x":"x","ẋ":"x","ẍ":"x","ⓨ":"y","y":"y","ỳ":"y","ý":"y","ŷ":"y","ỹ":"y","ȳ":"y","ẏ":"y","ÿ":"y","ỷ":"y","ẙ":"y","ỵ":"y","ƴ":"y","ɏ":"y","ỿ":"y","ⓩ":"z","z":"z","ź":"z","ẑ":"z","ż":"z","ž":"z","ẓ":"z","ẕ":"z","ƶ":"z","ȥ":"z","ɀ":"z","ⱬ":"z","ꝣ":"z","Ά":"Α","Έ":"Ε","Ή":"Η","Ί":"Ι","Ϊ":"Ι","Ό":"Ο","Ύ":"Υ","Ϋ":"Υ","Ώ":"Ω","ά":"α","έ":"ε","ή":"η","ί":"ι","ϊ":"ι","ΐ":"ι","ό":"ο","ύ":"υ","ϋ":"υ","ΰ":"υ","ω":"ω","ς":"σ"},e.fnOperators={equal:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?e.toLowerCase(t)===e.toLowerCase(n):t===n},notequal:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),!e.fnOperators.equal(t,n,a)},lessthan:function(t,n,a){return a?e.toLowerCase(t)<e.toLowerCase(n):(xpt(t)&&(t=void 0),t<n)},greaterthan:function(t,n,a){return a?e.toLowerCase(t)>e.toLowerCase(n):t>n},lessthanorequal:function(t,n,a){return a?e.toLowerCase(t)<=e.toLowerCase(n):(xpt(t)&&(t=void 0),t<=n)},greaterthanorequal:function(t,n,a){return a?e.toLowerCase(t)>=e.toLowerCase(n):t>=n},contains:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?!xpt(t)&&!xpt(n)&&-1!==e.toLowerCase(t).indexOf(e.toLowerCase(n)):!xpt(t)&&!xpt(n)&&-1!==t.toString().indexOf(n)},notnull:function(e){return null!==e},isnull:function(e){return null===e},startswith:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?t&&n&&e.startsWith(e.toLowerCase(t),e.toLowerCase(n)):t&&n&&e.startsWith(t,n)},endswith:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?t&&n&&e.endsWith(e.toLowerCase(t),e.toLowerCase(n)):t&&n&&e.endsWith(t,n)},processSymbols:function(t){var n=e.operatorSymbols[t];return n?e.fnOperators[n]:e.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){var n=e.fnOperators[t];return n||e.fnOperators.processSymbols(t)}},e.parse={parseJson:function(t){return"string"==typeof t?t=JSON.parse(t,e.parse.jsonReviver):t instanceof Array?e.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&e.parse.iterateAndReviveJson(t),t},iterateAndReviveArray:function(t){for(var n=0;n<t.length;n++)"object"==typeof t[n]&&null!==t[n]?e.parse.iterateAndReviveJson(t[n]):"string"!=typeof t[n]||/^[\s]*\[|^[\s]*\{(.)+:|\"/g.test(t[n])?t[n]=e.parse.parseJson(t[n]):t[n]=e.parse.jsonReviver("",t[n])},iterateAndReviveJson:function(t){for(var n,a=0,r=Object.keys(t);a<r.length;a++){var i=r[a];e.startsWith(i,"__")||("object"==typeof(n=t[i])?n instanceof Array?e.parse.iterateAndReviveArray(n):n&&e.parse.iterateAndReviveJson(n):t[i]=e.parse.jsonReviver(t[i],n))}},jsonReviver:function(t,n){if("string"==typeof n){var a=/^\/Date\(([+-]?[0-9]+)([+-][0-9]{4})?\)\/$/.exec(n),r=e.timeZoneHandling?e.serverTimezoneOffset:null;if(a)return e.dateParse.toTimeZone(new Date(parseInt(a[1],10)),r,!0);if(/^(\d{4}\-\d\d\-\d\d([tT][\d:\.]*){1})([zZ]|([+\-])(\d\d):?(\d\d))?$/.test(n)){var i=n.indexOf("Z")>-1||n.indexOf("z")>-1,o=n.split(/[^0-9.]/);if(i)n=e.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5],10)),e.serverTimezoneOffset,!1);else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5],10)),s=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(s)&&isNaN(c))return l;n.indexOf("+")>-1?l.setHours(l.getHours()-s,l.getMinutes()-c):l.setHours(l.getHours()+s,l.getMinutes()+c),n=e.dateParse.toTimeZone(l,e.serverTimezoneOffset,!1)}null==e.serverTimezoneOffset&&(n=e.dateParse.addSelfOffset(n))}}return n},isJson:function(t){return"string"==typeof t[0]?t:e.parse.parseJson(t)},isGuid:function(e){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(e)},replacer:function(t,n){return e.isPlainObject(t)?e.parse.jsonReplacer(t,n):t instanceof Array?e.parse.arrayReplacer(t):t instanceof Date?e.parse.jsonReplacer({val:t},n).val:t},jsonReplacer:function(t,n){for(var a,r=0,i=Object.keys(t);r<i.length;r++){var o=i[r];if((a=t[o])instanceof Date){var l=a;null==e.serverTimezoneOffset?t[o]=e.dateParse.toTimeZone(l,null).toJSON():(l=new Date(+l+36e5*e.serverTimezoneOffset),t[o]=e.dateParse.toTimeZone(e.dateParse.addSelfOffset(l),null).toJSON())}}return t},arrayReplacer:function(t){for(var n=0;n<t.length;n++)e.isPlainObject(t[n])?t[n]=e.parse.jsonReplacer(t[n]):t[n]instanceof Date&&(t[n]=e.parse.jsonReplacer({date:t[n]}).date);return t},jsonDateReplacer:function(t,n){if("value"===t&&n){if("string"==typeof n){var a=/^\/Date\(([+-]?[0-9]+)([+-][0-9]{4})?\)\/$/.exec(n);if(a)n=e.dateParse.toTimeZone(new Date(parseInt(a[1],10)),null,!0);else if(/^(\d{4}\-\d\d\-\d\d([tT][\d:\.]*){1})([zZ]|([+\-])(\d\d):?(\d\d))?$/.test(n)){var r=n.split(/[^0-9]/);n=e.dateParse.toTimeZone(new Date(parseInt(r[0],10),parseInt(r[1],10)-1,parseInt(r[2],10),parseInt(r[3],10),parseInt(r[4],10),parseInt(r[5],10)),null,!0)}}if(n instanceof Date)return n=e.dateParse.addSelfOffset(n),null===e.serverTimezoneOffset?e.dateParse.toTimeZone(e.dateParse.addSelfOffset(n),null).toJSON():(n=e.dateParse.toTimeZone(n,n.getTimezoneOffset()/60*2-e.serverTimezoneOffset,!1)).toJSON()}return n}},e.dateParse={addSelfOffset:function(e){return new Date(+e-6e4*e.getTimezoneOffset())},toUTC:function(e){return new Date(+e+6e4*e.getTimezoneOffset())},toTimeZone:function(t,n,a){if(null===n)return t;var r=a?e.dateParse.toUTC(t):t;return new Date(+r-36e5*n)},toLocalTime:function(e){var t=e,n=-t.getTimezoneOffset(),a=n>=0?"+":"-",r=function(e){var t=Math.floor(Math.abs(e));return(t<10?"0":"")+t};return t.getFullYear()+"-"+r(t.getMonth()+1)+"-"+r(t.getDate())+"T"+r(t.getHours())+":"+r(t.getMinutes())+":"+r(t.getSeconds())+a+r(n/60)+":"+r(n%60)}},e}(),swt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),cwt={GroupGuid:"{271bbba0-1ee7}"},dwt=function(){function e(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=e,this.dataSource=t,this.pvt={}}return e.prototype.processResponse=function(e,t,n,a){return e},e}(),hwt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return swt(t,e),t.prototype.processQuery=function(e,t){for(var n,a,r,i=e.dataSource.json.slice(0),o=i.length,l=!0,s={},c=0,d=[],h=0;h<t.lazyLoad.length;h++)c++,s[t.lazyLoad[h].key]=t.lazyLoad[h].value;var u={};for(h=0;h<t.queries.length;h++)"onPage"!==(a=t.queries[h]).fn&&"onGroup"!==a.fn||!t.lazyLoad.length?(n=this[a.fn].call(this,i,a.e,t),"onAggregates"===a.fn?u[a.e.field+" - "+a.e.type]=n:i=void 0!==n?n:i,"onPage"!==a.fn&&"onSkip"!==a.fn&&"onTake"!==a.fn&&"onRange"!==a.fn||(l=!1),l&&(o=i.length)):("onGroup"===a.fn&&d.push(a.e),"onPage"===a.fn&&(r=a.e));if(c){var p={query:t,lazyLoad:s,result:i,group:d,page:r},f=this.lazyLoadGroup(p);i=f.result,o=f.count}return t.isCountRequired&&(i={result:i,count:o,aggregates:u}),i},t.prototype.lazyLoadGroup=function(e){var t=0,n=this.getAggregate(e.query),a=e.result;if(xpt(e.lazyLoad.onDemandGroupInfo)){o=e.group[0].fieldName;t=(a=lwt.group(a,o,n,null,null,e.group[0].comparer,!0)).length;l=a;e.page&&(a=this.onPage(a,e.page,e.query)),this.formGroupResult(a,l)}else{for(var r=e.lazyLoad.onDemandGroupInfo,i=r.where.length-1;i>=0;i--)a=this.onWhere(a,r.where[i]);if(e.group.length!==r.level){var o=e.group[r.level].fieldName;a=lwt.group(a,o,n,null,null,e.group[0].comparer,!0)}t=a.length;var l=a;a=(a=a.slice(r.skip)).slice(0,r.take),e.group.length!==r.level&&this.formGroupResult(a,l)}return{result:a,count:t}},t.prototype.formGroupResult=function(e,t){if(e.length&&t.length){var n="GroupGuid",a="childLevels",r="level",i="records";e[n]=t[n],e[a]=t[a],e[r]=t[r],e[i]=t[i]}return e},t.prototype.getAggregate=function(e){var t=rwt.filterQueries(e.queries,"onAggregates"),n=[];if(t.length)for(var a=void 0,r=0;r<t.length;r++)a=t[r].e,n.push({type:a.type,field:lwt.getValue(a.field,e)});return n},t.prototype.batchRequest=function(e,t,n){var a,r=t.deletedRecords.length;for(a=0;a<t.addedRecords.length;a++)this.insert(e,t.addedRecords[a]);for(a=0;a<t.changedRecords.length;a++)this.update(e,n.key,t.changedRecords[a]);for(a=0;a<r;a++)this.remove(e,n.key,t.deletedRecords[a]);return t},t.prototype.onWhere=function(e,t){return e&&e.length?e.filter(function(e){if(t)return t.validate(e)}):e},t.prototype.onAggregates=function(e,t){var n=lwt.aggregates[t.type];return e&&n&&0!==e.length?n(e,t.field):null},t.prototype.onSearch=function(e,t){return e&&e.length?(0===t.fieldNames.length&&lwt.getFieldList(e[0],t.fieldNames),e.filter(function(e){for(var n=0;n<t.fieldNames.length;n++)if(t.comparer.call(e,lwt.getObject(t.fieldNames[n],e),t.searchKey,t.ignoreCase,t.ignoreAccent))return!0;return!1})):e},t.prototype.onSortBy=function(e,t,n){if(!e||!e.length)return e;var a,r=lwt.getValue(t.fieldName,n);if(!r)return e.sort(t.comparer);if(r instanceof Array){for(var i=(r=r.slice(0)).length-1;i>=0;i--)r[i]&&(a=t.comparer,lwt.endsWith(r[i]," desc")&&(a=lwt.fnSort("descending"),r[i]=r[i].replace(" desc","")),e=lwt.sort(e,r[i],a));return e}return lwt.sort(e,r,t.comparer)},t.prototype.onGroup=function(e,t,n){if(!e||!e.length)return e;var a=this.getAggregate(n);return lwt.group(e,lwt.getValue(t.fieldName,n),a,null,null,t.comparer)},t.prototype.onPage=function(e,t,n){var a=lwt.getValue(t.pageSize,n),r=(lwt.getValue(t.pageIndex,n)-1)*a,i=r+a;return e&&e.length?e.slice(r,i):e},t.prototype.onRange=function(e,t){return e&&e.length?e.slice(lwt.getValue(t.start),lwt.getValue(t.end)):e},t.prototype.onTake=function(e,t){return e&&e.length?e.slice(0,lwt.getValue(t.nos)):e},t.prototype.onSkip=function(e,t){return e&&e.length?e.slice(lwt.getValue(t.nos)):e},t.prototype.onSelect=function(e,t){return e&&e.length?lwt.select(e,lwt.getValue(t.fieldNames)):e},t.prototype.insert=function(e,t,n,a,r){return xpt(r)?e.dataSource.json.push(t):e.dataSource.json.splice(r,0,t)},t.prototype.remove=function(e,t,n,a){var r,i=e.dataSource.json;for("object"!=typeof n||n instanceof Date||(n=lwt.getObject(t,n)),r=0;r<i.length&&lwt.getObject(t,i[r])!==n;r++);return r!==i.length?i.splice(r,1):null},t.prototype.update=function(e,t,n,a){var r,i,o=e.dataSource.json;for(xpt(t)||(i=fpt(t,n)),r=0;r<o.length&&(xpt(t)||fpt(t,o[r])!==i);r++);return r<o.length?ypt(o[r],n):null},t}(dwt),uwt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return swt(t,e),t.prototype.processQuery=function(e,t,n){var a,r,i=this.getQueryRequest(t),o=rwt.filterQueryLists(t.queries,["onSelect","onPage","onSkip","onTake","onRange"]),l=t.params,s=e.dataSource.url,c=null,d=this.options,h={sorts:[],groups:[],filters:[],searches:[],aggregates:[]};"onPage"in o?(a=o.onPage,r=((r=lwt.getValue(a.pageIndex,t))-1)*(c=lwt.getValue(a.pageSize,t))):"onRange"in o&&(r=(a=o.onRange).start,c=a.end-a.start);for(var u=0;u<i.sorts.length;u++)a=lwt.getValue(i.sorts[u].e.fieldName,t),h.sorts.push(lwt.callAdaptorFunction(this,"onEachSort",{name:a,direction:i.sorts[u].e.direction},t));n&&(a=this.getFiltersFrom(n,t))&&h.filters.push(lwt.callAdaptorFunction(this,"onEachWhere",a.toJson(),t));for(u=0;u<i.filters.length;u++){var p=lwt.callAdaptorFunction(this,"onEachWhere",i.filters[u].e.toJson(),t);this.getModuleName&&"ODataV4Adaptor"===this.getModuleName()&&!xpt(i.filters[u].e.key)&&i.filters.length>1&&(p="("+p+")"),h.filters.push(p);for(var f=0,m="object"==typeof h.filters[u]?Object.keys(h.filters[u]):[];f<m.length;f++){var v=m[f];lwt.isNull(h[v])&&delete h[v]}}for(u=0;u<i.searches.length;u++)a=i.searches[u].e,h.searches.push(lwt.callAdaptorFunction(this,"onEachSearch",{fields:a.fieldNames,operator:a.operator,key:a.searchKey,ignoreCase:a.ignoreCase},t));for(u=0;u<i.groups.length;u++)h.groups.push(lwt.getValue(i.groups[u].e.fieldName,t));for(u=0;u<i.aggregates.length;u++)a=i.aggregates[u].e,h.aggregates.push({type:a.type,field:lwt.getValue(a.field,t)});var g={};if(this.getRequestQuery(d,t,o,h,g),lwt.callAdaptorFunction(this,"addParams",{dm:e,query:t,params:l,reqParams:g}),t.lazyLoad.length)for(u=0;u<t.lazyLoad.length;u++)g[t.lazyLoad[u].key]=t.lazyLoad[u].value;for(var w=0,y=Object.keys(g);w<y.length;w++){v=y[w];(lwt.isNull(g[v])||""===g[v]||0===g[v].length)&&delete g[v]}d.skip in g&&d.take in g||null===c||(g[d.skip]=lwt.callAdaptorFunction(this,"onSkip",r,t),g[d.take]=lwt.callAdaptorFunction(this,"onTake",c,t));var b=this.pvt;return this.pvt={},"json"===this.options.requestType?{data:JSON.stringify(g,lwt.parse.jsonDateReplacer),url:s,pvtData:b,type:"POST",contentType:"application/json; charset=utf-8"}:(a=this.convertToQueryString(g,t,e),{type:"GET",url:(a=(-1!==e.dataSource.url.indexOf("?")?"&":"/")+a).length?s.replace(/\/*$/,a):s,pvtData:b})},t.prototype.getRequestQuery=function(e,t,n,a,r){var i=r;i[e.from]=t.fromTable,e.apply&&t.distincts.length&&(i[e.apply]="onDistinct"in this?lwt.callAdaptorFunction(this,"onDistinct",t.distincts):""),!t.distincts.length&&e.expand&&(i[e.expand]="onExpand"in this&&"onSelect"in n?lwt.callAdaptorFunction(this,"onExpand",{selects:lwt.getValue(n.onSelect.fieldNames,t),expands:t.expands},t):t.expands),i[e.select]="onSelect"in n&&!t.distincts.length?lwt.callAdaptorFunction(this,"onSelect",lwt.getValue(n.onSelect.fieldNames,t),t):"",i[e.count]=t.isCountRequired?lwt.callAdaptorFunction(this,"onCount",t.isCountRequired,t):"",i[e.search]=a.searches.length?lwt.callAdaptorFunction(this,"onSearch",a.searches,t):"",i[e.skip]="onSkip"in n?lwt.callAdaptorFunction(this,"onSkip",lwt.getValue(n.onSkip.nos,t),t):"",i[e.take]="onTake"in n?lwt.callAdaptorFunction(this,"onTake",lwt.getValue(n.onTake.nos,t),t):"",i[e.where]=a.filters.length||a.searches.length?lwt.callAdaptorFunction(this,"onWhere",a.filters,t):"",i[e.sortBy]=a.sorts.length?lwt.callAdaptorFunction(this,"onSortBy",a.sorts,t):"",i[e.group]=a.groups.length?lwt.callAdaptorFunction(this,"onGroup",a.groups,t):"",i[e.aggregates]=a.aggregates.length?lwt.callAdaptorFunction(this,"onAggregates",a.aggregates,t):"",i.param=[]},t.prototype.convertToQueryString=function(e,t,n){return""},t.prototype.processResponse=function(e,t,n,a,r,i){if(a&&a.getResponseHeader("Content-Type")&&-1!==a.getResponseHeader("Content-Type").indexOf("application/json")){var o=lwt.timeZoneHandling;t&&!t.timeZoneHandling&&(lwt.timeZoneHandling=!1),e=lwt.parse.parseJson(e),lwt.timeZoneHandling=o}var l=r,s=l.pvtData||{},c=e?e.groupDs:[];if(a&&a.getResponseHeader("Content-Type")&&-1!==a.getResponseHeader("Content-Type").indexOf("xml"))return n.isCountRequired?{result:[],count:0}:[];var d=JSON.parse(l.data);if(d&&"batch"===d.action&&e&&e.addedRecords)return i.addedRecords=e.addedRecords,i;e&&e.d&&(e=e.d);var h={};e&&"count"in e&&(h.count=e.count),h.result=e&&e.result?e.result:e;var u=!1;if(Array.isArray(e.result)&&e.result.length){if(xpt(e.result[0].key)||(h.result=this.formRemoteGroupedData(h.result,1,s.groups.length-1)),n&&n.lazyLoad.length&&s.groups.length)for(var p=0;p<n.lazyLoad.length;p++)if("onDemandGroupInfo"===n.lazyLoad[p].key){var f=n.lazyLoad[p].value.level;s.groups.length===f&&(u=!0)}}return u||this.getAggregateResult(s,e,h,c,n),lwt.isNull(h.count)?h.result:{result:h.result,count:h.count,aggregates:h.aggregates}},t.prototype.formRemoteGroupedData=function(e,t,n){for(var a=0;a<e.length;a++)e[a].items.length&&Object.keys(e[a].items[0]).indexOf("key")>-1&&this.formRemoteGroupedData(e[a].items,t+1,n-1);var r="GroupGuid",i="records";return e[r]=cwt[r],e.level=t,e.childLevels=n,e[i]=e[0].items.length?this.getGroupedRecords(e,!xpt(e[0].items[i])):[],e},t.prototype.getGroupedRecords=function(e,t){for(var n=[],a=0;a<e.length;a++)if(t)n=n.concat(e[a].items.records);else for(var r=0;r<e[a].items.length;r++)n.push(e[a].items[r]);return n},t.prototype.onGroup=function(e){return this.pvt.groups=e,e},t.prototype.onAggregates=function(e){this.pvt.aggregates=e},t.prototype.batchRequest=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.batchUrl||e.dataSource.crudUrl||e.dataSource.removeUrl||e.dataSource.url,contentType:"application/json; charset=utf-8",dataType:"json",data:JSON.stringify(bpt({},{changed:t.changedRecords,added:t.addedRecords,deleted:t.deletedRecords,action:"batch",table:n[undefined],key:n[undefined]},lwt.getAddParams(this,e,a)))}},t.prototype.beforeSend=function(e,t){},t.prototype.insert=function(e,t,n,a){return{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:t,table:n,action:"insert"},lwt.getAddParams(this,e,a)))}},t.prototype.remove=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{key:n,keyColumn:t,table:a,action:"remove"},lwt.getAddParams(this,e,r)))}},t.prototype.update=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:n,action:"update",keyColumn:t,key:lwt.getObject(t,n),table:a},lwt.getAddParams(this,e,r)))}},t.prototype.getFiltersFrom=function(e,t){var n,a=t.fKey,r=a,i=t.key,o=[];"object"!=typeof e[0]&&(r=null);for(var l=0;l<e.length;l++)n="object"==typeof e[0]?lwt.getObject(i||r,e[l]):e[l],o.push(new iwt(a,"equal",n));return iwt.or(o)},t.prototype.getAggregateResult=function(e,t,n,a,r){var i=t;if(t&&t.result&&(i=t.result),e&&e.aggregates&&e.aggregates.length){var o=e.aggregates,l=void 0,s=i,c={};t.aggregate&&(s=t.aggregate);for(var d=0;d<o.length;d++)(l=lwt.aggregates[o[d].type])&&(c[o[d].field+" - "+o[d].type]=l(s,o[d].field));n.aggregates=c}var h=Array.isArray(t.result)&&t.result.length&&!xpt(t.result[0].key);if(e&&e.groups&&e.groups.length&&!h){var u=e.groups;for(d=0;d<u.length;d++){xpt(a)||(a=lwt.group(a,u[d]));var p=rwt.filterQueries(r.queries,"onGroup")[d].e;i=lwt.group(i,u[d],e.aggregates,null,a,p.comparer)}n.result=i}return n},t.prototype.getQueryRequest=function(e){var t={sorts:[],groups:[],filters:[],searches:[],aggregates:[]};return t.sorts=rwt.filterQueries(e.queries,"onSortBy"),t.groups=rwt.filterQueries(e.queries,"onGroup"),t.filters=rwt.filterQueries(e.queries,"onWhere"),t.searches=rwt.filterQueries(e.queries,"onSearch"),t.aggregates=rwt.filterQueries(e.queries,"onAggregates"),t},t.prototype.addParams=function(e){var t=e.reqParams;e.params.length&&(t.params={});for(var n=0,a=e.params;n<a.length;n++){var r=a[n];if(t[r.key])throw new Error("Query() - addParams: Custom Param is conflicting other request arguments");t[r.key]=r.value,r.fn&&(t[r.key]=r.fn.call(e.query,r.key,e.query,e.dm)),t.params[r.key]=t[r.key]}},t}(dwt),pwt=function(e){function t(t){var n=e.call(this)||this;return n.options=bpt({},n.options,{requestType:"get",accept:"application/json;odata=light;q=1,application/json;odata=verbose;q=0.5",multipartAccept:"multipart/mixed",sortBy:"$orderby",select:"$select",skip:"$skip",take:"$top",count:"$inlinecount",where:"$filter",expand:"$expand",batch:"$batch",changeSet:"--changeset_",batchPre:"batch_",contentId:"Content-Id: ",batchContent:"Content-Type: multipart/mixed; boundary=",changeSetContent:"Content-Type: application/http\nContent-Transfer-Encoding: binary ",batchChangeSetContentType:"Content-Type: application/json; charset=utf-8 ",updateType:"PUT"}),bpt(n.options,t||{}),n}return swt(t,e),t.prototype.getModuleName=function(){return"ODataAdaptor"},t.prototype.onPredicate=function(e,n,a){var r,i,o="",l=e.value,s=typeof l,c=e.field?t.getField(e.field):null;if(l instanceof Date&&(l="datetime'"+lwt.parse.replacer(l)+"'"),"string"===s&&(l=l.replace(/'/g,"''"),e.ignoreCase&&(l=l.toLowerCase()),l="'"+(l=encodeURIComponent(l))+"'",a&&(c="cast("+c+", 'Edm.String')"),lwt.parse.isGuid(l)&&(i="guid"),e.ignoreCase&&(i||(c="tolower("+c+")"),l=l.toLowerCase())),r=lwt.odBiOperator[e.operator])return o+=c,o+=r,i&&(o+=i),o+l;if("substringof"===(r=xpt(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?lwt.odUniOperator[e.operator]:lwt.odv4UniOperator[e.operator])){var d=l;l=c,c=d}return o+=r+"(",o+=c+",",i&&(o+=i),o+=l+")"},t.prototype.addParams=function(t){e.prototype.addParams.call(this,t),delete t.reqParams.params},t.prototype.onComplexPredicate=function(e,t,n){for(var a=[],r=0;r<e.predicates.length;r++)a.push("("+this.onEachWhere(e.predicates[r],t,n)+")");return a.join(" "+e.condition+" ")},t.prototype.onEachWhere=function(e,t,n){return e.isComplex?this.onComplexPredicate(e,t,n):this.onPredicate(e,t,n)},t.prototype.onWhere=function(e){return this.pvt.search&&e.push(this.onEachWhere(this.pvt.search,null,!0)),e.join(" and ")},t.prototype.onEachSearch=function(e){e.fields&&0===e.fields.length&&lwt.throwError("Query() - Search : oData search requires list of field names to search");for(var t=this.pvt.search||[],n=0;n<e.fields.length;n++)t.push(new iwt(e.fields[n],e.operator,e.key,e.ignoreCase));this.pvt.search=t},t.prototype.onSearch=function(e){return this.pvt.search=iwt.or(this.pvt.search),""},t.prototype.onEachSort=function(e){var n=[];if(e.name instanceof Array)for(var a=0;a<e.name.length;a++)n.push(t.getField(e.name[a])+("descending"===e.direction?" desc":""));else n.push(t.getField(e.name)+("descending"===e.direction?" desc":""));return n.join(",")},t.prototype.onSortBy=function(e){return e.reverse().join(",")},t.prototype.onGroup=function(e){return this.pvt.groups=e,[]},t.prototype.onSelect=function(e){for(var n=0;n<e.length;n++)e[n]=t.getField(e[n]);return e.join(",")},t.prototype.onAggregates=function(e){return this.pvt.aggregates=e,""},t.prototype.onCount=function(e){return!0===e?"allpages":""},t.prototype.beforeSend=function(e,t,n){lwt.endsWith(n.url,this.options.batch)&&"post"===n.type.toLowerCase()?(t.setRequestHeader("Accept",this.options.multipartAccept),t.setRequestHeader("DataServiceVersion","2.0"),t.overrideMimeType("text/plain; charset=x-user-defined")):t.setRequestHeader("Accept",this.options.accept),t.setRequestHeader("DataServiceVersion","2.0"),t.setRequestHeader("MaxDataServiceVersion","2.0")},t.prototype.processResponse=function(e,t,n,a,r,i){var o="odata.metadata";if(r&&"GET"===r.type&&!this.rootUrl&&e[o]){var l=e[o].split("/$metadata#");this.rootUrl=l[0],this.resourceTableName=l[1]}if(!xpt(e.d)){var s=n&&n.isCountRequired?e.d.results:e.d,c="__metadata";if(!xpt(s))for(var d=0;d<s.length;d++)xpt(s[d][c])||delete s[d][c]}var h=r&&r.pvtData,u=this.processBatchResponse(e,n,a,r,i);if(u)return u;var p=a&&r.getResponseHeader("DataServiceVersion"),f=null,m=p&&parseInt(p,10)||2;if(n&&n.isCountRequired){var v="__count";(e[v]||e["odata.count"])&&(f=e[v]||e["odata.count"]),e.d&&(e=e.d),(e[v]||e["odata.count"])&&(f=e[v]||e["odata.count"])}3===m&&e.value&&(e=e.value),e.d&&(e=e.d),m<3&&e.results&&(e=e.results);var g={};return g.count=f,g.result=e,this.getAggregateResult(h,e,g,null,n),lwt.isNull(f)?g.result:{result:g.result,count:g.count,aggregates:g.aggregates}},t.prototype.convertToQueryString=function(e,t,n){var a=[],r="table",i=e[r]||"";delete e[r],n.dataSource.requiresFormat&&(e.$format="json");for(var o=0,l=Object.keys(e);o<l.length;o++){var s=l[o];a.push(s+"="+e[s])}return a=a.join("&"),n.dataSource.url&&-1!==n.dataSource.url.indexOf("?")&&!i?a:a.length?i+"?"+a:i||""},t.prototype.localTimeReplacer=function(e,t){for(var n=0,a=xpt(t)?[]:Object.keys(t);n<a.length;n++){var r=a[n];t[r]instanceof Date&&(t[r]=lwt.dateParse.toLocalTime(t[r]))}return t},t.prototype.insert=function(e,t,n){return{url:(e.dataSource.insertUrl||e.dataSource.url).replace(/\/*$/,n?"/"+n:""),data:JSON.stringify(t,this.options.localTime?this.localTimeReplacer:null)}},t.prototype.remove=function(e,t,n,a){var r;return r="string"!=typeof n||lwt.parse.isGuid(n)?"("+n+")":"('"+n+"')",{type:"DELETE",url:(e.dataSource.removeUrl||e.dataSource.url).replace(/\/*$/,a?"/"+a:"")+r}},t.prototype.update=function(e,t,n,a,r,i){var o;return"PATCH"!==this.options.updateType||xpt(i)||(n=this.compareAndRemove(n,i,t)),o="string"!=typeof n[t]||lwt.parse.isGuid(n[t])?"("+n[t]+")":"('"+n[t]+"')",{type:this.options.updateType,url:(e.dataSource.updateUrl||e.dataSource.url).replace(/\/*$/,a?"/"+a:"")+o,data:JSON.stringify(n,this.options.localTime?this.localTimeReplacer:null),accept:this.options.accept}},t.prototype.batchRequest=function(e,t,n,a,r){var i=n.guid=lwt.getGuid(this.options.batchPre),o=this.rootUrl?this.rootUrl+"/"+this.options.batch:e.dataSource.url.replace(/\/*$/,"/"+this.options.batch);n.url=this.resourceTableName?this.resourceTableName:n.url;var l={url:n.url,key:n.key,cid:1,cSet:lwt.getGuid(this.options.changeSet)},s="--"+i+"\n";return s+="Content-Type: multipart/mixed; boundary="+l.cSet.replace("--","")+"\n",this.pvt.changeSet=0,s+=this.generateInsertRequest(t.addedRecords,l,e),s+=this.generateUpdateRequest(t.changedRecords,l,e,r?r.changedRecords:[]),s+=this.generateDeleteRequest(t.deletedRecords,l,e),s+=l.cSet+"--\n",{type:"POST",url:o,dataType:"json",contentType:"multipart/mixed; charset=UTF-8;boundary="+i,data:s+="--"+i+"--"}},t.prototype.generateDeleteRequest=function(e,t,n){if(!e)return"";var a={method:"DELETE ",url:function(e,t,n){var a=lwt.getObject(n,e[t]);return"number"==typeof a||lwt.parse.isGuid(a)?"("+a+")":a instanceof Date?"("+e[t][n].toJSON()+")":"('"+a+"')"},data:function(e,t){return""}};return this.generateBodyContent(e,t,a,n)+"\n"},t.prototype.generateInsertRequest=function(e,t,n){if(!e)return"";var a={method:"POST ",url:function(e,t,n){return""},data:function(e,t){return JSON.stringify(e[t])+"\n\n"}};return this.generateBodyContent(e,t,a,n)},t.prototype.generateUpdateRequest=function(e,t,n,a){var r=this;if(!e)return"";e.forEach(function(e){return e=r.compareAndRemove(e,a.filter(function(n){return lwt.getObject(t.key,n)===lwt.getObject(t.key,e)})[0],t.key)});var i={method:this.options.updateType+" ",url:function(e,t,n){return"number"==typeof e[t][n]||lwt.parse.isGuid(e[t][n])?"("+e[t][n]+")":e[t][n]instanceof Date?"("+e[t][n].toJSON()+")":"('"+e[t][n]+"')"},data:function(e,t){return JSON.stringify(e[t])+"\n\n"}};return this.generateBodyContent(e,t,i,n)},t.getField=function(e){return e.replace(/\./g,"/")},t.prototype.generateBodyContent=function(e,t,n,a){for(var r="",i=0;i<e.length;i++)r+="\n"+t.cSet+"\n",r+=this.options.changeSetContent+"\n\n",r+=n.method,"POST "===n.method?r+=(a.dataSource.insertUrl||a.dataSource.crudUrl||t.url)+n.url(e,i,t.key)+" HTTP/1.1\n":"PUT "===n.method||"PATCH "===n.method?r+=(a.dataSource.updateUrl||a.dataSource.crudUrl||t.url)+n.url(e,i,t.key)+" HTTP/1.1\n":"DELETE "===n.method&&(r+=(a.dataSource.removeUrl||a.dataSource.crudUrl||t.url)+n.url(e,i,t.key)+" HTTP/1.1\n"),r+="Accept: "+this.options.accept+"\n",r+="Content-Id: "+this.pvt.changeSet+++"\n",r+=this.options.batchChangeSetContentType+"\n",xpt(e[i]["@odata.etag"])?r+="\n":(r+="If-Match: "+e[i]["@odata.etag"]+"\n\n",delete e[i]["@odata.etag"]),r+=n.data(e,i);return r},t.prototype.processBatchResponse=function(e,t,n,a,r){if(n&&n.getResponseHeader("Content-Type")&&-1!==n.getResponseHeader("Content-Type").indexOf("xml"))return t.isCountRequired?{result:[],count:0}:[];if(a&&this.options.batch&&lwt.endsWith(a.url,this.options.batch)&&"post"===a.type.toLowerCase()){var i=n.getResponseHeader("Content-Type"),o=void 0,l=void 0,s=e+"";if(i=i.substring(i.indexOf("=batchresponse")+1),(s=s.split(i)).length<2)return{};s=s[1];var c=/(?:\bContent-Type.+boundary=)(changesetresponse.+)/i.exec(s);c&&s.replace(c[0],"");for(var d=c?c[1]:"",h=(s=s.split(d)).length;h>-1;h--)/\bContent-ID:/i.test(s[h])&&/\bHTTP.+201/.test(s[h])&&(o=parseInt(/\bContent-ID: (\d+)/i.exec(s[h])[1],10),r.addedRecords[o]&&(l=lwt.parse.parseJson(/^\{.+\}/m.exec(s[h])[0]),bpt({},r.addedRecords[o],this.processResponse(l))));return r}return null},t.prototype.compareAndRemove=function(e,t,n){var a=this;return xpt(t)||Object.keys(e).forEach(function(r){r!==n&&"@odata.etag"!==r&&(lwt.isPlainObject(e[r])?(a.compareAndRemove(e[r],t[r]),0===Object.keys(e[r]).filter(function(e){return"@odata.etag"!==e}).length&&delete e[r]):(e[r]===t[r]||e[r]&&t[r]&&e[r].valueOf()===t[r].valueOf())&&delete e[r])}),e},t}(uwt);!function(e){function t(t){var n=e.call(this,t)||this;return n.options=bpt({},n.options,{requestType:"get",accept:"application/json, text/javascript, */*; q=0.01",multipartAccept:"multipart/mixed",sortBy:"$orderby",select:"$select",skip:"$skip",take:"$top",count:"$count",search:"$search",where:"$filter",expand:"$expand",batch:"$batch",changeSet:"--changeset_",batchPre:"batch_",contentId:"Content-Id: ",batchContent:"Content-Type: multipart/mixed; boundary=",changeSetContent:"Content-Type: application/http\nContent-Transfer-Encoding: binary ",batchChangeSetContentType:"Content-Type: application/json; charset=utf-8 ",updateType:"PATCH",localTime:!1,apply:"$apply"}),bpt(n.options,t||{}),n}swt(t,e),t.prototype.getModuleName=function(){return"ODataV4Adaptor"},t.prototype.onCount=function(e){return!0===e?"true":""},t.prototype.onPredicate=function(t,n,a){var r="",i=t.value,o=i instanceof Date;if(n instanceof rwt)for(var l=this.getQueryRequest(n),s=0;s<l.filters.length;s++)l.filters[s].e.key===t.value&&(a=!0);return r=e.prototype.onPredicate.call(this,t,n,a),o&&(r=r.replace(/datetime'(.*)'$/,"$1")),lwt.parse.isGuid(i)&&(r=r.replace("guid","").replace(/'/g,"")),r},t.prototype.onEachSearch=function(e){var t=this.pvt.searches||[];t.push(e.key),this.pvt.searches=t},t.prototype.onSearch=function(e){return this.pvt.searches.join(" OR ")},t.prototype.onExpand=function(e){var t=this,n={},a={},r=e.expands.slice(),i=[];return e.selects.filter(function(e){return e.indexOf(".")>-1}).forEach(function(e){var a=e.split(".");if(a[0]in n||(n[a[0]]=[]),2==a.length)n[a[0]].length&&-1!==Object.keys(n).indexOf(a[0])?-1!==n[a[0]][0].indexOf("$expand")&&-1===n[a[0]][0].indexOf(";$select=")?n[a[0]][0]=n[a[0]][0]+";$select="+a[1]:n[a[0]][0]=n[a[0]][0]+","+a[1]:n[a[0]].push("$select="+a[1]);else{for(var r="$select="+a[a.length-1],i="",o="",l=1;l<a.length-1;l++)i=i+"$expand="+a[l]+"(",o+=")";var s=i+r+o;if(n[a[0]].length&&-1!==Object.keys(n).indexOf(a[0])&&t.expandQueryIndex(n[a[0]],!0)){var c=t.expandQueryIndex(n[a[0]]);n[a[0]][c]=n[a[0]][c]+s.replace("$expand=",",")}else n[a[0]].push(s)}}),Object.keys(n).forEach(function(e){-1===r.indexOf(e)&&r.push(e)}),r.forEach(function(e){a[e]=e in n?e+"("+n[e].join(";")+")":e}),Object.keys(a).forEach(function(e){return i.push(a[e])}),i.join(",")},t.prototype.expandQueryIndex=function(e,t){for(var n=0;n<e.length;n++)if(-1!==e[n].indexOf("$expand"))return!!t||n;return!t&&0},t.prototype.onDistinct=function(e){return"groupby(("+e.map(function(e){return pwt.getField(e)}).join(",")+"))"},t.prototype.onSelect=function(t){return e.prototype.onSelect.call(this,t.filter(function(e){return-1===e.indexOf(".")}))},t.prototype.beforeSend=function(e,t,n){"POST"!==n.type&&"PUT"!==n.type&&"PATCH"!==n.type||t.setRequestHeader("Prefer","return=representation"),t.setRequestHeader("Accept",this.options.accept)},t.prototype.processResponse=function(t,n,a,r,i,o){var l="@odata.context";if(i&&"GET"===i.type&&!this.rootUrl&&t[l]){var s=t[l].split("/$metadata#");this.rootUrl=s[0],this.resourceTableName=s[1]}var c=i&&i.pvtData,d=e.prototype.processBatchResponse.call(this,t,a,r,i,o);if(d)return d;var h=null,u="@odata.count";a&&a.isCountRequired&&u in t&&(h=t[u]),t=xpt(t.value)?t:t.value;var p={};return p.count=h,p.result=t,this.getAggregateResult(c,t,p,null,a),lwt.isNull(h)?p.result:{result:p.result,count:h,aggregates:p.aggregates}}}(pwt),function(e){function t(){return null!==e&&e.apply(this,arguments)||this}swt(t,e),t.prototype.getModuleName=function(){return"WebApiAdaptor"},t.prototype.insert=function(e,t,n){return{type:"POST",url:e.dataSource.url,data:JSON.stringify(t)}},t.prototype.remove=function(e,t,n,a){return{type:"DELETE",url:e.dataSource.url+"/"+n,data:JSON.stringify(n)}},t.prototype.update=function(e,t,n,a){return{type:"PUT",url:e.dataSource.url,data:JSON.stringify(n)}},t.prototype.batchRequest=function(e,t,n){var a=this,r=n.guid=lwt.getGuid(this.options.batchPre),i=e.dataSource.url.replace(/\/*$/,"/"+this.options.batch);n.url=this.resourceTableName?this.resourceTableName:n.url;for(var o=[],l=function(a,i){t.addedRecords.forEach(function(i,l){var s=function(e,t,n){return""};o.push("--"+r),o.push("Content-Type: application/http; msgtype=request",""),o.push("POST /api/"+(e.dataSource.insertUrl||e.dataSource.crudUrl||n.url)+s(t.addedRecords,a,n.key)+" HTTP/1.1"),o.push("Content-Type: application/json; charset=utf-8"),o.push("Host: "+location.host),o.push("",i?JSON.stringify(i):"")})},s=0,c=t.addedRecords.length;s<c;s++)l(s);var d=function(i,l){t.changedRecords.forEach(function(l,s){a.options.updateType;var c=function(e,t,n){return""};o.push("--"+r),o.push("Content-Type: application/http; msgtype=request",""),o.push("PUT /api/"+(e.dataSource.updateUrl||e.dataSource.crudUrl||n.url)+c(t.changedRecords,i,n.key)+" HTTP/1.1"),o.push("Content-Type: application/json; charset=utf-8"),o.push("Host: "+location.host),o.push("",l?JSON.stringify(l):"")})};for(s=0,c=t.changedRecords.length;s<c;s++)d(s);var h=function(a,i){t.deletedRecords.forEach(function(i,l){var s=function(e,t,n){var a=lwt.getObject(n,e[t]);return"number"==typeof a||lwt.parse.isGuid(a)?"/"+a:a instanceof Date?"/"+e[t][n].toJSON():"/'"+a+"'"};o.push("--"+r),o.push("Content-Type: application/http; msgtype=request",""),o.push("DELETE /api/"+(e.dataSource.removeUrl||e.dataSource.crudUrl||n.url)+s(t.deletedRecords,a,n.key)+" HTTP/1.1"),o.push("Content-Type: application/json; charset=utf-8"),o.push("Host: "+location.host),o.push("",i?JSON.stringify(i):"")})};for(s=0,c=t.deletedRecords.length;s<c;s++)h(s);return o.push("--"+r+"--",""),{type:"POST",url:i,contentType:"multipart/mixed; boundary="+r,data:o.join("\r\n")}},t.prototype.beforeSend=function(e,t,n){t.setRequestHeader("Accept","application/json, text/javascript, */*; q=0.01")},t.prototype.processResponse=function(e,t,n,a,r,i){var o=r&&r.pvtData,l=null,s={};if(r&&"post"!==r.type.toLowerCase()){var c=a&&r.getResponseHeader("DataServiceVersion"),d=c&&parseInt(c,10)||2;n&&n.isCountRequired&&(lwt.isNull(e.Count)||(l=e.Count)),d<3&&e.Items&&(e=e.Items),s.count=l,s.result=e,this.getAggregateResult(o,e,s,null,n)}return s.result=s.result||e,lwt.isNull(l)?s.result:{result:s.result,count:s.count,aggregates:s.aggregates}}}(pwt),function(e){function t(){return null!==e&&e.apply(this,arguments)||this}swt(t,e),t.prototype.processQuery=function(e,t,n){var a=(new uwt).processQuery(e,t,n),r=lwt.parse.parseJson(a.data),i={};if(r.param)for(var o=0;o<r.param.length;o++){var l=r.param[o],s=Object.keys(l)[0];i[s]=l[s]}i.value=r;return{data:JSON.stringify(i),url:a.url,pvtData:a.pvtData,type:"POST",contentType:"application/json; charset=utf-8"}}}(uwt);var fwt=function(e){function t(){var t=e.call(this)||this;return mpt("beforeSend",uwt.prototype.beforeSend,t),t}return swt(t,e),t.prototype.insert=function(e,t,n,a,r){return this.pvt.position=r,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:t,table:n,action:"insert"},lwt.getAddParams(this,e,a)))}},t.prototype.remove=function(t,n,a,r,i){return e.prototype.remove.call(this,t,n,a),{type:"POST",url:t.dataSource.removeUrl||t.dataSource.crudUrl||t.dataSource.url,data:JSON.stringify(bpt({},{key:a,keyColumn:n,table:r,action:"remove"},lwt.getAddParams(this,t,i)))}},t.prototype.update=function(e,t,n,a,r){return this.updateType="update",this.updateKey=t,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:n,action:"update",keyColumn:t,key:n[t],table:a},lwt.getAddParams(this,e,r)))}},t.prototype.processResponse=function(t,n,a,r,i,o,l){var s;if(t="batch"===(i?JSON.parse(i.data):t).action?lwt.parse.parseJson(t):t,"add"===this.updateType&&e.prototype.insert.call(this,n,t,null,null,this.pvt.position),"update"===this.updateType&&e.prototype.update.call(this,n,this.updateKey,t),this.updateType=void 0,t.added)for(s=0;s<t.added.length;s++)e.prototype.insert.call(this,n,t.added[s]);if(t.changed)for(s=0;s<t.changed.length;s++)e.prototype.update.call(this,n,l.key,t.changed[s]);if(t.deleted)for(s=0;s<t.deleted.length;s++)e.prototype.remove.call(this,n,l.key,t.deleted[s]);return t},t.prototype.batchRequest=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.batchUrl||e.dataSource.crudUrl||e.dataSource.url,contentType:"application/json; charset=utf-8",dataType:"json",data:JSON.stringify(bpt({},{changed:t.changedRecords,added:t.addedRecords,deleted:t.deletedRecords,action:"batch",table:n.url,key:n.key},lwt.getAddParams(this,e,a)))}},t.prototype.addParams=function(e){(new uwt).addParams(e)},t}(hwt),mwt=function(e){function t(t){var n=e.call(this)||this;return n.options=bpt({},n.options,{getData:new Function,addRecord:new Function,updateRecord:new Function,deleteRecord:new Function,batchUpdate:new Function}),bpt(n.options,t||{}),n}return swt(t,e),t.prototype.getModuleName=function(){return"CustomDataAdaptor"},t}(uwt);!function(e){function t(t){var n=e.call(this)||this;return n.opt=t,n.schema=n.opt.response,n.query=n.opt.query,n.getVariables=n.opt.getVariables?n.opt.getVariables:function(){},n.getQuery=function(){return n.query},n}swt(t,e),t.prototype.getModuleName=function(){return"GraphQLAdaptor"},t.prototype.processQuery=function(t,n){var a=e.prototype.processQuery.apply(this,arguments),r=JSON.parse(a.data),i={};["skip","take","sorted","table","select","where","search","requiresCounts","aggregates","params"].filter(function(e){i[e]="searchwhereparams".indexOf(e)>-1?JSON.stringify(r[e]):r[e]});var o=this.getVariables()||{};o.datamanager=i;var l=JSON.stringify({query:this.getQuery(),variables:o});return a.data=l,a},t.prototype.processResponse=function(e,t,n,a,r){var i,o,l=e,s=fpt(this.schema.result,l.data);this.schema.count&&(i=fpt(this.schema.count,l.data)),this.schema.aggregates&&(o=xpt(o=fpt(this.schema.aggregates,l.data))?o:lwt.parse.parseJson(o));var c=r.pvtData||{},d={result:s,aggregates:o},h=d;return c&&c.groups&&c.groups.length&&this.getAggregateResult(c,h,d,null,n),xpt(i)?d.result:{result:d.result,count:i,aggregates:o}},t.prototype.insert=function(){var t=e.prototype.insert.apply(this,arguments);return this.generateCrudData(t,"insert")},t.prototype.update=function(){var t=e.prototype.update.apply(this,arguments);return this.generateCrudData(t,"update")},t.prototype.remove=function(){var t=e.prototype.remove.apply(this,arguments);return this.generateCrudData(t,"remove")},t.prototype.batchRequest=function(t,n,a,r,i){var o=e.prototype.batchRequest.apply(this,arguments),l=JSON.parse(o.data);return l.key=a.key,o.data=JSON.stringify(l),this.generateCrudData(o,"batch")},t.prototype.generateCrudData=function(e,t){var n=JSON.parse(e.data);return e.data=JSON.stringify({query:this.opt.getMutation(t),variables:n}),e}}(uwt);var vwt,gwt=function(e){function t(t,n,a){var r=e.call(this)||this;r.isCrudAction=!1,r.isInsertAction=!1,xpt(t)||(r.cacheAdaptor=t),r.pageSize=a,r.guidId=lwt.getGuid("cacheAdaptor");window.localStorage.setItem(r.guidId,JSON.stringify({keys:[],results:[]}));var i=r.guidId;return xpt(n)||setInterval(function(){var e;e=lwt.parse.parseJson(window.localStorage.getItem(i));for(var t=[],a=0;a<e.results.length;a++){var r=+new Date,o=+new Date(e.results[a].timeStamp);e.results[a].timeStamp=r-o,r-o>n&&t.push(a)}for(a=0;a<t.length;a++)e.results.splice(t[a],1),e.keys.splice(t[a],1);window.localStorage.removeItem(i),window.localStorage.setItem(i,JSON.stringify(e))},n),r}return swt(t,e),t.prototype.generateKey=function(e,t){var n=this.getQueryRequest(t),a=rwt.filterQueryLists(t.queries,["onSelect","onPage","onSkip","onTake","onRange"]),r=e,i="onPage";i in a&&(r+=a[i].pageIndex),n.sorts.forEach(function(e){r+=e.e.direction+e.e.fieldName}),n.groups.forEach(function(e){r+=e.e.fieldName}),n.searches.forEach(function(e){r+=e.e.searchKey});for(var o=0;o<n.filters.length;o++){var l=n.filters[o];if(l.e.isComplex){var s=t.clone();s.queries=[];for(var c=0;c<l.e.predicates.length;c++)s.queries.push({fn:"onWhere",e:l.e.predicates[c],filter:t.queries.filter});r+=l.e.condition+this.generateKey(e,s)}else r+=l.e.field+l.e.operator+l.e.value}return r},t.prototype.processQuery=function(e,t,n){var a,r=this.generateKey(e.dataSource.url,t),i=(a=lwt.parse.parseJson(window.localStorage.getItem(this.guidId)))?a.results[a.keys.indexOf(r)]:null;return null==i||this.isCrudAction||this.isInsertAction?(this.isCrudAction=null,this.isInsertAction=null,this.cacheAdaptor.processQuery.apply(this.cacheAdaptor,[].slice.call(arguments,0))):i},t.prototype.processResponse=function(e,t,n,a,r,i){if(this.isInsertAction||r&&this.cacheAdaptor.options.batch&&lwt.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase())return this.cacheAdaptor.processResponse(e,t,n,a,r,i);e=this.cacheAdaptor.processResponse.apply(this.cacheAdaptor,[].slice.call(arguments,0));var o=n?this.generateKey(t.dataSource.url,n):t.dataSource.url,l={},s=(l=lwt.parse.parseJson(window.localStorage.getItem(this.guidId))).keys.indexOf(o);for(-1!==s&&(l.results.splice(s,1),l.keys.splice(s,1)),l.results[l.keys.push(o)-1]={keys:o,result:e.result,timeStamp:new Date,count:e.count};l.results.length>this.pageSize;)l.results.splice(0,1),l.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(l)),e},t.prototype.beforeSend=function(e,t,n){!xpt(this.cacheAdaptor.options.batch)&&lwt.endsWith(n.url,this.cacheAdaptor.options.batch)&&"post"===n.type.toLowerCase()&&t.setRequestHeader("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||t.setRequestHeader("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,t,n,a){return this.isCrudAction=!0,this.cacheAdaptor.update(e,t,n,a)},t.prototype.insert=function(e,t,n){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,t,n)},t.prototype.remove=function(e,t,n,a){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,t,n,a)},t.prototype.batchRequest=function(e,t,n){return this.cacheAdaptor.batchRequest(e,t,n)},t}(uwt),wwt=function(){function e(e,t,n){var a,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.requests=[],e||this.dataSource||(e=[]),n=n||e.adaptor,e&&!1===e.timeZoneHandling&&(this.timeZoneHandling=e.timeZoneHandling),e instanceof Array?a={json:e,offline:!0}:"object"==typeof e?(e.json||(e.json=[]),a={url:e.url,insertUrl:e.insertUrl,removeUrl:e.removeUrl,updateUrl:e.updateUrl,crudUrl:e.crudUrl,batchUrl:e.batchUrl,json:e.json,headers:e.headers,accept:e.accept,data:e.data,timeTillExpiration:e.timeTillExpiration,cachingPageSize:e.cachingPageSize,enableCaching:e.enableCaching,requestType:e.requestType,key:e.key,crossDomain:e.crossDomain,jsonp:e.jsonp,dataType:e.dataType,offline:void 0!==e.offline?e.offline:!(e.adaptor instanceof fwt||e.adaptor instanceof mwt)&&!e.url,requiresFormat:e.requiresFormat}):lwt.throwError("DataManager: Invalid arguments"),void 0!==a.requiresFormat||lwt.isCors()||(a.requiresFormat=!!xpt(a.crossDomain)||a.crossDomain),void 0===a.dataType&&(a.dataType="json"),this.dataSource=a,this.defaultQuery=t,a.url&&a.offline&&!a.json.length?(this.isDataAvailable=!1,this.adaptor=n||new pwt,this.dataSource.offline=!1,this.ready=this.executeQuery(t||new rwt),this.ready.then(function(e){r.dataSource.offline=!0,r.isDataAvailable=!0,a.json=e.result,r.adaptor=new hwt})):this.adaptor=a.offline?new hwt:new pwt,!a.jsonp&&this.adaptor instanceof pwt&&(a.jsonp="callback"),this.adaptor=n||this.adaptor,a.enableCaching&&(this.adaptor=new gwt(this.adaptor,a.timeTillExpiration,a.cachingPageSize)),this}return e.prototype.setDefaultQuery=function(e){return this.defaultQuery=e,this},e.prototype.executeLocal=function(t){this.defaultQuery||t instanceof rwt||lwt.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||lwt.throwError("DataManager - executeLocal() : Json data is required to execute"),t=t||this.defaultQuery;var n=this.adaptor.processQuery(this,t);if(t.subQuery){var a=t.subQuery.fromTable,r=t.subQuery.lookups,i=t.isCountRequired?n.result:n;r&&r instanceof Array&&lwt.buildHierarchy(t.subQuery.fKey,a,i,r,t.subQuery.key);for(var o=0;o<i.length;o++)i[o][a]instanceof Array&&(i[o]=bpt({},{},i[o]),i[o][a]=this.adaptor.processResponse(t.subQuery.using(new e(i[o][a].slice(0))).executeLocal(),this,t))}return this.adaptor.processResponse(n,this,t)},e.prototype.executeQuery=function(t,n,a,r){var i=this,o="makeRequest";"function"==typeof t&&(r=a,a=n,n=t,t=null),t||(t=this.defaultQuery),t instanceof rwt||lwt.throwError("DataManager - executeQuery() : A query is required to execute");var l=new ywt,s={query:t};if(!this.dataSource.offline&&void 0!==this.dataSource.url&&""!==this.dataSource.url||!xpt(this.adaptor[o])||this.isCustomDataAdaptor(this.adaptor)){var c=this.adaptor.processQuery(this,t);xpt(this.adaptor[o])?!xpt(c.url)||this.isCustomDataAdaptor(this.adaptor)?this.makeRequest(c,l,s,t):(s=e.getDeferedArgs(t,c,s),l.resolve(s)):this.adaptor[o](c,l,s,t)}else e.nextTick(function(){var n=i.executeLocal(t);s=e.getDeferedArgs(t,n,s),l.resolve(s)});return(n||a)&&l.promise.then(n,a),r&&l.promise.then(r,r),l.promise},e.getDeferedArgs=function(e,t,n){return e.isCountRequired?(n.result=t.result,n.count=t.count,n.aggregates=t.aggregates):n.result=t,n},e.nextTick=function(e){(window.setImmediate||window.setTimeout)(e,0)},e.prototype.extendRequest=function(e,t,n){return bpt({},{type:"GET",dataType:this.dataSource.dataType,crossDomain:this.dataSource.crossDomain,jsonp:this.dataSource.jsonp,cache:!0,processData:!1,onSuccess:t,onFailure:n},e)},e.prototype.makeRequest=function(e,t,n,a){var r=this,i=!!a.subQuerySelector,o=function(e){n.error=e,t.reject(n)},l=function(e,a,r,i,o,l,s){n.xhr=r,n.count=a?parseInt(a.toString(),10):0,n.result=e,n.request=i,n.aggregates=l,n.actual=o,n.virtualSelectRecords=s,t.resolve(n)},s=function(e,t){var s=new ywt,c={parent:n};a.subQuery.isChild=!0;var d=r.adaptor.processQuery(r,a.subQuery,e?r.adaptor.processResponse(e):t),h=r.makeRequest(d,s,c,a.subQuery);return i||s.then(function(t){e&&(lwt.buildHierarchy(a.subQuery.fKey,a.subQuery.fromTable,e,t,a.subQuery.key),l(e,t.count,t.xhr))},o),h},c=this.extendRequest(e,function(e,t){if(r.isGraphQLAdaptor(r.adaptor)&&!xpt(e.errors))return o(e.errors);r.isCustomDataAdaptor(r.adaptor)&&(t=bpt({},r.ajaxReqOption,t)),-1===t.httpRequest.getResponseHeader("Content-Type").indexOf("xml")&&r.dateParse&&(e=lwt.parse.parseJson(e));var n=r.adaptor.processResponse(e,r,a,t.httpRequest,t),c=0,d=null,h=e.virtualSelectRecords;a.isCountRequired&&(c=n.count,d=n.aggregates,n=n.result),a.subQuery?i||s(n,t):l(n,c,t.httpRequest,t.type,e,d,h)},o);if(this.isCustomDataAdaptor(this.adaptor)){this.ajaxReqOption=c;var d=c;this.adaptor.options.getData({data:d.data,onSuccess:d.onSuccess,onFailure:d.onFailure})}else{var h=new lft(c);h.beforeSend=function(){r.beforeSend(h.httpRequest,h)},(c=h.send()).catch(function(e){return!0}),this.requests.push(h)}if(i){var u=a.subQuerySelector.call(this,{query:a.subQuery,parent:a});u&&u.length?Promise.all([c,s(null,u)]).then(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e[0],o=r.adaptor.processResponse(n[0],r,a,r.requests[0].httpRequest,r.requests[0]),s=0;a.isCountRequired&&(s=o.count,o=o.result);var c=r.adaptor.processResponse(n[1],r,a.subQuery,r.requests[1].httpRequest,r.requests[1]);s=0,a.subQuery.isCountRequired&&(s=c.count,c=c.result),lwt.buildHierarchy(a.subQuery.fKey,a.subQuery.fromTable,o,c,a.subQuery.key),i=!1,l(o,s,r.requests[0].httpRequest)}):i=!1}return c},e.prototype.beforeSend=function(e,t){this.adaptor.beforeSend(this,e,t);for(var n,a=this.dataSource.headers,r=0;a&&r<a.length;r++){n=[];for(var i=0,o=Object.keys(a[r]);i<o.length;i++){var l=o[i];n.push(l),e.setRequestHeader(l,a[r][l])}}},e.prototype.saveChanges=function(e,t,n,a,r){var i=this;n instanceof rwt&&(a=n,n=null);var o={url:n,key:t||this.dataSource.key},l=this.adaptor.batchRequest(this,e,o,a||new rwt,r),s="doAjaxRequest";if(this.dataSource.offline)return l;if(xpt(this.adaptor[s])){if(this.isCustomDataAdaptor(this.adaptor))return this.doAjaxRequest(l,this.adaptor.options.batchUpdate);var c=new ywt,d=new lft(l);return d.beforeSend=function(){i.beforeSend(d.httpRequest,d)},d.onSuccess=function(t,n){i.isGraphQLAdaptor(i.adaptor)&&(xpt(t.errors)||d.onFailure(JSON.stringify(t.errors))),c.resolve(i.adaptor.processResponse(t,i,null,n.httpRequest,n,e,o))},d.onFailure=function(e){c.reject([{error:e}])},d.send().catch(function(e){return!0}),c.promise}return this.adaptor[s](l)},e.prototype.insert=function(e,t,n,a){t instanceof rwt&&(n=t,t=null);var r=this.adaptor.insert(this,e,t,n,a),i="doAjaxRequest";return this.dataSource.offline?r:xpt(this.adaptor[i])?this.doAjaxRequest(r,this.adaptor.options.addRecord):this.adaptor[i](r)},e.prototype.remove=function(e,t,n,a){"object"==typeof t&&(t=lwt.getObject(e,t)),n instanceof rwt&&(a=n,n=null);var r=this.adaptor.remove(this,e,t,n,a),i="doAjaxRequest";if(this.dataSource.offline)return r;if(xpt(this.adaptor[i])){var o=this.adaptor.options.deleteRecord;return this.doAjaxRequest(r,o)}return this.adaptor[i](r)},e.prototype.update=function(e,t,n,a,r){n instanceof rwt&&(a=n,n=null);var i=this.adaptor.update(this,e,t,n,a,r),o="doAjaxRequest";if(this.dataSource.offline)return i;if(xpt(this.adaptor[o])){var l=this.adaptor.options.updateRecord;return this.doAjaxRequest(i,l)}return this.adaptor[o](i)},e.prototype.isCustomDataAdaptor=function(e){return this.adaptor.getModuleName&&"CustomDataAdaptor"===this.adaptor.getModuleName()},e.prototype.isGraphQLAdaptor=function(e){return this.adaptor.getModuleName&&"GraphQLAdaptor"===this.adaptor.getModuleName()},e.prototype.successFunc=function(e,t){if(this.isGraphQLAdaptor(this.adaptor)){var n=JSON.parse(e);xpt(n.errors)||this.failureFunc(JSON.stringify(n.errors))}this.isCustomDataAdaptor(this.adaptor)&&(t=bpt({},this.ajaxReqOption,t));try{lwt.parse.parseJson(e)}catch(t){e=[]}e=this.adaptor.processResponse(lwt.parse.parseJson(e),this,null,t.httpRequest,t),this.ajaxDeffered.resolve(e)},e.prototype.failureFunc=function(e){this.ajaxDeffered.reject([{error:e}])},e.prototype.doAjaxRequest=function(e,t){var n=this;if(e=bpt({},{type:"POST",contentType:"application/json; charset=utf-8",processData:!1},e),this.ajaxDeffered=new ywt,this.isCustomDataAdaptor(this.adaptor))this.ajaxReqOption=e,t.call(this,{data:e.data,onSuccess:this.successFunc.bind(this),onFailure:this.failureFunc.bind(this)});else{var a=new lft(e);a.beforeSend=function(){n.beforeSend(a.httpRequest,a)},a.onSuccess=this.successFunc.bind(this),a.onFailure=this.failureFunc.bind(this),a.send().catch(function(e){return!0})}return this.ajaxDeffered.promise},e}(),ywt=function(){var e=this;this.promise=new Promise(function(t,n){e.resolve=t,e.reject=n}),this.then=this.promise.then.bind(this.promise),this.catch=this.promise.catch.bind(this.promise)},bwt={li:"e-list-item",ul:"e-list-parent e-ul",group:"e-list-group-item",icon:"e-list-icon",text:"e-list-text",check:"e-list-check",checked:"e-checked",selected:"e-selected",expanded:"e-expanded",textContent:"e-text-content",hasChild:"e-has-child",level:"e-level",url:"e-list-url",collapsible:"e-icon-collapsible",disabled:"e-disabled",image:"e-list-img",iconWrapper:"e-icon-wrapper",anchorWrap:"e-anchor-wrap",navigable:"e-navigable"};function xwt(e,t){var n={};if(xpt(e)||"string"==typeof e||"number"==typeof e||!xpt(e.isHeader))return e;for(var a=0,r=Object.keys(t);a<r.length;a++){var i=t[r[a]],o=xpt(i)||"string"!=typeof i?void 0:fpt(i,e);xpt(o)||(n[i]=o)}return n}function Ewt(e){if(e)try{return document.querySelector(e)?pvt(document.querySelector(e).innerHTML.trim()):pvt(e)}catch(t){return pvt(e)}}!function(e){e.defaultMappedFields={id:"id",text:"text",url:"url",value:"value",isChecked:"isChecked",enabled:"enabled",expanded:"expanded",selected:"selected",iconCss:"iconCss",child:"child",isVisible:"isVisible",hasChildren:"hasChildren",tooltip:"tooltip",htmlAttributes:"htmlAttributes",urlAttributes:"urlAttributes",imageAttributes:"imageAttributes",imageUrl:"imageUrl",groupBy:null,sortBy:null};var t={level:1,listRole:"presentation",itemRole:"presentation",groupItemRole:"group",itemText:"list-item",wrapperRole:"presentation"},n={showCheckBox:!1,showIcon:!1,enableHtmlSanitizer:!1,expandCollapse:!1,fields:e.defaultMappedFields,ariaAttributes:t,listClass:"",itemClass:"",processSubChild:!1,sortOrder:"None",template:null,groupTemplate:null,headerTemplate:null,expandIconClass:"e-icon-collapsible",moduleName:"list",expandIconPosition:"Right",itemNavigable:!1};function a(e,t,n,a,i){return y(e,r(e,t,n,a,i),null,a)}function r(e,t,a,r,i){var o=[],l=bpt({},n,r);bwt=v(l.moduleName);for(var s=p(),c=0;c<t.length;c++)if(!xpt(t[c])){var d=void 0;if(l.itemCreating&&"function"==typeof l.itemCreating){var h={dataSource:t,curData:t[c],text:t[c],options:l};l.itemCreating(h)}if(d=a?m(e,t[c],void 0,null,null,[],null,s,c,r):w(e,t[c],void 0,null,null,r,i),l.itemCreated&&"function"==typeof l.itemCreated){h={dataSource:t,curData:t[c],text:t[c],item:d,options:l};l.itemCreated(h)}o.push(d)}return o}function i(a,r,i,o,l,s){var c=bpt({},n,i);bwt=v(c.moduleName);var u,g=!s||"listview"!==s.getModuleName()&&"multiselect"!==s.getModuleName()?bpt({},e.defaultMappedFields,c.fields):c.fields,y=bpt({},t,c.ariaAttributes),b=[];o&&(y.level=o);var x,E,k=[];r&&r.length&&!xpt(d(r).item)&&!d(r).item.hasOwnProperty(g.id)&&(u=p());for(var M=0;M<r.length;M++){var S=xwt(r[M],g);if(!xpt(r[M])){if(c.itemCreating&&"function"==typeof c.itemCreating){var A={dataSource:r,curData:r[M],text:S[g.text],options:c,fields:g};c.itemCreating(A)}var _=r[M];c.itemCreating&&"function"==typeof c.itemCreating&&(S=xwt(r[M],g)),S.hasOwnProperty(g.id)&&!xpt(S[g.id])&&(u=S[g.id]);var C=[];if(c.showCheckBox&&(c.itemNavigable&&(S[g.url]||S[g.urlAttributes])?b.push(a("input",{className:bwt.check,attrs:{type:"checkbox"}})):C.push(a("input",{className:bwt.check,attrs:{type:"checkbox"}}))),!0===l)c.showIcon&&S.hasOwnProperty(g.iconCss)&&!xpt(S[g.iconCss])&&C.push(a("span",{className:bwt.icon+" "+S[g.iconCss]})),E=(x=m(a,_,S,g,c.itemClass,C,!(!_.hasOwnProperty("isHeader")||!_.isHeader),u,M,i)).querySelector("."+bwt.anchorWrap),c.itemNavigable&&b.length&&Sft(b,x.firstElementChild);else{if((x=w(a,_,S,g,c.itemClass,i,s)).classList.add(bwt.level+"-"+y.level),x.setAttribute("aria-level",y.level.toString()),E=x.querySelector("."+bwt.anchorWrap),S.hasOwnProperty(g.tooltip)&&x.setAttribute("title",S[g.tooltip]),S.hasOwnProperty(g.htmlAttributes)&&S[g.htmlAttributes]&&h(x,S[g.htmlAttributes]),S.hasOwnProperty(g.enabled)&&!1===S[g.enabled]&&x.classList.add(bwt.disabled),S.hasOwnProperty(g.isVisible)&&!1===S[g.isVisible]&&(x.style.display="none"),S.hasOwnProperty(g.imageUrl)&&!xpt(S[g.imageUrl])&&!c.template){var Z={src:S[g.imageUrl]};ypt(Z,S[g.imageAttributes]);var H=a("img",{className:bwt.image,attrs:Z});E?E.insertAdjacentElement("afterbegin",H):Sft([H],x.firstElementChild)}if(c.showIcon&&S.hasOwnProperty(g.iconCss)&&!xpt(S[g.iconCss])&&!c.template){var I=a("div",{className:bwt.icon+" "+S[g.iconCss]});E?E.insertAdjacentElement("afterbegin",I):Sft([I],x.firstElementChild)}C.length&&Sft(C,x.firstElementChild),c.itemNavigable&&b.length&&Sft(b,x.firstElementChild),f(a,S,g,r,c,x,y.level)}if(E&&xft([x],[bwt.navigable]),c.itemCreated&&"function"==typeof c.itemCreated){A={dataSource:r,curData:r[M],text:S[g.text],item:x,options:c,fields:g};c.itemCreated(A)}b=[],k.push(x)}}return k}function o(e,t,a,r,o,l){var s=bpt({},n,a);return y(e,i(e,t,a,r,o,l),s.listClass,a)}function l(e,t){if(t&&e){return Array.prototype.slice.call(t).indexOf(e)}}function s(e,t,n){if(void 0===n&&(n=new rwt),"Ascending"===e)n.sortBy(t,"ascending",!0);else if("Descending"===e)n.sortBy(t,"descending",!0);else for(var a=0;a<n.queries.length;a++)"onSortBy"===n.queries[a].fn&&n.queries.splice(a,1);return n}function c(e,t){return new wwt(e).executeLocal(t)}function d(e){for(var t={typeof:null,item:null},n=0;n<e.length;n++)if(!xpt(e[n]))return{typeof:typeof e[n],item:e[n]};return t}function h(e,t){var n={};ypt(n,t),n.class&&(xft([e],n.class.split(" ")),delete n.class),Hft(e,n)}function u(e){for(var t={},n=e.attributes,a=0;a<n.length;a++)t[n[a].nodeName]=n[a].nodeValue;return t}function p(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}function f(e,t,n,a,r,i,l){var s=t[n.child]||[],c=t[n.hasChildren];if(s.length&&(c=!0,i.classList.add(bwt.hasChild),r.processSubChild)){var d=o(e,s,r,++l);i.appendChild(d)}r.expandCollapse&&c&&!r.template&&(i.firstElementChild.classList.add(bwt.iconWrapper),("Left"===r.expandIconPosition?Sft:Aft)([e("div",{className:"e-icons "+r.expandIconClass})],i.querySelector("."+bwt.textContent)))}function m(e,a,r,i,o,l,s,c,d,u){var p,f,m=bpt({},n,u),v=bpt({},t,m.ariaAttributes),w=a,y=a;"string"!=typeof a&&"number"!=typeof a&&"boolean"!=typeof a&&(p=a,w="boolean"==typeof r[i.text]||"number"==typeof r[i.text]?r[i.text]:r[i.text]||"",y=r[i.value]),f=xpt(p)||xpt(r[i.id])||""===r[i.id]?c+"-"+d:c;var b=e("li",{className:(!0===s?bwt.group:bwt.li)+" "+(xpt(o)?"":o),id:f,attrs:""!==v.groupItemRole&&""!==v.itemRole?{role:!0===s?v.groupItemRole:v.itemRole}:{}});return p&&r.hasOwnProperty(i.enabled)&&"false"===r[i.enabled].toString()&&b.classList.add(bwt.disabled),s?b.innerText=w:(b.setAttribute("data-value",xpt(y)?"null":y),b.setAttribute("role","option"),p&&r.hasOwnProperty(i.htmlAttributes)&&r[i.htmlAttributes]&&h(b,r[i.htmlAttributes]),l.length&&!m.itemNavigable&&Aft(l,b),p&&(r[i.url]||r[i.urlAttributes]&&r[i.urlAttributes].href)?b.appendChild(g(e,p,i,w,l,m.itemNavigable)):(l.length&&m.itemNavigable&&Aft(l,b),b.appendChild(document.createTextNode(w)))),b}function v(e){return{li:"e-"+e+"-item",ul:"e-"+e+"-parent e-ul",group:"e-"+e+"-group-item",icon:"e-"+e+"-icon",text:"e-"+e+"-text",check:"e-"+e+"-check",checked:"e-checked",selected:"e-selected",expanded:"e-expanded",textContent:"e-text-content",hasChild:"e-has-child",level:"e-level",url:"e-"+e+"-url",collapsible:"e-icon-collapsible",disabled:"e-disabled",image:"e-"+e+"-img",iconWrapper:"e-icon-wrapper",anchorWrap:"e-anchor-wrap",navigable:"e-navigable"}}function g(e,t,n,a,r,i){var o,l=xwt(t,n),s={href:l[n.url]};if(l.hasOwnProperty(n.urlAttributes)&&l[n.urlAttributes]&&(ypt(s,l[n.urlAttributes]),s.href=l[n.url]?l[n.url]:l[n.urlAttributes].href),i){o=e("a",{className:bwt.text+" "+bwt.url});var c=e("div",{className:bwt.anchorWrap});r&&r.length&&Aft(r,c),c.appendChild(document.createTextNode(a)),Aft([c],o)}else o=e("a",{className:bwt.text+" "+bwt.url,innerHTML:a});return h(o,s),o}function w(e,a,r,i,o,l,s){var c,d,h,u=bpt({},n,l),f=bpt({},t,u.ariaAttributes),m=a;"string"!=typeof a&&"number"!=typeof a&&(h=a,m=r[i.text]||"",c=xpt(r._id)?r[i.id]:r._id,d=!(!a.hasOwnProperty("isHeader")||!a.isHeader)),l&&l.enableHtmlSanitizer;var v=e("li",{className:(!0===d?bwt.group:bwt.li)+" "+(xpt(o)?"":o),attrs:""!==f.groupItemRole&&""!==f.itemRole?{role:!0===d?f.groupItemRole:f.itemRole}:{}});if(!0==!xpt(c)?v.setAttribute("data-uid",c):v.setAttribute("data-uid",p()),d&&l&&l.groupTemplate){var w=Ewt(l.groupTemplate);if(s&&"listview"!==s.getModuleName())(y=w(a,s,"groupTemplate",u.groupTemplateID,!!u.isStringTemplate,null,v))&&Aft(y,v);else Aft(w(a,s,"groupTemplate",u.groupTemplateID,!!u.isStringTemplate),v)}else if(!d&&l&&l.template){var y;w=Ewt(l.template);if(s&&"listview"!==s.getModuleName())(y=w(a,s,"template",u.templateID,!!u.isStringTemplate,null,v))&&Aft(y,v);else Aft(w(a,s,"template",u.templateID,!!u.isStringTemplate),v)}else{var b=e("div",{className:bwt.textContent,attrs:""!==f.wrapperRole?{role:f.wrapperRole}:{}});if(h&&(r[i.url]||r[i.urlAttributes]&&r[i.urlAttributes].href))b.appendChild(g(e,h,i,m,null,u.itemNavigable));else{var x=e("span",{className:bwt.text,attrs:""!==f.itemText?{role:f.itemText}:{}});l&&l.enableHtmlSanitizer?x.innerText=m:x.innerHTML=m,b.appendChild(x)}v.appendChild(b)}return v}function y(e,a,r,i){var o=bpt({},n,i),l=bpt({},t,o.ariaAttributes),s=e("ul",{className:(bwt=v(o.moduleName)).ul+" "+(xpt(r)?"":r),attrs:""!==l.listRole?{role:l.listRole}:{}});return Aft(a,s),s}e.createList=function(e,r,i,l,s){var c=bpt({},n,i),h=bpt({},t,c.ariaAttributes),u=d(r).typeof;return"string"===u||"number"===u?a(e,r,l,i,s):o(e,r,i,h.level,l,s)},e.createListFromArray=a,e.createListItemFromArray=r,e.createListItemFromJson=i,e.createListFromJson=o,e.getSiblingLI=function(e,t,a){if(bwt=v(n.moduleName),e&&e.length){var r,i,o=Array.prototype.slice.call(e);for(r=o[(i=t?l(t,o):!0===a?o.length:-1)+(!0===a?-1:1)];r&&(!Mft(r)||r.classList.contains(bwt.disabled));)r=o[i+=!0===a?-1:1];return r}},e.indexOf=l,e.groupDataSource=function(t,n,a){void 0===a&&(a="None");var r=bpt({},e.defaultMappedFields,n),i=(new rwt).group(r.groupBy),o=c(t,i=s(a,"key",i));t=[];for(var l=0;l<o.length;l++){var d=o[l].items,h={};h[r.text]=o[l].key,h.isHeader=!0;var u=r.text;"id"===u&&(h[u="text"]=o[l].key),h._id="group-list-item-"+(o[l].key?o[l].key.toString().trim():"undefined"),h.items=d,t.push(h);for(var p=0;p<d.length;p++)t.push(d[p])}return t},e.addSorting=s,e.getDataSource=c,e.createJsonFromElement=function t(a,r){var i=bpt({},n,r),o=bpt({},e.defaultMappedFields,i.fields),l=a.cloneNode(!0),s=[];l.classList.add("json-parent");var c=l.querySelectorAll(".json-parent>li");l.classList.remove("json-parent");for(var d=0;d<c.length;d++){for(var h=c[d],f=h.querySelector("a"),m=h.querySelector("ul"),v={},g=f?f.childNodes:h.childNodes,w=Object.keys(g),y=0;y<g.length;y++)g[Number(w[y])].hasChildNodes()||(v[o.text]=g[Number(w[y])].textContent);var b=u(h);b.id?(v[o.id]=b.id,delete b.id):v[o.id]=p(),Object.keys(b).length&&(v[o.htmlAttributes]=b),f&&(b=u(f),Object.keys(b).length&&(v[o.urlAttributes]=b)),m&&(v[o.child]=t(m,r)),s.push(v)}return s},e.renderContentTemplate=function(t,a,r,i,o,l){for(var s,c=t("ul",{className:(bwt=v(n.moduleName)).ul,attrs:{role:"presentation"}}),d=bpt({},n,o),h=bpt({},e.defaultMappedFields,i),u=Ewt(a),f=[],m=p(),g=0;g<r.length;g++){var w=xwt(r[g],h),y=r[g],b=y.isHeader;if(s="string"==typeof r[g]||"number"==typeof r[g]?y:w[h.value],d.itemCreating&&"function"==typeof d.itemCreating){var x={dataSource:r,curData:y,text:s,options:d,fields:h};d.itemCreating(x)}d.itemCreating&&"function"==typeof d.itemCreating&&(w=xwt(r[g],h),s="string"==typeof r[g]||"number"==typeof r[g]?y:w[h.value]);var E=t("li",{id:m+"-"+g,className:b?bwt.group:bwt.li,attrs:{role:"presentation"}});if(b)"string"==typeof r[g]||"number"==typeof r[g]?E.innerText=y:E.innerText=w[h.text];else{var k,M=b?d.groupTemplateID:d.templateID;if(b)if(l&&"listview"!=l.getModuleName())(k=u(y,l,"headerTemplate",M,!!d.isStringTemplate,null,E))&&Aft(k,E);else Aft(u(y,l,"headerTemplate",M,!!d.isStringTemplate),E);else if(l&&"listview"!==l.getModuleName())(k=u(y,l,"template",M,!!d.isStringTemplate,null,E))&&Aft(k,E);else Aft(u(y,l,"template",M,!!d.isStringTemplate),E);E.setAttribute("data-value",xpt(s)?"null":s),E.setAttribute("role","option")}if(d.itemCreated&&"function"==typeof d.itemCreated){x={dataSource:r,curData:y,text:s,item:E,options:d,fields:h};d.itemCreated(x)}f.push(E)}return Aft(f,c),c},e.renderGroupTemplate=function(t,a,r,i,o,l){for(var s=Ewt(t),c=bpt({},e.defaultMappedFields,r),d=bpt({},n,o),h=c.groupBy,u=0,p=i;u<p.length;u++){var f=p[u],m={};if(m[h]=f.textContent,f.innerHTML="",l&&"listview"!==l.getModuleName()){var v=s(m,l,"groupTemplate",d.groupTemplateID,!!d.isStringTemplate,null,f);v&&Aft(v,f)}else Aft(s(m,l,"groupTemplate",d.groupTemplateID,!!d.isStringTemplate),f)}return i},e.generateId=p,e.generateUL=y,e.generateIcon=function(e,t,a,r){var i=bpt({},n,r);return bwt=v(i.moduleName),("Left"===i.expandIconPosition?Sft:Aft)([e("div",{className:"e-icons "+i.expandIconClass+" "+(xpt(a)?"":a)})],t.querySelector("."+bwt.textContent)),t}}(vwt||(vwt={}));var kwt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Mwt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Swt="e-input-group",Awt="e-popup",_wt="e-left-calendar",Cwt="e-right-calendar",Zwt="e-daterangepicker",Hwt="e-error",Iwt="e-active",Dwt="e-start-date",Nwt="e-end-date",Owt="e-start-btn",Lwt="e-input-focus",Vwt="e-range-hover",zwt="e-other-month",Pwt="e-start-label",Twt="e-end-label",Bwt="e-disabled",jwt="e-selected",Wwt="e-calendar",Rwt="e-next",Fwt="e-prev",Ywt="e-header",qwt="e-title",Uwt="e-icon-container",Gwt="e-date-range-container",Kwt="e-presets",Qwt="e-today",Xwt="e-focused-date",Jwt="e-content",$wt="e-day-span",eyt="e-week-number",tyt="e-date-disabled",nyt="e-icon-disabled",ayt="e-device",ryt="e-overlay",iyt="e-list-item",oyt="e-hover",lyt="e-range-overflow",syt="e-flat",cyt="e-css",dyt="e-non-edit",hyt="e-daterange-hidden",uyt=["title","class","style"],pyt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return kwt(t,e),Mwt([Kft()],t.prototype,"label",void 0),Mwt([Kft()],t.prototype,"start",void 0),Mwt([Kft()],t.prototype,"end",void 0),t}(fmt),fyt=function(e){function t(t,n){var a=e.call(this,t,n)||this;return a.isCustomRange=!1,a.isCustomWindow=!1,a.presetsItem=[],a.liCollections=[],a.previousEleValue="",a.isKeyPopup=!1,a.dateDisabled=!1,a.isRangeIconClicked=!1,a.isMaxDaysClicked=!1,a.disabledDays=[],a.preventBlur=!1,a.preventFocus=!1,a.invalidValueString=null,a.isAngular=!1,a.preventChange=!1,a.dateRangeOptions=t,a}return kwt(t,e),t.prototype.render=function(){this.initialize(),this.setProperties({startDate:this.startValue},!0),this.setProperties({endDate:this.endValue},!0),this.setModelValue(),this.setDataAttribute(!1),this.element.hasAttribute("data-val")&&this.element.setAttribute("data-val","false"),this.renderComplete()},t.prototype.preRender=function(){if(this.keyInputConfigs={altDownArrow:"alt+downarrow",escape:"escape",enter:"enter",tab:"tab",altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow",moveUp:"uparrow",moveDown:"downarrow",spacebar:"space"},this.defaultConstant={placeholder:this.placeholder,startLabel:"Start Date",endLabel:"End Date",customRange:"Custom Range",applyText:"Apply",cancelText:"Cancel",selectedDays:"Selected Days",days:"days"},this.isMobile=window.matchMedia("(max-width:550px)").matches,this.inputElement=this.element,this.angularTag=null,"EJS-DATERANGEPICKER"===this.element.tagName&&(this.angularTag=this.element.tagName,this.inputElement=this.createElement("input"),this.element.appendChild(this.inputElement)),this.cloneElement=this.element.cloneNode(!0),Eft([this.cloneElement],[Zwt,"e-control","e-lib"]),this.updateHtmlAttributeToElement(),this.element.getAttribute("id")?null!==this.angularTag&&(this.inputElement.id=this.element.getAttribute("id")+"_input"):(this.element.id=kpt("ej2-datetimepicker"),null!==this.angularTag&&Hft(this.inputElement,{id:this.element.id+"_input"})),this.checkInvalidRange(this.value),!this.invalidValueString&&"string"==typeof this.value){var t=this.value.split(" "+this.separator+" ");this.value=[new Date(t[0]),new Date(t[1])]}this.initProperty(),this.tabIndex=this.element.hasAttribute("tabindex")?this.element.getAttribute("tabindex"):"0",this.element.removeAttribute("tabindex"),e.prototype.preRender.call(this),this.navNextFunction=this.navNextMonth.bind(this),this.navPrevFunction=this.navPrevMonth.bind(this),this.deviceNavNextFunction=this.deviceNavNext.bind(this),this.deviceNavPrevFunction=this.deviceNavPrevious.bind(this),this.initStartDate=this.checkDateValue(this.startValue),this.initEndDate=this.checkDateValue(this.endValue),this.formElement=Oft(this.element,"form")},t.prototype.updateValue=function(){this.value&&this.value.length>0?(this.value[0]instanceof Date&&!isNaN(+this.value[0])?(this.setProperties({startDate:this.value[0]},!0),this.startValue=this.value[0]):"string"==typeof this.value[0]?0===+this.value[0]||isNaN(+new Date(this.checkValue(this.value[0])))?(this.startValue=null,this.setValue()):(this.setProperties({startDate:new Date(this.checkValue(this.value[0]))},!0),this.startValue=new Date(this.checkValue(this.value[0]))):(this.startValue=null,this.setValue()),this.value[1]instanceof Date&&!isNaN(+this.value[1])?(this.setProperties({endDate:this.value[1]},!0),this.endValue=this.value[1]):"string"==typeof this.value[1]?0===+this.value[0]||isNaN(+new Date(this.checkValue(this.value[0])))?(this.setProperties({endDate:null},!0),this.endValue=null,this.setValue()):(this.setProperties({endDate:new Date(this.checkValue(this.value[1]))},!0),this.endValue=new Date(this.checkValue(this.value[1])),this.setValue()):(this.setProperties({endDate:null},!0),this.endValue=null,this.setValue())):this.value&&this.value.start?(this.value.start instanceof Date&&!isNaN(+this.value.start)?(this.setProperties({startDate:this.value.start},!0),this.startValue=this.value.start):"string"==typeof this.value.start?(this.setProperties({startDate:new Date(this.checkValue(this.value.start))},!0),this.startValue=new Date(this.checkValue(this.value.start))):(this.startValue=null,this.setValue()),this.value.end instanceof Date&&!isNaN(+this.value.end)?(this.setProperties({endDate:this.value.end},!0),this.endValue=this.value.end):"string"==typeof this.value.end?(this.setProperties({endDate:new Date(this.checkValue(this.value.end))},!0),this.endValue=new Date(this.checkValue(this.value.end)),this.setValue()):(this.setProperties({endDate:null},!0),this.endValue=null,this.setValue())):xpt(this.value)&&(this.endValue=this.checkDateValue(new Date(this.checkValue(this.endDate))),this.startValue=this.checkDateValue(new Date(this.checkValue(this.startDate))),this.setValue())},t.prototype.initProperty=function(){this.globalize=new aft(this.locale),this.checkFormat(),this.checkView(),(xpt(this.firstDayOfWeek)||this.firstDayOfWeek>6||this.firstDayOfWeek<0)&&this.setProperties({firstDayOfWeek:this.globalize.getFirstDayOfWeek()},!0),this.updateValue()},t.prototype.checkFormat=function(){if(this.format)if("string"==typeof this.format)this.formatString=this.format;else if(""===this.format.skeleton||xpt(this.format.skeleton))this.formatString=null;else{var e=this.format.skeleton;this.formatString=this.globalize.getDatePattern({skeleton:e,type:"date"})}else this.formatString=null},t.prototype.initialize=function(){null!==this.angularTag&&this.validationAttribute(this.element,this.inputElement),this.checkHtmlAttributes(!1),ypt(this.defaultKeyConfigs,{shiftTab:"shift+tab",tab:"tab"});var e=this.checkDateValue(new Date(this.checkValue(this.startValue)));this.setProperties({startDate:e},!0),this.setProperties({endValue:this.checkDateValue(new Date(this.checkValue(this.endValue)))},!0),this.setValue(),this.setProperties({min:this.checkDateValue(new Date(this.checkValue(this.min)))},!0),this.setProperties({max:this.checkDateValue(new Date(this.checkValue(this.max)))},!0),this.l10n=new zmt("daterangepicker",this.defaultConstant,this.locale),this.l10n.setLocale(this.locale),this.setProperties({placeholder:this.placeholder||this.l10n.getConstant("placeholder")},!0),this.processPresets(),this.createInput(),this.updateHtmlAttributeToWrapper(),this.setRangeAllowEdit(),this.bindEvents()},t.prototype.setDataAttribute=function(e){var t={};if(e)t=this.htmlAttributes;else for(var n=0;n<this.element.attributes.length;n++)t[this.element.attributes[n].name]=this.element.getAttribute(this.element.attributes[n].name);for(var a=0,r=Object.keys(t);a<r.length;a++){var i=r[a];0===i.indexOf("data")&&(this.firstHiddenChild.setAttribute(i,t[i]),this.secondHiddenChild.setAttribute(i,t[i]))}},t.prototype.setRangeAllowEdit=function(){this.allowEdit?this.readonly||this.inputElement.removeAttribute("readonly"):Hft(this.inputElement,{readonly:""}),this.updateClearIconState()},t.prototype.updateClearIconState=function(){this.allowEdit||!this.inputWrapper||this.readonly?this.inputWrapper&&Eft([this.inputWrapper.container],[dyt]):""===this.inputElement.value?Eft([this.inputWrapper.container],[dyt]):xft([this.inputWrapper.container],[dyt])},t.prototype.validationAttribute=function(e,t){var n=e.getAttribute("name")?e.getAttribute("name"):e.getAttribute("id");t.setAttribute("name",n),e.removeAttribute("name");for(var a=["required","aria-required","form"],r=0;r<a.length;r++)if(!xpt(e.getAttribute(a[r]))){var i=e.getAttribute(a[r]);t.setAttribute(a[r],i),e.removeAttribute(a[r])}},t.prototype.updateHtmlAttributeToWrapper=function(){if(!xpt(this.htmlAttributes))for(var e=0,t=Object.keys(this.htmlAttributes);e<t.length;e++){var n=t[e];if(uyt.indexOf(n)>-1)if("class"===n){var a=this.htmlAttributes[n].replace(/\s+/g," ").trim();""!==a&&xft([this.inputWrapper.container],a.split(" "))}else if("style"===n){var r=this.inputWrapper.container.getAttribute(n);r=xpt(r)?this.htmlAttributes[n]:r+this.htmlAttributes[n],this.inputWrapper.container.setAttribute(n,r)}else this.inputWrapper.container.setAttribute(n,this.htmlAttributes[n])}},t.prototype.updateHtmlAttributeToElement=function(){if(!xpt(this.htmlAttributes))for(var e=0,t=Object.keys(this.htmlAttributes);e<t.length;e++){var n=t[e];uyt.indexOf(n)<0&&this.inputElement.setAttribute(n,this.htmlAttributes[n])}},t.prototype.updateCssClass=function(e,t){xpt(t)||(t=t.replace(/\s+/g," ").trim()),xpt(e)||(e=e.replace(/\s+/g," ").trim()),Vgt.setCssClass(e,[this.inputWrapper.container],t),this.popupWrapper&&Vgt.setCssClass(e,[this.popupWrapper],t)},t.prototype.processPresets=function(){this.presetsItem=[];var e=0;if(!Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)){for(var t=0,n=this.presets;t<n.length;t++){var a=n[t],r=a.label.replace(/\s+/g,"")+"_"+ ++e;"string"==typeof a.end?this.presetsItem.push({id:r,text:a.label,end:new Date(this.checkValue(a.end)),start:new Date(this.checkValue(a.start))}):this.presetsItem.push({id:r,text:a.label,start:a.start,end:a.end})}var i=xpt(this.startValue)?null:new Date(+this.startValue),o=xpt(this.endValue)?null:new Date(+this.endValue);this.presetsItem.push({id:"custom_range",text:this.l10n.getConstant("customRange"),start:i,end:o}),xpt(this.startValue)||xpt(this.endValue)||(this.isCustomRange=!0,this.activeIndex=this.presetsItem.length-1)}},t.prototype.bindEvents=function(){wft.add(this.inputWrapper.buttons[0],"mousedown",this.rangeIconHandler,this),wft.add(this.inputElement,"focus",this.inputFocusHandler,this),wft.add(this.inputElement,"blur",this.inputBlurHandler,this),wft.add(this.inputElement,"change",this.inputChangeHandler,this),this.showClearButton&&this.inputWrapper.clearButton&&wft.add(this.inputWrapper.clearButton,"mousedown",this.resetHandler,this),this.isMobile||(this.keyInputConfigs=bpt(this.keyInputConfigs,this.keyConfigs),this.inputKeyboardModule=new Vmt(this.inputElement,{eventName:"keydown",keyAction:this.inputHandler.bind(this),keyConfigs:this.keyInputConfigs})),this.formElement&&wft.add(this.formElement,"reset",this.formResetHandler,this),this.enabled?this.inputElement.setAttribute("tabindex",this.tabIndex):this.inputElement.tabIndex=-1},t.prototype.unBindEvents=function(){wft.remove(this.inputWrapper.buttons[0],"mousedown",this.rangeIconHandler),wft.remove(this.inputElement,"blur",this.inputBlurHandler),wft.remove(this.inputElement,"focus",this.inputFocusHandler),wft.remove(this.inputElement,"change",this.inputChangeHandler),this.showClearButton&&this.inputWrapper.clearButton&&wft.remove(this.inputWrapper.clearButton,"mousedown touchstart",this.resetHandler),this.isMobile||xpt(this.inputKeyboardModule)||this.inputKeyboardModule.destroy(),this.formElement&&wft.remove(this.formElement,"reset",this.formResetHandler),this.inputElement.tabIndex=-1},t.prototype.updateHiddenInput=function(){if(this.firstHiddenChild&&this.secondHiddenChild){var e={type:"datetime",skeleton:"yMd"};"string"==typeof this.startDate&&(this.startDate=this.globalize.parseDate(this.startDate,e)),"string"==typeof this.endDate&&(this.endDate=this.globalize.parseDate(this.endDate,e)),this.firstHiddenChild.value=this.startDate&&this.globalize.formatDate(this.startDate,e)||this.inputElement.value,this.secondHiddenChild.value=this.endDate&&this.globalize.formatDate(this.endDate,e)||this.inputElement.value,this.dispatchEvent(this.firstHiddenChild,"focusout"),this.dispatchEvent(this.firstHiddenChild,"change")}},t.prototype.inputChangeHandler=function(e){this.enabled&&(e.stopPropagation(),this.updateHiddenInput())},t.prototype.bindClearEvent=function(){this.showClearButton&&this.inputWrapper.clearButton&&wft.add(this.inputWrapper.clearButton,"mousedown",this.resetHandler,this)},t.prototype.resetHandler=function(e){if(this.enabled){this.valueType=this.value,e.preventDefault(),this.clear();var t={event:e};this.setProperties({endDate:this.checkDateValue(this.endValue)},!0),this.setProperties({startDate:this.checkDateValue(this.startValue)},!0),this.trigger("cleared",t),this.changeTrigger(e),this.clearRange(),this.hide(e)}},t.prototype.restoreValue=function(){this.previousEleValue=this.inputElement.value,this.previousStartValue=this.startValue,this.previousEndValue=this.endValue,this.valueType=null,this.initStartDate=this.checkDateValue(this.startValue),this.initEndDate=this.checkDateValue(this.endValue),this.setValue(),this.setModelValue()},t.prototype.formResetHandler=function(e){if(this.enabled&&this.formElement&&e.target===this.formElement&&!this.inputElement.disabled){var t=this.inputElement.getAttribute("value");xpt(this.startCopy)?(this.setProperties({value:null,startDate:null,endDate:null},!0),this.startValue=this.endValue=null):(xpt(this.value)||xpt(this.value.start)?(this.setProperties({value:[this.startCopy,this.endCopy]},!0),this.startValue=this.value[0],this.endValue=this.value[1]):(this.setProperties({value:{start:this.startCopy,end:this.endCopy}},!0),this.startValue=this.value.start,this.endValue=this.value.end),this.setProperties({startDate:this.startValue,endDate:this.endValue},!0)),"EJS-DATERANGEPICKER"===this.element.tagName&&(this.setProperties({value:null,startDate:null,endDate:null},!0),t="",this.startValue=this.endValue=null,this.inputElement.setAttribute("value","")),this.restoreValue(),this.inputElement&&(Vgt.setValue(t,this.inputElement,this.floatLabelType,this.showClearButton),this.errorClass())}},t.prototype.clear=function(){null!==this.startValue&&(this.startValue=null),null!==this.endValue&&(this.endValue=null),this.value&&this.value.start&&this.setProperties({value:{start:null,end:null}},!0),null!==this.value&&this.value.length>0&&this.setProperties({value:null},!0),Vgt.setValue("",this.inputElement,this.floatLabelType,this.showClearButton),xpt(this.applyButton)||(this.applyButton.disabled=this.applyButton.element.disabled=!0),this.removeSelection()},t.prototype.rangeIconHandler=function(e){this.enabled&&(this.isMobile&&this.inputElement.setAttribute("readonly",""),e.preventDefault(),this.targetElement=null,this.isPopupOpen()&&document.body.contains(this.popupObj.element)?this.applyFunction(e):(this.isRangeIconClicked=!0,this.inputWrapper.container.children[0].focus(),this.show(null,e),this.isMobile||xpt(this.leftCalendar)||(this.isRangeIconClicked=!1,this.calendarFocus(),this.isRangeIconClicked=!0),xft([this.inputWrapper.container],[Lwt])))},t.prototype.checkHtmlAttributes=function(e){this.globalize=new aft(this.locale);for(var t=e?xpt(this.htmlAttributes)?[]:Object.keys(this.htmlAttributes):["startDate","endDate","minDays","maxDays","min","max","disabled","readonly","style","name","placeholder","type","value"],n={format:this.formatString,type:"date",skeleton:"yMd"},a=0,r=t;a<r.length;a++){var i=r[a];if(!xpt(this.inputElement.getAttribute(i)))switch(i){case"disabled":if(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.enabled||e){var o="disabled"===this.inputElement.getAttribute(i)||""===this.inputElement.getAttribute(i)||"true"===this.inputElement.getAttribute(i);this.setProperties({enabled:!o},!e)}break;case"readonly":if(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.readonly||e){var l="readonly"===this.inputElement.getAttribute(i)||"true"===this.inputElement.getAttribute(i)||""===this.inputElement.getAttribute(i);this.setProperties({readonly:l},!e)}break;case"placeholder":(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.placeholder||e)&&this.setProperties({placeholder:this.inputElement.getAttribute(i)},!e);break;case"value":if(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.value||e){var s=this.inputElement.getAttribute(i);this.setProperties(mpt(i,s,{}),!e)}break;case"style":this.inputElement.setAttribute("style",""+this.inputElement.getAttribute(i));break;case"min":if(xpt(this.min)||+this.min===+new Date(1900,0,1)||e){var c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.setProperties(mpt(i,c,{}),!e)}break;case"name":this.inputElement.setAttribute("name",""+this.inputElement.getAttribute(i));break;case"max":if(xpt(this.max)||+this.max===+new Date(2099,11,31)||e){c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.setProperties(mpt(i,c,{}),!e)}break;case"startDate":if(xpt(this.startDate)){c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.startValue=c,this.setValue()}break;case"endDate":if(xpt(this.endDate)){c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.endValue=c,this.setValue()}break;case"minDays":xpt(this.minDays)&&this.setProperties(mpt(i,parseInt(this.inputElement.getAttribute(i),10),{}),!0);break;case"maxDays":xpt(this.maxDays)&&this.setProperties(mpt(i,parseInt(this.inputElement.getAttribute(i),10),{}),!0);break;case"type":"text"!==this.inputElement.getAttribute(i)&&this.inputElement.setAttribute("type","text")}}},t.prototype.createPopup=function(){for(var e=0;e<this.presetsItem.length;e++)e!==this.presetsItem.length-1&&"custom_range"===this.presetsItem[e].id&&this.presetsItem.splice(e,1);this.activeIndex=this.presetsItem.length-1,this.isCustomRange=!0;for(e=0;e<=this.presetsItem.length-2;e++){var t=this.presetsItem[e].start,n=this.presetsItem[e].end;this.startValue&&this.endValue&&+new Date(t.setHours(0,0,0,0))===+new Date(this.startValue.setHours(0,0,0,0))&&+new Date(n.setHours(0,0,0,0))===+new Date(this.endValue.setHours(0,0,0,0))&&(this.activeIndex=e,this.isCustomRange=!1)}this.popupWrapper=bft("div",{id:this.element.id+"_popup",className:Zwt+" "+Awt}),this.adjustLongHeaderWidth();var a=!this.isCustomRange||this.isMobile;!Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)&&a?(this.isCustomWindow=!1,this.createPresets(),this.listRippleEffect(),this.renderPopup()):(this.isCustomWindow=!0,this.renderControl())},t.prototype.renderControl=function(){this.createControl(),this.bindCalendarEvents(),this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar]),xpt(this.endValue)||xpt(this.startValue)||this.disabledDateRender(),this.updateHeader()},t.prototype.clearCalendarEvents=function(){wft.clearEvents(this.leftCalPrevIcon),wft.clearEvents(this.leftCalNextIcon),wft.clearEvents(this.rightCalPrevIcon),wft.clearEvents(this.rightCalNextIcon)},t.prototype.updateNavIcons=function(){e.prototype.iconHandler.call(this)},t.prototype.calendarIconEvent=function(){this.clearCalendarEvents(),this.leftCalPrevIcon&&!this.leftCalPrevIcon.classList.contains(Bwt)&&wft.add(this.leftCalPrevIcon,"mousedown",this.navPrevFunction),this.leftCalNextIcon&&!this.leftCalNextIcon.classList.contains(Bwt)&&wft.add(this.leftCalNextIcon,"mousedown",this.navNextFunction),this.rightCalPrevIcon&&!this.rightCalPrevIcon.classList.contains(Bwt)&&wft.add(this.rightCalPrevIcon,"mousedown",this.navPrevFunction),this.rightCalNextIcon&&!this.rightCalNextIcon.classList.contains(Bwt)&&wft.add(this.rightCalNextIcon,"mousedown",this.navNextFunction)},t.prototype.bindCalendarEvents=function(){this.isMobile?(this.deviceCalendarEvent(),wft.add(this.startButton.element,"click",this.deviceHeaderClick,this),wft.add(this.endButton.element,"click",this.deviceHeaderClick,this)):(this.updateNavIcons(),this.calendarIconEvent(),this.calendarIconRipple(),this.headerTitleElement=this.popupObj.element.querySelector("."+Cwt+" ."+Ywt+" ."+qwt),this.headerTitleElement=this.popupObj.element.querySelector("."+_wt+" ."+Ywt+" ."+qwt),this.defaultKeyConfigs=bpt(this.defaultKeyConfigs,this.keyConfigs),this.leftKeyboardModule=new Vmt(this.leftCalendar,{eventName:"keydown",keyAction:this.keyInputHandler.bind(this),keyConfigs:this.defaultKeyConfigs}),this.rightKeyboardModule=new Vmt(this.rightCalendar,{eventName:"keydown",keyAction:this.keyInputHandler.bind(this),keyConfigs:this.defaultKeyConfigs})),this.start===this.depth&&this.bindCalendarCellEvents(),this.removeFocusedDate()},t.prototype.calendarIconRipple=function(){omt(this.leftCalPrevIcon,{selector:".e-prev",duration:400,isCenterRipple:!0}),omt(this.leftCalNextIcon,{selector:".e-next",duration:400,isCenterRipple:!0}),omt(this.rightCalPrevIcon,{selector:".e-prev",duration:400,isCenterRipple:!0}),omt(this.rightCalNextIcon,{selector:".e-next",duration:400,isCenterRipple:!0})},t.prototype.deviceCalendarEvent=function(){wft.clearEvents(this.nextIcon),wft.clearEvents(this.previousIcon),omt(this.nextIcon,{selector:".e-prev",duration:400,isCenterRipple:!0}),omt(this.previousIcon,{selector:".e-next",duration:400,isCenterRipple:!0}),this.nextIcon&&!this.nextIcon.classList.contains(Bwt)&&wft.add(this.nextIcon,"mousedown",this.deviceNavNextFunction),this.previousIcon&&!this.previousIcon.classList.contains(Bwt)&&wft.add(this.previousIcon,"mousedown",this.deviceNavPrevFunction)},t.prototype.deviceNavNext=function(e){var t=Oft(e.target,"."+Wwt);this.updateDeviceCalendar(t),this.navigateNext(e),this.deviceNavigation()},t.prototype.deviceNavPrevious=function(e){var t=Oft(e.target,"."+Wwt);this.updateDeviceCalendar(t),this.navigatePrevious(e),this.deviceNavigation()},t.prototype.updateDeviceCalendar=function(e){e&&(this.previousIcon=e.querySelector("."+Fwt),this.nextIcon=e.querySelector("."+Rwt),this.calendarElement=e,this.deviceCalendar=e,this.contentElement=e.querySelector("."+Jwt),this.tableBodyElement=Ift("."+Jwt+" tbody",e),this.table=e.querySelector("."+Jwt).getElementsByTagName("table")[0],this.headerTitleElement=e.querySelector("."+Ywt+" ."+qwt),this.headerElement=e.querySelector("."+Ywt))},t.prototype.deviceHeaderClick=function(e){if(e.currentTarget.classList.contains(Owt)&&!xpt(this.startValue)){this.endButton.element.classList.remove(Iwt),this.startButton.element.classList.add(Iwt);var t=this.popupObj.element.querySelector("."+Wwt);this.updateDeviceCalendar(t),xpt(this.calendarElement.querySelector("."+Dwt+":not(.e-other-month)"))&&(this.currentDate=new Date(+this.startValue),Zft(this.tableBodyElement),this.createContentBody(),this.deviceNavigation()),this.removeClassDisabled()}else if(!xpt(this.startValue)&&!xpt(this.endValue)){this.startButton.element.classList.remove(Iwt),this.endButton.element.classList.add(Iwt);t=this.popupObj.element.querySelector("."+Wwt);this.updateDeviceCalendar(t),xpt(this.calendarElement.querySelector("."+Nwt+":not(.e-other-month)"))&&(this.currentDate=new Date(+this.endValue),Zft(this.tableBodyElement),this.createContentBody(),this.deviceNavigation()),this.updateMinMaxDays(this.popupObj.element.querySelector("."+Wwt)),this.selectableDates()}},t.prototype.inputFocusHandler=function(){if(this.enabled){this.preventBlur=!1;var e={model:this};this.preventFocus||this.trigger("focus",e),this.updateClearIconState(),this.updateHiddenInput(),this.openOnFocus&&!this.preventFocus?(this.preventFocus=!0,this.show()):this.preventFocus=!0}},t.prototype.inputBlurHandler=function(e){if(this.enabled){if(!this.preventBlur){var t=this.inputElement.value;if(xpt(this.presetsItem)||this.presetsItem.length>0&&this.previousEleValue!==this.inputElement.value&&(this.activeIndex=this.presetsItem.length-1,this.isCustomRange=!0),!xpt(t)&&""!==t.trim()){var n=t.split(" "+this.separator+" ");if(n.length>1){this.invalidValueString=null;var a={format:this.formatString,type:"date",skeleton:"yMd"},r=this.globalize.parseDate(n[0].trim(),a),i=this.globalize.parseDate(n[1].trim(),a);if(!(xpt(r)||isNaN(+r)||xpt(i)||isNaN(+i))){var o=this.startValue;this.startValue=r;var l=this.endValue;if(this.endValue=i,this.setValue(),this.refreshControl(),t!==this.previousEleValue&&this.changeTrigger(e),!this.preventBlur&&document.activeElement!==this.inputElement){this.preventFocus=!1;var s={model:this};this.trigger("blur",s)}return this.updateHiddenInput(),void(this.isMobile&&this.isPopupOpen()&&(this.startValue=o,this.endValue=l))}this.strictMode||(this.startValue=null,this.endValue=null,this.setValue())}else this.strictMode||(this.startValue=null,this.endValue=null,this.setValue())}if(this.strictMode?(xpt(t)||""!==t.trim()||(this.startValue=null,this.endValue=null),Vgt.setValue("",this.inputElement,this.floatLabelType,this.showClearButton),this.updateInput()):(xpt(this.popupObj)&&(this.currentDate=null),this.previousStartValue=this.previousEndValue=null,this.startValue=null,this.endValue=null,this.setValue()),this.errorClass(),this.changeTrigger(e),!this.preventBlur&&document.activeElement!==this.inputElement){this.preventFocus=!1;s={model:this};this.trigger("blur",s)}}this.updateHiddenInput()}},t.prototype.clearRange=function(){this.previousStartValue=this.previousEndValue=null,this.currentDate=null},t.prototype.errorClass=function(){var e=this.inputElement.value.trim();(xpt(this.endValue)&&xpt(this.startValue)&&""!==e||!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue||!xpt(this.endValue)&&+this.endValue>+this.max||this.startValue&&this.isDateDisabled(this.startValue)||this.endValue&&this.isDateDisabled(this.endValue))&&""!==e?(xft([this.inputWrapper.container],Hwt),Hft(this.inputElement,{"aria-invalid":"true"})):this.inputWrapper&&(Eft([this.inputWrapper.container],Hwt),Hft(this.inputElement,{"aria-invalid":"false"}))},t.prototype.keyCalendarUpdate=function(e,t,n){return void 0===n&&(n=!0),n&&this.removeFocusedDate(),e?(this.leftCalCurrentDate=new Date(+this.currentDate),t=this.leftCalendar):(this.rightCalCurrentDate=new Date(+this.currentDate),t=this.rightCalendar),this.updateCalendarElement(t),this.table.focus(),t},t.prototype.navInCalendar=function(e,t,n,a,r){var i,o,l=this.getViewNumber(this.currentView()),s=this.min;switch(o=xpt(this.maxDays)||!this.isMaxDaysClicked||xpt(this.startValue)?this.max:new Date(new Date(+this.startValue).setDate(this.startValue.getDate()+(this.maxDays-1))),e.action){case"moveRight":i=new Date(+this.currentDate),this.addDay(i,1,e,o,s),t&&+i===+a&&(r=this.keyCalendarUpdate(!1,r)),this.keyboardNavigate(1,l,e,o,s),this.keyNavigation(r,e);break;case"moveLeft":i=new Date(+this.currentDate),this.addDay(i,-1,e,o,s),t||+i===+n&&(r=this.keyCalendarUpdate(!0,r)),this.keyboardNavigate(-1,l,e,o,s),this.keyNavigation(r,e);break;case"moveUp":0===l?(i=new Date(+this.currentDate),this.addDay(i,-7,e,o,s),+i<=+n&&!t&&(r=this.keyCalendarUpdate(!0,r)),this.keyboardNavigate(-7,l,e,o,s)):this.keyboardNavigate(-4,l,e,this.max,this.min),this.keyNavigation(r,e);break;case"moveDown":0===l?(i=new Date(+this.currentDate),this.addDay(i,7,e,o,s),t&&+i>=+a&&(r=this.keyCalendarUpdate(!1,r)),this.keyboardNavigate(7,l,e,o,s)):this.keyboardNavigate(4,l,e,this.max,this.min),this.keyNavigation(r,e);break;case"home":this.currentDate=this.firstDay(this.currentDate),Zft(this.tableBodyElement),0===l?this.renderMonths(e):1===l?this.renderYears(e):this.renderDecades(e),this.keyNavigation(r,e);break;case"end":this.currentDate=this.lastDay(this.currentDate,l),Zft(this.tableBodyElement),0===l?this.renderMonths(e):1===l?this.renderYears(e):this.renderDecades(e),this.keyNavigation(r,e);break;case"tab":if(this.tabKeyValidation(r,_wt))xpt((r=this.keyCalendarUpdate(!1,r,!1)).querySelector(".e-focused-date"))&&(this.currentDate=this.firstCellToFocus(this.rightCalendar)),this.keyboardNavigate(0,l,e,o,s),this.keyNavigation(r,e);break;case"shiftTab":if(this.tabKeyValidation(r,Cwt))xpt((r=this.keyCalendarUpdate(!0,r,!1)).querySelector(".e-focused-date"))&&(this.currentDate=this.firstCellToFocus(this.leftCalendar)),this.keyboardNavigate(0,l,e,o,s),this.keyNavigation(r,e)}},t.prototype.firstCellToFocus=function(e){var t=e.children[1].firstElementChild.querySelector("td.e-cell:not(.e-week-number):not(.e-disabled):not(.e-other-month)"),n=t&&t.id?t.id.split("_")[0]:null,a=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth(),1);return n?new Date(+n):a},t.prototype.keyInputHandler=function(t,n){var a,r=this.getViewNumber(this.currentView()),i=new Date(this.rightCalCurrentDate.getFullYear(),this.rightCalCurrentDate.getMonth(),1),o=new Date(this.leftCalCurrentDate.getFullYear(),this.leftCalCurrentDate.getMonth()+1,0),l=Oft(t.target,"."+Cwt),s=(l=xpt(l)?this.leftCalendar:l).classList.contains(_wt);this.updateCalendarElement(l);var c=this.tableBodyElement.querySelector("tr td.e-selected"),d=l.querySelector("tr td."+Xwt),h=l.querySelector("tr td."+Dwt),u=l.querySelector("tr td."+Nwt),p=this.getViewNumber(this.depth),f=r===p&&this.getViewNumber(this.start)>=p,m=Oft(t.target,"."+_wt),v=Oft(t.target,"."+Cwt),g=Oft(t.target,"."+Kwt);switch(xpt(d)?xpt(u)||this.dateDisabled?xpt(h)||this.dateDisabled?this.dateDisabled||this.currentDate.setDate(1):this.currentDate=new Date(+this.startValue):this.currentDate=new Date(+this.endValue):this.currentDate=this.currentDate,this.effect="",t.action){case"altUpArrow":this.isPopupOpen()&&(this.hide(t),this.preventFocus=!0,this.inputElement.focus(),xft([this.inputWrapper.container],[Lwt]));break;case"select":if(f){var w=xpt(d)?h:d;xpt(w)||w.classList.contains(Bwt)||this.selectRange(null,w)}else(xpt(c)||f)&&xpt(d)||(xpt(this.value)||(n=this.calendarElement.classList.contains(_wt)?this.startDate:this.endDate),this.controlDown=t,this.contentClick(null,--r,d||c,n));t.preventDefault();break;case"controlHome":var y=new Date(this.currentDate.getFullYear(),0,1);!s&&+y<+o&&(l=this.keyCalendarUpdate(!0,l)),e.prototype.navigateTo.call(this,"Month",new Date(this.currentDate.getFullYear(),0,1)),this.keyNavigation(l,t);break;case"altRightArrow":xpt(m)?xpt(v)?xpt(g)||this.cancelButton.element.focus():xpt(this.presetElement)?this.cancelButton.element.focus():(this.presetElement.focus(),this.removeFocusedDate()):this.rightCalendar.children[1].firstElementChild.focus(),t.preventDefault();break;case"altLeftArrow":xpt(m)?xpt(v)||this.leftCalendar.children[1].firstElementChild.focus():!0!==this.applyButton.element.disabled?this.applyButton.element.focus():this.cancelButton.element.focus(),t.preventDefault();break;case"controlUp":this.calendarElement.classList.contains(_wt),this.calendarNavigation(t,this.calendarElement),t.preventDefault();break;case"controlDown":xpt(c)&&xpt(d)||f||(xpt(this.value)||(n=this.calendarElement.classList.contains(_wt)?this.startDate:this.endDate),this.controlDown=t,this.contentClick(null,--r,c||d,n)),t.preventDefault();break;case"controlEnd":y=new Date(this.currentDate.getFullYear(),11,31);s&&+y>+i&&(l=this.keyCalendarUpdate(!1,l)),e.prototype.navigateTo.call(this,"Month",new Date(this.currentDate.getFullYear(),11,31)),this.keyNavigation(l,t);break;case"pageUp":a=new Date(+this.currentDate),this.addMonths(a,-1),!s&&+a<=+o&&(l=this.keyCalendarUpdate(!0,l)),this.addMonths(this.currentDate,-1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"pageDown":a=new Date(+this.currentDate),this.addMonths(a,1),s&&+a>=+i&&(l=this.keyCalendarUpdate(!1,l)),this.addMonths(this.currentDate,1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"shiftPageUp":a=new Date(+this.currentDate),this.addYears(a,-1),!s&&+a<=+o&&(l=this.keyCalendarUpdate(!0,l)),this.addYears(this.currentDate,-1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"shiftPageDown":a=new Date(+this.currentDate),this.addYears(a,1),s&&+a>=+i&&(l=this.keyCalendarUpdate(!1,l)),this.addYears(this.currentDate,1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"shiftTab":xpt(this.presetElement)||(this.presetElement.setAttribute("tabindex","0"),this.presetElement.focus(),this.removeFocusedDate()),s&&t.preventDefault(),this.tabKeyValidation(l,Cwt)&&(this.currentDate=new Date(+this.leftCalCurrentDate),this.navInCalendar(t,s,o,i,l));break;case"spacebar":this.applyButton&&!this.applyButton.disabled&&this.applyFunction(t);break;case"tab":this.tabKeyValidation(l,_wt)&&(this.currentDate=new Date(+this.rightCalCurrentDate),this.navInCalendar(t,s,o,i,l));break;default:this.navInCalendar(t,s,o,i,l),this.checkMinMaxDays()}this.presetHeight()},t.prototype.tabKeyValidation=function(e,t){var n=e.classList.contains(t),a=this.rightCalendar.querySelector(".e-header"),r=this.leftCalendar.querySelector(".e-header"),i=!!a&&a.classList.contains("e-month"),o=!!r&&r.classList.contains("e-month");return n&&o&&i&&!this.isMobile},t.prototype.keyNavigation=function(e,t){this.bindCalendarCellEvents(e),e.classList.contains(_wt)?this.leftCalCurrentDate=new Date(+this.currentDate):this.rightCalCurrentDate=new Date(+this.currentDate),this.updateNavIcons(),this.calendarIconEvent(),this.updateRange([e]),this.dateDisabled=this.isDateDisabled(this.currentDate),t.preventDefault()},t.prototype.inputHandler=function(e){switch(e.action){case"altDownArrow":this.isPopupOpen()||(""===this.inputElement.value&&(this.clear(),this.changeTrigger(e),this.clearRange()),this.show(null,e),this.isRangeIconClicked=!1,this.isMobile||xpt(this.leftCalendar)||this.calendarFocus(),this.isKeyPopup=!0);break;case"escape":this.isPopupOpen()&&this.hide(e);break;case"enter":document.activeElement===this.inputElement&&(this.inputBlurHandler(e),this.hide(e));break;case"tab":document.activeElement===this.inputElement&&this.isPopupOpen()&&(this.hide(e),e.preventDefault())}},t.prototype.bindCalendarCellEvents=function(e){for(var t=0,n=e?e.querySelectorAll("."+Wwt+" td"):this.popupObj.element.querySelectorAll("."+Wwt+" td");t<n.length;t++){var a=n[t];wft.clearEvents(a),a.classList.contains(Bwt)||a.classList.contains(tyt)||a.classList.contains(eyt)||(this.isMobile||wft.add(a,"mouseover",this.hoverSelection,this),wft.add(a,"mousedown",this.selectRange,this))}},t.prototype.removeFocusedDate=function(){for(var e=!xpt(this.startValue)||!xpt(this.endValue),t=0,n=this.popupObj.element.querySelectorAll("."+Wwt+" ."+Xwt);t<n.length;t++){var a=n[t],r=new Date,i=this.getIdValue(null,a);("Month"===this.depth&&"Month"===this.currentView()&&(!a.classList.contains(Qwt)||a.classList.contains(Qwt)&&e)||"Year"===this.depth&&"Year"===this.currentView()&&(!this.isSameMonth(r,i)&&!this.isSameYear(r,i)||e)||"Decade"===this.depth&&"Decade"===this.currentView()&&(!this.isSameYear(r,i)||e))&&(a.classList.remove(Xwt),a.classList.contains(Dwt)||a.classList.contains(Nwt)||a.removeAttribute("aria-label"))}},t.prototype.hoverSelection=function(e,t){var n=t||e.currentTarget,a=this.getIdValue(null,n);if(!xpt(this.startValue)&&+this.startValue>=+this.min&&+this.startValue<=+this.max&&(!this.isDateDisabled(this.endValue)&&!this.isDateDisabled(this.startValue)&&xpt(this.endValue)&&xpt(this.startValue)||!xpt(this.startValue)&&xpt(this.endValue)))for(var r=0,i=this.popupObj.element.querySelectorAll("."+Wwt+" td");r<i.length;r++){var o=i[r],l=!o.classList.contains(Bwt)||o.classList.contains(tyt);if(!o.classList.contains(eyt)&&l){var s=this.getIdValue(null,o),c=new Date(+this.startValue);new Date(+s).setHours(0,0,0,0)>=c.setHours(0,0,0,0)&&+s<=+a?xft([o],Vwt):Eft([o],[Vwt])}}},t.prototype.isSameStartEnd=function(e,t){var n=!1;return"Month"===this.depth?e.setHours(0,0,0,0)===t.setHours(0,0,0,0)&&(n=!0):"Year"===this.depth?e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&(n=!0):"Decade"===this.depth&&e.getFullYear()===t.getFullYear()&&(n=!0),n},t.prototype.updateRange=function(e){if(!xpt(this.startValue))for(var t=0,n=e;t<n.length;t++)for(var a=0,r=n[t].querySelectorAll("."+Wwt+" td");a<r.length;a++){var i=r[a];if(!i.classList.contains(eyt)&&!i.classList.contains(Bwt)){var o=this.getIdValue(null,i),l=this.getIdValue(null,i);if(xpt(this.endValue)?Eft([i],[Vwt]):this.currentView()===this.depth&&+l.setHours(0,0,0,0)>=+new Date(+this.startValue).setHours(0,0,0,0)&&+l.setHours(0,0,0,0)<=+new Date(+this.endValue).setHours(0,0,0,0)&&!this.isSameStartEnd(new Date(+this.startValue),new Date(+this.endValue))&&+new Date(+this.startValue).setHours(0,0,0,0)>=+this.min&&+new Date(+this.endValue).setHours(0,0,0,0)<=+this.max&&!this.isDateDisabled(this.startValue)&&!this.isDateDisabled(this.endValue)&&xft([i],Vwt),i.classList.contains(jwt)&&i.classList.contains(Nwt)&&+l!==+this.endValue&&(Eft([i],[jwt]),Eft([i],[Nwt])),i.classList.contains(Vwt)&&+l>+this.endValue&&Eft([i],[Vwt]),!i.classList.contains(zwt)){var s=new Date(+this.startValue),c=new Date(+o);this.currentView()===this.depth&&+c.setHours(0,0,0,0)===+s.setHours(0,0,0,0)&&+c.setHours(0,0,0,0)>=+s.setHours(0,0,0,0)&&+this.startValue>=+this.min&&!this.inputWrapper.container.classList.contains("e-error")&&!this.isDateDisabled(this.startValue)&&!this.isDateDisabled(this.endValue)&&(xft([i],[Dwt,jwt]),this.addSelectedAttributes(i,this.startValue,!0));var d=new Date(+this.endValue);"Year"===this.currentView()?c=new Date(c.getFullYear(),c.getMonth()+1,0):"Decade"===this.currentView()&&(c=new Date(c.getFullYear(),11,31)),this.currentView()===this.depth&&!xpt(this.endValue)&&+c.setHours(0,0,0,0)===+d.setHours(0,0,0,0)&&+c.setHours(0,0,0,0)<=+d.setHours(0,0,0,0)&&+this.startValue>=+this.min&&!this.inputWrapper.container.classList.contains("e-error")&&!this.isDateDisabled(this.startValue)&&!this.isDateDisabled(this.endValue)&&(xft([i],[Nwt,jwt]),this.addSelectedAttributes(i,this.startValue,!1)),+o!==+this.startValue||xpt(this.endValue)||+o!==+this.endValue||this.addSelectedAttributes(i,this.endValue,!1,!0)}}}},t.prototype.checkMinMaxDays=function(){(!xpt(this.minDays)&&this.minDays>0||!xpt(this.maxDays)&&this.maxDays>0)&&(this.isMobile?this.updateMinMaxDays(this.popupObj.element.querySelector("."+Wwt)):(this.updateMinMaxDays(this.popupObj.element.querySelector("."+_wt)),this.updateMinMaxDays(this.popupObj.element.querySelector("."+Cwt))))},t.prototype.rangeArgs=function(e){var t,n,a=xpt(this.startValue)?null:this.globalize.formatDate(this.startValue,{format:this.formatString,type:"date",skeleton:"yMd"}),r=xpt(this.endValue)?null:this.globalize.formatDate(this.endValue,{format:this.formatString,type:"date",skeleton:"yMd"});return xpt(this.endValue)||xpt(this.startValue)?(t="",n=0):(t=a+" "+this.separator+" "+r,n=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1),{value:this.value,startDate:this.startValue,endDate:this.endValue,daySpan:n,event:e||null,element:this.element,isInteracted:!xpt(e),text:t}},t.prototype.otherMonthSelect=function(e,t,n){var a=+this.getIdValue(null,e),r='*[id^="/id"]:not(.e-other-month)'.replace("/id",""+a),i=this.popupObj&&this.popupObj.element.querySelector(r);xpt(i)||(t?(xft([i],[Dwt,jwt]),this.addSelectedAttributes(i,this.startValue,!0)):(xft([i],[Nwt,jwt]),this.addSelectedAttributes(i,this.endValue,!0)),n&&this.addSelectedAttributes(e,this.endValue,!1,!0))},t.prototype.selectRange=function(e,t){var n,a;e&&e.preventDefault();var r=xpt(e)?this.getIdValue(null,t):this.getIdValue(e,null),i=r.getFullYear(),o=r.getMonth(),l=new Date(i,o,1),s=new Date(i,o+1,0),c=new Date(i,0,1),d=new Date(i,11,31);xpt(this.endValue)||xpt(this.startValue)?this.isMobile&&this.startButton.element.classList.contains(Iwt)&&this.removeSelection():(!this.isMobile||this.isMobile&&!this.endButton.element.classList.contains(Iwt))&&this.removeSelection();var h=t||e.currentTarget;if(xpt(this.startValue))xpt(this.previousStartValue)||(r.setHours(this.previousStartValue.getHours()),r.setMinutes(this.previousStartValue.getMinutes()),r.setSeconds(this.previousStartValue.getSeconds())),this.startValue="Month"===this.depth?new Date(this.checkValue(r)):"Year"===this.depth?l:c,this.endValue=null,this.setValue(),xft([h],Dwt),this.addSelectedAttributes(h,this.startValue,!0),h.classList.contains(zwt)&&this.otherMonthSelect(h,!0),this.checkMinMaxDays(),this.applyButton.disabled=!0,this.applyButton.element.disabled=!0,this.isMobile&&(this.endButton.element.classList.add(Iwt),this.startButton.element.classList.remove(Iwt),this.endButton.element.removeAttribute("disabled"),this.selectableDates()),this.trigger("select",this.rangeArgs(e));else if(+r===+this.startValue||+r>+this.startValue){if(+r===+this.startValue&&!xpt(this.minDays)&&this.minDays>1)return;this.endValue=null,this.setValue(),(this.isMobile||t)&&this.hoverSelection(e,t),xpt(this.previousEndValue)||(r.setHours(this.previousEndValue.getHours()),r.setMinutes(this.previousEndValue.getMinutes()),r.setSeconds(this.previousEndValue.getSeconds())),this.endValue="Month"===this.depth?new Date(this.checkValue(r)):"Year"===this.depth?s:d,this.setValue();var u=this.popupObj.element.querySelectorAll("."+Nwt);if(this.isMobile){this.startButton.element.classList.remove(Iwt),this.endButton.element.classList.add(Iwt);for(var p=0,f=u;p<f.length;p++){var m=f[p];m.removeAttribute("aria-label"),m.classList.contains(Dwt)?(this.addSelectedAttributes(m,this.startValue,!0),Eft([m],[Nwt])):(m.setAttribute("aria-selected","false"),Eft([m],[Nwt,jwt]))}}xft([h],Nwt),+this.endValue===+this.startValue?this.addSelectedAttributes(h,this.endValue,!1,!0):this.addSelectedAttributes(h,this.endValue,!1),h.classList.contains(zwt)&&(+this.endValue===+this.startValue?this.otherMonthSelect(h,!1,!0):this.otherMonthSelect(h,!1));for(var v=0,g=u=this.popupObj.element.querySelectorAll("."+Nwt);v<g.length;v++){var w=g[v];w.classList.contains(Dwt)&&Eft([w],[Vwt])}this.applyButton.disabled=!1,this.applyButton.element.disabled=!1,this.isMobile||this.removeClassDisabled(),this.disabledDateRender(),this.trigger("select",this.rangeArgs(e))}else+r<+this.startValue&&(this.removeClassDisabled(),this.startValue="Month"===this.depth?new Date(this.checkValue(r)):"Year"===this.depth?l:c,this.setValue(),this.removeSelectedAttributes(),Eft(this.popupObj.element.querySelectorAll("."+Dwt),[Dwt,jwt]),xft([h],Dwt),this.addSelectedAttributes(h,this.startValue,!0),h.classList.contains(zwt)&&this.otherMonthSelect(h,!0),this.checkMinMaxDays());e&&(n=Oft(e.target,"."+_wt)),xpt(n)?(e&&(a=e&&Oft(e.target,"."+Cwt)),xpt(a)||this.rightCalendar.children[1].firstElementChild.focus()):this.leftCalendar.children[1].firstElementChild.focus(),xft([h],jwt),this.updateHeader(),this.removeFocusedDate()},t.prototype.selectableDates=function(){if(!xpt(this.startValue)){var e=this.calendarElement.querySelectorAll("."+Wwt+" td"),t=!1;if(this.currentView()===this.depth){for(var n=0,a=e;n<a.length;n++){if(!(o=a[n]).classList.contains(Dwt)&&!o.classList.contains(eyt)&&!o.classList.contains(Bwt)){if(+this.getIdValue(null,o)<+this.startValue){xft([o],[tyt,Bwt,ryt]),wft.clearEvents(o);continue}break}if(o.classList.contains(Dwt)&&!o.classList.contains(zwt)){t=!0;break}}t&&(this.previousIcon.classList.contains(Bwt)||xft([this.previousIcon],[nyt,Bwt,ryt]))}else{for(var r=0,i=e;r<i.length;r++){var o=i[r],l=this.startValue.getMonth(),s=this.startValue.getFullYear(),c=this.getIdValue(null,o);if(this.startButton.element.classList.contains(Iwt)||!("Year"===this.currentView()&&c.getMonth()<l&&c.getFullYear()<=s||"Decade"===this.currentView()&&c.getMonth()<=l&&c.getFullYear()<s))break;xft([o],[Bwt])}e[0].classList.contains(Bwt)?this.previousIconHandler(!0):e[e.length-1].classList.contains(Bwt)&&this.nextIconHandler(!0)}}},t.prototype.updateMinMaxDays=function(e){if(!xpt(this.startValue)&&xpt(this.endValue)||this.isMobile&&this.endButton.element.classList.contains(Iwt)){if(!xpt(this.minDays)&&this.minDays>0||!xpt(this.maxDays)&&this.maxDays>0){var t=this.removeTimeValueFromDate(this.startValue),n=new Date(new Date(+t).setDate(t.getDate()+(this.minDays-1))),a=new Date(new Date(+t).setDate(t.getDate()+(this.maxDays-1)));n=!xpt(this.minDays)&&this.minDays>0?n:null,a=!xpt(this.maxDays)&&this.maxDays>0?a:null,"Year"===this.currentView()?(n=xpt(n)?null:new Date(n.getFullYear(),n.getMonth(),0),a=xpt(a)?null:new Date(a.getFullYear(),a.getMonth(),1)):"Decade"===this.currentView()&&(n=xpt(n)?null:new Date(n.getFullYear()-1,11,1),a=xpt(a)?null:new Date(a.getFullYear(),0,1));for(var r=void 0,i=0,o=e.querySelectorAll("."+Wwt+" td");i<o.length;i++){var l=o[i];if(!l.classList.contains(Dwt)&&!l.classList.contains(eyt)){var s=this.getIdValue(null,l);if(s=this.removeTimeValueFromDate(s),!xpt(n)&&+s===+n&&l.classList.contains(Bwt)&&n.setDate(n.getDate()+1),!l.classList.contains(Bwt)){if(+s<=+t)continue;!xpt(n)&&+s<+n&&(xft([l],[tyt,Bwt,ryt]),wft.clearEvents(l)),!xpt(a)&&+s>+a&&(xft([l],[tyt,Bwt,ryt]),this.isMaxDaysClicked=!0,wft.clearEvents(l),xpt(r)&&!l.classList.contains(zwt)&&(r=l))}}}if(!xpt(r))if(this.isMobile)this.nextIcon.classList.contains(Bwt)||xft([this.nextIcon],[nyt,Bwt,ryt]);else{var c=Oft(r,"."+Cwt);(c=xpt(c)?this.leftCalendar:c).classList.contains(_wt)?(this.rightCalNextIcon.classList.contains(Bwt)||xft([this.rightCalNextIcon],[nyt,Bwt,ryt]),this.leftCalNextIcon.classList.contains(Bwt)||xft([this.leftCalNextIcon],[nyt,Bwt,ryt]),this.rightCalPrevIcon.classList.contains(Bwt)||xft([this.rightCalPrevIcon],[nyt,Bwt,ryt])):this.rightCalNextIcon.classList.contains(Bwt)||xft([this.rightCalNextIcon],[nyt,Bwt,ryt])}}}else this.isMaxDaysClicked=!1},t.prototype.removeTimeValueFromDate=function(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate())},t.prototype.removeClassDisabled=function(){for(var e=0,t=this.popupObj.element.querySelectorAll("."+Wwt+" td."+tyt);e<t.length;e++){var n=t[e];n.classList.contains(tyt)&&(Eft([n],[tyt,Bwt,ryt]),wft.add(n,"click",this.selectRange,this),this.isMobile||wft.add(n,"mouseover",this.hoverSelection,this))}this.isMobile?(this.nextIcon.classList.contains(nyt)&&Eft([this.nextIcon],[nyt,Bwt,ryt]),this.previousIcon.classList.contains(nyt)&&Eft([this.previousIcon],[nyt,Bwt,ryt])):(this.rightCalNextIcon.classList.contains(nyt)&&Eft([this.rightCalNextIcon],[nyt,Bwt,ryt]),this.rightCalPrevIcon.classList.contains(nyt)&&Eft([this.rightCalPrevIcon],[nyt,Bwt,ryt]),this.leftCalNextIcon.classList.contains(nyt)&&Eft([this.leftCalNextIcon],[nyt,Bwt,ryt]))},t.prototype.updateHeader=function(){var e={type:"date",skeleton:"yMMMd"};if(xpt(this.endValue)||xpt(this.startValue))this.popupObj.element.querySelector("."+$wt).textContent=this.l10n.getConstant("selectedDays");else{var t=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1;xpt(this.disabledDayCnt)||(t-=this.disabledDayCnt,this.disabledDayCnt=null),this.popupObj.element.querySelector("."+$wt).textContent=t.toString()+" "+this.l10n.getConstant("days")}this.isMobile?(xpt(this.startValue)?this.startButton.element.textContent=this.l10n.getConstant("startLabel"):this.startButton.element.textContent=this.globalize.formatDate(this.startValue,e),xpt(this.endValue)||xpt(this.startValue)?this.endButton.element.textContent=this.l10n.getConstant("endLabel"):this.endButton.element.textContent=this.globalize.formatDate(this.endValue,e)):(xpt(this.endValue)||xpt(this.startValue)?this.popupObj.element.querySelector("."+Twt).textContent=this.l10n.getConstant("endLabel"):this.popupObj.element.querySelector("."+Twt).textContent=this.globalize.formatDate(this.endValue,e),xpt(this.startValue)?this.popupObj.element.querySelector("."+Pwt).textContent=this.l10n.getConstant("startLabel"):this.popupObj.element.querySelector("."+Pwt).textContent=this.globalize.formatDate(this.startValue,e)),(this.isDateDisabled(this.startValue)||this.isDateDisabled(this.endValue)||!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue)&&(this.isMobile?(this.startButton.element.textContent=this.l10n.getConstant("startLabel"),this.endButton.element.textContent=this.l10n.getConstant("endLabel"),this.popupObj.element.querySelector("."+$wt).textContent=this.l10n.getConstant("selectedDays")):(this.popupObj.element.querySelector("."+$wt).textContent=this.l10n.getConstant("selectedDays"),this.popupObj.element.querySelector("."+Pwt).textContent=this.l10n.getConstant("startLabel"),this.popupObj.element.querySelector("."+Twt).textContent=this.l10n.getConstant("endLabel"))),this.popupObj.element.querySelector("#custom_range")&&(this.popupObj.element.querySelector("#custom_range").textContent=""!==this.l10n.getConstant("customRange")?this.l10n.getConstant("customRange"):"Custom Range")},t.prototype.removeSelection=function(){this.startValue=null,this.endValue=null,this.setValue(),this.removeSelectedAttributes(),this.popupObj&&(this.popupObj.element.querySelectorAll("."+jwt).length>0&&Eft(this.popupObj.element.querySelectorAll("."+jwt),[Dwt,Nwt,jwt]),this.popupObj.element.querySelectorAll("."+Xwt).length>0&&Eft(this.popupObj.element.querySelectorAll("."+Xwt),Xwt),this.popupObj.element.querySelectorAll("."+Vwt).length>0&&Eft(this.popupObj.element.querySelectorAll("."+Vwt),[Vwt]))},t.prototype.addSelectedAttributes=function(e,t,n,a){if(e){var r=this.globalize.formatDate(t,{type:"date",skeleton:"full"});!xpt(a)&&a?e.setAttribute("aria-label","The current start and end date is "+r):e.setAttribute("aria-label","The current "+(n?"start":"end")+" date is "+r),e.setAttribute("aria-selected","true")}},t.prototype.removeSelectedAttributes=function(){if(this.popupObj){for(var e=0,t=this.popupObj.element.querySelectorAll("."+Dwt);e<t.length;e++){(r=t[e]).setAttribute("aria-selected","false"),r.removeAttribute("aria-label")}for(var n=0,a=this.popupObj.element.querySelectorAll("."+Nwt);n<a.length;n++){var r;(r=a[n]).setAttribute("aria-selected","false"),r.removeAttribute("aria-label")}}},t.prototype.updateCalendarElement=function(e){e.classList.contains(_wt)?(this.calendarElement=this.leftCalendar,this.currentDate=this.leftCalCurrentDate,this.previousIcon=this.leftCalPrevIcon,this.nextIcon=this.leftCalNextIcon):(this.calendarElement=this.rightCalendar,this.currentDate=this.rightCalCurrentDate,this.previousIcon=this.rightCalPrevIcon,this.nextIcon=this.rightCalNextIcon),this.contentElement=e.querySelector("."+Jwt),this.tableBodyElement=Ift("."+Jwt+" tbody",e),this.table=e.querySelector("."+Jwt).getElementsByTagName("table")[0],this.headerTitleElement=e.querySelector("."+Ywt+" ."+qwt),this.headerElement=e.querySelector("."+Ywt)},t.prototype.navPrevMonth=function(e){e.preventDefault();var t=Oft(e.target,"."+_wt);t=xpt(t)?Oft(e.target,"."+Cwt):t,this.updateCalendarElement(t),this.navigatePrevious(e),!xpt(this.startValue)&&xpt(this.endValue)&&this.updateMinMaxDays(t),this.updateControl(t)},t.prototype.deviceNavigation=function(e){this.deviceCalendarEvent(),this.updateRange([this.popupObj.element.querySelector("."+Wwt)]),this.endButton.element.classList.contains(Iwt)&&this.updateMinMaxDays(this.popupObj.element.querySelector("."+Wwt)),this.endButton.element.classList.contains(Iwt)&&this.selectableDates(),this.currentView()===this.depth&&this.bindCalendarCellEvents(),this.removeFocusedDate()},t.prototype.updateControl=function(e,t){void 0===t&&(t=null),e.classList.contains(Cwt)?this.rightCalCurrentDate=new Date(+(t||this.currentDate)):this.leftCalCurrentDate=new Date(+this.currentDate),this.calendarIconEvent(),("Month"===this.depth&&this.leftCalendar.querySelector(".e-content").classList.contains("e-month")&&this.rightCalendar.querySelector(".e-content").classList.contains("e-month")||"Year"===this.depth&&this.leftCalendar.querySelector(".e-content").classList.contains("e-year")&&this.rightCalendar.querySelector(".e-content").classList.contains("e-year")||"Decade"===this.depth&&this.leftCalendar.querySelector(".e-content").classList.contains("e-decade")&&this.rightCalendar.querySelector(".e-content").classList.contains("e-decade")||this.isMobile)&&this.bindCalendarCellEvents(),this.removeFocusedDate(),this.updateRange([e])},t.prototype.navNextMonth=function(e){e.preventDefault();var t=Oft(e.target,"."+_wt);t=xpt(t)?Oft(e.target,"."+Cwt):t,this.updateCalendarElement(t),this.navigateNext(e),!xpt(this.startValue)&&xpt(this.endValue)&&this.updateMinMaxDays(t),this.updateControl(t)},t.prototype.isPopupOpen=function(){return!(xpt(this.popupObj)||!this.popupObj.element.classList.contains(Awt))},t.prototype.createRangeHeader=function(){var e=this.createElement("div",{className:"e-start-end"});if(this.isMobile){var t=this.createElement("button",{className:"e-end-btn"}),n=this.createElement("button",{className:Owt});this.startButton=new jgt({content:this.l10n.getConstant("startLabel")},n),this.endButton=new jgt({content:this.l10n.getConstant("endLabel")},t),e.appendChild(n),e.appendChild(t)}else{var a=this.createElement("a",{className:Pwt}),r=this.createElement("a",{className:Twt}),i=this.createElement("span",{className:"e-change-icon e-icons"});Hft(a,{"aria-atomic":"true","aria-live":"assertive","aria-label":"Start Date",role:"button"}),Hft(r,{"aria-atomic":"true","aria-live":"assertive","aria-label":"End Date",role:"button"}),e.appendChild(a),e.appendChild(i),e.appendChild(r),a.textContent=this.l10n.getConstant("startLabel"),r.textContent=this.l10n.getConstant("endLabel")}return e},t.prototype.disableInput=function(){this.strictMode?xpt(this.previousStartValue)||xpt(this.previousEndValue)||(this.startValue=this.previousStartValue,this.endValue=this.previousEndValue,this.setValue(),this.updateInput()):(this.updateInput(),this.clearRange(),this.setProperties({startDate:null},!0),this.setProperties({endDate:null},!0),this.startValue=null,this.endValue=null,this.setValue(),this.errorClass()),this.setProperties({enabled:!1},!0),Vgt.setEnabled(this.enabled,this.inputElement),this.bindEvents()},t.prototype.validateMinMax=function(){this.min=xpt(this.min)||!+this.min?this.min=new Date(1900,0,1):this.min,this.max=xpt(this.max)||!+this.max?this.max=new Date(2099,11,31):this.max,this.min<=this.max?(xpt(this.minDays)||xpt(this.maxDays)||this.maxDays>0&&this.minDays>0&&this.minDays>this.maxDays&&(this.maxDays=null),!xpt(this.minDays)&&this.minDays<0&&(this.minDays=null),!xpt(this.maxDays)&&this.maxDays<0&&(this.maxDays=null)):this.disableInput()},t.prototype.validateRangeStrict=function(){xpt(this.startValue)||(+this.startValue<=+this.min?(this.startValue=this.min,this.setValue()):+this.startValue>=+this.min&&+this.startValue>=+this.max&&(this.startValue=this.max)),xpt(this.endValue)||(+this.endValue>+this.max?(this.endValue=this.max,this.setValue()):+this.endValue<+this.min&&(this.endValue=this.min,this.setValue())),this.validateMinMaxDays()},t.prototype.validateRange=function(){this.validateMinMaxDays()},t.prototype.validateMinMaxDays=function(){if(!xpt(this.startValue)&&!xpt(this.endValue)){var e=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1;if(!xpt(this.minDays)&&this.minDays>0&&!(e>=this.minDays))if(this.strictMode){var t=new Date(+this.startValue);t.setDate(t.getDate()+(this.minDays-1)),+t>+this.max?(this.endValue=this.max,this.setValue()):(this.endValue=t,this.setValue())}else this.startValue=null,this.endValue=null,this.setValue();xpt(this.maxDays)||!(this.maxDays>0)||e<=this.maxDays||(this.strictMode?(this.endValue=new Date(+this.startValue),this.endValue.setDate(this.endValue.getDate()+(this.maxDays-1)),this.setValue()):(this.startValue=null,this.endValue=null,this.setValue()))}},t.prototype.renderCalendar=function(){this.calendarElement=this.createElement("div"),this.calendarElement.classList.add(Wwt),this.enableRtl&&this.calendarElement.classList.add("e-rtl"),Hft(this.calendarElement,{role:"calendar"}),e.prototype.createHeader.call(this),e.prototype.createContent.call(this)},t.prototype.isSameMonth=function(e,t){return e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()},t.prototype.isSameYear=function(e,t){return e.getFullYear()===t.getFullYear()},t.prototype.isSameDecade=function(e,t){var n=e.getFullYear(),a=t.getFullYear();return n-n%10==a-a%10},t.prototype.startMonthCurrentDate=function(){this.isSameMonth(this.min,this.max)||+this.currentDate>+this.max||this.isSameMonth(this.currentDate,this.max)?(this.currentDate=new Date(+this.max),this.currentDate.setDate(1),this.currentDate.setMonth(this.currentDate.getMonth()-1)):this.currentDate<this.min&&(this.currentDate=new Date(this.checkValue(this.min)))},t.prototype.selectNextMonth=function(){if(xpt(this.endValue)||xpt(this.startValue)||this.isSameMonth(this.endValue,this.currentDate)||this.isDateDisabled(this.endValue)||this.isDateDisabled(this.startValue))return this.currentDate.setDate(1),void this.currentDate.setMonth(this.currentDate.getMonth()+1);if(this.currentDate=new Date(+this.endValue),!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue){this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.currentDate.setDate(1);var e=this.currentDate.getMonth()+1;this.currentDate.setMonth(e)}},t.prototype.selectNextYear=function(){if(xpt(this.endValue)||xpt(this.startValue)||this.isSameYear(this.endValue,this.currentDate)||this.isDateDisabled(this.endValue)||this.isDateDisabled(this.startValue)){this.currentDate.setMonth(0);var e=this.currentDate.getFullYear()+1;this.currentDate.setFullYear(e)}else this.currentDate=new Date(+this.endValue),(!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue||!xpt(this.startValue)&&+this.startValue<+this.min)&&(this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.currentDate.setMonth(0),this.currentDate.setFullYear(this.currentDate.getFullYear()+1))},t.prototype.selectNextDecade=function(){if(xpt(this.endValue)||xpt(this.startValue)||this.isSameDecade(this.endValue,this.currentDate)||this.isDateDisabled(this.endValue)||this.isDateDisabled(this.startValue)){var e=this.currentDate.getFullYear()+10;this.currentDate.setFullYear(e)}else this.currentDate=new Date(+this.endValue),(!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue||!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&+this.startValue<+this.min)&&(this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.currentDate.setFullYear(this.currentDate.getFullYear()+10))},t.prototype.selectStartMonth=function(){xpt(this.startValue)?(this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.startMonthCurrentDate()):!xpt(this.max)&&this.isSameMonth(this.startValue,this.max)?(this.currentDate=new Date(+this.max),this.currentDate.setDate(1),this.currentDate.setMonth(this.currentDate.getMonth()-1)):this.startValue>=this.min&&this.startValue<=this.max&&!this.isDateDisabled(this.startValue)?this.currentDate=new Date(+this.startValue):this.currentDate=new Date((new Date).setHours(0,0,0,0)),(!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue)&&(this.currentDate=new Date((new Date).setHours(0,0,0,0))),this.startMonthCurrentDate()},t.prototype.createCalendar=function(){var t=this.createElement("div",{className:"e-calendar-container"});if(this.isMobile){xpt(this.startValue)||(this.currentDate=new Date(+this.startValue)),e.prototype.validateDate.call(this),e.prototype.minMaxUpdate.call(this),e.prototype.render.call(this);var n=this.calendarElement.querySelector("."+Wwt+" ."+Fwt),a=this.calendarElement.querySelector("."+Wwt+" ."+Rwt);Zft(this.calendarElement.querySelector("."+Wwt+" ."+Uwt)),this.calendarElement.querySelector("."+Wwt+" ."+Ywt).appendChild(a),this.calendarElement.querySelector("."+Wwt+" ."+Ywt).appendChild(n),Sft([n],this.calendarElement.querySelector("."+Wwt+" ."+Ywt)),this.deviceCalendar=this.calendarElement,t.appendChild(this.calendarElement),this.headerTitleElement=this.calendarElement.querySelector("."+Wwt+" ."+Ywt+" ."+qwt)}else{this.selectStartMonth(),this.renderCalendar(),this.leftCalCurrentDate=new Date(+this.currentDate),this.calendarElement.classList.add(_wt),this.leftCalPrevIcon=this.calendarElement.querySelector("."+_wt+" ."+Fwt),this.leftCalNextIcon=this.calendarElement.querySelector("."+_wt+" ."+Rwt),this.leftTitle=this.calendarElement.querySelector("."+_wt+" ."+qwt),Zft(this.calendarElement.querySelector("."+_wt+" ."+Uwt)),this.calendarElement.querySelector("."+_wt+" ."+Ywt).appendChild(this.leftCalNextIcon),this.calendarElement.querySelector("."+_wt+" ."+Ywt).appendChild(this.leftCalPrevIcon),Sft([this.leftCalPrevIcon],this.calendarElement.querySelector("."+_wt+" ."+Ywt)),this.leftCalendar=this.calendarElement;var r=this.createElement("div",{className:"e-left-container"}),i=this.createElement("div",{className:"e-right-container"});r.appendChild(this.leftCalendar),t.appendChild(r),this.isMobile||wft.add(this.leftTitle,"click",this.leftNavTitle,this),"Month"===this.start&&this.selectNextMonth(),"Year"===this.start&&this.selectNextYear(),"Decade"===this.start&&this.selectNextDecade(),this.renderCalendar(),this.rightCalCurrentDate=new Date(+this.currentDate),xft([this.calendarElement],Cwt),this.rightCalendar=this.calendarElement,Eft([this.leftCalendar&&this.leftCalendar.querySelector(".e-content tbody")],"e-zoomin"),Eft([this.rightCalendar&&this.rightCalendar.querySelector(".e-content tbody")],"e-zoomin"),this.rightCalPrevIcon=this.calendarElement.querySelector("."+Cwt+" ."+Fwt),this.rightCalNextIcon=this.calendarElement.querySelector("."+Cwt+" ."+Rwt),this.rightTitle=this.calendarElement.querySelector("."+Cwt+" ."+qwt),Zft(this.calendarElement.querySelector("."+Cwt+" ."+Uwt)),this.calendarElement.querySelector("table").setAttribute("tabindex","0"),this.calendarElement.querySelector("."+Cwt+" ."+Ywt).appendChild(this.rightCalNextIcon),this.calendarElement.querySelector("."+Cwt+" ."+Ywt).appendChild(this.rightCalPrevIcon),Sft([this.rightCalPrevIcon],this.calendarElement.querySelector("."+Cwt+" ."+Ywt)),i.appendChild(this.rightCalendar),t.appendChild(i),this.isMobile||wft.add(this.rightTitle,"click",this.rightNavTitle,this)}return t},t.prototype.leftNavTitle=function(e){this.isPopupOpen()&&(this.calendarElement=this.leftCalendar,this.calendarNavigation(e,this.calendarElement))},t.prototype.calendarNavigation=function(t,n){this.table=n.querySelector("table"),this.headerTitleElement=n.querySelector(".e-title"),this.tableBodyElement=n.querySelector("tbody"),this.tableHeadElement=n.querySelector("thead"),this.contentElement=n.querySelector(".e-content"),this.updateCalendarElement(n),e.prototype.navigateTitle.call(this,t),this.updateNavIcons()},t.prototype.rightNavTitle=function(e){this.isPopupOpen()&&(this.calendarElement=this.rightCalendar,this.calendarNavigation(e,this.calendarElement))},t.prototype.clickEventEmitter=function(e){this.isMobile||(Oft(e.target,".e-calendar.e-left-calendar")?(this.calendarElement=this.leftCalendar,this.updateCalendarElement(this.leftCalendar)):(this.calendarElement=this.rightCalendar,this.updateCalendarElement(this.rightCalendar)))},t.prototype.currentView=function(){return e.prototype.currentView.call(this)},t.prototype.getCalendarView=function(e){return"Year"===e?"Year":"Decade"===e?"Decade":"Month"},t.prototype.navigatedEvent=function(t){if(this.trigger("navigated",this.navigatedArgs),!xpt(this.popupObj)){var n=this.getCalendarView(this.currentView());if(this.isMobile)n===this.depth?(this.bindCalendarCellEvents(),this.deviceNavigation(),this.removeFocusedDate(),this.checkMinMaxDays()):this.selectableDates();else if(this.isMobile||n!==this.depth)this.updateNavIcons(),this.calendarIconEvent();else{if((this.calendarElement.classList.contains("e-left-calendar")?this.leftCalendar:this.rightCalendar)!==this.leftCalendar||(!t||t.currentTarget.children[0].classList.contains("e-icons"))&&xpt(this.controlDown))(t&&!t.currentTarget.children[0].classList.contains("e-icons")||!xpt(this.controlDown))&&(this.rightCalCurrentDate=new Date(+this.currentDate),this.effect="",this.currentDate=this.rightCalCurrentDate,this.updateCalendarElement(this.rightCalendar),this.updateControl(this.rightCalendar),this.updateCalendarElement(this.leftCalendar),this.startValue&&xpt(this.endValue)&&("Month"===n&&this.startValue.getMonth()<this.rightCalCurrentDate.getMonth()&&this.startValue.getFullYear()<=this.rightCalCurrentDate.getFullYear()||"Year"===n&&this.startValue.getFullYear()<this.rightCalCurrentDate.getFullYear())?e.prototype.navigateTo.call(this,n,new Date(+this.startValue)):e.prototype.navigateTo.call(this,n,this.leftCalCurrentDate),this.updateControl(this.leftCalendar),this.updateNavIcons(),this.calendarIconEvent(),this.calendarIconRipple(),this.controlDown=null);else{this.leftCalCurrentDate=new Date(+this.currentDate),this.effect="",this.currentDate=this.leftCalCurrentDate,this.updateCalendarElement(this.leftCalendar),this.updateControl(this.leftCalendar),this.updateCalendarElement(this.rightCalendar),e.prototype.navigateTo.call(this,n,this.rightCalCurrentDate);var a=this.rightCalCurrentDate?this.rightCalCurrentDate:this.currentDate;this.updateControl(this.rightCalendar,a),this.updateNavIcons(),this.calendarIconEvent(),this.calendarIconRipple(),this.controlDown=null}this.checkMinMaxDays()}}},t.prototype.createControl=function(){var e=this.createElement("div",{className:Gwt}),t=this.createElement("div",{className:"e-range-header"}),n=this.createRangeHeader();t.appendChild(n);var a=this.createElement("div",{className:$wt});Hft(a,{"aria-label":"Selected Days"}),a.textContent=this.l10n.getConstant("selectedDays"),t.appendChild(a);var r=this.createElement("div",{className:"e-separator"}),i=this.createCalendar();e.appendChild(t),e.appendChild(r),e.appendChild(i);var o=this.createElement("div",{className:"e-footer"}),l=this.createElement("button",{className:"e-cancel "+syt+" "+cyt}),s=this.createElement("button");xft([s],["e-apply",syt,"e-primary",cyt]),o.appendChild(s),o.appendChild(l);var c=!xpt(this.startValue)&&!xpt(this.endValue);(this.cancelButton=new jgt({content:this.l10n.getConstant("cancelText")},l),this.applyButton=new jgt({content:this.l10n.getConstant("applyText"),disabled:!c},s),wft.add(s,"click",this.applyFunction,this),wft.add(l,"click",this.cancelFunction,this),this.popupWrapper.appendChild(e),this.isMobile)||(Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)||(this.createPresets(),this.listRippleEffect(),xft([e],"e-range-border"),xft([this.popupWrapper],"e-preset-wrapper"),this.popupWrapper.querySelector("."+Kwt).style.height=this.popupWrapper.querySelector("."+Gwt).getBoundingClientRect().height+"px"));this.popupWrapper.appendChild(o),this.isMobile&&this.deviceHeaderUpdate(),this.renderPopup()},t.prototype.cancelFunction=function(e){document.activeElement!==this.inputElement&&(this.preventFocus=!0,this.inputElement.focus(),xft([this.inputWrapper.container],[Lwt])),e.preventDefault(),this.isKeyPopup&&(this.inputElement.focus(),this.isKeyPopup=!1),this.startValue=null,this.endValue=null,this.removeSelection(),this.hide(e)},t.prototype.deviceHeaderUpdate=function(){xpt(this.startValue)&&xpt(this.endValue)?(this.endButton.element.setAttribute("disabled",""),this.startButton.element.classList.add(Iwt)):xpt(this.startValue)||this.startButton.element.classList.add(Iwt)},t.prototype.applyFunction=function(e){var t=!1;"touchstart"!==e.type&&e.preventDefault(),this.closeEventArgs&&this.closeEventArgs.cancel&&(this.startValue=this.popupWrapper.querySelector(".e-start-date")&&this.getIdValue(null,this.popupWrapper.querySelector(".e-start-date")),this.endValue=this.popupWrapper.querySelector(".e-end-date")&&this.getIdValue(null,this.popupWrapper.querySelector(".e-end-date")),this.setValue()),document.activeElement!==this.inputElement&&(this.preventFocus=!0,this.inputElement.focus(),xft([this.inputWrapper.container],[Lwt])),"touchstart"!==e.type&&this.closeEventArgs&&!this.closeEventArgs.cancel&&e.preventDefault(),xpt(this.startValue)||xpt(this.endValue)?this.hide(e||null):(this.previousStartValue=new Date(+this.startValue),this.previousEndValue=new Date(+this.endValue),this.previousEleValue=this.inputElement.value,Vgt.setValue(this.rangeArgs(e).text,this.inputElement,this.floatLabelType,this.showClearButton),+this.initStartDate===+this.startValue&&+this.initEndDate===+this.endValue||(t=!0),this.changeTrigger(e),this.hide(e||null),this.errorClass(),t=!0),Oft(e.target,"."+Swt)||t||this.focusOut(),this.isMobile||(this.isKeyPopup=!1,this.isRangeIconClicked&&(this.inputWrapper.container.children[1].focus(),this.keyInputConfigs=bpt(this.keyInputConfigs,this.keyConfigs),this.popupKeyboardModule=new Vmt(this.inputWrapper.container.children[1],{eventName:"keydown",keyConfigs:this.keyInputConfigs,keyAction:this.popupKeyActionHandle.bind(this)})))},t.prototype.onMouseClick=function(e,t){if("touchstart"!==e.type){var n=Oft(t||e.target,"."+iyt),a=n&&n.classList.contains(Iwt);n&&n.classList.contains(iyt)&&this.setListSelection(n,e),this.preventFocus=!0,this.inputElement.focus(),this.isMobile||(this.preventFocus=!0,n&&n.classList.contains(iyt)&&"custom_range"===n.getAttribute("id")?this.leftCalendar.children[1].firstElementChild.focus():a||"keydown"!==e.type||this.inputElement.focus())}},t.prototype.onMouseOver=function(e){var t=Oft(e.target,"."+iyt);t&&t.classList.contains(iyt)&&!t.classList.contains(oyt)&&xft([t],oyt)},t.prototype.onMouseLeave=function(e){var t=Oft(e.target,"."+oyt);xpt(t)||Eft([t],oyt)},t.prototype.setListSelection=function(e,t){if(e&&(!e.classList.contains(Iwt)||this.isMobile&&e.classList.contains(Iwt))){if(this.isMobile&&e.classList.contains(Iwt))return this.activeIndex=Array.prototype.slice.call(this.liCollections).indexOf(e),"custom_range"===this.presetsItem[this.activeIndex].id?void this.renderCustomPopup():void 0;this.removeListSelection(),this.activeIndex=Array.prototype.slice.call(this.liCollections).indexOf(e),xft([e],Iwt),e.setAttribute("aria-selected","true");var n=this.presetsItem[this.activeIndex];"custom_range"===n.id?this.renderCustomPopup():this.applyPresetRange(n,t)}},t.prototype.removeListSelection=function(){var e=this.presetElement.querySelector("."+Iwt);xpt(e)||(Eft([e],Iwt),e.removeAttribute("aria-selected"))},t.prototype.setValue=function(){this.modelValue=[this.startValue,this.endValue]},t.prototype.applyPresetRange=function(e,t){this.hide(null),this.presetsItem[this.presetsItem.length-1].start=null,this.presetsItem[this.presetsItem.length-1].end=null,this.startValue=e.start,this.endValue=e.end,this.setValue(),this.refreshControl(),this.trigger("select",this.rangeArgs(t)),this.changeTrigger(t),this.previousEleValue=this.inputElement.value,this.isCustomRange=!1,this.leftCalendar=this.rightCalendar=null,this.isKeyPopup&&(this.isRangeIconClicked=!1,this.inputElement.focus())},t.prototype.showPopup=function(e,t){this.presetHeight(),1e3===this.zIndex?this.popupObj.show(null,this.element):this.popupObj.show(null,null),this.isMobile&&this.popupObj.refreshPosition()},t.prototype.renderCustomPopup=function(){this.isCustomWindow=!0,this.popupObj.hide(),this.popupWrapper=this.createElement("div",{id:this.element.id+"_popup",className:Zwt+" "+Awt}),this.renderControl(),this.openEventArgs.appendTo.appendChild(this.popupWrapper),this.showPopup(),this.isCustomRange=!0,this.isMobile||this.calendarFocus()},t.prototype.listRippleEffect=function(){for(var e=0,t=this.liCollections;e<t.length;e++){omt(t[e])}},t.prototype.createPresets=function(){if(!Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)){this.presetElement=this.createElement("div",{className:Kwt,attrs:{tabindex:"0"}});var e=vwt.createList(this.createElement,this.presetsItem,null,!0);Hft(e,{role:"listbox","aria-hidden":"false",id:this.element.id+"_options"}),this.presetElement.appendChild(e),this.popupWrapper.appendChild(this.presetElement);var t=this.presetElement.querySelector("#custom_range");xpt(t)||(t.textContent=""!==this.l10n.getConstant("customRange")?this.l10n.getConstant("customRange"):"Custom Range"),this.liCollections=this.presetElement.querySelectorAll("."+iyt),this.wireListEvents(),this.isMobile&&(this.presetElement.style.width=this.inputWrapper.container.getBoundingClientRect().width+"px"),!xpt(this.activeIndex)&&this.activeIndex>-1&&xft([this.liCollections[this.activeIndex]],Iwt)}},t.prototype.wireListEvents=function(){wft.add(this.presetElement,"click",this.onMouseClick,this),this.isMobile||(wft.add(this.presetElement,"mouseover",this.onMouseOver,this),wft.add(this.presetElement,"mouseout",this.onMouseLeave,this))},t.prototype.unWireListEvents=function(){xpt(this.presetElement)||(wft.remove(this.presetElement,"click touchstart",this.onMouseClick),this.isMobile||(wft.remove(this.presetElement,"mouseover",this.onMouseOver),wft.remove(this.presetElement,"mouseout",this.onMouseLeave)))},t.prototype.renderPopup=function(){var e=this;this.popupWrapper.classList.add("e-control");var t=this.popupWrapper.getBoundingClientRect().width;xpt(this.cssClass)||""===this.cssClass.trim()||(this.popupWrapper.className+=" "+this.cssClass),this.isMobile&&this.isCustomWindow&&(this.modal=this.createElement("div"),document.body.appendChild(this.modal)),this.popupObj=new Dgt(this.popupWrapper,{relateTo:this.isMobile&&this.isCustomWindow?document.body:xpt(this.targetElement)?this.inputWrapper.container:this.targetElement,position:this.isMobile?Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)||this.isCustomWindow?{X:"center",Y:"center"}:{X:"left",Y:"bottom"}:this.enableRtl?{X:"left",Y:"bottom"}:{X:"right",Y:"bottom"},offsetX:this.isMobile||this.enableRtl?0:-t,offsetY:4,collision:this.isMobile?Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)||this.isCustomWindow?{X:"fit",Y:"fit"}:{X:"fit"}:{X:"fit",Y:"flip"},targetType:this.isMobile&&this.isCustomWindow?"container":"relative",enableRtl:this.enableRtl,zIndex:this.zIndex,open:function(){Hft(e.inputElement,{"aria-expanded":"true"}),xft([e.inputWrapper.buttons[0]],Iwt),e.isMobile||(e.cancelButton&&(e.btnKeyboardModule=new Vmt(e.cancelButton.element,{eventName:"keydown",keyAction:e.popupKeyActionHandle.bind(e),keyConfigs:{tab:"tab",altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"}}),e.btnKeyboardModule=new Vmt(e.applyButton.element,{eventName:"keydown",keyAction:e.popupKeyActionHandle.bind(e),keyConfigs:{altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"}})),xpt(e.leftCalendar)||e.isRangeIconClicked||e.calendarFocus(),xpt(e.presetElement)||(e.keyInputConfigs=bpt(e.keyInputConfigs,e.keyConfigs),e.presetKeyboardModule=new Vmt(e.presetElement,{eventName:"keydown",keyAction:e.presetKeyActionHandler.bind(e),keyConfigs:e.keyInputConfigs}),e.presetKeyboardModule=new Vmt(e.presetElement,{eventName:"keydown",keyAction:e.popupKeyActionHandle.bind(e),keyConfigs:{altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"}}),xpt(e.leftCalendar)?(e.preventBlur=!0,e.presetElement.focus()):e.presetElement.setAttribute("tabindex","-1")),e.popupKeyBoardHandler()),e.isMobile&&!gft.isDevice&&wft.add(document,"keydown",e.popupCloseHandler,e)},close:function(){Hft(e.inputElement,{"aria-expanded":"false"}),Eft([e.inputWrapper.buttons[0]],Iwt),e.isRangeIconClicked&&e.inputWrapper.container.children[1].focus(),Ept(e.presets[0].start&&e.presets[0].end&&e.presets[0].label)||e.unWireListEvents(),xpt(e.popupObj)||(xpt(e.popupObj.element.parentElement)||Cft(e.popupObj.element),e.popupObj.destroy(),e.popupObj=null),e.isMobile&&!gft.isDevice&&wft.remove(document,"keydown",e.popupCloseHandler)},targetExitViewport:function(){gft.isDevice||e.hide()}}),this.isMobile&&(this.popupObj.element.classList.add(ayt),this.isMobile||this.popupObj.element.classList.add("e-bigger")),this.isMobile&&this.isCustomWindow&&(xft([this.modal],[ayt,Zwt,"e-range-modal"]),document.body.className+=" "+lyt,this.modal.style.display="block"),wft.add(document,"mousedown touchstart",this.documentHandler,this)},t.prototype.popupCloseHandler=function(e){if(27===e.keyCode)this.hide(e)},t.prototype.calendarFocus=function(){var e=this.popupObj&&this.popupObj.element.querySelector("."+Dwt);if(e){var t=Oft(e,"."+Cwt);t=xpt(t)?this.leftCalendar:t,this.isRangeIconClicked?this.inputWrapper.container.focus():(this.preventBlur=!0,t.children[1].firstElementChild.focus()),xft([e],Xwt)}else this.isRangeIconClicked?this.inputWrapper.container.focus():(this.preventBlur=!0,this.leftCalendar.children[1].firstElementChild.focus())},t.prototype.presetHeight=function(){var e=this.popupObj&&this.popupObj.element.querySelector("."+Kwt),t=this.popupObj&&this.popupObj.element.querySelector("."+Gwt);xpt(e)||xpt(t)||(e.style.height=t.getBoundingClientRect().height+"px")},t.prototype.presetKeyActionHandler=function(e){switch(e.action){case"moveDown":this.listMoveDown(e),this.setScrollPosition(),e.preventDefault();break;case"moveUp":this.listMoveUp(e),this.setScrollPosition(),e.preventDefault();break;case"enter":var t=this.getHoverLI(),n=this.getActiveLI();if(!xpt(this.leftCalendar)&&!xpt(n))if(xpt(t)||!xpt(n)&&n===t)if(this.activeIndex=Array.prototype.slice.call(this.liCollections).indexOf(n),"custom_range"===this.presetsItem[this.activeIndex].id)return this.calendarFocus(),n.classList.remove(oyt),void e.preventDefault();xpt(t)&&xpt(n)||this.onMouseClick(e,t||n),e.preventDefault();break;case"tab":if(this.leftCalendar){var a=this.getHoverLI();xpt(a)||a.classList.remove(oyt)}else this.hide(e),e.preventDefault()}},t.prototype.listMoveDown=function(e){var t=this.getHoverLI(),n=this.getActiveLI();if(xpt(t))if(xpt(n))xft([this.liCollections[0]],oyt);else{var a;!xpt(a=n.nextElementSibling)&&a.classList.contains(iyt)&&xft([a],oyt)}else!xpt(a=t.nextElementSibling)&&a.classList.contains(iyt)&&(Eft([t],oyt),xft([a],oyt))},t.prototype.listMoveUp=function(e){var t=this.getHoverLI(),n=this.getActiveLI();if(xpt(t)){if(!xpt(n)){var a;!xpt(a=n.previousElementSibling)&&a.classList.contains(iyt)&&xft([a],oyt)}}else!xpt(a=t.previousElementSibling)&&a.classList.contains(iyt)&&(Eft([t],oyt),xft([a],oyt))},t.prototype.getHoverLI=function(){return this.presetElement.querySelector("."+oyt)},t.prototype.getActiveLI=function(){return this.presetElement.querySelector("."+Iwt)},t.prototype.popupKeyBoardHandler=function(){this.popupKeyboardModule=new Vmt(this.popupWrapper,{eventName:"keydown",keyAction:this.popupKeyActionHandle.bind(this),keyConfigs:{escape:"escape"}}),this.keyInputConfigs=bpt(this.keyInputConfigs,this.keyConfigs),this.popupKeyboardModule=new Vmt(this.inputWrapper.container.children[1],{eventName:"keydown",keyAction:this.popupKeyActionHandle.bind(this),keyConfigs:this.keyInputConfigs})},t.prototype.setScrollPosition=function(){var e=this.presetElement.getBoundingClientRect().height,t=this.presetElement.querySelector("."+oyt),n=this.presetElement.querySelector("."+Iwt),a=xpt(t)?n:t;if(!xpt(a)){var r=a.nextElementSibling,i=r?r.offsetTop:a.offsetTop,o=a.getBoundingClientRect().height;i+a.offsetTop>e?this.presetElement.scrollTop=r?i-(e/2+o/2):i:this.presetElement.scrollTop=0}},t.prototype.popupKeyActionHandle=function(e){var t=Oft(e.target,"."+Kwt);switch(e.action){case"escape":this.isPopupOpen()?(this.isKeyPopup&&(this.inputElement.focus(),this.isKeyPopup=!1),this.hide(e)):this.inputWrapper.container.children[1].blur();break;case"enter":this.isPopupOpen()?this.inputWrapper.container.children[1].focus():this.show(null,e);break;case"tab":this.hide(e);break;case"altRightArrow":xpt(t)?document.activeElement===this.cancelButton.element&&!0!==this.applyButton.element.disabled?this.applyButton.element.focus():this.leftCalendar.children[1].firstElementChild.focus():this.cancelButton.element.focus(),e.preventDefault();break;case"altLeftArrow":xpt(t)?document.activeElement===this.applyButton.element&&!0!==this.applyButton.element.disabled?this.cancelButton.element.focus():xpt(this.presetElement)||document.activeElement!==this.cancelButton.element?this.rightCalendar.children[1].firstElementChild.focus():this.presetElement.focus():this.rightCalendar.children[1].firstElementChild.focus(),e.preventDefault()}},t.prototype.documentHandler=function(e){if(!xpt(this.popupObj)){var t=e.target;this.inputWrapper.container.contains(t)&&(xpt(this.popupObj)||Oft(t,'[id="'+this.popupWrapper.id+'"]'))||"touchstart"!==e.type&&("mousedown"===e.type||this.closeEventArgs&&!this.closeEventArgs.cancel)&&e.preventDefault(),!xpt(this.targetElement)&&(xpt(this.targetElement)||t===this.targetElement)||Oft(t,'[id="'+this.popupWrapper.id+'"]')||Oft(t,"."+Swt)===this.inputWrapper.container||Oft(t,".e-daterangepicker.e-popup")&&!t.classList.contains("e-day")||(this.preventBlur=!1,this.isPopupOpen()&&document.body.contains(this.popupObj.element)&&(this.applyFunction(e),this.isMobile||(this.isRangeIconClicked=!1)))}},t.prototype.createInput=function(){var e=this.cssClass;xpt(this.cssClass)||""===this.cssClass||(e=this.cssClass.replace(/\s+/g," ").trim()),this.inputWrapper=Vgt.createInput({floatLabelType:this.floatLabelType,element:this.inputElement,properties:{readonly:this.readonly,placeholder:this.placeholder,cssClass:e,enabled:this.enabled,enableRtl:this.enableRtl,showClearButton:this.showClearButton},buttons:["e-input-group-icon e-range-icon e-icons"]},this.createElement),Hft(this.inputElement,{"aria-readonly":this.readonly?"true":"false",tabindex:"0","aria-haspopup":"true","aria-activedescendant":"null","aria-owns":this.element.id+"_popup","aria-expanded":"false",role:"combobox",autocomplete:"off","aria-disabled":this.enabled?"false":"true",autocorrect:"off",autocapitalize:"off",spellcheck:"false"}),Vgt.addAttributes({"aria-label":"select"},this.inputWrapper.buttons[0]),xpt(this.placeholder)||""===this.placeholder.trim()||Vgt.addAttributes({"aria-placeholder":this.placeholder},this.inputElement),this.setEleWidth(this.width),xft([this.inputWrapper.container],"e-date-range-wrapper"),xpt(this.inputElement.getAttribute("name"))&&Hft(this.inputElement,{name:this.element.id}),"hidden"===this.inputElement.type&&(this.inputWrapper.container.style.display="none"),this.refreshControl(),this.previousEleValue=this.inputElement.value,this.inputElement.setAttribute("value",this.inputElement.value),this.startCopy=this.startDate,this.endCopy=this.endDate},t.prototype.setEleWidth=function(e){this.inputWrapper.container.style.width="string"==typeof e?this.width:"number"==typeof e?Apt(this.width):"100%"},t.prototype.adjustLongHeaderWidth=function(){"Wide"===this.dayHeaderFormat&&xft([this.popupWrapper],"e-daterange-day-header-lg")},t.prototype.refreshControl=function(){this.validateMinMax(),this.strictMode&&this.validateRangeStrict();var e=this.disabledDates();this.strictMode&&e&&(this.startValue=this.previousStartValue,this.setProperties({startDate:this.startValue},!0),this.endValue=this.previousEndValue,this.setProperties({endDate:this.endValue},!0),this.setValue()),this.updateInput(),this.strictMode||this.validateRange(),!this.strictMode&&e&&this.clearRange(),xpt(this.endValue)||xpt(this.startValue)||e||this.disabledDateRender(),this.errorClass(),this.previousStartValue=xpt(this.startValue)||isNaN(+this.startValue)?null:new Date(+this.startValue),this.previousEndValue=xpt(this.endValue)||isNaN(+this.endValue)?null:new Date(+this.endValue)},t.prototype.updateInput=function(){if(!xpt(this.endValue)&&!xpt(this.startValue)){var e={format:this.formatString,type:"date",skeleton:"yMd"},t=this.globalize.formatDate(this.startValue,e),n=this.globalize.formatDate(this.endValue,e);Vgt.setValue(t+" "+this.separator+" "+n,this.inputElement,this.floatLabelType,this.showClearButton),this.previousStartValue=new Date(+this.startValue),this.previousEndValue=new Date(+this.endValue)}!this.strictMode&&xpt(this.value)&&this.invalidValueString&&Vgt.setValue(this.invalidValueString,this.inputElement,this.floatLabelType,this.showClearButton)},t.prototype.checkInvalidRange=function(e){if(!xpt(e)){var t=!1,n=void 0,a=void 0,r=null,i=null,o=null,l=!1,s=!1,c=!1;if("string"==typeof e){var d=e.split(" "+this.separator+" ");2===d.length?(r=d[0],i=d[1]):(t=!0,o=e)}else e.length>0?(n=e[0],a=e[1]):(n=e.start,a=e.end),n instanceof Date||"object"==typeof n?n instanceof Date?l=!0:xpt(n)||(c=!0):r=this.getstringvalue(n),a instanceof Date||"object"==typeof a?a instanceof Date?s=!0:xpt(a)||(c=!0):i=this.getstringvalue(a);(xpt(r)&&!l&&!xpt(i)||!xpt(r)&&!s&&xpt(i))&&(t=!0),c&&(r=i=o=null,t=!0),r&&(t=t||this.checkInvalidValue(r)),i&&(t=t||this.checkInvalidValue(i)),t&&(l&&!c&&(r=n.toLocaleDateString()),s&&!c&&(i=a.toLocaleDateString()),xpt(r)||xpt(i)?xpt(r)?xpt(i)||(o=i):o=r:o=r+" "+this.separator+" "+i,this.invalidValueString=o,this.setProperties({value:null},!0),this.setProperties({startValue:null},!0),this.setProperties({endValue:null},!0),this.startDate=null,this.endDate=null)}},t.prototype.getstringvalue=function(e){var t=null;return xpt(e)||"number"!=typeof e?xpt(e)||"string"!=typeof e||(t=""+e):t=e.toString(),t},t.prototype.checkInvalidValue=function(e){var t,n=e,a=!1;if(t={format:this.formatString,type:"date",skeleton:"yMd"},"string"!=typeof n)a=!0;else{var r=new aft(this.locale);if(!this.checkDateValue(r.parseDate(n,t))){var i=null;i=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,(!/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/.test(n)&&!i.test(n)||/^[a-zA-Z0-9- ]*$/.test(n)||isNaN(+new Date(this.checkValue(n))))&&(a=!0)}}return a},t.prototype.isDateDisabled=function(e){if(xpt(e))return!1;var t=new Date(+e);if(+t<+this.min||+t>+this.max)return!0;this.virtualRenderCellArgs={date:t,isDisabled:!1};var n=this.virtualRenderCellArgs;return this.virtualRenderCellEvent(n),!!n.isDisabled},t.prototype.disabledDateRender=function(){this.disabledDays=[],this.disabledDayCnt=null;for(var e=new Date(+this.startValue),t=0;+e<=+this.endValue&&+this.endValue<=+this.max;){this.virtualRenderCellArgs={date:e,isDisabled:!1};var n=this.virtualRenderCellArgs;this.virtualRenderCellEvent(n),n.isDisabled&&(this.disabledDays.push(new Date(+n.date)),+e>+this.startValue&&+e<+this.endValue&&t++),this.addDay(e,1,null,this.max,this.min)}this.disabledDayCnt=t},t.prototype.virtualRenderCellEvent=function(e){bpt(this.virtualRenderCellArgs,{name:"renderDayCell"}),this.trigger("renderDayCell",e)},t.prototype.disabledDates=function(){var e=!1,t=!1;return xpt(this.endValue)||xpt(this.startValue)||(e=this.isDateDisabled(this.startValue),t=this.isDateDisabled(this.endValue),this.isPopupOpen()||(this.currentDate=null),this.setValue()),e||t},t.prototype.setModelValue=function(){this.value||null!==this.startDate||null!==this.endDate?null===this.value||null===this.value.start?null===this.value?this.setProperties({value:[this.startDate,this.endDate]},!0):null===this.value.start&&this.setProperties({value:{start:this.startDate,end:this.endDate}},!0):this.value&&this.value.length>0||this.valueType&&this.valueType.length>0?(+this.startDate===+this.value[0]&&+this.endDate===+this.value[1]||this.setProperties({value:[this.startDate,this.endDate]},!0),this.value&&null==this.value[0]&&null==this.value[1]&&this.setProperties({value:null},!0)):this.value&&this.value.start&&this.setProperties({value:{start:this.startDate,end:this.endDate}},!0):this.setProperties({value:null},!0),this.createHiddenInput()},t.prototype.dispatchEvent=function(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!1,!0),e.dispatchEvent(n),this.firstHiddenChild.dispatchEvent(n)},t.prototype.changeTrigger=function(e){+this.initStartDate===+this.startValue&&+this.initEndDate===+this.endValue||(this.setProperties({endDate:this.checkDateValue(this.endValue)},!0),this.setProperties({startDate:this.checkDateValue(this.startValue)},!0),this.setModelValue(),this.isAngular&&this.preventChange?this.preventChange=!1:this.trigger("change",this.rangeArgs(e))),this.previousEleValue=this.inputElement.value,this.initStartDate=this.checkDateValue(this.startValue),this.initEndDate=this.checkDateValue(this.endValue)},t.prototype.navigateTo=function(t,n){if(this.isPopupOpen()){if("month"===t.toLowerCase())t="Month";else if("year"===t.toLowerCase())t="Year";else{if("decade"!==t.toLowerCase())return;t="Decade"}this.getViewNumber(t)<this.getViewNumber(this.depth)&&(t=this.depth),this.isMobile?e.prototype.navigateTo.call(this,t,n):(n<this.min?n=new Date(+this.min):n>=this.max&&(n=new Date(+this.max)),"Month"===t&&this.isSameMonth(n,this.max)?n=new Date(this.max.getFullYear(),this.max.getMonth()-1,this.min.getDate()):"Year"===t&&this.isSameYear(n,this.max)?n=new Date(this.max.getFullYear()-1,this.max.getMonth(),this.max.getDate()):"Decade"===t&&this.isSameDecade(n,this.max)&&(n=new Date(this.max.getFullYear()-10,this.max.getMonth(),this.max.getDate())),this.leftCalCurrentDate=n,this.navigate(this.leftCalendar,this.leftCalCurrentDate,t),n="Month"===t?new Date(this.currentDate.setMonth(this.currentDate.getMonth()+1)):"Year"===t?new Date(this.currentDate.setFullYear(this.currentDate.getFullYear()+1)):new Date(this.currentDate.setFullYear(this.currentDate.getFullYear()+10)),this.rightCalCurrentDate=n,this.navigate(this.rightCalendar,this.rightCalCurrentDate,t),this.leftKeyboardModule=this.rightKeyboardModule=null,this.updateNavIcons()),this.currentView()===this.depth&&this.bindCalendarCellEvents(),this.removeFocusedDate(),this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar])}},t.prototype.navigate=function(t,n,a){this.calendarElement=t,this.table=t.querySelector("table"),this.tableBodyElement=t.querySelector("tbody"),this.headerTitleElement=t.querySelector(".e-title"),this.tableHeadElement=t.querySelector("thead"),this.contentElement=t.querySelector(".e-content"),this.previousIcon=t.querySelector(".e-prev"),this.nextIcon=t.querySelector(".e-next"),this.effect="e-zoomin",e.prototype.navigateTo.call(this,a,n)},t.prototype.focusIn=function(){document.activeElement!==this.inputElement&&this.enabled&&(xft([this.inputWrapper.container],[Lwt]),this.inputElement.focus())},t.prototype.focusOut=function(){var e=this.preventBlur;document.activeElement===this.inputElement&&(Eft([this.inputWrapper.container],[Lwt]),this.preventBlur=!1,this.inputElement.blur(),this.preventBlur=e)},t.prototype.destroy=function(){this.unBindEvents(),this.hide(null);var t={"aria-readonly":this.readonly?"true":"false",tabindex:"0","aria-haspopup":"true","aria-activedescendant":"null","aria-owns":this.element.id+"_popup","aria-expanded":"false",role:"combobox",autocomplete:"off","aria-disabled":this.enabled?"false":"true",autocorrect:"off",autocapitalize:"off","aria-invalid":"false",spellcheck:"false"};this.inputElement&&(Eft([this.inputElement],[Zwt]),wft.remove(this.inputElement,"blur",this.inputBlurHandler),Vgt.removeAttributes(t,this.inputElement),xpt(this.cloneElement.getAttribute("tabindex"))?this.inputElement.removeAttribute("tabindex"):this.inputElement.setAttribute("tabindex",this.tabIndex),this.ensureInputAttribute(),this.inputElement.classList.remove("e-input"),xpt(this.inputWrapper)||(wft.remove(this.inputWrapper.buttons[0],"mousedown",this.rangeIconHandler),null===this.angularTag&&this.inputWrapper.container.parentElement.appendChild(this.inputElement),Cft(this.inputWrapper.container))),xpt(this.inputKeyboardModule)||this.isMobile||this.inputKeyboardModule.destroy(),this.popupObj&&(this.isMobile||this.clearCalendarEvents()),e.prototype.destroy.call(this),this.inputWrapper=this.popupWrapper=this.popupObj=this.cloneElement=this.presetElement=null,this.formElement&&wft.remove(this.formElement,"reset",this.formResetHandler),xpt(this.firstHiddenChild)||xpt(this.secondHiddenChild)||(Cft(this.firstHiddenChild),Cft(this.secondHiddenChild),this.firstHiddenChild=this.secondHiddenChild=null,this.inputElement.setAttribute("name",this.element.getAttribute("data-name")),this.inputElement.removeAttribute("data-name"))},t.prototype.ensureInputAttribute=function(){for(var e=[],t=0;t<this.inputElement.attributes.length;t++)e[t]=this.inputElement.attributes[t].name;for(t=0;t<e.length;t++)xpt(this.cloneElement.getAttribute(e[t]))?("value"===e[t].toLowerCase()&&(this.inputElement.value=""),this.inputElement.removeAttribute(e[t])):("value"===e[t].toLowerCase()&&(this.inputElement.value=this.cloneElement.getAttribute(e[t])),this.inputElement.setAttribute(e[t],this.cloneElement.getAttribute(e[t])))},t.prototype.getModuleName=function(){return"daterangepicker"},t.prototype.getPersistData=function(){return this.addOnPersist(["startDate","endDate","value"])},t.prototype.getSelectedRange=function(){var e;return xpt(this.startValue)||xpt(this.endValue)?e=0:(e=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1,this.disabledDateRender(),xpt(this.disabledDayCnt)||(e-=this.disabledDayCnt,this.disabledDayCnt=null)),{startDate:this.startValue,endDate:this.endValue,daySpan:e}},t.prototype.show=function(t,n){var a=this;if(this.isMobile&&this.popupObj&&this.popupObj.refreshPosition(),!(this.enabled&&this.readonly||!this.enabled||this.popupObj||this.isPopupOpen())){t&&(this.targetElement=t),this.createPopup(),(this.isMobile||gft.isDevice)&&(this.mobileRangePopupWrap=this.createElement("div",{className:"e-daterangepick-mob-popup-wrap"}),document.body.appendChild(this.mobileRangePopupWrap)),this.openEventArgs={popup:this.popupObj||null,cancel:!1,date:this.inputElement.value,model:this,event:n||null,appendTo:this.isMobile||gft.isDevice?this.mobileRangePopupWrap:document.body};var r=this.openEventArgs;this.trigger("open",r,function(r){if(a.openEventArgs=r,!a.openEventArgs.cancel){a.openEventArgs.appendTo.appendChild(a.popupWrapper),a.showPopup(t,n);var i=!a.isCustomRange||a.isMobile&&a.isCustomRange;!Ept(a.presets[0].start&&a.presets[0].end&&a.presets[0].label)&&i&&a.setScrollPosition(),a.checkMinMaxDays(),a.isMobile&&!xpt(a.startDate)&&xpt(a.endDate)&&(a.endButton.element.classList.add(Iwt),a.startButton.element.classList.remove(Iwt),a.endButton.element.removeAttribute("disabled"),a.selectableDates()),e.prototype.setOverlayIndex.call(a,a.mobileRangePopupWrap,a.popupObj.element,a.modal,a.isMobile||gft.isDevice)}})}},t.prototype.hide=function(e){var t=this;if(this.popupObj){if(xpt(this.previousEndValue)&&xpt(this.previousStartValue)?this.clearRange():(xpt(this.previousStartValue)?(this.startValue=null,this.setValue()):(this.startValue=new Date(this.checkValue(this.previousStartValue)),this.setValue(),this.currentDate=new Date(this.checkValue(this.startValue))),xpt(this.previousEndValue)?(this.endValue=null,this.setValue()):(this.endValue=new Date(this.checkValue(this.previousEndValue)),this.setValue())),this.isPopupOpen()){this.closeEventArgs={cancel:!1,popup:this.popupObj,date:this.inputElement.value,model:this,event:e||null};var n=this.closeEventArgs;this.trigger("close",n,function(e){t.closeEventArgs=e,t.closeEventArgs.cancel?Eft([t.inputWrapper.buttons[0]],Iwt):(t.isMobile&&(xpt(t.startButton)||xpt(t.endButton)||(wft.remove(t.startButton.element,"click touchstart",t.deviceHeaderClick),wft.remove(t.endButton.element,"click touchstart",t.deviceHeaderClick))),t.popupObj&&(t.popupObj.hide(),t.preventBlur&&(t.inputElement.focus(),xft([t.inputWrapper.container],[Lwt]))),t.isMobile||(xpt(t.leftKeyboardModule)||xpt(t.rightKeyboardModule)||(t.leftKeyboardModule.destroy(),t.rightKeyboardModule.destroy()),xpt(t.presetElement)||t.presetKeyboardModule.destroy(),xpt(t.cancelButton)||t.btnKeyboardModule.destroy()),t.targetElement=null,Eft([document.body],lyt),wft.remove(document,"mousedown touchstart",t.documentHandler),t.isMobile&&t.modal&&(t.modal.style.display="none",t.modal.outerHTML="",t.modal=null),(t.isMobile||gft.isDevice)&&(xpt(t.mobileRangePopupWrap)||(t.mobileRangePopupWrap.remove(),t.mobileRangePopupWrap=null)),t.isKeyPopup=t.dateDisabled=!1),t.updateClearIconState(),t.updateHiddenInput(),t.isMobile&&t.allowEdit&&!t.readonly&&t.inputElement.removeAttribute("readonly")})}}else this.updateClearIconState(),this.updateHiddenInput(),this.isMobile&&this.allowEdit&&!this.readonly&&this.inputElement.removeAttribute("readonly")},t.prototype.setLocale=function(){this.globalize=new aft(this.locale),this.l10n.setLocale(this.locale),this.setProperties({placeholder:this.l10n.getConstant("placeholder")},!0),Vgt.setPlaceholder(this.placeholder,this.inputElement),this.updateInput(),this.updateHiddenInput(),this.changeTrigger()},t.prototype.refreshChange=function(){this.checkView(),this.refreshControl(),this.changeTrigger()},t.prototype.setDate=function(){Vgt.setValue("",this.inputElement,this.floatLabelType,this.showClearButton),this.refreshChange()},t.prototype.enableInput=function(){+this.min<=+this.max&&(this.setProperties({enabled:!0},!0),Vgt.setEnabled(this.enabled,this.inputElement),this.element.hasAttribute("disabled")&&this.bindEvents())},t.prototype.clearModelvalue=function(e,t){this.setProperties({startDate:null},!0),this.setProperties({endDate:null},!0),t.value&&t.value.length>0?this.setProperties({value:null},!0):(t.value&&t.value.start||t.value&&!t.value.start)&&this.setProperties({value:{start:null,end:null}},!0),this.updateValue(),this.setDate()},t.prototype.createHiddenInput=function(){xpt(this.firstHiddenChild)&&xpt(this.secondHiddenChild)&&(this.firstHiddenChild=this.createElement("input"),this.secondHiddenChild=this.createElement("input")),xpt(this.inputElement.getAttribute("name"))||(this.inputElement.setAttribute("data-name",this.inputElement.getAttribute("name")),this.inputElement.removeAttribute("name")),Hft(this.firstHiddenChild,{type:"text",name:this.inputElement.getAttribute("data-name"),class:hyt}),Hft(this.secondHiddenChild,{type:"text",name:this.inputElement.getAttribute("data-name"),class:hyt});var e={type:"datetime",skeleton:"yMd"};this.firstHiddenChild.value=this.startDate&&this.globalize.formatDate(this.startDate,e),this.secondHiddenChild.value=this.endDate&&this.globalize.formatDate(this.endDate,e),this.inputElement.parentElement.appendChild(this.firstHiddenChild),this.inputElement.parentElement.appendChild(this.secondHiddenChild)},t.prototype.setMinMaxDays=function(){this.isPopupOpen()&&(this.removeClassDisabled(),this.checkMinMaxDays(),this.isMobile&&this.selectableDates(),!this.strictMode&&xpt(this.startValue)&&xpt(this.endValue)?this.removeSelection():this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar]),this.updateHeader())},t.prototype.onPropertyChanged=function(e,t){for(var n={format:this.formatString,type:"date",skeleton:"yMd"},a=0,r=Object.keys(e);a<r.length;a++){var i=r[a];switch(["maxDays","minDays","value"].indexOf(i)<0&&this.hide(null),i){case"width":this.setEleWidth(this.width);break;case"separator":this.previousEleValue=this.inputElement.value,this.setProperties({separator:e.separator},!0),this.updateInput(),this.changeTrigger();break;case"placeholder":Vgt.setPlaceholder(e.placeholder,this.inputElement),this.setProperties({placeholder:e.placeholder},!0);break;case"readonly":Vgt.setReadonly(this.readonly,this.inputElement),this.inputElement.setAttribute("aria-readonly",""+this.readonly),this.setRangeAllowEdit();break;case"cssClass":this.updateCssClass(e.cssClass,t.cssClass);break;case"enabled":this.setProperties({enabled:e.enabled},!0),Vgt.setEnabled(this.enabled,this.inputElement),this.enabled?this.inputElement.setAttribute("tabindex",this.tabIndex):this.inputElement.tabIndex=-1;break;case"allowEdit":this.setRangeAllowEdit();break;case"enableRtl":this.setProperties({enableRtl:e.enableRtl},!0),Vgt.setEnableRtl(this.enableRtl,[this.inputWrapper.container]);break;case"zIndex":this.setProperties({zIndex:e.zIndex},!0);break;case"format":this.setProperties({format:e.format},!0),this.checkFormat(),this.updateInput(),this.changeTrigger();break;case"locale":this.globalize=new aft(this.locale),this.l10n.setLocale(this.locale),this.setProperties({placeholder:this.l10n.getConstant("placeholder")},!0),Vgt.setPlaceholder(this.placeholder,this.inputElement),this.setLocale();break;case"htmlAttributes":this.updateHtmlAttributeToElement(),this.updateHtmlAttributeToWrapper(),this.setDataAttribute(!0),this.checkHtmlAttributes(!0);break;case"showClearButton":Vgt.setClearButton(this.showClearButton,this.inputElement,this.inputWrapper),this.bindClearEvent();break;case"startDate":"string"==typeof e.startDate&&(e.startDate=this.globalize.parseDate(e.startDate,n)),+this.initStartDate!==+e.startDate&&(this.startValue=this.checkDateValue(new Date(this.checkValue(e.startDate))),this.setDate(),this.setValue());break;case"endDate":"string"==typeof e.endDate&&(e.endDate=this.globalize.parseDate(e.endDate,n)),+this.initEndDate!==+e.endDate&&(this.endValue=this.checkDateValue(new Date(this.checkValue(e.endDate))),this.setDate(),this.setValue());break;case"value":if(this.invalidValueString=null,this.checkInvalidRange(e.value),"string"==typeof e.value)if(this.invalidValueString)this.clearModelvalue(e,t);else{var o=e.value.split(" "+this.separator+" ");this.value=[new Date(o[0]),new Date(o[1])],this.updateValue(),this.setDate()}else!xpt(e.value)&&e.value.length>0||!xpt(e.value)&&e.value.start?(this.valueType=e.value,null===e.value[0]||null===e.value.start?1===e.value.length||e.value.start?this.clearModelvalue(e,t):null!==e.value[1]&&null!==e.value.start||this.clearModelvalue(e,t):+this.initStartDate===+e.value[0]&&+this.initEndDate===+e.value[1]&&+this.initStartDate===+(e.value.start||+this.initEndDate!==+e.value.start)||((1===e.value.length||e.value.start)&&(this.modelValue=e.value),this.updateValue(),this.setDate())):(xpt(this.value)||null==e.value.start)&&(this.valueType=e.value,this.startValue=null,this.endValue=null,this.clearModelvalue(e,t));if(this.isPopupOpen()){if(xpt(this.startValue)&&xpt(this.endValue))return this.removeSelection(),void(this.isMobile&&this.deviceHeaderUpdate());this.isMobile?(this.navigate(this.deviceCalendar,this.startValue,this.currentView()),this.deviceHeaderUpdate()):(this.navigate(this.leftCalendar,this.startValue,this.currentView()),this.updateControl(this.leftCalendar),this.navigate(this.rightCalendar,this.endValue,this.currentView()),this.updateControl(this.rightCalendar)),this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar]),this.updateHeader(),this.applyButton.disabled=this.applyButton.element.disabled=!1}this.preventChange=this.isAngular&&this.preventChange?!this.preventChange:this.preventChange;break;case"minDays":this.setProperties({minDays:e.minDays},!0),this.refreshChange(),this.setMinMaxDays();break;case"maxDays":this.setProperties({maxDays:e.maxDays},!0),this.refreshChange(),this.setMinMaxDays();break;case"min":this.setProperties({min:this.checkDateValue(new Date(this.checkValue(e.min)))},!0),this.previousEleValue=this.inputElement.value,this.enableInput(),this.refreshChange();break;case"max":this.setProperties({max:this.checkDateValue(new Date(this.checkValue(e.max)))},!0),this.enableInput(),this.refreshChange();break;case"strictMode":this.invalidValueString=null,this.setProperties({strictMode:e.strictMode},!0),this.refreshChange();break;case"presets":this.setProperties({presets:e.presets},!0),this.processPresets();break;case"floatLabelType":this.floatLabelType=e.floatLabelType,Vgt.removeFloating(this.inputWrapper),Vgt.addFloating(this.inputElement,this.floatLabelType,this.placeholder);break;case"start":this.setProperties({start:e.start},!0),this.refreshChange();break;case"depth":this.setProperties({depth:e.depth},!0),this.refreshChange()}}},Mwt([Kft(null)],t.prototype,"value",void 0),Mwt([Kft(!1)],t.prototype,"enablePersistence",void 0),Mwt([Kft(new Date(1900,0,1))],t.prototype,"min",void 0),Mwt([Kft(new Date(2099,11,31))],t.prototype,"max",void 0),Mwt([Kft(null)],t.prototype,"locale",void 0),Mwt([Kft(null)],t.prototype,"firstDayOfWeek",void 0),Mwt([Kft(!1)],t.prototype,"weekNumber",void 0),Mwt([Kft("Gregorian")],t.prototype,"calendarMode",void 0),Mwt([Kft(!1)],t.prototype,"openOnFocus",void 0),Mwt([Jft()],t.prototype,"created",void 0),Mwt([Jft()],t.prototype,"destroyed",void 0),Mwt([Jft()],t.prototype,"change",void 0),Mwt([Jft()],t.prototype,"cleared",void 0),Mwt([Jft()],t.prototype,"navigated",void 0),Mwt([Jft()],t.prototype,"renderDayCell",void 0),Mwt([Kft(null)],t.prototype,"startDate",void 0),Mwt([Kft(null)],t.prototype,"endDate",void 0),Mwt([Xft([{}],pyt)],t.prototype,"presets",void 0),Mwt([Kft("")],t.prototype,"width",void 0),Mwt([Kft(1e3)],t.prototype,"zIndex",void 0),Mwt([Kft(!0)],t.prototype,"showClearButton",void 0),Mwt([Kft(!0)],t.prototype,"showTodayButton",void 0),Mwt([Kft("Month")],t.prototype,"start",void 0),Mwt([Kft("Month")],t.prototype,"depth",void 0),Mwt([Kft("")],t.prototype,"cssClass",void 0),Mwt([Kft("-")],t.prototype,"separator",void 0),Mwt([Kft(null)],t.prototype,"minDays",void 0),Mwt([Kft(null)],t.prototype,"maxDays",void 0),Mwt([Kft(!1)],t.prototype,"strictMode",void 0),Mwt([Kft(null)],t.prototype,"keyConfigs",void 0),Mwt([Kft(null)],t.prototype,"format",void 0),Mwt([Kft(!0)],t.prototype,"enabled",void 0),Mwt([Kft(!1)],t.prototype,"readonly",void 0),Mwt([Kft(!0)],t.prototype,"allowEdit",void 0),Mwt([Kft("Never")],t.prototype,"floatLabelType",void 0),Mwt([Kft(null)],t.prototype,"placeholder",void 0),Mwt([Kft({})],t.prototype,"htmlAttributes",void 0),Mwt([Jft()],t.prototype,"open",void 0),Mwt([Jft()],t.prototype,"close",void 0),Mwt([Jft()],t.prototype,"select",void 0),Mwt([Jft()],t.prototype,"focus",void 0),Mwt([Jft()],t.prototype,"blur",void 0),t=Mwt([$ft],t)}(qvt),myt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),vyt=["alt","className","disabled","form","id","readOnly","style","tabIndex","title","type","name","onClick","onFocus","onBlur"],gyt=["accordion","tab","splitter"],wyt=new RegExp("]"),yyt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.mountingState=!1,t.attrKeys=[],t.cachedTimeOut=0,t.isAppendCalled=!1,t.initRenderCalled=!1,t.isReactForeceUpdate=!1,t.isReact=!0,t.isshouldComponentUpdateCalled=!1,t.isCreated=!1,t}return myt(t,e),t.prototype.componentDidMount=function(){this.refreshChild(!0),this.canDelayUpdate=-1!==gyt.indexOf(this.getModuleName()),this.renderReactComponent(),this.portals&&this.portals.length&&(this.mountingState=!0,this.renderReactTemplates(),this.mountingState=!1)},t.prototype.componentDidUpdate=function(e){this.isshouldComponentUpdateCalled||!this.initRenderCalled||this.isReactForeceUpdate||(this.isshouldComponentUpdateCalled=!0,e!==this.props&&this.refreshProperties(this.props,!0))},t.prototype.renderReactComponent=function(){var e=this.reactElement;e&&!this.isAppendCalled&&(this.isAppendCalled=!0,this.appendTo(e))},t.prototype.shouldComponentUpdate=function(e){return this.isshouldComponentUpdateCalled=!0,this.initRenderCalled?(this.isAppendCalled||(clearTimeout(this.cachedTimeOut),this.isAppendCalled=!0,this.appendTo(this.reactElement)),this.updateProperties(e),!0):(this.updateProperties(e,!0),!0)},t.prototype.updateProperties=function(e,t){for(var n=this,a=bpt({},e),r=0,i=Object.keys(e);r<i.length;r++){var o=i[r],l="className"===o;if("children"!==o)if(l||xpt(this.htmlattributes[o])||this.htmlattributes[o]===a[o]||(this.htmlattributes[o]=a[o]),this.compareValues(this.props[o],e[o]))delete a[o];else if(-1!==this.attrKeys.indexOf(o))if(l){this.clsName=!0;for(var s=this.props[o].split(" "),c=0;c<s.length;c++)this.element.classList.remove(s[c]);for(var d=a[o].split(" "),h=0;h<d.length;h++)this.element.classList.add(d[h])}else"disabled"!==o&&delete a[o];else"value"===o&&e[o]===this[o]?delete a[o]:"valueTemplate"!==o&&"itemTemplate"!==o&&"headerTemplate"!==o||e[o].toString()!==this[o].toString()?"content"===o&&"function"==typeof a[o]&&delete a[o]:delete a[o]}a.children&&delete a.children,this.initRenderCalled&&(this.canDelayUpdate||this.props.delayUpdate)?setTimeout(function(){n.refreshProperties(a,e,t)}):this.refreshProperties(a,e,t)},t.prototype.refreshProperties=function(e,t,n){Object.keys(e).length&&(n||this.processComplexTemplate(e,this),this.setProperties(e,n)),this.refreshChild(n,t)},t.prototype.processComplexTemplate=function(e,t){var n=t.complexTemplate;if(n)for(var a in n){var r=n[a];e[a]&&mpt(r,fpt(a,e),e)}},t.prototype.getDefaultAttributes=function(){var e=this;this.isReact=!0;var n=Object.keys(this.props);this.htmlattributes||(this.htmlattributes={}),this.attrKeys=vyt.concat(this.controlAttributes||[]);for(var a=0,r=n;a<r.length;a++){var i=r[a];-1===i.indexOf("data-")&&-1===i.indexOf("aria-")&&-1===this.attrKeys.indexOf(i)||this.htmlattributes[i]!==this.props[i]&&(this.htmlattributes[i]=this.props[i])}if(!this.htmlattributes.ref){this.htmlattributes.ref=function(t){e.reactElement=t};-1!==["autocomplete","combobox","dropdownlist","dropdowntree","multiselect","listbox","colorpicker","numerictextbox","textbox","uploader","maskedtextbox","slider","datepicker","datetimepicker","daterangepicker","timepicker","checkbox","switch","radio"].indexOf(this.getModuleName())&&(this.htmlattributes.key=""+t.reactUid,t.reactUid++)}if(this.clsName){for(var o=this.element.classList,l=this.htmlattributes.className,s=0;s<o.length;s++)-1==l.indexOf(o[s])&&(this.htmlattributes.className=this.htmlattributes.className+" "+o[s]);this.clsName=!1}return this.htmlattributes},t.prototype.trigger=function(e,t,n){var a=this;if(!0!==this.isDestroyed&&this.modelObserver){if(wyt.test(e)){var r=fpt(e,this);r?(r.call(this,t),n&&n.call(this,t)):n&&n.call(this,t)}"change"!==e&&"input"!==e||this.props.onChange&&t.event&&this.props.onChange.call(void 0,{syntheticEvent:t.event,nativeEvent:{text:t.value},value:t.value,target:this});var i=this.isProtectedOnChange;this.isProtectedOnChange=!1,"created"===e?setTimeout(function(){a.isCreated=!0,a.isDestroyed||a.modelObserver.notify(e,t,n)},10):this.modelObserver.notify(e,t,n),this.isProtectedOnChange=i}},t.prototype.compareValues=function(e,t){if(typeof e===typeof t){if(e===t)return!0;if((!xpt(e)&&e.constructor)!==(!xpt(t)&&t.constructor))return!1;if(e instanceof Date||e instanceof RegExp||e instanceof String||e instanceof Number)return e.toString()===t.toString();if(wpt(e)||Array.isArray(e)){var n=e,a=t;return wpt(n)&&(n=[e],a=[t]),this.compareObjects(n,a).status}}return!1},t.prototype.compareObjects=function(e,t,n){var a=!0,r=[];if(e.length===t.length)for(var i=0,o=t.length;i<o;i++){var l={},s=e[i],c=t[i],d=Object.keys(c);if(0!==d.length)for(var h=0,u=d;h<u.length;h++){var p=u[h],f=s[p],m=c[p];if("items"===p)for(var v=0;v<m.length;v++)if("richtexteditor"===this.getModuleName()&&"object"==typeof m[v])return{status:!0};if("grid"===this.getModuleName()&&"field"===p&&(l[p]=m),!s.hasOwnProperty(p)||!this.compareValues(f,m)){if(!n)return{status:!1};a=!1,l[p]=m}}else if(c[i]===s[i])a=!0;else{if(!n)return{status:!1};a=!1}Object.keys(l).length&&r.push({index:i,value:l,key:n})}else a=!1;return{status:a,changedProperties:r}},t.prototype.refreshChild=function(e,t){if(this.checkInjectedModules){for(var n=this.getInjectedModules()||[],a=0,r=this.getInjectedServices()||[];a<r.length;a++){var i=r[a];-1===n.indexOf(i)&&n.push(i)}this.injectedModules=n}if(this.directivekeys){var o=[],l=this.validateChildren({},this.directivekeys,t||this.props);if(l&&Object.keys(l).length){if(!e&&this.skipRefresh)for(var s=0,c=this.skipRefresh;s<c.length;s++){delete l[c[s]]}if(this.prevProperties)for(var d=Object.keys(this.prevProperties),h=0;h<d.length;h++){var u=d[h];if(l.hasOwnProperty(u)){var p=this.compareObjects(this.prevProperties[u],l[u],u);if(p.status)delete l[u];else{p.changedProperties.length&&(o=o.concat(p.changedProperties));var f={};f[u]=l[u],this.prevProperties=bpt(this.prevProperties,f)}}}else this.prevProperties=bpt({},l,{},!0);if(o.length)if("grid"===this.getModuleName()&&"columns"===u)for(var m=0,v=this.columns;m<v.length;m++){if(fpt("field",v[m])===fpt(m+".value.field",o)){var g=fpt(o[m].key+"."+o[m].index,this);g&&g.setProperties?g.setProperties(o[m].value):bpt(g,o[m].value)}else this.setProperties(l,e)}else for(var w=0,y=o;w<y.length;w++){var b=y[w],x=fpt(b.key+"."+b.index,this);x&&x.setProperties?x.setProperties(b.value):bpt(x,b.value)}else this.setProperties(l,e)}}},t.prototype.componentWillUnmount=function(){clearTimeout(this.cachedTimeOut);this.initRenderCalled&&this.isAppendCalled&&this.element&&(["dropdowntree","checkbox"].indexOf(this.getModuleName())||document.body.contains(this.element))&&!this.isDestroyed&&this.isCreated&&this.destroy()},t.prototype.appendReactElement=function(e,t){var n=g.createPortal(e,t);this.portals?this.portals.push(n):this.portals=[n]},t.prototype.renderReactTemplates=function(e){this.isReactForeceUpdate=!0,e?this.forceUpdate(e):this.forceUpdate(),this.isReactForeceUpdate=!1},t.prototype.clearTemplate=function(e,t,n){var a=this,r=[];e&&e.length?Array.prototype.forEach.call(e,function(e){var n=0,i=0;if(a.portals.forEach(function(t){t.propName===e&&(r.push(i),i++)}),t&&a.portals[r[t[n]]].propName==e)a.portals.splice(t,1),n++;else for(var o=0;o<a.portals.length;o++)a.portals[o].propName==e&&(a.portals.splice(o,1),o--)}):this.portals=[],this.renderReactTemplates(n)},t.prototype.validateChildren=function(e,t,n){for(var a=!1,r=0,i=m.Children.toArray(n.children);r<i.length;r++){var o=i[r],l=this.getChildType(o),s=t[l];if(l&&t){var c=this.getChildProps(m.Children.toArray(o.props.children),s);c.length&&(a=!0,e[o.type.propertyName||l]=c)}}return a?e:null},t.prototype.getChildType=function(e){return e.type&&e.type.isDirective&&e.type.moduleName||""},t.prototype.getChildProps=function(e,t){for(var n=[],a=0,r=e;a<r.length;a++){var i=r[a],o=!1,l=void 0;"string"==typeof t?(o=!0,l=t):l=Object.keys(t)[0];var s=i.props;if(this.getChildType(i)===l)if(o||!s.children){var c=bpt({},s,{},!0);this.processComplexTemplate(c,i.type),n.push(c)}else{var d=this.validateChildren(bpt({},s),t[l],s)||s;d.children&&delete d.children,this.processComplexTemplate(d,i.type),n.push(d)}}return n},t.prototype.getInjectedServices=function(){for(var e=0,t=m.Children.toArray(this.props.children);e<t.length;e++){var n=t[e];if(n.type.isService)return n.props.services}return[]},t.reactUid=1,t}(m.Component);var byt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}();!function(e){function t(){return null!==e&&e.apply(this,arguments)||this}byt(t,e),t.prototype.render=function(){return null},t.isDirective=!0}(m.PureComponent);var xyt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}();!function(e){function t(){return null!==e&&e.apply(this,arguments)||this}xyt(t,e),t.prototype.render=function(){return null},t.isService=!0}(m.PureComponent);var Eyt,kyt=wvt.compile;Eyt={compile:function(e,t){return"string"==typeof e?kyt(e,t):function(t,n,a,r){var i,o=e,l=t;"object"==typeof o&&(o=e.template,l=bpt({},t,e.data||{})),i=r||document.createElement("div");var s=m.createElement(o,l),c=g.createPortal(s,i);if(c.propName=a,n.portals?n.portals.push(c):n.portals=[c],!r)return[i]}}},wvt.compile=Eyt.compile;var Myt,Syt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Ayt=function(e){function t(t){var n=e.call(this,t)||this;return n.initRenderCalled=!1,n.checkInjectedModules=!1,n.directivekeys={presets:"preset"},n.immediateRender=!1,n.portals=[],n}return Syt(t,e),t.prototype.render=function(){if(!(this.element&&!this.initRenderCalled||this.refreshing)||this.isReactForeceUpdate)return m.createElement(m.Fragment,null,[].concat(m.createElement("input",this.getDefaultAttributes()),this.portals));e.prototype.render.call(this),this.initRenderCalled=!0},t}(fyt);function _yt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Cyt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_yt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_yt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}Myt=Ayt,[yyt,m.Component].forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(t){"isMounted"!==t&&"replaceState"!==t&&(Myt.prototype[t]=e.prototype[t])})});var Zyt={type:"logger",log:function(e){this.output("log",e)},warn:function(e){this.output("warn",e)},error:function(e){this.output("error",e)},output:function(e,t){console&&console[e]&&console[e].apply(console,t)}},Hyt=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};gs(this,e),this.init(t,n)}return ys(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||Zyt,this.options=t,this.debug=t.debug}},{key:"setDebug",value:function(e){this.debug=e}},{key:"log",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}},{key:"warn",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}},{key:"error",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}},{key:"deprecate",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(e,t,n,a){return a&&!this.debug?null:("string"==typeof e[0]&&(e[0]="".concat(n).concat(this.prefix," ").concat(e[0])),this.logger[t](e))}},{key:"create",value:function(t){return new e(this.logger,Cyt(Cyt({},{prefix:"".concat(this.prefix,":").concat(t,":")}),this.options))}},{key:"clone",value:function(t){return(t=t||this.options).prefix=t.prefix||this.prefix,new e(this.logger,t)}}]),e}(),Iyt=new Hyt,Dyt=function(){function e(){gs(this,e),this.observers={}}return ys(e,[{key:"on",value:function(e,t){var n=this;return e.split(" ").forEach(function(e){n.observers[e]=n.observers[e]||[],n.observers[e].push(t)}),this}},{key:"off",value:function(e,t){this.observers[e]&&(t?this.observers[e]=this.observers[e].filter(function(e){return e!==t}):delete this.observers[e])}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),a=1;a<t;a++)n[a-1]=arguments[a];this.observers[e]&&[].concat(this.observers[e]).forEach(function(e){e.apply(void 0,n)});this.observers["*"]&&[].concat(this.observers["*"]).forEach(function(t){t.apply(t,[e].concat(n))})}}]),e}();function Nyt(){var e,t,n=new Promise(function(n,a){e=n,t=a});return n.resolve=e,n.reject=t,n}function Oyt(e){return null==e?"":""+e}function Lyt(e,t,n){function a(e){return e&&e.indexOf("###")>-1?e.replace(/###/g,"."):e}function r(){return!e||"string"==typeof e}for(var i="string"!=typeof t?[].concat(t):t.split(".");i.length>1;){if(r())return{};var o=a(i.shift());!e[o]&&n&&(e[o]=new n),e=Object.prototype.hasOwnProperty.call(e,o)?e[o]:{}}return r()?{}:{obj:e,k:a(i.shift())}}function Vyt(e,t,n){var a=Lyt(e,t,Object);a.obj[a.k]=n}function zyt(e,t){var n=Lyt(e,t),a=n.obj,r=n.k;if(a)return a[r]}function Pyt(e,t,n){var a=zyt(e,n);return void 0!==a?a:zyt(t,n)}function Tyt(e,t,n){for(var a in t)"__proto__"!==a&&"constructor"!==a&&(a in e?"string"==typeof e[a]||e[a]instanceof String||"string"==typeof t[a]||t[a]instanceof String?n&&(e[a]=t[a]):Tyt(e[a],t[a],n):e[a]=t[a]);return e}function Byt(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var jyt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};function Wyt(e){return"string"==typeof e?e.replace(/[&<>"'\/]/g,function(e){return jyt[e]}):e}var Ryt="undefined"!=typeof window&&window.navigator&&void 0===window.navigator.userAgentData&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,Fyt=[" ",",","?","!",";"];function Yyt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function qyt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yyt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yyt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Uyt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}function Gyt(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(e){if(e[t])return e[t];for(var a=t.split(n),r=e,i=0;i<a.length;++i){if(!r)return;if("string"==typeof r[a[i]]&&i+1<a.length)return;if(void 0===r[a[i]]){for(var o=2,l=a.slice(i,i+o).join(n),s=r[l];void 0===s&&a.length>i+o;)o++,s=r[l=a.slice(i,i+o).join(n)];if(void 0===s)return;if(null===s)return null;if(t.endsWith(l)){if("string"==typeof s)return s;if(l&&"string"==typeof s[l])return s[l]}var c=a.slice(i+o).join(n);return c?Gyt(s,c,n):void 0}r=r[a[i]]}return r}}var Kyt=function(){CQe(t,Dyt);var e=Uyt(t);function t(n){var a,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};return gs(this,t),a=e.call(this),Ryt&&Dyt.call(qn(a)),a.data=n||{},a.options=r,void 0===a.options.keySeparator&&(a.options.keySeparator="."),void 0===a.options.ignoreJSONStructure&&(a.options.ignoreJSONStructure=!0),a}return ys(t,[{key:"addNamespaces",value:function(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}},{key:"removeNamespaces",value:function(e){var t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}},{key:"getResource",value:function(e,t,n){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},r=void 0!==a.keySeparator?a.keySeparator:this.options.keySeparator,i=void 0!==a.ignoreJSONStructure?a.ignoreJSONStructure:this.options.ignoreJSONStructure,o=[e,t];n&&"string"!=typeof n&&(o=o.concat(n)),n&&"string"==typeof n&&(o=o.concat(r?n.split(r):n)),e.indexOf(".")>-1&&(o=e.split("."));var l=zyt(this.data,o);return l||!i||"string"!=typeof n?l:Gyt(this.data&&this.data[e]&&this.data[e][t],n,r)}},{key:"addResource",value:function(e,t,n,a){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1},i=this.options.keySeparator;void 0===i&&(i=".");var o=[e,t];n&&(o=o.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=t,t=(o=e.split("."))[1]),this.addNamespaces(t),Vyt(this.data,o,a),r.silent||this.emit("added",e,t,n,a)}},{key:"addResources",value:function(e,t,n){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(var r in n)"string"!=typeof n[r]&&"[object Array]"!==Object.prototype.toString.apply(n[r])||this.addResource(e,t,r,n[r],{silent:!0});a.silent||this.emit("added",e,t,n)}},{key:"addResourceBundle",value:function(e,t,n,a,r){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1},o=[e,t];e.indexOf(".")>-1&&(a=n,n=t,t=(o=e.split("."))[1]),this.addNamespaces(t);var l=zyt(this.data,o)||{};a?Tyt(l,n,r):l=qyt(qyt({},l),n),Vyt(this.data,o,l),i.silent||this.emit("added",e,t,n)}},{key:"removeResourceBundle",value:function(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}},{key:"hasResourceBundle",value:function(e,t){return void 0!==this.getResource(e,t)}},{key:"getResourceBundle",value:function(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?qyt(qyt({},{}),this.getResource(e,t)):this.getResource(e,t)}},{key:"getDataByLanguage",value:function(e){return this.data[e]}},{key:"hasLanguageSomeTranslations",value:function(e){var t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(function(e){return t[e]&&Object.keys(t[e]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),t}(),Qyt={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,n,a,r){var i=this;return e.forEach(function(e){i.processors[e]&&(t=i.processors[e].process(t,n,a,r))}),t}};function Xyt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Jyt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xyt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xyt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function $yt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}var ebt={},tbt=function(){CQe(t,Dyt);var e=$yt(t);function t(n){var a,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return gs(this,t),a=e.call(this),Ryt&&Dyt.call(qn(a)),function(e,t,n){e.forEach(function(e){t[e]&&(n[e]=t[e])})}(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],n,qn(a)),a.options=r,void 0===a.options.keySeparator&&(a.options.keySeparator="."),a.logger=Iyt.create("translator"),a}return ys(t,[{key:"changeLanguage",value:function(e){e&&(this.language=e)}},{key:"exists",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};if(null==e)return!1;var n=this.resolve(e,t);return n&&void 0!==n.res}},{key:"extractFromKey",value:function(e,t){var n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");var a=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,r=t.ns||this.options.defaultNS||[],i=n&&e.indexOf(n)>-1,o=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||function(e,t,n){t=t||"",n=n||"";var a=Fyt.filter(function(e){return t.indexOf(e)<0&&n.indexOf(e)<0});if(0===a.length)return!0;var r=new RegExp("(".concat(a.map(function(e){return"?"===e?"\\?":e}).join("|"),")")),i=!r.test(e);if(!i){var o=e.indexOf(n);o>0&&!r.test(e.substring(0,o))&&(i=!0)}return i}(e,n,a));if(i&&!o){var l=e.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return{key:e,namespaces:r};var s=e.split(n);(n!==a||n===a&&this.options.ns.indexOf(s[0])>-1)&&(r=s.shift()),e=s.join(a)}return"string"==typeof r&&(r=[r]),{key:e,namespaces:r}}},{key:"translate",value:function(e,n,a){var r=this;if("object"!==fs(n)&&this.options.overloadTranslationOptionHandler&&(n=this.options.overloadTranslationOptionHandler(arguments)),n||(n={}),null==e)return"";Array.isArray(e)||(e=[String(e)]);var i=void 0!==n.returnDetails?n.returnDetails:this.options.returnDetails,o=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,l=this.extractFromKey(e[e.length-1],n),s=l.key,c=l.namespaces,d=c[c.length-1],h=n.lng||this.language,u=n.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(h&&"cimode"===h.toLowerCase()){if(u){var p=n.nsSeparator||this.options.nsSeparator;return i?(f.res="".concat(d).concat(p).concat(s),f):"".concat(d).concat(p).concat(s)}return i?(f.res=s,f):s}var f=this.resolve(e,n),m=f&&f.res,v=f&&f.usedKey||s,g=f&&f.exactUsedKey||s,w=Object.prototype.toString.apply(m),y=void 0!==n.joinArrays?n.joinArrays:this.options.joinArrays,b=!this.i18nFormat||this.i18nFormat.handleAsObject;if(b&&m&&("string"!=typeof m&&"boolean"!=typeof m&&"number"!=typeof m)&&["[object Number]","[object Function]","[object RegExp]"].indexOf(w)<0&&("string"!=typeof y||"[object Array]"!==w)){if(!n.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var x=this.options.returnedObjectHandler?this.options.returnedObjectHandler(v,m,Jyt(Jyt({},n),{},{ns:c})):"key '".concat(s," (").concat(this.language,")' returned an object instead of string.");return i?(f.res=x,f):x}if(o){var E="[object Array]"===w,k=E?[]:{},M=E?g:v;for(var S in m)if(Object.prototype.hasOwnProperty.call(m,S)){var A="".concat(M).concat(o).concat(S);k[S]=this.translate(A,Jyt(Jyt({},n),{joinArrays:!1,ns:c})),k[S]===A&&(k[S]=m[S])}m=k}}else if(b&&"string"==typeof y&&"[object Array]"===w)(m=m.join(y))&&(m=this.extendTranslation(m,e,n,a));else{var _=!1,C=!1,Z=void 0!==n.count&&"string"!=typeof n.count,H=t.hasDefaultValue(n),I=Z?this.pluralResolver.getSuffix(h,n.count,n):"",D=n["defaultValue".concat(I)]||n.defaultValue;!this.isValidLookup(m)&&H&&(_=!0,m=D),this.isValidLookup(m)||(C=!0,m=s);var N=(n.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&C?void 0:m,O=H&&D!==m&&this.options.updateMissing;if(C||_||O){if(this.logger.log(O?"updateKey":"missingKey",h,d,s,O?D:m),o){var L=this.resolve(s,Jyt(Jyt({},n),{},{keySeparator:!1}));L&&L.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var V=[],z=this.languageUtils.getFallbackCodes(this.options.fallbackLng,n.lng||this.language);if("fallback"===this.options.saveMissingTo&&z&&z[0])for(var P=0;P<z.length;P++)V.push(z[P]);else"all"===this.options.saveMissingTo?V=this.languageUtils.toResolveHierarchy(n.lng||this.language):V.push(n.lng||this.language);var T=function(e,t,a){var i=H&&a!==m?a:N;r.options.missingKeyHandler?r.options.missingKeyHandler(e,d,t,i,O,n):r.backendConnector&&r.backendConnector.saveMissing&&r.backendConnector.saveMissing(e,d,t,i,O,n),r.emit("missingKey",e,d,t,m)};this.options.saveMissing&&(this.options.saveMissingPlurals&&Z?V.forEach(function(e){r.pluralResolver.getSuffixes(e,n).forEach(function(t){T([e],s+t,n["defaultValue".concat(t)]||D)})}):T(V,s,D))}m=this.extendTranslation(m,e,n,f,a),C&&m===s&&this.options.appendNamespaceToMissingKey&&(m="".concat(d,":").concat(s)),(C||_)&&this.options.parseMissingKeyHandler&&(m="v1"!==this.options.compatibilityAPI?this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(d,":").concat(s):s,_?m:void 0):this.options.parseMissingKeyHandler(m))}return i?(f.res=m,f):m}},{key:"extendTranslation",value:function(e,t,n,a,r){var i=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,Jyt(Jyt({},this.options.interpolation.defaultVariables),n),a.usedLng,a.usedNS,a.usedKey,{resolved:a});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init(Jyt(Jyt({},n),{interpolation:Jyt(Jyt({},this.options.interpolation),n.interpolation)}));var o,l="string"==typeof e&&(n&&n.interpolation&&void 0!==n.interpolation.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);if(l){var s=e.match(this.interpolator.nestingRegexp);o=s&&s.length}var c=n.replace&&"string"!=typeof n.replace?n.replace:n;if(this.options.interpolation.defaultVariables&&(c=Jyt(Jyt({},this.options.interpolation.defaultVariables),c)),e=this.interpolator.interpolate(e,c,n.lng||this.language,n),l){var d=e.match(this.interpolator.nestingRegexp);o<(d&&d.length)&&(n.nest=!1)}!1!==n.nest&&(e=this.interpolator.nest(e,function(){for(var e=arguments.length,a=new Array(e),o=0;o<e;o++)a[o]=arguments[o];return r&&r[0]===a[0]&&!n.context?(i.logger.warn("It seems you are nesting recursively key: ".concat(a[0]," in key: ").concat(t[0])),null):i.translate.apply(i,a.concat([t]))},n)),n.interpolation&&this.interpolator.reset()}var h=n.postProcess||this.options.postProcess,u="string"==typeof h?[h]:h;return null!=e&&u&&u.length&&!1!==n.applyPostProcessor&&(e=Qyt.handle(u,e,t,this.options&&this.options.postProcessPassResolved?Jyt({i18nResolved:a},n):n,this)),e}},{key:"resolve",value:function(e){var t,n,a,r,i,o=this,l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e&&(e=[e]),e.forEach(function(e){if(!o.isValidLookup(t)){var s=o.extractFromKey(e,l),c=s.key;n=c;var d=s.namespaces;o.options.fallbackNS&&(d=d.concat(o.options.fallbackNS));var h=void 0!==l.count&&"string"!=typeof l.count,u=h&&!l.ordinal&&0===l.count&&o.pluralResolver.shouldUseIntlApi(),p=void 0!==l.context&&("string"==typeof l.context||"number"==typeof l.context)&&""!==l.context,f=l.lngs?l.lngs:o.languageUtils.toResolveHierarchy(l.lng||o.language,l.fallbackLng);d.forEach(function(e){o.isValidLookup(t)||(i=e,!ebt["".concat(f[0],"-").concat(e)]&&o.utils&&o.utils.hasLoadedNamespace&&!o.utils.hasLoadedNamespace(i)&&(ebt["".concat(f[0],"-").concat(e)]=!0,o.logger.warn('key "'.concat(n,'" for languages "').concat(f.join(", "),'" won\'t get resolved as namespace "').concat(i,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach(function(n){if(!o.isValidLookup(t)){r=n;var i,s=[c];if(o.i18nFormat&&o.i18nFormat.addLookupKeys)o.i18nFormat.addLookupKeys(s,c,n,e,l);else{var d;h&&(d=o.pluralResolver.getSuffix(n,l.count,l));var f="".concat(o.options.pluralSeparator,"zero");if(h&&(s.push(c+d),u&&s.push(c+f)),p){var m="".concat(c).concat(o.options.contextSeparator).concat(l.context);s.push(m),h&&(s.push(m+d),u&&s.push(m+f))}}for(;i=s.pop();)o.isValidLookup(t)||(a=i,t=o.getResource(n,e,i,l))}}))})}}),{res:t,usedKey:n,exactUsedKey:a,usedLng:r,usedNS:i}}},{key:"isValidLookup",value:function(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}},{key:"getResource",value:function(e,t,n){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,n,a):this.resourceStore.getResource(e,t,n,a)}}],[{key:"hasDefaultValue",value:function(e){var t="defaultValue";for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}]),t}();function nbt(e){return e.charAt(0).toUpperCase()+e.slice(1)}var abt=function(){function e(t){gs(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Iyt.create("languageUtils")}return ys(e,[{key:"getScriptPartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return null;var t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}},{key:"getLanguagePartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return e;var t=e.split("-");return this.formatLanguageCode(t[0])}},{key:"formatLanguageCode",value:function(e){if("string"==typeof e&&e.indexOf("-")>-1){var t=["hans","hant","latn","cyrl","cans","mong","arab"],n=e.split("-");return this.options.lowerCaseLng?n=n.map(function(e){return e.toLowerCase()}):2===n.length?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=nbt(n[1].toLowerCase()))):3===n.length&&(n[0]=n[0].toLowerCase(),2===n[1].length&&(n[1]=n[1].toUpperCase()),"sgn"!==n[0]&&2===n[2].length&&(n[2]=n[2].toUpperCase()),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=nbt(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=nbt(n[2].toLowerCase()))),n.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}},{key:"isSupportedCode",value:function(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}},{key:"getBestMatchFromCodes",value:function(e){var t,n=this;return e?(e.forEach(function(e){if(!t){var a=n.formatLanguageCode(e);n.options.supportedLngs&&!n.isSupportedCode(a)||(t=a)}}),!t&&this.options.supportedLngs&&e.forEach(function(e){if(!t){var a=n.getLanguagePartFromCode(e);if(n.isSupportedCode(a))return t=a;t=n.options.supportedLngs.find(function(e){if(0===e.indexOf(a))return e})}}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t):null}},{key:"getFallbackCodes",value:function(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),"string"==typeof e&&(e=[e]),"[object Array]"===Object.prototype.toString.apply(e))return e;if(!t)return e.default||[];var n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}},{key:"toResolveHierarchy",value:function(e,t){var n=this,a=this.getFallbackCodes(t||this.options.fallbackLng||[],e),r=[],i=function(e){e&&(n.isSupportedCode(e)?r.push(e):n.logger.warn("rejecting language code not found in supportedLngs: ".concat(e)))};return"string"==typeof e&&e.indexOf("-")>-1?("languageOnly"!==this.options.load&&i(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&i(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&i(this.getLanguagePartFromCode(e))):"string"==typeof e&&i(this.formatLanguageCode(e)),a.forEach(function(e){r.indexOf(e)<0&&i(n.formatLanguageCode(e))}),r}}]),e}(),rbt=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],ibt={1:function(e){return Number(e>1)},2:function(e){return Number(1!=e)},3:function(e){return 0},4:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},5:function(e){return Number(0==e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5)},6:function(e){return Number(1==e?0:e>=2&&e<=4?1:2)},7:function(e){return Number(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},8:function(e){return Number(1==e?0:2==e?1:8!=e&&11!=e?2:3)},9:function(e){return Number(e>=2)},10:function(e){return Number(1==e?0:2==e?1:e<7?2:e<11?3:4)},11:function(e){return Number(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3)},12:function(e){return Number(e%10!=1||e%100==11)},13:function(e){return Number(0!==e)},14:function(e){return Number(1==e?0:2==e?1:3==e?2:3)},15:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2)},16:function(e){return Number(e%10==1&&e%100!=11?0:0!==e?1:2)},17:function(e){return Number(1==e||e%10==1&&e%100!=11?0:1)},18:function(e){return Number(0==e?0:1==e?1:2)},19:function(e){return Number(1==e?0:0==e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3)},20:function(e){return Number(1==e?0:0==e||e%100>0&&e%100<20?1:2)},21:function(e){return Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0)},22:function(e){return Number(1==e?0:2==e?1:(e<0||e>10)&&e%10==0?2:3)}},obt=["v1","v2","v3"],lbt={zero:0,one:1,two:2,few:3,many:4,other:5};var sbt=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};gs(this,e),this.languageUtils=t,this.options=n,this.logger=Iyt.create("pluralResolver"),this.options.compatibilityJSON&&"v4"!==this.options.compatibilityJSON||"undefined"!=typeof Intl&&Intl.PluralRules||(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=function(){var e={};return rbt.forEach(function(t){t.lngs.forEach(function(n){e[n]={numbers:t.nr,plurals:ibt[t.fc]}})}),e}()}return ys(e,[{key:"addRule",value:function(e,t){this.rules[e]=t}},{key:"getRule",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(e,{type:t.ordinal?"ordinal":"cardinal"})}catch(e){return}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}},{key:"needsPlural",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return this.shouldUseIntlApi()?n&&n.resolvedOptions().pluralCategories.length>1:n&&n.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.getSuffixes(e,n).map(function(e){return"".concat(t).concat(e)})}},{key:"getSuffixes",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=this.getRule(e,n);return a?this.shouldUseIntlApi()?a.resolvedOptions().pluralCategories.sort(function(e,t){return lbt[e]-lbt[t]}).map(function(e){return"".concat(t.options.prepend).concat(e)}):a.numbers.map(function(a){return t.getSuffix(e,a,n)}):[]}},{key:"getSuffix",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=this.getRule(e,n);return a?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(a.select(t)):this.getSuffixRetroCompatible(a,t):(this.logger.warn("no plural rule found for: ".concat(e)),"")}},{key:"getSuffixRetroCompatible",value:function(e,t){var n=this,a=e.noAbs?e.plurals(t):e.plurals(Math.abs(t)),r=e.numbers[a];this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]&&(2===r?r="plural":1===r&&(r=""));var i=function(){return n.options.prepend&&r.toString()?n.options.prepend+r.toString():r.toString()};return"v1"===this.options.compatibilityJSON?1===r?"":"number"==typeof r?"_plural_".concat(r.toString()):i():"v2"===this.options.compatibilityJSON||this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]?i():this.options.prepend&&a.toString()?this.options.prepend+a.toString():a.toString()}},{key:"shouldUseIntlApi",value:function(){return!obt.includes(this.options.compatibilityJSON)}}]),e}();function cbt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function dbt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cbt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cbt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var hbt=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};gs(this,e),this.logger=Iyt.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(e){return e},this.init(t)}return ys(e,[{key:"init",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});var t=e.interpolation;this.escape=void 0!==t.escape?t.escape:Wyt,this.escapeValue=void 0===t.escapeValue||t.escapeValue,this.useRawValueToEscape=void 0!==t.useRawValueToEscape&&t.useRawValueToEscape,this.prefix=t.prefix?Byt(t.prefix):t.prefixEscaped||"{{",this.suffix=t.suffix?Byt(t.suffix):t.suffixEscaped||"}}",this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||",",this.unescapePrefix=t.unescapeSuffix?"":t.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":t.unescapeSuffix||"",this.nestingPrefix=t.nestingPrefix?Byt(t.nestingPrefix):t.nestingPrefixEscaped||Byt("$t("),this.nestingSuffix=t.nestingSuffix?Byt(t.nestingSuffix):t.nestingSuffixEscaped||Byt(")"),this.nestingOptionsSeparator=t.nestingOptionsSeparator?t.nestingOptionsSeparator:t.nestingOptionsSeparator||",",this.maxReplaces=t.maxReplaces?t.maxReplaces:1e3,this.alwaysFormat=void 0!==t.alwaysFormat&&t.alwaysFormat,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var e="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(e,"g");var t="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(t,"g");var n="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(n,"g")}},{key:"interpolate",value:function(e,t,n,a){var r,i,o,l=this,s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function c(e){return e.replace(/\$/g,"$$$$")}var d=function(e){if(e.indexOf(l.formatSeparator)<0){var r=Pyt(t,s,e);return l.alwaysFormat?l.format(r,void 0,n,dbt(dbt(dbt({},a),t),{},{interpolationkey:e})):r}var i=e.split(l.formatSeparator),o=i.shift().trim(),c=i.join(l.formatSeparator).trim();return l.format(Pyt(t,s,o),c,n,dbt(dbt(dbt({},a),t),{},{interpolationkey:o}))};this.resetRegExp();var h=a&&a.missingInterpolationHandler||this.options.missingInterpolationHandler,u=a&&a.interpolation&&void 0!==a.interpolation.skipOnVariables?a.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:function(e){return c(e)}},{regex:this.regexp,safeValue:function(e){return l.escapeValue?c(l.escape(e)):c(e)}}].forEach(function(t){for(o=0;r=t.regex.exec(e);){var n=r[1].trim();if(void 0===(i=d(n)))if("function"==typeof h){var s=h(e,r,a);i="string"==typeof s?s:""}else if(a&&a.hasOwnProperty(n))i="";else{if(u){i=r[0];continue}l.logger.warn("missed to pass in variable ".concat(n," for interpolating ").concat(e)),i=""}else"string"==typeof i||l.useRawValueToEscape||(i=Oyt(i));var c=t.safeValue(i);if(e=e.replace(r[0],c),u?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=r[0].length):t.regex.lastIndex=0,++o>=l.maxReplaces)break}}),e}},{key:"nest",value:function(e,t){var n,a,r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=dbt({},i);function l(e,t){var n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;var a=e.split(new RegExp("".concat(n,"[ ]*{"))),r="{".concat(a[1]);e=a[0];var i=(r=this.interpolate(r,o)).match(/'/g),l=r.match(/"/g);(i&&i.length%2==0&&!l||l.length%2!=0)&&(r=r.replace(/'/g,'"'));try{o=JSON.parse(r),t&&(o=dbt(dbt({},t),o))}catch(t){return this.logger.warn("failed parsing options string in nesting for key ".concat(e),t),"".concat(e).concat(n).concat(r)}return delete o.defaultValue,e}for(o.applyPostProcessor=!1,delete o.defaultValue;n=this.nestingRegexp.exec(e);){var s=[],c=!1;if(-1!==n[0].indexOf(this.formatSeparator)&&!/{.*}/.test(n[1])){var d=n[1].split(this.formatSeparator).map(function(e){return e.trim()});n[1]=d.shift(),s=d,c=!0}if((a=t(l.call(this,n[1].trim(),o),o))&&n[0]===e&&"string"!=typeof a)return a;"string"!=typeof a&&(a=Oyt(a)),a||(this.logger.warn("missed to resolve ".concat(n[1]," for nesting ").concat(e)),a=""),c&&(a=s.reduce(function(e,t){return r.format(e,t,i.lng,dbt(dbt({},i),{},{interpolationkey:n[1].trim()}))},a.trim())),e=e.replace(n[0],a),this.regexp.lastIndex=0}return e}}]),e}();function ubt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function pbt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ubt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ubt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function fbt(e){var t={};return function(n,a,r){var i=a+JSON.stringify(r),o=t[i];return o||(o=e(a,r),t[i]=o),o(n)}}var mbt=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};gs(this,e),this.logger=Iyt.create("formatter"),this.options=t,this.formats={number:fbt(function(e,t){var n=new Intl.NumberFormat(e,t);return function(e){return n.format(e)}}),currency:fbt(function(e,t){var n=new Intl.NumberFormat(e,pbt(pbt({},t),{},{style:"currency"}));return function(e){return n.format(e)}}),datetime:fbt(function(e,t){var n=new Intl.DateTimeFormat(e,pbt({},t));return function(e){return n.format(e)}}),relativetime:fbt(function(e,t){var n=new Intl.RelativeTimeFormat(e,pbt({},t));return function(e){return n.format(e,t.range||"day")}}),list:fbt(function(e,t){var n=new Intl.ListFormat(e,pbt({},t));return function(e){return n.format(e)}})},this.init(t)}return ys(e,[{key:"init",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}}).interpolation;this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||","}},{key:"add",value:function(e,t){this.formats[e.toLowerCase().trim()]=t}},{key:"addCached",value:function(e,t){this.formats[e.toLowerCase().trim()]=fbt(t)}},{key:"format",value:function(e,t,n,a){var r=this,i=t.split(this.formatSeparator).reduce(function(e,t){var i=function(e){var t=e.toLowerCase().trim(),n={};if(e.indexOf("(")>-1){var a=e.split("(");t=a[0].toLowerCase().trim();var r=a[1].substring(0,a[1].length-1);"currency"===t&&r.indexOf(":")<0?n.currency||(n.currency=r.trim()):"relativetime"===t&&r.indexOf(":")<0?n.range||(n.range=r.trim()):r.split(";").forEach(function(e){if(e){var t=XQe(e.split(":")),a=t[0],r=t.slice(1).join(":").trim().replace(/^'+|'+$/g,"");n[a.trim()]||(n[a.trim()]=r),"false"===r&&(n[a.trim()]=!1),"true"===r&&(n[a.trim()]=!0),isNaN(r)||(n[a.trim()]=parseInt(r,10))}})}return{formatName:t,formatOptions:n}}(t),o=i.formatName,l=i.formatOptions;if(r.formats[o]){var s=e;try{var c=a&&a.formatParams&&a.formatParams[a.interpolationkey]||{},d=c.locale||c.lng||a.locale||a.lng||n;s=r.formats[o](e,d,pbt(pbt(pbt({},l),a),c))}catch(e){r.logger.warn(e)}return s}return r.logger.warn("there was no format function for ".concat(o)),e},e);return i}}]),e}();function vbt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function gbt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vbt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vbt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function wbt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}var ybt=function(){CQe(t,Dyt);var e=wbt(t);function t(n,a,r){var i,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return gs(this,t),i=e.call(this),Ryt&&Dyt.call(qn(i)),i.backend=n,i.store=a,i.services=r,i.languageUtils=r.languageUtils,i.options=o,i.logger=Iyt.create("backendConnector"),i.waitingReads=[],i.maxParallelReads=o.maxParallelReads||10,i.readingCalls=0,i.maxRetries=o.maxRetries>=0?o.maxRetries:5,i.retryTimeout=o.retryTimeout>=1?o.retryTimeout:350,i.state={},i.queue=[],i.backend&&i.backend.init&&i.backend.init(r,o.backend,o),i}return ys(t,[{key:"queueLoad",value:function(e,t,n,a){var r=this,i={},o={},l={},s={};return e.forEach(function(e){var a=!0;t.forEach(function(t){var l="".concat(e,"|").concat(t);!n.reload&&r.store.hasResourceBundle(e,t)?r.state[l]=2:r.state[l]<0||(1===r.state[l]?void 0===o[l]&&(o[l]=!0):(r.state[l]=1,a=!1,void 0===o[l]&&(o[l]=!0),void 0===i[l]&&(i[l]=!0),void 0===s[t]&&(s[t]=!0)))}),a||(l[e]=!0)}),(Object.keys(i).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:a}),{toLoad:Object.keys(i),pending:Object.keys(o),toLoadLanguages:Object.keys(l),toLoadNamespaces:Object.keys(s)}}},{key:"loaded",value:function(e,t,n){var a=e.split("|"),r=a[0],i=a[1];t&&this.emit("failedLoading",r,i,t),n&&this.store.addResourceBundle(r,i,n),this.state[e]=t?-1:2;var o={};this.queue.forEach(function(n){!function(e,t,n,a){var r=Lyt(e,t,Object),i=r.obj,o=r.k;i[o]=i[o]||[],a&&(i[o]=i[o].concat(n)),a||i[o].push(n)}(n.loaded,[r],i),function(e,t){void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)}(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(function(e){o[e]||(o[e]={});var t=n.loaded[e];t.length&&t.forEach(function(t){void 0===o[e][t]&&(o[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",o),this.queue=this.queue.filter(function(e){return!e.done})}},{key:"read",value:function(e,t,n){var a=this,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,o=arguments.length>5?arguments[5]:void 0;return e.length?this.readingCalls>=this.maxParallelReads?void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:i,callback:o}):(this.readingCalls++,this.backend[n](e,t,function(l,s){if(a.readingCalls--,a.waitingReads.length>0){var c=a.waitingReads.shift();a.read(c.lng,c.ns,c.fcName,c.tried,c.wait,c.callback)}l&&s&&r<a.maxRetries?setTimeout(function(){a.read.call(a,e,t,n,r+1,2*i,o)},i):o(l,s)})):o(null,{})}},{key:"prepareLoading",value:function(e,t){var n=this,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();"string"==typeof e&&(e=this.languageUtils.toResolveHierarchy(e)),"string"==typeof t&&(t=[t]);var i=this.queueLoad(e,t,a,r);if(!i.toLoad.length)return i.pending.length||r(),null;i.toLoad.forEach(function(e){n.loadOne(e)})}},{key:"load",value:function(e,t,n){this.prepareLoading(e,t,{},n)}},{key:"reload",value:function(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}},{key:"loadOne",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",a=e.split("|"),r=a[0],i=a[1];this.read(r,i,"read",void 0,void 0,function(a,o){a&&t.logger.warn("".concat(n,"loading namespace ").concat(i," for language ").concat(r," failed"),a),!a&&o&&t.logger.log("".concat(n,"loaded namespace ").concat(i," for language ").concat(r),o),t.loaded(e,a,o)})}},{key:"saveMissing",value:function(e,t,n,a,r){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t)?this.logger.warn('did not save key "'.concat(n,'" as the namespace "').concat(t,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!"):null!=n&&""!==n&&(this.backend&&this.backend.create&&this.backend.create(e,t,n,a,null,gbt(gbt({},i),{},{isUpdate:r})),e&&e[0]&&this.store.addResource(e[0],t,n,a))}}]),t}();function bbt(e){return"string"==typeof e.ns&&(e.ns=[e.ns]),"string"==typeof e.fallbackLng&&(e.fallbackLng=[e.fallbackLng]),"string"==typeof e.fallbackNS&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function xbt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Ebt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?xbt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xbt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function kbt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}function Mbt(){}var Sbt=function(){CQe(t,Dyt);var e=kbt(t);function t(){var n,a,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=arguments.length>1?arguments[1]:void 0;if(gs(this,t),n=e.call(this),Ryt&&Dyt.call(qn(n)),n.options=bbt(r),n.services={},n.logger=Iyt,n.modules={external:[]},a=qn(n),Object.getOwnPropertyNames(Object.getPrototypeOf(a)).forEach(function(e){"function"==typeof a[e]&&(a[e]=a[e].bind(a))}),i&&!n.isInitialized&&!r.isClone){if(!n.options.initImmediate)return n.init(r,i),IQe(n,qn(n));setTimeout(function(){n.init(r,i)},0)}return n}return ys(t,[{key:"init",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;"function"==typeof t&&(n=t,t={}),!t.defaultNS&&!1!==t.defaultNS&&t.ns&&("string"==typeof t.ns?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));var a={debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(e){var t={};if("object"===fs(e[1])&&(t=e[1]),"string"==typeof e[1]&&(t.defaultValue=e[1]),"string"==typeof e[2]&&(t.tDescription=e[2]),"object"===fs(e[2])||"object"===fs(e[3])){var n=e[3]||e[2];Object.keys(n).forEach(function(e){t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:function(e,t,n,a){return e},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}};function r(e){return e?"function"==typeof e?new e:e:null}if(this.options=Ebt(Ebt(Ebt({},a),this.options),bbt(t)),"v1"!==this.options.compatibilityAPI&&(this.options.interpolation=Ebt(Ebt({},a.interpolation),this.options.interpolation)),void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator),!this.options.isClone){var i;this.modules.logger?Iyt.init(r(this.modules.logger),this.options):Iyt.init(null,this.options),this.modules.formatter?i=this.modules.formatter:"undefined"!=typeof Intl&&(i=mbt);var o=new abt(this.options);this.store=new Kyt(this.options.resources,this.options);var l=this.services;l.logger=Iyt,l.resourceStore=this.store,l.languageUtils=o,l.pluralResolver=new sbt(o,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!i||this.options.interpolation.format&&this.options.interpolation.format!==a.interpolation.format||(l.formatter=r(i),l.formatter.init(l,this.options),this.options.interpolation.format=l.formatter.format.bind(l.formatter)),l.interpolator=new hbt(this.options),l.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},l.backendConnector=new ybt(r(this.modules.backend),l.resourceStore,l,this.options),l.backendConnector.on("*",function(t){for(var n=arguments.length,a=new Array(n>1?n-1:0),r=1;r<n;r++)a[r-1]=arguments[r];e.emit.apply(e,[t].concat(a))}),this.modules.languageDetector&&(l.languageDetector=r(this.modules.languageDetector),l.languageDetector.init(l,this.options.detection,this.options)),this.modules.i18nFormat&&(l.i18nFormat=r(this.modules.i18nFormat),l.i18nFormat.init&&l.i18nFormat.init(this)),this.translator=new tbt(this.services,this.options),this.translator.on("*",function(t){for(var n=arguments.length,a=new Array(n>1?n-1:0),r=1;r<n;r++)a[r-1]=arguments[r];e.emit.apply(e,[t].concat(a))}),this.modules.external.forEach(function(t){t.init&&t.init(e)})}if(this.format=this.options.interpolation.format,n||(n=Mbt),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var s=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);s.length>0&&"dev"!==s[0]&&(this.options.lng=s[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(function(t){e[t]=function(){var n;return(n=e.store)[t].apply(n,arguments)}});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(function(t){e[t]=function(){var n;return(n=e.store)[t].apply(n,arguments),e}});var c=Nyt(),d=function(){var t=function(t,a){e.isInitialized&&!e.initializedStoreOnce&&e.logger.warn("init: i18next is already initialized. You should call init just once!"),e.isInitialized=!0,e.options.isClone||e.logger.log("initialized",e.options),e.emit("initialized",e.options),c.resolve(a),n(t,a)};if(e.languages&&"v1"!==e.options.compatibilityAPI&&!e.isInitialized)return t(null,e.t.bind(e));e.changeLanguage(e.options.lng,t)};return this.options.resources||!this.options.initImmediate?d():setTimeout(d,0),c}},{key:"loadResources",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Mbt,a="string"==typeof e?e:this.language;if("function"==typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(a&&"cimode"===a.toLowerCase())return n();var r=[],i=function(e){e&&t.services.languageUtils.toResolveHierarchy(e).forEach(function(e){r.indexOf(e)<0&&r.push(e)})};if(a)i(a);else this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(function(e){return i(e)});this.options.preload&&this.options.preload.forEach(function(e){return i(e)}),this.services.backendConnector.load(r,this.options.ns,function(e){e||t.resolvedLanguage||!t.language||t.setResolvedLanguage(t.language),n(e)})}else n(null)}},{key:"reloadResources",value:function(e,t,n){var a=Nyt();return e||(e=this.languages),t||(t=this.options.ns),n||(n=Mbt),this.services.backendConnector.reload(e,t,function(e){a.resolve(),n(e)}),a}},{key:"use",value:function(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&Qyt.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}},{key:"setResolvedLanguage",value:function(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(var t=0;t<this.languages.length;t++){var n=this.languages[t];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}},{key:"changeLanguage",value:function(e,t){var n=this;this.isLanguageChangingTo=e;var a=Nyt();this.emit("languageChanging",e);var r=function(e){n.language=e,n.languages=n.services.languageUtils.toResolveHierarchy(e),n.resolvedLanguage=void 0,n.setResolvedLanguage(e)},i=function(i){e||i||!n.services.languageDetector||(i=[]);var o="string"==typeof i?i:n.services.languageUtils.getBestMatchFromCodes(i);o&&(n.language||r(o),n.translator.language||n.translator.changeLanguage(o),n.services.languageDetector&&n.services.languageDetector.cacheUserLanguage(o)),n.loadResources(o,function(e){!function(e,i){i?(r(i),n.translator.changeLanguage(i),n.isLanguageChangingTo=void 0,n.emit("languageChanged",i),n.logger.log("languageChanged",i)):n.isLanguageChangingTo=void 0,a.resolve(function(){return n.t.apply(n,arguments)}),t&&t(e,function(){return n.t.apply(n,arguments)})}(e,o)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect(i):i(e):i(this.services.languageDetector.detect()),a}},{key:"getFixedT",value:function(e,t,n){var a=this,r=function e(t,r){var i;if("object"!==fs(r)){for(var o=arguments.length,l=new Array(o>2?o-2:0),s=2;s<o;s++)l[s-2]=arguments[s];i=a.options.overloadTranslationOptionHandler([t,r].concat(l))}else i=Ebt({},r);i.lng=i.lng||e.lng,i.lngs=i.lngs||e.lngs,i.ns=i.ns||e.ns,i.keyPrefix=i.keyPrefix||n||e.keyPrefix;var c=a.options.keySeparator||".",d=i.keyPrefix?"".concat(i.keyPrefix).concat(c).concat(t):t;return a.t(d,i)};return"string"==typeof e?r.lng=e:r.lngs=e,r.ns=t,r.keyPrefix=n,r}},{key:"t",value:function(){var e;return this.translator&&(e=this.translator).translate.apply(e,arguments)}},{key:"exists",value:function(){var e;return this.translator&&(e=this.translator).exists.apply(e,arguments)}},{key:"setDefaultNamespace",value:function(e){this.options.defaultNS=e}},{key:"hasLoadedNamespace",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var a=this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,i=this.languages[this.languages.length-1];if("cimode"===a.toLowerCase())return!0;var o=function(e,n){var a=t.services.backendConnector.state["".concat(e,"|").concat(n)];return-1===a||2===a};if(n.precheck){var l=n.precheck(this,o);if(void 0!==l)return l}return!!this.hasResourceBundle(a,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!o(a,e)||r&&!o(i,e)))}},{key:"loadNamespaces",value:function(e,t){var n=this,a=Nyt();return this.options.ns?("string"==typeof e&&(e=[e]),e.forEach(function(e){n.options.ns.indexOf(e)<0&&n.options.ns.push(e)}),this.loadResources(function(e){a.resolve(),t&&t(e)}),a):(t&&t(),Promise.resolve())}},{key:"loadLanguages",value:function(e,t){var n=Nyt();"string"==typeof e&&(e=[e]);var a=this.options.preload||[],r=e.filter(function(e){return a.indexOf(e)<0});return r.length?(this.options.preload=a.concat(r),this.loadResources(function(e){n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}},{key:"dir",value:function(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(this.services.languageUtils.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Mbt,r=Ebt(Ebt(Ebt({},this.options),n),{isClone:!0}),i=new t(r);void 0===n.debug&&void 0===n.prefix||(i.logger=i.logger.clone(n));return["store","services","language"].forEach(function(t){i[t]=e[t]}),i.services=Ebt({},this.services),i.services.utils={hasLoadedNamespace:i.hasLoadedNamespace.bind(i)},i.translator=new tbt(i.services,i.options),i.translator.on("*",function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),a=1;a<t;a++)n[a-1]=arguments[a];i.emit.apply(i,[e].concat(n))}),i.init(r,a),i.translator.options=i.options,i.translator.backendConnector.services.utils={hasLoadedNamespace:i.hasLoadedNamespace.bind(i)},i}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),t}();vs(Sbt,"createInstance",function(){return new Sbt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0)});var Abt=Sbt.createInstance();Abt.createInstance=Sbt.createInstance,Abt.createInstance,Abt.init,Abt.loadResources,Abt.reloadResources,Abt.use,Abt.changeLanguage,Abt.getFixedT;var _bt=Abt.t;Abt.exists,Abt.setDefaultNamespace,Abt.hasLoadedNamespace,Abt.loadNamespaces,Abt.loadLanguages;var Cbt=function(e){void 0===e&&(e=new Date);var t=e.getDay(),n=0===t?-6:1-t,a=new Date(e);return a.setDate(e.getDate()+n),a},Zbt=function(e){void 0===e&&(e=new Date);var t=e.getDay(),n=0===t?0:7-t,a=new Date(e);return a.setDate(e.getDate()+n),a},Hbt=function(){var e=new Date,t=e.getFullYear(),n=e.getMonth(),a=e.getDate();return[{value:0,label:"Tùy chọn",type:[]},{value:1,label:"Năm hiện tại",type:[new Date(t,0,1),new Date(t+1,0,0)]},{value:2,label:"Quý hiện tại",type:[new Date(t,3*Math.floor(n/3),1),new Date(t,3*Math.floor(n/3)+3,0)]},{value:3,label:"Tháng hiện tại",type:[new Date(t,n,1),new Date(t,n+1,0)]},{value:4,label:"30 ngày trước",type:[new Date(t,n,a-30),new Date]},{value:5,label:"30 ngày sau",type:[new Date,new Date(t,n,a+30)]},{value:6,label:"Tuần hiện tại",type:[Cbt(),Zbt()]},{value:7,label:"Ngày hiện tại",type:[new Date,new Date]},{value:8,label:"Năm trước",type:[new Date(t-1,0,1),new Date(t,0,0)]},{value:9,label:"Quý trước",type:[new Date(t,3*Math.floor(n/3-1),1),new Date(t,3*Math.floor(n/3-1)+3,0)]},{value:10,label:"Tháng trước",type:[new Date(t,n-1,1),new Date(t,n,0)]},{value:11,label:"Tháng sau",type:[new Date(t,n+1,1),new Date(t,n+2,0)]},{value:12,label:"Tuần trước",type:[Cbt(new Date(t,n,a-7)),Zbt(new Date(t,n,a-7))]},{value:13,label:"Tuần sau",type:[Cbt(new Date(t,n,a+7)),Zbt(new Date(t,n,a+7))]},{value:14,label:"Ngày trước",type:[new Date(t,n,a-1),new Date(t,n,a-1)]}]};exports.ExternalInterface=Zut,exports.ExternalInterfaceExtend=function(t){var n,a,r,i,o,l,s,d=t.toolbarTemplate,h=t.paramToolbar,u=t.currentPageDefault,p=t.queryOrderDefault,m=t.rowsPerPageDefault,v=t.queryKeyDataView,g=t.isSelectMulti,w=t.canContextMenuItems,y=t.handleContextMenuClick,b=t.rowSelected,x=t.dataSourceFilter,E=t.listContextHide,M=t.querySelectDefault,_=t.api,C=t.t,Z=t.contextMenuOpen,H=t.stateId,I=t.viewIdTable,D=t.height,N=t.hasIndex,O=t.dataSelected,L=t.showColumnChoose,V=t.typeCheckbox,z=t.format,P=t.rowSelection,T=t.dataSource,B=t.columns,j=t.totalCount,W=t.breakText,R=t.allowPaging,F=t.allowResizing,Y=t.showUltilities,q=t.handleDoubleContextMenuClick,U=t.stateChildId,G=t.titleChild,X=t.loading,J=t.checkInitSub,$=t.checkInit,ee=t.hasWorkflow,te=t.apiWorkflow,ne=t.rowClassName,ae=t.printApi,re=t.allowFilterClient,ie=t.ultilities,oe=t.summary,le=t.hideSelectAll,se=t.onChangeParam,ce=t.showToolbar,de=t.initAbility,he=t.pageSizeOptions,ue=t.onDataChange,pe=t.group,fe=t.onChangeTabChildren,me=null!=D?D:500,ve=[1,0],ge=[.5,.5],we=e.useState(ve),ye=we[0],be=we[1],xe=e.useState(me),Ee=xe[0],ke=xe[1],Me=e.useState(0),Se=Me[0],Ae=Me[1],_e=e.useState(0),Ce=_e[0],Ze=_e[1],He=e.useState({}),Ie=He[0],De=He[1],Ne=e.useState({}),Oe=Ne[0],Le=Ne[1],Ve=e.useState({}),ze=Ve[0],Pe=Ve[1],Te=e.useState({}),Be=Te[0],je=Te[1],We=Q(null==Ie?void 0:Ie.file)?"[]":null==Ie?void 0:Ie.file,Re=function(){be(ge),ke(me/2),Ae(me/2)},Fe=function(){Ze(0),fe&&fe(0),be(ve),ke(me),Ae(0)};e.useEffect(function(){je(k(k({},Be),ze))},[ze]),e.useEffect(function(){0===(null==ye?void 0:ye[1])&&(Ze(0),fe&&fe(0))},[null==ye?void 0:ye[1]]);var Ye=function(){return{innerWidth:window.innerWidth,innerHeight:window.innerHeight}},qe=e.useState(Ye()),Ue=qe[0],Ge=qe[1];e.useEffect(function(){var e=function(){Ge(Ye())};return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}},[]);var Ke=e.useState({}),Qe=Ke[0],Xe=Ke[1],Je=(null!==(n=null==U?void 0:U.filter(function(e){return K(e.columns)}).map(function(e){return e.stateId}))&&void 0!==n?n:[]).join();return e.useEffect(function(){Q(Je)||function(e){S(void 0,void 0,void 0,function(){var t,n,a,r,i,o,l,s;return A(this,function(c){switch(c.label){case 0:return[4,mi({ParaJson:JSON.stringify({ViewId:e})})];case 1:return t=c.sent(),n=JSON.parse(null!==(o=null===(i=null==t?void 0:t[0])||void 0===i?void 0:i.dataJson)&&void 0!==o?o:"[]"),a=JSON.parse(null!==(s=null===(l=null==n?void 0:n[0])||void 0===l?void 0:l.Data)&&void 0!==s?s:"[]"),r={},null==U||U.forEach(function(e){var t,n=a.filter(function(t){var n,a;return(null!==(n=null==t?void 0:t.ViewId)&&void 0!==n?n:"").toLowerCase()===(null!==(a=null==e?void 0:e.stateId)&&void 0!==a?a:"").toLowerCase()});r[e.stateId]=yi([],C,{hasIndex:null===(t=null==e?void 0:e.hasIndex)||void 0===t||t,breakText:null==e?void 0:e.breakText,hasWorkflow:!1,levelGroup:0,responseColumn:n})}),Xe(r),[2]}})})}(Je)},[Je]),f.default.createElement("div",{style:{height:"".concat(Ue.innerHeight-180,"px")}},f.default.createElement(Put,{orientation:"horizontal"},f.default.createElement(dpt,{flex:ye[0],minSize:0,onStopResize:function(e){var t=e.domElement.clientHeight;ke(t),Ae(me-t)},style:{}},f.default.createElement("div",{className:"pane-content",id:"reflex-top"},f.default.createElement("div",{onMouseUp:function(e){2===(null==e?void 0:e.button)&&Fe()}},f.default.createElement(Zut,{windowSize:Ue,showColumnChoose:L,isSelectMulti:g,dataSourceFilter:x,totalCount:j,dataSource:T,columns:B,rowSelection:P,format:z,stateId:H,stateChildId:U,height:Ee-5,viewIdTable:I,currentPageDefault:u,rowsPerPageDefault:m,pageSizeOptions:he,queryOrderDefault:p,queryKeyDataView:v,handleContextMenuClick:y,rowSelected:function(e){b&&b(e),function(e){var t;Ze(0),fe&&fe(0);var n=e.rowData;n&&!e.rightClick&&U&&(null==U?void 0:U.length)>0&&K(null==n?void 0:n.field)&&(De(e.rowData),Re()),(0===(null===(t=e.selected)||void 0===t?void 0:t.length)||e.rightClick)&&(De({}),Fe())}(e)},group:pe,allowPaging:R,allowResizing:F,listContextHide:E,querySelectDefault:M,contextMenuOpen:Z,canContextMenuItems:w,typeCheckbox:V,t:C,api:_,toolbarTemplate:d,paramToolbar:h,hasIndex:N,breakText:W,dataSelected:O,handleDoubleContextMenuClick:q,loading:X,checkInit:$,checkInitSub:J,hasWorkflow:ee,apiWorkflow:te,rowClassName:ne,printApi:ae,showUltilities:Y,allowFilterClient:re,summary:oe,hideSelectAll:le,ultilities:ie,onChangeParam:se,showToolbar:ce,initAbility:de,onDataChange:ue})))),U&&U.length>0&&f.default.createElement(Vut,{style:{display:0===ye[1]?"none":"block"}}),U&&U.length>0&&f.default.createElement(dpt,{flex:ye[1],style:{height:"".concat(me-Ee-150,"px")},minSize:0},f.default.createElement(Tut,{className:"handle"},f.default.createElement("div",{style:{marginTop:"5px",marginBottom:"0px",paddingBottom:"5px"},className:"d-flex justify-content-between align-items-center bb-1"},f.default.createElement("h5",{className:"m-0"},G),f.default.createElement("div",{className:"me-auto ms-1 d-flex align-items-center"},(null===(a=null==U?void 0:U[Ce])||void 0===a?void 0:a.buttons)&&(null===(i=null===(r=null==U?void 0:U[Ce])||void 0===r?void 0:r.buttons)||void 0===i?void 0:i.map(function(e,t){var n,a,r,i=oi[null!==(n=e.icon)&&void 0!==n?n:"Plus"];return"right"!==e.align&&!1!==e.visible&&f.default.createElement(Hn,{color:e.color||"primary",onClick:function(){return e.actionClick({rowData:null==Oe?void 0:Oe[Ce]})},disabled:e.disabled,key:t,className:"me-1 d-flex"},f.default.createElement(i,{fontSize:null!==(a=e.fontSize)&&void 0!==a?a:14,className:"me-50"}),String(C(null!==(r=e.title)&&void 0!==r?r:"")))}))),f.default.createElement("div",{className:"ms-auto d-flex align-items-center"},(null===(o=null==U?void 0:U[Ce])||void 0===o?void 0:o.buttons)&&(null===(s=null===(l=null==U?void 0:U[Ce])||void 0===l?void 0:l.buttons)||void 0===s?void 0:s.map(function(e,t){var n,a,r,i=oi[null!==(n=e.icon)&&void 0!==n?n:"Plus"];return"right"===e.align&&!1!==e.visible&&f.default.createElement(Hn,{color:e.color||"primary",onClick:function(){return e.actionClick({rowData:null==Oe?void 0:Oe[Ce]})},disabled:e.disabled,key:t,className:"me-1 d-flex"},f.default.createElement(i,{fontSize:null!==(a=e.fontSize)&&void 0!==a?a:14,className:"me-50"}),String(C(null!==(r=e.title)&&void 0!==r?r:"")))}))),f.default.createElement("span",null,f.default.createElement(ii,{style:{marginRight:5},fontSize:20,onClick:Fe,className:"cursor-pointer"})))),f.default.createElement("div",{className:"pane-content",id:"reflex-bottom",style:{height:"".concat(me-Ee-70,"px")}},f.default.createElement("div",{className:"bg-white p-25",style:{border:"1px solid #e0e0e0"}},f.default.createElement(c.TabComponent,{overflowMode:"Popup",heightAdjustMode:"Auto",className:"m-0",animation:{next:{effect:"None"},previous:{effect:"None"}},selectedItem:Ce,selected:function(e){Ze(e.selectedIndex),fe&&fe(e.selectedIndex)}},f.default.createElement(c.TabItemsDirective,null,null==U?void 0:U.map(function(e,t){var n,a,r,i;return"AttachFile"!==e.stateId?f.default.createElement(c.TabItemDirective,{key:t,headerText:"".concat(C(e.stateName)," (").concat(null!==(a=null!==(n=e.totalCount)&&void 0!==n?n:null==Be?void 0:Be[t])&&void 0!==a?a:0,")")}):f.default.createElement(c.TabItemDirective,{key:t,headerText:"".concat(C(Q(e.stateName)?"File attached":e.stateName)," (").concat(null!==(r=e.totalCount)&&void 0!==r?r:null===(i=Array.isArray(JSON.parse(We))?JSON.parse(We):[])||void 0===i?void 0:i.length,")")})}))),f.default.createElement("div",{className:"box form-box__border d-flex flex-column p-0"},f.default.createElement(jr,{activeTab:Ce},null==U?void 0:U.map(function(e,t){var n,a,r,i,o,l;return K(e.content)?"AttachFile"!==e.stateId?f.default.createElement(qr,{key:t,tabId:t},f.default.createElement(Iut,{index:t,windowSize:Ue,stateChildId:U,titleChild:G,group:e.group,showColumnChoose:!0,showToolbar:!1,format:z,height:Se-95,stateId:null!==(n=e.stateId)&&void 0!==n?n:"",viewIdTable:null!==(a=e.stateId)&&void 0!==a?a:"",dataSource:null!==(r=null==e?void 0:e.dataSource)&&void 0!==r?r:(null==Ie?void 0:Ie.id)?void 0:[],columns:null!==(o=null!==(i=null==e?void 0:e.columns)&&void 0!==i?i:null==Qe?void 0:Qe[e.stateId])&&void 0!==o?o:void 0,totalCount:null==e?void 0:e.totalCount,summary:null===(l=e.summary)||void 0===l||l,onChangeParam:e.onChangeParam,currentPageDefault:u,rowsPerPageDefault:m,pageSizeOptions:he,rowSelected:function(t){e.rowSelected&&e.rowSelected(t),Oe[Ce]=t.selected,Le(Oe)},callback:function(e){setTimeout(function(){Pe(function(n){var a;return k(k({},n),((a={})[t]=e.total,a))})},50*(t+1))},querySelectDefault:e.querySelectDefault,queryKeyDataView:[null==Ie?void 0:Ie.id],allowPaging:e.allowPaging,allowResizing:e.allowResizing,t:C,api:_,hasIndex:!0,breakText:W,loading:X,rowClassName:e.rowClassName,allowFilterClient:!0,typeCheckbox:e.typeCheckbox,onDataChange:e.onDataChange})):"AttachFile"===e.stateId?f.default.createElement(qr,{tabId:t,key:t},f.default.createElement(Dut,{height:Se-80,listFile:We,t:C})):void 0:f.default.createElement(qr,{key:t,tabId:t},e.content instanceof Function?e.content():e.content)}))))))))},exports.HeaderExternalInterface=function(e){var t=e.buttons,n=e.breadCrumb,a=e.CanPer,r=e.t;return f.default.createElement("div",{className:"table-toolbar"},f.default.createElement(ha,{className:"table-bar bar__action"},f.default.createElement(va,null,f.default.createElement("div",{className:"d-flex justify-content-between align-items-center w-100"},f.default.createElement("div",{className:"bar__action-left"},f.default.createElement(hpt,{breadCrumbTitle:n.breadCrumbTitle,breadCrumbActive:r(n.breadCrumbActive),breadCrumbParent:n.breadCrumbParent})),f.default.createElement("div",{className:"bar__action-right d-flex"},t&&t.length>0&&t.map(function(e,t){var n,i,o,l=oi[null!==(n=e.icon)&&void 0!==n?n:"Plus"];return f.default.createElement(a,{I:e.userAction,a:e.userSubject,key:t},f.default.createElement(Hn,{color:e.color||"primary",onClick:e.actionClick,disabled:e.disabled,className:"me-1 d-flex"},f.default.createElement(l,{fontSize:null!==(i=e.fontSize)&&void 0!==i?i:14,className:"me-50"}),String(r(null!==(o=e.title)&&void 0!==o?o:""))))}))))))},exports.ToolbarTemplate=function(e){var t=window.localStorage.getItem("i18nextLng"),n=t||"vi";return zmt.load({vi:{daterangepicker:{placeholder:"Chọn ngày",startLabel:"Ngày bắt đầu",endLabel:"Ngày kết thúc",applyText:"Chọn",cancelText:"Hủy",selectedDays:"Chọn ngày",days:"Ngày",customRange:"Tùy chỉnh"}}}),function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=0,a=e;n<a.length;n++){var r=a[n];bpt($pt,r,{},!0)}}(require("@src/assets/cldr-data/main/".concat(n,"/ca-gregorian.json")),require("@src/assets/cldr-data/main/".concat(n,"/numbers.json")),require("@src/assets/cldr-data/main/".concat(n,"/timeZoneNames.json")),require("@src/assets/supplemental/numberingSystems.json")),eft=n,Jpt.notify("notifyExternalChange",{locale:eft}),e.map(function(e,t){var a,r,i,o,l,s,c,d,u,p,m,v,g,w,y,b,x,E,M,S,A,_,C,Z,H,I,D,N,O,L=null!==(a=e.option)&&void 0!==a?a:[],V=function(e,t){for(var n,a=0;a<e.length;a++){var r=e[a];if(r[r.fieldValue?r.fieldValue:"value"]===t)return k({},r);if((null===(n=r.children)||void 0===n?void 0:n.length)>0){var i=V(r.children,t);if(i)return i}}};return{template:f.default.createElement("div",{key:t,className:"me-50",style:{width:null!==(r=e.width)&&void 0!==r?r:"listDate"===e.type?220:200},title:_bt(null!==(i=e.placeholder)&&void 0!==i?i:"")},"daterange"===e.type&&f.default.createElement(Ayt,{id:"daterangepicker",placeholder:e.t(null!==(o=e.placeholder)&&void 0!==o?o:""),startDate:!K(e.data)&&(null===(l=e.data)||void 0===l?void 0:l.length)>0?e.data[0]:void 0,endDate:!K(e.data)&&(null===(s=e.data)||void 0===s?void 0:s.length)>0?e.data[1]:void 0,format:z.dateFormat,onChange:function(t){var n,a;K(null===(n=t.target)||void 0===n?void 0:n.value)?e.setData([]):e.setData(null===(a=t.target)||void 0===a?void 0:a.value)},openOnFocus:!0,locale:n}),"listDate"===e.type&&(0===(null===(c=e.data)||void 0===c?void 0:c.value)?f.default.createElement(Ayt,{id:"daterangepicker",placeholder:e.t(null!==(d=e.placeholder)&&void 0!==d?d:""),startDate:!K(null===(u=e.data)||void 0===u?void 0:u.type)&&(null===(m=null===(p=e.data)||void 0===p?void 0:p.type)||void 0===m?void 0:m.length)>0?null===(g=null===(v=e.data)||void 0===v?void 0:v.type)||void 0===g?void 0:g[0]:void 0,endDate:!K(null===(w=e.data)||void 0===w?void 0:w.type)&&(null===(b=null===(y=e.data)||void 0===y?void 0:y.type)||void 0===b?void 0:b.length)>0?null===(E=null===(x=e.data)||void 0===x?void 0:x.type)||void 0===E?void 0:E[1]:void 0,format:z.dateFormat,onChange:function(t){var n,a;K(null===(n=t.target)||void 0===n?void 0:n.value)?e.setData({}):e.setData(k(k({},e.data),{type:null===(a=t.target)||void 0===a?void 0:a.value}))},openOnFocus:!0,locale:n}):f.default.createElement(h.SelectTable,{onChange:function(t){var n;0===(null==t?void 0:t.value)?e.setData({value:t.value,type:null===(n=e.data)||void 0===n?void 0:n.type}):e.setData(t)},isClearable:!0,options:Hbt(),value:Hbt().find(function(t){var n;return t.value===(null===(n=e.data)||void 0===n?void 0:n.value)}),placeholder:_bt(null!==(M=e.placeholder)&&void 0!==M?M:"")})),"select"===e.type&&f.default.createElement(h.SelectTable,{value:e.isMulti?Array.isArray(e.data)&&e.data.length>0?L.filter(function(t){return Array.isArray(e.data)&&e.data.some(function(n){var a;return t[null!==(a=e.fieldValue)&&void 0!==a?a:"value"]===n})}):[]:K(e.data)?void 0:L.find(function(t){var n;return t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"]===e.data}),onChange:function(t){var n,a,r;e.isMulti&&(K(t)||0===(null==t?void 0:t.length))?e.setData([]):!e.isMulti&&K(t)?e.setData(void 0):(e.isMulti||JSON.stringify(t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"])!==JSON.stringify(e.data))&&(e.isMulti?e.setData((null!==(a=null==t?void 0:t.length)&&void 0!==a?a:0)>0?t.map(function(t){var n;return t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"]}):[]):e.setData(K(t)?void 0:t[null!==(r=e.fieldValue)&&void 0!==r?r:"value"]))},fieldValue:null!==(S=e.fieldValue)&&void 0!==S?S:"value",fieldLabel:null!==(A=e.fieldLabel)&&void 0!==A?A:"label",placeholder:e.t(null!==(_=e.placeholder)&&void 0!==_?_:""),isMulti:null!==(C=e.isMulti)&&void 0!==C&&C,options:L,isClearable:null===(Z=e.isClearable)||void 0===Z||Z,columns:e.columns,loadOptions:e.loadOption}),"selecttree"===e.type&&f.default.createElement(h.SelectTableTree,{value:(e.isMulti?(null===(H=e.data)||void 0===H?void 0:H.length)>0:!K(e.data))?e.isMulti?e.data:V(L,e.data):e.isMulti?[]:void 0,onChange:function(t){var n;(e.isMulti||(e.fieldValue&&t?t[e.fieldValue]:null==t?void 0:t.value)!==e.data)&&(e.isMulti?e.setData(K(t)?[]:t):e.setData(K(t)?void 0:t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"]))},columns:null!==(I=e.columns)&&void 0!==I?I:me,placeholder:e.t(null!==(D=e.placeholder)&&void 0!==D?D:""),options:null!=L?L:[],isMulti:null!==(N=e.isMulti)&&void 0!==N&&N,isClearable:!0})),position:null!==(O=e.position)&&void 0!==O?O:"left"}})},exports.listFilterDate=Hbt,exports.renderColumnTable=function(e,t,n){var a,r,i,o,l,s,c,d=JSON.parse(null!==(r=null===(a=null==e?void 0:e[0])||void 0===a?void 0:a.dataJson)&&void 0!==r?r:"[]"),h=JSON.parse(null===(i=null==d?void 0:d[0])||void 0===i?void 0:i.Data),u={Data:null==h?void 0:h.filter(function(e){return!0===(null==e?void 0:e.IsActive)})},p=[];n&&p.push({width:60,type:"number",freeze:"Left",field:"STT",textAlign:"center",headerText:"STT",allowFiltering:!1,allowSorting:!1});for(var f=function(e){var n=u.Data[e],a={field:n.ColVirtual,headerText:n.Title,visible:!n.IsHidden,width:n.Width,maxWidth:null!==(o=n.MaxWidth)&&void 0!==o?o:n.Width,minWidth:null!==(l=n.MinWidth)&&void 0!==l?l:n.Width,allowSorting:!0,clipMode:"EllipsisWithTooltip",freeze:n.Freeze,textAlign:n.TextAlign};switch(n.Type){case"datetime":a.typeFilter="DateRange",a.template=J,a.type="datetime",a.hideOperator=!0;break;case"date":a.hideOperator=!0,a.typeFilter="DateRange",a.template=J,a.type="date";break;case"checkbox":a.hideOperator=!0,a.typeFilter="Checkbox";break;case"number":a.typeFilter="Number",a.type="number",Q(n.TypeDecimal)||"quantity"===n.TypeDecimal?a.template=oe:"allocationRatio"===n.TypeDecimal?a.template=pe:"exchangeMoney"===n.TypeDecimal?a.template=se:"overseaMoney"===n.TypeDecimal?a.template=le:"rate"===n.TypeDecimal?a.template=he:"ratio"===n.TypeDecimal?a.template=ue:"so_cong"===n.TypeDecimal?a.template=fe:"unitPriceExchange"===n.TypeDecimal?a.template=ce:"unitPriceOversea"===n.TypeDecimal?a.template=de:a.template="";break;default:a.type="string"}!Q(n.ColTemplate)&&Q(n.OptionTemplate)&&(a.template=function(e){var a;return t(null==e?void 0:e[null!==(a=n.ColTemplate)&&void 0!==a?a:""])}),Q(n.ColTemplate)||Q(n.OptionTemplate)||(a.source=null===(c=JSON.parse(null!==(s=n.OptionTemplate)&&void 0!==s?s:"[]"))||void 0===c?void 0:c.map(function(e){var n,a;return k(k({},e),{value:null!==(n=null==e?void 0:e.value)&&void 0!==n?n:null==e?void 0:e.id,label:t(null!==(a=e.label)&&void 0!==a?a:null==e?void 0:e.name)})}),a.template=function(e){var t,r;return null===(r=null===(t=a.source)||void 0===t?void 0:t.find(function(t){var a;return(null==t?void 0:t.value)===(null==e?void 0:e[null!==(a=n.ColTemplate)&&void 0!==a?a:""])}))||void 0===r?void 0:r.label}),0===e&&"checkbox"===n.Type?p.unshift({width:40,type:"checkbox",freeze:"Left"}):("id"===n.ColVirtual&&(a.isPrimaryKey=!0),p.push(a))},m=0;m<u.Data.length;m++)f(m);return p},exports.renderColumnTableBe=function(e,t,n,a){var r,i,o,l,s=JSON.parse(null!==(i=null===(r=null==e?void 0:e[0])||void 0===r?void 0:r.dataJson)&&void 0!==i?i:"[]"),c=JSON.parse(null!==(l=null===(o=null==s?void 0:s[0])||void 0===o?void 0:o.Data)&&void 0!==l?l:"[]"),d={Data:null==c?void 0:c.filter(function(e){return!0===(null==e?void 0:e.IsActive)})},h={};return n.forEach(function(e){for(var n,r,i,o,l,s,c,u=d.Data.filter(function(t){return t.ViewId===e}),p=[],f=function(e){var d=u[e],h={field:null!==(n=d.ColVirtual)&&void 0!==n?n:"",headerText:d.Title,visible:!d.IsHidden,width:d.Width,maxWidth:null!==(r=d.MaxWidth)&&void 0!==r?r:d.Width,minWidth:null!==(i=d.MinWidth)&&void 0!==i?i:d.Width,allowFiltering:!0,allowSorting:!0,textAlign:null!==(o=d.TextAlign)&&void 0!==o?o:"left",fixedType:Q(d.Freeze)?void 0:(null!==(l=d.Freeze)&&void 0!==l?l:"").toLowerCase()};switch(d.Type){case"datetime":h.typeFilter="DateRange",h.type="datetime";break;case"date":h.typeFilter="DateRange",h.type="date";break;case"checkbox":h.typeFilter="Checkbox",h.type="checkbox",h.hideOperator=!0;break;case"number":h.typeFilter="Number",h.type="number",Q(d.TypeDecimal)||"quantity"===d.TypeDecimal?h.format={decimalScale:ae("quantity")}:h.format={decimalScale:ae(Q(d.TypeDecimal)?"quantity":d.TypeDecimal)};break;default:h.type="string"}!Q(d.ColTemplate)&&Q(d.OptionTemplate)&&(h.template=function(e){var n;return t(null==e?void 0:e[null!==(n=d.ColTemplate)&&void 0!==n?n:""])}),Q(d.ColTemplate)||Q(d.OptionTemplate)||(h.source=null===(c=JSON.parse(null!==(s=d.OptionTemplate)&&void 0!==s?s:"[]"))||void 0===c?void 0:c.map(function(e){var n,a;return k(k({},e),{value:null!==(n=null==e?void 0:e.value)&&void 0!==n?n:null==e?void 0:e.id,label:t(null!==(a=e.label)&&void 0!==a?a:null==e?void 0:e.name)})}),h.template=function(e){var t,n;return null===(n=null===(t=h.source)||void 0===t?void 0:t.find(function(t){var n;return(null==t?void 0:t.value)===(null==e?void 0:e[null!==(n=d.ColTemplate)&&void 0!==n?n:""])}))||void 0===n?void 0:n.label}),0===e&&"checkbox"===d.Type?(p.push({width:40,field:"checkbox",fixedType:"left"}),p.push({field:"",headerText:"STT",textAlign:"center",headerTextAlign:"center",template:function(e){return e.indexRow+1},fixedType:"left",visible:a,width:50,minWidth:50,maxWidth:50})):(0===e&&p.push({field:"",headerText:"STT",textAlign:"center",headerTextAlign:"center",template:function(e){return e.indexRow+1},fixedType:"left",visible:a,width:50,minWidth:50,maxWidth:50}),p.push(h))},m=0;m<u.length;m++)f(m);h[e]=p}),h},exports.renderColumnTableGrid=yi;
646
+ return Out.isBrowser()&&!!document.documentMode}static isEdge(){return Out.isBrowser()&&!Out.isIE()&&!!window.StyleMedia}static isChrome(){return Out.isBrowser()&&!!window.chrome&&!!window.chrome.webstore}static isBlink(){return Out.isBrowser()&&(Out.isChrome()||Out.isOpera())&&!!window.CSS}static getUserAgent(){return"undefined"==typeof navigator?"":navigator.userAgent}static isAndroid(){return Out.isBrowser()&&Out.getUserAgent().match(/Android/i)}static isBlackBerry(){return Out.isBrowser()&&Out.getUserAgent().match(/BlackBerry/i)}static isIOS(){return Out.isBrowser()&&Out.getUserAgent().match(/iPhone|iPad|iPod/i)}static isOpera(){return Out.isBrowser()&&Out.getUserAgent().match(/Opera Mini/i)}static isWindows(){return Out.isBrowser()&&Out.isWindowsDesktop()||Out.isWindowsMobile()}static isWindowsMobile(){return Out.isBrowser()&&Out.getUserAgent().match(/IEMobile/i)}static isWindowsDesktop(){return Out.isBrowser()&&Out.getUserAgent().match(/WPDesktop/i)}static isMobile(){return Out.isBrowser()&&(Out.isWindowsMobile()||Out.isBlackBerry()||Out.isAndroid()||Out.isIOS())}}const Lut=e=>Object.keys(e).reduce((t,n)=>"data-"===n.substr(0,5)?Nut({},t,{[n]:e[n]}):t,{});class Vut extends f.default.Component{static isA(e){return!!e&&e.type===f.default.createElement(Vut,null).type}constructor(e){super(e),vs(this,"ref",f.default.createRef()),vs(this,"onMouseMove",e=>{if(this.state.active){const t=this.ref.current;this.props.events.emit("resize",{index:this.props.index,domElement:t,event:e}),this.props.onResize&&this.props.onResize({component:this,domElement:t}),e.stopPropagation(),e.preventDefault()}}),vs(this,"onMouseDown",e=>{this.setState({active:!0}),this.props.onStartResize&&this.props.onStartResize({domElement:this.ref.current,component:this})||this.props.events.emit("startResize",{index:this.props.index,event:e})}),vs(this,"onMouseUp",e=>{this.state.active&&(this.setState({active:!1}),this.props.onStopResize&&this.props.onStopResize({domElement:this.ref.current,component:this}),this.props.events.emit("stopResize",{index:this.props.index,event:e}))}),this.state={active:!1},this.document=e.document}componentDidMount(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}componentWillUnmount(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}render(){const e=[Out.isMobile()?"reflex-thin":"",...this.props.className.split(" "),this.state.active?"active":"","reflex-splitter"].join(" ").trim();return f.default.createElement("div",In({},Lut(this.props),{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id,ref:this.ref}),this.props.children)}}vs(Vut,"propTypes",{children:gt.oneOfType([gt.arrayOf(gt.node),gt.node]),onStartResize:gt.func,onStopResize:gt.func,className:gt.string,propagate:gt.bool,onResize:gt.func,style:gt.object}),vs(Vut,"defaultProps",{document:"undefined"!=typeof document?document:null,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});class zut{constructor(){this._events={}}on(e,t){return e.split(" ").forEach(e=>{this._events[e]=this._events[e]||[],this._events[e].push(t)}),this}off(e,t){if(null!=e)return e.split(" ").forEach(e=>{e in this._events!=!1&&(t?this._events[e].splice(this._events[e].indexOf(t),1):this._events[e]=[])}),this;this._events={}}emit(e){if(void 0!==this._events[e])for(var t=this._events[e].slice(),n=0;n<t.length;++n){var a=t[n].apply(this,Array.prototype.slice.call(arguments,1));if(void 0!==a)return a}}}Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(e,t){if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),a=n.length>>>0;if(0===a)return!1;var r=0|t,i=Math.max(r>=0?r:a-Math.abs(r),0);function o(e,t){return e===t||"number"==typeof e&&"number"==typeof t&&isNaN(e)&&isNaN(t)}for(;i<a;){if(o(n[i],e))return!0;i++}return!1}}),Math.sign||(Math.sign=function(e){return(e>0)-(e<0)||+e});class Put extends f.default.Component{constructor(e){super(e),vs(this,"onWindowResize",()=>{this.setState({flexData:this.computeFlexData()})}),vs(this,"onStartResize",e=>{const t=e.event.changedTouches?e.event.changedTouches[0]:e.event;if("horizontal"===this.props.orientation)document.body.classList.add("reflex-row-resize"),this.previousPos=t.clientY;else document.body.classList.add("reflex-col-resize"),this.previousPos=t.clientX;this.elements=[this.children[e.index-1],this.children[e.index+1]],this.emitElementsEvent(this.elements,"onStartResize")}),vs(this,"onResize",e=>{const t=e.event.changedTouches?e.event.changedTouches[0]:e.event,n=this.getOffset(t,e.domElement);if("horizontal"===this.props.orientation)this.previousPos=t.clientY;else this.previousPos=t.clientX;if(n){const t=this.computeAvailableOffset(e.index,n);t&&(this.elements=this.dispatchOffset(e.index,t),this.adjustFlex(this.elements),this.setState({resizing:!0},()=>{this.emitElementsEvent(this.elements,"onResize")}))}}),vs(this,"onStopResize",e=>{document.body.classList.remove("reflex-row-resize"),document.body.classList.remove("reflex-col-resize");const t=this.elements?this.elements.map(e=>e.ref):[],n=this.children.filter(e=>!Vut.isA(e)&&t.includes(e.ref));this.emitElementsEvent(n,"onStopResize"),this.setState({resizing:!1})}),vs(this,"onElementSize",e=>new Promise(t=>{try{const n=e.index,a=this.getSize(this.children[n]),r=e.size-a,i=e.direction,o=n+i,l=this.computeAvailableOffset(o,i*r);this.elements=null,l&&(this.elements=this.dispatchOffset(o,l),this.adjustFlex(this.elements)),this.setState(this.state,()=>{this.emitElementsEvent(this.elements,"onResize"),t()})}catch(e){console.log(e)}})),this.events=new zut,this.children=[],this.state={flexData:[]},this.ref=f.default.createRef()}componentDidMount(){const e=this.computeFlexData(),{windowResizeAware:t}=this.props;t&&window.addEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:t,flexData:e}),this.events.on("element.size",this.onElementSize),this.events.on("startResize",this.onStartResize),this.events.on("stopResize",this.onStopResize),this.events.on("resize",this.onResize)}componentWillUnmount(){this.events.off(),window.removeEventListener("resize",this.onWindowResize)}getValidChildren(e=this.props){return this.toArray(e.children).filter(e=>!!e)}componentDidUpdate(e,t){const n=this.getValidChildren(this.props);if(n.length!==this.state.flexData.length||e.orientation!==this.props.orientation||this.flexHasChanged(e)){const e=this.computeFlexData(n,this.props);this.setState({flexData:e})}this.props.windowResizeAware!==this.state.windowResizeAware&&(this.props.windowResizeAware?window.addEventListener("resize",this.onWindowResize):window.removeEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:this.props.windowResizeAware}))}flexHasChanged(e){const t=this.getValidChildren(e).map(e=>e.props.flex||0);return!this.getValidChildren().map(e=>e.props.flex||0).every((e,n)=>e===t[n])}getSize(e){var t,n,a;const r=null==e||null===(t=e.ref)||void 0===t?void 0:t.current;return"horizontal"===this.props.orientation?null!==(n=null==r?void 0:r.offsetHeight)&&void 0!==n?n:0:null!==(a=null==r?void 0:r.offsetWidth)&&void 0!==a?a:0}getOffset(e,t){const{top:n,bottom:a,left:r,right:i}=t.getBoundingClientRect();switch(this.props.orientation){case"horizontal":{const t=e.clientY-this.previousPos;if(t>0){if(e.clientY>=n)return t}else if(e.clientY<=a)return t;break}default:{const t=e.clientX-this.previousPos;if(t>0){if(e.clientX>r)return t}else if(e.clientX<i)return t}}return 0}adjustFlex(e){const t=e.reduce((t,n)=>{const a=n.props.index;return t+(n.props.flex-this.state.flexData[a].flex)/e.length},0);e.forEach(e=>{this.state.flexData[e.props.index].flex+=t})}computeAvailableOffset(e,t){const n=this.computeAvailableStretch(e,t),a=this.computeAvailableShrink(e,t);return Math.min(n,a)*Math.sign(t)}checkPropagate(e,t){if(t>0){if(e<this.children.length-2){const t=this.children[e+2];return Vut.isA(t)&&t.props.propagate}}else if(e>2){const t=this.children[e-2];return Vut.isA(t)&&t.props.propagate}return!1}computeAvailableStretch(e,t){var n;const a=t<0?e+1:e-1,r=this.children[a],i=this.getSize(r),o=(null!==(n=null==r?void 0:r.props.maxSize)&&void 0!==n?n:0)-i;if(o<Math.abs(t)&&this.checkPropagate(e,-1*t)){const n=Math.sign(t)*(Math.abs(t)-o);return o+this.computeAvailableStretch(t<0?e+2:e-2,n)}return Math.min(o,Math.abs(t))}computeAvailableShrink(e,t){var n;const a=t>0?e+1:e-1,r=this.children[a],i=this.getSize(r)-Math.max(null!==(n=null==r?void 0:r.props.minSize)&&void 0!==n?n:0,0);if(i<Math.abs(t)&&this.checkPropagate(e,t)){const n=Math.sign(t)*(Math.abs(t)-i);return i+this.computeAvailableShrink(t>0?e+2:e-2,n)}return Math.min(i,Math.abs(t))}computePixelFlex(e=this.props.orientation){return this.ref.current?"horizontal"===e?0===this.ref.current.offsetHeight?(console.warn("Found ReflexContainer with height=0, this will cause invalid behavior..."),console.warn(this.ref.current),0):1/this.ref.current.offsetHeight:0===this.ref.current.offsetWidth?(console.warn("Found ReflexContainer with width=0, this will cause invalid behavior..."),console.warn(this.ref.current),0):1/this.ref.current.offsetWidth:(console.warn("Unable to locate ReflexContainer dom node"),0)}addOffset(e,t){const n=this.getSize(e),a=e.props.index,r=Math.max(n+t,0),i=this.state.flexData[a].flex,o=i>0?i*r/n:this.computePixelFlex()*r;this.state.flexData[a].flex=!isFinite(o)||isNaN(o)?0:o}dispatchStretch(e,t){const n=t<0?e+1:e-1;if(n<0||n>this.children.length-1)return[];const a=this.children[n],r=this.getSize(a),i=Math.min(a.props.maxSize,r+Math.abs(t))-r;if(this.addOffset(a,i),i<Math.abs(t)){const n=e-2*Math.sign(t),r=Math.sign(t)*(Math.abs(t)-i);return[a,...this.dispatchStretch(n,r)]}return[a]}dispatchShrink(e,t){const n=t>0?e+1:e-1;if(n<0||n>this.children.length-1)return[];const a=this.children[n],r=this.getSize(a),i=Math.max(a.props.minSize,r-Math.abs(t))-r;if(this.addOffset(a,i),Math.abs(i)<Math.abs(t)){const n=e+2*Math.sign(t),r=Math.sign(t)*(Math.abs(t)+i);return[a,...this.dispatchShrink(n,r)]}return[a]}dispatchOffset(e,t){return[...this.dispatchStretch(e,t),...this.dispatchShrink(e,t)]}emitElementsEvent(e,t){this.toArray(e).forEach(e=>{e.props[t]&&e.props[t]({domElement:e.ref.current,component:e})})}computeFlexData(e=this.getValidChildren(),t=this.props){const n=this.computePixelFlex(t.orientation),a=e.map(e=>{const t=e.props;return{maxFlex:(t.maxSize||Number.MAX_VALUE)*n,sizeFlex:(t.size||Number.MAX_VALUE)*n,minFlex:(t.minSize||1)*n,constrained:void 0!==t.flex,flex:t.flex||0,type:e.type}}),r=(e,t=0)=>{let n=!1;const a=(e=>e.reduce((e,t)=>Vut.isA(t)||t.constrained?e:e+1,0))(e),i=(e=>e.reduce((e,t)=>!Vut.isA(t)&&t.constrained?e-t.flex:e,1))(e),o=e.map(e=>{if(Vut.isA(e))return e;const t=e.constrained?e.flex:i/a,r=Math.min(e.sizeFlex,Math.min(e.maxFlex,Math.max(e.minFlex,t))),o=e.constrained||r!==t;return n=n||o,Nut({},e,{flex:r,constrained:o})});return n&&t<this.props.maxRecDepth?r(o,t+1):o};return r(a).map(e=>({flex:Vut.isA(e)?0:e.flex,ref:f.default.createRef()}))}toArray(e){return e?Array.isArray(e)?e:[e]:[]}render(){const e=[this.state.resizing?"reflex-resizing":"",...this.props.className.split(" "),this.props.orientation,"reflex-container"].join(" ").trim();return this.children=f.default.Children.map(this.getValidChildren(),(e,t)=>{if(t>this.state.flexData.length-1)return f.default.createElement("div",null);const n=this.state.flexData[t],a=Nut({},e.props,{maxSize:e.props.maxSize||Number.MAX_VALUE,orientation:this.props.orientation,minSize:e.props.minSize||1,events:this.events,flex:n.flex,ref:n.ref,index:t});return f.default.cloneElement(e,a)}),f.default.createElement("div",In({},Lut(this.props),{style:this.props.style,className:e,ref:this.ref}),this.children)}}vs(Put,"propTypes",{windowResizeAware:gt.bool,orientation:gt.oneOf(["horizontal","vertical"]),maxRecDepth:gt.number,className:gt.string,style:gt.object}),vs(Put,"defaultProps",{orientation:"horizontal",windowResizeAware:!1,maxRecDepth:100,className:"",style:{}});class Tut extends f.default.Component{static isA(e){return!!e&&("development"===process.env.NODE_ENV?e.type===f.default.createElement(Tut,null).type:e.type===Tut)}constructor(e){super(e),vs(this,"ref",f.default.createRef()),vs(this,"onMouseMove",e=>{if(this.state.active){const t=this.ref.current;this.props.events.emit("resize",{index:this.props.index,domElement:t,event:e}),this.props.onResize&&this.props.onResize({component:this,domElement:t}),e.stopPropagation(),e.preventDefault()}}),vs(this,"onMouseDown",e=>{this.setState({active:!0}),this.props.onStartResize&&this.props.onStartResize({domElement:this.ref.current,component:this})||this.props.events.emit("startResize",{index:this.props.index,event:e})}),vs(this,"onMouseUp",e=>{this.state.active&&(this.setState({active:!1}),this.props.onStopResize&&this.props.onStopResize({domElement:this.ref.current,component:this}),this.props.events.emit("stopResize",{index:this.props.index,event:e}))}),this.state={active:!1},this.document=e.document}componentDidMount(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}componentWillUnmount(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}render(){const e=[...this.props.className.split(" "),this.state.active?"active":"","reflex-handle"].join(" ").trim();return f.default.createElement("div",In({},Lut(this.props),{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id,ref:this.ref}),this.props.children)}}vs(Tut,"propTypes",{children:gt.oneOfType([gt.arrayOf(gt.node),gt.node]),onStartResize:gt.func,onStopResize:gt.func,className:gt.string,propagate:gt.bool,onResize:gt.func,style:gt.object}),vs(Tut,"defaultProps",{document:"undefined"==typeof document?null:document,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});var But="Expected a function",jut=/^\s+|\s+$/g,Wut=/^[-+]0x[0-9a-f]+$/i,Rut=/^0b[01]+$/i,Fut=/^0o[0-7]+$/i,Yut=parseInt,qut="object"==typeof C&&C&&C.Object===Object&&C,Uut="object"==typeof self&&self&&self.Object===Object&&self,Gut=qut||Uut||Function("return this")(),Kut=Object.prototype.toString,Qut=Math.max,Xut=Math.min,Jut=function(){return Gut.Date.now()};function $ut(e,t,n){var a,r,i,o,l,s,c=0,d=!1,h=!1,u=!0;if("function"!=typeof e)throw new TypeError(But);function p(t){var n=a,i=r;return a=r=void 0,c=t,o=e.apply(i,n)}function f(e){var n=e-s;return void 0===s||n>=t||n<0||h&&e-c>=i}function m(){var e=Jut();if(f(e))return v(e);l=setTimeout(m,function(e){var n=t-(e-s);return h?Xut(n,i-(e-c)):n}(e))}function v(e){return l=void 0,u&&a?p(e):(a=r=void 0,o)}function g(){var e=Jut(),n=f(e);if(a=arguments,r=this,s=e,n){if(void 0===l)return function(e){return c=e,l=setTimeout(m,t),d?p(e):o}(s);if(h)return l=setTimeout(m,t),p(s)}return void 0===l&&(l=setTimeout(m,t)),o}return t=tpt(t)||0,ept(n)&&(d=!!n.leading,i=(h="maxWait"in n)?Qut(tpt(n.maxWait)||0,t):i,u="trailing"in n?!!n.trailing:u),g.cancel=function(){void 0!==l&&clearTimeout(l),c=0,a=s=r=l=void 0},g.flush=function(){return void 0===l?o:v(Jut())},g}function ept(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function tpt(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==Kut.call(e)}(e))return NaN;if(ept(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ept(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(jut,"");var n=Rut.test(e);return n||Fut.test(e)?Yut(e.slice(2),n?2:8):Wut.test(e)?NaN:+e}var npt=function(e,t,n){var a=!0,r=!0;if("function"!=typeof e)throw new TypeError(But);return ept(n)&&(a="leading"in n?!!n.leading:a,r="trailing"in n?!!n.trailing:r),$ut(e,t,{leading:a,maxWait:t,trailing:r})},apt=["client","offset","scroll","bounds","margin"];function rpt(e){var t=[];return apt.forEach(function(n){e[n]&&t.push(n)}),t}function ipt(e,t){var n={};if(t.indexOf("client")>-1&&(n.client={top:e.clientTop,left:e.clientLeft,width:e.clientWidth,height:e.clientHeight}),t.indexOf("offset")>-1&&(n.offset={top:e.offsetTop,left:e.offsetLeft,width:e.offsetWidth,height:e.offsetHeight}),t.indexOf("scroll")>-1&&(n.scroll={top:e.scrollTop,left:e.scrollLeft,width:e.scrollWidth,height:e.scrollHeight}),t.indexOf("bounds")>-1){var a=e.getBoundingClientRect();n.bounds={top:a.top,right:a.right,bottom:a.bottom,left:a.left,width:a.width,height:a.height}}if(t.indexOf("margin")>-1){var r=getComputedStyle(e);n.margin={top:r?parseInt(r.marginTop):0,right:r?parseInt(r.marginRight):0,bottom:r?parseInt(r.marginBottom):0,left:r?parseInt(r.marginLeft):0}}return n}var opt=function(t){return function(n){var a,r;return r=a=function(a){function r(){for(var e,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return(e=a.call.apply(a,[this].concat(r))||this).state={contentRect:{entry:{},client:{},offset:{},scroll:{},bounds:{},margin:{}}},e._animationFrameID=null,e._resizeObserver=null,e._node=null,e._window=null,e.measure=function(n){var a=ipt(e._node,t||rpt(e.props));n&&(a.entry=n[0].contentRect),e._animationFrameID=e._window.requestAnimationFrame(function(){null!==e._resizeObserver&&(e.setState({contentRect:a}),"function"==typeof e.props.onResize&&e.props.onResize(a))})},e._handleRef=function(t){var n;null!==e._resizeObserver&&null!==e._node&&e._resizeObserver.unobserve(e._node),e._node=t,e._window=(n=e._node)&&n.ownerDocument&&n.ownerDocument.defaultView||window;var a=e.props.innerRef;a&&("function"==typeof a?a(e._node):a.current=e._node),null!==e._resizeObserver&&null!==e._node&&e._resizeObserver.observe(e._node)},e}On(r,a);var i=r.prototype;return i.componentDidMount=function(){this._resizeObserver=null!==this._window&&this._window.ResizeObserver?new this._window.ResizeObserver(this.measure):new MQe(this.measure),null!==this._node&&(this._resizeObserver.observe(this._node),"function"==typeof this.props.onResize&&this.props.onResize(ipt(this._node,t||rpt(this.props))))},i.componentWillUnmount=function(){null!==this._window&&this._window.cancelAnimationFrame(this._animationFrameID),null!==this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)},i.render=function(){var t=this.props;t.innerRef,t.onResize;var a=Dn(t,["innerRef","onResize"]);return e.createElement(n,In({},a,{measureRef:this._handleRef,measure:this.measure,contentRect:this.state.contentRect}))},r}(e.Component),a.propTypes={client:gt.bool,offset:gt.bool,scroll:gt.bool,bounds:gt.bool,margin:gt.bool,innerRef:gt.oneOfType([gt.object,gt.func]),onResize:gt.func},r}}()(function(e){var t=e.measure,n=e.measureRef,a=e.contentRect;return(0,e.children)({measure:t,measureRef:n,contentRect:a})});opt.displayName="Measure",opt.propTypes.children=gt.func;const lpt=e=>e?Array.isArray(e)?e:[e]:[];class spt extends f.default.Component{constructor(e){super(e),vs(this,"onResize",e=>{const{resizeHeight:t,resizeWidth:n}=this.props,{height:a,width:r}=e.bounds;this.setDimensions(Nut({},t&&{height:a},n&&{width:r}))}),this.setDimensions=npt(e=>{this.setState(e)},this.props.propagateDimensionsRate/1e3),this.state={height:"100%",width:"100%"}}renderChildren(){const{propagateDimensions:e}=this.props,t=lpt(this.props.children).filter(e=>!!e);return f.default.Children.map(t,t=>this.props.withHandle||Tut.isA(t)?f.default.cloneElement(t,Nut({dimensions:e&&this.state},t.props,{index:this.props.index-1,events:this.props.events})):e?f.default.cloneElement(t,Nut({},t.props,{dimensions:this.state})):t)}render(){return f.default.createElement(opt,{bounds:!0,onResize:this.onResize},({measureRef:e})=>f.default.createElement("div",{ref:e,className:"reflex-size-aware"},f.default.createElement("div",{style:this.state},this.renderChildren())))}}class cpt extends f.default.Component{constructor(e){super(e),this.state={size:e.size}}static getDerivedStateFromProps(e,t){return e.size!==t.size?Nut({},t,{size:e.size}):null}async componentDidUpdate(e,t,n){if(t.size!==this.state.size){const e=lpt(this.props.direction);for(let t of e)await this.props.events.emit("element.size",{index:this.props.index,size:this.props.size,direction:t})}}renderChildren(){const e=lpt(this.props.children).filter(e=>!!e);return f.default.Children.map(e,e=>this.props.withHandle||Tut.isA(e)?f.default.cloneElement(e,Nut({},e.props,{index:this.props.index-1,events:this.props.events})):e)}render(){const e=[...this.props.className.split(" "),this.props.orientation,"reflex-element"].join(" ").trim(),t=Nut({},this.props.style,{flexGrow:this.props.flex,flexShrink:1,flexBasis:"0%"});return f.default.createElement("div",In({},Lut(this.props),{ref:this.props.innerRef,className:e,style:t}),this.props.propagateDimensions?f.default.createElement(spt,this.props):this.renderChildren())}}vs(cpt,"propTypes",{propagateDimensions:gt.bool,resizeHeight:gt.bool,resizeWidth:gt.bool,className:gt.string,size:gt.number}),vs(cpt,"defaultProps",{propagateDimensionsRate:100,propagateDimensions:!1,resizeHeight:!0,resizeWidth:!0,direction:[1],className:""});var dpt=f.default.forwardRef((e,t)=>f.default.createElement(cpt,In({innerRef:t},e)));E("body.reflex-col-resize {\n cursor: col-resize; }\n\nbody.reflex-row-resize {\n cursor: row-resize; }\n\n.reflex-container {\n justify-content: flex-start;\n /* align items in Main Axis */\n align-items: stretch;\n /* align items in Cross Axis */\n align-content: stretch;\n /* OLD - iOS 6-, Safari 3.1-6 */\n /* OLD - Firefox 19- (buggy but mostly works) */\n /* TWEENER - IE 10 */\n /* NEW - Chrome */\n display: flex;\n position: relative;\n height: 100%;\n width: 100%; }\n\n.reflex-container.horizontal {\n flex-direction: column;\n min-height: 1px; }\n\n.reflex-container.vertical {\n flex-direction: row;\n min-width: 1px; }\n\n.reflex-container > .reflex-element {\n position: relative;\n overflow: auto;\n height: 100%;\n width: 100%; }\n\n.reflex-container.reflex-resizing > .reflex-element {\n pointer-events: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none; }\n\n.reflex-container > .reflex-element > .reflex-size-aware {\n height: 100%;\n width: 100%; }\n\n.reflex-container > .reflex-splitter {\n background-color: #eeeeee;\n z-index: 100; }\n\n.reflex-container > .reflex-splitter.active,\n.reflex-container > .reflex-splitter:hover {\n background-color: #c6c6c6;\n transition: all 1s ease; }\n\n.horizontal > .reflex-splitter {\n border-bottom: 1px solid #c6c6c6;\n border-top: 1px solid #c6c6c6;\n cursor: row-resize;\n width: 100%;\n height: 2px; }\n\n.reflex-element.horizontal .reflex-handle {\n cursor: row-resize;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none; }\n\n.reflex-container.horizontal > .reflex-splitter:hover,\n.reflex-container.horizontal > .reflex-splitter.active {\n border-bottom: 1px solid #eeeeee;\n border-top: 1px solid #eeeeee; }\n\n.reflex-container.vertical > .reflex-splitter {\n border-right: 1px solid #c6c6c6;\n border-left: 1px solid #c6c6c6;\n cursor: col-resize;\n height: 100%;\n width: 2px; }\n\n.reflex-element.vertical .reflex-handle {\n cursor: col-resize;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none; }\n\n.reflex-container.vertical > .reflex-splitter:hover,\n.reflex-container.vertical > .reflex-splitter.active {\n border-right: 1px solid #eeeeee;\n border-left: 1px solid #eeeeee; }\n\n.reflex-container > .reflex-splitter.reflex-thin {\n box-sizing: border-box;\n -moz-background-clip: padding;\n -webkit-background-clip: padding;\n background-clip: padding-box;\n opacity: 0.2;\n z-index: 100; }\n\n.reflex-container > .reflex-splitter.reflex-thin.active\n.reflex-container > .reflex-splitter.reflex-thin:hover {\n transition: all 1.5s ease;\n opacity: 0.5; }\n\n.reflex-container.horizontal > .reflex-splitter.reflex-thin {\n border-bottom: 8px solid rgba(255, 255, 255, 0);\n border-top: 8px solid rgba(255, 255, 255, 0);\n height: 17px !important;\n cursor: row-resize;\n margin: -8px 0;\n width: 100%; }\n\n.reflex-container.horizontal > .reflex-splitter.reflex-thin.active,\n.reflex-container.horizontal > .reflex-splitter.reflex-thin:hover {\n border-bottom: 8px solid #e4e4e4;\n border-top: 8px solid #e4e4e4; }\n\n.reflex-container.vertical > .reflex-splitter.reflex-thin {\n border-right: 8px solid rgba(255, 255, 255, 0);\n border-left: 8px solid rgba(255, 255, 255, 0);\n width: 17px !important;\n cursor: col-resize;\n margin: 0 -8px;\n height: 100%; }\n\n.reflex-container.vertical > .reflex-splitter.reflex-thin.active,\n.reflex-container.vertical > .reflex-splitter.reflex-thin:hover {\n border-right: 8px solid #e4e4e4;\n border-left: 8px solid #e4e4e4; }");var hpt=function(e){var t=e.breadCrumbTitle,n=e.breadCrumbParent,a=e.breadCrumbActive;return f.default.createElement("div",{className:"content-header row"},f.default.createElement("div",{className:"content-header-left col-md-9 col-12"},f.default.createElement("div",{className:"row breadcrumbs-top"},f.default.createElement("div",{className:"col-12"},t?f.default.createElement("h2",{className:"content-header-title float-start mb-0"},t):"",f.default.createElement("div",{className:"breadcrumb-wrapper vs-breadcrumbs d-sm-block d-none col-12"},f.default.createElement(pn,{className:"breadcrumb-nowrap"},f.default.createElement(wn,{tag:"li"},f.default.createElement("a",{href:"/"},f.default.createElement(Xr,{fontSize:20}))),n&&n.length>0&&(null==n?void 0:n.map(function(e,t){return f.default.createElement(wn,{key:t,tag:"li"},e.link?f.default.createElement("a",{href:e.link},e.title):e.title)})),f.default.createElement(wn,{tag:"li",active:!0},a)))))))};hpt.propTypes={breadCrumbActive:gt.string.isRequired,breadCrumbParent:gt.object};var upt=0;function ppt(e,t){var n=t;return n.unshift(void 0),new(Function.prototype.bind.apply(e,n))}function fpt(e,t){for(var n=t,a=e.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r<a.length&&!Ept(n);r++)n=n[a[r]];return n}function mpt(e,t,n){var a,r,i=e.replace(/\[/g,".").replace(/\]/g,"").split("."),o=n||{},l=o,s=i.length;for(a=0;a<s;a++)r=i[a],a+1===s?l[r]=void 0===t?{}:t:xpt(l[r])&&(l[r]={}),l=l[r];return o}function vpt(e,t){delete e[t]}var gpt="undefined"!=typeof window?window:{};function wpt(e){return!xpt(e)&&e.constructor==={}.constructor}function ypt(e,t){if(!xpt(t))for(var n=e,a=t,r="deepMerge",i=0,o=Object.keys(t);i<o.length;i++){var l=o[i];xpt(n[r])||-1===n[r].indexOf(l)||!wpt(a[l])&&!Array.isArray(a[l])?n[l]=a[l]:bpt(n[l],n[l],a[l],!0)}}function bpt(e,t,n,a){var r=e&&"object"==typeof e?e:{},i=arguments.length;a&&(i-=1);for(var o=function(e){if(!l[e])return"continue";var t=l[e];Object.keys(t).forEach(function(e){var n,i=r[e],o=t[e];Array.isArray(o)&&Array.isArray(i)&&(o.length,i.length);a&&(wpt(o)||Array.isArray(o))?wpt(o)?(n=i||{},Array.isArray(n)&&n.hasOwnProperty("isComplexArray")?bpt(n,{},o,a):r[e]=bpt(n,{},o,a)):(n=i||[],r[e]=bpt([],n,o,n&&n.length||o&&o.length)):r[e]=o})},l=arguments,s=1;s<i;s++)o(s);return r}function xpt(e){return null==e}function Ept(e){return void 0===e}function kpt(e){return e+"_"+upt++}function Mpt(e,t){return e===t||!(e===document||!e)&&Mpt(e.parentNode,t)}function Spt(e){try{throw new Error(e)}catch(e){throw e.message+"\n"+e.stack}}function Apt(e){var t=e+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function _pt(){return false}var Cpt,Zpt={latn:{_digits:"0123456789",_type:"numeric"}},Hpt={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"∞",nan:"NaN",exponential:"E"},Ipt=[0,1,2,3,4,5,6,7,8,9],Dpt=function(){function e(){}return e.getMainObject=function(e,t){return fpt("main."+t,e)},e.getNumberingSystem=function(e){return fpt("supplemental.numberingSystems",e)||this.numberingSystems},e.reverseObject=function(e,t){for(var n={},a=0,r=t||Object.keys(e);a<r.length;a++){var i=r[a];n.hasOwnProperty(e[i])||(n[e[i]]=i)}return n},e.getSymbolRegex=function(e){var t=e.map(function(e){return e.replace(/([.*+?^=!:${}()|[\]/\\])/g,"\\$1")}).join("|");return new RegExp(t,"g")},e.getSymbolMatch=function(e){for(var t={},n=0,a=Object.keys(Hpt);n<a.length;n++){var r=a[n];t[e[r]]=Hpt[r]}return t},e.constructRegex=function(e){for(var t=e.length,n="",a=0;a<t;a++)n+=a!==t-1?e[a]+"|":e[a];return n},e.convertValueParts=function(e,t,n){return e.replace(t,function(e){return n[e]})},e.getDefaultNumberingSystem=function(e){var t={};return t.obj=fpt("numbers",e),t.nSystem=fpt("defaultNumberingSystem",t.obj),t},e.getCurrentNumericOptions=function(e,t,n,a){var r={},i=this.getDefaultNumberingSystem(e);if(!Ept(i.nSystem)||a){var o=a?fpt("obj.mapperDigits",i):fpt(i.nSystem+"._digits",t);Ept(o)||(r.numericPair=this.reverseObject(o,Ipt),r.numberParseRegex=new RegExp(this.constructRegex(o),"g"),r.numericRegex="["+o[0]+"-"+o[9]+"]",n&&(r.numericRegex=o[0]+"-"+o[9],r.symbolNumberSystem=fpt(a?"numberSymbols":"symbols-numberSystem-"+i.nSystem,i.obj),r.symbolMatch=this.getSymbolMatch(r.symbolNumberSystem),r.numberSystem=i.nSystem))}return r},e.getNumberMapper=function(e,t,n){var a={mapper:{}},r=this.getDefaultNumberingSystem(e);if(!Ept(r.nSystem)){a.numberSystem=r.nSystem,a.numberSymbols=fpt("symbols-numberSystem-"+r.nSystem,r.obj),a.timeSeparator=fpt("timeSeparator",a.numberSymbols);var i=fpt(r.nSystem+"._digits",t);if(!Ept(i))for(var o=0,l=Ipt;o<l.length;o++){var s=l[o];a.mapper[s]=i[s]}}return a},e.nPair="numericPair",e.nRegex="numericRegex",e.numberingSystems=Zpt,e}(),Npt={DJF:"Fdj",ERN:"Nfk",ETB:"Br",NAD:"$",ZAR:"R",XAF:"FCFA",GHS:"GH₵",XDR:"XDR",AED:"د.إ.‏",BHD:"د.ب.‏",DZD:"د.ج.‏",EGP:"ج.م.‏",ILS:"₪",IQD:"د.ع.‏",JOD:"د.ا.‏",KMF:"CF",KWD:"د.ك.‏",LBP:"ل.ل.‏",LYD:"د.ل.‏",MAD:"د.م.‏",MRU:"أ.م.",OMR:"ر.ع.‏",QAR:"ر.ق.‏",SAR:"ر.س.‏",SDG:"ج.س.",SOS:"S",SSP:"£",SYP:"ل.س.‏",TND:"د.ت.‏",YER:"ر.ي.‏",CLP:"$",INR:"₹",TZS:"TSh",EUR:"€",AZN:"₼",RUB:"₽",BYN:"Br",ZMW:"K",BGN:"лв.",NGN:"₦",XOF:"CFA",BDT:"৳",CNY:"¥",BAM:"КМ",UGX:"USh",USD:"$",CZK:"Kč",GBP:"£",DKK:"kr.",KES:"Ksh",CHF:"CHF",MVR:"ރ.",BTN:"Nu.",XCD:"EC$",AUD:"$",BBD:"$",BIF:"FBu",BMD:"$",BSD:"$",BWP:"P",BZD:"$",CAD:"$",NZD:"$",FJD:"$",FKP:"£",GIP:"£",GMD:"D",GYD:"$",HKD:"$",IDR:"Rp",JMD:"$",KYD:"$",LRD:"$",MGA:"Ar",MOP:"MOP$",MUR:"Rs",MWK:"MK",MYR:"RM",PGK:"K",PHP:"₱",PKR:"Rs",RWF:"RF",SBD:"$",SCR:"SR",SEK:"kr",SGD:"$",SHP:"£",SLL:"Le",ANG:"NAf.",SZL:"E",TOP:"T$",TTD:"$",VUV:"VT",WST:"WS$",ARS:"$",BOB:"Bs",BRL:"R$",COP:"$",CRC:"₡",CUP:"$",DOP:"$",GTQ:"Q",HNL:"L",MXN:"$",NIO:"C$",PAB:"B/.",PEN:"S/",PYG:"₲",UYU:"$",VES:"Bs.S",IRR:"ريال",GNF:"FG",CDF:"FC",HTG:"G",XPF:"FCFP",HRK:"kn",HUF:"Ft",AMD:"֏",ISK:"kr",JPY:"¥",GEL:"₾",CVE:"​",KZT:"₸",KHR:"៛",KPW:"₩",KRW:"₩",KGS:"сом",AOA:"Kz",LAK:"₭",MZN:"MTn",MKD:"ден",MNT:"₮",BND:"$",MMK:"K",NOK:"kr",NPR:"रु",AWG:"Afl.",SRD:"$",PLN:"zł",AFN:"؋",STN:"Db",MDL:"L",RON:"lei",UAH:"₴",LKR:"රු.",ALL:"Lekë",RSD:"дин.",TJS:"смн",THB:"฿",TMT:"m.",TRY:"₺",UZS:"сўм",VND:"₫",TWD:"NT$"};!function(e){var t=[28607,28636,28665,28695,28724,28754,28783,28813,28843,28872,28901,28931,28960,28990,29019,29049,29078,29108,29137,29167,29196,29226,29255,29285,29315,29345,29375,29404,29434,29463,29492,29522,29551,29580,29610,29640,29669,29699,29729,29759,29788,29818,29847,29876,29906,29935,29964,29994,30023,30053,30082,30112,30141,30171,30200,30230,30259,30289,30318,30348,30378,30408,30437,30467,30496,30526,30555,30585,30614,30644,30673,30703,30732,30762,30791,30821,30850,30880,30909,30939,30968,30998,31027,31057,31086,31116,31145,31175,31204,31234,31263,31293,31322,31352,31381,31411,31441,31471,31500,31530,31559,31589,31618,31648,31676,31706,31736,31766,31795,31825,31854,31884,31913,31943,31972,32002,32031,32061,32090,32120,32150,32180,32209,32239,32268,32298,32327,32357,32386,32416,32445,32475,32504,32534,32563,32593,32622,32652,32681,32711,32740,32770,32799,32829,32858,32888,32917,32947,32976,33006,33035,33065,33094,33124,33153,33183,33213,33243,33272,33302,33331,33361,33390,33420,33450,33479,33509,33539,33568,33598,33627,33657,33686,33716,33745,33775,33804,33834,33863,33893,33922,33952,33981,34011,34040,34069,34099,34128,34158,34187,34217,34247,34277,34306,34336,34365,34395,34424,34454,34483,34512,34542,34571,34601,34631,34660,34690,34719,34749,34778,34808,34837,34867,34896,34926,34955,34985,35015,35044,35074,35103,35133,35162,35192,35222,35251,35280,35310,35340,35370,35399,35429,35458,35488,35517,35547,35576,35605,35635,35665,35694,35723,35753,35782,35811,35841,35871,35901,35930,35960,35989,36019,36048,36078,36107,36136,36166,36195,36225,36254,36284,36314,36343,36373,36403,36433,36462,36492,36521,36551,36580,36610,36639,36669,36698,36728,36757,36786,36816,36845,36875,36904,36934,36963,36993,37022,37052,37081,37111,37141,37170,37200,37229,37259,37288,37318,37347,37377,37406,37436,37465,37495,37524,37554,37584,37613,37643,37672,37701,37731,37760,37790,37819,37849,37878,37908,37938,37967,37997,38027,38056,38085,38115,38144,38174,38203,38233,38262,38292,38322,38351,38381,38410,38440,38469,38499,38528,38558,38587,38617,38646,38676,38705,38735,38764,38794,38823,38853,38882,38912,38941,38971,39001,39030,39059,39089,39118,39148,39178,39208,39237,39267,39297,39326,39355,39385,39414,39444,39473,39503,39532,39562,39592,39621,39650,39680,39709,39739,39768,39798,39827,39857,39886,39916,39946,39975,40005,40035,40064,40094,40123,40153,40182,40212,40241,40271,40300,40330,40359,40389,40418,40448,40477,40507,40536,40566,40595,40625,40655,40685,40714,40744,40773,40803,40832,40862,40892,40921,40951,40980,41009,41039,41068,41098,41127,41157,41186,41216,41245,41275,41304,41334,41364,41393,41422,41452,41481,41511,41540,41570,41599,41629,41658,41688,41718,41748,41777,41807,41836,41865,41894,41924,41953,41983,42012,42042,42072,42102,42131,42161,42190,42220,42249,42279,42308,42337,42367,42397,42426,42456,42485,42515,42545,42574,42604,42633,42662,42692,42721,42751,42780,42810,42839,42869,42899,42929,42958,42988,43017,43046,43076,43105,43135,43164,43194,43223,43253,43283,43312,43342,43371,43401,43430,43460,43489,43519,43548,43578,43607,43637,43666,43696,43726,43755,43785,43814,43844,43873,43903,43932,43962,43991,44021,44050,44080,44109,44139,44169,44198,44228,44258,44287,44317,44346,44375,44405,44434,44464,44493,44523,44553,44582,44612,44641,44671,44700,44730,44759,44788,44818,44847,44877,44906,44936,44966,44996,45025,45055,45084,45114,45143,45172,45202,45231,45261,45290,45320,45350,45380,45409,45439,45468,45498,45527,45556,45586,45615,45644,45674,45704,45733,45763,45793,45823,45852,45882,45911,45940,45970,45999,46028,46058,46088,46117,46147,46177,46206,46236,46265,46295,46324,46354,46383,46413,46442,46472,46501,46531,46560,46590,46620,46649,46679,46708,46738,46767,46797,46826,46856,46885,46915,46944,46974,47003,47033,47063,47092,47122,47151,47181,47210,47240,47269,47298,47328,47357,47387,47417,47446,47476,47506,47535,47565,47594,47624,47653,47682,47712,47741,47771,47800,47830,47860,47890,47919,47949,47978,48008,48037,48066,48096,48125,48155,48184,48214,48244,48273,48303,48333,48362,48392,48421,48450,48480,48509,48538,48568,48598,48627,48657,48687,48717,48746,48776,48805,48834,48864,48893,48922,48952,48982,49011,49041,49071,49100,49130,49160,49189,49218,49248,49277,49306,49336,49365,49395,49425,49455,49484,49514,49543,49573,49602,49632,49661,49690,49720,49749,49779,49809,49838,49868,49898,49927,49957,49986,50016,50045,50075,50104,50133,50163,50192,50222,50252,50281,50311,50340,50370,50400,50429,50459,50488,50518,50547,50576,50606,50635,50665,50694,50724,50754,50784,50813,50843,50872,50902,50931,50960,50990,51019,51049,51078,51108,51138,51167,51197,51227,51256,51286,51315,51345,51374,51403,51433,51462,51492,51522,51552,51582,51611,51641,51670,51699,51729,51758,51787,51816,51846,51876,51906,51936,51965,51995,52025,52054,52083,52113,52142,52171,52200,52230,52260,52290,52319,52349,52379,52408,52438,52467,52497,52526,52555,52585,52614,52644,52673,52703,52733,52762,52792,52822,52851,52881,52910,52939,52969,52998,53028,53057,53087,53116,53146,53176,53205,53235,53264,53294,53324,53353,53383,53412,53441,53471,53500,53530,53559,53589,53619,53648,53678,53708,53737,53767,53796,53825,53855,53884,53913,53943,53973,54003,54032,54062,54092,54121,54151,54180,54209,54239,54268,54297,54327,54357,54387,54416,54446,54476,54505,54535,54564,54593,54623,54652,54681,54711,54741,54770,54800,54830,54859,54889,54919,54948,54977,55007,55036,55066,55095,55125,55154,55184,55213,55243,55273,55302,55332,55361,55391,55420,55450,55479,55508,55538,55567,55597,55627,55657,55686,55716,55745,55775,55804,55834,55863,55892,55922,55951,55981,56011,56040,56070,56100,56129,56159,56188,56218,56247,56276,56306,56335,56365,56394,56424,56454,56483,56513,56543,56572,56601,56631,56660,56690,56719,56749,56778,56808,56837,56867,56897,56926,56956,56985,57015,57044,57074,57103,57133,57162,57192,57221,57251,57280,57310,57340,57369,57399,57429,57458,57487,57517,57546,57576,57605,57634,57664,57694,57723,57753,57783,57813,57842,57871,57901,57930,57959,57989,58018,58048,58077,58107,58137,58167,58196,58226,58255,58285,58314,58343,58373,58402,58432,58461,58491,58521,58551,58580,58610,58639,58669,58698,58727,58757,58786,58816,58845,58875,58905,58934,58964,58994,59023,59053,59082,59111,59141,59170,59200,59229,59259,59288,59318,59348,59377,59407,59436,59466,59495,59525,59554,59584,59613,59643,59672,59702,59731,59761,59791,59820,59850,59879,59909,59939,59968,59997,60027,60056,60086,60115,60145,60174,60204,60234,60264,60293,60323,60352,60381,60411,60440,60469,60499,60528,60558,60588,60618,60648,60677,60707,60736,60765,60795,60824,60853,60883,60912,60942,60972,61002,61031,61061,61090,61120,61149,61179,61208,61237,61267,61296,61326,61356,61385,61415,61445,61474,61504,61533,61563,61592,61621,61651,61680,61710,61739,61769,61799,61828,61858,61888,61917,61947,61976,62006,62035,62064,62094,62123,62153,62182,62212,62242,62271,62301,62331,62360,62390,62419,62448,62478,62507,62537,62566,62596,62625,62655,62685,62715,62744,62774,62803,62832,62862,62891,62921,62950,62980,63009,63039,63069,63099,63128,63157,63187,63216,63246,63275,63305,63334,63363,63393,63423,63453,63482,63512,63541,63571,63600,63630,63659,63689,63718,63747,63777,63807,63836,63866,63895,63925,63955,63984,64014,64043,64073,64102,64131,64161,64190,64220,64249,64279,64309,64339,64368,64398,64427,64457,64486,64515,64545,64574,64603,64633,64663,64692,64722,64752,64782,64811,64841,64870,64899,64929,64958,64987,65017,65047,65076,65106,65136,65166,65195,65225,65254,65283,65313,65342,65371,65401,65431,65460,65490,65520,65549,65579,65608,65638,65667,65697,65726,65755,65785,65815,65844,65874,65903,65933,65963,65992,66022,66051,66081,66110,66140,66169,66199,66228,66258,66287,66317,66346,66376,66405,66435,66465,66494,66524,66553,66583,66612,66641,66671,66700,66730,66760,66789,66819,66849,66878,66908,66937,66967,66996,67025,67055,67084,67114,67143,67173,67203,67233,67262,67292,67321,67351,67380,67409,67439,67468,67497,67527,67557,67587,67617,67646,67676,67705,67735,67764,67793,67823,67852,67882,67911,67941,67971,68e3,68030,68060,68089,68119,68148,68177,68207,68236,68266,68295,68325,68354,68384,68414,68443,68473,68502,68532,68561,68591,68620,68650,68679,68708,68738,68768,68797,68827,68857,68886,68916,68946,68975,69004,69034,69063,69092,69122,69152,69181,69211,69240,69270,69300,69330,69359,69388,69418,69447,69476,69506,69535,69565,69595,69624,69654,69684,69713,69743,69772,69802,69831,69861,69890,69919,69949,69978,70008,70038,70067,70097,70126,70156,70186,70215,70245,70274,70303,70333,70362,70392,70421,70451,70481,70510,70540,70570,70599,70629,70658,70687,70717,70746,70776,70805,70835,70864,70894,70924,70954,70983,71013,71042,71071,71101,71130,71159,71189,71218,71248,71278,71308,71337,71367,71397,71426,71455,71485,71514,71543,71573,71602,71632,71662,71691,71721,71751,71781,71810,71839,71869,71898,71927,71957,71986,72016,72046,72075,72105,72135,72164,72194,72223,72253,72282,72311,72341,72370,72400,72429,72459,72489,72518,72548,72577,72607,72637,72666,72695,72725,72754,72784,72813,72843,72872,72902,72931,72961,72991,73020,73050,73080,73109,73139,73168,73197,73227,73256,73286,73315,73345,73375,73404,73434,73464,73493,73523,73552,73581,73611,73640,73669,73699,73729,73758,73788,73818,73848,73877,73907,73936,73965,73995,74024,74053,74083,74113,74142,74172,74202,74231,74261,74291,74320,74349,74379,74408,74437,74467,74497,74526,74556,74586,74615,74645,74675,74704,74733,74763,74792,74822,74851,74881,74910,74940,74969,74999,75029,75058,75088,75117,75147,75176,75206,75235,75264,75294,75323,75353,75383,75412,75442,75472,75501,75531,75560,75590,75619,75648,75678,75707,75737,75766,75796,75826,75856,75885,75915,75944,75974,76003,76032,76062,76091,76121,76150,76180,76210,76239,76269,76299,76328,76358,76387,76416,76446,76475,76505,76534,76564,76593,76623,76653,76682,76712,76741,76771,76801,76830,76859,76889,76918,76948,76977,77007,77036,77066,77096,77125,77155,77185,77214,77243,77273,77302,77332,77361,77390,77420,77450,77479,77509,77539,77569,77598,77627,77657,77686,77715,77745,77774,77804,77833,77863,77893,77923,77952,77982,78011,78041,78070,78099,78129,78158,78188,78217,78247,78277,78307,78336,78366,78395,78425,78454,78483,78513,78542,78572,78601,78631,78661,78690,78720,78750,78779,78808,78838,78867,78897,78926,78956,78985,79015,79044,79074,79104,79133,79163,79192,79222,79251,79281,79310,79340,79369,79399,79428,79458,79487,79517,79546,79576,79606,79635,79665,79695,79724,79753,79783,79812,79841,79871,79900,79930,79960,79990];e.getHijriDate=function(e){var n=e.getDate(),a=e.getMonth(),r=e.getFullYear(),i=a+1,o=r;i<3&&(o-=1,i+=12);var l=Math.floor(o/100),s=l-Math.floor(l/4)-2,c=Math.floor(365.25*(o+4716))+Math.floor(30.6001*(i+1))+n-s-1524,d=c+(s=(l=Math.floor((c-1867216.25)/36524.25))-Math.floor(l/4)+1)+1524,h=Math.floor((d-122.1)/365.25),u=Math.floor(365.25*h),p=Math.floor((d-u)/30.6001);n=d-u-Math.floor(30.6001*p),(a=Math.floor((d-u)/20.6001))>13&&(h+=1,a-=12),a-=1,r=h-4716;var f=c-24e5,m=10631/30,v=c-1948084,g=Math.floor(v/10631);v-=10631*g;var w=Math.floor((v-.1335)/m),y=30*g+w;v-=Math.floor(w*m+.1335);var b=Math.floor((v+28.5001)/29.5);13===b&&(b=12);for(var x=v-Math.floor(29.5001*b-29),E=0;E<t.length&&!(t[E]>f);E++);var k=E+16260,M=Math.floor((k-1)/12),S=M+1,A=k-12*M,_=f-t[E-1]+1;return(_+"").length>2&&(_=x,A=b,S=y),{year:S,month:A,date:_}},e.toGregorian=function(e,n,a){var r=a+t[12*(e-1)+1+(n-1)-16260-1]-1+24e5,i=Math.floor(r+.5),o=Math.floor((i-1867216.25)/36524.25),l=(o=i+1+o-Math.floor(o/4))+1524,s=Math.floor((l-122.1)/365.25),c=Math.floor(365.25*s),d=Math.floor((l-c)/30.6001),h=l-c-Math.floor(30.6001*d),u=d-(d>13.5?13:1),p=s-(u>2.5?4716:4715);return p<=0&&u--,new Date(p+"/"+u+"/"+h)}}(Cpt||(Cpt={}));var Opt=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Lpt="stand-alone",Vpt=["sun","mon","tue","wed","thu","fri","sat"],zpt={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Ppt={M:"month",d:"day",E:"weekday",c:"weekday",y:"year",m:"minute",h:"hour",H:"hour",s:"second",L:"month",a:"designator",z:"timeZone",Z:"timeZone",G:"era",f:"milliseconds"},Tpt=function(){function e(){}return e.dateFormat=function(e,t,n){var a=this,r=rft.getDependables(n,e,t.calendar);fpt("parserObject.numbers",r);var i=r.dateObject,o={isIslamic:rft.islamicRegex.test(t.calendar)},l=t.format||rft.getResultantPattern(t.skeleton,r.dateObject,t.type,!1,"");if(o.dateSeperator=rft.getDateSeparator(r.dateObject),Ept(l))Spt("Format options or type given must be invalid");else{l=rft.ConvertDateToWeekFormat(l),o.pattern=l,o.numMapper=Dpt.getNumberMapper(r.parserObject,Dpt.getNumberingSystem(n));for(var s=0,c=l.match(Opt)||[];s<c.length;s++){var d=c[s],h=d.length,u=d[0];switch("K"===u&&(u="h"),u){case"E":case"c":o.weekday=r.dateObject[rft.days][Lpt][rft.monthIndex[h]];break;case"M":case"L":o.month=r.dateObject[rft.month][Lpt][rft.monthIndex[h]];break;case"a":o.designator=fpt("dayPeriods.format.wide",i);break;case"G":var p=h<=3?"eraAbbr":4===h?"eraNames":"eraNarrow";o.era=fpt("eras."+p,r.dateObject);break;case"z":o.timeZone=fpt("dates.timeZoneNames",r.parserObject)}}}return function(e){return isNaN(e.getDate())?null:a.intDateFormatter(e,o)}},e.intDateFormatter=function(e,t){for(var n="",a=t.pattern.match(rft.dateParseRegex),r=this.getCurrentDateValue(e,t.isIslamic),i=0,o=a;i<o.length;i++){var l=o[i],s=l.length,c=l[0];"K"===c&&(c="h");var d=void 0,h="",u=void 0,p=void 0,f="";switch(c){case"M":case"L":d=r.month,s>2?n+=t.month[d]:u=!0;break;case"E":case"c":n+=t.weekday[Vpt[e.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(u=!0,"d"===c)d=r.date;else if("f"===c){u=!1,p=!0;var m=(h=(h=e[zpt[c]]().toString()).substring(0,s)).length;if(s!==m){if(s>3)continue;for(var v=0;v<s-m;v++)h="0"+h.toString()}f+=h}else d=e[zpt[c]]();"h"===c&&(d=d%12||12);break;case"y":p=!0,f+=r.year,2===s&&(f=f.substr(f.length-2));break;case"a":var g=e.getHours()<12?"am":"pm";n+=t.designator[g];break;case"G":var w=e.getFullYear()<0?0:1,y=t.era[w];xpt(y)&&(y=t.era[w?0:1]),n+=y||"";break;case"'":n+="''"===l?"'":l.replace(/'/g,"");break;case"z":var b=e.getTimezoneOffset(),x=s<4?"+H;-H":t.timeZone.hourFormat;x=x.replace(/:/g,t.numMapper.timeSeparator),0===b?n+=t.timeZone.gmtZeroFormat:(p=!0,f=this.getTimeZoneValue(b,x)),f=t.timeZone.gmtFormat.replace(/\{0\}/,f);break;case":":n+=t.numMapper.numberSymbols.timeSeparator;break;case"/":n+=t.dateSeperator;break;case"W":u=!0,d=rft.getWeekOfYear(e);break;default:n+=l}u&&(p=!0,f=this.checkTwodigitNumber(d,s)),p&&(n+=Dpt.convertValueParts(f,rft.latnParseRegex,t.numMapper.mapper))}return n},e.getCurrentDateValue=function(e,t){return t?Cpt.getHijriDate(e):{year:e.getFullYear(),month:e.getMonth()+1,date:e.getDate()}},e.checkTwodigitNumber=function(e,t){var n=e+"";return 2===t&&2!==n.length?"0"+n:n},e.getTimeZoneValue=function(e,t){var n=this,a=t.split(";")[e>0?1:0],r=Math.abs(e);return a.replace(/HH?|mm/g,function(e){var t=e.length,a=-1!==e.indexOf("H");return n.checkTwodigitNumber(Math.floor(a?r/60:r%60),t)})},e}(),Bpt={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},jpt=["infinity","nan","group","decimal","exponential"],Wpt=function(){function e(){}return e.numberFormatter=function(e,t,n){var a,r=this,i=bpt({},t),o={},l={},s=rft.getDependables(n,e,"",!0);s.numericObject,l.numberMapper=Dpt.getNumberMapper(s.parserObject,Dpt.getNumberingSystem(n),!0),l.currencySymbol=rft.getCurrencySymbol(s.numericObject,i.currency||tft,t.altSymbol),l.percentSymbol=l.numberMapper.numberSymbols.percentSign,l.minusSymbol=l.numberMapper.numberSymbols.minusSign;var c=l.numberMapper.numberSymbols;if(t.format&&!rft.formatRegex.test(t.format))o=rft.customFormat(t.format,l,s.numericObject);else{bpt(i,rft.getProperNumericSkeleton(t.format||"N")),i.isCurrency="currency"===i.type,i.isPercent="percent"===i.type,a=rft.getSymbolPattern(i.type,l.numberMapper.numberSystem,s.numericObject,i.isAccount),i.groupOne=this.checkValueRange(i.maximumSignificantDigits,i.minimumSignificantDigits,!0),this.checkValueRange(i.maximumFractionDigits,i.minimumFractionDigits,!1,!0),Ept(i.fractionDigits)||(i.minimumFractionDigits=i.maximumFractionDigits=i.fractionDigits),Ept(i.useGrouping)&&(i.useGrouping=!0),i.isCurrency&&(a=a.replace(/\u00A4/g,rft.defaultCurrency));var d=a.split(";");if(o.nData=rft.getFormatData(d[1]||"-"+d[0],!0,l.currencySymbol),o.pData=rft.getFormatData(d[0],!1,l.currencySymbol),i.useGrouping&&(i.groupSeparator=c[jpt[2]],i.groupData=this.getGroupingDetails(d[0])),Ept(i.minimumFractionDigits)&&(i.minimumFractionDigits=o.nData.minimumFraction),Ept(i.maximumFractionDigits)){var h=o.nData.maximumFraction;i.maximumFractionDigits=Ept(h)&&i.isPercent?0:h}var u=i.minimumFractionDigits,p=i.maximumFractionDigits;Ept(u)||Ept(p)||u>p&&(i.maximumFractionDigits=u)}return bpt(o.nData,i),bpt(o.pData,i),function(e){return isNaN(e)?c[jpt[1]]:isFinite(e)?r.intNumberFormatter(e,o,l):c[jpt[0]]}},e.getGroupingDetails=function(e){var t={},n=e.match(rft.negativeDataRegex);if(n&&n[4]){var a=n[4],r=a.lastIndexOf(",");if(-1!==r){var i=a.split(".")[0];t.primary=i.length-r-1;var o=a.lastIndexOf(",",r-1);-1!==o&&(t.secondary=r-1-o)}}return t},e.checkValueRange=function(e,t,n,a){var r=a?"f":"s",i=0,o=Bpt["l"+r],l=Bpt["m"+r];if(Ept(e)||(this.checkRange(e,o,a),i++),Ept(t)||(this.checkRange(t,l,a),i++),2===i){if(!(e<t))return!0;Spt(l+"specified must be less than the"+o)}else n&&1===i&&Spt("Both"+l+"and"+l+"must be present");return!1},e.checkRange=function(e,t,n){var a=n?[0,20]:[1,21];(e<a[0]||e>a[1])&&Spt(t+"value must be within the range"+a[0]+"to"+a[1])},e.intNumberFormatter=function(e,t,n){var a;if(!Ept(t.nData.type)){e<0?(e*=-1,a=t.nData):a=0===e&&t.zeroData||t.pData;var r="";return a.isPercent&&(e*=100),a.groupOne?r=this.processSignificantDigits(e,a.minimumSignificantDigits,a.maximumSignificantDigits):(r=this.processFraction(e,a.minimumFractionDigits,a.maximumFractionDigits),a.minimumIntegerDigits&&(r=this.processMinimumIntegers(r,a.minimumIntegerDigits))),"scientific"===a.type&&(r=(r=e.toExponential(a.maximumFractionDigits)).replace("e",n.numberMapper.numberSymbols[jpt[4]])),r=r.replace(".",n.numberMapper.numberSymbols[jpt[3]]),a.useGrouping&&(r=this.groupNumbers(r,a.groupData.primary,a.groupSeparator||",",n.numberMapper.numberSymbols[jpt[3]]||".",a.groupData.secondary)),r=Dpt.convertValueParts(r,rft.latnParseRegex,n.numberMapper.mapper),"N/A"===a.nlead?a.nlead:a.nlead+r+a.nend}},e.processSignificantDigits=function(e,t,n){var a=e+"";return a.length<t?e.toPrecision(t):+(a=e.toPrecision(n))+""},e.groupNumbers=function(e,t,n,a,r){for(var i=!xpt(r)&&0!==r,o=e.split(a),l=o[0],s=l.length,c="";s>t;)c=l.slice(s-t,s)+(c.length?n+c:""),s-=t,i&&(t=r,i=!1);return o[0]=l.slice(0,s)+(c.length?n:"")+c,o.join(a)},e.processFraction=function(e,t,n){var a=(e+"").split(".")[1],r=a?a.length:0;if(t&&r<t){var i="";if(0!==r){i+=e;for(var o=0;o<t-r;o++)i+="0";return i}return i=e.toFixed(t),e.toFixed(t)}return!xpt(n)&&(r>n||0===n)?e.toFixed(n):e+""},e.processMinimumIntegers=function(e,t){var n=e.split("."),a=n[0],r=a.length;if(r<t){for(var i=0;i<t-r;i++)a="0"+a;n[0]=a}return n.join(".")},e}(),Rpt="stand-alone",Fpt=/^[0-9]*$/,Ypt={minute:"setMinutes",hour:"setHours",second:"setSeconds",day:"setDate",month:"setMonth",milliseconds:"setMilliseconds"},qpt=function(){function e(){}return e.dateParser=function(e,t,n){var a,r=this,i=rft.getDependables(n,e,t.calendar),o=Dpt.getCurrentNumericOptions(i.parserObject,Dpt.getNumberingSystem(n),!1,!1),l={},s=t.format||rft.getResultantPattern(t.skeleton,i.dateObject,t.type,!1,""),c="";if(Ept(s))Spt("Format options or type given must be invalid");else{s=rft.ConvertDateToWeekFormat(s),l={isIslamic:rft.islamicRegex.test(t.calendar),pattern:s,evalposition:{},culture:e};for(var d=s.match(rft.dateParseRegex)||[],h=d.length,u=0,p=0,f=!1,m=o.numericRegex,v=Dpt.getNumberMapper(i.parserObject,Dpt.getNumberingSystem(n)),g=0;g<h;g++){var w=d[g],y=w.length,b="K"===w[0]?"h":w[0],x=void 0,E=void 0,k=Ppt[b],M=2===y?"":"?";switch(f&&(u=p,f=!1),b){case"E":case"c":var S;S=i.dateObject[rft.days][Rpt][rft.monthIndex[y]];var A=Dpt.reverseObject(S);c+="("+Object.keys(A).join("|")+")";break;case"M":case"L":case"d":case"m":case"s":case"h":case"H":case"f":if(E=!0,("M"===b||"L"===b)&&y>2){var _;_=i.dateObject.months[Rpt][rft.monthIndex[y]],l[k]=Dpt.reverseObject(_),c+="("+Object.keys(l[k]).join("|")+")"}else if("f"===b){if(y>3)continue;x=!0,c+="("+m+m+"?"+m+"?)"}else x=!0,c+="("+m+m+M+")";"h"===b&&(l.hour12=!0);break;case"W":c+="("+m+(1===y?"?":"")+m+")";break;case"y":E=x=!0,c+=2===y?"("+m+m+")":"("+m+"{"+y+",})";break;case"a":E=!0;var C=fpt("dayPeriods.format.wide",i.dateObject);l[k]=Dpt.reverseObject(C),c+="("+Object.keys(l[k]).join("|")+")";break;case"G":E=!0;var Z=y<=3?"eraAbbr":4===y?"eraNames":"eraNarrow";l[k]=Dpt.reverseObject(fpt("eras."+Z,i.dateObject)),c+="("+Object.keys(l[k]).join("|")+"?)";break;case"z":E=0!==(new Date).getTimezoneOffset(),l[k]=fpt("dates.timeZoneNames",i.parserObject);var H=l[k],I=(a=y<4)?"+H;-H":H.hourFormat;I=I.replace(/:/g,v.timeSeparator),c+="("+this.parseTimeZoneRegx(I,H,m)+")?",f=!0,p=a?6:12;break;case"'":c+="("+w.replace(/'/g,"")+")?";break;default:c+="([\\D])"}E&&(l.evalposition[k]={isNumber:x,pos:g+1+u,hourOnly:a}),g!==h-1||xpt(c)||(l.parserRegex=new RegExp("^"+c+"$","i"))}}return function(e){var t=r.internalDateParse(e,l,o);if(xpt(t)||!Object.keys(t).length)return null;if(l.isIslamic){var n={},a=t.year,i=t.day,s=t.month,c=a?a+"":"",d=2===c.length;a&&s&&i&&!d||(n=Cpt.getHijriDate(new Date)),d&&(a=parseInt((n.year+"").slice(0,2)+c,10));var h=Cpt.toGregorian(a||n.year,s||n.month,i||n.date);t.year=h.getFullYear(),t.month=h.getMonth()+1,t.day=h.getDate()}return r.getDateObject(t)}},e.getDateObject=function(e,t){var n=t||new Date;n.setMilliseconds(0);var a=e.year,r=e.designator,i=e.timeZone;if(!Ept(a)){if((a+"").length<=2)a+=100*Math.floor(n.getFullYear()/100);n.setFullYear(a)}for(var o=0,l=["hour","minute","second","milliseconds","month","day"];o<l.length;o++){var s=l[o],c=e[s];if(Ept(c)&&"day"===s&&n.setDate(1),!Ept(c))if("month"===s){if((c-=1)<0||c>11)return new Date("invalid");var d=n.getDate();n.setDate(1),n[Ypt[s]](c);var h=new Date(n.getFullYear(),c+1,0).getDate();n.setDate(d<h?d:h)}else{if("day"===s){var u=new Date(n.getFullYear(),n.getMonth()+1,0).getDate();if(c<1||c>u)return null}n[Ypt[s]](c)}}if(!Ept(r)){var p=n.getHours();"pm"===r?n.setHours(p+(12===p?0:12)):12===p&&n.setHours(0)}if(!Ept(i)){var f=i-n.getTimezoneOffset();0!==f&&n.setMinutes(n.getMinutes()+f)}return n},e.internalDateParse=function(e,t,n){var a=e.match(t.parserRegex),r={hour:0,minute:0,second:0};if(xpt(a))return null;for(var i=0,o=Object.keys(t.evalposition);i<o.length;i++){var l=o[i],s=t.evalposition[l],c=a[s.pos];if(s.isNumber)r[l]=this.internalNumberParser(c,n);else if("timeZone"!==l||Ept(c))c="month"!==l||t.isIslamic||"en"!==t.culture&&"en-GB"!==t.culture&&"en-US"!==t.culture?c:c[0].toUpperCase()+c.substring(1).toLowerCase(),r[l]=t[l][c];else{var d=s.pos,h=void 0,u=a[d+1],p=!Ept(u);s.hourOnly?h=60*this.getZoneValue(p,u,a[d+4],n):(h=60*this.getZoneValue(p,u,a[d+7],n),h+=this.getZoneValue(p,a[d+4],a[d+10],n)),xpt(h)||(r[l]=h)}}return t.hour12&&(r.hour12=!0),r},e.internalNumberParser=function(e,t){return e=Dpt.convertValueParts(e,t.numberParseRegex,t.numericPair),Fpt.test(e)?+e:null},e.parseTimeZoneRegx=function(e,t,n){var a,r,i=t.gmtFormat,o="("+n+")("+n+")";return a=e.replace("+","\\+"),r=(a=-1!==e.indexOf("HH")?a.replace(/HH|mm/g,"("+o+")"):a.replace(/H|m/g,"("+o+"?)")).split(";").map(function(e){return i.replace("{0}",e)}),a=r.join("|")+"|"+t.gmtZeroFormat},e.getZoneValue=function(e,t,n,a){var r=e?t:n;if(!r)return 0;var i=this.internalNumberParser(r,a);return e?-i:i},e}(),Upt=/^([^0-9]*)(([0-9,]*[0-9]+)(\.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$/,Gpt=/,/g,Kpt=["minusSign","infinity"],Qpt=function(){function e(){}return e.numberParser=function(e,t,n){var a,r,i=this,o=rft.getDependables(n,e,"",!0),l={custom:!0};if(rft.formatRegex.test(t.format)||!t.format?(bpt(l,rft.getProperNumericSkeleton(t.format||"N")),l.custom=!1,l.fractionDigits||t.maximumFractionDigits&&(l.maximumFractionDigits=t.maximumFractionDigits)):bpt(l,rft.customFormat(t.format,null,null)),fpt("numbers",o.parserObject),a=Dpt.getCurrentNumericOptions(o.parserObject,Dpt.getNumberingSystem(n),!0,!1),l.symbolRegex=Dpt.getSymbolRegex(Object.keys(a.symbolMatch)),l.infinity=a.symbolNumberSystem[Kpt[1]],r=rft.getSymbolPattern(l.type,a.numberSystem,o.numericObject,l.isAccount)){var s=(r=r.replace(/\u00A4/g,rft.defaultCurrency)).split(";");l.nData=rft.getFormatData(s[1]||"-"+s[0],!0,""),l.pData=rft.getFormatData(s[0],!0,"")}return function(e){return i.getParsedNumber(e,l,a)}},e.getParsedNumber=function(e,t,n){var a,r,i,o,l,s;if(-1!==e.indexOf(t.infinity))return 1/0;e=Dpt.convertValueParts(e,t.symbolRegex,n.symbolMatch),0===(e=-1!==(e=Dpt.convertValueParts(e,n.numberParseRegex,n.numericPair)).indexOf("-")?e.replace("-.","-0."):e).indexOf(".")&&(e="0"+e);var c=e.match(Upt);if(xpt(c))return NaN;o=c[1],i=c[2];var d=c[5];return l=c[6],r=(a=t.custom?o===t.nData.nlead&&l===t.nData.nend:-1!==o.indexOf(t.nData.nlead)&&-1!==l.indexOf(t.nData.nend))?t.nData.isPercent:t.pData.isPercent,i=i.replace(Gpt,""),d&&(i+=d),s=+i,("percent"===t.type||r)&&(s/=100),(t.custom||t.fractionDigits)&&(s=parseFloat(s.toFixed(t.custom?a?t.nData.maximumFractionDigits:t.pData.maximumFractionDigits:t.fractionDigits))),t.maximumFractionDigits&&(s=this.convertMaxFracDigits(i,t,s,a)),a&&(s*=-1),s},e.convertMaxFracDigits=function(e,t,n,a){var r=e.split(".");return r[1]&&r[1].length>t.maximumFractionDigits&&(n=+n.toFixed(t.custom?a?t.nData.maximumFractionDigits:t.pData.maximumFractionDigits:t.maximumFractionDigits)),n},e}(),Xpt=function(){function e(e){this.ranArray=[],this.boundedEvents={},xpt(e)||(this.context=e)}return e.prototype.on=function(e,t,n,a){if(!xpt(t)){var r=n||this.context;this.notExist(e)?this.boundedEvents[e]=[{handler:t,context:r}]:xpt(a)?this.isHandlerPresent(this.boundedEvents[e],t)||this.boundedEvents[e].push({handler:t,context:r}):-1===this.ranArray.indexOf(a)&&(this.ranArray.push(a),this.boundedEvents[e].push({handler:t,context:r,id:a}))}},e.prototype.off=function(e,t,n){if(!this.notExist(e)){var a=fpt(e,this.boundedEvents);if(t){for(var r=0;r<a.length;r++)if(n){if(a[r].id===n){a.splice(r,1);var i=this.ranArray.indexOf(n);-1!==i&&this.ranArray.splice(i,1);break}}else if(t===a[r].handler){a.splice(r,1);break}}else delete this.boundedEvents[e]}},e.prototype.notify=function(e,t,n,a){if(this.notExist(e))n&&n.call(this,t);else{t&&(t.name=e);var r=fpt(e,this.boundedEvents).slice(0);if(window.Blazor)return this.blazorCallback(r,t,n,a,0);for(var i=0,o=r;i<o.length;i++){var l=o[i];l.handler.call(l.context,t)}n&&n.call(this,t)}},e.prototype.blazorCallback=function(e,t,n,a,r){var i=this,o=r===e.length-1;if(r<e.length){var l=e[r],s=l.handler.call(l.context,t);if(s&&"function"==typeof s.then){if(!n)return s;s.then(function(s){if(s="string"==typeof s&&i.isJson(s)?JSON.parse(s,i.dateReviver):s,bpt(t,t,s,!0),!n||!o)return i.blazorCallback(e,t,n,a,r+1);n.call(l.context,t)}).catch(function(e){a&&a.call(l.context,"string"==typeof e&&i.isJson(e)?JSON.parse(e,i.dateReviver):e)})}else{if(!n||!o)return this.blazorCallback(e,t,n,a,r+1);n.call(l.context,t)}}},e.prototype.dateReviver=function(e,t){return _pt&&"string"==typeof t&&null!==t.match(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}/)?new Date(t):t},e.prototype.isJson=function(e){try{JSON.parse(e)}catch(e){return!1}return!0},e.prototype.destroy=function(){this.boundedEvents=this.context=void 0},e.prototype.notExist=function(e){return!1===this.boundedEvents.hasOwnProperty(e)||this.boundedEvents[e].length<=0},e.prototype.isHandlerPresent=function(e,t){for(var n=0,a=e;n<a.length;n++){if(a[n].handler===t)return!0}return!1},e}(),Jpt=new Xpt,$pt={},eft="en-US",tft="USD",nft=["numericObject","dateObject"],aft=function(){function e(e){e&&(this.culture=e)}return e.prototype.getDateFormat=function(e){return Tpt.dateFormat(this.getCulture(),e||{type:"date",skeleton:"short"},$pt)},e.prototype.getNumberFormat=function(e){return e&&!e.currency&&(e.currency=tft),Wpt.numberFormatter(this.getCulture(),e||{},$pt)},e.prototype.getDateParser=function(e){return qpt.dateParser(this.getCulture(),e||{skeleton:"short",type:"date"},$pt)},e.prototype.getNumberParser=function(e){return Qpt.numberParser(this.getCulture(),e||{format:"N"},$pt)},e.prototype.formatNumber=function(e,t){return this.getNumberFormat(t)(e)},e.prototype.formatDate=function(e,t){return this.getDateFormat(t)(e)},e.prototype.parseDate=function(e,t){return this.getDateParser(t)(e)},e.prototype.parseNumber=function(e,t){return this.getNumberParser(t)(e)},e.prototype.getDatePattern=function(e,t){return rft.getActualDateTimeFormat(this.getCulture(),e,$pt,t)},e.prototype.getNumberPattern=function(e,t){return rft.getActualNumberFormat(this.getCulture(),e,$pt,t)},e.prototype.getFirstDayOfWeek=function(){return rft.getWeekData(this.getCulture(),$pt)},e.prototype.getCulture=function(){return this.culture||eft},e}();var rft,ift={"en-US":{d:"M/d/y",D:"EEEE, MMMM d, y",f:"EEEE, MMMM d, y h:mm a",F:"EEEE, MMMM d, y h:mm:s a",g:"M/d/y h:mm a",G:"M/d/yyyy h:mm:ss tt",m:"MMMM d",M:"MMMM d",r:"ddd, dd MMM yyyy HH':'mm':'ss 'GMT'",R:"ddd, dd MMM yyyy HH':'mm':'ss 'GMT'",s:"yyyy'-'MM'-'dd'T'HH':'mm':'ss",t:"h:mm tt",T:"h:m:s tt",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'",U:"dddd, MMMM d, yyyy h:mm:ss tt",y:"MMMM yyyy",Y:"MMMM yyyy"}};!function(e){e.negativeDataRegex=/^(('[^']+'|''|[^*#@0,.E])*)(\*.)?((([#,]*[0,]*0+)(\.0*[0-9]*#*)?)|([#,]*@+#*))(E\+?0+)?(('[^']+'|''|[^*#@0,.E])*)$/,e.customRegex=/^(('[^']+'|''|[^*#@0,.])*)(\*.)?((([0#,]*[0,]*[0#]*[0#\ ]*)(\.[0#]*)?)|([#,]*@+#*))(E\+?0+)?(('[^']+'|''|[^*#@0,.E])*)$/,e.latnParseRegex=/0|1|2|3|4|5|6|7|8|9/g;var t=/[0-9]/g;e.defaultCurrency="$";var n=["infinity","nan","group","decimal"],a=/G|M|L|H|c|'| a|yy|y|EEEE|E/g,r={G:"",M:"m",L:"m",H:"h",c:"d","'":'"'," a":" AM/PM",yy:"yy",y:"yyyy",EEEE:"dddd",E:"ddd"};e.dateConverterMapper=/dddd|ddd/gi;e.islamicRegex=/^islamic/;var i={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};e.formatRegex=/(^[ncpae]{1})([0-1]?[0-9]|20)?$/i,e.currencyFormatRegex=/(^[ca]{1})([0-1]?[0-9]|20)?$/i,e.curWithoutNumberRegex=/(c|a)$/gi;var o={$:"isCurrency","%":"isPercent","-":"isNegative",0:"nlead",1:"nend"};function l(t,n,a,r,i){var o,l=a||"date";if(i)o=h({skeleton:t},i).format||h({skeleton:"d"},"en-US").format;else{if(-1!==e.basicPatterns.indexOf(t)){if(o=fpt(l+"Formats."+t,n),"dateTime"===l){var s=fpt("dateFormats."+t,n),c=fpt("timeFormats."+t,n);o=o.replace("{1}",s).replace("{0}",c)}}else o=fpt("dateTimeFormats.availableFormats."+t,n);Ept(o)&&"yMd"===t&&(o="M/d/y")}return o}function s(t,n,a,r){var i={},o=a||"gregorian";if(i.parserObject=Dpt.getMainObject(t,n)||e.defaultObject,r)i.numericObject=fpt("numbers",i.parserObject);else{var l="dates.calendars."+o;i.dateObject=fpt(l,i.parserObject)}return i}function c(e,t,n,a){return fpt(e+"Formats-numberSystem-"+t+(a?".accounting":".standard"),n)||(a?fpt(e+"Formats-numberSystem-"+t+".standard",n):"")}function d(t){t.match(e.dateConverterMapper);return t}function h(e,t){var n=e.format||e.skeleton,a=fpt((t||"en-US")+"."+n,ift);return a||(a=fpt("en-US."+n,ift)),a&&(a=d(a),e.format=a.replace(/tt/,"a")),e}function u(t){var n=t.match(e.formatRegex),a={},r=n[1].toUpperCase();return a.isAccount="A"===r,a.type=e.patternMatcher[r],t.length>1&&(a.fractionDigits=parseInt(n[2],10)),a}function p(n,a,r,i){var o=i?{}:{nlead:"",nend:""},l=n.match(e.customRegex);if(l){i||(o.nlead=f(l[1],r),o.nend=f(l[10],r),o.groupPattern=l[4]);var s=l[7];if(s&&a){var c=s.match(t);xpt(c)?o.minimumFraction=0:o.minimumFraction=c.length,o.maximumFraction=s.length-1}}return o}function f(t,n){return t?t.replace(e.defaultCurrency,n):""}function m(e,t,n){return fpt("currencies."+t+(n?"."+n:".symbol"),e)||fpt("currencies."+t+".symbol-alt-narrow",e)||"$"}function v(t,a,r){var i={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},o=t.match(e.customRegex);if(xpt(o)||""===o[5]&&"N/A"!==t)return i.type=void 0,i;i.nlead=o[1],i.nend=o[10];var l=o[6],s=!!l.match(/\ $/g),d=-1!==l.replace(/\ $/g,"").indexOf(" ");i.useGrouping=-1!==l.indexOf(",")||d,l=l.replace(/,/g,"");var h=o[7];if(-1!==l.indexOf("0")&&(i.minimumIntegerDigits=l.length-l.indexOf("0")),xpt(h)||(i.minimumFractionDigits=h.lastIndexOf("0"),i.maximumFractionDigits=h.lastIndexOf("#"),-1===i.minimumFractionDigits&&(i.minimumFractionDigits=0),(-1===i.maximumFractionDigits||i.maximumFractionDigits<i.minimumFractionDigits)&&(i.maximumFractionDigits=i.minimumFractionDigits)),xpt(a)?bpt(i,g([i.nlead,i.nend],"%","%")):(bpt(i,g([i.nlead,i.nend],"$",a.currencySymbol)),i.isCurrency||bpt(i,g([i.nlead,i.nend],"%",a.percentSymbol))),!xpt(r)){var u=c(i.type,a.numberMapper.numberSystem,r,!1);i.useGrouping&&(i.groupSeparator=d?" ":a.numberMapper.numberSymbols[n[2]],i.groupData=Wpt.getGroupingDetails(u.split(";")[0])),i.nlead=i.nlead.replace(/'/g,""),i.nend=s?" "+i.nend.replace(/'/g,""):i.nend.replace(/'/g,"")}return i}function g(e,t,n){for(var a={nlead:e[0],nend:e[1]},r=0;r<2;r++){var i=e[r],l=i.indexOf(t);if(-1!==l&&(l<i.indexOf("'")||l>i.lastIndexOf("'"))){a[o[r]]=i.substr(0,l)+n+i.substr(l+1),a[o[t]]=!0,a.type=a.isCurrency?"currency":"percent";break}}return a}function w(e,t,n){e+=".";for(var a=0;a<t;a++)e+="0";if(t<n)for(var r=n-t,i=0;i<r;i++)e+="#";return e}function y(e,t){for(var n=e.split("."),a="",r=0;r<t;r++)a+="0";return n[1]?a+"."+n[1]:a}function b(e){var t=e.split("."),n=t[0],a=3-n.length%3;e="";for(var r=(n=(a&&1===a?"#":2===a?"##":"")+n).length-1;r>0;r-=3)e=","+n[r-2]+n[r-1]+n[r]+e;return e=e.slice(1),t[1]?e+"."+t[1]:e}e.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,e.basicPatterns=["short","medium","long","full"],e.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhuʻl-Q.",12:"Dhuʻl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabiʻ I",4:"Rabiʻ II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Shaʻban",9:"Ramadan",10:"Shawwal",11:"Dhuʻl-Qiʻdah",12:"Dhuʻl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"€","symbol-alt-narrow":"€"},GBP:{displayName:"British Pound","symbol-alt-narrow":"£"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"×",perMille:"‰",infinity:"∞",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"¤#,##0.00",accounting:"¤#,##0.00;(¤#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},e.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"∞"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},e.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},e.month="months",e.days="days",e.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},e.getResultantPattern=l,e.getDependables=s,e.getSymbolPattern=c,e.ConvertDateToWeekFormat=d,e.compareBlazorDateFormats=h,e.getProperNumericSkeleton=u,e.getFormatData=p,e.changeCurrencySymbol=f,e.getCurrencySymbol=m,e.customFormat=function(e,t,n){for(var a={},r=e.split(";"),i=["pData","nData","zeroData"],o=0;o<r.length;o++)a[i[o]]=v(r[o],t,n);return xpt(a.nData)&&(a.nData=bpt({},a.pData),a.nData.nlead=xpt(t)?"-"+a.nData.nlead:t.minusSymbol+a.nData.nlead),a},e.customNumberFormat=v,e.isCurrencyPercent=g,e.getDateSeparator=function(e){var t=(fpt("dateFormats.short",e)||"").match(/[d‏M‏]([^d‏M])[d‏M‏]/i);return t?t[1]:"/"},e.getActualDateTimeFormat=function(e,t,n,i){var o=s(n,e,t.calendar),c=t.format||l(t.skeleton,o.dateObject,t.type);if(i){if(c=c.replace(a,function(e){return r[e]}),-1!==c.indexOf("z")){var d=c.match(/z/g).length,h=void 0,u={timeZone:{}};u.numMapper=Dpt.getNumberMapper(o.parserObject,Dpt.getNumberingSystem(n)),u.timeZone=fpt("dates.timeZoneNames",o.parserObject);var p=(new Date).getTimezoneOffset(),f=d<4?"+H;-H":u.timeZone.hourFormat;f=f.replace(/:/g,u.numMapper.timeSeparator),0===p?h=u.timeZone.gmtZeroFormat:(h=Tpt.getTimeZoneValue(p,f),h=u.timeZone.gmtFormat.replace(/\{0\}/,h)),c=c.replace(/[z]+/,'"'+h+'"')}c=c.replace(/ $/,"")}return c},e.getActualNumberFormat=function(t,n,a,r){var i,o=s(a,t,"",!0),l={custom:!0};o.numericObject;var d={},h=(n.format||"").match(e.currencyFormatRegex);!e.formatRegex.test(n.format)||u(n.format||"N");var f,v={};if(h){v.numberMapper=Dpt.getNumberMapper(o.parserObject,Dpt.getNumberingSystem(a),!0);var g=m(o.numericObject,n.currency||tft,n.altSymbol),x=c("currency",v.numberMapper.numberSystem,o.numericObject,/a/i.test(n.format)),E=(x=x.replace(/\u00A4/g,g)).split(";");d.hasNegativePattern=E.length>1,d.nData=p(E[1]||"-"+E[0],!0,g),d.pData=p(E[0],!1,g),h[2]||n.minimumFractionDigits||n.maximumFractionDigits||(i=p(x.split(";")[0],!0,"",!0).minimumFraction)}if(e.formatRegex.test(n.format)||!n.format){if(bpt(l,u(n.format||"N")),l.custom=!1,f="###0",l.fractionDigits||n.minimumFractionDigits||n.maximumFractionDigits||i){l.fractionDigits&&(n.minimumFractionDigits=n.maximumFractionDigits=l.fractionDigits),f=w(f,i||l.fractionDigits||n.minimumFractionDigits||0,n.maximumFractionDigits||0)}if(n.minimumIntegerDigits&&(f=y(f,n.minimumIntegerDigits)),n.useGrouping&&(f=b(f)),"currency"===l.type||(l.type,0)){var k=f;f=d.pData.nlead+k+d.pData.nend,d.hasNegativePattern&&(f+=";"+d.nData.nlead+k+d.nData.nend)}"percent"===l.type&&(f+=" %")}else f=n.format.replace(/'/g,'"');return Object.keys(v).length>0&&(f=r?f:function(e,t){if(-1!==e.indexOf(",")){var n=e.split(",");e=n[0]+fpt("numberMapper.numberSymbols.group",t)+n[1].replace(".",fpt("numberMapper.numberSymbols.decimal",t))}else e=e.replace(".",fpt("numberMapper.numberSymbols.decimal",t));return e}(f,v)),f},e.fractionDigitsPattern=w,e.minimumIntegerPattern=y,e.groupingPattern=b,e.getWeekData=function(e,t){var n="sun",a=fpt("supplemental.weekData.firstDay",t),r=e;return/en-/.test(r)&&(r=r.slice(3)),r=r.slice(0,2).toUpperCase()+r.substr(2),a&&(n=a[r]||a[r.slice(0,2)]||"sun"),i[n]},e.replaceBlazorCurrency=function(e,t,n){var a=fpt(n||"",Npt);if(t!==a)for(var r=0,i=e;r<i.length;r++){var o=i[r];o.nend=o.nend.replace(t,a),o.nlead=o.nlead.replace(t,a)}},e.getWeekOfYear=function(e){var t,n=new Date(e.getFullYear(),0,1),a=n.getDay();a=a>=0?a:a+7;var r=Math.floor((e.getTime()-n.getTime()-6e4*(e.getTimezoneOffset()-n.getTimezoneOffset()))/864e5)+1;if(a<4){if((t=Math.floor((r+a-1)/7)+1)>52){var i=new Date(e.getFullYear()+1,0,1).getDay();t=(i=i>=0?i:i+7)<4?1:53}}else t=Math.floor((r+a-1)/7);return t}}(rft||(rft={}));var oft=/^(.*?):[ \t]*([^\r\n]*)$/gm,lft=function(){function e(e,t,n,a){this.mode=!0,this.emitError=!0,this.options={},"string"==typeof e?(this.url=e,this.type=t?t.toUpperCase():"GET",this.mode=!!xpt(n)||n):"object"==typeof e&&(this.options=e,ypt(this,this.options)),this.type=this.type?this.type.toUpperCase():"GET",this.contentType=void 0!==this.contentType?this.contentType:a}return e.prototype.send=function(e){var t=this;this.data=xpt(e)?this.data:e;var n={cancel:!1,httpRequest:null};return new Promise(function(e,a){t.httpRequest=new XMLHttpRequest,t.httpRequest.onreadystatechange=function(){t.stateChange(e,a)},xpt(t.onLoad)||(t.httpRequest.onload=t.onLoad),xpt(t.onProgress)||(t.httpRequest.onprogress=t.onProgress),xpt(t.onAbort)||(t.httpRequest.onabort=t.onAbort),xpt(t.onError)||(t.httpRequest.onerror=t.onError),xpt(t.onUploadProgress)||(t.httpRequest.upload.onprogress=t.onUploadProgress),t.httpRequest.open(t.type,t.url,t.mode),xpt(t.data)||null===t.contentType||t.httpRequest.setRequestHeader("Content-Type",t.contentType||"application/json; charset=utf-8"),t.beforeSend&&(n.httpRequest=t.httpRequest,t.beforeSend(n)),n.cancel||t.httpRequest.send(xpt(t.data)?null:t.data)})},e.prototype.successHandler=function(e){return this.onSuccess&&this.onSuccess(e,this),e},e.prototype.failureHandler=function(e){return this.onFailure&&this.onFailure(this.httpRequest),e},e.prototype.stateChange=function(e,t){var n=this.httpRequest.responseText;if(this.dataType&&"json"===this.dataType.toLowerCase())if(""===n)n=void 0;else try{n=JSON.parse(n)}catch(e){}4===this.httpRequest.readyState&&(this.httpRequest.status>=200&&this.httpRequest.status<=299||304===this.httpRequest.status?e(this.successHandler(n)):this.emitError?t(new Error(this.failureHandler(this.httpRequest.statusText))):e())},e.prototype.getResponseHeader=function(e){var t,n;t={};for(var a=oft.exec(this.httpRequest.getAllResponseHeaders());a;)t[a[1].toLowerCase()]=a[2],a=oft.exec(this.httpRequest.getAllResponseHeaders());return xpt(n=t[e.toLowerCase()])?null:n},e}(),sft=/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini|mobile/i,cft=/msie|trident/i,dft=/Trident\/7\./,hft=/(ipad|iphone|ipod touch)/i,uft=/(ipad|iphone|ipod touch);.*os 7_\d|(ipad|iphone|ipod touch);.*os 8_\d/i,pft=/android/i,fft=/trident|windows phone|edge/i,mft=/(version)[ /]([\w.]+)/i,vft={OPERA:/(opera|opr)(?:.*version|)[ /]([\w.]+)/i,EDGE:/(edge)(?:.*version|)[ /]([\w.]+)/i,CHROME:/(chrome|crios)[ /]([\w.]+)/i,PANTHOMEJS:/(phantomjs)[ /]([\w.]+)/i,SAFARI:/(safari)[ /]([\w.]+)/i,WEBKIT:/(webkit)[ /]([\w.]+)/i,MSIE:/(msie|trident) ([\w.]+)/i,MOZILLA:/(mozilla)(?:.*? rv:([\w.]+)|)/i};"undefined"!=typeof window&&(window.browserDetails=window.browserDetails||{});var gft=function(){function e(){}return e.extractBrowserDetail=function(){for(var t={culture:{}},n=[],a=0,r=Object.keys(vft);a<r.length;a++){var i=r[a];if(n=e.userAgent.match(vft[i])){if(t.name="opr"===n[1].toLowerCase()?"opera":n[1].toLowerCase(),t.name="crios"===n[1].toLowerCase()?"chrome":t.name,t.version=n[2],t.culture.name=t.culture.language=navigator.language,e.userAgent.match(dft)){t.name="msie";break}var o=e.userAgent.match(mft);"safari"===t.name&&o&&(t.version=o[2]);break}}return t},e.getEvent=function(t){var n={start:{isPointer:"pointerdown",isTouch:"touchstart",isDevice:"mousedown"},move:{isPointer:"pointermove",isTouch:"touchmove",isDevice:"mousemove"},end:{isPointer:"pointerup",isTouch:"touchend",isDevice:"mouseup"},cancel:{isPointer:"pointercancel",isTouch:"touchcancel",isDevice:"mouseleave"}};return e.isPointer?n[t].isPointer:e.isTouch?n[t].isTouch+(e.isDevice?"":" "+n[t].isDevice):n[t].isDevice},e.getTouchStartEvent=function(){return e.getEvent("start")},e.getTouchEndEvent=function(){return e.getEvent("end")},e.getTouchMoveEvent=function(){return e.getEvent("move")},e.getTouchCancelEvent=function(){return e.getEvent("cancel")},e.getValue=function(t,n){var a=window.browserDetails;return"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===e.isTouch&&(a.isIos=!0,a.isDevice=!0,a.isTouch=!0,a.isPointer=!0),void 0===a[t]?a[t]=n.test(e.userAgent):a[t]},Object.defineProperty(e,"userAgent",{get:function(){return e.uA},set:function(t){e.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(e,"info",{get:function(){return Ept(window.browserDetails.info)?window.browserDetails.info=e.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isIE",{get:function(){return e.getValue("isIE",cft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isTouch",{get:function(){return Ept(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isPointer",{get:function(){return Ept(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isMSPointer",{get:function(){return Ept(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isDevice",{get:function(){return e.getValue("isDevice",sft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isIos",{get:function(){return e.getValue("isIos",hft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isIos7",{get:function(){return e.getValue("isIos7",uft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isAndroid",{get:function(){return e.getValue("isAndroid",pft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isWebView",{get:function(){return Ept(window.browserDetails.isWebView)?(window.browserDetails.isWebView=!(Ept(window.cordova)&&Ept(window.PhoneGap)&&Ept(window.phonegap)&&"object"!==window.forge),window.browserDetails.isWebView):window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(e,"isWindows",{get:function(){return e.getValue("isWindows",fft)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchStartEvent",{get:function(){return Ept(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=e.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchMoveEvent",{get:function(){return Ept(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=e.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchEndEvent",{get:function(){return Ept(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=e.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(e,"touchCancelEvent",{get:function(){return Ept(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=e.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),e.uA="undefined"!=typeof navigator?navigator.userAgent:"",e}(),wft=function(){function e(){}return e.addOrGetEventData=function(e){return"__eventList"in e?e.__eventList.events:(e.__eventList={},e.__eventList.events=[])},e.add=function(t,n,a,r,i){var o,l,s,c,d=e.addOrGetEventData(t);i?(l=a,s=i,o=function(){var e=this,t=arguments;clearTimeout(c),c=setTimeout(function(){return c=null,l.apply(e,t)},s)}):o=a,r&&(o=o.bind(r));for(var h=n.split(" "),u=0;u<h.length;u++)d.push({name:h[u],listener:a,debounce:o}),gft.isIE?t.addEventListener(h[u],o):t.addEventListener(h[u],o,{passive:!1});return o},e.remove=function(t,n,a){for(var r=e.addOrGetEventData(t),i=n.split(" "),o=function(e){var n,o=-1;r&&0!==r.length&&r.some(function(t,r){return t.name===i[e]&&t.listener===a&&(o=r,n=t.debounce,!0)}),-1!==o&&r.splice(o,1),n&&t.removeEventListener(i[e],n)},l=0;l<i.length;l++)o(l)},e.clearEvents=function(t){var n,a;a=bpt([],a,n=e.addOrGetEventData(t));for(var r=0;r<a.length;r++)t.removeEventListener(a[r].name,a[r].debounce),n.shift()},e.trigger=function(t,n,a){for(var r=0,i=e.addOrGetEventData(t);r<i.length;r++){var o=i[r];o.name===n&&o.debounce.call(this,a)}},e}(),yft=/^svg|^path|^g/;function bft(e,t){var n=yft.test(e)?document.createElementNS("http://www.w3.org/2000/svg",e):document.createElement(e);return void 0===t||(n.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(n.className=t.className),void 0!==t.id&&(n.id=t.id),void 0!==t.styles&&n.setAttribute("style",t.styles),void 0!==t.attrs&&Hft(n,t.attrs)),n}function xft(e,t){for(var n=kft(t),a=0,r=e;a<r.length;a++)for(var i=r[a],o=0,l=n;o<l.length;o++){var s=l[o];if(wpt(i)){var c=fpt("attributes.className",i);xpt(c)?mpt("attributes.className",s,i):new RegExp("\\b"+s+"\\b","i").test(c)||mpt("attributes.className",c+" "+s,i)}else i.classList.contains(s)||i.classList.add(s)}return e}function Eft(e,t){for(var n=kft(t),a=0,r=e;a<r.length;a++){var i=r[a],o=wpt(i);if(o?fpt("attributes.className",i):""!==i.className)for(var l=0,s=n;l<s.length;l++){var c=s[l];if(o){var d=fpt("attributes.className",i).split(" "),h=d.indexOf(c);-1!==h&&d.splice(h,1),mpt("attributes.className",d.join(" "),i)}else i.classList.remove(c)}}return e}function kft(e){var t=[];return"string"==typeof e?t.push(e):t=e,t}function Mft(e){var t=e;return""===t.style.visibility&&t.offsetWidth>0}function Sft(e,t,n){for(var a=document.createDocumentFragment(),r=0,i=e;r<i.length;r++){var o=i[r];a.appendChild(o)}return t.insertBefore(a,t.firstElementChild),n&&_ft(t),e}function Aft(e,t,n){for(var a=document.createDocumentFragment(),r=0,i=e;r<i.length;r++){var o=i[r];a.appendChild(o)}return t.appendChild(a),n&&_ft(t),e}function _ft(e){e.querySelectorAll("script").forEach(function(e){var t=document.createElement("script");t.text=e.innerHTML,document.head.appendChild(t),Cft(t)})}function Cft(e){var t=e.parentNode;if(t)return t.removeChild(e)}function Zft(e){var t=e.parentNode;wft.clearEvents(e),t.removeChild(e)}function Hft(e,t){for(var n=e,a=0,r=Object.keys(t);a<r.length;a++){var i=r[a];if(wpt(n)){var o=i;"tabindex"===i&&(o="tabIndex"),n.attributes[o]=t[i]}else n.setAttribute(i,t[i])}return n}function Ift(e,t,n){return void 0===t&&(t=document),e=Nft(e),t.querySelector(e)}function Dft(e,t,n){return void 0===t&&(t=document),e=Nft(e),t.querySelectorAll(e)}function Nft(e){var t=/(!|"|\$|%|&|'|\(|\)|\*|\/|:|;|<|=|\?|@|\]|\^|`|{|}|\||\+|~)/g;if(e.match(/#[0-9]/g)||e.match(t)){for(var n=e.split(","),a=0;a<n.length;a++){for(var r=n[a].split(" "),i=0;i<r.length;i++)if(r[i].indexOf("#")>-1&&!r[i].match(/\[.*\]/)){var o=r[i].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var l=r[i].split(".");l[0]=l[0].replace(/#/,"[id='")+"']",r[i]=l.join(".")}}n[a]=r.join(" ")}return n.join(",")}return e}function Oft(e,t){var n=e;if("function"==typeof n.closest)return n.closest(t);for(;n&&1===n.nodeType;){if(Vft(n,t))return n;n=n.parentNode}return null}function Lft(e,t){void 0!==t&&Object.keys(t).forEach(function(n){e.style[n]=t[n]})}function Vft(e,t){var n=e.matches||e.msMatchesSelector||e.webkitMatchesSelector;return n?n.call(e,t):-1!==[].indexOf.call(document.querySelectorAll(t),e)}var zft=new RegExp("]"),Pft=function(){function e(e,t){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Xpt(this),Ept(t)||(this.element="string"==typeof t?document.querySelector(t):t,xpt(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),Ept(e)||this.setProperties(e,!0),this.isDestroyed=!1}return e.prototype.setProperties=function(e,t){var n=this.isProtectedOnChange;this.isProtectedOnChange=!!t,ypt(this,e),!0!==t&&(ypt(this.changedProperties,e),this.dataBind()),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=n},e.callChildDataBind=function(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){var r=a[n];if(t[r]instanceof Array)for(var i=0,o=t[r];i<o.length;i++){var l=o[i];void 0!==l.dataBind&&l.dataBind()}else t[r].dataBind()}},e.prototype.clearChanges=function(){this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.childChangedProperties={}},e.prototype.dataBind=function(){if(e.callChildDataBind(this.childChangedProperties,this),Object.getOwnPropertyNames(this.changedProperties).length){var t=this.isProtectedOnChange,n=this.changedProperties,a=this.oldProperties;this.clearChanges(),this.isProtectedOnChange=!0,this.onPropertyChanged(n,a),this.isProtectedOnChange=t}},e.prototype.serverDataBind=function(e){},e.prototype.saveChanges=function(e,t,n){this.isProtectedOnChange||(this.oldProperties[e]=n,this.changedProperties[e]=t,this.finalUpdate(),this.finalUpdate=function(e){var t,n=new Uint16Array(5);(window.msCrypto||window.crypto).getRandomValues(n);var a="ej2"+function(e){for(var t="",n=0;n<5;n++)t+=(n?",":"")+e[n];return t}(n),r=function(n){n.source===window&&"string"==typeof n.data&&n.data.length<=32&&n.data===a&&(e(),t())};return window.addEventListener("message",r,!1),window.postMessage(a,"*"),t=function(){window.removeEventListener("message",r),e=r=a=void 0}}(this.dataBind.bind(this)))},e.prototype.addEventListener=function(e,t){this.modelObserver.on(e,t)},e.prototype.removeEventListener=function(e,t){this.modelObserver.off(e,t)},e.prototype.trigger=function(e,t,n,a){var r=this;if(!0!==this.isDestroyed){var i=this.isProtectedOnChange;this.isProtectedOnChange=!1;var o=this.modelObserver.notify(e,t,n,a);if(zft.test(e)){var l=fpt(e,this);if(l){if(window.Blazor){var s=l.call(this,t);s&&"function"==typeof s.then?n?s.then(function(e){n&&(e="string"==typeof e&&r.modelObserver.isJson(e)?JSON.parse(e):e,n.call(r,e))}).catch(function(e){a&&(e="string"==typeof e&&r.modelObserver.isJson(e)?JSON.parse(e):e,a.call(r,e))}):o=s:n&&n.call(this,t)}else l.call(this,t),n&&n.call(this,t)}else n&&n.call(this,t)}return this.isProtectedOnChange=i,o}},e.prototype.addInstance=function(){var e="e-"+this.getModuleName().toLowerCase();xft([this.element],["e-lib",e]),xpt(this.element.ej2_instances)?mpt("ej2_instances",[this],this.element):this.element.ej2_instances.push(this)},e.prototype.destroy=function(){var e=this;this.element.ej2_instances=this.element.ej2_instances.filter(function(t){return t!==e}),Eft([this.element],["e-"+this.getModuleName()]),0===this.element.ej2_instances.length&&Eft([this.element],["e-lib"]),this.clearChanges(),this.modelObserver.destroy(),this.isDestroyed=!0},e}();function Tft(e,t,n,a){return e.properties.hasOwnProperty(t)&&e.properties[t]instanceof a||(e.properties[t]=ppt(a,[e,t,n])),e.properties[t]}function Bft(e,t,n,a,r,i){for(var o=[],l=n?n.length:0,s=0;s<l;s++){var c=a;if(i&&(c=a(n[s],e)),r){var d=ppt(c,[e,t,{},!0]);d.setProperties(n[s],!0),o.push(d)}else o.push(ppt(c,[e,t,n[s],!1]))}return o}function jft(e,t){return function(){return this.properties.hasOwnProperty(t)||(this.properties[t]=e),this.properties[t]}}function Wft(e,t){return function(n){if(this.properties[t]!==n){var a=this.properties.hasOwnProperty(t)?this.properties[t]:e;this.saveChanges(t,n,a),this.properties[t]=n}}}function Rft(e,t,n){return function(){return Tft(this,t,e,n)}}function Fft(e,t,n){return function(a){Tft(this,t,e,n).setProperties(a)}}function Yft(e,t,n){return function(){var a=this;if(!this.properties.hasOwnProperty(t)){var r=Bft(this,t,e,n,!1);this.properties[t]=r}var i=void 0!==this.controlParent&&this.controlParent.ignoreCollectionWatch||this.ignoreCollectionWatch;return this.properties[t].hasOwnProperty("push")||i||["push","pop"].forEach(function(e){var r={value:Uft(e,t,n,a.properties[t]).bind(a),configurable:!0};Object.defineProperty(a.properties[t],e,r)}),this.properties[t].hasOwnProperty("isComplexArray")||Object.defineProperty(this.properties[t],"isComplexArray",{value:!0}),this.properties[t]}}function qft(e,t,n){return function(a){this.isComplexArraySetter=!0;var r=Bft(this,t,e,n,!1),i=Bft(this,t,a,n,!0);this.isComplexArraySetter=!1,this.saveChanges(t,i,r),this.properties[t]=i}}function Uft(e,t,n,a){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var i=this.propName?this.getParentKey()+"."+t+"-":t+"-";switch(e){case"push":for(var o=0;o<n.length;o++){Array.prototype[e].apply(a,[n[o]]);var l=Gft(i+(a.length-1),n[o],!this.controlParent,e);this.serverDataBind(l,n[o],!1,e)}break;case"pop":Array.prototype[e].apply(a);var s=Gft(i+a.length,null,!this.controlParent,e);this.serverDataBind(s,{ejsAction:"pop"},!1,e)}return a}}function Gft(e,t,n,a){var r=e;if(n&&((r={})[e]=t,t&&"object"==typeof t)){r[e].ejsAction=a}return r}function Kft(e){return function(t,n){var a={set:Wft(e,n),get:jft(e,n),enumerable:!0,configurable:!0};Object.defineProperty(t,n,a),emt(t,n,"prop",e)}}function Qft(e,t){return function(n,a){var r={set:Fft(e,a,t),get:Rft(e,a,t),enumerable:!0,configurable:!0};Object.defineProperty(n,a,r),emt(n,a,"complexProp",e,t)}}function Xft(e,t){return function(n,a){var r={set:qft(e,a,t),get:Yft(e,a,t),enumerable:!0,configurable:!0};Object.defineProperty(n,a,r),emt(n,a,"colProp",e,t)}}function Jft(){return function(e,t){var n={set:function(e){var n=this.properties[t];if(n!==e){var a=tmt(this,t);!1===Ept(n)&&a.context.removeEventListener(a.prefix,n),a.context.addEventListener(a.prefix,e),this.properties[t]=e}},get:jft(void 0,t),enumerable:!0,configurable:!0};Object.defineProperty(e,t,n),emt(e,t,"event")}}function $ft(e){}function emt(e,t,n,a,r){Ept(e.propList)&&(e.propList={props:[],complexProps:[],colProps:[],events:[],propNames:[],complexPropNames:[],colPropNames:[],eventNames:[]}),e.propList[n+"s"].push({propertyName:t,defaultValue:a,type:r}),e.propList[n+"Names"].push(t)}function tmt(e,t){if(!1===e.hasOwnProperty("parentObj"))return{context:e,prefix:t};var n=fpt("propName",e);return n&&(t=n+"-"+t),tmt(fpt("parentObj",e),t)}var nmt,amt=(nmt=function(e,t){return nmt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},nmt(e,t)},function(e,t){function n(){this.constructor=e}nmt(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),rmt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},imt=function(e){function t(t){var n=e.call(this,t,void 0)||this;return n.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},n}var n;return amt(t,e),n=t,t.prototype.animate=function(e,t){t=t||{};var a=this.getModel(t);if("string"==typeof e)for(var r=0,i=Array.prototype.slice.call(Dft(e,document));r<i.length;r++){var o=i[r];a.element=o,n.delayAnimation(a)}else a.element=e,n.delayAnimation(a)},t.stop=function(e,t){e.style.animation="",e.removeAttribute("e-animate");var n=e.getAttribute("e-animation-id");if(n){var a=parseInt(n,10);cancelAnimationFrame(a),e.removeAttribute("e-animation-id")}t&&t.end&&t.end.call(this,t)},t.delayAnimation=function(e){"Disable"===umt?(e.begin&&e.begin.call(this,e),e.end&&e.end.call(this,e)):e.delay?setTimeout(function(){n.applyAnimation(e)},e.delay):n.applyAnimation(e)},t.applyAnimation=function(e){var t=this;e.timeStamp=0;var n=0,a=0,r=0,i=e.duration;e.element.setAttribute("e-animate","true");var o=function(l){try{if(l){r=0===r?l:r,e.timeStamp=l+e.timeStamp-r,r=l,!n&&e.begin&&e.begin.call(t,e),n+=1;var s=e.timeStamp/n;e.timeStamp<i&&e.timeStamp+s<i&&e.element.getAttribute("e-animate")?(e.element.style.animation=e.name+" "+e.duration+"ms "+e.timingFunction,e.progress&&e.progress.call(t,e),requestAnimationFrame(o)):(cancelAnimationFrame(a),e.element.removeAttribute("e-animation-id"),e.element.removeAttribute("e-animate"),e.element.style.animation="",e.end&&e.end.call(t,e))}else a=requestAnimationFrame(o),e.element.setAttribute("e-animation-id",a.toString())}catch(n){cancelAnimationFrame(a),e.element.removeAttribute("e-animation-id"),e.fail&&e.fail.call(t,n)}};o()},t.prototype.getModel=function(e){return{name:e.name||this.name,delay:e.delay||this.delay,duration:void 0!==e.duration?e.duration:this.duration,begin:e.begin||this.begin,end:e.end||this.end,fail:e.fail||this.fail,progress:e.progress||this.progress,timingFunction:this.easing[e.timingFunction]?this.easing[e.timingFunction]:e.timingFunction||this.easing[this.timingFunction]}},t.prototype.onPropertyChanged=function(e,t){},t.prototype.getModuleName=function(){return"animation"},t.prototype.destroy=function(){},rmt([Kft("FadeIn")],t.prototype,"name",void 0),rmt([Kft(400)],t.prototype,"duration",void 0),rmt([Kft("ease")],t.prototype,"timingFunction",void 0),rmt([Kft(0)],t.prototype,"delay",void 0),rmt([Jft()],t.prototype,"progress",void 0),rmt([Jft()],t.prototype,"begin",void 0),rmt([Jft()],t.prototype,"end",void 0),rmt([Jft()],t.prototype,"fail",void 0),t=n=rmt([$ft],t)}(Pft);function omt(e,t,n){var a=function(e){var t={selector:e&&e.selector?e.selector:null,ignore:e&&e.ignore?e.ignore:null,rippleFlag:e&&e.rippleFlag,isCenterRipple:e&&e.isCenterRipple,duration:e&&e.duration?e.duration:350};return t}(t);return!1===a.rippleFlag||void 0===a.rippleFlag&&!hmt?function(){}:(e.setAttribute("data-ripple","true"),wft.add(e,"mousedown",lmt,{parent:e,rippleOptions:a}),wft.add(e,"mouseup",smt,{parent:e,rippleOptions:a,done:n}),wft.add(e,"mouseleave",cmt,{parent:e,rippleOptions:a}),gft.isPointer&&wft.add(e,"transitionend",cmt,{parent:e,rippleOptions:a}),function(){e.removeAttribute("data-ripple"),wft.remove(e,"mousedown",lmt),wft.remove(e,"mouseup",smt),wft.remove(e,"mouseleave",cmt),wft.remove(e,"transitionend",cmt)})}function lmt(e){var t=e.target,n=this.rippleOptions.selector,a=n?Oft(t,n):t;if(!(!a||this.rippleOptions&&Oft(t,this.rippleOptions.ignore))){var r=a.getBoundingClientRect(),i=e.pageX-document.body.scrollLeft,o=e.pageY-(!document.body.scrollTop&&document.documentElement?document.documentElement.scrollTop:document.body.scrollTop),l=Math.max(Math.abs(i-r.left),Math.abs(i-r.right)),s=Math.max(Math.abs(o-r.top),Math.abs(o-r.bottom)),c=Math.sqrt(l*l+s*s),d=2*c+"px",h=i-r.left-c,u=o-r.top-c;this.rippleOptions&&this.rippleOptions.isCenterRipple&&(h=0,u=0,d="100%"),a.classList.add("e-ripple");var p=bft("div",{className:"e-ripple-element",styles:"width: "+d+";height: "+d+";left: "+h+"px;top: "+u+"px;transition-duration: "+this.rippleOptions.duration.toString()+"ms;"});a.appendChild(p),window.getComputedStyle(p).getPropertyValue("opacity"),p.style.transform="scale(1)",a!==this.parent&&wft.add(a,"mouseleave",cmt,{parent:this.parent,rippleOptions:this.rippleOptions})}}function smt(e){dmt(e,this)}function cmt(e){dmt(e,this)}function dmt(e,t){var n=t.rippleOptions.duration,a=e.target,r=t.rippleOptions.selector,i=r?Oft(a,r):a;if(i&&(!i||-1!==i.className.indexOf("e-ripple"))){var o=Dft(".e-ripple-element",i),l=o[o.length-1];l&&(l.style.opacity="0.5"),t.parent!==i&&wft.remove(i,"mouseleave",cmt),setTimeout(function(){l&&l.parentNode&&l.parentNode.removeChild(l),i.getElementsByClassName("e-ripple-element").length||i.classList.remove("e-ripple"),t.done&&t.done(e)},n)}}var hmt=!1,umt="",pmt=function(){function e(e){this.loadedModules=[],this.parent=e}return e.prototype.inject=function(e,t){var n=e.length;if(0!==n){this.loadedModules.length&&this.clearUnusedModule(e);for(var a=0;a<n;a++)for(var r=e[a],i=0,o=t;i<o.length;i++){var l=o[i],s=r.member;if(l.prototype.getModuleName()===r.member&&!this.isModuleLoaded(s)){var c=ppt(l,r.args),d=this.getMemberName(s);r.isProperty?mpt(d,l,this.parent):mpt(d,c,this.parent);var h=r;h.member=d,this.loadedModules.push(h)}}}else this.clean()},e.prototype.clean=function(){for(var e=0,t=this.loadedModules;e<t.length;e++){var n=t[e];n.isProperty||fpt(n.member,this.parent).destroy()}this.loadedModules=[]},e.prototype.clearUnusedModule=function(e){for(var t=this,n=e.map(function(e){return t.getMemberName(e.member)}),a=0,r=this.loadedModules.filter(function(e){return-1===n.indexOf(e.member)});a<r.length;a++){var i=r[a];i.isProperty||fpt(i.member,this.parent).destroy(),this.loadedModules.splice(this.loadedModules.indexOf(i),1),vpt(this.parent,i.member)}},e.prototype.getMemberName=function(e){return e[0].toLowerCase()+e.substring(1)+"Module"},e.prototype.isModuleLoaded=function(e){for(var t=0,n=this.loadedModules;t<n.length;t++){if(n[t].member===this.getMemberName(e))return!0}return!1},e}(),fmt=function(){function e(e,t,n,a){this.isComplexArraySetter=!1,this.properties={},this.changedProperties={},this.childChangedProperties={},this.oldProperties={},this.finalUpdate=function(){},this.callChildDataBind=fpt("callChildDataBind",Pft),this.parentObj=e,this.controlParent=this.parentObj.controlParent||this.parentObj,this.propName=t,this.isParentArray=a,this.setProperties(n,!0)}return e.prototype.updateChange=function(e,t){!0===e?this.parentObj.childChangedProperties[t]=e:delete this.parentObj.childChangedProperties[t],this.parentObj.updateChange&&this.parentObj.updateChange(e,this.parentObj.propName)},e.prototype.updateTimeOut=function(){if(this.parentObj.updateTimeOut)this.parentObj.finalUpdate(),this.parentObj.updateTimeOut();else{var e=setTimeout(this.parentObj.dataBind.bind(this.parentObj));this.finalUpdate=function(){clearTimeout(e)}}},e.prototype.clearChanges=function(){this.finalUpdate(),this.updateChange(!1,this.propName),this.oldProperties={},this.changedProperties={}},e.prototype.setProperties=function(e,t){!0===t?(ypt(this,e),this.updateChange(!1,this.propName),this.clearChanges()):ypt(this,e)},e.prototype.dataBind=function(){if(this.callChildDataBind(this.childChangedProperties,this),this.isParentArray){var e=this.parentObj[this.propName].indexOf(this);Object.keys(this.changedProperties).length&&(mpt(this.propName+"."+e,this.changedProperties,this.parentObj.changedProperties),mpt(this.propName+"."+e,this.oldProperties,this.parentObj.oldProperties))}else this.parentObj.changedProperties[this.propName]=this.changedProperties,this.parentObj.oldProperties[this.propName]=this.oldProperties;this.clearChanges()},e.prototype.saveChanges=function(e,t,n,a){this.controlParent.isProtectedOnChange||(a||this.serverDataBind(e,t,!0),this.oldProperties[e]=n,this.changedProperties[e]=t,this.updateChange(!0,this.propName),this.finalUpdate(),this.updateTimeOut())},e.prototype.serverDataBind=function(e,t,n,a){},e.prototype.getParentKey=function(e){var t="",n=this.propName;if(this.isParentArray){t=this.parentObj[this.propName].indexOf(this);var a=this.parentObj[this.propName].length;a=e?a:a>0?a-1:0,n+=t=-1!==t?"-"+t:"-"+a}return this.controlParent!==this.parentObj&&(n=this.parentObj.getParentKey()+"."+this.propName+t),n},e}(),mmt=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],vmt=function(){function e(e){var t;this.isValidated=!1,this.version="20.2",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats/i,this.errors={noLicense:'This application was built using a trial version of Syncfusion Essential Studio. Please include a valid license to permanently remove this license validation message. You can also obtain a free 30 day evaluation license to temporarily remove this message during the evaluation period. Please refer to this <a class="e-license"href="https://help.syncfusion.com/common/essential-studio/licensing">help topic</a> for more information.',trailExpired:'Your Syncfusion trial license has expired. Please refer to this <a class="e-license"href="https://help.syncfusion.com/common/essential-studio/licensing/licensing-errors#trial-expired">help topic</a> for more information.',versionMismatched:'The included Syncfusion license (v##LicenseVersion) is invalid for version ##Requireversion. Please refer to this <a class="e-license" href="https://help.syncfusion.com/es/licensing/version-mismatch/">help topic</a> for more information.',platformMismatched:'The included Syncfusion license is invalid (Platform mismatch). Please refer to this <a class="e-license" href="https://help.syncfusion.com/common/essential-studio/licensing/licensing-errors#platform-mismatch">help topic</a> for more information.',invalidKey:'The included Syncfusion license is invalid. Please refer to this <a class="e-license" href="https://help.syncfusion.com/common/essential-studio/licensing/licensing-errors#invalid-key">help topic</a> for more information.'},this.manager=(t=null,{setKey:function(e){t=e},getKey:function(){return t}}),this.npxManager={getKey:function(){return"npxKeyReplace"}},this.manager.setKey(e)}return e.prototype.validate=function(){if(!this.isValidated&&gpt&&!fpt(wmt(mmt),gpt)&&!fpt("Blazor",gpt)){var e=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var t=this.getInfoFromKey();if(t&&t.length)for(var n=0,a=t;n<a.length;n++){var r=a[n];if(!this.platform.test(r.platform)||r.invalidPlatform)e=this.errors.platformMismatched;else if(-1===r.version.indexOf(this.version))e=(e=(e=this.errors.versionMismatched).replace("##LicenseVersion",r.version)).replace("##Requireversion",this.version+".x");else if(r.expiryDate){var i=new Date(r.expiryDate),o=new Date;if(!(i!==o&&i<o))break;e=this.errors.trailExpired}}else e=this.errors.invalidKey}else e=this.errors.noLicense;if(e&&"undefined"!=typeof document&&!xpt(document)){var l=bft("div",{innerHTML:e+'<span id="license-banner-error" class=".e-license-banner"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20"><line x1="5" y1="5" x2="15" y2="15" stroke="yellow" stroke-width="2.5" stroke-miterlimit="10" stroke-linecap="round"></line><line x1="15" y1="5" x2="5" y2="15" stroke="yellow" stroke-width="2.5" stroke-linecap="round" stroke-miterlimit="10"></line></svg></span>',styles:'position:fixed;top:0;left:0;right:0;font-family:"Segoe UI";font-size:16px;background:repeating-linear-gradient(45deg,#d70f0f,#d70f0f 10px,#e12121 10px,#e12121 17px);color:#ffffff;z-index:999999999;text-align:center;padding:10px 50px 10px 25px;'});l.setAttribute("id","js-licensing"),document.body.appendChild(l),document.getElementById("license-banner-error").addEventListener("click",function(){document.getElementById("js-licensing").remove()})}this.isValidated=!0,mpt(wmt(mmt),this.isValidated,gpt)}},e.prototype.getDecryptedData=function(e){try{return atob(e)}catch(e){return""}},e.prototype.getInfoFromKey=function(){try{var e="",t=[5439488,7929856,5111808,6488064,4587520,7667712,5439488,6881280,5177344,7208960,4194304,4456448,6619136,7733248,5242880,7077888,6356992,7602176,4587520,7274496,7471104,7143424],n=[],a=[],r=!1,i=!1;this.manager.getKey()?e=this.manager.getKey():(i=!0,e=this.npxManager.getKey().split("npxKeyReplace")[1]);for(var o=e.split(";"),l=0,s=o;l<s.length;l++){var c=s[l],d=this.getDecryptedData(c);if(d){var h=0,u="";if(i){var p=d[d.length-1],f=[];for(m=0;m<d.length;m++)f[m]=d[m].charCodeAt(0)-p.charCodeAt(0);for(m=0;m<f.length;m++)u+=String.fromCharCode(f[m])}else for(var m=0;m<d.length;m++,h++){h===t.length&&(h=0);var v=d.charCodeAt(m);u+=String.fromCharCode(v^t[h]>>16)}this.platform.test(u)?(n=u.split(";"),r=!1,n.length>3&&a.push({platform:n[0],version:n[1],expiryDate:n[2]})):u&&u.split(";").length>3&&(r=!0)}}return r&&!a.length?[{invalidPlatform:r}]:a.length?a:null}catch(e){return null}},e}(),gmt=new vmt;function wmt(e){for(var t="",n=0,a=e;n<a.length;n++){var r=a[n];t+=String.fromCharCode(r)}return t}var ymt,bmt=function(e){e&&function(e){gmt=new vmt(e)}(e),gmt.validate()},xmt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Emt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},kmt=0,Mmt=0,Smt=function(e){function t(t,n){var a=e.call(this,t,n)||this;return a.randomId=function(){if("undefined"!=typeof window){var e=new Uint16Array(5);return(window.msCrypto||window.crypto).getRandomValues(e)}}(),a.isStringTemplate=!1,a.needsID=!1,a.isReactHybrid=!1,xpt(a.enableRtl)&&a.setProperties({enableRtl:false},!0),xpt(a.locale)&&a.setProperties({locale:eft},!0),a.moduleLoader=new pmt(a),a.localObserver=new Xpt(a),Jpt.on("notifyExternalChange",a.detectFunction,a,a.randomId),bmt(),Ept(n)||a.appendTo(),a}return xmt(t,e),t.prototype.requiredModules=function(){return[]},t.prototype.destroy=function(){this.isDestroyed||(this.enablePersistence&&this.setPersistData(),this.localObserver.destroy(),this.refreshing||(Eft([this.element],["e-control"]),this.trigger("destroyed",{cancel:!1}),e.prototype.destroy.call(this),this.moduleLoader.clean(),Jpt.off("notifyExternalChange",this.detectFunction,this.randomId)))},t.prototype.refresh=function(){this.refreshing=!0,this.moduleLoader.clean(),this.destroy(),this.clearChanges(),this.localObserver=new Xpt(this),this.preRender(),this.injectModules(),this.render(),this.refreshing=!1},t.prototype.accessMount=function(){this.mount&&!this.isReactHybrid&&this.mount()},t.prototype.getRootElement=function(){return this.isReactHybrid?this.actualElement:this.element},t.prototype.getLocalData=function(){var e=this.getModuleName()+this.element.id;return window.localStorage.getItem(e)},t.prototype.appendTo=function(t){if(xpt(t)||"string"!=typeof t?xpt(t)||(this.element=t):this.element=Ift(t,document),!xpt(this.element)){var n="e-"+this.getModuleName().toLowerCase();xft([this.element],["e-control",n]),this.isProtectedOnChange=!1,this.needsID&&!this.element.id&&(this.element.id=this.getUniqueID(this.getModuleName())),this.enablePersistence&&(this.mergePersistData(),window.addEventListener("unload",this.setPersistData.bind(this)));var a=fpt("ej2_instances",this.element);a&&-1!==a.indexOf(this)||e.prototype.addInstance.call(this),this.preRender(),this.injectModules(),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),e.prototype.dataBind.call(this)},t.prototype.on=function(e,t,n){if("string"==typeof e)this.localObserver.on(e,t,n);else for(var a=0,r=e;a<r.length;a++){var i=r[a];this.localObserver.on(i.event,i.handler,i.context)}},t.prototype.off=function(e,t){if("string"==typeof e)this.localObserver.off(e,t);else for(var n=0,a=e;n<a.length;n++){var r=a[n];this.localObserver.off(r.event,r.handler)}},t.prototype.notify=function(e,t){!0!==this.isDestroyed&&this.localObserver.notify(e,t)},t.prototype.getInjectedModules=function(){return this.injectedModules},t.Inject=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.prototype.injectedModules||(this.prototype.injectedModules=[]);for(var n=0;n<e.length;n++)-1===this.prototype.injectedModules.indexOf(e[n])&&this.prototype.injectedModules.push(e[n])},t.prototype.createElement=function(e,t,n){return bft(e,t)},t.prototype.triggerStateChange=function(e,t){this.isReactHybrid&&(this.setState(),this.currentContext={calls:e,args:t})},t.prototype.injectModules=function(){this.injectedModules&&this.injectedModules.length&&this.moduleLoader.inject(this.requiredModules(),this.injectedModules)},t.prototype.detectFunction=function(e){var t=Object.keys(e);t.length&&(this[t[0]]=e[t[0]])},t.prototype.mergePersistData=function(){var e;xpt(e=window.localStorage.getItem(this.getModuleName()+this.element.id))||""===e||this.setProperties(JSON.parse(e),!0)},t.prototype.setPersistData=function(){this.isDestroyed||window.localStorage.setItem(this.getModuleName()+this.element.id,this.getPersistData())},t.prototype.renderReactTemplates=function(){},t.prototype.clearTemplate=function(e,t){},t.prototype.getUniqueID=function(e){return this.isHistoryChanged()&&(kmt=0),ymt=this.pageID(location.href),Mmt=history.length,e+"_"+ymt+"_"+kmt++},t.prototype.pageID=function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++){t=(t<<5)-t+e.charCodeAt(n),t&=t}return Math.abs(t)},t.prototype.isHistoryChanged=function(){return ymt!==this.pageID(location.href)||Mmt!==history.length},t.prototype.addOnPersist=function(e){for(var t=this,n={},a=0,r=e;a<r.length;a++){var i,o=r[a];Ept(i=fpt(o,this))||mpt(o,this.getActualProperties(i),n)}return JSON.stringify(n,function(e,n){return t.getActualProperties(n)})},t.prototype.getActualProperties=function(e){return e instanceof fmt?fpt("properties",e):e},t.prototype.ignoreOnPersist=function(e){return JSON.stringify(this.iterateJsonProperties(this.properties,e))},t.prototype.iterateJsonProperties=function(e,t){for(var n={},a=function(a){if(-1===t.indexOf(a)){var i=e[a];if("object"!=typeof i||i instanceof Array)n[a]=i;else{var o=t.filter(function(e){return new RegExp(a+".").test(e)}).map(function(e){return e.replace(a+".","")});n[a]=r.iterateJsonProperties(r.getActualProperties(i),o)}}},r=this,i=0,o=Object.keys(e);i<o.length;i++){a(o[i])}return n},Emt([Kft(!1)],t.prototype,"enablePersistence",void 0),Emt([Kft()],t.prototype,"enableRtl",void 0),Emt([Kft()],t.prototype,"locale",void 0),t=Emt([$ft],t)}(Pft);"undefined"!=typeof window&&window.addEventListener("popstate",function(){kmt=0});var Amt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),_mt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Cmt={left:0,top:0,bottom:0,right:0},Zmt={isDragged:!1},Hmt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Amt(t,e),_mt([Kft(0)],t.prototype,"left",void 0),_mt([Kft(0)],t.prototype,"top",void 0),t}(fmt);!function(e){function t(t,a){var r=e.call(this,a,t)||this;return r.dragLimit=n.getDefaultPosition(),r.borderWidth=n.getDefaultPosition(),r.padding=n.getDefaultPosition(),r.diffX=0,r.prevLeft=0,r.prevTop=0,r.dragProcessStarted=!1,r.eleTop=0,r.tapHoldTimer=0,r.externalInitialize=!1,r.diffY=0,r.parentScrollX=0,r.parentScrollY=0,r.droppables={},r.bind(),r}var n;Amt(t,e),n=t,t.prototype.bind=function(){this.toggleEvents(),gft.isIE&&xft([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return bpt({},Cmt)},t.prototype.toggleEvents=function(e){var t;Ept(this.handle)||(t=Ift(this.handle,this.element));var n=this.enableTapHold&&gft.isDevice&&gft.isTouch?this.mobileInitialize:this.initialize;e?wft.remove(t||this.element,gft.touchStartEvent,n):wft.add(t||this.element,gft.touchStartEvent,n,this)},t.prototype.mobileInitialize=function(e){var t=this,n=e.currentTarget;this.tapHoldTimer=setTimeout(function(){t.externalInitialize=!0,t.removeTapholdTimer(),t.initialize(e,n)},this.tapHoldThreshold),wft.add(document,gft.touchMoveEvent,this.removeTapholdTimer,this),wft.add(document,gft.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),wft.remove(document,gft.touchMoveEvent,this.removeTapholdTimer),wft.remove(document,gft.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(e,t){return xpt(e)?null:e[{vertical:"scrollHeight",horizontal:"scrollWidth"}[t]]>e[{vertical:"clientHeight",horizontal:"clientWidth"}[t]]&&("vertical"===t?e.scrollTop>0:e.scrollLeft>0)?("vertical"===t?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?e.scrollTop:e.scrollTop-this.parentScrollY),this.tempScrollHeight=e.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?e.scrollLeft:e.scrollLeft-this.parentScrollX),this.tempScrollWidth=e.scrollWidth),xpt(e)?e:this.getScrollableParent(e.parentNode,t)):this.getScrollableParent(e.parentNode,t)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(e,t){if(this.currentStateTarget=e.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=e.currentTarget||t,this.dragProcessStarted=!1,this.abort){var n=this.abort;"string"==typeof n&&(n=[n]);for(var a=0;a<n.length;a++)if(!xpt(Oft(e.target,n[a])))return void(this.isDragStarted()&&this.isDragStarted(!0))}this.preventDefault&&!Ept(e.changedTouches)&&"touchstart"!==e.type&&e.preventDefault(),this.element.setAttribute("aria-grabbed","true");var r=this.getCoordinates(e);if(this.initialPosition={x:r.pageX,y:r.pageY},!this.clone){var i=this.element.getBoundingClientRect();this.getScrollableValues(),e.clientX===e.pageX&&(this.parentScrollX=0),e.clientY===e.pageY&&(this.parentScrollY=0),this.relativeXPosition=r.pageX-(i.left+this.parentScrollX),this.relativeYPosition=r.pageY-(i.top+this.parentScrollY)}this.externalInitialize?this.intDragStart(e):(wft.add(document,gft.touchMoveEvent,this.intDragStart,this),wft.add(document,gft.touchEndEvent,this.intDestroy,this)),this.toggleEvents(!0),"touchstart"!==e.type&&this.isPreventSelect&&document.body.classList.add("e-prevent-select"),this.externalInitialize=!1,wft.trigger(document.documentElement,gft.touchStartEvent,e)}},t.prototype.intDragStart=function(e){this.removeTapholdTimer();var t=!Ept(e.changedTouches);if(!t||1===e.changedTouches.length){var n,a=this.getCoordinates(e),r=getComputedStyle(this.element);this.margin={left:parseInt(r.marginLeft,10),top:parseInt(r.marginTop,10),right:parseInt(r.marginRight,10),bottom:parseInt(r.marginBottom,10)};var i=this.element;if(this.clone&&this.dragTarget){var o=Oft(e.target,this.dragTarget);xpt(o)||(i=o)}this.isReplaceDragEle&&(i=this.currentStateCheck(e.target,i)),this.offset=this.calculateParentPosition(i),this.position=this.getMousePosition(e,this.isDragScroll);var l=this.initialPosition.x-a.pageX,s=this.initialPosition.y-a.pageY;if(Math.sqrt(l*l+s*s)>=this.distance||this.externalInitialize){var c=this.getHelperElement(e);if(!c||xpt(c))return;t&&e.preventDefault();var d=this.helperElement=c;if(this.parentClientRect=this.calculateParentPosition(d.offsetParent),this.dragStart){var h={event:e,element:i,target:this.getProperTargetElement(e),bindEvents:null,dragElement:d};this.trigger("dragStart",h)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),n={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var u=getComputedStyle(i),p=parseFloat(u.marginTop);this.clone&&0!==p&&(n.top+=p),this.eleTop=isNaN(parseFloat(u.top))?0:parseFloat(u.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(n.top-=this.parentScrollY,n.left-=this.parentScrollX);var f=this.getProcessedPositionValue({top:n.top-this.diffY+"px",left:n.left-this.diffX+"px"});this.dragElePosition={top:n.top,left:n.left},Lft(d,this.getDragPosition({position:"absolute",left:f.left,top:f.top})),wft.remove(document,gft.touchMoveEvent,this.intDragStart),wft.remove(document,gft.touchEndEvent,this.intDestroy),this.bindDragEvents(d)}}},t.prototype.bindDragEvents=function(e){Mft(e)?(wft.add(document,gft.touchMoveEvent,this.intDrag,this),wft.add(document,gft.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,e)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(e){for(this.top=e.offsetTop,this.left=e.offsetLeft,this.width=e.offsetWidth,this.height=e.offsetHeight;e.offsetParent;)e=e.offsetParent,this.top+=e.offsetTop,this.left+=e.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(e){return this.queryPositionInfo?this.queryPositionInfo(e):e},t.prototype.calculateParentPosition=function(e){if(xpt(e))return{left:0,top:0};var t=e.getBoundingClientRect(),n=getComputedStyle(e);return{left:t.left+window.pageXOffset-parseInt(n.marginLeft,10),top:t.top+window.pageYOffset-parseInt(n.marginTop,10)}},t.prototype.intDrag=function(e){if(Ept(e.changedTouches)||1===e.changedTouches.length){var t,n;this.clone&&e.changedTouches&&gft.isDevice&&gft.isTouch&&e.preventDefault(),this.position=this.getMousePosition(e,this.isDragScroll);var a=this.getDocumentWidthHeight("Height");a<this.position.top&&(this.position.top=a);var r=this.getDocumentWidthHeight("Width");if(r<this.position.left&&(this.position.left=r),this.drag){var i=this.getProperTargetElement(e);this.trigger("drag",{event:e,element:this.element,target:i})}var o=this.checkTargetElement(e);if(o.target&&o.instance){var l=!0;this.hoverObject&&(this.hoverObject.instance!==o.instance?this.triggerOutFunction(e,o):l=!1),l&&(o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intOver(e,o.target),this.hoverObject=o)}else this.hoverObject&&this.triggerOutFunction(e,o);var s=this.droppables[this.scope].helper;this.parentClientRect=this.calculateParentPosition(this.helperElement.offsetParent);var c=this.parentClientRect.left,d=this.parentClientRect.top,h=this.getCoordinates(e),u=h.pageX,p=h.pageY,f=this.position.left-this.diffX,m=this.position.top-this.diffY,v=getComputedStyle(s);if(this.dragArea){if(this.pageX!==u||this.skipDistanceCheck){var g=s.offsetWidth+(parseFloat(v.marginLeft)+parseFloat(v.marginRight));t=this.dragLimit.left>f&&f>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset<f+g&&f>0?f-(f-this.dragLimit.right)+window.pageXOffset-g:f<0?this.dragLimit.left:f}if(this.pageY!==p||this.skipDistanceCheck){var w=s.offsetHeight+(parseFloat(v.marginTop)+parseFloat(v.marginBottom));n=this.dragLimit.top>m&&m>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset<m+w&&m>0?m-(m-this.dragLimit.bottom)+window.pageYOffset-w:m<0?this.dragLimit.top:m}}else t=f,n=m;var y,b,x=d+this.borderWidth.top,E=c+this.borderWidth.left;this.dragProcessStarted&&(xpt(n)&&(n=this.prevTop),xpt(t)&&(t=this.prevLeft)),this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,y=n-x<0?this.dragLimit.top:n-x,b=t-E<0?this.dragElePosition.left:t-E):(y=n-x,b=t-E);var k=parseFloat(getComputedStyle(this.element).marginTop);if(k>0&&(this.clone&&(y+=k,m<0&&(k+m>=0?y=k+m:y-=k),y=this.dragLimit.bottom<y?this.dragLimit.bottom:y),n-x<0))if(m+k+(s.offsetHeight-x)>=0){var M=this.dragLimit.top+m-x;M+k+x<0?y-=k+x:y=M}else y-=k+x;this.enableScrollHandler&&!this.clone&&(y-=this.parentScrollY,b-=this.parentScrollX);var S=this.getProcessedPositionValue({top:y+"px",left:b+"px"});Lft(s,this.getDragPosition(S)),this.elementInViewport(s)||!this.enableAutoScroll||this.helperElement.classList.contains("e-treeview")||this.helperElement.scrollIntoView();var A=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===A.length&&(A=this.getPathElements(e));var _=this.getScrollParent(A,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(_,y):this.elementInViewport(this.helperElement)||(0===(A=[].slice.call(document.querySelectorAll(":hover"))).length&&(A=this.getPathElements(e)),_=this.getScrollParent(A,!0),this.getScrollPosition(_,y))}this.dragProcessStarted=!0,this.prevLeft=t,this.prevTop=n,this.position.left=t,this.position.top=n,this.pageX=u,this.pageY=p}},t.prototype.getScrollParent=function(e,t){for(var n,a=t?e.reverse():e,r=a.length-1;r>=0;r--)if(("auto"===(n=window.getComputedStyle(a[r])["overflow-y"])||"scroll"===n)&&a[r].scrollHeight>a[r].clientHeight)return a[r];if("visible"===(n=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(e,t){e&&e===document.scrollingElement?e.clientHeight-e.getBoundingClientRect().top-this.helperElement.clientHeight<t&&e.getBoundingClientRect().height>t?e.scrollTop+=this.helperElement.clientHeight:e.scrollHeight-e.clientHeight>t&&(e.scrollTop-=this.helperElement.clientHeight):e&&e!==document.scrollingElement&&(e.clientHeight+e.getBoundingClientRect().top-this.helperElement.clientHeight<t?e.scrollTop+=this.helperElement.clientHeight:e.getBoundingClientRect().top>t-this.helperElement.clientHeight&&(e.scrollTop-=this.helperElement.clientHeight))},t.prototype.getPathElements=function(e){var t=e.clientX>0?e.clientX:0,n=e.clientY>0?e.clientY:0;return document.elementsFromPoint(t,n)},t.prototype.triggerOutFunction=function(e,t){this.hoverObject.instance.intOut(e,t.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(e){var t=bpt({},e);return this.axis&&("x"===this.axis?delete t.top:"y"===this.axis&&delete t.left),t},t.prototype.getDocumentWidthHeight=function(e){var t=document.body,n=document.documentElement;return Math.max(t["scroll"+e],n["scroll"+e],t["offset"+e],n["offset"+e],n["client"+e])},t.prototype.intDragStop=function(e){if(this.dragProcessStarted=!1,Ept(e.changedTouches)||1===e.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(e.type)){if(this.dragStop){var t=this.getProperTargetElement(e);this.trigger("dragStop",{event:e,element:this.element,target:t,helper:this.helperElement})}this.intDestroy(e)}else this.element.setAttribute("aria-grabbed","false");var n=this.checkTargetElement(e);n.target&&n.instance&&(n.instance.dragStopCalled=!0,n.instance.dragData[this.scope]=this.droppables[this.scope],n.instance.intDrop(e,n.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(e){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),wft.remove(document,gft.touchMoveEvent,this.intDragStart),wft.remove(document,gft.touchEndEvent,this.intDragStop),wft.remove(document,gft.touchEndEvent,this.intDestroy),wft.remove(document,gft.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(e,t){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(e){return e&&(Zmt.isDragged=!Zmt.isDragged),Zmt.isDragged},t.prototype.setDragArea=function(){var e,t,n,a=0,r=0;if(n="string"===typeof this.dragArea?Ift(this.dragArea):this.dragArea){var i=n.getBoundingClientRect();e=n.scrollWidth?n.scrollWidth:i.right-i.left,t=n.scrollHeight?n.scrollHeight:i.bottom-i.top;for(var o=["Top","Left","Bottom","Right"],l=getComputedStyle(n),s=0;s<o.length;s++){var c=o[s],d=l["border"+c+"Width"],h=l["padding"+c],u=c.toLowerCase();this.borderWidth[u]=isNaN(parseFloat(d))?0:parseFloat(d),this.padding[u]=isNaN(parseFloat(h))?0:parseFloat(h)}a=i.top,r=i.left,this.dragLimit.left=r+this.borderWidth.left+this.padding.left,this.dragLimit.top=n.offsetTop+this.borderWidth.top+this.padding.top,this.dragLimit.right=r+e-(this.borderWidth.right+this.padding.right),this.dragLimit.bottom=a+t-(this.borderWidth.bottom+this.padding.bottom)}},t.prototype.getProperTargetElement=function(e){var t,n=this.getCoordinates(e),a=this.helperElement.style.pointerEvents||"";return Mpt(e.target,this.helperElement)||-1!==e.type.indexOf("touch")?(this.helperElement.style.pointerEvents="none",t=document.elementFromPoint(n.clientX,n.clientY),this.helperElement.style.pointerEvents=a):t=e.target,t},t.prototype.currentStateCheck=function(e,t){return xpt(this.currentStateTarget)||this.currentStateTarget===e?xpt(t)?e:t:this.currentStateTarget},t.prototype.getMousePosition=function(e,t){var n,a,r=void 0!==e.srcElement?e.srcElement:e.target,i=this.getCoordinates(e),o=xpt(r.offsetParent);return t?(n=this.clone?i.pageX:i.pageX+(o?0:r.offsetParent.scrollLeft)-this.relativeXPosition,a=this.clone?i.pageY:i.pageY+(o?0:r.offsetParent.scrollTop)-this.relativeYPosition):(n=this.clone?i.pageX:i.pageX+window.pageXOffset-this.relativeXPosition,a=this.clone?i.pageY:i.pageY+window.pageYOffset-this.relativeYPosition),{left:n-(this.margin.left+this.cursorAt.left),top:a-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(e){return e.type.indexOf("touch")>-1?e.changedTouches[0]:e},t.prototype.getHelperElement=function(e){var t;return this.clone?this.helper?t=this.helper({sender:e,element:this.target}):(t=bft("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(t)):t=this.element,t},t.prototype.setGlobalDroppables=function(e,t,n){this.droppables[this.scope]=e?null:{draggable:t,helper:n,draggedElement:this.element}},t.prototype.checkTargetElement=function(e){var t=this.getProperTargetElement(e),n=this.getDropInstance(t);if(!n&&t&&!xpt(t.parentNode)){var a=Oft(t.parentNode,".e-droppable")||t.parentElement;a&&(n=this.getDropInstance(a))}return{target:t,instance:n}},t.prototype.getDropInstance=function(e){var t,n=e&&e.ej2_instances;if(n)for(var a=0,r=n;a<r.length;a++){var i=r[a];if("droppable"===i.getModuleName()){t=i;break}}return t},t.prototype.destroy=function(){this.toggleEvents(!0),e.prototype.destroy.call(this)},_mt([Qft({},Hmt)],t.prototype,"cursorAt",void 0),_mt([Kft(!0)],t.prototype,"clone",void 0),_mt([Kft()],t.prototype,"dragArea",void 0),_mt([Kft()],t.prototype,"isDragScroll",void 0),_mt([Kft()],t.prototype,"isReplaceDragEle",void 0),_mt([Kft(!0)],t.prototype,"isPreventSelect",void 0),_mt([Jft()],t.prototype,"drag",void 0),_mt([Jft()],t.prototype,"dragStart",void 0),_mt([Jft()],t.prototype,"dragStop",void 0),_mt([Kft(1)],t.prototype,"distance",void 0),_mt([Kft()],t.prototype,"handle",void 0),_mt([Kft()],t.prototype,"abort",void 0),_mt([Kft()],t.prototype,"helper",void 0),_mt([Kft("default")],t.prototype,"scope",void 0),_mt([Kft("")],t.prototype,"dragTarget",void 0),_mt([Kft()],t.prototype,"axis",void 0),_mt([Kft()],t.prototype,"queryPositionInfo",void 0),_mt([Kft(!1)],t.prototype,"enableTailMode",void 0),_mt([Kft(!1)],t.prototype,"skipDistanceCheck",void 0),_mt([Kft(!0)],t.prototype,"preventDefault",void 0),_mt([Kft(!1)],t.prototype,"enableAutoScroll",void 0),_mt([Kft(!1)],t.prototype,"enableTapHold",void 0),_mt([Kft(750)],t.prototype,"tapHoldThreshold",void 0),_mt([Kft(!1)],t.prototype,"enableScrollHandler",void 0),t=n=_mt([$ft],t)}(Pft);var Imt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Dmt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o};!function(e){function t(t,n){var a=e.call(this,n,t)||this;return a.mouseOver=!1,a.dragData={},a.dragStopCalled=!1,a.bind(),a}Imt(t,e),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){wft.add(this.element,gft.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,t){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,t){if(!this.mouseOver){var n=this.dragData[this.scope];this.trigger("over",{event:e,target:t,dragData:n}),this.mouseOver=!0}},t.prototype.intOut=function(e,t){this.mouseOver&&(this.trigger("out",{evt:e,target:t}),this.mouseOver=!1)},t.prototype.intDrop=function(e,t){if(this.dragStopCalled){this.dragStopCalled=!1;var n,a=!0,r=this.dragData[this.scope],i=!!r&&(r.helper&&Mft(r.helper));i&&(n=this.isDropArea(e,r.helper,t),this.accept&&(a=Vft(r.helper,this.accept))),i&&this.drop&&n.canDrop&&a&&this.trigger("drop",{event:e,target:n.target,droppedElement:r.helper,dragData:r}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,t,n){var a={canDrop:!0,target:n||e.target},r="touchend"===e.type;if(r||a.target===t){t.style.display="none";var i=r?e.changedTouches[0]:e,o=document.elementFromPoint(i.clientX,i.clientY);a.canDrop=!1,a.canDrop=Mpt(o,this.element),a.canDrop&&(a.target=o),t.style.display=""}return a},t.prototype.destroy=function(){wft.remove(this.element,gft.touchEndEvent,this.intDrop),e.prototype.destroy.call(this)},Dmt([Kft()],t.prototype,"accept",void 0),Dmt([Kft("default")],t.prototype,"scope",void 0),Dmt([Jft()],t.prototype,"drop",void 0),Dmt([Jft()],t.prototype,"over",void 0),Dmt([Jft()],t.prototype,"out",void 0),t=Dmt([$ft],t)}(Pft);var Nmt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Omt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Lmt={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,space:32,escape:27,pageup:33,pagedown:34,end:35,home:36,leftarrow:37,uparrow:38,rightarrow:39,downarrow:40,insert:45,delete:46,f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123,semicolon:186,plus:187,comma:188,minus:189,dot:190,forwardslash:191,graveaccent:192,openbracket:219,backslash:220,closebracket:221,singlequote:222},Vmt=function(e){function t(t,a){var r=e.call(this,a,t)||this;return r.keyPressHandler=function(e){for(var t=e.altKey,a=e.ctrlKey,i=e.shiftKey,o=e.which,l=0,s=Object.keys(r.keyConfigs);l<s.length;l++)for(var c=s[l],d=0,h=r.keyConfigs[c].split(",");d<h.length;d++){var u=h[d],p=n.getKeyConfigData(u.trim());t===p.altKey&&a===p.ctrlKey&&i===p.shiftKey&&o===p.keyCode&&(e.action=c,r.keyAction&&r.keyAction(e))}},r.bind(),r}var n;return Nmt(t,e),n=t,t.prototype.destroy=function(){this.unwireEvents(),e.prototype.destroy.call(this)},t.prototype.onPropertyChanged=function(e,t){},t.prototype.bind=function(){this.wireEvents()},t.prototype.getModuleName=function(){return"keyboard"},t.prototype.wireEvents=function(){this.element.addEventListener(this.eventName,this.keyPressHandler)},t.prototype.unwireEvents=function(){this.element.removeEventListener(this.eventName,this.keyPressHandler)},t.getKeyConfigData=function(e){if(e in this.configCache)return this.configCache[e];var t=e.toLowerCase().split("+"),a={altKey:-1!==t.indexOf("alt"),ctrlKey:-1!==t.indexOf("ctrl"),shiftKey:-1!==t.indexOf("shift"),keyCode:null};return t[t.length-1].length>1&&Number(t[t.length-1])?a.keyCode=Number(t[t.length-1]):a.keyCode=n.getKeyCode(t[t.length-1]),n.configCache[e]=a,a},t.getKeyCode=function(e){return Lmt[e]||e.toUpperCase().charCodeAt(0)},t.configCache={},Omt([Kft({})],t.prototype,"keyConfigs",void 0),Omt([Kft("keyup")],t.prototype,"eventName",void 0),Omt([Jft()],t.prototype,"keyAction",void 0),t=n=Omt([$ft],t)}(Pft),zmt=function(){function e(e,t,n){this.controlName=e,this.localeStrings=t,this.setLocale(n||eft)}return e.prototype.setLocale=function(t){var n=this.intGetControlConstant(e.locale,t);this.currentLocale=n||this.localeStrings},e.load=function(e){this.locale=bpt(this.locale,e,{},!0)},e.prototype.getConstant=function(e){return xpt(this.currentLocale[e])?this.localeStrings[e]||"":this.currentLocale[e]},e.prototype.intGetControlConstant=function(e,t){return e[t]?e[t][this.controlName]:null},e.locale={},e}(),Pmt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Tmt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Bmt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Pmt(t,e),Tmt([Kft(50)],t.prototype,"swipeThresholdDistance",void 0),t}(fmt),jmt=/(Up|Down)/;!function(e){function t(t,n){var a=e.call(this,n,t)||this;return a.touchAction=!0,a.tapCount=0,a.startEvent=function(e){if(!0===a.touchAction){var t=a.updateChangeTouches(e);void 0!==e.changedTouches&&(a.touchAction=!1),a.isTouchMoved=!1,a.movedDirection="",a.startPoint=a.lastMovedPoint={clientX:t.clientX,clientY:t.clientY},a.startEventData=t,a.hScrollLocked=a.vScrollLocked=!1,a.tStampStart=Date.now(),a.timeOutTapHold=setTimeout(function(){a.tapHoldEvent(e)},a.tapHoldThreshold),wft.add(a.element,gft.touchMoveEvent,a.moveEvent,a),wft.add(a.element,gft.touchEndEvent,a.endEvent,a),wft.add(a.element,gft.touchCancelEvent,a.cancelEvent,a)}},a.moveEvent=function(e){var t=a.updateChangeTouches(e);a.movedPoint=t,a.isTouchMoved=!(t.clientX===a.startPoint.clientX&&t.clientY===a.startPoint.clientY);var n={};a.isTouchMoved&&(clearTimeout(a.timeOutTapHold),a.calcScrollPoints(e),n=bpt(n,{},{startEvents:a.startEventData,originalEvent:e,startX:a.startPoint.clientX,startY:a.startPoint.clientY,distanceX:a.distanceX,distanceY:a.distanceY,scrollDirection:a.scrollDirection,velocity:a.getVelocity(t)}),a.trigger("scroll",n),a.lastMovedPoint={clientX:t.clientX,clientY:t.clientY})},a.cancelEvent=function(e){clearTimeout(a.timeOutTapHold),clearTimeout(a.timeOutTap),a.tapCount=0,a.swipeFn(e),wft.remove(a.element,gft.touchCancelEvent,a.cancelEvent)},a.endEvent=function(e){a.swipeFn(e),a.isTouchMoved||"function"==typeof a.tap&&(a.trigger("tap",{originalEvent:e,tapCount:++a.tapCount}),a.timeOutTap=setTimeout(function(){a.tapCount=0},a.tapThreshold)),a.modeclear()},a.swipeFn=function(e){clearTimeout(a.timeOutTapHold),clearTimeout(a.timeOutTap);var t=a.updateChangeTouches(e),n=t.clientX-a.startPoint.clientX,r=t.clientY-a.startPoint.clientY;n=Math.floor(n<0?-1*n:n),r=Math.floor(r<0?-1*r:n),a.isTouchMoved=n>1||r>1,/Firefox/.test(gft.userAgent)&&0===t.clientX&&0===t.clientY&&"mouseup"===e.type&&(a.isTouchMoved=!1),a.endPoint=t,a.calcPoints(e);var i={originalEvent:e,startEvents:a.startEventData,startX:a.startPoint.clientX,startY:a.startPoint.clientY,distanceX:a.distanceX,distanceY:a.distanceY,swipeDirection:a.movedDirection,velocity:a.getVelocity(t)};if(a.isTouchMoved){var o=void 0,l=a.swipeSettings.swipeThresholdDistance;o=bpt(o,a.defaultArgs,i);var s=!1,c=a.element,d=a.isScrollable(c),h=jmt.test(a.movedDirection);(l<a.distanceX&&!h||l<a.distanceY&&h)&&(s=!d||a.checkSwipe(c,h)),s&&a.trigger("swipe",o)}a.modeclear()},a.modeclear=function(){a.modeClear=setTimeout(function(){a.touchAction=!0},"function"!=typeof a.tap?0:20),a.lastTapTime=(new Date).getTime(),wft.remove(a.element,gft.touchMoveEvent,a.moveEvent),wft.remove(a.element,gft.touchEndEvent,a.endEvent),wft.remove(a.element,gft.touchCancelEvent,a.cancelEvent)},a.bind(),a}Pmt(t,e),t.prototype.onPropertyChanged=function(e,t){},t.prototype.bind=function(){this.wireEvents(),gft.isIE&&this.element.classList.add("e-block-touch")},t.prototype.destroy=function(){this.unwireEvents(),e.prototype.destroy.call(this)},t.prototype.wireEvents=function(){wft.add(this.element,gft.touchStartEvent,this.startEvent,this)},t.prototype.unwireEvents=function(){wft.remove(this.element,gft.touchStartEvent,this.startEvent)},t.prototype.getModuleName=function(){return"touch"},t.prototype.isScrollable=function(e){var t=getComputedStyle(e),n=t.overflow+t.overflowX+t.overflowY;return!!/(auto|scroll)/.test(n)},t.prototype.tapHoldEvent=function(e){var t;this.tapCount=0,this.touchAction=!0,wft.remove(this.element,gft.touchMoveEvent,this.moveEvent),wft.remove(this.element,gft.touchEndEvent,this.endEvent),t={originalEvent:e},this.trigger("tapHold",t),wft.remove(this.element,gft.touchCancelEvent,this.cancelEvent)},t.prototype.calcPoints=function(e){var t=this.updateChangeTouches(e);this.defaultArgs={originalEvent:e},this.distanceX=Math.abs(Math.abs(t.clientX)-Math.abs(this.startPoint.clientX)),this.distanceY=Math.abs(Math.abs(t.clientY)-Math.abs(this.startPoint.clientY)),this.distanceX>this.distanceY?this.movedDirection=t.clientX>this.startPoint.clientX?"Right":"Left":this.movedDirection=t.clientY<this.startPoint.clientY?"Up":"Down"},t.prototype.calcScrollPoints=function(e){var t=this.updateChangeTouches(e);this.defaultArgs={originalEvent:e},this.distanceX=Math.abs(Math.abs(t.clientX)-Math.abs(this.lastMovedPoint.clientX)),this.distanceY=Math.abs(Math.abs(t.clientY)-Math.abs(this.lastMovedPoint.clientY)),(this.distanceX>this.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=t.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=t.clientY<this.lastMovedPoint.clientY?"Up":"Down",this.vScrollLocked=!0)},t.prototype.getVelocity=function(e){var t=e.clientX,n=e.clientY,a=Date.now(),r=t-this.startPoint.clientX,i=n-this.startPoint.clientX,o=a-this.tStampStart;return Math.sqrt(r*r+i*i)/o},t.prototype.checkSwipe=function(e,t){var n=["scroll","offset"],a=t?["Height","Top"]:["Width","Left"];return e[n[0]+a[0]]<=e[n[1]+a[0]]||(0===e[n[0]+a[1]]||e[n[1]+a[0]]+e[n[0]+a[1]]>=e[n[0]+a[0]])},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},Tmt([Jft()],t.prototype,"tap",void 0),Tmt([Jft()],t.prototype,"tapHold",void 0),Tmt([Jft()],t.prototype,"swipe",void 0),Tmt([Jft()],t.prototype,"scroll",void 0),Tmt([Kft(350)],t.prototype,"tapThreshold",void 0),Tmt([Kft(750)],t.prototype,"tapHoldThreshold",void 0),Tmt([Qft({},Bmt)],t.prototype,"swipeSettings",void 0),t=Tmt([$ft],t)}(Pft);var Wmt=new RegExp("\\n|\\r|\\s\\s+","g"),Rmt=new RegExp(/'|"/g),Fmt=new RegExp("if ?\\("),Ymt=new RegExp("else if ?\\("),qmt=new RegExp("else"),Umt=new RegExp("for ?\\("),Gmt=new RegExp("(/if|/for)"),Kmt=new RegExp("\\((.*)\\)",""),Qmt=new RegExp("^[0-9]+$","g"),Xmt=new RegExp("[\\w\"'.\\s+]+","g"),Jmt=new RegExp('"(.*?)"',"g"),$mt=new RegExp("[\\w\"'@#$.\\s-+]+","g"),evt=new RegExp("\\${([^}]*)}","g"),tvt=/^\..*/gm,nvt=/\\/gi,avt=/\\\\/gi,rvt=new RegExp("[\\w\"'@#$.\\s+]+","g"),ivt=/\window\./gm;function ovt(e,t,n){var a="data",r=function(e,t,n,a){var r=0,i=[],o=e.match(/class="([^"]+|)\s{2}/g),l="";o&&o.forEach(function(t){l=t.replace(/\s\s+/g," "),e=e.replace(t,l)});return e.replace(Wmt,"").replace(Jmt,"'$1'").replace(evt,function(e,o,l,s){var c=/@|#|\$/gm,d=o.match(Kmt);if(d){var h=d[1];if(Ymt.test(o))o='";} '+o.replace(d[1],h.replace(Xmt,function(e){return lvt(e=e.trim(),!Rmt.test(e)&&-1===i.indexOf(e),t,i,a)}))+'{ \n str = str + "';else if(Fmt.test(o))o='"; '+o.replace(d[1],h.replace($mt,function(e){return dvt(e,t,i,a)}))+'{ \n str = str + "';else if(Umt.test(o)){var u=d[1].split(" of ");o='"; '+o.replace(d[1],function(e){return i.push(u[0]),i.push(u[0]+"Index"),"var i"+(r+=1)+"=0; i"+r+" < "+lvt(u[1],!0,t,i,a)+".length; i"+r+"++"})+"{ \n "+u[0]+"= "+lvt(u[1],!0,t,i,a)+"[i"+r+"]; \n var "+u[0]+"Index=i"+r+'; \n str = str + "'}else{var p=o.split("("),f=n&&n.hasOwnProperty(p[0])?"this.":"global";f=/\./.test(p[0])?"":f;var m=d[1].split(",");0===d[1].length||/data/.test(m[0])||/window./.test(m[0])||(d[1]="global"===f?t+"."+d[1]:d[1]);var v=/@|\$|#/gm,g=/\]\./gm;if(ivt.test(o)&&g.test(o)||v.test(o))/@|\$|#|\]\./gm.test(o)&&(o='"+ '+("global"===f?"":f)+o.replace(d[1],h.replace(rvt,function(e){return dvt(e,t,i,a)}))+'+ "');else o='" + '+("global"===f?"":f)+o.replace(h,lvt(d[1].replace(/,( |)data.|,/gi,","+t+".").replace(/,( |)data.window/gi,",window"),"global"!==f,t,i,a))+'+"'}}else qmt.test(o)?o='"; '+o.replace(qmt,'} else { \n str = str + "'):o.match(Gmt)?o=o.replace(Gmt,'"; \n } \n str = str + "'):c.test(o)?(o.match(nvt)&&(o=cvt(o)),o='"+'+svt(o,-1===i.indexOf(o),t,i)+'"]+"'):o=o.match(nvt)?'"+'+svt(o=cvt(o),-1===i.indexOf(o),t,i)+'"]+"':'"+'+lvt(o.replace(/,/gi,"+"+t+"."),-1===i.indexOf(o),t,i,a)+'+"';return o})}(e,a,t,n);return new Function(a,'var str="'+r+"\";var valueRegEx = (/value=\\'([A-Za-z0-9 _]*)((.)([\\w)(!-;?-■\\s]+)['])/g);\n var hrefRegex = (/(?:href)([\\s='\"./]+)([\\w-./?=&\\\\#\"]+)((.)([\\w)(!-;/?-■\\s]+)['])/g);\n if(str.match(valueRegEx)){\n var check = str.match(valueRegEx);\n var str1 = str;\n for (var i=0; i < check.length; i++) {\n var check1 = str.match(valueRegEx)[i].split('value=')[1];\n var change = check1.match(/^'/) !== null ? check1.replace(/^'/, '\"') : check1;\n change =change.match(/.$/)[0] === '\\'' ? change.replace(/.$/,'\"') : change;\n str1 = str1.replace(check1, change);\n }\n str = str.replace(str, str1);\n }\n else if (str.match(/(?:href='')/) === null) {\n if(str.match(hrefRegex)) {\n var check = str.match(hrefRegex);\n var str1 = str;\n for (var i=0; i < check.length; i++) {\n var check1 = str.match(hrefRegex)[i].split('href=')[1];\n if (check1) {\n var change = check1.match(/^'/) !== null ? check1.replace(/^'/, '\"') : check1;\n change =change.match(/.$/)[0] === '\\'' ? change.replace(/.$/,'\"') : change;\n str1 = str1.replace(check1, change);\n }\n }\n str = str.replace(str, str1);\n }\n }\n return str;").bind(t)}function lvt(e,t,n,a,r){return!t||Qmt.test(e)||-1!==a.indexOf(e.split(".")[0])||r?e:n+"."+e}function svt(e,t,n,a){return t&&!Qmt.test(e)&&-1===a.indexOf(e.split(".")[0])?n+'["'+e:e}function cvt(e){return e.match(avt)||(e=e.replace(nvt,"\\\\")),e}function dvt(e,t,n,a){e=e.trim();if(/\window\./gm.test(e))return e;var r=/'|"/gm;return/@|\$|#/gm.test(e)&&(e=svt(e,-1===n.indexOf(e),t,n)+'"]'),tvt.test(e)?function(e,t,n,a){return!t||Qmt.test(e)||-1!==a.indexOf(e.split(".")[0])||/^\..*/gm.test(e)?e:n+"."+e}(e,!r.test(e)&&-1===n.indexOf(e),t,n):lvt(e,!r.test(e)&&-1===n.indexOf(e),t,n,a)}var hvt=/^[\n\r.]+<tr|^<tr/,uvt=/^[\n\r.]+<svg|^<path|^<g/;function pvt(e,t,n){var a=wvt.compile(e,t,n);return function(e,t,n,r,i,o,l,s){var c=a(e,t,n,l,s);return"string"==typeof c?uvt.test(c)?bft("svg",{innerHTML:c}).childNodes:bft(hvt.test(c)?"table":"div",{innerHTML:c}).childNodes:c}}var fvt,mvt,vvt,gvt,wvt={compile:(new(function(){function e(){}return e.prototype.compile=function(e,t,n){return void 0===t&&(t={}),ovt(e,t)},e}())).compile},yvt=["script","style","iframe[src]",'link[href*="javascript:"]','object[type="text/x-scriptlet"]','object[data^="data:text/html;base64"]','img[src^="data:text/html;base64"]','[src^="javascript:"]','[dynsrc^="javascript:"]','[lowsrc^="javascript:"]','[type^="application/x-shockwave-flash"]'],bvt=[{attribute:"href",selector:'[href*="javascript:"]'},{attribute:"background",selector:'[background^="javascript:"]'},{attribute:"style",selector:'[style*="javascript:"]'},{attribute:"style",selector:'[style*="expression("]'},{attribute:"href",selector:'a[href^="data:text/html;base64"]'}],xvt=["onchange","onclick","onmouseover","onmouseout","onkeydown","onload","onerror","onblur","onfocus","onbeforeload","onbeforeunload","onkeyup","onsubmit","onafterprint","onbeforeonload","onbeforeprint","onblur","oncanplay","oncanplaythrough","onchange","onclick","oncontextmenu","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onerror","onfocus","onformchange","onforminput","onhaschange","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onmessage","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onmousewheel","onoffline","onoine","ononline","onpagehide","onpageshow","onpause","onplay","onplaying","onpopstate","onprogress","onratechange","onreadystatechange","onredo","onresize","onscroll","onseeked","onseeking","onselect","onstalled","onstorage","onsubmit","onsuspend","ontimeupdate","onundo","onunload","onvolumechange","onwaiting","onmouseenter","onmouseleave","onmousewheel","onstart","onpropertychange"],Evt=function(){function e(){}return e.beforeSanitize=function(){return{selectors:{tags:yvt,attributes:bvt}}},e.sanitize=function(e){var t=this.beforeSanitize();return this.serializeValue(t,e)},e.serializeValue=function(e,t){this.removeAttrs=e.selectors.attributes,this.removeTags=e.selectors.tags,this.wrapElement=document.createElement("div"),this.wrapElement.innerHTML=t,this.removeXssTags(),this.removeJsEvents(),this.removeXssAttrs();var n=this.wrapElement.innerHTML;return this.removeElement(),n.replace("&amp;","&")},e.removeElement=function(){for(var e=this.wrapElement.children,t=0;t<e.length;t++)for(var n=e[t].attributes,a=0;a<n.length;a++)this.wrapElement.children[t].removeAttribute(n[a].localName)},e.removeXssTags=function(){var e=this.wrapElement.querySelectorAll(this.removeTags.join(","));e.length>0&&e.forEach(function(e){Cft(e)})},e.removeJsEvents=function(){var e=this.wrapElement.querySelectorAll("["+xvt.join("],[")+"]");e.length>0&&e.forEach(function(e){xvt.forEach(function(t){e.hasAttribute(t)&&e.removeAttribute(t)})})},e.removeXssAttrs=function(){var e=this;this.removeAttrs.forEach(function(t,n){var a=e.wrapElement.querySelectorAll(t.selector);a.length>0&&a.forEach(function(e){e.removeAttribute(t.attribute)})})},e}(),kvt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Mvt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Svt="e-other-month",Avt="e-other-year",_vt="e-calendar",Cvt="e-device",Zvt="e-rtl",Hvt="e-year",Ivt="e-month",Dvt="e-decade",Nvt="e-icons",Ovt="e-disabled",Lvt="e-overlay",Vvt="e-week-number",zvt="e-selected",Pvt="e-focused-date",Tvt="e-month-hide",Bvt="e-today",jvt="e-day",Wvt="e-cell",Rvt="e-zoomin",Fvt="e-calendar-day-header-lg",Yvt=864e5,qvt=function(e){function t(t,n){var a=e.call(this,t,n)||this;return a.effect="",a.isPopupClicked=!1,a.isDateSelected=!0,a.isTodayClicked=!1,a.preventChange=!1,a.isAngular=!1,a}return kvt(t,e),t.prototype.render=function(){this.rangeValidation(this.min,this.max),this.calendarEleCopy=this.element.cloneNode(!0),"Islamic"===this.calendarMode&&(+this.min.setSeconds(0)===+new Date(1900,0,1,0,0,0)&&(this.min=new Date(1944,2,18)),+this.max===+new Date(2099,11,31)&&(this.max=new Date(2069,10,16))),this.globalize=new aft(this.locale),(xpt(this.firstDayOfWeek)||this.firstDayOfWeek>6||this.firstDayOfWeek<0)&&this.setProperties({firstDayOfWeek:this.globalize.getFirstDayOfWeek()},!0),this.todayDisabled=!1,this.todayDate=new Date((new Date).setHours(0,0,0,0)),"calendar"===this.getModuleName()?(this.element.classList.add(_vt),this.enableRtl&&this.element.classList.add(Zvt),gft.isDevice&&this.element.classList.add(Cvt),Hft(this.element,{"data-role":"calendar"}),this.tabIndex=this.element.hasAttribute("tabindex")?this.element.getAttribute("tabindex"):"0",this.element.setAttribute("tabindex",this.tabIndex)):(this.calendarElement=this.createElement("div"),this.calendarElement.classList.add(_vt),this.enableRtl&&this.calendarElement.classList.add(Zvt),gft.isDevice&&this.calendarElement.classList.add(Cvt),Hft(this.calendarElement,{role:"calendar"})),this.createHeader(),this.createContent(),this.wireEvents()},t.prototype.rangeValidation=function(e,t){xpt(e)&&this.setProperties({min:new Date(1900,0,1)},!0),xpt(t)&&this.setProperties({max:new Date(2099,11,31)},!0)},t.prototype.getDefaultKeyConfig=function(){return this.defaultKeyConfigs={controlUp:"ctrl+38",controlDown:"ctrl+40",moveDown:"downarrow",moveUp:"uparrow",moveLeft:"leftarrow",moveRight:"rightarrow",select:"enter",home:"home",end:"end",pageUp:"pageup",pageDown:"pagedown",shiftPageUp:"shift+pageup",shiftPageDown:"shift+pagedown",controlHome:"ctrl+home",controlEnd:"ctrl+end",altUpArrow:"alt+uparrow",spacebar:"space",altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"},this.defaultKeyConfigs},t.prototype.validateDate=function(e){this.setProperties({min:this.checkDateValue(new Date(this.checkValue(this.min)))},!0),this.setProperties({max:this.checkDateValue(new Date(this.checkValue(this.max)))},!0),this.currentDate=this.currentDate?this.currentDate:new Date((new Date).setHours(0,0,0,0)),!xpt(e)&&this.min<=this.max&&e>=this.min&&e<=this.max&&(this.currentDate=new Date(this.checkValue(e)))},t.prototype.setOverlayIndex=function(e,t,n,a){if(a&&!xpt(t)&&!xpt(n)&&!xpt(e)){var r=parseInt(t.style.zIndex,10)?parseInt(t.style.zIndex,10):1e3;n.style.zIndex=(r-1).toString(),e.style.zIndex=r.toString()}},t.prototype.minMaxUpdate=function(e){+this.min<=+this.max?Eft([this.element],Lvt):(this.setProperties({min:this.min},!0),xft([this.element],Lvt)),this.min=xpt(this.min)||!+this.min?this.min=new Date(1900,0,1):this.min,this.max=xpt(this.max)||!+this.max?this.max=new Date(2099,11,31):this.max,+this.min<=+this.max&&e&&+e<=+this.max&&+e>=+this.min?this.currentDate=new Date(this.checkValue(e)):+this.min<=+this.max&&!e&&+this.currentDate>+this.max?this.currentDate=new Date(this.checkValue(this.max)):+this.currentDate<+this.min&&(this.currentDate=new Date(this.checkValue(this.min)))},t.prototype.createHeader=function(){this.headerElement=this.createElement("div",{className:"e-header"});var e=this.createElement("div",{className:"e-icon-container"});this.previousIcon=this.createElement("button",{className:"e-prev",attrs:{type:"button"}}),omt(this.previousIcon,{duration:400,selector:".e-prev",isCenterRipple:!0}),Hft(this.previousIcon,{"aria-disabled":"false","aria-label":"previous month"}),this.nextIcon=this.createElement("button",{className:"e-next",attrs:{type:"button"}}),omt(this.nextIcon,{selector:".e-next",duration:400,isCenterRipple:!0}),"daterangepicker"===this.getModuleName()&&(Hft(this.previousIcon,{tabIndex:"-1"}),Hft(this.nextIcon,{tabIndex:"-1"})),Hft(this.nextIcon,{"aria-disabled":"false","aria-label":"next month"}),this.headerTitleElement=this.createElement("div",{className:jvt+" e-title"}),Hft(this.headerTitleElement,{"aria-atomic":"true","aria-live":"assertive","aria-label":"title"}),this.headerElement.appendChild(this.headerTitleElement),this.previousIcon.appendChild(this.createElement("span",{className:"e-date-icon-prev "+Nvt})),this.nextIcon.appendChild(this.createElement("span",{className:"e-date-icon-next "+Nvt})),e.appendChild(this.previousIcon),e.appendChild(this.nextIcon),this.headerElement.appendChild(e),"calendar"===this.getModuleName()?this.element.appendChild(this.headerElement):this.calendarElement.appendChild(this.headerElement),this.adjustLongHeaderSize()},t.prototype.createContent=function(){this.contentElement=this.createElement("div",{className:"e-content"}),this.table=this.createElement("table",{attrs:{tabIndex:"0",role:"grid","aria-activedescendant":""}}),"calendar"===this.getModuleName()?this.element.appendChild(this.contentElement):this.calendarElement.appendChild(this.contentElement),this.contentElement.appendChild(this.table),this.createContentHeader(),this.createContentBody(),this.showTodayButton&&this.createContentFooter()},t.prototype.getCultureValues=function(){var e,t,n=[],a="days.stand-alone."+this.dayHeaderFormat.toLowerCase();e="en"===this.locale||"en-US"===this.locale?fpt(a,rft.getDependables($pt,"",t,!1)[nft[1]]):this.getCultureObjects($pt,""+this.locale);for(var r=0,i=Object.keys(e);r<i.length;r++){var o=i[r];n.push(fpt(o,e))}return n},t.prototype.toCapitalize=function(e){return!xpt(e)&&e.length?e[0].toUpperCase()+e.slice(1):e},t.prototype.createContentHeader=function(){"calendar"===this.getModuleName()?xpt(this.element.querySelectorAll(".e-content .e-week-header")[0])||Cft(this.element.querySelectorAll(".e-content .e-week-header")[0]):xpt(this.calendarElement.querySelectorAll(".e-content .e-week-header")[0])||Cft(this.calendarElement.querySelectorAll(".e-content .e-week-header")[0]);var e="";(this.firstDayOfWeek>6||this.firstDayOfWeek<0)&&this.setProperties({firstDayOfWeek:0},!0),this.tableHeadElement=this.createElement("thead",{className:"e-week-header"}),this.weekNumber&&(e+='<th class="e-week-number"></th>',"calendar"===this.getModuleName()?xft([this.element],""+Vvt):xft([this.calendarElement],""+Vvt));for(var t=this.shiftArray(this.getCultureValues().length>0&&this.getCultureValues(),this.firstDayOfWeek),n=0;n<=6;n++)e+='<th class="">'+this.toCapitalize(t[n])+"</th>";e="<tr>"+e+"</tr>",this.tableHeadElement.innerHTML=e,this.table.appendChild(this.tableHeadElement)},t.prototype.createContentBody=function(){switch("calendar"===this.getModuleName()?xpt(this.element.querySelectorAll(".e-content tbody")[0])||Cft(this.element.querySelectorAll(".e-content tbody")[0]):xpt(this.calendarElement.querySelectorAll(".e-content tbody")[0])||Cft(this.calendarElement.querySelectorAll(".e-content tbody")[0]),this.start){case"Year":this.renderYears();break;case"Decade":this.renderDecades();break;default:this.renderMonths()}},t.prototype.updateFooter=function(){this.todayElement.textContent=this.l10.getConstant("today"),this.todayElement.setAttribute("aria-label",this.l10.getConstant("today"))},t.prototype.createContentFooter=function(){if(this.showTodayButton){var e=new Date(+this.min),t=new Date(+this.max);this.globalize=new aft(this.locale),this.l10=new zmt(this.getModuleName(),{today:"Today"},this.locale),this.todayElement=this.createElement("button",{attrs:{role:"button"}}),omt(this.todayElement),this.updateFooter(),xft([this.todayElement],["e-btn",Bvt,"e-flat","e-primary","e-css"]),+new Date(e.setHours(0,0,0,0))<=+this.todayDate&&+this.todayDate<=+new Date(t.setHours(0,0,0,0))&&!this.todayDisabled||xft([this.todayElement],Ovt),this.footer=this.createElement("div",{className:"e-footer-container"}),this.footer.appendChild(this.todayElement),"calendar"===this.getModuleName()&&this.element.appendChild(this.footer),"datepicker"===this.getModuleName()&&this.calendarElement.appendChild(this.footer),"datetimepicker"===this.getModuleName()&&this.calendarElement.appendChild(this.footer),this.todayElement.classList.contains(Ovt)||wft.add(this.todayElement,"click",this.todayButtonClick,this)}},t.prototype.wireEvents=function(e,t,n,a){wft.add(this.headerTitleElement,"click",this.navigateTitle,this),this.defaultKeyConfigs=bpt(this.defaultKeyConfigs,this.keyConfigs),"calendar"===this.getModuleName()?this.keyboardModule=new Vmt(this.element,{eventName:"keydown",keyAction:this.keyActionHandle.bind(this),keyConfigs:this.defaultKeyConfigs}):this.keyboardModule=new Vmt(this.calendarElement,{eventName:"keydown",keyAction:this.keyActionHandle.bind(this),keyConfigs:this.defaultKeyConfigs})},t.prototype.dateWireEvents=function(e,t,n,a){this.defaultKeyConfigs=this.getDefaultKeyConfig(),this.defaultKeyConfigs=bpt(this.defaultKeyConfigs,n),this.serverModuleName=a},t.prototype.todayButtonClick=function(e,t,n){this.showTodayButton&&(this.currentView()===this.depth?this.effect="":this.effect="e-zoomin",this.getViewNumber(this.start)>=this.getViewNumber(this.depth)?this.navigateTo(this.depth,new Date(this.checkValue(t)),n):this.navigateTo("Month",new Date(this.checkValue(t)),n))},t.prototype.resetCalendar=function(){this.calendarElement&&Cft(this.calendarElement),this.tableBodyElement&&Cft(this.tableBodyElement),this.table&&Cft(this.table),this.tableHeadElement&&Cft(this.tableHeadElement),this.nextIcon&&Cft(this.nextIcon),this.previousIcon&&Cft(this.previousIcon),this.footer&&Cft(this.footer),this.todayElement=null,this.renderDayCellArgs=null,this.calendarElement=this.tableBodyElement=this.footer=this.tableHeadElement=this.nextIcon=this.previousIcon=this.table=null},t.prototype.keyActionHandle=function(e,t,n){var a,r=this.tableBodyElement.querySelector("tr td.e-focused-date");a=n?xpt(r)||+t!==parseInt(r.getAttribute("id").split("_")[0],10)?this.tableBodyElement.querySelector("tr td.e-selected"):r:this.tableBodyElement.querySelector("tr td.e-selected");var i=this.getViewNumber(this.currentView()),o=this.getViewNumber(this.depth),l=i===o&&this.getViewNumber(this.start)>=o;switch(this.effect="",e.action){case"moveLeft":this.keyboardNavigate(-1,i,e,this.max,this.min),e.preventDefault();break;case"moveRight":this.keyboardNavigate(1,i,e,this.max,this.min),e.preventDefault();break;case"moveUp":0===i?this.keyboardNavigate(-7,i,e,this.max,this.min):this.keyboardNavigate(-4,i,e,this.max,this.min),e.preventDefault();break;case"moveDown":0===i?this.keyboardNavigate(7,i,e,this.max,this.min):this.keyboardNavigate(4,i,e,this.max,this.min),e.preventDefault();break;case"select":if(e.target===this.todayElement)this.todayButtonClick(e,t);else{var s=xpt(r)?a:r;if(!xpt(s)&&!s.classList.contains(Ovt))if(l){var c=new Date(parseInt(""+s.id,0));this.selectDate(e,c,s)}else this.contentClick(null,--i,s,t)}break;case"controlUp":this.title(),e.preventDefault();break;case"controlDown":xpt(r)&&(xpt(a)||l)||this.contentClick(null,--i,r||a,t),e.preventDefault();break;case"home":this.currentDate=this.firstDay(this.currentDate),Cft(this.tableBodyElement),0===i?this.renderMonths(e):1===i?this.renderYears(e):this.renderDecades(e),e.preventDefault();break;case"end":this.currentDate=this.lastDay(this.currentDate,i),Cft(this.tableBodyElement),0===i?this.renderMonths(e):1===i?this.renderYears(e):this.renderDecades(e),e.preventDefault();break;case"pageUp":this.addMonths(this.currentDate,-1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"pageDown":this.addMonths(this.currentDate,1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"shiftPageUp":this.addYears(this.currentDate,-1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"shiftPageDown":this.addYears(this.currentDate,1),this.navigateTo("Month",this.currentDate),e.preventDefault();break;case"controlHome":this.navigateTo("Month",new Date(this.currentDate.getFullYear(),0,1)),e.preventDefault();break;case"controlEnd":this.navigateTo("Month",new Date(this.currentDate.getFullYear(),11,31)),e.preventDefault()}"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.keyboardNavigate=function(e,t,n,a,r){var i=new Date(this.checkValue(this.currentDate));switch(t){case 2:this.addYears(this.currentDate,e),this.isMonthYearRange(this.currentDate)?(Cft(this.tableBodyElement),this.renderDecades(n)):this.currentDate=i;break;case 1:this.addMonths(this.currentDate,e),this.calendarMode,this.isMonthYearRange(this.currentDate)?(Cft(this.tableBodyElement),this.renderYears(n)):this.currentDate=i;break;case 0:this.addDay(this.currentDate,e,n,a,r),this.isMinMaxRange(this.currentDate)?(Cft(this.tableBodyElement),this.renderMonths(n)):this.currentDate=i}},t.prototype.preRender=function(e){var t=this;this.navigatePreviousHandler=this.navigatePrevious.bind(this),this.navigateNextHandler=this.navigateNext.bind(this),this.defaultKeyConfigs=this.getDefaultKeyConfig(),this.navigateHandler=function(e){t.triggerNavigate(e)}},t.prototype.minMaxDate=function(e){var t=new Date(new Date(+e).setHours(0,0,0,0)),n=new Date(new Date(+this.min).setHours(0,0,0,0)),a=new Date(new Date(+this.max).setHours(0,0,0,0));return+t!==+n&&+t!==+a||(+e<+this.min&&(e=new Date(+this.min)),+e>+this.max&&(e=new Date(+this.max))),e},t.prototype.renderMonths=function(e,t,n){var a,r=this.weekNumber?8:7;a="Gregorian"===this.calendarMode?this.renderDays(this.currentDate,t,null,null,n):this.islamicModule.islamicRenderDays(this.currentDate,t),this.createContentHeader(),"Gregorian"===this.calendarMode?this.renderTemplate(a,r,Ivt,e,t):this.islamicModule.islamicRenderTemplate(a,r,Ivt,e,t)},t.prototype.renderDays=function(e,t,n,a,r){var i,o=[],l=r?new Date(+e):this.getDate(new Date,this.timezone),s=new Date(this.checkValue(e)),c=s.getMonth();this.titleUpdate(e,"days");var d=s;for(s=new Date(d.getFullYear(),d.getMonth(),0,d.getHours(),d.getMinutes(),d.getSeconds(),d.getMilliseconds());s.getDay()!==this.firstDayOfWeek;)this.setStartDate(s,-864e5);for(var h=0;h<42;++h){var u=this.createElement("td",{className:Wvt}),p=this.createElement("span");if(h%7==0&&this.weekNumber){var f="FirstDay"===this.weekRule?6:"FirstFourDayWeek"===this.weekRule?3:0,m=new Date(s.getFullYear(),s.getMonth(),s.getDate()+f);p.textContent=""+this.getWeek(m),u.appendChild(p),xft([u],""+Vvt),o.push(u)}i=new Date(+s),s=this.minMaxDate(s);var v={type:"dateTime",skeleton:"full"},g=this.globalize.parseDate(this.globalize.formatDate(s,v),v),w=this.dayCell(s),y=this.globalize.formatDate(s,{type:"date",skeleton:"full"}),b=this.createElement("span");b.textContent=this.globalize.formatDate(s,{format:"d",type:"date",skeleton:"yMd"});var x=this.min>s||this.max<s;x?(xft([w],Ovt),xft([w],Lvt)):b.setAttribute("title",""+y),c!==s.getMonth()&&xft([w],Svt),0!==s.getDay()&&6!==s.getDay()||xft([w],"e-weekend"),w.appendChild(b),this.renderDayCellArgs={date:s,isDisabled:!1,element:w,isOutOfRange:x};var E=this.renderDayCellArgs;if(this.renderDayCellEvent(E),E.isDisabled){var k=new Date(this.checkValue(t)),M=new Date(this.checkValue(E.date));if(n){if(!xpt(a)&&a.length>0)for(var S=0;S<a.length;S++){+new Date(this.globalize.formatDate(E.date,{type:"date",skeleton:"yMd"}))===+new Date(this.globalize.formatDate(a[S],{type:"date",skeleton:"yMd"}))&&(a.splice(S,1),S=-1)}}else k&&+k===+M&&this.setProperties({value:null},!0)}this.renderDayCellArgs.isDisabled&&!w.classList.contains(zvt)&&(xft([w],Ovt),xft([w],Lvt),+this.renderDayCellArgs.date===+this.todayDate&&(this.todayDisabled=!0));var A=w.classList.contains(Svt),_=w.classList.contains(Ovt);if(_||wft.add(w,"click",this.clickHandler,this),!n||xpt(a)||_)!_&&this.getDateVal(s,t)&&xft([w],zvt);else{for(var C=0;C<a.length;C++){var Z={format:null,type:"date",skeleton:"short",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"};this.globalize.formatDate(s,Z)===this.globalize.formatDate(a[C],Z)&&this.getDateVal(s,a[C])||this.getDateVal(s,t)?xft([w],zvt):this.updateFocus(A,_,s,w,e)}a.length<=0&&this.updateFocus(A,_,s,w,e)}this.updateFocus(A,_,s,w,e),g.getFullYear()===l.getFullYear()&&g.getMonth()===l.getMonth()&&g.getDate()===l.getDate()&&xft([w],Bvt),o.push(this.renderDayCellArgs.element),s=new Date(+i),this.addDay(s,1,null,this.max,this.min)}return o},t.prototype.updateFocus=function(e,t,n,a,r){r.getDate()!==n.getDate()||e||t?(r>=this.max&&parseInt(a.id,0)===+this.max&&!e&&!t&&xft([a],Pvt),r<=this.min&&parseInt(a.id,0)===+this.min&&!e&&!t&&xft([a],Pvt)):xft([a],Pvt)},t.prototype.renderYears=function(e,t){this.removeTableHeadElement();var n=[],a=xpt(t),r=new Date(this.checkValue(this.currentDate)),i=r.getMonth(),o=r.getFullYear(),l=r,s=l.getFullYear(),c=new Date(this.checkValue(this.min)).getFullYear(),d=new Date(this.checkValue(this.min)).getMonth(),h=new Date(this.checkValue(this.max)).getFullYear(),u=new Date(this.checkValue(this.max)).getMonth();l.setMonth(0),this.titleUpdate(this.currentDate,"months"),l.setDate(1);for(var p=0;p<12;++p){var f=this.dayCell(l),m=this.createElement("span"),v=t&&t.getMonth()===l.getMonth(),g=t&&t.getFullYear()===o&&v;m.textContent=this.toCapitalize(this.globalize.formatDate(l,{format:null,type:"dateTime",skeleton:"MMM"})),this.min&&(s<c||p<d&&s===c)||this.max&&(s>h||p>u&&s>=h)?xft([f],Ovt):!a&&g?xft([f],zvt):l.getMonth()===i&&this.currentDate.getMonth()===i&&xft([f],Pvt),l.setDate(1),l.setMonth(l.getMonth()+1),f.classList.contains(Ovt)||wft.add(f,"click",this.clickHandler,this),f.appendChild(m),n.push(f)}this.renderTemplate(n,4,Hvt,e,t)},t.prototype.renderDecades=function(e,t){this.removeTableHeadElement();var n=[],a=new Date(this.checkValue(this.currentDate));a.setMonth(0),a.setDate(1);var r=a.getFullYear(),i=new Date(a.setFullYear(r-r%10)),o=new Date(a.setFullYear(r-r%10+9)),l=i.getFullYear(),s=o.getFullYear(),c=this.globalize.formatDate(i,{format:null,type:"dateTime",skeleton:"y"}),d=this.globalize.formatDate(o,{format:null,type:"dateTime",skeleton:"y"});this.headerTitleElement.textContent=c+" - "+d;for(var h=new Date(r-r%10-1,0,1).getFullYear(),u=0;u<12;++u){var p=h+u;a.setFullYear(p);var f=this.dayCell(a);Hft(f,{role:"gridcell"});var m=this.createElement("span");m.textContent=this.globalize.formatDate(a,{format:null,type:"dateTime",skeleton:"y"}),p<l||p>s?(xft([f],Avt),xpt(t)||a.getFullYear()!==t.getFullYear()||xft([f],zvt),(p<new Date(this.checkValue(this.min)).getFullYear()||p>new Date(this.checkValue(this.max)).getFullYear())&&xft([f],Ovt)):p<new Date(this.checkValue(this.min)).getFullYear()||p>new Date(this.checkValue(this.max)).getFullYear()?xft([f],Ovt):xpt(t)||a.getFullYear()!==t.getFullYear()?a.getFullYear()!==this.currentDate.getFullYear()||f.classList.contains(Ovt)||xft([f],Pvt):xft([f],zvt),f.classList.contains(Ovt)||wft.add(f,"click",this.clickHandler,this),f.appendChild(m),n.push(f)}this.renderTemplate(n,4,"e-decade",e,t)},t.prototype.dayCell=function(e){var t={skeleton:"full",type:"dateTime",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"},n=this.globalize.parseDate(this.globalize.formatDate(e,t),t).valueOf(),a={className:Wvt,attrs:{id:""+kpt(""+n),"aria-selected":"false",role:"gridcell"}};return this.createElement("td",a)},t.prototype.firstDay=function(e){var t="Decade"!==this.currentView()?this.tableBodyElement.querySelectorAll("td:not(."+Svt):this.tableBodyElement.querySelectorAll("td:not(."+Avt);if(t.length)for(var n=0;n<t.length;n++)if(!t[n].classList.contains(Ovt)){e=new Date(parseInt(t[n].id,0));break}return e},t.prototype.lastDay=function(e,t){var n=new Date(e.getFullYear(),e.getMonth()+1,0);if(2!==t){var a=Math.abs(n.getTimezoneOffset()-this.firstDay(e).getTimezoneOffset());return a&&n.setHours(this.firstDay(e).getHours()+a/60),this.findLastDay(n)}return this.findLastDay(this.firstDay(n))},t.prototype.checkDateValue=function(e){return!xpt(e)&&e instanceof Date&&!isNaN(+e)?e:null},t.prototype.findLastDay=function(e){var t="Decade"===this.currentView()?this.tableBodyElement.querySelectorAll("td:not(."+Avt):this.tableBodyElement.querySelectorAll("td:not(."+Svt);if(t.length)for(var n=t.length-1;n>=0;n--)if(!t[n].classList.contains(Ovt)){e=new Date(parseInt(t[n].id,0));break}return e},t.prototype.removeTableHeadElement=function(){"calendar"===this.getModuleName()?xpt(this.element.querySelectorAll(".e-content table thead")[0])||Cft(this.tableHeadElement):xpt(this.calendarElement.querySelectorAll(".e-content table thead")[0])||Cft(this.tableHeadElement)},t.prototype.renderTemplate=function(e,t,n,a,r){var i,o=this.getViewNumber(this.currentView());this.tableBodyElement=this.createElement("tbody"),this.table.appendChild(this.tableBodyElement),Eft([this.contentElement,this.headerElement],[Ivt,Dvt,Hvt]),xft([this.contentElement,this.headerElement],[n]);for(var l=t,s=0,c=0;c<e.length/t;++c){for(i=this.createElement("tr",{attrs:{role:"row"}}),s=0+s;s<l;s++)e[s].classList.contains("e-week-number")||xpt(e[s].children[0])||(xft([e[s].children[0]],[jvt]),omt(e[s].children[0],{duration:600,isCenterRipple:!0})),i.appendChild(e[s]),this.weekNumber&&7===s&&e[7].classList.contains(Svt)&&xft([i],Tvt),!this.weekNumber&&6===s&&e[6].classList.contains(Svt)&&xft([i],Tvt),this.weekNumber?41===s&&e[41].classList.contains(Svt)&&xft([i],Tvt):35===s&&e[35].classList.contains(Svt)&&xft([i],Tvt);l+=t,s+=0,this.tableBodyElement.appendChild(i)}this.table.querySelector("tbody").className=this.effect,"Gregorian"===this.calendarMode?this.iconHandler():this.islamicModule.islamicIconHandler(),(o!==this.getViewNumber(this.currentView())||0===o&&o!==this.getViewNumber(this.currentView()))&&this.navigateHandler(a),this.setAriaActiveDescendant()},t.prototype.clickHandler=function(e,t){this.clickEventEmitter(e);var n=e.currentTarget,a=this.getViewNumber(this.currentView());n.classList.contains(Svt)?this.contentClick(e,0,null,t):a===this.getViewNumber(this.depth)&&this.getViewNumber(this.start)>=this.getViewNumber(this.depth)||2===a?this.contentClick(e,1,null,t):n.classList.contains(Svt)||0!==a?this.contentClick(e,0,n,t):this.selectDate(e,this.getIdValue(e,null),null),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.clickEventEmitter=function(e){e.preventDefault()},t.prototype.contentClick=function(e,t,n,a){var r=this.getViewNumber(this.currentView()),i=this.getIdValue(e,n);switch(t){case 0:r===this.getViewNumber(this.depth)&&this.getViewNumber(this.start)>=this.getViewNumber(this.depth)?(Cft(this.tableBodyElement),this.currentDate=i,this.effect=Rvt,this.renderMonths(e)):("Gregorian"===this.calendarMode?(this.currentDate.setMonth(i.getMonth()),i.getMonth()>0&&this.currentDate.getMonth()!==i.getMonth()&&this.currentDate.setDate(0),this.currentDate.setFullYear(i.getFullYear())):this.currentDate=i,this.effect=Rvt,Cft(this.tableBodyElement),this.renderMonths(e));break;case 1:if(r===this.getViewNumber(this.depth)&&this.getViewNumber(this.start)>=this.getViewNumber(this.depth))this.selectDate(e,i,null);else{if("Gregorian"===this.calendarMode)this.currentDate.setFullYear(i.getFullYear());else{var o=this.islamicModule.getIslamicDate(i);this.currentDate=this.islamicModule.toGregorian(o.year,o.month,1)}this.effect=Rvt,Cft(this.tableBodyElement),this.renderYears(e)}}},t.prototype.switchView=function(e,t,n,a){switch(e){case 0:Cft(this.tableBodyElement),this.renderMonths(t,null,a),n&&!xpt(this.tableBodyElement.querySelectorAll("."+Pvt)[0])&&this.tableBodyElement.querySelectorAll("."+Pvt)[0].classList.remove(Pvt);break;case 1:Cft(this.tableBodyElement),this.renderYears(t);break;case 2:Cft(this.tableBodyElement),this.renderDecades(t)}},t.prototype.getModuleName=function(){return"calendar"},t.prototype.requiredModules=function(){var e=[];return this&&e.push({args:[this],member:"islamic"}),e},t.prototype.getPersistData=function(){return this.addOnPersist(["value"])},t.prototype.onPropertyChanged=function(e,t,n,a){this.effect="";for(var r=0,i=Object.keys(e);r<i.length;r++){var o=i[r];switch(o){case"enableRtl":e.enableRtl?"calendar"===this.getModuleName()?this.element.classList.add("e-rtl"):this.calendarElement.classList.add("e-rtl"):"calendar"===this.getModuleName()?this.element.classList.remove("e-rtl"):this.calendarElement.classList.remove("e-rtl");break;case"dayHeaderFormat":this.getCultureValues(),("datepicker"!==this.getModuleName()||this.calendarElement)&&this.createContentHeader(),this.adjustLongHeaderSize();break;case"min":case"max":this.rangeValidation(this.min,this.max),"min"===o?this.setProperties({min:this.checkDateValue(new Date(this.checkValue(e.min)))},!0):this.setProperties({max:this.checkDateValue(new Date(this.checkValue(e.max)))},!0),this.setProperties({start:this.currentView()},!0),this.tableBodyElement&&Cft(this.tableBodyElement),this.minMaxUpdate(),n&&this.validateValues(n,a),("datepicker"!==this.getModuleName()||this.calendarElement)&&this.createContentBody(),(this.todayDate<this.min||this.max<this.todayDate)&&this.footer&&this.todayElement?(Cft(this.todayElement),Cft(this.footer),this.todayElement=this.footer=null,this.createContentFooter()):this.footer&&this.todayElement&&this.todayElement.classList.contains("e-disabled")&&(Eft([this.todayElement],Ovt),Cft(this.todayElement),Cft(this.footer),this.todayElement=this.footer=null,this.createContentFooter());break;case"start":case"depth":case"weekNumber":case"firstDayOfWeek":case"weekRule":this.checkView(),("datepicker"!==this.getModuleName()||this.calendarElement)&&(this.createContentHeader(),this.createContentBody());break;case"locale":this.globalize=new aft(this.locale),("datepicker"!==this.getModuleName()||this.calendarElement)&&(this.createContentHeader(),this.createContentBody()),this.l10.setLocale(this.locale),this.updateFooter();break;case"showTodayButton":e.showTodayButton?this.createContentFooter():xpt(this.todayElement)||xpt(this.footer)||(Cft(this.todayElement),Cft(this.footer),this.todayElement=this.footer=void 0),this.setProperties({showTodayButton:e.showTodayButton},!0)}}},t.prototype.validateValues=function(e,t){if(e&&!xpt(t)&&t.length>0){for(var n=this.copyValues(t),a=0;a<n.length;a++){var r=n[a],i="Gregorian"===this.calendarMode?"gregorian":"islamic",o=void 0;o="Gregorian"===this.calendarMode?this.globalize.formatDate(r,{type:"date",skeleton:"yMd"}):this.globalize.formatDate(r,{type:"dateTime",skeleton:"full",calendar:"islamic"});var l={type:"date",skeleton:"yMd",calendar:i},s=this.globalize.formatDate(this.min,l),c={type:"date",skeleton:"yMd",calendar:i},d=this.globalize.formatDate(this.max,c);(+new Date(o)<+new Date(s)||+new Date(o)>+new Date(d))&&(n.splice(a,1),a=-1)}this.setProperties({values:n},!0)}},t.prototype.setValueUpdate=function(){xpt(this.tableBodyElement)||(Cft(this.tableBodyElement),this.setProperties({start:this.currentView()},!0),this.createContentBody())},t.prototype.copyValues=function(e){var t=[];if(!xpt(e)&&e.length>0)for(var n=0;n<e.length;n++)t.push(new Date(+e[n]));return t},t.prototype.titleUpdate=function(e,t){var n,a,r=new aft(this.locale),i="Gregorian"===this.calendarMode?"gregorian":"islamic";switch("Gregorian"===this.calendarMode?(n=r.formatDate(e,{type:"dateTime",skeleton:"yMMMM",calendar:i}),a=r.formatDate(e,{format:null,type:"dateTime",skeleton:"y",calendar:i})):(n=r.formatDate(e,{type:"dateTime",format:"MMMM y",calendar:i}),a=r.formatDate(e,{type:"dateTime",format:"y",calendar:i})),t){case"days":this.headerTitleElement.textContent=this.toCapitalize(n);break;case"months":this.headerTitleElement.textContent=a}},t.prototype.setActiveDescendant=function(){var e,t,n=this.tableBodyElement.querySelector("tr td.e-focused-date"),a=this.tableBodyElement.querySelector("tr td.e-selected"),r="Gregorian"===this.calendarMode?"gregorian":"islamic",i=this.currentView();return t="Month"===i?this.globalize.formatDate(this.currentDate,{type:"date",skeleton:"full",calendar:r}):"Year"===i?"islamic"!==r?this.globalize.formatDate(this.currentDate,{type:"date",skeleton:"yMMMM",calendar:r}):this.globalize.formatDate(this.currentDate,{type:"date",skeleton:"GyMMM",calendar:r}):this.globalize.formatDate(this.currentDate,{format:null,type:"date",skeleton:"y",calendar:r}),(a||n)&&(xpt(a)||a.setAttribute("aria-selected","true"),(n||a).setAttribute("aria-label",t),e=(n||a).getAttribute("id")),e},t.prototype.iconHandler=function(){switch(new Date(this.checkValue(this.currentDate)).setDate(1),this.currentView()){case"Month":this.previousIconHandler(this.compareMonth(new Date(this.checkValue(this.currentDate)),this.min)<1),this.nextIconHandler(this.compareMonth(new Date(this.checkValue(this.currentDate)),this.max)>-1);break;case"Year":this.previousIconHandler(this.compareYear(new Date(this.checkValue(this.currentDate)),this.min)<1),this.nextIconHandler(this.compareYear(new Date(this.checkValue(this.currentDate)),this.max)>-1);break;case"Decade":this.previousIconHandler(this.compareDecade(new Date(this.checkValue(this.currentDate)),this.min)<1),this.nextIconHandler(this.compareDecade(new Date(this.checkValue(this.currentDate)),this.max)>-1)}},t.prototype.destroy=function(){("calendar"===this.getModuleName()&&this.element||this.calendarElement&&this.element)&&Eft([this.element],[_vt]),"calendar"===this.getModuleName()&&this.element&&(wft.remove(this.headerTitleElement,"click",this.navigateTitle),this.todayElement&&wft.remove(this.todayElement,"click",this.todayButtonClick),this.previousIconHandler(!0),this.nextIconHandler(!0),this.keyboardModule.destroy(),this.element.removeAttribute("data-role"),xpt(this.calendarEleCopy.getAttribute("tabindex"))?this.element.removeAttribute("tabindex"):this.element.setAttribute("tabindex",this.tabIndex)),this.element&&(this.element.innerHTML=""),e.prototype.destroy.call(this)},t.prototype.title=function(e){var t=this.getViewNumber(this.currentView());this.effect=Rvt,this.switchView(++t,e)},t.prototype.getViewNumber=function(e){return"Month"===e?0:"Year"===e?1:2},t.prototype.navigateTitle=function(e){e.preventDefault(),this.title(e),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.previous=function(){this.effect="";var e=this.getViewNumber(this.currentView());switch(this.currentView()){case"Month":this.addMonths(this.currentDate,-1),this.switchView(e);break;case"Year":this.addYears(this.currentDate,-1),this.switchView(e);break;case"Decade":this.addYears(this.currentDate,-10),this.switchView(e)}},t.prototype.navigatePrevious=function(e){e.preventDefault(),"Gregorian"===this.calendarMode?this.previous():this.islamicModule.islamicPrevious(),this.triggerNavigate(e),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.next=function(){this.effect="";var e=this.getViewNumber(this.currentView());switch(this.currentView()){case"Month":this.addMonths(this.currentDate,1),this.switchView(e);break;case"Year":this.addYears(this.currentDate,1),this.switchView(e);break;case"Decade":this.addYears(this.currentDate,10),this.switchView(e)}},t.prototype.navigateNext=function(e){e.preventDefault(),"Gregorian"===this.calendarMode?this.next():this.islamicModule.islamicNext(),this.triggerNavigate(e),"calendar"===this.getModuleName()&&this.table.focus()},t.prototype.navigateTo=function(e,t,n){+t>=+this.min&&+t<=+this.max&&(this.currentDate=t),+t<=+this.min&&(this.currentDate=new Date(this.checkValue(this.min))),+t>=+this.max&&(this.currentDate=new Date(this.checkValue(this.max))),this.getViewNumber(this.depth)>=this.getViewNumber(e)&&(this.getViewNumber(this.depth)<=this.getViewNumber(this.start)||this.getViewNumber(this.depth)===this.getViewNumber(e))&&(e=this.depth),this.switchView(this.getViewNumber(e),null,null,n)},t.prototype.currentView=function(){return this.contentElement.classList.contains(Hvt)?"Year":this.contentElement.classList.contains(Dvt)?"Decade":"Month"},t.prototype.getDateVal=function(e,t){return!xpt(t)&&e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()},t.prototype.getCultureObjects=function(e,t){var n=".dates.calendars.gregorian.days.format."+this.dayHeaderFormat.toLowerCase(),a=".dates.calendars.islamic.days.format."+this.dayHeaderFormat.toLowerCase();return"Gregorian"===this.calendarMode?fpt("main."+this.locale+n,e):fpt("main."+this.locale+a,e)},t.prototype.getWeek=function(e){var t=new Date(this.checkValue(e)).valueOf(),n=new Date(e.getFullYear(),0,1).valueOf();return Math.ceil((t-n+Yvt)/Yvt/7)},t.prototype.setStartDate=function(e,t){var n=e.getTimezoneOffset(),a=new Date(e.getTime()+t),r=a.getTimezoneOffset()-n;e.setTime(a.getTime()+6e4*r)},t.prototype.addMonths=function(e,t){if("Gregorian"===this.calendarMode){var n=e.getDate();e.setDate(1),e.setMonth(e.getMonth()+t),e.setDate(Math.min(n,this.getMaxDays(e)))}else{var a=this.islamicModule.getIslamicDate(e);this.currentDate=this.islamicModule.toGregorian(a.year,a.month+t,1)}},t.prototype.addYears=function(e,t){if("Gregorian"===this.calendarMode){var n=e.getDate();e.setDate(1),e.setFullYear(e.getFullYear()+t),e.setDate(Math.min(n,this.getMaxDays(e)))}else{var a=this.islamicModule.getIslamicDate(e);this.currentDate=this.islamicModule.toGregorian(a.year+t,a.month,1)}},t.prototype.getIdValue=function(e,t){var n;n=e?e.currentTarget:t;var a={type:"dateTime",skeleton:"full",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"},r=this.globalize.formatDate(new Date(parseInt(""+n.getAttribute("id"),0)),a),i=this.globalize.parseDate(r,a),o=i.valueOf()-i.valueOf()%1e3;return new Date(o)},t.prototype.adjustLongHeaderSize=function(){Eft([this.element],Fvt),"Wide"===this.dayHeaderFormat&&xft(["calendar"===this.getModuleName()?this.element:this.calendarElement],Fvt)},t.prototype.selectDate=function(e,t,n,a,r){var i=n||e.currentTarget;if(this.isDateSelected=!1,"Decade"===this.currentView())this.setDateDecade(this.currentDate,t.getFullYear());else if("Year"===this.currentView())this.setDateYear(this.currentDate,t);else{if(a&&!this.checkPresentDate(t,r)){var o=this.copyValues(r);!xpt(r)&&o.length>0?(o.push(new Date(this.checkValue(t))),this.setProperties({values:o},!0),this.setProperties({value:r[r.length-1]},!0)):this.setProperties({values:[new Date(this.checkValue(t))]},!0)}else this.setProperties({value:new Date(this.checkValue(t))},!0);this.currentDate=new Date(this.checkValue(t))}var l=Oft(i,"."+_vt);if(xpt(l)&&(l=this.tableBodyElement),a||xpt(l.querySelector("."+zvt))||Eft([l.querySelector("."+zvt)],zvt),a||xpt(l.querySelector("."+Pvt))||Eft([l.querySelector("."+Pvt)],Pvt),a){o=this.copyValues(r);for(var s=Array.prototype.slice.call(this.tableBodyElement.querySelectorAll("td")),c=0;c<s.length;c++){var d=l.querySelectorAll("td."+Pvt)[0],h=l.querySelectorAll("td."+zvt)[0];s[c]===d&&Eft([s[c]],Pvt),s[c]!==h||this.checkPresentDate(new Date(parseInt(h.getAttribute("id").split("_")[0],10)),r)||Eft([s[c]],zvt)}if(i.classList.contains(zvt)){Eft([i],zvt);for(var u=0;u<o.length;u++){var p={format:null,type:"date",skeleton:"short",calendar:"Gregorian"===this.calendarMode?"gregorian":"islamic"};if(this.globalize.formatDate(t,p)===this.globalize.formatDate(o[u],p)){c=o.indexOf(o[u]);o.splice(c,1),xft([i],Pvt)}}this.setProperties({values:o},!0)}else xft([i],zvt)}else xft([i],zvt);this.isDateSelected=!0},t.prototype.checkPresentDate=function(e,t){var n=!1;if(!xpt(t))for(var a=0;a<t.length;a++){var r="Gregorian"===this.calendarMode?"gregorian":"islamic";this.globalize.formatDate(e,{format:null,type:"date",skeleton:"short",calendar:r})===this.globalize.formatDate(t[a],{format:null,type:"date",skeleton:"short",calendar:r})&&(n=!0)}return n},t.prototype.setAriaActiveDescendant=function(){Hft(this.table,{"aria-activedescendant":""+this.setActiveDescendant()})},t.prototype.previousIconHandler=function(e){e?(wft.remove(this.previousIcon,"click",this.navigatePreviousHandler),xft([this.previousIcon],""+Ovt),xft([this.previousIcon],""+Lvt),this.previousIcon.setAttribute("aria-disabled","true")):(wft.add(this.previousIcon,"click",this.navigatePreviousHandler),Eft([this.previousIcon],""+Ovt),Eft([this.previousIcon],""+Lvt),this.previousIcon.setAttribute("aria-disabled","false"))},t.prototype.renderDayCellEvent=function(e){bpt(this.renderDayCellArgs,{name:"renderDayCell"}),this.trigger("renderDayCell",e)},t.prototype.navigatedEvent=function(e){bpt(this.navigatedArgs,{name:"navigated",event:e}),this.trigger("navigated",this.navigatedArgs)},t.prototype.triggerNavigate=function(e){this.navigatedArgs={view:this.currentView(),date:this.currentDate},this.navigatedEvent(e)},t.prototype.nextIconHandler=function(e){e?(wft.remove(this.nextIcon,"click",this.navigateNextHandler),xft([this.nextIcon],Ovt),xft([this.nextIcon],Lvt),this.nextIcon.setAttribute("aria-disabled","true")):(wft.add(this.nextIcon,"click",this.navigateNextHandler),Eft([this.nextIcon],Ovt),Eft([this.nextIcon],Lvt),this.nextIcon.setAttribute("aria-disabled","false"))},t.prototype.compare=function(e,t,n){var a,r,i=t.getFullYear();return a=i,r=0,n&&(a=(i-=i%n)-i%n+n-1),e.getFullYear()>a?r=1:e.getFullYear()<i&&(r=-1),r},t.prototype.isMinMaxRange=function(e){return+e>=+this.min&&+e<=+this.max},t.prototype.isMonthYearRange=function(e){if("Gregorian"===this.calendarMode)return e.getMonth()>=this.min.getMonth()&&e.getFullYear()>=this.min.getFullYear()&&e.getMonth()<=this.max.getMonth()&&e.getFullYear()<=this.max.getFullYear();var t=this.islamicModule.getIslamicDate(e);return t.month>=this.islamicModule.getIslamicDate(new Date(1944,1,18)).month&&t.year>=this.islamicModule.getIslamicDate(new Date(1944,1,18)).year&&t.month<=this.islamicModule.getIslamicDate(new Date(2069,1,16)).month&&t.year<=this.islamicModule.getIslamicDate(new Date(2069,1,16)).year},t.prototype.compareYear=function(e,t){return this.compare(e,t,0)},t.prototype.compareDecade=function(e,t){return this.compare(e,t,10)},t.prototype.shiftArray=function(e,t){return e.slice(t).concat(e.slice(0,t))},t.prototype.addDay=function(e,t,n,a,r){var i=t,o=new Date(+e);if(!xpt(this.tableBodyElement)&&!xpt(n)){for(;this.findNextTD(new Date(+e),i,a,r);)i+=t;var l=new Date(o.setDate(o.getDate()+i));i=+l>+a||+l<+r?i===t?t-t:t:i}e.setDate(e.getDate()+i)},t.prototype.findNextTD=function(e,t,n,a){var r=new Date(e.setDate(e.getDate()+t)),i=[],o=!1;if((!xpt(r)&&r.getMonth())===(!xpt(this.currentDate)&&this.currentDate.getMonth())){i=("Gregorian"===this.calendarMode?this.renderDays(r):this.islamicModule.islamicRenderDays(this.currentDate,r)).filter(function(e){return e.classList.contains(Ovt)})}else i=this.tableBodyElement.querySelectorAll("td."+Ovt);if(+r<=+n&&+r>=+a&&i.length)for(var l=0;l<i.length&&!(o=+r===+new Date(parseInt(i[l].id,0)));l++);return o},t.prototype.getMaxDays=function(e){var t,n=new Date(this.checkValue(e));t=28;for(var a=n.getMonth();n.getMonth()===a;)++t,n.setDate(t);return t-1},t.prototype.setDateDecade=function(e,t){e.setFullYear(t),this.setProperties({value:new Date(this.checkValue(e))},!0)},t.prototype.setDateYear=function(e,t){e.setFullYear(t.getFullYear(),t.getMonth(),e.getDate()),t.getMonth()!==e.getMonth()&&(e.setDate(0),this.currentDate=new Date(this.checkValue(t))),this.setProperties({value:new Date(this.checkValue(e))},!0)},t.prototype.compareMonth=function(e,t){return e.getFullYear()>t.getFullYear()?1:e.getFullYear()<t.getFullYear()?-1:e.getMonth()===t.getMonth()?0:e.getMonth()>t.getMonth()?1:-1},t.prototype.checkValue=function(e){return e instanceof Date?e.toUTCString():""+e},t.prototype.checkView=function(){"Decade"!==this.start&&"Year"!==this.start&&this.setProperties({start:"Month"},!0),"Decade"!==this.depth&&"Year"!==this.depth&&this.setProperties({depth:"Month"},!0),this.getViewNumber(this.depth)>this.getViewNumber(this.start)&&this.setProperties({depth:"Month"},!0)},t.prototype.getDate=function(e,t){return t&&(e=new Date(e.toLocaleString("en-US",{timeZone:t}))),e},Mvt([Kft(new Date(1900,0,1))],t.prototype,"min",void 0),Mvt([Kft(!0)],t.prototype,"enabled",void 0),Mvt([Kft(null)],t.prototype,"cssClass",void 0),Mvt([Kft(new Date(2099,11,31))],t.prototype,"max",void 0),Mvt([Kft(null)],t.prototype,"firstDayOfWeek",void 0),Mvt([Kft("Gregorian")],t.prototype,"calendarMode",void 0),Mvt([Kft("Month")],t.prototype,"start",void 0),Mvt([Kft("Month")],t.prototype,"depth",void 0),Mvt([Kft(!1)],t.prototype,"weekNumber",void 0),Mvt([Kft("FirstDay")],t.prototype,"weekRule",void 0),Mvt([Kft(!0)],t.prototype,"showTodayButton",void 0),Mvt([Kft("Short")],t.prototype,"dayHeaderFormat",void 0),Mvt([Kft(!1)],t.prototype,"enablePersistence",void 0),Mvt([Kft(null)],t.prototype,"keyConfigs",void 0),Mvt([Kft(null)],t.prototype,"serverTimezoneOffset",void 0),Mvt([Jft()],t.prototype,"created",void 0),Mvt([Jft()],t.prototype,"destroyed",void 0),Mvt([Jft()],t.prototype,"navigated",void 0),Mvt([Jft()],t.prototype,"renderDayCell",void 0),t=Mvt([$ft],t)}(Smt);!function(e){function t(t,n){return e.call(this,t,n)||this}kvt(t,e),t.prototype.render=function(){if("Islamic"===this.calendarMode&&void 0===this.islamicModule&&Spt("Requires the injectable Islamic modules to render Calendar in Islamic mode"),this.isMultiSelection&&"object"==typeof this.values&&!xpt(this.values)&&this.values.length>0){for(var t=[],n=[],a=0;a<this.values.length;a++)-1===t.indexOf(+this.values[a])&&(t.push(+this.values[a]),n.push(this.values[a]));this.setProperties({values:n},!0);for(var r=0;r<this.values.length;r++)if(!this.checkDateValue(this.values[r]))if("string"==typeof this.values[r]&&this.checkDateValue(new Date(this.checkValue(this.values[r])))){var i=new Date(this.checkValue(this.values[r]));this.values.splice(r,1),this.values.splice(r,0,i)}else this.values.splice(r,1);this.setProperties({value:this.values[this.values.length-1]},!0),this.previousValues=this.values.length}if(this.validateDate(),this.minMaxUpdate(),"calendar"===this.getModuleName()&&(this.setEnable(this.enabled),this.setClass(this.cssClass)),e.prototype.render.call(this),"calendar"===this.getModuleName()){var o=Oft(this.element,"form");o&&wft.add(o,"reset",this.formResetHandler.bind(this)),this.setTimeZone(this.serverTimezoneOffset)}this.renderComplete()},t.prototype.setEnable=function(e){e?Eft([this.element],Ovt):xft([this.element],Ovt)},t.prototype.setClass=function(e,t){xpt(t)||(t=t.replace(/\s+/g," ").trim()),xpt(e)||(e=e.replace(/\s+/g," ").trim()),xpt(t)||""===t||Eft([this.element],t.split(" ")),xpt(e)||xft([this.element],e.split(" "))},t.prototype.isDayLightSaving=function(){var e=new Date(this.value.getFullYear(),6,1).getTimezoneOffset(),t=new Date(this.value.getFullYear(),0,1).getTimezoneOffset();return this.value.getTimezoneOffset()<Math.max(t,e)},t.prototype.setTimeZone=function(e){if(!xpt(this.serverTimezoneOffset)&&this.value){var t=e+(new Date).getTimezoneOffset()/60;t=this.isDayLightSaving()?t--:t,this.value=new Date(this.value.getTime()+60*t*60*1e3)}},t.prototype.formResetHandler=function(){this.setProperties({value:null},!0)},t.prototype.validateDate=function(){"string"==typeof this.value&&this.setProperties({value:this.checkDateValue(new Date(this.checkValue(this.value)))},!0),e.prototype.validateDate.call(this,this.value),!xpt(this.value)&&this.min<=this.max&&this.value>=this.min&&this.value<=this.max&&(this.currentDate=new Date(this.checkValue(this.value))),isNaN(+this.value)&&this.setProperties({value:null},!0)},t.prototype.minMaxUpdate=function(){"calendar"===this.getModuleName()&&(!xpt(this.value)&&this.value<=this.min&&this.min<=this.max?(this.setProperties({value:this.min},!0),this.changedArgs={value:this.value}):!xpt(this.value)&&this.value>=this.max&&this.min<=this.max&&(this.setProperties({value:this.max},!0),this.changedArgs={value:this.value})),"calendar"===this.getModuleName()||xpt(this.value)?e.prototype.minMaxUpdate.call(this,this.value):!xpt(this.value)&&this.value<this.min&&this.min<=this.max?e.prototype.minMaxUpdate.call(this,this.min):!xpt(this.value)&&this.value>this.max&&this.min<=this.max&&e.prototype.minMaxUpdate.call(this,this.max)},t.prototype.generateTodayVal=function(t){var n=new Date;return xpt(this.timezone)||(n=e.prototype.getDate.call(this,n,this.timezone)),t&&xpt(this.timezone)?(n.setHours(t.getHours()),n.setMinutes(t.getMinutes()),n.setSeconds(t.getSeconds()),n.setMilliseconds(t.getMilliseconds())):n=new Date(n.getFullYear(),n.getMonth(),n.getDate(),0,0,0,0),n},t.prototype.todayButtonClick=function(t){if(this.showTodayButton){var n=this.generateTodayVal(this.value);if(this.setProperties({value:n},!0),this.isTodayClicked=!0,this.todayButtonEvent=t,this.isMultiSelection){var a=this.copyValues(this.values);e.prototype.checkPresentDate.call(this,n,this.values)||(a.push(n),this.setProperties({values:a}))}e.prototype.todayButtonClick.call(this,t,new Date(+this.value))}},t.prototype.keyActionHandle=function(t){e.prototype.keyActionHandle.call(this,t,this.value,this.isMultiSelection)},t.prototype.preRender=function(){var t=this;this.changeHandler=function(e){t.triggerChange(e)},this.checkView(),e.prototype.preRender.call(this,this.value)},t.prototype.createContent=function(){this.previousDate=this.value,this.previousDateTime=this.value,e.prototype.createContent.call(this)},t.prototype.minMaxDate=function(t){return e.prototype.minMaxDate.call(this,t)},t.prototype.renderMonths=function(t,n,a){e.prototype.renderMonths.call(this,t,this.value,a)},t.prototype.renderDays=function(t,n,a,r,i){var o=e.prototype.renderDays.call(this,t,this.value,this.isMultiSelection,this.values,i);return this.isMultiSelection&&e.prototype.validateValues.call(this,this.isMultiSelection,this.values),o},t.prototype.renderYears=function(t){"Gregorian"===this.calendarMode?e.prototype.renderYears.call(this,t,this.value):this.islamicModule.islamicRenderYears(t,this.value)},t.prototype.renderDecades=function(t){"Gregorian"===this.calendarMode?e.prototype.renderDecades.call(this,t,this.value):this.islamicModule.islamicRenderDecade(t,this.value)},t.prototype.renderTemplate=function(t,n,a,r){"Gregorian"===this.calendarMode?e.prototype.renderTemplate.call(this,t,n,a,r,this.value):this.islamicModule.islamicRenderTemplate(t,n,a,r,this.value),this.changedArgs={value:this.value,values:this.values},this.changeHandler()},t.prototype.clickHandler=function(t){var n=t.currentTarget;if(this.isPopupClicked=!0,n.classList.contains(Svt))if(this.isMultiSelection){var a=this.copyValues(this.values);a.push(this.getIdValue(t,null)),this.setProperties({values:a},!0),this.setProperties({value:this.values[this.values.length-1]},!0)}else this.setProperties({value:this.getIdValue(t,null)},!0);var r=this.currentView();e.prototype.clickHandler.call(this,t,this.value),this.isMultiSelection&&this.currentDate!==this.value&&!xpt(this.tableBodyElement.querySelectorAll("."+Pvt)[0])&&"Year"===r&&this.tableBodyElement.querySelectorAll("."+Pvt)[0].classList.remove(Pvt)},t.prototype.switchView=function(t,n,a,r){e.prototype.switchView.call(this,t,n,this.isMultiSelection,r)},t.prototype.getModuleName=function(){return e.prototype.getModuleName.call(this),"calendar"},t.prototype.getPersistData=function(){e.prototype.getPersistData.call(this);return this.addOnPersist(["value","values"])},t.prototype.onPropertyChanged=function(t,n){this.effect="",this.rangeValidation(this.min,this.max);for(var a=0,r=Object.keys(t);a<r.length;a++){switch(r[a]){case"value":this.isDateSelected&&("string"==typeof t.value?this.setProperties({value:new Date(this.checkValue(t.value))},!0):t.value=new Date(this.checkValue(t.value)),isNaN(+this.value)&&this.setProperties({value:n.value},!0),this.update());break;case"values":if(this.isDateSelected){if("string"==typeof t.values||"number"==typeof t.values)this.setProperties({values:null},!0);else{for(var i=this.copyValues(this.values),o=0;o<i.length;o++){var l=i[o];this.checkDateValue(l)&&!e.prototype.checkPresentDate.call(this,l,i)&&i.push(l)}this.setProperties({values:i},!0),this.values.length>0&&this.setProperties({value:t.values[t.values.length-1]},!0)}this.validateValues(this.isMultiSelection,this.values),this.update()}break;case"isMultiSelection":this.isDateSelected&&(this.setProperties({isMultiSelection:t.isMultiSelection},!0),this.update());break;case"enabled":this.setEnable(this.enabled);break;case"cssClass":"calendar"===this.getModuleName()&&this.setClass(t.cssClass,n.cssClass);break;default:e.prototype.onPropertyChanged.call(this,t,n,this.isMultiSelection,this.values)}}this.preventChange=this.isAngular&&this.preventChange?!this.preventChange:this.preventChange},t.prototype.destroy=function(){if(e.prototype.destroy.call(this),"calendar"===this.getModuleName()){var t=Oft(this.element,"form");t&&wft.remove(t,"reset",this.formResetHandler.bind(this))}},t.prototype.navigateTo=function(t,n,a){this.minMaxUpdate(),e.prototype.navigateTo.call(this,t,n,a)},t.prototype.currentView=function(){return e.prototype.currentView.call(this)},t.prototype.addDate=function(t){if("string"!=typeof t&&"number"!=typeof t){var n=this.copyValues(this.values);if("object"==typeof t&&t.length>0)for(var a=t,r=0;r<a.length;r++)this.checkDateValue(a[r])&&!e.prototype.checkPresentDate.call(this,a[r],n)&&(!xpt(n)&&n.length>0?n.push(a[r]):n=[new Date(+a[r])]);else this.checkDateValue(t)&&!e.prototype.checkPresentDate.call(this,t,n)&&(!xpt(n)&&n.length>0?n.push(t):n=[new Date(+t)]);this.setProperties({values:n},!0),this.isMultiSelection&&this.setProperties({value:this.values[this.values.length-1]},!0),this.validateValues(this.isMultiSelection,n),this.update(),this.changedArgs={value:this.value,values:this.values},this.changeHandler()}},t.prototype.removeDate=function(e){if("string"!=typeof e&&"number"!=typeof e&&!xpt(this.values)&&this.values.length>0){var t=this.copyValues(this.values);if("object"==typeof e&&e.length>0)for(var n=e,a=0;a<n.length;a++)for(var r=0;r<t.length;r++)+t[r]===+n[a]&&t.splice(r,1);else for(r=0;r<t.length;r++)+t[r]===+e&&t.splice(r,1);this.setProperties({values:t},!1),this.update(),this.isMultiSelection&&this.setProperties({value:this.values[this.values.length-1]},!0),this.changedArgs={value:this.value,values:this.values},this.changeHandler()}},t.prototype.setTodayDate=function(t){var n=new Date(+t);this.setProperties({value:n},!0),e.prototype.todayButtonClick.call(this,null,n,!0)},t.prototype.update=function(){this.validateDate(),this.minMaxUpdate(),e.prototype.setValueUpdate.call(this)},t.prototype.selectDate=function(t,n,a){e.prototype.selectDate.call(this,t,n,a,this.isMultiSelection,this.values),this.isMultiSelection&&!xpt(this.values)&&this.values.length>0&&this.setProperties({value:this.values[this.values.length-1]},!0),this.changedArgs={value:this.value,values:this.values},this.changeHandler(t)},t.prototype.changeEvent=function(e){((this.value&&this.value.valueOf())!==(this.previousDate&&+this.previousDate.valueOf())||this.isMultiSelection)&&(this.isAngular&&this.preventChange?this.preventChange=!1:this.trigger("change",this.changedArgs),this.previousDate=new Date(+this.value))},t.prototype.triggerChange=function(e){!xpt(this.todayButtonEvent)&&this.isTodayClicked&&(e=this.todayButtonEvent,this.isTodayClicked=!1),this.changedArgs.event=e||null,this.changedArgs.isInteracted=!xpt(e),xpt(this.value)||this.setProperties({value:this.value},!0),this.isMultiSelection||+this.value===Number.NaN||+this.value===+this.previousDate&&(null!=this.previousDate||isNaN(+this.value))?xpt(this.values)||this.previousValues===this.values.length||(this.changeEvent(e),this.previousValues=this.values.length):this.changeEvent(e)},Mvt([Kft(null)],t.prototype,"value",void 0),Mvt([Kft(null)],t.prototype,"values",void 0),Mvt([Kft(!1)],t.prototype,"isMultiSelection",void 0),Mvt([Jft()],t.prototype,"change",void 0),t=Mvt([$ft],t)}(qvt);var Uvt,Gvt,Kvt=!1;function Qvt(e,t,n,a,r){if(mvt=void 0,mvt=r,Kvt=!!a,!e)return{left:0,top:0};t||(t="left"),n||(n="top"),gvt=e.ownerDocument,vvt=e;return function(e,t,n){switch(fvt=vvt.getBoundingClientRect(),t+e){case"topcenter":Xvt(ogt(),n),Jvt(agt(),n);break;case"topright":Xvt(igt(),n),Jvt(agt(),n);break;case"centercenter":Xvt(ogt(),n),Jvt(ngt(),n);break;case"centerright":Xvt(igt(),n),Jvt(ngt(),n);break;case"centerleft":Xvt(rgt(),n),Jvt(ngt(),n);break;case"bottomcenter":Xvt(ogt(),n),Jvt(tgt(),n);break;case"bottomright":Xvt(igt(),n),Jvt(tgt(),n);break;case"bottomleft":Xvt(rgt(),n),Jvt(tgt(),n);break;default:Xvt(rgt(),n),Jvt(agt(),n)}return n}(t.toLowerCase(),n.toLowerCase(),{left:0,top:0})}function Xvt(e,t){t.left=e}function Jvt(e,t){t.top=e}function $vt(){return gvt.documentElement.scrollTop||gvt.body.scrollTop}function egt(){return gvt.documentElement.scrollLeft||gvt.body.scrollLeft}function tgt(){return Kvt?fvt.bottom:fvt.bottom+$vt()}function ngt(){return agt()+fvt.height/2}function agt(){return Kvt?fvt.top:fvt.top+$vt()}function rgt(){return fvt.left+egt()}function igt(){var e=vvt&&vvt.classList.contains("e-date-range-wrapper")?mvt?mvt.width:0:mvt&&fvt.width>=mvt.width?mvt.width:0;return fvt.right+egt()-e}function ogt(){return rgt()+fvt.width/2}function lgt(e,t,n,a,r,i,o,l,s){if(void 0===o&&(o=null),void 0===l&&(l={X:!0,Y:!0}),t&&e&&r&&i&&(l.X||l.Y)){var c,d={TL:null,TR:null,BL:null,BR:null},h={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(e).display){var u=e.style.visibility;e.style.visibility="hidden",e.style.display="block",c=e.getBoundingClientRect(),e.style.removeProperty("display"),e.style.visibility=u}else c=e.getBoundingClientRect();var p={posX:r,posY:i,offsetX:n,offsetY:a,position:{left:0,top:0}};Gvt=o,Uvt=t.ownerDocument,function(e,t,n,a,r){n.position=Qvt(e,n.posX,n.posY,a,r),t.TL=Qvt(e,"left","top",a,r),t.TR=Qvt(e,"right","top",a,r),t.BR=Qvt(e,"left","bottom",a,r),t.BL=Qvt(e,"right","bottom",a,r)}(t,d,p,s,c),sgt(h,p,c),l.X&&dgt(t,h,d,p,c,!0),l.Y&&d.TL.top>-1&&hgt(t,h,d,p,c,!0),function(e,t,n){var a=0,r=0;if(null!=e.offsetParent&&("absolute"===getComputedStyle(e.offsetParent).position||"relative"===getComputedStyle(e.offsetParent).position)){var i=Qvt(e.offsetParent,"left","top",!1,n);a=i.left,r=i.top}e.style.top=t.position.top+t.offsetY-r+"px",e.style.left=t.position.left+t.offsetX-a+"px"}(e,p,c)}}function sgt(e,t,n){e.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},e.TR={top:e.TL.top,left:e.TL.left+n.width},e.BL={top:e.TL.top+n.height,left:e.TL.left},e.BR={top:e.TL.top+n.height,left:e.TL.left+n.width}}function cgt(e,t){var n=!1,a=!1;return e-Egt()<wgt()&&(n=!0),t>ygt()&&(a=!0),{leftSide:n,rightSide:a}}function dgt(e,t,n,a,r,i){var o=cgt(t.TL.left,t.TR.left);n.TL.left-Egt()<=wgt()&&(o.leftSide=!1),n.TR.left>ygt()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&("right"===a.posX?a.posX="left":a.posX="right",a.offsetX=a.offsetX+r.width,a.offsetX=-1*a.offsetX,a.position=Qvt(e,a.posX,a.posY,!1),sgt(t,a,r),i&&dgt(e,t,n,a,r,!1))}function hgt(e,t,n,a,r,i){var o=ugt(t.TL.top,t.BL.top);n.TL.top-xgt()<=ggt()&&(o.topSide=!1),n.BL.top>=bgt()&&e.getBoundingClientRect().bottom<window.innerHeight&&(o.bottomSide=!1),(o.topSide&&!o.bottomSide||!o.topSide&&o.bottomSide)&&("top"===a.posY?a.posY="bottom":a.posY="top",a.offsetY=a.offsetY+r.height,a.offsetY=-1*a.offsetY,a.position=Qvt(e,a.posX,a.posY,!1,r),sgt(t,a,r),i&&hgt(e,t,n,a,r,!1))}function ugt(e,t){var n=!1,a=!1;return e-xgt()<ggt()&&(n=!0),t>bgt()&&(a=!0),{topSide:n,bottomSide:a}}function pgt(){return Gvt.getBoundingClientRect().width}function fgt(){return Gvt.getBoundingClientRect().height}function mgt(){return Gvt.getBoundingClientRect().left}function vgt(){return Gvt.getBoundingClientRect().top}function ggt(){return Gvt?vgt():0}function wgt(){return Gvt?mgt():0}function ygt(){return Gvt?Egt()+mgt()+pgt():Egt()+Mgt()}function bgt(){return Gvt?xgt()+vgt()+fgt():xgt()+kgt()}function xgt(){return Uvt.documentElement.scrollTop||Uvt.body.scrollTop}function Egt(){return Uvt.documentElement.scrollLeft||Uvt.body.scrollLeft}function kgt(){return window.innerHeight}function Mgt(){var e=window.innerWidth,t=document.documentElement.getBoundingClientRect();return e-(e-(xpt(document.documentElement)?0:t.width))}var Sgt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Agt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},_gt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Sgt(t,e),Agt([Kft("left")],t.prototype,"X",void 0),Agt([Kft("top")],t.prototype,"Y",void 0),t}(fmt),Cgt="e-popup",Zgt="e-rtl",Hgt="e-popup-open",Igt="e-popup-close",Dgt=function(e){function t(t,n){return e.call(this,n,t)||this}return Sgt(t,e),t.prototype.onPropertyChanged=function(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){switch(a[n]){case"width":Lft(this.element,{width:Apt(e.width)});break;case"height":Lft(this.element,{height:Apt(e.height)});break;case"zIndex":Lft(this.element,{zIndex:e.zIndex});break;case"enableRtl":this.setEnableRtl();break;case"position":case"relateTo":this.refreshPosition();break;case"offsetX":var r=e.offsetX-t.offsetX;this.element.style.left=(parseInt(this.element.style.left,10)+r).toString()+"px";break;case"offsetY":var i=e.offsetY-t.offsetY;this.element.style.top=(parseInt(this.element.style.top,10)+i).toString()+"px";break;case"content":this.setContent();break;case"actionOnScroll":"none"!==e.actionOnScroll?this.wireScrollEvents():this.unwireScrollEvents()}}},t.prototype.getModuleName=function(){return"popup"},t.prototype.resolveCollision=function(){this.checkCollision()},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.prototype.destroy=function(){this.element.classList.remove(Cgt,Zgt,Hgt,Igt),this.element.classList.contains("e-popup-open")&&this.unwireEvents(),e.prototype.destroy.call(this)},t.prototype.render=function(){this.element.classList.add(Cgt);var e={};1e3!==this.zIndex&&(e.zIndex=this.zIndex),"auto"!==this.width&&(e.width=Apt(this.width)),"auto"!==this.height&&(e.height=Apt(this.height)),Lft(this.element,e),this.fixedParent=!1,this.setEnableRtl(),this.setContent()},t.prototype.wireEvents=function(){gft.isDevice&&wft.add(window,"orientationchange",this.orientationOnChange,this),"none"!==this.actionOnScroll&&this.wireScrollEvents()},t.prototype.wireScrollEvents=function(){if(this.getRelateToElement())for(var e=0,t=this.getScrollableParent(this.getRelateToElement());e<t.length;e++){var n=t[e];wft.add(n,"scroll",this.scrollRefresh,this)}},t.prototype.unwireEvents=function(){gft.isDevice&&wft.remove(window,"orientationchange",this.orientationOnChange),"none"!==this.actionOnScroll&&this.unwireScrollEvents()},t.prototype.unwireScrollEvents=function(){if(this.getRelateToElement())for(var e=0,t=this.getScrollableParent(this.getRelateToElement());e<t.length;e++){var n=t[e];wft.remove(n,"scroll",this.scrollRefresh)}},t.prototype.getRelateToElement=function(){var e=""===this.relateTo||xpt(this.relateTo)?document.body:this.relateTo;return this.setProperties({relateTo:e},!0),"string"==typeof this.relateTo?document.querySelector(this.relateTo):this.relateTo},t.prototype.scrollRefresh=function(e){if("reposition"===this.actionOnScroll?xpt(this.element)||this.element.offsetParent===e.target||this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&null==e.target.parentElement||this.refreshPosition():"hide"===this.actionOnScroll&&this.hide(),"none"!==this.actionOnScroll&&this.getRelateToElement()){var t=this.isElementOnViewport(this.getRelateToElement(),e.target);t||this.targetInvisibleStatus?t&&(this.targetInvisibleStatus=!1):(this.trigger("targetExitViewport"),this.targetInvisibleStatus=!0)}},t.prototype.isElementOnViewport=function(e,t){for(var n=this.getScrollableParent(e),a=0;a<n.length;a++)if(!this.isElementVisible(e,n[a]))return!1;return!0},t.prototype.isElementVisible=function(e,t){var n=this.checkGetBoundingClientRect(e);if(!n.height||!n.width)return!1;if(xpt(this.checkGetBoundingClientRect(t))){var a=window,r={top:a.scrollY,left:a.scrollX,right:a.scrollX+a.outerWidth,bottom:a.scrollY+a.outerHeight},i=Qvt(e),o={top:i.top,left:i.left,right:i.left+n.width,bottom:i.top+n.height},l={top:r.bottom-o.top,left:r.right-o.left,bottom:o.bottom-r.top,right:o.right-r.left};return l.top>0&&l.left>0&&l.right>0&&l.bottom>0}var s=t.getBoundingClientRect();return!(n.bottom<s.top||n.bottom>s.bottom||n.right>s.right||n.left<s.left)},t.prototype.preRender=function(){},t.prototype.setEnableRtl=function(){this.reposition(),this.enableRtl?this.element.classList.add(Zgt):this.element.classList.remove(Zgt)},t.prototype.setContent=function(){if(!xpt(this.content))if(this.element.innerHTML="","string"==typeof this.content)this.element.textContent=this.content;else{var e=this.getRelateToElement(),t=this.content.props;e.classList.contains("e-dropdown-btn")&&!xpt(t)||this.element.appendChild(this.content)}},t.prototype.orientationOnChange=function(){var e=this;setTimeout(function(){e.refreshPosition()},200)},t.prototype.refreshPosition=function(e,t){xpt(e)||this.checkFixedParent(e),this.reposition(),t||this.checkCollision()},t.prototype.reposition=function(){var e,t,n=this.getRelateToElement();if("number"==typeof this.position.X&&"number"==typeof this.position.Y)e={left:this.position.X,top:this.position.Y};else if("string"==typeof this.position.X&&"number"==typeof this.position.Y||"number"==typeof this.position.X&&"string"==typeof this.position.Y){var a=void 0,r=this.element.style.display;this.element.style.display="block",this.element.classList.contains("e-dlg-modal")&&(a=this.element.parentElement.style.display,this.element.parentElement.style.display="block"),t=this.getAnchorPosition(n,this.element,this.position,this.offsetX,this.offsetY),e="string"==typeof this.position.X?{left:t.left,top:this.position.Y}:{left:this.position.X,top:t.top},this.element.style.display=r,this.element.classList.contains("e-dlg-modal")&&(this.element.parentElement.style.display=a)}else if(n){r=this.element.style.display;this.element.style.display="block",e=this.getAnchorPosition(n,this.element,this.position,this.offsetX,this.offsetY),this.element.style.display=r}else e={left:0,top:0};xpt(e)||(this.element.style.left=e.left+"px",this.element.style.top=e.top+"px")},t.prototype.checkGetBoundingClientRect=function(e){try{return e.getBoundingClientRect()}catch(e){return null}},t.prototype.getAnchorPosition=function(e,t,n,a,r){var i=this.checkGetBoundingClientRect(t),o=this.checkGetBoundingClientRect(e);if(xpt(i)||xpt(o))return null;var l=e,s={left:0,top:0};switch(t.offsetParent&&"BODY"===t.offsetParent.tagName&&"BODY"===e.tagName?s=Qvt(e):(t.classList.contains("e-dlg-modal")&&"BODY"!==l.tagName&&(t=t.parentElement),s=function(e,t){var n=!1,a={left:0,top:0},r=e;if(!e||!t)return a;for(xpt(t.offsetParent)&&"fixed"===t.style.position&&(n=!0);(t.offsetParent||n)&&e&&t.offsetParent!==e;)a.left+=e.offsetLeft,a.top+=e.offsetTop,e=e.offsetParent;for(e=r;(t.offsetParent||n)&&e&&t.offsetParent!==e;)a.left-=e.scrollLeft,a.top-=e.scrollTop,e=e.parentElement;return a}(l,t)),n.X){default:case"left":break;case"center":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.left+=window.innerWidth/2-i.width/2:"container"===this.targetType?s.left+=o.width/2-i.width/2:s.left+=o.width/2;break;case"right":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.left+=window.innerWidth-i.width:"container"===this.targetType?s.left+=o.width-i.width:s.left+=o.width}switch(n.Y){default:case"top":break;case"center":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.top+=window.innerHeight/2-i.height/2:"container"===this.targetType?s.top+=o.height/2-i.height/2:s.top+=o.height/2;break;case"bottom":t.classList.contains("e-dlg-modal")&&"BODY"===l.tagName&&"container"===this.targetType?s.top+=window.innerHeight-i.height:"container"===this.targetType?s.top+=o.height-i.height:s.top+=o.height}return s.left+=a,s.top+=r,s},t.prototype.callFlip=function(e){var t=this.getRelateToElement();lgt(this.element,t,this.offsetX,this.offsetY,this.position.X,this.position.Y,this.viewPortElement,e,this.fixedParent)},t.prototype.callFit=function(e){if(0!==function(e,t,n,a){void 0===t&&(t=null);var r=Qvt(e,"left","top");n&&(r.left=n),a&&(r.top=a);var i=[];Gvt=t,Uvt=e.ownerDocument;var o=e.getBoundingClientRect(),l=r.top,s=r.left,c=r.left+o.width,d=ugt(l,r.top+o.height),h=cgt(s,c);return d.topSide&&i.push("top"),h.rightSide&&i.push("right"),h.leftSide&&i.push("left"),d.bottomSide&&i.push("bottom"),i}(this.element,this.viewPortElement).length)if(xpt(this.viewPortElement)){var t=function(e,t,n,a){if(void 0===t&&(t=null),void 0===n&&(n={X:!1,Y:!1}),!n.Y&&!n.X)return{left:0,top:0};var r=e.getBoundingClientRect();if(Gvt=t,Uvt=e.ownerDocument,a||(a=Qvt(e,"left","top")),n.X){var i=Gvt?pgt():Mgt(),o=wgt(),l=ygt(),s=o-a.left,c=a.left+r.width-l;r.width>i?a.left=s>0&&c<=0?l-r.width:c>0&&s<=0?o:s>c?l-r.width:o:s>0?a.left+=s:c>0&&(a.left-=c)}if(n.Y){var d=Gvt?fgt():kgt(),h=ggt(),u=bgt(),p=h-a.top,f=a.top+r.height-u;r.height>d?a.top=p>0&&f<=0?u-r.height:f>0&&p<=0?h:p>f?u-r.height:h:p>0?a.top+=p:f>0&&(a.top-=f)}return a}(this.element,this.viewPortElement,e);e.X&&(this.element.style.left=t.left+"px"),e.Y&&(this.element.style.top=t.top+"px")}else{var n=this.checkGetBoundingClientRect(this.element),a=this.checkGetBoundingClientRect(this.viewPortElement);if(xpt(n)||xpt(a))return null;e&&!0===e.Y&&(a.top>n.top?this.element.style.top="0px":a.bottom<n.bottom&&(this.element.style.top=parseInt(this.element.style.top,10)-(n.bottom-a.bottom)+"px")),e&&!0===e.X&&(a.right<n.right?this.element.style.left=parseInt(this.element.style.left,10)-(n.right-a.right)+"px":a.left>n.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(a.left-n.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,t=this.collision.Y;"none"===e&&"none"===t||("flip"===e&&"flip"===t?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===t?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===t&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===t&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,t){var n=this;if(this.wireEvents(),1e3===this.zIndex||!xpt(t)){var a=xpt(t)?this.element:t;this.zIndex=function(e){var t=e.parentElement,n=[];for(;t&&"BODY"!==t.tagName;){var a=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==a&&"static"!==r&&n.push(a),t=t.parentElement}for(var i=[],o=0;o<document.body.children.length;o++)if(!e.isEqualNode(document.body.children[o])){a=document.defaultView.getComputedStyle(document.body.children[o],null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(document.body.children[o],null).getPropertyValue("position");"auto"!==a&&"static"!==r&&i.push(a)}i.push("999");var l=[];if(!xpt(e.parentElement)&&"BODY"!==e.parentElement.tagName){var s=[].slice.call(e.parentElement.children);for(o=0;o<s.length;o++)if(!e.isEqualNode(s[o])){a=document.defaultView.getComputedStyle(s[o],null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(s[o],null).getPropertyValue("position");"auto"!==a&&"static"!==r&&l.push(a)}}var c=n.concat(i,l),d=Math.max.apply(Math,c)+1;return d>2147483647?2147483647:d}(a),Lft(this.element,{zIndex:this.zIndex})}e=xpt(e)||"object"!=typeof e?this.showAnimation:e,"none"===this.collision.X&&"none"===this.collision.Y||(Eft([this.element],Igt),xft([this.element],Hgt),this.checkCollision(),Eft([this.element],Hgt),xft([this.element],Igt)),xpt(e)?(Eft([this.element],Igt),xft([this.element],Hgt),this.trigger("open")):(e.begin=function(){n.isDestroyed||(Eft([n.element],Igt),xft([n.element],Hgt))},e.end=function(){n.isDestroyed||n.trigger("open")},new imt(e).animate(this.element))},t.prototype.hide=function(e){var t=this;e=xpt(e)||"object"!=typeof e?this.hideAnimation:e,xpt(e)?(Eft([this.element],Hgt),xft([this.element],Igt),this.trigger("close")):(e.end=function(){t.isDestroyed||(Eft([t.element],Hgt),xft([t.element],Igt),t.trigger("close"))},new imt(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function(e,t){var n=getComputedStyle(e),a=[],r=/(auto|scroll)/,i=e.parentElement;for(;i&&"HTML"!==i.tagName;){var o=getComputedStyle(i);"absolute"===n.position&&"static"===o.position||!r.test(o.overflow+o.overflowY+o.overflowX)||a.push(i),i=i.parentElement}t||a.push(document);return a}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var t=e.parentElement;t&&"HTML"!==t.tagName;){var n=getComputedStyle(t);"fixed"===n.position&&!xpt(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top)?Apt(window.scrollY-parseInt(this.element.style.top)):Apt(parseInt(this.element.style.top)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),t=t.parentElement,!xpt(this.element)&&xpt(this.element.offsetParent)&&"fixed"===n.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},Agt([Kft("auto")],t.prototype,"height",void 0),Agt([Kft("auto")],t.prototype,"width",void 0),Agt([Kft(null)],t.prototype,"content",void 0),Agt([Kft("container")],t.prototype,"targetType",void 0),Agt([Kft(null)],t.prototype,"viewPortElement",void 0),Agt([Kft({X:"none",Y:"none"})],t.prototype,"collision",void 0),Agt([Kft("")],t.prototype,"relateTo",void 0),Agt([Qft({},_gt)],t.prototype,"position",void 0),Agt([Kft(0)],t.prototype,"offsetX",void 0),Agt([Kft(0)],t.prototype,"offsetY",void 0),Agt([Kft(1e3)],t.prototype,"zIndex",void 0),Agt([Kft(!1)],t.prototype,"enableRtl",void 0),Agt([Kft("reposition")],t.prototype,"actionOnScroll",void 0),Agt([Kft(null)],t.prototype,"showAnimation",void 0),Agt([Kft(null)],t.prototype,"hideAnimation",void 0),Agt([Jft()],t.prototype,"open",void 0),Agt([Jft()],t.prototype,"close",void 0),Agt([Jft()],t.prototype,"targetExitViewport",void 0),t=Agt([$ft],t)}(Smt);function Ngt(e){for(var t,n=e.childNodes,a=0;a<n.length;a++)if(3===(t=n[a]).nodeType)return t;return null}var Ogt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Lgt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o};new Xpt;var Vgt,zgt="e-rtl",Pgt="e-btn",Tgt="e-primary",Bgt="e-icon-btn",jgt=function(e){function t(t,n){return e.call(this,t,n)||this}return Ogt(t,e),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=omt(this.element,{selector:"."+Pgt}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&xft([this.element],this.cssClass.split(" ")),this.isPrimary&&this.element.classList.add(Tgt),this.content){var e=this.enableHtmlSanitizer?Evt.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss(),this.enableRtl&&this.element.classList.add(zgt),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),"Top"!==this.iconPosition&&"Bottom"!==this.iconPosition||this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add(Bgt);var t=this.element.childNodes[0];!t||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,t)}},t.prototype.wireEvents=function(){this.isToggle&&wft.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&wft.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var t=[Tgt,zgt,Bgt,"e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(t=t.concat(this.cssClass.split(" "))),e.prototype.destroy.call(this),Eft([this.element],t),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var n=this.element.querySelector("span.e-btn-icon");n&&Cft(n),this.unWireEvents()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,t){for(var n=this.element.querySelector("span.e-btn-icon"),a=0,r=Object.keys(e);a<r.length;a++){switch(r[a]){case"isPrimary":e.isPrimary?this.element.classList.add(Tgt):this.element.classList.remove(Tgt);break;case"disabled":this.controlStatus(e.disabled);break;case"iconCss":n?e.iconCss?(n.className="e-btn-icon "+e.iconCss,this.element.textContent.trim()&&("Left"===this.iconPosition?n.classList.add("e-icon-left"):n.classList.add("e-icon-right"))):Cft(n):this.setIconCss();break;case"iconPosition":Eft([this.element],["e-top-icon-btn","e-bottom-icon-btn"]),(n=this.element.querySelector("span.e-btn-icon"))&&Cft(n),this.setIconCss();break;case"cssClass":t.cssClass&&Eft([this.element],t.cssClass.split(" ")),e.cssClass&&xft([this.element],e.cssClass.split(" "));break;case"enableRtl":e.enableRtl?this.element.classList.add(zgt):this.element.classList.remove(zgt);break;case"content":Ngt(this.element)||this.element.classList.remove(Bgt),this.enableHtmlSanitizer&&(e.content=Evt.sanitize(e.content)),this.element.innerHTML=e.content,this.setIconCss();break;case"isToggle":e.isToggle?wft.add(this.element,"click",this.btnClickHandler,this):(wft.remove(this.element,"click",this.btnClickHandler),Eft([this.element],["e-active"]))}}},t.prototype.click=function(){this.element.click()},t.prototype.focusIn=function(){this.element.focus()},Lgt([Kft("Left")],t.prototype,"iconPosition",void 0),Lgt([Kft("")],t.prototype,"iconCss",void 0),Lgt([Kft(!1)],t.prototype,"disabled",void 0),Lgt([Kft(!1)],t.prototype,"isPrimary",void 0),Lgt([Kft("")],t.prototype,"cssClass",void 0),Lgt([Kft("")],t.prototype,"content",void 0),Lgt([Kft(!1)],t.prototype,"isToggle",void 0),Lgt([Kft()],t.prototype,"locale",void 0),Lgt([Kft(!1)],t.prototype,"enableHtmlSanitizer",void 0),Lgt([Jft()],t.prototype,"created",void 0),t=Lgt([$ft],t)}(Smt),Wgt="e-rtl",Rgt="e-disabled",Fgt="e-input",Ygt="e-multi-line-input",qgt="e-input-group",Ugt="e-float-input",Ggt="e-float-line",Kgt="e-float-text",Qgt="e-float-text-content",Xgt="e-clear-icon",Jgt="e-clear-icon-hide",$gt="e-label-top",ewt="e-label-bottom",twt="e-no-float-label",nwt="e-input-custom-tag",awt="e-float-custom-tag";!function(e){var t,n=!0;function a(e){r(e.floatLabelType,e.element),e.element.addEventListener("focus",function(){var e=u(this);(e.classList.contains("e-input-group")||e.classList.contains("e-outline")||e.classList.contains("e-filled"))&&e.classList.add("e-input-focus")}),e.element.addEventListener("blur",function(){var e=u(this);(e.classList.contains("e-input-group")||e.classList.contains("e-outline")||e.classList.contains("e-filled"))&&e.classList.remove("e-input-focus")}),e.element.addEventListener("input",function(){r(t,e.element)})}function r(e,t){var n=t.value;""!==n&&!xpt(n)&&t.parentElement?t.parentElement.classList.add("e-valid-input"):"Always"!==e&&t.parentElement&&t.parentElement.classList.remove("e-valid-input")}function i(){var e=u(this).getElementsByClassName("e-float-text")[0];xpt(e)||(xft([e],$gt),e.classList.contains(ewt)&&Eft([e],ewt))}function o(){var e=u(this);if(e.getElementsByTagName("textarea")[0]?""===e.getElementsByTagName("textarea")[0].value:""===e.getElementsByTagName("input")[0].value){var t=e.getElementsByClassName("e-float-text")[0];xpt(t)||(t.classList.contains($gt)&&Eft([t],$gt),xft([t],ewt))}}function l(e){e.addEventListener("focus",i),e.addEventListener("blur",o)}function s(e,t,n){var a=xpt(n)?bft:n;"Auto"===e.floatLabelType&&l(e.element),xpt(t.container)?(t.container=m(e,Ugt,awt,"div",a),e.element.parentNode&&e.element.parentNode.insertBefore(t.container,e.element)):(xpt(e.customTag)||t.container.classList.add(awt),t.container.classList.add(Ugt));var r=a("span",{className:Ggt}),i=a("label",{className:Kgt});if(xpt(e.element.id)||""===e.element.id||(i.id="label_"+e.element.id.replace(/ /g,"_"),Hft(e.element,{"aria-labelledby":i.id})),xpt(e.element.placeholder)||""===e.element.placeholder||(i.innerText=v(e.element.placeholder),e.element.removeAttribute("placeholder")),xpt(e.properties)||xpt(e.properties.placeholder)||""===e.properties.placeholder||(i.innerText=v(e.properties.placeholder)),i.innerText||t.container.classList.add(twt),t.container.classList.contains("e-float-icon-left")){var o=t.container.querySelector(".e-input-in-wrap");o.appendChild(e.element),o.appendChild(r),o.appendChild(i)}else t.container.appendChild(e.element),t.container.appendChild(r),t.container.appendChild(i);h(e.element.value,i),"Always"===e.floatLabelType&&(i.classList.contains(ewt)&&Eft([i],ewt),xft([i],$gt)),"Auto"===e.floatLabelType&&(e.element.addEventListener("input",function(t){h(e.element.value,i,e.element)}),e.element.addEventListener("blur",function(t){h(e.element.value,i)})),xpt(e.element.getAttribute("id"))||i.setAttribute("for",e.element.getAttribute("id"))}function c(e,t){"Always"===e&&t.classList.contains("e-outline")&&t.classList.add("e-valid-input")}function d(e,t,n){e&&!n?Eft([t],Jgt):xft([t],Jgt)}function h(e,t,n){(void 0===n&&(n=null),e)?(xft([t],$gt),t.classList.contains(ewt)&&Eft([t],ewt)):(null==n||n!==document.activeElement)&&(t.classList.contains($gt)&&Eft([t],$gt),xft([t],ewt))}function u(e){var t=xpt(e.parentNode)?e:e.parentNode;return t&&t.classList.contains("e-input-in-wrap")&&(t=t.parentNode),t}function p(e,t,a){(null==n||n)&&t.addEventListener("click",function(n){e.classList.contains(Rgt)||e.readOnly||(n.preventDefault(),e!==document.activeElement&&e.focus(),e.value="",xft([t],Jgt))}),e.addEventListener("input",function(n){d(e.value,t)}),e.addEventListener("focus",function(n){d(e.value,t,e.readOnly)}),e.addEventListener("blur",function(e){setTimeout(function(){xft([t],Jgt)},200)})}function f(e,t){if(u(e).classList.contains(Ugt)&&"Auto"===t){var n=u(e).getElementsByClassName("e-float-text")[0];h(e.value,n,e)}}function m(e,t,n,a,r){var i,o=xpt(r)?bft:r;return xpt(e.customTag)?i=o(a,{className:t}):(i=o(e.customTag,{className:t})).classList.add(n),i.classList.add("e-control-wrapper"),i}function v(e){var t="";if(!xpt(e)&&""!==e){var n=document.createElement("span");n.innerHTML='<input placeholder="'+e+'"/>',t=n.children[0].placeholder}return t}function g(e,t,n){xpt(n)||""===n||Eft(t,n.split(" ")),xpt(e)||""===e||xft(t,e.split(" "))}function w(e,t){xpt(t.getElementsByClassName("e-float-text-content")[0])||(t.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&t.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(e.clientWidth<t.getElementsByClassName("e-float-text-content")[0].clientWidth||e.clientWidth===t.getElementsByClassName("e-float-text-content")[0].clientWidth)&&t.getElementsByClassName("e-float-text-content")[0].classList.add("e-float-text-overflow"))}function y(e,t){e=v(e);var n=u(t);n.classList.contains(Ugt)?xpt(e)||""===e?(n.classList.add(twt),n.getElementsByClassName("e-float-text-content")[0]?n.getElementsByClassName(Kgt)[0].children[0].textContent="":n.getElementsByClassName(Kgt)[0].textContent=""):(n.getElementsByClassName("e-float-text-content")[0]?n.getElementsByClassName(Kgt)[0].children[0].textContent=e:n.getElementsByClassName(Kgt)[0].textContent=e,n.classList.remove(twt),t.removeAttribute("placeholder")):xpt(e)||""===e?(t.removeAttribute("placeholder"),t.removeAttribute("aria-placeholder")):Hft(t,{placeholder:e,"aria-placeholder":e})}function b(e,t,n){e?Hft(t,{readonly:""}):t.removeAttribute("readonly"),xpt(n)||f(t,n)}function x(e,t){e?xft(t,Wgt):Eft(t,Wgt)}function E(e,t,n,a){var r={disabled:"disabled","aria-disabled":"true"},i=!xpt(a);e?(t.classList.remove(Rgt),M(r,t),i&&Eft([a],Rgt)):(t.classList.add(Rgt),S(r,t),i&&xft([a],Rgt)),xpt(n)||f(t,n)}function k(e,t,n,a,r){var i=xpt(r)?bft:r;e?n.clearButton=function(e,t,n,a){var r=(xpt(a)?bft:a)("span",{className:Xgt}),i=t.container;return xpt(n)?(t.container.classList.contains(Ugt)?t.container.querySelector("."+Kgt):e).insertAdjacentElement("afterend",r):i.appendChild(r),!xpt(i)&&i.classList.contains(Ugt)&&xft([i],qgt),xft([r],Jgt),p(e,r),r.setAttribute("aria-label","close"),r}(t,n,a,i):(Zft(n.clearButton),n.clearButton=null)}function M(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){var r=a[n],i=u(t);"disabled"===r&&t.classList.remove(Rgt),"disabled"===r&&i.classList.contains(qgt)&&i.classList.remove(Rgt),"placeholder"===r&&i.classList.contains(Ugt)?i.getElementsByClassName(Kgt)[0].textContent="":t.removeAttribute(r)}}function S(e,t){for(var n=0,a=Object.keys(e);n<a.length;n++){var r=a[n],i=u(t);"disabled"===r&&t.classList.add(Rgt),"disabled"===r&&i.classList.contains(qgt)&&i.classList.add(Rgt),"placeholder"===r&&i.classList.contains(Ugt)?i.getElementsByClassName(Kgt)[0].textContent=e[r]:t.setAttribute(r,e[r])}}function A(e,t){if(e.container.classList.contains("e-outline")&&e.container.getElementsByClassName("e-float-text")[0]){var n=t("span",{className:Qgt});n.innerHTML=e.container.getElementsByClassName("e-float-text")[0].innerHTML,e.container.getElementsByClassName("e-float-text")[0].innerHTML="",e.container.getElementsByClassName("e-float-text")[0].appendChild(n)}}function _(e,t,n){var a=[];a.push(n);var r=xpt(n)?t.querySelectorAll(".e-input-group-icon"):a;if(e&&r.length>0)for(var i=0;i<r.length;i++)r[i].addEventListener("mousedown",C,!1),r[i].addEventListener("mouseup",Z,!1);else if(r.length>0)for(i=0;i<r.length;i++)r[i].removeEventListener("mousedown",C,this),r[i].removeEventListener("mouseup",Z,this)}function C(){for(var e=this.parentElement;!e.classList.contains("e-input-group");)e=e.parentElement;!function(e,t){e.classList.contains("e-disabled")||e.querySelector("input").readOnly||t.classList.add("e-input-btn-ripple")}(e,this)}function Z(){var e=this;setTimeout(function(){e.classList.remove("e-input-btn-ripple")},500)}function H(e,t){var n=t("span",{className:e});return n.classList.add("e-input-group-icon"),n}function I(e,t,n,a){var r=xpt(a)?bft:a,i=H(e,r);t.classList.add("e-float-icon-left");var o=t.querySelector(".e-input-in-wrap");if(xpt(o)){o=r("span",{className:"e-input-in-wrap"}),n.parentNode.insertBefore(o,n);var l=t.querySelectorAll(n.tagName+" ~ *");o.appendChild(n);for(var s=0;s<l.length;s++)o.appendChild(l[s])}return o.parentNode.insertBefore(i,o),t.classList.contains(qgt)||t.classList.add(qgt),_(!0,t,i),i}function D(e,t,n){var a=H(e,xpt(n)?bft:n);return t.classList.contains(qgt)||t.classList.add(qgt),(t.classList.contains("e-float-icon-left")?t.querySelector(".e-input-in-wrap"):t).appendChild(a),_(!0,t,a),a}function N(e,t){"hidden"===t.type?e.classList.add("e-hidden"):e.classList.contains("e-hidden")&&e.classList.remove("e-hidden")}e.createInput=function(e,r){var i=xpt(r)?bft:r,o={container:null,buttons:[],clearButton:null};if(t=e.floatLabelType,n=e.bindClearAction,xpt(e.floatLabelType)||"Never"===e.floatLabelType?(o.container=m(e,qgt,nwt,"span",i),e.element.parentNode.insertBefore(o.container,e.element),xft([e.element],Fgt),o.container.appendChild(e.element)):s(e,o,i),a(e),xpt(e.properties)||xpt(e.properties.showClearButton)||!e.properties.showClearButton||"TEXTAREA"===e.element.tagName||(k(e.properties.showClearButton,e.element,o,!0,i),o.clearButton.setAttribute("role","button"),o.container.classList.contains(Ugt)&&xft([o.container],qgt)),!xpt(e.buttons)&&"TEXTAREA"!==e.element.tagName)for(var l=0;l<e.buttons.length;l++)o.buttons.push(D(e.buttons[l],o.container,i));return xpt(e.element)||"TEXTAREA"!==e.element.tagName||xft([o.container],Ygt),N(o.container,e.element),o=function(e,t){if(!xpt(e.properties))for(var n=0,a=Object.keys(e.properties);n<a.length;n++){switch(a[n]){case"cssClass":g(e.properties.cssClass,[t.container]),c(e.floatLabelType,t.container);break;case"enabled":E(e.properties.enabled,e.element,e.floatLabelType,t.container);break;case"enableRtl":x(e.properties.enableRtl,[t.container]);break;case"placeholder":y(e.properties.placeholder,e.element);break;case"readonly":b(e.properties.readonly,e.element)}}return t}(e,o),A(o,i),o},e.bindInitialEvent=a,e.wireFloatingEvents=l,e.wireClearBtnEvents=p,e.setValue=function(e,t,n,a){if(t.value=e,xpt(t.getAttribute("value"))&&w(t,t.parentElement),xpt(n)||"Auto"!==n||f(t,n),!xpt(a)&&a){var i=u(t);if(!xpt(i)){var o=i.getElementsByClassName(Xgt)[0];xpt(o)||(t.value&&i.classList.contains("e-input-focus")?Eft([o],Jgt):xft([o],Jgt))}}r(n,t)},e.setCssClass=g,e.calculateWidth=w,e.setWidth=function(e,t){"number"==typeof e?t.style.width=Apt(e):"string"==typeof e&&(t.style.width=e.match(/px|%|em/)?e:Apt(e)),w(t.firstChild,t)},e.setPlaceholder=y,e.setReadonly=b,e.setEnableRtl=x,e.setEnabled=E,e.setClearButton=k,e.removeAttributes=M,e.addAttributes=S,e.removeFloating=function(e){var t=e.container;if(!xpt(t)&&t.classList.contains(Ugt)){var n=t.querySelector("textarea")?t.querySelector("textarea"):t.querySelector("input"),a=t.querySelector("."+Kgt).textContent,r=null!==t.querySelector(".e-clear-icon");Cft(t.querySelector("."+Ggt)),Cft(t.querySelector("."+Kgt)),function(e,t,n){xft([e],t),Eft([e],n)}(t,[qgt],[Ugt]),function(e){e.removeEventListener("focus",i),e.removeEventListener("blur",o)}(n),Hft(n,{placeholder:a}),n.classList.add(Fgt),r||"INPUT"!==n.tagName||n.removeAttribute("required")}},e.addFloating=function(e,n,a,r){var i=xpt(r)?bft:r,o=Oft(e,"."+qgt);if(t=n,"Never"!==n){var l=o.tagName,d={element:e,floatLabelType:n,customTag:l="DIV"!==l&&"SPAN"!==l?l:null,properties:{placeholder:a}},h=o.querySelector(".e-clear-icon"),u={container:o};e.classList.remove(Fgt),s(d,u,i),A(u,i),w(d.element,u.container);var p=o.classList.contains("e-float-icon-left");if(xpt(h))if(p)h=o.querySelector(".e-input-in-wrap").querySelector(".e-input-group-icon");else h=o.querySelector(".e-input-group-icon");if(xpt(h))p&&(h=o.querySelector(".e-input-group-icon")),xpt(h)&&o.classList.remove(qgt);else{var f=o.querySelector("."+Ggt),m=o.querySelector("."+Kgt),v=p?o.querySelector(".e-input-in-wrap"):o;v.insertBefore(e,h),v.insertBefore(f,h),v.insertBefore(m,h)}}c(n,e.parentElement)},e.createSpanElement=A,e.setRipple=function(e,t){for(var n=0;n<t.length;n++)_(e,t[n].container)},e.addIcon=function(e,t,n,a,r){var i="string"==typeof t?t.split(","):t;if("append"===e.toLowerCase())for(var o=0,l=i;o<l.length;o++){D(l[o],n,r)}else for(var s=0,c=i;s<c.length;s++){I(c[s],n,a,r)}n.getElementsByClassName("e-input-group-icon")[0]&&n.getElementsByClassName("e-float-text-overflow")[0]&&n.getElementsByClassName("e-float-text-overflow")[0].classList.add("e-icon")},e.prependSpan=I,e.appendSpan=D,e.validateInputType=N}(Vgt||(Vgt={}));var rwt=function(){function e(e){return this.subQuery=null,this.isChild=!1,this.distincts=[],this.queries=[],this.key="",this.fKey="","string"==typeof e?this.fromTable=e:e&&e instanceof Array&&(this.lookups=e),this.expands=[],this.sortedColumns=[],this.groupedColumns=[],this.subQuery=null,this.isChild=!1,this.params=[],this.lazyLoad=[],this}return e.prototype.setKey=function(e){return this.key=e,this},e.prototype.using=function(e){return this.dataManager=e,this},e.prototype.execute=function(e,t,n,a){return(e=e||this.dataManager)?e.executeQuery(this,t,n,a):lwt.throwError('Query - execute() : dataManager needs to be is set using "using" function or should be passed as argument')},e.prototype.executeLocal=function(e){return(e=e||this.dataManager)?e.executeLocal(this):lwt.throwError('Query - executeLocal() : dataManager needs to be is set using "using" function or should be passed as argument')},e.prototype.clone=function(){var t=new e;return t.queries=this.queries.slice(0),t.key=this.key,t.isChild=this.isChild,t.dataManager=this.dataManager,t.fromTable=this.fromTable,t.params=this.params.slice(0),t.expands=this.expands.slice(0),t.sortedColumns=this.sortedColumns.slice(0),t.groupedColumns=this.groupedColumns.slice(0),t.subQuerySelector=this.subQuerySelector,t.subQuery=this.subQuery,t.fKey=this.fKey,t.isCountRequired=this.isCountRequired,t.distincts=this.distincts.slice(0),t.lazyLoad=this.lazyLoad.slice(0),t},e.prototype.from=function(e){return this.fromTable=e,this},e.prototype.addParams=function(e,t){return"function"==typeof t?this.params.push({key:e,fn:t}):this.params.push({key:e,value:t}),this},e.prototype.distinct=function(e){return this.distincts="string"==typeof e?[].slice.call([e],0):e.slice(0),this},e.prototype.expand=function(e){return this.expands="string"==typeof e?[].slice.call([e],0):e.slice(0),this},e.prototype.where=function(e,t,n,a,r){t=t?t.toLowerCase():null;var i=null;return"string"==typeof e?i=new iwt(e,t,n,a,r):e instanceof iwt&&(i=e),this.queries.push({fn:"onWhere",e:i}),this},e.prototype.search=function(e,t,n,a,r){"string"==typeof t&&(t=[t]),n&&"none"!==n||(n="contains");var i=lwt.fnOperators[n];return this.queries.push({fn:"onSearch",e:{fieldNames:t,operator:n,searchKey:e,ignoreCase:a,ignoreAccent:r,comparer:i}}),this},e.prototype.sortBy=function(e,t,n){return this.sortByForeignKey(e,t,n)},e.prototype.sortByForeignKey=function(t,n,a,r){var i,o,l=xpt(r)?"ascending":r;if("string"==typeof t&&lwt.endsWith(t.toLowerCase()," desc")&&(t=t.replace(/ desc$/i,""),n="descending"),n&&"string"!=typeof n||(l=n?n.toLowerCase():"ascending",n=lwt.fnSort(n)),a){i=e.filterQueries(this.queries,"onSortBy");for(var s=0;s<i.length;s++)if("string"==typeof(o=i[s].e.fieldName)){if(o===t)return this}else if(o instanceof Array)for(var c=0;c<o.length;c++)if(o[c]===t||t.toLowerCase()===o[c]+" desc")return this}return this.queries.push({fn:"onSortBy",e:{fieldName:t,comparer:n,direction:l}}),this},e.prototype.sortByDesc=function(e){return this.sortBy(e,"descending")},e.prototype.group=function(e,t,n){return this.sortBy(e,null,!0),this.queries.push({fn:"onGroup",e:{fieldName:e,comparer:t||null,format:n||null}}),this},e.prototype.page=function(e,t){return this.queries.push({fn:"onPage",e:{pageIndex:e,pageSize:t}}),this},e.prototype.range=function(e,t){return this.queries.push({fn:"onRange",e:{start:e,end:t}}),this},e.prototype.take=function(e){return this.queries.push({fn:"onTake",e:{nos:e}}),this},e.prototype.skip=function(e){return this.queries.push({fn:"onSkip",e:{nos:e}}),this},e.prototype.select=function(e){return"string"==typeof e&&(e=[].slice.call([e],0)),this.queries.push({fn:"onSelect",e:{fieldNames:e}}),this},e.prototype.hierarchy=function(e,t){return this.subQuerySelector=t,this.subQuery=e,this},e.prototype.foreignKey=function(e){return this.fKey=e,this},e.prototype.requiresCount=function(){return this.isCountRequired=!0,this},e.prototype.aggregate=function(e,t){return this.queries.push({fn:"onAggregates",e:{field:t,type:e}}),this},e.filterQueries=function(e,t){return e.filter(function(e){return e.fn===t})},e.filterQueryLists=function(e,t){for(var n=e.filter(function(e){return-1!==t.indexOf(e.fn)}),a={},r=0;r<n.length;r++)a[n[r].fn]||(a[n[r].fn]=n[r].e);return a},e}(),iwt=function(){function e(t,n,a,r,i){return void 0===r&&(r=!1),this.ignoreAccent=!1,this.isComplex=!1,"string"==typeof t?(this.field=t,this.operator=n.toLowerCase(),this.value=a,this.ignoreCase=r,this.ignoreAccent=i,this.isComplex=!1,this.comparer=lwt.fnOperators.processOperator(this.operator)):(t instanceof e&&a instanceof e||a instanceof Array)&&(this.isComplex=!0,this.condition=n.toLowerCase(),this.predicates=[t],a instanceof Array?[].push.apply(this.predicates,a):this.predicates.push(a)),this}return e.and=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return e.combinePredicates([].slice.call(t,0),"and")},e.prototype.and=function(t,n,a,r,i){return e.combine(this,t,n,a,"and",r,i)},e.or=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return e.combinePredicates([].slice.call(t,0),"or")},e.prototype.or=function(t,n,a,r,i){return e.combine(this,t,n,a,"or",r,i)},e.fromJson=function(e){if(e instanceof Array){for(var t=[],n=0,a=e.length;n<a;n++)t.push(this.fromJSONData(e[n]));return t}var r=e;return this.fromJSONData(r)},e.prototype.validate=function(e){var t,n,a=this.predicates?this.predicates:[];if(!this.isComplex&&this.comparer)return this.comparer.call(this,lwt.getObject(this.field,e),this.value,this.ignoreCase,this.ignoreAccent);t="and"===this.condition;for(var r=0;r<a.length;r++)if(n=a[r].validate(e),t){if(!n)return!1}else if(n)return!0;return t},e.prototype.toJson=function(){var e,t;if(this.isComplex){e=[],t=this.predicates;for(var n=0;n<t.length;n++)e.push(t[n].toJson())}return{isComplex:this.isComplex,field:this.field,operator:this.operator,value:this.value,ignoreCase:this.ignoreCase,ignoreAccent:this.ignoreAccent,condition:this.condition,predicates:e}},e.combinePredicates=function(t,n){if(1===t.length){if(!(t[0]instanceof Array))return t[0];t=t[0]}return new e(t[0],n,t.slice(1))},e.combine=function(t,n,a,r,i,o,l){return n instanceof e?e[i](t,n):"string"==typeof n?e[i](t,new e(n,a,r,o,l)):lwt.throwError("Predicate - "+i+" : invalid arguments")},e.fromJSONData=function(t){for(var n=t.predicates||[],a=n.length,r=[],i=0;i<a;i++)r.push(this.fromJSONData(n[i]));return t.isComplex?new e(r[0],t.condition,r.slice(1)):new e(t.field,t.operator,t.value,t.ignoreCase,t.ignoreAccent)},e}(),owt={GroupGuid:"{271bbba0-1ee7}"},lwt=function(){function e(){}return e.getValue=function(e,t){return"function"==typeof e?e.call(t||{}):e},e.endsWith=function(e,t){return e.slice&&e.slice(-t.length)===t},e.startsWith=function(e,t){return e.slice(0,t.length)===t},e.fnSort=function(t){return"ascending"===(t=t?e.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},e.fnAscending=function(e,t){return xpt(e)&&xpt(t)||null==t?-1:"string"==typeof e?e.localeCompare(t):null==e?1:e-t},e.fnDescending=function(e,t){return xpt(e)&&xpt(t)?-1:null==t?1:"string"==typeof e?-1*e.localeCompare(t):null==e?-1:t-e},e.extractFields=function(e,t){for(var n={},a=0;a<t.length;a++)n=this.setValue(t[a],this.getObject(t[a],e),n);return n},e.select=function(e,t){for(var n=[],a=0;a<e.length;a++)n.push(this.extractFields(e[a],t));return n},e.group=function(t,n,a,r,i,o,l){r=r||1;var s=t,c="GroupGuid";if(s.GroupGuid===owt[c]){for(var d=function(e){if(xpt(i))s[e].items=h.group(s[e].items,n,a,s.level+1,null,o,l),s[e].count=s[e].items.length;else{var t,r=i.filter(function(t){return t.key===s[e].key});t=i.indexOf(r[0]),s[e].items=h.group(s[e].items,n,a,s.level+1,i[t].items,o,l),s[e].count=i[t].count}},h=this,u=0;u<s.length;u++)d(u);return s.childLevels+=1,s}var p={},f=[];f.GroupGuid=owt[c],f.level=r,f.childLevels=0,f.records=s;for(var m=function(e){var t=v.getVal(s,e,n);if(xpt(o)||(t=o(t,n)),!p[t]&&(p[t]={key:t,count:0,items:[],aggregates:{},field:n},f.push(p[t]),!xpt(i))){var r=i.filter(function(e){return e.key===p[t].key});p[t].count=r[0].count}p[t].count=xpt(i)?p[t].count+=1:p[t].count,(!l||l&&a.length)&&p[t].items.push(s[e])},v=this,g=0;g<s.length;g++)m(g);if(a&&a.length){var w=function(t){for(var n={},r=void 0,o=a,l=0;l<a.length;l++)if(r=e.aggregates[a[l].type],xpt(i))r&&(n[o[l].field+" - "+o[l].type]=r(f[t].items,o[l].field));else{var s=i.filter(function(e){return e.key===f[t].key});r&&(n[o[l].field+" - "+o[l].type]=r(s[0].items,o[l].field))}f[t].aggregates=n};for(g=0;g<f.length;g++)w(g)}if(l&&f.length&&a.length)for(g=0;g<f.length;g++)f[g].items=[];return s.length&&f||s},e.buildHierarchy=function(e,t,n,a,r){var i,o={};for(a.result&&(a=a.result),a.GroupGuid&&this.throwError("DataManager: Do not have support Grouping in hierarchy"),i=0;i<a.length;i++){(o[l=this.getObject(e,a[i])]||(o[l]=[])).push(a[i])}for(i=0;i<n.length;i++){var l=this.getObject(r||e,n[i]);n[i][t]=o[l]}},e.getFieldList=function(e,t,n){if(void 0===n&&(n=""),null==t)return this.getFieldList(e,[],n);for(var a=e,r=0,i=Object.keys(e);r<i.length;r++){var o=i[r];"object"!=typeof a[o]||a[o]instanceof Array?t.push(n+o):this.getFieldList(a[o],t,n+o+".")}return t},e.getObject=function(e,t){if(!e)return t;if(t){if(-1===e.indexOf("."))return t[e];for(var n=t,a=e.split("."),r=0;r<a.length&&null!=n;r++)n=n[a[r]];return n}},e.setValue=function(e,t,n){var a,r,i=e.toString().split("."),o=n||{},l=o,s=i.length;for(a=0;a<s;a++)r=i[a],a+1===s?l[r]=void 0===t?void 0:t:xpt(l[r])&&(l[r]={}),l=l[r];return o},e.sort=function(e,t,n){if(e.length<=1)return e;var a=parseInt((e.length/2).toString(),10),r=e.slice(0,a),i=e.slice(a);return r=this.sort(r,t,n),i=this.sort(i,t,n),this.merge(r,i,t,n)},e.ignoreDiacritics=function(t){return"string"!=typeof t?t:t.split("").map(function(t){return t in e.diacritics?e.diacritics[t]:t}).join("")},e.merge=function(e,t,n,a){for(var r,i=[];e.length>0||t.length>0;)r=e.length>0&&t.length>0?a?a(this.getVal(e,0,n),this.getVal(t,0,n),e[0],t[0])<=0?e:t:e[0][n]<e[0][n]?e:t:e.length>0?e:t,i.push(r.shift());return i},e.getVal=function(e,t,n){return n?this.getObject(n,e[t]):e[t]},e.toLowerCase=function(e){return e?"string"==typeof e?e.toLowerCase():e.toString():0===e||!1===e?e.toString():""},e.callAdaptorFunction=function(e,t,n,a){if(t in e){var r=e[t](n,a);xpt(r)||(n=r)}return n},e.getAddParams=function(t,n,a){var r={};return e.callAdaptorFunction(t,"addParams",{dm:n,query:a,params:a.params,reqParams:r}),r},e.isPlainObject=function(e){return!!e&&e.constructor===Object},e.isCors=function(){var e=null;try{e=new window.XMLHttpRequest}catch(e){}return!!e&&"withCredentials"in e},e.getGuid=function(e){var t;return(e||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(e,n){if("crypto"in window&&"getRandomValues"in crypto){var a=new Uint8Array(1);window.crypto.getRandomValues(a),t=a[0]%16|0}else t=16*Math.random()|0;return"0123456789abcdef"[19===n?3&t|8:t]})},e.isNull=function(e){return null==e},e.getItemFromComparer=function(t,n,a){var r,i,o,l=0,s="string"==typeof e.getVal(t,0,n);if(t.length)for(;xpt(r)&&l<t.length;)r=e.getVal(t,l,n),o=t[l++];for(;l<t.length;l++)xpt(i=e.getVal(t,l,n))||(s&&(r=+r,i=+i),a(r,i)>0&&(r=i,o=t[l]));return o},e.distinct=function(t,n,a){a=!xpt(a)&&a;var r,i=[],o={};return t.forEach(function(l,s){(r="object"==typeof t[s]?e.getVal(t,s,n):t[s])in o||(i.push(a?t[s]:r),o[r]=1)}),i},e.processData=function(e,t){var n=this.prepareQuery(e),a=new wwt(t);e.requiresCounts&&n.requiresCount();var r=a.executeLocal(n),i={result:e.requiresCounts?r.result:r,count:r.count,aggregates:JSON.stringify(r.aggregates)};return e.requiresCounts?i:r},e.prepareQuery=function(t){var n=this,a=new rwt;(t.select&&a.select(t.select),t.where)&&e.parse.parseJson(t.where).filter(function(e){if(xpt(e.condition))a.where(e.field,e.operator,e.value,e.ignoreCase,e.ignoreAccent);else{var t=[];e.field?t.push(new iwt(e.field,e.operator,e.value,e.ignoreCase,e.ignoreAccent)):t=t.concat(n.getPredicate(e.predicates)),"or"==e.condition?a.where(iwt.or(t)):"and"==e.condition&&a.where(iwt.and(t))}});t.search&&e.parse.parseJson(t.search).filter(function(e){return a.search(e.key,e.fields,e.operator,e.ignoreCase,e.ignoreAccent)});return t.aggregates&&t.aggregates.filter(function(e){return a.aggregate(e.type,e.field)}),t.sorted&&t.sorted.filter(function(e){return a.sortBy(e.name,e.direction)}),t.skip&&a.skip(t.skip),t.take&&a.take(t.take),t.group&&t.group.filter(function(e){return a.group(e)}),a},e.getPredicate=function(e){for(var t=[],n=0;n<e.length;n++){var a=e[n];if(a.field)t.push(new iwt(a.field,a.operator,a.value,a.ignoreCase,a.ignoreAccent));else{for(var r=[],i=this.getPredicate(a.predicates),o=0,l=Object.keys(i);o<l.length;o++){var s=l[o];r.push(i[s])}t.push("or"==a.condition?iwt.or(r):iwt.and(r))}}return t},e.serverTimezoneOffset=null,e.timeZoneHandling=!0,e.throwError=function(e){try{throw new Error(e)}catch(e){throw e.message+"\n"+e.stack}},e.aggregates={sum:function(t,n){for(var a,r=0,i="number"!=typeof e.getVal(t,0,n),o=0;o<t.length;o++)a=e.getVal(t,o,n),isNaN(a)||null===a||(i&&(a=+a),r+=a);return r},average:function(t,n){return e.aggregates.sum(t,n)/t.length},min:function(t,n){var a;return"function"==typeof n&&(a=n,n=null),e.getObject(n,e.getItemFromComparer(t,n,a||e.fnAscending))},max:function(t,n){var a;return"function"==typeof n&&(a=n,n=null),e.getObject(n,e.getItemFromComparer(t,n,a||e.fnDescending))},truecount:function(e,t){return new wwt(e).executeLocal((new rwt).where(t,"equal",!0,!0)).length},falsecount:function(e,t){return new wwt(e).executeLocal((new rwt).where(t,"equal",!1,!0)).length},count:function(e,t){return e.length}},e.operatorSymbols={"<":"lessthan",">":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},e.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},e.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof"},e.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains"},e.diacritics={"Ⓐ":"A","A":"A","À":"A","Á":"A","Â":"A","Ầ":"A","Ấ":"A","Ẫ":"A","Ẩ":"A","Ã":"A","Ā":"A","Ă":"A","Ằ":"A","Ắ":"A","Ẵ":"A","Ẳ":"A","Ȧ":"A","Ǡ":"A","Ä":"A","Ǟ":"A","Ả":"A","Å":"A","Ǻ":"A","Ǎ":"A","Ȁ":"A","Ȃ":"A","Ạ":"A","Ậ":"A","Ặ":"A","Ḁ":"A","Ą":"A","Ⱥ":"A","Ɐ":"A","Ꜳ":"AA","Æ":"AE","Ǽ":"AE","Ǣ":"AE","Ꜵ":"AO","Ꜷ":"AU","Ꜹ":"AV","Ꜻ":"AV","Ꜽ":"AY","Ⓑ":"B","B":"B","Ḃ":"B","Ḅ":"B","Ḇ":"B","Ƀ":"B","Ƃ":"B","Ɓ":"B","Ⓒ":"C","C":"C","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","Ç":"C","Ḉ":"C","Ƈ":"C","Ȼ":"C","Ꜿ":"C","Ⓓ":"D","D":"D","Ḋ":"D","Ď":"D","Ḍ":"D","Ḑ":"D","Ḓ":"D","Ḏ":"D","Đ":"D","Ƌ":"D","Ɗ":"D","Ɖ":"D","Ꝺ":"D","DZ":"DZ","DŽ":"DZ","Dz":"Dz","Dž":"Dz","Ⓔ":"E","E":"E","È":"E","É":"E","Ê":"E","Ề":"E","Ế":"E","Ễ":"E","Ể":"E","Ẽ":"E","Ē":"E","Ḕ":"E","Ḗ":"E","Ĕ":"E","Ė":"E","Ë":"E","Ẻ":"E","Ě":"E","Ȅ":"E","Ȇ":"E","Ẹ":"E","Ệ":"E","Ȩ":"E","Ḝ":"E","Ę":"E","Ḙ":"E","Ḛ":"E","Ɛ":"E","Ǝ":"E","Ⓕ":"F","F":"F","Ḟ":"F","Ƒ":"F","Ꝼ":"F","Ⓖ":"G","G":"G","Ǵ":"G","Ĝ":"G","Ḡ":"G","Ğ":"G","Ġ":"G","Ǧ":"G","Ģ":"G","Ǥ":"G","Ɠ":"G","Ꞡ":"G","Ᵹ":"G","Ꝿ":"G","Ⓗ":"H","H":"H","Ĥ":"H","Ḣ":"H","Ḧ":"H","Ȟ":"H","Ḥ":"H","Ḩ":"H","Ḫ":"H","Ħ":"H","Ⱨ":"H","Ⱶ":"H","Ɥ":"H","Ⓘ":"I","I":"I","Ì":"I","Í":"I","Î":"I","Ĩ":"I","Ī":"I","Ĭ":"I","İ":"I","Ï":"I","Ḯ":"I","Ỉ":"I","Ǐ":"I","Ȉ":"I","Ȋ":"I","Ị":"I","Į":"I","Ḭ":"I","Ɨ":"I","Ⓙ":"J","J":"J","Ĵ":"J","Ɉ":"J","Ⓚ":"K","K":"K","Ḱ":"K","Ǩ":"K","Ḳ":"K","Ķ":"K","Ḵ":"K","Ƙ":"K","Ⱪ":"K","Ꝁ":"K","Ꝃ":"K","Ꝅ":"K","Ꞣ":"K","Ⓛ":"L","L":"L","Ŀ":"L","Ĺ":"L","Ľ":"L","Ḷ":"L","Ḹ":"L","Ļ":"L","Ḽ":"L","Ḻ":"L","Ł":"L","Ƚ":"L","Ɫ":"L","Ⱡ":"L","Ꝉ":"L","Ꝇ":"L","Ꞁ":"L","LJ":"LJ","Lj":"Lj","Ⓜ":"M","M":"M","Ḿ":"M","Ṁ":"M","Ṃ":"M","Ɱ":"M","Ɯ":"M","Ⓝ":"N","N":"N","Ǹ":"N","Ń":"N","Ñ":"N","Ṅ":"N","Ň":"N","Ṇ":"N","Ņ":"N","Ṋ":"N","Ṉ":"N","Ƞ":"N","Ɲ":"N","Ꞑ":"N","Ꞥ":"N","NJ":"NJ","Nj":"Nj","Ⓞ":"O","O":"O","Ò":"O","Ó":"O","Ô":"O","Ồ":"O","Ố":"O","Ỗ":"O","Ổ":"O","Õ":"O","Ṍ":"O","Ȭ":"O","Ṏ":"O","Ō":"O","Ṑ":"O","Ṓ":"O","Ŏ":"O","Ȯ":"O","Ȱ":"O","Ö":"O","Ȫ":"O","Ỏ":"O","Ő":"O","Ǒ":"O","Ȍ":"O","Ȏ":"O","Ơ":"O","Ờ":"O","Ớ":"O","Ỡ":"O","Ở":"O","Ợ":"O","Ọ":"O","Ộ":"O","Ǫ":"O","Ǭ":"O","Ø":"O","Ǿ":"O","Ɔ":"O","Ɵ":"O","Ꝋ":"O","Ꝍ":"O","Ƣ":"OI","Ꝏ":"OO","Ȣ":"OU","Ⓟ":"P","P":"P","Ṕ":"P","Ṗ":"P","Ƥ":"P","Ᵽ":"P","Ꝑ":"P","Ꝓ":"P","Ꝕ":"P","Ⓠ":"Q","Q":"Q","Ꝗ":"Q","Ꝙ":"Q","Ɋ":"Q","Ⓡ":"R","R":"R","Ŕ":"R","Ṙ":"R","Ř":"R","Ȑ":"R","Ȓ":"R","Ṛ":"R","Ṝ":"R","Ŗ":"R","Ṟ":"R","Ɍ":"R","Ɽ":"R","Ꝛ":"R","Ꞧ":"R","Ꞃ":"R","Ⓢ":"S","S":"S","ẞ":"S","Ś":"S","Ṥ":"S","Ŝ":"S","Ṡ":"S","Š":"S","Ṧ":"S","Ṣ":"S","Ṩ":"S","Ș":"S","Ş":"S","Ȿ":"S","Ꞩ":"S","Ꞅ":"S","Ⓣ":"T","T":"T","Ṫ":"T","Ť":"T","Ṭ":"T","Ț":"T","Ţ":"T","Ṱ":"T","Ṯ":"T","Ŧ":"T","Ƭ":"T","Ʈ":"T","Ⱦ":"T","Ꞇ":"T","Ꜩ":"TZ","Ⓤ":"U","U":"U","Ù":"U","Ú":"U","Û":"U","Ũ":"U","Ṹ":"U","Ū":"U","Ṻ":"U","Ŭ":"U","Ü":"U","Ǜ":"U","Ǘ":"U","Ǖ":"U","Ǚ":"U","Ủ":"U","Ů":"U","Ű":"U","Ǔ":"U","Ȕ":"U","Ȗ":"U","Ư":"U","Ừ":"U","Ứ":"U","Ữ":"U","Ử":"U","Ự":"U","Ụ":"U","Ṳ":"U","Ų":"U","Ṷ":"U","Ṵ":"U","Ʉ":"U","Ⓥ":"V","V":"V","Ṽ":"V","Ṿ":"V","Ʋ":"V","Ꝟ":"V","Ʌ":"V","Ꝡ":"VY","Ⓦ":"W","W":"W","Ẁ":"W","Ẃ":"W","Ŵ":"W","Ẇ":"W","Ẅ":"W","Ẉ":"W","Ⱳ":"W","Ⓧ":"X","X":"X","Ẋ":"X","Ẍ":"X","Ⓨ":"Y","Y":"Y","Ỳ":"Y","Ý":"Y","Ŷ":"Y","Ỹ":"Y","Ȳ":"Y","Ẏ":"Y","Ÿ":"Y","Ỷ":"Y","Ỵ":"Y","Ƴ":"Y","Ɏ":"Y","Ỿ":"Y","Ⓩ":"Z","Z":"Z","Ź":"Z","Ẑ":"Z","Ż":"Z","Ž":"Z","Ẓ":"Z","Ẕ":"Z","Ƶ":"Z","Ȥ":"Z","Ɀ":"Z","Ⱬ":"Z","Ꝣ":"Z","ⓐ":"a","a":"a","ẚ":"a","à":"a","á":"a","â":"a","ầ":"a","ấ":"a","ẫ":"a","ẩ":"a","ã":"a","ā":"a","ă":"a","ằ":"a","ắ":"a","ẵ":"a","ẳ":"a","ȧ":"a","ǡ":"a","ä":"a","ǟ":"a","ả":"a","å":"a","ǻ":"a","ǎ":"a","ȁ":"a","ȃ":"a","ạ":"a","ậ":"a","ặ":"a","ḁ":"a","ą":"a","ⱥ":"a","ɐ":"a","ꜳ":"aa","æ":"ae","ǽ":"ae","ǣ":"ae","ꜵ":"ao","ꜷ":"au","ꜹ":"av","ꜻ":"av","ꜽ":"ay","ⓑ":"b","b":"b","ḃ":"b","ḅ":"b","ḇ":"b","ƀ":"b","ƃ":"b","ɓ":"b","ⓒ":"c","c":"c","ć":"c","ĉ":"c","ċ":"c","č":"c","ç":"c","ḉ":"c","ƈ":"c","ȼ":"c","ꜿ":"c","ↄ":"c","ⓓ":"d","d":"d","ḋ":"d","ď":"d","ḍ":"d","ḑ":"d","ḓ":"d","ḏ":"d","đ":"d","ƌ":"d","ɖ":"d","ɗ":"d","ꝺ":"d","dz":"dz","dž":"dz","ⓔ":"e","e":"e","è":"e","é":"e","ê":"e","ề":"e","ế":"e","ễ":"e","ể":"e","ẽ":"e","ē":"e","ḕ":"e","ḗ":"e","ĕ":"e","ė":"e","ë":"e","ẻ":"e","ě":"e","ȅ":"e","ȇ":"e","ẹ":"e","ệ":"e","ȩ":"e","ḝ":"e","ę":"e","ḙ":"e","ḛ":"e","ɇ":"e","ɛ":"e","ǝ":"e","ⓕ":"f","f":"f","ḟ":"f","ƒ":"f","ꝼ":"f","ⓖ":"g","g":"g","ǵ":"g","ĝ":"g","ḡ":"g","ğ":"g","ġ":"g","ǧ":"g","ģ":"g","ǥ":"g","ɠ":"g","ꞡ":"g","ᵹ":"g","ꝿ":"g","ⓗ":"h","h":"h","ĥ":"h","ḣ":"h","ḧ":"h","ȟ":"h","ḥ":"h","ḩ":"h","ḫ":"h","ẖ":"h","ħ":"h","ⱨ":"h","ⱶ":"h","ɥ":"h","ƕ":"hv","ⓘ":"i","i":"i","ì":"i","í":"i","î":"i","ĩ":"i","ī":"i","ĭ":"i","ï":"i","ḯ":"i","ỉ":"i","ǐ":"i","ȉ":"i","ȋ":"i","ị":"i","į":"i","ḭ":"i","ɨ":"i","ı":"i","ⓙ":"j","j":"j","ĵ":"j","ǰ":"j","ɉ":"j","ⓚ":"k","k":"k","ḱ":"k","ǩ":"k","ḳ":"k","ķ":"k","ḵ":"k","ƙ":"k","ⱪ":"k","ꝁ":"k","ꝃ":"k","ꝅ":"k","ꞣ":"k","ⓛ":"l","l":"l","ŀ":"l","ĺ":"l","ľ":"l","ḷ":"l","ḹ":"l","ļ":"l","ḽ":"l","ḻ":"l","ſ":"l","ł":"l","ƚ":"l","ɫ":"l","ⱡ":"l","ꝉ":"l","ꞁ":"l","ꝇ":"l","lj":"lj","ⓜ":"m","m":"m","ḿ":"m","ṁ":"m","ṃ":"m","ɱ":"m","ɯ":"m","ⓝ":"n","n":"n","ǹ":"n","ń":"n","ñ":"n","ṅ":"n","ň":"n","ṇ":"n","ņ":"n","ṋ":"n","ṉ":"n","ƞ":"n","ɲ":"n","ʼn":"n","ꞑ":"n","ꞥ":"n","nj":"nj","ⓞ":"o","o":"o","ò":"o","ó":"o","ô":"o","ồ":"o","ố":"o","ỗ":"o","ổ":"o","õ":"o","ṍ":"o","ȭ":"o","ṏ":"o","ō":"o","ṑ":"o","ṓ":"o","ŏ":"o","ȯ":"o","ȱ":"o","ö":"o","ȫ":"o","ỏ":"o","ő":"o","ǒ":"o","ȍ":"o","ȏ":"o","ơ":"o","ờ":"o","ớ":"o","ỡ":"o","ở":"o","ợ":"o","ọ":"o","ộ":"o","ǫ":"o","ǭ":"o","ø":"o","ǿ":"o","ɔ":"o","ꝋ":"o","ꝍ":"o","ɵ":"o","ƣ":"oi","ȣ":"ou","ꝏ":"oo","ⓟ":"p","p":"p","ṕ":"p","ṗ":"p","ƥ":"p","ᵽ":"p","ꝑ":"p","ꝓ":"p","ꝕ":"p","ⓠ":"q","q":"q","ɋ":"q","ꝗ":"q","ꝙ":"q","ⓡ":"r","r":"r","ŕ":"r","ṙ":"r","ř":"r","ȑ":"r","ȓ":"r","ṛ":"r","ṝ":"r","ŗ":"r","ṟ":"r","ɍ":"r","ɽ":"r","ꝛ":"r","ꞧ":"r","ꞃ":"r","ⓢ":"s","s":"s","ß":"s","ś":"s","ṥ":"s","ŝ":"s","ṡ":"s","š":"s","ṧ":"s","ṣ":"s","ṩ":"s","ș":"s","ş":"s","ȿ":"s","ꞩ":"s","ꞅ":"s","ẛ":"s","ⓣ":"t","t":"t","ṫ":"t","ẗ":"t","ť":"t","ṭ":"t","ț":"t","ţ":"t","ṱ":"t","ṯ":"t","ŧ":"t","ƭ":"t","ʈ":"t","ⱦ":"t","ꞇ":"t","ꜩ":"tz","ⓤ":"u","u":"u","ù":"u","ú":"u","û":"u","ũ":"u","ṹ":"u","ū":"u","ṻ":"u","ŭ":"u","ü":"u","ǜ":"u","ǘ":"u","ǖ":"u","ǚ":"u","ủ":"u","ů":"u","ű":"u","ǔ":"u","ȕ":"u","ȗ":"u","ư":"u","ừ":"u","ứ":"u","ữ":"u","ử":"u","ự":"u","ụ":"u","ṳ":"u","ų":"u","ṷ":"u","ṵ":"u","ʉ":"u","ⓥ":"v","v":"v","ṽ":"v","ṿ":"v","ʋ":"v","ꝟ":"v","ʌ":"v","ꝡ":"vy","ⓦ":"w","w":"w","ẁ":"w","ẃ":"w","ŵ":"w","ẇ":"w","ẅ":"w","ẘ":"w","ẉ":"w","ⱳ":"w","ⓧ":"x","x":"x","ẋ":"x","ẍ":"x","ⓨ":"y","y":"y","ỳ":"y","ý":"y","ŷ":"y","ỹ":"y","ȳ":"y","ẏ":"y","ÿ":"y","ỷ":"y","ẙ":"y","ỵ":"y","ƴ":"y","ɏ":"y","ỿ":"y","ⓩ":"z","z":"z","ź":"z","ẑ":"z","ż":"z","ž":"z","ẓ":"z","ẕ":"z","ƶ":"z","ȥ":"z","ɀ":"z","ⱬ":"z","ꝣ":"z","Ά":"Α","Έ":"Ε","Ή":"Η","Ί":"Ι","Ϊ":"Ι","Ό":"Ο","Ύ":"Υ","Ϋ":"Υ","Ώ":"Ω","ά":"α","έ":"ε","ή":"η","ί":"ι","ϊ":"ι","ΐ":"ι","ό":"ο","ύ":"υ","ϋ":"υ","ΰ":"υ","ω":"ω","ς":"σ"},e.fnOperators={equal:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?e.toLowerCase(t)===e.toLowerCase(n):t===n},notequal:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),!e.fnOperators.equal(t,n,a)},lessthan:function(t,n,a){return a?e.toLowerCase(t)<e.toLowerCase(n):(xpt(t)&&(t=void 0),t<n)},greaterthan:function(t,n,a){return a?e.toLowerCase(t)>e.toLowerCase(n):t>n},lessthanorequal:function(t,n,a){return a?e.toLowerCase(t)<=e.toLowerCase(n):(xpt(t)&&(t=void 0),t<=n)},greaterthanorequal:function(t,n,a){return a?e.toLowerCase(t)>=e.toLowerCase(n):t>=n},contains:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?!xpt(t)&&!xpt(n)&&-1!==e.toLowerCase(t).indexOf(e.toLowerCase(n)):!xpt(t)&&!xpt(n)&&-1!==t.toString().indexOf(n)},notnull:function(e){return null!==e},isnull:function(e){return null===e},startswith:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?t&&n&&e.startsWith(e.toLowerCase(t),e.toLowerCase(n)):t&&n&&e.startsWith(t,n)},endswith:function(t,n,a,r){return r&&(t=e.ignoreDiacritics(t),n=e.ignoreDiacritics(n)),a?t&&n&&e.endsWith(e.toLowerCase(t),e.toLowerCase(n)):t&&n&&e.endsWith(t,n)},processSymbols:function(t){var n=e.operatorSymbols[t];return n?e.fnOperators[n]:e.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){var n=e.fnOperators[t];return n||e.fnOperators.processSymbols(t)}},e.parse={parseJson:function(t){return"string"==typeof t?t=JSON.parse(t,e.parse.jsonReviver):t instanceof Array?e.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&e.parse.iterateAndReviveJson(t),t},iterateAndReviveArray:function(t){for(var n=0;n<t.length;n++)"object"==typeof t[n]&&null!==t[n]?e.parse.iterateAndReviveJson(t[n]):"string"!=typeof t[n]||/^[\s]*\[|^[\s]*\{(.)+:|\"/g.test(t[n])?t[n]=e.parse.parseJson(t[n]):t[n]=e.parse.jsonReviver("",t[n])},iterateAndReviveJson:function(t){for(var n,a=0,r=Object.keys(t);a<r.length;a++){var i=r[a];e.startsWith(i,"__")||("object"==typeof(n=t[i])?n instanceof Array?e.parse.iterateAndReviveArray(n):n&&e.parse.iterateAndReviveJson(n):t[i]=e.parse.jsonReviver(t[i],n))}},jsonReviver:function(t,n){if("string"==typeof n){var a=/^\/Date\(([+-]?[0-9]+)([+-][0-9]{4})?\)\/$/.exec(n),r=e.timeZoneHandling?e.serverTimezoneOffset:null;if(a)return e.dateParse.toTimeZone(new Date(parseInt(a[1],10)),r,!0);if(/^(\d{4}\-\d\d\-\d\d([tT][\d:\.]*){1})([zZ]|([+\-])(\d\d):?(\d\d))?$/.test(n)){var i=n.indexOf("Z")>-1||n.indexOf("z")>-1,o=n.split(/[^0-9.]/);if(i)n=e.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5],10)),e.serverTimezoneOffset,!1);else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5],10)),s=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(s)&&isNaN(c))return l;n.indexOf("+")>-1?l.setHours(l.getHours()-s,l.getMinutes()-c):l.setHours(l.getHours()+s,l.getMinutes()+c),n=e.dateParse.toTimeZone(l,e.serverTimezoneOffset,!1)}null==e.serverTimezoneOffset&&(n=e.dateParse.addSelfOffset(n))}}return n},isJson:function(t){return"string"==typeof t[0]?t:e.parse.parseJson(t)},isGuid:function(e){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(e)},replacer:function(t,n){return e.isPlainObject(t)?e.parse.jsonReplacer(t,n):t instanceof Array?e.parse.arrayReplacer(t):t instanceof Date?e.parse.jsonReplacer({val:t},n).val:t},jsonReplacer:function(t,n){for(var a,r=0,i=Object.keys(t);r<i.length;r++){var o=i[r];if((a=t[o])instanceof Date){var l=a;null==e.serverTimezoneOffset?t[o]=e.dateParse.toTimeZone(l,null).toJSON():(l=new Date(+l+36e5*e.serverTimezoneOffset),t[o]=e.dateParse.toTimeZone(e.dateParse.addSelfOffset(l),null).toJSON())}}return t},arrayReplacer:function(t){for(var n=0;n<t.length;n++)e.isPlainObject(t[n])?t[n]=e.parse.jsonReplacer(t[n]):t[n]instanceof Date&&(t[n]=e.parse.jsonReplacer({date:t[n]}).date);return t},jsonDateReplacer:function(t,n){if("value"===t&&n){if("string"==typeof n){var a=/^\/Date\(([+-]?[0-9]+)([+-][0-9]{4})?\)\/$/.exec(n);if(a)n=e.dateParse.toTimeZone(new Date(parseInt(a[1],10)),null,!0);else if(/^(\d{4}\-\d\d\-\d\d([tT][\d:\.]*){1})([zZ]|([+\-])(\d\d):?(\d\d))?$/.test(n)){var r=n.split(/[^0-9]/);n=e.dateParse.toTimeZone(new Date(parseInt(r[0],10),parseInt(r[1],10)-1,parseInt(r[2],10),parseInt(r[3],10),parseInt(r[4],10),parseInt(r[5],10)),null,!0)}}if(n instanceof Date)return n=e.dateParse.addSelfOffset(n),null===e.serverTimezoneOffset?e.dateParse.toTimeZone(e.dateParse.addSelfOffset(n),null).toJSON():(n=e.dateParse.toTimeZone(n,n.getTimezoneOffset()/60*2-e.serverTimezoneOffset,!1)).toJSON()}return n}},e.dateParse={addSelfOffset:function(e){return new Date(+e-6e4*e.getTimezoneOffset())},toUTC:function(e){return new Date(+e+6e4*e.getTimezoneOffset())},toTimeZone:function(t,n,a){if(null===n)return t;var r=a?e.dateParse.toUTC(t):t;return new Date(+r-36e5*n)},toLocalTime:function(e){var t=e,n=-t.getTimezoneOffset(),a=n>=0?"+":"-",r=function(e){var t=Math.floor(Math.abs(e));return(t<10?"0":"")+t};return t.getFullYear()+"-"+r(t.getMonth()+1)+"-"+r(t.getDate())+"T"+r(t.getHours())+":"+r(t.getMinutes())+":"+r(t.getSeconds())+a+r(n/60)+":"+r(n%60)}},e}(),swt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),cwt={GroupGuid:"{271bbba0-1ee7}"},dwt=function(){function e(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=e,this.dataSource=t,this.pvt={}}return e.prototype.processResponse=function(e,t,n,a){return e},e}(),hwt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return swt(t,e),t.prototype.processQuery=function(e,t){for(var n,a,r,i=e.dataSource.json.slice(0),o=i.length,l=!0,s={},c=0,d=[],h=0;h<t.lazyLoad.length;h++)c++,s[t.lazyLoad[h].key]=t.lazyLoad[h].value;var u={};for(h=0;h<t.queries.length;h++)"onPage"!==(a=t.queries[h]).fn&&"onGroup"!==a.fn||!t.lazyLoad.length?(n=this[a.fn].call(this,i,a.e,t),"onAggregates"===a.fn?u[a.e.field+" - "+a.e.type]=n:i=void 0!==n?n:i,"onPage"!==a.fn&&"onSkip"!==a.fn&&"onTake"!==a.fn&&"onRange"!==a.fn||(l=!1),l&&(o=i.length)):("onGroup"===a.fn&&d.push(a.e),"onPage"===a.fn&&(r=a.e));if(c){var p={query:t,lazyLoad:s,result:i,group:d,page:r},f=this.lazyLoadGroup(p);i=f.result,o=f.count}return t.isCountRequired&&(i={result:i,count:o,aggregates:u}),i},t.prototype.lazyLoadGroup=function(e){var t=0,n=this.getAggregate(e.query),a=e.result;if(xpt(e.lazyLoad.onDemandGroupInfo)){o=e.group[0].fieldName;t=(a=lwt.group(a,o,n,null,null,e.group[0].comparer,!0)).length;l=a;e.page&&(a=this.onPage(a,e.page,e.query)),this.formGroupResult(a,l)}else{for(var r=e.lazyLoad.onDemandGroupInfo,i=r.where.length-1;i>=0;i--)a=this.onWhere(a,r.where[i]);if(e.group.length!==r.level){var o=e.group[r.level].fieldName;a=lwt.group(a,o,n,null,null,e.group[0].comparer,!0)}t=a.length;var l=a;a=(a=a.slice(r.skip)).slice(0,r.take),e.group.length!==r.level&&this.formGroupResult(a,l)}return{result:a,count:t}},t.prototype.formGroupResult=function(e,t){if(e.length&&t.length){var n="GroupGuid",a="childLevels",r="level",i="records";e[n]=t[n],e[a]=t[a],e[r]=t[r],e[i]=t[i]}return e},t.prototype.getAggregate=function(e){var t=rwt.filterQueries(e.queries,"onAggregates"),n=[];if(t.length)for(var a=void 0,r=0;r<t.length;r++)a=t[r].e,n.push({type:a.type,field:lwt.getValue(a.field,e)});return n},t.prototype.batchRequest=function(e,t,n){var a,r=t.deletedRecords.length;for(a=0;a<t.addedRecords.length;a++)this.insert(e,t.addedRecords[a]);for(a=0;a<t.changedRecords.length;a++)this.update(e,n.key,t.changedRecords[a]);for(a=0;a<r;a++)this.remove(e,n.key,t.deletedRecords[a]);return t},t.prototype.onWhere=function(e,t){return e&&e.length?e.filter(function(e){if(t)return t.validate(e)}):e},t.prototype.onAggregates=function(e,t){var n=lwt.aggregates[t.type];return e&&n&&0!==e.length?n(e,t.field):null},t.prototype.onSearch=function(e,t){return e&&e.length?(0===t.fieldNames.length&&lwt.getFieldList(e[0],t.fieldNames),e.filter(function(e){for(var n=0;n<t.fieldNames.length;n++)if(t.comparer.call(e,lwt.getObject(t.fieldNames[n],e),t.searchKey,t.ignoreCase,t.ignoreAccent))return!0;return!1})):e},t.prototype.onSortBy=function(e,t,n){if(!e||!e.length)return e;var a,r=lwt.getValue(t.fieldName,n);if(!r)return e.sort(t.comparer);if(r instanceof Array){for(var i=(r=r.slice(0)).length-1;i>=0;i--)r[i]&&(a=t.comparer,lwt.endsWith(r[i]," desc")&&(a=lwt.fnSort("descending"),r[i]=r[i].replace(" desc","")),e=lwt.sort(e,r[i],a));return e}return lwt.sort(e,r,t.comparer)},t.prototype.onGroup=function(e,t,n){if(!e||!e.length)return e;var a=this.getAggregate(n);return lwt.group(e,lwt.getValue(t.fieldName,n),a,null,null,t.comparer)},t.prototype.onPage=function(e,t,n){var a=lwt.getValue(t.pageSize,n),r=(lwt.getValue(t.pageIndex,n)-1)*a,i=r+a;return e&&e.length?e.slice(r,i):e},t.prototype.onRange=function(e,t){return e&&e.length?e.slice(lwt.getValue(t.start),lwt.getValue(t.end)):e},t.prototype.onTake=function(e,t){return e&&e.length?e.slice(0,lwt.getValue(t.nos)):e},t.prototype.onSkip=function(e,t){return e&&e.length?e.slice(lwt.getValue(t.nos)):e},t.prototype.onSelect=function(e,t){return e&&e.length?lwt.select(e,lwt.getValue(t.fieldNames)):e},t.prototype.insert=function(e,t,n,a,r){return xpt(r)?e.dataSource.json.push(t):e.dataSource.json.splice(r,0,t)},t.prototype.remove=function(e,t,n,a){var r,i=e.dataSource.json;for("object"!=typeof n||n instanceof Date||(n=lwt.getObject(t,n)),r=0;r<i.length&&lwt.getObject(t,i[r])!==n;r++);return r!==i.length?i.splice(r,1):null},t.prototype.update=function(e,t,n,a){var r,i,o=e.dataSource.json;for(xpt(t)||(i=fpt(t,n)),r=0;r<o.length&&(xpt(t)||fpt(t,o[r])!==i);r++);return r<o.length?ypt(o[r],n):null},t}(dwt),uwt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return swt(t,e),t.prototype.processQuery=function(e,t,n){var a,r,i=this.getQueryRequest(t),o=rwt.filterQueryLists(t.queries,["onSelect","onPage","onSkip","onTake","onRange"]),l=t.params,s=e.dataSource.url,c=null,d=this.options,h={sorts:[],groups:[],filters:[],searches:[],aggregates:[]};"onPage"in o?(a=o.onPage,r=((r=lwt.getValue(a.pageIndex,t))-1)*(c=lwt.getValue(a.pageSize,t))):"onRange"in o&&(r=(a=o.onRange).start,c=a.end-a.start);for(var u=0;u<i.sorts.length;u++)a=lwt.getValue(i.sorts[u].e.fieldName,t),h.sorts.push(lwt.callAdaptorFunction(this,"onEachSort",{name:a,direction:i.sorts[u].e.direction},t));n&&(a=this.getFiltersFrom(n,t))&&h.filters.push(lwt.callAdaptorFunction(this,"onEachWhere",a.toJson(),t));for(u=0;u<i.filters.length;u++){var p=lwt.callAdaptorFunction(this,"onEachWhere",i.filters[u].e.toJson(),t);this.getModuleName&&"ODataV4Adaptor"===this.getModuleName()&&!xpt(i.filters[u].e.key)&&i.filters.length>1&&(p="("+p+")"),h.filters.push(p);for(var f=0,m="object"==typeof h.filters[u]?Object.keys(h.filters[u]):[];f<m.length;f++){var v=m[f];lwt.isNull(h[v])&&delete h[v]}}for(u=0;u<i.searches.length;u++)a=i.searches[u].e,h.searches.push(lwt.callAdaptorFunction(this,"onEachSearch",{fields:a.fieldNames,operator:a.operator,key:a.searchKey,ignoreCase:a.ignoreCase},t));for(u=0;u<i.groups.length;u++)h.groups.push(lwt.getValue(i.groups[u].e.fieldName,t));for(u=0;u<i.aggregates.length;u++)a=i.aggregates[u].e,h.aggregates.push({type:a.type,field:lwt.getValue(a.field,t)});var g={};if(this.getRequestQuery(d,t,o,h,g),lwt.callAdaptorFunction(this,"addParams",{dm:e,query:t,params:l,reqParams:g}),t.lazyLoad.length)for(u=0;u<t.lazyLoad.length;u++)g[t.lazyLoad[u].key]=t.lazyLoad[u].value;for(var w=0,y=Object.keys(g);w<y.length;w++){v=y[w];(lwt.isNull(g[v])||""===g[v]||0===g[v].length)&&delete g[v]}d.skip in g&&d.take in g||null===c||(g[d.skip]=lwt.callAdaptorFunction(this,"onSkip",r,t),g[d.take]=lwt.callAdaptorFunction(this,"onTake",c,t));var b=this.pvt;return this.pvt={},"json"===this.options.requestType?{data:JSON.stringify(g,lwt.parse.jsonDateReplacer),url:s,pvtData:b,type:"POST",contentType:"application/json; charset=utf-8"}:(a=this.convertToQueryString(g,t,e),{type:"GET",url:(a=(-1!==e.dataSource.url.indexOf("?")?"&":"/")+a).length?s.replace(/\/*$/,a):s,pvtData:b})},t.prototype.getRequestQuery=function(e,t,n,a,r){var i=r;i[e.from]=t.fromTable,e.apply&&t.distincts.length&&(i[e.apply]="onDistinct"in this?lwt.callAdaptorFunction(this,"onDistinct",t.distincts):""),!t.distincts.length&&e.expand&&(i[e.expand]="onExpand"in this&&"onSelect"in n?lwt.callAdaptorFunction(this,"onExpand",{selects:lwt.getValue(n.onSelect.fieldNames,t),expands:t.expands},t):t.expands),i[e.select]="onSelect"in n&&!t.distincts.length?lwt.callAdaptorFunction(this,"onSelect",lwt.getValue(n.onSelect.fieldNames,t),t):"",i[e.count]=t.isCountRequired?lwt.callAdaptorFunction(this,"onCount",t.isCountRequired,t):"",i[e.search]=a.searches.length?lwt.callAdaptorFunction(this,"onSearch",a.searches,t):"",i[e.skip]="onSkip"in n?lwt.callAdaptorFunction(this,"onSkip",lwt.getValue(n.onSkip.nos,t),t):"",i[e.take]="onTake"in n?lwt.callAdaptorFunction(this,"onTake",lwt.getValue(n.onTake.nos,t),t):"",i[e.where]=a.filters.length||a.searches.length?lwt.callAdaptorFunction(this,"onWhere",a.filters,t):"",i[e.sortBy]=a.sorts.length?lwt.callAdaptorFunction(this,"onSortBy",a.sorts,t):"",i[e.group]=a.groups.length?lwt.callAdaptorFunction(this,"onGroup",a.groups,t):"",i[e.aggregates]=a.aggregates.length?lwt.callAdaptorFunction(this,"onAggregates",a.aggregates,t):"",i.param=[]},t.prototype.convertToQueryString=function(e,t,n){return""},t.prototype.processResponse=function(e,t,n,a,r,i){if(a&&a.getResponseHeader("Content-Type")&&-1!==a.getResponseHeader("Content-Type").indexOf("application/json")){var o=lwt.timeZoneHandling;t&&!t.timeZoneHandling&&(lwt.timeZoneHandling=!1),e=lwt.parse.parseJson(e),lwt.timeZoneHandling=o}var l=r,s=l.pvtData||{},c=e?e.groupDs:[];if(a&&a.getResponseHeader("Content-Type")&&-1!==a.getResponseHeader("Content-Type").indexOf("xml"))return n.isCountRequired?{result:[],count:0}:[];var d=JSON.parse(l.data);if(d&&"batch"===d.action&&e&&e.addedRecords)return i.addedRecords=e.addedRecords,i;e&&e.d&&(e=e.d);var h={};e&&"count"in e&&(h.count=e.count),h.result=e&&e.result?e.result:e;var u=!1;if(Array.isArray(e.result)&&e.result.length){if(xpt(e.result[0].key)||(h.result=this.formRemoteGroupedData(h.result,1,s.groups.length-1)),n&&n.lazyLoad.length&&s.groups.length)for(var p=0;p<n.lazyLoad.length;p++)if("onDemandGroupInfo"===n.lazyLoad[p].key){var f=n.lazyLoad[p].value.level;s.groups.length===f&&(u=!0)}}return u||this.getAggregateResult(s,e,h,c,n),lwt.isNull(h.count)?h.result:{result:h.result,count:h.count,aggregates:h.aggregates}},t.prototype.formRemoteGroupedData=function(e,t,n){for(var a=0;a<e.length;a++)e[a].items.length&&Object.keys(e[a].items[0]).indexOf("key")>-1&&this.formRemoteGroupedData(e[a].items,t+1,n-1);var r="GroupGuid",i="records";return e[r]=cwt[r],e.level=t,e.childLevels=n,e[i]=e[0].items.length?this.getGroupedRecords(e,!xpt(e[0].items[i])):[],e},t.prototype.getGroupedRecords=function(e,t){for(var n=[],a=0;a<e.length;a++)if(t)n=n.concat(e[a].items.records);else for(var r=0;r<e[a].items.length;r++)n.push(e[a].items[r]);return n},t.prototype.onGroup=function(e){return this.pvt.groups=e,e},t.prototype.onAggregates=function(e){this.pvt.aggregates=e},t.prototype.batchRequest=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.batchUrl||e.dataSource.crudUrl||e.dataSource.removeUrl||e.dataSource.url,contentType:"application/json; charset=utf-8",dataType:"json",data:JSON.stringify(bpt({},{changed:t.changedRecords,added:t.addedRecords,deleted:t.deletedRecords,action:"batch",table:n[undefined],key:n[undefined]},lwt.getAddParams(this,e,a)))}},t.prototype.beforeSend=function(e,t){},t.prototype.insert=function(e,t,n,a){return{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:t,table:n,action:"insert"},lwt.getAddParams(this,e,a)))}},t.prototype.remove=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{key:n,keyColumn:t,table:a,action:"remove"},lwt.getAddParams(this,e,r)))}},t.prototype.update=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:n,action:"update",keyColumn:t,key:lwt.getObject(t,n),table:a},lwt.getAddParams(this,e,r)))}},t.prototype.getFiltersFrom=function(e,t){var n,a=t.fKey,r=a,i=t.key,o=[];"object"!=typeof e[0]&&(r=null);for(var l=0;l<e.length;l++)n="object"==typeof e[0]?lwt.getObject(i||r,e[l]):e[l],o.push(new iwt(a,"equal",n));return iwt.or(o)},t.prototype.getAggregateResult=function(e,t,n,a,r){var i=t;if(t&&t.result&&(i=t.result),e&&e.aggregates&&e.aggregates.length){var o=e.aggregates,l=void 0,s=i,c={};t.aggregate&&(s=t.aggregate);for(var d=0;d<o.length;d++)(l=lwt.aggregates[o[d].type])&&(c[o[d].field+" - "+o[d].type]=l(s,o[d].field));n.aggregates=c}var h=Array.isArray(t.result)&&t.result.length&&!xpt(t.result[0].key);if(e&&e.groups&&e.groups.length&&!h){var u=e.groups;for(d=0;d<u.length;d++){xpt(a)||(a=lwt.group(a,u[d]));var p=rwt.filterQueries(r.queries,"onGroup")[d].e;i=lwt.group(i,u[d],e.aggregates,null,a,p.comparer)}n.result=i}return n},t.prototype.getQueryRequest=function(e){var t={sorts:[],groups:[],filters:[],searches:[],aggregates:[]};return t.sorts=rwt.filterQueries(e.queries,"onSortBy"),t.groups=rwt.filterQueries(e.queries,"onGroup"),t.filters=rwt.filterQueries(e.queries,"onWhere"),t.searches=rwt.filterQueries(e.queries,"onSearch"),t.aggregates=rwt.filterQueries(e.queries,"onAggregates"),t},t.prototype.addParams=function(e){var t=e.reqParams;e.params.length&&(t.params={});for(var n=0,a=e.params;n<a.length;n++){var r=a[n];if(t[r.key])throw new Error("Query() - addParams: Custom Param is conflicting other request arguments");t[r.key]=r.value,r.fn&&(t[r.key]=r.fn.call(e.query,r.key,e.query,e.dm)),t.params[r.key]=t[r.key]}},t}(dwt),pwt=function(e){function t(t){var n=e.call(this)||this;return n.options=bpt({},n.options,{requestType:"get",accept:"application/json;odata=light;q=1,application/json;odata=verbose;q=0.5",multipartAccept:"multipart/mixed",sortBy:"$orderby",select:"$select",skip:"$skip",take:"$top",count:"$inlinecount",where:"$filter",expand:"$expand",batch:"$batch",changeSet:"--changeset_",batchPre:"batch_",contentId:"Content-Id: ",batchContent:"Content-Type: multipart/mixed; boundary=",changeSetContent:"Content-Type: application/http\nContent-Transfer-Encoding: binary ",batchChangeSetContentType:"Content-Type: application/json; charset=utf-8 ",updateType:"PUT"}),bpt(n.options,t||{}),n}return swt(t,e),t.prototype.getModuleName=function(){return"ODataAdaptor"},t.prototype.onPredicate=function(e,n,a){var r,i,o="",l=e.value,s=typeof l,c=e.field?t.getField(e.field):null;if(l instanceof Date&&(l="datetime'"+lwt.parse.replacer(l)+"'"),"string"===s&&(l=l.replace(/'/g,"''"),e.ignoreCase&&(l=l.toLowerCase()),l="'"+(l=encodeURIComponent(l))+"'",a&&(c="cast("+c+", 'Edm.String')"),lwt.parse.isGuid(l)&&(i="guid"),e.ignoreCase&&(i||(c="tolower("+c+")"),l=l.toLowerCase())),r=lwt.odBiOperator[e.operator])return o+=c,o+=r,i&&(o+=i),o+l;if("substringof"===(r=xpt(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?lwt.odUniOperator[e.operator]:lwt.odv4UniOperator[e.operator])){var d=l;l=c,c=d}return o+=r+"(",o+=c+",",i&&(o+=i),o+=l+")"},t.prototype.addParams=function(t){e.prototype.addParams.call(this,t),delete t.reqParams.params},t.prototype.onComplexPredicate=function(e,t,n){for(var a=[],r=0;r<e.predicates.length;r++)a.push("("+this.onEachWhere(e.predicates[r],t,n)+")");return a.join(" "+e.condition+" ")},t.prototype.onEachWhere=function(e,t,n){return e.isComplex?this.onComplexPredicate(e,t,n):this.onPredicate(e,t,n)},t.prototype.onWhere=function(e){return this.pvt.search&&e.push(this.onEachWhere(this.pvt.search,null,!0)),e.join(" and ")},t.prototype.onEachSearch=function(e){e.fields&&0===e.fields.length&&lwt.throwError("Query() - Search : oData search requires list of field names to search");for(var t=this.pvt.search||[],n=0;n<e.fields.length;n++)t.push(new iwt(e.fields[n],e.operator,e.key,e.ignoreCase));this.pvt.search=t},t.prototype.onSearch=function(e){return this.pvt.search=iwt.or(this.pvt.search),""},t.prototype.onEachSort=function(e){var n=[];if(e.name instanceof Array)for(var a=0;a<e.name.length;a++)n.push(t.getField(e.name[a])+("descending"===e.direction?" desc":""));else n.push(t.getField(e.name)+("descending"===e.direction?" desc":""));return n.join(",")},t.prototype.onSortBy=function(e){return e.reverse().join(",")},t.prototype.onGroup=function(e){return this.pvt.groups=e,[]},t.prototype.onSelect=function(e){for(var n=0;n<e.length;n++)e[n]=t.getField(e[n]);return e.join(",")},t.prototype.onAggregates=function(e){return this.pvt.aggregates=e,""},t.prototype.onCount=function(e){return!0===e?"allpages":""},t.prototype.beforeSend=function(e,t,n){lwt.endsWith(n.url,this.options.batch)&&"post"===n.type.toLowerCase()?(t.setRequestHeader("Accept",this.options.multipartAccept),t.setRequestHeader("DataServiceVersion","2.0"),t.overrideMimeType("text/plain; charset=x-user-defined")):t.setRequestHeader("Accept",this.options.accept),t.setRequestHeader("DataServiceVersion","2.0"),t.setRequestHeader("MaxDataServiceVersion","2.0")},t.prototype.processResponse=function(e,t,n,a,r,i){var o="odata.metadata";if(r&&"GET"===r.type&&!this.rootUrl&&e[o]){var l=e[o].split("/$metadata#");this.rootUrl=l[0],this.resourceTableName=l[1]}if(!xpt(e.d)){var s=n&&n.isCountRequired?e.d.results:e.d,c="__metadata";if(!xpt(s))for(var d=0;d<s.length;d++)xpt(s[d][c])||delete s[d][c]}var h=r&&r.pvtData,u=this.processBatchResponse(e,n,a,r,i);if(u)return u;var p=a&&r.getResponseHeader("DataServiceVersion"),f=null,m=p&&parseInt(p,10)||2;if(n&&n.isCountRequired){var v="__count";(e[v]||e["odata.count"])&&(f=e[v]||e["odata.count"]),e.d&&(e=e.d),(e[v]||e["odata.count"])&&(f=e[v]||e["odata.count"])}3===m&&e.value&&(e=e.value),e.d&&(e=e.d),m<3&&e.results&&(e=e.results);var g={};return g.count=f,g.result=e,this.getAggregateResult(h,e,g,null,n),lwt.isNull(f)?g.result:{result:g.result,count:g.count,aggregates:g.aggregates}},t.prototype.convertToQueryString=function(e,t,n){var a=[],r="table",i=e[r]||"";delete e[r],n.dataSource.requiresFormat&&(e.$format="json");for(var o=0,l=Object.keys(e);o<l.length;o++){var s=l[o];a.push(s+"="+e[s])}return a=a.join("&"),n.dataSource.url&&-1!==n.dataSource.url.indexOf("?")&&!i?a:a.length?i+"?"+a:i||""},t.prototype.localTimeReplacer=function(e,t){for(var n=0,a=xpt(t)?[]:Object.keys(t);n<a.length;n++){var r=a[n];t[r]instanceof Date&&(t[r]=lwt.dateParse.toLocalTime(t[r]))}return t},t.prototype.insert=function(e,t,n){return{url:(e.dataSource.insertUrl||e.dataSource.url).replace(/\/*$/,n?"/"+n:""),data:JSON.stringify(t,this.options.localTime?this.localTimeReplacer:null)}},t.prototype.remove=function(e,t,n,a){var r;return r="string"!=typeof n||lwt.parse.isGuid(n)?"("+n+")":"('"+n+"')",{type:"DELETE",url:(e.dataSource.removeUrl||e.dataSource.url).replace(/\/*$/,a?"/"+a:"")+r}},t.prototype.update=function(e,t,n,a,r,i){var o;return"PATCH"!==this.options.updateType||xpt(i)||(n=this.compareAndRemove(n,i,t)),o="string"!=typeof n[t]||lwt.parse.isGuid(n[t])?"("+n[t]+")":"('"+n[t]+"')",{type:this.options.updateType,url:(e.dataSource.updateUrl||e.dataSource.url).replace(/\/*$/,a?"/"+a:"")+o,data:JSON.stringify(n,this.options.localTime?this.localTimeReplacer:null),accept:this.options.accept}},t.prototype.batchRequest=function(e,t,n,a,r){var i=n.guid=lwt.getGuid(this.options.batchPre),o=this.rootUrl?this.rootUrl+"/"+this.options.batch:e.dataSource.url.replace(/\/*$/,"/"+this.options.batch);n.url=this.resourceTableName?this.resourceTableName:n.url;var l={url:n.url,key:n.key,cid:1,cSet:lwt.getGuid(this.options.changeSet)},s="--"+i+"\n";return s+="Content-Type: multipart/mixed; boundary="+l.cSet.replace("--","")+"\n",this.pvt.changeSet=0,s+=this.generateInsertRequest(t.addedRecords,l,e),s+=this.generateUpdateRequest(t.changedRecords,l,e,r?r.changedRecords:[]),s+=this.generateDeleteRequest(t.deletedRecords,l,e),s+=l.cSet+"--\n",{type:"POST",url:o,dataType:"json",contentType:"multipart/mixed; charset=UTF-8;boundary="+i,data:s+="--"+i+"--"}},t.prototype.generateDeleteRequest=function(e,t,n){if(!e)return"";var a={method:"DELETE ",url:function(e,t,n){var a=lwt.getObject(n,e[t]);return"number"==typeof a||lwt.parse.isGuid(a)?"("+a+")":a instanceof Date?"("+e[t][n].toJSON()+")":"('"+a+"')"},data:function(e,t){return""}};return this.generateBodyContent(e,t,a,n)+"\n"},t.prototype.generateInsertRequest=function(e,t,n){if(!e)return"";var a={method:"POST ",url:function(e,t,n){return""},data:function(e,t){return JSON.stringify(e[t])+"\n\n"}};return this.generateBodyContent(e,t,a,n)},t.prototype.generateUpdateRequest=function(e,t,n,a){var r=this;if(!e)return"";e.forEach(function(e){return e=r.compareAndRemove(e,a.filter(function(n){return lwt.getObject(t.key,n)===lwt.getObject(t.key,e)})[0],t.key)});var i={method:this.options.updateType+" ",url:function(e,t,n){return"number"==typeof e[t][n]||lwt.parse.isGuid(e[t][n])?"("+e[t][n]+")":e[t][n]instanceof Date?"("+e[t][n].toJSON()+")":"('"+e[t][n]+"')"},data:function(e,t){return JSON.stringify(e[t])+"\n\n"}};return this.generateBodyContent(e,t,i,n)},t.getField=function(e){return e.replace(/\./g,"/")},t.prototype.generateBodyContent=function(e,t,n,a){for(var r="",i=0;i<e.length;i++)r+="\n"+t.cSet+"\n",r+=this.options.changeSetContent+"\n\n",r+=n.method,"POST "===n.method?r+=(a.dataSource.insertUrl||a.dataSource.crudUrl||t.url)+n.url(e,i,t.key)+" HTTP/1.1\n":"PUT "===n.method||"PATCH "===n.method?r+=(a.dataSource.updateUrl||a.dataSource.crudUrl||t.url)+n.url(e,i,t.key)+" HTTP/1.1\n":"DELETE "===n.method&&(r+=(a.dataSource.removeUrl||a.dataSource.crudUrl||t.url)+n.url(e,i,t.key)+" HTTP/1.1\n"),r+="Accept: "+this.options.accept+"\n",r+="Content-Id: "+this.pvt.changeSet+++"\n",r+=this.options.batchChangeSetContentType+"\n",xpt(e[i]["@odata.etag"])?r+="\n":(r+="If-Match: "+e[i]["@odata.etag"]+"\n\n",delete e[i]["@odata.etag"]),r+=n.data(e,i);return r},t.prototype.processBatchResponse=function(e,t,n,a,r){if(n&&n.getResponseHeader("Content-Type")&&-1!==n.getResponseHeader("Content-Type").indexOf("xml"))return t.isCountRequired?{result:[],count:0}:[];if(a&&this.options.batch&&lwt.endsWith(a.url,this.options.batch)&&"post"===a.type.toLowerCase()){var i=n.getResponseHeader("Content-Type"),o=void 0,l=void 0,s=e+"";if(i=i.substring(i.indexOf("=batchresponse")+1),(s=s.split(i)).length<2)return{};s=s[1];var c=/(?:\bContent-Type.+boundary=)(changesetresponse.+)/i.exec(s);c&&s.replace(c[0],"");for(var d=c?c[1]:"",h=(s=s.split(d)).length;h>-1;h--)/\bContent-ID:/i.test(s[h])&&/\bHTTP.+201/.test(s[h])&&(o=parseInt(/\bContent-ID: (\d+)/i.exec(s[h])[1],10),r.addedRecords[o]&&(l=lwt.parse.parseJson(/^\{.+\}/m.exec(s[h])[0]),bpt({},r.addedRecords[o],this.processResponse(l))));return r}return null},t.prototype.compareAndRemove=function(e,t,n){var a=this;return xpt(t)||Object.keys(e).forEach(function(r){r!==n&&"@odata.etag"!==r&&(lwt.isPlainObject(e[r])?(a.compareAndRemove(e[r],t[r]),0===Object.keys(e[r]).filter(function(e){return"@odata.etag"!==e}).length&&delete e[r]):(e[r]===t[r]||e[r]&&t[r]&&e[r].valueOf()===t[r].valueOf())&&delete e[r])}),e},t}(uwt);!function(e){function t(t){var n=e.call(this,t)||this;return n.options=bpt({},n.options,{requestType:"get",accept:"application/json, text/javascript, */*; q=0.01",multipartAccept:"multipart/mixed",sortBy:"$orderby",select:"$select",skip:"$skip",take:"$top",count:"$count",search:"$search",where:"$filter",expand:"$expand",batch:"$batch",changeSet:"--changeset_",batchPre:"batch_",contentId:"Content-Id: ",batchContent:"Content-Type: multipart/mixed; boundary=",changeSetContent:"Content-Type: application/http\nContent-Transfer-Encoding: binary ",batchChangeSetContentType:"Content-Type: application/json; charset=utf-8 ",updateType:"PATCH",localTime:!1,apply:"$apply"}),bpt(n.options,t||{}),n}swt(t,e),t.prototype.getModuleName=function(){return"ODataV4Adaptor"},t.prototype.onCount=function(e){return!0===e?"true":""},t.prototype.onPredicate=function(t,n,a){var r="",i=t.value,o=i instanceof Date;if(n instanceof rwt)for(var l=this.getQueryRequest(n),s=0;s<l.filters.length;s++)l.filters[s].e.key===t.value&&(a=!0);return r=e.prototype.onPredicate.call(this,t,n,a),o&&(r=r.replace(/datetime'(.*)'$/,"$1")),lwt.parse.isGuid(i)&&(r=r.replace("guid","").replace(/'/g,"")),r},t.prototype.onEachSearch=function(e){var t=this.pvt.searches||[];t.push(e.key),this.pvt.searches=t},t.prototype.onSearch=function(e){return this.pvt.searches.join(" OR ")},t.prototype.onExpand=function(e){var t=this,n={},a={},r=e.expands.slice(),i=[];return e.selects.filter(function(e){return e.indexOf(".")>-1}).forEach(function(e){var a=e.split(".");if(a[0]in n||(n[a[0]]=[]),2==a.length)n[a[0]].length&&-1!==Object.keys(n).indexOf(a[0])?-1!==n[a[0]][0].indexOf("$expand")&&-1===n[a[0]][0].indexOf(";$select=")?n[a[0]][0]=n[a[0]][0]+";$select="+a[1]:n[a[0]][0]=n[a[0]][0]+","+a[1]:n[a[0]].push("$select="+a[1]);else{for(var r="$select="+a[a.length-1],i="",o="",l=1;l<a.length-1;l++)i=i+"$expand="+a[l]+"(",o+=")";var s=i+r+o;if(n[a[0]].length&&-1!==Object.keys(n).indexOf(a[0])&&t.expandQueryIndex(n[a[0]],!0)){var c=t.expandQueryIndex(n[a[0]]);n[a[0]][c]=n[a[0]][c]+s.replace("$expand=",",")}else n[a[0]].push(s)}}),Object.keys(n).forEach(function(e){-1===r.indexOf(e)&&r.push(e)}),r.forEach(function(e){a[e]=e in n?e+"("+n[e].join(";")+")":e}),Object.keys(a).forEach(function(e){return i.push(a[e])}),i.join(",")},t.prototype.expandQueryIndex=function(e,t){for(var n=0;n<e.length;n++)if(-1!==e[n].indexOf("$expand"))return!!t||n;return!t&&0},t.prototype.onDistinct=function(e){return"groupby(("+e.map(function(e){return pwt.getField(e)}).join(",")+"))"},t.prototype.onSelect=function(t){return e.prototype.onSelect.call(this,t.filter(function(e){return-1===e.indexOf(".")}))},t.prototype.beforeSend=function(e,t,n){"POST"!==n.type&&"PUT"!==n.type&&"PATCH"!==n.type||t.setRequestHeader("Prefer","return=representation"),t.setRequestHeader("Accept",this.options.accept)},t.prototype.processResponse=function(t,n,a,r,i,o){var l="@odata.context";if(i&&"GET"===i.type&&!this.rootUrl&&t[l]){var s=t[l].split("/$metadata#");this.rootUrl=s[0],this.resourceTableName=s[1]}var c=i&&i.pvtData,d=e.prototype.processBatchResponse.call(this,t,a,r,i,o);if(d)return d;var h=null,u="@odata.count";a&&a.isCountRequired&&u in t&&(h=t[u]),t=xpt(t.value)?t:t.value;var p={};return p.count=h,p.result=t,this.getAggregateResult(c,t,p,null,a),lwt.isNull(h)?p.result:{result:p.result,count:h,aggregates:p.aggregates}}}(pwt),function(e){function t(){return null!==e&&e.apply(this,arguments)||this}swt(t,e),t.prototype.getModuleName=function(){return"WebApiAdaptor"},t.prototype.insert=function(e,t,n){return{type:"POST",url:e.dataSource.url,data:JSON.stringify(t)}},t.prototype.remove=function(e,t,n,a){return{type:"DELETE",url:e.dataSource.url+"/"+n,data:JSON.stringify(n)}},t.prototype.update=function(e,t,n,a){return{type:"PUT",url:e.dataSource.url,data:JSON.stringify(n)}},t.prototype.batchRequest=function(e,t,n){var a=this,r=n.guid=lwt.getGuid(this.options.batchPre),i=e.dataSource.url.replace(/\/*$/,"/"+this.options.batch);n.url=this.resourceTableName?this.resourceTableName:n.url;for(var o=[],l=function(a,i){t.addedRecords.forEach(function(i,l){var s=function(e,t,n){return""};o.push("--"+r),o.push("Content-Type: application/http; msgtype=request",""),o.push("POST /api/"+(e.dataSource.insertUrl||e.dataSource.crudUrl||n.url)+s(t.addedRecords,a,n.key)+" HTTP/1.1"),o.push("Content-Type: application/json; charset=utf-8"),o.push("Host: "+location.host),o.push("",i?JSON.stringify(i):"")})},s=0,c=t.addedRecords.length;s<c;s++)l(s);var d=function(i,l){t.changedRecords.forEach(function(l,s){a.options.updateType;var c=function(e,t,n){return""};o.push("--"+r),o.push("Content-Type: application/http; msgtype=request",""),o.push("PUT /api/"+(e.dataSource.updateUrl||e.dataSource.crudUrl||n.url)+c(t.changedRecords,i,n.key)+" HTTP/1.1"),o.push("Content-Type: application/json; charset=utf-8"),o.push("Host: "+location.host),o.push("",l?JSON.stringify(l):"")})};for(s=0,c=t.changedRecords.length;s<c;s++)d(s);var h=function(a,i){t.deletedRecords.forEach(function(i,l){var s=function(e,t,n){var a=lwt.getObject(n,e[t]);return"number"==typeof a||lwt.parse.isGuid(a)?"/"+a:a instanceof Date?"/"+e[t][n].toJSON():"/'"+a+"'"};o.push("--"+r),o.push("Content-Type: application/http; msgtype=request",""),o.push("DELETE /api/"+(e.dataSource.removeUrl||e.dataSource.crudUrl||n.url)+s(t.deletedRecords,a,n.key)+" HTTP/1.1"),o.push("Content-Type: application/json; charset=utf-8"),o.push("Host: "+location.host),o.push("",i?JSON.stringify(i):"")})};for(s=0,c=t.deletedRecords.length;s<c;s++)h(s);return o.push("--"+r+"--",""),{type:"POST",url:i,contentType:"multipart/mixed; boundary="+r,data:o.join("\r\n")}},t.prototype.beforeSend=function(e,t,n){t.setRequestHeader("Accept","application/json, text/javascript, */*; q=0.01")},t.prototype.processResponse=function(e,t,n,a,r,i){var o=r&&r.pvtData,l=null,s={};if(r&&"post"!==r.type.toLowerCase()){var c=a&&r.getResponseHeader("DataServiceVersion"),d=c&&parseInt(c,10)||2;n&&n.isCountRequired&&(lwt.isNull(e.Count)||(l=e.Count)),d<3&&e.Items&&(e=e.Items),s.count=l,s.result=e,this.getAggregateResult(o,e,s,null,n)}return s.result=s.result||e,lwt.isNull(l)?s.result:{result:s.result,count:s.count,aggregates:s.aggregates}}}(pwt),function(e){function t(){return null!==e&&e.apply(this,arguments)||this}swt(t,e),t.prototype.processQuery=function(e,t,n){var a=(new uwt).processQuery(e,t,n),r=lwt.parse.parseJson(a.data),i={};if(r.param)for(var o=0;o<r.param.length;o++){var l=r.param[o],s=Object.keys(l)[0];i[s]=l[s]}i.value=r;return{data:JSON.stringify(i),url:a.url,pvtData:a.pvtData,type:"POST",contentType:"application/json; charset=utf-8"}}}(uwt);var fwt=function(e){function t(){var t=e.call(this)||this;return mpt("beforeSend",uwt.prototype.beforeSend,t),t}return swt(t,e),t.prototype.insert=function(e,t,n,a,r){return this.pvt.position=r,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:t,table:n,action:"insert"},lwt.getAddParams(this,e,a)))}},t.prototype.remove=function(t,n,a,r,i){return e.prototype.remove.call(this,t,n,a),{type:"POST",url:t.dataSource.removeUrl||t.dataSource.crudUrl||t.dataSource.url,data:JSON.stringify(bpt({},{key:a,keyColumn:n,table:r,action:"remove"},lwt.getAddParams(this,t,i)))}},t.prototype.update=function(e,t,n,a,r){return this.updateType="update",this.updateKey=t,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(bpt({},{value:n,action:"update",keyColumn:t,key:n[t],table:a},lwt.getAddParams(this,e,r)))}},t.prototype.processResponse=function(t,n,a,r,i,o,l){var s;if(t="batch"===(i?JSON.parse(i.data):t).action?lwt.parse.parseJson(t):t,"add"===this.updateType&&e.prototype.insert.call(this,n,t,null,null,this.pvt.position),"update"===this.updateType&&e.prototype.update.call(this,n,this.updateKey,t),this.updateType=void 0,t.added)for(s=0;s<t.added.length;s++)e.prototype.insert.call(this,n,t.added[s]);if(t.changed)for(s=0;s<t.changed.length;s++)e.prototype.update.call(this,n,l.key,t.changed[s]);if(t.deleted)for(s=0;s<t.deleted.length;s++)e.prototype.remove.call(this,n,l.key,t.deleted[s]);return t},t.prototype.batchRequest=function(e,t,n,a,r){return{type:"POST",url:e.dataSource.batchUrl||e.dataSource.crudUrl||e.dataSource.url,contentType:"application/json; charset=utf-8",dataType:"json",data:JSON.stringify(bpt({},{changed:t.changedRecords,added:t.addedRecords,deleted:t.deletedRecords,action:"batch",table:n.url,key:n.key},lwt.getAddParams(this,e,a)))}},t.prototype.addParams=function(e){(new uwt).addParams(e)},t}(hwt),mwt=function(e){function t(t){var n=e.call(this)||this;return n.options=bpt({},n.options,{getData:new Function,addRecord:new Function,updateRecord:new Function,deleteRecord:new Function,batchUpdate:new Function}),bpt(n.options,t||{}),n}return swt(t,e),t.prototype.getModuleName=function(){return"CustomDataAdaptor"},t}(uwt);!function(e){function t(t){var n=e.call(this)||this;return n.opt=t,n.schema=n.opt.response,n.query=n.opt.query,n.getVariables=n.opt.getVariables?n.opt.getVariables:function(){},n.getQuery=function(){return n.query},n}swt(t,e),t.prototype.getModuleName=function(){return"GraphQLAdaptor"},t.prototype.processQuery=function(t,n){var a=e.prototype.processQuery.apply(this,arguments),r=JSON.parse(a.data),i={};["skip","take","sorted","table","select","where","search","requiresCounts","aggregates","params"].filter(function(e){i[e]="searchwhereparams".indexOf(e)>-1?JSON.stringify(r[e]):r[e]});var o=this.getVariables()||{};o.datamanager=i;var l=JSON.stringify({query:this.getQuery(),variables:o});return a.data=l,a},t.prototype.processResponse=function(e,t,n,a,r){var i,o,l=e,s=fpt(this.schema.result,l.data);this.schema.count&&(i=fpt(this.schema.count,l.data)),this.schema.aggregates&&(o=xpt(o=fpt(this.schema.aggregates,l.data))?o:lwt.parse.parseJson(o));var c=r.pvtData||{},d={result:s,aggregates:o},h=d;return c&&c.groups&&c.groups.length&&this.getAggregateResult(c,h,d,null,n),xpt(i)?d.result:{result:d.result,count:i,aggregates:o}},t.prototype.insert=function(){var t=e.prototype.insert.apply(this,arguments);return this.generateCrudData(t,"insert")},t.prototype.update=function(){var t=e.prototype.update.apply(this,arguments);return this.generateCrudData(t,"update")},t.prototype.remove=function(){var t=e.prototype.remove.apply(this,arguments);return this.generateCrudData(t,"remove")},t.prototype.batchRequest=function(t,n,a,r,i){var o=e.prototype.batchRequest.apply(this,arguments),l=JSON.parse(o.data);return l.key=a.key,o.data=JSON.stringify(l),this.generateCrudData(o,"batch")},t.prototype.generateCrudData=function(e,t){var n=JSON.parse(e.data);return e.data=JSON.stringify({query:this.opt.getMutation(t),variables:n}),e}}(uwt);var vwt,gwt=function(e){function t(t,n,a){var r=e.call(this)||this;r.isCrudAction=!1,r.isInsertAction=!1,xpt(t)||(r.cacheAdaptor=t),r.pageSize=a,r.guidId=lwt.getGuid("cacheAdaptor");window.localStorage.setItem(r.guidId,JSON.stringify({keys:[],results:[]}));var i=r.guidId;return xpt(n)||setInterval(function(){var e;e=lwt.parse.parseJson(window.localStorage.getItem(i));for(var t=[],a=0;a<e.results.length;a++){var r=+new Date,o=+new Date(e.results[a].timeStamp);e.results[a].timeStamp=r-o,r-o>n&&t.push(a)}for(a=0;a<t.length;a++)e.results.splice(t[a],1),e.keys.splice(t[a],1);window.localStorage.removeItem(i),window.localStorage.setItem(i,JSON.stringify(e))},n),r}return swt(t,e),t.prototype.generateKey=function(e,t){var n=this.getQueryRequest(t),a=rwt.filterQueryLists(t.queries,["onSelect","onPage","onSkip","onTake","onRange"]),r=e,i="onPage";i in a&&(r+=a[i].pageIndex),n.sorts.forEach(function(e){r+=e.e.direction+e.e.fieldName}),n.groups.forEach(function(e){r+=e.e.fieldName}),n.searches.forEach(function(e){r+=e.e.searchKey});for(var o=0;o<n.filters.length;o++){var l=n.filters[o];if(l.e.isComplex){var s=t.clone();s.queries=[];for(var c=0;c<l.e.predicates.length;c++)s.queries.push({fn:"onWhere",e:l.e.predicates[c],filter:t.queries.filter});r+=l.e.condition+this.generateKey(e,s)}else r+=l.e.field+l.e.operator+l.e.value}return r},t.prototype.processQuery=function(e,t,n){var a,r=this.generateKey(e.dataSource.url,t),i=(a=lwt.parse.parseJson(window.localStorage.getItem(this.guidId)))?a.results[a.keys.indexOf(r)]:null;return null==i||this.isCrudAction||this.isInsertAction?(this.isCrudAction=null,this.isInsertAction=null,this.cacheAdaptor.processQuery.apply(this.cacheAdaptor,[].slice.call(arguments,0))):i},t.prototype.processResponse=function(e,t,n,a,r,i){if(this.isInsertAction||r&&this.cacheAdaptor.options.batch&&lwt.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase())return this.cacheAdaptor.processResponse(e,t,n,a,r,i);e=this.cacheAdaptor.processResponse.apply(this.cacheAdaptor,[].slice.call(arguments,0));var o=n?this.generateKey(t.dataSource.url,n):t.dataSource.url,l={},s=(l=lwt.parse.parseJson(window.localStorage.getItem(this.guidId))).keys.indexOf(o);for(-1!==s&&(l.results.splice(s,1),l.keys.splice(s,1)),l.results[l.keys.push(o)-1]={keys:o,result:e.result,timeStamp:new Date,count:e.count};l.results.length>this.pageSize;)l.results.splice(0,1),l.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(l)),e},t.prototype.beforeSend=function(e,t,n){!xpt(this.cacheAdaptor.options.batch)&&lwt.endsWith(n.url,this.cacheAdaptor.options.batch)&&"post"===n.type.toLowerCase()&&t.setRequestHeader("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||t.setRequestHeader("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,t,n,a){return this.isCrudAction=!0,this.cacheAdaptor.update(e,t,n,a)},t.prototype.insert=function(e,t,n){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,t,n)},t.prototype.remove=function(e,t,n,a){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,t,n,a)},t.prototype.batchRequest=function(e,t,n){return this.cacheAdaptor.batchRequest(e,t,n)},t}(uwt),wwt=function(){function e(e,t,n){var a,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.requests=[],e||this.dataSource||(e=[]),n=n||e.adaptor,e&&!1===e.timeZoneHandling&&(this.timeZoneHandling=e.timeZoneHandling),e instanceof Array?a={json:e,offline:!0}:"object"==typeof e?(e.json||(e.json=[]),a={url:e.url,insertUrl:e.insertUrl,removeUrl:e.removeUrl,updateUrl:e.updateUrl,crudUrl:e.crudUrl,batchUrl:e.batchUrl,json:e.json,headers:e.headers,accept:e.accept,data:e.data,timeTillExpiration:e.timeTillExpiration,cachingPageSize:e.cachingPageSize,enableCaching:e.enableCaching,requestType:e.requestType,key:e.key,crossDomain:e.crossDomain,jsonp:e.jsonp,dataType:e.dataType,offline:void 0!==e.offline?e.offline:!(e.adaptor instanceof fwt||e.adaptor instanceof mwt)&&!e.url,requiresFormat:e.requiresFormat}):lwt.throwError("DataManager: Invalid arguments"),void 0!==a.requiresFormat||lwt.isCors()||(a.requiresFormat=!!xpt(a.crossDomain)||a.crossDomain),void 0===a.dataType&&(a.dataType="json"),this.dataSource=a,this.defaultQuery=t,a.url&&a.offline&&!a.json.length?(this.isDataAvailable=!1,this.adaptor=n||new pwt,this.dataSource.offline=!1,this.ready=this.executeQuery(t||new rwt),this.ready.then(function(e){r.dataSource.offline=!0,r.isDataAvailable=!0,a.json=e.result,r.adaptor=new hwt})):this.adaptor=a.offline?new hwt:new pwt,!a.jsonp&&this.adaptor instanceof pwt&&(a.jsonp="callback"),this.adaptor=n||this.adaptor,a.enableCaching&&(this.adaptor=new gwt(this.adaptor,a.timeTillExpiration,a.cachingPageSize)),this}return e.prototype.setDefaultQuery=function(e){return this.defaultQuery=e,this},e.prototype.executeLocal=function(t){this.defaultQuery||t instanceof rwt||lwt.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||lwt.throwError("DataManager - executeLocal() : Json data is required to execute"),t=t||this.defaultQuery;var n=this.adaptor.processQuery(this,t);if(t.subQuery){var a=t.subQuery.fromTable,r=t.subQuery.lookups,i=t.isCountRequired?n.result:n;r&&r instanceof Array&&lwt.buildHierarchy(t.subQuery.fKey,a,i,r,t.subQuery.key);for(var o=0;o<i.length;o++)i[o][a]instanceof Array&&(i[o]=bpt({},{},i[o]),i[o][a]=this.adaptor.processResponse(t.subQuery.using(new e(i[o][a].slice(0))).executeLocal(),this,t))}return this.adaptor.processResponse(n,this,t)},e.prototype.executeQuery=function(t,n,a,r){var i=this,o="makeRequest";"function"==typeof t&&(r=a,a=n,n=t,t=null),t||(t=this.defaultQuery),t instanceof rwt||lwt.throwError("DataManager - executeQuery() : A query is required to execute");var l=new ywt,s={query:t};if(!this.dataSource.offline&&void 0!==this.dataSource.url&&""!==this.dataSource.url||!xpt(this.adaptor[o])||this.isCustomDataAdaptor(this.adaptor)){var c=this.adaptor.processQuery(this,t);xpt(this.adaptor[o])?!xpt(c.url)||this.isCustomDataAdaptor(this.adaptor)?this.makeRequest(c,l,s,t):(s=e.getDeferedArgs(t,c,s),l.resolve(s)):this.adaptor[o](c,l,s,t)}else e.nextTick(function(){var n=i.executeLocal(t);s=e.getDeferedArgs(t,n,s),l.resolve(s)});return(n||a)&&l.promise.then(n,a),r&&l.promise.then(r,r),l.promise},e.getDeferedArgs=function(e,t,n){return e.isCountRequired?(n.result=t.result,n.count=t.count,n.aggregates=t.aggregates):n.result=t,n},e.nextTick=function(e){(window.setImmediate||window.setTimeout)(e,0)},e.prototype.extendRequest=function(e,t,n){return bpt({},{type:"GET",dataType:this.dataSource.dataType,crossDomain:this.dataSource.crossDomain,jsonp:this.dataSource.jsonp,cache:!0,processData:!1,onSuccess:t,onFailure:n},e)},e.prototype.makeRequest=function(e,t,n,a){var r=this,i=!!a.subQuerySelector,o=function(e){n.error=e,t.reject(n)},l=function(e,a,r,i,o,l,s){n.xhr=r,n.count=a?parseInt(a.toString(),10):0,n.result=e,n.request=i,n.aggregates=l,n.actual=o,n.virtualSelectRecords=s,t.resolve(n)},s=function(e,t){var s=new ywt,c={parent:n};a.subQuery.isChild=!0;var d=r.adaptor.processQuery(r,a.subQuery,e?r.adaptor.processResponse(e):t),h=r.makeRequest(d,s,c,a.subQuery);return i||s.then(function(t){e&&(lwt.buildHierarchy(a.subQuery.fKey,a.subQuery.fromTable,e,t,a.subQuery.key),l(e,t.count,t.xhr))},o),h},c=this.extendRequest(e,function(e,t){if(r.isGraphQLAdaptor(r.adaptor)&&!xpt(e.errors))return o(e.errors);r.isCustomDataAdaptor(r.adaptor)&&(t=bpt({},r.ajaxReqOption,t)),-1===t.httpRequest.getResponseHeader("Content-Type").indexOf("xml")&&r.dateParse&&(e=lwt.parse.parseJson(e));var n=r.adaptor.processResponse(e,r,a,t.httpRequest,t),c=0,d=null,h=e.virtualSelectRecords;a.isCountRequired&&(c=n.count,d=n.aggregates,n=n.result),a.subQuery?i||s(n,t):l(n,c,t.httpRequest,t.type,e,d,h)},o);if(this.isCustomDataAdaptor(this.adaptor)){this.ajaxReqOption=c;var d=c;this.adaptor.options.getData({data:d.data,onSuccess:d.onSuccess,onFailure:d.onFailure})}else{var h=new lft(c);h.beforeSend=function(){r.beforeSend(h.httpRequest,h)},(c=h.send()).catch(function(e){return!0}),this.requests.push(h)}if(i){var u=a.subQuerySelector.call(this,{query:a.subQuery,parent:a});u&&u.length?Promise.all([c,s(null,u)]).then(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e[0],o=r.adaptor.processResponse(n[0],r,a,r.requests[0].httpRequest,r.requests[0]),s=0;a.isCountRequired&&(s=o.count,o=o.result);var c=r.adaptor.processResponse(n[1],r,a.subQuery,r.requests[1].httpRequest,r.requests[1]);s=0,a.subQuery.isCountRequired&&(s=c.count,c=c.result),lwt.buildHierarchy(a.subQuery.fKey,a.subQuery.fromTable,o,c,a.subQuery.key),i=!1,l(o,s,r.requests[0].httpRequest)}):i=!1}return c},e.prototype.beforeSend=function(e,t){this.adaptor.beforeSend(this,e,t);for(var n,a=this.dataSource.headers,r=0;a&&r<a.length;r++){n=[];for(var i=0,o=Object.keys(a[r]);i<o.length;i++){var l=o[i];n.push(l),e.setRequestHeader(l,a[r][l])}}},e.prototype.saveChanges=function(e,t,n,a,r){var i=this;n instanceof rwt&&(a=n,n=null);var o={url:n,key:t||this.dataSource.key},l=this.adaptor.batchRequest(this,e,o,a||new rwt,r),s="doAjaxRequest";if(this.dataSource.offline)return l;if(xpt(this.adaptor[s])){if(this.isCustomDataAdaptor(this.adaptor))return this.doAjaxRequest(l,this.adaptor.options.batchUpdate);var c=new ywt,d=new lft(l);return d.beforeSend=function(){i.beforeSend(d.httpRequest,d)},d.onSuccess=function(t,n){i.isGraphQLAdaptor(i.adaptor)&&(xpt(t.errors)||d.onFailure(JSON.stringify(t.errors))),c.resolve(i.adaptor.processResponse(t,i,null,n.httpRequest,n,e,o))},d.onFailure=function(e){c.reject([{error:e}])},d.send().catch(function(e){return!0}),c.promise}return this.adaptor[s](l)},e.prototype.insert=function(e,t,n,a){t instanceof rwt&&(n=t,t=null);var r=this.adaptor.insert(this,e,t,n,a),i="doAjaxRequest";return this.dataSource.offline?r:xpt(this.adaptor[i])?this.doAjaxRequest(r,this.adaptor.options.addRecord):this.adaptor[i](r)},e.prototype.remove=function(e,t,n,a){"object"==typeof t&&(t=lwt.getObject(e,t)),n instanceof rwt&&(a=n,n=null);var r=this.adaptor.remove(this,e,t,n,a),i="doAjaxRequest";if(this.dataSource.offline)return r;if(xpt(this.adaptor[i])){var o=this.adaptor.options.deleteRecord;return this.doAjaxRequest(r,o)}return this.adaptor[i](r)},e.prototype.update=function(e,t,n,a,r){n instanceof rwt&&(a=n,n=null);var i=this.adaptor.update(this,e,t,n,a,r),o="doAjaxRequest";if(this.dataSource.offline)return i;if(xpt(this.adaptor[o])){var l=this.adaptor.options.updateRecord;return this.doAjaxRequest(i,l)}return this.adaptor[o](i)},e.prototype.isCustomDataAdaptor=function(e){return this.adaptor.getModuleName&&"CustomDataAdaptor"===this.adaptor.getModuleName()},e.prototype.isGraphQLAdaptor=function(e){return this.adaptor.getModuleName&&"GraphQLAdaptor"===this.adaptor.getModuleName()},e.prototype.successFunc=function(e,t){if(this.isGraphQLAdaptor(this.adaptor)){var n=JSON.parse(e);xpt(n.errors)||this.failureFunc(JSON.stringify(n.errors))}this.isCustomDataAdaptor(this.adaptor)&&(t=bpt({},this.ajaxReqOption,t));try{lwt.parse.parseJson(e)}catch(t){e=[]}e=this.adaptor.processResponse(lwt.parse.parseJson(e),this,null,t.httpRequest,t),this.ajaxDeffered.resolve(e)},e.prototype.failureFunc=function(e){this.ajaxDeffered.reject([{error:e}])},e.prototype.doAjaxRequest=function(e,t){var n=this;if(e=bpt({},{type:"POST",contentType:"application/json; charset=utf-8",processData:!1},e),this.ajaxDeffered=new ywt,this.isCustomDataAdaptor(this.adaptor))this.ajaxReqOption=e,t.call(this,{data:e.data,onSuccess:this.successFunc.bind(this),onFailure:this.failureFunc.bind(this)});else{var a=new lft(e);a.beforeSend=function(){n.beforeSend(a.httpRequest,a)},a.onSuccess=this.successFunc.bind(this),a.onFailure=this.failureFunc.bind(this),a.send().catch(function(e){return!0})}return this.ajaxDeffered.promise},e}(),ywt=function(){var e=this;this.promise=new Promise(function(t,n){e.resolve=t,e.reject=n}),this.then=this.promise.then.bind(this.promise),this.catch=this.promise.catch.bind(this.promise)},bwt={li:"e-list-item",ul:"e-list-parent e-ul",group:"e-list-group-item",icon:"e-list-icon",text:"e-list-text",check:"e-list-check",checked:"e-checked",selected:"e-selected",expanded:"e-expanded",textContent:"e-text-content",hasChild:"e-has-child",level:"e-level",url:"e-list-url",collapsible:"e-icon-collapsible",disabled:"e-disabled",image:"e-list-img",iconWrapper:"e-icon-wrapper",anchorWrap:"e-anchor-wrap",navigable:"e-navigable"};function xwt(e,t){var n={};if(xpt(e)||"string"==typeof e||"number"==typeof e||!xpt(e.isHeader))return e;for(var a=0,r=Object.keys(t);a<r.length;a++){var i=t[r[a]],o=xpt(i)||"string"!=typeof i?void 0:fpt(i,e);xpt(o)||(n[i]=o)}return n}function Ewt(e){if(e)try{return document.querySelector(e)?pvt(document.querySelector(e).innerHTML.trim()):pvt(e)}catch(t){return pvt(e)}}!function(e){e.defaultMappedFields={id:"id",text:"text",url:"url",value:"value",isChecked:"isChecked",enabled:"enabled",expanded:"expanded",selected:"selected",iconCss:"iconCss",child:"child",isVisible:"isVisible",hasChildren:"hasChildren",tooltip:"tooltip",htmlAttributes:"htmlAttributes",urlAttributes:"urlAttributes",imageAttributes:"imageAttributes",imageUrl:"imageUrl",groupBy:null,sortBy:null};var t={level:1,listRole:"presentation",itemRole:"presentation",groupItemRole:"group",itemText:"list-item",wrapperRole:"presentation"},n={showCheckBox:!1,showIcon:!1,enableHtmlSanitizer:!1,expandCollapse:!1,fields:e.defaultMappedFields,ariaAttributes:t,listClass:"",itemClass:"",processSubChild:!1,sortOrder:"None",template:null,groupTemplate:null,headerTemplate:null,expandIconClass:"e-icon-collapsible",moduleName:"list",expandIconPosition:"Right",itemNavigable:!1};function a(e,t,n,a,i){return y(e,r(e,t,n,a,i),null,a)}function r(e,t,a,r,i){var o=[],l=bpt({},n,r);bwt=v(l.moduleName);for(var s=p(),c=0;c<t.length;c++)if(!xpt(t[c])){var d=void 0;if(l.itemCreating&&"function"==typeof l.itemCreating){var h={dataSource:t,curData:t[c],text:t[c],options:l};l.itemCreating(h)}if(d=a?m(e,t[c],void 0,null,null,[],null,s,c,r):w(e,t[c],void 0,null,null,r,i),l.itemCreated&&"function"==typeof l.itemCreated){h={dataSource:t,curData:t[c],text:t[c],item:d,options:l};l.itemCreated(h)}o.push(d)}return o}function i(a,r,i,o,l,s){var c=bpt({},n,i);bwt=v(c.moduleName);var u,g=!s||"listview"!==s.getModuleName()&&"multiselect"!==s.getModuleName()?bpt({},e.defaultMappedFields,c.fields):c.fields,y=bpt({},t,c.ariaAttributes),b=[];o&&(y.level=o);var x,E,k=[];r&&r.length&&!xpt(d(r).item)&&!d(r).item.hasOwnProperty(g.id)&&(u=p());for(var M=0;M<r.length;M++){var S=xwt(r[M],g);if(!xpt(r[M])){if(c.itemCreating&&"function"==typeof c.itemCreating){var A={dataSource:r,curData:r[M],text:S[g.text],options:c,fields:g};c.itemCreating(A)}var _=r[M];c.itemCreating&&"function"==typeof c.itemCreating&&(S=xwt(r[M],g)),S.hasOwnProperty(g.id)&&!xpt(S[g.id])&&(u=S[g.id]);var C=[];if(c.showCheckBox&&(c.itemNavigable&&(S[g.url]||S[g.urlAttributes])?b.push(a("input",{className:bwt.check,attrs:{type:"checkbox"}})):C.push(a("input",{className:bwt.check,attrs:{type:"checkbox"}}))),!0===l)c.showIcon&&S.hasOwnProperty(g.iconCss)&&!xpt(S[g.iconCss])&&C.push(a("span",{className:bwt.icon+" "+S[g.iconCss]})),E=(x=m(a,_,S,g,c.itemClass,C,!(!_.hasOwnProperty("isHeader")||!_.isHeader),u,M,i)).querySelector("."+bwt.anchorWrap),c.itemNavigable&&b.length&&Sft(b,x.firstElementChild);else{if((x=w(a,_,S,g,c.itemClass,i,s)).classList.add(bwt.level+"-"+y.level),x.setAttribute("aria-level",y.level.toString()),E=x.querySelector("."+bwt.anchorWrap),S.hasOwnProperty(g.tooltip)&&x.setAttribute("title",S[g.tooltip]),S.hasOwnProperty(g.htmlAttributes)&&S[g.htmlAttributes]&&h(x,S[g.htmlAttributes]),S.hasOwnProperty(g.enabled)&&!1===S[g.enabled]&&x.classList.add(bwt.disabled),S.hasOwnProperty(g.isVisible)&&!1===S[g.isVisible]&&(x.style.display="none"),S.hasOwnProperty(g.imageUrl)&&!xpt(S[g.imageUrl])&&!c.template){var Z={src:S[g.imageUrl]};ypt(Z,S[g.imageAttributes]);var H=a("img",{className:bwt.image,attrs:Z});E?E.insertAdjacentElement("afterbegin",H):Sft([H],x.firstElementChild)}if(c.showIcon&&S.hasOwnProperty(g.iconCss)&&!xpt(S[g.iconCss])&&!c.template){var I=a("div",{className:bwt.icon+" "+S[g.iconCss]});E?E.insertAdjacentElement("afterbegin",I):Sft([I],x.firstElementChild)}C.length&&Sft(C,x.firstElementChild),c.itemNavigable&&b.length&&Sft(b,x.firstElementChild),f(a,S,g,r,c,x,y.level)}if(E&&xft([x],[bwt.navigable]),c.itemCreated&&"function"==typeof c.itemCreated){A={dataSource:r,curData:r[M],text:S[g.text],item:x,options:c,fields:g};c.itemCreated(A)}b=[],k.push(x)}}return k}function o(e,t,a,r,o,l){var s=bpt({},n,a);return y(e,i(e,t,a,r,o,l),s.listClass,a)}function l(e,t){if(t&&e){return Array.prototype.slice.call(t).indexOf(e)}}function s(e,t,n){if(void 0===n&&(n=new rwt),"Ascending"===e)n.sortBy(t,"ascending",!0);else if("Descending"===e)n.sortBy(t,"descending",!0);else for(var a=0;a<n.queries.length;a++)"onSortBy"===n.queries[a].fn&&n.queries.splice(a,1);return n}function c(e,t){return new wwt(e).executeLocal(t)}function d(e){for(var t={typeof:null,item:null},n=0;n<e.length;n++)if(!xpt(e[n]))return{typeof:typeof e[n],item:e[n]};return t}function h(e,t){var n={};ypt(n,t),n.class&&(xft([e],n.class.split(" ")),delete n.class),Hft(e,n)}function u(e){for(var t={},n=e.attributes,a=0;a<n.length;a++)t[n[a].nodeName]=n[a].nodeValue;return t}function p(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}function f(e,t,n,a,r,i,l){var s=t[n.child]||[],c=t[n.hasChildren];if(s.length&&(c=!0,i.classList.add(bwt.hasChild),r.processSubChild)){var d=o(e,s,r,++l);i.appendChild(d)}r.expandCollapse&&c&&!r.template&&(i.firstElementChild.classList.add(bwt.iconWrapper),("Left"===r.expandIconPosition?Sft:Aft)([e("div",{className:"e-icons "+r.expandIconClass})],i.querySelector("."+bwt.textContent)))}function m(e,a,r,i,o,l,s,c,d,u){var p,f,m=bpt({},n,u),v=bpt({},t,m.ariaAttributes),w=a,y=a;"string"!=typeof a&&"number"!=typeof a&&"boolean"!=typeof a&&(p=a,w="boolean"==typeof r[i.text]||"number"==typeof r[i.text]?r[i.text]:r[i.text]||"",y=r[i.value]),f=xpt(p)||xpt(r[i.id])||""===r[i.id]?c+"-"+d:c;var b=e("li",{className:(!0===s?bwt.group:bwt.li)+" "+(xpt(o)?"":o),id:f,attrs:""!==v.groupItemRole&&""!==v.itemRole?{role:!0===s?v.groupItemRole:v.itemRole}:{}});return p&&r.hasOwnProperty(i.enabled)&&"false"===r[i.enabled].toString()&&b.classList.add(bwt.disabled),s?b.innerText=w:(b.setAttribute("data-value",xpt(y)?"null":y),b.setAttribute("role","option"),p&&r.hasOwnProperty(i.htmlAttributes)&&r[i.htmlAttributes]&&h(b,r[i.htmlAttributes]),l.length&&!m.itemNavigable&&Aft(l,b),p&&(r[i.url]||r[i.urlAttributes]&&r[i.urlAttributes].href)?b.appendChild(g(e,p,i,w,l,m.itemNavigable)):(l.length&&m.itemNavigable&&Aft(l,b),b.appendChild(document.createTextNode(w)))),b}function v(e){return{li:"e-"+e+"-item",ul:"e-"+e+"-parent e-ul",group:"e-"+e+"-group-item",icon:"e-"+e+"-icon",text:"e-"+e+"-text",check:"e-"+e+"-check",checked:"e-checked",selected:"e-selected",expanded:"e-expanded",textContent:"e-text-content",hasChild:"e-has-child",level:"e-level",url:"e-"+e+"-url",collapsible:"e-icon-collapsible",disabled:"e-disabled",image:"e-"+e+"-img",iconWrapper:"e-icon-wrapper",anchorWrap:"e-anchor-wrap",navigable:"e-navigable"}}function g(e,t,n,a,r,i){var o,l=xwt(t,n),s={href:l[n.url]};if(l.hasOwnProperty(n.urlAttributes)&&l[n.urlAttributes]&&(ypt(s,l[n.urlAttributes]),s.href=l[n.url]?l[n.url]:l[n.urlAttributes].href),i){o=e("a",{className:bwt.text+" "+bwt.url});var c=e("div",{className:bwt.anchorWrap});r&&r.length&&Aft(r,c),c.appendChild(document.createTextNode(a)),Aft([c],o)}else o=e("a",{className:bwt.text+" "+bwt.url,innerHTML:a});return h(o,s),o}function w(e,a,r,i,o,l,s){var c,d,h,u=bpt({},n,l),f=bpt({},t,u.ariaAttributes),m=a;"string"!=typeof a&&"number"!=typeof a&&(h=a,m=r[i.text]||"",c=xpt(r._id)?r[i.id]:r._id,d=!(!a.hasOwnProperty("isHeader")||!a.isHeader)),l&&l.enableHtmlSanitizer;var v=e("li",{className:(!0===d?bwt.group:bwt.li)+" "+(xpt(o)?"":o),attrs:""!==f.groupItemRole&&""!==f.itemRole?{role:!0===d?f.groupItemRole:f.itemRole}:{}});if(!0==!xpt(c)?v.setAttribute("data-uid",c):v.setAttribute("data-uid",p()),d&&l&&l.groupTemplate){var w=Ewt(l.groupTemplate);if(s&&"listview"!==s.getModuleName())(y=w(a,s,"groupTemplate",u.groupTemplateID,!!u.isStringTemplate,null,v))&&Aft(y,v);else Aft(w(a,s,"groupTemplate",u.groupTemplateID,!!u.isStringTemplate),v)}else if(!d&&l&&l.template){var y;w=Ewt(l.template);if(s&&"listview"!==s.getModuleName())(y=w(a,s,"template",u.templateID,!!u.isStringTemplate,null,v))&&Aft(y,v);else Aft(w(a,s,"template",u.templateID,!!u.isStringTemplate),v)}else{var b=e("div",{className:bwt.textContent,attrs:""!==f.wrapperRole?{role:f.wrapperRole}:{}});if(h&&(r[i.url]||r[i.urlAttributes]&&r[i.urlAttributes].href))b.appendChild(g(e,h,i,m,null,u.itemNavigable));else{var x=e("span",{className:bwt.text,attrs:""!==f.itemText?{role:f.itemText}:{}});l&&l.enableHtmlSanitizer?x.innerText=m:x.innerHTML=m,b.appendChild(x)}v.appendChild(b)}return v}function y(e,a,r,i){var o=bpt({},n,i),l=bpt({},t,o.ariaAttributes),s=e("ul",{className:(bwt=v(o.moduleName)).ul+" "+(xpt(r)?"":r),attrs:""!==l.listRole?{role:l.listRole}:{}});return Aft(a,s),s}e.createList=function(e,r,i,l,s){var c=bpt({},n,i),h=bpt({},t,c.ariaAttributes),u=d(r).typeof;return"string"===u||"number"===u?a(e,r,l,i,s):o(e,r,i,h.level,l,s)},e.createListFromArray=a,e.createListItemFromArray=r,e.createListItemFromJson=i,e.createListFromJson=o,e.getSiblingLI=function(e,t,a){if(bwt=v(n.moduleName),e&&e.length){var r,i,o=Array.prototype.slice.call(e);for(r=o[(i=t?l(t,o):!0===a?o.length:-1)+(!0===a?-1:1)];r&&(!Mft(r)||r.classList.contains(bwt.disabled));)r=o[i+=!0===a?-1:1];return r}},e.indexOf=l,e.groupDataSource=function(t,n,a){void 0===a&&(a="None");var r=bpt({},e.defaultMappedFields,n),i=(new rwt).group(r.groupBy),o=c(t,i=s(a,"key",i));t=[];for(var l=0;l<o.length;l++){var d=o[l].items,h={};h[r.text]=o[l].key,h.isHeader=!0;var u=r.text;"id"===u&&(h[u="text"]=o[l].key),h._id="group-list-item-"+(o[l].key?o[l].key.toString().trim():"undefined"),h.items=d,t.push(h);for(var p=0;p<d.length;p++)t.push(d[p])}return t},e.addSorting=s,e.getDataSource=c,e.createJsonFromElement=function t(a,r){var i=bpt({},n,r),o=bpt({},e.defaultMappedFields,i.fields),l=a.cloneNode(!0),s=[];l.classList.add("json-parent");var c=l.querySelectorAll(".json-parent>li");l.classList.remove("json-parent");for(var d=0;d<c.length;d++){for(var h=c[d],f=h.querySelector("a"),m=h.querySelector("ul"),v={},g=f?f.childNodes:h.childNodes,w=Object.keys(g),y=0;y<g.length;y++)g[Number(w[y])].hasChildNodes()||(v[o.text]=g[Number(w[y])].textContent);var b=u(h);b.id?(v[o.id]=b.id,delete b.id):v[o.id]=p(),Object.keys(b).length&&(v[o.htmlAttributes]=b),f&&(b=u(f),Object.keys(b).length&&(v[o.urlAttributes]=b)),m&&(v[o.child]=t(m,r)),s.push(v)}return s},e.renderContentTemplate=function(t,a,r,i,o,l){for(var s,c=t("ul",{className:(bwt=v(n.moduleName)).ul,attrs:{role:"presentation"}}),d=bpt({},n,o),h=bpt({},e.defaultMappedFields,i),u=Ewt(a),f=[],m=p(),g=0;g<r.length;g++){var w=xwt(r[g],h),y=r[g],b=y.isHeader;if(s="string"==typeof r[g]||"number"==typeof r[g]?y:w[h.value],d.itemCreating&&"function"==typeof d.itemCreating){var x={dataSource:r,curData:y,text:s,options:d,fields:h};d.itemCreating(x)}d.itemCreating&&"function"==typeof d.itemCreating&&(w=xwt(r[g],h),s="string"==typeof r[g]||"number"==typeof r[g]?y:w[h.value]);var E=t("li",{id:m+"-"+g,className:b?bwt.group:bwt.li,attrs:{role:"presentation"}});if(b)"string"==typeof r[g]||"number"==typeof r[g]?E.innerText=y:E.innerText=w[h.text];else{var k,M=b?d.groupTemplateID:d.templateID;if(b)if(l&&"listview"!=l.getModuleName())(k=u(y,l,"headerTemplate",M,!!d.isStringTemplate,null,E))&&Aft(k,E);else Aft(u(y,l,"headerTemplate",M,!!d.isStringTemplate),E);else if(l&&"listview"!==l.getModuleName())(k=u(y,l,"template",M,!!d.isStringTemplate,null,E))&&Aft(k,E);else Aft(u(y,l,"template",M,!!d.isStringTemplate),E);E.setAttribute("data-value",xpt(s)?"null":s),E.setAttribute("role","option")}if(d.itemCreated&&"function"==typeof d.itemCreated){x={dataSource:r,curData:y,text:s,item:E,options:d,fields:h};d.itemCreated(x)}f.push(E)}return Aft(f,c),c},e.renderGroupTemplate=function(t,a,r,i,o,l){for(var s=Ewt(t),c=bpt({},e.defaultMappedFields,r),d=bpt({},n,o),h=c.groupBy,u=0,p=i;u<p.length;u++){var f=p[u],m={};if(m[h]=f.textContent,f.innerHTML="",l&&"listview"!==l.getModuleName()){var v=s(m,l,"groupTemplate",d.groupTemplateID,!!d.isStringTemplate,null,f);v&&Aft(v,f)}else Aft(s(m,l,"groupTemplate",d.groupTemplateID,!!d.isStringTemplate),f)}return i},e.generateId=p,e.generateUL=y,e.generateIcon=function(e,t,a,r){var i=bpt({},n,r);return bwt=v(i.moduleName),("Left"===i.expandIconPosition?Sft:Aft)([e("div",{className:"e-icons "+i.expandIconClass+" "+(xpt(a)?"":a)})],t.querySelector("."+bwt.textContent)),t}}(vwt||(vwt={}));var kwt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Mwt=function(e,t,n,a){var r,i=arguments.length,o=i<3?t:null===a?a=Object.getOwnPropertyDescriptor(t,n):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,n,a);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(o=(i<3?r(o):i>3?r(t,n,o):r(t,n))||o);return i>3&&o&&Object.defineProperty(t,n,o),o},Swt="e-input-group",Awt="e-popup",_wt="e-left-calendar",Cwt="e-right-calendar",Zwt="e-daterangepicker",Hwt="e-error",Iwt="e-active",Dwt="e-start-date",Nwt="e-end-date",Owt="e-start-btn",Lwt="e-input-focus",Vwt="e-range-hover",zwt="e-other-month",Pwt="e-start-label",Twt="e-end-label",Bwt="e-disabled",jwt="e-selected",Wwt="e-calendar",Rwt="e-next",Fwt="e-prev",Ywt="e-header",qwt="e-title",Uwt="e-icon-container",Gwt="e-date-range-container",Kwt="e-presets",Qwt="e-today",Xwt="e-focused-date",Jwt="e-content",$wt="e-day-span",eyt="e-week-number",tyt="e-date-disabled",nyt="e-icon-disabled",ayt="e-device",ryt="e-overlay",iyt="e-list-item",oyt="e-hover",lyt="e-range-overflow",syt="e-flat",cyt="e-css",dyt="e-non-edit",hyt="e-daterange-hidden",uyt=["title","class","style"],pyt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return kwt(t,e),Mwt([Kft()],t.prototype,"label",void 0),Mwt([Kft()],t.prototype,"start",void 0),Mwt([Kft()],t.prototype,"end",void 0),t}(fmt),fyt=function(e){function t(t,n){var a=e.call(this,t,n)||this;return a.isCustomRange=!1,a.isCustomWindow=!1,a.presetsItem=[],a.liCollections=[],a.previousEleValue="",a.isKeyPopup=!1,a.dateDisabled=!1,a.isRangeIconClicked=!1,a.isMaxDaysClicked=!1,a.disabledDays=[],a.preventBlur=!1,a.preventFocus=!1,a.invalidValueString=null,a.isAngular=!1,a.preventChange=!1,a.dateRangeOptions=t,a}return kwt(t,e),t.prototype.render=function(){this.initialize(),this.setProperties({startDate:this.startValue},!0),this.setProperties({endDate:this.endValue},!0),this.setModelValue(),this.setDataAttribute(!1),this.element.hasAttribute("data-val")&&this.element.setAttribute("data-val","false"),this.renderComplete()},t.prototype.preRender=function(){if(this.keyInputConfigs={altDownArrow:"alt+downarrow",escape:"escape",enter:"enter",tab:"tab",altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow",moveUp:"uparrow",moveDown:"downarrow",spacebar:"space"},this.defaultConstant={placeholder:this.placeholder,startLabel:"Start Date",endLabel:"End Date",customRange:"Custom Range",applyText:"Apply",cancelText:"Cancel",selectedDays:"Selected Days",days:"days"},this.isMobile=window.matchMedia("(max-width:550px)").matches,this.inputElement=this.element,this.angularTag=null,"EJS-DATERANGEPICKER"===this.element.tagName&&(this.angularTag=this.element.tagName,this.inputElement=this.createElement("input"),this.element.appendChild(this.inputElement)),this.cloneElement=this.element.cloneNode(!0),Eft([this.cloneElement],[Zwt,"e-control","e-lib"]),this.updateHtmlAttributeToElement(),this.element.getAttribute("id")?null!==this.angularTag&&(this.inputElement.id=this.element.getAttribute("id")+"_input"):(this.element.id=kpt("ej2-datetimepicker"),null!==this.angularTag&&Hft(this.inputElement,{id:this.element.id+"_input"})),this.checkInvalidRange(this.value),!this.invalidValueString&&"string"==typeof this.value){var t=this.value.split(" "+this.separator+" ");this.value=[new Date(t[0]),new Date(t[1])]}this.initProperty(),this.tabIndex=this.element.hasAttribute("tabindex")?this.element.getAttribute("tabindex"):"0",this.element.removeAttribute("tabindex"),e.prototype.preRender.call(this),this.navNextFunction=this.navNextMonth.bind(this),this.navPrevFunction=this.navPrevMonth.bind(this),this.deviceNavNextFunction=this.deviceNavNext.bind(this),this.deviceNavPrevFunction=this.deviceNavPrevious.bind(this),this.initStartDate=this.checkDateValue(this.startValue),this.initEndDate=this.checkDateValue(this.endValue),this.formElement=Oft(this.element,"form")},t.prototype.updateValue=function(){this.value&&this.value.length>0?(this.value[0]instanceof Date&&!isNaN(+this.value[0])?(this.setProperties({startDate:this.value[0]},!0),this.startValue=this.value[0]):"string"==typeof this.value[0]?0===+this.value[0]||isNaN(+new Date(this.checkValue(this.value[0])))?(this.startValue=null,this.setValue()):(this.setProperties({startDate:new Date(this.checkValue(this.value[0]))},!0),this.startValue=new Date(this.checkValue(this.value[0]))):(this.startValue=null,this.setValue()),this.value[1]instanceof Date&&!isNaN(+this.value[1])?(this.setProperties({endDate:this.value[1]},!0),this.endValue=this.value[1]):"string"==typeof this.value[1]?0===+this.value[0]||isNaN(+new Date(this.checkValue(this.value[0])))?(this.setProperties({endDate:null},!0),this.endValue=null,this.setValue()):(this.setProperties({endDate:new Date(this.checkValue(this.value[1]))},!0),this.endValue=new Date(this.checkValue(this.value[1])),this.setValue()):(this.setProperties({endDate:null},!0),this.endValue=null,this.setValue())):this.value&&this.value.start?(this.value.start instanceof Date&&!isNaN(+this.value.start)?(this.setProperties({startDate:this.value.start},!0),this.startValue=this.value.start):"string"==typeof this.value.start?(this.setProperties({startDate:new Date(this.checkValue(this.value.start))},!0),this.startValue=new Date(this.checkValue(this.value.start))):(this.startValue=null,this.setValue()),this.value.end instanceof Date&&!isNaN(+this.value.end)?(this.setProperties({endDate:this.value.end},!0),this.endValue=this.value.end):"string"==typeof this.value.end?(this.setProperties({endDate:new Date(this.checkValue(this.value.end))},!0),this.endValue=new Date(this.checkValue(this.value.end)),this.setValue()):(this.setProperties({endDate:null},!0),this.endValue=null,this.setValue())):xpt(this.value)&&(this.endValue=this.checkDateValue(new Date(this.checkValue(this.endDate))),this.startValue=this.checkDateValue(new Date(this.checkValue(this.startDate))),this.setValue())},t.prototype.initProperty=function(){this.globalize=new aft(this.locale),this.checkFormat(),this.checkView(),(xpt(this.firstDayOfWeek)||this.firstDayOfWeek>6||this.firstDayOfWeek<0)&&this.setProperties({firstDayOfWeek:this.globalize.getFirstDayOfWeek()},!0),this.updateValue()},t.prototype.checkFormat=function(){if(this.format)if("string"==typeof this.format)this.formatString=this.format;else if(""===this.format.skeleton||xpt(this.format.skeleton))this.formatString=null;else{var e=this.format.skeleton;this.formatString=this.globalize.getDatePattern({skeleton:e,type:"date"})}else this.formatString=null},t.prototype.initialize=function(){null!==this.angularTag&&this.validationAttribute(this.element,this.inputElement),this.checkHtmlAttributes(!1),ypt(this.defaultKeyConfigs,{shiftTab:"shift+tab",tab:"tab"});var e=this.checkDateValue(new Date(this.checkValue(this.startValue)));this.setProperties({startDate:e},!0),this.setProperties({endValue:this.checkDateValue(new Date(this.checkValue(this.endValue)))},!0),this.setValue(),this.setProperties({min:this.checkDateValue(new Date(this.checkValue(this.min)))},!0),this.setProperties({max:this.checkDateValue(new Date(this.checkValue(this.max)))},!0),this.l10n=new zmt("daterangepicker",this.defaultConstant,this.locale),this.l10n.setLocale(this.locale),this.setProperties({placeholder:this.placeholder||this.l10n.getConstant("placeholder")},!0),this.processPresets(),this.createInput(),this.updateHtmlAttributeToWrapper(),this.setRangeAllowEdit(),this.bindEvents()},t.prototype.setDataAttribute=function(e){var t={};if(e)t=this.htmlAttributes;else for(var n=0;n<this.element.attributes.length;n++)t[this.element.attributes[n].name]=this.element.getAttribute(this.element.attributes[n].name);for(var a=0,r=Object.keys(t);a<r.length;a++){var i=r[a];0===i.indexOf("data")&&(this.firstHiddenChild.setAttribute(i,t[i]),this.secondHiddenChild.setAttribute(i,t[i]))}},t.prototype.setRangeAllowEdit=function(){this.allowEdit?this.readonly||this.inputElement.removeAttribute("readonly"):Hft(this.inputElement,{readonly:""}),this.updateClearIconState()},t.prototype.updateClearIconState=function(){this.allowEdit||!this.inputWrapper||this.readonly?this.inputWrapper&&Eft([this.inputWrapper.container],[dyt]):""===this.inputElement.value?Eft([this.inputWrapper.container],[dyt]):xft([this.inputWrapper.container],[dyt])},t.prototype.validationAttribute=function(e,t){var n=e.getAttribute("name")?e.getAttribute("name"):e.getAttribute("id");t.setAttribute("name",n),e.removeAttribute("name");for(var a=["required","aria-required","form"],r=0;r<a.length;r++)if(!xpt(e.getAttribute(a[r]))){var i=e.getAttribute(a[r]);t.setAttribute(a[r],i),e.removeAttribute(a[r])}},t.prototype.updateHtmlAttributeToWrapper=function(){if(!xpt(this.htmlAttributes))for(var e=0,t=Object.keys(this.htmlAttributes);e<t.length;e++){var n=t[e];if(uyt.indexOf(n)>-1)if("class"===n){var a=this.htmlAttributes[n].replace(/\s+/g," ").trim();""!==a&&xft([this.inputWrapper.container],a.split(" "))}else if("style"===n){var r=this.inputWrapper.container.getAttribute(n);r=xpt(r)?this.htmlAttributes[n]:r+this.htmlAttributes[n],this.inputWrapper.container.setAttribute(n,r)}else this.inputWrapper.container.setAttribute(n,this.htmlAttributes[n])}},t.prototype.updateHtmlAttributeToElement=function(){if(!xpt(this.htmlAttributes))for(var e=0,t=Object.keys(this.htmlAttributes);e<t.length;e++){var n=t[e];uyt.indexOf(n)<0&&this.inputElement.setAttribute(n,this.htmlAttributes[n])}},t.prototype.updateCssClass=function(e,t){xpt(t)||(t=t.replace(/\s+/g," ").trim()),xpt(e)||(e=e.replace(/\s+/g," ").trim()),Vgt.setCssClass(e,[this.inputWrapper.container],t),this.popupWrapper&&Vgt.setCssClass(e,[this.popupWrapper],t)},t.prototype.processPresets=function(){this.presetsItem=[];var e=0;if(!Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)){for(var t=0,n=this.presets;t<n.length;t++){var a=n[t],r=a.label.replace(/\s+/g,"")+"_"+ ++e;"string"==typeof a.end?this.presetsItem.push({id:r,text:a.label,end:new Date(this.checkValue(a.end)),start:new Date(this.checkValue(a.start))}):this.presetsItem.push({id:r,text:a.label,start:a.start,end:a.end})}var i=xpt(this.startValue)?null:new Date(+this.startValue),o=xpt(this.endValue)?null:new Date(+this.endValue);this.presetsItem.push({id:"custom_range",text:this.l10n.getConstant("customRange"),start:i,end:o}),xpt(this.startValue)||xpt(this.endValue)||(this.isCustomRange=!0,this.activeIndex=this.presetsItem.length-1)}},t.prototype.bindEvents=function(){wft.add(this.inputWrapper.buttons[0],"mousedown",this.rangeIconHandler,this),wft.add(this.inputElement,"focus",this.inputFocusHandler,this),wft.add(this.inputElement,"blur",this.inputBlurHandler,this),wft.add(this.inputElement,"change",this.inputChangeHandler,this),this.showClearButton&&this.inputWrapper.clearButton&&wft.add(this.inputWrapper.clearButton,"mousedown",this.resetHandler,this),this.isMobile||(this.keyInputConfigs=bpt(this.keyInputConfigs,this.keyConfigs),this.inputKeyboardModule=new Vmt(this.inputElement,{eventName:"keydown",keyAction:this.inputHandler.bind(this),keyConfigs:this.keyInputConfigs})),this.formElement&&wft.add(this.formElement,"reset",this.formResetHandler,this),this.enabled?this.inputElement.setAttribute("tabindex",this.tabIndex):this.inputElement.tabIndex=-1},t.prototype.unBindEvents=function(){wft.remove(this.inputWrapper.buttons[0],"mousedown",this.rangeIconHandler),wft.remove(this.inputElement,"blur",this.inputBlurHandler),wft.remove(this.inputElement,"focus",this.inputFocusHandler),wft.remove(this.inputElement,"change",this.inputChangeHandler),this.showClearButton&&this.inputWrapper.clearButton&&wft.remove(this.inputWrapper.clearButton,"mousedown touchstart",this.resetHandler),this.isMobile||xpt(this.inputKeyboardModule)||this.inputKeyboardModule.destroy(),this.formElement&&wft.remove(this.formElement,"reset",this.formResetHandler),this.inputElement.tabIndex=-1},t.prototype.updateHiddenInput=function(){if(this.firstHiddenChild&&this.secondHiddenChild){var e={type:"datetime",skeleton:"yMd"};"string"==typeof this.startDate&&(this.startDate=this.globalize.parseDate(this.startDate,e)),"string"==typeof this.endDate&&(this.endDate=this.globalize.parseDate(this.endDate,e)),this.firstHiddenChild.value=this.startDate&&this.globalize.formatDate(this.startDate,e)||this.inputElement.value,this.secondHiddenChild.value=this.endDate&&this.globalize.formatDate(this.endDate,e)||this.inputElement.value,this.dispatchEvent(this.firstHiddenChild,"focusout"),this.dispatchEvent(this.firstHiddenChild,"change")}},t.prototype.inputChangeHandler=function(e){this.enabled&&(e.stopPropagation(),this.updateHiddenInput())},t.prototype.bindClearEvent=function(){this.showClearButton&&this.inputWrapper.clearButton&&wft.add(this.inputWrapper.clearButton,"mousedown",this.resetHandler,this)},t.prototype.resetHandler=function(e){if(this.enabled){this.valueType=this.value,e.preventDefault(),this.clear();var t={event:e};this.setProperties({endDate:this.checkDateValue(this.endValue)},!0),this.setProperties({startDate:this.checkDateValue(this.startValue)},!0),this.trigger("cleared",t),this.changeTrigger(e),this.clearRange(),this.hide(e)}},t.prototype.restoreValue=function(){this.previousEleValue=this.inputElement.value,this.previousStartValue=this.startValue,this.previousEndValue=this.endValue,this.valueType=null,this.initStartDate=this.checkDateValue(this.startValue),this.initEndDate=this.checkDateValue(this.endValue),this.setValue(),this.setModelValue()},t.prototype.formResetHandler=function(e){if(this.enabled&&this.formElement&&e.target===this.formElement&&!this.inputElement.disabled){var t=this.inputElement.getAttribute("value");xpt(this.startCopy)?(this.setProperties({value:null,startDate:null,endDate:null},!0),this.startValue=this.endValue=null):(xpt(this.value)||xpt(this.value.start)?(this.setProperties({value:[this.startCopy,this.endCopy]},!0),this.startValue=this.value[0],this.endValue=this.value[1]):(this.setProperties({value:{start:this.startCopy,end:this.endCopy}},!0),this.startValue=this.value.start,this.endValue=this.value.end),this.setProperties({startDate:this.startValue,endDate:this.endValue},!0)),"EJS-DATERANGEPICKER"===this.element.tagName&&(this.setProperties({value:null,startDate:null,endDate:null},!0),t="",this.startValue=this.endValue=null,this.inputElement.setAttribute("value","")),this.restoreValue(),this.inputElement&&(Vgt.setValue(t,this.inputElement,this.floatLabelType,this.showClearButton),this.errorClass())}},t.prototype.clear=function(){null!==this.startValue&&(this.startValue=null),null!==this.endValue&&(this.endValue=null),this.value&&this.value.start&&this.setProperties({value:{start:null,end:null}},!0),null!==this.value&&this.value.length>0&&this.setProperties({value:null},!0),Vgt.setValue("",this.inputElement,this.floatLabelType,this.showClearButton),xpt(this.applyButton)||(this.applyButton.disabled=this.applyButton.element.disabled=!0),this.removeSelection()},t.prototype.rangeIconHandler=function(e){this.enabled&&(this.isMobile&&this.inputElement.setAttribute("readonly",""),e.preventDefault(),this.targetElement=null,this.isPopupOpen()&&document.body.contains(this.popupObj.element)?this.applyFunction(e):(this.isRangeIconClicked=!0,this.inputWrapper.container.children[0].focus(),this.show(null,e),this.isMobile||xpt(this.leftCalendar)||(this.isRangeIconClicked=!1,this.calendarFocus(),this.isRangeIconClicked=!0),xft([this.inputWrapper.container],[Lwt])))},t.prototype.checkHtmlAttributes=function(e){this.globalize=new aft(this.locale);for(var t=e?xpt(this.htmlAttributes)?[]:Object.keys(this.htmlAttributes):["startDate","endDate","minDays","maxDays","min","max","disabled","readonly","style","name","placeholder","type","value"],n={format:this.formatString,type:"date",skeleton:"yMd"},a=0,r=t;a<r.length;a++){var i=r[a];if(!xpt(this.inputElement.getAttribute(i)))switch(i){case"disabled":if(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.enabled||e){var o="disabled"===this.inputElement.getAttribute(i)||""===this.inputElement.getAttribute(i)||"true"===this.inputElement.getAttribute(i);this.setProperties({enabled:!o},!e)}break;case"readonly":if(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.readonly||e){var l="readonly"===this.inputElement.getAttribute(i)||"true"===this.inputElement.getAttribute(i)||""===this.inputElement.getAttribute(i);this.setProperties({readonly:l},!e)}break;case"placeholder":(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.placeholder||e)&&this.setProperties({placeholder:this.inputElement.getAttribute(i)},!e);break;case"value":if(xpt(this.dateRangeOptions)||void 0===this.dateRangeOptions.value||e){var s=this.inputElement.getAttribute(i);this.setProperties(mpt(i,s,{}),!e)}break;case"style":this.inputElement.setAttribute("style",""+this.inputElement.getAttribute(i));break;case"min":if(xpt(this.min)||+this.min===+new Date(1900,0,1)||e){var c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.setProperties(mpt(i,c,{}),!e)}break;case"name":this.inputElement.setAttribute("name",""+this.inputElement.getAttribute(i));break;case"max":if(xpt(this.max)||+this.max===+new Date(2099,11,31)||e){c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.setProperties(mpt(i,c,{}),!e)}break;case"startDate":if(xpt(this.startDate)){c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.startValue=c,this.setValue()}break;case"endDate":if(xpt(this.endDate)){c=this.globalize.parseDate(this.inputElement.getAttribute(i),n);this.endValue=c,this.setValue()}break;case"minDays":xpt(this.minDays)&&this.setProperties(mpt(i,parseInt(this.inputElement.getAttribute(i),10),{}),!0);break;case"maxDays":xpt(this.maxDays)&&this.setProperties(mpt(i,parseInt(this.inputElement.getAttribute(i),10),{}),!0);break;case"type":"text"!==this.inputElement.getAttribute(i)&&this.inputElement.setAttribute("type","text")}}},t.prototype.createPopup=function(){for(var e=0;e<this.presetsItem.length;e++)e!==this.presetsItem.length-1&&"custom_range"===this.presetsItem[e].id&&this.presetsItem.splice(e,1);this.activeIndex=this.presetsItem.length-1,this.isCustomRange=!0;for(e=0;e<=this.presetsItem.length-2;e++){var t=this.presetsItem[e].start,n=this.presetsItem[e].end;this.startValue&&this.endValue&&+new Date(t.setHours(0,0,0,0))===+new Date(this.startValue.setHours(0,0,0,0))&&+new Date(n.setHours(0,0,0,0))===+new Date(this.endValue.setHours(0,0,0,0))&&(this.activeIndex=e,this.isCustomRange=!1)}this.popupWrapper=bft("div",{id:this.element.id+"_popup",className:Zwt+" "+Awt}),this.adjustLongHeaderWidth();var a=!this.isCustomRange||this.isMobile;!Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)&&a?(this.isCustomWindow=!1,this.createPresets(),this.listRippleEffect(),this.renderPopup()):(this.isCustomWindow=!0,this.renderControl())},t.prototype.renderControl=function(){this.createControl(),this.bindCalendarEvents(),this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar]),xpt(this.endValue)||xpt(this.startValue)||this.disabledDateRender(),this.updateHeader()},t.prototype.clearCalendarEvents=function(){wft.clearEvents(this.leftCalPrevIcon),wft.clearEvents(this.leftCalNextIcon),wft.clearEvents(this.rightCalPrevIcon),wft.clearEvents(this.rightCalNextIcon)},t.prototype.updateNavIcons=function(){e.prototype.iconHandler.call(this)},t.prototype.calendarIconEvent=function(){this.clearCalendarEvents(),this.leftCalPrevIcon&&!this.leftCalPrevIcon.classList.contains(Bwt)&&wft.add(this.leftCalPrevIcon,"mousedown",this.navPrevFunction),this.leftCalNextIcon&&!this.leftCalNextIcon.classList.contains(Bwt)&&wft.add(this.leftCalNextIcon,"mousedown",this.navNextFunction),this.rightCalPrevIcon&&!this.rightCalPrevIcon.classList.contains(Bwt)&&wft.add(this.rightCalPrevIcon,"mousedown",this.navPrevFunction),this.rightCalNextIcon&&!this.rightCalNextIcon.classList.contains(Bwt)&&wft.add(this.rightCalNextIcon,"mousedown",this.navNextFunction)},t.prototype.bindCalendarEvents=function(){this.isMobile?(this.deviceCalendarEvent(),wft.add(this.startButton.element,"click",this.deviceHeaderClick,this),wft.add(this.endButton.element,"click",this.deviceHeaderClick,this)):(this.updateNavIcons(),this.calendarIconEvent(),this.calendarIconRipple(),this.headerTitleElement=this.popupObj.element.querySelector("."+Cwt+" ."+Ywt+" ."+qwt),this.headerTitleElement=this.popupObj.element.querySelector("."+_wt+" ."+Ywt+" ."+qwt),this.defaultKeyConfigs=bpt(this.defaultKeyConfigs,this.keyConfigs),this.leftKeyboardModule=new Vmt(this.leftCalendar,{eventName:"keydown",keyAction:this.keyInputHandler.bind(this),keyConfigs:this.defaultKeyConfigs}),this.rightKeyboardModule=new Vmt(this.rightCalendar,{eventName:"keydown",keyAction:this.keyInputHandler.bind(this),keyConfigs:this.defaultKeyConfigs})),this.start===this.depth&&this.bindCalendarCellEvents(),this.removeFocusedDate()},t.prototype.calendarIconRipple=function(){omt(this.leftCalPrevIcon,{selector:".e-prev",duration:400,isCenterRipple:!0}),omt(this.leftCalNextIcon,{selector:".e-next",duration:400,isCenterRipple:!0}),omt(this.rightCalPrevIcon,{selector:".e-prev",duration:400,isCenterRipple:!0}),omt(this.rightCalNextIcon,{selector:".e-next",duration:400,isCenterRipple:!0})},t.prototype.deviceCalendarEvent=function(){wft.clearEvents(this.nextIcon),wft.clearEvents(this.previousIcon),omt(this.nextIcon,{selector:".e-prev",duration:400,isCenterRipple:!0}),omt(this.previousIcon,{selector:".e-next",duration:400,isCenterRipple:!0}),this.nextIcon&&!this.nextIcon.classList.contains(Bwt)&&wft.add(this.nextIcon,"mousedown",this.deviceNavNextFunction),this.previousIcon&&!this.previousIcon.classList.contains(Bwt)&&wft.add(this.previousIcon,"mousedown",this.deviceNavPrevFunction)},t.prototype.deviceNavNext=function(e){var t=Oft(e.target,"."+Wwt);this.updateDeviceCalendar(t),this.navigateNext(e),this.deviceNavigation()},t.prototype.deviceNavPrevious=function(e){var t=Oft(e.target,"."+Wwt);this.updateDeviceCalendar(t),this.navigatePrevious(e),this.deviceNavigation()},t.prototype.updateDeviceCalendar=function(e){e&&(this.previousIcon=e.querySelector("."+Fwt),this.nextIcon=e.querySelector("."+Rwt),this.calendarElement=e,this.deviceCalendar=e,this.contentElement=e.querySelector("."+Jwt),this.tableBodyElement=Ift("."+Jwt+" tbody",e),this.table=e.querySelector("."+Jwt).getElementsByTagName("table")[0],this.headerTitleElement=e.querySelector("."+Ywt+" ."+qwt),this.headerElement=e.querySelector("."+Ywt))},t.prototype.deviceHeaderClick=function(e){if(e.currentTarget.classList.contains(Owt)&&!xpt(this.startValue)){this.endButton.element.classList.remove(Iwt),this.startButton.element.classList.add(Iwt);var t=this.popupObj.element.querySelector("."+Wwt);this.updateDeviceCalendar(t),xpt(this.calendarElement.querySelector("."+Dwt+":not(.e-other-month)"))&&(this.currentDate=new Date(+this.startValue),Zft(this.tableBodyElement),this.createContentBody(),this.deviceNavigation()),this.removeClassDisabled()}else if(!xpt(this.startValue)&&!xpt(this.endValue)){this.startButton.element.classList.remove(Iwt),this.endButton.element.classList.add(Iwt);t=this.popupObj.element.querySelector("."+Wwt);this.updateDeviceCalendar(t),xpt(this.calendarElement.querySelector("."+Nwt+":not(.e-other-month)"))&&(this.currentDate=new Date(+this.endValue),Zft(this.tableBodyElement),this.createContentBody(),this.deviceNavigation()),this.updateMinMaxDays(this.popupObj.element.querySelector("."+Wwt)),this.selectableDates()}},t.prototype.inputFocusHandler=function(){if(this.enabled){this.preventBlur=!1;var e={model:this};this.preventFocus||this.trigger("focus",e),this.updateClearIconState(),this.updateHiddenInput(),this.openOnFocus&&!this.preventFocus?(this.preventFocus=!0,this.show()):this.preventFocus=!0}},t.prototype.inputBlurHandler=function(e){if(this.enabled){if(!this.preventBlur){var t=this.inputElement.value;if(xpt(this.presetsItem)||this.presetsItem.length>0&&this.previousEleValue!==this.inputElement.value&&(this.activeIndex=this.presetsItem.length-1,this.isCustomRange=!0),!xpt(t)&&""!==t.trim()){var n=t.split(" "+this.separator+" ");if(n.length>1){this.invalidValueString=null;var a={format:this.formatString,type:"date",skeleton:"yMd"},r=this.globalize.parseDate(n[0].trim(),a),i=this.globalize.parseDate(n[1].trim(),a);if(!(xpt(r)||isNaN(+r)||xpt(i)||isNaN(+i))){var o=this.startValue;this.startValue=r;var l=this.endValue;if(this.endValue=i,this.setValue(),this.refreshControl(),t!==this.previousEleValue&&this.changeTrigger(e),!this.preventBlur&&document.activeElement!==this.inputElement){this.preventFocus=!1;var s={model:this};this.trigger("blur",s)}return this.updateHiddenInput(),void(this.isMobile&&this.isPopupOpen()&&(this.startValue=o,this.endValue=l))}this.strictMode||(this.startValue=null,this.endValue=null,this.setValue())}else this.strictMode||(this.startValue=null,this.endValue=null,this.setValue())}if(this.strictMode?(xpt(t)||""!==t.trim()||(this.startValue=null,this.endValue=null),Vgt.setValue("",this.inputElement,this.floatLabelType,this.showClearButton),this.updateInput()):(xpt(this.popupObj)&&(this.currentDate=null),this.previousStartValue=this.previousEndValue=null,this.startValue=null,this.endValue=null,this.setValue()),this.errorClass(),this.changeTrigger(e),!this.preventBlur&&document.activeElement!==this.inputElement){this.preventFocus=!1;s={model:this};this.trigger("blur",s)}}this.updateHiddenInput()}},t.prototype.clearRange=function(){this.previousStartValue=this.previousEndValue=null,this.currentDate=null},t.prototype.errorClass=function(){var e=this.inputElement.value.trim();(xpt(this.endValue)&&xpt(this.startValue)&&""!==e||!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue||!xpt(this.endValue)&&+this.endValue>+this.max||this.startValue&&this.isDateDisabled(this.startValue)||this.endValue&&this.isDateDisabled(this.endValue))&&""!==e?(xft([this.inputWrapper.container],Hwt),Hft(this.inputElement,{"aria-invalid":"true"})):this.inputWrapper&&(Eft([this.inputWrapper.container],Hwt),Hft(this.inputElement,{"aria-invalid":"false"}))},t.prototype.keyCalendarUpdate=function(e,t,n){return void 0===n&&(n=!0),n&&this.removeFocusedDate(),e?(this.leftCalCurrentDate=new Date(+this.currentDate),t=this.leftCalendar):(this.rightCalCurrentDate=new Date(+this.currentDate),t=this.rightCalendar),this.updateCalendarElement(t),this.table.focus(),t},t.prototype.navInCalendar=function(e,t,n,a,r){var i,o,l=this.getViewNumber(this.currentView()),s=this.min;switch(o=xpt(this.maxDays)||!this.isMaxDaysClicked||xpt(this.startValue)?this.max:new Date(new Date(+this.startValue).setDate(this.startValue.getDate()+(this.maxDays-1))),e.action){case"moveRight":i=new Date(+this.currentDate),this.addDay(i,1,e,o,s),t&&+i===+a&&(r=this.keyCalendarUpdate(!1,r)),this.keyboardNavigate(1,l,e,o,s),this.keyNavigation(r,e);break;case"moveLeft":i=new Date(+this.currentDate),this.addDay(i,-1,e,o,s),t||+i===+n&&(r=this.keyCalendarUpdate(!0,r)),this.keyboardNavigate(-1,l,e,o,s),this.keyNavigation(r,e);break;case"moveUp":0===l?(i=new Date(+this.currentDate),this.addDay(i,-7,e,o,s),+i<=+n&&!t&&(r=this.keyCalendarUpdate(!0,r)),this.keyboardNavigate(-7,l,e,o,s)):this.keyboardNavigate(-4,l,e,this.max,this.min),this.keyNavigation(r,e);break;case"moveDown":0===l?(i=new Date(+this.currentDate),this.addDay(i,7,e,o,s),t&&+i>=+a&&(r=this.keyCalendarUpdate(!1,r)),this.keyboardNavigate(7,l,e,o,s)):this.keyboardNavigate(4,l,e,this.max,this.min),this.keyNavigation(r,e);break;case"home":this.currentDate=this.firstDay(this.currentDate),Zft(this.tableBodyElement),0===l?this.renderMonths(e):1===l?this.renderYears(e):this.renderDecades(e),this.keyNavigation(r,e);break;case"end":this.currentDate=this.lastDay(this.currentDate,l),Zft(this.tableBodyElement),0===l?this.renderMonths(e):1===l?this.renderYears(e):this.renderDecades(e),this.keyNavigation(r,e);break;case"tab":if(this.tabKeyValidation(r,_wt))xpt((r=this.keyCalendarUpdate(!1,r,!1)).querySelector(".e-focused-date"))&&(this.currentDate=this.firstCellToFocus(this.rightCalendar)),this.keyboardNavigate(0,l,e,o,s),this.keyNavigation(r,e);break;case"shiftTab":if(this.tabKeyValidation(r,Cwt))xpt((r=this.keyCalendarUpdate(!0,r,!1)).querySelector(".e-focused-date"))&&(this.currentDate=this.firstCellToFocus(this.leftCalendar)),this.keyboardNavigate(0,l,e,o,s),this.keyNavigation(r,e)}},t.prototype.firstCellToFocus=function(e){var t=e.children[1].firstElementChild.querySelector("td.e-cell:not(.e-week-number):not(.e-disabled):not(.e-other-month)"),n=t&&t.id?t.id.split("_")[0]:null,a=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth(),1);return n?new Date(+n):a},t.prototype.keyInputHandler=function(t,n){var a,r=this.getViewNumber(this.currentView()),i=new Date(this.rightCalCurrentDate.getFullYear(),this.rightCalCurrentDate.getMonth(),1),o=new Date(this.leftCalCurrentDate.getFullYear(),this.leftCalCurrentDate.getMonth()+1,0),l=Oft(t.target,"."+Cwt),s=(l=xpt(l)?this.leftCalendar:l).classList.contains(_wt);this.updateCalendarElement(l);var c=this.tableBodyElement.querySelector("tr td.e-selected"),d=l.querySelector("tr td."+Xwt),h=l.querySelector("tr td."+Dwt),u=l.querySelector("tr td."+Nwt),p=this.getViewNumber(this.depth),f=r===p&&this.getViewNumber(this.start)>=p,m=Oft(t.target,"."+_wt),v=Oft(t.target,"."+Cwt),g=Oft(t.target,"."+Kwt);switch(xpt(d)?xpt(u)||this.dateDisabled?xpt(h)||this.dateDisabled?this.dateDisabled||this.currentDate.setDate(1):this.currentDate=new Date(+this.startValue):this.currentDate=new Date(+this.endValue):this.currentDate=this.currentDate,this.effect="",t.action){case"altUpArrow":this.isPopupOpen()&&(this.hide(t),this.preventFocus=!0,this.inputElement.focus(),xft([this.inputWrapper.container],[Lwt]));break;case"select":if(f){var w=xpt(d)?h:d;xpt(w)||w.classList.contains(Bwt)||this.selectRange(null,w)}else(xpt(c)||f)&&xpt(d)||(xpt(this.value)||(n=this.calendarElement.classList.contains(_wt)?this.startDate:this.endDate),this.controlDown=t,this.contentClick(null,--r,d||c,n));t.preventDefault();break;case"controlHome":var y=new Date(this.currentDate.getFullYear(),0,1);!s&&+y<+o&&(l=this.keyCalendarUpdate(!0,l)),e.prototype.navigateTo.call(this,"Month",new Date(this.currentDate.getFullYear(),0,1)),this.keyNavigation(l,t);break;case"altRightArrow":xpt(m)?xpt(v)?xpt(g)||this.cancelButton.element.focus():xpt(this.presetElement)?this.cancelButton.element.focus():(this.presetElement.focus(),this.removeFocusedDate()):this.rightCalendar.children[1].firstElementChild.focus(),t.preventDefault();break;case"altLeftArrow":xpt(m)?xpt(v)||this.leftCalendar.children[1].firstElementChild.focus():!0!==this.applyButton.element.disabled?this.applyButton.element.focus():this.cancelButton.element.focus(),t.preventDefault();break;case"controlUp":this.calendarElement.classList.contains(_wt),this.calendarNavigation(t,this.calendarElement),t.preventDefault();break;case"controlDown":xpt(c)&&xpt(d)||f||(xpt(this.value)||(n=this.calendarElement.classList.contains(_wt)?this.startDate:this.endDate),this.controlDown=t,this.contentClick(null,--r,c||d,n)),t.preventDefault();break;case"controlEnd":y=new Date(this.currentDate.getFullYear(),11,31);s&&+y>+i&&(l=this.keyCalendarUpdate(!1,l)),e.prototype.navigateTo.call(this,"Month",new Date(this.currentDate.getFullYear(),11,31)),this.keyNavigation(l,t);break;case"pageUp":a=new Date(+this.currentDate),this.addMonths(a,-1),!s&&+a<=+o&&(l=this.keyCalendarUpdate(!0,l)),this.addMonths(this.currentDate,-1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"pageDown":a=new Date(+this.currentDate),this.addMonths(a,1),s&&+a>=+i&&(l=this.keyCalendarUpdate(!1,l)),this.addMonths(this.currentDate,1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"shiftPageUp":a=new Date(+this.currentDate),this.addYears(a,-1),!s&&+a<=+o&&(l=this.keyCalendarUpdate(!0,l)),this.addYears(this.currentDate,-1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"shiftPageDown":a=new Date(+this.currentDate),this.addYears(a,1),s&&+a>=+i&&(l=this.keyCalendarUpdate(!1,l)),this.addYears(this.currentDate,1),e.prototype.navigateTo.call(this,"Month",this.currentDate),this.keyNavigation(l,t);break;case"shiftTab":xpt(this.presetElement)||(this.presetElement.setAttribute("tabindex","0"),this.presetElement.focus(),this.removeFocusedDate()),s&&t.preventDefault(),this.tabKeyValidation(l,Cwt)&&(this.currentDate=new Date(+this.leftCalCurrentDate),this.navInCalendar(t,s,o,i,l));break;case"spacebar":this.applyButton&&!this.applyButton.disabled&&this.applyFunction(t);break;case"tab":this.tabKeyValidation(l,_wt)&&(this.currentDate=new Date(+this.rightCalCurrentDate),this.navInCalendar(t,s,o,i,l));break;default:this.navInCalendar(t,s,o,i,l),this.checkMinMaxDays()}this.presetHeight()},t.prototype.tabKeyValidation=function(e,t){var n=e.classList.contains(t),a=this.rightCalendar.querySelector(".e-header"),r=this.leftCalendar.querySelector(".e-header"),i=!!a&&a.classList.contains("e-month"),o=!!r&&r.classList.contains("e-month");return n&&o&&i&&!this.isMobile},t.prototype.keyNavigation=function(e,t){this.bindCalendarCellEvents(e),e.classList.contains(_wt)?this.leftCalCurrentDate=new Date(+this.currentDate):this.rightCalCurrentDate=new Date(+this.currentDate),this.updateNavIcons(),this.calendarIconEvent(),this.updateRange([e]),this.dateDisabled=this.isDateDisabled(this.currentDate),t.preventDefault()},t.prototype.inputHandler=function(e){switch(e.action){case"altDownArrow":this.isPopupOpen()||(""===this.inputElement.value&&(this.clear(),this.changeTrigger(e),this.clearRange()),this.show(null,e),this.isRangeIconClicked=!1,this.isMobile||xpt(this.leftCalendar)||this.calendarFocus(),this.isKeyPopup=!0);break;case"escape":this.isPopupOpen()&&this.hide(e);break;case"enter":document.activeElement===this.inputElement&&(this.inputBlurHandler(e),this.hide(e));break;case"tab":document.activeElement===this.inputElement&&this.isPopupOpen()&&(this.hide(e),e.preventDefault())}},t.prototype.bindCalendarCellEvents=function(e){for(var t=0,n=e?e.querySelectorAll("."+Wwt+" td"):this.popupObj.element.querySelectorAll("."+Wwt+" td");t<n.length;t++){var a=n[t];wft.clearEvents(a),a.classList.contains(Bwt)||a.classList.contains(tyt)||a.classList.contains(eyt)||(this.isMobile||wft.add(a,"mouseover",this.hoverSelection,this),wft.add(a,"mousedown",this.selectRange,this))}},t.prototype.removeFocusedDate=function(){for(var e=!xpt(this.startValue)||!xpt(this.endValue),t=0,n=this.popupObj.element.querySelectorAll("."+Wwt+" ."+Xwt);t<n.length;t++){var a=n[t],r=new Date,i=this.getIdValue(null,a);("Month"===this.depth&&"Month"===this.currentView()&&(!a.classList.contains(Qwt)||a.classList.contains(Qwt)&&e)||"Year"===this.depth&&"Year"===this.currentView()&&(!this.isSameMonth(r,i)&&!this.isSameYear(r,i)||e)||"Decade"===this.depth&&"Decade"===this.currentView()&&(!this.isSameYear(r,i)||e))&&(a.classList.remove(Xwt),a.classList.contains(Dwt)||a.classList.contains(Nwt)||a.removeAttribute("aria-label"))}},t.prototype.hoverSelection=function(e,t){var n=t||e.currentTarget,a=this.getIdValue(null,n);if(!xpt(this.startValue)&&+this.startValue>=+this.min&&+this.startValue<=+this.max&&(!this.isDateDisabled(this.endValue)&&!this.isDateDisabled(this.startValue)&&xpt(this.endValue)&&xpt(this.startValue)||!xpt(this.startValue)&&xpt(this.endValue)))for(var r=0,i=this.popupObj.element.querySelectorAll("."+Wwt+" td");r<i.length;r++){var o=i[r],l=!o.classList.contains(Bwt)||o.classList.contains(tyt);if(!o.classList.contains(eyt)&&l){var s=this.getIdValue(null,o),c=new Date(+this.startValue);new Date(+s).setHours(0,0,0,0)>=c.setHours(0,0,0,0)&&+s<=+a?xft([o],Vwt):Eft([o],[Vwt])}}},t.prototype.isSameStartEnd=function(e,t){var n=!1;return"Month"===this.depth?e.setHours(0,0,0,0)===t.setHours(0,0,0,0)&&(n=!0):"Year"===this.depth?e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&(n=!0):"Decade"===this.depth&&e.getFullYear()===t.getFullYear()&&(n=!0),n},t.prototype.updateRange=function(e){if(!xpt(this.startValue))for(var t=0,n=e;t<n.length;t++)for(var a=0,r=n[t].querySelectorAll("."+Wwt+" td");a<r.length;a++){var i=r[a];if(!i.classList.contains(eyt)&&!i.classList.contains(Bwt)){var o=this.getIdValue(null,i),l=this.getIdValue(null,i);if(xpt(this.endValue)?Eft([i],[Vwt]):this.currentView()===this.depth&&+l.setHours(0,0,0,0)>=+new Date(+this.startValue).setHours(0,0,0,0)&&+l.setHours(0,0,0,0)<=+new Date(+this.endValue).setHours(0,0,0,0)&&!this.isSameStartEnd(new Date(+this.startValue),new Date(+this.endValue))&&+new Date(+this.startValue).setHours(0,0,0,0)>=+this.min&&+new Date(+this.endValue).setHours(0,0,0,0)<=+this.max&&!this.isDateDisabled(this.startValue)&&!this.isDateDisabled(this.endValue)&&xft([i],Vwt),i.classList.contains(jwt)&&i.classList.contains(Nwt)&&+l!==+this.endValue&&(Eft([i],[jwt]),Eft([i],[Nwt])),i.classList.contains(Vwt)&&+l>+this.endValue&&Eft([i],[Vwt]),!i.classList.contains(zwt)){var s=new Date(+this.startValue),c=new Date(+o);this.currentView()===this.depth&&+c.setHours(0,0,0,0)===+s.setHours(0,0,0,0)&&+c.setHours(0,0,0,0)>=+s.setHours(0,0,0,0)&&+this.startValue>=+this.min&&!this.inputWrapper.container.classList.contains("e-error")&&!this.isDateDisabled(this.startValue)&&!this.isDateDisabled(this.endValue)&&(xft([i],[Dwt,jwt]),this.addSelectedAttributes(i,this.startValue,!0));var d=new Date(+this.endValue);"Year"===this.currentView()?c=new Date(c.getFullYear(),c.getMonth()+1,0):"Decade"===this.currentView()&&(c=new Date(c.getFullYear(),11,31)),this.currentView()===this.depth&&!xpt(this.endValue)&&+c.setHours(0,0,0,0)===+d.setHours(0,0,0,0)&&+c.setHours(0,0,0,0)<=+d.setHours(0,0,0,0)&&+this.startValue>=+this.min&&!this.inputWrapper.container.classList.contains("e-error")&&!this.isDateDisabled(this.startValue)&&!this.isDateDisabled(this.endValue)&&(xft([i],[Nwt,jwt]),this.addSelectedAttributes(i,this.startValue,!1)),+o!==+this.startValue||xpt(this.endValue)||+o!==+this.endValue||this.addSelectedAttributes(i,this.endValue,!1,!0)}}}},t.prototype.checkMinMaxDays=function(){(!xpt(this.minDays)&&this.minDays>0||!xpt(this.maxDays)&&this.maxDays>0)&&(this.isMobile?this.updateMinMaxDays(this.popupObj.element.querySelector("."+Wwt)):(this.updateMinMaxDays(this.popupObj.element.querySelector("."+_wt)),this.updateMinMaxDays(this.popupObj.element.querySelector("."+Cwt))))},t.prototype.rangeArgs=function(e){var t,n,a=xpt(this.startValue)?null:this.globalize.formatDate(this.startValue,{format:this.formatString,type:"date",skeleton:"yMd"}),r=xpt(this.endValue)?null:this.globalize.formatDate(this.endValue,{format:this.formatString,type:"date",skeleton:"yMd"});return xpt(this.endValue)||xpt(this.startValue)?(t="",n=0):(t=a+" "+this.separator+" "+r,n=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1),{value:this.value,startDate:this.startValue,endDate:this.endValue,daySpan:n,event:e||null,element:this.element,isInteracted:!xpt(e),text:t}},t.prototype.otherMonthSelect=function(e,t,n){var a=+this.getIdValue(null,e),r='*[id^="/id"]:not(.e-other-month)'.replace("/id",""+a),i=this.popupObj&&this.popupObj.element.querySelector(r);xpt(i)||(t?(xft([i],[Dwt,jwt]),this.addSelectedAttributes(i,this.startValue,!0)):(xft([i],[Nwt,jwt]),this.addSelectedAttributes(i,this.endValue,!0)),n&&this.addSelectedAttributes(e,this.endValue,!1,!0))},t.prototype.selectRange=function(e,t){var n,a;e&&e.preventDefault();var r=xpt(e)?this.getIdValue(null,t):this.getIdValue(e,null),i=r.getFullYear(),o=r.getMonth(),l=new Date(i,o,1),s=new Date(i,o+1,0),c=new Date(i,0,1),d=new Date(i,11,31);xpt(this.endValue)||xpt(this.startValue)?this.isMobile&&this.startButton.element.classList.contains(Iwt)&&this.removeSelection():(!this.isMobile||this.isMobile&&!this.endButton.element.classList.contains(Iwt))&&this.removeSelection();var h=t||e.currentTarget;if(xpt(this.startValue))xpt(this.previousStartValue)||(r.setHours(this.previousStartValue.getHours()),r.setMinutes(this.previousStartValue.getMinutes()),r.setSeconds(this.previousStartValue.getSeconds())),this.startValue="Month"===this.depth?new Date(this.checkValue(r)):"Year"===this.depth?l:c,this.endValue=null,this.setValue(),xft([h],Dwt),this.addSelectedAttributes(h,this.startValue,!0),h.classList.contains(zwt)&&this.otherMonthSelect(h,!0),this.checkMinMaxDays(),this.applyButton.disabled=!0,this.applyButton.element.disabled=!0,this.isMobile&&(this.endButton.element.classList.add(Iwt),this.startButton.element.classList.remove(Iwt),this.endButton.element.removeAttribute("disabled"),this.selectableDates()),this.trigger("select",this.rangeArgs(e));else if(+r===+this.startValue||+r>+this.startValue){if(+r===+this.startValue&&!xpt(this.minDays)&&this.minDays>1)return;this.endValue=null,this.setValue(),(this.isMobile||t)&&this.hoverSelection(e,t),xpt(this.previousEndValue)||(r.setHours(this.previousEndValue.getHours()),r.setMinutes(this.previousEndValue.getMinutes()),r.setSeconds(this.previousEndValue.getSeconds())),this.endValue="Month"===this.depth?new Date(this.checkValue(r)):"Year"===this.depth?s:d,this.setValue();var u=this.popupObj.element.querySelectorAll("."+Nwt);if(this.isMobile){this.startButton.element.classList.remove(Iwt),this.endButton.element.classList.add(Iwt);for(var p=0,f=u;p<f.length;p++){var m=f[p];m.removeAttribute("aria-label"),m.classList.contains(Dwt)?(this.addSelectedAttributes(m,this.startValue,!0),Eft([m],[Nwt])):(m.setAttribute("aria-selected","false"),Eft([m],[Nwt,jwt]))}}xft([h],Nwt),+this.endValue===+this.startValue?this.addSelectedAttributes(h,this.endValue,!1,!0):this.addSelectedAttributes(h,this.endValue,!1),h.classList.contains(zwt)&&(+this.endValue===+this.startValue?this.otherMonthSelect(h,!1,!0):this.otherMonthSelect(h,!1));for(var v=0,g=u=this.popupObj.element.querySelectorAll("."+Nwt);v<g.length;v++){var w=g[v];w.classList.contains(Dwt)&&Eft([w],[Vwt])}this.applyButton.disabled=!1,this.applyButton.element.disabled=!1,this.isMobile||this.removeClassDisabled(),this.disabledDateRender(),this.trigger("select",this.rangeArgs(e))}else+r<+this.startValue&&(this.removeClassDisabled(),this.startValue="Month"===this.depth?new Date(this.checkValue(r)):"Year"===this.depth?l:c,this.setValue(),this.removeSelectedAttributes(),Eft(this.popupObj.element.querySelectorAll("."+Dwt),[Dwt,jwt]),xft([h],Dwt),this.addSelectedAttributes(h,this.startValue,!0),h.classList.contains(zwt)&&this.otherMonthSelect(h,!0),this.checkMinMaxDays());e&&(n=Oft(e.target,"."+_wt)),xpt(n)?(e&&(a=e&&Oft(e.target,"."+Cwt)),xpt(a)||this.rightCalendar.children[1].firstElementChild.focus()):this.leftCalendar.children[1].firstElementChild.focus(),xft([h],jwt),this.updateHeader(),this.removeFocusedDate()},t.prototype.selectableDates=function(){if(!xpt(this.startValue)){var e=this.calendarElement.querySelectorAll("."+Wwt+" td"),t=!1;if(this.currentView()===this.depth){for(var n=0,a=e;n<a.length;n++){if(!(o=a[n]).classList.contains(Dwt)&&!o.classList.contains(eyt)&&!o.classList.contains(Bwt)){if(+this.getIdValue(null,o)<+this.startValue){xft([o],[tyt,Bwt,ryt]),wft.clearEvents(o);continue}break}if(o.classList.contains(Dwt)&&!o.classList.contains(zwt)){t=!0;break}}t&&(this.previousIcon.classList.contains(Bwt)||xft([this.previousIcon],[nyt,Bwt,ryt]))}else{for(var r=0,i=e;r<i.length;r++){var o=i[r],l=this.startValue.getMonth(),s=this.startValue.getFullYear(),c=this.getIdValue(null,o);if(this.startButton.element.classList.contains(Iwt)||!("Year"===this.currentView()&&c.getMonth()<l&&c.getFullYear()<=s||"Decade"===this.currentView()&&c.getMonth()<=l&&c.getFullYear()<s))break;xft([o],[Bwt])}e[0].classList.contains(Bwt)?this.previousIconHandler(!0):e[e.length-1].classList.contains(Bwt)&&this.nextIconHandler(!0)}}},t.prototype.updateMinMaxDays=function(e){if(!xpt(this.startValue)&&xpt(this.endValue)||this.isMobile&&this.endButton.element.classList.contains(Iwt)){if(!xpt(this.minDays)&&this.minDays>0||!xpt(this.maxDays)&&this.maxDays>0){var t=this.removeTimeValueFromDate(this.startValue),n=new Date(new Date(+t).setDate(t.getDate()+(this.minDays-1))),a=new Date(new Date(+t).setDate(t.getDate()+(this.maxDays-1)));n=!xpt(this.minDays)&&this.minDays>0?n:null,a=!xpt(this.maxDays)&&this.maxDays>0?a:null,"Year"===this.currentView()?(n=xpt(n)?null:new Date(n.getFullYear(),n.getMonth(),0),a=xpt(a)?null:new Date(a.getFullYear(),a.getMonth(),1)):"Decade"===this.currentView()&&(n=xpt(n)?null:new Date(n.getFullYear()-1,11,1),a=xpt(a)?null:new Date(a.getFullYear(),0,1));for(var r=void 0,i=0,o=e.querySelectorAll("."+Wwt+" td");i<o.length;i++){var l=o[i];if(!l.classList.contains(Dwt)&&!l.classList.contains(eyt)){var s=this.getIdValue(null,l);if(s=this.removeTimeValueFromDate(s),!xpt(n)&&+s===+n&&l.classList.contains(Bwt)&&n.setDate(n.getDate()+1),!l.classList.contains(Bwt)){if(+s<=+t)continue;!xpt(n)&&+s<+n&&(xft([l],[tyt,Bwt,ryt]),wft.clearEvents(l)),!xpt(a)&&+s>+a&&(xft([l],[tyt,Bwt,ryt]),this.isMaxDaysClicked=!0,wft.clearEvents(l),xpt(r)&&!l.classList.contains(zwt)&&(r=l))}}}if(!xpt(r))if(this.isMobile)this.nextIcon.classList.contains(Bwt)||xft([this.nextIcon],[nyt,Bwt,ryt]);else{var c=Oft(r,"."+Cwt);(c=xpt(c)?this.leftCalendar:c).classList.contains(_wt)?(this.rightCalNextIcon.classList.contains(Bwt)||xft([this.rightCalNextIcon],[nyt,Bwt,ryt]),this.leftCalNextIcon.classList.contains(Bwt)||xft([this.leftCalNextIcon],[nyt,Bwt,ryt]),this.rightCalPrevIcon.classList.contains(Bwt)||xft([this.rightCalPrevIcon],[nyt,Bwt,ryt])):this.rightCalNextIcon.classList.contains(Bwt)||xft([this.rightCalNextIcon],[nyt,Bwt,ryt])}}}else this.isMaxDaysClicked=!1},t.prototype.removeTimeValueFromDate=function(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate())},t.prototype.removeClassDisabled=function(){for(var e=0,t=this.popupObj.element.querySelectorAll("."+Wwt+" td."+tyt);e<t.length;e++){var n=t[e];n.classList.contains(tyt)&&(Eft([n],[tyt,Bwt,ryt]),wft.add(n,"click",this.selectRange,this),this.isMobile||wft.add(n,"mouseover",this.hoverSelection,this))}this.isMobile?(this.nextIcon.classList.contains(nyt)&&Eft([this.nextIcon],[nyt,Bwt,ryt]),this.previousIcon.classList.contains(nyt)&&Eft([this.previousIcon],[nyt,Bwt,ryt])):(this.rightCalNextIcon.classList.contains(nyt)&&Eft([this.rightCalNextIcon],[nyt,Bwt,ryt]),this.rightCalPrevIcon.classList.contains(nyt)&&Eft([this.rightCalPrevIcon],[nyt,Bwt,ryt]),this.leftCalNextIcon.classList.contains(nyt)&&Eft([this.leftCalNextIcon],[nyt,Bwt,ryt]))},t.prototype.updateHeader=function(){var e={type:"date",skeleton:"yMMMd"};if(xpt(this.endValue)||xpt(this.startValue))this.popupObj.element.querySelector("."+$wt).textContent=this.l10n.getConstant("selectedDays");else{var t=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1;xpt(this.disabledDayCnt)||(t-=this.disabledDayCnt,this.disabledDayCnt=null),this.popupObj.element.querySelector("."+$wt).textContent=t.toString()+" "+this.l10n.getConstant("days")}this.isMobile?(xpt(this.startValue)?this.startButton.element.textContent=this.l10n.getConstant("startLabel"):this.startButton.element.textContent=this.globalize.formatDate(this.startValue,e),xpt(this.endValue)||xpt(this.startValue)?this.endButton.element.textContent=this.l10n.getConstant("endLabel"):this.endButton.element.textContent=this.globalize.formatDate(this.endValue,e)):(xpt(this.endValue)||xpt(this.startValue)?this.popupObj.element.querySelector("."+Twt).textContent=this.l10n.getConstant("endLabel"):this.popupObj.element.querySelector("."+Twt).textContent=this.globalize.formatDate(this.endValue,e),xpt(this.startValue)?this.popupObj.element.querySelector("."+Pwt).textContent=this.l10n.getConstant("startLabel"):this.popupObj.element.querySelector("."+Pwt).textContent=this.globalize.formatDate(this.startValue,e)),(this.isDateDisabled(this.startValue)||this.isDateDisabled(this.endValue)||!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue)&&(this.isMobile?(this.startButton.element.textContent=this.l10n.getConstant("startLabel"),this.endButton.element.textContent=this.l10n.getConstant("endLabel"),this.popupObj.element.querySelector("."+$wt).textContent=this.l10n.getConstant("selectedDays")):(this.popupObj.element.querySelector("."+$wt).textContent=this.l10n.getConstant("selectedDays"),this.popupObj.element.querySelector("."+Pwt).textContent=this.l10n.getConstant("startLabel"),this.popupObj.element.querySelector("."+Twt).textContent=this.l10n.getConstant("endLabel"))),this.popupObj.element.querySelector("#custom_range")&&(this.popupObj.element.querySelector("#custom_range").textContent=""!==this.l10n.getConstant("customRange")?this.l10n.getConstant("customRange"):"Custom Range")},t.prototype.removeSelection=function(){this.startValue=null,this.endValue=null,this.setValue(),this.removeSelectedAttributes(),this.popupObj&&(this.popupObj.element.querySelectorAll("."+jwt).length>0&&Eft(this.popupObj.element.querySelectorAll("."+jwt),[Dwt,Nwt,jwt]),this.popupObj.element.querySelectorAll("."+Xwt).length>0&&Eft(this.popupObj.element.querySelectorAll("."+Xwt),Xwt),this.popupObj.element.querySelectorAll("."+Vwt).length>0&&Eft(this.popupObj.element.querySelectorAll("."+Vwt),[Vwt]))},t.prototype.addSelectedAttributes=function(e,t,n,a){if(e){var r=this.globalize.formatDate(t,{type:"date",skeleton:"full"});!xpt(a)&&a?e.setAttribute("aria-label","The current start and end date is "+r):e.setAttribute("aria-label","The current "+(n?"start":"end")+" date is "+r),e.setAttribute("aria-selected","true")}},t.prototype.removeSelectedAttributes=function(){if(this.popupObj){for(var e=0,t=this.popupObj.element.querySelectorAll("."+Dwt);e<t.length;e++){(r=t[e]).setAttribute("aria-selected","false"),r.removeAttribute("aria-label")}for(var n=0,a=this.popupObj.element.querySelectorAll("."+Nwt);n<a.length;n++){var r;(r=a[n]).setAttribute("aria-selected","false"),r.removeAttribute("aria-label")}}},t.prototype.updateCalendarElement=function(e){e.classList.contains(_wt)?(this.calendarElement=this.leftCalendar,this.currentDate=this.leftCalCurrentDate,this.previousIcon=this.leftCalPrevIcon,this.nextIcon=this.leftCalNextIcon):(this.calendarElement=this.rightCalendar,this.currentDate=this.rightCalCurrentDate,this.previousIcon=this.rightCalPrevIcon,this.nextIcon=this.rightCalNextIcon),this.contentElement=e.querySelector("."+Jwt),this.tableBodyElement=Ift("."+Jwt+" tbody",e),this.table=e.querySelector("."+Jwt).getElementsByTagName("table")[0],this.headerTitleElement=e.querySelector("."+Ywt+" ."+qwt),this.headerElement=e.querySelector("."+Ywt)},t.prototype.navPrevMonth=function(e){e.preventDefault();var t=Oft(e.target,"."+_wt);t=xpt(t)?Oft(e.target,"."+Cwt):t,this.updateCalendarElement(t),this.navigatePrevious(e),!xpt(this.startValue)&&xpt(this.endValue)&&this.updateMinMaxDays(t),this.updateControl(t)},t.prototype.deviceNavigation=function(e){this.deviceCalendarEvent(),this.updateRange([this.popupObj.element.querySelector("."+Wwt)]),this.endButton.element.classList.contains(Iwt)&&this.updateMinMaxDays(this.popupObj.element.querySelector("."+Wwt)),this.endButton.element.classList.contains(Iwt)&&this.selectableDates(),this.currentView()===this.depth&&this.bindCalendarCellEvents(),this.removeFocusedDate()},t.prototype.updateControl=function(e,t){void 0===t&&(t=null),e.classList.contains(Cwt)?this.rightCalCurrentDate=new Date(+(t||this.currentDate)):this.leftCalCurrentDate=new Date(+this.currentDate),this.calendarIconEvent(),("Month"===this.depth&&this.leftCalendar.querySelector(".e-content").classList.contains("e-month")&&this.rightCalendar.querySelector(".e-content").classList.contains("e-month")||"Year"===this.depth&&this.leftCalendar.querySelector(".e-content").classList.contains("e-year")&&this.rightCalendar.querySelector(".e-content").classList.contains("e-year")||"Decade"===this.depth&&this.leftCalendar.querySelector(".e-content").classList.contains("e-decade")&&this.rightCalendar.querySelector(".e-content").classList.contains("e-decade")||this.isMobile)&&this.bindCalendarCellEvents(),this.removeFocusedDate(),this.updateRange([e])},t.prototype.navNextMonth=function(e){e.preventDefault();var t=Oft(e.target,"."+_wt);t=xpt(t)?Oft(e.target,"."+Cwt):t,this.updateCalendarElement(t),this.navigateNext(e),!xpt(this.startValue)&&xpt(this.endValue)&&this.updateMinMaxDays(t),this.updateControl(t)},t.prototype.isPopupOpen=function(){return!(xpt(this.popupObj)||!this.popupObj.element.classList.contains(Awt))},t.prototype.createRangeHeader=function(){var e=this.createElement("div",{className:"e-start-end"});if(this.isMobile){var t=this.createElement("button",{className:"e-end-btn"}),n=this.createElement("button",{className:Owt});this.startButton=new jgt({content:this.l10n.getConstant("startLabel")},n),this.endButton=new jgt({content:this.l10n.getConstant("endLabel")},t),e.appendChild(n),e.appendChild(t)}else{var a=this.createElement("a",{className:Pwt}),r=this.createElement("a",{className:Twt}),i=this.createElement("span",{className:"e-change-icon e-icons"});Hft(a,{"aria-atomic":"true","aria-live":"assertive","aria-label":"Start Date",role:"button"}),Hft(r,{"aria-atomic":"true","aria-live":"assertive","aria-label":"End Date",role:"button"}),e.appendChild(a),e.appendChild(i),e.appendChild(r),a.textContent=this.l10n.getConstant("startLabel"),r.textContent=this.l10n.getConstant("endLabel")}return e},t.prototype.disableInput=function(){this.strictMode?xpt(this.previousStartValue)||xpt(this.previousEndValue)||(this.startValue=this.previousStartValue,this.endValue=this.previousEndValue,this.setValue(),this.updateInput()):(this.updateInput(),this.clearRange(),this.setProperties({startDate:null},!0),this.setProperties({endDate:null},!0),this.startValue=null,this.endValue=null,this.setValue(),this.errorClass()),this.setProperties({enabled:!1},!0),Vgt.setEnabled(this.enabled,this.inputElement),this.bindEvents()},t.prototype.validateMinMax=function(){this.min=xpt(this.min)||!+this.min?this.min=new Date(1900,0,1):this.min,this.max=xpt(this.max)||!+this.max?this.max=new Date(2099,11,31):this.max,this.min<=this.max?(xpt(this.minDays)||xpt(this.maxDays)||this.maxDays>0&&this.minDays>0&&this.minDays>this.maxDays&&(this.maxDays=null),!xpt(this.minDays)&&this.minDays<0&&(this.minDays=null),!xpt(this.maxDays)&&this.maxDays<0&&(this.maxDays=null)):this.disableInput()},t.prototype.validateRangeStrict=function(){xpt(this.startValue)||(+this.startValue<=+this.min?(this.startValue=this.min,this.setValue()):+this.startValue>=+this.min&&+this.startValue>=+this.max&&(this.startValue=this.max)),xpt(this.endValue)||(+this.endValue>+this.max?(this.endValue=this.max,this.setValue()):+this.endValue<+this.min&&(this.endValue=this.min,this.setValue())),this.validateMinMaxDays()},t.prototype.validateRange=function(){this.validateMinMaxDays()},t.prototype.validateMinMaxDays=function(){if(!xpt(this.startValue)&&!xpt(this.endValue)){var e=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1;if(!xpt(this.minDays)&&this.minDays>0&&!(e>=this.minDays))if(this.strictMode){var t=new Date(+this.startValue);t.setDate(t.getDate()+(this.minDays-1)),+t>+this.max?(this.endValue=this.max,this.setValue()):(this.endValue=t,this.setValue())}else this.startValue=null,this.endValue=null,this.setValue();xpt(this.maxDays)||!(this.maxDays>0)||e<=this.maxDays||(this.strictMode?(this.endValue=new Date(+this.startValue),this.endValue.setDate(this.endValue.getDate()+(this.maxDays-1)),this.setValue()):(this.startValue=null,this.endValue=null,this.setValue()))}},t.prototype.renderCalendar=function(){this.calendarElement=this.createElement("div"),this.calendarElement.classList.add(Wwt),this.enableRtl&&this.calendarElement.classList.add("e-rtl"),Hft(this.calendarElement,{role:"calendar"}),e.prototype.createHeader.call(this),e.prototype.createContent.call(this)},t.prototype.isSameMonth=function(e,t){return e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()},t.prototype.isSameYear=function(e,t){return e.getFullYear()===t.getFullYear()},t.prototype.isSameDecade=function(e,t){var n=e.getFullYear(),a=t.getFullYear();return n-n%10==a-a%10},t.prototype.startMonthCurrentDate=function(){this.isSameMonth(this.min,this.max)||+this.currentDate>+this.max||this.isSameMonth(this.currentDate,this.max)?(this.currentDate=new Date(+this.max),this.currentDate.setDate(1),this.currentDate.setMonth(this.currentDate.getMonth()-1)):this.currentDate<this.min&&(this.currentDate=new Date(this.checkValue(this.min)))},t.prototype.selectNextMonth=function(){if(xpt(this.endValue)||xpt(this.startValue)||this.isSameMonth(this.endValue,this.currentDate)||this.isDateDisabled(this.endValue)||this.isDateDisabled(this.startValue))return this.currentDate.setDate(1),void this.currentDate.setMonth(this.currentDate.getMonth()+1);if(this.currentDate=new Date(+this.endValue),!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue){this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.currentDate.setDate(1);var e=this.currentDate.getMonth()+1;this.currentDate.setMonth(e)}},t.prototype.selectNextYear=function(){if(xpt(this.endValue)||xpt(this.startValue)||this.isSameYear(this.endValue,this.currentDate)||this.isDateDisabled(this.endValue)||this.isDateDisabled(this.startValue)){this.currentDate.setMonth(0);var e=this.currentDate.getFullYear()+1;this.currentDate.setFullYear(e)}else this.currentDate=new Date(+this.endValue),(!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue||!xpt(this.startValue)&&+this.startValue<+this.min)&&(this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.currentDate.setMonth(0),this.currentDate.setFullYear(this.currentDate.getFullYear()+1))},t.prototype.selectNextDecade=function(){if(xpt(this.endValue)||xpt(this.startValue)||this.isSameDecade(this.endValue,this.currentDate)||this.isDateDisabled(this.endValue)||this.isDateDisabled(this.startValue)){var e=this.currentDate.getFullYear()+10;this.currentDate.setFullYear(e)}else this.currentDate=new Date(+this.endValue),(!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue||!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&+this.startValue<+this.min)&&(this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.currentDate.setFullYear(this.currentDate.getFullYear()+10))},t.prototype.selectStartMonth=function(){xpt(this.startValue)?(this.currentDate=new Date((new Date).setHours(0,0,0,0)),this.startMonthCurrentDate()):!xpt(this.max)&&this.isSameMonth(this.startValue,this.max)?(this.currentDate=new Date(+this.max),this.currentDate.setDate(1),this.currentDate.setMonth(this.currentDate.getMonth()-1)):this.startValue>=this.min&&this.startValue<=this.max&&!this.isDateDisabled(this.startValue)?this.currentDate=new Date(+this.startValue):this.currentDate=new Date((new Date).setHours(0,0,0,0)),(!xpt(this.endValue)&&+this.endValue>+this.max||!xpt(this.startValue)&&+this.startValue<+this.min||!xpt(this.startValue)&&!xpt(this.endValue)&&+this.startValue>+this.endValue)&&(this.currentDate=new Date((new Date).setHours(0,0,0,0))),this.startMonthCurrentDate()},t.prototype.createCalendar=function(){var t=this.createElement("div",{className:"e-calendar-container"});if(this.isMobile){xpt(this.startValue)||(this.currentDate=new Date(+this.startValue)),e.prototype.validateDate.call(this),e.prototype.minMaxUpdate.call(this),e.prototype.render.call(this);var n=this.calendarElement.querySelector("."+Wwt+" ."+Fwt),a=this.calendarElement.querySelector("."+Wwt+" ."+Rwt);Zft(this.calendarElement.querySelector("."+Wwt+" ."+Uwt)),this.calendarElement.querySelector("."+Wwt+" ."+Ywt).appendChild(a),this.calendarElement.querySelector("."+Wwt+" ."+Ywt).appendChild(n),Sft([n],this.calendarElement.querySelector("."+Wwt+" ."+Ywt)),this.deviceCalendar=this.calendarElement,t.appendChild(this.calendarElement),this.headerTitleElement=this.calendarElement.querySelector("."+Wwt+" ."+Ywt+" ."+qwt)}else{this.selectStartMonth(),this.renderCalendar(),this.leftCalCurrentDate=new Date(+this.currentDate),this.calendarElement.classList.add(_wt),this.leftCalPrevIcon=this.calendarElement.querySelector("."+_wt+" ."+Fwt),this.leftCalNextIcon=this.calendarElement.querySelector("."+_wt+" ."+Rwt),this.leftTitle=this.calendarElement.querySelector("."+_wt+" ."+qwt),Zft(this.calendarElement.querySelector("."+_wt+" ."+Uwt)),this.calendarElement.querySelector("."+_wt+" ."+Ywt).appendChild(this.leftCalNextIcon),this.calendarElement.querySelector("."+_wt+" ."+Ywt).appendChild(this.leftCalPrevIcon),Sft([this.leftCalPrevIcon],this.calendarElement.querySelector("."+_wt+" ."+Ywt)),this.leftCalendar=this.calendarElement;var r=this.createElement("div",{className:"e-left-container"}),i=this.createElement("div",{className:"e-right-container"});r.appendChild(this.leftCalendar),t.appendChild(r),this.isMobile||wft.add(this.leftTitle,"click",this.leftNavTitle,this),"Month"===this.start&&this.selectNextMonth(),"Year"===this.start&&this.selectNextYear(),"Decade"===this.start&&this.selectNextDecade(),this.renderCalendar(),this.rightCalCurrentDate=new Date(+this.currentDate),xft([this.calendarElement],Cwt),this.rightCalendar=this.calendarElement,Eft([this.leftCalendar&&this.leftCalendar.querySelector(".e-content tbody")],"e-zoomin"),Eft([this.rightCalendar&&this.rightCalendar.querySelector(".e-content tbody")],"e-zoomin"),this.rightCalPrevIcon=this.calendarElement.querySelector("."+Cwt+" ."+Fwt),this.rightCalNextIcon=this.calendarElement.querySelector("."+Cwt+" ."+Rwt),this.rightTitle=this.calendarElement.querySelector("."+Cwt+" ."+qwt),Zft(this.calendarElement.querySelector("."+Cwt+" ."+Uwt)),this.calendarElement.querySelector("table").setAttribute("tabindex","0"),this.calendarElement.querySelector("."+Cwt+" ."+Ywt).appendChild(this.rightCalNextIcon),this.calendarElement.querySelector("."+Cwt+" ."+Ywt).appendChild(this.rightCalPrevIcon),Sft([this.rightCalPrevIcon],this.calendarElement.querySelector("."+Cwt+" ."+Ywt)),i.appendChild(this.rightCalendar),t.appendChild(i),this.isMobile||wft.add(this.rightTitle,"click",this.rightNavTitle,this)}return t},t.prototype.leftNavTitle=function(e){this.isPopupOpen()&&(this.calendarElement=this.leftCalendar,this.calendarNavigation(e,this.calendarElement))},t.prototype.calendarNavigation=function(t,n){this.table=n.querySelector("table"),this.headerTitleElement=n.querySelector(".e-title"),this.tableBodyElement=n.querySelector("tbody"),this.tableHeadElement=n.querySelector("thead"),this.contentElement=n.querySelector(".e-content"),this.updateCalendarElement(n),e.prototype.navigateTitle.call(this,t),this.updateNavIcons()},t.prototype.rightNavTitle=function(e){this.isPopupOpen()&&(this.calendarElement=this.rightCalendar,this.calendarNavigation(e,this.calendarElement))},t.prototype.clickEventEmitter=function(e){this.isMobile||(Oft(e.target,".e-calendar.e-left-calendar")?(this.calendarElement=this.leftCalendar,this.updateCalendarElement(this.leftCalendar)):(this.calendarElement=this.rightCalendar,this.updateCalendarElement(this.rightCalendar)))},t.prototype.currentView=function(){return e.prototype.currentView.call(this)},t.prototype.getCalendarView=function(e){return"Year"===e?"Year":"Decade"===e?"Decade":"Month"},t.prototype.navigatedEvent=function(t){if(this.trigger("navigated",this.navigatedArgs),!xpt(this.popupObj)){var n=this.getCalendarView(this.currentView());if(this.isMobile)n===this.depth?(this.bindCalendarCellEvents(),this.deviceNavigation(),this.removeFocusedDate(),this.checkMinMaxDays()):this.selectableDates();else if(this.isMobile||n!==this.depth)this.updateNavIcons(),this.calendarIconEvent();else{if((this.calendarElement.classList.contains("e-left-calendar")?this.leftCalendar:this.rightCalendar)!==this.leftCalendar||(!t||t.currentTarget.children[0].classList.contains("e-icons"))&&xpt(this.controlDown))(t&&!t.currentTarget.children[0].classList.contains("e-icons")||!xpt(this.controlDown))&&(this.rightCalCurrentDate=new Date(+this.currentDate),this.effect="",this.currentDate=this.rightCalCurrentDate,this.updateCalendarElement(this.rightCalendar),this.updateControl(this.rightCalendar),this.updateCalendarElement(this.leftCalendar),this.startValue&&xpt(this.endValue)&&("Month"===n&&this.startValue.getMonth()<this.rightCalCurrentDate.getMonth()&&this.startValue.getFullYear()<=this.rightCalCurrentDate.getFullYear()||"Year"===n&&this.startValue.getFullYear()<this.rightCalCurrentDate.getFullYear())?e.prototype.navigateTo.call(this,n,new Date(+this.startValue)):e.prototype.navigateTo.call(this,n,this.leftCalCurrentDate),this.updateControl(this.leftCalendar),this.updateNavIcons(),this.calendarIconEvent(),this.calendarIconRipple(),this.controlDown=null);else{this.leftCalCurrentDate=new Date(+this.currentDate),this.effect="",this.currentDate=this.leftCalCurrentDate,this.updateCalendarElement(this.leftCalendar),this.updateControl(this.leftCalendar),this.updateCalendarElement(this.rightCalendar),e.prototype.navigateTo.call(this,n,this.rightCalCurrentDate);var a=this.rightCalCurrentDate?this.rightCalCurrentDate:this.currentDate;this.updateControl(this.rightCalendar,a),this.updateNavIcons(),this.calendarIconEvent(),this.calendarIconRipple(),this.controlDown=null}this.checkMinMaxDays()}}},t.prototype.createControl=function(){var e=this.createElement("div",{className:Gwt}),t=this.createElement("div",{className:"e-range-header"}),n=this.createRangeHeader();t.appendChild(n);var a=this.createElement("div",{className:$wt});Hft(a,{"aria-label":"Selected Days"}),a.textContent=this.l10n.getConstant("selectedDays"),t.appendChild(a);var r=this.createElement("div",{className:"e-separator"}),i=this.createCalendar();e.appendChild(t),e.appendChild(r),e.appendChild(i);var o=this.createElement("div",{className:"e-footer"}),l=this.createElement("button",{className:"e-cancel "+syt+" "+cyt}),s=this.createElement("button");xft([s],["e-apply",syt,"e-primary",cyt]),o.appendChild(s),o.appendChild(l);var c=!xpt(this.startValue)&&!xpt(this.endValue);(this.cancelButton=new jgt({content:this.l10n.getConstant("cancelText")},l),this.applyButton=new jgt({content:this.l10n.getConstant("applyText"),disabled:!c},s),wft.add(s,"click",this.applyFunction,this),wft.add(l,"click",this.cancelFunction,this),this.popupWrapper.appendChild(e),this.isMobile)||(Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)||(this.createPresets(),this.listRippleEffect(),xft([e],"e-range-border"),xft([this.popupWrapper],"e-preset-wrapper"),this.popupWrapper.querySelector("."+Kwt).style.height=this.popupWrapper.querySelector("."+Gwt).getBoundingClientRect().height+"px"));this.popupWrapper.appendChild(o),this.isMobile&&this.deviceHeaderUpdate(),this.renderPopup()},t.prototype.cancelFunction=function(e){document.activeElement!==this.inputElement&&(this.preventFocus=!0,this.inputElement.focus(),xft([this.inputWrapper.container],[Lwt])),e.preventDefault(),this.isKeyPopup&&(this.inputElement.focus(),this.isKeyPopup=!1),this.startValue=null,this.endValue=null,this.removeSelection(),this.hide(e)},t.prototype.deviceHeaderUpdate=function(){xpt(this.startValue)&&xpt(this.endValue)?(this.endButton.element.setAttribute("disabled",""),this.startButton.element.classList.add(Iwt)):xpt(this.startValue)||this.startButton.element.classList.add(Iwt)},t.prototype.applyFunction=function(e){var t=!1;"touchstart"!==e.type&&e.preventDefault(),this.closeEventArgs&&this.closeEventArgs.cancel&&(this.startValue=this.popupWrapper.querySelector(".e-start-date")&&this.getIdValue(null,this.popupWrapper.querySelector(".e-start-date")),this.endValue=this.popupWrapper.querySelector(".e-end-date")&&this.getIdValue(null,this.popupWrapper.querySelector(".e-end-date")),this.setValue()),document.activeElement!==this.inputElement&&(this.preventFocus=!0,this.inputElement.focus(),xft([this.inputWrapper.container],[Lwt])),"touchstart"!==e.type&&this.closeEventArgs&&!this.closeEventArgs.cancel&&e.preventDefault(),xpt(this.startValue)||xpt(this.endValue)?this.hide(e||null):(this.previousStartValue=new Date(+this.startValue),this.previousEndValue=new Date(+this.endValue),this.previousEleValue=this.inputElement.value,Vgt.setValue(this.rangeArgs(e).text,this.inputElement,this.floatLabelType,this.showClearButton),+this.initStartDate===+this.startValue&&+this.initEndDate===+this.endValue||(t=!0),this.changeTrigger(e),this.hide(e||null),this.errorClass(),t=!0),Oft(e.target,"."+Swt)||t||this.focusOut(),this.isMobile||(this.isKeyPopup=!1,this.isRangeIconClicked&&(this.inputWrapper.container.children[1].focus(),this.keyInputConfigs=bpt(this.keyInputConfigs,this.keyConfigs),this.popupKeyboardModule=new Vmt(this.inputWrapper.container.children[1],{eventName:"keydown",keyConfigs:this.keyInputConfigs,keyAction:this.popupKeyActionHandle.bind(this)})))},t.prototype.onMouseClick=function(e,t){if("touchstart"!==e.type){var n=Oft(t||e.target,"."+iyt),a=n&&n.classList.contains(Iwt);n&&n.classList.contains(iyt)&&this.setListSelection(n,e),this.preventFocus=!0,this.inputElement.focus(),this.isMobile||(this.preventFocus=!0,n&&n.classList.contains(iyt)&&"custom_range"===n.getAttribute("id")?this.leftCalendar.children[1].firstElementChild.focus():a||"keydown"!==e.type||this.inputElement.focus())}},t.prototype.onMouseOver=function(e){var t=Oft(e.target,"."+iyt);t&&t.classList.contains(iyt)&&!t.classList.contains(oyt)&&xft([t],oyt)},t.prototype.onMouseLeave=function(e){var t=Oft(e.target,"."+oyt);xpt(t)||Eft([t],oyt)},t.prototype.setListSelection=function(e,t){if(e&&(!e.classList.contains(Iwt)||this.isMobile&&e.classList.contains(Iwt))){if(this.isMobile&&e.classList.contains(Iwt))return this.activeIndex=Array.prototype.slice.call(this.liCollections).indexOf(e),"custom_range"===this.presetsItem[this.activeIndex].id?void this.renderCustomPopup():void 0;this.removeListSelection(),this.activeIndex=Array.prototype.slice.call(this.liCollections).indexOf(e),xft([e],Iwt),e.setAttribute("aria-selected","true");var n=this.presetsItem[this.activeIndex];"custom_range"===n.id?this.renderCustomPopup():this.applyPresetRange(n,t)}},t.prototype.removeListSelection=function(){var e=this.presetElement.querySelector("."+Iwt);xpt(e)||(Eft([e],Iwt),e.removeAttribute("aria-selected"))},t.prototype.setValue=function(){this.modelValue=[this.startValue,this.endValue]},t.prototype.applyPresetRange=function(e,t){this.hide(null),this.presetsItem[this.presetsItem.length-1].start=null,this.presetsItem[this.presetsItem.length-1].end=null,this.startValue=e.start,this.endValue=e.end,this.setValue(),this.refreshControl(),this.trigger("select",this.rangeArgs(t)),this.changeTrigger(t),this.previousEleValue=this.inputElement.value,this.isCustomRange=!1,this.leftCalendar=this.rightCalendar=null,this.isKeyPopup&&(this.isRangeIconClicked=!1,this.inputElement.focus())},t.prototype.showPopup=function(e,t){this.presetHeight(),1e3===this.zIndex?this.popupObj.show(null,this.element):this.popupObj.show(null,null),this.isMobile&&this.popupObj.refreshPosition()},t.prototype.renderCustomPopup=function(){this.isCustomWindow=!0,this.popupObj.hide(),this.popupWrapper=this.createElement("div",{id:this.element.id+"_popup",className:Zwt+" "+Awt}),this.renderControl(),this.openEventArgs.appendTo.appendChild(this.popupWrapper),this.showPopup(),this.isCustomRange=!0,this.isMobile||this.calendarFocus()},t.prototype.listRippleEffect=function(){for(var e=0,t=this.liCollections;e<t.length;e++){omt(t[e])}},t.prototype.createPresets=function(){if(!Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)){this.presetElement=this.createElement("div",{className:Kwt,attrs:{tabindex:"0"}});var e=vwt.createList(this.createElement,this.presetsItem,null,!0);Hft(e,{role:"listbox","aria-hidden":"false",id:this.element.id+"_options"}),this.presetElement.appendChild(e),this.popupWrapper.appendChild(this.presetElement);var t=this.presetElement.querySelector("#custom_range");xpt(t)||(t.textContent=""!==this.l10n.getConstant("customRange")?this.l10n.getConstant("customRange"):"Custom Range"),this.liCollections=this.presetElement.querySelectorAll("."+iyt),this.wireListEvents(),this.isMobile&&(this.presetElement.style.width=this.inputWrapper.container.getBoundingClientRect().width+"px"),!xpt(this.activeIndex)&&this.activeIndex>-1&&xft([this.liCollections[this.activeIndex]],Iwt)}},t.prototype.wireListEvents=function(){wft.add(this.presetElement,"click",this.onMouseClick,this),this.isMobile||(wft.add(this.presetElement,"mouseover",this.onMouseOver,this),wft.add(this.presetElement,"mouseout",this.onMouseLeave,this))},t.prototype.unWireListEvents=function(){xpt(this.presetElement)||(wft.remove(this.presetElement,"click touchstart",this.onMouseClick),this.isMobile||(wft.remove(this.presetElement,"mouseover",this.onMouseOver),wft.remove(this.presetElement,"mouseout",this.onMouseLeave)))},t.prototype.renderPopup=function(){var e=this;this.popupWrapper.classList.add("e-control");var t=this.popupWrapper.getBoundingClientRect().width;xpt(this.cssClass)||""===this.cssClass.trim()||(this.popupWrapper.className+=" "+this.cssClass),this.isMobile&&this.isCustomWindow&&(this.modal=this.createElement("div"),document.body.appendChild(this.modal)),this.popupObj=new Dgt(this.popupWrapper,{relateTo:this.isMobile&&this.isCustomWindow?document.body:xpt(this.targetElement)?this.inputWrapper.container:this.targetElement,position:this.isMobile?Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)||this.isCustomWindow?{X:"center",Y:"center"}:{X:"left",Y:"bottom"}:this.enableRtl?{X:"left",Y:"bottom"}:{X:"right",Y:"bottom"},offsetX:this.isMobile||this.enableRtl?0:-t,offsetY:4,collision:this.isMobile?Ept(this.presets[0].start&&this.presets[0].end&&this.presets[0].label)||this.isCustomWindow?{X:"fit",Y:"fit"}:{X:"fit"}:{X:"fit",Y:"flip"},targetType:this.isMobile&&this.isCustomWindow?"container":"relative",enableRtl:this.enableRtl,zIndex:this.zIndex,open:function(){Hft(e.inputElement,{"aria-expanded":"true"}),xft([e.inputWrapper.buttons[0]],Iwt),e.isMobile||(e.cancelButton&&(e.btnKeyboardModule=new Vmt(e.cancelButton.element,{eventName:"keydown",keyAction:e.popupKeyActionHandle.bind(e),keyConfigs:{tab:"tab",altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"}}),e.btnKeyboardModule=new Vmt(e.applyButton.element,{eventName:"keydown",keyAction:e.popupKeyActionHandle.bind(e),keyConfigs:{altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"}})),xpt(e.leftCalendar)||e.isRangeIconClicked||e.calendarFocus(),xpt(e.presetElement)||(e.keyInputConfigs=bpt(e.keyInputConfigs,e.keyConfigs),e.presetKeyboardModule=new Vmt(e.presetElement,{eventName:"keydown",keyAction:e.presetKeyActionHandler.bind(e),keyConfigs:e.keyInputConfigs}),e.presetKeyboardModule=new Vmt(e.presetElement,{eventName:"keydown",keyAction:e.popupKeyActionHandle.bind(e),keyConfigs:{altRightArrow:"alt+rightarrow",altLeftArrow:"alt+leftarrow"}}),xpt(e.leftCalendar)?(e.preventBlur=!0,e.presetElement.focus()):e.presetElement.setAttribute("tabindex","-1")),e.popupKeyBoardHandler()),e.isMobile&&!gft.isDevice&&wft.add(document,"keydown",e.popupCloseHandler,e)},close:function(){Hft(e.inputElement,{"aria-expanded":"false"}),Eft([e.inputWrapper.buttons[0]],Iwt),e.isRangeIconClicked&&e.inputWrapper.container.children[1].focus(),Ept(e.presets[0].start&&e.presets[0].end&&e.presets[0].label)||e.unWireListEvents(),xpt(e.popupObj)||(xpt(e.popupObj.element.parentElement)||Cft(e.popupObj.element),e.popupObj.destroy(),e.popupObj=null),e.isMobile&&!gft.isDevice&&wft.remove(document,"keydown",e.popupCloseHandler)},targetExitViewport:function(){gft.isDevice||e.hide()}}),this.isMobile&&(this.popupObj.element.classList.add(ayt),this.isMobile||this.popupObj.element.classList.add("e-bigger")),this.isMobile&&this.isCustomWindow&&(xft([this.modal],[ayt,Zwt,"e-range-modal"]),document.body.className+=" "+lyt,this.modal.style.display="block"),wft.add(document,"mousedown touchstart",this.documentHandler,this)},t.prototype.popupCloseHandler=function(e){if(27===e.keyCode)this.hide(e)},t.prototype.calendarFocus=function(){var e=this.popupObj&&this.popupObj.element.querySelector("."+Dwt);if(e){var t=Oft(e,"."+Cwt);t=xpt(t)?this.leftCalendar:t,this.isRangeIconClicked?this.inputWrapper.container.focus():(this.preventBlur=!0,t.children[1].firstElementChild.focus()),xft([e],Xwt)}else this.isRangeIconClicked?this.inputWrapper.container.focus():(this.preventBlur=!0,this.leftCalendar.children[1].firstElementChild.focus())},t.prototype.presetHeight=function(){var e=this.popupObj&&this.popupObj.element.querySelector("."+Kwt),t=this.popupObj&&this.popupObj.element.querySelector("."+Gwt);xpt(e)||xpt(t)||(e.style.height=t.getBoundingClientRect().height+"px")},t.prototype.presetKeyActionHandler=function(e){switch(e.action){case"moveDown":this.listMoveDown(e),this.setScrollPosition(),e.preventDefault();break;case"moveUp":this.listMoveUp(e),this.setScrollPosition(),e.preventDefault();break;case"enter":var t=this.getHoverLI(),n=this.getActiveLI();if(!xpt(this.leftCalendar)&&!xpt(n))if(xpt(t)||!xpt(n)&&n===t)if(this.activeIndex=Array.prototype.slice.call(this.liCollections).indexOf(n),"custom_range"===this.presetsItem[this.activeIndex].id)return this.calendarFocus(),n.classList.remove(oyt),void e.preventDefault();xpt(t)&&xpt(n)||this.onMouseClick(e,t||n),e.preventDefault();break;case"tab":if(this.leftCalendar){var a=this.getHoverLI();xpt(a)||a.classList.remove(oyt)}else this.hide(e),e.preventDefault()}},t.prototype.listMoveDown=function(e){var t=this.getHoverLI(),n=this.getActiveLI();if(xpt(t))if(xpt(n))xft([this.liCollections[0]],oyt);else{var a;!xpt(a=n.nextElementSibling)&&a.classList.contains(iyt)&&xft([a],oyt)}else!xpt(a=t.nextElementSibling)&&a.classList.contains(iyt)&&(Eft([t],oyt),xft([a],oyt))},t.prototype.listMoveUp=function(e){var t=this.getHoverLI(),n=this.getActiveLI();if(xpt(t)){if(!xpt(n)){var a;!xpt(a=n.previousElementSibling)&&a.classList.contains(iyt)&&xft([a],oyt)}}else!xpt(a=t.previousElementSibling)&&a.classList.contains(iyt)&&(Eft([t],oyt),xft([a],oyt))},t.prototype.getHoverLI=function(){return this.presetElement.querySelector("."+oyt)},t.prototype.getActiveLI=function(){return this.presetElement.querySelector("."+Iwt)},t.prototype.popupKeyBoardHandler=function(){this.popupKeyboardModule=new Vmt(this.popupWrapper,{eventName:"keydown",keyAction:this.popupKeyActionHandle.bind(this),keyConfigs:{escape:"escape"}}),this.keyInputConfigs=bpt(this.keyInputConfigs,this.keyConfigs),this.popupKeyboardModule=new Vmt(this.inputWrapper.container.children[1],{eventName:"keydown",keyAction:this.popupKeyActionHandle.bind(this),keyConfigs:this.keyInputConfigs})},t.prototype.setScrollPosition=function(){var e=this.presetElement.getBoundingClientRect().height,t=this.presetElement.querySelector("."+oyt),n=this.presetElement.querySelector("."+Iwt),a=xpt(t)?n:t;if(!xpt(a)){var r=a.nextElementSibling,i=r?r.offsetTop:a.offsetTop,o=a.getBoundingClientRect().height;i+a.offsetTop>e?this.presetElement.scrollTop=r?i-(e/2+o/2):i:this.presetElement.scrollTop=0}},t.prototype.popupKeyActionHandle=function(e){var t=Oft(e.target,"."+Kwt);switch(e.action){case"escape":this.isPopupOpen()?(this.isKeyPopup&&(this.inputElement.focus(),this.isKeyPopup=!1),this.hide(e)):this.inputWrapper.container.children[1].blur();break;case"enter":this.isPopupOpen()?this.inputWrapper.container.children[1].focus():this.show(null,e);break;case"tab":this.hide(e);break;case"altRightArrow":xpt(t)?document.activeElement===this.cancelButton.element&&!0!==this.applyButton.element.disabled?this.applyButton.element.focus():this.leftCalendar.children[1].firstElementChild.focus():this.cancelButton.element.focus(),e.preventDefault();break;case"altLeftArrow":xpt(t)?document.activeElement===this.applyButton.element&&!0!==this.applyButton.element.disabled?this.cancelButton.element.focus():xpt(this.presetElement)||document.activeElement!==this.cancelButton.element?this.rightCalendar.children[1].firstElementChild.focus():this.presetElement.focus():this.rightCalendar.children[1].firstElementChild.focus(),e.preventDefault()}},t.prototype.documentHandler=function(e){if(!xpt(this.popupObj)){var t=e.target;this.inputWrapper.container.contains(t)&&(xpt(this.popupObj)||Oft(t,'[id="'+this.popupWrapper.id+'"]'))||"touchstart"!==e.type&&("mousedown"===e.type||this.closeEventArgs&&!this.closeEventArgs.cancel)&&e.preventDefault(),!xpt(this.targetElement)&&(xpt(this.targetElement)||t===this.targetElement)||Oft(t,'[id="'+this.popupWrapper.id+'"]')||Oft(t,"."+Swt)===this.inputWrapper.container||Oft(t,".e-daterangepicker.e-popup")&&!t.classList.contains("e-day")||(this.preventBlur=!1,this.isPopupOpen()&&document.body.contains(this.popupObj.element)&&(this.applyFunction(e),this.isMobile||(this.isRangeIconClicked=!1)))}},t.prototype.createInput=function(){var e=this.cssClass;xpt(this.cssClass)||""===this.cssClass||(e=this.cssClass.replace(/\s+/g," ").trim()),this.inputWrapper=Vgt.createInput({floatLabelType:this.floatLabelType,element:this.inputElement,properties:{readonly:this.readonly,placeholder:this.placeholder,cssClass:e,enabled:this.enabled,enableRtl:this.enableRtl,showClearButton:this.showClearButton},buttons:["e-input-group-icon e-range-icon e-icons"]},this.createElement),Hft(this.inputElement,{"aria-readonly":this.readonly?"true":"false",tabindex:"0","aria-haspopup":"true","aria-activedescendant":"null","aria-owns":this.element.id+"_popup","aria-expanded":"false",role:"combobox",autocomplete:"off","aria-disabled":this.enabled?"false":"true",autocorrect:"off",autocapitalize:"off",spellcheck:"false"}),Vgt.addAttributes({"aria-label":"select"},this.inputWrapper.buttons[0]),xpt(this.placeholder)||""===this.placeholder.trim()||Vgt.addAttributes({"aria-placeholder":this.placeholder},this.inputElement),this.setEleWidth(this.width),xft([this.inputWrapper.container],"e-date-range-wrapper"),xpt(this.inputElement.getAttribute("name"))&&Hft(this.inputElement,{name:this.element.id}),"hidden"===this.inputElement.type&&(this.inputWrapper.container.style.display="none"),this.refreshControl(),this.previousEleValue=this.inputElement.value,this.inputElement.setAttribute("value",this.inputElement.value),this.startCopy=this.startDate,this.endCopy=this.endDate},t.prototype.setEleWidth=function(e){this.inputWrapper.container.style.width="string"==typeof e?this.width:"number"==typeof e?Apt(this.width):"100%"},t.prototype.adjustLongHeaderWidth=function(){"Wide"===this.dayHeaderFormat&&xft([this.popupWrapper],"e-daterange-day-header-lg")},t.prototype.refreshControl=function(){this.validateMinMax(),this.strictMode&&this.validateRangeStrict();var e=this.disabledDates();this.strictMode&&e&&(this.startValue=this.previousStartValue,this.setProperties({startDate:this.startValue},!0),this.endValue=this.previousEndValue,this.setProperties({endDate:this.endValue},!0),this.setValue()),this.updateInput(),this.strictMode||this.validateRange(),!this.strictMode&&e&&this.clearRange(),xpt(this.endValue)||xpt(this.startValue)||e||this.disabledDateRender(),this.errorClass(),this.previousStartValue=xpt(this.startValue)||isNaN(+this.startValue)?null:new Date(+this.startValue),this.previousEndValue=xpt(this.endValue)||isNaN(+this.endValue)?null:new Date(+this.endValue)},t.prototype.updateInput=function(){if(!xpt(this.endValue)&&!xpt(this.startValue)){var e={format:this.formatString,type:"date",skeleton:"yMd"},t=this.globalize.formatDate(this.startValue,e),n=this.globalize.formatDate(this.endValue,e);Vgt.setValue(t+" "+this.separator+" "+n,this.inputElement,this.floatLabelType,this.showClearButton),this.previousStartValue=new Date(+this.startValue),this.previousEndValue=new Date(+this.endValue)}!this.strictMode&&xpt(this.value)&&this.invalidValueString&&Vgt.setValue(this.invalidValueString,this.inputElement,this.floatLabelType,this.showClearButton)},t.prototype.checkInvalidRange=function(e){if(!xpt(e)){var t=!1,n=void 0,a=void 0,r=null,i=null,o=null,l=!1,s=!1,c=!1;if("string"==typeof e){var d=e.split(" "+this.separator+" ");2===d.length?(r=d[0],i=d[1]):(t=!0,o=e)}else e.length>0?(n=e[0],a=e[1]):(n=e.start,a=e.end),n instanceof Date||"object"==typeof n?n instanceof Date?l=!0:xpt(n)||(c=!0):r=this.getstringvalue(n),a instanceof Date||"object"==typeof a?a instanceof Date?s=!0:xpt(a)||(c=!0):i=this.getstringvalue(a);(xpt(r)&&!l&&!xpt(i)||!xpt(r)&&!s&&xpt(i))&&(t=!0),c&&(r=i=o=null,t=!0),r&&(t=t||this.checkInvalidValue(r)),i&&(t=t||this.checkInvalidValue(i)),t&&(l&&!c&&(r=n.toLocaleDateString()),s&&!c&&(i=a.toLocaleDateString()),xpt(r)||xpt(i)?xpt(r)?xpt(i)||(o=i):o=r:o=r+" "+this.separator+" "+i,this.invalidValueString=o,this.setProperties({value:null},!0),this.setProperties({startValue:null},!0),this.setProperties({endValue:null},!0),this.startDate=null,this.endDate=null)}},t.prototype.getstringvalue=function(e){var t=null;return xpt(e)||"number"!=typeof e?xpt(e)||"string"!=typeof e||(t=""+e):t=e.toString(),t},t.prototype.checkInvalidValue=function(e){var t,n=e,a=!1;if(t={format:this.formatString,type:"date",skeleton:"yMd"},"string"!=typeof n)a=!0;else{var r=new aft(this.locale);if(!this.checkDateValue(r.parseDate(n,t))){var i=null;i=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,(!/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/.test(n)&&!i.test(n)||/^[a-zA-Z0-9- ]*$/.test(n)||isNaN(+new Date(this.checkValue(n))))&&(a=!0)}}return a},t.prototype.isDateDisabled=function(e){if(xpt(e))return!1;var t=new Date(+e);if(+t<+this.min||+t>+this.max)return!0;this.virtualRenderCellArgs={date:t,isDisabled:!1};var n=this.virtualRenderCellArgs;return this.virtualRenderCellEvent(n),!!n.isDisabled},t.prototype.disabledDateRender=function(){this.disabledDays=[],this.disabledDayCnt=null;for(var e=new Date(+this.startValue),t=0;+e<=+this.endValue&&+this.endValue<=+this.max;){this.virtualRenderCellArgs={date:e,isDisabled:!1};var n=this.virtualRenderCellArgs;this.virtualRenderCellEvent(n),n.isDisabled&&(this.disabledDays.push(new Date(+n.date)),+e>+this.startValue&&+e<+this.endValue&&t++),this.addDay(e,1,null,this.max,this.min)}this.disabledDayCnt=t},t.prototype.virtualRenderCellEvent=function(e){bpt(this.virtualRenderCellArgs,{name:"renderDayCell"}),this.trigger("renderDayCell",e)},t.prototype.disabledDates=function(){var e=!1,t=!1;return xpt(this.endValue)||xpt(this.startValue)||(e=this.isDateDisabled(this.startValue),t=this.isDateDisabled(this.endValue),this.isPopupOpen()||(this.currentDate=null),this.setValue()),e||t},t.prototype.setModelValue=function(){this.value||null!==this.startDate||null!==this.endDate?null===this.value||null===this.value.start?null===this.value?this.setProperties({value:[this.startDate,this.endDate]},!0):null===this.value.start&&this.setProperties({value:{start:this.startDate,end:this.endDate}},!0):this.value&&this.value.length>0||this.valueType&&this.valueType.length>0?(+this.startDate===+this.value[0]&&+this.endDate===+this.value[1]||this.setProperties({value:[this.startDate,this.endDate]},!0),this.value&&null==this.value[0]&&null==this.value[1]&&this.setProperties({value:null},!0)):this.value&&this.value.start&&this.setProperties({value:{start:this.startDate,end:this.endDate}},!0):this.setProperties({value:null},!0),this.createHiddenInput()},t.prototype.dispatchEvent=function(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!1,!0),e.dispatchEvent(n),this.firstHiddenChild.dispatchEvent(n)},t.prototype.changeTrigger=function(e){+this.initStartDate===+this.startValue&&+this.initEndDate===+this.endValue||(this.setProperties({endDate:this.checkDateValue(this.endValue)},!0),this.setProperties({startDate:this.checkDateValue(this.startValue)},!0),this.setModelValue(),this.isAngular&&this.preventChange?this.preventChange=!1:this.trigger("change",this.rangeArgs(e))),this.previousEleValue=this.inputElement.value,this.initStartDate=this.checkDateValue(this.startValue),this.initEndDate=this.checkDateValue(this.endValue)},t.prototype.navigateTo=function(t,n){if(this.isPopupOpen()){if("month"===t.toLowerCase())t="Month";else if("year"===t.toLowerCase())t="Year";else{if("decade"!==t.toLowerCase())return;t="Decade"}this.getViewNumber(t)<this.getViewNumber(this.depth)&&(t=this.depth),this.isMobile?e.prototype.navigateTo.call(this,t,n):(n<this.min?n=new Date(+this.min):n>=this.max&&(n=new Date(+this.max)),"Month"===t&&this.isSameMonth(n,this.max)?n=new Date(this.max.getFullYear(),this.max.getMonth()-1,this.min.getDate()):"Year"===t&&this.isSameYear(n,this.max)?n=new Date(this.max.getFullYear()-1,this.max.getMonth(),this.max.getDate()):"Decade"===t&&this.isSameDecade(n,this.max)&&(n=new Date(this.max.getFullYear()-10,this.max.getMonth(),this.max.getDate())),this.leftCalCurrentDate=n,this.navigate(this.leftCalendar,this.leftCalCurrentDate,t),n="Month"===t?new Date(this.currentDate.setMonth(this.currentDate.getMonth()+1)):"Year"===t?new Date(this.currentDate.setFullYear(this.currentDate.getFullYear()+1)):new Date(this.currentDate.setFullYear(this.currentDate.getFullYear()+10)),this.rightCalCurrentDate=n,this.navigate(this.rightCalendar,this.rightCalCurrentDate,t),this.leftKeyboardModule=this.rightKeyboardModule=null,this.updateNavIcons()),this.currentView()===this.depth&&this.bindCalendarCellEvents(),this.removeFocusedDate(),this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar])}},t.prototype.navigate=function(t,n,a){this.calendarElement=t,this.table=t.querySelector("table"),this.tableBodyElement=t.querySelector("tbody"),this.headerTitleElement=t.querySelector(".e-title"),this.tableHeadElement=t.querySelector("thead"),this.contentElement=t.querySelector(".e-content"),this.previousIcon=t.querySelector(".e-prev"),this.nextIcon=t.querySelector(".e-next"),this.effect="e-zoomin",e.prototype.navigateTo.call(this,a,n)},t.prototype.focusIn=function(){document.activeElement!==this.inputElement&&this.enabled&&(xft([this.inputWrapper.container],[Lwt]),this.inputElement.focus())},t.prototype.focusOut=function(){var e=this.preventBlur;document.activeElement===this.inputElement&&(Eft([this.inputWrapper.container],[Lwt]),this.preventBlur=!1,this.inputElement.blur(),this.preventBlur=e)},t.prototype.destroy=function(){this.unBindEvents(),this.hide(null);var t={"aria-readonly":this.readonly?"true":"false",tabindex:"0","aria-haspopup":"true","aria-activedescendant":"null","aria-owns":this.element.id+"_popup","aria-expanded":"false",role:"combobox",autocomplete:"off","aria-disabled":this.enabled?"false":"true",autocorrect:"off",autocapitalize:"off","aria-invalid":"false",spellcheck:"false"};this.inputElement&&(Eft([this.inputElement],[Zwt]),wft.remove(this.inputElement,"blur",this.inputBlurHandler),Vgt.removeAttributes(t,this.inputElement),xpt(this.cloneElement.getAttribute("tabindex"))?this.inputElement.removeAttribute("tabindex"):this.inputElement.setAttribute("tabindex",this.tabIndex),this.ensureInputAttribute(),this.inputElement.classList.remove("e-input"),xpt(this.inputWrapper)||(wft.remove(this.inputWrapper.buttons[0],"mousedown",this.rangeIconHandler),null===this.angularTag&&this.inputWrapper.container.parentElement.appendChild(this.inputElement),Cft(this.inputWrapper.container))),xpt(this.inputKeyboardModule)||this.isMobile||this.inputKeyboardModule.destroy(),this.popupObj&&(this.isMobile||this.clearCalendarEvents()),e.prototype.destroy.call(this),this.inputWrapper=this.popupWrapper=this.popupObj=this.cloneElement=this.presetElement=null,this.formElement&&wft.remove(this.formElement,"reset",this.formResetHandler),xpt(this.firstHiddenChild)||xpt(this.secondHiddenChild)||(Cft(this.firstHiddenChild),Cft(this.secondHiddenChild),this.firstHiddenChild=this.secondHiddenChild=null,this.inputElement.setAttribute("name",this.element.getAttribute("data-name")),this.inputElement.removeAttribute("data-name"))},t.prototype.ensureInputAttribute=function(){for(var e=[],t=0;t<this.inputElement.attributes.length;t++)e[t]=this.inputElement.attributes[t].name;for(t=0;t<e.length;t++)xpt(this.cloneElement.getAttribute(e[t]))?("value"===e[t].toLowerCase()&&(this.inputElement.value=""),this.inputElement.removeAttribute(e[t])):("value"===e[t].toLowerCase()&&(this.inputElement.value=this.cloneElement.getAttribute(e[t])),this.inputElement.setAttribute(e[t],this.cloneElement.getAttribute(e[t])))},t.prototype.getModuleName=function(){return"daterangepicker"},t.prototype.getPersistData=function(){return this.addOnPersist(["startDate","endDate","value"])},t.prototype.getSelectedRange=function(){var e;return xpt(this.startValue)||xpt(this.endValue)?e=0:(e=Math.round(Math.abs((this.removeTimeValueFromDate(this.startValue).getTime()-this.removeTimeValueFromDate(this.endValue).getTime())/864e5))+1,this.disabledDateRender(),xpt(this.disabledDayCnt)||(e-=this.disabledDayCnt,this.disabledDayCnt=null)),{startDate:this.startValue,endDate:this.endValue,daySpan:e}},t.prototype.show=function(t,n){var a=this;if(this.isMobile&&this.popupObj&&this.popupObj.refreshPosition(),!(this.enabled&&this.readonly||!this.enabled||this.popupObj||this.isPopupOpen())){t&&(this.targetElement=t),this.createPopup(),(this.isMobile||gft.isDevice)&&(this.mobileRangePopupWrap=this.createElement("div",{className:"e-daterangepick-mob-popup-wrap"}),document.body.appendChild(this.mobileRangePopupWrap)),this.openEventArgs={popup:this.popupObj||null,cancel:!1,date:this.inputElement.value,model:this,event:n||null,appendTo:this.isMobile||gft.isDevice?this.mobileRangePopupWrap:document.body};var r=this.openEventArgs;this.trigger("open",r,function(r){if(a.openEventArgs=r,!a.openEventArgs.cancel){a.openEventArgs.appendTo.appendChild(a.popupWrapper),a.showPopup(t,n);var i=!a.isCustomRange||a.isMobile&&a.isCustomRange;!Ept(a.presets[0].start&&a.presets[0].end&&a.presets[0].label)&&i&&a.setScrollPosition(),a.checkMinMaxDays(),a.isMobile&&!xpt(a.startDate)&&xpt(a.endDate)&&(a.endButton.element.classList.add(Iwt),a.startButton.element.classList.remove(Iwt),a.endButton.element.removeAttribute("disabled"),a.selectableDates()),e.prototype.setOverlayIndex.call(a,a.mobileRangePopupWrap,a.popupObj.element,a.modal,a.isMobile||gft.isDevice)}})}},t.prototype.hide=function(e){var t=this;if(this.popupObj){if(xpt(this.previousEndValue)&&xpt(this.previousStartValue)?this.clearRange():(xpt(this.previousStartValue)?(this.startValue=null,this.setValue()):(this.startValue=new Date(this.checkValue(this.previousStartValue)),this.setValue(),this.currentDate=new Date(this.checkValue(this.startValue))),xpt(this.previousEndValue)?(this.endValue=null,this.setValue()):(this.endValue=new Date(this.checkValue(this.previousEndValue)),this.setValue())),this.isPopupOpen()){this.closeEventArgs={cancel:!1,popup:this.popupObj,date:this.inputElement.value,model:this,event:e||null};var n=this.closeEventArgs;this.trigger("close",n,function(e){t.closeEventArgs=e,t.closeEventArgs.cancel?Eft([t.inputWrapper.buttons[0]],Iwt):(t.isMobile&&(xpt(t.startButton)||xpt(t.endButton)||(wft.remove(t.startButton.element,"click touchstart",t.deviceHeaderClick),wft.remove(t.endButton.element,"click touchstart",t.deviceHeaderClick))),t.popupObj&&(t.popupObj.hide(),t.preventBlur&&(t.inputElement.focus(),xft([t.inputWrapper.container],[Lwt]))),t.isMobile||(xpt(t.leftKeyboardModule)||xpt(t.rightKeyboardModule)||(t.leftKeyboardModule.destroy(),t.rightKeyboardModule.destroy()),xpt(t.presetElement)||t.presetKeyboardModule.destroy(),xpt(t.cancelButton)||t.btnKeyboardModule.destroy()),t.targetElement=null,Eft([document.body],lyt),wft.remove(document,"mousedown touchstart",t.documentHandler),t.isMobile&&t.modal&&(t.modal.style.display="none",t.modal.outerHTML="",t.modal=null),(t.isMobile||gft.isDevice)&&(xpt(t.mobileRangePopupWrap)||(t.mobileRangePopupWrap.remove(),t.mobileRangePopupWrap=null)),t.isKeyPopup=t.dateDisabled=!1),t.updateClearIconState(),t.updateHiddenInput(),t.isMobile&&t.allowEdit&&!t.readonly&&t.inputElement.removeAttribute("readonly")})}}else this.updateClearIconState(),this.updateHiddenInput(),this.isMobile&&this.allowEdit&&!this.readonly&&this.inputElement.removeAttribute("readonly")},t.prototype.setLocale=function(){this.globalize=new aft(this.locale),this.l10n.setLocale(this.locale),this.setProperties({placeholder:this.l10n.getConstant("placeholder")},!0),Vgt.setPlaceholder(this.placeholder,this.inputElement),this.updateInput(),this.updateHiddenInput(),this.changeTrigger()},t.prototype.refreshChange=function(){this.checkView(),this.refreshControl(),this.changeTrigger()},t.prototype.setDate=function(){Vgt.setValue("",this.inputElement,this.floatLabelType,this.showClearButton),this.refreshChange()},t.prototype.enableInput=function(){+this.min<=+this.max&&(this.setProperties({enabled:!0},!0),Vgt.setEnabled(this.enabled,this.inputElement),this.element.hasAttribute("disabled")&&this.bindEvents())},t.prototype.clearModelvalue=function(e,t){this.setProperties({startDate:null},!0),this.setProperties({endDate:null},!0),t.value&&t.value.length>0?this.setProperties({value:null},!0):(t.value&&t.value.start||t.value&&!t.value.start)&&this.setProperties({value:{start:null,end:null}},!0),this.updateValue(),this.setDate()},t.prototype.createHiddenInput=function(){xpt(this.firstHiddenChild)&&xpt(this.secondHiddenChild)&&(this.firstHiddenChild=this.createElement("input"),this.secondHiddenChild=this.createElement("input")),xpt(this.inputElement.getAttribute("name"))||(this.inputElement.setAttribute("data-name",this.inputElement.getAttribute("name")),this.inputElement.removeAttribute("name")),Hft(this.firstHiddenChild,{type:"text",name:this.inputElement.getAttribute("data-name"),class:hyt}),Hft(this.secondHiddenChild,{type:"text",name:this.inputElement.getAttribute("data-name"),class:hyt});var e={type:"datetime",skeleton:"yMd"};this.firstHiddenChild.value=this.startDate&&this.globalize.formatDate(this.startDate,e),this.secondHiddenChild.value=this.endDate&&this.globalize.formatDate(this.endDate,e),this.inputElement.parentElement.appendChild(this.firstHiddenChild),this.inputElement.parentElement.appendChild(this.secondHiddenChild)},t.prototype.setMinMaxDays=function(){this.isPopupOpen()&&(this.removeClassDisabled(),this.checkMinMaxDays(),this.isMobile&&this.selectableDates(),!this.strictMode&&xpt(this.startValue)&&xpt(this.endValue)?this.removeSelection():this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar]),this.updateHeader())},t.prototype.onPropertyChanged=function(e,t){for(var n={format:this.formatString,type:"date",skeleton:"yMd"},a=0,r=Object.keys(e);a<r.length;a++){var i=r[a];switch(["maxDays","minDays","value"].indexOf(i)<0&&this.hide(null),i){case"width":this.setEleWidth(this.width);break;case"separator":this.previousEleValue=this.inputElement.value,this.setProperties({separator:e.separator},!0),this.updateInput(),this.changeTrigger();break;case"placeholder":Vgt.setPlaceholder(e.placeholder,this.inputElement),this.setProperties({placeholder:e.placeholder},!0);break;case"readonly":Vgt.setReadonly(this.readonly,this.inputElement),this.inputElement.setAttribute("aria-readonly",""+this.readonly),this.setRangeAllowEdit();break;case"cssClass":this.updateCssClass(e.cssClass,t.cssClass);break;case"enabled":this.setProperties({enabled:e.enabled},!0),Vgt.setEnabled(this.enabled,this.inputElement),this.enabled?this.inputElement.setAttribute("tabindex",this.tabIndex):this.inputElement.tabIndex=-1;break;case"allowEdit":this.setRangeAllowEdit();break;case"enableRtl":this.setProperties({enableRtl:e.enableRtl},!0),Vgt.setEnableRtl(this.enableRtl,[this.inputWrapper.container]);break;case"zIndex":this.setProperties({zIndex:e.zIndex},!0);break;case"format":this.setProperties({format:e.format},!0),this.checkFormat(),this.updateInput(),this.changeTrigger();break;case"locale":this.globalize=new aft(this.locale),this.l10n.setLocale(this.locale),this.setProperties({placeholder:this.l10n.getConstant("placeholder")},!0),Vgt.setPlaceholder(this.placeholder,this.inputElement),this.setLocale();break;case"htmlAttributes":this.updateHtmlAttributeToElement(),this.updateHtmlAttributeToWrapper(),this.setDataAttribute(!0),this.checkHtmlAttributes(!0);break;case"showClearButton":Vgt.setClearButton(this.showClearButton,this.inputElement,this.inputWrapper),this.bindClearEvent();break;case"startDate":"string"==typeof e.startDate&&(e.startDate=this.globalize.parseDate(e.startDate,n)),+this.initStartDate!==+e.startDate&&(this.startValue=this.checkDateValue(new Date(this.checkValue(e.startDate))),this.setDate(),this.setValue());break;case"endDate":"string"==typeof e.endDate&&(e.endDate=this.globalize.parseDate(e.endDate,n)),+this.initEndDate!==+e.endDate&&(this.endValue=this.checkDateValue(new Date(this.checkValue(e.endDate))),this.setDate(),this.setValue());break;case"value":if(this.invalidValueString=null,this.checkInvalidRange(e.value),"string"==typeof e.value)if(this.invalidValueString)this.clearModelvalue(e,t);else{var o=e.value.split(" "+this.separator+" ");this.value=[new Date(o[0]),new Date(o[1])],this.updateValue(),this.setDate()}else!xpt(e.value)&&e.value.length>0||!xpt(e.value)&&e.value.start?(this.valueType=e.value,null===e.value[0]||null===e.value.start?1===e.value.length||e.value.start?this.clearModelvalue(e,t):null!==e.value[1]&&null!==e.value.start||this.clearModelvalue(e,t):+this.initStartDate===+e.value[0]&&+this.initEndDate===+e.value[1]&&+this.initStartDate===+(e.value.start||+this.initEndDate!==+e.value.start)||((1===e.value.length||e.value.start)&&(this.modelValue=e.value),this.updateValue(),this.setDate())):(xpt(this.value)||null==e.value.start)&&(this.valueType=e.value,this.startValue=null,this.endValue=null,this.clearModelvalue(e,t));if(this.isPopupOpen()){if(xpt(this.startValue)&&xpt(this.endValue))return this.removeSelection(),void(this.isMobile&&this.deviceHeaderUpdate());this.isMobile?(this.navigate(this.deviceCalendar,this.startValue,this.currentView()),this.deviceHeaderUpdate()):(this.navigate(this.leftCalendar,this.startValue,this.currentView()),this.updateControl(this.leftCalendar),this.navigate(this.rightCalendar,this.endValue,this.currentView()),this.updateControl(this.rightCalendar)),this.updateRange(this.isMobile?[this.calendarElement]:[this.leftCalendar,this.rightCalendar]),this.updateHeader(),this.applyButton.disabled=this.applyButton.element.disabled=!1}this.preventChange=this.isAngular&&this.preventChange?!this.preventChange:this.preventChange;break;case"minDays":this.setProperties({minDays:e.minDays},!0),this.refreshChange(),this.setMinMaxDays();break;case"maxDays":this.setProperties({maxDays:e.maxDays},!0),this.refreshChange(),this.setMinMaxDays();break;case"min":this.setProperties({min:this.checkDateValue(new Date(this.checkValue(e.min)))},!0),this.previousEleValue=this.inputElement.value,this.enableInput(),this.refreshChange();break;case"max":this.setProperties({max:this.checkDateValue(new Date(this.checkValue(e.max)))},!0),this.enableInput(),this.refreshChange();break;case"strictMode":this.invalidValueString=null,this.setProperties({strictMode:e.strictMode},!0),this.refreshChange();break;case"presets":this.setProperties({presets:e.presets},!0),this.processPresets();break;case"floatLabelType":this.floatLabelType=e.floatLabelType,Vgt.removeFloating(this.inputWrapper),Vgt.addFloating(this.inputElement,this.floatLabelType,this.placeholder);break;case"start":this.setProperties({start:e.start},!0),this.refreshChange();break;case"depth":this.setProperties({depth:e.depth},!0),this.refreshChange()}}},Mwt([Kft(null)],t.prototype,"value",void 0),Mwt([Kft(!1)],t.prototype,"enablePersistence",void 0),Mwt([Kft(new Date(1900,0,1))],t.prototype,"min",void 0),Mwt([Kft(new Date(2099,11,31))],t.prototype,"max",void 0),Mwt([Kft(null)],t.prototype,"locale",void 0),Mwt([Kft(null)],t.prototype,"firstDayOfWeek",void 0),Mwt([Kft(!1)],t.prototype,"weekNumber",void 0),Mwt([Kft("Gregorian")],t.prototype,"calendarMode",void 0),Mwt([Kft(!1)],t.prototype,"openOnFocus",void 0),Mwt([Jft()],t.prototype,"created",void 0),Mwt([Jft()],t.prototype,"destroyed",void 0),Mwt([Jft()],t.prototype,"change",void 0),Mwt([Jft()],t.prototype,"cleared",void 0),Mwt([Jft()],t.prototype,"navigated",void 0),Mwt([Jft()],t.prototype,"renderDayCell",void 0),Mwt([Kft(null)],t.prototype,"startDate",void 0),Mwt([Kft(null)],t.prototype,"endDate",void 0),Mwt([Xft([{}],pyt)],t.prototype,"presets",void 0),Mwt([Kft("")],t.prototype,"width",void 0),Mwt([Kft(1e3)],t.prototype,"zIndex",void 0),Mwt([Kft(!0)],t.prototype,"showClearButton",void 0),Mwt([Kft(!0)],t.prototype,"showTodayButton",void 0),Mwt([Kft("Month")],t.prototype,"start",void 0),Mwt([Kft("Month")],t.prototype,"depth",void 0),Mwt([Kft("")],t.prototype,"cssClass",void 0),Mwt([Kft("-")],t.prototype,"separator",void 0),Mwt([Kft(null)],t.prototype,"minDays",void 0),Mwt([Kft(null)],t.prototype,"maxDays",void 0),Mwt([Kft(!1)],t.prototype,"strictMode",void 0),Mwt([Kft(null)],t.prototype,"keyConfigs",void 0),Mwt([Kft(null)],t.prototype,"format",void 0),Mwt([Kft(!0)],t.prototype,"enabled",void 0),Mwt([Kft(!1)],t.prototype,"readonly",void 0),Mwt([Kft(!0)],t.prototype,"allowEdit",void 0),Mwt([Kft("Never")],t.prototype,"floatLabelType",void 0),Mwt([Kft(null)],t.prototype,"placeholder",void 0),Mwt([Kft({})],t.prototype,"htmlAttributes",void 0),Mwt([Jft()],t.prototype,"open",void 0),Mwt([Jft()],t.prototype,"close",void 0),Mwt([Jft()],t.prototype,"select",void 0),Mwt([Jft()],t.prototype,"focus",void 0),Mwt([Jft()],t.prototype,"blur",void 0),t=Mwt([$ft],t)}(qvt),myt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),vyt=["alt","className","disabled","form","id","readOnly","style","tabIndex","title","type","name","onClick","onFocus","onBlur"],gyt=["accordion","tab","splitter"],wyt=new RegExp("]"),yyt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.mountingState=!1,t.attrKeys=[],t.cachedTimeOut=0,t.isAppendCalled=!1,t.initRenderCalled=!1,t.isReactForeceUpdate=!1,t.isReact=!0,t.isshouldComponentUpdateCalled=!1,t.isCreated=!1,t}return myt(t,e),t.prototype.componentDidMount=function(){this.refreshChild(!0),this.canDelayUpdate=-1!==gyt.indexOf(this.getModuleName()),this.renderReactComponent(),this.portals&&this.portals.length&&(this.mountingState=!0,this.renderReactTemplates(),this.mountingState=!1)},t.prototype.componentDidUpdate=function(e){this.isshouldComponentUpdateCalled||!this.initRenderCalled||this.isReactForeceUpdate||(this.isshouldComponentUpdateCalled=!0,e!==this.props&&this.refreshProperties(this.props,!0))},t.prototype.renderReactComponent=function(){var e=this.reactElement;e&&!this.isAppendCalled&&(this.isAppendCalled=!0,this.appendTo(e))},t.prototype.shouldComponentUpdate=function(e){return this.isshouldComponentUpdateCalled=!0,this.initRenderCalled?(this.isAppendCalled||(clearTimeout(this.cachedTimeOut),this.isAppendCalled=!0,this.appendTo(this.reactElement)),this.updateProperties(e),!0):(this.updateProperties(e,!0),!0)},t.prototype.updateProperties=function(e,t){for(var n=this,a=bpt({},e),r=0,i=Object.keys(e);r<i.length;r++){var o=i[r],l="className"===o;if("children"!==o)if(l||xpt(this.htmlattributes[o])||this.htmlattributes[o]===a[o]||(this.htmlattributes[o]=a[o]),this.compareValues(this.props[o],e[o]))delete a[o];else if(-1!==this.attrKeys.indexOf(o))if(l){this.clsName=!0;for(var s=this.props[o].split(" "),c=0;c<s.length;c++)this.element.classList.remove(s[c]);for(var d=a[o].split(" "),h=0;h<d.length;h++)this.element.classList.add(d[h])}else"disabled"!==o&&delete a[o];else"value"===o&&e[o]===this[o]?delete a[o]:"valueTemplate"!==o&&"itemTemplate"!==o&&"headerTemplate"!==o||e[o].toString()!==this[o].toString()?"content"===o&&"function"==typeof a[o]&&delete a[o]:delete a[o]}a.children&&delete a.children,this.initRenderCalled&&(this.canDelayUpdate||this.props.delayUpdate)?setTimeout(function(){n.refreshProperties(a,e,t)}):this.refreshProperties(a,e,t)},t.prototype.refreshProperties=function(e,t,n){Object.keys(e).length&&(n||this.processComplexTemplate(e,this),this.setProperties(e,n)),this.refreshChild(n,t)},t.prototype.processComplexTemplate=function(e,t){var n=t.complexTemplate;if(n)for(var a in n){var r=n[a];e[a]&&mpt(r,fpt(a,e),e)}},t.prototype.getDefaultAttributes=function(){var e=this;this.isReact=!0;var n=Object.keys(this.props);this.htmlattributes||(this.htmlattributes={}),this.attrKeys=vyt.concat(this.controlAttributes||[]);for(var a=0,r=n;a<r.length;a++){var i=r[a];-1===i.indexOf("data-")&&-1===i.indexOf("aria-")&&-1===this.attrKeys.indexOf(i)||this.htmlattributes[i]!==this.props[i]&&(this.htmlattributes[i]=this.props[i])}if(!this.htmlattributes.ref){this.htmlattributes.ref=function(t){e.reactElement=t};-1!==["autocomplete","combobox","dropdownlist","dropdowntree","multiselect","listbox","colorpicker","numerictextbox","textbox","uploader","maskedtextbox","slider","datepicker","datetimepicker","daterangepicker","timepicker","checkbox","switch","radio"].indexOf(this.getModuleName())&&(this.htmlattributes.key=""+t.reactUid,t.reactUid++)}if(this.clsName){for(var o=this.element.classList,l=this.htmlattributes.className,s=0;s<o.length;s++)-1==l.indexOf(o[s])&&(this.htmlattributes.className=this.htmlattributes.className+" "+o[s]);this.clsName=!1}return this.htmlattributes},t.prototype.trigger=function(e,t,n){var a=this;if(!0!==this.isDestroyed&&this.modelObserver){if(wyt.test(e)){var r=fpt(e,this);r?(r.call(this,t),n&&n.call(this,t)):n&&n.call(this,t)}"change"!==e&&"input"!==e||this.props.onChange&&t.event&&this.props.onChange.call(void 0,{syntheticEvent:t.event,nativeEvent:{text:t.value},value:t.value,target:this});var i=this.isProtectedOnChange;this.isProtectedOnChange=!1,"created"===e?setTimeout(function(){a.isCreated=!0,a.isDestroyed||a.modelObserver.notify(e,t,n)},10):this.modelObserver.notify(e,t,n),this.isProtectedOnChange=i}},t.prototype.compareValues=function(e,t){if(typeof e===typeof t){if(e===t)return!0;if((!xpt(e)&&e.constructor)!==(!xpt(t)&&t.constructor))return!1;if(e instanceof Date||e instanceof RegExp||e instanceof String||e instanceof Number)return e.toString()===t.toString();if(wpt(e)||Array.isArray(e)){var n=e,a=t;return wpt(n)&&(n=[e],a=[t]),this.compareObjects(n,a).status}}return!1},t.prototype.compareObjects=function(e,t,n){var a=!0,r=[];if(e.length===t.length)for(var i=0,o=t.length;i<o;i++){var l={},s=e[i],c=t[i],d=Object.keys(c);if(0!==d.length)for(var h=0,u=d;h<u.length;h++){var p=u[h],f=s[p],m=c[p];if("items"===p)for(var v=0;v<m.length;v++)if("richtexteditor"===this.getModuleName()&&"object"==typeof m[v])return{status:!0};if("grid"===this.getModuleName()&&"field"===p&&(l[p]=m),!s.hasOwnProperty(p)||!this.compareValues(f,m)){if(!n)return{status:!1};a=!1,l[p]=m}}else if(c[i]===s[i])a=!0;else{if(!n)return{status:!1};a=!1}Object.keys(l).length&&r.push({index:i,value:l,key:n})}else a=!1;return{status:a,changedProperties:r}},t.prototype.refreshChild=function(e,t){if(this.checkInjectedModules){for(var n=this.getInjectedModules()||[],a=0,r=this.getInjectedServices()||[];a<r.length;a++){var i=r[a];-1===n.indexOf(i)&&n.push(i)}this.injectedModules=n}if(this.directivekeys){var o=[],l=this.validateChildren({},this.directivekeys,t||this.props);if(l&&Object.keys(l).length){if(!e&&this.skipRefresh)for(var s=0,c=this.skipRefresh;s<c.length;s++){delete l[c[s]]}if(this.prevProperties)for(var d=Object.keys(this.prevProperties),h=0;h<d.length;h++){var u=d[h];if(l.hasOwnProperty(u)){var p=this.compareObjects(this.prevProperties[u],l[u],u);if(p.status)delete l[u];else{p.changedProperties.length&&(o=o.concat(p.changedProperties));var f={};f[u]=l[u],this.prevProperties=bpt(this.prevProperties,f)}}}else this.prevProperties=bpt({},l,{},!0);if(o.length)if("grid"===this.getModuleName()&&"columns"===u)for(var m=0,v=this.columns;m<v.length;m++){if(fpt("field",v[m])===fpt(m+".value.field",o)){var g=fpt(o[m].key+"."+o[m].index,this);g&&g.setProperties?g.setProperties(o[m].value):bpt(g,o[m].value)}else this.setProperties(l,e)}else for(var w=0,y=o;w<y.length;w++){var b=y[w],x=fpt(b.key+"."+b.index,this);x&&x.setProperties?x.setProperties(b.value):bpt(x,b.value)}else this.setProperties(l,e)}}},t.prototype.componentWillUnmount=function(){clearTimeout(this.cachedTimeOut);this.initRenderCalled&&this.isAppendCalled&&this.element&&(["dropdowntree","checkbox"].indexOf(this.getModuleName())||document.body.contains(this.element))&&!this.isDestroyed&&this.isCreated&&this.destroy()},t.prototype.appendReactElement=function(e,t){var n=g.createPortal(e,t);this.portals?this.portals.push(n):this.portals=[n]},t.prototype.renderReactTemplates=function(e){this.isReactForeceUpdate=!0,e?this.forceUpdate(e):this.forceUpdate(),this.isReactForeceUpdate=!1},t.prototype.clearTemplate=function(e,t,n){var a=this,r=[];e&&e.length?Array.prototype.forEach.call(e,function(e){var n=0,i=0;if(a.portals.forEach(function(t){t.propName===e&&(r.push(i),i++)}),t&&a.portals[r[t[n]]].propName==e)a.portals.splice(t,1),n++;else for(var o=0;o<a.portals.length;o++)a.portals[o].propName==e&&(a.portals.splice(o,1),o--)}):this.portals=[],this.renderReactTemplates(n)},t.prototype.validateChildren=function(e,t,n){for(var a=!1,r=0,i=m.Children.toArray(n.children);r<i.length;r++){var o=i[r],l=this.getChildType(o),s=t[l];if(l&&t){var c=this.getChildProps(m.Children.toArray(o.props.children),s);c.length&&(a=!0,e[o.type.propertyName||l]=c)}}return a?e:null},t.prototype.getChildType=function(e){return e.type&&e.type.isDirective&&e.type.moduleName||""},t.prototype.getChildProps=function(e,t){for(var n=[],a=0,r=e;a<r.length;a++){var i=r[a],o=!1,l=void 0;"string"==typeof t?(o=!0,l=t):l=Object.keys(t)[0];var s=i.props;if(this.getChildType(i)===l)if(o||!s.children){var c=bpt({},s,{},!0);this.processComplexTemplate(c,i.type),n.push(c)}else{var d=this.validateChildren(bpt({},s),t[l],s)||s;d.children&&delete d.children,this.processComplexTemplate(d,i.type),n.push(d)}}return n},t.prototype.getInjectedServices=function(){for(var e=0,t=m.Children.toArray(this.props.children);e<t.length;e++){var n=t[e];if(n.type.isService)return n.props.services}return[]},t.reactUid=1,t}(m.Component);var byt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}();!function(e){function t(){return null!==e&&e.apply(this,arguments)||this}byt(t,e),t.prototype.render=function(){return null},t.isDirective=!0}(m.PureComponent);var xyt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}();!function(e){function t(){return null!==e&&e.apply(this,arguments)||this}xyt(t,e),t.prototype.render=function(){return null},t.isService=!0}(m.PureComponent);var Eyt,kyt=wvt.compile;Eyt={compile:function(e,t){return"string"==typeof e?kyt(e,t):function(t,n,a,r){var i,o=e,l=t;"object"==typeof o&&(o=e.template,l=bpt({},t,e.data||{})),i=r||document.createElement("div");var s=m.createElement(o,l),c=g.createPortal(s,i);if(c.propName=a,n.portals?n.portals.push(c):n.portals=[c],!r)return[i]}}},wvt.compile=Eyt.compile;var Myt,Syt=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},e(t,n)};return function(t,n){function a(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(a.prototype=n.prototype,new a)}}(),Ayt=function(e){function t(t){var n=e.call(this,t)||this;return n.initRenderCalled=!1,n.checkInjectedModules=!1,n.directivekeys={presets:"preset"},n.immediateRender=!1,n.portals=[],n}return Syt(t,e),t.prototype.render=function(){if(!(this.element&&!this.initRenderCalled||this.refreshing)||this.isReactForeceUpdate)return m.createElement(m.Fragment,null,[].concat(m.createElement("input",this.getDefaultAttributes()),this.portals));e.prototype.render.call(this),this.initRenderCalled=!0},t}(fyt);function _yt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Cyt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_yt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_yt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}Myt=Ayt,[yyt,m.Component].forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(t){"isMounted"!==t&&"replaceState"!==t&&(Myt.prototype[t]=e.prototype[t])})});var Zyt={type:"logger",log:function(e){this.output("log",e)},warn:function(e){this.output("warn",e)},error:function(e){this.output("error",e)},output:function(e,t){console&&console[e]&&console[e].apply(console,t)}},Hyt=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};gs(this,e),this.init(t,n)}return ys(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||Zyt,this.options=t,this.debug=t.debug}},{key:"setDebug",value:function(e){this.debug=e}},{key:"log",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}},{key:"warn",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}},{key:"error",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}},{key:"deprecate",value:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(e,t,n,a){return a&&!this.debug?null:("string"==typeof e[0]&&(e[0]="".concat(n).concat(this.prefix," ").concat(e[0])),this.logger[t](e))}},{key:"create",value:function(t){return new e(this.logger,Cyt(Cyt({},{prefix:"".concat(this.prefix,":").concat(t,":")}),this.options))}},{key:"clone",value:function(t){return(t=t||this.options).prefix=t.prefix||this.prefix,new e(this.logger,t)}}]),e}(),Iyt=new Hyt,Dyt=function(){function e(){gs(this,e),this.observers={}}return ys(e,[{key:"on",value:function(e,t){var n=this;return e.split(" ").forEach(function(e){n.observers[e]=n.observers[e]||[],n.observers[e].push(t)}),this}},{key:"off",value:function(e,t){this.observers[e]&&(t?this.observers[e]=this.observers[e].filter(function(e){return e!==t}):delete this.observers[e])}},{key:"emit",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),a=1;a<t;a++)n[a-1]=arguments[a];this.observers[e]&&[].concat(this.observers[e]).forEach(function(e){e.apply(void 0,n)});this.observers["*"]&&[].concat(this.observers["*"]).forEach(function(t){t.apply(t,[e].concat(n))})}}]),e}();function Nyt(){var e,t,n=new Promise(function(n,a){e=n,t=a});return n.resolve=e,n.reject=t,n}function Oyt(e){return null==e?"":""+e}function Lyt(e,t,n){function a(e){return e&&e.indexOf("###")>-1?e.replace(/###/g,"."):e}function r(){return!e||"string"==typeof e}for(var i="string"!=typeof t?[].concat(t):t.split(".");i.length>1;){if(r())return{};var o=a(i.shift());!e[o]&&n&&(e[o]=new n),e=Object.prototype.hasOwnProperty.call(e,o)?e[o]:{}}return r()?{}:{obj:e,k:a(i.shift())}}function Vyt(e,t,n){var a=Lyt(e,t,Object);a.obj[a.k]=n}function zyt(e,t){var n=Lyt(e,t),a=n.obj,r=n.k;if(a)return a[r]}function Pyt(e,t,n){var a=zyt(e,n);return void 0!==a?a:zyt(t,n)}function Tyt(e,t,n){for(var a in t)"__proto__"!==a&&"constructor"!==a&&(a in e?"string"==typeof e[a]||e[a]instanceof String||"string"==typeof t[a]||t[a]instanceof String?n&&(e[a]=t[a]):Tyt(e[a],t[a],n):e[a]=t[a]);return e}function Byt(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var jyt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};function Wyt(e){return"string"==typeof e?e.replace(/[&<>"'\/]/g,function(e){return jyt[e]}):e}var Ryt="undefined"!=typeof window&&window.navigator&&void 0===window.navigator.userAgentData&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,Fyt=[" ",",","?","!",";"];function Yyt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function qyt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yyt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yyt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function Uyt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}function Gyt(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(e){if(e[t])return e[t];for(var a=t.split(n),r=e,i=0;i<a.length;++i){if(!r)return;if("string"==typeof r[a[i]]&&i+1<a.length)return;if(void 0===r[a[i]]){for(var o=2,l=a.slice(i,i+o).join(n),s=r[l];void 0===s&&a.length>i+o;)o++,s=r[l=a.slice(i,i+o).join(n)];if(void 0===s)return;if(null===s)return null;if(t.endsWith(l)){if("string"==typeof s)return s;if(l&&"string"==typeof s[l])return s[l]}var c=a.slice(i+o).join(n);return c?Gyt(s,c,n):void 0}r=r[a[i]]}return r}}var Kyt=function(){CQe(t,Dyt);var e=Uyt(t);function t(n){var a,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};return gs(this,t),a=e.call(this),Ryt&&Dyt.call(qn(a)),a.data=n||{},a.options=r,void 0===a.options.keySeparator&&(a.options.keySeparator="."),void 0===a.options.ignoreJSONStructure&&(a.options.ignoreJSONStructure=!0),a}return ys(t,[{key:"addNamespaces",value:function(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}},{key:"removeNamespaces",value:function(e){var t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}},{key:"getResource",value:function(e,t,n){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},r=void 0!==a.keySeparator?a.keySeparator:this.options.keySeparator,i=void 0!==a.ignoreJSONStructure?a.ignoreJSONStructure:this.options.ignoreJSONStructure,o=[e,t];n&&"string"!=typeof n&&(o=o.concat(n)),n&&"string"==typeof n&&(o=o.concat(r?n.split(r):n)),e.indexOf(".")>-1&&(o=e.split("."));var l=zyt(this.data,o);return l||!i||"string"!=typeof n?l:Gyt(this.data&&this.data[e]&&this.data[e][t],n,r)}},{key:"addResource",value:function(e,t,n,a){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1},i=this.options.keySeparator;void 0===i&&(i=".");var o=[e,t];n&&(o=o.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=t,t=(o=e.split("."))[1]),this.addNamespaces(t),Vyt(this.data,o,a),r.silent||this.emit("added",e,t,n,a)}},{key:"addResources",value:function(e,t,n){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(var r in n)"string"!=typeof n[r]&&"[object Array]"!==Object.prototype.toString.apply(n[r])||this.addResource(e,t,r,n[r],{silent:!0});a.silent||this.emit("added",e,t,n)}},{key:"addResourceBundle",value:function(e,t,n,a,r){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1},o=[e,t];e.indexOf(".")>-1&&(a=n,n=t,t=(o=e.split("."))[1]),this.addNamespaces(t);var l=zyt(this.data,o)||{};a?Tyt(l,n,r):l=qyt(qyt({},l),n),Vyt(this.data,o,l),i.silent||this.emit("added",e,t,n)}},{key:"removeResourceBundle",value:function(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}},{key:"hasResourceBundle",value:function(e,t){return void 0!==this.getResource(e,t)}},{key:"getResourceBundle",value:function(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?qyt(qyt({},{}),this.getResource(e,t)):this.getResource(e,t)}},{key:"getDataByLanguage",value:function(e){return this.data[e]}},{key:"hasLanguageSomeTranslations",value:function(e){var t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(function(e){return t[e]&&Object.keys(t[e]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),t}(),Qyt={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,n,a,r){var i=this;return e.forEach(function(e){i.processors[e]&&(t=i.processors[e].process(t,n,a,r))}),t}};function Xyt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Jyt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xyt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xyt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function $yt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}var ebt={},tbt=function(){CQe(t,Dyt);var e=$yt(t);function t(n){var a,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return gs(this,t),a=e.call(this),Ryt&&Dyt.call(qn(a)),function(e,t,n){e.forEach(function(e){t[e]&&(n[e]=t[e])})}(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],n,qn(a)),a.options=r,void 0===a.options.keySeparator&&(a.options.keySeparator="."),a.logger=Iyt.create("translator"),a}return ys(t,[{key:"changeLanguage",value:function(e){e&&(this.language=e)}},{key:"exists",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};if(null==e)return!1;var n=this.resolve(e,t);return n&&void 0!==n.res}},{key:"extractFromKey",value:function(e,t){var n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");var a=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,r=t.ns||this.options.defaultNS||[],i=n&&e.indexOf(n)>-1,o=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||function(e,t,n){t=t||"",n=n||"";var a=Fyt.filter(function(e){return t.indexOf(e)<0&&n.indexOf(e)<0});if(0===a.length)return!0;var r=new RegExp("(".concat(a.map(function(e){return"?"===e?"\\?":e}).join("|"),")")),i=!r.test(e);if(!i){var o=e.indexOf(n);o>0&&!r.test(e.substring(0,o))&&(i=!0)}return i}(e,n,a));if(i&&!o){var l=e.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return{key:e,namespaces:r};var s=e.split(n);(n!==a||n===a&&this.options.ns.indexOf(s[0])>-1)&&(r=s.shift()),e=s.join(a)}return"string"==typeof r&&(r=[r]),{key:e,namespaces:r}}},{key:"translate",value:function(e,n,a){var r=this;if("object"!==fs(n)&&this.options.overloadTranslationOptionHandler&&(n=this.options.overloadTranslationOptionHandler(arguments)),n||(n={}),null==e)return"";Array.isArray(e)||(e=[String(e)]);var i=void 0!==n.returnDetails?n.returnDetails:this.options.returnDetails,o=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,l=this.extractFromKey(e[e.length-1],n),s=l.key,c=l.namespaces,d=c[c.length-1],h=n.lng||this.language,u=n.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(h&&"cimode"===h.toLowerCase()){if(u){var p=n.nsSeparator||this.options.nsSeparator;return i?(f.res="".concat(d).concat(p).concat(s),f):"".concat(d).concat(p).concat(s)}return i?(f.res=s,f):s}var f=this.resolve(e,n),m=f&&f.res,v=f&&f.usedKey||s,g=f&&f.exactUsedKey||s,w=Object.prototype.toString.apply(m),y=void 0!==n.joinArrays?n.joinArrays:this.options.joinArrays,b=!this.i18nFormat||this.i18nFormat.handleAsObject;if(b&&m&&("string"!=typeof m&&"boolean"!=typeof m&&"number"!=typeof m)&&["[object Number]","[object Function]","[object RegExp]"].indexOf(w)<0&&("string"!=typeof y||"[object Array]"!==w)){if(!n.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var x=this.options.returnedObjectHandler?this.options.returnedObjectHandler(v,m,Jyt(Jyt({},n),{},{ns:c})):"key '".concat(s," (").concat(this.language,")' returned an object instead of string.");return i?(f.res=x,f):x}if(o){var E="[object Array]"===w,k=E?[]:{},M=E?g:v;for(var S in m)if(Object.prototype.hasOwnProperty.call(m,S)){var A="".concat(M).concat(o).concat(S);k[S]=this.translate(A,Jyt(Jyt({},n),{joinArrays:!1,ns:c})),k[S]===A&&(k[S]=m[S])}m=k}}else if(b&&"string"==typeof y&&"[object Array]"===w)(m=m.join(y))&&(m=this.extendTranslation(m,e,n,a));else{var _=!1,C=!1,Z=void 0!==n.count&&"string"!=typeof n.count,H=t.hasDefaultValue(n),I=Z?this.pluralResolver.getSuffix(h,n.count,n):"",D=n["defaultValue".concat(I)]||n.defaultValue;!this.isValidLookup(m)&&H&&(_=!0,m=D),this.isValidLookup(m)||(C=!0,m=s);var N=(n.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&C?void 0:m,O=H&&D!==m&&this.options.updateMissing;if(C||_||O){if(this.logger.log(O?"updateKey":"missingKey",h,d,s,O?D:m),o){var L=this.resolve(s,Jyt(Jyt({},n),{},{keySeparator:!1}));L&&L.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var V=[],z=this.languageUtils.getFallbackCodes(this.options.fallbackLng,n.lng||this.language);if("fallback"===this.options.saveMissingTo&&z&&z[0])for(var P=0;P<z.length;P++)V.push(z[P]);else"all"===this.options.saveMissingTo?V=this.languageUtils.toResolveHierarchy(n.lng||this.language):V.push(n.lng||this.language);var T=function(e,t,a){var i=H&&a!==m?a:N;r.options.missingKeyHandler?r.options.missingKeyHandler(e,d,t,i,O,n):r.backendConnector&&r.backendConnector.saveMissing&&r.backendConnector.saveMissing(e,d,t,i,O,n),r.emit("missingKey",e,d,t,m)};this.options.saveMissing&&(this.options.saveMissingPlurals&&Z?V.forEach(function(e){r.pluralResolver.getSuffixes(e,n).forEach(function(t){T([e],s+t,n["defaultValue".concat(t)]||D)})}):T(V,s,D))}m=this.extendTranslation(m,e,n,f,a),C&&m===s&&this.options.appendNamespaceToMissingKey&&(m="".concat(d,":").concat(s)),(C||_)&&this.options.parseMissingKeyHandler&&(m="v1"!==this.options.compatibilityAPI?this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(d,":").concat(s):s,_?m:void 0):this.options.parseMissingKeyHandler(m))}return i?(f.res=m,f):m}},{key:"extendTranslation",value:function(e,t,n,a,r){var i=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,Jyt(Jyt({},this.options.interpolation.defaultVariables),n),a.usedLng,a.usedNS,a.usedKey,{resolved:a});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init(Jyt(Jyt({},n),{interpolation:Jyt(Jyt({},this.options.interpolation),n.interpolation)}));var o,l="string"==typeof e&&(n&&n.interpolation&&void 0!==n.interpolation.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);if(l){var s=e.match(this.interpolator.nestingRegexp);o=s&&s.length}var c=n.replace&&"string"!=typeof n.replace?n.replace:n;if(this.options.interpolation.defaultVariables&&(c=Jyt(Jyt({},this.options.interpolation.defaultVariables),c)),e=this.interpolator.interpolate(e,c,n.lng||this.language,n),l){var d=e.match(this.interpolator.nestingRegexp);o<(d&&d.length)&&(n.nest=!1)}!1!==n.nest&&(e=this.interpolator.nest(e,function(){for(var e=arguments.length,a=new Array(e),o=0;o<e;o++)a[o]=arguments[o];return r&&r[0]===a[0]&&!n.context?(i.logger.warn("It seems you are nesting recursively key: ".concat(a[0]," in key: ").concat(t[0])),null):i.translate.apply(i,a.concat([t]))},n)),n.interpolation&&this.interpolator.reset()}var h=n.postProcess||this.options.postProcess,u="string"==typeof h?[h]:h;return null!=e&&u&&u.length&&!1!==n.applyPostProcessor&&(e=Qyt.handle(u,e,t,this.options&&this.options.postProcessPassResolved?Jyt({i18nResolved:a},n):n,this)),e}},{key:"resolve",value:function(e){var t,n,a,r,i,o=this,l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e&&(e=[e]),e.forEach(function(e){if(!o.isValidLookup(t)){var s=o.extractFromKey(e,l),c=s.key;n=c;var d=s.namespaces;o.options.fallbackNS&&(d=d.concat(o.options.fallbackNS));var h=void 0!==l.count&&"string"!=typeof l.count,u=h&&!l.ordinal&&0===l.count&&o.pluralResolver.shouldUseIntlApi(),p=void 0!==l.context&&("string"==typeof l.context||"number"==typeof l.context)&&""!==l.context,f=l.lngs?l.lngs:o.languageUtils.toResolveHierarchy(l.lng||o.language,l.fallbackLng);d.forEach(function(e){o.isValidLookup(t)||(i=e,!ebt["".concat(f[0],"-").concat(e)]&&o.utils&&o.utils.hasLoadedNamespace&&!o.utils.hasLoadedNamespace(i)&&(ebt["".concat(f[0],"-").concat(e)]=!0,o.logger.warn('key "'.concat(n,'" for languages "').concat(f.join(", "),'" won\'t get resolved as namespace "').concat(i,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach(function(n){if(!o.isValidLookup(t)){r=n;var i,s=[c];if(o.i18nFormat&&o.i18nFormat.addLookupKeys)o.i18nFormat.addLookupKeys(s,c,n,e,l);else{var d;h&&(d=o.pluralResolver.getSuffix(n,l.count,l));var f="".concat(o.options.pluralSeparator,"zero");if(h&&(s.push(c+d),u&&s.push(c+f)),p){var m="".concat(c).concat(o.options.contextSeparator).concat(l.context);s.push(m),h&&(s.push(m+d),u&&s.push(m+f))}}for(;i=s.pop();)o.isValidLookup(t)||(a=i,t=o.getResource(n,e,i,l))}}))})}}),{res:t,usedKey:n,exactUsedKey:a,usedLng:r,usedNS:i}}},{key:"isValidLookup",value:function(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}},{key:"getResource",value:function(e,t,n){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,n,a):this.resourceStore.getResource(e,t,n,a)}}],[{key:"hasDefaultValue",value:function(e){var t="defaultValue";for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}]),t}();function nbt(e){return e.charAt(0).toUpperCase()+e.slice(1)}var abt=function(){function e(t){gs(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Iyt.create("languageUtils")}return ys(e,[{key:"getScriptPartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return null;var t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}},{key:"getLanguagePartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return e;var t=e.split("-");return this.formatLanguageCode(t[0])}},{key:"formatLanguageCode",value:function(e){if("string"==typeof e&&e.indexOf("-")>-1){var t=["hans","hant","latn","cyrl","cans","mong","arab"],n=e.split("-");return this.options.lowerCaseLng?n=n.map(function(e){return e.toLowerCase()}):2===n.length?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=nbt(n[1].toLowerCase()))):3===n.length&&(n[0]=n[0].toLowerCase(),2===n[1].length&&(n[1]=n[1].toUpperCase()),"sgn"!==n[0]&&2===n[2].length&&(n[2]=n[2].toUpperCase()),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=nbt(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=nbt(n[2].toLowerCase()))),n.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}},{key:"isSupportedCode",value:function(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}},{key:"getBestMatchFromCodes",value:function(e){var t,n=this;return e?(e.forEach(function(e){if(!t){var a=n.formatLanguageCode(e);n.options.supportedLngs&&!n.isSupportedCode(a)||(t=a)}}),!t&&this.options.supportedLngs&&e.forEach(function(e){if(!t){var a=n.getLanguagePartFromCode(e);if(n.isSupportedCode(a))return t=a;t=n.options.supportedLngs.find(function(e){if(0===e.indexOf(a))return e})}}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t):null}},{key:"getFallbackCodes",value:function(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),"string"==typeof e&&(e=[e]),"[object Array]"===Object.prototype.toString.apply(e))return e;if(!t)return e.default||[];var n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}},{key:"toResolveHierarchy",value:function(e,t){var n=this,a=this.getFallbackCodes(t||this.options.fallbackLng||[],e),r=[],i=function(e){e&&(n.isSupportedCode(e)?r.push(e):n.logger.warn("rejecting language code not found in supportedLngs: ".concat(e)))};return"string"==typeof e&&e.indexOf("-")>-1?("languageOnly"!==this.options.load&&i(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&i(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&i(this.getLanguagePartFromCode(e))):"string"==typeof e&&i(this.formatLanguageCode(e)),a.forEach(function(e){r.indexOf(e)<0&&i(n.formatLanguageCode(e))}),r}}]),e}(),rbt=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],ibt={1:function(e){return Number(e>1)},2:function(e){return Number(1!=e)},3:function(e){return 0},4:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},5:function(e){return Number(0==e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5)},6:function(e){return Number(1==e?0:e>=2&&e<=4?1:2)},7:function(e){return Number(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},8:function(e){return Number(1==e?0:2==e?1:8!=e&&11!=e?2:3)},9:function(e){return Number(e>=2)},10:function(e){return Number(1==e?0:2==e?1:e<7?2:e<11?3:4)},11:function(e){return Number(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3)},12:function(e){return Number(e%10!=1||e%100==11)},13:function(e){return Number(0!==e)},14:function(e){return Number(1==e?0:2==e?1:3==e?2:3)},15:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2)},16:function(e){return Number(e%10==1&&e%100!=11?0:0!==e?1:2)},17:function(e){return Number(1==e||e%10==1&&e%100!=11?0:1)},18:function(e){return Number(0==e?0:1==e?1:2)},19:function(e){return Number(1==e?0:0==e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3)},20:function(e){return Number(1==e?0:0==e||e%100>0&&e%100<20?1:2)},21:function(e){return Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0)},22:function(e){return Number(1==e?0:2==e?1:(e<0||e>10)&&e%10==0?2:3)}},obt=["v1","v2","v3"],lbt={zero:0,one:1,two:2,few:3,many:4,other:5};var sbt=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};gs(this,e),this.languageUtils=t,this.options=n,this.logger=Iyt.create("pluralResolver"),this.options.compatibilityJSON&&"v4"!==this.options.compatibilityJSON||"undefined"!=typeof Intl&&Intl.PluralRules||(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=function(){var e={};return rbt.forEach(function(t){t.lngs.forEach(function(n){e[n]={numbers:t.nr,plurals:ibt[t.fc]}})}),e}()}return ys(e,[{key:"addRule",value:function(e,t){this.rules[e]=t}},{key:"getRule",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(e,{type:t.ordinal?"ordinal":"cardinal"})}catch(e){return}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}},{key:"needsPlural",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return this.shouldUseIntlApi()?n&&n.resolvedOptions().pluralCategories.length>1:n&&n.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.getSuffixes(e,n).map(function(e){return"".concat(t).concat(e)})}},{key:"getSuffixes",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=this.getRule(e,n);return a?this.shouldUseIntlApi()?a.resolvedOptions().pluralCategories.sort(function(e,t){return lbt[e]-lbt[t]}).map(function(e){return"".concat(t.options.prepend).concat(e)}):a.numbers.map(function(a){return t.getSuffix(e,a,n)}):[]}},{key:"getSuffix",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=this.getRule(e,n);return a?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(a.select(t)):this.getSuffixRetroCompatible(a,t):(this.logger.warn("no plural rule found for: ".concat(e)),"")}},{key:"getSuffixRetroCompatible",value:function(e,t){var n=this,a=e.noAbs?e.plurals(t):e.plurals(Math.abs(t)),r=e.numbers[a];this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]&&(2===r?r="plural":1===r&&(r=""));var i=function(){return n.options.prepend&&r.toString()?n.options.prepend+r.toString():r.toString()};return"v1"===this.options.compatibilityJSON?1===r?"":"number"==typeof r?"_plural_".concat(r.toString()):i():"v2"===this.options.compatibilityJSON||this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]?i():this.options.prepend&&a.toString()?this.options.prepend+a.toString():a.toString()}},{key:"shouldUseIntlApi",value:function(){return!obt.includes(this.options.compatibilityJSON)}}]),e}();function cbt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function dbt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cbt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cbt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var hbt=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};gs(this,e),this.logger=Iyt.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(e){return e},this.init(t)}return ys(e,[{key:"init",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});var t=e.interpolation;this.escape=void 0!==t.escape?t.escape:Wyt,this.escapeValue=void 0===t.escapeValue||t.escapeValue,this.useRawValueToEscape=void 0!==t.useRawValueToEscape&&t.useRawValueToEscape,this.prefix=t.prefix?Byt(t.prefix):t.prefixEscaped||"{{",this.suffix=t.suffix?Byt(t.suffix):t.suffixEscaped||"}}",this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||",",this.unescapePrefix=t.unescapeSuffix?"":t.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":t.unescapeSuffix||"",this.nestingPrefix=t.nestingPrefix?Byt(t.nestingPrefix):t.nestingPrefixEscaped||Byt("$t("),this.nestingSuffix=t.nestingSuffix?Byt(t.nestingSuffix):t.nestingSuffixEscaped||Byt(")"),this.nestingOptionsSeparator=t.nestingOptionsSeparator?t.nestingOptionsSeparator:t.nestingOptionsSeparator||",",this.maxReplaces=t.maxReplaces?t.maxReplaces:1e3,this.alwaysFormat=void 0!==t.alwaysFormat&&t.alwaysFormat,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var e="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(e,"g");var t="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(t,"g");var n="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(n,"g")}},{key:"interpolate",value:function(e,t,n,a){var r,i,o,l=this,s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function c(e){return e.replace(/\$/g,"$$$$")}var d=function(e){if(e.indexOf(l.formatSeparator)<0){var r=Pyt(t,s,e);return l.alwaysFormat?l.format(r,void 0,n,dbt(dbt(dbt({},a),t),{},{interpolationkey:e})):r}var i=e.split(l.formatSeparator),o=i.shift().trim(),c=i.join(l.formatSeparator).trim();return l.format(Pyt(t,s,o),c,n,dbt(dbt(dbt({},a),t),{},{interpolationkey:o}))};this.resetRegExp();var h=a&&a.missingInterpolationHandler||this.options.missingInterpolationHandler,u=a&&a.interpolation&&void 0!==a.interpolation.skipOnVariables?a.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:function(e){return c(e)}},{regex:this.regexp,safeValue:function(e){return l.escapeValue?c(l.escape(e)):c(e)}}].forEach(function(t){for(o=0;r=t.regex.exec(e);){var n=r[1].trim();if(void 0===(i=d(n)))if("function"==typeof h){var s=h(e,r,a);i="string"==typeof s?s:""}else if(a&&a.hasOwnProperty(n))i="";else{if(u){i=r[0];continue}l.logger.warn("missed to pass in variable ".concat(n," for interpolating ").concat(e)),i=""}else"string"==typeof i||l.useRawValueToEscape||(i=Oyt(i));var c=t.safeValue(i);if(e=e.replace(r[0],c),u?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=r[0].length):t.regex.lastIndex=0,++o>=l.maxReplaces)break}}),e}},{key:"nest",value:function(e,t){var n,a,r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=dbt({},i);function l(e,t){var n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;var a=e.split(new RegExp("".concat(n,"[ ]*{"))),r="{".concat(a[1]);e=a[0];var i=(r=this.interpolate(r,o)).match(/'/g),l=r.match(/"/g);(i&&i.length%2==0&&!l||l.length%2!=0)&&(r=r.replace(/'/g,'"'));try{o=JSON.parse(r),t&&(o=dbt(dbt({},t),o))}catch(t){return this.logger.warn("failed parsing options string in nesting for key ".concat(e),t),"".concat(e).concat(n).concat(r)}return delete o.defaultValue,e}for(o.applyPostProcessor=!1,delete o.defaultValue;n=this.nestingRegexp.exec(e);){var s=[],c=!1;if(-1!==n[0].indexOf(this.formatSeparator)&&!/{.*}/.test(n[1])){var d=n[1].split(this.formatSeparator).map(function(e){return e.trim()});n[1]=d.shift(),s=d,c=!0}if((a=t(l.call(this,n[1].trim(),o),o))&&n[0]===e&&"string"!=typeof a)return a;"string"!=typeof a&&(a=Oyt(a)),a||(this.logger.warn("missed to resolve ".concat(n[1]," for nesting ").concat(e)),a=""),c&&(a=s.reduce(function(e,t){return r.format(e,t,i.lng,dbt(dbt({},i),{},{interpolationkey:n[1].trim()}))},a.trim())),e=e.replace(n[0],a),this.regexp.lastIndex=0}return e}}]),e}();function ubt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function pbt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ubt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ubt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function fbt(e){var t={};return function(n,a,r){var i=a+JSON.stringify(r),o=t[i];return o||(o=e(a,r),t[i]=o),o(n)}}var mbt=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};gs(this,e),this.logger=Iyt.create("formatter"),this.options=t,this.formats={number:fbt(function(e,t){var n=new Intl.NumberFormat(e,t);return function(e){return n.format(e)}}),currency:fbt(function(e,t){var n=new Intl.NumberFormat(e,pbt(pbt({},t),{},{style:"currency"}));return function(e){return n.format(e)}}),datetime:fbt(function(e,t){var n=new Intl.DateTimeFormat(e,pbt({},t));return function(e){return n.format(e)}}),relativetime:fbt(function(e,t){var n=new Intl.RelativeTimeFormat(e,pbt({},t));return function(e){return n.format(e,t.range||"day")}}),list:fbt(function(e,t){var n=new Intl.ListFormat(e,pbt({},t));return function(e){return n.format(e)}})},this.init(t)}return ys(e,[{key:"init",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}}).interpolation;this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||","}},{key:"add",value:function(e,t){this.formats[e.toLowerCase().trim()]=t}},{key:"addCached",value:function(e,t){this.formats[e.toLowerCase().trim()]=fbt(t)}},{key:"format",value:function(e,t,n,a){var r=this,i=t.split(this.formatSeparator).reduce(function(e,t){var i=function(e){var t=e.toLowerCase().trim(),n={};if(e.indexOf("(")>-1){var a=e.split("(");t=a[0].toLowerCase().trim();var r=a[1].substring(0,a[1].length-1);"currency"===t&&r.indexOf(":")<0?n.currency||(n.currency=r.trim()):"relativetime"===t&&r.indexOf(":")<0?n.range||(n.range=r.trim()):r.split(";").forEach(function(e){if(e){var t=XQe(e.split(":")),a=t[0],r=t.slice(1).join(":").trim().replace(/^'+|'+$/g,"");n[a.trim()]||(n[a.trim()]=r),"false"===r&&(n[a.trim()]=!1),"true"===r&&(n[a.trim()]=!0),isNaN(r)||(n[a.trim()]=parseInt(r,10))}})}return{formatName:t,formatOptions:n}}(t),o=i.formatName,l=i.formatOptions;if(r.formats[o]){var s=e;try{var c=a&&a.formatParams&&a.formatParams[a.interpolationkey]||{},d=c.locale||c.lng||a.locale||a.lng||n;s=r.formats[o](e,d,pbt(pbt(pbt({},l),a),c))}catch(e){r.logger.warn(e)}return s}return r.logger.warn("there was no format function for ".concat(o)),e},e);return i}}]),e}();function vbt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function gbt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vbt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vbt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function wbt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}var ybt=function(){CQe(t,Dyt);var e=wbt(t);function t(n,a,r){var i,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return gs(this,t),i=e.call(this),Ryt&&Dyt.call(qn(i)),i.backend=n,i.store=a,i.services=r,i.languageUtils=r.languageUtils,i.options=o,i.logger=Iyt.create("backendConnector"),i.waitingReads=[],i.maxParallelReads=o.maxParallelReads||10,i.readingCalls=0,i.maxRetries=o.maxRetries>=0?o.maxRetries:5,i.retryTimeout=o.retryTimeout>=1?o.retryTimeout:350,i.state={},i.queue=[],i.backend&&i.backend.init&&i.backend.init(r,o.backend,o),i}return ys(t,[{key:"queueLoad",value:function(e,t,n,a){var r=this,i={},o={},l={},s={};return e.forEach(function(e){var a=!0;t.forEach(function(t){var l="".concat(e,"|").concat(t);!n.reload&&r.store.hasResourceBundle(e,t)?r.state[l]=2:r.state[l]<0||(1===r.state[l]?void 0===o[l]&&(o[l]=!0):(r.state[l]=1,a=!1,void 0===o[l]&&(o[l]=!0),void 0===i[l]&&(i[l]=!0),void 0===s[t]&&(s[t]=!0)))}),a||(l[e]=!0)}),(Object.keys(i).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:a}),{toLoad:Object.keys(i),pending:Object.keys(o),toLoadLanguages:Object.keys(l),toLoadNamespaces:Object.keys(s)}}},{key:"loaded",value:function(e,t,n){var a=e.split("|"),r=a[0],i=a[1];t&&this.emit("failedLoading",r,i,t),n&&this.store.addResourceBundle(r,i,n),this.state[e]=t?-1:2;var o={};this.queue.forEach(function(n){!function(e,t,n,a){var r=Lyt(e,t,Object),i=r.obj,o=r.k;i[o]=i[o]||[],a&&(i[o]=i[o].concat(n)),a||i[o].push(n)}(n.loaded,[r],i),function(e,t){void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)}(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(function(e){o[e]||(o[e]={});var t=n.loaded[e];t.length&&t.forEach(function(t){void 0===o[e][t]&&(o[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",o),this.queue=this.queue.filter(function(e){return!e.done})}},{key:"read",value:function(e,t,n){var a=this,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,o=arguments.length>5?arguments[5]:void 0;return e.length?this.readingCalls>=this.maxParallelReads?void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:i,callback:o}):(this.readingCalls++,this.backend[n](e,t,function(l,s){if(a.readingCalls--,a.waitingReads.length>0){var c=a.waitingReads.shift();a.read(c.lng,c.ns,c.fcName,c.tried,c.wait,c.callback)}l&&s&&r<a.maxRetries?setTimeout(function(){a.read.call(a,e,t,n,r+1,2*i,o)},i):o(l,s)})):o(null,{})}},{key:"prepareLoading",value:function(e,t){var n=this,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();"string"==typeof e&&(e=this.languageUtils.toResolveHierarchy(e)),"string"==typeof t&&(t=[t]);var i=this.queueLoad(e,t,a,r);if(!i.toLoad.length)return i.pending.length||r(),null;i.toLoad.forEach(function(e){n.loadOne(e)})}},{key:"load",value:function(e,t,n){this.prepareLoading(e,t,{},n)}},{key:"reload",value:function(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}},{key:"loadOne",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",a=e.split("|"),r=a[0],i=a[1];this.read(r,i,"read",void 0,void 0,function(a,o){a&&t.logger.warn("".concat(n,"loading namespace ").concat(i," for language ").concat(r," failed"),a),!a&&o&&t.logger.log("".concat(n,"loaded namespace ").concat(i," for language ").concat(r),o),t.loaded(e,a,o)})}},{key:"saveMissing",value:function(e,t,n,a,r){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t)?this.logger.warn('did not save key "'.concat(n,'" as the namespace "').concat(t,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!"):null!=n&&""!==n&&(this.backend&&this.backend.create&&this.backend.create(e,t,n,a,null,gbt(gbt({},i),{},{isUpdate:r})),e&&e[0]&&this.store.addResource(e[0],t,n,a))}}]),t}();function bbt(e){return"string"==typeof e.ns&&(e.ns=[e.ns]),"string"==typeof e.fallbackLng&&(e.fallbackLng=[e.fallbackLng]),"string"==typeof e.fallbackNS&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function xbt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Ebt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?xbt(Object(n),!0).forEach(function(t){vs(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xbt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function kbt(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,a=ZQe(e);if(t){var r=ZQe(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return IQe(this,n)}}function Mbt(){}var Sbt=function(){CQe(t,Dyt);var e=kbt(t);function t(){var n,a,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=arguments.length>1?arguments[1]:void 0;if(gs(this,t),n=e.call(this),Ryt&&Dyt.call(qn(n)),n.options=bbt(r),n.services={},n.logger=Iyt,n.modules={external:[]},a=qn(n),Object.getOwnPropertyNames(Object.getPrototypeOf(a)).forEach(function(e){"function"==typeof a[e]&&(a[e]=a[e].bind(a))}),i&&!n.isInitialized&&!r.isClone){if(!n.options.initImmediate)return n.init(r,i),IQe(n,qn(n));setTimeout(function(){n.init(r,i)},0)}return n}return ys(t,[{key:"init",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;"function"==typeof t&&(n=t,t={}),!t.defaultNS&&!1!==t.defaultNS&&t.ns&&("string"==typeof t.ns?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));var a={debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(e){var t={};if("object"===fs(e[1])&&(t=e[1]),"string"==typeof e[1]&&(t.defaultValue=e[1]),"string"==typeof e[2]&&(t.tDescription=e[2]),"object"===fs(e[2])||"object"===fs(e[3])){var n=e[3]||e[2];Object.keys(n).forEach(function(e){t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:function(e,t,n,a){return e},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}};function r(e){return e?"function"==typeof e?new e:e:null}if(this.options=Ebt(Ebt(Ebt({},a),this.options),bbt(t)),"v1"!==this.options.compatibilityAPI&&(this.options.interpolation=Ebt(Ebt({},a.interpolation),this.options.interpolation)),void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator),!this.options.isClone){var i;this.modules.logger?Iyt.init(r(this.modules.logger),this.options):Iyt.init(null,this.options),this.modules.formatter?i=this.modules.formatter:"undefined"!=typeof Intl&&(i=mbt);var o=new abt(this.options);this.store=new Kyt(this.options.resources,this.options);var l=this.services;l.logger=Iyt,l.resourceStore=this.store,l.languageUtils=o,l.pluralResolver=new sbt(o,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!i||this.options.interpolation.format&&this.options.interpolation.format!==a.interpolation.format||(l.formatter=r(i),l.formatter.init(l,this.options),this.options.interpolation.format=l.formatter.format.bind(l.formatter)),l.interpolator=new hbt(this.options),l.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},l.backendConnector=new ybt(r(this.modules.backend),l.resourceStore,l,this.options),l.backendConnector.on("*",function(t){for(var n=arguments.length,a=new Array(n>1?n-1:0),r=1;r<n;r++)a[r-1]=arguments[r];e.emit.apply(e,[t].concat(a))}),this.modules.languageDetector&&(l.languageDetector=r(this.modules.languageDetector),l.languageDetector.init(l,this.options.detection,this.options)),this.modules.i18nFormat&&(l.i18nFormat=r(this.modules.i18nFormat),l.i18nFormat.init&&l.i18nFormat.init(this)),this.translator=new tbt(this.services,this.options),this.translator.on("*",function(t){for(var n=arguments.length,a=new Array(n>1?n-1:0),r=1;r<n;r++)a[r-1]=arguments[r];e.emit.apply(e,[t].concat(a))}),this.modules.external.forEach(function(t){t.init&&t.init(e)})}if(this.format=this.options.interpolation.format,n||(n=Mbt),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var s=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);s.length>0&&"dev"!==s[0]&&(this.options.lng=s[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(function(t){e[t]=function(){var n;return(n=e.store)[t].apply(n,arguments)}});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(function(t){e[t]=function(){var n;return(n=e.store)[t].apply(n,arguments),e}});var c=Nyt(),d=function(){var t=function(t,a){e.isInitialized&&!e.initializedStoreOnce&&e.logger.warn("init: i18next is already initialized. You should call init just once!"),e.isInitialized=!0,e.options.isClone||e.logger.log("initialized",e.options),e.emit("initialized",e.options),c.resolve(a),n(t,a)};if(e.languages&&"v1"!==e.options.compatibilityAPI&&!e.isInitialized)return t(null,e.t.bind(e));e.changeLanguage(e.options.lng,t)};return this.options.resources||!this.options.initImmediate?d():setTimeout(d,0),c}},{key:"loadResources",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Mbt,a="string"==typeof e?e:this.language;if("function"==typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(a&&"cimode"===a.toLowerCase())return n();var r=[],i=function(e){e&&t.services.languageUtils.toResolveHierarchy(e).forEach(function(e){r.indexOf(e)<0&&r.push(e)})};if(a)i(a);else this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(function(e){return i(e)});this.options.preload&&this.options.preload.forEach(function(e){return i(e)}),this.services.backendConnector.load(r,this.options.ns,function(e){e||t.resolvedLanguage||!t.language||t.setResolvedLanguage(t.language),n(e)})}else n(null)}},{key:"reloadResources",value:function(e,t,n){var a=Nyt();return e||(e=this.languages),t||(t=this.options.ns),n||(n=Mbt),this.services.backendConnector.reload(e,t,function(e){a.resolve(),n(e)}),a}},{key:"use",value:function(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&Qyt.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}},{key:"setResolvedLanguage",value:function(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(var t=0;t<this.languages.length;t++){var n=this.languages[t];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}},{key:"changeLanguage",value:function(e,t){var n=this;this.isLanguageChangingTo=e;var a=Nyt();this.emit("languageChanging",e);var r=function(e){n.language=e,n.languages=n.services.languageUtils.toResolveHierarchy(e),n.resolvedLanguage=void 0,n.setResolvedLanguage(e)},i=function(i){e||i||!n.services.languageDetector||(i=[]);var o="string"==typeof i?i:n.services.languageUtils.getBestMatchFromCodes(i);o&&(n.language||r(o),n.translator.language||n.translator.changeLanguage(o),n.services.languageDetector&&n.services.languageDetector.cacheUserLanguage(o)),n.loadResources(o,function(e){!function(e,i){i?(r(i),n.translator.changeLanguage(i),n.isLanguageChangingTo=void 0,n.emit("languageChanged",i),n.logger.log("languageChanged",i)):n.isLanguageChangingTo=void 0,a.resolve(function(){return n.t.apply(n,arguments)}),t&&t(e,function(){return n.t.apply(n,arguments)})}(e,o)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect(i):i(e):i(this.services.languageDetector.detect()),a}},{key:"getFixedT",value:function(e,t,n){var a=this,r=function e(t,r){var i;if("object"!==fs(r)){for(var o=arguments.length,l=new Array(o>2?o-2:0),s=2;s<o;s++)l[s-2]=arguments[s];i=a.options.overloadTranslationOptionHandler([t,r].concat(l))}else i=Ebt({},r);i.lng=i.lng||e.lng,i.lngs=i.lngs||e.lngs,i.ns=i.ns||e.ns,i.keyPrefix=i.keyPrefix||n||e.keyPrefix;var c=a.options.keySeparator||".",d=i.keyPrefix?"".concat(i.keyPrefix).concat(c).concat(t):t;return a.t(d,i)};return"string"==typeof e?r.lng=e:r.lngs=e,r.ns=t,r.keyPrefix=n,r}},{key:"t",value:function(){var e;return this.translator&&(e=this.translator).translate.apply(e,arguments)}},{key:"exists",value:function(){var e;return this.translator&&(e=this.translator).exists.apply(e,arguments)}},{key:"setDefaultNamespace",value:function(e){this.options.defaultNS=e}},{key:"hasLoadedNamespace",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var a=this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,i=this.languages[this.languages.length-1];if("cimode"===a.toLowerCase())return!0;var o=function(e,n){var a=t.services.backendConnector.state["".concat(e,"|").concat(n)];return-1===a||2===a};if(n.precheck){var l=n.precheck(this,o);if(void 0!==l)return l}return!!this.hasResourceBundle(a,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!o(a,e)||r&&!o(i,e)))}},{key:"loadNamespaces",value:function(e,t){var n=this,a=Nyt();return this.options.ns?("string"==typeof e&&(e=[e]),e.forEach(function(e){n.options.ns.indexOf(e)<0&&n.options.ns.push(e)}),this.loadResources(function(e){a.resolve(),t&&t(e)}),a):(t&&t(),Promise.resolve())}},{key:"loadLanguages",value:function(e,t){var n=Nyt();"string"==typeof e&&(e=[e]);var a=this.options.preload||[],r=e.filter(function(e){return a.indexOf(e)<0});return r.length?(this.options.preload=a.concat(r),this.loadResources(function(e){n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}},{key:"dir",value:function(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(this.services.languageUtils.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Mbt,r=Ebt(Ebt(Ebt({},this.options),n),{isClone:!0}),i=new t(r);void 0===n.debug&&void 0===n.prefix||(i.logger=i.logger.clone(n));return["store","services","language"].forEach(function(t){i[t]=e[t]}),i.services=Ebt({},this.services),i.services.utils={hasLoadedNamespace:i.hasLoadedNamespace.bind(i)},i.translator=new tbt(i.services,i.options),i.translator.on("*",function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),a=1;a<t;a++)n[a-1]=arguments[a];i.emit.apply(i,[e].concat(n))}),i.init(r,a),i.translator.options=i.options,i.translator.backendConnector.services.utils={hasLoadedNamespace:i.hasLoadedNamespace.bind(i)},i}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),t}();vs(Sbt,"createInstance",function(){return new Sbt(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0)});var Abt=Sbt.createInstance();Abt.createInstance=Sbt.createInstance,Abt.createInstance,Abt.init,Abt.loadResources,Abt.reloadResources,Abt.use,Abt.changeLanguage,Abt.getFixedT;var _bt=Abt.t;Abt.exists,Abt.setDefaultNamespace,Abt.hasLoadedNamespace,Abt.loadNamespaces,Abt.loadLanguages;var Cbt=function(e){void 0===e&&(e=new Date);var t=e.getDay(),n=0===t?-6:1-t,a=new Date(e);return a.setDate(e.getDate()+n),a},Zbt=function(e){void 0===e&&(e=new Date);var t=e.getDay(),n=0===t?0:7-t,a=new Date(e);return a.setDate(e.getDate()+n),a},Hbt=function(){var e=new Date,t=e.getFullYear(),n=e.getMonth(),a=e.getDate();return[{value:0,label:"Tùy chọn",type:[]},{value:1,label:"Năm hiện tại",type:[new Date(t,0,1),new Date(t+1,0,0)]},{value:2,label:"Quý hiện tại",type:[new Date(t,3*Math.floor(n/3),1),new Date(t,3*Math.floor(n/3)+3,0)]},{value:3,label:"Tháng hiện tại",type:[new Date(t,n,1),new Date(t,n+1,0)]},{value:4,label:"30 ngày trước",type:[new Date(t,n,a-30),new Date]},{value:5,label:"30 ngày sau",type:[new Date,new Date(t,n,a+30)]},{value:6,label:"Tuần hiện tại",type:[Cbt(),Zbt()]},{value:7,label:"Ngày hiện tại",type:[new Date,new Date]},{value:8,label:"Năm trước",type:[new Date(t-1,0,1),new Date(t,0,0)]},{value:9,label:"Quý trước",type:[new Date(t,3*Math.floor(n/3-1),1),new Date(t,3*Math.floor(n/3-1)+3,0)]},{value:10,label:"Tháng trước",type:[new Date(t,n-1,1),new Date(t,n,0)]},{value:11,label:"Tháng sau",type:[new Date(t,n+1,1),new Date(t,n+2,0)]},{value:12,label:"Tuần trước",type:[Cbt(new Date(t,n,a-7)),Zbt(new Date(t,n,a-7))]},{value:13,label:"Tuần sau",type:[Cbt(new Date(t,n,a+7)),Zbt(new Date(t,n,a+7))]},{value:14,label:"Ngày trước",type:[new Date(t,n,a-1),new Date(t,n,a-1)]}]};exports.ExternalInterface=Zut,exports.ExternalInterfaceExtend=function(t){var n,a,r,i,o,l,s,d=t.toolbarTemplate,h=t.paramToolbar,u=t.currentPageDefault,p=t.queryOrderDefault,m=t.rowsPerPageDefault,v=t.queryKeyDataView,g=t.isSelectMulti,w=t.canContextMenuItems,y=t.handleContextMenuClick,b=t.rowSelected,x=t.dataSourceFilter,E=t.listContextHide,M=t.querySelectDefault,_=t.api,C=t.t,Z=t.contextMenuOpen,H=t.stateId,I=t.viewIdTable,D=t.height,N=t.hasIndex,O=t.dataSelected,L=t.showColumnChoose,V=t.typeCheckbox,z=t.format,P=t.rowSelection,T=t.dataSource,B=t.columns,j=t.totalCount,W=t.breakText,R=t.allowPaging,F=t.allowResizing,Y=t.showUltilities,q=t.handleDoubleContextMenuClick,U=t.stateChildId,G=t.titleChild,X=t.loading,J=t.checkInitSub,$=t.checkInit,ee=t.hasWorkflow,te=t.apiWorkflow,ne=t.rowClassName,ae=t.printApi,re=t.allowFilterClient,ie=t.ultilities,oe=t.summary,le=t.hideSelectAll,se=t.onChangeParam,ce=t.showToolbar,de=t.initAbility,he=t.pageSizeOptions,ue=t.onDataChange,pe=t.group,fe=t.onChangeTabChildren,me=null!=D?D:500,ve=[1,0],ge=[.5,.5],we=e.useState(ve),ye=we[0],be=we[1],xe=e.useState(me),Ee=xe[0],ke=xe[1],Me=e.useState(0),Se=Me[0],Ae=Me[1],_e=e.useState(0),Ce=_e[0],Ze=_e[1],He=e.useState({}),Ie=He[0],De=He[1],Ne=e.useState({}),Oe=Ne[0],Le=Ne[1],Ve=e.useState({}),ze=Ve[0],Pe=Ve[1],Te=e.useState({}),Be=Te[0],je=Te[1],We=Q(null==Ie?void 0:Ie.file)?"[]":null==Ie?void 0:Ie.file,Re=function(){be(ge),ke(me/2),Ae(me/2)},Fe=function(){Ze(0),fe&&fe(0),be(ve),ke(me),Ae(0)};e.useEffect(function(){je(k(k({},Be),ze))},[ze]),e.useEffect(function(){0===(null==ye?void 0:ye[1])&&(Ze(0),fe&&fe(0))},[null==ye?void 0:ye[1]]);var Ye=function(){return{innerWidth:window.innerWidth,innerHeight:window.innerHeight}},qe=e.useState(Ye()),Ue=qe[0],Ge=qe[1];e.useEffect(function(){var e=function(){Ge(Ye())};return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}},[]);var Ke=e.useState({}),Qe=Ke[0],Xe=Ke[1],Je=(null!==(n=null==U?void 0:U.filter(function(e){return K(e.columns)}).map(function(e){return e.stateId}))&&void 0!==n?n:[]).join();return e.useEffect(function(){Q(Je)||function(e){S(void 0,void 0,void 0,function(){var t,n,a,r,i,o,l,s;return A(this,function(c){switch(c.label){case 0:return[4,mi({ParaJson:JSON.stringify({ViewId:e})})];case 1:return t=c.sent(),n=JSON.parse(null!==(o=null===(i=null==t?void 0:t[0])||void 0===i?void 0:i.dataJson)&&void 0!==o?o:"[]"),a=JSON.parse(null!==(s=null===(l=null==n?void 0:n[0])||void 0===l?void 0:l.Data)&&void 0!==s?s:"[]"),r={},null==U||U.forEach(function(e){var t,n=a.filter(function(t){var n,a;return(null!==(n=null==t?void 0:t.ViewId)&&void 0!==n?n:"").toLowerCase()===(null!==(a=null==e?void 0:e.stateId)&&void 0!==a?a:"").toLowerCase()});r[e.stateId]=yi([],C,{hasIndex:null===(t=null==e?void 0:e.hasIndex)||void 0===t||t,breakText:null==e?void 0:e.breakText,hasWorkflow:!1,levelGroup:0,responseColumn:n})}),Xe(r),[2]}})})}(Je)},[Je]),f.default.createElement("div",{style:{height:"".concat(Ue.innerHeight-180,"px")}},f.default.createElement(Put,{orientation:"horizontal"},f.default.createElement(dpt,{flex:ye[0],minSize:0,onStopResize:function(e){var t=e.domElement.clientHeight;ke(t),Ae(me-t)},style:{}},f.default.createElement("div",{className:"pane-content",id:"reflex-top"},f.default.createElement("div",{onMouseUp:function(e){2===(null==e?void 0:e.button)&&Fe()}},f.default.createElement(Zut,{windowSize:Ue,showColumnChoose:L,isSelectMulti:g,dataSourceFilter:x,totalCount:j,dataSource:T,columns:B,rowSelection:P,format:z,stateId:H,stateChildId:U,height:Ee-5,viewIdTable:I,currentPageDefault:u,rowsPerPageDefault:m,pageSizeOptions:he,queryOrderDefault:p,queryKeyDataView:v,handleContextMenuClick:y,rowSelected:function(e){b&&b(e),function(e){var t;Ze(0),fe&&fe(0);var n=e.rowData;n&&!e.rightClick&&U&&(null==U?void 0:U.length)>0&&K(null==n?void 0:n.field)&&(De(e.rowData),Re()),(0===(null===(t=e.selected)||void 0===t?void 0:t.length)||e.rightClick)&&(De({}),Fe())}(e)},group:pe,allowPaging:R,allowResizing:F,listContextHide:E,querySelectDefault:M,contextMenuOpen:Z,canContextMenuItems:w,typeCheckbox:V,t:C,api:_,toolbarTemplate:d,paramToolbar:h,hasIndex:N,breakText:W,dataSelected:O,handleDoubleContextMenuClick:q,loading:X,checkInit:$,checkInitSub:J,hasWorkflow:ee,apiWorkflow:te,rowClassName:ne,printApi:ae,showUltilities:Y,allowFilterClient:re,summary:oe,hideSelectAll:le,ultilities:ie,onChangeParam:se,showToolbar:ce,initAbility:de,onDataChange:ue})))),U&&U.length>0&&f.default.createElement(Vut,{style:{display:0===ye[1]?"none":"block"}}),U&&U.length>0&&f.default.createElement(dpt,{flex:ye[1],style:{height:"".concat(me-Ee-150,"px")},minSize:0},f.default.createElement(Tut,{className:"handle"},f.default.createElement("div",{style:{marginTop:"5px",marginBottom:"0px",paddingBottom:"5px"},className:"d-flex justify-content-between align-items-center bb-1"},f.default.createElement("h5",{className:"m-0"},G),f.default.createElement("div",{className:"me-auto ms-1 d-flex align-items-center"},(null===(a=null==U?void 0:U[Ce])||void 0===a?void 0:a.buttons)&&(null===(i=null===(r=null==U?void 0:U[Ce])||void 0===r?void 0:r.buttons)||void 0===i?void 0:i.map(function(e,t){var n,a,r,i=oi[null!==(n=e.icon)&&void 0!==n?n:"Plus"];return"right"!==e.align&&!1!==e.visible&&f.default.createElement(Hn,{color:e.color||"primary",onClick:function(){return e.actionClick({rowData:null==Oe?void 0:Oe[Ce]})},disabled:e.disabled,key:t,className:"me-1 d-flex"},f.default.createElement(i,{fontSize:null!==(a=e.fontSize)&&void 0!==a?a:14,className:"me-50"}),String(C(null!==(r=e.title)&&void 0!==r?r:"")))}))),f.default.createElement("div",{className:"ms-auto d-flex align-items-center"},(null===(o=null==U?void 0:U[Ce])||void 0===o?void 0:o.buttons)&&(null===(s=null===(l=null==U?void 0:U[Ce])||void 0===l?void 0:l.buttons)||void 0===s?void 0:s.map(function(e,t){var n,a,r,i=oi[null!==(n=e.icon)&&void 0!==n?n:"Plus"];return"right"===e.align&&!1!==e.visible&&f.default.createElement(Hn,{color:e.color||"primary",onClick:function(){return e.actionClick({rowData:null==Oe?void 0:Oe[Ce]})},disabled:e.disabled,key:t,className:"me-1 d-flex"},f.default.createElement(i,{fontSize:null!==(a=e.fontSize)&&void 0!==a?a:14,className:"me-50"}),String(C(null!==(r=e.title)&&void 0!==r?r:"")))}))),f.default.createElement("span",null,f.default.createElement(ii,{style:{marginRight:5},fontSize:20,onClick:Fe,className:"cursor-pointer"})))),f.default.createElement("div",{className:"pane-content",id:"reflex-bottom",style:{height:"".concat(me-Ee-70,"px")}},f.default.createElement("div",{className:"bg-white p-25",style:{border:"1px solid #e0e0e0"}},f.default.createElement(c.TabComponent,{overflowMode:"Popup",heightAdjustMode:"Auto",className:"m-0",animation:{next:{effect:"None"},previous:{effect:"None"}},selectedItem:Ce,selected:function(e){Ze(e.selectedIndex),fe&&fe(e.selectedIndex)}},f.default.createElement(c.TabItemsDirective,null,null==U?void 0:U.map(function(e,t){var n,a,r,i;return"AttachFile"!==e.stateId?f.default.createElement(c.TabItemDirective,{key:t,headerText:"".concat(C(e.stateName)," (").concat(null!==(a=null!==(n=e.totalCount)&&void 0!==n?n:null==Be?void 0:Be[t])&&void 0!==a?a:0,")")}):f.default.createElement(c.TabItemDirective,{key:t,headerText:"".concat(C(Q(e.stateName)?"File attached":e.stateName)," (").concat(null!==(r=e.totalCount)&&void 0!==r?r:null===(i=Array.isArray(JSON.parse(We))?JSON.parse(We):[])||void 0===i?void 0:i.length,")")})}))),f.default.createElement("div",{className:"box form-box__border d-flex flex-column p-0"},f.default.createElement(jr,{activeTab:Ce},null==U?void 0:U.map(function(e,t){var n,a,r,i,o,l;return K(e.content)?"AttachFile"!==e.stateId?f.default.createElement(qr,{key:t,tabId:t},f.default.createElement(Iut,{index:t,windowSize:Ue,stateChildId:U,titleChild:G,group:e.group,showColumnChoose:!0,showToolbar:!1,format:z,height:Se-95,stateId:null!==(n=e.stateId)&&void 0!==n?n:"",viewIdTable:null!==(a=e.stateId)&&void 0!==a?a:"",dataSource:null!==(r=null==e?void 0:e.dataSource)&&void 0!==r?r:(null==Ie?void 0:Ie.id)?void 0:[],columns:null!==(o=null!==(i=null==e?void 0:e.columns)&&void 0!==i?i:null==Qe?void 0:Qe[e.stateId])&&void 0!==o?o:void 0,totalCount:null==e?void 0:e.totalCount,summary:null===(l=e.summary)||void 0===l||l,onChangeParam:e.onChangeParam,currentPageDefault:u,rowsPerPageDefault:m,pageSizeOptions:he,rowSelected:function(t){e.rowSelected&&e.rowSelected(t),Oe[Ce]=t.selected,Le(Oe)},callback:function(e){setTimeout(function(){Pe(function(n){var a;return k(k({},n),((a={})[t]=e.total,a))})},50*(t+1))},querySelectDefault:e.querySelectDefault,queryKeyDataView:[null==Ie?void 0:Ie.id],allowPaging:e.allowPaging,allowResizing:e.allowResizing,t:C,api:_,hasIndex:!0,breakText:W,loading:X,rowClassName:e.rowClassName,allowFilterClient:!0,typeCheckbox:e.typeCheckbox,onDataChange:e.onDataChange})):"AttachFile"===e.stateId?f.default.createElement(qr,{tabId:t,key:t},f.default.createElement(Dut,{height:Se-80,listFile:We,t:C})):void 0:f.default.createElement(qr,{key:t,tabId:t},e.content instanceof Function?e.content():e.content)}))))))))},exports.HeaderExternalInterface=function(e){var t=e.buttons,n=e.breadCrumb,a=e.CanPer,r=e.t;return f.default.createElement("div",{className:"table-toolbar"},f.default.createElement(ha,{className:"table-bar bar__action"},f.default.createElement(va,null,f.default.createElement("div",{className:"d-flex justify-content-between align-items-center w-100"},f.default.createElement("div",{className:"bar__action-left"},f.default.createElement(hpt,{breadCrumbTitle:n.breadCrumbTitle,breadCrumbActive:r(n.breadCrumbActive),breadCrumbParent:n.breadCrumbParent})),f.default.createElement("div",{className:"bar__action-right d-flex"},t&&t.length>0&&t.map(function(e,t){var n,i,o,l=oi[null!==(n=e.icon)&&void 0!==n?n:"Plus"];return f.default.createElement(a,{I:e.userAction,a:e.userSubject,key:t},f.default.createElement(Hn,{color:e.color||"primary",onClick:e.actionClick,disabled:e.disabled,className:"me-1 d-flex"},f.default.createElement(l,{fontSize:null!==(i=e.fontSize)&&void 0!==i?i:14,className:"me-50"}),String(r(null!==(o=e.title)&&void 0!==o?o:""))))}))))))},exports.ToolbarTemplate=function(e){var t=window.localStorage.getItem("i18nextLng"),n=t||"vi";return zmt.load({vi:{daterangepicker:{placeholder:"Chọn ngày",startLabel:"Ngày bắt đầu",endLabel:"Ngày kết thúc",applyText:"Chọn",cancelText:"Hủy",selectedDays:"Chọn ngày",days:"Ngày",customRange:"Tùy chỉnh"}}}),function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=0,a=e;n<a.length;n++){var r=a[n];bpt($pt,r,{},!0)}}(require("@src/assets/cldr-data/main/".concat(n,"/ca-gregorian.json")),require("@src/assets/cldr-data/main/".concat(n,"/numbers.json")),require("@src/assets/cldr-data/main/".concat(n,"/timeZoneNames.json")),require("@src/assets/supplemental/numberingSystems.json")),eft=n,Jpt.notify("notifyExternalChange",{locale:eft}),e.map(function(e,t){var a,r,i,o,l,s,c,d,u,p,m,v,g,w,y,b,x,E,M,S,A,_,C,Z,H,I,D,N,O,L,V=null!==(a=e.option)&&void 0!==a?a:[],P=function(e,t){for(var n,a=0;a<e.length;a++){var r=e[a];if(r[r.fieldValue?r.fieldValue:"value"]===t)return k({},r);if((null===(n=r.children)||void 0===n?void 0:n.length)>0){var i=P(r.children,t);if(i)return i}}};return K(e.template)?{template:f.default.createElement("div",{key:t,className:"me-50",style:{width:null!==(r=e.width)&&void 0!==r?r:"listDate"===e.type?220:200},title:_bt(null!==(i=e.placeholder)&&void 0!==i?i:"")},"daterange"===e.type&&f.default.createElement(Ayt,{id:"daterangepicker",placeholder:e.t(null!==(o=e.placeholder)&&void 0!==o?o:""),startDate:!K(e.data)&&(null===(l=e.data)||void 0===l?void 0:l.length)>0?e.data[0]:void 0,endDate:!K(e.data)&&(null===(s=e.data)||void 0===s?void 0:s.length)>0?e.data[1]:void 0,format:z.dateFormat,onChange:function(t){var n,a;K(null===(n=t.target)||void 0===n?void 0:n.value)?e.setData([]):e.setData(null===(a=t.target)||void 0===a?void 0:a.value)},openOnFocus:!0,locale:n}),"listDate"===e.type&&(0===(null===(c=e.data)||void 0===c?void 0:c.value)?f.default.createElement(Ayt,{id:"daterangepicker",placeholder:e.t(null!==(d=e.placeholder)&&void 0!==d?d:""),startDate:!K(null===(u=e.data)||void 0===u?void 0:u.type)&&(null===(m=null===(p=e.data)||void 0===p?void 0:p.type)||void 0===m?void 0:m.length)>0?null===(g=null===(v=e.data)||void 0===v?void 0:v.type)||void 0===g?void 0:g[0]:void 0,endDate:!K(null===(w=e.data)||void 0===w?void 0:w.type)&&(null===(b=null===(y=e.data)||void 0===y?void 0:y.type)||void 0===b?void 0:b.length)>0?null===(E=null===(x=e.data)||void 0===x?void 0:x.type)||void 0===E?void 0:E[1]:void 0,format:z.dateFormat,onChange:function(t){var n,a;K(null===(n=t.target)||void 0===n?void 0:n.value)?e.setData({}):e.setData(k(k({},e.data),{type:null===(a=t.target)||void 0===a?void 0:a.value}))},openOnFocus:!0,locale:n}):f.default.createElement(h.SelectTable,{onChange:function(t){var n;0===(null==t?void 0:t.value)?e.setData({value:t.value,type:null===(n=e.data)||void 0===n?void 0:n.type}):e.setData(t)},isClearable:!0,options:Hbt(),value:Hbt().find(function(t){var n;return t.value===(null===(n=e.data)||void 0===n?void 0:n.value)}),placeholder:_bt(null!==(M=e.placeholder)&&void 0!==M?M:"")})),"select"===e.type&&f.default.createElement(h.SelectTable,{value:e.isMulti?Array.isArray(e.data)&&e.data.length>0?V.filter(function(t){return Array.isArray(e.data)&&e.data.some(function(n){var a;return t[null!==(a=e.fieldValue)&&void 0!==a?a:"value"]===n})}):[]:K(e.data)?void 0:V.find(function(t){var n;return t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"]===e.data}),onChange:function(t){var n,a,r;e.isMulti&&(K(t)||0===(null==t?void 0:t.length))?e.setData([]):!e.isMulti&&K(t)?e.setData(void 0):(e.isMulti||JSON.stringify(t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"])!==JSON.stringify(e.data))&&(e.isMulti?e.setData((null!==(a=null==t?void 0:t.length)&&void 0!==a?a:0)>0?t.map(function(t){var n;return t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"]}):[]):e.setData(K(t)?void 0:t[null!==(r=e.fieldValue)&&void 0!==r?r:"value"]))},fieldValue:null!==(S=e.fieldValue)&&void 0!==S?S:"value",fieldLabel:null!==(A=e.fieldLabel)&&void 0!==A?A:"label",placeholder:e.t(null!==(_=e.placeholder)&&void 0!==_?_:""),isMulti:null!==(C=e.isMulti)&&void 0!==C&&C,options:V,isClearable:null===(Z=e.isClearable)||void 0===Z||Z,columns:e.columns,loadOptions:e.loadOption}),"selecttree"===e.type&&f.default.createElement(h.SelectTableTree,{value:(e.isMulti?(null===(H=e.data)||void 0===H?void 0:H.length)>0:!K(e.data))?e.isMulti?e.data:P(V,e.data):e.isMulti?[]:void 0,onChange:function(t){var n;(e.isMulti||(e.fieldValue&&t?t[e.fieldValue]:null==t?void 0:t.value)!==e.data)&&(e.isMulti?e.setData(K(t)?[]:t):e.setData(K(t)?void 0:t[null!==(n=e.fieldValue)&&void 0!==n?n:"value"]))},columns:null!==(I=e.columns)&&void 0!==I?I:me,placeholder:e.t(null!==(D=e.placeholder)&&void 0!==D?D:""),options:null!=V?V:[],isMulti:null!==(N=e.isMulti)&&void 0!==N&&N,isClearable:!0})),position:null!==(O=e.position)&&void 0!==O?O:"left"}:{template:e.template instanceof Function?e.template():e.template,position:null!==(L=e.position)&&void 0!==L?L:"left"}})},exports.listFilterDate=Hbt,exports.renderColumnTable=function(e,t,n){var a,r,i,o,l,s,c,d=JSON.parse(null!==(r=null===(a=null==e?void 0:e[0])||void 0===a?void 0:a.dataJson)&&void 0!==r?r:"[]"),h=JSON.parse(null===(i=null==d?void 0:d[0])||void 0===i?void 0:i.Data),u={Data:null==h?void 0:h.filter(function(e){return!0===(null==e?void 0:e.IsActive)})},p=[];n&&p.push({width:60,type:"number",freeze:"Left",field:"STT",textAlign:"center",headerText:"STT",allowFiltering:!1,allowSorting:!1});for(var f=function(e){var n=u.Data[e],a={field:n.ColVirtual,headerText:n.Title,visible:!n.IsHidden,width:n.Width,maxWidth:null!==(o=n.MaxWidth)&&void 0!==o?o:n.Width,minWidth:null!==(l=n.MinWidth)&&void 0!==l?l:n.Width,allowSorting:!0,clipMode:"EllipsisWithTooltip",freeze:n.Freeze,textAlign:n.TextAlign};switch(n.Type){case"datetime":a.typeFilter="DateRange",a.template=J,a.type="datetime",a.hideOperator=!0;break;case"date":a.hideOperator=!0,a.typeFilter="DateRange",a.template=J,a.type="date";break;case"checkbox":a.hideOperator=!0,a.typeFilter="Checkbox";break;case"number":a.typeFilter="Number",a.type="number",Q(n.TypeDecimal)||"quantity"===n.TypeDecimal?a.template=oe:"allocationRatio"===n.TypeDecimal?a.template=pe:"exchangeMoney"===n.TypeDecimal?a.template=se:"overseaMoney"===n.TypeDecimal?a.template=le:"rate"===n.TypeDecimal?a.template=he:"ratio"===n.TypeDecimal?a.template=ue:"so_cong"===n.TypeDecimal?a.template=fe:"unitPriceExchange"===n.TypeDecimal?a.template=ce:"unitPriceOversea"===n.TypeDecimal?a.template=de:a.template="";break;default:a.type="string"}!Q(n.ColTemplate)&&Q(n.OptionTemplate)&&(a.template=function(e){var a;return t(null==e?void 0:e[null!==(a=n.ColTemplate)&&void 0!==a?a:""])}),Q(n.ColTemplate)||Q(n.OptionTemplate)||(a.source=null===(c=JSON.parse(null!==(s=n.OptionTemplate)&&void 0!==s?s:"[]"))||void 0===c?void 0:c.map(function(e){var n,a;return k(k({},e),{value:null!==(n=null==e?void 0:e.value)&&void 0!==n?n:null==e?void 0:e.id,label:t(null!==(a=e.label)&&void 0!==a?a:null==e?void 0:e.name)})}),a.template=function(e){var t,r;return null===(r=null===(t=a.source)||void 0===t?void 0:t.find(function(t){var a;return(null==t?void 0:t.value)===(null==e?void 0:e[null!==(a=n.ColTemplate)&&void 0!==a?a:""])}))||void 0===r?void 0:r.label}),0===e&&"checkbox"===n.Type?p.unshift({width:40,type:"checkbox",freeze:"Left"}):("id"===n.ColVirtual&&(a.isPrimaryKey=!0),p.push(a))},m=0;m<u.Data.length;m++)f(m);return p},exports.renderColumnTableBe=function(e,t,n,a){var r,i,o,l,s=JSON.parse(null!==(i=null===(r=null==e?void 0:e[0])||void 0===r?void 0:r.dataJson)&&void 0!==i?i:"[]"),c=JSON.parse(null!==(l=null===(o=null==s?void 0:s[0])||void 0===o?void 0:o.Data)&&void 0!==l?l:"[]"),d={Data:null==c?void 0:c.filter(function(e){return!0===(null==e?void 0:e.IsActive)})},h={};return n.forEach(function(e){for(var n,r,i,o,l,s,c,u=d.Data.filter(function(t){return t.ViewId===e}),p=[],f=function(e){var d=u[e],h={field:null!==(n=d.ColVirtual)&&void 0!==n?n:"",headerText:d.Title,visible:!d.IsHidden,width:d.Width,maxWidth:null!==(r=d.MaxWidth)&&void 0!==r?r:d.Width,minWidth:null!==(i=d.MinWidth)&&void 0!==i?i:d.Width,allowFiltering:!0,allowSorting:!0,textAlign:null!==(o=d.TextAlign)&&void 0!==o?o:"left",fixedType:Q(d.Freeze)?void 0:(null!==(l=d.Freeze)&&void 0!==l?l:"").toLowerCase()};switch(d.Type){case"datetime":h.typeFilter="DateRange",h.type="datetime";break;case"date":h.typeFilter="DateRange",h.type="date";break;case"checkbox":h.typeFilter="Checkbox",h.type="checkbox",h.hideOperator=!0;break;case"number":h.typeFilter="Number",h.type="number",Q(d.TypeDecimal)||"quantity"===d.TypeDecimal?h.format={decimalScale:ae("quantity")}:h.format={decimalScale:ae(Q(d.TypeDecimal)?"quantity":d.TypeDecimal)};break;default:h.type="string"}!Q(d.ColTemplate)&&Q(d.OptionTemplate)&&(h.template=function(e){var n;return t(null==e?void 0:e[null!==(n=d.ColTemplate)&&void 0!==n?n:""])}),Q(d.ColTemplate)||Q(d.OptionTemplate)||(h.source=null===(c=JSON.parse(null!==(s=d.OptionTemplate)&&void 0!==s?s:"[]"))||void 0===c?void 0:c.map(function(e){var n,a;return k(k({},e),{value:null!==(n=null==e?void 0:e.value)&&void 0!==n?n:null==e?void 0:e.id,label:t(null!==(a=e.label)&&void 0!==a?a:null==e?void 0:e.name)})}),h.template=function(e){var t,n;return null===(n=null===(t=h.source)||void 0===t?void 0:t.find(function(t){var n;return(null==t?void 0:t.value)===(null==e?void 0:e[null!==(n=d.ColTemplate)&&void 0!==n?n:""])}))||void 0===n?void 0:n.label}),0===e&&"checkbox"===d.Type?(p.push({width:40,field:"checkbox",fixedType:"left"}),p.push({field:"",headerText:"STT",textAlign:"center",headerTextAlign:"center",template:function(e){return e.indexRow+1},fixedType:"left",visible:a,width:50,minWidth:50,maxWidth:50})):(0===e&&p.push({field:"",headerText:"STT",textAlign:"center",headerTextAlign:"center",template:function(e){return e.indexRow+1},fixedType:"left",visible:a,width:50,minWidth:50,maxWidth:50}),p.push(h))},m=0;m<u.length;m++)f(m);h[e]=p}),h},exports.renderColumnTableGrid=yi;