import{e as Yu}from"./chunk-35QF24UV.js";import{Ca as SE,Ga as EE,Y as ju,a as yf,aa as La,e as Va,ia as qu,ya as Na}from"./chunk-KOULBGOK.js";import{$c as Uu,Ab as te,Ac as Ba,Bb as L,Bc as CE,Cb as wi,Cc as Ku,Ea as un,Eb as J,Fa as Ge,Fb as Gi,Ja as Pe,Ka as Ad,Lb as pE,Lc as le,Mc as xE,Nc as vE,Pa as Je,Sb as Md,Tb as mt,Ua as je,Ub as gE,Vb as Gr,Xb as mE,aa as Gu,bd as bE,ca as Ht,cc as ro,da as Dd,dc as ao,ea as V,ec as cs,fc as fE,g as aE,ga as Wr,gc as _E,gd as yE,hc as Pa,hd as OE,ja as Td,k as lE,ld as bf,mb as Zt,nd as Xs,ob as uE,oc as mi,od as Rd,pc as nn,qb as ds,qc as fi,r as dE,rb as E,rc as _i,tb as hE,tc as ke,va as Ze,vc as Be,wc as Ve,x as cE,za as ki,zc as ka}from"./chunk-ZGECHOBP.js";import{a as yn,b as so,g as G1}from"./chunk-K4ALXBGI.js";var K1={"[object Array]":"array","[object Date]":"date","[object Object]":"object","[object String]":"string"},ri=function(i){if(i===null)return"null";let e=Object.prototype.toString.call(i);return typeof i=="object"?K1[e]||"object":typeof i},Qs=function(i){return typeof i=="boolean"},Xu=function(i){return xe(i)&&i.toString().indexOf("e")!==-1},Et=function(i){return ri(i)==="date"},f=function(i){return i!=null},A=function(i){return typeof i=="function"},B=function(i){return typeof i=="string"},xe=function(i){return typeof i=="number"&&isFinite(i)||!isNaN(i-parseFloat(i))},$=function(i){return ri(i)==="object"},dt=function(i){let e;for(e in i)return!1;return!0},q=function(i){if(!i||ri(i)!=="object")return!1;let e=Object.getPrototypeOf(i);if(!e)return!0;let t=Object.hasOwnProperty.call(e,"constructor")&&e.constructor;return typeof t=="function"&&Object.toString.call(t)===Object.toString.call(Object)},Zs=function(i){return["object","array","function"].indexOf(ri(i))===-1},Ne=function(i){return i!=null&&i===i.window},$t=function(i){return!!i&&!!(i.jquery||i.dxRenderer)},To=function(i){return!!i&&A(i.then)},Ha=function(i){return!!i&&A(i.done)&&A(i.fail)},wE=function(i){return!!(i&&i.preventDefault)};var IE=function(i,e,t){i=i||{};for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n)){let o=e[n];(!(n in i)||t)&&(i[n]=o)}return i},m=function(i){i=i||{};let e=1,t=!1;for(typeof i=="boolean"&&(t=i,i=arguments[1]||{},e++);e<arguments.length;e++){let n=arguments[e];if(n!=null)for(let o in n){let s=i[o],r=n[o],a=!1,l;o==="__proto__"||o==="constructor"||i===r||(t&&r&&(q(r)||(a=Array.isArray(r)))?(a?l=s&&Array.isArray(s)?s:[]:l=s&&q(s)?s:{},i[o]=m(t,l,r)):r!==void 0&&(i[o]=r))}}return i};var He=(i,e)=>{if(Array.isArray(i))return i.map(e);let t=[];for(let n in i)t.push(e(i[n],n));return t},x=(i,e)=>{if(i){if("length"in i)for(let t=0;t<i.length&&e.call(i[t],t,i[t])!==!1;t++);else for(let t in i)if(e.call(i[t],t,i[t])===!1)break;return i}};var U1=function(){},Qu=function(i){return typeof console>"u"||!A(console[i])?U1:console[i].bind(console)},Js={log:Qu("log"),info:Qu("info"),warn:Qu("warn"),error:Qu("error")};var Zu=function(){let i=[new RegExp("&","g"),new RegExp('"',"g"),new RegExp("'","g"),new RegExp("<","g"),new RegExp(">","g")];return function(e){return String(e).replace(i[0],"&amp;").replace(i[1],"&quot;").replace(i[2],"&#39;").replace(i[3],"&lt;").replace(i[4],"&gt;")}}(),j1=function(i){switch(typeof i){case"string":return i.split(/\s+/,4);case"object":return[i.x||i.h||i.left,i.y||i.v||i.top,i.x||i.h||i.right,i.y||i.v||i.bottom];case"number":return[i];default:return i}},DE=function(i){let e=j1(i),t=parseInt(e&&e[0],10),n=parseInt(e&&e[1],10),o=parseInt(e&&e[2],10),s=parseInt(e&&e[3],10);return isFinite(t)||(t=0),isFinite(n)||(n=t),isFinite(o)||(o=t),isFinite(s)||(s=n),{top:n,right:o,bottom:s,left:t}};function Ii(i){for(var e=arguments.length,t=new Array(e>1?e-1:0),n=1;n<e;n++)t[n-1]=arguments[n];return A(i)?i(...t):(t.forEach((o,s)=>{B(o)&&(o=o.replace(/\$/g,"$$$$"));let r=new RegExp("\\{"+s+"\\}","gm");i=i.replace(r,o)}),i)}var $a=function(){let i=/\s/g;return function(e){return!e||!e.replace(i,"")}}();var TE="24.1.10",Sf="24.1.10";var q1="https://js.devexpress.com/error/"+TE.split(".").slice(0,2).join("_")+"/";function za(i,e){let t={ERROR_MESSAGES:m(e,i),Error:function(){return function(r){let a=r[0];r=r.slice(1);let l=n(a,r),d=s(a),c=o(a,l);return m(new Error(c),{__id:a,__details:l,url:d})}([].slice.call(arguments))},log:function(r){let a="log";/^E\d+$/.test(r)?a="error":/^W\d+$/.test(r)&&(a="warn"),Js[a](a==="log"?r:function(l){let d=l[0];return l=l.slice(1),o(d,n(d,l))}([].slice.call(arguments)))}};function n(r,a){return a=[t.ERROR_MESSAGES[r]].concat(a),Ii.apply(this,a).replace(/\.*\s*?$/,"")}function o(r,a){let l=r!=null&&r.startsWith("W")?"warning":"error";return Ii.apply(this,[`{0} - {1}.

For additional information on this {2} message, see: {3}`,r,a,l,s(r)])}function s(r){return q1+r}return t}var he=za({E0001:"Method is not implemented",E0002:"Member name collision: {0}",E0003:"A class must be instantiated using the 'new' keyword",E0004:"The NAME property of the component is not specified",E0005:"Unknown device",E0006:"Unknown endpoint key is requested",E0007:"'Invalidate' method is called outside the update transaction",E0008:"Type of the option name is not appropriate to create an action",E0009:"Component '{0}' has not been initialized for an element",E0010:"Animation configuration with the '{0}' type requires '{1}' configuration as {2}",E0011:"Unknown animation type '{0}'",E0012:"jQuery version is too old. Please upgrade jQuery to 1.10.0 or later",E0013:"KnockoutJS version is too old. Please upgrade KnockoutJS to 2.3.0 or later",E0014:"The 'release' method shouldn't be called for an unlocked Lock object",E0015:"Queued task returned an unexpected result",E0017:"Event namespace is not defined",E0018:"DevExpress.ui.DevExpressPopup widget is required",E0020:"Template engine '{0}' is not supported",E0021:"Unknown theme is set: {0}",E0022:"LINK[rel=DevExpress-theme] tags must go before DevExpress included scripts",E0023:"Template name is not specified",E0024:"DevExtreme bundle already included",E0025:"Unexpected argument type",E0100:"Unknown validation type is detected",E0101:"Misconfigured range validation rule is detected",E0102:"Misconfigured comparison validation rule is detected",E0103:"validationCallback of an asynchronous rule should return a jQuery or a native promise",E0110:"Unknown validation group is detected",E0120:"Adapter for a DevExpressValidator component cannot be configured",E0121:"The 'customItem' parameter of the 'onCustomItemCreating' function is empty or contains invalid data. Assign a custom object or a Promise that is resolved after the item is created.",W0000:"'{0}' is deprecated in {1}. {2}",W0001:"{0} - '{1}' option is deprecated in {2}. {3}",W0002:"{0} - '{1}' method is deprecated in {2}. {3}",W0003:"{0} - '{1}' property is deprecated in {2}. {3}",W0004:"Timeout for theme loading is over: {0}",W0005:"'{0}' event is deprecated in {1}. {2}",W0006:"Invalid recurrence rule: '{0}'",W0007:"'{0}' Globalize culture is not defined",W0008:"Invalid view name: '{0}'",W0009:"Invalid time zone name: '{0}'",W0010:"{0} is deprecated in {1}. {2}",W0011:"Number parsing is invoked while the parser is not defined",W0012:"Date parsing is invoked while the parser is not defined",W0013:"'{0}' file is deprecated in {1}. {2}",W0014:"{0} - '{1}' type is deprecated in {2}. {3}",W0015:"Instead of returning a value from the '{0}' function, write it into the '{1}' field of the function's parameter.",W0016:'The "{0}" option does not accept the "{1}" value since v{2}. {3}.',W0017:'Setting the "{0}" property with a function is deprecated since v21.2',W0018:'Setting the "position" property with a function is deprecated since v21.2',W0019:`DevExtreme: Unable to Locate a Valid License Key.

Detailed license/registration related information and instructions: https://js.devexpress.com/Documentation/Licensing/.

If you are using a 30-day trial version of DevExtreme, you must uninstall all copies of DevExtreme once your 30-day trial period expires. For terms and conditions that govern use of DevExtreme UI components/libraries, please refer to the DevExtreme End User License Agreement: https://js.devexpress.com/EULAs/DevExtremeComplete.

To use DevExtreme in a commercial project, you must purchase a license. For pricing/licensing options, please visit: https://js.devexpress.com/Buy.

If you have licensing-related questions or need help with a purchase, please email clientservices@devexpress.com.

`,W0020:`DevExtreme: License Key Has Expired.

Detailed license/registration related information and instructions: https://js.devexpress.com/Documentation/Licensing/.

A mismatch exists between the license key used and the DevExtreme version referenced in this project.

To proceed, you can:
\u2022 use a version of DevExtreme linked to your license key: https://www.devexpress.com/ClientCenter/DownloadManager
\u2022 renew your DevExpress Subscription: https://www.devexpress.com/buy/renew (once you renew your subscription, you will be entitled to product updates and support service as defined in the DevExtreme End User License Agreement)

If you have licensing-related questions or need help with a renewal, please email clientservices@devexpress.com.

`,W0021:`DevExtreme: License Key Verification Has Failed.

Detailed license/registration related information and instructions: https://js.devexpress.com/Documentation/Licensing/.

To verify your DevExtreme license, make certain to specify a correct key in the GlobalConfig. If you continue to encounter this error, please visit https://www.devexpress.com/ClientCenter/DownloadManager to obtain a valid license key.

If you have a valid license and this problem persists, please submit a support ticket via the DevExpress Support Center. We will be happy to follow-up: https://supportcenter.devexpress.com/ticket/create.

`,W0022:`DevExtreme: Pre-release software. Not suitable for commercial use.

Detailed license/registration related information and instructions: https://js.devexpress.com/Documentation/Licensing/.

Pre-release software may contain deficiencies and as such, should not be considered for use or integrated in any mission critical application.

`,W0023:`DevExtreme: the following 'devextreme' package version does not match versions of other DevExpress products used in this application:

{0}

Interoperability between different versions of the products listed herein cannot be guaranteed.

`});var Y1=function(i,e,t){return function(){let n=this.callBase;this.callBase=i[e];try{return t.apply(this,arguments)}finally{this.callBase=n}}},X1=function(i){let e=function(){};return e.prototype=i.prototype,new e},Q1=function(i){let e=this,t,n,o;if(!i)return e;for(n in i)o=i[n],t=typeof e.prototype[n]=="function"&&typeof o=="function",e.prototype[n]=t?Y1(e.parent.prototype,n,o):o;return e},Z1=function(){let i=this,e,t,n,o=Object.prototype.hasOwnProperty.bind(i);for(!o("_includedCtors")&&!o("_includedPostCtors")&&(i._includedCtors=i._includedCtors.slice(0),i._includedPostCtors=i._includedPostCtors.slice(0)),n=0;n<arguments.length;n++){e=arguments[n],e.ctor&&i._includedCtors.push(e.ctor),e.postCtor&&i._includedPostCtors.push(e.postCtor);for(t in e)t==="ctor"||t==="postCtor"||t==="default"||(i.prototype[t]=e[t])}return i},J1=function(i){if(!Object.prototype.hasOwnProperty.bind(this)("parent")&&this.parent){let n=Object.getPrototypeOf(this);return n===i||n.subclassOf(i)}else return this.parent===i?!0:!this.parent||!this.parent.subclassOf?!1:this.parent.subclassOf(i)},AE=function(){throw he.Error("E0001")},e$=function(){let i=Object.prototype.hasOwnProperty;return function(e,t){for(let n in e){if(!i.call(e,n))return;t[n]=e[n]}}}(),Ef=function(){};Ef.inherit=function(i){let e=function(){if(!this||Ne(this)||typeof this.constructor!="function")throw he.Error("E0003");let t=this,n=t.ctor,o=t.constructor._includedCtors,s=t.constructor._includedPostCtors,r;for(r=0;r<o.length;r++)o[r].call(t);for(n&&n.apply(t,arguments),r=0;r<s.length;r++)s[r].call(t)};return e.prototype=X1(this),e$(this,e),e.inherit=this.inherit,e.abstract=AE,e.redefine=Q1,e.include=Z1,e.subclassOf=J1,e.parent=this,e._includedCtors=this._includedCtors?this._includedCtors.slice(0):[],e._includedPostCtors=this._includedPostCtors?this._includedPostCtors.slice(0):[],e.prototype.constructor=e,e.redefine(i),e};Ef.abstract=AE;var ce=Ef;function wt(i){let e=ce.inherit(i),t=e,n=new t(i),o={},s=function(r,a){x(r,function(l){A(n[l])?(a||!i[l])&&(i[l]=function(){return n[l].apply(i,arguments)}):(a&&(o[l]=i[l]),i[l]=n[l])})};return s(i,!0),i.inject=function(r){t=t.inherit(r),n=new t,s(r)},i.resetInjection=function(){m(i,o),t=e,n=new e},i}function I(){return I=Object.assign?Object.assign.bind():function(i){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var n in t)({}).hasOwnProperty.call(t,n)&&(i[n]=t[n])}return i},I.apply(null,arguments)}var ME={rtlEnabled:!1,defaultCurrency:"USD",defaultUseCurrencyAccountingStyle:!0,oDataFilterToLower:!0,serverDecimalSeparator:".",decimalSeparator:".",thousandsSeparator:",",forceIsoDateParsing:!0,wrapActionsBeforeExecute:!0,useLegacyStoreResult:!1,useJQuery:void 0,editorStylingMode:void 0,useLegacyVisibleIndex:!1,floatingActionButtonConfig:{icon:"add",closeIcon:"close",label:"",position:{at:"right bottom",my:"right bottom",offset:{x:-16,y:-16}},maxSpeedDialActionCount:5,shading:!1,direction:"auto"},optionsParser:i=>{i.trim().charAt(0)!=="{"&&(i="{"+i+"}");try{return JSON.parse(i)}catch(e){try{return JSON.parse(t$(i))}catch{throw he.Error("E3018",e,i)}}}},t$=i=>i.replace(/'/g,'"').replace(/,\s*([\]}])/g,"$1").replace(/([{,])\s*([^":\s]+)\s*:/g,'$1"$2":'),i$=["decimalSeparator","thousandsSeparator"],RE=function(){if(!arguments.length)return ME;let i=arguments.length<=0?void 0:arguments[0];i$.forEach(e=>{if(i[e]){let t=`Now, the ${e} is selected based on the specified locale.`;he.log("W0003","config",e,"19.2",t)}}),m(ME,i)};typeof DevExpress<"u"&&DevExpress.config&&RE(DevExpress.config);var fe=RE;var n$=ce.inherit({ctor:function(i){i&&(i=String(i)),this._value=this._normalize(i||this._generate())},_normalize:function(i){for(i=i.replace(/[^a-f0-9]/gi,"").toLowerCase();i.length<32;)i+="0";return[i.substr(0,8),i.substr(8,4),i.substr(12,4),i.substr(16,4),i.substr(20,12)].join("-")},_generate:function(){let i="";for(let e=0;e<32;e++)i+=Math.round(15*Math.random()).toString(16);return i},toString:function(){return this._value},valueOf:function(){return this._value},toJSON:function(){return this._value}}),Oe=n$;var us=function(i){this._options=i||{},this._list=[],this._queue=[],this._firing=!1,this._fired=!1,this._firingIndexes=[]};us.prototype._fireCore=function(i,e){let t=this._firingIndexes,n=this._list,o=this._options.stopOnFalse,s=t.length;for(t[s]=0;t[s]<n.length&&!(n[t[s]].apply(i,e)===!1&&o);t[s]++);t.pop()};us.prototype.add=function(i){return typeof i=="function"&&(!this._options.unique||!this.has(i))&&this._list.push(i),this};us.prototype.remove=function(i){let e=this._list,t=this._firingIndexes,n=e.indexOf(i);if(n>-1&&(e.splice(n,1),this._firing&&t.length))for(let o=0;o<t.length;o++)n<=t[o]&&t[o]--;return this};us.prototype.has=function(i){let e=this._list;return i?e.indexOf(i)>-1:!!e.length};us.prototype.empty=function(i){return this._list=[],this};us.prototype.fireWith=function(i,e){let t=this._queue;if(e=e||[],e=e.slice?e.slice():e,this._options.syncStrategy)this._firing=!0,this._fireCore(i,e);else{if(t.push([i,e]),this._firing)return;for(this._firing=!0;t.length;){let n=t.shift();this._fireCore(n[0],n[1])}}return this._firing=!1,this._fired=!0,this};us.prototype.fire=function(){this.fireWith(this,arguments)};us.prototype.fired=function(){return this._fired};var o$=function(i){return new us(i)},ue=o$;var FE=[{method:"resolve",handler:"done",state:"resolved"},{method:"reject",handler:"fail",state:"rejected"},{method:"notify",handler:"progress"}],Wa=function(){let i=this;this._state="pending",this._promise={},FE.forEach(function(e){let t=e.method;this[t+"Callbacks"]=ue(),this[t]=function(){return this[t+"With"](this._promise,arguments)}.bind(this),this._promise[e.handler]=function(n){if(!n)return this;let o=i[t+"Callbacks"];return o.fired()?n.apply(i[t+"Context"],i[t+"Args"]):o.add(function(s,r){n.apply(s,r)}.bind(this)),this}}.bind(this)),this._promise.always=function(e){return this.done(e).fail(e)},this._promise.catch=function(e){return this.then(null,e)},this._promise.then=function(e,t){let n=new Wa;return["done","fail"].forEach(function(o){let s=o==="done"?e:t;this[o](function(){if(!s){n[o==="done"?"resolve":"reject"].apply(this,arguments);return}let r=s&&s.apply(this,arguments);Ha(r)?r.done(n.resolve).fail(n.reject):To(r)?r.then(n.resolve,n.reject):n.resolve.apply(this,f(r)?[r]:arguments)})}.bind(this)),n.promise()},this._promise.state=function(){return i._state},this._promise.promise=function(e){return e?m(e,i._promise):i._promise},this._promise.promise(this)};FE.forEach(function(i){let e=i.method,t=i.state;Wa.prototype[e+"With"]=function(n,o){let s=this[e+"Callbacks"];return this.state()==="pending"&&(this[e+"Args"]=o,this[e+"Context"]=n,t&&(this._state=t),s.fire(n,o),t!=="pending"&&(this.resolveCallbacks.empty(),this.rejectCallbacks.empty())),this}});function ht(i,e){if(Ha(i))return i;if(To(i)){let t=new Wa;return i.then(function(){t.resolveWith.apply(t,[e].concat([[].slice.call(arguments)]))},function(){t.rejectWith.apply(t,[e].concat([[].slice.call(arguments)]))}),t}return new Wa().resolveWith(e,[i])}var s$=function(){if(arguments.length===1)return ht(arguments[0]);let i=[].slice.call(arguments),e=[],t=0,n=new Wa,o=function(s){return function(r){e[s]=this,i[s]=arguments.length>1?[].slice.call(arguments):r,t++,t===i.length&&n.resolveWith(e,i)}};for(let s=0;s<i.length;s++)Ha(i[s])?i[s].promise().done(o(s)).fail(n.reject):t++;return t===i.length&&n.resolveWith(e,i),n.promise()};function y(){return new Wa}function P(){return s$.apply(this,arguments)}var It=wt({isWrapped:function(){return!1},isWritableWrapped:function(){return!1},wrap:function(i){return i},unwrap:function(i){return i},assign:function(){Js.error("Method 'assign' should not be used for not wrapped variables. Use 'isWrapped' method for ensuring.")}});var Fd=function(i,e){let t=[],n,o;for(n in i)Object.prototype.hasOwnProperty.call(i,n)&&t.push(n);for(t.sort(function(s,r){let a=xe(s),l=xe(r);return a&&l?s-r:a&&!l?-1:!a&&l?1:s<r?-1:s>r?1:0}),o=0;o<t.length;o++)n=t[o],e(n,i[n])},r$=function(i,e,t,n){!n&&It.isWrapped(i[e])?It.assign(i[e],t):i[e]=t},Bi=function(i,e,t,n){let o,s;for(let r in e)if(o=i[r],s=e[r],!(r==="__proto__"||r==="constructor"||i===s)){if(q(s)){let a=t?$(o):q(o);s=Bi(a?o:{},s,t,n)}s!==void 0&&o!==s&&r$(i,r,s,n)}return i};var a$=It.unwrap,kE=It.isWrapped,l$=It.assign,d$=function(i){return i.replace(/\[/g,".").replace(/\]/g,"")},Fn=function(i){return d$(i).split(".")},c$=function(i,e,t){return t=t||{},Pd(e==="this"?i:i[e],t)},BE=function(i,e,t,n){if(e==="this")throw new he.Error("E4016");let o=i[e];n.unwrapObservables&&kE(o)?l$(o,t):i[e]=t},VE=function(i){return i=i||{},i.unwrapObservables=i.unwrapObservables!==void 0?i.unwrapObservables:!0,i};function Pd(i,e){return e.unwrapObservables?a$(i):i}var me=function(i){if(arguments.length>1&&(i=[].slice.call(arguments)),!i||i==="this")return function(e){return e};if(typeof i=="string"){let e=Fn(i);return function(t,n){n=VE(n);let o=n.functionsAsIs,s="defaultValue"in n,r=Pd(t,n);for(let a=0;a<e.length;a++){if(!r){if(r==null&&s)return n.defaultValue;break}let l=e[a];if(s&&$(r)&&!(l in r))return n.defaultValue;let d=Pd(r[l],n);!o&&A(d)&&(d=d.call(r)),r=d}return r}}if(Array.isArray(i))return u$(i);if(A(i))return i};function u$(i){let e={};for(let t=0,n=i.length;t<n;t++){let o=i[t];e[o]=me(o)}return function(t,n){let o;return x(e,function(s){let r=this(t,n);if(r===void 0)return;let a=o||(o={}),l=s.split("."),d=l.length-1;for(let c=0;c<d;c++){let h=l[c];h in a||(a[h]={}),a=a[h]}a[l[d]]=r}),o}}function h$(i,e){return e!=null&&e.locale?i.toLocaleLowerCase(e.locale):i.toLowerCase()}function p$(i,e){return e!=null&&e.locale?i.toLocaleUpperCase(e.locale):i.toUpperCase()}var PE=function(i,e,t,n){if(f(t))return t;let o={};return BE(i,e,o,n),o},Ga=function(i){i=Fn(i||"this");let e=i.length-1;return function(t,n,o){o=VE(o);let s=Pd(t,o);i.forEach(function(r,a){let l=c$(s,r,o),d=!o.functionsAsIs&&A(l)&&!kE(l);a===e?o.merge&&q(n)&&(!f(l)||q(l))?(l=PE(s,r,l,o),Bi(l,n,!1,!0)):d?s[r](n):BE(s,r,n,o):(l=PE(s,r,l,o),d&&(l=l.call(s)),s=l)})}},Ot=function(i,e){var t;let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(i instanceof Date)return i.getTime();if(i&&i instanceof ce&&i.valueOf)return i.valueOf();if(!((n==null||(t=n.collatorOptions)===null||t===void 0?void 0:t.sensitivity)==="case"||e)&&typeof i=="string"){var s,r;if((n==null||(s=n.collatorOptions)===null||s===void 0?void 0:s.sensitivity)==="base"){let d=/[\u0300-\u036f]/g;i=i.normalize("NFD").replace(d,"")}let a=n==null||(r=n.locale)===null||r===void 0?void 0:r.toLowerCase();return(a&&!!["hy","el"].find(d=>a===d||a.startsWith(`${d}-`))?p$:h$)(i,n)}return i};var Te=function(i,e){return f(i)?i:e},Ua=function(i,e){let t=new y,n=e||this,o={promise:t.promise(),abort:function(){clearTimeout(s),t.rejectWith(n)}},s=(arguments[2]||setTimeout)(function(){let r=i.call(n);r&&r.done&&A(r.done)?r.done(function(){t.resolveWith(n)}):t.resolveWith(n)},typeof e=="number"?e:0);return o},wf=[],LE=[],kd=[],Ka,Ju=function(i,e,t){if(Ka&&Ka!==i)return wf.push(e),LE.push(i),t=t||new y,kd.push(t),t;{let n=Ka,o=kd.length;Ka=i;let s=e();return s||(kd.length>o?s=P.apply(this,kd.slice(o)):t&&t.resolve()),Ka=n,t&&s&&s.done&&s.done(t.resolve).fail(t.reject),!Ka&&wf.length&&(LE.shift()==="render"?nt:Jt)(wf.shift(),kd.shift()),s||P()}},nt=function(i,e){return Ju("render",i,e)},Jt=function(i,e){return Ju("update",i,e)},Ao=function(i){return function(){let e=this;return Ju("render",function(){return i.call(e)})}},If=function(i){return function(){let e=this;return Ju("update",function(){return i.call(e)})}},eh=function(i,e,t){let n=[],o=0;return x(e,(s,r)=>{let a=0,l=t?t(r):r;x(i,(d,c)=>{let h=l[d];if(h!==void 0){if(g$(h,c)){a++;return}return a=-1,!1}}),!(a<o)&&(a>o&&(n.length=0,o=a),n.push(r))}),n},g$=function(i,e){if(Array.isArray(i)&&Array.isArray(e)){let t=!1;return x(i,(n,o)=>{if(o!==e[n])return t=!0,!1}),!t}return i===e},Mo=function(i){switch(ri(i)){case"string":return i.split(/\s+/,2);case"object":return[i.x??i.h,i.y??i.v];case"number":return[i];case"array":return i;default:return null}};var ja=function(i,e){let t=Mo(i),n=e?parseFloat(t&&t[0]):parseInt(t&&t[0],10),o=e?parseFloat(t&&t[1]):parseInt(t&&t[1],10);return isFinite(n)||(n=0),isFinite(o)||(o=n),{h:n,v:o}},ai=function(i){if(i instanceof Oe)return i.toString();if($(i)||Array.isArray(i))try{let e=JSON.stringify(i);return e==="{}"?i:e}catch{return i}return i},Pn=function(i){return i.replace(/[[\]{}\-()*+?.\\^$|\s]/g,"\\$&")},HE=function(i){let e=fe().serverDecimalSeparator;return f(i)&&(i=i.toString().replace(".",e)),i},S=function(){},th=function(){return new y().resolve().promise()},xt=function(i,e,t){let n=[],o,s=!t;for(let r=0;r<i.length;r++)o=!!e(i[r],r),o===s&&n.push(i[r]);return n},m$=(i,e,t,n)=>i.length!==e.length?!1:!i.some((o,s)=>!Df(o,e[s],t+1,I({},n,{strict:!0}))),f$=(i,e,t,n)=>{let o=Object.keys(i),s=Object.keys(e);if(o.length!==s.length)return!1;let r=new Set(s);return!o.some(a=>!r.has(a)||!Df(i[a],e[a],t+1,n))},NE={maxDepth:3,strict:!0},Df=(i,e,t,n)=>{let{strict:o,maxDepth:s}=n,r=Ot(i,!0),a=Ot(e,!0),l=o?r===a:r==a;switch(!0){case l:case t>=s:return!0;case($(r)&&$(a)):return f$(r,a,t,n);case(Array.isArray(r)&&Array.isArray(a)):return m$(r,a,t,n);default:return!1}},ve=function(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:NE,n=I({},NE,t);return Df(i,e,0,n)};var Tf="dx-",ih=null;function $E(i){try{return new CSSStyleSheet}catch{let t=i.ownerDocument.createElement("style");return i.appendChild(t),t.sheet}}function zE(i,e,t){for(let n=0;n<e.length;n++){let o=e[n];try{for(let s=0;s<o.cssRules.length;s++)_$(i,o.cssRules[s],t)}catch{}}}function _$(i,e,t){var n,o,s,r;(t||((n=e.selectorText)===null||n===void 0?void 0:n.includes(Tf))||((o=e.cssRules)===null||o===void 0||(o=o[0])===null||o===void 0||(o=o.selectorText)===null||o===void 0?void 0:o.includes(Tf))||((s=e.name)===null||s===void 0?void 0:s.startsWith(Tf))||((r=e.style)===null||r===void 0?void 0:r.fontFamily)==="DXIcons")&&i.insertRule(e.cssText,i.cssRules.length)}function WE(i){var e;let t=i.get(0),n=(e=t.getRootNode)===null||e===void 0?void 0:e.call(t);if(!(n!=null&&n.host))return;ih||(ih=$E(n),zE(ih,t.ownerDocument.styleSheets,!1));let o=$E(n);zE(o,n.styleSheets,!0),n.adoptedStyleSheets=[ih,o]}function C$(i,e,t){var n;let o=(n=i.getBoundingClientRect)===null||n===void 0?void 0:n.call(i);return o&&e>=o.left&&e<o.right&&t>=o.top&&t<o.bottom}function x$(){let i=0,e=[];return{push(t){return e.push(t),this},shift(){return i++,e[i-1]},get length(){return e.length-i},get items(){return e}}}function GE(i,e,t){let n=x$().push(t);for(;n.length;){let s=n.shift();for(let r=0;r<s.childNodes.length;r++){let a=s.childNodes[r];a.nodeType===Node.ELEMENT_NODE&&C$(a,i,e)&&getComputedStyle(a).pointerEvents!=="none"&&n.push(a)}}let o=n.items.reverse();return o.pop(),o}var v$={querySelectorAll:(i,e)=>i.querySelectorAll(e),elementMatches(i,e){return(i.matches||i.matchesSelector||i.mozMatchesSelector||i.msMatchesSelector||i.oMatchesSelector||i.webkitMatchesSelector||(n=>{let o=i.document||i.ownerDocument;if(!o)return!1;let s=this.querySelectorAll(o,n);for(let r=0;r<s.length;r++)if(s[r]===i)return!0})).call(i,e)},createElement(i,e){return e=e||this._document,e.createElement(i)},createElementNS(i,e,t){return t=t||this._document,t.createElementNS(i,e)},createTextNode(i,e){return e=e||this._document,e.createTextNode(i)},createAttribute(i,e){return e=e||this._document,e.createAttribute(i)},isNode:i=>i&&typeof i=="object"&&"nodeType"in i&&"nodeName"in i,isElementNode:i=>i&&i.nodeType===1,isTextNode:i=>i&&i.nodeType===3,isDocument:i=>i&&i.nodeType===9,isDocumentFragment:i=>i&&i.nodeType===11,removeElement(i){let e=i&&i.parentNode;e&&e.removeChild(i)},insertElement(i,e,t){i&&e&&i!==e&&(t?i.insertBefore(e,t):i.appendChild(e))},getAttribute:(i,e)=>i.getAttribute(e),setAttribute(i,e,t){e==="style"?i.style.cssText=t:i.setAttribute(e,t)},removeAttribute(i,e){i.removeAttribute(e)},setProperty(i,e,t){i[e]=t},setText(i,e){i&&(i.textContent=e)},setClass(i,e,t){i.nodeType===1&&e&&(t?i.classList.add(e):i.classList.remove(e))},setStyle(i,e,t){i.style[e]=t||""},_document:typeof document>"u"?void 0:document,getDocument(){return this._document},getActiveElement(i){return this.getRootNode(i).activeElement},getRootNode(i){var e;return(i==null||(e=i.getRootNode)===null||e===void 0?void 0:e.call(i))??this._document},getBody(){return this._document.body},createDocumentFragment(){return this._document.createDocumentFragment()},getDocumentElement(){return this._document.documentElement},getLocation(){return this._document.location},getSelection(){return this._document.selection},getReadyState(){return this._document.readyState},getHead(){return this._document.head},hasDocumentProperty(i){return i in this._document},listen(i,e,t,n){return!i||!("addEventListener"in i)?S:(i.addEventListener(e,t,n),()=>{i.removeEventListener(e,t)})},elementsFromPoint(i,e,t){let n=this.getRootNode(t);return n.host?GE(i,e,n):n.elementsFromPoint(i,e)}},w=wt(v$);var er=class{constructor(){this.memory=[],this.callbacks=ue()}add(e){x(this.memory,(t,n)=>e.apply(e,n)),this.callbacks.add(e)}remove(e){this.callbacks.remove(e)}fire(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.memory.push(t),this.callbacks.fire.apply(this.callbacks,t)}};var Bd=new er;var qa=i=>{var e,t;let n=i.originalEvent;if(!n)return i.target;if(!!!(!((e=n.target)===null||e===void 0)&&e.shadowRoot))return n.target;let s=n.path??((t=n.composedPath)===null||t===void 0?void 0:t.call(n));return s?.[0]??i.target};var b$=typeof window<"u",W=()=>b$,Kr=W()?window:void 0;Kr||(Kr={},Kr.window=Kr);var K=()=>Kr;var Af=i=>W()&&i in Kr,Vd=i=>i<768?"xs":i<992?"sm":i<1200?"md":"lg",nh=i=>{let e=i||Vd,t=w.getDocumentElement().clientWidth;return e(t)},hs=()=>W()?Kr.navigator:{userAgent:""};var y$=["pageX","pageY","screenX","screenY","clientX","clientY"],O$=function(i,e){if(e[i]&&!e.touches||!e.touches)return e[i];let t=e.touches.length?e.touches:e.changedTouches;if(t.length)return t[0][i]};function KE(i){y$.forEach(function(e){i(e,function(t){return O$(e,t)})},this)}var S$=function(i){let e,t=function(){return e=i.apply(this,arguments),t=function(){return e},e};return function(){return t.apply(this,arguments)}},Ki=S$;var Ff=K(),oh="dxEmptyEventType",UE={mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},E$={focusin:"focus",focusout:"blur"},w$=["blur","focus","load"],XE=["touchmove","wheel","mousewheel","touchstart"],I$=["target","relatedTarget","delegateTarget","altKey","bubbles","cancelable","changedTouches","ctrlKey","detail","eventPhase","metaKey","shiftKey","view","char","code","charCode","key","keyCode","button","buttons","offsetX","offsetY","pointerId","pointerType","targetTouches","toElement","touches"];function D$(i,e){return!Ne(i)&&i.nodeName!=="#document"&&w.elementMatches(i,e)}var Mf=new WeakMap,QE=0,sh,tr=function(){let i={};return Bd.add(function(e,t){i[e]=t}),{getField:function(e,t){return i[e]&&i[e][t]},callMethod:function(e,t,n,o){return i[e]&&i[e][t]&&i[e][t].apply(n,o)}}}(),Dt=wt({on:Ld(Rf(YE(function(i,e,t,n,o){Ya(i,e).addHandler(o,t,n)}))),one:Ld(Rf(function(i,e,t,n,o){let s=function(){Dt.off(i,e,t,s),o.apply(this,arguments)};Dt.on(i,e,t,n,s)})),off:Ld(M$(YE(function(i,e,t,n){Ya(i,e).removeHandler(n,t)}))),trigger:Ld(qE(function(i,e,t){let n=e.type,o=Ya(i,e.type);if(tr.callMethod(n,"trigger",i,[e,t]),o.callHandlers(e,t),!(tr.getField(n,"noBubble")||e.isPropagationStopped()||w$.indexOf(n)!==-1)){let r=[],a=function(d){let c=d.parentNode??($(d.host)?d.host:null);c&&(r.push(c),a(c))};a(i),r.push(Ff);let l=0;for(;r[l]&&!e.isPropagationStopped();)Ya(r[l],e.type).callHandlers(m(e,{currentTarget:r[l]}),t),l++}(i.nodeType||Ne(i))&&(tr.callMethod(n,"_default",i,[e,t]),F$(n,i))})),triggerHandler:Ld(qE(function(i,e,t){Ya(i,e.type).callHandlers(e,t)}))});function Pf(i,e){let t=i[0];if(t)if(w.isNode(t)||Ne(t))e.apply(Dt,i);else if(!B(t)&&"length"in t){let n=Array.prototype.slice.call(i,0);Array.prototype.forEach.call(t,function(o){n[0]=o,Pf(n,e)})}else throw he.Error("E0025")}function Ld(i){return function(){Pf(arguments,i)}}function T$(){let i=!1;try{let e=Object.defineProperty({},"passive",{get:function(){return i=!0,!0}});Ff.addEventListener("test",null,e)}catch{}return i}var ZE=Ki(T$),JE=(i,e)=>Ne(i)?JE(i.document,e):i.contains?i.contains(e):!!(e.compareDocumentPosition(i)&e.DOCUMENT_POSITION_CONTAINS);function Ya(i,e){let t=Mf.get(i);e=e||"";let n=e.split("."),o=n.slice(1),s=!!n[0];e=n[0]||oh,t||(t={},Mf.set(i,t)),t[e]||(t[e]={handleObjects:[],nativeHandler:null});let r=t[e];return{addHandler:function(a,l,d){let c=function(v,b){let T=[v],R=v.currentTarget,U=v.relatedTarget,Q,se;e in UE&&(Q=U&&R&&(U===R||JE(R,U))),b!==void 0&&T.push(b),tr.callMethod(e,"handle",i,[v,d]),Q||(se=a.apply(R,T)),se===!1&&(v.preventDefault(),v.stopPropagation())},h={handler:a,wrappedHandler:function(v,b){if(!(sh&&v.type===sh))if(v.data=d,v.delegateTarget=i,l){let R=v.target;for(;R&&R!==i;)D$(R,l)&&(v.currentTarget=R,c(v,b)),R=R.parentNode}else{var T;if(v.currentTarget=v.delegateTarget||v.target,!!(!((T=v.target)===null||T===void 0)&&T.shadowRoot)){let U=qa(v);v.target=U}c(v,b)}},selector:l,type:e,data:d,namespace:o.join("."),namespaces:o,guid:++QE};r.handleObjects.push(h);let g=r.handleObjects.length===1&&s,C;g&&(g=!tr.callMethod(e,"setup",i,[d,o,a])),g&&(r.nativeHandler=A$(e),ZE()&&XE.indexOf(e)>-1&&(C={passive:!1}),r.removeListener=w.listen(i,UE[e]||e,r.nativeHandler,C)),tr.callMethod(e,"add",i,[h])},removeHandler:function(a,l){let d=function(h){let p=t[h];if(!p.handleObjects.length){delete t[h];return}let g;p.handleObjects=p.handleObjects.filter(function(b){let T=o.length&&!jE(b.namespaces,o)||a&&b.handler!==a||l&&b.selector!==l;return T||(g=b.handler,tr.callMethod(h,"remove",i,[b])),T}),!p.handleObjects.length&&h!==oh&&(tr.callMethod(h,"teardown",i,[o,g]),p.nativeHandler&&p.removeListener(),delete t[h])};if(s)d(e);else for(let h in t)d(h);Object.keys(t).length===0&&Mf.delete(i)},callHandlers:function(a,l){let d=!1,c=function(h){d||(!o.length||jE(h.namespaces,o))&&(h.wrappedHandler(a,l),d=a.isImmediatePropagationStopped())};r.handleObjects.forEach(c),o.length&&t[oh]&&t[oh].handleObjects.forEach(c)}}}function A$(i){return function(e,t){let n=Ya(this,i);e=Dt.Event(e),n.callHandlers(e,t)}}function jE(i,e){for(let t=0;t<e.length;t++)if(i.indexOf(e[t])<0)return!1;return!0}function Rf(i){return function(e,t,n,o,s){s||(s=o,o=void 0),typeof n!="string"&&(o=n,n=void 0),!s&&typeof t=="string"&&(s=o||n,n=void 0,o=void 0),i(e,t,n,o,s)}}function M$(i){return function(e,t,n,o){typeof n=="function"&&(o=n,n=void 0),i(e,t,n,o)}}function qE(i){return function(e,t,n){typeof t=="string"&&(t={type:t}),t.target||(t.target=e),t.currentTarget=e,t.delegateTarget||(t.delegateTarget=e),!t.type&&t.originalEvent&&(t.type=t.originalEvent.type),i(e,t instanceof Dt.Event?t:Dt.Event(t),n)}}function R$(i){return Dt.Event=function(e,t){if(!(this instanceof Dt.Event))return new Dt.Event(e,t);e||(e={}),typeof e=="string"&&(e={type:e}),t||(t={}),i.call(this,e,t)},Object.assign(Dt.Event.prototype,{_propagationStopped:!1,_immediatePropagationStopped:!1,_defaultPrevented:!1,isPropagationStopped:function(){return!!(this._propagationStopped||this.originalEvent&&this.originalEvent.propagationStopped)},stopPropagation:function(){this._propagationStopped=!0,this.originalEvent&&this.originalEvent.stopPropagation()},isImmediatePropagationStopped:function(){return this._immediatePropagationStopped},stopImmediatePropagation:function(){this.stopPropagation(),this._immediatePropagationStopped=!0,this.originalEvent&&this.originalEvent.stopImmediatePropagation()},isDefaultPrevented:function(){return!!(this._defaultPrevented||this.originalEvent&&this.originalEvent.defaultPrevented)},preventDefault:function(){this._defaultPrevented=!0,this.originalEvent&&this.originalEvent.preventDefault()}}),Dt.Event}function YE(i){let e=function(t,n){if(n&&n.indexOf(" ")>-1){let o=Array.prototype.slice.call(arguments,0);n.split(" ").forEach(function(s){o[1]=s,i.apply(this,o)})}else i.apply(this,arguments)};return function(t,n){if(typeof n=="object"){let o=Array.prototype.slice.call(arguments,0);for(let s in n)o[1]=s,o[o.length-1]=n[s],e.apply(this,o)}else e.apply(this,arguments)}}function F$(i,e){let t=E$[i]||i;(function(n,o){return n==="click"&&o.localName==="a"})(i,e)||A(e[t])&&(sh=i,e[t](),sh=void 0)}function P$(i){return function(e){return e.which==null&&e.type.indexOf("key")===0}(i)?i.charCode!=null?i.charCode:i.keyCode:function(e){return!e.which&&e.button!==void 0&&/^(?:mouse|pointer|contextmenu|drag|drop)|click/.test(e.type)}(i)?{1:1,2:3,3:1,4:2}[i.button]:i.which}function ew(i){i&&(Dt.Event=i,Dt.Event.prototype=i.prototype)}ew(R$(function(i,e){var t;i instanceof Dt.Event||W()&&i instanceof Ff.Event||((t=i.view)===null||t===void 0?void 0:t.Event)&&i instanceof i.view.Event?(this.originalEvent=i,this.type=i.type,this.currentTarget=void 0,Object.prototype.hasOwnProperty.call(i,"isTrusted")&&(this.isTrusted=i.isTrusted),this.timeStamp=i.timeStamp||Date.now()):Object.assign(this,i),kf("which",P$,this),i.type.indexOf("touch")===0&&(delete e.pageX,delete e.pageY),Object.assign(this,e),this.guid=++QE}));function kf(i,e,t){Object.defineProperty(t||Dt.Event.prototype,i,{enumerable:!0,configurable:!0,get:function(){return this.originalEvent&&e(this.originalEvent)},set:function(n){Object.defineProperty(this,i,{enumerable:!0,configurable:!0,writable:!0,value:n})}})}I$.forEach(i=>kf(i,e=>e[i]));KE(kf);var tw=ue(),iw=ue();Dt.set=function(i){tw.fire(),Dt.inject(i),ew(i.Event),iw.fire()};Dt.subscribeGlobal=function(){Pf(arguments,Rf(function(){let i=arguments;Dt.on.apply(this,i),tw.add(function(){let e=Array.prototype.slice.call(i,0);e.splice(3,1),Dt.off.apply(this,e)}),iw.add(function(){Dt.on.apply(this,i)})}))};Dt.forcePassiveFalseEventNames=XE;Dt.passiveEventHandlersSupported=ZE;var _=Dt;var Qee=_.on,nw=_.one,Zee=_.off,Jee=_.trigger,Bf=_.triggerHandler,ete=_.Event;var Nd=new WeakMap,Ur,k$=new er,ow=function(){},B$=function(){},V$=function(i){k$.fire(i),Ur=i;let e=Ur.cleanData;Ur.cleanData=function(t){ow(t);let n=e.call(this,t);return B$(t),n}};V$({data:function(){let i=arguments[0],e=arguments[1],t=arguments[2];if(!i)return;let n=Nd.get(i);return n||(n={},Nd.set(i,n)),e===void 0?n:arguments.length===2?n[e]:(n[e]=t,t)},removeData:function(i,e){if(i)if(e===void 0)Nd.delete(i);else{let t=Nd.get(i);t&&delete t[e]}},cleanData:function(i){for(let e=0;e<i.length;e++)_.off(i[e]),Nd.delete(i[e])}});function $e(){return Ur.data.apply(this,arguments)}function sw(i){ow=i}function ir(i,e){return Ur.removeData.call(this,i,e)}function nr(i,e){if(!w.isElementNode(i))return;let t=i.getElementsByTagName("*");Ur.cleanData(t),e&&Ur.cleanData([i])}var rw=function(i){return i==null?"":String(i)},Vf=function(i){return rw(i).charAt(0).toUpperCase()+i.substr(1)},Lf=function(i){return rw(i).replace(/([a-z\d])([A-Z])/g,"$1 $2").split(/[\s_-]+/)},Hd=function(i){return He(Lf(i),function(e){return e.toLowerCase()}).join("-")};var Ci=function(i,e){return He(Lf(i),function(t,n){return t=t.toLowerCase(),(e||n>0)&&(t=Vf(t)),t}).join("")},aw=function(i){return Vf(Hd(i).replace(/-/g," "))},or=function(i){return He(Lf(i),function(e){return Vf(e.toLowerCase())}).join(" ")},L$=["0","1","2","3","4","5","6","7","8","9"],kn=function(i){let e=[],t,n,o=!1,s=!1;for(t=0;t<i.length;t++)n=i.charAt(t),s=n===n.toUpperCase()&&n!=="-"&&n!==")"&&n!=="/"||n in L$,n==="_"||n==="."?(n=" ",s=!0):t===0?(n=n.toUpperCase(),s=!0):!o&&s&&e.length>0&&e.push(" "),e.push(n),o=s;return e.join("")};var rh=["","Webkit","Moz","O","Ms"],N$={"":"",Webkit:"-webkit-",Moz:"-moz-",O:"-o-",ms:"-ms-"},Nf=Ki(function(){return w.createElement("dx").style}),H$=function(i,e){i=Ci(i,!0);let t;for(let n=0,o=rh.length;n<o;n++){let s=rh[n],r=s+i,a=Ci(r);if(t=e(a,s),t===void 0&&(t=e(r,s)),t!==void 0)break}return t||""},lo=function(i){if(i in Nf())return i;let e=i;i=i.charAt(0).toUpperCase()+i.substr(1);for(let t=1;t<rh.length;t++){let n=rh[t].toLowerCase()+i;if(n in Nf())return n}return e},Xa=function(i){return H$(i,function(e,t){if(e in Nf())return N$[t]})},$$=["fillOpacity","columnCount","flexGrow","flexShrink","fontWeight","lineHeight","opacity","zIndex","zoom"];var ps=function(i,e){return xe(e)&&$$.indexOf(i)===-1&&(e+="px"),e},lw=function(i,e,t){if(i){t=xe(t)?t+="px":t;for(let n=0;n<i.length;++n)i[n].style[e]=t}},$d=function(i,e){lw(i,"width",e)},ah=function(i,e){lw(i,"height",e)},lh=function(i,e){(arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0)&&[].slice.call(i.style).forEach(o=>{i.style.removeProperty(o)}),e.split(";").forEach(n=>{let o=n.split(":").map(s=>s.trim());if(o.length===2){let[s,r]=o;i.style[s]=r}})};var dh=K(),z$=["auto","none","inherit","initial"],Hf=function(i,e){let t=0;return e.forEach(function(n){t+=parseFloat(i[n])||0}),t},ch=function(i,e){let t=i==="width"?"Left":"Top",n=i==="width"?"Right":"Bottom";return{padding:Hf(e,["padding"+t,"padding"+n]),border:Hf(e,["border"+t+"Width","border"+n+"Width"]),margin:Hf(e,["margin"+t,"margin"+n])}},cw=function(i){var e;let t=(i==null||(e=i.ownerDocument)===null||e===void 0?void 0:e.defaultView)||dh;return t.getComputedStyle&&t.getComputedStyle(i)},$f=function(i,e,t,n){var o;return e?.[t]||((o=i.style)===null||o===void 0?void 0:o[t])||n},Qa={content:0,padding:1,border:2,margin:3,"content-box":0,"border-box":2},dw={width:["left","right"],height:["top","bottom"]};function zd(i,e,t,n){let o=(r,a,l)=>parseFloat($f(r,a,l,"0"))||0,s=t==="border"?"-width":"";return o(i,n,`${t}-${dw[e][0]}${s}`)+o(i,n,`${t}-${dw[e][1]}${s}`)}var W$=function(i,e,t){let n=e==="width"?"offsetWidth":"offsetHeight",o=cw(i),s=$f(i,o,e);(s===""||s==="auto")&&(s=i[n]),s=parseFloat(s)||0;let r=$f(i,o,"boxSizing","content-box"),l=Qa[t||r],d=Qa[r];if(l===void 0||d===void 0)throw new Error;if(d===l)return s;let c=Math.sign(l-d),h=!1,p=!1,g=!1,C=!1;c===1&&(l+=1,d+=1);for(let v=d;v!==l;v+=c)switch(v){case Qa.content:break;case Qa.padding:h=c*zd(i,e,"padding",o);break;case Qa.border:p=c*zd(i,e,"border",o);break;case Qa.margin:g=c*zd(i,e,"margin",o)}if(h||p){let v=(h===!1?c*zd(i,e,"padding",o):h)+(p===!1?c*zd(i,e,"border",o):p);C=c*Math.max(0,Math.floor(i[n]-s-c*v))||0}return s+g+h+p+C},G$=function(i){return Ne(i)?i.innerHeight:i.offsetHeight},Wf=function(i,e,t){return i.indexOf("px")>0?i=parseInt(i.replace("px","")):i.indexOf("%")>0?i=parseInt(i.replace("%",""))*G$(e)/100:isNaN(i)?i.indexOf("vh")>0?i=dh.innerHeight/100*parseInt(i.replace("vh","")):t&&i.indexOf("em")>0&&(i=parseFloat(i.replace("em",""))*parseFloat(dh.getComputedStyle(t).fontSize)):i=parseInt(i),i},uw=function(i,e,t){if(!i)return null;if(z$.indexOf(i)>-1)return e?null:i;if(B(i)&&(i=Wf(i,t)),xe(i))return Math.max(0,i+e);let n=e<0?" - ":" ";return"calc("+i+n+Math.abs(e)+"px)"},hw=function(i,e,t){let n=uw(i,e,t);return n!==null?n:"none"},pw=function(i,e,t){let n=uw(i,e,t);return n!==null?n:0},sr=function(i,e){if(!i)return 0;let t=ch("height",dh.getComputedStyle(i));return t.padding+t.border+(e?t.margin:0)},Gf=function(i){if(i){var e;let t=(e=i.getBoundingClientRect)===null||e===void 0?void 0:e.call(i);if(t!=null&&t.height)return t.height}return 0},Ro={getWidth:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("width",...e)},setWidth:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("width",...e)},getHeight:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("height",...e)},setHeight:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("height",...e)},getOuterWidth:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("outerWidth",...e)},setOuterWidth:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("outerWidth",...e)},getOuterHeight:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("outerHeight",...e)},setOuterHeight:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("outerHeight",...e)},getInnerWidth:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("innerWidth",...e)},setInnerWidth:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("innerWidth",...e)},getInnerHeight:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("innerHeight",...e)},setInnerHeight:function(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return Bn("innerHeight",...e)}};function Bn(i,e,t){return arguments.length===2?zf(e,i):zf(e,i,t)}var z=i=>Ro.getWidth(i),Fo=(i,e)=>Ro.setWidth(i,e),Y=i=>Ro.getHeight(i),xi=(i,e)=>Ro.setHeight(i,e),ie=(i,e)=>Ro.getOuterWidth(i,e||!1),Wd=(i,e)=>Ro.setOuterWidth(i,e),X=(i,e)=>Ro.getOuterHeight(i,e||!1),Kf=(i,e)=>Ro.setOuterHeight(i,e),Za=i=>Ro.getInnerWidth(i);var jr=i=>Ro.getInnerHeight(i);var zf=function(i,e,t){let n=e.toLowerCase().indexOf("width")>=0?"Width":"Height",o=n.toLowerCase(),s=e.indexOf("outer")===0,r=e.indexOf("inner")===0,a=arguments.length===2||typeof t=="boolean";if($t(i)){if(i.length>1&&!a){for(let l=0;l<i.length;l++)zf(i[l],e,t);return}i=i[0]}if(i){if(Ne(i))return s?i["inner"+n]:w.getDocumentElement()["client"+n];if(w.isDocument(i)){let l=w.getDocumentElement(),d=w.getBody();return Math.max(d["scroll"+n],d["offset"+n],l["scroll"+n],l["offset"+n],l["client"+n])}if(a){let l="content";return s&&(l=t?"margin":"border"),r&&(l="padding"),W$(i,o,l)}if(xe(t)){let l=cw(i),d=ch(o,l),c=l.boxSizing==="border-box";t=Number(t),s?t-=c?0:d.border+d.padding:r?t+=c?d.border:-d.padding:c&&(t+=d.border+d.padding)}return t+=xe(t)?"px":"",w.setStyle(i,o,t),null}},Uf=i=>Ne(i)?i:i.defaultView,Ja=i=>{var e,t;if(!((e=i.getClientRects)!==null&&e!==void 0&&e.call(i).length))return{top:0,left:0};let n=(t=i.getBoundingClientRect)===null||t===void 0?void 0:t.call(i),o=Uf(i.ownerDocument),s=i.ownerDocument.documentElement;return{top:n.top+o.pageYOffset-s.clientTop,left:n.left+o.pageXOffset-s.clientLeft}};var gw=/<([a-z][^/\0>\x20\t\r\n\f]+)/i,Po={default:{tagsCount:0,startTags:"",endTags:""},thead:{tagsCount:1,startTags:"<table>",endTags:"</table>"},td:{tagsCount:3,startTags:"<table><tbody><tr>",endTags:"</tr></tbody></table>"},col:{tagsCount:2,startTags:"<table><colgroup>",endTags:"</colgroup></table>"},tr:{tagsCount:2,startTags:"<table><tbody>",endTags:"</tbody></table>"}};Po.tbody=Po.colgroup=Po.caption=Po.tfoot=Po.thead;Po.th=Po.td;var Gd=function(i){if(typeof i!="string")return null;let t=w.createDocumentFragment().appendChild(w.createElement("div")),n=gw.exec(i),o=n&&n[1].toLowerCase(),s=Po[o]||Po.default;t.innerHTML=s.startTags+i+s.endTags;for(let r=0;r<s.tagsCount;r++)t=t.lastChild;return[...t.childNodes]},mw=function(i){let e=gw.exec(i);return e&&e[1]in Po};var K$=K(),Fe,_e=function(i,e){return i?typeof i=="string"?i==="body"?(this[0]=e?e.body:w.getBody(),this.length=1,this):(e=e||w.getDocument(),i[0]==="<"?(this[0]=w.createElement(i.slice(1,-1),e),this.length=1,this):([].push.apply(this,w.querySelectorAll(e,i)),this)):w.isNode(i)||Ne(i)?(this[0]=i,this.length=1,this):Array.isArray(i)?([].push.apply(this,i),this):Fe(i.toArray?i.toArray():[i]):(this.length=0,this)};Fe=function(i,e){return new _e(i,e)};Fe.fn={dxRenderer:!0};_e.prototype=Fe.fn;var el=function(i,e){for(let t=0;t<this.length;t++){let n=Fe(this[t]);n[i].apply(n,e)}return this},jf=function(i,e,t){t!=null&&t!==!1?w.setAttribute(i,e,t):w.removeAttribute(i,e)};_e.prototype.show=function(){return this.toggle(!0)};_e.prototype.hide=function(){return this.toggle(!1)};_e.prototype.toggle=function(i){return this[0]&&this.toggleClass("dx-state-invisible",!i),this};_e.prototype.attr=function(i,e){if(this.length>1&&arguments.length>1)return el.call(this,"attr",arguments);if(!this[0])return $(i)||e!==void 0?this:void 0;if(!this[0].getAttribute)return this.prop(i,e);if(typeof i=="string"&&arguments.length===1){let t=this[0].getAttribute(i);return t??void 0}else if(q(i))for(let t in i)this.attr(t,i[t]);else jf(this[0],i,e);return this};_e.prototype.removeAttr=function(i){return this.each(function(e,t){w.removeAttribute(t,i)}),this};_e.prototype.prop=function(i,e){if(!this[0])return this;if(typeof i=="string"&&arguments.length===1)return this[0][i];if(q(i))for(let t in i)this.prop(t,i[t]);else w.setProperty(this[0],i,e);return this};_e.prototype.addClass=function(i){return this.toggleClass(i,!0)};_e.prototype.removeClass=function(i){return this.toggleClass(i,!1)};_e.prototype.hasClass=function(i){if(!this[0]||this[0].className===void 0)return!1;let e=i.split(" ");for(let t=0;t<e.length;t++)if(this[0].classList){if(this[0].classList.contains(e[t]))return!0}else if(((B(this[0].className)?this[0].className:w.getAttribute(this[0],"class"))||"").split(" ").indexOf(e[t])>=0)return!0;return!1};_e.prototype.toggleClass=function(i,e){if(this.length>1)return el.call(this,"toggleClass",arguments);if(!this[0]||!i)return this;e=e===void 0?!this.hasClass(i):e;let t=i.split(" ");for(let n=0;n<t.length;n++)w.setClass(this[0],t[n],e);return this};_e.prototype.html=function(i){return arguments.length?(this.empty(),typeof i=="string"&&!mw(i)||typeof i=="number"?(this[0].innerHTML=i,this):this.append(Gd(i))):this[0].innerHTML};var Cw=function(i,e){if(!(!this[0]||!i)){typeof i=="string"?i=Gd(i):i.nodeType?i=[i]:xe(i)&&(i=[w.createTextNode(i)]);for(let t=0;t<i.length;t++){let n=i[t],o=this[0];o.tagName==="TABLE"&&n.tagName==="TR"&&o.tBodies&&o.tBodies.length&&(o=o.tBodies[0]),w.insertElement(o,n.nodeType?n:n[0],e)}}},fw=function(i,e){if(!(!this[0]||!this[0].style)&&!(e===null||typeof e=="number"&&isNaN(e))){i=lo(i);for(let t=0;t<this.length;t++)this[t].style[i]=ps(i,e)}};_e.prototype.css=function(i,e){if(B(i))if(arguments.length===2)fw.call(this,i,e);else{if(!this[0])return;i=lo(i);let t=K$.getComputedStyle(this[0])[i]||this[0].style[i];return xe(t)?t.toString():t}else if(q(i))for(let t in i)fw.call(this,t,i[t]);return this};_e.prototype.prepend=function(i){if(arguments.length>1){for(let e=0;e<arguments.length;e++)this.prepend(arguments[e]);return this}return Cw.apply(this,[i,this[0].firstChild]),this};_e.prototype.append=function(i){if(arguments.length>1){for(let e=0;e<arguments.length;e++)this.append(arguments[e]);return this}return Cw.apply(this,[i]),this};_e.prototype.prependTo=function(i){if(this.length>1){for(let e=this.length-1;e>=0;e--)Fe(this[e]).prependTo(i);return this}return i=Fe(i),i[0]&&w.insertElement(i[0],this[0],i[0].firstChild),this};_e.prototype.appendTo=function(i){return this.length>1?el.call(this,"appendTo",arguments):(w.insertElement(Fe(i)[0],this[0]),this)};_e.prototype.insertBefore=function(i){return i&&i[0]&&w.insertElement(i[0].parentNode,this[0],i[0]),this};_e.prototype.insertAfter=function(i){return i&&i[0]&&w.insertElement(i[0].parentNode,this[0],i[0].nextSibling),this};_e.prototype.before=function(i){return this[0]&&w.insertElement(this[0].parentNode,i[0],this[0]),this};_e.prototype.after=function(i){return this[0]&&w.insertElement(this[0].parentNode,i[0],this[0].nextSibling),this};_e.prototype.wrap=function(i){if(this[0]){let e=Fe(i);e.insertBefore(this),e.append(this)}return this};_e.prototype.wrapInner=function(i){let e=this.contents();return e.length?e.wrap(i):this.append(i),this};_e.prototype.replaceWith=function(i){if(i&&i[0])return i.is(this)?this:(i.insertBefore(this),this.remove(),i)};_e.prototype.remove=function(){return this.length>1?el.call(this,"remove",arguments):(nr(this[0],!0),w.removeElement(this[0]),this)};_e.prototype.detach=function(){return this.length>1?el.call(this,"detach",arguments):(w.removeElement(this[0]),this)};_e.prototype.empty=function(){return this.length>1?el.call(this,"empty",arguments):(nr(this[0]),w.setText(this[0],""),this)};_e.prototype.clone=function(){let i=[];for(let e=0;e<this.length;e++)i.push(this[e].cloneNode(!0));return Fe(i)};_e.prototype.text=function(i){if(!arguments.length){let t="";for(let n=0;n<this.length;n++)t+=this[n]&&this[n].textContent||"";return t}let e=A(i)?i():i;return nr(this[0],!1),w.setText(this[0],f(e)?e:""),this};_e.prototype.val=function(i){return arguments.length===1?this.prop("value",f(i)?i:""):this.prop("value")};_e.prototype.contents=function(){if(!this[0])return Fe();let i=[];return i.push.apply(i,this[0].childNodes),Fe(i)};_e.prototype.find=function(i){let e=Fe();if(!i)return e;let t=[],n;if(typeof i=="string")for(i=i.trim(),n=0;n<this.length;n++){let o=this[n];if(w.isElementNode(o)){let s=o.getAttribute("id"),r=s||"dx-query-children";s||jf(o,"id",r),r="[id='"+r+"'] ";let a=r+i.replace(/([^\\])(,)/g,"$1, "+r);t.push.apply(t,w.querySelectorAll(o,a)),jf(o,"id",s)}else(w.isDocument(o)||w.isDocumentFragment(o))&&t.push.apply(t,w.querySelectorAll(o,i))}else for(n=0;n<this.length;n++)i=w.isNode(i)?i:i[0],this[n]!==i&&this[n].contains(i)&&t.push(i);return e.add(t)};var _w=function(i,e){var t,n;return e=e.host??e,e.nodeType?!!(e.offsetWidth||e.offsetHeight||(t=(n=e).getClientRects)!==null&&t!==void 0&&t.call(n).length):!0};_e.prototype.filter=function(i){if(!i)return Fe();if(i===":visible")return this.filter(_w);if(i===":hidden")return this.filter(function(t,n){return!_w(0,n)});let e=[];for(let t=0;t<this.length;t++){let n=this[t];if(w.isElementNode(n)&&ri(i)==="string")w.elementMatches(n,i)&&e.push(n);else if(w.isNode(i)||Ne(i))i===n&&e.push(n);else if(A(i))i.call(n,t,n)&&e.push(n);else for(let o=0;o<i.length;o++)i[o]===n&&e.push(n)}return Fe(e)};_e.prototype.not=function(i){let e=[],t=this.filter(i).toArray();for(let n=0;n<this.length;n++)t.indexOf(this[n])===-1&&e.push(this[n]);return Fe(e)};_e.prototype.is=function(i){return!!this.filter(i).length};_e.prototype.children=function(i){let e=[];for(let t=0;t<this.length;t++){let n=this[t]?this[t].childNodes:[];for(let o=0;o<n.length;o++)w.isElementNode(n[o])&&e.push(n[o])}return e=Fe(e),i?e.filter(i):e};_e.prototype.siblings=function(){let i=this[0];if(!i||!i.parentNode)return Fe();let e=[],t=i.parentNode.childNodes||[];for(let n=0;n<t.length;n++){let o=t[n];w.isElementNode(o)&&o!==i&&e.push(o)}return Fe(e)};_e.prototype.each=function(i){for(let e=0;e<this.length&&i.call(this[e],e,this[e])!==!1;e++);};_e.prototype.index=function(i){return i?(i=Fe(i),this.toArray().indexOf(i[0])):this.parent().children().index(this)};_e.prototype.get=function(i){return this[i<0?this.length+i:i]};_e.prototype.eq=function(i){return i=i<0?this.length+i:i,Fe(this[i])};_e.prototype.first=function(){return this.eq(0)};_e.prototype.last=function(){return this.eq(-1)};_e.prototype.select=function(){for(let i=0;i<this.length;i+=1)this[i].select&&this[i].select();return this};_e.prototype.parent=function(i){if(!this[0])return Fe();let e=Fe(this[0].parentNode);return!i||e.is(i)?e:Fe()};_e.prototype.parents=function(i){let e=[],t=this.parent();for(;t&&t[0]&&!w.isDocument(t[0]);)w.isElementNode(t[0])&&(!i||t.is(i))&&e.push(t.get(0)),t=t.parent();return Fe(e)};_e.prototype.closest=function(i){if(this.is(i))return this;let e=this.parent();for(;e&&e.length;){if(e.is(i))return e;e=e.parent()}return Fe()};_e.prototype.next=function(i){if(!this[0])return Fe();let e=Fe(this[0].nextSibling);if(!arguments.length)return e;for(;e&&e.length;){if(e.is(i))return e;e=e.next()}return Fe()};_e.prototype.prev=function(){return this[0]?Fe(this[0].previousSibling):Fe()};_e.prototype.add=function(i){let e=Fe(i),t=this.toArray();for(let n=0;n<e.length;n++){let o=e[n];t.indexOf(o)===-1&&t.push(o)}return Fe(t)};var qf=[];_e.prototype.splice=function(){return Fe(qf.splice.apply(this,arguments))};_e.prototype.slice=function(){return Fe(qf.slice.apply(this,arguments))};_e.prototype.toArray=function(){return qf.slice.call(this)};_e.prototype.offset=function(){if(this[0])return Ja(this[0])};_e.prototype.offsetParent=function(){if(!this[0])return Fe();let i=Fe(this[0].offsetParent);for(;i[0]&&i.css("position")==="static";)i=Fe(i[0].offsetParent);return i=i[0]?i:Fe(w.getDocumentElement()),i};_e.prototype.position=function(){if(!this[0])return;let i,e=parseFloat(this.css("marginTop")),t=parseFloat(this.css("marginLeft"));if(this.css("position")==="fixed")return i=this[0].getBoundingClientRect(),{top:i.top-e,left:i.left-t};i=this.offset();let n=this.offsetParent(),o={top:0,left:0};return n[0].nodeName!=="HTML"&&(o=n.offset()),o={top:o.top+parseFloat(n.css("borderTopWidth")),left:o.left+parseFloat(n.css("borderLeftWidth"))},{top:i.top-o.top-e,left:i.left-o.left-t}};[{name:"scrollLeft",offsetProp:"pageXOffset",scrollWindow:function(i,e){i.scrollTo(e,i.pageYOffset)}},{name:"scrollTop",offsetProp:"pageYOffset",scrollWindow:function(i,e){i.scrollTo(i.pageXOffset,e)}}].forEach(function(i){let e=i.name;_e.prototype[e]=function(t){if(!this[0])return;let n=Uf(this[0]);return t===void 0?n?n[i.offsetProp]:this[0][e]:(n?i.scrollWindow(n,t):this[0][e]=t,this)}});_e.prototype.data=function(i,e){if(this[0])return arguments.length<2?$e.call(Fe,this[0],i):($e.call(Fe,this[0],i,e),this)};_e.prototype.removeData=function(i){return this[0]&&ir(this[0],i),this};var xw=function(){return Fe.apply(this,arguments)};Object.defineProperty(xw,"fn",{enumerable:!0,configurable:!0,get:function(){return Fe.fn},set:function(i){Fe.fn=i}});var vw={set:function(i){Fe=i},get:function(){return xw}};var u=vw.get();var U$=K(),j$={getXhr:function(){return new U$.XMLHttpRequest}},uh=wt(j$);var Yf=[],q$=Ki(()=>{let i=w.listen(w.getDocument(),"DOMContentLoaded",()=>{bw.fire(),i()})}),bw={add:i=>{let e=W();e&&w.getReadyState()!=="loading"?i():(Yf.push(i),e&&q$())},fire:()=>{Yf.forEach(i=>i()),Yf=[]}},zt=wt(bw);var yw=K(),Ow=function(i){let e=w.createElement("script");for(let t in i)e[t]=i[t];return e},Sw=function(i){return w.getHead().appendChild(i)},Ew=function(i){i.parentNode.removeChild(i)},Xf=function(i){let e=Ow({text:i});Sw(e),Ew(e)},ww=function(i){let e=Ow({src:i});return new Promise(function(t,n){let o={load:t,error:n},s=function(r){o[r.type](),Ew(e)};for(let r in o)w.listen(e,r,s);Sw(e)})};function hh(i){return(i.method||"GET").toUpperCase()}var Y$=function(i){let e=[];for(let t in i){let n=i[t];n!==void 0&&(n===null&&(n=""),typeof n=="function"&&(n=n()),e.push(encodeURIComponent(t)+"="+encodeURIComponent(n)))}return e.join("&")},X$=function(i){let e;return i.data&&!i.upload&&hh(i)!=="GET"&&(e="application/x-www-form-urlencoded;charset=utf-8"),i.contentType||e},Q$=function(i){let e=i.dataType||"*",t="text/javascript, application/javascript, application/ecmascript, application/x-ecmascript",n={"*":"*/*",text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript",jsonp:t,script:t};return IE(n,i.accepts,!0),n[e]?n[e]+(e!=="*"?", */*; q=0.01":""):n["*"]},Iw=function(i){let e=i.headers||{};return e["Content-Type"]=e["Content-Type"]||X$(i),e.Accept=e.Accept||Q$(i),!i.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest"),e},Dw=function(i){if(i.dataType==="jsonp"){let e=Math.random().toString().replace(/\D/g,""),t=i.jsonpCallback||"dxCallback"+Date.now()+"_"+e,n=i.jsonp||"callback";return i.data=i.data||{},i.data[n]=t,t}},Tw=function(i,e){let t=i.data,n=typeof t=="string",o=i.url||yw.location.href;return!n&&!i.cache&&(t=t||{},t._=Date.now()),t&&!i.upload&&(n||(t=Y$(t)),hh(i)==="GET"?(t!==""&&(o+=(o.indexOf("?")>-1?"&":"?")+t),t=null):e["Content-Type"]&&e["Content-Type"].indexOf("application/x-www-form-urlencoded")>-1&&(t=t.replace(/%20/g,"+"))),{url:o,parameters:t}},Aw=function(i){if(!W())return!0;let e=!1,t=w.createElement("a"),n=w.createElement("a");t.href=yw.location.href;try{n.href=i,n.href=n.href,e=t.protocol+"//"+t.host!=n.protocol+"//"+n.host}catch{e=!0}return e};var Z$=K(),Kd="success",Qf="error",J$="timeout",ez="nocontent",tz="parsererror",iz=function(i){return 200<=i&&i<300},nz=function(i){return i!==204},oz=function(i){return i.responseType&&i.responseType!=="text"||typeof i.responseText!="string"?i.response:i.responseText},sz=function(i,e,t){let n=oz(e);switch(t){case"jsonp":Xf(n);break;case"script":Xf(n),i.resolve(n,Kd,e);break;case"json":try{i.resolve(JSON.parse(n),Kd,e)}catch(o){i.reject(e,tz,o)}break;default:i.resolve(n,Kd,e)}},rz=function(i,e){return i&&setTimeout(function(){e.customStatus=J$,e.abort()},i)},az=function(i){let e=uh.getXhr(),t=new y,n=t.promise(),o=f(i.async)?i.async:!0,s=i.dataType,r=i.timeout||0,a;i.crossDomain=Aw(i.url);let l=s==="jsonp"||s==="script";i.cache===void 0&&(i.cache=!l);let d=Dw(i),c=Iw(i),h=Tw(i,c),p=h.url,g=h.parameters;if(d&&(Z$[d]=function(C){t.resolve(C,Kd,e)}),i.crossDomain&&l){let C=function(){t.reject(e,Qf)},v=function(){s!=="jsonp"&&t.resolve(null,Kd,e)};return ww(p).then(v,C),n}if(i.crossDomain&&!("withCredentials"in e))return t.reject(e,Qf),n;if(e.open(hh(i),p,o,i.username,i.password),o&&(e.timeout=r,a=rz(r,e)),e.onreadystatechange=function(C){e.readyState===4&&(clearTimeout(a),iz(e.status)?nz(e.status)?sz(t,e,s):t.resolve(null,ez,e):t.reject(e,e.customStatus||Qf))},i.upload&&(e.upload.onprogress=i.upload.onprogress,e.upload.onloadstart=i.upload.onloadstart,e.upload.onabort=i.upload.onabort),i.xhrFields)for(let C in i.xhrFields)e[C]=i.xhrFields[C];i.responseType==="arraybuffer"&&(e.responseType=i.responseType);for(let C in c)Object.prototype.hasOwnProperty.call(c,C)&&f(c[C])&&e.setRequestHeader(C,c[C]);return i.beforeSend&&i.beforeSend(e),e.send(g),n.abort=function(){e.abort()},n},Zf=wt({sendRequest:az});var ee=class{host;setHost(e){this.host=e}setTemplate(e){this.host.setTemplate(e)}};var ph=class{instance;zone;subscriptions={};events={};constructor(e,t){this.instance=e,this.zone=t}hasEvent(e){return this.getEmitter(e).observers.length!==0}fireEvent(e,t){let n=this.getEmitter(e);n.observers.length&&((this.subscriptions[e]||[]).length===n.observers.length?n.next(t&&t[0]):this.zone.run(()=>n.next(t&&t[0])))}on(e,t){if(typeof e=="string"){let n=this.subscriptions[e]||[],o=this.getEmitter(e).subscribe(t?.bind(this.instance)),s=o.unsubscribe.bind(o);n.push({handler:t,unsubscribe:s}),this.subscriptions[e]=n}else{let n=e;Object.keys(n).forEach(o=>this.on(o,n[o]))}}off(e,t){let n=this.subscriptions[e]||[];t?n.some((o,s)=>o.handler===t?(o.unsubscribe(),n.splice(s,1),!0):!1):(n.forEach(o=>{o.unsubscribe()}),n.splice(0,n.length))}dispose(){}addEmitter(e,t){this.events[e]=t}getEmitter(e){return this.events[e]||(this.events[e]=new un),this.events[e]}},t_=class{zone;component;lockedValueChangeEvent=!1;constructor(e,t){this.zone=e,this.component=t}fireNgEvent(e,t){if(this.lockedValueChangeEvent&&e==="valueChange")return;let n=this.component[e];n&&n.observers.length&&this.zone.run(()=>{n.next(t&&t[0])})}createEmitters(e){e.forEach(t=>{this.component[t.emit]=new un})}};var ae=(()=>{class i{_watchers=[];getWatchMethod(){return(n,o,s)=>{let r=n();s=s||{},s.skipImmediate||o(r);let a=()=>{let l=n();this._isDifferentValues(r,l,s.deep)&&(o(l),r=l)};return this._watchers.push(a),()=>{let l=this._watchers.indexOf(a);l!==-1&&this._watchers.splice(l,1)}}}_isDifferentValues(t,n,o){let s=this._toComparable(n),r=this._toComparable(t),a=s instanceof Object&&r instanceof Object;return o&&a?this._checkObjectsFields(n,t):s!==r}_toComparable(t){return t instanceof Date?t.getTime():t}_checkObjectsFields(t,n){for(let o in t){let s=this._toComparable(t[o]),r=this._toComparable(n[o]),a=!1;if(typeof s=="object"&&typeof r=="object"&&(a=ve(s,r)),s!==r&&!a)return!0}}checkWatchers(){for(let t of this._watchers)t()}static \u0275fac=function(n){return new(n||i)};static \u0275prov=Dd({token:i,factory:i.\u0275fac})}return i})();function Rw(i){return i.get?i.get(0):i}var Fw="dx-template-wrapper";var Pw=(()=>{class i{templateRef;viewContainerRef;renderer;zone;set dxTemplateOf(t){this.name=t}name;constructor(t,n,o,s,r){this.templateRef=t,this.viewContainerRef=n,this.renderer=s,this.zone=r,o.setTemplate(this)}renderTemplate(t){let n=this.viewContainerRef.createEmbeddedView(this.templateRef,{$implicit:t.model,index:t.index}),o=Rw(t.container);return t.container&&n.rootNodes.forEach(s=>{this.renderer.appendChild(o,s)}),n}render(t){let n;return this.zone.isStable?n=this.zone.run(()=>this.renderTemplate(t)):n=this.renderTemplate(t),n.detectChanges(),n.rootNodes.forEach(o=>{o.nodeType===1&&w.setClass(o,Fw,!0),nw(o,"dxremove",({},s)=>{(!s||!s._angularIntegration)&&n.destroy()})}),n.rootNodes}static \u0275fac=function(n){return new(n||i)(E(uE),E(hE),E(ee),E(ds),E(Ge))};static \u0275dir=wi({type:i,selectors:[["","dxTemplate",""]],inputs:{dxTemplateOf:"dxTemplateOf"},standalone:!1})}return i})(),ye=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Mw="dx-visibility-change-handler",kw=(()=>{class i{_host;_hostOptionPath;_collectionContainerImpl;_initialOptions={};constructor(){this._collectionContainerImpl=new gh(this._setOption.bind(this),this._filterItems.bind(this))}_optionChangedHandler(t){let n=this._fullOptionPath();if(t.fullName.indexOf(n)===0){let o=t.fullName.slice(n.length),s=this[`${o}Change`];s&&s.next(t.value)}}_createEventEmitters(t){t.forEach(n=>{this[n.emit]=new un})}_getOption(t){return this.isLinked?this.instance.option(this._fullOptionPath()+t):this._initialOptions[t]}_setOption(t,n){if(this.isLinked){let o=this._fullOptionPath()+t;this.instance.option(o,n)}else this._initialOptions[t]=n}_addRemovedOption(t){this.instance&&this.removedNestedComponents&&this.removedNestedComponents.push(t)}_deleteRemovedOptions(t){this.instance&&this.removedNestedComponents&&(this.removedNestedComponents=this.removedNestedComponents.filter(n=>!n.startsWith(t)))}_addRecreatedComponent(){this.instance&&this.recreatedNestedComponents&&this.recreatedNestedComponents.push({getOptionPath:()=>this._getOptionPath()})}_getOptionPath(){return this._hostOptionPath()+this._optionPath}setHost(t,n){this._host=t,this._hostOptionPath=n,this.optionChangedHandlers.subscribe(this._optionChangedHandler.bind(this))}setChildren(t,n){return this.resetOptions(t),this._collectionContainerImpl.setChildren(t,n)}_filterItems(t){return t.filter(n=>n!==this)}get instance(){return this._host&&this._host.instance}get resetOptions(){return this._host&&this._host.resetOptions}get isRecreated(){return this._host&&this._host.isRecreated}get removedNestedComponents(){return this._host&&this._host.removedNestedComponents}set removedNestedComponents(t){this._host.removedNestedComponents=t}get recreatedNestedComponents(){return this._host&&this._host.recreatedNestedComponents}set recreatedNestedComponents(t){this._host.recreatedNestedComponents=t}get isLinked(){return!!this.instance&&this._host.isLinked}get optionChangedHandlers(){return this._host&&this._host.optionChangedHandlers}static \u0275fac=function(n){return new(n||i)};static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),gh=class{_setOption;_filterItems;_activatedQueries={};constructor(e,t){this._setOption=e,this._filterItems=t}setChildren(e,t){if(this._filterItems&&(t=this._filterItems(t)),t.length&&(this._activatedQueries[e]=!0),this._activatedQueries[e]){let n=t.map((o,s)=>(o._index=s,o._value));this._setOption(e,n)}}},ko=(()=>{class i extends kw{setHost(t,n){super.setHost(t,n),this._host[this._optionPath]=this._initialOptions}_fullOptionPath(){return`${this._getOptionPath()}.`}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),hn=(()=>{class i extends kw{_index;_fullOptionPath(){return`${this._getOptionPath()}[${this._index}].`}get _value(){return this._initialOptions}get isLinked(){return this._index!==void 0&&!!this.instance&&this._host.isLinked}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),lz=function(i){let e=[];u(i).hasClass(Mw)||e.push(i),e.push.apply(e,i.querySelectorAll(`.${Mw}`));for(let t=0;t<e.length;t++)Bf(e[t],"dxshown")};function mh(i,e,t,n){!i.template===void 0||!e.nativeElement.hasChildNodes()||![].slice.call(e.nativeElement.childNodes).filter(r=>{if(r.tagName){let a=r.tagName.toLowerCase().substr(0,3);return!(a==="dxi"||a==="dxo")}return r.nodeName!=="#comment"&&r.textContent.replace(/\s/g,"").length}).length||(i.template={render:r=>{let a=e.nativeElement;if(w.setClass(a,Fw,!0),r.container){let l=Rw(r.container),d=l.contains(e.nativeElement);t.appendChild(l,e.nativeElement),d||n.body.contains(l)&&lz(a)}return a}})}var k=class{_host;_optionPath;getHost(){return this._host}setHost(e,t){this._host=e,this._optionPath=t||(()=>"")}setNestedOption(e){e.setHost(this._host,this._optionPath)}};fe({buyNowLink:"https://go.devexpress.com/Licensing_Installer_Watermark_DevExtremeAngular.aspx"});var Jf,e_=()=>(Jf||(Jf="DX_isPlatformServer"),Jf),et=(()=>{class i{element;ngZone;watcherHelper;transferState;platformId;_initialOptions={};_optionsToUpdate={};_collectionContainerImpl;eventHelper;optionChangedHandlers=new un;templates;instance;isLinked=!0;changedOptions={};removedNestedComponents=[];recreatedNestedComponents;widgetUpdateLocked=!1;templateUpdateRequired=!1;_updateTemplates(){if(this.templates.length&&this.templateUpdateRequired){let t={};this.templates.forEach(n=>{t[n.name]=n}),this.instance.option("integrationOptions.templates",t),this.templates=Object.values(t),this.templateUpdateRequired=!1}}_initEvents(){this.instance.on("optionChanged",t=>{this.changedOptions[t.name]=t.value;let n=t.name===t.fullName?t.value:t.component.option(t.name);this.eventHelper.fireNgEvent(`${t.name}Change`,[n]),this.optionChangedHandlers.emit(t)})}_initOptions(){this._initialOptions.integrationOptions.watchMethod=this.watcherHelper.getWatchMethod()}_initPlatform(){this.transferState.hasKey(e_())?this._initialOptions.integrationOptions.renderedOnServer=this.transferState.get(e_(),null):SE(this.platformId)&&this.transferState.set(e_(),!0)}_createEventEmitters(t){let n=this.ngZone;this.eventHelper.createEmitters(t),this._initialOptions.eventsStrategy=o=>{let s=new ph(o,n);return t.filter(r=>r.subscribe).forEach(r=>{s.addEmitter(r.subscribe,this[r.emit])}),s},this._initialOptions.nestedComponentOptions=function(o){return{eventsStrategy:s=>new ph(s,n),nestedComponentOptions:o.option("nestedComponentOptions")}}}_shouldOptionChange(t,n){if(this.changedOptions.hasOwnProperty(t)){let o=this.changedOptions[t];return delete this.changedOptions[t],n!==o}return!0}clearChangedOptions(){this.changedOptions={}}_getOption(t){return this.instance?this.instance.option(t):this._initialOptions[t]}lockWidgetUpdate(){!this.widgetUpdateLocked&&this.instance&&(this.instance.beginUpdate(),this.widgetUpdateLocked=!0)}unlockWidgetUpdate(){this.widgetUpdateLocked&&(this.widgetUpdateLocked=!1,this.instance.endUpdate())}_setOption(t,n){this.lockWidgetUpdate(),this._shouldOptionChange(t,n)&&(this.instance?this.instance.option(t,n):this._initialOptions[t]=n)}_createWidget(t){this._initialOptions.integrationOptions={},this._initPlatform(),this._initOptions(),this._initialOptions.onInitializing=function(){this.beginUpdate()},this.instance=this._createInstance(t,this._initialOptions),this._initEvents(),this._initialOptions={}}_destroyWidget(){if(this.removedNestedComponents=[],this.instance){let t=this.instance.element();Bf(t,"dxremove",{_angularIntegration:!0}),this.instance.dispose(),w.removeElement(t)}}constructor(t,n,o,s,r,a){this.element=t,this.ngZone=n,this.watcherHelper=s,this.transferState=r,this.platformId=a,this.templates=[],o.setHost(this),this._collectionContainerImpl=new gh(this._setOption.bind(this)),this.eventHelper=new t_(n,this)}ngOnChanges(t){for(let n in t)t[n].currentValue!==this[n]&&(this._optionsToUpdate[n]=t[n].currentValue)}ngOnInit(){this._createWidget(this.element.nativeElement)}ngDoCheck(){this.applyOptions()}ngAfterContentChecked(){this.applyOptions(),this.resetOptions(),this.unlockWidgetUpdate()}ngAfterViewInit(){this._updateTemplates(),this.instance.endUpdate(),this.recreatedNestedComponents=[]}ngAfterViewChecked(){this._updateTemplates()}applyOptions(){Object.keys(this._optionsToUpdate).length&&(this.instance&&this.instance.option(this._optionsToUpdate),this._optionsToUpdate={})}resetOptions(t){this.instance&&(this.removedNestedComponents.filter(n=>n&&!this.isRecreated(n)&&t?n.startsWith(t):!0).forEach(n=>{this.instance.resetOption(n)}),this.removedNestedComponents=[],this.recreatedNestedComponents=[])}isRecreated(t){return this.recreatedNestedComponents&&this.recreatedNestedComponents.some(n=>n.getOptionPath()===t)}setTemplate(t){this.templates.push(t),this.templateUpdateRequired=!0}setChildren(t,n){return this.resetOptions(t),this._collectionContainerImpl.setChildren(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var dz=["mousemove","mouseover","mouseout"],cz=["mouseup","click","mousedown","transitionend","wheel"],i_,n_=[],Bw=function(i){i_||(i_=this.callBase.bind(this)),n_.push(i)};zt.inject({add(i){return Bw.call(this,i)}});var Vw=(i,e,t)=>{Number(bE.major)<12&&console.warn("Your version of Angular is not supported. Please update your project to version 12 or later. Please refer to the Angular Update Guide for more information: https://update.angular.io"),w.inject({_document:i,listen(...o){let s=o[1];return dz.includes(s)?e.runOutsideAngular(()=>this.callBase.apply(this,o)):e.isStable&&cz.includes(s)?e.run(()=>this.callBase.apply(this,o)):this.callBase.apply(this,o)},isElementNode(o){return o&&o.nodeType===1},isTextNode(o){return o&&o.nodeType===3},isDocument(o){return o&&o.nodeType===9}}),uh.inject({getXhr(){if(!t)return this.callBase.apply(this);let o=t.build();return"withCredentials"in o||(o.withCredentials=!1),o}});let n=()=>{e.run(()=>{_.set({}),n_.forEach(o=>i_.call(null,o)),n_=[],zt.fire()})};n(),Bw=o=>e.run(()=>o()),Vw=n},qe=(()=>{class i{constructor(t,n,o){Vw(t,n,o)}static \u0275fac=function(n){return new(n||i)(Td(Va),Td(Ge),Td(EE,8))};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();function uz(i){return i&&typeof i[Symbol.iterator]=="function"}var Se=(()=>{class i{_differs;_host;_propertyDiffers={};constructor(t){this._differs=t}setHost(t){this._host=t}setup(t,n){if(t in n){let o=n[t].currentValue;this.setupSingle(t,o)}}setupSingle(t,n){if(n&&Array.isArray(n)){if(!this._propertyDiffers[t])try{return this._propertyDiffers[t]=this._differs.find(n).create(null),!0}catch{}}else delete this._propertyDiffers[t];return!1}getChanges(t,n){if(this._propertyDiffers[t])return this._propertyDiffers[t].diff(n)}checkChangedOptions(t,n){return this._host.changedOptions[t]===n}doCheck(t){if(this._propertyDiffers[t]&&this._host.instance){let n=this._host[t];uz(n)&&this.getChanges(t,n)&&!this.checkChangedOptions(t,n)&&(this._host.lockWidgetUpdate(),this._host.instance.option(t,n))}}static \u0275fac=function(n){return new(n||i)(Td(OE))};static \u0275prov=Dd({token:i,factory:i.\u0275fac})}return i})();function hz(i){return i&&i.get?i.get(0):i}var pz=hz;function N(i){return pz(i)}var gz=/matrix(3d)?\((.+?)\)/,mz=/translate(?:3d)?\((.+?)\)/,li=function(i){i=u(i);let e=Ud(i);return{left:e.x,top:e.y}};function fh(i){return ri(i)==="string"&&i[i.length-1]==="%"}function Lw(i,e){i.length&&$e(i.get(0),"dxTranslator",e)}var _h=function(i){i.length&&ir(i.get(0),"dxTranslator")},tl=function(i){i.x=i.x||0,i.y=i.y||0;let e=fh(i.x)?i.x:i.x+"px",t=fh(i.y)?i.y:i.y+"px";return"translate("+e+", "+t+")"},Ud=function(i){let e=i.length?$e(i.get(0),"dxTranslator"):null;if(!e){let n=(i.css("transform")||tl({x:0,y:0})).match(gz),o=n&&n[1];n?(n=n[2].split(","),o==="3d"?n=n.slice(12,15):(n.push(0),n=n.slice(4,7))):n=[0,0,0],e={x:parseFloat(n[0]),y:parseFloat(n[1]),z:parseFloat(n[2])},Lw(i,e)}return e},Ae=function(i,e){i=u(i);let t=e.left,n=e.top,o;t===void 0?(o=Ud(i),o.y=n||0):n===void 0?(o=Ud(i),o.x=t||0):(o={x:t||0,y:n||0,z:0},Lw(i,o)),i.css({transform:tl(o)}),(fh(t)||fh(n))&&_h(i)},Bo=function(i,e){i=u(i);let t,n={left:0,top:0,transform:"none"};e&&(t=i.css("transition"),n.transition="none"),i.css(n),_h(i),e&&(i.get(0).offsetHeight,i.css("transition",t))},Nw=function(i){let e=i.match(mz);if(!(!e||!e[1]))return e=e[1].split(","),e={x:parseFloat(e[0]),y:parseFloat(e[1]),z:parseFloat(e[2])},e};var Hw=/cubic-bezier\((\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\)/,$w={linear:"cubic-bezier(0, 0, 1, 1)",swing:"cubic-bezier(0.445, 0.05, 0.55, 0.95)",ease:"cubic-bezier(0.25, 0.1, 0.25, 1)","ease-in":"cubic-bezier(0.42, 0, 1, 1)","ease-out":"cubic-bezier(0, 0, 0.58, 1)","ease-in-out":"cubic-bezier(0.42, 0, 0.58, 1)"},fz=function(i,e,t,n){let o=3*i,s=3*(t-i)-o,r=1-o-s,a=3*e,l=3*(n-e)-a,d=1-a-l,c=function(p){return p*(o+p*(s+p*r))},h=function(p){return o+p*(2*s+3*p*r)};return function(p){return function(g){return g*(a+g*(l+g*d))}(function(g){let C=g,v=0,b;for(;v<14&&(b=c(C)-g,!(Math.abs(b)<.001));)C-=b/h(C),v++;return C}(p))}},s_={},zw=function(i){i=$w[i]||i;let e=i.match(Hw),t;e||(t="linear",e=$w[t].match(Hw)),e=e.slice(1,5);for(let o=0;o<e.length;o++)e[o]=parseFloat(e[o]);let n=t||"cubicbezier_"+e.join("_").replace(/\./g,"p");return A(s_[n])||(s_[n]=function(o,s,r,a,l){return a*fz(e[0],e[1],e[2],e[3])(s/l)+r}),n};function Ww(i){return s_[i]}var Vn=W()?K():{},Oie=1e3/60,Gw=function(i){return setTimeout(i,16.666666666666668)},Kw=function(i){clearTimeout(i)},Uw=Ki(function(){let i=Vn.requestAnimationFrame||Vn.webkitRequestAnimationFrame||Vn.mozRequestAnimationFrame||Vn.oRequestAnimationFrame||Vn.msRequestAnimationFrame,e=Vn.cancelAnimationFrame||Vn.webkitCancelAnimationFrame||Vn.mozCancelAnimationFrame||Vn.oCancelAnimationFrame||Vn.msCancelAnimationFrame;i&&e&&(Gw=i,Kw=e)});function rr(){return Uw(),Gw.apply(Vn,arguments)}function On(){Uw(),Kw.apply(Vn,arguments)}var c_={};G1(c_,{animation:()=>yh,inputType:()=>Yr,nativeScrolling:()=>Hn,pointerEvents:()=>e0,styleProp:()=>lo,stylePropPrefix:()=>Xa,supportProp:()=>l_,touch:()=>Nn,touchEvents:()=>Jw,transition:()=>bh,transitionEndEventName:()=>d_});var _z=function(){let i,e=ue(),t=e.add,n=e.remove;if(!W())return e;let o=function(){let l=K();return{width:l.innerWidth,height:l.innerHeight}},s=function(){let l=o();if(l.width===i.width&&l.height===i.height)return;let d;l.width===i.width&&(d="height"),l.height===i.height&&(d="width"),i=l,e.fire(d)},r=Ki(function(){i=o()}),a;return e.add=function(){let l=t.apply(e,arguments);return r(),zt.add(function(){!a&&e.has()&&(a=w.listen(K(),"resize",s))}),l},e.remove=function(){let l=n.apply(e,arguments);return!e.has()&&a&&(a(),a=void 0),l},e}(),co=_z;var Ln=class i{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this._events={},this._owner=e,this._options=t}static create(e,t){return t?A(t)?t(e):t:new i(e)}hasEvent(e){let t=this._events[e];return t?t.has():!1}fireEvent(e,t){let n=this._events[e];return n&&n.fireWith(this._owner,t),this._owner}on(e,t){if(q(e))x(e,(n,o)=>{this.on(n,o)});else{let n=this._events[e];n||(n=ue({syncStrategy:this._options.syncStrategy}),this._events[e]=n),(n.originalAdd||n.add).call(n,t)}}off(e,t){let n=this._events[e];n&&(A(t)?n.remove(t):n.empty())}dispose(){x(this._events,(e,t)=>{t.empty()})}};var Cz=K(),Ch=function(){let i;try{i=Cz.sessionStorage}catch{}return i};var xz=zt.add,qr=ue(),jw=u(),Sn=function(){let i;return function(e){if(!arguments.length)return i;let t=u(e);jw=t;let n=!!t.length,o=Sn();i=n?t:u("body"),qr.fire(n?Sn():u(),o)}}();xz(function(){Sn(".dx-viewport")});function xh(){return jw}var Qw=K(),vz={iPhone:"iPhone",iPhone5:"iPhone",iPhone6:"iPhone",iPhone6plus:"iPhone",iPad:"iPad",iPadMini:"iPad Mini",androidPhone:"Android Mobile",androidTablet:"Android",msSurface:"Windows ARM Tablet PC",desktop:"desktop"},qw={deviceType:"desktop",platform:"generic",version:[],phone:!1,tablet:!1,android:!1,ios:!1,generic:!0,grade:"A",mac:!1},r_={generic(i){let e=/windows phone/i.test(i)||i.match(/WPDesktop/),t=!e&&/Windows(.*)arm(.*)Tablet PC/i.test(i),n=!e&&!t&&/msapphost/i.test(i),o=/((intel|ppc) mac os x)/.test(i.toLowerCase());return e||t||n||o?{deviceType:e?"phone":t?"tablet":"desktop",platform:"generic",version:[],grade:"A",mac:o}:null},appleTouchDevice(i){let e=hs(),t=/Macintosh/i.test(i)&&e?.maxTouchPoints>2;if(!/ip(hone|od|ad)/i.test(i)&&!t)return null;let o=/ip(hone|od)/i.test(i),s=i.match(/os\s{0,}X? (\d+)_(\d+)_?(\d+)?/i),r=s?[parseInt(s[1],10),parseInt(s[2],10),parseInt(s[3]||0,10)]:[],l=Qw.screen.height===480?"B":"A";return{deviceType:o?"phone":"tablet",platform:"ios",version:r,grade:l}},android(i){let e=/android|htc_|silk/i.test(i),t=/windows phone/i.test(i);if(!e||t)return null;let n=/mobile/i.test(i),o=i.match(/android (\d+)\.?(\d+)?\.?(\d+)?/i),s=o?[parseInt(o[1],10),parseInt(o[2]||0,10),parseInt(o[3]||0,10)]:[],a=s.length>1&&(s[0]<4||s[0]===4&&s[1]<4)?"B":"A";return{deviceType:n?"phone":"tablet",platform:"android",version:s,grade:a}}},Yw=[r_.appleTouchDevice,r_.android,r_.generic],a_=class{constructor(e){this._window=e?.window||Qw,this._realDevice=this._getDevice(),this._currentDevice=void 0,this._currentOrientation=void 0,this._eventsStrategy=new Ln(this),this.changed=ue(),W()&&(zt.add(this._recalculateOrientation.bind(this)),co.add(this._recalculateOrientation.bind(this)))}current(e){if(e){this._currentDevice=this._getDevice(e),this._forced=!0,this.changed.fire();return}if(!this._currentDevice){e=void 0;try{e=this._getDeviceOrNameFromWindowScope()}catch{e=this._getDeviceNameFromSessionStorage()}finally{e||(e=this._getDeviceNameFromSessionStorage()),e&&(this._forced=!0)}this._currentDevice=this._getDevice(e)}return this._currentDevice}real(e){return m({},this._realDevice)}orientation(){return this._currentOrientation}isForced(){return this._forced}isRippleEmulator(){return!!this._window.tinyHippos}_getCssClasses(e){let t=[],n=this._realDevice;return e=e||this.current(),e.deviceType&&(t.push(`dx-device-${e.deviceType}`),e.deviceType!=="desktop"&&t.push("dx-device-mobile")),t.push(`dx-device-${n.platform}`),n.version&&n.version.length&&t.push(`dx-device-${n.platform}-${n.version[0]}`),this.isSimulator()&&t.push("dx-simulator"),fe().rtlEnabled&&t.push("dx-rtl"),t}attachCssClasses(e,t){this._deviceClasses=this._getCssClasses(t).join(" "),u(e).addClass(this._deviceClasses)}detachCssClasses(e){u(e).removeClass(this._deviceClasses)}isSimulator(){try{return this._isSimulator||W()&&this._window.top!==this._window.self&&this._window.top["dx-force-device"]||this.isRippleEmulator()}catch{return!1}}forceSimulator(){this._isSimulator=!0}_getDevice(e){if(e==="genericPhone"&&(e={deviceType:"phone",platform:"generic",generic:!0}),q(e))return this._fromConfig(e);{let t;if(e){if(t=vz[e],!t)throw he.Error("E0005")}else t=hs().userAgent;return this._fromUA(t)}}_getDeviceOrNameFromWindowScope(){let e;return W()&&(this._window.top["dx-force-device-object"]||this._window.top["dx-force-device"])&&(e=this._window.top["dx-force-device-object"]||this._window.top["dx-force-device"]),e}_getDeviceNameFromSessionStorage(){let e=Ch();if(!e)return;let t=e.getItem("dx-force-device");try{return JSON.parse(t)}catch{return t}}_fromConfig(e){let t=m({},qw,this._currentDevice,e),n={phone:t.deviceType==="phone",tablet:t.deviceType==="tablet",android:t.platform==="android",ios:t.platform==="ios",generic:t.platform==="generic"};return m(t,n)}_fromUA(e){for(let t=0;t<Yw.length;t+=1){let n=Yw[t],o=n(e);if(o)return this._fromConfig(o)}return qw}_changeOrientation(){let e=u(this._window),t=Y(e)>z(e)?"portrait":"landscape";this._currentOrientation!==t&&(this._currentOrientation=t,this._eventsStrategy.fireEvent("orientationChanged",[{orientation:t}]))}_recalculateOrientation(){let e=z(this._window);this._currentWidth!==e&&(this._currentWidth=e,this._changeOrientation())}on(e,t){return this._eventsStrategy.on(e,t),this}off(e,t){return this._eventsStrategy.off(e,t),this}},vh=new a_,Xw=Sn();Xw&&vh.attachCssClasses(Xw);qr.add((i,e)=>{vh.detachCssClasses(e),vh.attachCssClasses(i)});var F=vh;var{maxTouchPoints:Zw}=hs(),bz={webkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd",transition:"transitionend"},l_=function(i){return!!lo(i)},yz=function(){let{platform:i,mac:e}=F.real();return i==="ios"||i==="android"||e},Yr=function(i){if(i==="text")return!0;let e=w.createElement("input");try{return e.setAttribute("type",i),e.value="wrongValue",!e.value}catch{return!1}},Oz=function(i,e){return(i("ontouchstart")||!!e)&&!i("callPhantom")},Sz=function(i){return i("PointerEvent")},Jw=Oz(Af,Zw),e0=Sz(Af),Ez=!!Zw;var Nn=Jw||e0&&Ez,bh=Ki(function(){return l_("transition")}),d_=Ki(function(){return bz[lo("transition")]}),yh=Ki(function(){return l_("animation")}),Hn=yz();var Ui=i=>i??fe().rtlEnabled?"right":"left",Ie=i=>{var e;return Ne(i)?{width:i.outerWidth,height:i.outerHeight}:(e=i.getBoundingClientRect)===null||e===void 0?void 0:e.call(i)};var wz=hs(),Iz=/(webkit)[ /]([\w.]+)/,Dz=/(mozilla)(?:.*? rv:([\w.]+))/,t0=i=>{i=i.toLowerCase();let e={},t=Iz.exec(i)||i.indexOf("compatible")<0&&Dz.exec(i)||[],n=t[1],o=t[2];return n==="webkit"&&(e.webkit=!0,i.indexOf("chrome")>=0||i.indexOf("crios")>=0?(n="chrome",o=/(?:chrome|crios)\/(\d+\.\d+)/.exec(i),o=o&&o[1]):i.indexOf("fxios")>=0?(n="mozilla",o=/fxios\/(\d+\.\d+)/.exec(i),o=o&&o[1]):i.indexOf("safari")>=0&&/version|phantomjs/.test(i)?(n="safari",o=/(?:version|phantomjs)\/([0-9.]+)/.exec(i),o=o&&o[1]):(n="unknown",o=/applewebkit\/([0-9.]+)/.exec(i),o=o&&o[1])),n&&(e[n]=!0,e.version=o),e},be=m({_fromUA:t0},t0(wz.userAgent));var i0=K(),Tz=/left|right/,Az=/top|bottom/,n0=/fit|flip|none/,Mz=/scale\(.+?\)/,Rz=be.safari,u_=function(i){let e={h:"center",v:"center"},t=Mo(i);return t&&x(t,function(){let n=String(this).toLowerCase();Tz.test(n)?e.h=n:Az.test(n)&&(e.v=n)}),e},o0=function(i,e){return ja(i,e)},Fz=function(i){let e=Mo(i),t=String(e&&e[0]).toLowerCase(),n=String(e&&e[1]).toLowerCase();return n0.test(t)||(t="none"),n0.test(n)||(n=t),{h:t,v:n}},s0=function(i){switch(i){case"center":return .5;case"right":case"bottom":return 1;default:return 0}},h_=function(i){switch(i){case"left":return"right";case"right":return"left";case"top":return"bottom";case"bottom":return"top";default:return i}},p_=function(i,e){let t=0;return i.myLocation<e.min&&(t+=e.min-i.myLocation),i.myLocation>e.max&&(t+=i.myLocation-e.max),t},r0=function(i,e,t){return e.myLocation<t.min?i==="h"?"left":"top":e.myLocation>t.max?i==="h"?"right":"bottom":"none"},g_=function(i){i.myLocation=i.atLocation+s0(i.atAlign)*i.atSize-s0(i.myAlign)*i.mySize+i.offset},Oh={fit:function(i,e){let t=!1;i.myLocation>e.max&&(i.myLocation=e.max,t=!0),i.myLocation<e.min&&(i.myLocation=e.min,t=!0),i.fit=t},flip:function(i,e){if(i.flip=!1,!(i.myAlign==="center"&&i.atAlign==="center")&&(i.myLocation<e.min||i.myLocation>e.max)){let t=m({},i,{myAlign:h_(i.myAlign),atAlign:h_(i.atAlign),offset:-i.offset});g_(t),t.oversize=p_(t,e),(t.myLocation>=e.min&&t.myLocation<=e.max||i.oversize>t.oversize)&&(i.myLocation=t.myLocation,i.oversize=t.oversize,i.flip=!0)}},flipfit:function(i,e){this.flip(i,e),this.fit(i,e)},none:function(i){i.oversize=0}},l0,d0=function(){let i=u("<div>").css({width:100,height:100,overflow:"scroll",position:"absolute",top:-9999}).appendTo(u("body")),e=i.get(0).offsetWidth-i.get(0).clientWidth;i.remove(),l0=e},Pz={h:{location:0,flip:!1,fit:!1,oversize:0},v:{location:0,flip:!1,fit:!1,oversize:0}},c0=function(i,e){let t=u(i),n=t.offset(),o=m(!0,{},Pz,{h:{location:n.left},v:{location:n.top}});if(!e)return o;let s=u_(e.my),r=u_(e.at),a=u(e.of).length&&e.of||i0,l=o0(e.offset,e.precise),d=Fz(e.collision),c=e.boundary,h=o0(e.boundaryOffset,e.precise),p={mySize:ie(t),myAlign:s.h,atAlign:r.h,offset:l.h,collision:d.h,boundaryOffset:h.h},g={mySize:X(t),myAlign:s.v,atAlign:r.v,offset:l.v,collision:d.v,boundaryOffset:h.v};if(a.preventDefault)p.atLocation=a.pageX,g.atLocation=a.pageY,p.atSize=0,g.atSize=0;else if(a=u(a),Ne(a[0]))p.atLocation=a.scrollLeft(),g.atLocation=a.scrollTop(),F.real().deviceType==="phone"&&a[0].visualViewport?(p.atLocation=Math.max(p.atLocation,a[0].visualViewport.offsetLeft),g.atLocation=Math.max(g.atLocation,a[0].visualViewport.offsetTop),p.atSize=a[0].visualViewport.width,g.atSize=a[0].visualViewport.height):(p.atSize=a[0].innerWidth>a[0].outerWidth?a[0].innerWidth:z(a),g.atSize=a[0].innerHeight>a[0].outerHeight||Rz?a[0].innerHeight:Y(a));else if(a[0].nodeType===9)p.atLocation=0,g.atLocation=0,p.atSize=z(a),g.atSize=Y(a);else{let b=Ie(a.get(0)),T=Sh(a);p.atLocation=T.left,g.atLocation=T.top,p.atSize=Math.max(b.width,ie(a)),g.atSize=Math.max(b.height,X(a))}g_(p),g_(g);let C=function(){let b=u(i0),T=z(b),R=Y(b),U=b.scrollLeft(),Q=b.scrollTop(),se=w.getDocumentElement(),re=Nn?se.clientWidth/T:1,Re=Nn?se.clientHeight/R:1;l0===void 0&&d0();let we=T,We=R;if(c&&!Ne(c)){let gi=u(c),gt=gi.offset();U=gt.left,Q=gt.top,we=z(gi),We=Y(gi)}return{h:{min:U+p.boundaryOffset,max:U+we/re-p.mySize-p.boundaryOffset},v:{min:Q+g.boundaryOffset,max:Q+We/Re-g.mySize-g.boundaryOffset}}}();p.oversize=p_(p,C.h),g.oversize=p_(g,C.v),p.collisionSide=r0("h",p,C.h),g.collisionSide=r0("v",g,C.v),Oh[p.collision]&&Oh[p.collision](p,C.h),Oh[g.collision]&&Oh[g.collision](g,C.v);let v=function(b){return e.precise?b:Math.round(b)};return m(!0,o,{h:{location:v(p.myLocation),oversize:v(p.oversize),fit:p.fit,flip:p.flip,collisionSide:p.collisionSide},v:{location:v(g.myLocation),oversize:v(g.oversize),fit:g.fit,flip:g.flip,collisionSide:g.collisionSide},precise:e.precise}),o},a0=function(i,e,t,n){let o=f(i.style)&&!w.isNode(i.style),s=n?t.replace(e,""):t;if(o)lh(i,s,!1);else{let r=w.createAttribute("style");r.value=s,i.setAttributeNode(r)}},Sh=function(i){var e,t;let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:i,o=n.get(0);if(!o)return i.offset();let s=((e=o.getAttribute)===null||e===void 0?void 0:e.call(o,"style"))||"",r=(t=s.match(Mz))===null||t===void 0?void 0:t[0],a;return r?(a0(o,r,s,!0),a=Sh(i,n.parent()),a0(o,r,s,!1)):a=Sh(i,n.parent()),a},jd=function(i,e){let t=u(i);if(!e)return t.offset();Bo(t,!0);let n=Sh(t),o=e.h&&e.v?e:c0(t,e),s=function(r){return e.precise?r:Math.round(r)};return Ae(t,{left:o.h.location-s(n.left),top:o.v.location-s(n.top)}),o},kz=function(i){return i=u(i).get(0),Ne(i)?null:i&&"pageY"in i&&"pageX"in i?{top:i.pageY,left:i.pageX}:u(i).offset()};jd.inverseAlign||(jd.inverseAlign=h_);jd.normalizeAlign||(jd.normalizeAlign=u_);var lt={calculateScrollbarWidth:d0,calculate:c0,setup:jd,offset:kz};var u0=function(i,e){let t={};"noBubble"in e&&(t.noBubble=e.noBubble),"bindType"in e&&(t.bindType=e.bindType),"delegateType"in e&&(t.delegateType=e.delegateType),x(["setup","teardown","add","remove","trigger","handle","_default","dispose"],function(n,o){e[o]&&(t[o]=function(){let s=[].slice.call(arguments);return s.unshift(this),e[o].apply(e,s)})}),Bd.fire(i,t)};u0.callbacks=Bd;var vi=u0;var Gt="dxremove",m_="dxRemoveEvent";sw(function(i){i=[].slice.call(i);for(let e=0;e<i.length;e++){let t=u(i[e]);t.prop(m_)&&(t[0][m_]=null,_.triggerHandler(t,"dxremove"))}});vi("dxremove",{noBubble:!0,setup:function(i){u(i).prop(m_,!0)}});var f_=(i,e)=>{if(!e)throw he.Error("E0017");return Array.isArray(i)?i.map(t=>f_(t,e)).join(" "):i.indexOf(" ")!==-1?f_(i.split(/\s+/g),e):`${i}.${e}`},h0=f_;var p0=function(i,e){if(!Bz(i))return!1;let t=i.nodeName.toLowerCase(),n=!isNaN(e),o=i.disabled,s=/^(input|select|textarea|button|object|iframe)$/.test(t),r=t==="a",a,l=i.isContentEditable;return s||l?a=!o:r?a=i.href||n:a=n,a};function Bz(i){let e=u(i);return e.is(":visible")&&e.css("visibility")!=="hidden"&&e.parents().css("visibility")!=="hidden"}var qd=function(i,e){return p0(e,u(e).attr("tabIndex"))},Yd=function(i,e){let t=u(e).attr("tabIndex");return(isNaN(t)||t>=0)&&p0(e,t)},pn=function(i){let e=u(i).get(0);return w.getActiveElement(e)===e};var Vz={backspace:"backspace",tab:"tab",enter:"enter",escape:"escape",pageup:"pageUp",pagedown:"pageDown",end:"end",home:"home",arrowleft:"leftArrow",arrowup:"upArrow",arrowright:"rightArrow",arrowdown:"downArrow",delete:"del"," ":"space",f:"F",a:"A","*":"asterisk","-":"minus",alt:"alt",control:"control",shift:"shift"},Lz={8:"backspace",9:"tab",13:"enter",27:"escape",33:"pageUp",34:"pageDown",35:"end",36:"home",37:"leftArrow",38:"upArrow",39:"rightArrow",40:"downArrow",46:"del",32:"space",70:"F",65:"A",106:"asterisk",109:"minus",189:"minus",173:"minus",16:"shift",17:"control",18:"alt"},Nz={dx:/^dx/i,mouse:/(mouse|wheel)/i,touch:/^touch/i,keyboard:/^key/i,pointer:/^(ms)?pointer/i},Hz=i=>i,$z=i=>Hz(_.Event(i,i),i),__=i=>il(i)==="dx",zz=i=>il(i)==="mouse",g0=i=>il(i)==="touch",il=i=>{let{type:e}=i,t="other";return x(Nz,function(n){if(this.test(e))return t=n,!1}),t},m0=i=>il(i)==="pointer",$n=i=>zz(i)||(m0(i)||__(i))&&i.pointerType==="mouse",Ut=i=>i&&i.type==="dxmousewheel",gs=i=>g0(i)||(m0(i)||__(i))&&i.pointerType==="touch";var Ye=i=>{let{pageX:e,pageY:t,timeStamp:n}=i;return{x:e,y:t,time:n}},Vo=(i,e)=>({x:e.x-i.x,y:e.y-i.y,time:e.time-i.time||1}),f0=i=>{let{originalEvent:e,pointers:t}=i;return g0(i)?(e.touches||[]).length:__(i)?(t||[]).length:0},Wz=!1;var Eh=i=>{if(Wz)return!0;let{target:e}=i,t=u(e),n=e?.isContentEditable||e?.hasAttribute("contenteditable"),o=t.is("input, textarea, select")||n;if(Ut(i))return t.is("textarea")&&t.hasClass("dx-texteditor-input")||n?!1:t.is("input[type='number'], textarea, select")&&t.is(":focus");if($n(i))return o||i.which>1;if(gs(i))return o&&pn(t)};var uo=(i,e)=>{let t=$z(i);return e&&m(t,e),t},ji=i=>{let{originalEvent:e,delegateTarget:t}=i,n=uo(e,i);return _.trigger(t||n.target,n),n},De=i=>{let{key:e,which:t}=i,n=Vz[e?.toLowerCase()]||e,o=Lz[t];return o&&n===e?o:!n&&t?String.fromCharCode(t):n},Xd=i=>{let{key:e,which:t}=i;return e||String.fromCharCode(t)},D=h0,ot=i=>{let{ctrlKey:e,metaKey:t}=i;return e||t};var C0=K(),Qd=D(Gt,"dxFX"),Gz=/^([+-])=(.*)/i,Zd="dxAnimData",O_="dxAnimQueue";var Kz={initAnimation:function(i,e){i.css({transitionProperty:"none"}),typeof e.from=="string"?i.addClass(e.from):y_(i,e.from);let t=this,n=new y,o=e.cleanupWhen;e.transitionAnimation={deferred:n,finish:function(){t._finishTransition(i),o?P(n,o).always(function(){t._cleanup(i,e)}):t._cleanup(i,e),n.resolveWith(i,[e,i])}},this._completeAnimationCallback(i,e).done(function(){e.transitionAnimation.finish()}).fail(function(){n.rejectWith(i,[e,i])}),e.duration||e.transitionAnimation.finish(),i.css("transform")},animate:function(i,e){return this._startAnimation(i,e),e.transitionAnimation.deferred.promise()},_completeAnimationCallback:function(i,e){let t=this,n=Date.now()+e.delay,o=new y,s=new y,r=new y,a,l=d_()+".dxFX";e.transitionAnimation.cleanup=function(){clearTimeout(a),clearTimeout(d),_.off(i,l),_.off(i,Qd)},_.one(i,l,function(){Date.now()-n>=e.duration&&s.reject()}),_.off(i,Qd),_.on(i,Qd,function(){t.stop(i,e),o.reject()});let d=setTimeout(function(){a=setTimeout(function(){r.reject()},e.duration+e.delay+Jd._simulatedTransitionEndDelay),P(s,r).fail(function(){o.resolve()}.bind(this))});return o.promise()},_startAnimation:function(i,e){i.css({transitionProperty:"all",transitionDelay:e.delay+"ms",transitionDuration:e.duration+"ms",transitionTimingFunction:e.easing}),typeof e.to=="string"?i[0].className+=" "+e.to:e.to&&y_(i,e.to)},_finishTransition:function(i){i.css("transition","none")},_cleanup:function(i,e){e.transitionAnimation.cleanup(),typeof e.from=="string"&&(i.removeClass(e.from),i.removeClass(e.to))},stop:function(i,e,t){e&&(t?e.transitionAnimation.finish():(q(e.to)&&x(e.to,function(n){i.css(n,i.css(n))}),this._finishTransition(i),this._cleanup(i,e)))}},_0={initAnimation:function(i,e){y_(i,e.from)},animate:function(i,e){let t=new y,n=this;return e?(x(e.to,function(o){e.from[o]===void 0&&(e.from[o]=n._normalizeValue(i.css(o)))}),e.to.transform&&(e.from.transform=n._parseTransform(e.from.transform),e.to.transform=n._parseTransform(e.to.transform)),e.frameAnimation={to:e.to,from:e.from,currentValue:e.from,easing:zw(e.easing),duration:e.duration,startTime:new Date().valueOf(),finish:function(){this.currentValue=this.to,this.draw(),On(e.frameAnimation.animationFrameId),t.resolve()},draw:function(){if(e.draw){e.draw(this.currentValue);return}let o=m({},this.currentValue);o.transform&&(o.transform=He(o.transform,function(s,r){if(r==="translate")return tl(s);if(r==="scale")return"scale("+s+")";if(r.substr(0,r.length-1)==="rotate")return r+"("+s+"deg)"}).join(" ")),i.css(o)}},e.delay?(e.frameAnimation.startTime+=e.delay,e.frameAnimation.delayTimeout=setTimeout(function(){n._startAnimation(i,e)},e.delay)):n._startAnimation(i,e),t.promise()):t.reject().promise()},_startAnimation:function(i,e){_.off(i,Qd),_.on(i,Qd,function(){e.frameAnimation&&On(e.frameAnimation.animationFrameId)}),this._animationStep(i,e)},_parseTransform:function(i){let e={};return x(i.match(/\w+\d*\w*\([^)]*\)\s*/g),function(t,n){let o=Nw(n),s=n.match(/scale\((.+?)\)/),r=n.match(/(rotate.)\((.+)deg\)/);o&&(e.translate=o),s&&s[1]&&(e.scale=parseFloat(s[1])),r&&r[1]&&(e[r[1]]=parseFloat(r[2]))}),e},stop:function(i,e,t){let n=e&&e.frameAnimation;n&&(On(n.animationFrameId),clearTimeout(n.delayTimeout),t&&n.finish(),delete e.frameAnimation)},_animationStep:function(i,e){let t=e&&e.frameAnimation;if(!t)return;let n=new Date().valueOf();if(n>=t.startTime+t.duration){t.finish();return}t.currentValue=this._calcStepValue(t,n-t.startTime),t.draw();let o=this;t.animationFrameId=rr(function(){o._animationStep(i,e)})},_calcStepValue:function(i,e){let t=function(n,o){let s=Array.isArray(o)?[]:{};return x(o,function(r,a){if(typeof a=="string"&&parseFloat(a)===!1)return!0;s[r]=typeof a=="object"?t(n[r],a):function(l){let d=e/i.duration,c=e,h=1*n[l],p=o[l]-n[l],g=i.duration;return Ww(i.easing)(d,c,h,p,g)}(r)}),s};return t(i.from,i.to)},_normalizeValue:function(i){let e=parseFloat(i);return e===!1?i:e}},Uz={initAnimation:function(){},animate:function(){return new y().resolve().promise()},stop:S,isSynchronous:!0},jz=function(i){i=i||{};let e={transition:bh()?Kz:_0,frame:_0,noAnimation:Uz},t=i.strategy||"transition";return i.type==="css"&&!bh()&&(t="noAnimation"),e[t]},x0=function(i,e,t,n){x(["from","to"],function(){if(!t(i[this]))throw he.Error("E0010",e,this,n)})},v0=function(i,e){return x0(i,e,function(t){return q(t)},"a plain object")},qz=function(i,e){return x0(i,e,function(t){return typeof t=="string"},"a string")},Yz={setup:function(){}},Xz={validateConfig:function(i){qz(i,"css")},setup:function(){}},Qz={top:{my:"bottom center",at:"top center"},bottom:{my:"top center",at:"bottom center"},right:{my:"left center",at:"right center"},left:{my:"right center",at:"left center"}},C_={validateConfig:function(i){v0(i,"slide")},setup:function(i,e){let t=li(i);if(e.type!=="slide"){let n=e.type==="slideIn"?e.from:e.to;n.position=m({of:C0},Qz[e.direction]),b_(i,n)}this._setUpConfig(t,e.from),this._setUpConfig(t,e.to),_h(i)},_setUpConfig:function(i,e){e.left="left"in e?e.left:"+=0",e.top="top"in e?e.top:"+=0",this._initNewPosition(i,e)},_initNewPosition:function(i,e){let t={left:e.left,top:e.top};delete e.left,delete e.top;let n=this._getRelativeValue(t.left);n!==void 0?t.left=n+i.left:e.left=0,n=this._getRelativeValue(t.top),n!==void 0?t.top=n+i.top:e.top=0,e.transform=tl({x:t.left,y:t.top})},_getRelativeValue:function(i){let e;if(typeof i=="string"&&(e=Gz.exec(i)))return parseInt(e[1]+"1")*e[2]}},x_={setup:function(i,e){let t=e.from,n=e.to,o=e.type==="fadeOut"?1:0,s=e.type==="fadeOut"?0:1,r=q(t)?String(t.opacity??o):String(t),a=q(n)?String(n.opacity??s):String(n);switch(e.skipElementInitialStyles||(r=i.css("opacity")),e.type){case"fadeIn":a=1;break;case"fadeOut":a=0}e.from={visibility:"visible",opacity:r},e.to={opacity:a}}},Zz={validateConfig:function(i){v0(i,"pop")},setup:function(i,e){let t=e.from,n=e.to,o="opacity"in t?t.opacity:i.css("opacity"),s="opacity"in n?n.opacity:1,r="scale"in t?t.scale:0,a="scale"in n?n.scale:1;e.from={opacity:o};let l=Ud(i);e.from.transform=this._getCssTransform(l,r),e.to={opacity:s},e.to.transform=this._getCssTransform(l,a)},_getCssTransform:function(i,e){return tl(i)+"scale("+e+")"}},b0={custom:Yz,slide:C_,slideIn:C_,slideOut:C_,fade:x_,fadeIn:x_,fadeOut:x_,pop:Zz,css:Xz},Jz=function(i){let e=b0[i.type];if(!e)throw he.Error("E0011",i.type);return e},eW={type:"custom",from:{},to:{},duration:400,start:S,complete:S,easing:"ease",delay:0},tW={duration:400,easing:"ease",delay:0};function iW(){let i=this.element,e=this.config;if(b_(i,e.from),b_(i,e.to),this.configurator.setup(i,e),i.data(Zd,this),Jd.off&&(e.duration=0,e.delay=0),this.strategy.initAnimation(i,e),e.start){let t=N(i);e.start.apply(this,[t,e])}}var nW=function(i){let e=i.element,t=i.config;if(e.removeData(Zd),t.complete){let n=N(e);t.complete.apply(this,[n,t])}i.deferred.resolveWith(this,[e,t])},oW=function(){let i=this,e=i.element,t=i.config;return i.isStarted=!0,i.strategy.animate(e,t).done(function(){nW(i)}).fail(function(){i.deferred.rejectWith(this,[e,t])})},sW=function(i){let e=this,t=e.element,n=e.config;clearTimeout(e.startTimeout),e.isStarted||e.start(),e.strategy.stop(t,n,i)},v_=D(Gt,"dxFXStartAnimation"),rW=function(i){_.off(i.element,v_),_.on(i.element,v_,function(){Jd.stop(i.element)}),i.deferred.always(function(){_.off(i.element,v_)})},y0=function(i,e){let t=e.type==="css"?tW:eW,n=m(!0,{},t,e),o=Jz(n),s=jz(n),r={element:u(i),config:n,configurator:o,strategy:s,isSynchronous:s.isSynchronous,setup:iW,start:oW,stop:sW,deferred:new y};return A(o.validateConfig)&&o.validateConfig(n),rW(r),r},aW=function(i,e){let t=u(i);if(!t.length)return new y().resolve().promise();let n=y0(t,e);return lW(t,n),n.deferred.promise()};function lW(i,e){let t=S_(i);dW(i,t),t.push(e),wh(i)||E_(i,t)}function S_(i){return i.data(O_)||[]}function dW(i,e){i.data(O_,e)}var O0=function(i){i.removeData(O_)};function wh(i){return!!i.data(Zd)}function E_(i,e){if(e=S_(i),!e.length)return;let t=e.shift();e.length===0&&O0(i),cW(t).done(function(){wh(i)||E_(i)})}function cW(i){return i.setup(),Jd.off||i.isSynchronous?i.start():i.startTimeout=setTimeout(function(){i.start()}),i.deferred.promise()}function b_(i,e){if(!e||!e.position)return;let t=u(C0),n=0,o=0,s=lt.calculate(i,e.position),r=i.offset(),a=i.position();a.top>r.top&&(o=t.scrollTop()),a.left>r.left&&(n=t.scrollLeft()),m(e,{left:s.h.location-r.left+a.left-n,top:s.v.location-r.top+a.top-o}),delete e.position}function y_(i,e){x(e,function(t,n){try{i.css(t,A(n)?n():n)}catch{}})}var uW=function(i,e){let t=u(i),n=S_(t);x(n,function(s,r){r.config.delay=0,r.config.duration=0,r.isSynchronous=!0}),wh(t)||E_(t,n);let o=t.data(Zd);o&&o.stop(e),t.removeData(Zd),O0(t)},Jd={off:!1,animationTypes:b0,animate:aW,createAnimation:y0,isAnimating:wh,stop:uW,_simulatedTransitionEndDelay:100},pe=Jd;var w_=new er;var Ih=new WeakMap,hW=0,ar=function(i,e){if(f(e)){Ih.set(i,e);return}if(!Ih.has(i)){let t="dxPrivateComponent"+hW++;return Ih.set(i,t),t}return Ih.get(i)};function Dh(i,e,t){let n=$e(i.get(0)),o=ar(e.constructor);n[o]=e,t&&_.one(i,Gt,function(){t.call(e)}),n.dxComponents||(n.dxComponents=[]),n.dxComponents.push(o)}function Th(i,e){let t=ar(e);return $e(i.get(0),t)}var pW=function(i,e,t){t?e[i]=t:t=e,ar(t,i),w_.fire(i,t)},gW=function(i,e){u.fn[i]=function(t){let n=typeof t=="string",o;if(n){let s=t,r=[].slice.call(arguments).slice(1);this.each(function(){let a=e.getInstance(this);if(!a)throw he.Error("E0009",i);let d=a[s].apply(a,r);o===void 0&&(o=d)})}else this.each(function(){let s=e.getInstance(this);s?s.option(t):new e(this,t)}),o=this;return o}};w_.add(gW);var G=pW;var I_=K(),mW=i=>{if(!i.getRootNode)return;let e=i.getRootNode().host;if(!B(e))return e},zn=()=>{let i=w.getActiveElement();if(i&&i!==w.getBody()){var e;(e=i.blur)===null||e===void 0||e.call(i)}},S0=()=>{let i=I_.getSelection();if(i&&i.type!=="Caret"){if(i.empty)i.empty();else if(i.removeAllRanges)try{i.removeAllRanges()}catch{}}},E0=(i,e)=>{let t=u(i),n=u(e);if(t[0]===n[0])return t[0];let o=t.parents(),s=n.parents(),r=Math.min(o.length,s.length);for(let a=-r;a<0;a++)if(o.get(a)===s.get(a))return o.get(a)};var Xr=i=>{let e=f(i)&&(i.nodeType||$t(i))?u(i):u("<div>").html(i).contents();return e.length===1&&(e.is("script")?e=Xr(e.html().trim()):e.is("table")&&(e=e.children("tbody").contents())),e},ec=(i,e)=>{let t=i.originalEvent&&i.originalEvent.clipboardData||I_.clipboardData;if(!e)return t&&t.getData("Text");t&&t.setData("Text",e)},on=(i,e)=>e?Ne(i)?on(i.document,e):i.contains(e)||on(i,mW(e)):!1,w0=(i,e,t)=>{let n=I_.getComputedStyle(u(i).get(0)),o=t&&t.includePaddings;return u("<div>").text(e).css({fontStyle:n.fontStyle,fontVariant:n.fontVariant,fontWeight:n.fontWeight,fontSize:n.fontSize,fontFamily:n.fontFamily,letterSpacing:n.letterSpacing,border:n.border,paddingTop:o?n.paddingTop:"",paddingRight:o?n.paddingRight:"",paddingBottom:o?n.paddingBottom:"",paddingLeft:o?n.paddingLeft:"",visibility:"hidden",whiteSpace:"pre",position:"absolute",float:"left"})},fW=(i,e)=>(e&&w.insertElement(i.parentNode,e,i),i),I0=(i,e)=>{if(e&&e[0])return e.is(i)?i:(x(e,(t,n)=>{fW(i[0],n)}),i.remove(),e)},Lo=i=>{let e=i?.get(0),t=e?.getRootNode().host;return!!u(t||e).closest(K().document).length};var D_=function(i){return function(e){let t=u(e||"body"),n=t.filter(".dx-visibility-change-handler").add(t.find(".dx-visibility-change-handler"));for(let o=0;o<n.length;o++)_.triggerHandler(n[o],i)}},nl=D_("dxshown"),D0=D_("dxhiding"),bi=D_("dxresize");var _W=ue({syncStrategy:!0}),sn=class{render(e){e=e||{};let t=e.onRendered;delete e.onRendered;let n;return e.renovated&&e.transclude&&this._element?n=u("<div>").append(this._element).contents():n=this._renderCore(e),this._ensureResultInContainer(n,e.container),_W.fire(n,e.container),t&&t(),n}_ensureResultInContainer(e,t){if(!t)return;let n=u(t),o=on(n.get(0),e.get(0));n.append(e),!(o||!on(w.getBody(),n.get(0)))&&nl(e)}_renderCore(){throw he.Error("E0001")}};var CW=function(i,e,t,n,o){let s,r=((a,l,d)=>l(()=>a,d))(i,e,function(a){if(s&&s(),Zs(a)){o(a);return}s=function(l,d,c,h,p){let g={},C=c.slice(),v=c.map(function(b){let T=h[b];return d(T?()=>T(l):()=>l[b],function(R){if(g[b]=R,C.length){let U=C.indexOf(b);U>=0&&C.splice(U,1)}C.length||p(g)})});return function(){v.forEach(b=>b())}}(a,e,t,n,o)});return function(){s&&s(),r&&r()}},di=class extends sn{constructor(e,t,n,o){super(),this._render=e,this._fields=t,this._fieldsMap=o||{},this._watchMethod=n}_renderCore(e){let t=u(e.container),n=CW(e.model,this._watchMethod,this._fields,this._fieldsMap,o=>{t.empty(),this._render(t,o,e.model)});return _.on(t,Gt,n),t.contents()}};var ms=i=>!i||typeof i!="string"?!1:/^\s*<svg[^>]*>(.|\r?\n)*?<\/svg>\s*$/i.test(i)?"svg":/data:.*base64|\.|[^<\s]\/{1,1}/.test(i)?"image":/^[\w-_]+$/.test(i)?"dxIcon":/^\s?([\w-_:]\s?)+$/.test(i)?"fontIcon":!1,ci=i=>{switch(ms(i)){case"image":return u("<img>").attr("src",i).addClass("dx-icon");case"fontIcon":return u("<i>").addClass(`dx-icon ${i}`);case"dxIcon":return u("<i>").addClass(`dx-icon dx-icon-${i}`);case"svg":return u("<i>").addClass("dx-icon dx-svg-icon").append(i);default:return null}};function T0(i){return i&&[i.target,i.delegateTarget,i.relatedTarget,i.currentTarget].filter(e=>!!e)}var A0=(i,e)=>{_.one(T0(i),Gt,e)},M0=(i,e)=>{_.off(T0(i),Gt,e)};var vW=ce.inherit({ctor:function(i,e){this._eventName=i,this._originalEvents=D(e,"dxPointerEvents"),this._handlerCount=0,this.noBubble=this._isNoBubble()},_isNoBubble:function(){let i=this._eventName;return i==="dxpointerenter"||i==="dxpointerleave"},_handler:function(i){let e=this._getDelegateTarget(i),t={type:this._eventName,pointerType:i.pointerType||il(i),originalEvent:i,delegateTarget:e,timeStamp:be.mozilla?new Date().getTime():i.timeStamp},n=qa(i);return t.target=n,this._fireEvent(t)},_getDelegateTarget:function(i){let e;return this.noBubble&&(e=i.delegateTarget),e},_fireEvent:function(i){return ji(i)},_setSelector:function(i){this._selector=this.noBubble&&i?i.selector:null},_getSelector:function(){return this._selector},setup:function(){return!0},add:function(i,e){if(this._handlerCount<=0||this.noBubble){i=this.noBubble?i:w.getDocument(),this._setSelector(e);let t=this;_.on(i,this._originalEvents,this._getSelector(),function(n){t._handler(n)})}this.noBubble||this._handlerCount++},remove:function(i){this._setSelector(i),this.noBubble||this._handlerCount--},teardown:function(i){this._handlerCount&&!this.noBubble||(i=this.noBubble?i:w.getDocument(),this._originalEvents!==".dxPointerEvents"&&_.off(i,this._originalEvents,this._getSelector()))},dispose:function(i){i=this.noBubble?i:w.getDocument(),_.off(i,this._originalEvents)}}),ol=vW;var bW={dxpointerdown:"touchstart",dxpointermove:"touchmove",dxpointerup:"touchend",dxpointercancel:"touchcancel",dxpointerover:"",dxpointerout:"",dxpointerenter:"",dxpointerleave:""},R0=function(i){let e=[];return x(i.touches,function(t,n){e.push(m({pointerId:n.identifier},n))}),{pointers:e,pointerId:i.changedTouches[0].identifier}},yW=function(i){return F.real().platform==="ios"&&(i==="dxpointerdown"||i==="dxpointerup")},T_=ol.inherit({ctor:function(){this.callBase.apply(this,arguments),this._pointerId=0},_handler:function(i){if(yW(this._eventName)){let e=i.changedTouches[0];if(this._pointerId===e.identifier&&this._pointerId!==0)return;this._pointerId=e.identifier}return this.callBase.apply(this,arguments)},_fireEvent:function(i){return this.callBase(m(R0(i.originalEvent),i))}});T_.map=bW;T_.normalize=R0;var tc=T_;var Ah=function(i,e){zt.add(function(){i.split(" ").forEach(function(t){w.listen(w.getDocument(),t,e,!0)})})},OW=function(i,e,t){t=t||function(){};let n=[],o=function(r){let a=-1;return x(n,function(l,d){return e(r,d)?(a=l,!1):!0}),a},s=function(r){let a=o(r);a>-1&&n.splice(a,1)};Ah(i.dxpointerdown,function(r){o(r)===-1&&(t(r),n.push(r))}),Ah(i.dxpointermove,function(r){n[o(r)]=r}),Ah(i.dxpointerup,s),Ah(i.dxpointercancel,s),this.pointers=function(){return n},this.reset=function(){n=[]}},F0=OW;var A_={dxpointerdown:"mousedown",dxpointermove:"mousemove",dxpointerup:"mouseup",dxpointercancel:"pointercancel",dxpointerover:"mouseover",dxpointerout:"mouseout",dxpointerenter:"mouseenter",dxpointerleave:"mouseleave"};be.safari&&(A_.dxpointercancel+=" dragstart");var k0=function(i){return i.pointerId=1,{pointers:M_.pointers(),pointerId:1}},M_,P0=!1,B0=function(){P0||(M_=new F0(A_,function(){return!0}),P0=!0)},ic=ol.inherit({ctor:function(){this.callBase.apply(this,arguments),B0()},_fireEvent:function(i){return this.callBase(m(k0(i.originalEvent),i))}});ic.map=A_;ic.normalize=k0;ic.activate=B0;ic.resetObserver=function(){M_.reset()};var Qr=ic;var SW={dxpointerdown:"touchstart mousedown",dxpointermove:"touchmove mousemove",dxpointerup:"touchend mouseup",dxpointercancel:"touchcancel",dxpointerover:"mouseover",dxpointerout:"mouseout",dxpointerenter:"mouseenter",dxpointerleave:"mouseleave"},V0=!1,EW=function(){V0||(Qr.activate(),V0=!0)},R_=ol.inherit({EVENT_LOCK_TIMEOUT:100,ctor:function(){this.callBase.apply(this,arguments),EW()},_handler:function(i){let e=$n(i);if(e||(this._skipNextEvents=!0),!(e&&this._mouseLocked)){if(e&&this._skipNextEvents){this._skipNextEvents=!1,this._mouseLocked=!0,clearTimeout(this._unlockMouseTimer);let t=this;this._unlockMouseTimer=setTimeout(function(){t._mouseLocked=!1},this.EVENT_LOCK_TIMEOUT);return}return this.callBase(i)}},_fireEvent:function(i){let e=$n(i.originalEvent)?Qr.normalize:tc.normalize;return this.callBase(m(e(i.originalEvent),i))},dispose:function(){this.callBase(),this._skipNextEvents=!1,this._mouseLocked=!1,clearTimeout(this._unlockMouseTimer)}});R_.map=SW;R_.resetObserver=Qr.resetObserver;var F_=R_;var wW=(i,e)=>{let{tablet:t,phone:n}=e,o=DW();return o||(i.touch&&!(t||n)?F_:i.touch?tc:Qr)},L0=wW(c_,F.real());x(L0.map,(i,e)=>{vi(i,new L0(i,e))});var IW={down:"dxpointerdown",up:"dxpointerup",move:"dxpointermove",cancel:"dxpointercancel",enter:"dxpointerenter",leave:"dxpointerleave",over:"dxpointerover",out:"dxpointerout"};function DW(){let i=fe().pointerEventStrategy;return{"mouse-and-touch":F_,touch:tc,mouse:Qr}[i]}var ne=IW;var TW=ce.inherit({ctor:function(i){this._$element=u(i),this._cancelCallback=ue(),this._acceptCallback=ue()},getElement:function(){return this._$element},validate:function(i){return!Ut(i)},validatePointers:function(i){return f0(i)===1},allowInterruptionByMouseWheel:function(){return!0},configure:function(i){m(this,i)},addCancelCallback:function(i){this._cancelCallback.add(i)},removeCancelCallback:function(){this._cancelCallback.empty()},_cancel:function(i){this._cancelCallback.fire(this,i)},addAcceptCallback:function(i){this._acceptCallback.add(i)},removeAcceptCallback:function(){this._acceptCallback.empty()},_accept:function(i){this._acceptCallback.fire(this,i)},_requestAccept:function(i){this._acceptRequestEvent=i},_forgetAccept:function(){this._accept(this._acceptRequestEvent),this._acceptRequestEvent=null},start:S,move:S,end:S,cancel:S,reset:function(){this._acceptRequestEvent&&this._accept(this._acceptRequestEvent)},_fireEvent:function(i,e,t){let n=m({type:i,originalEvent:e,target:this._getEmitterTarget(e),delegateTarget:this.getElement().get(0)},t);return e=ji(n),e.cancel&&this._cancel(e),e},_getEmitterTarget:function(i){return(this.delegateSelector?u(i.target).closest(this.delegateSelector):this.getElement()).get(0)},dispose:S}),lr=TW;var dr="dxmousewheel";var P_={setup:function(i){let e=u(i);_.on(e,D("wheel","dxWheel"),P_._wheelHandler.bind(P_))},teardown:function(i){_.off(i,".dxWheel")},_wheelHandler:function(i){let{deltaMode:e,deltaY:t,deltaX:n,deltaZ:o}=i.originalEvent;ji({type:dr,originalEvent:i,delta:this._normalizeDelta(t,e),deltaX:n,deltaY:t,deltaZ:o,deltaMode:e,pointerType:"mouse"}),i.stopPropagation()},_normalizeDelta(i){return(arguments.length>1&&arguments[1]!==void 0?arguments[1]:0)===0?-i:-30*i}};vi(dr,P_);var Mh="dxEventManager";var AW=ce.inherit({ctor:function(){this._attachHandlers(),this.reset(),this._proxiedCancelHandler=this._cancelHandler.bind(this),this._proxiedAcceptHandler=this._acceptHandler.bind(this)},_attachHandlers:function(){zt.add(function(){let i=w.getDocument();_.subscribeGlobal(i,D(ne.down,Mh),this._pointerDownHandler.bind(this)),_.subscribeGlobal(i,D(ne.move,Mh),this._pointerMoveHandler.bind(this)),_.subscribeGlobal(i,D([ne.up,ne.cancel].join(" "),Mh),this._pointerUpHandler.bind(this)),_.subscribeGlobal(i,D(dr,Mh),this._mouseWheelHandler.bind(this))}.bind(this))},_eachEmitter:function(i){let e=this._activeEmitters||[],t=0;for(;e.length>t;){let n=e[t];if(i(n)===!1)break;e[t]===n&&t++}},_applyToEmitters:function(i,e){this._eachEmitter(function(t){t[i].call(t,e)})},reset:function(){this._eachEmitter(this._proxiedCancelHandler),this._activeEmitters=[]},resetEmitter:function(i){this._proxiedCancelHandler(i)},_pointerDownHandler:function(i){$n(i)&&i.which>1||this._updateEmitters(i)},_updateEmitters:function(i){this._isSetChanged(i)&&(this._cleanEmitters(i),this._fetchEmitters(i))},_isSetChanged:function(i){let e=this._closestEmitter(i),t=this._emittersSet||[],n=e.length!==t.length;return x(e,function(o,s){return n=n||t[o]!==s,!n}),this._emittersSet=e,n},_closestEmitter:function(i){let e=this,t=[],n=u(i.target);function o(s,r){r&&r.validatePointers(i)&&r.validate(i)&&(r.addCancelCallback(e._proxiedCancelHandler),r.addAcceptCallback(e._proxiedAcceptHandler),t.push(r))}for(;n.length;){let s=$e(n.get(0),"dxEmitter")||[];x(s,o),n=n.parent()}return t},_acceptHandler:function(i,e){let t=this;this._eachEmitter(function(n){n!==i&&t._cancelEmitter(n,e)})},_cancelHandler:function(i,e){this._cancelEmitter(i,e)},_cancelEmitter:function(i,e){let t=this._activeEmitters;e?i.cancel(e):i.reset(),i.removeCancelCallback(),i.removeAcceptCallback();let n=t.indexOf(i);n>-1&&t.splice(n,1)},_cleanEmitters:function(i){this._applyToEmitters("end",i),this.reset(i)},_fetchEmitters:function(i){this._activeEmitters=this._emittersSet.slice(),this._applyToEmitters("start",i)},_pointerMoveHandler:function(i){this._applyToEmitters("move",i)},_pointerUpHandler:function(i){this._updateEmitters(i)},_mouseWheelHandler:function(i){this._allowInterruptionByMouseWheel()&&(i.pointers=[null],this._pointerDownHandler(i),this._adjustWheelEvent(i),this._pointerMoveHandler(i),i.pointers=[],this._pointerUpHandler(i))},_allowInterruptionByMouseWheel:function(){let i=!0;return this._eachEmitter(function(e){return i=e.allowInterruptionByMouseWheel()&&i,i}),i},_adjustWheelEvent:function(i){let e=null;if(this._eachEmitter(function(s){if(!s.gesture)return;let r=s.getDirection(i);if(r!=="horizontal"&&!i.shiftKey||r!=="vertical"&&i.shiftKey)return e=s,!1}),!e)return;let t=e.getDirection(i),o=t==="both"&&!i.shiftKey||t==="vertical"?"pageY":"pageX";i[o]+=i.delta},isActive:function(i){let e=!1;return this._eachEmitter(function(t){e=e||t.getElement().is(i)}),e}}),N0=new AW;var MW=function(i){let e=i.emitter,t=i.events[0],n=i.events;x(n,function(o,s){vi(s,{noBubble:!i.bubble,setup:function(r){let a=$e(r,"dxEmitterSubscription")||{},l=$e(r,"dxEmitter")||{},d=l[t]||new e(r);a[s]=!0,l[t]=d,$e(r,"dxEmitter",l),$e(r,"dxEmitterSubscription",a)},add:function(r,a){$e(r,"dxEmitter")[t].configure(m({delegateSelector:a.selector},a.data),a.type)},teardown:function(r){let a=$e(r,"dxEmitterSubscription"),l=$e(r,"dxEmitter"),d=l[t];delete a[s];let c=!0;x(n,function(h,p){return c=c&&!a[p],c}),c&&(N0.isActive(r)&&N0.resetEmitter(d),d&&d.dispose(),delete l[t])}})})},Wn=MW;var oe="dxclick";var k_=null,nc=null,H0=()=>{nc=null},$0=function(i){let e=i.originalEvent,t=nc===e||e&&e.DXCLICK_FIRED;(!i.which||i.which===1)&&!k_&&!t&&(e&&(e.DXCLICK_FIRED=!0),M0(nc,H0),nc=e,A0(nc,H0),ji({type:"dxclick",originalEvent:i}))},RW=lr.inherit({ctor:function(i){this.callBase(i),_.on(this.getElement(),"click",$0)},start:function(i){k_=null},cancel:function(){k_=!0},dispose:function(){_.off(this.getElement(),"click",$0)}});(function(){if(!F.real().generic){let e=null,t=!1,n=function(d){return u(d).is("input, textarea, select, button ,:focus, :focus *")},o=function(d){e=d.target,t=d.isDefaultPrevented()},s=function(d){let c=qa(d);return u(c)},r=function(d){let c=s(d);!t&&e&&!c.is(e)&&!u(e).is("label")&&n(c)&&zn(),e=null,t=!1},a="NATIVE_CLICK_FIXER",l=w.getDocument();_.subscribeGlobal(l,D(ne.down,a),o),_.subscribeGlobal(l,D("click",a),r)}})();Wn({emitter:RW,bubble:!0,events:["dxclick"]});var Rh=function(i,e){let t=e(i);if($(t))try{return JSON.stringify(t)}catch{return t}return t},PW=function(i,e,t,n){let o=Rh(i,n);return e[t[o]]},z0=function(i,e){if(i.length!==e.length)return!1;for(let t=0;t<e.length;t++)if(i[t]!==e[t])return!1;return!0},Fh=function(i,e,t,n){let o={},s={},r=0,a=0,l=[];i.forEach(function(c,h){let p=Rh(c,t);o[p]=h}),e.forEach(function(c,h){let p=Rh(c,t);s[p]=h});let d=Math.max(i.length,e.length);for(let c=0;c<d+r;c++){let h=e[c],p=c-r+a,g=i[p];if(!h||g&&!PW(g,e,s,t))g&&(l.push({type:"remove",key:t(g),index:c,oldItem:g}),a++,c--);else{let v=Rh(h,t),b=o[v],T=i[b];if(!T)r++,l.push({type:"insert",data:h,index:c});else if(b===p)n(T,h)||l.push({type:"update",data:h,key:t(h),index:c,oldItem:T});else return}}return l};var st=za(he.ERROR_MESSAGES,{E4000:"[DevExpress.data]: {0}",E4001:"Unknown aggregating function is detected: '{0}'",E4002:"Unsupported OData protocol version is used",E4003:"Unknown filter operation is used: {0}",E4004:"The thenby() method is called before the sortby() method",E4005:"Store requires a key expression for this operation",E4006:"ArrayStore 'data' option must be an array",E4007:"Compound keys cannot be auto-generated",E4008:"Attempt to insert an item with a duplicated key",E4009:"Data item cannot be found",E4010:"CustomStore does not support creating queries",E4011:"Custom Store method is not implemented or is not a function: {0}",E4012:"Custom Store method returns an invalid value: {0}",E4013:"Local Store requires the 'name' configuration option is specified",E4014:"Unknown data type is specified for ODataStore: {0}",E4015:"Unknown entity name or alias is used: {0}",E4016:"The compileSetter(expr) method is called with 'self' passed as a parameter",E4017:"Keys cannot be modified",E4018:"The server has returned a non-numeric value in a response to an item count request",E4019:"Mixing of group operators inside a single group of filter expression is not allowed",E4020:"Unknown store type is detected: {0}",E4021:"The server response does not provide the totalCount value",E4022:"The server response does not provide the groupCount value",E4023:"Could not parse the following XML: {0}",E4024:"String function {0} cannot be used with the data field {1} of type {2}.",W4000:"Data returned from the server has an incorrect structure",W4001:'The {0} field is listed in both "keyType" and "fieldTypes". The value of "fieldTypes" is used.',W4002:"Data loading has failed for some cells due to the following error: {0}"}),kW=null,sl=function(i){var e;(e=kW)===null||e===void 0||e(i)};var BW=zt.add,B_="DEVEXTREME_XHR_ERROR_UNLOAD",W0=function(i){return[i[0],i.length<3?"=":String(i[1]).toLowerCase(),i.length<2?!0:i[i.length-1]]},rn=function(i){return Array.isArray(i)||(i=[i]),He(i,function(e){let t={selector:A(e)||typeof e=="string"?e:e.getter||e.field||e.selector,desc:!!(e.desc||String(e.dir).charAt(0).toLowerCase()==="d")};return e.compare&&(t.compare=e.compare),t})},G0=function(){let i={timeout:"Network connection timeout",error:"Unspecified network error",parsererror:"Unexpected server response"},e;return BW(function(){let t=K();w.listen(t,"beforeunload",function(){e=!0})}),function(t,n){return e?B_:t.status<400?function(o){let s=i[o];return s||o}(n):t.statusText}}(),oc={count:{seed:0,step:function(i){return 1+i}},sum:{seed:0,step:function(i,e){return i+e}},min:{step:function(i,e){return e<i?e:i}},max:{step:function(i,e){return e>i?e:i}},avg:{seed:[0,0],step:function(i,e){return[i[0]+e,i[1]+1]},finalize:function(i){return i[1]?i[0]/i[1]:NaN}}},K0=function(){let i=0,e;return{obtain:function(){i===0&&(e=new y),i++},release:function(){i--,i<1&&e.resolve()},promise:function(){return(i===0?new y().resolve():e).promise()},reset:function(){i=0,e&&e.resolve()}}}();function U0(i){return/^(and|&&|&)$/i.test(i)}var fs=function(i,e,t){if(Array.isArray(i)){let n=He(e,function(s,r){return r}),o;for(let s=0;s<n.length;s++)if(o=n[s],!ve(e[o],t[o],{strict:!1}))return!1;return!0}return ve(e,t,{strict:!1})};var j0=function(i){return i[0]==="!"&&Array.isArray(i[1])},VW=function(i){return i==="and"||i==="or"},q0=function(i){if(i.length>2&&Array.isArray(i[0])&&i[1]==="or"&&typeof i[0][0]=="string"&&i[0][1]==="="){let[e]=i[0];return!i.find((t,n)=>n%2!==0?t!=="or":!Array.isArray(t)||t.length!==3||t[0]!==e||t[1]!=="=")}return!1},Y0=function(i){let e=i[0],t=i[1];return!!(Array.isArray(e)||A(e)&&(Array.isArray(t)||A(t)||VW(t)))},cr=function(){let i=new y;return i.resolve.apply(i,arguments).promise()},Ph=function(){let i=new y;return i.reject.apply(i,arguments).promise()};function LW(i,e){let t;return function(){return t||(t=setTimeout(()=>{t=void 0,i.call(this)},A(e)?e():e)),t}}function X0(i,e){let t=[],n=LW(function(){i.call(this,t),t=[]},e);return function(o){return Array.isArray(o)&&t.push(...o),n.call(this,t)}}function NW(i,e){let t,n=typeof e=="string"?e.split():e.slice();for(;n.length;)if(t=n.shift(),t in i)return!0;return!1}function Q0(i,e,t,n){let o,s;if(n){for(let r=0;r<e.length;r++)if(o=e[r].items||e[r].collapsedItems||[],s=Q0(i,o||[],t,n-1),s)return s}else if(_s(i,e,t)>=0)return e}function HW(i,e,t,n){return n?Q0(i,e,t,n)||[]:e}function $W(i,e){if(i.key()&&(!e._dataByKeyMap||e._dataByKeyMapLength!==e.length)){let t={},n=e.length;for(let o=0;o<n;o++)t[JSON.stringify(i.keyOf(e[o]))]=e[o];e._dataByKeyMap=t,e._dataByKeyMapLength=n}}function zW(i,e){if(i._dataByKeyMap)return i._dataByKeyMap[JSON.stringify(e)]}function WW(i,e){return i._dataByKeyMap?i._dataByKeyMap[JSON.stringify(e)]:!0}function Z0(i,e,t){i._dataByKeyMap&&(i._dataByKeyMap[JSON.stringify(e)]=t,i._dataByKeyMapLength+=t?1:-1)}function J0(i,e,t){t=t||new WeakMap;let n=i?Object.create(Object.getPrototypeOf(i)):{};i&&t.set(i,n);let o=I({},i);Bi(n,o,!0,!0);for(let s in o){let r=o[s],a=e?.[s];$(r)&&!q(r)&&$(a)&&!t.has(r)&&(n[s]=J0(r,a,t))}for(let s in n){let r=n[s];$(r)&&t.has(r)&&(n[s]=t.get(r))}return n}function ho(i,e){let t=J0(i,e);return Bi(t,e,!0,!0)}function Gn(i){let{keyInfo:e,data:t,changes:n,groupCount:o,useInsertIndex:s,immutable:r,disableCache:a,logError:l,skipCopying:d}=i,c=r===!0?[...t]:t;return n.forEach(h=>{let p=h.type==="insert"?c:HW(e,c,h.key,o);switch(!a&&$W(e,p),h.type){case"update":sc(e,p,h.key,h.data,!0,r,l);break;case"insert":rc(e,p,h.data,s&&f(h.index)?h.index:-1,!0,l,d);break;case"remove":V_(e,p,h.key,!0,l)}}),c}function kh(i,e,t){return i?e&&st.log(t):Ph(st.Error(t))}function sc(i,e,t,n,o,s,r){let a,l=i.key();if(l){if(NW(n,l)&&!fs(l,t,i.keyOf(n)))return kh(o,r,"E4017");if(a=zW(e,t),!a){let d=_s(i,e,t);if(d<0)return kh(o,r,"E4009");if(a=e[d],s===!0&&f(a)){let c=ho(a,n);return e[d]=c,!o&&cr(c,t)}}}else a=t;if(Bi(a,n,!0),!o)return fe().useLegacyStoreResult?cr(t,n):cr(a,t)}function rc(i,e,t,n,o,s,r){let a,l=i.key(),d=q(t)&&!r?m({},t):t;if(l){if(a=i.keyOf(d),a===void 0||typeof a=="object"&&dt(a)){if(Array.isArray(l))throw st.Error("E4007");a=d[l]=String(new Oe)}else if(e[_s(i,e,a)]!==void 0)return kh(o,s,"E4008")}else a=d;if(n>=0?e.splice(n,0,d):e.push(d),Z0(e,a,d),!o)return cr(fe().useLegacyStoreResult?t:d,a)}function V_(i,e,t,n,o){let s=_s(i,e,t);if(s>-1&&(e.splice(s,1),Z0(e,t,null)),n){if(s<0)return kh(n,o,"E4009")}else return cr(t)}function _s(i,e,t){let n=i.key();if(!WW(e,t))return-1;for(let o=0,s=e.length;o<s;o++)if(fs(n,i.keyOf(e[o]),t))return o;return-1}var ac=ce.inherit({toArray:function(){let i=[];for(this.reset();this.next();)i.push(this.current());return i},countable:function(){return!1}}),$_=ac.inherit({ctor:function(i){this.array=i,this.index=-1},next:function(){return this.index+1<this.array.length?(this.index++,!0):!1},current:function(){return this.array[this.index]},reset:function(){this.index=-1},toArray:function(){return this.array.slice(0)},countable:function(){return!0},count:function(){return this.array.length}}),Bh=ac.inherit({ctor:function(i){this.iter=i},next:function(){return this.iter.next()},current:function(){return this.iter.current()},reset:function(){return this.iter.reset()}}),L_=Bh.inherit({ctor:function(i,e){this.callBase(i),this.index=-1,this.mapper=e},current:function(){return this.mapper(this.callBase(),this.index)},next:function(){let i=this.callBase();return i&&this.index++,i}}),GW=function(i,e,t){return B(i)&&B(e)&&(t!=null&&t.locale||t!=null&&t.collatorOptions)?new Intl.Collator(t?.locale||void 0,t?.collatorOptions||void 0).compare(i,e):(i=Ot(i,!1,t),e=Ot(e,!1,t),i===null&&e!==null?-1:i!==null&&e===null||i===void 0&&e!==void 0?1:i!==void 0&&e===void 0||i<e?-1:i>e?1:0)},N_=ac.inherit({ctor:function(i,e,t,n){this.langParams=i.langParams,i instanceof L_||(i=new L_(i,this._wrap),i.langParams=this.langParams),this.iter=i,this.rules=[{getter:e,desc:t,compare:n,langParams:this.langParams}]},thenBy:function(i,e,t){let n=new N_(this.sortedIter||this.iter,i,e,t);return this.sortedIter||(n.rules=this.rules.concat(n.rules)),n},next:function(){return this._ensureSorted(),this.sortedIter.next()},current:function(){return this._ensureSorted(),this.sortedIter.current()},reset:function(){delete this.sortedIter},countable:function(){return this.sortedIter||this.iter.countable()},count:function(){return this.sortedIter?this.sortedIter.count():this.iter.count()},_ensureSorted:function(){let i=this;i.sortedIter||(x(i.rules,function(){this.getter=me(this.getter)}),i.sortedIter=new L_(new $_(this.iter.toArray().sort(function(e,t){return i._compare(e,t)})),i._unwrap))},_wrap:function(i,e){return{index:e,value:i}},_unwrap:function(i){return i.value},_getDefaultCompare:i=>(e,t)=>GW(e,t,i),_compare:function(i,e){let t=i.index,n=e.index;if(i=i.value,e=e.value,i===e)return t-n;for(let o=0,s=this.rules.length;o<s;o++){let r=this.rules[o],a=r.getter(i),l=r.getter(e),c=(r.compare||this._getDefaultCompare(r.langParams))(a,l);if(c)return r.desc?-c:c}return t-n}}),H_=function(){let i={},e=r=>Ot(r,!1,i),t=function(r){if(q0(r))return(c=>{let h=me(c[0][0]),p=c.reduce((g,C,v)=>(v%2===0&&g.push(e(C[2])),g),[]);return g=>{let C=e(h(g));return p.some(v=>s(v)?C===v:C==v)}})(r);let a=[],l=!1,d=!1;return x(r,function(){if(Array.isArray(this)||A(this)){if(a.length>1&&l!==d)throw new st.Error("E4019");a.push(H_(this,i)),l=d,d=!0}else d=U0(this)}),function(c){let h=l;for(let p=0;p<a.length;p++)if(a[p](c)!==l){h=!l;break}return h}},n=function(r){var a;return f(r)?(a=i)!==null&&a!==void 0&&a.locale?r.toLocaleString(i.locale):r.toString():""};function o(r,a,l){return function(d){d=e(r(d));let c=s(a)?d===a:d==a;return l&&(c=!c),c}}function s(r){return r===""||r===0||r===!1}return function(r,a){return i=a||{},A(r)?r:Y0(r)?t(r):j0(r)?function(l){let d=l[0],c=H_(l[1],i);if(d==="!")return function(h){return!c(h)};throw st.Error("E4003",d)}(r):function(l){l=W0(l);let d=me(l[0]),c=l[1],h=l[2];h=e(h);let p=(g,C)=>(g=e(d(g)),(h==null||g==null)&&h!==g?!1:C(g,h));switch(c.toLowerCase()){case"=":return o(d,h);case"<>":return o(d,h,!0);case">":return g=>p(g,(C,v)=>C>v);case"<":return g=>p(g,(C,v)=>C<v);case">=":return g=>p(g,(C,v)=>C>=v);case"<=":return g=>p(g,(C,v)=>C<=v);case"startswith":return function(g){return e(n(d(g))).indexOf(h)===0};case"endswith":return function(g){let C=e(n(d(g))),v=n(h);if(C.length<v.length)return!1;let b=C.lastIndexOf(h);return b!==-1&&b===C.length-h.length};case"contains":return function(g){return e(n(d(g))).indexOf(h)>-1};case"notcontains":return function(g){return e(n(d(g))).indexOf(h)===-1}}throw st.Error("E4003",c)}(r)}}(),KW=Bh.inherit({ctor:function(i,e){this.callBase(i),this.langParams=i.langParams,this.criteria=H_(e,this.langParams)},next:function(){for(;this.iter.next();)if(this.criteria(this.current()))return!0;return!1}}),UW=ac.inherit({ctor:function(i,e){this.iter=i,this.getter=e},next:function(){return this._ensureGrouped(),this.groupedIter.next()},current:function(){return this._ensureGrouped(),this.groupedIter.current()},reset:function(){delete this.groupedIter},countable:function(){return!!this.groupedIter},count:function(){return this.groupedIter.count()},_ensureGrouped:function(){if(this.groupedIter)return;let i={},e=[],t=this.iter,n=me(this.getter);for(t.reset();t.next();){let o=t.current(),s=n(o);s in i?i[s].push(o):(i[s]=[o],e.push(s))}this.groupedIter=new $_(He(e,function(o){return{key:o,items:i[o]}}))}}),jW=Bh.inherit({ctor:function(i,e){this.callBase(i),this.getter=me(e)},current:function(){return this.getter(this.callBase())},countable:function(){return this.iter.countable()},count:function(){return this.iter.count()}}),qW=Bh.inherit({ctor:function(i,e,t){this.callBase(i),this.skip=Math.max(0,e),this.take=Math.max(0,t),this.pos=0},next:function(){if(this.pos>=this.skip+this.take)return!1;for(;this.pos<this.skip&&this.iter.next();)this.pos++;return this.pos++,this.iter.next()},reset:function(){this.callBase(),this.pos=0},countable:function(){return this.iter.countable()},count:function(){return Math.min(this.iter.count()-this.skip,this.take)}}),eI=function(i,e){e=e||{},i instanceof ac||(i=new $_(i)),e.langParams&&(i.langParams=e.langParams);let t=function(l){let d=e.errorHandler;d&&d(l),sl(l)},n=function(l){let d=new y().fail(t),c,h=l.step,p=l.finalize;try{i.reset(),"seed"in l?c=l.seed:c=i.next()?i.current():NaN;let g=c;for(;i.next();)g=h(g,i.current());d.resolve(p?p(g):g)}catch(g){d.reject(g)}return d.promise()},o=function(l){return n(oc[l])},s=function(l){return!A(l)&&!Array.isArray(l)&&(l=[].slice.call(arguments)),a(new jW(i,l))},r=function(l){return s(me(l))};function a(l){return eI(l,e)}return{toArray:function(){return i.toArray()},enumerate:function(){let l=new y().fail(t);try{l.resolve(i.toArray())}catch(d){l.reject(d)}return l.promise()},setLangParams(l){i.langParams=l},sortBy:function(l,d,c){return a(new N_(i,l,d,c))},thenBy:function(l,d,c){if(i instanceof N_)return a(i.thenBy(l,d,c));throw st.Error("E4004")},filter:function(l){return Array.isArray(l)||(l=[].slice.call(arguments)),a(new KW(i,l))},slice:function(l,d){return d===void 0&&(d=Number.MAX_VALUE),a(new qW(i,l,d))},select:s,groupBy:function(l){return a(new UW(i,l))},aggregate:function(l,d,c){return arguments.length<2?n({step:arguments[0]}):n({seed:l,step:d,finalize:c})},count:function(){if(i.countable()){let l=new y().fail(t);try{l.resolve(i.count())}catch(d){l.reject(d)}return l.promise()}return o("count")},sum:function(l){return l?r(l).sum():o("sum")},min:function(l){return l?r(l).min():o("min")},max:function(l){return l?r(l).max():o("max")},avg:function(l){return l?r(l).avg():o("avg")}}},ur=eI;function z_(i,e){return i=i.groupBy(e[0].selector),e.length>1&&(i=i.select(function(t){return m({},t,{items:z_(ur(t.items),e.slice(1)).toArray()})})),i}function tI(i,e){let t=[];return x(i,function(n,o){xt(e,function(r){return o.selector===r.selector}).length<1&&t.push(o)}),t.concat(e)}function YW(i,e,t){var n;e=e||{};let o=e.filter;if((n=e)!==null&&n!==void 0&&n.langParams){var s,r;(s=(r=i).setLangParams)===null||s===void 0||s.call(r,e.langParams)}if(o&&(i=i.filter(o)),t)return i;let a=e.sort,l=e.select,d=e.group,c=e.skip,h=e.take;return d&&(d=rn(d),d.keepInitialKeyOrder=!!e.group.keepInitialKeyOrder),(a||d)&&(a=rn(a||[]),d&&!d.keepInitialKeyOrder&&(a=tI(d,a)),x(a,function(p){i=i[p?"thenBy":"sortBy"](this.selector,this.desc,this.compare)})),l&&(i=i.select(l)),d&&(i=z_(i,d)),(h||c)&&(i=i.slice(c||0,h)),i}var qi={multiLevelGroup:z_,arrangeSortingInfo:tI,queryByOptions:YW};var lc=ce.abstract,iI=qi.queryByOptions,W_={},rl=ce.inherit({_langParams:{},ctor:function(i){let e=this;i=i||{},this._eventsStrategy=new Ln(this),x(["onLoaded","onLoading","onInserted","onInserting","onUpdated","onUpdating","onPush","onRemoved","onRemoving","onModified","onModifying"],function(t,n){n in i&&e.on(n.slice(2).toLowerCase(),i[n])}),this._key=i.key,this._errorHandler=i.errorHandler,this._useDefaultSearch=!0},_clearCache:S,_customLoadOptions:function(){return null},key:function(){return this._key},keyOf:function(i){return this._keyGetter||(this._keyGetter=me(this.key())),this._keyGetter(i)},_requireKey:function(){if(!this.key())throw st.Error("E4005")},load:function(i){let e=this;return i=i||{},this._eventsStrategy.fireEvent("loading",[i]),this._withLock(this._loadImpl(i)).done(function(t){e._eventsStrategy.fireEvent("loaded",[t,i])})},_loadImpl:function(i){return dt(this._langParams)||(i=i||{},i._langParams=I({},this._langParams,i._langParams)),iI(this.createQuery(i),i).enumerate()},_withLock:function(i){let e=new y;return i.done(function(){let t=this,n=arguments;K0.promise().done(function(){e.resolveWith(t,n)})}).fail(function(){e.rejectWith(this,arguments)}),e},createQuery:lc,totalCount:function(i){return this._totalCountImpl(i)},_totalCountImpl:function(i){return iI(this.createQuery(i),i,!0).count()},byKey:function(i,e){return this._addFailHandlers(this._withLock(this._byKeyImpl(i,e)))},_byKeyImpl:lc,insert:function(i){let e=this;return e._eventsStrategy.fireEvent("modifying"),e._eventsStrategy.fireEvent("inserting",[i]),e._addFailHandlers(e._insertImpl(i).done(function(t,n){e._eventsStrategy.fireEvent("inserted",[t,n]),e._eventsStrategy.fireEvent("modified")}))},_insertImpl:lc,update:function(i,e){let t=this;return t._eventsStrategy.fireEvent("modifying"),t._eventsStrategy.fireEvent("updating",[i,e]),t._addFailHandlers(t._updateImpl(i,e).done(function(){t._eventsStrategy.fireEvent("updated",[i,e]),t._eventsStrategy.fireEvent("modified")}))},_updateImpl:lc,push:function(i){let e={changes:i,waitFor:[]};this._eventsStrategy.fireEvent("beforePushAggregation",[e]),P(...e.waitFor).done(()=>{this._pushImpl(i),this._eventsStrategy.fireEvent("beforePush",[{changes:i}]),this._eventsStrategy.fireEvent("push",[i])})},_pushImpl:S,remove:function(i){let e=this;return e._eventsStrategy.fireEvent("modifying"),e._eventsStrategy.fireEvent("removing",[i]),e._addFailHandlers(e._removeImpl(i).done(function(t){e._eventsStrategy.fireEvent("removed",[t]),e._eventsStrategy.fireEvent("modified")}))},_removeImpl:lc,_addFailHandlers:function(i){return i.fail(this._errorHandler).fail(sl)},on(i,e){return this._eventsStrategy.on(i,e),this},off(i,e){return this._eventsStrategy.off(i,e),this}});rl.create=function(i,e){if(!(i in W_))throw st.Error("E4020",i);return new W_[i](e)};rl.registerClass=function(i,e){return e&&(W_[e]=i),i};rl.inherit=function(i){return function(e,t){let n=i.apply(this,[e]);return rl.registerClass(n,t),n}}(rl.inherit);var Cs=rl;var aI="totalCount",G_="load",lI="byKey",nI="insert",oI="update",sI="remove";function al(i){return i&&A(i.then)}function Jr(i){return new y().resolve(i).promise()}function dc(i,e){if(!A(e))throw st.Error("E4011",i)}function dI(i){throw st.Error("E4012",i)}function Zr(i){return function(e){let t;e instanceof Error?t=e:t=new Error(function(n){let o=n[0],s=n[1];return!o||!o.getResponseHeader?null:G0(o,s)}(arguments)||e&&String(e)||"Unknown error"),t.message!==B_&&i.reject(t)}}function cI(i,e){let t=i._loadFunc,n;return dc(G_,t),n=t.apply(i,[e]),Array.isArray(n)?n=Jr(n):n==null?n=Jr([]):al(n)||dI(G_),ht(n)}function XW(i,e){let t=i._totalCountFunc,n;if(!A(t))throw st.Error("E4021");return n=t.apply(i,[e]),al(n)||(n=Number(n),isFinite(n)||dI(aI),n=Jr(n)),ht(n)}function QW(i,e,t){let n=i._byKeyFunc,o;return dc(lI,n),o=n.apply(i,[e,t]),al(o)||(o=Jr(o)),ht(o)}function uI(i,e,t,n){if(e.__rawData)n(e.__rawData);else{let o=e.__rawDataPromise||cI(e,t);e._cacheRawData&&(e.__rawDataPromise=o),o.always(function(){delete e.__rawDataPromise}).done(function(s){e._cacheRawData&&(e.__rawData=s),n(s)}).fail(s=>{var r;let a=Zr(i);(r=e._errorHandler)===null||r===void 0||r.call(e,s),a(s)})}}function rI(i,e,t,n){t=t||{};let o={};"userData"in t&&(o.userData=t.userData),uI(i,e,o,function(s){let r=ur(s,{errorHandler:e._errorHandler}),a,l,d=[],c,h;n||(a=qi.queryByOptions(r,t),a===r?c=s.slice(0):d.push(a.enumerate().done(function(p){c=p}))),(t.requireTotalCount||n)&&(l=qi.queryByOptions(r,t,!0),l===r?h=s.length:d.push(l.count().done(function(p){h=p}))),P.apply(u,d).done(function(){n?i.resolve(h):t.requireTotalCount?i.resolve(c,{totalCount:h}):i.resolve(c)}).fail(function(p){i.reject(p)})})}function ZW(i,e,t){uI(i,e,{},function(n){let o=e.key(),s;for(let r=0,a=n.length;r<a;r++)if(s=n[r],fs(o,e.keyOf(n[r]),t)){i.resolve(s);return}i.reject(st.Error("E4009"))})}var JW=Cs.inherit({ctor:function(i){i=i||{},this.callBase(i),this._useDefaultSearch=!!i.useDefaultSearch||i.loadMode==="raw",this._loadMode=i.loadMode,this._cacheRawData=i.cacheRawData!==!1,this._loadFunc=i[G_],this._totalCountFunc=i[aI],this._byKeyFunc=i[lI],this._insertFunc=i[nI],this._updateFunc=i[oI],this._removeFunc=i[sI]},_clearCache(){delete this.__rawData},createQuery:function(){throw st.Error("E4010")},clearRawDataCache:function(){this._clearCache()},_totalCountImpl:function(i){let e=new y;return this._loadMode==="raw"&&!this._totalCountFunc?rI(e,this,i,!0):(XW(this,i).done(function(t){e.resolve(Number(t))}).fail(Zr(e)),e=this._addFailHandlers(e)),e.promise()},_pushImpl:function(i){this.__rawData&&Gn({keyInfo:this,data:this.__rawData,changes:i})},_loadImpl:function(i){let e=new y;return this._loadMode==="raw"?rI(e,this,i,!1):(cI(this,i).done(function(t,n){e.resolve(t,n)}).fail(Zr(e)),e=this._addFailHandlers(e)),e.promise()},_byKeyImpl:function(i,e){let t=new y;return this._byKeyViaLoad()?(this._requireKey(),ZW(t,this,i)):QW(this,i,e).done(function(n){t.resolve(n)}).fail(Zr(t)),t.promise()},_byKeyViaLoad:function(){return this._loadMode==="raw"&&!this._byKeyFunc},_insertImpl:function(i){let e=this,t=e._insertFunc,n,o=new y;return dc(nI,t),n=t.apply(e,[i]),al(n)||(n=Jr(n)),ht(n).done(function(s){fe().useLegacyStoreResult?o.resolve(i,s):o.resolve(s||i,e.keyOf(s))}).fail(Zr(o)),o.promise()},_updateImpl:function(i,e){let t=this._updateFunc,n,o=new y;return dc(oI,t),n=t.apply(this,[i,e]),al(n)||(n=Jr(n)),ht(n).done(function(s){fe().useLegacyStoreResult?o.resolve(i,e):o.resolve(s||e,i)}).fail(Zr(o)),o.promise()},_removeImpl:function(i){let e=this._removeFunc,t,n=new y;return dc(sI,e),t=e.apply(this,[i]),al(t)||(t=Jr()),ht(t).done(function(){n.resolve(i)}).fail(Zr(n)),n.promise()}}),ea=JW;function K_(i){let e=[],t=!1;function n(){for(;e.length;){t=!0;let s=e.shift()();if(s!==void 0){if(s.then){P(s).always(n);return}throw he.Error("E0015")}}t=!1}return{add:function(o,s){i?(e[0]&&s&&s(e[0]),e=[o]):e.push(o),t||n()},busy:function(){return t}}}var bae=K_().add;function ge(i,e){if(i==null)return{};var t={};for(var n in i)if({}.hasOwnProperty.call(i,n)){if(e.indexOf(n)!==-1)continue;t[n]=i[n]}return t}var hI={};var pI=function(i,e,t){t=t||[],e=e||{};let n=function(r,a){return{name:r,args:a}},o=function(r){let a=new y,l,d,c,h,p,g=function(v){let b=e.errorHandler;b&&b(v),sl(v),a.reject(v)};function C(v){switch(v.name){case"sortBy":return p=[v.args],!0;case"thenBy":if(!p)throw st.Error("E4004");return p.push(v.args),!0}return!1}try{l=e.adapter,A(l)||(l=hI[l]),d=l(e),c=[].concat(t).concat(r);let v=d.optimize;for(v&&v(c);c.length;){if(h=c[0],!C(h)){if(p){c.unshift(n("multiSort",[p])),p=null;continue}if(String(h.name)!=="enumerate"&&(!d[h.name]||d[h.name].apply(d,h.args)===!1))break}c.shift()}(function(){let b=c[0],T=[];b&&b.name==="multiSort"&&(c.shift(),x(b.args[0],function(){T.push(n(T.length?"thenBy":"sortBy",this))})),c=T.concat(c)})(),d.exec(i).done(function(b,T){if(!c.length)a.resolve(b,T);else{let R=ur(b,{errorHandler:e.errorHandler});x(c,function(){R=R[this.name].apply(R,this.args)}),R.done(a.resolve).fail(a.reject)}}).fail(g)}catch(v){g(v)}return a.promise()},s={};return x(["sortBy","thenBy","filter","slice","select","groupBy"],function(){let r=String(this);s[r]=function(){return pI(i,e,t.concat(n(r,arguments)))}}),x(["count","min","max","sum","avg","aggregate","enumerate"],function(){let r=String(this);s[r]=function(){return o.call(this,n(r,arguments))}}),s},gI=pI;var mI={array:ur,remote:gI};var eG=function(){let i=Array.isArray(arguments[0])?"array":"remote";return mI[i].apply(this,arguments)},vt=eG;var tG=Cs.inherit({ctor:function(i){Array.isArray(i)?i={data:i}:i=i||{},this.callBase(i);let e=i.data;if(e&&!Array.isArray(e))throw st.Error("E4006");this._array=e||[]},createQuery:function(){return vt(this._array,{errorHandler:this._errorHandler})},_byKeyImpl:function(i){let e=_s(this,this._array,i);return e===-1?Ph(st.Error("E4009")):cr(this._array[e])},_insertImpl:function(i){return rc(this,this._array,i)},_pushImpl:function(i){Gn({keyInfo:this,data:this._array,changes:i})},_updateImpl:function(i,e){return sc(this,this._array,i,e)},_removeImpl:function(i){return V_(this,this._array,i)},clear:function(){this._eventsStrategy.fireEvent("modifying"),this._array=[],this._eventsStrategy.fireEvent("modified")}},"array"),No=tG;var iG=["items"],Vh="canceled",U_=i=>i.state()==="pending",j_=i=>{switch(i.length){case 0:return;case 1:return i[0]}return[].slice.call(i)},nG=(i,e,t)=>He(i,n=>{let o=ge(n,iG);return I({},o,{items:fI(n.items,e-1,t)})}),fI=(i,e,t)=>Array.isArray(i)?e?nG(i,e,t):He(i,t):i,_I=(i,e,t)=>{let n=t?rn(t).length:0;return fI(i,n,e)},Lh=(i,e)=>{var t;return(t=i)!==null&&t!==void 0&&t.data&&(e=i,i=i.data),Array.isArray(i)||(i=[i]),{data:i,extra:e}},oG=i=>{let e={};return x(["useDefaultSearch","key","load","loadMode","cacheRawData","byKey","lookup","totalCount","insert","update","remove"],function(){e[this]=i[this],delete i[this]}),new ea(e)},sG=i=>{let e=i.type;return delete i.type,Cs.create(e,i)},rG=(i,e)=>new ea({load:()=>Zf.sendRequest({url:i,dataType:"json"}),loadMode:e?.fromUrlLoadMode}),Yi=(i,e)=>{let t;return typeof i=="string"&&(i={paginate:!1,store:rG(i,e)}),i===void 0&&(i=[]),Array.isArray(i)||i instanceof Cs?i={store:i}:i=m({},i),i.store===void 0&&(i.store=[]),t=i.store,"load"in i?t=oG(i):Array.isArray(t)?t=new No(t):q(t)&&(t=sG(m({},t))),i.store=t,i};var Nh=class{constructor(){this._counter=-1,this._deferreds={}}add(e){return this._counter++,this._deferreds[this._counter]=e,this._counter}remove(e){return delete this._deferreds[e]}cancel(e){return e in this._deferreds?(this._deferreds[e].reject(Vh),!0):!1}cancelAll(){for(;this._counter>-1;)this.cancel(this._counter),this._counter--}};var jt=ce.inherit({ctor(i){if(i=Yi(i),this._eventsStrategy=new Ln(this,{syncStrategy:!0}),this._store=i.store,this._changedTime=0,i.pushAggregationTimeout!==0){let t=i.pushAggregationTimeout===void 0?()=>5*this._changedTime:i.pushAggregationTimeout,n,o,s=X0(r=>{n.resolve(),P(...o).done(()=>this._onPush(r)),o=void 0,n=void 0},t);this._onPushHandler=r=>{this._aggregationTimeoutId=s(r.changes),n||(n=new y),o=r.waitFor,r.waitFor.push(n.promise())},this._store.on("beforePushAggregation",this._onPushHandler)}else this._onPushHandler=t=>this._onPush(t),this._store.on("push",this._onPushHandler);this._storeLoadOptions=this._extractLoadOptions(i),this._mapFunc=i.map,this._postProcessFunc=i.postProcess,this._pageIndex=i.pageIndex!==void 0?i.pageIndex:0,this._pageSize=i.pageSize!==void 0?i.pageSize:20,this._loadingCount=0,this._loadQueue=this._createLoadQueue(),this._searchValue="searchValue"in i?i.searchValue:null,this._searchOperation=i.searchOperation||"contains",this._searchExpr=i.searchExpr,this._paginate=i.paginate,this._reshapeOnPush=i.reshapeOnPush??!1,x(["onChanged","onLoadError","onLoadingChanged","onCustomizeLoadResult","onCustomizeStoreLoadOptions"],(t,n)=>{n in i&&this.on(n.substr(2,1).toLowerCase()+n.substr(3),i[n])}),this._operationManager=new Nh,this._init()},_init(){this._items=[],this._userData={},this._totalCount=-1,this._isLoaded=!1,f(this._paginate)||(this._paginate=!this.group()),this._isLastPage=!this._paginate},dispose(){var i;this._store.off("beforePushAggregation",this._onPushHandler),this._store.off("push",this._onPushHandler),this._eventsStrategy.dispose(),clearTimeout(this._aggregationTimeoutId),(i=this._delayedLoadTask)===null||i===void 0||i.abort(),this._operationManager.cancelAll(),delete this._store,delete this._items,delete this._delayedLoadTask,this._disposed=!0},_extractLoadOptions(i){let e={},t=["sort","filter","langParams","select","group","requireTotalCount"],n=this._store._customLoadOptions();return n&&(t=t.concat(n)),x(t,function(){e[this]=i[this]}),e},loadOptions(){return this._storeLoadOptions},items(){return this._items},pageIndex(i){if(!xe(i))return this._pageIndex;this._pageIndex=i,this._isLastPage=!this._paginate},paginate(i){if(!Qs(i))return this._paginate;this._paginate!==i&&(this._paginate=i,this.pageIndex(0))},pageSize(i){if(!xe(i))return this._pageSize;this._pageSize=i},isLastPage(){return this._isLastPage},generateStoreLoadOptionAccessor(i){return e=>{let t=j_(e);if(t===void 0)return this._storeLoadOptions[i];this._storeLoadOptions[i]=t}},sort(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return this.generateStoreLoadOptionAccessor("sort")(e)},filter(){let i=j_(arguments);if(i===void 0)return this._storeLoadOptions.filter;this._storeLoadOptions.filter=i,this.pageIndex(0)},group(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return this.generateStoreLoadOptionAccessor("group")(e)},select(){for(var i=arguments.length,e=new Array(i),t=0;t<i;t++)e[t]=arguments[t];return this.generateStoreLoadOptionAccessor("select")(e)},requireTotalCount(i){if(!Qs(i))return this._storeLoadOptions.requireTotalCount;this._storeLoadOptions.requireTotalCount=i},searchValue(i){if(arguments.length<1)return this._searchValue;this._searchValue=i,this.pageIndex(0)},searchOperation(i){if(!B(i))return this._searchOperation;this._searchOperation=i,this.pageIndex(0)},searchExpr(i){let e=arguments.length;if(e===0)return this._searchExpr;e>1&&(i=[].slice.call(arguments)),this._searchExpr=i,this.pageIndex(0)},store(){return this._store},key(){var i;return(i=this._store)===null||i===void 0?void 0:i.key()},totalCount(){return this._totalCount},isLoaded(){return this._isLoaded},isLoading(){return this._loadingCount>0},beginLoading(){this._changeLoadingCount(1)},endLoading(){this._changeLoadingCount(-1)},_createLoadQueue:()=>K_(),_changeLoadingCount(i){let e=this.isLoading();this._loadingCount+=i;let t=this.isLoading();e^t&&this._eventsStrategy.fireEvent("loadingChanged",[t])},_scheduleLoadCallbacks(i){this.beginLoading(),i.always(()=>{this.endLoading()})},_scheduleFailCallbacks(i){var e=this;i.fail(function(){for(var t=arguments.length,n=new Array(t),o=0;o<t;o++)n[o]=arguments[o];n[0]!==Vh&&e._eventsStrategy.fireEvent("loadError",n)})},_fireChanged(i){let e=new Date;this._eventsStrategy.fireEvent("changed",i),this._changedTime=new Date-e},_scheduleChangedCallbacks(i){i.done(()=>this._fireChanged())},loadSingle(i,e){let t=new y,n=this.key(),o=this._store,s=this._createStoreLoadOptions();return this._scheduleFailCallbacks(t),arguments.length<2&&(e=i,i=n),delete s.skip,delete s.group,delete s.refresh,delete s.pageIndex,delete s.searchString,(i===n||o instanceof ea&&!o._byKeyViaLoad()?o.byKey(e,s):(s.take=1,s.filter=s.filter?[s.filter,[i,e]]:[i,e],o.load(s))).fail(t.reject).done(r=>{let a=Array.isArray(r)&&!r.length;!f(r)||a?t.reject(new st.Error("E4009")):(Array.isArray(r)||(r=[r]),t.resolve(this._applyMapFunction(r)[0]))}),t.promise()},load(){let i=new y,e=()=>{if(!this._disposed&&U_(i))return this._loadFromStore(t,i)};this._scheduleLoadCallbacks(i),this._scheduleFailCallbacks(i),this._scheduleChangedCallbacks(i);let t=this._createLoadOperation(i);return this._eventsStrategy.fireEvent("customizeStoreLoadOptions",[t]),this._loadQueue.add(()=>(typeof t.delay=="number"?this._delayedLoadTask=Ua(e,t.delay):e(),i.promise())),i.promise({operationId:t.operationId})},_onPush(i){if(this._reshapeOnPush)this.load();else{let e={changes:i};this._eventsStrategy.fireEvent("changing",[e]);let t=this.group(),n=this.items(),o=0,s=this.paginate()||t?i.filter(r=>r.type==="update"):i;t&&(o=Array.isArray(t)?t.length:1),this._mapFunc&&s.forEach(r=>{r.type==="insert"&&(r.data=this._mapFunc(r.data))}),e.postProcessChanges&&(s=e.postProcessChanges(s)),Gn({keyInfo:this.store(),data:n,changes:s,groupCount:o,useInsertIndex:!0}),this._fireChanged([{changes:i}])}},_createLoadOperation(i){let e=this._operationManager.add(i),t=this._createStoreLoadOptions();return this._store&&!dt(t?.langParams)&&(this._store._langParams=I({},this._store._langParams,t.langParams)),i.always(()=>this._operationManager.remove(e)),{operationId:e,storeLoadOptions:t}},reload(){return this.store()._clearCache(),this._init(),this.load()},cancel(i){return this._operationManager.cancel(i)},cancelAll(){return this._operationManager.cancelAll()},_addSearchOptions(i){this._disposed||(this.store()._useDefaultSearch?this._addSearchFilter(i):(i.searchOperation=this._searchOperation,i.searchValue=this._searchValue,i.searchExpr=this._searchExpr))},_createStoreLoadOptions(){let i=m({},this._storeLoadOptions);return this._addSearchOptions(i),this._paginate&&this._pageSize&&(i.skip=this._pageIndex*this._pageSize,i.take=this._pageSize),i.userData=this._userData,i},_addSearchFilter(i){let e=this._searchValue,t=this._searchOperation,n=this._searchExpr,o=[];e&&(n||(n="this"),Array.isArray(n)||(n=[n]),x(n,function(s,r){o.length&&o.push("or"),o.push([r,t,e])}),i.filter?i.filter=[o,i.filter]:i.filter=o)},_loadFromStore(i,e){let t=(n,o)=>{if(this._disposed||!U_(e))return;let s=m(Lh(n,o),i);this._eventsStrategy.fireEvent("customizeLoadResult",[s]),P(s.data).done(r=>{s.data=r,this._processStoreLoadResult(s,e)}).fail(e.reject)};return i.data?new y().resolve(i.data).done(t):this.store().load(i.storeLoadOptions).done(t).fail(e.reject)},_processStoreLoadResult(i,e){let t=i.data,n=i.extra,o=i.storeLoadOptions,s=()=>(this._isLoaded=!0,this._totalCount=isFinite(n.totalCount)?n.totalCount:-1,e.resolve(t,n)),r=()=>{this.store().totalCount(o).done(function(a){n.totalCount=a,s()}).fail(e.reject)};this._disposed||(t=this._applyPostProcessFunction(this._applyMapFunction(t)),$(n)||(n={}),this._items=t,(!t.length||!this._paginate||this._pageSize&&t.length<this._pageSize)&&(this._isLastPage=!0),o.requireTotalCount&&!isFinite(n.totalCount)?r():s())},_applyMapFunction(i){return this._mapFunc?_I(i,this._mapFunc,this.group()):i},_applyPostProcessFunction(i){return this._postProcessFunc?this._postProcessFunc(i):i},on(i,e){return this._eventsStrategy.on(i,e),this},off(i,e){return this._eventsStrategy.off(i,e),this}});var Z=za(he.ERROR_MESSAGES,{E1001:"Module '{0}'. Controller '{1}' is already registered",E1002:"Module '{0}'. Controller '{1}' does not inherit from DevExpress.ui.dxDataGrid.Controller",E1003:"Module '{0}'. View '{1}' is already registered",E1004:"Module '{0}'. View '{1}' does not inherit from DevExpress.ui.dxDataGrid.View",E1005:"Public method '{0}' is already registered",E1006:"Public method '{0}.{1}' does not exist",E1007:"State storing cannot be provided due to the restrictions of the browser",E1010:"The template does not contain the TextBox widget",E1011:'Items cannot be deleted from the List. Implement the "remove" function in the data store',E1012:"Editing type '{0}' with the name '{1}' is unsupported",E1016:"Unexpected type of data source is provided for a lookup column",E1018:"The 'collapseAll' method cannot be called if you use a remote data source",E1019:"Search mode '{0}' is unavailable",E1020:"The type cannot be changed after initialization",E1021:"{0} '{1}' you are trying to remove does not exist",E1022:'The "markers" option is given an invalid value. Assign an array instead',E1023:'The "routes" option is given an invalid value. Assign an array instead',E1025:"This layout is too complex to render",E1026:'The "calculateCustomSummary" function is missing from a field whose "summaryType" option is set to "custom"',E1031:"Unknown subscription in the Scheduler widget: '{0}'",E1032:"Unknown start date in an appointment: '{0}'",E1033:"Unknown step in the date navigator: '{0}'",E1034:"The browser does not implement an API for saving files",E1035:"The editor cannot be created: {0}",E1037:"Invalid structure of grouped data",E1038:"The browser does not support local storages for local web pages",E1039:"A cell's position cannot be calculated",E1040:"The '{0}' key value is not unique within the data array",E1041:"The '{0}' script is referenced after the DevExtreme scripts or not referenced at all",E1042:"{0} requires the key field to be specified",E1043:"Changes cannot be processed due to the incorrectly set key",E1044:"The key field specified by the keyExpr option does not match the key field specified in the data store",E1045:"Editing requires the key field to be specified in the data store",E1046:"The '{0}' key field is not found in data objects",E1047:'The "{0}" field is not found in the fields array',E1048:'The "{0}" operation is not found in the filterOperations array',E1049:"Column '{0}': filtering is allowed but the 'dataField' or 'name' option is not specified",E1050:"The validationRules option does not apply to third-party editors defined in the editCellTemplate",E1051:`HtmlEditor's valueType is "{0}", but the {0} converter was not imported.`,E1052:'{0} should have the "dataSource" option specified',E1053:'The "buttons" option accepts an array that contains only objects or string values',E1054:"All text editor buttons must have names",E1055:'One or several text editor buttons have invalid or non-unique "name" values',E1056:'The {0} widget does not support buttons of the "{1}" type',E1058:'The "startDayHour" and "endDayHour" options must be integers in the [0, 24] range, with "endDayHour" being greater than "startDayHour".',E1059:"The following column names are not unique: {0}",E1060:"All editable columns must have names",E1061:'The "offset" option must be an integer in the [-1440, 1440] range, divisible by 5 without a remainder.',E1062:'The "cellDuration" must be a positive integer, evenly dividing the ("endDayHour" - "startDayHour") interval into minutes.',W1001:'The "key" option cannot be modified after initialization',W1002:"An item with the key '{0}' does not exist",W1003:"A group with the key '{0}' in which you are trying to select items does not exist",W1004:"The item '{0}' you are trying to select in the group '{1}' does not exist",W1005:"Due to column data types being unspecified, data has been loaded twice in order to apply initial filter settings. To resolve this issue, specify data types for all grid columns.",W1006:"The map service returned the following error: '{0}'",W1007:"No item with key {0} was found in the data source, but this key was used as the parent key for item {1}",W1008:"Cannot scroll to the '{0}' date because it does not exist on the current view",W1009:"Searching works only if data is specified using the dataSource option",W1010:"The capability to select all items works with source data of plain structure only",W1011:'The "keyExpr" option is not applied when dataSource is not an array',W1012:"The '{0}' key field is not found in data objects",W1013:'The "message" field in the dialog component was renamed to "messageHtml". Change your code correspondingly. In addition, if you used HTML code in the message, make sure that it is secure',W1014:"The Floating Action Button exceeds the recommended speed dial action count. If you need to display more speed dial actions, increase the maxSpeedDialActionCount option value in the global config.",W1016:"The '{0}' field in the HTML Editor toolbar item configuration was renamed to '{1}'. Please make a corresponding change in your code.",W1017:"The 'key' property is not specified for a lookup data source. Please specify it to prevent requests for the entire dataset when users filter data.",W1018:"Infinite scrolling may not work properly with multiple selection. To use these features together, set 'selection.deferred' to true or set 'selection.selectAllMode' to 'page'.",W1019:"Filter query string exceeds maximum length limit of {0} characters.",W1020:"hideEvent is ignored when the shading property is true",W1021:`The '{0}' is not rendered because none of the DOM elements match the value of the "container" property.`,W1022:"{0} JSON parsing error: '{1}'",W1023:"Appointments require unique keys. Otherwise, the agenda view may not work correctly.",W1024:"The client-side export is enabled. Implement the 'onExporting' function.",W1025:"'scrolling.mode' is set to 'virtual' or 'infinite'. Specify the height of the component."});var ll=class{constructor(e){this.options=e,this._setOption("disabledItemKeys",[]),this._clearItemKeys()}_clearItemKeys(){this._setOption("addedItemKeys",[]),this._setOption("removedItemKeys",[]),this._setOption("removedItems",[]),this._setOption("addedItems",[])}validate(){}_setOption(e,t){this.options[e]=t}onSelectionChanged(){let{addedItemKeys:e}=this.options,{removedItemKeys:t}=this.options,{addedItems:n}=this.options,{removedItems:o}=this.options,{selectedItems:s}=this.options,{selectedItemKeys:r}=this.options,a=this.options.onSelectionChanged||S;this._clearItemKeys(),a({selectedItems:s,selectedItemKeys:r,addedItemKeys:e,removedItemKeys:t,addedItems:n,removedItems:o})}equalKeys(e,t){return this.options.equalByReference&&$(e)&&$(t)?e===t:ve(e,t)}getSelectableItems(e){return e.filter(t=>!(t!=null&&t.disabled))}_clearSelection(e,t,n,o){return e=e||[],e=Array.isArray(e)?e:[e],this.validate(),this.selectedItemKeys(e,t,n,o)}_removeTemplateProperty(e){return Array.isArray(e)?e.map(t=>this._removeTemplateProperty(t)):($(e)&&delete e.template,e)}_loadFilteredData(e,t,n,o){let s=encodeURI(JSON.stringify(this._removeTemplateProperty(e))).length,r=this.options.maxFilterLengthInRequest&&s>this.options.maxFilterLengthInRequest,a=y(),l={filter:r?void 0:e,select:r?this.options.dataFields():n||this.options.dataFields()};return e&&e.length===0?a.resolve([]):this.options.load(l).done(d=>{let c=q(d)?d.data:d;t&&!o?c=c.filter(t):r&&(c=vt(c).filter(e).toArray()),a.resolve(c)}).fail(a.reject.bind(a)),a}updateSelectedItemKeyHash(e){for(let t=0;t<e.length;t++){let n=ai(e[t]);$(n)||(this.options.keyHashIndices[n]=this.options.keyHashIndices[n]||[],this.options.keyHashIndices[n].push(t))}}_isAnyItemSelected(e){for(let t=0;t<e.length;t++)if(this.options.isItemSelected(e[t]))return;return!1}_getFullSelectAllState(){let e=this.options.plainItems(),t=this.options.filter(),n=this.options.ignoreDisabledItems?this.options.selectedItems:this.options.selectedItems.filter(r=>!(r!=null&&r.disabled));t&&(n=vt(n).filter(t).toArray());let o=n.length,s=e.length-this.getSelectableItems(e).length;if(!o)return this._isAnyItemSelected(e);if(o>=this.options.totalCount()-s)return!0}_getVisibleSelectAllState(){let e=this.getSelectableItems(this.options.plainItems()),t=!1,n=!1;for(let o=0;o<e.length;o++){let s=e[o],r=this.options.getItemData(s),a=this.options.keyOf(r);this.options.isSelectableItem(s)&&(this.isItemKeySelected(a)?t=!0:n=!0)}return t?n?void 0:!0:!1}};var Hh=class extends ll{getSelectedItems(){return this._loadFilteredData(this.options.selectionFilter)}getSelectedItemKeys(){let e=y(),t=this,n=this.options.key(),o=B(n)?[n]:n;return this._loadFilteredData(this.options.selectionFilter,null,o).done(s=>{let r=s.map(a=>t.options.keyOf(a));e.resolve(r)}).fail(e.reject),e.promise()}selectedItemKeys(e,t,n,o){if(o){let s=this.options.filter();!s||JSON.stringify(s)===JSON.stringify(this.options.selectionFilter)&&n?this._setOption("selectionFilter",n?[]:null):this._addSelectionFilter(n,s,o)}else{t||this._setOption("selectionFilter",[]);for(let s=0;s<e.length;s++)n?this.removeSelectedItem(e[s]):this.addSelectedItem(e[s],o,!t)}return this.onSelectionChanged(),y().resolve()}setSelectedItems(e){this._setOption("selectionFilter",null);for(let t=0;t<e.length;t++)this.addSelectedItem(e[t])}isItemDataSelected(e){return this.isItemKeySelected(e)}isItemKeySelected(e){let{selectionFilter:t,sensitivity:n}=this.options;return t?!!vt([e],{langParams:{collatorOptions:{sensitivity:n}}}).filter(t).toArray().length:!0}_getKeyExpr(){let e=this.options.key();return Array.isArray(e)&&e.length===1?e[0]:e}_normalizeKey(e){let t=this.options.key();return Array.isArray(t)&&t.length===1?e[t[0]]:e}_getFilterByKey(e){let t=this._getKeyExpr(),n=[t,"=",this._normalizeKey(e)];if(Array.isArray(t)){n=[];for(let o=0;o<t.length;o++)n.push([t[o],"=",e[t[o]]]),o!==t.length-1&&n.push("and")}return n}addSelectedItem(e,t,n){let o=this._getFilterByKey(e);this._addSelectionFilter(!1,o,t,n)}removeSelectedItem(e){let t=this._getFilterByKey(e);this._addSelectionFilter(!0,t)}validate(){let{key:e}=this.options;if(e&&e()===void 0)throw Z.Error("E1042","Deferred selection")}_findSubFilter(e,t){if(!e)return-1;let n=JSON.stringify(t);for(let o=0;o<e.length;o++){let s=e[o];if(s&&JSON.stringify(s)===n)return o}return-1}_isLastSubFilter(e,t){return e&&t?this._findSubFilter(e,t)===e.length-1||this._findSubFilter([e],t)===0:!1}_addFilterOperator(e,t){return e.length>1&&B(e[1])&&e[1]!==t&&(e=[e]),e.length&&e.push(t),e}_denormalizeFilter(e){return e&&B(e[0])&&(e=[e]),e}_isOnlyNegativeFiltersLeft(e){return e.every((t,n)=>n%2===0?Array.isArray(t)&&t[0]==="!":t==="and")}_addSelectionFilter(e,t,n,o){var s;let r=this,a=e?["!",t]:t,l=e?"and":"or",d=!0,c=r.options.selectionFilter||[];if(c=r._denormalizeFilter(c),(s=c)!==null&&s!==void 0&&s.length&&!o){let h=r._removeSameFilter(c,t,e,n),p=r._removeSameFilter(c,t,!e);e&&(h!==-1||p!==-1)&&this._isOnlyNegativeFiltersLeft(c)&&(c=[]);let C=this._isKeyFilter(t)&&this._hasKeyFiltersOnlyStartingFromIndex(c,p);d=t.length&&!C}d&&(c=r._addFilterOperator(c,l),c.push(a)),c=r._normalizeFilter(c),r._setOption("selectionFilter",!e&&!c.length?null:c)}_normalizeFilter(e){return e&&e.length===1&&(e=e[0]),e}_removeFilterByIndex(e,t,n){let o=e[1];t>0?e.splice(t-1,2):e.splice(t,2),n&&o==="and"&&e.splice(0,e.length)}_isSimpleKeyFilter(e,t){return e.length===3&&e[0]===t&&e[1]==="="}_isKeyFilter(e){if(e.length===2&&e[0]==="!")return this._isKeyFilter(e[1]);let t=this._getKeyExpr();if(Array.isArray(t)){if(e.length!==2*t.length-1)return!1;for(let n=0;n<t.length;n++)if(n>0&&e[2*n-1]!=="and"||!this._isSimpleKeyFilter(e[2*n],t[n]))return!1;return!0}return this._isSimpleKeyFilter(e,t)}_hasKeyFiltersOnlyStartingFromIndex(e,t){if(t>=0){for(let n=t;n<e.length;n++)if(typeof e[n]!="string"&&!this._isKeyFilter(e[n]))return!1;return!0}return!1}_removeSameFilter(e,t,n,o){if(t=n?["!",t]:t,JSON.stringify(t)===JSON.stringify(e))return e.splice(0,e.length),0;let s=this._findSubFilter(e,t);if(s>=0)return this._removeFilterByIndex(e,s,o),s;for(let r=0;r<e.length;r++)if(Array.isArray(e[r])&&e[r].length>2){let a=this._removeSameFilter(e[r],t,!1,o);if(a>=0)return e[r].length?e[r].length===1&&(e[r]=e[r][0]):this._removeFilterByIndex(e,r,o),a}return-1}getSelectAllState(){let e=this.options.filter(),{selectionFilter:t}=this.options;if(!t)return!0;if(!t.length)return!1;if(!(!e||!e.length)){if(t=this._denormalizeFilter(t),this._isLastSubFilter(t,e))return!0;if(this._isLastSubFilter(t,["!",e]))return!1}}loadSelectedItemsWithFilter(){let e=this.options.filter(),{selectionFilter:t}=this.options,n=e?[e,"and",t]:t;return this._loadFilteredData(n)}};function aG(i){return i.reduce((e,t)=>{let n=(e.get(t)??0)+1;return e.set(t,n),e},new Map)}var CI=function(i){return Array.isArray(i)?i:[i]},xI=function(i){return[...new Set(i)]};var q_=function(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],t=aG(e);return i.filter(n=>{let o=t.get(n);return o&&t.set(n,o-1),!o})},ta=function(i,e,t,n){let o={},{useLegacyVisibleIndex:s}=fe(),r=0,a=l=>!f(l[e])&&(!n||n(l));i.forEach(l=>{let d=l[e];d>=0?(o[d]=o[d]||[],l===t?o[d].unshift(l):o[d].push(l)):l[e]=void 0}),s||i.forEach(l=>{if(a(l)){for(;o[r];)r++;o[r]=[l],r++}}),r=0,Fd(o,function(l,d){d.forEach(c=>{l>=0&&(c[e]=r++)})}),s&&i.forEach(l=>{a(l)&&(l[e]=r++)})},vI=(i,e)=>i.reduce((t,n)=>{let o=e(n);return t[o]=t[o]??[],t[o].push(n),t},{});var Y_=function(i,e){this.getLocalFilter=function(a,l,d,c){return l=l===void 0?ve:l,s.bind(this,l,a,d,c)},this.getExpr=function(a){if(!a)return;let l;return i.forEach(function(d,c){l=l||[];let h;c>0&&l.push(e?"and":"or"),B(a)||A(a)?h=r(a,d):h=function(p,g){let C=[];for(let v=0,b=p.length;v<b;v++){let T=p[v],R=me(T),U=g&&R(g),Q=r(T,U);if(!Q)break;v>0&&C.push(e?"or":"and"),C.push(Q)}return C}(a,d),l.push(h)}),l&&l.length===1&&(l=l[0]),l},this.getCombinedFilter=function(a,l){let d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,c=this.getExpr(a),h=c;return(d||e)&&l&&(c?(h=[],h.push(c),h.push(l)):h=l),h};let t,n=function(a,l){if(!t){t={};let d=o(i,a,l);for(let c=0;c<d.length;c++)t[ai(d[c])]=!0}return t},o=function(a,l,d){return Array.isArray(d)?a.map(c=>l(c)):a};function s(a,l,d,c,h){let p=l(h),g,C;if(!d&&(g=ai(p),!$(g)))return n(l,c)[g]?!e:!!e;for(C=0;C<i.length;C++)if(a(i[C],p))return!e;return!!e}function r(a,l){if(l!==void 0)return[a,e?"<>":"=",l]}};var $h=class extends ll{constructor(e){super(e),this._initSelectedItemKeyHash()}_initSelectedItemKeyHash(){this._setOption("keyHashIndices",this.options.equalByReference?null:{})}getSelectedItemKeys(){return this.options.selectedItemKeys.slice(0)}getSelectedItems(){return this.options.selectedItems.slice(0)}_preserveSelectionUpdate(e,t){let{keyOf:n}=this.options,o,s,r;if(!n)return;let a=t&&e.length>1&&!this.options.equalByReference;for(a&&(o={}),r=0;r<e.length;r++){let l=e[r],d=n(l);t?(s=this.removeSelectedItem(d,o,l?.disabled),o&&s>=0&&(o[s]=!0)):this.addSelectedItem(d,l)}a&&this._batchRemoveSelectedItems(o)}_batchRemoveSelectedItems(e){let t=this.options.selectedItemKeys.slice(0),n=this.options.selectedItems.slice(0);this.options.selectedItemKeys.length=0,this.options.selectedItems.length=0;for(let o=0;o<t.length;o++)e[o]||(this.options.selectedItemKeys.push(t[o]),this.options.selectedItems.push(n[o]));this._initSelectedItemKeyHash(),this.updateSelectedItemKeyHash(this.options.selectedItemKeys)}_loadSelectedItemsCore(e,t,n,o){let s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,r=y(),a=this.options.key();if(!e.length&&!n)return r.resolve([]),r;if(n&&t&&!o)return r.resolve(this.getSelectedItems()),r;let l=new Y_(e,n),d=l.getCombinedFilter(a,o,s),c=[];if(t){let{selectedItems:g}=this.options;c=d&&e.length!==g.length?vt(g).filter(d).toArray():g.slice(0)}let h=c.length?c:this.options.plainItems(!0).filter(this.options.isSelectableItem).map(this.options.getItemData),p=l.getLocalFilter(this.options.keyOf,this.equalKeys.bind(this),this.options.equalByReference,a);return h=h.filter(p),c.length||!n&&h.length===e.length?r.resolve(h):r=this._loadFilteredData(d,p,null,n),r}_replaceSelectionUpdate(e){let t=[],{keyOf:n}=this.options;if(n){for(let o=0;o<e.length;o++){let s=e[o],r=n(s);t.push(r)}this.setSelectedItems(t,e)}}_warnOnIncorrectKeys(e){let{allowNullValue:t}=this.options;for(let n=0;n<e.length;n++){let o=e[n];(!t||o!==null)&&!this.isItemKeySelected(o)&&Z.log("W1002",o)}}_isMultiSelectEnabled(){let{mode:e}=this.options;return e==="all"||e==="multiple"}_requestInProgress(){var e;return((e=this._lastLoadDeferred)===null||e===void 0?void 0:e.state())==="pending"}_concatRequestsItems(e,t,n,o){let s,r=t?e:[];return o?s=o:s=q_(e,this.options.selectedItemKeys),{addedItems:n.added.concat(s),removedItems:n.removed.concat(r),keys:e}}_collectLastRequestData(e,t,n,o){let s=t&&n,r={added:[],removed:[]},a=this._isMultiSelectEnabled(),l=a?this._lastRequestData:{};return a&&(this._shouldMergeWithLastRequest&&(s?(this._lastLoadDeferred.reject(),l={}):z0(e,this.options.selectedItemKeys)||(r.added=l.addedItems,r.removed=l.removedItems,t||this._lastLoadDeferred.reject())),l=this._concatRequestsItems(e,t,r,this._shouldMergeWithLastRequest?void 0:o)),l}_updateKeysByLastRequestData(e,t,n){let o=e;if(this._isMultiSelectEnabled()&&this._shouldMergeWithLastRequest&&!t&&!n){var s,r;o=q_(e.concat((s=this._lastRequestData)===null||s===void 0?void 0:s.addedItems),(r=this._lastRequestData)===null||r===void 0?void 0:r.removedItems),o=xI(o)}return o}_loadSelectedItems(e,t,n,o){let s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,r=this,a=y(),l=r.options.filter();return this._shouldMergeWithLastRequest=this._requestInProgress(),this._lastRequestData=this._collectLastRequestData(e,t,n,o),P(r._lastLoadDeferred).always(()=>{let d=r._updateKeysByLastRequestData(e,t,n);r._shouldMergeWithLastRequest=!1,r._loadSelectedItemsCore(d,t,n,l,s).done(a.resolve).fail(a.reject)}),r._lastLoadDeferred=a,a}selectedItemKeys(e,t,n,o,s){let r=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,a=this,l=a._loadSelectedItems(e,n,o,s,r);return l.done(d=>{t?a._preserveSelectionUpdate(d,n):a._replaceSelectionUpdate(d),a.onSelectionChanged()}),l}addSelectedItem(e,t){if(f(t)&&!this.options.ignoreDisabledItems&&t.disabled){this.options.disabledItemKeys.indexOf(e)===-1&&this.options.disabledItemKeys.push(e);return}let n=this._getKeyHash(e);this._indexOfSelectedItemKey(n)===-1&&(!$(n)&&this.options.keyHashIndices&&(this.options.keyHashIndices[n]=[this.options.selectedItemKeys.length]),this.options.selectedItemKeys.push(e),this.options.addedItemKeys.push(e),this.options.addedItems.push(t),this.options.selectedItems.push(t))}_getSelectedIndexByKey(e,t){let{selectedItemKeys:n}=this.options;for(let o=0;o<n.length;o++)if((!t||!t[o])&&this.equalKeys(n[o],e))return o;return-1}_getSelectedIndexByHash(e,t){let n=this.options.keyHashIndices[e];return n&&n.length>1&&t&&(n=n.filter(o=>!t[o])),n&&n[0]>=0?n[0]:-1}_indexOfSelectedItemKey(e,t){let n;return this.options.equalByReference?n=this.options.selectedItemKeys.indexOf(e):$(e)?n=this._getSelectedIndexByKey(e,t):n=this._getSelectedIndexByHash(e,t),n}_shiftSelectedKeyIndices(e){for(let t=e;t<this.options.selectedItemKeys.length;t++){let n=this.options.selectedItemKeys[t],o=ai(n),s=this.options.keyHashIndices[o];if(s)for(let r=0;r<s.length;r++)s[r]>e&&s[r]--}}removeSelectedItem(e,t,n){if(!this.options.ignoreDisabledItems&&n)return;let o=this._getKeyHash(e),s=!!t,r=this._indexOfSelectedItemKey(o,t);if(r<0||(this.options.removedItemKeys.push(e),this.options.removedItems.push(this.options.selectedItems[r]),s)||(this.options.selectedItemKeys.splice(r,1),this.options.selectedItems.splice(r,1),$(o)||!this.options.keyHashIndices))return r;let a=this.options.keyHashIndices[o];return a&&(a.shift(),a.length||delete this.options.keyHashIndices[o],this._shiftSelectedKeyIndices(r)),r}_updateAddedItemKeys(e,t){for(let n=0;n<e.length;n++)this.isItemKeySelected(e[n])||(this.options.addedItemKeys.push(e[n]),this.options.addedItems.push(t[n]))}_updateRemovedItemKeys(e,t,n){for(let o=0;o<t.length;o++)this.isItemKeySelected(t[o])||(this.options.removedItemKeys.push(t[o]),this.options.removedItems.push(n[o]))}_isItemSelectionInProgress(e,t){return t&&this._lastRequestData&&this._requestInProgress()?(this._lastRequestData.addedItems??[]).includes(e):!1}_getKeyHash(e){return this.options.equalByReference?e:ai(e)}setSelectedItems(e,t){this._updateAddedItemKeys(e,t);let n=this.options.selectedItemKeys,o=this.options.selectedItems;this.options.equalByReference||(this._initSelectedItemKeyHash(),this.updateSelectedItemKeyHash(e)),this._setOption("selectedItemKeys",e),this._setOption("selectedItems",t),this._updateRemovedItemKeys(e,n,o)}isItemDataSelected(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=this.options.keyOf(e);return this.isItemKeySelected(n,t)}isItemKeySelected(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=this._isItemSelectionInProgress(e,t.checkPending);if(!n){let o=this._getKeyHash(e);n=this._indexOfSelectedItemKey(o)!==-1}return n}getSelectAllState(e){return e?this._getVisibleSelectAllState():this._getFullSelectAllState()}loadSelectedItemsWithFilter(){let e=this.options.key(),t=this.getSelectedItemKeys(),n=this.options.filter();if(!t.length)return y().resolve([]);let s=new Y_(t).getCombinedFilter(e,n,!0);return this._loadFilteredData(s)}};var dl=class{constructor(e){this.options=m(this._getDefaultOptions(),e,{selectedItemKeys:e.selectedKeys||[]}),this._selectionStrategy=this.options.deferred?new Hh(this.options):new $h(this.options),this._focusedItemIndex=-1,this.options.equalByReference||this._selectionStrategy.updateSelectedItemKeyHash(this.options.selectedItemKeys)}_getDefaultOptions(){return{allowNullValue:!1,deferred:!1,equalByReference:!1,mode:"multiple",selectedItems:[],selectionFilter:[],maxFilterLengthInRequest:0,onSelectionChanged:S,key:S,keyOf:e=>e,load:()=>y().resolve([]),totalCount:()=>-1,isSelectableItem:()=>!0,isItemSelected:()=>!1,getItemData:e=>e,dataFields:S,filter:S}}validate(){this._selectionStrategy.validate()}getSelectedItemKeys(){return this._selectionStrategy.getSelectedItemKeys()}getSelectedItems(){return this._selectionStrategy.getSelectedItems()}selectionFilter(e){if(e===void 0)return this.options.selectionFilter;let t=this.options.selectionFilter!==e&&JSON.stringify(this.options.selectionFilter)!==JSON.stringify(e);this.options.selectionFilter=e,t&&this.onSelectionChanged()}setSelection(e,t){return this.selectedItemKeys(e,!1,!1,!1,t)}select(e){return this.selectedItemKeys(e,!0)}deselect(e){return this.selectedItemKeys(e,!0,!0)}selectedItemKeys(e,t,n,o,s){return e=e??[],e=Array.isArray(e)?e:[e],this.validate(),this._selectionStrategy.selectedItemKeys(e,t,n,o,s)}clearSelection(){return this.selectedItemKeys([])}_addSelectedItem(e,t){this._selectionStrategy.addSelectedItem(t,e)}_removeSelectedItem(e){this._selectionStrategy.removeSelectedItem(e)}_setSelectedItems(e,t){this._selectionStrategy.setSelectedItems(e,t)}onSelectionChanged(){this._selectionStrategy.onSelectionChanged()}changeItemSelection(e,t,n){var o,s;let r,a=this.options.plainItems(),l=a[e],d,{isVirtualPaging:c}=this.options,h=(o=(s=this.options).allowLoadByRange)===null||o===void 0?void 0:o.call(s),{alwaysSelectByShift:p}=this.options,g,C=!1,v=!1,b=Q=>Q>=0&&!a.filter(se=>se.loadIndex===Q).length;if(c&&f(l)&&(h&&(g=l.loadIndex-e,e=l.loadIndex),C=b(this._focusedItemIndex),f(this._shiftFocusedItemIndex)&&(v=b(this._shiftFocusedItemIndex))),!this.isSelectable()||!this.isDataItem(l))return!1;let T=this.options.getItemData(l),R=this.options.keyOf(T);t=t||{};let U=t.shift;if(p===!1&&U&&(U=h!==!1||!C&&!v),U&&this.options.mode==="multiple"&&this._focusedItemIndex>=0)h&&(C||v)?(r=e!==this._shiftFocusedItemIndex||this._focusedItemIndex!==this._shiftFocusedItemIndex,r&&(d=this.changeItemSelectionWhenShiftKeyInVirtualPaging(e))):r=this.changeItemSelectionWhenShiftKeyPressed(e,a,g);else if(t.control){if(this._resetItemSelectionWhenShiftKeyPressed(),!n){let Q=this._selectionStrategy.isItemDataSelected(T);this.options.mode==="single"&&this.clearSelectedItems(),Q?this._removeSelectedItem(R):this._addSelectedItem(T,R)}r=!0}else{this._resetItemSelectionWhenShiftKeyPressed();let Q=this._selectionStrategy.equalKeys(this.options.selectedItemKeys[0],R);(this.options.selectedItemKeys.length!==1||!Q)&&(this._setSelectedItems([R],[T]),r=!0)}if(r)return P(d).done(()=>{this._focusedItemIndex=e,!n&&this.onSelectionChanged()}),!0}isDataItem(e){return this.options.isSelectableItem(e)}isSelectable(){return this.options.mode==="single"||this.options.mode==="multiple"}isItemDataSelected(e){return this._selectionStrategy.isItemDataSelected(e,{checkPending:!0})}isItemSelected(e,t){return this._selectionStrategy.isItemKeySelected(e,t)}_resetItemSelectionWhenShiftKeyPressed(){delete this._shiftFocusedItemIndex}_resetFocusedItemIndex(){this._focusedItemIndex=-1}changeItemSelectionWhenShiftKeyInVirtualPaging(e){let t=this.options.getLoadOptions(e,this._focusedItemIndex,this._shiftFocusedItemIndex),n=y(),o=t.skip;return this.options.load(t).done(s=>{this.changeItemSelectionWhenShiftKeyPressed(e,s,o),n.resolve()}),n.promise()}changeItemSelectionWhenShiftKeyPressed(e,t,n){let o=!1,s,r=f(n),a=r?this._focusedItemIndex-n:this._focusedItemIndex,{keyOf:l}=this.options,d=t[a],c=this.options.getItemData(d),h=l(c),p=d&&this.isItemDataSelected(c);f(this._shiftFocusedItemIndex)||(this._shiftFocusedItemIndex=this._focusedItemIndex);let g,C,v,b;if(this._shiftFocusedItemIndex!==this._focusedItemIndex)for(s=this._focusedItemIndex<this._shiftFocusedItemIndex?1:-1,v=r?this._focusedItemIndex-n:this._focusedItemIndex,b=r?this._shiftFocusedItemIndex-n:this._shiftFocusedItemIndex,a=v;a!==b;a+=s)(r||this.isDataItem(t[a]))&&(C=l(this.options.getItemData(t[a])),this._removeSelectedItem(C),o=!0);if(e!==this._shiftFocusedItemIndex)for(s=e<this._shiftFocusedItemIndex?1:-1,v=r?e-n:e,b=r?this._shiftFocusedItemIndex-n:this._shiftFocusedItemIndex,a=v;a!==b;a+=s)(r||this.isDataItem(t[a]))&&(g=this.options.getItemData(t[a]),C=l(g),this._addSelectedItem(g,C),o=!0);return(r||this.isDataItem(d))&&!p&&(this._addSelectedItem(c,h),o=!0),o}clearSelectedItems(){this._setSelectedItems([],[])}selectAll(e){return this._resetFocusedItemIndex(),e?this._onePageSelectAll(!1):this.selectedItemKeys([],!0,!1,!0)}deselectAll(e){return this._resetFocusedItemIndex(),e?this._onePageSelectAll(!0):this.selectedItemKeys([],!0,!0,!0)}_onePageSelectAll(e){let t=this._selectionStrategy.getSelectableItems(this.options.plainItems());for(let n=0;n<t.length;n++){let o=t[n];if(this.isDataItem(o)){let s=this.options.getItemData(o),r=this.options.keyOf(s),a=this.isItemSelected(r);!a&&!e&&this._addSelectedItem(s,r),a&&e&&this._removeSelectedItem(r)}}return this.onSelectionChanged(),y().resolve()}getSelectAllState(e){return this._selectionStrategy.getSelectAllState(e)}loadSelectedItemsWithFilter(){return this._selectionStrategy.loadSelectedItemsWithFilter()}};var po=(()=>{class i{constructor(t,n){n=n||{},this._action=t,this._context=n.context||K(),this._beforeExecute=n.beforeExecute,this._afterExecute=n.afterExecute,this._component=n.component,this._validatingTargetName=n.validatingTargetName;let o=this._excludeValidators={};if(n.excludeValidators)for(let s=0;s<n.excludeValidators.length;s++)o[n.excludeValidators[s]]=!0}execute(){let t={action:this._action,args:Array.prototype.slice.call(arguments),context:this._context,component:this._component,validatingTargetName:this._validatingTargetName,cancel:!1,handled:!1},n=this._beforeExecute,o=this._afterExecute,s=t.args[0]||{};if(!this._validateAction(t)||(n?.call(this._context,t),t.cancel))return;let r=this._executeAction(t);if(!s.cancel)return o?.call(this._context,t),r}_validateAction(t){let n=this._excludeValidators,{executors:o}=i;for(let r in o)if(!n[r]){var s;let a=o[r];if((s=a.validate)===null||s===void 0||s.call(a,t),t.cancel)return!1}return!0}_executeAction(t){let n,{executors:o}=i;for(let r in o){var s;let a=o[r];if((s=a.execute)===null||s===void 0||s.call(a,t),t.handled){n=t.result;break}}return n}static registerExecutor(t,n){if(q(t)){x(t,i.registerExecutor);return}i.executors[t]=n}static unregisterExecutor(){for(var t=arguments.length,n=new Array(t),o=0;o<t;o++)n[o]=arguments[o];x(n,function(){delete i.executors[this]})}}return i.executors={},i})();var bI=i=>e=>{if(!e.args.length)return;let t=e.args[0],n=t[e.validatingTargetName]||t.element;n&&i(u(n))&&(e.cancel=!0)};po.registerExecutor({disabled:{validate:bI(i=>i.is(".dx-state-disabled, .dx-state-disabled *"))},readOnly:{validate:bI(i=>i.is(".dx-state-readonly, .dx-state-readonly *:not(.dx-state-independent)"))},undefined:{execute:i=>{i.action||(i.result=void 0,i.handled=!0)}},func:{execute:i=>{A(i.action)&&(i.result=i.action.call(i.context,i.args[0]),i.handled=!0)}}});var hr=class extends sn{constructor(e){super(),this.name=e}};var Vi=class extends sn{_renderCore(){return u()}};var yI={},zh;function OI(i,e){yI[i]=e}function SI(i){if(B(i)){if(zh=yI[i],!zh)throw he.Error("E0020",i)}else zh=i}function X_(){return zh}OI("default",{compile:i=>Xr(i),render:(i,e,t)=>i.clone()});SI("default");var Wh=class extends sn{constructor(e){super(),this._element=e}_renderCore(e){let t=e.transclude;return!t&&!this._compiledTemplate&&(this._compiledTemplate=X_().compile(this._element)),u("<div>").append(t?this._element:X_().render(this._compiledTemplate,e.model,e.index)).contents()}source(){return u(this._element).clone()}};var Gh=(i,e)=>{let t=u(i).contents().filter(`[data-options*="${e}"]`);return[].slice.call(t).map(n=>{let o=u(n).attr("data-options")||"";return{element:n,options:fe().optionsParser(o)[e]}}).filter(n=>!!n.options)},EI=i=>{let e=vI(i,n=>n.options.name);if(e[void 0])throw he.Error("E0023");let t={};return Object.keys(e).forEach(n=>{var o;let s=(o=eh(F.current(),e[n],r=>r.options)[0])===null||o===void 0?void 0:o.element;s&&(t[n]=s)}),t},wI=i=>{let e=i.render.bind(i);return m({},i,{render(t){let n=e(t);return t&&t.onRendered&&t.onRendered(),n}})},lG=i=>{let e=i.render.bind(i);return m({},i,{render(t){let n=u(t.container);return e(I({},t,{container:N(n)}))}})},II=i=>{let e=[];return"model"in i&&e.push(i.model),"index"in i&&e.push(i.index),e.push(i.container),e},DI=i=>typeof i=="string"?Xr(i):i,Q_=i=>$t(i)&&i[0]||i,TI=i=>new Wh(i),dG=(i,e,t,n)=>{let o=null;return(!n||n.indexOf(i)===-1)&&(o=e[i],o&&!(o instanceof sn)&&(A(o.render)&&(o=lG(o)),t||(o=wI(o)))),o},Z_=(i,e,t,n,o,s)=>i==null?new Vi:i instanceof hr?s[i.name]:i instanceof sn?i:A(i.render)&&!$t(i)?n?i:wI(i):i.nodeType||$t(i)?e(u(i)):dG(i,t,n,o)||s[i]||e(i);var cG={load:()=>y().reject(),loadSingle:()=>y().reject(),loadFromStore:()=>y().reject(),loadNextPage:()=>y().reject(),loadOptions:S,userData:S,cancel:S,cancelAll:S,filter:S,addSearchFilter:S,group:S,paginate:S,pageSize:S,pageIndex:S,resetDataSourcePageIndex:S,totalCount:S,isLastPage:S,isLoading:S,isLoaded:S,searchValue:S,searchOperation:S,searchExpr:S,select:S,key:S,keyOf:S,store:S,items:S,applyMapFunction:S,getDataSource:S,reload:S,on:S,off:S},J_=class{constructor(e){if(!e)return cG;this._dataSource=e}load(){return this._dataSource.load()}loadSingle(e,t){return arguments.length<2&&(t=e,e=this.key()),this._dataSource.loadSingle(e,t)}loadFromStore(e){return this.store().load(e)}loadNextPage(){return this.pageIndex(1+this.pageIndex()),this.load()}loadOptions(){return this._dataSource.loadOptions()}userData(){return this._dataSource._userData}cancel(e){this._dataSource.cancel(e)}cancelAll(){this._dataSource.cancelAll()}filter(e){return this._dataSource.filter(e)}addSearchFilter(e){this._dataSource._addSearchFilter(e)}group(e){return this._dataSource.group(e)}paginate(){return this._dataSource.paginate()}pageSize(){return this._dataSource._pageSize}pageIndex(e){return this._dataSource.pageIndex(e)}resetDataSourcePageIndex(){this.pageIndex()&&(this.pageIndex(0),this.load())}totalCount(){return this._dataSource.totalCount()}isLastPage(){return this._dataSource.isLastPage()||!this._dataSource._pageSize}isLoading(){return this._dataSource.isLoading()}isLoaded(){return this._dataSource.isLoaded()}searchValue(e){return arguments.length?this._dataSource.searchValue(e):this._dataSource.searchValue()}searchOperation(e){return this._dataSource.searchOperation(e)}searchExpr(e){return arguments.length?this._dataSource.searchExpr(e):this._dataSource.searchExpr()}select(){return this._dataSource.select(...arguments)}key(){return this._dataSource.key()}keyOf(e){return this.store().keyOf(e)}store(){return this._dataSource.store()}items(){return this._dataSource.items()}applyMapFunction(e){return this._dataSource._applyMapFunction(e)}getDataSource(){return this._dataSource||null}reload(){return this._dataSource.reload()}on(e,t){this._dataSource.on(e,t)}off(e,t){this._dataSource.off(e,t)}},Kh=J_;var AI="_dataSourceChangedHandler";var MI="_getSpecificDataSourceOption",RI="_normalizeDataSource",uG={postCtor:function(){this.on("disposing",function(){this._disposeDataSource()}.bind(this))},_refreshDataSource:function(){this._initDataSource(),this._loadDataSource()},_initDataSource:function(){let i=MI in this?this[MI]():this.option("dataSource"),e,t;this._disposeDataSource(),i&&(i instanceof jt?(this._isSharedDataSource=!0,this._dataSource=i):(e="_dataSourceOptions"in this?this._dataSourceOptions():{},t=this._dataSourceType?this._dataSourceType():jt,i=Yi(i,{fromUrlLoadMode:"_dataSourceFromUrlLoadMode"in this&&this._dataSourceFromUrlLoadMode()}),this._dataSource=new t(m(!0,{},e,i))),RI in this&&(this._dataSource=this[RI](this._dataSource)),this._addDataSourceHandlers(),this._initDataController())},_initDataController:function(){var i;let e=(i=this.option)===null||i===void 0?void 0:i.call(this,"_dataController"),t=this._dataSource;e?this._dataController=e:this._dataController=new Kh(t)},_addDataSourceHandlers:function(){AI in this&&this._addDataSourceChangeHandler(),"_dataSourceLoadErrorHandler"in this&&this._addDataSourceLoadErrorHandler(),"_dataSourceLoadingChangedHandler"in this&&this._addDataSourceLoadingChangedHandler(),this._addReadyWatcher()},_addReadyWatcher:function(){this.readyWatcher=function(i){this._ready&&this._ready(!i)}.bind(this),this._dataSource.on("loadingChanged",this.readyWatcher)},_addDataSourceChangeHandler:function(){let i=this._dataSource;this._proxiedDataSourceChangedHandler=function(e){this[AI](i.items(),e)}.bind(this),i.on("changed",this._proxiedDataSourceChangedHandler)},_addDataSourceLoadErrorHandler:function(){this._proxiedDataSourceLoadErrorHandler=this._dataSourceLoadErrorHandler.bind(this),this._dataSource.on("loadError",this._proxiedDataSourceLoadErrorHandler)},_addDataSourceLoadingChangedHandler:function(){this._proxiedDataSourceLoadingChangedHandler=this._dataSourceLoadingChangedHandler.bind(this),this._dataSource.on("loadingChanged",this._proxiedDataSourceLoadingChangedHandler)},_loadDataSource:function(){let i=this._dataSource;i&&(i.isLoaded()?this._proxiedDataSourceChangedHandler&&this._proxiedDataSourceChangedHandler():i.load())},_loadSingle:function(i,e){return i=i==="this"?this._dataSource.key()||"this":i,this._dataSource.loadSingle(i,e)},_isLastPage:function(){return!this._dataSource||this._dataSource.isLastPage()||!this._dataSource._pageSize},_isDataSourceLoading:function(){return this._dataSource&&this._dataSource.isLoading()},_disposeDataSource:function(){this._dataSource&&(this._isSharedDataSource?(delete this._isSharedDataSource,this._proxiedDataSourceChangedHandler&&this._dataSource.off("changed",this._proxiedDataSourceChangedHandler),this._proxiedDataSourceLoadErrorHandler&&this._dataSource.off("loadError",this._proxiedDataSourceLoadErrorHandler),this._proxiedDataSourceLoadingChangedHandler&&this._dataSource.off("loadingChanged",this._proxiedDataSourceLoadingChangedHandler),this._dataSource._eventsStrategy&&this._dataSource._eventsStrategy.off("loadingChanged",this.readyWatcher)):this._dataSource.dispose(),delete this._dataSource,delete this._proxiedDataSourceChangedHandler,delete this._proxiedDataSourceLoadErrorHandler,delete this._proxiedDataSourceLoadingChangedHandler)},getDataSource:function(){return this._dataSource||null}},Uh=uG;var FI=Math.abs;var hG=lr.inherit({start:function(i){this._startEventData=Ye(i),this._startTimer(i)},_startTimer:function(i){let e="timeout"in this?this.timeout:750;this._holdTimer=setTimeout(function(){this._requestAccept(i),this._fireEvent("dxhold",i,{target:i.target}),this._forgetAccept()}.bind(this),e)},move:function(i){this._touchWasMoved(i)&&this._cancel(i)},_touchWasMoved:function(i){let e=Vo(this._startEventData,Ye(i));return FI(e.x)>5||FI(e.y)>5},end:function(){this._stopTimer()},_stopTimer:function(){clearTimeout(this._holdTimer)},cancel:function(){this._stopTimer()},dispose:function(){this._stopTimer()}});Wn({emitter:hG,bubble:!0,events:["dxhold"]});var an={name:"dxhold"};var pG=D("contextmenu","dxContexMenu"),gG=D(an.name,"dxContexMenu");var mG=ce.inherit({setup:function(i){let e=u(i);_.on(e,pG,this._contextMenuHandler.bind(this)),(Nn||F.isSimulator())&&_.on(e,gG,this._holdHandler.bind(this))},_holdHandler:function(i){$n(i)&&!F.isSimulator()||this._fireContextMenu(i)},_contextMenuHandler:function(i){this._fireContextMenu(i)},_fireContextMenu:function(i){return ji({type:"dxcontextmenu",originalEvent:i})},teardown:function(i){_.off(i,".dxContexMenu")}});vi("dxcontextmenu",new mG);var jh="dxcontextmenu";var PI={"en-150":"en-001","en-AG":"en-001","en-AI":"en-001","en-AU":"en-001","en-BB":"en-001","en-BM":"en-001","en-BS":"en-001","en-BW":"en-001","en-BZ":"en-001","en-CC":"en-001","en-CK":"en-001","en-CM":"en-001","en-CX":"en-001","en-CY":"en-001","en-DG":"en-001","en-DM":"en-001","en-ER":"en-001","en-FJ":"en-001","en-FK":"en-001","en-FM":"en-001","en-GB":"en-001","en-GD":"en-001","en-GG":"en-001","en-GH":"en-001","en-GI":"en-001","en-GM":"en-001","en-GY":"en-001","en-HK":"en-001","en-IE":"en-001","en-IL":"en-001","en-IM":"en-001","en-IN":"en-001","en-IO":"en-001","en-JE":"en-001","en-JM":"en-001","en-KE":"en-001","en-KI":"en-001","en-KN":"en-001","en-KY":"en-001","en-LC":"en-001","en-LR":"en-001","en-LS":"en-001","en-MG":"en-001","en-MO":"en-001","en-MS":"en-001","en-MT":"en-001","en-MU":"en-001","en-MV":"en-001","en-MW":"en-001","en-MY":"en-001","en-NA":"en-001","en-NF":"en-001","en-NG":"en-001","en-NR":"en-001","en-NU":"en-001","en-NZ":"en-001","en-PG":"en-001","en-PK":"en-001","en-PN":"en-001","en-PW":"en-001","en-RW":"en-001","en-SB":"en-001","en-SC":"en-001","en-SD":"en-001","en-SG":"en-001","en-SH":"en-001","en-SL":"en-001","en-SS":"en-001","en-SX":"en-001","en-SZ":"en-001","en-TC":"en-001","en-TK":"en-001","en-TO":"en-001","en-TT":"en-001","en-TV":"en-001","en-TZ":"en-001","en-UG":"en-001","en-VC":"en-001","en-VG":"en-001","en-VU":"en-001","en-WS":"en-001","en-ZA":"en-001","en-ZM":"en-001","en-ZW":"en-001","en-AT":"en-150","en-BE":"en-150","en-CH":"en-150","en-DE":"en-150","en-DK":"en-150","en-FI":"en-150","en-NL":"en-150","en-SE":"en-150","en-SI":"en-150","hi-Latn":"en-IN","es-AR":"es-419","es-BO":"es-419","es-BR":"es-419","es-BZ":"es-419","es-CL":"es-419","es-CO":"es-419","es-CR":"es-419","es-CU":"es-419","es-DO":"es-419","es-EC":"es-419","es-GT":"es-419","es-HN":"es-419","es-MX":"es-419","es-NI":"es-419","es-PA":"es-419","es-PE":"es-419","es-PR":"es-419","es-PY":"es-419","es-SV":"es-419","es-US":"es-419","es-UY":"es-419","es-VE":"es-419",nb:"no",nn:"no","pt-AO":"pt-PT","pt-CH":"pt-PT","pt-CV":"pt-PT","pt-FR":"pt-PT","pt-GQ":"pt-PT","pt-GW":"pt-PT","pt-LU":"pt-PT","pt-MO":"pt-PT","pt-MZ":"pt-PT","pt-ST":"pt-PT","pt-TL":"pt-PT","az-Arab":"und","az-Cyrl":"und","bal-Latn":"und","blt-Latn":"und","bm-Nkoo":"und","bs-Cyrl":"und","byn-Latn":"und","cu-Glag":"und","dje-Arab":"und","dyo-Arab":"und","en-Dsrt":"und","en-Shaw":"und","ff-Adlm":"und","ff-Arab":"und","ha-Arab":"und","iu-Latn":"und","kk-Arab":"und","ks-Deva":"und","ku-Arab":"und","ky-Arab":"und","ky-Latn":"und","ml-Arab":"und","mn-Mong":"und","mni-Mtei":"und","ms-Arab":"und","pa-Arab":"und","sat-Deva":"und","sd-Deva":"und","sd-Khoj":"und","sd-Sind":"und","shi-Latn":"und","so-Arab":"und","sr-Latn":"und","sw-Arab":"und","tg-Arab":"und","ug-Cyrl":"und","uz-Arab":"und","uz-Cyrl":"und","vai-Latn":"und","wo-Arab":"und","yo-Arab":"und","yue-Hans":"und","zh-Hant":"und","zh-Hant-MO":"zh-Hant-HK"};var kI=(i,e)=>{let t=i[e];return t?t!=="root"&&t:e.substr(0,e.lastIndexOf("-"))};var Xi=wt({locale:(()=>{let i="en";return e=>{if(!e)return i;i=e}})(),getValueByClosestLocale:function(i){let e=this.locale(),t=i(e),n;for(;!t&&!n;)e=kI(PI,e),e?t=i(e):n=!0;return t===void 0&&e!=="en"?i("en"):t}});var BI={en:{Yes:"Yes",No:"No",Cancel:"Cancel",CheckState:"Check state",Close:"Close",Clear:"Clear",Done:"Done",Loading:"Loading...",Select:"Select...",Search:"Search",Back:"Back",OK:"OK","dxCollectionWidget-noDataText":"No data to display","dxDropDownEditor-selectLabel":"Select","validation-required":"Required","validation-required-formatted":"{0} is required","validation-numeric":"Value must be a number","validation-numeric-formatted":"{0} must be a number","validation-range":"Value is out of range","validation-range-formatted":"{0} is out of range","validation-stringLength":"The length of the value is not correct","validation-stringLength-formatted":"The length of {0} is not correct","validation-custom":"Value is invalid","validation-custom-formatted":"{0} is invalid","validation-async":"Value is invalid","validation-async-formatted":"{0} is invalid","validation-compare":"Values do not match","validation-compare-formatted":"{0} does not match","validation-pattern":"Value does not match pattern","validation-pattern-formatted":"{0} does not match pattern","validation-email":"Email is invalid","validation-email-formatted":"{0} is invalid","validation-mask":"Value is invalid","dxLookup-searchPlaceholder":"Minimum character number: {0}","dxList-pullingDownText":"Pull down to refresh...","dxList-pulledDownText":"Release to refresh...","dxList-refreshingText":"Refreshing...","dxList-pageLoadingText":"Loading...","dxList-nextButtonText":"More","dxList-selectAll":"Select All","dxList-listAriaLabel":"Items","dxList-listAriaLabel-deletable":"Deletable items","dxListEditDecorator-delete":"Delete","dxListEditDecorator-more":"More","dxList-selectAll-indeterminate":"Half-checked","dxList-selectAll-checked":"Checked","dxList-selectAll-notChecked":"Not checked","dxList-ariaRoleDescription":"List","dxScrollView-pullingDownText":"Pull down to refresh...","dxScrollView-pulledDownText":"Release to refresh...","dxScrollView-refreshingText":"Refreshing...","dxScrollView-reachBottomText":"Loading...","dxDateBox-simulatedDataPickerTitleTime":"Select time","dxDateBox-simulatedDataPickerTitleDate":"Select date","dxDateBox-simulatedDataPickerTitleDateTime":"Select date and time","dxDateBox-validation-datetime":"Value must be a date or time","dxDateRangeBox-invalidStartDateMessage":"Start value must be a date","dxDateRangeBox-invalidEndDateMessage":"End value must be a date","dxDateRangeBox-startDateOutOfRangeMessage":"Start date is out of range","dxDateRangeBox-endDateOutOfRangeMessage":"End date is out of range","dxDateRangeBox-startDateLabel":"Start Date","dxDateRangeBox-endDateLabel":"End Date","dxFileUploader-selectFile":"Select a file","dxFileUploader-dropFile":"or Drop a file here","dxFileUploader-bytes":"bytes","dxFileUploader-kb":"KB","dxFileUploader-Mb":"MB","dxFileUploader-Gb":"GB","dxFileUploader-upload":"Upload","dxFileUploader-uploaded":"Uploaded","dxFileUploader-readyToUpload":"Ready to upload","dxFileUploader-uploadAbortedMessage":"Upload cancelled","dxFileUploader-uploadFailedMessage":"Upload failed","dxFileUploader-invalidFileExtension":"File type is not allowed","dxFileUploader-invalidMaxFileSize":"File is too large","dxFileUploader-invalidMinFileSize":"File is too small","dxRangeSlider-ariaFrom":"From","dxRangeSlider-ariaTill":"Till","dxSwitch-switchedOnText":"ON","dxSwitch-switchedOffText":"OFF","dxForm-optionalMark":"optional","dxForm-requiredMessage":"{0} is required","dxNumberBox-invalidValueMessage":"Value must be a number","dxNumberBox-noDataText":"No data","dxDataGrid-emptyHeaderWithColumnChooserText":"Use {0} to display columns","dxDataGrid-emptyHeaderWithGroupPanelText":"Drag a column from the group panel here","dxDataGrid-emptyHeaderWithColumnChooserAndGroupPanelText":"Use {0} or drag a column from the group panel","dxDataGrid-emptyHeaderColumnChooserText":"column chooser","dxDataGrid-columnChooserTitle":"Column Chooser","dxDataGrid-columnChooserEmptyText":"Drag a column here to hide it","dxDataGrid-groupContinuesMessage":"Continues on the next page","dxDataGrid-groupContinuedMessage":"Continued from the previous page","dxDataGrid-groupHeaderText":"Group by This Column","dxDataGrid-ungroupHeaderText":"Ungroup","dxDataGrid-ungroupAllText":"Ungroup All","dxDataGrid-editingEditRow":"Edit","dxDataGrid-editingSaveRowChanges":"Save","dxDataGrid-editingCancelRowChanges":"Cancel","dxDataGrid-editingDeleteRow":"Delete","dxDataGrid-editingUndeleteRow":"Undelete","dxDataGrid-editingConfirmDeleteMessage":"Are you sure you want to delete this record?","dxDataGrid-validationCancelChanges":"Cancel changes","dxDataGrid-groupPanelEmptyText":"Drag a column header here to group by that column","dxDataGrid-noDataText":"No data","dxDataGrid-searchPanelPlaceholder":"Search...","dxDataGrid-filterRowShowAllText":"(All)","dxDataGrid-filterRowResetOperationText":"Reset","dxDataGrid-filterRowOperationEquals":"Equals","dxDataGrid-filterRowOperationNotEquals":"Does not equal","dxDataGrid-filterRowOperationLess":"Less than","dxDataGrid-filterRowOperationLessOrEquals":"Less than or equal to","dxDataGrid-filterRowOperationGreater":"Greater than","dxDataGrid-filterRowOperationGreaterOrEquals":"Greater than or equal to","dxDataGrid-filterRowOperationStartsWith":"Starts with","dxDataGrid-filterRowOperationContains":"Contains","dxDataGrid-filterRowOperationNotContains":"Does not contain","dxDataGrid-filterRowOperationEndsWith":"Ends with","dxDataGrid-filterRowOperationBetween":"Between","dxDataGrid-filterRowOperationBetweenStartText":"Start","dxDataGrid-filterRowOperationBetweenEndText":"End","dxDataGrid-ariaSearchBox":"Search box","dxDataGrid-applyFilterText":"Apply filter","dxDataGrid-trueText":"true","dxDataGrid-falseText":"false","dxDataGrid-sortingAscendingText":"Sort Ascending","dxDataGrid-sortingDescendingText":"Sort Descending","dxDataGrid-sortingClearText":"Clear Sorting","dxDataGrid-ariaNotSortedColumn":"Not sorted column","dxDataGrid-ariaSortedAscendingColumn":"Column sorted in ascending order","dxDataGrid-ariaSortedDescendingColumn":"Column sorted in descending order","dxDataGrid-ariaSortIndex":"Sort index {0}","dxDataGrid-editingSaveAllChanges":"Save changes","dxDataGrid-editingCancelAllChanges":"Discard changes","dxDataGrid-editingAddRow":"Add a row","dxDataGrid-summaryMin":"Min: {0}","dxDataGrid-summaryMinOtherColumn":"Min of {1} is {0}","dxDataGrid-summaryMax":"Max: {0}","dxDataGrid-summaryMaxOtherColumn":"Max of {1} is {0}","dxDataGrid-summaryAvg":"Avg: {0}","dxDataGrid-summaryAvgOtherColumn":"Avg of {1} is {0}","dxDataGrid-summarySum":"Sum: {0}","dxDataGrid-summarySumOtherColumn":"Sum of {1} is {0}","dxDataGrid-summaryCount":"Count: {0}","dxDataGrid-columnFixingFix":"Fix","dxDataGrid-columnFixingUnfix":"Unfix","dxDataGrid-columnFixingLeftPosition":"To the left","dxDataGrid-columnFixingRightPosition":"To the right","dxDataGrid-exportTo":"Export","dxDataGrid-exportToExcel":"Export to Excel file","dxDataGrid-exporting":"Exporting...","dxDataGrid-excelFormat":"Excel file","dxDataGrid-selectedRows":"Selected rows","dxDataGrid-exportSelectedRows":"Export selected rows to {0}","dxDataGrid-exportAll":"Export all data to {0}","dxDataGrid-headerFilterLabel":"Filter options","dxDataGrid-headerFilterIndicatorLabel":"Show filter options for column '{0}'","dxDataGrid-headerFilterEmptyValue":"(Blanks)","dxDataGrid-headerFilterOK":"OK","dxDataGrid-headerFilterCancel":"Cancel","dxDataGrid-ariaAdaptiveCollapse":"Hide additional data","dxDataGrid-ariaAdaptiveExpand":"Display additional data","dxDataGrid-ariaColumn":"Column","dxDataGrid-ariaColumnHeader":"Column header","dxDataGrid-ariaValue":"Value","dxDataGrid-ariaError":"Error","dxDataGrid-ariaRevertButton":"Press Escape to discard the changes","dxDataGrid-ariaFilterCell":"Filter cell","dxDataGrid-ariaCollapse":"Collapse","dxDataGrid-ariaModifiedCell":"Modified","dxDataGrid-ariaDeletedCell":"Deleted","dxDataGrid-ariaEditableCell":"Editable","dxDataGrid-ariaExpand":"Expand","dxDataGrid-ariaCollapsedRow":"Collapsed row","dxDataGrid-ariaExpandedRow":"Expanded row","dxDataGrid-ariaDataGrid":"Data grid with {0} rows and {1} columns","dxDataGrid-ariaSearchInGrid":"Search in the data grid","dxDataGrid-ariaSelectAll":"Select all","dxDataGrid-ariaSelectRow":"Select row","dxDataGrid-ariaToolbar":"Data grid toolbar","dxDataGrid-ariaEditForm":"Edit form","dxDataGrid-filterBuilderPopupTitle":"Filter Builder","dxDataGrid-filterPanelCreateFilter":"Create Filter","dxDataGrid-filterPanelClearFilter":"Clear","dxDataGrid-filterPanelFilterEnabledHint":"Enable the filter","dxDataGrid-masterDetail":"Cell with details","dxTreeList-ariaTreeList":"Tree list with {0} rows and {1} columns","dxTreeList-ariaSearchInGrid":"Search in the tree list","dxTreeList-ariaToolbar":"Tree list toolbar","dxTreeList-editingAddRowToNode":"Add","dxPager-infoText":"Page {0} of {1} ({2} items)","dxPager-pagesCountText":"of","dxPager-pageSize":"Items per page: {0}","dxPager-pageSizesAllText":"All","dxPager-page":"Page {0}","dxPager-prevPage":"Previous Page","dxPager-nextPage":"Next Page","dxPager-ariaLabel":"Page Navigation","dxPager-ariaPageSize":"Page size","dxPager-ariaPageNumber":"Page number","dxPivotGrid-grandTotal":"Grand Total","dxPivotGrid-total":"{0} Total","dxPivotGrid-fieldChooserTitle":"Field Chooser","dxPivotGrid-showFieldChooser":"Show Field Chooser","dxPivotGrid-expandAll":"Expand All","dxPivotGrid-collapseAll":"Collapse All","dxPivotGrid-sortColumnBySummary":'Sort "{0}" by This Column',"dxPivotGrid-sortRowBySummary":'Sort "{0}" by This Row',"dxPivotGrid-removeAllSorting":"Remove All Sorting","dxPivotGrid-dataNotAvailable":"N/A","dxPivotGrid-rowFields":"Row Fields","dxPivotGrid-columnFields":"Column Fields","dxPivotGrid-dataFields":"Data Fields","dxPivotGrid-filterFields":"Filter Fields","dxPivotGrid-allFields":"All Fields","dxPivotGrid-columnFieldArea":"Drop Column Fields Here","dxPivotGrid-dataFieldArea":"Drop Data Fields Here","dxPivotGrid-rowFieldArea":"Drop Row Fields Here","dxPivotGrid-filterFieldArea":"Drop Filter Fields Here","dxScheduler-editorLabelTitle":"Subject","dxScheduler-editorLabelStartDate":"Start Date","dxScheduler-editorLabelEndDate":"End Date","dxScheduler-editorLabelDescription":"Description","dxScheduler-editorLabelRecurrence":"Repeat","dxScheduler-openAppointment":"Open appointment","dxScheduler-recurrenceNever":"Never","dxScheduler-recurrenceMinutely":"Every minute","dxScheduler-recurrenceHourly":"Hourly","dxScheduler-recurrenceDaily":"Daily","dxScheduler-recurrenceWeekly":"Weekly","dxScheduler-recurrenceMonthly":"Monthly","dxScheduler-recurrenceYearly":"Yearly","dxScheduler-recurrenceRepeatEvery":"Repeat Every","dxScheduler-recurrenceRepeatOn":"Repeat On","dxScheduler-recurrenceEnd":"End repeat","dxScheduler-recurrenceAfter":"After","dxScheduler-recurrenceOn":"On","dxScheduler-recurrenceRepeatMinutely":"minute(s)","dxScheduler-recurrenceRepeatHourly":"hour(s)","dxScheduler-recurrenceRepeatDaily":"day(s)","dxScheduler-recurrenceRepeatWeekly":"week(s)","dxScheduler-recurrenceRepeatMonthly":"month(s)","dxScheduler-recurrenceRepeatYearly":"year(s)","dxScheduler-switcherDay":"Day","dxScheduler-switcherWeek":"Week","dxScheduler-switcherWorkWeek":"Work Week","dxScheduler-switcherMonth":"Month","dxScheduler-switcherAgenda":"Agenda","dxScheduler-switcherTimelineDay":"Timeline Day","dxScheduler-switcherTimelineWeek":"Timeline Week","dxScheduler-switcherTimelineWorkWeek":"Timeline Work Week","dxScheduler-switcherTimelineMonth":"Timeline Month","dxScheduler-recurrenceRepeatOnDate":"on date","dxScheduler-recurrenceRepeatCount":"occurrence(s)","dxScheduler-allDay":"All day","dxScheduler-confirmRecurrenceEditTitle":"Edit Recurring Appointment","dxScheduler-confirmRecurrenceDeleteTitle":"Delete Recurring Appointment","dxScheduler-confirmRecurrenceEditMessage":"Do you want to edit only this appointment or the whole series?","dxScheduler-confirmRecurrenceDeleteMessage":"Do you want to delete only this appointment or the whole series?","dxScheduler-confirmRecurrenceEditSeries":"Edit series","dxScheduler-confirmRecurrenceDeleteSeries":"Delete series","dxScheduler-confirmRecurrenceEditOccurrence":"Edit appointment","dxScheduler-confirmRecurrenceDeleteOccurrence":"Delete appointment","dxScheduler-noTimezoneTitle":"No timezone","dxScheduler-moreAppointments":"{0} more","dxCalendar-currentDay":"Today","dxCalendar-currentMonth":"Current month","dxCalendar-currentYear":"Current year","dxCalendar-currentYearRange":"Current year range","dxCalendar-todayButtonText":"Today","dxCalendar-ariaWidgetName":"Calendar","dxCalendar-previousMonthButtonLabel":"Previous month","dxCalendar-previousYearButtonLabel":"Previous year","dxCalendar-previousDecadeButtonLabel":"Previous decade","dxCalendar-previousCenturyButtonLabel":"Previous century","dxCalendar-nextMonthButtonLabel":"Next month","dxCalendar-nextYearButtonLabel":"Next year","dxCalendar-nextDecadeButtonLabel":"Next decade","dxCalendar-nextCenturyButtonLabel":"Next century","dxCalendar-captionMonthLabel":"Month selection","dxCalendar-captionYearLabel":"Year selection","dxCalendar-captionDecadeLabel":"Decade selection","dxCalendar-captionCenturyLabel":"Century selection","dxCalendar-selectedDate":"The selected date is {0}","dxCalendar-selectedDateRange":"The selected date range is from {0} to {1}","dxColorView-ariaRed":"Red","dxColorView-ariaGreen":"Green","dxColorView-ariaBlue":"Blue","dxColorView-ariaAlpha":"Transparency","dxColorView-ariaHex":"Color code","dxTagBox-selected":"{0} selected","dxTagBox-allSelected":"All selected ({0})","dxTagBox-moreSelected":"{0} more","dxTagBox-tagRoleDescription":"Tag. Press the delete button to remove this tag","dxTagBox-ariaRoleDescription":"Tag box","vizExport-printingButtonText":"Print","vizExport-titleMenuText":"Exporting/Printing","vizExport-exportButtonText":"{0} file","dxFilterBuilder-and":"And","dxFilterBuilder-or":"Or","dxFilterBuilder-notAnd":"Not And","dxFilterBuilder-notOr":"Not Or","dxFilterBuilder-addCondition":"Add Condition","dxFilterBuilder-addGroup":"Add Group","dxFilterBuilder-enterValueText":"<enter a value>","dxFilterBuilder-filterOperationEquals":"Equals","dxFilterBuilder-filterOperationNotEquals":"Does not equal","dxFilterBuilder-filterOperationLess":"Is less than","dxFilterBuilder-filterOperationLessOrEquals":"Is less than or equal to","dxFilterBuilder-filterOperationGreater":"Is greater than","dxFilterBuilder-filterOperationGreaterOrEquals":"Is greater than or equal to","dxFilterBuilder-filterOperationStartsWith":"Starts with","dxFilterBuilder-filterOperationContains":"Contains","dxFilterBuilder-filterOperationNotContains":"Does not contain","dxFilterBuilder-filterOperationEndsWith":"Ends with","dxFilterBuilder-filterOperationIsBlank":"Is blank","dxFilterBuilder-filterOperationIsNotBlank":"Is not blank","dxFilterBuilder-filterOperationBetween":"Is between","dxFilterBuilder-filterOperationAnyOf":"Is any of","dxFilterBuilder-filterOperationNoneOf":"Is none of","dxHtmlEditor-dialogColorCaption":"Change Font Color","dxHtmlEditor-dialogBackgroundCaption":"Change Background Color","dxHtmlEditor-dialogLinkCaption":"Add Link","dxHtmlEditor-dialogLinkUrlField":"URL","dxHtmlEditor-dialogLinkTextField":"Text","dxHtmlEditor-dialogLinkTargetField":"Open link in new window","dxHtmlEditor-dialogImageCaption":"Add Image","dxHtmlEditor-dialogImageUrlField":"URL","dxHtmlEditor-dialogImageAltField":"Alternate text","dxHtmlEditor-dialogImageWidthField":"Width (px)","dxHtmlEditor-dialogImageHeightField":"Height (px)","dxHtmlEditor-dialogInsertTableRowsField":"Rows","dxHtmlEditor-dialogInsertTableColumnsField":"Columns","dxHtmlEditor-dialogInsertTableCaption":"Insert Table","dxHtmlEditor-dialogUpdateImageCaption":"Update Image","dxHtmlEditor-dialogImageUpdateButton":"Update","dxHtmlEditor-dialogImageAddButton":"Add","dxHtmlEditor-dialogImageSpecifyUrl":"From the Web","dxHtmlEditor-dialogImageSelectFile":"From This Device","dxHtmlEditor-dialogImageKeepAspectRatio":"Keep Aspect Ratio","dxHtmlEditor-dialogImageEncodeToBase64":"Encode to Base64","dxHtmlEditor-heading":"Heading","dxHtmlEditor-normalText":"Normal text","dxHtmlEditor-background":"Background Color","dxHtmlEditor-bold":"Bold","dxHtmlEditor-color":"Font Color","dxHtmlEditor-font":"Font","dxHtmlEditor-italic":"Italic","dxHtmlEditor-link":"Add Link","dxHtmlEditor-image":"Add Image","dxHtmlEditor-size":"Size","dxHtmlEditor-strike":"Strikethrough","dxHtmlEditor-subscript":"Subscript","dxHtmlEditor-superscript":"Superscript","dxHtmlEditor-underline":"Underline","dxHtmlEditor-blockquote":"Blockquote","dxHtmlEditor-header":"Header","dxHtmlEditor-increaseIndent":"Increase Indent","dxHtmlEditor-decreaseIndent":"Decrease Indent","dxHtmlEditor-orderedList":"Ordered List","dxHtmlEditor-bulletList":"Bullet List","dxHtmlEditor-alignLeft":"Align Left","dxHtmlEditor-alignCenter":"Align Center","dxHtmlEditor-alignRight":"Align Right","dxHtmlEditor-alignJustify":"Align Justify","dxHtmlEditor-codeBlock":"Code Block","dxHtmlEditor-variable":"Add Variable","dxHtmlEditor-undo":"Undo","dxHtmlEditor-redo":"Redo","dxHtmlEditor-clear":"Clear Formatting","dxHtmlEditor-insertTable":"Insert Table","dxHtmlEditor-insertHeaderRow":"Insert Header Row","dxHtmlEditor-insertRowAbove":"Insert Row Above","dxHtmlEditor-insertRowBelow":"Insert Row Below","dxHtmlEditor-insertColumnLeft":"Insert Column Left","dxHtmlEditor-insertColumnRight":"Insert Column Right","dxHtmlEditor-deleteColumn":"Delete Column","dxHtmlEditor-deleteRow":"Delete Row","dxHtmlEditor-deleteTable":"Delete Table","dxHtmlEditor-cellProperties":"Cell Properties","dxHtmlEditor-tableProperties":"Table Properties","dxHtmlEditor-insert":"Insert","dxHtmlEditor-delete":"Delete","dxHtmlEditor-border":"Border","dxHtmlEditor-style":"Style","dxHtmlEditor-width":"Width","dxHtmlEditor-height":"Height","dxHtmlEditor-borderColor":"Color","dxHtmlEditor-borderWidth":"Border Width","dxHtmlEditor-tableBackground":"Background","dxHtmlEditor-dimensions":"Dimensions","dxHtmlEditor-alignment":"Alignment","dxHtmlEditor-horizontal":"Horizontal","dxHtmlEditor-vertical":"Vertical","dxHtmlEditor-paddingVertical":"Vertical Padding","dxHtmlEditor-paddingHorizontal":"Horizontal Padding","dxHtmlEditor-pixels":"Pixels","dxHtmlEditor-list":"List","dxHtmlEditor-ordered":"Ordered","dxHtmlEditor-bullet":"Bullet","dxHtmlEditor-align":"Align","dxHtmlEditor-center":"Center","dxHtmlEditor-left":"Left","dxHtmlEditor-right":"Right","dxHtmlEditor-indent":"Indent","dxHtmlEditor-justify":"Justify","dxHtmlEditor-borderStyleNone":"none","dxHtmlEditor-borderStyleHidden":"hidden","dxHtmlEditor-borderStyleDotted":"dotted","dxHtmlEditor-borderStyleDashed":"dashed","dxHtmlEditor-borderStyleSolid":"solid","dxHtmlEditor-borderStyleDouble":"double","dxHtmlEditor-borderStyleGroove":"groove","dxHtmlEditor-borderStyleRidge":"ridge","dxHtmlEditor-borderStyleInset":"inset","dxHtmlEditor-borderStyleOutset":"outset","dxFileManager-newDirectoryName":"Untitled directory","dxFileManager-rootDirectoryName":"Files","dxFileManager-errorNoAccess":"Access Denied. Operation could not be completed.","dxFileManager-errorDirectoryExistsFormat":"Directory '{0}' already exists.","dxFileManager-errorFileExistsFormat":"File '{0}' already exists.","dxFileManager-errorFileNotFoundFormat":"File '{0}' not found.","dxFileManager-errorDirectoryNotFoundFormat":"Directory '{0}' not found.","dxFileManager-errorWrongFileExtension":"File extension is not allowed.","dxFileManager-errorMaxFileSizeExceeded":"File size exceeds the maximum allowed size.","dxFileManager-errorInvalidSymbols":"This name contains invalid characters.","dxFileManager-errorDefault":"Unspecified error.","dxFileManager-errorDirectoryOpenFailed":"The directory cannot be opened","dxFileManager-commandCreate":"New directory","dxFileManager-commandRename":"Rename","dxFileManager-commandMove":"Move to","dxFileManager-commandCopy":"Copy to","dxFileManager-commandDelete":"Delete","dxFileManager-commandDownload":"Download","dxFileManager-commandUpload":"Upload files","dxFileManager-commandRefresh":"Refresh","dxFileManager-commandThumbnails":"Thumbnails View","dxFileManager-commandDetails":"Details View","dxFileManager-commandClearSelection":"Clear selection","dxFileManager-commandShowNavPane":"Toggle navigation pane","dxFileManager-dialogDirectoryChooserMoveTitle":"Move to","dxFileManager-dialogDirectoryChooserMoveButtonText":"Move","dxFileManager-dialogDirectoryChooserCopyTitle":"Copy to","dxFileManager-dialogDirectoryChooserCopyButtonText":"Copy","dxFileManager-dialogRenameItemTitle":"Rename","dxFileManager-dialogRenameItemButtonText":"Save","dxFileManager-dialogCreateDirectoryTitle":"New directory","dxFileManager-dialogCreateDirectoryButtonText":"Create","dxFileManager-dialogDeleteItemTitle":"Delete","dxFileManager-dialogDeleteItemButtonText":"Delete","dxFileManager-dialogDeleteItemSingleItemConfirmation":"Are you sure you want to delete {0}?","dxFileManager-dialogDeleteItemMultipleItemsConfirmation":"Are you sure you want to delete {0} items?","dxFileManager-dialogButtonCancel":"Cancel","dxFileManager-editingCreateSingleItemProcessingMessage":"Creating a directory inside {0}","dxFileManager-editingCreateSingleItemSuccessMessage":"Created a directory inside {0}","dxFileManager-editingCreateSingleItemErrorMessage":"Directory was not created","dxFileManager-editingCreateCommonErrorMessage":"Directory was not created","dxFileManager-editingRenameSingleItemProcessingMessage":"Renaming an item inside {0}","dxFileManager-editingRenameSingleItemSuccessMessage":"Renamed an item inside {0}","dxFileManager-editingRenameSingleItemErrorMessage":"Item was not renamed","dxFileManager-editingRenameCommonErrorMessage":"Item was not renamed","dxFileManager-editingDeleteSingleItemProcessingMessage":"Deleting an item from {0}","dxFileManager-editingDeleteMultipleItemsProcessingMessage":"Deleting {0} items from {1}","dxFileManager-editingDeleteSingleItemSuccessMessage":"Deleted an item from {0}","dxFileManager-editingDeleteMultipleItemsSuccessMessage":"Deleted {0} items from {1}","dxFileManager-editingDeleteSingleItemErrorMessage":"Item was not deleted","dxFileManager-editingDeleteMultipleItemsErrorMessage":"{0} items were not deleted","dxFileManager-editingDeleteCommonErrorMessage":"Some items were not deleted","dxFileManager-editingMoveSingleItemProcessingMessage":"Moving an item to {0}","dxFileManager-editingMoveMultipleItemsProcessingMessage":"Moving {0} items to {1}","dxFileManager-editingMoveSingleItemSuccessMessage":"Moved an item to {0}","dxFileManager-editingMoveMultipleItemsSuccessMessage":"Moved {0} items to {1}","dxFileManager-editingMoveSingleItemErrorMessage":"Item was not moved","dxFileManager-editingMoveMultipleItemsErrorMessage":"{0} items were not moved","dxFileManager-editingMoveCommonErrorMessage":"Some items were not moved","dxFileManager-editingCopySingleItemProcessingMessage":"Copying an item to {0}","dxFileManager-editingCopyMultipleItemsProcessingMessage":"Copying {0} items to {1}","dxFileManager-editingCopySingleItemSuccessMessage":"Copied an item to {0}","dxFileManager-editingCopyMultipleItemsSuccessMessage":"Copied {0} items to {1}","dxFileManager-editingCopySingleItemErrorMessage":"Item was not copied","dxFileManager-editingCopyMultipleItemsErrorMessage":"{0} items were not copied","dxFileManager-editingCopyCommonErrorMessage":"Some items were not copied","dxFileManager-editingUploadSingleItemProcessingMessage":"Uploading an item to {0}","dxFileManager-editingUploadMultipleItemsProcessingMessage":"Uploading {0} items to {1}","dxFileManager-editingUploadSingleItemSuccessMessage":"Uploaded an item to {0}","dxFileManager-editingUploadMultipleItemsSuccessMessage":"Uploaded {0} items to {1}","dxFileManager-editingUploadSingleItemErrorMessage":"Item was not uploaded","dxFileManager-editingUploadMultipleItemsErrorMessage":"{0} items were not uploaded","dxFileManager-editingUploadCanceledMessage":"Canceled","dxFileManager-editingDownloadSingleItemErrorMessage":"Item was not downloaded","dxFileManager-editingDownloadMultipleItemsErrorMessage":"{0} items were not downloaded","dxFileManager-listDetailsColumnCaptionName":"Name","dxFileManager-listDetailsColumnCaptionDateModified":"Date Modified","dxFileManager-listDetailsColumnCaptionFileSize":"File Size","dxFileManager-listThumbnailsTooltipTextSize":"Size","dxFileManager-listThumbnailsTooltipTextDateModified":"Date Modified","dxFileManager-notificationProgressPanelTitle":"Progress","dxFileManager-notificationProgressPanelEmptyListText":"No operations","dxFileManager-notificationProgressPanelOperationCanceled":"Canceled","dxDiagram-categoryGeneral":"General","dxDiagram-categoryFlowchart":"Flowchart","dxDiagram-categoryOrgChart":"Org Chart","dxDiagram-categoryContainers":"Containers","dxDiagram-categoryCustom":"Custom","dxDiagram-commandExportToSvg":"Export to SVG","dxDiagram-commandExportToPng":"Export to PNG","dxDiagram-commandExportToJpg":"Export to JPEG","dxDiagram-commandUndo":"Undo","dxDiagram-commandRedo":"Redo","dxDiagram-commandFontName":"Font Name","dxDiagram-commandFontSize":"Font Size","dxDiagram-commandBold":"Bold","dxDiagram-commandItalic":"Italic","dxDiagram-commandUnderline":"Underline","dxDiagram-commandTextColor":"Font Color","dxDiagram-commandLineColor":"Line Color","dxDiagram-commandLineWidth":"Line Width","dxDiagram-commandLineStyle":"Line Style","dxDiagram-commandLineStyleSolid":"Solid","dxDiagram-commandLineStyleDotted":"Dotted","dxDiagram-commandLineStyleDashed":"Dashed","dxDiagram-commandFillColor":"Fill Color","dxDiagram-commandAlignLeft":"Align Left","dxDiagram-commandAlignCenter":"Align Center","dxDiagram-commandAlignRight":"Align Right","dxDiagram-commandConnectorLineType":"Connector Line Type","dxDiagram-commandConnectorLineStraight":"Straight","dxDiagram-commandConnectorLineOrthogonal":"Orthogonal","dxDiagram-commandConnectorLineStart":"Connector Line Start","dxDiagram-commandConnectorLineEnd":"Connector Line End","dxDiagram-commandConnectorLineNone":"None","dxDiagram-commandConnectorLineArrow":"Arrow","dxDiagram-commandFullscreen":"Full Screen","dxDiagram-commandUnits":"Units","dxDiagram-commandPageSize":"Page Size","dxDiagram-commandPageOrientation":"Page Orientation","dxDiagram-commandPageOrientationLandscape":"Landscape","dxDiagram-commandPageOrientationPortrait":"Portrait","dxDiagram-commandPageColor":"Page Color","dxDiagram-commandShowGrid":"Show Grid","dxDiagram-commandSnapToGrid":"Snap to Grid","dxDiagram-commandGridSize":"Grid Size","dxDiagram-commandZoomLevel":"Zoom Level","dxDiagram-commandAutoZoom":"Auto Zoom","dxDiagram-commandFitToContent":"Fit to Content","dxDiagram-commandFitToWidth":"Fit to Width","dxDiagram-commandAutoZoomByContent":"Auto Zoom by Content","dxDiagram-commandAutoZoomByWidth":"Auto Zoom by Width","dxDiagram-commandSimpleView":"Simple View","dxDiagram-commandCut":"Cut","dxDiagram-commandCopy":"Copy","dxDiagram-commandPaste":"Paste","dxDiagram-commandSelectAll":"Select All","dxDiagram-commandDelete":"Delete","dxDiagram-commandBringToFront":"Bring to Front","dxDiagram-commandSendToBack":"Send to Back","dxDiagram-commandLock":"Lock","dxDiagram-commandUnlock":"Unlock","dxDiagram-commandInsertShapeImage":"Insert Image...","dxDiagram-commandEditShapeImage":"Change Image...","dxDiagram-commandDeleteShapeImage":"Delete Image","dxDiagram-commandLayoutLeftToRight":"Left-to-right","dxDiagram-commandLayoutRightToLeft":"Right-to-left","dxDiagram-commandLayoutTopToBottom":"Top-to-bottom","dxDiagram-commandLayoutBottomToTop":"Bottom-to-top","dxDiagram-unitIn":"in","dxDiagram-unitCm":"cm","dxDiagram-unitPx":"px","dxDiagram-dialogButtonOK":"OK","dxDiagram-dialogButtonCancel":"Cancel","dxDiagram-dialogInsertShapeImageTitle":"Insert Image","dxDiagram-dialogEditShapeImageTitle":"Change Image","dxDiagram-dialogEditShapeImageSelectButton":"Select image","dxDiagram-dialogEditShapeImageLabelText":"or drop a file here","dxDiagram-uiExport":"Export","dxDiagram-uiProperties":"Properties","dxDiagram-uiSettings":"Settings","dxDiagram-uiShowToolbox":"Show Toolbox","dxDiagram-uiSearch":"Search","dxDiagram-uiStyle":"Style","dxDiagram-uiLayout":"Layout","dxDiagram-uiLayoutTree":"Tree","dxDiagram-uiLayoutLayered":"Layered","dxDiagram-uiDiagram":"Diagram","dxDiagram-uiText":"Text","dxDiagram-uiObject":"Object","dxDiagram-uiConnector":"Connector","dxDiagram-uiPage":"Page","dxDiagram-shapeText":"Text","dxDiagram-shapeRectangle":"Rectangle","dxDiagram-shapeEllipse":"Ellipse","dxDiagram-shapeCross":"Cross","dxDiagram-shapeTriangle":"Triangle","dxDiagram-shapeDiamond":"Diamond","dxDiagram-shapeHeart":"Heart","dxDiagram-shapePentagon":"Pentagon","dxDiagram-shapeHexagon":"Hexagon","dxDiagram-shapeOctagon":"Octagon","dxDiagram-shapeStar":"Star","dxDiagram-shapeArrowLeft":"Left Arrow","dxDiagram-shapeArrowUp":"Up Arrow","dxDiagram-shapeArrowRight":"Right Arrow","dxDiagram-shapeArrowDown":"Down Arrow","dxDiagram-shapeArrowUpDown":"Up Down Arrow","dxDiagram-shapeArrowLeftRight":"Left Right Arrow","dxDiagram-shapeProcess":"Process","dxDiagram-shapeDecision":"Decision","dxDiagram-shapeTerminator":"Terminator","dxDiagram-shapePredefinedProcess":"Predefined Process","dxDiagram-shapeDocument":"Document","dxDiagram-shapeMultipleDocuments":"Multiple Documents","dxDiagram-shapeManualInput":"Manual Input","dxDiagram-shapePreparation":"Preparation","dxDiagram-shapeData":"Data","dxDiagram-shapeDatabase":"Database","dxDiagram-shapeHardDisk":"Hard Disk","dxDiagram-shapeInternalStorage":"Internal Storage","dxDiagram-shapePaperTape":"Paper Tape","dxDiagram-shapeManualOperation":"Manual Operation","dxDiagram-shapeDelay":"Delay","dxDiagram-shapeStoredData":"Stored Data","dxDiagram-shapeDisplay":"Display","dxDiagram-shapeMerge":"Merge","dxDiagram-shapeConnector":"Connector","dxDiagram-shapeOr":"Or","dxDiagram-shapeSummingJunction":"Summing Junction","dxDiagram-shapeContainerDefaultText":"Container","dxDiagram-shapeVerticalContainer":"Vertical Container","dxDiagram-shapeHorizontalContainer":"Horizontal Container","dxDiagram-shapeCardDefaultText":"Person's Name","dxDiagram-shapeCardWithImageOnLeft":"Card with Image on the Left","dxDiagram-shapeCardWithImageOnTop":"Card with Image on the Top","dxDiagram-shapeCardWithImageOnRight":"Card with Image on the Right","dxGantt-dialogTitle":"Title","dxGantt-dialogStartTitle":"Start","dxGantt-dialogEndTitle":"End","dxGantt-dialogProgressTitle":"Progress","dxGantt-dialogResourcesTitle":"Resources","dxGantt-dialogResourceManagerTitle":"Resource Manager","dxGantt-dialogTaskDetailsTitle":"Task Details","dxGantt-dialogEditResourceListHint":"Edit Resource List","dxGantt-dialogEditNoResources":"No resources","dxGantt-dialogButtonAdd":"Add","dxGantt-contextMenuNewTask":"New Task","dxGantt-contextMenuNewSubtask":"New Subtask","dxGantt-contextMenuDeleteTask":"Delete Task","dxGantt-contextMenuDeleteDependency":"Delete Dependency","dxGantt-dialogTaskDeleteConfirmation":"Deleting a task also deletes all its dependencies and subtasks. Are you sure you want to delete this task?","dxGantt-dialogDependencyDeleteConfirmation":"Are you sure you want to delete the dependency from the task?","dxGantt-dialogResourcesDeleteConfirmation":"Deleting a resource also deletes it from tasks to which this resource is assigned. Are you sure you want to delete these resources? Resources: {0}","dxGantt-dialogConstraintCriticalViolationMessage":"The task you are attempting to move is linked to a second task by a dependency relation. This change would conflict with dependency rules. How would you like to proceed?","dxGantt-dialogConstraintViolationMessage":"The task you are attempting to move is linked to a second task by a dependency relation. How would you like to proceed?","dxGantt-dialogCancelOperationMessage":"Cancel the operation","dxGantt-dialogDeleteDependencyMessage":"Delete the dependency","dxGantt-dialogMoveTaskAndKeepDependencyMessage":"Move the task and keep the dependency","dxGantt-dialogConstraintCriticalViolationSeveralTasksMessage":"The task you are attempting to move is linked to another tasks by dependency relations. This change would conflict with dependency rules. How would you like to proceed?","dxGantt-dialogConstraintViolationSeveralTasksMessage":"The task you are attempting to move is linked to another tasks by dependency relations. How would you like to proceed?","dxGantt-dialogDeleteDependenciesMessage":"Delete the dependency relations","dxGantt-dialogMoveTaskAndKeepDependenciesMessage":"Move the task and keep the dependencies","dxGantt-undo":"Undo","dxGantt-redo":"Redo","dxGantt-expandAll":"Expand All","dxGantt-collapseAll":"Collapse All","dxGantt-addNewTask":"Add New Task","dxGantt-deleteSelectedTask":"Delete Selected Task","dxGantt-zoomIn":"Zoom In","dxGantt-zoomOut":"Zoom Out","dxGantt-fullScreen":"Full Screen","dxGantt-quarter":"Q{0}","dxGantt-sortingAscendingText":"Sort Ascending","dxGantt-sortingDescendingText":"Sort Descending","dxGantt-sortingClearText":"Clear Sorting","dxGantt-showResources":"Show Resources","dxGantt-showDependencies":"Show Dependencies","dxGantt-dialogStartDateValidation":"Start date must be after {0}","dxGantt-dialogEndDateValidation":"End date must be after {0}","dxGallery-itemName":"Gallery item","dxMultiView-elementAriaRoleDescription":"MultiView","dxMultiView-elementAriaLabel":"Use the arrow keys or swipe to navigate between views","dxMultiView-itemAriaRoleDescription":"View","dxMultiView-itemAriaLabel":"{0} of {1}","dxSplitter-resizeHandleAriaLabel":"Split bar","dxSplitter-resizeHandleAriaRoleDescription":"Separator"}};var fG=m(!0,{},BI),_G=(i,e)=>{var t;return i[e]||e?.toLowerCase&&((t=Object.entries(i).find(n=>{let[o]=n;return o.toLowerCase()===e.toLowerCase()}))===null||t===void 0?void 0:t[1])||{}},eC={},CG=wt({engine:function(){return"base"},_dictionary:fG,load:function(i){m(!0,this._dictionary,i)},_localizablePrefix:"@",setup:function(i){this._localizablePrefix=i},localizeString:function(i){let e=this,t=new RegExp("(^|[^a-zA-Z_0-9"+e._localizablePrefix+"-]+)("+e._localizablePrefix+"{1,2})([a-zA-Z_0-9-]+)","g"),n=e._localizablePrefix+e._localizablePrefix;return i.replace(t,(o,s,r,a)=>{let l=e._localizablePrefix+a,d;return r!==n&&(d=e.format(a)),d||(eC[a]=aw(a)),s+(d||l)})},getMessagesByLocales:function(){return this._dictionary},getDictionary:function(i){return i?eC:m({},eC,this.getMessagesByLocales()[Xi.locale()])},getFormatter:function(i){return this._getFormatterBase(i)||this._getFormatterBase(i,"en")},_getFormatterBase:function(i,e){let t=Xi.getValueByClosestLocale(n=>_G(this._dictionary,n)[i]);if(t)return function(){let n=arguments.length===1&&Array.isArray(arguments[0])?arguments[0].slice(0):Array.prototype.slice.call(arguments,0);return n.unshift(t),Ii.apply(this,n)}},format:function(i){let e=this.getFormatter(i),t=Array.prototype.slice.call(arguments,1);return e&&e.apply(this,t)||""}}),O=CG;var xG=function(i,e){return 1/i===1/e},VI=function(i,e){return i=Ot(i,!0),e=Ot(e,!0),i&&e&&$t(i)&&$t(e)?e.is(i):i!==i&&e!==e?!0:i===0&&e===0?xG(i,e):i===null||typeof i!="object"||w.isElementNode(i)?i===e:!1};var tC={},go=i=>{let e=F.current();return i.reduce((t,n)=>{let{device:o,options:s}=n,r=o||{};return(A(r)?r(e):vG(e,r))&&m(!0,t,s),t},{})},LI=(i,e)=>typeof i!="string"?i:{[i]:e},vG=(i,e)=>dt(e)||eh(i,[e]).length>0,iC=i=>i.substr(i.lastIndexOf(".")+1),nC=i=>i.substr(0,i.lastIndexOf(".")),NI=function(i,e){return tC[e]=tC[e]||me(e),tC[e](i,{functionsAsIs:!0})},HI=function(){return arguments.length>0&&arguments[0]!==void 0?arguments[0]:[]};var oC={},sC={},qh=class{constructor(e,t){this._options=e,this._optionsByReference=t,this._changingCallback,this._changedCallback,this._namePreparedCallbacks}_setByReference(e,t){m(!0,e,t);for(let n in this._optionsByReference)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}_setPreparedValue(e,t,n,o){let s=this.get(this._options,e,!1);if(!VI(s,t)){let r=Fn(e);!o&&this._changingCallback(e,s,t),sC[e]=sC[e]||Ga(e),sC[e](this._options,t,{functionsAsIs:!0,merge:f(n)?n:!this._optionsByReference[e],unwrapObservables:r.length>1&&!!this._optionsByReference[r[0]]}),!o&&this._changedCallback(e,t,s)}}_prepareRelevantNames(e,t,n,o){if(q(n))for(let s in n)this._prepareRelevantNames(e,`${t}.${s}`,n[s]);this._namePreparedCallbacks(e,t,n,o)}get(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._options,t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;return oC[t]=oC[t]||me(t),oC[t](e,{functionsAsIs:!0,unwrapObservables:n})}set(e,t,n,o){e=LI(e,t);for(let s in e)this._prepareRelevantNames(e,s,e[s],o);for(let s in e)this._setPreparedValue(s,e[s],n,o)}onRelevantNamesPrepared(e){this._namePreparedCallbacks=e}onChanging(e){this._changingCallback=e}onChanged(e){this._changedCallback=e}dispose(){this._changingCallback=S,this._changedCallback=S}};var Yh=class{constructor(e,t,n,o){this._deprecatedCallback,this._startChangeCallback,this._endChangeCallback,this._default=t,this._deprecated=o,this._deprecatedNames=[],this._initDeprecatedNames(),this._optionManager=new qh(e,n),this._optionManager.onRelevantNamesPrepared((s,r,a,l)=>this._setRelevantNames(s,r,a,l)),this._cachedOptions={},this._rules=[]}set _initial(e){this._initialOptions=e}get _initial(){if(!this._initialOptions){let e=this._getByRules(this.silent("defaultOptionsRules"));this._initialOptions=this._default,this._optionManager._setByReference(this._initialOptions,e)}return this._initialOptions}_initDeprecatedNames(){for(let e in this._deprecated)this._deprecatedNames.push(e)}_getByRules(e){return e=Array.isArray(e)?this._rules.concat(e):this._rules,go(e)}_notifyDeprecated(e){let t=this._deprecated[e];t&&this._deprecatedCallback(e,t)}_setRelevantNames(e,t,n,o){if(t){let s=this._normalizeName(t,o);s&&s!==t&&(this._setField(e,s,n),this._clearField(e,t))}}_setField(e,t,n){let o="",s=null;do o=o?`.${o}`:"",o=iC(t)+o,t=nC(t),s=t?this._optionManager.get(e,t,!1):e;while(!s);s[o]=n}_clearField(e,t){delete e[t];let n=nC(t),o=n?this._optionManager.get(e,n,!1):e;o&&delete o[iC(t)]}_normalizeName(e,t){if(this._deprecatedNames.length&&e){for(let n=0;n<this._deprecatedNames.length;n++)if(this._deprecatedNames[n]===e){let o=this._deprecated[e];if(o)return!t&&this._notifyDeprecated(e),o.alias||e}}return e}addRules(e){this._rules=e.concat(this._rules)}applyRules(e){let t=this._getByRules(e);this.silent(t)}dispose(){this._deprecatedCallback=S,this._startChangeCallback=S,this._endChangeCallback=S,this._optionManager.dispose()}onChanging(e){this._optionManager.onChanging(e)}onChanged(e){this._optionManager.onChanged(e)}onDeprecated(e){this._deprecatedCallback=e}onStartChange(e){this._startChangeCallback=e}onEndChange(e){this._endChangeCallback=e}isInitial(e){let t=this.silent(e),n=this.initial(e);return A(t)&&A(n)?t.toString()===n.toString():ve(t,n)}initial(e){return NI(this._initial,e)}option(e,t){if(arguments.length<2&&ri(e)!=="object")return this._optionManager.get(void 0,this._normalizeName(e));this._startChangeCallback();try{this._optionManager.set(e,t)}finally{this._endChangeCallback()}}silent(e,t){if(arguments.length<2&&ri(e)!=="object")return this._optionManager.get(void 0,e,void 0,!0);this._optionManager.set(e,t,void 0,!0)}reset(e){if(e){let n=Fn(e).reduce((s,r)=>s?s[r]:this.initial(r),null),o=$(n)?I({},n):n;this._optionManager.set(e,o,!1)}}getAliasesByName(e){return Object.keys(this._deprecated).filter(t=>e===this._deprecated[t].alias)}isDeprecated(e){return Object.prototype.hasOwnProperty.call(this._deprecated,e)}cache(e,t){if(arguments.length<2)return this._cachedOptions[e];this._cachedOptions[e]=m(this._cachedOptions[e],t)}};var Xh=class{constructor(){this._postponedOperations={}}add(e,t,n){if(e in this._postponedOperations)n&&this._postponedOperations[e].promises.push(n);else{let o=new y;this._postponedOperations[e]={fn:t,completePromise:o,promises:n?[n]:[]}}return this._postponedOperations[e].completePromise.promise()}callPostponedOperations(){for(let e in this._postponedOperations){let t=this._postponedOperations[e];f(t)&&(t.promises&&t.promises.length?P(...t.promises).done(t.fn).then(t.completePromise.resolve):t.fn().done(t.completePromise.resolve))}this._postponedOperations={}}};var $I=i=>i.charAt(2).toLowerCase()+i.substr(3),bG=i=>i.indexOf("_",0)===0,rC=ce.inherit({_setDeprecatedOptions(){this._deprecatedOptions={}},_getDeprecatedOptions(){return this._deprecatedOptions},_getDefaultOptions:()=>({onInitialized:null,onOptionChanged:null,onDisposing:null,defaultOptionsRules:null}),_defaultOptionsRules:()=>[],_setOptionsByDevice(i){this._options.applyRules(i)},_convertRulesToOptions:i=>go(i),_isInitialOptionValue(i){return this._options.isInitial(i)},_setOptionsByReference(){this._optionsByReference={}},_getOptionsByReference(){return this._optionsByReference},ctor(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{_optionChangedCallbacks:e,_disposingCallbacks:t}=i;this.NAME=ar(this.constructor),this._eventsStrategy=Ln.create(this,i.eventsStrategy),this._updateLockCount=0,this._optionChangedCallbacks=e||ue(),this._disposingCallbacks=t||ue(),this.postponedOperations=new Xh,this._createOptions(i)},_createOptions(i){this.beginUpdate();try{this._setOptionsByReference(),this._setDeprecatedOptions(),this._options=new Yh(this._getDefaultOptions(),this._getDefaultOptions(),this._getOptionsByReference(),this._getDeprecatedOptions()),this._options.onChanging((e,t,n)=>this._initialized&&this._optionChanging(e,t,n)),this._options.onDeprecated((e,t)=>this._logDeprecatedOptionWarning(e,t)),this._options.onChanged((e,t,n)=>this._notifyOptionChanged(e,t,n)),this._options.onStartChange(()=>this.beginUpdate()),this._options.onEndChange(()=>this.endUpdate()),this._options.addRules(this._defaultOptionsRules()),i&&i.onInitializing&&i.onInitializing.apply(this,[i]),this._setOptionsByDevice(i.defaultOptionsRules),this._initOptions(i)}finally{this.endUpdate()}},_initOptions(i){this.option(i)},_init(){this._createOptionChangedAction(),this.on("disposing",i=>{this._disposingCallbacks.fireWith(this,[i])})},_logDeprecatedOptionWarning(i,e){let t=e.message||`Use the '${e.alias}' option instead`;he.log("W0001",this.NAME,i,e.since,t)},_logDeprecatedComponentWarning(i,e){he.log("W0000",this.NAME,i,`Use the '${e}' widget instead`)},_createOptionChangedAction(){this._optionChangedAction=this._createActionByOption("onOptionChanged",{excludeValidators:["disabled","readOnly"]})},_createDisposingAction(){this._disposingAction=this._createActionByOption("onDisposing",{excludeValidators:["disabled","readOnly"]})},_optionChanged(i){switch(i.name){case"onDisposing":case"onInitialized":case"defaultOptionsRules":break;case"onOptionChanged":this._createOptionChangedAction()}},_dispose(){this._optionChangedCallbacks.empty(),this._createDisposingAction(),this._disposingAction(),this._eventsStrategy.dispose(),this._options.dispose(),this._disposed=!0},_lockUpdate(){this._updateLockCount++},_unlockUpdate(){this._updateLockCount=Math.max(this._updateLockCount-1,0)},_isUpdateAllowed(){return this._updateLockCount===0},_isInitializingRequired(){return!this._initializing&&!this._initialized},isInitialized(){return this._initialized},_commitUpdate(){this.postponedOperations.callPostponedOperations(),this._isInitializingRequired()&&this._initializeComponent()},_initializeComponent(){this._initializing=!0;try{this._init()}finally{this._initializing=!1,this._lockUpdate(),this._createActionByOption("onInitialized",{excludeValidators:["disabled","readOnly"]})(),this._unlockUpdate(),this._initialized=!0}},instance(){return this},beginUpdate:function(){this._lockUpdate()},endUpdate:function(){this._unlockUpdate(),this._isUpdateAllowed()&&this._commitUpdate()},_optionChanging:S,_notifyOptionChanged(i,e,t){if(this._initialized){let n=[i].concat(this._options.getAliasesByName(i));for(let o=0;o<n.length;o++){let s=n[o],r={name:Fn(s)[0],fullName:s,value:e,previousValue:t};bG(s)||(this._optionChangedCallbacks.fireWith(this,[m(this._defaultActionArgs(),r)]),this._optionChangedAction(m({},r))),!this._disposed&&this._cancelOptionChange!==s&&this._optionChanged(r)}}},initialOption(i){return this._options.initial(i)},_defaultActionConfig(){return{context:this,component:this}},_defaultActionArgs(){return{component:this}},_createAction(i,e){let t;return n=>(f(n)||(n={}),q(n)||(n={actionValue:n}),t=t||new po(i,m({},e,this._defaultActionConfig())),t.execute.call(t,m(n,this._defaultActionArgs())))},_createActionByOption(i,e){var t=this;let n,o,s;e=m({},e);let r=function(){if(!o){if(e=e||{},typeof i!="string")throw he.Error("E0008");i.indexOf("on")===0&&(o=$I(i)),s=t.option(i)}if(!(!n&&!s&&!e.beforeExecute&&!e.afterExecute&&!t._eventsStrategy.hasEvent(o))){if(!n){let h=e.beforeExecute;e.beforeExecute=function(){for(var p=arguments.length,g=new Array(p),C=0;C<p;C++)g[C]=arguments[C];h&&h.apply(t,g),t._eventsStrategy.fireEvent(o,g[0].args)},n=t._createAction(s,e)}for(var l=arguments.length,d=new Array(l),c=0;c<l;c++)d[c]=arguments[c];return fe().wrapActionsBeforeExecute?((t.option("beforeActionExecute")||S)(t,n,e)||n).apply(t,d):n.apply(t,d)}};return fe().wrapActionsBeforeExecute?r:(this.option("onActionCreated")||S)(this,r,e)||r},on(i,e){return this._eventsStrategy.on(i,e),this},off(i,e){return this._eventsStrategy.off(i,e),this},hasActionSubscription:function(i){return!!this._options.silent(i)||this._eventsStrategy.hasEvent($I(i))},isOptionDeprecated(i){return this._options.isDeprecated(i)},_setOptionWithoutOptionChange(i,e){this._cancelOptionChange=i,this.option(i,e),this._cancelOptionChange=!1},_getOptionValue(i,e){let t=this.option(i);return A(t)?t.bind(e)():t},option(){return this._options.option(...arguments)},resetOption(i){this.beginUpdate(),this._options.reset(i),this.endUpdate()}});var gn=class extends sn{constructor(e){super(),this._render=e}_renderCore(e){return Xr(this._render(e))}};var yG=new gn(i=>{let{model:e,parent:t}=i,n=e.widget;if(!n)return u();let o=u("<div>"),s=e.options||{};return t?t._createComponent(o,n,s):o[n](s),o}),cc=class{constructor(e,t){this._tempTemplates=[],this._defaultTemplates={},this._anonymousTemplateName=t||"template",this._createElement=e||TI,this._createTemplateIfNeeded=this._createTemplateIfNeeded.bind(this)}static createDefaultOptions(){return{integrationOptions:{watchMethod:function(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:{}).skipImmediate||t(e()),S},templates:{"dx-polymorph-widget":yG},useDeferUpdateForTemplates:!0}}}get anonymousTemplateName(){return this._anonymousTemplateName}addDefaultTemplates(e){this._defaultTemplates=m({},this._defaultTemplates,e)}dispose(){this._tempTemplates.forEach(e=>{e.template.dispose&&e.template.dispose()}),this._tempTemplates=[]}extractTemplates(e){let t=this._extractTemplates(e),n=this._extractAnonymousTemplate(e);return{templates:t,anonymousTemplateMeta:n}}_extractTemplates(e){let t=Gh(e,"dxTemplate"),n=EI(t);return t.forEach(o=>{let{element:s,options:{name:r}}=o;s===n[r]?u(s).addClass("dx-template-wrapper").detach():u(s).remove()}),Object.keys(n).map(o=>({name:o,template:this._createTemplate(n[o])}))}_extractAnonymousTemplate(e){let t=e.contents().detach();return t.filter((o,s)=>{let r=s.nodeType===3,a=u(s).text().trim().length<1;return!(r&&a)}).length>0?{template:this._createTemplate(t),name:this._anonymousTemplateName}:{}}_createTemplateIfNeeded(e){let t=this._tempTemplates.filter(o=>o.source===Q_(e))[0];if(t)return t.template;let n=this._createTemplate(e);return this._tempTemplates.push({template:n,source:Q_(e)}),n}_createTemplate(e){return this._createElement(DI(e))}getTemplate(e,t,n,o){let{isAsyncTemplate:s,skipTemplates:r}=n;return A(e)?new gn(a=>{let l=e.apply(o,II(a));if(!f(l))return new Vi;let d=!1,c=Z_(l,p=>p.nodeType||$t(p)&&!u(p).is("script")?new gn(()=>p):(d=!0,this._createTemplate(p)),t,s,r,this._defaultTemplates),h=c.render(a);return d&&c.dispose&&c.dispose(),h}):Z_(e,this._createTemplateIfNeeded,t,s,r,this._defaultTemplates)}};var aC="KeyboardProcessor",zI=i=>({keyName:De(i),key:i.key,code:i.code,ctrl:i.ctrlKey,location:i.location,metaKey:i.metaKey,shift:i.shiftKey,alt:i.altKey,which:i.which,originalEvent:i}),WI=ce.inherit({_keydown:D("keydown",aC),_compositionStart:D("compositionstart",aC),_compositionEnd:D("compositionend",aC),ctor:function(i){i=i||{},i.element&&(this._element=u(i.element)),i.focusTarget&&(this._focusTarget=i.focusTarget),this._handler=i.handler,this._element&&(this._processFunction=e=>{let t=u(this._focusTarget).toArray(),n=this._focusTarget&&this._focusTarget!==e.target&&!t.includes(e.target),o=this._isComposingJustFinished&&e.which===229||this._isComposing||n;this._isComposingJustFinished=!1,o||this.process(e)},this._toggleProcessingWithContext=this.toggleProcessing.bind(this),_.on(this._element,this._keydown,this._processFunction),_.on(this._element,this._compositionStart,this._toggleProcessingWithContext),_.on(this._element,this._compositionEnd,this._toggleProcessingWithContext))},dispose:function(){this._element&&(_.off(this._element,this._keydown,this._processFunction),_.off(this._element,this._compositionStart,this._toggleProcessingWithContext),_.off(this._element,this._compositionEnd,this._toggleProcessingWithContext)),this._element=void 0,this._handler=void 0},process:function(i){this._handler(zI(i))},toggleProcessing:function(i){let{type:e}=i;this._isComposing=e==="compositionstart",this._isComposingJustFinished=!this._isComposing}});WI.createKeyDownOptions=zI;var Qh=WI;function qt(i,e){return e?D(i,e):i}function lC(i,e){return typeof i=="function"?i(e):i.execute(e)}var dC={on:(i,e,t,n)=>{let{selector:o,showTimeout:s,hideTimeout:r,namespace:a}=n;_.on(i,qt("dxactive",a),o,{timeout:s},l=>lC(e,{event:l,element:l.currentTarget})),_.on(i,qt("dxinactive",a),o,{timeout:r},l=>lC(t,{event:l,element:l.currentTarget}))},off:(i,e)=>{let{namespace:t,selector:n}=e;_.off(i,qt("dxactive",t),n),_.off(i,qt("dxinactive",t),n)}},cl={on:function(i,e){let{namespace:t}=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};_.on(i,qt("dxresize",t),e)},off:function(i){let{namespace:e}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};_.off(i,qt("dxresize",e))}},cC={on:(i,e,t,n)=>{let{selector:o,namespace:s}=n;_.on(i,qt("dxhoverend",s),o,r=>t(r)),_.on(i,qt("dxhoverstart",s),o,r=>lC(e,{element:r.target,event:r}))},off:(i,e)=>{let{selector:t,namespace:n}=e;_.off(i,qt("dxhoverstart",n),t),_.off(i,qt("dxhoverend",n),t)}},ul={on:(i,e,t,n)=>{let{namespace:o}=n;_.on(i,qt("dxhiding",o),t),_.on(i,qt("dxshown",o),e)},off:(i,e)=>{let{namespace:t}=e;_.off(i,qt("dxhiding",t)),_.off(i,qt("dxshown",t))}},hl={on:(i,e,t,n)=>{let{namespace:o}=n;_.on(i,qt("focusin",o),e),_.on(i,qt("focusout",o),t)},off:(i,e)=>{let{namespace:t}=e;_.off(i,qt("focusin",t)),_.off(i,qt("focusout",t))},trigger:i=>_.trigger(i,"focus")},uC={on:function(i,e){let{namespace:t}=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};_.on(i,qt("dxclick",t),e)},off:function(i){let{namespace:e}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};_.off(i,qt("dxclick",e))}},hC={on:function(i,e){let{namespace:t}=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};_.on(i,qt("click",t),e)},off:function(i){let{namespace:e}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};_.off(i,qt("click",e))}},OG=0,uc={},SG=()=>"keyboardProcessorId"+OG++,Kn={on:(i,e,t)=>{let n=SG();return uc[n]=new Qh({element:i,focusTarget:e,handler:t}),n},off:i=>{i&&uc[i]&&(uc[i].dispose(),delete uc[i])},_getProcessor:i=>uc[i]};var EG=[],wG=".";function IG(i){let{major:e,minor:t,patch:n}=i;return[e,t,n].join(wG)}function pC(i){let[e,t,n]=i.split(".").map(Number);return{major:e,minor:t,patch:n}}function DG(i){return i.map(e=>`${e.packageName}: ${e.version}`).join(`
`)}function TG(i,e){return i.major===e.major&&i.minor===e.minor&&i.patch===e.patch}function GI(i){let{major:e,minor:t,patch:n}=i;return t===1?{major:e-1,minor:2,patch:n}:{major:e,minor:t-1,patch:n}}function KI(i){let e=EG.filter(t=>!TG(pC(t.version),i));return e.length?(he.log("W0023",DG([{packageName:"devextreme",version:IG(i)},...e])),!1):!0}function UI(i){return new Uint8Array(atob(i).split("").map(e=>e.charCodeAt(0)))}function jI(i){var e;return new Uint8Array(((e=i.match(/.{1,2}/g))===null||e===void 0?void 0:e.map(t=>parseInt(t,16)))??[])}function qI(i){let e=new Uint8Array(i.length);for(let t=0;t<i.length;t+=1)e[t]=255&i.charCodeAt(t);return e}function YI(i){let e=new Uint8Array(4*i.length);for(let t=0;t<e.length;t+=1)e[t]=i[t>>2]>>>8*(3-t%4);return e}function XI(i){let e=new Uint32Array(1+(i.length-1>>2));for(let t=0;t<i.length;t+=1)e[t>>2]|=i[t]<<8*(3-t%4);return e}function gC(i,e){return(i<<e|i>>>32-e)>>>0}function mC(i,e){let t=new Uint8Array(i.length+e.length);return t.set(i,0),t.set(e,i.length),t}var Zh={e:65537,n:new Uint8Array([200,219,153,203,140,7,228,253,193,243,62,137,139,60,68,242,48,142,113,88,185,235,253,105,80,74,32,170,96,74,111,250,7,205,154,3,146,115,153,53,45,132,123,56,61,208,184,201,63,24,109,223,0,179,169,102,139,224,73,233,45,173,138,66,98,88,69,76,177,111,113,218,192,33,101,152,25,134,34,173,32,82,230,44,247,200,253,170,192,246,30,12,96,205,100,249,181,93,0,231])},QI="Tv3jUCG8VU28WQMlFQFESQ";var AG="3021300906052b0e03021a05000414";function ZI(i){let e=(8*Zh.n.length+6)/8,t=mC(jI(AG),i);if(t.length+10>e)throw Error("Key is too short for SHA1 signing algorithm");let n=new Uint8Array(e-t.length);return n.fill(255,0,n.length-1),n[0]=0,n[1]=1,n[n.length-1]=0,mC(n,t)}function JI(i){try{let e=BigInt(0),t=BigInt(1),n=BigInt(8),o=(h,p,g)=>{let C=t,v=h,b=p;for(;b;)b&t&&(C=C*v%g),v=v*v%g,b>>=t;return C},s=h=>h.reduce((p,g)=>(p<<n)+BigInt(g),e),r=s(i.actual),a=s(i.signature),l=BigInt(i.key.e),d=s(i.key.n);return o(a,l,d)===r}catch{return!0}}function MG(i){let e=new Uint8Array(i.length+1);e.set(qI(i)),e[e.length-1]=128;let t=XI(new Uint8Array(e)),n=new Uint32Array(16*Math.ceil((t.length+2)/16));return n.set(t,0),n[n.length-1]=8*(e.length-1),n}function eD(i){let e=MG(i),t=new Uint32Array([1732584193,4023233417,2562383102,271733878,3285377520]);for(let n=0;n<e.length;n+=16){let o=new Uint32Array(80);for(let c=0;c<16;c+=1)o[c]=e[n+c];for(let c=16;c<80;c+=1){let h=o[c-3]^o[c-8]^o[c-14]^o[c-16];o[c]=h<<1|h>>>31}let s=t[0],r=t[1],a=t[2],l=t[3],d=t[4];for(let c=0;c<80;c+=1){let[h,p]=c<20?[r&a|~r&l,1518500249]:c<40?[r^a^l,1859775393]:c<60?[r&a|r&l|a&l,2400959708]:[r^a^l,3395469782],g=gC(s,5)+h+d+p+o[c];d=l,l=a,a=gC(r,30),r=s,s=g}t[0]+=s,t[1]+=r,t[2]+=a,t[3]+=l,t[4]+=d}return YI(t)}var _C=()=>typeof HTMLElement<"u"&&typeof customElements<"u",nD=_C()?HTMLElement:class{};var ia={trigger:"dx-license-trigger",panel:"dx-license"},Un={buyNow:"buy-now",licensingDoc:"licensing-doc",version:"version"},oD={opacity:"1",visibility:"visible","clip-path":"none",filter:"none"},sD=I({},oD,{width:"100%",height:"auto","line-height":"normal",display:"block","z-index":"1500",position:"static",transform:"translate(0px, 0px)","background-color":"#FF7200",border:"none",margin:"auto","box-sizing":"border-box","text-align":"center"}),RG=I({},sD,{display:"flex","align-items":"center","flex-direction":"row",position:"relative",top:"0px",left:"0px",padding:"0.5rem"}),FG={width:"1rem",cursor:"pointer",height:"1rem"},tD=I({},oD,{display:"inline",position:"static",padding:"0px",margin:"0px",color:"white","font-family":"'Segoe UI','Open Sans Condensed',-apple-system,BlinkMacSystemFont,avenir next,avenir,helvetica neue,helvetica,Cantarell,Ubuntu,roboto,noto,arial,sans-serif","font-size":"0.875rem","font-wight":"600"});function xs(i,e){let t=e?I({},i,e):i;return Object.keys(t).reduce((n,o)=>`${n}${[o,`${t[o]} !important;`].join(": ")}`,"")}var iD=(()=>{class i extends nD{constructor(){var t,n,o,s,r;super(),this._observer=null,this._inReassign=!1,this._hidden=!1,this._spanStyles=xs(tD,(t=i.customStyles)===null||t===void 0?void 0:t.textStyles),this._linkStyles=xs(tD,(n=i.customStyles)===null||n===void 0?void 0:n.linkStyles),this._containerStyles=xs(RG,(o=i.customStyles)===null||o===void 0?void 0:o.containerStyles),this._contentStyles=xs(sD,(s=i.customStyles)===null||s===void 0?void 0:s.contentStyles),this._buttonStyles=xs(FG,(r=i.customStyles)===null||r===void 0?void 0:r.contentStyles)}_createSpan(t){let n=document.createElement("span");return n.innerText=t,n.style.cssText=this._spanStyles,n}_createLink(t,n){let o=document.createElement("a");return o.innerText=t,o.style.cssText=this._linkStyles,o.href=n,o.target="_blank",o}_createButton(){let t=document.createElement("div");t.style.cssText=this._buttonStyles;let n=document.createElementNS("http://www.w3.org/2000/svg","polygon"),o=document.createElementNS("http://www.w3.org/2000/svg","svg");return n.setAttribute("points","13.4 12.7 8.7 8 13.4 3.4 12.6 2.6 8 7.3 3.4 2.6 2.6 3.4 7.3 8 2.6 12.6 3.4 13.4 8 8.7 12.7 13.4 13.4 12.7"),n.style.cssText=xs({fill:"#fff",opacity:".5","stroke-width":"0px"}),o.setAttribute("id","Layer_1"),o.setAttribute("data-name","Layer 1"),o.setAttribute("version","1.1"),o.setAttribute("viewBox","0 0 16 16"),o.style.cssText=xs({"vertical-align":"baseline"}),o.appendChild(n),t.appendChild(o),t.onclick=()=>{this._hidden=!0,this.style.cssText=xs({display:"none"})},t}_createContentContainer(){let t=document.createElement("div");return t.style.cssText=this._contentStyles,t.append(this._createSpan("For evaluation purposes only. Redistribution prohibited. Please "),this._createLink("register",this.getAttribute(Un.licensingDoc)),this._createSpan(" an existing license or "),this._createLink("purchase a new license",this.getAttribute(Un.buyNow)),this._createSpan(` to continue use of DevExpress product libraries (v${this.getAttribute(Un.version)}).`)),t}_reassignComponent(){this.innerHTML="",this.style.cssText=this._containerStyles,this.append(this._createContentContainer(),this._createButton())}connectedCallback(){this._reassignComponent(),this._observer||(this._observer=new MutationObserver(()=>{if(this._hidden){var t;(t=this._observer)===null||t===void 0||t.disconnect();return}this._inReassign?this._inReassign=!1:(this._inReassign=!0,this._reassignComponent())}),this._observer.observe(this,{childList:!0,attributes:!0,subtree:!0}))}disconnectedCallback(){setTimeout(()=>{document.getElementsByTagName(ia.panel).length||document.body.prepend(this)},100)}}return i.customStyles=void 0,i})(),fC=class extends nD{connectedCallback(){if(this.style.cssText=xs({display:"none"}),!document.getElementsByTagName(ia.panel).length){let t=document.createElement(ia.panel);t.setAttribute(Un.version,this.getAttribute(Un.version)),t.setAttribute(Un.buyNow,this.getAttribute(Un.buyNow)),t.setAttribute(Un.licensingDoc,this.getAttribute(Un.licensingDoc)),t.setAttribute("data-permanent","true"),document.body.prepend(t)}}};function rD(i){customElements.get(ia.trigger)||(iD.customStyles=i,customElements.define(ia.trigger,fC),customElements.define(ia.panel,iD))}function aD(i,e,t,n){rD(n);let o=document.createElement(ia.trigger);o.setAttribute(Un.buyNow,i),o.setAttribute(Un.licensingDoc,e),o.setAttribute(Un.version,t),document.body.appendChild(o)}function lD(i,e,t,n){_C()&&aD(i,e,t,n)}var En;(function(i){i.corrupted="corrupted",i.verified="verified",i.internal="internal"})(En||(En={}));var PG=["customerId","maxVersionAllowed","format","internalUsageId"],kG=1,BG=3,VG=".",LG="https://go.devexpress.com/Licensing_Installer_Watermark_DevExtremeJQuery.aspx",NG="https://go.devexpress.com/Licensing_Documentation_DevExtremeJQuery.aspx",dD={kind:En.corrupted,error:"general"},HG={kind:En.corrupted,error:"verification"},$G={kind:En.corrupted,error:"decoding"},zG={kind:En.corrupted,error:"deserialization"},WG={kind:En.corrupted,error:"payload"},GG={kind:En.corrupted,error:"version"},CC=!1;function KG(i){let{text:e,signature:t}=i;return JI({key:Zh,signature:UI(t),actual:ZI(eD(e))})}function UG(i){if(i===void 0)return dD;let e=i.split(VG);if(e.length!==2||e[0].length===0||e[1].length===0)return dD;if(!KG({text:e[0],signature:e[1]}))return HG;let t="";try{t=atob(e[0])}catch{return $G}let n={};try{n=JSON.parse(t)}catch{return zG}let{customerId:o,maxVersionAllowed:s,format:r,internalUsageId:a}=n,l=ge(n,PG);return a!==void 0?{kind:En.internal,internalUsageId:a}:o===void 0||s===void 0||r===void 0?WG:r!==kG?GG:{kind:En.verified,payload:I({customerId:o,maxVersionAllowed:s},l)}}function cD(i){return isNaN(i)||i<BG}function jG(i){let{licenseKey:e,version:t}=i,n=!1;try{n=cD(t.patch);let{major:o,minor:s}=n?GI(t):t;if(!e)return{preview:n,error:"W0019"};let r=UG(e);return r.kind===En.corrupted?{preview:n,error:"W0021"}:r.kind===En.internal?{preview:n,internal:!0,error:r.internalUsageId===QI?void 0:"W0020"}:o&&s?10*o+s>r.payload.maxVersionAllowed?{preview:n,error:"W0020"}:{preview:n,error:void 0}:{preview:n,error:"W0021"}}catch{return{preview:n,error:"W0021"}}}function qG(i){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Sf;if(CC)return;CC=!0;let t=pC(e),n=KI(t),{internal:o,error:s}=jG({licenseKey:i,version:t});if(!n&&o)return;if(s&&!o){let a=fe().buyNowLink??LG,l=fe().licensingDocLink??NG;lD(a,l,Sf)}let r=cD(t.patch);if(s){he.log(r?"W0022":s);return}r&&!o&&he.log("W0022")}function xC(){return CC}var uD={validateLicense:qG};var{abstract:Jh}=rC,vC=rC.inherit({_getDefaultOptions(){return m(this.callBase(),{width:void 0,height:void 0,rtlEnabled:fe().rtlEnabled,elementAttr:{},disabled:!1,integrationOptions:{}},this._useTemplates()?cc.createDefaultOptions():{})},ctor(i,e){this._customClass=null,this._createElement(i),Dh(this._$element,this,this._dispose),this.callBase(e);let t=xC();uD.validateLicense(fe().licenseKey),!t&&xC()&&fe({licenseKey:""})},_createElement(i){this._$element=u(i)},_getSynchronizableOptionsForCreateComponent:()=>["rtlEnabled","disabled","templatesRenderAsynchronously"],_checkFunctionValueDeprecation:function(i){this.option("_ignoreFunctionValueDeprecation")||i.forEach(e=>{A(this.option(e))&&he.log("W0017",e)})},_visibilityChanged:Jh,_dimensionChanged:Jh,_init(){this.callBase(),this._checkFunctionValueDeprecation(["width","height","maxHeight","maxWidth","minHeight","minWidth","popupHeight","popupWidth"]),this._attachWindowResizeCallback(),this._initTemplateManager()},_setOptionsByDevice(i){this.callBase([].concat(this.constructor._classCustomRules||[],i||[]))},_isInitialOptionValue(i){return!(this.constructor._classCustomRules&&Object.prototype.hasOwnProperty.call(this._convertRulesToOptions(this.constructor._classCustomRules),i))&&this.callBase(i)},_attachWindowResizeCallback(){if(this._isDimensionChangeSupported()){let i=this._windowResizeCallBack=this._dimensionChanged.bind(this);co.add(i)}},_isDimensionChangeSupported(){return this._dimensionChanged!==Jh},_renderComponent(){WE(this.$element()),this._initMarkup(),W()&&this._render()},_initMarkup(){let{rtlEnabled:i}=this.option()||{};this._renderElementAttributes(),this._toggleRTLDirection(i),this._renderVisibilityChange(),this._renderDimensions()},_render(){this._attachVisibilityChangeHandlers()},_renderElementAttributes(){let{elementAttr:i}=this.option()||{},e=m({},i),t=e.class;delete e.class,this.$element().attr(e).removeClass(this._customClass).addClass(t),this._customClass=t},_renderVisibilityChange(){this._isDimensionChangeSupported()&&this._attachDimensionChangeHandlers(),this._isVisibilityChangeSupported()&&this.$element().addClass("dx-visibility-change-handler")},_renderDimensions(){let i=this.$element(),e=i.get(0),t=this._getOptionValue("width",e),n=this._getOptionValue("height",e);this._isCssUpdateRequired(e,n,t)&&i.css({width:t===null?"":t,height:n===null?"":n})},_isCssUpdateRequired:(i,e,t)=>!!(f(t)||f(e)||i.style.width||i.style.height),_attachDimensionChangeHandlers(){let i=this.$element(),e=`${this.NAME}VisibilityChange`;cl.off(i,{namespace:e}),cl.on(i,()=>this._dimensionChanged(),{namespace:e})},_attachVisibilityChangeHandlers(){if(this._isVisibilityChangeSupported()){let i=this.$element(),e=`${this.NAME}VisibilityChange`;this._isHidden=!this._isVisible(),ul.off(i,{namespace:e}),ul.on(i,()=>this._checkVisibilityChanged("shown"),()=>this._checkVisibilityChanged("hiding"),{namespace:e})}},_isVisible(){return this.$element().is(":visible")},_checkVisibilityChanged(i){this._isVisible()&&(i==="hiding"&&!this._isHidden?(this._visibilityChanged(!1),this._isHidden=!0):i==="shown"&&this._isHidden&&(this._isHidden=!1,this._visibilityChanged(!0)))},_isVisibilityChangeSupported(){return this._visibilityChanged!==Jh&&W()},_clean:S,_modelByElement(){let{modelByElement:i}=this.option(),e=this.$element();return i?i(e):void 0},_invalidate(){if(this._isUpdateAllowed())throw he.Error("E0007");this._requireRefresh=!0},_refresh(){this._clean(),this._renderComponent()},_dispose(){this._templateManager&&this._templateManager.dispose(),this.callBase(),this._clean(),this._detachWindowResizeCallback()},_detachWindowResizeCallback(){this._isDimensionChangeSupported()&&co.remove(this._windowResizeCallBack)},_toggleRTLDirection(i){this.$element().toggleClass("dx-rtl",i)},_createComponent(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=xt(this._getSynchronizableOptionsForCreateComponent(),l=>!(l in t)),{integrationOptions:o}=this.option(),{nestedComponentOptions:s}=this.option();s=s||S;let r=m({integrationOptions:o},s(this));n.forEach(l=>r[l]=this.option(l)),this._extendConfig(t,r);let a;if(B(e)?a=u(i)[e](t)[e]("instance"):i&&(a=e.getInstance(i),a?a.option(t):a=new e(i,t)),a){let l=d=>{let{name:c,value:h}=d;n.includes(c)&&a.option(c,h)};this.on("optionChanged",l),a.on("disposing",()=>this.off("optionChanged",l))}return a},_extendConfig(i,e){x(e,(t,n)=>{!Object.prototype.hasOwnProperty.call(i,t)&&(i[t]=n)})},_defaultActionConfig(){let i=this.$element(),e=this._modelByElement(i);return m(this.callBase(),{context:e})},_defaultActionArgs(){let i=this.$element(),e=this._modelByElement(i),t=this.element();return m(this.callBase(),{element:t,model:e})},_optionChanged(i){switch(i.name){case"width":case"height":this._renderDimensions();break;case"rtlEnabled":this._invalidate();break;case"elementAttr":this._renderElementAttributes();break;case"disabled":case"integrationOptions":break;default:this.callBase(i)}},_removeAttributes(i){let e=i.attributes;for(let t=e.length-1;t>=0;t--){let n=e[t];if(n){let{name:o}=n;(!o.indexOf("aria-")||o.indexOf("dx-")!==-1||o==="role"||o==="style"||o==="tabindex")&&i.removeAttribute(o)}}},_removeClasses(i){i.className=i.className.split(" ").filter(e=>e.lastIndexOf("dx-",0)!==0).join(" ")},_updateDOMComponent(i){i?this._renderComponent():this._requireRefresh&&(this._requireRefresh=!1,this._refresh())},endUpdate(){let i=this._isInitializingRequired();this.callBase(),this._isUpdateAllowed()&&this._updateDOMComponent(i)},$element(){return this._$element},element(){let i=this.$element();return N(i)},dispose(){let i=this.$element().get(0);nr(i,!0),i.textContent="",this._removeAttributes(i),this._removeClasses(i)},resetOption(i){if(this.callBase(i),i==="width"||i==="height"){let e=this.initialOption(i);!f(e)&&this.$element().css(i,"")}},_getAnonymousTemplateName(){},_initTemplateManager(){if(this._templateManager||!this._useTemplates())return;let{integrationOptions:i={}}=this.option(),{createTemplate:e}=i;this._templateManager=new cc(e,this._getAnonymousTemplateName()),this._initTemplates()},_initTemplates(){let{templates:i,anonymousTemplateMeta:e}=this._templateManager.extractTemplates(this.$element()),t=this.option(`integrationOptions.templates.${e.name}`);i.forEach(n=>{let{name:o,template:s}=n;this._options.silent(`integrationOptions.templates.${o}`,s)}),e.name&&!t&&(this._options.silent(`integrationOptions.templates.${e.name}`,e.template),this._options.silent("_hasAnonymousTemplateContent",!0))},_getTemplateByOption(i){return this._getTemplate(this.option(i))},_getTemplate(i){let e=this.option("integrationOptions.templates"),t=this.option("templatesRenderAsynchronously"),n=this.option("integrationOptions.skipTemplates");return this._templateManager.getTemplate(i,e,{isAsyncTemplate:t,skipTemplates:n},this)},_saveTemplate(i,e){this._setOptionWithoutOptionChange("integrationOptions.templates."+i,this._templateManager._createTemplate(e))},_useTemplates:()=>!0});vC.getInstance=function(i){return Th(u(i),this)};vC.defaultOptions=function(i){this._classCustomRules=this._classCustomRules||[],this._classCustomRules.push(i)};var Qi=vC;function ep(i,e,t){function n(s){return typeof s=="string"?s.split("."):typeof s=="number"?[s]:s}i=n(i),e=n(e);let o=Math.max(i.length,e.length);isFinite(t)&&(o=Math.min(o,t));for(let s=0;s<o;s++){let r=parseInt(i[s]||0,10),a=parseInt(e[s]||0,10);if(r<a)return-1;if(r>a)return 1}return 0}var hD="dxactive";var tp=ce.inherit({ctor:function(i,e){this._timeout=i,this._fire=e},start:function(){let i=this;this._schedule(function(){i.force()})},_schedule:function(i){this.stop(),this._timer=setTimeout(i,this._timeout)},stop:function(){clearTimeout(this._timer)},force:function(){this._fired||(this.stop(),this._fire(),this._fired=!0)},fired:function(){return this._fired}}),mo,bC=lr.inherit({ctor:function(){this.callBase.apply(this,arguments),this._active=new tp(0,S),this._inactive=new tp(0,S)},configure:function(i,e){switch(e){case"dxactive":i.activeTimeout=i.timeout;break;case"dxinactive":i.inactiveTimeout=i.timeout}this.callBase(i)},start:function(i){if(mo){let e=on(this.getElement().get(0),mo.getElement().get(0)),t=!mo._active.fired();if(e&&t){this._cancel();return}mo._inactive.force()}mo=this,this._initEvents(i),this._active.start()},_initEvents:function(i){let e=this,t=this._getEmitterTarget(i),n=$n(i),s=F.isSimulator()||!n,r=Te(this.activeTimeout,30),a=Te(this.inactiveTimeout,400);this._active=new tp(s?r:0,function(){e._fireEvent("dxactive",i,{target:t})}),this._inactive=new tp(s?a:0,function(){e._fireEvent("dxinactive",i,{target:t}),mo=null})},cancel:function(i){this.end(i)},end:function(i){let e=i.type!==ne.up;e?this._active.stop():this._active.force(),this._inactive.start(),e&&this._inactive.force()},dispose:function(){this._active.stop(),this._inactive.stop(),mo===this&&(mo=null),this.callBase()},lockInactive:function(){return this._active.force(),this._inactive.stop(),mo=null,this._cancel(),this._inactive.force.bind(this._inactive)}});bC.lock=function(i){let e=mo?mo.lockInactive():S;i.done(e)};Wn({emitter:bC,events:["dxactive","dxinactive"]});var ip=bC.lock;var pr="dxhoverstart",YG=D(ne.enter,"dxHoverStart");var gr="dxhoverend",XG=D(ne.leave,"dxHoverEnd"),pD=ce.inherit({noBubble:!0,ctor:function(){this._handlerArrayKeyPath=this._eventNamespace+"_HandlerStore"},setup:function(i){$e(i,this._handlerArrayKeyPath,{})},add:function(i,e){let t=this,n=function(o){t._handler(o)};_.on(i,this._originalEventName,e.selector,n),$e(i,this._handlerArrayKeyPath)[e.guid]=n},_handler:function(i){gs(i)||F.isSimulator()||ji({type:this._eventName,originalEvent:i,delegateTarget:i.delegateTarget})},remove:function(i,e){let t=$e(i,this._handlerArrayKeyPath)[e.guid];_.off(i,this._originalEventName,e.selector,t)},teardown:function(i){ir(i,this._handlerArrayKeyPath)}}),QG=pD.inherit({ctor:function(){this._eventNamespace="dxHoverStart",this._eventName=pr,this._originalEventName=YG,this.callBase()},_handler:function(i){(i.pointers||[]).length||this.callBase(i)}}),ZG=pD.inherit({ctor:function(){this._eventNamespace="dxHoverEnd",this._eventName=gr,this._originalEventName=XG,this.callBase()}});vi(pr,new QG);vi(gr,new ZG);function gD(i,e,t){i=i==="role"||i==="id"?i:`aria-${i}`,e=f(e)?e.toString():null,t.attr(i,e)}var yC=Qi.inherit({_feedbackHideTimeout:400,_feedbackShowTimeout:30,_supportedKeys:()=>({}),_getDefaultOptions(){return m(this.callBase(),{hoveredElement:null,isActive:!1,disabled:!1,visible:!0,hint:void 0,activeStateEnabled:!1,onContentReady:null,hoverStateEnabled:!1,focusStateEnabled:!1,tabIndex:0,accessKey:void 0,onFocusIn:null,onFocusOut:null,onKeyboardHandled:null,ignoreParentReadOnly:!1,useResizeObserver:!0})},_defaultOptionsRules:function(){return this.callBase().concat([{device:function(){let i=F.real(),e=i.platform,t=i.version;return e==="ios"&&ep(t,"13.3")<=0},options:{useResizeObserver:!1}}])},_init(){this.callBase(),this._initContentReadyAction()},_innerWidgetOptionChanged:function(i,e){let t=yC.getOptionsFromContainer(e);i&&i.option(t),this._options.cache(e.name,t)},_bindInnerWidgetOptions(i,e){let t=()=>this._options.silent(e,m({},i.option()));t(),i.on("optionChanged",t)},_getAriaTarget(){return this._focusTarget()},_initContentReadyAction(){this._contentReadyAction=this._createActionByOption("onContentReady",{excludeValidators:["disabled","readOnly"]})},_initMarkup(){let{disabled:i,visible:e}=this.option();this.$element().addClass("dx-widget"),this._toggleDisabledState(i),this._toggleVisibility(e),this._renderHint(),this._isFocusable()&&this._renderFocusTarget(),this.callBase()},_render(){this.callBase(),this._renderContent(),this._renderFocusState(),this._attachFeedbackEvents(),this._attachHoverEvents(),this._toggleIndependentState()},_renderHint(){let{hint:i}=this.option();this.$element().attr("title",i||null)},_renderContent(){nt(()=>this._disposed?void 0:this._renderContentImpl()).done(()=>this._disposed?void 0:this._fireContentReadyAction())},_renderContentImpl:S,_fireContentReadyAction:Ao(function(){return this._contentReadyAction()}),_dispose(){this._contentReadyAction=null,this._detachKeyboardEvents(),this.callBase()},_resetActiveState(){this._toggleActiveState(this._eventBindingTarget(),!1)},_clean(){this._cleanFocusState(),this._resetActiveState(),this.callBase(),this.$element().empty()},_toggleVisibility(i){this.$element().toggleClass("dx-state-invisible",!i)},_renderFocusState(){this._attachKeyboardEvents(),this._isFocusable()&&(this._renderFocusTarget(),this._attachFocusEvents(),this._renderAccessKey())},_renderAccessKey(){let i=this._focusTarget(),{accessKey:e}=this.option();i.attr("accesskey",e)},_isFocusable(){let{focusStateEnabled:i,disabled:e}=this.option();return i&&!e},_eventBindingTarget(){return this.$element()},_focusTarget(){return this._getActiveElement()},_isFocusTarget:function(i){return u(this._focusTarget()).toArray().includes(i)},_findActiveTarget(i){return i.find(this._activeStateUnit).not(".dx-state-disabled")},_getActiveElement(){let i=this._eventBindingTarget();return this._activeStateUnit?this._findActiveTarget(i):i},_renderFocusTarget(){let{tabIndex:i}=this.option();this._focusTarget().attr("tabIndex",i)},_keyboardEventBindingTarget(){return this._eventBindingTarget()},_refreshFocusEvent(){this._detachFocusEvents(),this._attachFocusEvents()},_focusEventTarget(){return this._focusTarget()},_focusInHandler(i){i.isDefaultPrevented()||this._createActionByOption("onFocusIn",{beforeExecute:()=>this._updateFocusState(i,!0),excludeValidators:["readOnly"]})({event:i})},_focusOutHandler(i){i.isDefaultPrevented()||this._createActionByOption("onFocusOut",{beforeExecute:()=>this._updateFocusState(i,!1),excludeValidators:["readOnly","disabled"]})({event:i})},_updateFocusState(i,e){let{target:t}=i;this._isFocusTarget(t)&&this._toggleFocusClass(e,u(t))},_toggleFocusClass(i,e){(e&&e.length?e:this._focusTarget()).toggleClass("dx-state-focused",i)},_hasFocusClass(i){return u(i||this._focusTarget()).hasClass("dx-state-focused")},_isFocused(){return this._hasFocusClass()},_getKeyboardListeners:()=>[],_attachKeyboardEvents(){this._detachKeyboardEvents();let{focusStateEnabled:i,onKeyboardHandled:e}=this.option(),t=this._getKeyboardListeners().length;(i||t||!!e)&&(this._keyboardListenerId=Kn.on(this._keyboardEventBindingTarget(),this._focusTarget(),s=>this._keyboardHandler(s)))},_keyboardHandler(i,e){if(!e){let{originalEvent:o,keyName:s,which:r}=i,a=this._supportedKeys(o),l=a[s]||a[r];if(l!==void 0&&!l.bind(this)(o,i))return!1}let t=this._getKeyboardListeners(),{onKeyboardHandled:n}=this.option();return t.forEach(o=>o&&o._keyboardHandler(i)),n&&n(i),!0},_refreshFocusState(){this._cleanFocusState(),this._renderFocusState()},_cleanFocusState(){this._focusTarget().removeAttr("tabIndex"),this._toggleFocusClass(!1),this._detachFocusEvents(),this._detachKeyboardEvents()},_detachKeyboardEvents(){Kn.off(this._keyboardListenerId),this._keyboardListenerId=null},_attachHoverEvents(){let{hoverStateEnabled:i}=this.option(),e=this._activeStateUnit,t=this._eventBindingTarget();cC.off(t,{selector:e,namespace:"UIFeedback"}),i&&cC.on(t,new po(n=>{let{event:o,element:s}=n;this._hoverStartHandler(o),this.option("hoveredElement",u(s))},{excludeValidators:["readOnly"]}),n=>{this.option("hoveredElement",null),this._hoverEndHandler(n)},{selector:e,namespace:"UIFeedback"})},_attachFeedbackEvents(){let{activeStateEnabled:i}=this.option(),e=this._activeStateUnit,t=this._eventBindingTarget();dC.off(t,{namespace:"UIFeedback",selector:e}),i&&dC.on(t,new po(n=>{let{event:o,element:s}=n;return this._toggleActiveState(u(s),!0,o)}),new po(n=>{let{event:o,element:s}=n;return this._toggleActiveState(u(s),!1,o)},{excludeValidators:["disabled","readOnly"]}),{showTimeout:this._feedbackShowTimeout,hideTimeout:this._feedbackHideTimeout,selector:e,namespace:"UIFeedback"})},_detachFocusEvents(){let i=this._focusEventTarget();hl.off(i,{namespace:`${this.NAME}Focus`})},_attachFocusEvents(){let i=this._focusEventTarget();hl.on(i,e=>this._focusInHandler(e),e=>this._focusOutHandler(e),{namespace:`${this.NAME}Focus`,isFocusable:(e,t)=>u(t).is(qd)})},_hoverStartHandler:S,_hoverEndHandler:S,_toggleActiveState(i,e){this.option("isActive",e),i.toggleClass("dx-state-active",e)},_updatedHover(){let i=this._options.silent("hoveredElement");this._hover(i,i)},_findHoverTarget(i){return i&&i.closest(this._activeStateUnit||this._eventBindingTarget())},_hover(i,e){let{hoverStateEnabled:t,disabled:n,isActive:o}=this.option();if(e=this._findHoverTarget(e),e&&e.toggleClass("dx-state-hover",!1),i&&t&&!n&&!o){let s=this._findHoverTarget(i);s&&s.toggleClass("dx-state-hover",!0)}},_toggleDisabledState(i){this.$element().toggleClass("dx-state-disabled",!!i),this.setAria("disabled",i||void 0)},_toggleIndependentState(){this.$element().toggleClass("dx-state-independent",this.option("ignoreParentReadOnly"))},_setWidgetOption(i,e){if(!this[i])return;if(q(e[0])){x(e[0],(s,r)=>this._setWidgetOption(i,[s,r]));return}let t=e[0],n=e[1];e.length===1&&(n=this.option(t));let o=this[`${i}OptionMap`];this[i].option(o?o(t):t,n)},_optionChanged(i){let{name:e,value:t,previousValue:n}=i;switch(e){case"disabled":this._toggleDisabledState(t),this._updatedHover(),this._refreshFocusState();break;case"hint":this._renderHint();break;case"ignoreParentReadOnly":this._toggleIndependentState();break;case"activeStateEnabled":this._attachFeedbackEvents();break;case"hoverStateEnabled":this._attachHoverEvents(),this._updatedHover();break;case"tabIndex":case"focusStateEnabled":this._refreshFocusState();break;case"onFocusIn":case"onFocusOut":case"useResizeObserver":break;case"accessKey":this._renderAccessKey();break;case"hoveredElement":this._hover(t,n);break;case"isActive":this._updatedHover();break;case"visible":this._toggleVisibility(t),this._isVisibilityChangeSupported()&&this._checkVisibilityChanged(t?"shown":"hiding");break;case"onKeyboardHandled":this._attachKeyboardEvents();break;case"onContentReady":this._initContentReadyAction();break;default:this.callBase(i)}},_isVisible(){let{visible:i}=this.option();return this.callBase()&&i},beginUpdate(){this._ready(!1),this.callBase()},endUpdate(){this.callBase(),this._initialized&&this._ready(!0)},_ready(i){if(arguments.length===0)return this._isReady;this._isReady=i},setAria(){if(!q(arguments.length<=0?void 0:arguments[0]))gD(arguments.length<=0?void 0:arguments[0],arguments.length<=1?void 0:arguments[1],(arguments.length<=2?void 0:arguments[2])||this._getAriaTarget());else{let i=(arguments.length<=1?void 0:arguments[1])||this._getAriaTarget();x(arguments.length<=0?void 0:arguments[0],(e,t)=>gD(e,t,i))}},isReady(){return this._ready()},repaint(){this._refresh()},focus(){hl.trigger(this._focusTarget())},registerKeyHandler(i,e){let t=this._supportedKeys();this._supportedKeys=()=>m(t,{[i]:e})}});yC.getOptionsFromContainer=i=>{let{name:e,fullName:t,value:n}=i,o={};if(e===t)o=n;else{let s=t.split(".").pop();o[s]=n}return o};var Xe=yC;var JG=function(i,e,t){let n=function(){let o;return function(s){o!==s&&(t(s,o),o=s)}}();return{dispose:i(e,n),force(){n(e())}}},mD=ce.inherit({ctor(i,e,t){this._$element=i,this._options=e,this._rawData=t,Dh(i,this,this._dispose),this._render()},_render(){let i=u("<div>").addClass("dx-item-content-placeholder");this._$element.append(i),this._watchers=[],this._renderWatchers()},_renderWatchers(){this._startWatcher("disabled",this._renderDisabled.bind(this)),this._startWatcher("visible",this._renderVisible.bind(this))},_startWatcher(i,e){let t=this._rawData,n=this._options.fieldGetter(i),o=JG(this._options.watchMethod(),()=>n(t),(s,r)=>{this._dirty=!0,e(s,r)});this._watchers.push(o)},setDataField(){if(this._dirty=!1,x(this._watchers,(i,e)=>{e.force()}),this._dirty)return!0},_renderDisabled(i,e){this._$element.toggleClass("dx-state-disabled",!!i),this._$element.attr("aria-disabled",!!i),this._updateOwnerFocus(i)},_updateOwnerFocus(i){let e=this._options.owner;e&&i&&e._resetItemFocus(this._$element)},_renderVisible(i,e){this._$element.toggleClass("dx-state-invisible",i!==void 0&&!i)},_dispose(){x(this._watchers,(i,e)=>{e.dispose()})}});mD.getInstance=function(i){return Th(i,this)};var jn=mD;var np="dx-item";var eK="dx-empty-collection";var tK=/^([^.]+\[\d+\]\.)+([\w.]+)$/;var fD=Xe.inherit({_activeStateUnit:`.${np}`,_supportedKeys(){let i=function(e,t){ot(t)||(t.preventDefault(),t.stopPropagation(),this._moveFocus(e,t))};return m(this.callBase(),{space:function(e){e.preventDefault(),this._enterKeyHandler(e)},enter:this._enterKeyHandler,leftArrow:i.bind(this,"left"),rightArrow:i.bind(this,"right"),upArrow:i.bind(this,"up"),downArrow:i.bind(this,"down"),pageUp:i.bind(this,"up"),pageDown:i.bind(this,"down"),home:i.bind(this,"first"),end:i.bind(this,"last")})},_enterKeyHandler(i){let e=u(this.option("focusedElement"));if(!e.length)return;let t=this._getItemData(e);t!=null&&t.onClick&&this._itemEventHandlerByHandler(e,t.onClick,{event:i}),this._itemClickHandler(m({},i,{target:e.get(0),currentTarget:e.get(0)}))},_getDefaultOptions(){return m(this.callBase(),{selectOnFocus:!1,loopItemFocus:!0,items:[],itemTemplate:"item",onItemRendered:null,onItemClick:null,onItemHold:null,itemHoldTimeout:750,onItemContextMenu:null,onFocusedItemChanged:null,noDataText:O.format("dxCollectionWidget-noDataText"),encodeNoDataText:!1,dataSource:null,_dataController:null,_itemAttributes:{},itemTemplateProperty:"template",focusOnSelectedItem:!0,focusedElement:null,displayExpr:void 0,disabledExpr:i=>i?i.disabled:void 0,visibleExpr:i=>i?i.visible:void 0})},_init(){this._compileDisplayGetter(),this._initDataController(),this.callBase(),this._cleanRenderedItems(),this._refreshDataSource()},_compileDisplayGetter(){let i=this.option("displayExpr");this._displayGetter=i?me(this.option("displayExpr")):void 0},_initTemplates(){this._initItemsFromMarkup(),this._initDefaultItemTemplate(),this.callBase()},_getAnonymousTemplateName:()=>"item",_initDefaultItemTemplate(){let i=this._getFieldsMap();this._templateManager.addDefaultTemplates({item:new di((e,t)=>{q(t)?this._prepareDefaultItemTemplate(t,e):(i&&A(i.text)&&(t=i.text(t)),e.text(String(Te(t,""))))},this._getBindableFields(),this.option("integrationOptions.watchMethod"),i)})},_getBindableFields:()=>["text","html"],_getFieldsMap(){if(this._displayGetter)return{text:this._displayGetter}},_prepareDefaultItemTemplate(i,e){f(i.text)&&e.text(i.text),f(i.html)&&e.html(i.html)},_initItemsFromMarkup(){let i=Gh(this.$element(),"dxItem");if(!i.length||this.option("items").length)return;let e=i.map(t=>{let{element:n,options:o}=t;return/\S/.test(n.innerHTML)&&!o.template?o.template=this._prepareItemTemplate(n):u(n).remove(),o});this.option("items",e)},_prepareItemTemplate(i){let e="tmpl-"+new Oe,t=u(i).detach().clone().removeAttr("data-options").addClass("dx-template-wrapper");return this._saveTemplate(e,t),e},_dataSourceOptions:()=>({paginate:!1}),_cleanRenderedItems(){this._renderedItemsCount=0},_focusTarget(){return this.$element()},_focusInHandler(i){if(this.callBase.apply(this,arguments),!this._isFocusTarget(i.target))return;let e=u(this.option("focusedElement"));if(e.length)this._setFocusedItem(e);else{let t=this._getActiveItem();t.length&&this.option("focusedElement",N(t))}},_focusOutHandler(){this.callBase.apply(this,arguments);let i=u(this.option("focusedElement"));this._updateFocusedItemState(i,!1)},_findActiveTarget(i){return i.find(this._activeStateUnit)},_getActiveItem(i){let e=u(this.option("focusedElement"));if(e.length)return e;let t=this.option("focusOnSelectedItem")?this.option("selectedIndex"):0,n=this._getActiveElement(),o=n.length-1;return t<0&&(t=i?o:0),n.eq(t)},_moveFocus(i){let e=this._getAvailableItems(),t;switch(i){case"pageup":case"up":t=this._prevItem(e);break;case"pagedown":case"down":t=this._nextItem(e);break;case"right":t=this.option("rtlEnabled")?this._prevItem(e):this._nextItem(e);break;case"left":t=this.option("rtlEnabled")?this._nextItem(e):this._prevItem(e);break;case"first":t=e.first();break;case"last":t=e.last();break;default:return!1}t.length!==0&&this.option("focusedElement",N(t))},_getVisibleItems(i){return i=i||this._itemElements(),i.filter(":visible")},_getAvailableItems(i){return this._getVisibleItems(i)},_prevItem(i){let e=this._getActiveItem(),t=i.index(e),n=i.last(),o=u(i[t-1]),s=this.option("loopItemFocus");return o.length===0&&s&&(o=n),o},_nextItem(i){let e=this._getActiveItem(!0),t=i.index(e),n=i.first(),o=u(i[t+1]),s=this.option("loopItemFocus");return o.length===0&&s&&(o=n),o},_selectFocusedItem(i){this.selectItem(i)},_updateFocusedItemState(i,e,t){let n=u(i);n.length&&(this._refreshActiveDescendant(),this._refreshItemId(n,t),this._toggleFocusClass(e,n)),this._updateParentActiveDescendant()},_refreshActiveDescendant(i){this.setAria("activedescendant",f(this.option("focusedElement"))?this.getFocusedItemId():null,i)},_refreshItemId(i,e){!e&&this.option("focusedElement")?this.setAria("id",this.getFocusedItemId(),i):this.setAria("id",null,i)},_isDisabled:i=>i&&u(i).attr("aria-disabled")==="true",_setFocusedItem(i){if(!i||!i.length)return;this._updateFocusedItemState(i,!0),this.onFocusedItemChanged(this.getFocusedItemId());let{selectOnFocus:e}=this.option(),t=this._isDisabled(i);e&&!t&&this._selectFocusedItem(i)},_findItemElementByItem(i){let e=u(),t=this;return this.itemElements().each(function(){let n=u(this);if(n.data(t._itemDataKey())===i)return e=n,!1}),e},_getIndexByItem(i){return this.option("items").indexOf(i)},_itemOptionChanged(i,e,t,n){let o=this._findItemElementByItem(i);if(!o.length)return;this.constructor.ItemClass.getInstance(o).setDataField(e,t)||this._refreshItem(o,i),e==="disabled"&&t&&this._resetItemFocus(o)},_resetItemFocus(i){i.is(this.option("focusedElement"))&&this.option("focusedElement",null)},_refreshItem(i){let e=this._getItemData(i),t=i.data(this._itemIndexKey());this._renderItem(this._renderedItemsCount+t,e,null,i)},_updateParentActiveDescendant:S,_optionChanged(i){if(i.name==="items"){let e=i.fullName.match(tK);if(e&&e.length){let t=e[e.length-1],n=i.fullName.replace(`.${t}`,""),o=this.option(n);this._itemOptionChanged(o,t,i.value,i.previousValue);return}}switch(i.name){case"items":case"_itemAttributes":case"itemTemplateProperty":case"useItemTextAsTitle":this._cleanRenderedItems(),this._invalidate();break;case"dataSource":this._refreshDataSource(),this._renderEmptyMessage();break;case"noDataText":case"encodeNoDataText":this._renderEmptyMessage();break;case"itemTemplate":case"visibleExpr":case"disabledExpr":this._invalidate();break;case"onItemRendered":this._createItemRenderAction();break;case"onItemClick":case"selectOnFocus":case"loopItemFocus":case"focusOnSelectedItem":break;case"onItemHold":case"itemHoldTimeout":this._attachHoldEvent();break;case"onItemContextMenu":this._attachContextMenuEvent();break;case"onFocusedItemChanged":this.onFocusedItemChanged=this._createActionByOption("onFocusedItemChanged");break;case"focusedElement":this._updateFocusedItemState(i.previousValue,!1,!0),this._setFocusedItem(u(i.value));break;case"displayExpr":this._compileDisplayGetter(),this._initDefaultItemTemplate(),this._invalidate();break;default:this.callBase(i)}},_invalidate(){return this.option("focusedElement",null),this.callBase.apply(this,arguments)},_loadNextPage(){return this._expectNextPageLoading(),this._dataController.loadNextPage()},_expectNextPageLoading(){this._startIndexForAppendedItems=0},_expectLastItemLoading(){this._startIndexForAppendedItems=-1},_forgetNextPageLoading(){this._startIndexForAppendedItems=null},_dataSourceChangedHandler(i){let e=this.option("items");this._initialized&&e&&this._shouldAppendItems()?(this._renderedItemsCount=e.length,(!this._isLastPage()||this._startIndexForAppendedItems!==-1)&&(this.option().items=e.concat(i.slice(this._startIndexForAppendedItems))),this._forgetNextPageLoading(),this._refreshContent()):this.option("items",i.slice())},_refreshContent(){this._prepareContent(),this._renderContent()},_dataSourceLoadErrorHandler(){this._forgetNextPageLoading(),this.option("items",this.option("items"))},_shouldAppendItems(){return this._startIndexForAppendedItems!=null&&this._allowDynamicItemsAppend()},_allowDynamicItemsAppend:()=>!1,_clean(){this._cleanFocusState(),this._cleanItemContainer(),this._inkRipple&&delete this._inkRipple,this._resetActiveState()},_cleanItemContainer(){u(this._itemContainer()).empty()},_dispose(){this.callBase(),clearTimeout(this._itemFocusTimeout)},_refresh(){this._cleanRenderedItems(),this.callBase.apply(this,arguments)},_itemContainer(){return this.$element()},_itemClass:()=>np,_itemContentClass(){return this._itemClass()+"-content"},_selectedItemClass:()=>"dx-item-selected",_itemResponseWaitClass:()=>"dx-item-response-wait",_itemSelector(){return`.${this._itemClass()}`},_itemDataKey:()=>"dxItemData",_itemIndexKey:()=>"dxItemIndex",_itemElements(){return this._itemContainer().find(this._itemSelector())},_initMarkup(){this.callBase(),this.onFocusedItemChanged=this._createActionByOption("onFocusedItemChanged"),this.$element().addClass("dx-collection"),this._prepareContent()},_prepareContent:Ao(function(){this._renderContentImpl()}),_renderContent(){this._fireContentReadyAction()},_render(){this.callBase(),this._attachClickEvent(),this._attachHoldEvent(),this._attachContextMenuEvent()},_getPointerEvent:()=>ne.down,_attachClickEvent(){let i=this._itemSelector(),e=this._getPointerEvent(),t=D(oe,this.NAME),n=D(e,this.NAME),o=new po(s=>{let{event:r}=s;this._itemPointerDownHandler(r)});_.off(this._itemContainer(),t,i),_.off(this._itemContainer(),n,i),_.on(this._itemContainer(),t,i,s=>this._itemClickHandler(s)),_.on(this._itemContainer(),n,i,s=>{o.execute({element:u(s.target),event:s})})},_itemClickHandler(i,e,t){this._itemDXEventHandler(i,"onItemClick",e,t)},_itemPointerDownHandler(i){this.option("focusStateEnabled")&&(this._itemFocusHandler=function(){if(clearTimeout(this._itemFocusTimeout),this._itemFocusHandler=null,i.isDefaultPrevented())return;let e=u(i.target),t=e.closest(this._itemElements()),n=this._closestFocusable(e);t.length&&this._isFocusTarget(n?.get(0))&&this.option("focusedElement",N(t))}.bind(this),this._itemFocusTimeout=setTimeout(this._forcePointerDownFocus.bind(this)))},_closestFocusable(i){if(i.is(qd))return i;for(i=i.parent();i.length&&!w.isDocument(i.get(0))&&!w.isDocumentFragment(i.get(0));){if(i.is(qd))return i;i=i.parent()}},_forcePointerDownFocus(){this._itemFocusHandler&&this._itemFocusHandler()},_updateFocusState(){this.callBase.apply(this,arguments),this._forcePointerDownFocus()},_attachHoldEvent(){let i=this._itemContainer(),e=this._itemSelector(),t=D(an.name,this.NAME);_.off(i,t,e),_.on(i,t,e,{timeout:this._getHoldTimeout()},this._itemHoldHandler.bind(this))},_getHoldTimeout(){return this.option("itemHoldTimeout")},_shouldFireHoldEvent(){return this.hasActionSubscription("onItemHold")},_itemHoldHandler(i){this._shouldFireHoldEvent()?this._itemDXEventHandler(i,"onItemHold"):i.cancel=!0},_attachContextMenuEvent(){let i=this._itemContainer(),e=this._itemSelector(),t=D(jh,this.NAME);_.off(i,t,e),_.on(i,t,e,this._itemContextMenuHandler.bind(this))},_shouldFireContextMenuEvent(){return this.hasActionSubscription("onItemContextMenu")},_itemContextMenuHandler(i){this._shouldFireContextMenuEvent()?this._itemDXEventHandler(i,"onItemContextMenu"):i.cancel=!0},_renderContentImpl(){let i=this.option("items")||[];this._renderedItemsCount?this._renderItems(i.slice(this._renderedItemsCount)):this._renderItems(i)},_renderItems(i){i.length&&x(i,(e,t)=>{this._renderItem(this._renderedItemsCount+e,t)}),this._renderEmptyMessage()},_getItemsContainer(){return this._itemContainer()},_setAttributes(i){let e=I({},this.option("_itemAttributes")),{class:t}=e;if(t){let n=i.get(0).className;e.class=[n,t].join(" ")}i.attr(e)},_renderItem(i,e,t,n){let o=i?.item??i;t=t||this._getItemsContainer();let s=this._renderItemFrame(o,e,t,n);this._setElementData(s,e,o),this._setAttributes(s),this._attachItemClickEvent(e,s);let r=this._getItemContent(s),a=this._renderItemContent({index:o,itemData:e,container:N(r),contentClass:this._itemContentClass(),defaultTemplateName:this.option("itemTemplate")}),l=this;return P(a).done(d=>{l._postprocessRenderItem({itemElement:s,itemContent:d,itemData:e,itemIndex:o}),l._executeItemRenderAction(i,e,N(s))}),s},_getItemContent(i){let e=i.find(".dx-item-content-placeholder");return e.removeClass("dx-item-content-placeholder"),e},_attachItemClickEvent(i,e){!i||!i.onClick||_.on(e,oe,t=>{this._itemEventHandlerByHandler(e,i.onClick,{event:t})})},_renderItemContent(i){let e=this._getItemTemplateName(i),t=this._getTemplate(e);this._addItemContentClasses(i);let n=u(this._createItemByTemplate(t,i));return n.hasClass("dx-template-wrapper")?this._renderItemContentByNode(i,n):i.container},_renderItemContentByNode(i,e){return u(i.container).replaceWith(e),i.container=N(e),this._addItemContentClasses(i),e},_addItemContentClasses(i){let e=[np+"-content",i.contentClass];u(i.container).addClass(e.join(" "))},_appendItemToContainer(i,e,t){e.appendTo(i)},_renderItemFrame(i,e,t,n){let o=u("<div>");if(new this.constructor.ItemClass(o,this._itemOptions(),e||{}),n&&n.length?n.replaceWith(o):this._appendItemToContainer.call(this,t,o,i),this.option("useItemTextAsTitle")){let s=this._displayGetter?this._displayGetter(e):e;o.attr("title",s)}return o},_itemOptions(){let i=this;return{watchMethod:()=>i.option("integrationOptions.watchMethod"),owner:i,fieldGetter(e){let t=i.option(`${e}Expr`);return me(t)}}},_postprocessRenderItem:S,_executeItemRenderAction(i,e,t){this._getItemRenderAction()({itemElement:t,itemIndex:i,itemData:e})},_setElementData(i,e,t){i.addClass([np,this._itemClass()].join(" ")).data(this._itemDataKey(),e).data(this._itemIndexKey(),t)},_createItemRenderAction(){return this._itemRenderAction=this._createActionByOption("onItemRendered",{element:this.element(),excludeValidators:["disabled","readOnly"],category:"rendering"})},_getItemRenderAction(){return this._itemRenderAction||this._createItemRenderAction()},_getItemTemplateName(i){let e=i.itemData,t=i.templateProperty||this.option("itemTemplateProperty");return e&&e[t]||i.defaultTemplateName},_createItemByTemplate(i,e){return i.render({model:e.itemData,container:e.container,index:e.index,onRendered:this._onItemTemplateRendered(i,e)})},_onItemTemplateRendered:()=>S,_emptyMessageContainer(){return this._itemContainer()},_renderEmptyMessage(i){i=i||this.option("items");let e=this.option("noDataText"),t=!e||i&&i.length||this._dataController.isLoading();t&&this._$noData&&(this._$noData.remove(),this._$noData=null,this.setAria("label",void 0)),t||(this._$noData=this._$noData||u("<div>").addClass("dx-empty-message"),this._$noData.appendTo(this._emptyMessageContainer()),this.option("encodeNoDataText")?this._$noData.text(e):this._$noData.html(e)),this.$element().toggleClass(eK,!t)},_itemDXEventHandler(i,e,t,n){this._itemEventHandler(i.target,e,m(t,{event:i}),n)},_itemEventHandler(i,e,t,n){let o=this._createActionByOption(e,m({validatingTargetName:"itemElement"},n));return this._itemEventHandlerImpl(i,o,t)},_itemEventHandlerByHandler(i,e,t,n){let o=this._createAction(e,m({validatingTargetName:"itemElement"},n));return this._itemEventHandlerImpl(i,o,t)},_itemEventHandlerImpl(i,e,t){let n=this._closestItemElement(u(i)),o=m({},t);return e(m(t,this._extendActionArgs(n),o))},_extendActionArgs(i){return{itemElement:N(i),itemIndex:this._itemElements().index(i),itemData:this._getItemData(i)}},_closestItemElement(i){return u(i).closest(this._itemSelector())},_getItemData(i){return u(i).data(this._itemDataKey())},_getSummaryItemsSize(i,e,t){let n=0;return e&&x(e,(o,s)=>{i==="width"?n+=ie(s,t||!1):i==="height"&&(n+=X(s,t||!1))}),n},getFocusedItemId(){return this._focusedItemId||(this._focusedItemId=`dx-${new Oe}`),this._focusedItemId},itemElements(){return this._itemElements()},itemsContainer(){return this._itemContainer()}}).include(Uh);fD.ItemClass=jn;var OC=fD;var{abstract:mn}=ce,iK=ce.inherit({ctor(i){this._collectionWidget=i},getIndexByItemData:mn,getItemDataByIndex:mn,getKeysByItems:mn,getItemsByKeys:mn,itemsGetter:mn,getKeyByIndex(i){let e=this._denormalizeItemIndex(i);return this.getKeysByItems([this.getItemDataByIndex(e)])[0]},_equalKeys(i,e){return this._collectionWidget._isKeySpecified()?ve(i,e):i===e},beginCache(){this._cache={}},endCache(){this._cache=null},getIndexByKey:mn,getNormalizedIndex(i){return this._isNormalizedItemIndex(i)?i:this._isItemIndex(i)?this._normalizeItemIndex(i):this._isNode(i)?this._getNormalizedItemIndex(i):this._normalizeItemIndex(this.getIndexByItemData(i))},getIndex(i){return this._isNormalizedItemIndex(i)?this._denormalizeItemIndex(i):this._isItemIndex(i)?i:this._isNode(i)?this._denormalizeItemIndex(this._getNormalizedItemIndex(i)):this.getIndexByItemData(i)},getItemElement(i){if(this._isNormalizedItemIndex(i))return this._getItemByNormalizedIndex(i);if(this._isItemIndex(i))return this._getItemByNormalizedIndex(this._normalizeItemIndex(i));if(this._isNode(i))return u(i);let e=this._normalizeItemIndex(this.getIndexByItemData(i));return this._getItemByNormalizedIndex(e)},_isNode:i=>w.isNode(i&&$t(i)?i.get(0):i),deleteItemAtIndex:mn,itemPlacementFunc(i,e){return this._itemsFromSameParent(i,e)&&i<e?"after":"before"},moveItemAtIndexToIndex:mn,_isNormalizedItemIndex:i=>typeof i=="number"&&Math.round(i)===i,_isItemIndex:mn,_getNormalizedItemIndex:mn,_normalizeItemIndex:mn,_denormalizeItemIndex:mn,_getItemByNormalizedIndex:mn,_itemsFromSameParent:mn}),_D=iK;var nK=_D.inherit({_getPlainItems(){return this._collectionWidget.option("items")||[]},getIndexByItemData(i){let e=this._collectionWidget.keyOf.bind(this._collectionWidget);return e?this.getIndexByKey(e(i)):this._getPlainItems().indexOf(i)},getItemDataByIndex(i){return this._getPlainItems()[i]},deleteItemAtIndex(i){this._getPlainItems().splice(i,1)},itemsGetter(){return this._getPlainItems()},getKeysByItems(i){let e=this._collectionWidget.keyOf.bind(this._collectionWidget),t=i;if(e){t=[];for(let n=0;n<i.length;n++)t.push(e(i[n]))}return t},getIndexByKey(i){let e=this._cache,t=e&&e.keys||this.getKeysByItems(this._getPlainItems());if(e&&!e.keys&&(e.keys=t),typeof i=="object"){for(let n=0,{length:o}=t;n<o;n++)if(this._equalKeys(i,t[n]))return n}else return t.indexOf(i);return-1},getItemsByKeys:(i,e)=>(e||i).slice(),moveItemAtIndexToIndex(i,e){let t=this._getPlainItems(),n=t[i];t.splice(i,1),t.splice(e,0,n)},_isItemIndex:i=>typeof i=="number"&&Math.round(i)===i,_getNormalizedItemIndex(i){return this._collectionWidget._itemElements().index(i)},_normalizeItemIndex:i=>i,_denormalizeItemIndex:i=>i,_getItemByNormalizedIndex(i){return i>-1?this._collectionWidget._itemElements().eq(i):null},_itemsFromSameParent:()=>!0}),pl=nK;var fo=function(i){return i!==-1},oK=OC.inherit({_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{selectedItem:!0})},_getDefaultOptions(){return m(this.callBase(),{selectionMode:"none",selectionRequired:!1,selectByClick:!0,selectedItems:[],selectedItemKeys:[],maxFilterLengthInRequest:1500,keyExpr:null,selectedIndex:-1,selectedItem:null,onSelectionChanged:null,onItemReordered:null,onItemDeleting:null,onItemDeleted:null})},ctor(i,e){this._userOptions=e||{},this.callBase(i,e)},_init(){this._initEditStrategy(),this.callBase(),this._initKeyGetter(),this._initSelectionModule()},_initKeyGetter(){this._keyGetter=me(this.option("keyExpr"))},_getKeysByItems(i){return this._editStrategy.getKeysByItems(i)},_getItemsByKeys(i,e){return this._editStrategy.getItemsByKeys(i,e)},_getKeyByIndex(i){return this._editStrategy.getKeyByIndex(i)},_getIndexByKey(i){return this._editStrategy.getIndexByKey(i)},_getIndexByItemData(i){return this._editStrategy.getIndexByItemData(i)},_isKeySpecified(){return!!this._dataController.key()},_getCombinedFilter(){return this._dataController.filter()},key(){return this.option("keyExpr")?this.option("keyExpr"):this._dataController.key()},keyOf(i){let e=i;return this.option("keyExpr")?e=this._keyGetter(i):this._dataController.store()&&(e=this._dataController.keyOf(i)),e},_nullValueSelectionSupported:()=>!1,_initSelectionModule(){let i=this,{itemsGetter:e}=i._editStrategy;this._selection=new dl({allowNullValue:this._nullValueSelectionSupported(),mode:this.option("selectionMode"),maxFilterLengthInRequest:this.option("maxFilterLengthInRequest"),equalByReference:!this._isKeySpecified(),onSelectionChanged(t){(t.addedItemKeys.length||t.removedItemKeys.length)&&(i.option("selectedItems",i._getItemsByKeys(t.selectedItemKeys,t.selectedItems)),i._updateSelectedItems(t))},filter:i._getCombinedFilter.bind(i),totalCount(){let t=i.option("items"),n=i._dataController.totalCount();return n>=0?n:i._getItemsCount(t)},key:i.key.bind(i),keyOf:i.keyOf.bind(i),load(t){var n;let o=i._dataController;return t.customQueryParams=(n=o.loadOptions())===null||n===void 0?void 0:n.customQueryParams,t.userData=o.userData(),o.store()?o.loadFromStore(t).done(s=>{if(i._disposed)return;let r=Lh(s).data;o.applyMapFunction(r)}):y().resolve(this.plainItems())},dataFields:()=>i._dataController.select(),plainItems:e.bind(i._editStrategy)})},_getItemsCount(i){return i.reduce((e,t)=>e+(t.items?this._getItemsCount(t.items):1),0)},_initEditStrategy(){let i=pl;this._editStrategy=new i(this)},_getSelectedItemIndices(i){let e=this,t=[];return i=i||this._selection.getSelectedItemKeys(),e._editStrategy.beginCache(),x(i,(n,o)=>{let s=e._getIndexByKey(o);fo(s)&&t.push(s)}),e._editStrategy.endCache(),t},_initMarkup(){this._rendering=!0,this._dataController.isLoading()||this._syncSelectionOptions().done(()=>this._normalizeSelectedItems()),this.callBase()},_render(){this.callBase(),this._rendering=!1},_fireContentReadyAction(){this._rendering=!1,this._rendered=!0,this.callBase.apply(this,arguments)},_syncSelectionOptions(i){i=i||this._chooseSelectOption();let e,t,n,o;switch(i){case"selectedIndex":e=this._editStrategy.getItemDataByIndex(this.option("selectedIndex")),f(e)?(this._setOptionWithoutOptionChange("selectedItems",[e]),this._setOptionWithoutOptionChange("selectedItem",e),this._setOptionWithoutOptionChange("selectedItemKeys",this._editStrategy.getKeysByItems([e]))):(this._setOptionWithoutOptionChange("selectedItems",[]),this._setOptionWithoutOptionChange("selectedItemKeys",[]),this._setOptionWithoutOptionChange("selectedItem",null));break;case"selectedItems":if(o=this.option("selectedItems")||[],t=o.length?this._editStrategy.getIndexByItemData(o[0]):-1,this.option("selectionRequired")&&!fo(t))return this._syncSelectionOptions("selectedIndex");this._setOptionWithoutOptionChange("selectedItem",o[0]),this._setOptionWithoutOptionChange("selectedIndex",t),this._setOptionWithoutOptionChange("selectedItemKeys",this._editStrategy.getKeysByItems(o));break;case"selectedItem":if(e=this.option("selectedItem"),t=this._editStrategy.getIndexByItemData(e),this.option("selectionRequired")&&!fo(t))return this._syncSelectionOptions("selectedIndex");f(e)?(this._setOptionWithoutOptionChange("selectedItems",[e]),this._setOptionWithoutOptionChange("selectedIndex",t),this._setOptionWithoutOptionChange("selectedItemKeys",this._editStrategy.getKeysByItems([e]))):(this._setOptionWithoutOptionChange("selectedItems",[]),this._setOptionWithoutOptionChange("selectedItemKeys",[]),this._setOptionWithoutOptionChange("selectedIndex",-1));break;case"selectedItemKeys":if(n=this.option("selectedItemKeys"),this.option("selectionRequired")){let s=this._getIndexByKey(n[0]);if(!fo(s))return this._syncSelectionOptions("selectedIndex")}return this._selection.setSelection(n)}return y().resolve().promise()},_chooseSelectOption(){let i="selectedIndex",e=function(t){let n=this.option(t);return f(n)&&n.length||t in this._userOptions}.bind(this);return e("selectedItems")?i="selectedItems":e("selectedItem")?i="selectedItem":e("selectedItemKeys")&&(i="selectedItemKeys"),i},_compareKeys(i,e){if(i.length!==e.length)return!1;for(let t=0;t<e.length;t++)if(i[t]!==e[t])return!1;return!0},_normalizeSelectedItems(){if(this.option("selectionMode")==="none")this._setOptionWithoutOptionChange("selectedItems",[]),this._syncSelectionOptions("selectedItems");else if(this.option("selectionMode")==="single"){let i=this.option("selectedItems");if(i.length>1||!i.length&&this.option("selectionRequired")&&this.option("items")&&this.option("items").length){let e=this._selection.getSelectedItems(),t=i[0]===void 0?e[0]:i[0];return t===void 0&&(t=this._editStrategy.itemsGetter()[0]),this.option("grouped")&&t&&t.items&&(t.items=[t.items[0]]),this._selection.setSelection(this._getKeysByItems([t])),this._setOptionWithoutOptionChange("selectedItems",[t]),this._syncSelectionOptions("selectedItems")}this._selection.setSelection(this._getKeysByItems(i))}else{let i=this._getKeysByItems(this.option("selectedItems")),e=this._selection.getSelectedItemKeys();this._compareKeys(e,i)||this._selection.setSelection(i)}return y().resolve().promise()},_itemClickHandler(i){let e=y().resolve(),{callBase:t}=this;this._createAction(n=>{e=this._itemSelectHandler(n.event)??e},{validatingTargetName:"itemElement"})({itemElement:u(i.currentTarget),event:i}),e.always(()=>{t.apply(this,arguments)})},_itemSelectHandler(i){var e;let t;if(!this.option("selectByClick"))return;let n=i.currentTarget;return this.isItemSelected(n)?this.unselectItem(i.currentTarget):t=this.selectItem(i.currentTarget),(e=t)===null||e===void 0?void 0:e.promise()},_selectedItemElement(i){return this._itemElements().eq(i)},_postprocessRenderItem(i){if(this.option("selectionMode")!=="none"){let e=u(i.itemElement),t=this._editStrategy.getNormalizedIndex(e),n=this._isItemSelected(t);this._processSelectableItem(e,n)}},_processSelectableItem(i,e){i.toggleClass(this._selectedItemClass(),e),this._setAriaSelectionAttribute(i,String(e))},_updateSelectedItems(i){let e=this,{addedItemKeys:t}=i,{removedItemKeys:n}=i;if(e._rendered&&(t.length||n.length)){let o=e._selectionChangePromise;if(!e._rendering){let s=[],r,a=[];e._editStrategy.beginCache();for(let l=0;l<t.length;l++)r=e._getIndexByKey(t[l]),s.push(r),e._addSelection(r);for(let l=0;l<n.length;l++)r=e._getIndexByKey(n[l]),a.push(r),e._removeSelection(r);e._editStrategy.endCache(),e._updateSelection(s,a)}P(o).done(()=>{e._fireSelectionChangeEvent(i.addedItems,i.removedItems)})}},_fireSelectionChangeEvent(i,e){this._createActionByOption("onSelectionChanged",{excludeValidators:["disabled","readOnly"]})({addedItems:i,removedItems:e})},_updateSelection:S,_setAriaSelectionAttribute(i,e){this.setAria("selected",e,i)},_removeSelection(i){let e=this._editStrategy.getItemElement(i);fo(i)&&(this._processSelectableItem(e,!1),_.triggerHandler(e,"stateChanged",!1))},_addSelection(i){let e=this._editStrategy.getItemElement(i);fo(i)&&(this._processSelectableItem(e,!0),_.triggerHandler(e,"stateChanged",!0))},_isItemSelected(i){let e=this._getKeyByIndex(i);return this._selection.isItemSelected(e,{checkPending:!0})},_optionChanged(i){switch(i.name){case"selectionMode":this._invalidate();break;case"dataSource":(!i.value||Array.isArray(i.value)&&!i.value.length)&&this.option("selectedItemKeys",[]),this.callBase(i);break;case"selectedIndex":case"selectedItem":case"selectedItems":case"selectedItemKeys":this._syncSelectionOptions(i.name).done(()=>this._normalizeSelectedItems());break;case"keyExpr":this._initKeyGetter();break;case"selectionRequired":this._normalizeSelectedItems();break;case"selectByClick":case"onSelectionChanged":case"onItemDeleting":case"onItemDeleted":case"onItemReordered":case"maxFilterLengthInRequest":break;default:this.callBase(i)}},_clearSelectedItems(){this._setOptionWithoutOptionChange("selectedItems",[]),this._syncSelectionOptions("selectedItems")},_waitDeletingPrepare(i){if(i.data("dxItemDeleting"))return y().resolve().promise();i.data("dxItemDeleting",!0);let e=y(),t={cancel:!1},n=this._itemEventHandler(i,"onItemDeleting",t,{excludeValidators:["disabled","readOnly"]});return P(n).always(function(o){let s=!n,r=!s&&n.state()==="resolved",a=!!arguments.length,l=s||r&&!a||r&&o;P(ht(t.cancel)).always(()=>{i.data("dxItemDeleting",!1)}).done(d=>{l&&!d?e.resolve():e.reject()}).fail(e.reject)}),e.promise()},_deleteItemFromDS(i){let e=this._dataController,t=y(),n=this.option("disabled"),o=e.store();if(!o)return y().resolve().promise();if(!o.remove)throw Z.Error("E1011");return this.option("disabled",!0),o.remove(e.keyOf(this._getItemData(i))).done(s=>{s!==void 0?t.resolve():t.reject()}).fail(()=>{t.reject()}),t.always(()=>{this.option("disabled",n)}),t},_tryRefreshLastPage(){let i=y();return this._isLastPage()||this.option("grouped")?i.resolve():this._refreshLastPage().done(()=>{i.resolve()}),i.promise()},_refreshLastPage(){return this._expectLastItemLoading(),this._dataController.load()},_updateSelectionAfterDelete(i){let e=this._getKeyByIndex(i);this._selection.deselect([e])},_updateIndicesAfterIndex(i){let e=this._itemElements();for(let t=i+1;t<e.length;t++)u(e[t]).data(this._itemIndexKey(),t-1)},_simulateOptionChange(i){let e=this.option(i);e instanceof jt||this._optionChangedAction({name:i,fullName:i,value:e})},isItemSelected(i){return this._isItemSelected(this._editStrategy.getNormalizedIndex(i))},selectItem(i){if(this.option("selectionMode")==="none")return;let e=this._editStrategy.getNormalizedIndex(i);if(!fo(e))return;let t=this._getKeyByIndex(e);if(this._selection.isItemSelected(t))return;if(this.option("selectionMode")==="single")return this._selection.setSelection([t]);let n=this.option("selectedItemKeys")||[];return this._selection.setSelection([...n,t],[t])},unselectItem(i){let e=this._editStrategy.getNormalizedIndex(i);if(!fo(e))return;let t=this._selection.getSelectedItemKeys();if(this.option("selectionRequired")&&t.length<=1)return;let n=this._getKeyByIndex(e);this._selection.isItemSelected(n,{checkPending:!0})&&this._selection.deselect([n])},_deleteItemElementByIndex(i){this._updateSelectionAfterDelete(i),this._updateIndicesAfterIndex(i),this._editStrategy.deleteItemAtIndex(i)},_afterItemElementDeleted(i,e){let t=this._dataController.getDataSource()?"dataSource":"items";this._simulateOptionChange(t),this._itemEventHandler(i,"onItemDeleted",e,{beforeExecute(){i.remove()},excludeValidators:["disabled","readOnly"]}),this._renderEmptyMessage()},deleteItem(i){let e=this,t=y(),n=this._editStrategy.getItemElement(i),o=this._editStrategy.getNormalizedIndex(i),s=this._itemResponseWaitClass();return fo(o)?this._waitDeletingPrepare(n).done(()=>{n.addClass(s);let r=e._extendActionArgs(n);e._deleteItemFromDS(n).done(()=>{e._deleteItemElementByIndex(o),e._afterItemElementDeleted(n,r),e._tryRefreshLastPage().done(()=>{t.resolveWith(e)})}).fail(()=>{n.removeClass(s),t.rejectWith(e)})}).fail(()=>{t.rejectWith(e)}):t.rejectWith(e),t.promise()},reorderItem(i,e){let t=y(),n=this,o=this._editStrategy,s=o.getItemElement(i),r=o.getItemElement(e),a=o.getNormalizedIndex(i),l=o.getNormalizedIndex(e),d=this._dataController.getDataSource()?"dataSource":"items";return fo(a)&&fo(l)&&a!==l?t.resolveWith(this):t.rejectWith(this),t.promise().done(function(){r[o.itemPlacementFunc(a,l)](s),o.moveItemAtIndexToIndex(a,l),this._updateIndicesAfterIndex(a),n.option("selectedItems",n._getItemsByKeys(n._selection.getSelectedItemKeys(),n._selection.getSelectedItems())),d==="items"&&n._simulateOptionChange(d),n._itemEventHandler(s,"onItemReordered",{fromIndex:o.getIndex(a),toIndex:o.getIndex(l)},{excludeValidators:["disabled","readOnly"]})})}}),gl=oK;var sK="__dx_key__",CD=gl.inherit({_getDefaultOptions(){return m(this.callBase(),{repaintChangesOnly:!1})},_customizeStoreLoadOptions(i){this._dataController.getDataSource()&&!this._dataController.isLoaded()&&(this._correctionIndex=0),this._correctionIndex&&i.storeLoadOptions&&(i.storeLoadOptions.skip+=this._correctionIndex)},reload(){this._correctionIndex=0},_init(){this.callBase(),this._refreshItemsCache(),this._correctionIndex=0,this._subscribeLoadOptionsCustomization(!0)},_findItemElementByKey(i){let e=u(),t=this.key();return this.itemElements().each((n,o)=>{let s=u(o),r=this._getItemData(s);if(t?fs(t,this.keyOf(r),i):this._isItemEquals(r,i))return e=s,!1}),e},_dataSourceChangedHandler(i,e){e!=null&&e.changes?this._modifyByChanges(e.changes):(this.callBase(i,e),this._refreshItemsCache())},_isItemEquals(i,e){i&&i.__dx_key__&&(i=i.data);try{return JSON.stringify(i)===JSON.stringify(e)}catch{return i===e}},_isItemStrictEquals(i,e){return this._isItemEquals(i,e)},_shouldAddNewGroup(i,e){let t=!1;return this.option("grouped")&&(i.length||(t=!0),x(i,(n,o)=>{o.type==="insert"&&(t=!0,x(e,(s,r)=>{if(o.data.key!==void 0&&o.data.key===r.key)return t=!1,!1}))})),t},_partialRefresh(){if(this.option("repaintChangesOnly")){let i=t=>t&&t.__dx_key__!==void 0?t.__dx_key__:this.keyOf(t),e=Fh(this._itemsCache,this._editStrategy.itemsGetter(),i,this._isItemStrictEquals.bind(this));if(e&&this._itemsCache.length&&!this._shouldAddNewGroup(e,this._itemsCache))return this._modifyByChanges(e,!0),this._renderEmptyMessage(),!0;this._refreshItemsCache()}return!1},_refreshItemsCache(){if(this.option("repaintChangesOnly")){let i=this._editStrategy.itemsGetter();try{this._itemsCache=m(!0,[],i),this.key()||(this._itemsCache=this._itemsCache.map((e,t)=>({[sK]:i[t],data:e})))}catch{this._itemsCache=m([],i)}}},_dispose(){this._subscribeLoadOptionsCustomization(!1),this.callBase()},_updateByChange(i,e,t,n){if(n)this._renderItem(t.index,t.data,null,this._findItemElementByKey(t.key));else{let o=e[_s(i,e,t.key)];o&&sc(i,e,t.key,t.data).done(()=>{this._renderItem(e.indexOf(o),o,null,this._findItemElementByKey(t.key))})}},_insertByChange(i,e,t,n){P(n||rc(i,e,t.data,t.index)).done(()=>{this._beforeItemElementInserted(t),this._renderItem(t.index??e.length,t.data),this._afterItemElementInserted(),this._correctionIndex++})},_updateSelectionAfterRemoveByChange(i){let e=this.option("selectedIndex");e>i?this.option("selectedIndex",e-1):e===i&&this.option("selectedItems").length===1?this.option("selectedItems",[]):this._normalizeSelectedItems()},_beforeItemElementInserted(i){let e=this.option("selectedIndex");i.index<=e&&this.option("selectedIndex",e+1)},_afterItemElementInserted:S,_removeByChange(i,e,t,n){let o=n?t.index:_s(i,e,t.key);if(n?t.oldItem:e[o]){let r=this._findItemElementByKey(t.key),a=this._extendActionArgs(r);this._waitDeletingPrepare(r).done(()=>{n?(this._updateIndicesAfterIndex(o-1),this._afterItemElementDeleted(r,a),this._updateSelectionAfterRemoveByChange(o)):(this._deleteItemElementByIndex(o),this._afterItemElementDeleted(r,a))}),this._correctionIndex--}},_modifyByChanges(i,e){let t=this._editStrategy.itemsGetter(),n={key:this.key.bind(this),keyOf:this.keyOf.bind(this)},o=this._dataController,s=o.paginate(),r=o.group();(s||r)&&(i=i.filter(a=>a.type!=="insert"||a.index!==void 0)),i.forEach(a=>this[`_${a.type}ByChange`](n,t,a,e)),this._renderedItemsCount=t.length,this._refreshItemsCache(),this._fireContentReadyAction()},_appendItemToContainer(i,e,t){let n=i.children(this._itemSelector()).get(t);w.insertElement(i.get(0),e.get(0),n)},_subscribeLoadOptionsCustomization(i){this._dataController&&(i?(this._correctionIndex=0,this._dataController.on("customizeStoreLoadOptions",this._customizeStoreLoadOptions.bind(this))):this._dataController.off("customizeStoreLoadOptions",this._customizeStoreLoadOptions.bind(this)))},_optionChanged(i){switch(i.name){case"items":{this._partialRefresh(i.value)||this.callBase(i);break}case"dataSource":(!this.option("repaintChangesOnly")||!i.value)&&this.option("items",[]),this._subscribeLoadOptionsCustomization(!1),this.callBase(i),this._subscribeLoadOptionsCustomization(!0);break;case"repaintChangesOnly":break;default:this.callBase(i)}}});var mr=CD;var na=ue();var SD=K(),rK=zt.add,aK=Sn,lK=qr,hc=new y,ED="link[rel=dx-theme]",dK="data-theme",cK="data-active",xD="dx-hairlines",wD="any",vs,EC,bs,wn,fr,vD=15e3,SC="dx.";function wC(){if(!W())return null;let i=u("<div>",vs).addClass("dx-theme-marker").appendTo(vs.documentElement),e;try{return e=SD.getComputedStyle(i.get(0)).fontFamily,!e||(e=e.replace(/["']/g,""),e.substr(0,SC.length)!==SC)?null:e.substr(SC.length)}finally{i.remove()}}function bD(i){let e,t,n=!0;fr=i;function o(){fr=null,clearInterval(t),n=!0,na.fire(),na.empty(),hc.resolve()}if(yD()||!vD)o();else{if(!n){fr&&(fr=i);return}e=Date.now(),n=!1,t=setInterval(function(){let s=yD(),r=!s&&Date.now()-e>vD;r&&Z.log("W0004",fr),(s||r)&&o()},10)}}function yD(){if(!fr)return!0;let i=fr===wD;if(hc.state()==="resolved"&&i)return!0;let e=wC();return e&&i?!0:e===fr}function uK(){let i=u(ED,vs);i.length&&(bs={},EC=u(Gd("<link rel=stylesheet>"),vs),i.each(function(){let e=u(this,vs),t=e.attr(dK),n=e.attr("href"),o=e.attr(cK)==="true";bs[t]={url:n,isActive:o}}),i.last().after(EC),i.remove())}function hK(i){let e=i?i.split("."):[],t=null;if(bs){if(i in bs)return i;x(bs,function(n,o){let s=n.split(".");if(!(e[0]&&s[0]!==e[0])&&!(e[1]&&e[1]!==s[1])&&!(e[2]&&e[2]!==s[2])&&((!t||o.isActive)&&(t=n),o.isActive))return!1})}return t}function pK(i){try{i!==vs&&(bs=null)}catch{bs=null}vs=i}function ID(i){i=i||{},pK(i.context||w.getDocument()),vs&&(uK(),wn=void 0,ct(i))}function ct(i){if(!arguments.length)return wn=wn||wC(),wn;TD(aK()),i=i||{},typeof i=="string"&&(i={theme:i});let e=i._autoInit,t=i.loadCallback,n;if(wn=hK(i.theme||wn),wn&&(n=bs[wn]),t&&na.add(t),n)EC.attr("href",bs[wn].url),(na.has()||hc.state()!=="resolved"||i._forceTimeout)&&bD(wn);else if(e)W()&&bD(wD),na.fire(),na.empty();else throw Z.Error("E0021",wn);hc.done(()=>DD(xh(),wn))}function gK(i){i=i||ct();let e=[],t=i&&i.split(".");return t&&(e.push("dx-theme-"+t[0],"dx-theme-"+t[0]+"-typography"),t.length>1&&e.push("dx-color-scheme-"+t[1]+(pt(i)?"-"+t[2]:""))),e}var op;function DD(i,e){op=gK(e).join(" "),u(i).addClass(op),function(){let t=W()&&SD.devicePixelRatio;if(!t||t<2)return;let n=u("<div>");n.css("border",".5px solid transparent"),u("body").append(n),X(n)===1&&(u(i).addClass(xD),op+=" "+xD),n.remove()}()}function TD(i){u(i).removeClass(op)}function IC(i,e){return e||(e=wn||wC()),new RegExp(i).test(e)}function pt(i){return it(i)||ut(i)}function it(i){return IC("material",i)}function ut(i){return IC("fluent",i)}function sp(i){return IC("generic",i)}function mK(i,e){let t=w.getDocument(),n=t.createElement("span");n.style.position="absolute",n.style.top="-9999px",n.style.left="-9999px",n.style.visibility="hidden",n.style.fontFamily="Arial",n.style.fontSize="250px",n.style.fontWeight=e,n.innerHTML=i,t.body.appendChild(n);let o=n.offsetWidth;n.style.fontFamily="Roboto, RobotoFallback, Arial";let s=n.offsetWidth;return n.parentNode.removeChild(n),o!==s}function AD(i,e){return new Promise(t=>{let n=()=>{clearInterval(o),clearTimeout(s),t()},o=setInterval(()=>{mK(i,e)&&n()},15),s=setTimeout(n,2e3)})}function OD(){if(ID({_autoInit:!0,_forceTimeout:!0}),u(ED,vs).length)throw Z.Error("E0022")}W()?OD():rK(OD);lK.add(function(i,e){hc.done(function(){TD(e),DD(i)})});F.changed.add(function(){ID({_autoInit:!0})});var MD=mr.inherit({_activeStateUnit:".dx-accordion-item",_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,height:void 0,itemTitleTemplate:"title",onItemTitleClick:null,selectedIndex:0,collapsible:!1,multiple:!1,animationDuration:300,deferRendering:!0,selectByClick:!0,activeStateEnabled:!0,_itemAttributes:{role:"tab"},_animationEasing:"ease"})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>pt(),options:{animationDuration:200,_animationEasing:"cubic-bezier(0.4, 0, 0.2, 1)"}}])},_itemElements(){return this._itemContainer().children(this._itemSelector())},_init(){this.callBase(),this.option("selectionRequired",!this.option("collapsible")),this.option("selectionMode",this.option("multiple")?"multiple":"single");let i=this.$element();i.addClass("dx-accordion"),this._$container=u("<div>").addClass("dx-accordion-wrapper"),i.append(this._$container)},_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({title:new di((i,e)=>{if(q(e)){let t=ci(e.icon);t&&i.append(t),f(e.title)&&!q(e.title)&&i.append(w.createTextNode(e.title))}else f(e)&&i.text(String(e));i.wrapInner(u("<div>").addClass("dx-accordion-item-title-caption"))},["title","icon"],this.option("integrationOptions.watchMethod"))})},_initMarkup(){this._deferredItems=[],this._deferredTemplateItems=[],this.callBase(),this.setAria({role:"tablist",multiselectable:this.option("multiple")}),nt(()=>{let i=this._getSelectedItemIndices();this._renderSelection(i,[])})},_render(){this.callBase(),P.apply(this,this._deferredTemplateItems).done(()=>{this._updateItemHeights(!0)})},_itemDataKey:()=>"dxAccordionItemData",_itemClass:()=>"dx-accordion-item",_itemContainer(){return this._$container},_itemTitles(){return this._itemElements().find(".dx-accordion-item-title")},_itemContents(){return this._itemElements().find(".dx-accordion-item-body")},_getItemData(i){return u(i).parent().data(this._itemDataKey())||this.callBase.apply(this,arguments)},_executeItemRenderAction(i){i.type||this.callBase.apply(this,arguments)},_itemSelectHandler(i){u(i.target).closest(this._itemContents()).length||this.callBase.apply(this,arguments)},_afterItemElementDeleted(i,e){this._deferredItems.splice(e.itemIndex,1),this.callBase.apply(this,arguments)},_renderItemContent(i){this._deferredTemplateItems[i.index]=y();let e=this.callBase(m({},i,{contentClass:"dx-accordion-item-title",templateProperty:"titleTemplate",defaultTemplateName:this.option("itemTitleTemplate")}));this._attachItemTitleClickAction(e);let t=y();f(this._deferredItems[i.index])?this._deferredItems[i.index]=t:this._deferredItems.push(t),(!this.option("deferRendering")||this._getSelectedItemIndices().indexOf(i.index)>=0)&&t.resolve(),t.done(this.callBase.bind(this,m({},i,{contentClass:"dx-accordion-item-body",container:N(u("<div>").appendTo(u(e).parent()))})))},_onItemTemplateRendered(i,e){return()=>{let t=this._deferredTemplateItems[e.index];t&&t.resolve()}},_attachItemTitleClickAction(i){let e=D(oe,this.NAME);_.off(i,e),_.on(i,e,this._itemTitleClickHandler.bind(this))},_itemTitleClickHandler(i){this._itemDXEventHandler(i,"onItemTitleClick")},_renderSelection(i,e){this._itemElements().addClass("dx-accordion-item-closed"),this.setAria("hidden",!0,this._itemContents()),this._updateItems(i,e)},_updateSelection(i,e){this._updateItems(i,e),this._updateItemHeightsWrapper(!1)},_updateItems(i,e){let t=this._itemElements();x(i,(n,o)=>{var s;(s=this._deferredItems[o])===null||s===void 0||s.resolve();let r=t.eq(o).addClass("dx-accordion-item-opened").removeClass("dx-accordion-item-closed");this.setAria("hidden",!1,r.find(".dx-accordion-item-body"))}),x(e,(n,o)=>{let s=t.eq(o).removeClass("dx-accordion-item-opened");this.setAria("hidden",!0,s.find(".dx-accordion-item-body"))})},_updateItemHeightsWrapper(i){this.option("templatesRenderAsynchronously")?this._animationTimer=setTimeout(()=>{this._updateItemHeights(i)}):this._updateItemHeights(i)},_updateItemHeights(i){let e=this,t=e._deferredAnimate,n=this._splitFreeSpace(this._calculateFreeSpace());return clearTimeout(this._animationTimer),P.apply(u,[].slice.call(this._itemElements()).map(o=>e._updateItemHeight(u(o),n,i))).done(()=>{t&&t.resolveWith(e)})},_updateItemHeight(i,e,t){let n=i.children(".dx-accordion-item-title");pe.isAnimating(i)&&pe.stop(i);let o=X(i),s;return i.hasClass("dx-accordion-item-opened")?(s=e+X(n),s||(xi(i,"auto"),s=X(i))):s=X(n),this._animateItem(i,o,s,t,!!e)},_animateItem(i,e,t,n,o){let s;return n||e===t?(i.css("height",t),s=y().resolve()):s=pe.animate(i,{type:"custom",from:{height:e},to:{height:t},duration:this.option("animationDuration"),easing:this.option("_animationEasing")}),s.done(()=>{i.hasClass("dx-accordion-item-opened")&&!o&&i.css("height",""),i.not(".dx-accordion-item-opened").addClass("dx-accordion-item-closed")})},_splitFreeSpace(i){return i&&i/this.option("selectedItems").length},_calculateFreeSpace(){let i=this.option("height");if(i===void 0||i==="auto")return;let e=this._itemTitles(),t=0;return x(e,(n,o)=>{t+=X(o)}),Y(this.$element())-t},_visibilityChanged(i){i&&this._dimensionChanged()},_dimensionChanged(){this._updateItemHeights(!0)},_clean(){this._deferredTemplateItems.forEach(i=>{i.reject()}),this._deferredTemplateItems=[],clearTimeout(this._animationTimer),this.callBase()},_tryParseItemPropertyName(i){let e=i.match(/.*\.(.*)/);if(f(e)&&e.length>=1)return e[1]},_optionChanged(i){switch(i.name){case"items":this.callBase(i),this._tryParseItemPropertyName(i.fullName)==="title"&&this._renderSelection(this._getSelectedItemIndices(),[]),this._tryParseItemPropertyName(i.fullName)==="visible"&&this._updateItemHeightsWrapper(!0),this.option("repaintChangesOnly")===!0&&i.fullName==="items"&&(this._updateItemHeightsWrapper(!0),this._renderSelection(this._getSelectedItemIndices(),[]));break;case"animationDuration":case"onItemTitleClick":case"_animationEasing":break;case"collapsible":this.option("selectionRequired",!this.option("collapsible"));break;case"itemTitleTemplate":case"height":case"deferRendering":this._invalidate();break;case"multiple":this.option("selectionMode",i.value?"multiple":"single");break;default:this.callBase(i)}},expandItem(i){return this._deferredAnimate=y(),this.selectItem(i),this._deferredAnimate.promise()},collapseItem(i){return this._deferredAnimate=y(),this.unselectItem(i),this._deferredAnimate.promise()},updateDimensions(){return this._updateItemHeights(!1)}});G("dxAccordion",MD);var RD=MD;var FD=RD;var DC=["*"];var Tt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var At=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Mt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var fK=(()=>{class i extends hn{get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get html(){return this._getOption("html")}set html(t){this._setOption("html",t)}get icon(){return this._getOption("icon")}set icon(t){this._setOption("icon",t)}get template(){return this._getOption("template")}set template(t){this._setOption("template",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get title(){return this._getOption("title")}set title(t){this._setOption("title",t)}get titleTemplate(){return this._getOption("titleTemplate")}set titleTemplate(t){this._setOption("titleTemplate",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get onClick(){return this._getOption("onClick")}set onClick(t){this._setOption("onClick",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get type(){return this._getOption("type")}set type(t){this._setOption("type",t)}get baseSize(){return this._getOption("baseSize")}set baseSize(t){this._setOption("baseSize",t)}get box(){return this._getOption("box")}set box(t){this._setOption("box",t)}get ratio(){return this._getOption("ratio")}set ratio(t){this._setOption("ratio",t)}get shrink(){return this._getOption("shrink")}set shrink(t){this._setOption("shrink",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get beginGroup(){return this._getOption("beginGroup")}set beginGroup(t){this._setOption("beginGroup",t)}get closeMenuOnClick(){return this._getOption("closeMenuOnClick")}set closeMenuOnClick(t){this._setOption("closeMenuOnClick",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get selectable(){return this._getOption("selectable")}set selectable(t){this._setOption("selectable",t)}get selected(){return this._getOption("selected")}set selected(t){this._setOption("selected",t)}get colSpan(){return this._getOption("colSpan")}set colSpan(t){this._setOption("colSpan",t)}get cssClass(){return this._getOption("cssClass")}set cssClass(t){this._setOption("cssClass",t)}get dataField(){return this._getOption("dataField")}set dataField(t){this._setOption("dataField",t)}get editorOptions(){return this._getOption("editorOptions")}set editorOptions(t){this._setOption("editorOptions",t)}get editorType(){return this._getOption("editorType")}set editorType(t){this._setOption("editorType",t)}get helpText(){return this._getOption("helpText")}set helpText(t){this._setOption("helpText",t)}get isRequired(){return this._getOption("isRequired")}set isRequired(t){this._setOption("isRequired",t)}get itemType(){return this._getOption("itemType")}set itemType(t){this._setOption("itemType",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get validationRules(){return this._getOption("validationRules")}set validationRules(t){this._setOption("validationRules",t)}get visibleIndex(){return this._getOption("visibleIndex")}set visibleIndex(t){this._setOption("visibleIndex",t)}get alignItemLabels(){return this._getOption("alignItemLabels")}set alignItemLabels(t){this._setOption("alignItemLabels",t)}get caption(){return this._getOption("caption")}set caption(t){this._setOption("caption",t)}get captionTemplate(){return this._getOption("captionTemplate")}set captionTemplate(t){this._setOption("captionTemplate",t)}get colCount(){return this._getOption("colCount")}set colCount(t){this._setOption("colCount",t)}get colCountByScreen(){return this._getOption("colCountByScreen")}set colCountByScreen(t){this._setOption("colCountByScreen",t)}get tabPanelOptions(){return this._getOption("tabPanelOptions")}set tabPanelOptions(t){this._setOption("tabPanelOptions",t)}get tabs(){return this._getOption("tabs")}set tabs(t){this._setOption("tabs",t)}get badge(){return this._getOption("badge")}set badge(t){this._setOption("badge",t)}get tabTemplate(){return this._getOption("tabTemplate")}set tabTemplate(t){this._setOption("tabTemplate",t)}get buttonOptions(){return this._getOption("buttonOptions")}set buttonOptions(t){this._setOption("buttonOptions",t)}get horizontalAlignment(){return this._getOption("horizontalAlignment")}set horizontalAlignment(t){this._setOption("horizontalAlignment",t)}get verticalAlignment(){return this._getOption("verticalAlignment")}set verticalAlignment(t){this._setOption("verticalAlignment",t)}get locateInMenu(){return this._getOption("locateInMenu")}set locateInMenu(t){this._setOption("locateInMenu",t)}get location(){return this._getOption("location")}set location(t){this._setOption("location",t)}get menuItemTemplate(){return this._getOption("menuItemTemplate")}set menuItemTemplate(t){this._setOption("menuItemTemplate",t)}get options(){return this._getOption("options")}set options(t){this._setOption("options",t)}get showText(){return this._getOption("showText")}set showText(t){this._setOption("showText",t)}get widget(){return this._getOption("widget")}set widget(t){this._setOption("widget",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get imageAlt(){return this._getOption("imageAlt")}set imageAlt(t){this._setOption("imageAlt",t)}get imageSrc(){return this._getOption("imageSrc")}set imageSrc(t){this._setOption("imageSrc",t)}get acceptedValues(){return this._getOption("acceptedValues")}set acceptedValues(t){this._setOption("acceptedValues",t)}get formatName(){return this._getOption("formatName")}set formatName(t){this._setOption("formatName",t)}get formatValues(){return this._getOption("formatValues")}set formatValues(t){this._setOption("formatValues",t)}get key(){return this._getOption("key")}set key(t){this._setOption("key",t)}get showChevron(){return this._getOption("showChevron")}set showChevron(t){this._setOption("showChevron",t)}get linkAttr(){return this._getOption("linkAttr")}set linkAttr(t){this._setOption("linkAttr",t)}get url(){return this._getOption("url")}set url(t){this._setOption("url",t)}get collapsed(){return this._getOption("collapsed")}set collapsed(t){this._setOption("collapsed",t)}get collapsedSize(){return this._getOption("collapsedSize")}set collapsedSize(t){this._setOption("collapsedSize",t)}get collapsible(){return this._getOption("collapsible")}set collapsible(t){this._setOption("collapsible",t)}get maxSize(){return this._getOption("maxSize")}set maxSize(t){this._setOption("maxSize",t)}get minSize(){return this._getOption("minSize")}set minSize(t){this._setOption("minSize",t)}get resizable(){return this._getOption("resizable")}set resizable(t){this._setOption("resizable",t)}get size(){return this._getOption("size")}set size(t){this._setOption("size",t)}get splitter(){return this._getOption("splitter")}set splitter(t){this._setOption("splitter",t)}get heightRatio(){return this._getOption("heightRatio")}set heightRatio(t){this._setOption("heightRatio",t)}get widthRatio(){return this._getOption("widthRatio")}set widthRatio(t){this._setOption("widthRatio",t)}get expanded(){return this._getOption("expanded")}set expanded(t){this._setOption("expanded",t)}get hasItems(){return this._getOption("hasItems")}set hasItems(t){this._setOption("hasItems",t)}get id(){return this._getOption("id")}set id(t){this._setOption("id",t)}get parentId(){return this._getOption("parentId")}set parentId(t){this._setOption("parentId",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var PD=(()=>{class i extends hn{get message(){return this._getOption("message")}set message(t){this._setOption("message",t)}get trim(){return this._getOption("trim")}set trim(t){this._setOption("trim",t)}get type(){return this._getOption("type")}set type(t){this._setOption("type",t)}get ignoreEmptyValue(){return this._getOption("ignoreEmptyValue")}set ignoreEmptyValue(t){this._setOption("ignoreEmptyValue",t)}get max(){return this._getOption("max")}set max(t){this._setOption("max",t)}get min(){return this._getOption("min")}set min(t){this._setOption("min",t)}get reevaluate(){return this._getOption("reevaluate")}set reevaluate(t){this._setOption("reevaluate",t)}get validationCallback(){return this._getOption("validationCallback")}set validationCallback(t){this._setOption("validationCallback",t)}get comparisonTarget(){return this._getOption("comparisonTarget")}set comparisonTarget(t){this._setOption("comparisonTarget",t)}get comparisonType(){return this._getOption("comparisonType")}set comparisonType(t){this._setOption("comparisonType",t)}get pattern(){return this._getOption("pattern")}set pattern(t){this._setOption("pattern",t)}get _optionPath(){return"validationRules"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-validation-rule"]],inputs:{message:"message",trim:"trim",type:"type",ignoreEmptyValue:"ignoreEmptyValue",max:"max",min:"min",reevaluate:"reevaluate",validationCallback:"validationCallback",comparisonTarget:"comparisonTarget",comparisonType:"comparisonType",pattern:"pattern"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),TC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var _K=(()=>{class i extends hn{get alignItemLabels(){return this._getOption("alignItemLabels")}set alignItemLabels(t){this._setOption("alignItemLabels",t)}get badge(){return this._getOption("badge")}set badge(t){this._setOption("badge",t)}get colCount(){return this._getOption("colCount")}set colCount(t){this._setOption("colCount",t)}get colCountByScreen(){return this._getOption("colCountByScreen")}set colCountByScreen(t){this._setOption("colCountByScreen",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get icon(){return this._getOption("icon")}set icon(t){this._setOption("icon",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get tabTemplate(){return this._getOption("tabTemplate")}set tabTemplate(t){this._setOption("tabTemplate",t)}get template(){return this._getOption("template")}set template(t){this._setOption("template",t)}get title(){return this._getOption("title")}set title(t){this._setOption("title",t)}get commands(){return this._getOption("commands")}set commands(t){this._setOption("commands",t)}get groups(){return this._getOption("groups")}set groups(t){this._setOption("groups",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var CK=(()=>{class i extends hn{get icon(){return this._getOption("icon")}set icon(t){this._setOption("icon",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get location(){return this._getOption("location")}set location(t){this._setOption("location",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var kD=(()=>{class i extends CK{get _optionPath(){return"commands"}get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-command"]],contentQueries:function(n,o,s){if(n&1&&ke(s,qn,4),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r)}},inputs:{icon:"icon",items:"items",location:"location",name:"name",text:"text"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var xK=(()=>{class i extends hn{get commands(){return this._getOption("commands")}set commands(t){this._setOption("commands",t)}get title(){return this._getOption("title")}set title(t){this._setOption("title",t)}get category(){return this._getOption("category")}set category(t){this._setOption("category",t)}get displayMode(){return this._getOption("displayMode")}set displayMode(t){this._setOption("displayMode",t)}get expanded(){return this._getOption("expanded")}set expanded(t){this._setOption("expanded",t)}get shapes(){return this._getOption("shapes")}set shapes(t){this._setOption("shapes",t)}get _optionPath(){return"groups"}get commandsChildren(){return this._getOption("commands")}set commandsChildren(t){this.setChildren("commands",t)}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-group"]],contentQueries:function(n,o,s){if(n&1&&ke(s,kD,4),n&2){let r;Be(r=Ve())&&(o.commandsChildren=r)}},inputs:{commands:"commands",title:"title",category:"category",displayMode:"displayMode",expanded:"expanded",shapes:"shapes"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var vK=(()=>{class i extends _K{renderer;document;element;get _optionPath(){return"tabs"}get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}get commandsChildren(){return this._getOption("commands")}set commandsChildren(t){this.setChildren("commands",t)}get groupsChildren(){return this._getOption("groups")}set groupsChildren(t){this.setChildren("groups",t)}constructor(t,n,o,s,r,a){super(),this.renderer=o,this.document=s,this.element=a,t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this)),r.setHost(this)}setTemplate(t){this.template=t}ngAfterViewInit(){mh(this,this.element,this.renderer,this.document)}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1),E(ds),E(Va),E(ee,1),E(Pe))};static \u0275cmp=te({type:i,selectors:[["dxi-tab"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,qn,4),ke(s,kD,4),ke(s,xK,4)),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r),Be(r=Ve())&&(o.commandsChildren=r),Be(r=Ve())&&(o.groupsChildren=r)}},inputs:{alignItemLabels:"alignItemLabels",badge:"badge",colCount:"colCount",colCountByScreen:"colCountByScreen",disabled:"disabled",icon:"icon",items:"items",tabTemplate:"tabTemplate",template:"template",title:"title",commands:"commands",groups:"groups",name:"name"},standalone:!1,features:[le([k,ee]),J],ngContentSelectors:DC,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},styles:["[_nghost-%COMP%]{display:block}"]})}return i})(),AC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var bK=(()=>{class i extends hn{get lat(){return this._getOption("lat")}set lat(t){this._setOption("lat",t)}get lng(){return this._getOption("lng")}set lng(t){this._setOption("lng",t)}get col(){return this._getOption("col")}set col(t){this._setOption("col",t)}get colspan(){return this._getOption("colspan")}set colspan(t){this._setOption("colspan",t)}get row(){return this._getOption("row")}set row(t){this._setOption("row",t)}get rowspan(){return this._getOption("rowspan")}set rowspan(t){this._setOption("rowspan",t)}get screen(){return this._getOption("screen")}set screen(t){this._setOption("screen",t)}get _optionPath(){return"location"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-location"]],inputs:{lat:"lat",lng:"lng",col:"col",colspan:"colspan",row:"row",rowspan:"rowspan",screen:"screen"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var qn=(()=>{class i extends fK{renderer;document;element;get _optionPath(){return"items"}get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}get validationRulesChildren(){return this._getOption("validationRules")}set validationRulesChildren(t){this.setChildren("validationRules",t)}get tabsChildren(){return this._getOption("tabs")}set tabsChildren(t){this.setChildren("tabs",t)}get locationChildren(){return this._getOption("location")}set locationChildren(t){this.setChildren("location",t)}constructor(t,n,o,s,r,a){super(),this.renderer=o,this.document=s,this.element=a,t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this)),r.setHost(this)}setTemplate(t){this.template=t}ngAfterViewInit(){mh(this,this.element,this.renderer,this.document)}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1),E(ds),E(Va),E(ee,1),E(Pe))};static \u0275cmp=te({type:i,selectors:[["dxi-item"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,i,4),ke(s,PD,4),ke(s,vK,4),ke(s,bK,4)),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r),Be(r=Ve())&&(o.validationRulesChildren=r),Be(r=Ve())&&(o.tabsChildren=r),Be(r=Ve())&&(o.locationChildren=r)}},inputs:{disabled:"disabled",html:"html",icon:"icon",template:"template",text:"text",title:"title",titleTemplate:"titleTemplate",visible:"visible",onClick:"onClick",stylingMode:"stylingMode",type:"type",baseSize:"baseSize",box:"box",ratio:"ratio",shrink:"shrink",elementAttr:"elementAttr",hint:"hint",beginGroup:"beginGroup",closeMenuOnClick:"closeMenuOnClick",items:"items",selectable:"selectable",selected:"selected",colSpan:"colSpan",cssClass:"cssClass",dataField:"dataField",editorOptions:"editorOptions",editorType:"editorType",helpText:"helpText",isRequired:"isRequired",itemType:"itemType",label:"label",name:"name",validationRules:"validationRules",visibleIndex:"visibleIndex",alignItemLabels:"alignItemLabels",caption:"caption",captionTemplate:"captionTemplate",colCount:"colCount",colCountByScreen:"colCountByScreen",tabPanelOptions:"tabPanelOptions",tabs:"tabs",badge:"badge",tabTemplate:"tabTemplate",buttonOptions:"buttonOptions",horizontalAlignment:"horizontalAlignment",verticalAlignment:"verticalAlignment",locateInMenu:"locateInMenu",location:"location",menuItemTemplate:"menuItemTemplate",options:"options",showText:"showText",widget:"widget",height:"height",width:"width",imageAlt:"imageAlt",imageSrc:"imageSrc",acceptedValues:"acceptedValues",formatName:"formatName",formatValues:"formatValues",key:"key",showChevron:"showChevron",linkAttr:"linkAttr",url:"url",collapsed:"collapsed",collapsedSize:"collapsedSize",collapsible:"collapsible",maxSize:"maxSize",minSize:"minSize",resizable:"resizable",size:"size",splitter:"splitter",heightRatio:"heightRatio",widthRatio:"widthRatio",expanded:"expanded",hasItems:"hasItems",id:"id",parentId:"parentId"},standalone:!1,features:[le([k,ee]),J],ngContentSelectors:DC,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},styles:["[_nghost-%COMP%]{display:block}"]})}return i})(),Ti=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var yK=(()=>{class i extends hn{get location(){return this._getOption("location")}set location(t){this._setOption("location",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get options(){return this._getOption("options")}set options(t){this._setOption("options",t)}get cssClass(){return this._getOption("cssClass")}set cssClass(t){this._setOption("cssClass",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get icon(){return this._getOption("icon")}set icon(t){this._setOption("icon",t)}get onClick(){return this._getOption("onClick")}set onClick(t){this._setOption("onClick",t)}get template(){return this._getOption("template")}set template(t){this._setOption("template",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var _o=(()=>{class i extends yK{get _optionPath(){return"buttons"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-button"]],inputs:{location:"location",name:"name",options:"options",cssClass:"cssClass",disabled:"disabled",hint:"hint",icon:"icon",onClick:"onClick",template:"template",text:"text",visible:"visible"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),ei=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var MC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var ml=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var RC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var FC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Rt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var PC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var OK=(()=>{class i extends hn{get alignment(){return this._getOption("alignment")}set alignment(t){this._setOption("alignment",t)}get allowEditing(){return this._getOption("allowEditing")}set allowEditing(t){this._setOption("allowEditing",t)}get allowExporting(){return this._getOption("allowExporting")}set allowExporting(t){this._setOption("allowExporting",t)}get allowFiltering(){return this._getOption("allowFiltering")}set allowFiltering(t){this._setOption("allowFiltering",t)}get allowFixing(){return this._getOption("allowFixing")}set allowFixing(t){this._setOption("allowFixing",t)}get allowGrouping(){return this._getOption("allowGrouping")}set allowGrouping(t){this._setOption("allowGrouping",t)}get allowHeaderFiltering(){return this._getOption("allowHeaderFiltering")}set allowHeaderFiltering(t){this._setOption("allowHeaderFiltering",t)}get allowHiding(){return this._getOption("allowHiding")}set allowHiding(t){this._setOption("allowHiding",t)}get allowReordering(){return this._getOption("allowReordering")}set allowReordering(t){this._setOption("allowReordering",t)}get allowResizing(){return this._getOption("allowResizing")}set allowResizing(t){this._setOption("allowResizing",t)}get allowSearch(){return this._getOption("allowSearch")}set allowSearch(t){this._setOption("allowSearch",t)}get allowSorting(){return this._getOption("allowSorting")}set allowSorting(t){this._setOption("allowSorting",t)}get autoExpandGroup(){return this._getOption("autoExpandGroup")}set autoExpandGroup(t){this._setOption("autoExpandGroup",t)}get buttons(){return this._getOption("buttons")}set buttons(t){this._setOption("buttons",t)}get calculateCellValue(){return this._getOption("calculateCellValue")}set calculateCellValue(t){this._setOption("calculateCellValue",t)}get calculateDisplayValue(){return this._getOption("calculateDisplayValue")}set calculateDisplayValue(t){this._setOption("calculateDisplayValue",t)}get calculateFilterExpression(){return this._getOption("calculateFilterExpression")}set calculateFilterExpression(t){this._setOption("calculateFilterExpression",t)}get calculateGroupValue(){return this._getOption("calculateGroupValue")}set calculateGroupValue(t){this._setOption("calculateGroupValue",t)}get calculateSortValue(){return this._getOption("calculateSortValue")}set calculateSortValue(t){this._setOption("calculateSortValue",t)}get caption(){return this._getOption("caption")}set caption(t){this._setOption("caption",t)}get cellTemplate(){return this._getOption("cellTemplate")}set cellTemplate(t){this._setOption("cellTemplate",t)}get columns(){return this._getOption("columns")}set columns(t){this._setOption("columns",t)}get cssClass(){return this._getOption("cssClass")}set cssClass(t){this._setOption("cssClass",t)}get customizeText(){return this._getOption("customizeText")}set customizeText(t){this._setOption("customizeText",t)}get dataField(){return this._getOption("dataField")}set dataField(t){this._setOption("dataField",t)}get dataType(){return this._getOption("dataType")}set dataType(t){this._setOption("dataType",t)}get editCellTemplate(){return this._getOption("editCellTemplate")}set editCellTemplate(t){this._setOption("editCellTemplate",t)}get editorOptions(){return this._getOption("editorOptions")}set editorOptions(t){this._setOption("editorOptions",t)}get encodeHtml(){return this._getOption("encodeHtml")}set encodeHtml(t){this._setOption("encodeHtml",t)}get falseText(){return this._getOption("falseText")}set falseText(t){this._setOption("falseText",t)}get filterOperations(){return this._getOption("filterOperations")}set filterOperations(t){this._setOption("filterOperations",t)}get filterType(){return this._getOption("filterType")}set filterType(t){this._setOption("filterType",t)}get filterValue(){return this._getOption("filterValue")}set filterValue(t){this._setOption("filterValue",t)}get filterValues(){return this._getOption("filterValues")}set filterValues(t){this._setOption("filterValues",t)}get fixed(){return this._getOption("fixed")}set fixed(t){this._setOption("fixed",t)}get fixedPosition(){return this._getOption("fixedPosition")}set fixedPosition(t){this._setOption("fixedPosition",t)}get format(){return this._getOption("format")}set format(t){this._setOption("format",t)}get formItem(){return this._getOption("formItem")}set formItem(t){this._setOption("formItem",t)}get groupCellTemplate(){return this._getOption("groupCellTemplate")}set groupCellTemplate(t){this._setOption("groupCellTemplate",t)}get groupIndex(){return this._getOption("groupIndex")}set groupIndex(t){this._setOption("groupIndex",t)}get headerCellTemplate(){return this._getOption("headerCellTemplate")}set headerCellTemplate(t){this._setOption("headerCellTemplate",t)}get headerFilter(){return this._getOption("headerFilter")}set headerFilter(t){this._setOption("headerFilter",t)}get hidingPriority(){return this._getOption("hidingPriority")}set hidingPriority(t){this._setOption("hidingPriority",t)}get isBand(){return this._getOption("isBand")}set isBand(t){this._setOption("isBand",t)}get lookup(){return this._getOption("lookup")}set lookup(t){this._setOption("lookup",t)}get minWidth(){return this._getOption("minWidth")}set minWidth(t){this._setOption("minWidth",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get ownerBand(){return this._getOption("ownerBand")}set ownerBand(t){this._setOption("ownerBand",t)}get renderAsync(){return this._getOption("renderAsync")}set renderAsync(t){this._setOption("renderAsync",t)}get selectedFilterOperation(){return this._getOption("selectedFilterOperation")}set selectedFilterOperation(t){this._setOption("selectedFilterOperation",t)}get setCellValue(){return this._getOption("setCellValue")}set setCellValue(t){this._setOption("setCellValue",t)}get showEditorAlways(){return this._getOption("showEditorAlways")}set showEditorAlways(t){this._setOption("showEditorAlways",t)}get showInColumnChooser(){return this._getOption("showInColumnChooser")}set showInColumnChooser(t){this._setOption("showInColumnChooser",t)}get showWhenGrouped(){return this._getOption("showWhenGrouped")}set showWhenGrouped(t){this._setOption("showWhenGrouped",t)}get sortIndex(){return this._getOption("sortIndex")}set sortIndex(t){this._setOption("sortIndex",t)}get sortingMethod(){return this._getOption("sortingMethod")}set sortingMethod(t){this._setOption("sortingMethod",t)}get sortOrder(){return this._getOption("sortOrder")}set sortOrder(t){this._setOption("sortOrder",t)}get trueText(){return this._getOption("trueText")}set trueText(t){this._setOption("trueText",t)}get type(){return this._getOption("type")}set type(t){this._setOption("type",t)}get validationRules(){return this._getOption("validationRules")}set validationRules(t){this._setOption("validationRules",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get visibleIndex(){return this._getOption("visibleIndex")}set visibleIndex(t){this._setOption("visibleIndex",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var BD=(()=>{class i extends OK{filterValueChange;filterValuesChange;groupIndexChange;selectedFilterOperationChange;sortIndexChange;sortOrderChange;visibleChange;visibleIndexChange;get _optionPath(){return"columns"}get buttonsChildren(){return this._getOption("buttons")}set buttonsChildren(t){this.setChildren("buttons",t)}get columnsChildren(){return this._getOption("columns")}set columnsChildren(t){this.setChildren("columns",t)}get validationRulesChildren(){return this._getOption("validationRules")}set validationRulesChildren(t){this.setChildren("validationRules",t)}constructor(t,n){super(),this._createEventEmitters([{emit:"filterValueChange"},{emit:"filterValuesChange"},{emit:"groupIndexChange"},{emit:"selectedFilterOperationChange"},{emit:"sortIndexChange"},{emit:"sortOrderChange"},{emit:"visibleChange"},{emit:"visibleIndexChange"}]),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-column"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,_o,4),ke(s,i,4),ke(s,PD,4)),n&2){let r;Be(r=Ve())&&(o.buttonsChildren=r),Be(r=Ve())&&(o.columnsChildren=r),Be(r=Ve())&&(o.validationRulesChildren=r)}},inputs:{alignment:"alignment",allowEditing:"allowEditing",allowExporting:"allowExporting",allowFiltering:"allowFiltering",allowFixing:"allowFixing",allowGrouping:"allowGrouping",allowHeaderFiltering:"allowHeaderFiltering",allowHiding:"allowHiding",allowReordering:"allowReordering",allowResizing:"allowResizing",allowSearch:"allowSearch",allowSorting:"allowSorting",autoExpandGroup:"autoExpandGroup",buttons:"buttons",calculateCellValue:"calculateCellValue",calculateDisplayValue:"calculateDisplayValue",calculateFilterExpression:"calculateFilterExpression",calculateGroupValue:"calculateGroupValue",calculateSortValue:"calculateSortValue",caption:"caption",cellTemplate:"cellTemplate",columns:"columns",cssClass:"cssClass",customizeText:"customizeText",dataField:"dataField",dataType:"dataType",editCellTemplate:"editCellTemplate",editorOptions:"editorOptions",encodeHtml:"encodeHtml",falseText:"falseText",filterOperations:"filterOperations",filterType:"filterType",filterValue:"filterValue",filterValues:"filterValues",fixed:"fixed",fixedPosition:"fixedPosition",format:"format",formItem:"formItem",groupCellTemplate:"groupCellTemplate",groupIndex:"groupIndex",headerCellTemplate:"headerCellTemplate",headerFilter:"headerFilter",hidingPriority:"hidingPriority",isBand:"isBand",lookup:"lookup",minWidth:"minWidth",name:"name",ownerBand:"ownerBand",renderAsync:"renderAsync",selectedFilterOperation:"selectedFilterOperation",setCellValue:"setCellValue",showEditorAlways:"showEditorAlways",showInColumnChooser:"showInColumnChooser",showWhenGrouped:"showWhenGrouped",sortIndex:"sortIndex",sortingMethod:"sortingMethod",sortOrder:"sortOrder",trueText:"trueText",type:"type",validationRules:"validationRules",visible:"visible",visibleIndex:"visibleIndex",width:"width"},outputs:{filterValueChange:"filterValueChange",filterValuesChange:"filterValuesChange",groupIndexChange:"groupIndexChange",selectedFilterOperationChange:"selectedFilterOperationChange",sortIndexChange:"sortIndexChange",sortOrderChange:"sortOrderChange",visibleChange:"visibleChange",visibleIndexChange:"visibleIndexChange"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),kC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var BC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var VC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var LC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var NC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var HC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var fl=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var rp=(()=>{class i extends hn{renderer;document;element;get cssClass(){return this._getOption("cssClass")}set cssClass(t){this._setOption("cssClass",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get html(){return this._getOption("html")}set html(t){this._setOption("html",t)}get locateInMenu(){return this._getOption("locateInMenu")}set locateInMenu(t){this._setOption("locateInMenu",t)}get location(){return this._getOption("location")}set location(t){this._setOption("location",t)}get menuItemTemplate(){return this._getOption("menuItemTemplate")}set menuItemTemplate(t){this._setOption("menuItemTemplate",t)}get options(){return this._getOption("options")}set options(t){this._setOption("options",t)}get showText(){return this._getOption("showText")}set showText(t){this._setOption("showText",t)}get template(){return this._getOption("template")}set template(t){this._setOption("template",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get toolbar(){return this._getOption("toolbar")}set toolbar(t){this._setOption("toolbar",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get widget(){return this._getOption("widget")}set widget(t){this._setOption("widget",t)}get _optionPath(){return"toolbarItems"}constructor(t,n,o,s,r,a){super(),this.renderer=o,this.document=s,this.element=a,t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this)),r.setHost(this)}setTemplate(t){this.template=t}ngAfterViewInit(){mh(this,this.element,this.renderer,this.document)}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1),E(ds),E(Va),E(ee,1),E(Pe))};static \u0275cmp=te({type:i,selectors:[["dxi-toolbar-item"]],inputs:{cssClass:"cssClass",disabled:"disabled",html:"html",locateInMenu:"locateInMenu",location:"location",menuItemTemplate:"menuItemTemplate",options:"options",showText:"showText",template:"template",text:"text",toolbar:"toolbar",visible:"visible",widget:"widget"},standalone:!1,features:[le([k,ee]),J],ngContentSelectors:DC,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},styles:["[_nghost-%COMP%]{display:block}"]})}return i})(),Ai=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var ys=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var $C=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var zC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var SK=(()=>{class i extends hn{get cssClass(){return this._getOption("cssClass")}set cssClass(t){this._setOption("cssClass",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get icon(){return this._getOption("icon")}set icon(t){this._setOption("icon",t)}get locateInMenu(){return this._getOption("locateInMenu")}set locateInMenu(t){this._setOption("locateInMenu",t)}get location(){return this._getOption("location")}set location(t){this._setOption("location",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get options(){return this._getOption("options")}set options(t){this._setOption("options",t)}get showText(){return this._getOption("showText")}set showText(t){this._setOption("showText",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get widget(){return this._getOption("widget")}set widget(t){this._setOption("widget",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var EK=(()=>{class i extends SK{get _optionPath(){return"fileSelectionItems"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-file-selection-item"]],inputs:{cssClass:"cssClass",disabled:"disabled",icon:"icon",locateInMenu:"locateInMenu",location:"location",name:"name",options:"options",showText:"showText",text:"text",visible:"visible",widget:"widget"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var WC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var GC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var KC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var UC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var wK=(()=>{class i extends ko{get applyFilter(){return this._getOption("applyFilter")}set applyFilter(t){this._setOption("applyFilter",t)}get applyFilterText(){return this._getOption("applyFilterText")}set applyFilterText(t){this._setOption("applyFilterText",t)}get betweenEndText(){return this._getOption("betweenEndText")}set betweenEndText(t){this._setOption("betweenEndText",t)}get betweenStartText(){return this._getOption("betweenStartText")}set betweenStartText(t){this._setOption("betweenStartText",t)}get operationDescriptions(){return this._getOption("operationDescriptions")}set operationDescriptions(t){this._setOption("operationDescriptions",t)}get resetOperationText(){return this._getOption("resetOperationText")}set resetOperationText(t){this._setOption("resetOperationText",t)}get showAllText(){return this._getOption("showAllText")}set showAllText(t){this._setOption("showAllText",t)}get showOperationChooser(){return this._getOption("showOperationChooser")}set showOperationChooser(t){this._setOption("showOperationChooser",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var Zge=(()=>{class i extends wK{get _optionPath(){return"filterRow"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-filter-row"]],inputs:{applyFilter:"applyFilter",applyFilterText:"applyFilterText",betweenEndText:"betweenEndText",betweenStartText:"betweenStartText",operationDescriptions:"operationDescriptions",resetOperationText:"resetOperationText",showAllText:"showAllText",showOperationChooser:"showOperationChooser",visible:"visible"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),jC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var qC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var YC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var _l=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Ft=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var IK=(()=>{class i extends hn{get alignByColumn(){return this._getOption("alignByColumn")}set alignByColumn(t){this._setOption("alignByColumn",t)}get column(){return this._getOption("column")}set column(t){this._setOption("column",t)}get customizeText(){return this._getOption("customizeText")}set customizeText(t){this._setOption("customizeText",t)}get displayFormat(){return this._getOption("displayFormat")}set displayFormat(t){this._setOption("displayFormat",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get showInColumn(){return this._getOption("showInColumn")}set showInColumn(t){this._setOption("showInColumn",t)}get showInGroupFooter(){return this._getOption("showInGroupFooter")}set showInGroupFooter(t){this._setOption("showInGroupFooter",t)}get skipEmptyValues(){return this._getOption("skipEmptyValues")}set skipEmptyValues(t){this._setOption("skipEmptyValues",t)}get summaryType(){return this._getOption("summaryType")}set summaryType(t){this._setOption("summaryType",t)}get valueFormat(){return this._getOption("valueFormat")}set valueFormat(t){this._setOption("valueFormat",t)}get _optionPath(){return"groupItems"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-group-item"]],inputs:{alignByColumn:"alignByColumn",column:"column",customizeText:"customizeText",displayFormat:"displayFormat",name:"name",showInColumn:"showInColumn",showInGroupFooter:"showInGroupFooter",skipEmptyValues:"skipEmptyValues",summaryType:"summaryType",valueFormat:"valueFormat"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),XC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var QC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var ZC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var JC=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var ex=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Cl=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Pt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var tx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var ix=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Jge=(()=>{class i extends ko{get enabled(){return this._getOption("enabled")}set enabled(t){this._setOption("enabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get indicatorSrc(){return this._getOption("indicatorSrc")}set indicatorSrc(t){this._setOption("indicatorSrc",t)}get shading(){return this._getOption("shading")}set shading(t){this._setOption("shading",t)}get shadingColor(){return this._getOption("shadingColor")}set shadingColor(t){this._setOption("shadingColor",t)}get showIndicator(){return this._getOption("showIndicator")}set showIndicator(t){this._setOption("showIndicator",t)}get showPane(){return this._getOption("showPane")}set showPane(t){this._setOption("showPane",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get _optionPath(){return"loadPanel"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-load-panel"]],inputs:{enabled:"enabled",height:"height",indicatorSrc:"indicatorSrc",shading:"shading",shadingColor:"shadingColor",showIndicator:"showIndicator",showPane:"showPane",text:"text",width:"width"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),nx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var eme=(()=>{class i extends ko{get allowClearing(){return this._getOption("allowClearing")}set allowClearing(t){this._setOption("allowClearing",t)}get calculateCellValue(){return this._getOption("calculateCellValue")}set calculateCellValue(t){this._setOption("calculateCellValue",t)}get dataSource(){return this._getOption("dataSource")}set dataSource(t){this._setOption("dataSource",t)}get displayExpr(){return this._getOption("displayExpr")}set displayExpr(t){this._setOption("displayExpr",t)}get valueExpr(){return this._getOption("valueExpr")}set valueExpr(t){this._setOption("valueExpr",t)}get _optionPath(){return"lookup"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-lookup"]],inputs:{allowClearing:"allowClearing",calculateCellValue:"calculateCellValue",dataSource:"dataSource",displayExpr:"displayExpr",valueExpr:"valueExpr"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),ox=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var sx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var kt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Bt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var rx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Mi=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var tme=(()=>{class i extends ko{get allowedPageSizes(){return this._getOption("allowedPageSizes")}set allowedPageSizes(t){this._setOption("allowedPageSizes",t)}get displayMode(){return this._getOption("displayMode")}set displayMode(t){this._setOption("displayMode",t)}get infoText(){return this._getOption("infoText")}set infoText(t){this._setOption("infoText",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get showInfo(){return this._getOption("showInfo")}set showInfo(t){this._setOption("showInfo",t)}get showNavigationButtons(){return this._getOption("showNavigationButtons")}set showNavigationButtons(t){this._setOption("showNavigationButtons",t)}get showPageSizeSelector(){return this._getOption("showPageSizeSelector")}set showPageSizeSelector(t){this._setOption("showPageSizeSelector",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get _optionPath(){return"pager"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-pager"]],inputs:{allowedPageSizes:"allowedPageSizes",displayMode:"displayMode",infoText:"infoText",label:"label",showInfo:"showInfo",showNavigationButtons:"showNavigationButtons",showPageSizeSelector:"showPageSizeSelector",visible:"visible"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),ax=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var ime=(()=>{class i extends ko{get enabled(){return this._getOption("enabled")}set enabled(t){this._setOption("enabled",t)}get pageIndex(){return this._getOption("pageIndex")}set pageIndex(t){this._setOption("pageIndex",t)}get pageSize(){return this._getOption("pageSize")}set pageSize(t){this._setOption("pageSize",t)}pageIndexChange;pageSizeChange;get _optionPath(){return"paging"}constructor(t,n){super(),this._createEventEmitters([{emit:"pageIndexChange"},{emit:"pageSizeChange"}]),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-paging"]],inputs:{enabled:"enabled",pageIndex:"pageIndex",pageSize:"pageSize"},outputs:{pageIndexChange:"pageIndexChange",pageSizeChange:"pageSizeChange"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),lx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var dx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Vt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var cx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var nme=(()=>{class i extends ko{get allowDropInsideItem(){return this._getOption("allowDropInsideItem")}set allowDropInsideItem(t){this._setOption("allowDropInsideItem",t)}get allowReordering(){return this._getOption("allowReordering")}set allowReordering(t){this._setOption("allowReordering",t)}get autoScroll(){return this._getOption("autoScroll")}set autoScroll(t){this._setOption("autoScroll",t)}get boundary(){return this._getOption("boundary")}set boundary(t){this._setOption("boundary",t)}get container(){return this._getOption("container")}set container(t){this._setOption("container",t)}get cursorOffset(){return this._getOption("cursorOffset")}set cursorOffset(t){this._setOption("cursorOffset",t)}get data(){return this._getOption("data")}set data(t){this._setOption("data",t)}get dragDirection(){return this._getOption("dragDirection")}set dragDirection(t){this._setOption("dragDirection",t)}get dragTemplate(){return this._getOption("dragTemplate")}set dragTemplate(t){this._setOption("dragTemplate",t)}get dropFeedbackMode(){return this._getOption("dropFeedbackMode")}set dropFeedbackMode(t){this._setOption("dropFeedbackMode",t)}get filter(){return this._getOption("filter")}set filter(t){this._setOption("filter",t)}get group(){return this._getOption("group")}set group(t){this._setOption("group",t)}get handle(){return this._getOption("handle")}set handle(t){this._setOption("handle",t)}get onAdd(){return this._getOption("onAdd")}set onAdd(t){this._setOption("onAdd",t)}get onDragChange(){return this._getOption("onDragChange")}set onDragChange(t){this._setOption("onDragChange",t)}get onDragEnd(){return this._getOption("onDragEnd")}set onDragEnd(t){this._setOption("onDragEnd",t)}get onDragMove(){return this._getOption("onDragMove")}set onDragMove(t){this._setOption("onDragMove",t)}get onDragStart(){return this._getOption("onDragStart")}set onDragStart(t){this._setOption("onDragStart",t)}get onRemove(){return this._getOption("onRemove")}set onRemove(t){this._setOption("onRemove",t)}get onReorder(){return this._getOption("onReorder")}set onReorder(t){this._setOption("onReorder",t)}get scrollSensitivity(){return this._getOption("scrollSensitivity")}set scrollSensitivity(t){this._setOption("scrollSensitivity",t)}get scrollSpeed(){return this._getOption("scrollSpeed")}set scrollSpeed(t){this._setOption("scrollSpeed",t)}get showDragIcons(){return this._getOption("showDragIcons")}set showDragIcons(t){this._setOption("showDragIcons",t)}get _optionPath(){return"rowDragging"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-row-dragging"]],inputs:{allowDropInsideItem:"allowDropInsideItem",allowReordering:"allowReordering",autoScroll:"autoScroll",boundary:"boundary",container:"container",cursorOffset:"cursorOffset",data:"data",dragDirection:"dragDirection",dragTemplate:"dragTemplate",dropFeedbackMode:"dropFeedbackMode",filter:"filter",group:"group",handle:"handle",onAdd:"onAdd",onDragChange:"onDragChange",onDragEnd:"onDragEnd",onDragMove:"onDragMove",onDragStart:"onDragStart",onRemove:"onRemove",onReorder:"onReorder",scrollSensitivity:"scrollSensitivity",scrollSpeed:"scrollSpeed",showDragIcons:"showDragIcons"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),ux=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var hx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var px=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var gx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var mx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var DK=(()=>{class i extends ko{get allowSelectAll(){return this._getOption("allowSelectAll")}set allowSelectAll(t){this._setOption("allowSelectAll",t)}get recursive(){return this._getOption("recursive")}set recursive(t){this._setOption("recursive",t)}get selectByClick(){return this._getOption("selectByClick")}set selectByClick(t){this._setOption("selectByClick",t)}get deferred(){return this._getOption("deferred")}set deferred(t){this._setOption("deferred",t)}get mode(){return this._getOption("mode")}set mode(t){this._setOption("mode",t)}get selectAllMode(){return this._getOption("selectAllMode")}set selectAllMode(t){this._setOption("selectAllMode",t)}get sensitivity(){return this._getOption("sensitivity")}set sensitivity(t){this._setOption("sensitivity",t)}get showCheckBoxesMode(){return this._getOption("showCheckBoxesMode")}set showCheckBoxesMode(t){this._setOption("showCheckBoxesMode",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var ome=(()=>{class i extends DK{get _optionPath(){return"selection"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-selection"]],inputs:{allowSelectAll:"allowSelectAll",recursive:"recursive",selectByClick:"selectByClick",deferred:"deferred",mode:"mode",selectAllMode:"selectAllMode",sensitivity:"sensitivity",showCheckBoxesMode:"showCheckBoxesMode"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),fx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Os=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var _x=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Lt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var VD=(()=>{class i extends hn{get groupColumn(){return this._getOption("groupColumn")}set groupColumn(t){this._setOption("groupColumn",t)}get sortOrder(){return this._getOption("sortOrder")}set sortOrder(t){this._setOption("sortOrder",t)}get summaryItem(){return this._getOption("summaryItem")}set summaryItem(t){this._setOption("summaryItem",t)}get _optionPath(){return"sortByGroupSummaryInfo"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-sort-by-group-summary-info"]],inputs:{groupColumn:"groupColumn",sortOrder:"sortOrder",summaryItem:"summaryItem"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),Cx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var xx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var vx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var TK=(()=>{class i extends hn{get alignment(){return this._getOption("alignment")}set alignment(t){this._setOption("alignment",t)}get column(){return this._getOption("column")}set column(t){this._setOption("column",t)}get cssClass(){return this._getOption("cssClass")}set cssClass(t){this._setOption("cssClass",t)}get customizeText(){return this._getOption("customizeText")}set customizeText(t){this._setOption("customizeText",t)}get displayFormat(){return this._getOption("displayFormat")}set displayFormat(t){this._setOption("displayFormat",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get showInColumn(){return this._getOption("showInColumn")}set showInColumn(t){this._setOption("showInColumn",t)}get skipEmptyValues(){return this._getOption("skipEmptyValues")}set skipEmptyValues(t){this._setOption("skipEmptyValues",t)}get summaryType(){return this._getOption("summaryType")}set summaryType(t){this._setOption("summaryType",t)}get valueFormat(){return this._getOption("valueFormat")}set valueFormat(t){this._setOption("valueFormat",t)}get _optionPath(){return"totalItems"}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnDestroy(){this._deleteRemovedOptions(this._fullOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxi-total-item"]],inputs:{alignment:"alignment",column:"column",cssClass:"cssClass",customizeText:"customizeText",displayFormat:"displayFormat",name:"name",showInColumn:"showInColumn",skipEmptyValues:"skipEmptyValues",summaryType:"summaryType",valueFormat:"valueFormat"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),bx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var sme=(()=>{class i extends ko{get calculateCustomSummary(){return this._getOption("calculateCustomSummary")}set calculateCustomSummary(t){this._setOption("calculateCustomSummary",t)}get groupItems(){return this._getOption("groupItems")}set groupItems(t){this._setOption("groupItems",t)}get recalculateWhileEditing(){return this._getOption("recalculateWhileEditing")}set recalculateWhileEditing(t){this._setOption("recalculateWhileEditing",t)}get skipEmptyValues(){return this._getOption("skipEmptyValues")}set skipEmptyValues(t){this._setOption("skipEmptyValues",t)}get texts(){return this._getOption("texts")}set texts(t){this._setOption("texts",t)}get totalItems(){return this._getOption("totalItems")}set totalItems(t){this._setOption("totalItems",t)}get _optionPath(){return"summary"}get groupItemsChildren(){return this._getOption("groupItems")}set groupItemsChildren(t){this.setChildren("groupItems",t)}get totalItemsChildren(){return this._getOption("totalItems")}set totalItemsChildren(t){this.setChildren("totalItems",t)}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-summary"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,IK,4),ke(s,TK,4)),n&2){let r;Be(r=Ve())&&(o.groupItemsChildren=r),Be(r=Ve())&&(o.totalItemsChildren=r)}},inputs:{calculateCustomSummary:"calculateCustomSummary",groupItems:"groupItems",recalculateWhileEditing:"recalculateWhileEditing",skipEmptyValues:"skipEmptyValues",texts:"texts",totalItems:"totalItems"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),yx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Ox=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Sx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var Nt=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var AK=(()=>{class i extends ko{get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get fileSelectionItems(){return this._getOption("fileSelectionItems")}set fileSelectionItems(t){this._setOption("fileSelectionItems",t)}get container(){return this._getOption("container")}set container(t){this._setOption("container",t)}get multiline(){return this._getOption("multiline")}set multiline(t){this._setOption("multiline",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275cmp=te({type:i,selectors:[["ng-component"]],standalone:!1,features:[J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})();var rme=(()=>{class i extends AK{get _optionPath(){return"toolbar"}get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}get fileSelectionItemsChildren(){return this._getOption("fileSelectionItems")}set fileSelectionItemsChildren(t){this.setChildren("fileSelectionItems",t)}constructor(t,n){super(),t.setNestedOption(this),n.setHost(this,this._fullOptionPath.bind(this))}ngOnInit(){this._addRecreatedComponent()}ngOnDestroy(){this._addRemovedOption(this._getOptionPath())}static \u0275fac=function(n){return new(n||i)(E(k,5),E(k,1))};static \u0275cmp=te({type:i,selectors:[["dxo-toolbar"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,qn,4),ke(s,EK,4)),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r),Be(r=Ve())&&(o.fileSelectionItemsChildren=r)}},inputs:{disabled:"disabled",items:"items",visible:"visible",fileSelectionItems:"fileSelectionItems",container:"container",multiline:"multiline"},standalone:!1,features:[le([k]),J],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),Ex=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var wx=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})();var MK=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get animationDuration(){return this._getOption("animationDuration")}set animationDuration(t){this._setOption("animationDuration",t)}get collapsible(){return this._getOption("collapsible")}set collapsible(t){this._setOption("collapsible",t)}get dataSource(){return this._getOption("dataSource")}set dataSource(t){this._setOption("dataSource",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get itemHoldTimeout(){return this._getOption("itemHoldTimeout")}set itemHoldTimeout(t){this._setOption("itemHoldTimeout",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get itemTemplate(){return this._getOption("itemTemplate")}set itemTemplate(t){this._setOption("itemTemplate",t)}get itemTitleTemplate(){return this._getOption("itemTitleTemplate")}set itemTitleTemplate(t){this._setOption("itemTitleTemplate",t)}get keyExpr(){return this._getOption("keyExpr")}set keyExpr(t){this._setOption("keyExpr",t)}get multiple(){return this._getOption("multiple")}set multiple(t){this._setOption("multiple",t)}get noDataText(){return this._getOption("noDataText")}set noDataText(t){this._setOption("noDataText",t)}get repaintChangesOnly(){return this._getOption("repaintChangesOnly")}set repaintChangesOnly(t){this._setOption("repaintChangesOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get selectedIndex(){return this._getOption("selectedIndex")}set selectedIndex(t){this._setOption("selectedIndex",t)}get selectedItem(){return this._getOption("selectedItem")}set selectedItem(t){this._setOption("selectedItem",t)}get selectedItemKeys(){return this._getOption("selectedItemKeys")}set selectedItemKeys(t){this._setOption("selectedItemKeys",t)}get selectedItems(){return this._getOption("selectedItems")}set selectedItems(t){this._setOption("selectedItems",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onContentReady;onDisposing;onInitialized;onItemClick;onItemContextMenu;onItemHold;onItemRendered;onItemTitleClick;onOptionChanged;onSelectionChanged;accessKeyChange;activeStateEnabledChange;animationDurationChange;collapsibleChange;dataSourceChange;deferRenderingChange;disabledChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;itemHoldTimeoutChange;itemsChange;itemTemplateChange;itemTitleTemplateChange;keyExprChange;multipleChange;noDataTextChange;repaintChangesOnlyChange;rtlEnabledChange;selectedIndexChange;selectedItemChange;selectedItemKeysChange;selectedItemsChange;tabIndexChange;visibleChange;widthChange;get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"itemClick",emit:"onItemClick"},{subscribe:"itemContextMenu",emit:"onItemContextMenu"},{subscribe:"itemHold",emit:"onItemHold"},{subscribe:"itemRendered",emit:"onItemRendered"},{subscribe:"itemTitleClick",emit:"onItemTitleClick"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"selectionChanged",emit:"onSelectionChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"animationDurationChange"},{emit:"collapsibleChange"},{emit:"dataSourceChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"itemHoldTimeoutChange"},{emit:"itemsChange"},{emit:"itemTemplateChange"},{emit:"itemTitleTemplateChange"},{emit:"keyExprChange"},{emit:"multipleChange"},{emit:"noDataTextChange"},{emit:"repaintChangesOnlyChange"},{emit:"rtlEnabledChange"},{emit:"selectedIndexChange"},{emit:"selectedItemChange"},{emit:"selectedItemKeysChange"},{emit:"selectedItemsChange"},{emit:"tabIndexChange"},{emit:"visibleChange"},{emit:"widthChange"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new FD(t,n)}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("dataSource",t),this.setupChanges("items",t),this.setupChanges("selectedItemKeys",t),this.setupChanges("selectedItems",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("dataSource"),this._idh.doCheck("items"),this._idh.doCheck("selectedItemKeys"),this._idh.doCheck("selectedItems"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-accordion"]],contentQueries:function(n,o,s){if(n&1&&ke(s,qn,4),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r)}},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",animationDuration:"animationDuration",collapsible:"collapsible",dataSource:"dataSource",deferRendering:"deferRendering",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",itemHoldTimeout:"itemHoldTimeout",items:"items",itemTemplate:"itemTemplate",itemTitleTemplate:"itemTitleTemplate",keyExpr:"keyExpr",multiple:"multiple",noDataText:"noDataText",repaintChangesOnly:"repaintChangesOnly",rtlEnabled:"rtlEnabled",selectedIndex:"selectedIndex",selectedItem:"selectedItem",selectedItemKeys:"selectedItemKeys",selectedItems:"selectedItems",tabIndex:"tabIndex",visible:"visible",width:"width"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onInitialized:"onInitialized",onItemClick:"onItemClick",onItemContextMenu:"onItemContextMenu",onItemHold:"onItemHold",onItemRendered:"onItemRendered",onItemTitleClick:"onItemTitleClick",onOptionChanged:"onOptionChanged",onSelectionChanged:"onSelectionChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",animationDurationChange:"animationDurationChange",collapsibleChange:"collapsibleChange",dataSourceChange:"dataSourceChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",itemHoldTimeoutChange:"itemHoldTimeoutChange",itemsChange:"itemsChange",itemTemplateChange:"itemTemplateChange",itemTitleTemplateChange:"itemTitleTemplateChange",keyExprChange:"keyExprChange",multipleChange:"multipleChange",noDataTextChange:"noDataTextChange",repaintChangesOnlyChange:"repaintChangesOnlyChange",rtlEnabledChange:"rtlEnabledChange",selectedIndexChange:"selectedIndexChange",selectedItemChange:"selectedItemChange",selectedItemKeysChange:"selectedItemKeysChange",selectedItemsChange:"selectedItemsChange",tabIndexChange:"tabIndexChange",visibleChange:"visibleChange",widthChange:"widthChange"},standalone:!1,features:[le([ee,ae,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),RK=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Ti,qe,ye,Ti,ye]})}return i})();var Co=function(i){return i===0?0:i/Math.abs(i)},ft=function(i,e,t){let n=!e&&e!==0,o=!t&&t!==0;return n&&(e=o?i:Math.min(i,t)),o&&(t=n?i:Math.max(i,e)),Math.min(Math.max(i,e),t)},fn=function(i,e,t){return i>=e&&i<=t};function LD(i){return Math.abs(parseInt(i.toExponential().split("e")[1]))}function FK(i){let e=i.toExponential().split("e"),t=parseFloat(e[0]);return{exponent:parseInt(e[1]),mantissa:t}}function ap(i,e){let t=FK(i);return parseFloat(`${t.mantissa}e${t.exponent+e}`)}function PK(){return 3e-4.toPrecision(3)!=="0.000300"}function pc(i,e){let t=kK(e||0)+2,n=i.toString().split("."),o=i,s=Math.abs(i),r,a=Xu(i),l=s>1?10:0;return n.length===1?i:(a||(Xu(e)&&(t=n[0].length+LD(e)),i=s,i=i-Math.floor(i)+l),t=PK()&&LD(i)>6||t>7?15:7,!a&&(r=parseFloat(i.toPrecision(t)).toString().split("."),r[0]===l.toString())?parseFloat(n[0]+"."+r[1]):parseFloat(o.toPrecision(t)))}function kK(i){let e=i.toString();if(e.indexOf(".")<0)return 0;let t=e.split("."),n=t[1].indexOf("e");return n>=0?n:t[1].length}var BK=10;function VK(i){return Co(i)*Math.round(Math.abs(i))}function LK(i,e){let t=Math.pow(BK,e),n=ap(i,e);return VK(n)/t}function lp(i,e){let t=e||0;return(t>0?LK(...arguments):i).toFixed(t)}var NK={thousandsSeparator:",",decimalSeparator:"."},ND="'";function HK(i){return i.split(",").slice(1).map(function(e){let t=0;return e.split("").filter(function(n,o){t+=n==="'";let s=n==="#"||n==="0",r=t%2;return s&&!r}).length})}function $K(i){let e=i.split(";");return e.length===1&&e.push("-"+e[0]),e}function Ix(i){return i.toString().split("").reverse().join("")}function zK(i){return i.indexOf("%")!==-1&&!i.match(/'[^']*%[^']*'/g)}function UD(i){return i.replace(/'.+'/g,"")}function HD(i){if(!i)return 0;let e=UD(i);return e.length-e.replace(/[#]/g,"").length}function $D(i){if(!i)return 0;let e=UD(i);return e.length-e.replace(/[0]/g,"").length}function zD(i,e,t){if(!i)return"";for(i.length>t&&(i=i.substr(0,t));i.length>e&&i.slice(-1)==="0";)i=i.substr(0,i.length-1);for(;i.length<e;)i+="0";return i}function WK(i,e,t){if(!e.length)return i;let n=[],o=0;for(;i;){let s=e[o];if(!s)break;n.push(i.slice(0,s)),i=i.slice(s),o<e.length-1&&o++}return n.join(t)}function WD(i,e){return i.split(ND).map(function(t,n){let o=n%2;return!t&&o?ND:o?t:t.replace(/[,#0]+/,e)}).join("")}function GK(i){let e=!1;for(let t=0;t<i.length;t++)if(i[t]==="'"&&(e=!e),i[t]==="."&&!e)return t;return i.length}function jD(i,e){return e=e||NK,function(t){if(typeof t!="number"||isNaN(t))return"";let n=$K(i),o=1/t===1/0,s=t>0||o,r=n[s?0:1],a=GK(r),l=[r.substr(0,a),r.substr(a+1)],d=$D(l[1]),c=d+HD(l[1]);zK(r)&&(t=ap(t,2)),s||(t=-t);let h=$D(l[0]),p=HD(l[0])||e.unlimitedIntegerDigits?void 0:h,g=Math.floor(t).toString().length,C=ft(c,0,15-g),v=HK(l[0]).reverse(),b=lp(t,C<0?0:C).split("."),T=zD(Ix(b[0]),h,p),R=zD(b[1],d,c);T=WK(T,v,e.thousandsSeparator);let U=Ix(WD(Ix(l[0]),T)),Q=c?WD(l[1],R):"";return U+(Q.match(/\d/)?e.decimalSeparator:"")+Q}}function gc(i,e,t){let n=(e?.01:1)*parseFloat(i)||0;return t?-n:n}function GD(i,e,t,n){let o=i,s,r,a;do a&&(s=r.length===a.length?"0":"1",i=n?s+i:i+s),r=a||e(gc(o,t)),o=n?"1"+o:o+"1",a=e(gc(o,t));while(r!==a&&(n?r.length===a.length:r.length<=a.length));if(n&&a.length>r.length){let l=e(12345).indexOf("12345")===-1;do i="1"+i;while(l&&gc(i,t)<1e5)}return i}function KD(i,e,t,n){let o=e(gc(i,t,n)),s=i.split("."),r=s[0]+".3"+s[1].slice(1),a=gc(r,t,n),l=e(a).indexOf("3")-1;return o=o.replace(/(\d)\D(\d)/g,"$1,$2"),l>=0&&(o=o.slice(0,l)+"."+o.slice(l+1)),o=o.replace(/1+/,"1").replace(/1/g,"#"),t||(o=o.replace(/%/g,"'%'")),o}function qD(i){let e=".",t=i(1).indexOf("100")>=0;e=GD(e,i,t,!0),e=GD(e,i,t,!1);let n=KD(e,i,t,!1),o=KD(e,i,t,!0);return o==="-"+n?n:n+";"+o}var YD={_formatNumberCore:function(i,e,t){if(e==="currency"){t.precision=t.precision||0;let n=this.format(i,m({},t,{type:"fixedpoint"})),o=this.getCurrencySymbol().symbol.replace(/\$/g,"$$$$");return n=n.replace(/^(\D*)(\d.*)/,"$1"+o+"$2"),n}return this.callBase.apply(this,arguments)},getCurrencySymbol:function(){return{symbol:"$"}},getOpenXmlCurrencyFormat:function(){return"$#,##0{0}_);\\($#,##0{0}\\)"}};var XD=(i,e)=>{if(!e)return;let t=i;if(typeof i=="string"){t="";for(let s=0;s<i.length;s++)i[s]!=="$"&&(t+="\\"),t+=i[s]}let n={".00":"{0}","'":"\\'","\\(":"\\(","\\)":"\\)"," ":"\\ ",'"':"&quot;","\\\xA4":t},o=e.split(";");for(let s=0;s<o.length;s++)for(let r in n)Object.prototype.hasOwnProperty.call(n,r)&&(o[s]=o[s].replace(new RegExp(r,"g"),n[r]));return o.length===2?o[0]+"_);"+o[1]:o[0]};var QD={af:"\xA4#,##0.00;(\xA4#,##0.00)","af-NA":"\xA4#,##0.00;(\xA4#,##0.00)",agq:"#,##0.00\xA4",ak:"\xA4#,##0.00",am:"\xA4#,##0.00;(\xA4#,##0.00)",ar:"\xA4#,##0.00;(\xA4#,##0.00)","ar-AE":"\xA4#,##0.00;(\xA4#,##0.00)","ar-BH":"\xA4#,##0.00;(\xA4#,##0.00)","ar-DJ":"\xA4#,##0.00;(\xA4#,##0.00)","ar-DZ":"\xA4#,##0.00;(\xA4#,##0.00)","ar-EG":"\xA4#,##0.00;(\xA4#,##0.00)","ar-EH":"\xA4#,##0.00;(\xA4#,##0.00)","ar-ER":"\xA4#,##0.00;(\xA4#,##0.00)","ar-IL":"\xA4#,##0.00;(\xA4#,##0.00)","ar-IQ":"\xA4#,##0.00;(\xA4#,##0.00)","ar-JO":"\xA4#,##0.00;(\xA4#,##0.00)","ar-KM":"\xA4#,##0.00;(\xA4#,##0.00)","ar-KW":"\xA4#,##0.00;(\xA4#,##0.00)","ar-LB":"\xA4#,##0.00;(\xA4#,##0.00)","ar-LY":"\xA4#,##0.00;(\xA4#,##0.00)","ar-MA":"\xA4#,##0.00;(\xA4#,##0.00)","ar-MR":"\xA4#,##0.00;(\xA4#,##0.00)","ar-OM":"\xA4#,##0.00;(\xA4#,##0.00)","ar-PS":"\xA4#,##0.00;(\xA4#,##0.00)","ar-QA":"\xA4#,##0.00;(\xA4#,##0.00)","ar-SA":"\xA4#,##0.00;(\xA4#,##0.00)","ar-SD":"\xA4#,##0.00;(\xA4#,##0.00)","ar-SO":"\xA4#,##0.00;(\xA4#,##0.00)","ar-SS":"\xA4#,##0.00;(\xA4#,##0.00)","ar-SY":"\xA4#,##0.00;(\xA4#,##0.00)","ar-TD":"\xA4#,##0.00;(\xA4#,##0.00)","ar-TN":"\xA4#,##0.00;(\xA4#,##0.00)","ar-YE":"\xA4#,##0.00;(\xA4#,##0.00)",as:"\xA4\xA0#,##,##0.00",asa:"#,##0.00\xA0\xA4",ast:"#,##0.00\xA0\xA4",az:"#,##0.00\xA0\xA4","az-Cyrl":"#,##0.00\xA0\xA4","az-Latn":"#,##0.00\xA0\xA4",bas:"#,##0.00\xA0\xA4",be:"#,##0.00\xA0\xA4","be-tarask":"#,##0.00\xA0\xA4",bem:"\xA4#,##0.00;(\xA4#,##0.00)",bez:"#,##0.00\xA4",bg:"0.00\xA0\xA4;(0.00\xA0\xA4)",bm:"\xA4#,##0.00;(\xA4#,##0.00)",bn:"#,##,##0.00\xA4;(#,##,##0.00\xA4)","bn-IN":"#,##,##0.00\xA4;(#,##,##0.00\xA4)",bo:"\xA4\xA0#,##0.00","bo-IN":"\xA4\xA0#,##0.00",br:"#,##0.00\xA0\xA4",brx:"\xA4\xA0#,##,##0.00",bs:"#,##0.00\xA0\xA4","bs-Cyrl":"#,##0.00\xA0\xA4","bs-Latn":"#,##0.00\xA0\xA4",ca:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","ca-AD":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","ca-ES-valencia":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","ca-FR":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","ca-IT":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",ccp:"#,##,##0.00\xA4;(#,##,##0.00\xA4)","ccp-IN":"#,##,##0.00\xA4;(#,##,##0.00\xA4)",ce:"#,##0.00\xA0\xA4",ceb:"\xA4#,##0.00;(\xA4#,##0.00)",cgg:"\xA4#,##0.00",chr:"\xA4#,##0.00;(\xA4#,##0.00)",ckb:"\xA4\xA0#,##0.00","ckb-IR":"\xA4\xA0#,##0.00",cs:"#,##0.00\xA0\xA4",cy:"\xA4#,##0.00;(\xA4#,##0.00)",da:"#,##0.00\xA0\xA4","da-GL":"#,##0.00\xA0\xA4",dav:"\xA4#,##0.00;(\xA4#,##0.00)",de:"#,##0.00\xA0\xA4","de-AT":"#,##0.00\xA0\xA4","de-BE":"#,##0.00\xA0\xA4","de-CH":"#,##0.00\xA0\xA4","de-IT":"#,##0.00\xA0\xA4","de-LI":"#,##0.00\xA0\xA4","de-LU":"#,##0.00\xA0\xA4",dje:"#,##0.00\xA4",doi:"\xA4#,##0.00",dsb:"#,##0.00\xA0\xA4",dua:"#,##0.00\xA0\xA4",dyo:"#,##0.00\xA0\xA4",dz:"\xA4#,##,##0.00",ebu:"\xA4#,##0.00;(\xA4#,##0.00)",ee:"\xA4#,##0.00;(\xA4#,##0.00)","ee-TG":"\xA4#,##0.00;(\xA4#,##0.00)",el:"#,##0.00\xA0\xA4","el-CY":"#,##0.00\xA0\xA4",en:"\xA4#,##0.00;(\xA4#,##0.00)","en-001":"\xA4#,##0.00;(\xA4#,##0.00)","en-150":"#,##0.00\xA0\xA4","en-AE":"\xA4#,##0.00;(\xA4#,##0.00)","en-AG":"\xA4#,##0.00;(\xA4#,##0.00)","en-AI":"\xA4#,##0.00;(\xA4#,##0.00)","en-AS":"\xA4#,##0.00;(\xA4#,##0.00)","en-AT":"\xA4\xA0#,##0.00","en-AU":"\xA4#,##0.00;(\xA4#,##0.00)","en-BB":"\xA4#,##0.00;(\xA4#,##0.00)","en-BE":"#,##0.00\xA0\xA4","en-BI":"\xA4#,##0.00;(\xA4#,##0.00)","en-BM":"\xA4#,##0.00;(\xA4#,##0.00)","en-BS":"\xA4#,##0.00;(\xA4#,##0.00)","en-BW":"\xA4#,##0.00;(\xA4#,##0.00)","en-BZ":"\xA4#,##0.00;(\xA4#,##0.00)","en-CA":"\xA4#,##0.00;(\xA4#,##0.00)","en-CC":"\xA4#,##0.00;(\xA4#,##0.00)","en-CH":"\xA4\xA0#,##0.00;\xA4-#,##0.00","en-CK":"\xA4#,##0.00;(\xA4#,##0.00)","en-CM":"\xA4#,##0.00;(\xA4#,##0.00)","en-CX":"\xA4#,##0.00;(\xA4#,##0.00)","en-CY":"\xA4#,##0.00;(\xA4#,##0.00)","en-DE":"#,##0.00\xA0\xA4","en-DG":"\xA4#,##0.00;(\xA4#,##0.00)","en-DK":"#,##0.00\xA0\xA4","en-DM":"\xA4#,##0.00;(\xA4#,##0.00)","en-ER":"\xA4#,##0.00;(\xA4#,##0.00)","en-FI":"#,##0.00\xA0\xA4","en-FJ":"\xA4#,##0.00;(\xA4#,##0.00)","en-FK":"\xA4#,##0.00;(\xA4#,##0.00)","en-FM":"\xA4#,##0.00;(\xA4#,##0.00)","en-GB":"\xA4#,##0.00;(\xA4#,##0.00)","en-GD":"\xA4#,##0.00;(\xA4#,##0.00)","en-GG":"\xA4#,##0.00;(\xA4#,##0.00)","en-GH":"\xA4#,##0.00;(\xA4#,##0.00)","en-GI":"\xA4#,##0.00;(\xA4#,##0.00)","en-GM":"\xA4#,##0.00;(\xA4#,##0.00)","en-GU":"\xA4#,##0.00;(\xA4#,##0.00)","en-GY":"\xA4#,##0.00;(\xA4#,##0.00)","en-HK":"\xA4#,##0.00;(\xA4#,##0.00)","en-IE":"\xA4#,##0.00;(\xA4#,##0.00)","en-IL":"\xA4#,##0.00;(\xA4#,##0.00)","en-IM":"\xA4#,##0.00;(\xA4#,##0.00)","en-IN":"\xA4#,##0.00;(\xA4#,##0.00)","en-IO":"\xA4#,##0.00;(\xA4#,##0.00)","en-JE":"\xA4#,##0.00;(\xA4#,##0.00)","en-JM":"\xA4#,##0.00;(\xA4#,##0.00)","en-KE":"\xA4#,##0.00;(\xA4#,##0.00)","en-KI":"\xA4#,##0.00;(\xA4#,##0.00)","en-KN":"\xA4#,##0.00;(\xA4#,##0.00)","en-KY":"\xA4#,##0.00;(\xA4#,##0.00)","en-LC":"\xA4#,##0.00;(\xA4#,##0.00)","en-LR":"\xA4#,##0.00;(\xA4#,##0.00)","en-LS":"\xA4#,##0.00;(\xA4#,##0.00)","en-MG":"\xA4#,##0.00;(\xA4#,##0.00)","en-MH":"\xA4#,##0.00;(\xA4#,##0.00)","en-MO":"\xA4#,##0.00;(\xA4#,##0.00)","en-MP":"\xA4#,##0.00;(\xA4#,##0.00)","en-MS":"\xA4#,##0.00;(\xA4#,##0.00)","en-MT":"\xA4#,##0.00;(\xA4#,##0.00)","en-MU":"\xA4#,##0.00;(\xA4#,##0.00)","en-MV":"\xA4\xA0#,##0.00","en-MW":"\xA4#,##0.00;(\xA4#,##0.00)","en-MY":"\xA4#,##0.00;(\xA4#,##0.00)","en-NA":"\xA4#,##0.00;(\xA4#,##0.00)","en-NF":"\xA4#,##0.00;(\xA4#,##0.00)","en-NG":"\xA4#,##0.00;(\xA4#,##0.00)","en-NL":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","en-NR":"\xA4#,##0.00;(\xA4#,##0.00)","en-NU":"\xA4#,##0.00;(\xA4#,##0.00)","en-NZ":"\xA4#,##0.00;(\xA4#,##0.00)","en-PG":"\xA4#,##0.00;(\xA4#,##0.00)","en-PH":"\xA4#,##0.00;(\xA4#,##0.00)","en-PK":"\xA4#,##0.00;(\xA4#,##0.00)","en-PN":"\xA4#,##0.00;(\xA4#,##0.00)","en-PR":"\xA4#,##0.00;(\xA4#,##0.00)","en-PW":"\xA4#,##0.00;(\xA4#,##0.00)","en-RW":"\xA4#,##0.00;(\xA4#,##0.00)","en-SB":"\xA4#,##0.00;(\xA4#,##0.00)","en-SC":"\xA4#,##0.00;(\xA4#,##0.00)","en-SD":"\xA4#,##0.00;(\xA4#,##0.00)","en-SE":"#,##0.00\xA0\xA4","en-SG":"\xA4#,##0.00;(\xA4#,##0.00)","en-SH":"\xA4#,##0.00;(\xA4#,##0.00)","en-SI":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","en-SL":"\xA4#,##0.00;(\xA4#,##0.00)","en-SS":"\xA4#,##0.00;(\xA4#,##0.00)","en-SX":"\xA4#,##0.00;(\xA4#,##0.00)","en-SZ":"\xA4#,##0.00;(\xA4#,##0.00)","en-TC":"\xA4#,##0.00;(\xA4#,##0.00)","en-TK":"\xA4#,##0.00;(\xA4#,##0.00)","en-TO":"\xA4#,##0.00;(\xA4#,##0.00)","en-TT":"\xA4#,##0.00;(\xA4#,##0.00)","en-TV":"\xA4#,##0.00;(\xA4#,##0.00)","en-TZ":"\xA4#,##0.00;(\xA4#,##0.00)","en-UG":"\xA4#,##0.00;(\xA4#,##0.00)","en-UM":"\xA4#,##0.00;(\xA4#,##0.00)","en-VC":"\xA4#,##0.00;(\xA4#,##0.00)","en-VG":"\xA4#,##0.00;(\xA4#,##0.00)","en-VI":"\xA4#,##0.00;(\xA4#,##0.00)","en-VU":"\xA4#,##0.00;(\xA4#,##0.00)","en-WS":"\xA4#,##0.00;(\xA4#,##0.00)","en-ZA":"\xA4#,##0.00;(\xA4#,##0.00)","en-ZM":"\xA4#,##0.00;(\xA4#,##0.00)","en-ZW":"\xA4#,##0.00;(\xA4#,##0.00)",eo:"\xA4\xA0#,##0.00",es:"#,##0.00\xA0\xA4","es-419":"\xA4#,##0.00","es-AR":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","es-BO":"\xA4#,##0.00","es-BR":"\xA4#,##0.00","es-BZ":"\xA4#,##0.00","es-CL":"\xA4#,##0.00","es-CO":"\xA4#,##0.00","es-CR":"\xA4#,##0.00","es-CU":"\xA4#,##0.00","es-DO":"\xA4#,##0.00;(\xA4#,##0.00)","es-EA":"#,##0.00\xA0\xA4","es-EC":"\xA4#,##0.00","es-GQ":"#,##0.00\xA0\xA4","es-GT":"\xA4#,##0.00","es-HN":"\xA4#,##0.00","es-IC":"#,##0.00\xA0\xA4","es-MX":"\xA4#,##0.00","es-NI":"\xA4#,##0.00","es-PA":"\xA4#,##0.00","es-PE":"\xA4#,##0.00","es-PH":"#,##0.00\xA0\xA4","es-PR":"\xA4#,##0.00","es-PY":"\xA4#,##0.00","es-SV":"\xA4#,##0.00","es-US":"\xA4#,##0.00","es-UY":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","es-VE":"\xA4#,##0.00",et:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",eu:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",ewo:"#,##0.00\xA0\xA4",fa:"\u200E\xA4\xA0#,##0.00;\u200E(\xA4\xA0#,##0.00)","fa-AF":"\xA4\xA0#,##0.00;\u200E(\xA4\xA0#,##0.00)",ff:"#,##0.00\xA0\xA4","ff-Adlm":"\xA4\xA0#,##0.00","ff-Adlm-BF":"\xA4\xA0#,##0.00","ff-Adlm-CM":"\xA4\xA0#,##0.00","ff-Adlm-GH":"\xA4\xA0#,##0.00","ff-Adlm-GM":"\xA4\xA0#,##0.00","ff-Adlm-GW":"\xA4\xA0#,##0.00","ff-Adlm-LR":"\xA4\xA0#,##0.00","ff-Adlm-MR":"\xA4\xA0#,##0.00","ff-Adlm-NE":"\xA4\xA0#,##0.00","ff-Adlm-NG":"\xA4\xA0#,##0.00","ff-Adlm-SL":"\xA4\xA0#,##0.00","ff-Adlm-SN":"\xA4\xA0#,##0.00","ff-Latn":"#,##0.00\xA0\xA4","ff-Latn-BF":"#,##0.00\xA0\xA4","ff-Latn-CM":"#,##0.00\xA0\xA4","ff-Latn-GH":"#,##0.00\xA0\xA4","ff-Latn-GM":"#,##0.00\xA0\xA4","ff-Latn-GN":"#,##0.00\xA0\xA4","ff-Latn-GW":"#,##0.00\xA0\xA4","ff-Latn-LR":"#,##0.00\xA0\xA4","ff-Latn-MR":"#,##0.00\xA0\xA4","ff-Latn-NE":"#,##0.00\xA0\xA4","ff-Latn-NG":"#,##0.00\xA0\xA4","ff-Latn-SL":"#,##0.00\xA0\xA4",fi:"#,##0.00\xA0\xA4",fil:"\xA4#,##0.00;(\xA4#,##0.00)",fo:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fo-DK":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",fr:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-BE":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-BF":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-BI":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-BJ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-BL":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CA":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CD":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CF":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CG":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CH":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CI":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-CM":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-DJ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-DZ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-GA":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-GF":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-GN":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-GP":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-GQ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-HT":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-KM":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-LU":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MA":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MC":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MF":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MG":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-ML":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MQ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MR":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-MU":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-NC":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-NE":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-PF":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-PM":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-RE":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-RW":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-SC":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-SN":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-SY":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-TD":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-TG":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-TN":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-VU":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-WF":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","fr-YT":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",fur:"\xA4\xA0#,##0.00",fy:"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)",ga:"\xA4#,##0.00;(\xA4#,##0.00)","ga-GB":"\xA4#,##0.00;(\xA4#,##0.00)",gd:"\xA4#,##0.00;(\xA4#,##0.00)",gl:"#,##0.00\xA0\xA4",gsw:"#,##0.00\xA0\xA4","gsw-FR":"#,##0.00\xA0\xA4","gsw-LI":"#,##0.00\xA0\xA4",gu:"\xA4#,##,##0.00;(\xA4#,##,##0.00)",guz:"\xA4#,##0.00;(\xA4#,##0.00)",gv:"\xA4#,##0.00",ha:"\xA4\xA0#,##0.00","ha-GH":"\xA4\xA0#,##0.00","ha-NE":"\xA4\xA0#,##0.00",haw:"\xA4#,##0.00;(\xA4#,##0.00)",he:"#,##0.00\xA0\xA4",hi:"\xA4#,##,##0.00","hi-Latn":"\xA4#,##,##0.00",hr:"#,##0.00\xA0\xA4","hr-BA":"#,##0.00\xA0\xA4",hsb:"#,##0.00\xA0\xA4",hu:"#,##0.00\xA0\xA4",hy:"#,##0.00\xA0\xA4",ia:"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)",id:"\xA4#,##0.00",ig:"\xA4#,##0.00;(\xA4#,##0.00)",ii:"\xA4\xA0#,##0.00",is:"#,##0.00\xA0\xA4",it:"#,##0.00\xA0\xA4","it-CH":"#,##0.00\xA0\xA4","it-SM":"#,##0.00\xA0\xA4","it-VA":"#,##0.00\xA0\xA4",ja:"\xA4#,##0.00;(\xA4#,##0.00)",jgo:"\xA4\xA0#,##0.00",jmc:"\xA4#,##0.00",jv:"\xA4\xA0#,##0.00",ka:"#,##0.00\xA0\xA4",kab:"#,##0.00\xA4",kam:"\xA4#,##0.00;(\xA4#,##0.00)",kde:"\xA4#,##0.00;(\xA4#,##0.00)",kea:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",kgp:"\xA4\xA0#,##0.00",khq:"#,##0.00\xA4",ki:"\xA4#,##0.00;(\xA4#,##0.00)",kk:"#,##0.00\xA0\xA4",kkj:"\xA4\xA0#,##0.00",kl:"\xA4#,##0.00;\xA4-#,##0.00",kln:"\xA4#,##0.00;(\xA4#,##0.00)",km:"#,##0.00\xA4;(#,##0.00\xA4)",kn:"\xA4#,##0.00;(\xA4#,##0.00)",ko:"\xA4#,##0.00;(\xA4#,##0.00)","ko-KP":"\xA4#,##0.00;(\xA4#,##0.00)",kok:"\xA4#,##0.00;(\xA4#,##0.00)",ks:"\xA4#,##0.00","ks-Arab":"\xA4#,##0.00","ks-Deva":"\xA4\xA0#,##0.00",ksb:"#,##0.00\xA4",ksf:"#,##0.00\xA0\xA4",ksh:"#,##0.00\xA0\xA4",ku:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",kw:"\xA4#,##0.00",ky:"#,##0.00\xA0\xA4",lag:"\xA4\xA0#,##0.00",lb:"#,##0.00\xA0\xA4",lg:"#,##0.00\xA4",lkt:"\xA4\xA0#,##0.00",ln:"#,##0.00\xA0\xA4","ln-AO":"#,##0.00\xA0\xA4","ln-CF":"#,##0.00\xA0\xA4","ln-CG":"#,##0.00\xA0\xA4",lo:"\xA4#,##0.00;\xA4-#,##0.00",lrc:"\xA4\xA0#,##0.00","lrc-IQ":"\xA4\xA0#,##0.00",lt:"#,##0.00\xA0\xA4",lu:"#,##0.00\xA4",luo:"#,##0.00\xA4",luy:"\xA4#,##0.00;\xA4-\xA0#,##0.00",lv:"#,##0.00\xA0\xA4",mai:"\xA4\xA0#,##0.00",mas:"\xA4#,##0.00;(\xA4#,##0.00)","mas-TZ":"\xA4#,##0.00;(\xA4#,##0.00)",mer:"\xA4#,##0.00;(\xA4#,##0.00)",mfe:"\xA4\xA0#,##0.00",mg:"\xA4#,##0.00",mgh:"\xA4\xA0#,##0.00",mgo:"\xA4\xA0#,##0.00",mi:"\xA4\xA0#,##0.00",mk:"#,##0.00\xA0\xA4",ml:"\xA4#,##0.00;(\xA4#,##0.00)",mn:"\xA4\xA0#,##0.00",mni:"\xA4\xA0#,##0.00","mni-Beng":"\xA4\xA0#,##0.00",mr:"\xA4#,##0.00;(\xA4#,##0.00)",ms:"\xA4#,##0.00;(\xA4#,##0.00)","ms-BN":"\xA4#,##0.00;(\xA4#,##0.00)","ms-ID":"\xA4#,##0.00","ms-SG":"\xA4#,##0.00;(\xA4#,##0.00)",mt:"\xA4#,##0.00",mua:"\xA4#,##0.00;(\xA4#,##0.00)",my:"\xA4\xA0#,##0.00",mzn:"\xA4\xA0#,##0.00",naq:"\xA4#,##0.00",nb:"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nb-SJ":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)",nd:"\xA4#,##0.00;(\xA4#,##0.00)",nds:"\xA4\xA0#,##0.00","nds-NL":"\xA4\xA0#,##0.00",ne:"\xA4\xA0#,##,##0.00","ne-IN":"\xA4\xA0#,##,##0.00",nl:"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nl-AW":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nl-BE":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nl-BQ":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nl-CW":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nl-SR":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)","nl-SX":"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)",nmg:"#,##0.00\xA0\xA4",nn:"#,##0.00\xA0\xA4",nnh:"\xA4\xA0#,##0.00",no:"\xA4\xA0#,##0.00;(\xA4\xA0#,##0.00)",nus:"\xA4#,##0.00;(\xA4#,##0.00)",nyn:"\xA4#,##0.00",om:"\xA4#,##0.00","om-KE":"\xA4#,##0.00",or:"\xA4#,##0.00;(\xA4#,##0.00)",os:"\xA4\xA0#,##0.00","os-RU":"\xA4\xA0#,##0.00",pa:"\xA4\xA0#,##0.00","pa-Arab":"\xA4\xA0#,##0.00","pa-Guru":"\xA4\xA0#,##0.00",pcm:"\xA4#,##0.00",pl:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",ps:"\xA4#,##0.00;(\xA4#,##0.00)","ps-PK":"\xA4#,##0.00;(\xA4#,##0.00)",pt:"\xA4\xA0#,##0.00","pt-AO":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-CH":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-CV":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-GQ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-GW":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-LU":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-MO":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-MZ":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-PT":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-ST":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","pt-TL":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",qu:"\xA4\xA0#,##0.00","qu-BO":"\xA4\xA0#,##0.00","qu-EC":"\xA4\xA0#,##0.00",rm:"#,##0.00\xA0\xA4",rn:"#,##0.00\xA4",ro:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","ro-MD":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",rof:"\xA4#,##0.00",ru:"#,##0.00\xA0\xA4","ru-BY":"#,##0.00\xA0\xA4","ru-KG":"#,##0.00\xA0\xA4","ru-KZ":"#,##0.00\xA0\xA4","ru-MD":"#,##0.00\xA0\xA4","ru-UA":"#,##0.00\xA0\xA4",rw:"\xA4\xA0#,##0.00",rwk:"#,##0.00\xA4",sa:"\xA4\xA0#,##0.00",sah:"#,##0.00\xA0\xA4",saq:"\xA4#,##0.00;(\xA4#,##0.00)",sat:"\xA4\xA0#,##0.00","sat-Olck":"\xA4\xA0#,##0.00",sbp:"#,##0.00\xA4",sc:"#,##0.00\xA0\xA4",sd:"\xA4\xA0#,##0.00","sd-Arab":"\xA4\xA0#,##0.00","sd-Deva":"\xA4\xA0#,##0.00",se:"#,##0.00\xA0\xA4","se-FI":"#,##0.00\xA0\xA4","se-SE":"#,##0.00\xA0\xA4",seh:"#,##0.00\xA4",ses:"#,##0.00\xA4",sg:"\xA4#,##0.00;\xA4-#,##0.00",shi:"#,##0.00\xA4","shi-Latn":"#,##0.00\xA4","shi-Tfng":"#,##0.00\xA4",si:"\xA4#,##0.00;(\xA4#,##0.00)",sk:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",sl:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",smn:"#,##0.00\xA0\xA4",sn:"\xA4#,##0.00;(\xA4#,##0.00)",so:"\xA4#,##0.00;(\xA4#,##0.00)","so-DJ":"\xA4#,##0.00;(\xA4#,##0.00)","so-ET":"\xA4#,##0.00;(\xA4#,##0.00)","so-KE":"\xA4#,##0.00;(\xA4#,##0.00)",sq:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sq-MK":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sq-XK":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",sr:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Cyrl":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Cyrl-BA":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Cyrl-ME":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Cyrl-XK":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Latn":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Latn-BA":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Latn-ME":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)","sr-Latn-XK":"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",su:"\xA4#,##0.00","su-Latn":"\xA4#,##0.00",sv:"#,##0.00\xA0\xA4","sv-AX":"#,##0.00\xA0\xA4","sv-FI":"#,##0.00\xA0\xA4",sw:"\xA4\xA0#,##0.00","sw-CD":"\xA4\xA0#,##0.00","sw-KE":"\xA4\xA0#,##0.00","sw-UG":"\xA4\xA0#,##0.00",ta:"\xA4#,##0.00;(\xA4#,##0.00)","ta-LK":"\xA4#,##0.00;(\xA4#,##0.00)","ta-MY":"\xA4#,##0.00;(\xA4#,##0.00)","ta-SG":"\xA4#,##0.00;(\xA4#,##0.00)",te:"\xA4#,##0.00;(\xA4#,##0.00)",teo:"\xA4#,##0.00;(\xA4#,##0.00)","teo-KE":"\xA4#,##0.00;(\xA4#,##0.00)",tg:"#,##0.00\xA0\xA4",th:"\xA4#,##0.00;(\xA4#,##0.00)",ti:"\xA4#,##0.00","ti-ER":"\xA4#,##0.00",tk:"#,##0.00\xA0\xA4",to:"\xA4\xA0#,##0.00",tr:"\xA4#,##0.00;(\xA4#,##0.00)","tr-CY":"\xA4#,##0.00;(\xA4#,##0.00)",tt:"#,##0.00\xA0\xA4",twq:"#,##0.00\xA4",tzm:"#,##0.00\xA0\xA4",ug:"\xA4#,##0.00;(\xA4#,##0.00)",uk:"#,##0.00\xA0\xA4",und:"\xA4\xA0#,##0.00",ur:"\xA4#,##0.00;(\xA4#,##0.00)","ur-IN":"\xA4#,##0.00;(\xA4#,##0.00)",uz:"#,##0.00\xA0\xA4","uz-Arab":"\xA4\xA0#,##0.00","uz-Cyrl":"#,##0.00\xA0\xA4","uz-Latn":"#,##0.00\xA0\xA4",vai:"\xA4#,##0.00;(\xA4#,##0.00)","vai-Latn":"\xA4#,##0.00;(\xA4#,##0.00)","vai-Vaii":"\xA4#,##0.00;(\xA4#,##0.00)",vi:"#,##0.00\xA0\xA4",vun:"\xA4#,##0.00",wae:"\xA4\xA0#,##0.00",wo:"\xA4\xA0#,##0.00",xh:"\xA4#,##0.00",xog:"#,##0.00\xA0\xA4",yav:"#,##0.00\xA0\xA4;(#,##0.00\xA0\xA4)",yi:"\xA4\xA0#,##0.00",yo:"\xA4#,##0.00;(\xA4#,##0.00)","yo-BJ":"\xA4#,##0.00;(\xA4#,##0.00)",yrl:"\xA4\xA0#,##0.00","yrl-CO":"\xA4\xA0#,##0.00","yrl-VE":"\xA4\xA0#,##0.00",yue:"\xA4#,##0.00;(\xA4#,##0.00)","yue-Hans":"\xA4#,##0.00;(\xA4#,##0.00)","yue-Hant":"\xA4#,##0.00;(\xA4#,##0.00)",zgh:"#,##0.00\xA4",zh:"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hans":"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hans-HK":"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hans-MO":"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hans-SG":"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hant":"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hant-HK":"\xA4#,##0.00;(\xA4#,##0.00)","zh-Hant-MO":"\xA4#,##0.00;(\xA4#,##0.00)",zu:"\xA4#,##0.00;(\xA4#,##0.00)"};var KK=["standard","accounting"];var UK=/([^\s0]+)?(\s*)0*[.,]*0*(\s*)([^\s0]+)?/,Dx={},ZD=i=>{let e=Xi.locale()+"/"+JSON.stringify(i);return Dx[e]||(Dx[e]=new Intl.NumberFormat(Xi.locale(),i).format),Dx[e]},jK=i=>new Intl.NumberFormat(Xi.locale(),{style:"currency",currency:i}),JD={engine:function(){return"intl"},_formatNumberCore:function(i,e,t){return e==="exponential"?this.callBase.apply(this,arguments):ZD(this._normalizeFormatConfig(e,t,i))(i)},_normalizeFormatConfig:function(i,e,t){let n;if(i==="decimal"){let o=String(t).split(".")[1];n={minimumIntegerDigits:e.precision||void 0,useGrouping:!1,maximumFractionDigits:o&&o.length,round:t<0?"ceil":"floor"}}else n=this._getPrecisionConfig(e.precision);if(i==="percent")n.style="percent";else if(i==="currency"){let o=e.useCurrencyAccountingStyle??fe().defaultUseCurrencyAccountingStyle;n.style="currency",n.currency=e.currency||fe().defaultCurrency,n.currencySign=KK[+o]}return n},_getPrecisionConfig:function(i){let e;return i===null?e={minimumFractionDigits:0,maximumFractionDigits:20}:e={minimumFractionDigits:i||0,maximumFractionDigits:i||0},e},format:function(i,e){return typeof i!="number"?i:(e=this._normalizeFormat(e),e.currency==="default"&&(e.currency=fe().defaultCurrency),!e||typeof e!="function"&&!e.type&&!e.formatter?ZD(e)(i):this.callBase.apply(this,arguments))},_getCurrencySymbolInfo:function(i){let e=jK(i);return this._extractCurrencySymbolInfo(e.format(0))},_extractCurrencySymbolInfo:function(i){let e=UK.exec(i)||[],t=e[1]?"before":"after",n=e[1]||e[4]||"",o=e[2]||e[3]||"";return{position:t,symbol:n,delimiter:o}},getCurrencySymbol:function(i){return i||(i=fe().defaultCurrency),{symbol:this._getCurrencySymbolInfo(i).symbol}},getOpenXmlCurrencyFormat:function(i){let e=i||fe().defaultCurrency,t=this._getCurrencySymbolInfo(e).symbol,n=Xi.getValueByClosestLocale(o=>QD[o]);return XD(t,n)}};var qK=typeof Intl<"u";var eT=["currency","fixedpoint","exponential","percent","decimal"],Tx={1:"K",2:"M",3:"B",4:"T"},tT={largenumber:"auto",thousands:1,millions:2,billions:3,trillions:4},Ax=wt({engine:function(){return"base"},numericFormats:eT,defaultLargeNumberFormatPostfixes:Tx,_parseNumberFormatString:function(i){let e={};if(!i||typeof i!="string")return;let t=i.toLowerCase().split(" ");if(x(t,(n,o)=>{eT.includes(o)?e.formatType=o:o in tT&&(e.power=tT[o])}),e.power&&!e.formatType&&(e.formatType="fixedpoint"),e.formatType)return e},_calculateNumberPower:function(i,e,t,n){let o=Math.abs(i),s=0;if(o>1)for(;o&&o>=e&&(n===void 0||s<n);)s++,o/=e;else if(o>0&&o<1)for(;o<1&&(t===void 0||s>t);)s--,o*=e;return s},_getNumberByPower:function(i,e,t){let n=i;for(;e>0;)n/=t,e--;for(;e<0;)n*=t,e++;return n},_formatNumber:function(i,e,t){e.power==="auto"&&(e.power=this._calculateNumberPower(i,1e3,0,4)),e.power&&(i=this._getNumberByPower(i,e.power,1e3));let n=this.defaultLargeNumberFormatPostfixes[e.power]||"",o=this._formatNumberCore(i,e.formatType,t);return o=o.replace(/(\d|.$)(\D*)$/,"$1"+n+"$2"),o},_formatNumberExponential:function(i,e){let t=this._calculateNumberPower(i,10),n=this._getNumberByPower(i,t,10);e.precision===void 0&&(e.precision=1),n.toFixed(e.precision||0)>=10&&(t++,n/=10);let o=(t>=0?"+":"")+t.toString();return this._formatNumberCore(n,"fixedpoint",e)+"E"+o},_addZeroes:function(i,e){let t=Math.pow(10,e),n=i<0?"-":"";i=(Math.abs(i)*t>>>0)/t;let o=i.toString();for(;o.length<e;)o="0"+o;return n+o},_addGroupSeparators:function(i){let e=i.toString().split(".");return e[0].replace(/\B(?=(\d{3})+(?!\d))/g,fe().thousandsSeparator)+(e[1]?fe().decimalSeparator+e[1]:"")},_formatNumberCore:function(i,e,t){return e==="exponential"?this._formatNumberExponential(i,t):(e!=="decimal"&&t.precision!==null&&(t.precision=t.precision||0),e==="percent"&&(i*=100),t.precision!==void 0&&(e==="decimal"?i=this._addZeroes(i,t.precision):i=t.precision===null?i.toPrecision():lp(i,t.precision)),e!=="decimal"?i=this._addGroupSeparators(i):i=i.toString().replace(".",fe().decimalSeparator),e==="percent"&&(i+="%"),i)},_normalizeFormat:function(i){return i?(typeof i=="function"||q(i)||(i={type:i}),i):{}},_getSeparators:function(){return{decimalSeparator:this.getDecimalSeparator(),thousandsSeparator:this.getThousandsSeparator()}},getThousandsSeparator:function(){return this.format(1e4,"fixedPoint")[2]},getDecimalSeparator:function(){return this.format(1.2,{type:"fixedPoint",precision:1})[1]},convertDigits:function(i,e){let t=this.format(90,"decimal");if(typeof i!="string"||t[1]==="0")return i;let n=e?t[1]:"0",o=e?"0":t[1],s=e?t[0]:"9",r=new RegExp("["+n+"-"+s+"]","g");return i.replace(r,a=>String.fromCharCode(a.charCodeAt(0)+(o.charCodeAt(0)-n.charCodeAt(0))))},getNegativeEtalonRegExp:function(i){let e=this._getSeparators(),t=new RegExp("[0-9"+Pn(e.decimalSeparator+e.thousandsSeparator)+"]+","g"),n=this.format(-1,i).replace(t,"1");return["\\","(",")","[","]","*","+","$","^","?","|","{","}"].forEach(o=>{n=n.replace(new RegExp(`\\${o}`,"g"),`\\${o}`)}),n=n.replace(/ /g,"\\s"),n=n.replace(/1/g,".*"),new RegExp(n,"g")},getSign:function(i,e){if(!e)return i.replace(/[^0-9-]/g,"").charAt(0)==="-"?-1:1;let t=this.getNegativeEtalonRegExp(e);return i.match(t)?-1:1},format:function(i,e){if(typeof i!="number"||typeof e=="number")return i;if(e=e&&e.formatter||e,typeof e=="function")return e(i);e=this._normalizeFormat(e),e.type||(e.type="decimal");let t=this._parseNumberFormatString(e.type);if(!t){let n=this._getSeparators();return n.unlimitedIntegerDigits=e.unlimitedIntegerDigits,this.convertDigits(jD(e.type,n)(i))}return this._formatNumber(i,t,e)},parse:function(i,e){if(!i)return;if(e&&e.parser)return e.parser(i);i=this.convertDigits(i,!0),e&&typeof e!="string"&&he.log("W0011");let t=this.getDecimalSeparator(),n=new RegExp("[^0-9"+Pn(t)+"]","g"),o=i.replace(n,"").replace(t,".").replace(/\.$/g,"");if(o==="."||o==="")return null;if(this._calcSignificantDigits(o)>15)return NaN;let s=+o*this.getSign(i,e);e=this._normalizeFormat(e);let r=this._parseNumberFormatString(e.type),a=r?.power;if(a){if(a==="auto"){let l=i.match(/\d(K|M|B|T)/);l&&(a=Object.keys(Tx).find(d=>Tx[d]===l[1]))}s*=Math.pow(10,3*a)}return r?.formatType==="percent"&&(s/=100),s},_calcSignificantDigits:function(i){let[e,t]=i.split("."),n=s=>{let r=-1;for(let a=0;a<s.length;a++)if(s[a]!=="0"){r=a;break}return r>-1?s.length-r:0},o=0;return e&&(o+=n(e.split(""))),t&&(o+=n(t.split("").reverse())),o}});Ax.inject(YD);qK&&Ax.inject(JD);var ze=Ax;var YK=/^[\d\w.+_-]+@[\d\w._-]+\.[\w]+$/i,Yt={valid:"valid",invalid:"invalid",pending:"pending"},Ho=class{constructor(){this.NAME="base"}defaultMessage(e){return O.getFormatter(`validation-${this.NAME}`)(e)}defaultFormattedMessage(e){return O.getFormatter(`validation-${this.NAME}-formatted`)(e)}_isValueEmpty(e){return!mc.required.validate(e,{})}validate(e,t){let n=Array.isArray(e)?e:[e],o=!0;return n.length?n.every(s=>(o=this._validate(s,t),o)):o=this._validate(null,t),o}},Mx=class extends Ho{constructor(){super(),this.NAME="required"}_validate(e,t){return!f(e)||e===!1?!1:(e=String(e),(t.trim||!f(t.trim))&&(e=e.trim()),e!=="")}},Rx=class extends Ho{constructor(){super(),this.NAME="numeric"}_validate(e,t){return t.ignoreEmptyValue!==!1&&this._isValueEmpty(e)?!0:t.useCultureSettings&&B(e)?!isNaN(ze.parse(e)):xe(e)}},Fx=class extends Ho{constructor(){super(),this.NAME="range"}_validate(e,t){if(t.ignoreEmptyValue!==!1&&this._isValueEmpty(e))return!0;let n=mc.numeric.validate(e,t),o=f(e)&&e!=="",s=n?parseFloat(e):o&&e.valueOf(),{min:r}=t,{max:a}=t;if(!(n||Et(e))&&!o)return!1;if(f(r))return f(a)?s>=r&&s<=a:s>=r;if(f(a))return s<=a;throw he.Error("E0101")}},Px=class extends Ho{constructor(){super(),this.NAME="stringLength"}_validate(e,t){return e=String(e??""),(t.trim||!f(t.trim))&&(e=e.trim()),t.ignoreEmptyValue&&this._isValueEmpty(e)?!0:mc.range.validate(e.length,m({},t))}},dp=class extends Ho{constructor(){super(),this.NAME="custom"}validate(e,t){if(t.ignoreEmptyValue&&this._isValueEmpty(e))return!0;let{validator:n}=t,o=n&&A(n.option)&&n.option("dataGetter"),s=A(o)&&o(),r={value:e,validator:n,rule:t};return s&&m(r,s),t.validationCallback(r)}},kx=class extends dp{constructor(){super(),this.NAME="async"}validate(e,t){if(f(t.reevaluate)||m(t,{reevaluate:!0}),t.ignoreEmptyValue&&this._isValueEmpty(e))return!0;let{validator:n}=t,o=n&&A(n.option)&&n.option("dataGetter"),s=A(o)&&o(),r={value:e,validator:n,rule:t};s&&m(r,s);let a=t.validationCallback(r);if(!To(a))throw he.Error("E0103");return this._getWrappedPromise(ht(a).promise())}_getWrappedPromise(e){let t=y();return e.then(n=>{t.resolve(n)},n=>{let o={isValid:!1};f(n)&&(B(n)?o.message=n:$(n)&&f(n.message)&&B(n.message)&&(o.message=n.message)),t.resolve(o)}),t.promise()}},Bx=class extends Ho{constructor(){super(),this.NAME="compare"}_validate(e,t){if(!t.comparisonTarget)throw he.Error("E0102");if(t.ignoreEmptyValue&&this._isValueEmpty(e))return!0;m(t,{reevaluate:!0});let n=t.comparisonTarget();switch(t.comparisonType||"=="){case"==":return e==n;case"!=":return e!=n;case"===":return e===n;case"!==":return e!==n;case">":return e>n;case">=":return e>=n;case"<":return e<n;case"<=":return e<=n}}},Vx=class extends Ho{constructor(){super(),this.NAME="pattern"}_validate(e,t){if(t.ignoreEmptyValue!==!1&&this._isValueEmpty(e))return!0;let{pattern:n}=t;return B(n)&&(n=new RegExp(n)),n.test(e)}},Lx=class extends Ho{constructor(){super(),this.NAME="email"}_validate(e,t){return t.ignoreEmptyValue!==!1&&this._isValueEmpty(e)?!0:mc.pattern.validate(e,m({},t,{pattern:YK}))}},mc={required:new Mx,numeric:new Rx,range:new Fx,stringLength:new Px,custom:new dp,async:new kx,compare:new Bx,pattern:new Vx,email:new Lx},XK=ce.inherit({ctor(i,e){this.group=i,this.validators=[],this._isRemovable=e,this._pendingValidators=[],this._onValidatorStatusChanged=this._onValidatorStatusChanged.bind(this),this._resetValidationInfo(),this._eventsStrategy=new Ln(this)},validate(){let i={isValid:!0,brokenRules:[],validators:[],status:Yt.valid,complete:null};return this._unsubscribeFromAllChangeEvents(),this._pendingValidators=[],this._resetValidationInfo(),x(this.validators,(e,t)=>{let n=t.validate();i.isValid=i.isValid&&n.isValid,n.brokenRules&&(i.brokenRules=i.brokenRules.concat(n.brokenRules)),i.validators.push(t),n.status===Yt.pending&&this._addPendingValidator(t),this._subscribeToChangeEvents(t)}),this._pendingValidators.length?i.status=Yt.pending:(i.status=i.isValid?Yt.valid:Yt.invalid,this._unsubscribeFromAllChangeEvents(),this._raiseValidatedEvent(i)),this._updateValidationInfo(i),m({},this._validationInfo.result)},_subscribeToChangeEvents(i){i.on("validating",this._onValidatorStatusChanged),i.on("validated",this._onValidatorStatusChanged)},_unsubscribeFromChangeEvents(i){i.off("validating",this._onValidatorStatusChanged),i.off("validated",this._onValidatorStatusChanged)},_unsubscribeFromAllChangeEvents(){x(this.validators,(i,e)=>{this._unsubscribeFromChangeEvents(e)})},_updateValidationInfo(i){this._validationInfo.result=i,i.status===Yt.pending&&(this._validationInfo.deferred||(this._validationInfo.deferred=y(),this._validationInfo.result.complete=this._validationInfo.deferred.promise()))},_addPendingValidator(i){xt(this._pendingValidators,t=>t===i)[0]||this._pendingValidators.push(i)},_removePendingValidator(i){let e=this._pendingValidators.indexOf(i);e>=0&&this._pendingValidators.splice(e,1)},_orderBrokenRules(i){let e=[];return x(this.validators,(t,n)=>{let o=xt(i,s=>s.validator===n);o.length&&(e=e.concat(o))}),e},_updateBrokenRules(i){if(!this._validationInfo.result)return;let{brokenRules:e}=this._validationInfo.result,t=xt(e,n=>n.validator!==i.validator);i.brokenRules&&(e=t.concat(i.brokenRules)),this._validationInfo.result.brokenRules=this._orderBrokenRules(e)},_onValidatorStatusChanged(i){if(i.status===Yt.pending){this._addPendingValidator(i.validator);return}this._resolveIfComplete(i)},_resolveIfComplete(i){if(this._removePendingValidator(i.validator),this._updateBrokenRules(i),!this._pendingValidators.length){if(this._unsubscribeFromAllChangeEvents(),!this._validationInfo.result)return;this._validationInfo.result.status=this._validationInfo.result.brokenRules.length===0?Yt.valid:Yt.invalid,this._validationInfo.result.isValid=this._validationInfo.result.status===Yt.valid;let e=m({},this._validationInfo.result,{complete:null}),{deferred:t}=this._validationInfo;this._validationInfo.deferred=null,this._raiseValidatedEvent(e),t&&setTimeout(()=>{t.resolve(e)})}},_raiseValidatedEvent(i){this._eventsStrategy.fireEvent("validated",[i])},_resetValidationInfo(){this._validationInfo={result:null,deferred:null}},_synchronizeValidationInfo(){this._validationInfo.result&&(this._validationInfo.result.validators=this.validators)},removeRegisteredValidator(i){let e=this.validators.indexOf(i);e>-1&&(this.validators.splice(e,1),this._synchronizeValidationInfo(),this._resolveIfComplete({validator:i}))},registerValidator(i){this.validators.includes(i)||(this.validators.push(i),this._synchronizeValidationInfo())},reset(){x(this.validators,(i,e)=>{e.reset()}),this._pendingValidators=[],this._resetValidationInfo()},on(i,e){return this._eventsStrategy.on(i,e),this},off(i,e){return this._eventsStrategy.off(i,e),this}}),oa={groups:[],getGroupConfig(i){let e=xt(this.groups,t=>t.group===i);if(e.length)return e[0]},findGroup(i,e){var t;let o=((t=i.data())===null||t===void 0||(t=t.dxComponents)===null||t===void 0?void 0:t.includes("dxValidationGroup"))&&i.dxValidationGroup("instance");if(o)return o;let s=i.parents(".dx-validationgroup").first();return s.length?s.dxValidationGroup("instance"):e},initGroups(){this.groups=[],this.addGroup(void 0,!1)},addGroup(i){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,t=this.getGroupConfig(i);return t||(t=new XK(i,e),this.groups.push(t)),t},removeGroup(i){let e=this.getGroupConfig(i),t=this.groups.indexOf(e);return t>-1&&this.groups.splice(t,1),e},_setDefaultMessage(i){let{rule:e,validator:t,name:n}=i;f(e.message)||(t.defaultFormattedMessage&&f(n)?e.message=t.defaultFormattedMessage(n):e.message=t.defaultMessage())},_addBrokenRule(i){let{result:e,rule:t}=i;e.brokenRule||(e.brokenRule=t),e.brokenRules||(e.brokenRules=[]),e.brokenRules.push(t)},validate(i,e,t){var n;let o={name:t,value:i,brokenRule:null,brokenRules:null,isValid:!0,validationRules:e,pendingRules:null,status:Yt.valid,complete:null},s=e==null||(n=e[0])===null||n===void 0?void 0:n.validator,r=[];return x(e||[],(a,l)=>{let d=mc[l.type],c;if(d){if(f(l.isValid)&&l.value===i&&!l.reevaluate)return l.isValid?!0:(o.isValid=!1,this._addBrokenRule({result:o,rule:l}),!1);if(l.value=i,l.type==="async")return r.push({rule:l,ruleValidator:d}),!0;if(c=d.validate(i,l),l.isValid=c,c||(o.isValid=!1,this._setDefaultMessage({rule:l,validator:d,name:t}),this._addBrokenRule({result:o,rule:l})),!l.isValid)return!1}else throw he.Error("E0100")}),o.isValid&&!o.brokenRules&&r.length&&(o=this._validateAsyncRules({value:i,items:r,result:o,name:t})),this._synchronizeGroupValidationInfo(s,o),o.status=o.pendingRules?Yt.pending:o.isValid?Yt.valid:Yt.invalid,o},_synchronizeGroupValidationInfo(i,e){if(!i)return;let t=oa.getGroupConfig(i._validationGroup);t._updateBrokenRules.call(t,{validator:i,brokenRules:e.brokenRules??[]})},_validateAsyncRules(i){let{result:e,value:t,items:n,name:o}=i,s=[];return x(n,(r,a)=>{let l=a.ruleValidator.validate(t,a.rule);if(!To(l))this._updateRuleConfig({rule:a.rule,ruleResult:this._getPatchedRuleResult(l),validator:a.ruleValidator,name:o});else{e.pendingRules||(e.pendingRules=[]),e.pendingRules.push(a.rule);let d=l.then(c=>{let h=this._getPatchedRuleResult(c);return this._updateRuleConfig({rule:a.rule,ruleResult:h,validator:a.ruleValidator,name:o}),h});s.push(d)}}),s.length&&(e.complete=Promise.all(s).then(r=>this._getAsyncRulesResult({result:e,values:r}))),e},_updateRuleConfig(i){let{rule:e,ruleResult:t,validator:n,name:o}=i;e.isValid=t.isValid,t.isValid||(f(t.message)&&B(t.message)&&t.message.length?e.message=t.message:this._setDefaultMessage({rule:e,validator:n,name:o}))},_getPatchedRuleResult(i){let e;return $(i)?(e=m({},i),f(e.isValid)||(e.isValid=!0)):e={isValid:Qs(i)?i:!0},e},_getAsyncRulesResult(i){let{values:e,result:t}=i;return x(e,(n,o)=>{if(o.isValid===!1){t.isValid=o.isValid;let s=t.pendingRules[n];this._addBrokenRule({result:t,rule:s})}}),t.pendingRules=null,t.complete=null,t.status=t.isValid?Yt.valid:Yt.invalid,t},registerValidatorInGroup(i,e){let t=oa.addGroup(i);t.registerValidator.call(t,e)},removeRegisteredValidator(i,e){let t=oa.getGroupConfig(i);if(t){t.removeRegisteredValidator.call(t,e);let n=t.validators,o=t._isRemovable;n.length===0&&o&&this.removeGroup(i)}},initValidationOptions(i){let e={};return i&&["isValid","validationStatus","validationError","validationErrors"].forEach(n=>{n in i&&m(e,this.synchronizeValidationOptions({name:n,value:i[n]},i))}),e},synchronizeValidationOptions(i,e){let{name:t,value:n}=i;switch(t){case"validationStatus":{let o=n===Yt.valid||n===Yt.pending;return e.isValid!==o?{isValid:o}:{}}case"isValid":{let{validationStatus:o}=e,s=o;return n&&o===Yt.invalid?s=Yt.valid:!n&&o!==Yt.invalid&&(s=Yt.invalid),s!==o?{validationStatus:s}:{}}case"validationErrors":{let o=!n||!n.length?null:n[0];return e.validationError!==o?{validationError:o}:{}}case"validationError":{let{validationErrors:o}=e;if(!n&&o)return{validationErrors:null};if(n&&!o)return{validationErrors:[n]};if(n&&o&&n!==o[0])return o[0]=n,{validationErrors:o.slice()}}}return{}},validateGroup(i){let e=oa.getGroupConfig(i);if(!e)throw he.Error("E0110");return e.validate()},resetGroup(i){let e=oa.getGroupConfig(i);if(!e)throw he.Error("E0110");return e.reset()}};oa.initGroups();var yi=oa;var Xt=yi;var xc=Array.isArray;function gp(i){var e=typeof i;return e==="string"||e==="number"}function Ue(i){return i==null}function vc(i){return i===null||i===!1||i===!0||i===void 0}function bt(i){return typeof i=="function"}function bc(i){return typeof i=="string"}function QK(i){return typeof i=="number"}function ln(i){return i===null}function ZK(i){return i===void 0}function _r(i,e){var t={};if(i)for(var n in i)t[n]=i[n];if(e)for(var o in e)t[o]=e[o];return t}function Wx(i){return!ln(i)&&typeof i=="object"}var ui={},JK="$F";function Gx(i){return i.substr(2).toLowerCase()}function rT(i,e){i.appendChild(e)}function Kx(i,e,t){ln(t)?rT(i,e):i.insertBefore(e,t)}function eU(i,e){return e?document.createElementNS("http://www.w3.org/2000/svg",i):document.createElement(i)}function tU(i,e,t){i.replaceChild(e,t)}function aT(i,e){i.removeChild(e)}function lT(i){for(var e=0;e<i.length;e++)i[e]()}function iU(i,e,t){var n=i.children;return t&4?n.$LI:t&8192?i.childFlags===2?n:n[e?0:n.length-1]:n}function _n(i,e){for(var t;i;){if(t=i.flags,t&2033)return i.dom;i=iU(i,e,t)}return null}function Sc(i,e){do{var t=i.flags;if(t&2033){aT(e,i.dom);return}var n=i.children;if(t&4&&(i=n.$LI),t&8&&(i=n),t&8192)if(i.childFlags===2)i=n;else{for(var o=0,s=n.length;o<s;++o)Sc(n[o],e);return}}while(i)}function dT(i,e,t){do{var n=i.flags;if(n&2033){Kx(e,i.dom,t);return}var o=i.children;if(n&4&&(i=o.$LI),n&8&&(i=o),n&8192)if(i.childFlags===2)i=o;else{for(var s=0,r=o.length;s<r;++s)dT(o[s],e,t);return}}while(i)}function cT(i,e,t){return i.constructor.getDerivedStateFromProps?_r(t,i.constructor.getDerivedStateFromProps(e,t)):t}var yc={v:!1},xl={componentComparator:null,createVNode:null,renderComplete:null};function _c(i,e){i.textContent=e}function uT(i,e){return Wx(i)&&i.event===e.event&&i.data===e.data}function hT(i,e){for(var t in e)ZK(i[t])&&(i[t]=e[t]);return i}function Ux(i,e){return!!bt(i)&&(i(e),!0)}var Cc="$";function fp(i,e,t,n,o,s,r,a){this.childFlags=i,this.children=e,this.className=t,this.dom=null,this.flags=n,this.key=o===void 0?null:o,this.props=s===void 0?null:s,this.ref=r===void 0?null:r,this.type=a}function Ke(i,e,t,n,o,s,r,a){var l=o===void 0?1:o,d=new fp(l,n,t,i,r,s,a,e);return xl.createVNode&&xl.createVNode(d),l===0&&mT(d,d.children),d}function nU(i,e,t){if(i&4)return t;var n=(i&32768?e.render:e).defaultHooks;return Ue(n)?t:Ue(t)?n:hT(t,n)}function oU(i,e,t){var n=(i&32768?e.render:e).defaultProps;return Ue(n)?t:Ue(t)?_r(n,null):hT(t,n)}function sU(i,e){return i&12?i:e.prototype&&e.prototype.render?4:e.render?32776:8}function Ee(i,e,t,n,o){i=sU(i,e);var s=new fp(1,null,null,i,n,oU(i,e,t),nU(i,e,o),e);return xl.createVNode&&xl.createVNode(s),s}function Ec(i,e){return new fp(1,Ue(i)||i===!0||i===!1?"":i,null,16,e,null,null,null)}function Zi(i,e,t){var n=Ke(8192,8192,null,i,e,null,t,null);switch(n.childFlags){case 1:n.children=_p(),n.childFlags=2;break;case 16:n.children=[Ec(i)],n.childFlags=4;break}return n}function yt(i){var e=i.props;if(e){var t=i.flags;t&481&&(e.children!==void 0&&Ue(i.children)&&mT(i,e.children),e.className!==void 0&&(Ue(i.className)&&(i.className=e.className||null),e.className=void 0)),e.key!==void 0&&(i.key=e.key,e.key=void 0),e.ref!==void 0&&(t&8?i.ref=_r(i.ref,e.ref):i.ref=e.ref,e.ref=void 0)}return i}function rU(i){var e=i.children,t=i.childFlags;return Zi(t===2?Oi(e):e.map(Oi),t,i.key)}function Oi(i){var e=i.flags&-16385,t=i.props;if(e&14&&!ln(t)){var n=t;t={};for(var o in n)t[o]=n[o]}return(e&8192)===0?new fp(i.childFlags,i.children,i.className,e,i.key,t,i.ref,i.type):rU(i)}function _p(){return Ec("",null)}function pT(i,e,t,n){for(var o=i.length;t<o;t++){var s=i[t];if(!vc(s)){var r=n+Cc+t;if(xc(s))pT(s,e,0,r);else{if(gp(s))s=Ec(s,r);else{var a=s.key,l=bc(a)&&a[0]===Cc;(s.flags&81920||l)&&(s=Oi(s)),s.flags|=65536,l?a.substring(0,n.length)!==n&&(s.key=n+a):ln(a)?s.key=r:s.key=n+a}e.push(s)}}}}function gT(i){switch(i){case"svg":return 32;case"input":return 64;case"select":return 256;case"textarea":return 128;case JK:return 8192;default:return 1}}function mT(i,e){var t,n=1;if(vc(e))t=e;else if(gp(e))n=16,t=e;else if(xc(e)){for(var o=e.length,s=0;s<o;++s){var r=e[s];if(vc(r)||xc(r)){t=t||e.slice(0,s),pT(e,t,s,"");break}else if(gp(r))t=t||e.slice(0,s),t.push(Ec(r,Cc+s));else{var a=r.key,l=(r.flags&81920)>0,d=ln(a),c=bc(a)&&a[0]===Cc;l||d||c?(t=t||e.slice(0,s),(l||c)&&(r=Oi(r)),(d||c)&&(r.key=Cc+s),t.push(r)):t&&t.push(r),r.flags|=65536}}t=t||e,t.length===0?n=1:n=8}else t=e,t.flags|=65536,e.flags&81920&&(t=Oi(e)),n=2;return i.children=t,i.childFlags=n,i}function wc(i){return vc(i)||gp(i)?Ec(i,null):xc(i)?Zi(i,0,null):i.flags&16384?Oi(i):i}var sa="http://www.w3.org/1999/xlink",Nx="http://www.w3.org/XML/1998/namespace",iT={"xlink:actuate":sa,"xlink:arcrole":sa,"xlink:href":sa,"xlink:role":sa,"xlink:show":sa,"xlink:title":sa,"xlink:type":sa,"xml:base":Nx,"xml:lang":Nx,"xml:space":Nx};function Cp(i){return{onClick:i,onDblClick:i,onFocusIn:i,onFocusOut:i,onKeyDown:i,onKeyPress:i,onKeyUp:i,onMouseDown:i,onMouseMove:i,onMouseUp:i,onTouchEnd:i,onTouchMove:i,onTouchStart:i}}var fT=Cp(0),Hx=Cp(null),_T=Cp(!0);function nT(i,e){var t=e.$EV;return t||(t=e.$EV=Cp(null)),t[i]||++fT[i]===1&&(Hx[i]=gU(i)),t}function CT(i,e){var t=e.$EV;t&&t[i]&&(--fT[i]===0&&(document.removeEventListener(Gx(i),Hx[i]),Hx[i]=null),t[i]=null)}function aU(i,e,t,n){if(bt(t))nT(i,n)[i]=t;else if(Wx(t)){if(uT(e,t))return;nT(i,n)[i]=t}else CT(i,n)}function lU(i){return bt(i.composedPath)?i.composedPath()[0]:i.target}function xT(i,e,t,n){var o=lU(i);do{if(e&&o.disabled)return;var s=o.$EV;if(s){var r=s[t];if(r&&(n.dom=o,r.event?r.event(r.data,i):r(i),i.cancelBubble))return}o=o.parentNode}while(!ln(o))}function dU(){this.cancelBubble=!0,this.immediatePropagationStopped||this.stopImmediatePropagation()}function cU(){return this.defaultPrevented}function uU(){return this.cancelBubble}function vT(i){var e={dom:document};return i.isDefaultPrevented=cU,i.isPropagationStopped=uU,i.stopPropagation=dU,Object.defineProperty(i,"currentTarget",{configurable:!0,get:function(){return e.dom}}),e}function hU(i){return function(e){if(e.button!==0){e.stopPropagation();return}xT(e,!0,i,vT(e))}}function pU(i){return function(e){xT(e,!1,i,vT(e))}}function gU(i){var e=i==="onClick"||i==="onDblClick"?hU(i):pU(i);return document.addEventListener(Gx(i),e),e}function mU(i,e){var t=document.createElement("i");return t.innerHTML=e,t.innerHTML===i.innerHTML}function oT(i,e,t){if(i[e]){var n=i[e];n.event?n.event(n.data,t):n(t)}else{var o=e.toLowerCase();i[o]&&i[o](t)}}function Ic(i,e){var t=function(n){var o=this.$V;if(o){var s=o.props||ui,r=o.dom;if(bc(i))oT(s,i,n);else for(var a=0;a<i.length;++a)oT(s,i[a],n);if(bt(e)){var l=this.$V,d=l.props||ui;e(d,r,!1,l)}}};return Object.defineProperty(t,"wrapped",{configurable:!1,enumerable:!1,value:!0,writable:!1}),t}function ra(i,e,t){var n="$"+e,o=i[n];if(o){if(o[1].wrapped)return;i.removeEventListener(o[0],o[1]),i[n]=null}bt(t)&&(i.addEventListener(e,t),i[n]=[e,t])}function jx(i){return i==="checkbox"||i==="radio"}var fU=Ic("onInput",qx),_U=Ic(["onClick","onChange"],qx);function bT(i){i.stopPropagation()}bT.wrapped=!0;function CU(i,e){jx(e.type)?(ra(i,"change",_U),ra(i,"click",bT)):ra(i,"input",fU)}function qx(i,e){var t=i.type,n=i.value,o=i.checked,s=i.multiple,r=i.defaultValue,a=!Ue(n);t&&t!==e.type&&e.setAttribute("type",t),!Ue(s)&&s!==e.multiple&&(e.multiple=s),!Ue(r)&&!a&&(e.defaultValue=r+""),jx(t)?(a&&(e.value=n),Ue(o)||(e.checked=o)):a&&e.value!==n?(e.defaultValue=n,e.value=n):Ue(o)||(e.checked=o)}function fc(i,e){if(i.type==="option")xU(i,e);else{var t=i.children,n=i.flags;if(n&4)fc(t.$LI,e);else if(n&8)fc(t,e);else if(i.childFlags===2)fc(t,e);else if(i.childFlags&12)for(var o=0,s=t.length;o<s;++o)fc(t[o],e)}}function xU(i,e){var t=i.props||ui,n=i.dom;n.value=t.value,t.value===e||xc(e)&&e.indexOf(t.value)!==-1?n.selected=!0:(!Ue(e)||!Ue(t.selected))&&(n.selected=t.selected||!1)}var vU=Ic("onChange",yT);function bU(i){ra(i,"change",vU)}function yT(i,e,t,n){var o=!!i.multiple;!Ue(i.multiple)&&o!==e.multiple&&(e.multiple=o);var s=i.selectedIndex;s===-1&&(e.selectedIndex=-1);var r=n.childFlags;if(r!==1){var a=i.value;QK(s)&&s>-1&&e.options[s]&&(a=e.options[s].value),t&&Ue(a)&&(a=i.defaultValue),fc(n,a)}}var yU=Ic("onInput",OT),OU=Ic("onChange");function SU(i,e){ra(i,"input",yU),e.onChange&&ra(i,"change",OU)}function OT(i,e,t){var n=i.value,o=e.value;if(Ue(n)){if(t){var s=i.defaultValue;!Ue(s)&&s!==o&&(e.defaultValue=s,e.value=s)}}else o!==n&&(e.defaultValue=n,e.value=n)}function ST(i,e,t,n,o,s){i&64?qx(n,t):i&256?yT(n,t,o,e):i&128&&OT(n,t,o),s&&(t.$V=e)}function EU(i,e,t){i&64?CU(e,t):i&256?bU(e):i&128&&SU(e,t)}function ET(i){return i.type&&jx(i.type)?!Ue(i.checked):!Ue(i.value)}function at(){return{current:null}}function mp(i){i&&!Ux(i,null)&&i.current&&(i.current=null)}function vl(i,e,t){i&&(bt(i)||i.current!==void 0)&&t.push(function(){!Ux(i,e)&&i.current!==void 0&&(i.current=e)})}function xo(i,e){Es(i),Sc(i,e)}function Es(i){var e=i.flags,t=i.children,n;if(e&481){n=i.ref;var o=i.props;mp(n);var s=i.childFlags;if(!ln(o))for(var r=Object.keys(o),a=0,l=r.length;a<l;a++){var d=r[a];_T[d]&&CT(d,i.dom)}s&12?Oc(t):s===2&&Es(t)}else t&&(e&4?(bt(t.componentWillUnmount)&&t.componentWillUnmount(),mp(i.ref),t.$UN=!0,Es(t.$LI)):e&8?(n=i.ref,!Ue(n)&&bt(n.onComponentWillUnmount)&&n.onComponentWillUnmount(_n(i,!0),i.props||ui),Es(t)):e&1024?xo(t,i.ref):e&8192&&i.childFlags&12&&Oc(t))}function Oc(i){for(var e=0,t=i.length;e<t;++e)Es(i[e])}function up(i){i.textContent=""}function hp(i,e,t){Oc(t),e.flags&8192?Sc(e,i):up(i)}function wU(i){var e=i.event;return function(t){e(i.data,t)}}function IU(i,e,t,n){if(Wx(t)){if(uT(e,t))return;t=wU(t)}ra(n,Gx(i),t)}function DU(i,e,t){if(Ue(e)){t.removeAttribute("style");return}var n=t.style,o,s;if(bc(e)){n.cssText=e;return}if(!Ue(i)&&!bc(i)){for(o in e)s=e[o],s!==i[o]&&n.setProperty(o,s);for(o in i)Ue(e[o])&&n.removeProperty(o)}else for(o in e)s=e[o],n.setProperty(o,s)}function TU(i,e,t,n){var o=i&&i.__html||"",s=e&&e.__html||"";o!==s&&!Ue(s)&&!mU(n,s)&&(ln(t)||(t.childFlags&12?Oc(t.children):t.childFlags===2&&Es(t.children),t.children=null,t.childFlags=1),n.innerHTML=s)}function $x(i,e,t,n,o,s,r){switch(i){case"children":case"childrenType":case"className":case"defaultValue":case"key":case"multiple":case"ref":case"selectedIndex":break;case"autoFocus":n.autofocus=!!t;break;case"allowfullscreen":case"autoplay":case"capture":case"checked":case"controls":case"default":case"disabled":case"hidden":case"indeterminate":case"loop":case"muted":case"novalidate":case"open":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"selected":n[i]=!!t;break;case"defaultChecked":case"value":case"volume":if(s&&i==="value")break;var a=Ue(t)?"":t;n[i]!==a&&(n[i]=a);break;case"style":DU(e,t,n);break;case"dangerouslySetInnerHTML":TU(e,t,r,n);break;default:_T[i]?aU(i,e,t,n):i.charCodeAt(0)===111&&i.charCodeAt(1)===110?IU(i,e,t,n):Ue(t)?n.removeAttribute(i):o&&iT[i]?n.setAttributeNS(iT[i],i,t):n.setAttribute(i,t);break}}function Yx(i,e,t,n,o){var s=!1,r=(e&448)>0;r&&(s=ET(t),s&&EU(e,n,t));for(var a in t)$x(a,null,t[a],n,o,s,null);r&&ST(e,i,n,t,!0,s)}function wT(i,e,t){var n=wc(i.render(e,i.state,t)),o=t;return bt(i.getChildContext)&&(o=_r(t,i.getChildContext())),i.$CX=o,n}function Xx(i,e,t,n,o,s){var r=new e(t,n),a=r.$N=!!(e.getDerivedStateFromProps||r.getSnapshotBeforeUpdate);if(r.$SVG=o,r.$L=s,i.children=r,r.$BS=!1,r.context=n,r.props===ui&&(r.props=t),a)r.state=cT(r,t,r.state);else if(bt(r.componentWillMount)){r.$BR=!0,r.componentWillMount();var l=r.$PS;if(!ln(l)){var d=r.state;if(ln(d))r.state=l;else for(var c in l)d[c]=l[c];r.$PS=null}r.$BR=!1}return r.$LI=wT(r,t,n),r}function xp(i,e){var t=i.props||ui;return i.flags&32768?i.type.render(t,i.ref,e):i.type(t,e)}function hi(i,e,t,n,o,s){var r=i.flags|=16384;r&481?Qx(i,e,t,n,o,s):r&4?RU(i,e,t,n,o,s):r&8?(FU(i,e,t,n,o,s),Jx(i,s)):r&512||r&16?IT(i,e,o):r&8192?MU(i,t,e,n,o,s):r&1024&&AU(i,t,e,o,s)}function AU(i,e,t,n,o){hi(i.children,i.ref,e,!1,null,o);var s=_p();IT(s,t,n),i.dom=s.dom}function MU(i,e,t,n,o,s){var r=i.children,a=i.childFlags;a&12&&r.length===0&&(a=i.childFlags=2,r=i.children=_p()),a===2?hi(r,t,e,n,o,s):aa(r,t,e,n,o,s)}function IT(i,e,t){var n=i.dom=document.createTextNode(i.children);ln(e)||Kx(e,n,t)}function Qx(i,e,t,n,o,s){var r=i.flags,a=i.props,l=i.className,d=i.childFlags,c=i.dom=eU(i.type,n=n||(r&32)>0),h=i.children;if(!Ue(l)&&l!==""&&(n?c.setAttribute("class",l):c.className=l),d===16)_c(c,h);else if(d!==1){var p=n&&i.type!=="foreignObject";d===2?(h.flags&16384&&(i.children=h=Oi(h)),hi(h,c,t,p,null,s)):(d===8||d===4)&&aa(h,c,t,p,null,s)}ln(e)||Kx(e,c,o),ln(a)||Yx(i,r,a,c,n),vl(i.ref,c,s)}function aa(i,e,t,n,o,s){for(var r=0;r<i.length;++r){var a=i[r];a.flags&16384&&(i[r]=a=Oi(a)),hi(a,e,t,n,o,s)}}function RU(i,e,t,n,o,s){var r=Xx(i,i.type,i.props||ui,t,n,s);hi(r.$LI,e,r.$CX,n,o,s),Zx(i.ref,r,s)}function FU(i,e,t,n,o,s){hi(i.children=wc(xp(i,t)),e,t,n,o,s)}function PU(i){return function(){i.componentDidMount()}}function Zx(i,e,t){vl(i,e,t),bt(e.componentDidMount)&&t.push(PU(e))}function kU(i,e){return function(){i.onComponentDidMount(_n(e,!0),e.props||ui)}}function Jx(i,e){var t=i.ref;Ue(t)||(Ux(t.onComponentWillMount,i.props||ui),bt(t.onComponentDidMount)&&e.push(kU(t,i)))}function BU(i,e,t,n,o,s){Es(i),(e.flags&i.flags&2033)!==0?(hi(e,null,n,o,null,s),tU(t,e.dom,i.dom)):(hi(e,t,n,o,_n(i,!0),s),Sc(i,t))}function ws(i,e,t,n,o,s,r){var a=e.flags|=16384;i.flags!==a||i.type!==e.type||i.key!==e.key||a&2048?i.flags&16384?BU(i,e,t,n,o,r):hi(e,t,n,o,s,r):a&481?$U(i,e,n,o,a,r):a&4?GU(i,e,t,n,o,s,r):a&8?KU(i,e,t,n,o,s,r):a&16?UU(i,e):a&512?e.dom=i.dom:a&8192?NU(i,e,t,n,o,r):HU(i,e,n,r)}function VU(i,e,t){i!==e&&(i!==""?t.firstChild.nodeValue=e:_c(t,e))}function LU(i,e){i.textContent!==e&&(i.textContent=e)}function NU(i,e,t,n,o,s){var r=i.children,a=e.children,l=i.childFlags,d=e.childFlags,c=null;d&12&&a.length===0&&(d=e.childFlags=2,a=e.children=_p());var h=(d&2)!==0;if(l&12){var p=r.length;(l&8&&d&8||h||!h&&a.length>p)&&(c=_n(r[p-1],!1).nextSibling)}ev(l,d,r,a,t,n,o,c,i,s)}function HU(i,e,t,n){var o=i.ref,s=e.ref,r=e.children;if(ev(i.childFlags,e.childFlags,i.children,r,o,t,!1,null,i,n),e.dom=i.dom,o!==s&&!vc(r)){var a=r.dom;aT(o,a),rT(s,a)}}function $U(i,e,t,n,o,s){var r=e.dom=i.dom,a=i.props,l=e.props,d=!1,c=!1,h;if(n=n||(o&32)>0,a!==l){var p=a||ui;if(h=l||ui,h!==ui){d=(o&448)>0,d&&(c=ET(h));for(var g in h){var C=p[g],v=h[g];C!==v&&$x(g,C,v,r,n,c,i)}}if(p!==ui)for(var b in p)Ue(h[b])&&!Ue(p[b])&&$x(b,p[b],null,r,n,c,i)}var T=e.children,R=e.className;i.className!==R&&(Ue(R)?r.removeAttribute("class"):n?r.setAttribute("class",R):r.className=R),o&4096?LU(r,T):ev(i.childFlags,e.childFlags,i.children,T,r,t,n&&e.type!=="foreignObject",null,i,s),d&&ST(o,e,r,h,!1,c);var U=e.ref,Q=i.ref;Q!==U&&(mp(Q),vl(U,r,s))}function zU(i,e,t,n,o,s){Es(i),aa(e,t,n,o,_n(i,!0),s),Sc(i,t)}function ev(i,e,t,n,o,s,r,a,l,d){switch(i){case 2:switch(e){case 2:ws(t,n,o,s,r,a,d);break;case 1:xo(t,o);break;case 16:Es(t),_c(o,n);break;default:zU(t,n,o,s,r,d);break}break;case 1:switch(e){case 2:hi(n,o,s,r,a,d);break;case 1:break;case 16:_c(o,n);break;default:aa(n,o,s,r,a,d);break}break;case 16:switch(e){case 16:VU(t,n,o);break;case 2:up(o),hi(n,o,s,r,a,d);break;case 1:up(o);break;default:up(o),aa(n,o,s,r,a,d);break}break;default:switch(e){case 16:Oc(t),_c(o,n);break;case 2:hp(o,l,t),hi(n,o,s,r,a,d);break;case 1:hp(o,l,t);break;default:var c=t.length|0,h=n.length|0;c===0?h>0&&aa(n,o,s,r,a,d):h===0?hp(o,l,t):e===8&&i===8?qU(t,n,o,s,r,c,h,a,l,d):jU(t,n,o,s,r,c,h,a,d);break}break}}function WU(i,e,t,n,o){o.push(function(){i.componentDidUpdate(e,t,n)})}function DT(i,e,t,n,o,s,r,a,l){var d=i.state,c=i.props,h=!!i.$N,p=bt(i.shouldComponentUpdate);if(h&&(e=cT(i,t,e!==d?_r(d,e):e)),r||!p||p&&i.shouldComponentUpdate(t,e,o)){!h&&bt(i.componentWillUpdate)&&i.componentWillUpdate(t,e,o),i.props=t,i.state=e,i.context=o;var g=null,C=wT(i,t,o);h&&bt(i.getSnapshotBeforeUpdate)&&(g=i.getSnapshotBeforeUpdate(c,d)),ws(i.$LI,C,n,i.$CX,s,a,l),i.$LI=C,bt(i.componentDidUpdate)&&WU(i,c,d,g,l)}else i.props=t,i.state=e,i.context=o}function GU(i,e,t,n,o,s,r){var a=e.children=i.children;if(!ln(a)){a.$L=r;var l=e.props||ui,d=e.ref,c=i.ref,h=a.state;if(!a.$N){if(bt(a.componentWillReceiveProps)){if(a.$BR=!0,a.componentWillReceiveProps(l,n),a.$UN)return;a.$BR=!1}ln(a.$PS)||(h=_r(h,a.$PS),a.$PS=null)}DT(a,h,l,t,n,o,!1,s,r),c!==d&&(mp(c),vl(d,a,r))}}function KU(i,e,t,n,o,s,r){var a=!0,l=e.props||ui,d=e.ref,c=i.props,h=!Ue(d),p=i.children;if(h&&bt(d.onComponentShouldUpdate)&&(a=d.onComponentShouldUpdate(c,l)),a!==!1){h&&bt(d.onComponentWillUpdate)&&d.onComponentWillUpdate(c,l);var g=wc(xp(e,n));ws(p,g,t,n,o,s,r),e.children=g,h&&bt(d.onComponentDidUpdate)&&d.onComponentDidUpdate(c,l)}else e.children=p}function UU(i,e){var t=e.children,n=e.dom=i.dom;t!==i.children&&(n.nodeValue=t)}function jU(i,e,t,n,o,s,r,a,l){for(var d=s>r?r:s,c=0,h,p;c<d;++c)h=e[c],p=i[c],h.flags&16384&&(h=e[c]=Oi(h)),ws(p,h,t,n,o,a,l),i[c]=h;if(s<r)for(c=d;c<r;++c)h=e[c],h.flags&16384&&(h=e[c]=Oi(h)),hi(h,t,n,o,a,l);else if(s>r)for(c=d;c<s;++c)xo(i[c],t)}function qU(i,e,t,n,o,s,r,a,l,d){var c=s-1,h=r-1,p=0,g=i[p],C=e[p],v,b;e:{for(;g.key===C.key;){if(C.flags&16384&&(e[p]=C=Oi(C)),ws(g,C,t,n,o,a,d),i[p]=C,++p,p>c||p>h)break e;g=i[p],C=e[p]}for(g=i[c],C=e[h];g.key===C.key;){if(C.flags&16384&&(e[h]=C=Oi(C)),ws(g,C,t,n,o,a,d),i[c]=C,c--,h--,p>c||p>h)break e;g=i[c],C=e[h]}}if(p>c){if(p<=h)for(v=h+1,b=v<r?_n(e[v],!0):a;p<=h;)C=e[p],C.flags&16384&&(e[p]=C=Oi(C)),++p,hi(C,t,n,o,b,d)}else if(p>h)for(;p<=c;)xo(i[p++],t);else YU(i,e,n,s,r,c,h,p,t,o,a,l,d)}function YU(i,e,t,n,o,s,r,a,l,d,c,h,p){var g,C,v,b=0,T=a,R=a,U=s-a+1,Q=r-a+1,se=new Int32Array(Q+1),re=U===n,Re=!1,we=0,We=0;if(o<4||(U|Q)<32)for(b=T;b<=s;++b)if(g=i[b],We<Q){for(a=R;a<=r;a++)if(C=e[a],g.key===C.key){if(se[a-R]=b+1,re)for(re=!1;T<b;)xo(i[T++],l);we>a?Re=!0:we=a,C.flags&16384&&(e[a]=C=Oi(C)),ws(g,C,l,t,d,c,p),++We;break}!re&&a>r&&xo(g,l)}else re||xo(g,l);else{var gi={};for(b=R;b<=r;++b)gi[e[b].key]=b;for(b=T;b<=s;++b)if(g=i[b],We<Q)if(a=gi[g.key],a!==void 0){if(re)for(re=!1;b>T;)xo(i[T++],l);se[a-R]=b+1,we>a?Re=!0:we=a,C=e[a],C.flags&16384&&(e[a]=C=Oi(C)),ws(g,C,l,t,d,c,p),++We}else re||xo(g,l);else re||xo(g,l)}if(re)hp(l,h,i),aa(e,l,t,d,c,p);else if(Re){var gt=XU(se);for(a=gt.length-1,b=Q-1;b>=0;b--)se[b]===0?(we=b+R,C=e[we],C.flags&16384&&(e[we]=C=Oi(C)),v=we+1,hi(C,l,t,d,v<o?_n(e[v],!0):c,p)):a<0||b!==gt[a]?(we=b+R,C=e[we],v=we+1,dT(C,l,v<o?_n(e[v],!0):c)):a--}else if(We!==Q)for(b=Q-1;b>=0;b--)se[b]===0&&(we=b+R,C=e[we],C.flags&16384&&(e[we]=C=Oi(C)),v=we+1,hi(C,l,t,d,v<o?_n(e[v],!0):c,p))}var Ss,cp,sT=0;function XU(i){var e=0,t=0,n=0,o=0,s=0,r=0,a=0,l=i.length;for(l>sT&&(sT=l,Ss=new Int32Array(l),cp=new Int32Array(l));t<l;++t)if(e=i[t],e!==0){if(n=Ss[o],i[n]<e){cp[t]=n,Ss[++o]=t;continue}for(s=0,r=o;s<r;)a=s+r>>1,i[Ss[a]]<e?s=a+1:r=a;e<i[Ss[s]]&&(s>0&&(cp[t]=Ss[s-1]),Ss[s]=t)}s=o+1;var d=new Int32Array(s);for(r=Ss[s-1];s-- >0;)d[s]=r,r=cp[r],Ss[s]=0;return d}var QU=typeof document<"u";QU&&window.Node&&(Node.prototype.$EV=null,Node.prototype.$V=null);function ZU(i,e,t,n){var o=[],s=e.$V;yc.v=!0,Ue(s)?Ue(i)||(i.flags&16384&&(i=Oi(i)),hi(i,e,n,!1,null,o),e.$V=i,s=i):Ue(i)?(xo(s,e),e.$V=null):(i.flags&16384&&(i=Oi(i)),ws(s,i,e,n,!1,null,o),s=e.$V=i),lT(o),yc.v=!1,bt(t)&&t(),bt(xl.renderComplete)&&xl.renderComplete(s,e)}function la(i,e,t,n){t===void 0&&(t=null),n===void 0&&(n=ui),ZU(i,e,t,n)}var pp=[],JU=typeof Promise<"u"?Promise.resolve().then.bind(Promise.resolve()):function(i){window.setTimeout(i,0)},zx=!1;function TT(i,e,t,n){var o=i.$PS;if(bt(e)&&(e=e(o?_r(i.state,o):i.state,i.props,i.context)),Ue(o))i.$PS=e;else for(var s in e)o[s]=e[s];if(i.$BR)bt(t)&&i.$L.push(t.bind(i));else{if(!yc.v&&pp.length===0){AT(i,n),bt(t)&&t.call(i);return}if(pp.indexOf(i)===-1&&pp.push(i),n&&(i.$F=!0),zx||(zx=!0,JU(tv)),bt(t)){var r=i.$QU;r||(r=i.$QU=[]),r.push(t)}}}function ej(i){for(var e=i.$QU,t=0;t<e.length;++t)e[t].call(i);i.$QU=null}function tv(){var i;for(zx=!1;i=pp.shift();)if(!i.$UN){var e=i.$F;i.$F=!1,AT(i,e),i.$QU&&ej(i)}}function AT(i,e){if(e||!i.$BR){var t=i.$PS;i.$PS=null;var n=[];yc.v=!0,DT(i,_r(i.state,t),i.props,_n(i.$LI,!0).parentNode,i.context,i.$SVG,e,null,n),lT(n),yc.v=!1}else i.state=i.$PS,i.$PS=null}var da=function(e,t){this.state=null,this.$BR=!1,this.$BS=!0,this.$PS=null,this.$LI=null,this.$UN=!1,this.$CX=null,this.$QU=null,this.$N=!1,this.$L=null,this.$SVG=!1,this.$F=!1,this.props=e||ui,this.context=t||ui};da.prototype.forceUpdate=function(e){this.$UN||TT(this,{},e,!0)};da.prototype.setState=function(e,t){this.$UN||this.$BS||TT(this,e,t,!1)};da.prototype.render=function(e,t,n){return null};var $o={lockCount:0,lock(){this.lockCount++},callbacks:[],callEffects(){if(this.lockCount--,this.lockCount<0)throw new Error("Unexpected Effect Call");if(this.lockCount===0){let i=this.callbacks;this.callbacks=[],i.forEach(e=>e())}}};var iv=(i,e)=>{if(!(i instanceof Object&&e instanceof Object))return i===e;let n=Object.keys(i),o=Object.keys(e);return n.length!==o.length?!1:!n.some(r=>i[r]!==e[r])},_t=class extends da{constructor(){super(...arguments),this._pendingContext=this.context}componentWillReceiveProps(e,t){this._pendingContext=t??{}}shouldComponentUpdate(e,t){return!iv(this.props,e)||!iv(this.state,t)||!iv(this.context,this._pendingContext)}},Si=class extends _t{constructor(){super(...arguments),this._effects=[]}createEffects(){return[]}updateEffects(){}componentWillMount(){$o.lock()}componentWillUpdate(e,t,n){$o.lock()}componentDidMount(){$o.callbacks.push(()=>{this._effects=this.createEffects()}),$o.callEffects()}componentDidUpdate(){$o.callbacks.push(()=>this.updateEffects()),$o.callEffects()}destroyEffects(){this._effects.forEach(e=>e.dispose())}componentWillUnmount(){this.destroyEffects()}},Yn=class extends Si{constructor(){super(...arguments),this.vDomElement=null}vDomUpdateClasses(){let e=this.vDomElement,t=e.className.length?e.className.split(" "):[],n=t.filter(s=>e.dxClasses.previous.indexOf(s)<0),o=e.dxClasses.previous.filter(s=>t.indexOf(s)<0);n.forEach(s=>{let r=e.dxClasses.removed.indexOf(s);r>-1?e.dxClasses.removed.splice(r,1):e.dxClasses.added.includes(s)||e.dxClasses.added.push(s)}),o.forEach(s=>{let r=e.dxClasses.added.indexOf(s);r>-1?e.dxClasses.added.splice(r,1):e.dxClasses.removed.includes(s)||e.dxClasses.removed.push(s)})}componentDidMount(){let e=_n(this.$LI,!0);this.vDomElement=e,super.componentDidMount(),e.dxClasses=e.dxClasses||{removed:[],added:[],previous:[]},e.dxClasses.previous=e?.className.length?e.className.split(" "):[]}componentDidUpdate(){super.componentDidUpdate();let e=this.vDomElement;e!==null&&(e.dxClasses.added.forEach(t=>e.classList.add(t)),e.dxClasses.removed.forEach(t=>e.classList.remove(t)),e.dxClasses.previous=e.className.length?e.className.split(" "):[])}shouldComponentUpdate(e,t){let n=super.shouldComponentUpdate(e,t);return n&&this.vDomUpdateClasses(),n}};var tj=0,vp=function(i){let e=tj++;return{id:e,defaultValue:i,Provider:class extends da{getChildContext(){return Object.assign(Object.assign({},this.context),{[e]:this.props.value||i})}render(){return this.props.children}}}};var Le=class{constructor(e,t){this.dependency=t,this.effect=e,this.destroy=e()}update(e){let t=this.dependency;e&&(this.dependency=e),(!e||e.some((n,o)=>t[o]!==n))&&(this.dispose(),this.destroy=this.effect())}dispose(){this.destroy&&this.destroy()}};var zo=()=>new Le(()=>{tv()},[]);var ij="a runtime error occured! Use Inferno in development environment to find the error.";function MT(i){return i==null}function RT(i){return i===null||i===!1||i===!0||i===void 0}function FT(i){return typeof i=="function"}function ca(i){return i===null}function PT(i){throw i||(i=ij),new Error(`Inferno Error: ${i}`)}function nj(i,e){let t=document.createElement("i");return t.innerHTML=e,t.innerHTML===i.innerHTML}function oj(i){let e,t;for(;i;){if(e=i.flags,e&2033)return i.dom;t=i.children,e&8192?i=i.childFlags===2?t:t[t.length-1]:e&4?i=t.$LI:i=t}return null}function sj(i,e){return!!(e&&e.dangerouslySetInnerHTML&&e.dangerouslySetInnerHTML.__html&&nj(i,e.dangerouslySetInnerHTML.__html))}function rj(i,e,t,n,o,s,r){let a=i.type,l=i.ref,d=i.props||ui,c;if(s){let h=Xx(i,a,d,n,o,r),p=h.$LI;c=Dc(p,e,t,h.$CX,o,r),Zx(l,h,r)}else{let h=wc(xp(i,n));c=Dc(h,e,t,n,o,r),i.children=h,Jx(i,r)}return c}function kT(i,e,t,n,o,s){let r=i.childFlags,a=i.children,l=i.props,d=i.flags;if(r!==1){if(r===2)ca(t)?hi(a,e,n,o,null,s):(t=Dc(a,e,t,n,o,s),t=t?t.nextSibling:null);else if(r===16)ca(t)?e.appendChild(document.createTextNode(a)):e.childNodes.length!==1||t.nodeType!==3?e.textContent=a:t.nodeValue!==a&&(t.nodeValue=a),t=null;else if(r&12){let c=!1;for(let h=0,p=a.length;h<p;++h){let g=a[h];ca(t)||c&&(g.flags&16)>0?hi(g,e,n,o,t,s):(t=Dc(g,e,t,n,o,s),t=t?t.nextSibling:null),c=(g.flags&16)>0}}if((d&8192)===0){let c=null;for(;t;)c=t.nextSibling,e.removeChild(t),t=c}}else!ca(e.firstChild)&&!sj(e,l)&&(e.textContent="",d&448&&(e.defaultValue=""))}function aj(i,e,t,n,o,s){let r=i.props,a=i.className,l=i.flags,d=i.ref;return o=o||(l&32)>0,t.nodeType!==1?(Qx(i,null,n,o,null,s),e.replaceChild(i.dom,t)):(i.dom=t,kT(i,t,t.firstChild,n,o,s),ca(r)||Yx(i,l,r,t,o),MT(a)?t.className!==""&&t.removeAttribute("class"):o?t.setAttribute("class",a):t.className=a,vl(d,t,s)),i.dom}function BT(i,e,t){if(t.nodeType!==3)e.replaceChild(i.dom=document.createTextNode(i.children),t);else{let n=i.children;t.nodeValue!==n&&(t.nodeValue=n),i.dom=t}return i.dom}function lj(i,e,t,n,o,s){let r=i.children;return i.childFlags===2?(BT(r,e,t),r.dom):(kT(i,e,t,n,o,s),oj(r[r.length-1]))}function Dc(i,e,t,n,o,s){let r=i.flags|=16384;return r&14?rj(i,e,t,n,o,(r&4)>0,s):r&481?aj(i,e,t,n,o,s):r&16?BT(i,e,t):r&512?i.dom=t:r&8192?lj(i,e,t,n,o,s):(PT(),null)}function VT(i,e,t){let n=e.firstChild;if(ca(n))la(i,e,t);else{let o=[];for(RT(i)||(n=Dc(i,e,n,{},!1,o));n&&(n=n.nextSibling);)e.removeChild(n);if(o.length>0){let s;for(;(s=o.shift())!==void 0;)s()}}e.$V=i,FT(t)&&t()}function LT(i){return i==null}function dj(i){return typeof i=="string"}function NT(i){return i===void 0}var cj={onComponentDidMount:1,onComponentDidUpdate:1,onComponentShouldUpdate:1,onComponentWillMount:1,onComponentWillUnmount:1,onComponentWillUpdate:1};function bl(i,e,t){var n=arguments,o,s=null,r=null,a=null,l=0,d,c=arguments.length-2;if(c===1)o=t;else if(c>1)for(o=[];c-- >0;)o[c]=n[c+2];if(dj(i)){if(l=gT(i),!LT(e)){d={};for(var h in e)h==="className"||h==="class"?a=e[h]:h==="key"?r=e.key:h==="children"&&NT(o)?o=e.children:h==="ref"?s=e.ref:(h==="contenteditable"&&(l|=4096),d[h]=e[h])}}else{if(l=2,NT(o)||(e||(e={}),e.children=o),!LT(e)){d={};for(var p in e)p==="key"?r=e.key:p==="ref"?s=e.ref:cj[p]===1?(s||(s={}),s[p]=e[p]):d[p]=e[p]}return Ee(l,i,d,r,s)}return l&8192?Zi(c===1?[o]:o,0,r):Ke(l,i,a,o,0,d,r,s)}var uj=i=>{var e,t;return((e=i.container)===null||e===void 0?void 0:e.get(0))||((t=i.item)===null||t===void 0?void 0:t.get(0))};function HT(i,e,t){setTimeout(()=>{la(bl(i,e),uj(e))},0)}var $T=(i,e,t)=>{let n=e[i];return!!n&&typeof n!="string"};var hj=new Set(["animationIterationCount","borderImageOutset","borderImageSlice","border-imageWidth","boxFlex","boxFlexGroup","boxOrdinalGroup","columnCount","fillOpacity","flex","flexGrow","flexNegative","flexOrder","flexPositive","flexShrink","floodOpacity","fontWeight","gridColumn","gridRow","lineClamp","lineHeight","opacity","order","orphans","stopOpacity","strokeDasharray","strokeDashoffset","strokeMiterlimit","strokeOpacity","strokeWidth","tabSize","widows","zIndex","zoom"]),pj=i=>typeof i=="number"?!0:!Number.isNaN(Number(i)),gj=(i,e)=>hj.has(i)?e:`${e}px`,mj=/[A-Z]/g,fj=i=>i.replace(mj,"-$&").toLowerCase();function yl(i){if(i instanceof Object)return Object.entries(i).reduce((e,[t,n])=>(e[fj(t)]=pj(n)?gj(t,n):n,e),{})}var zT=i=>{let{parentNode:e}=i;if(e){let t=i.nextSibling;nr(i),e.$V=i.$V,la(null,e),e.insertBefore(i,t),i.innerHTML="",delete e.$V}delete i.$V},ua=wt({createElement:(i,e)=>bl(i,e),remove:zT,onAfterRender:()=>{$o.callEffects()},onPreRender:()=>{$o.lock()},render:(i,e,t,n)=>{if(n)la(bl(i,e),t);else{let{parentNode:o}=t,s=t?.nextSibling,r=w.createElement("div");r.appendChild(t);let a=w.createDocumentFragment().appendChild(r);!!t.$V&&zT(t),VT(bl(i,e),a),t.$V=a.$V,o&&o.insertBefore(t,s)}}});var WT=(i,e)=>Object.keys(i).length!==Object.keys(e).length?!1:Object.keys(i).every(t=>i[t]===e[t]);var _j=["isEqual"];function Cj(i){return!!i.toArray}function GT(i,e){let t={template:e,model:I({},i)},n=i.data??{},{isEqual:o}=n,s=ge(n,_j);return o&&(t.model.data=s,t.isEqual=o),t}function xj(i,e){let{data:t,index:n}=i.model??{data:{}};t&&Object.keys(t).forEach(s=>{t[s]&&w.isNode(t[s])&&(t[s]=N(u(t[s])))});let o=i.template.render(I({container:e,transclude:i.transclude},{renovated:i.renovated},i.transclude?{}:{model:t},!i.transclude&&Number.isFinite(n)?{index:n}:{}));return o===void 0?[]:Cj(o)?o.toArray():[u(o).get(0)]}function vj(i,e){e.forEach(t=>{!!!i.find(o=>t===o)&&t.parentNode&&u(t).remove()})}var Tc=class extends Si{constructor(e){super(e),this.renderTemplate=this.renderTemplate.bind(this)}renderTemplate(){let e=_n(this.$LI,!0);if(!(e!=null&&e.parentNode))return()=>{};let t=e.parentNode,n=u(t),o=n.contents().toArray(),s=xj(this.props,N(n));return I0(u(e),u(s)),()=>{let r=u(t).contents().toArray();vj(o,r),t.appendChild(e)}}shouldComponentUpdate(e){let{model:t,template:n}=this.props,{isEqual:o,model:s,template:r}=e,a=o??WT;if(n!==r)return!0;if(!f(t)||!f(s))return t!==s;let{data:l,index:d}=t,{data:c,index:h}=s;return d!==h?!0:!a(l,c)}createEffects(){return[new Le(this.renderTemplate,[this.props.template,this.props.model])]}updateEffects(){this._effects[0].update([this.props.template,this.props.model])}componentWillUnmount(){}render(){return null}};function nv(i){return Array.isArray(i)?[...i]:I({},i)}function KT(i,e,t){let n=t.length>0&&e&&i!==e?nv(e):nv(i),o=t[0];return t.length>1?n[o]=KT(i[o],e?.[o],t.slice(1)):o&&(q(i[o])?n[o]=nv(i[o]):n[o]=i[o]),n}function UT(i,e,t,n){let o=e[t],s=i[t],r=i;q(o)||t!==n&&Array.isArray(o)?r[t]=KT(o,s,Fn(n).slice(1)):r[t]=o}var ov=(i,e)=>t=>{Object.prototype.hasOwnProperty.call(i,t)&&i[t]===void 0&&(i[t]=e(t))},jT=(()=>{class i extends Qi{get _propsInfo(){return{allowNull:[],twoWay:[],elements:[],templates:[],props:[]}}constructor(t,n){super(t,n),this._shouldRaiseContentReady=!1,this.validateKeyDownHandler()}validateKeyDownHandler(){let n=this.getSupportedKeyNames().length>0,o=typeof this._viewComponent.prototype.keyDown=="function";if(n&&!o)throw Error("Component's declaration must have 'keyDown' method.")}get viewRef(){var t;return(t=this._viewRef)===null||t===void 0?void 0:t.current}_checkContentReadyOption(t){let n=this._getContentReadyOptions().reduce((o,s)=>(o[s]=!0,o),{});return this._checkContentReadyOption=o=>!!n[o],this._checkContentReadyOption(t)}_getContentReadyOptions(){return["rtlEnabled"]}_fireContentReady(){this._actionsMap.onContentReady({})}_getDefaultOptions(){let t=this._getViewComponentDefaultProps();return m(!0,super._getDefaultOptions(),t,this._propsInfo.twoWay.reduce((n,o)=>{let[s,r,a]=o;return I({},n,{[s]:t[r],[a]:l=>this.option(s,l)})},{}),this._propsInfo.templates.reduce((n,o)=>I({},n,{[o]:null}),{}))}_getUnwrappedOption(){let t={};return Object.keys(this.option()).forEach(n=>{t[n]=this.option(n)}),t}_initializeComponent(){var t;super._initializeComponent(),(t=this._templateManager)===null||t===void 0||t.addDefaultTemplates(this.getDefaultTemplates());let n=this._getUnwrappedOption();this._props=this._optionsWithDefaultTemplates(n),this._propsInfo.templates.forEach(o=>{this._componentTemplates[o]=this._createTemplateComponent(this._props[o])}),Object.keys(this._getActionConfigsFull()).forEach(o=>this._addAction(o)),this._viewRef=at(),this.defaultKeyHandlers=this._createDefaultKeyHandlers()}_initMarkup(){let t=this.getProps();this._renderWrapper(t)}_renderWrapper(t){let n=this.$element()[0];this._isNodeReplaced||ua.onPreRender(),ua.render(this._viewComponent,t,n,this._isNodeReplaced),this._isNodeReplaced||(this._isNodeReplaced=!0,ua.onAfterRender(),this._shouldRaiseContentReady=!0),this._shouldRaiseContentReady&&(this._fireContentReady(),this._shouldRaiseContentReady=!1)}_silent(t,n){this._options.silent(t,n)}_render(){}_removeWidget(){ua.remove(this.$element()[0])}_dispose(){this._removeWidget(),super._dispose()}get elementAttr(){let t=this.$element()[0];if(!this._elementAttr){let{attributes:s}=t,r=Array.from(s).filter(a=>{var l;return!this._propsInfo.templates.includes(a.name)&&((l=s[a.name])===null||l===void 0?void 0:l.specified)}).reduce((a,l)=>{let{name:d,value:c}=l,h=a,p=d in t;return h[d]=c===""&&p?t[d]:c,h},{});this._elementAttr=r,this._storedClasses=t.getAttribute("class")||""}let n=t.style,o={};for(let s=0;s<n.length;s+=1)o[n[s]]=n.getPropertyValue(n[s]);return this._elementAttr.style=o,this._elementAttr.class=this._storedClasses,this._elementAttr}_getAdditionalActionConfigs(){return{onContentReady:{excludeValidators:["disabled","readOnly"]}}}_getAdditionalProps(){return[]}_patchOptionValues(t){let{allowNull:n,elements:o,props:s,twoWay:r}=this._propsInfo,a=this._getViewComponentDefaultProps(),l=Object.keys(a),d=this._getDefaultOptions(),{children:c,onKeyboardHandled:h,ref:p}=t,C={ref:p,children:c,onKeyDown:h?(v,b)=>{h(b)}:void 0};return[...s,...this._getAdditionalProps()].forEach(v=>{Object.prototype.hasOwnProperty.call(t,v)&&(C[v]=t[v])}),n.forEach(ov(C,()=>null)),l.forEach(ov(C,v=>d[v])),r.forEach(v=>{let[b,T]=v;ov(C,()=>d[T])(b)}),o.forEach(v=>{if(v in C){let b=C[v];$t(b)&&(C[v]=this._patchElementParam(b))}}),C}getSupportedKeyNames(){return[]}prepareStyleProp(t){return typeof t.style=="string"?I({},t,{style:{},cssText:t.style}):t}getProps(){let{elementAttr:t}=this.option(),n=this._patchOptionValues(I({},this._props,{ref:this._viewRef,children:this._extractDefaultSlot(),aria:this._aria}));return this._propsInfo.templates.forEach(o=>{n[o]=this._componentTemplates[o]}),this.prepareStyleProp(I({},n,this.elementAttr,t,{className:[...(this.elementAttr.class??"").split(" "),...(t?.class??"").split(" ")].filter((o,s,r)=>o&&r.indexOf(o)===s).join(" ").trim(),class:""},this._actionsMap))}_getActionConfigs(){return{}}_getActionConfigsFull(){return I({},this._getActionConfigs(),this._getAdditionalActionConfigs())}getDefaultTemplates(){let t=Object.values(this._templatesInfo),n={};return t.forEach(o=>{n[o]="dx-renovation-template-mock"}),n}get _templatesInfo(){return{}}_optionsWithDefaultTemplates(t){let n=Object.entries(this._templatesInfo).reduce((o,s)=>{let[r,a]=s;return I({},o,{[r]:t[r]??a})},{});return I({},t,n)}_init(){super._init(),this.customKeyHandlers={},this._actionsMap={},this._aria={},this._componentTemplates={}}_createDefaultKeyHandlers(){let t={};return this.getSupportedKeyNames().forEach(o=>{t[o]=s=>this.viewRef.keyDown(Qh.createKeyDownOptions(s))}),t}_addAction(t,n){let o=n;if(!o){let s=this._createActionByOption(t,this._getActionConfigsFull()[t]);o=r=>(Object.keys(r).forEach(a=>{f(r[a])&&w.isNode(r[a])&&(r[a]=N(u(r[a])))}),s(r))}this._actionsMap[t]=o}_optionChanged(t){let{fullName:n,name:o,previousValue:s,value:r}=t;UT(this._props,this.option(),o,n),this._propsInfo.templates.includes(o)&&r!==s&&(this._componentTemplates[o]=this._createTemplateComponent(r)),o&&this._getActionConfigsFull()[o]&&this._addAction(o),this._shouldRaiseContentReady=this._shouldRaiseContentReady||this._checkContentReadyOption(n),super._optionChanged(t),this._invalidate()}_extractDefaultSlot(){return this.option("_hasAnonymousTemplateContent")?ua.createElement(Tc,{template:this._getTemplate(this._templateManager.anonymousTemplateName),transclude:!0,renovated:!0}):null}_createTemplateComponent(t){if(!t)return;let n=this._getTemplate(t);if(!(B(n)&&n==="dx-renovation-template-mock"))return o=>ua.createElement(Tc,GT(o,n))}_wrapKeyDownHandler(t){return n=>{let{keyName:o,originalEvent:s,which:r}=n,a=this.customKeyHandlers,l=a[o]||a[r];return l!==void 0&&!l.bind(this)(s,n)?(s.cancel=!0,s):t?.(s,n)}}_toPublicElement(t){return N(u(t))}_patchElementParam(t){try{let n=u(t),o=n?.get(0);return o!=null&&o.nodeType?o:t}catch{return t}}repaint(){this._isNodeReplaced=!1,this._shouldRaiseContentReady=!0,this._removeWidget(),this._refresh()}_supportedKeys(){return I({},this.defaultKeyHandlers,this.customKeyHandlers)}registerKeyHandler(t,n){this.customKeyHandlers[t]=n}setAria(t,n){this._aria[t]=n,this._initMarkup()}_getViewComponentDefaultProps(){return this._viewComponent.defaultProps||{}}}return i.IS_RENOVATED_WIDGET=!1,i})(),Ol=jT;jT.IS_RENOVATED_WIDGET=!0;var bp=class extends Ol{get _validationGroupConfig(){return Xt.getGroupConfig(this._findGroup())}getDefaultTemplateNames(){return["content"]}getSupportedKeyNames(){return["space","enter"]}getProps(){let e=super.getProps();return e.onClick=n=>{let{event:o}=n;this._clickAction({event:o,validationGroup:this._validationGroupConfig})},ms(e.icon)==="svg"&&(e.iconTemplate=this._createTemplateComponent(()=>e.icon)),e}get _templatesInfo(){return{template:"content"}}_toggleActiveState(e,t){let n=this.viewRef;t?n.activate():n.deactivate()}_getSubmitAction(){let e=!0,t="valid";return this._createAction(n=>{let{event:o,submitInput:s}=n;if(e){let r=this._validationGroupConfig;if(r!==void 0&&r!==""){let a=r.validate();t=a.status,a.status==="pending"&&(e=!1,this.option("disabled",!0),a.complete.then(l=>{let{status:d}=l;this.option("disabled",!1),t=d,t==="valid"&&s.click(),e=!0}))}}t!=="valid"&&o.preventDefault(),o.stopPropagation()})}_initializeComponent(){super._initializeComponent(),this._addAction("onSubmit",this._getSubmitAction()),this._clickAction=this._createClickAction()}_initMarkup(){super._initMarkup();let e=this.$element().find(".dx-button-content").first(),t=e.children().filter(".dx-template-wrapper"),n=e.children().filter(".dx-button-submit-input");t.length&&(t.addClass("dx-button-content"),t.append(n),e.replaceWith(t))}_patchOptionValues(e){return super._patchOptionValues(I({},e,{templateData:e._templateData}))}_findGroup(){let e=this.$element(),t=this.option("validationGroup");return t!==void 0&&t!==""?t:Xt.findGroup(e,this._modelByElement(e))}_createClickAction(){return this._createActionByOption("onClick",{excludeValidators:["readOnly"]})}_optionChanged(e){e.name==="onClick"&&(this._clickAction=this._createClickAction()),super._optionChanged(e)}};function ti(i){return Object.keys(i).filter(e=>i[e]).join(" ")}var bj=["iconTemplate","position","source"],yj=i=>{let{iconClassName:e,props:{iconTemplate:t,source:n},sourceType:o}=i;return Zi([o==="dxIcon"&&Ke(1,"i",e),o==="fontIcon"&&Ke(1,"i",e),o==="image"&&Ke(1,"img",e,null,1,{alt:"",src:n}),t&&Ke(1,"i",e,t({}),0)],0)},Oj={position:"left",source:""},Sj=i=>i&&(i.defaultProps?e=>yt(Ee(2,i,I({},e))):i),qT=(()=>{class i extends _t{constructor(t){super(t),this.state={}}get sourceType(){return ms(this.props.source)}get cssClass(){return this.props.position!=="left"?"dx-icon-right":""}get iconClassName(){let t={"dx-icon":!0,[this.cssClass]:!!this.cssClass},{source:n}=this.props;return this.sourceType==="dxIcon"?ti(I({},t,{[`dx-icon-${n}`]:!0})):this.sourceType==="fontIcon"?ti(I({},t,{[String(n)]:!!n})):this.sourceType==="image"?ti(t):this.sourceType==="svg"?ti(I({},t,{"dx-svg-icon":!0})):""}get restAttributes(){let t=this.props;return ge(t,bj)}render(){let t=this.props;return yj({props:I({},t,{iconTemplate:Sj(t.iconTemplate)}),sourceType:this.sourceType,cssClass:this.cssClass,iconClassName:this.iconClassName,restAttributes:this.restAttributes})}}return i.defaultProps=Oj,i})();var YT="dx-inkripple-showing",XT="dx-inkripple-hiding";var sv=function(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{useHoldAnimation:e,waveSizeCoefficient:t,isCentered:n,wavesNumber:o}=i;return{waveSizeCoefficient:t||2,isCentered:n||!1,wavesNumber:o||1,durations:Dj(e??!0)}},Sl=function(i){let e=sv(i);return{showWave:rv.bind(this,e),hideWave:av.bind(this,e)}},Ej=function(i){let e=i.children(".dx-inkripple");return e.length===0&&(e=u("<div>").addClass("dx-inkripple").appendTo(i)),e},QT=function(i,e){let t=Ej(u(i)),n=t.children(".dx-inkripple-wave").toArray();for(let o=n.length;o<e;o++){let s=u("<div>").appendTo(t).addClass("dx-inkripple-wave");n.push(s[0])}return u(n)},wj=function(i,e){let t=u(e.element),n=ie(t),o=X(t),s=parseInt(Math.sqrt(n*n+o*o)),r=Math.min(4e3,parseInt(s*i.waveSizeCoefficient)),a,l;if(i.isCentered)a=(n-r)/2,l=(o-r)/2;else{let d=e.event,c=t.offset(),h=d.pageX-c.left,p=d.pageY-c.top;a=h-r/2,l=p-r/2}return{left:a,top:l,height:r,width:r}};function rv(i,e){let t=QT(e.element,i.wavesNumber).eq(e.wave||0);i.hidingTimeout&&clearTimeout(i.hidingTimeout),ZT(t),t.css(wj(i,e)),i.showingTimeout=setTimeout(Ij.bind(this,i,t),0)}function Ij(i,e){let t=i.durations.showingScale+"ms";e.addClass(YT).css("transitionDuration",t)}function Dj(i){return{showingScale:i?1e3:300,hidingScale:300,hidingOpacity:300}}function ZT(i){i.removeClass(XT).css("transitionDuration","")}function av(i,e){i.showingTimeout&&clearTimeout(i.showingTimeout);let t=QT(e.element,e.wavesNumber).eq(e.wave||0),n=i.durations,o=n.hidingScale+"ms, "+n.hidingOpacity+"ms";t.addClass(XT).removeClass(YT).css("transitionDuration",o);let s=Math.max(n.hidingScale,n.hidingOpacity);i.hidingTimeout=setTimeout(ZT.bind(this,t),s)}var Tj=["config"],Aj=i=>yt(Ke(1,"div","dx-inkripple",null,1,I({},i.restAttributes))),Mj={config:Object.freeze({})},JT=(()=>{class i extends _t{constructor(t){super(t),this.state={},this.__getterCache={},this.hideWave=this.hideWave.bind(this),this.showWave=this.showWave.bind(this)}get getConfig(){return this.__getterCache.getConfig!==void 0?this.__getterCache.getConfig:this.__getterCache.getConfig=(()=>{let{config:t}=this.props;return sv(t)})()}get restAttributes(){let t=this.props;return ge(t,Tj)}hideWave(t){av(this.getConfig,t)}showWave(t){rv(this.getConfig,t)}componentWillUpdate(t,n,o){this.props.config!==t.config&&(this.__getterCache.getConfig=void 0)}render(){let t=this.props;return Aj({props:I({},t),getConfig:this.getConfig,restAttributes:this.restAttributes})}}return i.defaultProps=Mj,i})();var Rj=zt.add,eA=Math.abs;var yp=10;var Fj=function(){return lo("pointer-events")},Pj=Ki(function(){let i=F.real().deviceType==="desktop";if(!Fj()||!i)return S;let e=u("<div>").addClass("dx-gesture-cover").css("pointerEvents","none");return _.subscribeGlobal(e,"dxmousewheel",function(t){t.preventDefault()}),Rj(function(){e.appendTo("body")}),function(t,n){e.css("pointerEvents",t?"all":"none"),t&&e.css("cursor",n)}}),kj=function(i,e){Pj()(i,e)},lv=lr.inherit({gesture:!0,configure:function(i){this.getElement().css("msTouchAction",i.immediate?"pinch-zoom":""),this.callBase(i)},allowInterruptionByMouseWheel:function(){return this._stage!==2},getDirection:function(){return this.direction},_cancel:function(){this.callBase.apply(this,arguments),this._toggleGestureCover(!1),this._stage=0},start:function(i){if(i._needSkipEvent||Eh(i)){this._cancel(i);return}this._startEvent=uo(i),this._startEventData=Ye(i),this._stage=1,this._init(i),this._setupImmediateTimer()},_setupImmediateTimer:function(){if(clearTimeout(this._immediateTimer),this._immediateAccepted=!1,!!this.immediate){if(this.immediateTimeout===0){this._immediateAccepted=!0;return}this._immediateTimer=setTimeout(function(){this._immediateAccepted=!0}.bind(this),this.immediateTimeout??180)}},move:function(i){if(this._stage===1&&this._directionConfirmed(i)){if(this._stage=2,this._resetActiveElement(),this._toggleGestureCover(!0),this._clearSelection(i),this._adjustStartEvent(i),this._start(this._startEvent),this._stage===0)return;this._requestAccept(i),this._move(i),this._forgetAccept()}else this._stage===2&&(this._clearSelection(i),this._move(i))},_directionConfirmed:function(i){let e=this._getTouchBoundary(i),t=Vo(this._startEventData,Ye(i)),n=eA(t.x),o=eA(t.y),s=this._validateMove(e,n,o),r=this._validateMove(e,o,n),a=this.getDirection(i);return a==="both"&&(s||r)||a==="horizontal"&&s||a==="vertical"&&r||this._immediateAccepted},_validateMove:function(i,e,t){return e&&e>=i&&(this.immediate?e>=t:!0)},_getTouchBoundary:function(i){return this.immediate||Ut(i)?0:yp},_adjustStartEvent:function(i){let e=this._getTouchBoundary(i),t=Vo(this._startEventData,Ye(i));this._startEvent.pageX+=Co(t.x)*e,this._startEvent.pageY+=Co(t.y)*e},_resetActiveElement:function(){F.real().platform==="ios"&&this.getElement().find(":focus").length&&zn()},_toggleGestureCover:function(i){this._toggleGestureCoverImpl(i)},_toggleGestureCoverImpl:function(i){this._stage===2&&kj(i,this.getElement().css("cursor"))},_clearSelection:function(i){Ut(i)||gs(i)||S0()},end:function(i){this._toggleGestureCover(!1),this._stage===2?this._end(i):this._stage===1&&this._stop(i),this._stage=0},dispose:function(){clearTimeout(this._immediateTimer),this.callBase.apply(this,arguments),this._toggleGestureCover(!1)},_init:S,_start:S,_move:S,_stop:S,_end:S});lv.initialTouchBoundary=yp;lv.touchBoundary=function(i){if(f(i)){yp=i;return}return yp};var El=lv;var Bj=ce.abstract,Vj=F.real();var iA=ce.inherit(function(){let i=D("scroll","dxScrollEmitter");return{ctor:function(e){this._element=e,this._locked=!1,this._proxiedScroll=t=>{this._disposed||this._scroll(t)},_.on(this._element,i,this._proxiedScroll)},_scroll:Bj,check:function(e,t){this._locked&&t()},dispose:function(){this._disposed=!0,_.off(this._element,i,this._proxiedScroll)}}}()),nA=iA.inherit({ctor:function(i,e){this.callBase(i),this._timeout=e},_scroll:function(){this._prepare(),this._forget()},_prepare:function(){this._timer&&this._clearTimer(),this._locked=!0},_clearTimer:function(){clearTimeout(this._timer),this._locked=!1,this._timer=null},_forget:function(){let i=this;this._timer=setTimeout(function(){i._clearTimer()},this._timeout)},dispose:function(){this.callBase(),this._clearTimer()}}),tA=nA.inherit({ctor:function(i){this.callBase(i,400),this._lastWheelDirection=null},check:function(i,e){this._checkDirectionChanged(i),this.callBase(i,e)},_checkDirectionChanged:function(i){if(!Ut(i)){this._lastWheelDirection=null;return}let e=i.shiftKey||!1,t=this._lastWheelDirection!==null&&e!==this._lastWheelDirection;this._lastWheelDirection=e,this._locked=this._locked&&!t}}),dv=nA.inherit({ctor:function(i){this.callBase(i,400)}});(function(){let{ios:i,android:e}=Vj;(i||e)&&(dv=iA.inherit({_scroll:function(){this._locked=!0;let t=this;On(this._scrollFrame),this._scrollFrame=rr(function(){t._locked=!1})},check:function(t,n){On(this._scrollFrame),On(this._checkFrame);let o=this,s=this.callBase;this._checkFrame=rr(function(){s.call(o,t,n),o._locked=!1})},dispose:function(){this.callBase(),On(this._scrollFrame),On(this._checkFrame)}}))})();var Lj=El.inherit(function(){let i=Math.round(16.666666666666668);return{ctor:function(e){this.callBase.apply(this,arguments),this.direction="both",this._pointerLocker=new dv(e),this._wheelLocker=new tA(e)},validate:function(){return!0},configure:function(e){e.scrollTarget&&(this._pointerLocker.dispose(),this._wheelLocker.dispose(),this._pointerLocker=new dv(e.scrollTarget),this._wheelLocker=new tA(e.scrollTarget)),this.callBase(e)},_init:function(e){this._wheelLocker.check(e,function(){Ut(e)&&this._accept(e)}.bind(this)),this._pointerLocker.check(e,function(){let t=this.isNative&&$n(e);!Ut(e)&&!t&&this._accept(e)}.bind(this)),this._fireEvent("dxscrollinit",e),this._prevEventData=Ye(e)},move:function(e){this.callBase.apply(this,arguments),e.isScrollingEvent=this.isNative||e.isScrollingEvent},_start:function(e){this._savedEventData=Ye(e),this._fireEvent("dxscrollstart",e),this._prevEventData=Ye(e)},_move:function(e){let t=Ye(e);this._fireEvent("dxscroll",e,{delta:Vo(this._prevEventData,t)}),Vo(this._savedEventData,t).time>200&&(this._savedEventData=this._prevEventData),this._prevEventData=Ye(e)},_end:function(e){let t=Vo(this._prevEventData,Ye(e)),n={x:0,y:0};if(!Ut(e)&&t.time<100){let o=Vo(this._savedEventData,this._prevEventData),s=i/o.time;n={x:o.x*s,y:o.y*s}}this._fireEvent("dxscrollend",e,{velocity:n})},_stop:function(e){this._fireEvent("dxscrollstop",e)},cancel:function(e){this.callBase.apply(this,arguments),this._fireEvent("dxscrollcancel",e)},dispose:function(){this.callBase.apply(this,arguments),this._pointerLocker.dispose(),this._wheelLocker.dispose()},_clearSelection:function(){if(!this.isNative)return this.callBase.apply(this,arguments)},_toggleGestureCover:function(){if(!this.isNative)return this.callBase.apply(this,arguments)}}}());Wn({emitter:Lj,events:["dxscrollinit","dxscrollstart","dxscroll","dxscrollend","dxscrollstop","dxscrollcancel"]});var Li={init:"dxscrollinit",start:"dxscrollstart",move:"dxscroll",end:"dxscrollend",stop:"dxscrollstop",cancel:"dxscrollcancel",scroll:"scroll"};function pi(i){return(e,t,n,o)=>{let s=o?D(i,o):i;if(t)return _.on(e,s,n,t),()=>{_.off(e,s,t)}}}var oA=pi(oe),OCe=pi(Li.scroll),SCe=pi(Li.init),ECe=pi(Li.start),wCe=pi(Li.move),ICe=pi(Li.end),DCe=pi(Li.stop),TCe=pi(Li.cancel),ACe=pi(ne.down),MCe=pi(ne.up),RCe=pi(ne.move),FCe=pi("mouseenter"),PCe=pi("mouseleave"),kCe=pi("keydown"),sA=pi("dxactive"),rA=pi("dxinactive"),aA=pi("dxhoverstart"),lA=pi("dxhoverend"),dA=pi("focusin"),cA=pi("focusout");var Cr={className:"",activeStateEnabled:!1,disabled:!1,focusStateEnabled:!1,hoverStateEnabled:!1,tabIndex:0,visible:!0};var Kt=vp(void 0);var Nj=["children","rtlEnabled"],Hj=i=>i.props.children,$j={},uA=(()=>{class i extends _t{constructor(t){super(t),this.state={},this.__getterCache={}}getChildContext(){return I({},this.context,{[Kt.id]:this.config||Kt.defaultValue})}get config(){return this.__getterCache.config!==void 0?this.__getterCache.config:this.__getterCache.config={rtlEnabled:this.props.rtlEnabled}}get restAttributes(){let t=this.props;return ge(t,Nj)}componentWillUpdate(t,n,o){this.props.rtlEnabled!==t.rtlEnabled&&(this.__getterCache.config=void 0)}render(){let t=this.props;return Hj({props:I({},t),config:this.config,restAttributes:this.restAttributes})}}return i.defaultProps=$j,i})();function hA(i,e){return i!==void 0?i:e?.rtlEnabled!==void 0?e.rtlEnabled:fe().rtlEnabled}function pA(i,e){let t=f(i),n=f(fe().rtlEnabled)&&!t&&!f(e?.rtlEnabled);return t&&i!==e?.rtlEnabled||n}var zj=["_feedbackHideTimeout","_feedbackShowTimeout","accessKey","activeStateEnabled","activeStateUnit","addWidgetClass","aria","children","className","classes","cssText","disabled","focusStateEnabled","height","hint","hoverStateEnabled","name","onActive","onClick","onDimensionChanged","onFocusIn","onFocusOut","onHoverEnd","onHoverStart","onInactive","onKeyDown","onRootElementRendered","onVisibilityChange","rootElementRef","rtlEnabled","tabIndex","visible","width"];var Wj=i=>Object.keys(i).reduce((e,t)=>i[t]?I({},e,{[t==="role"||t==="id"?t:`aria-${t}`]:String(i[t])}):e,{}),Gj=i=>{let e=yt(Ke(1,"div",i.cssClasses,i.props.children,0,I({},i.attributes,{tabIndex:i.tabIndex,title:i.props.hint,style:yl(i.styles)}),null,i.widgetElementRef));return i.shouldRenderConfigProvider?Ee(2,uA,{rtlEnabled:i.rtlEnabled,children:e}):e},wl=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(Cr),Object.getOwnPropertyDescriptors({_feedbackHideTimeout:400,_feedbackShowTimeout:30,cssText:"",aria:Object.freeze({}),classes:"",name:"",addWidgetClass:!0}))),Il=(()=>{class i extends Yn{get config(){return this.context[Kt.id]?this.context[Kt.id]:Kt.defaultValue}constructor(t){super(t),this.widgetElementRef=at(),this.state={active:!1,focused:!1,hovered:!1},this.setRootElementRef=this.setRootElementRef.bind(this),this.activeEffect=this.activeEffect.bind(this),this.inactiveEffect=this.inactiveEffect.bind(this),this.clickEffect=this.clickEffect.bind(this),this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.activate=this.activate.bind(this),this.deactivate=this.deactivate.bind(this),this.focusInEffect=this.focusInEffect.bind(this),this.focusOutEffect=this.focusOutEffect.bind(this),this.hoverStartEffect=this.hoverStartEffect.bind(this),this.hoverEndEffect=this.hoverEndEffect.bind(this),this.keyboardEffect=this.keyboardEffect.bind(this),this.resizeEffect=this.resizeEffect.bind(this),this.windowResizeEffect=this.windowResizeEffect.bind(this),this.visibilityEffect=this.visibilityEffect.bind(this),this.checkDeprecation=this.checkDeprecation.bind(this),this.applyCssTextEffect=this.applyCssTextEffect.bind(this)}createEffects(){return[new Le(this.setRootElementRef,[]),new Le(this.activeEffect,[this.props._feedbackShowTimeout,this.props.activeStateEnabled,this.props.activeStateUnit,this.props.disabled,this.props.onActive]),new Le(this.inactiveEffect,[this.props._feedbackHideTimeout,this.props.activeStateEnabled,this.props.activeStateUnit,this.props.onInactive,this.state.active]),new Le(this.clickEffect,[this.props.disabled,this.props.name,this.props.onClick]),new Le(this.focusInEffect,[this.props.disabled,this.props.focusStateEnabled,this.props.name,this.props.onFocusIn]),new Le(this.focusOutEffect,[this.props.focusStateEnabled,this.props.name,this.props.onFocusOut,this.state.focused]),new Le(this.hoverStartEffect,[this.props.activeStateUnit,this.props.disabled,this.props.hoverStateEnabled,this.props.onHoverStart,this.state.active]),new Le(this.hoverEndEffect,[this.props.activeStateUnit,this.props.hoverStateEnabled,this.props.onHoverEnd,this.state.hovered]),new Le(this.keyboardEffect,[this.props.focusStateEnabled,this.props.onKeyDown]),new Le(this.resizeEffect,[this.props.name,this.props.onDimensionChanged]),new Le(this.windowResizeEffect,[this.props.onDimensionChanged]),new Le(this.visibilityEffect,[this.props.name,this.props.onVisibilityChange]),new Le(this.checkDeprecation,[this.props.height,this.props.width]),new Le(this.applyCssTextEffect,[this.props.cssText]),zo()]}updateEffects(){var t,n,o,s,r,a,l,d,c,h,p,g,C;(t=this._effects[1])===null||t===void 0||t.update([this.props._feedbackShowTimeout,this.props.activeStateEnabled,this.props.activeStateUnit,this.props.disabled,this.props.onActive]),(n=this._effects[2])===null||n===void 0||n.update([this.props._feedbackHideTimeout,this.props.activeStateEnabled,this.props.activeStateUnit,this.props.onInactive,this.state.active]),(o=this._effects[3])===null||o===void 0||o.update([this.props.disabled,this.props.name,this.props.onClick]),(s=this._effects[4])===null||s===void 0||s.update([this.props.disabled,this.props.focusStateEnabled,this.props.name,this.props.onFocusIn]),(r=this._effects[5])===null||r===void 0||r.update([this.props.focusStateEnabled,this.props.name,this.props.onFocusOut,this.state.focused]),(a=this._effects[6])===null||a===void 0||a.update([this.props.activeStateUnit,this.props.disabled,this.props.hoverStateEnabled,this.props.onHoverStart,this.state.active]),(l=this._effects[7])===null||l===void 0||l.update([this.props.activeStateUnit,this.props.hoverStateEnabled,this.props.onHoverEnd,this.state.hovered]),(d=this._effects[8])===null||d===void 0||d.update([this.props.focusStateEnabled,this.props.onKeyDown]),(c=this._effects[9])===null||c===void 0||c.update([this.props.name,this.props.onDimensionChanged]),(h=this._effects[10])===null||h===void 0||h.update([this.props.onDimensionChanged]),(p=this._effects[11])===null||p===void 0||p.update([this.props.name,this.props.onVisibilityChange]),(g=this._effects[12])===null||g===void 0||g.update([this.props.height,this.props.width]),(C=this._effects[13])===null||C===void 0||C.update([this.props.cssText])}setRootElementRef(){let{onRootElementRendered:t,rootElementRef:n}=this.props;n&&(n.current=this.widgetElementRef.current),t?.(this.widgetElementRef.current)}activeEffect(){let{_feedbackShowTimeout:t,activeStateEnabled:n,activeStateUnit:o,disabled:s,onActive:r}=this.props,a=o;if(n&&!s)return sA(this.widgetElementRef.current,l=>{this.setState(d=>({active:!0})),r?.(l)},{timeout:t,selector:a},"UIFeedback")}inactiveEffect(){let{_feedbackHideTimeout:t,activeStateEnabled:n,activeStateUnit:o,onInactive:s}=this.props,r=o;if(n)return rA(this.widgetElementRef.current,a=>{this.state.active&&(this.setState(l=>({active:!1})),s?.(a))},{timeout:t,selector:r},"UIFeedback")}clickEffect(){let{disabled:t,name:n,onClick:o}=this.props,s=n;if(o&&!t)return uC.on(this.widgetElementRef.current,o,{namespace:s}),()=>uC.off(this.widgetElementRef.current,{namespace:s})}focusInEffect(){let{disabled:t,focusStateEnabled:n,name:o,onFocusIn:s}=this.props,r=`${o}Focus`;if(n&&!t)return dA(this.widgetElementRef.current,a=>{a.isDefaultPrevented()||(this.setState(l=>({focused:!0})),s?.(a))},null,r)}focusOutEffect(){let{focusStateEnabled:t,name:n,onFocusOut:o}=this.props,s=`${n}Focus`;if(t)return cA(this.widgetElementRef.current,r=>{!r.isDefaultPrevented()&&this.state.focused&&(this.setState(a=>({focused:!1})),o?.(r))},null,s)}hoverStartEffect(){let{activeStateUnit:t,disabled:n,hoverStateEnabled:o,onHoverStart:s}=this.props,r=t;if(o&&!n)return aA(this.widgetElementRef.current,a=>{!this.state.active&&this.setState(l=>({hovered:!0})),s?.(a)},{selector:r},"UIFeedback")}hoverEndEffect(){let{activeStateUnit:t,hoverStateEnabled:n,onHoverEnd:o}=this.props,s=t;if(n)return lA(this.widgetElementRef.current,r=>{this.state.hovered&&(this.setState(a=>({hovered:!1})),o?.(r))},{selector:s},"UIFeedback")}keyboardEffect(){let{focusStateEnabled:t,onKeyDown:n}=this.props;if(t&&n){let o=Kn.on(this.widgetElementRef.current,this.widgetElementRef.current,s=>n(s));return()=>Kn.off(o)}}resizeEffect(){let t=`${this.props.name}VisibilityChange`,{onDimensionChanged:n}=this.props;if(n)return cl.on(this.widgetElementRef.current,n,{namespace:t}),()=>cl.off(this.widgetElementRef.current,{namespace:t})}windowResizeEffect(){let{onDimensionChanged:t}=this.props;if(t)return co.add(t),()=>{co.remove(t)}}visibilityEffect(){let{name:t,onVisibilityChange:n}=this.props,o=`${t}VisibilityChange`;if(n)return ul.on(this.widgetElementRef.current,()=>n(!0),()=>n(!1),{namespace:o}),()=>ul.off(this.widgetElementRef.current,{namespace:o})}checkDeprecation(){let{height:t,width:n}=this.props;A(n)&&he.log("W0017","width"),A(t)&&he.log("W0017","height")}applyCssTextEffect(){let{cssText:t}=this.props;t!==""&&(this.widgetElementRef.current.style.cssText=t)}get shouldRenderConfigProvider(){let{rtlEnabled:t}=this.props;return pA(t,this.config)}get rtlEnabled(){let{rtlEnabled:t}=this.props;return hA(t,this.config)}get attributes(){let{aria:t,disabled:n,focusStateEnabled:o,visible:s}=this.props,r=o&&!n&&this.props.accessKey;return I({},m({},r&&{accessKey:r}),Wj(I({},t,{disabled:n,hidden:!s})),m({},this.restAttributes))}get styles(){let{height:t,width:n}=this.props,o=this.restAttributes.style||{},s=ps("width",A(n)?n():n),r=ps("height",A(t)?t():t);return I({},o,{height:r??o.height,width:s??o.width})}get cssClasses(){let{activeStateEnabled:t,addWidgetClass:n,className:o,classes:s,disabled:r,focusStateEnabled:a,hoverStateEnabled:l,onVisibilityChange:d,visible:c}=this.props,h=!!a&&!r,p=!!l&&!r,g=!!t&&!r,C={"dx-widget":!!n,[String(s)]:!!s,[String(o)]:!!o,"dx-state-disabled":!!r,"dx-state-invisible":!c,"dx-state-focused":!!this.state.focused&&h,"dx-state-active":!!this.state.active&&g,"dx-state-hover":!!this.state.hovered&&p&&!this.state.active,"dx-rtl":!!this.rtlEnabled,"dx-visibility-change-handler":!!d};return ti(C)}get tabIndex(){let{disabled:t,focusStateEnabled:n,tabIndex:o}=this.props;return n&&!t?o:void 0}get restAttributes(){let t=this.props;return ge(t,zj)}focus(){hl.trigger(this.widgetElementRef.current)}blur(){let t=w.getActiveElement(this.widgetElementRef.current);this.widgetElementRef.current===t&&t.blur()}activate(){this.setState(t=>({active:!0}))}deactivate(){this.setState(t=>({active:!1}))}render(){let t=this.props;return Gj({props:I({},t),active:this.state.active,focused:this.state.focused,hovered:this.state.hovered,widgetElementRef:this.widgetElementRef,config:this.config,shouldRenderConfigProvider:this.shouldRenderConfigProvider,rtlEnabled:this.rtlEnabled,attributes:this.attributes,styles:this.styles,cssClasses:this.cssClasses,tabIndex:this.tabIndex,restAttributes:this.restAttributes})}}return i.defaultProps=wl,i})();var Kj=["accessKey","activeStateEnabled","children","className","disabled","focusStateEnabled","height","hint","hoverStateEnabled","icon","iconPosition","iconTemplate","onClick","onKeyDown","onSubmit","pressed","rtlEnabled","stylingMode","tabIndex","template","templateData","text","type","useInkRipple","useSubmitBehavior","visible","width"],Uj=["outlined","text","contained"],jj=i=>{let{icon:e,iconPosition:t,stylingMode:n,text:o,type:s}=i,a={"dx-button":!0,[`dx-button-mode-${n&&Uj.includes(n)?n:"contained"}`]:!0,[`dx-button-${s??"normal"}`]:!0,"dx-button-has-text":!!o,"dx-button-has-icon":!!e,"dx-button-icon-right":t!=="left"};return ti(a)},qj=i=>{let{children:e,iconPosition:t,iconTemplate:n,template:o,text:s}=i.props,r=!i.props.template&&!e&&s!=="",a=t==="left",l=!i.props.template&&!e&&(i.iconSource||i.props.iconTemplate)&&Ee(2,qT,{source:i.iconSource,position:t,iconTemplate:n});return yt(Ee(2,Il,I({accessKey:i.props.accessKey,activeStateEnabled:i.props.activeStateEnabled,aria:i.aria,className:i.props.className,classes:i.cssClasses,disabled:i.props.disabled,focusStateEnabled:i.props.focusStateEnabled,height:i.props.height,hint:i.props.hint,hoverStateEnabled:i.props.hoverStateEnabled,onActive:i.onActive,onClick:i.onWidgetClick,onInactive:i.onInactive,onKeyDown:i.keyDown,rtlEnabled:i.props.rtlEnabled,tabIndex:i.props.tabIndex,visible:i.props.visible,width:i.props.width},i.restAttributes,{children:Ke(1,"div","dx-button-content",[i.props.template&&o({data:i.buttonTemplateData}),!i.props.template&&e,a&&l,r&&Ke(1,"span","dx-button-text",s,0),!a&&l,i.props.useSubmitBehavior&&Ke(64,"input","dx-button-submit-input",null,1,{type:"submit",tabIndex:-1},null,i.submitInputRef),i.props.useInkRipple&&Ee(2,JT,{config:i.inkRippleConfig},null,i.inkRippleRef)],0,null,null,i.contentRef)}),null,i.widgetRef))},Yj=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(Cr),Object.getOwnPropertyDescriptors({activeStateEnabled:!0,hoverStateEnabled:!0,icon:"",iconPosition:"left",stylingMode:"contained",text:"",type:"normal",useInkRipple:!1,useSubmitBehavior:!1,templateData:Object.freeze({})}))),fA=HI([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>it(ct()),options:{useInkRipple:!0}}]),gA=i=>i&&(i.defaultProps?e=>yt(Ee(2,i,I({},e))):i),ha=class extends Yn{constructor(e){super(e),this.state={},this.contentRef=at(),this.inkRippleRef=at(),this.submitInputRef=at(),this.widgetRef=at(),this.__getterCache={},this.focus=this.focus.bind(this),this.activate=this.activate.bind(this),this.deactivate=this.deactivate.bind(this),this.submitEffect=this.submitEffect.bind(this),this.onActive=this.onActive.bind(this),this.onInactive=this.onInactive.bind(this),this.onWidgetClick=this.onWidgetClick.bind(this),this.keyDown=this.keyDown.bind(this),this.emitClickEvent=this.emitClickEvent.bind(this)}createEffects(){return[new Le(this.submitEffect,[this.props.onSubmit,this.props.useSubmitBehavior]),zo()]}updateEffects(){var e;(e=this._effects[0])===null||e===void 0||e.update([this.props.onSubmit,this.props.useSubmitBehavior])}submitEffect(){let{onSubmit:e,useSubmitBehavior:t}=this.props;if(t&&e)return hC.on(this.submitInputRef.current,n=>e({event:n,submitInput:this.submitInputRef.current}),{namespace:"UIFeedback"}),()=>hC.off(this.submitInputRef.current,{namespace:"UIFeedback"})}onActive(e){let{useInkRipple:t}=this.props;t&&this.inkRippleRef.current.showWave({element:this.contentRef.current,event:e})}onInactive(e){let{useInkRipple:t}=this.props;t&&this.inkRippleRef.current.hideWave({element:this.contentRef.current,event:e})}onWidgetClick(e){let{onClick:t,useSubmitBehavior:n}=this.props;t?.({event:e}),n&&this.submitInputRef.current.click()}keyDown(e){let{onKeyDown:t}=this.props,{keyName:n,originalEvent:o,which:s}=e,r=t?.(e);if(r!=null&&r.cancel)return r;(n==="space"||s==="space"||n==="enter"||s==="enter")&&(o.preventDefault(),this.emitClickEvent())}emitClickEvent(){this.contentRef.current.click()}get aria(){let{icon:e,text:t}=this.props,n=t??"";if(!t&&e)switch(ms(e)){case"image":{let r=/^(?!(?:https?:\/\/)|(?:ftp:\/\/)|(?:www\.))[^\s]+$/;n=!e.includes("base64")&&r.test(e)?e.replace(/.+\/([^.]+)\..+$/,"$1"):"";break}case"dxIcon":n=O.format(Ci(e,!0))||e;break;case"fontIcon":n=e;break;case"svg":{var o;n=((o=/<title>(.*?)<\/title>/.exec(e))===null||o===void 0?void 0:o[1])??"";break}}return I({role:"button"},n?{label:n}:{})}get cssClasses(){return jj(this.props)}get iconSource(){let{icon:e}=this.props;return e??""}get inkRippleConfig(){return this.__getterCache.inkRippleConfig!==void 0?this.__getterCache.inkRippleConfig:this.__getterCache.inkRippleConfig=(()=>{let{icon:e,text:t}=this.props;return!t&&e?{isCentered:!0,useHoldAnimation:!1,waveSizeCoefficient:1}:{}})()}get buttonTemplateData(){let{icon:e,templateData:t,text:n}=this.props;return I({icon:e,text:n},t)}get restAttributes(){let e=this.props;return ge(e,Kj)}focus(){this.widgetRef.current.focus()}activate(){this.widgetRef.current.activate()}deactivate(){this.widgetRef.current.deactivate()}componentWillUpdate(e,t,n){super.componentWillUpdate(),(this.props.icon!==e.icon||this.props.text!==e.text)&&(this.__getterCache.inkRippleConfig=void 0)}render(){let e=this.props;return qj({props:I({},e,{template:gA(e.template),iconTemplate:gA(e.iconTemplate)}),contentRef:this.contentRef,submitInputRef:this.submitInputRef,inkRippleRef:this.inkRippleRef,widgetRef:this.widgetRef,onActive:this.onActive,onInactive:this.onInactive,onWidgetClick:this.onWidgetClick,keyDown:this.keyDown,emitClickEvent:this.emitClickEvent,aria:this.aria,cssClasses:this.cssClasses,iconSource:this.iconSource,inkRippleConfig:this.inkRippleConfig,buttonTemplateData:this.buttonTemplateData,restAttributes:this.restAttributes})}};ha.defaultProps=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(Yj),Object.getOwnPropertyDescriptors(I({},go(fA)))));var mA=[];function _A(i){mA.push(i),ha.defaultProps=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(ha.defaultProps),Object.getOwnPropertyDescriptors(go(fA)),Object.getOwnPropertyDescriptors(go(mA))))}var Dl=class extends bp{getProps(){let e=super.getProps();return e.onKeyDown=this._wrapKeyDownHandler(e.onKeyDown),e}focus(){var e;return(e=this.viewRef)===null||e===void 0?void 0:e.focus(...arguments)}activate(){var e;return(e=this.viewRef)===null||e===void 0?void 0:e.activate(...arguments)}deactivate(){var e;return(e=this.viewRef)===null||e===void 0?void 0:e.deactivate(...arguments)}_getActionConfigs(){return{onClick:{excludeValidators:["readOnly"]},onSubmit:{}}}get _propsInfo(){return{twoWay:[],allowNull:[],elements:["onSubmit"],templates:["template","iconTemplate"],props:["activeStateEnabled","hoverStateEnabled","icon","iconPosition","onClick","onSubmit","pressed","stylingMode","template","iconTemplate","text","type","useInkRipple","useSubmitBehavior","templateData","className","accessKey","disabled","focusStateEnabled","height","hint","onKeyDown","rtlEnabled","tabIndex","visible","width"]}}get _viewComponent(){return ha}};G("dxButton",Dl);Dl.defaultOptions=_A;var rt=Dl;var In=gl;var Xj=gl.inherit({_initMarkup(){this._deferredItems=[],this.callBase()},_renderItemContent(i){let e=y(),t=y();this._deferredItems[i.index]=t;let n=this.callBase.call(this,i);return t.done(()=>{e.resolve(n)}),e.promise()},_onItemTemplateRendered(i,e){return()=>{this._deferredItems[e.index].resolve()}},_postProcessRenderItems:S,_renderItemsAsync(){let i=y();return P.apply(this,this._deferredItems).done(()=>{this._postProcessRenderItems(),i.resolve()}),i.promise()},_clean(){this.callBase(),this._deferredItems=[]}}),CA=Xj;var xA=CA;var Qj=Xe,Op=Qj;var Zj=xA,vA=Zj;var Sp="dx-toolbar";var Jj="dxToolbarItemDataKey";var Ep=class extends vA{_getSynchronizableOptionsForCreateComponent(){return super._getSynchronizableOptionsForCreateComponent().filter(e=>e!=="disabled")}_initTemplates(){super._initTemplates();let e=new di((t,n,o)=>{if(q(n)){let{text:s,html:r,widget:a}=n;s&&t.text(s).wrapInner("<div>"),r&&t.html(r),a==="dxDropDownButton"&&(n.options=n.options??{},f(n.options.stylingMode)||(n.options.stylingMode=this.option("useFlatButtons")?"text":"contained")),a==="dxButton"&&(this.option("useFlatButtons")&&(n.options=n.options??{},n.options.stylingMode=n.options.stylingMode??"text"),this.option("useDefaultButtons")&&(n.options=n.options??{},n.options.type=n.options.type??"default"))}else t.text(String(n));this._getTemplate("dx-polymorph-widget").render({container:t,model:o,parent:this})},["text","html","widget","options"],this.option("integrationOptions.watchMethod"));this._templateManager.addDefaultTemplates({item:e,menuItem:e})}_getDefaultOptions(){return I({},super._getDefaultOptions(),{renderAs:"topToolbar",grouped:!1,useFlatButtons:!1,useDefaultButtons:!1})}_defaultOptionsRules(){return super._defaultOptionsRules().concat([{device:()=>pt(),options:{useFlatButtons:!0}}])}_itemContainer(){return this._$toolbarItemsContainer.find([".dx-toolbar-before",".dx-toolbar-center",".dx-toolbar-after"].join(","))}_itemClass(){return"dx-toolbar-item"}_itemDataKey(){return Jj}_dimensionChanged(e){this._disposed||(this._arrangeItems(),this._applyCompactMode())}_initMarkup(){this._renderToolbar(),this._renderSections(),super._initMarkup()}_render(){super._render(),this._renderItemsAsync(),this._updateDimensionsInMaterial()}_postProcessRenderItems(){this._arrangeItems()}_renderToolbar(){this.$element().addClass(Sp),this._$toolbarItemsContainer=u("<div>").addClass("dx-toolbar-items-container").appendTo(this.$element()),this.setAria("role","toolbar")}_renderSections(){let e=this._$toolbarItemsContainer;x(["before","center","after"],(t,n)=>{let o=`dx-toolbar-${n}`;e.find(`.${o}`).length||(this[`_$${n}Section`]=u("<div>").addClass(o).attr("role","presentation").appendTo(e))})}_arrangeItems(e){var t,n;let o=e??z(this.$element());this._$centerSection.css({margin:"0 auto",float:"none"});let s=Ie((t=this._$beforeSection)===null||t===void 0?void 0:t.get(0)),r=Ie((n=this._$afterSection)===null||n===void 0?void 0:n.get(0));this._alignCenterSection(s,r,o);let a=this._$toolbarItemsContainer.find(".dx-toolbar-label").eq(0),l=a.parent();if(!a.length)return;let d=s.width?s.width:a.position().left,c=l.hasClass("dx-toolbar-before")?0:d,h=l.hasClass("dx-toolbar-after")?0:r.width,p=0;l.children().not(".dx-toolbar-label").each((v,b)=>{p+=ie(b)});let g=o-p,C=Math.max(g-c-h,0);if(l.hasClass("dx-toolbar-before"))this._alignSection(this._$beforeSection,C);else{let v=ie(a)-z(a);a.css("maxWidth",C-v)}}_alignCenterSection(e,t,n){var o;this._alignSection(this._$centerSection,n-e.width-t.width);let s=this.option("rtlEnabled"),r=s?t:e,a=s?e:t,l=Ie((o=this._$centerSection)===null||o===void 0?void 0:o.get(0));(r.right>l.left||l.right>a.left)&&this._$centerSection.css({marginLeft:r.width,marginRight:a.width,float:r.width>a.width?"none":"right"})}_alignSection(e,t){let o=e.find(".dx-toolbar-label").toArray();t-=this._getCurrentLabelsPaddings(o);let s=this._getCurrentLabelsWidth(o),r=Math.abs(s-t);t<s?(o=o.reverse(),this._alignSectionLabels(o,r,!1)):this._alignSectionLabels(o,r,!0)}_alignSectionLabels(e,t,n){let o=function(s){return Ie(s).width};for(let s=0;s<e.length;s++){let r=u(e[s]),a=Math.ceil(o(e[s])),l;n&&r.css("maxWidth","inherit");let d=Math.ceil(n?o(e[s]):a);if(d<t)l=n?d:0,t-=d;else{l=n?a+t:a-t,r.css("maxWidth",l);break}r.css("maxWidth",l)}}_applyCompactMode(){let e=u(this.element());e.removeClass("dx-toolbar-compact"),this.option("compactMode")&&this._getSummaryItemsSize("width",this._itemElements(),!0)>z(e)&&e.addClass("dx-toolbar-compact")}_getCurrentLabelsWidth(e){let t=0;return e.forEach(n=>{t+=ie(n)}),t}_getCurrentLabelsPaddings(e){let t=0;return e.forEach(n=>{t+=ie(n)-z(n)}),t}_renderItem(e,t,n,o){let s=t.location??"center",r=n??this[`_$${s}Section`],a=!!(t.text??t.html),l=super._renderItem(e,t,r,o);return l.toggleClass("dx-toolbar-button",!a).toggleClass("dx-toolbar-label",a).addClass(t.cssClass),l}_renderGroupedItems(){x(this.option("items"),(e,t)=>{let n=t.items,o=u("<div>").addClass("dx-toolbar-group"),s=t.location??"center";!n||!n.length||(x(n,(r,a)=>{this._renderItem(r,a,o,null)}),this._$toolbarItemsContainer.find(`.dx-toolbar-${s}`).append(o))})}_renderItems(e){this.option("grouped")&&e.length&&e[0].items?this._renderGroupedItems():super._renderItems(e)}_getToolbarItems(){return this.option("items")??[]}_renderContentImpl(){let e=this._getToolbarItems();this.$element().toggleClass("dx-toolbar-mini",e.length===0),this._renderedItemsCount?this._renderItems(e.slice(this._renderedItemsCount)):this._renderItems(e),this._applyCompactMode()}_renderEmptyMessage(){}_clean(){this._$toolbarItemsContainer.children().empty(),this.$element().empty(),delete this._$beforeSection,delete this._$centerSection,delete this._$afterSection}_visibilityChanged(e){e&&this._arrangeItems()}_isVisible(){return z(this.$element())>0&&Y(this.$element())>0}_getIndexByItem(e){return this._getToolbarItems().indexOf(e)}_itemOptionChanged(e,t,n,o){super._itemOptionChanged(e,t,n,o),this._arrangeItems()}_optionChanged(e){let{name:t}=e;switch(t){case"width":super._optionChanged(e),this._dimensionChanged();break;case"renderAs":case"useFlatButtons":case"useDefaultButtons":this._invalidate();break;case"compactMode":this._applyCompactMode();break;case"grouped":break;default:super._optionChanged(e)}}_dispose(){super._dispose(),clearTimeout(this._waitParentAnimationTimeout)}_updateDimensionsInMaterial(){if(it()){let e=()=>new Promise(n=>{let o=()=>{let r=!0;return this.$element().parents().each((a,l)=>{if(pe.isAnimating(u(l)))return r=!1,!1}),r&&n(),r},s=()=>{clearTimeout(this._waitParentAnimationTimeout),this._waitParentAnimationTimeout=setTimeout(()=>o()||s(),15)};s()}),t=()=>{let n=this.$element().find(".dx-toolbar-label"),o=[];return n.each((s,r)=>{let a=u(r).text(),l=u(r).css("fontWeight");o.push(AD(a,l))}),Promise.all(o)};Promise.all([e(),t()]).then(()=>{this._dimensionChanged()})}}};G("dxToolbarBase",Ep);var cv=Ep;var bA=K(),e2={observe:S,unobserve:S,disconnect:S},uv=class{constructor(){if(!W()||!bA.ResizeObserver)return e2;this._callbacksMap=new Map,this._observer=new bA.ResizeObserver(e=>{e.forEach(t=>{var n;(n=this._callbacksMap.get(t.target))===null||n===void 0||n(t)})})}observe(e,t){this._callbacksMap.set(e,t),this._observer.observe(e)}unobserve(e){this._callbacksMap.delete(e),this._observer.unobserve(e)}disconnect(){this._callbacksMap.clear(),this._observer.disconnect()}},t2=new uv,Wo=t2;var Ds="dxdragstart",vo="dxdrag",Ts="dxdragend",Ac="dxdragenter",Mc="dxdragleave",pv="dxdrop";var Is=[],Tl=[],hv=[],gv={setup:function(i,e){Is.includes(i)||(Is.push(i),Tl.push([]),hv.push(e||{}))},add:function(i,e){let t=Is.indexOf(i);this.updateEventsCounter(i,e.type,1);let n=e.selector;Tl[t].includes(n)||Tl[t].push(n)},updateEventsCounter:function(i,e,t){if([Ac,Mc,pv].indexOf(e)>-1){let n=$e(i,"dxDragEventsCount")||0;$e(i,"dxDragEventsCount",Math.max(0,n+t))}},remove:function(i,e){this.updateEventsCounter(i,e.type,-1)},teardown:function(i){if(!$e(i,"dxDragEventsCount")){let t=Is.indexOf(i);Is.splice(t,1),Tl.splice(t,1),hv.splice(t,1),ir(i,"dxDragEventsCount")}}};vi(Ac,gv);vi(Mc,gv);vi(pv,gv);var i2=function(i){let e=Is.indexOf(i.get(0)),t=Tl[e].filter(o=>o),n=i.find(t.join(", "));return Tl[e].includes(void 0)&&(n=n.add(i)),n},n2=function(i){let e=Is.indexOf(i.get(0));return hv[e]},o2=function(i,e){return i.itemPositionFunc?i.itemPositionFunc(e):e.offset()},s2=function(i,e){return i.itemSizeFunc?i.itemSizeFunc(e):{width:e.get(0).getBoundingClientRect().width,height:e.get(0).getBoundingClientRect().height}},r2=El.inherit({ctor:function(i){this.callBase(i),this.direction="both"},_init:function(i){this._initEvent=i},_start:function(i){if(i=this._fireEvent("dxdragstart",this._initEvent),this._maxLeftOffset=i.maxLeftOffset,this._maxRightOffset=i.maxRightOffset,this._maxTopOffset=i.maxTopOffset,this._maxBottomOffset=i.maxBottomOffset,i.targetElements||i.targetElements===null){let e=CI(i.targetElements||[]);this._dropTargets=He(e,function(t){return u(t).get(0)})}else this._dropTargets=Is},_move:function(i){let e=Ye(i),t=this._calculateOffset(e);i=this._fireEvent("dxdrag",i,{offset:t}),this._processDropTargets(i),i._cancelPreventDefault||i.preventDefault()},_calculateOffset:function(i){return{x:this._calculateXOffset(i),y:this._calculateYOffset(i)}},_calculateXOffset:function(i){if(this.direction!=="vertical"){let e=i.x-this._startEventData.x;return this._fitOffset(e,this._maxLeftOffset,this._maxRightOffset)}return 0},_calculateYOffset:function(i){if(this.direction!=="horizontal"){let e=i.y-this._startEventData.y;return this._fitOffset(e,this._maxTopOffset,this._maxBottomOffset)}return 0},_fitOffset:function(i,e,t){return e!=null&&(i=Math.max(i,-e)),t!=null&&(i=Math.min(i,t)),i},_processDropTargets:function(i){let e=this._findDropTarget(i);e===this._currentDropTarget||(this._fireDropTargetEvent(i,Mc),this._currentDropTarget=e,this._fireDropTargetEvent(i,Ac))},_fireDropTargetEvent:function(i,e){if(!this._currentDropTarget)return;let t={type:e,originalEvent:i,draggingElement:this._$element.get(0),target:this._currentDropTarget};ji(t)},_findDropTarget:function(i){let e=this,t;return x(Is,function(n,o){if(!e._checkDropTargetActive(o))return;let s=u(o);x(i2(s),function(r,a){let l=u(a);e._checkDropTarget(n2(s),l,u(t),i)&&(t=a)})}),t},_checkDropTargetActive:function(i){let e=!1;return x(this._dropTargets,function(t,n){return e=e||n===i||on(n,i),!e}),e},_checkDropTarget:function(i,e,t,n){if(e.get(0)===u(n.target).get(0))return!1;let s=o2(i,e);if(n.pageX<s.left||n.pageY<s.top)return!1;let r=s2(i,e);return n.pageX>s.left+r.width||n.pageY>s.top+r.height||t.length&&t.closest(e).length||i.checkDropTarget&&!i.checkDropTarget(e,n)?!1:e},_end:function(i){let e=Ye(i);this._fireEvent("dxdragend",i,{offset:this._calculateOffset(e)}),this._fireDropTargetEvent(i,pv),delete this._currentDropTarget}});Wn({emitter:r2,events:["dxdragstart","dxdrag","dxdragend"]});var mv=function(){let i=[];return{add:function(e){i.includes(e)||i.push(e)},remove:function(e){let t=i.indexOf(e);t!==-1&&i.splice(t,1)},fire:function(){let e=i.pop(),t=!!e;return t&&e(),t},hasCallback:function(){return i.length>0}}}();var a2=i=>{let t=u(i).closest('[class^="dx-swatch-"], [class*=" dx-swatch-"]'),n=Sn();if(!t.length)return n;let o=new RegExp("(\\s|^)(dx-swatch-.*?)(\\s|$)"),s=t[0].className.match(o)[2],r=n.children("."+s);return r.length||(r=u("<div>").addClass(s).appendTo(n)),r},wp={getSwatchContainer:a2};var l2=K(),fv={top:{my:"top center",at:"top center"},bottom:{my:"bottom center",at:"bottom center"},right:{my:"right center",at:"right center"},left:{my:"left center",at:"left center"},center:{my:"center",at:"center"},"right bottom":{my:"right bottom",at:"right bottom"},"right top":{my:"right top",at:"right top"},"left bottom":{my:"left bottom",at:"left bottom"},"left top":{my:"left top",at:"left top"}},yA={h:0,v:0},xr=class{constructor(e){let{position:t,container:n,visualContainer:o,$root:s,$content:r,$wrapper:a,onPositioned:l,onVisualPositionChanged:d,restorePosition:c,_fixWrapperPosition:h,_skipContentPositioning:p}=e;this._props={position:t,container:n,visualContainer:o,restorePosition:c,onPositioned:l,onVisualPositionChanged:d,_fixWrapperPosition:h,_skipContentPositioning:p},this._$root=s,this._$content=r,this._$wrapper=a,this._$markupContainer=void 0,this._$visualContainer=void 0,this._shouldRenderContentInitialPosition=!0,this._visualPosition=void 0,this._initialPosition=void 0,this._previousVisualPosition=void 0,this.updateContainer(n),this.updatePosition(t),this.updateVisualContainer(o)}get $container(){return this.updateContainer(),this._$markupContainer}get $visualContainer(){return this._$visualContainer}get position(){return this._position}set fixWrapperPosition(e){this._props._fixWrapperPosition=e,this.styleWrapperPosition()}set restorePosition(e){this._props.restorePosition=e}restorePositionOnNextRender(e){this._shouldRenderContentInitialPosition=e||!this._visualPosition}openingHandled(){let e=this._props.restorePosition;this.restorePositionOnNextRender(e)}updatePosition(e){this._props.position=e,this._position=this._normalizePosition(e),this.updateVisualContainer()}updateContainer(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._props.container;this._props.container=e,this._$markupContainer=e?u(e):wp.getSwatchContainer(this._$root),this.updateVisualContainer(this._props.visualContainer)}updateVisualContainer(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._props.visualContainer;this._props.visualContainer=e,this._$visualContainer=this._getVisualContainer()}detectVisualPositionChange(e){this._updateVisualPositionValue(),this._raisePositionedEvents(e)}positionContent(){this._shouldRenderContentInitialPosition?this._renderContentInitialPosition():(Ae(this._$content,this._visualPosition),this.detectVisualPositionChange())}positionWrapper(){this._$visualContainer&&lt.setup(this._$wrapper,{my:"top left",at:"top left",of:this._$visualContainer})}styleWrapperPosition(){let t=Ne(this.$visualContainer.get(0))||this._props._fixWrapperPosition?"fixed":"absolute";this._$wrapper.css("position",t)}_updateVisualPositionValue(){this._previousVisualPosition=this._visualPosition,this._visualPosition=li(this._$content)}_renderContentInitialPosition(){this._renderBoundaryOffset(),Bo(this._$content);let e=this._$wrapper.css("overflow");if(this._$wrapper.css("overflow","hidden"),!this._props._skipContentPositioning){let t=lt.setup(this._$content,this._position);this._initialPosition=t}this._$wrapper.css("overflow",e),this.detectVisualPositionChange()}_raisePositionedEvents(e){let t=this._previousVisualPosition,n=this._visualPosition;(t?.top!==n.top||t?.left!==n.left)&&this._props.onVisualPositionChanged({previousPosition:t,position:n,event:e}),this._props.onPositioned({position:this._initialPosition})}_renderBoundaryOffset(){let e=this._position??{boundaryOffset:yA};this._$content.css("margin",`${e.v}px ${e.h}px`)}_getVisualContainer(){var e,t;let n=this._props.container,o=this._props.visualContainer,s=wE((e=this._props.position)===null||e===void 0?void 0:e.of)?this._props.position.of.target:(t=this._props.position)===null||t===void 0?void 0:t.of;return o?u(o):n?u(n):s?u(s):u(l2)}_normalizePosition(e){let t={boundaryOffset:yA};return f(e)?m(!0,{},t,this._positionToObject(e)):t}_positionToObject(e){return B(e)?m({},fv[e]):e}};var Ip=1500,vr=[],OA=i=>(Ip=Te(i,Ip),Ip),Dp=function(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Ip,{length:e}=vr,t=(e?vr[e-1]:i)+1;return vr.push(t),t},Rc=i=>{let e=vr.indexOf(i);e>=0&&vr.splice(e,1)},SA=i=>vr.length&&vr[vr.length-1]===i;var d2=zt.add,Al=K(),wA=qr;var _v=[];d2(()=>{_.subscribeGlobal(w.getDocument(),ne.down,i=>{for(let e=_v.length-1;e>=0;e--)if(!_v[e]._proxiedDocumentDownHandler(i))return})});var Tp=Xe.inherit({_supportedKeys(){return m(this.callBase(),{escape(){this.hide()}})},_getDefaultOptions(){return m(this.callBase(),{activeStateEnabled:!1,visible:!1,deferRendering:!0,shading:!0,shadingColor:"",wrapperAttr:{},position:m({},fv.center),width:"80vw",minWidth:null,maxWidth:null,height:"80vh",minHeight:null,maxHeight:null,animation:{show:{type:"pop",duration:300,from:{scale:.55}},hide:{type:"pop",duration:300,from:{opacity:1,scale:1},to:{opacity:0,scale:.55}}},closeOnOutsideClick:!1,hideOnOutsideClick:!1,_ignorePreventScrollEventsDeprecation:!1,onShowing:null,onShown:null,onHiding:null,onHidden:null,contentTemplate:"content",innerOverlay:!1,restorePosition:!0,container:void 0,visualContainer:void 0,hideTopOverlayHandler:()=>{this.hide()},hideOnParentScroll:!1,preventScrollEvents:!0,onPositioned:null,propagateOutsideClick:!1,ignoreChildEvents:!0,_checkParentVisibility:!0,_hideOnParentScrollTarget:void 0,_fixWrapperPosition:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>!W(),options:{width:null,height:null,animation:null,_checkParentVisibility:!1}}])},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{animation:!0})},$wrapper(){return this._$wrapper},_eventBindingTarget(){return this._$content},_setDeprecatedOptions(){this.callBase(),m(this._deprecatedOptions,{closeOnOutsideClick:{since:"22.1",alias:"hideOnOutsideClick"}})},ctor(i,e){this.callBase(i,e),e&&"preventScrollEvents"in e&&!e._ignorePreventScrollEventsDeprecation&&this._logDeprecatedPreventScrollEventsInfo()},_logDeprecatedPreventScrollEventsInfo(){this._logDeprecatedOptionWarning("preventScrollEvents",{since:"23.1",message:"If you enable this option, end-users may experience scrolling issues."})},_init(){this.callBase(),this._initActions(),this._initHideOnOutsideClickHandler(),this._initTabTerminatorHandler(),this._customWrapperClass=null,this._$wrapper=u("<div>").addClass("dx-overlay-wrapper"),this._$content=u("<div>").addClass("dx-overlay-content"),this._initInnerOverlayClass(),this.$element().addClass("dx-overlay"),this._$wrapper.attr("data-bind","dxControlsDescendantBindings: true"),this._toggleViewPortSubscription(!0),this._initHideTopOverlayHandler(this.option("hideTopOverlayHandler")),this._parentsScrollSubscriptionInfo={handler:e=>{this._hideOnParentsScrollHandler(e)}},this.warnPositionAsFunction()},warnPositionAsFunction(){A(this.option("position"))&&he.log("W0018")},_initInnerOverlayClass(){this._$content.toggleClass("dx-inner-overlay",this.option("innerOverlay"))},_initHideTopOverlayHandler(i){this._hideTopOverlayHandler=i},_getActionsList:()=>["onShowing","onShown","onHiding","onHidden","onPositioned","onVisualPositionChanged"],_initActions(){this._actions={};let i=this._getActionsList();x(i,(e,t)=>{this._actions[t]=this._createActionByOption(t,{excludeValidators:["disabled","readOnly"]})||S})},_initHideOnOutsideClickHandler(){var i=this;this._proxiedDocumentDownHandler=function(){return i._documentDownHandler(...arguments)}},_initMarkup(){this.callBase(),this._renderWrapperAttributes(),this._initPositionController()},_documentDownHandler(i){this._showAnimationProcessing&&this._stopAnimation();let e=u(Al.document).is(i.target)||on(Al.document,i.target),t=u(i.target).closest(".dx-inner-overlay").length;return e&&!t&&!(this._$content.is(i.target)||on(this._$content.get(0),i.target))&&this._shouldHideOnOutsideClick(i)&&this._outsideClickHandler(i),this.option("propagateOutsideClick")},_shouldHideOnOutsideClick(i){let{hideOnOutsideClick:e}=this.option();return A(e)?e(i):e},_outsideClickHandler(i){this.option("shading")&&i.preventDefault(),this.hide()},_getAnonymousTemplateName:()=>"content",_initTemplates(){this._templateManager.addDefaultTemplates({content:new Vi}),this.callBase()},_isTopOverlay(){let i=this._overlayStack();for(let e=i.length-1;e>=0;e--){let t=i[e]._findTabbableBounds();if(t.first||t.last)return i[e]===this}return!1},_overlayStack:()=>_v,_zIndexInitValue:()=>Tp.baseZIndex(),_toggleViewPortSubscription(i){var e=this;wA.remove(this._viewPortChangeHandle),i&&(this._viewPortChangeHandle=function(){e._viewPortChangeHandler(...arguments)},wA.add(this._viewPortChangeHandle))},_viewPortChangeHandler(){this._positionController.updateContainer(this.option("container")),this._refresh()},_renderWrapperAttributes(){let{wrapperAttr:i}=this.option(),e=m({},i),t=e.class;delete e.class,this.$wrapper().attr(e).removeClass(this._customWrapperClass).addClass(t),this._customWrapperClass=t},_renderVisibilityAnimate(i){return this._stopAnimation(),i?this._show():this._hide()},_getAnimationConfig(){return this._getOptionValue("animation",this)},_toggleBodyScroll:S,_animateShowing(){var i=this;let e=this._getAnimationConfig()??{},t=this._normalizeAnimation(e.show,"to"),n=t?.start??S,o=t?.complete??S;this._animate(t,function(){if(!i._isAnimationPaused){i.option("focusStateEnabled")&&_.trigger(i._focusTarget(),"focus");for(var s=arguments.length,r=new Array(s),a=0;a<s;a++)r[a]=arguments[a];o.call(i,...r),i._showAnimationProcessing=!1,i._isHidden=!1,i._actions.onShown(),i._toggleSafariScrolling(),i._showingDeferred.resolve()}},function(){if(!i._isAnimationPaused){for(var s=arguments.length,r=new Array(s),a=0;a<s;a++)r[a]=arguments[a];n.call(i,...r),i._showAnimationProcessing=!0}})},_processShowingHidingCancel(i,e,t){To(i)?i.then(n=>{n?t():e()}).catch(()=>e()):i?t():e()},_show(){if(this._showingDeferred=y(),this._parentHidden=this._isParentHidden(),this._showingDeferred.done(()=>{delete this._parentHidden}),this._parentHidden)return this._isHidden=!0,this._showingDeferred.resolve();if(this._currentVisible)return y().resolve().promise();if(this._currentVisible=!0,this._isHidingActionCanceled)delete this._isHidingActionCanceled,this._showingDeferred.reject();else{let i=()=>{this._stopAnimation(),this._toggleBodyScroll(this.option("enableBodyScroll")),this._toggleVisibility(!0),this._$content.css("visibility","hidden"),this._$content.toggleClass("dx-state-invisible",!1),this._updateZIndexStackPosition(!0),this._positionController.openingHandled(),this._renderContent();let e={cancel:!1};this._actions.onShowing(e),this._processShowingHidingCancel(e.cancel,()=>{this._$content.css("visibility",""),this._renderVisibility(!0),this._animateShowing()},()=>{this._toggleVisibility(!1),this._$content.css("visibility",""),this._$content.toggleClass("dx-state-invisible",!0),this._isShowingActionCanceled=!0,this._moveFromContainer(),this._toggleBodyScroll(!0),this.option("visible",!1),this._showingDeferred.resolve()})};this.option("templatesRenderAsynchronously")?(this._stopShowTimer(),this._asyncShowTimeout=setTimeout(i)):i()}return this._showingDeferred.promise()},_normalizeAnimation(i,e){return i&&(i=m({type:"slide",skipElementInitialStyles:!0},i),$(i[e])&&m(i[e],{position:this._positionController.position})),i},_animateHiding(){var i=this;let e=this._getAnimationConfig()??{},t=this._normalizeAnimation(e.hide,"from"),n=t?.start??S,o=t?.complete??S;this._animate(t,function(){var s;i._$content.css("pointerEvents",""),i._renderVisibility(!1);for(var r=arguments.length,a=new Array(r),l=0;l<r;l++)a[l]=arguments[l];o.call(i,...a),i._hideAnimationProcessing=!1,(s=i._actions)===null||s===void 0||s.onHidden(),i._hidingDeferred.resolve()},function(){i._$content.css("pointerEvents","none");for(var s=arguments.length,r=new Array(s),a=0;a<s;a++)r[a]=arguments[a];n.call(i,...r),i._hideAnimationProcessing=!0})},_hide(){if(!this._currentVisible)return y().resolve().promise();this._currentVisible=!1,this._hidingDeferred=y();let i={cancel:!1};if(this._isShowingActionCanceled)delete this._isShowingActionCanceled,this._hidingDeferred.reject();else{this._actions.onHiding(i),this._toggleSafariScrolling(),this._toggleBodyScroll(!0);let e=()=>{this._isHidingActionCanceled=!0,this._toggleBodyScroll(this.option("enableBodyScroll")),this.option("visible",!0),this._hidingDeferred.resolve()},t=()=>{this._forceFocusLost(),this._toggleShading(!1),this._toggleSubscriptions(!1),this._stopShowTimer(),this._animateHiding()};this._processShowingHidingCancel(i.cancel,t,e)}return this._hidingDeferred.promise()},_forceFocusLost(){let i=w.getActiveElement();!!this._$content.find(i).length&&zn()},_animate(i,e,t){i?(t=t||i.start||S,pe.animate(this._$content,m({},i,{start:t,complete:e}))):e()},_stopAnimation(){pe.stop(this._$content,!0)},_renderVisibility(i){i&&this._isParentHidden()||(this._currentVisible=i,this._stopAnimation(),i||D0(this._$content),i?(this._checkContainerExists(),this._moveToContainer(),this._renderGeometry(),nl(this._$content),bi(this._$content)):(this._toggleVisibility(i),this._$content.toggleClass("dx-state-invisible",!i),this._updateZIndexStackPosition(i),this._moveFromContainer()),this._toggleShading(i),this._toggleSubscriptions(i))},_updateZIndexStackPosition(i){let e=this._overlayStack(),t=e.indexOf(this);i?(t===-1&&(this._zIndex=Dp(this._zIndexInitValue()),e.push(this)),this._$wrapper.css("zIndex",this._zIndex),this._$content.css("zIndex",this._zIndex)):t!==-1&&(e.splice(t,1),Rc(this._zIndex))},_toggleShading(i){this._$wrapper.toggleClass("dx-overlay-shader",i&&this.option("shading")),this._$wrapper.css("backgroundColor",this.option("shading")?this.option("shadingColor"):""),this._toggleTabTerminator(i&&this.option("shading"))},_initTabTerminatorHandler(){var i=this;this._proxiedTabTerminatorHandler=function(){i._tabKeyHandler(...arguments)}},_toggleTabTerminator(i){let e=D("keydown",this.NAME);i?_.on(w.getDocument(),e,this._proxiedTabTerminatorHandler):_.off(w.getDocument(),e,this._proxiedTabTerminatorHandler)},_findTabbableBounds(){let i=this._$wrapper.find("*"),e=i.length-1,t={first:null,last:null};for(let n=0;n<=e&&(!t.first&&i.eq(n).is(Yd)&&(t.first=i.eq(n)),!t.last&&i.eq(e-n).is(Yd)&&(t.last=i.eq(e-n)),!(t.first&&t.last));n++);return t},_tabKeyHandler(i){if(De(i)!=="tab"||!this._isTopOverlay())return;let e=this._findTabbableBounds(),t=e.first,n=e.last,o=!i.shiftKey&&i.target===n.get(0),s=i.shiftKey&&i.target===t.get(0),r=e.length===0,a=!on(this._$wrapper.get(0),i.target);if(o||s||r||a){i.preventDefault();let l=i.shiftKey?n:t;_.trigger(l,"focusin"),_.trigger(l,"focus")}},_toggleSubscriptions(i){W()&&(this._toggleHideTopOverlayCallback(i),this._toggleHideOnParentsScrollSubscription(i))},_toggleHideTopOverlayCallback(i){this._hideTopOverlayHandler&&(i?mv.add(this._hideTopOverlayHandler):mv.remove(this._hideTopOverlayHandler))},_toggleHideOnParentsScrollSubscription(i){let e=D("scroll",this.NAME),{prevTargets:t,handler:n}=this._parentsScrollSubscriptionInfo??{};_.off(t,e,n);let o=this.option("hideOnParentScroll");if(i&&o){let s=this._getHideOnParentScrollTarget().parents();F.real().deviceType==="desktop"&&(s=s.add(Al)),_.on(s,e,n),this._parentsScrollSubscriptionInfo.prevTargets=s}},_hideOnParentsScrollHandler(i){let e=!1,t=this.option("hideOnParentScroll");A(t)&&(e=t(i)),!e&&!this._showAnimationProcessing&&this.hide()},_getHideOnParentScrollTarget(){let i=u(this.option("_hideOnParentScrollTarget"));return i.length?i:this._$wrapper},_render(){this.callBase(),this._appendContentToElement(),this._renderVisibilityAnimate(this.option("visible"))},_appendContentToElement(){this._$content.parent().is(this.$element())||this._$content.appendTo(this.$element())},_renderContent(){let i=!this._currentVisible&&this.option("deferRendering");if(this.option("visible")&&this._isParentHidden()){this._isHidden=!0;return}this._contentAlreadyRendered||i||(this._contentAlreadyRendered=!0,this._appendContentToElement(),this.callBase())},_isParentHidden(){if(!this.option("_checkParentVisibility"))return!1;if(this._parentHidden!==void 0)return this._parentHidden;let i=this.$element().parent();if(i.is(":visible"))return!1;let e=!1;return i.add(i.parents()).each((t,n)=>{if(u(n).css("display")==="none")return e=!0,!1}),e||!w.getBody().contains(i.get(0))},_renderContentImpl(){let i=y(),e=this.option("contentTemplate"),t=this._getTemplate(e),n=this._templateManager.anonymousTemplateName===e;return t&&t.render({container:N(this.$content()),noModel:!0,transclude:n,onRendered:()=>{i.resolve(),this.option("templatesRenderAsynchronously")&&this._dimensionChanged()}}),this._toggleWrapperScrollEventsSubscription(this.option("preventScrollEvents")),i.done(()=>{this.option("visible")&&this._moveToContainer()}),i.promise()},_getPositionControllerConfig(){let{container:i,visualContainer:e,_fixWrapperPosition:t,restorePosition:n,_skipContentPositioning:o}=this.option();return{container:i,visualContainer:e,$root:this.$element(),$content:this._$content,$wrapper:this._$wrapper,onPositioned:this._actions.onPositioned,onVisualPositionChanged:this._actions.onVisualPositionChanged,restorePosition:n,_fixWrapperPosition:t,_skipContentPositioning:o}},_initPositionController(){this._positionController=new xr(this._getPositionControllerConfig())},_toggleWrapperScrollEventsSubscription(i){let e=D(vo,this.NAME);_.off(this._$wrapper,e),i&&_.on(this._$wrapper,e,{validate:()=>!0,getDirection:()=>"both",_toggleGestureCover(t){t||this._toggleGestureCoverImpl(t)},_clearSelection:S,isNative:!0},t=>{let{originalEvent:n}=t.originalEvent,{type:o}=n||{},s=o==="wheel",r=o==="mousemove",a=s&&!ot(t);t._cancelPreventDefault=!0,n&&t.cancelable!==!1&&(!r&&!s||a)&&t.preventDefault()})},_moveFromContainer(){this._$content.appendTo(this.$element()),this._$wrapper.detach()},_checkContainerExists(){let i=this._positionController.$container;if(i===void 0)return;i.length>0||Z.log("W1021",this.NAME)},_moveToContainer(){let i=this._positionController.$container;this._$wrapper.appendTo(i),this._$content.appendTo(this._$wrapper)},_renderGeometry(i){let{visible:e}=this.option();e&&W()&&(this._stopAnimation(),this._renderGeometryImpl())},_renderGeometryImpl(){this._positionController.updatePosition(this._getOptionValue("position")),this._renderWrapper(),this._renderDimensions(),this._renderPosition()},_renderPosition(){this._positionController.positionContent()},_isAllWindowCovered(){return Ne(this._positionController.$visualContainer.get(0))&&this.option("shading")},_toggleSafariScrolling(){let i=this.option("visible"),e=u(w.getBody()),t=F.real().platform==="ios"&&be.safari,n=this._isAllWindowCovered(),o=e.hasClass("dx-prevent-safari-scrolling"),s=!o&&i&&n,r=o&&(!i||!n||this._disposed);t&&(r?(e.removeClass("dx-prevent-safari-scrolling"),Al.scrollTo(0,this._cachedBodyScrollTop),this._cachedBodyScrollTop=void 0):s&&(this._cachedBodyScrollTop=Al.pageYOffset,e.addClass("dx-prevent-safari-scrolling")))},_renderWrapper(){this._positionController.styleWrapperPosition(),this._renderWrapperDimensions(),this._positionController.positionWrapper()},_renderWrapperDimensions(){let{$visualContainer:i}=this._positionController,e=w.getDocumentElement(),t=Ne(i.get(0)),n=t?e.clientWidth:ie(i),o=t?Al.innerHeight:X(i);this._$wrapper.css({width:n,height:o})},_renderDimensions(){let i=this._$content.get(0);this._$content.css({minWidth:this._getOptionValue("minWidth",i),maxWidth:this._getOptionValue("maxWidth",i),minHeight:this._getOptionValue("minHeight",i),maxHeight:this._getOptionValue("maxHeight",i),width:this._getOptionValue("width",i),height:this._getOptionValue("height",i)})},_focusTarget(){return this._$content},_attachKeyboardEvents(){this._keyboardListenerId=Kn.on(this._$content,null,i=>this._keyboardHandler(i))},_keyboardHandler(i){let e=i.originalEvent;(u(e.target).is(this._$content)||!this.option("ignoreChildEvents"))&&this.callBase(...arguments)},_isVisible(){return this.option("visible")},_visibilityChanged(i){i?this.option("visible")&&this._renderVisibilityAnimate(i):this._renderVisibilityAnimate(i)},_dimensionChanged(){this._renderGeometry()},_clean(){let i=this.option();!this._contentAlreadyRendered&&!i.isRenovated&&this.$content().empty(),this._renderVisibility(!1),this._stopShowTimer(),this._cleanFocusState()},_stopShowTimer(){this._asyncShowTimeout&&clearTimeout(this._asyncShowTimeout),this._asyncShowTimeout=null},_dispose(){pe.stop(this._$content,!1),clearTimeout(this._deferShowTimer),this._toggleViewPortSubscription(!1),this._toggleSubscriptions(!1),this._updateZIndexStackPosition(!1),this._toggleTabTerminator(!1),this._actions=null,this._parentsScrollSubscriptionInfo=null,this.callBase(),this._toggleSafariScrolling(),this.option("visible")&&Rc(this._zIndex),this._$wrapper.remove(),this._$content.remove()},_toggleRTLDirection(i){this._$content.toggleClass("dx-rtl",i)},_optionChanged(i){let{value:e,name:t}=i;if(this._getActionsList().includes(t)){this._initActions();return}switch(t){case"animation":case"closeOnOutsideClick":case"hideOnOutsideClick":case"propagateOutsideClick":break;case"shading":this._toggleShading(this.option("visible")),this._toggleSafariScrolling();break;case"shadingColor":this._toggleShading(this.option("visible"));break;case"width":case"height":case"minWidth":case"maxWidth":case"minHeight":case"maxHeight":this._renderGeometry();break;case"position":this._positionController.updatePosition(this.option("position")),this._positionController.restorePositionOnNextRender(!0),this._renderGeometry(),this._toggleSafariScrolling();break;case"visible":this._renderVisibilityAnimate(e).done(()=>{var n;return(n=this._animateDeferred)===null||n===void 0?void 0:n.resolveWith(this)}).fail(()=>{var n;return(n=this._animateDeferred)===null||n===void 0?void 0:n.reject()});break;case"container":this._positionController.updateContainer(e),this._invalidate(),this._toggleSafariScrolling();break;case"visualContainer":this._positionController.updateVisualContainer(e),this._renderWrapper(),this._toggleSafariScrolling();break;case"innerOverlay":this._initInnerOverlayClass();break;case"deferRendering":case"contentTemplate":this._contentAlreadyRendered=!1,this._clean(),this._invalidate();break;case"hideTopOverlayHandler":this._toggleHideTopOverlayCallback(!1),this._initHideTopOverlayHandler(e),this._toggleHideTopOverlayCallback(this.option("visible"));break;case"hideOnParentScroll":case"_hideOnParentScrollTarget":this._toggleHideOnParentsScrollSubscription(this.option("visible"));break;case"rtlEnabled":this._contentAlreadyRendered=!1,this.callBase(i);break;case"_fixWrapperPosition":this._positionController.fixWrapperPosition=e;break;case"wrapperAttr":this._renderWrapperAttributes();break;case"restorePosition":this._positionController.restorePosition=e;break;case"preventScrollEvents":this._logDeprecatedPreventScrollEventsInfo(),this._toggleWrapperScrollEventsSubscription(e);break;default:this.callBase(i)}},toggle(i){i=i===void 0?!this.option("visible"):i;let e=y();if(i===this.option("visible"))return e.resolveWith(this,[i]).promise();let t=y();return this._animateDeferred=t,this.option("visible",i),t.promise().done(()=>{delete this._animateDeferred,e.resolveWith(this,[this.option("visible")])}).fail(()=>{delete this._animateDeferred,e.reject()}),e.promise()},$content(){return this._$content},show(){return this.toggle(!0)},hide(){return this.toggle(!1)},content(){return N(this._$content)},repaint(){this._contentAlreadyRendered?(this._positionController.restorePositionOnNextRender(!0),this._renderGeometry({forceStopAnimation:!0}),bi(this._$content)):this.callBase()}});Tp.baseZIndex=i=>OA(i);G("dxOverlay",Tp);var IA=Tp;var Ni=IA;var Ap="dxResizable";var c2=D(Ds,Ap),u2=D(vo,Ap),h2=D(Ts,Ap),p2={left:"borderLeftWidth",top:"borderTopWidth",right:"borderRightWidth",bottom:"borderBottomWidth"},DA=Qi.inherit({_getDefaultOptions(){return m(this.callBase(),{handles:"all",step:"1",stepPrecision:"simple",area:void 0,minWidth:30,maxWidth:1/0,minHeight:30,maxHeight:1/0,onResizeStart:null,onResize:null,onResizeEnd:null,roundStepValue:!0,keepAspectRatio:!0})},_init(){this.callBase(),this.$element().addClass("dx-resizable")},_initMarkup(){this.callBase(),this._renderHandles()},_render(){this.callBase(),this._renderActions()},_renderActions(){this._resizeStartAction=this._createActionByOption("onResizeStart"),this._resizeEndAction=this._createActionByOption("onResizeEnd"),this._resizeAction=this._createActionByOption("onResize")},_renderHandles(){this._handles=[];let i=this.option("handles");if(i==="none"||!i)return;let e=i==="all"?["top","bottom","left","right"]:i.split(" "),t={};x(e,(n,o)=>{t[o]=!0,this._renderHandle(o)}),t.bottom&&t.right&&this._renderHandle("corner-bottom-right"),t.bottom&&t.left&&this._renderHandle("corner-bottom-left"),t.top&&t.right&&this._renderHandle("corner-top-right"),t.top&&t.left&&this._renderHandle("corner-top-left"),this._attachEventHandlers()},_renderHandle(i){let e=u("<div>").addClass("dx-resizable-handle").addClass(`dx-resizable-handle-${i}`).appendTo(this.$element());this._handles.push(e)},_attachEventHandlers(){if(this.option("disabled"))return;let i={};i[c2]=this._dragStartHandler.bind(this),i[u2]=this._dragHandler.bind(this),i[h2]=this._dragEndHandler.bind(this),this._handles.forEach(e=>{_.on(e,i,{direction:"both",immediate:!0})})},_detachEventHandlers(){this._handles.forEach(i=>{_.off(i)})},_toggleEventHandlers(i){i?this._attachEventHandlers():this._detachEventHandlers()},_getElementSize(){let i=this.$element();return i.css("boxSizing")==="border-box"?{width:ie(i),height:X(i)}:{width:z(i),height:Y(i)}},_dragStartHandler(i){let e=this.$element();if(e.is(".dx-state-disabled, .dx-state-disabled *")){i.cancel=!0;return}this._toggleResizingClass(!0),this._movingSides=this._getMovingSides(i),this._elementLocation=li(e),this._elementSize=this._getElementSize(),this._renderDragOffsets(i),this._resizeStartAction({event:i,width:this._elementSize.width,height:this._elementSize.height,handles:this._movingSides}),i.targetElements=null},_toggleResizingClass(i){this.$element().toggleClass("dx-resizable-resizing",i)},_renderDragOffsets(i){let e=this._getArea();if(!e)return;let t=u(i.target).closest(".dx-resizable-handle"),n=ie(t),o=X(t),s=t.offset(),r=e.offset,a=this._getAreaScrollOffset();i.maxLeftOffset=this._leftMaxOffset=s.left-r.left-a.scrollX,i.maxRightOffset=this._rightMaxOffset=r.left+e.width-s.left-n+a.scrollX,i.maxTopOffset=this._topMaxOffset=s.top-r.top-a.scrollY,i.maxBottomOffset=this._bottomMaxOffset=r.top+e.height-s.top-o+a.scrollY},_getBorderWidth(i,e){if(Ne(i.get(0)))return 0;let t=i.css(p2[e]);return parseInt(t)||0},_proportionate(i,e){let t=this._elementSize,n=i==="x"?t.width/t.height:t.height/t.width;return e*n},_getProportionalDelta(i){let{x:e,y:t}=i,n=this._proportionate("y",e);if(n>=t)return{x:e,y:n};let o=this._proportionate("x",t);return o>=e?{x:o,y:t}:{x:0,y:0}},_getDirectionName(i){let e=this._movingSides;return i==="x"?e.left?"left":"right":e.top?"top":"bottom"},_fitIntoArea(i,e){let t=this._getDirectionName(i);return Math.min(e,this[`_${t}MaxOffset`]??1/0)},_fitDeltaProportionally(i){let e=I({},i),t=this._elementSize,{minWidth:n,minHeight:o,maxWidth:s,maxHeight:r}=this.option(),a=()=>t.width+e.x,l=()=>t.height+e.y,d=p=>e[p]===this._fitIntoArea(p,e[p]),c=()=>fn(a(),n,s)&&d("x"),h=()=>fn(l(),o,r)&&d("y");if(!c()){let p=this._fitIntoArea("x",ft(a(),n,s)-t.width);e={x:p,y:this._proportionate("y",p)}}if(!h()){let p=this._fitIntoArea("y",ft(l(),o,r)-t.height);e={x:this._proportionate("x",p),y:p}}return c()&&h()?e:{x:0,y:0}},_fitDelta(i){let{x:e,y:t}=i,n=this._elementSize,{minWidth:o,minHeight:s,maxWidth:r,maxHeight:a}=this.option();return{x:ft(n.width+e,o,r)-n.width,y:ft(n.height+t,s,a)-n.height}},_getDeltaByOffset(i){let e=this._movingSides,t=this._isCornerHandler(e)&&this.option("keepAspectRatio"),n={x:i.x*(e.left?-1:1),y:i.y*(e.top?-1:1)};if(t){let o=this._getProportionalDelta(n);n=this._fitDeltaProportionally(o)}else{let o=this._fitDelta(n);n=this._roundByStep(o)}return n},_updatePosition(i,e){let{width:t,height:n}=e,o=this._elementLocation,s=this._movingSides,r=this.$element(),a=this._getElementSize(),l=i.y*(s.top?-1:1)-((a.height||n)-n),d=i.x*(s.left?-1:1)-((a.width||t)-t);Ae(r,{top:o.top+(s.top?l:0),left:o.left+(s.left?d:0)})},_dragHandler(i){let e=this._getOffset(i),t=this._getDeltaByOffset(e),n=this._updateDimensions(t);this._updatePosition(t,n),this._triggerResizeAction(i,n)},_updateDimensions(i){let e=d=>d.substring(d.length-2)==="px",t=this.option("stepPrecision")==="strict",n=this._elementSize,o=n.width+i.x,s=n.height+i.y,r=this.$element().get(0).style,a=i.x||t||e(r.width),l=i.y||t||e(r.height);return a&&this.option({width:o}),l&&this.option({height:s}),{width:a?o:n.width,height:l?s:n.height}},_triggerResizeAction(i,e){let{width:t,height:n}=e;this._resizeAction({event:i,width:this.option("width")||t,height:this.option("height")||n,handles:this._movingSides}),bi(this.$element())},_isCornerHandler:i=>Object.values(i).reduce((e,t)=>e^t,0)===0,_getOffset(i){let{offset:e}=i,t=this._movingSides;return!t.left&&!t.right&&(e.x=0),!t.top&&!t.bottom&&(e.y=0),e},_roundByStep(i){return this.option("stepPrecision")==="strict"?this._roundStrict(i):this._roundNotStrict(i)},_getSteps(){return ja(this.option("step"),!this.option("roundStepValue"))},_roundNotStrict(i){let e=this._getSteps();return{x:i.x-i.x%e.h,y:i.y-i.y%e.v}},_roundStrict(i){let e=this._movingSides,t={x:i.x*(e.left?-1:1),y:i.y*(e.top?-1:1)},n=this._getSteps(),o=this._elementLocation,s=this._elementSize,r=e.left?o.left:o.left+s.width,a=e.top?o.top:o.top+s.height,l=(r+t.x)%n.h,d=(a+t.y)%n.v,c=Math.sign||(T=>(T=+T,T===0||isNaN(T)?T:T>0?1:-1)),h=(T,R)=>(1+.2*c(R))%1*T,p=(T,R)=>Math.abs(T)<.2*R,g=t.x-l,C=t.y-d;l>h(n.h,t.x)&&(g+=n.h),d>h(n.v,t.y)&&(C+=n.v);let v=(e.left||e.right)&&!p(t.x,n.h)?g:0,b=(e.top||e.bottom)&&!p(t.y,n.v)?C:0;return{x:v*(e.left?-1:1),y:b*(e.top?-1:1)}},_getMovingSides(i){let e=u(i.target),t=e.hasClass("dx-resizable-handle-corner-top-left"),n=e.hasClass("dx-resizable-handle-corner-top-right"),o=e.hasClass("dx-resizable-handle-corner-bottom-left"),s=e.hasClass("dx-resizable-handle-corner-bottom-right");return{top:e.hasClass("dx-resizable-handle-top")||t||n,left:e.hasClass("dx-resizable-handle-left")||t||o,bottom:e.hasClass("dx-resizable-handle-bottom")||o||s,right:e.hasClass("dx-resizable-handle-right")||n||s}},_getArea(){let i=this.option("area");return A(i)&&(i=i.call(this)),q(i)?this._getAreaFromObject(i):this._getAreaFromElement(i)},_getAreaScrollOffset(){let i=this.option("area"),e=!A(i)&&!q(i),t={scrollY:0,scrollX:0};if(e){let n=u(i)[0];Ne(n)&&(t.scrollX=n.pageXOffset,t.scrollY=n.pageYOffset)}return t},_getAreaFromObject(i){let e={width:i.right-i.left,height:i.bottom-i.top,offset:{left:i.left,top:i.top}};return this._correctAreaGeometry(e),e},_getAreaFromElement(i){let e=u(i),t;return e.length&&(t={width:Za(e),height:jr(e),offset:m({top:0,left:0},Ne(e[0])?{}:e.offset())},this._correctAreaGeometry(t,e)),t},_correctAreaGeometry(i,e){let t=e?this._getBorderWidth(e,"left"):0,n=e?this._getBorderWidth(e,"top"):0;i.offset.left+=t+this._getBorderWidth(this.$element(),"left"),i.offset.top+=n+this._getBorderWidth(this.$element(),"top"),i.width-=ie(this.$element())-Za(this.$element()),i.height-=X(this.$element())-jr(this.$element())},_dragEndHandler(i){let e=this.$element();this._resizeEndAction({event:i,width:ie(e),height:X(e),handles:this._movingSides}),this._toggleResizingClass(!1)},_renderWidth(i){this.option("width",ft(i,this.option("minWidth"),this.option("maxWidth")))},_renderHeight(i){this.option("height",ft(i,this.option("minHeight"),this.option("maxHeight")))},_optionChanged(i){switch(i.name){case"disabled":this._toggleEventHandlers(!i.value),this.callBase(i);break;case"handles":this._invalidate();break;case"minWidth":case"maxWidth":W()&&this._renderWidth(ie(this.$element()));break;case"minHeight":case"maxHeight":W()&&this._renderHeight(X(this.$element()));break;case"onResize":case"onResizeStart":case"onResizeEnd":this._renderActions();break;case"area":case"stepPrecision":case"step":case"roundStepValue":case"keepAspectRatio":break;default:this.callBase(i)}},_clean(){this.$element().find(".dx-resizable-handle").remove()},_useTemplates:()=>!1});G(Ap,DA);var TA=DA;var AA=TA;var Cv=class{constructor(e){this.init(e)}init(e){let{dragEnabled:t,handle:n,draggableElement:o,positionController:s}=e;this._positionController=s,this._draggableElement=o,this._handle=n,this._dragEnabled=t,this.unsubscribe(),t&&this.subscribe()}moveDown(e){this._moveTo(5,0,e)}moveUp(e){this._moveTo(-5,0,e)}moveLeft(e){this._moveTo(0,-5,e)}moveRight(e){this._moveTo(0,5,e)}subscribe(){let e=this._getEventNames();_.on(this._handle,e.startEventName,t=>{this._dragStartHandler(t)}),_.on(this._handle,e.updateEventName,t=>{this._dragUpdateHandler(t)}),_.on(this._handle,e.endEventName,t=>{this._dragEndHandler(t)})}unsubscribe(){let e=this._getEventNames();_.off(this._handle,e.startEventName),_.off(this._handle,e.updateEventName),_.off(this._handle,e.endEventName)}_getEventNames(){let e=D(Ds,"overlayDrag"),t=D(vo,"overlayDrag"),n=D(Ts,"overlayDrag");return{startEventName:e,updateEventName:t,endEventName:n}}_dragStartHandler(e){let t=this._getAllowedOffsets();this._prevOffset={x:0,y:0},e.targetElements=[],e.maxTopOffset=t.top,e.maxBottomOffset=t.bottom,e.maxLeftOffset=t.left,e.maxRightOffset=t.right}_dragUpdateHandler(e){let t={top:e.offset.y-this._prevOffset.y,left:e.offset.x-this._prevOffset.x};this._moveByOffset(t),this._prevOffset=e.offset}_dragEndHandler(e){this._positionController.dragHandled(),this._positionController.detectVisualPositionChange(e)}_moveTo(e,t,n){if(!this._dragEnabled)return;n.preventDefault(),n.stopPropagation();let o=this._fitOffsetIntoAllowedRange(e,t);this._moveByOffset(o),this._dragEndHandler(n)}_fitOffsetIntoAllowedRange(e,t){let n=this._getAllowedOffsets();return{top:ft(e,-n.top,n.bottom),left:ft(t,-n.left,n.right)}}_getContainerDimensions(){let e=w.getDocument(),t=this._positionController.$dragResizeContainer.get(0),n=ie(t),o=X(t);return Ne(t)&&(o=Math.max(e.body.clientHeight,o),n=Math.max(e.body.clientWidth,n)),{width:n,height:o}}_getContainerPosition(){let e=this._positionController.$dragResizeContainer.get(0);return Ne(e)?{top:0,left:0}:Ja(e)}_getElementPosition(){return Ja(this._draggableElement)}_getInnerDelta(){let e=this._getContainerDimensions(),t=this._getElementDimensions();return{x:e.width-t.width,y:e.height-t.height}}_getOuterDelta(){let{width:e,height:t}=this._getElementDimensions(),{outsideDragFactor:n}=this._positionController;return{x:e*n,y:t*n}}_getFullDelta(){let e=this._getInnerDelta(),t=this._getOuterDelta();return{x:e.x+t.x,y:e.y+t.y}}_getElementDimensions(){return{width:this._draggableElement.offsetWidth,height:this._draggableElement.offsetHeight}}_getAllowedOffsets(){let e=this._getFullDelta();if(!(e.y>=0&&e.x>=0))return{top:0,bottom:0,left:0,right:0};let n=this._getElementPosition(),o=this._getContainerPosition(),s=this._getOuterDelta();return{top:n.top-o.top+s.y,bottom:-n.top+o.top+e.y,left:n.left-o.left+s.x,right:-n.left+o.left+e.x}}_moveByOffset(e){let t=li(this._draggableElement),n={left:t.left+e.left,top:t.top+e.top};Ae(this._draggableElement,n)}},MA=Cv;var g2={setOverflow:S,restoreOverflow:S},RA=()=>{if(!W())return g2;let i=K(),{documentElement:e}=w.getDocument(),t=w.getBody(),n=F.real().platform==="ios",o={overflow:null,overflowX:null,overflowY:null,paddingRight:null,position:null,top:null,left:null};return{setOverflow:n?()=>{if(f(o.position)||t.style.position==="fixed")return;let{scrollY:s,scrollX:r}=i;o.position=t.style.position,o.top=t.style.top,o.left=t.style.left,t.style.setProperty("position","fixed"),t.style.setProperty("top",-s+"px"),t.style.setProperty("left",-r+"px")}:()=>{(()=>{let s=i.innerWidth-e.clientWidth;if(o.paddingRight||s<=0)return;let r=i.getComputedStyle(t).getPropertyValue("padding-right"),a=parseInt(r,10);o.paddingRight=a,t.style.setProperty("padding-right",`${a+s}px`)})(),!(o.overflow||t.style.overflow==="hidden")&&(o.overflow=t.style.overflow,o.overflowX=t.style.overflowX,o.overflowY=t.style.overflowY,t.style.setProperty("overflow","hidden"))},restoreOverflow:n?()=>{if(!f(o.position))return;let s=-parseInt(t.style.top,10),r=-parseInt(t.style.left,10);["position","top","left"].forEach(a=>{o[a]?t.style.setProperty(a,o[a]):t.style.removeProperty(a)}),i.scrollTo(r,s),o.position=null}:()=>{f(o.paddingRight)&&(o.paddingRight?t.style.setProperty("padding-right",`${o.paddingRight}px`):t.style.removeProperty("padding-right"),o.paddingRight=null),["overflow","overflowX","overflowY"].forEach(s=>{if(!f(o[s]))return;let r=s.replace(/(X)|(Y)/,a=>`-${a.toLowerCase()}`);o[s]?t.style.setProperty(r,o[s]):t.style.removeProperty(r),o[s]=null})}}};var m2=["fullScreen","forceApplyBindings","dragOutsideBoundary","dragAndResizeArea","outsideDragFactor"],xv=K(),Mp=class extends xr{constructor(e){let{fullScreen:t,forceApplyBindings:n,dragOutsideBoundary:o,dragAndResizeArea:s,outsideDragFactor:r}=e,a=ge(e,m2);super(a),this._props=I({},this._props,{fullScreen:t,forceApplyBindings:n,dragOutsideBoundary:o,dragAndResizeArea:s,outsideDragFactor:r}),this._$dragResizeContainer=void 0,this._updateDragResizeContainer()}set fullScreen(e){this._props.fullScreen=e,e?this._fullScreenEnabled():this._fullScreenDisabled()}get $dragResizeContainer(){return this._$dragResizeContainer}get outsideDragFactor(){return this._props.dragOutsideBoundary?1:this._props.outsideDragFactor}set dragAndResizeArea(e){this._props.dragAndResizeArea=e,this._updateDragResizeContainer()}set dragOutsideBoundary(e){this._props.dragOutsideBoundary=e,this._updateDragResizeContainer()}set outsideDragFactor(e){this._props.outsideDragFactor=e}updateContainer(e){super.updateContainer(e),this._updateDragResizeContainer()}dragHandled(){this.restorePositionOnNextRender(!1)}resizeHandled(){this.restorePositionOnNextRender(!1)}positionContent(){if(this._props.fullScreen)Ae(this._$content,{top:0,left:0}),this.detectVisualPositionChange();else{var e,t;(e=(t=this._props).forceApplyBindings)===null||e===void 0||e.call(t),super.positionContent()}}_updateDragResizeContainer(){this._$dragResizeContainer=this._getDragResizeContainer()}_getDragResizeContainer(){return this._props.dragOutsideBoundary?u(xv):this._props.dragAndResizeArea?u(this._props.dragAndResizeArea):xh().get(0)||this._props.container?this._$markupContainer:u(xv)}_getVisualContainer(){return this._props.fullScreen?u(xv):super._getVisualContainer()}_fullScreenEnabled(){this.restorePositionOnNextRender(!1)}_fullScreenDisabled(){this.restorePositionOnNextRender(!0)}};var f2=K();var FA=["cancel","clear","done"];var _2=be.safari&&ep(be.version,[11])<0,br={static:"",inherit:"dx-popup-inherit-height",flex:"dx-popup-flex-height"},C2=i=>{let e=F.current(),{platform:t}=e,n="bottom",o="before";if(t==="ios")switch(i){case"cancel":n="top";break;case"clear":n="top",o="after";break;case"done":o="after"}else if(t==="android")switch(i){case"cancel":case"done":o="after"}return{toolbar:n,location:o}},PA=Ni.inherit({_supportedKeys(){return m(this.callBase(),{upArrow:i=>{var e;(e=this._drag)===null||e===void 0||e.moveUp(i)},downArrow:i=>{var e;(e=this._drag)===null||e===void 0||e.moveDown(i)},leftArrow:i=>{var e;(e=this._drag)===null||e===void 0||e.moveLeft(i)},rightArrow:i=>{var e;(e=this._drag)===null||e===void 0||e.moveRight(i)}})},_getDefaultOptions(){return m(this.callBase(),{fullScreen:!1,title:"",showTitle:!0,titleTemplate:"title",onTitleRendered:null,dragOutsideBoundary:!1,dragEnabled:!1,dragAndResizeArea:void 0,enableBodyScroll:!0,outsideDragFactor:0,onResizeStart:null,onResize:null,onResizeEnd:null,resizeEnabled:!1,toolbarItems:[],showCloseButton:!1,bottomTemplate:"bottom",useDefaultToolbarButtons:!1,useFlatToolbarButtons:!1,autoResizeEnabled:!0})},_defaultOptionsRules(){return this.callBase().concat([{device:{platform:"ios"},options:{animation:this._iosAnimation}},{device:{platform:"android"},options:{animation:this._androidAnimation}},{device:{platform:"generic"},options:{showCloseButton:!0}},{device:i=>F.real().deviceType==="desktop"&&i.platform==="generic",options:{dragEnabled:!0}},{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>pt(),options:{useFlatToolbarButtons:!0}},{device:()=>it(),options:{useDefaultToolbarButtons:!0,showCloseButton:!1}}])},_iosAnimation:{show:{type:"slide",duration:400,from:{position:{my:"top",at:"bottom"}},to:{position:{my:"center",at:"center"}}},hide:{type:"slide",duration:400,from:{opacity:1,position:{my:"center",at:"center"}},to:{opacity:1,position:{my:"top",at:"bottom"}}}},_androidAnimation(){return this.option("fullScreen")?{show:{type:"slide",duration:300,from:{top:"30%",opacity:0},to:{top:0,opacity:1}},hide:{type:"slide",duration:300,from:{top:0,opacity:1},to:{top:"30%",opacity:0}}}:{show:{type:"fade",duration:400,from:0,to:1},hide:{type:"fade",duration:400,from:1,to:0}}},_init(){let i=this.option("_wrapperClassExternal"),e=i?`dx-popup-wrapper ${i}`:"dx-popup-wrapper";this.callBase(),this._createBodyOverflowManager(),this._updateResizeCallbackSkipCondition(),this.$element().addClass("dx-popup"),this.$wrapper().addClass(e),this._$popupContent=this._$content.wrapInner(u("<div>").addClass("dx-popup-content")).children().eq(0),this._toggleContentScrollClass(),this.$overlayContent().attr("role","dialog")},_render(){let i=this.option("fullScreen");this._toggleFullScreenClass(i),this.callBase()},_createBodyOverflowManager(){this._bodyOverflowManager=RA()},_toggleFullScreenClass(i){this.$overlayContent().toggleClass("dx-popup-fullscreen",i).toggleClass("dx-popup-normal",!i)},_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({title:new Vi,bottom:new Vi})},_getActionsList(){return this.callBase().concat(["onResizeStart","onResize","onResizeEnd"])},_contentResizeHandler(i){this._shouldSkipContentResize(i)||this._renderGeometry({shouldOnlyReposition:!0})},_doesShowAnimationChangeDimensions(){let i=this.option("animation");return["to","from"].some(e=>{var t;let n=i==null||(t=i.show)===null||t===void 0?void 0:t[e];return $(n)&&("width"in n||"height"in n)})},_updateResizeCallbackSkipCondition(){let i=this._doesShowAnimationChangeDimensions();this._shouldSkipContentResize=e=>i&&this._showAnimationProcessing||this._areContentDimensionsRendered(e)},_observeContentResize(i){if(!this.option("useResizeObserver"))return;let e=this._$content.get(0);i?Wo.observe(e,t=>{this._contentResizeHandler(t)}):Wo.unobserve(e)},_areContentDimensionsRendered(i){var e,t,n;let o=(e=i.contentBoxSize)===null||e===void 0?void 0:e[0];if(o){var s,r;return parseInt(o.inlineSize,10)===((s=this._renderedDimensions)===null||s===void 0?void 0:s.width)&&parseInt(o.blockSize,10)===((r=this._renderedDimensions)===null||r===void 0?void 0:r.height)}let{contentRect:a}=i;return parseInt(a.width,10)===((t=this._renderedDimensions)===null||t===void 0?void 0:t.width)&&parseInt(a.height,10)===((n=this._renderedDimensions)===null||n===void 0?void 0:n.height)},_renderContent(){this.callBase(),this._observeContentResize(!0)},_renderContentImpl(){this._renderTitle(),this.callBase(),this._renderResize(),this._renderBottom()},_renderTitle(){let i=this._getToolbarItems("top"),{title:e,showTitle:t}=this.option();if(t&&e&&i.unshift({location:F.current().ios?"center":"before",text:e}),t||i.length>0){this._$title&&this._$title.remove();let n=u("<div>").addClass("dx-popup-title").insertBefore(this.$content());this._$title=this._renderTemplateByType("titleTemplate",i,n).addClass("dx-popup-title"),this._renderDrag(),this._executeTitleRenderAction(this._$title),this._$title.toggleClass("dx-has-close-button",this._hasCloseButton())}else this._$title&&this._$title.detach();this._toggleAriaLabel()},_toggleAriaLabel(){var i;let{title:e,showTitle:t}=this.option(),o=t&&!!e?new Oe:null;(i=this._$title)===null||i===void 0||i.find(".dx-toolbar-label").eq(0).attr("id",o),this.$overlayContent().attr("aria-labelledby",o)},_renderTemplateByType(i,e,t,n){let{rtlEnabled:o,useDefaultToolbarButtons:s,useFlatToolbarButtons:r,disabled:a}=this.option(),l=this._getTemplateByOption(i);if(l instanceof Vi){let h=m({},this.option("integrationOptions"),{skipTemplates:["content","title"]}),p=m(n,{items:e,rtlEnabled:o,useDefaultButtons:s,useFlatButtons:r,disabled:a,integrationOptions:h});this._getTemplate("dx-polymorph-widget").render({container:t,model:{widget:this._getToolbarName(),options:p}});let g=t.children("div");return t.replaceWith(g),g}let c=u(l.render({container:N(t)}));return c.hasClass("dx-template-wrapper")&&(t.replaceWith(c),t=c),t},_getToolbarName:()=>"dxToolbarBase",_renderVisibilityAnimate(i){return this.callBase(i)},_hide(){return this._observeContentResize(!1),this.callBase()},_executeTitleRenderAction(i){this._getTitleRenderAction()({titleElement:N(i)})},_getTitleRenderAction(){return this._titleRenderAction||this._createTitleRenderAction()},_createTitleRenderAction(){return this._titleRenderAction=this._createActionByOption("onTitleRendered",{element:this.element(),excludeValidators:["disabled","readOnly"]})},_getCloseButton(){return{toolbar:"top",location:"after",template:this._getCloseButtonRenderer()}},_getCloseButtonRenderer(){return(i,e,t)=>{let n=u("<div>").addClass("dx-closebutton");this._createComponent(n,rt,{icon:"close",onClick:this._createToolbarItemAction(void 0),stylingMode:"text",integrationOptions:{}}),u(t).append(n)}},_getToolbarItems(i){let e=this.option("toolbarItems"),t=[];this._toolbarItemClasses=[];let n=F.current().platform,o=0;return x(e,(s,r)=>{let a=f(r.shortcut),l=a?C2(r.shortcut):r;if(a&&n==="ios"&&o<2&&(l.toolbar="top",o++),l.toolbar=r.toolbar||l.toolbar||"top",l&&l.toolbar===i){a&&m(l,{location:r.location},this._getToolbarItemByAlias(r));let d=n==="generic";r.shortcut==="done"&&d||r.shortcut==="cancel"&&!d?t.unshift(l):t.push(l)}}),i==="top"&&this._hasCloseButton()&&t.push(this._getCloseButton()),t},_hasCloseButton(){return this.option("showCloseButton")&&this.option("showTitle")},_getLocalizationKey:i=>i.toLowerCase()==="done"?"OK":Ci(i,!0),_getToolbarButtonStylingMode(i){return ut()?i==="done"?"contained":"outlined":this.option("useFlatToolbarButtons")?"text":"contained"},_getToolbarButtonType(i){return ut()&&i==="done"||this.option("useDefaultToolbarButtons")?"default":"normal"},_getToolbarItemByAlias(i){let e=this,t=i.shortcut;if(!FA.includes(t))return!1;let n=m({text:O.format(this._getLocalizationKey(t)),onClick:this._createToolbarItemAction(i.onClick),integrationOptions:{},type:this._getToolbarButtonType(t),stylingMode:this._getToolbarButtonStylingMode(t)},i.options||{}),o=`dx-popup-${t}`;return this._toolbarItemClasses.push(o),{template(s,r,a){let l=u("<div>").addClass(o).appendTo(a);e._createComponent(l,rt,n)}}},_createToolbarItemAction(i){return this._createAction(i,{afterExecute(e){e.component.hide()}})},_renderBottom(){let i=this._getToolbarItems("bottom");if(i.length){this._$bottom&&this._$bottom.remove();let e=u("<div>").addClass("dx-popup-bottom").insertAfter(this.$content());this._$bottom=this._renderTemplateByType("bottomTemplate",i,e,{compactMode:!0}).addClass("dx-popup-bottom"),this._toggleClasses()}else this._$bottom&&this._$bottom.detach()},_toggleDisabledState(i){this.callBase(...arguments),this.$content().toggleClass("dx-state-disabled",!!i)},_toggleClasses(){x(FA,(e,t)=>{let n=`dx-popup-${t}`;this._toolbarItemClasses.includes(n)?(this.$wrapper().addClass(`${n}-visible`),this._$bottom.addClass(n)):(this.$wrapper().removeClass(`${n}-visible`),this._$bottom.removeClass(n))})},_toggleFocusClass(i,e){if(this.callBase(i,e),i&&!SA(this._zIndex)){let t=Dp(this._zIndexInitValue());Rc(this._zIndex),this._zIndex=t,this._$wrapper.css("zIndex",t),this._$content.css("zIndex",t)}},_toggleContentScrollClass(){let i=!this.option("preventScrollEvents");this.$content().toggleClass("dx-popup-content-scrollable",i)},_getPositionControllerConfig(){let{fullScreen:i,forceApplyBindings:e,dragOutsideBoundary:t,dragAndResizeArea:n,outsideDragFactor:o}=this.option();return m({},this.callBase(),{fullScreen:i,forceApplyBindings:e,dragOutsideBoundary:t,dragAndResizeArea:n,outsideDragFactor:o})},_initPositionController(){this._positionController=new Mp(this._getPositionControllerConfig())},_getDragTarget(){return this.topToolbar()},_renderGeometry(i){let{visible:e,useResizeObserver:t}=this.option();if(e&&W()){let o=this._showAnimationProcessing&&!(i!=null&&i.forceStopAnimation)&&t;this._isAnimationPaused=o||void 0,this._stopAnimation(),i!=null&&i.shouldOnlyReposition?this._renderPosition(!1):this._renderGeometryImpl(i?.isDimensionChange),o&&(this._animateShowing(),this._isAnimationPaused=void 0)}},_cacheDimensions(){this.option("useResizeObserver")&&(this._renderedDimensions={width:parseInt(z(this._$content),10),height:parseInt(Y(this._$content),10)})},_renderGeometryImpl(){(arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1)||this._resetContentHeight(),this.callBase(),this._cacheDimensions(),this._setContentHeight()},_resetContentHeight(){this._getOptionValue("height")==="auto"&&this.$content().css({height:"auto",maxHeight:"none"})},_renderDrag(){let i=this._getDragTarget(),e=this.option("dragEnabled");if(!i)return;let t={dragEnabled:e,handle:i.get(0),draggableElement:this._$content.get(0),positionController:this._positionController};this._drag?this._drag.init(t):this._drag=new MA(t),this.$overlayContent().toggleClass("dx-popup-draggable",e)},_renderResize(){this._resizable=this._createComponent(this._$content,AA,{handles:this.option("resizeEnabled")?"all":"none",onResizeEnd:i=>{this._resizeEndHandler(i),this._observeContentResize(!0)},onResize:i=>{this._setContentHeight(),this._actions.onResize(i)},onResizeStart:i=>{this._observeContentResize(!1),this._actions.onResizeStart(i)},minHeight:100,minWidth:100,area:this._positionController.$dragResizeContainer,keepAspectRatio:!1})},_resizeEndHandler(i){let e=this._resizable.option("width"),t=this._resizable.option("height");e&&this._setOptionWithoutOptionChange("width",e),t&&this._setOptionWithoutOptionChange("height",t),this._cacheDimensions(),this._positionController.resizeHandled(),this._positionController.detectVisualPositionChange(i.event),this._actions.onResizeEnd(i)},_setContentHeight(){(this.option("forceApplyBindings")||S)();let i=this.$overlayContent().get(0),e=this._chooseHeightStrategy(i);this.$content().css(this._getHeightCssStyles(e,i)),this._setHeightClasses(this.$overlayContent(),e)},_heightStrategyChangeOffset:(i,e)=>i===br.flex?-e:0,_chooseHeightStrategy(i){let e=i.style.width==="auto"||i.style.width==="",t=br.static;return this._isAutoHeight()&&this.option("autoResizeEnabled")&&(e||_2?t=br.inherit:t=br.flex),t},_getHeightCssStyles(i,e){let t={},n=this._getOptionValue("maxHeight",e),o=this._getOptionValue("minHeight",e),s=this._splitPopupHeight(),r=s.header+s.footer+s.contentVerticalOffsets+s.popupVerticalOffsets+this._heightStrategyChangeOffset(i,s.popupVerticalPaddings);if(i===br.static){if(!this._isAutoHeight()||n||o){let l=(this.option("fullScreen")?Math.min(Ie(e).height,K().innerHeight):Ie(e).height)-r;t={height:Math.max(0,l),minHeight:"auto",maxHeight:"auto"}}}else{let a=u(this._positionController.$visualContainer).get(0),l=hw(n,-r,a);t={height:"auto",minHeight:pw(o,-r,a),maxHeight:l}}return t},_setHeightClasses(i,e){let t="";for(let n in br)br[n]!==e&&(t+=` ${br[n]}`);i.removeClass(t).addClass(e)},_isAutoHeight(){return this.$overlayContent().get(0).style.height==="auto"},_splitPopupHeight(){let i=this.topToolbar(),e=this.bottomToolbar();return{header:Gf(i&&i.get(0)),footer:Gf(e&&e.get(0)),contentVerticalOffsets:sr(this.$overlayContent().get(0),!0),popupVerticalOffsets:sr(this.$content().get(0),!0),popupVerticalPaddings:sr(this.$content().get(0),!1)}},_isAllWindowCovered(){return this.callBase()||this.option("fullScreen")},_renderDimensions(){this.option("fullScreen")?this.$overlayContent().css({width:"100%",height:"100%",minWidth:"",maxWidth:"",minHeight:"",maxHeight:""}):this.callBase(),W()&&this._renderFullscreenWidthClass()},_dimensionChanged(){this._renderGeometry({isDimensionChange:!0})},_clean(){this.callBase(),this._observeContentResize(!1)},_dispose(){this.callBase(),this._toggleBodyScroll(!0)},_renderFullscreenWidthClass(){this.$overlayContent().toggleClass("dx-popup-fullscreen-width",ie(this.$overlayContent())===z(f2))},_toggleSafariScrolling(){this.option("enableBodyScroll")&&this.callBase()},_toggleBodyScroll(i){if(!this._bodyOverflowManager)return;let{setOverflow:e,restoreOverflow:t}=this._bodyOverflowManager;i?t():e()},refreshPosition(){this._renderPosition()},_optionChanged(i){var e;let{value:t,name:n}=i;switch(n){case"disabled":this.callBase(i),this._renderTitle(),this._renderBottom();break;case"animation":this._updateResizeCallbackSkipCondition();break;case"enableBodyScroll":this.option("visible")&&this._toggleBodyScroll(t);break;case"showTitle":case"title":case"titleTemplate":this._renderTitle(),this._renderGeometry(),bi(this.$overlayContent());break;case"bottomTemplate":this._renderBottom(),this._renderGeometry(),bi(this.$overlayContent());break;case"container":if(this.callBase(i),this.option("resizeEnabled")){var o;(o=this._resizable)===null||o===void 0||o.option("area",this._positionController.$dragResizeContainer)}break;case"width":case"height":this.callBase(i),(e=this._resizable)===null||e===void 0||e.option(n,t);break;case"onTitleRendered":this._createTitleRenderAction(t);break;case"toolbarItems":case"useDefaultToolbarButtons":case"useFlatToolbarButtons":{let s=!i.fullName.match(/^toolbarItems((\[\d+\])(\.(options|visible).*)?)?$/);this._renderTitle(),this._renderBottom(),s&&(this._renderGeometry(),bi(this.$overlayContent()));break}case"dragEnabled":this._renderDrag();break;case"dragAndResizeArea":this._positionController.dragAndResizeArea=t,this.option("resizeEnabled")&&this._resizable.option("area",this._positionController.$dragResizeContainer),this._positionController.positionContent();break;case"dragOutsideBoundary":this._positionController.dragOutsideBoundary=t,this.option("resizeEnabled")&&this._resizable.option("area",this._positionController.$dragResizeContainer);break;case"outsideDragFactor":this._positionController.outsideDragFactor=t;break;case"resizeEnabled":this._renderResize(),this._renderGeometry();break;case"autoResizeEnabled":this._renderGeometry(),bi(this.$overlayContent());break;case"fullScreen":this._positionController.fullScreen=t,this._toggleFullScreenClass(t),this._toggleSafariScrolling(),this._renderGeometry(),bi(this.$overlayContent());break;case"showCloseButton":this._renderTitle();break;case"preventScrollEvents":this.callBase(i),this._toggleContentScrollClass();break;default:this.callBase(i)}},bottomToolbar(){return this._$bottom},topToolbar(){return this._$title},$content(){return this._$popupContent},content(){return N(this.$content())},$overlayContent(){return this._$content},getFocusableElements(){return this.$wrapper().find("[tabindex]").filter((i,e)=>e.getAttribute("tabindex")>=0)}});G("dxPopup",PA);var kA=PA;var ii=kA;var BA={left:"borderLeftWidth",top:"borderTopWidth",right:"borderRightWidth",bottom:"borderBottomWidth"};var x2=["shading","target","$arrow"],As={left:-1,top:-1,center:0,right:1,bottom:1},vv={top:{my:"bottom center",at:"top center",collision:"fit flip"},bottom:{my:"top center",at:"bottom center",collision:"fit flip"},right:{my:"left center",at:"right center",collision:"flip fit"},left:{my:"right center",at:"left center",collision:"flip fit"}},v2={h:10,v:10},Rp=class extends xr{constructor(e){let{shading:t,target:n,$arrow:o}=e,s=ge(e,x2);super(s),this._props=I({},this._props,{shading:t,target:n}),this._$arrow=o,this._positionSide=void 0,this.updatePosition(this._props.position)}positionWrapper(){this._props.shading&&this._$wrapper.css({top:0,left:0})}updateTarget(e){this._props.target=e,this.updatePosition(this._props.position)}_renderBoundaryOffset(){}_getContainerPosition(){let e=ja(this._position.offset||""),{h:t,v:n}=e,o=this._isVerticalSide(),s=this._isHorizontalSide();if(o||s){let a=(this._isPopoverInside()?-1:1)*As[this._positionSide],l=o?Y(this._$arrow):z(this._$arrow),d=this._getContentBorderWidth(this._positionSide),c=a*(l-d);o?n+=c:t+=c}return m({},this._position,{offset:`${t} ${n}`})}_getContentBorderWidth(e){let t=this._$content.css(BA[e]);return parseInt(t)||0}_isPopoverInside(){let e=lt.setup.normalizeAlign(this._position.my),t=lt.setup.normalizeAlign(this._position.at);return e.h===t.h&&e.v===t.v}_isVerticalSide(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._positionSide;return e==="top"||e==="bottom"}_isHorizontalSide(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._positionSide;return e==="left"||e==="right"}_getDisplaySide(e){let t=lt.setup.normalizeAlign(e.my),n=lt.setup.normalizeAlign(e.at),o=As[t.h]===As[n.h]&&As[t.v]===As[n.v]?-1:1,s=Math.abs(As[t.h]-o*As[n.h]),r=Math.abs(As[t.v]-o*As[n.v]);return s>r?n.h:n.v}_normalizePosition(e){let t={of:this._props.target,boundaryOffset:v2},n;return f(e)?n=m(!0,{},t,this._positionToObject(e)):n=t,this._positionSide=this._getDisplaySide(n),n}_positionToObject(e){return B(e)?m({},vv[e]):e}};var VA={left:"right",top:"bottom",right:"left",bottom:"top",center:"center"},LA=function(i){return $(i)?i.name:i},NA=function(i,e){let t=i.option(e);return LA(t)},b2=function(i,e){let t=i.option(e);return $(t)&&t.delay},bv=function(i,e){let{target:t,shading:n,disabled:o,hideEvent:s}=i.option(),r=B(t),a=n&&e==="hide",l=a?null:NA(i,`${e}Event`);if(a&&s&&Z.log("W1020"),!l||o)return;let d=D(l,i.NAME),c=i._createAction(function(){let g=b2(i,`${e}Event`);this._clearEventsTimeouts(),g?this._timeouts[e]=setTimeout(()=>{i[e]()},g):i[e]()}.bind(i),{validatingTargetName:"target"}),h=function(g){c({event:g,target:u(g.currentTarget)})},p=`_${e}EventHandler`;if(r)i[p]=h,_.on(w.getDocument(),d,t,h);else{let g=N(u(t));i[p]=void 0,_.on(g,d,h)}},yv=function(i,e,t,n){let o=n||NA(i,`${t}Event`);if(!o)return;o=D(o,i.NAME);let s=`_${t}EventHandler`;i[s]?_.off(w.getDocument(),o,e,i[s]):_.off(N(u(e)),o)},HA=ii.inherit({_getDefaultOptions(){return m(this.callBase(),{target:void 0,shading:!1,position:m({},vv.bottom),hideOnOutsideClick:!0,animation:{show:{type:"fade",from:0,to:1},hide:{type:"fade",from:1,to:0}},showTitle:!1,width:"auto",height:"auto",dragEnabled:!1,resizeEnabled:!1,fullScreen:!1,hideOnParentScroll:!0,arrowPosition:"",arrowOffset:0,_fixWrapperPosition:!0})},_defaultOptionsRules:()=>[{device:{platform:"ios"},options:{arrowPosition:{boundaryOffset:{h:20,v:-10},collision:"fit"}}},{device:()=>!W(),options:{animation:null}},{device:()=>pt(),options:{useFlatToolbarButtons:!0}},{device:()=>it(),options:{useDefaultToolbarButtons:!0,showCloseButton:!1}}],_init(){var i;this.callBase(),this._renderArrow(),this._timeouts={},this.$element().addClass("dx-popover"),this.$wrapper().addClass("dx-popover-wrapper");let e=(i=this.option("toolbarItems"))===null||i===void 0?void 0:i.length;this.setAria("role",e?"dialog":"tooltip")},_render(){this.callBase.apply(this,arguments),this._detachEvents(this.option("target")),this._attachEvents()},_detachEvents(i){yv(this,i,"show"),yv(this,i,"hide")},_attachEvents(){bv(this,"show"),bv(this,"hide")},_renderArrow(){this._$arrow=u("<div>").addClass("dx-popover-arrow").prependTo(this.$overlayContent())},_documentDownHandler(i){return this._isOutsideClick(i)?this.callBase(i):!0},_isOutsideClick(i){return!u(i.target).closest(this.option("target")).length},_animate(i){i&&i.to&&typeof i.to=="object"&&m(i.to,{position:this._getContainerPosition()}),this.callBase.apply(this,arguments)},_stopAnimation(){this.callBase.apply(this,arguments)},_renderTitle(){this.$wrapper().toggleClass("dx-popover-without-title",!this.option("showTitle")),this.callBase()},_renderPosition(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.callBase(),this._renderOverlayPosition(i),this._actions.onPositioned()},_renderOverlayPosition(i){this._resetOverlayPosition(i),this._updateContentSize(i);let e=this._getContainerPosition(),t=lt.setup(this.$overlayContent(),e),n=this._getSideByLocation(t);this._togglePositionClass(`dx-position-${n}`),this._toggleFlippedClass(t.h.flip,t.v.flip),(this._isHorizontalSide()||this._isVerticalSide())&&this._renderArrowPosition(n)},_resetOverlayPosition(i){this._setContentHeight(i),this._togglePositionClass(`dx-position-${this._positionController._positionSide}`),Ae(this.$overlayContent(),{left:0,top:0}),this._$arrow.css({top:"auto",right:"auto",bottom:"auto",left:"auto"})},_updateContentSize(i){if(!this.$content()||!i)return;let e=lt.calculate(this.$overlayContent(),this._getContainerPosition());if(e.h.oversize>0&&this._isHorizontalSide()&&!e.h.fit){let t=z(this.$overlayContent())-e.h.oversize;Fo(this.$overlayContent(),t)}if(e.v.oversize>0&&this._isVerticalSide()&&!e.v.fit){let t=Y(this.$overlayContent())-e.v.oversize,n=Y(this.$content())-e.v.oversize;xi(this.$overlayContent(),t),xi(this.$content(),n)}},_getContainerPosition(){return this._positionController._getContainerPosition()},_getHideOnParentScrollTarget(){return u(this._positionController._position.of||this.callBase())},_getSideByLocation(i){let e=i.v.flip,t=i.h.flip;return this._isVerticalSide()&&e||this._isHorizontalSide()&&t||this._isPopoverInside()?VA[this._positionController._positionSide]:this._positionController._positionSide},_togglePositionClass(i){this.$wrapper().removeClass("dx-position-left dx-position-right dx-position-top dx-position-bottom").addClass(i)},_toggleFlippedClass(i,e){this.$wrapper().toggleClass("dx-popover-flipped-horizontal",i).toggleClass("dx-popover-flipped-vertical",e)},_renderArrowPosition(i){let e=Ie(this._$arrow.get(0)),t=-(this._isVerticalSide(i)?e.height:e.width);this._$arrow.css(VA[i],t);let n=this._isVerticalSide(i)?"left":"top",o=this._isVerticalSide(i)?"width":"height",s=u(this._positionController._position.of),r=lt.offset(s)||{top:0,left:0},a=lt.offset(this.$overlayContent()),l=e[o],d=a[n],c=Ie(this.$overlayContent().get(0))[o],h=r[n],p=s.get(0),g=p&&!p.preventDefault?Ie(p)[o]:0,C=Math.max(d,h),v=Math.min(d+c,h+g),b;this.option("arrowPosition")==="start"?b=C-d:this.option("arrowPosition")==="end"?b=v-d-l:b=(C+v)/2-d-l/2;let T=this._positionController._getContentBorderWidth(i),R=ft(b-T+this.option("arrowOffset"),T,c-l-2*T);this._$arrow.css(n,R)},_isPopoverInside(){return this._positionController._isPopoverInside()},_setContentHeight(i){i&&this.callBase()},_getPositionControllerConfig(){let{shading:i,target:e}=this.option();return m({},this.callBase(),{target:e,shading:i,$arrow:this._$arrow})},_initPositionController(){this._positionController=new Rp(this._getPositionControllerConfig())},_renderWrapperDimensions(){this.option("shading")&&this.$wrapper().css({width:"100%",height:"100%"})},_isVerticalSide(i){return this._positionController._isVerticalSide(i)},_isHorizontalSide(i){return this._positionController._isHorizontalSide(i)},_clearEventTimeout(i){clearTimeout(this._timeouts[i])},_clearEventsTimeouts(){this._clearEventTimeout("show"),this._clearEventTimeout("hide")},_clean(){this._detachEvents(this.option("target")),this.callBase.apply(this,arguments)},_optionChanged(i){switch(i.name){case"arrowPosition":case"arrowOffset":this._renderGeometry();break;case"fullScreen":i.value&&this.option("fullScreen",!1);break;case"target":i.previousValue&&this._detachEvents(i.previousValue),this._positionController.updateTarget(i.value),this._invalidate();break;case"showEvent":case"hideEvent":{let e=i.name.substring(0,4),t=LA(i.previousValue);this.hide(),yv(this,this.option("target"),e,t),bv(this,e);break}case"visible":this._clearEventTimeout(i.value?"show":"hide"),this.callBase(i);break;case"disabled":this._detachEvents(this.option("target")),this._attachEvents(),this.callBase(i);break;default:this.callBase(i)}},show(i){return i&&this.option("target",i),this.callBase()}});G("dxPopover",HA);var $A=HA;var Fc=$A;var y2=m({},Uh,{_dataExpressionDefaultOptions:()=>({items:[],dataSource:null,itemTemplate:"item",value:null,valueExpr:"this",displayExpr:void 0}),_initDataExpressions(){this._compileValueGetter(),this._compileDisplayGetter(),this._initDynamicTemplates(),this._initDataSource(),this._itemsToDataSource()},_itemsToDataSource(){this.option("dataSource")||(this._dataSource=new jt({store:new No(this.option("items")),pageSize:0}),this._initDataController())},_compileDisplayGetter(){this._displayGetter=me(this._displayGetterExpr())},_displayGetterExpr(){return this.option("displayExpr")},_compileValueGetter(){this._valueGetter=me(this._valueGetterExpr())},_valueGetterExpr(){return this.option("valueExpr")||"this"},_loadValue(i){let e=y();return i=this._unwrappedValue(i),f(i)?(this._loadSingle(this._valueGetterExpr(),i).done(t=>{this._isValueEquals(this._valueGetter(t),i)?e.resolve(t):e.reject()}).fail(()=>{e.reject()}),this._loadValueDeferred=e,e.promise()):e.reject().promise()},_rejectValueLoading(){var i;(i=this._loadValueDeferred)===null||i===void 0||i.reject({shouldSkipCallback:!0})},_getCurrentValue(){return this.option("value")},_unwrappedValue(i){return i=i??this._getCurrentValue(),i&&this._dataSource&&this._valueGetterExpr()==="this"&&(i=this._getItemKey(i)),It.unwrap(i)},_getItemKey(i){let e=this._dataSource.key();if(Array.isArray(e)){let t={};for(let n=0,o=e.length;n<o;n++)t[e[n]]=i[e[n]];return t}return e&&typeof i=="object"&&(i=i[e]),i},_isValueEquals(i,e){let t=this._dataSource&&this._dataSource.key(),n=this._compareValues(i,e);return!n&&t&&f(i)&&f(e)&&(Array.isArray(t)?n=this._compareByCompositeKey(i,e,t):n=this._compareByKey(i,e,t)),n},_compareByCompositeKey(i,e,t){let n=$;if(!n(i)||!n(e))return!1;for(let o=0,s=t.length;o<s;o++)if(i[t[o]]!==e[t[o]])return!1;return!0},_compareByKey(i,e,t){let n=It.unwrap,o=Te(n(i[t]),i),s=Te(n(e[t]),e);return this._compareValues(o,s)},_compareValues:(i,e)=>Ot(i,!0)===Ot(e,!0),_initDynamicTemplates:S,_setCollectionWidgetItemTemplate(){this._initDynamicTemplates(),this._setCollectionWidgetOption("itemTemplate",this.option("itemTemplate"))},_getCollectionKeyExpr(){let i=this.option("valueExpr");return B(i)&&i!=="this"||A(i)?i:null},_dataExpressionOptionChanged(i){switch(i.name){case"items":this._itemsToDataSource(),this._setCollectionWidgetOption("items");break;case"dataSource":this._initDataSource();break;case"itemTemplate":this._setCollectionWidgetItemTemplate();break;case"valueExpr":this._compileValueGetter();break;case"displayExpr":this._compileDisplayGetter(),this._initDynamicTemplates(),this._setCollectionWidgetOption("displayExpr")}}}),zA=y2;var Pc=zA;function WA(i){return class{constructor(){throw new Error(`Module '${i}' not found`)}static getInstance(){}}}var GA=WA("TextBox"),bo={_getDefaultOptions:function(){return m(this.callBase(),{searchMode:"",searchExpr:null,searchValue:"",searchEnabled:!1,searchEditorOptions:{}})},_initMarkup:function(){this._renderSearch(),this.callBase()},_renderSearch:function(){let i=this.$element(),e=this.option("searchEnabled"),t=this._addWidgetPrefix("search"),n=this._addWidgetPrefix("with-search");if(!e){i.removeClass(n),this._removeSearchBox();return}let o=this._getSearchEditorOptions();this._searchEditor?this._searchEditor.option(o):(i.addClass(n),this._$searchEditorElement=u("<div>").addClass(t).prependTo(i),this._searchEditor=this._createComponent(this._$searchEditorElement,GA,o))},_removeSearchBox:function(){this._$searchEditorElement&&this._$searchEditorElement.remove(),delete this._$searchEditorElement,delete this._searchEditor},_getSearchEditorOptions:function(){let i=this,e=i.option("searchEditorOptions"),t=O.format("Search");return m({mode:"search",placeholder:t,tabIndex:i.option("tabIndex"),value:i.option("searchValue"),valueChangeEvent:"input",inputAttr:{"aria-label":t},onValueChanged:function(n){let o=i.option("searchTimeout");i._valueChangeDeferred=new y,clearTimeout(i._valueChangeTimeout),i._valueChangeDeferred.done(function(){this.option("searchValue",n.value)}.bind(i)),n.event&&n.event.type==="input"&&o?i._valueChangeTimeout=setTimeout(function(){i._valueChangeDeferred.resolve()},o):i._valueChangeDeferred.resolve()}},e)},_getAriaTarget:function(){return this.option("searchEnabled")?this._itemContainer(!0):this.callBase()},_focusTarget:function(){return this.option("searchEnabled")?this._itemContainer(!0):this.callBase()},_updateFocusState:function(i,e){this.option("searchEnabled")&&this._toggleFocusClass(e,this.$element()),this.callBase(i,e)},getOperationBySearchMode:function(i){return i==="equals"?"=":i},_optionChanged:function(i){switch(i.name){case"searchEnabled":case"searchEditorOptions":this._invalidate();break;case"searchExpr":case"searchMode":case"searchValue":if(!this._dataSource){Z.log("W1009");return}i.name==="searchMode"?this._dataSource.searchOperation(this.getOperationBySearchMode(i.value)):this._dataSource[i.name](i.value),this._dataSource.load();break;case"searchTimeout":break;default:this.callBase(i)}},focus:function(){if(!this.option("focusedElement")&&this.option("searchEnabled")){this._searchEditor&&this._searchEditor.focus();return}this.callBase()},_cleanAria:function(){let i=this.$element();this.setAria({role:null,activedescendant:null},i),i.attr("tabIndex",null)},_clean(){this.callBase(),this._cleanAria()},_refresh:function(){this._valueChangeDeferred&&this._valueChangeDeferred.resolve(),this.callBase()},setEditorClass:function(i){GA=i}};var Fp="dxswipestart",Pp="dxswipe",Ml="dxswipeend",O2={defaultItemSizeFunc:function(){return z(this.getElement())},getBounds:function(){return[this._maxLeftOffset,this._maxRightOffset]},calcOffsetRatio:function(i){return(Ye(i).x-(this._savedEventData&&this._savedEventData.x||0))/this._itemSizeFunc().call(this,i)},isFastSwipe:function(i){let e=Ye(i);return this.FAST_SWIPE_SPEED_LIMIT*Math.abs(e.x-this._tickData.x)>=e.time-this._tickData.time}},S2={defaultItemSizeFunc:function(){return Y(this.getElement())},getBounds:function(){return[this._maxTopOffset,this._maxBottomOffset]},calcOffsetRatio:function(i){return(Ye(i).y-(this._savedEventData&&this._savedEventData.y||0))/this._itemSizeFunc().call(this,i)},isFastSwipe:function(i){let e=Ye(i);return this.FAST_SWIPE_SPEED_LIMIT*Math.abs(e.y-this._tickData.y)>=e.time-this._tickData.time}},E2={horizontal:O2,vertical:S2},w2=El.inherit({TICK_INTERVAL:300,FAST_SWIPE_SPEED_LIMIT:10,ctor:function(i){this.callBase(i),this.direction="horizontal",this.elastic=!0},_getStrategy:function(){return E2[this.direction]},_defaultItemSizeFunc:function(){return this._getStrategy().defaultItemSizeFunc.call(this)},_itemSizeFunc:function(){return this.itemSizeFunc||this._defaultItemSizeFunc},_init:function(i){this._tickData=Ye(i)},_start:function(i){this._savedEventData=Ye(i),i=this._fireEvent("dxswipestart",i),i.cancel||(this._maxLeftOffset=i.maxLeftOffset,this._maxRightOffset=i.maxRightOffset,this._maxTopOffset=i.maxTopOffset,this._maxBottomOffset=i.maxBottomOffset)},_move:function(i){let e=this._getStrategy(),t=Ye(i),n=e.calcOffsetRatio.call(this,i);n=this._fitOffset(n,this.elastic),t.time-this._tickData.time>this.TICK_INTERVAL&&(this._tickData=t),this._fireEvent("dxswipe",i,{offset:n}),i.cancelable!==!1&&i.preventDefault()},_end:function(i){let e=this._getStrategy(),t=e.calcOffsetRatio.call(this,i),n=e.isFastSwipe.call(this,i),o=t,s=this._calcTargetOffset(t,n);o=this._fitOffset(o,this.elastic),s=this._fitOffset(s,!1),this._fireEvent("dxswipeend",i,{offset:o,targetOffset:s})},_fitOffset:function(i,e){let n=this._getStrategy().getBounds.call(this);return i<-n[0]?e?(-2*n[0]+i)/3:-n[0]:i>n[1]?e?(2*n[1]+i)/3:n[1]:i},_calcTargetOffset:function(i,e){let t;return e?(t=Math.ceil(Math.abs(i)),i<0&&(t=-t)):t=Math.round(i),t}});Wn({emitter:w2,events:["dxswipestart","dxswipe","dxswipeend"]});function kp(i){return i?Number(i.replace("px","")):0}function I2(i){var e,t;return i&&W()?(e=(t=K()).getComputedStyle)===null||e===void 0?void 0:e.call(t,i):null}function KA(i,e){let t=I2(i);return t?kp(t[`margin${or(e)}`]):0}var D2=hs();var UA=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{indicatorSrc:"",activeStateEnabled:!1,hoverStateEnabled:!1,_animatingSegmentCount:1,_animatingSegmentInner:!1})},_defaultOptionsRules(){let i=ct();return this.callBase().concat([{device(){return F.real().platform==="android"&&!/chrome/i.test(D2.userAgent)},options:{viaImage:!0}},{device:()=>pt(i),options:{_animatingSegmentCount:2,_animatingSegmentInner:!0}},{device:()=>sp(i),options:{_animatingSegmentCount:7}}])},_useTemplates:()=>!1,_init(){this.callBase(),this.$element().addClass("dx-loadindicator");let e={role:"alert",label:O.format("Loading")};this.setAria(e)},_initMarkup(){this.callBase(),this._renderWrapper(),this._renderIndicatorContent(),this._renderMarkup()},_renderWrapper(){this._$wrapper=u("<div>").addClass("dx-loadindicator-wrapper"),this.$element().append(this._$wrapper)},_renderIndicatorContent(){this._$content=u("<div>").addClass("dx-loadindicator-content"),this._$wrapper.append(this._$content)},_renderMarkup(){let{viaImage:i,indicatorSrc:e}=this.option();yh()&&!i&&!e?this._renderMarkupForAnimation():this._renderMarkupForImage()},_renderMarkupForAnimation(){let i=this.option("_animatingSegmentInner");this._$indicator=u("<div>").addClass("dx-loadindicator-icon"),this._$content.append(this._$indicator);for(let e=this.option("_animatingSegmentCount");e>=0;--e){let t=u("<div>").addClass("dx-loadindicator-segment").addClass("dx-loadindicator-segment"+e);i&&t.append(u("<div>").addClass("dx-loadindicator-segment-inner")),this._$indicator.append(t)}},_renderMarkupForImage(){let{indicatorSrc:i}=this.option();i?(this._$wrapper.addClass("dx-loadindicator-image"),this._$wrapper.css("backgroundImage",`url(${i})`)):yh()&&this._renderMarkupForAnimation()},_renderDimensions(){this.callBase(),this._updateContentSizeForAnimation()},_updateContentSizeForAnimation(){if(!this._$indicator)return;let i=this.option("width"),e=this.option("height");if(i||e){i=z(this.$element()),e=Y(this.$element());let t=Math.min(e,i);this._$wrapper.css({height:t,width:t,fontSize:t})}},_clean(){this.callBase(),this._removeMarkupForAnimation(),this._removeMarkupForImage()},_removeMarkupForAnimation(){this._$indicator&&(this._$indicator.remove(),delete this._$indicator)},_removeMarkupForImage(){this._$wrapper.css("backgroundImage","none")},_optionChanged(i){switch(i.name){case"_animatingSegmentCount":case"_animatingSegmentInner":case"indicatorSrc":this._invalidate();break;default:this.callBase(i)}}});G("dxLoadIndicator",UA);var jA=UA;var ni=jA;var qA=Ni.inherit({_supportedKeys(){return m(this.callBase(),{escape:S})},_getDefaultOptions(){return m(this.callBase(),{message:O.format("Loading"),width:222,height:90,animation:null,showIndicator:!0,indicatorSrc:"",showPane:!0,delay:0,templatesRenderAsynchronously:!1,hideTopOverlayHandler:null,focusStateEnabled:!1,propagateOutsideClick:!0,preventScrollEvents:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:{platform:"generic"},options:{shadingColor:"transparent"}},{device:()=>it(),options:{message:"",width:60,height:60,maxHeight:60,maxWidth:60}},{device:()=>ut(),options:{width:"auto",height:"auto"}}])},_init(){this.callBase.apply(this,arguments)},_render(){this.callBase(),this.$element().addClass("dx-loadpanel"),this.$wrapper().addClass("dx-loadpanel-wrapper"),this._updateWrapperAria()},_updateWrapperAria(){if(this.$wrapper().removeAttr("aria-label").removeAttr("role"),!this.option("showIndicator")){let e=this._getAriaAttributes();this.$wrapper().attr(e)}},_getAriaAttributes(){let{message:i}=this.option();return{role:"alert","aria-label":i||O.format("Loading")}},_renderContentImpl(){this.callBase(),this.$content().addClass("dx-loadpanel-content"),this._$loadPanelContentWrapper=u("<div>").addClass("dx-loadpanel-content-wrapper"),this._$loadPanelContentWrapper.appendTo(this.$content()),this._togglePaneVisible(),this._cleanPreviousContent(),this._renderLoadIndicator(),this._renderMessage()},_show(){let i=this.option("delay");if(!i)return this.callBase();let e=y(),t=this.callBase.bind(this);return this._clearShowTimeout(),this._showTimeout=setTimeout(()=>{t().done(()=>{e.resolve()})},i),e.promise()},_hide(){return this._clearShowTimeout(),this.callBase()},_clearShowTimeout(){clearTimeout(this._showTimeout)},_renderMessage(){if(!this._$loadPanelContentWrapper)return;let i=this.option("message");if(!i)return;let e=u("<div>").addClass("dx-loadpanel-message").text(i);this._$loadPanelContentWrapper.append(e)},_renderLoadIndicator(){!this._$loadPanelContentWrapper||!this.option("showIndicator")||(this._$indicator||(this._$indicator=u("<div>").addClass("dx-loadpanel-indicator").appendTo(this._$loadPanelContentWrapper)),this._createComponent(this._$indicator,ni,{elementAttr:this._getAriaAttributes(),indicatorSrc:this.option("indicatorSrc")}))},_cleanPreviousContent(){this.$content().find(".dx-loadpanel-message").remove(),this.$content().find(".dx-loadpanel-indicator").remove(),delete this._$indicator},_togglePaneVisible(){this.$content().toggleClass("dx-loadpanel-pane-hidden",!this.option("showPane"))},_optionChanged(i){switch(i.name){case"delay":break;case"message":case"showIndicator":this._cleanPreviousContent(),this._renderLoadIndicator(),this._renderMessage(),this._updateWrapperAria();break;case"showPane":this._togglePaneVisible();break;case"indicatorSrc":this._renderLoadIndicator();break;default:this.callBase(i)}},_dispose(){this._clearShowTimeout(),this.callBase()}});G("dxLoadPanel",qA);var YA=qA;var Bp=YA;var Ov="dxScrollbar";var T2="dx-scrollbar-hoverable",XA="horizontal";var Ms={onScroll:"onScroll",onHover:"onHover",always:"always",never:"never"},Rl=null,A2=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{direction:null,visible:!1,activeStateEnabled:!1,visibilityMode:Ms.onScroll,containerSize:0,contentSize:0,expandable:!0,scaleRatio:1})},_init(){this.callBase(),this._isHovered=!1},_initMarkup(){this._renderThumb(),this.callBase()},_render(){this.callBase(),this._renderDirection(),this._update(),this._attachPointerDownHandler(),this.option("hoverStateEnabled",this._isHoverMode()),this.$element().toggleClass(T2,this.option("hoverStateEnabled"))},_renderThumb(){this._$thumb=u("<div>").addClass("dx-scrollable-scroll"),u("<div>").addClass("dx-scrollable-scroll-content").appendTo(this._$thumb),this.$element().addClass("dx-scrollable-scrollbar").append(this._$thumb)},isThumb(i){return!!this.$element().find(i).length},_isHoverMode(){let i=this.option("visibilityMode");return(i===Ms.onHover||i===Ms.always)&&this.option("expandable")},_renderDirection(){let i=this.option("direction");this.$element().addClass(`dx-scrollbar-${i}`),this._dimension=i===XA?"width":"height",this._prop=i===XA?"left":"top"},_attachPointerDownHandler(){_.on(this._$thumb,D(ne.down,Ov),this.feedbackOn.bind(this))},feedbackOn(i){i?.preventDefault(),this.$element().addClass("dx-scrollable-scrollbar-active"),Rl=this},feedbackOff(){this.$element().removeClass("dx-scrollable-scrollbar-active"),Rl=null},cursorEnter(){this._isHovered=!0,this._needScrollbar()&&this.option("visible",!0)},cursorLeave(){this._isHovered=!1,this.option("visible",!1)},_renderDimensions(){this._$thumb.css({width:this.option("width"),height:this.option("height")})},_toggleVisibility(i){this.option("visibilityMode")===Ms.onScroll&&this._$thumb.css("opacity"),i=this._adjustVisibility(i),this.option().visible=i,this._$thumb.toggleClass("dx-state-invisible",!i)},_adjustVisibility(i){if(this._baseContainerToContentRatio&&!this._needScrollbar())return!1;switch(this.option("visibilityMode")){case Ms.onScroll:break;case Ms.onHover:i=i||!!this._isHovered;break;case Ms.never:i=!1;break;case Ms.always:i=!0}return i},moveTo(i){if(this._isHidden())return;q(i)&&(i=i[this._prop]||0);let e={};e[this._prop]=this._calculateScrollBarPosition(i),Ae(this._$thumb,e)},_calculateScrollBarPosition(i){return-i*this._thumbRatio},_update(){let i=Math.round(this.option("containerSize")),e=Math.round(this.option("contentSize")),t=Math.round(this.option("baseContainerSize")),n=Math.round(this.option("baseContentSize"));isNaN(t)&&(t=i,n=e),this._baseContainerToContentRatio=n?t/n:t,this._realContainerToContentRatio=e?i/e:i;let o=Math.round(Math.max(Math.round(i*this._realContainerToContentRatio),15));this._thumbRatio=(i-o)/(this.option("scaleRatio")*(e-i)),this.option(this._dimension,o/this.option("scaleRatio")),this.$element().css("display",this._needScrollbar()?"":"none")},_isHidden(){return this.option("visibilityMode")===Ms.never},_needScrollbar(){return!this._isHidden()&&this._baseContainerToContentRatio<1},containerToContentRatio(){return this._realContainerToContentRatio},_normalizeSize(i){return q(i)?i[this._dimension]||0:i},_clean(){this.callBase(),this===Rl&&(Rl=null),_.off(this._$thumb,`.${Ov}`)},_optionChanged(i){if(!this._isHidden())switch(i.name){case"containerSize":case"contentSize":this.option()[i.name]=this._normalizeSize(i.value),this._update();break;case"baseContentSize":case"baseContainerSize":case"scaleRatio":this._update();break;case"visibilityMode":case"direction":this._invalidate();break;default:this.callBase.apply(this,arguments)}},update:Ao(function(){this._adjustVisibility()&&this.option("visible",!0)})});zt.add(()=>{_.subscribeGlobal(w.getDocument(),D(ne.up,Ov),()=>{Rl&&Rl.feedbackOff()})});var Vp=A2;var QA="dxNativeScrollable";var M2="dx-scrollable-scrollbar-simulated",R2="dx-scrollable-scrollbars-hidden",kc="vertical",Lp="horizontal";var F2=ce.inherit({ctor(i){this._init(i)},_init(i){this._component=i,this._$element=i.$element(),this._$container=u(i.container()),this._$content=i.$content(),this._direction=i.option("direction"),this._useSimulatedScrollbar=i.option("useSimulatedScrollbar"),this.option=i.option.bind(i),this._createActionByOption=i._createActionByOption.bind(i),this._isLocked=i._isLocked.bind(i),this._isDirection=i._isDirection.bind(i),this._allowedDirection=i._allowedDirection.bind(i),this._getMaxOffset=i._getMaxOffset.bind(i),this._isRtlNativeStrategy=i._isRtlNativeStrategy.bind(i)},render(){let e=F.real().platform;this._$element.addClass("dx-scrollable-native").addClass(`dx-scrollable-native-${e}`).toggleClass(R2,!this._isScrollbarVisible()),this._isScrollbarVisible()&&this._useSimulatedScrollbar&&this._renderScrollbars()},updateRtlPosition(i){i&&this.option("rtlEnabled")&&this._isScrollbarVisible()&&this._useSimulatedScrollbar&&this._moveScrollbars()},_renderScrollbars(){this._scrollbars={},this._hideScrollbarTimeout=0,this._$element.addClass(M2),this._renderScrollbar(kc),this._renderScrollbar(Lp)},_renderScrollbar(i){this._isDirection(i)&&(this._scrollbars[i]=new Vp(u("<div>").appendTo(this._$element),{direction:i,expandable:this._component.option("scrollByThumb")}))},handleInit:S,handleStart:S,handleMove(i){if(this._isLocked()){i.cancel=!0;return}this._allowedDirection()&&(i.originalEvent.isScrollingEvent=!0)},handleEnd:S,handleCancel:S,handleStop:S,_eachScrollbar(i){i=i.bind(this),x(this._scrollbars||{},(e,t)=>{i(t,e)})},createActions(){this._scrollAction=this._createActionByOption("onScroll"),this._updateAction=this._createActionByOption("onUpdated")},_createActionArgs(){let{left:i,top:e}=this.location();return{event:this._eventForUserAction,scrollOffset:this._getScrollOffset(),reachedLeft:this._isRtlNativeStrategy()?this._isReachedRight(-i):this._isReachedLeft(i),reachedRight:this._isRtlNativeStrategy()?this._isReachedLeft(-Math.abs(i)):this._isReachedRight(i),reachedTop:this._isDirection(kc)?Math.round(e)>=0:void 0,reachedBottom:this._isDirection(kc)?Math.round(Math.abs(e)-this._getMaxOffset().top)>=0:void 0}},_getScrollOffset(){let{top:i,left:e}=this.location();return{top:-i,left:this._normalizeOffsetLeft(-e)}},_normalizeOffsetLeft(i){return this._isRtlNativeStrategy()?this._getMaxOffset().left+i:i},_isReachedLeft(i){return this._isDirection(Lp)?Math.round(i)>=0:void 0},_isReachedRight(i){return this._isDirection(Lp)?Math.round(Math.abs(i)-this._getMaxOffset().left)>=0:void 0},_isScrollbarVisible(){let{showScrollbar:i}=this.option();return i!=="never"&&i!==!1},handleScroll(i){this._eventForUserAction=i,this._moveScrollbars(),this._scrollAction(this._createActionArgs())},_moveScrollbars(){let{top:i,left:e}=this._getScrollOffset();this._eachScrollbar(t=>{t.moveTo({top:-i,left:-e}),t.option("visible",!0)}),this._hideScrollbars()},_hideScrollbars(){clearTimeout(this._hideScrollbarTimeout),this._hideScrollbarTimeout=setTimeout(()=>{this._eachScrollbar(i=>{i.option("visible",!1)})},500)},location(){return{left:-this._$container.scrollLeft(),top:-this._$container.scrollTop()}},disabledChanged:S,update(){this._update(),this._updateAction(this._createActionArgs())},_update(){this._updateDimensions(),this._updateScrollbars()},_updateDimensions(){this._containerSize={height:Y(this._$container),width:z(this._$container)},this._componentContentSize={height:Y(this._component.$content()),width:z(this._component.$content())},this._contentSize={height:Y(this._$content),width:z(this._$content)}},_updateScrollbars(){this._eachScrollbar(function(i,e){let t=e===kc?"height":"width";i.option({containerSize:this._containerSize[t],contentSize:this._componentContentSize[t]}),i.update()})},_allowedDirections(){return{vertical:this._isDirection(kc)&&this._contentSize.height>this._containerSize.height,horizontal:this._isDirection(Lp)&&this._contentSize.width>this._containerSize.width}},dispose(){let{className:i}=this._$element.get(0),e=new RegExp("dx-scrollable-native\\S*","g");e.test(i)&&this._$element.removeClass(i.match(e).join(" ")),_.off(this._$element,`.${QA}`),_.off(this._$container,`.${QA}`),this._removeScrollbars(),clearTimeout(this._hideScrollbarTimeout)},_removeScrollbars(){this._eachScrollbar(i=>{i.$element().remove()})},scrollBy(i){let e=this.location();this._$container.scrollTop(Math.round(-e.top-i.top)),this._$container.scrollLeft(Math.round(-e.left-i.left))},validate(i){return this.option("disabled")||Ut(i)&&this._isScrolledInMaxDirection(i)?!1:!!this._allowedDirection()},_isScrolledInMaxDirection(i){let e=this._$container.get(0),t;return i.delta>0?t=i.shiftKey?!e.scrollLeft:!e.scrollTop:i.shiftKey?t=e.scrollLeft>=this._getMaxOffset().left:t=e.scrollTop>=this._getMaxOffset().top,t},getDirection(){return this._allowedDirection()}}),Fl=F2;var P2=Fl.inherit({_init(i){this.callBase(i),this._$topPocket=i._$topPocket,this._$pullDown=i._$pullDown,this._$refreshingText=i._$refreshingText,this._$scrollViewContent=u(i.content()),this._$container=u(i.container()),this._initCallbacks()},_initCallbacks(){this.pullDownCallbacks=ue(),this.releaseCallbacks=ue(),this.reachBottomCallbacks=ue()},render(){this.callBase(),this._renderPullDown(),this._releaseState()},_renderPullDown(){let i=u("<div>").addClass("dx-scrollview-pull-down-image"),e=u("<div>").addClass("dx-scrollview-pull-down-indicator"),t=new ni(u("<div>")).$element(),n=this._$pullDownText=u("<div>").addClass("dx-scrollview-pull-down-text");this._$pullingDownText=u("<div>").text(this.option("pullingDownText")).appendTo(n),this._$pulledDownText=u("<div>").text(this.option("pulledDownText")).appendTo(n),this._$refreshingText=u("<div>").text(this.option("refreshingText")).appendTo(n),this._$pullDown.empty().append(i).append(e.append(t)).append(n)},_releaseState(){this._state=0,this._refreshPullDownText()},_refreshPullDownText(){let i=this,e=[{element:this._$pullingDownText,visibleState:0},{element:this._$pulledDownText,visibleState:1},{element:this._$refreshingText,visibleState:2}];x(e,(t,n)=>{let o=i._state===n.visibleState?"addClass":"removeClass";n.element[o]("dx-scrollview-pull-down-text-visible")})},update(){this.callBase(),this._setTopPocketOffset()},_updateDimensions(){this.callBase(),this._topPocketSize=this._$topPocket.get(0).clientHeight;let i=this._$scrollViewContent.get(0),e=this._$container.get(0);this._bottomBoundary=Math.max(i.clientHeight-e.clientHeight,0)},_allowedDirections(){let i=this.callBase();return i.vertical=i.vertical||this._pullDownEnabled,i},_setTopPocketOffset(){this._$topPocket.css({top:-this._topPocketSize})},handleEnd(){this.callBase(),this._complete()},handleStop(){this.callBase(),this._complete()},_complete(){this._state===1&&(this._setPullDownOffset(this._topPocketSize),clearTimeout(this._pullDownRefreshTimeout),this._pullDownRefreshTimeout=setTimeout(()=>{this._pullDownRefreshing()},400))},_setPullDownOffset(i){Ae(this._$topPocket,{top:i}),Ae(this._$scrollViewContent,{top:i})},handleScroll(i){if(this.callBase(i),this._state===2)return;let e=this.location().top,t=(this._location||0)-e;this._location=e,this._isPullDown()?this._pullDownReady():t>0&&this._isReachBottom()?this._reachBottom():this._stateReleased()},_isPullDown(){return this._pullDownEnabled&&this._location>=this._topPocketSize},_isReachBottom(){return this._reachBottomEnabled&&Math.round(this._bottomBoundary+Math.floor(this._location))<=1},_reachBottom(){this._state!==3&&(this._state=3,this.reachBottomCallbacks.fire())},_pullDownReady(){this._state!==1&&(this._state=1,this._$pullDown.addClass("dx-scrollview-pull-down-ready"),this._refreshPullDownText())},_stateReleased(){this._state!==0&&(this._$pullDown.removeClass("dx-scrollview-pull-down-loading").removeClass("dx-scrollview-pull-down-ready"),this._releaseState())},_pullDownRefreshing(){this._state!==2&&(this._state=2,this._$pullDown.addClass("dx-scrollview-pull-down-loading").removeClass("dx-scrollview-pull-down-ready"),this._refreshPullDownText(),this.pullDownCallbacks.fire())},pullDownEnable(i){i&&(this._updateDimensions(),this._setTopPocketOffset()),this._pullDownEnabled=i},reachBottomEnable(i){this._reachBottomEnabled=i},pendingRelease(){this._state=1},release(){let i=y();return this._updateDimensions(),clearTimeout(this._releaseTimeout),this._state===3&&(this._state=0),this._releaseTimeout=setTimeout(()=>{this._setPullDownOffset(0),this._stateReleased(),this.releaseCallbacks.fire(),this._updateAction(),i.resolve()},400),i.promise()},dispose(){clearTimeout(this._pullDownRefreshTimeout),clearTimeout(this._releaseTimeout),this.callBase()}}),ZA=P2;var k2=Fl.inherit({_init(i){this.callBase(i),this._$topPocket=i._$topPocket,this._$pullDown=i._$pullDown,this._$scrollViewContent=u(i.content()),this._$container=u(i.container()),this._initCallbacks(),this._location=0},_initCallbacks(){this.pullDownCallbacks=ue(),this.releaseCallbacks=ue(),this.reachBottomCallbacks=ue()},render(){this.callBase(),this._renderPullDown(),this._releaseState()},_renderPullDown(){let i=u("<div>").addClass("dx-scrollview-pull-down-indicator"),e=new ni(u("<div>")).$element();this._$icon=u("<div>").addClass("dx-icon-pulldown"),this._$pullDown.empty().append(this._$icon).append(i.append(e))},_releaseState(){this._state=0,this._releasePullDown(),this._updateDimensions()},_releasePullDown(){this._$pullDown.css({opacity:0})},_updateDimensions(){this.callBase(),this._topPocketSize=this._$topPocket.get(0).clientHeight;let i=this._$scrollViewContent.get(0),e=this._$container.get(0);this._bottomBoundary=Math.max(i.clientHeight-e.clientHeight,0)},_allowedDirections(){let i=this.callBase();return i.vertical=i.vertical||this._pullDownEnabled,i},handleInit(i){this.callBase(i),this._state===0&&this._location===0&&(this._startClientY=Ye(i.originalEvent).y,this._state=4)},handleMove(i){this.callBase(i),this._deltaY=Ye(i.originalEvent).y-this._startClientY,this._state===4&&(this._pullDownEnabled&&this._deltaY>0?this._state=5:this._complete()),this._state===5&&(i.preventDefault(),this._movePullDown())},_movePullDown(){let i=this._getPullDownHeight(),e=Math.min(3*i,this._deltaY+this._getPullDownStartPosition()),t=180*e/i/3;this._$pullDown.css({opacity:1}).toggleClass("dx-scrollview-pull-down-refreshing",e<i),Ae(this._$pullDown,{top:e}),this._$icon.css({transform:`rotate(${t}deg)`})},_isPullDown(){return this._pullDownEnabled&&this._state===5&&this._deltaY>=this._getPullDownHeight()-this._getPullDownStartPosition()},_getPullDownHeight(){return Math.round(.05*X(this._$element))},_getPullDownStartPosition(){return-Math.round(1.5*X(this._$pullDown))},handleEnd(){this._isPullDown()&&this._pullDownRefreshing(),this._complete()},handleStop(){this._complete()},_complete(){(this._state===4||this._state===5)&&this._releaseState()},handleScroll(i){if(this.callBase(i),this._state===2)return;let e=this.location().top,t=this._location-e;this._location=e,t>0&&this._isReachBottom()?this._reachBottom():this._stateReleased()},_isReachBottom(){return this._reachBottomEnabled&&Math.round(this._bottomBoundary+Math.floor(this._location))<=1},_reachBottom(){this.reachBottomCallbacks.fire()},_stateReleased(){this._state!==0&&(this._$pullDown.removeClass("dx-scrollview-pull-down-loading"),this._releaseState())},_pullDownRefreshing(){this._state=2,this._pullDownRefreshHandler()},_pullDownRefreshHandler(){this._refreshPullDown(),this.pullDownCallbacks.fire()},_refreshPullDown(){this._$pullDown.addClass("dx-scrollview-pull-down-loading"),Ae(this._$pullDown,{top:this._getPullDownHeight()})},pullDownEnable(i){this._$topPocket.toggle(i),this._pullDownEnabled=i},reachBottomEnable(i){this._reachBottomEnabled=i},pendingRelease(){this._state=1},release(){let i=y();return this._updateDimensions(),clearTimeout(this._releaseTimeout),this._releaseTimeout=setTimeout(()=>{this._stateReleased(),this.releaseCallbacks.fire(),this._updateAction(),i.resolve()},800),i.promise()},dispose(){clearTimeout(this._pullDownRefreshTimeout),clearTimeout(this._releaseTimeout),this.callBase()}}),JA=k2;var{abstract:B2}=ce,V2=ce.inherit({ctor(){this._finished=!0,this._stopped=!1,this._proxiedStepCore=this._stepCore.bind(this)},start(){this._stopped=!1,this._finished=!1,this._stepCore()},stop(){this._stopped=!0,On(this._stepAnimationFrame)},_stepCore(){if(this._isStopped()){this._stop();return}if(this._isFinished()){this._finished=!0,this._complete();return}this._step(),this._stepAnimationFrame=rr(this._proxiedStepCore)},_step:B2,_isFinished:S,_stop:S,_complete:S,_isStopped(){return this._stopped},inProgress(){return!(this._stopped||this._finished)}}),Np=V2;var eM="dxSimulatedScrollable",L2="dxScrollableStrategy",Hp=`${eM}Cursor`,Sv=`${eM}Keyboard`;var N2="dx-scrollable-scrollbars-alwaysvisible";var Go="vertical",Hi="horizontal";var H2=Math.round(1e3/60);var $2=400/H2,z2=(1-.92**$2)/(1-.92),Rs={PAGE_UP:"pageUp",PAGE_DOWN:"pageDown",END:"end",HOME:"home",LEFT:"leftArrow",UP:"upArrow",RIGHT:"rightArrow",DOWN:"downArrow",TAB:"tab"},tM=Np.inherit({ctor(i){this.callBase(),this.scroller=i},VELOCITY_LIMIT:1,_isFinished(){return Math.abs(this.scroller._velocity)<=this.VELOCITY_LIMIT},_step(){this.scroller._scrollStep(this.scroller._velocity),this.scroller._velocity*=this._acceleration()},_acceleration(){return this.scroller._inBounds()?.92:.5},_complete(){this.scroller._scrollComplete()}}),W2=tM.inherit({VELOCITY_LIMIT:.2,_isFinished(){return this.scroller._crossBoundOnNextStep()||this.callBase()},_acceleration:()=>.92,_complete(){this.scroller._move(this.scroller._bounceLocation),this.callBase()}}),Ev=ce.inherit({ctor(i){this._initOptions(i),this._initAnimators(),this._initScrollbar()},_initOptions(i){this._location=0,this._topReached=!1,this._bottomReached=!1,this._axis=i.direction===Hi?"x":"y",this._prop=i.direction===Hi?"left":"top",this._dimension=i.direction===Hi?"width":"height",this._scrollProp=i.direction===Hi?"scrollLeft":"scrollTop",x(i,(e,t)=>{this[`_${e}`]=t})},_initAnimators(){this._inertiaAnimator=new tM(this),this._bounceAnimator=new W2(this)},_initScrollbar(){this._scrollbar=new Vp(u("<div>").appendTo(this._$container),{direction:this._direction,visible:this._scrollByThumb,visibilityMode:this._visibilityModeNormalize(this._scrollbarVisible),expandable:this._scrollByThumb}),this._$scrollbar=this._scrollbar.$element()},_visibilityModeNormalize:i=>i===!0?"onScroll":i===!1?"never":i,_scrollStep(i){let e=this._location;this._location+=i,this._suppressBounce(),this._move(),!(Math.abs(e-this._location)<1)&&_.triggerHandler(this._$container,{type:"scroll"})},_suppressBounce(){this._bounceEnabled||this._inBounds(this._location)||(this._velocity=0,this._location=this._boundLocation())},_boundLocation(i){return i=i!==void 0?i:this._location,Math.max(Math.min(i,this._maxOffset),this._minOffset)},_move(i){this._location=i!==void 0?i*this._getScaleRatio():this._location,this._moveContent(),this._moveScrollbar()},_moveContent(){let i=this._location;this._$container[this._scrollProp](-i/this._getScaleRatio()),this._moveContentByTranslator(i)},_getScaleRatio(){if(W()&&!this._scaleRatio){let i=this._$element.get(0),e=this._getRealDimension(i,this._dimension),t=this._getBaseDimension(i,this._dimension);this._scaleRatio=Math.round(e/t*100)/100}return this._scaleRatio||1},_getRealDimension:(i,e)=>Math.round(Ie(i)[e]),_getBaseDimension(i,e){let t=`offset${or(e)}`;return i[t]},_moveContentByTranslator(i){let e,t=-this._maxScrollPropValue;if(i>0&&(e=i),i<=t&&(e=i-t),this._translateOffset===e)return;let n={};if(n[this._prop]=e,this._translateOffset=e,!e){Bo(this._$content);return}Ae(this._$content,n)},_moveScrollbar(){this._scrollbar.moveTo(this._location)},_scrollComplete(){this._inBounds()&&(this._hideScrollbar(),this._completeDeferred&&this._completeDeferred.resolve()),this._scrollToBounds()},_scrollToBounds(){this._inBounds()||(this._bounceAction(),this._setupBounce(),this._bounceAnimator.start())},_setupBounce(){let e=(this._bounceLocation=this._boundLocation())-this._location;this._velocity=e/z2},_inBounds(i){return i=i!==void 0?i:this._location,this._boundLocation(i)===i},_crossBoundOnNextStep(){let i=this._location,e=i+this._velocity;return i<this._minOffset&&e>=this._minOffset||i>this._maxOffset&&e<=this._maxOffset},_initHandler(i){this._stopScrolling(),this._prepareThumbScrolling(i)},_stopScrolling:Ao(function(){this._hideScrollbar(),this._inertiaAnimator.stop(),this._bounceAnimator.stop()}),_prepareThumbScrolling(i){if(Ut(i.originalEvent))return;let e=u(i.originalEvent.target),t=this._isScrollbar(e);t&&this._moveToMouseLocation(i),this._thumbScrolling=t||this._isThumb(e),this._crossThumbScrolling=!this._thumbScrolling&&this._isAnyThumbScrolling(e),this._thumbScrolling&&this._scrollbar.feedbackOn()},_isThumbScrollingHandler(i){return this._isThumb(i)},_moveToMouseLocation(i){let e=i[`page${this._axis.toUpperCase()}`]-this._$element.offset()[this._prop],t=this._location+e/this._containerToContentRatio()-Y(this._$container)/2;this._scrollStep(-Math.round(t))},_startHandler(){this._showScrollbar()},_moveHandler(i){this._crossThumbScrolling||(this._thumbScrolling&&(i[this._axis]=-Math.round(i[this._axis]/this._containerToContentRatio())),this._scrollBy(i))},_scrollBy(i){i=i[this._axis],this._inBounds()||(i*=.5),this._scrollStep(i)},_scrollByHandler(i){!i.x&&!i.y||(this._scrollBy(i),this._scrollComplete())},_containerToContentRatio(){return this._scrollbar.containerToContentRatio()},_endHandler(i){return this._completeDeferred=y(),this._velocity=i[this._axis],this._inertiaHandler(),this._resetThumbScrolling(),this._completeDeferred.promise()},_inertiaHandler(){this._suppressInertia(),this._inertiaAnimator.start()},_suppressInertia(){(!this._inertiaEnabled||this._thumbScrolling)&&(this._velocity=0)},_resetThumbScrolling(){this._thumbScrolling=!1,this._crossThumbScrolling=!1},_stopHandler(){this._thumbScrolling&&this._scrollComplete(),this._resetThumbScrolling(),this._scrollToBounds()},_disposeHandler(){this._stopScrolling(),this._$scrollbar.remove()},_updateHandler(){this._update(),this._moveToBounds()},_update(){return this._stopScrolling(),Jt(()=>{this._resetScaleRatio(),this._updateLocation(),this._updateBounds(),this._updateScrollbar(),nt(()=>{this._moveScrollbar(),this._scrollbar.update()})})},_resetScaleRatio(){this._scaleRatio=null},_updateLocation(){this._location=(li(this._$content)[this._prop]-this._$container[this._scrollProp]())*this._getScaleRatio()},_updateBounds(){this._maxOffset=this._getMaxOffset(),this._minOffset=this._getMinOffset()},_getMaxOffset:()=>0,_getMinOffset(){return this._maxScrollPropValue=Math.max(this._contentSize()-this._containerSize(),0),-this._maxScrollPropValue},_updateScrollbar:If(function(){let i=this._containerSize(),e=this._contentSize(),t=this._getBaseDimension(this._$container.get(0),this._dimension),n=this._getBaseDimension(this._$content.get(0),this._dimension);nt(()=>{this._scrollbar.option({containerSize:i,contentSize:e,baseContainerSize:t,baseContentSize:n,scaleRatio:this._getScaleRatio()})})}),_moveToBounds:Ao(If(Ao(function(){let i=this._boundLocation(),e=i!==this._location;this._location=i,this._move(),e&&this._scrollAction()}))),_createActionsHandler(i){this._scrollAction=i.scroll,this._bounceAction=i.bounce},_showScrollbar(){this._scrollbar.option("visible",!0)},_hideScrollbar(){this._scrollbar.option("visible",!1)},_containerSize(){return this._getRealDimension(this._$container.get(0),this._dimension)},_contentSize(){let i=this._$content.css(`overflow${this._axis.toUpperCase()}`)==="hidden",e=this._getRealDimension(this._$content.get(0),this._dimension);if(!i){let t=this._$content[0][`scroll${or(this._dimension)}`]*this._getScaleRatio();e=Math.max(t,e)}return e},_validateEvent(i){let e=u(i.originalEvent.target);return this._isThumb(e)||this._isScrollbar(e)},_isThumb(i){return this._scrollByThumb&&this._scrollbar.isThumb(i)},_isScrollbar(i){return this._scrollByThumb&&i&&i.is(this._$scrollbar)},_reachedMin(){return Math.round(this._location-this._minOffset)<=0},_reachedMax(){return Math.round(this._location-this._maxOffset)>=0},_cursorEnterHandler(){this._resetScaleRatio(),this._updateScrollbar(),this._scrollbar.cursorEnter()},_cursorLeaveHandler(){this._scrollbar.cursorLeave()},dispose:S}),yo,Pl,$p=ce.inherit({ctor(i){this._init(i)},_init(i){this._component=i,this._$element=i.$element(),this._$container=u(i.container()),this._$wrapper=i._$wrapper,this._$content=i.$content(),this.option=i.option.bind(i),this._createActionByOption=i._createActionByOption.bind(i),this._isLocked=i._isLocked.bind(i),this._isDirection=i._isDirection.bind(i),this._allowedDirection=i._allowedDirection.bind(i),this._getMaxOffset=i._getMaxOffset.bind(i)},render(){this._$element.addClass("dx-scrollable-simulated"),this._createScrollers(),this.option("useKeyboard")&&this._$container.prop("tabIndex",0),this._attachKeyboardHandler(),this._attachCursorHandlers()},_createScrollers(){this._scrollers={},this._isDirection(Hi)&&this._createScroller(Hi),this._isDirection(Go)&&this._createScroller(Go),this._$element.toggleClass(N2,this.option("showScrollbar")==="always")},_createScroller(i){this._scrollers[i]=new Ev(this._scrollerOptions(i))},_scrollerOptions(i){return{direction:i,$content:this._$content,$container:this._$container,$wrapper:this._$wrapper,$element:this._$element,scrollByThumb:this.option("scrollByThumb"),scrollbarVisible:this.option("showScrollbar"),bounceEnabled:this.option("bounceEnabled"),inertiaEnabled:this.option("inertiaEnabled"),isAnyThumbScrolling:this._isAnyThumbScrolling.bind(this)}},_applyScaleRatio(i){for(let e in this._scrollers){let t=this._getPropByDirection(e);if(f(i[t])){let n=this._scrollers[e];i[t]*=n._getScaleRatio()}}return i},_isAnyThumbScrolling(i){let e=!1;return this._eventHandler("isThumbScrolling",i).done((t,n)=>{e=t||n}),e},handleInit(i){this._suppressDirections(i),this._eventForUserAction=i,this._eventHandler("init",i)},_suppressDirections(i){if(Ut(i.originalEvent)){this._prepareDirections(!0);return}this._prepareDirections(),this._eachScroller(function(e,t){let n=u(i.originalEvent.target),o=e._validateEvent(i)||this.option("scrollByContent")&&this._isContent(n);this._validDirections[t]=o})},_isContent(i){return!!i.closest(this._$element).length},_prepareDirections(i){i=i||!1,this._validDirections={},this._validDirections[Hi]=i,this._validDirections[Go]=i},_eachScroller(i){i=i.bind(this),x(this._scrollers,(e,t)=>{i(t,e)})},handleStart(i){this._eventForUserAction=i,this._eventHandler("start").done(this._startAction)},_saveActive(){Pl=this},_resetActive(){Pl===this&&(Pl=null)},handleMove(i){if(this._isLocked()){i.cancel=!0,this._resetActive();return}this._saveActive(),i.preventDefault&&i.preventDefault(),this._adjustDistance(i,i.delta),this._eventForUserAction=i,this._eventHandler("move",i.delta)},_adjustDistance(i,e){e.x*=this._validDirections[Hi],e.y*=this._validDirections[Go];let t=this._tryGetDevicePixelRatio();t&&Ut(i.originalEvent)&&(e.x=Math.round(e.x/t*100)/100,e.y=Math.round(e.y/t*100)/100)},_tryGetDevicePixelRatio(){if(W())return K().devicePixelRatio},handleEnd(i){return this._resetActive(),this._refreshCursorState(i.originalEvent&&i.originalEvent.target),this._adjustDistance(i,i.velocity),this._eventForUserAction=i,this._eventHandler("end",i.velocity).done(this._endAction)},handleCancel(i){return this._resetActive(),this._eventForUserAction=i,this._eventHandler("end",{x:0,y:0})},handleStop(){this._resetActive(),this._eventHandler("stop")},handleScroll(){this._updateRtlConfig(),this._scrollAction()},_attachKeyboardHandler(){_.off(this._$element,`.${Sv}`),!this.option("disabled")&&this.option("useKeyboard")&&_.on(this._$element,D("keydown",Sv),this._keyDownHandler.bind(this))},_keyDownHandler(i){if(clearTimeout(this._updateHandlerTimeout),this._updateHandlerTimeout=setTimeout(()=>{De(i)===Rs.TAB&&this._eachScroller(t=>{t._updateHandler()})}),!this._$container.is(w.getActiveElement(this._$container.get(0))))return;let e=!0;switch(De(i)){case Rs.DOWN:this._scrollByLine({y:1});break;case Rs.UP:this._scrollByLine({y:-1});break;case Rs.RIGHT:this._scrollByLine({x:1});break;case Rs.LEFT:this._scrollByLine({x:-1});break;case Rs.PAGE_DOWN:this._scrollByPage(1);break;case Rs.PAGE_UP:this._scrollByPage(-1);break;case Rs.HOME:this._scrollToHome();break;case Rs.END:this._scrollToEnd();break;default:e=!1}e&&(i.stopPropagation(),i.preventDefault())},_scrollByLine(i){let e=this._tryGetDevicePixelRatio(),t=40;e&&(t=Math.abs(t/e*100)/100),this.scrollBy({top:(i.y||0)*-t,left:(i.x||0)*-t})},_scrollByPage(i){let e=this._wheelProp(),t=this._dimensionByProp(e),n={},o=t==="width"?z:Y;n[e]=i*-o(this._$container),this.scrollBy(n)},_dimensionByProp:i=>i==="left"?"width":"height",_getPropByDirection:i=>i===Hi?"left":"top",_scrollToHome(){let i=this._wheelProp(),e={};e[i]=0,this._component.scrollTo(e)},_scrollToEnd(){let i=this._wheelProp(),e=this._dimensionByProp(i),t={},n=e==="width"?z:Y;t[i]=n(this._$content)-n(this._$container),this._component.scrollTo(t)},createActions(){this._startAction=this._createActionHandler("onStart"),this._endAction=this._createActionHandler("onEnd"),this._updateAction=this._createActionHandler("onUpdated"),this._createScrollerActions()},_createScrollerActions(){this._scrollAction=this._createActionHandler("onScroll"),this._bounceAction=this._createActionHandler("onBounce"),this._eventHandler("createActions",{scroll:this._scrollAction,bounce:this._bounceAction})},_createActionHandler(i){let e=this._createActionByOption(i);return()=>{e(m(this._createActionArgs(),arguments))}},_createActionArgs(){let{horizontal:i,vertical:e}=this._scrollers,t=this._getScrollOffset();return this._scrollOffset={top:e&&t.top,left:i&&t.left},{event:this._eventForUserAction,scrollOffset:this._scrollOffset,reachedLeft:i&&i._reachedMax(),reachedRight:i&&i._reachedMin(),reachedTop:e&&e._reachedMax(),reachedBottom:e&&e._reachedMin()}},_getScrollOffset(){return{top:-this.location().top,left:-this.location().left}},_eventHandler(i){let e=[].slice.call(arguments).slice(1),t=He(this._scrollers,n=>n[`_${i}Handler`].apply(n,e));return P.apply(u,t).promise()},location(){let i=li(this._$content);return i.top-=this._$container.scrollTop(),i.left-=this._$container.scrollLeft(),i},disabledChanged(){this._attachCursorHandlers()},_attachCursorHandlers(){_.off(this._$element,`.${Hp}`),!this.option("disabled")&&this._isHoverMode()&&(_.on(this._$element,D("mouseenter",Hp),this._cursorEnterHandler.bind(this)),_.on(this._$element,D("mouseleave",Hp),this._cursorLeaveHandler.bind(this)))},_isHoverMode(){return this.option("showScrollbar")==="onHover"},_cursorEnterHandler(i){i=i||{},i.originalEvent=i.originalEvent||{},!(Pl||i.originalEvent._hoverHandled)&&(yo&&yo._cursorLeaveHandler(),yo=this,this._eventHandler("cursorEnter"),i.originalEvent._hoverHandled=!0)},_cursorLeaveHandler(i){yo!==this||Pl===yo||(this._eventHandler("cursorLeave"),yo=null,this._refreshCursorState(i&&i.relatedTarget))},_refreshCursorState(i){if(!this._isHoverMode()&&(!i||Pl))return;let t=u(i).closest(".dx-scrollable-simulated:not(.dx-state-disabled)"),n=t.length&&t.data(L2);yo&&yo!==n&&yo._cursorLeaveHandler(),n&&n._cursorEnterHandler()},update(){let i=this._eventHandler("update").done(this._updateAction);return P(i,Jt(()=>{let e=this._allowedDirections();return nt(()=>{let t=e.vertical?"pan-x":"";t=e.horizontal?"pan-y":t,t=e.vertical&&e.horizontal?"none":t,this._$container.css("touchAction",t)}),P().promise()}))},_allowedDirections(){let i=this.option("bounceEnabled"),e=this._scrollers[Go],t=this._scrollers[Hi];return{vertical:e&&(e._minOffset<0||i),horizontal:t&&(t._minOffset<0||i)}},_updateBounds(){this._scrollers[Hi]&&this._scrollers[Hi]._updateBounds()},_isHorizontalAndRtlEnabled(){return this.option("rtlEnabled")&&this.option("direction")!==Go},updateRtlPosition(i){if(i&&(this._rtlConfig={scrollRight:0,clientWidth:this._$container.get(0).clientWidth,windowPixelRatio:this._getWindowDevicePixelRatio()}),this._updateBounds(),this._isHorizontalAndRtlEnabled()){let e=this._getMaxOffset().left-this._rtlConfig.scrollRight;e<=0&&(e=0,this._rtlConfig.scrollRight=this._getMaxOffset().left),this._getScrollOffset().left!==e&&(this._rtlConfig.skipUpdating=!0,this._component.scrollTo({left:e}),this._rtlConfig.skipUpdating=!1)}},_updateRtlConfig(){if(this._isHorizontalAndRtlEnabled()&&!this._rtlConfig.skipUpdating){let{clientWidth:i,scrollLeft:e}=this._$container.get(0),t=this._getWindowDevicePixelRatio();this._rtlConfig.windowPixelRatio===t&&this._rtlConfig.clientWidth===i&&(this._rtlConfig.scrollRight=this._getMaxOffset().left-e),this._rtlConfig.clientWidth=i,this._rtlConfig.windowPixelRatio=t}},_getWindowDevicePixelRatio:()=>W()?K().devicePixelRatio:1,scrollBy(i){let e=this._scrollers[Go],t=this._scrollers[Hi];e&&(i.top=e._boundLocation(i.top+e._location)-e._location),t&&(i.left=t._boundLocation(i.left+t._location)-t._location),this._prepareDirections(!0),this._startAction(),this._eventHandler("scrollBy",{x:i.left,y:i.top}),this._endAction(),this._updateRtlConfig()},validate(i){return Ut(i)&&ot(i)||this.option("disabled")?!1:this.option("bounceEnabled")?!0:Ut(i)?this._validateWheel(i):this._validateMove(i)},_validateWheel(i){let e=this._scrollers[this._wheelDirection(i)],t=e._reachedMin(),n=e._reachedMax(),o=!t||!n,s=!t&&!n,r=t&&i.delta>0,a=n&&i.delta<0,l=o&&(s||r||a);return l=l||this._validateWheelTimer!==void 0,l&&(clearTimeout(this._validateWheelTimer),this._validateWheelTimer=setTimeout(()=>{this._validateWheelTimer=void 0},500)),l},_validateMove(i){return!this.option("scrollByContent")&&!u(i.target).closest(".dx-scrollable-scrollbar").length?!1:this._allowedDirection()},getDirection(i){return Ut(i)?this._wheelDirection(i):this._allowedDirection()},_wheelProp(){return this._wheelDirection()===Hi?"left":"top"},_wheelDirection(i){switch(this.option("direction")){case Hi:return Hi;case Go:return Go;default:return i&&i.shiftKey?Hi:Go}},dispose(){this._resetActive(),yo===this&&(yo=null),this._eventHandler("dispose"),this._detachEventHandlers(),this._$element.removeClass("dx-scrollable-simulated"),this._eventForUserAction=null,clearTimeout(this._validateWheelTimer),clearTimeout(this._updateHandlerTimeout)},_detachEventHandlers(){_.off(this._$element,`.${Hp}`),_.off(this._$container,`.${Sv}`)}});var G2=Math;var K2=Ev.inherit({ctor(){this._topPocketSize=0,this._bottomPocketSize=0,this.callBase.apply(this,arguments),this._initCallbacks(),this._releaseState()},_releaseState(){this._state=0,this._refreshPullDownText()},_refreshPullDownText(){let i=this,e=[{element:this._$pullingDownText,visibleState:0},{element:this._$pulledDownText,visibleState:1},{element:this._$refreshingText,visibleState:2}];x(e,(t,n)=>{let o=i._state===n.visibleState?"addClass":"removeClass";n.element[o]("dx-scrollview-pull-down-text-visible")})},_initCallbacks(){this.pullDownCallbacks=ue(),this.releaseCallbacks=ue(),this.reachBottomCallbacks=ue()},_updateBounds(){if(this._direction!=="horizontal"){this._topPocketSize=this._$topPocket.get(0).clientHeight,this._bottomPocketSize=this._$bottomPocket.get(0).clientHeight;let e=this._$container.get(0),t=this._$content.get(0);this._bottomBoundary=Math.max(t.clientHeight-this._bottomPocketSize-e.clientHeight,0)}this.callBase()},_updateScrollbar(){this._scrollbar.option({containerSize:this._containerSize(),contentSize:this._contentSize()-this._topPocketSize-this._bottomPocketSize,scaleRatio:this._getScaleRatio()})},_moveContent(){this.callBase(),this._isPullDown()?this._pullDownReady():this._isReachBottom()?this._reachBottomReady():this._state!==0&&this._stateReleased()},_moveScrollbar(){this._scrollbar.moveTo(this._topPocketSize+this._location)},_isPullDown(){return this._pullDownEnabled&&this._location>=0},_isReachBottom(){let i=this._$container.get(0);return this._reachBottomEnabled&&Math.round(this._bottomBoundary-Math.ceil(i.scrollTop))<=1},_scrollComplete(){this._inBounds()&&this._state===1?this._pullDownRefreshing():this._inBounds()&&this._state===3?this._reachBottomLoading():this.callBase()},_reachBottomReady(){this._state!==3&&(this._state=3,this._minOffset=this._getMinOffset())},_getMaxOffset(){return-this._topPocketSize},_getMinOffset(){return G2.min(this.callBase(),-this._topPocketSize)},_reachBottomLoading(){this.reachBottomCallbacks.fire()},_pullDownReady(){this._state!==1&&(this._state=1,this._maxOffset=0,this._$pullDown.addClass("dx-scrollview-pull-down-ready"),this._refreshPullDownText())},_stateReleased(){this._state!==0&&(this._releaseState(),this._updateBounds(),this._$pullDown.removeClass("dx-scrollview-pull-down-loading").removeClass("dx-scrollview-pull-down-ready"),this.releaseCallbacks.fire())},_pullDownRefreshing(){this._state!==2&&(this._state=2,this._$pullDown.addClass("dx-scrollview-pull-down-loading").removeClass("dx-scrollview-pull-down-ready"),this._refreshPullDownText(),this.pullDownCallbacks.fire())},_releaseHandler(){return this._state===0&&this._moveToBounds(),this._update(),this._releaseTask&&this._releaseTask.abort(),this._releaseTask=Ua(this._release.bind(this)),this._releaseTask.promise},_release(){this._stateReleased(),this._scrollComplete()},_reachBottomEnablingHandler(i){this._reachBottomEnabled!==i&&(this._reachBottomEnabled=i,this._updateBounds())},_pullDownEnablingHandler(i){this._pullDownEnabled!==i&&(this._pullDownEnabled=i,this._considerTopPocketChange(),this._updateHandler())},_considerTopPocketChange(){this._location-=Y(this._$topPocket)||-this._topPocketSize,this._maxOffset=0,this._move()},_pendingReleaseHandler(){this._state=1},dispose(){this._releaseTask&&this._releaseTask.abort(),this.callBase()}}),U2=$p.inherit({_init(i){this.callBase(i),this._$pullDown=i._$pullDown,this._$topPocket=i._$topPocket,this._$bottomPocket=i._$bottomPocket,this._initCallbacks()},_initCallbacks(){this.pullDownCallbacks=ue(),this.releaseCallbacks=ue(),this.reachBottomCallbacks=ue()},render(){this._renderPullDown(),this.callBase()},_renderPullDown(){let i=u("<div>").addClass("dx-scrollview-pull-down-image"),e=u("<div>").addClass("dx-scrollview-pull-down-indicator"),t=new ni(u("<div>")).$element(),n=this._$pullDownText=u("<div>").addClass("dx-scrollview-pull-down-text");this._$pullingDownText=u("<div>").text(this.option("pullingDownText")).appendTo(n),this._$pulledDownText=u("<div>").text(this.option("pulledDownText")).appendTo(n),this._$refreshingText=u("<div>").text(this.option("refreshingText")).appendTo(n),this._$pullDown.empty().append(i).append(e.append(t)).append(n)},pullDownEnable(i){this._eventHandler("pullDownEnabling",i)},reachBottomEnable(i){this._eventHandler("reachBottomEnabling",i)},_createScroller(i){let e=this,t=e._scrollers[i]=new K2(e._scrollerOptions(i));t.pullDownCallbacks.add(()=>{e.pullDownCallbacks.fire()}),t.releaseCallbacks.add(()=>{e.releaseCallbacks.fire()}),t.reachBottomCallbacks.add(()=>{e.reachBottomCallbacks.fire()})},_scrollerOptions(i){return m(this.callBase(i),{$topPocket:this._$topPocket,$bottomPocket:this._$bottomPocket,$pullDown:this._$pullDown,$pullDownText:this._$pullDownText,$pullingDownText:this._$pullingDownText,$pulledDownText:this._$pulledDownText,$refreshingText:this._$refreshingText})},pendingRelease(){this._eventHandler("pendingRelease")},release(){return this._eventHandler("release").done(this._updateAction)},location(){let i=this.callBase();return i.top+=Y(this._$topPocket),i},dispose(){x(this._scrollers,function(){this.dispose()}),this.callBase()}}),iM=U2;function zp(i,e){let t={left:0,top:0},n=e;for(;(o=n)!==null&&o!==void 0&&o.offsetParent&&!n.classList.contains(i);){var o;let s=n.offsetParent,r=n.getBoundingClientRect(),a=s.getBoundingClientRect();t.left+=r.left-a.left,t.top+=r.top-a.top,n=n.offsetParent}return t}var pa="vertical",Wp="horizontal",Gp="both";var Kp="dx-scrollable-content";function nM(i,e,t,n,o){let s=I({top:0,left:0,right:0,bottom:0},o),r=e===pa,a=r?"top":"left",l=r?"bottom":"right",d=r?"height":"width",c=t[`offset${or(d)}`],h=t[`client${or(d)}`],p=t.getBoundingClientRect()[d],g=i.getBoundingClientRect()[d],C=1;Math.abs(p-c)>1&&(C=p/c);let v=zp(Kp,i)[a]/C,b=n[a],T=b-v+s[a],R=b-v-g/C+h-s[l];return T<=0&&R>=0?b:b-(Math.abs(T)>Math.abs(R)?R:T)}var Up=function(){return[{device:()=>!Hn,options:{useNative:!1}},{device:i=>!F.isSimulator()&&F.real().deviceType==="desktop"&&i.platform==="generic",options:{bounceEnabled:!1,scrollByThumb:!0,scrollByContent:Nn,showScrollbar:"onHover"}}]};var Uo="dxScrollable",j2="dxScrollableStrategy";var Ko="vertical",Fs="horizontal",wv="both",Iv=Qi.inherit({_getDefaultOptions(){return m(this.callBase(),{disabled:!1,onScroll:null,direction:Ko,showScrollbar:"onScroll",useNative:!0,bounceEnabled:!0,scrollByContent:!0,scrollByThumb:!1,onUpdated:null,onStart:null,onEnd:null,onBounce:null,useSimulatedScrollbar:!1,useKeyboard:!0,inertiaEnabled:!0,updateManually:!1,_onVisibilityChanged:S})},_defaultOptionsRules(){return this.callBase().concat(Up(),[{device:()=>Hn&&F.real().platform==="android"&&!be.mozilla,options:{useSimulatedScrollbar:!0}}])},_initOptions(i){this.callBase(i),"useSimulatedScrollbar"in i||this._setUseSimulatedScrollbar()},_setUseSimulatedScrollbar(){this.initialOption("useSimulatedScrollbar")||this.option("useSimulatedScrollbar",!this.option("useNative"))},_init(){this.callBase(),this._initScrollableMarkup(),this._locked=!1},_visibilityChanged(i){i?(this.update(),this._updateRtlPosition(),this._savedScrollOffset&&this.scrollTo(this._savedScrollOffset),delete this._savedScrollOffset,this.option("_onVisibilityChanged")(this)):this._savedScrollOffset=this.scrollOffset()},_initScrollableMarkup(){let i=this.$element().addClass("dx-scrollable"),e=this._$container=u("<div>").addClass("dx-scrollable-container"),t=this._$wrapper=u("<div>").addClass("dx-scrollable-wrapper");(this._$content=u("<div>").addClass("dx-scrollable-content")).append(i.contents()).appendTo(e),e.appendTo(t),t.appendTo(i)},_dimensionChanged(){this.update(),this._updateRtlPosition()},_initMarkup(){this.callBase(),this._renderDirection()},_render(){this._renderStrategy(),this._attachEventHandlers(),this._renderDisabledState(),this._createActions(),this.update(),this.callBase(),this._updateRtlPosition(!0)},_updateRtlPosition(i){this._strategy.updateRtlPosition(i)},_getMaxOffset(){let{scrollWidth:i,clientWidth:e,scrollHeight:t,clientHeight:n}=u(this.container()).get(0);return{left:i-e,top:t-n}},_attachEventHandlers(){let i=this._strategy,e={getDirection:i.getDirection.bind(i),validate:this._validate.bind(this),isNative:this.option("useNative"),scrollTarget:this._$container};_.off(this._$wrapper,`.${Uo}`),_.on(this._$wrapper,D(Li.init,Uo),e,this._initHandler.bind(this)),_.on(this._$wrapper,D(Li.start,Uo),i.handleStart.bind(i)),_.on(this._$wrapper,D(Li.move,Uo),i.handleMove.bind(i)),_.on(this._$wrapper,D(Li.end,Uo),i.handleEnd.bind(i)),_.on(this._$wrapper,D(Li.cancel,Uo),i.handleCancel.bind(i)),_.on(this._$wrapper,D(Li.stop,Uo),i.handleStop.bind(i)),_.off(this._$container,`.${Uo}`),_.on(this._$container,D("scroll",Uo),i.handleScroll.bind(i))},_validate(i){return this._isLocked()?!1:(this._updateIfNeed(),this._moveIsAllowed(i))},_moveIsAllowed(i){return this._strategy.validate(i)},handleMove(i){this._strategy.handleMove(i)},_prepareDirections(i){this._strategy._prepareDirections(i)},_initHandler(){let i=this._strategy;i.handleInit.apply(i,arguments)},_renderDisabledState(){this.$element().toggleClass("dx-scrollable-disabled",this.option("disabled")),this.option("disabled")?this._lock():this._unlock()},_renderDirection(){this.$element().removeClass(`dx-scrollable-${Fs}`).removeClass(`dx-scrollable-${Ko}`).removeClass(`dx-scrollable-${wv}`).addClass(`dx-scrollable-${this.option("direction")}`)},_renderStrategy(){this._createStrategy(),this._strategy.render(),this.$element().data(j2,this._strategy)},_createStrategy(){this._strategy=this.option("useNative")?new Fl(this):new $p(this)},_createActions(){this._strategy&&this._strategy.createActions()},_clean(){this._strategy&&this._strategy.dispose()},_optionChanged(i){switch(i.name){case"onStart":case"onEnd":case"onUpdated":case"onScroll":case"onBounce":this._createActions();break;case"direction":this._resetInactiveDirection(),this._invalidate();break;case"useNative":this._setUseSimulatedScrollbar(),this._invalidate();break;case"inertiaEnabled":case"scrollByThumb":case"bounceEnabled":case"useKeyboard":case"showScrollbar":case"useSimulatedScrollbar":this._invalidate();break;case"disabled":this._renderDisabledState(),this._strategy&&this._strategy.disabledChanged();break;case"updateManually":case"scrollByContent":case"_onVisibilityChanged":break;case"width":this.callBase(i),this._updateRtlPosition();break;default:this.callBase(i)}},_resetInactiveDirection(){let i=this._getInactiveProp();if(!i||!W())return;let e=this.scrollOffset();e[i]=0,this.scrollTo(e)},_getInactiveProp(){let i=this.option("direction");if(i===Ko)return"left";if(i===Fs)return"top"},_location(){return this._strategy.location()},_normalizeLocation(i){if(q(i)){let t=Te(i.left,i.x),n=Te(i.top,i.y);return{left:f(t)?-t:void 0,top:f(n)?-n:void 0}}let e=this.option("direction");return{left:e!==Ko?-i:void 0,top:e!==Fs?-i:void 0}},_isLocked(){return this._locked},_lock(){this._locked=!0},_unlock(){this.option("disabled")||(this._locked=!1)},_isDirection(i){let e=this.option("direction");return i===Ko?e!==Fs:i===Fs?e!==Ko:e===i},_updateAllowedDirection(){let i=this._strategy._allowedDirections();this._isDirection(wv)&&i.vertical&&i.horizontal?this._allowedDirectionValue=wv:this._isDirection(Fs)&&i.horizontal?this._allowedDirectionValue=Fs:this._isDirection(Ko)&&i.vertical?this._allowedDirectionValue=Ko:this._allowedDirectionValue=null},_allowedDirection(){return this._allowedDirectionValue},$content(){return this._$content},content(){return N(this._$content)},container(){return N(this._$container)},scrollOffset(){return this._strategy._getScrollOffset()},_isRtlNativeStrategy(){let{useNative:i,rtlEnabled:e}=this.option();return i&&e},scrollTop(){return this.scrollOffset().top},scrollLeft(){return this.scrollOffset().left},clientHeight(){return Y(this._$container)},scrollHeight(){return X(this.$content())},clientWidth(){return z(this._$container)},scrollWidth(){return ie(this.$content())},update(){if(this._strategy)return P(this._strategy.update()).done(()=>{this._updateAllowedDirection()})},scrollBy(i){i=this._normalizeLocation(i),!(!i.top&&!i.left)&&(this._updateIfNeed(),this._strategy.scrollBy(i))},scrollTo(i){i=this._normalizeLocation(i),this._updateIfNeed();let e=this._location();this.option("useNative")||(i=this._strategy._applyScaleRatio(i),e=this._strategy._applyScaleRatio(e)),this._isRtlNativeStrategy()&&(e.left-=this._getMaxOffset().left);let t=this._normalizeLocation({left:e.left-Te(i.left,e.left),top:e.top-Te(i.top,e.top)});!t.top&&!t.left||this._strategy.scrollBy(t)},scrollToElement(i,e){let t=u(i),n=this.$content().find(i).length,o=t.parents(".dx-scrollable").length-t.parents(".dx-scrollable-content").length===0;if(!n||!o)return;let s={top:0,left:0},r=this.option("direction");r!==Ko&&(s.left=this.getScrollElementPosition(t,Fs,e)),r!==Fs&&(s.top=this.getScrollElementPosition(t,Ko,e)),this.scrollTo(s)},getScrollElementPosition(i,e,t){let n=this.scrollOffset();return nM(i.get(0),e,u(this.container()).get(0),n,t)},_updateIfNeed(){this.option("updateManually")||this.update()},_useTemplates:()=>!1,isRenovated:()=>!!Iv.IS_RENOVATED_WIDGET});G(Uo,Iv);var kl=Iv;var q2="dx-scrollview-loadpanel",Y2={pullDown:ZA,swipeDown:JA,simulated:iM},X2=!W(),Q2={finishLoading:S,release:S,refresh:S,scrollOffset:()=>({top:0,left:0}),_optionChanged(i){if(i.name!=="onUpdated")return this.callBase.apply(this,arguments)}},oM=kl.inherit(X2?Q2:{_getDefaultOptions(){return m(this.callBase(),{pullingDownText:O.format("dxScrollView-pullingDownText"),pulledDownText:O.format("dxScrollView-pulledDownText"),refreshingText:O.format("dxScrollView-refreshingText"),reachBottomText:O.format("dxScrollView-reachBottomText"),onPullDown:null,onReachBottom:null,refreshStrategy:"pullDown"})},_defaultOptionsRules(){return this.callBase().concat([{device(){return F.real().platform==="android"},options:{refreshStrategy:"swipeDown"}},{device:()=>pt(),options:{pullingDownText:"",pulledDownText:"",refreshingText:"",reachBottomText:""}}])},_init(){this.callBase(),this._loadingIndicatorEnabled=!0},_initScrollableMarkup(){this.callBase(),this.$element().addClass("dx-scrollview"),this._initContent(),this._initTopPocket(),this._initBottomPocket(),this._initLoadPanel()},_initContent(){let i=u("<div>").addClass("dx-scrollview-content");this._$content.wrapInner(i)},_initTopPocket(){let i=this._$topPocket=u("<div>").addClass("dx-scrollview-top-pocket"),e=this._$pullDown=u("<div>").addClass("dx-scrollview-pull-down");i.append(e),this._$content.prepend(i)},_initBottomPocket(){let i=this._$bottomPocket=u("<div>").addClass("dx-scrollview-bottom-pocket"),e=this._$reachBottom=u("<div>").addClass("dx-scrollview-scrollbottom"),t=u("<div>").addClass("dx-scrollview-scrollbottom-indicator"),n=new ni(u("<div>")).$element(),o=this._$reachBottomText=u("<div>").addClass("dx-scrollview-scrollbottom-text");this._updateReachBottomText(),e.append(t.append(n)).append(o),i.append(e),this._$content.append(i)},_initLoadPanel(){let i=u("<div>").addClass(q2).appendTo(this.$element()),e={shading:!1,delay:400,message:this.option("refreshingText"),position:{of:this.$element()}};this._loadPanel=this._createComponent(i,Bp,e)},_updateReachBottomText(){this._$reachBottomText.text(this.option("reachBottomText"))},_createStrategy(){let i=this.option("useNative")?this.option("refreshStrategy"):"simulated",e=Y2[i];this._strategy=new e(this),this._strategy.pullDownCallbacks.add(this._pullDownHandler.bind(this)),this._strategy.releaseCallbacks.add(this._releaseHandler.bind(this)),this._strategy.reachBottomCallbacks.add(this._reachBottomHandler.bind(this))},_createActions(){this.callBase(),this._pullDownAction=this._createActionByOption("onPullDown"),this._reachBottomAction=this._createActionByOption("onReachBottom"),this._tryRefreshPocketState()},_tryRefreshPocketState(){this._pullDownEnable(this.hasActionSubscription("onPullDown")),this._reachBottomEnable(this.hasActionSubscription("onReachBottom"))},on(i){let e=this.callBase.apply(this,arguments);return(i==="pullDown"||i==="reachBottom")&&this._tryRefreshPocketState(),e},_pullDownEnable(i){if(arguments.length===0)return this._pullDownEnabled;this._$pullDown&&this._strategy&&(this._$pullDown.toggle(i),this._strategy.pullDownEnable(i),this._pullDownEnabled=i)},_reachBottomEnable(i){if(arguments.length===0)return this._reachBottomEnabled;this._$reachBottom&&this._strategy&&(this._$reachBottom.toggle(i),this._strategy.reachBottomEnable(i),this._reachBottomEnabled=i)},_pullDownHandler(){this._loadingIndicator(!1),this._pullDownLoading()},_loadingIndicator(i){if(arguments.length<1)return this._loadingIndicatorEnabled;this._loadingIndicatorEnabled=i},_pullDownLoading(){this.startLoading(),this._pullDownAction()},_reachBottomHandler(){this._loadingIndicator(!1),this._reachBottomLoading()},_reachBottomLoading(){this.startLoading(),this._reachBottomAction()},_releaseHandler(){this.finishLoading(),this._loadingIndicator(!0)},_optionChanged(i){switch(i.name){case"onPullDown":case"onReachBottom":this._createActions();break;case"pullingDownText":case"pulledDownText":case"refreshingText":case"refreshStrategy":this._invalidate();break;case"reachBottomText":this._updateReachBottomText();break;default:this.callBase(i)}},content(){return N(this._$content.children().eq(1))},release(i){return i!==void 0&&this.toggleLoading(!i),this._strategy.release()},toggleLoading(i){this._reachBottomEnable(i)},refresh(){this.hasActionSubscription("onPullDown")&&(this._strategy.pendingRelease(),this._pullDownLoading())},startLoading(){this._loadingIndicator()&&this.$element().is(":visible")&&this._loadPanel.show(),this._lock()},finishLoading(){this._loadPanel.hide(),this._unlock()},_dispose(){this._strategy.dispose(),this.callBase(),this._loadPanel&&this._loadPanel.$element().remove()}});G("dxScrollView",oM);var sM=oM;var Bl=sM;var Z2=i=>Array.isArray(i)&&i.every(e=>{let t=Object.keys(e).length===2,n="key"in e&&"items"in e;return t&&n&&Array.isArray(e.items)}),jp={_getSpecificDataSourceOption(){let i=this.option("dataSource"),e=!1,t={};return this._getGroupedOption()&&Z2(i)&&(t=i.reduce((n,o)=>{let s=o.items.map(r=>($(r)||(r={text:r},e=!0),"key"in r||(r.key=o.key),r));return n.concat(s)},[]),i={store:{type:"array",data:t},group:{selector:"key",keepInitialKeyOrder:!0}},e&&(i.searchExpr="text")),i}};var J2=jn.inherit({_renderWatchers(){this.callBase(),this._startWatcher("badge",this._renderBadge.bind(this)),this._startWatcher("showChevron",this._renderShowChevron.bind(this))},_renderBadge(i){if(this._$element.children(".dx-list-item-badge-container").remove(),!i)return;let e=u("<div>").addClass("dx-list-item-badge-container").append(u("<div>").addClass("dx-list-item-badge").addClass("dx-badge").text(i)),t=this._$element.children(".dx-list-item-chevron-container").first();t.length>0?e.insertBefore(t):e.appendTo(this._$element)},_renderShowChevron(i){if(this._$element.children(".dx-list-item-chevron-container").remove(),!i)return;let e=u("<div>").addClass("dx-list-item-chevron-container"),t=u("<div>").addClass("dx-list-item-chevron");e.append(t).appendTo(this._$element)}}),rM=J2;var e4=".dx-list-item";var t4=".dx-list-select-all";var i4=me("items"),n4,Bc=mr.inherit({_activeStateUnit:[e4,t4].join(","),_supportedKeys(){let i=this,e=function(n){let o=t(n);o.is(i.option("focusedElement"))&&(function(r,a){let l=r.position().top;a==="prev"&&(l=r.position().top-Y(i.$element())+X(r)),i.scrollTo(l)}(o,n),o=t(n)),i.option("focusedElement",N(o)),i.scrollToItem(o)};function t(n){let o=i.scrollTop(),s=Y(i.$element()),r=u(i.option("focusedElement")),a=!0;if(!r.length)return u();for(;a;){let l=r[n]();if(!l.length)break;let d=l.position().top+X(l)/2;a=d<s+o&&d>o,a&&(r=l)}return r}return m(this.callBase(),{leftArrow:S,rightArrow:S,pageUp(){return e("prev"),!1},pageDown(){return e("next"),!1}})},_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,pullRefreshEnabled:!1,scrollingEnabled:!0,selectByClick:!0,showScrollbar:"onScroll",useNativeScrolling:!0,bounceEnabled:!0,scrollByContent:!0,scrollByThumb:!1,pullingDownText:O.format("dxList-pullingDownText"),pulledDownText:O.format("dxList-pulledDownText"),refreshingText:O.format("dxList-refreshingText"),pageLoadingText:O.format("dxList-pageLoadingText"),onScroll:null,onPullRefresh:null,onPageLoading:null,pageLoadMode:"scrollBottom",nextButtonText:O.format("dxList-nextButtonText"),onItemSwipe:null,grouped:!1,onGroupRendered:null,collapsibleGroups:!1,groupTemplate:"group",indicateLoading:!0,activeStateEnabled:!0,_itemAttributes:{role:"option"},useInkRipple:!1,wrapItemText:!1,_swipeEnabled:!0,showChevronExpr:i=>i?i.showChevron:void 0,badgeExpr:i=>i?i.badge:void 0})},_defaultOptionsRules(){let i=ct();return this.callBase().concat(Up(),[{device:()=>!Hn,options:{useNativeScrolling:!1}},{device:e=>!Hn&&!F.isSimulator()&&F.real().deviceType==="desktop"&&e.platform==="generic",options:{showScrollbar:"onHover",pageLoadMode:"nextButton"}},{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>it(i),options:{useInkRipple:!0}},{device:()=>pt(i),options:{pullingDownText:"",pulledDownText:"",refreshingText:"",pageLoadingText:""}}])},_visibilityChanged(i){i&&this._updateLoadingState(!0)},_itemClass:()=>"dx-list-item",_itemDataKey:()=>"dxListItemData",_itemContainer(){return this._$container},_getItemsContainer(){return this._$listContainer},_cleanItemContainer(){this.callBase();let i=this._getItemsContainer();u(i).empty(),i.appendTo(this._$container)},_saveSelectionChangeEvent(i){this._selectionChangeEventInstance=i},_getSelectionChangeEvent(){return this._selectionChangeEventInstance},_refreshItemElements(){this.option("grouped")?this._itemElementsCache=this._getItemsContainer().children(".dx-list-group").children(".dx-list-group-body").children(this._itemSelector()):this._itemElementsCache=this._getItemsContainer().children(this._itemSelector())},_modifyByChanges(){this.callBase.apply(this,arguments),this._refreshItemElements(),this._updateLoadingState(!0)},reorderItem(i,e){return this.callBase(i,e).done(function(){this._refreshItemElements()})},deleteItem(i){return this.callBase(i).done(function(){this._refreshItemElements()})},_itemElements(){return this._itemElementsCache},_itemSelectHandler(i){if(!(this.option("selectionMode")==="single"&&this.isItemSelected(i.currentTarget)))return this.callBase(i)},_allowDynamicItemsAppend:()=>!0,_init(){this.callBase(),this._dataController.resetDataSourcePageIndex(),this._$container=this.$element(),this._$listContainer=u("<div>").addClass("dx-list-items"),this._initScrollView(),this._feedbackShowTimeout=70,this._createGroupRenderAction()},_scrollBottomMode(){return this.option("pageLoadMode")==="scrollBottom"},_nextButtonMode(){return this.option("pageLoadMode")==="nextButton"},_dataSourceOptions(){let i=this._scrollBottomMode(),e=this._nextButtonMode();return m(this.callBase(),{paginate:Te(i||e,!0)})},_getGroupedOption(){return this.option("grouped")},_getGroupContainerByIndex(i){return this._getItemsContainer().find(".dx-list-group").eq(i).find(".dx-list-group-body")},_dataSourceFromUrlLoadMode:()=>"raw",_initScrollView(){let i=this.option("scrollingEnabled"),e=i&&this.option("pullRefreshEnabled"),t=i&&this._scrollBottomMode()&&!!this._dataController.getDataSource();this._scrollView=this._createComponent(this.$element(),o4(),{height:this.option("height"),width:this.option("width"),disabled:this.option("disabled")||!i,onScroll:this._scrollHandler.bind(this),onPullDown:e?this._pullDownHandler.bind(this):null,onReachBottom:t?this._scrollBottomHandler.bind(this):null,showScrollbar:this.option("showScrollbar"),useNative:this.option("useNativeScrolling"),bounceEnabled:this.option("bounceEnabled"),scrollByContent:this.option("scrollByContent"),scrollByThumb:this.option("scrollByThumb"),pullingDownText:this.option("pullingDownText"),pulledDownText:this.option("pulledDownText"),refreshingText:this.option("refreshingText"),reachBottomText:this.option("pageLoadingText"),useKeyboard:!1}),this._$container=u(this._scrollView.content()),this._$listContainer.appendTo(this._$container),this._toggleWrapItemText(this.option("wrapItemText")),this._createScrollViewActions()},_toggleWrapItemText(i){this._$listContainer.toggleClass("dx-wrap-item-text",i)},_createScrollViewActions(){this._scrollAction=this._createActionByOption("onScroll"),this._pullRefreshAction=this._createActionByOption("onPullRefresh"),this._pageLoadingAction=this._createActionByOption("onPageLoading")},_scrollHandler(i){this._scrollAction&&this._scrollAction(i)},_initTemplates(){this._templateManager.addDefaultTemplates({group:new di((i,e)=>{q(e)?e.key&&i.text(e.key):i.text(String(e))},["key"],this.option("integrationOptions.watchMethod"))}),this.callBase()},_prepareDefaultItemTemplate(i,e){if(this.callBase(i,e),i.icon){let t=ci(i.icon).addClass("dx-list-item-icon"),n=u("<div>").addClass("dx-list-item-icon-container");n.append(t),e.prepend(n)}},_getBindableFields:()=>["text","html","icon"],_updateLoadingState(i){let e=this._dataController,t=this._scrollBottomMode()&&i&&!e.isLoading()&&!this._isLastPage();this._shouldContinueLoading(t)?this._infiniteDataLoading():(this._scrollView.release(!t&&!e.isLoading()),this._toggleNextButton(this._shouldRenderNextButton()&&!this._isLastPage()),this._loadIndicationSuppressed(!1))},_shouldRenderNextButton(){return this._nextButtonMode()&&this._dataController.isLoaded()},_isDataSourceFirstLoadCompleted(i){return f(i)&&(this._isFirstLoadCompleted=i),this._isFirstLoadCompleted},_dataSourceLoadingChangedHandler(i){this._loadIndicationSuppressed()||(i&&this.option("indicateLoading")?this._showLoadingIndicatorTimer=setTimeout(()=>{if(!!this._itemElements().length||this._isDataSourceFirstLoadCompleted()){var n;(n=this._scrollView)===null||n===void 0||n.startLoading()}}):(clearTimeout(this._showLoadingIndicatorTimer),this._scrollView&&this._scrollView.finishLoading()),i||this._isDataSourceFirstLoadCompleted(!1))},_dataSourceChangedHandler(){!this._shouldAppendItems()&&W()&&this._scrollView&&this._scrollView.scrollTo(0),this.callBase.apply(this,arguments),this._isDataSourceFirstLoadCompleted(!0)},_refreshContent(){this._prepareContent(),this._fireContentReadyAction()},_hideLoadingIfLoadIndicationOff(){this.option("indicateLoading")||this._dataSourceLoadingChangedHandler(!1)},_loadIndicationSuppressed(i){if(!arguments.length)return this._isLoadIndicationSuppressed;this._isLoadIndicationSuppressed=i},_scrollViewIsFull(){let i=this._scrollView;return!i||Y(i.content())>Y(i.container())},_pullDownHandler(i){this._pullRefreshAction(i);let e=this._dataController;e.getDataSource()&&!e.isLoading()?(this._clearSelectedItems(),e.pageIndex(0),e.reload()):this._updateLoadingState()},_shouldContinueLoading(i){var e;let t=Y(this._scrollView.content())-Y(this._scrollView.container())<(((e=this._scrollView.scrollOffset())===null||e===void 0?void 0:e.top)??0);return i&&(!this._scrollViewIsFull()||t)},_infiniteDataLoading(){this.$element().is(":visible")&&(clearTimeout(this._loadNextPageTimer),this._loadNextPageTimer=setTimeout(()=>{this._loadNextPage()}))},_scrollBottomHandler(i){this._pageLoadingAction(i),!this._dataController.isLoading()&&!this._isLastPage()?this._loadNextPage():this._updateLoadingState()},_renderItems(i){this.option("grouped")?(x(i,this._renderGroup.bind(this)),this._attachGroupCollapseEvent(),this._renderEmptyMessage(),it()&&this.attachGroupHeaderInkRippleEvents()):this.callBase.apply(this,arguments),this._refreshItemElements(),this._updateLoadingState(!0)},_attachGroupCollapseEvent(){let i=D(oe,this.NAME),e=this.$element(),t=this.option("collapsibleGroups");e.toggleClass("dx-list-collapsible-groups",t),_.off(e,i,".dx-list-group-header"),t&&_.on(e,i,".dx-list-group-header",n=>{this._createAction(o=>{let s=u(o.event.currentTarget).parent();this._collapseGroupHandler(s),this.option("focusStateEnabled")&&this.option("focusedElement",N(s.find(".dx-list-item").eq(0)))},{validatingTargetName:"element"})({event:n})})},_collapseGroupHandler(i,e){let t=y();if(i.hasClass("dx-list-group-collapsed")===e)return t.resolve();let n=i.children(".dx-list-group-body"),o=X(n),s=0;return o===0&&(xi(n,"auto"),s=X(n)),i.toggleClass("dx-list-group-collapsed",e),pe.animate(n,{type:"custom",from:{height:o},to:{height:s},duration:200,complete:function(){this.updateDimensions(),this._updateLoadingState(!0),t.resolve()}.bind(this)}),t.promise()},_dataSourceLoadErrorHandler(){this._forgetNextPageLoading(),this._initialized&&(this._renderEmptyMessage(),this._updateLoadingState())},_initMarkup(){this._itemElementsCache=u(),this.$element().addClass("dx-list"),this.callBase(),this.option("useInkRipple")&&this._renderInkRipple();let i={role:"group",roledescription:O.format("dxList-ariaRoleDescription")};this.setAria(i,this.$element()),this.setAria({role:"application"},this._focusTarget()),this._setListAria()},_setListAria(){let{items:i,allowItemDeleting:e}=this.option(),t=e?O.format("dxList-listAriaLabel-deletable"):O.format("dxList-listAriaLabel"),n=i!=null&&i.length?{role:"listbox",label:t}:{role:void 0,label:void 0};this.setAria(n,this._$listContainer)},_focusTarget(){return this._itemContainer()},_renderInkRipple(){this._inkRipple=Sl()},_toggleActiveState(i,e,t){this.callBase.apply(this,arguments);let n=this;if(!this._inkRipple)return;let o={element:i,event:t};e?it()?this._inkRippleTimer=setTimeout(()=>{n._inkRipple.showWave(o)},35):n._inkRipple.showWave(o):(clearTimeout(this._inkRippleTimer),this._inkRipple.hideWave(o))},_postprocessRenderItem(i){this._refreshItemElements(),this.callBase.apply(this,arguments),this.option("_swipeEnabled")&&this._attachSwipeEvent(u(i.itemElement))},_attachSwipeEvent(i){let e=D(Ml,this.NAME);_.on(i,e,this._itemSwipeEndHandler.bind(this))},_itemSwipeEndHandler(i){this._itemDXEventHandler(i,"onItemSwipe",{direction:i.offset<0?"left":"right"})},_nextButtonHandler(i){this._pageLoadingAction(i);let e=this._dataController;e.getDataSource()&&!e.isLoading()&&(this._scrollView.toggleLoading(!0),this._$nextButton.detach(),this._loadIndicationSuppressed(!0),this._loadNextPage())},_renderGroup(i,e){let t=u("<div>").addClass("dx-list-group").appendTo(this._getItemsContainer()),n=`dx-${new Oe().toString()}`,o={role:"group",labelledby:n};this.setAria(o,t);let s=u("<div>").addClass("dx-list-group-header").attr("id",n).appendTo(t),r=this.option("groupTemplate"),a=this._getTemplate(e.template||r,e,i,s),l={index:i,itemData:e,container:N(s)};this._createItemByTemplate(a,l),u("<div>").addClass("dx-list-group-header-indicator").prependTo(s),this._renderingGroupIndex=i;let d=u("<div>").addClass("dx-list-group-body").appendTo(t);x(i4(e)||[],(c,h)=>{this._renderItem({group:i,item:c},h,d)}),this._groupRenderAction({groupElement:N(t),groupIndex:i,groupData:e})},downInkRippleHandler(i){this._toggleActiveState(u(i.currentTarget),!0,i)},upInkRippleHandler(i){this._toggleActiveState(u(i.currentTarget),!1)},attachGroupHeaderInkRippleEvents(){let i=this.$element();this._downInkRippleHandler=this._downInkRippleHandler||this.downInkRippleHandler.bind(this),this._upInkRippleHandler=this._upInkRippleHandler||this.upInkRippleHandler.bind(this);let e=[i,"dxpointerdown",".dx-list-group-header",this._downInkRippleHandler],t=[i,"dxpointerup dxpointerout",".dx-list-group-header",this._upInkRippleHandler];_.off(...e),_.on(...e),_.off(...t),_.on(...t)},_createGroupRenderAction(){this._groupRenderAction=this._createActionByOption("onGroupRendered")},_clean(){clearTimeout(this._inkRippleTimer),this._$nextButton&&(this._$nextButton.remove(),this._$nextButton=null),this.callBase.apply(this,arguments)},_dispose(){this._isDataSourceFirstLoadCompleted(!1),clearTimeout(this._holdTimer),clearTimeout(this._loadNextPageTimer),clearTimeout(this._showLoadingIndicatorTimer),this.callBase()},_toggleDisabledState(i){this.callBase(i),this._scrollView.option("disabled",i||!this.option("scrollingEnabled"))},_toggleNextButton(i){let e=this._dataController,t=this._getNextButton();this.$element().toggleClass("dx-has-next",i),i&&e.isLoaded()&&t.appendTo(this._itemContainer()),i||t.detach()},_getNextButton(){return this._$nextButton||(this._$nextButton=this._createNextButton()),this._$nextButton},_createNextButton(){let i=u("<div>").addClass("dx-list-next-button"),e=u("<div>").appendTo(i);return this._createComponent(e,rt,{text:this.option("nextButtonText"),onClick:this._nextButtonHandler.bind(this),type:pt()?"default":void 0,integrationOptions:{}}),i},_moveFocus(){this.callBase.apply(this,arguments),this.scrollToItem(this.option("focusedElement"))},_refresh(){if(!W())this.callBase();else{let i=this._scrollView.scrollTop();this.callBase(),i&&this._scrollView.scrollTo(i)}},_optionChanged(i){switch(i.name){case"pageLoadMode":this._toggleNextButton(i.value),this._initScrollView();break;case"dataSource":this.callBase(i),this._initScrollView(),this._updateLoadingState(!0),this._isDataSourceFirstLoadCompleted(!1);break;case"items":this.callBase(i),this._isDataSourceFirstLoadCompleted(!1);break;case"pullingDownText":case"pulledDownText":case"refreshingText":case"pageLoadingText":case"showScrollbar":case"bounceEnabled":case"scrollByContent":case"scrollByThumb":case"useNativeScrolling":case"scrollingEnabled":case"pullRefreshEnabled":this._initScrollView(),this._updateLoadingState(!0);break;case"nextButtonText":case"onItemSwipe":case"useInkRipple":case"grouped":case"collapsibleGroups":case"groupTemplate":case"showChevronExpr":case"badgeExpr":this._invalidate();break;case"onScroll":case"onPullRefresh":case"onPageLoading":this._createScrollViewActions();break;case"wrapItemText":this._toggleWrapItemText(i.value);break;case"onGroupRendered":this._createGroupRenderAction();break;case"width":case"height":this.callBase(i),this._scrollView.option(i.name,i.value),this._scrollView.update();break;case"indicateLoading":this._hideLoadingIfLoadIndicationOff();break;case"visible":this.callBase(i),this._scrollView.update();break;case"rtlEnabled":this._initScrollView(),this.callBase(i);break;case"_swipeEnabled":case"selectByClick":break;default:this.callBase(i)}},_extendActionArgs(i){if(!this.option("grouped"))return this.callBase(i);let e=i.closest(".dx-list-group"),t=e.find(".dx-list-item");return m(this.callBase(i),{itemIndex:{group:e.index(),item:t.index(i)}})},expandGroup(i){let e=y(),t=this._getItemsContainer().find(".dx-list-group").eq(i);return this._collapseGroupHandler(t,!1).done(()=>{e.resolveWith(this)}),e.promise()},collapseGroup(i){let e=y(),t=this._getItemsContainer().find(".dx-list-group").eq(i);return this._collapseGroupHandler(t,!0).done(()=>{e.resolveWith(this)}),e},updateDimensions(){let i=this,e=y();return i._scrollView?i._scrollView.update().done(()=>{!i._scrollViewIsFull()&&i._updateLoadingState(!0),e.resolveWith(i)}):e.resolveWith(i),e.promise()},reload(){this.callBase(),this.scrollTo(0),this._pullDownHandler()},repaint(){this.scrollTo(0),this.callBase()},scrollTop(){return this._scrollView.scrollOffset().top},clientHeight(){return this._scrollView.clientHeight()},scrollHeight(){return this._scrollView.scrollHeight()},scrollBy(i){this._scrollView.scrollBy(i)},scrollTo(i){this._scrollView.scrollTo(i)},scrollToItem(i){let e=this._editStrategy.getItemElement(i),t=e?.get(0);this._scrollView.scrollToElement(t,{bottom:KA(t,"bottom")})},_dimensionChanged(){this.updateDimensions()}}).include(jp);Bc.ItemClass=rM;function o4(){return n4||Bl}var Dv={};function aM(i,e,t){let n=Dv,o={};o[i]=n[i]?n[i]:{},o[i][e]=t,m(n,o)}var lM=[],qp=function(i,e,t){lM.push({enabled:i,decoratorType:e,decoratorSubType:t})};qp(function(){return this.option("menuItems").length},()=>"menu",function(){return this.option("menuMode")});qp(function(){return!this.option("menuItems").length&&this.option("allowItemDeleting")},function(){let i=this.option("itemDeleteMode");return i==="toggle"||i==="slideButton"||i==="swipe"||i==="static"?"delete":"menu"},function(){let i=this.option("itemDeleteMode");return i==="slideItem"&&(i="slide"),i});qp(function(){return this.option("selectionMode")!=="none"&&this.option("showSelectionControls")},()=>"selection",()=>"default");qp(function(){return this.option("itemDragging.allowReordering")||this.option("itemDragging.allowDropInsideItem")||this.option("itemDragging.group")},()=>"reorder",()=>"default");var s4=ce.inherit({ctor(i){this._list=i,this._fetchRequiredDecorators()},dispose(){this._decorators&&this._decorators.length&&x(this._decorators,(i,e)=>{e.dispose()})},_fetchRequiredDecorators(){this._decorators=[],x(lM,(i,e)=>{if(e.enabled.call(this._list)){let n=e.decoratorType.call(this._list),o=e.decoratorSubType.call(this._list),s=this._createDecorator(n,o);this._decorators.push(s)}})},_createDecorator(i,e){let t=this._findDecorator(i,e);return new t(this._list)},_findDecorator(i,e){var t;let n=(t=Dv[i])===null||t===void 0?void 0:t[e];if(!n)throw Z.Error("E1012",i,e);return n},modifyItemElement(i){let e=u(i.itemElement),t={$itemElement:e};this._prependBeforeBags(e,t),this._appendAfterBags(e,t),this._applyDecorators("modifyElement",t)},afterItemsRendered(){this._applyDecorators("afterRender")},_prependBeforeBags(i,e){let t=this._collectDecoratorsMarkup("beforeBag",e,"dx-list-item-before-bag");i.prepend(t)},_appendAfterBags(i,e){let t=this._collectDecoratorsMarkup("afterBag",e,"dx-list-item-after-bag");i.append(t)},_collectDecoratorsMarkup(i,e,t){let n=u("<div>");return x(this._decorators,function(){let o=u("<div>").addClass(t);this[i](m({$container:o},e)),o.children().length&&n.append(o)}),n.children()},_applyDecorators(i,e){x(this._decorators,function(){this[i](e)})},_handlerExists(i){if(!this._decorators)return!1;let e=this._decorators,{length:t}=e;for(let n=0;n<t;n++)if(e[n][i]!==S)return!0;return!1},_eventHandler(i,e,t){if(!this._decorators)return!1;let n=!1,o=this._decorators,{length:s}=o;for(let r=0;r<s&&(n=o[r][i](e,t),!n);r++);return n},handleClick(i,e){return this._eventHandler("handleClick",i,e)},handleKeyboardEvents(i,e){return this._eventHandler("handleKeyboardEvents",i,e)},handleEnterPressing(i){return this._eventHandler("handleEnterPressing",i)},contextMenuHandlerExists(){return this._handlerExists("handleContextMenu")},handleContextMenu(i,e){return this._eventHandler("handleContextMenu",i,e)},getExcludedItemSelectors(){let i=[];return this._applyDecorators("getExcludedSelectors",i),i.join(",")}}),dM=s4;var cM=function(i){return(i.group<<20)+i.item},ga=function(i){return{group:i>>20,item:1048575&i}},r4=pl.inherit({_groupElements(){return this._collectionWidget._itemContainer().find(".dx-list-group")},_groupItemElements:i=>i.find(".dx-list-item"),getIndexByItemData(i){let e=this._collectionWidget.option("items"),t=!1;return i?(i.items&&i.items.length&&(i=i.items[0]),x(e,(n,o)=>{if(!o.items||(x(o.items,(s,r)=>r!==i?!0:(t={group:n,item:s},!1)),t))return!1}),t):!1},getItemDataByIndex(i){let e=this._collectionWidget.option("items");return xe(i)?this.itemsGetter()[i]:i&&e[i.group]&&e[i.group].items[i.item]||null},itemsGetter(){let i=[],e=this._collectionWidget.option("items");for(let t=0;t<e.length;t++)e[t]&&e[t].items?i=i.concat(e[t].items):i.push(e[t]);return i},deleteItemAtIndex(i){let e=ga(i);this._collectionWidget.option("items")[e.group].items.splice(e.item,1)},getKeysByItems(i){let e=[],t;for(t=0;t<i.length;t++)i[t]&&i[t].items?e=e.concat(i[t].items):e.push(i[t]);let n=[];for(t=0;t<e.length;t++)n.push(this._collectionWidget.keyOf(e[t]));return n},getIndexByKey(i,e){let t=e||this._collectionWidget.option("items"),n=-1,o=this;return x(t,(s,r)=>{if(r.items&&(x(r.items,(a,l)=>{let d=o._collectionWidget.keyOf(l);if(o._equalKeys(d,i))return n={group:s,item:a},!1}),n!==-1))return!1}),n},_getGroups(i){let t=this._collectionWidget._dataController.group();return t?qi.queryByOptions(vt(i),{group:t}).toArray():this._collectionWidget.option("items")},getItemsByKeys(i,e){let t=[],n=this._getGroups(e),o={},s=r=>{let a=this.getIndexByKey(r,n),l=a&&n[a.group];if(l)return{groupKey:l.key,item:l.items[a.item]}};return x(i,(r,a)=>{let l=s(a);if(!l)return;let{groupKey:d}=l,{item:c}=l,h=o[d];h||(h={key:d,items:[]},o[d]=h,t.push(h)),h.items.push(c)}),t},moveItemAtIndexToIndex(i,e){let t=this._collectionWidget.option("items"),n=ga(i),o=ga(e),s=t[n.group].items,r=t[o.group].items,a=s[n.item];s.splice(n.item,1),r.splice(o.item,0,a)},_isItemIndex:i=>i&&xe(i.group)&&xe(i.item),_getNormalizedItemIndex(i){let e=u(i),t=e.closest(".dx-list-group");return t.length?cM({group:this._groupElements().index(t),item:this._groupItemElements(t).index(e)}):-1},_normalizeItemIndex:i=>cM(i),_denormalizeItemIndex:i=>ga(i),_getItemByNormalizedIndex(i){let e=ga(i),t=this._groupElements().eq(e.group);return this._groupItemElements(t).eq(e.item)},_itemsFromSameParent:(i,e)=>ga(i).group===ga(e).group}),uM=r4;var a4=Bc.inherit({_supportedKeys(){let i=this,e=this.callBase(),t=(n,o)=>{let s=this._editStrategy,r=this.option("focusedElement"),a=s.getNormalizedIndex(r);if(!(a===this._getLastItemIndex()&&this._dataController.isLoading()))if(n.shiftKey&&i.option("itemDragging.allowReordering")){let d=a+(o?-1:1),c=s.getItemElement(d);this.reorderItem(r,c),this.scrollToItem(r),n.preventDefault()}else this._editProvider.handleKeyboardEvents(a,o)||(o?e.upArrow(n):e.downArrow(n))};return m({},e,{del:n=>{i.option("allowItemDeleting")&&(n.preventDefault(),i.deleteItem(i.option("focusedElement")))},upArrow:n=>t(n,!0),downArrow:n=>t(n),enter:function(n){this._editProvider.handleEnterPressing(n)||e.enter.apply(this,arguments)},space:function(n){this._editProvider.handleEnterPressing(n)||e.space.apply(this,arguments)}})},_updateSelection(){this._editProvider.afterItemsRendered(),this.callBase()},_getLastItemIndex(){return this._itemElements().length-1},_refreshItemElements(){this.callBase();let i=this._editProvider.getExcludedItemSelectors();i.length&&(this._itemElementsCache=this._itemElementsCache.not(i))},_isItemStrictEquals(i,e){let t=i&&i.__dx_key__;return t&&!this.key()&&this._selection.isItemSelected(t)?!1:this.callBase(i,e)},_getDefaultOptions(){return m(this.callBase(),{showSelectionControls:!1,selectionMode:"none",selectAllMode:"page",onSelectAllValueChanged:null,selectAllText:O.format("dxList-selectAll"),menuItems:[],menuMode:"context",allowItemDeleting:!1,itemDeleteMode:"static",itemDragging:{}})},_defaultOptionsRules(){return this.callBase().concat([{device:i=>i.platform==="ios",options:{menuMode:"slide",itemDeleteMode:"slideItem"}},{device:{platform:"android"},options:{itemDeleteMode:"swipe"}}])},_init(){this.callBase(),this._initEditProvider()},_initDataSource(){this.callBase(),this._isPageSelectAll()||this._dataSource&&this._dataSource.requireTotalCount(!0)},_isPageSelectAll(){return this.option("selectAllMode")==="page"},_initEditProvider(){this._editProvider=new dM(this)},_disposeEditProvider(){this._editProvider&&this._editProvider.dispose()},_refreshEditProvider(){this._disposeEditProvider(),this._initEditProvider()},_initEditStrategy(){this.option("grouped")?this._editStrategy=new uM(this):this.callBase()},_initMarkup(){this._refreshEditProvider(),this.callBase()},_renderItems(){this.callBase(...arguments),this._editProvider.afterItemsRendered()},_renderItem(i,e,t,n){let{showSelectionControls:o,selectionMode:s}=this.option(),r=this.callBase(i,e,t,n);return o&&s!=="none"&&this._updateItemAriaLabel(r,e),r},_updateItemAriaLabel(i,e){var t;let n=((t=this._displayGetter)===null||t===void 0?void 0:t.call(this,e))??e?.text??e;this.setAria("label",n,i)},_selectedItemClass:()=>"dx-list-item-selected",_itemResponseWaitClass:()=>"dx-list-item-response-wait",_itemClickHandler(i){let e=u(i.currentTarget);e.is(".dx-state-disabled, .dx-state-disabled *")||this._editProvider.handleClick(e,i)||(this._saveSelectionChangeEvent(i),this.callBase(...arguments))},_shouldFireContextMenuEvent(){return this.callBase(...arguments)||this._editProvider.contextMenuHandlerExists()},_itemHoldHandler(i){let e=u(i.currentTarget);if(e.is(".dx-state-disabled, .dx-state-disabled *"))return;if(gs(i)&&this._editProvider.handleContextMenu(e,i)){i.handledByEditProvider=!0;return}this.callBase(...arguments)},_getItemContainer(i){if(this.option("grouped")){var e;let t=(e=this._editStrategy.getIndexByItemData(i))===null||e===void 0?void 0:e.group;return this._getGroupContainerByIndex(t)}return this.callBase(i)},_itemContextMenuHandler(i){let e=u(i.currentTarget);if(e.is(".dx-state-disabled, .dx-state-disabled *"))return;if(!i.handledByEditProvider&&this._editProvider.handleContextMenu(e,i)){i.preventDefault();return}this.callBase(...arguments)},_postprocessRenderItem(i){this.callBase(...arguments),this._editProvider.modifyItemElement(i)},_clean(){this._disposeEditProvider(),this.callBase()},focusListItem(i){let e=this._editStrategy.getItemElement(i);this.option("focusedElement",e),this.focus(),this.scrollToItem(this.option("focusedElement"))},_optionChanged(i){switch(i.name){case"selectAllMode":this._initDataSource(),this._dataController.pageIndex(0),this._dataController.load();break;case"grouped":this._clearSelectedItems(),delete this._renderingGroupIndex,this._initEditStrategy(),this.callBase(i);break;case"showSelectionControls":case"menuItems":case"menuMode":case"allowItemDeleting":case"itemDeleteMode":case"itemDragging":case"selectAllText":this._invalidate();break;case"onSelectAllValueChanged":break;default:this.callBase(i)}},selectAll(){return this._selection.selectAll(this._isPageSelectAll())},unselectAll(){return this._selection.deselectAll(this._isPageSelectAll())},isSelectAll(){return this._selection.getSelectAllState(this._isPageSelectAll())},getFlatIndexByItemElement(i){return this._itemElements().index(i)},getItemElementByFlatIndex(i){let e=this._itemElements();return i<0||i>=e.length?u():e.eq(i)},getItemByIndex(i){return this._editStrategy.getItemDataByIndex(i)},deleteItem(i){let e=this._editStrategy,t=e.getNormalizedIndex(i),n=this.option("focusedElement"),o=this.option("focusStateEnabled"),s=n?e.getNormalizedIndex(n):t,a=s===this._getLastItemIndex()||t<s?s-1:s;return this.callBase(i).done(function(){o&&this.focusListItem(a)})}}),hM=a4;var l4=hM.inherit(bo).inherit({_addWidgetPrefix:i=>`dx-list-${i}`,_getCombinedFilter(){let i=this._dataController,e={filter:i.filter()};i.addSearchFilter(e);let{filter:t}=e;return t},_initDataSource(){let i=this.option("searchValue"),e=this.option("searchExpr"),t=this.option("searchMode");this.callBase();let n=this._dataController;i&&i.length&&n.searchValue(i),t.length&&n.searchOperation(bo.getOperationBySearchMode(t)),e&&n.searchExpr(e)}}),Tv=l4;G("dxList",Tv);var jo=Tv;var Yp="dx-invalid-message",d4="dx-invalid-message-auto",c4="dx-invalid-message-always",u4="dx-invalid-message-content";var pM=Ni.inherit({_getDefaultOptions(){return m(this.callBase(),{integrationOptions:{},templatesRenderAsynchronously:!1,shading:!1,width:"auto",height:"auto",hideOnOutsideClick:!1,animation:null,visible:!0,propagateOutsideClick:!0,_checkParentVisibility:!1,rtlEnabled:!1,contentTemplate:this._renderInnerHtml,maxWidth:"100%",container:this.$element(),target:void 0,mode:"auto",validationErrors:void 0,preventScrollEvents:!1,positionSide:"top",boundary:void 0,offset:{h:0,v:0},contentId:void 0})},_init(){this.callBase(),this.updateMaxWidth(),this._updatePosition()},_initMarkup(){this.callBase(),this._ensureMessageNotEmpty(),this._updatePositionByTarget(),this._toggleModeClass(),this._updateContentId()},_updatePositionByTarget(){let{target:i}=this.option();this.option("position.of",i)},_ensureMessageNotEmpty(){this._textMarkup=this._getTextMarkup();let i=this.option("visible")&&this._textMarkup;this._toggleVisibilityClasses(i)},_toggleVisibilityClasses(i){i?(this.$element().addClass(Yp),this.$wrapper().addClass(Yp)):(this.$element().removeClass(Yp),this.$wrapper().removeClass(Yp))},_updateContentId(){let{container:i,contentId:e}=this.option(),t=e??u(i).attr("aria-describedby");this.$content().addClass(u4).attr("id",t)},_renderInnerHtml(i){let e=i&&u(i);e?.html(this._textMarkup)},_getTextMarkup(){let i=this.option("validationErrors")??[],e="";return i.forEach(t=>{e+=(e?"<br />":"")+Zu(t?.message??"")}),e},_toggleModeClass(){let i=this.option("mode");this.$wrapper().toggleClass(d4,i==="auto").toggleClass(c4,i==="always")},updateMaxWidth(){let i=this.option("target"),e=ie(i),t="100%";e&&(t=Math.max(e,100)),this.option({maxWidth:t})},_getPositionsArray(i,e){switch(i){case"top":return[`${e} bottom`,`${e} top`];case"left":return["right","left"];case"right":return["left","right"];default:return[`${e} top`,`${e} bottom`]}},_updatePosition(){let{positionSide:i,rtlEnabled:e,offset:t,boundary:n}=this.option(),o=Ui(e),s=this._getPositionsArray(i,o),r=I({},t);this.$element().addClass(`dx-invalid-message-${i}`),e&&i!=="left"&&i!=="right"&&(r.h=-r.h),i==="top"&&(r.v=-r.v),i==="left"&&(r.h=-r.h),this.option("position",{offset:r,boundary:n,my:s[0],at:s[1],collision:"none flip"})},_optionChanged(i){let{name:e,value:t,previousValue:n}=i;switch(e){case"target":this._updatePositionByTarget(),this.updateMaxWidth(),this.callBase(i);break;case"boundary":this.option("position.boundary",t);break;case"mode":this._toggleModeClass(t);break;case"rtlEnabled":case"offset":case"positionSide":this.$element().removeClass(`dx-invalid-message-${n}`),this._updatePosition();break;case"container":this._updateContentId(),this.callBase(i);break;case"contentId":this._updateContentId();break;case"validationErrors":this._ensureMessageNotEmpty(),this._renderInnerHtml(this.$content());break;default:this.callBase(i)}}});G("dxValidationMessage",pM);var gM=pM;var Xp=gM;var mM="dx-invalid-message-auto";var h4="dx-show-invalid-badge",fM="dx-validation-target";var p4=["outlined","filled","underlined"],_M={validationMessageMode:"mode",validationMessagePosition:"positionSide",validationMessageOffset:"offset",validationBoundary:"boundary"},Av=Xe.inherit({ctor(){this.showValidationMessageTimeout=null,this.validationRequest=ue(),this.callBase.apply(this,arguments)},_createElement(i){this.callBase(i);let e=this.$element();e&&$e(e[0],fM,this)},_initOptions(i){this.callBase.apply(this,arguments),this.option(Xt.initValidationOptions(i))},_init(){this._initialValue=this.option("value"),this.callBase(),this._options.cache("validationTooltipOptions",this.option("validationTooltipOptions")),this.$element().addClass(h4)},_getDefaultOptions(){return m(this.callBase(),{value:null,name:"",onValueChanged:null,readOnly:!1,isValid:!0,validationError:null,validationErrors:null,validationStatus:"valid",validationMessageMode:"auto",validationMessagePosition:"bottom",validationBoundary:void 0,validationMessageOffset:{h:0,v:0},validationTooltipOptions:{},_showValidationMessage:!0,isDirty:!1})},_attachKeyboardEvents(){this.option("readOnly")||this.callBase()},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{validationError:!0})},_createValueChangeAction(){this._valueChangeAction=this._createActionByOption("onValueChanged",{excludeValidators:["disabled","readOnly"]})},_suppressValueChangeAction(){this._valueChangeActionSuppressed=!0},_resumeValueChangeAction(){this._valueChangeActionSuppressed=!1},_initMarkup(){var i;this._toggleReadOnlyState(),this._setSubmitElementName(this.option("name")),this.callBase(),this._renderValidationState(),(i=this.option("_onMarkupRendered"))===null||i===void 0||i()},_raiseValueChangeAction(i,e){this._valueChangeAction||this._createValueChangeAction(),this._valueChangeAction(this._valueChangeArgs(i,e))},_valueChangeArgs(i,e){return{value:i,previousValue:e,event:this._valueChangeEventInstance}},_saveValueChangeEvent(i){this._valueChangeEventInstance=i},_focusInHandler(i){let e=this.option("validationMessageMode")==="auto";if(this._canValueBeChangedByClick()&&e){var t;let n=(t=this._validationMessage)===null||t===void 0?void 0:t.$wrapper();n?.removeClass(mM),clearTimeout(this.showValidationMessageTimeout),this.showValidationMessageTimeout=setTimeout(()=>n?.addClass(mM),150)}return this.callBase(i)},_canValueBeChangedByClick:()=>!1,_getStylingModePrefix:()=>"dx-editor-",_renderStylingMode(){let i=this.option("stylingMode"),e=this._getStylingModePrefix(),t=p4.map(o=>e+o);t.forEach(o=>this.$element().removeClass(o));let n=e+i;if(!t.includes(n)){let o=this._getDefaultOptions().stylingMode,s=this._convertRulesToOptions(this._defaultOptionsRules()).stylingMode;n=e+(s||o)}this.$element().addClass(n)},_getValidationErrors(){let i=this.option("validationErrors");return!i&&this.option("validationError")&&(i=[this.option("validationError")]),i},_disposeValidationMessage(){this._$validationMessage&&(this._$validationMessage.remove(),this.setAria("describedby",null),this._$validationMessage=void 0,this._validationMessage=void 0)},_toggleValidationClasses(i){this.$element().toggleClass("dx-invalid",i),this.setAria("invalid",i||void 0)},_renderValidationState(){let i=this.option("isValid")&&this.option("validationStatus")!=="invalid",e=this._getValidationErrors(),t=this.$element();if(this._toggleValidationClasses(!i),!(!W()||this.option("_showValidationMessage")===!1)&&(this._disposeValidationMessage(),!i&&e)){let{validationMessageMode:n,validationMessageOffset:o,validationBoundary:s,rtlEnabled:r}=this.option();this._$validationMessage=u("<div>").appendTo(t);let a=`dx-${new Oe}`;this.setAria("describedby",a),this._validationMessage=new Xp(this._$validationMessage,m({validationErrors:e,rtlEnabled:r,target:this._getValidationMessageTarget(),visualContainer:t,mode:n,positionSide:this._getValidationMessagePosition(),offset:o,boundary:s,contentId:a},this._options.cache("validationTooltipOptions"))),this._bindInnerWidgetOptions(this._validationMessage,"validationTooltipOptions")}},_getValidationMessagePosition(){return this.option("validationMessagePosition")},_getValidationMessageTarget(){return this.$element()},_toggleReadOnlyState(){let i=this.option("readOnly");this._toggleBackspaceHandler(i),this.$element().toggleClass("dx-state-readonly",!!i),this._setAriaReadonly(i)},_setAriaReadonly(i){this.setAria("readonly",i||void 0)},_toggleBackspaceHandler(i){let e=this._keyboardEventBindingTarget(),t=D("keydown","editorReadOnly");_.off(e,t),i&&_.on(e,t,n=>{De(n)==="backspace"&&n.preventDefault()})},_dispose(){let i=this.$element()[0];$e(i,fM,null),clearTimeout(this.showValidationMessageTimeout),this._disposeValidationMessage(),this.callBase()},_setSubmitElementName(i){let e=this._getSubmitElement();e&&(i.length>0?e.attr("name",i):e.removeAttr("name"))},_getSubmitElement:()=>null,_setValidationMessageOption(i){var e;let{name:t,value:n}=i,o=_M[t]?_M[t]:t;(e=this._validationMessage)===null||e===void 0||e.option(o,n)},_hasActiveElement:S,_optionChanged(i){var e;switch(i.name){case"onValueChanged":this._createValueChangeAction();break;case"readOnly":this._toggleReadOnlyState(),this._refreshFocusState();break;case"value":i.value!=i.previousValue&&(this.option("isDirty",this._initialValue!==i.value),this.validationRequest.fire({value:i.value,editor:this})),this._valueChangeActionSuppressed||(this._raiseValueChangeAction(i.value,i.previousValue),this._saveValueChangeEvent(void 0));break;case"width":this.callBase(i),(e=this._validationMessage)===null||e===void 0||e.updateMaxWidth();break;case"name":this._setSubmitElementName(i.value);break;case"isValid":case"validationError":case"validationErrors":case"validationStatus":this.option(Xt.synchronizeValidationOptions(i,this.option())),this._renderValidationState();break;case"validationBoundary":case"validationMessageMode":case"validationMessagePosition":case"validationMessageOffset":this._setValidationMessageOption(i);break;case"rtlEnabled":this._setValidationMessageOption(i),this.callBase(i);break;case"validationTooltipOptions":this._innerWidgetOptionChanged(this._validationMessage,i);break;case"_showValidationMessage":case"isDirty":break;default:this.callBase(i)}},_resetToInitialValue(){this.option("value",this._initialValue)},blur(){this._hasActiveElement()&&zn()},clear(){let i=this._getDefaultOptions();this.option("value",i.value)},reset(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:void 0;arguments.length&&(this._initialValue=i),this._resetToInitialValue(),this.option("isDirty",!1),this.option("isValid",!0)}});Av.isEditor=i=>i instanceof Av;var CM=Av;var oi=CM;var qo=class{constructor(e,t,n){this.instance=null,this.$container=null,this.$placeMarker=null,this.editor=t,this.name=e,this.options=n||{}}_addPlaceMarker(e){this.$placeMarker=u("<div>").appendTo(e)}_addToContainer(e){let{$placeMarker:t,$container:n}=this;t?t.replaceWith(e):e.appendTo(n)}_attachEvents(e,t){throw"Not implemented"}_create(){throw"Not implemented"}_isRendered(){return!!this.instance}_isVisible(){let{editor:e,options:t}=this;return t.visible||!e.option("readOnly")}_isDisabled(){throw"Not implemented"}_shouldRender(){return this._isVisible()&&!this._isRendered()}dispose(){let{instance:e,$placeMarker:t}=this;e&&(e.dispose?e.dispose():e.remove(),this.instance=null),t&&t.remove()}render(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.$container;if(this.$container=e,this._isVisible()){let{instance:t,$element:n}=this._create();this.instance=t,this._attachEvents(t,n)}else this._addPlaceMarker(e)}update(){return this._shouldRender()&&this.render(),!!this.instance}};var g4=ne.down;var Vl=class extends qo{_create(){let e=u("<span>").addClass("dx-clear-button-area").append(u("<span>").addClass("dx-icon").addClass("dx-icon-clear"));return this._addToContainer(e),this.update(!0),{instance:e,$element:e}}_isVisible(){let{editor:e}=this;return e._isClearButtonVisible()}_attachEvents(e,t){let{editor:n}=this,o=n.NAME;_.on(t,D(g4,o),s=>{s.preventDefault(),s.pointerType!=="mouse"&&n._clearValueHandler(s)}),_.on(t,D(oe,o),s=>n._clearValueHandler(s))}_legacyRender(e,t){e.toggleClass("dx-show-clear-button",t)}update(){!(arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1)&&super.update();let{editor:t,instance:n}=this,o=t.$element(),s=this._isVisible();n&&n.toggleClass("dx-state-invisible",!s),this._legacyRender(o,s)}};var Qp=class{constructor(e){this.NAME="dxLabel",this._props=e,this._id=`dx-texteditor-label-${new Oe}`,this._render(),this._toggleMarkupVisibility()}_isVisible(){return!!this._props.text&&this._props.mode!=="hidden"}_render(){this._$before=u("<div>").addClass("dx-label-before"),this._$labelSpan=u("<span>"),this._$label=u("<div>").addClass("dx-label").append(this._$labelSpan),this._$after=u("<div>").addClass("dx-label-after"),this._$root=u("<div>").addClass("dx-texteditor-label").attr("id",this._id).append(this._$before).append(this._$label).append(this._$after),this._updateMark(),this._updateText(),this._updateBeforeWidth(),this._updateMaxWidth()}_toggleMarkupVisibility(){let e=this._isVisible();this._updateEditorBeforeButtonsClass(e),this._updateEditorLabelClass(e),e?this._$root.appendTo(this._props.$editor):this._$root.detach(),this._attachEvents()}_attachEvents(){let e=D(oe,this.NAME),t=D(pr,this.NAME),n=D(hD,this.NAME);_.off(this._$labelSpan,e),_.off(this._$labelSpan,t),_.off(this._$labelSpan,n),this._isVisible()&&this._isOutsideMode()&&(_.on(this._$labelSpan,e,o=>{K().getSelection().toString()===""&&(this._props.onClickHandler(),o.preventDefault())}),_.on(this._$labelSpan,t,o=>{this._props.onHoverHandler(o)}),_.on(this._$labelSpan,n,o=>{this._props.onActiveHandler(o)}))}_updateEditorLabelClass(e){if(this._props.$editor.removeClass("dx-texteditor-with-floating-label").removeClass("dx-texteditor-label-outside").removeClass("dx-texteditor-with-label"),e){let t=this._props.mode==="floating"?"dx-texteditor-with-floating-label":"dx-texteditor-with-label";this._props.$editor.addClass(t),this._isOutsideMode()&&this._props.$editor.addClass("dx-texteditor-label-outside")}}_isOutsideMode(){return this._props.mode==="outside"}_updateEditorBeforeButtonsClass(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._isVisible();if(this._props.$editor.removeClass("dx-texteditor-with-before-buttons"),e){let t=this._props.containsButtonsBefore?"dx-texteditor-with-before-buttons":"";this._props.$editor.addClass(t)}}_updateMark(){this._$labelSpan.attr("data-mark",this._props.mark)}_updateText(){this._$labelSpan.text(this._props.text)}_updateBeforeWidth(){if(this._isVisible()){let e=this._props.beforeWidth??this._props.getBeforeWidth();this._$before.css({width:e}),this._updateLabelTransform()}}_updateLabelTransform(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;if(this._$labelSpan.css("transform",""),this._isVisible()&&this._isOutsideMode()){let n=(this._props.rtlEnabled?1:-1)*(z(this._$before)+e);this._$labelSpan.css("transform",`translateX(${n}px)`)}}_updateMaxWidth(){if(this._isVisible()&&!this._isOutsideMode()){let e=this._props.containerWidth??this._props.getContainerWidth();this._$label.css({maxWidth:e})}}$element(){return this._$root}isVisible(){return this._isVisible()}getId(){if(this._isVisible())return this._id}updateMode(e){this._props.mode=e,this._toggleMarkupVisibility(),this._updateBeforeWidth(),this._updateMaxWidth()}updateText(e){this._props.text=e,this._updateText(),this._toggleMarkupVisibility(),this._updateBeforeWidth(),this._updateMaxWidth()}updateMark(e){this._props.mark=e,this._updateMark()}updateContainsButtonsBefore(e){this._props.containsButtonsBefore=e,this._updateEditorBeforeButtonsClass()}updateBeforeWidth(e){this._props.beforeWidth=e,this._updateBeforeWidth()}updateMaxWidth(e){this._props.containerWidth=e,this._updateMaxWidth()}};var Zp=class extends qo{_attachEvents(e,t){let{editor:n}=this;_.on(t,pr,()=>{n.$element().addClass("dx-custom-button-hovered")}),_.on(t,gr,()=>{n.$element().removeClass("dx-custom-button-hovered")}),_.on(t,oe,o=>{o.stopPropagation()})}_create(){let{editor:e}=this,t=u("<div>");this._addToContainer(t);let n=e._createComponent(t,rt,m({},this.options,{ignoreParentReadOnly:!0,disabled:this._isDisabled(),integrationOptions:this._prepareIntegrationOptions(e)}));return{$element:t,instance:n}}_prepareIntegrationOptions(e){return m({},e.option("integrationOptions"),{skipTemplates:["content"]})}update(){let e=super.update();return this.instance&&this.instance.option("disabled",this._isDisabled()),e}_isVisible(){let{editor:e}=this;return e.option("visible")}_isDisabled(){return this.options.disabled!==void 0?this.instance?this.instance.option("disabled"):this.options.disabled:this.editor.option("readOnly")}};function m4(i){(()=>{if(!i||typeof i!="object"||Array.isArray(i))throw Z.Error("E1053")})(),(()=>{if(!("name"in i))throw Z.Error("E1054")})(),(()=>{let{name:e}=i;if(typeof e!="string")throw Z.Error("E1055")})(),(()=>{let{location:e}=i;"location"in i&&e!=="after"&&e!=="before"&&(i.location="after")})()}function xM(i,e){if(i.indexOf(e)!==-1)throw Z.Error("E1055",e);i.push(e)}function f4(i,e){return!!e.find(t=>t.name===i)}var Ll=class{constructor(e,t){this.buttons=[],this.defaultButtonsInfo=t,this.editor=e}_compileButtonInfo(e){let t=[];return e.map(n=>{let o=typeof n=="string";if(o||m4(n),o||f4(n.name,this.defaultButtonsInfo)){let a=this.defaultButtonsInfo.find(l=>{let{name:d}=l;return d===n||d===n.name});if(!a)throw Z.Error("E1056",this.editor.NAME,n);return xM(t,n),a}let{name:r}=n;return xM(t,r),m(n,{Ctor:Zp})})}_createButton(e){let{Ctor:t,options:n,name:o}=e,s=new t(o,this.editor,n);return this.buttons.push(s),s}_renderButtons(e,t,n){let o=null;return(e?this._compileButtonInfo(e):this.defaultButtonsInfo).forEach(r=>{let{location:a="after"}=r;a===n&&this._createButton(r).render((o=o??u("<div>").addClass("dx-texteditor-buttons-container"),n==="before"?t.prepend(o):t.append(o),o))}),o}clean(){this.buttons.forEach(e=>e.dispose()),this.buttons=[]}getButton(e){let t=this.buttons.find(n=>{let{name:o}=n;return o===e});return t&&t.instance}renderAfterButtons(e,t){return this._renderButtons(e,t,"after")}renderBeforeButtons(e,t){return this._renderButtons(e,t,"before")}updateButtons(e){this.buttons.forEach(t=>{(!e||e.indexOf(t.name)!==-1)&&t.update()})}};var bM="dx-texteditor";var yM="dx-texteditor-input";var Jp=["KeyDown","KeyPress","KeyUp","Change","Cut","Copy","Paste","Input"],_4=["tab","enter","shift","control","alt","escape","pageUp","pageDown","end","home","leftArrow","upArrow","rightArrow","downArrow"],C4=Qp;function vM(i){if(f(i)&&!Array.isArray(i))throw Z.Error("E1053")}var x4=oi.inherit({ctor(i,e){e&&vM(e.buttons),this._buttonCollection=new Ll(this,this._getDefaultButtons()),this._$beforeButtonsContainer=null,this._$afterButtonsContainer=null,this._labelContainerElement=null,this.callBase.apply(this,arguments)},_getDefaultOptions(){return m(this.callBase(),{buttons:void 0,value:"",spellcheck:!1,showClearButton:!1,valueChangeEvent:"change",placeholder:"",inputAttr:{},onFocusIn:null,onFocusOut:null,onKeyDown:null,onKeyUp:null,onChange:null,onInput:null,onCut:null,onCopy:null,onPaste:null,onEnterKey:null,mode:"text",hoverStateEnabled:!0,focusStateEnabled:!0,text:void 0,displayValueFormatter:i=>f(i)&&i!==!1?i:"",stylingMode:fe().editorStylingMode||"outlined",showValidationMark:!0,label:"",labelMode:"static",labelMark:""})},_defaultOptionsRules(){return this.callBase().concat([{device(){let i=ct();return it(i)},options:{labelMode:"floating",stylingMode:fe().editorStylingMode||"filled"}},{device(){let i=ct();return ut(i)},options:{labelMode:"outside"}}])},_getDefaultButtons:()=>[{name:"clear",Ctor:Vl}],_isClearButtonVisible(){return this.option("showClearButton")&&!this.option("readOnly")},_input(){return this.$element().find(".dx-texteditor-input").first()},_isFocused(){return pn(this._input())||this.callBase()},_inputWrapper(){return this.$element()},_buttonsContainer(){return this._inputWrapper().find(".dx-texteditor-buttons-container").eq(0)},_isControlKey:i=>_4.includes(i),_renderStylingMode(){this.callBase(),this._updateButtonsStyling(this.option("stylingMode"))},_initMarkup(){this.$element().addClass("dx-texteditor"),this._renderInput(),this._renderButtonContainers(),this._renderStylingMode(),this._renderInputType(),this._renderPlaceholder(),this._renderProps(),this.callBase(),this._renderValue(),this._renderLabel()},_render(){this.callBase(),this._refreshValueChangeEvent(),this._refreshEvents(),this._renderEnterKeyAction(),this._renderEmptinessEvent()},_renderInput(){this._$textEditorContainer=u("<div>").addClass("dx-texteditor-container").appendTo(this.$element()),this._$textEditorInputContainer=u("<div>").addClass("dx-texteditor-input-container").appendTo(this._$textEditorContainer),this._$textEditorInputContainer.append(this._createInput())},_getInputContainer(){return this._$textEditorInputContainer},_renderPendingIndicator(){this.$element().addClass("dx-validation-pending");let i=this._getInputContainer(),e=u("<div>").addClass("dx-pending-indicator").appendTo(i);this._pendingIndicator=this._createComponent(e,ni)},_disposePendingIndicator(){this._pendingIndicator&&(this._pendingIndicator.dispose(),this._pendingIndicator.$element().remove(),this._pendingIndicator=null,this.$element().removeClass("dx-validation-pending"))},_renderValidationState(){this.callBase(),this.option("validationStatus")==="pending"?(!this._pendingIndicator&&this._renderPendingIndicator(),this._showValidMark=!1):(this.option("validationStatus")==="invalid"&&(this._showValidMark=!1),!this._showValidMark&&this.option("showValidationMark")===!0&&(this._showValidMark=this.option("validationStatus")==="valid"&&!!this._pendingIndicator),this._disposePendingIndicator()),this._toggleValidMark()},_getButtonsContainer(){return this._$textEditorContainer},_renderButtonContainers(){let i=this.option("buttons"),e=this._getButtonsContainer();this._$beforeButtonsContainer=this._buttonCollection.renderBeforeButtons(i,e),this._$afterButtonsContainer=this._buttonCollection.renderAfterButtons(i,e)},_cleanButtonContainers(){var i,e;(i=this._$beforeButtonsContainer)===null||i===void 0||i.remove(),(e=this._$afterButtonsContainer)===null||e===void 0||e.remove(),this._buttonCollection.clean()},_clean(){this._buttonCollection.clean(),this._disposePendingIndicator(),this._unobserveLabelContainerResize(),this._$beforeButtonsContainer=null,this._$afterButtonsContainer=null,this._$textEditorContainer=null,this.callBase()},_createInput(){let i=u("<input>");return this._applyInputAttributes(i,this.option("inputAttr")),i},_setSubmitElementName(i){let e=this.option("inputAttr.name");return this.callBase(i||e||"")},_applyInputAttributes(i,e){let t=m(this._getDefaultAttributes(),e);i.attr(t).addClass("dx-texteditor-input"),this._setInputMinHeight(i)},_setInputMinHeight(i){i.css("minHeight",this.option("height")?"0":"")},_getPlaceholderAttr(){let{ios:i,mac:e}=F.real(),{placeholder:t}=this.option();return t||(i||e?" ":null)},_getDefaultAttributes(){return{autocomplete:"off",placeholder:this._getPlaceholderAttr()}},_updateButtons(i){this._buttonCollection.updateButtons(i)},_updateButtonsStyling(i){x(this.option("buttons"),(e,t)=>{let{options:n,name:o}=t;if(n&&!n.stylingMode&&this.option("visible")){let s=this.getButton(o);s.option&&s.option("stylingMode",i==="underlined"?"text":"contained")}})},_renderValue(){return this._renderInputValue().promise()},_renderInputValue(i){i=i??this.option("value");let e=this.option("text"),t=this.option("displayValue"),n=this.option("displayValueFormatter");return t!==void 0&&i!==null?e=n(t):f(e)||(e=n(i)),this.option("text",e),this._input().val()!==(f(e)?e:"")?this._renderDisplayText(e):this._toggleEmptinessEventHandler(),y().resolve()},_renderDisplayText(i){this._input().val(i),this._toggleEmptinessEventHandler()},_isValueValid(){if(this._input().length){let{validity:i}=this._input().get(0);if(i)return i.valid}return!0},_toggleEmptiness(i){this.$element().toggleClass("dx-texteditor-empty",i),this._togglePlaceholder(i)},_togglePlaceholder(i){this.$element().find(".dx-placeholder").eq(0).toggleClass("dx-state-invisible",!i)},_renderProps(){this._toggleReadOnlyState(),this._toggleSpellcheckState(),this._toggleTabIndex()},_toggleDisabledState(i){this.callBase.apply(this,arguments),this._input().prop("disabled",i)},_toggleTabIndex(){let i=this._input(),e=this.option("disabled"),t=this.option("focusStateEnabled");e||!t?i.attr("tabIndex",-1):i.removeAttr("tabIndex")},_toggleReadOnlyState(){this._input().prop("readOnly",this._readOnlyPropValue()),this.callBase()},_readOnlyPropValue(){return this.option("readOnly")},_toggleSpellcheckState(){this._input().prop("spellcheck",this.option("spellcheck"))},_unobserveLabelContainerResize(){this._labelContainerElement&&(Wo.unobserve(this._labelContainerElement),this._labelContainerElement=null)},_getLabelContainer(){return this._input()},_getLabelContainerWidth(){return z(this._getLabelContainer())},_getLabelBeforeWidth(){return(this._$beforeButtonsContainer&&z(this._$beforeButtonsContainer))??0},_updateLabelWidth(){this._label.updateBeforeWidth(this._getLabelBeforeWidth()),this._label.updateMaxWidth(this._getLabelContainerWidth())},_getFieldElement(){return this._getLabelContainer()},_setFieldAria(i){var e;let t=this.option("inputAttr"),n=t?.["aria-label"],o=(e=this._label)===null||e===void 0?void 0:e.getId(),s=n?void 0:o;if(s||i){let r={labelledby:s,label:n};this.setAria(r,this._getFieldElement())}},_renderLabel(){this._unobserveLabelContainerResize(),this._labelContainerElement=u(this._getLabelContainer()).get(0);let{label:i,labelMode:e,labelMark:t,rtlEnabled:n}=this.option(),o={onClickHandler:()=>{this.focus()},onHoverHandler:s=>{s.stopPropagation()},onActiveHandler:s=>{s.stopPropagation()},$editor:this.$element(),text:i,mark:t,mode:e,rtlEnabled:n,containsButtonsBefore:!!this._$beforeButtonsContainer,getContainerWidth:()=>this._getLabelContainerWidth(),getBeforeWidth:()=>this._getLabelBeforeWidth()};this._label=new C4(o),this._setFieldAria(),this._labelContainerElement&&Wo.observe(this._labelContainerElement,this._updateLabelWidth.bind(this))},_renderPlaceholder(){this._renderPlaceholderMarkup(),this._attachPlaceholderEvents()},_renderPlaceholderMarkup(){this._$placeholder&&(this._$placeholder.remove(),this._$placeholder=null);let i=this._input(),e=this.option("placeholder"),t={id:e?`dx-${new Oe}`:void 0,"data-dx_placeholder":e},n=this._$placeholder=u("<div>").attr(t);n.insertAfter(i),n.addClass("dx-placeholder")},_attachPlaceholderEvents(){let i=D(ne.up,this.NAME);_.on(this._$placeholder,i,()=>{_.trigger(this._input(),"focus")}),this._toggleEmptinessEventHandler()},_placeholder(){return this._$placeholder||u()},_clearValueHandler(i){let e=this._input();i.stopPropagation(),this._saveValueChangeEvent(i),this._clearValue(),!this._isFocused()&&_.trigger(e,"focus"),_.trigger(e,"input")},_clearValue(){this.clear()},_renderEvents(){let i=this._input();x(Jp,(e,t)=>{if(this.hasActionSubscription(`on${t}`)){let n=this._createActionByOption(`on${t}`,{excludeValidators:["readOnly"]});_.on(i,D(t.toLowerCase(),this.NAME),o=>{this._disposed||n({event:o})})}})},_refreshEvents(){let i=this._input();x(Jp,(e,t)=>{_.off(i,D(t.toLowerCase(),this.NAME))}),this._renderEvents()},_keyPressHandler(){this.option("text",this._input().val())},_keyDownHandler(i){let e=this._input(),t=i.ctrlKey&&De(i)==="enter",n=e.val()!==this.option("value");t&&n&&_.trigger(e,"change")},_getValueChangeEventOptionName:()=>"valueChangeEvent",_renderValueChangeEvent(){let i=D(this._renderValueEventName(),`${this.NAME}TextChange`),e=D(this.option(this._getValueChangeEventOptionName()),`${this.NAME}ValueChange`),t=D("keydown",`${this.NAME}TextChange`),n=this._input();_.on(n,i,this._keyPressHandler.bind(this)),_.on(n,e,this._valueChangeEventHandler.bind(this)),_.on(n,t,this._keyDownHandler.bind(this))},_cleanValueChangeEvent(){let i=`.${this.NAME}ValueChange`,e=`.${this.NAME}TextChange`;_.off(this._input(),i),_.off(this._input(),e)},_refreshValueChangeEvent(){this._cleanValueChangeEvent(),this._renderValueChangeEvent()},_renderValueEventName:()=>"input change keypress",_focusTarget(){return this._input()},_focusEventTarget(){return this.element()},_isInput(i){return i===this._input().get(0)},_preventNestedFocusEvent(i){if(i.isDefaultPrevented())return!0;let e=this._isNestedTarget(i.relatedTarget);return i.type==="focusin"?e=e&&this._isNestedTarget(i.target)&&!this._isInput(i.target):e||this._toggleFocusClass(!1,this.$element()),e&&i.preventDefault(),e},_isNestedTarget(i){return!!this.$element().find(i).length},_focusClassTarget(){return this.$element()},_focusInHandler(i){this._preventNestedFocusEvent(i),this.callBase.apply(this,arguments)},_focusOutHandler(i){this._preventNestedFocusEvent(i),this.callBase.apply(this,arguments)},_toggleFocusClass(i,e){this.callBase(i,this._focusClassTarget(e))},_hasFocusClass(i){return this.callBase(u(i||this.$element()))},_renderEmptinessEvent(){let i=this._input();_.on(i,"input blur",this._toggleEmptinessEventHandler.bind(this))},_toggleEmptinessEventHandler(){let i=this._input().val(),e=(i===""||i===null)&&this._isValueValid();this._toggleEmptiness(e)},_valueChangeEventHandler(i,e){this.option("readOnly")||(this._saveValueChangeEvent(i),this.option("value",arguments.length>1?e:this._input().val()),this._saveValueChangeEvent(void 0))},_renderEnterKeyAction(){this._enterKeyAction=this._createActionByOption("onEnterKey",{excludeValidators:["readOnly"]}),_.off(this._input(),"keyup.onEnterKey.dxTextEditor"),_.on(this._input(),"keyup.onEnterKey.dxTextEditor",this._enterKeyHandlerUp.bind(this))},_enterKeyHandlerUp(i){this._disposed||De(i)==="enter"&&this._enterKeyAction({event:i})},_updateValue(){this._options.silent("text",null),this._renderValue()},_dispose(){this._enterKeyAction=void 0,this.callBase()},_getSubmitElement(){return this._input()},_hasActiveElement(){return this._input().is(w.getActiveElement(this._input()[0]))},_optionChanged(i){let{name:e,fullName:t,value:n}=i,o=e.replace("on","");if(Jp.includes(o)){this._refreshEvents();return}switch(e){case"valueChangeEvent":this._refreshValueChangeEvent(),this._refreshFocusEvent(),this._refreshEvents();break;case"onValueChanged":this._createValueChangeAction();break;case"focusStateEnabled":this.callBase(i),this._toggleTabIndex();break;case"spellcheck":this._toggleSpellcheckState();break;case"mode":this._renderInputType();break;case"onEnterKey":this._renderEnterKeyAction();break;case"placeholder":this._renderPlaceholder(),this._setFieldAria(!0),this._input().attr({placeholder:this._getPlaceholderAttr()});break;case"label":this._label.updateText(n),this._setFieldAria(!0);break;case"labelMark":this._label.updateMark(n);break;case"labelMode":this._label.updateMode(n),this._setFieldAria();break;case"width":this.callBase(i),this._label.updateMaxWidth(this._getLabelContainerWidth());break;case"readOnly":case"disabled":this._updateButtons(),this.callBase(i);break;case"showClearButton":this._updateButtons(["clear"]);break;case"text":case"showValidationMark":break;case"value":this._updateValue(),this.callBase(i);break;case"inputAttr":this._applyInputAttributes(this._input(),this.option(e));break;case"stylingMode":this._renderStylingMode(),this._updateLabelWidth();break;case"buttons":t===e&&vM(n),this._cleanButtonContainers(),this._renderButtonContainers(),this._updateButtonsStyling(this.option("stylingMode")),this._updateLabelWidth(),this._label.updateContainsButtonsBefore(!!this._$beforeButtonsContainer);break;case"visible":this.callBase(i),n&&this.option("buttons")&&(this._cleanButtonContainers(),this._renderButtonContainers(),this._updateButtonsStyling(this.option("stylingMode")));break;case"displayValueFormatter":this._invalidate();break;default:this.callBase(i)}},_renderInputType(){this._setInputType(this.option("mode"))},_setInputType(i){let e=this._input();i==="search"&&(i="text");try{e.prop("type",i)}catch{e.prop("type","text")}},getButton(i){return this._buttonCollection.getButton(i)},focus(){_.trigger(this._input(),"focus")},clear(){this._showValidMark&&(this._showValidMark=!1,this._renderValidationState());let i=this._getDefaultOptions();this.option("value")===i.value?(this._options.silent("text",""),this._renderValue()):this.option("value",i.value)},_resetInputText(){this._options.silent("text",this._initialValue),this._renderValue()},_isValueEqualToInitial(){let{value:i}=this.option(),e=this._initialValue;return i===e},_resetToInitialValue(){this._isValueEqualToInitial()?this._resetInputText():this.callBase(),this._disposePendingIndicator(),this._showValidMark=!1,this._toggleValidMark()},_toggleValidMark(){this.$element().toggleClass("dx-valid",!!this._showValidMark)},reset(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:void 0;arguments.length?this.callBase(i):this.callBase()},on(i,e){let t=this.callBase(i,e),n=i.charAt(0).toUpperCase()+i.substr(1);return Jp.includes(n)&&this._refreshEvents(),t}}),OM=x4;var eg=class{constructor(e){this._value=" ",m(this,e)}next(e){if(!arguments.length)return this._next;this._next=e}_prepareHandlingArgs(e,t){t=t||{};let n=Object.prototype.hasOwnProperty.call(e,"value")?"value":"text";return e[n]=t.str??e[n],e.start=t.start??e.start,e.length=t.length??e.length,e.index+=1,e}first(e){return e=e||0,this.next().first(e+1)}isAccepted(e){return!1}adjustedCaret(e,t,n){return t?this._adjustedForward(e,0,n):this._adjustedBackward(e,0,n)}_adjustedForward(e,t,n){}_adjustedBackward(e,t,n){}isValid(e){}reset(){}clear(e){}text(){}value(){}rawValue(){}handle(e){}},tg=class extends eg{next(){}handle(){return 0}text(){return""}value(){return""}first(){return 0}rawValue(){return""}adjustedCaret(){return 0}isValid(){return!0}},Vc=class extends eg{text(){return(this._value!==" "?this._value:this.maskChar)+this.next().text()}value(){return this._value+this.next().value()}rawValue(){return this._value+this.next().rawValue()}handle(e){let t=Object.prototype.hasOwnProperty.call(e,"value")?e.value:e.text;if(!t||!t.length||!e.length)return 0;if(e.start)return this.next().handle(this._prepareHandlingArgs(e,{start:e.start-1}));let n=t[0],o=t.substring(1);return this._tryAcceptChar(n,e),this._accepted()?this.next().handle(this._prepareHandlingArgs(e,{str:o,length:e.length-1}))+1:this.handle(this._prepareHandlingArgs(e,{str:o,length:e.length-1}))}clear(e){this._tryAcceptChar(" ",e),this.next().clear(this._prepareHandlingArgs(e))}reset(){this._accepted(!1),this.next().reset()}_tryAcceptChar(e,t){if(this._accepted(!1),!this._isAllowed(e,t))return;let n=e===" "?this.maskChar:e;t.fullText=t.fullText.substring(0,t.index)+n+t.fullText.substring(t.index+1),this._accepted(!0),this._value=e}_accepted(e){if(!arguments.length)return!!this._isAccepted;this._isAccepted=!!e}first(e){return this._value===" "?e||0:super.first(e)}_isAllowed(e,t){return e===" "?!0:this._isValid(e,t)}_isValid(e,t){let{allowedChars:n}=this;return n instanceof RegExp?n.test(e):A(n)?n(e,t.index,t.fullText):Array.isArray(n)?n.includes(e):n===e}isAccepted(e){return e===0?this._accepted():this.next().isAccepted(e-1)}_adjustedForward(e,t,n){return t>=e?t:this.next()._adjustedForward(e,t+1,n)||t+1}_adjustedBackward(e,t){return t>=e-1?e:this.next()._adjustedBackward(e,t+1)||t+1}isValid(e){return this._isValid(this._value,e)&&this.next().isValid(this._prepareHandlingArgs(e))}},Lc=class extends Vc{value(){return this.next().value()}handle(e){let t=Object.prototype.hasOwnProperty.call(e,"value"),n=t?e.value:e.text;if(!n.length||!e.length)return 0;if(e.start||t)return this.next().handle(this._prepareHandlingArgs(e,{start:e.start&&e.start-1}));let o=n[0],s=n.substring(1);this._tryAcceptChar(o);let r=this._isAllowed(o)?this._prepareHandlingArgs(e,{str:s,length:e.length-1}):e;return this.next().handle(r)+1}clear(e){this._accepted(!1),this.next().clear(this._prepareHandlingArgs(e))}_tryAcceptChar(e){this._accepted(this._isValid(e))}_isValid(e){return e===this.maskChar}first(e){return e=e||0,this.next().first(e+1)}_adjustedForward(e,t,n){return t>=e&&n===this.maskChar?t:e===t+1&&this._accepted()?e:this.next()._adjustedForward(e,t+1,n)}_adjustedBackward(e,t){return t>=e-1?0:this.next()._adjustedBackward(e,t+1)}isValid(e){return this.next().isValid(this._prepareHandlingArgs(e))}};var v4="blur beforedeactivate";var b4=["deleteContentBackward","deleteSoftLineBackward","deleteContent","deleteHardLineBackward"],y4=["historyUndo","historyRedo"],O4=["focusIn","focusOut","input","paste","cut","drop","beforeInput"];function S4(i){return" ".repeat(i)}var ig=class{constructor(e){this.editor=e}_editorOption(){return this.editor.option(...arguments)}_editorInput(){return this.editor._input()}_editorCaret(e){if(!e)return this.editor._caret();this.editor._caret(e)}_attachChangeEventHandler(){if(!this._editorOption("valueChangeEvent").split(" ").includes("change"))return;let e=this._editorInput(),t=D(v4,"dxMask");_.on(e,t,n=>{this.editor._changeHandler(n)})}_beforeInputHandler(){this._previousText=this._editorOption("text"),this._prevCaret=this._editorCaret()}_inputHandler(e){let{originalEvent:t}=e;if(!t)return;let{inputType:n}=t;if(y4.includes(n))this._handleHistoryInputEvent();else if(b4.includes(n))this._handleBackwardDeleteInputEvent();else{let o=this._editorCaret();if(!o.end)return;this._clearSelectedText(),this._autoFillHandler(t),this._editorCaret(o),this._handleInsertTextInputEvent(t.data)}this._editorOption("text")===this._previousText&&e.stopImmediatePropagation()}_handleHistoryInputEvent(){let e=this._editorCaret();this._updateEditorMask({start:e.start,length:e.end-e.start,text:""}),this._editorCaret(this._prevCaret)}_handleBackwardDeleteInputEvent(){this._clearSelectedText();let e=this._editorCaret();this.editor.setForwardDirection(),this.editor._adjustCaret(),this._editorCaret().start!==e.start&&(this.editor.setBackwardDirection(),this.editor._adjustCaret())}_clearSelectedText(){var e,t;let n=((e=this._prevCaret)===null||e===void 0?void 0:e.end)-((t=this._prevCaret)===null||t===void 0?void 0:t.start)||1,o=this._editorCaret();this._isAutoFill()||(this.editor.setBackwardDirection(),this._updateEditorMask({start:o.start,length:n,text:S4(n)}))}_handleInsertTextInputEvent(e){var t;let n=e??"";this.editor.setForwardDirection(),this._updateEditorMask({start:((t=this._prevCaret)===null||t===void 0?void 0:t.start)??0,length:n.length||1,text:n})||this._editorCaret(this._prevCaret)}_updateEditorMask(e){let t=e.text.length,n=this.editor._handleChain(e);if(this.editor._displayMask(),this.editor.isForwardDirection()){let{start:o,end:s}=this._editorCaret(),r=n-t;n>1&&t===1&&this._editorCaret({start:o+r,end:s+r}),this.editor._adjustCaret()}return!!n}_focusInHandler(){if(this.editor._showMaskPlaceholder(),this.editor.setForwardDirection(),!this.editor._isValueEmpty()&&this._editorOption("isValid"))this.editor._adjustCaret();else{let e=this.editor._maskRulesChain.first();this._caretTimeout=setTimeout(()=>{this._editorCaret({start:e,end:e})},0)}}_focusOutHandler(e){this.editor._changeHandler(e),this._editorOption("showMaskMode")==="onFocus"&&this.editor._isValueEmpty()&&(this._editorOption("text",""),this.editor._renderDisplayText(""))}_delHandler(e){let{editor:t}=this;t._maskKeyHandler(e,()=>{t._hasSelection()||t._handleKey(" ")})}_cutHandler(e){let t=this._editorCaret(),n=this._editorInput().val().substring(t.start,t.end);this.editor._maskKeyHandler(e,()=>ec(e,n))}_dropHandler(){this._clearDragTimer(),this._dragTimer=setTimeout(()=>{let e=this.editor._convertToValue(this._editorInput().val());this._editorOption("value",e)})}_pasteHandler(e){let{editor:t}=this;if(this._editorOption("disabled"))return;let n=this._editorCaret();t._maskKeyHandler(e,()=>{let o=ec(e),s=t._maskRulesChain.text().substring(n.end),r=t._handleChain({text:o,start:n.start,length:o.length}),a=n.start+r;t._handleChain({text:s,start:a,length:s.length}),t._caret({start:a,end:a})})}_autoFillHandler(e){let{editor:t}=this,n=this._editorInput().val();this._inputHandlerTimer=setTimeout(()=>{this._isAutoFill()&&(t._maskKeyHandler(e,()=>{t._handleChain({text:n,start:0,length:n.length})}),t._validateMask())})}_isAutoFill(){let e=this._editorInput();if(be.webkit){let t=e.get(0);return t?.matches(":-webkit-autofill")??!1}return!1}_clearDragTimer(){clearTimeout(this._dragTimer)}_clearTimers(){this._clearDragTimer(),clearTimeout(this._caretTimeout),clearTimeout(this._inputHandlerTimer)}getHandler(e){return t=>{var n;(n=this[`_${e}Handler`])===null||n===void 0||n.call(this,t)}}attachEvents(){let e=this._editorInput();O4.forEach(t=>{let n=D(t.toLowerCase(),"dxMask");_.on(e,n,this.getHandler(t))}),this._attachChangeEventHandler()}detachEvents(){this._clearTimers(),_.off(this._editorInput(),".dxMask")}clean(){this._clearTimers()}};var{ios:E4,mac:w4}=F.real(),I4=E4||w4,D4=function(i){let e;try{e={start:i.selectionStart,end:i.selectionEnd}}catch{e={start:0,end:0}}return e},T4=function(i,e){let t=w.getBody();if(!(!t.contains(i)&&!t.contains(i.getRootNode().host)))try{i.selectionStart=e.start,i.selectionEnd=e.end}catch{}},A4=function(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(i=u(i).get(0),!f(e))return D4(i);!t&&I4&&w.getActiveElement(i)!==i||T4(i,e)},SM=A4;var EM=SM;var M4={0:/[0-9]/,9:/[0-9\s]/,"#":/[-+0-9\s]/,L:i=>ng(i),l:i=>ng(i)||IM(i),C:/\S/,c:/./,A:i=>ng(i)||wM(i),a:i=>ng(i)||wM(i)||IM(i)};function wM(i){return/[0-9]/.test(i)}function ng(i){let e=i.charCodeAt();return e>64&&e<91||e>96&&e<123||e>127}function IM(i){return i===" "}var R4=OM.inherit({_getDefaultOptions(){return m(this.callBase(),{mask:"",maskChar:"_",maskRules:{},maskInvalidMessage:O.format("validation-mask"),useMaskedValue:!1,showMaskMode:"always"})},_supportedKeys(){let i=this,e={del:i._maskStrategy.getHandler("del"),enter:i._changeHandler},t=i.callBase();return x(e,(n,o)=>{let s=t[n];t[n]=function(r){i.option("mask")&&o.call(i,r),s&&s(r)}}),t},_getSubmitElement(){return this.option("mask")?this._$hiddenElement:this.callBase()},_init(){this.callBase(),this._initMaskStrategy()},_initMaskStrategy(){this._maskStrategy=new ig(this)},_initMarkup(){this._renderHiddenElement(),this.callBase()},_attachMouseWheelEventHandlers(){if(!(this._onMouseWheel!==S))return;let e=this._input(),t=D(dr,this.NAME),n=this._createAction(o=>{let{event:s}=o;pn(e)&&!ot(s)&&(this._onMouseWheel(s),s.preventDefault(),s.stopPropagation())});_.off(e,t),_.on(e,t,o=>{n({event:o})})},_onMouseWheel:S,_useMaskBehavior(){return!!this.option("mask")},_attachDropEventHandler(){if(!this._useMaskBehavior())return;let e=D("drop",this.NAME),t=this._input();_.off(t,e),_.on(t,e,n=>n.preventDefault())},_render(){this._attachMouseWheelEventHandlers(),this._renderMask(),this.callBase(),this._attachDropEventHandler()},_renderHiddenElement(){this.option("mask")&&(this._$hiddenElement=u("<input>").attr("type","hidden").appendTo(this._inputWrapper()))},_removeHiddenElement(){this._$hiddenElement&&this._$hiddenElement.remove()},_renderMask(){this.$element().removeClass("dx-texteditor-masked"),this._maskRulesChain=null,this._maskStrategy.detachEvents(),this.option("mask")&&(this.$element().addClass("dx-texteditor-masked"),this._maskStrategy.attachEvents(),this._parseMask(),this._renderMaskedValue())},_changeHandler(i){let e=this._input(),t=e.val();if(t===this._changedValue)return;this._changedValue=t;let n=uo(i,{type:"change"});_.trigger(e,n)},_parseMask(){this._maskRules=m({},M4,this.option("maskRules")),this._maskRulesChain=this._parseMaskRule(0)},_parseMaskRule(i){let e=this.option("mask");if(i>=e.length)return new tg;let t=e[i],n=t==="\\",o=n?new Lc({maskChar:e[i+1]}):this._getMaskRule(t);return o.next(this._parseMaskRule(i+1+n)),o},_getMaskRule(i){let e;return x(this._maskRules,(t,n)=>{if(t===i)return e={pattern:t,allowedChars:n},!1}),f(e)?new Vc(m({maskChar:this.option("maskChar")||" "},e)):new Lc({maskChar:i})},_renderMaskedValue(){if(!this._maskRulesChain)return;let i=this.option("value")||"";this._maskRulesChain.clear(this._normalizeChainArguments());let e={length:i.length};e[this._isMaskedValueMode()?"text":"value"]=i,this._handleChain(e),this._displayMask()},_replaceSelectedText(i,e,t){if(t===void 0)return i;let n=i.slice(0,e.start),o=i.slice(e.end);return n+t+o},_isMaskedValueMode(){return this.option("useMaskedValue")},_displayMask(i){i=i||this._caret(),this._renderValue(),this._caret(i)},_isValueEmpty(){return $a(this._value)},_shouldShowMask(){return this.option("showMaskMode")==="onFocus"?pn(this._input())||!this._isValueEmpty():!0},_showMaskPlaceholder(){if(this._shouldShowMask()){let i=this._maskRulesChain.text();this.option("text",i),this.option("showMaskMode")==="onFocus"&&this._renderDisplayText(i)}},_renderValue(){if(this._maskRulesChain&&(this._showMaskPlaceholder(),this._$hiddenElement)){let i=this._maskRulesChain.value(),e=$a(i)?"":this._getPreparedValue();this._$hiddenElement.val(e)}return this.callBase()},_getPreparedValue(){return this._convertToValue().replace(/\s+$/,"")},_valueChangeEventHandler(i){if(!this._maskRulesChain){this.callBase.apply(this,arguments);return}this._saveValueChangeEvent(i),this.option("value",this._getPreparedValue())},_isControlKeyFired(i){return this._isControlKey(De(i))||ot(i)},_handleChain(i){let e=this._maskRulesChain.handle(this._normalizeChainArguments(i));return this._updateMaskInfo(),e},_normalizeChainArguments(i){return i=i||{},i.index=0,i.fullText=this._maskRulesChain.text(),i},_convertToValue(i){return this._isMaskedValueMode()?i=this._replaceMaskCharWithEmpty(i||this._textValue||""):i=i||this._value||"",i},_replaceMaskCharWithEmpty(i){return i.replace(new RegExp(this.option("maskChar"),"g")," ")},_maskKeyHandler(i,e){if(this.option("readOnly"))return;this.setForwardDirection(),i.preventDefault(),this._handleSelection();let t=this._input().val(),n=()=>{t!==this._input().val()&&_.trigger(this._input(),"input")},o=e();o?o.then(n):(this.setForwardDirection(),this._adjustCaret(),this._displayMask(),this._maskRulesChain.reset(),n())},_handleKey(i,e){this._direction(e||"forward"),this._adjustCaret(i),this._handleKeyChain(i),this._moveCaret()},_handleSelection(){if(!this._hasSelection())return;let i=this._caret(),e=new Array(i.end-i.start+1).join(" ");this._handleKeyChain(e)},_handleKeyChain(i){let e=this._caret(),t=this.isForwardDirection()?e.start:e.start-1,n=this.isForwardDirection()?e.end:e.end-1,o=t===n?1:n-t;this._handleChain({text:i,start:t,length:o})},_tryMoveCaretBackward(){this.setBackwardDirection();let i=this._caret().start;return this._adjustCaret(),!i||i!==this._caret().start},_adjustCaret(i){let e=this._caret().start,t=this.isForwardDirection(),n=this._maskRulesChain.adjustedCaret(e,t,i);this._caret({start:n,end:n})},_moveCaret(){let i=this._caret().start,e=i+(this.isForwardDirection()?0:-1),t=this._maskRulesChain.isAccepted(e)?i+(this.isForwardDirection()?1:-1):i;this._caret({start:t,end:t})},_caret(i,e){let t=this._input();if(t.length){if(!arguments.length)return EM(t);EM(t,i,e)}},_hasSelection(){let i=this._caret();return i.start!==i.end},_direction(i){if(!arguments.length)return this._typingDirection;this._typingDirection=i},setForwardDirection(){this._direction("forward")},setBackwardDirection(){this._direction("backward")},isForwardDirection(){return this._direction()==="forward"},_updateMaskInfo(){this._textValue=this._maskRulesChain.text(),this._value=this._maskRulesChain.value()},_clean(){this._maskStrategy&&this._maskStrategy.clean(),this.callBase()},_validateMask(){if(!this._maskRulesChain)return;let i=$a(this.option("value"))||this._maskRulesChain.isValid(this._normalizeChainArguments());this.option({isValid:i,validationError:i?null:{editorSpecific:!0,message:this.option("maskInvalidMessage")}})},_updateHiddenElement(){this._removeHiddenElement(),this.option("mask")&&(this._input().removeAttr("name"),this._renderHiddenElement()),this._setSubmitElementName(this.option("name"))},_updateMaskOption(){this._updateHiddenElement(),this._renderMask(),this._validateMask(),this._refreshValueChangeEvent()},_processEmptyMask(i){if(i)return;let e=this.option("value");this.option({text:e,isValid:!0,validationError:null}),this.validationRequest.fire({value:e,editor:this}),this._renderValue()},_optionChanged(i){switch(i.name){case"mask":this._updateMaskOption(),this._processEmptyMask(i.value);break;case"maskChar":case"maskRules":case"useMaskedValue":this._updateMaskOption();break;case"value":this._renderMaskedValue(),this._validateMask(),this.callBase(i),this._changedValue=this._input().val();break;case"maskInvalidMessage":break;case"showMaskMode":this.option("text",""),this._renderValue();break;default:this.callBase(i)}},clear(){let{value:i}=this._getDefaultOptions();this.option("value")===i&&this._renderMaskedValue(),this.callBase()}}),Mv=R4;G("dxTextEditor",Mv);var og=Mv;var F4=K(),P4=["backspace","tab","enter","pageUp","pageDown","end","home","leftArrow","rightArrow","downArrow","upArrow","del"];var DM=og.inherit({ctor(i,e){e&&(this._showClearButton=e.showClearButton),this.callBase.apply(this,arguments)},_getDefaultOptions(){return m(this.callBase(),{value:"",mode:"text",maxLength:null})},_initMarkup(){this.$element().addClass("dx-textbox"),this.callBase(),this.setAria("role","textbox")},_renderInputType(){this.callBase(),this._renderSearchMode()},_useTemplates:()=>!1,_renderProps(){this.callBase(),this._toggleMaxLengthProp()},_toggleMaxLengthProp(){let i=this._getMaxLength();i&&i>0?this._input().attr("maxLength",i):this._input().removeAttr("maxLength")},_renderSearchMode(){let i=this._$element;this.option("mode")==="search"?(i.addClass("dx-searchbox"),this._renderSearchIcon(),this._showClearButton===void 0&&(this._showClearButton=this.option("showClearButton"),this.option("showClearButton",!0))):(i.removeClass("dx-searchbox"),this._$searchIcon&&this._$searchIcon.remove(),this.option("showClearButton",this._showClearButton===void 0?this.option("showClearButton"):this._showClearButton),delete this._showClearButton)},_renderSearchIcon(){let i=u("<div>").addClass("dx-icon").addClass("dx-icon-search");i.prependTo(this._input().parent()),this._$searchIcon=i},_getLabelContainerWidth(){if(this._$searchIcon){let i=this._input().parent();return z(i)-this._getLabelBeforeWidth()}return this.callBase()},_getLabelBeforeWidth(){let i=this.callBase();return this._$searchIcon&&(i+=ie(this._$searchIcon)),i},_optionChanged(i){switch(i.name){case"maxLength":this._toggleMaxLengthProp();break;case"mode":this.callBase(i),this._updateLabelWidth();break;case"mask":this.callBase(i),this._toggleMaxLengthProp();break;default:this.callBase(i)}},_onKeyDownCutOffHandler(i){let e=this._getMaxLength();if(e&&!i.ctrlKey&&!this._hasSelection()){let t=u(i.target),n=De(i);return this._cutOffExtraChar(t),t.val().length<e||P4.includes(n)||F4.getSelection().toString()!==""}return!0},_onChangeCutOffHandler(i){let e=u(i.target);this.option("maxLength")&&this._cutOffExtraChar(e)},_cutOffExtraChar(i){let e=this._getMaxLength(),t=i.val();e&&t.length>e&&i.val(t.substr(0,e))},_getMaxLength(){return!!this.option("mask")?null:this.option("maxLength")}});G("dxTextBox",DM);var TM=DM;var AM=TM;var Xn=AM;var k4="dx-dropdowneditor-button-visible",B4="dxDropDownEditor-selectLabel",Nl=class extends qo{constructor(e,t,n){super(e,t,n),this.currentTemplate=null}_attachEvents(e){let{editor:t}=this;e.option("onClick",n=>{var o;if((o=t._shouldCallOpenHandler)!==null&&o!==void 0&&o.call(t)){t._openHandler(n);return}!t.option("openOnFieldClick")&&t._openHandler(n)}),_.on(e.$element(),"mousedown",n=>{t.$element().is(".dx-state-focused")&&n.preventDefault()})}_create(){let{editor:e}=this,t=u("<div>"),n=this._getOptions();this._addToContainer(t);let o=e._createComponent(t,rt,m({},n,{elementAttr:{"aria-label":O.format(B4)}}));return this._legacyRender(e.$element(),t,n.visible),{$element:t,instance:o}}_getOptions(){let{editor:e}=this,t=this._isVisible(),o={focusStateEnabled:!1,hoverStateEnabled:!1,activeStateEnabled:!1,useInkRipple:!1,disabled:e.option("readOnly"),visible:t};return this._addTemplate(o),o}_isVisible(){let{editor:e}=this;return super._isVisible()&&e.option("showDropDownButton")}_legacyRender(e,t,n){e.toggleClass(k4,n),t&&t.removeClass("dx-button").removeClass("dx-button-mode-contained").addClass("dx-dropdowneditor-button")}_isSameTemplate(){return this.editor.option("dropDownButtonTemplate")===this.currentTemplate}_addTemplate(e){this._isSameTemplate()||(e.template=this.editor._getTemplateByOption("dropDownButtonTemplate"),this.currentTemplate=this.editor.option("dropDownButtonTemplate"))}update(){if(super.update()){let{editor:t,instance:n}=this,o=t.$element(),s=this._getOptions();n?.option(s),this._legacyRender(o,n?.$element(),s.visible)}}};var Hl=function(i){if(W())return ie(i)},$l=function(i){return i===null&&(i=void 0),typeof i=="function"&&(i=i()),i};var FM="dx-dropdowneditor",MM="dx-dropdowneditor-input-wrapper";var sg="dx-dropdowneditor-overlay",V4="dx-dropdowneditor-overlay-flipped",L4="dx-dropdowneditor-active",N4="dx-dropdowneditor-field-clickable",H4="dx-dropdowneditor-field-template-wrapper";var RM=F.current().platform==="ios",PM=Xn.inherit({_supportedKeys(){return m({},this.callBase(),{tab(i){if(!this.option("opened"))return;if(!this._popup.getFocusableElements().length){this.close();return}let e=i.shiftKey?this._getLastPopupElement():this._getFirstPopupElement();e&&(_.trigger(e,"focus"),e.select()),i.preventDefault()},escape(i){return this.option("opened")&&i.preventDefault(),this.close(),!0},upArrow(i){return!ot(i)&&(i.preventDefault(),i.stopPropagation(),i.altKey)?(this.close(),!1):!0},downArrow(i){return!ot(i)&&(i.preventDefault(),i.stopPropagation(),i.altKey)?(this._validatedOpening(),!1):!0},enter(i){return this.option("opened")&&(i.preventDefault(),this._valueChangeEventHandler(i)),!0}})},_getDefaultButtons(){return this.callBase().concat([{name:"dropDown",Ctor:Nl}])},_getDefaultOptions(){return m(this.callBase(),{value:null,onOpened:null,onClosed:null,opened:!1,acceptCustomValue:!0,applyValueMode:"instantly",deferRendering:!0,activeStateEnabled:!0,dropDownButtonTemplate:"dropDownButton",fieldTemplate:null,openOnFieldClick:!1,showDropDownButton:!0,buttons:void 0,dropDownOptions:{showTitle:!1},popupPosition:this._getDefaultPopupPosition(),onPopupInitialized:null,applyButtonText:O.format("OK"),cancelButtonText:O.format("Cancel"),buttonsLocation:"default",useHiddenSubmitElement:!1,validationMessagePosition:"auto"})},_useTemplates:()=>!0,_getDefaultPopupPosition(i){let e=Ui(i);return{offset:{h:0,v:-1},my:`${e} top`,at:`${e} bottom`,collision:"flip flip"}},_defaultOptionsRules(){return this.callBase().concat([{device(i){return i.platform==="generic"},options:{popupPosition:{offset:{v:0}}}}])},_inputWrapper(){return this.$element().find(`.${MM}`).first()},_init(){this.callBase(),this._initVisibilityActions(),this._initPopupInitializedAction(),this._updatePopupPosition(this.option("rtlEnabled")),this._options.cache("dropDownOptions",this.option("dropDownOptions"))},_updatePopupPosition(i){let{my:e,at:t}=this._getDefaultPopupPosition(i),n=this.option("popupPosition");this.option("popupPosition",m({},n,{my:e,at:t}))},_initVisibilityActions(){this._openAction=this._createActionByOption("onOpened",{excludeValidators:["disabled","readOnly"]}),this._closeAction=this._createActionByOption("onClosed",{excludeValidators:["disabled","readOnly"]})},_initPopupInitializedAction(){this._popupInitializedAction=this._createActionByOption("onPopupInitialized",{excludeValidators:["disabled","readOnly"]})},_initMarkup(){this._renderSubmitElement(),this.callBase(),this.$element().addClass("dx-dropdowneditor"),this.setAria("role",this._getAriaRole())},_render(){this._detachFocusEvents(),this.callBase(),this._renderOpenHandler(),this._attachFocusOutHandler(),this._renderOpenedState()},_renderContentImpl(){this.option("deferRendering")||this._createPopup()},_renderInput(){this.callBase(),this._renderTemplateWrapper(),this._wrapInput(),this._setDefaultAria()},_wrapInput(){this._$container=this.$element().wrapInner(u("<div>").addClass(MM)).children().eq(0)},_getAriaHasPopup:()=>"true",_getAriaAutocomplete:()=>"none",_getAriaRole:()=>"combobox",_setDefaultAria(){this.setAria({haspopup:this._getAriaHasPopup(),autocomplete:this._getAriaAutocomplete(),role:this._getAriaRole()})},_readOnlyPropValue(){return!this._isEditable()||this.callBase()},_cleanFocusState(){this.callBase(),this.option("fieldTemplate")&&this._detachFocusEvents()},_getFieldTemplate(){return this.option("fieldTemplate")&&this._getTemplateByOption("fieldTemplate")},_renderMask(){this.option("fieldTemplate")||this.callBase()},_renderField(){let i=this._getFieldTemplate();i&&this._renderTemplatedField(i,this._fieldRenderData())},_renderPlaceholder(){!!this._getFieldTemplate()||this.callBase()},_renderValue(){this.option("useHiddenSubmitElement")&&this._setSubmitValue(),this.callBase().always(this._renderField.bind(this))},_getButtonsContainer(){return this._getFieldTemplate()?this._$container:this._$textEditorContainer},_renderTemplateWrapper(){this._getFieldTemplate()&&(this._$templateWrapper||(this._$templateWrapper=u("<div>").addClass(H4).prependTo(this.$element())))},_renderTemplatedField(i,e){let t=pn(this._input());this._detachKeyboardEvents(),this._detachFocusEvents(),this._$textEditorContainer.remove(),this._$templateWrapper.empty();let n=this._$templateWrapper,o=Symbol("renderContext");this._activeRenderContext=o,i.render({model:e,container:N(n),onRendered:()=>{if(this._activeRenderContext!==o||!!!this.$element().find(n).length)return;let r=this._input();if(!r.length)throw Z.Error("E1010");this._integrateInput(),t&&_.trigger(r,"focus")}})},_integrateInput(){var i;let{isValid:e}=this.option();this._renderFocusState(),this._refreshValueChangeEvent(),this._refreshEvents(),this._refreshEmptinessEvent(),this._setDefaultAria(),this._setFieldAria(),this._toggleValidationClasses(!e),(i=this.option("_onMarkupRendered"))===null||i===void 0||i()},_refreshEmptinessEvent(){_.off(this._input(),"input blur",this._toggleEmptinessEventHandler),this._renderEmptinessEvent()},_fieldRenderData(){return this.option("value")},_initTemplates(){this._templateManager.addDefaultTemplates({dropDownButton:new gn(i=>{let e=u("<div>").addClass("dx-dropdowneditor-icon");u(i.container).append(e)})}),this.callBase()},_renderOpenHandler(){let i=this._inputWrapper(),e=D(oe,this.NAME),t=this.option("openOnFieldClick");_.off(i,e),_.on(i,e,this._getInputClickHandler(t)),this.$element().toggleClass(N4,t),t&&(this._openOnFieldClickAction=this._createAction(this._openHandler.bind(this)))},_attachFocusOutHandler(){RM&&(this._detachFocusOutEvents(),_.on(this._inputWrapper(),D("focusout",this.NAME),i=>{let e=i.relatedTarget;e&&this.option("opened")&&this._isTargetOutOfComponent(e)&&this.close()}))},_isTargetOutOfComponent(i){let e=this.content?u(this.content()).closest(`.${sg}`):this._$popup;return u(i).closest(`.${sg}`,e).length===0},_detachFocusOutEvents(){RM&&_.off(this._inputWrapper(),D("focusout",this.NAME))},_getInputClickHandler(i){return i?e=>{this._executeOpenAction(e)}:()=>{this._focusInput()}},_openHandler(){this._toggleOpenState()},_executeOpenAction(i){this._openOnFieldClickAction({event:i})},_keyboardEventBindingTarget(){return this._input()},_focusInput(){return this.option("disabled")?!1:(this.option("focusStateEnabled")&&!pn(this._input())&&(this._resetCaretPosition(),_.trigger(this._input(),"focus")),!0)},_resetCaretPosition(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,e=this._input().get(0);if(e){let{value:t}=e,n=f(t)&&(i||this._isEditable())?t.length:0;this._caret({start:n,end:n},!0)}},_isEditable(){return this.option("acceptCustomValue")},_toggleOpenState(i){this._focusInput()&&(this.option("readOnly")||(i=arguments.length?i:!this.option("opened"),this.option("opened",i)))},_getControlsAria(){return this._popup&&this._popupContentId},_renderOpenedState(){let i=this.option("opened");i&&this._createPopup(),this.$element().toggleClass(L4,i),this._setPopupOption("visible",i);let e={expanded:i,controls:this._getControlsAria()};this.setAria(e),this.setAria("owns",i?this._popupContentId:void 0,this.$element())},_createPopup(){this._$popup||(this._$popup=u("<div>").addClass(sg).appendTo(this.$element()),this._renderPopup(),this._renderPopupContent(),this._setPopupAriaLabel())},_setPopupAriaLabel(){let i=this._popup.$overlayContent();this.setAria("label","Dropdown",i)},_renderPopupContent:S,_renderPopup(){let i=m(this._popupConfig(),this._options.cache("dropDownOptions"));delete i.closeOnOutsideClick,this._popup=this._createComponent(this._$popup,ii,i),this._popup.on({showing:this._popupShowingHandler.bind(this),shown:this._popupShownHandler.bind(this),hiding:this._popupHidingHandler.bind(this),hidden:this._popupHiddenHandler.bind(this),contentReady:this._contentReadyHandler.bind(this)}),this._attachPopupKeyHandler(),this._contentReadyHandler(),this._setPopupContentId(this._popup.$content()),this._bindInnerWidgetOptions(this._popup,"dropDownOptions")},_attachPopupKeyHandler(){_.on(this._popup.$overlayContent(),D("keydown",this.NAME),i=>this._popupKeyHandler(i))},_popupKeyHandler(i){switch(De(i)){case"tab":this._popupTabHandler(i);break;case"escape":this._popupEscHandler(i)}},_popupTabHandler(i){let e=u(i.target),t=i.shiftKey&&e.is(this._getFirstPopupElement());(!i.shiftKey&&e.is(this._getLastPopupElement())||t)&&(_.trigger(this.field(),"focus"),i.preventDefault())},_popupEscHandler(){_.trigger(this._input(),"focus"),this.close()},_setPopupContentId(i){this._popupContentId=`dx-${new Oe}`,this.setAria("id",this._popupContentId,i)},_contentReadyHandler:S,_popupConfig(){return{onInitialized:this._getPopupInitializedHandler(),position:m(this.option("popupPosition"),{of:this.$element()}),showTitle:this.option("dropDownOptions.showTitle"),_ignoreFunctionValueDeprecation:!0,width:()=>Hl(this.$element()),height:"auto",shading:!1,hideOnParentScroll:!0,hideOnOutsideClick:i=>this._closeOutsideDropDownHandler(i),animation:{show:{type:"fade",duration:0,from:0,to:1},hide:{type:"fade",duration:400,from:1,to:0}},deferRendering:!1,focusStateEnabled:!1,showCloseButton:!1,dragEnabled:!1,toolbarItems:this._getPopupToolbarItems(),onPositioned:this._popupPositionedHandler.bind(this),fullScreen:!1,contentTemplate:null,_hideOnParentScrollTarget:this.$element(),_wrapperClassExternal:sg,_ignorePreventScrollEventsDeprecation:!0}},_popupInitializedHandler:S,_getPopupInitializedHandler(){let i=this.option("onPopupInitialized");return e=>{this._popupInitializedHandler(e),i&&this._popupInitializedAction({popup:e.component})}},_dimensionChanged(){if(W()&&!this.$element().is(":visible")){this.close();return}this._updatePopupWidth()},_updatePopupWidth(){$l(this.option("dropDownOptions.width"))===void 0&&this._setPopupOption("width",()=>Hl(this.$element()))},_popupPositionedHandler(i){var e;let{labelMode:t,stylingMode:n}=this.option();if(!this._popup)return;let o=this._popup.$overlayContent(),s=(e=i.position)===null||e===void 0||(e=e.v)===null||e===void 0?void 0:e.flip,r=t!=="hidden"&&t!=="outside"&&n==="outlined";if(i.position&&o.toggleClass(V4,s),s&&r&&this._label.isVisible()){let a=this._label.$element();Ae(o,{top:li(o).top-parseInt(a.css("fontSize"))})}},_popupShowingHandler:S,_popupHidingHandler(){this.option("opened",!1)},_popupShownHandler(){var i;this._openAction(),(i=this._validationMessage)===null||i===void 0||i.option("positionSide",this._getValidationMessagePositionSide())},_popupHiddenHandler(){var i;this._closeAction(),(i=this._validationMessage)===null||i===void 0||i.option("positionSide",this._getValidationMessagePositionSide())},_getValidationMessagePositionSide(){let i=this.option("validationMessagePosition");if(i!=="auto")return i;let e="bottom";if(this._popup&&this._popup.option("visible")){let{top:t}=lt.setup(this.$element()),{top:n}=lt.setup(this._popup.$content());e=t+this.option("popupPosition").offset.v>n?"bottom":"top"}return e},_closeOutsideDropDownHandler(i){let{target:e}=i,t=u(e),n=this.getButton("dropDown"),o=n&&n.$element(),s=!!t.closest(this.$element()).length,r=!!t.closest(o).length;return!s&&!r},_clean(){delete this._openOnFieldClickAction,delete this._$templateWrapper,this._$popup&&(this._$popup.remove(),delete this._$popup,delete this._popup),this.callBase()},_setPopupOption(i,e){this._setWidgetOption("_popup",arguments)},_validatedOpening(){this.option("readOnly")||this._toggleOpenState(!0)},_getPopupToolbarItems(){return this.option("applyValueMode")==="useButtons"?this._popupToolbarItemsConfig():[]},_getFirstPopupElement(){return u(this._popup.getFocusableElements()).first()},_getLastPopupElement(){return u(this._popup.getFocusableElements()).last()},_popupToolbarItemsConfig(){let i=[{shortcut:"done",options:{onClick:this._applyButtonHandler.bind(this),text:this.option("applyButtonText")}},{shortcut:"cancel",options:{onClick:this._cancelButtonHandler.bind(this),text:this.option("cancelButtonText")}}];return this._applyButtonsLocation(i)},_applyButtonsLocation(i){let e=this.option("buttonsLocation"),t=i;if(e!=="default"){let n=Mo(e);x(t,(o,s)=>{m(s,{toolbar:n[0],location:n[1]})})}return t},_applyButtonHandler(){this.close(),this.option("focusStateEnabled")&&this.focus()},_cancelButtonHandler(){this.close(),this.option("focusStateEnabled")&&this.focus()},_popupOptionChanged(i){let e=Xe.getOptionsFromContainer(i);this._setPopupOption(e);let t=Object.keys(e);(t.includes("width")||t.includes("height"))&&this._dimensionChanged()},_renderSubmitElement(){this.option("useHiddenSubmitElement")&&(this._$submitElement=u("<input>").attr("type","hidden").appendTo(this.$element()))},_setSubmitValue(){this._getSubmitElement().val(this.option("value"))},_getSubmitElement(){return this.option("useHiddenSubmitElement")?this._$submitElement:this.callBase()},_dispose(){this._detachFocusOutEvents(),this.callBase()},_optionChanged(i){var e;switch(i.name){case"width":case"height":this.callBase(i),(e=this._popup)===null||e===void 0||e.repaint();break;case"opened":this._renderOpenedState();break;case"onOpened":case"onClosed":this._initVisibilityActions();break;case"onPopupInitialized":this._initPopupInitializedAction();break;case"fieldTemplate":case"acceptCustomValue":case"openOnFieldClick":this._invalidate();break;case"dropDownButtonTemplate":case"showDropDownButton":this._updateButtons(["dropDown"]);break;case"dropDownOptions":this._popupOptionChanged(i),this._options.cache("dropDownOptions",this.option("dropDownOptions"));break;case"popupPosition":break;case"deferRendering":W()&&this._createPopup();break;case"applyValueMode":case"applyButtonText":case"cancelButtonText":case"buttonsLocation":this._setPopupOption("toolbarItems",this._getPopupToolbarItems());break;case"useHiddenSubmitElement":this._$submitElement&&(this._$submitElement.remove(),this._$submitElement=void 0),this._renderSubmitElement();break;case"rtlEnabled":this._updatePopupPosition(i.value),this.callBase(i);break;default:this.callBase(i)}},open(){this.option("opened",!0)},close(){this.option("opened",!1)},field(){return N(this._input())},content(){return this._popup?this._popup.content():null}});G("dxDropDownEditor",PM);var zl=PM;var kM=K();var $4=["startswith","contains","endwith","notcontains"],BM=F.real().platform!=="android",VM=zl.inherit({_supportedKeys(){let i=this.callBase();return m({},i,{tab(e){if(this._allowSelectItemByTab()){this._saveValueChangeEvent(e);let t=u(this._list.option("focusedElement"));t.length&&this._setSelectedElement(t)}i.tab.apply(this,arguments)},space:S,home:S,end:S})},_allowSelectItemByTab(){return this.option("opened")&&this.option("applyValueMode")==="instantly"},_setSelectedElement(i){let e=this._valueGetter(this._list._getItemData(i));this._setValue(e)},_setValue(i){this.option("value",i)},_getDefaultOptions(){return m(this.callBase(),m(Pc._dataExpressionDefaultOptions(),{displayValue:void 0,searchEnabled:!1,searchMode:"contains",searchTimeout:500,minSearchLength:0,searchExpr:null,valueChangeEvent:"input change keyup",selectedItem:null,noDataText:O.format("dxCollectionWidget-noDataText"),encodeNoDataText:!1,onSelectionChanged:null,onItemClick:S,showDataBeforeSearch:!1,grouped:!1,groupTemplate:"group",popupPosition:{my:"left top",at:"left bottom",offset:{h:0,v:0},collision:"flip"},wrapItemText:!1,useItemTextAsTitle:!1}))},_defaultOptionsRules(){return this.callBase().concat([{device:{platform:"ios"},options:{popupPosition:{offset:{v:-1}}}},{device:{platform:"generic"},options:{buttonsLocation:"bottom center"}}])},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{value:!0,selectedItem:!0,displayValue:!0})},_init(){this.callBase(),this._initDataExpressions(),this._initActions(),this._setListDataSource(),this._validateSearchMode(),this._clearSelectedItem(),this._initItems()},_setListFocusedElementOptionChange(){this._list._updateParentActiveDescendant=this._updateActiveDescendant.bind(this)},_initItems(){let{items:i}=this.option();i&&!i.length&&this._dataSource&&(this.option().items=this._dataSource.items())},_initActions(){this._initContentReadyAction(),this._initSelectionChangedAction(),this._initItemClickAction()},_initContentReadyAction(){this._contentReadyAction=this._createActionByOption("onContentReady",{excludeValidators:["disabled","readOnly"]})},_initSelectionChangedAction(){this._selectionChangedAction=this._createActionByOption("onSelectionChanged",{excludeValidators:["disabled","readOnly"]})},_initItemClickAction(){this._itemClickAction=this._createActionByOption("onItemClick")},_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({item:new hr("item")})},_isEditable(){return this.callBase()||this.option("searchEnabled")},_saveFocusOnWidget(){this._list&&this._list.initialOption("focusStateEnabled")&&this._focusInput()},_fitIntoRange(i,e,t){return i>t?e:i<e?t:i},_items(){let i=this._getPlainItems(!this._list&&this._dataSource.items());return new vt(i).filter("disabled","<>",!0).toArray()},_calcNextItem(i){let e=this._items(),t=this._fitIntoRange(this._getSelectedIndex()+i,0,e.length-1);return e[t]},_getSelectedIndex(){let i=this._items(),e=this.option("selectedItem"),t=-1;return x(i,(n,o)=>{if(this._isValueEquals(o,e))return t=n,!1}),t},_createPopup(){this.callBase(),this._updateCustomBoundaryContainer(),this._popup.$wrapper().addClass(this._popupWrapperClass());let i=this._popup.$content();_.off(i,"mouseup"),_.on(i,"mouseup",this._saveFocusOnWidget.bind(this))},_updateCustomBoundaryContainer(){let i=this.option("dropDownOptions.container"),e=i&&u(i);if(e&&e.length&&!Ne(e.get(0))){let t=[].slice.call(e.parents());t.unshift(e.get(0)),x(t,(n,o)=>{if(o===u("body").get(0))return!1;if(kM.getComputedStyle(o).overflowY==="hidden")return this._$customBoundaryContainer=u(o),!1})}},_popupWrapperClass:()=>"dx-dropdownlist-popup-wrapper",_renderInputValue(){var i=this;let{value:e,renderOnly:t}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=e??this._getCurrentValue();return this._rejectValueLoading(),t?this.callBase(n):this._loadInputValue(n,function(){i._setSelectedItem(...arguments)}).always(this.callBase.bind(this,n))},_loadInputValue(i,e){return this._loadItem(i).always(e)},_getItemFromPlain(i,e){let t,n;return e&&typeof i!="object"&&(e.itemByValue||(e.itemByValue={},t=this._getPlainItems(),t.forEach(function(o){e.itemByValue[this._valueGetter(o)]=o},this)),n=e.itemByValue[i]),n||(t=this._getPlainItems(),n=xt(t,o=>this._isValueEquals(this._valueGetter(o),i))[0]),n},_resetInputText(){this._renderInputValue({renderOnly:!0})},_loadItem(i,e){let t=this._getItemFromPlain(i,e);return t!==void 0?y().resolve(t).promise():this._loadValue(i)},_getPlainItems(i){let e=[];i=i||this.option("items")||this._dataSource.items()||[];for(let t=0;t<i.length;t++)i[t]&&i[t].items?e=e.concat(i[t].items):e.push(i[t]);return e},_updateActiveDescendant(i){var e;let t=this.option("opened"),n=(e=this._list)===null||e===void 0?void 0:e.getFocusedItemId(),o=u(`#${n}`).length>0,s=t&&o&&n;this.setAria({activedescendant:s||null},i)},_setSelectedItem(i){let e=this._displayValue(i);this.option("selectedItem",Te(i,null)),this.option("displayValue",e)},_displayValue(i){return this._displayGetter(i)},_refreshSelected(){let i={};this._listItemElements().each((e,t)=>{let n=u(t),o=this._valueGetter(n.data("dxListItemData"));this._isSelectedValue(o,i)?this._list.selectItem(n):this._list.unselectItem(n)})},_popupShownHandler(){this.callBase(),this._setFocusPolicy()},_setFocusPolicy(){!this.option("focusStateEnabled")||!this._list||this._list.option("focusedElement",null)},_isSelectedValue(i){return this._isValueEquals(i,this.option("value"))},_validateSearchMode(){let i=this.option("searchMode"),e=i.toLowerCase();if(!$4.includes(e))throw Z.Error("E1019",i)},_clearSelectedItem(){this.option("selectedItem",null)},_processDataSourceChanging(){this._initDataController(),this._setListOption("_dataController",this._dataController),this._setListDataSource(),this._renderInputValue().fail(()=>{this._isCustomValueAllowed()||this._clearSelectedItem()})},_isCustomValueAllowed(){return this.option("displayCustomValue")},clear(){this.callBase(),this._clearFilter(),this._clearSelectedItem()},_listItemElements(){return this._$list?this._$list.find(".dx-list-item"):u()},_popupConfig(){return m(this.callBase(),{templatesRenderAsynchronously:!1,autoResizeEnabled:!1,maxHeight:this._getMaxHeight.bind(this)})},_renderPopupContent(){this.callBase(),this._renderList()},_getKeyboardListeners(){let i=this._canListHaveFocus();return this.callBase().concat([!i&&this._list])},_renderList(){this._listId=`dx-${new Oe()._value}`;let i=u("<div>").attr("id",this._listId).appendTo(this._popup.$content());this._$list=i,this._list=this._createComponent(i,jo,this._listConfig()),this._refreshList(),this._renderPreventBlurOnListClick(),this._setListFocusedElementOptionChange()},_renderPreventBlurOnListClick(){let i=D("mousedown","dxDropDownList");_.off(this._$list,i),_.on(this._$list,i,e=>e.preventDefault())},_getControlsAria(){return this._list&&this._listId},_renderOpenedState(){this.callBase(),this._list&&this._updateActiveDescendant(),this.setAria("owns",this._popup&&this._popupContentId)},_getAriaHasPopup:()=>"listbox",_refreshList(){this._list&&this._shouldRefreshDataSource()&&this._setListDataSource()},_shouldRefreshDataSource(){return!!this._list.option("dataSource")!==this._needPassDataSourceToList()},_isDesktopDevice:()=>F.real().deviceType==="desktop",_listConfig(){let i={selectionMode:"single",_templates:this.option("_templates"),templateProvider:this.option("templateProvider"),noDataText:this.option("noDataText"),encodeNoDataText:this.option("encodeNoDataText"),grouped:this.option("grouped"),wrapItemText:this.option("wrapItemText"),useItemTextAsTitle:this.option("useItemTextAsTitle"),onContentReady:this._listContentReadyHandler.bind(this),itemTemplate:this.option("itemTemplate"),indicateLoading:!1,keyExpr:this._getCollectionKeyExpr(),displayExpr:this._displayGetterExpr(),groupTemplate:this.option("groupTemplate"),onItemClick:this._listItemClickAction.bind(this),dataSource:this._getDataSource(),_dataController:this._dataController,hoverStateEnabled:this._isDesktopDevice()?this.option("hoverStateEnabled"):!1,focusStateEnabled:this._isDesktopDevice()?this.option("focusStateEnabled"):!1};return this._canListHaveFocus()||(i.tabIndex=null),i},_canListHaveFocus:()=>!1,_getDataSource(){return this._needPassDataSourceToList()?this._dataSource:null},_dataSourceOptions:()=>({paginate:!1}),_getGroupedOption(){return this.option("grouped")},_dataSourceFromUrlLoadMode:()=>"raw",_listContentReadyHandler(){this._list=this._list||this._$list.dxList("instance"),this.option("deferRendering")||this._refreshSelected(),this._updatePopupWidth(),this._updateListDimensions(),this._contentReadyAction()},_setListOption(i,e){this._setWidgetOption("_list",arguments)},_listItemClickAction(i){this._listItemClickHandler(i),this._itemClickAction(i)},_listItemClickHandler:S,_setListDataSource(){this._list&&(this._setListOption("dataSource",this._getDataSource()),this._needPassDataSourceToList()||this._setListOption("items",[]))},_needPassDataSourceToList(){return this.option("showDataBeforeSearch")||this._isMinSearchLengthExceeded()},_isMinSearchLengthExceeded(){return this._searchValue().toString().length>=this.option("minSearchLength")},_needClearFilter(){return this._canKeepDataSource()?!1:this._needPassDataSourceToList()},_canKeepDataSource(){let i=this._isMinSearchLengthExceeded();return this._dataController.isLoaded()&&this.option("showDataBeforeSearch")&&this.option("minSearchLength")&&!i&&!this._isLastMinSearchLengthExceeded},_searchValue(){return this._input().val()||""},_getSearchEvent(){return D("input",`${this.NAME}Search`)},_getCompositionStartEvent(){return D("compositionstart",`${this.NAME}CompositionStart`)},_getCompositionEndEvent(){return D("compositionend",`${this.NAME}CompositionEnd`)},_getSetFocusPolicyEvent(){return D("input",`${this.NAME}FocusPolicy`)},_renderEvents(){this.callBase(),_.on(this._input(),this._getSetFocusPolicyEvent(),()=>{this._setFocusPolicy()}),this._shouldRenderSearchEvent()&&(_.on(this._input(),this._getSearchEvent(),i=>{this._searchHandler(i)}),BM&&(_.on(this._input(),this._getCompositionStartEvent(),()=>{this._isTextCompositionInProgress(!0)}),_.on(this._input(),this._getCompositionEndEvent(),i=>{this._isTextCompositionInProgress(void 0),this._searchHandler(i,this._searchValue())})))},_shouldRenderSearchEvent(){return this.option("searchEnabled")},_refreshEvents(){_.off(this._input(),this._getSearchEvent()),_.off(this._input(),this._getSetFocusPolicyEvent()),BM&&(_.off(this._input(),this._getCompositionStartEvent()),_.off(this._input(),this._getCompositionEndEvent())),this.callBase()},_isTextCompositionInProgress(i){if(arguments.length)this._isTextComposition=i;else return this._isTextComposition},_searchHandler(i,e){if(this._isTextCompositionInProgress())return;if(!this._isMinSearchLengthExceeded()){this._searchCanceled();return}let t=this.option("searchTimeout");t?(this._clearSearchTimer(),this._searchTimer=setTimeout(()=>{this._searchDataSource(e)},t)):this._searchDataSource(e)},_searchCanceled(){this._clearSearchTimer(),this._needClearFilter()&&this._filterDataSource(null),this._refreshList()},_searchDataSource(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._searchValue();this._filterDataSource(i)},_filterDataSource(i){this._clearSearchTimer();let e=this._dataController;e.searchExpr(this.option("searchExpr")||this._displayGetterExpr()),e.searchOperation(this.option("searchMode")),e.searchValue(i),e.load().done(this._dataSourceFiltered.bind(this,i))},_clearFilter(){let i=this._dataController;i.searchValue()&&i.searchValue(null)},_dataSourceFiltered(){this._isLastMinSearchLengthExceeded=this._isMinSearchLengthExceeded(),this._refreshList(),this._refreshPopupVisibility()},_shouldOpenPopup(){return this._hasItemsToShow()},_refreshPopupVisibility(){if(this.option("readOnly")||!this._searchValue())return;let i=this._shouldOpenPopup();i&&!this._isFocused()||(this.option("opened",i),i&&(this._updatePopupWidth(),this._updateListDimensions()))},_dataSourceChangedHandler(i){this._dataController.pageIndex()===0?this.option().items=i:this.option().items=this.option().items.concat(i)},_hasItemsToShow(){let t=(this._dataController.items()||[]).length;return!!(this._needPassDataSourceToList()&&t)},_clearSearchTimer(){clearTimeout(this._searchTimer),delete this._searchTimer},_popupShowingHandler(){this._updatePopupWidth(),this._updateListDimensions()},_dimensionChanged(){this.callBase(),this._updateListDimensions()},_needPopupRepaint(){let i=this._dataController,e=i.pageIndex(),t=f(this._pageIndex)&&e<=this._pageIndex||i.isLastPage()&&!this._list._scrollViewIsFull();return this._pageIndex=e,t},_updateListDimensions(){this._popup&&(this._needPopupRepaint()&&this._popup.repaint(),this._list&&this._list.updateDimensions())},_getMaxHeight(){let i=this.$element(),e=this._$customBoundaryContainer,t=i.offset().top-(e?e.offset().top:0),n=X(kM),o=e?Math.min(X(e),n):n,s=Math.max(t,o-t-X(i));return Math.min(.5*o,s)},_clean(){this._list&&delete this._list,delete this._isLastMinSearchLengthExceeded,this.callBase()},_dispose(){this._clearSearchTimer(),this.callBase()},_setCollectionWidgetOption(){this._setListOption.apply(this,arguments)},_setSubmitValue(){let i=this.option("value"),e=this._shouldUseDisplayValue(i)?this._displayGetter(i):i;this._getSubmitElement().val(e)},_shouldUseDisplayValue(i){return this.option("valueExpr")==="this"&&$(i)},_optionChanged(i){switch(this._dataExpressionOptionChanged(i),i.name){case"hoverStateEnabled":case"focusStateEnabled":this._isDesktopDevice()&&this._setListOption(i.name,i.value),this.callBase(i);break;case"items":this.option("dataSource")||this._processDataSourceChanging();break;case"dataSource":this._processDataSourceChanging();break;case"valueExpr":this._renderValue(),this._setListOption("keyExpr",this._getCollectionKeyExpr());break;case"displayExpr":this._renderValue(),this._setListOption("displayExpr",this._displayGetterExpr());break;case"searchMode":this._validateSearchMode();break;case"minSearchLength":this._refreshList();break;case"searchEnabled":case"showDataBeforeSearch":case"searchExpr":this._invalidate();break;case"onContentReady":this._initContentReadyAction();break;case"onSelectionChanged":this._initSelectionChangedAction();break;case"onItemClick":this._initItemClickAction();break;case"grouped":case"groupTemplate":case"wrapItemText":case"noDataText":case"encodeNoDataText":case"useItemTextAsTitle":this._setListOption(i.name);break;case"displayValue":this.option("text",i.value);break;case"itemTemplate":case"searchTimeout":break;case"selectedItem":i.previousValue!==i.value&&this._selectionChangedAction({selectedItem:i.value});break;default:this.callBase(i)}}}).include(Pc,jp);G("dxDropDownList",VM);var LM=VM;var NM=LM;var qM=(()=>{class i{_renderer;_elementRef;onChange=t=>{};onTouched=()=>{};constructor(t,n){this._renderer=t,this._elementRef=n}setProperty(t,n){this._renderer.setProperty(this._elementRef.nativeElement,t,n)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}static \u0275fac=function(n){return new(n||i)(E(ds),E(Pe))};static \u0275dir=wi({type:i})}return i})(),z4=(()=>{class i extends qM{static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275dir=wi({type:i,features:[J]})}return i})(),Ri=new Wr("");var W4={provide:Ri,useExisting:Ht(()=>YM),multi:!0};function G4(){let i=yf()?yf().getUserAgent():"";return/android (\d+)/.test(i.toLowerCase())}var K4=new Wr(""),YM=(()=>{class i extends qM{_compositionMode;_composing=!1;constructor(t,n,o){super(t,n),this._compositionMode=o,this._compositionMode==null&&(this._compositionMode=!G4())}writeValue(t){let n=t??"";this.setProperty("value",n)}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}static \u0275fac=function(n){return new(n||i)(E(ds),E(Pe),E(K4,8))};static \u0275dir=wi({type:i,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(n,o){n&1&&mi("input",function(r){return o._handleInput(r.target.value)})("blur",function(){return o.onTouched()})("compositionstart",function(){return o._compositionStart()})("compositionend",function(r){return o._compositionEnd(r.target.value)})},standalone:!1,features:[le([W4]),J]})}return i})();function Vv(i){return i==null||Lv(i)===0}function Lv(i){return i==null?null:Array.isArray(i)||typeof i=="string"?i.length:i instanceof Set?i.size:null}var ma=new Wr(""),Ul=new Wr(""),U4=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,HM=class{static min(e){return j4(e)}static max(e){return q4(e)}static required(e){return XM(e)}static requiredTrue(e){return Y4(e)}static email(e){return X4(e)}static minLength(e){return Q4(e)}static maxLength(e){return Z4(e)}static pattern(e){return J4(e)}static nullValidator(e){return ag()}static compose(e){return iR(e)}static composeAsync(e){return oR(e)}};function j4(i){return e=>{if(e.value==null||i==null)return null;let t=parseFloat(e.value);return!isNaN(t)&&t<i?{min:{min:i,actual:e.value}}:null}}function q4(i){return e=>{if(e.value==null||i==null)return null;let t=parseFloat(e.value);return!isNaN(t)&&t>i?{max:{max:i,actual:e.value}}:null}}function XM(i){return Vv(i.value)?{required:!0}:null}function Y4(i){return i.value===!0?null:{required:!0}}function X4(i){return Vv(i.value)||U4.test(i.value)?null:{email:!0}}function Q4(i){return e=>{let t=e.value?.length??Lv(e.value);return t===null||t===0?null:t<i?{minlength:{requiredLength:i,actualLength:t}}:null}}function Z4(i){return e=>{let t=e.value?.length??Lv(e.value);return t!==null&&t>i?{maxlength:{requiredLength:i,actualLength:t}}:null}}function J4(i){if(!i)return ag;let e,t;return typeof i=="string"?(t="",i.charAt(0)!=="^"&&(t+="^"),t+=i,i.charAt(i.length-1)!=="$"&&(t+="$"),e=new RegExp(t)):(t=i.toString(),e=i),n=>{if(Vv(n.value))return null;let o=n.value;return e.test(o)?null:{pattern:{requiredPattern:t,actualValue:o}}}}function ag(i){return null}function QM(i){return i!=null}function ZM(i){return pE(i)?lE(i):i}function JM(i){let e={};return i.forEach(t=>{e=t!=null?yn(yn({},e),t):e}),Object.keys(e).length===0?null:e}function eR(i,e){return e.map(t=>t(i))}function eq(i){return!i.validate}function tR(i){return i.map(e=>eq(e)?e:t=>e.validate(t))}function iR(i){if(!i)return null;let e=i.filter(QM);return e.length==0?null:function(t){return JM(eR(t,e))}}function nR(i){return i!=null?iR(tR(i)):null}function oR(i){if(!i)return null;let e=i.filter(QM);return e.length==0?null:function(t){let n=eR(t,e).map(ZM);return cE(n).pipe(dE(JM))}}function sR(i){return i!=null?oR(tR(i)):null}function $M(i,e){return i===null?[e]:Array.isArray(i)?[...i,e]:[i,e]}function rR(i){return i._rawValidators}function aR(i){return i._rawAsyncValidators}function Rv(i){return i?Array.isArray(i)?i:[i]:[]}function lg(i,e){return Array.isArray(i)?i.includes(e):i===e}function zM(i,e){let t=Rv(e);return Rv(i).forEach(o=>{lg(t,o)||t.push(o)}),t}function WM(i,e){return Rv(e).filter(t=>!lg(i,t))}var dg=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=nR(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=sR(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e=void 0){this.control&&this.control.reset(e)}hasError(e,t){return this.control?this.control.hasError(e,t):!1}getError(e,t){return this.control?this.control.getError(e,t):null}},Dn=class extends dg{name;get formDirective(){return null}get path(){return null}},Ps=class extends dg{_parent=null;name=null;valueAccessor=null},cg=class{_cd;constructor(e){this._cd=e}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}},tq={"[class.ng-untouched]":"isUntouched","[class.ng-touched]":"isTouched","[class.ng-pristine]":"isPristine","[class.ng-dirty]":"isDirty","[class.ng-valid]":"isValid","[class.ng-invalid]":"isInvalid","[class.ng-pending]":"isPending"},UAe=so(yn({},tq),{"[class.ng-submitted]":"isSubmitted"}),jAe=(()=>{class i extends cg{constructor(t){super(t)}static \u0275fac=function(n){return new(n||i)(E(Ps,2))};static \u0275dir=wi({type:i,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(n,o){n&2&&Gr("ng-untouched",o.isUntouched)("ng-touched",o.isTouched)("ng-pristine",o.isPristine)("ng-dirty",o.isDirty)("ng-valid",o.isValid)("ng-invalid",o.isInvalid)("ng-pending",o.isPending)},standalone:!1,features:[J]})}return i})(),qAe=(()=>{class i extends cg{constructor(t){super(t)}static \u0275fac=function(n){return new(n||i)(E(Dn,10))};static \u0275dir=wi({type:i,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(n,o){n&2&&Gr("ng-untouched",o.isUntouched)("ng-touched",o.isTouched)("ng-pristine",o.isPristine)("ng-dirty",o.isDirty)("ng-valid",o.isValid)("ng-invalid",o.isInvalid)("ng-pending",o.isPending)("ng-submitted",o.isSubmitted)},standalone:!1,features:[J]})}return i})();var Nc="VALID",rg="INVALID",Wl="PENDING",Hc="DISABLED",yr=class{},ug=class extends yr{value;source;constructor(e,t){super(),this.value=e,this.source=t}},$c=class extends yr{pristine;source;constructor(e,t){super(),this.pristine=e,this.source=t}},zc=class extends yr{touched;source;constructor(e,t){super(),this.touched=e,this.source=t}},Gl=class extends yr{status;source;constructor(e,t){super(),this.status=e,this.source=t}},Fv=class extends yr{source;constructor(e){super(),this.source=e}},Pv=class extends yr{source;constructor(e){super(),this.source=e}};function Nv(i){return(_g(i)?i.validators:i)||null}function iq(i){return Array.isArray(i)?nR(i):i||null}function Hv(i,e){return(_g(e)?e.asyncValidators:i)||null}function nq(i){return Array.isArray(i)?sR(i):i||null}function _g(i){return i!=null&&!Array.isArray(i)&&typeof i=="object"}function lR(i,e,t){let n=i.controls;if(!(e?Object.keys(n):n).length)throw new Gu(1e3,"");if(!n[t])throw new Gu(1001,"")}function dR(i,e,t){i._forEachChild((n,o)=>{if(t[o]===void 0)throw new Gu(1002,"")})}var Kl=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(e,t){this._assignValidators(e),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(e){this._rawValidators=this._composedValidatorFn=e}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(e){this._rawAsyncValidators=this._composedAsyncValidatorFn=e}get parent(){return this._parent}get status(){return Xs(this.statusReactive)}set status(e){Xs(()=>this.statusReactive.set(e))}_status=Rd(()=>this.statusReactive());statusReactive=Ad(void 0);get valid(){return this.status===Nc}get invalid(){return this.status===rg}get pending(){return this.status==Wl}get disabled(){return this.status===Hc}get enabled(){return this.status!==Hc}errors;get pristine(){return Xs(this.pristineReactive)}set pristine(e){Xs(()=>this.pristineReactive.set(e))}_pristine=Rd(()=>this.pristineReactive());pristineReactive=Ad(!0);get dirty(){return!this.pristine}get touched(){return Xs(this.touchedReactive)}set touched(e){Xs(()=>this.touchedReactive.set(e))}_touched=Rd(()=>this.touchedReactive());touchedReactive=Ad(!1);get untouched(){return!this.touched}_events=new aE;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(e){this._assignValidators(e)}setAsyncValidators(e){this._assignAsyncValidators(e)}addValidators(e){this.setValidators(zM(e,this._rawValidators))}addAsyncValidators(e){this.setAsyncValidators(zM(e,this._rawAsyncValidators))}removeValidators(e){this.setValidators(WM(e,this._rawValidators))}removeAsyncValidators(e){this.setAsyncValidators(WM(e,this._rawAsyncValidators))}hasValidator(e){return lg(this._rawValidators,e)}hasAsyncValidator(e){return lg(this._rawAsyncValidators,e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){let t=this.touched===!1;this.touched=!0;let n=e.sourceControl??this;this._parent&&!e.onlySelf&&this._parent.markAsTouched(so(yn({},e),{sourceControl:n})),t&&e.emitEvent!==!1&&this._events.next(new zc(!0,n))}markAllAsTouched(e={}){this.markAsTouched({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:this}),this._forEachChild(t=>t.markAllAsTouched(e))}markAsUntouched(e={}){let t=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let n=e.sourceControl??this;this._forEachChild(o=>{o.markAsUntouched({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:n})}),this._parent&&!e.onlySelf&&this._parent._updateTouched(e,n),t&&e.emitEvent!==!1&&this._events.next(new zc(!1,n))}markAsDirty(e={}){let t=this.pristine===!0;this.pristine=!1;let n=e.sourceControl??this;this._parent&&!e.onlySelf&&this._parent.markAsDirty(so(yn({},e),{sourceControl:n})),t&&e.emitEvent!==!1&&this._events.next(new $c(!1,n))}markAsPristine(e={}){let t=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let n=e.sourceControl??this;this._forEachChild(o=>{o.markAsPristine({onlySelf:!0,emitEvent:e.emitEvent})}),this._parent&&!e.onlySelf&&this._parent._updatePristine(e,n),t&&e.emitEvent!==!1&&this._events.next(new $c(!0,n))}markAsPending(e={}){this.status=Wl;let t=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new Gl(this.status,t)),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.markAsPending(so(yn({},e),{sourceControl:t}))}disable(e={}){let t=this._parentMarkedDirty(e.onlySelf);this.status=Hc,this.errors=null,this._forEachChild(o=>{o.disable(so(yn({},e),{onlySelf:!0}))}),this._updateValue();let n=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new ug(this.value,n)),this._events.next(new Gl(this.status,n)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(so(yn({},e),{skipPristineCheck:t}),this),this._onDisabledChange.forEach(o=>o(!0))}enable(e={}){let t=this._parentMarkedDirty(e.onlySelf);this.status=Nc,this._forEachChild(n=>{n.enable(so(yn({},e),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors(so(yn({},e),{skipPristineCheck:t}),this),this._onDisabledChange.forEach(n=>n(!1))}_updateAncestors(e,t){this._parent&&!e.onlySelf&&(this._parent.updateValueAndValidity(e),e.skipPristineCheck||this._parent._updatePristine({},t),this._parent._updateTouched({},t))}setParent(e){this._parent=e}getRawValue(){return this.value}updateValueAndValidity(e={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let n=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Nc||this.status===Wl)&&this._runAsyncValidator(n,e.emitEvent)}let t=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new ug(this.value,t)),this._events.next(new Gl(this.status,t)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.updateValueAndValidity(so(yn({},e),{sourceControl:t}))}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Hc:Nc}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e,t){if(this.asyncValidator){this.status=Wl,this._hasOwnPendingAsyncValidator={emitEvent:t!==!1};let n=ZM(this.asyncValidator(this));this._asyncValidationSubscription=n.subscribe(o=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(o,{emitEvent:t,shouldHaveEmitted:e})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let e=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,e}return!1}setErrors(e,t={}){this.errors=e,this._updateControlsErrors(t.emitEvent!==!1,this,t.shouldHaveEmitted)}get(e){let t=e;return t==null||(Array.isArray(t)||(t=t.split(".")),t.length===0)?null:t.reduce((n,o)=>n&&n._find(o),this)}getError(e,t){let n=t?this.get(t):this;return n&&n.errors?n.errors[e]:null}hasError(e,t){return!!this.getError(e,t)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e,t,n){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),(e||n)&&this._events.next(new Gl(this.status,t)),this._parent&&this._parent._updateControlsErrors(e,t,n)}_initObservables(){this.valueChanges=new un,this.statusChanges=new un}_calculateStatus(){return this._allControlsDisabled()?Hc:this.errors?rg:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Wl)?Wl:this._anyControlsHaveStatus(rg)?rg:Nc}_anyControlsHaveStatus(e){return this._anyControls(t=>t.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e,t){let n=!this._anyControlsDirty(),o=this.pristine!==n;this.pristine=n,this._parent&&!e.onlySelf&&this._parent._updatePristine(e,t),o&&this._events.next(new $c(this.pristine,t))}_updateTouched(e={},t){this.touched=this._anyControlsTouched(),this._events.next(new zc(this.touched,t)),this._parent&&!e.onlySelf&&this._parent._updateTouched(e,t)}_onDisabledChange=[];_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){_g(e)&&e.updateOn!=null&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){let t=this._parent&&this._parent.dirty;return!e&&!!t&&!this._parent._anyControlsDirty()}_find(e){return null}_assignValidators(e){this._rawValidators=Array.isArray(e)?e.slice():e,this._composedValidatorFn=iq(this._rawValidators)}_assignAsyncValidators(e){this._rawAsyncValidators=Array.isArray(e)?e.slice():e,this._composedAsyncValidatorFn=nq(this._rawAsyncValidators)}},hg=class extends Kl{constructor(e,t,n){super(Nv(t),Hv(n,t)),this.controls=e,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(e,t){return this.controls[e]?this.controls[e]:(this.controls[e]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(e,t,n={}){this.registerControl(e,t),this.updateValueAndValidity({emitEvent:n.emitEvent}),this._onCollectionChange()}removeControl(e,t={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}setControl(e,t,n={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],t&&this.registerControl(e,t),this.updateValueAndValidity({emitEvent:n.emitEvent}),this._onCollectionChange()}contains(e){return this.controls.hasOwnProperty(e)&&this.controls[e].enabled}setValue(e,t={}){dR(this,!0,e),Object.keys(e).forEach(n=>{lR(this,!0,n),this.controls[n].setValue(e[n],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(e,t={}){e!=null&&(Object.keys(e).forEach(n=>{let o=this.controls[n];o&&o.patchValue(e[n],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(e={},t={}){this._forEachChild((n,o)=>{n.reset(e?e[o]:null,{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t,this),this._updateTouched(t,this),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(e,t,n)=>(e[n]=t.getRawValue(),e))}_syncPendingControls(){let e=this._reduceChildren(!1,(t,n)=>n._syncPendingControls()?!0:t);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){Object.keys(this.controls).forEach(t=>{let n=this.controls[t];n&&e(n,t)})}_setUpControls(){this._forEachChild(e=>{e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(e){for(let[t,n]of Object.entries(this.controls))if(this.contains(t)&&e(n))return!0;return!1}_reduceValue(){let e={};return this._reduceChildren(e,(t,n,o)=>((n.enabled||this.disabled)&&(t[o]=n.value),t))}_reduceChildren(e,t){let n=e;return this._forEachChild((o,s)=>{n=t(n,o,s)}),n}_allControlsDisabled(){for(let e of Object.keys(this.controls))if(this.controls[e].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(e){return this.controls.hasOwnProperty(e)?this.controls[e]:null}};var kv=class extends hg{};var Gc=new Wr("",{providedIn:"root",factory:()=>Cg}),Cg="always";function xg(i,e){return[...e.path,i]}function pg(i,e,t=Cg){$v(i,e),e.valueAccessor.writeValue(i.value),(i.disabled||t==="always")&&e.valueAccessor.setDisabledState?.(i.disabled),sq(i,e),aq(i,e),rq(i,e),oq(i,e)}function gg(i,e,t=!0){let n=()=>{};e.valueAccessor&&(e.valueAccessor.registerOnChange(n),e.valueAccessor.registerOnTouched(n)),fg(i,e),i&&(e._invokeOnDestroyCallbacks(),i._registerOnCollectionChange(()=>{}))}function mg(i,e){i.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(e)})}function oq(i,e){if(e.valueAccessor.setDisabledState){let t=n=>{e.valueAccessor.setDisabledState(n)};i.registerOnDisabledChange(t),e._registerOnDestroy(()=>{i._unregisterOnDisabledChange(t)})}}function $v(i,e){let t=rR(i);e.validator!==null?i.setValidators($M(t,e.validator)):typeof t=="function"&&i.setValidators([t]);let n=aR(i);e.asyncValidator!==null?i.setAsyncValidators($M(n,e.asyncValidator)):typeof n=="function"&&i.setAsyncValidators([n]);let o=()=>i.updateValueAndValidity();mg(e._rawValidators,o),mg(e._rawAsyncValidators,o)}function fg(i,e){let t=!1;if(i!==null){if(e.validator!==null){let o=rR(i);if(Array.isArray(o)&&o.length>0){let s=o.filter(r=>r!==e.validator);s.length!==o.length&&(t=!0,i.setValidators(s))}}if(e.asyncValidator!==null){let o=aR(i);if(Array.isArray(o)&&o.length>0){let s=o.filter(r=>r!==e.asyncValidator);s.length!==o.length&&(t=!0,i.setAsyncValidators(s))}}}let n=()=>{};return mg(e._rawValidators,n),mg(e._rawAsyncValidators,n),t}function sq(i,e){e.valueAccessor.registerOnChange(t=>{i._pendingValue=t,i._pendingChange=!0,i._pendingDirty=!0,i.updateOn==="change"&&cR(i,e)})}function rq(i,e){e.valueAccessor.registerOnTouched(()=>{i._pendingTouched=!0,i.updateOn==="blur"&&i._pendingChange&&cR(i,e),i.updateOn!=="submit"&&i.markAsTouched()})}function cR(i,e){i._pendingDirty&&i.markAsDirty(),i.setValue(i._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(i._pendingValue),i._pendingChange=!1}function aq(i,e){let t=(n,o)=>{e.valueAccessor.writeValue(n),o&&e.viewToModelUpdate(n)};i.registerOnChange(t),e._registerOnDestroy(()=>{i._unregisterOnChange(t)})}function lq(i,e){i==null,$v(i,e)}function dq(i,e){return fg(i,e)}function zv(i,e){if(!i.hasOwnProperty("model"))return!1;let t=i.model;return t.isFirstChange()?!0:!Object.is(e,t.currentValue)}function cq(i){return Object.getPrototypeOf(i.constructor)===z4}function uq(i,e){i._syncPendingControls(),e.forEach(t=>{let n=t.control;n.updateOn==="submit"&&n._pendingChange&&(t.viewToModelUpdate(n._pendingValue),n._pendingChange=!1)})}function Wv(i,e){if(!e)return null;Array.isArray(e);let t,n,o;return e.forEach(s=>{s.constructor===YM?t=s:cq(s)?n=s:o=s}),o||n||t||null}function hq(i,e){let t=i.indexOf(e);t>-1&&i.splice(t,1)}function GM(i,e){let t=i.indexOf(e);t>-1&&i.splice(t,1)}function KM(i){return typeof i=="object"&&i!==null&&Object.keys(i).length===2&&"value"in i&&"disabled"in i}var Wc=class extends Kl{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(e=null,t,n){super(Nv(t),Hv(n,t)),this._applyFormState(e),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),_g(t)&&(t.nonNullable||t.initialValueIsDefault)&&(KM(e)?this.defaultValue=e.value:this.defaultValue=e)}setValue(e,t={}){this.value=this._pendingValue=e,this._onChange.length&&t.emitModelToViewChange!==!1&&this._onChange.forEach(n=>n(this.value,t.emitViewToModelChange!==!1)),this.updateValueAndValidity(t)}patchValue(e,t={}){this.setValue(e,t)}reset(e=this.defaultValue,t={}){this._applyFormState(e),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_unregisterOnChange(e){GM(this._onChange,e)}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_unregisterOnDisabledChange(e){GM(this._onDisabledChange,e)}_forEachChild(e){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(e){KM(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}};var pq=i=>i instanceof Wc,gq=(()=>{class i extends Dn{_parent;ngOnInit(){this._checkParentType(),this.formDirective.addFormGroup(this)}ngOnDestroy(){this.formDirective&&this.formDirective.removeFormGroup(this)}get control(){return this.formDirective.getFormGroup(this)}get path(){return xg(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275dir=wi({type:i,standalone:!1,features:[J]})}return i})();var mq={provide:Ps,useExisting:Ht(()=>fq)},UM=Promise.resolve(),fq=(()=>{class i extends Ps{_changeDetectorRef;callSetDisabledState;control=new Wc;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new un;constructor(t,n,o,s,r,a){super(),this._changeDetectorRef=r,this.callSetDisabledState=a,this._parent=t,this._setValidators(n),this._setAsyncValidators(o),this.valueAccessor=Wv(this,s)}ngOnChanges(t){if(this._checkForErrors(),!this._registered||"name"in t){if(this._registered&&(this._checkName(),this.formDirective)){let n=t.name.previousValue;this.formDirective.removeControl({name:n,path:this._getPath(n)})}this._setUpControl()}"isDisabled"in t&&this._updateDisabled(t),zv(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){pg(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(t){UM.then(()=>{this.control.setValue(t,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(t){let n=t.isDisabled.currentValue,o=n!==0&&bf(n);UM.then(()=>{o&&!this.control.disabled?this.control.disable():!o&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(t){return this._parent?xg(t,this._parent):[t]}static \u0275fac=function(n){return new(n||i)(E(Dn,9),E(ma,10),E(Ul,10),E(Ri,10),E(yE,8),E(Gc,8))};static \u0275dir=wi({type:i,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[le([mq]),J,Ze]})}return i})();var XAe=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275dir=wi({type:i,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return i})();var Gv=new Wr(""),_q={provide:Ps,useExisting:Ht(()=>Cq)},Cq=(()=>{class i extends Ps{_ngModelWarningConfig;callSetDisabledState;viewModel;form;set isDisabled(t){}model;update=new un;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(t,n,o,s,r){super(),this._ngModelWarningConfig=s,this.callSetDisabledState=r,this._setValidators(t),this._setAsyncValidators(n),this.valueAccessor=Wv(this,o)}ngOnChanges(t){if(this._isControlChanged(t)){let n=t.form.previousValue;n&&gg(n,this,!1),pg(this.form,this,this.callSetDisabledState),this.form.updateValueAndValidity({emitEvent:!1})}zv(t,this.viewModel)&&(this.form.setValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.form&&gg(this.form,this,!1)}get path(){return[]}get control(){return this.form}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_isControlChanged(t){return t.hasOwnProperty("form")}static \u0275fac=function(n){return new(n||i)(E(ma,10),E(Ul,10),E(Ri,10),E(Gv,8),E(Gc,8))};static \u0275dir=wi({type:i,selectors:[["","formControl",""]],inputs:{form:[0,"formControl","form"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],standalone:!1,features:[le([_q]),J,Ze]})}return i})(),xq={provide:Dn,useExisting:Ht(()=>uR)},uR=(()=>{class i extends Dn{callSetDisabledState;get submitted(){return Xs(this._submittedReactive)}set submitted(t){this._submittedReactive.set(t)}_submitted=Rd(()=>this._submittedReactive());_submittedReactive=Ad(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];form=null;ngSubmit=new un;constructor(t,n,o){super(),this.callSetDisabledState=o,this._setValidators(t),this._setAsyncValidators(n)}ngOnChanges(t){t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(fg(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(t){let n=this.form.get(t.path);return pg(n,t,this.callSetDisabledState),n.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),n}getControl(t){return this.form.get(t.path)}removeControl(t){gg(t.control||null,t,!1),hq(this.directives,t)}addFormGroup(t){this._setUpFormContainer(t)}removeFormGroup(t){this._cleanUpFormContainer(t)}getFormGroup(t){return this.form.get(t.path)}addFormArray(t){this._setUpFormContainer(t)}removeFormArray(t){this._cleanUpFormContainer(t)}getFormArray(t){return this.form.get(t.path)}updateModel(t,n){this.form.get(t.path).setValue(n)}onSubmit(t){return this._submittedReactive.set(!0),uq(this.form,this.directives),this.ngSubmit.emit(t),this.form._events.next(new Fv(this.control)),t?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(t=void 0){this.form.reset(t),this._submittedReactive.set(!1),this.form._events.next(new Pv(this.form))}_updateDomValue(){this.directives.forEach(t=>{let n=t.control,o=this.form.get(t.path);n!==o&&(gg(n||null,t),pq(o)&&(pg(o,t,this.callSetDisabledState),t.control=o))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(t){let n=this.form.get(t.path);lq(n,t),n.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(t){if(this.form){let n=this.form.get(t.path);n&&dq(n,t)&&n.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){$v(this.form,this),this._oldForm&&fg(this._oldForm,this)}static \u0275fac=function(n){return new(n||i)(E(ma,10),E(Ul,10),E(Gc,8))};static \u0275dir=wi({type:i,selectors:[["","formGroup",""]],hostBindings:function(n,o){n&1&&mi("submit",function(r){return o.onSubmit(r)})("reset",function(){return o.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[le([xq]),J,Ze]})}return i})(),vq={provide:Dn,useExisting:Ht(()=>hR)},hR=(()=>{class i extends gq{name=null;constructor(t,n,o){super(),this._parent=t,this._setValidators(n),this._setAsyncValidators(o)}_checkParentType(){gR(this._parent)}static \u0275fac=function(n){return new(n||i)(E(Dn,13),E(ma,10),E(Ul,10))};static \u0275dir=wi({type:i,selectors:[["","formGroupName",""]],inputs:{name:[0,"formGroupName","name"]},standalone:!1,features:[le([vq]),J]})}return i})(),bq={provide:Dn,useExisting:Ht(()=>pR)},pR=(()=>{class i extends Dn{_parent;name=null;constructor(t,n,o){super(),this._parent=t,this._setValidators(n),this._setAsyncValidators(o)}ngOnInit(){gR(this._parent),this.formDirective.addFormArray(this)}ngOnDestroy(){this.formDirective?.removeFormArray(this)}get control(){return this.formDirective.getFormArray(this)}get formDirective(){return this._parent?this._parent.formDirective:null}get path(){return xg(this.name==null?this.name:this.name.toString(),this._parent)}static \u0275fac=function(n){return new(n||i)(E(Dn,13),E(ma,10),E(Ul,10))};static \u0275dir=wi({type:i,selectors:[["","formArrayName",""]],inputs:{name:[0,"formArrayName","name"]},standalone:!1,features:[le([bq]),J]})}return i})();function gR(i){return!(i instanceof hR)&&!(i instanceof uR)&&!(i instanceof pR)}var yq={provide:Ps,useExisting:Ht(()=>Oq)},Oq=(()=>{class i extends Ps{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(t){}model;update=new un;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(t,n,o,s,r){super(),this._ngModelWarningConfig=r,this._parent=t,this._setValidators(n),this._setAsyncValidators(o),this.valueAccessor=Wv(this,s)}ngOnChanges(t){this._added||this._setUpControl(),zv(t,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}get path(){return xg(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_setUpControl(){this.control=this.formDirective.addControl(this),this._added=!0}static \u0275fac=function(n){return new(n||i)(E(Dn,13),E(ma,10),E(Ul,10),E(Ri,10),E(Gv,8))};static \u0275dir=wi({type:i,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[le([yq]),J,Ze]})}return i})();var Sq=(()=>{class i{_validator=ag;_onChange;_enabled;ngOnChanges(t){if(this.inputName in t){let n=this.normalizeInput(t[this.inputName].currentValue);this._enabled=this.enabled(n),this._validator=this._enabled?this.createValidator(n):ag,this._onChange&&this._onChange()}}validate(t){return this._validator(t)}registerOnValidatorChange(t){this._onChange=t}enabled(t){return t!=null}static \u0275fac=function(n){return new(n||i)};static \u0275dir=wi({type:i,features:[Ze]})}return i})();var Eq={provide:ma,useExisting:Ht(()=>wq),multi:!0};var wq=(()=>{class i extends Sq{required;inputName="required";normalizeInput=bf;createValidator=t=>XM;enabled(t){return t}static \u0275fac=(()=>{let t;return function(o){return(t||(t=ki(i)))(o||i)}})();static \u0275dir=wi({type:i,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(n,o){n&2&&Md("required",o._enabled?"":null)},inputs:{required:"required"},standalone:!1,features:[le([Eq]),J]})}return i})();var mR=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({})}return i})(),Bv=class extends Kl{constructor(e,t,n){super(Nv(t),Hv(n,t)),this.controls=e,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(e){return this.controls[this._adjustIndex(e)]}push(e,t={}){this.controls.push(e),this._registerControl(e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}insert(e,t,n={}){this.controls.splice(e,0,t),this._registerControl(t),this.updateValueAndValidity({emitEvent:n.emitEvent})}removeAt(e,t={}){let n=this._adjustIndex(e);n<0&&(n=0),this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),this.controls.splice(n,1),this.updateValueAndValidity({emitEvent:t.emitEvent})}setControl(e,t,n={}){let o=this._adjustIndex(e);o<0&&(o=0),this.controls[o]&&this.controls[o]._registerOnCollectionChange(()=>{}),this.controls.splice(o,1),t&&(this.controls.splice(o,0,t),this._registerControl(t)),this.updateValueAndValidity({emitEvent:n.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(e,t={}){dR(this,!1,e),e.forEach((n,o)=>{lR(this,!1,o),this.at(o).setValue(n,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(e,t={}){e!=null&&(e.forEach((n,o)=>{this.at(o)&&this.at(o).patchValue(n,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(e=[],t={}){this._forEachChild((n,o)=>{n.reset(e[o],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t,this),this._updateTouched(t,this),this.updateValueAndValidity(t)}getRawValue(){return this.controls.map(e=>e.getRawValue())}clear(e={}){this.controls.length<1||(this._forEachChild(t=>t._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:e.emitEvent}))}_adjustIndex(e){return e<0?e+this.length:e}_syncPendingControls(){let e=this.controls.reduce((t,n)=>n._syncPendingControls()?!0:t,!1);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){this.controls.forEach((t,n)=>{e(t,n)})}_updateValue(){this.value=this.controls.filter(e=>e.enabled||this.disabled).map(e=>e.value)}_anyControls(e){return this.controls.some(t=>t.enabled&&e(t))}_setUpControls(){this._forEachChild(e=>this._registerControl(e))}_allControlsDisabled(){for(let e of this.controls)if(e.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(e){e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)}_find(e){return this.at(e)??null}};function jM(i){return!!i&&(i.asyncValidators!==void 0||i.validators!==void 0||i.updateOn!==void 0)}var QAe=(()=>{class i{useNonNullable=!1;get nonNullable(){let t=new i;return t.useNonNullable=!0,t}group(t,n=null){let o=this._reduceControls(t),s={};return jM(n)?s=n:n!==null&&(s.validators=n.validator,s.asyncValidators=n.asyncValidator),new hg(o,s)}record(t,n=null){let o=this._reduceControls(t);return new kv(o,n)}control(t,n,o){let s={};return this.useNonNullable?(jM(n)?s=n:(s.validators=n,s.asyncValidators=o),new Wc(t,so(yn({},s),{nonNullable:!0}))):new Wc(t,n,o)}array(t,n,o){let s=t.map(r=>this._createControl(r));return new Bv(s,n,o)}_reduceControls(t){let n={};return Object.keys(t).forEach(o=>{n[o]=this._createControl(t[o])}),n}_createControl(t){if(t instanceof Wc)return t;if(t instanceof Kl)return t;if(Array.isArray(t)){let n=t[0],o=t.length>1?t[1]:null,s=t.length>2?t[2]:null;return this.control(n,o,s)}else return this.control(t)}static \u0275fac=function(n){return new(n||i)};static \u0275prov=Dd({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var ZAe=(()=>{class i{static withConfig(t){return{ngModule:i,providers:[{provide:Gc,useValue:t.callSetDisabledState??Cg}]}}static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[mR]})}return i})(),JAe=(()=>{class i{static withConfig(t){return{ngModule:i,providers:[{provide:Gv,useValue:t.warnOnNgModelWithFormControl??"always"},{provide:Gc,useValue:t.callSetDisabledState??Cg}]}}static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[mR]})}return i})();var Iq={millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5,week:6048e5,month:2592e6,quarter:7776e6,year:31536e6};function Kc(i){return Iq[i]}var jc=7;var Uc=["millisecond","second","minute","hour","day","week","month","quarter","year"],Dq=function(i,e,t){let n=e.getTime()-i.getTime(),o=Kc(t)||1;return Math.floor(n/o)},Tq=function(i,e){switch(yg(i)){case"millisecond":return"second";case"second":return"minute";case"minute":return"hour";case"hour":return"day";case"day":return e?"week":"month";case"week":return"month";case"month":return"quarter";case"quarter":case"year":return"year";default:return 0}},CR=function(i){let e,t,n,o=["millisecond","second","minute","hour","day","month","year"],s={};for(e=o.length-1;e>=0;e--)n=o[e],t=Math.floor(i/Kc(n)),t>0&&(s[n+"s"]=t,i-=vg(n,t));return s},Aq=function(i){let e=0;return $(i)&&x(i,function(t,n){e+=vg(t.substr(0,t.length-1),n)}),B(i)&&(e=vg(i,1)),e};function vg(i,e){return Kc(i)*e}function yg(i){let e=-1,t;return B(i)?i:$(i)?(x(i,function(n,o){for(t=0;t<Uc.length;t++)o&&(n===Uc[t]+"s"||n===Uc[t])&&e<t&&(e=t)}),Uc[e]):""}var Mq={millisecond:"millisecond",second:"longtime",minute:"shorttime",hour:"shorttime",day:"day",week:"day",month:"month",quarter:"quarter",year:"year"};function Rq(i){return Mq[yg(i)]||""}var xR=function(i){return Math.floor(i/3)},vR=function(i){return 3*xR(i)};function bR(i,e,t,n){i=new Date(i.getTime());let o=new Date(i.getTime()),s,r,a=yg(e);switch(a){case"second":i=new Date(1e3*Math.floor(o.getTime()/1e3));break;case"minute":i=new Date(6e4*Math.floor(o.getTime()/6e4));break;case"hour":i=new Date(36e5*Math.floor(o.getTime()/36e5));break;case"year":i.setMonth(0);case"month":i.setDate(1);case"day":i.setHours(0,0,0,0);break;case"week":i=IR(i,n||0),i.setHours(0,0,0,0);break;case"quarter":s=vR(i.getMonth()),r=i.getMonth(),i.setDate(1),i.setHours(0,0,0,0),r!==s&&i.setMonth(s)}return t&&a!=="hour"&&a!=="minute"&&a!=="second"&&AR(o,i),i}function yR(i){return bR(i,"day")}var Fq=function(i){let e=yR(i);return e.setDate(e.getDate()+1),new Date(e.getTime()-1)},Pq=function(i,e){let t=0,n={year:i.getFullYear()!==e.getFullYear(),month:i.getMonth()!==e.getMonth(),day:i.getDate()!==e.getDate(),hour:i.getHours()!==e.getHours(),minute:i.getMinutes()!==e.getMinutes(),second:i.getSeconds()!==e.getSeconds(),millisecond:i.getMilliseconds()!==e.getMilliseconds()};return x(n,function(o,s){s&&t++}),t===0&&MR(i,e)!==0&&(n.hour=!0,t++),n.count=t,n};function OR(i,e,t){let n=new Date(i.getTime()),o=B(e)?ER(e.toLowerCase()):xe(e)?CR(e):e;return o.years&&n.setFullYear(n.getFullYear()+o.years*t),o.quarters&&n.setMonth(n.getMonth()+3*o.quarters*t),o.months&&n.setMonth(n.getMonth()+o.months*t),o.weeks&&n.setDate(n.getDate()+7*o.weeks*t),o.days&&n.setDate(n.getDate()+o.days*t),o.hours&&n.setTime(n.getTime()+36e5*o.hours*t),o.minutes&&n.setTime(n.getTime()+6e4*o.minutes*t),o.seconds&&n.setTime(n.getTime()+1e3*o.seconds*t),o.milliseconds&&n.setTime(n.getTime()+o.milliseconds*t),n}var SR=function(i,e,t){let n=t?-1:1;return Et(i)?OR(i,e,n):pc(i+e*n,e)},kq=function(i,e,t){let n=[],o;for(n.push(Et(i)?new Date(i.getTime()):i),o=i;o<e;)o=SR(o,t),n.push(o);return n},Bq=function(i,e){if(i==="month")return Tn(e.getFullYear(),e.getMonth(),1);if(i==="year")return Tn(e.getFullYear(),0,e.getDate());if(i==="decade")return Tn(Yc(e),e.getMonth(),e.getDate());if(i==="century")return Tn(qc(e),e.getMonth(),e.getDate())},Vq=function(i,e){if(i==="month")return Tn(e.getFullYear(),e.getMonth(),bg(e));if(i==="year")return Tn(e.getFullYear(),11,e.getDate());if(i==="decade")return Tn(Yc(e)+9,e.getMonth(),e.getDate());if(i==="century")return Tn(qc(e)+90,e.getMonth(),e.getDate())},Lq=function(i,e){let t=Tn(e.getFullYear(),e.getMonth(),1);return i==="month"||(t.setMonth(0),i==="year")||(i==="decade"&&t.setFullYear(Yc(e)),i==="century"&&t.setFullYear(qc(e))),t},Nq=function(i,e){let t=new Date(e);return t.setDate(bg(e)),i==="month"||(t.setMonth(11),t.setDate(bg(t)),i==="year")||(i==="decade"&&t.setFullYear(Yc(e)+9),i==="century"&&t.setFullYear(qc(e)+99)),t};function bg(i){return Tn(i.getFullYear(),i.getMonth()+1,0).getDate()}var Hq=function(i){switch(i){case"month":return"year";case"year":return"decade";case"decade":return"century"}},$q=function(i){switch(i){case"century":return"decade";case"decade":return"year";case"year":return"month"}},zq=function(i){let e=1;return i==="year"&&(e=12),i==="decade"&&(e=120),i==="century"&&(e=1200),e},Wq=function(i){let e=1;return i==="decade"&&(e=12),i==="century"&&(e=120),e};function ER(i){let e={};switch(i){case"year":e.years=1;break;case"month":e.months=1;break;case"quarter":e.months=3;break;case"week":e.weeks=1;break;case"day":e.days=1;break;case"hour":e.hours=1;break;case"minute":e.minutes=1;break;case"second":e.seconds=1;break;case"millisecond":e.milliseconds=1}return e}function Gq(i,e){return Uv(i,e)&&i.getDate()===e.getDate()}function Uv(i,e){return wR(i,e)&&i.getMonth()===e.getMonth()}function wR(i,e){return i&&e&&i.getFullYear()===e.getFullYear()}function Kq(i,e){return i&&e&&i.getHours()===e.getHours()&&i.getMinutes()===e.getMinutes()}var Uq=function(i,e){if(!f(i)||!f(e))return;let t=i.getFullYear()-i.getFullYear()%10,n=e.getFullYear()-e.getFullYear()%10;return i&&e&&t===n},jq=function(i,e){if(!f(i)||!f(e))return;let t=i.getFullYear()-i.getFullYear()%100,n=e.getFullYear()-e.getFullYear()%100;return i&&e&&t===n};function qc(i){return i&&i.getFullYear()-i.getFullYear()%100}function Yc(i){return i&&i.getFullYear()-i.getFullYear()%10}var qq=function(){return"yyyy/MM/dd"},Yq=function(i){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(!f(i))return;let t=new Date(i.getTime()),n=t.getMonth()+e;return t.setMonth(n),Tn(t.getFullYear(),n,1)},Xq=function(i){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(!f(i))return;let t=new Date(i.getTime()),n=t.getMonth()+e;return t.setMonth(n),Tn(t.getFullYear(),n+1,0)};function IR(i,e){let t=(i.getDay()-e+jc)%jc,n=new Date(i);return n.setDate(i.getDate()-t),n}function fR(i){return Date.UTC(i.getFullYear(),i.getMonth(),i.getDate())}function Qq(i){let e=fR(i)-fR(DR(i.getFullYear()));return 1+Math.floor(e/Kc("day"))}function DR(i){return new Date(i,0,1)}function Kv(i){return new Date(i,11,31)}function _R(i,e){let t=i.getDay()-e+1;return t<=0&&(t+=jc),t}function jv(i,e,t){let n=_R(DR(i.getFullYear()),e),o=_R(Kv(i.getFullYear()),e),s=jc-n+1,r=Math.ceil((Qq(i)-s)/7);switch(t){case"fullWeek":if(s===jc&&r++,r===0){let a=Kv(i.getFullYear()-1);return jv(a,e,t)}return r;case"firstDay":{s>0&&r++;let a=n===7||o===7;return(r>52&&!a||r===54)&&(r=1),r}case"firstFourDays":{s>3&&r++;let a=n===4||o===4;if(r>52&&!a&&(r=1),r===0){let l=Kv(i.getFullYear()-1);return jv(l,e,t)}return r}}}var Zq=function(i,e){let t=fa.getDatesInterval(i,e,"day"),n=new Date(i);return t>=6&&(n=new Date(n.setDate(n.getDate()+7))),n},Jq=function(i,e,t,n){return n==="date"&&(e=e&&fa.correctDateWithUnitBeginning(e,"day"),t=t&&fa.correctDateWithUnitBeginning(t,"day"),i=i&&fa.correctDateWithUnitBeginning(i,"day")),TR(i,e,t)===i},e5=function(i){let{firstMin:e,firstMax:t,secondMin:n,secondMax:o}=i;return e<=n&&n<=t||e>n&&e<o||e<o&&t>o},t5=function(i){let e=Math.floor(i),t=i%1*60;return{hours:e,minutes:t}},i5=function(i,e){let t=this.dateTimeFromDecimal(e),n=new Date(i);return(i.getHours()===t.hours&&i.getMinutes()<t.minutes||i.getHours()<t.hours)&&n.setHours(t.hours,t.minutes,0,0),n};function TR(i,e,t){let n=i;return f(i)?(f(e)&&i<e&&(n=e),f(t)&&i>t&&(n=t),n):i}function AR(i,e){if(!f(i))return;let t=e.getHours()-i.getHours();if(t===0)return;let n=t===1||t===-23?-1:1,o=new Date(e.getTime()+36e5*n);(n>0||o.getDate()===e.getDate())&&e.setTime(o.getTime())}var n5=function(i){let e=new Date(i.getTime());return e.setHours(e.getHours()+1),e.setMinutes(0),e};function MR(i,e){return 60*(e.getTimezoneOffset()-i.getTimezoneOffset())*1e3}var o5=function(i){return new Date(i)},s5=function(i,e,t){let n=[],o=new Date(i.getTime());for(;o<e;)n.push(new Date(o.getTime())),o=this.addInterval(o,t);return n},Tn=function(i){let e=new Date(...arguments);return e.setFullYear(i),e},r5=()=>typeof Intl<"u"?Intl.DateTimeFormat().resolvedOptions().timeZone:null,fa={dateUnitIntervals:Uc,convertMillisecondsToDateUnits:CR,dateToMilliseconds:Aq,getNextDateUnit:Tq,convertDateUnitToMilliseconds:vg,getDateUnitInterval:yg,getDateFormatByTickInterval:Rq,getDatesDifferences:Pq,correctDateWithUnitBeginning:bR,trimTime:yR,setToDayEnd:Fq,roundDateByStartDayHour:i5,dateTimeFromDecimal:t5,addDateInterval:OR,addInterval:SR,getSequenceByInterval:kq,getDateIntervalByString:ER,sameHoursAndMinutes:Kq,sameDate:Gq,sameMonthAndYear:Uv,sameMonth:Uv,sameYear:wR,sameDecade:Uq,sameCentury:jq,getDifferenceInMonth:zq,getDifferenceInMonthForCells:Wq,getFirstYearInDecade:Yc,getFirstDecadeInCentury:qc,getShortDateFormat:qq,getViewFirstCellDate:Bq,getViewLastCellDate:Vq,getViewDown:$q,getViewUp:Hq,getLastMonthDay:bg,getLastMonthDate:Xq,getFirstMonthDate:Yq,getFirstWeekDate:IR,getWeekNumber:jv,normalizeDateByWeek:Zq,getQuarter:xR,getFirstQuarterMonth:vR,dateInRange:Jq,intervalsOverlap:e5,roundToHour:n5,normalizeDate:TR,getViewMinBoundaryDate:Lq,getViewMaxBoundaryDate:Nq,fixTimezoneGap:AR,getTimezonesDifference:MR,makeDate:o5,getDatesInterval:Dq,getDatesOfInterval:s5,createDateWithFullYear:Tn,getMachineTimezoneName:r5};fa.sameView=function(i,e,t){return fa[Ci("same "+i)](e,t)};var j=fa;var RR={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightslategrey:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"},qv=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(i){return[parseInt(i[1],10),parseInt(i[2],10),parseInt(i[3],10)]}},{re:/^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*(\d*\.*\d+)\)$/,process:function(i){return[parseInt(i[1],10),parseInt(i[2],10),parseInt(i[3],10),parseFloat(i[4])]}},{re:/^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/,process:function(i){return[parseInt(i[1],16),parseInt(i[2],16),parseInt(i[3],16)]}},{re:/^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/,process:function(i){return[parseInt(i[1],16),parseInt(i[2],16),parseInt(i[3],16),Number((parseInt(i[4],16)/255).toFixed(2))]}},{re:/^#([a-f0-9]{1})([a-f0-9]{1})([a-f0-9]{1})([a-f0-9]{1})$/,process:function(i){return[parseInt(i[1]+i[1],16),parseInt(i[2]+i[2],16),parseInt(i[3]+i[3],16),Number((parseInt(i[4]+i[4],16)/255).toFixed(2))]}},{re:/^#([a-f0-9]{1})([a-f0-9]{1})([a-f0-9]{1})$/,process:function(i){return[parseInt(i[1]+i[1],16),parseInt(i[2]+i[2],16),parseInt(i[3]+i[3],16)]}},{re:/^hsv\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(i){let e=parseInt(i[1],10),t=parseInt(i[2],10),n=parseInt(i[3],10),o=FR(e,t,n);return[o[0],o[1],o[2],1,[e,t,n]]}},{re:/^hsl\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(i){let e=parseInt(i[1],10),t=parseInt(i[2],10),n=parseInt(i[3],10),o=PR(e,t,n);return[o[0],o[1],o[2],1,null,[e,t,n]]}}],ks=Math.round;function Or(i){this.baseColor=i;let e;i&&(e=String(i).toLowerCase().replace(/ /g,""),e=RR[e]?"#"+RR[e]:e,e=a5(e)),e||(this.colorIsInvalid=!0),e=e||{},this.r=Yo(e[0]),this.g=Yo(e[1]),this.b=Yo(e[2]),this.a=Yo(e[3],1,1),e[4]?this.hsv={h:e[4][0],s:e[4][1],v:e[4][2]}:this.hsv=d5(this.r,this.g,this.b),e[5]?this.hsl={h:e[5][0],s:e[5][1],l:e[5][2]}:this.hsl=u5(this.r,this.g,this.b)}function a5(i){if(i==="transparent")return[0,0,0,0];let e=0,t=qv.length,n;for(;e<t;++e)if(n=qv[e].re.exec(i),n)return qv[e].process(n);return null}function Yo(i,e,t){return e=e||0,t=t||255,i<0||isNaN(i)?e:i>t?t:i}function l5(i,e,t){return"#"+(16777216|i<<16|e<<8|t).toString(16).slice(1)}function d5(i,e,t){let n=Math.max(i,e,t),o=Math.min(i,e,t),s=n-o,r,a,l=n;if(a=n===0?0:1-o/n,n===o)r=0;else switch(n){case i:r=(e-t)/s*60,e<t&&(r+=360);break;case e:r=(t-i)/s*60+120;break;case t:r=(i-e)/s*60+240}return a*=100,l*=100/255,{h:Math.round(r),s:Math.round(a),v:Math.round(l)}}function FR(i,e,t){let n=Math.floor(i%360/60),o=(100-e)*t/100,s=i%60/60*(t-o),r=o+s,a=t-s,l,d,c;switch(n){case 0:l=t,d=r,c=o;break;case 1:l=a,d=t,c=o;break;case 2:l=o,d=t,c=r;break;case 3:l=o,d=a,c=t;break;case 4:l=r,d=o,c=t;break;case 5:l=t,d=o,c=a}return[Math.round(2.55*l),Math.round(2.55*d),Math.round(2.55*c)]}function c5(i,e,t,n){switch(Math.max(i,e,t)){case i:return(e-t)/n+(e<t?6:0);case e:return(t-i)/n+2;case t:return(i-e)/n+4}}function u5(i,e,t){i=jl(i,255),e=jl(e,255),t=jl(t,255);let n=Math.max(i,e,t),o=Math.min(i,e,t),s=n+o,r,a,l=s/2;if(n===o)r=a=0;else{let d=n-o;l>.5?a=d/(2-s):a=d/s,r=c5(i,e,t,d),r/=6}return{h:ks(360*r),s:ks(100*a),l:ks(100*l)}}function Yv(i,e){let t=e;return i==="r"&&(t=e+1/3),i==="b"&&(t=e-1/3),t}function h5(i){return i<0&&(i+=1),i>1&&(i-=1),i}function Xv(i,e,t){return t=h5(t),t<1/6?i+6*(e-i)*t:t<.5?e:t<2/3?i+(e-i)*(2/3-t)*6:i}function PR(i,e,t){let n,o,s;if(i=jl(i,360),e=jl(e,100),t=jl(t,100),e===0)n=o=s=t;else{let r=t<.5?t*(1+e):t+e-t*e,a=2*t-r;n=Xv(a,r,Yv("r",i)),o=Xv(a,r,Yv("g",i)),s=Xv(a,r,Yv("b",i))}return[ks(255*n),ks(255*o),ks(255*s)]}function jl(i,e){return i=Math.min(e,Math.max(0,parseFloat(i))),Math.abs(i-e)<1e-6?1:i%e/parseFloat(e)}function Qv(i,e,t){return e=e||0,t=t||255,!(i%1!==0||i<e||i>t||typeof i!="number"||isNaN(i))}Or.prototype={constructor:Or,highlight:function(i){return i=i||10,this.alter(i).toHex()},darken:function(i){return i=i||10,this.alter(-i).toHex()},alter:function(i){let e=new Or;return e.r=Yo(this.r+i),e.g=Yo(this.g+i),e.b=Yo(this.b+i),e},blend:function(i,e){let t=i instanceof Or?i:new Or(i),n=new Or;return n.r=Yo(ks(this.r*(1-e)+t.r*e)),n.g=Yo(ks(this.g*(1-e)+t.g*e)),n.b=Yo(ks(this.b*(1-e)+t.b*e)),n},toHex:function(){return l5(this.r,this.g,this.b)},getPureColor:function(){let i=FR(this.hsv.h,100,100);return new Or("rgb("+i.join(",")+")")},isValidHex:function(i){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)/i.test(i)},isValidRGB:function(i,e,t){return!(!Qv(i)||!Qv(e)||!Qv(t))},isValidAlpha:function(i){return!(isNaN(i)||i<0||i>1||typeof i!="number")},colorIsInvalid:!1,fromHSL:function(i){let e=new Or,t=PR(i.h,i.s,i.l);return e.r=t[0],e.g=t[1],e.b=t[2],e}};var{PI:p5,LN10:vMe,abs:bMe,log:yMe,floor:OMe,ceil:SMe,pow:EMe,sqrt:wMe,atan2:IMe}=Math;var DMe=j.dateToMilliseconds;var TMe=p5/180;function Qn(i,e){for(;i.length<e;)i="0"+i;return i}var Xc={3:"abbreviated",4:"wide",5:"narrow"},Zv={y:function(i,e,t){let n=i[t?"getUTCFullYear":"getFullYear"]();return e===2&&(n%=100),Qn(n.toString(),e)},M:function(i,e,t,n){let o=i[t?"getUTCMonth":"getMonth"](),s=Xc[e];return s?n.getMonthNames(s,"format")[o]:Qn((o+1).toString(),Math.min(e,2))},L:function(i,e,t,n){let o=i[t?"getUTCMonth":"getMonth"](),s=Xc[e];return s?n.getMonthNames(s,"standalone")[o]:Qn((o+1).toString(),Math.min(e,2))},Q:function(i,e,t,n){let o=i[t?"getUTCMonth":"getMonth"](),s=Math.floor(o/3),r=Xc[e];return r?n.getQuarterNames(r)[s]:Qn((s+1).toString(),Math.min(e,2))},E:function(i,e,t,n){let o=i[t?"getUTCDay":"getDay"](),s=Xc[e<3?3:e];return n.getDayNames(s)[o]},a:function(i,e,t,n){let s=i[t?"getUTCHours":"getHours"]()<12?0:1,r=Xc[e];return n.getPeriodNames(r)[s]},d:function(i,e,t){return Qn(i[t?"getUTCDate":"getDate"]().toString(),Math.min(e,2))},H:function(i,e,t){return Qn(i[t?"getUTCHours":"getHours"]().toString(),Math.min(e,2))},h:function(i,e,t){let n=i[t?"getUTCHours":"getHours"]();return Qn((n%12||12).toString(),Math.min(e,2))},m:function(i,e,t){return Qn(i[t?"getUTCMinutes":"getMinutes"]().toString(),Math.min(e,2))},s:function(i,e,t){return Qn(i[t?"getUTCSeconds":"getSeconds"]().toString(),Math.min(e,2))},S:function(i,e,t){return Qn(i[t?"getUTCMilliseconds":"getMilliseconds"]().toString(),3).substr(0,e)},x:function(i,e,t){let n=t?0:i.getTimezoneOffset(),o=n>0?"-":"+",s=Math.abs(n),r=Math.floor(s/60),a=s%60,l=Qn(r.toString(),2),d=Qn(a.toString(),2);return o+l+(e>=3?":":"")+(e>1||a?d:"")},X:function(i,e,t){return t||!i.getTimezoneOffset()?"Z":Zv.x(i,e,t)},Z:function(i,e,t){return Zv.X(i,e>=5?3:2,t)}},Og=function(i,e){return function(t){let n,o,s,r=0,a=!1,l,d="";if(!t)return null;if(!i)return t;let c=i[i.length-1]==="Z"||i.slice(-3)==="'Z'";for(n=0;n<i.length;n++)s=i[n],o=Zv[s],l=s===i[n+1],r++,l||(o&&!a&&(d+=o(t,r,c,e)),r=0),s==="'"&&!l?a=!a:(a||!o)&&(d+=s),s==="'"&&l&&n++;return d}};var g5=["January","February","March","April","May","June","July","August","September","October","November","December"],m5=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],f5=["AM","PM"],_5=["Q1","Q2","Q3","Q4"],kR=(i,e)=>{let t={abbreviated:3,short:2,narrow:1};return He(i,n=>n.substr(0,t[e]))},Bs={getMonthNames:function(i){return kR(g5,i)},getDayNames:function(i){return kR(m5,i)},getQuarterNames:function(i){return _5},getPeriodNames:function(i){return f5}};var VR=/^(\d{4,})(-)?(\d{2})(-)?(\d{2})(?:T(\d{2})(:)?(\d{2})?(:)?(\d{2}(?:\.(\d{1,3})\d*)?)?)?(Z|([+-])(\d{2})(:)?(\d{2})?)?$/,LR=/^(\d{2}):(\d{2})(:(\d{2}))?$/,BR=["","yyyy","","MM","","dd","THH","","mm","","ss",".SSS"],C5=/^(\d{4})\/(\d{2})\/(\d{2})$/;var NR=function(i,e){let t;return B(i)&&!e&&(t=v5(i)),t||x5(i)};function Ji(i){return+i||0}function x5(i){let e=HR(i)==="yyyy/MM/dd",t=!Et(i)&&Date.parse(i);if(!t&&e){let n=i.match(C5);if(n){let o=new Date(Ji(n[1]),Ji(n[2]),Ji(n[3]));return o.setFullYear(Ji(n[1])),o.setMonth(Ji(n[2])-1),o.setDate(Ji(n[3])),o}}return xe(t)?new Date(t):i}function v5(i){let e=i.match(VR);if(!e)return e=i.match(LR),e?new Date(0,0,0,Ji(e[1]),Ji(e[2]),Ji(e[4])):void 0;let t=Ji(e[1]),n=--e[3],o=e[5],s=0,r=0,a=p=>(t<100&&p.setFullYear(t),p);s=Ji(e[14]),r=Ji(e[16]),e[13]==="-"&&(s=-s,r=-r);let l=Ji(e[6])-s,d=Ji(e[8])-r,c=Ji(e[10]),h=function(p){return p=p||"",Ji(p)*Math.pow(10,3-p.length)}(e[11]);return e[12]?a(new Date(Date.UTC(t,n,o,l,d,c,h))):a(new Date(t,n,o,l,d,c,h))}var b5=function(i,e){let t=i.match(VR),n="";if(!t)return t=i.match(LR),t?t[3]?"HH:mm:ss":"HH:mm":void 0;for(let o=1;o<BR.length;o++)t[o]&&(n+=BR[o]||t[o]);return t[12]==="Z"&&(n+="'Z'"),t[14]&&(t[15]?n+="xxx":t[16]?n+="xx":n+="x"),n},y5=function(i){return typeof i=="number"?new Date(i):NR(i,!fe().forceIsoDateParsing)},O5=function(i,e){return e?Et(i)?e==="number"?i&&i.valueOf?i.valueOf():null:Og(e,Bs)(i):null:i},HR=function(i){if(typeof i=="number")return"number";if(B(i)){let e;return fe().forceIsoDateParsing&&(e=b5(i)),e||(i.indexOf(":")>=0?"yyyy/MM/dd HH:mm:ss":"yyyy/MM/dd")}else if(i)return null},tt={dateParser:NR,deserializeDate:y5,serializeDate:O5,getDateSerializationFormat:HR};var zR=" .,:;/\\<>()-[]\u060C";var Sr=function(i){let e=i&&ze.convertDigits(i,!1).charCodeAt(0),t=ze.convertDigits("0",!1).charCodeAt(0);return t<=e&&e<t+10},S5=function(i,e,t,n){let o=i[t],s=i[t+1];if(!n&&(o==="."||o===" "&&i.slice(t-1,t+3)===". m."||o==="-"&&!Sr(s)))return!0;let r=n&&e.some(a=>i[t]!==a[t]);return zR.indexOf(o)<0&&n===Sr(o)&&(!n||r)},E5=function(i,e){if(!Sr(i[e]))for(;e>0&&!Sr(i[e-1])&&(i[e-1]==="."||zR.indexOf(i[e-1])<0);)e--;return e},w5=function(i,e,t,n){let o=0,s=[],r=function(a){return i[o]!==a[o]&&(n===void 0||Sr(i[o])===n)};for(Array.isArray(e)||(e=[e]),o=0;o<i.length;o++)if(t.indexOf(o)<0&&e.filter(r).length){o=E5(i,o);do{if(n=Sr(i[o]),!s.length&&!n&&Sr(e[0][o]))break;s.push(o),t.unshift(o),o++}while(i[o]&&S5(i,e,o,n));break}return s.length===1&&(i[t[0]-1]==="0"||i[t[0]-1]==="\u0660")&&t.unshift(t[0]-1),s},I5=function(i,e,t,n){let o=e[0],s=o<n.length?n[o]:o;return e.forEach(function(r,a){i=i.substr(0,s+a)+(t.length>1?t[a]:t)+i.substr(s+a+1)}),e.length===1&&(i=i.replace("0"+t,t+t),i=i.replace("\u0660"+t,t+t)),i},D5=function(i,e,t,n){let o,s,r;if(!Sr(i[e[0]]||"0")){let a=Math.max(e.length<=3?3:4,t.length);for(;e.length>a;){for(s=e.pop(),r=n[s],n[s]=-1,o=s+1;o<n.length;o++)n[o]--;i=i.substr(0,r)+i.substr(r+1)}for(s=e[e.length-1]+1,r=s<n.length?n[s]:s;e.length<a;){for(e.push(e[e.length-1]+1),o=s;o<n.length;o++)n[o]++;i=i.substr(0,r)+" "+i.substr(r)}}return i=I5(i,e,t,n),i},$R=function(i,e){return Array.isArray(i)?i.map(function(t){return(e(t)||"").toString()}):(e(i)||"").toString()},T5=/[a-zA-Z]/g,A5=function(i,e,t,n){let o=e.split("").map(function(s,r){return t.indexOf(r)<0&&(s.match(T5)||s==="'")?n[r]:-1});return i=i.split("").map(function(s,r){let a=s,l=o.indexOf(r)>=0,d=r>0&&o.indexOf(r-1)>=0,c=o.indexOf(r+1)>=0;return l&&(d||(a="'"+a),c||(a+="'")),a}).join(""),i},Sg=function(i){let e=[],t=$R(new Date(2009,8,8,6,5,4),i),n=t.split("").map(function(a,l){return l}),o=t,s={},r=[{date:new Date(2009,8,8,6,5,4,111),pattern:"S"},{date:new Date(2009,8,8,6,5,2),pattern:"s"},{date:new Date(2009,8,8,6,2,4),pattern:"m"},{date:new Date(2009,8,8,18,5,4),pattern:"H",isDigit:!0},{date:new Date(2009,8,8,2,5,4),pattern:"h",isDigit:!0},{date:new Date(2009,8,8,18,5,4),pattern:"a",isDigit:!1},{date:new Date(2009,8,1,6,5,4),pattern:"d"},{date:[new Date(2009,8,2,6,5,4),new Date(2009,8,3,6,5,4),new Date(2009,8,4,6,5,4)],pattern:"E"},{date:new Date(2009,9,6,6,5,4),pattern:"M"},{date:new Date(1998,8,8,6,5,4),pattern:"y"}];if(o&&(r.forEach(function(a){let l=w5(t,$R(a.date,i),e,a.isDigit),d=a.pattern==="M"&&!s.d?"L":a.pattern;o=D5(o,l,d,n),s[d]=l.length}),o=A5(o,t,e,n),e.length))return o};var Ls={3:"abbreviated",4:"wide",5:"narrow"},WR=function(i,e){return i>2?Object.keys(Ls).map(function(t){return["format","standalone"].map(function(n){return e.getMonthNames(Ls[t],n).join("|")}).join("|")}).join("|"):i===2?"1[012]|0?[1-9]":"0??[1-9]|1[012]"},M5={":":function(i,e){let t=i>1?`{${i}}`:"",n=Pn(e.getTimeSeparator());return n!==":"&&(n=`${n}|:`),`${n}${t}`},y:function(i){return i===2?`[0-9]{${i}}`:"[0-9]+?"},M:WR,L:WR,Q:function(i,e){return i>2?e.getQuarterNames(Ls[i],"format").join("|"):"0?[1-4]"},E:function(i,e){return"\\D*"},a:function(i,e){return e.getPeriodNames(Ls[i<3?3:i],"format").join("|")},d:function(i){return i===2?"3[01]|[12][0-9]|0?[1-9]":"0??[1-9]|[12][0-9]|3[01]"},H:function(i){return i===2?"2[0-3]|1[0-9]|0?[0-9]":"0??[0-9]|1[0-9]|2[0-3]"},h:function(i){return i===2?"1[012]|0?[1-9]":"0??[1-9]|1[012]"},m:function(i){return i===2?"[1-5][0-9]|0?[0-9]":"0??[0-9]|[1-5][0-9]"},s:function(i){return i===2?"[1-5][0-9]|0?[0-9]":"0??[0-9]|[1-5][0-9]"},S:function(i){return`[0-9]{1,${i}}`},w:function(i){return i===2?"[1-5][0-9]|0?[0-9]":"0??[0-9]|[1-5][0-9]"},x:function(i){return i===3?"[+-](?:2[0-3]|[01][0-9]):(?:[0-5][0-9])|Z":"[+-](?:2[0-3]|[01][0-9])(?:[0-5][0-9])|Z"}},Vs=Number,Jv=function(i,e){return i.map(t=>t.toLowerCase()).indexOf(e.toLowerCase())},GR=function(i,e,t){return e>2?["format","standalone"].map(function(n){return Object.keys(Ls).map(function(o){let s=t.getMonthNames(Ls[o],n);return Jv(s,i)})}).reduce(function(n,o){return n.concat(o)}).filter(function(n){return n>=0})[0]:Vs(i)-1},R5={y:function(i,e){let t=Vs(i);return e===2?t<30?2e3+t:1900+t:t},M:GR,L:GR,Q:function(i,e,t){return e>2?t.getQuarterNames(Ls[e],"format").indexOf(i):Vs(i)-1},E:function(i,e,t){let n=t.getDayNames(Ls[e<3?3:e],"format");return Jv(n,i)},a:function(i,e,t){let n=t.getPeriodNames(Ls[e<3?3:e],"format");return Jv(n,i)},d:Vs,H:Vs,h:Vs,m:Vs,s:Vs,S:function(i,e){for(e=Math.max(e,3),i=i.slice(0,3);e<3;)i+="0",e++;return Vs(i)}},Eg=["y","M","d","h","m","s","S"],eb={y:"setFullYear",M:"setMonth",L:"setMonth",a:function(i,e,t){let n=i.getHours(),o=t.h;o!==void 0&&o!==n&&n--,!e&&n===12?n=0:e&&n!==12&&(n+=12),i.setHours(n)},d:"setDate",H:"setHours",h:"setHours",m:"setMinutes",s:"setSeconds",S:"setMilliseconds"},F5=function(i,e){let t=i[e];if(!t)return 0;let n=0;do e++,n++;while(i[e]===t);return n},P5=function(i,e){let t="";for(let n=0;n<e;n++)t+=i;return t},tb=function(i,e){let t="",n="",o,s=[],r=function(){n&&(s.push(`'${n}'`),t+=`${Pn(n)})`,n="")};for(let a=0;a<i.length;a++){let l=i[a],d=l==="'",c=M5[l];if(!(d&&(o=!o,i[a-1]!=="'")))if(c&&!o){let h=F5(i,a),p=P5(l,h);r(),s.push(p),t+=`(${c(h,e)})`,a+=h-1}else n||(t+="("),n+=l}return r(),B5(s)||Js.warn(`The following format may be parsed incorrectly: ${i}.`),{patterns:s,regexp:new RegExp(`^${t}$`,"i")}},k5=["d","H","h","m","s","w","M","L","Q"],B5=function(i){let e=o=>{if(!o)return!1;let s=o[0];return["y","S"].includes(s)||k5.includes(s)&&o.length<3},t=!0,n=0;return i.every((o,s,r)=>(e(o)&&((a=>a[0]!=="S"&&a.length!==2)(o)&&(t=++n<2),e(r[s+1])||(n=0)),t))},KR=function(){return eb},V5=function(i,e,t,n,o){let s=e[0],r=eb[s],a=R5[s];if(r&&a){let l=a(t,e.length,n);o[e]=l,i[r]?i[r](l):r(i,l,o)}},L5=function(i,e,t){let n=eb[e],o="g"+n.substr(1),s=t[o]();i[n](s)},N5=function(i){return i.map(function(e){return e[0]==="'"?"":e[0]==="H"?"h":e[0]})},H5=function(i){let e=i.map(function(t){return Eg.indexOf(t)});return Math.max.apply(Math,e)},$5=function(i){let e=i.filter(function(t){return Eg.indexOf(t)<0});return Eg.concat(e)},UR=function(i,e){let t=tb(i,e);return function(n){let o=t.regexp.exec(n);if(o){let s=new Date,r=new Date(s.getFullYear(),0,1),a=N5(t.patterns),l=H5(a),d=$5(a),c={};return d.forEach(function(h,p){if(!h||p<Eg.length&&p>l)return;let g=a.indexOf(h);if(g>=0){let C=t.patterns[g],v=o[g+1];V5(r,C,v,e,c)}else L5(r,h,s)}),r}return null}};var jR={"af-NA":1,agq:1,ak:1,ar:6,"ar-EH":1,"ar-ER":1,"ar-KM":1,"ar-LB":1,"ar-MA":1,"ar-MR":1,"ar-PS":1,"ar-SO":1,"ar-SS":1,"ar-TD":1,"ar-TN":1,asa:1,ast:1,az:1,"az-Cyrl":1,bas:1,be:1,bem:1,bez:1,bg:1,bm:1,br:1,bs:1,"bs-Cyrl":1,ca:1,ce:1,cgg:1,ckb:6,cs:1,cy:1,da:1,de:1,dje:1,dsb:1,dua:1,dyo:1,ee:1,el:1,"en-001":1,"en-AE":6,"en-BI":1,"en-MP":1,"en-MV":5,"en-SD":6,eo:1,es:1,et:1,eu:1,ewo:1,fa:6,ff:1,"ff-Adlm":1,fi:1,fo:1,fr:1,"fr-DJ":6,"fr-DZ":6,"fr-SY":6,fur:1,fy:1,ga:1,gd:1,gl:1,gsw:1,gv:1,ha:1,hr:1,hsb:1,hu:1,hy:1,ia:1,ig:1,is:1,it:1,jgo:1,jmc:1,ka:1,kab:6,kde:1,kea:1,khq:1,kk:1,kkj:1,kl:1,"ko-KP":1,ksb:1,ksf:1,ksh:1,ku:1,kw:1,ky:1,lag:1,lb:1,lg:1,ln:1,lrc:6,lt:1,lu:1,lv:1,"mas-TZ":1,mfe:1,mg:1,mgo:1,mi:1,mk:1,mn:1,ms:1,mua:1,mzn:6,naq:1,nds:1,nl:1,nmg:1,nnh:1,no:1,nus:1,nyn:1,os:1,pcm:1,pl:1,ps:6,"pt-AO":1,"pt-CH":1,"pt-CV":1,"pt-GQ":1,"pt-GW":1,"pt-LU":1,"pt-ST":1,"pt-TL":1,"qu-BO":1,"qu-EC":1,rm:1,rn:1,ro:1,rof:1,ru:1,rw:1,rwk:1,sah:1,sbp:1,sc:1,se:1,ses:1,sg:1,shi:1,"shi-Latn":1,si:1,sk:1,sl:1,smn:1,so:1,"so-DJ":6,sq:1,sr:1,"sr-Latn":1,sv:1,sw:1,"ta-LK":1,"ta-MY":1,teo:1,tg:1,"ti-ER":1,tk:1,to:1,tr:1,tt:1,twq:1,tzm:1,uk:1,uz:1,"uz-Arab":6,"uz-Cyrl":1,vai:1,"vai-Latn":1,vi:1,vun:1,wae:1,wo:1,xog:1,yav:1,yi:1,yo:1,zgh:1};var z5=/[\u200E\u200F]/g,W5=/[\u202F]/g,_a=i=>e=>{if(!i.timeZoneName){let t=e.getFullYear(),n=String(t).length<3,s=n?t+400:t,r=new Date(Date.UTC(s,e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));n&&r.setFullYear(t);let a=m({timeZone:"UTC"},i);return nb(r,a)}return nb(e,i)},ib={},G5=i=>{let e=Xi.locale()+"/"+JSON.stringify(i);return ib[e]||(ib[e]=new Intl.DateTimeFormat(Xi.locale(),i).format),ib[e]};function nb(i,e){return G5(e)(i).replace(z5,"").replace(W5," ")}var ob=i=>new Intl.NumberFormat(Xi.locale()).format(i),K5=(()=>{let i={};return e=>{if(!(e in i)){if(ob(0)==="0")return i[e]=!1,!1;i[e]={};for(let t=0;t<10;++t)i[e][ob(t)]=t}return i[e]}})(),wg=i=>{let e=K5(Xi.locale());return e?i.split("").map(t=>t in e?String(e[t]):t).join(""):i},qR=i=>i.replace(/(\D)0+(\d)/g,"$1$2"),U5=(i,e)=>qR(i)===qR(e),sb=i=>i.replace("d\u2019","de "),rb={day:{day:"numeric"},date:{year:"numeric",month:"long",day:"numeric"},dayofweek:{weekday:"long"},longdate:{weekday:"long",year:"numeric",month:"long",day:"numeric"},longdatelongtime:{weekday:"long",year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"},longtime:{hour:"numeric",minute:"numeric",second:"numeric"},month:{month:"long"},monthandday:{month:"long",day:"numeric"},monthandyear:{year:"numeric",month:"long"},shortdate:{},shorttime:{hour:"numeric",minute:"numeric"},shortyear:{year:"2-digit"},year:{year:"numeric"}};Object.defineProperty(rb,"shortdateshorttime",{get:function(){let i=Intl.DateTimeFormat(Xi.locale()).resolvedOptions();return{year:i.year,month:i.month,day:i.day,hour:"numeric",minute:"numeric"}}});var j5=i=>typeof i=="string"&&rb[i.toLowerCase()],YR={standalone:function(i,e){let t=new Date(1999,i,13,1);return _a({month:e})(t)},format:function(i,e){let t=new Date(0,i,13,1),o=sb(_a({day:"numeric",month:e})(t)).split(" ").filter(s=>s.indexOf("13")<0);return o.length===1?o[0]:o.length===2?o[0].length>o[1].length?o[0]:o[1]:YR.standalone(i,e)}},XR={engine:function(){return"intl"},getMonthNames:function(i,e){let t={wide:"long",abbreviated:"short",narrow:"narrow"}[i||"wide"];return e=e==="format"?e:"standalone",Array.apply(null,new Array(12)).map((n,o)=>YR[e](o,t))},getDayNames:function(i){return(t=>Array.apply(null,new Array(7)).map((n,o)=>_a({weekday:t})(new Date(0,0,o))))({wide:"long",abbreviated:"short",short:"narrow",narrow:"narrow"}[i||"wide"])},getPeriodNames:function(){let i=_a({hour:"numeric",hour12:!0});return[1,13].map(e=>{let t=ob(1),n=i(new Date(0,0,1,e)).split(t);return n.length!==2?"":(n[0].length>n[1].length?n[0]:n[1]).trim()})},format:function(i,e){if(!i)return;if(!e)return i;typeof e!="function"&&!e.formatter&&(e=e.type||e);let t=j5(e);if(t)return _a(t)(i);let n=typeof e;return e.formatter||n==="function"||n==="string"?this.callBase.apply(this,arguments):_a(e)(i)},parse:function(i,e){let t;return e&&!e.parser&&typeof i=="string"&&(i=sb(i),t=n=>sb(this.format(n,e))),this.callBase(i,t||e)},_parseDateBySimpleFormat:function(i,e){i=wg(i);let t=this.getFormatParts(e),n=i.split(/\D+/).filter(r=>r.length>0);if(t.length!==n.length)return;let o=this._generateDateArgs(t,n),s=r=>{let a=((l,d)=>{let c=d?12:0;return new Date(l.year,l.month,l.day,(l.hours+c)%24,l.minutes,l.seconds)})(o,r);if(U5(wg(this.format(a,e)),i))return a};return s(!1)||s(!0)},_generateDateArgs:function(i,e){let t=new Date,n={year:t.getFullYear(),month:t.getMonth(),day:t.getDate(),hours:0,minutes:0,seconds:0};return i.forEach((o,s)=>{let r=e[s],a=parseInt(r,10);o==="month"&&(a-=1),n[o]=a}),n},formatUsesMonthName:function(i){return typeof i=="object"&&!(i.type||i.format)?i.month==="long":this.callBase.apply(this,arguments)},formatUsesDayName:function(i){return typeof i=="object"&&!(i.type||i.format)?i.weekday==="long":this.callBase.apply(this,arguments)},getTimeSeparator:function(){return wg(nb(new Date(2001,1,1,11,11),{hour:"numeric",minute:"numeric",hour12:!1})).replace(/\d/g,"")},getFormatParts:function(i){if(typeof i=="string")return this.callBase(i);let e=m({},rb[i.toLowerCase()]),t=new Date(2001,2,4,5,6,7),n=_a(e)(t);return n=wg(n),[{name:"year",value:1},{name:"month",value:3},{name:"day",value:4},{name:"hours",value:5},{name:"minutes",value:6},{name:"seconds",value:7}].map(o=>({name:o.name,index:n.indexOf(o.value)})).filter(o=>o.index>-1).sort((o,s)=>o.index-s.index).map(o=>o.name)}};var q5=typeof Intl<"u",ab={shortdate:"M/d/y",shorttime:"h:mm a",longdate:"EEEE, MMMM d, y",longtime:"h:mm:ss a",monthandday:"MMMM d",monthandyear:"MMMM y",quarterandyear:"QQQ y",day:"d",year:"y",shortdateshorttime:"M/d/y, h:mm a",longdatelongtime:"EEEE, MMMM d, y, h:mm:ss a",month:"LLLL",shortyear:"yy",dayofweek:"EEEE",quarter:"QQQ",hour:"HH",minute:"mm",second:"ss",millisecond:"SSS","datetime-local":"yyyy-MM-ddTHH':'mm':'ss"},Y5={year:["y","yy","yyyy"],day:["d","dd"],month:["M","MM","MMM","MMMM"],hours:["H","HH","h","hh","ah"],minutes:["m","mm"],seconds:["s","ss"],milliseconds:["S","SS","SSS"]},QR=wt({engine:function(){return"base"},_getPatternByFormat:function(i){return ab[i.toLowerCase()]},_expandPattern:function(i){return this._getPatternByFormat(i)||i},formatUsesMonthName:function(i){return this._expandPattern(i).indexOf("MMMM")!==-1},formatUsesDayName:function(i){return this._expandPattern(i).indexOf("EEEE")!==-1},getFormatParts:function(i){let e=this._getPatternByFormat(i)||i,t=[];return x(e.split(/\W+/),(n,o)=>{x(Y5,(s,r)=>{r.includes(o)&&t.push(s)})}),t},getMonthNames:function(i){return Bs.getMonthNames(i)},getDayNames:function(i){return Bs.getDayNames(i)},getQuarterNames:function(i){return Bs.getQuarterNames(i)},getPeriodNames:function(i){return Bs.getPeriodNames(i)},getTimeSeparator:function(){return":"},is24HourFormat:function(i){let e=new Date(2017,0,20,11,0,0,0),t=new Date(2017,0,20,23,0,0,0),n=this.format(e,i),o=this.format(t,i);for(let s=0;s<n.length;s++)if(n[s]!==o[s])return!isNaN(parseInt(n[s]))},format:function(i,e){if(!i)return;if(!e)return i;let t;if(typeof e=="function")t=e;else if(e.formatter)t=e.formatter;else if(e=e.type||e,B(e))return e=ab[e.toLowerCase()]||e,ze.convertDigits(Og(e,this)(i));if(t)return t(i)},parse:function(i,e){let t=this,n,o;if(!i)return;if(!e)return this.parse(i,"shortdate");if(e.parser)return e.parser(i);if(typeof e=="string"&&!ab[e.toLowerCase()])n=e;else{o=r=>{let a=t.format(r,e);return ze.convertDigits(a,!0)};try{n=Sg(o)}catch{}}if(n)return i=ze.convertDigits(i,!0),UR(n,this)(i);he.log("W0012");let s=new Date(i);if(!(!s||isNaN(s.getTime())))return s},firstDayOfWeekIndex:function(){let i=Xi.getValueByClosestLocale(e=>jR[e]);return i===void 0?0:i}});q5&&QR.inject(XR);var de=QR;var Ig=wt({format:function(i,e){let t=B(e)&&e!==""||q(e)||A(e),n=xe(i)||Et(i);if(!t||!n)return f(i)?i.toString():"";if(A(e))return e(i);if(B(e)&&(e={type:e}),xe(i))return ze.format(i,e);if(Et(i))return de.format(i,e)},getTimeFormat:function(i){return i?"longtime":"shorttime"},_normalizeFormat:function(i){return Array.isArray(i)?i.length===1?i[0]:function(e){return i.map(function(t){return de.format(e,t)}).join(" ")}:i},getDateFormatByDifferences:function(i,e){let t=[],n=e&&i.millisecond&&!(i.year||i.month||i.day);if(n){let o=function(s){return s.getSeconds()+s.getMilliseconds()/1e3+"s"};t.push(o)}else i.millisecond&&t.push("millisecond");if((i.hour||i.minute||!n&&i.second)&&t.unshift(this.getTimeFormat(i.second)),i.year&&i.month&&i.day)return e&&e==="month"?"monthandyear":(t.unshift("shortdate"),this._normalizeFormat(t));if(i.year&&i.month)return"monthandyear";if(i.year&&i.quarter)return"quarterandyear";if(i.year)return"year";if(i.quarter)return"quarter";if(i.month&&i.day){if(e){let o=function(s){return de.getMonthNames("abbreviated")[s.getMonth()]+" "+de.format(s,"day")};t.unshift(o)}else t.unshift("monthandday");return this._normalizeFormat(t)}if(i.month)return"month";if(i.day){if(e)t.unshift("day");else{let o=function(s){return de.format(s,"dayofweek")+", "+de.format(s,"day")};t.unshift(o)}return this._normalizeFormat(t)}return this._normalizeFormat(t)},getDateFormatByTicks:function(i){let e,t,n;if(i.length>1)for(e=j.getDatesDifferences(i[0],i[1]),n=1;n<i.length-1;n++)t=j.getDatesDifferences(i[n],i[n+1]),e.count<t.count&&(e=t);else e={year:!0,month:!0,day:!0,hour:i[0].getHours()>0,minute:i[0].getMinutes()>0,second:i[0].getSeconds()>0,millisecond:i[0].getMilliseconds()>0};return this.getDateFormatByDifferences(e)},getDateFormatByTickInterval:function(i,e,t){let n,o=function(a,l,d){switch(l){case"year":case"quarter":a.month=d;case"month":a.day=d;case"week":case"day":a.hour=d;case"hour":a.minute=d;case"minute":a.second=d;case"second":a.millisecond=d}};t=B(t)?t.toLowerCase():t;let s=j.getDatesDifferences(i,e);return i!==e&&function(a,l,d){!d.getMilliseconds()&&d.getSeconds()?d.getSeconds()-l.getSeconds()===1&&(a.millisecond=!0,a.second=!1):!d.getSeconds()&&d.getMinutes()?d.getMinutes()-l.getMinutes()===1&&(a.second=!0,a.minute=!1):!d.getMinutes()&&d.getHours()?d.getHours()-l.getHours()===1&&(a.minute=!0,a.hour=!1):!d.getHours()&&d.getDate()>1?d.getDate()-l.getDate()===1&&(a.hour=!0,a.day=!1):d.getDate()===1&&d.getMonth()?d.getMonth()-l.getMonth()===1&&(a.day=!0,a.month=!1):!d.getMonth()&&d.getFullYear()&&d.getFullYear()-l.getFullYear()===1&&(a.month=!0,a.year=!1)}(s,i>e?e:i,i>e?i:e),n=j.getDateUnitInterval(s),o(s,n,!0),n=j.getDateUnitInterval(t||"second"),o(s,n,!1),s[{week:"day"}[n]||n]=!0,this.getDateFormatByDifferences(s)}});var X5={row:"minWidth",col:"minHeight"},Q5={row:"maxWidth",col:"maxHeight"},ZR={start:"flex-start",end:"flex-end",center:"center","space-between":"space-between","space-around":"space-around"},JR={start:"flex-start",end:"flex-end",center:"center",stretch:"stretch"},Z5={row:"row",col:"column"},ql=(i,e,t)=>{if(t=ps(e,t),i.style[lo(e)]=t,!W()){if(t===""||!f(t))return;let o=`${Hd(e)}: ${t};`;lh(i,o,!1)}},lb=class extends jn{_renderVisible(e,t){super._renderVisible(e),f(t)&&this._options.fireItemStateChangedAction({name:"visible",state:e,oldState:t})}},db=class{constructor(e,t){this._$element=e,this._option=t}renderBox(){this._$element.css({display:`${Xa("flexDirection")}flex`}),ql(this._$element.get(0),"flexDirection",Z5[this._option("direction")])}renderAlign(){this._$element.css({justifyContent:this._normalizedAlign()})}_normalizedAlign(){let e=this._option("align");return e in ZR?ZR[e]:e}renderCrossAlign(){this._$element.css({alignItems:this._normalizedCrossAlign()})}_normalizedCrossAlign(){let e=this._option("crossAlign");return e in JR?JR[e]:e}renderItems(e){let t=Xa("flexDirection"),n=this._option("direction");x(e,function(){let o=u(this),s=o.data("dxBoxItemData");o.css({display:`${t}flex`}).css(Q5[n],s.maxSize||"none").css(X5[n],s.minSize||"0"),ql(o.get(0),"flexBasis",s.baseSize||0),ql(o.get(0),"flexGrow",s.ratio),ql(o.get(0),"flexShrink",f(s.shrink)?s.shrink:1),o.children().each((r,a)=>{u(a).css({width:"auto",height:"auto",display:`${Xa("flexDirection")}flex`,flexBasis:0}),ql(a,"flexGrow",1),ql(a,"flexDirection",u(a)[0].style.flexDirection||"column")})})}},eF=(()=>{class i extends In{_getDefaultOptions(){return m(super._getDefaultOptions(),{direction:"row",align:"start",crossAlign:"stretch",activeStateEnabled:!1,focusStateEnabled:!1,onItemStateChanged:void 0,_queue:void 0})}_itemClass(){return"dx-box-item"}_itemDataKey(){return"dxBoxItemData"}_itemElements(){return this._itemContainer().children(this._itemSelector())}_init(){super._init(),this.$element().addClass("dx-box-flex"),this._initLayout(),this._initBoxQueue()}_initLayout(){this._layout=new db(this.$element(),this.option.bind(this))}_initBoxQueue(){this._queue=this.option("_queue")||[]}_queueIsNotEmpty(){return this.option("_queue")?!1:!!this._queue.length}_pushItemToQueue(t,n){this._queue.push({$item:t,config:n})}_shiftItemFromQueue(){return this._queue.shift()}_initMarkup(){this.$element().addClass("dx-box"),this._layout.renderBox(),super._initMarkup(),this._renderAlign(),this._renderActions()}_renderActions(){this._onItemStateChanged=this._createActionByOption("onItemStateChanged")}_renderAlign(){this._layout.renderAlign(),this._layout.renderCrossAlign()}_renderItems(t){for(super._renderItems(t);this._queueIsNotEmpty();){let n=this._shiftItemFromQueue();this._createComponent(n.$item,i,m({itemTemplate:this.option("itemTemplate"),itemHoldTimeout:this.option("itemHoldTimeout"),onItemHold:this.option("onItemHold"),onItemClick:this.option("onItemClick"),onItemContextMenu:this.option("onItemContextMenu"),onItemRendered:this.option("onItemRendered"),_queue:this._queue},n.config))}this._layout.renderItems(this._itemElements())}_renderItemContent(t){let n=t.itemData&&t.itemData.node;return n?this._renderItemContentByNode(t,n):super._renderItemContent(t)}_postprocessRenderItem(t){let n=t.itemData.box;n&&this._pushItemToQueue(t.itemContent,n)}_createItemByTemplate(t,n){return n.itemData.box?t.source?t.source():u():super._createItemByTemplate(t,n)}_itemOptionChanged(t,n,o,s){n==="visible"&&this._onItemStateChanged({name:n,state:o,oldState:s!==!1}),super._itemOptionChanged(t,n,o)}_optionChanged(t){switch(t.name){case"_queue":case"direction":this._invalidate();break;case"align":this._layout.renderAlign();break;case"crossAlign":this._layout.renderCrossAlign();break;default:super._optionChanged(t)}}_itemOptions(){let t=super._itemOptions();return t.fireItemStateChangedAction=n=>{this._onItemStateChanged(n)},t}}return i.ItemClass=lb,i})();G("dxBox",eF);var tF=eF;var Ca=tF;var J5=["*"],cb=(()=>{class i extends et{instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get icon(){return this._getOption("icon")}set icon(t){this._setOption("icon",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get template(){return this._getOption("template")}set template(t){this._setOption("template",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get type(){return this._getOption("type")}set type(t){this._setOption("type",t)}get useSubmitBehavior(){return this._getOption("useSubmitBehavior")}set useSubmitBehavior(t){this._setOption("useSubmitBehavior",t)}get validationGroup(){return this._getOption("validationGroup")}set validationGroup(t){this._setOption("validationGroup",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onClick;onContentReady;onDisposing;onInitialized;onOptionChanged;accessKeyChange;activeStateEnabledChange;disabledChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;iconChange;rtlEnabledChange;stylingModeChange;tabIndexChange;templateChange;textChange;typeChange;useSubmitBehaviorChange;validationGroupChange;visibleChange;widthChange;constructor(t,n,o,s,r,a,l){super(t,n,o,s,a,l),this._createEventEmitters([{subscribe:"click",emit:"onClick"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"optionChanged",emit:"onOptionChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"iconChange"},{emit:"rtlEnabledChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"templateChange"},{emit:"textChange"},{emit:"typeChange"},{emit:"useSubmitBehaviorChange"},{emit:"validationGroupChange"},{emit:"visibleChange"},{emit:"widthChange"}]),r.setHost(this)}_createInstance(t,n){return new rt(t,n)}ngOnDestroy(){this._destroyWidget()}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-button"]],inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",icon:"icon",rtlEnabled:"rtlEnabled",stylingMode:"stylingMode",tabIndex:"tabIndex",template:"template",text:"text",type:"type",useSubmitBehavior:"useSubmitBehavior",validationGroup:"validationGroup",visible:"visible",width:"width"},outputs:{onClick:"onClick",onContentReady:"onContentReady",onDisposing:"onDisposing",onInitialized:"onInitialized",onOptionChanged:"onOptionChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",iconChange:"iconChange",rtlEnabledChange:"rtlEnabledChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",templateChange:"templateChange",textChange:"textChange",typeChange:"typeChange",useSubmitBehaviorChange:"useSubmitBehaviorChange",validationGroupChange:"validationGroupChange",visibleChange:"visibleChange",widthChange:"widthChange"},standalone:!1,features:[le([ee,ae,k]),J],ngContentSelectors:J5,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},encapsulation:2})}return i})(),ub=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[qe,ye,ye]})}return i})();var iF="dx-buttongroup-item-has-width";var Dg={contained:"dx-buttongroup-mode-contained",outlined:"dx-buttongroup-mode-outlined",text:"dx-buttongroup-mode-text"},e3=In.inherit({_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({item:new di((i,e,t)=>{this._prepareItemStyles(i);let n=this.option("buttonTemplate");this._createComponent(i,rt,m({},t,e,this._getBasicButtonOptions(),{_templateData:this._hasCustomTemplate(n)?t:{},template:t.template||n}))},["text","type","icon","disabled","visible","hint"],this.option("integrationOptions.watchMethod"))})},_getBasicButtonOptions(){return{focusStateEnabled:!1,onClick:null,hoverStateEnabled:this.option("hoverStateEnabled"),activeStateEnabled:this.option("activeStateEnabled"),stylingMode:this.option("stylingMode")}},_getDefaultOptions(){return m(this.callBase(),{itemTemplateProperty:null})},_hasCustomTemplate(i){return A(i)||this.option("integrationOptions.templates")[i]},_selectedItemClass:()=>"dx-item-selected dx-state-selected",_prepareItemStyles(i){let e=i.data("dxItemIndex");e===0&&i.addClass("dx-buttongroup-first-item");let t=this.option("items");t&&e===t.length-1&&i.addClass("dx-buttongroup-last-item"),i.addClass("dx-shape-standard")},_renderItemContent(i){return i.container=u(i.container).parent(),this.callBase(i)},_setAriaSelectionAttribute(i,e){this.setAria("pressed",e,i)},_renderItemContentByNode(i,e){return i.container=u(i.container.children().first()),this.callBase(i,e)},_focusTarget(){return this.$element().parent()},_keyboardEventBindingTarget(){return this._focusTarget()},_refreshContent(){this._prepareContent(),this._renderContent()},_itemClass:()=>"dx-buttongroup-item",_itemSelectHandler(i){this.option("selectionMode")==="single"&&this.isItemSelected(i.currentTarget)||this.callBase(i)}}),nF=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,focusStateEnabled:!0,selectionMode:"single",selectedItems:[],selectedItemKeys:[],stylingMode:"contained",keyExpr:"text",items:[],buttonTemplate:"content",onSelectionChanged:null,onItemClick:null})},_init(){this.callBase(),this._createItemClickAction()},_createItemClickAction(){this._itemClickAction=this._createActionByOption("onItemClick")},_initMarkup(){this.setAria("role","group"),this.$element().addClass("dx-buttongroup"),this._renderStylingMode(),this._renderButtons(),this._syncSelectionOptions(),this.callBase()},_renderStylingMode(){let{stylingMode:i}=this.option();for(let e in Dg)this.$element().removeClass(Dg[e]);this.$element().addClass(Dg[i]??Dg.contained)},_fireSelectionChangeEvent(i,e){this._createActionByOption("onSelectionChanged",{excludeValidators:["disabled","readOnly"]})({addedItems:i,removedItems:e})},_renderButtons(){let i=u("<div>").addClass("dx-buttongroup-wrapper").appendTo(this.$element()),e=this.option("selectedItems"),t={selectionMode:this.option("selectionMode"),items:this.option("items"),keyExpr:this.option("keyExpr"),buttonTemplate:this.option("buttonTemplate"),scrollingEnabled:!1,selectedItemKeys:this.option("selectedItemKeys"),focusStateEnabled:this.option("focusStateEnabled"),hoverStateEnabled:this.option("hoverStateEnabled"),activeStateEnabled:this.option("activeStateEnabled"),stylingMode:this.option("stylingMode"),accessKey:this.option("accessKey"),tabIndex:this.option("tabIndex"),noDataText:"",selectionRequired:!1,onItemRendered:n=>{let o=this.option("width");f(o)&&u(n.itemElement).addClass(iF)},onSelectionChanged:n=>{this._syncSelectionOptions(),this._fireSelectionChangeEvent(n.addedItems,n.removedItems)},onItemClick:n=>{this._itemClickAction(n)}};f(e)&&e.length&&(t.selectedItems=e),this._buttonsCollection=this._createComponent(i,e3,t)},_syncSelectionOptions(){this._setOptionWithoutOptionChange("selectedItems",this._buttonsCollection.option("selectedItems")),this._setOptionWithoutOptionChange("selectedItemKeys",this._buttonsCollection.option("selectedItemKeys"))},_optionChanged(i){switch(i.name){case"stylingMode":case"selectionMode":case"keyExpr":case"buttonTemplate":case"items":case"activeStateEnabled":case"focusStateEnabled":case"hoverStateEnabled":case"tabIndex":this._invalidate();break;case"selectedItemKeys":case"selectedItems":this._buttonsCollection.option(i.name,i.value);break;case"onItemClick":this._createItemClickAction();break;case"onSelectionChanged":break;case"width":this.callBase(i),this._buttonsCollection.itemElements().toggleClass(iF,!!i.value);break;default:this.callBase(i)}}});G("dxButtonGroup",nF);var oF=nF;var sF=oF;var t3="dxSwipeable";var i3={onStart:Fp,onUpdated:Pp,onEnd:Ml,onCancel:"dxswipecancel"};var rF=Qi.inherit({_getDefaultOptions:function(){return m(this.callBase(),{elastic:!0,immediate:!1,immediateTimeout:180,direction:"horizontal",itemSizeFunc:null,onStart:null,onUpdated:null,onEnd:null,onCancel:null})},_render:function(){this.callBase(),this.$element().addClass("dx-swipeable"),this._attachEventHandlers()},_attachEventHandlers:function(){if(this._detachEventHandlers(),this.option("disabled"))return;let i=this.NAME;this._createEventData(),x(i3,function(e,t){let n=this._createActionByOption(e,{context:this});t=D(t,i),_.on(this.$element(),t,this._eventData,function(o){return n({event:o})})}.bind(this))},_createEventData:function(){this._eventData={elastic:this.option("elastic"),itemSizeFunc:this.option("itemSizeFunc"),direction:this.option("direction"),immediate:this.option("immediate"),immediateTimeout:this.option("immediateTimeout")}},_detachEventHandlers:function(){_.off(this.$element(),".dxSwipeable")},_optionChanged:function(i){switch(i.name){case"disabled":case"onStart":case"onUpdated":case"onEnd":case"onCancel":case"elastic":case"immediate":case"itemSizeFunc":case"direction":this._detachEventHandlers(),this._attachEventHandlers();break;case"rtlEnabled":break;default:this.callBase(i)}},_useTemplates:function(){return!1}});ar(rF,t3);var Ns=rF;var hb=class{constructor(e){this.calendar=e}dateOption(e){return this.calendar._dateOption(e)}dateValue(e,t){this.calendar._dateValue(e,t)}skipNavigate(){this.calendar._skipNavigate=!0}updateAriaSelected(e,t){this.calendar._updateAriaSelected(e,t),e[0]&&this.calendar.option("currentDate").getTime()===e[0].getTime()&&this.calendar._updateAriaId(e[0])}processValueChanged(e,t){var n,o;f(e)&&!Array.isArray(e)&&(e=[e]),f(t)&&!Array.isArray(t)&&(t=[t]),e=((n=e)===null||n===void 0?void 0:n.map(s=>this._convertToDate(s)))||[],t=((o=t)===null||o===void 0?void 0:o.map(s=>this._convertToDate(s)))||[],this._updateViewsValue(e),this.updateAriaSelected(e,t),this._currentDateChanged||this.calendar._initCurrentDate(),this._currentDateChanged=!1}_isDateDisabled(e){let t=this.calendar._dateOption("min"),n=this.calendar._dateOption("max"),o=f(t)&&e<t&&!j.sameDate(t,e),s=f(n)&&e>n&&!j.sameDate(n,e);return this.calendar._view.isDateDisabled(e)||o||s}_getLowestDateInArray(e){if(e.length)return new Date(Math.min(...e))}_convertToDate(e){return this.calendar._convertToDate(e)}_isMaxZoomLevel(){return this.calendar._isMaxZoomLevel()}_updateViewsOption(e,t){this.calendar._updateViewsOption(e,t)}_updateViewsValue(e){this._updateViewsOption("value",e)}_updateCurrentDate(e){this.calendar.option("currentDate",e??new Date)}_shouldHandleWeekNumberClick(){let{selectionMode:e,selectWeekOnClick:t}=this.calendar.option();return t&&e!=="single"}},Yl=hb;var pb=class extends Yl{constructor(e){super(e),this.NAME="MultiSelection"}getViewOptions(){return{value:this.dateOption("value"),range:[],selectionMode:"multiple",onWeekNumberClick:this._shouldHandleWeekNumberClick()?this._weekNumberClickHandler.bind(this):null}}selectValue(e,t){let n=[...this.dateOption("value")],o=n.findIndex(s=>s?.toDateString()===e.toDateString());o>-1?n.splice(o,1):n.push(e),this.skipNavigate(),this._updateCurrentDate(e),this._currentDateChanged=!0,this.dateValue(n,t)}updateAriaSelected(e,t){e??(e=this.dateOption("value")),t??(t=[]),super.updateAriaSelected(e,t)}getDefaultCurrentDate(){let e=this.dateOption("value").filter(t=>t);return this._getLowestDateInArray(e)}restoreValue(){this.calendar.option("value",[])}_weekNumberClickHandler(e){let{rowDates:t,event:n}=e,o=t.filter(s=>!this._isDateDisabled(s));this.dateValue(o,n)}},aF=pb;var gb=class extends Op{_getDefaultOptions(){return I({},super._getDefaultOptions(),{onClick:void 0,onCaptionClick:void 0,type:"normal",stylingMode:"outlined",text:""})}_defaultOptionsRules(){return super._defaultOptionsRules().concat([{device:()=>it(),options:{type:"default",stylingMode:"text"}},{device:()=>ut(),options:{type:"normal",stylingMode:"text"}}])}_init(){super._init(),this._initActions()}_initActions(){this._clickAction=this._createActionByOption("onClick"),this._captionClickAction=this._createActionByOption("onCaptionClick")}_initMarkup(){super._initMarkup(),u(this.element()).addClass("dx-calendar-navigator"),this._renderButtons(),this._renderCaption()}_renderButtons(){let{rtlEnabled:e,type:t,stylingMode:n,focusStateEnabled:o}=this.option();this._prevButton=this._createComponent(u("<div>"),rt,{focusStateEnabled:o,icon:e?"chevronright":"chevronleft",onClick:l=>{this._clickAction({direction:-1,event:l})},type:t,stylingMode:n,integrationOptions:{}});let s=u(this._prevButton.element()).addClass("dx-calendar-navigator-previous-view").addClass("dx-calendar-navigator-previous-month");this._nextButton=this._createComponent(u("<div>"),rt,{focusStateEnabled:o,icon:e?"chevronleft":"chevronright",onClick:l=>{this._clickAction({direction:1,event:l})},type:t,stylingMode:n,integrationOptions:{}});let r=u(this._nextButton.element()).addClass("dx-calendar-navigator-next-view").addClass("dx-calendar-navigator-next-month");this._caption=this._createComponent(u("<div>").addClass("dx-calendar-caption-button"),rt,{focusStateEnabled:o,onClick:l=>{this._captionClickAction({event:l})},type:t,stylingMode:n,template:(l,d)=>{let{text:c}=this.option();c.split(" - ").forEach(p=>{u(d).append(u("<span>").addClass("dx-button-text").text(p))})},integrationOptions:{}});let a=this._caption.$element();this.$element().append(s,a,r)}_renderCaption(){var e;(e=this._caption)===null||e===void 0||e.option("text",this.option("text"))}toggleButton(e,t){let n=`_${e}Button`,o=this[n];o&&(o.option("disabled",t),o.$element().toggleClass("dx-calendar-disabled-navigator-link",t))}_optionChanged(e){e.name==="text"?this._renderCaption():super._optionChanged(e)}},lF=gb;var mb=class extends Yl{constructor(e){super(e),this.NAME="RangeSelection"}getViewOptions(){let e=this._getValue(),t=this._getDaysInRange(e[0],e[1]);return{value:e,range:t,selectionMode:"range",onCellHover:this._cellHoverHandler.bind(this),onWeekNumberClick:this._shouldHandleWeekNumberClick()?this._weekNumberClickHandler.bind(this):null}}selectValue(e,t){let[n,o]=this._getValue();this.skipNavigate(),this._updateCurrentDate(e),this._currentDateChanged=!0,this.calendar.option("_allowChangeSelectionOrder")===!0?(this.calendar._valueSelected=!0,this.calendar.option("_currentSelection")==="startDate"?this.calendar._convertToDate(e)>this.calendar._convertToDate(o)?this.dateValue([e,null],t):this.dateValue([e,o],t):this.calendar._convertToDate(e)>=this.calendar._convertToDate(n)?this.dateValue([n,e],t):this.dateValue([e,null],t)):!n||o?this.dateValue([e,null],t):this.dateValue(n<e?[n,e]:[e,n],t)}updateAriaSelected(e,t){e??(e=this._getValue()),t??(t=[]),super.updateAriaSelected(e,t)}processValueChanged(e,t){super.processValueChanged(e,t);let n=this._getRange();this._updateViewsOption("range",n)}getDefaultCurrentDate(){let{_allowChangeSelectionOrder:e,_currentSelection:t}=this.calendar.option(),n=this.dateOption("value");if(e){if(t==="startDate"&&n[0])return n[0];if(t==="endDate"&&n[1])return n[1]}let o=n.filter(s=>s);return this._getLowestDateInArray(o)}restoreValue(){this.calendar.option("value",[null,null])}_getValue(){let e=this.dateOption("value");if(!e.length)return e;let[t,n]=e;return t&&n&&t>n&&([t,n]=[n,t]),[t,n]}_getRange(){let[e,t]=this._getValue();return this._getDaysInRange(e,t)}_getDaysInRange(e,t){if(!e||!t)return[];let{currentDate:n,viewsCount:o}=this.calendar.option(),s=this.calendar._isAdditionalViewDate(n),r=j.getFirstMonthDate(n,s?-2:-1),a=j.getLastMonthDate(n,s?1:o),l=new Date(Math.max(r,e)),d=new Date(Math.min(a,t));return[...j.getDatesOfInterval(l,d,864e5),d]}_cellHoverHandler(e){let t=this._isMaxZoomLevel(),[n,o]=this._getValue(),{_allowChangeSelectionOrder:s,_currentSelection:r}=this.calendar.option();if(t){if(n&&!o&&!(s&&r==="startDate")){if(e.value>n){this._updateViewsOption("hoveredRange",this._getDaysInRange(n,e.value));return}}else if(!n&&o&&!(s&&r==="endDate")){if(e.value<o){this._updateViewsOption("hoveredRange",this._getDaysInRange(e.value,o));return}}else if(n&&o){if(r==="startDate"&&e.value<n){this._updateViewsOption("hoveredRange",this._getDaysInRange(e.value,n));return}if(r==="endDate"&&e.value>o){this._updateViewsOption("hoveredRange",this._getDaysInRange(o,e.value));return}}this._updateViewsOption("hoveredRange",[])}}_weekNumberClickHandler(e){let{rowDates:t,event:n}=e,o=t.filter(r=>!this._isDateDisabled(r)),s=o.length?[o[0],o[o.length-1]]:[null,null];this.dateValue(s,n)}},dF=mb;var fb=class extends Yl{constructor(e){super(e),this.NAME="SingleSelection"}getViewOptions(){return{value:this.dateOption("value"),range:[],selectionMode:"single"}}selectValue(e,t){this.skipNavigate(),this.dateValue(e,t)}updateAriaSelected(e,t){e??(e=[this.dateOption("value")]),t??(t=[]),super.updateAriaSelected(e,t)}getDefaultCurrentDate(){let e=this.dateOption("value");return e===""?new Date:e}restoreValue(){this.calendar.option("value",null)}_updateViewsValue(e){this._updateViewsOption("value",e[0])}},cF=fb;var{abstract:Xo}=Xe;var uF="td:not(.dx-calendar-week-number-cell)",_b=D(oe,"dxCalendar"),hF=D(pr,"dxCalendar");var n3={month:O.format("dxCalendar-currentDay"),year:O.format("dxCalendar-currentMonth"),decade:O.format("dxCalendar-currentYear"),century:O.format("dxCalendar-currentYearRange")};var xa={single:"single",multiple:"multiple",range:"range"},o3=Xe.inherit({_getViewName:()=>"base",_getDefaultOptions(){return m(this.callBase(),{date:new Date,focusStateEnabled:!1,cellTemplate:null,disabledDates:null,onCellClick:null,onCellHover:null,onWeekNumberClick:null,rowCount:3,colCount:4,allowValueSelection:!0,_todayDate:()=>new Date})},_initMarkup(){this.callBase(),this._renderImpl()},_renderImpl(){this.$element().append(this._createTable()),this._createDisabledDatesHandler(),this._renderBody(),this._renderContouredDate(),this._renderValue(),this._renderRange(),this._renderEvents(),this._updateTableAriaLabel()},_getLocalizedWidgetName(){return O.format("dxCalendar-ariaWidgetName")},_getSingleModeAriaLabel(){let{value:i}=this.option(),e=this._getLocalizedWidgetName(),t=de.format(i,"date"),n=O.format("dxCalendar-selectedDate",t);return`${e}. ${n}`},_getRangeModeAriaLabel(){let{value:i}=this.option(),e=this._getLocalizedWidgetName(),[t,n]=i,o=de.format(t,"date"),s=de.format(n,"date"),r=t&&n?O.format("dxCalendar-selectedDateRange",o,s):O.format("dxCalendar-selectedDate",o??s);return`${e}. ${r}`},_getMultipleModeAriaLabel(){return this._getLocalizedWidgetName()},_getTableAriaLabel(){let{value:i,selectionMode:e}=this.option();if(!i||Array.isArray(i)&&!i.filter(Boolean).length)return this._getLocalizedWidgetName();switch(e){case xa.single:return this._getSingleModeAriaLabel();case xa.range:return this._getRangeModeAriaLabel();case xa.multiple:return this._getMultipleModeAriaLabel()}},_updateTableAriaLabel(){let i=this._getTableAriaLabel();this.setAria({label:i},this._$table)},_createTable(){return this._$table=u("<table>"),this.setAria({role:"grid"},this._$table),this._$table},_renderBody(){this.$body=u("<tbody>").appendTo(this._$table);let i={cellDate:this._getFirstCellData(),prevCellDate:null};for(let e=0,t=this.option("rowCount");e<t;e++){i.row=this._createRow();for(let n=0,o=this.option("colCount");n<o;n++)this._renderCell(i,n);this._renderWeekNumberCell(i)}},_createRow(){let i=w.createElement("tr");return this.setAria("role","row",u(i)),this.$body.get(0).appendChild(i),i},_createCell(i,e){let t=w.createElement("td"),n=u(t);return t.className=this._getClassNameByDate(i,e),t.setAttribute("data-value",tt.serializeDate(i,j.getShortDateFormat())),$e(t,"dxDateValueKey",i),this.setAria({role:"gridcell",selected:!1,label:this.getCellAriaLabel(i)},n),{cell:t,$cell:n}},_renderCell(i,e){let{cellDate:t,prevCellDate:n,row:o}=i;n&&j.fixTimezoneGap(n,t),i.prevCellDate=t;let{cell:s,$cell:r}=this._createCell(t,e),a=this.option("cellTemplate");u(o).append(s),a?a.render(this._prepareCellTemplateData(t,e,r)):s.innerHTML=this._getCellText(t),i.cellDate=this._getNextCellData(t)},_getClassNameByDate(i,e){let t="dx-calendar-cell";return this._isTodayCell(i)&&(t+=" dx-calendar-today"),(this._isDateOutOfRange(i)||this.isDateDisabled(i))&&(t+=" dx-calendar-empty-cell"),this._isOtherView(i)&&(t+=" dx-calendar-other-view"),this.option("selectionMode")===xa.range&&(e===0&&(t+=" dx-calendar-cell-start-in-row"),e===this.option("colCount")-1&&(t+=" dx-calendar-cell-end-in-row"),this._isStartDayOfMonth(i)&&(t+=" dx-calendar-cell-start"),this._isEndDayOfMonth(i)&&(t+=" dx-calendar-cell-end")),t},_prepareCellTemplateData(i,e,t){let n=i instanceof Date,o=n?this._getCellText(i):i,s=n?i:void 0,r=this._getViewName();return{model:{text:o,date:s,view:r},container:N(t),index:e}},_renderEvents(){this._createCellClickAction(),_.off(this._$table,_b),_.on(this._$table,_b,uF,e=>{u(e.currentTarget).hasClass("dx-calendar-empty-cell")||this._cellClickAction({event:e,value:u(e.currentTarget).data("dxDateValueKey")})});let{selectionMode:i}=this.option();_.off(this._$table,hF),i===xa.range&&(this._createCellHoverAction(),_.on(this._$table,hF,uF,e=>{u(e.currentTarget).hasClass("dx-calendar-empty-cell")||this._cellHoverAction({event:e,value:u(e.currentTarget).data("dxDateValueKey")})})),i!==xa.single&&(this._createWeekNumberCellClickAction(),_.on(this._$table,_b,".dx-calendar-week-number-cell",e=>{let t=u(e.currentTarget).closest("tr"),n=t.find(".dx-calendar-cell").first().data("dxDateValueKey"),o=t.find(".dx-calendar-cell").last().data("dxDateValueKey"),s=[...j.getDatesOfInterval(n,o,864e5),o];this._weekNumberCellClickAction({event:e,rowDates:s})}))},_createCellClickAction(){this._cellClickAction=this._createActionByOption("onCellClick")},_createCellHoverAction(){this._cellHoverAction=this._createActionByOption("onCellHover")},_createWeekNumberCellClickAction(){this._weekNumberCellClickAction=this._createActionByOption("onWeekNumberClick")},_createDisabledDatesHandler(){let i=this.option("disabledDates");this._disabledDatesHandler=Array.isArray(i)?this._getDefaultDisabledDatesHandler(i):i||S},_getDefaultDisabledDatesHandler:()=>S,_isTodayCell:Xo,_isDateOutOfRange:Xo,isDateDisabled(i){let e={date:i,view:this._getViewName()};return this._disabledDatesHandler(e)},_isOtherView:Xo,_isStartDayOfMonth:Xo,_isEndDayOfMonth:Xo,_getCellText:Xo,_getFirstCellData:Xo,_getNextCellData:Xo,_renderContouredDate(i){if(!this.option("focusStateEnabled"))return;i=i||this.option("contouredDate");let e=this._getContouredCell(),t=this._getCellByDate(i);e.removeClass("dx-calendar-contoured-date"),i&&t.addClass("dx-calendar-contoured-date")},_getContouredCell(){return this._$table.find(".dx-calendar-contoured-date")},_renderValue(){if(!this.option("allowValueSelection"))return;let i=this.option("value");Array.isArray(i)||(i=[i]),this._updateSelectedClass(i)},_updateSelectedClass(i){var e;this._isRangeMode()&&!this._isMonthView()||((e=this._$selectedCells)===null||e===void 0||e.forEach(t=>{t.removeClass("dx-calendar-selected-date")}),this._$selectedCells=i.map(t=>this._getCellByDate(t)),this._$selectedCells.forEach(t=>{t.addClass("dx-calendar-selected-date")}))},_renderRange(){var i,e,t,n,o,s,r,a;let{allowValueSelection:l,value:d,range:c}=this.option();!l||!this._isRangeMode()||!this._isMonthView()||((i=this._$rangeCells)===null||i===void 0||i.forEach(h=>{h.removeClass("dx-calendar-cell-in-range")}),(e=this._$hoveredRangeCells)===null||e===void 0||e.forEach(h=>{h.removeClass("dx-calendar-cell-range-hover")}),(t=this._$rangeStartHoverCell)===null||t===void 0||t.removeClass("dx-calendar-cell-range-hover-start"),(n=this._$rangeEndHoverCell)===null||n===void 0||n.removeClass("dx-calendar-cell-range-hover-end"),(o=this._$rangeStartDateCell)===null||o===void 0||o.removeClass("dx-calendar-range-start-date"),(s=this._$rangeEndDateCell)===null||s===void 0||s.removeClass("dx-calendar-range-end-date"),this._$rangeCells=c.map(h=>this._getCellByDate(h)),this._$rangeStartDateCell=this._getCellByDate(d[0]),this._$rangeEndDateCell=this._getCellByDate(d[1]),this._$rangeCells.forEach(h=>{h.addClass("dx-calendar-cell-in-range")}),(r=this._$rangeStartDateCell)===null||r===void 0||r.addClass("dx-calendar-range-start-date"),(a=this._$rangeEndDateCell)===null||a===void 0||a.addClass("dx-calendar-range-end-date"))},_renderHoveredRange(){var i,e,t,n,o;let{allowValueSelection:s,hoveredRange:r}=this.option();!s||!this._isRangeMode()||!this._isMonthView()||((i=this._$hoveredRangeCells)===null||i===void 0||i.forEach(a=>{a.removeClass("dx-calendar-cell-range-hover")}),(e=this._$rangeStartHoverCell)===null||e===void 0||e.removeClass("dx-calendar-cell-range-hover-start"),(t=this._$rangeEndHoverCell)===null||t===void 0||t.removeClass("dx-calendar-cell-range-hover-end"),this._$hoveredRangeCells=r.map(a=>this._getCellByDate(a)),this._$rangeStartHoverCell=this._getCellByDate(r[0]),this._$rangeEndHoverCell=this._getCellByDate(r[r.length-1]),this._$hoveredRangeCells.forEach(a=>{a.addClass("dx-calendar-cell-range-hover")}),(n=this._$rangeStartHoverCell)===null||n===void 0||n.addClass("dx-calendar-cell-range-hover-start"),(o=this._$rangeEndHoverCell)===null||o===void 0||o.addClass("dx-calendar-cell-range-hover-end"))},_isMonthView(){return this.option("zoomLevel")==="month"},_isRangeMode(){return this.option("selectionMode")===xa.range},_getCurrentDateFormat:()=>null,getCellAriaLabel(i){let e=this._getViewName(),t=this._isTodayCell(i),n=this._getCurrentDateFormat(),o=n?de.format(i,n):this._getCellText(i);return t?`${o}. ${n3[e]}`:o},_getFirstAvailableDate(){let i=this.option("date"),e=this.option("min");return i=j.getViewFirstCellDate(this._getViewName(),i),new Date(e&&i<e?e:i)},_getCellByDate:Xo,isBoundary:Xo,_optionChanged(i){let{name:e,value:t}=i;switch(e){case"value":this._renderValue(),this._updateTableAriaLabel();break;case"range":this._renderRange();break;case"hoveredRange":this._renderHoveredRange();break;case"contouredDate":this._renderContouredDate(t);break;case"onCellClick":this._createCellClickAction();break;case"onCellHover":this._createCellHoverAction();break;case"min":case"max":case"disabledDates":case"cellTemplate":case"selectionMode":this._invalidate();break;case"_todayDate":this._renderBody();break;default:this.callBase(i)}}}),Qc=o3;var s3={month:Qc.inherit({_getViewName:()=>"month",_getCurrentDateFormat:()=>"longdate",_getDefaultOptions(){return m(this.callBase(),{firstDayOfWeek:0,rowCount:6,colCount:7})},_renderImpl(){this.callBase(),this._renderHeader()},_renderBody(){this.callBase(),this._$table.find(".dx-calendar-other-view").addClass("dx-calendar-other-month")},_renderFocusTarget:S,_renderHeader(){let i=u("<tr>"),e=u("<thead>").append(i);this._$table.prepend(e);for(let t=0,n=this.option("colCount");t<n;t++)this._renderHeaderCell(t,i);this.option("showWeekNumbers")&&this._renderWeekHeaderCell(i)},_renderHeaderCell(i,e){let{firstDayOfWeek:t}=this.option(),{full:n,abbreviated:o}=this._getDayCaption(t+i),s=u("<th>").attr({scope:"col",abbr:n}).text(o);e.append(s)},_renderWeekHeaderCell(i){let e=u("<th>").attr({scope:"col",abbr:"WeekNumber",class:"dx-week-number-header"});i.prepend(e)},_renderWeekNumberCell(i){let{showWeekNumbers:e,cellTemplate:t,selectionMode:n,selectWeekOnClick:o}=this.option();if(!e)return;let s=this._getWeekNumber(i.prevCellDate),r=w.createElement("td"),a=u(r);r.className="dx-calendar-week-number-cell",n!=="single"&&o&&a.addClass("dx-calendar-week-selection"),t?t.render(this._prepareCellTemplateData(s,-1,a)):r.innerHTML=s,i.row.prepend(r),this.setAria({role:"gridcell",label:`Week ${s}`},a)},_getWeekNumber(i){let{weekNumberRule:e,firstDayOfWeek:t}=this.option();return e==="auto"?j.getWeekNumber(i,t,t===1?"firstFourDays":"firstDay"):j.getWeekNumber(i,t,e)},getNavigatorCaption(){return de.format(this.option("date"),"monthandyear")},_isTodayCell(i){let e=this.option("_todayDate")();return j.sameDate(i,e)},_isDateOutOfRange(i){let e=this.option("min"),t=this.option("max");return!j.dateInRange(i,e,t,"date")},_isOtherView(i){return i.getMonth()!==this.option("date").getMonth()},_isStartDayOfMonth(i){return j.sameDate(i,j.getFirstMonthDate(this.option("date")))},_isEndDayOfMonth(i){return j.sameDate(i,j.getLastMonthDate(this.option("date")))},_getCellText:i=>de.format(i,"d"),_getDayCaption(i){let e=this.option("colCount"),t=i%e;return{full:de.getDayNames()[t],abbreviated:de.getDayNames("abbreviated")[t]}},_getFirstCellData(){let{firstDayOfWeek:i}=this.option(),e=j.getFirstMonthDate(this.option("date")),t=i-e.getDay(),n=this.option("colCount");return t>=0&&(t-=n),e.setDate(e.getDate()+t),e},_getNextCellData(i){return i=new Date(i),i.setDate(i.getDate()+1),i},_getCellByDate(i){return this._$table.find(`td[data-value='${tt.serializeDate(i,j.getShortDateFormat())}']`)},isBoundary(i){return j.sameMonthAndYear(i,this.option("min"))||j.sameMonthAndYear(i,this.option("max"))},_getDefaultDisabledDatesHandler:i=>function(e){if(i.some(n=>j.sameDate(n,e.date)))return!0}}),year:Qc.inherit({_getViewName:()=>"year",_getCurrentDateFormat:()=>"monthandyear",_isTodayCell(i){let e=this.option("_todayDate")();return j.sameMonthAndYear(i,e)},_isDateOutOfRange(i){return!j.dateInRange(i,j.getFirstMonthDate(this.option("min")),j.getLastMonthDate(this.option("max")))},_isOtherView:()=>!1,_isStartDayOfMonth:()=>!1,_isEndDayOfMonth:()=>!1,_getCellText:i=>de.getMonthNames("abbreviated")[i.getMonth()],_getFirstCellData(){let i=this.option("date"),e=new Date(i);return e.setDate(1),e.setMonth(0),e},_getNextCellData(i){return i=new Date(i),i.setMonth(i.getMonth()+1),i},_getCellByDate(i){let e=new Date(i);return e.setDate(1),this._$table.find(`td[data-value='${tt.serializeDate(e,j.getShortDateFormat())}']`)},getNavigatorCaption(){return de.format(this.option("date"),"yyyy")},isBoundary(i){return j.sameYear(i,this.option("min"))||j.sameYear(i,this.option("max"))},_renderWeekNumberCell:S}),decade:Qc.inherit({_getViewName:()=>"decade",_isTodayCell(i){let e=this.option("_todayDate")();return j.sameYear(i,e)},_isDateOutOfRange(i){let e=this.option("min"),t=this.option("max");return!j.dateInRange(i.getFullYear(),e&&e.getFullYear(),t&&t.getFullYear())},_isOtherView(i){let e=new Date(i);return e.setMonth(1),!j.sameDecade(e,this.option("date"))},_isStartDayOfMonth:()=>!1,_isEndDayOfMonth:()=>!1,_getCellText:i=>de.format(i,"yyyy"),_getFirstCellData(){let i=j.getFirstYearInDecade(this.option("date"))-1;return j.createDateWithFullYear(i,0,1)},_getNextCellData(i){return i=new Date(i),i.setFullYear(i.getFullYear()+1),i},getNavigatorCaption(){let i=this.option("date"),e=j.getFirstYearInDecade(i),t=new Date(i),n=new Date(i);return t.setFullYear(e),n.setFullYear(e+9),`${de.format(t,"yyyy")}-${de.format(n,"yyyy")}`},_isValueOnCurrentView:(i,e)=>j.sameDecade(i,e),_getCellByDate(i){let e=new Date(i);return e.setDate(1),e.setMonth(0),this._$table.find(`td[data-value='${tt.serializeDate(e,j.getShortDateFormat())}']`)},isBoundary(i){return j.sameDecade(i,this.option("min"))||j.sameDecade(i,this.option("max"))},_renderWeekNumberCell:S}),century:Qc.inherit({_getViewName:()=>"century",_isTodayCell(i){let e=this.option("_todayDate")();return j.sameDecade(i,e)},_isDateOutOfRange(i){let e=j.getFirstYearInDecade(i),t=j.getFirstYearInDecade(this.option("min")),n=j.getFirstYearInDecade(this.option("max"));return!j.dateInRange(e,t,n)},_isOtherView(i){let e=new Date(i);return e.setMonth(1),!j.sameCentury(e,this.option("date"))},_isStartDayOfMonth:()=>!1,_isEndDayOfMonth:()=>!1,_getCellText(i){let e=de.format(i,"yyyy"),t=new Date(i);return t.setFullYear(t.getFullYear()+9),`${e} - ${de.format(t,"yyyy")}`},_getFirstCellData(){let i=j.getFirstDecadeInCentury(this.option("date"))-10;return j.createDateWithFullYear(i,0,1)},_getNextCellData(i){return i=new Date(i),i.setFullYear(i.getFullYear()+10),i},_getCellByDate(i){let e=new Date(i);return e.setDate(1),e.setMonth(0),e.setFullYear(j.getFirstYearInDecade(e)),this._$table.find(`td[data-value='${tt.serializeDate(e,j.getShortDateFormat())}']`)},getNavigatorCaption(){let i=this.option("date"),e=j.getFirstDecadeInCentury(i),t=new Date(i),n=new Date(i);return t.setFullYear(e),n.setFullYear(e+99),`${de.format(t,"yyyy")}-${de.format(n,"yyyy")}`},isBoundary(i){return j.sameCentury(i,this.option("min"))||j.sameCentury(i,this.option("max"))},_renderWeekNumberCell:S})},pF=s3;var gF=D(gr,"dxCalendar"),Xl={month:3,year:2,decade:1,century:0},Fi={MONTH:"month",YEAR:"year",DECADE:"decade",CENTURY:"century"},r3={SingleSelection:cF,MultipleSelection:aF,RangeSelection:dF},mF=oi.inherit({_activeStateUnit:".dx-calendar-cell",_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,activeStateEnabled:!0,currentDate:new Date,value:null,dateSerializationFormat:void 0,min:new Date(1e3,0),max:new Date(3e3,0),firstDayOfWeek:void 0,viewsCount:1,zoomLevel:Fi.MONTH,maxZoomLevel:Fi.MONTH,minZoomLevel:Fi.CENTURY,selectionMode:"single",selectWeekOnClick:!0,showTodayButton:!1,showWeekNumbers:!1,weekNumberRule:"auto",cellTemplate:"cell",disabledDates:null,onCellClick:null,onContouredChanged:null,skipFocusCheck:!1,_todayDate:()=>new Date})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}}])},_supportedKeys(){return m(this.callBase(),{rightArrow(i){i.preventDefault(),ot(i)?this._waitRenderView(1):this._moveCurrentDateByOffset(1*this._getRtlCorrection())},leftArrow(i){i.preventDefault(),ot(i)?this._waitRenderView(-1):this._moveCurrentDateByOffset(-1*this._getRtlCorrection())},upArrow(i){if(i.preventDefault(),ot(i))this._navigateUp();else{if(pe.isAnimating(this._view.$element()))return;this._moveCurrentDateByOffset(-1*this._view.option("colCount"))}},downArrow(i){if(i.preventDefault(),ot(i))this._navigateDown();else{if(pe.isAnimating(this._view.$element()))return;this._moveCurrentDateByOffset(1*this._view.option("colCount"))}},home(i){i.preventDefault();let e=this.option("zoomLevel"),t=this.option("currentDate"),n=this._dateOption("min");if(this._view.isDateDisabled(t))return;let o=j.sameView(e,t,n)?n:j.getViewFirstCellDate(e,t);this._moveToClosestAvailableDate(o)},end(i){i.preventDefault();let e=this.option("zoomLevel"),t=this.option("currentDate"),n=this._dateOption("max");if(this._view.isDateDisabled(t))return;let o=j.sameView(e,t,n)?n:j.getViewLastCellDate(e,t);this._moveToClosestAvailableDate(o)},pageUp(i){i.preventDefault(),this._waitRenderView(-1*this._getRtlCorrection())},pageDown(i){i.preventDefault(),this._waitRenderView(1*this._getRtlCorrection())},tab:S,enter:this._enterKeyHandler})},_enterKeyHandler(i){if(!this._isMaxZoomLevel())this._navigateDown();else if(!this._view.isDateDisabled(this.option("currentDate"))){let e=this._updateTimeComponent(this.option("currentDate"));this._selectionStrategy.selectValue(e,i)}},_getSerializationFormat(i){let e=this.option(i||"value");if(this.option("dateSerializationFormat"))return this.option("dateSerializationFormat");if(xe(e))return"number";if(B(e))return tt.getDateSerializationFormat(e)},_convertToDate:i=>tt.deserializeDate(i),_dateValue(i,e){if(e){if(e.type==="keydown"){let t=this._view._getContouredCell().get(0);e.target=t}this._saveValueChangeEvent(e)}this._dateOption("value",i)},_dateOption(i,e){let t=i==="value"&&!this._isSingleMode(),n=this.option("value");if(arguments.length===1)return t?(n??[]).map(r=>this._convertToDate(r)):this._convertToDate(this.option(i));let o=this._getSerializationFormat(i),s=t?e?.map(r=>tt.serializeDate(r,o))||[]:tt.serializeDate(e,o);this.option(i,s)},_isSingleMode(){return this.option("selectionMode")==="single"},_shiftDate(i,e,t,n){switch(i){case Fi.MONTH:e.setDate(e.getDate()+t*n);break;case Fi.YEAR:e.setMonth(e.getMonth()+t*n);break;case Fi.DECADE:e.setFullYear(e.getFullYear()+t*n);break;case Fi.CENTURY:e.setFullYear(e.getFullYear()+10*t*n)}},_moveCurrentDateByOffset(i){let e=this.option("currentDate"),t=new Date(e),n=this.option("zoomLevel");this._shiftDate(n,t,i,1);let o=this._getMaxDate(),s=this._getMinDate(),r=this._areDatesInNeighborView(n,t,e),a=fn(t,s,o)&&r,l=new Date(t);for(;a;){if(!this._view.isDateDisabled(l)){t=l;break}this._shiftDate(n,l,i,1),r=this._areDatesInNeighborView(n,l,e),a=fn(l,s,o)&&r}if(this._view.isDateDisabled(e)||this._view.isDateDisabled(t)){let d=i>0?1:-1;(d===1?this._isNextViewDisabled():this._isPrevViewDisabled())?this._moveToClosestAvailableDate(t):this._waitRenderView(d)}else this._skipNavigate=!0,this.option("currentDate",t)},_isNextViewDisabled(){return this._navigator._nextButton.option("disabled")},_isPrevViewDisabled(){return this._navigator._prevButton.option("disabled")},_areDatesInSameView(i,e,t){switch(i){case Fi.MONTH:return e.getMonth()===t.getMonth();case Fi.YEAR:return e.getYear()===t.getYear();case Fi.DECADE:return parseInt(e.getYear()/10)===parseInt(t.getYear()/10);case Fi.CENTURY:return parseInt(e.getYear()/100)===parseInt(t.getYear()/100)}},_areDatesInNeighborView(i,e,t){switch(i){case Fi.MONTH:return((n,o)=>{let s=Math.abs(n-o);return Math.min(s,12-s)})(e.getMonth(),t.getMonth())<=1;case Fi.YEAR:return Math.abs(e.getYear()-t.getYear())<=1;case Fi.DECADE:return Math.abs(e.getYear()-t.getYear())<=10;case Fi.CENTURY:return Math.abs(e.getYear()-t.getYear())<=100}},_moveToClosestAvailableDate(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.option("currentDate"),e=new Date(i),t=this.option("zoomLevel"),n=!this._isDateNotAvailable(e),o=n,s=n,r,a,l=new Date(e),d=new Date(e);do{if(o){e=l;break}if(s){e=d;break}this._shiftDate(t,l,1,1),this._shiftDate(t,d,1,-1),r=this._areDatesInSameView(t,l,i),a=this._areDatesInSameView(t,d,i),o=r&&!this._isDateNotAvailable(l),s=a&&!this._isDateNotAvailable(d)}while(r||a);this.option("currentDate",e)},_isDateNotAvailable(i){let e=this._getMaxDate(),t=this._getMinDate();return!fn(i,t,e)||this._view.isDateDisabled(i)},_init(){this.callBase(),this._initSelectionStrategy(),this._correctZoomLevel(),this._initCurrentDate(),this._initActions()},_initSelectionStrategy(){let i=this._getSelectionStrategyName(),e=r3[i];(!this._selectionStrategy||this._selectionStrategy.NAME!==i)&&(this._selectionStrategy=new e(this))},_refreshSelectionStrategy(){this._initSelectionStrategy(),this._selectionStrategy.restoreValue(),this._refresh()},_getSelectionStrategyName(){switch(this.option("selectionMode")){case"multiple":return"MultipleSelection";case"range":return"RangeSelection";default:return"SingleSelection"}},_correctZoomLevel(){let i=this.option("minZoomLevel"),e=this.option("maxZoomLevel"),t=this.option("zoomLevel");Xl[e]<Xl[i]||(Xl[t]>Xl[e]?this.option("zoomLevel",e):Xl[t]<Xl[i]&&this.option("zoomLevel",i))},_initCurrentDate(){let i=this._getNormalizedDate(this._selectionStrategy.getDefaultCurrentDate())??this._getNormalizedDate(this.option("currentDate"));this.option("currentDate",i)},_getNormalizedDate(i){return i=j.normalizeDate(i,this._getMinDate(),this._getMaxDate()),f(i)?this._getDate(i):i},_initActions(){this._cellClickAction=this._createActionByOption("onCellClick"),this._onContouredChanged=this._createActionByOption("onContouredChanged")},_initTemplates(){this._templateManager.addDefaultTemplates({cell:new gn(i=>{let e=i.model;u(i.container).append(u("<span>").text(e&&e.text||String(e)))})}),this.callBase()},_updateCurrentDate(i){pe.isAnimating(this._$viewsWrapper)&&pe.stop(this._$viewsWrapper,!0);let e=this._getMinDate(),t=this._getMaxDate();if(e>t){this.option("currentDate",new Date);return}let n=this._getNormalizedDate(i);if(i.getTime()!==n.getTime()){this.option("currentDate",new Date(n));return}let o=this._getViewsOffset(this._view.option("date"),n);o!==0&&!this._isMaxZoomLevel()&&this._isOtherViewCellClicked&&(o=0),this._view&&o!==0&&!this._suppressNavigation?this._additionalView?o>2||o<-1?(this._refreshViews(),this._setViewContoured(n),this._updateAriaId(n),this._renderNavigator()):o===1&&this._skipNavigate?(this._setViewContoured(n),this._updateAriaId(n)):this._navigate(o,n):this._navigate(o,n):(this._renderNavigator(),this._setViewContoured(n),this._updateAriaId(n)),this._skipNavigate=!1},_isAdditionalViewDate(i){return this._additionalView?i>=this._additionalView._getFirstAvailableDate():!1},_getActiveView(i){return this._isAdditionalViewDate(i)?this._additionalView:this._view},_setViewContoured(i){if(this.option("skipFocusCheck")||u(this._$viewsWrapper).is(":focus")){var e;this._view.option("contouredDate",null),(e=this._additionalView)===null||e===void 0||e.option("contouredDate",null),(this._isAdditionalViewDate(i)?this._additionalView:this._view).option("contouredDate",i)}},_getMinDate(){let i=this.option("_rangeMin");return i||(this.min?this.min:(this.min=this._dateOption("min")||new Date(1e3,0),this.min))},_getMaxDate(){let i=this.option("_rangeMax");return i||(this.max?this.max:(this.max=this._dateOption("max")||new Date(3e3,0),this.max))},_getViewsOffset(i,e){let t=this.option("zoomLevel");if(t===Fi.MONTH)return this._getMonthsOffset(i,e);let n;switch(t){case Fi.CENTURY:n=100;break;case Fi.DECADE:n=10;break;default:n=1}return parseInt(e.getFullYear()/n)-parseInt(i.getFullYear()/n)},_getMonthsOffset(i,e){let t=e.getFullYear()-i.getFullYear(),n=e.getMonth()-i.getMonth();return 12*t+n},_waitRenderView(i){if(this._alreadyViewRender)return;this._alreadyViewRender=!0;let e=this._getDateByOffset(i*this._getRtlCorrection());this._moveToClosestAvailableDate(e),this._waitRenderViewTimeout=setTimeout(()=>{this._alreadyViewRender=!1})},_getRtlCorrection(){return this.option("rtlEnabled")?-1:1},_getDateByOffset(i,e){e=this._getDate(e??this.option("currentDate"));let t=e.getDate(),n=j.getDifferenceInMonth(this.option("zoomLevel"))*i;e.setDate(1),e.setMonth(e.getMonth()+n);let o=j.getLastMonthDate(e).getDate();return e.setDate(t>o?o:t),e},_focusTarget(){return this._$viewsWrapper},_focusEventTarget(){return this.$element()},_initMarkup(){this._renderSubmitElement();let i=this.$element();i.addClass("dx-calendar"),i.toggleClass("dx-calendar-range",this.option("selectionMode")==="range"),this._renderBody(),i.append(this.$body),this._renderViews(),this._renderNavigator(),this.callBase(),this._renderEvents(),i.prepend(this._navigator.$element()),this._renderSwipeable(),this._renderFooter(),this._selectionStrategy.updateAriaSelected(),this._updateAriaId(),this._updateNavigatorLabels(),this.setAria("role","application"),this._moveToClosestAvailableDate()},_render(){this.callBase(),this._setViewContoured(this.option("currentDate"))},_renderBody(){this._$viewsWrapper||(this.$body=u("<div>").addClass("dx-calendar-body"),this._$viewsWrapper=u("<div>").addClass("dx-calendar-views-wrapper"),this.$body.append(this._$viewsWrapper))},_setAriaReadonly:S,_getKeyboardListeners(){return this.callBase().concat([this._view])},_renderViews(){this.$element().addClass(`dx-calendar-view-${this.option("zoomLevel")}`);let{currentDate:i,viewsCount:e}=this.option();if(this.$element().toggleClass("dx-calendar-multiview",e>1),this._view=this._renderSpecificView(i),W()){let t=this._getDateByOffset(-1,i);this._beforeView=this._isViewAvailable(t)?this._renderSpecificView(t):null;let n=this._getDateByOffset(e,i);n.setDate(1),this._afterView=this._isViewAvailable(n)?this._renderSpecificView(n):null}e>1&&(this._additionalView=this._renderSpecificView(this._getDateByOffset(1,i))),this._translateViews()},_renderSpecificView(i){let{zoomLevel:e}=this.option(),t=pF[e],n=u("<div>").appendTo(this._$viewsWrapper),o=this._viewConfig(i);return this._createComponent(n,t,o)},_viewConfig(i){let e=this.option("disabledDates");return e=A(e)?this._injectComponent(e.bind(this)):e,I({},this._selectionStrategy.getViewOptions(),{date:i,min:this._getMinDate(),max:this._getMaxDate(),firstDayOfWeek:this.option("firstDayOfWeek")??de.firstDayOfWeekIndex(),showWeekNumbers:this.option("showWeekNumbers"),selectWeekOnClick:this.option("selectWeekOnClick"),weekNumberRule:this.option("weekNumberRule"),zoomLevel:this.option("zoomLevel"),tabIndex:void 0,focusStateEnabled:this.option("focusStateEnabled"),hoverStateEnabled:this.option("hoverStateEnabled"),disabledDates:e,onCellClick:this._cellClickHandler.bind(this),cellTemplate:this._getTemplateByOption("cellTemplate"),allowValueSelection:this._isMaxZoomLevel(),_todayDate:this.option("_todayDate")})},_renderEvents(){_.off(this._$viewsWrapper,gF),this.option("selectionMode")==="range"&&_.on(this._$viewsWrapper,gF,null,()=>{this._updateViewsOption("hoveredRange",[])})},_injectComponent(i){let e=this;return function(t){return m(t,{component:e}),i(t)}},_isViewAvailable(i){let e=this.option("zoomLevel"),t=j.getViewMinBoundaryDate(e,this._getMinDate()),n=j.getViewMaxBoundaryDate(e,this._getMaxDate());return j.dateInRange(i,t,n)},_translateViews(){let{viewsCount:i}=this.option();Ae(this._view.$element(),{left:0,top:0}),this._moveViewElement(this._beforeView,-1),this._moveViewElement(this._afterView,i),this._moveViewElement(this._additionalView,1)},_moveViewElement(i,e){i&&Ae(i.$element(),{left:this._getViewPosition(e),top:0})},_getViewPosition(i){let e=this.option("rtlEnabled")?-1:1;return 100*i*e+"%"},_cellClickHandler(i){let e=this.option("zoomLevel"),t=j.getViewDown(e),n=this._isMaxZoomLevel();if(t&&!n)this._navigateDown(i.event.currentTarget);else{let o=this._updateTimeComponent(i.value);this._selectionStrategy.selectValue(o,i.event),this._cellClickAction(i)}},_updateTimeComponent(i){let e=new Date(i),t=this._dateOption("value");return t&&this._isSingleMode()&&(e.setHours(t.getHours()),e.setMinutes(t.getMinutes()),e.setSeconds(t.getSeconds()),e.setMilliseconds(t.getMilliseconds())),e},_isMaxZoomLevel(){return this.option("zoomLevel")===this.option("maxZoomLevel")},_navigateDown(i){let e=this.option("zoomLevel");if(this._isMaxZoomLevel())return;let t=j.getViewDown(e);if(!t)return;let n=this._view.option("contouredDate")||this._view.option("date");i&&(n=u(i).data("dxDateValueKey")),this._isOtherViewCellClicked=!0,this.option("currentDate",n),this.option("zoomLevel",t),this._isOtherViewCellClicked=!1,this._renderNavigator(),this._animateShowView(),this._moveToClosestAvailableDate(),this._setViewContoured(this._getNormalizedDate(this.option("currentDate")))},_renderNavigator(){this._navigator||(this._navigator=new lF(u("<div>"),this._navigatorConfig())),this._navigator.option("text",this._getViewsCaption(this._view,this._additionalView)),this._updateButtonsVisibility()},_navigatorConfig(){let{focusStateEnabled:i,rtlEnabled:e}=this.option();return{text:this._getViewsCaption(this._view,this._additionalView),onClick:this._navigatorClickHandler.bind(this),onCaptionClick:this._navigateUp.bind(this),focusStateEnabled:i,rtlEnabled:e,tabIndex:void 0}},_navigatorClickHandler(i){let{currentDate:e,viewsCount:t}=this.option(),n=i.direction;if(t>1){let s=this._isAdditionalViewDate(e);(s&&n<0||!s&&n>0)&&(n*=2)}let o=this._getDateByOffset(n,e);this._moveToClosestAvailableDate(o)},_navigateUp(){let i=this.option("zoomLevel"),e=j.getViewUp(i);!e||this._isMinZoomLevel(i)||(this.option("zoomLevel",e),this._renderNavigator(),this._animateShowView(),this._moveToClosestAvailableDate(),this._setViewContoured(this._getNormalizedDate(this.option("currentDate"))))},_isMinZoomLevel(i){let e=this._getMinDate(),t=this._getMaxDate();return j.sameView(i,e,t)||this.option("minZoomLevel")===i},_updateButtonsVisibility(){this._navigator.toggleButton("next",!f(this._afterView)),this._navigator.toggleButton("prev",!f(this._beforeView))},_renderSwipeable(){this._swipeable||(this._swipeable=this._createComponent(this.$element(),Ns,{onStart:this._swipeStartHandler.bind(this),onUpdated:this._swipeUpdateHandler.bind(this),onEnd:this._swipeEndHandler.bind(this),itemSizeFunc:this._viewWidth.bind(this)}))},_swipeStartHandler(i){pe.stop(this._$viewsWrapper,!0);let{viewsCount:e}=this.option();this._toggleGestureCoverCursor("grabbing"),i.event.maxLeftOffset=this._getRequiredView("next")?1/e:0,i.event.maxRightOffset=this._getRequiredView("prev")?1/e:0},_toggleGestureCoverCursor(i){u(".dx-gesture-cover").css("cursor",i)},_getRequiredView(i){let e,t=this.option("rtlEnabled");return i==="next"?e=t?this._beforeView:this._afterView:i==="prev"&&(e=t?this._afterView:this._beforeView),e},_swipeUpdateHandler(i){let{offset:e}=i.event;Ae(this._$viewsWrapper,{left:e*this._viewWidth(),top:0}),this._updateNavigatorCaption(e)},_swipeEndHandler(i){this._toggleGestureCoverCursor("auto");let{currentDate:e,rtlEnabled:t}=this.option(),{targetOffset:n}=i.event,o=n?n/Math.abs(n):0,r=this._isAdditionalViewDate(e)&&(t?o===-1:o===1);if(o===0){this._animateWrapper(0,250);return}let a=-o*this._getRtlCorrection()*(r?2:1),l=this._getDateByOffset(a);this._isDateInInvalidRange(l)&&(o>=0?l=new Date(this._getMinDate()):l=new Date(this._getMaxDate())),this.option("currentDate",l)},_viewWidth(){return this._viewWidthValue||(this._viewWidthValue=z(this.$element())/this.option("viewsCount")),this._viewWidthValue},_updateNavigatorCaption(i){i*=this._getRtlCorrection();let e=this.option("viewsCount")>1,t,n;i>.5&&this._beforeView?(t=this._beforeView,n=e&&this._view):i<-.5&&this._afterView?(t=e?this._additionalView:this._afterView,n=e?this._afterView:null):(t=this._view,n=e?this._additionalView:null),this._navigator.option("text",this._getViewsCaption(t,n))},_getViewsCaption(i,e){let t=i.getNavigatorCaption(),{viewsCount:n}=this.option();if(n>1&&e){let o=e.getNavigatorCaption();t=`${t} - ${o}`}return t},_isDateInInvalidRange(i){if(this._view.isBoundary(i))return;let e=this._getMinDate(),t=this._getMaxDate(),n=j.normalizeDate(i,e,t);return n===e||n===t},_renderFooter(){let i=this.option("showTodayButton");if(i){let e=this._createComponent(u("<div>"),rt,{focusStateEnabled:this.option("focusStateEnabled"),text:O.format("dxCalendar-todayButtonText"),onClick:t=>{this._toTodayView(t)},type:ut()?"normal":"default",stylingMode:ut()?"outlined":"text",integrationOptions:{}}).$element().addClass("dx-calendar-today-button");this._$footer=u("<div>").addClass("dx-calendar-footer").append(e),this.$element().append(this._$footer)}this.$element().toggleClass("dx-calendar-with-footer",i)},_renderSubmitElement(){this._$submitElement=u("<input>").attr("type","hidden").appendTo(this.$element()),this._setSubmitValue(this.option("value"))},_setSubmitValue(i){let e=this._convertToDate(i);this._getSubmitElement().val(tt.serializeDate(e,"yyyy-MM-dd"))},_getSubmitElement(){return this._$submitElement},_animateShowView(){pe.stop(this._view.$element(),!0),this._popAnimationView(this._view,.6,1,250),this.option("viewsCount")>1&&(pe.stop(this._additionalView.$element(),!0),this._popAnimationView(this._additionalView,.6,1,250))},_popAnimationView:(i,e,t,n)=>pe.animate(i.$element(),{type:"pop",from:{scale:e,opacity:e},to:{scale:t,opacity:t},duration:n}),_navigate(i,e){if(i!==0&&Math.abs(i)!==1&&this._isViewAvailable(e)){let r=this._renderSpecificView(e);i>0?(this._afterView&&this._afterView.$element().remove(),this._afterView=r):(this._beforeView&&this._beforeView.$element().remove(),this._beforeView=r),this._translateViews()}let t=this._getRtlCorrection(),n=i>0?1:i<0?-1:0,o=-t*n*this._viewWidth();this._$viewsWrapper.position().left!==o&&(this._preventViewChangeAnimation?this._wrapperAnimationEndHandler(i,e):this._animateWrapper(o,250).done(this._wrapperAnimationEndHandler.bind(this,i,e)))},_animateWrapper(i,e){return pe.animate(this._$viewsWrapper,{type:"slide",from:{left:this._$viewsWrapper.position().left},to:{left:i},duration:e})},_getDate:i=>new Date(i),_toTodayView(i){let e=new Date;if(this._isMaxZoomLevel()){this._selectionStrategy.selectValue(e,i.event);return}this._preventViewChangeAnimation=!0,this.option("zoomLevel",this.option("maxZoomLevel")),this._selectionStrategy.selectValue(e,i.event),this._animateShowView(),this._preventViewChangeAnimation=!1},_wrapperAnimationEndHandler(i,e){this._rearrangeViews(i),this._translateViews(),this._resetLocation(),this._renderNavigator(),this._setViewContoured(e),this._updateAriaId(e),this._selectionStrategy.updateAriaSelected()},_rearrangeViews(i){var e;if(i===0)return;let{viewsCount:t}=this.option(),n,o,s,r,a;if(i<0?(n=1,o="_beforeView",s="_afterView",r="_view",a=t===1?"_view":"_additionalView"):(n=-1,o="_afterView",s="_beforeView",r=t===1?"_view":"_additionalView",a="_view"),!this[o])return;let l=this[o].option("date");(e=this[s])===null||e===void 0||e.$element().remove(),this[s]=this._renderSpecificView(this._getDateByOffset(n*t,l)),this[a].$element().remove(),t===1?this[a]=this[o]:(this[a]=this[r],this[r]=this[o]);let d=this._getDateByOffset(-n,l);this[o]=this._isViewAvailable(d)?this._renderSpecificView(d):null},_resetLocation(){Ae(this._$viewsWrapper,{left:0,top:0})},_clean(){this.callBase(),this._clearViewWidthCache(),delete this._$viewsWrapper,delete this._navigator,delete this._$footer},_clearViewWidthCache(){delete this._viewWidthValue},_disposeViews(){this._view.$element().remove(),this._beforeView&&this._beforeView.$element().remove(),this._additionalView&&this._additionalView.$element().remove(),this._afterView&&this._afterView.$element().remove(),delete this._view,delete this._additionalView,delete this._beforeView,delete this._afterView,delete this._skipNavigate},_dispose(){clearTimeout(this._waitRenderViewTimeout),this.callBase()},_refreshViews(){this._resetActiveState(),this._disposeViews(),this._renderViews()},_visibilityChanged(){this._translateViews()},_shouldSkipFocusEvent(i){let{target:e,relatedTarget:t}=i;return u(e).parents(".dx-calendar").length&&u(t).parents(".dx-calendar").length},_focusInHandler(i){u(i.target).is(this._$viewsWrapper)&&this._setViewContoured(this.option("currentDate")),!this._shouldSkipFocusEvent(i)&&(this.callBase.apply(this,arguments),this._toggleFocusClass(!0,this.$element()))},_focusOutHandler(i){if(u(i.target).is(this._$viewsWrapper)){var e;this._view.option("contouredDate",null),(e=this._additionalView)===null||e===void 0||e.option("contouredDate",null)}this._shouldSkipFocusEvent(i)||(this.callBase.apply(this,arguments),this._toggleFocusClass(!1,this.$element()))},_updateViewsOption(i,e){var t,n,o;this._view.option(i,e),(t=this._additionalView)===null||t===void 0||t.option(i,e),(n=this._beforeView)===null||n===void 0||n.option(i,e),(o=this._afterView)===null||o===void 0||o.option(i,e)},_setViewsMinOption(i){this._restoreViewsMinMaxOptions(),this.option("_rangeMin",this._convertToDate(i)),this._updateViewsOption("min",this._getMinDate())},_setViewsMaxOption(i){this._restoreViewsMinMaxOptions(),this.option("_rangeMax",this._convertToDate(i)),this._updateViewsOption("max",this._getMaxDate())},_restoreViewsMinMaxOptions(){this._resetActiveState(),this.option({_rangeMin:null,_rangeMax:null}),this._updateViewsOption("min",this._getMinDate()),this._updateViewsOption("max",this._getMaxDate())},_updateNavigatorLabels(){let i=this.option("zoomLevel");i=i.charAt(0).toUpperCase()+i.slice(1);let e=this._navigator._caption.option("text"),t=O.format(`dxCalendar-previous${i}ButtonLabel`),n=O.format(`dxCalendar-caption${i}Label`),o=O.format(`dxCalendar-next${i}ButtonLabel`);this.setAria("label",t,this._navigator._prevButton.$element()),this.setAria("label",`${e}. ${n}`,this._navigator._caption.$element()),this.setAria("label",o,this._navigator._nextButton.$element())},_updateAriaSelected(i,e){e.forEach(t=>{this.setAria("selected",!1,this._view._getCellByDate(t))}),i.forEach(t=>{this.setAria("selected",!0,this._view._getCellByDate(t))}),this.option("viewsCount")>1&&(e.forEach(t=>{this.setAria("selected",!1,this._additionalView._getCellByDate(t))}),i.forEach(t=>{this.setAria("selected",!0,this._additionalView._getCellByDate(t))}))},_updateAriaId(i){i=i??this.option("currentDate");let e=`dx-${new Oe}`,n=this._getActiveView(i)._getCellByDate(i);this.setAria("id",e,n),this.setAria("activedescendant",e),this._onContouredChanged(e)},_suppressingNavigation(i,e){this._suppressNavigation=!0,i.apply(this,e),delete this._suppressNavigation},_optionChanged(i){let{value:e,previousValue:t}=i;switch(i.name){case"width":this.callBase(i),this._clearViewWidthCache();break;case"min":case"max":this.min=void 0,this.max=void 0,this._suppressingNavigation(this._updateCurrentDate,[this.option("currentDate")]),this._refreshViews(),this._renderNavigator();break;case"selectionMode":this._refreshSelectionStrategy(),this._initCurrentDate();break;case"selectWeekOnClick":case"_todayDate":case"showWeekNumbers":case"weekNumberRule":this._refreshViews();break;case"firstDayOfWeek":this._refreshViews(),this._updateButtonsVisibility();break;case"focusStateEnabled":case"disabledDates":case"dateSerializationFormat":case"cellTemplate":case"showTodayButton":this._invalidate();break;case"currentDate":this.setAria("id",void 0,this._view._getCellByDate(t)),this._updateCurrentDate(e);break;case"zoomLevel":this.$element().removeClass(`dx-calendar-view-${t}`),this._correctZoomLevel(),this._refreshViews(),this._renderNavigator(),this._updateAriaId(),this._updateNavigatorLabels();break;case"minZoomLevel":case"maxZoomLevel":this._correctZoomLevel(),this._updateButtonsVisibility();break;case"value":this._selectionStrategy.processValueChanged(e,t),this._setSubmitValue(e),this.callBase(i);break;case"viewsCount":this._refreshViews(),this._renderNavigator();break;case"onCellClick":this._view.option("onCellClick",e);break;case"onContouredChanged":this._onContouredChanged=this._createActionByOption("onContouredChanged");break;case"skipFocusCheck":break;default:this.callBase(i)}},getContouredDate(){return this._view.option("contouredDate")}});G("dxCalendar",mF);var fF=mF;var _F=fF;function CF(i,e){var t;return(((t=i.getRootNode)===null||t===void 0?void 0:t.call(i))??document).querySelector(e)}var xF="dx-invalid-message-auto",vF="dx-validation-target",Ql=class extends Ol{getProps(){let e=super.getProps();return e.onFocusIn=()=>{if(this.option("validationMessageMode")==="auto"){let n=u(CF(this.element(),".dx-invalid-message.dx-overlay-wrapper"));n?.removeClass(xF);let o=150;this.showValidationMessageTimeout&&clearTimeout(this.showValidationMessageTimeout),this.showValidationMessageTimeout=setTimeout(()=>{n?.addClass(xF)},o)}},e.saveValueChangeEvent=t=>{this._valueChangeEventInstance=t},e}_createElement(e){super._createElement(e),this.showValidationMessageTimeout=void 0,this.validationRequest=ue(),$e(this.$element()[0],vF,this)}_render(){var e;(e=this.option("_onMarkupRendered"))===null||e===void 0||e()}_init(){super._init(),this._initialValue=this.option("value")}_initializeComponent(){super._initializeComponent(),this._valueChangeAction=this._createActionByOption("onValueChanged",{excludeValidators:["disabled","readOnly"]})}_initOptions(e){super._initOptions(e),this.option(Xt.initValidationOptions(e))}_getDefaultOptions(){return m(super._getDefaultOptions(),{validationMessageOffset:{h:0,v:0},validationTooltipOptions:{}})}_bindInnerWidgetOptions(e,t){let n=m({},e.option()),o=()=>this._silent(t,n);o(),e.on("optionChanged",o)}_raiseValidation(e,t){let n=!f(e)&&!f(t);e!==t&&!n&&this.validationRequest.fire({value:e,editor:this})}_raiseValueChangeAction(e,t){var n;(n=this._valueChangeAction)===null||n===void 0||n.call(this,{element:this.$element(),previousValue:t,value:e,event:this._valueChangeEventInstance}),this._valueChangeEventInstance=void 0}_optionChanged(e){let{name:t,previousValue:n,value:o}=e;switch(t&&this._getActionConfigs()[t]!==void 0&&this._addAction(t),t){case"value":this._raiseValidation(o,n),this.option("isDirty",this._initialValue!==o),this._raiseValueChangeAction(o,n);break;case"onValueChanged":this._valueChangeAction=this._createActionByOption("onValueChanged",{excludeValidators:["disabled","readOnly"]});break;case"isValid":case"validationError":case"validationErrors":case"validationStatus":this.option(Xt.synchronizeValidationOptions(e,this.option()))}super._optionChanged(e)}clear(){let{value:e}=this._getDefaultOptions();this.option({value:e})}reset(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:void 0;arguments.length&&(this._initialValue=e),this.option("value",this._initialValue),this.option("isDirty",!1),this.option("isValid",!0)}_dispose(){super._dispose(),$e(this.element(),vF,null),this.showValidationMessageTimeout&&clearTimeout(this.showValidationMessageTimeout)}};var a3=oi.isEditor,bF=i=>a3(i)||i instanceof Ql;Ql.isEditor=bF;oi.isEditor=bF;var Tg=class extends Ql{_useTemplates(){return!1}_isFocused(){return this.$element()[0].classList.contains("dx-state-focused")}getSupportedKeyNames(){return["space"]}getProps(){let e=super.getProps();return e.value!==null&&(e.value=!!e.value),e}};var l3=["dataSource","selectedRowKeys"],d3={integrationOptions:!0};function Zc(i,e,t){return{path:i,value:e,previousValue:t}}function yF(i,e,t,n,o,s){if(d3[n])return;let r=ri(e),a=ri(t);if(e!==t)if(r!==a)i.push(Zc(n,t,e));else if(r==="object")if(!q(t))i.push(Zc(n,t,e));else{let l=OF(e,t,o,s);i.push(...l.map(d=>I({},d,{path:`${n}.${d.path}`})))}else if(r==="array")if(s.some(d=>o.includes(d))&&e!==t)i.push(Zc(n,t,e));else if(e.length!==t.length)i.push(Zc(n,t,e));else{let d=OF(e,t,o,s);[].push.apply(i,d.map(c=>I({},c,{path:`${n}${c.path}`})))}else i.push(Zc(n,t,e))}var SF=i=>(e,t,n,o)=>{let s=[],r=Array.isArray(e)?a=>{yF(s,e[a],t[a],`[${a}]`,`${n}.${a}`,o)}:a=>{yF(s,e[a],t[a],a,`${n}.${a}`,o)};return i(e).forEach(r),Object.keys(t).filter(a=>!Object.prototype.hasOwnProperty.call(e,a)&&e[a]!==t[a]).forEach(a=>{s.push({path:a,value:t[a],previousValue:e[a]})}),s},OF=SF(i=>Object.keys(i)),c3={key:!0,ref:!0,children:!0,style:!0},u3=SF(i=>Object.keys(i).filter(e=>!c3[e]));function EF(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:l3;return u3(i,e,"",t)}var h3=["valueChange"],p3=["componentProps","componentType","templateNames"],wF=i=>Object.keys(i).reduce((e,t)=>(i[t]!==void 0&&(e[t]=i[t]),e),{}),g3=i=>{let{props:{componentProps:{className:e}},restAttributes:t,widgetRef:n}=i;return wF(Ke(1,"div",e,null,1,I({},t),null,n))},m3={},Zl=(()=>{class i extends Si{get config(){return this.context[Kt.id]?this.context[Kt.id]:Kt.defaultValue}constructor(t){super(t),this.state={},this.widgetRef=at(),this.getInstance=this.getInstance.bind(this),this.setupWidget=this.setupWidget.bind(this),this.updateWidget=this.updateWidget.bind(this)}createEffects(){return[new Le(this.setupWidget,[]),new Le(this.updateWidget,[this.props.componentProps,this.config,this.props.templateNames])]}updateEffects(){var t;(t=this._effects[1])===null||t===void 0||t.update([this.props.componentProps,this.config,this.props.templateNames])}setupWidget(){let t=new this.props.componentType(this.widgetRef.current,this.properties);return this.instance=t,()=>{t.dispose(),this.instance=null}}updateWidget(){let t=this.getInstance();if(!t)return;let n=EF(this.prevProps||{},this.properties);n.length&&(t.beginUpdate(),n.forEach(o=>{let{path:s,value:r}=o;t.option(s,r)}),t.endUpdate()),this.prevProps=this.properties}get properties(){var t;let n=wF(this.props.componentProps),{valueChange:o}=n,s=ge(n,h3),r=I({rtlEnabled:!!((t=this.config)!==null&&t!==void 0&&t.rtlEnabled),isRenovated:!0},s);return o&&(r.onValueChanged=l=>{let{value:d}=l;return o(d)}),this.props.templateNames.forEach(l=>{$T(l,r,this)&&(r[l]=(d,c,h)=>{HT(this.props.componentProps[l],{item:d,index:c,container:h},this)})}),r}get restAttributes(){let t=this.props;return ge(t,p3)}getInstance(){return this.instance}render(){let t=this.props;return g3({props:I({},t),widgetRef:this.widgetRef,config:this.config,properties:this.properties,restAttributes:this.restAttributes})}}return i.defaultProps=m3,i})();var f3=["accessKey","activeStateEnabled","boundary","className","contentId","disabled","focusStateEnabled","height","hint","hoverStateEnabled","mode","offset","onClick","onKeyDown","positionSide","rtlEnabled","tabIndex","target","validationErrors","visible","visualContainer","width"],_3=i=>{let{componentProps:e,restAttributes:t}=i;return yt(Ee(2,Zl,I({componentType:Xp,componentProps:e,templateNames:[]},t)))},C3=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(Cr),Object.getOwnPropertyDescriptors({mode:"auto",positionSide:"top",offset:Object.freeze({h:0,v:0}),isReactComponentWrapper:!0}))),IF=(()=>{class i extends _t{constructor(t){super(t),this.state={}}get componentProps(){return this.props}get restAttributes(){let t=this.props;return ge(t,f3)}render(){let t=this.props;return _3({props:I({},t),componentProps:this.componentProps,restAttributes:this.restAttributes})}}return i.defaultProps=C3,i})();var x3=["accessKey","activeStateEnabled","aria","children","className","classes","defaultValue","disabled","focusStateEnabled","height","hint","hoverStateEnabled","inputAttr","isDirty","isValid","name","onClick","onFocusIn","onKeyDown","readOnly","rtlEnabled","tabIndex","validationError","validationErrors","validationMessageMode","validationMessagePosition","validationStatus","value","valueChange","visible","width"],v3=i=>{let{classes:e,isValid:t,readOnly:n}=i,o={"dx-state-readonly":!!n,"dx-invalid":!t,[String(e)]:!!e};return ti(o)},b3=i=>{let{aria:e,cssClasses:t,isValidationMessageVisible:n,onFocusIn:o,props:{accessKey:s,activeStateEnabled:r,children:a,className:l,disabled:d,focusStateEnabled:c,height:h,hint:p,hoverStateEnabled:g,onClick:C,onKeyDown:v,rtlEnabled:b,tabIndex:T,validationMessageMode:R,validationMessagePosition:U,visible:Q,width:se},restAttributes:re,rootElementRef:Re,validationErrors:we,validationMessageGuid:We,validationMessageTarget:gi,widgetRef:gt}=i;return yt(Ee(2,Il,I({rootElementRef:Re,aria:e,classes:t,activeStateEnabled:r,focusStateEnabled:c,hoverStateEnabled:g,accessKey:s,className:l,rtlEnabled:b,hint:p,disabled:d,height:h,width:se,onFocusIn:o,onClick:C,onKeyDown:v,tabIndex:T,visible:Q},re,{children:Zi([a,n&&Ee(2,IF,{validationErrors:we,mode:R,positionSide:U,rtlEnabled:b,target:gi,boundary:gi,visualContainer:gi,contentId:We})],0)}),null,gt))},St=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(Cr),Object.getOwnPropertyDescriptors({readOnly:!1,name:"",validationError:null,validationErrors:null,validationMessageMode:"auto",validationMessagePosition:"bottom",validationStatus:"valid",isValid:!0,isDirty:!1,inputAttr:Object.freeze({}),defaultValue:null,valueChange:()=>{}}))),y3={get readOnly(){return St.readOnly},get name(){return St.name},get validationError(){return St.validationError},get validationErrors(){return St.validationErrors},get validationMessageMode(){return St.validationMessageMode},get validationMessagePosition(){return St.validationMessagePosition},get validationStatus(){return St.validationStatus},get isValid(){return St.isValid},get isDirty(){return St.isDirty},get inputAttr(){return St.inputAttr},get defaultValue(){return St.defaultValue},get valueChange(){return St.valueChange},get className(){return St.className},get activeStateEnabled(){return St.activeStateEnabled},get disabled(){return St.disabled},get focusStateEnabled(){return St.focusStateEnabled},get hoverStateEnabled(){return St.hoverStateEnabled},get tabIndex(){return St.tabIndex},get visible(){return St.visible},get aria(){return wl.aria},get classes(){return wl.classes}},Jc=class extends Yn{constructor(e){super(e),this.widgetRef=at(),this.rootElementRef=at(),this.__getterCache={},this.state={validationMessageGuid:`dx-${new Oe}`,isValidationMessageVisible:!1,value:this.props.value!==void 0?this.props.value:this.props.defaultValue},this.updateValidationMessageVisibility=this.updateValidationMessageVisibility.bind(this),this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.onFocusIn=this.onFocusIn.bind(this)}createEffects(){return[new Le(this.updateValidationMessageVisibility,[this.props.isValid,this.props.validationStatus,this.props.validationError,this.props.validationErrors]),zo()]}updateEffects(){var e;(e=this._effects[0])===null||e===void 0||e.update([this.props.isValid,this.props.validationStatus,this.props.validationError,this.props.validationErrors])}updateValidationMessageVisibility(){this.setState(e=>({isValidationMessageVisible:this.shouldShowValidationMessage}))}onFocusIn(e){let{onFocusIn:t}=this.props;t?.(e)}get cssClasses(){return`${v3(I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value}))}`}get shouldShowValidationMessage(){let{isValid:e,validationStatus:t}=this.props,n=this.validationErrors??[];return!(e&&t!=="invalid")&&n.length>0}get aria(){let{isValid:e,readOnly:t}=this.props,n={readonly:t?"true":"false",invalid:e?"false":"true"};return this.shouldShowValidationMessage&&(n.describedBy=this.state.validationMessageGuid),I({},n,this.props.aria)}get validationErrors(){return this.__getterCache.validationErrors!==void 0?this.__getterCache.validationErrors:this.__getterCache.validationErrors=(()=>{let{validationError:e,validationErrors:t}=this.props,n=t&&[...t];return!n&&e&&(n=[I({},e)]),n})()}get validationMessageTarget(){var e;return(e=this.rootElementRef)===null||e===void 0?void 0:e.current}get restAttributes(){let e=I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value});return ge(e,x3)}focus(){this.widgetRef.current.focus()}blur(){this.widgetRef.current.blur()}componentWillUpdate(e,t,n){super.componentWillUpdate(),(this.props.validationError!==e.validationError||this.props.validationErrors!==e.validationErrors)&&(this.__getterCache.validationErrors=void 0)}render(){let e=this.props;return b3({props:I({},e,{value:this.props.value!==void 0?this.props.value:this.state.value}),validationMessageGuid:this.state.validationMessageGuid,isValidationMessageVisible:this.state.isValidationMessageVisible,rootElementRef:this.rootElementRef,widgetRef:this.widgetRef,onFocusIn:this.onFocusIn,cssClasses:this.cssClasses,shouldShowValidationMessage:this.shouldShowValidationMessage,aria:this.aria,validationErrors:this.validationErrors,validationMessageTarget:this.validationMessageTarget,restAttributes:this.restAttributes})}};Jc.defaultProps=y3;var O3=["size"],S3=i=>{let{cssStyles:e,elementRef:t}=i;return Ke(1,"span","dx-checkbox-icon",null,1,{style:yl(e)},null,t)},E3={},DF=(()=>{class i extends _t{constructor(t){super(t),this.state={},this.elementRef=at(),this.__getterCache={}}get cssStyles(){return this.__getterCache.cssStyles!==void 0?this.__getterCache.cssStyles:this.__getterCache.cssStyles=(()=>{let{size:t}=this.props;return{fontSize:ps("fontSize",t)}})()}get restAttributes(){let t=this.props;return ge(t,O3)}componentWillUpdate(t,n,o){this.props.size!==t.size&&(this.__getterCache.cssStyles=void 0)}render(){let t=this.props;return S3({props:I({},t),elementRef:this.elementRef,cssStyles:this.cssStyles,restAttributes:this.restAttributes})}}return i.defaultProps=E3,i})();var w3=["accessKey","activeStateEnabled","aria","className","defaultValue","disabled","enableThreeStateBehavior","focusStateEnabled","height","hint","hoverStateEnabled","iconSize","inputAttr","isDirty","isValid","name","onClick","onFocusIn","onKeyDown","readOnly","rtlEnabled","saveValueChangeEvent","tabIndex","text","validationError","validationErrors","validationMessageMode","validationMessagePosition","validationStatus","value","valueChange","visible","width"],I3=i=>{let{text:e,value:t}=i,n=t;return ti({"dx-checkbox":!0,"dx-checkbox-checked":n===!0,"dx-checkbox-has-text":!!e,"dx-checkbox-indeterminate":n===null})},D3=i=>{let{aria:e,cssClasses:t,editorRef:n,keyDown:o,onWidgetClick:s,props:{accessKey:r,activeStateEnabled:a,className:l,disabled:d,focusStateEnabled:c,height:h,hint:p,hoverStateEnabled:g,iconSize:C,isValid:v,name:b,onFocusIn:T,readOnly:R,rtlEnabled:U,tabIndex:Q,text:se,validationError:re,validationErrors:Re,validationMessageMode:we,validationMessagePosition:We,validationStatus:gi,value:gt,visible:oo,width:zr},restAttributes:bn}=i;return yt(Ee(2,Jc,I({aria:e,classes:t,onClick:s,onKeyDown:o,accessKey:r,activeStateEnabled:a,focusStateEnabled:c,hoverStateEnabled:g,className:l,disabled:d,readOnly:R,hint:p,height:h,width:zr,rtlEnabled:U,tabIndex:Q,visible:oo,validationError:re,validationErrors:Re,validationMessageMode:we,validationMessagePosition:We,validationStatus:gi,isValid:v,onFocusIn:T},bn,{children:Zi([yt(Ke(64,"input",null,null,1,I({type:"hidden",value:`${gt}`},b&&{name:b}))),Ke(1,"div","dx-checkbox-container",[Ee(2,DF,{size:C,isChecked:gt===!0}),se&&Ke(1,"span","dx-checkbox-text",se,0)],0)],4)}),null,n))},si=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(St),Object.getOwnPropertyDescriptors({text:"",enableThreeStateBehavior:!1,activeStateEnabled:!0,hoverStateEnabled:!0,get focusStateEnabled(){return F.real().deviceType==="desktop"&&!F.isSimulator()},defaultValue:!1,valueChange:()=>{}}))),T3={get text(){return si.text},get enableThreeStateBehavior(){return si.enableThreeStateBehavior},get activeStateEnabled(){return si.activeStateEnabled},get hoverStateEnabled(){return si.hoverStateEnabled},get focusStateEnabled(){return si.focusStateEnabled},get defaultValue(){return si.defaultValue},get valueChange(){return si.valueChange},get readOnly(){return si.readOnly},get name(){return si.name},get validationError(){return si.validationError},get validationErrors(){return si.validationErrors},get validationMessageMode(){return si.validationMessageMode},get validationMessagePosition(){return si.validationMessagePosition},get validationStatus(){return si.validationStatus},get isValid(){return si.isValid},get isDirty(){return si.isDirty},get inputAttr(){return si.inputAttr},get className(){return si.className},get disabled(){return si.disabled},get tabIndex(){return si.tabIndex},get visible(){return si.visible},get aria(){return wl.aria}},va=class extends Yn{constructor(e){super(e),this.editorRef=at(),this.state={value:this.props.value!==void 0?this.props.value:this.props.defaultValue},this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.onWidgetClick=this.onWidgetClick.bind(this),this.keyDown=this.keyDown.bind(this)}createEffects(){return[zo()]}onWidgetClick(e){let{enableThreeStateBehavior:t,readOnly:n,saveValueChangeEvent:o}=this.props;if(!n)if(o?.(e),t){let s;this.setState(r=>(s=(this.props.value!==void 0?this.props.value:r.value)===null||((this.props.value!==void 0?this.props.value:r.value)?!1:null),{value:s})),this.props.valueChange(s)}else{let s;this.setState(r=>(s=!((this.props.value!==void 0?this.props.value:r.value)??!1),{value:s})),this.props.valueChange(s)}}keyDown(e){let{onKeyDown:t}=this.props,{keyName:n,originalEvent:o,which:s}=e,r=t?.(e);if(r!=null&&r.cancel)return r;(n==="space"||s==="space")&&(o.preventDefault(),this.onWidgetClick(o))}get cssClasses(){return I3(I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value}))}get aria(){let e=(this.props.value!==void 0?this.props.value:this.state.value)===!0,n={role:"checkbox",checked:(this.props.value!==void 0?this.props.value:this.state.value)===null?"mixed":`${e}`};return I({},n,this.props.aria)}get restAttributes(){let e=I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value});return ge(e,w3)}focus(){this.editorRef.current.focus()}blur(){this.editorRef.current.blur()}render(){let e=this.props;return D3({props:I({},e,{value:this.props.value!==void 0?this.props.value:this.state.value}),editorRef:this.editorRef,onWidgetClick:this.onWidgetClick,keyDown:this.keyDown,cssClasses:this.cssClasses,aria:this.aria,restAttributes:this.restAttributes})}};function A3(i){let e=["value"];return Object.keys(i).reduce((t,n)=>{let o=i[n],s=e.some(r=>r===n)?"default"+n.charAt(0).toUpperCase()+n.slice(1):n;return t[s]=o,t},{})}va.defaultProps=T3;var TF=[];function AF(i){TF.push(i),va.defaultProps=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(va.defaultProps),Object.getOwnPropertyDescriptors(A3(go(TF)))))}var Jl=class extends Tg{getProps(){let e=super.getProps();return e.onKeyDown=this._wrapKeyDownHandler(e.onKeyDown),e}focus(){var e;return(e=this.viewRef)===null||e===void 0?void 0:e.focus(...arguments)}blur(){var e;return(e=this.viewRef)===null||e===void 0?void 0:e.blur(...arguments)}_getActionConfigs(){return{onFocusIn:{},onClick:{}}}get _propsInfo(){return{twoWay:[["value","defaultValue","valueChange"]],allowNull:["defaultValue","validationError","validationErrors","value"],elements:[],templates:[],props:["text","iconSize","enableThreeStateBehavior","activeStateEnabled","hoverStateEnabled","focusStateEnabled","saveValueChangeEvent","defaultValue","valueChange","readOnly","name","validationError","validationErrors","validationMessageMode","validationMessagePosition","validationStatus","isValid","isDirty","inputAttr","onFocusIn","className","accessKey","disabled","height","hint","onClick","onKeyDown","rtlEnabled","tabIndex","visible","width","aria","value"]}}get _viewComponent(){return va}};G("dxCheckBox",Jl);Jl.defaultOptions=AF;var Er=Jl;var MF=K();var Qo="dxDraggable",M3=D(Ds,Qo),R3=D(vo,Qo),F3=D(Ts,Qo),P3=D(Ac,Qo),k3=D(Mc,Qo),B3=D(ne.down,Qo),V3=D("keydown",Qo);var Cb,Ag;var xb=i=>({x:i.pageX-u(MF).scrollLeft(),y:i.pageY-u(MF).scrollTop()});var Mg=class{constructor(e,t){this._$scrollableAtPointer=null,this._preventScroll=!0,this._component=t,e==="vertical"?(this._scrollValue="scrollTop",this._overFlowAttr="overflowY",this._sizeAttr="height",this._scrollSizeProp="scrollHeight",this._clientSizeProp="clientHeight",this._limitProps={start:"top",end:"bottom"}):(this._scrollValue="scrollLeft",this._overFlowAttr="overflowX",this._sizeAttr="width",this._scrollSizeProp="scrollWidth",this._clientSizeProp="clientWidth",this._limitProps={start:"left",end:"right"})}updateScrollable(e,t){let n=!1;e.some(o=>{let s=u(o),r=s.hasClass("dx-overlay-wrapper"),a=s.hasClass("dx-overlay-content");return r||a?!0:(n=this._trySetScrollable(o,t),n)}),n||(this._$scrollableAtPointer=null,this._scrollSpeed=0)}isScrolling(){return!!this._scrollSpeed}isScrollable(e){return(e.css(this._overFlowAttr)==="auto"||e.hasClass("dx-scrollable-container"))&&e.prop(this._scrollSizeProp)>Math.ceil(this._sizeAttr==="width"?z(e):Y(e))}_trySetScrollable(e,t){let n=this,o=u(e),s,r=n._component.option("scrollSensitivity"),a=n.isScrollable(o);return a&&(s=n._calculateDistanceToBorders(o,t),r>s[n._limitProps.start]?n._preventScroll||(n._scrollSpeed=-n._calculateScrollSpeed(s[n._limitProps.start]),n._$scrollableAtPointer=o):r>s[n._limitProps.end]?n._preventScroll||(n._scrollSpeed=n._calculateScrollSpeed(s[n._limitProps.end]),n._$scrollableAtPointer=o):(a=!1,n._preventScroll=!1)),a}_calculateDistanceToBorders(e,t){let n=e.get(0),o;return n?(o=Ie(n),{left:t.x-o.left,top:t.y-o.top,right:o.right-t.x,bottom:o.bottom-t.y}):{}}_calculateScrollSpeed(e){let t=this._component,n=t.option("scrollSensitivity"),o=t.option("scrollSpeed");return Math.ceil(((n-e)/n)**2*o)}scrollByStep(){let e=this;if(e._$scrollableAtPointer&&e._scrollSpeed){if(e._$scrollableAtPointer.hasClass("dx-scrollable-container")){let n=e._$scrollableAtPointer.closest(".dx-scrollable"),o=n.data("dxScrollable")||n.data("dxScrollView");if(o){let s=o.scrollOffset()[e._limitProps.start]+e._scrollSpeed;o.scrollTo({[e._limitProps.start]:s})}}else{let n=e._$scrollableAtPointer[e._scrollValue]()+e._scrollSpeed;e._$scrollableAtPointer[e._scrollValue](n)}let t=e._component._dragMoveArgs;t&&e._component._dragMoveHandler(t)}}reset(){this._$scrollableAtPointer=null,this._scrollSpeed=0,this._preventScroll=!0}isOutsideScrollable(e,t){if(!e)return!1;let n=Ie(e.get(0)),o=n[this._limitProps.start],s=n[this._sizeAttr],r=xb(t),a=this._sizeAttr==="width"?r.x:r.y;return a<o||a>o+s}},L3=Np.inherit({ctor(i){this.callBase(),this._strategy=i},_step(){let i=this._strategy._horizontalScrollHelper,e=this._strategy._verticalScrollHelper;i&&i.scrollByStep(),e&&e.scrollByStep()}}),RF=Qi.inherit({reset:S,dragMove:S,dragEnter:S,dragLeave:S,dragEnd(i){return this._getSourceDraggable()._fireRemoveEvent(i),y().resolve()},_fireRemoveEvent:S,_getDefaultOptions(){return m(this.callBase(),{onDragStart:null,onDragMove:null,onDragEnd:null,onDragEnter:null,onDragLeave:null,onDragCancel:null,onCancelByEsc:!1,onDrop:null,immediate:!0,dragDirection:"both",boundary:void 0,boundOffset:0,allowMoveByClick:!1,itemData:null,container:void 0,dragTemplate:void 0,contentTemplate:"content",handle:"",filter:"",clone:!1,autoScroll:!0,scrollSpeed:30,scrollSensitivity:60,group:void 0,data:void 0})},_setOptionsByReference(){this.callBase.apply(this,arguments),m(this._optionsByReference,{component:!0,group:!0,itemData:!0,data:!0})},_init(){this.callBase(),this._attachEventHandlers(),this._scrollAnimator=new L3(this),this._horizontalScrollHelper=new Mg("horizontal",this),this._verticalScrollHelper=new Mg("vertical",this),this._initScrollTop=0,this._initScrollLeft=0},_normalizeCursorOffset(i){return $(i)&&(i={h:i.x,v:i.y}),i=Mo(i).map(e=>parseFloat(e)),{left:i[0],top:i.length===1?i[0]:i[1]}},_getNormalizedCursorOffset(i,e){return A(i)&&(i=i.call(this,e)),this._normalizeCursorOffset(i)},_calculateElementOffset(i){let e,t,{event:n}=i,o=u(i.itemElement),s=u(i.dragElement),r=this._dragElementIsCloned(),a=this.option("cursorOffset"),l={left:0,top:0},d=this._initialLocate=li(s);return(r||i.initialOffset||a)&&(e=i.initialOffset||o.offset(),a&&(l=this._getNormalizedCursorOffset(a,i),isFinite(l.left)&&(e.left=n.pageX),isFinite(l.top)&&(e.top=n.pageY)),t=s.offset(),e.top-=t.top+(l.top||0)-d.top,e.left-=t.left+(l.left||0)-d.left),e},_initPosition(i){let e=u(i.dragElement),t=this._calculateElementOffset(i);t&&this._move(t,e),this._startPosition=li(e)},_startAnimator(){this._scrollAnimator.inProgress()||this._scrollAnimator.start()},_stopAnimator(){this._scrollAnimator.stop()},_addWidgetPrefix(i){let e=this.NAME;return Hd(e)+(i?`-${i}`:"")},_getItemsSelector(){return this.option("filter")||""},_$content(){let i=this.$element(),e=i.children(".dx-template-wrapper");return e.length?e:i},_attachEventHandlers(){if(this.option("disabled"))return;let i=this._$content(),e=this._getItemsSelector(),t=this.option("allowMoveByClick"),n={direction:this.option("dragDirection"),immediate:this.option("immediate"),checkDropTarget:(o,s)=>{let r=this.option("group"),a=this._getSourceDraggable().option("group"),l=this._getScrollable(o);return this._verticalScrollHelper.isOutsideScrollable(l,s)||this._horizontalScrollHelper.isOutsideScrollable(l,s)?!1:a&&a===r}};t&&(i=this._getArea(),_.on(i,B3,n,this._pointerDownHandler.bind(this))),e[0]===">"&&(e=e.slice(1)),_.on(i,M3,e,n,this._dragStartHandler.bind(this)),_.on(i,R3,n,this._dragMoveHandler.bind(this)),_.on(i,F3,n,this._dragEndHandler.bind(this)),_.on(i,P3,n,this._dragEnterHandler.bind(this)),_.on(i,k3,n,this._dragLeaveHandler.bind(this)),this.option("onCancelByEsc")&&_.on(i,V3,this._keydownHandler.bind(this))},_dragElementIsCloned(){return this._$dragElement&&this._$dragElement.hasClass(this._addWidgetPrefix("clone"))},_getDragTemplateArgs(i,e){return{container:N(e),model:{itemData:this.option("itemData"),itemElement:N(i)}}},_createDragElement(i){let e=i,t=this.option("clone"),n=this._getContainer(),o=this.option("dragTemplate");return o?(o=this._getTemplate(o),e=u("<div>").appendTo(n),o.render(this._getDragTemplateArgs(i,e))):t&&(e=u("<div>").appendTo(n),i.clone().css({width:i.css("width"),height:i.css("height")}).appendTo(e)),e.toggleClass(this._addWidgetPrefix("clone"),e.get(0)!==i.get(0)).toggleClass("dx-rtl",this.option("rtlEnabled"))},_resetDragElement(){this._dragElementIsCloned()?this._$dragElement.remove():this._toggleDraggingClass(!1),this._$dragElement=null},_resetSourceElement(){this._toggleDragSourceClass(!1),this._$sourceElement=null},_detachEventHandlers(){_.off(this._$content(),`.${Qo}`),_.off(this._getArea(),`.${Qo}`)},_move(i,e){Ae(e||this._$dragElement,i)},_getDraggableElement(i){let e=this._getSourceElement();if(e)return e;if(this.option("allowMoveByClick"))return this.$element();let n=u(i&&i.target),o=this._getItemsSelector();if(o[0]===">"){let s=this._$content().find(o);s.is(n)||(n=n.closest(s))}return n},_getSourceElement(){return this._getSourceDraggable()._$sourceElement},_pointerDownHandler(i){if(Eh(i))return;let e={},t=this.$element(),n=this.option("dragDirection");(n==="horizontal"||n==="both")&&(e.left=i.pageX-t.offset().left+li(t).left-z(t)/2),(n==="vertical"||n==="both")&&(e.top=i.pageY-t.offset().top+li(t).top-Y(t)/2),this._move(e,t),this._getAction("onDragMove")(this._getEventArgs(i))},_isValidElement(i,e){let t=this.option("handle"),n=u(i.originalEvent&&i.originalEvent.target);return t&&!n.closest(t).length||!e.length?!1:!e.is(".dx-state-disabled, .dx-state-disabled *")},_dragStartHandler(i){let e=this._getDraggableElement(i);if(this.dragInProgress=!0,!this._isValidElement(i,e)){i.cancel=!0;return}if(this._$sourceElement)return;let t=this._getDragStartArgs(i,e);if(this._getAction("onDragStart")(t),t.cancel){i.cancel=!0;return}this.option("itemData",t.itemData),this._setSourceDraggable(),this._$sourceElement=e;let n=e.offset();!this._hasClonedDraggable()&&this.option("autoScroll")&&(this._initScrollTop=this._getScrollableScrollTop(),this._initScrollLeft=this._getScrollableScrollLeft(),n=this._getDraggableElementOffset(n.left,n.top));let o=this._$dragElement=this._createDragElement(e);this._toggleDraggingClass(!0),this._toggleDragSourceClass(!0),this._setGestureCoverCursor(o.children());let s=o.css("position")==="fixed";this._initPosition(m({},t,{dragElement:o.get(0),initialOffset:s&&n})),this._getAction("onDraggableElementShown")(I({},t,{dragElement:o}));let r=this._getArea(),a=this._getAreaOffset(r),l=this._getBoundOffset(),d=ie(r),c=X(r),h=z(o),p=Y(o),g=o.offset().left-a.left,C=o.offset().top-a.top;r.length&&(i.maxLeftOffset=g-l.left,i.maxRightOffset=d-g-h-l.right,i.maxTopOffset=C-l.top,i.maxBottomOffset=c-C-p-l.bottom),this.option("autoScroll")&&this._startAnimator()},_getAreaOffset(i){return i&&lt.offset(i)||{left:0,top:0}},_toggleDraggingClass(i){this._$dragElement&&this._$dragElement.toggleClass(this._addWidgetPrefix("dragging"),i)},_toggleDragSourceClass(i,e){let t=e||this._$sourceElement;t&&t.toggleClass(this._addWidgetPrefix("source"),i)},_setGestureCoverCursor(i){u(".dx-gesture-cover").css("cursor",i.css("cursor"))},_getBoundOffset(){let i=this.option("boundOffset");return A(i)&&(i=i.call(this)),DE(i)},_getArea(){let i=this.option("boundary");return A(i)&&(i=i.call(this)),u(i)},_getContainer(){let i=this.option("container");return i===void 0&&(i=Sn()),u(i)},_getDraggableElementOffset(i,e){var t,n;let o=this._initScrollTop,s=this._initScrollLeft,r=this._getScrollableScrollTop(),a=this._getScrollableScrollLeft(),d=u(this.element()).css("position")==="fixed",c={left:(((t=this._startPosition)===null||t===void 0?void 0:t.left)??0)+i,top:(((n=this._startPosition)===null||n===void 0?void 0:n.top)??0)+e};return d||this._hasClonedDraggable()?c:{left:xe(a)?c.left+a-s:c.left,top:xe(r)?c.top+r-o:c.top}},_hasClonedDraggable(){return this.option("clone")||this.option("dragTemplate")},_dragMoveHandler(i){if(this._dragMoveArgs=i,!this._$dragElement){i.cancel=!0;return}let e=this._getDraggableElementOffset(i.offset.x,i.offset.y);this._move(e),this._updateScrollable(i);let t=this._getEventArgs(i);if(this._getAction("onDragMove")(t),t.cancel===!0)return;this._getTargetDraggable().dragMove(i,scrollBy)},_updateScrollable(i){let e=this;if(e.option("autoScroll")){let t=xb(i),n=w.elementsFromPoint(t.x,t.y,this.$element().get(0));e._verticalScrollHelper.updateScrollable(n,t),e._horizontalScrollHelper.updateScrollable(n,t)}},_getScrollable(i){let e;return i.parents().toArray().some(t=>{let n=u(t);return this._horizontalScrollHelper.isScrollable(n)||this._verticalScrollHelper.isScrollable(n)?(e=n,!0):!1}),e},_getScrollableScrollTop(){var i;return((i=this._getScrollable(u(this.element())))===null||i===void 0?void 0:i.scrollTop())??0},_getScrollableScrollLeft(){var i;return((i=this._getScrollable(u(this.element())))===null||i===void 0?void 0:i.scrollLeft())??0},_defaultActionArgs(){let i=this.callBase.apply(this,arguments),e=this.option("component");return e&&(i.component=e,i.element=e.element()),i},_getEventArgs(i){let e=this._getSourceDraggable(),t=this._getTargetDraggable();return{event:i,itemData:e.option("itemData"),itemElement:N(e._$sourceElement),fromComponent:e.option("component")||e,toComponent:t.option("component")||t,fromData:e.option("data"),toData:t.option("data")}},_getDragStartArgs(i,e){let t=this._getEventArgs(i);return{event:t.event,itemData:t.itemData,itemElement:e,fromData:t.fromData}},_revertItemToInitialPosition(){!this._dragElementIsCloned()&&this._move(this._initialLocate,this._$sourceElement)},_dragEndHandler(i){let e=y(),t=this._getEventArgs(i),n=this._getEventArgs(i),o=this._getTargetDraggable(),s=!0;this.dragInProgress=!1;try{this._getAction("onDragEnd")(t)}finally{P(ht(t.cancel)).done(r=>{if(!r&&(o!==this&&o._getAction("onDrop")(n),!n.cancel)){s=!1,P(ht(o.dragEnd(t))).always(e.resolve);return}e.resolve()}).fail(e.resolve),e.done(()=>{s&&this._revertItemToInitialPosition(),this._resetDragOptions(o)})}},_isTargetOverAnotherDraggable(i){let e=this._getSourceDraggable();if(this===e)return!1;let t=e._$dragElement,n=e.$element(),o=this.$element(),s=xb(i),a=w.elementsFromPoint(s.x,s.y,this.element()).filter(h=>{let p=u(h);return p.hasClass(this._addWidgetPrefix())?!p.closest(t).length:!1})[0],l=this._getSourceElement(),d=a===n.get(0),c=u(a).closest(l).length;return!a||a===o.get(0)&&!d&&!c},_dragEnterHandler(i){this._fireDragEnterEvent(i),this._isTargetOverAnotherDraggable(i)&&this._setTargetDraggable(),this._getSourceDraggable().dragEnter(i)},_dragLeaveHandler(i){this._fireDragLeaveEvent(i),this._resetTargetDraggable(),this!==this._getSourceDraggable()&&this.reset(),this._getSourceDraggable().dragLeave(i)},_keydownHandler(i){this.dragInProgress&&i.key==="Escape"&&this._keydownEscapeHandler(i)},_keydownEscapeHandler(i){var e;if(!this._getSourceElement())return;let n=this._getEventArgs(i);if(this._getAction("onDragCancel")(n),n.cancel)return;this.dragInProgress=!1,(e=Ag)===null||e===void 0||e._toggleDraggingClass(!1),this._detachEventHandlers(),this._revertItemToInitialPosition();let o=this._getTargetDraggable();this._resetDragOptions(o),this._attachEventHandlers()},_getAction(i){return this[`_${i}Action`]||this._createActionByOption(i)},_getAnonymousTemplateName:()=>"content",_initTemplates(){this.option("contentTemplate")&&(this._templateManager.addDefaultTemplates({content:new Vi}),this.callBase.apply(this,arguments))},_render(){this.callBase(),this.$element().addClass(this._addWidgetPrefix());let i=this._templateManager.anonymousTemplateName===this.option("contentTemplate"),e=this._getTemplateByOption("contentTemplate");e&&u(e.render({container:this.element(),transclude:i}))},_optionChanged(i){let{name:e}=i;switch(e){case"onDragStart":case"onDragMove":case"onDragEnd":case"onDrop":case"onDragEnter":case"onDragLeave":case"onDragCancel":case"onDraggableElementShown":this[`_${e}Action`]=this._createActionByOption(e);break;case"dragTemplate":case"contentTemplate":case"container":case"clone":case"scrollSensitivity":case"scrollSpeed":case"boundOffset":case"handle":case"group":case"data":case"itemData":break;case"allowMoveByClick":case"dragDirection":case"disabled":case"boundary":case"filter":case"immediate":this._resetDragElement(),this._detachEventHandlers(),this._attachEventHandlers();break;case"onCancelByEsc":this._keydownHandler();break;case"autoScroll":this._verticalScrollHelper.reset(),this._horizontalScrollHelper.reset();break;default:this.callBase(i)}},_getTargetDraggable(){return Cb||this},_getSourceDraggable(){return Ag||this},_setTargetDraggable(){let i=this.option("group"),e=this._getSourceDraggable();i&&i===e.option("group")&&(Cb=this)},_setSourceDraggable(){Ag=this},_resetSourceDraggable(){Ag=null},_resetTargetDraggable(){Cb=null},_resetDragOptions(i){this.reset(),i.reset(),this._stopAnimator(),this._horizontalScrollHelper.reset(),this._verticalScrollHelper.reset(),this._resetDragElement(),this._resetSourceElement(),this._resetTargetDraggable(),this._resetSourceDraggable()},_dispose(){this.callBase(),this._detachEventHandlers(),this._resetDragElement(),this._resetTargetDraggable(),this._resetSourceDraggable(),this._$sourceElement=null,this._stopAnimator()},_fireDragEnterEvent(i){let e=this._getEventArgs(i);this._getAction("onDragEnter")(e)},_fireDragLeaveEvent(i){let e=this._getEventArgs(i);this._getAction("onDragLeave")(e)}});G(Qo,RF);var FF=RF;var Hs="dxdblclick";var PF=D(oe,"dxDblClick");var N3=ce.inherit({ctor(){this._handlerCount=0,this._forgetLastClick()},_forgetLastClick(){this._firstClickTarget=null,this._lastClickTimeStamp=-300},add(){this._handlerCount<=0&&_.on(w.getDocument(),PF,this._clickHandler.bind(this)),this._handlerCount+=1},_clickHandler(i){let e=i.timeStamp||Date.now(),t=e-this._lastClickTimeStamp;!(t<0)&&t<300?(ji({type:"dxdblclick",target:E0(this._firstClickTarget,i.target),originalEvent:i}),this._forgetLastClick()):(this._firstClickTarget=i.target,this._lastClickTimeStamp=e,clearTimeout(this._lastClickClearTimeout),this._lastClickClearTimeout=setTimeout(()=>{this._forgetLastClick()},600))},remove(){this._handlerCount-=1,this._handlerCount<=0&&(this._forgetLastClick(),_.off(w.getDocument(),PF,void 0),clearTimeout(this._lastClickClearTimeout),this._handlerCount=0)}}),kF=new N3;vi(Hs,kF);var BF=og;var H3="dx-numberbox-spin",$3="dx-numberbox-spin-button";var NF="dxNumberBox",VF=D(ne.up,NF),LF=D(ne.cancel,NF),z3=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{direction:"up",onChange:null,activeStateEnabled:!0,hoverStateEnabled:!0})},_initMarkup(){this.callBase();let i=`${H3}-${this.option("direction")}`;this.$element().addClass($3).addClass(i),this._spinIcon=u("<div>").addClass(`${i}-icon`).appendTo(this.$element())},_render(){this.callBase();let i=D(ne.down,this.NAME),e=this.$element();_.off(e,i),_.on(e,i,this._spinDownHandler.bind(this)),this._spinChangeHandler=this._createActionByOption("onChange")},_spinDownHandler(i){i.preventDefault(),this._clearTimer(),_.on(this.$element(),an.name,()=>{this._feedBackDeferred=y(),ip(this._feedBackDeferred),this._spinChangeHandler({event:i}),this._holdTimer=setInterval(this._spinChangeHandler,100,{event:i})});let e=w.getDocument();_.on(e,VF,this._clearTimer.bind(this)),_.on(e,LF,this._clearTimer.bind(this)),this._spinChangeHandler({event:i})},_dispose(){this._clearTimer(),this.callBase()},_clearTimer(){_.off(this.$element(),an.name);let i=w.getDocument();_.off(i,VF),_.off(i,LF),this._feedBackDeferred&&this._feedBackDeferred.resolve(),this._holdTimer&&clearInterval(this._holdTimer)},_optionChanged(i){switch(i.name){case"onChange":case"direction":this._invalidate();break;default:this.callBase(i)}}}),ba=z3;var W3="dx-numberbox-spin",G3="dx-numberbox-spin-container",K3="dx-numberbox-spin-touch-friendly",Rg=class extends qo{_attachEvents(e,t){let{editor:n}=this,o=D(ne.down,n.NAME),s=t.children(),r=n._createAction(a=>n._spinButtonsPointerDownHandler(a));_.off(t,o),_.on(t,o,a=>r({event:a})),ba.getInstance(s.eq(0)).option("onChange",a=>n._spinUpChangeHandler(a)),ba.getInstance(s.eq(1)).option("onChange",a=>n._spinDownChangeHandler(a))}_create(){let{editor:e}=this,t=u("<div>").addClass(G3),n=u("<div>").appendTo(t),o=u("<div>").appendTo(t),s=this._getOptions();return this._addToContainer(t),e._createComponent(n,ba,m({direction:"up"},s)),e._createComponent(o,ba,m({direction:"down"},s)),this._legacyRender(e.$element(),this._isTouchFriendly(),s.visible),{instance:t,$element:t}}_getOptions(){let{editor:e}=this,t=this._isVisible(),n=e.option("disabled");return{visible:t,disabled:n}}_isVisible(){let{editor:e}=this;return super._isVisible()&&e.option("showSpinButtons")}_isTouchFriendly(){let{editor:e}=this;return e.option("showSpinButtons")&&e.option("useLargeSpinButtons")}_legacyRender(e,t,n){e.toggleClass(K3,t),e.toggleClass(W3,n)}update(){if(super.update()){let{editor:t,instance:n}=this,o=t.$element(),s=this._isVisible(),r=this._isTouchFriendly(),a=n.children(),l=ba.getInstance(a.eq(0)),d=ba.getInstance(a.eq(1)),c=this._getOptions();l.option(c),d.option(c),this._legacyRender(o,r,s)}}};var U3=Math,j3="dx-numberbox",q3=["tab","del","backspace","leftArrow","rightArrow","home","end","enter"];var Y3=BF.inherit({_supportedKeys(){return m(this.callBase(),{upArrow(i){ot(i)||(i.preventDefault(),i.stopPropagation(),this._spinUpChangeHandler(i))},downArrow(i){ot(i)||(i.preventDefault(),i.stopPropagation(),this._spinDownChangeHandler(i))},enter(){}})},_getDefaultOptions(){return m(this.callBase(),{value:0,min:void 0,max:void 0,step:1,showSpinButtons:!1,useLargeSpinButtons:!0,mode:"text",invalidValueMessage:O.format("dxNumberBox-invalidValueMessage"),buttons:void 0})},_useTemplates:()=>!1,_getDefaultButtons(){return this.callBase().concat([{name:"spins",Ctor:Rg}])},_isSupportInputMode(){let i=parseFloat(be.version);return be.chrome&&i>=66||be.safari&&i>=12},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().generic&&!F.isSimulator(),options:{useLargeSpinButtons:!1}},{device:function(){return F.real().deviceType!=="desktop"&&!this._isSupportInputMode()}.bind(this),options:{mode:"number"}}])},_initMarkup(){this._renderSubmitElement(),this.$element().addClass(j3),this.callBase()},_getDefaultAttributes(){let i=this.callBase();return i.inputmode="decimal",i},_renderContentImpl(){this.option("isValid")&&this._validateValue(this.option("value")),this.setAria("role","spinbutton")},_renderSubmitElement(){this._$submitElement=u("<input>").attr("type","hidden").appendTo(this.$element()),this._setSubmitValue(this.option("value"))},_setSubmitValue(i){this._getSubmitElement().val(HE(i))},_getSubmitElement(){return this._$submitElement},_keyPressHandler(i){this.callBase(i);let e=Xd(i);if(!/[\d.,eE\-+]/.test(e)){let n=De(i);return ot(i)||n&&q3.includes(n)?void 0:(i.preventDefault(),!1)}this._keyPressed=!0},_onMouseWheel(i){i.delta>0?this._spinValueChange(1,i):this._spinValueChange(-1,i)},_renderValue(){let i=this._input().val(),e=this.option("value");(!i.length||Number(i)!==e)&&(this._forceValueRender(),this._toggleEmptinessEventHandler());let t=f(e)?null:O.format("dxNumberBox-noDataText");return this.setAria({valuenow:Te(e,""),valuetext:t}),this.option("text",this._input().val()),this._updateButtons(),y().resolve()},_forceValueRender(){let i=this.option("value"),e=Number(i),t=isNaN(e)?"":this._applyDisplayValueFormatter(i);this._renderDisplayText(t)},_applyDisplayValueFormatter(i){return this.option("displayValueFormatter")(i)},_renderProps(){this._input().prop({min:this.option("min"),max:this.option("max"),step:this.option("step")}),this.setAria({valuemin:Te(this.option("min"),""),valuemax:Te(this.option("max"),"")})},_spinButtonsPointerDownHandler(){let i=this._input();!this.option("useLargeSpinButtons")&&w.getActiveElement()!==i[0]&&_.trigger(i,"focus")},_spinUpChangeHandler(i){this.option("readOnly")||this._spinValueChange(1,i.event||i)},_spinDownChangeHandler(i){this.option("readOnly")||this._spinValueChange(-1,i.event||i)},_spinValueChange(i,e){let t=parseFloat(this.option("step"));if(t===0)return;let n=parseFloat(this._normalizeInputValue())||0;n=this._correctRounding(n,t*i);let o=this.option("min"),s=this.option("max");f(o)&&(n=Math.max(o,n)),f(s)&&(n=Math.min(s,n)),this._saveValueChangeEvent(e),this.option("value",n)},_correctRounding(i,e){let t=/[,.](.*)/,n=t.test(i),o=t.test(e);if(n||o){let s=n?t.exec(i)[0].length:0,r=o?t.exec(e)[0].length:0,a=U3.max(s,r);return i=this._round(i+e,a),i}return i+e},_round(i,e){e=e||0;let t=10**e;return i*=t,i=Math.round(i)/t,i},_renderValueChangeEvent(){this.callBase();let i=D("focusout","NumberBoxForceValueChange");_.off(this.element(),i),_.on(this.element(),i,this._forceRefreshInputValue.bind(this))},_forceRefreshInputValue(){if(this.option("mode")==="number")return;let i=this._input(),e=this._applyDisplayValueFormatter(this.option("value"));i.val(null),i.val(e)},_valueChangeEventHandler(i){let e=this._input(),t=this._normalizeText(),n=this._parseValue(t),o=t!=="."&&t!=="-";if(this._isValueValid()&&!this._validateValue(n)){e.val(this._applyDisplayValueFormatter(n));return}o&&this.callBase(i,isNaN(n)?null:n),this._applyValueBoundaries(t,n),this.validationRequest.fire({value:n,editor:this})},_applyValueBoundaries(i,e){let t=this._isValueIncomplete(i),n=this._isValueInRange(i);!t&&!n&&e!==null&&Number(i)!==e&&this._input().val(this._applyDisplayValueFormatter(e))},_replaceCommaWithPoint:i=>i.replace(",","."),_inputIsInvalid(){let i=this.option("mode")==="number",e=this._input().get(0).validity;return i&&e&&e.badInput},_renderDisplayText(i){this._inputIsInvalid()||this.callBase(i)},_isValueIncomplete:i=>/(^-$)|(^-?\d*\.$)|(\d+e-?$)/i.test(i),_isValueInRange(i){return fn(i,this.option("min"),this.option("max"))},_isNumber(i){return this._parseValue(i)!==null},_validateValue(i){let e=this._normalizeText(),t=this._isValueValid(),n=!0,o=this._isNumber(e);return isNaN(Number(i))&&(n=!1),!i&&t?n=!0:!o&&!t&&(n=!1),this.option({isValid:n,validationError:n?null:{editorSpecific:!0,message:this.option("invalidValueMessage")}}),n},_normalizeInputValue(){return this._parseValue(this._normalizeText())},_normalizeText(){let i=this._input().val().trim();return this._replaceCommaWithPoint(i)},_parseValue(i){let e=parseFloat(i);return isNaN(e)?null:ft(e,this.option("min"),this.option("max"))},_clearValue(){this._inputIsInvalid()&&(this._input().val(""),this._validateValue()),this.callBase()},clear(){this.option("value")===null?(this.option("text",""),this._input().length&&this._renderValue()):this.option("value",null)},_optionChanged(i){switch(i.name){case"value":this._validateValue(i.value),this._setSubmitValue(i.value),this.callBase(i),this._resumeValueChangeAction();break;case"step":this._renderProps();break;case"min":case"max":this._renderProps(),this.option("value",this._parseValue(this.option("value")));break;case"showSpinButtons":case"useLargeSpinButtons":this._updateButtons(["spins"]);break;case"invalidValueMessage":break;default:this.callBase(i)}}}),HF=Y3;var ed=function(i){let e=0,t=0;for(let n=0;n<i.length;++n)if(i[n]==="'"&&e++,i[n]==="."&&(++t,e%2===0))return{occurrence:t,index:n};return{occurrence:1,index:-1}},eu=function(i,e,t){let n=-1;for(;t--&&n++<i.length;)n=i.indexOf(e,n);return n},tu=function(i,e){return e===-1?[i]:[i.slice(0,e),i.slice(e+1)]},$F=function(i,e){return i&&pc(i/100,e)};var iu=function(i,e){if(typeof e=="string"){let t=e.split(";"),n=ze.getSign(i,e);t[1]=t[1]||`-${t[0]}`,e=t[n<0?1:0],e=(a=>a.replace(/'([^']*)'/g,l=>l.split("").map(()=>" ").join("").substr(2)))(e);let s=/^[^#0.,]*/.exec(e)[0].length,r=/[^#0.,]*$/.exec(e)[0].length;return{start:s,end:i.length-r}}return{start:0,end:i.length}},zF=function(i,e){let t=ze.getDecimalSeparator(),n=new RegExp(`[^0-9${Pn(t)}]`,"g");return e.slice(0,i).replace(n,"").length},WF=function(i){return i.split("").reverse().join("")},GF=function(i,e){if(!i)return-1;let t=/[0-9]/g,n=1,o=null,s=t.exec(e);for(;s;){if(o=s.index,n>=i)return o;n++,s=t.exec(e)}return o===null?e.length:o},X3=function(i){return i.replace(/[^0-9e]+$/,"")},wr=function(i,e){return i.start===void 0&&(i={start:i,end:i}),{start:i.start+e,end:i.end+e}},KF=function(i,e,t,n){t=wr(t,0);let o=ze.getDecimalSeparator(),s=Q3(i),r=ed(n).occurrence,a=s?0:eu(i,o,r),l=eu(e,o,r),d=tu(i,a),c=tu(e,l);if(a!==-1&&t.start>a){let T=t.start-a-1,R=zF(T,d[1]),U=c[1]?l+1+GF(R,c[1])+1:e.length;return $s(U,e,n)}let p=X3(c[0]),g=d[0].length-t.start,C=zF(g,WF(d[0])),v=GF(C,WF(p)),b=p.length-(v+1);return $s(b,e,n)};function Q3(i){return i.length===1&&!!i.match(/^[,.][0-9]*$/g)}var UF=function(i,e,t){i=wr(i,0);let n=$s(i,e,t);return i.start>=n.start&&i.end<=n.end};function $s(i,e,t){i=wr(i,0);let n=iu(e,t);return{start:ft(i.start,n.start,n.end),end:ft(i.end,n.start,n.end)}}var jF=function(i,e,t){let n=iu(i,t);return iu(e,t).start-n.start};var Z3=HF.inherit({_getDefaultOptions(){return m(this.callBase(),{useMaskBehavior:!0,format:null})},_isDeleteKey:i=>i==="del",_supportedKeys(){return this._useMaskBehavior()?m(this.callBase(),{minus:this._revertSign.bind(this),del:this._removeHandler.bind(this),backspace:this._removeHandler.bind(this),leftArrow:this._arrowHandler.bind(this,-1),rightArrow:this._arrowHandler.bind(this,1),home:this._moveCaretToBoundaryEventHandler.bind(this,1),enter:this._updateFormattedValue.bind(this),end:this._moveCaretToBoundaryEventHandler.bind(this,-1)}):this.callBase()},_getTextSeparatorIndex(i){let e=ze.getDecimalSeparator(),t=ed(this.option("format")).occurrence;return eu(i,e,t)},_focusInHandler(i){this._preventNestedFocusEvent(i)||(this.clearCaretTimeout(),this._caretTimeout=setTimeout(()=>{this._caretTimeout=void 0;let e=this._caret();if(e.start===e.end&&this._useMaskBehavior()){let t=this._getInputVal(),n=this._getTextSeparatorIndex(t);n>=0?this._caret({start:n,end:n}):this._moveCaretToBoundaryEventHandler(-1,i)}},0)),this.callBase(i)},_focusOutHandler(i){let e=!this._preventNestedFocusEvent(i);e&&(this._focusOutOccurs=!0,this._useMaskBehavior()&&this._updateFormattedValue()),this.callBase(i),e&&(this._focusOutOccurs=!1)},_hasValueBeenChanged(i){let e=this._getFormatPattern(),t=this.option("value");return(this._format(t,e)||"")!==i},_updateFormattedValue(){let i=this._getInputVal();this._hasValueBeenChanged(i)&&(this._updateParsedValue(),this._adjustParsedValue(),this._setTextByParsedValue(),this._parsedValue!==this.option("value")&&_.trigger(this._input(),"change"))},_arrowHandler(i,e){if(!this._useMaskBehavior())return;let t=this._getInputVal(),n=this._getFormatPattern(),o=wr(this._caret(),i);UF(o,t,n)||(o=i===1?o.end:o.start,e.preventDefault(),this._caret($s(o,t,n)))},_moveCaretToBoundary(i){let e=iu(this._getInputVal(),this._getFormatPattern()),t=wr(i===1?e.start:e.end,0);this._caret(t)},_moveCaretToBoundaryEventHandler(i,e){!this._useMaskBehavior()||e&&e.shiftKey||(this._moveCaretToBoundary(i),e&&e.preventDefault())},_shouldMoveCaret(i,e){let t=ze.getDecimalSeparator(),n=i.charAt(e.end)===t;return(this._lastKey===t||this._lastKey==="."||this._lastKey===",")&&n},_getInputVal(){return ze.convertDigits(this._input().val(),!0)},_keyboardHandler(i){if(this.clearCaretTimeout(),this._lastKey=ze.convertDigits(Xd(i),!0),this._lastKeyName=De(i),!this._shouldHandleKey(i.originalEvent))return this.callBase(i);let e=this._getInputVal(),t=this._caret(),n;this._lastKeyName==="minus"?n="":n=i.which===110?ze.getDecimalSeparator():this._lastKey;let o=this._tryParse(e,t,n);return this._shouldMoveCaret(e,t)&&(this._moveCaret(1),i.originalEvent.preventDefault()),o===void 0?this._lastKeyName!=="minus"&&i.originalEvent.preventDefault():this._parsedValue=o,this.callBase(i)},_keyPressHandler(i){this._useMaskBehavior()||this.callBase(i)},_removeHandler(i){let e=this._caret(),t=this._getInputVal(),{start:n}=e,{end:o}=e;this._lastKey=Xd(i),this._lastKeyName=De(i);let s=this._isDeleteKey(this._lastKeyName),r=!s;if(n===o){let c=n;if(r&&c>0||s&&c<t.length)s&&o++,r&&n--;else{i.preventDefault();return}}let a=t.slice(n,o);if(this._isStub(a)){this._moveCaret(s?1:-1),(this._parsedValue<0||1/this._parsedValue===-1/0)&&(this._revertSign(i),this._setTextByParsedValue(),this.option("valueChangeEvent").split(" ").includes("input")&&_.trigger(this._input(),"input")),i.preventDefault();return}let l=ze.getDecimalSeparator();if(a===l){let c=t.indexOf(l);this._isNonStubAfter(c+1)&&(this._moveCaret(s?1:-1),i.preventDefault());return}if(o-n<t.length&&this._replaceSelectedText(t,{start:n,end:o},"").search(/[0-9]/)<0&&this._isValueInRange(0)){this._parsedValue=this._parsedValue<0||1/this._parsedValue===-1/0?-0:0;return}let d=this._tryParse(t,{start:n,end:o},"");d===void 0?i.preventDefault():this._parsedValue=d},_isPercentFormat(){return this._getFormatPattern().replace(/'[^']+'/g,"").indexOf("%")!==-1},_parse(i,e){let t=this.option("format"),n=A(t.parser),o=n?t.parser:ze.parse,s=0;if(!n){let r=ed(e).index,a=this._getTextSeparatorIndex(i),l=r!==-1?r:e.length,d=a!==-1?a:i.length;d>l&&e.indexOf("#")===-1&&(s=d-l)}return i=i.substr(s),o(i,e)},_format(i,e){let t=this.option("format"),n=t?.formatter||t,o=A(n)?n:ze.format;return i===null?"":o(i,e)},_getFormatPattern(){return this._currentFormat||this._updateFormat(),this._currentFormat},_updateFormat(){let i=this.option("format"),e=A(i?.parser),t=B(i)&&(i.includes("0")||i.includes("#")),n=i==="exponential"||i?.type==="exponential",o=e||t||n;this._currentFormat=o?i:qD(s=>{let r=this._format(s,i);return ze.convertDigits(r,!0)})},_getFormatForSign(i){let e=this._getFormatPattern();if(B(e)){let n=e.split(";"),o=ze.getSign(i,e);return n[1]=n[1]||`-${n[0]}`,o<0?n[1]:n[0]}return ze.getSign(i)<0?"-":""},_removeStubs(i,e){let t=this._getFormatForSign(i),n=ze.getThousandsSeparator(),o=this._getStubs(t),s=i;if(o.length){let r=o[0],a=new RegExp(`(${Pn(o[1]||"")})$`,"g"),l=new RegExp(`[-${Pn(e?"":n)}]`,"g");s=s.replace(r,"").replace(a,"").replace(l,"")}return s},_getStubs(i){let e=/[^']([#0.,]+)/g.exec(i),t=e&&e[0].trim();return i.split(t).map(n=>n.replace(/'/g,""))},_truncateToPrecision(i,e){if(f(i)){let t=i.toString(),n=t.indexOf(".");if(t&&n>-1){let o=parseFloat(t.substr(0,n+e+1));return isNaN(o)?i:o}}return i},_tryParse(i,e,t){let n=e.start!==e.end,o=n&&e.start===0&&e.end===i.length,s=ze.getDecimalSeparator();if(o&&t===s)return 0;let r=this._replaceSelectedText(i,e,t),a=this._getFormatPattern(),l=this._getParsedValue(r,a),d=!a.parser&&this._getPrecisionLimits(r).max,c=l!==this._parsedValue,h=t===s&&d===0,p=!n&&!c&&t!=="-"&&this._isStub(t);if(h||p||(this._removeStubs(r)===""&&(l=Math.abs(0*this._parsedValue)),isNaN(l)))return;let g=l===null?this._parsedValue:l;return l=d?this._truncateToPrecision(g,d):l,!a.parser&&this._isPercentFormat()?$F(l,d):l},_getParsedValue(i,e){let t=ze.getSign(i,e?.formatter||e),n=this._removeStubs(i,!0),o=this._parse(n,e),s=o<0?-1:1;return xe(o)&&t!==s?t*o:o},_isValueIncomplete(i){if(!this._useMaskBehavior())return this.callBase(i);let e=this._caret(),t=ze.getDecimalSeparator(),n=this._getTextSeparatorIndex(i),o=n>=0&&n<e.start,s=this._removeStubs(i,!0).split(t);if(!o||s.length!==2)return!1;let r=s[1].length,l=!!this._getFormatPattern().parser,d=!l&&this._getPrecisionLimits(this._getFormatPattern(),i),c=l?!0:fn(r,d.min,d.max),h=s[1].charAt(r-1)==="0";return c&&(h||!r)},_isValueInRange(i){let e=Te(this.option("min"),-1/0),t=Te(this.option("max"),1/0);return fn(i,e,t)},_setInputText(i){let e=ze.convertDigits(i,!0),t=KF(this._getInputVal(),e,this._caret(),this._getFormatPattern());this._input().val(i),this._toggleEmptinessEventHandler(),this._formattedValue=i,this._focusOutOccurs||this._caret(t)},_useMaskBehavior(){return!!this.option("format")&&this.option("useMaskBehavior")},_renderInputType(){let i=this.option("mode")==="number",e=F.real().deviceType==="desktop";this._useMaskBehavior()&&i?this._setInputType(e||this._isSupportInputMode()?"text":"tel"):this.callBase()},_isChar:i=>B(i)&&i.length===1,_moveCaret(i){if(!i)return;let e=wr(this._caret(),i),t=$s(e,this._getInputVal(),this._getFormatPattern());this._caret(t)},_shouldHandleKey(i){let e=De(i),t=ot(i)||i.altKey||i.shiftKey||!this._isChar(e),n=e==="minus";return this._useMaskBehavior()&&!t&&!n},_renderInput(){this.callBase(),this._renderFormatter()},_renderFormatter(){this._clearCache(),this._detachFormatterEvents(),this._useMaskBehavior()&&this._attachFormatterEvents()},_detachFormatterEvents(){_.off(this._input(),".dxNumberFormatter")},_isInputFromPaste(i){let e=i.originalEvent&&i.originalEvent.inputType;return f(e)?e==="insertFromPaste":this._isValuePasted},_attachFormatterEvents(){let i=this._input();_.on(i,D("input","dxNumberFormatter"),e=>{this._formatValue(e),this._isValuePasted=!1}),_.on(i,D("dxclick","dxNumberFormatter"),()=>{this._caretTimeout||(this._caretTimeout=setTimeout(()=>{this._caretTimeout=void 0,this._caret($s(this._caret(),this._getInputVal(),this._getFormatPattern()))},0))}),_.on(i,Hs,()=>{this.clearCaretTimeout()})},clearCaretTimeout(){clearTimeout(this._caretTimeout),this._caretTimeout=void 0},_forceRefreshInputValue(){if(!this._useMaskBehavior())return this.callBase()},_isNonStubAfter(i){let e=this._getInputVal().slice(i);return e&&!this._isStub(e,!0)},_isStub(i,e){let n=`^[^0-9${Pn(ze.getDecimalSeparator())}]+$`;return new RegExp(n,"g").test(i)&&(e||this._isChar(i))},_parseValue(i){return this._useMaskBehavior()?this._parsedValue:this.callBase(i)},_getPrecisionLimits(i){let e=this._getFormatForSign(i),t=ed(e).index,n=(tu(e,t)[1]||"").replace(/[^#0]/g,""),o=n.replace(/^(0*)#*/,"$1").length,s=n.length;return{min:o,max:s}},_revertSign(i){if(!this._useMaskBehavior())return;let e=this._caret();if(e.start!==e.end){if(De(i)==="minus"){this._applyRevertedSign(i,e,!0);return}this._caret($s(0,this._getInputVal(),this._getFormatPattern()))}this._applyRevertedSign(i,e)},_applyRevertedSign(i,e,t){let n=-1*Te(this._parsedValue,null);if((this._isValueInRange(n)||n===0)&&(this._parsedValue=n,t)){let o=this._getFormatPattern(),s=this._getInputVal();this._setTextByParsedValue(),i.preventDefault();let r=this._getInputVal(),a=jF(s,r,o);e=wr(e,a);let l=$s(e,r,o);this._caret(l)}},_removeMinusFromText(i,e){return this._lastKeyName==="minus"&&i.charAt(e.start-1)==="-"?this._replaceSelectedText(i,{start:e.start-1,end:e.start},""):i},_setTextByParsedValue(){let i=this._getFormatPattern(),e=this._parseValue(),t=this._format(e,i)||"";this._setInputText(t)},_formatValue(i){let e=this._getInputVal(),t=this._caret(),n=this._removeMinusFromText(e,t),o=n!==e;if(e=n,!this._isInputFromPaste(i)&&this._isValueIncomplete(n)){this._formattedValue=e,o&&this._setTextByParsedValue();return}if(ze.convertDigits(this._formattedValue,!0)!==e){let r=this._tryParse(e,t,"");f(r)&&(this._parsedValue=r)}this._setTextByParsedValue()},_renderDisplayText(){this._useMaskBehavior()?this._toggleEmptinessEventHandler():this.callBase.apply(this,arguments)},_renderValue(){return this._useMaskBehavior()&&(this._parsedValue=this.option("value"),this._setTextByParsedValue()),this.callBase()},_updateParsedValue(){let i=this._getInputVal();this._parsedValue=this._tryParse(i,this._caret())},_adjustParsedValue(){if(!this._useMaskBehavior())return;let e=this._removeStubs(this._getInputVal())?this._parseValue():null;if(!xe(e)){this._parsedValue=e;return}this._parsedValue=ft(e,this.option("min"),this.option("max"))},_valueChangeEventHandler(i){if(!this._useMaskBehavior())return this.callBase(i);let e=this._caret();this._saveValueChangeEvent(i),this._lastKey=null,this._lastKeyName=null,this._updateParsedValue(),this._adjustParsedValue(),this.option("value",this._parsedValue),e&&this._caret(e)},_optionChanged(i){switch(i.name){case"format":case"useMaskBehavior":this._renderInputType(),this._updateFormat(),this._renderFormatter(),this._renderValue(),this._refreshValueChangeEvent(),this._refreshEvents();break;case"min":case"max":this._adjustParsedValue(),this.callBase(i);break;default:this.callBase(i)}},_clearCache(){delete this._formattedValue,delete this._lastKey,delete this._lastKeyName,delete this._parsedValue,delete this._focusOutOccurs,clearTimeout(this._caretTimeout),delete this._caretTimeout},_clean(){this._clearCache(),this.callBase()}}),vb=Z3;G("dxNumberBox",vb);var qF=vb;var ya=qF;var Pi=kl;var J3=ce.inherit({ctor(){this._dataStructure=[],this._itemsCount=0,this._visibleItemsCount=0},_indexByKey:{},_convertItemsToNodes(i,e){let t=this;x(i,(n,o)=>{let s=f(e)?e:t._getParentId(o),r=t._convertItemToNode(o,s);t._dataStructure.push(r),t._checkForDuplicateId(r.internalFields.key),t._indexByKey[r.internalFields.key]=t._dataStructure.length-1,t._itemHasChildren(o)&&t._convertItemsToNodes(t._dataAccessors.getters.items(o),r.internalFields.key)})},_checkForDuplicateId(i){if(f(this._indexByKey[i]))throw Z.Error("E1040",i)},_getParentId(i){return this._dataType==="plain"?this._dataAccessors.getters.parentKey(i):void 0},_itemHasChildren(i){if(this._dataType==="plain")return;let e=this._dataAccessors.getters.items(i);return e&&e.length},_getUniqueKey(i){let e=this._dataAccessors.getters.key,t=e(i);return e&&(t||t===0)&&Zs(t)?t:this.getItemsCount()},_convertItemToNode(i,e){this._itemsCount++,i.visible!==!1&&this._visibleItemsCount++;let t={internalFields:{disabled:this._dataAccessors.getters.disabled(i,{defaultValue:!1}),expanded:this._dataAccessors.getters.expanded(i,{defaultValue:!1}),selected:this._dataAccessors.getters.selected(i,{defaultValue:!1}),key:this._getUniqueKey(i),parentKey:f(e)?e:this._rootValue,item:this._makeObjectFromPrimitive(i),childrenKeys:[]}};return m(t,i),delete t.items,t},setChildrenKeys(){let i=this;x(this._dataStructure,(e,t)=>{if(t.internalFields.parentKey===i._rootValue)return;let n=i.getParentNode(t);n&&n.internalFields.childrenKeys.push(t.internalFields.key)})},_makeObjectFromPrimitive(i){if(Zs(i)){let e=i;i={},this._dataAccessors.setters.key(i,e)}return i},_convertToPublicNode(i,e){if(!i)return null;let t={text:this._dataAccessors.getters.display(i),key:i.internalFields.key,selected:i.internalFields.selected,expanded:i.internalFields.expanded,disabled:i.internalFields.disabled,parent:e||null,itemData:i.internalFields.item,children:[],items:[]};return t.parent&&(t.parent.children.push(t),t.parent.items.push(t)),t},convertToPublicNodes(i,e){if(!i.length)return[];let t=this,n=[];return x(i,(o,s)=>{s=Zs(s)?t._getByKey(s):s;let r=t._convertToPublicNode(s,e);r.children=t.convertToPublicNodes(s.internalFields.childrenKeys,r),n.push(r),s.internalFields.publicNode=r}),n},setDataAccessors(i){this._dataAccessors=i},_getByKey(i){return this._dataStructure[this.getIndexByKey(i)]||null},getParentNode(i){return this._getByKey(i.internalFields.parentKey)},getByKey(i,e){if(e==null)return null;let t=null,n=this;return function(o,s){return x(o,(r,a)=>{if((a.internalFields&&a.internalFields.key||n._dataAccessors.getters.key(a)).toString()===s.toString())return t=a,!1}),t}(i,e)},getItemsCount(){return this._itemsCount},getVisibleItemsCount(){return this._visibleItemsCount},updateIndexByKey(){let i=this;this._indexByKey={},x(this._dataStructure,(e,t)=>{i._checkForDuplicateId(t.internalFields.key),i._indexByKey[t.internalFields.key]=e})},updateChildrenKeys(){this._indexByKey={},this.removeChildrenKeys(),this.updateIndexByKey(),this.setChildrenKeys()},removeChildrenKeys(){this._indexByKey={},x(this._dataStructure,(i,e)=>{e.internalFields.childrenKeys=[]})},getIndexByKey(i){return this._indexByKey[i]},createPlainStructure(i,e,t){return this._itemsCount=0,this._visibleItemsCount=0,this._rootValue=e,this._dataType=t,this._indexByKey={},this._convertItemsToNodes(i),this.setChildrenKeys(),this._dataStructure}}),YF=J3;var td="expanded",Oa="selected",eY="disabled";bo.setEditorClass(Xn);var tY=ce.inherit({ctor(i){this.options={},m(this.options,this._defaultOptions(),i),this.options.dataConverter.setDataAccessors(this.options.dataAccessors),this._selectedNodesKeys=[],this._expandedNodesKeys=[],this._dataStructure=[],this._createInternalDataStructure(),this.getTreeNodes()},setOption(i,e){this.options[i]=e,i==="recursiveSelection"&&this._updateSelection()},_defaultOptions:()=>({dataAccessors:void 0,items:[],multipleSelection:!0,recursiveSelection:!1,recursiveExpansion:!1,rootValue:0,searchValue:"",dataType:"tree",searchMode:"contains",dataConverter:new YF,onNodeChanged:S,sort:null}),_createInternalDataStructure(){this._initialDataStructure=this.options.dataConverter.createPlainStructure(this.options.items,this.options.rootValue,this.options.dataType),this._dataStructure=this.options.searchValue.length?this.search(this.options.searchValue):this._initialDataStructure,this.options.dataConverter._dataStructure=this._dataStructure,this._updateSelection(),this._updateExpansion()},_updateSelection(){this.options.recursiveSelection&&(this._setChildrenSelection(),this._setParentSelection()),this._selectedNodesKeys=this._updateNodesKeysArray(Oa)},_updateExpansion(i){this.options.recursiveExpansion&&(i?this._updateOneBranch(i):this._setParentExpansion()),this._expandedNodesKeys=this._updateNodesKeysArray(td)},_updateNodesKeysArray(i){let e=this,t=[];return x(e._getDataBySelectionMode(),(n,o)=>{e._isNodeVisible(o)&&o.internalFields[i]&&(i===td||e.options.multipleSelection?t.push(o.internalFields.key):(t.length&&e.toggleSelection(t[0],!1,!0),t=[o.internalFields.key]))}),t},_getDataBySelectionMode(){return this.options.multipleSelection?this.getData():this.getFullData()},_isNodeVisible:i=>i.internalFields.item.visible!==!1,_getByKey(i,e){return i===this._dataStructure?this.options.dataConverter._getByKey(e):this.options.dataConverter.getByKey(i,e)},_setChildrenSelection(){let i=this;x(this._dataStructure,(e,t)=>{if(!t.internalFields.childrenKeys.length)return;let n=t.internalFields.selected;n===!0&&i._toggleChildrenSelection(t,n)})},_setParentSelection(){let i=this;x(this._dataStructure,(e,t)=>{i.options.dataConverter.getParentNode(t)&&t.internalFields.parentKey!==i.options.rootValue&&i._iterateParents(t,o=>{let s=i._calculateSelectedState(o);i._setFieldState(o,Oa,s)})})},_setParentExpansion(){let i=this;x(this._dataStructure,(e,t)=>{t.internalFields.expanded&&i._updateOneBranch(t.internalFields.key)})},_updateOneBranch(i){let e=this,t=this.getNodeByKey(i);e._iterateParents(t,n=>{e._setFieldState(n,td,!0)})},_iterateChildren(i,e,t,n){if(!A(t))return;let o=this,s=i.internalFields.key;n=n||[],n.indexOf(s)===-1&&(n.push(s),x(i.internalFields.childrenKeys,(r,a)=>{let l=o.getNodeByKey(a);t(l),l.internalFields.childrenKeys.length&&e&&o._iterateChildren(l,e,t,n)}))},_iterateParents(i,e,t){if(i.internalFields.parentKey===this.options.rootValue||!A(e))return;t=t||[];let{key:n}=i.internalFields;if(t.indexOf(n)===-1){t.push(n);let o=this.options.dataConverter.getParentNode(i);o&&(e(o),o.internalFields.parentKey!==this.options.rootValue&&this._iterateParents(o,e,t))}},_calculateSelectedState(i){let e=i.internalFields.childrenKeys.length,t=0,n=0,o=!1;for(let s=0;s<=e-1;s++){let r=this.getNodeByKey(i.internalFields.childrenKeys[s]),a=r.internalFields.item.visible===!1,l=r.internalFields.selected;if(a){n++;continue}l?t++:l===void 0&&(t+=.5)}return t&&(o=t===e-n?!0:void 0),o},_toggleChildrenSelection(i,e){let t=this;this._iterateChildren(i,!0,n=>{t._isNodeVisible(n)&&t._setFieldState(n,Oa,e)})},_setFieldState(i,e,t){i.internalFields[e]!==t&&(i.internalFields[e]=t,i.internalFields.publicNode&&(i.internalFields.publicNode[e]=t),this.options.dataAccessors.setters[e](i.internalFields.item,t),this.options.onNodeChanged(i))},_markChildren(i){let e=this;x(i,(t,n)=>{let o=e.getIndexByKey(n),s=e.getNodeByKey(n);e._dataStructure[o]=0,s.internalFields.childrenKeys.length&&e._markChildren(s.internalFields.childrenKeys)})},_removeNode(i){let e=this.getNodeByKey(i);this._dataStructure[this.getIndexByKey(i)]=0,this._markChildren(e.internalFields.childrenKeys);let t=this,n=0,o=m([],this._dataStructure);x(o,(s,r)=>{r||(t._dataStructure.splice(s-n,1),n++)})},_addNode(i){let{dataConverter:e}=this.options,t=e._convertItemToNode(i,this.options.dataAccessors.getters.parentKey(i));this._dataStructure=this._dataStructure.concat(t),this._initialDataStructure=this._initialDataStructure.concat(t),e._dataStructure=e._dataStructure.concat(t)},_updateFields(){this.options.dataConverter.updateChildrenKeys(),this._updateSelection(),this._updateExpansion()},getSelectedNodesKeys(){return this._selectedNodesKeys},getExpandedNodesKeys(){return this._expandedNodesKeys},getData(){return this._dataStructure},getFullData(){return this._initialDataStructure},getNodeByItem(i){let e=null;return x(this._dataStructure,(t,n)=>{if(n.internalFields.item===i)return e=n,!1}),e},getNodesByItems(i){let e=this,t=[];return x(i,(n,o)=>{let s=e.getNodeByItem(o);s&&t.push(s)}),t},getNodeByKey(i,e){return this._getByKey(e||this._getDataBySelectionMode(),i)},getTreeNodes(){return this.options.dataConverter.convertToPublicNodes(this.getRootNodes())},getItemsCount(){return this.options.dataConverter.getItemsCount()},getVisibleItemsCount(){return this.options.dataConverter.getVisibleItemsCount()},getPublicNode:i=>i.internalFields.publicNode,getRootNodes(){return this.getChildrenNodes(this.options.rootValue)},getChildrenNodes(i){return vt(this._dataStructure,{langParams:this.options.langParams}).filter(["internalFields.parentKey",i]).toArray()},getIndexByKey(i){return this.options.dataConverter.getIndexByKey(i)},addItem(i){this._addNode(i),this._updateFields()},removeItem(i){this._removeNode(i),this._updateFields()},toggleSelection(i,e,t){let n=this._isSingleModeUnselect(e),o=this._getByKey(t||n?this._initialDataStructure:this._dataStructure,i);this._setFieldState(o,Oa,e),this.options.recursiveSelection&&!t&&(e?this._setChildrenSelection():this._toggleChildrenSelection(o,e),this._setParentSelection()),this._selectedNodesKeys=this._updateNodesKeysArray(Oa)},_isSingleModeUnselect(i){return!this.options.multipleSelection&&!i},toggleNodeDisabledState(i,e){let t=this.getNodeByKey(i);this._setFieldState(t,eY,e)},toggleSelectAll(i){if(!f(i))return;let e=this,t=e._selectedNodesKeys[e._selectedNodesKeys.length-1],n=e._isSingleModeUnselect(i)?this._initialDataStructure:this._dataStructure;x(n,(o,s)=>{e._isNodeVisible(s)&&e._setFieldState(s,Oa,i)}),e._selectedNodesKeys=e._updateNodesKeysArray(Oa),!i&&e.options.selectionRequired&&e.toggleSelection(t,!0)},isAllSelected(){return this.getSelectedNodesKeys().length?this.getSelectedNodesKeys().length===this.getVisibleItemsCount()?!0:void 0:!1},toggleExpansion(i,e){let t=this.getNodeByKey(i);this._setFieldState(t,td,e),e&&this._updateExpansion(i),this._expandedNodesKeys=this._updateNodesKeysArray(td)},isFiltered(i){return!this.options.searchValue.length||!!this._filterDataStructure(this.options.searchValue,[i]).length},_createCriteria(i,e,t){let n=[];return Array.isArray(i)?(x(i,(o,s)=>{n.push([s,t,e],"or")}),n.pop(),n):[i,t,e]},_filterDataStructure(i,e){let t=this.options.searchExpr||this.options.dataAccessors.getters.display,n=bo.getOperationBySearchMode(this.options.searchMode),o=this._createCriteria(t,i,n);return e=e||this._initialDataStructure,vt(e,{langParams:this.options.langParams}).filter(o).toArray()},search(i){let e=this,t=this._filterDataStructure(i),{dataConverter:n}=this.options;return function o(s,r){let{length:a}=s;for(;r<a;){let l=s[r];if(l.internalFields.parentKey===e.options.rootValue){r++;continue}let d=n.getParentNode(l);if(!d){Z.log("W1007",l.internalFields.parentKey,l.internalFields.key),r++;continue}if(d.internalFields.expanded||e._setFieldState(d,td,!0),s.includes(d)){r++;continue}s.splice(r,0,d),o(s,r)}}(t,0),this.options.sort&&(t=qi.queryByOptions(vt(t),{sort:this.options.sort,langParams:this.options.langParams}).toArray()),n._indexByKey={},x(t,(o,s)=>{s.internalFields.childrenKeys=[],n._indexByKey[s.internalFields.key]=o}),n._dataStructure=t,n.setChildrenKeys(),n._dataStructure}}),XF=tY;var iY=In.inherit({_getDefaultOptions(){return m(this.callBase(),{keyExpr:"id",displayExpr:"text",selectedExpr:"selected",disabledExpr:"disabled",itemsExpr:"items",hoverStateEnabled:!0,parentIdExpr:"parentId",expandedExpr:"expanded"})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}}])},_init(){this.callBase(),this._initAccessors(),this._initDataAdapter(),this._initDynamicTemplates()},_initDataSource(){this.callBase(),this._dataSource&&this._dataSource.paginate(!1)},_initDataAdapter(){let i=this._createDataAdapterAccessors();this._dataAdapter=new XF(m({dataAccessors:{getters:i.getters,setters:i.setters},items:this.option("items")},this._getDataAdapterOptions()))},_getDataAdapterOptions:S,_getItemExtraPropNames:S,_initDynamicTemplates(){let i=["text","html","items","icon"].concat(this._getItemExtraPropNames());this._templateManager.addDefaultTemplates({item:new di(this._addContent.bind(this),i,this.option("integrationOptions.watchMethod"),{text:this._displayGetter,items:this._itemsGetter})})},_addContent(i,e){i.html(e.html).append(this._getIconContainer(e)).append(this._getTextContainer(e))},_getLinkContainer(i,e,t){let{linkAttr:n,url:o}=t,s=$(n)?n:{};return u("<a>").addClass("dx-item-url").attr(I({},s,{href:o})).append(i).append(e)},_getIconContainer(i){if(!i.icon)return;let e=ci(i.icon);if(e.is("img")){let t=this.NAME.startsWith("dxPrivateComponent")?"":`${this.NAME} `;e.attr("alt",`${t}item icon`)}return e},_getTextContainer:i=>u("<span>").text(i.text),_initAccessors(){let i=this;x(this._getAccessors(),(e,t)=>{i._compileAccessor(t)}),this._compileDisplayGetter()},_getAccessors:()=>["key","selected","items","disabled","parentId","expanded"],_getChildNodes(i){let e=this,t=[];return x(i.internalFields.childrenKeys,(n,o)=>{let s=e._dataAdapter.getNodeByKey(o);t.push(s)}),t},_hasChildren:i=>i&&i.internalFields.childrenKeys.length,_compileAccessor(i){let e=`_${i}Getter`,t=`_${i}Setter`,n=this.option(`${i}Expr`);if(!n){this[e]=S,this[t]=S;return}if(A(n)){this[t]=function(o,s){o[n()]=s},this[e]=function(o){return o[n()]};return}this[e]=me(n),this[t]=Ga(n)},_createDataAdapterAccessors(){let i=this,e={getters:{},setters:{}};return x(this._getAccessors(),(t,n)=>{let o=`_${n}Getter`,s=`_${n}Setter`,r=n==="parentId"?"parentKey":n;e.getters[r]=i[o],e.setters[r]=i[s]}),e.getters.display=this._displayGetter?this._displayGetter:t=>t.text,e},_initMarkup(){this.callBase(),this._addWidgetClass()},_addWidgetClass(){this._focusTarget().addClass(this._widgetClass())},_widgetClass:S,_renderItemFrame(i,e){let t=this.callBase.apply(this,arguments);return t.toggleClass("dx-state-disabled",!!this._disabledGetter(e)),t},_optionChanged(i){switch(i.name){case"displayExpr":case"keyExpr":this._initAccessors(),this._initDynamicTemplates(),this.repaint();break;case"itemsExpr":case"selectedExpr":case"disabledExpr":case"expandedExpr":case"parentIdExpr":this._initAccessors(),this._initDataAdapter(),this.repaint();break;case"items":this._initDataAdapter(),this.callBase(i);break;default:this.callBase(i)}}}),QF=iY;var Fg=QF;var nY=Fg,ZF=nY;var bb=class extends pl{_getPlainItems(){return He(this._collectionWidget.option("items"),function e(t){return t.items?[t].concat(He(t.items,e)):t})}_stringifyItem(e){return JSON.stringify(e,(t,n)=>t==="template"?this._getTemplateString(n):n)}_getTemplateString(e){let t;return typeof e=="object"?t=u(e).text():t=e.toString(),t}},JF=bb;var Zn="dx-menu-item",oY=`${Zn}-content`,yb=`${Zn}-selected`,eP=`${Zn}-wrapper`;var sY=`${Zn}-expanded`;var rY=`${Zn}-has-text`,aY=`${Zn}-has-icon`,lY=`${Zn}-has-submenu`,tP=`${Zn}-popout`,dY=`${tP}-container`,iP=`${Zn}-text`;var cY={show:50,hide:300},uY=`${iP}-with-url`;var hY=(()=>{class i extends ZF{_getDefaultOptions(){return m(super._getDefaultOptions(),{items:[],cssClass:"",activeStateEnabled:!0,showSubmenuMode:{name:"onHover",delay:{show:50,hide:300}},animation:{show:{type:"fade",from:0,to:1,duration:100},hide:{type:"fade",from:1,to:0,duration:100}},selectByClick:!1,focusOnSelectedItem:!1,keyExpr:null,_itemAttributes:{role:"menuitem"},useInkRipple:!1})}_itemDataKey(){return"dxMenuItemDataKey"}_itemClass(){return Zn}_setAriaSelectionAttribute(t,n){}_selectedItemClass(){return yb}_widgetClass(){return"dx-menu-base"}_focusTarget(){return this._itemContainer()}_clean(){this.option("focusedElement",null),super._clean()}_supportedKeys(){return m(super._supportedKeys(),{space:()=>{let t=u(this.option("focusedElement"));!t.length||!this._isSelectionEnabled()||this.selectItem(t[0])},pageUp:S,pageDown:S})}_isSelectionEnabled(){return this.option("selectionMode")==="single"}_init(){this._activeStateUnit=`.${Zn}`,super._init(),this._renderSelectedItem(),this._initActions()}_getLinkContainer(t,n,o){let{linkAttr:s,url:r}=o;return t?.addClass("dx-icon-with-url"),n?.addClass(uY),super._getLinkContainer(t,n,{linkAttr:s,url:r})}_addContent(t,n){let{html:o,url:s}=n;if(s){t.html(o);let r=this._getLinkContainer(this._getIconContainer(n),this._getTextContainer(n),n);t.append(r)}else super._addContent(t,n);t.append(this._getPopoutContainer(n)),this._addContentClasses(n,t.parent())}_getTextContainer(t){let{text:n}=t;if(!n)return;let o=u("<span>").addClass(iP),s=q(t)?n:String(t);return o.text(s)}_getItemExtraPropNames(){return["url","linkAttr"]}_getPopoutContainer(t){let{items:n}=t,o;if(n&&n.length){let s=u("<div>").addClass(tP);o=u("<span>").addClass(dY).append(s)}return o}_getDataAdapterOptions(){return{rootValue:0,multipleSelection:!1,recursiveSelection:!1,recursiveExpansion:!1,searchValue:""}}_selectByItem(t){if(!t)return;let n=this._dataAdapter.getNodeByItem(t);this._dataAdapter.toggleSelection(n.internalFields.key,!0)}_renderSelectedItem(){let t=this._dataAdapter.getSelectedNodesKeys(),n=t.length&&t[0],o=this.option("selectedItem");if(!n){this._selectByItem(o);return}let s=this._dataAdapter.getNodeByKey(n);if(s.selectable!==!1){if(!o){this.option("selectedItem",s.internalFields.item);return}o!==s.internalFields.item&&(this._dataAdapter.toggleSelection(n,!1),this._selectByItem(o))}}_initActions(){}_initMarkup(){super._initMarkup(),this.option("useInkRipple")&&this._renderInkRipple()}_renderInkRipple(){this._inkRipple=Sl()}_toggleActiveState(t,n,o){if(super._toggleActiveState.apply(this,arguments),!this._inkRipple)return;let s={element:t,event:o};n?this._inkRipple.showWave(s):this._inkRipple.hideWave(s)}_getShowSubmenuMode(){let t=this.option("showSubmenuMode");return t=$(t)?t.name:t,this._isDesktopDevice()?t:"onClick"}_initSelectedItems(){}_isDesktopDevice(){return F.real().deviceType==="desktop"}_initEditStrategy(){let t=JF;this._editStrategy=new t(this)}_addCustomCssClass(t){t.addClass(this.option("cssClass"))}_itemWrapperSelector(){return`.${eP}`}_hoverStartHandler(t){let n=this._getItemElementByEventArgs(t);!n||this._isItemDisabled(n)||(t.stopPropagation(),this._getShowSubmenuMode()==="onHover"&&(clearTimeout(this._showSubmenusTimeout),this._showSubmenusTimeout=setTimeout(this._showSubmenu.bind(this,n),this._getSubmenuDelay("show"))))}_getAvailableItems(t){return super._getAvailableItems(t).filter(function(){return u(this).css("visibility")!=="hidden"})}_isItemDisabled(t){return this._disabledGetter(t.data(this._itemDataKey()))}_showSubmenu(t){this._addExpandedClass(t)}_addExpandedClass(t){u(t).addClass(sY)}_getSubmenuDelay(t){let{delay:n}=this.option("showSubmenuMode");return f(n)?$(n)?n[t]:n:cY[t]}_getItemElementByEventArgs(t){let n=u(t.target);if(n.hasClass(this._itemClass())||n.get(0)===t.currentTarget)return n;for(;!n.hasClass(this._itemClass());)if(n=n.parent(),n.hasClass("dx-submenu"))return null;return n}_hoverEndHandler(t){clearTimeout(this._showSubmenusTimeout)}_hasSubmenu(t){return t&&t.internalFields.childrenKeys.length}_renderContentImpl(){this._renderItems(this._dataAdapter.getRootNodes())}_renderItems(t,n){if(!t.length)return;this.hasIcons=!1;let o=this._renderContainer(this.$element(),n),s=-1,r=-1;x(t,(a,l)=>{let d=l.visible!==!1;d&&s<0&&(s=a),s<a&&(l.beginGroup||a===r)&&(r=d?a:a+1),a===r&&s<a&&this._renderSeparator(o),this._renderItem(a,l,o)}),this.hasIcons||o.addClass("dx-menu-no-icons")}_renderContainer(t,n){let o=u("<ul>");return this.setAria("role","none",o),o.appendTo(t).addClass("dx-menu-items-container")}_createDOMElement(t){let n=u("<li>");return this.setAria("role","none",n),n.appendTo(t).addClass(eP)}_renderItem(t,n,o,s){let{items:r=[]}=this.option(),a=s??this._createDOMElement(o);r[t+1]&&r[t+1].beginGroup&&a.addClass("dx-menu-last-group-item");let l=super._renderItem(t,n.internalFields.item,a);n.internalFields.item===this.option("selectedItem")&&l.addClass(yb),l.attr("tabIndex",-1),this._hasSubmenu(n)&&this.setAria("haspopup","true",l)}_renderItemFrame(t,n,o){let s=o.children(`.${Zn}`);return s.length?s:super._renderItemFrame.apply(this,arguments)}_refreshItem(t,n){let o=this._dataAdapter.getNodeByItem(n),s=t.data(this._itemIndexKey()),r=t.closest("ul"),a=t.closest("li");this._renderItem(s,o,r,a)}_addContentClasses(t,n){let o=t.text?!!t.text.length:!1,s=!!t.icon,r=t.items?!!t.items.length:!1;n.toggleClass(rY,o),n.toggleClass(aY,s),this.hasIcons||(this.hasIcons=s),n.toggleClass(lY,r)}_getItemContent(t){let n=super._getItemContent(t);return n.length||(n=t.children(`.${oY}`)),n}_postprocessRenderItem(t){let n=u(t.itemElement),o=this._dataAdapter.getSelectedNodesKeys();if(!o.length||!this._selectedGetter(t.itemData)||!this._isItemSelectable(t.itemData)){this._setAriaSelectionAttribute(n,"false");return}this._dataAdapter.getNodeByItem(t.itemData).internalFields.key===o[0]?(n.addClass(this._selectedItemClass()),this._setAriaSelectionAttribute(n,"true")):this._setAriaSelectionAttribute(n,"false")}_isItemSelectable(t){return t.selectable!==!1}_renderSeparator(t){u("<li>").appendTo(t).addClass("dx-menu-separator")}_itemClickHandler(t){if(t._skipHandling)return;let n=this._createAction(this._updateSubmenuVisibilityOnClick.bind(this));this._itemDXEventHandler(t,"onItemClick",{},{beforeExecute:this._itemClick,afterExecute:n.bind(this)}),t._skipHandling=!0}_itemClick(t){let{event:n,itemData:o}=t.args[0],s=this._getItemElementByEventArgs(n),r=s&&s.find(".dx-item-url").get(0);o.url&&r&&r.click()}_updateSubmenuVisibilityOnClick(t){this._updateSelectedItemOnClick(t),this._getShowSubmenuMode()==="onClick"&&this._addExpandedClass(t.args[0].itemElement)}_updateSelectedItemOnClick(t){let n=t.args?t.args[0]:t;if(!this._isItemSelectAllowed(n.itemData))return;let o=this._dataAdapter.getSelectedNodesKeys(),s=o.length&&this._dataAdapter.getNodeByKey(o[0]);s&&this._toggleItemSelection(s,!1),!s||s.internalFields.item!==n.itemData?this.selectItem(n.itemData):(this._fireSelectionChangeEvent(null,this.option("selectedItem")),this._setOptionWithoutOptionChange("selectedItem",null))}_isItemSelectAllowed(t){let n=this._isSelectionEnabled()&&this.option("selectByClick");return!this._isContainerEmpty()&&n&&this._isItemSelectable(t)&&!this._itemsGetter(t)}_isContainerEmpty(){return this._itemContainer().is(":empty")}_syncSelectionOptions(){return th()}_optionChanged(t){switch(t.name){case"showSubmenuMode":break;case"selectedItem":{let n=this._dataAdapter.getNodeByItem(t.value),o=this._dataAdapter.getSelectedNodesKeys()[0];if(n&&n.internalFields.key!==o){if(n.selectable===!1)break;o&&this._toggleItemSelection(this._dataAdapter.getNodeByKey(o),!1),this._toggleItemSelection(n,!0),this._updateSelectedItems()}break}case"cssClass":case"position":case"selectByClick":case"animation":case"useInkRipple":this._invalidate();break;default:super._optionChanged(t)}}_toggleItemSelection(t,n){let o=this._getElementByItem(t.internalFields.item);o&&u(o).toggleClass(yb),this._dataAdapter.toggleSelection(t.internalFields.key,n)}_getElementByItem(t){let n;return x(this._itemElements(),(o,s)=>u(s).data(this._itemDataKey())!==t?!0:(n=s,!1)),n}_updateSelectedItems(t,n){(t||n)&&this._fireSelectionChangeEvent(n,t)}_fireSelectionChangeEvent(t,n){this._createActionByOption("onSelectionChanged",{excludeValidators:["disabled","readOnly"]})({addedItems:[t],removedItems:[n]})}selectItem(t){let n=t.nodeType?this._getItemData(t):t,o=this._dataAdapter.getSelectedNodesKeys()[0],s=this.option("selectedItem"),r=this._dataAdapter.getNodeByItem(n);r.internalFields.key!==o&&(o&&this._toggleItemSelection(this._dataAdapter.getNodeByKey(o),!1),this._toggleItemSelection(r,!0),this._updateSelectedItems(s,n),this._setOptionWithoutOptionChange("selectedItem",n))}unselectItem(t){let n=t.nodeType?this._getItemData(t):t,o=this._dataAdapter.getNodeByItem(n),s=this.option("selectedItem");o.internalFields.selected&&(this._toggleItemSelection(o,!1),this._updateSelectedItems(s,null),this._setOptionWithoutOptionChange("selectedItem",null))}}return i.ItemClass=jn,i})(),Pg=hY;var pY="dx-menu-phone-overlay";var nP=["onShowing","onShown","onSubmenuCreated","onHiding","onHidden","onPositioning","onLeftFirstItem","onLeftLastItem","onCloseRootSubmenu","onExpandLastSubmenu"],gY=["up","down","first","last"];var oP=K(),kg=class extends Pg{getShowEvent(e){if($(e)){if(e.name!==null)return e.name??"dxcontextmenu"}else return e;return null}getShowDelay(e){return $(e)&&e.delay}_getDefaultOptions(){return m(super._getDefaultOptions(),{showEvent:"dxcontextmenu",hideOnOutsideClick:!0,position:{at:"top left",my:"top left"},onShowing:null,onShown:null,onSubmenuCreated:null,onHiding:null,onHidden:null,onPositioning:null,submenuDirection:"auto",visible:!1,target:void 0,onLeftFirstItem:null,onLeftLastItem:null,onCloseRootSubmenu:null,onExpandLastSubmenu:null})}_defaultOptionsRules(){return super._defaultOptionsRules().concat([{device:()=>!W(),options:{animation:null}}])}_setDeprecatedOptions(){super._setDeprecatedOptions(),m(this._deprecatedOptions,{closeOnOutsideClick:{since:"22.2",alias:"hideOnOutsideClick"}})}_initActions(){this._actions={},x(nP,(e,t)=>{this._actions[t]=this._createActionByOption(t)||S})}_setOptionsByReference(){super._setOptionsByReference(),m(this._optionsByReference,{animation:!0,selectedItem:!0})}_focusInHandler(){}_itemContainer(){return this._overlay?this._overlay.$content():u()}_eventBindingTarget(){return this._itemContainer()}itemsContainer(){return this._overlay?this._overlay.$content():void 0}_supportedKeys(){return m(super._supportedKeys(),{space:()=>{let e=u(this.option("focusedElement"));this.hide(),!(!e.length||!this._isSelectionEnabled())&&this.selectItem(e[0])},escape:this.hide})}_getActiveItem(e){let t=this._getAvailableItems(),n=t.filter(".dx-state-focused"),o=t.filter(".dx-state-hover");return o.closest(".dx-menu-items-container").find(".dx-menu-item").index(n)>=0?n:o.length?o:super._getActiveItem()}_moveFocus(e){let t=this._getItemsByLocation(e),n=this._getActiveItem(!0),o=this.itemsContainer().find(".dx-state-hover"),r=!!(u(this.option("focusedElement")).length||o.length),a;switch(e){case"up":a=r?this._prevItem(t):n,this._setFocusedElement(a),n.is(t.first())&&this._actions.onLeftFirstItem(n);break;case"down":a=r?this._nextItem(t):n,this._setFocusedElement(a),n.is(t.last())&&this._actions.onLeftLastItem(n);break;case"right":a=this.option("rtlEnabled")?this._hideSubmenuHandler():this._expandSubmenuHandler(t,e),this._setFocusedElement(a);break;case"left":a=this.option("rtlEnabled")?this._expandSubmenuHandler(t,e):this._hideSubmenuHandler(),this._setFocusedElement(a);break;case"first":a=t.first(),this._setFocusedElement(a);break;case"last":a=t.last(),this._setFocusedElement(a);break;default:return super._moveFocus(e)}}_setFocusedElement(e){e&&e.length!==0&&(this.option("focusedElement",N(e)),this._scrollToElement(e))}_scrollToElement(e){let n=e.closest(".dx-scrollable").dxScrollable("instance");n?.scrollToElement(e)}_getItemsByLocation(e){let t=this._getActiveItem(!0),n;return gY.includes(e)&&(n=t.closest(".dx-menu-items-container").children().children()),n=this._getAvailableItems(n),n}_getAriaTarget(){return this.$element()}_refreshActiveDescendant(){if(f(this._overlay)){let e=this._overlay.$content();super._refreshActiveDescendant(e)}}_hideSubmenuHandler(){let e=this._getActiveItem(!0),t=e.parents(".dx-menu-item-expanded").first();if(t.length)return this._hideSubmenusOnSameLevel(t),this._hideSubmenu(e.closest(".dx-submenu")),t;this._actions.onCloseRootSubmenu(e)}_expandSubmenuHandler(e,t){let n=this._getActiveItem(!0),o=this._getItemData(n),s=this._dataAdapter.getNodeByItem(o),r=this._hasSubmenu(s),a=n.children(".dx-submenu");if(r&&!n.hasClass("dx-state-disabled"))return(!a.length||a.css("visibility")==="hidden")&&this._showSubmenu(n),this._nextItem(this._getItemsByLocation(t));this._actions.onExpandLastSubmenu(n)}_clean(){this._overlay&&(this._overlay.$element().remove(),this._overlay=null),this._detachShowContextMenuEvents(this._getTarget()),this._shownSubmenus=[],super._clean()}_initMarkup(){this.$element().addClass("dx-has-context-menu"),super._initMarkup()}_render(){super._render(),this._renderVisibility(this.option("visible")),this._addWidgetClass()}_isTargetOutOfComponent(e){return!(u(e).closest(".dx-context-menu").length!==0)}_focusOutHandler(e){let{relatedTarget:t}=e;t&&this._isTargetOutOfComponent(t)&&this.hide(),super._focusOutHandler(e)}_renderContentImpl(){this._detachShowContextMenuEvents(this._getTarget()),this._attachShowContextMenuEvents()}_attachKeyboardEvents(){!this._keyboardListenerId&&this._focusTarget().length&&super._attachKeyboardEvents()}_renderContextMenuOverlay(){if(this._overlay)return;let e=this._getOverlayOptions();this._overlay=this._createComponent(u("<div>").appendTo(this._$element),Ni,e);let t=this._overlay.$content();t.addClass("dx-context-menu"),this._addCustomCssClass(t),this._addPlatformDependentClass(t),this._attachContextMenuEvent()}preventShowingDefaultContextMenuAboveOverlay(){let e=this._itemContainer(),t=D(jh,this.NAME);_.off(e,t,".dx-submenu"),_.on(e,t,".dx-submenu",n=>{n.stopPropagation(),n.preventDefault(),_.off(e,t,".dx-submenu")})}_itemContextMenuHandler(e){super._itemContextMenuHandler(e),e.stopPropagation()}_addPlatformDependentClass(e){F.current().phone&&e.addClass(pY)}_detachShowContextMenuEvents(e){let t=this.getShowEvent(this.option("showEvent"));if(!t)return;let n=D(t,this.NAME);this._showContextMenuEventHandler?_.off(w.getDocument(),n,e,this._showContextMenuEventHandler):_.off(u(e),n)}_attachShowContextMenuEvents(){let e=this._getTarget(),t=this.getShowEvent(this.option("showEvent"));if(!t)return;let n=D(t,this.NAME),o=this._createAction(r=>{let a=this.getShowDelay(this.option("showEvent"));a?setTimeout(()=>this._show(r.event),a):this._show(r.event)},{validatingTargetName:"target"}),s=r=>o({event:r,target:u(r.currentTarget)});o=this._createAction(o),$t(e)||e.nodeType||Ne(e)?(this._showContextMenuEventHandler=void 0,_.on(e,n,s)):(this._showContextMenuEventHandler=s,_.on(w.getDocument(),n,e,this._showContextMenuEventHandler))}_hoverEndHandler(e){super._hoverEndHandler(e),e.stopPropagation()}_renderDimensions(){}_renderContainer(e,t){let n=t||this._itemContainer();e=u("<div>"),e.appendTo(n).addClass("dx-submenu").css("visibility",t?"hidden":"visible"),e.parent().hasClass("dx-overlay-content")||this._addCustomCssClass(e);let o=super._renderContainer(e);return t?o:this.option("width")?o.css("minWidth",this.option("width")):this.option("height")?o.css("minHeight",this.option("height")):o}_renderSubmenuItems(e,t){this._renderItems(this._getChildNodes(e),t);let n=t.children(".dx-submenu");this._actions.onSubmenuCreated({itemElement:N(t),itemData:e.internalFields.item,submenuElement:N(n)}),this._initScrollable(n),this.setAria({role:"menu"},n)}_getOverlayOptions(){let e=this.option("position");return{focusStateEnabled:this.option("focusStateEnabled"),animation:this.option("animation"),innerOverlay:!0,hideOnOutsideClick:n=>this._hideOnOutsideClickHandler(n),propagateOutsideClick:!0,hideOnParentScroll:!0,deferRendering:!1,position:{at:e.at,my:e.my,of:this._getTarget(),collision:"flipfit"},shading:!1,showTitle:!1,height:"auto",width:"auto",onShown:this._overlayShownActionHandler.bind(this),onHiding:this._overlayHidingActionHandler.bind(this),onHidden:this._overlayHiddenActionHandler.bind(this),visualContainer:oP}}_overlayShownActionHandler(e){this._actions.onShown(e)}_overlayHidingActionHandler(e){this._actions.onHiding(e),e.cancel||(this._hideAllShownSubmenus(),this._setOptionWithoutOptionChange("visible",!1))}_overlayHiddenActionHandler(e){this._actions.onHidden(e)}_shouldHideOnOutsideClick(e){let{closeOnOutsideClick:t,hideOnOutsideClick:n}=this.option();return A(n)?n(e):A(t)?t(e):n||t}_hideOnOutsideClickHandler(e){if(!this._shouldHideOnOutsideClick(e))return!1;if(w.isDocument(e.target))return!0;let t=this._getActiveItemsContainer(e.target),n=this._getItemsContainers(),o=this._searchActiveItem(e.target),s=this.$element().parents(".dx-menu-item"),r=o[0]===s[0]&&o.length&&s.length;return this._isIncludeOverlay(t,n)&&o.length||r?(this._getShowSubmenuMode()==="onClick"&&this._hideAllShownChildSubmenus(o),!1):!0}_getActiveItemsContainer(e){return u(e).closest(".dx-menu-items-container")}_getItemsContainers(){return this._overlay.$content().find(".dx-menu-items-container")}_searchActiveItem(e){return u(e).closest(".dx-menu-item").eq(0)}_isIncludeOverlay(e,t){let n=!1;return x(t,(o,s)=>{e.is(s)&&!n&&(n=!0)}),n}_hideAllShownChildSubmenus(e){let t=e.find(".dx-submenu"),n=m([],this._shownSubmenus);t.length>0&&x(n,(o,s)=>{let r=this._searchActiveItem(s.context).parent();r.parent().is(e.parent().parent())&&!r.is(e.parent())&&this._hideSubmenu(s)})}_initScrollable(e){this._createComponent(e,Pi,{useKeyboard:!1,_onVisibilityChanged:t=>{t.scrollTo(0)}})}_setSubMenuHeight(e,t,n){let o=e.find(".dx-menu-items-container"),s=X(o),r=this._getMaxHeight(t,!n),a=Math.min(s,r);e.css("height",n?a:"100%")}_getMaxHeight(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=X(oP),o=$t(e),s=w.getDocument(),r=e.length&&e[0]===s;if(!o||r)return n;let a=e[0].getBoundingClientRect().top,l=X(e);return(t?Math.max(a,n-a-l):Math.max(a+l,n-a))-10}_dimensionChanged(){this._shownSubmenus&&this._shownSubmenus.forEach(e=>{let t=e.closest(".dx-menu-item");this._setSubMenuHeight(e,t,!0),this._scrollToElement(t);let n=this._getSubmenuPosition(t);lt.setup(e,n)})}_getSubmenuBorderWidth(){return pt(ct())?0:1}_showSubmenu(e){let t=this._dataAdapter.getNodeByItem(this._getItemData(e));if(this._hideSubmenusOnSameLevel(e),!this._hasSubmenu(t))return;let n=e.children(".dx-submenu"),o=n.length;super._showSubmenu(e),o||(this._renderSubmenuItems(t,e),n=e.children(".dx-submenu")),this._setSubMenuHeight(n,e,!0),this._isSubmenuVisible(n)||this._drawSubmenu(e)}_hideSubmenusOnSameLevel(e){let t=e.parent(".dx-menu-item-wrapper").siblings().find(".dx-menu-item-expanded");t.length&&(t.removeClass("dx-menu-item-expanded"),this._hideSubmenu(t.find(".dx-submenu")))}_hideSubmenuGroup(e){this._isSubmenuVisible(e)&&this._hideSubmenuCore(e)}_isSubmenuVisible(e){return e.css("visibility")==="visible"}_drawSubmenu(e){let t=this.option("animation")?this.option("animation").show:{},n=e.children(".dx-submenu"),o=this._getSubmenuPosition(e);this._overlay&&this._overlay.option("visible")&&(f(this._shownSubmenus)||(this._shownSubmenus=[]),this._shownSubmenus.includes(n)||this._shownSubmenus.push(n),t&&pe.stop(n),lt.setup(n,o),t&&(q(t.to)&&(t.to.position=o),this._animate(n,t)),n.css("visibility","visible"))}_animate(e,t){pe.animate(e,t)}_getSubmenuPosition(e){let t=this.option("submenuDirection").toLowerCase(),o={collision:"flip",of:e.parent(".dx-menu-item-wrapper"),offset:{h:0,v:-1}};switch(t){case"left":o.at="left top",o.my="right top";break;case"right":o.at="right top",o.my="left top";break;default:this.option("rtlEnabled")?(o.at="left top",o.my="right top"):(o.at="right top",o.my="left top")}return o}_updateSubmenuVisibilityOnClick(e){if(!e.args.length)return;let{itemData:t}=e.args[0],n=this._dataAdapter.getNodeByItem(t);if(!n)return;let o=u(e.args[0].itemElement),s=o.find(".dx-submenu");if(this._hasSubmenu(n)&&!s.length&&(this._renderSubmenuItems(n,o),s=o.find(".dx-submenu")),o.context===s.context&&s.css("visibility")==="visible")return;this._updateSelectedItemOnClick(e);let a=t&&t.closeMenuOnClick===!1;if(!(!t||t.disabled||a))if(s.length===0){let l=u(o.parents(".dx-submenu")[0]);this._hideSubmenu(l),!e.canceled&&this._overlay&&this._overlay.option("visible")&&this.option("visible",!1)}else this._shownSubmenus&&this._shownSubmenus.length>0&&this._shownSubmenus[0].is(s)&&this._hideSubmenu(s),this._showSubmenu(o)}_hideSubmenu(e){let t=m([],this._shownSubmenus);x(t,(n,o)=>{(e.is(o)||on(e[0],o[0]))&&(o.parent().removeClass("dx-menu-item-expanded"),this._hideSubmenuCore(o))})}_hideSubmenuCore(e){let t=this._shownSubmenus.indexOf(e),n=this.option("animation")?this.option("animation").hide:null;t>=0&&this._shownSubmenus.splice(t,1),this._stopAnimate(e),n&&this._animate(e,n),e.css("visibility","hidden"),e.dxScrollable("instance").scrollTo(0),this.option("focusedElement",null)}_stopAnimate(e){pe.stop(e,!0)}_hideAllShownSubmenus(){let e=m([],this._shownSubmenus);this._overlay.$content().find(".dx-menu-item-expanded").removeClass("dx-menu-item-expanded"),x(e,(n,o)=>{this._hideSubmenu(o)})}_visibilityChanged(e){e&&this._renderContentImpl()}_optionChanged(e){if(nP.includes(e.name)){this._initActions();return}switch(e.name){case"visible":this._renderVisibility(e.value);break;case"showEvent":case"position":case"submenuDirection":this._invalidate();break;case"target":e.previousValue&&this._detachShowContextMenuEvents(e.previousValue),this._invalidate();break;case"closeOnOutsideClick":case"hideOnOutsideClick":break;default:super._optionChanged(e)}}_renderVisibility(e){return e?this._show():this._hide()}_toggleVisibility(){}_show(e){let t={jQEvent:e},n=y().reject().promise();if(this._actions.onShowing(t),t.cancel)return n;let o=this._positionContextMenu(e);if(o){var s;this._overlay||(this._renderContextMenuOverlay(),this._overlay.$content().addClass(this._widgetClass()),this._renderFocusState(),this._attachHoverEvents(),this._attachClickEvent(),this._renderItems(this._dataAdapter.getRootNodes()));let r=u(this._overlay.content()).children(".dx-submenu");this._setOptionWithoutOptionChange("visible",!0),this._overlay.option({height:()=>this._getMaxHeight(o.of),maxHeight:()=>{let a=r.find(".dx-menu-items-container"),l=this._getSubmenuBorderWidth();return X(a)+2*l},position:o}),r.length&&this._setSubMenuHeight(r,o.of,!1),n=this._overlay.show(),e&&e.stopPropagation(),this._setAriaAttributes(),(e==null||(s=e.originalEvent)===null||s===void 0?void 0:s.type)===an.name&&this.preventShowingDefaultContextMenuAboveOverlay()}return n}_renderItems(e,t){super._renderItems(e,t);let n=u(this._overlay.content()).children(".dx-submenu");n.length&&this._initScrollable(n)}_setAriaAttributes(){this._overlayContentId=`dx-${new Oe}`,this.setAria("owns",this._overlayContentId),this.setAria({id:this._overlayContentId,role:"menu"},this._overlay.$content())}_cleanAriaAttributes(){this._overlay&&this.setAria("id",null,this._overlay.$content()),this.setAria("owns",void 0)}_getTarget(){return this.option("target")||this.option("position").of||u(w.getDocument())}_getContextMenuPosition(){return m({},this.option("position"),{of:this._getTarget()})}_positionContextMenu(e){let t=this._getContextMenuPosition(),n=this._isInitialOptionValue("position"),o=this._createActionByOption("onPositioning");e&&e.preventDefault&&n&&(t.of=e);let s={position:t,event:e};return o(s),s.cancel?t=null:s.event&&(s.event.cancel=!0,e.preventDefault()),t}_refresh(){if(!W())super._refresh();else if(this._overlay){let e=this._overlay.option("position");super._refresh(),this._overlay&&this._overlay.option("position",e)}else super._refresh()}_hide(){let e;return this._overlay&&(e=this._overlay.hide(),this._setOptionWithoutOptionChange("visible",!1)),this._cleanAriaAttributes(),this.option("focusedElement",null),e||y().reject().promise()}toggle(e){let t=this.option("visible");return e=e===void 0?!t:e,this._renderVisibility(e)}show(){return this.toggle(!0)}hide(){return this.toggle(!1)}};G("dxContextMenu",kg);var Bg=kg;var Ob=Bg;var mY=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ti,Os,_x,HC,qe,ye,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ti,Os,_x,HC,ye]})}return i})();var Eb="dx-state-focused",fY="dx-cell-focus-disabled";var lP=".dx-datagrid-rowsview .dx-row",sP=`${lP} > td`,dP=".dx-treelist-rowsview .dx-row",rP=`${dP} > td`,aP={groupPanel:[".dx-datagrid-group-panel .dx-group-panel-item[tabindex]"],columnHeaders:[".dx-datagrid-headers .dx-header-row > td.dx-datagrid-action",".dx-treelist-headers .dx-header-row > td.dx-treelist-action"],filterRow:[".dx-datagrid-headers .dx-datagrid-filter-row .dx-editor-cell .dx-texteditor-input",".dx-treelist-headers .dx-treelist-filter-row .dx-editor-cell .dx-texteditor-input"],rowsView:[".dx-row-focused",`${lP}[tabindex]`,`${sP}[tabindex]`,`${sP}`,`${dP}[tabindex]`,`${rP}[tabindex]`,`${rP}`],footer:[".dx-datagrid-total-footer .dx-datagrid-summary-item",".dx-treelist-total-footer .dx-treelist-summary-item"],filterPanel:[".dx-datagrid-filter-panel .dx-icon-filter",".dx-treelist-filter-panel .dx-icon-filter"],pager:[".dx-datagrid-pager [tabindex]",".dx-treelist-pager [tabindex]"]},Sb=!1,Vg=!1,id=null;function _Y(i,e,t,n,o,s){if(xY(e,t.originalEvent,s))return;let a=De(t);a==="enter"||a==="space"?(wb(t.target,e),n&&n({event:t})):a==="tab"?o.addClass(Eb):nu(i,e,t)}function wb(i,e){let t=u(i),n=t.attr("aria-label"),s=cP(n,e.element()).index(t);id=m({},{ariaLabel:n,index:s},{viewInstance:e})}function cP(i,e){let t=u(e),n;if(i){let o=i?.replace(/\\/g,"\\\\").replace(/"/g,'\\"');n=t.find(`[aria-label="${o}"][tabindex]`)}else n=t.find("[tabindex]");return n}function CY(i,e){let t=e?.getRootNode()||w.getDocument();for(let n in i){let o=i[n],s=u(t).find(o).first();if(s.length)return s}}function xY(i,e,t){let n={event:e,handled:!1};return t?t(n):i._createActionByOption("onKeyDown")(n),n.handled}function uP(){Vg=w.getDocument().visibilityState==="visible"}function hP(){_.on(w.getDocument(),"visibilitychange",uP)}function Ib(){_.off(w.getDocument(),"visibilitychange",uP)}function pP(i,e){Vg=!0,i.focus({preventScroll:e}),Vg=!1}function Lg(i,e,t,n,o,s){if(e.option("useLegacyKeyboardNavigation"))return S;let r=()=>u(e.element()),a=c=>_Y(i,e,c,o,r(),s),l=()=>{Sb=!0,r().removeClass(Eb)},d=()=>{!Sb&&!Vg&&r().addClass(Eb),Sb=!1};return _.on(t,"keydown",n,a),_.on(t,"mousedown",n,l),_.on(t,"focusin",n,d),()=>{_.off(t,"keydown",n,a),_.off(t,"mousedown",n,l),_.off(t,"focusin",n,d)}}function nd(i){if(!i.option("useLegacyKeyboardNavigation")&&id){let e=id.viewInstance;if(e){let n=cP(id.ariaLabel,e.element()).eq(id.index);id=null,_.trigger(n,"focus")}}}function nu(i,e,t){let n=De(t);if(t.ctrlKey&&(n==="upArrow"||n==="downArrow")){let o=Object.keys(aP),s=o.indexOf(i);for(;s>=0&&s<o.length;){s=n==="upArrow"?--s:++s;let r=o[s],a=aP[r],l=CY(a,t.target);if(l&&l.length){l.attr("tabindex",e.option("tabindex")||0),_.trigger(l,"focus"),l.removeClass(fY);break}}}}function gP(i,e){i.option("useLegacyKeyboardnavigation")||e.attr("tabindex",i.option("tabindex")||0)}var Ir=function(i,e,t,n,o){let s=e.getController("keyboardNavigation");e.option("useLegacyKeyboardNavigation")||s&&!s.isKeyboardEnabled()||(e.createAction("onKeyDown"),Lg(i,e,t,n,o,r=>{e.executeAction("onKeyDown",r)}))};var mP=i=>class extends i{_applyColumnState(e){var t;let n=this.option("rtlEnabled"),o=this._getColumnAlignment(e.column.alignment,n),s=m(!0,{columnAlignment:o},e),r=s.rootElement.hasClass("dx-group-panel-item"),a=this._createIndicatorContainer(s,r),l=u("<span>").addClass(this._getIndicatorClassName(e.name)),d=(t=this.component)===null||t===void 0?void 0:t.getController("columns"),c=d?.getHeaderContentAlignment(o)||o;return s.container=a,s.indicator=l,this._renderIndicator(s),a[(r||!e.showColumnLines)&&c==="left"?"appendTo":"prependTo"](e.rootElement),l}_getIndicatorClassName(e){}_getColumnAlignment(e,t){return t=t||this.option("rtlEnabled"),e&&e!=="center"?e:Ui(t)}_createIndicatorContainer(e,t){let n=this._getIndicatorContainer(e.rootElement),o=e.columnAlignment==="left"?"right":"left";return n.length||(n=u("<div>").addClass("dx-column-indicators")),this.setAria("role","presentation",n),n.css("float",e.showColumnLines&&!t?o:null)}_getIndicatorContainer(e){return e&&e.find(".dx-column-indicators")}_getIndicatorElements(e){let t=this._getIndicatorContainer(e);return t&&t.children()}_renderIndicator(e){let t=e.container,n=e.indicator;t&&n&&t.append(n)}_updateIndicators(e){let t=this,n=t.getColumns(),o=t.getColumnElements(),s;if(!(!o||n.length!==o.length))for(let r=0;r<n.length;r++){s=o.eq(r),t._updateIndicator(s,n[r],e);let a=s.parent().data("options");a&&a.cells&&(a.cells[s.index()].column=n[r])}}_updateIndicator(e,t,n){if(!t.command)return this._applyColumnState({name:n,rootElement:e,column:t,showColumnLines:this.option("showColumnLines")})}};var vY=["rowsView"],Dr={borderedTop:"dx-bordered-top-view",borderedBottom:"dx-bordered-bottom-view"},bY=i=>{let{columnHeadersView:e,rowsView:t}=i;return e!=null&&e.isVisible()?e.element():t.element()},yY=i=>{let{filterPanelView:e,footerView:t,rowsView:n}=i;return e!=null&&e.isVisible()?e.element():t!=null&&t.isVisible()?t.element():n.element()},fP=(i,e)=>{let t=Object.values(i).find(n=>{var o;return n==null||(o=n.element())===null||o===void 0?void 0:o.hasClass(e)});return t?.element()??null},OY=(i,e)=>{var t;if(!Object.keys(e).includes(i))return!1;let{rowsView:n}=e,o=ge(e,vY);return f(n==null||(t=n.element)===null||t===void 0?void 0:t.call(n))?Object.values(o).filter(s=>{var r;return s==null||(r=s.isVisible)===null||r===void 0?void 0:r.call(s)}).every(s=>f(s?.element())):!1},_P=(i,e)=>{if(!OY(i,e))return;let t=fP(e,Dr.borderedTop),n=fP(e,Dr.borderedBottom),o=bY(e),s=yY(e);t&&!t.is(o)&&t.removeClass(Dr.borderedTop),n&&!n.is(s)&&n.removeClass(Dr.borderedBottom),o.hasClass(Dr.borderedTop)||o.addClass(Dr.borderedTop),s.hasClass(Dr.borderedBottom)||s.addClass(Dr.borderedBottom)};var Ng=class{constructor(e){let t=this;t._updateLockCount=0,t.component=e,t._actions={},t._actionConfigs={},x(this.callbackNames()||[],function(n,o){let s=t.callbackFlags(o)||{};s.unique=!0,s.syncStrategy=!0,t[this]=ue(s)})}_endUpdateCore(){}init(){}callbackNames(){}callbackFlags(e){}publicMethods(){return[]}beginUpdate(){this._updateLockCount++}endUpdate(){this._updateLockCount>0&&(this._updateLockCount--,this._updateLockCount||this._endUpdateCore())}option(e){let{component:t}=this,n=t._optionCache;return arguments.length===1&&n?(e in n||(n[e]=t.option(e)),n[e]):t.option.apply(t,arguments)}_silentOption(e,t){let{component:n}=this,o=n._optionCache;return o&&(o[e]=t),n._setOptionWithoutOptionChange(e,t)}localize(e){let t=this.component._optionCache;return t?(e in t||(t[e]=O.format(e)),t[e]):O.format(e)}on(e,t){return this.component.on.apply(this.component,arguments)}off(){return this.component.off.apply(this.component,arguments)}optionChanged(e){e.name in this._actions&&(this.createAction(e.name,this._actionConfigs[e.name]),e.handled=!0)}getAction(e){return this._actions[e]}setAria(e,t,n){let o=n.get(0),s=e!=="role"&&e!=="id"?"aria-":"";o.setAttribute?o.setAttribute(s+e,t):n.attr(s+e,t)}_createComponent(e,t,n){return this.component._createComponent(e,t,n)}getController(e){return this.component._controllers[e]}createAction(e,t){if(A(e)){let n=this.component._createAction(e.bind(this),t);return function(o){n({event:o})}}this._actions[e]=this.component._createActionByOption(e,t),this._actionConfigs[e]=t}executeAction(e,t){let n=this._actions[e];return n&&n(t)}dispose(){let e=this;x(e.callbackNames()||[],function(){e[this].empty()})}addWidgetPrefix(e){return`dx-${this.component.NAME.slice(2).toLowerCase()}${e?`-${e}`:""}`}getWidgetContainerClass(){let e=this.component.NAME==="dxDataGrid"?null:"container";return this.addWidgetPrefix(e)}elementIsInsideGrid(e){return e.closest(`.${this.getWidgetContainerClass()}`).parent().is(this.component.$element())}},ou=class extends Ng{},Tb=class extends ou{getView(e){return this.component._views[e]}getViews(){return this.component._views}},Hg=class extends Ng{constructor(e){super(e),this.renderCompleted=ue(),this.resizeCompleted=ue()}_isReady(){return this.component.isReady()}_endUpdateCore(){super._endUpdateCore(),!this._isReady()&&this._requireReady&&(this._requireRender=!1,this.component._requireResize=!1),this._requireRender&&(this._requireRender=!1,this.render(this._$parent))}_invalidate(e,t){this._requireRender=!0,this.component._requireResize=W()&&(this.component._requireResize||e),this._requireReady=this._requireReady||t}_renderCore(e){}_resizeCore(){}_parentElement(){return this._$parent}element(){return this._$element}getElementHeight(){let e=this.element();if(!e)return 0;let t=parseFloat(e.css("marginTop"))||0,n=parseFloat(e.css("marginBottom"))||0,{offsetHeight:o}=e.get(0);return o+t+n}isVisible(){return!0}getTemplate(e){return this.component._getTemplate(e)}getView(e){return this.component._views[e]}_getBorderedViews(){return{columnHeadersView:this.component._views.columnHeadersView,rowsView:this.component._views.rowsView,filterPanelView:this.component._views.filterPanelView,footerView:this.component._views.footerView}}render(e,t){let n=this._$element,o=this.isVisible();if(!(!n&&!e)&&(this._requireReady=!1,n||(n=this._$element=u("<div>").appendTo(e),this._$parent=e),n.toggleClass("dx-hidden",!o),this.component._views&&_P(this.name,this._getBorderedViews()),o)){this.component._optionCache={};let s=this._renderCore(t);this.component._optionCache=void 0,s?s.done(()=>{this.renderCompleted.fire(t)}):this.renderCompleted.fire(t)}}resize(){this.isResizing=!0,this._resizeCore(),this.resizeCompleted.fire(),this.isResizing=!1}focus(e){this.element().get(0).focus({preventScroll:e})}};function CP(i){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t={};return Object.entries(e).forEach(n=>{let[o,s]=n,r=i[o];if(r)if(A(s))t[o]=s(r);else{let a=r;t[o]=a.inherit(s)}}),t}function SY(i,e,t){let n=t.publicMethods();n&&x(n,(o,s)=>{if(t[s])if(!i[s])i[s]=function(){return t[s](...arguments)};else throw Z.Error("E1005",s);else throw Z.Error("E1006",e,s)})}function EY(i,e){let{modules:t}=e,{modulesOrder:n}=e;function o(c){let h={};return x(c,(p,g)=>{let C=new g(i);C.name=p,SY(i,p,C),h[p]=C}),h}n&&t.sort((c,h)=>{let p=n.indexOf(c.name),g=n.indexOf(h.name);return p<0&&(p=1e6),g<0&&(g=1e6),p-g});let s={},r={};t.forEach(c=>{let{name:h,controllers:p={},views:g={}}=c;Object.entries(p).forEach(C=>{let[v,b]=C;if(s[v])throw Z.Error("E1001",h,v);if(!(b?.prototype instanceof ou))throw Z.Error("E1002",h,v);s[v]=b}),Object.entries(g).forEach(C=>{let[v,b]=C;if(r[v])throw Z.Error("E1003",h,v);if(!(b?.prototype instanceof Hg))throw Z.Error("E1004",h,v);r[v]=b})});let a=t.filter(c=>{let{extenders:h}=c;return!!h}),l=a.reduce((c,h)=>{let{extenders:p}=h;return I({},c,CP(c,p?.controllers))},s),d=a.reduce((c,h)=>{let{extenders:p}=h;return I({},c,CP(c,p?.views))},r);i._controllers=o(l),i._views=o(d)}var wY=function(i,e,t){t=t||[],i._controllers&&x(i._controllers,function(){this[e]&&this[e].apply(this,t)}),i._views&&x(i._views,function(){this[e]&&this[e].apply(this,t)})},Ce={modules:[],View:Hg,ViewController:Tb,Controller:ou,registerModule(i,e){let{modules:t}=this;for(let n=0;n<t.length;n++)if(t[n].name===i)return;e.name=i,t.push(e)},registerModulesOrder(i){this.modulesOrder=i},unregisterModule(i){this.modules=xt(this.modules,e=>e.name!==i)},processModules:EY,callModuleItemsMethod:wY};var IY=["year","month","day"],DY=["year","month","day","hour","minute"],Mb=function(i){return i==="date"||i==="datetime"},Ab=function(i){let e,t=[],n=["year","month","day","hour","minute","second"],o=i.headerFilter&&i.headerFilter.groupInterval,s=o==="quarter"?"month":o;if(Mb(i.dataType)&&o!==null)return t=i.dataType==="datetime"?DY:IY,e=n.indexOf(s),e>=0&&(t=n.slice(0,e),t.push(o)),t;if(f(o))return Array.isArray(o)?o:[o]},Jn=function(){let i=function(o,s){let r=o.dataField||o.selector;return s==="search"&&(r=o.displayField||o.calculateDisplayValue||r),r},e=function(o,s){let r=this,a,l,d,c=i(r,s);if(Array.isArray(o)&&f(o[0])&&f(o[1]))return l=[c,">=",o[0]],d=[c,"<=",o[1]],Mb(r.dataType)&&(h=o[1],h.getHours()+h.getMinutes()+h.getSeconds()+h.getMilliseconds()<1)&&(a=new Date(o[1].getTime()),r.dataType==="date"&&a.setDate(o[1].getDate()+1),d=[c,"<",a]),[l,"and",d];var h},t=function(o,s,r){let a=this,l,d,c,h=function(g){return Et(g)?[g.getFullYear(),g.getMonth(),g.getDate(),g.getHours(),g.getMinutes(),g.getSeconds()]:He((""+g).split("/"),function(C,v){return v===1?Number(C)-1:Number(C)})}(o),p=i(a,r);switch(r==="headerFilter"?c=Ab(a)[h.length-1]:a.dataType==="datetime"&&(c="minute"),c){case"year":l=new Date(h[0],0,1),d=new Date(h[0]+1,0,1);break;case"month":l=new Date(h[0],h[1],1),d=new Date(h[0],h[1]+1,1);break;case"quarter":l=new Date(h[0],3*h[1],1),d=new Date(h[0],3*h[1]+3,1);break;case"hour":l=new Date(h[0],h[1],h[2],h[3]),d=new Date(h[0],h[1],h[2],h[3]+1);break;case"minute":l=new Date(h[0],h[1],h[2],h[3],h[4]),d=new Date(h[0],h[1],h[2],h[3],h[4]+1);break;case"second":l=new Date(h[0],h[1],h[2],h[3],h[4],h[5]),d=new Date(h[0],h[1],h[2],h[3],h[4],h[5]+1);break;default:l=new Date(h[0],h[1],h[2]),d=new Date(h[0],h[1],h[2]+1)}switch(s){case"<":return[p,"<",l];case"<=":return[p,"<",d];case">":return[p,">=",d];case">=":return[p,">=",l];case"<>":return[[p,"<",l],"or",[p,">=",d]];default:return[[p,">=",l],"and",[p,"<",d]]}},n=function(o,s,r){let a=i(this,r),l=Ab(this);if(r==="headerFilter"&&l&&f(o)){let d=(""+o).split("/"),c=Number(d[d.length-1]),h=l[d.length-1],p=[a,">=",c],g=[a,"<",c+h];return[p,"and",g]}return[a,s||"=",o]};return{defaultCalculateFilterExpression:function(o,s,r){let a=this,l=i(a,r),d=a.calculateDisplayValue&&r==="search",c=d&&a.lookup&&a.lookup.dataType||a.dataType,h=null;if((r==="headerFilter"||r==="filterBuilder")&&o===null)h=[l,s||"=",null],c==="string"&&(h=[h,s==="="?"or":"and",[l,s||"=",""]]);else if(c==="string"&&(!a.lookup||d))h=[l,s||"contains",o];else{if(s==="between")return e.apply(a,[o,r]);if(Mb(c)&&f(o))return t.apply(a,arguments);if(c==="number")return n.apply(a,arguments);h=[l,s||"=",o]}return h},getGroupInterval:Ab}}();var TY="scrolling.legacyMode";var AY="scrolling.rowRenderingMode",MY={year:i=>i&&i.getFullYear(),month:i=>i&&i.getMonth()+1,day:i=>i&&i.getDate(),quarter:i=>i&&Math.floor(i.getMonth()/3)+1,hour:i=>i&&i.getHours(),minute:i=>i&&i.getMinutes(),second:i=>i&&i.getSeconds()},RY=function(){let i=arguments[1],e=this.calculateCellValue(i);if(!f(e))return null;if(OP(this.dataType)){let t=arguments[0];return MY[t](e)}if(this.dataType==="number"){let t=arguments[0];return Math.floor(Number(e)/t)*t}},FY=function(i,e){return A(i)&&A(e)&&i.originalCallback&&e.originalCallback?i.originalCallback===e.originalCallback&&i.columnIndex===e.columnIndex:i===e};function OP(i){return i==="date"||i==="datetime"}var xP=function(i){i.get(0).textContent="\xA0"},Rb=function(i){i=i||[];let e=rn(i);for(let t=0;t<i.length;t++)i&&i[t]&&i[t].isExpanded!==void 0&&(e[t].isExpanded=i[t].isExpanded),i&&i[t]&&i[t].groupInterval!==void 0&&(e[t].groupInterval=i[t].groupInterval);return e},SP=function(i,e){let t=Ig.format(i,e.format)||i&&i.toString()||"",n={value:i,valueText:e.getDisplayFormat?e.getDisplayFormat(t):t,target:e.target||"row",groupInterval:e.groupInterval};return e.customizeText?e.customizeText.call(e,n):n.valueText},vP=function(i,e){let t=i.displayFormat||i.columnCaption&&e[`${i.summaryType}OtherColumn`]||e[i.summaryType];return SP(i.value,{format:i.valueFormat,getDisplayFormat:n=>t?Ii(t,n,i.columnCaption):n,customizeText:i.customizeText})},bP=function(i){let e=i.data&&i.data(),t=e&&e.dxComponents,n=t&&t[0];return n&&e[n]},EP=function(i,e){if(Array.isArray(i)&&Array.isArray(e)){if(i.length!==e.length)return!1;for(let t=0;t<i.length;t++)if(!EP(i[t],e[t]))return!1;return!0}return A(i)&&i.columnIndex>=0&&A(e)&&e.columnIndex>=0?i.columnIndex===e.columnIndex&&Ot(i.filterValue)===Ot(e.filterValue)&&Ot(i.selectedFilterOperation)===Ot(e.selectedFilterOperation):Ot(i)==Ot(e)},PY=i=>({index:i.index,columnIndex:i.columnIndex,x:i.x,y:i.y}),yP=(i,e,t)=>{let n=!1;if(t&&(n=t(e)),!n){let o=PY(e);i.push(o)}};function kY(i){return Array.isArray(i)||(i=[i]),i.map((e,t)=>B(e)?{selector:e,isExpanded:t<i.length-1}:e)}var M={renderNoDataText(i){let e=this;if(i=i||this.element(),!i)return;let t=e.addWidgetPrefix("nodata"),n=i.find(`.${t}`).last(),o=this._dataController.isEmpty(),s=this._dataController.isLoading();n.length||(n=u("<span>").addClass(t)),n.parent().is(i)||n.appendTo(i),o&&!s?n.removeClass("dx-hidden").text(e._getNoDataText()):n.addClass("dx-hidden")},renderLoadPanel(i,e,t){let n=this,o;n._loadPanel&&n._loadPanel.$element().remove(),o=n.option("loadPanel"),o&&(o.enabled==="auto"?!t:o.enabled)?(o=m({shading:!1,message:o.text,container:e},o),n._loadPanel=n._createComponent(u("<div>").appendTo(e),Bp,o)):n._loadPanel=null},calculateLoadPanelPosition(i){let e=u(K());return Y(i)>Y(e)?{of:e,boundary:i,collision:"fit"}:{of:i}},getIndexByKey(i,e,t){let n=-1;if(i!==void 0&&Array.isArray(e)){t=arguments.length<=2?"key":t;for(let o=0;o<e.length;o++){let s=f(t)?e[o][t]:e[o];if(ve(i,s)){n=o;break}}}return n},combineFilters(i,e){let t=[];e=e||"and";for(let o=0;o<i.length;o++){var n;if(i[o]){if(((n=i[o])===null||n===void 0?void 0:n.length)===1&&i[o][0]==="!"){if(e==="and")return["!"];if(e==="or")continue}t.length&&t.push(e),t.push(i[o])}}if(t.length===1&&(t=t[0]),t.length)return t},checkChanges(i,e){let t=0;for(let n=0;n<e.length;n++)i[e[n]]&&t++;return i.length&&i.length===t},equalFilterParameters:EP,proxyMethod(i,e,t){i[e]||(i[e]=function(){let n=this._dataSource;return n?n[e].apply(n,arguments):t})},formatValue:SP,getFormatOptionsByColumn:(i,e)=>({format:i.format,getDisplayFormat:i.getDisplayFormat,customizeText:i.customizeText,target:e,trueText:i.trueText,falseText:i.falseText}),getDisplayValue(i,e,t,n){return i.displayValueMap&&i.displayValueMap[e]!==void 0?i.displayValueMap[e]:i.calculateDisplayValue&&t&&n!=="group"?i.calculateDisplayValue(t):i.lookup&&!(n==="group"&&(i.calculateGroupValue||i.calculateDisplayValue))?i.lookup.calculateCellValue(e):e},getGroupRowSummaryText(i,e){let t="(";for(let n=0;n<i.length;n++){let o=i[n];t+=(n>0?", ":"")+vP(o,e)}return t+")"},getSummaryText:vP,normalizeSortingInfo:Rb,getFormatByDataType(i){switch(i){case"date":return"shortDate";case"datetime":return"shortDateShortTime";default:return}},getHeaderFilterGroupParameters(i,e){let t=[],n=i.dataField||i.name,o=Jn.getGroupInterval(i);return o?(x(o,(s,r)=>{t.push(e?{selector:n,groupInterval:r,isExpanded:s<o.length-1}:RY.bind(i,r))}),t):(e?t=[{selector:n,isExpanded:!1}]:(t=function(s){let r=i.calculateCellValue(s);return(r===void 0||r==="")&&(r=null),r},i.sortingMethod&&(t=[{selector:t,compare:i.sortingMethod.bind(i)}])),t)},equalSortParameters(i,e,t){if(i=Rb(i),e=Rb(e),Array.isArray(i)&&Array.isArray(e)){if(i.length!==e.length)return!1;for(let n=0;n<i.length;n++)if(!FY(i[n].selector,e[n].selector)||i[n].desc!==e[n].desc||i[n].groupInterval!==e[n].groupInterval||!t&&!!i[n].isExpanded!=!!e[n].isExpanded)return!1;return!0}return(!i||!i.length)==(!e||!e.length)},getPointsByColumns(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,s=[],r=i.length,a,l={left:0,top:0},d={width:0,height:0},c=n,h;for(let g=0;g<=r;g++){var p;g<r&&(a=i.eq(g),l=a.offset(),d=Ie(a.get(0)),h=a.css("direction")==="rtl");let C=l.left+d.width,v=l.top+d.height,b={index:c,columnIndex:c,item:(p=a)===null||p===void 0?void 0:p.get(0),x:!t&&h!==(g===r)?C:l.left,y:t&&g===r?v:l.top};if(!t&&g>0){let T=i.eq(g-1).offset(),{width:R}=Ie(i[g-1]),U=h?T.left:T.left+R;if(T.top<b.y&&(b.y=T.top),o&&Math.round(U)!==Math.round(b.x)){let Q=I({},b,{item:i[g-1],x:U});h?(b.isRightBoundary=!0,Q.isLeftBoundary=!0):(b.isLeftBoundary=!0,Q.isRightBoundary=!0),yP(s,Q,e)}}yP(s,b,e),c++}return s},getExpandCellTemplate:()=>({allowRenderToDetachedContainer:!0,render(i,e){let t=u(i);if(f(e.value)&&!(e.data&&e.data.isContinuation)&&!e.row.isNewRow){let n=e.component.getView("rowsView");t.addClass("dx-datagrid-expand").addClass("dx-selection-disabled"),u("<div>").addClass(e.value?"dx-datagrid-group-opened":"dx-datagrid-group-closed").appendTo(t),n.setAria("label",e.value?n.localize("dxDataGrid-ariaCollapse"):n.localize("dxDataGrid-ariaExpand"),t)}else xP(t)}}),setEmptyText:xP,isDateType:OP,getSelectionRange(i){try{if(i)return{selectionStart:i.selectionStart,selectionEnd:i.selectionEnd}}catch{}return{}},setSelectionRange(i,e){try{i&&i.setSelectionRange&&i.setSelectionRange(e.selectionStart,e.selectionEnd)}catch{}},focusAndSelectElement(i,e){let t=e.is(":focus");_.trigger(e,"focus");let n=i.option("editing.selectTextOnEditStart"),o=e.get(0);if(!t&&n&&e.is(".dx-texteditor-input")&&!e.is("[readonly]")){let s=bP(e.closest(".dx-texteditor"));P(s&&s._loadItemDeferred).done(()=>{o.select()})}},getWidgetInstance:bP,getLastResizableColumnIndex(i,e){let t=i.some(o=>o&&!o.command&&!o.fixed&&o.allowResizing!==!1),n;for(n=i.length-1;i[n];n--){let o=i[n],s=e&&e[n],r=!t||o.allowResizing!==!1;if(!o.command&&!o.fixed&&s!=="adaptiveHidden"&&r)break}return n},isElementInCurrentGrid(i,e){return e&&e.length?e.closest(`.${i.getWidgetContainerClass()}`).parent().is(i.component.$element()):!1},isVirtualRowRendering(i){let e=i.option(AY),t=i.option("scrolling.mode")==="virtual",n=i.option("scrolling.mode")==="infinite";return i.option(TY)===!1&&(t||n)?!0:e==="virtual"},getPixelRatio:i=>i.devicePixelRatio||1,getContentHeightLimit(i){return i.mozilla?8e6:15e6/this.getPixelRatio(K())},normalizeLookupDataSource(i){let e;return i.items?e=i.items:(e=i.dataSource,A(e)&&!It.isWrapped(e)&&(e=e({}))),Yi(e)},getWrappedLookupDataSource(i,e,t){if(!e)return[];let n=this.normalizeLookupDataSource(i.lookup);if(i.calculateCellValue!==i.defaultCalculateCellValue)return n;let o=e.remoteOperations().groupPaging,s=i.displayField&&B(i.displayField),r,a,l,d=(h,p)=>{let g=p.skip??0,C=p.take?g+p.take:h.length;return h.slice(g,C)};return I({},n,{__dataGridSourceFilter:t,load:h=>{let p=new y;return(g=>{let C=kY(s?[i.dataField,i.displayField]:i.dataField),v=new y;return r&&(!o||g.skip===l&&g.take===a)?v.resolve(d(r,g)):(l=g.skip,a=g.take,e.load({filter:t,group:C,take:o?g.take:void 0,skip:o?g.skip:void 0}).done(T=>{r=T,v.resolve(o?T:d(T,g))}).fail(v.fail)),v})(h).done(g=>{if(g.length===0){p.resolve([]);return}let C=this.combineFilters(g.flatMap(b=>b.key).map(b=>[i.lookup.valueExpr,b]),"or");new jt(I({},n,h,{filter:this.combineFilters([C,h.filter],"and"),paginate:!1})).load().done(p.resolve).fail(p.fail)}).fail(p.fail),p},key:i.lookup.valueExpr,byKey(h){let p=y();return this.load({filter:[i.lookup.valueExpr,"=",h]}).done(g=>{p.resolve(g[0])}),p.promise()}})},logHeaderFilterDeprecatedWarningIfNeed(i){let e=i._logDeprecatedOptionWarning.bind(i);f(i.option("headerFilter.allowSearch"))&&e("headerFilter.allowSearch",{since:"23.1",alias:"headerFilter.search.enabled"}),f(i.option("headerFilter.searchTimeout"))&&e("headerFilter.searchTimeout",{since:"23.1",alias:"headerFilter.search.timeout"});let t=i.NAME==="dxPivotGrid"?"dataSource.fields":"columns",n=i.option(t);if(!Array.isArray(n))return;let o=s=>{s.forEach(r=>{var a;let l=r.headerFilter||{};f(l.allowSearch)&&e(`${t}[].headerFilter.allowSearch`,{since:"23.1",alias:`${t}[].headerFilter.search.enabled`}),f(l.searchMode)&&e(`${t}[].headerFilter.searchMode`,{since:"23.1",alias:`${t}[].headerFilter.search.mode`}),(a=r.columns)!==null&&a!==void 0&&a.length&&o(r.columns)})};o(n)}};var Fb="dx-master-detail-row";var Pb="dxCellHintVisible";var BY={render(i){i.container.append(i.content)}},VY=function(i,e){let t,n,o;function s(r){return setTimeout(()=>{t=n=null},r)}_.on(e,"touchstart touchend",".dx-row",r=>{clearTimeout(o),r.type==="touchstart"?(t=r.target,n=r.currentTarget,o=s(1e3)):o=s()}),_.on(e,[oe,Hs,ne.down].join(" "),".dx-row",i.createAction(r=>{let{event:a}=r;t&&(a.target=t,a.currentTarget=n),u(a.target).closest("a").length||(r.rowIndex=i.getRowIndex(a.currentTarget),r.rowIndex>=0&&(r.rowElement=N(u(a.currentTarget)),r.columns=i.getColumns(),a.type===ne.down?i._rowPointerDown(r):a.type===oe?i._rowClick(r):i._rowDblClick(r)))}))},$g=function(i){return i==="auto"?"":xe(i)?`${i}px`:i},wP=function(i,e,t){i.style.width=i.style.maxWidth=e.width==="auto"?"":t},LY=function(i,e){if(!i||!e)return;let t=i.attributes,n=e.attributes,o;for(o=0;o<t.length;o++){let s=t[o].nodeName;e.hasAttribute(s)||i.removeAttribute(s)}for(o=0;o<n.length;o++)i.setAttribute(n[o].nodeName,n[o].nodeValue)},NY=function(i){i.resolve()},kb=i=>typeof i=="number"?`${i.toFixed(3)}px`:i==="adaptiveHidden"?"0.0001px":i,eo=class extends mP(Ce.View){init(){this._scrollLeft=-1,this._columnsController=this.getController("columns"),this._dataController=this.getController("data"),this._adaptiveColumnsController=this.getController("adaptiveColumns"),this._columnChooserController=this.getController("columnChooser"),this._editorFactoryController=this.getController("editorFactory"),this._selectionController=this.getController("selection"),this._columnChooserView=this.getView("columnChooserView"),this._delayedTemplates=[],this._templateDeferreds=new Set,this._templatesCache={},this._templateTimeouts=new Set,this.createAction("onCellClick"),this.createAction("onRowClick"),this.createAction("onCellDblClick"),this.createAction("onRowDblClick"),this.createAction("onCellHoverChanged",{excludeValidators:["disabled","readOnly"]}),this.createAction("onCellPrepared",{excludeValidators:["disabled","readOnly"],category:"rendering"}),this.createAction("onRowPrepared",{excludeValidators:["disabled","readOnly"],category:"rendering",afterExecute:e=>{this._afterRowPrepared(e)}}),this._columnsController.columnsChanged.add(this._columnOptionChanged.bind(this)),this._dataController&&this._dataController.changed.add(this._handleDataChanged.bind(this))}dispose(){if(W()){var e,t;let n=K();(e=this._templateTimeouts)===null||e===void 0||e.forEach(o=>n.clearTimeout(o)),(t=this._templateTimeouts)===null||t===void 0||t.clear()}}optionChanged(e){switch(super.optionChanged(e),e.name){case"cellHintEnabled":case"onCellPrepared":case"onRowPrepared":case"onCellHoverChanged":this._invalidate(!0,!0),e.handled=!0;break;case"keyboardNavigation":e.fullName==="keyboardNavigation.enabled"&&this._invalidate(!0,!0),e.handled=!0}}_createScrollableOptions(){let e=this.option("scrolling"),t=this.option("scrolling.useNative"),n=m({},e,{direction:"both",bounceEnabled:!1,useKeyboard:!1});return t===void 0&&(t=!0),t==="auto"?(delete n.useNative,delete n.useSimulatedScrollbar):(n.useNative=!!t,n.useSimulatedScrollbar=!t),n}_updateCell(e,t){t.rowType&&this._cellPrepared(e,t)}_needToSetCellWidths(){return this.option("columnAutoWidth")}_createCell(e){let{column:t}=e,n=t.alignment||Ui(this.option("rtlEnabled")),o=this._needToSetCellWidths(),s=w.createElement("td");s.style.textAlign=n;let r=u(s);return e.rowType==="data"&&t.headerId&&!t.type&&this.component.option("showColumnHeaders")&&this.setAria("describedby",t.headerId,r),t.cssClass&&r.addClass(t.cssClass),Array.isArray(t.elementAttr)&&t.elementAttr.forEach(a=>{let{name:l,value:d}=a;r.attr(l,d)}),t.command==="expand"&&(r.addClass(t.cssClass),r.addClass(this.addWidgetPrefix("group-space"))),t.colspan>1?r.attr("colSpan",t.colspan):!t.isBand&&t.visibleWidth!=="auto"&&o&&((t.width||t.minWidth)&&(s.style.minWidth=$g(t.minWidth||t.width)),t.width&&wP(s,t,$g(t.width))),r}_createRow(e,t){t=t||"tr";let n=u(`<${t}>`).addClass("dx-row");return t==="tr"&&this.setAria("role","row",n),n}_isAltRow(e){return e&&e.dataIndex%2===1}_createTable(e,t){let n=u("<table>").addClass(this.addWidgetPrefix("table")).addClass(this.addWidgetPrefix("table-fixed"));if(e&&!t?(n.attr("id",`dx-${new Oe}`).append(this._createColGroup(e)),be.safari&&n.append(u("<thead>").append("<tr>")),this.setAria("role","presentation",n)):this.setAria("hidden",!0,n),this.setAria("role","presentation",u("<tbody>").appendTo(n)),t)return n;be.mozilla&&_.on(n,"mousedown","td",s=>{s.ctrlKey&&s.preventDefault()}),this.option("cellHintEnabled")&&_.on(n,"mousemove",".dx-row > td",this.createAction(s=>{let r=s.event,a=u(r.target),l=u(r.currentTarget),d=l.parent(),c=this._columnsController.getVisibleColumns(),h=d.data("options"),p=l.index(),g=h&&h.cells&&h.cells[p],C=g?g.column:c[p],v=d.hasClass("dx-header-row"),b=d.hasClass("dx-data-row"),T=d.hasClass(Fb),R=d.hasClass("dx-group-row"),U=d.hasClass(this.addWidgetPrefix("filter-row")),Q=b&&(!C||C.cellTemplate),se=b&&g&&(h.isEditing||g.isEditing||C?.showEditorAlways),re=v&&(!C||C.headerCellTemplate),Re=R&&(!C||C.groupIndex&&C.groupCellTemplate);!T&&!U&&!se&&!Q&&!re&&!Re&&(a.data(Pb)&&(a.removeAttr("title"),a.data(Pb,!1)),a[0].scrollWidth-a[0].clientWidth>0&&!f(a.attr("title"))&&(a.attr("title",a.text()),a.data(Pb,!0)))}));let o=s=>{let r=u(s.currentTarget),a=u(s.target).closest(".dx-field-item-content"),l=r.parent(),d=l.data("options"),c=d&&d.cells&&d.cells[r.index()];if(!r.closest("table").is(s.delegateTarget))return;let h=m({},c,{cellElement:N(r),event:s,eventType:s.type});if(h.rowIndex=this.getRowIndex(l),a.length){let p=a.data("dx-form-item");p.column&&(h.column=p.column,h.columnIndex=this._columnsController.getVisibleIndex(h.column.index))}return h};return _.on(n,"mouseover",".dx-row > td",s=>{let r=o(s);r&&this.executeAction("onCellHoverChanged",r)}),_.on(n,"mouseout",".dx-row > td",s=>{let r=o(s);r&&this.executeAction("onCellHoverChanged",r)}),_.on(n,oe,".dx-row > td",s=>{let r=o(s);r&&this.executeAction("onCellClick",r)}),_.on(n,Hs,".dx-row > td",s=>{let r=o(s);r&&this.executeAction("onCellDblClick",r)}),VY(this,n),n}_rowPointerDown(e){}_rowClick(){}_rowDblClick(){}_createColGroup(e){let t=u("<colgroup>");for(let n=0;n<e.length;n++){let o=e[n].colspan||1;for(let s=0;s<o;s++)t.append(this._createCol(e[n]))}return t}_createCol(e){let t=e.visibleWidth||e.width;t==="adaptiveHidden"&&(t="0.0001px");let n=u("<col>");return $d(n,t),n}renderDelayedTemplates(e){let t=this._delayedTemplates,n=t.filter(s=>!s.async),o=t.filter(s=>s.async);this._delayedTemplates=[],this._renderDelayedTemplatesCore(n,!1,e),this._renderDelayedTemplatesCoreAsync(o)}_renderDelayedTemplatesCoreAsync(e){if(e.length){let t=K().setTimeout(()=>{this._templateTimeouts.delete(t),this._renderDelayedTemplatesCore(e,!0)});this._templateTimeouts.add(t)}}_renderDelayedTemplatesCore(e,t,n){let o=new Date;for(;e.length;){let s=e.shift(),{options:r}=s,a=w.getRootNode(u(r.container).get(0)),l=this.needWaitAsyncTemplates();if((!t||u(r.container).closest(a).length||l)&&(n&&(r.change=n),s.template.render(r)),t&&new Date-o>30){this._renderDelayedTemplatesCoreAsync(e);break}}!e.length&&this._delayedTemplates.length&&this.renderDelayedTemplates()}_processTemplate(e,t){let n=this,o;if(e&&e.render&&!$t(e))o={allowRenderToDetachedContainer:e.allowRenderToDetachedContainer,render(s){e.render(s.container,s.model,s.change),s.deferred&&s.deferred.resolve()}};else if(A(e))o={render(s){let r=e(N(s.container),s.model,s.change);r&&(r.nodeType||$t(r))&&s.container.append(r),s.deferred&&s.deferred.resolve()}};else{let s=B(e)?e:u(e).attr("id");s?(n._templatesCache[s]||(n._templatesCache[s]=n.getTemplate(e)),o=n._templatesCache[s]):o=n.getTemplate(e)}return o}renderTemplate(e,t,n,o,s){let r=this._processTemplate(t,n),{column:a}=n,l=n.rowType==="data",d=new y,c={container:e,model:n,deferred:d,onRendered:()=>{this.isDisposed()?d.reject():d.resolve()}};if(r){n.component=this.component;let h=a&&(a.renderAsync&&l||this.option("renderAsync")&&(a.renderAsync!==!1&&(a.command||a.showEditorAlways)&&l||n.rowType==="filter")),p=n.renderAsync??h;(r.allowRenderToDetachedContainer||o)&&!p?r.render(c):this._delayedTemplates.push({template:r,options:c,async:p}),this._templateDeferreds.add(d),_.on(e,Gt,NY.bind(null,d))}else d.reject();return d.promise().always(()=>{this._templateDeferreds.delete(d)})}_getBodies(e){return u(e).children("tbody").not(".dx-header").not(".dx-footer")}_needWrapRow(e){var t;return!!this.option().rowTemplate&&!!((t=this._getBodies(e))!==null&&t!==void 0&&t.filter(".dx-row").length)}_wrapRowIfNeed(e,t,n){let o=n?e||this._tableElement:this._tableElement||e;if(this._needWrapRow(o)){let r=u("<tbody>").addClass(t.attr("class"));return this.setAria("role","presentation",r),r.append(t)}return t}_appendRow(e,t,n){n=n||BY,n.render({content:t,container:e})}_resizeCore(){let e=this._scrollLeft;e>=0&&(this._scrollLeft=0,this.scrollTo({left:e}))}_renderCore(e){let t=this.element().parent();(!t||t.parent().length)&&this.renderDelayedTemplates(e)}_renderTable(e){e=e||{},e.columns=this._columnsController.getVisibleColumns();let t=e.change&&e.change.changeType,n=this._createTable(e.columns,t==="append"||t==="prepend"||t==="update");return this._renderRows(n,e),n}_renderRows(e,t){let n=this,o=n._getRows(t.change),s=t.change&&t.change.columnIndices||[],r=t.change&&t.change.changeTypes||[];for(let a=0;a<o.length;a++)n._renderRow(e,m({row:o[a],columnIndices:s[a],changeType:r[a]},t))}_renderRow(e,t){t.columnIndices||(t.row.cells=[]);let n=this._createRow(t.row),o=this._wrapRowIfNeed(e,n);t.changeType!=="remove"&&this._renderCells(n,t),this._appendRow(e,o);let s=m({columns:t.columns},t.row);this._addWatchMethod(s,t.row),this._rowPrepared(o,s,t.row)}_needRenderCell(e,t){return!t||t.indexOf(e)>=0}_renderCells(e,t){let n=this,o=0,{row:s}=t,{columns:r}=t;for(let a=0;a<r.length;a++)this._needRenderCell(a,t.columnIndices)&&n._renderCell(e,m({column:r[a],columnIndex:o,value:s.values&&s.values[o],oldValue:s.oldValues&&s.oldValues[o]},t)),r[a].colspan>1?o+=r[a].colspan:o++}_updateCells(e,t,n){let o=e.children(),s=t.children(),r=this.option("highlightChanges"),a=this.addWidgetPrefix("cell-updated-animation");n.forEach((l,d)=>{let c=o.eq(l),h=s.eq(d);c.replaceWith(h),r&&!h.hasClass("dx-command-expand")&&h.addClass(a)}),LY(e.get(0),t.get(0))}_setCellAriaAttributes(e,t){if(t.rowType!=="freeSpace"){this.setAria("role","gridcell",e);let n=this._columnsController.getColumnIndexOffset(),o=t.columnIndex+n+1;this.setAria("colindex",o,e)}}_renderCell(e,t){let n=this._getCellOptions(t);if(t.columnIndices){if(t.row.cells){let s=t.row.cells.findIndex(r=>r.columnIndex===n.columnIndex);t.row.cells[s]=n}}else t.row.cells.push(n);let o=this._createCell(n);return this._setCellAriaAttributes(o,n),this._renderCellContent(o,n,t),e.get(0).appendChild(o.get(0)),o}_renderCellContent(e,t,n){let o=this._getCellTemplate(t);P(!o||this.renderTemplate(e,o,t,void 0,n.change)).done(()=>{this._updateCell(e,t)})}_getCellTemplate(e){}_getRows(e){return[]}_getCellOptions(e){let t={column:e.column,columnIndex:e.columnIndex,rowType:e.row.rowType,isAltRow:this._isAltRow(e.row)};return this._addWatchMethod(t),t}_addWatchMethod(e,t){if(!this.option("repaintChangesOnly"))return;let n=[];return t=t||e,t.watch=t.watch||function(o,s,r){let a=o(t.data),l=function(d){d&&r&&r(d);let c=o(t.data);JSON.stringify(a)!==JSON.stringify(c)&&(d&&s(c),a=c)};return n.push(l),function(){let d=n.indexOf(l);d>=0&&n.splice(d,1)}},t.update=t.update||function(o,s){o&&(this.data=e.data=o.data,this.rowIndex=e.rowIndex=o.rowIndex,this.dataIndex=e.dataIndex=o.dataIndex,this.isExpanded=e.isExpanded=o.isExpanded,e.row&&!s&&(e.row=o)),n.forEach(r=>{r(o)})},t!==e&&(e.watch=t.watch.bind(t)),e}_cellPrepared(e,t){t.cellElement=N(u(e)),this.executeAction("onCellPrepared",t)}_rowPrepared(e,t,n){$e(e.get(0),"options",t),t.rowElement=N(e),this.executeAction("onRowPrepared",t)}_columnOptionChanged(e){let{optionNames:t}=e;if(M.checkChanges(t,["width","visibleWidth"])){let o=this._columnsController.getVisibleColumns().map(s=>s.visibleWidth||s.width);this.setColumnWidths({widths:o,optionNames:t});return}this._requireReady||this.render()}getCellIndex(e,t){return e.length?e[0].cellIndex:-1}getTableElements(){return this._tableElement||u()}getTableElement(e){return this._tableElement}setTableElement(e,t){this._tableElement=e}_afterRowPrepared(e){}_handleDataChanged(e){}callbackNames(){return["scrollChanged"]}_updateScrollLeftPosition(){let e=this._scrollLeft;e>=0&&(this._scrollLeft=0,this.scrollTo({left:e}))}scrollTo(e){let t=this.element(),n=t&&t.children(`.${this.addWidgetPrefix("scroll-container")}`).not(`.${this.addWidgetPrefix("content-fixed")}`);f(e)&&f(e.left)&&this._scrollLeft!==e.left&&(this._scrollLeft=e.left,n&&n.scrollLeft(e.left))}_getContent(e){var t;return(t=this._tableElement)===null||t===void 0?void 0:t.parent()}_removeContent(e){let t=this._getContent(e);t!=null&&t.length&&t.remove()}_wrapTableInScrollContainer(e,t){let n=u("<div>"),o=this.option("scrolling.useNative");return(o===!1||o==="auto"&&!Hn)&&n.addClass(this.addWidgetPrefix("scrollable-simulated")),_.on(n,"scroll",()=>{let s=n.scrollLeft();s!==this._scrollLeft&&this.scrollChanged.fire({left:s},this.name)}),n.addClass(this.addWidgetPrefix("content")).addClass(this.addWidgetPrefix("scroll-container")).append(e).appendTo(this.element()),this.setAria("role","presentation",n),n}needWaitAsyncTemplates(){return this.option("templatesRenderAsynchronously")&&this.option("renderAsync")===!1}waitAsyncTemplates(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,t=new y;if(!(e||this.needWaitAsyncTemplates()))return t.resolve();let o=()=>P.apply(this,Array.from(this._templateDeferreds)).done(()=>{this.isDisposed()?t.reject():this._templateDeferreds.size>0?o():t.resolve()}).fail(t.reject);return o(),t.promise()}_updateContent(e,t,n){return this.waitAsyncTemplates().done(()=>{this._removeContent(n),this.setTableElement(e,n),this._wrapTableInScrollContainer(e,n)})}_findContentElement(e){}_getWidths(e){if(!e)return[];let t=[];return e.toArray().forEach(o=>{let s=o.offsetWidth;if(o.getBoundingClientRect){let r=Ie(o);r.width>o.offsetWidth-1&&(s=r.width)}t.push(s)}),t}getColumnWidths(e){if((this.option("forceApplyBindings")||S)(),e=e??this.getTableElement(),e){let t=e.children("tbody:not(.dx-header)").children();for(let n=0;n<t.length;n++){let o=t.eq(n),s=o.hasClass("dx-group-row"),r=o.hasClass(Fb),a=o.hasClass("dx-error-row");if(o.get(0).style.display!=="none"&&!o.hasClass("dx-state-invisible")&&(!s&&!r&&!a)){let c=o.children("td");return this._getWidths(c)}}}return[]}getVisibleColumnIndex(e,t){return e}setColumnWidths(e){let{widths:t,optionNames:n}=e,o=this.getTableElement();if(!(o!=null&&o.length)||!t)return;let s=this.getColumns(),r=this._needToSetCellWidths(),a=o.children("colgroup").children("col");a.toArray().forEach(l=>l.removeAttribute("style")),s.forEach((l,d)=>{if(r&&l.width&&!l.command){let h=$g(l.visibleWidth||l.width),p=$g(l.minWidth||h),g=o.children().children(".dx-row").not(`.${Fb}`);for(let C=0;C<g.length;C++){let v=this.getVisibleColumnIndex(d,C);if(v>=0){let b=g.eq(C),T=b.hasClass("dx-group-row")?b.find(`td[aria-colindex='${v+1}']:not(.dx-group-cell)`):b.find("td").eq(v);if(T.length){let R=T.get(0);wP(R,l,h),R.style.minWidth=p}}}}let c=kb(t[d]);f(c)&&$d(a.eq(d),c)})}getCellElements(e){return this._getCellElementsCore(e)}_getCellElementsCore(e){return e<0?void 0:this._getRowElements().eq(e).children()}_getCellElement(e,t){let n=this.getCellElements(e),o=this._getVisibleColumnIndex(n,e,t);if(!(n!=null&&n.length)||o<0)return;let s=n.eq(o);return s.length>0?s:void 0}_getRowElement(e){let t=this,n=u(),o=t.getTableElements();if(x(o,(s,r)=>{n=n.add(t._getRowElements(u(r)).eq(e))}),n.length)return n}getCellElement(e,t){let n=this._getCellElement(e,t);if(n)return N(n)}getRowElement(e){let t=this._getRowElement(e),n=[];if(t&&!N(t).get)for(let o=0;o<t.length;o++)n.push(t[o]);else n=t;return n}_getVisibleColumnIndex(e,t,n){if(B(n)){let o=this._columnsController.columnOption(n,"index");return this._columnsController.getVisibleIndex(o)}return n}getColumnElements(){}getColumns(e,t){return this._columnsController.getVisibleColumns(e)}getCell(e,t,n){let o=t||this._getRowElements(),s;if(o.length>0&&e.rowIndex>=0){var r;if(this.option("scrolling.mode")!=="virtual"&&this.option("scrolling.rowRenderingMode")!=="virtual"&&(e.rowIndex=e.rowIndex<o.length?e.rowIndex:o.length-1),s=n||this.getCellElements(e.rowIndex),((r=s)===null||r===void 0?void 0:r.length)>0)return s.eq(s.length>e.columnIndex?e.columnIndex:s.length-1)}}getRowsCount(){let e=this.getTableElement();return e&&e.length===1?e[0].rows.length:0}_getRowElementsCore(e){if(e=e||this.getTableElement(),e){let n=(this.option().rowTemplate||this.option("dataRowTemplate"))&&e.find("> tbody.dx-row");return n&&n.length?n:e.find("> tbody > .dx-row, > .dx-row")}return u()}_getRowElements(e){return this._getRowElementsCore(e)}getRowIndex(e){return this._getRowElements().index(e)}getBoundingRect(){}getName(){}setScrollerSpacing(e){let t=this.element(),n=this.option("rtlEnabled");t&&t.css({paddingLeft:n?e:"",paddingRight:n?"":e})}isScrollbarVisible(e){let t=this.element(),n=this._tableElement;return t&&n?e?ie(n)-z(t)>0:X(n)-Y(t)>0:!1}isDisposed(){var e;return(e=this.component)===null||e===void 0?void 0:e._disposed}};var HY="dx-link",Bb=function(i,e,t){let n=u("<div>").addClass(i.addWidgetPrefix("text-content"));i.setAria("role","presentation",n),IP(i,e,t.column,n);let o=i.option("showColumnLines"),s=i.getController("columns").getHeaderContentAlignment(t.column.alignment);return n[o||s==="right"?"appendTo":"prependTo"](e)};function IP(i,e,t,n){let o=i._getIndicatorElements(e,!0),s=i._getIndicatorElements(e),r=o&&o.length,a=i._getColumnAlignment(t.alignment),l=`.${i._getIndicatorClassName("sort")}`,d=`.${i._getIndicatorClassName("sortIndex")}`,c=s.filter(l),h=s.children().filter(d);n=n||e.children(`.${i.addWidgetPrefix("text-content")}`),n.toggleClass("dx-text-content-alignment-"+a,r>0).toggleClass("dx-text-content-alignment-"+(a==="left"?"right":"left"),r>0&&t.alignment==="center").toggleClass("dx-sort-indicator",!!c.length).toggleClass("dx-sort-index-indicator",!!h.length).toggleClass("dx-header-filter-indicator",!!s.filter(`.${i._getIndicatorClassName("headerFilter")}`).length)}var Vb=class extends eo{init(){super.init(),this._headerPanelView=this.getView("headerPanel"),this._headerFilterController=this.getController("headerFilter"),this._dataController=this.getController("data")}_createTable(){let e=super._createTable.apply(this,arguments);return _.on(e,"mousedown selectstart",this.createAction(t=>{let{event:n}=t;n.shiftKey&&n.preventDefault()})),e}_isLegacyKeyboardNavigation(){return this.option("useLegacyKeyboardNavigation")}_getDefaultTemplate(e){let t=this;return function(n,o){let{caption:s}=e,r=!e.command||s&&e.command!=="expand";e.command==="empty"?t._renderEmptyMessage(n,o):r?Bb(t,n,o).text(s):e.command&&n.html("&nbsp;")}}_renderEmptyMessage(e,t){let n=this._getEmptyHeaderText();if(!n){e.html("&nbsp;");return}let o=Bb(this,e,t);if(n.includes("{0}")){let[r,a]=n.split("{0}"),l=O.format("dxDataGrid-emptyHeaderColumnChooserText"),d=this._columnChooserView,c=u("<a>").text(l).addClass(HY);_.on(c,"click",this.createAction(()=>d.showColumnChooser())),o.append(w.createTextNode(r)).append(c).append(w.createTextNode(a))}else o.text(n)}_getEmptyHeaderText(){let e=!!this._columnChooserView.hasHiddenColumns(),t=!!this._headerPanelView.hasGroupedColumns();switch(!0){case(e&&t):return O.format("dxDataGrid-emptyHeaderWithColumnChooserAndGroupPanelText");case t:return O.format("dxDataGrid-emptyHeaderWithGroupPanelText");case e:return O.format("dxDataGrid-emptyHeaderWithColumnChooserText");default:return""}}_getHeaderTemplate(e){return e.headerCellTemplate||{allowRenderToDetachedContainer:!0,render:this._getDefaultTemplate(e)}}_processTemplate(e,t){let n=this,o,{column:s}=t,r=super._processTemplate(e);return t.rowType==="header"&&r&&s.headerCellTemplate&&!s.command?o={render(a){let l=Bb(n,a.container,a.model);r.render(m({},a,{container:l}))}}:o=r,o}_handleDataChanged(e){e.changeType==="refresh"&&(this._isGroupingChanged||this._requireReady)&&(this._isGroupingChanged=!1,this.render())}_renderCell(e,t){let n=super._renderCell(e,t);return t.row.rowType==="header"&&(n.addClass("dx-cell-focus-disabled"),this._isLegacyKeyboardNavigation()||t.column&&!t.column.type&&n.attr("tabindex",this.option("tabindex")||0)),n}_setCellAriaAttributes(e,t){super._setCellAriaAttributes(e,t),t.rowType==="header"&&(t.column.type||this.setAria("role","columnheader",e),t.column&&!t.column.command&&!t.column.isBand&&(e.attr("id",t.column.headerId),this.setAria("label",`${O.format("dxDataGrid-ariaColumn")} ${t.column.caption}`,e)))}_createRow(e){let t=super._createRow.apply(this,arguments);return t.toggleClass("dx-column-lines",this.option("showColumnLines")),e.rowType==="header"&&(t.addClass("dx-header-row"),this._isLegacyKeyboardNavigation()||Ir("columnHeaders",this,t,"td",this._handleActionKeyDown.bind(this))),t}_processHeaderAction(e,t){}_handleActionKeyDown(e){let{event:t}=e,n=u(t.target);if(this._lastActionElement=t.target,n.is(".dx-header-filter")){let o=this._headerFilterController,s=n.closest("td"),r=this.getColumnIndexByElement(s);r>=0&&o.showHeaderFilterMenu(r,!1)}else{let o=n.closest(".dx-row");this._processHeaderAction(t,o)}t.preventDefault()}_renderCore(){let e=this.element(),t={};if(this._tableElement&&!this._dataController.isLoaded()&&!this._hasRowElements)return;e.addClass(this.addWidgetPrefix("headers")).toggleClass(this.addWidgetPrefix("nowrap"),!this.option("wordWrapEnabled")).empty(),this.setAria("role","presentation",e);let n=this._updateContent(this._renderTable({change:t}),t);return this.getRowCount()>1&&e.addClass("dx-header-multi-row"),super._renderCore.apply(this,arguments),n}_renderRows(){let e=this;(e._dataController.isLoaded()||e._hasRowElements)&&(super._renderRows.apply(e,arguments),e._hasRowElements=!0)}_renderRow(e,t){let n=this.getRowCount()===1?null:t.row.rowIndex;t.columns=this.getColumns(n),super._renderRow(e,t)}_createCell(e){let{column:t}=e,n=super._createCell.apply(this,arguments);return t.rowspan>1&&e.rowType==="header"&&n.attr("rowSpan",t.rowspan),n}_getRows(){let e=[],t=this.getRowCount();if(this.option("showColumnHeaders"))for(let n=0;n<t;n++)e.push({rowType:"header",rowIndex:n});return e}_getCellTemplate(e){if(e.rowType==="header")return this._getHeaderTemplate(e.column)}_columnOptionChanged(e){let{changeTypes:t}=e,{optionNames:n}=e;if(t.grouping||t.groupExpanding){t.grouping&&(this._isGroupingChanged=!0);return}super._columnOptionChanged(e),(n.width||n.visible)&&this.resizeCompleted.fire()}_isElementVisible(e){return e&&e.visible}_alignCaptionByCenter(e){let t=this._getIndicatorContainer(e,!0);t&&t.length&&(t.filter(".dx-visibility-hidden").remove(),t=this._getIndicatorContainer(e),t.clone().addClass("dx-visibility-hidden").css("float","").insertBefore(e.children(`.${this.addWidgetPrefix("text-content")}`)))}_updateCell(e,t){t.rowType==="header"&&t.column.alignment==="center"&&this._alignCaptionByCenter(e),super._updateCell.apply(this,arguments)}_updateIndicator(e,t,n){let o=super._updateIndicator.apply(this,arguments);return t.alignment==="center"&&this._alignCaptionByCenter(e),IP(this,e,t),o}_getIndicatorContainer(e,t){let n=super._getIndicatorContainer(e);return t?n:n.filter(":not(.dx-visibility-hidden)")}_isSortableElement(e){return!0}getHeadersRowHeight(){let e=this.getTableElement(),t=e&&e.find(".dx-header-row");return t&&t.toArray().reduce((n,o)=>n+Y(o),0)||0}getHeaderElement(e){let t=this.getColumnElements();return t&&t.eq(e)}getColumnElements(e,t){let n=this,o,s=n._columnsController,r=n.getRowCount();if(n.option("showColumnHeaders")){if(r>1&&(!f(e)||f(t))){let a=[],l=f(t)?s.getChildrenByBandColumn(t,!0):s.getVisibleColumns();return x(l,(d,c)=>{let h=f(e)?e:s.getRowIndex(c.index);o=n._getCellElement(h,s.getVisibleIndex(c.index,h)),o&&a.push(o.get(0))}),u(a)}if(!e||e<r)return n.getCellElements(e||0)}}getColumnIndexByElement(e){let t=this.getCellIndex(e),n=e.closest(".dx-row"),{rowIndex:o}=n[0],s=this.getColumns(o)[t];return s?s.index:-1}getVisibleColumnIndex(e,t){let n=this.getColumns()[e];return n?this._columnsController.getVisibleIndex(n.index,t):-1}getColumnWidths(){let e=this.getColumnElements();return e&&e.length?this._getWidths(e):super.getColumnWidths.apply(this,arguments)}allowDragging(e){let t=e&&this._columnsController.getRowIndex(e.index),n=this.getColumns(t);return(this.option("allowColumnReordering")??this._columnsController.isColumnOptionUsed("allowReordering"))&&e.allowReordering&&n.length>1}getBoundingRect(){let e=this,t=e.getColumnElements();return t&&t.length?{top:e.getTableElement().offset().top}:null}getName(){return"headers"}getColumnCount(){let e=this.getColumnElements();return e?e.length:0}isVisible(){return this.option("showColumnHeaders")}optionChanged(e){let t=this;switch(e.name){case"showColumnHeaders":case"wordWrapEnabled":case"showColumnLines":t._invalidate(!0,!0),e.handled=!0;break;default:super.optionChanged(e)}}getHeight(){return this.getElementHeight()}getContextMenuItems(e){let t=this,{column:n}=e;if(e.row&&(e.row.rowType==="header"||e.row.rowType==="detailAdaptive")){let o=t.option("sorting");if(o&&o.mode!=="none"&&n&&n.allowSorting){let s=function(r){setTimeout(()=>{t._columnsController.changeSortOrder(n.index,r.itemData.value)})};return[{text:o.ascendingText,value:"asc",disabled:n.sortOrder==="asc",icon:"context-menu-sort-asc",onItemClick:s},{text:o.descendingText,value:"desc",disabled:n.sortOrder==="desc",icon:"context-menu-sort-desc",onItemClick:s},{text:o.clearText,value:"none",disabled:!n.sortOrder,icon:"context-menu-sort-none",onItemClick:s}]}}}getRowCount(){return this._columnsController&&this._columnsController.getRowCount()}setRowsOpacity(e,t,n){let o,s,r=this.getRowCount(),a=this._columnsController.getColumns(),l=a&&a[e],d=l&&l.isBand&&l.index,c=(h,p)=>{h.ownerBand===d&&(s.eq(p).css({opacity:t}),h.isBand&&this.setRowsOpacity(h.index,t,o+1))};if(f(d))for(n=n||0,o=n;o<r;o++)s=this.getCellElements(o),s&&this.getColumns(o).forEach(c)}},Lb={defaultOptions:()=>({showColumnHeaders:!0,cellHintEnabled:!0}),views:{columnHeadersView:Vb}};var H=I({},Ce,M,{modules:[]});var ZHe=Lb.views.columnHeadersView;H.registerModule("columnHeaders",Lb);var Nb=["filterValues","filterType","fixed","fixedPosition"],od=["visibleIndex","dataField","name","dataType","width","visible","sortOrder","lastSortOrder","sortIndex","groupIndex","filterValue","bufferedFilterValue","selectedFilterOperation","bufferedSelectedFilterOperation","added"].concat(Nb),DP={visibleWidth:!0,bestFitWidth:!0,bufferedFilterValue:!0},TP="dx-command-expand",Hb=Number.MAX_SAFE_INTEGER||9007199254740991,Zo="groupExpand",AP="detailExpand",zg=/columns\[(\d+)\]\.?/gi,MP={visible:!0,showInColumnChooser:!0},RP={number:["=","<>","<",">","<=",">=","between"],string:["contains","notcontains","startswith","endswith","=","<>"],date:["=","<>","<",">","<=",">=","between"],datetime:["=","<>","<",">","<=",">=","between"]},FP={visibleIndex:!0,groupIndex:!0,grouped:!0,sortIndex:!0,sortOrder:!0},Tr="group",Ar="columnChooser";var $b=function(i){i.filterOperations=i.defaultFilterOperations},$Y=1,ru=function(i,e,t,n){let o={};if(e){B(e)&&(e={dataField:e}),i.setName(e);let s={};if(e.command)s=Bi(o,e);else{o=i.getCommonSettings(e),t&&t.name&&t.dataField&&(e=m({},e,{dataField:t.dataField}));let r=i._createCalculatedColumnOptions(e,n);e.type||(s={headerId:"dx-col-"+$Y++}),s=Bi(s,MP),Bi(s,o),Bi(s,r),Bi(s,e),Bi(s,{selector:null})}return e.filterOperations===e.defaultFilterOperations&&$b(s),s}},Mr=function(i,e,t,n){let o=[];return e&&x(e,(s,r)=>{let a=(n??0)+o.length,l=i._columnsUserState&&jb(r,i._columnsUserState[a])&&i._columnsUserState[a],d=ru(i,r,l,t);d&&(t&&(d.ownerBand=t),o.push(d),d.columns&&(o=o.concat(Mr(i,d.columns,d,o.length)),delete d.columns,d.hasColumns=!0))}),o},Rr=function(i,e){let t=[],n=e[i];for(;n;)t.unshift(n),i=n.index,n=e[i];return t},zb=function(i,e,t){let n=[],o=e[i];if(o)for(let s=0;s<o.length;s++){let r=o[s];(!f(r.groupIndex)||r.showWhenGrouped)&&(n.push(r),t&&r.isBand&&(n=n.concat(zb(r.index,e,t))))}return n},PP=function(i,e){let t,n,o=i.getBandColumnsCache(),s=function(r){let a=t?t.index:void 0;return r.ownerBand===a};if(o.isPlain)t=i._columns[e[0]];else{n=i._columns.filter(s);for(let r=0;r<e.length;r++)t=n[e[r]],t&&(n=i._columns.filter(s))}return t},zY=function(i,e){let t=[],n,o=i.getBandColumnsCache(),s=function(r){return r.ownerBand===e.ownerBand};if(o.isPlain){let r=i._columns.indexOf(e);r>=0&&(t=[`columns[${r}]`])}else for(n=i._columns.filter(s);n.length&&n.indexOf(e)!==-1;)t.unshift(`columns[${n.indexOf(e)}]`),e=o.columnParentByIndex[e.index],n=e?i._columns.filter(s):[];return t.join(".")},kP=function(i,e){let t=0,n=i.getChildrenByBandColumn(e,!0);return x(n,(o,s)=>{s.isBand?(s.colspan=s.colspan||kP(i,s.index),t+=s.colspan||1):t+=1}),t},BP=function(i,e,t){let n;for(let o=0;o<e.length;o++){let s=e[o];(s.visible||s.command)&&(s.isBand&&(s.colspan=s.colspan||kP(i,s.index)),(!s.isBand||!s.colspan)&&(n=i.getRowCount(),!s.command&&(!f(s.groupIndex)||s.showWhenGrouped)&&(n-=Rr(s.index,t.columnParentByIndex).length),n>1&&(s.rowspan=n)))}},Wg=function(i){let e=ri(i);return e!=="string"&&e!=="boolean"&&e!=="number"&&e!=="date"&&e!=="object"&&(e=void 0),e},Wb=function(i,e){switch(i){case"date":case"datetime":return tt.getDateSerializationFormat(e);case"number":if(B(e))return"string";if(xe(e))return null}},Gb=function(i,e){i.deserializeValue||(M.isDateType(e)&&(i.deserializeValue=function(t){return tt.deserializeDate(t)},i.serializeValue=function(t){return B(t)?t:tt.serializeDate(t,this.serializationFormat)}),e==="number"&&(i.deserializeValue=function(t){let n=parseFloat(t);return isNaN(n)?t:n},i.serializeValue=function(t,n){return n==="filter"?t:f(t)&&this.serializationFormat==="string"?t.toString():t}))},VP=function(i,e){switch(i){case"number":return"right";case"boolean":return"center";default:return Ui(e)}},WY=function(i){return i.value===!0?this.trueText||"true":i.value===!1?this.falseText||"false":i.valueText||""},Kb=function(i){if(i==="boolean")return WY},LP=function(i,e){let t=i._getFirstItems(e),n,o={},s=[];for(let r=0;r<t.length;r++)if(t[r])for(n in t[r])(!A(t[r][n])||It.isWrapped(t[r][n]))&&(o[n]=!0);for(n in o)if(n.indexOf("__")!==0){let r=ru(i,n);s.push(r)}return s},NP=function(i){x(i._columns,(e,t)=>{t.index=e}),x(i._columns,(e,t)=>{$(t.ownerBand)&&(t.ownerBand=t.ownerBand.index)}),x(i._commandColumns,(e,t)=>{t.index=-(e+1)})},Ub=function(i,e){ta(i._columns,"groupIndex",e,t=>{let{grouped:n}=t;return delete t.grouped,n})},GY=function(i,e){x(i._columns,(t,n)=>{f(n.sortIndex)&&!su(n.sortOrder)&&delete n.sortIndex}),ta(i._columns,"sortIndex",e,t=>!f(t.groupIndex)&&su(t.sortOrder))},KY=function(i,e){let t,n=[],o=i.getBandColumnsCache(),s=[],r=i._columns.filter(a=>!a.command);for(let a=0;a<r.length;a++)t=r[a],Rr(a,o.columnParentByIndex).length?s.push(t):n.push(t);ta(s,"visibleIndex",e),ta(n,"visibleIndex",e)},Gg=function(i,e,t){let n=$(e)?e.rowIndex:null,o=t===Tr?i.getGroupColumns():t===Ar?i.getChooserColumns():i.getVisibleColumns(n),s;return e=$(e)?e.columnIndex:e,s=o[e],s&&s.type===Zo&&(s=i._columns.filter(r=>s.type===r.type)[0]||s),s&&f(s.index)?s.index:-1},HP=function(i,e,t){let n=i.getGroupColumns(),o;if(t>=0)for(o=0;o<n.length;o++)n[o].groupIndex>=t&&n[o].groupIndex++;else for(t=0,o=0;o<n.length;o++)t=Math.max(t,n[o].groupIndex+1);return t};function jb(i,e){return i&&e&&e.name===(i.name||i.dataField)&&(e.dataField===i.dataField||i.name)}var qb=function(i){let e=i._columnsUserState,t=i._ignoreColumnOptionNames||[],n=i._columns,o={},s=[],r=!0,a=[],l,d,c;function h(g,C){if(C)for(let v=0;v<od.length;v++){let b=od[v];t.includes(b)||(b==="dataType"?g[b]=g[b]||C[b]:Nb.includes(b)?b in C&&(g[b]=C[b]):(b==="selectedFilterOperation"&&C[b]&&(g.defaultSelectedFilterOperation=g[b]||null),g[b]=C[b]))}}function p(g,C){let v=C.name||C.dataField,b=o[v]||0;for(let T=0;T<g.length;T++)if(jb(C,g[T]))if(b)b--;else return o[v]=o[v]||0,o[v]++,T;return-1}if(e){for(c=0;c<n.length;c++)d=p(e,n[c]),r=r&&d>=0,a.push(d);for(c=0;c<n.length;c++)l=n[c],d=a[c],(i._hasUserState||r)&&h(l,e[d]),d>=0&&f(e[d].initialIndex)?s[d]=l:s.push(l);let g=!1;for(c=0;c<e.length;c++){let C=e[c];C.added&&p(n,C)<0&&(l=ru(i,C.added),h(l,C),s.push(l),C.added.columns&&(g=!0))}g&&(NP(i),s=Mr(i,s)),Sa(i,s)}},Fr=function(i,e){NP(i),Ub(i,e),GY(i,e),ty(i),KY(i,e)},au=function(i){i.resetColumnsCache()};function Sa(i,e){i._previousColumns=i._columns,i._columns=e,au(i),i.updateColumnDataTypes()}var Oo=function(i,e,t,n){let o=i._columnChanges||{optionNames:{length:0},changeTypes:{length:0},columnIndex:n};t=t||"all",t=t.split(".")[0];let{changeTypes:s}=o;e&&!s[e]&&(s[e]=!0,s.length++);let{optionNames:r}=o;t&&!r[t]&&(r[t]=!0,r.length++),(n===void 0||n!==o.columnIndex)&&(f(n)&&(o.columnIndices??(o.columnIndices=[]),f(o.columnIndex)&&o.columnIndices.push(o.columnIndex),o.columnIndices.push(n)),delete o.columnIndex),i._columnChanges=o,au(i)},sd=function(i){let e=i.option("onColumnsChanging"),t=i._columnChanges,n=["dataField","lookup","dataType","columns"];i.isInitialized()&&!i._updateLockCount&&t&&(e&&(i._updateLockCount++,e(m({component:i.component},t)),i._updateLockCount--),i._columnChanges=void 0,o=t.optionNames,o&&n.some(s=>o[s])?(i._reinitAfterLookupChanges=t?.optionNames.lookup,i.reinit(),i._reinitAfterLookupChanges=void 0):i.columnsChanged.fire(t));var o},UY=function(i,e,t,n){let o=n>=0;if(t>=0)o||(e.lastSortOrder=e.sortOrder);else{let s=i.option("sorting.mode"),r=e.lastSortOrder;s==="single"&&i._columns.some(l=>l!==e&&f(l.sortIndex))&&(r=void 0),e.sortOrder=r}},jY=function(i,e){let{value:t}=e,{optionName:n}=e,{prevValue:o}=e,{fullOptionName:s}=e,r=`${s}.${n}`;!DP[n]&&i._skipProcessingColumnsChange!==r&&(i._skipProcessingColumnsChange=r,i.component._notifyOptionChanged(r,t,o),i._skipProcessingColumnsChange=!1)},Kg=function(i,e,t,n,o){let s=me(t),r=e.index,a,l,d;if(arguments.length===3)return s(e,{functionsAsIs:!0});let c=s(e,{functionsAsIs:!0});if(!ve(c,n,{maxDepth:5})){t==="groupIndex"||t==="calculateGroupValue"?(l="grouping",UY(i,e,n,c)):t==="sortIndex"||t==="sortOrder"||t==="calculateSortValue"?l="sorting":l="columns";let h=Ga(t);h(e,n,{functionsAsIs:!0});let p=zY(i,e);FP[t]&&(Fr(i,e),n=s(e)),(t==="name"||t==="allowEditing")&&i._checkColumns(),!f(c)&&!f(n)&&t.indexOf("buffer")!==0&&(o=!0),o?au(i):(!od.includes(t)&&t!=="visibleWidth"&&(a=i.option("columns"),d=i.getColumnByPath(p,a),B(d)&&(d=a[r]={dataField:d}),d&&jb(d,e)&&h(d,n,{functionsAsIs:!0})),Oo(i,l,t,r)),p&&jY(i,{fullOptionName:p,optionName:t,value:n,prevValue:c})}};function su(i){return i==="asc"||i==="desc"}var $P=function(i){let e=i._getExpandColumnOptions();i.addCommandColumn(e)},zP=function(i,e){if(!this.dataField)return;let t=this.dataField.split("."),n=t.length-1;this.serializeValue&&(e=this.serializeValue(e));for(let o=0;o<n;o++){let s=t[o];i=i[s]=i[s]||{}}i[t[n]]=e},Yb=function(i,e,t){let n=[];return e=e||0,i[e]&&x(i[e],(o,s)=>{(s.ownerBand===t||s.type===Zo)&&(!s.isBand||!s.colspan?(!s.command||e<1)&&n.push(s):n.push.apply(n,Yb(i,e+1,s.index)))}),n},WP=function(i){let e=1,t=i.getBandColumnsCache(),{columnParentByIndex:n}=t;return i._columns.forEach(o=>{let s=Rr(o.index,n),r=s.filter(a=>!a.visible);o.visible&&!r.length&&(e=Math.max(e,s.length+1))}),e},Ug=(i,e)=>!!i._columns.filter(n=>n.type===e.type).length,Xb=function(i,e){let t=i.option("rtlEnabled");return e.command&&!Ug(i,e)||!e.fixedPosition?t?"right":"left":e.fixedPosition},Qb=function(i,e,t,n){let o,s=this.getRowCount(),r=i[n]&&i[n].rowspan,a=e.filter(l=>l.type===t);return i.forEach((l,d)=>{l.type===t&&(o=d,r=i[d+1]?i[d+1].rowspan:s)}),r>1&&(a=He(a,l=>m({},l,{rowspan:r}))),a.unshift.apply(a,f(o)?[o,1]:[n,0]),i.splice.apply(i,a),r||1},GP=function(i){let e;for(e=0;i>1;e++)i/=10;return e},Zb=function(i,e){let t=i?i.toString():"0";for(;t.length<e;)t=`0${t}`;return t},Jb=(i,e,t,n)=>{let o,s,r=e.slice().map(h=>m({},h)),a=i._isColumnFixing(),l=t.slice().map(h=>m({fixed:a},h)),d=h=>t.reduce((p,g,C)=>{let v=n&&h.type===Zo?"expand":h.type;return g.type===v||g.command===h.command?C:p},-1),c=h=>h.command!==t[s].command;for(let h=0;h<e.length;h++)if(o=e[h],s=o&&(o.type||o.command)?d(o):-1,s>=0)if(n)r[h]=m({fixed:a},t[s],o),o.type!==Zo&&(l=l.filter(c));else{let p={visibleIndex:o.visibleIndex,index:o.index,headerId:o.headerId,allowFixing:o.groupIndex===0,allowReordering:o.groupIndex===0,groupIndex:o.groupIndex};r[h]=m({},o,t[s],o.type===Zo&&p)}return e.length&&n&&l.length&&(r=r.concat(l)),r},ey=(i,e)=>f(e.fixed)||!e.type?e.fixed:i._isColumnFixing(),KP=i=>{i.forEach(e=>{f(e.ownerBand)&&(e.ownerBand=i[e.ownerBand])})},ty=i=>{i._bandColumnsCache=void 0},iy=(i,e)=>{let t=B(e)&&e.substr(0,e.indexOf(":")),n;if(e!==void 0)return t&&(e=e.substr(t.length+1)),t?n=i.filter(o=>`${o[t]}`===e)[0]:["index","name","dataField","caption"].some(o=>(n=i.filter(s=>s[o]===e)[0],!!n)),n},UP=(i,e)=>{if(e!=="asc"&&e!=="desc")return i;let t=e==="asc"?1:-1;return i.sort((n,o)=>{let s=n.caption||"",r=o.caption||"";return t*s.localeCompare(r)}),i},jP=function(i,e){let t=ze.parse(i);if(xe(t)){let n=ze.format(t,e),o=ze.format(t,"decimal");if(n===i||o===i)return t}};var ny=class extends Ce.Controller{init(e){this._dataController=this.getController("data"),this._focusController=this.getController("focus"),this._stateStoringController=this.getController("stateStoring");let t=this.option("columns");this._commandColumns=this._commandColumns||[],this._columns=this._columns||[],this._isColumnsFromOptions=!!t,this._isColumnsFromOptions?(Sa(this,t?Mr(this,t):[]),qb(this)):Sa(this,this._columnsUserState?Mr(this,this._columnsUserState):this._columns),$P(this),this._dataSourceApplied?this.applyDataSource(this._dataSource,!0,e):Fr(this),this._checkColumns()}_getExpandColumnOptions(){return{type:"expand",command:"expand",width:"auto",cssClass:TP,allowEditing:!1,allowGrouping:!1,allowSorting:!1,allowResizing:!1,allowReordering:!1,allowHiding:!1}}_getFirstItems(e){let t,n=[],o=function(s,r){if(!s||!r)return s;for(let a=0;a<s.length;a++){let l=o(s[a].items||s[a].collapsedItems,r-1);if(l&&l.length)return l}};return e&&e.items().length>0&&(t=M.normalizeSortingInfo(e.group()).length,n=o(e.items(),t)||[]),n}_endUpdateCore(){!this._skipProcessingColumnsChange&&sd(this)}callbackNames(){return["columnsChanged"]}getColumnByPath(e,t){let n=this,o,s=[];return e.replace(zg,(r,a)=>(s.push(parseInt(a)),"")),s.length&&(t?o=s.reduce((r,a)=>r&&r.columns&&r.columns[a],{columns:t}):o=PP(n,s)),o}optionChanged(e){let t;switch(e.name){case"adaptColumnWidthByRatio":e.handled=!0;break;case"dataSource":e.value!==e.previousValue&&!this.option("columns")&&(!Array.isArray(e.value)||!Array.isArray(e.previousValue))&&(this._columns=[]);break;case"columns":t=this._skipProcessingColumnsChange,e.handled=!0,this._skipProcessingColumnsChange||(e.name===e.fullName?(this._columnsUserState=null,this._ignoreColumnOptionNames=null,this.init()):(this._columnOptionChanged(e),t=!0)),t&&this._updateRequireResize(e);break;case"commonColumnSettings":case"columnAutoWidth":case"allowColumnResizing":case"allowColumnReordering":case"columnFixing":case"grouping":case"groupPanel":case"regenerateColumnsByVisibleItems":case"customizeColumns":case"columnHidingEnabled":case"dateSerializationFormat":case"columnResizingMode":case"columnMinWidth":case"columnWidth":{e.handled=!0;let n=e.fullName==="columnWidth"&&["width"];this.reinit(n);break}case"rtlEnabled":this.reinit();break;default:super.optionChanged(e)}}_columnOptionChanged(e){let t={},n=this.getColumnByPath(e.fullName),o=e.fullName.replace(zg,"");n&&(o?t[o]=e.value:t=e.value,this._skipProcessingColumnsChange=e.fullName,this.columnOption(n.index,t),this._skipProcessingColumnsChange=!1)}_updateRequireResize(e){let{component:t}=this;e.fullName.replace(zg,"")==="width"&&t._updateLockCount&&(t._requireResize=!0)}publicMethods(){return["addColumn","deleteColumn","columnOption","columnCount","clearSorting","clearGrouping","getVisibleColumns","getVisibleColumnIndex"]}applyDataSource(e,t,n){let o=this,s=e&&e.isLoaded();if(o._dataSource=e,!o._dataSourceApplied||o._dataSourceColumnsCount===0||t||o.option("regenerateColumnsByVisibleItems")){if(s){if(!o._isColumnsFromOptions){let r=LP(o,e);r.length&&(Sa(o,r),o._dataSourceColumnsCount=o._columns.length,qb(o))}return o.updateColumns(e,t,n)}o._dataSourceApplied=!1,Fr(o)}else if(s&&!o.isAllDataTypesDefined(!0)&&o.updateColumnDataTypes(e))return Oo(o,"columns"),sd(o),new y().reject().promise()}reset(){this._dataSource=null,this._dataSourceApplied=!1,this._dataSourceColumnsCount=void 0,this.reinit()}resetColumnsCache(){this._visibleColumns=void 0,this._fixedColumns=void 0,this._rowCount=void 0,ty(this)}reinit(e){this._columnsUserState=this.getUserState(),this._ignoreColumnOptionNames=e||null,this.init(),e&&(this._ignoreColumnOptionNames=null)}isInitialized(){return!!this._columns.length||!!this.option("columns")}isDataSourceApplied(){return this._dataSourceApplied}getCommonSettings(e){let t=(!e||!e.type)&&this.option("commonColumnSettings")||{},n=this.option("grouping")??{},o=this.option("groupPanel")??{};return m({allowFixing:this.option("columnFixing.enabled"),allowResizing:this.option("allowColumnResizing")||void 0,allowReordering:this.option("allowColumnReordering"),minWidth:this.option("columnMinWidth"),width:this.option("columnWidth"),autoExpandGroup:n.autoExpandAll,allowCollapsing:n.allowCollapsing,allowGrouping:o.allowColumnDragging&&o.visible||n.contextMenuEnabled},t)}isColumnOptionUsed(e){for(let t=0;t<this._columns.length;t++)if(this._columns[t][e])return!0}isAllDataTypesDefined(e){let t=this._columns;if(!t.length)return!1;for(let n=0;n<t.length;n++)if(!(!t[n].dataField&&t[n].calculateCellValue===t[n].defaultCalculateCellValue)&&(!t[n].dataType||e&&t[n].deserializeValue&&t[n].serializationFormat===void 0))return!1;return!0}getColumns(){return this._columns}isBandColumnsUsed(){return this.getColumns().some(e=>e.isBand)}getGroupColumns(){let e=[];return x(this._columns,function(){let t=this;f(t.groupIndex)&&(e[t.groupIndex]=t)}),e}_shouldReturnVisibleColumns(){return!0}_compileVisibleColumns(e){return this._visibleColumns=this._visibleColumns||this._compileVisibleColumnsCore(),e=f(e)?e:this._visibleColumns.length-1,this._visibleColumns[e]||[]}getVisibleColumns(e,t){return this._shouldReturnVisibleColumns()?this._compileVisibleColumns.apply(this,arguments):[]}getFixedColumns(e){return this._fixedColumns=this._fixedColumns||this._getFixedColumnsCore(),e=f(e)?e:this._fixedColumns.length-1,this._fixedColumns[e]||[]}getFilteringColumns(){return this.getColumns().filter(e=>(e.dataField||e.name)&&(e.allowFiltering||e.allowHeaderFiltering)).map(e=>{let t=m(!0,{},e);return f(t.dataField)||(t.dataField=t.name),t.filterOperations=e.filterOperations!==e.defaultFilterOperations?t.filterOperations:null,t})}getColumnIndexOffset(){return 0}_getFixedColumnsCore(){let e=this,t=[],n=e.getRowCount(),o=e._isColumnFixing(),s={command:"transparent"},r=0,a,l,d;if(o)for(let c=0;c<=n;c++){a=0,d=null,l=null;let h=e.getVisibleColumns(c,!0);for(let p=0;p<h.length;p++){let g=h[p-1],C=h[p];C.fixed?g&&g.fixed&&Xb(e,g)!==Xb(e,C)?f(l)||(l=p):d=C.fixedPosition:(c===0&&(C.isBand&&C.colspan?r+=C.colspan:r++),a++,f(l)||(l=p))}if(c===0&&(a===0||a>=h.length))return[];f(l)||(l=d==="right"?0:h.length),t[c]=h.slice(0),s.colspan||(s.colspan=r),t[c].splice(l,a,s)}return t.map(c=>c.map(h=>{let p=I({},h);return p.headerId&&(p.headerId+="-fixed"),p}))}_isColumnFixing(){let e=this.option("columnFixing.enabled");return!e&&x(this._columns,(t,n)=>{if(n.fixed)return e=!0,!1}),e}_getExpandColumnsCore(){return this.getGroupColumns()}getExpandColumns(){let e=this._getExpandColumnsCore(),t,n=e.filter(a=>a.groupIndex===0)[0],o=n&&n.fixed,s=this._isColumnFixing(),r=this.option("rtlEnabled");return e.length&&(t=this.columnOption("command:expand")),e=He(e,a=>m({},a,{visibleWidth:null,minWidth:null,cellTemplate:f(a.groupIndex)?null:a.cellTemplate,headerCellTemplate:null,fixed:!f(a.groupIndex)||!o?s:!0,fixedPosition:r?"right":"left"},t,{index:a.index,type:a.type||Zo})),e}getBandColumnsCache(){if(!this._bandColumnsCache){let e=this._columns,t={},n={},o=!0;e.forEach(s=>{let{ownerBand:r}=s,a=$(r)?r.index:r,l=e[a];s.hasColumns&&(o=!1),s.colspan&&(s.colspan=void 0),s.rowspan&&(s.rowspan=void 0),l?n[s.index]=l:a=-1,t[a]=t[a]||[],t[a].push(s)}),this._bandColumnsCache={isPlain:o,columnChildrenByIndex:t,columnParentByIndex:n}}return this._bandColumnsCache}_isColumnVisible(e){return e.visible&&this.isParentColumnVisible(e.index)}_isColumnInGroupPanel(e){return f(e.groupIndex)&&!e.showWhenGrouped}hasVisibleDataColumns(){return this._columns.some(t=>{let n=this._isColumnVisible(t),o=this._isColumnInGroupPanel(t),s=!!t.command;return n&&!o&&!s})}_compileVisibleColumnsCore(){let e=this.getBandColumnsCache(),t=Jb(this,this._columns,this._commandColumns,!0);BP(this,t,e);let n=this._getIndexedColumns(t),o=this._getVisibleColumnsFromIndexed(n);return!this.hasVisibleDataColumns()&&this._columns.length&&o[o.length-1].push({command:"empty"}),o}_getIndexedColumns(e){let t=this.option("rtlEnabled"),n=this.getRowCount(),o=GP(e.length),s=this.getBandColumnsCache(),r=[],a=[];for(let l=0;l<n;l+=1)a[l]=[{}],r[l]=[{},{},{}];return e.forEach(l=>{let{visibleIndex:d}=l,c,h=Rr(l.index,s.columnParentByIndex),p=this._isColumnVisible(l),g=this._isColumnInGroupPanel(l);if(p&&!g){let b=h.length;if(d<0)d=-d,c=a[b];else{var C,v;if(l.fixed=((C=h[0])===null||C===void 0?void 0:C.fixed)??l.fixed,l.fixedPosition=((v=h[0])===null||v===void 0?void 0:v.fixedPosition)??l.fixedPosition,l.fixed){let T=!!l.command&&!Ug(this,l),R=l.fixedPosition==="right";t&&!T&&(R=!R),c=R?r[b][2]:r[b][0]}else c=r[b][1]}if(h.length){d=Zb(d,o);for(let T=h.length-1;T>=0;T-=1)d=Zb(h[T].visibleIndex,o)+d}c[d]=c[d]||[],c[d].push(l)}}),{positiveIndexedColumns:r,negativeIndexedColumns:a}}_getVisibleColumnsFromIndexed(e){let{positiveIndexedColumns:t,negativeIndexedColumns:n}=e,o=[],s=this.getRowCount(),r=Jb(this,this.getExpandColumns(),this._columns),a=0,l=0;for(let d=0;d<s;d+=1){o.push([]),Fd(n[d],(p,g)=>{o[d].unshift.apply(o[d],g)});let c=o[d].length;t[d].forEach(p=>{Fd(p,(g,C)=>{o[d].push.apply(o[d],C)})}),l<=d&&(l+=Qb.call(this,o[d],r,AP,c)),a<=d&&(a+=Qb.call(this,o[d],r,Zo,c))}return o.push(Yb(o)),o}getInvisibleColumns(e,t){let n=this,o=[],s;return e=e||n._columns,x(e,(r,a)=>{if(a.ownerBand===t){if(a.isBand){a.visible?s=n.getInvisibleColumns(n.getChildrenByBandColumn(a.index),a.index):s=n.getChildrenByBandColumn(a.index),s.length&&(o.push(a),o=o.concat(s));return}a.visible||o.push(a)}}),o}getChooserColumns(e){let n=(e?this.getColumns():this.getInvisibleColumns()).filter(s=>s.showInColumnChooser),o=this.option("columnChooser.sortOrder");return UP(n,o)}allowMoveColumn(e,t,n,o){let s=Gg(this,e,n),r=this._columns[s];return r&&(r.allowReordering||r.allowGrouping||r.allowHiding)?n===o?n===Ar?!1:(e=$(e)?e.columnIndex:e,t=$(t)?t.columnIndex:t,e!==t&&e+1!==t):n===Tr&&o!==Ar||o===Tr?r&&r.allowGrouping:n===Ar||o===Ar?r&&r.allowHiding:!0:!1}moveColumn(e,t,n,o){let s=this,r={},a,l=Gg(s,e,n),d=Gg(s,t,o),c;if(l>=0){let h=s._columns[l];if(t=$(t)?t.columnIndex:t,c=d>=0?s._columns[d].groupIndex:-1,f(h.groupIndex)&&n===Tr&&(c>h.groupIndex&&c--,o!==Tr?r.groupIndex=void 0:(a=h.groupIndex,delete h.groupIndex,Ub(s))),o===Tr)r.groupIndex=HP(s,h,c),h.groupIndex=a;else if(t>=0){let g=s._columns[d];!g||h.ownerBand!==g.ownerBand?r.visibleIndex=Hb:ey(s,h)^ey(s,g)?r.visibleIndex=Hb:r.visibleIndex=g.visibleIndex}let p=o!==Ar;h.visible!==p&&(r.visible=p),s.columnOption(h.index,r)}}changeSortOrder(e,t){let n=this,o={},s=n.option("sorting"),r=s&&s.mode,a=r==="single"||!t,l=r==="single"||r==="multiple",d=n._columns[e];l&&d&&d.allowSorting&&(a&&!f(d.groupIndex)&&x(n._columns,function(c){c!==e&&this.sortOrder&&(f(this.groupIndex)||delete this.sortOrder,delete this.sortIndex)}),su(t)?d.sortOrder!==t&&(o.sortOrder=t):t==="none"?d.sortOrder&&(o.sortIndex=void 0,o.sortOrder=void 0):function(c){if(t==="ctrl"){if(!("sortOrder"in c&&"sortIndex"in c))return!1;o.sortOrder=void 0,o.sortIndex=void 0}else f(c.groupIndex)||f(c.sortIndex)?o.sortOrder=c.sortOrder==="desc"?"asc":"desc":o.sortOrder="asc";return!0}(d)),n.columnOption(d.index,o)}getSortDataSourceParameters(e){let t=[],n=[];return x(this._columns,function(){(this.dataField||this.selector||this.calculateCellValue)&&f(this.sortIndex)&&!f(this.groupIndex)&&(t[this.sortIndex]=this)}),x(t,function(){let o=this&&this.sortOrder;if(su(o)){let s={selector:this.calculateSortValue||this.displayField||this.calculateDisplayValue||e&&this.selector||this.dataField||this.calculateCellValue,desc:this.sortOrder==="desc"};this.sortingMethod&&(s.compare=this.sortingMethod.bind(this)),n.push(s)}}),n.length>0?n:null}getGroupDataSourceParameters(e){let t=[];return x(this.getGroupColumns(),function(){let n=this.calculateGroupValue||this.displayField||this.calculateDisplayValue||e&&this.selector||this.dataField||this.calculateCellValue;if(n){let o={selector:n,desc:this.sortOrder==="desc",isExpanded:!!this.autoExpandGroup};this.sortingMethod&&(o.compare=this.sortingMethod.bind(this)),t.push(o)}}),t.length>0?t:null}refresh(e){let t=[];return x(this._columns,function(){let{lookup:n}=this;if(n&&!this.calculateDisplayValue){if(e&&n.valueMap)return;n.update&&t.push(n.update())}}),P.apply(u,t).done(au.bind(null,this))}_updateColumnOptions(e,t){var n,o;let s=this._reinitAfterLookupChanges&&((n=this._previousColumns)===null||n===void 0?void 0:n[t]);e.selector=e.selector??(l=>e.calculateCellValue(l)),e.selector.columnIndex=t,e.selector.originalCallback=s?((o=this._previousColumns[t].selector)===null||o===void 0?void 0:o.originalCallback)??e.selector:e.selector,x(["calculateSortValue","calculateGroupValue","calculateDisplayValue"],(l,d)=>{let c=e[d];if(A(c))if(c.originalCallback)e[d].context.column=e;else{let h={column:e};e[d]=function(p){return c.call(h.column,p)},e[d].originalCallback=c,e[d].columnIndex=t,e[d].context=h}}),B(e.calculateDisplayValue)&&(e.displayField=e.calculateDisplayValue,e.calculateDisplayValue=me(e.displayField)),e.calculateDisplayValue&&(e.displayValueMap=e.displayValueMap||{}),Gb(e,e.dataType);let{lookup:r}=e;r&&Gb(r,r.dataType);let a=r?r.dataType:e.dataType;a&&(e.alignment=e.alignment||VP(a,this.option("rtlEnabled")),e.format=e.format||M.getFormatByDataType(a),e.customizeText=e.customizeText||Kb(a),e.defaultFilterOperations=e.defaultFilterOperations||!r&&RP[a]||[],f(e.filterOperations)||$b(e),e.defaultFilterOperation=e.filterOperations&&e.filterOperations[0]||"=",e.showEditorAlways=f(e.showEditorAlways)?e.showEditorAlways:a==="boolean"&&!e.cellTemplate&&!e.lookup)}updateColumnDataTypes(e){let t=this,n=t.option("dateSerializationFormat"),o=t._getFirstItems(e),s=!1;return x(t._columns,(r,a)=>{let l,d,c,h,p,{lookup:g}=a;if(M.isDateType(a.dataType)&&a.serializationFormat===void 0&&(a.serializationFormat=n),g&&M.isDateType(g.dataType)&&a.serializationFormat===void 0&&(g.serializationFormat=n),a.calculateCellValue&&o.length){if(!a.dataType||g&&!g.dataType){for(l=0;l<o.length;l++)d=a.calculateCellValue(o[l]),a.dataType||(p=Wg(d),c=c||p,c&&p&&c!==p&&(c="string")),g&&!g.dataType&&(p=Wg(M.getDisplayValue(a,d,o[l])),h=h||p,h&&p&&h!==p&&(h="string"));(c||h)&&(c&&(a.dataType=c),g&&h&&(g.dataType=h),s=!0)}if(a.serializationFormat===void 0||g&&g.serializationFormat===void 0)for(l=0;l<o.length;l++)d=a.calculateCellValue(o[l],!0),a.serializationFormat===void 0&&(a.serializationFormat=Wb(a.dataType,d)),g&&g.serializationFormat===void 0&&(g.serializationFormat=Wb(g.dataType,g.calculateCellValue(d,!0)))}t._updateColumnOptions(a,r)}),s}_customizeColumns(e){let t=this,n=t.option("customizeColumns");n&&(e.some(s=>$(s.ownerBand))&&Fr(t),n(e),Sa(t,Mr(t,e)))}updateColumns(e,t,n){if(t||this.updateSortingGrouping(e),!e||e.isLoaded()){let o=e?e.sort()||[]:this.getSortDataSourceParameters(),s=e?e.group()||[]:this.getGroupDataSourceParameters(),r=e?.lastLoadOptions().filter;n||this._customizeColumns(this._columns),Fr(this);let a=this._columns;return P(this.refresh(!0)).always(()=>{this._columns===a&&(this._updateChanges(e,{sorting:o,grouping:s,filtering:r}),sd(this))})}}_updateChanges(e,t){e&&(this.updateColumnDataTypes(e),this._dataSourceApplied=!0),M.equalSortParameters(t.sorting,this.getSortDataSourceParameters())||Oo(this,"sorting"),M.equalSortParameters(t.grouping,this.getGroupDataSourceParameters())||Oo(this,"grouping"),this._dataController&&!M.equalFilterParameters(t.filtering,this._dataController.getCombinedFilter())&&Oo(this,"filtering"),Oo(this,"columns")}updateSortingGrouping(e,t){let n=this,o,s=function(a,l,d){x(a,(c,h)=>{if(delete h[d],l)for(let p=0;p<l.length;p++){let{selector:g}=l[p],{isExpanded:C}=l[p];if(g===h.dataField||g===h.name||g===h.displayField||g===h.selector||g===h.calculateCellValue||g===h.calculateGroupValue||g===h.calculateDisplayValue){t?h.sortOrder="sortOrder"in h?h.sortOrder:l[p].desc?"desc":"asc":h.sortOrder=h.sortOrder||(l[p].desc?"desc":"asc"),C!==void 0&&(h.autoExpandGroup=C),h[d]=p;break}}})};if(e){var r;let a=M.normalizeSortingInfo(e.sort()),l=M.normalizeSortingInfo(e.group()),d=n.getGroupDataSourceParameters(),c=n.getSortDataSourceParameters(),h=(r=this._columnChanges)===null||r===void 0?void 0:r.changeTypes,p=!M.equalSortParameters(a,c),g=t&&!(h!=null&&h.sorting),C=t&&!(h!=null&&h.grouping),v=!M.equalSortParameters(l,d,!0),b=!v&&!M.equalSortParameters(l,d);n._columns.length||(x(l,(T,R)=>{n._columns.push(R.selector)}),x(a,(T,R)=>{A(R.selector)||n._columns.push(R.selector)}),Sa(n,Mr(n,n._columns))),(C||!d&&!n._hasUserState)&&(v||b)&&(s(n._columns,l,"groupIndex"),t&&(v&&Oo(n,"grouping"),b&&Oo(n,"groupExpanding"),o=!0)),(g||!c&&!n._hasUserState)&&p&&(s(n._columns,a,"sortIndex"),t&&(Oo(n,"sorting"),o=!0)),o&&sd(n)}}updateFilter(e,t,n,o){let s=this;if(!Array.isArray(e))return e;if(e=m([],e),n=e.columnIndex!==void 0?e.columnIndex:n,o=e.filterValue!==void 0?e.filterValue:o,B(e[0])&&e[0]!=="!"){let r=s.columnOption(e[0]);t?fe().forceIsoDateParsing&&r&&r.serializeValue&&e.length>1&&(e[e.length-1]=r.serializeValue(e[e.length-1],"filter")):r&&r.selector&&(e[0]=r.selector,e[0].columnIndex=r.index)}else A(e[0])&&(e[0].columnIndex=n,e[0].filterValue=o,e[0].selectedFilterOperation=e.selectedFilterOperation);for(let r=0;r<e.length;r++)e[r]=s.updateFilter(e[r],t,n,o);return e}columnCount(){return this._columns?this._columns.length:0}columnOption(e,t,n,o){let s=this,r=s._columns.concat(s._commandColumns),a=iy(r,e);if(a){if(arguments.length===1)return m({},a);if(B(t)){if(arguments.length===2)return Kg(s,a,t);Kg(s,a,t,n,o)}else $(t)&&x(t,(l,d)=>{Kg(s,a,l,d,o)});sd(s)}}clearSorting(){let e=this,t=this.columnCount();e.beginUpdate();for(let n=0;n<t;n++)e.columnOption(n,"sortOrder",void 0),delete iy(e._columns,n).sortOrder;e.endUpdate()}clearGrouping(){let e=this,t=this.columnCount();e.beginUpdate();for(let n=0;n<t;n++)e.columnOption(n,"groupIndex",void 0);e.endUpdate()}getVisibleIndex(e,t){let n=this.getVisibleColumns(t);for(let o=n.length-1;o>=0;o--)if(n[o].index===e)return o;return-1}getVisibleIndexByColumn(e,t){let n=this.getVisibleColumns(t),o=n.filter(s=>s.index===e.index&&s.command===e.command)[0];return n.indexOf(o)}getVisibleColumnIndex(e,t){let n=this.columnOption(e,"index");return this.getVisibleIndex(n,t)}addColumn(e){let t=this,n=ru(t,e),o=t._columns.length;t._columns.push(n),n.isBand&&(t._columns=Mr(t,t._columns),n=t._columns[o]),n.added=e,Fr(t,n),t.updateColumns(t._dataSource),t._checkColumns()}deleteColumn(e){let t=this,n=t.columnOption(e);if(n&&n.index>=0){if(KP(t._columns),t._columns.splice(n.index,1),n.isBand){let o=t.getChildrenByBandColumn(n.index).map(s=>s.index);t._columns=t._columns.filter(s=>o.indexOf(s.index)<0)}Fr(t),t.updateColumns(t._dataSource)}}addCommandColumn(e){let t=this._commandColumns.filter(n=>n.command===e.command)[0];t||(t=e,this._commandColumns.push(t))}getUserState(){let e=this._columns,t=[],n;function o(s,r){e[n][r]!==void 0&&(t[n][r]=e[n][r])}for(n=0;n<e.length;n++)t[n]={},x(od,o);return t}setName(e){e.name=e.name||e.dataField||e.type}setUserState(e){let t=this,n=t._dataSource,o=t.option("stateStoring.ignoreColumnOptionNames");if(e?.forEach(this.setName),!o){o=[];let s=t.getCommonSettings();t.option("columnChooser.enabled")||o.push("visible"),t.option("sorting.mode")==="none"&&o.push("sortIndex","sortOrder"),s.allowGrouping||o.push("groupIndex"),s.allowFixing||o.push("fixed","fixedPosition"),s.allowResizing||o.push("width","visibleWidth");let r=!t.option("filterPanel.visible");!t.option("filterRow.visible")&&r&&o.push("filterValue","selectedFilterOperation"),!t.option("headerFilter.visible")&&r&&o.push("filterValues","filterType")}t._columnsUserState=e,t._ignoreColumnOptionNames=o,t._hasUserState=!!e,Oo(t,"filtering"),t.init(!0),n&&(n.sort(t.getSortDataSourceParameters()),n.group(t.getGroupDataSourceParameters()))}_checkColumns(){let e={},t=!1,n=[];this._columns.forEach(o=>{var s;let{name:r}=o,a=(s=o.columns)===null||s===void 0?void 0:s.length,l=o.allowEditing&&(o.dataField||o.setCellValue)&&!a;r?(e[r]&&n.push(`"${r}"`),e[r]=!0):l&&(t=!0)}),n.length&&Z.log("E1059",n.join(", ")),t&&Z.log("E1060")}_createCalculatedColumnOptions(e,t){let n={},{dataField:o}=e;if((Array.isArray(e.columns)&&e.columns.length||e.isBand)&&(n.isBand=!0,o=null),o){if(B(o)){let s=me(o);n={caption:kn(o),calculateCellValue(r,a){let l=s(r);return this.deserializeValue&&!a?this.deserializeValue(l):l},setCellValue:zP,parseValue(r){let a=this,l,d;return a.dataType==="number"?B(r)&&a.format?l=jP(r.trim(),a.format):f(r)&&xe(r)&&(l=Number(r)):a.dataType==="boolean"?r===a.trueText?l=!0:r===a.falseText&&(l=!1):M.isDateType(a.dataType)?(d=de.parse(r,a.format),d&&(l=d)):l=r,l}}}n.allowFiltering=!0}else n.allowFiltering=!!e.calculateFilterExpression;return n.calculateFilterExpression=function(){return Jn.defaultCalculateFilterExpression.apply(this,arguments)},n.defaultFilterOperation="=",n.createFilterExpression=function(s,r){let a;return this.calculateFilterExpression&&(a=this.calculateFilterExpression.apply(this,arguments)),A(a)&&(a=[a,"=",!0]),a&&(a.columnIndex=this.index,a.filterValue=s,a.selectedFilterOperation=r),a},(!o||!B(o))&&m(!0,n,{allowSorting:!1,allowGrouping:!1,calculateCellValue:()=>null}),t&&(n.allowFixing=!1),e.dataType&&(n.userDataType=e.dataType),e.selectedFilterOperation&&!("defaultSelectedFilterOperation"in n)&&(n.defaultSelectedFilterOperation=e.selectedFilterOperation),e.lookup&&(n.lookup={calculateCellValue(s,r){return this.valueExpr&&(s=this.valueMap&&this.valueMap[s]),this.deserializeValue&&!r?this.deserializeValue(s):s},updateValueMap(){if(this.valueMap={},this.items){let s=me(this.valueExpr),r=me(this.displayExpr);for(let a=0;a<this.items.length;a++){let l=this.items[a],d=r(l);this.valueMap[s(l)]=d,this.dataType=this.dataType||Wg(d)}}},update(){let s=this,{dataSource:r}=s;if(r)if(A(r)&&!It.isWrapped(r)&&(r=r({})),q(r)||r instanceof Cs||Array.isArray(r)){if(s.valueExpr){let a=Yi(r);return a.paginate=!1,r=new jt(a),r.load().done(l=>{s.items=l,s.updateValueMap&&s.updateValueMap()})}}else Z.log("E1016");else s.updateValueMap&&s.updateValueMap()}}),n.resizedCallbacks=ue(),e.resized&&n.resizedCallbacks.add(e.resized.bind(e)),x(n,s=>{if(A(n[s])&&s.indexOf("default")!==0){let r=`default${s.charAt(0).toUpperCase()}${s.substr(1)}`;n[r]=n[s]}}),n}getRowCount(){return this._rowCount=this._rowCount||WP(this),this._rowCount}getRowIndex(e,t){let n=this._columns[e],o=this.getBandColumnsCache();return n&&(t||n.visible&&!(n.command||f(n.groupIndex)))?Rr(e,o.columnParentByIndex).length:0}getChildrenByBandColumn(e,t){let n=this.getBandColumnsCache(),o=zb(e,n.columnChildrenByIndex,!t);return t?o.filter(s=>s.visible&&!s.command).sort((s,r)=>s.visibleIndex-r.visibleIndex):o}isParentBandColumn(e,t){let n=!1,o=this._columns[e],s=this.getBandColumnsCache(),r=o&&Rr(e,s.columnParentByIndex);return r&&x(r,(a,l)=>{if(l.index===t)return n=!0,!1}),n}isParentColumnVisible(e){let t=!0,n=this.getBandColumnsCache(),o=e>=0&&Rr(e,n.columnParentByIndex);return o&&x(o,(s,r)=>(t=t&&r.visible,t)),t}getColumnId(e){return e.command&&e.type===Zo?Ug(this,e)?`type:${e.type}`:`command:${e.command}`:e.index}getCustomizeTextByDataType(e){return Kb(e)}getHeaderContentAlignment(e){return this.option("rtlEnabled")?e==="left"?"right":"left":e}},oy={defaultOptions:()=>({commonColumnSettings:{allowFiltering:!0,allowHiding:!0,allowSorting:!0,allowEditing:!0,encodeHtml:!0,trueText:O.format("dxDataGrid-trueText"),falseText:O.format("dxDataGrid-falseText")},allowColumnReordering:!1,allowColumnResizing:!1,columnResizingMode:"nextColumn",columnMinWidth:void 0,columnWidth:void 0,adaptColumnWidthByRatio:!0,columns:void 0,regenerateColumnsByVisibleItems:!1,customizeColumns:null,dateSerializationFormat:void 0}),controllers:{columns:ny}};H.registerModule("columns",{defaultOptions:()=>m(!0,{},oy.defaultOptions(),{commonColumnSettings:{allowExporting:!0}}),controllers:oy.controllers});var qP="_dataSourceChangedHandler";var YP="_getSpecificDataSourceOption",XP="_normalizeDataSource",QP=i=>class extends i{postCtor(){this.on("disposing",()=>{this._disposeDataSource()})}_refreshDataSource(){this._initDataSource(),this._loadDataSource()}_initDataSource(){let e=YP in this?this[YP]():this.option("dataSource"),t,n;this._disposeDataSource(),e&&(e instanceof jt?(this._isSharedDataSource=!0,this._dataSource=e):(t="_dataSourceOptions"in this?this._dataSourceOptions():{},n=this._dataSourceType?this._dataSourceType():jt,e=Yi(e,{fromUrlLoadMode:"_dataSourceFromUrlLoadMode"in this&&this._dataSourceFromUrlLoadMode()}),this._dataSource=new n(m(!0,{},t,e))),XP in this&&(this._dataSource=this[XP](this._dataSource)),this._addDataSourceHandlers(),this._initDataController())}_initDataController(){var e;let t=(e=this.option)===null||e===void 0?void 0:e.call(this,"_dataController"),n=this._dataSource;t?this._dataController=t:this._dataController=new Kh(n)}_addDataSourceHandlers(){qP in this&&this._addDataSourceChangeHandler(),"_dataSourceLoadErrorHandler"in this&&this._addDataSourceLoadErrorHandler(),"_dataSourceLoadingChangedHandler"in this&&this._addDataSourceLoadingChangedHandler(),this._addReadyWatcher()}_addReadyWatcher(){this.readyWatcher=function(e){this._ready&&this._ready(!e)}.bind(this),this._dataSource.on("loadingChanged",this.readyWatcher)}_addDataSourceChangeHandler(){let e=this._dataSource;this._proxiedDataSourceChangedHandler=function(t){this[qP](e.items(),t)}.bind(this),e.on("changed",this._proxiedDataSourceChangedHandler)}_addDataSourceLoadErrorHandler(){this._proxiedDataSourceLoadErrorHandler=this._dataSourceLoadErrorHandler.bind(this),this._dataSource.on("loadError",this._proxiedDataSourceLoadErrorHandler)}_addDataSourceLoadingChangedHandler(){this._proxiedDataSourceLoadingChangedHandler=this._dataSourceLoadingChangedHandler.bind(this),this._dataSource.on("loadingChanged",this._proxiedDataSourceLoadingChangedHandler)}_loadDataSource(){let e=this._dataSource;e&&(e.isLoaded()?this._proxiedDataSourceChangedHandler&&this._proxiedDataSourceChangedHandler():e.load())}_loadSingle(e,t){return e=e==="this"?this._dataSource.key()||"this":e,this._dataSource.loadSingle(e,t)}_isLastPage(){return!this._dataSource||this._dataSource.isLastPage()||!this._dataSource._pageSize}_isDataSourceLoading(){return this._dataSource&&this._dataSource.isLoading()}_disposeDataSource(){this._dataSource&&(this._isSharedDataSource?(delete this._isSharedDataSource,this._proxiedDataSourceChangedHandler&&this._dataSource.off("changed",this._proxiedDataSourceChangedHandler),this._proxiedDataSourceLoadErrorHandler&&this._dataSource.off("loadError",this._proxiedDataSourceLoadErrorHandler),this._proxiedDataSourceLoadingChangedHandler&&this._dataSource.off("loadingChanged",this._proxiedDataSourceLoadingChangedHandler),this._dataSource._eventsStrategy&&this._dataSource._eventsStrategy.off("loadingChanged",this.readyWatcher)):this._dataSource.dispose(),delete this._dataSource,delete this._proxiedDataSourceChangedHandler,delete this._proxiedDataSourceLoadErrorHandler,delete this._proxiedDataSourceLoadingChangedHandler)}getDataSource(){return this._dataSource||null}};var ZP=function(i,e,t){let n=i._dataSource;if(n){if(t!==void 0){if(i._getPagingOptionValue(e)!==t){e==="pageSize"&&n.pageIndex(0),n[e](t),i._skipProcessingPagingChange=!0,i.option(`paging.${e}`,t),i._skipProcessingPagingChange=!1;let s=n.pageIndex();return i._isPaging=e==="pageIndex",n[e==="pageIndex"?"load":"reload"]().done(()=>{i._isPaging=!1,i.pageChanged.fire(s)})}return y().resolve().promise()}return n[e]()}return e==="pageIndex"&&t!==void 0?y().resolve().promise():0},lu=class extends QP(Ce.Controller){init(){this._items=[],this._cachedProcessedItems=null,this._columnsController=this.getController("columns"),this._adaptiveColumnsController=this.getController("adaptiveColumns"),this._editingController=this.getController("editing"),this._editorFactoryController=this.getController("editorFactory"),this._errorHandlingController=this.getController("errorHandling"),this._filterSyncController=this.getController("filterSync"),this._applyFilterController=this.getController("applyFilter"),this._keyboardNavigationController=this.getController("keyboardNavigation"),this._focusController=this.getController("focus"),this._headerFilterController=this.getController("headerFilter"),this._selectionController=this.getController("selection"),this._stateStoringController=this.getController("stateStoring"),this._validatingController=this.getController("validating"),this._isPaging=!1,this._currentOperationTypes=null,this._dataChangedHandler=e=>{this._currentOperationTypes=this._dataSource.operationTypes(),this._handleDataChanged(e),this._currentOperationTypes=null},this._columnsChangedHandler=this._handleColumnsChanged.bind(this),this._loadingChangedHandler=this._handleLoadingChanged.bind(this),this._loadErrorHandler=this._handleLoadError.bind(this),this._customizeStoreLoadOptionsHandler=this._handleCustomizeStoreLoadOptions.bind(this),this._changingHandler=this._handleChanging.bind(this),this._dataPushedHandler=this._handleDataPushed.bind(this),this._columnsController.columnsChanged.add(this._columnsChangedHandler),this._isLoading=!1,this._isCustomLoading=!1,this._repaintChangesOnly=void 0,this._changes=[],this.createAction("onDataErrorOccurred"),this.dataErrorOccurred.add(e=>this.executeAction("onDataErrorOccurred",{error:e})),this._refreshDataSource(),this.postCtor()}_getPagingOptionValue(e){return this._dataSource[e]()}callbackNames(){return["changed","loadingChanged","dataErrorOccurred","pageChanged","dataSourceChanged","pushed"]}callbackFlags(e){if(e==="dataErrorOccurred")return{stopOnFalse:!0}}publicMethods(){return["_disposeDataSource","beginCustomLoading","byKey","clearFilter","endCustomLoading","filter","getCombinedFilter","getDataByKeys","getDataSource","getKeyByRowIndex","getRowIndexByKey","getVisibleRows","keyOf","pageCount","pageIndex","pageSize","refresh","repaintRows","totalCount"]}reset(){this._columnsController.reset(),this._items=[],this._refreshDataSource()}_handleDataSourceChange(e){if(e.value===e.previousValue||this.option("columns")&&Array.isArray(e.value)&&Array.isArray(e.previousValue)){if(e.value!==e.previousValue){let n=this.store();n&&(n._array=e.value)}return this.needToRefreshOnDataSourceChange(e)&&this.refresh(this.option("repaintChangesOnly")),!0}return!1}needToRefreshOnDataSourceChange(e){return!0}optionChanged(e){let t=this,n,o;function s(){e.handled=!0}if(e.name==="dataSource"&&e.name===e.fullName&&this._handleDataSourceChange(e)){s();return}switch(e.name){case"cacheEnabled":case"repaintChangesOnly":case"highlightChanges":case"loadingTimeout":s();break;case"remoteOperations":case"keyExpr":case"dataSource":case"scrolling":s(),t.reset();break;case"paging":if(n=t.dataSource(),n&&(o=t._setPagingOptions(n),o)){let r=n.pageIndex();this._isPaging=o.isPageIndexChanged,n.load().done(()=>{this._isPaging=!1,t.pageChanged.fire(r)})}s();break;case"rtlEnabled":t.reset();break;case"columns":n=t.dataSource(),n&&n.isLoading()&&e.name===e.fullName&&(this._useSortingGroupingFromColumns=!0,n.load());break;default:super.optionChanged(e)}}isReady(){return!this._isLoading}getDataSource(){return this._dataSource&&this._dataSource._dataSource}getCombinedFilter(e){return this.combinedFilter(void 0,e)}combinedFilter(e,t){if(!this._dataSource)return e;let n=e??this._dataSource.filter();if(this._columnsController.isDataSourceApplied()||this._columnsController.isAllDataTypesDefined()){let r=this._calculateAdditionalFilter();n=r?M.combineFilters([r,n]):n}let s=this._dataSource.remoteOperations().filtering||t;return n=this._columnsController.updateFilter(n,s),n}waitReady(){return this._updateLockCount?(this._readyDeferred=new y,this._readyDeferred):P()}_endUpdateCore(){let e=this._changes;if(e.length){this._changes=[];let t=e.every(n=>n.repaintChangesOnly);this.updateItems(e.length===1?e[0]:{repaintChangesOnly:t})}this._readyDeferred&&(this._readyDeferred.resolve(),this._readyDeferred=null)}_handleCustomizeStoreLoadOptions(e){var t;let n=this._columnsController,o=this._dataSource,{storeLoadOptions:s}=e;e.isCustomLoading&&!s.isLoadingAll||(s.filter=this.combinedFilter(s.filter),((t=s.filter)===null||t===void 0?void 0:t.length)===1&&s.filter[0]==="!"&&(e.data=[],e.extra=e.extra||{},e.extra.totalCount=0),n.isDataSourceApplied()||n.updateColumnDataTypes(o),this._columnsUpdating=!0,n.updateSortingGrouping(o,!this._useSortingGroupingFromColumns),this._columnsUpdating=!1,s.sort=n.getSortDataSourceParameters(),s.group=n.getGroupDataSourceParameters(),o.sort(s.sort),o.group(s.group),s.sort=n.getSortDataSourceParameters(!o.remoteOperations().sorting),e.group=n.getGroupDataSourceParameters(!o.remoteOperations().grouping))}_handleColumnsChanged(e){let t=this,{changeTypes:n}=e,{optionNames:o}=e,s,r,a,l=function(d){var c;t._columnsController.columnsChanged.remove(l),t.updateItems({repaintChangesOnly:!1,virtualColumnsScrolling:d==null||(c=d.changeTypes)===null||c===void 0?void 0:c.virtualColumnsScrolling})};if(n.sorting||n.grouping)t._dataSource&&!t._columnsUpdating&&(t._dataSource.group(t._columnsController.getGroupDataSourceParameters()),t._dataSource.sort(t._columnsController.getSortDataSourceParameters()),t.reload());else if(n.columns&&(r=t._columnsController.columnOption(e.columnIndex,"filterValues"),(o.filterValues||o.filterType&&Array.isArray(r)||o.filterValue||o.selectedFilterOperation||o.allowFiltering)&&(s=t._columnsController.columnOption(e.columnIndex,"filterValue"),(Array.isArray(r)||e.columnIndex===void 0||f(s)||!o.selectedFilterOperation||o.filterValue)&&(t._applyFilter(),a=!0)),!t._needApplyFilter&&!M.checkChanges(o,["width","visibleWidth","filterValue","bufferedFilterValue","selectedFilterOperation","filterValues","filterType"])&&t._columnsController.columnsChanged.add(l),f(o.visible))){let d=t._columnsController.columnOption(e.columnIndex);d&&(f(d.filterValue)||f(d.filterValues))&&(t._applyFilter(),a=!0)}!a&&n.filtering&&!this._needApplyFilter&&t.reload()}_handleDataChanged(e){let t=this,n=t._dataSource,o=t._columnsController,s=!1;this._useSortingGroupingFromColumns=!1,n&&!t._isDataSourceApplying&&(t._isDataSourceApplying=!0,P(t._columnsController.applyDataSource(n)).done(()=>{t._isLoading&&t._handleLoadingChanged(!1),s&&e&&e.isDelayed&&(e.isDelayed=!1),t._isDataSourceApplying=!1;let r=t._needApplyFilter;t._needApplyFilter=!1,r&&!t._isAllDataTypesDefined&&(()=>{let a=t._calculateAdditionalFilter();return a&&a.length})()?(Z.log("W1005",t.component.NAME),t._applyFilter()):t.updateItems(e,!0)}).fail(()=>{t._isDataSourceApplying=!1}),t._isDataSourceApplying&&(s=!0,t._handleLoadingChanged(!0)),t._needApplyFilter=!t._columnsController.isDataSourceApplied(),t._isAllDataTypesDefined=o.isAllDataTypesDefined())}_handleLoadingChanged(e){this._isLoading=e,this._fireLoadingChanged()}_handleLoadError(e){this.dataErrorOccurred.fire(e)}_handleDataPushed(e){this.pushed.fire(e)}fireError(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.dataErrorOccurred.fire(Z.Error.apply(Z,t))}_setPagingOptions(e){let t=this.option("paging.pageIndex"),n=this.option("paging.pageSize"),o=this.option("paging.enabled"),s=this.option("scrolling.mode"),r=s==="infinite",l=o||s==="virtual"||r,d=!1,c=!1,h=!1;return e.requireTotalCount(!r),o!==void 0&&e.paginate()!==l&&(e.paginate(l),d=!0),n!==void 0&&e.pageSize()!==n&&(e.pageSize(n),c=!0),t!==void 0&&e.pageIndex()!==t&&(e.pageIndex(t),h=!0),d||c||h?{isPaginateChanged:d,isPageSizeChanged:c,isPageIndexChanged:h}:!1}_getSpecificDataSourceOption(){let e=this.option("dataSource");return Array.isArray(e)?{store:{type:"array",data:e,key:this.option("keyExpr")}}:e}_initDataSource(){let e=this,t=this._dataSource;super._initDataSource();let n=e._dataSource;if(e._useSortingGroupingFromColumns=!0,e._cachedProcessedItems=null,n){let o=e._setPagingOptions(n);this._isPaging=o?.isPageIndexChanged,e.setDataSource(n)}else t&&e.updateItems()}_loadDataSource(){let e=this,t=e._dataSource,n=new y;return P(this._columnsController.refresh(!0)).always(()=>{t?t.load().done(function(){e._isPaging=!1,n.resolve.apply(n,arguments)}).fail(n.reject):n.resolve()}),n.promise()}_beforeProcessItems(e){return e.slice(0)}getRowIndexDelta(){return 0}getDataIndex(e){let t=this._items,n=e.changeType==="append"&&t.length>0?t[t.length-1]:null;return f(n?.dataIndex)?n.dataIndex+1:0}_processItems(e,t){let n=this,o=n.getRowIndexDelta(),{changeType:s}=t,r=n._columnsController.getVisibleColumns(null,s==="loadingAll"),a=this.getDataIndex(t),l={visibleColumns:r,dataIndex:a},d=[];return x(e,(c,h)=>{f(h)&&(l.rowIndex=c-o,h=n._processItem(h,l),d.push(h))}),d}_processItem(e,t){return e=this._generateDataItem(e,t),e=this._processDataItem(e,t),e.dataIndex=t.dataIndex++,e}_generateDataItem(e,t){return{rowType:"data",data:e,key:this.keyOf(e)}}_processDataItem(e,t){return e.values=this.generateDataValues(e.data,t.visibleColumns),e}generateDataValues(e,t,n){let o=[],s;for(let r=0;r<t.length;r++){let a=t[r];s=n?void 0:null,a.command||(a.calculateCellValue?s=a.calculateCellValue(e):a.dataField&&(s=e[a.dataField])),o.push(s)}return o}_applyChange(e){let t=this;e.changeType==="update"?t._applyChangeUpdate(e):t.items().length&&e.repaintChangesOnly&&e.changeType==="refresh"?t._applyChangesOnly(e):e.changeType==="refresh"&&t._applyChangeFull(e)}_applyChangeFull(e){this._items=e.items.slice(0)}_getRowIndices(e){let t=e.rowIndices.slice(0),n=this.getRowIndexDelta();t.sort((o,s)=>o-s);for(let o=0;o<t.length;o++){let s=t[o];e.allowInvisibleRowIndices&&(s+=n),s<0&&(t.splice(o,1),o--)}return t}_applyChangeUpdate(e){let t=this,{items:n}=e,o=t._getRowIndices(e),s=t.getRowIndexDelta(),r=t.option("repaintChangesOnly"),a=-1,l=0,d;e.items=[],e.rowIndices=[],e.columnIndices=[],e.changeTypes=[];let c=function(h,p,g){let C=h&&p&&ve(h.key,p.key);return C&&g&&(C=h.rowType===p.rowType&&(p.rowType!=="detail"||h.isEditing===p.isEditing)),C};x(o,(h,p)=>{let g;if(p+=l+s,a===p)return;a=p;let C=t._items[p],v=t._items[p+1],b=n[p],T=n[p+1],R=c(C,v)||c(b,T);if(b&&(b.rowIndex=p,e.items.push(b)),C&&b&&c(C,b,R))d="update",t._items[p]=b,C.visible!==b.visible?e.items.splice(-1,1,{visible:b.visible}):r&&!e.isFullUpdate&&(g=t._partialUpdateRow(C,b,p-s));else if(b&&!C||T&&c(C,T,R))d="insert",t._items.splice(p,0,b),l++;else if(C&&!b||v&&c(b,v,R))d="remove",t._items.splice(p,1),l--,a=-1;else if(b)d="update",t._items[p]=b;else return;e.rowIndices.push(p-s),e.changeTypes.push(d),e.columnIndices.push(g)})}_isCellChanged(e,t,n,o,s){if(JSON.stringify(e.values[o])!==JSON.stringify(t.values[o]))return!0;function r(a,l){return a.modifiedValues?a.modifiedValues[l]!==void 0:!1}return r(e,o)!==r(t,o)}_getChangedColumnIndices(e,t,n,o){let s;if(e.rowType===t.rowType){if(t.rowType!=="group"&&t.rowType!=="groupFooter"&&(s=[],t.rowType!=="detail"))for(let r=0;r<e.values.length;r++)this._isCellChanged(e,t,n,r,o)&&s.push(r);t.rowType==="group"&&e.cells&&t.isExpanded===e.isExpanded&&t.data.isContinuation===e.data.isContinuation&&t.data.isContinuationOnNextPage===e.data.isContinuationOnNextPage&&(s=e.cells.map((a,l)=>{var d;return((d=a.column)===null||d===void 0?void 0:d.type)!=="groupExpand"?l:-1}).filter(a=>a>=0))}return s}_partialUpdateRow(e,t,n,o){var s;let r=this._getChangedColumnIndices(e,t,n,o);return(s=r)!==null&&s!==void 0&&s.length&&this.option("dataRowTemplate")&&(r=void 0),r&&(e.cells&&e.cells.forEach((a,l)=>{!(r.indexOf(l)>=0)&&a&&a.update&&a.update(t)}),t.update=e.update,t.watch=e.watch,t.cells=e.cells,o&&(t.oldValues=e.values),e.update&&e.update(t)),r}_isItemEquals(e,t){if(JSON.stringify(e.values)!==JSON.stringify(t.values)||["modified","isNewRow","removed","isEditing"].some(a=>e[a]!==t[a]))return!1;if(e.rowType==="group"||e.rowType==="groupFooter"){var n,o,s,r;let a=e.isExpanded===t.isExpanded,l=JSON.stringify(e.summaryCells)===JSON.stringify(t.summaryCells),d=((n=e.data)===null||n===void 0?void 0:n.isContinuation)===((o=t.data)===null||o===void 0?void 0:o.isContinuation)&&((s=e.data)===null||s===void 0?void 0:s.isContinuationOnNextPage)===((r=t.data)===null||r===void 0?void 0:r.isContinuationOnNextPage);if(!a||!l||!d)return!1}return!0}_applyChangesOnly(e){let t=[],n=[],o=[],s=[],r={},a=e?.isLiveUpdate??!0;function l(p){if(p)return`${p.rowType},${JSON.stringify(p.key)}`}let d=this._items,c=d.slice();e.items.forEach((p,g)=>{let C=l(p);r[C]=g,p.rowIndex=g});let h=Fh(c,e.items,l,(p,g)=>this._isItemEquals(p,g)?(p.cells&&(p.update&&p.update(g),p.cells.forEach(C=>{C&&C.update&&C.update(g,!0)})),!0):!1);if(!h){this._applyChangeFull(e);return}h.forEach(p=>{switch(p.type){case"update":{let{index:g}=p,C=p.data,{oldItem:v}=p,b=this._partialUpdateRow(v,C,g,a);t.push(g),o.push("update"),s.push(C),d[g]=C,n.push(b);break}case"insert":t.push(p.index),o.push("insert"),s.push(p.data),n.push(void 0),d.splice(p.index,0,p.data);break;case"remove":t.push(p.index),o.push("remove"),d.splice(p.index,1),s.push(p.oldItem),n.push(void 0)}}),e.repaintChangesOnly=!0,e.changeType="update",e.rowIndices=t,e.columnIndices=n,e.changeTypes=o,e.items=s,c.length&&(e.isLiveUpdate=!0),this._correctRowIndices(p=>{let g=this._rowIndexOffset||0,C=this.getRowIndexOffset(),v=c[p-g],b=l(v),T=r[b];return T>=0?T+C-p:0})}_correctRowIndices(e){}_afterProcessItems(e,t){return e}_updateItemsCore(e){let t,n=this._dataSource,o=e.changeType||"refresh";if(e.changeType=o,n){let s=this._cachedProcessedItems;e.useProcessedItemsCache&&s?t=s:(t=e.items||n.items(),t=this._beforeProcessItems(t),t=this._processItems(t,e),this._cachedProcessedItems=t),t=this._afterProcessItems(t,e),e.items=t;let r=this._items.length===t.length&&this._items;this._applyChange(e);let a=this.getRowIndexDelta();x(this._items,(l,d)=>{d.rowIndex=l-a,r&&(d.cells=r[l].cells??[]);let c=t[l];c&&(d.loadIndex=c.loadIndex)}),this._rowIndexOffset=this.getRowIndexOffset()}else this._items=[]}_handleChanging(e){let t=this.getVisibleRows();this.dataSource()&&e.changes.forEach(o=>{if(o.type==="insert"&&o.index>=0){let s=0;for(let r=0;r<o.index;r++){let a=t[r];a&&(a.rowType==="data"||a.rowType==="group")&&s++}o.index=s}})}updateItems(e,t){e=e||{};let n=this;if(n._repaintChangesOnly!==void 0)e.repaintChangesOnly=e.repaintChangesOnly??n._repaintChangesOnly,e.needUpdateDimensions=e.needUpdateDimensions||n._needUpdateDimensions;else if(e.changes)e.repaintChangesOnly=n.option("repaintChangesOnly");else if(t){let o=n.dataSource().operationTypes();e.repaintChangesOnly=o&&!o.grouping&&!o.filtering&&n.option("repaintChangesOnly"),e.isDataChanged=!0,o&&(o.reload||o.paging||o.groupExpanding)&&(e.needUpdateDimensions=!0)}if(n._updateLockCount&&!e.cancel){n._changes.push(e);return}n._updateItemsCore(e),!e.cancel&&n._fireChanged(e)}loadingOperationTypes(){let e=this.dataSource();return e&&e.loadingOperationTypes()||{}}_fireChanged(e){this._currentOperationTypes&&(e.operationTypes=this._currentOperationTypes,this._currentOperationTypes=null),nt(()=>{this.changed.fire(e)})}isLoading(){return this._isLoading||this._isCustomLoading}_fireLoadingChanged(){this.loadingChanged.fire(this.isLoading(),this._loadingText)}_calculateAdditionalFilter(){return null}_applyFilter(){let e=this._dataSource;return e?(e.pageIndex(0),this._isFilterApplying=!0,this.reload().done(()=>{this._isFilterApplying&&this.pageChanged.fire()})):new y().resolve()}resetFilterApplying(){this._isFilterApplying=!1}filter(e){let t=this._dataSource,n=t&&t.filter();if(arguments.length===0)return n;e=arguments.length>1?Array.prototype.slice.call(arguments,0):e,!M.equalFilterParameters(n,e)&&(t&&t.filter(e),this._applyFilter())}clearFilter(e){let t=this,n=t._columnsController,o=function(s){let r=n.columnCount();for(let a=0;a<r;a++)n.columnOption(a,s,void 0)};if(t.component.beginUpdate(),arguments.length>0)switch(e){case"dataSource":t.filter(null);break;case"search":t.searchByText("");break;case"header":o("filterValues");break;case"row":o("filterValue")}else t.filter(null),t.searchByText(""),o("filterValue"),o("bufferedFilterValue"),o("filterValues");t.component.endUpdate()}_fireDataSourceChanged(){let e=this,t=function(){e.changed.remove(t),e.dataSourceChanged.fire()};e.changed.add(t)}_getDataSourceAdapter(){}_createDataSourceAdapterCore(e,t){let o=this._getDataSourceAdapter().create(this.component);return o.init(e,t),o}isLocalStore(){return(arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.store())instanceof No}isCustomStore(e){return e=e||this.store(),e instanceof ea}_createDataSourceAdapter(e){let t=this.option("remoteOperations"),n=e.store(),o={filtering:!0,sorting:!0,paging:!0,grouping:!0,summary:!0};return $(t)&&t.groupPaging&&(t=m({},o,t)),t==="auto"&&(t=this.isLocalStore(n)||this.isCustomStore(n)?{}:{filtering:!0,sorting:!0,paging:!0}),t===!0&&(t=o),this._createDataSourceAdapterCore(e,t)}setDataSource(e){let t=this,n=t._dataSource;!e&&n&&(n.cancelAll(),n.changed.remove(t._dataChangedHandler),n.loadingChanged.remove(t._loadingChangedHandler),n.loadError.remove(t._loadErrorHandler),n.customizeStoreLoadOptions.remove(t._customizeStoreLoadOptionsHandler),n.changing.remove(t._changingHandler),n.pushed.remove(t._dataPushedHandler),n.dispose(t._isSharedDataSource)),e&&(e=t._createDataSourceAdapter(e)),t._dataSource=e,e&&(t._fireDataSourceChanged(),t._isLoading=!e.isLoaded(),t._needApplyFilter=!0,t._isAllDataTypesDefined=t._columnsController.isAllDataTypesDefined(),e.changed.add(t._dataChangedHandler),e.loadingChanged.add(t._loadingChangedHandler),e.loadError.add(t._loadErrorHandler),e.customizeStoreLoadOptions.add(t._customizeStoreLoadOptionsHandler),e.changing.add(t._changingHandler),e.pushed.add(t._dataPushedHandler))}items(e){return this._items}isEmpty(){return!this.items().length}pageCount(){return this._dataSource?this._dataSource.pageCount():1}dataSource(){return this._dataSource}store(){let e=this._dataSource;return e&&e.store()}loadAll(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=this,o=new y,s=n._dataSource;if(s)if(e){let r={data:e,isCustomLoading:!0,storeLoadOptions:{isLoadingAll:!0},loadOptions:{filter:t?null:n.getCombinedFilter(),group:s.group(),sort:s.sort()}};s._handleDataLoaded(r),P(r.data).done(a=>{var l;a=n._beforeProcessItems(a),o.resolve(n._processItems(a,{changeType:"loadingAll"}),(l=r.extra)===null||l===void 0?void 0:l.summary)}).fail(o.reject)}else if(s.isLoading())o.reject();else{let r=m({},s.loadOptions(),{isLoadingAll:!0,requireTotalCount:!1});s.load(r).done((a,l)=>{a=n._beforeProcessItems(a),a=n._processItems(a,{changeType:"loadingAll"}),o.resolve(a,l&&l.summary)}).fail(o.reject)}else o.resolve([]);return o}getKeyByRowIndex(e,t){let n=this.items(t)[e];if(n)return n.key}getRowIndexByKey(e,t){return M.getIndexByKey(e,this.items(t))}keyOf(e){let t=this.store();if(t)return t.keyOf(e)}byKey(e){let t=this.store(),n=this.getRowIndexByKey(e),o;if(t)return n>=0&&(o=new y().resolve(this.items()[n].data)),o||t.byKey(e)}key(){let e=this.store();if(e)return e.key()}getRowIndexOffset(e){return 0}getDataByKeys(e){let t=this,n=new y,o=[],s=[];return x(e,(r,a)=>{o.push(t.byKey(a).done(l=>{s[r]=l}))}),P.apply(u,o).always(()=>{n.resolve(s)}),n}pageIndex(e){return ZP(this,"pageIndex",e)}pageSize(e){return ZP(this,"pageSize",e)}beginCustomLoading(e){this._isCustomLoading=!0,this._loadingText=e||"",this._fireLoadingChanged()}endCustomLoading(){this._isCustomLoading=!1,this._loadingText=void 0,this._fireLoadingChanged()}refresh(e){e===!0?e={reload:!0,changesOnly:!0}:e||(e={lookup:!0,selection:!0,reload:!0});let t=this,n=t.getDataSource(),{changesOnly:o}=e,s=new y,r=function(){t._repaintChangesOnly=!!o};return P(!e.lookup||t._columnsController.refresh()).always(()=>{e.load||e.reload?(n&&n.on("customizeLoadResult",r),P(t.reload(e.reload,o)).always(()=>{n&&n.off("customizeLoadResult",r),t._repaintChangesOnly=void 0}).done(s.resolve).fail(s.reject)):(t.updateItems({repaintChangesOnly:e.changesOnly}),s.resolve())}),s.promise()}getVisibleRows(){return this.items()}_disposeDataSource(){this._dataSource&&this._dataSource._eventsStrategy&&this._dataSource._eventsStrategy.off("loadingChanged",this.readyWatcher),this.setDataSource(null)}dispose(){this._disposeDataSource(),super.dispose()}repaintRows(e,t){e=Array.isArray(e)?e:[e],(e.length>1||f(e[0]))&&this.updateItems({changeType:"update",rowIndices:e,isFullUpdate:!t})}skipProcessingPagingChange(e){return this._skipProcessingPagingChange&&(e==="paging.pageIndex"||e==="paging.pageSize")}getUserState(){return{searchText:this.option("searchPanel.text"),pageIndex:this.pageIndex(),pageSize:this.pageSize()}}getCachedStoreData(){return this._dataSource&&this._dataSource.getCachedStoreData()}isLastPageLoaded(){let e=this.pageIndex(),t=this.pageCount();return e===t-1}load(){var e;return(e=this._dataSource)===null||e===void 0?void 0:e.load()}reload(e,t){var n;return(n=this._dataSource)===null||n===void 0?void 0:n.reload(e,t)}push(){for(var e,t=arguments.length,n=new Array(t),o=0;o<t;o++)n[o]=arguments[o];return(e=this._dataSource)===null||e===void 0?void 0:e.push(...n)}itemsCount(){var e;return this._dataSource?(e=this._dataSource)===null||e===void 0?void 0:e.itemsCount():0}totalItemsCount(){var e;return this._dataSource?(e=this._dataSource)===null||e===void 0?void 0:e.totalItemsCount():0}hasKnownLastPage(){var e;return this._dataSource?(e=this._dataSource)===null||e===void 0?void 0:e.hasKnownLastPage():!0}isLoaded(){var e;return this._dataSource?(e=this._dataSource)===null||e===void 0?void 0:e.isLoaded():!0}totalCount(){var e;return this._dataSource?(e=this._dataSource)===null||e===void 0?void 0:e.totalCount():0}hasLoadOperation(){var e;let t=((e=this._dataSource)===null||e===void 0?void 0:e.operationTypes())??{};return Object.keys(t).some(n=>t[n])}},JP={defaultOptions:()=>({loadingTimeout:0,dataSource:null,cacheEnabled:!0,repaintChangesOnly:!1,highlightChanges:!1,onDataErrorOccurred:null,remoteOperations:"auto",paging:{enabled:!0,pageSize:void 0,pageIndex:void 0}}),controllers:{data:lu}};var du=function(i,e){if(i&&(i=i.slice(0),e))for(let t=0;t<i.length;t++)i[t]=m({key:i[t].key},i[t]),i[t].items=du(i[t].items,e-1);return i},sy=function(i,e,t){let n={reload:!0,fullReload:!0};return e&&(n={sorting:!M.equalSortParameters(i.sort,e.sort),grouping:!M.equalSortParameters(i.group,e.group,!0),groupExpanding:!M.equalSortParameters(i.group,e.group)||e.groupExpand,filtering:!M.equalFilterParameters(i.filter,e.filter),pageIndex:i.pageIndex!==e.pageIndex,skip:i.skip!==e.skip,take:i.take!==e.take,pageSize:i.pageSize!==e.pageSize,fullReload:t,reload:!1,paging:!1},n.reload=t||n.sorting||n.grouping||n.filtering,n.paging=n.pageIndex||n.pageSize||n.take),n},ek=function(i,e){f(e)?Ua(i,e):i()},rd=function(){return{items:{}}},ry=function(i,e){let t=M.normalizeSortingInfo(i.group||i.storeLoadOptions.group||i.loadOptions.group).length,n=[];if(tk(n,i,t))return n;e&&YY(n,i,t)},tk=function(i,e,t,n){var o;let{storeLoadOptions:s}=e,r=e.take??s.take??0,a=(o=e.cachedData)===null||o===void 0?void 0:o.items;if(r&&a){let l=e.skip??s.skip??0;for(let d=0;d<r;d+=1){let c=n?r-1-d:d,h=c+l,p=a[h];if(p===void 0&&h in a)return!0;let g=qY(e,p,t,c,r);if(g)i.push(g);else return!1}return!0}return!1},qY=function(i,e,t,n,o){if(t&&e){let s=n===0&&i.skips||[],r=n===o-1&&i.takes||[];return ik(e,t,s,r)}return e},ik=function(i,e,t,n){if(e&&i){let o=I({},i),s=t[0]||0,r=n[0],{items:a}=i;if(a){if(r===void 0&&!a[s])return;o.items=[],t.length&&(o.isContinuation=!0),r&&(o.isContinuationOnNextPage=i.count>r);for(let l=0;r===void 0?a[l+s]:l<r;l+=1){let d=a[l+s],c=l+1===r,h=ik(d,e-1,l===0?t.slice(1):[],c?n.slice(1):[]);if(h!==void 0)o.items.push(h);else return}}return o}return i},YY=function(i,e,t){let n=i.length,{storeLoadOptions:o}=e;if(o.skip!==void 0&&o.take&&!t){let s=[];tk(s,e,t,!0);let r=s.length;(n||r)&&(e.skip=e.skip??o.skip,e.take=e.take??o.take),n&&(o.skip+=n,o.take-=n,e.cachedDataPartBegin=i),r&&(o.take-=r,e.cachedDataPartEnd=s.reverse())}},nk=function(i,e,t){let{storeLoadOptions:n}=i,o=i.skip??n.skip??0,s=i.take??n.take??0;for(let r=0;r<s;r+=1){let a=r+o,l=i.cachedData.items,d=r===0&&i.skips||[];l[a]=ok(l[a],e[r],t,d)}},ok=function(i,e,t,n){if(t&&e){let o=I({},e);delete o.isContinuation,delete o.isContinuationOnNextPage;let s=n[0]||0;return e.items&&(o.items=i?.items||{},e.items.forEach((r,a)=>{let l=a+s,d=a===0?n.slice(1):[];o.items[l]=ok(o.items[l],r,t-1,d)})),o}return e};var jg=class extends Ce.Controller{init(e,t){let n=this;n._dataSource=e,n._remoteOperations=t||{},n._isLastPage=!e.isLastPage(),n._hasLastPage=!1,n._currentTotalCount=0,n._cachedData=rd(),n._lastOperationTypes={},n._eventsStrategy=e._eventsStrategy,n._totalCountCorrection=0,n._isLoadingAll=!1,n.changed=ue(),n.loadingChanged=ue(),n.loadError=ue(),n.customizeStoreLoadOptions=ue(),n.changing=ue(),n.pushed=ue(),n._dataChangedHandler=n._handleDataChanged.bind(n),n._customizeStoreLoadOptionsHandler=n._handleCustomizeStoreLoadOptions.bind(n),n._dataLoadedHandler=n._handleDataLoaded.bind(n),n._loadingChangedHandler=n._handleLoadingChanged.bind(n),n._loadErrorHandler=n._handleLoadError.bind(n),n._pushHandler=n._handlePush.bind(n),n._changingHandler=n._handleChanging.bind(n),e.on("changed",n._dataChangedHandler),e.on("customizeStoreLoadOptions",n._customizeStoreLoadOptionsHandler),e.on("customizeLoadResult",n._dataLoadedHandler),e.on("loadingChanged",n._loadingChangedHandler),e.on("loadError",n._loadErrorHandler),e.on("changing",n._changingHandler),e.store().on("beforePush",n._pushHandler),x(e,(o,s)=>{!n[o]&&A(s)&&(n[o]=function(){return this._dataSource[o].apply(this._dataSource,arguments)})})}dispose(e){let t=this._dataSource,n=t.store();t.off("changed",this._dataChangedHandler),t.off("customizeStoreLoadOptions",this._customizeStoreLoadOptionsHandler),t.off("customizeLoadResult",this._dataLoadedHandler),t.off("loadingChanged",this._loadingChangedHandler),t.off("loadError",this._loadErrorHandler),t.off("changing",this._changingHandler),n&&n.off("beforePush",this._pushHandler),e||t.dispose()}remoteOperations(){return this._remoteOperations}refresh(e,t){let n=this,o=n._dataSource;t.reload&&(n.resetCurrentTotalCount(),n._isLastPage=!o.paginate(),n._hasLastPage=n._isLastPage)}resetCurrentTotalCount(){this._currentTotalCount=0,this._totalCountCorrection=0}resetCache(){this._cachedStoreData=void 0,this._cachedPagingData=void 0}resetPagesCache(e){this._cachedData=rd()}_needClearStoreDataCache(){let e=this.remoteOperations(),t=sy(this._lastLoadOptions||{},{});return!Object.keys(e).every(o=>!t[o]||!e[o])}push(e,t){let n=this.store();this._needClearStoreDataCache()&&(this._cachedStoreData=void 0),this._cachedPagingData=void 0,this.resetPagesCache(!0),this._cachedStoreData&&Gn({keyInfo:n,data:this._cachedStoreData,changes:e}),t||this._applyBatch(e),this.pushed.fire(e)}getDataIndexGetter(){if(!this._dataIndexGetter){let e,t,n=this.store();this._dataIndexGetter=o=>{let s=t&&t!==this._cachedStoreData;if(!e||s){t=this._cachedStoreData||[],e={};for(let r=0;r<t.length;r++)e[ai(n.keyOf(t[r]))]=r}return e[ai(n.keyOf(o))]}}return this._dataIndexGetter}_getKeyInfo(){return this.store()}_needToCopyDataObject(){return!0}_applyBatch(e,t){let n=this._getKeyInfo(),o=this._dataSource,s=M.normalizeSortingInfo(this.group()).length,r=this.option("editing.refreshMode")==="reshape",a=this.option("scrolling.mode")==="virtual";e=e.filter(h=>!o.paginate()||h.type!=="insert"||h.index!==void 0);let l=()=>s?this.itemsCount():this.items().length,d=l();Gn({keyInfo:n,data:this._items,changes:e,groupCount:s,useInsertIndex:!0,skipCopying:!this._needToCopyDataObject()}),Gn({keyInfo:n,data:o.items(),changes:e,groupCount:s,useInsertIndex:!0,skipCopying:!this._needToCopyDataObject()}),(this._currentTotalCount>0||(t||!r)&&a)&&(this._totalCountCorrection+=l()-d),e.splice(0,e.length)}_handlePush(e){let{changes:t}=e;this.push(t,!0)}_handleChanging(e){this.changing.fire(e),this._applyBatch(e.changes,!0)}_needCleanCacheByOperation(e,t){let n=["filtering","sorting","paging"],o=n.indexOf(e);return(o>=0?n.slice(o):[e]).some(r=>t[r])}_customizeRemoteOperations(e,t){let n=this._cachedStoreData,o=this._cachedPagingData,s=this._cachedData;(e.storeLoadOptions.filter&&!e.remoteOperations.filtering||e.storeLoadOptions.sort&&!e.remoteOperations.sorting)&&(e.remoteOperations={filtering:e.remoteOperations.filtering,summary:e.remoteOperations.summary}),t.fullReload?(n=void 0,o=void 0,s=rd()):(t.reload?(o=void 0,s=rd()):t.groupExpanding&&(s=rd()),x(t,(r,a)=>{a&&this._needCleanCacheByOperation(r,e.remoteOperations)&&(n=void 0,o=void 0)})),o&&(e.remoteOperations.paging=!1),e.cachedStoreData=n,e.cachedPagingData=o,e.cachedData=s,e.isCustomLoading||(this._cachedStoreData=n,this._cachedPagingData=o,this._cachedData=s)}_handleCustomizeStoreLoadOptions(e){var t;this._handleDataLoading(e),((t=e.data)===null||t===void 0?void 0:t.length)!==0&&(e.data=ry(e,!0)||e.cachedStoreData)}_handleDataLoading(e){let t=this._dataSource,n=this._lastLoadOptions;this.customizeStoreLoadOptions.fire(e),e.delay=this.option("loadingTimeout"),e.originalStoreLoadOptions=e.storeLoadOptions,e.remoteOperations=m({},this.remoteOperations());let o=!this.isLoaded()&&!this._isRefreshing;this.option("integrationOptions.renderedOnServer")&&!this.isLoaded()&&(e.delay=void 0);let s=m({pageIndex:this.pageIndex(),pageSize:this.pageSize()},e.storeLoadOptions),r=sy(s,n,o);if(this._customizeRemoteOperations(e,r),!e.isCustomLoading){let a=this._isRefreshing;e.pageIndex=t.pageIndex(),e.lastLoadOptions=s,e.operationTypes=r,this._loadingOperationTypes=r,this._isRefreshing=!0,P(a||this._isRefreshed||this.refresh(e,r)).done(()=>{this._lastOperationId===e.operationId&&(this._isRefreshed=!0,this.load().always(()=>{this._isRefreshed=!1}))}).fail(()=>{t.cancel(e.operationId)}).always(()=>{this._isRefreshing=!1}),t.cancel(this._lastOperationId),this._lastOperationId=e.operationId,this._isRefreshing&&t.cancel(this._lastOperationId)}this._handleDataLoadingCore(e)}_handleDataLoadingCore(e){let{remoteOperations:t}=e;e.loadOptions={};let n=e.cachedData.extra,o={filter:!t.filtering,sort:!t.sorting,group:!t.grouping,summary:!t.summary,skip:!t.paging,take:!t.paging,requireTotalCount:n&&"totalCount"in n||!t.paging,langParams:!t.filtering||!t.sorting};x(e.storeLoadOptions,(s,r)=>{o[s]&&(e.loadOptions[s]=r,delete e.storeLoadOptions[s])}),n&&(e.extra=n)}_handleDataLoaded(e){let{loadOptions:t}=e,n=e.remoteOperations&&!e.remoteOperations.paging,{cachedData:o}=e,{storeLoadOptions:s}=e,r=this.option("cacheEnabled")!==!1&&s,a=r&&!e.isCustomLoading&&o&&(!n||s.group),l=r&&n,d=l&&!e.isCustomLoading;if(!t){this._dataSource.cancel(e.operationId);return}n&&(e.skip=t.skip,e.take=t.take,delete t.skip,delete t.take),t.group&&(t.group=e.group||t.group);let c=M.normalizeSortingInfo(e.group||s.group||t.group).length;if(e.cachedDataPartBegin&&(e.data=e.cachedDataPartBegin.concat(e.data)),e.cachedDataPartEnd&&(e.data=e.data.concat(e.cachedDataPartEnd)),!a||!ry(e)){var h;l&&e.cachedPagingData?e.data=du(e.cachedPagingData,c):(d&&(this._cachedStoreData?e.mergeStoreLoadData&&(e.data=this._cachedStoreData=this._cachedStoreData.concat(e.data)):this._cachedStoreData=du(e.data,M.normalizeSortingInfo(s.group).length)),new No(e.data).load(t).done(p=>{e.data=p,d&&(this._cachedPagingData=du(e.data,c))}).fail(p=>{e.data=new y().reject(p)})),t.requireTotalCount&&n&&(e.extra=q(e.extra)?e.extra:{},e.extra.totalCount=e.data.length),e.extra&&e.extra.totalCount>=0&&(s.requireTotalCount===!1||t.requireTotalCount===!1)&&(e.extra.totalCount=-1),!t.data&&(s.requireTotalCount||(((h=e.extra)===null||h===void 0?void 0:h.totalCount)??-1)>=0)&&(this._totalCountCorrection=0),this._handleDataLoadedCore(e),a&&(o.extra=o.extra||m({},e.extra),P(e.data).done(p=>{nk(e,p,c)}))}P(e.data).done(()=>{e.lastLoadOptions&&(this._lastLoadOptions=e.lastLoadOptions,Object.keys(e.operationTypes).forEach(p=>{this._lastOperationTypes[p]=this._lastOperationTypes[p]||e.operationTypes[p]}))}),e.storeLoadOptions=e.originalStoreLoadOptions}_handleDataLoadedCore(e){e.remoteOperations&&!e.remoteOperations.paging&&Array.isArray(e.data)&&(e.skip!==void 0&&(e.data=e.data.slice(e.skip)),e.take!==void 0&&(e.data=e.data.slice(0,e.take)))}_handleLoadingChanged(e){this.loadingChanged.fire(e)}_handleLoadError(e){this.loadError.fire(e),this.changed.fire({changeType:"loadError",error:e})}_loadPageSize(){return this.pageSize()}_handleDataChanged(e){let t,n=this._dataSource,o=!1,s=!e||f(e.changeType),r=this.itemsCount();s&&(this._isLastPage=!r||!this._loadPageSize()||r<this._loadPageSize(),this._isLastPage&&(this._hasLastPage=!0)),n.totalCount()>=0?n.pageIndex()>=this.pageCount()&&(n.pageIndex(this.pageCount()-1),this.pageIndex(n.pageIndex()),this.resetPagesCache(),n.load(),o=!0):s&&(t=n.pageIndex()*this.pageSize()+r,t>this._currentTotalCount&&(this._currentTotalCount=t,(n.pageIndex()===0||!this.option("scrolling.legacyMode"))&&(this._totalCountCorrection=0)),r===0&&n.pageIndex()>=this.pageCount()&&(n.pageIndex(this.pageCount()-1),this.option("scrolling.mode")!=="infinite"&&(n.load(),o=!0))),o||(this._operationTypes=this._lastOperationTypes,this._lastOperationTypes={},this.component._optionCache={},this.changed.fire(e),this.component._optionCache=void 0)}_scheduleCustomLoadCallbacks(e){let t=this;t._isCustomLoading=!0,e.always(()=>{t._isCustomLoading=!1})}loadingOperationTypes(){return this._loadingOperationTypes}operationTypes(){return this._operationTypes}lastLoadOptions(){return this._lastLoadOptions||{}}isLastPage(){return this._isLastPage}_dataSourceTotalCount(){return this._dataSource.totalCount()}_changeRowExpandCore(e){}changeRowExpand(e){}totalCount(){return parseInt((this._currentTotalCount||this._dataSourceTotalCount())+this._totalCountCorrection)}totalCountCorrection(){return this._totalCountCorrection}items(){}itemsCount(){return this._dataSource.items().length}totalItemsCount(){return this.totalCount()}pageSize(){let e=this._dataSource;return!arguments.length&&!e.paginate()?0:e.pageSize.apply(e,arguments)}pageCount(){let e=this.totalItemsCount()-this._totalCountCorrection,t=this.pageSize();return t&&e>0?Math.max(1,Math.ceil(e/t)):1}hasKnownLastPage(){return this._hasLastPage||this._dataSource.totalCount()>=0}loadFromStore(e,t){let n=this._dataSource,o=new y;if(n)return t=t||n.store(),t.load(e).done((s,r)=>{s&&!Array.isArray(s)&&Array.isArray(s.data)&&(r=s,s=s.data),o.resolve(s,r)}).fail(o.reject),o}isCustomLoading(){return!!this._isCustomLoading}load(e){let t=this,n=t._dataSource,o=new y;if(e){let s=n.store(),r=n.loadOptions(),a={storeLoadOptions:m({},e,{langParams:r?.langParams}),isCustomLoading:!0};return x(s._customLoadOptions()||[],(l,d)=>{d in a.storeLoadOptions||(a.storeLoadOptions[d]=r[d])}),this._isLoadingAll=e.isLoadingAll,t._scheduleCustomLoadCallbacks(o),n._scheduleLoadCallbacks(o),t._handleCustomizeStoreLoadOptions(a),ek(()=>{if(!n.store())return o.reject("canceled");P(a.data||t.loadFromStore(a.storeLoadOptions)).done((l,d)=>{a.data=l,a.extra=d||{},t._handleDataLoaded(a),e.requireTotalCount&&a.extra.totalCount===void 0&&(a.extra.totalCount=s.totalCount(a.storeLoadOptions)),P(a.data,a.extra.totalCount).done((c,h)=>{a.extra.totalCount=h,o.resolve(c,a.extra)}).fail(o.reject)}).fail(o.reject)},t.option("loadingTimeout")),o.fail(function(){t._eventsStrategy.fireEvent("loadError",arguments)}).always(()=>{this._isLoadingAll=!1}).promise()}return n.load()}reload(e){return e?this._dataSource.reload():this._dataSource.load()}getCachedStoreData(){return this._cachedStoreData}isLoaded(){}pageIndex(e){}};var ay=jg,Pr={extend(i){ay=i(ay)},create:i=>new ay(i)};var ly=class extends lu{_getDataSourceAdapter(){return Pr}_getSpecificDataSourceOption(){let e=this.option("dataSource");return e&&!Array.isArray(e)&&this.option("keyExpr")&&Z.log("W1011"),super._getSpecificDataSourceOption()}};H.registerModule("data",{defaultOptions:JP.defaultOptions,controllers:{data:ly}});var XY=i=>class extends i{_applyColumnState(e){let t=this,n,o,s=t.option("sorting.mode"),{rootElement:r}=e,{column:a}=e,l=t._getIndicatorContainer(r);if(e.name==="sort"){r.find(".dx-sort").remove(),!l.children().length&&l.remove();let d=s!=="none"&&a.allowSorting,c=t.getController&&!!t.getController("columns").columnOption("sortIndex:1");return!f(a.groupIndex)&&(d||f(a.sortOrder))&&(n=a.sortOrder==="asc"?"ascending":"descending",o=super._applyColumnState(e).toggleClass("dx-sort-up",a.sortOrder==="asc").toggleClass("dx-sort-down",a.sortOrder==="desc"),c&&t.option("sorting.showSortIndexes")&&a.sortIndex>=0&&(u("<span>").addClass("dx-sort-index-icon").text(a.sortIndex+1).appendTo(o),o.addClass("dx-sort-index")),d&&e.rootElement.addClass(t.addWidgetPrefix("action"))),this._setAriaSortAttribute(a,n,r,c),o}return super._applyColumnState(e)}_setAriaSortAttribute(e,t,n,o){if(n.removeAttr("aria-roledescription"),e.isGrouped){let s=this.localize("dxDataGrid-ariaNotSortedColumn");f(e.sortOrder)&&(s=e.sortOrder==="asc"?this.localize("dxDataGrid-ariaSortedAscendingColumn"):this.localize("dxDataGrid-ariaSortedDescendingColumn")),this.setAria("roledescription",s,n)}else if(!f(e.sortOrder))this.setAria("sort","none",n);else if(this.setAria("sort",t,n),o&&e.sortIndex>=0){let s=O.format("dxDataGrid-ariaColumnHeader"),r=O.format("dxDataGrid-ariaSortIndex",e.sortIndex+1),a=`${s}, ${r}`;this.setAria("roledescription",a,n)}}_getIndicatorClassName(e){return e==="sort"?"dx-sort":e==="sortIndex"?"dx-sort-index-icon":super._getIndicatorClassName(e)}_renderIndicator(e){let{column:t}=e,n=e.container,o=e.indicator;if(e.name==="sort"){let s=this.option("rtlEnabled");if(f(t.sortOrder)||o&&o.addClass("dx-sort-none"),n.children().length&&(!s&&e.columnAlignment==="left"||s&&e.columnAlignment==="right")){n.prepend(o);return}}super._renderIndicator(e)}_updateIndicator(e,t,n){if(!(n==="sort"&&f(t.groupIndex)))return super._updateIndicator.apply(this,arguments)}_getIndicatorElements(e,t){let n=super._getIndicatorElements(e);return t?n:n&&n.not(".dx-sort-none")}},dy=XY;var QY=i=>class extends dy(i){optionChanged(e){let t=this;e.name==="sorting"?(t._invalidate(),e.handled=!0):super.optionChanged(e)}_createRow(e){let t=super._createRow(e);return e.rowType==="header"&&_.on(t,D(oe,"dxDataGridColumnHeadersView"),"td",this.createAction(n=>{this._processHeaderAction(n.event,t)})),t}_processHeaderAction(e,t){if(u(e.currentTarget).parent().get(0)!==t.get(0))return;let n=this,o=null,s=u(e.currentTarget),r=s.parent().index(),a=-1;[].slice.call(n.getCellElements(r)).some((g,C)=>{if(g===s.get(0))return a=C,!0});let d=n._columnsController.getVisibleColumns(r)[a],c=n.getController("editing"),h=n.option("editing.mode");c&&c.isEditing()&&(h==="batch"||h==="cell")||!n._isSortableElement(u(e.target))||d&&!f(d.groupIndex)&&!d.command&&(e.shiftKey?o="shift":ot(e)&&(o="ctrl"),setTimeout(()=>{n._columnsController.changeSortOrder(d.index,o)}))}_renderCellContent(e,t){let n=this,{column:o}=t;!o.command&&t.rowType==="header"&&n._applyColumnState({name:"sort",rootElement:e,column:o,showColumnLines:n.option("showColumnLines")}),super._renderCellContent.apply(this,arguments)}_columnOptionChanged(e){let{changeTypes:t}=e;if(t.length===1&&t.sorting){this._updateIndicators("sort");return}super._columnOptionChanged(e)}},ZY=i=>class extends dy(i){optionChanged(e){let t=this;e.name==="sorting"?(t._invalidate(),e.handled=!0):super.optionChanged(e)}_createGroupPanelItem(e,t){let n=this,o=super._createGroupPanelItem(...arguments);return _.on(o,D(oe,"dxDataGridHeaderPanel"),n.createAction(()=>{n._processGroupItemAction(t.index)})),n._applyColumnState({name:"sort",rootElement:o,column:{alignment:n.option("rtlEnabled")?"right":"left",allowSorting:t.allowSorting,sortOrder:t.sortOrder==="desc"?"desc":"asc",isGrouped:!0},showColumnLines:!0}),o}_processGroupItemAction(e){setTimeout(()=>this.getController("columns").changeSortOrder(e))}},sk={defaultOptions:()=>({sorting:{mode:"single",ascendingText:O.format("dxDataGrid-sortingAscendingText"),descendingText:O.format("dxDataGrid-sortingDescendingText"),clearText:O.format("dxDataGrid-sortingClearText"),showSortIndexes:!0}}),extenders:{views:{columnHeadersView:QY,headerPanel:ZY}}};H.registerModule("sorting",sk);var qg="dx-freespace-row";var rk="dx-last-row-border";function ak(i){return i?Math.round(i.scrollWidth()-i.clientWidth()):0}function lk(i){let{rowType:e,column:t}=i;return e==="group"&&f(t.groupIndex)&&!t.showWhenGrouped&&!t.command}function dk(i){let{element:e,watch:t,getter:n,callBack:o}=i;if(t){let s=t(n,o);_.on(e,Gt,s)}}var JY=function(i,e){let t=$a(e.text)&&e.rowType==="data",{text:n}=e,o=i.get(0);t?M.setEmptyText(i):e.column.encodeHtml?o.textContent=n:o.innerHTML=n},eX=function(i){let e=i.getScrollable();return e?Math.ceil(parseFloat(u(e.content()).css("paddingBottom"))):0},cy=class extends eo{init(){super.init(),this._editingController=this.getController("editing"),this._resizingController=this.getController("resizing"),this._columnsResizerController=this.getController("columnsResizer"),this._focusController=this.getController("focus"),this._keyboardNavigationController=this.getController("keyboardNavigation"),this._validatingController=this.getController("validating"),this._errorHandlingController=this.getController("errorHandling"),this._columnHeadersView=this.getView("columnHeadersView"),this._rowHeight=0,this._scrollTop=0,this._scrollLeft=-1,this._scrollRight=0,this._hasHeight=void 0,this._contentChanges=[],this._dataController.loadingChanged.add((e,t)=>{this.setLoading(e,t)}),this._dataController.dataSourceChanged.add(()=>{this._scrollLeft>=0&&!this._dataController.isLoading()&&this._handleScroll({component:this.getScrollable(),forceUpdateScrollPosition:!0,scrollOffset:{top:this._scrollTop,left:this._scrollLeft}})})}_getDefaultTemplate(e){return e.command==="empty"?function(t){t.html("&nbsp;")}:JY}renderFocusState(e){}_getDefaultGroupTemplate(e){let t=this.option("summary.texts");return function(n,o){let{data:s}=o,r=`${o.column.caption}: ${o.text}`,a=n.get(0);o.summaryItems&&o.summaryItems.length&&(r+=` ${M.getGroupRowSummaryText(o.summaryItems,t)}`),s&&(o.groupContinuedMessage&&o.groupContinuesMessage?r+=` (${o.groupContinuedMessage}. ${o.groupContinuesMessage})`:o.groupContinuesMessage?r+=` (${o.groupContinuesMessage})`:o.groupContinuedMessage&&(r+=` (${o.groupContinuedMessage})`)),e.encodeHtml?a.textContent=r:a.innerHTML=r}}_update(e){}_updateCell(e,t){lk(t)&&e.addClass("dx-group-cell"),super._updateCell.apply(this,arguments)}_getCellTemplate(e){let t=this,{column:n}=e,o;return lk(e)?o=n.groupCellTemplate||{allowRenderToDetachedContainer:!0,render:t._getDefaultGroupTemplate(n)}:(e.rowType==="data"||n.command)&&n.cellTemplate?o=n.cellTemplate:o={allowRenderToDetachedContainer:!0,render:t._getDefaultTemplate(n)},o}_createRow(e,t){let n=super._createRow.apply(this,arguments);if(e){let o=e.rowType==="group",s=e.rowType==="data";s&&n.addClass("dx-data-row"),s&&this.option("showRowLines")&&n.addClass("dx-row-lines"),this.option("showColumnLines")&&n.addClass("dx-column-lines"),e.visible===!1&&n.hide(),o&&(n.addClass("dx-group-row"),this.setAriaExpandedAttribute(n,e))}return n}_rowPrepared(e,t,n){t.rowType==="data"&&(this.option("rowAlternationEnabled")&&(this._isAltRow(n)&&e.addClass("dx-row-alt"),dk({element:e.get(0),watch:t.watch,getter:()=>this._isAltRow(n),callBack:o=>{e.toggleClass("dx-row-alt",o)}})),this._setAriaRowIndex(t,e),dk({element:e.get(0),watch:t.watch,getter:()=>t.rowIndex,callBack:()=>this._setAriaRowIndex(t,e)})),super._rowPrepared.apply(this,arguments)}_setAriaRowIndex(e,t){if(!t.is("tr"))return;let{component:n}=this,o=n.option("scrolling.mode")==="standard"&&!M.isVirtualRowRendering(n),s=e.rowIndex+1;o?s=n.pageIndex()*n.pageSize()+s:s+=this._dataController.getRowIndexOffset(),this.setAria("rowindex",s,t)}setAriaExpandedAttribute(e,t){let n=t.isExpanded?this.localize("dxDataGrid-ariaExpandedRow"):this.localize("dxDataGrid-ariaCollapsedRow");this.setAria("roledescription",n,e)}_afterRowPrepared(e){let t=e.args[0],n=this._dataController,o=n.getVisibleRows()[t.rowIndex],s=this.option("integrationOptions.watchMethod");if(!t.data||t.rowType!=="data"||t.isNewRow||!this.option("twoWayBindingEnabled")||!s||!o)return;let r=s(()=>n.generateDataValues(t.data,t.columns),()=>{n.repaintRows([o.rowIndex],this.option("repaintChangesOnly"))},{deep:!0,skipImmediate:!0});_.on(t.rowElement,Gt,r)}_renderScrollable(e){let t=this,n=t.element();if(n.children().length||n.append("<div>"),(e||!t._loadPanel)&&t._renderLoadPanel(n,n.parent(),t._dataController.isLocalStore()),(e||!t.getScrollable())&&t._dataController.isLoaded()){let o=t.getColumns(),s=!0;for(let r=0;r<o.length;r++)if(!o[r].width&&!o[r].minWidth){s=!1;break}(t.option("columnAutoWidth")||t._hasHeight||s||t._columnsController._isColumnFixing())&&t._renderScrollableCore(n)}}_handleScroll(e){let t=this.option("rtlEnabled"),n=e.component.option("useNative");this._scrollTop=e.scrollOffset.top,this._scrollLeft=e.scrollOffset.left;let o=e.scrollOffset.left;t&&(this._scrollRight=ak(e.component)-this._scrollLeft,n&&(o=-this._scrollRight),this.isScrollbarVisible(!0)||(this._scrollLeft=-1)),this.scrollChanged.fire(I({},e.scrollOffset,{left:o}),this.name)}_renderScrollableCore(e){let t=this._createScrollableOptions(),n=this._handleScroll.bind(this);t.onScroll=n,this._scrollable=this._createComponent(e,Pi,t),this._scrollableContainer=this._scrollable&&u(this._scrollable.container())}_renderLoadPanel(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return M.renderLoadPanel.apply(this,arguments)}_renderContent(e,t,n){return e.empty().append(t),this._findContentElement()}_updateContent(e,t,n){return this._contentChanges.push({newTableElement:e,change:t,isFixedTableRendering:n}),this.waitAsyncTemplates().done(()=>{let o=this._contentChanges;this._contentChanges=[],o.forEach(s=>{let{newTableElement:r,change:a,isFixedTableRendering:l}=s,d=this.getTableElement(l),c=this._findContentElement(l),h=a?.changeType,p=[],g=this.option("highlightChanges"),C=this.addWidgetPrefix("row-inserted-animation");h==="update"?(x(a.rowIndices,(v,b)=>{var T;let R=this._getRowElements(r).eq(v),U=(T=a.changeTypes)===null||T===void 0?void 0:T[v],Q=a.items&&a.items[v];p.push(()=>{let se=this._getRowElements(d),re=se.eq(b);switch(U){case"update":if(Q){var Re;let we=(Re=a.columnIndices)===null||Re===void 0?void 0:Re[v];f(Q.visible)&&Q.visible!==re.is(":visible")?re.toggle(Q.visible):we?this._updateCells(re,R,we):re.replaceWith(R)}break;case"insert":if(se.length)re.length?R.insertBefore(re):R.insertAfter(se.last());else if(d){let we=R.is("tbody")?d:d.children("tbody");R.prependTo(we)}g&&a.isLiveUpdate&&R.addClass(C);break;case"remove":re.remove()}})}),x(p,function(){this()}),r.remove()):(this.setTableElement(r,l),c.addClass(this.addWidgetPrefix("content")),this._setGridRole(c),this._renderContent(c,r,l))})}).fail(()=>{this._contentChanges=[]})}_getGridRoleName(){return"grid"}_setGridRole(e){var t;let n=!((t=this._dataController)!==null&&t!==void 0&&t.isEmpty()),o=this._getGridRoleName();e!=null&&e.length&&n&&this.setAria("role",o,e)}_createEmptyRow(e,t,n){let o=this,s,r=o._createRow(),a=t?this.getFixedColumns():this.getColumns();r.addClass(e).toggleClass("dx-column-lines",o.option("showColumnLines"));for(let l=0;l<a.length;l++)s=o._createCell({column:a[l],rowType:"freeSpace",columnIndex:l,columns:a}),xe(n)&&s.css("height",n),r.append(s);return o.setAria("role","presentation",r),r}getFixedColumns(){throw new Error("Method not implemented.")}_appendEmptyRow(e,t,n){let o=this._getBodies(e),s=!o.length||t.is("tbody"),r=s?e:o;if(n==="top"){if(r.first().prepend(t),s){let a=r.children("colgroup");r.prepend(a)}}else r.last().append(t)}_renderFreeSpaceRow(e,t){let n=this._createEmptyRow(qg);n=this._wrapRowIfNeed(e,n,t?.changeType==="refresh"),this._appendEmptyRow(e,n)}_checkRowKeys(e){let t=this,n=t._getRows(e),o=t._dataController.store()&&t._dataController.store().key();o&&n.some(s=>{if(s.rowType==="data"&&s.key===void 0)return t._dataController.fireError("E1046",o),!0})}_needUpdateRowHeight(e){return e>0&&!this._rowHeight}_getRowsHeight(e){return e=e||this._tableElement,e.children("tbody").children().not(".dx-virtual-row").not(`.${qg}`).toArray().reduce((n,o)=>n+Ie(o).height,0)}_updateRowHeight(){let e=this,t=e.getTableElement(),n=e._dataController.items().length;if(t&&e._needUpdateRowHeight(n)){let o=e._getRowsHeight(t);e._rowHeight=o/n}}_findContentElement(e){let t=this.element(),n=this.getScrollable();if(t)return n&&(t=u(n.content())),t.children().first()}_getRowElements(e){let t=super._getRowElements(e);return t&&t.not(`.${qg}`)}_getFreeSpaceRowElements(e){let t=e||this.getTableElements();return t&&t.children("tbody").children(`.${qg}`)}_getNoDataText(){return this.option("noDataText")}_rowClick(e){let t=this._dataController.items()[e.rowIndex]||{};this.executeAction("onRowClick",m({evaluate(n){return me(n)(t.data)}},e,t))}_rowDblClick(e){let t=this._dataController.items()[e.rowIndex]||{};this.executeAction("onRowDblClick",m({},e,t))}_getColumnsCountBeforeGroups(e){for(let t=0;t<e.length;t++)if(e[t].type==="groupExpand")return t;return 0}_getGroupCellOptions(e){let t=this._getColumnsCountBeforeGroups(e.columns),n=(e.row.groupIndex||0)+t;return{columnIndex:n,colspan:e.columns.length-n-1}}_needWrapRow(){return super._needWrapRow.apply(this,arguments)||!!this.option("dataRowTemplate")}_renderCells(e,t){t.row.rowType==="group"?this._renderGroupedCells(e,t):t.row.values&&super._renderCells(e,t)}_renderGroupedCells(e,t){let{row:n}=t,o,{columns:s}=t,{rowIndex:r}=n,a,l=this._getGroupCellOptions(t);for(let h=0;h<=l.columnIndex;h++)h===l.columnIndex&&s[h].allowCollapsing&&t.scrollingMode!=="infinite"?(a=!!n.isExpanded,o=s[h]):(a=null,o={command:"expand",cssClass:s[h].cssClass}),this._needRenderCell(h,t.columnIndices)&&this._renderCell(e,{value:a,row:n,rowIndex:r,column:o,columnIndex:h,columnIndices:t.columnIndices,change:t.change});let d=Ui(this.option("rtlEnabled")),c=m({},s[l.columnIndex],{command:null,type:null,cssClass:null,width:null,showWhenGrouped:!1,alignment:d});l.colspan>1&&(c.colspan=l.colspan),this._needRenderCell(l.columnIndex+1,t.columnIndices)&&this._renderCell(e,{value:n.values[n.groupIndex],row:n,rowIndex:r,column:c,columnIndex:l.columnIndex+1,columnIndices:t.columnIndices,change:t.change})}_renderRows(e,t){let n=this,o=n.option("scrolling.mode");super._renderRows(e,m({scrollingMode:o},t)),n._checkRowKeys(t.change),n._renderFreeSpaceRow(e,t.change),n._hasHeight||n.updateFreeSpaceRowHeight(e)}_renderDataRowByTemplate(e,t,n){let{row:o}=t,s=m({columns:t.columns},o),r=this._createRow(o,"tbody");r.appendTo(e),this.renderTemplate(r,n,s,!0,t.change),this._rowPrepared(r,s,t.row)}_renderRow(e,t){let{row:n}=t,{rowTemplate:o}=this.option(),s=this.option("dataRowTemplate");n.rowType==="data"&&s?this._renderDataRowByTemplate(e,t,s):(n.rowType==="data"||n.rowType==="group")&&!f(n.groupIndex)&&o?this.renderTemplate(e,o,m({columns:t.columns},n),!0):super._renderRow(e,t)}_renderTable(e){let t=this,n=super._renderTable(e),o=function(){let s=t.getScrollable();s&&t.element().closest(K().document).length&&(t.resizeCompleted.remove(o),s._visibilityChanged(!0))};return f(t.getTableElement())?t._renderScrollable():(t.setTableElement(n),t._renderScrollable(!0),t.resizeCompleted.add(o)),n}_createTable(){let e=super._createTable.apply(this,arguments);return(this.option().rowTemplate||this.option().dataRowTemplate)&&e.appendTo(this.component.$element()),e}_renderCore(e){let t=this.element();t.addClass(this.addWidgetPrefix("rowsview")).toggleClass(this.addWidgetPrefix("nowrap"),!this.option("wordWrapEnabled")),t.toggleClass("dx-empty",this._dataController.isEmpty()),this.setAria("role","presentation",t);let n=this._renderTable({change:e}),o=this._updateContent(n,e);return super._renderCore(e),this._lastColumnWidths=null,o}_getRows(e){return e&&e.items||this._dataController.items()}_getCellOptions(e){let t=this,{column:n}=e,{row:o}=e,{data:s}=o,r=o&&o.summaryCells,{value:a}=e,l=M.getDisplayValue(n,a,s,o.rowType),d=super._getCellOptions(e);if(d.value=a,d.oldValue=e.oldValue,d.displayValue=l,d.row=o,d.key=o.key,d.data=s,d.rowType=o.rowType,d.values=o.values,d.text=n.command?"":M.formatValue(l,n),d.rowIndex=o.rowIndex,d.summaryItems=r&&r[e.columnIndex],d.resized=n.resizedCallbacks,f(n.groupIndex)&&!n.command){let c=t.option("grouping.texts"),h=t.option("scrolling.mode");h!=="virtual"&&h!=="infinite"&&(d.groupContinuesMessage=s&&s.isContinuationOnNextPage&&c&&c.groupContinuesMessage,d.groupContinuedMessage=s&&s.isContinuation&&c&&c.groupContinuedMessage)}return d}_setRowsOpacityCore(e,t,n,o){let s=this._columnsController,r=s.getColumns(),a=r&&r[n],l=a&&a.isBand&&a.index;x(e,(d,c)=>{if(!u(c).hasClass("dx-group-row"))for(let h=0;h<t.length&&!((xe(l)&&s.isParentBandColumn(t[h].index,l)||t[h].index===n)&&(e.eq(d).children().eq(h).css({opacity:o}),!xe(l)));h++);})}_getDevicePixelRatio(){return K().devicePixelRatio}renderNoDataText(){return M.renderNoDataText.apply(this,arguments)}getCellOptions(e,t){let n=this._dataController.items()[e],o,s;return n&&(B(t)?s=this._columnsController.columnOption(t):s=this._columnsController.getVisibleColumns()[t],s&&(o=this._getCellOptions({value:s.calculateCellValue(n.data),rowIndex:n.rowIndex,row:n,column:s}))),o}getRow(e){if(e>=0){let t=this._getRowElements();if(t.length>e)return u(t[e])}}updateFreeSpaceRowHeight(e){let t=this._dataController,n=t.items(!0).length,o=this._findContentElement(),s=this._getFreeSpaceRowElements(e);if(s&&o&&t.totalCount()>=0){let r=!1;if(n>0)if(this._hasHeight)s.hide(),Jt(()=>{let a=this.getScrollbarWidth(!0),l=Y(this.element())-a,d=X(o),c=l-d>0,h=this._getRowsHeight(o.children().first()),p=e||this.getTableElements(),g=Math.ceil(parseFloat(p.css("borderTopWidth"))),C=this._getHeightCorrection(),v=l-h-g-C;c&&nt(()=>{s.css("height",v),r=!0,s.show()}),nt(()=>this._updateLastRowBorder(r))});else{let a=t.pageSize()-n,l=this.option("scrolling.mode");a>0&&t.pageCount()>1&&l!=="virtual"&&l!=="infinite"&&(ah(s,a*this._rowHeight),r=!0),!r&&e?ah(s,0):s.toggle(r),this._updateLastRowBorder(r)}else s.css("height",0),s.show(),this._updateLastRowBorder(!0)}}_getHeightCorrection(){let e=be.webkit&&this._getDevicePixelRatio()>=2,t=be.chrome&&be.version>=91,n=be.mozilla&&be.version>=70&&!this.option("showRowLines");return e||n||t?1:0}_columnOptionChanged(e){let{optionNames:t}=e;e.changeTypes.grouping||(t.width||t.visibleWidth)&&(super._columnOptionChanged(e),this._fireColumnResizedCallbacks())}getScrollable(){return this._scrollable}_handleDataChanged(e){let t=this;switch(e.changeType){case"refresh":case"prepend":case"append":case"update":t.render(null,e);break;default:t._update(e)}}publicMethods(){return["isScrollbarVisible","getTopVisibleRowData","getScrollbarWidth","getCellElement","getRowElement","getScrollable"]}contentWidth(){return z(this.element())-this.getScrollbarWidth()}getScrollbarWidth(e){let t=this._scrollableContainer&&this._scrollableContainer.get(0),n=0;return t&&(e?(n=t.clientHeight?t.offsetHeight-t.clientHeight:0,n+=eX(this)):n=t.clientWidth?t.offsetWidth-t.clientWidth:0),n>0?n:0}_fireColumnResizedCallbacks(){let e=this._lastColumnWidths||[],t=[],n=this.getColumns();for(let o=0;o<n.length;o++)t[o]=n[o].visibleWidth,n[o].resizedCallbacks&&!f(n[o].groupIndex)&&e[o]!==t[o]&&n[o].resizedCallbacks.fire(t[o]);this._lastColumnWidths=t}_updateLastRowBorder(e){this.option("showBorders")&&!e?this.element().addClass(rk):this.element().removeClass(rk)}_updateScrollable(){let e=Pi.getInstance(this.element());e&&(e.update(),(e.option("useNative")||!(e!=null&&e.isRenovated()))&&this._updateHorizontalScrollPosition())}_updateHorizontalScrollPosition(){let e=this.getScrollable(),t=e&&e.scrollOffset().left;if(this.option("rtlEnabled")){let o=ak(e);o-t!==this._scrollRight&&(this._scrollLeft=o-this._scrollRight)}this._scrollLeft>=0&&t!==this._scrollLeft&&e.scrollTo({x:this._scrollLeft})}_resizeCore(){let e=this;e._fireColumnResizedCallbacks(),e._updateRowHeight(),nt(()=>{e._renderScrollable(),e.renderNoDataText(),e.updateFreeSpaceRowHeight(),Jt(()=>{e._updateScrollable()})})}scrollTo(e){let t=this.element(),n=t&&Pi.getInstance(t);n&&n.scrollTo(e)}height(e){let t=this,n=this.element();if(arguments.length===0)return n?X(n,!0):0;f(e)&&n&&(t.hasHeight(e!=="auto"),ah(n,e))}hasHeight(e){if(arguments.length===0)return!!this._hasHeight;this._hasHeight=e}setLoading(e,t){let n=this,o=n._loadPanel,s=n._dataController,r=n.option("loadPanel")||{},a=s.isLoaded()?r.animation:null,l=n.element();if(W()&&(!o&&t!==void 0&&s.isLocalStore()&&r.enabled==="auto"&&l&&(n._renderLoadPanel(l,l.parent()),o=n._loadPanel),o)){let d={message:t||r.text,animation:a,visible:e};e&&(d.position=M.calculateLoadPanelPosition(l)),clearTimeout(n._hideLoadingTimeoutID),o.option("visible")&&!e?n._hideLoadingTimeoutID=setTimeout(()=>{o.option(d)},200):o.option(d)}}setRowsOpacity(e,t){let n=this._getRowElements().not(".dx-group-row")||[];this._setRowsOpacityCore(n,this.getColumns(),e,t)}_getCellElementsCore(e){let t=super._getCellElementsCore.apply(this,arguments);if(t){let n=t.filter(".dx-group-cell").index();if(n>=0&&t.length>n+1)return t.slice(0,n+1)}return t}_getBoundaryVisibleItemIndex(e,t){let n=this,o=0,s=0,r=0,a=n._scrollTop,l=n._findContentElement(),d=l&&l.offset().top,c=this._dataController.items(),h=n.getTableElement();if(c.length&&h){let p=n._getRowElements(h).filter(":visible");if(!e){let g=X(this._hasHeight?this.element():K());a+=g}for(o=0;o<c.length;o++){s=r;let g=u(p).eq(o);if(g.length&&(r=g.offset(),r=(e?r.top:r.top+X(g))-d,r>a)){o&&(t||2*a<Math.round(r+s))&&o--;break}}o&&o===c.length&&o--}return o}getTopVisibleItemIndex(e){return this._getBoundaryVisibleItemIndex(!0,e)}getBottomVisibleItemIndex(e){return this._getBoundaryVisibleItemIndex(!1,e)}getTopVisibleRowData(){let e=this.getTopVisibleItemIndex(),t=this._dataController.items();if(t[e])return t[e].data}_scrollToElement(e,t){let n=this.getScrollable();n&&n.scrollToElement(e,t)}optionChanged(e){let t=this;switch(super.optionChanged(e),e.name){case"wordWrapEnabled":case"showColumnLines":case"showRowLines":case"rowAlternationEnabled":case"rowTemplate":case"dataRowTemplate":case"twoWayBindingEnabled":t._invalidate(!0,!0),e.handled=!0;break;case"scrolling":t._rowHeight=null,t._tableElement=null,e.handled=!0;break;case"rtlEnabled":t._rowHeight=null,t._tableElement=null;break;case"loadPanel":t._tableElement=null,t._invalidate(!0,e.fullName!=="loadPanel.enabled"),e.handled=!0;break;case"noDataText":t.renderNoDataText(),e.handled=!0}}setAriaOwns(e,t,n){let o=this._findContentElement(),s=this.getTableElement();s!=null&&s.length&&this.setAria("owns",`${e??""} ${s.attr("id")??""} ${t??""}`.trim(),o)}dispose(){super.dispose(),clearTimeout(this._hideLoadingTimeoutID),this._scrollable&&this._scrollable.dispose()}setScrollerSpacing(e,t){}getFixedContentElement(){var e;let t=this.addWidgetPrefix("content-fixed");return(e=this.element())===null||e===void 0?void 0:e.children(`.${t}`)}_restoreErrorRow(e){}isElementInside(e){return e.closest(`.${this.addWidgetPrefix("rowsview")}`).is(this.element())}},uy={defaultOptions:()=>({hoverStateEnabled:!1,scrolling:{useNative:"auto"},loadPanel:{enabled:"auto",text:O.format("Loading"),width:200,height:90,showIndicator:!0,indicatorSrc:"",showPane:!0},dataRowTemplate:null,columnAutoWidth:!1,noDataText:O.format("dxDataGrid-noDataText"),wordWrapEnabled:!1,showColumnLines:!0,showRowLines:!1,rowAlternationEnabled:!1,activeStateEnabled:!1,twoWayBindingEnabled:!0}),views:{rowsView:cy}};var Cze=uy.views.rowsView;H.registerModule("rows",uy);var tX="dx-context-menu",iX={columnHeadersView:"header",rowsView:"content",footerView:"footer",headerPanel:"headerPanel"},nX=["columnHeadersView","rowsView","footerView","headerPanel"],hy=class extends Ce.ViewController{init(){this.createAction("onContextMenuPreparing")}getContextMenuItems(e){if(!e)return!1;let t=this,n=u(e.target),o,s,r,a;return x(nX,function(){let l=t.getView(this);if(o=l&&l.element(),o&&(o.is(n)||o.find(n).length)){var d;r=n.closest(".dx-row > td, .dx-row > tr"),s=r.parent();let c=l.getRowIndex(s),h=r[0]&&r[0].cellIndex,p=s.data("options"),g={event:e,targetElement:N(n),target:iX[this],rowIndex:c,row:l._getRows()[c],columnIndex:h,column:p==null||(d=p.cells)===null||d===void 0||(d=d[h])===null||d===void 0?void 0:d.column};if(g.items=l.getContextMenuItems&&l.getContextMenuItems(g),t.executeAction("onContextMenuPreparing",g),t._contextMenuPrepared(g),a=g.items,a)return!1}}),a}_contextMenuPrepared(e){}},py=class extends Ce.View{init(){super.init(),this._contextMenuController=this.getController("contextMenu")}_renderCore(){let e=this.element().addClass(tX);this.setAria("role","presentation",e),this._createComponent(e,Ob,{onPositioning:t=>{let{event:n}=t,o=t.component,s=this._contextMenuController.getContextMenuItems(n);s?(o.option("items",s),n.stopPropagation()):t.cancel=!0},onItemClick(t){var n,o;(n=t.itemData)===null||n===void 0||(o=n.onItemClick)===null||o===void 0||o.call(n,t)},cssClass:this.getWidgetContainerClass(),target:this.component.$element()})}},ck={defaultOptions:()=>({onContextMenuPreparing:null}),controllers:{contextMenu:hy},views:{contextMenuView:py}};H.registerModule("contextMenu",ck);var gy=class extends Ce.ViewController{init(){this._resizingController=this.getController("resizing"),this._columnsController=this.getController("columns"),this._columnHeadersView=this.getView("columnHeadersView"),this._rowsView=this.getView("rowsView")}_createErrorRow(e,t){let n,o,s=this._renderErrorMessage(e);return t?(n=u("<tr>").attr("role","row").addClass("dx-error-row"),o=u("<div>").addClass("dx-closebutton").addClass(this.addWidgetPrefix("action")),_.on(o,oe,this.createAction(r=>{var a,l;let d=r.event,c,h=u(d.currentTarget).closest(".dx-error-row").index();d.stopPropagation(),x(t,(p,g)=>{c=u(g).children("tbody").children("tr").eq(h),this.removeErrorRow(c)}),(a=this._resizingController)===null||a===void 0||(l=a.fireContentReadyAction)===null||l===void 0||l.call(a)})),u("<td>").attr({colSpan:this._columnsController.getVisibleColumns().length,role:"gridcell"}).prepend(o).append(s).appendTo(n),n):s}_renderErrorMessage(e){let t=e.url?e.message.replace(e.url,""):e.message||e,n=u("<div>").attr("role","alert").attr("aria-roledescription",O.format("dxDataGrid-ariaError")).addClass("dx-error-message").text(t);return e.url&&u("<a>").attr("href",e.url).text(e.url).appendTo(n),n}renderErrorRow(e,t,n){var o,s;let r=this,a,l;if(n)return n.find(".dx-error-message").remove(),a=r._createErrorRow(e),n.prepend(a),a;let d=t>=0||!r._columnHeadersView.isVisible()?r._rowsView:r._columnHeadersView,c=d.getTableElements();return x(c,(h,p)=>{if(a=r._createErrorRow(e,c),l=l||a,t>=0){let g=d._getRowElements(u(p)).eq(t);r.removeErrorRow(g.next()),a.insertAfter(g)}else{let g=u(p).children("tbody"),C=g.children("tr");r._columnHeadersView.isVisible()?(r.removeErrorRow(C.last()),u(p).append(a)):(r.removeErrorRow(C.first()),g.first().prepend(a))}}),(o=this._resizingController)===null||o===void 0||(s=o.fireContentReadyAction)===null||s===void 0||s.call(o),l}removeErrorRow(e){if(!e){let t=this._columnHeadersView&&this._columnHeadersView.element();if(e=t&&t.find(".dx-error-row"),!e||!e.length){let n=this._rowsView.element();e=n&&n.find(".dx-error-row")}}e&&e.hasClass("dx-error-row")&&e.remove()}optionChanged(e){e.name==="errorRowEnabled"?e.handled=!0:super.optionChanged(e)}},oX=i=>class extends i{init(){super.init(),this.dataErrorOccurred.add((e,t)=>{this.option("errorRowEnabled")&&this._errorHandlingController.renderErrorRow(e,void 0,t)}),this.changed.add(e=>{if(!(e&&e.changeType==="loadError")&&this._editingController&&!this._editingController.hasChanges()){var t,n;(t=this._errorHandlingController)===null||t===void 0||(n=t.removeErrorRow)===null||n===void 0||n.call(t)}})}},uk={defaultOptions:()=>({errorRowEnabled:!0}),controllers:{errorHandling:gy},extenders:{controllers:{data:oX}}};H.registerModule("errorHandling",uk);var sX={container:"dx-gridbase-a11y-status-container"},hk=i=>{let{statusText:e}=i;return u("<div>").text(e??"").addClass(sX.container).attr("role","status")};var Cy=["columnsSeparatorView","blockSeparatorView","trackerView","headerPanel","columnHeadersView","rowsView","footerView","columnChooserView","filterPanelView","pagerView","draggingHeaderView","contextMenuView","errorView","headerFilterView","filterBuilderView"],rX={a11yStatusContainer:"e2e-a11y-general-status-container"},cu=function(i){return B(i)&&i.endsWith("%")},aX=function(i){return B(i)&&i.endsWith("px")},pk=function(i,e){let t=i._rowsView.contentWidth(),n=i._getTotalWidth(e,t);return t-n},lX=function(i,e,t,n){return pk(i,n.map((o,s)=>s===e?t:o))},dX=function(i,e){pP(i,!0),M.setSelectionRange(i,e)},my=class extends Ce.ViewController{init(){this._prevContentMinHeight=null,this._dataController=this.getController("data"),this._columnsController=this.getController("columns"),this._columnHeadersView=this.getView("columnHeadersView"),this._adaptiveColumnsController=this.getController("adaptiveColumns"),this._editorFactoryController=this.getController("editorFactory"),this._footerView=this.getView("footerView"),this._rowsView=this.getView("rowsView"),this._gridView=this.getView("gridView")}_initPostRenderHandlers(){this._refreshSizesHandler||(this._refreshSizesHandler=e=>{let t=new y().resolve(null),n=e?.changeType,o=e?.isDelayed,s=n&&n!=="updateSelection"&&n!=="updateFocusedRow"&&n!=="pageIndex"&&!o;this._dataController.changed.remove(this._refreshSizesHandler),this._checkSize()&&(t=this._refreshSizes(e)),s&&P(t).done(()=>{this._setAriaLabel(),this.fireContentReadyAction()})},this._dataController.changed.add(()=>{this._dataController.changed.add(this._refreshSizesHandler)}))}_refreshSizes(e){let t=new y().resolve(null),n=e?.changeType,o=e?.isDelayed,s=this._dataController.items();if(!e||n==="refresh"||n==="prepend"||n==="append")o||(t=this.resize());else if(n==="update"){var r;if(((r=e.changeTypes)===null||r===void 0?void 0:r.length)===0)return t;(s.length>1||e.changeTypes[0]!=="insert")&&!(s.length===0&&e.changeTypes[0]==="remove")&&!e.needUpdateDimensions?(t=new y,this._waitAsyncTemplates().done(()=>{Jt(()=>nt(()=>Jt(()=>{this._setScrollerSpacing(),this._rowsView.resize(),t.resolve()})))}).fail(t.reject)):t=this.resize()}return t}fireContentReadyAction(){this.component._fireContentReadyAction()}_getWidgetAriaLabel(){return"dxDataGrid-ariaDataGrid"}_setAriaLabel(){var e;let t=((e=this._columnsController)===null||e===void 0||(e=e._columns)===null||e===void 0?void 0:e.filter(a=>{let{visible:l}=a;return!!l}).length)??0,n=Math.max(0,this._dataController.totalItemsCount()),o=this._getWidgetAriaLabel(),s=O.format(o,n,t),r=this.component.$element().children(".dx-gridbase-container");this.component.setAria("label",s,r),this._gridView.setWidgetA11yStatusText(s)}_getBestFitWidths(){var e;let t=this._rowsView,n=this._columnHeadersView,o=t.getColumnWidths();if(!((e=o)!==null&&e!==void 0&&e.length)){var s;let r=n.getTableElement();n.setTableElement((s=t.getTableElement())===null||s===void 0?void 0:s.children(".dx-header")),o=n.getColumnWidths(),n.setTableElement(r)}return o}_setVisibleWidths(e,t){let n=this._columnsController;n.beginUpdate(),x(e,(o,s)=>{let r=n.getColumnId(s);n.columnOption(r,"visibleWidth",t[o])}),n.endUpdate()}_toggleBestFitModeForView(e,t,n){if(!e||!e.isVisible())return;let o=this._rowsView.getTableElements(),s=e.getTableElements();x(o,(r,a)=>{let l,d=u(a),c=s.eq(r);c&&c.length&&(n?l=c.children("tbody").appendTo(d):l=d.children(`.${t}`).appendTo(c),l.toggleClass(t,n),l.toggleClass(this.addWidgetPrefix("best-fit"),n))})}_toggleBestFitMode(e){let t=this._rowsView.getTableElement(),n=this._rowsView.getTableElements().eq(1);t&&(t.css("tableLayout",e?"auto":"fixed"),t.children("colgroup").css("display",e?"none":""),x(n.find("tr.dx-group-row"),(o,s)=>{u(s).css("display",e?"none":"")}),n.toggleClass(this.addWidgetPrefix("table-fixed"),!e),this._toggleBestFitModeForView(this._columnHeadersView,"dx-header",e),this._toggleBestFitModeForView(this._footerView,"dx-footer",e),this._needStretch()&&(t.get(0).style.width=e?"auto":""))}_toggleContentMinHeight(e){let t=this._rowsView.getScrollable(),n=this._rowsView._findContentElement();t?.option("useNative")===!1&&(e===!0&&(this._prevContentMinHeight=n.get(0).style.minHeight),f(this._prevContentMinHeight)&&n.css({minHeight:e?M.getContentHeightLimit(be):this._prevContentMinHeight}))}_synchronizeColumns(){let e=this._columnsController,t=e.getVisibleColumns(),n=this.option("columnAutoWidth"),o=this.option("wordWrapEnabled"),s=t.some(C=>!f(C.width)),r=this._needBestFit(),a=!1,l,d=!1,c=[],h,p;!r&&x(t,(C,v)=>{if(v.width==="auto")return r=!0,!1}),x(t,(C,v)=>{if(v.minWidth)return a=!0,!1}),this._setVisibleWidths(t,[]);let g=this.component.$element();r&&(h=w.getActiveElement(g.get(0)),p=M.getSelectionRange(h),this._toggleBestFitMode(!0),l=!0),this._toggleContentMinHeight(o),g&&g.get(0)&&this._maxWidth&&(delete this._maxWidth,g[0].style.maxWidth=""),Jt(()=>{r?(c=this._getBestFitWidths(),x(t,(C,v)=>{let b=e.getColumnId(v);e.columnOption(b,"bestFitWidth",c[C],!0)})):a&&(c=this._getBestFitWidths()),x(t,function(C){let{width:v}=this;v!=="auto"&&(f(v)?c[C]=xe(v)||aX(v)?parseFloat(v):v:n||(c[C]=void 0))}),l&&(this._toggleBestFitMode(!1),l=!1,h&&h!==w.getActiveElement()&&(Ie(h).bottom<0||dX(h,p))),d=this._correctColumnWidths(c,t),n&&(function(){let C;x(t,(v,b)=>{b.type==="groupExpand"&&(C=c[v])}),x(t,(v,b)=>{b.type==="groupExpand"&&C&&(c[v]=C)})}(),this._needStretch()&&this._processStretch(c,t)),nt(()=>{(r||d||s)&&this._setVisibleWidths(t,c),o&&this._toggleContentMinHeight(!1)})})}_needBestFit(){return this.option("columnAutoWidth")}_needStretch(){return this._columnsController.getVisibleColumns().some(e=>e.width==="auto"&&!e.command)}_getAverageColumnsWidth(e){let t=pk(this,e),n=e.filter(o=>o===void 0).length;return t/n}_correctColumnWidths(e,t){let n=this,o,s=!1,r=!1,a=!1,l=n.component.$element(),d=n._hasWidth;for(o=0;o<t.length;o++){let c=o,h=t[c],p=e[c]==="adaptiveHidden",g=e[c],{minWidth:C}=h;C&&(g===void 0?g=n._getAverageColumnsWidth(e):cu(g)&&lX(n,c,C,e)<0&&(g=-1));let v=n._getRealColumnWidth(c,e.map((b,T)=>c===T?g:b));C&&!p&&v<C&&(e[c]=C,a=!0,o=-1),f(h.width)||(r=!0),cu(h.width)&&(s=!0)}if(!r&&e.length){let c=n._rowsView.element(),h=n._rowsView.contentWidth(),p=n._rowsView.getScrollbarWidth(),g=n._getTotalWidth(e,h);if(g<h){let C=M.getLastResizableColumnIndex(t,e);if(C>=0&&(e[C]="auto",a=!0,d===!1&&!s)){let v=n.option("showBorders")?Math.ceil(ie(c)-Za(c)):0;n._maxWidth=g+p+v,l.css("maxWidth",n._maxWidth)}}}return a}_processStretch(e,t){let n=this._rowsView.contentWidth(),o=this._getTotalWidth(e,n),s={length:0};if(!e.length)return;x(t,function(d){(this.width||e[d]==="adaptiveHidden")&&(s[d]=!0,s.length++)});let r=n-o,a=Math.floor(r/(e.length-s.length)),l=r-a*(e.length-s.length);if(r>=0)for(let d=0;d<e.length;d++)s[d]||(e[d]+=a,l>0&&(l<1?(e[d]+=l,l=0):(e[d]++,l--)))}_getRealColumnWidth(e,t,n){let o=1,s=t[e];if(!cu(s))return parseFloat(s);let r=t.reduce((c,h,p)=>cu(h)?c+parseFloat(h):c,0),a=t.reduce((c,h)=>!h||h==="adaptiveHidden"||cu(h)?c:c+parseFloat(h),0);n=n||this._rowsView.contentWidth();let l=n-a,d=r*n/100;return a>0&&d+a>=n&&(o=d>l?l/d:1),parseFloat(s)*n*o/100}_getTotalWidth(e,t){let n=0;for(let o=0;o<e.length;o++){let s=e[o];s&&s!=="adaptiveHidden"&&(n+=this._getRealColumnWidth(o,e,t))}return Math.ceil(n)}_getGroupElement(){return this.component.$element().children().get(0)}updateSize(e){let t=this,n=u(e),o=t.addWidgetPrefix("important-margin");if(t._hasHeight===void 0&&n&&n.is(":visible")&&z(n)){let s=n.children(`.${t.getWidgetContainerClass()}`);s.length&&s.detach(),t._hasHeight=!!Y(n);let r=z(n);n.addClass(o),t._hasWidth=z(n)===r,n.removeClass(o),s.length&&s.appendTo(n)}}publicMethods(){return["resize","updateDimensions"]}_waitAsyncTemplates(){var e,t,n;return P((e=this._columnHeadersView)===null||e===void 0?void 0:e.waitAsyncTemplates(!0),(t=this._rowsView)===null||t===void 0?void 0:t.waitAsyncTemplates(!0),(n=this._footerView)===null||n===void 0?void 0:n.waitAsyncTemplates(!0))}resize(){if(this.component._requireResize)return new y().resolve();let e=new y;return this._waitAsyncTemplates().done(()=>{P(this.updateDimensions()).done(e.resolve).fail(e.reject)}).fail(e.reject),e.promise()}updateDimensions(e){let t=this;if(t._initPostRenderHandlers(),!t._checkSize(e))return;let n=t._resizeDeferred,o=t._resizeDeferred=new y;return P(n).always(()=>{nt(()=>{t._dataController.isLoaded()&&t._synchronizeColumns(),t._resetGroupElementHeight(),Jt(()=>{nt(()=>{Jt(()=>{t._updateDimensionsCore()})})})}).done(o.resolve).fail(o.reject)}),o.promise()}_resetGroupElementHeight(){let e=this._getGroupElement(),t=this._rowsView.getScrollable();e&&e.style.height&&(!t||!t.scrollTop())&&(e.style.height="")}_checkSize(e){let t=this.component.$element(),n=t.is(":visible"),o=this._lastWidth!==z(t)||this._lastHeight!==Y(t)||this._devicePixelRatio!==K().devicePixelRatio;return n&&(!e||o)}_setScrollerSpacingCore(){let e=this,t=e._rowsView.getScrollbarWidth(),n=e._rowsView.getScrollbarWidth(!0);nt(()=>{e._columnHeadersView&&e._columnHeadersView.setScrollerSpacing(t),e._footerView&&e._footerView.setScrollerSpacing(t),e._rowsView.setScrollerSpacing(t,n)})}_setScrollerSpacing(){let e=this._rowsView.getScrollable(),t=this.option("scrolling.useNative")===!0;!e||t?nt(()=>{Jt(()=>{this._setScrollerSpacingCore()})}):this._setScrollerSpacingCore()}_setAriaOwns(){var e,t,n;let o=(e=this._columnHeadersView)===null||e===void 0?void 0:e.getTableElement(),s=(t=this._footerView)===null||t===void 0?void 0:t.getTableElement();(n=this._rowsView)===null||n===void 0||n.setAriaOwns(o?.attr("id"),s?.attr("id"))}_updateDimensionsCore(){let e=this,t=e._dataController,n=e._rowsView,o=e.component.$element(),s=this._getGroupElement(),r=Y(o),a=e.option("height")??o.get(0).style.height,l=!!a&&a!=="auto",d=parseInt(o.css("maxHeight")),c=d&&r>=d,h=s&&s.scrollHeight===s.offsetHeight;e.updateSize(o),nt(()=>{let p=e._hasHeight||!!d||l;if(n.hasHeight(p),this._setAriaOwns(),c&&!h&&u(s).css("height",d),!t.isLoaded()){n.setLoading(t.isLoading());return}Jt(()=>{e._updateLastSizes(o),e._setScrollerSpacing(),x(Cy,(g,C)=>{let v=e.getView(C);v&&v.resize()}),this._editorFactoryController&&this._editorFactoryController.resize()})})}_updateLastSizes(e){this._lastWidth=z(e),this._lastHeight=Y(e),this._devicePixelRatio=K().devicePixelRatio}optionChanged(e){switch(e.name){case"width":case"height":this.component._renderDimensions(),this.resize();case"renderAsync":e.handled=!0;return;default:super.optionChanged(e)}}},fy=class extends Ce.ViewController{_scrollChangedHandler(e,t,n){for(let o=0;o<e.length;o++)e[o]&&e[o].name!==n&&e[o].scrollTo({left:t.left,top:t.top})}init(){let e=[this.getView("columnHeadersView"),this.getView("footerView"),this.getView("rowsView")];for(let t=0;t<e.length;t++){let n=e[t];n&&n.scrollChanged.add(this._scrollChangedHandler.bind(this,e))}}},_y=class extends Ce.View{init(){this._resizingController=this.getController("resizing"),this._dataController=this.getController("data")}_endUpdateCore(){this.component._requireResize&&(this.component._requireResize=!1,this._resizingController.resize())}getView(e){return this.component._views[e]}element(){return this._groupElement}optionChanged(e){let t=this;f(t._groupElement)&&e.name==="showBorders"?(t._groupElement.toggleClass(t.addWidgetPrefix("borders"),!!e.value),e.handled=!0):super.optionChanged(e)}_renderViews(e){let t=this;x(Cy,(n,o)=>{let s=t.getView(o);s&&s.render(e)})}_getTableRoleName(){return"group"}render(e){let t=!this._groupElement,n=this._groupElement||u("<div>").addClass(this.getWidgetContainerClass());n.addClass("dx-gridbase-container"),n.toggleClass(this.addWidgetPrefix("borders"),!!this.option("showBorders")),this.setAria("role","presentation",e),this.component.setAria("role",this._getTableRoleName(),n),this._rootElement=e||this._rootElement,t&&(this._groupElement=n,W()&&this._resizingController.updateSize(e),n.appendTo(e)),this._a11yGeneralStatusElement||(this._a11yGeneralStatusElement=hk({}),this._a11yGeneralStatusElement.attr(rX.a11yStatusContainer,"true"),n.append(this._a11yGeneralStatusElement)),this._renderViews(n)}update(){let e=this,t=e._rootElement,n=e._groupElement;t&&n&&(this._resizingController.resize(),e._dataController.isLoaded()&&e._resizingController.fireContentReadyAction())}setWidgetA11yStatusText(e){var t;(t=this._a11yGeneralStatusElement)===null||t===void 0||t.text(e)}},gk={defaultOptions:()=>({showBorders:!1,renderAsync:!1}),controllers:{resizing:my,synchronizeScrolling:fy},views:{gridView:_y},VIEW_NAMES:Cy};H.registerModule("gridView",gk);var cX=["dxAutocomplete","dxButton","dxCheckBox","dxDateBox","dxMenu","dxSelectBox","dxTabs","dxTextBox","dxButtonGroup","dxDropDownButton"],uX=function(i){let e=i.data&&i.data(),t=e&&e.dxComponents,n=t&&t[0];return n&&e[n]};function ad(i,e){var t;if(!i)return;let n=i._findItemElementByItem(e);if(!n.length)return;let o=i._getItemData(n),s=!!((t=o.options)!==null&&t!==void 0&&t.disabled||o.disabled||i.option("disabled")),{widget:r}=o;if(r&&cX.includes(r)){let d=n.find(r.toLowerCase().replace("dx",".dx-"));if(d.length){var a,l;let c=uX(d);if(!c)return;let h=(a=c._focusTarget)===null||a===void 0?void 0:a.call(c);r==="dxDropDownButton"?h=h&&h.find(".dx-buttongroup"):h=h??u(c.element());let p=(l=o.options)===null||l===void 0?void 0:l.tabIndex;s?h.attr("tabIndex",-1):h.attr("tabIndex",p??0)}}}var Yg=class{constructor(e){this._toolbar=e}_initMarkup(){}_updateMenuVisibility(){}_renderMenuItems(){}_renderItem(){}_getMenuItems(){}_getToolbarItems(){return this._toolbar.option("items")??[]}_getItemsWidth(){return this._toolbar._getSummaryItemsSize("width",this._toolbar._itemElements(),!0)}_arrangeItems(){let e=this._toolbar._$toolbarItemsContainer.find(".dx-toolbar-label").eq(0);if(!e.length)return;let t=z(this._toolbar.$element()),n=ie(e)-z(e);e.css("maxWidth",t-n)}_hideOverflowItems(){}_dimensionChanged(){}_itemOptionChanged(){}_optionChanged(){}};var Xg=class extends Bc{_init(){super._init(),this._activeStateUnit=".dx-toolbar-menu-action:not(.dx-toolbar-hidden-button-group)"}_initMarkup(){this._renderSections(),super._initMarkup(),this._setMenuRole()}_getSections(){return this._itemContainer().children()}_itemElements(){return this._getSections().children(this._itemSelector())}_renderSections(){let e=this._itemContainer();x(["before","center","after","menu"],(t,n)=>{let o=`_$${n}Section`;this[o]||(this[o]=u("<div>").addClass("dx-toolbar-menu-section")),this[o].appendTo(e)})}_renderItems(){super._renderItems.apply(this,arguments),this._updateSections()}_setMenuRole(){this.$element().find(".dx-scrollview-content").attr("role","menu")}_updateSections(){let e=this.$element().find(".dx-toolbar-menu-section");e.removeClass("dx-toolbar-menu-last-section"),e.not(":empty").eq(-1).addClass("dx-toolbar-menu-last-section")}_renderItem(e,t,n,o){let s=t.location??"menu",r=this[`_$${s}Section`],a=super._renderItem(e,t,r,o);return this._getItemTemplateName({itemData:t})&&a.addClass("dx-toolbar-menu-custom"),(s==="menu"||t.widget==="dxButton"||t.widget==="dxButtonGroup"||t.isAction)&&a.addClass("dx-toolbar-menu-action"),t.widget==="dxButton"&&a.addClass("dx-toolbar-hidden-button"),t.widget==="dxButtonGroup"&&a.addClass("dx-toolbar-hidden-button-group"),a.addClass(t.cssClass),a}_getItemTemplateName(e){let t=super._getItemTemplateName(e),n=e.itemData;return n&&n.menuItemTemplate||t}_dataSourceOptions(){return{paginate:!1}}_itemClickHandler(e,t,n){u(e.target).closest(".dx-toolbar-menu-action").length&&super._itemClickHandler(e,t,n)}_clean(){this._getSections().empty(),super._clean()}};var Qg=class extends Op{_supportedKeys(){var e;let t={};return(!this.option("opened")||!((e=this._list)!==null&&e!==void 0&&e.option("focusedElement")))&&(t=this._button._supportedKeys()),m(super._supportedKeys(),t,{tab(){this._popup&&this._popup.hide()}})}_getDefaultOptions(){return I({},super._getDefaultOptions(),{items:[],onItemClick:null,dataSource:null,itemTemplate:"item",onButtonClick:null,activeStateEnabled:!0,hoverStateEnabled:!0,opened:!1,onItemRendered:null,closeOnClick:!0,useInkRipple:!1,container:void 0,animation:{show:{type:"fade",from:0,to:1},hide:{type:"fade",to:0}}})}_defaultOptionsRules(){return super._defaultOptionsRules().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>pt(),options:{useInkRipple:!0,animation:{show:{type:"pop",duration:200,from:{scale:0},to:{scale:1}},hide:{type:"pop",duration:200,from:{scale:1},to:{scale:0}}}}}])}_init(){super._init(),this.$element().addClass("dx-dropdownmenu"),this._initItemClickAction(),this._initButtonClickAction()}_initItemClickAction(){this._itemClickAction=this._createActionByOption("onItemClick")}_initButtonClickAction(){this._buttonClickAction=this._createActionByOption("onButtonClick")}_initTemplates(){this._templateManager.addDefaultTemplates({content:new hr("content")}),super._initTemplates()}_initMarkup(){this._renderButton(),super._initMarkup()}_render(){super._render(),this.setAria({haspopup:!0,expanded:this.option("opened")})}_renderContentImpl(){this.option("opened")&&this._renderPopup()}_clean(){this._cleanFocusState(),this._list&&this._list.$element().remove(),this._popup&&this._popup.$element().remove(),delete this._list,delete this._popup}_renderButton(){let e=this.$element().addClass("dx-dropdownmenu-button");this._button=this._createComponent(e,rt,{icon:"overflow",template:"content",stylingMode:ut()?"text":"contained",useInkRipple:this.option("useInkRipple"),hoverStateEnabled:!1,focusStateEnabled:!1,onClick:t=>{this.option("opened",!this.option("opened")),this._buttonClickAction(t)}})}_toggleActiveState(e,t,n){this._button._toggleActiveState(e,t,n)}_toggleMenuVisibility(e){var t,n;let o=e??!((t=this._popup)!==null&&t!==void 0&&t.option("visible"));e&&this._renderPopup(),(n=this._popup)===null||n===void 0||n.toggle(o),this.setAria("expanded",o)}_renderPopup(){if(this._$popup)return;this._$popup=u("<div>").appendTo(this.$element());let{rtlEnabled:e,container:t,animation:n}=this.option();this._popup=this._createComponent(this._$popup,"dxPopup",{onInitialized(o){let{component:s}=o;s.$wrapper().addClass("dx-dropdownmenu-popup-wrapper").addClass("dx-dropdownmenu-popup")},deferRendering:!1,preventScrollEvents:!1,contentTemplate:o=>this._renderList(o),_ignoreFunctionValueDeprecation:!0,maxHeight:()=>this._getMaxHeight(),position:{my:"top "+(e?"left":"right"),at:"bottom "+(e?"left":"right"),collision:"fit flip",offset:{v:3},of:this.$element()},animation:n,onOptionChanged:o=>{let{name:s,value:r}=o;s==="visible"&&this.option("opened",r)},container:t,autoResizeEnabled:!1,height:"auto",width:"auto",hideOnOutsideClick:o=>this._closeOutsideDropDownHandler(o),hideOnParentScroll:!0,shading:!1,dragEnabled:!1,showTitle:!1,fullScreen:!1,_fixWrapperPosition:!0})}_getMaxHeight(){let e=this.$element(),t=e.offset().top,n=X(K()),o=Math.max(t,n-t-X(e));return Math.min(n,o-3-10)}_closeOutsideDropDownHandler(e){return!u(e.target).closest(this.$element()).length}_renderList(e){let t=u(e);t.addClass("dx-dropdownmenu-list"),this._list=this._createComponent(t,Xg,{dataSource:this._getListDataSource(),pageLoadMode:"scrollBottom",indicateLoading:!1,noDataText:"",itemTemplate:this.option("itemTemplate"),onItemClick:n=>{this.option("closeOnClick")&&this.option("opened",!1),this._itemClickAction(n)},tabIndex:-1,focusStateEnabled:!1,activeStateEnabled:!0,onItemRendered:this.option("onItemRendered"),_itemAttributes:{role:"menuitem"}})}_itemOptionChanged(e,t,n){var o;(o=this._list)===null||o===void 0||o._itemOptionChanged(e,t,n),ad(this._list,e)}_getListDataSource(){return this.option("dataSource")??this.option("items")}_setListDataSource(){var e;(e=this._list)===null||e===void 0||e.option("dataSource",this._getListDataSource()),delete this._deferRendering}_getKeyboardListeners(){return super._getKeyboardListeners().concat([this._list])}_toggleVisibility(e){var t;super._toggleVisibility(e),(t=this._button)===null||t===void 0||t.option("visible",e)}_optionChanged(e){var t,n,o;let{name:s,value:r}=e;switch(s){case"items":case"dataSource":this.option("opened")?this._setListDataSource():this._deferRendering=!0;break;case"itemTemplate":(t=this._list)===null||t===void 0||t.option(s,this._getTemplate(r));break;case"onItemClick":this._initItemClickAction();break;case"onButtonClick":this._buttonClickAction();break;case"useInkRipple":this._invalidate();break;case"focusStateEnabled":(n=this._list)===null||n===void 0||n.option(s,r),super._optionChanged(e);break;case"onItemRendered":(o=this._list)===null||o===void 0||o.option(s,r);break;case"opened":this._deferRendering&&this._setListDataSource(),this._toggleMenuVisibility(r),this._updateFocusableItemsTabIndex();break;case"closeOnClick":break;case"container":this._popup&&this._popup.option(s,r);break;case"disabled":this._list&&this._updateFocusableItemsTabIndex();break;default:super._optionChanged(e)}}_updateFocusableItemsTabIndex(){this.option("items").forEach(e=>ad(this._list,e))}};var xy="dx-toolbar-item-invisible",Zg=class{constructor(e){this._toolbar=e}_initMarkup(){nt(()=>{this._renderOverflowMenu(),this._renderMenuItems()})}_renderOverflowMenu(){if(!this._hasVisibleMenuItems())return;this._renderMenuButtonContainer();let e=u("<div>").appendTo(this._overflowMenuContainer()),t=this._toolbar._createActionByOption("onItemClick"),n=this._toolbar._getTemplateByOption("menuItemTemplate");this._menu=this._toolbar._createComponent(e,Qg,{disabled:this._toolbar.option("disabled"),itemTemplate:()=>n,onItemClick:o=>{t(o)},container:this._toolbar.option("menuContainer"),onOptionChanged:o=>{let{name:s,value:r}=o;s==="opened"&&this._toolbar.option("overflowMenuVisible",r),s==="items"&&this._updateMenuVisibility(r)}})}renderMenuItems(){this._menu||this._renderOverflowMenu(),this._menu&&this._menu.option("items",this._getMenuItems()),this._menu&&!this._menu.option("items").length&&this._menu.option("opened",!1)}_renderMenuButtonContainer(){this._$overflowMenuContainer=u("<div>").appendTo(this._toolbar._$afterSection).addClass("dx-toolbar-button").addClass("dx-toolbar-menu-container")}_overflowMenuContainer(){return this._$overflowMenuContainer}_updateMenuVisibility(e){let t=e??this._getMenuItems(),n=t.length&&this._hasVisibleMenuItems(t);this._toggleMenuVisibility(n)}_toggleMenuVisibility(e){this._overflowMenuContainer()&&this._overflowMenuContainer().toggleClass("dx-state-invisible",!e)}_renderMenuItems(){nt(()=>{this.renderMenuItems()})}_dimensionChanged(){this.renderMenuItems()}_getToolbarItems(){return xt(this._toolbar.option("items")??[],e=>!this._toolbar._isMenuItem(e))}_getHiddenItems(){return this._toolbar._itemContainer().children(`.dx-toolbar-item-auto-hide.${xy}`).not(".dx-state-invisible")}_getMenuItems(){let e=xt(this._toolbar.option("items")??[],o=>this._toolbar._isMenuItem(o)),t=this._getHiddenItems();return this._restoreItems=this._restoreItems??[],[...[].slice.call(t).map(o=>{let s=this._toolbar._getItemData(o),r=u(o),a=r.children();return m({menuItemTemplate:()=>(this._restoreItems.push({container:r,item:a}),u("<div>").addClass("dx-toolbar-item-auto-hide").append(a))},s)}),...e]}_hasVisibleMenuItems(e){let t=e??this._toolbar.option("items"),n=!1,o=me("visible"),s=me("locateInMenu");return x(t,(r,a)=>{let l=o(a,{functionsAsIs:!0}),d=s(a,{functionsAsIs:!0});(l!==!1&&(d==="auto"||d==="always")||a.location==="menu")&&(n=!0)}),n}_arrangeItems(){this._toolbar._$centerSection.css({margin:"0 auto",float:"none"}),x(this._restoreItems??[],(t,n)=>{u(n.container).append(n.item)}),this._restoreItems=[];let e=z(this._toolbar.$element());return this._hideOverflowItems(e),e}_hideOverflowItems(e){let t=this._toolbar.$element().find(".dx-toolbar-item-auto-hide");if(!t.length)return;let n=e??z(this._toolbar.$element());u(t).removeClass(xy);let o=this._getItemsWidth();for(;t.length&&n<o;)t.eq(-1).addClass(xy),o=this._getItemsWidth(),t.splice(-1,1)}_getItemsWidth(){return this._toolbar._getSummaryItemsSize("width",[this._toolbar._$beforeSection,this._toolbar._$centerSection,this._toolbar._$afterSection])}_itemOptionChanged(e,t,n){if((t==="disabled"||t==="options.disabled")&&this._toolbar._isMenuItem(e)){var o;(o=this._menu)===null||o===void 0||o._itemOptionChanged(e,t,n);return}this.renderMenuItems()}_renderItem(e,t){e.locateInMenu==="auto"&&t.addClass("dx-toolbar-item-auto-hide")}_optionChanged(e,t){var n,o,s,r,a;switch(e){case"disabled":(n=this._menu)===null||n===void 0||n.option(e,t);break;case"overflowMenuVisible":(o=this._menu)===null||o===void 0||o.option("opened",t);break;case"onItemClick":(s=this._menu)===null||s===void 0||s.option(e,t);break;case"menuContainer":(r=this._menu)===null||r===void 0||r.option("container",t);break;case"menuItemTemplate":(a=this._menu)===null||a===void 0||a.option("itemTemplate",t)}}};var Jg=class extends cv{_getDefaultOptions(){return I({},super._getDefaultOptions(),{menuItemTemplate:"menuItem",menuContainer:void 0,overflowMenuVisible:!1,multiline:!1})}_isMultiline(){return this.option("multiline")}_dimensionChanged(e){e!=="height"&&(super._dimensionChanged(),this._layoutStrategy._dimensionChanged())}_initMarkup(){super._initMarkup(),this._updateFocusableItemsTabIndex(),this._layoutStrategy._initMarkup()}_renderToolbar(){super._renderToolbar(),this._renderLayoutStrategy()}_itemContainer(){return this._isMultiline()?this._$toolbarItemsContainer:super._itemContainer()}_renderLayoutStrategy(){this.$element().toggleClass("dx-toolbar-multiline",this._isMultiline()),this._layoutStrategy=this._isMultiline()?new Yg(this):new Zg(this)}_renderSections(){if(!this._isMultiline())return super._renderSections()}_postProcessRenderItems(){this._layoutStrategy._hideOverflowItems(),this._layoutStrategy._updateMenuVisibility(),super._postProcessRenderItems(),this._layoutStrategy._renderMenuItems()}_renderItem(e,t,n,o){let s=super._renderItem(e,t,n,o);this._layoutStrategy._renderItem(t,s);let{widget:r,showText:a}=t;return r==="dxButton"&&a==="inMenu"&&s.toggleClass("dx-toolbar-text-auto-hide"),s}_getItemsWidth(){return this._layoutStrategy._getItemsWidth()}_getMenuItems(){return this._layoutStrategy._getMenuItems()}_getToolbarItems(){return this._layoutStrategy._getToolbarItems()}_arrangeItems(){if(this.$element().is(":hidden"))return;let e=this._layoutStrategy._arrangeItems();this._isMultiline()||super._arrangeItems(e)}_itemOptionChanged(e,t,n,o){this._isMenuItem(e)||super._itemOptionChanged(e,t,n,o),this._layoutStrategy._itemOptionChanged(e,t,n),(t==="disabled"||t==="options.disabled")&&ad(this,e),t==="location"&&this.repaint()}_updateFocusableItemsTabIndex(){this._getToolbarItems().forEach(e=>ad(this,e))}_isMenuItem(e){return e.location==="menu"||e.locateInMenu==="always"}_isToolbarItem(e){return e.location===void 0||e.locateInMenu==="never"}_optionChanged(e){let{name:t,value:n}=e;switch(this._layoutStrategy._optionChanged(t,n),t){case"menuContainer":case"menuItemTemplate":case"overflowMenuVisible":break;case"multiline":this._invalidate();break;case"disabled":super._optionChanged(e),this._updateFocusableItemsTabIndex();break;default:super._optionChanged(e)}}updateDimensions(){this._dimensionChanged()}};G("dxToolbar",Jg);var mk=Jg;var fk=mk;var _k=fk;var Ck=["addRowButton","applyFilterButton","columnChooserButton","exportButton","groupPanel","revertButton","saveButton","searchPanel"],vy=class extends eo{init(){super.init(),this._editingController=this.getController("editing"),this._headerFilterController=this.getController("headerFilter"),this.createAction("onToolbarPreparing",{excludeValidators:["disabled","readOnly"]})}_getToolbarItems(){return[]}_getButtonContainer(){return u("<div>").addClass(this.addWidgetPrefix("toolbar-button"))}_getToolbarButtonClass(e){let t=e?` ${e}`:"";return this.addWidgetPrefix("toolbar-button")+t}_getToolbarOptions(){let e=this.option("toolbar"),t={toolbarOptions:{items:this._getToolbarItems(),visible:e?.visible,disabled:e?.disabled,onItemRendered(o){let s=o.itemData.onItemRendered;s&&s(o)}}},n=e?.items;if(t.toolbarOptions.items=this._normalizeToolbarItems(t.toolbarOptions.items,n),this.executeAction("onToolbarPreparing",t),t.toolbarOptions&&!f(t.toolbarOptions.visible)){let o=t.toolbarOptions.items;t.toolbarOptions.visible=!!(o!=null&&o.length)}return t.toolbarOptions}_normalizeToolbarItems(e,t){e.forEach(a=>{if(!Ck.includes(a.name))throw new Error(`Default toolbar item '${a.name}' is not added to DEFAULT_TOOLBAR_ITEM_NAMES`)});let n={location:"after"},o=Array.isArray(t);if(!f(t))return e;o||(t=[t]);let s={};e.forEach(a=>{s[a.name]=a});let r=t.map(a=>(B(a)&&(a={name:a}),f(a.name)&&(f(s[a.name])?a=m(!0,{},s[a.name],a):Ck.includes(a.name)&&(a=I({},a,{visible:!1}))),m(!0,{},n,a)));return o?r:r[0]}_renderCore(){if(this._toolbar)this._toolbar.option(this._toolbarOptions);else{let e=this.element();e.addClass(this.addWidgetPrefix("header-panel"));let t=O.format(this.component.NAME+"-ariaToolbar"),n=u("<div>").attr("aria-label",t).appendTo(e);this._toolbar=this._createComponent(n,_k,this._toolbarOptions)}}_columnOptionChanged(){}_handleDataChanged(){this._requireReady&&this.render()}_isDisabledDefinedByUser(e){var t;let n=(t=this.option("toolbar"))===null||t===void 0?void 0:t.items,o=n?.find(s=>s?.name===e);return f(o?.disabled)}render(){this._toolbarOptions=this._getToolbarOptions(),super.render.apply(this,arguments)}setToolbarItemDisabled(e,t){let n=this._toolbar,o=this._isDisabledDefinedByUser(e);if(!n||o)return;let r=(n.option("items")??[]).findIndex(l=>l.name===e);if(r<0)return;let a=n.option(`items[${r}]`);n.option(`items[${r}].disabled`,t),a.options&&n.option(`items[${r}].options.disabled`,t)}updateToolbarDimensions(){var e;(e=this._toolbar)===null||e===void 0||e.updateDimensions()}getHeaderPanel(){return this.element()}getHeight(){return this.getElementHeight()}optionChanged(e){if(e.name==="onToolbarPreparing"&&(this._invalidate(),e.handled=!0),e.name==="toolbar"){let s=Fn(e.fullName),r=e.fullName.replace(/^toolbar\./,"");if(s.length===1||s[1]==="visible")this._invalidate();else if(s[1]==="items"){if(s.length===2)this._invalidate();else if(s.length===3){var t;let a=this._normalizeToolbarItems(this._getToolbarItems(),e.value);(t=this._toolbar)===null||t===void 0||t.option(r,a)}else if(s.length>=4){var n;(n=this._toolbar)===null||n===void 0||n.option(r,e.value)}}else{var o;(o=this._toolbar)===null||o===void 0||o.option(r,e.value)}e.handled=!0}super.optionChanged(e)}isVisible(){return!!(this._toolbarOptions&&this._toolbarOptions.visible)}allowDragging(){}hasGroupedColumns(){}},hX=i=>class extends i{_updateDimensionsCore(){super._updateDimensionsCore.apply(this,arguments),this.getView("headerPanel").updateToolbarDimensions()}},by={defaultOptions:()=>({}),views:{headerPanel:vy},extenders:{controllers:{resizing:hX}}};var iGe=by.views.headerPanel;H.registerModule("headerPanel",by);var em=class extends Xe{_getDefaultOptions(){let e=super._getDefaultOptions();return x(this.getGridCoreHelper().modules,function(){A(this.defaultOptions)&&m(!0,e,this.defaultOptions())}),e}_init(){this._activeStateUnit=".dx-row",super._init()}_setDeprecatedOptions(){super._setDeprecatedOptions(),m(this._deprecatedOptions,{"columnChooser.allowSearch":{since:"23.1",message:'Use the "columnChooser.search.enabled" option instead'},"columnChooser.searchTimeout":{since:"23.1",message:'Use the "columnChooser.search.timeout" option instead'}})}_clean(){}_optionChanged(e){this.getGridCoreHelper().callModuleItemsMethod(this,"optionChanged",[e]),e.handled||super._optionChanged(e)}_dimensionChanged(){this.updateDimensions(!0)}_visibilityChanged(e){e&&this.updateDimensions()}_renderContentImpl(){this.getView("gridView").update()}_renderContent(){let e=this;nt(()=>{e._renderContentImpl()})}_dispose(){super._dispose(),this.getGridCoreHelper().callModuleItemsMethod(this,"dispose")}isReady(){return this.getController("data").isReady()}getController(e){return this._controllers[e]}getView(e){return this._views[e]}getGridCoreHelper(){}beginUpdate(){super.beginUpdate(),this.getGridCoreHelper().callModuleItemsMethod(this,"beginUpdate")}endUpdate(){this.getGridCoreHelper().callModuleItemsMethod(this,"endUpdate"),super.endUpdate()}};var pX="Specifying grid templates with the jQuery selector name is now deprecated. Use the DOM Node or the jQuery object that references this selector instead.";H.registerModulesOrder(["stateStoring","columns","selection","editorFactory","columnChooser","grouping","editing","editingRowBased","editingFormBased","editingCellBased","masterDetail","validating","adaptivity","data","virtualScrolling","columnHeaders","filterRow","headerPanel","headerFilter","sorting","search","rows","pager","columnsResizingReordering","contextMenu","keyboardNavigation","errorHandling","summary","columnFixing","export","gridView"]);var tm=class extends em{_defaultOptionsRules(){return super._defaultOptionsRules().concat([{device:{platform:"ios"},options:{showRowLines:!0}},{device:()=>pt(),options:{showRowLines:!0,showColumnLines:!1,headerFilter:{height:315},editing:{useIcons:!0},selection:{showCheckBoxesMode:"always"}}},{device:()=>be.webkit,options:{loadingTimeout:30,loadPanel:{animation:{show:{easing:"cubic-bezier(1, 0, 1, 0)",duration:500,from:{opacity:0},to:{opacity:1}}}}}},{device:e=>e.deviceType!=="desktop",options:{grouping:{expandMode:"rowClick"}}}])}_init(){super._init(),M.logHeaderFilterDeprecatedWarningIfNeed(this),H.processModules(this,H),H.callModuleItemsMethod(this,"init")}_initMarkup(){super._initMarkup.apply(this,arguments),this.getView("gridView").render(this.$element())}_setDeprecatedOptions(){super._setDeprecatedOptions(),m(this._deprecatedOptions,{useKeyboard:{since:"19.2",alias:"keyboardNavigation.enabled"},rowTemplate:{since:"21.2",message:'Use the "dataRowTemplate" option instead'}})}static registerModule(e,t){H.registerModule(e,t)}getGridCoreHelper(){return H}_getTemplate(e){let t=e;return B(t)&&t.startsWith("#")&&(t=u(e),Js.warn(pX)),super._getTemplate(t)}focus(e){this.getController("keyboardNavigation").focus(e)}};G("dxDataGrid",tm);var xk=tm;var gX=/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)Z$/,yk=function(i){i&&x(i,(e,t)=>{if(q(t)||Array.isArray(t))yk(t);else if(typeof t=="string"){let n=gX.exec(t);n&&(i[e]=new Date(Date.UTC(+n[1],+n[2]-1,+n[3],+n[4],+n[5],+n[6])))}})},vk=function(i){let e=i.type==="sessionStorage"?Ch():K().localStorage;if(!e)throw new Error("E1007");return e},bk=function(i){return f(i.storageKey)?i.storageKey:"storage"},im=class extends Ce.ViewController{getDataController(){return this.getController("data")}getExportController(){return this.getController("export")}getColumnsController(){return this.getController("columns")}init(){return this._state={},this._isLoaded=!1,this._isLoading=!1,this._windowUnloadHandler=()=>{this._savingTimeoutID!==void 0&&this._saveState(this.state())},_.on(K(),"visibilitychange",this._windowUnloadHandler),this}optionChanged(e){let t=this;e.name==="stateStoring"?(t.isEnabled()&&!t.isLoading()&&t.load(),e.handled=!0):super.optionChanged(e)}dispose(){clearTimeout(this._savingTimeoutID),_.off(K(),"visibilitychange",this._windowUnloadHandler)}_loadState(){let e=this.option("stateStoring");if(e.type==="custom")return e.customLoad&&e.customLoad();try{return JSON.parse(vk(e).getItem(bk(e)))}catch(t){Z.log("W1022","State storing",t.message)}}_saveState(e){let t=this.option("stateStoring");if(t.type==="custom"){t.customSave&&t.customSave(e);return}try{vk(t).setItem(bk(t),JSON.stringify(e))}catch(n){Z.log(n.message)}}publicMethods(){return["state"]}isEnabled(){return this.option("stateStoring.enabled")}isLoaded(){return this._isLoaded}isLoading(){return this._isLoading}load(){this._isLoading=!0;let e=ht(this._loadState());return e.always(()=>{this._isLoaded=!0,this._isLoading=!1}).done(t=>{t!==null&&!dt(t)&&this.state(t)}),e}state(e){let t=this;if(!arguments.length)return m(!0,{},t._state);t._state=m({},e),yk(t._state)}save(){let e=this;clearTimeout(e._savingTimeoutID),e._savingTimeoutID=setTimeout(()=>{e._saveState(e.state()),e._savingTimeoutID=void 0},e.option("stateStoring.savingTimeout"))}};var mX=i=>{let e=i.getView("pagerView"),t=i.getController("data"),n={allowedPageSizes:e?e.getPageSizes():void 0,filterPanel:{filterEnabled:i.option("filterPanel.filterEnabled")},filterValue:i.option("filterValue"),focusedRowKey:i.option("focusedRowEnabled")?i.option("focusedRowKey"):void 0};return m(n,t.getUserState())},fX=i=>{let e=i.getController("columns"),t=i.getController("selection"),n=i.getController("export"),o=i.getController("data");e&&e.columnsChanged.add(()=>{i.updateState({columns:e.getUserState()})}),t&&t.selectionChanged.add(s=>{i.updateState({selectedRowKeys:s.selectedRowKeys,selectionFilter:s.selectionFilter})}),o&&(i._initialPageSize=i.option("paging.pageSize"),i._initialFilterValue=i.option("filterValue"),o.changed.add(()=>{let s=mX(i);i.updateState(s)})),n&&n.selectionOnlyChanged.add(()=>{i.updateState({exportSelectionOnly:n.selectionOnly()})})};var _X=(i,e)=>{let t=i.getController("filterSync"),n=i.getController("columns"),o=e.columns||e.filterValue!==void 0;return t?o?e.filterValue||t.getFilterValueFromColumns(e.columns):i._initialFilterValue||t.getFilterValueFromColumns(n.getColumns()):null},CX=i=>class extends i{init(){super.init(),this._dataController.stateLoaded.add(()=>{if(this._dataController.isLoaded()&&!this._dataController.getDataSource()){this.setLoading(!1),this.renderNoDataText();let e=this.component.getView("columnHeadersView");e&&e.render(),this.component._fireContentReadyAction()}})}},xX=i=>class extends i{init(){return super.init.apply(this,arguments),fX(this),this}isLoading(){return super.isLoading()||this.getDataController().isStateLoading()}state(e){let t=super.state.apply(this,arguments);return e!==void 0&&this.applyState(m(!0,{},e)),t}updateState(e){if(this.isEnabled()){let t=this.state(),n=m({},t,e),o=ai(t),s=ai(n);ve(o,s)||(e=m(!0,{},e),m(this._state,e),this.save())}else m(this._state,e)}applyState(e){var t;let{allowedPageSizes:n}=e,{searchText:o}=e,{selectedRowKeys:s}=e,{selectionFilter:r}=e,a=this.option("scrolling.mode"),l=a==="virtual"||a==="infinite",d=this.option("pager.visible")===!0&&this.option("pager.showPageSizeSelector"),c=(t=this.getView("rowsView"))===null||t===void 0?void 0:t.hasHeight();this.component.beginUpdate(),this.getColumnsController()&&this.getColumnsController().setUserState(e.columns),this.getExportController()&&this.getExportController().selectionOnly(e.exportSelectionOnly),this.option("selection.deferred")||this.option("selectedRowKeys",s||[]),this.option("selectionFilter",r),n&&this.option("pager.allowedPageSizes")==="auto"&&(this.option("pager").allowedPageSizes=n),this.option("focusedRowEnabled")&&(this.option("focusedRowIndex",-1),this.option("focusedRowKey",e.focusedRowKey??null)),this.component.endUpdate(),this.option("searchPanel.text",o||""),this.option("filterValue",_X(this,e)),this.option("filterPanel.filterEnabled",e.filterPanel?e.filterPanel.filterEnabled:!0),this.option("paging.pageIndex",(!l||c)&&e.pageIndex||0),this.option("paging.pageSize",(!l||d)&&f(e.pageSize)?e.pageSize:this._initialPageSize),this.getDataController()&&this.getDataController().reset()}},vX=i=>class extends i{_shouldReturnVisibleColumns(){return super._shouldReturnVisibleColumns.apply(this,arguments)&&(!this._stateStoringController.isEnabled()||this._stateStoringController.isLoaded())}},bX=i=>class extends i{dispose(){clearTimeout(this._restoreStateTimeoutID),super.dispose()}callbackNames(){return super.callbackNames().concat(["stateLoaded"])}_refreshDataSource(){if(this._stateStoringController.isEnabled()&&!this._stateStoringController.isLoaded()){clearTimeout(this._restoreStateTimeoutID);let e=new y;return this._restoreStateTimeoutID=setTimeout(()=>{this._stateStoringController.load().always(()=>{this._restoreStateTimeoutID=null}).done(()=>{super._refreshDataSource(),this.stateLoaded.fire(),e.resolve()}).fail(t=>{this.stateLoaded.fire(),this._handleLoadError(t||"Unknown error"),e.reject()})}),e.promise()}this.isStateLoading()||super._refreshDataSource()}isLoading(){return super.isLoading()||this._stateStoringController.isLoading()}isStateLoading(){return f(this._restoreStateTimeoutID)}isLoaded(){return super.isLoaded()&&!this.isStateLoading()}},yX=i=>class extends i{_fireSelectionChanged(e){let t=this.option("selection.deferred");this._stateStoringController.isLoading()&&t||super._fireSelectionChanged.apply(this,arguments)}},Ok={defaultOptions:()=>({stateStoring:{enabled:!1,storageKey:null,type:"localStorage",customLoad:null,customSave:null,savingTimeout:2e3}}),controllers:{stateStoring:im},extenders:{views:{rowsView:CX},controllers:{stateStoring:xX,columns:vX,data:bX,selection:yX}}};H.registerModule("stateStoring",Ok);var OX="dx-select-checkboxes-hidden";var Jo="selection.showCheckBoxesMode",uu="selection.mode",Sk=function(i,e){let t=i.getView("rowsView"),n=i.getController("selection"),o=u(e.target).closest(".dx-data-row"),s=t.getRowIndex(o);s<0||(i.option(Jo)==="onLongTap"?n.isSelectionWithCheckboxes()?n.stopSelectionWithCheckboxes():n.startSelectionWithCheckboxes():(i.option(Jo)==="onClick"&&n.startSelectionWithCheckboxes(),i.option(Jo)!=="always"&&n.changeItemSelection(s,{control:!0})))},SX=function(i,e){let t=0,n=i._dataController.store(),o=n&&n.key(),s=Array.isArray(o);if(!e.length)return!1;if(s&&Array.isArray(e[0])&&e[1]==="and"){for(let r=0;r<e.length;r++)if(Array.isArray(e[r])){if(e[r][0]!==o[t]||e[r][1]!=="=")return!0;t++}return!1}return o!==e[0]},EX=(i,e)=>{let{component:t}=e,n=t.getView("rowsView");t.option("renderAsync")&&!t.option("selection.deferred")&&(e.value=t.isRowSelected(e.row.key)),n.renderSelectCheckBoxContainer(u(i),e)},wX=(i,e)=>{let{column:t}=e,n=u(i),o=e.component.getView("columnHeadersView");n.addClass("dx-editor-cell"),o._renderSelectAllCheckBox(n,t),o._attachSelectAllCheckBoxClickEvent(n)},yy=class extends Ce.Controller{init(){let{deferred:e,selectAllMode:t,mode:n}=this.option("selection")??{};this.option("scrolling.mode")==="infinite"&&!e&&n==="multiple"&&t==="allPages"&&Z.log("W1018"),this._dataController=this.getController("data"),this._columnsController=this.getController("columns"),this._stateStoringController=this.getController("stateStoring"),this._selectionMode=n,this._isSelectionWithCheckboxes=!1,this._selection=this._createSelection(),this._updateSelectColumn(),this.createAction("onSelectionChanged",{excludeValidators:["disabled","readOnly"]}),this._dataPushedHandler||(this._dataPushedHandler=this._handleDataPushed.bind(this),this._dataController.pushed.add(this._dataPushedHandler))}_handleDataPushed(e){this._deselectRemovedOnPush(e),this._updateSelectedOnPush(e)}_deselectRemovedOnPush(e){let t=this.option("selection.deferred"),n=e.filter(o=>o.type==="remove").map(o=>o.key);if(t){let o=this._dataController.items().filter(s=>s.isSelected).map(s=>s.key);n=n.filter(s=>o.find(r=>ve(r,s)))}n.length&&this.deselectRows(n)}_updateSelectedOnPush(e){if(this.option("selection.deferred"))return;let n=e.filter(s=>s.type==="update"),o=this.getSelectedRowsData();Gn({keyInfo:this._selection.options,data:o,changes:n})}_getSelectionConfig(){let e=this._dataController,t=this._columnsController,n=this.option("selection")??{},{deferred:o}=n,s=this.option("scrolling.mode"),r=s==="virtual"||s==="infinite",a=this.option("selection.allowSelectAll"),l=this.option("scrolling.legacyMode");return{selectedKeys:this.option("selectedRowKeys"),mode:this._selectionMode,deferred:o,alwaysSelectByShift:n.alwaysSelectByShift,maxFilterLengthInRequest:n.maxFilterLengthInRequest,selectionFilter:this.option("selectionFilter"),ignoreDisabledItems:!0,isVirtualPaging:r,sensitivity:this.option("selection.sensitivity"),allowLoadByRange(){let d=t.getGroupColumns().length>0;return r&&!l&&!d&&a&&!o},key:()=>e?.key(),keyOf:d=>e?.keyOf(d),dataFields(){var d;return(d=e.dataSource())===null||d===void 0?void 0:d.select()},load(d){var c;return((c=e.dataSource())===null||c===void 0?void 0:c.load(d))||new y().resolve([])},plainItems:d=>e.items(!0),isItemSelected:d=>d.selected,isSelectableItem:d=>d?.rowType==="data"&&!d.isNewRow,getItemData:d=>f(d?.rowType)?d?.oldData||d?.data:d,filter:()=>e.getCombinedFilter(o),totalCount:()=>e.totalCount(),getLoadOptions(d,c,h){var p;let{sort:g,filter:C}=((p=e.dataSource())===null||p===void 0?void 0:p.lastLoadOptions())??{},v=Math.min(d,c),b=Math.max(d,c);f(h)&&(v=Math.min(h,v),b=Math.max(h,b));let T=b-v+1;return{skip:v,take:T,filter:C,sort:g}},onSelectionChanged:this._updateSelectedItems.bind(this)}}_updateSelectColumn(){let e=this._columnsController,t=this.isSelectColumnVisible();e.addCommandColumn({type:"selection",command:"select",visible:t,visibleIndex:-1,dataType:"boolean",alignment:"center",cssClass:"dx-command-select",width:"auto",cellTemplate:EX,headerCellTemplate:wX}),e.columnOption("command:select","visible",t)}_createSelection(){let e=this._getSelectionConfig();return new dl(e)}_fireSelectionChanged(e){let t=this.option("selection.deferred")?{selectionFilter:this.option("selectionFilter")}:{selectedRowKeys:this.option("selectedRowKeys")};this.selectionChanged.fire(t),e&&this.executeAction("onSelectionChanged",e)}_updateCheckboxesState(e){let{isDeferredMode:t}=e,{selectionFilter:n}=e,{selectedItemKeys:o}=e,{removedItemKeys:s}=e;this.option(Jo)==="onClick"&&((t?n&&SX(this,n):o.length>1)?this.startSelectionWithCheckboxes():(t?n&&!n.length:o.length===0&&s.length)&&this.stopSelectionWithCheckboxes())}_updateSelectedItems(e){let t=this,n,o=t.option("selection.deferred"),s=t._selection.selectionFilter(),r=t._dataController,a=r.items(!0),l=r.items();if(!a)return;let d=t.isSelectionWithCheckboxes(),c=t.getChangedItemIndexes(a),h=t.getChangedItemIndexes(l);t._updateCheckboxesState({selectedItemKeys:e.selectedItemKeys,removedItemKeys:e.removedItemKeys,selectionFilter:s,isDeferredMode:o}),(c.length||d!==t.isSelectionWithCheckboxes())&&r.updateItems({changeType:"updateSelection",itemIndexes:h}),o?(t.option("selectionFilter",s),n={}):(e.addedItemKeys.length||e.removedItemKeys.length)&&(t._selectedItemsInternalChange=!0,t.option("selectedRowKeys",e.selectedItemKeys.slice(0)),t._selectedItemsInternalChange=!1,n={selectedRowsData:e.selectedItems.slice(0),selectedRowKeys:e.selectedItemKeys.slice(0),currentSelectedRowKeys:e.addedItemKeys.slice(0),currentDeselectedRowKeys:e.removedItemKeys.slice(0)}),t._fireSelectionChanged(n)}getChangedItemIndexes(e){let t=this,n=[],o=this.option("selection.deferred");for(let s=0,{length:r}=e;s<r;s++){let a=e[s],l=t.isRowSelected(o?a.data:a.key);t._selection.isDataItem(a)&&a.isSelected!==l&&n.push(s)}return n}callbackNames(){return["selectionChanged"]}optionChanged(e){var t;super.optionChanged(e);let n=!!((t=this._selection)!==null&&t!==void 0&&t.options);switch(e.name){case"selection":{let o=this._selectionMode;if(this.init(),n&&e.fullName==="selection.sensitivity"&&(this._selection.options.sensitivity=e.value),e.fullName!=="selection.showCheckBoxesMode"){let s=this._selectionMode,r=this.option("selectedRowKeys");o!==s&&(s==="single"?r.length>1&&(r=[r[0]]):s!=="multiple"&&(r=[])),this.selectRows(r).always(()=>{this._fireSelectionChanged()})}this._columnsController.updateColumns(),e.handled=!0;break}case"selectionFilter":this._selection.selectionFilter(e.value),e.handled=!0;break;case"selectedRowKeys":{let o=e.value||[];Array.isArray(o)&&!this._selectedItemsInternalChange&&(this.component.getDataSource()||!o.length)&&this.selectRows(o),e.handled=!0;break}}}publicMethods(){return["selectRows","deselectRows","selectRowsByIndexes","getSelectedRowKeys","getSelectedRowsData","clearSelection","selectAll","deselectAll","startSelectionWithCheckboxes","stopSelectionWithCheckboxes","isRowSelected"]}isRowSelected(e){return this._selection.isItemSelected(e)}isSelectColumnVisible(){return this.option(uu)==="multiple"&&(this.option(Jo)==="always"||this.option(Jo)==="onClick"||this._isSelectionWithCheckboxes)}_isOnePageSelectAll(){return this.option("selection.selectAllMode")==="page"}isSelectAll(){return this._selection.getSelectAllState(this._isOnePageSelectAll())}selectAll(){return this.option(Jo)==="onClick"&&this.startSelectionWithCheckboxes(),this._selection.selectAll(this._isOnePageSelectAll())}deselectAll(){return this._selection.deselectAll(this._isOnePageSelectAll())}clearSelection(){return this.selectedItemKeys([])}refresh(){let e=this.option("selectedRowKeys")??[];return!this.option("selection.deferred")&&e.length?this.selectedItemKeys(e):new y().resolve().promise()}selectedItemKeys(e,t,n,o){return this._selection.selectedItemKeys(e,t,n,o)}getSelectedRowKeys(e){return this._selection.getSelectedItemKeys()}selectRows(e,t){return this.selectedItemKeys(e,t)}deselectRows(e){return this.selectedItemKeys(e,!0,!0)}selectRowsByIndexes(e){let t=this._dataController.items(),n=[];return Array.isArray(e)||(e=Array.prototype.slice.call(arguments,0)),x(e,function(){let o=t[this];o&&o.rowType==="data"&&n.push(o.key)}),this.selectRows(n)}getSelectedRowsData(e){return this._selection.getSelectedItems()}loadSelectedItemsWithFilter(){return this._selection.loadSelectedItemsWithFilter()}changeItemSelection(e,t,n){t=t||{},this.isSelectionWithCheckboxes()&&(t.control=!0);let o=e+this._dataController.getRowIndexOffset()-this._dataController.getRowIndexOffset(!0);return this._selection.changeItemSelection(o,t,n)}focusedItemIndex(e){let t=this;if(f(e))t._selection._focusedItemIndex=e;else return t._selection._focusedItemIndex}isSelectionWithCheckboxes(){return this.option(uu)==="multiple"&&(this.option(Jo)==="always"||this._isSelectionWithCheckboxes)}startSelectionWithCheckboxes(){let e=this;return e.option(uu)==="multiple"&&!e.isSelectionWithCheckboxes()?(e._isSelectionWithCheckboxes=!0,e._updateSelectColumn(),!0):!1}stopSelectionWithCheckboxes(){let e=this;return e._isSelectionWithCheckboxes?(e._isSelectionWithCheckboxes=!1,e._updateSelectColumn(),!0):!1}},IX=i=>class extends i{init(){let e=this.option("selection.deferred");super.init.apply(this,arguments),e&&this._selectionController._updateCheckboxesState({isDeferredMode:!0,selectionFilter:this.option("selectionFilter")})}_loadDataSource(){let e=this;return super._loadDataSource().always(()=>{e._selectionController.refresh()})}_processDataItem(e,t){let n=this._selectionController.isSelectColumnVisible(),o=t.isDeferredSelection=t.isDeferredSelection===void 0?this.option("selection.deferred"):t.isDeferredSelection,s=super._processDataItem.apply(this,arguments);if(s.isSelected=this._selectionController.isRowSelected(o?s.data:s.key),n&&s.values){for(let r=0;r<t.visibleColumns.length;r++)if(t.visibleColumns[r].command==="select"){s.values[r]=s.isSelected;break}}return s}refresh(e){let t=this,n=new y;return super.refresh.apply(this,arguments).done(()=>{!e||e.selection?t._selectionController.refresh().done(n.resolve).fail(n.reject):n.resolve()}).fail(n.reject),n.promise()}_handleDataChanged(e){let t=this.hasLoadOperation();super._handleDataChanged.apply(this,arguments),t&&!this._repaintChangesOnly&&this._selectionController.focusedItemIndex(-1)}_applyChange(e){if(e&&e.changeType==="updateSelection"){e.items.forEach((t,n)=>{let o=this._items[n];o&&(o.isSelected=t.isSelected,o.values=t.values)});return}return super._applyChange.apply(this,arguments)}_endUpdateCore(){let e=this._changes;if(e.length>1&&e.every(n=>n.changeType==="updateSelection")){let n=e.map(o=>o.itemIndexes||[]).reduce((o,s)=>o.concat(s));this._changes=[{changeType:"updateSelection",itemIndexes:n}]}super._endUpdateCore.apply(this,arguments)}},DX=i=>class extends i{_contextMenuPrepared(e){let t=e.event;t.originalEvent&&t.originalEvent.type!=="dxhold"||e.items&&e.items.length>0||Sk(this,t)}},TX=i=>class extends i{init(){super.init(),this._selectionController.selectionChanged.add(this._updateSelectAllValue.bind(this))}_updateSelectAllValue(){let e=this,t=e.element(),n=t&&t.find(".dx-select-checkbox");if(t&&n.length&&e.option("selection.mode")==="multiple"){let o=e._selectionController.isSelectAll(),s=o!==!1,r=e.option("selection.allowSelectAll")?!e._dataController.isEmpty():s;n.dxCheckBox("instance").option({visible:r,value:o})}}_handleDataChanged(e){super._handleDataChanged(e),(!e||e.changeType==="refresh"||e.repaintChangesOnly&&e.changeType==="update")&&this.waitAsyncTemplates().done(()=>{this._updateSelectAllValue()})}_renderSelectAllCheckBox(e,t){let n=this,o=n._dataController.isEmpty(),s=u("<div>").appendTo(e).addClass("dx-select-checkbox");return n.setAria("label",O.format("dxDataGrid-ariaSelectAll"),s),n._editorFactoryController.createEditor(s,m({},t,{parentType:"headerRow",dataType:"boolean",value:this._selectionController.isSelectAll(),editorOptions:{visible:!o&&(n.option("selection.allowSelectAll")||this._selectionController.isSelectAll()!==!1)},tabIndex:n.option("useLegacyKeyboardNavigation")?-1:n.option("tabIndex")||0,setValue:(r,a)=>{let l=n.option("selection.allowSelectAll");a.component.option("visible",l||a.component.option("value")!==!1),!(!a.event||this._selectionController.isSelectAll()===r)&&(a.value&&!l?a.component.option("value",!1):a.value?this._selectionController.selectAll():this._selectionController.deselectAll(),a.event.preventDefault())}})),s}_attachSelectAllCheckBoxClickEvent(e){_.on(e,oe,this.createAction(t=>{let{event:n}=t;u(n.target).closest(".dx-select-checkbox").length||_.trigger(u(n.currentTarget).children(".dx-select-checkbox"),oe),n.preventDefault()}))}},AX=i=>class extends i{renderSelectCheckBoxContainer(e,t){t.rowType==="data"&&!t.row.isNewRow?(e.addClass("dx-editor-cell"),this._attachCheckBoxClickEvent(e),this._renderSelectCheckBox(e,t)):M.setEmptyText(e)}_renderSelectCheckBox(e,t){let n=u("<div>").addClass("dx-select-checkbox").appendTo(e);return this.setAria("label",O.format("dxDataGrid-ariaSelectRow"),n),this._editorFactoryController.createEditor(n,m({},t.column,{parentType:"dataRow",dataType:"boolean",lookup:null,value:t.value,setValue(o,s){var r;(s==null||(r=s.event)===null||r===void 0?void 0:r.type)==="keydown"&&_.trigger(s.element,oe,s)},row:t.row})),n}_attachCheckBoxClickEvent(e){_.on(e,oe,this.createAction(function(t){let{event:n}=t,o=this.getRowIndex(u(n.currentTarget).closest(".dx-row"));o>=0&&(this._selectionController.startSelectionWithCheckboxes(),this._selectionController.changeItemSelection(o,{shift:n.shiftKey}),u(n.target).closest(".dx-select-checkbox").length&&this._dataController.updateItems({changeType:"updateSelection",itemIndexes:[o]}))}))}_update(e){let t=this,n=t.getTableElements();e.changeType==="updateSelection"?n.length>0&&(x(n,(o,s)=>{x(e.itemIndexes||[],(r,a)=>{let l;if(e.items[a]&&(l=t._getRowElements(u(s)).eq(a),l.length)){let{isSelected:d}=e.items[a];l.toggleClass("dx-selection",d===void 0?!1:d).find(".dx-select-checkbox").dxCheckBox("option","value",d),t.setAria("selected",d,l)}})}),t._updateCheckboxesClass()):super._update(e)}_createTable(){let e=this,t=e.option("selection.mode"),n=super._createTable.apply(e,arguments);return t!=="none"&&((e.option(Jo)==="onLongTap"||!Nn)&&_.on(n,D(an.name,"dxDataGridRowsView"),".dx-data-row",e.createAction(o=>{Sk(e.component,o.event),o.event.stopPropagation()})),_.on(n,"mousedown selectstart",e.createAction(o=>{let{event:s}=o;s.shiftKey&&s.preventDefault()}))),n}_createRow(e){let t=super._createRow.apply(this,arguments);if(e){let{isSelected:n}=e;n&&t.addClass("dx-selection"),this.option(uu)!=="none"&&this.setAria("selected",n,t)}return t}_rowClickForTreeList(e){super._rowClick(e)}_rowClick(e){let t=this,n=e.event,o=u(n.target).closest(".dx-selection-disabled").length;t.isClickableElement(u(n.target))||(!o&&(t.option(uu)!=="multiple"||t.option(Jo)!=="always")&&t._selectionController.changeItemSelection(e.rowIndex,{control:ot(n),shift:n.shiftKey})&&(n.preventDefault(),e.handled=!0),super._rowClick(e))}isClickableElement(e){return!!e.closest(".dx-command-select").length}_renderCore(e){let t=super._renderCore(e);return this._updateCheckboxesClass(),t}_updateCheckboxesClass(){let e=this.getTableElements(),t=this._selectionController.isSelectColumnVisible()&&!this._selectionController.isSelectionWithCheckboxes();x(e,(n,o)=>{u(o).toggleClass(OX,t)})}},Ek={defaultOptions:()=>({selection:{mode:"none",showCheckBoxesMode:"onClick",allowSelectAll:!0,selectAllMode:"allPages",deferred:!1,maxFilterLengthInRequest:1500,alwaysSelectByShift:!1},selectionFilter:[],selectedRowKeys:[]}),controllers:{selection:yy},extenders:{controllers:{data:IX,contextMenu:DX},views:{columnHeadersView:TX,rowsView:AX}}};H.registerModule("selection",Ek);var An="dx-treeview",dn=`${An}-node`,zs=`${dn}-container`,Oy=`${dn}-loadindicator`,kr=`${dn}-container-opened`,hu=`${dn}-is-leaf`,$i=`${An}-item`,MX=`${$i}-with-checkbox`,RX=`${$i}-with-custom-expander-icon`,FX=`${An}-custom-expander-icon-item-container`,PX=`${$i}-without-checkbox`,kX=`${$i}-data`,pu=`${An}-toggle-item-visibility`,Sy=`${An}-custom-collapse-icon`,Ey=`${An}-custom-expand-icon`,BX=`${An}-loadindicator`,VX=`${An}-loadindicator-wrapper`,wk=`${An}-toggle-item-visibility-opened`,nm=`${An}-select-all-item`;var om="data-item-id";var LX=`${An}-root-node`,NX=`${An}-expander-icon-stub`,HX=Fg.inherit({_supportedKeys(i){let e=o=>{let s=u(this.option("focusedElement"));if(!s.length)return;o.target=s,o.currentTarget=s,this._itemClickHandler(o,s.children(`.${$i}`)),this._getEventNameByOption(this.option("expandEvent"))===D(oe,"dxTreeView_expand")&&this._expandEventHandler(o)},t=o=>{o.preventDefault();let s=u(this.option("focusedElement")),r=this._getCheckBoxInstance(s);if(!r.option("disabled")){let a=r.option("value");this._updateItemSelection(!a,s.find(`.${$i}`).get(0),!0)}},n=function(o,s){if(!this.option("expandAllEnabled"))return;s.preventDefault();let r=u(this.option("focusedElement"));if(!r.length)return;let a=this._getItemData(r.find(`.${$i}`));this._toggleExpandedNestedItems([a],o)};return m(this.callBase(),{enter:this._showCheckboxes()?t:e,space:this._showCheckboxes()?t:e,asterisk:n.bind(this,!0),minus:n.bind(this,!1)})},_toggleExpandedNestedItems(i,e){if(i)for(let t=0,n=i.length;t<n;t++){let o=i[t],s=this._dataAdapter.getNodeByItem(o);this._toggleExpandedState(s,e),this._toggleExpandedNestedItems(o.items,e)}},_getNodeElement(i,e){let t=this._encodeString(i.internalFields.key);if(e)return e.$nodeByKey||(e.$nodeByKey={},this.$element().find(`.${dn}`).each(function(){let o=u(this),s=o.attr(om);e.$nodeByKey[s]=o})),e.$nodeByKey[t]||u();let n=this.$element().get(0).querySelector(`[${om}="${t}"]`);return u(n)},_activeStateUnit:`.${$i}`,_widgetClass:()=>An,_getDefaultOptions(){let i=m(this.callBase(),{animationEnabled:!0,dataStructure:"tree",deferRendering:!0,expandAllEnabled:!1,hasItemsExpr:"hasItems",selectNodesRecursive:!0,expandNodesRecursive:!0,showCheckBoxesMode:"none",expandIcon:null,collapseIcon:null,selectAllText:O.format("dxList-selectAll"),onItemSelectionChanged:null,onItemExpanded:null,onItemCollapsed:null,scrollDirection:"vertical",useNativeScrolling:!0,virtualModeEnabled:!1,rootValue:0,focusStateEnabled:!1,selectionMode:"multiple",expandEvent:"dblclick",selectByClick:!1,createChildren:null,onSelectAllValueChanged:null,_supportItemUrl:!1});return m(!0,i,{integrationOptions:{useDeferUpdateForTemplates:!1}})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>!Hn,options:{useNativeScrolling:!1}}])},_initSelectedItems:S,_syncSelectionOptions:th,_fireSelectionChanged(){let i=this._selectionChangePromise;P(i).done(()=>{this._createActionByOption("onSelectionChanged",{excludeValidators:["disabled","readOnly"]})()})},_createSelectAllValueChangedAction(){this._selectAllValueChangedAction=this._createActionByOption("onSelectAllValueChanged",{excludeValidators:["disabled","readOnly"]})},_fireSelectAllValueChanged(i){this._selectAllValueChangedAction({value:i})},_checkBoxModeChange(i,e){let t=this.option("searchEnabled"),n=this._selectAllEnabled(e),o=this._itemContainer(t,n);if(this._detachClickEvent(o),this._detachExpandEvent(o),e==="none"||i==="none")return;let s=this._$selectAllItem&&this._$selectAllItem.length;switch(i){case"selectAll":s||(this._createSelectAllValueChangedAction(),this._renderSelectAllItem());break;case"normal":s&&(this._$selectAllItem.remove(),delete this._$selectAllItem)}},_removeSelection(){let i=this;x(this._dataAdapter.getFullData(),(e,t)=>{i._hasChildren(t)&&i._dataAdapter.toggleSelection(t.internalFields.key,!1,!0)})},_optionChanged(i){let{name:e,value:t,previousValue:n}=i;switch(e){case"selectAllText":this._$selectAllItem&&this._$selectAllItem.dxCheckBox("instance").option("text",t);break;case"showCheckBoxesMode":this._checkBoxModeChange(t,n),this._invalidate();break;case"scrollDirection":this.getScrollable().option("direction",t);break;case"useNativeScrolling":this.getScrollable().option("useNative",t);break;case"items":delete this._$selectAllItem,this.callBase(i);break;case"dataSource":this.callBase(i),this._initDataAdapter(),this._filter={};break;case"hasItemsExpr":this._initAccessors(),this.repaint();break;case"expandEvent":this._attachExpandEvent();break;case"deferRendering":case"dataStructure":case"rootValue":case"createChildren":case"expandNodesRecursive":case"onItemSelectionChanged":case"onItemExpanded":case"onItemCollapsed":case"expandAllEnabled":case"animationEnabled":case"virtualModeEnabled":case"selectByClick":case"_supportItemUrl":break;case"selectionMode":this._initDataAdapter(),this.callBase(i);break;case"onSelectAllValueChanged":this._createSelectAllValueChangedAction();break;case"selectNodesRecursive":this._dataAdapter.setOption("recursiveSelection",i.value),this.repaint();break;case"expandIcon":case"collapseIcon":this.repaint();break;default:this.callBase(i)}},_initDataSource(){this._useCustomChildrenLoader()?this._loadChildrenByCustomLoader(null).done(i=>{i&&i.length&&this.option("items",i)}):(this.callBase(),this._isVirtualMode()&&this._initVirtualMode())},_initVirtualMode(){let i=this._filter;i.custom||(i.custom=this._dataSource.filter()),i.internal||(i.internal=[this.option("parentIdExpr"),this.option("rootValue")])},_useCustomChildrenLoader(){return A(this.option("createChildren"))&&this._isDataStructurePlain()},_loadChildrenByCustomLoader(i){let e=this.option("createChildren").call(this,i);return Array.isArray(e)?y().resolve(e).promise():e&&A(e.then)?ht(e):y().resolve([]).promise()},_combineFilter(){return!this._filter.custom||!this._filter.custom.length?this._filter.internal:[this._filter.custom,this._filter.internal]},_dataSourceLoadErrorHandler(){this._renderEmptyMessage()},_init(){this._filter={},this.callBase(),this._initStoreChangeHandlers()},_dataSourceChangedHandler(i){let e=this.option("items");this._initialized&&this._isVirtualMode()&&e.length||this.option("items",i)},_removeTreeViewLoadIndicator(){this._treeViewLoadIndicator&&(this._treeViewLoadIndicator.remove(),this._treeViewLoadIndicator=null)},_createTreeViewLoadIndicator(){return this._treeViewLoadIndicator=u("<div>").addClass(BX),this._createComponent(this._treeViewLoadIndicator,ni,{}),this._treeViewLoadIndicator},_dataSourceLoadingChangedHandler(i){let e;if(this._isVirtualMode()&&(e=this._combineFilter(),this._dataSource.filter(e)),i&&!this._dataSource.isLoaded()){this.option("items",[]);let t=u("<div>").addClass(VX);this._createTreeViewLoadIndicator().appendTo(t),this.itemsContainer().append(t),this._isVirtualMode()&&this._dataSource.filter()!==e&&this._dataSource.filter([])}else this._removeTreeViewLoadIndicator()},_initStoreChangeHandlers(){this.option("dataStructure")==="plain"&&this._dataSource&&this._dataSource.store().on("inserted",i=>{this.option().items=this.option("items").concat(i),this._dataAdapter.addItem(i),this._dataAdapter.isFiltered(i)&&this._updateLevel(this._parentIdGetter(i))}).on("removed",i=>{let e=this._dataAdapter.getNodeByKey(i);f(e)&&(this.option("items")[this._dataAdapter.getIndexByKey(e.internalFields.key)]=0,this._markChildrenItemsToRemove(e),this._removeItems(),this._dataAdapter.removeItem(i),this._updateLevel(this._parentIdGetter(e)))})},_markChildrenItemsToRemove(i){let e=i.internalFields.childrenKeys;x(e,(t,n)=>{this.option("items")[this._dataAdapter.getIndexByKey(n)]=0,this._markChildrenItemsToRemove(this._dataAdapter.getNodeByKey(n))})},_removeItems(){let i=m(!0,[],this.option("items")),e=0;x(i,(t,n)=>{n||(this.option("items").splice(t-e,1),e++)})},_updateLevel(i){let e=this._getContainerByParentKey(i);this._renderItems(e,this._dataAdapter.getChildrenNodes(i))},_getOldContainer(i){if(i.length)return i.children(`.${zs}`);let e=this.getScrollable();return e?u(e.content()).children():u()},_getContainerByParentKey(i){let e=this._dataAdapter.getNodeByKey(i),t=e?this._getNodeElement(e):[];this._getOldContainer(t).remove();let n=this._renderNodeContainer(t);if(this._isRootLevel(i)){let o=this.getScrollable();o||this._renderScrollableContainer(),u(o.content()).append(n)}return n},_isRootLevel(i){return i===this.option("rootValue")},_getAccessors(){let i=this.callBase();return i.push("hasItems"),i},_getDataAdapterOptions(){var i,e;return{rootValue:this.option("rootValue"),multipleSelection:!this._isSingleSelection(),recursiveSelection:this._isRecursiveSelection(),recursiveExpansion:this.option("expandNodesRecursive"),selectionRequired:this.option("selectionRequired"),dataType:this.option("dataStructure"),sort:this._dataSource&&this._dataSource.sort(),langParams:(i=this._dataSource)===null||i===void 0||(e=i.loadOptions)===null||e===void 0||(e=e.call(i))===null||e===void 0?void 0:e.langParams}},_initMarkup(){this._renderScrollableContainer(),this._renderEmptyMessage(this._dataAdapter.getRootNodes()),this.callBase(),this._setAriaRole()},_setAriaRole(){let{items:i}=this.option();i!=null&&i.length&&this.setAria({role:"tree"})},_renderContentImpl(){let i=this._renderNodeContainer();u(this.getScrollable().content()).append(i),!(!this.option("items")||!this.option("items").length)&&(this._renderItems(i,this._dataAdapter.getRootNodes()),this._attachExpandEvent(),this._selectAllEnabled()&&(this._createSelectAllValueChangedAction(),this._renderSelectAllItem(i)))},_isVirtualMode(){return this.option("virtualModeEnabled")&&this._isDataStructurePlain()&&!!this.option("dataSource")},_isDataStructurePlain(){return this.option("dataStructure")==="plain"},_fireContentReadyAction(){let i=this.getDataSource(),e=i&&!i.isLoaded()||this._skipContentReadyAndItemExpanded,t=this.getScrollable();t&&W()&&t.update(),e||this.callBase(),t&&W()&&t.update()},_renderScrollableContainer(){this._scrollable=this._createComponent(u("<div>").appendTo(this.$element()),Pi,{useNative:this.option("useNativeScrolling"),direction:this.option("scrollDirection"),useKeyboard:!1})},_renderNodeContainer(i){let e=u("<ul>").addClass(zs);if(this.setAria("role","group",e),i&&i.length){let t=this._getItemData(i.children(`.${$i}`));this._expandedGetter(t)&&e.addClass(kr),e.appendTo(i)}return e},_createDOMElement(i,e){var t;let n=u("<li>").addClass(dn).attr(om,this._encodeString(e.internalFields.key)).prependTo(i),o={role:"treeitem",label:this._displayGetter(e.internalFields.item)||"",level:this._getLevel(i)};return!!(e!=null&&(t=e.internalFields)!==null&&t!==void 0&&(t=t.childrenKeys)!==null&&t!==void 0&&t.length)&&(o.expanded=e.internalFields.expanded||!1),this.setAria(o,n),n},_getLevel(i){let e=i.parent();return e.hasClass("dx-scrollable-content")?1:parseInt(e.attr("aria-level"))+1},_showCheckboxes(){return this.option("showCheckBoxesMode")!=="none"},_hasCustomExpanderIcons(){return this.option("expandIcon")||this.option("collapseIcon")},_selectAllEnabled(i){return(i??this.option("showCheckBoxesMode"))==="selectAll"&&!this._isSingleSelection()},_renderItems(i,e){let t=e.length-1;for(let n=t;n>=0;n--)this._renderItem(n,e[n],i);this._renderedItemsCount+=e.length},_renderItem(i,e,t){let n=this._createDOMElement(t,e),o=e.internalFields,s=this._showCheckboxes();n.addClass(s?MX:PX),n.toggleClass("dx-state-invisible",o.item.visible===!1),this._hasCustomExpanderIcons()&&(n.addClass(RX),t.addClass(FX)),this.setAria("selected",o.selected,n),this._toggleSelectedClass(n,o.selected),o.disabled&&this.setAria("disabled",o.disabled,n),this.callBase(this._renderedItemsCount+i,o.item,n),this._getNode(e.internalFields.parentKey)||n.addClass(LX),o.item.visible!==!1&&this._renderChildren(n,e)},_setAriaSelectionAttribute:S,_renderChildren(i,e){if(!this._hasChildren(e)){this._addLeafClass(i),u("<div>").addClass(NX).appendTo(this._getItem(i));return}this._hasCustomExpanderIcons()?this._renderCustomExpanderIcons(i,e):this._renderDefaultExpanderIcons(i,e),this._shouldRenderSublevel(e.internalFields.expanded)&&this._loadSublevel(e).done(t=>{this._renderSublevel(i,this._getActualNode(e),t)})},_shouldRenderSublevel(i){return i||!this.option("deferRendering")},_getActualNode(i){return this._dataAdapter.getNodeByKey(i.internalFields.key)},_hasChildren(i){return this._isVirtualMode()||this._useCustomChildrenLoader()?this._hasItemsGetter(i.internalFields.item)!==!1:this.callBase(i)},_loadSublevel(i){let e=y(),t=this._getChildNodes(i);return t.length?e.resolve(t):this._loadNestedItems(i).done(n=>{e.resolve(this._dataAdapter.getNodesByItems(n))}),e.promise()},_getItemExtraPropNames:()=>["url","linkAttr"],_addContent(i,e){let{html:t,url:n}=e;if(this.option("_supportItemUrl")&&n){i.html(t);let o=this._getLinkContainer(this._getIconContainer(e),this._getTextContainer(e),e);i.append(o)}else this.callBase(i,e)},_postprocessRenderItem(i){let{itemData:e,itemElement:t}=i;this._showCheckboxes()&&this._renderCheckBox(t,this._getNode(e)),this.callBase(i)},_renderSublevel(i,e,t){let n=this._renderNodeContainer(i,e),o=t.filter(s=>e.internalFields.childrenKeys.indexOf(s.internalFields.key)!==-1);if(this._renderItems(n,o),o.length&&!e.internalFields.selected){let s=o[0];this._updateParentsState(s,this._getNodeElement(s))}this._normalizeIconState(i,o.length),e.internalFields.expanded&&n.addClass(kr)},_executeItemRenderAction(i,e,t){let n=this._getNode(t);this._getItemRenderAction()({itemElement:t,itemIndex:i,itemData:e,node:this._dataAdapter.getPublicNode(n)})},_addLeafClass(i){i.addClass(hu)},_expandEventHandler(i){u(i.currentTarget.parentNode).hasClass(hu)||this._toggleExpandedState(i.currentTarget,void 0,i)},_attachExpandEvent(){let i=this._getEventNameByOption(this.option("expandEvent")),e=this._itemContainer();this._detachExpandEvent(e),_.on(e,i,this._itemSelector(),this._expandEventHandler.bind(this))},_detachExpandEvent(i){_.off(i,".dxTreeView_expand",this._itemSelector())},_getEventNameByOption(i){return D(i==="click"?oe:Hs,"dxTreeView_expand")},_getNode(i){if(!f(i))return null;if(i.internalFields)return i;if(Zs(i))return this._dataAdapter.getNodeByKey(i);let e=u(i).get(0);return e?w.isElementNode(e)?this._getNodeByElement(e):this._dataAdapter.getNodeByItem(e):null},_getNodeByElement(i){let e=u(i).closest(`.${dn}`),t=this._decodeString(e.attr(om));return this._dataAdapter.getNodeByKey(t)},_toggleExpandedState(i,e,t){let n=this._getNode(i);if(!n)return y().reject().promise();if(n.internalFields.disabled)return y().reject().promise();let o=n.internalFields.expanded;if(o===e)return y().resolve().promise();if(this._hasChildren(n)){let s=this._getNodeElement(n);if(s.find(`.${Oy}:not(.dx-state-invisible)`).length)return y().reject().promise();!o&&!this._nodeHasRenderedChildren(s)&&this._createLoadIndicator(s)}return f(e)||(e=!o),this._dataAdapter.toggleExpansion(n.internalFields.key,e),this._updateExpandedItemsUI(n,e,t)},_nodeHasRenderedChildren(i){return i.children(`.${zs}`).not(":empty").length},_getItem:i=>i.children(`.${$i}`).eq(0),_createLoadIndicator(i){let e=this._getItem(i);this._createComponent(u("<div>").addClass(Oy),ni,{}).$element().appendTo(e),e.children(`.${pu},.${Ey}`).hide()},_renderExpanderIcon(i,e,t,n){t.appendTo(this._getItem(i)),t.addClass(n),e.internalFields.disabled&&t.addClass("dx-state-disabled"),this._renderToggleItemVisibilityIconClick(t,e)},_renderDefaultExpanderIcons(i,e){let t=this._getItem(i),n=u("<div>").addClass(pu).appendTo(t);e.internalFields.expanded&&(n.addClass(wk),i.parent().addClass(kr)),e.internalFields.disabled&&n.addClass("dx-state-disabled"),this._renderToggleItemVisibilityIconClick(n,e)},_renderCustomExpanderIcons(i,e){let{expandIcon:t,collapseIcon:n}=this.option(),o=ci(t??n),s=ci(n??t);this._renderExpanderIcon(i,e,o,Ey),this._renderExpanderIcon(i,e,s,Sy);let r=e.internalFields.expanded;r&&i.parent().addClass(kr),this._toggleCustomExpanderIcons(o,s,r)},_renderToggleItemVisibilityIconClick(i,e){let t=D(oe,this.NAME);_.off(i,t),_.on(i,t,n=>(this._toggleExpandedState(e.internalFields.key,void 0,n),!1))},_toggleCustomExpanderIcons(i,e,t){e.toggle(t),i.toggle(!t)},_updateExpandedItemsUI(i,e,t){let n=this._getNodeElement(i),o=!n.length||e&&n.is(":hidden");if(this.option("expandNodesRecursive")&&o){let l=this._getNode(i.internalFields.parentKey);l&&this._updateExpandedItemsUI(l,e,t)}if(!this._hasCustomExpanderIcons())this._getItem(n).children(`.${pu}`).toggleClass(wk,e);else if(this._nodeHasRenderedChildren(n)){let l=this._getItem(n),d=l.children(`.${Ey}`),c=l.children(`.${Sy}`);this._toggleCustomExpanderIcons(d,c,e)}let s=n.children(`.${zs}`),r=s.length>0,a=y();return!e||r&&!s.is(":empty")?(this._animateNodeContainer(i,e,t,a),a.promise()):i.internalFields.childrenKeys.length===0&&(this._isVirtualMode()||this._useCustomChildrenLoader())?(this._loadNestedItemsWithUpdate(i,e,t,a),a.promise()):(this._renderSublevel(n,i,this._getChildNodes(i)),this._fireContentReadyAction(),this._animateNodeContainer(i,e,t,a),a.promise())},_loadNestedItemsWithUpdate(i,e,t,n){let o=this._getNodeElement(i);this._loadNestedItems(i).done(s=>{let r=this._getActualNode(i);if(this._renderSublevel(o,r,this._dataAdapter.getNodesByItems(s)),!s||!s.length){n.resolve();return}this._fireContentReadyAction(),this._animateNodeContainer(r,e,t,n)})},_loadNestedItems(i){if(this._useCustomChildrenLoader()){let e=this._dataAdapter.getPublicNode(i);return this._loadChildrenByCustomLoader(e).done(t=>{this._areNodesExists(t)||this._appendItems(t)})}return this._isVirtualMode()?(this._filter.internal=[this.option("parentIdExpr"),i.internalFields.key],this._dataSource.filter(this._combineFilter()),this._dataSource.load().done(e=>{this._areNodesExists(e)||this._appendItems(e)})):y().resolve([]).promise()},_areNodesExists(i,e){let t=this.keyOf(i[0]),n=this._dataAdapter.getFullData();return!!this._dataAdapter.getNodeByKey(t,n)},_appendItems(i){this.option().items=this.option("items").concat(i),this._initDataAdapter()},_animateNodeContainer(i,e,t,n){let o=this._getNodeElement(i),s=o.children(`.${zs}`);i&&n&&s.length===0&&n.resolve(),s.addClass(kr);let r=Y(s);pe.stop(s,!0),pe.animate(s,{type:"custom",duration:this.option("animationEnabled")?400:0,from:{maxHeight:e?0:r},to:{maxHeight:e?r:0},complete:function(){s.css("maxHeight","none"),s.toggleClass(kr,e),this.setAria("expanded",e,o),this.getScrollable().update(),this._fireExpandedStateUpdatedEvent(e,i,t),n&&n.resolve()}.bind(this)})},_fireExpandedStateUpdatedEvent(i,e,t){if(!this._hasChildren(e)||this._skipContentReadyAndItemExpanded)return;let n=i?"onItemExpanded":"onItemCollapsed";if(f(t))this._itemDXEventHandler(t,n,{node:this._dataAdapter.getPublicNode(e)});else{let o=this._getNodeElement(e);this._itemEventHandler(o,n,{event:t,node:this._dataAdapter.getPublicNode(e)})}},_normalizeIconState(i,e){let t=i.find(`.${Oy}`);if(t.length){var n;(n=ni.getInstance(t))===null||n===void 0||n.option("visible",!1)}let s=this._getItem(i).children(`.${Sy},.${pu}`);if(e){s.show();return}s.removeClass(pu),i.addClass(hu)},_emptyMessageContainer(){let i=this.getScrollable();return i?u(i.content()):this.callBase()},_renderContent(){let i=this.option("items");i&&i.length&&(this._contentAlreadyRendered=!0),this.callBase()},_renderSelectAllItem(i){let{selectAllText:e,focusStateEnabled:t}=this.option();i=i||this.$element().find(`.${zs}`).first(),this._$selectAllItem=u("<div>").addClass(nm);let n=this._dataAdapter.isAllSelected();this._createComponent(this._$selectAllItem,Er,{value:n,elementAttr:{"aria-label":"Select All"},text:e,focusStateEnabled:t,onValueChanged:this._onSelectAllCheckboxValueChanged.bind(this),onInitialized:o=>{let{component:s}=o;s.registerKeyHandler("enter",()=>{s.option("value",!s.option("value"))})}}),this._toggleSelectedClass(this._$selectAllItem,n),i.before(this._$selectAllItem)},_onSelectAllCheckboxValueChanged(i){this._toggleSelectAll(i),this._fireSelectAllValueChanged(i.value)},_toggleSelectAll(i){this._dataAdapter.toggleSelectAll(i.value),this._updateItemsUI(),this._fireSelectionChanged()},_renderCheckBox(i,e){let t=u("<div>").appendTo(i);this._createComponent(t,Er,{value:e.internalFields.selected,onValueChanged:this._changeCheckboxValue.bind(this),focusStateEnabled:!1,elementAttr:{"aria-label":O.format("CheckState")},disabled:this._disabledGetter(e)})},_toggleSelectedClass(i,e){i.toggleClass("dx-state-selected",!!e)},_toggleNodeDisabledState(i,e){let t=this._getNodeElement(i),n=t.find(`.${$i}`).eq(0);this._dataAdapter.toggleNodeDisabledState(i.internalFields.key,e),n.toggleClass("dx-state-disabled",!!e),this._showCheckboxes()&&this._getCheckBoxInstance(t).option("disabled",!!e)},_itemOptionChanged(i,e,t){let n=this._dataAdapter.getNodeByItem(i);e===this.option("disabledExpr")&&this._toggleNodeDisabledState(n,t)},_changeCheckboxValue(i){let e=u(i.element).closest(`.${dn}`),t=this._getItem(e),n=this._getItemData(t),o=this._getNodeByElement(t),{value:s}=i;o&&o.internalFields.selected===s||this._updateItemSelection(s,n,i.event)},_isSingleSelection(){return this.option("selectionMode")==="single"},_isRecursiveSelection(){return this.option("selectNodesRecursive")&&this.option("selectionMode")!=="single"},_isLastSelectedBranch(i,e,t){let n=e.indexOf(i.key);return n>=0&&e.splice(n,1),t&&x(i.children,(o,s)=>{this._isLastSelectedBranch(s,e,!0)}),i.parent&&this._isLastSelectedBranch(i.parent,e),e.length===0},_isLastRequired(i){let e=this.option("selectionRequired"),t=this._isSingleSelection(),n=this.getSelectedNodeKeys();if(e)return t?n.length===1:this._isLastSelectedBranch(i.internalFields.publicNode,n.slice(),!0)},_updateItemSelection(i,e,t){let n=this._getNode(e);if(!n||n.visible===!1)return!1;if(n.internalFields.selected===i)return!0;if(!i&&this._isLastRequired(n)){if(this._showCheckboxes()){let r=this._getNodeElement(n);this._getCheckBoxInstance(r).option("value",!0)}return!1}if(i&&this._isSingleSelection()){let r=this.getSelectedNodeKeys();x(r,(a,l)=>{this._dataAdapter.toggleSelection(l,!1),this._updateItemsUI(),this._fireItemSelectionChanged(this._getNode(l))})}this._dataAdapter.toggleSelection(n.internalFields.key,i);let o=this._dataAdapter.isAllSelected(),s=this._selectAllEnabled()&&this._$selectAllItem.dxCheckBox("instance").option("value")!==o;return this._updateItemsUI(),this._fireItemSelectionChanged(n,t),this._fireSelectionChanged(),s&&this._fireSelectAllValueChanged(o),!0},_fireItemSelectionChanged(i,e){let t=e||this._findItemElementByItem(i.internalFields.item);(e?this._itemDXEventHandler:this._itemEventHandler).call(this,t,"onItemSelectionChanged",{node:this._dataAdapter.getPublicNode(i),itemData:i.internalFields.item})},_getCheckBoxInstance(i){return this._getItem(i).children(".dx-checkbox").dxCheckBox("instance")},_updateItemsUI(){let i={};if(x(this._dataAdapter.getData(),(e,t)=>{let n=this._getNodeElement(t,i),o=t.internalFields.selected;n.length&&(this._toggleSelectedClass(n,o),this.setAria("selected",o,n),this._showCheckboxes()&&this._getCheckBoxInstance(n).option("value",o))}),this._selectAllEnabled()){let e=this._$selectAllItem.dxCheckBox("instance");e.option("onValueChanged",void 0),e.option("value",this._dataAdapter.isAllSelected()),e.option("onValueChanged",this._onSelectAllCheckboxValueChanged.bind(this))}},_updateParentsState(i,e){if(!e)return;let t=this._dataAdapter.getNodeByKey(i.internalFields.parentKey),n=u(e.parents(`.${dn}`)[0]);if(this._showCheckboxes()){let o=t.internalFields.selected;this._getCheckBoxInstance(n).option("value",o),this._toggleSelectedClass(n,o)}t.internalFields.parentKey!==this.option("rootValue")&&this._updateParentsState(t,n)},_itemEventHandlerImpl(i,e,t){let n=u(i).closest(`.${dn}`).children(`.${$i}`);return e(m(this._extendActionArgs(n),t))},_itemContextMenuHandler(i){this._createEventHandler("onItemContextMenu",i)},_itemHoldHandler(i){this._createEventHandler("onItemHold",i)},_createEventHandler(i,e){let t=this._getNodeByElement(e.currentTarget);this._itemDXEventHandler(e,i,{node:this._dataAdapter.getPublicNode(t)})},_itemClass:()=>$i,_itemDataKey:()=>kX,_attachClickEvent(){let i=this._itemContainer();this._detachClickEvent(i);let{clickEventNamespace:e,itemSelector:t,pointerDownEventNamespace:n,nodeSelector:o}=this._getItemClickEventData();_.on(i,e,t,s=>{u(s.target).hasClass("dx-checkbox-icon")||u(s.target).hasClass("dx-checkbox")||this._itemClickHandler(s,u(s.currentTarget))}),_.on(i,n,o,s=>{this._itemPointerDownHandler(s)})},_detachClickEvent(i){let{clickEventNamespace:e,itemSelector:t,pointerDownEventNamespace:n,nodeSelector:o}=this._getItemClickEventData();_.off(i,e,t),_.off(i,n,o)},_getItemClickEventData(){let i=`.${this._itemClass()}`,e=`.${dn}, .${nm}`,t=D(oe,this.NAME),n=D(ne.down,this.NAME);return{clickEventNamespace:t,itemSelector:i,pointerDownEventNamespace:n,nodeSelector:e}},_itemClick(i){let e=i.args[0],n=(e.event.target[0]||e.event.target).getElementsByClassName("dx-item-url")[0];e.itemData.url&&n&&n.click()},_itemClickHandler(i,e){let t=this._getItemData(e),n=this._getNodeByElement(e);this._itemDXEventHandler(i,"onItemClick",{node:this._dataAdapter.getPublicNode(n)},{beforeExecute:this._itemClick}),this.option("selectByClick")&&!i.isDefaultPrevented()&&this._updateItemSelection(!n.internalFields.selected,t,i)},_updateSelectionToFirstItem(i,e){let t=e;for(;t>=0;){let n=u(i[t]);this._updateItemSelection(!0,n.find(`.${$i}`).get(0)),t--}},_updateSelectionToLastItem(i,e){let{length:t}=i,n=e;for(;n<t;){let o=u(i[n]);this._updateItemSelection(!0,o.find(`.${$i}`).get(0)),n++}},focus(){if(this._selectAllEnabled()){_.trigger(this._$selectAllItem,"focus");return}this.callBase()},_focusInHandler(i){this._updateFocusState(i,!0);let e=u(i.target).hasClass(nm);if(e||this.option("focusedElement")){clearTimeout(this._setFocusedItemTimeout),this._setFocusedItemTimeout=setTimeout(()=>{let n=e?N(this._$selectAllItem):u(this.option("focusedElement"));this._setFocusedItem(n)});return}let t=this._getActiveItem();this.option("focusedElement",N(t.closest(`.${dn}`)))},_itemPointerDownHandler(i){if(!this.option("focusStateEnabled"))return;let e=u(i.target).closest(`.${dn}, .${nm}`);if(!e.length)return;let t=e.hasClass("dx-state-disabled")?null:e;this.option("focusedElement",N(t))},_findNonDisabledNodes:i=>i.not(function(){return u(this).children(`.${$i}`).hasClass("dx-state-disabled")}),_moveFocus(i,e){let t=this.option("rtlEnabled")?"right":"left",n=this.option("rtlEnabled")?"left":"right";this.$element().find(`.${zs}`).each(function(){pe.stop(this,!0)});let o=this._nodeElements();if(!(!o||!o.length))switch(i){case"up":{let s=this._prevItem(o);this.option("focusedElement",N(s));let r=this._getNodeItemElement(s);this.getScrollable().scrollToElement(r),e.shiftKey&&this._showCheckboxes()&&this._updateItemSelection(!0,r);break}case"down":{let s=this._nextItem(o);this.option("focusedElement",N(s));let r=this._getNodeItemElement(s);this.getScrollable().scrollToElement(r),e.shiftKey&&this._showCheckboxes()&&this._updateItemSelection(!0,r);break}case"first":{let s=o.first();e.shiftKey&&this._showCheckboxes()&&this._updateSelectionToFirstItem(o,o.index(this._prevItem(o))),this.option("focusedElement",N(s)),this.getScrollable().scrollToElement(this._getNodeItemElement(s));break}case"last":{let s=o.last();e.shiftKey&&this._showCheckboxes()&&this._updateSelectionToLastItem(o,o.index(this._nextItem(o))),this.option("focusedElement",N(s)),this.getScrollable().scrollToElement(this._getNodeItemElement(s));break}case n:this._expandFocusedContainer();break;case t:this._collapseFocusedContainer();break;default:this.callBase.apply(this,arguments)}},_getNodeItemElement:i=>i.find(`.${$i}`).get(0),_nodeElements(){return this.$element().find(`.${dn}`).not(":hidden")},_expandFocusedContainer(){let i=u(this.option("focusedElement"));if(!i.length||i.hasClass(hu))return;if(i.find(`.${zs}`).eq(0).hasClass(kr)){let n=this._nextItem(this._findNonDisabledNodes(this._nodeElements()));this.option("focusedElement",N(n)),this.getScrollable().scrollToElement(this._getNodeItemElement(n));return}let t=this._getNodeByElement(this._getItem(i));this._toggleExpandedState(t,!0)},_getClosestNonDisabledNode(i){do i=i.parent().closest(`.${dn}`);while(i.children(".dx-treeview-item.dx-state-disabled").length);return i},_collapseFocusedContainer(){let i=u(this.option("focusedElement"));if(!i.length)return;let e=i.find(`.${zs}`).eq(0);if(!i.hasClass(hu)&&e.hasClass(kr)){let t=this._getNodeByElement(this._getItem(i));this._toggleExpandedState(t,!1)}else{let t=this._getClosestNonDisabledNode(i);t.length&&this.option("focusedElement",N(t)),this.getScrollable().scrollToElement(this._getNodeItemElement(t))}},_encodeString:i=>B(i)?encodeURI(i):i,_decodeString:i=>B(i)?decodeURI(i):i,getScrollable(){return this._scrollable},updateDimensions(){let i=y(),e=this.getScrollable();return e?e.update().done(()=>{i.resolveWith(this)}):i.resolveWith(this),i.promise()},selectItem(i){return this._updateItemSelection(!0,i)},unselectItem(i){return this._updateItemSelection(!1,i)},expandItem(i){return this._toggleExpandedState(i,!0)},collapseItem(i){return this._toggleExpandedState(i,!1)},getNodes(){return this._dataAdapter.getTreeNodes()},getSelectedNodes(){return this.getSelectedNodeKeys().map(i=>{let e=this._dataAdapter.getNodeByKey(i);return this._dataAdapter.getPublicNode(e)})},getSelectedNodeKeys(){return this._dataAdapter.getSelectedNodesKeys()},selectAll(){this._selectAllEnabled()?this._$selectAllItem.dxCheckBox("instance").option("value",!0):this._toggleSelectAll({value:!0})},unselectAll(){this._selectAllEnabled()?this._$selectAllItem.dxCheckBox("instance").option("value",!1):this._toggleSelectAll({value:!1})},_allItemsExpandedHandler(){this._skipContentReadyAndItemExpanded=!1,this._fireContentReadyAction()},expandAll(){let i=this._dataAdapter.getData(),e=[];this._skipContentReadyAndItemExpanded=!0,i.forEach(t=>e.push(this._toggleExpandedState(t.internalFields.key,!0))),Promise.allSettled(e).then(()=>{var t;return(t=this._allItemsExpandedHandler)===null||t===void 0?void 0:t.call(this)})},collapseAll(){x(this._dataAdapter.getExpandedNodesKeys(),(i,e)=>{this._toggleExpandedState(e,!1)})},scrollToItem(i){let e=this._getNode(i);if(!e)return y().reject().promise();let t=[],n=e.internalFields.publicNode.parent;for(;n!=null;)n.expanded||t.push(n.key),n=n.parent;let o=y();return this._expandNodes(t.reverse()).always(()=>{let s=this._getNodeElement(e);s&&s.length?(this.scrollToElementTopLeft(s.get(0)),o.resolve()):o.reject()}),o.promise()},scrollToElementTopLeft(i){let e=this.getScrollable(),{scrollDirection:t,rtlEnabled:n}=this.option(),o={top:0,left:0},s=zp(Kp,i);if(t!==pa){let r=u(e.container()).get(0);o.left=n?s.left+i.offsetWidth-r.clientWidth:s.left}t!==Wp&&(o.top=s.top),e.scrollTo(o)},_expandNodes(i){if(!i||i.length===0)return y().resolve().promise();let e=y(),t=i.map(n=>this.expandItem(n));return P.apply(u,t).done(()=>e.resolve()).fail(()=>e.reject()),e.promise()},_dispose(){this.callBase(),clearTimeout(this._setFocusedItemTimeout),this._allItemsExpandedHandler=null}}),Ik=HX;bo.setEditorClass(Xn);var Dk="dx-treeview",$X=`${Dk}-node-container`,Tk=Ik.inherit(bo).inherit({_addWidgetPrefix:i=>`${Dk}-${i}`,_optionChanged(i){switch(i.name){case"searchValue":this._showCheckboxes()&&this._isRecursiveSelection()&&this._removeSelection(),this._initDataAdapter(),this._updateSearch(),this._repaintContainer(),this.option("focusedElement",null);break;case"searchExpr":this._initDataAdapter(),this.repaint();break;case"searchMode":this.option("expandNodesRecursive")?this._updateDataAdapter():this._initDataAdapter(),this.repaint();break;default:this.callBase(i)}},_updateDataAdapter(){this._setOptionWithoutOptionChange("expandNodesRecursive",!1),this._initDataAdapter(),this._setOptionWithoutOptionChange("expandNodesRecursive",!0)},_getDataAdapterOptions(){return m(this.callBase(),{searchValue:this.option("searchValue"),searchMode:this.option("searchMode")||"contains",searchExpr:this.option("searchExpr")})},_getNodeContainer(){return this.$element().find(`.${$X}`).first()},_updateSearch(){if(this._searchEditor){let i=this._getSearchEditorOptions();this._searchEditor.option(i)}},_repaintContainer(){let i=this._getNodeContainer(),e;i.length&&(i.empty(),e=this._dataAdapter.getRootNodes(),this._renderEmptyMessage(e),this._renderItems(i,e),this._fireContentReadyAction())},_focusTarget(){return this._itemContainer(this.option("searchEnabled"))},_cleanItemContainer(){this.$element().empty()},_itemContainer(i,e){return e??(e=this._selectAllEnabled()),e?this._getNodeContainer():this._scrollable&&i?u(this._scrollable.content()):this.callBase()},_addWidgetClass(){this.$element().addClass(this._widgetClass())},_clean(){this.callBase(),this._removeSearchBox()}});G("dxTreeView",Tk);var Ak=Tk;var es=Ak;var zX="column-chooser-mode-drag",WX="column-chooser-mode-select";var GX=["showInColumnChooser","caption","allowHiding","visible","cssClass","ownerBand"],KX=function(i,e){let t=[],n=i.isSelectMode(),o=i.option("columnChooser.selection.recursive");return e.length&&x(e,(s,r)=>{let a={text:r.caption,cssClass:r.cssClass,allowHiding:r.allowHiding,expanded:!0,id:r.index,disabled:r.allowHiding===!1,parentId:f(r.ownerBand)?r.ownerBand:null},l=o&&r.hasColumns;n&&!l&&(a.selected=r.visible),t.push(a)}),t},wy=class extends Ce.ViewController{init(){super.init(),this._rowsView=this.getView("rowsView")}renderShowColumnChooserButton(e){let t=this,n=t.addWidgetPrefix("column-chooser-button"),o=t.option("columnChooser.enabled"),s=e.find(`.${n}`),r;o?s.length?s.show():(r=u("<div>").addClass(n).appendTo(e),t._createComponent(r,rt,{icon:"column-chooser",onClick(){t.getView("columnChooserView").showColumnChooser()},hint:t.option("columnChooser.title"),integrationOptions:{}})):s.hide()}getPosition(){let e=this.option("columnChooser.position");return f(e)?e:{my:"right bottom",at:"right bottom",of:this._rowsView&&this._rowsView.element(),collision:"fit",offset:"-2 -2",boundaryOffset:"2 2"}}},Iy=class extends eo{optionChanged(e){e.name==="columnChooser"?(this._initializePopupContainer(),this.render(null,"full")):super.optionChanged(e)}publicMethods(){return["showColumnChooser","hideColumnChooser"]}_resizeCore(){}_isWinDevice(){return!!F.real().win}_initializePopupContainer(){let e=this,t=e.addWidgetPrefix("column-chooser"),n=e.element().addClass(t),o=e.option("columnChooser"),s=this._columnChooserController.getPosition(),r=ct(),a=sp(r),l=it(r),d={visible:!1,shading:!1,showCloseButton:!1,dragEnabled:!0,resizeEnabled:!0,wrapperAttr:{class:t},toolbarItems:[{text:o.title,toolbar:"top",location:a||l?"before":"center"}],position:s,width:o.width,height:o.height,rtlEnabled:e.option("rtlEnabled"),onHidden(){e._isWinDevice()&&u("body").removeClass(e.addWidgetPrefix("notouch-action"))},container:o.container};a||l?m(d,{showCloseButton:!0}):d.toolbarItems[d.toolbarItems.length]={shortcut:"cancel"},f(this._popupContainer)?this._popupContainer.option(d):(e._popupContainer=e._createComponent(n,ii,d),e._popupContainer.on("optionChanged",c=>{c.name==="visible"&&e.renderCompleted.fire()})),this.setPopupAttributes()}setPopupAttributes(){let e=this.isSelectMode(),t=this._columnsController.isBandColumnsUsed();this._popupContainer.setAria({role:"dialog",label:O.format("dxDataGrid-columnChooserTitle")}),this._popupContainer.$wrapper().toggleClass(this.addWidgetPrefix(zX),!e).toggleClass(this.addWidgetPrefix(WX),e),this._popupContainer.$content().addClass(this.addWidgetPrefix("column-chooser-list")),e&&!t&&this._popupContainer.$content().addClass(this.addWidgetPrefix("column-chooser-plain"))}_renderCore(e){if(this._popupContainer){let t=!this.isSelectMode();!this._columnChooserList||e==="full"?this._renderTreeView():t&&this._updateItems()}}_renderTreeView(){var e,t,n;let o=this,s=this._popupContainer.$content(),r=this.option("columnChooser"),a=this.isSelectMode(),l=f(r.allowSearch)?r.allowSearch:(e=r.search)===null||e===void 0?void 0:e.enabled,d=f(r.searchTimeout)?r.searchTimeout:(t=r.search)===null||t===void 0?void 0:t.timeout,c={dataStructure:"plain",activeStateEnabled:!0,focusStateEnabled:!0,hoverStateEnabled:!0,itemTemplate:"item",showCheckBoxesMode:"none",rootValue:null,searchEnabled:l,searchTimeout:d,searchEditorOptions:(n=r.search)===null||n===void 0?void 0:n.editorOptions};if(this._isWinDevice()&&(c.useNativeScrolling=!1),m(c,a?this._prepareSelectModeConfig():this._prepareDragModeConfig()),this._columnChooserList)c.searchEnabled||(c.searchValue=""),this._columnChooserList.option(c),this._updateItems();else{this._columnChooserList=this._createComponent(s,es,c),this._updateItems();let h=0;this._columnChooserList.on("optionChanged",p=>{h=p.component.getScrollable().scrollTop()}),this._columnChooserList.on("contentReady",p=>{Jt(()=>{p.component.getScrollable().scrollTo({y:h}),o.renderCompleted.fire()})})}}_prepareDragModeConfig(){return{noDataText:this.option("columnChooser").emptyPanelText,activeStateEnabled:!1,hoverStateEnabled:!1,itemTemplate(t,n,o){u(o).text(t.text).parent().addClass(t.cssClass).addClass("dx-column-chooser-item")}}}_prepareSelectModeConfig(){let e=this,t=this.option("columnChooser.selection")??{},n=!1;return{selectByClick:t.selectByClick,selectNodesRecursive:t.recursive,showCheckBoxesMode:t.allowSelectAll?"selectAll":"normal",onSelectionChanged:o=>{if(n)return;let s=(r=>{let a=(l,d)=>l.reduce((c,h)=>(c.push(h),h.children.length&&a(h.children,c),c),d);return a(r,[])})(o.component.getNodes());o.component.beginUpdate(),n=!0,((r,a)=>{a.filter(l=>l.itemData.allowHiding===!1).forEach(l=>r.component.selectItem(l.key))})(o,s),o.component.endUpdate(),n=!1,e.component.beginUpdate(),this._isUpdatingColumnVisibility=!0,(r=>{r.forEach(a=>{let l=a.itemData.id,d=a.selected!==!1;e._columnsController.columnOption(l,"visible",d)})})(s),e.component.endUpdate(),this._isUpdatingColumnVisibility=!1}}}_updateItems(){let e=this.isSelectMode(),t=this._columnsController.getChooserColumns(e),n=KX(this,t);this._columnChooserList.option("items",n)}_updateItemsSelection(e){let t=e?.map(n=>this._columnsController.columnOption(n));this._columnChooserList.beginUpdate(),t?.forEach(n=>{let{visible:o,index:s}=n;o?this._columnChooserList.selectItem(s):this._columnChooserList.unselectItem(s)}),this._columnChooserList.endUpdate()}_columnOptionChanged(e){if(super._columnOptionChanged(e),this.isSelectMode()&&this._columnChooserList&&!this._isUpdatingColumnVisibility){let{optionNames:n}=e,o=n.visible&&n.length===1,s=f(e.columnIndex)?[e.columnIndex]:e.columnIndices;(GX.some(a=>n[a])||e.changeTypes.columns&&n.all)&&(this._updateItemsSelection(s),o||this._updateItems())}}getColumnElements(){let e=[],t=this.isSelectMode(),n=this._columnsController.getChooserColumns(t),o=this._popupContainer&&this._popupContainer.$content(),s=o&&o.find(".dx-treeview-node");return s&&n.forEach(r=>{let a=s.filter(`[data-item-id = '${r.index}']`),l=a.length?a.children(".dx-column-chooser-item").get(0):null;e.push(l)}),u(e)}getName(){return"columnChooser"}getColumns(){return this._columnsController.getChooserColumns()}allowDragging(e){let t=this._columnsController.isParentColumnVisible(e.index),n=!e.visible&&e.allowHiding;return this.isColumnChooserVisible()&&t&&n}allowColumnHeaderDragging(e){return!this.isSelectMode()&&this.isColumnChooserVisible()&&e.allowHiding}getBoundingRect(){let e=this._popupContainer&&this._popupContainer.$overlayContent();if(e&&e.is(":visible")){let t=e.offset();return{left:t.left,top:t.top,right:t.left+ie(e),bottom:t.top+X(e)}}return null}showColumnChooser(){this._popupContainer||(this._initializePopupContainer(),this.render()),this._popupContainer.show(),this._isWinDevice()&&u("body").addClass(this.addWidgetPrefix("notouch-action"))}hideColumnChooser(){this._popupContainer&&this._popupContainer.hide()}isColumnChooserVisible(){let e=this._popupContainer;return e&&e.option("visible")}isSelectMode(){return this.option("columnChooser.mode")==="select"}hasHiddenColumns(){let e=this.option("columnChooser.enabled"),t=this.getColumns().filter(n=>!n.visible);return e&&t.length}},UX=i=>class extends i{_getToolbarItems(){let e=super._getToolbarItems();return this._appendColumnChooserItem(e)}_appendColumnChooserItem(e){let t=this;if(t.option("columnChooser.enabled")){let o=function(){t.component.getView("columnChooserView").showColumnChooser()},s=function(l){u(l.element).addClass(t._getToolbarButtonClass(t.addWidgetPrefix("column-chooser-button")))},r=t.option("columnChooser.title"),a={widget:"dxButton",options:{icon:"column-chooser",onClick:o,hint:r,text:r,onInitialized:s,elementAttr:{"aria-haspopup":"dialog"}},showText:"inMenu",location:"after",name:"columnChooserButton",locateInMenu:"auto",sortIndex:40};e.push(a)}return e}optionChanged(e){e.name==="columnChooser"?(this._invalidate(),e.handled=!0):super.optionChanged(e)}},jX=i=>class extends i{allowMoveColumn(e,t,n,o){return this.option("columnChooser.mode")==="select"&&o==="columnChooser"?!1:super.allowMoveColumn(e,t,n,o)}},qX=i=>class extends i{allowDragging(e){let t=!this._columnChooserView.isSelectMode(),n=this._columnChooserView.isColumnChooserVisible();return t&&n&&e.allowHiding||super.allowDragging(e)}},sm={defaultOptions:()=>({columnChooser:{enabled:!1,search:{enabled:!1,timeout:500,editorOptions:{}},selection:{allowSelectAll:!1,selectByClick:!1,recursive:!1},position:void 0,mode:"dragAndDrop",width:250,height:260,title:O.format("dxDataGrid-columnChooserTitle"),emptyPanelText:O.format("dxDataGrid-columnChooserEmptyText"),container:void 0}}),controllers:{columnChooser:wy},views:{columnChooserView:Iy},extenders:{views:{headerPanel:UX,columnHeadersView:qX},controllers:{columns:jX}}};var SUe=sm.controllers.columnChooser,EUe=sm.views.columnChooserView;H.registerModule("columnChooser",sm);function ts(i,e){let t=rn(e.group),n=[];for(let o=0;o<i.length;o++)n.push([t[o].selector,"=",i[o]]);return e.filter&&n.push(e.filter),M.combineFilters(n)}function rm(i,e,t){let n=rn(e.group),o=[];for(let s=t?i.length-1:0;s<i.length;s++){let r=[];for(let a=0;a<=s;a++){let{selector:l}=n[a];if(s===a&&(i[a]===null||i[a]===!1||i[a]===!0))i[a]===!1?r.push([l,"=",n[a].desc?!0:null]):(i[a]?!n[a].desc:n[a].desc)?r.push([l,"<>",i[a]]):(r.push([l,"<>",null]),r.push([l,"=",null]));else{let d=[l,s===a?n[a].desc?">":"<":"=",i[a]];d[1]==="<"?r.push([d,"or",[l,"=",null]]):r.push(d)}}o.push(H.combineFilters(r))}return o=H.combineFilters(o,"or"),H.combineFilters([o,e.filter])}var Mk=function(i,e){let{hash:t}=i;return t&&t[JSON.stringify(e)]},YX=function(i,e){let t=0,n=i.length-1;if(!i.length)return 0;do{let s=n+t>>1;i[s].offset>e?n=s:t=s}while(n-t>1);let o;for(o=t;o<=n&&!(i[o].offset>e);o++);return o},Rk=function(i,e,t){for(let n=0;n<i.length;n++)e+1>=t?i[n].children=[]:Rk(i[n].children,e+1,t)},Fk=function(i,e,t){let n=0;if(e)if(!t)n=e.length;else for(let o=0;o<e.length;o++)i.isGroupItemCountable(e[o])&&n++,n+=Fk(i,e[o].items,t-1);return n},ld=class{constructor(e){this._dataSource=e,this.reset()}reset(){this._groupsInfo=[],this._totalCountCorrection=0}totalCountCorrection(){return this._totalCountCorrection}updateTotalItemsCount(e){this._totalCountCorrection=e||0}isGroupItemCountable(e){return!this._isVirtualPaging()||!e.isContinuation}_isVirtualPaging(){let e=this._dataSource.option("scrolling.mode");return e==="virtual"||e==="infinite"}itemsCount(){let t=this._dataSource._dataSource,n=H.normalizeSortingInfo(t.group()||[]).length;return Fk(this,t.items(),n)}foreachGroups(e,t,n,o,s){let r=this;return function a(l,d,c,h){let p=[];function g(v,b,T,R){let U=b&&v(b,T);return U&&R.push(U),U}for(let v=0;v<l.length;v++){if(h.push(l[v].data),!c&&g(d,l[v].data,h,p)===!1)return!1;if(!l[v].data||l[v].data.isExpanded||n){let{children:b}=l[v],T=b.length&&a(b,d,c,h);if(T&&p.push(T),T===!1)return!1}if(c&&g(d,l[v].data,h,p)===!1)return!1;(!l[v].data||l[v].data.offset!==l[v].offset)&&(o=!0),h.pop()}let C=s&&h.slice(0);return o&&P.apply(u,p).always(()=>{r._updateGroupInfoOffsets(l,C)})}(r._groupsInfo,e,t,[])}_updateGroupInfoOffsets(e,t){t=t||[];for(let n=0;n<e.length;n++){let o=e[n];if(o.data&&o.data.offset!==o.offset){o.offset=o.data.offset;for(let s=0;s<t.length;s++)t[s].offset=o.offset}}e.sort((n,o)=>n.offset-o.offset)}findGroupInfo(e){let t,n=this._groupsInfo;for(let o=0;n&&o<e.length;o++)t=Mk(n,e[o]),n=t&&t.children;return t&&t.data}addGroupInfo(e){let t=this,n,{path:o}=e,s=t._groupsInfo;for(let r=0;r<o.length;r++){if(n=Mk(s,o[r]),!n){n={key:o[r],offset:e.offset,data:{offset:e.offset,isExpanded:!0,path:o.slice(0,r+1)},children:[]};let a=YX(s,e.offset);s.splice(a,0,n),s.hash=s.hash||{},s.hash[JSON.stringify(n.key)]=n}r===o.length-1&&(n.data=e,n.offset!==e.offset&&t._updateGroupInfoOffsets(s)),s=n.children}}allowCollapseAll(){return!0}refresh(e){let t=this,{storeLoadOptions:n}=e,o=rn(n.group||[]),s="_group"in t?rn(t._group||[]):o,r=Math.min(s.length,o.length);t._group=n.group;for(let a=0;a<r;a++)if(s[a].selector!==o[a].selector){r=a;break}r?Rk(t._groupsInfo,0,r):t.reset()}handleDataLoading(){}handleDataLoaded(e,t){t(e)}handleDataLoadedCore(e,t){t(e)}};function Ay(i,e,t,n){if(n=n||0,e>1&&t>0){let o=i-Math.floor(i/e)*e||e;return o+=t-n-2,o<0&&(o+=e),Math.floor(o/(e-n-1))}return 0}var gu=function(i,e,t){return i.foreachGroups((n,o)=>{if(n.isExpanded)return e(n,o)},!0,!1,t,t)},My=function(i,e,t,n,o,s,r){let a;if(n.items=n.items||[],n.paths=n.paths||[],n.count=n.count||0,n.lastCount=n.lastCount||0,!!t)for(let l=0;l<e.length;l++){let d=e[l];if(d.items!==void 0){if(o.push(d.key),s)a=!0;else{let c=i.findGroupInfo(o);a=c&&c.isExpanded}a?d.items?My(i,d.items,t-1,n,o,s,r):t===1&&d.count&&(!s||r)&&(n.items.push(d),n.paths.push(o.slice(0)),n.count+=n.lastCount,n.lastCount=d.count):(d.collapsedItems=d.items,d.items=null),o.pop()}}},XX=function(i,e,t,n,o){let s=i.findGroupInfo(n),r;s?(t?s.count=e.count>0?e.count:e.items&&e.items.length||0:e.count=s.count||e.count,s.offset=o):(t&&(r=e.count>0?e.count:e.items.length),i.addGroupInfo({isExpanded:i._isGroupExpanded(n.length-1),path:n.slice(0),offset:o,count:r||0}))},Ry=function(i,e,t,n,o,s,r){let l=(e.group?e.group.length:0)===n,d=e.remoteOperations.paging,c=0,h=0,p;if(o=o||0,s=s||[],d&&!r&&(c=o===0?e.skip||0:e.skips[o-1]||0),o>=n)return t.length;for(let g=0;g<t.length;g++){let C=t[g];if(C){if(s.push(C.key),!C.count&&!C.items||C.items===void 0||(XX(i,C,l,s,c+g),p=C.items?Ry(i,e,C.items,n,o+1,s,g):C.count||-1,p<0))return-1;h+=p,s.pop()}}return h},Dy=function(i,e){return i&&i.length&&i[e]&&!!i[e].isExpanded},Pk=function(i,e,t){let n,o=t;for(let s=0;s<i.length;s++)n=i[s].offset+1,s>0&&(n+=i[s-1].childrenTotalCount,e&&(n+=Ay(o,e,n,s-1)*s)),o+=n;return o};function Bk(i,e,t,n){let o=e.items[n],s=i.skips&&i.skips[t],r=i.takes&&i.takes[t],a=n===e.items.length-1,l=n===0,d=l&&s||0,c=o.count>r+d;l&&s!==void 0&&(o.isContinuation=!0),a&&r!==void 0&&c&&(o.isContinuationOnNextPage=!0)}function QX(i,e,t){let n=t-1,o=i.group?i.group.length:0;e.skip=i.skips&&i.skips[n],i.takes&&i.takes[n]!==void 0&&(o===t?e.take=e.count?e.count-(e.skip||0):0:e.take=0,e.take+=i.takes[n])}function Vk(i){return!Array.isArray(i)}function kk(i){Vk(i.data)||(i.data=new y)}function Lk(i,e,t,n,o,s){e.isCustomLoading||(n={},My(i,s,t,n,[]),QX(e,n,t));let r=e.group?e.group.length:0;n.paths.length&&r-t>0?(kk(e),ZX(i,e,n,t,o,s)):n.paths.length&&e.storeLoadOptions.group?(kk(e),JX(i,e,n,s)):Vk(e.data)&&e.data.resolve(s)}function ZX(i,e,t,n,o,s){let r=e.group||[],a=r[o+1],l=[];x(t.paths,d=>{var c;let h={requireTotalCount:!1,requireGroupCount:!0,group:[a],groupSummary:e.storeLoadOptions.groupSummary,filter:ts(t.paths[d],{filter:e.storeLoadOptions.filter,group:r}),select:e.storeLoadOptions.select,langParams:(c=e.storeLoadOptions)===null||c===void 0?void 0:c.langParams};d===0&&(h.skip=t.skip||0),d===t.paths.length-1&&(h.take=t.take);let p=h.take===0?[]:i._dataSource.loadFromStore(h);P(p).done(g=>{let C=t.items[d];Bk(e,t,o,d),C.items=g}),l.push(p)}),P.apply(null,l).done(()=>{Ry(i,e,s,n+1),Lk(i,e,n+1,t,o+1,s)})}function JX(i,e,t,n){let o=[],s=e.group||[];x(t.paths,(d,c)=>{o.push(ts(c,{group:e.isCustomLoading?e.storeLoadOptions.group:s}))});let{filter:r}=e.storeLoadOptions;e.storeLoadOptions.isLoadingAll||(r=H.combineFilters([r,H.combineFilters(o,"or")]));let a=m({},e.storeLoadOptions,{requireTotalCount:!1,requireGroupCount:!1,group:null,sort:s.concat(H.normalizeSortingInfo(e.storeLoadOptions.sort||[])),filter:r}),l=i._dataSource.isLastLevelGroupItemsPagingLocal();l||(a.skip=t.skip,a.take=t.take),P(t.take===0?[]:i._dataSource.loadFromStore(a)).done(d=>{l&&(d=i._dataSource.sortLastLevelGroupItems(d,s,t.paths),d=t.skip?d.slice(t.skip):d,d=t.take?d.slice(0,t.take):d),x(t.items,(c,h)=>{let p=h.count-(c===0&&t.skip||0),g=d.splice(0,p);Bk(e,t,s.length-1,c),h.items=g}),e.data.resolve(n)}).fail(e.data.reject)}var Ty=function(i,e){let t=new y,n=!!(e.group&&e.group.length),o=m({skip:0,take:1,requireGroupCount:n,requireTotalCount:!n},e,{group:n?e.group:null});return i.load(o).done((s,r)=>{let a=r&&(n?r.groupCount:r.totalCount);if(!isFinite(a)){t.reject(st.Error(n?"E4022":"E4021"));return}t.resolve(a)}).fail(t.reject.bind(t)),t},mu=class extends ld{updateTotalItemsCount(e){let t=0,n=e.extra&&e.extra.totalCount||0,o=e.extra&&e.extra.groupCount||0,s=this._dataSource.pageSize(),r=this._isVirtualPaging();gu(this,a=>{a.childrenTotalCount=0}),gu(this,(a,l)=>{let d=Pk(l,r?0:s,t),c=a.count+a.childrenTotalCount;r||(c+=Ay(d,s,c,l.length-1)),l[l.length-2]?l[l.length-2].childrenTotalCount+=c:t+=c}),super.updateTotalItemsCount(t-n+o)}_isGroupExpanded(e){let t=this._dataSource.group();return Dy(t,e)}_updatePagingOptions(e,t){let n=this,o=n._isVirtualPaging(),s=n._dataSource.pageSize(),r=[],a=[],l=0,d=0;e.take&&(gu(this,c=>{c.childrenTotalCount=0,c.skipChildrenTotalCount=0}),gu(n,(c,h)=>{let p,g=0,C=0,v=Pk(h,o?0:s,d),b=0,T=0,R=c.count+c.childrenTotalCount,U=R;t&&t(c,v);let Q=e.skip-v;v<=e.skip+e.take&&R&&(p=e.take,o||(b=Ay(v,s,R,h.length-1),R+=b*h.length,U+=b,s&&Q>=0&&(g=h.length,C=h.length-1,T=Math.floor(Q/s))),Q>=0?(v+R>e.skip&&r.unshift(Q-T*g-c.skipChildrenTotalCount),v+R>=e.skip+p&&a.unshift(p-g-c.childrenTotalCount+c.skipChildrenTotalCount)):v+R>=e.skip+p&&a.unshift(p+Q-c.childrenTotalCount)),v<=e.skip&&(h[h.length-2]?h[h.length-2].skipChildrenTotalCount+=Math.min(U,Q+1-T*C):l+=Math.min(U,Q+1)),v<=e.skip+p&&(R=Math.min(U,Q+p-(T+1)*C),h[h.length-2]?h[h.length-2].childrenTotalCount+=R:d+=R)}),e.skip-=l,e.take-=d-l),e.skips=r,e.takes=a}changeRowExpand(e){let t=this.findGroupInfo(e),n=this._dataSource,o=n.remoteOperations().groupPaging,s=H.normalizeSortingInfo(n.group());return t?(t.isExpanded=!t.isExpanded,o&&t.isExpanded&&e.length<s.length?Ty(n,{filter:ts(e,{filter:n.lastLoadOptions().filter,group:n.group()}),group:[s[e.length]],select:n.select()}).done(r=>{t.count=r}):new y().resolve()):new y().reject()}handleDataLoading(e){let t=this,{storeLoadOptions:n}=e,o=H.normalizeSortingInfo(n.group||e.loadOptions.group);if(!(e.isCustomLoading||!o.length)){if(e.remoteOperations.grouping){let s=t._dataSource.remoteOperations().paging;n.group=H.normalizeSortingInfo(n.group),n.group.forEach((r,a)=>{let l=a===n.group.length-1;r.isExpanded=!s||!l})}e.group=e.group||o,e.remoteOperations.paging?(e.skip=n.skip,e.take=n.take,n.requireGroupCount=!0,n.group=o.slice(0,1),t._updatePagingOptions(e),n.skip=e.skip,n.take=e.take):(e.skip=e.loadOptions.skip,e.take=e.loadOptions.take,t._updatePagingOptions(e))}}handleDataLoadedCore(e,t){let n=this,o=H.normalizeSortingInfo(e.storeLoadOptions.group||e.loadOptions.group).length,s=e.group?e.group.length:0,r,a={};if(e.isCustomLoading)t(e),My(n,e.data,o,a,[],e.isCustomLoading,e.storeLoadOptions.isLoadingAll);else{if(e.remoteOperations.paging||n.foreachGroups(l=>{l.count=0}),r=Ry(n,e,e.data,o),r<0){e.data=new y().reject(Z.Error("E1037"));return}if(e.remoteOperations.paging||o&&e.extra&&e.loadOptions.requireTotalCount&&(e.extra.totalCount=r,e.extra.groupCount=e.data.length),s&&e.storeLoadOptions.requireGroupCount&&!isFinite(e.extra.groupCount)){e.data=new y().reject(st.Error("E4022"));return}n.updateTotalItemsCount(e),e.remoteOperations.paging||(n._updatePagingOptions(e),e.lastLoadOptions.skips=e.skips,e.lastLoadOptions.takes=e.takes),t(e),e.remoteOperations.paging||n._processPaging(e,o)}Lk(n,e,o,a,0,e.data)}_processSkips(e,t,n){if(!n)return;let o=e[0],s=t[0],r=o&&o.items;s!==void 0&&(o.isContinuation=!0,r&&(o.items=r.slice(s),this._processSkips(o.items,t.slice(1),n-1)))}_processTakes(e,t,n,o,s){if(!o||!e)return;s=s||[];let r=e[e.length-1],a=r&&r.items,l=n[0],d=t[0];if(r){let c=r.count-(r.isContinuation&&d||0)||a.length;l!==void 0&&c>l&&(r.isContinuationOnNextPage=!0,s.forEach(h=>{h.isContinuationOnNextPage=!0}),a&&(a=a.slice(0,l),r.items=a)),s.push(r),this._processTakes(a,t.slice(1),n.slice(1),o-1,s)}}_processPaging(e,t){this._processSkips(e.data,e.skips,t),this._processTakes(e.data,e.skips,e.takes,t)}isLastLevelGroupItemsPagingLocal(){return!1}sortLastLevelGroupItems(e){return e}refresh(e,t){let n=this,o=n._dataSource,{storeLoadOptions:s}=e,r=e.group||e.storeLoadOptions.group,a=H.normalizeSortingInfo(n._group),l,d;function c(h,p){p.length===d+1&&(h.isExpanded=l)}for(d=0;d<a.length;d++)l=Dy(r,d),Dy(n._group,d)!==l&&n.foreachGroups(c);if(super.refresh.apply(this,arguments),r&&e.remoteOperations.paging&&t.reload)return gu(n,h=>{let p=Ty(o,{filter:ts(h.path,{filter:s.filter,group:r}),group:r.slice(h.path.length),select:s.select}),g=Ty(o,{filter:rm(h.path,{filter:s.filter,group:r},!0),group:r.slice(h.path.length-1,h.path.length),select:s.select});return P(g,p).done((C,v)=>{C=parseInt(C.length?C[0]:C),v=parseInt(v.length?v[0]:v),h.offset=C,h.count!==v&&(h.count=v,n.updateTotalItemsCount(e))})},!0)}};var Fy=function(i,e){let t=new y,n=m({skip:0,take:1,requireTotalCount:!0},e);return i.load(n).done((o,s)=>{t.resolve(s&&s.totalCount)}).fail(t.reject.bind(t)),t},am=function(i,e,t){return i.foreachGroups(n=>{if(!n.isExpanded)return e(n)},!1,!1,t,!0)},Nk=function(i,e){let t=0,n=e||0;return e&&(am(i,o=>{if(o.offset-t>=e)return!1;t+=o.count-1}),n+=t),n},Hk=function(i,e,t,n,o,s){let r=0,a=!1;for(let l=0;l<e.length;l++){let d=e[l];if(d.items!==void 0){t.push(d.key);let c=i.findGroupInfo(t);if(c&&!c.isExpanded)d.collapsedItems=d.items,d.items=null,n+=c.count,s--,s<0&&r++,o&&(a=!0);else if(d.items){let h=Hk(i,d.items,t,n,o,s);o&&(h.offset-n>1?d.isContinuation=!0:a=!0),n=h.offset,s=h.take,s<0&&(d.items.length?d.isContinuationOnNextPage=!0:r++)}t.pop()}else o&&(a=!0),n++,s--,s<0&&r++;o=!1}return a&&e.splice(0,1),r&&e.splice(-r,r),{offset:n,take:s}},e6=function(i,e){if(i.length!==e.length)return!1;for(let t=0;t<i.length;t++)if(!fs(null,i[t],e[t]))return!1;return!0},Py=function(i,e,t,n,o){if(e){for(let s=0;s<e.length;s++){let r=e[s];if("key"in r&&r.items!==void 0){t.push(r.key),o&&e6(o.path,t)&&!r.isContinuation&&(o.offset=n);let a=i.findGroupInfo(t);a&&!r.isContinuation&&(a.offset=n),a&&!a.isExpanded?n+=a.count:n=Py(i,r.items,t,n,o),t.pop()}else n++}return n}},t6=function(i,e){if(e.group){let t=H.normalizeSortingInfo(e.group),n=H.normalizeSortingInfo(i.sort);i.sort=qi.arrangeSortingInfo(t,n),delete e.group}},i6=function(i,e,t){let n=H.normalizeSortingInfo(t||e.group),o=[];for(let s=0;s<i.length;s++){let r=[];for(let a=0;a<=s;a++)r.push([n[a].selector,s===a?"<>":"=",i[a]]);o.push(H.combineFilters(r))}return o=H.combineFilters(o,"or"),H.combineFilters([o,e.filter])},$k=function(i,e){let t=i.count||i.items.length;if(!i.count&&e>1){t=0;for(let n=0;n<i.items.length;n++)t+=$k(i.items[n],e-1)}return t},fu=class extends ld{handleDataLoading(e){let{storeLoadOptions:t}=e,n=[],o=0,s=!1,r,{group:a}=e.loadOptions,l=0;if(t6(t,e.loadOptions),e.group=e.group||a,e.isCustomLoading)return;let d=m({},t);d.skip=Nk(this,t.skip),d.skip&&d.take&&a&&(d.skip--,d.take++,s=!0),d.take&&a&&(r=d.take,d.take++),am(this,c=>{if(c.offset>=d.skip+d.take+l)return!1;c.offset>=d.skip+l&&c.count&&(l+=c.count-1,n.push(c),o+=c.count)}),x(n,function(){d.filter=i6(this.path,d,a)}),e.storeLoadOptions=d,e.collapsedGroups=n,e.collapsedItemsCount=o,e.skip=d.skip||0,e.skipFirstItem=s,e.take=r}handleDataLoaded(e,t){let n=this,{collapsedGroups:o}=e,s=H.normalizeSortingInfo(e.group),r=s.length;function a(l,d,c,h,p){if(!l||!d.length||!c.length)return;let g,C,v=Ot(d[0],!0);for(C=0;C<l.length&&(g=Ot(l[C].key,!0),!(p>=h.offset||v===g));C++)p+=$k(l[C],c.length);(!l.length||v!==g)&&l.splice(C,0,{key:d[0],items:[],count:d.length===1?h.count:void 0}),a(l[C].items,d.slice(1),c.slice(1),h,p)}if(e.collapsedItemsCount&&e.extra&&e.extra.totalCount>=0&&(e.extra._totalCountWasIncreasedByCollapsedItems||(e.extra.totalCount+=e.collapsedItemsCount,e.extra._totalCountWasIncreasedByCollapsedItems=!0)),t(e),r){let{data:l}=e,d=vt(l);if(qi.multiLevelGroup(d,s).enumerate().done(c=>{l=c}),o)for(let c=0;c<o.length;c++)a(l,o[c].path,s,o[c],e.skip);e.isCustomLoading||Hk(n,l,[],e.skip,e.skipFirstItem,e.take),e.data=l}}isGroupItemCountable(e){return e.items===null}updateTotalItemsCount(){let e=0;am(this,t=>{t.count&&(e-=t.count-1)}),super.updateTotalItemsCount(e)}changeRowExpand(e){let t=this,n=t._dataSource,o=n.beginPageIndex?n.beginPageIndex():n.pageIndex(),s=n.items(),r=Nk(t,o*n.pageSize()),a=t.findGroupInfo(e),l;return a&&!a.isExpanded?l=new y().resolve(a.count):l=Fy(n,{filter:ts(e,{filter:n.filter(),group:n.group()})}),P(l).done(d=>{d=parseInt(d.length?d[0]:d),a?(Py(t,s,[],r),a.isExpanded=!a.isExpanded,a.count=d):(a={offset:-1,count:d,path:e,isExpanded:!1},Py(t,s,[],r,a),a.offset>=0&&t.addGroupInfo(a)),t.updateTotalItemsCount()}).fail(function(){n._eventsStrategy.fireEvent("loadError",arguments)})}allowCollapseAll(){return!1}refresh(e,t){let n=this,{storeLoadOptions:o}=e,s=n._dataSource;if(super.refresh.apply(this,arguments),t.reload)return am(n,r=>{let a=Fy(s,{filter:ts(r.path,o)}),l=Fy(s,{filter:rm(r.path,o)});return P(l,a).done((d,c)=>{d=parseInt(d.length?d[0]:d),c=parseInt(c.length?c[0]:c),r.offset=d,r.count!==c&&(r.count=c,n.updateTotalItemsCount())})},!0)}};var n6=i=>class extends i{init(){super.init.apply(this,arguments),this._initGroupingHelper()}_initGroupingHelper(e){let t=this._grouping,n=this.option("grouping.autoExpandAll"),o=this.option("focusedRowEnabled"),s=e?e.remoteOperations:this.remoteOperations();s.filtering&&s.sorting&&s.paging&&!s.grouping&&(n||!o)?(!t||t instanceof mu)&&(this._grouping=new fu(this)):(!t||t instanceof fu)&&(this._grouping=new mu(this))}totalItemsCount(){let e=super.totalItemsCount();return e>0&&this._dataSource.group()&&this._dataSource.requireTotalCount()?e+this._grouping.totalCountCorrection():e}itemsCount(){return this._dataSource.group()?this._grouping.itemsCount()||0:super.itemsCount.apply(this,arguments)}allowCollapseAll(){return this._grouping.allowCollapseAll()}isGroupItemCountable(e){return this._grouping.isGroupItemCountable(e)}isRowExpanded(e){let t=this._grouping.findGroupInfo(e);return t?t.isExpanded:!this._grouping.allowCollapseAll()}collapseAll(e){return this._collapseExpandAll(e,!1)}expandAll(e){return this._collapseExpandAll(e,!0)}_collapseExpandAll(e,t){let n=this,o=n._dataSource,s=o.group(),r=H.normalizeSortingInfo(s||[]);if(r.length){for(let a=0;a<r.length;a++)e===void 0||e===a?r[a].isExpanded=t:s&&s[a]&&(r[a].isExpanded=s[a].isExpanded);o.group(r),n._grouping.foreachGroups((a,l)=>{(e===void 0||e===l.length-1)&&(a.isExpanded=t)},!1,!0),n.resetPagesCache()}return!0}refresh(){return super.refresh.apply(this,arguments),this._grouping.refresh.apply(this._grouping,arguments)}changeRowExpand(e){let t=this,n=t._dataSource;if(n.group())return n.beginLoading(),t._lastLoadOptions&&(t._lastLoadOptions.groupExpand=!0),t._changeRowExpandCore(e).always(()=>{n.endLoading()})}_changeRowExpandCore(e){return this._grouping.changeRowExpand(e)}_hasGroupLevelsExpandState(e,t){if(e&&Array.isArray(e)){for(let n=0;n<e.length;n++)if(e[n].isExpanded===t)return!0}}_customizeRemoteOperations(e,t){let{remoteOperations:n}=e;e.storeLoadOptions.group?(n.grouping&&!e.isCustomLoading&&(!n.groupPaging||this._hasGroupLevelsExpandState(e.storeLoadOptions.group,!0))&&(n.paging=!1),!n.grouping&&(!n.sorting||!n.filtering||e.isCustomLoading||this._hasGroupLevelsExpandState(e.storeLoadOptions.group,!1))&&(n.paging=!1)):!e.isCustomLoading&&n.paging&&t.grouping&&this.resetCache(),super._customizeRemoteOperations.apply(this,arguments)}_handleDataLoading(e){return super._handleDataLoading(e),this._initGroupingHelper(e),this._grouping.handleDataLoading(e)}_handleDataLoaded(e){return this._grouping.handleDataLoaded(e,super._handleDataLoaded.bind(this))}_handleDataLoadedCore(e){return this._grouping.handleDataLoadedCore(e,super._handleDataLoadedCore.bind(this))}};Pr.extend(n6);var o6=i=>class extends i{init(){super.init(),this.createAction("onRowExpanding"),this.createAction("onRowExpanded"),this.createAction("onRowCollapsing"),this.createAction("onRowCollapsed")}_beforeProcessItems(e){let t=this._columnsController.getGroupColumns();return e=super._beforeProcessItems(e),e.length&&t.length&&(e=this._processGroupItems(e,t.length)),e}_processItem(e,t){return f(e.groupIndex)&&B(e.rowType)&&e.rowType.indexOf("group")===0?(e=this._processGroupItem(e,t),t.dataIndex=0):e=super._processItem.apply(this,arguments),e}_processGroupItem(e,t){return e}_processGroupItems(e,t,n){let o=this,s=o._columnsController.getGroupColumns(),r=s[s.length-t];if(!n){let l=o.option("scrolling.mode");n={collectContinuationItems:l!=="virtual"&&l!=="infinite",resultItems:[],path:[],values:[]}}let{resultItems:a}=n;if(n.data&&(n.collectContinuationItems||!n.data.isContinuation)&&a.push({rowType:"group",data:n.data,groupIndex:n.path.length-1,isExpanded:!!n.data.items,key:n.path.slice(0),values:n.values.slice(0)}),e)if(t===0)a.push.apply(a,e);else for(let l=0;l<e.length;l++){let d=e[l];d&&"items"in d?(n.data=d,n.path.push(d.key),n.values.push(r&&r.deserializeValue&&!r.calculateDisplayValue?r.deserializeValue(d.key):d.key),o._processGroupItems(d.items,t-1,n),n.data=void 0,n.path.pop(),n.values.pop()):a.push(d)}return a}publicMethods(){return super.publicMethods().concat(["collapseAll","expandAll","isRowExpanded","expandRow","collapseRow"])}collapseAll(e){let t=this._dataSource;t&&t.collapseAll(e)&&(t.pageIndex(0),t.reload())}expandAll(e){let t=this._dataSource;t&&t.expandAll(e)&&(t.pageIndex(0),t.reload())}changeRowExpand(e){let t=this,n=t.isRowExpanded(e),o={key:e,expanded:n};return t.executeAction(n?"onRowCollapsing":"onRowExpanding",o),o.cancel?new y().resolve():P(t._changeRowExpandCore(e)).done(()=>{o.expanded=!n,t.executeAction(n?"onRowCollapsed":"onRowExpanded",o)})}_changeRowExpandCore(e){let t=this,n=this._dataSource,o=new y;return n?P(n.changeRowExpand(e)).done(()=>{t.load().done(o.resolve).fail(o.reject)}).fail(o.reject):o.resolve(),o}isRowExpanded(e){let t=this._dataSource;return t&&t.isRowExpanded(e)}expandRow(e){return this.isRowExpanded(e)?new y().resolve():this.changeRowExpand(e)}collapseRow(e){return this.isRowExpanded(e)?this.changeRowExpand(e):new y().resolve()}optionChanged(e){e.name==="grouping"&&(e.name="dataSource"),super.optionChanged(e)}},ky=function(i,e){let t=this._columnsController;switch(e.itemData.value){case"group":{let n=t._dataSource.group()||[];t.columnOption(i.dataField,"groupIndex",n.length);break}case"ungroup":t.columnOption(i.dataField,"groupIndex",-1);break;case"ungroupAll":this.component.clearGrouping()}},zk=i=>{let e=i?.visible;return e==="auto"?F.current().deviceType==="desktop":!!e},Wk=(i,e)=>{let t=zk(i),n=i?.allowColumnDragging&&e.allowGrouping;return t&&!!n},s6=i=>class extends i{_getToolbarItems(){let e=super._getToolbarItems();return this._appendGroupingItem(e)}_appendGroupingItem(e){if(this._isGroupPanelVisible()){let t=!1,n={template:()=>{let o=u("<div>").addClass("dx-datagrid-group-panel");return this._updateGroupPanelContent(o),Ir("groupPanel",this,o,void 0,this._handleActionKeyDown.bind(this)),o},name:"groupPanel",onItemRendered:()=>{t&&this.renderCompleted.fire(),t=!0},location:"before",locateInMenu:"never",sortIndex:1};e.push(n),this.updateToolbarDimensions()}return e}_handleActionKeyDown(e){let{event:t}=e,n=u(t.target),o=n.closest(".dx-group-panel-item").index(),s=this._columnsController.getGroupColumns()[o],r=s&&s.index;n.is(".dx-header-filter")?this._headerFilterController.showHeaderFilterMenu(r,!0):this._processGroupItemAction(r),t.preventDefault()}_isGroupPanelVisible(){return zk(this.option("groupPanel"))}_renderGroupPanelItems(e,t){let n=this;e.empty(),x(t,(o,s)=>{n._createGroupPanelItem(e,s)}),nd(this)}_createGroupPanelItem(e,t){let n=u("<div>").addClass(t.cssClass).addClass("dx-group-panel-item").data("columnData",t).appendTo(e).text(t.caption);return gP(this,n),n}_columnOptionChanged(e){if(!this._requireReady&&!H.checkChanges(e.optionNames,["width","visibleWidth"])){let t=this.element(),n=t&&t.find(".dx-datagrid-group-panel");n&&n.length&&(this._updateGroupPanelContent(n),this.updateToolbarDimensions(),this.renderCompleted.fire())}super._columnOptionChanged()}_updateGroupPanelContent(e){let t=this.getColumns(),n=this.option("groupPanel");this._renderGroupPanelItems(e,t),n.allowColumnDragging&&!t.length&&(u("<div>").addClass("dx-group-panel-message").text(n.emptyPanelText).appendTo(e),e.closest(".dx-toolbar-item").addClass("dx-toolbar-label"),e.closest(".dx-toolbar-label").css("maxWidth","none"))}allowDragging(e){let t=this.option("groupPanel");return Wk(t,e)}getColumnElements(){let e=this.element();return e&&e.find(".dx-group-panel-item")}getColumns(){return this._columnsController.getGroupColumns()}getBoundingRect(){let e=this.element();if(e&&e.find(".dx-datagrid-group-panel").length){let t=e.offset();return{top:t.top,bottom:t.top+Y(e)}}return null}getName(){return"group"}getContextMenuItems(e){let t=this,n=t.option("grouping.contextMenuEnabled"),o=u(e.targetElement).closest(".dx-group-panel-item"),s;if(o.length&&(e.column=o.data("columnData")),n&&e.column){let{column:r}=e;if(f(r.allowGrouping)?r.allowGrouping:!0){let l=f(r.groupIndex)&&r.groupIndex>-1,d=t.option("grouping.texts"),c=ky.bind(t,r);s=[{text:d.ungroup,value:"ungroup",disabled:!l,onItemClick:c},{text:d.ungroupAll,value:"ungroupAll",onItemClick:c}]}}return s}hasGroupedColumns(){return this._isGroupPanelVisible()&&!!this.getColumns().length}optionChanged(e){e.name==="groupPanel"?(this._invalidate(),e.handled=!0):super.optionChanged(e)}},r6=i=>class extends i{getContextMenuItems(e){let t=this,n=t.option("grouping.contextMenuEnabled"),o;if(n&&e.row&&e.row.rowType==="group"){let r=t._columnsController.columnOption(`groupIndex:${e.row.groupIndex}`);if(r&&r.allowGrouping){let a=t.option("grouping.texts"),l=ky.bind(t,r);o=[],o.push({text:a.ungroup,value:"ungroup",onItemClick:l},{text:a.ungroupAll,value:"ungroupAll",onItemClick:l})}}return o}_rowClick(e){let t=this,n=t.option("grouping.expandMode"),s=t.option("scrolling.mode")!=="infinite"&&n==="rowClick"&&u(e.event.target).closest(".dx-group-row").length,r=u(e.event.target).closest(".dx-datagrid-expand").length;(s||r)&&t._changeGroupRowState(e),super._rowClick(e)}_changeGroupRowState(e){let t=this._dataController.items()[e.rowIndex],n=this._columnsController.columnOption(`groupIndex:${t.groupIndex}`,"allowCollapsing");(t.rowType==="data"||t.rowType==="group"&&n!==!1)&&(this._dataController.changeRowExpand(t.key,!0),e.event.preventDefault(),e.handled=!0)}},a6=i=>class extends i{getContextMenuItems(e){let t=this,n=t.option("grouping.contextMenuEnabled"),o=super.getContextMenuItems(e);if(n&&e.row&&(e.row.rowType==="header"||e.row.rowType==="detailAdaptive")){let{column:s}=e;if(!s.command&&(!f(s.allowGrouping)||s.allowGrouping)){let r=t.option("grouping.texts"),a=f(s.groupIndex)&&s.groupIndex>-1,l=ky.bind(t,s);o=o||[],o.push({text:r.groupByThisColumn,value:"group",beginGroup:!0,disabled:a,onItemClick:l}),s.showWhenGrouped&&o.push({text:r.ungroup,value:"ungroup",disabled:!a,onItemClick:l}),o.push({text:r.ungroupAll,value:"ungroupAll",onItemClick:l})}}return o}allowDragging(e){let t=this.option("groupPanel");return Wk(t,e)||super.allowDragging(e)}};H.registerModule("grouping",{defaultOptions:()=>({grouping:{autoExpandAll:!0,allowCollapsing:!0,contextMenuEnabled:!1,expandMode:"buttonClick",texts:{groupContinuesMessage:O.format("dxDataGrid-groupContinuesMessage"),groupContinuedMessage:O.format("dxDataGrid-groupContinuedMessage"),groupByThisColumn:O.format("dxDataGrid-groupHeaderText"),ungroup:O.format("dxDataGrid-ungroupHeaderText"),ungroupAll:O.format("dxDataGrid-ungroupAllText")}},groupPanel:{visible:!1,emptyPanelText:O.format("dxDataGrid-groupPanelEmptyText"),allowColumnDragging:!0}}),extenders:{controllers:{data:o6,columns:i=>class extends i{_getExpandColumnOptions(){let e=super._getExpandColumnOptions.apply(this,arguments);return e.cellTemplate=H.getExpandCellTemplate(),e}},editing:i=>class extends i{_isProcessedItem(e){return f(e.groupIndex)&&B(e.rowType)&&e.rowType.indexOf("group")===0}}},views:{headerPanel:s6,rowsView:r6,columnHeadersView:a6}}});var l6=i=>class extends i{_getExpandColumnsCore(){let e=super._getExpandColumnsCore();return this.option("masterDetail.enabled")&&e.push({type:"detailExpand",cellTemplate:M.getExpandCellTemplate()}),e}},By=function(i){i._expandedItems=[],i._isExpandAll=i.option("masterDetail.autoExpandAll")},d6=i=>class extends i{init(){By(this),super.init()}expandAll(e){let t=this;e<0?(t._isExpandAll=!0,t._expandedItems=[],t.updateItems()):super.expandAll.apply(t,arguments)}collapseAll(e){let t=this;e<0?(t._isExpandAll=!1,t._expandedItems=[],t.updateItems()):super.collapseAll.apply(t,arguments)}isRowExpandedHack(){return super.isRowExpanded.apply(this,arguments)}isRowExpanded(e){let t=this,n=M.getIndexByKey(e,t._expandedItems);return Array.isArray(e)?super.isRowExpanded.apply(t,arguments):!!(t._isExpandAll^(n>=0&&t._expandedItems[n].visible))}_getRowIndicesForExpand(e){let t=this.getRowIndexByKey(e);return[t,t+1]}_changeRowExpandCore(e){let t=this,n;if(Array.isArray(e))n=super._changeRowExpandCore.apply(t,arguments);else{let o=M.getIndexByKey(e,t._expandedItems);if(o>=0){let{visible:s}=t._expandedItems[o];t._expandedItems[o].visible=!s}else t._expandedItems.push({key:e,visible:!0});t.updateItems({changeType:"update",rowIndices:t._getRowIndicesForExpand(e)}),n=new y().resolve()}return n}_processDataItemHack(){return super._processDataItem.apply(this,arguments)}_processDataItem(e,t){let n=super._processDataItem.apply(this,arguments);return n.isExpanded=this.isRowExpanded(n.key),t.detailColumnIndex===void 0&&(t.detailColumnIndex=-1,x(t.visibleColumns,(o,s)=>{if(s.command==="expand"&&!f(s.groupIndex))return t.detailColumnIndex=o,!1})),t.detailColumnIndex>=0&&(n.values[t.detailColumnIndex]=n.isExpanded),n}_processItemsHack(){return super._processItems.apply(this,arguments)}_processItems(e,t){let n=this,{changeType:o}=t,s=[];return e=super._processItems.apply(n,arguments),o==="loadingAll"?e:(o==="refresh"&&(n._expandedItems=xt(n._expandedItems,r=>r.visible)),x(e,(r,a)=>{s.push(a);let l=M.getIndexByKey(a.key,n._expandedItems);a.rowType==="data"&&(a.isExpanded||l>=0)&&!a.isNewRow&&s.push({visible:a.isExpanded,rowType:"detail",key:a.key,data:a.data,values:[]})}),s)}optionChanged(e){let t=this,n,o;if(e.name==="masterDetail"){switch(e.name="dataSource",e.fullName){case"masterDetail":{let s=e.value||{},r=e.previousValue||{};n=s.enabled!==r.enabled,o=s.autoExpandAll!==r.autoExpandAll;break}case"masterDetail.template":By(t);break;case"masterDetail.enabled":n=!0;break;case"masterDetail.autoExpandAll":o=!0}(n||o)&&By(t)}super.optionChanged(e)}},c6=i=>class extends i{fireContentReadyAction(){super.fireContentReadyAction.apply(this,arguments),this._updateParentDataGrids(this.component.$element())}_updateParentDataGrids(e){let t=e.closest(".dx-master-detail-row");t.length&&P(this._updateMasterDataGrid(t,e)).done(()=>{this._updateParentDataGrids(t.parent())})}_updateMasterDataGrid(e,t){let n=u(e).data("options"),o=u(e).closest(`.${this.getWidgetContainerClass()}`).parent().data("dxDataGrid");if(n&&o)return this._updateMasterDataGridCore(o,n)}_updateMasterDataGridCore(e,t){let n=y();if(e.getView("rowsView").isFixedColumns())this._updateFixedMasterDetailGrids(e,t.rowIndex,u(t.rowElement)).done(n.resolve);else{if(e.option("scrolling.useNative")===!0){e.updateDimensions().done(()=>n.resolve(!0));return}let o=e.getScrollable();o?o?.update().done(()=>n.resolve()):n.resolve()}return n.promise()}_updateFixedMasterDetailGrids(e,t,n){let o=y(),s=u(e.getRowElement(t)),r=u(e.getView("rowsView").getTableElements()),a=s?.length===2&&Y(s.eq(0))!==Y(s.eq(1)),l=r?.length===2&&Y(r.eq(0))!==Y(r.eq(1));if(a||l){let d=z(n);return e.updateDimensions().done(()=>{let c=this.option("columnAutoWidth")&&e.option("scrolling.useNative")===!0,h=c&&d!==z(n);c&&h?this.updateDimensions().done(()=>o.resolve(!0)):o.resolve(!0)}),o.promise()}return y().resolve()}_toggleBestFitMode(e){if(super._toggleBestFitMode.apply(this,arguments),this.option("masterDetail.template")){let t=this._rowsView.getTableElement();t&&t.find(".dx-master-detail-cell").css("maxWidth",e?0:"")}}},u6=i=>class extends i{_getCellTemplate(e){let t=this,{column:n}=e,o=this._editingController,s=o&&o.isEditRow(e.rowIndex),r;return n.command==="detail"&&!s?r=t.option("masterDetail.template")||{allowRenderToDetachedContainer:!1,render:t._getDefaultTemplate(n)}:r=super._getCellTemplate.apply(t,arguments),r}_isDetailRow(e){return e&&e.rowType&&e.rowType.indexOf("detail")===0}_createRow(e){let t=super._createRow.apply(this,arguments);return e&&this._isDetailRow(e)&&(this.option("showRowLines")&&t.addClass("dx-row-lines"),t.addClass("dx-master-detail-row"),f(e.visible)&&t.toggle(e.visible)),t}_renderCells(e,t){let{row:n}=t,o,s=this._columnsController.getVisibleColumns();n.rowType&&this._isDetailRow(n)?this._needRenderCell(0,t.columnIndices)&&(o=this._renderCell(e,{value:null,row:n,rowIndex:n.rowIndex,column:{command:"detail"},columnIndex:0,change:t.change}),o.addClass("dx-cell-focus-disabled").addClass("dx-master-detail-cell").attr("colSpan",s.length),n.isEditing||o.attr("aria-roledescription",O.format("dxDataGrid-masterDetail"))):super._renderCells.apply(this,arguments)}},Gk={defaultOptions:()=>({masterDetail:{enabled:!1,autoExpandAll:!1,template:null}}),extenders:{controllers:{columns:l6,data:d6,resizing:c6},views:{rowsView:u6}}};H.registerModule("masterDetail",Gk);var Kk=oi.inherit({_supportedKeys(){return m(this.callBase(),{space:function(i){i.preventDefault(),this._clickAction({event:i})}})},_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,activeStateEnabled:!0,value:!1})},_canValueBeChangedByClick:()=>!0,_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}}])},_init(){this.callBase(),this.$element().addClass("dx-radiobutton")},_initMarkup(){this.callBase(),this._renderIcon(),this._renderCheckedState(this.option("value")),this._renderClick(),this.setAria("role","radio")},_renderIcon(){this._$icon=u("<div>").addClass("dx-radiobutton-icon"),u("<div>").addClass("dx-radiobutton-icon-dot").appendTo(this._$icon),this.$element().append(this._$icon)},_renderCheckedState(i){this.$element().toggleClass("dx-radiobutton-checked",i).find(".dx-radiobutton-icon").toggleClass("dx-radiobutton-icon-checked",i),this.setAria("checked",i)},_renderClick(){let i=D(oe,this.NAME);this._clickAction=this._createAction(e=>{this._clickHandler(e.event)}),_.off(this.$element(),i),_.on(this.$element(),i,e=>{this._clickAction({event:e})})},_clickHandler(i){this._saveValueChangeEvent(i),this.option("value",!0)},_optionChanged(i){i.name==="value"?(this._renderCheckedState(i.value),this.callBase(i)):this.callBase(i)}});G("dxRadioButton",Kk);var Uk=Kk;var jk=Uk;var Vy="dxListEditDecorator",h6=D(Fp,Vy),p6=D(Pp,Vy),g6=D(Ml,Vy),m6=ce.inherit({ctor(i){this._list=i,this._init()},_init:S,_shouldHandleSwipe:!1,_attachSwipeEvent(i){let e={itemSizeFunc:function(){return this._clearSwipeCache&&(this._itemWidthCache=z(this._list.$element()),this._clearSwipeCache=!1),this._itemWidthCache}.bind(this)};_.on(i.$itemElement,h6,e,this._itemSwipeStartHandler.bind(this)),_.on(i.$itemElement,p6,this._itemSwipeUpdateHandler.bind(this)),_.on(i.$itemElement,g6,this._itemSwipeEndHandler.bind(this))},_itemSwipeStartHandler(i){let e=u(i.currentTarget);if(e.is(".dx-state-disabled, .dx-state-disabled *")){i.cancel=!0;return}clearTimeout(this._list._inkRippleTimer),this._swipeStartHandler(e,i)},_itemSwipeUpdateHandler(i){let e=u(i.currentTarget);this._swipeUpdateHandler(e,i)},_itemSwipeEndHandler(i){let e=u(i.currentTarget);this._swipeEndHandler(e,i),this._clearSwipeCache=!0},beforeBag:S,afterBag:S,_commonOptions(){return{activeStateEnabled:this._list.option("activeStateEnabled"),hoverStateEnabled:this._list.option("hoverStateEnabled"),focusStateEnabled:this._list.option("focusStateEnabled")}},modifyElement(i){this._shouldHandleSwipe&&(this._attachSwipeEvent(i),this._clearSwipeCache=!0)},afterRender:S,handleClick:S,handleKeyboardEvents:S,handleEnterPressing:S,handleContextMenu:S,_swipeStartHandler:S,_swipeUpdateHandler:S,_swipeEndHandler:S,visibilityChange:S,getExcludedSelectors:S,dispose:S}),qk=m6;var Yk="dx-list-select-decorator-enabled";var f6="dx-list-select-checkbox-container",_6="dx-list-select-checkbox",C6="dx-list-select-radiobutton-container",x6="dx-list-select-radiobutton";var Xk=D(oe,"dxListEditDecorator");aM("selection","default",qk.inherit({_init(){this.callBase.apply(this,arguments);let i=this._list.option("selectionMode");this._singleStrategy=i==="single",this._containerClass=this._singleStrategy?C6:f6,this._controlClass=this._singleStrategy?x6:_6,this._controlWidget=this._singleStrategy?jk:Er,this._list.$element().addClass(Yk)},beforeBag(i){let{$itemElement:e}=i,t=i.$container.addClass(this._containerClass),n=u("<div>").addClass(this._controlClass).appendTo(t);new this._controlWidget(n,m(this._commonOptions(),{value:this._isSelected(e),elementAttr:{"aria-label":O.format("CheckState")},focusStateEnabled:!1,hoverStateEnabled:!1,onValueChanged:function(o){o.event&&this._list._saveSelectionChangeEvent(o.event),this._processCheckedState(e,o.value),o.event&&o.event.stopPropagation()}.bind(this)}))},modifyElement(i){this.callBase.apply(this,arguments);let{$itemElement:e}=i,t=this._controlWidget.getInstance(e.find(`.${this._controlClass}`));_.on(e,"stateChanged",(n,o)=>{t.option("value",o)})},_updateSelectAllState(){this._$selectAll&&this._selectAllCheckBox.option("value",this._list.isSelectAll())},afterRender(){this._list.option("selectionMode")==="all"&&(this._$selectAll?this._updateSelectAllState():this._renderSelectAll())},handleKeyboardEvents(i,e){let t=!e,n=this._list,o=this._$selectAll,s=n._getLastItemIndex();return!!o&&(e&&i===0||t&&i===s)?(n.option("focusedElement",o),n.scrollToItem(n.option("focusedElement")),!0):!1},handleEnterPressing(i){if(this._$selectAll&&this._$selectAll.hasClass("dx-state-focused"))return i.target=this._$selectAll.get(0),this._list._saveSelectionChangeEvent(i),this._selectAllCheckBox.option("value",!this._selectAllCheckBox.option("value")),!0},_renderSelectAll(){this._$selectAll=u("<div>").addClass("dx-list-select-all");let i=this._list._supportedKeys().downArrow.bind(this._list),e=u("<div>").addClass("dx-list-select-all-checkbox").appendTo(this._$selectAll);this._selectAllCheckBox=this._list._createComponent(e,Er,{elementAttr:{"aria-label":O.format("dxList-selectAll")},focusStateEnabled:!1,hoverStateEnabled:!1}),this._selectAllCheckBox.registerKeyHandler("downArrow",i),u("<div>").addClass("dx-list-select-all-label").text(this._list.option("selectAllText")).appendTo(this._$selectAll),this._list.itemsContainer().prepend(this._$selectAll),this._updateSelectAllState(),this._updateSelectAllAriaLabel(),this._attachSelectAllHandler()},_attachSelectAllHandler(){this._selectAllCheckBox.option("onValueChanged",this._selectAllHandler.bind(this)),_.off(this._$selectAll,Xk),_.on(this._$selectAll,Xk,this._selectAllClickHandler.bind(this))},_updateSelectAllAriaLabel(){if(!this._$selectAll)return;let{value:i}=this._selectAllCheckBox.option(),t=i===void 0?"indeterminate":i?"checked":"notChecked",n=`${O.format("dxList-selectAll")}, ${O.format(`dxList-selectAll-${t}`)}`;this._$selectAll.attr({"aria-label":n})},_selectAllHandler(i){i.event&&i.event.stopPropagation(),i.event&&this._list._saveSelectionChangeEvent(i.event);let{value:e}=this._selectAllCheckBox.option();e?this._selectAllItems():e===!1&&this._unselectAllItems(),this._updateSelectAllAriaLabel(),this._list._createActionByOption("onSelectAllValueChanged")({value:e})},_checkSelectAllCapability(){let i=this._list,e=i._dataController;return i.option("selectAllMode")==="allPages"&&i.option("grouped")&&!e.group()?(Z.log("W1010"),!1):!0},_selectAllItems(){this._checkSelectAllCapability()&&this._list._selection.selectAll(this._list.option("selectAllMode")==="page")},_unselectAllItems(){this._checkSelectAllCapability()&&this._list._selection.deselectAll(this._list.option("selectAllMode")==="page")},_selectAllClickHandler(i){this._list._saveSelectionChangeEvent(i),this._selectAllCheckBox.option("value",!this._selectAllCheckBox.option("value"))},_isSelected(i){return this._list.isItemSelected(i)},_processCheckedState(i,e){e?this._list.selectItem(i):this._list.unselectItem(i)},dispose(){this._disposeSelectAll(),this._list.$element().removeClass(Yk),this.callBase.apply(this,arguments)},_disposeSelectAll(){this._$selectAll&&(this._$selectAll.remove(),this._$selectAll=null)}}));var Qk=NM.inherit({_supportedKeys(){let i=this,e=this.callBase(),t=function(o){this._isEditable()?this._valueSubstituted()&&(this._preventFiltering=!0):this.option("showClearButton")&&(o.preventDefault(),this.clear()),this._savedTextRemoveEvent=o,this._preventSubstitution=!0},n=function(){i.option("searchEnabled")&&i._valueSubstituted()&&i._searchHandler()};return m({},e,{tab(){let{opened:o}=this.option(),s=o&&!!this._popup.getFocusableElements().length;s||this._resetCaretPosition(!0),e.tab&&e.tab.apply(this,arguments),s||this._cancelSearchIfNeed()},upArrow(o){if(e.upArrow.apply(this,arguments))return this.option("opened")||this._setNextValue(o),!0},downArrow(o){if(e.downArrow.apply(this,arguments))return this.option("opened")||this._setNextValue(o),!0},leftArrow(){var o;n(),(o=e.leftArrow)===null||o===void 0||o.apply(this,arguments)},rightArrow(){n(),e.rightArrow&&e.rightArrow.apply(this,arguments)},home(){n(),e.home&&e.home.apply(this,arguments)},end(){n(),e.end&&e.end.apply(this,arguments)},escape(){let o=e.escape&&e.escape.apply(this,arguments);return this._cancelEditing(),o??!0},enter(o){let s=this.option("opened"),r=this._input().val().trim(),a=r&&this._list&&!this._list.option("focusedElement");if(!r&&f(this.option("value"))&&this.option("allowClearing"))this._saveValueChangeEvent(o),this.option({selectedItem:null,value:null}),this.close();else{if(this.option("acceptCustomValue"))return o.preventDefault(),a&&(s&&this._toggleOpenState(),this._valueChangeEventHandler(o)),s;if(e.enter&&e.enter.apply(this,arguments))return s}},space(o){let s=this.option("opened"),r=this.option("searchEnabled"),a=this.option("acceptCustomValue");if(!(!s||r||a))return o.preventDefault(),this._valueChangeEventHandler(o),!0},backspace:t,del:t})},_getDefaultOptions(){return m(this.callBase(),{placeholder:O.format("Select"),fieldTemplate:null,customItemCreateEvent:"change",valueChangeEvent:"change",acceptCustomValue:!1,onCustomItemCreating(i){f(i.customItem)||(i.customItem=i.text)},showSelectionControls:!1,allowClearing:!0,tooltipEnabled:!1,openOnFieldClick:!0,showDropDownButton:!0,displayCustomValue:!1,useHiddenSubmitElement:!0})},_init(){this.callBase(),this._initCustomItemCreatingAction()},_initMarkup(){this.$element().addClass("dx-selectbox"),this._renderTooltip(),this.callBase(),this._$container.addClass("dx-selectbox-container")},_createPopup(){this.callBase(),this._popup.$element().addClass("dx-selectbox-popup"),this._popup.$overlayContent().attr("tabindex",-1)},_popupWrapperClass(){return`${this.callBase()} dx-selectbox-popup-wrapper`},_setDeprecatedOptions(){this.callBase(),m(this._deprecatedOptions,{valueChangeEvent:{since:"22.2",alias:"customItemCreateEvent"}})},_cancelEditing(){!this.option("searchEnabled")&&this._list&&(this._focusListElement(null),this._updateField(this.option("selectedItem")))},_renderOpenedState(){this.callBase(),this.option("opened")&&(this._scrollToSelectedItem(),this._focusSelectedElement())},_focusSelectedElement(){if(!this._searchValue()){this._focusListElement(null);return}let{items:e,selectedItem:t}=this.option(),n=this._list._itemElements(),o=e?.indexOf(t)??-1,s=o!==-1&&!this._isCustomItemSelected()?n.eq(o):null;this._focusListElement(s)},_renderFocusedElement(){if(!this._list)return;if(!this._searchValue()||this.option("acceptCustomValue")){this._focusListElement(null);return}let t=this._list._itemElements().not(".dx-state-disabled").eq(0);this._focusListElement(t)},_focusListElement(i){this._preventInputValueRender=!0,this._list.option("focusedElement",N(i)),delete this._preventInputValueRender},_scrollToSelectedItem(){this._list&&this._list.scrollToItem(this._list.option("selectedItem"))},_listContentReadyHandler(){this.callBase(),!(this._dataController.paginate()&&this._needPopupRepaint())&&this._scrollToSelectedItem()},_renderValue(){return this._renderInputValue(),this._setSubmitValue(),y().resolve()},_renderInputValue(){return this.callBase(...arguments).always(()=>{this._renderInputValueAsync()})},_renderInputValueAsync(){this._renderTooltip(),this._renderInputValueImpl().always(()=>{this._refreshSelected()})},_renderInputValueImpl(){return this._renderField(),y().resolve()},_setNextItem(i){let e=this._calcNextItem(i),t=this._valueGetter(e);this._setValue(t)},_setNextValue(i){(this._dataController.isLoaded()?y().resolve():this._dataController.load()).done(()=>{let t=this._getSelectedIndex(),n=this._dataController.pageSize(),o=this._dataController.isLastPage(),s=t===this._items().length-1;this._saveValueChangeEvent(i);let r=De(i)==="downArrow"?1:-1;n&&!o&&s&&r>0?(this._popup||this._createPopup(),this._dataController.isLoading()||this._list._loadNextPage().done(this._setNextItem.bind(this,r))):this._setNextItem(r)})},_setSelectedItem(i){let e=!this._isCustomValueAllowed()&&i===void 0;this.callBase(e?null:i),!e&&(!this._isEditable()||this._isCustomItemSelected())&&this._setListOption("selectedItem",this.option("selectedItem"))},_isCustomValueAllowed(){return this.option("acceptCustomValue")||this.callBase()},_displayValue(i){return i=!f(i)&&this._isCustomValueAllowed()?this.option("value"):i,this.callBase(i)},_listConfig(){let i=m(this.callBase(),{pageLoadMode:"scrollBottom",onSelectionChanged:this._getSelectionChangeHandler(),selectedItem:this.option("selectedItem"),onFocusedItemChanged:this._listFocusedItemChangeHandler.bind(this)});return this.option("showSelectionControls")&&m(i,{showSelectionControls:!0,selectByClick:!0}),i},_listFocusedItemChangeHandler(i){if(this._preventInputValueRender)return;let e=i.component,t=u(e.option("focusedElement")),n=e._getItemData(t);this._updateField(n)},_updateField(i){if(!(this._getTemplateByOption("fieldTemplate")&&this.option("fieldTemplate"))){let t=this._displayGetter(i);this.option("text",t),this._renderDisplayText(t);return}this._renderField()},_getSelectionChangeHandler(){return this.option("showSelectionControls")?this._selectionChangeHandler.bind(this):S},_selectionChangeHandler(i){x(i.addedItems||[],(e,t)=>{this._setValue(this._valueGetter(t))})},_getActualSearchValue(){return this._dataController.searchValue()},_isInlineAutocompleteEnabled(){return this.option("searchEnabled")&&!this.option("acceptCustomValue")&&this.option("searchMode")==="startswith"},_getAriaAutocomplete(){let{disabled:i,readOnly:e,searchEnabled:t}=this.option();return t&&!(e||i)?this._isInlineAutocompleteEnabled()?"both":"list":"none"},_toggleOpenState(i){if(!this.option("disabled")){if(i=arguments.length?i:!this.option("opened"),!i&&!this._shouldClearFilter()&&this._restoreInputText(!0),this._wasSearch()&&i)if(this._wasSearch(!1),(this.option("showDataBeforeSearch")||this._isMinSearchLengthExceeded())&&this._dataController.getDataSource()){if(this._searchTimer)return;let t=this._getActualSearchValue();t&&this._wasSearch(!0),this._filterDataSource(t||null)}else this._setListOption("items",[]);i&&this._scrollToSelectedItem(),this.callBase(i)}},_renderTooltip(){this.option("tooltipEnabled")&&this.$element().attr("title",this.option("displayValue"))},_renderDimensions(){this.callBase(),this._updatePopupWidth(),this._updateListDimensions()},_isValueEqualInputText(){let i=this.option("selectedItem");if(i===null)return!1;let e=this._displayGetter(i),t=e?String(e):"",n=this._searchValue();return t===n},_popupHidingHandler(){this._isValueEqualInputText()&&this._cancelEditing(),this.callBase()},_popupHiddenHandler(){this.callBase(),this._shouldCancelSearch()&&(this._wasSearch(!1),this._searchCanceled(),this._shouldCancelSearch(!1))},_restoreInputText(i){this.option("readOnly")||this._loadItemDeferred&&this._loadItemDeferred.always(()=>{let{acceptCustomValue:e,text:t,selectedItem:n}=this.option();if(e){!i&&!this._isValueChanging&&(this._updateField(n??this._createCustomItem(t)),this._clearFilter());return}if(this.option("searchEnabled")&&!this._searchValue()&&this.option("allowClearing")){this._clearTextValue();return}this._isValueEqualInputText()||this._renderInputValue().always(o=>{let s=Te(o,n);this._setSelectedItem(s),this._updateField(s),this._clearFilter()})})},_valueChangeEventIncludesBlur(){return this.option(this._getValueChangeEventOptionName()).includes("blur")},_isPreventedFocusOutEvent(i){return this._preventNestedFocusEvent(i)||this._valueChangeEventIncludesBlur()},_focusOutHandler(i){this._isPreventedFocusOutEvent(i)||(this._isOverlayNestedTarget(i.relatedTarget)||(this._restoreInputText(),this._clearSearchTimer()),this._cancelSearchIfNeed(i)),i.target=this._input().get(0),this.callBase(i)},_cancelSearchIfNeed(i){let{searchEnabled:e}=this.option(),t=this._isOverlayNestedTarget(i?.relatedTarget);if(this._wasSearch()&&e&&!t){var o;let s=(o=this._popup)===null||o===void 0?void 0:o._hideAnimationProcessing;this._clearSearchTimer(),s?this._shouldCancelSearch(!0):(this._wasSearch(!1),this._searchCanceled())}},_shouldCancelSearch(i){if(!arguments.length)return this._shouldCancelSearchValue;this._shouldCancelSearchValue=i},_isOverlayNestedTarget:i=>!!u(i).closest(".dx-selectbox-popup-wrapper").length,_clearTextValue(){let i=this.option("selectedItem"),e=this._displayGetter(i);i&&e!==""&&(this._savedTextRemoveEvent&&this._saveValueChangeEvent(this._savedTextRemoveEvent),this.option("value",null)),delete this._savedTextRemoveEvent},_shouldOpenPopup(){return this._needPassDataSourceToList()&&this._wasSearch()},_isFocused(){let i=w.getActiveElement(this.element());return this.callBase()&&u(i).closest(this._input()).length>0},_getValueChangeEventOptionName:()=>"customItemCreateEvent",_renderValueChangeEvent(){this._isEditable()&&this.callBase()},_fieldRenderData(){let i=this._list&&this.option("opened")&&u(this._list.option("focusedElement"));return i&&i.length?this._list._getItemData(i):this.option("selectedItem")},_isSelectedValue(i){return this._isValueEquals(i,this.option("value"))},_shouldCloseOnItemClick(){return!(this.option("showSelectionControls")&&this.option("selectionMode")!=="single")},_listItemClickHandler(i){let e=this._getCurrentValue();this._focusListElement(u(i.itemElement)),this._saveValueChangeEvent(i.event),this._completeSelection(this._valueGetter(i.itemData)),this._shouldCloseOnItemClick()&&this.option("opened",!1),this.option("searchEnabled")&&e===this._valueGetter(i.itemData)&&this._updateField(i.itemData),this._shouldClearFilter()&&this._cancelSearchIfNeed()},_shouldClearFilter(){return this._wasSearch()},_completeSelection(i){this._setValue(i)},_loadItem(i,e){let t=this,n=y();return this.callBase(i,e).done(o=>{n.resolve(o)}).fail(o=>{if(o!=null&&o.shouldSkipCallback)return;let s=t.option("selectedItem");t.option("acceptCustomValue")&&i===t._valueGetter(s)?n.resolve(s):n.reject()}),n.promise()},_loadInputValue(i,e){return this._loadItemDeferred=this._loadItem(i).always(e),this._loadItemDeferred},_isCustomItemSelected(){let i=this.option("selectedItem"),e=this._searchValue(),t=this._displayGetter(i);return!t||e!==t.toString()},_valueChangeEventHandler(i){this.option("acceptCustomValue")&&this._isCustomItemSelected()&&!this._isValueChanging&&(this._isValueChanging=!0,this._customItemAddedHandler(i))},_initCustomItemCreatingAction(){this._customItemCreatingAction=this._createActionByOption("onCustomItemCreating")},_createCustomItem(i){let e={text:i},t=this._customItemCreatingAction(e),n=Te(t,e.customItem);return f(t)&&he.log("W0015","onCustomItemCreating","customItem"),n},_customItemAddedHandler(i){let e=this._searchValue(),t=this._createCustomItem(e);if(this._saveValueChangeEvent(i),t===void 0)throw this._renderValue(),he.Error("E0121");To(t)?ht(t).done(this._setCustomItem.bind(this)).fail(this._setCustomItem.bind(this,null)):this._setCustomItem(t)},_setCustomItem(i){this._disposed||(i=i||null,this.option("selectedItem",i),this._cancelSearchIfNeed(),this._setValue(this._valueGetter(i)),this._renderDisplayText(this._displayGetter(i)),this._isValueChanging=!1)},_clearValueHandler(i){return this._preventFiltering=!0,this.callBase(i),this._searchCanceled(),!1},_wasSearch(i){if(!arguments.length)return!!this._wasSearchValue;this._wasSearchValue=i},_searchHandler(){if(this._preventFiltering){delete this._preventFiltering;return}this._needPassDataSourceToList()&&this._wasSearch(!0),this.callBase(arguments)},_dataSourceFiltered(i){this.callBase(),i!==null&&(this._renderInputSubstitution(),this._renderFocusedElement())},_valueSubstituted(){let i=this._input().get(0),e=this._searchValue().length,t=i.selectionStart===0&&i.selectionEnd===e,n=i.selectionStart!==i.selectionEnd,o=e===i.selectionEnd;return this._wasSearch()&&n&&!t&&o&&this._shouldSubstitutionBeRendered()},_shouldSubstitutionBeRendered(){return!this._preventSubstitution&&this._isInlineAutocompleteEnabled()},_renderInputSubstitution(){if(!this._shouldSubstitutionBeRendered()){delete this._preventSubstitution;return}let i=this._list&&this._getPlainItems(this._list.option("items"))[0];if(!i)return;let e=this._input(),t=e.val().length;if(t===0)return;let n=e.get(0),o=this._displayGetter(i).toString();n.value=o,this._caret({start:t,end:o.length})},_dispose(){this._renderInputValueAsync=S,delete this._loadItemDeferred,this.callBase()},_optionChanged(i){switch(i.name){case"customItemCreateEvent":this._refreshValueChangeEvent(),this._refreshFocusEvent(),this._refreshEvents();break;case"onCustomItemCreating":this._initCustomItemCreatingAction();break;case"tooltipEnabled":this._renderTooltip();break;case"readOnly":case"disabled":case"searchMode":this.callBase(i),this._setDefaultAria();break;case"displayCustomValue":case"acceptCustomValue":case"showSelectionControls":this._invalidate();break;case"allowClearing":break;default:this.callBase(i)}}});G("dxSelectBox",Qk);var Zk=Qk;var lm=Zk;var{abstract:dm}=ce,v6=ce.inherit({ctor(i){this.dateBox=i},widgetOption(){return this._widget&&this._widget.option.apply(this._widget,arguments)},_renderWidget(i){i=i||u("<div>"),this._widget=this._createWidget(i),this._widget.$element().appendTo(this._getWidgetContainer())},_createWidget(i){let e=this._getWidgetName(),t=this._getWidgetOptions();return this.dateBox._createComponent(i,e,t)},_getWidgetOptions:dm,_getWidgetName:dm,getDefaultOptions:()=>({mode:"text"}),getDisplayFormat:dm,supportedKeys:S,getKeyboardListener:S,customizeButtons:S,getParsedText(i,e){return de.parse(i,e)||de.parse(i)},renderInputMinMax:S,renderOpenedState(){this._updateValue()},popupConfig:dm,_dimensionChanged(){var i;(i=this._getPopup())===null||i===void 0||i.repaint()},renderPopupContent(){let i=this._getPopup();this._renderWidget();let e=i.$content().parent();_.off(e,"mousedown"),_.on(e,"mousedown",this._preventFocusOnPopup.bind(this))},_preventFocusOnPopup(i){i.preventDefault()},_getWidgetContainer(){return this._getPopup().$content()},_getPopup(){return this.dateBox._popup},popupShowingHandler:S,popupHiddenHandler:S,_updateValue(){this._widget&&this._widget.option("value",this.dateBoxValue())},useCurrentDateByDefault:S,getDefaultDate:()=>new Date,textChangedHandler:S,renderValue(){this.dateBox.option("opened")&&this._updateValue()},getValue(){return this._widget.option("value")},isAdaptivityChanged:()=>!1,dispose(){let i=this._getPopup();i&&i.$content().empty()},dateBoxValue(){return arguments.length?this.dateBox.dateValue.apply(this.dateBox,arguments):this.dateBox.dateOption.apply(this.dateBox,["value"])}}),Br=v6;var b6=Br.inherit({NAME:"Calendar",getDefaultOptions(){return m(this.callBase(),{todayButtonText:O.format("dxCalendar-todayButtonText")})},supportedKeys(){let i=function(e){return this.option("opened")?(e.preventDefault(),!0):!1};return{rightArrow(){if(this.option("opened"))return!0},leftArrow(){if(this.option("opened"))return!0},enter:function(e){if(this.dateBox.option("opened")){if(e.preventDefault(),this._widget.option("zoomLevel")===this._widget.option("maxZoomLevel")){let t=this._getContouredValue(),n=this._lastActionElement,o=this._closeDropDownByEnter();return o&&t&&n==="calendar"&&this.dateBoxValue(t,e),o&&this.dateBox.close(),this.dateBox._valueChangeEventHandler(e),!o}return!0}this.dateBox._valueChangeEventHandler(e)}.bind(this),home:i,end:i}},getDisplayFormat:i=>i||"shortdate",_closeDropDownByEnter:()=>!0,_getWidgetName:()=>_F,_getContouredValue(){return this._widget._view.option("contouredDate")},getKeyboardListener(){return this._widget},_getWidgetOptions(){let i=this.dateBox.option("disabledDates");return m(this.dateBox.option("calendarOptions"),{value:this.dateBoxValue()||null,selectionMode:"single",dateSerializationFormat:null,min:this.dateBox.dateOption("min"),max:this.dateBox.dateOption("max"),onValueChanged:this._valueChangedHandler.bind(this),onCellClick:this._cellClickHandler.bind(this),disabledDates:A(i)?this._injectComponent(i.bind(this.dateBox)):i,onContouredChanged:this._refreshActiveDescendant.bind(this),skipFocusCheck:!0})},_injectComponent(i){let e=this;return function(t){return m(t,{component:e.dateBox}),i(t)}},_refreshActiveDescendant(i){this._lastActionElement="calendar",this.dateBox.setAria("activedescendant",i.actionValue)},_getTodayButtonConfig(){let i=this.dateBox.option("buttonsLocation"),t=i==="default"?["bottom","center"]:Mo(i),n=it()?"text":"outlined";return{widget:"dxButton",toolbar:t[0],location:t[1]==="after"?"before":t[1],options:{onClick:o=>{this._widget._toTodayView(o)},text:this.dateBox.option("todayButtonText"),elementAttr:{class:"dx-button-today"},stylingMode:n}}},_isCalendarVisible(){let{calendarOptions:i}=this.dateBox.option();return dt(i)||i.visible!==!1},_getPopupToolbarItems(i){return this.dateBox.option("applyValueMode")==="useButtons"&&this._isCalendarVisible()?[this._getTodayButtonConfig(),...i]:i},popupConfig:i=>m(!0,i,{position:{collision:"flipfit flip"},width:"auto"}),_valueChangedHandler(i){let{value:e}=i,t=i.previousValue;j.sameDate(e,t)&&j.sameHoursAndMinutes(e,t)||this.dateBox.option("applyValueMode")==="instantly"&&this.dateBoxValue(this.getValue(),i.event)},_updateValue(){this._widget&&this._widget.option("value",this.dateBoxValue())},textChangedHandler(){this._lastActionElement="input",this.dateBox.option("opened")&&this._widget&&this._updateValue(!0)},_cellClickHandler(i){let{dateBox:e}=this;e.option("applyValueMode")==="instantly"&&(e.option("opened",!1),this.dateBoxValue(this.getValue(),i.event))}}),dd=b6;var Ly=["year","day","month","day"],Jk=["hours","minutes","seconds","milliseconds"];var y6=864e5,O6=31536e6,S6=function(i){let e=typeof i;return e==="string"?"format":e==="object"&&i.type!==void 0?i.type:null},is={SUPPORTED_FORMATS:["date","time","datetime"],ONE_MINUTE:6e4,ONE_DAY:y6,ONE_YEAR:O6,MIN_DATEVIEW_DEFAULT_DATE:new Date(1900,0,1),MAX_DATEVIEW_DEFAULT_DATE:function(){let i=new Date;return new Date(i.getFullYear()+50,i.getMonth(),i.getDate(),23,59,59)}(),FORMATS_INFO:{date:{getStandardPattern:()=>"yyyy-MM-dd",components:Ly},time:{getStandardPattern:()=>"HH:mm",components:Jk},datetime:{getStandardPattern(){let i;return function(){let e=u("<input>").attr("type","datetime");e.val("2000-01-01T01:01Z"),e.val()&&(i="yyyy-MM-ddTHH:mmZ")}(),i||(i="yyyy-MM-ddTHH:mm:ssZ"),is.FORMATS_INFO.datetime.getStandardPattern=function(){return i},i},components:[...Ly,...Jk]},"datetime-local":{getStandardPattern:()=>"yyyy-MM-ddTHH:mm:ss",components:[...Ly,"hours","minutes","seconds"]}},FORMATS_MAP:{date:"shortdate",time:"shorttime",datetime:"shortdateshorttime"},SUBMIT_FORMATS_MAP:{date:"date",time:"time",datetime:"datetime-local"},toStandardDateFormat(i,e){let t=is.FORMATS_INFO[e].getStandardPattern();return tt.serializeDate(i,t)},fromStandardDateFormat(i){let e=tt.dateParser(i);return Et(e)?e:void 0},getMaxMonthDay:(i,e)=>new Date(i,e+1,0).getDate(),mergeDates(i,e,t){if(!e)return e||null;if(!i||isNaN(i.getTime())){let s=new Date(null);i=new Date(s.getFullYear(),s.getMonth(),s.getDate())}let n=new Date(i.valueOf()),o=is.FORMATS_INFO[t];return x(o.components,function(){let s=is.DATE_COMPONENTS_INFO[this];n[s.setter](e[s.getter]())}),n},getLongestCaptionIndex(i){let e=0,t=0,n;for(n=0;n<i.length;++n)i[n].length>t&&(e=n,t=i[n].length);return e},formatUsesMonthName:i=>de.formatUsesMonthName(i),formatUsesDayName:i=>de.formatUsesDayName(i),getLongestDate(i,e,t){let n=S6(i),o=9;(!n||is.formatUsesMonthName(n))&&(o=is.getLongestCaptionIndex(e));let s=new Date(1888,o,21,23,59,59,999);if(!n||is.formatUsesDayName(n)){let r=s.getDate()-s.getDay()+is.getLongestCaptionIndex(t);s.setDate(r)}return s},normalizeTime(i){i.setSeconds(0),i.setMilliseconds(0)}};is.DATE_COMPONENTS_INFO={year:{getter:"getFullYear",setter:"setFullYear",formatter(i,e){let t=new Date(e.getTime());return t.setFullYear(i),de.format(t,"yyyy")},startValue:void 0,endValue:void 0},day:{getter:"getDate",setter:"setDate",formatter(i,e){let t=new Date(e.getTime());return t.setDate(i),de.format(t,"d")},startValue:1,endValue:void 0},month:{getter:"getMonth",setter:"setMonth",formatter:i=>de.getMonthNames()[i],startValue:0,endValue:11},hours:{getter:"getHours",setter:"setHours",formatter:i=>de.format(new Date(0,0,0,i),"hour"),startValue:0,endValue:23},minutes:{getter:"getMinutes",setter:"setMinutes",formatter:i=>de.format(new Date(0,0,0,0,i),"minute"),startValue:0,endValue:59},seconds:{getter:"getSeconds",setter:"setSeconds",formatter:i=>de.format(new Date(0,0,0,0,0,i),"second"),startValue:0,endValue:59},milliseconds:{getter:"getMilliseconds",setter:"setMilliseconds",formatter:i=>de.format(new Date(0,0,0,0,0,0,i),"millisecond"),startValue:0,endValue:999}};var Qe=is;var eB=function(i,e,t){E6(i,e,t)},E6=function(i,e,t){i.css("transform",`rotate(${e}deg) translate(0,${t}px)`)},tB=oi.inherit({_getDefaultOptions(){return m(this.callBase(),{value:new Date(Date.now()),use24HourFormat:!0,_showClock:!0,_arrowOffset:5,stylingMode:void 0})},_getValue(){return this.option("value")||new Date},_init(){this.callBase(),this.$element().addClass("dx-timeview")},_render(){this.callBase(),this._renderBox(),this._updateTime()},_renderBox(){let i=u("<div>").appendTo(this.$element()),e=[];this.option("_showClock")&&e.push({ratio:1,shrink:0,baseSize:"auto",template:this._renderClock.bind(this)}),e.push({ratio:0,shrink:0,baseSize:"auto",template:this._renderField.bind(this)}),this._createComponent(i,Ca,{height:"100%",width:"100%",direction:"col",items:e})},_renderClock(i,e,t){this._$hourArrow=u("<div>").addClass("dx-timeview-hourarrow"),this._$minuteArrow=u("<div>").addClass("dx-timeview-minutearrow");let n=u(t);n.addClass("dx-timeview-clock").append(this._$hourArrow).append(this._$minuteArrow),this.setAria("role","presentation",n)},_updateClock(){let i=this._getValue(),e=i.getHours()/12*360+i.getMinutes()/60*30,t=i.getMinutes()/60*360;eB(this._$hourArrow,e,this.option("_arrowOffset")),eB(this._$minuteArrow,t,this.option("_arrowOffset"))},_getBoxItems(i){let e=[{ratio:0,shrink:0,baseSize:"auto",template:()=>this._hourBox.$element()},{ratio:0,shrink:0,baseSize:"auto",template:u("<div>").addClass("dx-timeview-time-separator").text(de.getTimeSeparator())},{ratio:0,shrink:0,baseSize:"auto",template:()=>this._minuteBox.$element()}];return i&&e.push({ratio:0,shrink:0,baseSize:"auto",template:()=>this._format12.$element()}),e},_renderField(){let i=!this.option("use24HourFormat");return this._createHourBox(i),this._createMinuteBox(),i&&this._createFormat12Box(),this._createComponent(u("<div>").addClass("dx-timeview-field"),Ca,{direction:"row",align:"center",crossAlign:"center",items:this._getBoxItems(i)}).$element()},_createHourBox(i){(this._hourBox=this._createComponent(u("<div>"),ya,m({min:-1,max:i?13:24,value:this._getValue().getHours(),onValueChanged:this._onHourBoxValueChanged.bind(this),onKeyboardHandled:t=>this._keyboardHandler(t)},this._getNumberBoxConfig()))).setAria("label","hours")},_isPM(){return!this.option("use24HourFormat")&&this._format12.option("value")===1},_onHourBoxValueChanged(i){let{value:e,component:t}=i,n=this._getValue(),o=new Date(n),s=this._convertMaxHourToMin(e);t.option("value",s),this._isPM()&&(s+=12),o.setHours(s),Qe.normalizeTime(o),this.option("value",o)},_convertMaxHourToMin(i){let e=this.option("use24HourFormat")?24:12;return(e+i)%e},_createMinuteBox(){(this._minuteBox=this._createComponent(u("<div>"),ya,m({min:-1,max:60,value:this._getValue().getMinutes(),onKeyboardHandled:e=>this._keyboardHandler(e),onValueChanged:e=>{let{value:t,component:n}=e,o=(60+t)%60;n.option("value",o);let s=new Date(this._getValue());s.setMinutes(o),Qe.normalizeTime(s),this.option("value",s)}},this._getNumberBoxConfig()))).setAria("label","minutes")},_createFormat12Box(){let i=de.getPeriodNames();(this._format12=this._createComponent(u("<div>").addClass("dx-timeview-format12"),lm,{items:[{value:-1,text:i[0]},{value:1,text:i[1]}],valueExpr:"value",displayExpr:"text",onKeyboardHandled:t=>this._keyboardHandler(t),onValueChanged:t=>{let{value:n}=t,o=this._getValue().getHours(),s=new Date(this._getValue()),r=(o+12*n)%24;s.setHours(r),this.option("value",s)},value:this._getValue().getHours()>=12?1:-1,stylingMode:this.option("stylingMode")})).setAria("label","type")},_refreshFormat12(){if(this.option("use24HourFormat"))return;let n=this._getValue().getHours()>=12?1:-1;this._silentEditorValueUpdate(this._format12,n)},_silentEditorValueUpdate(i,e){i&&(i._suppressValueChangeAction(),i.option("value",e),i._resumeValueChangeAction())},_getNumberBoxConfig(){return{showSpinButtons:!0,displayValueFormatter:i=>(i<10?"0":"")+i,stylingMode:this.option("stylingMode")}},_normalizeHours(i){return this.option("use24HourFormat")?i:i%12||12},_updateField(){let i=this._normalizeHours(this._getValue().getHours());this._silentEditorValueUpdate(this._hourBox,i),this._silentEditorValueUpdate(this._minuteBox,this._getValue().getMinutes()),this._refreshFormat12()},_updateTime(){this.option("_showClock")&&this._updateClock(),this._updateField()},_visibilityChanged(i){i&&this._updateTime()},_optionChanged(i){switch(i.name){case"value":this._updateTime(),this.callBase(i);break;case"_arrowOffset":break;case"use24HourFormat":case"_showClock":case"stylingMode":this._invalidate();break;default:this.callBase(i)}}});G("dxTimeView",tB);var iB=tB;var w6=K();var nB="dx-datebox-datetime-time-side",I6=dd.inherit({NAME:"CalendarWithTime",getDefaultOptions(){return m(this.callBase(),{applyValueMode:"useButtons",buttonsLocation:"bottom after","dropDownOptions.showTitle":!1})},_closeDropDownByEnter(){return j.sameDate(this._getContouredValue(),this.widgetOption("value"))},getDisplayFormat:i=>i||"shortdateshorttime",_is24HourFormat(){return de.is24HourFormat(this.getDisplayFormat(this.dateBox.option("displayFormat")))},_getContouredValue(){let i=this.callBase();return this._updateDateTime(i)},_renderWidget(){this.callBase(),this._timeView=this.dateBox._createComponent(u("<div>"),iB,{value:this.dateBoxValue(),_showClock:!this._isShrinkView(),use24HourFormat:this._is24HourFormat(),onValueChanged:this._valueChangedHandler.bind(this),stylingMode:this.dateBox.option("stylingMode")})},renderOpenedState(){this.callBase();let i=this._getPopup();i&&i.$wrapper().toggleClass("dx-datebox-adaptivity-mode",this._isSmallScreen()),clearTimeout(this._repaintTimer),this._repaintTimer=setTimeout(()=>{this._getPopup()&&this._getPopup().repaint()},0)},isAdaptivityChanged(){let i=this._isShrinkView(),e=this._currentAdaptiveMode;return i!==e?(this._currentAdaptiveMode=i,e!==void 0):this.callBase()},_updateValue(i){let e=this.dateBoxValue();!e&&!i&&(e=new Date,Qe.normalizeTime(e)),this.callBase(),this._timeView&&(e&&this._timeView.option("value",e),this._timeView.option("use24HourFormat",this._is24HourFormat()))},_isSmallScreen:()=>z(w6)<=573,_isShrinkView(){return!this.dateBox.option("showAnalogClock")||this.dateBox.option("adaptivityEnabled")&&this._isSmallScreen()},_getBoxItems(){let i=[{ratio:0,shrink:0,baseSize:"auto",name:"calendar"}];return this._isShrinkView()||i.push({ratio:0,shrink:0,baseSize:"auto",name:"time"}),i},renderPopupContent(){this.callBase(),this._currentAdaptiveMode=this._isShrinkView();let i=this._getPopup().$content();this._box=this.dateBox._createComponent(u("<div>").appendTo(i),Ca,{direction:"row",crossAlign:"stretch",items:this._getBoxItems(),itemTemplate:function(e,t,n){let o=u("<div>");switch(e.name){case"calendar":o.append(this._widget.$element()),this._isShrinkView()&&(this._timeView.$element().addClass(nB),o.append(this._timeView.$element()));break;case"time":o.append(this._timeView.$element()),u(n).addClass(nB)}return o}.bind(this)})},popupConfig(i){let e=this.callBase(i);return m(e,{width:"auto"})},_preventFocusOnPopup(i){u(i.target).hasClass("dx-texteditor-input")||(this.callBase.apply(this,arguments),this.dateBox._hasFocusClass()||this.dateBox.focus())},_updateDateTime(i){let e=this._timeView.option("value");return i.setHours(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),i},getValue(){let i=this._widget.option("value")??this._widget.getContouredDate();return i=i?new Date(i):new Date,this._updateDateTime(i)},dispose(){clearTimeout(this._removeMinWidthTimer),clearTimeout(this._repaintTimer),this.callBase()}}),oB=I6;var _u=class{constructor(e){this.DIRECTION_HORIZONTAL="horizontal",this.DIRECTION_VERTICAL="vertical",this.DIRECTION_BOTH="both",this.direction=e??pa}get isHorizontal(){return this.direction===Wp||this.direction===Gp}get isVertical(){return this.direction===pa||this.direction===Gp}get isBoth(){return this.direction===Gp}};function sB(i,e){if(q(i)){let o=Te(i.left,i.x),s=Te(i.top,i.y);return{left:f(o)?o:void 0,top:f(s)?s:void 0}}let{isHorizontal:t,isVertical:n}=new _u(e);return{left:t&&f(i)?i:void 0,top:n&&f(i)?i:void 0}}var cm=class extends kl{_getDefaultOptions(){return m(super._getDefaultOptions(),{showScrollbar:"never",useNative:!1,selectedIndex:0,bounceEnabled:!1,items:[],showOnClick:!1,onClick:null,onSelectedIndexChanged:null,scrollByContent:!0})}_init(){super._init(),this.option("onVisibilityChange",this._visibilityChangedHandler.bind(this)),this.option("onEnd",this._endActionHandler.bind(this))}_render(){super._render(),this._renderSelectedItemFrame(),this.$element().addClass("dx-dateviewroller"),this._renderContainerClick(),this._renderItems(),this._renderSelectedValue(),this._renderItemsClick(),this._renderWheelEvent(),this._renderSelectedIndexChanged()}_renderSelectedIndexChanged(){this._selectedIndexChanged=this._createActionByOption("onSelectedIndexChanged")}_renderWheelEvent(){_.on(u(this.container()),"dxmousewheel",e=>{this._isWheelScrolled=!0})}_renderContainerClick(){if(!this.option("showOnClick"))return;let e=D(oe,this.NAME),t=this._createActionByOption("onClick");_.off(u(this.container()),e),_.on(u(this.container()),e,n=>{t({event:n})})}_renderItems(){let e=this.option("items")||[],t=u();u(this.content()).empty(),e.forEach(n=>{t=t.add(u("<div>").addClass("dx-dateview-item").append(n))}),u(this.content()).append(t),this._$items=t,this.update()}_renderSelectedItemFrame(){u("<div>").addClass("dx-dateview-item-selected-frame").append(u("<div>").addClass("dx-dateview-item-selected-border")).appendTo(u(this.container()))}_renderSelectedValue(e){let t=this._fitIndex(e??this.option("selectedIndex"));this._moveTo({top:this._getItemPosition(t)}),this._renderActiveStateItem()}_fitIndex(e){let n=(this.option("items")||[]).length;return e>=n?n-1:e<0?0:e}_getItemPosition(e){return Math.round(this._itemHeight()*e)}_renderItemsClick(){let e=this._getItemSelector(),t=D(oe,this.NAME);_.off(this.$element(),t,e),_.on(this.$element(),t,e,this._itemClickHandler.bind(this))}_getItemSelector(){return".dx-dateview-item"}_itemClickHandler(e){this.option("selectedIndex",this._itemElementIndex(e.currentTarget))}_itemElementIndex(e){return this._itemElements().index(e)}_itemElements(){return this.$element().find(this._getItemSelector())}_renderActiveStateItem(){let e=this.option("selectedIndex");x(this._$items,function(t){u(this).toggleClass("dx-dateview-item-selected",e===t)})}_shouldScrollToNeighborItem(){return F.real().deviceType==="desktop"&&this._isWheelScrolled}_moveTo(e){let{top:t,left:n}=sB(e),o=this.scrollOffset(),s={x:o.left-n,y:o.top-t};if(this._isVisible()&&(s.x||s.y))if(this._prepareDirections(!0),this._animation&&!this._shouldScrollToNeighborItem()){let r=this;pe.stop(u(this.content())),pe.animate(u(this.content()),{duration:200,type:"slide",to:{top:Math.floor(s.y)},complete(){Bo(u(r.content())),r.handleMove({delta:s})}}),delete this._animation}else this.handleMove({delta:s})}_validate(e){return this._moveIsAllowed(e)}_fitSelectedIndexInRange(e){let t=this.option("items").length;return Math.max(Math.min(e,t-1),0)}_isInNullNeighborhood(e){return-.1<=e&&e<=.1}_getSelectedIndexAfterScroll(e){let t=this.scrollOffset().top,n=e*this._itemHeight(),o=t-n;if(this._isInNullNeighborhood(o))return e;let s=o>0?1:-1;return this._fitSelectedIndexInRange(e+s)}_getNewSelectedIndex(e){if(this._shouldScrollToNeighborItem())return this._getSelectedIndexAfterScroll(e);this._animation=!0;let t=this.scrollOffset().top/this._itemHeight();return Math.round(t)}_endActionHandler(){let e=this.option("selectedIndex"),t=this._getNewSelectedIndex(e);t===e?this._renderSelectedValue(t):this.option("selectedIndex",t),this._isWheelScrolled=!1}_itemHeight(){let e=this._$items.first();return Y(e)}_toggleActive(e){this.$element().toggleClass("dx-state-active",e)}_isVisible(){return u(this.container()).is(":visible")}_fireSelectedIndexChanged(e,t){this._selectedIndexChanged({value:e,previousValue:t,event:void 0})}_visibilityChanged(e){super._visibilityChanged(e),this._visibilityChangedHandler(e)}_visibilityChangedHandler(e){e&&(this._visibilityTimer=setTimeout(()=>{this._renderSelectedValue(this.option("selectedIndex"))})),this.toggleActiveState(!1)}toggleActiveState(e){this.$element().toggleClass("dx-dateviewroller-current",e)}_refreshSelectedIndex(){let e=this.option("selectedIndex"),t=this._fitIndex(e);t===e?this._renderActiveStateItem():this.option("selectedIndex",t)}_optionChanged(e){switch(e.name){case"selectedIndex":this._fireSelectedIndexChanged(e.value,e.previousValue),this._renderSelectedValue(e.value);break;case"items":this._renderItems(),this._refreshSelectedIndex();break;case"onClick":case"showOnClick":this._renderContainerClick();break;case"onSelectedIndexChanged":this._renderSelectedIndexChanged();break;default:super._optionChanged(e)}}_dispose(){clearTimeout(this._visibilityTimer),super._dispose()}};G("dxDateViewRoller",cm);var rB=cm;var aB={date:"date",datetime:"datetime",time:"time"},Cn={year:"year",month:"month",day:"day",hours:"hours"},lB=oi.inherit({_valueOption(){let i=this.option("value"),e=new Date(i);return!i||isNaN(e)?this._getDefaultDate():e},_getDefaultDate(){let i=new Date;return this.option("type")===aB.date?new Date(i.getFullYear(),i.getMonth(),i.getDate()):i},_getDefaultOptions(){return m(this.callBase(),{minDate:Qe.MIN_DATEVIEW_DEFAULT_DATE,maxDate:Qe.MAX_DATEVIEW_DEFAULT_DATE,type:aB.date,value:new Date,applyCompactClass:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:i=>i.deviceType!=="desktop",options:{applyCompactClass:!0}}])},_render(){this.callBase(),this.$element().addClass("dx-dateview"),this._toggleFormatClasses(this.option("type")),this._toggleCompactClass()},_toggleFormatClasses(i,e){this.$element().addClass(`dx-dateview-${i}`),e&&this.$element().removeClass(`dx-dateview-${e}`)},_toggleCompactClass(){this.$element().toggleClass("dx-dateview-compact",this.option("applyCompactClass"))},_wrapper(){return this._$wrapper},_renderContentImpl(){this._$wrapper=u("<div>").addClass("dx-dateview-wrapper"),this._renderRollers(),this._$wrapper.appendTo(this.$element())},_renderRollers(){this._$rollersContainer||(this._$rollersContainer=u("<div>").addClass("dx-dateview-rollers")),this._$rollersContainer.empty(),this._createRollerConfigs(),this._rollers={};let i=this;x(i._rollerConfigs,e=>{let t=u("<div>").appendTo(i._$rollersContainer).addClass(`dx-dateviewroller-${i._rollerConfigs[e].type}`);i._rollers[i._rollerConfigs[e].type]=i._createComponent(t,rB,{items:i._rollerConfigs[e].displayItems,selectedIndex:i._rollerConfigs[e].selectedIndex,showScrollbar:"never",scrollByContent:!0,onStart(n){let o=n.component;o._toggleActive(!0),i._setActiveRoller(i._rollerConfigs[e],o.option("selectedIndex"))},onEnd(n){n.component._toggleActive(!1)},onClick(n){let o=n.component;o._toggleActive(!0),i._setActiveRoller(i._rollerConfigs[e],o.option("selectedIndex")),i._setRollerState(i._rollerConfigs[e],o.option("selectedIndex")),o._toggleActive(!1)},onSelectedIndexChanged(n){let o=n.component;i._setRollerState(i._rollerConfigs[e],o.option("selectedIndex"))}})}),i._$rollersContainer.appendTo(i._wrapper())},_createRollerConfigs(i){let e=this;i=i||e.option("type"),e._rollerConfigs={},de.getFormatParts(Qe.FORMATS_MAP[i]).forEach(t=>{e._createRollerConfig(t)})},_createRollerConfig(i){let e=Qe.DATE_COMPONENTS_INFO[i],t=this._calculateRollerConfigValueRange(i),{startValue:n}=t,{endValue:o}=t,{formatter:s}=e,r=this._getCurrentDate(),a={type:i,setValue:e.setter,valueItems:[],displayItems:[],getIndex:l=>l[e.getter]()-n};for(let l=n;l<=o;l++)a.valueItems.push(l),a.displayItems.push(s(l,r));a.selectedIndex=a.getIndex(r),this._rollerConfigs[i]=a},_setActiveRoller(i){let e=i&&this._rollers[i.type];x(this._rollers,function(){this.toggleActiveState(this===e)})},_updateRollersPosition(){let i=this;x(this._rollers,function(e){let t=i._rollerConfigs[e].getIndex(i._getCurrentDate());this.option("selectedIndex",t)})},_setRollerState(i,e){if(e!==i.selectedIndex){let t=i.valueItems[e],{setValue:n}=i,o=new Date(this._getCurrentDate()),s=o.getDate(),r=this.option("minDate"),a=this.option("maxDate");i.type===Cn.month?s=Math.min(s,Qe.getMaxMonthDay(o.getFullYear(),t)):i.type===Cn.year&&(s=Math.min(s,Qe.getMaxMonthDay(t,o.getMonth()))),o.setDate(s),o[n](t);let l=j.normalizeDate(o,r,a);o=Qe.mergeDates(l,o,"time"),o=j.normalizeDate(o,r,a),this.option("value",o),i.selectedIndex=e}i.type===Cn.year&&this._refreshRollers(),i.type===Cn.month&&(this._refreshRoller(Cn.day),this._refreshRoller(Cn.hours))},_refreshRoller(i){let e=this._rollers[i];if(e){this._createRollerConfig(i);let t=this._rollerConfigs[i];(i===Cn.day||t.displayItems.toString()!==e.option("items").toString())&&e.option({items:t.displayItems,selectedIndex:t.selectedIndex})}},_getCurrentDate(){let i=this._valueOption(),e=this.option("minDate"),t=this.option("maxDate");return j.normalizeDate(i,e,t)},_calculateRollerConfigValueRange(i){let e=this._getCurrentDate(),t=this.option("minDate"),n=this.option("maxDate"),o=j.sameYear(e,t),s=o&&e.getMonth()===t.getMonth(),r=j.sameYear(e,n),a=r&&e.getMonth()===n.getMonth(),l=s&&e.getDate()===t.getDate(),d=a&&e.getDate()===n.getDate(),c=Qe.DATE_COMPONENTS_INFO[i],{startValue:h}=c,{endValue:p}=c;return i===Cn.year&&(h=t.getFullYear(),p=n.getFullYear()),i===Cn.month&&(o&&(h=t.getMonth()),r&&(p=n.getMonth())),i===Cn.day&&(p=Qe.getMaxMonthDay(e.getFullYear(),e.getMonth()),o&&s&&(h=t.getDate()),r&&a&&(p=n.getDate())),i===Cn.hours&&(h=l?t.getHours():h,p=d?n.getHours():p),{startValue:h,endValue:p}},_refreshRollers(){this._refreshRoller(Cn.month),this._refreshRoller(Cn.day),this._refreshRoller(Cn.hours)},_optionChanged(i){switch(i.name){case"minDate":case"maxDate":case"type":this._renderRollers(),this._toggleFormatClasses(i.value,i.previousValue);break;case"visible":this.callBase(i),i.value&&this._renderRollers();break;case"value":this.option("value",this._valueOption()),this._refreshRollers(),this._updateRollersPosition();break;default:this.callBase(i)}},_clean(){this.callBase(),delete this._$rollersContainer}});G("dxDateView",lB);var dB=lB;var D6=K(),T6=Br.inherit({NAME:"DateView",getDefaultOptions(){return m(this.callBase(),{openOnFieldClick:!0,applyButtonText:O.format("OK"),"dropDownOptions.showTitle":!0})},getDisplayFormat(i){return i||Qe.FORMATS_MAP[this.dateBox.option("type")]},popupConfig(i){return{toolbarItems:this.dateBox._popupToolbarItemsConfig(),onInitialized:i.onInitialized,defaultOptionsRules:[{device:{platform:"android"},options:{width:333,height:331}},{device(e){let{platform:t}=e;return t==="generic"||t==="ios"},options:{width:"auto",height:"auto"}},{device(e){let{platform:t}=e,{phone:n}=e;return t==="generic"&&n},options:{width:333,maxWidth:"100%",maxHeight:"100%",height:"auto",position:{collision:"flipfit flip"}}},{device:{platform:"ios",phone:!0},options:{width:"100%",position:{my:"bottom",at:"bottom",of:D6}}}]}},_renderWidget(){if(Yr(this.dateBox.option("mode"))&&this.dateBox._isNativeType()||this.dateBox.option("readOnly")){this._widget&&(this._widget.$element().remove(),this._widget=null);return}let i=this._getPopup();if(this._widget)this._widget.option(this._getWidgetOptions());else{let e=u("<div>").appendTo(i.$content());this._widget=this._createWidget(e)}this._widget.$element().appendTo(this._getWidgetContainer())},_getWidgetName:()=>dB,renderOpenedState(){this.callBase(),this._widget&&this._widget.option("value",this._widget._getCurrentDate())},_getWidgetOptions(){return{value:this.dateBoxValue()||new Date,type:this.dateBox.option("type"),minDate:this.dateBox.dateOption("min")||new Date(1900,0,1),maxDate:this.dateBox.dateOption("max")||new Date(Date.now()+50*Qe.ONE_YEAR),onDisposing:function(){this._widget=null}.bind(this)}}}),cB=T6;var A6=K();var M6={min:new Date(0,0,0,0,0),max:new Date(0,0,0,23,59)},R6=Br.inherit({NAME:"List",supportedKeys:()=>({space:S,home:S,end:S}),getDefaultOptions(){return m(this.callBase(),{applyValueMode:"instantly"})},getDisplayFormat:i=>i||"shorttime",popupConfig:i=>i,getValue(){let i=this._widget.option("selectedIndex");if(i===-1)return this.dateBox.option("value");let e=this._widgetItems[i];return this._getDateByItemData(e)},useCurrentDateByDefault:()=>!0,getDefaultDate:()=>new Date(null),popupShowingHandler(){this.dateBox._dimensionChanged()},_renderWidget(){this.callBase(),this._refreshItems()},_getWidgetName:()=>jo,_getWidgetOptions(){return{itemTemplate:this._timeListItemTemplate.bind(this),onItemClick:this._listItemClickHandler.bind(this),tabIndex:-1,onFocusedItemChanged:this._refreshActiveDescendant.bind(this),selectionMode:"single"}},_refreshActiveDescendant(i){this.dateBox.setAria("activedescendant",""),this.dateBox.setAria("activedescendant",i.actionValue)},_refreshItems(){this._widgetItems=this._getTimeListItems(),this._widget.option("items",this._widgetItems)},renderOpenedState(){this._widget&&(this._widget.option("focusedElement",null),this._setSelectedItemsByValue(),this._widget.option("templatesRenderAsynchronously")?this._asyncScrollTimeout=setTimeout(this._scrollToSelectedItem.bind(this)):this._scrollToSelectedItem())},dispose(){this.callBase(),clearTimeout(this._asyncScrollTimeout)},_updateValue(){this._widget&&(this._refreshItems(),this._setSelectedItemsByValue(),this._scrollToSelectedItem())},_setSelectedItemsByValue(){let i=this.dateBoxValue(),e=this._getDateIndex(i);e===-1?this._widget.option("selectedItems",[]):this._widget.option("selectedIndex",e)},_scrollToSelectedItem(){this._widget.scrollToItem(this._widget.option("selectedIndex"))},_getDateIndex(i){let e=-1;for(let t=0,n=this._widgetItems.length;t<n;t++)if(this._areDatesEqual(i,this._widgetItems[t])){e=t;break}return e},_areDatesEqual:(i,e)=>Et(i)&&Et(e)&&i.getHours()===e.getHours()&&i.getMinutes()===e.getMinutes(),_getTimeListItems(){let i=this.dateBox.dateOption("min")||this._getBoundaryDate("min"),e=this.dateBox.dateOption("max")||this._getBoundaryDate("max"),t=this.dateBox.dateOption("value")||null,n=e-i,o=i.getMinutes()%this.dateBox.option("interval");return n<0?[]:(n>Qe.ONE_DAY&&(n=Qe.ONE_DAY),t-i<Qe.ONE_DAY?this._getRangeItems(i,new Date(i),n):(i=this._getBoundaryDate("min"),i.setMinutes(o),t&&Math.abs(t-e)<Qe.ONE_DAY&&(n=(60*e.getHours()+Math.abs(e.getMinutes()-o))*Qe.ONE_MINUTE),this._getRangeItems(i,new Date(i),n)))},_getRangeItems(i,e,t){let n=[],o=this.dateBox.option("interval");for(;e-i<=t;)n.push(new Date(e)),e.setMinutes(e.getMinutes()+o);return n},_getBoundaryDate(i){let e=M6[i],t=new Date(Te(this.dateBox.dateOption("value"),0));return new Date(t.getFullYear(),t.getMonth(),t.getDate(),e.getHours(),e.getMinutes())},_timeListItemTemplate(i){let e=this.dateBox.option("displayFormat");return de.format(i,this.getDisplayFormat(e))},_listItemClickHandler(i){if(this.dateBox.option("applyValueMode")==="useButtons")return;let e=this._getDateByItemData(i.itemData);this.dateBox.option("opened",!1),this.dateBoxValue(e,i.event)},_getDateByItemData(i){let e=this.dateBox.option("value"),t=i.getHours(),n=i.getMinutes(),o=i.getSeconds(),s=i.getFullYear(),r=i.getMonth(),a=i.getDate();return e?(this.dateBox.option("dateSerializationFormat")?e=tt.deserializeDate(e):e=new Date(e),e.setHours(t),e.setMinutes(n),e.setSeconds(o),e.setFullYear(s),e.setMonth(r),e.setDate(a)):e=new Date(s,r,a,t,n,0,0),e},getKeyboardListener(){return this._widget},_updatePopupHeight(){let i=$l(this.dateBox.option("dropDownOptions.height"));if(i===void 0||i==="auto"){this.dateBox._setPopupOption("height","auto");let e=X(this._widget.$element()),t=.45*Y(A6);this.dateBox._setPopupOption("height",Math.min(e,t))}this.dateBox._timeList&&this.dateBox._timeList.updateDimensions()},getParsedText(i,e){let t=this.callBase(i,e);return t&&(t=Qe.mergeDates(t,new Date(null),"date")),t}}),uB=R6;var F6=Br.inherit({NAME:"Native",popupConfig:i=>m({},i,{width:"auto"}),getParsedText(i){return i?this.dateBox.option("type")==="datetime"?new Date(i.replace(/-/g,"/").replace("T"," ").split(".")[0]):Qe.fromStandardDateFormat(i):null},renderPopupContent:S,_getWidgetName:S,_getWidgetOptions:S,_getDateBoxType(){let i=this.dateBox.option("type");return Qe.SUPPORTED_FORMATS.includes(i)?i==="datetime"&&!Yr(i)&&(i="datetime-local"):i="date",i},customizeButtons(){let i=this.dateBox.getButton("dropDown");F.real().android&&i&&i.on("click",()=>{this.dateBox._input().get(0).click()})},getDefaultOptions(){return{mode:this._getDateBoxType()}},getDisplayFormat(i){let e=this._getDateBoxType();return i||Qe.FORMATS_MAP[e]},renderInputMinMax(i){let e=this.dateBox.option("type"),t={datetime:"yyyy-MM-ddTHH:mm:ss",date:"yyyy-MM-dd",time:"HH:mm:ss"}[e]??"yyyy-MM-dd";i.attr({min:tt.serializeDate(this.dateBox.dateOption("min"),t),max:tt.serializeDate(this.dateBox.dateOption("max"),t)})}}),hB=F6;var Cu=K();var P6="dx-show-invalid-badge",k6="dx-clear-button-area";var to={calendar:"calendar",rollers:"rollers",list:"list",native:"native"},io={date:"date",datetime:"datetime",time:"time"},xu={calendar:"Calendar",dateView:"DateView",native:"Native",calendarWithTime:"CalendarWithTime",list:"List"},B6={Calendar:dd,DateView:cB,Native:hB,CalendarWithTime:oB,List:uB},V6=zl.inherit({_supportedKeys(){return m(this.callBase(),this._strategy.supportedKeys())},_renderButtonContainers(){this.callBase.apply(this,arguments),this._strategy.customizeButtons()},_getDefaultOptions(){return m(this.callBase(),{type:"date",showAnalogClock:!0,value:null,dateSerializationFormat:void 0,min:void 0,max:void 0,displayFormat:null,interval:30,disabledDates:null,pickerType:to.calendar,invalidDateMessage:O.format("dxDateBox-validation-datetime"),dateOutOfRangeMessage:O.format("validation-range"),applyButtonText:O.format("OK"),adaptivityEnabled:!1,calendarOptions:{},useHiddenSubmitElement:!0,_showValidationIcon:!0})},_defaultOptionsRules(){return this.callBase().concat([{device:{platform:"ios"},options:{"dropDownOptions.showTitle":!0}},{device:{platform:"android"},options:{buttonsLocation:"bottom after"}},{device(){let i=F.real(),{platform:e}=i;return e==="ios"||e==="android"},options:{pickerType:to.native}},{device:{platform:"generic",deviceType:"desktop"},options:{buttonsLocation:"bottom after"}}])},_initOptions(i){this._userOptions=m({},i),this.callBase(i),this._updatePickerOptions()},_updatePickerOptions(){let i=this.option("pickerType"),e=this.option("type");i===to.list&&(e===io.datetime||e===io.date)&&(i=to.calendar),e===io.time&&i===to.calendar&&(i=to.list),this._pickerType=i,this._setShowDropDownButtonOption()},_setShowDropDownButtonOption(){let{platform:i}=F.real(),e=i==="android"&&be.mozilla,t=this._isNativeType(),n=i!=="generic"||!t;t&&e&&(n=!1),this.option({showDropDownButton:n})},_init(){this._initStrategy(),this.option(m({},this._strategy.getDefaultOptions(),this._userOptions)),delete this._userOptions,this.callBase()},_toLowerCaseFirstLetter:i=>i.charAt(0).toLowerCase()+i.substr(1),_initStrategy(){let i=this._getStrategyName(this._getFormatType()),e=B6[i];this._strategy&&this._strategy.NAME===i||(this._strategy=new e(this))},_getFormatType(){let i=this.option("type"),e=/h|m|s/g.test(i),t=/d|M|Y/g.test(i),n="";return t&&(n+=io.date),e&&(n+=io.time),n},_getStrategyName(i){let e=this._pickerType;return e===to.rollers?xu.dateView:e===to.native?xu.native:i===io.date?xu.calendar:i===io.datetime?xu.calendarWithTime:xu.list},_initMarkup(){this.$element().addClass("dx-datebox"),this.callBase(),this._refreshFormatClass(),this._refreshPickerTypeClass(),this._strategy.renderInputMinMax(this._input())},_render(){this.callBase(),this._formatValidationIcon()},_renderDimensions(){this.callBase(),this.$element().toggleClass("dx-auto-width",!this.option("width")),this._updatePopupWidth(),this._updatePopupHeight()},_dimensionChanged(){this.callBase(),this._updatePopupHeight()},_updatePopupHeight(){if(this._popup){var i,e;(i=(e=this._strategy)._updatePopupHeight)===null||i===void 0||i.call(e)}},_refreshFormatClass(){let i=this.$element();x(io,(e,t)=>{i.removeClass(`dx-datebox-${t}`)}),i.addClass(`dx-datebox-${this.option("type")}`)},_refreshPickerTypeClass(){let i=this.$element();x(to,(e,t)=>{i.removeClass(`dx-datebox-${t}`)}),i.addClass(`dx-datebox-${this._pickerType}`)},_formatValidationIcon(){if(!W())return;let i=this._input().get(0),e=this.option("rtlEnabled"),t=this._getClearButtonWidth(),n=this._getLongestElementDimensions(),o=parseFloat(Cu.getComputedStyle(i).width)-t,s=n.width>o,{style:r}=i;this.$element().toggleClass(P6,!s&&this.option("_showValidationIcon")),s?(this._storedPadding===void 0&&(this._storedPadding=e?n.leftPadding:n.rightPadding),e?r.paddingLeft=0:r.paddingRight=0):e?r.paddingLeft=`${this._storedPadding}px`:r.paddingRight=`${this._storedPadding}px`},_getClearButtonWidth(){let i=0;if(this._isClearButtonVisible()&&this._input().val()===""){let e=this.$element().find(`.${k6}`).get(0);i=parseFloat(Cu.getComputedStyle(e).width)}return i},_getLongestElementDimensions(){let i=this._strategy.getDisplayFormat(this.option("displayFormat")),e=de.format(Qe.getLongestDate(i,de.getMonthNames(),de.getDayNames()),i),t=this._input(),n=t.get(0),o=w0(t,e),r=this._storedPadding!==void 0?this._storedPadding:0;o.appendTo(this.$element());let a=parseFloat(Cu.getComputedStyle(o.get(0)).width),l=parseFloat(Cu.getComputedStyle(n).paddingRight),d=parseFloat(Cu.getComputedStyle(n).paddingLeft),c=a+d+l+r;return o.remove(),{width:c,leftPadding:d,rightPadding:l}},_getKeyboardListeners(){return this.callBase().concat([this._strategy&&this._strategy.getKeyboardListener()])},_renderPopup(){this.callBase(),this._popup.$wrapper().addClass("dx-datebox-wrapper"),this._renderPopupWrapper()},_getPopupToolbarItems(){var i,e;let t=this.callBase();return((i=(e=this._strategy)._getPopupToolbarItems)===null||i===void 0?void 0:i.call(e,t))??t},_popupConfig(){let i=this.callBase();return m(this._strategy.popupConfig(i),{title:this._getPopupTitle(),dragEnabled:!1})},_renderPopupWrapper(){if(!this._popup)return;let i=this.$element(),e=m({},io,to);x(e,(t,n)=>{i.removeClass(`dx-datebox-wrapper-${n}`)}),this._popup.$wrapper().addClass(`dx-datebox-wrapper-${this.option("type")}`).addClass(`dx-datebox-wrapper-${this._pickerType}`).addClass("dx-dropdowneditor-overlay")},_renderPopupContent(){this.callBase(),this._strategy.renderPopupContent()},_popupShowingHandler(){this.callBase(),this._strategy.popupShowingHandler()},_popupShownHandler(){this.callBase(),this._strategy.renderOpenedState()},_popupHiddenHandler(){this.callBase(),this._strategy.renderOpenedState(),this._strategy.popupHiddenHandler()},_visibilityChanged(i){i&&this._formatValidationIcon()},_clearValueHandler(i){this.option("text",""),this.callBase(i)},_readOnlyPropValue(){if(this._pickerType===to.rollers)return!0;let{platform:i}=F.real();return this._isNativeType()&&(i==="ios"||i==="android")?this.option("readOnly"):this.callBase()},_isClearButtonVisible(){return this.callBase()&&!this._isNativeType()},_renderValue(){let i=this.dateOption("value");return this.option("text",this._getDisplayedText(i)),this._strategy.renderValue(),this.callBase()},_setSubmitValue(){let i=this.dateOption("value"),e=this.option("dateSerializationFormat"),t=Qe.SUBMIT_FORMATS_MAP[this.option("type")],n=e?tt.serializeDate(i,e):Qe.toStandardDateFormat(i,t);this._getSubmitElement().val(n)},_getDisplayedText(i){let e=this.option("mode"),t;if(e==="text"){let n=this._strategy.getDisplayFormat(this.option("displayFormat"));t=de.format(i,n)}else{let n=this._getFormatByMode(e);n?t=de.format(i,n):t=Qe.toStandardDateFormat(i,e)}return t},_getFormatByMode:i=>Yr(i)?null:Qe.FORMATS_MAP[i],_valueChangeEventHandler(i){let{text:e,type:t,validationError:n}=this.option(),o=this.dateOption("value");if(e===this._getDisplayedText(o)){this._recallInternalValidation(o,n);return}let s=this._getParsedDate(e),r=o??this._getDateByDefault(),a=Qe.mergeDates(r,s,t),l=s&&t==="time"?a:s;if(this._applyInternalValidation(l).isValid){let d=this._getDisplayedText(a);r&&a&&r.getTime()===a.getTime()&&d!==e?this._renderValue():this.dateValue(a,i)}},_recallInternalValidation(i,e){(!e||e.editorSpecific)&&(this._applyInternalValidation(i),this._applyCustomValidation(i))},_getDateByDefault(){return this._strategy.useCurrentDateByDefault()&&this._strategy.getDefaultDate()},_getParsedDate(i){let e=this._strategy.getDisplayFormat(this.option("displayFormat"));return this._strategy.getParsedText(i,e)??void 0},_applyInternalValidation(i){let t=!!this.option("text")&&i!==null,n=!!i&&Et(i)&&!isNaN(i.getTime()),o=n&&j.dateInRange(i,this.dateOption("min"),this.dateOption("max"),this.option("type")),s=!t&&!i||o,r="";return n?o||(r=this.option("dateOutOfRangeMessage")):r=this.option("invalidDateMessage"),this._updateInternalValidationState(s,r),{isValid:s,isDate:n}},_updateInternalValidationState(i,e){this.option({isValid:i,validationError:i?null:{editorSpecific:!0,message:e}})},_applyCustomValidation(i){this.validationRequest.fire({editor:this,value:this._serializeDate(i)})},_isValueChanged(i){let e=this.dateOption("value"),t=e&&e.getTime(),n=i&&i.getTime();return t!==n},_isTextChanged(i){let e=this.option("text"),t=i&&this._getDisplayedText(i)||"";return e!==t},_renderProps(){this.callBase(),this._input().attr("autocomplete","off")},_renderOpenedState(){this._isNativeType()||this.callBase(),this._strategy.isAdaptivityChanged()&&this._refreshStrategy()},_getPopupTitle(){let i=this.option("placeholder");if(i)return i;let e=this.option("type");return e===io.time?O.format("dxDateBox-simulatedDataPickerTitleTime"):e===io.date||e===io.datetime?O.format("dxDateBox-simulatedDataPickerTitleDate"):""},_refreshStrategy(){this._strategy.dispose(),this._initStrategy(),this.option(this._strategy.getDefaultOptions()),this._refresh()},_applyButtonHandler(i){let e=this._strategy.getValue();this.dateValue(e,i.event),this.callBase()},_dispose(){var i;this.callBase(),(i=this._strategy)===null||i===void 0||i.dispose()},_isNativeType(){return this._pickerType===to.native},_updatePopupTitle(){var i;(i=this._popup)===null||i===void 0||i.option("title",this._getPopupTitle())},_optionChanged(i){switch(i.name){case"showClearButton":case"buttons":case"isValid":case"readOnly":this.callBase.apply(this,arguments),this._formatValidationIcon();break;case"pickerType":this._updatePickerOptions({pickerType:i.value}),this._refreshStrategy(),this._refreshPickerTypeClass(),this._invalidate();break;case"type":this._updatePickerOptions({format:i.value}),this._refreshStrategy(),this._refreshFormatClass(),this._renderPopupWrapper(),this._formatValidationIcon(),this._updateValue();break;case"placeholder":this.callBase.apply(this,arguments),this._updatePopupTitle();break;case"min":case"max":{let e=this.option("isValid");this._applyInternalValidation(this.dateOption("value")),e||this._applyCustomValidation(this.dateOption("value")),this._invalidate();break}case"dateSerializationFormat":case"interval":case"disabledDates":case"calendarOptions":this._invalidate();break;case"displayFormat":this.option("text",this._getDisplayedText(this.dateOption("value"))),this._renderInputValue();break;case"text":this._strategy.textChangedHandler(i.value),this.callBase.apply(this,arguments);break;case"showDropDownButton":this._formatValidationIcon(),this.callBase.apply(this,arguments);break;case"todayButtonText":this._setPopupOption("toolbarItems",this._getPopupToolbarItems());break;case"invalidDateMessage":case"dateOutOfRangeMessage":case"adaptivityEnabled":case"showAnalogClock":case"_showValidationIcon":break;default:this.callBase.apply(this,arguments)}},_getSerializationFormat(){let i=this.option("value");if(this.option("dateSerializationFormat")&&fe().forceIsoDateParsing)return this.option("dateSerializationFormat");if(xe(i))return"number";if(B(i))return tt.getDateSerializationFormat(i)},_updateValue(i){this.callBase(),this._applyInternalValidation(i??this.dateOption("value"))},dateValue(i,e){let t=this._isValueChanged(i);return t&&e&&this._saveValueChangeEvent(e),t||(this._isTextChanged(i)?this._updateValue(i):this.option("text")===""&&this._applyCustomValidation(i)),this.dateOption("value",i)},dateOption(i,e){if(arguments.length===1)return tt.deserializeDate(this.option(i));this.option(i,this._serializeDate(e))},_serializeDate(i){let e=this._getSerializationFormat();return tt.serializeDate(i,e)},_clearValue(){let i=this.option("value");this.callBase(),i===null&&this._applyCustomValidation(null)},clear(){let i=this.option("value");this.callBase(),i===null&&this._applyInternalValidation(null)}}),pB=V6;var gB=i=>i.getMonth()+1,mB=(i,e)=>{let t=i.getDate(),n=vu("M",i),o=ft(parseInt(e),n.min,n.max);i.setMonth(o-1,1);let{min:s,max:r}=vu("dM",i),a=ft(t,s,r);i.setDate(a)},L6={a:i=>i.getHours()<12?0:1,E:"getDay",y:"getFullYear",M:gB,L:gB,d:"getDate",H:"getHours",h:"getHours",m:"getMinutes",s:"getSeconds",S:"getMilliseconds",x:"getTimezoneOffset"},N6=m({},KR(),{a:(i,e)=>{let t=i.getHours();t>=12!==!!parseInt(e)&&i.setHours((t+12)%24)},d:(i,e)=>{let t=vu("dM",i).max;e>t&&i.setMonth(i.getMonth()+1),i.setDate(e)},h:(i,e)=>{let t=i.getHours()>=12;i.setHours(+e%12+(t?12:0))},M:mB,L:mB,E:(i,e)=>{e<0||i.setDate(i.getDate()-i.getDay()+parseInt(e))},y:(i,e)=>{let t=i.getFullYear(),n=String(e).length,o=String(vu("y",i).max).length,s=parseInt(String(t).substr(0,o-n)+e);i.setFullYear(s)},x:i=>i}),H6=i=>L6[i]||(()=>i),fB=(i,e)=>{let t=e.regexp.exec(i),n=0,o=0,s=[];for(let r=1;r<t.length;r++){n=o,o=n+t[r].length;let a=e.patterns[r-1].replace(/^'|'$/g,""),l=H6(a[0]);s.push({index:r-1,isStub:a===t[r],caret:{start:n,end:o},pattern:a,text:t[r],limits:function(){for(var d=arguments.length,c=new Array(d),h=0;h<d;h++)c[h]=arguments[h];return vu(a[0],...c)},setter:N6[a[0]]||S,getter:l})}return s},vu=(i,e,t)=>{let n={y:{min:0,max:9999},M:{min:1,max:12},L:{min:1,max:12},d:{min:1,max:31},dM:{min:1,max:new Date(e.getFullYear(),e.getMonth()+1,0).getDate()},E:{min:0,max:6},H:{min:0,max:23},h:{min:1,max:12},m:{min:0,max:59},s:{min:0,max:59},S:{min:0,max:999},a:{min:0,max:1},x:{min:0,max:0}};return n[t||i]||n.getAmPm},_B=(i,e)=>{for(let t=0;t<i.length;t++){let n=i[t].caret.end>=e;if(!i[t].isStub&&n)return t}return null};var $6=pB.inherit({_supportedKeys(i){let e=this.callBase(i),t=o=>{let s=e[De(o)];return s&&s.apply(this,[o])},n=(o,s)=>this._shouldUseOriginalHandler(o)?t.apply(this,[o]):s.apply(this,[o]);return m({},e,{del:o=>n(o,s=>{this._revertPart(1),this._isAllSelected()||s.preventDefault()}),backspace:o=>n(o,s=>{this._revertPart(-1),this._isAllSelected()||s.preventDefault()}),home:o=>n(o,s=>{this._selectFirstPart(),s.preventDefault()}),end:o=>n(o,s=>{this._selectLastPart(),s.preventDefault()}),escape:o=>n(o,s=>{this._revertChanges(s)}),enter:o=>n(o,()=>{this._enterHandler()}),leftArrow:o=>n(o,s=>{this._selectNextPart(-1),s.preventDefault()}),rightArrow:o=>n(o,s=>{this._selectNextPart(1),s.preventDefault()}),upArrow:o=>n(o,s=>{this._upDownArrowHandler(1),s.preventDefault()}),downArrow:o=>n(o,s=>{this._upDownArrowHandler(-1),s.preventDefault()})})},_shouldUseOriginalHandler(i){let e=this.option("opened")&&i&&!["backspace","del"].includes(De(i));return!this._useMaskBehavior()||e||i&&i.altKey},_upDownArrowHandler(i){this._setNewDateIfEmpty();let e=this._getActivePartValue(this._initialMaskValue),n=this._getActivePartValue()-e;this._loadMaskValue(this._initialMaskValue),this._changePartValue(n+i,!0)},_changePartValue(i,e){let t=this._getActivePartProp("pattern");/^a{1,5}$/.test(t)?this._toggleAmPm():this._partIncrease(i,e)},_toggleAmPm(){let i=this._getActivePartProp("text"),t=1^Bs.getPeriodNames().indexOf(i);this._setActivePartValue(t)},_getDefaultOptions(){return m(this.callBase(),{useMaskBehavior:!1,emptyDateValue:new Date(2e3,0,1,0,0,0)})},_isSingleCharKey(i){let{originalEvent:e,alt:t}=i,n=e.data||e.key;return typeof n=="string"&&n.length===1&&!t&&!ot(e)},_isSingleDigitKey(i){var e;let t=(e=i.originalEvent)===null||e===void 0?void 0:e.data;return t?.length===1&&parseInt(t,10)},_useBeforeInputEvent:()=>F.real().android,_keyInputHandler(i,e){let t=this._input().val();this._processInputKey(e),i.preventDefault(),t!==this._input().val()&&_.trigger(this._input(),"input")},_keyboardHandler(i){let{key:e}=i.originalEvent,t=this.callBase(i);return!this._useMaskBehavior()||this._useBeforeInputEvent()||(be.chrome&&i.key==="Process"&&i.code.indexOf("Digit")===0?(e=i.code.replace("Digit",""),this._processInputKey(e),this._maskInputHandler=()=>{this._renderSelectedPart()}):this._isSingleCharKey(i)&&this._keyInputHandler(i.originalEvent,e)),t},_maskBeforeInputHandler(i){this._maskInputHandler=null;let{inputType:e}=i.originalEvent;e==="insertCompositionText"&&(this._maskInputHandler=()=>{this._renderSelectedPart()});let t=e==="deleteContentBackward";if(t||e==="deleteContentForward"){let s=t?-1:1;this._maskInputHandler=()=>{this._revertPart(),this._selectNextPart(s)}}if(!this._useMaskBehavior()||!this._isSingleCharKey(i))return;let o=i.originalEvent.data;return this._keyInputHandler(i,o),!0},_keyPressHandler(i){let{originalEvent:e}=i;e?.inputType==="insertCompositionText"&&this._isSingleDigitKey(i)&&(this._processInputKey(e.data),this._renderDisplayText(this._getDisplayedText(this._maskValue)),this._selectNextPart()),this.callBase(i),this._maskInputHandler&&(this._maskInputHandler(),this._maskInputHandler=null)},_processInputKey(i){this._isAllSelected()&&(this._activePartIndex=0),this._setNewDateIfEmpty(),isNaN(parseInt(i))?this._searchString(i):this._searchNumber(i)},_isAllSelected(){let i=this._caret();return i.end-i.start===this.option("text").length},_getFormatPattern(){if(this._formatPattern)return this._formatPattern;let i=this._strategy.getDisplayFormat(this.option("displayFormat"));return B(i)&&!de._getPatternByFormat(i)?this._formatPattern=i:this._formatPattern=Sg(t=>de.format(t,i)),this._formatPattern},_setNewDateIfEmpty(){if(!this._maskValue){let i=this.option("type")==="time"?new Date(null):new Date;this._maskValue=i,this._initialMaskValue=i,this._renderDateParts()}},_partLimitsReached(i){let e=String(i).length,t=this._getActivePartProp("pattern").length,o=t===1?e:Math.min(t,e),s=this._searchValue.length===o,r=parseInt(`${this._searchValue}0`)>i;return s||r},_searchNumber(i){let{max:e}=this._getActivePartLimits(),t=String(e).length;this._searchValue=(this._searchValue+i).substr(-t),isNaN(this._searchValue)&&(this._searchValue=i),this._setActivePartValue(this._searchValue),this._partLimitsReached(e)&&this._selectNextPart(1)},_searchString(i){if(!isNaN(parseInt(this._getActivePartProp("text"))))return;let e=this._getActivePartProp("limits")(this._maskValue),t=this._searchValue+i.toLowerCase(),n=e.max-e.min;for(let o=0;o<=n;o++)if(this._loadMaskValue(this._initialMaskValue),this._changePartValue(o+1),this._getActivePartProp("text").toLowerCase().indexOf(t)===0){this._searchValue=t;return}this._setNewDateIfEmpty(),this._searchValue&&(this._clearSearchValue(),this._searchString(i))},_clearSearchValue(){this._searchValue=""},_revertPart(i){if(!this._isAllSelected()){let e=this._getActivePartValue(this.option("emptyDateValue"));this._setActivePartValue(e),this._selectNextPart(i)}this._clearSearchValue()},_useMaskBehavior(){return this.option("useMaskBehavior")&&this.option("mode")==="text"},_prepareRegExpInfo(){this._regExpInfo=tb(this._getFormatPattern(),de);let{regexp:i}=this._regExpInfo,{source:e}=i,{flags:t}=i,n=new RegExp(/(\{[0-9]+,?[0-9]*\})/),o=e.split(n).map(s=>n.test(s)?s:ze.convertDigits(s,!1)).join("");this._regExpInfo.regexp=new RegExp(o,t)},_initMaskState(){this._activePartIndex=0,this._formatPattern=null,this._prepareRegExpInfo(),this._loadMaskValue()},_renderMask(){this.callBase(),this._detachMaskEvents(),this._clearMaskState(),this._useMaskBehavior()&&(this._attachMaskEvents(),this._initMaskState(),this._renderDateParts())},_renderDateParts(){if(!this._useMaskBehavior())return;let i=this.option("text")||this._getDisplayedText(this._maskValue);i&&(this._dateParts=fB(i,this._regExpInfo),this._input().is(":hidden")||this._selectNextPart())},_detachMaskEvents(){_.off(this._input(),".dateBoxMask")},_attachMaskEvents(){_.on(this._input(),D("dxclick","dateBoxMask"),this._maskClickHandler.bind(this)),_.on(this._input(),D("paste","dateBoxMask"),this._maskPasteHandler.bind(this)),_.on(this._input(),D("drop","dateBoxMask"),()=>{this._renderSelectedPart()}),_.on(this._input(),D("compositionend","dateBoxMask"),this._maskCompositionEndHandler.bind(this)),this._useBeforeInputEvent()&&_.on(this._input(),D("beforeinput","dateBoxMask"),this._maskBeforeInputHandler.bind(this))},_renderSelectedPart(){this._renderDisplayText(this._getDisplayedText(this._maskValue)),this._selectNextPart()},_selectLastPart(){this.option("text")&&(this._activePartIndex=this._dateParts.length,this._selectNextPart(-1))},_selectFirstPart(){this.option("text")&&this._dateParts&&(this._activePartIndex=-1,this._selectNextPart(1))},_onMouseWheel(i){this._useMaskBehavior()&&this._partIncrease(i.delta>0?1:-1,i)},_selectNextPart(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;if(!this.option("text")||this._disposed)return;i&&(this._initialMaskValue=new Date(this._maskValue));let e=ft(this._activePartIndex+i,0,this._dateParts.length-1);if(this._dateParts[e].isStub){if(!(e===0&&i<0||e===this._dateParts.length-1&&i>0)){this._selectNextPart(i>=0?i+1:i-1);return}e=this._activePartIndex}this._activePartIndex!==e&&this._clearSearchValue(),this._activePartIndex=e,this._caret(this._getActivePartProp("caret"))},_getRealLimitsPattern(){if(this._getActivePartProp("pattern")[0]==="d")return"dM"},_getActivePartLimits(i){return this._getActivePartProp("limits")(this._maskValue,i&&this._getRealLimitsPattern())},_getActivePartValue(i){i=i||this._maskValue;let e=this._getActivePartProp("getter");return A(e)?e(i):i[e]()},_addLeadingZeroes(i){let e=this._searchValue.match(/^0+/),t=this._getActivePartLimits(),n=String(t.max).length;return((e&&e[0]||"")+String(i)).substr(-n)},_setActivePartValue(i,e){e=e||this._maskValue;let t=this._getActivePartProp("setter"),n=this._getActivePartLimits();i=fn(i,n.min,n.max)?i:i%10,i=this._addLeadingZeroes(ft(i,n.min,n.max)),A(t)?t(e,i):e[t](i),this._renderDisplayText(this._getDisplayedText(e)),this._renderDateParts()},_getActivePartProp(i){if(!(!this._dateParts||!this._dateParts[this._activePartIndex]))return this._dateParts[this._activePartIndex][i]},_loadMaskValue(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.dateOption("value");this._maskValue=i&&new Date(i),this._initialMaskValue=i&&new Date(i)},_saveMaskValue(){let i=this._maskValue&&new Date(this._maskValue);i&&this.option("type")==="date"&&i.setHours(0,0,0,0),this._initialMaskValue=new Date(i),this.dateOption("value",i)},_revertChanges(){this._loadMaskValue(),this._renderDisplayText(this._getDisplayedText(this._maskValue)),this._renderDateParts()},_renderDisplayText(i){this.callBase(i),this._useMaskBehavior()&&this.option("text",i)},_partIncrease(i,e){this._setNewDateIfEmpty();let{max:t,min:n}=this._getActivePartLimits(e),o=i+this._getActivePartValue();o>t?o=this._applyLimits(o,{limitBase:n,limitClosest:t,max:t}):o<n&&(o=this._applyLimits(o,{limitBase:t,limitClosest:n,max:t})),this._setActivePartValue(o)},_applyLimits(i,e){let{limitBase:t,limitClosest:n,max:o}=e,s=(i-n)%o;return s?t+s-1*Co(s):n},_maskClickHandler(){this._loadMaskValue(this._maskValue),this.option("text")&&(this._activePartIndex=_B(this._dateParts,this._caret().start),this._isAllSelected()||(f(this._activePartIndex)?this._caret(this._getActivePartProp("caret")):this._selectLastPart()))},_maskCompositionEndHandler(i){this._input().val(this._getDisplayedText(this._maskValue)),this._selectNextPart(),this._maskInputHandler=()=>{this._renderSelectedPart()}},_maskPasteHandler(i){let e=this._replaceSelectedText(this.option("text"),this._caret(),ec(i)),t=de.parse(e,this._getFormatPattern());t&&this._isDateValid(t)&&(this._maskValue=t,this._renderDisplayText(this._getDisplayedText(this._maskValue)),this._renderDateParts(),this._selectNextPart()),i.preventDefault()},_isDateValid:i=>Et(i)&&!isNaN(i),_isValueDirty(){let i=this.dateOption("value");return(this._maskValue&&this._maskValue.getTime())!==(i&&i.getTime())},_fireChangeEvent(){this._clearSearchValue(),this._isValueDirty()&&_.trigger(this._input(),"change")},_enterHandler(){this._fireChangeEvent(),this._selectNextPart(1)},_focusOutHandler(i){this._useMaskBehavior()&&!i.isDefaultPrevented()?(this._fireChangeEvent(),this.callBase(i),this._selectFirstPart(i)):this.callBase(i)},_valueChangeEventHandler(i){let e=this.option("text");this._useMaskBehavior()?(this._saveValueChangeEvent(i),e?this._maskValue===null&&this._loadMaskValue(e):this._maskValue=null,this._saveMaskValue()):this.callBase(i)},_optionChanged(i){switch(i.name){case"useMaskBehavior":this._renderMask();break;case"displayFormat":case"mode":this.callBase(i),this._renderMask();break;case"value":this._loadMaskValue(),this.callBase(i),this._renderDateParts();break;case"emptyDateValue":break;default:this.callBase(i)}},_clearMaskState(){this._clearSearchValue(),delete this._dateParts,delete this._activePartIndex,delete this._maskValue},clear(){this._clearMaskState(),this._activePartIndex=0,this.callBase()},_clean(){this.callBase(),this._detachMaskEvents(),this._clearMaskState()}}),Ny=$6;G("dxDateBox",Ny);var CB=Ny;var um=CB;var{isWrapped:z6}=It;var W6="dx-editor-inline-block",bu=function(i,e){return m(i,{readOnly:e.readOnly,placeholder:e.placeholder,inputAttr:{id:e.id,"aria-labelledby":e["aria-labelledby"]},tabIndex:e.tabIndex},e.editorOptions)},yB=function(){return be.mozilla||F.real().ios},OB=function(i){let e={},t=yB(),n=i.sharedData||e;return bu({placeholder:i.placeholder,width:i.width,value:i.value,onValueChanged:function(o){let s=i.parentType==="filterRow"||i.parentType==="searchPanel",r=o.event&&(o.event.type==="input"||o.event.type==="keyup"),a=function(l,d){i&&i.setValue(l.value,d)};clearTimeout(e.valueChangeTimeout),r&&s?n.valueChangeTimeout=e.valueChangeTimeout=setTimeout(function(){a(o,e.valueChangeTimeout!==n.valueChangeTimeout)},f(i.updateValueTimeout)?i.updateValueTimeout:0):a(o)},onKeyDown:function(o){t&&De(o.event)==="enter"&&_.trigger(u(o.component._input()),"change")},valueChangeEvent:"change"+(i.parentType==="filterRow"?" keyup input":"")},i)},xB=function(i){i.editorName="dxDateBox",i.editorOptions=bu({value:i.value,onValueChanged:function(e){i.setValue(e.value)},onKeyDown:function(e){let{component:t,event:n}=e,o=t.option("useMaskBehavior");(yB()||o)&&De(n)==="enter"&&(t.blur(),t.focus())},displayFormat:i.format,type:i.dataType,dateSerializationFormat:null,width:i.parentType==="filterBuilder"?void 0:"auto"},i)},vB=function(i){let e=OB(i),t=i.parentType==="searchPanel";i.editorType&&i.editorType!=="dxTextBox"?e.value=i.value:e.value=(n=i.value,f(n)?n.toString():"");var n;e.valueChangeEvent+=t?" keyup input search":"",e.mode=e.mode||(t?"search":"text"),i.editorName="dxTextBox",i.editorOptions=e},bB=function(i){let e=OB(i);e.value=f(i.value)?i.value:null,i.editorName="dxNumberBox",i.editorOptions=e},G6=function(i){i.parentType==="filterRow"||i.parentType==="filterBuilder"?SB(m(i,{lookup:{displayExpr:function(e){if(e===!0)return i.trueText||"true";if(e===!1)return i.falseText||"false"},dataSource:[!0,!1]}})):EB(i)};function K6(i){if(i.row&&i.row.watch&&i.parentType==="dataRow"){let e=i.editorOptions||{};i.editorOptions=e;let t,n=e.onInitialized;e.onInitialized=function(r){n&&n.apply(this,arguments),t=r.component,t.on("disposing",s)};let o,s=i.row.watch(()=>(o=i.lookup.dataSource(i.row),o&&o.filter),()=>{t.option("dataSource",o)},r=>{i.row=r})}}function SB(i){let e=i.lookup,t,n,o,s=i.parentType==="filterRow";if(e){t=me(e.displayExpr),n=e.dataSource,A(n)&&!z6(n)&&(n=n(i.row||{}),K6(i)),($(n)||Array.isArray(n))&&(n=Yi(n),s&&(o=n.postProcess,n.postProcess=function(a){return this.pageIndex()===0&&(a=a.slice(0),a.unshift(null)),o?o.call(this,a):a}));let r=!!(e.allowClearing&&!s);i.editorName=i.editorType??"dxSelectBox",i.editorOptions=bu({searchEnabled:!0,value:i.value,valueExpr:i.lookup.valueExpr,searchExpr:i.lookup.searchExpr||i.lookup.displayExpr,allowClearing:r,showClearButton:r,displayExpr:function(a){return a===null?i.showAllText:t(a)},dataSource:n,onValueChanged:function(a){let l=[a.value];!s&&l.push(a.component.option("text")),i.setValue.apply(this,l)}},i)}}function EB(i){i.editorName="dxCheckBox",i.editorOptions=bu({elementAttr:{id:i.id},value:f(i.value)?i.value:void 0,hoverStateEnabled:!i.readOnly,focusStateEnabled:!i.readOnly,activeStateEnabled:!1,onValueChanged:function(e){i.setValue&&i.setValue(e.value,e)}},i)}var U6=function(i,e){let t=u(e.editorElement);if(e.editorName&&e.editorOptions&&t[e.editorName]){if((e.editorName==="dxCheckBox"||e.editorName==="dxSwitch")&&(e.isOnForm||(t.addClass(i.addWidgetPrefix("checkbox-size")),t.parent().addClass(W6))),i._createComponent(t,e.editorName,e.editorOptions),e.editorName==="dxDateBox"){let n=t.dxDateBox("instance"),o=n._supportedKeys().enter;n.registerKeyHandler("enter",s=>(n.option("opened")&&o(s),!0))}e.editorName==="dxTextArea"&&t.dxTextArea("instance").registerKeyHandler("enter",function(n){De(n)==="enter"&&!n.ctrlKey&&!n.shiftKey&&n.stopPropagation()})}},j6=i=>{i.editorName=i.editorType,i.editorOptions=bu({value:i.value,onValueChanged:function(e){i.setValue(e.value)}},i)},q6=i=>{let e={dxDateBox:xB,dxCheckBox:EB,dxNumberBox:bB,dxTextBox:vB};if(i.lookup)SB(i);else if(i.editorType)(e[i.editorType]??j6)(i);else switch(i.dataType){case"date":case"datetime":xB(i);break;case"boolean":G6(i);break;case"number":bB(i);break;default:vB(i)}},Y6=i=>class extends i{createEditor(e,t){t.cancel=!1,t.editorElement=N(e),f(t.tabIndex)||(t.tabIndex=this.option("tabIndex")),q6(t),this.executeAction("onEditorPreparing",t),!t.cancel&&(t.parentType==="dataRow"&&!t.isOnForm&&!f(t.editorOptions.showValidationMark)&&(t.editorOptions.showValidationMark=!1),U6(this,t),this.executeAction("onEditorPrepared",t))}},hm=Y6;var X6="dx-editor-inline-block";var IB="dxDataGridEditorFactory",wB=D([ne.down,"focusin",oe].join(" "),IB),Hy="dx-hidden",Q6=hm(Ce.ViewController),$y=class extends Q6{init(){this.createAction("onEditorPreparing",{excludeValidators:["disabled","readOnly"],category:"rendering"}),this.createAction("onEditorPrepared",{excludeValidators:["disabled","readOnly"],category:"rendering"}),this._columnsResizerController=this.getController("columnsResizer"),this._editingController=this.getController("editing"),this._keyboardNavigationController=this.getController("keyboardNavigation"),this._columnsController=this.getController("columns"),this._validatingController=this.getController("validating"),this._rowsView=this.getView("rowsView"),this._updateFocusHandler=this._updateFocusHandler||this.createAction(this._updateFocus.bind(this)),this._subscribedContainerRoot=this._getContainerRoot(),_.on(this._subscribedContainerRoot,wB,this._updateFocusHandler),this._attachContainerEventHandlers()}dispose(){clearTimeout(this._focusTimeoutID),clearTimeout(this._updateFocusTimeoutID),_.off(this._subscribedContainerRoot,wB,this._updateFocusHandler)}_getFocusedElement(e){let n=["td[tabindex]:focus",`${this.option("focusedRowEnabled")?"tr[tabindex]:focus":"tr[tabindex]:not(.dx-data-row):focus"}`,"input:focus","button:focus","textarea:focus","div[tabindex]:focus",".dx-lookup-field:focus",".dx-checkbox:focus",".dx-switch:focus",".dx-dropdownbutton .dx-buttongroup:focus",".dx-adaptive-item-text:focus"].join(","),o=e.find(n);return this.elementIsInsideGrid(o)&&o}_getFocusCellSelector(){return".dx-row > td"}_updateFocusCore(){let e=this.component&&this.component.$element();if(e){let t=this._getFocusedElement(e);if(t&&t.length){let n;if(!t.hasClass("dx-cell-focus-disabled")&&!t.hasClass("dx-row")){let o=t.closest(`${this._getFocusCellSelector()}, .dx-cell-focus-disabled`);o.get(0)!==t.get(0)&&(n=this._needHideBorder(o),t=o)}if(t.length&&!t.hasClass("dx-cell-focus-disabled")){this.focus(t,n);return}}}this.loseFocus()}_needHideBorder(e){let t=this._rowsView.element(),n=e.closest(t).length>0,o=this._editingController.isEditing();return e.hasClass(X6)||n&&!o}_updateFocus(e){let t=this,n=e&&e.event&&u(e.event.target).hasClass(t.addWidgetPrefix("focus-overlay"));t._isFocusOverlay=t._isFocusOverlay||n,clearTimeout(t._updateFocusTimeoutID),t._updateFocusTimeoutID=setTimeout(()=>{delete t._updateFocusTimeoutID,t._isFocusOverlay||t._updateFocusCore(),t._isFocusOverlay=!1})}_updateFocusOverlaySize(e,t){e.hide();let n=lt.calculate(e,m({collision:"fit"},t));n.h.oversize>0&&Wd(e,ie(e)-n.h.oversize),n.v.oversize>0&&Kf(e,X(e)-n.v.oversize),e.show()}callbackNames(){return["focused"]}focus(e,t){let n=this;if(e===void 0)return n._$focusedElement;e&&(e.is(n._$focusedElement)||n._$focusedElement&&n._$focusedElement.removeClass("dx-focused"),n._$focusedElement=e,clearTimeout(n._focusTimeoutID),n._focusTimeoutID=setTimeout(()=>{delete n._focusTimeoutID,n.renderFocusOverlay(e,t),e.addClass("dx-focused"),n.focused.fire(e)}))}refocus(){let e=this.focus();this.focus(e)}renderFocusOverlay(e,t){let n=this;if(M.isElementInCurrentGrid(this,e)){if(n._$focusOverlay||(n._$focusOverlay=u("<div>").addClass(n.addWidgetPrefix("focus-overlay"))),t)n._$focusOverlay.addClass(Hy);else if(e.length){let o=be.mozilla?"right bottom":"left top",s=e.closest(`.${n.addWidgetPrefix("content")}`),r=Ie(e.get(0)),a=e.hasClass(this.addWidgetPrefix("invalid")),l=e.hasClass("dx-cell-modified")&&!a;n._$focusOverlay.removeClass(Hy).toggleClass("dx-focused-cell-invalid",a).toggleClass("dx-focused-cell-modified",l).appendTo(s),Kf(n._$focusOverlay,r.bottom-r.top+1),Wd(n._$focusOverlay,r.right-r.left+1);let d={precise:!0,my:o,at:o,of:e,boundary:s.length&&s};n._updateFocusOverlaySize(n._$focusOverlay,d),lt.setup(n._$focusOverlay,d),n._$focusOverlay.css("visibility","visible")}}}resize(){let e=this._$focusedElement;e&&this.focus(e)}loseFocus(e){this._$focusedElement&&this._$focusedElement.removeClass("dx-focused"),this._$focusedElement=null,this._$focusOverlay&&this._$focusOverlay.addClass(Hy)}_getContainerRoot(){var e;let t=(e=this.component)===null||e===void 0?void 0:e.$element(),n=w.getRootNode(t?.get(0));return n.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&!n.host?w.getDocument():n}_attachContainerEventHandlers(){let e=this,t=e.component&&e.component.$element();t&&_.on(t,D("keydown",IB),n=>{De(n)==="tab"&&e._updateFocusHandler(n)})}},DB={defaultOptions:()=>({}),controllers:{editorFactory:$y}};H.registerModule("editorFactory",DB);var pm=K(),Z6={text:"OK",onClick:()=>!0};var J6=()=>ut()?{stylingMode:"contained",type:"default"}:{},eQ=()=>ut()?{stylingMode:"outlined",type:"default"}:{},TB=function(i){let e=y();i=i||{};let t=u("<div>").addClass("dx-dialog").appendTo(Sn()),n="message"in i,o="messageHtml"in i;n&&Z.log("W1013");let s=String(o?i.messageHtml:i.message),r=i.title?null:new Oe,a=u("<div>").addClass("dx-dialog-message").html(s).attr("id",r),l=[],d=new ii(t,m({title:i.title??"",showTitle:Te(i.showTitle,!0),dragEnabled:Te(i.dragEnabled,!0),height:"auto",width:i.width,showCloseButton:i.showCloseButton||!1,ignoreChildEvents:!1,container:t,visualContainer:pm,dragAndResizeArea:pm,onContentReady(p){p.component.$content().addClass("dx-dialog-content").append(a),r&&p.component.$overlayContent().attr("aria-labelledby",r)},onShowing(p){p.component.bottomToolbar().addClass("dx-dialog-buttons").find(".dx-button").addClass("dx-dialog-button"),zn()},onShown(p){let g=p.component.bottomToolbar().find(".dx-button").first();_.trigger(g,"focus")},onHiding(){e.reject()},onHidden(p){let{element:g}=p;u(g).remove()},animation:{show:{type:"pop",duration:400},hide:{type:"pop",duration:400,to:{opacity:0,scale:0},from:{opacity:1,scale:1}}},rtlEnabled:fe().rtlEnabled,position:{boundaryOffset:{h:10,v:0}}},i.popupOptions));(i.buttons||[Z6]).forEach(p=>{let g=new po(p.onClick,{context:d});l.push({toolbar:"bottom",location:F.current().android?"after":"center",widget:"dxButton",options:I({},p,{onClick(){let C=g.execute(...arguments);h(C)}})})}),d.option("toolbarItems",l),d.$wrapper().addClass("dx-dialog-wrapper"),i.position&&d.option("position",i.position),d.$wrapper().addClass("dx-dialog-root");function h(p){e.resolve(p),d.hide()}return{show:function(){if(F.real().deviceType==="phone"){let g=Y(pm)>z(pm)?"90%":"60%";d.option({width:g})}return d.show(),e.promise()},hide:h}};var zy=function(i){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",t=arguments.length>2?arguments[2]:void 0,n=q(i)?i:{title:e,messageHtml:i,showTitle:t,buttons:[I({text:O.format("Yes"),onClick:()=>!0},J6()),I({text:O.format("No"),onClick:()=>!1},eQ())],dragEnabled:t};return TB(n).show()};var Vr="dx-editor-cell",So="dx-row",AB="dx-cell-modified",Wy="dx-selection",cd="edit-form",Mn="insert",Eo="remove",ud="editing.popup",gm="editing.form",zi="editing.editRowKey",Ws="editing.editColumnName",mm="targetComponent",yu="input:not([type='hidden'])",hd=`[tabindex]:not([disabled]), ${yu}:not([disabled])`,Ou="batch",Lr="row",Su="cell",Eu="form",MB="popup",Gy="first",wu="last",Ky="pageBottom",fm="pageTop",Uy="viewportBottom",jy="viewportTop",RB=["batch","row","cell","form","popup"],FB=["row","form","popup"],PB=["batch","cell"],kB=["batch","row","cell"],BB=["row","form"],VB="readonly",LB="dx-link",NB="dx-link-icon",HB="dx-selection",$B="dx-edit-button",zB="dx-command-edit",qy="dx-command-edit-with-icons",Gs="__DX_INSERT_INDEX__",WB="dx-row-inserted",GB="dx-row-modified",Yy="dx-cell-modified",KB="dxDataGridEditing",UB="dx-cell-focus-disabled",pd="update",jB="click",qB={save:"dx-link-save",cancel:"dx-link-cancel",edit:"dx-link-edit",undelete:"dx-link-undelete",delete:"dx-link-delete",add:"dx-link-add"},YB={save:"save",cancel:"revert",edit:"edit",undelete:"revert",delete:"trash",add:"add"},XB={edit:"editRow",delete:"deleteRow",undelete:"undeleteRow",save:"saveEditData",cancel:"cancelEditData",add:"addRowByRowIndex"},QB={add:"allowAdding",edit:"allowUpdating",delete:"allowDeleting"},ZB=["edit","save","cancel","delete","undelete"],ns="editing.changes",JB="focus-overlay",eV="addrow-button",tV="dx-dropdowneditor-overlay",iV="dx-data-row",nV="dx-row-removed",oV="filter-row",tQ=!!Pi.IS_RENOVATED_WIDGET,Xy="edit-form-item",sV="edit-popup",rV="edit-popup-form",aV=tQ?"dx-scrollable":"dx-scrollable-container",lV="dx-button",dV="form-buttons-container",Qy="dx-edit-row";var gd=function(i){return function(e){let t=e instanceof Error?e:new Error(e&&String(e)||"Unknown error");i.reject(t)}},Zy=function(i,e){return e.isEditing||i&&e.column.allowEditing},Jy=function(i,e){let t=!!e.column.command,n=Zy(i,e),o=!t&&(n||e.column.showEditorAlways);return e.rowType==="data"&&o},cV=i=>{let e=i.component.option("editing.texts")||{};return{save:e.saveRowChanges,cancel:e.cancelRowChanges,edit:e.editRow,undelete:e.undeleteRow,delete:e.deleteRow,add:e.addRowToNode}},uV=()=>`_DX_KEY_${new Oe}`,hV=i=>typeof i=="string"&&i.startsWith("_DX_KEY_")&&i.length===44,Ea=(i,e)=>{let t=-1;return i.some((n,o)=>{if(eO(n)===e)return t=o,!0}),t};function eO(i){return $(i)?i.name:i}function pV(i){return i&&(i.is("input")||i.is("textarea"))}var gV=i=>{var e;let{column:t}=i;return i.isCustomEditorType?i.editorType:(e=t.formItem)===null||e===void 0?void 0:e.editorType},tO=(i,e)=>{i.forEach(t=>{t.items||t.tabs?tO(t.items||t.tabs,e):e(t)})};var iO=class extends Ce.ViewController{init(){this._columnsController=this.getController("columns"),this._dataController=this.getController("data"),this._adaptiveColumnsController=this.getController("adaptiveColumns"),this._validatingController=this.getController("validating"),this._editorFactoryController=this.getController("editorFactory"),this._focusController=this.getController("focus"),this._keyboardNavigationController=this.getController("keyboardNavigation"),this._columnsResizerController=this.getController("columnsResizer"),this._errorHandlingController=this.getController("errorHandling"),this._rowsView=this.getView("rowsView"),this._headerPanelView=this.getView("headerPanel"),this._lastOperation=null,this._changes=[],this._deferreds&&this._deferreds.forEach(e=>{e.reject("cancel")}),this._deferreds=[],this._dataChangedHandler||(this._dataChangedHandler=this._handleDataChanged.bind(this),this._dataController.changed.add(this._dataChangedHandler)),this._saveEditorHandler||(this.createAction("onInitNewRow",{excludeValidators:["disabled","readOnly"]}),this.createAction("onRowInserting",{excludeValidators:["disabled","readOnly"]}),this.createAction("onRowInserted",{excludeValidators:["disabled","readOnly"]}),this.createAction("onEditingStart",{excludeValidators:["disabled","readOnly"]}),this.createAction("onRowUpdating",{excludeValidators:["disabled","readOnly"]}),this.createAction("onRowUpdated",{excludeValidators:["disabled","readOnly"]}),this.createAction("onRowRemoving",{excludeValidators:["disabled","readOnly"]}),this.createAction("onRowRemoved",{excludeValidators:["disabled","readOnly"]}),this.createAction("onSaved",{excludeValidators:["disabled","readOnly"]}),this.createAction("onSaving",{excludeValidators:["disabled","readOnly"]}),this.createAction("onEditCanceling",{excludeValidators:["disabled","readOnly"]}),this.createAction("onEditCanceled",{excludeValidators:["disabled","readOnly"]})),this._updateEditColumn(),this._updateEditButtons(),this._internalState||(this._internalState=new Map),this.component._optionsByReference[zi]=!0,this.component._optionsByReference[ns]=!0}getEditMode(){let e=this.option("editing.mode")??Lr;return RB.includes(e)?e:Lr}isCellBasedEditMode(){let e=this.getEditMode();return PB.includes(e)}_getDefaultEditorTemplate(){return(e,t)=>{let n=u("<div>").appendTo(e),o=m({},t.column,{value:t.value,setValue:t.setValue,row:t.row,parentType:"dataRow",width:null,readOnly:!t.setValue,isOnForm:t.isOnForm,id:t.id});kB.includes(this.getEditMode())&&(o["aria-labelledby"]=t.column.headerId),this._editorFactoryController.createEditor(n,o)}}_getNewRowPosition(){let e=this.option("editing.newRowPosition");if(this.option("scrolling.mode")==="virtual")switch(e){case fm:return jy;case Ky:return Uy;default:return e}return e}getChanges(){return this.option(ns)}getInsertRowCount(){return this.option(ns).filter(t=>t.type==="insert").length}resetChanges(){let e=this.getChanges();e?.length&&this._silentOption(ns,[])}_getInternalData(e){return this._internalState.get(ai(e))}_addInternalData(e){let t=this._getInternalData(e.key);return t?m(t,e):(this._internalState.set(ai(e.key),e),e)}_getOldData(e){var t;return(t=this._getInternalData(e))===null||t===void 0?void 0:t.oldData}getUpdatedData(e){let t=this._dataController.keyOf(e),n=this.getChanges(),o=M.getIndexByKey(t,n);return n[o]?ho(e,n[o].data):e}getInsertedData(){return this.getChanges().filter(e=>e.data&&e.type===Mn).map(e=>e.data)}getRemovedData(){return this.getChanges().filter(e=>this._getOldData(e.key)&&e.type===Eo).map(e=>this._getOldData(e.key))}_fireDataErrorOccurred(e){if(e==="cancel")return;let t=this.getPopupContent();this._dataController.dataErrorOccurred.fire(e,t)}_needToCloseEditableCell(e){}_closeEditItem(e){}_handleDataChanged(e){}_isDefaultButtonVisible(e,t){let n=!0;switch(e.name){case"delete":n=this.allowDeleting(t);break;case"undelete":n=!1}return n}isPopupEditMode(){return this.option("editing.mode")===MB}_isButtonVisible(e,t){let{visible:n}=e;return f(n)?A(n)?n.call(e,{component:t.component,row:t.row,column:t.column}):n:this._isDefaultButtonVisible(e,t)}_isButtonDisabled(e,t){let{disabled:n}=e;return A(n)?n.call(e,{component:t.component,row:t.row,column:t.column}):!!n}_getButtonConfig(e,t){let n=$(e)?e:{},o=eO(e),s=cV(t),r=XB[o],a=this.option("editing"),l=QB[o],d=l?a[l]:!0;return m({name:o,text:s[o],cssClass:qB[o]},{onClick:r&&(c=>{let{event:h}=c;h.stopPropagation(),h.preventDefault(),setTimeout(()=>{t.row&&d&&this[r]&&this[r](t.row.rowIndex)})})},n)}_getEditingButtons(e){let t,n=!!e.column.buttons,o=(e.column.buttons||[]).slice();return n?(t=Ea(o,"edit"),t>=0&&(Ea(o,"save")<0&&o.splice(t+1,0,"save"),Ea(o,"cancel")<0&&o.splice(Ea(o,"save")+1,0,"cancel")),t=Ea(o,"delete"),t>=0&&Ea(o,"undelete")<0&&o.splice(t+1,0,"undelete")):o=ZB.slice(),o.map(s=>this._getButtonConfig(s,e))}_renderEditingButtons(e,t,n,o){t.forEach(s=>{this._isButtonVisible(s,n)&&this._createButton(e,s,n,o)})}_getEditCommandCellTemplate(){return(e,t,n)=>{let o=u(e);if(t.rowType==="data"){let s=this._getEditingButtons(t);if(this._renderEditingButtons(o,s,t,n),t.watch){let r=t.watch(()=>s.map(a=>({visible:this._isButtonVisible(a,t),disabled:this._isButtonDisabled(a,t)})),()=>{o.empty(),this._renderEditingButtons(o,s,t)});_.on(o,Gt,r)}}else M.setEmptyText(o)}}isRowBasedEditMode(){let e=this.getEditMode();return FB.includes(e)}getFirstEditableColumnIndex(){let e,t=this._columnsController.getVisibleColumns();return x(t,(n,o)=>{if(o.allowEditing)return e=n,!1}),e}getFirstEditableCellInRow(e){var t;let n=this.getFirstEditableColumnIndex();return(t=this._rowsView)===null||t===void 0?void 0:t._getCellElement(e||0,n)}getFocusedCellInRow(e){return this.getFirstEditableCellInRow(e)}getIndexByKey(e,t){return M.getIndexByKey(e,t)}hasChanges(e){let t=this.getChanges(),n=!1;for(let o=0;o<t?.length;o++)if(t[o].type&&(!f(e)||this._dataController.getRowIndexByKey(t[o].key)===e)){n=!0;break}return n}dispose(){super.dispose(),clearTimeout(this._inputFocusTimeoutID),_.off(w.getDocument(),ne.up,this._pointerUpEditorHandler),_.off(w.getDocument(),ne.down,this._pointerDownEditorHandler),_.off(w.getDocument(),oe,this._saveEditorHandler)}_silentOption(e,t){e==="editing.changes"&&(this._changes=Bi([],t)),super._silentOption(e,t)}optionChanged(e){if(e.name==="editing"){let{fullName:t}=e;t===zi?this._handleEditRowKeyChange(e):t===ns?ve(e.value,this._changes,{maxDepth:4})||(this._changes=Bi([],e.value),this._handleChangesChange(e)):e.handled||(this._columnsController.reinit(),this.init(),this.resetChanges(),this._resetEditColumnName(),this._resetEditRowKey()),e.handled=!0}else super.optionChanged(e)}_handleEditRowKeyChange(e){let t=this._dataController.getRowIndexByKey(e.value),n=this._getEditRowIndexCorrection(),o=this._dataController.getRowIndexByKey(e.previousValue)+n;f(e.value)?e.value!==e.previousValue&&this._editRowFromOptionChanged(t,o):this.cancelEditData()}_handleChangesChange(e){let t=this._dataController,n=e.value;!e.value.length&&!e.previousValue.length||(n.forEach(o=>{if(o.type==="insert")this._addInsertInfo(o);else{var s;let r=t.getCachedStoreData()||((s=t.items())===null||s===void 0?void 0:s.map(l=>l.data)),a=M.getIndexByKey(o.key,r,t.key());this._addInternalData({key:o.key,oldData:r[a]})}}),t.updateItems({repaintChangesOnly:!0,isLiveUpdate:!1,isOptionChanged:!0}))}publicMethods(){return["addRow","deleteRow","undeleteRow","editRow","saveEditData","cancelEditData","hasEditData"]}refresh(){f(this._pageIndex)&&this._refreshCore.apply(this,arguments)}_refreshCore(e){}isEditing(){return f(this.option(zi))}isEditRow(e){return!1}_setEditRowKey(e,t){t?this._silentOption(zi,e):this.option(zi,e),this._refocusEditCell&&(this._refocusEditCell=!1,this._focusEditingCell())}_setEditRowKeyByIndex(e,t){let n=this._dataController.getKeyByRowIndex(e);if(n===void 0){this._dataController.fireError("E1043");return}this._setEditRowKey(n,t)}getEditRowIndex(){return this._getVisibleEditRowIndex()}getEditFormRowIndex(){return-1}isEditRowByIndex(e){let t=this._dataController.getKeyByRowIndex(e),n=f(t)&&ve(this.option(zi),t);return n&&this._getVisibleEditRowIndex()===e}isEditCell(e,t){return this.isEditRowByIndex(e)&&this._getVisibleEditColumnIndex()===t}getPopupContent(){}_isProcessedItem(e){return!1}_getInsertRowIndex(e,t,n){let o=-1,s=this._dataController,r=this._getInsertAfterOrBeforeKey(t);return!f(r)&&e.length===0?o=0:f(r)&&e.some((a,l)=>{let d=n||this._isProcessedItem(a);if($(a)&&(d||f(a[Gs])?ve(a.key,r)&&(o=l):ve(s.keyOf(a),r)&&(o=l)),o>=0){let c=e[o+1];return c&&(c.rowType==="detail"||c.rowType==="detailAdaptive")&&f(t.insertAfterKey)?void 0:(f(t.insertAfterKey)&&(o+=1),!0)}}),o}_generateNewItem(e){var t;let n={key:e},o=(t=this._getInternalData(e))===null||t===void 0?void 0:t.insertInfo;return o!=null&&o[Gs]&&(n[Gs]=o[Gs]),n}_getLoadedRowIndex(e,t,n){let o=this._getInsertRowIndex(e,t,n),s=this._dataController;if(o<0){let r=this._getNewRowPosition(),a=s.pageIndex(),l=this._getInsertAfterOrBeforeKey(t);r!==wu&&a===0&&!f(l)?o=0:r===wu&&s.isLastPageLoaded()&&(o=e.length)}return o}processItems(e,t){let{changeType:n}=t;return this.update(n),this.getChanges().forEach(s=>{var r;if(!(s.type===Mn))return;let{key:l}=s,d=(r=this._getInternalData(l))===null||r===void 0?void 0:r.insertInfo;(!f(l)||!f(d))&&(d=this._addInsertInfo(s),l=d.key);let c=this._getLoadedRowIndex(e,s),h=this._generateNewItem(l);c>=0&&e.splice(c,0,h)}),e}processDataItem(e,t,n){let o=t.visibleColumns,s=e.data[Gs]?e.data.key:e.key,r=this.getChanges(),a=M.getIndexByKey(s,r);e.isEditing=!1,a>=0&&this._processDataItemCore(e,r[a],s,o,n)}_processDataItemCore(e,t,n,o,s){let{data:r,type:a}=t;switch(a){case Mn:e.isNewRow=!0,e.key=n,e.data=r;break;case pd:e.modified=!0,e.oldData=e.data,e.data=ho(e.data,r),e.modifiedValues=s(r,o,!0);break;case Eo:e.removed=!0}}_initNewRow(e){if(this.executeAction("onInitNewRow",e),e.promise){let t=new y;return P(ht(e.promise)).done(t.resolve).fail(gd(t)).fail(n=>this._fireDataErrorOccurred(n)),t}}_createInsertInfo(){let e={};return e[Gs]=this._getInsertIndex(),e}_addInsertInfo(e,t){var n;let o;e.key=this.getChangeKeyValue(e);let{key:s}=e;if(o=(n=this._getInternalData(s))===null||n===void 0?void 0:n.insertInfo,!f(o)){let r=this._getInsertAfterOrBeforeKey(e);o=this._createInsertInfo(),f(r)||this._setInsertAfterOrBeforeKey(e,t)}return this._addInternalData({insertInfo:o,key:s}),{insertInfo:o,key:s}}getChangeKeyValue(e){if(f(e.key))return e.key;let t=this._dataController.key(),n;return e.data&&t&&!Array.isArray(t)&&(n=e.data[t]),f(n)||(n=uV()),n}_setInsertAfterOrBeforeKey(e,t){let n=this.getView("rowsView"),o=this._dataController,s=o.items(!0),r=this._getNewRowPosition();switch(r){case Gy:case wu:break;case fm:case Ky:if(s.length){let a=r===fm?0:s.length-1;e[a===0?"insertBeforeKey":"insertAfterKey"]=s[a].key}break;default:{let l=r===Uy?n?.getBottomVisibleItemIndex():n?.getTopVisibleItemIndex(),d=o.getVisibleRows()[l];d&&(!d.isEditing&&d.rowType==="detail"||d.rowType==="detailAdaptive")&&l++;let c=o.getKeyByRowIndex(l);f(c)&&(e.insertBeforeKey=c)}}}_getInsertIndex(){let e=0;return this.getChanges().forEach(t=>{var n;let o=(n=this._getInternalData(t.key))===null||n===void 0?void 0:n.insertInfo;f(o)&&t.type===Mn&&o[Gs]>e&&(e=o[Gs])}),e+1}_getInsertAfterOrBeforeKey(e){return e.insertAfterKey??e.insertBeforeKey}_getPageIndexToInsertRow(){let e=this._getNewRowPosition(),t=this._dataController,n=t.pageIndex(),o=t.pageCount()-1;return e===Gy&&n!==0?0:e===wu&&n!==o?o:-1}addRow(e){let t=this._dataController;return t.store()?this._addRow(e):(t.fireError("E1052",this.component.NAME),new y().reject())}_addRow(e){let n=this._dataController.store(),o=n&&n.key(),s={data:{}},r=this._getVisibleEditRowIndex(),a=new y;return this.refresh({allowCancelEditing:!0}),this._allowRowAdding()?(o||(s.data.__KEY__=String(new Oe)),P(this._initNewRow(s,e)).done(()=>{this._allowRowAdding()?P(this._addRowCore(s.data,e,r)).done(a.resolve).fail(a.reject):a.reject("cancel")}).fail(a.reject),a.promise()):(P(this._navigateToNewRow(r)).done(a.resolve).fail(a.reject),a.promise())}_allowRowAdding(e){return!(this._getInsertIndex()>1)}_addRowCore(e,t,n){let o={data:e,type:Mn},s=this._getVisibleEditRowIndex(),r=this._addInsertInfo(o,t),{key:a}=r;return this._setEditRowKey(a,!0),this._addChange(o),this._navigateToNewRow(n,o,s)}_navigateToNewRow(e,t,n){let o=new y,s=this._dataController;if(n=n??-1,t=t??this.getChanges().filter(c=>c.type===Mn)[0],!t)return o.reject("cancel").promise();let r=this._getPageIndexToInsertRow(),a=this._getLoadedRowIndex(s.items(),t,!0),l=c=>{var h;P((h=this._focusController)===null||h===void 0?void 0:h.navigateToRow(c)).done(()=>{a=s.getRowIndexByKey(t.key),o.resolve()})},d=this._getInsertAfterOrBeforeKey(t);return r>=0?s.pageIndex(r).done(()=>{l(t.key)}).fail(o.reject):a<0&&f(d)?l(d):(s.updateItems({changeType:"update",rowIndices:[e,n,a]}),a=s.getRowIndexByKey(t.key),a<0?l(t.key):o.resolve()),o.done(()=>{var c;(c=this._rowsView)===null||c===void 0||c.waitAsyncTemplates(!0).done(()=>{this._showAddedRow(a),this._afterInsertRow(t.key)})}),o.promise()}_showAddedRow(e){this._focusFirstEditableCellInRow(e)}_beforeFocusElementInRow(e){}_focusFirstEditableCellInRow(e){var t;let n=this._dataController,o=n.getKeyByRowIndex(e),s=this.getFirstEditableCellInRow(e);(t=this._keyboardNavigationController)===null||t===void 0||t.focus(s),this.option("focusedRowKey",o),this._editCellInProgress=!0,this._delayedInputFocus(s,()=>{e=n.getRowIndexByKey(o),this._editCellInProgress=!1,this._beforeFocusElementInRow(e)})}_isEditingStart(e){return this.executeAction("onEditingStart",e),e.cancel}_beforeUpdateItems(e,t){}_getVisibleEditColumnIndex(){let e=this.option(Ws);return f(e)?this._columnsController.getVisibleColumnIndex(e):-1}_setEditColumnNameByIndex(e,t){var n;let o=this._columnsController.getVisibleColumns();this._setEditColumnName((n=o[e])===null||n===void 0?void 0:n.name,t)}_setEditColumnName(e,t){t?this._silentOption(Ws,e):this.option(Ws,e)}_resetEditColumnName(){this._setEditColumnName(null,!0)}_getEditColumn(){let e=this.option(Ws);return this._getColumnByName(e)}_getColumnByName(e){let t=this._columnsController.getVisibleColumns(),n;return f(e)&&t.some(o=>{if(o.name===e)return n=o,!0}),n}_getVisibleEditRowIndex(e){let t=this._dataController,n=this.option(zi),o=t.getRowIndexByKey(n);return o===-1?o:o+this._getEditRowIndexCorrection(e)}_getEditRowIndexCorrection(e){let t=e?this._getColumnByName(e):this._getEditColumn();return t?.visibleWidth==="adaptiveHidden"?1:0}_resetEditRowKey(){this._refocusEditCell=!1,this._setEditRowKey(null,!0)}_resetEditIndices(){this._resetEditColumnName(),this._resetEditRowKey()}editRow(e){let t=this._dataController,o=t.items()[e],s={data:o&&o.data,cancel:!1},r=this._getVisibleEditRowIndex();if(o){if(e===r)return!0;if(o.key===void 0){this._dataController.fireError("E1043");return}o.isNewRow||(s.key=o.key),!this._isEditingStart(s)&&(this.resetChanges(),this.init(),this._resetEditColumnName(),this._pageIndex=t.pageIndex(),this._addInternalData({key:o.key,oldData:o.oldData??o.data}),this._setEditRowKey(o.key))}}_editRowFromOptionChanged(e,t){let n=[t,e];this._beforeUpdateItems(n,e,t),this._editRowFromOptionChangedCore(n,e)}_editRowFromOptionChangedCore(e,t,n){this._needFocusEditor=!0,this._dataController.updateItems({changeType:"update",rowIndices:e,cancel:n})}_focusEditorIfNeed(){}_showEditPopup(e,t){}_repaintEditPopup(){}_getEditPopupHiddenHandler(){return e=>{this.isEditing()&&this.cancelEditData()}}_getPopupEditFormTemplate(e){}_getSaveButtonConfig(){let e={text:this.option("editing.texts.saveRowChanges"),onClick:this.saveEditData.bind(this)};return ut(ct())&&(e.stylingMode="contained",e.type="default"),e}_getCancelButtonConfig(){let e={text:this.option("editing.texts.cancelRowChanges"),onClick:this.cancelEditData.bind(this)};return ut(ct())&&(e.stylingMode="outlined"),e}_removeInternalData(e){this._internalState.delete(ai(e))}_updateInsertAfterOrBeforeKeys(e,t){let n=e[t];e.forEach(o=>{if(o.type===Mn){let s=this._getInsertAfterOrBeforeKey(o);ve(s,n.key)&&(o[f(o.insertAfterKey)?"insertAfterKey":"insertBeforeKey"]=this._getInsertAfterOrBeforeKey(n))}})}_removeChange(e){if(e>=0){let t=[...this.getChanges()],{key:n}=t[e];this._removeInternalData(n),this._updateInsertAfterOrBeforeKeys(t,e),t.splice(e,1),this._silentOption(ns,t),ve(this.option(zi),n)&&this._resetEditIndices()}}executeOperation(e,t){this._lastOperation&&this._lastOperation.reject(),this._lastOperation=e,this.waitForDeferredOperations().done(()=>{e.state()!=="rejected"&&(t(),this._lastOperation=null)}).fail(()=>{e.reject(),this._lastOperation=null})}waitForDeferredOperations(){return P(...this._deferreds)}_processCanceledEditingCell(){}_repaintEditCell(e,t,n){!e||!e.showEditorAlways||t&&!t.showEditorAlways?(this._editCellInProgress=!0,this._needFocusEditor=!0,this._editorFactoryController.loseFocus(),this._dataController.updateItems({changeType:"update",rowIndices:[n,this._getVisibleEditRowIndex()]})):e!==t&&(this._needFocusEditor=!0,this._dataController.updateItems({changeType:"update",rowIndices:[]}))}_delayedInputFocus(e,t,n){let o=()=>{if(t&&t(),e){let s=e.find(hd).first();M.focusAndSelectElement(this,s)}this._beforeFocusCallback=null};F.real().ios||F.real().android?o():(this._beforeFocusCallback&&this._beforeFocusCallback(),clearTimeout(this._inputFocusTimeoutID),n&&(this._beforeFocusCallback=t),this._inputFocusTimeoutID=setTimeout(o))}_focusEditingCell(e,t,n){let o=this._getVisibleEditColumnIndex();t=t||this._rowsView&&this._rowsView._getCellElement(this._getVisibleEditRowIndex(),o),t&&this._delayedInputFocus(t,e,n)}deleteRow(e){this._checkAndDeleteRow(e)}_checkAndDeleteRow(e){let t=this.option("editing"),n=t?.texts,o=t?.confirmDelete,s=n?.confirmDeleteMessage,r=this._dataController.items()[e],a=!this.isEditing()||r.isNewRow;if(r&&a)if(!o||!s)this._deleteRowCore(e);else{let l=n&&n.confirmDeleteTitle,d=f(l)&&l.length>0;zy(s,l,d).done(c=>{c&&this._deleteRowCore(e)})}}_deleteRowCore(e){let n=this._dataController.items()[e],o=n&&n.key,s=this._getVisibleEditRowIndex();this.refresh();let r=this.getChanges(),a=M.getIndexByKey(o,r);return a>=0?r[a].type===Mn?this._removeChange(a):this._addChange({key:o,type:Eo}):this._addChange({key:o,oldData:n.data,type:Eo}),this._afterDeleteRow(e,s)}_afterDeleteRow(e,t){return this.saveEditData()}undeleteRow(e){let t=this._dataController,n=t.items()[e],o=this._getVisibleEditRowIndex(),s=n&&n.key,r=this.getChanges();if(n){let a=M.getIndexByKey(s,r);if(a>=0){let{data:l}=r[a];dt(l)?this._removeChange(a):this._addChange({key:s,type:pd}),t.updateItems({changeType:"update",rowIndices:[o,e]})}}}_fireOnSaving(){let e={cancel:!1,promise:null,changes:[...this.getChanges()]};this.executeAction("onSaving",e);let t=new y;return P(ht(e.promise)).done(()=>{t.resolve(e)}).fail(n=>{gd(t),this._fireDataErrorOccurred(n),t.resolve({cancel:!0})}),t}_executeEditingAction(e,t,n){if(this.component._disposed)return null;let o=new y;return this.executeAction(e,t),P(ht(t.cancel)).done(s=>{s?setTimeout(()=>{o.resolve("cancel")}):n(t).done(o.resolve).fail(gd(o))}).fail(gd(o)),o}_processChanges(e,t,n,o){let s=this._dataController.store();x(o,(r,a)=>{let l=this._getOldData(a.key),{data:d,type:c}=a,h=I({},a),p,g;if(!this._beforeSaveEditData(a,r)){switch(c){case Eo:g={data:l,key:a.key,cancel:!1},p=this._executeEditingAction("onRowRemoving",g,()=>s.remove(a.key).done(C=>{n.push({type:"remove",key:C})}));break;case Mn:g={data:d,cancel:!1},p=this._executeEditingAction("onRowInserting",g,()=>s.insert(g.data).done((C,v)=>{f(v)&&(h.key=v),C&&$(C)&&C!==g.data&&(h.data=C),n.push({type:"insert",data:C,index:0})}));break;case pd:g={newData:d,oldData:l,key:a.key,cancel:!1},p=this._executeEditingAction("onRowUpdating",g,()=>s.update(a.key,g.newData).done((C,v)=>{C&&$(C)&&C!==g.newData&&(h.data=C),n.push({type:"update",key:v,data:C})}))}if(o[r]=h,p){let C=new y;p.always(v=>{t.push({key:a.key,result:v})}).always(C.resolve),e.push(C.promise())}}})}_processRemoveIfError(e,t){let n=e[t];return n?.type===Eo&&t>=0&&e.splice(t,1),!0}_processRemove(e,t,n){let o=e[t];if(!n||!o||o.type===Eo)return this._processRemoveCore(e,t,!n||!o)}_processRemoveCore(e,t,n){return t>=0&&e.splice(t,1),!0}_processSaveEditDataResult(e){let t=!1,n=this.getChanges(),o=[...n],s=o.length;for(let r=0;r<e.length;r++){let a=e[r].result,l=a==="cancel",d=M.getIndexByKey(e[r].key,o),c=o[d];if(a&&a instanceof Error){if(c&&this._addInternalData({key:c.key,error:a}),this._fireDataErrorOccurred(a),this._processRemoveIfError(o,d))break}else if(this._processRemove(o,d,l)){t=!l;let p=M.getIndexByKey(e[r].key,n);this._updateInsertAfterOrBeforeKeys(n,p)}}return o.length<s&&this._silentOption(ns,o),t}_fireSaveEditDataEvents(e){x(e,(t,n)=>{let{data:o,key:s,type:r}=n,a=this._addInternalData({key:s}),l={key:s,data:o};switch(a.error&&(l.error=a.error),r){case Eo:this.executeAction("onRowRemoved",m({},l,{data:a.oldData}));break;case Mn:this.executeAction("onRowInserted",l);break;case pd:this.executeAction("onRowUpdated",l)}}),this.executeAction("onSaved",{changes:e})}saveEditData(){let e=new y;return this.waitForDeferredOperations().done(()=>{if(this.isSaving()){this._resolveAfterSave(e);return}P(this._beforeSaveEditData()).done(t=>{if(t){this._resolveAfterSave(e,{cancel:t});return}this._saving=!0,this._saveEditDataInner().always(()=>{this._saving=!1,this._refocusEditCell&&this._focusEditingCell()}).done(e.resolve).fail(e.reject)}).fail(e.reject)}).fail(e.reject),e.promise()}_resolveAfterSave(e){let{cancel:t,error:n}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};P(this._afterSaveEditData(t)).done(()=>{e.resolve(n)}).fail(e.reject)}_saveEditDataInner(){let e=new y,t=[],n=[],o=[],s=this._dataController.dataSource();return P(this._fireOnSaving()).done(r=>{let{cancel:a,changes:l}=r;if(a)return e.resolve().promise();if(this._processChanges(n,t,o,l),n.length)return this._refocusEditCell=!0,s?.beginLoading(),P(...n).done(()=>{this._processSaveEditDataResult(t)?this._endSaving(o,l,e):(s?.endLoading(),e.resolve())}).fail(d=>{s?.endLoading(),e.resolve(d)}),e.always(()=>{this._refocusEditCell=!0}).promise();this._cancelSaving(e)}).fail(e.reject),e.promise()}_beforeEndSaving(e){this._resetEditIndices()}_endSaving(e,t,n){let o=this._dataController.dataSource();this._beforeEndSaving(t),o?.endLoading(),this._refreshDataAfterSave(e,t,n)}_cancelSaving(e){this.executeAction("onSaved",{changes:[]}),this._resolveAfterSave(e)}_refreshDataAfterSave(e,t,n){let o=this._dataController,s=this.option("editing.refreshMode"),r=s!=="reshape"&&s!=="repaint";r||o.push(e),P(o.refresh({selection:r,reload:r,load:s==="reshape",changesOnly:this.option("repaintChangesOnly")})).always(()=>{this._fireSaveEditDataEvents(t)}).done(()=>{this._resolveAfterSave(n)}).fail(a=>{this._resolveAfterSave(n,{error:a})})}isSaving(){return this._saving}_updateEditColumn(){let e=this._isEditColumnVisible(),t=this.option("editing.useIcons"),n=zB+(t?` ${qy}`:"");this._columnsController.addCommandColumn({type:"buttons",command:"edit",visible:e,cssClass:n,width:"auto",alignment:"center",cellTemplate:this._getEditCommandCellTemplate(),fixedPosition:"right"}),this._columnsController.columnOption("command:edit",{visible:e,cssClass:n})}_isEditColumnVisible(){return this.option("editing").allowDeleting}_isEditButtonDisabled(){let e=this.hasChanges();return!(f(this.option("editing.editRowKey"))||e)}_updateEditButtons(){let e=this._isEditButtonDisabled();this._headerPanelView&&(this._headerPanelView.setToolbarItemDisabled("saveButton",e),this._headerPanelView.setToolbarItemDisabled("revertButton",e))}_applyModified(e,t){e&&e.addClass(Yy)}_beforeCloseEditCellInBatchMode(e){}cancelEditData(){let e=this.getChanges(),t={cancel:!1,changes:e};this.executeAction("onEditCanceling",t),t.cancel||(this._cancelEditDataCore(),this.executeAction("onEditCanceled",{changes:e}))}_cancelEditDataCore(){let e=this._getVisibleEditRowIndex();this._beforeCancelEditData(),this.init(),this.resetChanges(),this._resetEditColumnName(),this._resetEditRowKey(),this._afterCancelEditData(e)}_afterCancelEditData(e){this._dataController.updateItems({repaintChangesOnly:this.option("repaintChangesOnly")})}_hideEditPopup(){}hasEditData(){return this.hasChanges()}update(e){let t=this._dataController;t&&this._pageIndex!==t.pageIndex()&&(e==="refresh"&&this.refresh({isPageChanged:!0}),this._pageIndex=t.pageIndex()),this._updateEditButtons()}_getRowIndicesForCascadeUpdating(e,t){return t?[]:[e.rowIndex]}addDeferred(e){this._deferreds.includes(e)||(this._deferreds.push(e),e.always(()=>{let t=this._deferreds.indexOf(e);t>=0&&this._deferreds.splice(t,1)}))}_prepareChange(e,t,n){var o;let s={},r=(o=e.row)===null||o===void 0?void 0:o.data,a=e.key,l=new y;return a!==void 0&&(e.value=t,ht(e.column.setCellValue(s,t,m(!0,{},r),n)).done(()=>{l.resolve({data:s,key:a,oldData:r,type:pd})}).fail(gd(l)).fail(c=>this._fireDataErrorOccurred(c)),f(n)&&e.column.displayValueMap&&(e.column.displayValueMap[t]=n),this._updateRowValues(e),this.addDeferred(l)),l}_updateRowValues(e){if(e.values){let t=this._dataController,n=t.getRowIndexByKey(e.key),o=t.getVisibleRows()[n];o&&(e.row.values=o.values,e.values=o.values),e.values[e.columnIndex]=e.value}}updateFieldValue(e,t,n,o){let s=e.key,r=new y;return s===void 0&&this._dataController.fireError("E1043"),e.column.setCellValue?this._prepareChange(e,t,n).done(a=>{P(this._applyChange(e,a,o)).always(()=>{r.resolve()})}):r.resolve(),r.promise()}_focusPreviousEditingCellIfNeed(e){if(this.hasEditData()&&!this.isEditCell(e.rowIndex,e.columnIndex))return this._focusEditingCell(),this._updateEditRow(e.row,!0),!0}_needUpdateRow(e){let t=this._columnsController.getVisibleColumns();e||(e=this._getEditColumn());let n=e&&e.setCellValue!==e.defaultSetCellValue,o=t.some(s=>s.calculateCellValue!==s.defaultCalculateCellValue);return n||o}_applyChange(e,t,n){let o=I({},e,{forceUpdateRow:n});return this._addChange(t,o),this._updateEditButtons(),this._applyChangeCore(e,o.forceUpdateRow)}_applyChangeCore(e,t){let n=e.column.setCellValue!==e.column.defaultSetCellValue,{row:o}=e;o&&(t||n?this._updateEditRow(o,t,n):o.update&&o.update())}_updateEditRowCore(e,t,n){this._dataController.updateItems({changeType:"update",rowIndices:this._getRowIndicesForCascadeUpdating(e,t)})}_updateEditRow(e,t,n){t?this._updateRowImmediately(e,t,n):this._updateRowWithDelay(e,n)}_updateRowImmediately(e,t,n){this._updateEditRowCore(e,!t,n),this._validateEditFormAfterUpdate(e,n),t||this._focusEditingCell()}_updateRowWithDelay(e,t){let n=new y;this.addDeferred(n),setTimeout(()=>{var o;let s=((o=this._editForm)===null||o===void 0?void 0:o.element())||this.component.$element().get(0),r=u(w.getActiveElement(s)),a=this._rowsView.getCellIndex(r,e.rowIndex),l=r.get(0),d=M.getSelectionRange(l);if(this._updateEditRowCore(e,!1,t),this._validateEditFormAfterUpdate(e,t),a>=0){let c=this._rowsView._getCellElement(e.rowIndex,a);this._delayedInputFocus(c,()=>{setTimeout(()=>{var h;l=w.getActiveElement((h=this.component.$element())===null||h===void 0?void 0:h.get(0)),d.selectionStart>=0&&M.setSelectionRange(l,d)})})}n.resolve()})}_validateEditFormAfterUpdate(){}_addChange(e,t){var n;let o=t?.row,s=[...this.getChanges()],r=M.getIndexByKey(e.key,s);r<0&&(r=s.length,this._addInternalData({key:e.key,oldData:e.oldData}),delete e.oldData,s.push(e));let a=I({},s[r]);return a&&(e.data&&(a.data=ho(a.data,e.data)),(!a.type||!e.data)&&e.type&&(a.type=e.type),o&&(o.oldData=this._getOldData(o.key),o.data=ho(o.data,e.data))),s[r]=a,this._silentOption(ns,s),t&&a!==((n=this.getChanges())===null||n===void 0?void 0:n[r])&&(t.forceUpdateRow=!0),a}_getFormEditItemTemplate(e,t){return t.editCellTemplate||this._getDefaultEditorTemplate()}getColumnTemplate(e){let{column:t}=e,n=e.row&&e.row.rowIndex,o,s=this.isRowBasedEditMode(),r=this.isEditRow(n),a=this.isEditCell(n,e.columnIndex),l;return(t.showEditorAlways||t.setCellValue&&(r&&t.allowEditing||a))&&(e.rowType==="data"||e.rowType==="detailAdaptive")&&!t.command?(((this.allowUpdating(e)||r)&&t.allowEditing||a)&&(r||!s)&&(t.showEditorAlways&&!s&&(l={cancel:!1,key:e.row.isNewRow?void 0:e.row.key,data:e.row.data,column:t},this._isEditingStart(l)),(!l||!l.cancel)&&(e.setValue=(c,h)=>{this.updateFieldValue(e,c,h)})),o=t.editCellTemplate||this._getDefaultEditorTemplate()):t.command==="detail"&&e.rowType==="detail"&&r&&(o=this===null||this===void 0?void 0:this.getEditFormTemplate(e)),o}_createButton(e,t,n,o){let s=YB[t.name],r=this.option("editing.useIcons"),a=this.option("useLegacyColumnButtonTemplate"),l=u("<a>").attr("href","#").addClass(LB).addClass(t.cssClass);if(t.template&&a)this._rowsView.renderTemplate(e,t.template,n,!0);else{if(t.template)l=u("<span>").addClass(t.cssClass);else if(r&&s||t.icon){s=t.icon||s;let d=ms(s);d==="image"||d==="svg"?l=ci(s).addClass(t.cssClass):l.addClass(`dx-icon${d==="dxIcon"?"-":" "}${s}`).attr("title",t.text),l.addClass(NB),e.addClass(qy);let c=this.getButtonLocalizationNames()[t.name];c&&l.attr("aria-label",O.format(c))}else l.text(t.text);f(t.hint)&&l.attr("title",t.hint),this._isButtonDisabled(t,n)?l.addClass("dx-state-disabled"):(!t.template||t.onClick)&&_.on(l,D("click",KB),this.createAction(d=>{var c;(c=t.onClick)===null||c===void 0||c.call(t,m({},d,{row:n.row,column:n.column})),d.event.preventDefault(),d.event.stopPropagation()})),e.append(l),t.template&&(n.renderAsync=!1,this._rowsView.renderTemplate(l,t.template,n,!0,o))}}getButtonLocalizationNames(){return{edit:"dxDataGrid-editingEditRow",save:"dxDataGrid-editingSaveRowChanges",delete:"dxDataGrid-editingDeleteRow",undelete:"dxDataGrid-editingUndeleteRow",cancel:"dxDataGrid-editingCancelRowChanges"}}prepareButtonItem(e,t,n,o){let s=this.option("editing.texts")??{},r={revert:s.cancelAllChanges,save:s.saveAllChanges,addRow:s.addRow},a={revert:"cancel",save:"save",addRow:"addrow"}[t],l=r[t],d=(a==="save"||a==="cancel")&&this._isEditButtonDisabled();return{widget:"dxButton",options:{onInitialized:c=>{u(c.element).addClass(e._getToolbarButtonClass(`${$B} ${this.addWidgetPrefix(a)}-button`))},icon:`edit-button-${a}`,disabled:d,onClick:()=>{setTimeout(()=>{this[n]()})},text:l,hint:l},showText:"inMenu",name:`${t}Button`,location:"after",locateInMenu:"auto",sortIndex:o}}prepareEditButtons(e){let t=this.option("editing")??{},n=[];return t.allowAdding&&n.push(this.prepareButtonItem(e,"addRow","addRow",20)),n}highlightDataCell(e,t){this.shouldHighlightCell(t)&&e.addClass(Yy)}_afterInsertRow(e){}_beforeSaveEditData(e){if(e&&!f(e.key)&&f(e.type))return!0}_afterSaveEditData(){}_beforeCancelEditData(){}_allowEditAction(e,t){let n=this.option(`editing.${e}`);return A(n)&&(n=n({component:this.component,row:t.row})),n}allowUpdating(e,t){let n=this.option("editing.startEditAction")??jB;return(arguments.length>1?n===t||t==="down":!0)&&this._allowEditAction("allowUpdating",e)}allowDeleting(e){return this._allowEditAction("allowDeleting",e)}isCellModified(e){var t,n;let{columnIndex:o}=e,s=e==null||(t=e.row)===null||t===void 0||(t=t.modifiedValues)===null||t===void 0?void 0:t[o];return e!=null&&(n=e.row)!==null&&n!==void 0&&n.isNewRow&&(s=e.value),s!==void 0}isNewRowInEditMode(){let e=this._getVisibleEditRowIndex(),t=this._dataController.items();return e>=0?t[e].isNewRow:!1}_isRowDeleteAllowed(){}shouldHighlightCell(e){return this.isCellModified(e)&&e.column.setCellValue&&(this.getEditMode()!==Lr||!e.row.isEditing)}},nO=i=>class extends i{reload(e,t){return!t&&this._editingController.refresh(),super.reload.apply(this,arguments)}repaintRows(){if(!this._editingController.isSaving())return super.repaintRows.apply(this,arguments)}_updateEditRow(e){let t=this.option(zi),n=M.getIndexByKey(t,e),o=e[n];if(o){var s;o.isEditing=!0,(s=this._updateEditItem)===null||s===void 0||s.call(this,o)}}_updateItemsCore(e){super._updateItemsCore(e),this._updateEditRow(this.items(!0))}_applyChangeUpdate(e){this._updateEditRow(e.items),super._applyChangeUpdate(e)}_applyChangesOnly(e){this._updateEditRow(e.items),super._applyChangesOnly(e)}_processItems(e,t){return e=this._editingController.processItems(e,t),super._processItems(e,t)}_processDataItem(e,t){return this._editingController.processDataItem(e,t,this.generateDataValues),super._processDataItem(e,t)}_processItem(e,t){return e=super._processItem(e,t),e.isNewRow&&(t.dataIndex--,delete e.dataIndex),e}_getChangedColumnIndices(e,t,n,o){if(!(e.isNewRow!==t.isNewRow||e.removed!==t.removed))return super._getChangedColumnIndices.apply(this,arguments)}_isCellChanged(e,t,n,o,s){let r=e.cells&&e.cells[o],a=this._editingController&&this._editingController.isEditCell(n,o);return s&&a?!1:r&&r.column&&!r.column.showEditorAlways&&r.isEditing!==a?!0:super._isCellChanged.apply(this,arguments)}needToRefreshOnDataSourceChange(e){return!(Array.isArray(e.value)&&e.value===e.previousValue&&this._editingController.isSaving())}_handleDataSourceChange(e){let t=super._handleDataSourceChange(e),n=this.option("editing.changes"),o=e.value;if(Array.isArray(o)&&n.length){let s=o.map(d=>this.keyOf(d)),r=n.filter(d=>d.type==="insert"||s.some(c=>ve(d.key,c)));r.length!==n.length&&this.option("editing.changes",r);let a=this.option("editing.editRowKey");!r.some(d=>d.type==="insert"&&ve(a,d.key))&&s.every(d=>!ve(a,d))&&this.option("editing.editRowKey",null)}return t}},iQ=i=>class extends i{getCellIndex(e,t){if(!e.is("td")&&t>=0){let n=this.getCellElements(t),o=-1;return x(n,(s,r)=>{u(r).find(e).length&&(o=s)}),o}return super.getCellIndex.apply(this,arguments)}publicMethods(){return super.publicMethods().concat(["cellValue"])}_getCellTemplate(e){return this._editingController.getColumnTemplate(e)||super._getCellTemplate(e)}_createRow(e){let t=super._createRow.apply(this,arguments);if(e){let n=!!e.removed,o=!!e.isNewRow,s=!!e.modified;o&&t.addClass(WB),s&&t.addClass(GB),(o||n)&&t.removeClass(HB)}return t}_getColumnIndexByElement(e){let t=e.closest("table"),n=this.getTableElements();for(;t.length&&!n.filter(t).length;)e=t.closest("td"),t=e.closest("table");return this._getColumnIndexByElementCore(e)}_getColumnIndexByElementCore(e){let t=e.closest(`.${So}> td:not(.dx-master-detail-cell)`);return this.getCellIndex(t)}_editCellByClick(e,t){let n=this._editingController,o=u(e.event.target),s=this._getColumnIndexByElement(o),r=this._dataController.items()[e.rowIndex],a=n.allowUpdating({row:r},t)||r&&r.isNewRow,l=this._columnsController.getVisibleColumns()[s],d=n.isEditCell(e.rowIndex,s),c=a&&l&&(l.allowEditing||d),h=this.option("editing.startEditAction")||"click",p=l&&l.showEditorAlways;if(d)return!0;if(t==="down")return(F.real().ios||F.real().android)&&zn(),p&&c&&n.editCell(e.rowIndex,s);if(t==="click"&&h==="dblClick"&&this._pointerDownTarget===o.get(0)){let C=r?.isNewRow;n.closeEditCell(!1,C)}if(c&&t===h)return n.editCell(e.rowIndex,s)||n.isEditRow(e.rowIndex)}_rowPointerDown(e){this._pointerDownTarget=e.event.target,this._pointerDownTimeout=setTimeout(()=>{this._editCellByClick(e,"down")})}_rowClickTreeListHack(e){super._rowClick.apply(this,arguments)}_rowClick(e){let t=u(e.rowElement).hasClass(this.addWidgetPrefix(cd));e.event[mm]=this.component,!this._editCellByClick(e,"click")&&!t&&super._rowClick.apply(this,arguments)}_rowDblClickTreeListHack(e){super._rowDblClick.apply(this,arguments)}_rowDblClick(e){this._editCellByClick(e,"dblClick")||super._rowDblClick.apply(this,arguments)}_cellPrepared(e,t){var n;let o=this._editingController,s=!!t.column.command,r=t.setValue,a=o.isEditRow(t.rowIndex),l=Zy(a,t);if(Jy(a,t)){let{alignment:c}=t.column;e.toggleClass(this.addWidgetPrefix(VB),!r).toggleClass(UB,!r),c&&e.find(yu).first().css("textAlign",c)}l&&this._editCellPrepared(e);let d=!!((n=t.column)!==null&&n!==void 0&&n.cellTemplate);t.column&&!s&&(!d||o.shouldHighlightCell(t))&&o.highlightDataCell(e,t),super._cellPrepared.apply(this,arguments)}_getCellOptions(e){let t=super._getCellOptions(e),{columnIndex:n,row:o}=e;return t.isEditing=this._editingController.isEditCell(t.rowIndex,t.columnIndex),t.removed=o.removed,o.modified&&(t.modified=o.modifiedValues[n]!==void 0),t}_setCellAriaAttributes(e,t){super._setCellAriaAttributes(e,t),t.removed&&this.setAria("roledescription",O.format("dxDataGrid-ariaDeletedCell"),e),t.modified&&this.setAria("roledescription",O.format("dxDataGrid-ariaModifiedCell"),e),t.column.allowEditing&&!t.removed&&!t.modified&&t.rowType==="data"&&t.column.calculateCellValue===t.column.defaultCalculateCellValue&&this._editingController.isCellBasedEditMode()&&this.setAria("roledescription",O.format("dxDataGrid-ariaEditableCell"),e)}_createCell(e){let t=super._createCell(e),n=this._editingController.isEditRow(e.rowIndex);return Jy(n,e)&&t.addClass(Vr),t}cellValue(e,t,n,o){let s=this.getCellOptions(e,t);if(s){if(n===void 0)return s.value;this._editingController.updateFieldValue(s,n,o,!0)}}dispose(){super.dispose.apply(this,arguments),clearTimeout(this._pointerDownTimeout)}_renderCore(){return super._renderCore.apply(this,arguments),this.waitAsyncTemplates(!0).done(()=>{this._editingController._focusEditorIfNeed()})}_editCellPrepared(){}_formItemPrepared(){}},nQ=i=>class extends i{optionChanged(e){let{fullName:t}=e;switch(e.name){case"editing":{t&&![ud,ns,Ws,zi].some(s=>s===t)&&this._invalidate(),super.optionChanged(e);break}case"useLegacyColumnButtonTemplate":e.handled=!0;break;default:super.optionChanged(e)}}_getToolbarItems(){let e=super._getToolbarItems();return this._editingController.prepareEditButtons(this).concat(e)}},_m={defaultOptions:()=>({editing:{mode:"row",refreshMode:"full",newRowPosition:jy,allowAdding:!1,allowUpdating:!1,allowDeleting:!1,useIcons:!1,selectTextOnEditStart:!1,confirmDelete:!0,texts:{editRow:O.format("dxDataGrid-editingEditRow"),saveAllChanges:O.format("dxDataGrid-editingSaveAllChanges"),saveRowChanges:O.format("dxDataGrid-editingSaveRowChanges"),cancelAllChanges:O.format("dxDataGrid-editingCancelAllChanges"),cancelRowChanges:O.format("dxDataGrid-editingCancelRowChanges"),addRow:O.format("dxDataGrid-editingAddRow"),deleteRow:O.format("dxDataGrid-editingDeleteRow"),undeleteRow:O.format("dxDataGrid-editingUndeleteRow"),confirmDeleteMessage:O.format("dxDataGrid-editingConfirmDeleteMessage"),confirmDeleteTitle:""},form:{colCount:2},popup:{},startEditAction:"click",editRowKey:null,editColumnName:null,changes:[]},useLegacyColumnButtonTemplate:!1}),controllers:{editing:iO},extenders:{controllers:{data:nO},views:{rowsView:iQ,headerPanel:nQ}}};var oQ=i=>class extends nO(i){_changeRowExpandCore(e){let t=this._editingController;return Array.isArray(e)&&t&&t.refresh(),super._changeRowExpandCore.apply(this,arguments)}};H.registerModule("editing",I({},_m,{extenders:I({},_m.extenders,{controllers:I({},_m.extenders.controllers,{data:oQ})})}));var sQ=i=>class extends i{isRowEditMode(){return this.getEditMode()===Lr}_afterCancelEditData(e){let t=this._dataController;this.isRowBasedEditMode()&&e>=0?t.updateItems({changeType:"update",rowIndices:[e,e+1]}):super._afterCancelEditData(e)}_isDefaultButtonVisible(e,t){let n=this.isRowBasedEditMode(),s=!this.isPopupEditMode()&&t.row&&ve(t.row.key,this.option(zi));if(n)switch(e.name){case"edit":return!s&&this.allowUpdating(t);case"delete":return super._isDefaultButtonVisible(e,t)&&!s;case"save":case"cancel":return s;default:return super._isDefaultButtonVisible(e,t)}return super._isDefaultButtonVisible(e,t)}isEditRow(e){return this.isRowBasedEditMode()&&this.isEditRowByIndex(e)}_cancelSaving(e){this.isRowBasedEditMode()&&(this.hasChanges()||this._cancelEditDataCore()),super._cancelSaving(e)}_refreshCore(e){let{allowCancelEditing:t}=e??{};if(this.isRowBasedEditMode()){let n=this.getChanges().filter(o=>o.type==="update").length>0;this.init(),t&&n&&this._cancelEditDataCore()}super._refreshCore(e)}_isEditColumnVisible(){let e=super._isEditColumnVisible(),t=this.option("editing"),n=this.isRowEditMode(),o=t.allowUpdating||t.allowAdding;return e||n&&o}_focusEditorIfNeed(){let e=this.getEditMode();if(this._needFocusEditor){if(BB.includes(e)){let t=this.getFocusedCellInRow(this._getVisibleEditRowIndex());this._delayedInputFocus(t,()=>{t&&this.component.focus(t)})}this._needFocusEditor=!1}}},rQ=i=>class extends i{_getChangedColumnIndices(e,t,n,o){if(!(this._editingController.isRowBasedEditMode()&&e.isEditing!==t.isEditing))return super._getChangedColumnIndices.apply(this,arguments)}},aQ=i=>class extends i{_createRow(e){let t=super._createRow.apply(this,arguments);return e&&this._editingController.isEditRow(e.rowIndex)&&(t.addClass(Qy),t.removeClass(Wy),e.rowType==="detail"&&t.addClass(this.addWidgetPrefix(cd))),t}_update(e){super._update(e),e.changeType==="updateSelection"&&this.getTableElements().children("tbody").children(`.${Qy}`).removeClass(Wy)}},mV={extenders:{controllers:{editing:sQ,data:rQ},views:{rowsView:aQ}}};H.registerModule("editingRowBased",mV);var fV="dx-responsivebox-screen-";var _V=In.inherit({_getDefaultOptions(){return m(this.callBase(),{rows:[],cols:[],screenByWidth:null,singleColumnScreen:"",height:"100%",width:"100%",activeStateEnabled:!1,focusStateEnabled:!1,onItemStateChanged:void 0,onLayoutChanged:null,currentScreenFactor:void 0})},_init(){this.option("screenByWidth")||this._options.silent("screenByWidth",Vd),this.callBase(),this._initLayoutChangedAction()},_initLayoutChangedAction(){this._layoutChangedAction=this._createActionByOption("onLayoutChanged",{excludeValidators:["disabled","readonly"]})},_itemClass:()=>"dx-box-item",_itemDataKey:()=>"dxBoxItemData",_initMarkup(){this.callBase(),this.$element().addClass("dx-responsivebox")},_renderItems(){this._setScreenSize(),this._screenItems=this._itemsByScreen(),this._prepareGrid(),this._spreadItems(),this._layoutItems(),this._linkNodeToItem()},_itemOptionChanged(i){let e=this._findItemElementByItem(i);e.length&&(this._refreshItem(e,i),this._clearItemNodeTemplates(),this._update(!0))},_setScreenSize(){let i=this._getCurrentScreen();this._removeScreenSizeClass(),this.$element().addClass(fV+i),this.option("currentScreenFactor",i)},_removeScreenSizeClass(){let i=this.option("currentScreenFactor");i&&this.$element().removeClass(fV+i)},_prepareGrid(){let i=this._grid=[];this._prepareRowsAndCols(),x(this._rows,()=>{let e=[];i.push(e),x(this._cols,()=>{e.push(this._createEmptyCell())})})},getSingleColumnRows(){let i=this.option("rows"),e=this._screenItems.length;if(i.length){let t=this._filterByScreen(i),n=[];for(let o=0;o<e;o++){let s=this._defaultSizeConfig();o<t.length&&f(t[o].shrink)&&(s.shrink=t[o].shrink),n.push(s)}return n}return this._defaultSizeConfig(e)},_prepareRowsAndCols(){this._isSingleColumnScreen()?(this._prepareSingleColumnScreenItems(),this._rows=this.getSingleColumnRows(),this._cols=this._defaultSizeConfig(1)):(this._rows=this._sizesByScreen(this.option("rows")),this._cols=this._sizesByScreen(this.option("cols")))},_isSingleColumnScreen(){return this._screenRegExp().test(this.option("singleColumnScreen"))||!this.option("rows").length||!this.option("cols").length},_prepareSingleColumnScreenItems(){this._screenItems.sort((i,e)=>i.location.row-e.location.row||i.location.col-e.location.col),x(this._screenItems,(i,e)=>{m(e.location,{row:i,col:0,rowspan:1,colspan:1})})},_sizesByScreen(i){return He(this._filterByScreen(i),e=>m(this._defaultSizeConfig(),e))},_createDefaultSizeConfig:()=>({ratio:1,baseSize:0,minSize:0,maxSize:0}),_defaultSizeConfig(i){let e=this._createDefaultSizeConfig();if(!arguments.length)return e;let t=[];for(let n=0;n<i;n++)t.push(e);return t},_filterByScreen(i){let e=this._screenRegExp();return xt(i,t=>!t.screen||e.test(t.screen))},_screenRegExp(){let i=this._getCurrentScreen();return new RegExp(`(^|\\s)${i}($|\\s)`,"i")},_getCurrentScreen(){let i=this._screenWidth();return this.option("screenByWidth")(i)},_screenWidth:()=>W()?z(K()):1920,_createEmptyCell:()=>({item:{},location:{colspan:1,rowspan:1}}),_spreadItems(){x(this._screenItems,(i,e)=>{let t=e.location||{},n=t.col,o=t.row,s=this._grid[o],r=s&&s[n];this._occupyCells(r,e)})},_itemsByScreen(){return this.option("items").reduce((i,e)=>{let t=e.location||{};return t=q(t)?[t]:t,this._filterByScreen(t).forEach(n=>{i.push({item:e,location:m({rowspan:1,colspan:1},n)})}),i},[])},_occupyCells(i,e){!i||this._isItemCellOccupied(i,e)||(m(i,e),this._markSpanningCell(i))},_isItemCellOccupied(i,e){if(!dt(i.item))return!0;let t=!1;return this._loopOverSpanning(e.location,n=>{t=t||!dt(n.item)}),t},_loopOverSpanning(i,e){let t=i.row+i.rowspan-1,n=i.col+i.colspan-1,o=Math.min(t,this._rows.length-1),s=Math.min(n,this._cols.length-1);i.rowspan-=t-o,i.colspan-=n-s;for(let r=i.row;r<=o;r++)for(let a=i.col;a<=s;a++)(r!==i.row||a!==i.col)&&e(this._grid[r][a])},_markSpanningCell(i){this._loopOverSpanning(i.location,e=>{m(e,{item:i.item,spanningCell:i})})},_linkNodeToItem(){x(this._itemElements(),(i,e)=>{let t=u(e),n=t.data("dxBoxItemData");n.box||(n.node=t.children())})},_layoutItems(){let i=this._grid.length,e=i&&this._grid[0].length;if(!i&&!e)return;let t=this._layoutBlock({direction:"col",row:{start:0,end:i-1},col:{start:0,end:e-1}}),n=this._prepareBoxConfig(t.box||{direction:"row",items:[m(t,{ratio:1})]});m(n,this._rootBoxConfig(n.items)),this._$root=u("<div>").appendTo(this._itemContainer()),this._createComponent(this._$root,Ca,n)},_rootBoxConfig(i){return{width:"100%",height:"100%",items:x(i,(t,n)=>{this._needApplyAutoBaseSize(n)&&m(n,{baseSize:"auto"})}),itemTemplate:this._getTemplateByOption("itemTemplate"),itemHoldTimeout:this.option("itemHoldTimeout"),onItemHold:this._createActionByOption("onItemHold"),onItemClick:this._createActionByOption("onItemClick"),onItemContextMenu:this._createActionByOption("onItemContextMenu"),onItemRendered:this._createActionByOption("onItemRendered")}},_needApplyAutoBaseSize:i=>!i.baseSize&&(!i.minSize||i.minSize==="auto")&&(!i.maxSize||i.maxSize==="auto"),_prepareBoxConfig(i){return m(i||{},{crossAlign:"stretch",onItemStateChanged:this.option("onItemStateChanged")})},_layoutBlock(i){return this._isSingleItem(i)?this._itemByCell(i.row.start,i.col.start):this._layoutDirection(i)},_isSingleItem(i){let e=this._grid[i.row.start][i.col.start].location,t=i.row.end-i.row.start===e.rowspan-1,n=i.col.end-i.col.start===e.colspan-1;return t&&n},_itemByCell(i,e){let t=this._grid[i][e];return t.spanningCell?null:t.item},_layoutDirection(i){let e=[],{direction:t}=i,n=this._crossDirection(t),o;for(;o=this._nextBlock(i);){if(this._isBlockIndivisible(i.prevBlockOptions,o))throw Z.Error("E1025");let s=this._layoutBlock({direction:n,row:o.row,col:o.col,prevBlockOptions:i});s&&(m(s,this._blockSize(o,n)),e.push(s)),i[n].start=o[n].end+1}return{box:this._prepareBoxConfig({direction:t,items:e})}},_isBlockIndivisible:(i,e)=>i&&i.col.start===e.col.start&&i.col.end===e.col.end&&i.row.start===e.row.start&&i.row.end===e.row.end,_crossDirection:i=>i==="col"?"row":"col",_nextBlock(i){let{direction:e}=i,t=this._crossDirection(e),n=i[e].start,o=i[e].end,s=i[t].start;if(s>i[t].end)return null;let r=1;for(let l=s;l<s+r;l++){let d=1;for(let p=n;p<=o;p++){let g=this._cellByDirection(e,p,l);d=Math.max(d,g.location[`${t}span`])}let c=l+d,h=s+r;c>h&&(r+=c-h)}let a={};return a[e]={start:n,end:o},a[t]={start:s,end:s+r-1},a},_cellByDirection(i,e,t){return i==="col"?this._grid[t][e]:this._grid[e][t]},_blockSize(i,e){let t=e==="row"?"auto":0,n=e==="row"?this._rows:this._cols,o=m(this._createDefaultSizeConfig(),{ratio:0});for(let s=i[e].start;s<=i[e].end;s++){let r=n[s];o.ratio+=r.ratio,o.baseSize+=r.baseSize,o.minSize+=r.minSize,o.maxSize+=r.maxSize,f(r.shrink)&&(o.shrink=r.shrink)}return o.minSize=o.minSize?o.minSize:t,o.maxSize=o.maxSize?o.maxSize:"auto",this._isSingleColumnScreen()&&(o.baseSize="auto"),o},_update(i){let e=this._$root;this._renderItems(),e&&(i?e.remove():(e.detach(),this._saveAssistantRoot(e))),this._layoutChangedAction()},_saveAssistantRoot(i){this._assistantRoots=this._assistantRoots||[],this._assistantRoots.push(i)},_dispose(){this._clearItemNodeTemplates(),this._cleanUnusedRoots(),this.callBase.apply(this,arguments)},_cleanUnusedRoots(){this._assistantRoots&&x(this._assistantRoots,(i,e)=>{u(e).remove()})},_clearItemNodeTemplates(){x(this.option("items"),function(){delete this.node})},_attachClickEvent:S,_optionChanged(i){switch(i.name){case"rows":case"cols":case"screenByWidth":case"singleColumnScreen":this._clearItemNodeTemplates(),this._invalidate();break;case"width":case"height":this.callBase(i),this._update();break;case"onLayoutChanged":this._initLayoutChangedAction();break;case"itemTemplate":this._clearItemNodeTemplates(),this.callBase(i);break;case"currentScreenFactor":break;default:this.callBase(i)}},_dimensionChanged(){this._getCurrentScreen()!==this.option("currentScreenFactor")&&this._update()},repaint(){this._update()}});G("dxResponsiveBox",_V);var CV=_V;var xV=CV;function vV(i){let{item:e,$parent:t,rootElementCssClassList:n,validationGroup:o,createComponentCallback:s}=i,r=u("<div>").appendTo(t).addClass(n.join(" ")).addClass("dx-field-button-item").css("textAlign",lQ(e.horizontalAlignment));t.css("justifyContent",dQ(e.verticalAlignment));let a=u("<div>").appendTo(r);return{$rootElement:r,buttonInstance:s(a,"dxButton",m({validationGroup:o},e.buttonOptions))}}function lQ(i){return f(i)?i:"right"}function dQ(i){switch(i){case"center":return"center";case"bottom":return"flex-end";default:return"flex-start"}}function oO(i){let{$parent:e,rootElementCssClassList:t}=i;return u("<div>").addClass("dx-field-empty-item").html("&nbsp;").addClass(t.join(" ")).appendTo(e)}var cQ=ce.inherit({ctor(i,e){this.editor=i,this.validator=e,this.validationRequestsCallbacks=[];let t=n=>{this.validationRequestsCallbacks.forEach(o=>o(n))};i.validationRequest.add(t),i.on("disposing",()=>{i.validationRequest.remove(t)})},getValue(){return this.editor.option("value")},getCurrentValidationError(){return this.editor.option("validationError")},bypass(){return this.editor.option("disabled")},applyValidationResults(i){this.editor.option({validationErrors:i.brokenRules,validationStatus:i.status})},reset(){this.editor.clear()},focus(){this.editor.focus()}}),bV=cQ;var yV=Qi.inherit({_initOptions(i){this.callBase.apply(this,arguments),this.option(yi.initValidationOptions(i))},_getDefaultOptions(){return m(this.callBase(),{validationRules:[]})},_init(){this.callBase(),this._initGroupRegistration(),this.focused=ue(),this._initAdapter(),this._validationInfo={result:null,deferred:null,skipValidation:!1}},_initGroupRegistration(){let i=this._findGroup();this._groupWasInit||this.on("disposing",e=>{yi.removeRegisteredValidator(e.component._validationGroup,e.component)}),(!this._groupWasInit||this._validationGroup!==i)&&(yi.removeRegisteredValidator(this._validationGroup,this),this._groupWasInit=!0,this._validationGroup=i,yi.registerValidatorInGroup(i,this))},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{validationGroup:!0})},_getEditor(){let i=this.$element()[0];return $e(i,"dx-validation-target")},_initAdapter(){let i=this._getEditor(),e=this.option("adapter");if(!e){if(i){e=new bV(i,this),e.validationRequestsCallbacks.push(n=>{this._validationInfo.skipValidation||this.validate(n)}),this.option("adapter",e);return}throw Z.Error("E0120")}let t=e.validationRequestsCallbacks;t&&t.push(n=>{this.validate(n)})},_toggleRTLDirection(i){var e;let t=((e=this.option("adapter"))===null||e===void 0||(e=e.editor)===null||e===void 0?void 0:e.option("rtlEnabled"))??i;this.callBase(t)},_initMarkup(){this.$element().addClass("dx-validator"),this.callBase()},_render(){this.callBase(),this._toggleAccessibilityAttributes()},_toggleAccessibilityAttributes(){let i=this._getEditor();if(i){let t=(this.option("validationRules")||[]).some(n=>{let{type:o}=n;return o==="required"})||null;i.isInitialized()&&i.setAria("required",t),i.option("_onMarkupRendered",()=>{i.setAria("required",t)})}},_visibilityChanged(i){i&&this._initGroupRegistration()},_optionChanged(i){switch(i.name){case"validationGroup":this._initGroupRegistration();return;case"validationRules":this._resetValidationRules(),this._toggleAccessibilityAttributes(),this.option("isValid")!==void 0&&this.validate();return;case"adapter":this._initAdapter();break;case"isValid":case"validationStatus":this.option(yi.synchronizeValidationOptions(i,this.option()));break;default:this.callBase(i)}},_getValidationRules(){return this._validationRules||(this._validationRules=He(this.option("validationRules"),(i,e)=>m({},i,{validator:this,index:e}))),this._validationRules},_findGroup(){let i=this.$element();return this.option("validationGroup")||yi.findGroup(i,this._modelByElement(i))},_resetValidationRules(){delete this._validationRules},validate(i){let e=this.option("adapter"),t=this.option("name"),n=e.bypass&&e.bypass(),o=i&&i.value!==void 0?i.value:e.getValue(),s=e.getCurrentValidationError&&e.getCurrentValidationError(),r=this._getValidationRules(),a=this._validationInfo&&this._validationInfo.result;if(a&&a.status==="pending"&&a.value===o)return m({},a);let l;return n?l={isValid:!0,status:"valid"}:s&&s.editorSpecific?(s.validator=this,l={isValid:!1,status:"invalid",brokenRule:s,brokenRules:[s]}):l=yi.validate(o,r,t),l.id=new Oe().toString(),this._applyValidationResult(l,e),l.complete&&l.complete.then(d=>{d.id===this._validationInfo.result.id&&this._applyValidationResult(d,e)}),m({},this._validationInfo.result)},reset(){let i=this.option("adapter"),e={id:null,isValid:!0,brokenRule:null,brokenRules:null,pendingRules:null,status:"valid",complete:null};this._validationInfo.skipValidation=!0,i.reset(),this._validationInfo.skipValidation=!1,this._resetValidationRules(),this._applyValidationResult(e,i)},_updateValidationResult(i){if(!this._validationInfo.result||this._validationInfo.result.id!==i.id){let e=this._validationInfo.deferred&&this._validationInfo.result.complete;this._validationInfo.result=m({},i,{complete:e})}else for(let e in i)e!=="id"&&e!=="complete"&&(this._validationInfo.result[e]=i[e])},_applyValidationResult(i,e){let t=this._createActionByOption("onValidated",{excludeValidators:["readOnly"]});if(i.validator=this,this._updateValidationResult(i),e.applyValidationResults&&e.applyValidationResults(this._validationInfo.result),this.option({validationStatus:this._validationInfo.result.status}),this._validationInfo.result.status==="pending"){this._validationInfo.deferred||(this._validationInfo.deferred=y(),this._validationInfo.result.complete=this._validationInfo.deferred.promise()),this._eventsStrategy.fireEvent("validating",[this._validationInfo.result]);return}this._validationInfo.result.status!=="pending"&&(t(i),this._validationInfo.deferred&&(this._validationInfo.deferred.resolve(i),this._validationInfo.deferred=null))},focus(){let i=this.option("adapter");i&&i.focus&&i.focus()},_useTemplates:()=>!1});G("dxValidator",yV);var Cm=yV;var xm=Cm;var OV="dx-form",vm="dx-form-group",SV="dx-form-group-caption",EV="dx-form-group-custom-caption",sO="dx-col-",bm="dx-field-item",rO="dx-layout-manager-one-col",aO="dx-field-item-label-content",wV="dx-layout-manager",lO="dx-field-item-label",Iu="dx-field-item-content",IV="dx-single-column-item-content",ym="dx-root-simple-item",DV="dx-form-group-content",TV="dx-field-item-has-group",AV="dx-field-item-has-tabs",MV="dx-form-group-with-caption",dO="dx-field-item-tab",cO="dx-group-colcount-",uO="group-col-count",RV="dx-form-validation-summary",FV="dx-form-styling-mode-underlined",Du="simple";var uQ=["dxTagBox","dxRangeSlider","dxDateRangeBox"],hQ=["dxRangeSlider","dxSlider"],pQ=["dxCalendar","dxCheckBox","dxHtmlEditor","dxRadioGroup","dxRangeSlider","dxSlider","dxSwitch"],gQ=["dxSelectBox","dxDropDownBox","dxTagBox","dxLookup","dxAutocomplete","dxColorBox","dxDateBox","dxDateRangeBox"];function PV(i){let{$parent:e,rootElementCssClassList:t,formOrLayoutManager:n,createComponentCallback:o,item:s,template:r,labelTemplate:a,name:l,formLabelLocation:d,requiredMessageTemplate:c,validationGroup:h,editorValue:p,canAssignUndefinedValueToEditor:g,editorValidationBoundary:C,editorStylingMode:v,showColonAfterLabel:b,managerLabelLocation:T,itemId:R,managerMarkOptions:U,labelMode:Q,onLabelTemplateRendered:se}=i,re=f(s.isRequired)?s.isRequired:!!_Q(s.validationRules),Re=s.itemType===Du,we=s.helpText?`dx-${new Oe}`:null,We=CQ({item:s,id:R,isRequired:re,managerMarkOptions:U,showColonAfterLabel:b,labelLocation:T,formLabelMode:Q,labelTemplate:a,onLabelTemplateRendered:se}),gi=We.visible&&(We.text||We.labelTemplate&&Re),{location:gt,labelID:oo}=We,zr=gt!=="top"&&["dxTextArea","dxRadioGroup","dxCalendar","dxHtmlEditor"].includes(s.editorType),bn=fQ({$parent:e,editorType:s.editorType,editorValue:p,defaultEditorName:s.dataField,canAssignUndefinedValueToEditor:g,externalEditorOptions:s.editorOptions,editorInputId:R,editorValidationBoundary:C,editorStylingMode:v,formLabelMode:Q,labelText:We.textWithoutColon,labelMark:We.markOptions.showRequiredMark?"\xA0"+We.markOptions.requiredMark:""}),rE=We.markOptions.showOptionalMark&&!We.visible&&bn.labelMode!=="hidden"&&!f(s.helpText)?We.markOptions.optionalMark:s.helpText;return{$parent:e,rootElementCssClassList:t,formOrLayoutManager:n,createComponentCallback:o,labelOptions:We,labelNeedBaselineAlign:zr,labelLocation:gt,needRenderLabel:gi,item:s,isSimpleItem:Re,isRequired:re,template:r,helpID:we,labelID:oo,name:l,helpText:rE,formLabelLocation:d,requiredMessageTemplate:c,validationGroup:h,editorOptions:bn}}function kV(i){let{showRequiredMark:e,requiredMark:t,showOptionalMark:n,optionalMark:o}=i;return!e&&!n?"":"\xA0"+(e?t:o)}function hO(i,e){let{showRequiredMark:t,requiredMark:n,showOptionalMark:o,optionalMark:s}=i;return{showRequiredMark:t&&e,requiredMark:n,showOptionalMark:o&&!e,optionalMark:s}}function mQ(i,e,t){return gQ.includes(e)?{onPopupInitialized:o=>{let{component:s,popup:r}=o,a=s.option("openOnFieldClick"),l=r.option("hideOnOutsideClick");if(a&&A(l)){let d=c=>{let h=u(c.target),p=i.find(`label[for="${t}"]`);return!!!h.closest(p).length&&l(c)};s.option("dropDownOptions",{hideOnOutsideClick:d}),r.option({hideOnOutsideClick:d})}}}:{}}function fQ(i){let{$parent:e,editorType:t,defaultEditorName:n,editorValue:o,canAssignUndefinedValueToEditor:s,externalEditorOptions:r,editorInputId:a,editorValidationBoundary:l,editorStylingMode:d,formLabelMode:c,labelText:h,labelMark:p}=i,g={};(o!==void 0||s)&&(g.value=o),uQ.includes(t)&&(g.value=g.value||[]);let C=r?.labelMode;f(C)||(C=c==="outside"?"hidden":c);let v=r?.stylingMode||d,b=hQ.includes(t),T=mQ(e,t,a),R=m(!0,g,r,T,{inputAttr:{id:a},validationBoundary:l,stylingMode:v,label:b?r?.label:h,labelMode:C,labelMark:p});return r&&(R.dataSource&&(R.dataSource=r.dataSource),R.items&&(R.items=r.items)),n&&!R.name&&(R.name=n),R}function _Q(i){let e;return i&&i.length&&x(i,(t,n)=>{if(n.type==="required")return e=!0,!1}),e}function CQ(i){let{item:e,id:t,isRequired:n,managerMarkOptions:o,showColonAfterLabel:s,labelLocation:r,labelTemplate:a,formLabelMode:l,onLabelTemplateRendered:d}=i,c=pQ.includes(e.editorType),h=m({showColon:s,location:r,id:t,visible:l==="outside"||c&&l!=="hidden",isRequired:n},e?e.label:{},{markOptions:hO(o,n),labelTemplate:a,onLabelTemplateRendered:d});return["dxRadioGroup","dxCheckBox","dxLookup","dxSlider","dxRangeSlider","dxSwitch","dxHtmlEditor","dxDateRangeBox"].includes(e.editorType)&&(h.labelID=`dx-label-${new Oe}`),!h.text&&e.dataField&&(h.text=kn(e.dataField)),h.text&&(h.textWithoutColon=h.text,h.text+=h.showColon?":":""),h}var xQ="dx-field-item-required-mark";var vQ="dx-field-item-optional-mark";function BV(i){let{text:e,id:t,location:n,alignment:o,labelID:s=null,markOptions:r={},labelTemplate:a,labelTemplateData:l,onLabelTemplateRendered:d}=i;if((!f(e)||e.length<=0)&&!f(a))return null;let c=u("<label>").addClass(`${lO} dx-field-item-label-location-${n}`).attr("for",t).attr("id",s).css("textAlign",o),h=u("<span>").addClass(aO),p=u("<span>").addClass("dx-field-item-label-text").text(e);return a&&(p=u("<div>").addClass("dx-field-item-custom-label-content"),l.text=e,a.render({container:N(p),model:l,onRendered(){d?.()}})),c.append(h.append(p,bQ(r)))}function bQ(i){let e=kV(i);return e===""?null:u("<span>").addClass(i.showRequiredMark?xQ:vQ).text(e)}function VV(i,e,t){let n=`${e} > .${lO}:not(.dx-field-item-label-location-top) > .${aO}`,o=i.find(n),s=o.length,r,a,l=0;for(a=0;a<s;a++)r=yQ(o[a]),r>l&&(l=r);for(a=0;a<s;a++)o[a].style.width=`${l}px`}function yQ(i){let e=0,t=i.children.length;for(let n=0;n<t;n++){let o=i.children[n];e+=o.offsetWidth}return e}var $V="dx-field-item-content-wrapper";var OQ="dx-template-wrapper",pO="dx-validation-target",SQ="dx-invalid";function zV(i){let{$parent:e,rootElementCssClassList:t,formOrLayoutManager:n,createComponentCallback:o,labelOptions:s,labelNeedBaselineAlign:r,labelLocation:a,needRenderLabel:l,formLabelLocation:d,item:c,editorOptions:h,isSimpleItem:p,isRequired:g,template:C,helpID:v,labelID:b,name:T,helpText:R,requiredMessageTemplate:U,validationGroup:Q}=i,se=u("<div>").addClass(t.join(" ")).appendTo(e);se.addClass(g?"dx-field-item-required":"dx-field-item-optional"),p&&se.addClass("dx-flex-layout"),p&&r&&se.addClass("dx-field-item-label-align");let re=u("<div>");re.data("dx-form-item",c),re.addClass(Iu).addClass("dx-field-item-content-location-"+{right:"left",left:"right",top:"bottom"}[d]);let Re=null;if(l&&(s.labelTemplate&&(s.labelTemplateData=HV(c,h,n)),Re=BV(s)),Re){let{editorType:gt}=c;se.append(Re),(a==="top"||a==="left")&&se.append(re),a==="right"&&se.prepend(re),a==="top"?se.addClass("dx-label-v-align"):se.addClass("dx-label-h-align"),(gt==="dxCheckBox"||gt==="dxSwitch")&&_.on(Re,oe,()=>{_.trigger(re.children(),oe)});let zr=["dxCheckBox","dxSwitch","dxRadioGroup"].includes(gt),bn=s.alignment;!C&&zr&&a==="top"&&(bn==="left"||!bn)&&re.addClass("dx-toggle-controls-paddings")}else se.append(re);let we;if(C)C.render({container:N(re),model:HV(c,h,n),onRendered(){let gt=LV(re),oo=EQ(gt);NV(oo)}});else{let gt=u("<div>").appendTo(re);try{we=o(gt,c.editorType,h),we.setAria("describedby",v),b&&we.setAria("labelledby",b),we.setAria("required",g)}catch(oo){Z.log("E1035",oo.message)}}let We=LV(re),gi=We&&We.data(pO);if(gi){let gt=c.label&&c.label.text,oo=gt?null:T,zr=gt?c.label.text:oo&&kn(oo),bn;if(p)if(c.validationRules)bn=c.validationRules;else{let vf=Ii(U,zr||"");bn=c.isRequired?[{type:"required",message:vf}]:null}Array.isArray(bn)&&bn.length&&o(We,xm,{validationRules:bn,validationGroup:Q,dataGetter:()=>({formItem:c})}),NV(gi)}return R&&p&&re.parent().append(u("<div>").addClass($V).append(re).append(u("<div>").addClass("dx-field-item-help-text").attr("id",v).text(R))),{$fieldEditorContainer:re,$rootElement:se,widgetInstance:we}}function LV(i){let e=i.children().first();return e.hasClass(OQ)?e.children().first():e}function EQ(i){var e;return i?.data(pO)||(i==null||(e=i.parent)===null||e===void 0||(e=e.call(i))===null||e===void 0?void 0:e.data(pO))}function NV(i){if(i&&pt()){let e=`.${$V}`,t=n=>{let{element:o,component:s}=n,{isValid:r,validationMessageMode:a}=s.option();u(o).parents(e).toggleClass(SQ,r===!1&&(s._isFocused()||a==="always"))};i.on("optionChanged",n=>{n.name==="isValid"&&t(n)}),i.on("focusIn",t).on("focusOut",t).on("enterKey",t)}}function HV(i,e,t){return{dataField:i.dataField,editorType:i.editorType,editorOptions:e,component:t,name:i.name}}var md=class{constructor(){this._map={}}_findWidgetInstance(e){let t;return x(this._map,(n,o)=>{let{widgetInstance:s,item:r}=o;if(e(r))return t=s,!1}),t}_findFieldByCondition(e,t){let n;return x(this._map,(o,s)=>{if(e(s))return n=t==="guid"?o:s[t],!1}),n}clear(){this._map={}}removeItemsByItems(e){x(e.getItems(),t=>this.removeItemByKey(t))}removeItemByKey(e){delete this._map[e]}add(e){let t=e.guid||new Oe;return this._map[t]=e,t}addItemsOrExtendFrom(e){e.each((t,n)=>{this._map[t]?(n.widgetInstance&&(this._map[t].widgetInstance=n.widgetInstance),this._map[t].$itemContainer=n.$itemContainer):this.add({item:n.item,widgetInstance:n.widgetInstance,guid:t,$itemContainer:n.$itemContainer})})}extendRunTimeItemInfoByKey(e,t){this._map[e]&&(this._map[e]=m(this._map[e],t))}findWidgetInstanceByItem(e){return this._findWidgetInstance(t=>t===e)}findGroupOrTabLayoutManagerByPath(e){return this._findFieldByCondition(t=>{let{path:n}=t;return n===e},"layoutManager")}findKeyByPath(e){return this._findFieldByCondition(t=>{let{path:n}=t;return n===e},"guid")}findWidgetInstanceByName(e){return this._findWidgetInstance(t=>e===t.name)}findWidgetInstanceByDataField(e){return this._findWidgetInstance(t=>e===(B(t)?t:t.dataField))}findItemContainerByItem(e){for(let t in this._map)if(this._map[t].item===e)return this._map[t].$itemContainer;return null}findItemIndexByItem(e){return this._findFieldByCondition(t=>{let{item:n}=t;return n===e},"itemIndex")}findPreparedItemByItem(e){return this._findFieldByCondition(t=>{let{item:n}=t;return n===e},"preparedItem")}getItems(){return this._map}each(e){x(this._map,(t,n)=>{e(t,n)})}removeItemsByPathStartWith(e){Object.keys(this._map).filter(o=>this._map[o].path?this._map[o].path.indexOf(e,0)>-1:!1).forEach(o=>this.removeItemByKey(o))}};var wQ=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{layoutData:{},readOnly:!1,colCount:1,colCountByScreen:void 0,labelLocation:"left",onFieldDataChanged:null,onEditorEnterKey:null,customizeItem:null,alignItemLabels:!0,minColWidth:200,showRequiredMark:!0,screenByWidth:null,showOptionalMark:!1,requiredMark:"*",labelMode:"outside",optionalMark:O.format("dxForm-optionalMark"),requiredMessage:O.getFormatter("dxForm-requiredMessage")})},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{layoutData:!0,validationGroup:!0})},_init(){let i=this.option("layoutData");this.callBase(),this._itemWatchers=[],this._itemsRunTimeInfo=new md,this._updateReferencedOptions(i),this._initDataAndItems(i)},_dispose(){this.callBase(),this._cleanItemWatchers()},_initDataAndItems(i){this._syncDataWithItems(),this._updateItems(i)},_syncDataWithItems(){let i=this.option("layoutData"),e=this.option("items");f(e)&&e.forEach(t=>{if(t.dataField&&this._getDataByField(t.dataField)===void 0){let n;t.editorOptions&&(n=t.editorOptions.value),(f(n)||t.dataField in i)&&this._updateFieldValue(t.dataField,n)}})},_getDataByField(i){return i?this.option(`layoutData.${i}`):null},_isCheckboxUndefinedStateEnabled(i){let{allowIndeterminateState:e,editorType:t,dataField:n}=i;if(e===!0&&t==="dxCheckBox"){let o=["layoutData",...n.split(".")],s=o.pop(),r=this.option(o.join("."));return r&&s in r}return!1},_updateFieldValue(i,e){let t=this.option("layoutData"),n=e;!It.isWrapped(t[i])&&f(i)?this.option(`layoutData.${i}`,n):It.isWritableWrapped(t[i])&&(n=A(n)?n():n,t[i](n)),this._triggerOnFieldDataChanged({dataField:i,value:n})},_triggerOnFieldDataChanged(i){this._createActionByOption("onFieldDataChanged")(i)},_updateItems(i){let e=this,t=this.option("items"),n=f(t),o=e.option("customizeItem"),s=n?t:this._generateItemsByData(i);if(f(s)){let r=[];x(s,(a,l)=>{e._isAcceptableItem(l)&&(l=e._processItem(l),o&&o(l),$(l)&&It.unwrap(l.visible)!==!1&&r.push(l))}),(!e._itemWatchers.length||!n)&&e._updateItemWatchers(s),this._setItems(r),this._sortItems()}},_cleanItemWatchers(){this._itemWatchers.forEach(i=>{i()}),this._itemWatchers=[]},_updateItemWatchers(i){let e=this,t=e._getWatch();i.forEach(n=>{$(n)&&f(n.visible)&&A(t)&&e._itemWatchers.push(t(()=>It.unwrap(n.visible),()=>{e._updateItems(e.option("layoutData")),e.repaint()},{skipImmediate:!0}))})},_generateItemsByData(i){let e=[];return f(i)&&x(i,t=>{e.push({dataField:t})}),e},_isAcceptableItem(i){let e=i.dataField||i,t=this._getDataByField(e);return!(A(t)&&!It.isWrapped(t))},_processItem(i){if(typeof i=="string"&&(i={dataField:i}),typeof i=="object"&&!i.itemType&&(i.itemType=Du),!f(i.editorType)&&f(i.dataField)){let e=this._getDataByField(i.dataField);i.editorType=f(e)?this._getEditorTypeByDataType(ri(e)):"dxTextBox"}return i.editorType==="dxCheckBox"&&(i.allowIndeterminateState=i.allowIndeterminateState??!0),i},_getEditorTypeByDataType(i){switch(i){case"number":return"dxNumberBox";case"date":return"dxDateBox";case"boolean":return"dxCheckBox";default:return"dxTextBox"}},_sortItems(){ta(this._items,"visibleIndex"),this._sortIndexes()},_sortIndexes(){this._items.sort((i,e)=>{let t=i.visibleIndex,n=e.visibleIndex,o;return t>n?o=1:t<n?o=-1:o=0,o})},_initMarkup(){this._itemsRunTimeInfo.clear(),this.$element().addClass(wV),this.callBase(),this._renderResponsiveBox()},_renderResponsiveBox(){let i=this,e=[];if(i._items&&i._items.length){let t=i._getColCount(),n=u("<div>").appendTo(i.$element());i._prepareItemsWithMerging(t);let o=i._generateLayoutItems();i._responsiveBox=i._createComponent(n,xV,i._getResponsiveBoxConfig(o,t,e)),W()||i._renderTemplates(e)}},_itemStateChangedHandler(i){this._refresh()},_renderTemplates(i){let e=this,t=0;i.forEach(n=>{var o;let{item:s}=n;s!=null&&(o=s.label)!==null&&o!==void 0&&o.template&&t++}),x(i,(n,o)=>{switch(o.itemType){case"empty":oO(o);break;case"button":e._renderButtonItem(o);break;default:e._renderFieldItem(o,t)}})},_getResponsiveBoxConfig(i,e,t){let n=this,o=n.option("colCountByScreen"),s=o&&o.xs;return{onItemStateChanged:this._itemStateChangedHandler.bind(this),onLayoutChanged(){let r=n.option("onLayoutChanged"),a=n.isSingleColumnMode();r&&(n.$element().toggleClass(rO,a),r(a))},onContentReady(r){W()&&n._renderTemplates(t),n.option("onLayoutChanged")&&n.$element().toggleClass(rO,n.isSingleColumnMode(r.component))},itemTemplate(r,a,l){if(!r.location)return;let d=u(l),c=r.location.row*e,h=n._items[r.location.col+c];if(!h)return;let p=[h.cssClass];d.toggleClass(IV,n.isSingleColumnMode(this)),r.location.row===0&&p.push("dx-first-row"),r.location.col===0&&p.push("dx-first-col"),h.itemType===Du&&n.option("isRoot")&&d.addClass(ym);let g=r.location.col===e-1||r.location.col+r.location.colspan===e,C=n._getRowsCount(),v=r.location.row===C-1;g&&p.push("dx-last-col"),v&&p.push("dx-last-row"),h.itemType!=="empty"&&(p.push(bm),p.push(n.option("cssItemClass")),f(h.col)&&p.push(`dx-col-${h.col}`)),t.push({itemType:h.itemType,item:h,$parent:d,rootElementCssClassList:p})},cols:n._generateRatio(e),rows:n._generateRatio(n._getRowsCount(),!0),dataSource:i,screenByWidth:n.option("screenByWidth"),singleColumnScreen:s?!1:"xs"}},_getColCount(){let i=this.option("colCount"),e=this.option("colCountByScreen");if(e){let t=this.option("form").getTargetScreenFactor();t||(t=W()?nh(this.option("screenByWidth")):"lg"),i=e[t]||i}if(i==="auto"){if(this._cashedColCount)return this._cashedColCount;this._cashedColCount=i=this._getMaxColCount()}return i<1?1:i},_getMaxColCount(){if(!W())return 1;let i=this.option("minColWidth"),e=z(this.$element()),t=this._items.length,n=Math.floor(e/i)||1;return t<n?t:n},isCachedColCountObsolete(){return this._cashedColCount&&this._getMaxColCount()!==this._cashedColCount},_prepareItemsWithMerging(i){let e=this._items.slice(0),t,n,o=[],s,r;for(r=0;r<e.length;r++)if(t=e[r],o.push(t),(this.option("alignItemLabels")||t.alignItemLabels||t.colSpan)&&(t.col=this._getColByIndex(o.length-1,i)),t.colSpan>1&&t.col+t.colSpan<=i){for(n=[],s=0;s<t.colSpan-1;s++)n.push({merged:!0});o=o.concat(n)}else delete t.colSpan;this._setItems(o)},_getColByIndex:(i,e)=>i%e,_setItems(i){this._items=i,this._cashedColCount=null},_generateLayoutItems(){let i=this._items,e=this._getColCount(),t=[],n,o;for(o=0;o<i.length;o++)if(n=i[o],!n.merged){let s={location:{row:parseInt(o/e),col:this._getColByIndex(o,e)}};f(n.disabled)&&(s.disabled=n.disabled),f(n.visible)&&(s.visible=n.visible),f(n.colSpan)&&(s.location.colspan=n.colSpan),f(n.rowSpan)&&(s.location.rowspan=n.rowSpan),t.push(s)}return t},_renderEmptyItem(i){oO({$container:i})},_renderButtonItem(i){let{item:e,$parent:t,rootElementCssClassList:n}=i,{$rootElement:o,buttonInstance:s}=vV({item:e,$parent:t,rootElementCssClassList:n,validationGroup:this.option("validationGroup"),createComponentCallback:this._createComponent.bind(this)});this._itemsRunTimeInfo.add({item:e,widgetInstance:s,guid:e.guid,$itemContainer:o})},_renderFieldItem(i,e){var t,n;let{item:o,$parent:s,rootElementCssClassList:r}=i,a=this._getDataByField(o.dataField),l=!1;if(a===void 0){let{allowIndeterminateState:C,editorType:v,dataField:b}=o;l=this._isCheckboxUndefinedStateEnabled({allowIndeterminateState:C,editorType:v,dataField:b})}let d=o.dataField||o.name,c=this._getFormOrThis(),{$fieldEditorContainer:h,widgetInstance:p,$rootElement:g}=zV(PV({$parent:s,rootElementCssClassList:r,item:o,name:d,editorValue:a,canAssignUndefinedValueToEditor:l,formOrLayoutManager:this._getFormOrThis(),createComponentCallback:this._createComponent.bind(this),formLabelLocation:this.option("labelLocation"),requiredMessageTemplate:this.option("requiredMessage"),validationGroup:this.option("validationGroup"),editorValidationBoundary:this.option("validationBoundary"),editorStylingMode:this.option("form")&&this.option("form").option("stylingMode"),showColonAfterLabel:this.option("showColonAfterLabel"),managerLabelLocation:this.option("labelLocation"),template:o.template?this._getTemplate(o.template):null,labelTemplate:(t=o.label)!==null&&t!==void 0&&t.template?this._getTemplate(o.label.template):null,itemId:this.option("form")&&this.option("form").getItemID(d),managerMarkOptions:this._getMarkOptions(),labelMode:this.option("labelMode"),onLabelTemplateRendered:()=>{this._incTemplateRenderedCallCount(),this._shouldAlignLabelsOnTemplateRendered(c,e)&&c._alignLabels(this,this.isSingleColumnMode(c))}}));(n=this.option("onFieldItemRendered"))===null||n===void 0||n(),p&&o.dataField&&this._bindDataField(p,o.dataField,o.editorType,h),this._itemsRunTimeInfo.add({item:o,widgetInstance:p,guid:o.guid,$itemContainer:g})},_incTemplateRenderedCallCount(){this._labelTemplateRenderedCallCount=(this._labelTemplateRenderedCallCount??0)+1},_shouldAlignLabelsOnTemplateRendered(i,e){return i.option("templatesRenderAsynchronously")&&this._labelTemplateRenderedCallCount===e},_getMarkOptions(){return{showRequiredMark:this.option("showRequiredMark"),requiredMark:this.option("requiredMark"),showOptionalMark:this.option("showOptionalMark"),optionalMark:this.option("optionalMark")}},_getFormOrThis(){return this.option("form")||this},_bindDataField(i,e,t,n){let o=this._getFormOrThis();i.on("enterKey",s=>{o._createActionByOption("onEditorEnterKey")(m(s,{dataField:e}))}),this._createWatcher(i,n,e),this.linkEditorToDataField(i,e,t)},_createWatcher(i,e,t){let n=this,o=n._getWatch();if(!A(o))return;let s=o(()=>n._getDataByField(t),()=>{let r=n._getDataByField(t);if(i.NAME==="dxTagBox"){let a=i.option("value");if(r!==a&&function(l,d){if(!Array.isArray(l)||!Array.isArray(d)||l.length!==d.length)return!1;for(let c=0;c<l.length;c++)if(l[c]!==d[c])return!1;return!0}(r,a))return}i.option("value",r)},{deep:!0,skipImmediate:!0},{createWatcherDataField:t});_.on(e,Gt,s)},_getWatch(){if(!f(this._watch)){let i=this.option("form");this._watch=i&&i.option("integrationOptions.watchMethod")}return this._watch},_createComponent(i,e,t){let n=this.option("readOnly"),o=Object.hasOwn(t,"readOnly"),s=this.callBase(i,e,I({},t,{readOnly:o?t.readOnly:n})),r=!1;return s.on("optionChanged",a=>{a.name==="readOnly"&&!r&&(o=!0)}),this.on("optionChanged",a=>{a.name==="readOnly"&&!o&&(r=!0,s.option(a.name,a.value),r=!1)}),s},_generateRatio(i,e){let t=[],n,o;for(o=0;o<i;o++)n={ratio:1},e&&(n.baseSize="auto"),t.push(n);return t},_getRowsCount(){return Math.ceil(this._items.length/this._getColCount())},_updateReferencedOptions(i){let e=this.option("layoutData");$(e)&&Object.getOwnPropertyNames(e).forEach(t=>delete this._optionsByReference[`layoutData.${t}`]),$(i)&&Object.getOwnPropertyNames(i).forEach(t=>this._optionsByReference[`layoutData.${t}`]=!0)},_clearWidget(i){this._disableEditorValueChangedHandler=!0,i.clear(),this._disableEditorValueChangedHandler=!1,i.option("isValid",!0)},_optionChanged(i){if(i.fullName.search("layoutData.")!==0)switch(i.name){case"showRequiredMark":case"showOptionalMark":case"requiredMark":case"optionalMark":this._cashedRequiredConfig=null,this._invalidate();break;case"layoutData":this._updateReferencedOptions(i.value),this.option("items")?dt(i.value)||this._itemsRunTimeInfo.each((e,t)=>{if(f(t.item)){let{dataField:n}=t.item;if(n&&f(t.widgetInstance)){let s=me(n)(i.value),{allowIndeterminateState:r,editorType:a}=t.item;s!==void 0||this._isCheckboxUndefinedStateEnabled({allowIndeterminateState:r,editorType:a,dataField:n})?t.widgetInstance.option("value",s):this._clearWidget(t.widgetInstance)}}}):(this._initDataAndItems(i.value),this._invalidate());break;case"items":this._cleanItemWatchers(),this._initDataAndItems(i.value),this._invalidate();break;case"alignItemLabels":case"labelLocation":case"labelMode":case"requiredMessage":this._invalidate();break;case"customizeItem":this._updateItems(this.option("layoutData")),this._invalidate();break;case"colCount":case"colCountByScreen":this._resetColCount();break;case"minColWidth":this.option("colCount")==="auto"&&this._resetColCount();break;case"readOnly":case"onFieldDataChanged":break;case"width":this.callBase(i),this.option("colCount")==="auto"&&this._resetColCount();break;default:this.callBase(i)}},_resetColCount(){this._cashedColCount=null,this._invalidate()},linkEditorToDataField(i,e){this.on("optionChanged",t=>{t.fullName===`layoutData.${e}`&&i._setOptionWithoutOptionChange("value",t.value)}),i.on("valueChanged",t=>{let n=$(t.value)||Array.isArray(t.value);!this._disableEditorValueChangedHandler&&!(n&&t.value===t.previousValue)&&this._updateFieldValue(e,t.value)})},_dimensionChanged(){this.option("colCount")==="auto"&&this.isCachedColCountObsolete()&&this._eventsStrategy.fireEvent("autoColCountChanged")},updateData(i,e){let t=this;$(i)?x(i,(n,o)=>{t._updateFieldValue(n,o)}):typeof i=="string"&&t._updateFieldValue(i,e)},getEditor(i){return this._itemsRunTimeInfo.findWidgetInstanceByDataField(i)||this._itemsRunTimeInfo.findWidgetInstanceByName(i)},isSingleColumnMode(i){let e=this._responsiveBox||i;if(e)return e.option("currentScreenFactor")===e.option("singleColumnScreen")},getItemsRunTimeInfo(){return this._itemsRunTimeInfo}});G("dxLayoutManager",wQ);var IQ="dx-validationsummary-item",DQ="dx-validationsummary-item-data",WV=In.inherit({_getDefaultOptions(){return m(this.callBase(),{focusStateEnabled:!1,noDataText:null})},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{validationGroup:!0})},_init(){this.callBase(),this._initGroupRegistration()},_initGroupRegistration(){let i=this.$element(),e=this.option("validationGroup")||yi.findGroup(i,this._modelByElement(i)),t=yi.addGroup(e,!0);this._unsubscribeGroup(),this._groupWasInit=!0,this._validationGroup=e,this.groupSubscription=this._groupValidationHandler.bind(this),t.on("validated",this.groupSubscription)},_unsubscribeGroup(){let i=yi.getGroupConfig(this._validationGroup);i&&i.off("validated",this.groupSubscription)},_getOrderedItems(i,e){let t=[];return x(i,(n,o)=>{let s=xt(e,r=>{if(r.validator===o)return!0});s.length&&(t=t.concat(s))}),t},_groupValidationHandler(i){let e=this._getOrderedItems(i.validators,He(i.brokenRules,t=>({text:t.message,validator:t.validator,index:t.index})));this.validators=i.validators,x(this.validators,(t,n)=>{if(n._validationSummary!==this){let o=this._itemValidationHandler.bind(this),s=function(){n.off("validated",o),n._validationSummary=null,o=null};n.on("validated",o),n.on("disposing",s),n._validationSummary=this}}),this.option("items",e)},_itemValidationHandler(i){let{isValid:e,validator:t,brokenRules:n}=i,o=this.option("items"),s=!1,r=0;for(;r<o.length;){let a=o[r];if(a.validator===t){let l=xt(n||[],d=>d.index===a.index)[0];if(e||!l){o.splice(r,1),s=!0;continue}l.message!==a.text&&(a.text=l.message,s=!0)}r++}x(n,(a,l)=>{xt(o,c=>c.validator===t&&c.index===l.index)[0]||(o.push({text:l.message,validator:t,index:l.index}),s=!0)}),s&&(o=this._getOrderedItems(this.validators,o),this.option("items",o))},_initMarkup(){this.$element().addClass("dx-validationsummary"),this.callBase()},_optionChanged(i){i.name==="validationGroup"?this._initGroupRegistration():this.callBase(i)},_itemClass:()=>IQ,_itemDataKey:()=>DQ,_postprocessRenderItem(i){_.on(i.itemElement,"click",()=>{i.itemData.validator&&i.itemData.validator.focus&&i.itemData.validator.focus()})},_dispose(){this.callBase(),this._unsubscribeGroup()},refreshValidationGroup(){this._initGroupRegistration()}});G("dxValidationSummary",WV);var gO=WV;var mO=class extends Qi{_getDefaultOptions(){return super._getDefaultOptions()}_init(){super._init(),yi.addGroup(this,!1)}_initMarkup(){let e=this.$element();e.addClass("dx-validationgroup"),e.find(".dx-validator").each((t,n)=>{Cm.getInstance(u(n))._initGroupRegistration()}),e.find(".dx-validationsummary").each((t,n)=>{gO.getInstance(u(n)).refreshValidationGroup()}),super._initMarkup()}validate(){return yi.validateGroup(this)}reset(){return yi.resetGroup(this)}_dispose(){yi.removeGroup(this),this.$element().removeClass("dx-validationgroup"),super._dispose()}_useTemplates(){return!1}};G("dxValidationGroup",mO);var Tu={move(i,e){Ae(i,{left:e})}},Om={moveTo(i,e,t,n){pe.animate(i,{type:"slide",to:{left:e},duration:t,complete:n})},complete(i){pe.stop(i,!0)}};var GV=i=>+i,TQ=i=>li(i).left,KV=mr.inherit({_activeStateUnit:".dx-multiview-item",_supportedKeys(){return m(this.callBase(),{pageUp:S,pageDown:S})},_getDefaultOptions(){return m(this.callBase(),{selectedIndex:0,swipeEnabled:!0,animationEnabled:!0,loop:!1,deferRendering:!0,loopItemFocus:!1,selectOnFocus:!0,selectionMode:"single",selectionRequired:!0,selectByClick:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}}])},_itemClass:()=>"dx-multiview-item",_itemDataKey:()=>"dxMultiViewItemData",_itemContainer(){return this._$itemContainer},_itemElements(){return this._itemContainer().children(this._itemSelector())},_itemWidth(){return this._itemWidthValue||(this._itemWidthValue=z(this._$wrapper)),this._itemWidthValue},_clearItemWidthCache(){delete this._itemWidthValue},_itemsCount(){return this.option("items").length},_normalizeIndex(i){let e=this._itemsCount();return i<0&&(i+=e),i>=e&&(i-=e),i},_getRTLSignCorrection(){return this.option("rtlEnabled")?-1:1},_init(){this.callBase.apply(this,arguments);let i=this.$element();i.addClass("dx-multiview"),this._$wrapper=u("<div>").addClass("dx-multiview-wrapper"),this._$wrapper.appendTo(i),this._$itemContainer=u("<div>").addClass("dx-multiview-item-container"),this._$itemContainer.appendTo(this._$wrapper),this.option("loopItemFocus",this.option("loop")),this._findBoundaryIndices(),this._initSwipeable()},_initMarkup(){this._deferredItems=[],this.callBase();let i=this._getSelectedItemIndices();this._updateItemsVisibility(i[0]),this._setElementAria(),this._setItemsAria()},_afterItemElementDeleted(i,e){this.callBase(i,e),this._deferredItems&&this._deferredItems.splice(e.itemIndex,1)},_beforeItemElementInserted(i){this.callBase.apply(this,arguments),this._deferredItems&&this._deferredItems.splice(i.index,0,null)},_executeItemRenderAction(i,e,t){i=(this.option("items")||[]).indexOf(e),this.callBase(i,e,t)},_renderItemContent(i){let e=y(),t=this,{callBase:n}=this,o=y();return o.done(()=>{let s=n.call(t,i);e.resolve(s)}),this._deferredItems[i.index]=o,this.option("deferRendering")||o.resolve(),e.promise()},_render(){this.callBase(),nt(()=>{let i=this._getSelectedItemIndices();this._updateItems(i[0])})},_getElementAria:()=>({role:"group",roledescription:O.format("dxMultiView-elementAriaRoleDescription"),label:O.format("dxMultiView-elementAriaLabel")}),_setElementAria(){let i=this._getElementAria();this.setAria(i,this.$element())},_setItemsAria(){let i=this._itemElements(),e=this._itemsCount();i.each((t,n)=>{let o=this._getItemAria({itemIndex:t,itemsCount:e});this.setAria(o,u(n))})},_getItemAria(i){let{itemIndex:e,itemsCount:t}=i;return{role:"group",roledescription:O.format("dxMultiView-itemAriaRoleDescription"),label:O.format("dxMultiView-itemAriaLabel",e+1,t)}},_updateItems(i,e){this._updateItemsPosition(i,e),this._updateItemsVisibility(i,e)},_modifyByChanges(){this.callBase.apply(this,arguments);let i=this._getSelectedItemIndices();this._updateItemsVisibility(i[0])},_updateItemsPosition(i,e){let t=this._itemElements(),n=f(e)?-this._animationDirection(e,i):void 0,o=t.eq(i);Tu.move(o,0),f(e)&&Tu.move(t.eq(e),100*n+"%")},_updateItemsVisibility(i,e){this._itemElements().each((n,o)=>{let s=u(o),r=n!==i&&n!==e;r||this._renderSpecificItem(n),s.toggleClass("dx-multiview-item-hidden",r),this.setAria("hidden",r||void 0,s)})},_renderSpecificItem(i){let e=this._itemElements().eq(i),t=e.find(this._itemContentClass()).length>0;f(i)&&!t&&(this._deferredItems[i].resolve(),bi(e))},_refreshItem(i,e){this.callBase(i,e),this._updateItemsVisibility(this.option("selectedIndex"))},_setAriaSelectionAttribute:S,_updateSelection(i,e){let t=i[0],n=e[0];Om.complete(this._$itemContainer),this._updateItems(n,t);let o=this._animationDirection(t,n);this._animateItemContainer(o*this._itemWidth(),()=>{Tu.move(this._$itemContainer,0),this._updateItems(t),z(this._$itemContainer)})},_animateItemContainer(i,e){let t=this.option("animationEnabled")?200:0;Om.moveTo(this._$itemContainer,i,t,e)},_animationDirection(i,e){let t=TQ(this._$itemContainer),n=(e-i)*this._getRTLSignCorrection()*this._getItemFocusLoopSignCorrection();return Co(t!==0?t:n)},_getSwipeDisabledState(){return!this.option("swipeEnabled")||this._itemsCount()<=1},_initSwipeable(){this._createComponent(this.$element(),Ns,{disabled:this._getSwipeDisabledState(),elastic:!1,itemSizeFunc:this._itemWidth.bind(this),onStart:i=>this._swipeStartHandler(i.event),onUpdated:i=>this._swipeUpdateHandler(i.event),onEnd:i=>this._swipeEndHandler(i.event)})},_findBoundaryIndices(){let i=this.option("items"),e,t;i.forEach((n,o)=>{!!n?.disabled||(e??(e=o),t=o)}),this._boundaryIndices={firstAvailableIndex:e??0,lastAvailableIndex:t??i.length-1,firstTrueIndex:0,lastTrueIndex:i.length-1}},_swipeStartHandler(i){Om.complete(this._$itemContainer);let e=this.option("selectedIndex"),t=this.option("loop"),{firstAvailableIndex:n,lastAvailableIndex:o}=this._boundaryIndices,s=this.option("rtlEnabled");i.maxLeftOffset=GV(t||(s?e>n:e<o)),i.maxRightOffset=GV(t||(s?e<o:e>n)),this._swipeDirection=null},_swipeUpdateHandler(i){let{offset:e}=i,t=Co(e)*this._getRTLSignCorrection();if(Tu.move(this._$itemContainer,e*this._itemWidth()),t!==this._swipeDirection){this._swipeDirection=t;let n=this.option("selectedIndex"),o=this._normalizeIndex(n-t);this._updateItems(n,o)}},_findNextAvailableIndex(i,e){let{items:t,loop:n}=this.option(),{firstAvailableIndex:o,lastAvailableIndex:s,firstTrueIndex:r,lastTrueIndex:a}=this._boundaryIndices,l=[r,o].includes(i),d=[a,s].includes(i);if(n){if(l&&e<0)return s;if(d&&e>0)return o}for(let c=i+e;c>=o&&c<=s;c+=e)if(!!!t[c].disabled)return c;return i},_swipeEndHandler(i){let e=i.targetOffset*this._getRTLSignCorrection();if(e){let t=this._findNextAvailableIndex(this.option("selectedIndex"),-e);this.option("selectedIndex",t);let n=this.itemElements().filter(".dx-item-selected");this.option("focusStateEnabled")&&this.option("focusedElement",N(n))}else this._animateItemContainer(0,S)},_getItemFocusLoopSignCorrection(){return this._itemFocusLooped?-1:1},_moveFocus(){this.callBase.apply(this,arguments),this._itemFocusLooped=!1},_prevItem(i){let e=this.callBase.apply(this,arguments);return this._itemFocusLooped=e.is(i.last()),e},_nextItem(i){let e=this.callBase.apply(this,arguments);return this._itemFocusLooped=e.is(i.first()),e},_dimensionChanged(){this._clearItemWidthCache()},_visibilityChanged(i){i&&this._dimensionChanged()},_updateSwipeDisabledState(){let i=this._getSwipeDisabledState();Ns.getInstance(this.$element()).option("disabled",i)},_dispose(){delete this._boundaryIndices,this.callBase()},_optionChanged(i){let{value:e}=i;switch(i.name){case"loop":this.option("loopItemFocus",e);break;case"animationEnabled":break;case"swipeEnabled":this._updateSwipeDisabledState();break;case"deferRendering":this._invalidate();break;case"items":this._updateSwipeDisabledState(),this._findBoundaryIndices(),this.callBase(i);break;default:this.callBase(i)}}});G("dxMultiView",KV);var UV=KV;var jV=UV;function Sm(i){return i.scrollWidth-i.clientWidth}function qV(i){return i.scrollHeight-i.clientHeight}function YV(i,e){return Math.round(i)<=e}function XV(i,e,t){return Math.round(Sm(i)-e)<=t}function QV(i,e){return Math.round(i)<=e}function ZV(i,e,t,n){return Math.round(qV(i)-e-t)<=n}var fO="dx-tabs-expanded";var AQ=jn.inherit({_renderWatchers(){this.callBase(),this._startWatcher("badge",this._renderBadge.bind(this))},_renderBadge(i){if(this._$element.children(".dx-badge").remove(),!i)return;let e=u("<div>").addClass("dx-tabs-item-badge").addClass("dx-badge").text(i);this._$element.append(e)}}),JV=AQ;var eL={vertical:"dx-tabs-vertical",horizontal:"dx-tabs-horizontal"},tL={top:"dx-tab-indicator-position-top",right:"dx-tab-indicator-position-right",bottom:"dx-tab-indicator-position-bottom",left:"dx-tab-indicator-position-left"},Au={top:"dx-tabs-icon-position-top",end:"dx-tabs-icon-position-end",bottom:"dx-tabs-icon-position-bottom",start:"dx-tabs-icon-position-start"},_O={primary:"dx-tabs-styling-mode-primary",secondary:"dx-tabs-styling-mode-secondary"};var CO={horizontal:"horizontal",vertical:"vertical"},Em={top:"top",right:"right",bottom:"bottom",left:"left"},iL={horizontal:"horizontal",vertical:"vertical"},fd={top:"top",end:"end",bottom:"bottom",start:"start"},nL={primary:"primary",secondary:"secondary"},xO=mr.inherit({_activeStateUnit:".dx-tab",_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,showNavButtons:!0,scrollByContent:!0,scrollingEnabled:!0,selectionMode:"single",orientation:CO.horizontal,iconPosition:fd.start,stylingMode:nL.primary,activeStateEnabled:!0,selectionRequired:!1,selectOnFocus:!0,loopItemFocus:!1,useInkRipple:!1,badgeExpr:i=>i?i.badge:void 0,_itemAttributes:{role:"tab"},_indicatorPosition:null})},_defaultOptionsRules(){let i=ct();return this.callBase().concat([{device:()=>F.real().deviceType!=="desktop",options:{showNavButtons:!1}},{device:{deviceType:"desktop"},options:{scrollByContent:!1}},{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>ut(i),options:{iconPosition:fd.top,stylingMode:nL.secondary}},{device:()=>it(i),options:{useInkRipple:!0,selectOnFocus:!1,iconPosition:fd.top}}])},_init(){let{orientation:i,stylingMode:e,scrollingEnabled:t}=this.option(),n=this._getIndicatorPosition();this.callBase(),this.setAria("role","tablist"),this.$element().addClass("dx-tabs"),this._toggleScrollingEnabledClass(t),this._toggleOrientationClass(i),this._toggleIndicatorPositionClass(n),this._toggleIconPositionClass(),this._toggleStylingModeClass(e),this._renderWrapper(),this._renderMultiple(),this._feedbackHideTimeout=100},_prepareDefaultItemTemplate(i,e){let t=q(i)?i?.text:i;if(f(t)){let n=u("<span>").addClass("dx-tab-text-span");n.text(t);let o=u("<span>").addClass("dx-tab-text-span-pseudo");o.text(t),o.appendTo(n),n.appendTo(e)}f(i.html)&&e.html(i.html)},_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({item:new di((i,e)=>{this._prepareDefaultItemTemplate(e,i);let t=ci(e.icon);t&&t.prependTo(i);let n=u("<div>").addClass("dx-tab-text");i.wrapInner(n)},["text","html","icon"],this.option("integrationOptions.watchMethod"))})},_createItemByTemplate:function(i,e){let{itemData:t,container:n,index:o}=e;return this._deferredTemplates[o]=y(),i.render({model:t,container:n,index:o,onRendered:()=>this._deferredTemplates[o].resolve()})},_itemClass:()=>"dx-tab",_selectedItemClass:()=>"dx-tab-selected",_itemDataKey:()=>"dxTabData",_initMarkup(){this._deferredTemplates=[],this.callBase(),this.option("useInkRipple")&&this._renderInkRipple(),this.$element().addClass("dx-overflow-hidden")},_render(){this.callBase(),this._deferRenderScrolling()},_deferRenderScrolling(){P.apply(this,this._deferredTemplates).done(()=>this._renderScrolling())},_renderScrolling(){let i=["dx-tabs-stretched",fO,"dx-overflow-hidden"];if(this.$element().removeClass(i.join(" ")),this.option("scrollingEnabled")&&this._isItemsSizeExceeded()){this._scrollable||(this._renderScrollable(),this._renderNavButtons());let e=this.getScrollable();if(e.update(),this.option("rtlEnabled")){let t=Sm(u(this.getScrollable().container()).get(0));e.scrollTo({left:t})}this._updateNavButtonsState(),this._scrollToItem(this.option("selectedItem"))}this.option("scrollingEnabled")&&this._isItemsSizeExceeded()||(this._cleanScrolling(),this._needStretchItems()&&this.$element().addClass("dx-tabs-stretched"),this.$element().removeClass("dx-tabs-nav-buttons").addClass(fO))},_isVertical(){return this.option("orientation")===CO.vertical},_isItemsSizeExceeded(){return this._isVertical()?this._isItemsHeightExceeded():this._isItemsWidthExceeded()},_isItemsWidthExceeded(){let i=this._getVisibleItems(),e=this._getSummaryItemsSize("width",i,!0),t=z(this.$element());return[e,t].includes(0)?!1:e>t-1},_isItemsHeightExceeded(){let i=this._getVisibleItems(),e=this._getSummaryItemsSize("height",i,!0),t=Y(this.$element());return e-1>t},_needStretchItems(){let i=this._getVisibleItems(),e=z(this.$element()),t=[];x(i,(r,a)=>{t.push(ie(a,!0))});let n=Math.max.apply(null,t),o=e/i.length;return n>o+1},_cleanNavButtons(){!this._leftButton||!this._rightButton||(this._leftButton.$element().remove(),this._rightButton.$element().remove(),this._leftButton=null,this._rightButton=null)},_cleanScrolling(){this._scrollable&&(this._$wrapper.appendTo(this.$element()),this._scrollable.$element().remove(),this._scrollable=null,this._cleanNavButtons())},_renderInkRipple(){this._inkRipple=Sl()},_getPointerEvent:()=>ne.up,_toggleActiveState(i,e,t){if(this.callBase.apply(this,arguments),!this._inkRipple)return;let n={element:i,event:t};e?this._inkRipple.showWave(n):this._inkRipple.hideWave(n)},_renderMultiple(){this.option("selectionMode")==="multiple"&&this.option("selectOnFocus",!1)},_renderWrapper(){this._$wrapper=u("<div>").addClass("dx-tabs-wrapper"),this.$element().append(this._$wrapper)},_itemContainer(){return this._$wrapper},_getScrollableDirection(){return this._isVertical()?iL.vertical:iL.horizontal},_updateScrollable(){this.getScrollable()&&this._cleanScrolling(),this._renderScrolling()},_renderScrollable(){let i=this.$element().wrapInner(u("<div>").addClass("dx-tabs-scrollable")).children();this._scrollable=this._createComponent(i,Pi,{direction:this._getScrollableDirection(),showScrollbar:"never",useKeyboard:!1,useNative:!1,scrollByContent:this.option("scrollByContent"),onScroll:()=>{this._updateNavButtonsState()}}),this.$element().append(this._scrollable.$element())},_scrollToItem(i){if(!this._scrollable)return;let e=this._editStrategy.getItemElement(i);this._scrollable.scrollToElement(e)},_renderNavButtons(){let{showNavButtons:i,rtlEnabled:e}=this.option();if(this.$element().toggleClass("dx-tabs-nav-buttons",i),!i)return;this._leftButton=this._createNavButton(-30,e?"chevronnext":"chevronprev");let t=this._leftButton.$element();t.addClass("dx-tabs-nav-button-left"),this.$element().prepend(t),this._rightButton=this._createNavButton(30,e?"chevronprev":"chevronnext");let n=this._rightButton.$element();n.addClass("dx-tabs-nav-button-right"),this.$element().append(n)},_updateNavButtonsAriaDisabled(){[this._leftButton,this._rightButton].forEach(e=>{e?.$element().attr({"aria-disabled":null})})},_updateNavButtonsState(){let i=this._isVertical(),e=this.getScrollable();if(i){var t,n;(t=this._leftButton)===null||t===void 0||t.option("disabled",QV(e.scrollTop(),1)),(n=this._rightButton)===null||n===void 0||n.option("disabled",ZV(u(e.container()).get(0),e.scrollTop(),0,1))}else{var o,s;(o=this._leftButton)===null||o===void 0||o.option("disabled",YV(e.scrollLeft(),1)),(s=this._rightButton)===null||s===void 0||s.option("disabled",XV(u(e.container()).get(0),e.scrollLeft(),1))}this._updateNavButtonsAriaDisabled()},_updateScrollPosition(i,e){this._scrollable.update(),this._scrollable.scrollBy(i/e)},_createNavButton(i,e){let t=this._createAction(()=>{this._holdInterval=setInterval(()=>{this._updateScrollPosition(i,5)},5)}),n=D(an.name,"dxNavButton"),o=D(ne.up,"dxNavButton"),s=D(ne.out,"dxNavButton"),r=this._createComponent(u("<div>").addClass("dx-tabs-nav-button"),rt,{focusStateEnabled:!1,icon:e,integrationOptions:{},elementAttr:{role:null,"aria-label":null,"aria-disabled":null},onClick:()=>{this._updateScrollPosition(i,1)}}),a=r.$element();return _.on(a,n,{timeout:300},l=>{t({event:l})}),_.on(a,o,()=>{this._clearInterval()}),_.on(a,s,()=>{this._clearInterval()}),r},_clearInterval(){this._holdInterval&&clearInterval(this._holdInterval)},_updateSelection(i){this._scrollable&&this._scrollable.scrollToElement(this.itemElements().eq(i[0]))},_visibilityChanged(i){i&&this._dimensionChanged()},_dimensionChanged(){this._renderScrolling()},_itemSelectHandler(i){this.option("selectionMode")==="single"&&this.isItemSelected(i.currentTarget)||this.callBase(i)},_clean(){this._deferredTemplates=[],this._cleanScrolling(),this.callBase()},_toggleTabsVerticalClass(i){this.$element().toggleClass(eL.vertical,i)},_toggleTabsHorizontalClass(i){this.$element().toggleClass(eL.horizontal,i)},_getIndicatorPositionClass:i=>tL[i],_getIndicatorPosition(){let{_indicatorPosition:i,rtlEnabled:e}=this.option();if(i)return i;let t=this._isVertical();return e?t?Em.left:Em.bottom:t?Em.right:Em.bottom},_toggleIndicatorPositionClass(i){let e=this._getIndicatorPositionClass(i);this._toggleElementClasses(tL,e)},_toggleScrollingEnabledClass(i){this.$element().toggleClass("dx-tabs-scrolling-enabled",!!i)},_toggleOrientationClass(i){let e=i===CO.vertical;this._toggleTabsVerticalClass(e),this._toggleTabsHorizontalClass(!e)},_getTabsIconPositionClass(){switch(this.option("iconPosition")){case fd.top:return Au.top;case fd.end:return Au.end;case fd.bottom:return Au.bottom;default:return Au.start}},_toggleIconPositionClass(){let i=this._getTabsIconPositionClass();this._toggleElementClasses(Au,i)},_toggleStylingModeClass(i){let e=_O[i]??_O.primary;this._toggleElementClasses(_O,e)},_toggleElementClasses(i,e){for(let t in i)this.$element().removeClass(i[t]);this.$element().addClass(e)},_toggleFocusedDisabledNextClass(i,e){this._itemElements().eq(i).toggleClass("dx-focused-disabled-next-tab",e)},_toggleFocusedDisabledPrevClass(i,e){this._itemElements().eq(i).toggleClass("dx-focused-disabled-prev-tab",e)},_toggleFocusedDisabledClasses(i){let{selectedIndex:e}=this.option();this._itemElements().removeClass("dx-focused-disabled-next-tab").removeClass("dx-focused-disabled-prev-tab");let t=e-1,n=e+1,o=u(i).index(),s=this._itemElements().eq(n).hasClass("dx-state-disabled"),r=this._itemElements().eq(t).hasClass("dx-state-disabled"),a=s&&o===n,l=r&&o===t;this._toggleFocusedDisabledNextClass(e,a),this._toggleFocusedDisabledPrevClass(e,l)},_updateFocusedElement(){let{focusStateEnabled:i,selectedIndex:e}=this.option(),t=this._itemElements();if(i&&t.length){let n=t.get(e);this.option({focusedElement:n})}},_optionChanged(i){switch(i.name){case"useInkRipple":case"scrollingEnabled":this._toggleScrollingEnabledClass(i.value),this._invalidate();break;case"showNavButtons":case"badgeExpr":this._invalidate();break;case"scrollByContent":this._scrollable&&this._scrollable.option(i.name,i.value);break;case"width":case"height":this.callBase(i),this._dimensionChanged();break;case"selectionMode":this._renderMultiple(),this.callBase(i);break;case"focusedElement":this._toggleFocusedDisabledClasses(i.value),this.callBase(i),this._scrollToItem(i.value);break;case"rtlEnabled":{this.callBase(i);let e=this._getIndicatorPosition();this._toggleIndicatorPositionClass(e);break}case"orientation":{this._toggleOrientationClass(i.value);let e=this._getIndicatorPosition();this._toggleIndicatorPositionClass(e),W()&&this._updateScrollable();break}case"iconPosition":this._toggleIconPositionClass(),W()&&this._dimensionChanged();break;case"stylingMode":this._toggleStylingModeClass(i.value),W()&&this._dimensionChanged();break;case"_indicatorPosition":this._toggleIndicatorPositionClass(i.value);break;case"selectedIndex":case"selectedItem":case"selectedItems":this.callBase(i),this._updateFocusedElement();break;default:this.callBase(i)}},_afterItemElementInserted(){this.callBase(),this._deferRenderScrolling()},_afterItemElementDeleted(i,e){this.callBase(i,e),this._renderScrolling()},getScrollable(){return this._scrollable}});xO.ItemClass=JV;G("dxTabs",xO);var oL=xO;var sL=oL;var wm=class extends jn{_renderWatchers(){return this._startWatcher("badge",S),super._renderWatchers()}};var _d={top:"dx-tabpanel-tabs-position-top",right:"dx-tabpanel-tabs-position-right",bottom:"dx-tabpanel-tabs-position-bottom",left:"dx-tabpanel-tabs-position-left"},wa={top:"top",right:"right",bottom:"bottom",left:"left"},MQ={top:"bottom",right:"left",bottom:"top",left:"right"},rL={horizontal:"horizontal",vertical:"vertical"},aL={top:"top",end:"end",bottom:"bottom",start:"start"},lL={primary:"primary",secondary:"secondary"},vO=jV.inherit({_getDefaultOptions(){return m(this.callBase(),{itemTitleTemplate:"title",hoverStateEnabled:!0,showNavButtons:!1,scrollByContent:!0,scrollingEnabled:!0,tabsPosition:wa.top,iconPosition:aL.start,stylingMode:lL.primary,onTitleClick:null,onTitleHold:null,onTitleRendered:null,badgeExpr:i=>i?i.badge:void 0,_tabsIndicatorPosition:null})},_defaultOptionsRules(){let i=ct();return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}},{device:()=>!Nn,options:{swipeEnabled:!1}},{device:{platform:"generic"},options:{animationEnabled:!1}},{device:()=>ut(i),options:{stylingMode:lL.secondary}},{device:()=>pt(i),options:{iconPosition:aL.top}}])},_init(){this.callBase(),this.$element().addClass("dx-tabpanel"),this._toggleTabPanelTabsPositionClass()},_getElementAria:()=>({role:"tabpanel"}),_getItemAria:()=>({role:"tabpanel"}),_initMarkup(){this.callBase(),this._createTitleActions(),this._renderLayout()},_prepareTabsItemTemplate(i,e){let t=ci(i?.icon);t&&e.append(t);let n=q(i)?i?.title:i;if(f(n)&&!q(n)){let o=u("<span>").addClass("dx-tab-text-span");o.append(w.createTextNode(n));let s=u("<span>").addClass("dx-tab-text-span-pseudo");s.append(w.createTextNode(n)),s.appendTo(o),o.appendTo(e)}},_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({title:new di((i,e)=>{this._prepareTabsItemTemplate(e,i);let t=u("<div>").addClass("dx-tab-text");i.wrapInner(t)},["title","icon"],this.option("integrationOptions.watchMethod"))})},_createTitleActions(){this._createTitleClickAction(),this._createTitleHoldAction(),this._createTitleRenderedAction()},_createTitleClickAction(){this._titleClickAction=this._createActionByOption("onTitleClick")},_createTitleHoldAction(){this._titleHoldAction=this._createActionByOption("onTitleHold")},_createTitleRenderedAction(){this._titleRenderedAction=this._createActionByOption("onTitleRendered")},_renderLayout(){if(this._tabs)return;let i=this.$element();this._$tabContainer=u("<div>").addClass("dx-tabpanel-tabs").appendTo(i);let e=u("<div>").appendTo(this._$tabContainer);this._tabs=this._createComponent(e,sL,this._tabConfig()),this._$container=u("<div>").addClass("dx-tabpanel-container").appendTo(i),this._$container.append(this._$wrapper)},_refreshActiveDescendant(){if(!this._tabs)return;let i=this._tabs,e=i.itemElements(),t=u(e[i.option("selectedIndex")]),n=this.getFocusedItemId();this.setAria("controls",void 0,u(e)),this.setAria("controls",n,t)},_getTabsIndicatorPosition(){let{_tabsIndicatorPosition:i,tabsPosition:e}=this.option();return i??MQ[e]},_tabConfig(){let i=this._getTabsIndicatorPosition();return{selectOnFocus:!0,focusStateEnabled:this.option("focusStateEnabled"),hoverStateEnabled:this.option("hoverStateEnabled"),repaintChangesOnly:this.option("repaintChangesOnly"),tabIndex:this.option("tabIndex"),selectedIndex:this.option("selectedIndex"),badgeExpr:this.option("badgeExpr"),onItemClick:this._titleClickAction.bind(this),onItemHold:this._titleHoldAction.bind(this),itemHoldTimeout:this.option("itemHoldTimeout"),onSelectionChanged:function(e){this.option("selectedIndex",e.component.option("selectedIndex")),this._refreshActiveDescendant()}.bind(this),onItemRendered:this._titleRenderedAction.bind(this),itemTemplate:this._getTemplateByOption("itemTitleTemplate"),items:this.option("items"),noDataText:null,scrollingEnabled:this.option("scrollingEnabled"),scrollByContent:this.option("scrollByContent"),showNavButtons:this.option("showNavButtons"),itemTemplateProperty:"tabTemplate",loopItemFocus:this.option("loop"),selectionRequired:!0,onOptionChanged:function(e){if(e.name==="focusedElement")if(e.value){let t=u(e.value),n=this._itemElements().eq(t.index());this.option("focusedElement",N(n))}else this.option("focusedElement",e.value)}.bind(this),onFocusIn:function(e){this._focusInHandler(e.event)}.bind(this),onFocusOut:function(e){this._isFocusOutHandlerExecuting||this._focusOutHandler(e.event)}.bind(this),orientation:this._getTabsOrientation(),iconPosition:this.option("iconPosition"),stylingMode:this.option("stylingMode"),_itemAttributes:{class:"dx-tabpanel-tab"},_indicatorPosition:i}},_renderFocusTarget(){this._focusTarget().attr("tabIndex",-1)},_getTabsOrientation(){let{tabsPosition:i}=this.option();return[wa.right,wa.left].includes(i)?rL.vertical:rL.horizontal},_getTabPanelTabsPositionClass(){switch(this.option("tabsPosition")){case wa.right:return _d.right;case wa.bottom:return _d.bottom;case wa.left:return _d.left;case wa.top:default:return _d.top}},_toggleTabPanelTabsPositionClass(){for(let e in _d)this.$element().removeClass(_d[e]);let i=this._getTabPanelTabsPositionClass();this.$element().addClass(i)},_updateTabsOrientation(){let i=this._getTabsOrientation();this._setTabsOption("orientation",i)},_toggleWrapperFocusedClass(i){this._toggleFocusClass(i,this._$wrapper)},_toggleDisabledFocusedClass(i){this._focusTarget().toggleClass("dx-disabled-focused-tab",i)},_updateFocusState(i,e){this.callBase(i,e);let t=i.target===this._tabs._focusTarget().get(0),n=i.target===this._focusTarget().get(0);if(t&&this._toggleFocusClass(e,this._focusTarget()),t||n){let o=this._isDisabled(this.option("focusedElement"));this._toggleWrapperFocusedClass(e&&!o),this._toggleDisabledFocusedClass(e&&o)}n&&this._toggleFocusClass(e,this._tabs.option("focusedElement"))},_focusOutHandler(i){this._isFocusOutHandlerExecuting=!0,this.callBase.apply(this,arguments),this._tabs._focusOutHandler(i),this._isFocusOutHandlerExecuting=!1},_setTabsOption(i,e){this._tabs&&this._tabs.option(i,e)},_visibilityChanged(i){i&&this._tabs._dimensionChanged()},registerKeyHandler(i,e){this.callBase(i,e),this._tabs&&this._tabs.registerKeyHandler(i,e)},repaint(){this.callBase(),this._tabs.repaint()},_updateTabsIndicatorPosition(){let i=this._getTabsIndicatorPosition();this._setTabsOption("_indicatorPosition",i)},_optionChanged(i){let{name:e,value:t,fullName:n}=i;switch(e){case"dataSource":default:this.callBase(i);break;case"items":this._setTabsOption(e,this.option(e)),this.option("repaintChangesOnly")||this._tabs.repaint(),this.callBase(i);break;case"width":this.callBase(i),this._tabs.repaint();break;case"selectedIndex":case"selectedItem":if(this._setTabsOption(n,t),this.callBase(i),this.option("focusStateEnabled")===!0){let o=this.option("selectedIndex"),s=this._itemElements().eq(o);this.option("focusedElement",N(s))}break;case"itemHoldTimeout":case"focusStateEnabled":case"hoverStateEnabled":this._setTabsOption(n,t),this.callBase(i);break;case"scrollingEnabled":case"scrollByContent":case"showNavButtons":this._setTabsOption(n,t);break;case"focusedElement":{let o=t&&u(t).index(),s=t&&this._tabs._itemElements().eq(o);if(this._setTabsOption("focusedElement",N(s)),t){let r=this._isDisabled(t);this._toggleWrapperFocusedClass(!r),this._toggleDisabledFocusedClass(r)}this.callBase(i);break}case"itemTitleTemplate":this._setTabsOption("itemTemplate",this._getTemplateByOption("itemTitleTemplate"));break;case"onTitleClick":this._createTitleClickAction(),this._setTabsOption("onItemClick",this._titleClickAction.bind(this));break;case"onTitleHold":this._createTitleHoldAction(),this._setTabsOption("onItemHold",this._titleHoldAction.bind(this));break;case"onTitleRendered":this._createTitleRenderedAction(),this._setTabsOption("onItemRendered",this._titleRenderedAction.bind(this));break;case"loop":this._setTabsOption("loopItemFocus",t);break;case"badgeExpr":this._invalidate();break;case"tabsPosition":this._toggleTabPanelTabsPositionClass(),this._updateTabsIndicatorPosition(),this._updateTabsOrientation();break;case"iconPosition":this._setTabsOption("iconPosition",t);break;case"stylingMode":this._setTabsOption("stylingMode",t);break;case"_tabsIndicatorPosition":this._setTabsOption("_indicatorPosition",t)}}});vO.ItemClass=wm;G("dxTabPanel",vO);var dL=vO;var cL=dL;var os=class{constructor(e){this._options=e,this._itemsRunTimeInfo=this._options.itemsRunTimeInfo}findInstance(){return this._itemsRunTimeInfo.findWidgetInstanceByItem(this._options.item)}findItemContainer(){return this._itemsRunTimeInfo.findItemContainerByItem(this._options.item)}findPreparedItem(){return this._itemsRunTimeInfo.findPreparedItemByItem(this._options.item)}tryExecute(){ce.abstract()}};var Im=(i,e)=>`${e?"tabs":"items"}[${i}]`,bO=(i,e)=>f(i)&&f(e)?`${i}.${e}`:i||e,Dm=i=>i?i.replace(/\s/g,""):void 0,uL=(i,e)=>i?i.dataField===e||i.name===e||Dm(i.title)===e||i.itemType==="group"&&Dm(i.caption)===e:!1,Ia=(i,e)=>`${i}.${e}`,yO=i=>{let e=i.split(".");return e[e.length-1].replace(/\[\d+]/,"")},hL=i=>{let e=i.split("."),t=[...e];for(let n=e.length-1;n>=0;n--){if(OO(e[n]))return t.join(".");t.splice(n,1)}return""},OO=i=>i.indexOf("tabs")>-1,SO=(i,e,t)=>{let n=i.indexOf(e);if(n>-1)return Im(n,t);for(let o=0;o<i.length;o++){let s=i[o],r=s.tabs||s.items;if(r){let a=SO(r,e,s.tabs);if(a)return bO(Im(o,t),a)}}};function pL(i){let{form:e,$formElement:t,formOptions:n,items:o,validationGroup:s,extendedLayoutManagerOptions:r,onFieldDataChanged:a,onContentReady:l,onDisposing:d,onFieldItemRendered:c}=i,h={form:e,items:o,$formElement:t,validationGroup:s,onFieldDataChanged:a,onContentReady:l,onDisposing:d,onFieldItemRendered:c,validationBoundary:n.scrollingEnabled?t:void 0,scrollingEnabled:n.scrollingEnabled,showRequiredMark:n.showRequiredMark,showOptionalMark:n.showOptionalMark,requiredMark:n.requiredMark,optionalMark:n.optionalMark,requiredMessage:n.requiredMessage,screenByWidth:n.screenByWidth,layoutData:n.formData,labelLocation:n.labelLocation,customizeItem:n.customizeItem,minColWidth:n.minColWidth,showColonAfterLabel:n.showColonAfterLabel,onEditorEnterKey:n.onEditorEnterKey,labelMode:n.labelMode};return m(h,{isRoot:r.isRoot,colCount:r.colCount,alignItemLabels:r.alignItemLabels,cssItemClass:r.cssItemClass,colCountByScreen:r.colCountByScreen,onLayoutChanged:r.onLayoutChanged,width:r.width})}var EO=class extends os{tryExecute(){let{value:e}=this._options,t=this.findInstance();return t?(t.option(e),!0):!1}},Tm=class extends os{tryExecute(){let e=this.findInstance();if(e){let{optionName:t,item:n,value:o}=this._options,s=this._itemsRunTimeInfo.findItemIndexByItem(n);if(s>=0)return e.option(Ia(`items[${s}]`,t),o),!0}return!1}},wO=class extends os{tryExecute(){return!1}},IO=class extends os{tryExecute(){let e=this.findPreparedItem();return e!=null&&e._prepareGroupItemTemplate&&e._renderGroupContentTemplate?(e._prepareGroupItemTemplate(this._options.item.template),e._renderGroupContentTemplate(),!0):!1}},DO=class extends os{tryExecute(){let e=this.findInstance();if(e){let{value:t}=this._options;return e.option("dataSource",t),!0}return!1}},TO=class extends os{tryExecute(){let{item:e}=this._options,t=this.findInstance(),n=t&&$e(t.$element()[0],"dxValidator");if(n&&e){let o=a=>a.type==="required",s=(n.option("validationRules")||[]).some(o),r=(e.validationRules||[]).some(o);if(!s&&!r||s&&r)return n.option("validationRules",e.validationRules),!0}return!1}},AO=class extends os{tryExecute(){let e=this.findItemContainer(),{previousValue:t,value:n}=this._options;return e?(e.removeClass(t).addClass(n),!0):!1}},RQ=(i,e)=>{switch(i){case"editorOptions":case"buttonOptions":return new EO(e);case"validationRules":return new TO(e);case"cssClass":return new AO(e);case"badge":case"disabled":case"icon":case"tabTemplate":case"title":return new Tm(m(e,{optionName:i}));case"tabs":return new DO(e);case"template":{var t,n;let o=(e==null||(t=e.item)===null||t===void 0?void 0:t.itemType)??((n=e.itemsRunTimeInfo.findPreparedItemByItem(e?.item))===null||n===void 0?void 0:n.itemType);return o==="simple"?new wO(e):o==="group"?new IO(e):new Tm(m(e,{optionName:i}))}default:return null}},gL=RQ;var FQ=["items","isRequired","validationRules","visible"],mL=Xe.inherit({_init(){this.callBase(),this._dirtyFields=new Set,this._cachedColCountOptions=[],this._itemsRunTimeInfo=new md,this._groupsColCount=[],this._attachSyncSubscriptions()},_getDefaultOptions(){return m(this.callBase(),{formID:`dx-${new Oe}`,formData:{},colCount:1,screenByWidth:Vd,colCountByScreen:void 0,labelLocation:"left",readOnly:!1,onFieldDataChanged:null,customizeItem:null,onEditorEnterKey:null,minColWidth:200,alignItemLabels:!0,alignItemLabelsInAllGroups:!0,alignRootItemLabels:!0,showColonAfterLabel:!0,showRequiredMark:!0,showOptionalMark:!1,requiredMark:"*",optionalMark:O.format("dxForm-optionalMark"),requiredMessage:O.getFormatter("dxForm-requiredMessage"),showValidationSummary:!1,items:void 0,scrollingEnabled:!1,validationGroup:void 0,stylingMode:fe().editorStylingMode,labelMode:"outside",isDirty:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>pt(),options:{labelLocation:"top"}},{device:()=>it(),options:{showColonAfterLabel:!1}}])},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{formData:!0,validationGroup:!0})},_getGroupColCount:i=>parseInt(i.attr(uO)),_applyLabelsWidthByCol(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=arguments.length>3?arguments[3]:void 0,o=t.inOneColumn?bm:sO+e,s=t.excludeTabbed?`:not(.${dO})`:"";VV(i,`.${o}${s}`,n)},_applyLabelsWidth(i,e,t,n,o){n=t?1:n||this._getGroupColCount(i);let s={excludeTabbed:e,inOneColumn:t},r;for(r=0;r<n;r++)this._applyLabelsWidthByCol(i,r,s,o)},_getGroupElementsInColumn(i,e,t){let n=f(t)?`.${cO}${t}`:"",o=`.${sO}${e} > .${Iu} > .${vm}${n}`;return i.find(o)},_applyLabelsWidthWithGroups(i,e,t,n){if(this.option("alignRootItemLabels")===!0){let s=i.find(`.${ym}`);for(let r=0;r<e;r++)this._applyLabelsWidthByCol(s,r,t,n)}if(this.option("alignItemLabelsInAllGroups"))this._applyLabelsWidthWithNestedGroups(i,e,t,n);else{let s=this.$element().find(`.${vm}`),r;for(r=0;r<s.length;r++)this._applyLabelsWidth(s.eq(r),t,void 0,void 0,n)}},_applyLabelsWidthWithNestedGroups(i,e,t,n){let o={excludeTabbed:t},s,r,a,l;for(s=0;s<e;s++)for(l=this._getGroupElementsInColumn(i,s),this._applyLabelsWidthByCol(l,0,o,n),r=0;r<this._groupsColCount.length;r++){l=this._getGroupElementsInColumn(i,s,this._groupsColCount[r]);let d=this._getGroupColCount(l);for(a=1;a<d;a++)this._applyLabelsWidthByCol(l,a,o,n)}},_labelLocation(){return this.option("labelLocation")},_alignLabelsInColumn(i){let{layoutManager:e,inOneColumn:t,$container:n,excludeTabbed:o,items:s}=i;if(!W()||this._labelLocation()==="top")return;let r=hO(e._getMarkOptions());t?this._applyLabelsWidth(n,o,!0,void 0,r):this._checkGrouping(s)?this._applyLabelsWidthWithGroups(n,e._getColCount(),o,r):this._applyLabelsWidth(n,o,!1,e._getColCount(),r)},_prepareFormData(){f(this.option("formData"))||this.option("formData",{})},_setStylingModeClass(){this.option("stylingMode")==="underlined"&&this.$element().addClass(FV)},_initMarkup(){Xt.addGroup(this._getValidationGroup(),!1),this._clearCachedInstances(),this._prepareFormData(),this.$element().addClass(OV),this._setStylingModeClass(),this.callBase(),this.setAria("role","form",this.$element()),this.option("scrollingEnabled")&&this._renderScrollable(),this._renderLayout(),this._renderValidationSummary(),this._lastMarkupScreenFactor=this._targetScreenFactor||this._getCurrentScreenFactor(),this._attachResizeObserverSubscription()},_attachResizeObserverSubscription(){if(W()){let i=this.$element().get(0);Wo.unobserve(i),Wo.observe(i,()=>{this._resizeHandler()})}},_resizeHandler(){this._cachedLayoutManagers.length&&x(this._cachedLayoutManagers,(i,e)=>{var t;(t=e.option("onLayoutChanged"))===null||t===void 0||t(e.isSingleColumnMode())})},_getCurrentScreenFactor(){return W()?nh(this.option("screenByWidth")):"lg"},_clearCachedInstances(){this._itemsRunTimeInfo.clear(),this._cachedLayoutManagers=[]},_alignLabels(i,e){this._alignLabelsInColumn({$container:this.$element(),layoutManager:i,excludeTabbed:!0,items:this.option("items"),inOneColumn:e}),bi(this.$element().find(`.${Sp}`))},_clean(){this._clearValidationSummary(),this.callBase(),this._groupsColCount=[],this._cachedColCountOptions=[],this._lastMarkupScreenFactor=void 0,Wo.unobserve(this.$element().get(0))},_renderScrollable(){let i=this.option("useNativeScrolling");this._scrollable=new Pi(this.$element(),{useNative:!!i,useSimulatedScrollbar:!i,useKeyboard:!1,direction:"both",bounceEnabled:!1})},_getContent(){return this.option("scrollingEnabled")?u(this._scrollable.content()):this.$element()},_clearValidationSummary(){var i;(i=this._$validationSummary)===null||i===void 0||i.remove(),this._$validationSummary=void 0,this._validationSummary=void 0},_renderValidationSummary(){this._clearValidationSummary(),this.option("showValidationSummary")&&(this._$validationSummary=u("<div>").addClass(RV).appendTo(this._getContent()),this._validationSummary=this._$validationSummary.dxValidationSummary({validationGroup:this._getValidationGroup()}).dxValidationSummary("instance"))},_prepareItems(i,e,t,n){if(i){let o=[];for(let s=0;s<i.length;s++){let r=i[s],a=bO(t,Im(s,n)),l={item:r,itemIndex:s,path:a},d=this._itemsRunTimeInfo.add(l);if(B(r)&&(r={dataField:r}),$(r)){let c=I({},r);l.preparedItem=c,c.guid=d,this._tryPrepareGroupItemCaption(c),this._tryPrepareGroupItem(c),this._tryPrepareTabbedItem(c,a),this._tryPrepareItemTemplate(c),e&&(c.cssItemClass=dO),c.items&&(c.items=this._prepareItems(c.items,e,a)),o.push(c)}else o.push(r)}return o}},_tryPrepareGroupItemCaption(i){i.itemType==="group"&&(i._prepareGroupCaptionTemplate=e=>{i.captionTemplate&&(i.groupCaptionTemplate=this._getTemplate(e)),i.captionTemplate=this._itemGroupTemplate.bind(this,i)},i._prepareGroupCaptionTemplate(i.captionTemplate))},_tryPrepareGroupItem(i){i.itemType==="group"&&(i.alignItemLabels=Te(i.alignItemLabels,!0),i._prepareGroupItemTemplate=e=>{i.template&&(i.groupContentTemplate=this._getTemplate(e)),i.template=this._itemGroupTemplate.bind(this,i)},i._prepareGroupItemTemplate(i.template))},_tryPrepareTabbedItem(i,e){i.itemType==="tabbed"&&(i.template=this._itemTabbedTemplate.bind(this,i),i.tabs=this._prepareItems(i.tabs,!0,e,!0))},_tryPrepareItemTemplate(i){i.template&&(i.template=this._getTemplate(i.template))},_checkGrouping(i){if(i){for(let e=0;e<i.length;e++)if(i[e].itemType==="group")return!0}},_renderLayout(){let i=this,e=i.option("items"),t=i._getContent();e=i._prepareItems(e),i._rootLayoutManager=i._renderLayoutManager(t,this._createLayoutManagerOptions(e,{isRoot:!0,colCount:i.option("colCount"),alignItemLabels:i.option("alignItemLabels"),screenByWidth:this.option("screenByWidth"),colCountByScreen:this.option("colCountByScreen"),onLayoutChanged(n){i._alignLabels.bind(i)(i._rootLayoutManager,n)},onContentReady(n){i._alignLabels(n.component,n.component.isSingleColumnMode())}}))},_tryGetItemsForTemplate:i=>i.items||[],_itemTabbedTemplate(i,e,t){let n=u("<div>").appendTo(t),o=m({},i.tabPanelOptions,{dataSource:i.tabs,onItemRendered:a=>{var l,d;(l=i.tabPanelOptions)===null||l===void 0||(d=l.onItemRendered)===null||d===void 0||d.call(l,a),nl(a.itemElement)},itemTemplate:(a,l,d)=>{let c=u(d),h=Te(a.alignItemLabels,!0),p=this._renderLayoutManager(c,this._createLayoutManagerOptions(this._tryGetItemsForTemplate(a),{colCount:a.colCount,alignItemLabels:h,screenByWidth:this.option("screenByWidth"),colCountByScreen:a.colCountByScreen,cssItemClass:a.cssItemClass,onLayoutChanged:g=>{this._alignLabelsInColumn({$container:c,layoutManager:p,items:a.items,inOneColumn:g})}}));this._itemsRunTimeInfo&&this._itemsRunTimeInfo.extendRunTimeItemInfoByKey(a.guid,{layoutManager:p}),h&&this._alignLabelsInColumn({$container:c,layoutManager:p,items:a.items,inOneColumn:p.isSingleColumnMode()})}}),s=(a,l)=>{Array.isArray(a)&&a.forEach(d=>this._itemsRunTimeInfo.extendRunTimeItemInfoByKey(d.guid,{widgetInstance:l}))},r=this._createComponent(n,cL,o);u(t).parent().addClass(AV),r.on("optionChanged",a=>{a.fullName==="dataSource"&&s(a.value,a.component)}),s([{guid:i.guid},...i.tabs??[]],r)},_itemGroupCaptionTemplate(i,e,t){if(i.groupCaptionTemplate){let n=u("<div>").addClass(EV).attr("id",t).appendTo(e);i._renderGroupCaptionTemplate=()=>{let o={component:this,caption:i.caption,name:i.name};i.groupCaptionTemplate.render({model:o,container:N(n)})},i._renderGroupCaptionTemplate();return}i.caption&&u("<span>").addClass(SV).text(i.caption).attr("id",t).appendTo(e)},_itemGroupContentTemplate(i,e){let t=u("<div>").addClass(DV).appendTo(e);if(i.groupContentTemplate)i._renderGroupContentTemplate=()=>{t.empty();let n={formData:this.option("formData"),component:this};i.groupContentTemplate.render({model:n,container:N(t)})},i._renderGroupContentTemplate();else{let n=this._renderLayoutManager(t,this._createLayoutManagerOptions(this._tryGetItemsForTemplate(i),{colCount:i.colCount,colCountByScreen:i.colCountByScreen,alignItemLabels:i.alignItemLabels,cssItemClass:i.cssItemClass}));this._itemsRunTimeInfo&&this._itemsRunTimeInfo.extendRunTimeItemInfoByKey(i.guid,{layoutManager:n});let o=n._getColCount();this._groupsColCount.includes(o)||this._groupsColCount.push(o),e.addClass(cO+o),e.attr(uO,o)}},_itemGroupTemplate(i,e,t){let{id:n}=e.editorOptions.inputAttr,o=u("<div>").toggleClass(MV,f(i.caption)&&i.caption.length).addClass(vm).appendTo(t),s={role:"group",labelledby:n};this.setAria(s,o),u(t).parent().addClass(TV),this._itemGroupCaptionTemplate(i,o,n),this._itemGroupContentTemplate(i,o)},_createLayoutManagerOptions(i,e){return pL({form:this,formOptions:this.option(),$formElement:this.$element(),items:i,validationGroup:this._getValidationGroup(),extendedLayoutManagerOptions:e,onFieldDataChanged:t=>{this._isDataUpdating||this._triggerOnFieldDataChanged(t)},onContentReady:t=>{this._itemsRunTimeInfo.addItemsOrExtendFrom(t.component._itemsRunTimeInfo),e.onContentReady&&e.onContentReady(t)},onDisposing:t=>{let{component:n}=t,o=n.getItemsRunTimeInfo();this._itemsRunTimeInfo.removeItemsByItems(o)},onFieldItemRendered:()=>{var t;(t=this._validationSummary)===null||t===void 0||t.refreshValidationGroup()}})},_renderLayoutManager(i,e){let t={lg:e.colCount,md:e.colCount,sm:e.colCount,xs:1};this._cachedColCountOptions.push({colCountByScreen:m(t,e.colCountByScreen)});let n=u("<div>");n.appendTo(i);let o=this._createComponent(n,"dxLayoutManager",e);return o.on("autoColCountChanged",()=>{this._clearAutoColCountChangedTimeout(),this.autoColCountChangedTimeoutId=setTimeout(()=>!this._disposed&&this._refresh(),0)}),this._cachedLayoutManagers.push(o),o},_getValidationGroup(){return this.option("validationGroup")||this},_createComponent(i,e,t){return t=t||{},this._extendConfig(t,{readOnly:this.option("readOnly")}),this.callBase(i,e,t)},_attachSyncSubscriptions(){let i=this;i.on("optionChanged",e=>{let t=e.fullName;t==="formData"&&(f(e.value)||i._options.silent("formData",e.value={}),i._triggerOnFieldDataChangedByDataSet(e.value)),i._cachedLayoutManagers.length&&x(i._cachedLayoutManagers,(n,o)=>{t==="formData"&&(i._isDataUpdating=!0,o.option("layoutData",e.value),i._isDataUpdating=!1),(e.name==="readOnly"||e.name==="disabled")&&o.option(t,e.value)})})},_optionChanged(i){let e=i.fullName.split(".");e.length>1&&e[0].search("items")!==-1&&this._itemsOptionChangedHandler(i)||e.length>1&&e[0].search("formData")!==-1&&this._formDataOptionChangedHandler(i)||this._defaultOptionChangedHandler(i)},_defaultOptionChangedHandler(i){switch(i.name){case"formData":this.option("items")?dt(i.value)&&this._clear():this._invalidate();break;case"onFieldDataChanged":case"alignRootItemLabels":case"readOnly":case"isDirty":break;case"items":case"colCount":case"onEditorEnterKey":case"labelLocation":case"labelMode":case"alignItemLabels":case"showColonAfterLabel":case"customizeItem":case"alignItemLabelsInAllGroups":case"showRequiredMark":case"showOptionalMark":case"requiredMark":case"optionalMark":case"requiredMessage":case"scrollingEnabled":case"formID":case"colCountByScreen":case"screenByWidth":case"stylingMode":this._invalidate();break;case"showValidationSummary":this._renderValidationSummary();break;case"minColWidth":this.option("colCount")==="auto"&&this._invalidate();break;case"width":this.callBase(i),this._rootLayoutManager.option(i.name,i.value),this._alignLabels(this._rootLayoutManager,this._rootLayoutManager.isSingleColumnMode());break;case"validationGroup":Xt.removeGroup(i.previousValue||this),this._invalidate();break;default:this.callBase(i)}},_itemsOptionChangedHandler(i){let e=i.fullName.split("."),{value:t}=i,n=this._getItemPath(e),o=this.option(n),s=i.fullName.replace(`${n}.`,""),r=s.split(".")[0].replace(/\[\d+]/,""),a=this._tryCreateItemOptionAction(r,o,o[r],i.previousValue,n),l=this._tryExecuteItemOptionAction(a)||this._tryChangeLayoutManagerItemOption(i.fullName,t);if(!l&&o){this._changeItemOption(o,s,t);let d=this._generateItemsFromData(this.option("items"));this.option("items",d),l=!0}return l},_formDataOptionChangedHandler(i){let e=i.fullName.split("."),{value:t}=i,n=e.slice(1).join("."),o=this.getEditor(n);return o?o.option("value",t):this._triggerOnFieldDataChanged({dataField:n,value:t}),!0},_tryCreateItemOptionAction(i,e,t,n,o){return i==="tabs"&&(this._itemsRunTimeInfo.removeItemsByPathStartWith(`${o}.tabs`),t=this._prepareItems(t,!0,o,!0)),gL(i,{item:e,value:t,previousValue:n,itemsRunTimeInfo:this._itemsRunTimeInfo})},_tryExecuteItemOptionAction:i=>i&&i.tryExecute(),_updateValidationGroupAndSummaryIfNeeded(i){let e=yO(i);if(FQ.includes(e)&&(Xt.addGroup(this._getValidationGroup(),!1),this.option("showValidationSummary"))){var t;(t=this._validationSummary)===null||t===void 0||t.refreshValidationGroup()}},_setLayoutManagerItemOption(i,e,t,n){if(this._updateLockCount>0){!i._updateLockCount&&i.beginUpdate();let s=this._itemsRunTimeInfo.findKeyByPath(n);this.postponedOperations.add(s,()=>(!i._disposed&&i.endUpdate(),y().resolve()))}let o=s=>{if(s.component.off("contentReady",o),OO(n)){let r=hL(n),a=this._itemsRunTimeInfo.findGroupOrTabLayoutManagerByPath(r);a&&this._alignLabelsInColumn({items:a.option("items"),layoutManager:a,$container:a.$element(),inOneColumn:a.isSingleColumnMode()})}else this._alignLabels(this._rootLayoutManager,this._rootLayoutManager.isSingleColumnMode())};i.on("contentReady",o),i.option(e,t),this._updateValidationGroupAndSummaryIfNeeded(e)},_tryChangeLayoutManagerItemOption(i,e){let t=i.split("."),n=yO(i);if(n==="items"&&t.length>1){let o=this._getItemPath(t),s=this._itemsRunTimeInfo.findGroupOrTabLayoutManagerByPath(o);if(s){this._itemsRunTimeInfo.removeItemsByItems(s.getItemsRunTimeInfo());let r=this._prepareItems(e,!1,o);return this._setLayoutManagerItemOption(s,n,r,o),!0}}else if(t.length>2){let o=t.length-2,s=this._getItemPath(t.slice(0,o)),r=this._itemsRunTimeInfo.findGroupOrTabLayoutManagerByPath(s);if(r){let a=Ia(t[o],n);if(n==="editorType"&&r.option(a)!==e)return!1;if(n==="visible"){let l=this.option(Ia(s,"items"));if(l&&l.length){let d=r.option("items");l.forEach((c,h)=>{let p=d[h];p.visibleIndex=c.visibleIndex})}}return this._setLayoutManagerItemOption(r,a,e,s),!0}}return!1},_tryChangeLayoutManagerItemOptions(i,e){let t;return this.beginUpdate(),x(e,(n,o)=>{if(t=this._tryChangeLayoutManagerItemOption(Ia(i,n),o),!t)return!1}),this.endUpdate(),t},_getItemPath(i){let e=i[0],t;for(t=1;t<i.length&&i[t].search(/items\[\d+]|tabs\[\d+]/)!==-1;t++)e+=`.${i[t]}`;return e},_triggerOnFieldDataChanged(i){this._updateIsDirty(i.dataField),this._createActionByOption("onFieldDataChanged")(i)},_triggerOnFieldDataChangedByDataSet(i){i&&$(i)&&Object.keys(i).forEach(e=>{this._triggerOnFieldDataChanged({dataField:e,value:i[e]})})},_updateFieldValue(i,e){if(f(this.option("formData"))){let t=this.getEditor(i);this.option(`formData.${i}`,e),t&&t.option("value")!==e&&t.option("value",e)}},_generateItemsFromData(i){let e=this.option("formData"),t=[];return!i&&f(e)&&x(e,n=>{t.push({dataField:n})}),i&&x(i,(n,o)=>{$(o)?t.push(o):t.push({dataField:o})}),t},_getItemByField(i,e){let t=this,n=$(i)?i:t._getFieldParts(i),{fieldName:o}=n,{fieldPath:s}=n,r;return e.length&&x(e,(a,l)=>{let{itemType:d}=l;if(s.length){let c=s.slice();l=t._getItemByFieldPath(c,o,l)}else if(d==="group"&&!(l.caption||l.name)||d==="tabbed"&&!l.name){let c=t._getSubItemField(d);l.items=t._generateItemsFromData(l.items),l=t._getItemByField({fieldName:o,fieldPath:s},l[c])}if(uL(l,o))return r=l,!1}),r},_getFieldParts(i){let e=i,t=e.indexOf("."),n=[];for(;t!==-1;)n.push(e.substr(0,t)),e=e.substr(t+1),t=e.indexOf(".");return{fieldName:e,fieldPath:n.reverse()}},_getItemByFieldPath(i,e,t){let n=this,{itemType:o}=t,s=n._getSubItemField(o),r=o==="group"||o==="tabbed"||t.title,a;do if(r){let l=t.name||t.caption||t.title,d=f(l),c=Dm(l),h;if(t[s]=n._generateItemsFromData(t[s]),d&&(h=i.pop()),!i.length&&(a=n._getItemByField(e,t[s]),a))break;(!d||d&&c===h)&&i.length&&(a=n._searchItemInEverySubItem(i,e,t[s]))}else break;while(i.length&&!f(a));return a},_getSubItemField:i=>i==="tabbed"?"tabs":"items",_searchItemInEverySubItem(i,e,t){let n=this,o;return x(t,(s,r)=>{if(o=n._getItemByFieldPath(i.slice(),e,r),o)return!1}),o||(o=!1),o},_changeItemOption(i,e,t){$(i)&&(i[e]=t)},_dimensionChanged(){let i=this._getCurrentScreenFactor();this._lastMarkupScreenFactor!==i&&(this._isColCountChanged(this._lastMarkupScreenFactor,i)&&(this._targetScreenFactor=i,this._refresh(),this._targetScreenFactor=void 0),this._lastMarkupScreenFactor=i)},_isColCountChanged(i,e){let t=!1;return x(this._cachedColCountOptions,(n,o)=>{if(o.colCountByScreen[i]!==o.colCountByScreen[e])return t=!0,!1}),t},_refresh(){let i=`.${bM}.dx-state-focused:not(.${FM}) .${yM}`;_.trigger(this.$element().find(i),"change"),this.callBase()},_updateIsDirty(i){let e=this.getEditor(i);e&&(e.option("isDirty")?this._dirtyFields.add(i):this._dirtyFields.delete(i),this.option("isDirty",!!this._dirtyFields.size))},updateRunTimeInfoForEachEditor(i){this._itemsRunTimeInfo.each((e,t)=>{let{widgetInstance:n}=t;f(n)&&oi.isEditor(n)&&i(n)})},_clear(){this.updateRunTimeInfoForEachEditor(i=>{i.clear(),i.option("isValid",!0)}),Xt.resetGroup(this._getValidationGroup())},_updateData(i,e,t){let n=this,o=t?e:i;$(o)?x(o,(s,r)=>{n._updateData(t?`${i}.${s}`:s,r,$(r))}):B(i)&&n._updateFieldValue(i,e)},registerKeyHandler(i,e){this.callBase(i,e),this._itemsRunTimeInfo.each((t,n)=>{f(n.widgetInstance)&&n.widgetInstance.registerKeyHandler(i,e)})},_focusTarget(){return this.$element().find(`.${Iu} [tabindex]`).first()},_visibilityChanged(){this._alignLabels(this._rootLayoutManager,this._rootLayoutManager.isSingleColumnMode())},_clearAutoColCountChangedTimeout(){this.autoColCountChangedTimeoutId&&(clearTimeout(this.autoColCountChangedTimeoutId),this.autoColCountChangedTimeoutId=void 0)},_dispose(){this._clearAutoColCountChangedTimeout(),Xt.removeGroup(this._getValidationGroup()),this.callBase()},clear(){this._clear()},resetValues(){this._clear()},reset(i){this.updateRunTimeInfoForEachEditor(e=>{let t=e.option("name");i&&t in i?e.reset(i[t]):e.reset()}),this._renderValidationSummary()},updateData(i,e){this._updateData(i,e)},getEditor(i){return this._itemsRunTimeInfo.findWidgetInstanceByDataField(i)||this._itemsRunTimeInfo.findWidgetInstanceByName(i)},getButton(i){return this._itemsRunTimeInfo.findWidgetInstanceByName(i)},updateDimensions(){let i=this,e=y();return i._scrollable?i._scrollable.update().done(()=>{e.resolveWith(i)}):e.resolveWith(i),e.promise()},itemOption(i,e,t){let n=this._generateItemsFromData(this.option("items")),o=this._getItemByField(i,n),s=SO(n,o);if(o)switch(arguments.length){case 1:return o;case 3:{let r=this._tryCreateItemOptionAction(e,o,t,o[e],s);this._changeItemOption(o,e,t);let a=Ia(s,e);!this._tryExecuteItemOptionAction(r)&&!this._tryChangeLayoutManagerItemOption(a,t)&&this.option("items",n);break}default:if($(e)&&!this._tryChangeLayoutManagerItemOptions(s,e)){let r;x(e,(a,l)=>{let d=this._tryCreateItemOptionAction(a,o,l,o[a],s);this._changeItemOption(o,a,l),!r&&!this._tryExecuteItemOptionAction(d)&&(r=!0)}),r&&this.option("items",n)}}},validate(){return Xt.validateGroup(this._getValidationGroup())},getItemID(i){return`dx_${this.option("formID")}_${i||new Oe}`},getTargetScreenFactor(){return this._targetScreenFactor}});G("dxForm",mL);var fL=mL;var _L=fL;var Am=_L;var PQ=i=>class extends i{init(){this._editForm=null,this._updateEditFormDeferred=null,super.init()}isEditRow(e){return!this.isPopupEditMode()&&super.isEditRow(e)}isFormOrPopupEditMode(){return this.isPopupEditMode()||this.isFormEditMode()}isFormEditMode(){return this.option("editing.mode")===Eu}getFirstEditableColumnIndex(){let e=this._firstFormItem;if(this.isFormEditMode()&&e){let t=this.option(zi),n=this._dataController.getRowIndexByKey(t),o=this._rowsView.getCellElements(n);return this._rowsView._getEditFormEditorVisibleIndex(o,e.column)}return super.getFirstEditableColumnIndex()}getEditFormRowIndex(){return this.isFormOrPopupEditMode()?this._getVisibleEditRowIndex():super.getEditFormRowIndex()}_isEditColumnVisible(){let e=super._isEditColumnVisible(),t=this.option("editing");return this.isFormOrPopupEditMode()&&t.allowUpdating||e}_handleDataChanged(e){if(this.isPopupEditMode()){var t,n;let o=this.option("editing.editRowKey"),s=e==null||(t=e.items)===null||t===void 0?void 0:t.some(a=>ve(a.key,o)),r=((n=e.changeTypes)===null||n===void 0?void 0:n.length)&&e.changeTypes.every(a=>a==="insert");(e.changeType==="refresh"||s&&e.isOptionChanged)&&!r&&this._repaintEditPopup()}super._handleDataChanged(e)}getPopupContent(){var e;let t=(e=this._editPopup)===null||e===void 0?void 0:e.option("visible");if(this.isPopupEditMode()&&t)return this._$popupContent}_showAddedRow(e){this.isPopupEditMode()?this._showEditPopup(e):super._showAddedRow(e)}_cancelEditDataCore(){super._cancelEditDataCore(),this.isPopupEditMode()&&this._hideEditPopup()}_updateEditRowCore(e,t,n){let o=this._editForm;if(this.isPopupEditMode())if(this.option("repaintChangesOnly")){var s;(s=e.update)===null||s===void 0||s.call(e,e),this._rowsView.renderDelayedTemplates()}else o&&(this._updateEditFormDeferred=new y().done(()=>o.repaint()),this._updateLockCount||this._updateEditFormDeferred.resolve());else super._updateEditRowCore(e,t,n)}_showEditPopup(e,t){let n=F.current().deviceType!=="desktop",o=this.addWidgetPrefix(sV),s=m({showTitle:!1,fullScreen:n,wrapperAttr:{class:o},toolbarItems:[{toolbar:"bottom",location:"after",widget:"dxButton",options:this._getSaveButtonConfig()},{toolbar:"bottom",location:"after",widget:"dxButton",options:this._getCancelButtonConfig()}],contentTemplate:this._getPopupEditFormTemplate(e)},this.option(ud));if(!this._editPopup){let r=u("<div>").appendTo(this.component.$element()).addClass(o);this._editPopup=this._createComponent(r,ii),this._editPopup.on("hiding",this._getEditPopupHiddenHandler()),this._editPopup.on("shown",a=>{if(_.trigger(a.component.$content().find(hd).not(`.${aV}`).first(),"focus"),t){var l;(l=this._editForm)===null||l===void 0||l.repaint()}})}this._editPopup.option(s),this._editPopup.show(),super._showEditPopup(e,t)}_getPopupEditFormTemplate(e){let t=this.component.getVisibleRows()[e],n={row:t,values:t.values,rowType:t.rowType,key:t.key,rowIndex:e};return this._rowsView._addWatchMethod(n,t),o=>{let s=this.getEditFormTemplate(),r=this._createComponent(u("<div>").appendTo(o),Pi);this._$popupContent=u(r.content()),s(this._$popupContent,n,{isPopupForm:!0}),this._rowsView.renderDelayedTemplates(),u(o).parent().attr("aria-label",this.localize("dxDataGrid-ariaEditForm"))}}_repaintEditPopup(){let e=this._getVisibleEditRowIndex();if(e>=0){var t,n;let o=(t=this._editPopup)===null||t===void 0?void 0:t.option("animation");(n=this._editPopup)===null||n===void 0||n.option("animation",null),this._showEditPopup(e,!0),o!==void 0&&this._editPopup.option("animation",o)}}_hideEditPopup(){var e;(e=this._editPopup)===null||e===void 0||e.option("visible",!1)}optionChanged(e){if(e.name==="editing"&&this.isFormOrPopupEditMode()){let{fullName:t}=e;t.indexOf(gm)===0?(this._handleFormOptionChange(e),e.handled=!0):t.indexOf(ud)===0&&(this._handlePopupOptionChange(e),e.handled=!0)}super.optionChanged(e)}_handleFormOptionChange(e){var t;if(this.isFormEditMode()){let n=this._getVisibleEditRowIndex();n>=0&&this._dataController.updateItems({changeType:"update",rowIndices:[n]})}else(t=this._editPopup)!==null&&t!==void 0&&t.option("visible")&&e.fullName.indexOf(gm)===0&&this._repaintEditPopup()}_handlePopupOptionChange(e){let t=this._editPopup;if(t){let n=e.fullName.slice(ud.length+1);n?t.option(n,e.value):t.option(e.value)}}renderFormEditorTemplate(e,t,n,o,s){let r=this,a=u(o),{column:l}=t,d=gV(t),c=e?.row,h=c?.data,p=n.component,g=l.calculateCellValue(h),C=M.getDisplayValue(l,g,h,c?.rowType),{label:v,labelMark:b,labelMode:T}=n.editorOptions||{},R=m({},e,{data:h,cellElement:null,isOnForm:!0,item:t,id:p.getItemID(t.name||t.dataField),column:m({},l,{editorType:d,editorOptions:m({label:v,labelMark:b,labelMode:T},l.editorOptions,t.editorOptions)}),columnIndex:l.index,setValue:!s&&l.allowEditing&&function(Q,se){r.updateFieldValue(R,Q,se)}});R.value=g,R.displayValue=C,R.text=l.command?"":M.formatValue(C,l);let U=this._getFormEditItemTemplate.bind(this)(R,l);return this._rowsView.renderTemplate(a,U,R,!!Lo(a)).done(()=>{this._rowsView._updateCell(a,R)}),R}getFormEditorTemplate(e,t){let n=this.component.columnOption(t.name||t.dataField);return(o,s)=>{let r=u(s),{row:a}=e;if(a!=null&&a.watch){let l=a.watch(()=>n.selector(a.data),()=>{var d;let c=r.find(".dx-widget").first(),h=c.data("dxValidator"),p=(d=h)===null||d===void 0?void 0:d.option();r.contents().remove(),e=this.renderFormEditorTemplate.bind(this)(e,t,o,r),c=r.find(".dx-widget").first(),h=c.data("dxValidator"),p&&!h&&c.dxValidator({validationRules:p.validationRules,validationGroup:p.validationGroup,dataGetter:p.dataGetter})});_.on(r,Gt,l)}e=this.renderFormEditorTemplate.bind(this)(e,t,o,r)}}getEditFormOptions(e){var t;let n=(t=this._getValidationGroupsInForm)===null||t===void 0?void 0:t.call(this,e),o=this.option("editing.form.customizeItem"),s=this.addWidgetPrefix(Xy),r=this.option("editing.form.items"),a={};if(r)tO(r,l=>{let d=l?.name||l?.dataField;d&&(a[d]=!!l.editorType)});else{let l=this._columnsController.getColumns();r=[],x(l,(d,c)=>{!c.isBand&&!c.type&&r.push({column:c,name:c.name,dataField:c.dataField})})}return m({},n,{items:r,formID:`dx-${new Oe}`,customizeItem:l=>{let d,c=l.name||l.dataField;if((l.column||c)&&(d=l.column||this._columnsController.columnOption(l.name?`name:${l.name}`:`dataField:${l.dataField}`)),d){if(l.label=l.label||{},l.label.text=l.label.text||d.caption,d.dataType==="boolean"&&l.label.visible===void 0){let p=this.option("editing.form.labelMode");(p==="floating"||p==="static")&&(l.label.visible=!0)}l.template=l.template||this.getFormEditorTemplate(e,l),l.column=d,l.isCustomEditorType=a[c],d.formItem&&m(l,d.formItem),l.isRequired===void 0&&d.validationRules&&(l.isRequired=d.validationRules.some(p=>p.type==="required"),l.validationRules=[]);let h=f(l.visible)?l.visible:!0;!this._firstFormItem&&h&&(this._firstFormItem=l)}o?.call(this,l),l.cssClass=B(l.cssClass)?`${l.cssClass} ${s}`:s}})}getEditFormTemplate(){return(e,t,n)=>{let o=this.option(gm),s=this.getEditFormOptions(t),r=u("<div>").appendTo(e),a=n?.isPopupForm;if(this._firstFormItem=void 0,a&&r.addClass(this.addWidgetPrefix(rV)),this._editForm=this._createComponent(r,Am,m({},o,s)),!a){let l=u("<div>").addClass(this.addWidgetPrefix(dV)).appendTo(e);this._createComponent(u("<div>").appendTo(l),rt,this._getSaveButtonConfig()),this._createComponent(u("<div>").appendTo(l),rt,this._getCancelButtonConfig())}this._editForm.on("contentReady",()=>{var l;this._rowsView.renderDelayedTemplates(),(l=this._editPopup)===null||l===void 0||l.repaint()})}}getEditForm(){return this._editForm}_endUpdateCore(){var e;(e=this._updateEditFormDeferred)===null||e===void 0||e.resolve()}_beforeEndSaving(e){if(super._beforeEndSaving(e),this.isPopupEditMode()){var t;(t=this._editPopup)===null||t===void 0||t.hide()}}_processDataItemCore(e,t,n,o,s){let{type:r}=t;this.isPopupEditMode()&&r===Mn&&(e.visible=!1),super._processDataItemCore(e,t,n,o,s)}_editRowFromOptionChangedCore(e,t){let n=this.isPopupEditMode();super._editRowFromOptionChangedCore(e,t,n),n&&this._showEditPopup(t)}},kQ=i=>class extends i{_updateEditItem(e){this._editingController.isFormEditMode()&&(e.rowType="detail")}_getChangedColumnIndices(e,t,n,o){if(!(o===!1&&t.isEditing&&this._editingController.isFormEditMode()))return super._getChangedColumnIndices.apply(this,arguments)}},BQ=i=>class extends i{_renderCellContent(e,t){t.rowType==="data"&&this._editingController.isPopupEditMode()&&t.row.visible===!1||super._renderCellContent.apply(this,arguments)}getCellElements(e){let t=super.getCellElements(e),n=this._editingController,o=n.getEditForm();return n.getEditFormRowIndex()===e&&t&&o?o.$element().find(`.${this.addWidgetPrefix(Xy)}, .${lV}`):t}_getVisibleColumnIndex(e,t,n){if(this._editingController.getEditFormRowIndex()===t&&B(n)){let s=this._columnsController.columnOption(n);return this._getEditFormEditorVisibleIndex(e,s)}return super._getVisibleColumnIndex.apply(this,arguments)}_getEditFormEditorVisibleIndex(e,t){let n=-1;return x(e,(o,s)=>{let r=u(s).find(".dx-field-item-content").data("dx-form-item");if(r!=null&&r.column&&t&&r.column.index===t.index)return n=o,!1}),n}_isFormItem(e){let t=e.rowType==="detail"||e.rowType==="detailAdaptive",n=e.rowType==="data"&&this._editingController.isPopupEditMode();return(t||n)&&e.item}_updateCell(e,t){this._isFormItem(t)?this._formItemPrepared(t,e):super._updateCell(e,t)}_updateContent(){let e=this._editingController,t=e.getEditForm(),n=t?.option("validationGroup");return super._updateContent.apply(this,arguments).done(()=>{let s=e.getEditForm();n&&s&&s!==t&&s.option("validationGroup",n)})}},CL={extenders:{controllers:{editing:PQ,data:kQ},views:{rowsView:BQ}}};H.registerModule("editingFormBased",CL);var VQ=i=>class extends i{init(){let e=!this._saveEditorHandler;if(super.init(),e){let t,n;this._pointerUpEditorHandler=()=>{var o;n=(o=this._columnsResizerController)===null||o===void 0?void 0:o.isResizing()},this._pointerDownEditorHandler=o=>t=u(o.target),this._saveEditorHandler=this.createAction(function(o){let{event:s}=o,r=u(s.target),a=s[mm],{component:l}=this;if(pV(t)&&!t.is(r))return;function d(c){if(!c)return!1;let h=c.closest(`.${tV}`),p=l.$element();return h.length>0&&p.closest(h).length===0}if(this.isCellOrBatchEditMode()&&!this._editCellInProgress){let c=d(r)||d(a?.$element()),h=a&&!a._disposed&&a!==this.component,p=!!r.closest(`.${this.addWidgetPrefix(eV)}`).length,g=r.hasClass(this.addWidgetPrefix(JB)),C=this.isCellEditMode();!n&&!c&&!g&&!(p&&C&&this.isEditing())&&(Lo(r)||h)&&this._closeEditItem.bind(this)(r)}}),_.on(w.getDocument(),ne.up,this._pointerUpEditorHandler),_.on(w.getDocument(),ne.down,this._pointerDownEditorHandler),_.on(w.getDocument(),oe,this._saveEditorHandler)}}isCellEditMode(){return this.option("editing.mode")===Su}isBatchEditMode(){return this.option("editing.mode")===Ou}isCellOrBatchEditMode(){return this.isCellEditMode()||this.isBatchEditMode()}_needToCloseEditableCell(e){let t=this.component.$element(),n=this.isEditing();if((!t||!!e.closest(t).length)&&e.closest(`.${iV}`).length){let a=e.closest(`.${So}> td`),l=this._rowsView.getRowIndex(a.parent()),d=this._rowsView.getCellElements(l);if(d!=null&&d.length){var s;let c=d.index(a),p=(s=this._columnsController.getVisibleColumns()[c])===null||s===void 0?void 0:s.allowEditing,g=this.isEditCell(l,c);n=n&&!p&&!g}}return n||super._needToCloseEditableCell(e)}_closeEditItem(e){this._needToCloseEditableCell(e)&&this.closeEditCell()}_focusEditorIfNeed(){if(this._needFocusEditor&&this.isCellOrBatchEditMode()){var e;let t=this._getVisibleEditColumnIndex(),n=(e=this._rowsView)===null||e===void 0?void 0:e._getCellElement(this._getVisibleEditRowIndex(),t);this._refocusEditCell=!1,clearTimeout(this._inputFocusTimeoutID),n&&!n.find(":focus").length?this._focusEditingCell(()=>{this._editCellInProgress=!1},n,!0):this._editCellInProgress=!1,this._needFocusEditor=!1}else super._focusEditorIfNeed()}isEditing(){if(this.isCellOrBatchEditMode()){let e=f(this.option(zi)),t=f(this.option(Ws));return e&&t}return super.isEditing()}_handleEditColumnNameChange(e){let t=this._getVisibleEditRowIndex(e.previousValue);if(this.isCellOrBatchEditMode()&&t!==-1&&f(e.value)&&e.value!==e.previousValue){let n=this._columnsController.getVisibleColumnIndex(e.value),o=this._columnsController.getVisibleColumnIndex(e.previousValue);this._editCellFromOptionChanged(n,o,t)}}_addRow(e){if(this.isCellEditMode()&&this.hasChanges()){let t=new y;return this.saveEditData().done(()=>{this.hasChanges()?t.reject("cancel"):this.addRow(e).done(t.resolve).fail(t.reject)}),t.promise()}return super._addRow(e)}editCell(e,t){return this._editCell({rowIndex:e,columnIndex:t})}_editCell(e){let t=new y,n;return this.executeOperation(t,()=>{n=this._editCellCore(e),P(n).done(t.resolve).fail(t.reject)}),n!==void 0?n:t.promise()}_editCellCore(e){let t=this._dataController,n=f(e.oldColumnIndex)||f(e.oldRowIndex),{columnIndex:o,rowIndex:s,column:r,item:a}=this._getNormalizedEditCellOptions(e),l={data:a?.data,cancel:!1,column:r};if(a.key===void 0){this._dataController.fireError("E1043");return}if(r&&(a.rowType==="data"||a.rowType==="detailAdaptive")&&!a.removed&&this.isCellOrBatchEditMode()){if(!n&&this.isEditCell(s,o))return!0;let d=s+t.getRowIndexOffset();return P(this._beforeEditCell(s,o,a)).done(c=>{c||this._prepareEditCell(l,a,o,d)||this._processCanceledEditingCell()})}return!1}_beforeEditCell(e,t,n){if(this.isCellEditMode()&&!n.isNewRow&&this.hasChanges()){let o=new y;return this.saveEditData().always(()=>{o.resolve(this.hasChanges())}),this.addDeferred(o),o}return!1}publicMethods(){return super.publicMethods().concat(["editCell","closeEditCell"])}_getNormalizedEditCellOptions(e){let{oldColumnIndex:t,oldRowIndex:n,columnIndex:o,rowIndex:s}=e,r=this._columnsController,a=r.getVisibleColumns(),d=this._dataController.items()[s],c;f(t)?c=a[t]:c=this._getEditColumn(),f(n)||(n=this._getVisibleEditRowIndex()),B(o)&&(o=r.columnOption(o,"index"),o=r.getVisibleIndex(o));let h=a[o];return{oldColumn:c,columnIndex:o,oldRowIndex:n,rowIndex:s,column:h,item:d}}_prepareEditCell(e,t,n,o){return t.isNewRow||(e.key=t.key),this._isEditingStart(e)?!1:(this._pageIndex=this._dataController.pageIndex(),this._setEditRowKey(t.key),this._setEditColumnNameByIndex(n),e.column.showEditorAlways||this._addInternalData({key:t.key,oldData:t.oldData??t.data}),!0)}closeEditCell(e,t){let n=P(),o=this._getVisibleEditRowIndex();if(this.isCellOrBatchEditMode()){let s=new y;n=new y,this.executeOperation(s,()=>{this._closeEditCellCore(e,o,t).always(n.resolve)})}return n.promise()}_closeEditCellCore(e,t,n){let o=this._dataController,s=new y,r=s.promise();if(this.isCellEditMode()&&this.hasChanges()){if(!n)return this.saveEditData().done(a=>{if(!this.hasChanges()){this.closeEditCell(!!a).always(s.resolve);return}s.resolve()}),r}else if(this._resetEditRowKey(),this._resetEditColumnName(),t>=0){let a=[t];this._beforeCloseEditCellInBatchMode(a),e||o.updateItems({changeType:"update",rowIndices:a})}return s.resolve(),r}_resetModifiedClassCells(e){if(this.isBatchEditMode()){let t=this._columnsController.getVisibleColumns().length;e.forEach(n=>{let{key:o}=n,s=this._dataController.getRowIndexByKey(o);for(let r=0;r<t;r++){let a=this._rowsView._getCellElement(s,r);a?.removeClass(AB)}})}}_prepareChange(e,t,n){let o=u(e.cellElement);return this.isBatchEditMode()&&e.key!==void 0&&this._applyModified(o,e),super._prepareChange(e,t,n)}_cancelSaving(e){let t=this._dataController;this.isCellOrBatchEditMode()&&(this.isBatchEditMode()&&this._resetEditIndices(),t.updateItems()),super._cancelSaving(e)}optionChanged(e){let{fullName:t}=e;e.name==="editing"&&t===Ws?(this._handleEditColumnNameChange(e),e.handled=!0):super.optionChanged(e)}_editCellFromOptionChanged(e,t,n){let o=this._columnsController.getVisibleColumns();e>-1&&nt(()=>{this._repaintEditCell(o[e],o[t],n)})}_handleEditRowKeyChange(e){if(this.isCellOrBatchEditMode()){let n=this._getVisibleEditColumnIndex(),o=this._getEditRowIndexCorrection(),s=this._dataController.getRowIndexByKey(e.previousValue)+o;if(f(e.value)&&e.value!==e.previousValue){var t;(t=this._editCellFromOptionChanged)===null||t===void 0||t.call(this,n,n,s)}}else super._handleEditRowKeyChange(e)}deleteRow(e){if(this.isCellEditMode()&&this.isEditing()){let{isNewRow:t}=this._dataController.items()[e],n=this._dataController.getKeyByRowIndex(e);this.closeEditCell(null,t).always(()=>{e=this._dataController.getRowIndexByKey(n),this._checkAndDeleteRow(e)})}else super.deleteRow(e)}_checkAndDeleteRow(e){this.isBatchEditMode()?this._deleteRowCore(e):super._checkAndDeleteRow(e)}_refreshCore(e){let{isPageChanged:t}=e??{},n=this.isBatchEditMode()||t&&this.option("scrolling.mode")!=="virtual";this.isCellOrBatchEditMode()?n&&(this._resetEditColumnName(),this._resetEditRowKey()):super._refreshCore(e)}_allowRowAdding(e){return this.isBatchEditMode()?!0:super._allowRowAdding(e)}_afterDeleteRow(e,t){let n=this._dataController;return this.isBatchEditMode()?(n.updateItems({changeType:"update",rowIndices:[t,e]}),new y().resolve()):super._afterDeleteRow(e,t)}_updateEditRow(e,t,n){this.isCellOrBatchEditMode()?this._updateRowImmediately(e,t,n):super._updateEditRow(e,t,n)}_isDefaultButtonVisible(e,t){if(this.isCellOrBatchEditMode()){let n=this.isBatchEditMode();switch(e.name){case"save":case"cancel":case"edit":return!1;case"delete":return super._isDefaultButtonVisible(e,t)&&(!n||!t.row.removed);case"undelete":return n&&this.allowDeleting(t)&&t.row.removed;default:return super._isDefaultButtonVisible(e,t)}}return super._isDefaultButtonVisible(e,t)}_isRowDeleteAllowed(){return super._isRowDeleteAllowed()||this.isBatchEditMode()}_beforeEndSaving(e){if(this.isCellEditMode()){var t;((t=e[0])===null||t===void 0?void 0:t.type)!=="update"&&super._beforeEndSaving(e)}else this.isBatchEditMode()&&this._resetModifiedClassCells(e),super._beforeEndSaving(e)}prepareEditButtons(e){let t=this.option("editing")??{},n=super.prepareEditButtons(e);return(t.allowUpdating||t.allowAdding||t.allowDeleting)&&this.isBatchEditMode()&&(n.push(this.prepareButtonItem(e,"save","saveEditData",21)),n.push(this.prepareButtonItem(e,"revert","cancelEditData",22))),n}_saveEditDataInner(){var e;let t=this._dataController.getVisibleRows()[this.getEditRowIndex()],n=this._getEditColumn(),o=n?.showEditorAlways,s=this.isCellEditMode()&&!(t!=null&&t.isNewRow),r;return s&&o&&(r=new y,this.addDeferred(r)),super._saveEditDataInner().always((e=r)===null||e===void 0?void 0:e.resolve)}_applyChange(e,t,n){let o=this.isCellEditMode()&&e.row&&!e.row.isNewRow,{showEditorAlways:s}=e.column,r=e.column.setCellValue!==e.column.defaultSetCellValue;if(s&&!n&&o&&this.hasEditData()&&!this.isEditCell(e.rowIndex,e.columnIndex)){this._focusEditingCell(),this._updateEditRow(e.row,!0,r);return}return super._applyChange(e,t,n)}_applyChangeCore(e,t){let{showEditorAlways:n}=e.column,o=this.isCellEditMode()&&e.row&&!e.row.isNewRow;if(n&&!t){if(o)return this._setEditRowKey(e.row.key,!0),this._setEditColumnNameByIndex(e.columnIndex,!0),this.saveEditData();if(this.isBatchEditMode())return t=this._needUpdateRow(e.column),super._applyChangeCore(e,t)}return super._applyChangeCore(e,t)}_processDataItemCore(e,t,n,o,s){let{data:r,type:a}=t;this.isBatchEditMode()&&a===Eo&&(e.data=ho(e.data,r)),super._processDataItemCore(e,t,n,o,s)}_processRemoveCore(e,t,n){if(!(this.isBatchEditMode()&&!n))return super._processRemoveCore(e,t,n)}_processRemoveIfError(e,t){if(!this.isBatchEditMode())return super._processRemoveIfError(e,t)}_beforeFocusElementInRow(e){super._beforeFocusElementInRow(e);let t=e>=0?e:0,n=this.getFirstEditableColumnIndex();n>=0&&this.editCell(t,n)}},LQ=i=>class extends i{_createTable(){let e=super._createTable.apply(this,arguments),t=this._editingController;return t.isCellOrBatchEditMode()&&this.option("editing.allowUpdating")&&_.on(e,D(an.name,"dxDataGridRowsView"),`td:not(.${Vr})`,this.createAction(()=>{t.isEditing()&&t.closeEditCell()})),e}_createRow(e){let t=super._createRow.apply(this,arguments);if(e){let n=this._editingController,o=!!e.removed;n.isBatchEditMode()&&o&&t.addClass(nV)}return t}},xL={extenders:{controllers:{editing:VQ},views:{rowsView:LQ}}};H.registerModule("editingCellBased",xL);var vL="__DX_INSERT_INDEX__";var bL="row";var Mm="batch",Cd="cell";var yL=["popup","form"];var xn={valid:"valid",invalid:"invalid",pending:"pending"};var Mu=function(i){return f(i)&&i!=="cancel"},OL=function(i,e){return i!==void 0||i===void 0&&e&&!e.isNewRow},MO=class extends Ce.Controller{constructor(){super(...arguments),this._isValidationInProgress=!1,this._disableApplyValidationResults=!1}init(){this._editingController=this.getController("editing"),this._editorFactoryController=this.getController("editorFactory"),this._columnsController=this.getController("columns"),this.createAction("onRowValidating"),this._validationState||this.initValidationState()}initValidationState(){this._validationState=[],this._validationStateCache={}}_rowIsValidated(e){let t=this._getValidationData(e?.key);return!!t&&!!t.validated}_getValidationData(e,t){let n=ai(e),o=$(n),s;return o?s=this._validationState.filter(r=>ve(r.key,e))[0]:s=this._validationStateCache[n],!s&&t&&(s={key:e,isValid:!0},this._validationState.push(s),o||(this._validationStateCache[n]=s)),s}_getBrokenRules(e,t){let n;return t?n=t.brokenRules||t.brokenRule&&[t.brokenRule]:n=e.brokenRules||[],n}_rowValidating(e,t){let n=new y,o=this._editingController.getChangeByKey(e?.key),s=this._getBrokenRules(e,t),r=t?t.isValid:e.isValid,a={brokenRules:s,isValid:r,key:o.key,newData:o.data,oldData:this._editingController._getOldData(o.key),promise:null,errorText:this.getHiddenValidatorsErrorText(s)};return this.executeAction("onRowValidating",a),P(ht(a.promise)).always(()=>{e.isValid=a.isValid,e.errorText=a.errorText,n.resolve(a)}),n.promise()}getHiddenValidatorsErrorText(e){let t=[];return x(e,(n,o)=>{let{column:s}=o,r=s&&s.groupIndex!==void 0&&!s.showWhenGrouped,a=s&&s.visible;!o.validator.$element().parent().length&&(!a||r)&&t.push(o.message)}),t.join(", ")}validate(e){let t=!0,n=this._editingController,o=new y,s=[],r=n.getEditMode();if(e=e||r===bL,this._isValidationInProgress)return o.resolve(!1).promise();if(this._isValidationInProgress=!0,e){n.addDeferred(o);let a=n.getChanges();x(a,(l,d)=>{let{type:c,key:h}=d;if(c!=="remove"){let p=this._getValidationData(h,!0),g=this.validateGroup(p);s.push(g),g.done(C=>{p.validated=!0,t=t&&C.isValid})}})}else if(this._currentCellValidator){let a=this.validateGroup(this._currentCellValidator._findGroup());s.push(a),a.done(l=>{t=l.isValid})}return P(...s).done(()=>{this._isValidationInProgress=!1,o.resolve(t)}),o.promise()}validateGroup(e){var t;let n=new y,o=e&&Xt.getGroupConfig(e),s;return o!=null&&o.validators.length&&(this.resetRowValidationResults(e),s=Xt.validateGroup(e)),P(((t=s)===null||t===void 0?void 0:t.complete)||s).done(r=>{P(this._rowValidating(e,r)).done(n.resolve)}),n.promise()}isRowDataModified(e){return!dt(e.data)}updateValidationState(e){let t=this._editingController.getEditMode(),{key:n}=e,o=this._getValidationData(n,!0);if(yL.includes(t))o.isValid=!0;else{if(e.type==="insert"&&!this.isRowDataModified(e)){o.isValid=!0;return}if(this.setDisableApplyValidationResults(!0),Xt.getGroupConfig(o)){let r=Xt.validateGroup(o);P(r.complete||r).done(a=>{o.isValid=a.isValid,o.brokenRules=a.brokenRules})}else(!o.brokenRules||!o.brokenRules.length)&&(o.isValid=!0);this.setDisableApplyValidationResults(!1)}}setValidator(e){this._currentCellValidator=e}renderCellPendingIndicator(e){let t=e.find(".dx-pending-indicator");if(!t.length){let n=e;t=u("<div>").appendTo(n).addClass("dx-pending-indicator"),this._createComponent(t,ni),e.addClass("dx-validation-pending")}}disposeCellPendingIndicator(e){let t=e.find(".dx-pending-indicator");if(t.length){let n=ni.getInstance(t);n&&(n.dispose(),n.$element().remove()),e.removeClass("dx-validation-pending")}}validationStatusChanged(e){let{validator:t}=e,n=t.option("validationGroup"),{column:o}=t.option("dataGetter")();this.updateCellValidationResult({rowKey:n.key,columnIndex:o.index,validationResult:e})}validatorInitialized(e){e.component.on("validating",this.validationStatusChanged.bind(this)),e.component.on("validated",this.validationStatusChanged.bind(this))}validatorDisposing(e){let t=e.component,n=t.option("validationGroup"),{column:o}=t.option("dataGetter")(),s=this.getCellValidationResult({rowKey:n?.key,columnIndex:o.index});Mu(s)&&s.status===xn.pending&&this.cancelCellValidationResult({change:n,columnIndex:o.index})}applyValidationResult(e,t){let{validator:n}=t,o=n.option("validationGroup"),{column:s}=n.option("dataGetter")();if(t.brokenRules&&t.brokenRules.forEach(r=>{r.columnIndex=s.index,r.column=s}),e){let r=this.getCellValidationResult({rowKey:o.key,columnIndex:s.index}),a=Mu(r)&&r.disabledPendingId===t.id;if(this._disableApplyValidationResults||a)return;if(t.status===xn.invalid){let d=e.find(":focus");pn(d)||(_.trigger(d,"focus"),_.trigger(d,ne.down))}let l=!s.editCellTemplate&&this._editorFactoryController.getEditorInstance(e);t.status===xn.pending?l?l.option("validationStatus",xn.pending):this.renderCellPendingIndicator(e):l?l.option("validationStatus",xn.valid):this.disposeCellPendingIndicator(e),e.toggleClass(this.addWidgetPrefix("invalid"),t.status===xn.invalid)}}_syncInternalEditingData(e){var t;let n=this._editingController,o=n.getChangeByKey(e.key),s=n._getOldData(e.key),r=(t=e.row)===null||t===void 0?void 0:t.oldData;o&&r&&!s&&n._addInternalData({key:e.key,oldData:r})}createValidator(e,t){let n=this._editingController,{column:o}=e,{showEditorAlways:s}=o;if(f(o.command)||!o.validationRules||!Array.isArray(o.validationRules)||!o.validationRules.length)return;let a=n.getIndexByKey(e.key,n.getChanges())>-1;if(!a){if(!s){var l;s=(((l=this._columnsController)===null||l===void 0?void 0:l.getVisibleColumns())||[]).some(g=>g.showEditorAlways)}let c=ve(this.option("editing.editRowKey"),e.key),h=n.isCellOrBatchEditMode()&&n.allowUpdating({row:e.row});if(a=c||h&&s,h&&s){var d;n._addInternalData({key:e.key,oldData:((d=e.row)===null||d===void 0?void 0:d.oldData)??e.data})}}if(a){if(t&&!t.length){Z.log("E1050");return}this._syncInternalEditingData(e);let c=this._getValidationData(e.key,!0),h=()=>{let C=n.getChangeByKey(c?.key),v=o.calculateCellValue(C?.data||{});return v!==void 0?v:e.value},p=t&&t.hasClass("dx-widget");t&&t.addClass(this.addWidgetPrefix("validator"));let g=new xm(t||u("<div>"),{name:o.caption,validationRules:m(!0,[],o.validationRules),validationGroup:c,adapter:p?null:{getValue:h,applyValidationResults:C=>{this.applyValidationResult(t,C)}},dataGetter(){let C=c?.key,v=n.getChangeByKey(C),b=n._getOldData(C);return{data:ho(b,v?.data),column:o}},onInitialized:this.validatorInitialized.bind(this),onDisposing:this.validatorDisposing.bind(this)});if(p){let C=g.option("adapter");if(C){let v=C.bypass,b=()=>e.row.isNewRow&&!this._isValidationInProgress&&!n.isCellModified(e);C.getValue=h,C.validationRequestsCallbacks=[],C.bypass=()=>v.call(C)||b()}}return g}}setDisableApplyValidationResults(e){this._disableApplyValidationResults=e}getDisableApplyValidationResults(){return this._disableApplyValidationResults}isCurrentValidatorProcessing(e){let{rowKey:t,columnIndex:n}=e;return this._currentCellValidator&&ve(this._currentCellValidator.option("validationGroup").key,t)&&this._currentCellValidator.option("dataGetter")().column.index===n}validateCell(e){let t={rowKey:e.option("validationGroup").key,columnIndex:e.option("dataGetter")().column.index,validationResult:null},n=this.getCellValidationResult(t),o=Mu(n),s=e.option("adapter");if(!o)n=e.validate();else{let a=s.getValue();ve(a,n.value)||(n=e.validate())}let r=new y;return o&&n.status===xn.pending&&(this.updateCellValidationResult(t),s.applyValidationResults(n)),P(n.complete||n).done(a=>{o&&s.applyValidationResults(a),r.resolve(a)}),r.promise()}updateCellValidationResult(e){let{rowKey:t,columnIndex:n,validationResult:o}=e,s=this._getValidationData(t);if(!s)return;s.validationResults||(s.validationResults={});let r;if(o){if(r=m({},o),s.validationResults[n]=r,o.status===xn.pending&&(this._editingController.getEditMode()===Cd&&(r.deferred=new y,r.complete.always(()=>{r.deferred.resolve()}),this._editingController.addDeferred(r.deferred)),this._disableApplyValidationResults)){r.disabledPendingId=o.id;return}}else r=s.validationResults[n];r&&r.disabledPendingId&&delete r.disabledPendingId}getCellValidationResult(e){var t;let{rowKey:n,columnIndex:o}=e,s=this._getValidationData(n,!0);return s==null||(t=s.validationResults)===null||t===void 0?void 0:t[o]}removeCellValidationResult(e){let{change:t,columnIndex:n}=e,o=this._getValidationData(t?.key);o&&o.validationResults&&(this.cancelCellValidationResult({change:t,columnIndex:n}),delete o.validationResults[n])}cancelCellValidationResult(e){let{change:t,columnIndex:n}=e,o=this._getValidationData(t.key);if(t&&o.validationResults){let s=o.validationResults[n];s&&(s.deferred&&s.deferred.reject("cancel"),o.validationResults[n]="cancel")}}resetRowValidationResults(e){e&&(e.validationResults&&delete e.validationResults,delete e.validated)}isInvalidCell(e){let{rowKey:t,columnIndex:n}=e,o=this.getCellValidationResult({rowKey:t,columnIndex:n});return Mu(o)&&o.status===xn.invalid}getCellValidator(e){let{rowKey:t,columnIndex:n}=e,o=this._getValidationData(t),s=o&&Xt.getGroupConfig(o),r=s&&s.validators;return r&&r.filter(a=>{let{column:l}=a.option("dataGetter")();return l?l.index===n:!1})[0]}setCellValidationStatus(e){let t=this.getCellValidationResult({rowKey:e.key,columnIndex:e.column.index});f(t)?e.validationStatus=t!=="cancel"?t.status:"cancel":delete e.validationStatus}},NQ=i=>class extends i{processDataItemTreeListHack(e){super.processDataItem.apply(this,arguments)}processItemsTreeListHack(e,t){return super.processItems.apply(this,arguments)}_addChange(e){let t=super._addChange.apply(this,arguments);return t&&e.type!=="remove"&&this._validatingController.updateValidationState(t),t}_handleChangesChange(e){super._handleChangesChange.apply(this,arguments),e.value.forEach(t=>{this._validatingController._getValidationData(t.key)===void 0&&this._validatingController.updateValidationState(t)})}_updateRowAndPageIndices(){let e=this,t=e.getView("rowsView").getTopVisibleItemIndex(),n=t;x(e.getChanges(),(o,s)=>{let{key:r,type:a}=s,l=this._validatingController._getValidationData(r);l&&!l.isValid&&l.pageIndex!==e._pageIndex&&(l.pageIndex=e._pageIndex,a==="insert"?l.rowIndex=t:l.rowIndex=n,n++)})}_getValidationGroupsInForm(e){return{validationGroup:this._validatingController._getValidationData(e.key,!0)}}_validateEditFormAfterUpdate(e,t){t&&this._editForm&&this._editForm.validate(),super._validateEditFormAfterUpdate.apply(this,arguments)}_prepareEditCell(e){let t=super._prepareEditCell.apply(this,arguments);return t&&e.column.showEditorAlways&&this._validatingController.updateValidationState({key:e.key}),t}processItems(e,t){let n=this.getChanges(),o=(r,a)=>{let l=-1,d=r.type==="insert",{key:c}=r;return x(a,(h,p)=>{if(ve(c,d?p.key:this._dataController.keyOf(p)))return l=h,!1}),l};e=super.processItems(e,t);let s=e.length;return this.getEditMode()===Mm&&t!=="prepend"&&t!=="append"&&n.forEach(r=>{let{key:a}=r,l=this._validatingController._getValidationData(a);l&&r.type&&l.pageIndex===this._pageIndex&&r?.pageIndex!==this._pageIndex&&function(d,c){let h={key:d.key};if(o(d,e)>=0)return;c.rowIndex=c.rowIndex>s?c.rowIndex%s:c.rowIndex;let{rowIndex:g}=c;h[vL]=1,e.splice(g,0,h)}(r,l)}),e}processDataItem(e){let t=e.data[vL],n=t?e.data.key:e.key;if(this.getEditMode()===Mm&&t&&n){let s=this.getChanges(),r=M.getIndexByKey(n,s);if(r>=0){let a=s[r];if(a.type!=="insert"){let l=this._getOldData(a.key);e.data=m(!0,{},l,a.data),e.key=n}}}super.processDataItem.apply(this,arguments)}_createInvisibleColumnValidators(e){let t=this,n=this._columnsController.getColumns(),o=this._columnsController.getInvisibleColumns().filter(l=>!l.isBand),s=this._columnsController.getGroupColumns().filter(l=>!l.showWhenGrouped&&o.indexOf(l)===-1),r=[],a=(l,d)=>this._dataController.getRowIndexByKey(d)>=0&&o.indexOf(l)<0;return o.push(...s),yL.includes(this.getEditMode())||x(n,(l,d)=>{e.forEach(c=>{let h;if(!a(d,c.key)){if(c.type==="insert")h=c.data;else if(c.type==="update"){let p=t._getOldData(c.key);if(!f(p))return;h=ho(p,c.data)}if(h){let p=this._validatingController.createValidator({column:d,key:c.key,value:d.calculateCellValue(h)});p&&r.push(p)}}})}),function(){r.forEach(l=>{l.dispose()})}}_beforeSaveEditData(e,t){let n=super._beforeSaveEditData.apply(this,arguments),o=this._validatingController._getValidationData(e?.key,!0);if(e){let s=e.type==="remove"||o.isValid;n=n||!s}else{let s=this._createInvisibleColumnValidators(this.getChanges());n=new y,this.executeOperation(n,()=>{this._validatingController.validate(!0).done(r=>{switch(s(),this._updateRowAndPageIndices(),this.getEditMode()){case Cd:r||this._focusEditingCell();break;case Mm:r||(this._resetEditRowKey(),this._resetEditColumnName(),this._dataController.updateItems())}n.resolve(!r)})})}return n.promise?n.promise():n}_beforeEditCell(e,t,n){let o=super._beforeEditCell(e,t,n);if(this.getEditMode()===Cd){let s=this._rowsView._getCellElement(e,t),r=s&&s.data("dxValidator"),a=s&&s.closest(".dx-row").data("options"),l=r&&r.option("adapter").getValue();if(r&&OL(l,a)){let d=new y;return P(this._validatingController.validateCell(r),o).done((c,h)=>{d.resolve(c.status===xn.valid&&h)}),d.promise()}if(!r)return o}return!1}_afterSaveEditData(e){let t,n=this.getEditMode()===Cd;if(x(this.getChanges(),(o,s)=>{let r=this._showErrorRow(s);t=t||r}),t){let o=this._rowsView.getScrollable();o&&(o.update(),o.scrollToElement(t))}if(e&&n&&this._needUpdateRow()){let o=this.getEditRowIndex();this._dataController.updateItems({changeType:"update",rowIndices:[o]}),this._focusEditingCell()}else if(!e){let o=!0;n&&(o=!(this._columnsController.getColumns().filter(a=>{var l;return a.showEditorAlways&&((l=a.validationRules)===null||l===void 0?void 0:l.length)>0}).length>0)),o&&this._validatingController.initValidationState()}}_handleDataChanged(e){let t=this._validatingController._validationState;this.option("scrolling.mode")==="standard"&&this.resetRowAndPageIndices(),e.changeType==="prepend"&&x(t,(n,o)=>{o.rowIndex+=e.items.length}),super._handleDataChanged(e)}resetRowAndPageIndices(){let e=this._validatingController._validationState;x(e,(t,n)=>{n.pageIndex!==this._pageIndex&&(delete n.pageIndex,delete n.rowIndex)})}_beforeCancelEditData(){this._validatingController.initValidationState(),super._beforeCancelEditData()}_showErrorRow(e){let t,n=this._dataController.items(),o=this.getIndexByKey(e.key,n),s=this._validatingController._getValidationData(e.key);if(!(s!=null&&s.isValid)&&s!==null&&s!==void 0&&s.errorText&&o>=0)return t=this.getPopupContent(),this._errorHandlingController&&this._errorHandlingController.renderErrorRow(s?.errorText,o,t)}updateFieldValue(e){let t=new y;return this._validatingController.removeCellValidationResult({change:this.getChangeByKey(e.key),columnIndex:e.column.index}),super.updateFieldValue.apply(this,arguments).done(()=>{let n=this._validatingController.getCellValidator({rowKey:e.key,columnIndex:e.column.index});P(n&&this._validatingController.validateCell(n)).done(o=>{this._editorFactoryController.refocus(),t.resolve(o)})}),t.promise()}highlightDataCell(e,t){super.highlightDataCell.apply(this,arguments),this._validatingController.setCellValidationStatus(t);let n=!!t.setValue,o=this.isCellModified(t),s=f(t.validationStatus);if(o&&t.column.setCellValue||n&&!o&&!(t.row.isNewRow||!s)){let a=e.data("dxValidator");a&&P(this._validatingController.validateCell(a)).done(()=>{this._validatingController.setCellValidationStatus(t)})}}getChangeByKey(e){let t=this.getChanges();return t[M.getIndexByKey(e,t)]}isCellModified(e){let t=super.isCellModified(e),n=this.getChangeByKey(e.key),o=!!e.row&&this._validatingController.isInvalidCell({rowKey:e.key,columnIndex:e.column.index});return t||this._validatingController._rowIsValidated(n)&&o}},HQ=function(i,e){let t=u(e).closest("tr").index(),n=u(i._rowsView.getRowElement(t)).first().children().filter(":not(.dx-hidden-cell)");return i._rowsView._getWidths(n).reduce((o,s)=>o+s,0)},$Q=function(i){let e,t;return i.some((n,o)=>{if(n.command==="transparent")return e=o===0?-1:o,t=o===i.length-1?-1:o+n.colspan-1,!0}),{startColumnIndex:e,endColumnIndex:t}},zQ=i=>class extends i{_showRevertButton(e){var t,n;let o=(t=this._revertTooltip)===null||t===void 0?void 0:t.$element();if(!e||!e.length){var s;(s=o)===null||s===void 0||s.remove(),this._revertTooltip=void 0;return}if(e.find(o).length)return;let r=e.closest(`.${this.addWidgetPrefix("content")}`).parent(),a=this.addWidgetPrefix("revert-tooltip");(n=o)===null||n===void 0||n.remove(),o=u("<div>").addClass(a).appendTo(e);let l={animation:null,visible:!0,width:"auto",height:"auto",shading:!1,container:r,propagateOutsideClick:!0,hideOnOutsideClick:!1,wrapperAttr:{class:a},contentTemplate:()=>{let d=u("<div>").addClass("dx-revert-button"),c={icon:"revert",hint:this.option("editing.texts.validationCancelChanges"),elementAttr:{id:"dxRevertButton","aria-label":O.format("dxDataGrid-ariaRevertButton")},onClick:()=>{this._editingController.cancelEditData()}};return new rt(d,c).$element()},position:{my:"left top",at:"right top",offset:"1 0",collision:"flip",boundaryOffset:"0 0",boundary:this._rowsView.element(),of:e},onPositioned:this._positionedHandler.bind(this)};this._revertTooltip=new Ni(o,l)}_hideFixedGroupCell(e,t){let n,o,s=this._rowsView.isFixedColumns(),r=this._editingController.isFormOrPopupEditMode();if(s&&!r){let a=e.closest(".dx-row").next().data("options");a&&a.rowType==="group"&&(n=u(this._rowsView.getRowElement(a.rowIndex)).last(),o=n.find(".dx-group-cell"),o.length&&o.get(0).style.visibility!=="hidden"&&(o.css("visibility","hidden"),t.onDisposing=function(){o.css("visibility","")}))}}_positionedHandler(e,t){if(!e.component.__skipPositionProcessing){let n=u(e.element).hasClass(this.addWidgetPrefix("revert-tooltip")),o=!n&&this._rowsView.updateFreeSpaceRowHeight(),s=this._normalizeValidationMessagePositionAndMaxWidth(e,n,t);e.component.__skipPositionProcessing=!!(o||s),s?e.component.option(s):o&&e.component.repaint()}}_showValidationMessage(e,t,n){var o;let s=e.find(".dx-dropdowneditor-overlay").data("dxPopup"),r=s&&s.option("visible"),a=r?"top right":`top ${n}`,l=r?"top left":`bottom ${n}`,c=((o=this._columnsController.getFixedColumns())===null||o===void 0?void 0:o.length)>0?this.getView("rowsView").element():e.closest(`.${this.addWidgetPrefix("content")}`),h="";t&&t.forEach(v=>{h+=(h.length?"<br/>":"")+Zu(v)});let p=this.addWidgetPrefix("invalid-message");this._rowsView.element().find(`.${p}`).remove();let g=u("<div>").addClass("dx-invalid-message").addClass("dx-invalid-message-always").addClass(p).html(h).appendTo(e),C={container:c,shading:!1,width:"auto",height:"auto",visible:!0,animation:!1,propagateOutsideClick:!0,hideOnOutsideClick:!1,wrapperAttr:{id:"dxInvalidMessage",class:`dx-invalid-message dx-invalid-message-always ${p}`},position:{collision:"flip",boundary:this._rowsView.element(),boundaryOffset:"0 0",offset:{x:0,y:!r&&be.mozilla?-1:0},my:a,at:l,of:e},onPositioned:v=>{this._positionedHandler(v,r),this._shiftValidationMessageIfNeed(v.component.$content(),e)}};this._hideFixedGroupCell(e,C),new Ni(g,C)}_hideValidationMessage(){var e;let t=(e=this._rowsView.element())===null||e===void 0?void 0:e.find(this._getValidationMessagesSelector());t?.remove()}_normalizeValidationMessagePositionAndMaxWidth(e,t,n){let o=this._columnsController.getFixedColumns();if(!o||!o.length)return;let s,r=!t&&HQ(this,e.element),a=e.component.$content(),l=ie(a,!0),d=!t&&l>r,c=this._rowsView.getCellIndex(u(e.element).closest("td")),h=$Q(o);return!t&&(c===h.startColumnIndex||d)?s={collision:"none flip",my:"top left",at:n?"top right":"bottom left"}:c===h.endColumnIndex&&(s={collision:"none flip",my:"top right",at:t||n?"top left":"bottom right"},t&&(s.offset="-1 0")),s&&{position:s,maxWidth:d?r-2:void 0}}_shiftValidationMessageIfNeed(e,t){let n=this._revertTooltip&&this._revertTooltip.$content();if(!n)return;let o=e.offset(),s=n.offset();if(o.top===s.top&&o.left+z(e)>s.left){let r=z(n)+2;e.css("left",s.left<t.offset().left?-r:r)}}_getRevertTooltipsSelector(){return`.dx-editor-cell .${this.addWidgetPrefix("revert-tooltip")}`}_getValidationMessagesSelector(){let e=this.addWidgetPrefix("invalid-message");return`.dx-editor-cell .${e}, .dx-cell-modified .${e}`}loseFocus(e){e||this._validatingController.setValidator(null),super.loseFocus()}updateCellState(e,t,n){var o;let s=e?.closest(this._getFocusCellSelector()),r=s!=null&&s.is("td")?s:null,a=s?.closest(".dx-row").data("options"),l=a?this._editingController.getChangeByKey(a.key):null,d=r&&this._columnsController.getVisibleColumns()[r.index()],c=(l==null||(o=l.data)===null||o===void 0?void 0:o[d?.name])!==void 0&&!this._editingController.isSaving(),h=[];if(this._editingController.getEditMode()===Cd&&(t?.status===xn.invalid||c?(this._showRevertButton(s),h.push("dxRevertButton")):this._revertTooltip&&this._revertTooltip.$element().remove()),t&&t.status===xn.invalid&&r&&d&&t&&t.brokenRules){let g=[];t.brokenRules.forEach(C=>{C.message&&g.push(C.message)}),g.length&&(this._showValidationMessage(s,g,d.alignment||"left"),h.push("dxInvalidMessage"))}this._updateAriaValidationAttributes(s,h),!n&&this._rowsView.element()&&this._rowsView.updateFreeSpaceRowHeight()}_updateAriaValidationAttributes(e,t){if(t.length===0)return;let n=this._editingController.getEditMode();if([Cd,Mm,bL].includes(n)){let s=this._getCurrentFocusElement(e);s.attr("aria-labelledby",t.join(" ")),s.attr("aria-invalid",!0)}}_getCurrentFocusElement(e){return this._editingController.isEditing()?e.find(yu).first():e}focus(e,t){if(!arguments.length)return super.focus();if(this._hideValidationMessage(),e!=null&&e.hasClass("dx-row")||e!=null&&e.hasClass("dx-master-detail-cell"))return super.focus(e,t);let n=e?.closest(this._getFocusCellSelector()),o=n&&(n.data("dxValidator")||e.find(`.${this.addWidgetPrefix("validator")}`).eq(0).data("dxValidator")),s=n&&n.closest(".dx-row").data("options"),r=s?this._editingController.getChangeByKey(s.key):null,a;if(o){this._validatingController.setValidator(o);let l=o.option("adapter").getValue();if(OL(l,s)||this._validatingController._rowIsValidated(r))return this._editingController.waitForDeferredOperations().done(()=>{this._rowsView.isElementInside(e)&&P(this._validatingController.validateCell(o)).done(c=>{a=c;let{column:h}=a.validator.option("dataGetter")();r&&h&&!this._validatingController.isCurrentValidatorProcessing({rowKey:r.key,columnIndex:h.index})||(!ut(ct())&&a.status===xn.invalid&&(t=!0),this.updateCellState(e,a,t),super.focus.call(this,e,t))})}),super.focus(e,t)}return this.updateCellState(e,a,t),super.focus(e,t)}getEditorInstance(e){let t=e.find(".dx-texteditor").eq(0);return M.getWidgetInstance(t)}},WQ=i=>class extends i{_getValidationStatus(e){return(Mu(e)?e.status:e)||xn.valid}_isCellChanged(e,t,n,o,s){var r,a;let l=(r=e.cells)===null||r===void 0?void 0:r[o],d=this._getValidationStatus({status:l?.validationStatus}),c=this._validatingController.getCellValidationResult({rowKey:e.key,columnIndex:o}),h=this._validatingController._getValidationData(e.key),p=this._getValidationStatus(c),g=JSON.stringify(t.modifiedValues)!==JSON.stringify(e.modifiedValues),C=d!==p&&g,v=u(l?.cellElement).hasClass(this.addWidgetPrefix("invalid")),b=l==null||(a=l.column.validationRules)===null||a===void 0?void 0:a.length,T=e.isEditing!==t.isEditing&&b,R=C||h.isValid&&v;return T||R?!0:super._isCellChanged.apply(this,arguments)}},GQ=i=>class extends i{updateFreeSpaceRowHeight(e){let t=this,n,o,s,r=t.element(),a=r&&r.find(`.${t.addWidgetPrefix("invalid-message")} .dx-overlay-content`);if(super.updateFreeSpaceRowHeight(e),a&&a.length&&(n=t._getRowElements(),s=t._getFreeSpaceRowElements(e),o=s.first(),o&&n.length===1&&(!o.is(":visible")||X(a)>X(o))))return s.show(),xi(s,X(a)),!0}_formItemPrepared(e,t){super._formItemPrepared.apply(this,arguments),Jt(()=>{let n=t.find(".dx-widget").first();n.length&&!n.children().length||this._validatingController.createValidator(e,n)})}_cellPrepared(e,t){this._editingController.isFormOrPopupEditMode()||this._validatingController.createValidator(t,e),super._cellPrepared.apply(this,arguments)}_restoreErrorRow(e){this._editingController&&this._editingController.hasChanges()&&this._getRowElements(e).each((t,n)=>{let o=u(n).data("options");if(o){let s=this._editingController.getChangeByKey(o.key);s&&this._editingController._showErrorRow(s)}})}},SL={defaultOptions:()=>({editing:{texts:{validationCancelChanges:O.format("dxDataGrid-validationCancelChanges")}}}),controllers:{validating:MO},extenders:{controllers:{editing:NQ,editorFactory:zQ,data:WQ},views:{rowsView:GQ}}};H.registerModule("validating",SL);var RO="scrolling.legacyMode",IL=i=>i.option("scrolling.loadTwoPagesOnStart")||i._controller.isVirtual()||i._controller.getViewportItemIndex()>0,Rm=i=>i._cache.length?i._cache[0].pageIndex:-1,FO=i=>i._cache.length?i._cache[i._cache.length-1].pageIndex:-1,Pm=(i,e,t)=>{i._isChangedFiring=!0,e(t),i._isChangedFiring=!1},EL=(i,e,t)=>{if(i._isDelayChanged)return i._isDelayChanged=!1,Pm(i,e,t),!0},KQ=i=>{let e=i._dataOptions.pageSize();if(i.option("scrolling.preventPreload"))return 0;let n=i._controller.viewportSize();if(i._controller.isVirtualMode()&&i.option("scrolling.removeInvisiblePages")){n=0;let o=i._controller.viewportSize()*i._controller.viewportItemSize(),s=i._controller.getContentOffset(),r=i._controller.getViewportPosition(),a=i._controller.virtualItemsCount(),l=i._dataOptions.totalItemsCount();for(let d=a.begin;d<l&&!(s>=r+o);d++){let c=i._controller.getItemSizes()[d]||i._controller.viewportItemSize();s+=c,s>=r&&n++}}return e&&n>0?Math.ceil(n/e):1},Fm=(i,e)=>{let t=i.option("scrolling.preloadEnabled"),n=KQ(i),o=i._controller.isAppendMode();return n&&(e?n=t?1:0:(t&&n++,(o||!IL(i))&&n--)),n},UQ=i=>{let e=-1,t=Rm(i),n=i._dataOptions;return t<0?e=i._pageIndex:i._cache[i._pageIndex-t]?t>=0&&i._controller.viewportSize()>=0&&(t>0&&(FO(i)+1===n.pageCount()&&i._cache.length<Fm(i)+1||i._pageIndex===t&&Fm(i,!0))&&(e=t-1),e<0&&t+i._cache.length<=i._pageIndex+Fm(i)&&(e=t+i._cache.length)):e=i._pageIndex,i._loadingPageIndexes[e]&&(e=-1),e},jQ=(i,e)=>{let t=i._dataOptions;if(e===i.pageIndex()||!t.isLoading()&&e<t.pageCount()||!t.hasKnownLastPage()&&e===t.pageCount())return t.pageIndex(e),i._loadingPageIndexes[e]=!0,P(t.load()).always(()=>{i._loadingPageIndexes[e]=!1})},wL=(i,e,t,n,o)=>{let s=i._dataOptions,r=s.items().slice(),a=$(t)?t:void 0,l=t==="prepend",d=s.viewportItems();t&&B(t)&&!i._isDelayChanged&&(a={changeType:t,items:r},o&&(a.removeCount=o.itemsCount,a.removeCount&&s.correctCount&&(a.removeCount=s.correctCount(d,a.removeCount,l))));let c=o?o.itemsLength:0;c&&s.correctCount&&(c=s.correctCount(d,c,l)),t==="append"?(d.push.apply(d,r),o&&d.splice(0,c)):l?(d.unshift.apply(d,r),o&&d.splice(-c)):i._dataOptions.viewportItems(r),s.updateLoading(),i._lastPageIndex=i.pageIndex(),i._isDelayChanged=n,n||Pm(i,e,a)},km=class{constructor(e,t){this._dataOptions=t,this._controller=e,this._pageIndex=this._lastPageIndex=t.pageIndex(),this._cache=[],this._loadingPageIndexes={}}option(){return this._controller.option.apply(this._controller,arguments)}viewportItemIndexChanged(e){let t=this._dataOptions.pageSize(),n=this._dataOptions.pageCount(),o=this._controller.isVirtualMode(),s=this._controller.isAppendMode(),r=this._dataOptions.totalItemsCount(),a;if(t&&(o||s)&&r>=0){let l=this._controller.viewportSize();if(l&&e+l>=r&&!this._controller.isVirtual())if(this._dataOptions.hasKnownLastPage()){a=n-1;let d=r%t;a>0&&d>0&&d<l&&a--}else a=n;else{a=Math.floor(e/t);let d=n-1;a=Math.max(a,0),a=Math.min(a,d)}return this.pageIndex(a),this.load()}}pageIndex(e){let t=this._controller.isVirtualMode(),n=this._controller.isAppendMode();return this.option(RO)!==!1&&(t||n)?(e!==void 0&&(this._pageIndex=e),this._pageIndex):this._dataOptions.pageIndex(e)}beginPageIndex(e){let t=Rm(this);return t<0&&(t=e!==void 0?e:this.pageIndex()),t}endPageIndex(){let e=FO(this);return e>0?e:this._lastPageIndex}pageSize(){return this._dataOptions.pageSize()}load(){let e=this._dataOptions,t,n=this._controller.isVirtualMode(),o=this._controller.isAppendMode();if(this.option(RO)!==!1&&(n||o)){let s=UQ(this);if(s>=0){let r=jQ(this,s);r&&(t=new y,r.done(()=>{let a=this._delayDeferred;a?a.done(t.resolve).fail(t.reject):t.resolve()}).fail(t.reject),e.updateLoading())}}else t=e.load();return!t&&this._lastPageIndex!==this.pageIndex()&&this._dataOptions.onChanged({changeType:"pageIndex"}),t||new y().resolve()}loadIfNeed(){let e=this._controller.isVirtualMode(),t=this._controller.isAppendMode();if((e||t)&&!this._dataOptions.isLoading()&&(!this._isChangedFiring||this._controller.isVirtual())){let n=this._controller.getViewportPosition();n>0?this._controller._setViewportPositionCore(n):this.load()}}handleDataChanged(e,t){let n=this._dataOptions,o=this._cache.length,s,r,a=this._controller.isVirtualMode(),l=this._controller.isAppendMode();if(t&&t.changes)Pm(this,e,t);else if(this.option(RO)!==!1&&(a||l)){let d=Rm(this);if(d>=0&&(a&&d+this._cache.length!==n.pageIndex()&&d-1!==n.pageIndex()&&(o=0,this._cache=[]),l)){if(n.pageIndex()===0)this._cache=[];else if(n.pageIndex()<FO(this)){Pm(this,e,{changeType:"append",items:[]});return}}let c={pageIndex:n.pageIndex(),itemsLength:n.items(!0).length,itemsCount:this.itemsCount(!0)};this.option("scrolling.removeInvisiblePages")&&a?r=this._cache.length>Math.max(Fm(this)+(this.option("scrolling.preloadEnabled")?1:0),2):EL(this,e,{isDelayed:!0});let h;d===n.pageIndex()+1?(r&&(h=this._cache.pop()),s="prepend",this._cache.unshift(c)):(r&&(h=this._cache.shift()),s="append",this._cache.push(c));let p=a&&o===0&&IL(this);wL(this,e,this._cache.length>1?s:void 0,p,h),this._delayDeferred=this.load().done(()=>{EL(this,e)&&this.load()})}else wL(this,e,t)}getDelayDeferred(){return this._delayDeferred}itemsCount(e){let t=0,n=this._controller.isVirtualMode();return!e&&n?this._cache.forEach(o=>{t+=o.itemsCount}):t=this._dataOptions.itemsCount(),t}virtualItemsCount(){let e=Rm(this);e<0&&(e=this._dataOptions.pageIndex());let t=e*this._dataOptions.pageSize(),n=this._cache.length*this._dataOptions.pageSize(),o=Math.max(0,this._dataOptions.totalItemsCount()-n-t);return{begin:t,end:o}}reset(){this._loadingPageIndexes={},this._cache=[]}};var Bm="scrolling.legacyMode",DL=i=>i.option("scrolling.mode")==="virtual"||i._isVirtual,qQ=i=>i.option("scrolling.mode")==="infinite"&&!i._isVirtual;function PO(i,e,t){let n,o=[],s=[],r=[];t=t||i;function a(h){let p=h.element?h.$element():h,g=lt.offset(p);return g?h.scrollTop()-(g.top-i.offset().top):i.offset().top}let l={on(h,p,g){h.on("scroll",g)},off(h,p,g){h.off("scroll",g)}};function d(h){let p=h.get(0).nodeName==="#document",g=h.get(0).nodeType===K().Node.ELEMENT_NODE,C=h.data("dxScrollable"),v=l;if(!C&&(C=p&&u(K())||g&&h.css("overflowY")==="auto"&&h,v=_,!C))return;let b=function(T){return function(){let R=T.scrollTop()-a(T);R=R>0?R:0,e(R)}}(C);v.on(C,"scroll",b),s.push(T=>{let R=a(C),U=C.scrollTo?"scrollTo":"scrollTop";T-R>=0&&C[U](T+R)}),o.push(C),r.push(()=>{v.off(C,"scroll",b)})}let c=h=>u(h.get(0).parentNode??h.get(0).host);for(n=t.parent();n.length;n=c(n))d(n);return{scrollTo(h){x(s,(p,g)=>{g(h)})},dispose(){x(r,(h,p)=>{p()})}}}var Ru=class{constructor(e,t,n){this._dataOptions=t,this.component=e,this._viewportSize=e.option(Bm)===!1?15:0,this._viewportItemSize=20,this._viewportItemIndex=0,this._position=0,this._isScrollingBack=!1,this._contentSize=0,this._itemSizes={},this._sizeRatio=1,this._isVirtual=n,this.positionChanged=ue(),this._dataLoader=new km(this,this._dataOptions)}getItemSizes(){return this._itemSizes}option(e,t){return this.component.option.apply(this.component,arguments)}isVirtual(){return this._isVirtual}virtualItemsCount(){if(DL(this)){let e=this._dataOptions,t=e.totalItemsCount();if(this.option(Bm)===!1&&t!==-1){let n=this.getViewportParams(),o=e.loadedOffset(),s=e.loadedItemCount(),r=Math.max(n.skip,o),a=Math.min(n.take,s),l=Math.max(t-(r+a),0);return{begin:r,end:l}}return this._dataLoader.virtualItemsCount.apply(this._dataLoader,arguments)}}getScrollingTimeout(){let e=this.option("scrolling.renderAsync"),t=0;return f(e)?e&&(t=this.option("scrolling.timeout")??0):(t=Math.min(this.option("scrolling.timeout")||0,this._dataOptions.changingDuration()),t<this.option("scrolling.renderingThreshold")&&(t=this.option("scrolling.minTimeout")||0)),t}setViewportPosition(e){let t=new y,n=this.getScrollingTimeout();return clearTimeout(this._scrollTimeoutID),n>0?this._scrollTimeoutID=setTimeout(()=>{this._setViewportPositionCore(e),t.resolve()},n):(this._setViewportPositionCore(e),t.resolve()),t.promise()}getViewportPosition(){return this._position}getItemIndexByPosition(e,t,n){e=e??this._position;let o=this.getItemSize(),s=0,r=0,a=Object.keys(this._itemSizes).concat(-1);for(let l=0;l<a.length&&s<e;l++){let d=parseInt(a[l]),c=(e-s)/o;if(d<0||r+c<d){r+=c,this._sizeRatio<1&&f(t)&&(r=t+n/this._viewportItemSize);break}else c=d-r,s+=c*o,r+=c;let h=this._itemSizes[d];s+=h,r+=s<e?1:(e-s+h)/h}return Math.round(50*r)/50}isScrollingBack(){return this._isScrollingBack}_setViewportPositionCore(e){let t=this._position||0;this._position=e,t!==this._position&&(this._isScrollingBack=this._position<t);let n=this.getItemIndexByPosition(),o=this.setViewportItemIndex(n);return this.positionChanged.fire(),o}setContentItemSizes(e){let t=this.virtualItemsCount();if(this._contentSize=e.reduce((n,o)=>n+o,0),t){e.forEach((s,r)=>{this._itemSizes[t.begin+r]=s});let n=(t.begin+t.end+this.itemsCount())*this._viewportItemSize,o=M.getContentHeightLimit(be);n>o?this._sizeRatio=o/n:this._sizeRatio=1}}getItemSize(){return this._viewportItemSize*this._sizeRatio}getItemOffset(e,t){let n=this.virtualItemsCount(),o=e;if(!n)return 0;let s=0,r=this._dataOptions.totalItemsCount();return Object.keys(this._itemSizes).forEach(a=>{o&&(t?a>=r-e:a<e)&&(s+=this._itemSizes[a],o--)}),Math.floor(s+o*this._viewportItemSize*this._sizeRatio)}getContentOffset(e){let t=e==="end",n=this.virtualItemsCount();return n?this.getItemOffset(t?n.end:n.begin,t):0}getVirtualContentSize(){return this.virtualItemsCount()?this.getContentOffset("begin")+this.getContentOffset("end")+this._contentSize:0}getViewportItemIndex(){return this._viewportItemIndex}setViewportItemIndex(e){if(this._viewportItemIndex=e,this.option(Bm)!==!1)return this._dataLoader.viewportItemIndexChanged.apply(this._dataLoader,arguments)}viewportItemSize(e){return e!==void 0&&(this._viewportItemSize=e),this._viewportItemSize}viewportSize(e){return e!==void 0&&(this._viewportSize=e),this._viewportSize}viewportHeight(e,t){let n=t??this._position,o=this.getItemIndexByPosition(n),s=this.getItemIndexByPosition(n+e,o,e);this.viewportSize(Math.ceil(s-o)),!f(t)&&this._viewportItemIndex!==o&&this._setViewportPositionCore(n)}reset(e){this._dataLoader.reset(),e||(this._itemSizes={})}subscribeToWindowScrollEvents(e){this._windowScroll=this._windowScroll||PO(e,t=>{this.viewportItemSize()&&this.setViewportPosition(t)})}dispose(){clearTimeout(this._scrollTimeoutID),this._windowScroll&&this._windowScroll.dispose(),this._windowScroll=null}scrollTo(e){this._windowScroll&&this._windowScroll.scrollTo(e)}isVirtualMode(){return DL(this)}isAppendMode(){return qQ(this)}getViewportParams(){let e=this.option("scrolling.mode")==="virtual",t=this._dataOptions.totalItemsCount(),o=this._dataOptions.hasKnownLastPage()&&this._viewportItemIndex>t?t:this._viewportItemIndex,s=this._viewportSize+o,r=this.option("scrolling.prerenderedRowChunkSize")||1,a=this.isScrollingBack(),l=this.option("scrolling.prerenderedRowCount")??1,d=a?l:0,c=a?0:l,h=Math.floor(Math.max(0,o-d)/r)*r,p=Math.ceil((s+c-h)/r)*r;if(e){let g=Math.max(0,t-h);p=Math.min(p,g)}return{skip:h,take:p}}itemsCount(){let e=0;return this.option(Bm)?e=this._dataLoader.itemsCount.apply(this._dataLoader,arguments):e=this._dataOptions.itemsCount(),e}pageIndex(){return this._dataLoader.pageIndex(...arguments)}beginPageIndex(){return this._dataLoader.beginPageIndex(...arguments)}endPageIndex(){return this._dataLoader.endPageIndex(...arguments)}pageSize(){return this._dataLoader.pageSize(...arguments)}load(){return this._dataLoader.load(...arguments)}loadIfNeed(){return this._dataLoader.loadIfNeed(...arguments)}handleDataChanged(){return this._dataLoader.handleDataChanged(...arguments)}getDelayDeferred(){return this._dataLoader.getDelayDeferred()}};var ML="dx-freespace-row";var YQ="dx-row-inserted";var Me="scrolling.legacyMode";var XQ=["beginPageIndex","endPageIndex","pageIndex"],tn=function(i){return i.option("scrolling.mode")==="virtual"},ss=function(i){return i.option("scrolling.mode")==="infinite"},wo=function(i){return tn(i)||ss(i)},TL=function(i,e,t,n){for(let o=0;o<e+1;o++){let s=i[t?i.length-1-o:o];s&&!n(s,o===e,t)&&e++}return e},Vm=function(i,e){return i.rowType==="data"&&!i.isNewRow||i.rowType==="group"&&e.isGroupItemCountable(i.data)},QQ=function(i){return i.forEach((e,t)=>{e.rowIndex=t}),i},kO=function(i){let e=i._virtualScrollController.beginPageIndex(-1);tn(i)&&(e<0||i.viewportSize()>=0&&i.getViewportItemIndex()>=0&&(e*i.pageSize()>i.getViewportItemIndex()||e*i.pageSize()+i.itemsCount()<i.getViewportItemIndex()+i.viewportSize())&&i._dataSource.isLoading()?i._isLoading||(i._isLoading=!0,i.loadingChanged.fire(!0)):i._isLoading&&(i._isLoading=!1,i.loadingChanged.fire(!1)))},en=function(i,e,t){if(i.option(Me)===!1&&XQ.includes(e)){let o=i._dataSource;return o.pageIndex.apply(o,t)}let n=i._virtualScrollController;return n[e].apply(n,t)},AL=function(i,e){let t=i.toArray().map(o=>u(o).parent(`.${e}`).get(0)).filter(o=>o);t.length&&(i=u(t));let n=e===ML?i.length-1:i.length;for(let o=0;o<n;o++)i.eq(o).remove()},RL=i=>class extends i{init(){super.init.apply(this,arguments),this._items=[],this._totalCount=-1,this._isLoaded=!0,this._loadPageCount=1,this._virtualScrollController=new Ru(this.component,this._getVirtualScrollDataOptions())}dispose(){this._virtualScrollController.dispose(),super.dispose.apply(this,arguments)}_getVirtualScrollDataOptions(){let e=this;return{pageSize:()=>e.pageSize(),totalItemsCount:()=>e.totalItemsCount(),hasKnownLastPage:()=>e.hasKnownLastPage(),pageIndex:t=>e._dataSource.pageIndex(t),isLoading:()=>e._dataSource.isLoading()&&!e.isCustomLoading(),pageCount:()=>e.pageCount(),load:()=>e._dataSource.load(),updateLoading(){kO(e)},itemsCount:()=>e.itemsCount(!0),items:()=>e._dataSource.items(),viewportItems(t){return t&&(e._items=t),e._items},onChanged(t){e.changed.fire(t)},changingDuration(){return e.isLoading()?300:e._renderTime||0}}}_handleLoadingChanged(e){if(this.option(Me)===!1){super._handleLoadingChanged.apply(this,arguments);return}(!tn(this)||this._isLoadingAll)&&(this._isLoading=e,super._handleLoadingChanged.apply(this,arguments)),e?this._startLoadTime=new Date:this._startLoadTime=void 0}_handleLoadError(){this.option(Me)!==!1&&(this._isLoading=!1,this.loadingChanged.fire(!1)),super._handleLoadError.apply(this,arguments)}_handleDataChanged(e){if(this.option(Me)===!1){this._items=this._dataSource.items().slice(),this._totalCount=this._dataSourceTotalCount(!0),super._handleDataChanged.apply(this,arguments);return}let t=super._handleDataChanged.bind(this);this._virtualScrollController.handleDataChanged(t,e)}_customizeRemoteOperations(e,t){let n=this.option(Me)===!1,o=this.option("scrolling.renderAsync");f(o)||(o=this._renderTime>=this.option("scrolling.renderingThreshold")),(tn(this)||ss(this)&&n)&&!t.reload&&(t.skip||n)&&!o&&(e.delay=void 0),super._customizeRemoteOperations.apply(this,arguments)}items(){return this._items}_dataSourceTotalCount(e){return this.option(Me)===!1&&tn(this)&&!e?this._totalCount:super._dataSourceTotalCount()}itemsCount(e){return e||this.option(Me)===!1?super.itemsCount():this._virtualScrollController.itemsCount()}load(e){return this.option(Me)===!1||e?super.load(e):this._virtualScrollController.load()}isLoading(){return this.option(Me)===!1?this._dataSource.isLoading():this._isLoading}isLoaded(){return this._dataSource.isLoaded()&&this._isLoaded}resetPagesCache(e){e||this._virtualScrollController.reset(!0),super.resetPagesCache.apply(this,arguments)}_changeRowExpandCore(){let e=super._changeRowExpandCore.apply(this,arguments);return this.option(Me)===!1||(this.resetPagesCache(),kO(this)),e}reload(){this._dataSource.pageIndex(this.pageIndex());let e=this._virtualScrollController;if(this.option(Me)!==!1&&e){let t=new y;return super.reload.apply(this,arguments).done(n=>{let o=e.getDelayDeferred();o?o.done(t.resolve).fail(t.reject):t.resolve(n)}).fail(t.reject),t}return super.reload.apply(this,arguments)}refresh(e,t){if(this.option(Me)!==!1){let{storeLoadOptions:n}=e,o=this._dataSource;t.reload?(this._virtualScrollController.reset(),o.items().length=0,this._isLoaded=!1,kO(this),this._isLoaded=!0,ss(this)?(this.pageIndex(0),o.pageIndex(0),n.pageIndex=0,e.pageIndex=0,n.skip=0):(o.pageIndex(this.pageIndex()),o.paginate()&&(e.pageIndex=this.pageIndex(),n.skip=this.pageIndex()*this.pageSize()))):ss(this)&&n.skip&&this._totalCountCorrection<0&&(n.skip+=this._totalCountCorrection)}return super.refresh.apply(this,arguments)}loadPageCount(e){if(!f(e))return this._loadPageCount;this._loadPageCount=e}_handleDataLoading(e){let t=this.loadPageCount(),n=this.pageSize(),o=this.option(Me)===!1,{storeLoadOptions:s}=e,r=f(s.take);e.loadPageCount=t,!e.isCustomLoading&&o&&r&&t>1&&n>0&&(s.take=t*n),super._handleDataLoading.apply(this,arguments)}_loadPageSize(){return super._loadPageSize.apply(this,arguments)*this.loadPageCount()}beginPageIndex(){return en(this,"beginPageIndex",[...arguments])}endPageIndex(){return en(this,"endPageIndex",[...arguments])}pageIndex(e){return en(this,"pageIndex",[...arguments])}virtualItemsCount(){return en(this,"virtualItemsCount",[...arguments])}getContentOffset(){return en(this,"getContentOffset",[...arguments])}getVirtualContentSize(){return en(this,"getVirtualContentSize",[...arguments])}setContentItemSizes(){return en(this,"setContentItemSizes",[...arguments])}setViewportPosition(){return en(this,"setViewportPosition",[...arguments])}getViewportItemIndex(){return en(this,"getViewportItemIndex",[...arguments])}setViewportItemIndex(e){return en(this,"setViewportItemIndex",[...arguments])}getItemIndexByPosition(){return en(this,"getItemIndexByPosition",[...arguments])}viewportSize(){return en(this,"viewportSize",[...arguments])}viewportItemSize(){return en(this,"viewportItemSize",[...arguments])}getItemSize(){return en(this,"getItemSize",[...arguments])}getItemSizes(){return en(this,"getItemSizes",[...arguments])}loadIfNeed(){return en(this,"loadIfNeed",[...arguments])}},ZQ=i=>class extends i{dispose(){let e=this._rowsScrollController;e&&e.dispose(),super.dispose.apply(this,arguments)}_refreshDataSource(){let e=super._refreshDataSource.apply(this,arguments)||new y().resolve().promise();return e.done(this.initVirtualRows.bind(this)),e}_loadDataSource(){if(this._rowsScrollController&&wo(this)){var e;let{loadPageCount:t}=f(this._loadViewportParams)?this.getLoadPageParams():{loadPageCount:0};t>=1&&((e=this._dataSource)===null||e===void 0||e.loadPageCount(t))}return super._loadDataSource.apply(this,arguments)}getRowPageSize(){let e=this.option("scrolling.rowPageSize"),t=this.pageSize();return t&&t<e?t:e}reload(){let e=this._rowsScrollController||this._dataSource,t=e&&e.getItemIndexByPosition(),n=super.reload.apply(this,arguments);return n&&n.done(()=>{if(tn(this)||M.isVirtualRowRendering(this)){let s=this.getRowIndexOffset(),r=Math.floor(t)-s,{component:a}=this,l=a.getScrollable&&a.getScrollable(),d=this.dataSource().operationTypes().sorting;if(l&&!d&&r>=0){var o;let c=a.getRowElement(r),h=c&&c[0]&&u(c[0]),p=h&&((o=h.position())===null||o===void 0?void 0:o.top),g=be.chrome&&Number(be.version??0)>=91,C=be.mozilla||g?1:0;p&&p>C&&(p=Math.round(p+X(h)*(t%1)),l.scrollTo({y:p}))}}})}initVirtualRows(){let e=M.isVirtualRowRendering(this);if(this._allItems=null,this._loadViewportParams=null,this.option("scrolling.mode")!=="virtual"&&!e||!e||this.option(Me)!==!1&&!this.option("scrolling.rowPageSize")){this._visibleItems=null,this._rowsScrollController=null;return}let t=!tn(this)&&this.pageIndex()>=this.pageCount()?this.pageCount()-1:this.pageIndex();this._rowPageIndex=Math.ceil(t*this.pageSize()/this.getRowPageSize()),this._visibleItems=this.option(Me)===!1?null:[],this._viewportChanging=!1,this._needUpdateViewportAfterLoading=!1,this._rowsScrollController||(this._rowsScrollController=new Ru(this.component,this._getRowsScrollDataOptions(),!0),this._rowsScrollController.positionChanged.add(()=>{var n;if(this.option(Me)===!1){this._viewportChanging=!0,this.loadViewport(),this._viewportChanging=!1;return}(n=this._dataSource)===null||n===void 0||n.setViewportItemIndex(this._rowsScrollController.getViewportItemIndex())})),this.option(Me)===!1&&this._updateLoadViewportParams(),this.isLoaded()&&this.option(Me)!==!1&&this._rowsScrollController.load()}isViewportChanging(){return this._viewportChanging}_getRowsScrollDataOptions(){let e=this,t=function(n){return Vm(n,e._dataSource)};return{pageSize:()=>e.getRowPageSize(),loadedOffset(){var n;return tn(e)&&((n=e._dataSource)===null||n===void 0?void 0:n.lastLoadOptions().skip)||0},loadedItemCount:()=>e._itemCount,totalItemsCount(){return wo(e)?e.totalItemsCount():e.option(Me)===!1?e._itemCount:e._items.filter(t).length},hasKnownLastPage:()=>e.option(Me)===!1?e.hasKnownLastPage():!0,pageIndex(n){return n!==void 0&&(e._rowPageIndex=n),e._rowPageIndex},isLoading:()=>e.isLoading(),pageCount(){return Math.ceil(this.totalItemsCount()/this.pageSize())||1},load(){e._rowsScrollController.pageIndex()>=this.pageCount()&&(e._rowPageIndex=this.pageCount()-1,e._rowsScrollController.pageIndex(e._rowPageIndex)),!(!this.items().length&&this.totalItemsCount())&&e._rowsScrollController.handleDataChanged(n=>{n=n||{},n.changeType=n.changeType||"refresh",n.items=n.items||e._visibleItems,e._visibleItems.forEach((o,s)=>{o.rowIndex=s}),e._fireChanged(n)})},updateLoading(){},itemsCount(){return this.items(!0).length},correctCount:(n,o,s)=>TL(n,o,s,(r,a,l)=>r.isNewRow?a&&!l:a&&l?!r.isNewRow:t(r)),items(n){let o=e._items;if(e.option(Me)){let s=e.dataSource(),r=s?.virtualItemsCount(),a=r?r.begin:0,l=e.getRowPageSize(),d=e._rowPageIndex*l-a,c=l;if(d<0)return[];d&&(d=this.correctCount(o,d),o=o.slice(d)),c&&(c=this.correctCount(o,c),o=o.slice(0,c))}return n?o.filter(t):o},viewportItems(n){return n&&e.option(Me)!==!1&&(e._visibleItems=n),e._visibleItems},onChanged(){},changingDuration(){let n=e.dataSource();return n!=null&&n.isLoading()&&e.option(Me)!==!1?300:n?._renderTime||0}}}_updateItemsCore(e){let t=this.getRowIndexDelta();if(super._updateItemsCore.apply(this,arguments),this.option(Me)===!1&&M.isVirtualRowRendering(this)){e.changeType==="update"&&e.rowIndices.length===0&&e.cancelEmptyChanges&&(e.cancel=!0);return}let n=this._rowsScrollController;if(n){let o=this._visibleItems,s=e.changeType==="refresh"||e.isLiveUpdate;if(e.changeType==="append"&&e.items&&!e.items.length)return;s||e.changeType==="append"||e.changeType==="prepend"?(e.cancel=!0,s&&n.reset(!0),n.load()):(e.changeType==="update"?e.rowIndices.forEach((r,a)=>{let l=e.changeTypes[a],d=e.items[a];l==="update"?o[r]=d:l==="insert"?o.splice(r,0,d):l==="remove"&&o.splice(r,1)}):(o.forEach((r,a)=>{o[a]=this._items[a+t]||o[a]}),e.items=o),QQ(o))}}_updateLoadViewportParams(){let e=this._rowsScrollController.getViewportParams(),t=this.pageSize();if(e&&!wo(this)&&t>0){let n=this.pageIndex()*t;e.skip+=n}this._loadViewportParams=e}_processItems(){let e=super._processItems.apply(this,arguments);if(this.option(Me)===!1){let t=this._dataSource,n=t?.lastLoadOptions().skip??0,o,s,r,a=!1,l=[];e.forEach(d=>{let{rowType:c}=d,h=Vm(d,t),p=c==="group"&&(o||h||s!=="group"&&n>0),g=c==="data"&&h&&(o||s!=="group");!d.isNewRow&&f(o)&&(p||g)&&!(r&&!a)&&n++,(p||g)&&(a=!0),d.isNewRow?l.push(d):(l.forEach(C=>{C.loadIndex=n}),l=[]),d.loadIndex=n,o=h,s=c,r=d.isNewRow}),l.forEach(d=>{d.loadIndex=n})}return e}_afterProcessItems(e){if(this._itemCount=e.filter(t=>Vm(t,this._dataSource)).length,f(this._loadViewportParams)){this._updateLoadViewportParams();let t=e;if(this._allItems=e,e.length){let{skipForCurrentPage:n}=this.getLoadPageParams(!0),o=e[0].loadIndex+n,{take:s}=this._loadViewportParams;t=e.filter(r=>{let a=r.isNewRow&&r.loadIndex===o&&s===0,l=r.loadIndex>=o,d=r.loadIndex<o+s||a;return l&&d})}return t}return super._afterProcessItems.apply(this,arguments)}_applyChange(e){let t=this,{items:n}=e,{changeType:o}=e,{removeCount:s}=e;if(s){let r=o==="prepend";s=TL(t._items,s,r,(a,l)=>a.rowType==="data"&&!a.isNewRow||a.rowType==="group"&&(t._dataSource.isGroupItemCountable(a.data)||l)),e.removeCount=s}switch(o){case"prepend":t._items.unshift.apply(t._items,n),s&&t._items.splice(-s);break;case"append":t._items.push.apply(t._items,n),s&&t._items.splice(0,s);break;default:super._applyChange(e)}}items(e){return e?this._allItems||this._items:this._visibleItems||this._items}getRowIndexDelta(){let e=0;if(this.option(Me)){let t=this._visibleItems;t&&t[0]&&(e=this._items.indexOf(t[0]))}return e<0?0:e}getRowIndexOffset(e,t){let n=0,o=this.dataSource(),s=this._rowsScrollController,r=this.option(Me)===!1,a=wo(this);if(s&&!e)if(r&&f(this._loadViewportParams)){let{skipForCurrentPage:d,pageIndex:c}=this.getLoadPageParams(!0),h=this.items(!0);if(n=a?c*this.pageSize():0,h.length){let p=h[0].loadIndex;n+=h.filter(g=>g.loadIndex<p+d).length}}else n=s.beginPageIndex()*s.pageSize();else if(a&&r&&o){var l;let d=o.lastLoadOptions();t&&(l=d.skips)!==null&&l!==void 0&&l.length?n=d.skips.reduce((c,h)=>c+h,0):n=d.skip??0}else tn(this)&&o&&(n=o.beginPageIndex()*o.pageSize());return n}getDataIndex(){return this.option(Me)===!1?this.getRowIndexOffset(!0,!0):super.getDataIndex.apply(this,arguments)}viewportSize(){let e=this._rowsScrollController,t=this._dataSource,n=e?.viewportSize.apply(e,arguments);return this.option(Me)===!1?n:t?.viewportSize.apply(t,arguments)}viewportHeight(e,t){var n;(n=this._rowsScrollController)===null||n===void 0||n.viewportHeight(e,t)}viewportItemSize(){let e=this._rowsScrollController,t=this._dataSource,n=e?.viewportItemSize.apply(e,arguments);return this.option(Me)===!1?n:t?.viewportItemSize.apply(t,arguments)}setViewportPosition(){let e=this._rowsScrollController,t=this._dataSource;this._isPaging=!1,e?e.setViewportPosition.apply(e,arguments):t?.setViewportPosition.apply(t,arguments)}setContentItemSizes(e){let t=this._rowsScrollController,n=this._dataSource,o=t?.setContentItemSizes(e);return this.option(Me)===!1?o:n?.setContentItemSizes(e)}getPreloadedRowCount(){let e=this.option("scrolling.preloadedRowCount"),t=this.option("scrolling.preloadEnabled");if(f(e))return e;let n=this.viewportSize();return t?2*n:n}getLoadPageParams(e){var t,n;let o=this.pageSize(),s=this._loadViewportParams,r=(t=this._dataSource)===null||t===void 0?void 0:t.lastLoadOptions(),a=r?.pageIndex||0,l=r?.take||0,d=this._rowsScrollController.isScrollingBack(),c=d?this.getPreloadedRowCount():0,h=d?0:this.getPreloadedRowCount(),p=((n=this._dataSource)===null||n===void 0?void 0:n.totalCountCorrection())||0,g=Math.max(0,s.skip-c),C=e?a:Math.floor(o?g/o:0),v=C*o,b=s.skip-v,T=s.take+b+h-p,U=Math.ceil(o?(e?l:T)/o:0);return{pageIndex:C,loadPageCount:Math.max(1,U),skipForCurrentPage:Math.max(0,b)}}_updateVisiblePageIndex(e){if(!this._rowsScrollController)return;if(f(e)){this._silentOption("paging.pageIndex",e),this.pageChanged.fire();return}let t=this._rowsScrollController.getViewportItemIndex(),n=Math.floor(t/this.pageSize());this.pageIndex()!==n&&(this._silentOption("paging.pageIndex",n),this.updateItems({changeType:"pageIndex"}))}_getChangedLoadParams(){let e=this.getLoadPageParams(!0),{pageIndex:t,loadPageCount:n}=this.getLoadPageParams(),o=this._pageIndexIsValid(t),s=null;return!this._isLoading&&o&&(t!==e.pageIndex||n!==e.loadPageCount)&&(s={pageIndex:t,loadPageCount:n}),s}_pageIndexIsValid(e){let t=!0;return(ss(this)&&this.hasKnownLastPage()||tn(this))&&(t=e*this.pageSize()<this.totalItemsCount()),t}_loadItems(e,t){let n=wo(this),o=this._dataSource,s=this._getChangedLoadParams(),r=o?.loadPageCount()??0,a=this.pageSize()*r,l=o?.pageIndex()??0,d=s?.pageIndex===l,c=ss(this)&&this.totalItemsCount()<a,h=this.option("editing.refreshMode")==="repaint",p=s?.pageIndex>l,g=!1;if(!o||n&&e&&(h&&t||p||d&&c))return g;if(n&&this._isLoading&&(this._needUpdateViewportAfterLoading=!0),n&&s){g=!0,o.pageIndex(s.pageIndex),o.loadPageCount(s.loadPageCount),this._repaintChangesOnly=!0,this._needUpdateDimensions=!0;let C=this._viewportChanging;this.load().always(()=>{this._repaintChangesOnly=void 0,this._needUpdateDimensions=void 0}).done(()=>{let v=this.pageCount()>0&&this.pageIndex()===this.pageCount()-1;(C||v)&&this._updateVisiblePageIndex(),this._needUpdateViewportAfterLoading&&(this._needUpdateViewportAfterLoading=!1,this.loadViewport({checkLoadedParamsOnly:!0}))})}return g}loadViewport(e){let{checkLoadedParamsOnly:t,checkLoading:n,viewportIsNotFilled:o}=e??{};if(wo(this)||M.isVirtualRowRendering(this)){var r;this._updateLoadViewportParams();let l=this._loadItems(n,!o),d=(r=this._dataSource)===null||r===void 0?void 0:r.isCustomLoading(),c=n&&!d&&this._isLoading;if(!(l||c||t)){var a;let p=!((a=this._editingController)!==null&&a!==void 0&&(a=a.getChanges())!==null&&a!==void 0&&a.length);this.updateItems({repaintChangesOnly:!0,needUpdateDimensions:!0,useProcessedItemsCache:p,cancelEmptyChanges:!0})}}}updateViewport(){var e;let t=this.viewportSize(),n=this.items().length,o=t>n,s=((e=this._loadViewportParams)===null||e===void 0?void 0:e.take)??0,r=this._rowsScrollController,a=r?.getViewportParams().take;(o||s<a)&&!this._isPaging&&n&&this.loadViewport({checkLoading:!0,viewportIsNotFilled:o})}loadIfNeed(){if(this.option(Me)===!1)return;let e=this._rowsScrollController;e&&e.loadIfNeed();let t=this._dataSource;return t&&t.loadIfNeed()}getItemSize(){let e=this._rowsScrollController;if(e)return e.getItemSize.apply(e,arguments);let t=this._dataSource;return t&&t.getItemSize.apply(t,arguments)}getItemSizes(){let e=this._rowsScrollController;if(e)return e.getItemSizes.apply(e,arguments);let t=this._dataSource;return t&&t.getItemSizes.apply(t,arguments)}getContentOffset(){let e=this._rowsScrollController;if(e)return e.getContentOffset.apply(e,arguments);let t=this._dataSource;return t&&t.getContentOffset.apply(t,arguments)}refresh(e){let t=this._dataSource;return t&&e&&e.load&&ss(this)&&t.resetCurrentTotalCount(),super.refresh.apply(this,arguments)}topItemIndex(){var e;return(e=this._loadViewportParams)===null||e===void 0?void 0:e.skip}bottomItemIndex(){let e=this._loadViewportParams;return e&&e.skip+e.take}virtualItemsCount(){let e=this._rowsScrollController;if(e)return e.virtualItemsCount.apply(e,arguments);let t=this._dataSource;return t?.virtualItemsCount.apply(t,arguments)}pageIndex(e){let t=wo(this),n=this._rowsScrollController;return this.option(Me)===!1&&t&&n&&e===void 0?this.option("paging.pageIndex")??0:super.pageIndex.apply(this,arguments)}_fireChanged(e){super._fireChanged.apply(this,arguments);let{operationTypes:t}=e;if(this.option(Me)===!1&&wo(this)&&t){let{fullReload:n,pageIndex:o}=t;e.isDataChanged&&!n&&o&&this._updateVisiblePageIndex(this._dataSource.pageIndex())}}_getPagingOptionValue(e){let t=super._getPagingOptionValue.apply(this,arguments);return this.option(Me)===!1&&wo(this)&&(t=this[e]()),t}isEmpty(){return this.option(Me)===!1?!this.items(!0).length:super.isEmpty.apply(this,arguments)}isLastPageLoaded(){let e=!1;if(this.option(Me)===!1&&wo(this)){let{pageIndex:t,loadPageCount:n}=this.getLoadPageParams(!0),o=this.pageCount();e=t+n>=o}else e=super.isLastPageLoaded.apply(this,arguments);return e}reset(){this._itemCount=0,this._allItems=null,super.reset.apply(this,arguments)}_applyFilter(){var e;return(e=this._dataSource)===null||e===void 0||e.loadPageCount(1),super._applyFilter.apply(this,arguments)}getVirtualContentSize(){var e;return(e=this._dataSource)===null||e===void 0?void 0:e.getVirtualContentSize.apply(this._dataSource,arguments)}setViewportItemIndex(){var e;return(e=this._dataSource)===null||e===void 0?void 0:e.setViewportItemIndex.apply(this._dataSource,arguments)}},JQ=i=>class extends i{dispose(){super.dispose.apply(this,arguments),clearTimeout(this._resizeTimeout)}_updateMasterDataGridCore(e){return P(super._updateMasterDataGridCore.apply(this,arguments)).done(t=>{let n=tn(e)&&e.option(Me)===!1;!t&&n&&e.getScrollable()&&e.updateDimensions()})}hasResizeTimeout(){return!!this._resizeTimeout}resize(){let e;if(tn(this)||M.isVirtualRowRendering(this)){clearTimeout(this._resizeTimeout),this._resizeTimeout=null;let t=new Date-this._lastTime,n=this.option("scrolling.updateTimeout");this._lastTime&&t<n?(e=new y,this._resizeTimeout=setTimeout(()=>{this._resizeTimeout=null,super.resize.apply(this).done(e.resolve).fail(e.reject),this._lastTime=new Date},n),this._lastTime=new Date):(e=super.resize.apply(this),this._dataController.isLoaded()&&(this._lastTime=new Date))}else e=super.resize.apply(this);return e}},e9=i=>class extends i{init(){var e;super.init(),this._dataController.pageChanged.add(t=>{let n=this._scrollTop;this.scrollToPage(t??this._dataController.pageIndex()),this.option(Me)===!1&&this._scrollTop===n&&this._dataController.updateViewport()}),this._dataController.dataSourceChanged.add(()=>{!this._scrollTop&&this._scrollToCurrentPageOnResize()}),(e=this._dataController.stateLoaded)===null||e===void 0||e.add(()=>{this._scrollToCurrentPageOnResize()}),this._scrollToCurrentPageOnResize()}dispose(){clearTimeout(this._scrollTimeoutID),super.dispose()}_scrollToCurrentPageOnResize(){if(this._dataController.pageIndex()>0){let e=()=>{this.resizeCompleted.remove(e),this.scrollToPage(this._dataController.pageIndex())};this.resizeCompleted.add(e)}}scrollToPage(e){let t=this._dataController?this._dataController.pageSize():0,n;if(tn(this)||ss(this)){let o=this._dataController.getItemSize(),s=this._dataController.getItemSizes(),r=e*t;n=r*o;for(let a in s)parseInt(a)<r&&(n+=s[a]-o)}else n=0;this.scrollTo({y:n,x:this._scrollLeft})}renderDelayedTemplates(){this.waitAsyncTemplates().done(()=>{this._updateContentPosition(!0)}),super.renderDelayedTemplates.apply(this,arguments)}_renderCore(e){let t=new Date,n=super._renderCore.apply(this,arguments),o=this._dataController._dataSource;if(o&&e){let s=e.items?e.items.length:20,r=this._dataController.viewportSize()||20;M.isVirtualRowRendering(this)&&s>0&&this.option(Me)!==!1?o._renderTime=(new Date-t)*r/s:o._renderTime=new Date-t}return n}_getRowElements(e){let t=super._getRowElements(e);return t&&t.not(".dx-virtual-row")}_removeRowsElements(e,t,n){let o=this._getRowElements(e).toArray();n==="append"?o=o.slice(0,t):o=o.slice(-t),o.map(s=>{let r=u(s);this._errorHandlingController&&this._errorHandlingController.removeErrorRow(r.next()),r.remove()})}_updateContent(e,t){let n,o=this._findContentElement(),s=t&&t.changeType,r=y(),a=o.children().first();return s==="append"||s==="prepend"?this.waitAsyncTemplates().done(()=>{let l=this._getBodies(e);l.length===1?this._getBodies(a)[s==="append"?"append":"prepend"](l.children()):l[s==="append"?"appendTo":"prependTo"](a),e.remove(),n=this._getFreeSpaceRowElements(a),AL(n,ML),t.removeCount&&this._removeRowsElements(a,t.removeCount,s),this._restoreErrorRow(a),r.resolve()}).fail(r.reject):super._updateContent.apply(this,arguments).done(()=>{s==="update"&&this._restoreErrorRow(a),r.resolve()}).fail(r.reject),r.promise().done(()=>{this._updateBottomLoading()})}_addVirtualRow(e,t,n,o){if(!o)return;let s=this._createEmptyRow("dx-virtual-row",t,o);s=this._wrapRowIfNeed(e,s),this._appendEmptyRow(e,s,n)}_updateContentItemSizes(){let e=this._getRowHeights(),t=this._correctRowHeights(e);this._dataController.setContentItemSizes(t)}_updateViewportSize(e,t){f(e)||(e=this._hasHeight?X(this.element()):X(K())),this._dataController.viewportHeight(e,t)}_getRowHeights(){var e,t;let n=(e=this._editingController)===null||e===void 0||(t=e.isPopupEditMode)===null||t===void 0?void 0:t.call(e),o=this._getRowElements(this._tableElement).toArray();return n&&(o=o.filter(s=>!u(s).hasClass(YQ))),o.map(s=>Ie(s).height)}_correctRowHeights(e){let t=this._dataController,n=t._dataSource,o=[],s=t.getVisibleRows(),r=0,a=!0,l=-1;for(let d=0;d<e.length;d++){let c=s[d];f(c)&&(this.option(Me)===!1?(l>=0&&l!==c.loadIndex&&(o.push(r),r=0),l=c.loadIndex):Vm(c,n)&&(a?a=!1:(o.push(r),r=0)),r+=e[d])}return r>0&&o.push(r),o}_updateContentPosition(e){let t=this._rowHeight||20;if(this._dataController.viewportItemSize(t),tn(this)||M.isVirtualRowRendering(this)){if(this._dataController.isEmpty())return;e||this._updateContentItemSizes();let o=this._dataController.getContentOffset("begin"),s=this._dataController.getContentOffset("end"),r=this.getTableElements(),a=r.children("tbody").children(".dx-virtual-row");AL(a,"dx-virtual-row"),r.each((l,d)=>{let c=l>0,h=this._isFixedTableRendering;this._isFixedTableRendering=c,this._addVirtualRow(u(d),c,"top",o),this._addVirtualRow(u(d),c,"bottom",s),this._isFixedTableRendering=h})}}_isTableLinesDisplaysCorrect(e){return e.find(".dx-column-lines").length>0===this.option("showColumnLines")}_isColumnElementsEqual(e,t){let n=e.length===t.length;return n&&x(e,(o,s)=>{if(s.style.width!==t[o].style.width)return n=!1,n}),n}_getCellClasses(e){let t=[],{cssClass:n}=e,o=e.command==="expand";return n&&t.push(n),o&&t.push(this.addWidgetPrefix("group-space")),t}_findBottomLoadPanel(e){let t=e||this.element(),n=t&&t.find(`.${this.addWidgetPrefix("bottom-load-panel")}`);if(n&&n.length)return n}_updateBottomLoading(){let e=this,t=tn(this),n=ss(this),o=!e._dataController.hasKnownLastPage()&&e._dataController.isLoaded()&&(t||n),s=e._findContentElement(),r=e._findBottomLoadPanel(s);o?r||u("<div>").addClass(e.addWidgetPrefix("bottom-load-panel")).append(e._createComponent(u("<div>"),ni,{elementAttr:{role:null,"aria-label":null}}).$element()).appendTo(s):r&&r.remove()}_handleScroll(e){let t=this.option(Me)===!0,n=e.scrollOffset.top===0,s=this._scrollTop!==e.scrollOffset.top||e.forceUpdateScrollPosition,r=this._hasHeight||!t&&n;s&&r&&this._rowHeight&&(this._scrollTop=e.scrollOffset.top,(tn(this)||this.option("scrolling.rowRenderingMode")!=="standard")&&this.option(Me)===!1&&(this._updateContentItemSizes(),this._updateViewportSize(null,this._scrollTop)),this._dataController.setViewportPosition(e.scrollOffset.top)),super._handleScroll.apply(this,arguments)}_needUpdateRowHeight(e){return super._needUpdateRowHeight.apply(this,arguments)||e>0&&ss(this)&&!M.isVirtualRowRendering(this)}_updateRowHeight(){if(super._updateRowHeight.apply(this,arguments),this._rowHeight){this._updateContentPosition();let e=this._hasHeight?X(this.element()):X(K());this.option(Me)===!1?(this._updateViewportSize(e),this._dataController.updateViewport()):this._dataController.viewportSize(Math.ceil(e/this._rowHeight))}}updateFreeSpaceRowHeight(){let e=super.updateFreeSpaceRowHeight.apply(this,arguments);return e&&this._updateContentPosition(),e}setLoading(e,t){let n=this._dataController,o=n.pageIndex()>0&&n.isLoaded()&&!!this._findBottomLoadPanel();this.option(Me)===!1&&e&&n.isViewportChanging()||(o&&(e=!1),super.setLoading.call(this,e,t))}throwHeightWarningIfNeed(){if(this._hasHeight===void 0)return;!this._hasHeight&&wo(this)&&!this._heightWarningIsThrown&&(this._heightWarningIsThrown=!0,Z.log("W1025"))}_resizeCore(){let e=this,t=e.element();super._resizeCore(),this.throwHeightWarningIfNeed(),e.component.$element()&&!e._windowScroll&&Lo(t)&&(e._windowScroll=PO(t,n=>{!e._hasHeight&&e._rowHeight&&e._dataController.setViewportPosition(n)},e.component.$element()),e.on("disposing",()=>{e._windowScroll.dispose()})),this.option(Me)!==!1&&e.loadIfNeed()}loadIfNeed(){var e,t;(e=this._dataController)===null||e===void 0||(t=e.loadIfNeed)===null||t===void 0||t.call(e)}_restoreErrorRow(e){if(this.option(Me)===!1){var t;(t=this._errorHandlingController)===null||t===void 0||t.removeErrorRow()}super._restoreErrorRow.apply(this,arguments)}},FL={defaultOptions:()=>({scrolling:{timeout:300,updateTimeout:300,minTimeout:0,renderingThreshold:100,removeInvisiblePages:!0,rowPageSize:5,prerenderedRowChunkSize:1,mode:"standard",preloadEnabled:!1,rowRenderingMode:"standard",loadTwoPagesOnStart:!1,legacyMode:!1,prerenderedRowCount:1}}),extenders:{controllers:{data:ZQ,resizing:JQ},views:{rowsView:e9}}};H.registerModule("virtualScrolling",FL);Pr.extend(RL);var xd=(i,e)=>{let t=u(K()),{top:n}=i.offset(),o;if(xe(e)){if(e<n)return n-e;o=jr(t)-e+t.scrollTop()}else{let s=n-t.scrollTop(),r=jr(t)-s-X(i);o=Math.max(s,r)}return .9*o};var BO=class extends Bg{_getDefaultOptions(){return m(super._getDefaultOptions(),{orientation:"horizontal",tabIndex:null,onHoverStart:S})}_initDataAdapter(){this._dataAdapter=this.option("_dataAdapter"),this._dataAdapter||super._initDataAdapter()}_renderContentImpl(){this._renderContextMenuOverlay(),super._renderContentImpl();let e=this._dataAdapter.getNodeByKey(this.option("_parentKey"));e&&this._renderItems(this._getChildNodes(e)),this._renderDelimiter()}_renderDelimiter(){this.$contentDelimiter=u("<div>").appendTo(this._itemContainer()).addClass("dx-context-menu-content-delimiter")}_getOverlayOptions(){return m(!0,super._getOverlayOptions(),{onPositioned:this._overlayPositionedActionHandler.bind(this),position:{precise:!0}})}_overlayPositionedActionHandler(e){this._showDelimiter(e)}_hoverEndHandler(e){super._hoverEndHandler(e),this._toggleFocusClass(!1,e.currentTarget)}_isMenuHorizontal(){return this.option("orientation")==="horizontal"}_hoverStartHandler(e){this.option("onHoverStart")(e),super._hoverStartHandler(e),this._toggleFocusClass(!0,e.currentTarget)}_drawSubmenu(e){this._actions.onShowing({rootItem:N(e),submenu:this}),super._drawSubmenu(e),this._actions.onShown({rootItem:N(e),submenu:this})}_hideSubmenu(e){this._actions.onHiding({cancel:!0,rootItem:N(e),submenu:this}),super._hideSubmenu(e),this._actions.onHidden({rootItem:N(e),submenu:this})}_showDelimiter(e){if(!this.$contentDelimiter)return;let t=this._itemContainer().children(".dx-submenu").eq(0),n=this.option("position").of.find(".dx-context-menu-container-border"),o={of:t,precise:!0},s=e.position,r=s.v.location,a=s.h.location,l=n.offset(),d=Math.round(l.left),c=Math.round(l.top),h=z(n),p=Y(n),g=z(t),C=Y(t);this.$contentDelimiter.css("display","block"),Fo(this.$contentDelimiter,this._isMenuHorizontal()?h<g?h:g:3),xi(this.$contentDelimiter,this._isMenuHorizontal()?3:p<C?p:C),this._isMenuHorizontal()?r>c?Math.round(a)===d?(o.offset="0 -2.5",o.at=o.my="left top"):(o.offset="0 -2.5",o.at=o.my="right top"):(xi(this.$contentDelimiter,5),Math.round(a)===d?(o.offset="0 5",o.at=o.my="left bottom"):(o.offset="0 5",o.at=o.my="right bottom")):a>d?Math.round(r)===c?(o.offset="-2.5 0",o.at=o.my="left top"):(o.offset="-2.5 0",o.at=o.my="left bottom"):Math.round(r)===c?(o.offset="2.5 0",o.at=o.my="right top"):(o.offset="2.5 0",o.at=o.my="right bottom"),lt.setup(this.$contentDelimiter,o)}_getContextMenuPosition(){return this.option("position")}isOverlayVisible(){return this._overlay.option("visible")}getOverlayContent(){return this._overlay.$content()}},Lm=BO;var Nm="dx-menu-adaptive-mode";var t9=`${Nm}-overlay-wrapper`;var i9={show:50,hide:300},PL=["onSubmenuShowing","onSubmenuShown","onSubmenuHiding","onSubmenuHidden","onItemContextMenu","onItemClick","onSelectionChanged","onItemRendered"],Hm=class extends Pg{_getDefaultOptions(){return m(super._getDefaultOptions(),{orientation:"horizontal",submenuDirection:"auto",showFirstSubmenuMode:{name:"onClick",delay:{show:50,hide:300}},hideSubmenuOnMouseLeave:!1,onSubmenuShowing:null,onSubmenuShown:null,onSubmenuHiding:null,onSubmenuHidden:null,adaptivityEnabled:!1})}_setOptionsByReference(){super._setOptionsByReference(),m(this._optionsByReference,{animation:!0,selectedItem:!0})}_itemElements(){let e=super._itemElements(),t=this._submenuItemElements();return e.add(t)}_submenuItemElements(){let e=[],t=this._submenus.length&&this._submenus[0];return t&&t.itemsContainer()&&(e=t.itemsContainer().find(".dx-menu-item")),e}_focusTarget(){return this.$element()}_isMenuHorizontal(){return this.option("orientation")==="horizontal"}_moveFocus(e){let t=this._getAvailableItems(),n=this._isMenuHorizontal(),o=this._getActiveItem(!0),s,r,a,l;switch(e){case"up":r=n?"showSubmenu":this._getItemsNavigationOperation("prevItem"),s=n?o:t,a=this._getKeyboardNavigationAction(r,s),l=a();break;case"down":r=n?"showSubmenu":this._getItemsNavigationOperation("nextItem"),s=n?o:t,a=this._getKeyboardNavigationAction(r,s),l=a();break;case"right":r=n?this._getItemsNavigationOperation("nextItem"):"showSubmenu",s=n?t:o,a=this._getKeyboardNavigationAction(r,s),l=a();break;case"left":r=n?this._getItemsNavigationOperation("prevItem"):"showSubmenu",s=n?t:o,a=this._getKeyboardNavigationAction(r,s),l=a();break;default:return super._moveFocus(e)}l&&l.length!==0&&this.option("focusedElement",N(l))}_getItemsNavigationOperation(e){let t=e;return this.option("rtlEnabled")&&(t=e==="prevItem"?"nextItem":"prevItem"),t}_getKeyboardNavigationAction(e,t){let n=S;switch(e){case"showSubmenu":t.hasClass("dx-state-disabled")||(n=this._showSubmenu.bind(this,t));break;case"nextItem":n=this._nextItem.bind(this,t);break;case"prevItem":n=this._prevItem.bind(this,t)}return n}_clean(){super._clean(),this.option("templatesRenderAsynchronously")&&clearTimeout(this._resizeEventTimer)}_visibilityChanged(e){e&&(this._menuItemsWidth||this._updateItemsWidthCache(),this._dimensionChanged())}_isAdaptivityEnabled(){return this.option("adaptivityEnabled")&&this.option("orientation")==="horizontal"}_updateItemsWidthCache(){let e=this.$element().find("ul").first().children("li").children(".dx-menu-item");this._menuItemsWidth=this._getSummaryItemsSize("width",e,!0)}_dimensionChanged(){if(!this._isAdaptivityEnabled())return;let e=ie(this.$element());this._toggleAdaptiveMode(this._menuItemsWidth>e)}_init(){super._init(),this._submenus=[]}_initActions(){this._actions={},x(PL,(e,t)=>{this._actions[t]=this._createActionByOption(t)})}_initMarkup(){this._visibleSubmenu=null,this.$element().addClass("dx-menu"),super._initMarkup(),this._addCustomCssClass(this.$element()),this.setAria("role","menubar")}_render(){super._render(),this._initAdaptivity()}_isTargetOutOfComponent(e){let t=u(e).closest(".dx-menu").length!==0,n=u(e).closest(".dx-context-menu").length!==0;return!(t||n)}_focusOutHandler(e){let{relatedTarget:t}=e;t&&this._isTargetOutOfComponent(t)&&this._hideVisibleSubmenu(),super._focusOutHandler(e)}_renderHamburgerButton(){return this._hamburger=new rt(u("<div>").addClass("dx-menu-hamburger-button"),{icon:"menu",activeStateEnabled:!1,onClick:this._toggleTreeView.bind(this)}),this._hamburger.$element()}_toggleTreeView(e){q(e)&&(e=!this._overlay.option("visible")),this._overlay.option("visible",e),e&&this._treeView.focus(),this._toggleHamburgerActiveState(e)}_toggleHamburgerActiveState(e){this._hamburger&&this._hamburger.$element().toggleClass("dx-state-active",e)}_toggleAdaptiveMode(e){let t=this.$element().find(".dx-menu-horizontal"),n=this.$element().find(`.${Nm}`);e?this._hideVisibleSubmenu():(this._treeView&&this._treeView.collapseAll(),this._overlay&&this._toggleTreeView(e)),t.toggle(!e),n.toggle(e)}_removeAdaptivity(){this._$adaptiveContainer&&(this._toggleAdaptiveMode(!1),this._$adaptiveContainer.remove(),this._$adaptiveContainer=null,this._treeView=null,this._hamburger=null,this._overlay=null)}_treeviewItemClickHandler(e){this._actions.onItemClick(e),e.node.children.length||this._toggleTreeView(!1)}_getAdaptiveOverlayOptions(){let t=this.option("rtlEnabled")?"right":"left";return{_ignoreFunctionValueDeprecation:!0,maxHeight:()=>xd(this.$element()),deferRendering:!1,shading:!1,animation:!1,hideOnParentScroll:!0,onHidden:()=>{this._toggleHamburgerActiveState(!1)},height:"auto",hideOnOutsideClick:n=>!u(n.target).closest(".dx-menu-hamburger-button").length,position:{collision:"flipfit",at:`bottom ${t}`,my:`top ${t}`,of:this._hamburger.$element()}}}_getTreeViewOptions(){let e={};return x(["rtlEnabled","width","accessKey","activeStateEnabled","animation","dataSource","disabled","displayExpr","displayExpr","focusStateEnabled","hint","hoverStateEnabled","itemsExpr","items","itemTemplate","selectedExpr","selectionMode","tabIndex","visible"],(t,n)=>{e[n]=this.option(n)}),x(["onItemContextMenu","onSelectionChanged","onItemRendered"],(t,n)=>{e[n]=o=>{this._actions[n](o)}}),m(e,{dataSource:this.getDataSource(),animationEnabled:!!this.option("animation"),onItemClick:this._treeviewItemClickHandler.bind(this),onItemExpanded:t=>{this._overlay.repaint(),this._actions.onSubmenuShown(t)},onItemCollapsed:t=>{this._overlay.repaint(),this._actions.onSubmenuHidden(t)},selectNodesRecursive:!1,selectByClick:this.option("selectByClick"),expandEvent:"click",_supportItemUrl:!0})}_initAdaptivity(){if(!this._isAdaptivityEnabled())return;this._$adaptiveContainer=u("<div>").addClass(Nm);let e=this._renderHamburgerButton();this._treeView=this._createComponent(u("<div>"),es,this._getTreeViewOptions()),this._overlay=this._createComponent(u("<div>"),Ni,this._getAdaptiveOverlayOptions()),this._overlay.$content().append(this._treeView.$element()).addClass(Nm).addClass(this.option("cssClass")),this._overlay.$wrapper().addClass(t9),this._$adaptiveContainer.append(e),this._$adaptiveContainer.append(this._overlay.$element()),this.$element().append(this._$adaptiveContainer),this._updateItemsWidthCache(),this._dimensionChanged()}_getDelay(e){let{delay:t}=this.option("showFirstSubmenuMode");return f(t)?$(t)?t[e]:t:i9[e]}_keyboardHandler(e){return super._keyboardHandler(e,!!this._visibleSubmenu)}_renderContainer(){let e=u("<div>");return e.appendTo(this.$element()).addClass(this._isMenuHorizontal()?"dx-menu-horizontal":"dx-menu-vertical"),super._renderContainer(e)}_renderSubmenuItems(e,t){let n=this._createSubmenu(e,t);return this._submenus.push(n),this._renderBorderElement(t),n}_getKeyboardListeners(){return super._getKeyboardListeners().concat(this._visibleSubmenu)}_createSubmenu(e,t){let n=u("<div>").addClass("dx-context-menu").appendTo(t),o=this._getChildNodes(e),s=this._createComponent(n,Lm,m(this._getSubmenuOptions(),{_dataAdapter:this._dataAdapter,_parentKey:e.internalFields.key,items:o,onHoverStart:this._clearTimeouts.bind(this),position:this.getSubmenuPosition(t)}));return this._attachSubmenuHandlers(t,s),s}_getSubmenuOptions(){let e=u("<div>"),t=this._isMenuHorizontal();return{itemTemplate:this.option("itemTemplate"),target:e,orientation:this.option("orientation"),selectionMode:this.option("selectionMode"),cssClass:this.option("cssClass"),selectByClick:this.option("selectByClick"),hoverStateEnabled:this.option("hoverStateEnabled"),activeStateEnabled:this.option("activeStateEnabled"),focusStateEnabled:this.option("focusStateEnabled"),animation:this.option("animation"),showSubmenuMode:this.option("showSubmenuMode"),displayExpr:this.option("displayExpr"),disabledExpr:this.option("disabledExpr"),selectedExpr:this.option("selectedExpr"),itemsExpr:this.option("itemsExpr"),onFocusedItemChanged:n=>{n.component.option("visible")&&this.option("focusedElement",n.component.option("focusedElement"))},onSelectionChanged:this._nestedItemOnSelectionChangedHandler.bind(this),onItemClick:this._nestedItemOnItemClickHandler.bind(this),onItemRendered:this._nestedItemOnItemRenderedHandler.bind(this),onLeftFirstItem:t?null:this._moveMainMenuFocus.bind(this,"prevItem"),onLeftLastItem:t?null:this._moveMainMenuFocus.bind(this,"nextItem"),onCloseRootSubmenu:this._moveMainMenuFocus.bind(this,t?"prevItem":null),onExpandLastSubmenu:t?this._moveMainMenuFocus.bind(this,"nextItem"):null}}_getShowFirstSubmenuMode(){if(!this._isDesktopDevice())return"onClick";let e=this.option("showFirstSubmenuMode");return $(e)?e.name:e}_moveMainMenuFocus(e){let t=this._getAvailableItems(),n=t.length,o=t.filter(".dx-menu-item-expanded").eq(0),s=t.index(o);this._hideSubmenu(this._visibleSubmenu),s+=e==="prevItem"?-1:1,s>=n?s=0:s<0&&(s=n-1);let r=t.eq(s);this.option("focusedElement",N(r))}_nestedItemOnSelectionChangedHandler(e){let t=e.addedItems.length&&e.addedItems[0],n=Lm.getInstance(e.element),{onSelectionChanged:o}=this._actions;o(e),t&&this._clearSelectionInSubmenus(t[0],n),this._clearRootSelection(),this._setOptionWithoutOptionChange("selectedItem",t)}_clearSelectionInSubmenus(e,t){let n=!arguments.length;x(this._submenus,(o,s)=>{let r=s._itemContainer(),a=!r.is(t&&t._itemContainer()),l=r.find(`.${this._selectedItemClass()}`);if(a&&l.length||n){l.removeClass(this._selectedItemClass());let d=this._getItemData(l);d&&(d.selected=!1),s._clearSelectedItems()}})}_clearRootSelection(){let e=this.$element().find(".dx-menu-items-container").first().children().children().filter(`.${this._selectedItemClass()}`);if(e.length){let t=this._getItemData(e);t.selected=!1,e.removeClass(this._selectedItemClass())}}_nestedItemOnItemClickHandler(e){this._actions.onItemClick(e)}_nestedItemOnItemRenderedHandler(e){this._actions.onItemRendered(e)}_attachSubmenuHandlers(e,t){let o=t.getOverlayContent().find(".dx-submenu"),s=D(gr,`${this.NAME}_submenu`);t.option({onShowing:this._submenuOnShowingHandler.bind(this,e,t),onShown:this._submenuOnShownHandler.bind(this,e,t),onHiding:this._submenuOnHidingHandler.bind(this,e,t),onHidden:this._submenuOnHiddenHandler.bind(this,e,t)}),x(o,(r,a)=>{_.off(a,s),_.on(a,s,null,this._submenuMouseLeaveHandler.bind(this,e))})}_submenuOnShowingHandler(e,t,n){let{rootItem:o}=n,s=e.children(".dx-context-menu-container-border"),r=this._getVisibilityChangeEventParams(o,t,e);this._actions.onSubmenuShowing(r),s.show(),e.addClass("dx-menu-item-expanded")}_submenuOnShownHandler(e,t,n){let{rootItem:o}=n,s=this._getVisibilityChangeEventParams(o,t,e);this._actions.onSubmenuShown(s)}_submenuOnHidingHandler(e,t,n){let o=e.children(".dx-context-menu-container-border"),s=this._getVisibilityChangeEventParams(n.rootItem,t,e,!0);n.itemData=s.itemData,n.rootItem=s.rootItem,n.submenuContainer=s.submenuContainer,n.submenu=s.submenu,this._actions.onSubmenuHiding(n),n.cancel||(this._visibleSubmenu===t&&(this._visibleSubmenu=null),o.hide(),e.removeClass("dx-menu-item-expanded"))}_submenuOnHiddenHandler(e,t,n){let{rootItem:o}=n,s=this._getVisibilityChangeEventParams(o,t,e,!0);this._actions.onSubmenuHidden(s)}_getVisibilityChangeEventParams(e,t,n,o){let s,r;if(e){let a=o?u(e).closest(".dx-menu-item")[0]:e;s=this._getItemData(a),r=u(a).find(".dx-submenu").first()}else{let a=u(t._overlay.content());s=this._getItemData(n),r=a.find(".dx-submenu").first()}return{itemData:s,rootItem:N(n),submenuContainer:N(r),submenu:t}}_submenuMouseLeaveHandler(e,t){let n=u(t.relatedTarget).parents(".dx-context-menu")[0],o=this._getSubmenuByRootElement(e).getOverlayContent()[0];this.option("hideSubmenuOnMouseLeave")&&n!==o&&(this._clearTimeouts(),setTimeout(this._hideSubmenuAfterTimeout.bind(this),this._getDelay("hide")))}_hideSubmenuAfterTimeout(){if(!this._visibleSubmenu)return;let e=u(this._visibleSubmenu.$element().context).hasClass("dx-state-hover"),t=this._visibleSubmenu.getOverlayContent().find(".dx-state-hover").length;!this._visibleSubmenu.getOverlayContent().get(0).querySelector(":hover")&&!t&&!e&&this._visibleSubmenu.hide()}_getSubmenuByRootElement(e){if(!e)return!1;let t=e.children(".dx-context-menu");return t.length&&Lm.getInstance(t)}getSubmenuPosition(e){let t=this._isMenuHorizontal(),n=this.option("submenuDirection").toLowerCase(),o=this.option("rtlEnabled"),s={collision:"flip",of:e,precise:!0};switch(n){case"leftortop":s.at="left top",s.my=t?"left bottom":"right top";break;case"rightorbottom":s.at=t?"left bottom":"right top",s.my="left top";break;default:t?(s.at=o?"right bottom":"left bottom",s.my=o?"right top":"left top"):(s.at=o?"left top":"right top",s.my=o?"right top":"left top")}return s}_renderBorderElement(e){u("<div>").appendTo(e).addClass("dx-context-menu-container-border").hide()}_itemPointerDownHandler(e){if(u(e.target).closest(this._itemElements()).hasClass("dx-menu-item-has-submenu")){this.option("focusedElement",null);return}super._itemPointerDownHandler(e)}_hoverStartHandler(e){let t=D(ne.move,this.NAME),n=this._getItemElementByEventArgs(e),o=this._dataAdapter.getNodeByItem(this._getItemData(n)),s=f(e.buttons)&&e.buttons===1||!f(e.buttons)&&e.which===1;if(!this._isItemDisabled(n)){if(_.off(n,t),!this._hasChildren(o)){this._showSubmenuTimer=setTimeout(this._hideSubmenuAfterTimeout.bind(this),this._getDelay("hide"));return}if(this._getShowFirstSubmenuMode()==="onHover"&&!s){let r=this._getSubmenuByElement(n);this._clearTimeouts(),r.isOverlayVisible()||(_.on(n,t,this._itemMouseMoveHandler.bind(this)),this._showSubmenuTimer=this._getDelay("hide"))}}}_hoverEndHandler(e){let t=this._getItemElementByEventArgs(e),n=u(e.relatedTarget);super._hoverEndHandler(e),this._clearTimeouts(),!this._isItemDisabled(t)&&(n.hasClass("dx-context-menu-content-delimiter")||this.option("hideSubmenuOnMouseLeave")&&!n.hasClass("dx-menu-items-container")&&(this._hideSubmenuTimer=setTimeout(()=>{this._hideSubmenuAfterTimeout()},this._getDelay("hide"))))}_hideVisibleSubmenu(){return this._visibleSubmenu?(this._hideSubmenu(this._visibleSubmenu),!0):!1}_showSubmenu(e){let t=this._getSubmenuByElement(e);this._visibleSubmenu!==t&&this._hideVisibleSubmenu(),t&&(this._clearTimeouts(),this.focus(),t.show(),this.option("focusedElement",t.option("focusedElement"))),this._visibleSubmenu=t,this._hoveredRootItem=e}_hideSubmenu(e){e&&e.hide(),this._visibleSubmenu===e&&(this._visibleSubmenu=null),this._hoveredRootItem=null}_itemMouseMoveHandler(e){if(e.pointers&&e.pointers.length)return;let t=u(e.currentTarget);f(this._showSubmenuTimer)&&(this._clearTimeouts(),this._showSubmenuTimer=setTimeout(()=>{let n=this._getSubmenuByElement(t);n&&!n.isOverlayVisible()&&this._showSubmenu(t)},this._getDelay("show")))}_clearTimeouts(){clearTimeout(this._hideSubmenuTimer),clearTimeout(this._showSubmenuTimer)}_getSubmenuByElement(e,t){let n=this._getSubmenuByRootElement(e);if(n)return n;t=t??this._getItemData(e);let o=this._dataAdapter.getNodeByItem(t);return this._hasChildren(o)&&this._renderSubmenuItems(o,e)}_updateSubmenuVisibilityOnClick(e){let t=e.args.length&&e.args[0];if(!t||this._disabledGetter(t.itemData))return;let n=u(t.itemElement),o=this._getSubmenuByElement(n,t.itemData);if(this._updateSelectedItemOnClick(e),this._visibleSubmenu){if(this._visibleSubmenu===o){this.option("showFirstSubmenuMode")==="onClick"&&this._hideSubmenu(this._visibleSubmenu);return}this._hideSubmenu(this._visibleSubmenu)}o&&(o.isOverlayVisible()||this._showSubmenu(n))}_optionChanged(e){if(PL.includes(e.name)){this._initActions();return}switch(e.name){case"orientation":case"submenuDirection":this._invalidate();break;case"showFirstSubmenuMode":case"hideSubmenuOnMouseLeave":break;case"showSubmenuMode":this._changeSubmenusOption(e.name,e.value);break;case"adaptivityEnabled":e.value?this._initAdaptivity():this._removeAdaptivity();break;case"width":this._isAdaptivityEnabled()&&(this._treeView.option(e.name,e.value),this._overlay.option(e.name,e.value)),super._optionChanged(e),this._dimensionChanged();break;case"animation":this._isAdaptivityEnabled()&&this._treeView.option("animationEnabled",!!e.value),super._optionChanged(e);break;default:this._isAdaptivityEnabled()&&(e.name===e.fullName||e.name==="items")&&this._treeView.option(e.fullName,e.value),super._optionChanged(e)}}_changeSubmenusOption(e,t){x(this._submenus,(n,o)=>{o.option(e,t)})}selectItem(e){this._hideSubmenu(this._visibleSubmenu),super.selectItem(e)}unselectItem(e){this._hideSubmenu(this._visibleSubmenu),super.unselectItem(e)}};G("dxMenu",Hm);var kL=Hm;var VO=kL;var LO={"=":"filter-operation-equals","<>":"filter-operation-not-equals","<":"filter-operation-less","<=":"filter-operation-less-equal",">":"filter-operation-greater",">=":"filter-operation-greater-equal",default:"filter-operation-default",notcontains:"filter-operation-not-contains",contains:"filter-operation-contains",startswith:"filter-operation-starts-with",endswith:"filter-operation-ends-with",between:"filter-operation-between"},BL={"=":"equal","<>":"notEqual","<":"lessThan","<=":"lessThanOrEqual",">":"greaterThan",">=":"greaterThanOrEqual",startswith:"startsWith",contains:"contains",notcontains:"notContains",endswith:"endsWith",between:"between"};var n9="dx-filter-menu";var Fu="input:not([type='hidden'])",o9=["date","datetime","number"],s9=O.format("dxDataGrid-ariaSearchBox");function vd(i){return i.option("filterRow.applyFilter")==="onClick"}var NO=function(i){let e=i&&i.children(),t=e&&e.data("dxComponents"),n=t&&t.length&&e.data(t[0]);return n instanceof oi?n:null},HO=function(i,e){let t="",n="",o=WO(i,e),s=M.getFormatOptionsByColumn(e,"filterRow");return Array.isArray(o)?(t=M.formatValue(o[0],s),n=M.formatValue(o[1],s),n!==""&&(t+=` - ${n}`)):f(o)&&(t=M.formatValue(o,s)),t};function WO(i,e){if(e)return vd(i)&&e.bufferedFilterValue!==void 0?e.bufferedFilterValue:e.filterValue}var rs=function(i,e){if(e)return vd(i)&&e.bufferedSelectedFilterOperation!==void 0?e.bufferedSelectedFilterOperation:e.selectedFilterOperation},r9=function(i,e){return e&&o9.includes(e.dataType)&&Array.isArray(i)?!1:i!==void 0},$O=function(i,e,t){let n=i._columnsController.columnOption(e),o=WO(i,n),s=t.closest(`.${i.addWidgetPrefix("filter-range-overlay")}`).length,r=t.hasClass(i.addWidgetPrefix("filter-range-start"));return o&&Array.isArray(o)&&rs(i,n)==="between"?r?o[0]:o[1]:!s&&r9(o,n)?o:null},a9=function(i,e,t,n){if(rs(i,t)==="between"){let o=WO(i,t);return n.hasClass(i.addWidgetPrefix("filter-range-start"))?[e,Array.isArray(o)?o[1]:void 0]:[Array.isArray(o)?o[0]:o,e]}return e},l9=function(i,e){let t=e.value===""?null:e.value,n=e.container,o=i._columnsController.columnOption(e.column.index),s=$O(i,o.index,n);if(!f(s)&&!f(t))return;i._applyFilterViewController.setHighLight(n,s!==t);let r=vd(i)?"bufferedFilterValue":"filterValue",a=a9(i,t,o,n),l=rs(i,o)==="between",d=e.notFireEvent||l&&Array.isArray(a)&&a.includes(void 0);i._columnsController.columnOption(o.index,r,a,d)},d9=i=>class extends i{init(){super.init(),this._applyFilterViewController=this.getController("applyFilter")}optionChanged(e){switch(e.name){case"filterRow":case"showColumnLines":this._invalidate(!0,!0),e.handled=!0;break;case"syncLookupFilterValues":e.value?this.updateLookupDataSource():this.render(),e.handled=!0;break;default:super.optionChanged(e)}}_updateEditorValue(e,t){let n=NO(t);n&&n.option("value",$O(this,e.index,t))}_columnOptionChanged(e){let t=this,{optionNames:n}=e,o,s,r,a;if(M.checkChanges(n,["filterValue","bufferedFilterValue","selectedFilterOperation","bufferedSelectedFilterOperation","filterValues","filterType"])&&e.columnIndex!==void 0){let l=t._columnsController.getVisibleIndex(e.columnIndex),d=t._columnsController.columnOption(e.columnIndex);if(o=t._getCellElement(t.element().find(`.${t.addWidgetPrefix("filter-row")}`).index(),l)??u(),s=o.find(".dx-editor-container").first(),n.filterValue||n.bufferedFilterValue){t._updateEditorValue(d,s);let c=o.find(`.${t.addWidgetPrefix("filter-range-overlay")}`).data("dxOverlay");c&&(r=c.$content().find(".dx-editor-container"),t._updateEditorValue(d,r.first()),t._updateEditorValue(d,r.last())),(!c||!c.option("visible"))&&t._updateFilterRangeContent(o,HO(t,d))}(n.selectedFilterOperation||n.bufferedSelectedFilterOperation)&&l>=0&&d&&(a=o.find(".dx-menu"),a.length&&(t._updateFilterOperationChooser(a,d,s),rs(t,d)==="between"?t._renderFilterRangeContent(o,d):s.find(".dx-filter-range-content").length&&(t._renderEditor(s,t._getEditorOptions(s,d)),t._hideFilterRange())));return}super._columnOptionChanged(e)}_renderCore(){return this._filterRangeOverlayInstance=null,super._renderCore.apply(this,arguments)}_resizeCore(){var e;super._resizeCore.apply(this,arguments),(e=this._filterRangeOverlayInstance)===null||e===void 0||e.repaint()}isFilterRowVisible(){return this._isElementVisible(this.option("filterRow"))}isVisible(){return super.isVisible()||this.isFilterRowVisible()}_initFilterRangeOverlay(e,t){let n=this,o={},s=e.find(".dx-editor-container"),r=n.addWidgetPrefix("filter-range-overlay"),a=u("<div>").addClass(r).appendTo(e);return n._createComponent(a,Ni,{height:"auto",shading:!1,showTitle:!1,focusStateEnabled:!1,hideOnOutsideClick:!0,wrapperAttr:{class:r},animation:!1,position:{my:"top",at:"top",of:s.length&&s||e,offset:"0 -1"},contentTemplate(l){let d,c=u("<div>").addClass(`dx-editor-container ${n.addWidgetPrefix("filter-range-start")}`).appendTo(l);return t=n._columnsController.columnOption(t.index),d=n._getEditorOptions(c,t),d.sharedData=o,n._renderEditor(c,d),_.on(c.find(Fu),"keydown",h=>{let p=e.find("[tabindex]").not(h.target).first();De(h)==="tab"&&h.shiftKey&&(h.preventDefault(),n._hideFilterRange(),p.length||(p=e.prev().find("[tabindex]").last()),_.trigger(p,"focus"))}),c=u("<div>").addClass(`dx-editor-container ${n.addWidgetPrefix("filter-range-end")}`).appendTo(l),d=n._getEditorOptions(c,t),d.sharedData=o,n._renderEditor(c,d),_.on(c.find(Fu),"keydown",h=>{De(h)==="tab"&&!h.shiftKey&&(h.preventDefault(),n._hideFilterRange(),_.trigger(e.next().find("[tabindex]").first(),"focus"))}),u(l).addClass(n.getWidgetContainerClass())},onShown(l){let d=l.component.$content().find(".dx-editor-container").first();_.trigger(d.find(Fu),"focus")},onHidden(){t=n._columnsController.columnOption(t.index),e.find(".dx-menu").parent().addClass("dx-editor-with-menu"),rs(n,t)==="between"&&(n._updateFilterRangeContent(e,HO(n,t)),n.component.updateDimensions())}})}_updateFilterRangeOverlay(e){let t=this._filterRangeOverlayInstance;t&&t.option(e)}_showFilterRange(e,t){let n=this,o=e.children(`.${n.addWidgetPrefix("filter-range-overlay")}`),s=o.length&&o.data("dxOverlay");!s&&t&&(s=n._initFilterRangeOverlay(e,t)),s.option("visible")||(n._filterRangeOverlayInstance&&n._filterRangeOverlayInstance.hide(),n._filterRangeOverlayInstance=s,n._updateFilterRangeOverlay({width:ie(e,!0)+1}),n._filterRangeOverlayInstance&&n._filterRangeOverlayInstance.show())}_hideFilterRange(){let e=this._filterRangeOverlayInstance;e&&e.hide()}getFilterRangeOverlayInstance(){return this._filterRangeOverlayInstance}_createRow(e){let t=super._createRow(e);return e.rowType==="filter"&&(t.addClass(this.addWidgetPrefix("filter-row")),this.option("useLegacyKeyboardNavigation")||_.on(t,"keydown",n=>nu("filterRow",this,n))),t}_getRows(){let e=super._getRows();return this.isFilterRowVisible()&&e.push({rowType:"filter"}),e}_renderFilterCell(e,t){let n=this,{column:o}=t,s=u(e);n.component.option("showColumnHeaders")&&n.setAria("describedby",o.headerId,s),n.setAria("label",O.format("dxDataGrid-ariaFilterCell"),s),s.addClass("dx-editor-cell");let r=u("<div>").appendTo(s),a=u("<div>").addClass("dx-editor-container").appendTo(r);if(rs(n,o)==="between")n._renderFilterRangeContent(s,o);else{let d=n._getEditorOptions(a,o);n._renderEditor(a,d)}let{alignment:l}=o;l&&l!=="center"&&s.find(Fu).first().css("textAlign",o.alignment),o.filterOperations&&o.filterOperations.length&&n._renderFilterOperationChooser(r,o,a)}_renderCellContent(e,t){let n=this,{column:o}=t;if(t.rowType==="filter"){if(o.command)e.html("&nbsp;");else if(o.allowFiltering){n.renderTemplate(e,n._renderFilterCell.bind(n),t).done(()=>{n._updateCell(e,t)});return}}super._renderCellContent.apply(this,arguments)}_getEditorOptions(e,t){let n=this,o={editorOptions:{inputAttr:n._getFilterInputAccessibilityAttributes(t)}},s=m(o,t,{value:$O(n,t.index,e),parentType:"filterRow",showAllText:n.option("filterRow.showAllText"),updateValueTimeout:n.option("filterRow.applyFilter")==="onClick"?0:700,width:null,setValue(r,a){l9(n,{column:t,value:r,container:e,notFireEvent:a})}});return rs(n,t)==="between"&&(e.hasClass(n.addWidgetPrefix("filter-range-start"))?s.placeholder=n.option("filterRow.betweenStartText"):s.placeholder=n.option("filterRow.betweenEndText")),s}_getFilterInputAccessibilityAttributes(e){let t=O.format("dxDataGrid-ariaFilterCell");return this.component.option("showColumnHeaders")?{"aria-label":t,"aria-describedby":e.headerId}:{"aria-label":t}}_renderEditor(e,t){e.empty();let n=u("<div>").appendTo(e),o=this._dataController.dataSource();if(t.lookup&&this.option("syncLookupFilterValues")){this._applyFilterViewController.setCurrentColumnForFiltering(t);let s=this._dataController.getCombinedFilter();this._applyFilterViewController.setCurrentColumnForFiltering(null);let r=M.getWrappedLookupDataSource(t,o,s),a=I({},t,{lookup:I({},t.lookup,{dataSource:r})});return this._editorFactoryController.createEditor(n,a)}return this._editorFactoryController.createEditor(n,t)}_renderFilterRangeContent(e,t){let n=this,o=e.find(".dx-editor-container").first();o.empty();let s=u("<div>").addClass("dx-filter-range-content").attr("tabindex",this.option("tabIndex"));_.on(s,"focusin",()=>{n._showFilterRange(e,t)}),s.appendTo(o),n._updateFilterRangeContent(e,HO(n,t))}_updateFilterRangeContent(e,t){let n=e.find(".dx-filter-range-content");n.length&&(t===""?n.html("&nbsp;"):n.text(t))}_updateFilterOperationChooser(e,t,n){let o=this,s,r=function(){let l=VO.getInstance(e);l&&l.option("focusedElement",null),s&&o._focusEditor(n)},a=this._editorFactoryController;o._createComponent(e,VO,{integrationOptions:{},activeStateEnabled:!1,selectionMode:"single",cssClass:`${o.getWidgetContainerClass()} dx-cell-focus-disabled ${n9}`,showFirstSubmenuMode:"onHover",hideSubmenuOnMouseLeave:!0,items:[{disabled:!(t.filterOperations&&t.filterOperations.length),icon:LO[rs(o,t)||"default"],selectable:!1,items:o._getFilterOperationMenuItems(t)}],onItemRendered:l=>{let{itemElement:d}=l;this.setAria("label",s9,u(d))},onItemClick(l){let d=l.itemData.name,c=rs(o,t),h=!1,p=vd(o),g={};if(!(l.itemData.items||d&&d===c)){if(d?(g[p?"bufferedSelectedFilterOperation":"selectedFilterOperation"]=d,(d==="between"||c==="between")&&(h=d==="between",g[p?"bufferedFilterValue":"filterValue"]=null)):(g[p?"bufferedFilterValue":"filterValue"]=null,g[p?"bufferedSelectedFilterOperation":"selectedFilterOperation"]=t.defaultSelectedFilterOperation||null),o._columnsController.columnOption(t.index,g),o._applyFilterViewController.setHighLight(n,!0),!d){let C=NO(n);C&&C.NAME==="dxDateBox"&&!C.option("isValid")&&(C.clear(),C.option("isValid",!0))}h?o._showFilterRange(n.closest(".dx-editor-cell"),t):o._focusEditor(n)}},onSubmenuShowing(){s=o._isEditorFocused(n),a.loseFocus()},onSubmenuHiding(){_.trigger(e,"blur"),r()},onContentReady(l){_.on(e,"blur",()=>{l.component._hideSubmenuAfterTimeout(),r()})},rtlEnabled:o.option("rtlEnabled")})}_isEditorFocused(e){return e.hasClass("dx-focused")||e.parents(".dx-focused").length}_focusEditor(e){this._editorFactoryController.focus(e),_.trigger(e.find(Fu),"focus")}_renderFilterOperationChooser(e,t,n){let o=this,s;o.option("filterRow.showOperationChooser")&&(e.addClass("dx-editor-with-menu"),s=u("<div>").prependTo(e),o._updateFilterOperationChooser(s,t,n))}_getFilterOperationMenuItems(e){let t=this,n=[{}],o=t.option("filterRow"),s=o&&o.operationDescriptions||{};if(e.filterOperations&&e.filterOperations.length){let r=e.filterOperations.filter(a=>f(BL[a]));n=He(r,a=>{let l=BL[a];return{name:a,selected:(rs(t,e)||e.defaultFilterOperation)===a,text:s[l],icon:LO[a]}}),n.push({name:null,text:o&&o.resetOperationText,icon:LO.default})}return n}_handleDataChanged(e){var t,n,o,s,r;let a=(t=this._dataController)===null||t===void 0||(n=t.dataSource)===null||n===void 0?void 0:n.call(t),l=a==null||(o=a.lastLoadOptions)===null||o===void 0?void 0:o.call(a);if(super._handleDataChanged.apply(this,arguments),(s=e.operationTypes)!==null&&s!==void 0&&s.filtering||(r=e.operationTypes)!==null&&r!==void 0&&r.fullReload){var d;this.updateLookupDataSource(((d=e.operationTypes)===null||d===void 0?void 0:d.filtering)||l?.filter)}}updateLookupDataSource(e){if(!this.option("syncLookupFilterValues")||!this.element())return;let t=this._columnsController.getVisibleColumns(),n=this._dataController.dataSource(),o=this._applyFilterViewController,s=this.element().find(`.${this.addWidgetPrefix("filter-row")}`).index();s!==-1&&t.forEach((r,a)=>{if(!r.lookup||r.calculateCellValue!==r.defaultCalculateCellValue)return;let l=this._getCellElement(s,a),d=NO(l?.find(".dx-editor-container"));if(d){o.setCurrentColumnForFiltering(r);let c=this._dataController.getCombinedFilter()||null;o.setCurrentColumnForFiltering(null);let h=d.option("dataSource");if(!e||!ve(h.__dataGridSourceFilter||null,c)){let g=M.getWrappedLookupDataSource(r,n,c);d.option("dataSource",g)}}})}},c9=i=>class extends i{skipCalculateColumnFilters(){return!1}_calculateAdditionalFilter(){if(this.skipCalculateColumnFilters())return super._calculateAdditionalFilter();let e=[super._calculateAdditionalFilter()],t=this._columnsController.getVisibleColumns(null,!0),n=this._applyFilterController;return x(t,function(){var o;let s=((o=n.getCurrentColumnForFiltering())===null||o===void 0?void 0:o.index)===this.index;if(this.allowFiltering&&this.calculateFilterExpression&&f(this.filterValue)&&!s){let r=this.createFilterExpression(this.filterValue,this.selectedFilterOperation||this.defaultFilterOperation,"filterRow");e.push(r)}}),M.combineFilters(e)}},zO=class extends Ce.ViewController{init(){this._columnsController=this.getController("columns")}_getHeaderPanel(){return this._headerPanel||(this._headerPanel=this.getView("headerPanel")),this._headerPanel}setHighLight(e,t){vd(this)&&(e&&e.toggleClass("dx-highlight-outline",t)&&e.closest(".dx-editor-cell").toggleClass("dx-filter-modified",t),this._getHeaderPanel().enableApplyButton(t))}applyFilter(){let e=this._columnsController.getColumns();this._columnsController.beginUpdate();for(let t=0;t<e.length;t++){let n=e[t];n.bufferedFilterValue!==void 0&&(this._columnsController.columnOption(t,"filterValue",n.bufferedFilterValue),n.bufferedFilterValue=void 0),n.bufferedSelectedFilterOperation!==void 0&&(this._columnsController.columnOption(t,"selectedFilterOperation",n.bufferedSelectedFilterOperation),n.bufferedSelectedFilterOperation=void 0)}this._columnsController.endUpdate(),this.removeHighLights()}removeHighLights(){if(vd(this)){let e=this.getView("columnHeadersView").element();e.find(`.${this.addWidgetPrefix("filter-row")} .dx-highlight-outline`).removeClass("dx-highlight-outline"),e.find(`.${this.addWidgetPrefix("filter-row")} .dx-filter-modified`).removeClass("dx-filter-modified"),this._getHeaderPanel().enableApplyButton(!1)}}setCurrentColumnForFiltering(e){this._currentColumn=e}getCurrentColumnForFiltering(){return this._currentColumn}},u9=i=>class extends i{_startResizing(){let e=this;if(super._startResizing.apply(e,arguments),e.isResizing()){let t=e._columnHeadersView.getFilterRangeOverlayInstance();if(t){let n=t.$element().closest("td").index();(n===e._targetPoint.columnIndex||n===e._targetPoint.columnIndex+1)&&t.$content().hide()}}}_endResizing(){let e=this,t;if(e.isResizing()){let n=e._columnHeadersView.getFilterRangeOverlayInstance();n&&(t=n.$element().closest("td"),e._columnHeadersView._updateFilterRangeOverlay({width:ie(t,!0)+1}),n.$content().show())}super._endResizing.apply(e,arguments)}},h9=i=>class extends i{updateFieldValue(e){return e.column.lookup&&(this._needUpdateLookupDataSource=!0),super.updateFieldValue.apply(this,arguments)}_afterSaveEditData(e){if(this._needUpdateLookupDataSource&&!e){var t;(t=this.getView("columnHeadersView"))===null||t===void 0||t.updateLookupDataSource()}return this._needUpdateLookupDataSource=!1,super._afterSaveEditData.apply(this,arguments)}_afterCancelEditData(){return this._needUpdateLookupDataSource=!1,super._afterCancelEditData.apply(this,arguments)}},p9=i=>class extends i{init(){super.init(),this._dataController=this.getController("data"),this._applyFilterViewController=this.getController("applyFilter")}optionChanged(e){e.name==="filterRow"?(this._invalidate(),e.handled=!0):super.optionChanged(e)}_getToolbarItems(){let e=super._getToolbarItems();return this._prepareFilterItem().concat(e)}_prepareFilterItem(){let e=this,t=[];if(e._isShowApplyFilterButton()){let n=e.option("filterRow.applyFilterText"),l={widget:"dxButton",options:{icon:"apply-filter",disabled:!e._columnsController.getColumns().filter(d=>d.bufferedFilterValue!==void 0).length,onClick:function(){e._applyFilterViewController.applyFilter()},hint:n,text:n,onInitialized:function(d){u(d.element).addClass(e._getToolbarButtonClass("dx-apply-button"))}},showText:"inMenu",name:"applyFilterButton",location:"after",locateInMenu:"auto",sortIndex:10};t.push(l)}return t}_isShowApplyFilterButton(){let e=this.option("filterRow");return!!(e!=null&&e.visible)&&e.applyFilter==="onClick"}enableApplyButton(e){this.setToolbarItemDisabled("applyFilterButton",!e)}},VL={defaultOptions:()=>({syncLookupFilterValues:!0,filterRow:{visible:!1,showOperationChooser:!0,showAllText:O.format("dxDataGrid-filterRowShowAllText"),resetOperationText:O.format("dxDataGrid-filterRowResetOperationText"),applyFilter:"auto",applyFilterText:O.format("dxDataGrid-applyFilterText"),operationDescriptions:{equal:O.format("dxDataGrid-filterRowOperationEquals"),notEqual:O.format("dxDataGrid-filterRowOperationNotEquals"),lessThan:O.format("dxDataGrid-filterRowOperationLess"),lessThanOrEqual:O.format("dxDataGrid-filterRowOperationLessOrEquals"),greaterThan:O.format("dxDataGrid-filterRowOperationGreater"),greaterThanOrEqual:O.format("dxDataGrid-filterRowOperationGreaterOrEquals"),startsWith:O.format("dxDataGrid-filterRowOperationStartsWith"),contains:O.format("dxDataGrid-filterRowOperationContains"),notContains:O.format("dxDataGrid-filterRowOperationNotContains"),endsWith:O.format("dxDataGrid-filterRowOperationEndsWith"),between:O.format("dxDataGrid-filterRowOperationBetween"),isBlank:O.format("dxFilterBuilder-filterOperationIsBlank"),isNotBlank:O.format("dxFilterBuilder-filterOperationIsNotBlank")},betweenStartText:O.format("dxDataGrid-filterRowOperationBetweenStartText"),betweenEndText:O.format("dxDataGrid-filterRowOperationBetweenEndText")}}),controllers:{applyFilter:zO},extenders:{controllers:{data:c9,columnsResizer:u9,editing:h9},views:{columnHeadersView:d9,headerPanel:p9}}};H.registerModule("filterRow",VL);bo.setEditorClass(Xn);function NL(i){i=i||[];for(let e=0;e<i.length;e++)i[e].selected=!1,NL(i[e].items)}function HL(i){let e=i.NAME==="dxTreeView"?".dx-treeview-select-all-item":".dx-list-select-all-checkbox";return i.$element().find(e).dxCheckBox("instance")}function LL(i,e){if(i.component.option("searchValue"))return;let t=HL(i.component);t&&e&&e.length&&t.option("value",void 0)}function $L(i,e,t){if(e^t){if(i.selected=!0,t&&i.items){for(let n=0;n<i.items.length;n++)if(!i.items[n].selected){i.selected=void 0;break}}}else(t||i.selected)&&(i.selected=!1,NL(i.items))}var $m=class extends Ce.View{getPopupContainer(){return this._popupContainer}getListComponent(){return this._listComponent}applyHeaderFilter(e){let t=this.getListComponent(),n=t.option("searchValue"),o=HL(t),s=!n&&!e.isFilterBuilder&&o?.option("value"),r=[],a=function(l,d,c){x(d,(h,p)=>{if(p.selected!==void 0&&!!p.selected^c){let g=t._getNode(p),v=t._hasChildren(g)&&p.items&&p.items.some(b=>b.selected);if(!n||!v){l.push(p.value);return}}p.items&&p.items.length&&a(l,p.items,c)})};s?(e.type==="tree"&&(e.filterType="exclude"),Array.isArray(e.filterValues)&&(e.filterValues=[])):e.type==="tree"&&(e.filterType&&(e.filterType="include"),a(r,t.option("items"),!1),e.filterValues=r),e.filterValues&&!e.filterValues.length&&(e.filterValues=null),e.apply(),this.hideHeaderFilterMenu()}showHeaderFilterMenu(e,t){let n=this;if(t){n._initializePopupContainer(t);let o=n.getPopupContainer();n.hideHeaderFilterMenu(),n.updatePopup(e,t),o.show()}}hideHeaderFilterMenu(){let e=this.getPopupContainer();e&&e.hide()}updatePopup(e,t){let n=this,o=this.option("showColumnLines"),s=t.alignment==="right"^!o?"left":"right";n._popupContainer.setAria({role:"dialog",label:O.format("dxDataGrid-headerFilterLabel")}),n._popupContainer&&(n._cleanPopupContent(),n._popupContainer.option("position",{my:`${s} top`,at:`${s} bottom`,of:e,collision:"fit fit"}))}_getSearchExpr(e,t){let{lookup:n}=e,{useDefaultSearchExpr:o}=e,s=t.dataSource,r=t.search.searchExpr;if(r)return r;if(o||f(s)&&!A(s))return"text";if(n)return n.displayExpr||"this";if(e.dataSource){let{group:a}=e.dataSource;if(Array.isArray(a)&&a.length>0)return a[0].selector;if(A(a)&&!e.remoteFiltering)return a}return e.dataField||e.selector}_cleanPopupContent(){this._popupContainer&&this._popupContainer.$content().empty()}_initializePopupContainer(e){let t=this,n=t.element(),o=this._normalizeHeaderFilterOptions(e),{height:s,width:r}=o,a={width:r,height:s,visible:!1,shading:!1,showTitle:!1,showCloseButton:!1,hideOnParentScroll:!1,dragEnabled:!1,hideOnOutsideClick:!0,wrapperAttr:{class:"dx-header-filter-menu"},focusStateEnabled:!1,toolbarItems:[{toolbar:"bottom",location:"after",widget:"dxButton",options:{text:o.texts.ok,onClick(){t.applyHeaderFilter(e)}}},{toolbar:"bottom",location:"after",widget:"dxButton",options:{text:o.texts.cancel,onClick(){t.hideHeaderFilterMenu()}}}],resizeEnabled:!0,onShowing(l){l.component.$content().parent().addClass("dx-dropdowneditor-overlay"),t._initializeListContainer(e,o),e.onShowing&&e.onShowing(l)},onShown(){t.getListComponent().focus()},onHidden:e.onHidden,onInitialized(l){let{component:d}=l;d.option("animation",d._getDefaultOptions().animation)}};f(t._popupContainer)?t._popupContainer.option(a):t._popupContainer=t._createComponent(n,ii,a)}_initializeListContainer(e,t){let n=this,o=n._popupContainer.$content(),s=!e.isFilterBuilder&&t.allowSelectAll,r={searchEnabled:t.search.enabled,searchTimeout:t.search.timeout,searchEditorOptions:t.search.editorOptions,searchMode:t.search.mode||"",dataSource:e.dataSource,onContentReady(){n.renderCompleted.fire()},itemTemplate(l,d,c){let h=u(c);return e.encodeHtml?h.text(l.text):h.html(l.text)}};function a(l){l.fullName==="searchValue"&&s&&n.option("headerFilter.hideSelectAllOnSearch")!==!1&&(e.type==="tree"?l.component.option("showCheckBoxesMode",l.value?"normal":"selectAll"):l.component.option("selectionMode",l.value?"multiple":"all"))}e.type==="tree"?n._listComponent=n._createComponent(u("<div>").appendTo(o),es,m(r,{showCheckBoxesMode:s?"selectAll":"normal",onOptionChanged:a,keyExpr:"id"})):n._listComponent=n._createComponent(u("<div>").appendTo(o),jo,m(r,{searchExpr:n._getSearchExpr(e,t),pageLoadMode:"scrollBottom",showSelectionControls:!0,selectionMode:s?"all":"multiple",onOptionChanged:a,onSelectionChanged(l){let d=l.component.option("items"),c=l.component.option("selectedItems");if(!l.component._selectedItemsUpdating&&!l.component.option("searchValue")&&!e.isFilterBuilder){let h=e.filterValues||[],p=e.filterType==="exclude";c.length===0&&d.length&&(h.length<=1||p&&h.length===d.length-1)?(e.filterType="include",e.filterValues=[]):c.length===d.length&&(e.filterType="exclude",e.filterValues=[])}x(d,(h,p)=>{let g=M.getIndexByKey(p,c,null)>=0;if(!!p.selected!==g){p.selected=g,e.filterValues=e.filterValues||[];let v=M.getIndexByKey(p.value,e.filterValues,null);v>=0&&e.filterValues.splice(v,1);let b=e.filterType==="exclude";g^b&&e.filterValues.push(p.value)}}),LL(l,e.filterValues)},onContentReady(l){let{component:d}=l,c=d.option("items"),h=[];x(c,function(){this.selected&&h.push(this)}),d._selectedItemsUpdating=!0,d.option("selectedItems",h),d._selectedItemsUpdating=!1,LL(l,e.filterValues)}}))}_normalizeHeaderFilterOptions(e){let t=this.option("headerFilter")||{},n=e.headerFilter||{},o={search:{enabled:t.allowSearch,timeout:t.searchTimeout}},s={search:{enabled:n.allowSearch,mode:n.searchMode,timeout:n.searchTimeout}};return m(!0,{},t,o,n,s)}_renderCore(){this.element().addClass("dx-header-filter-menu")}},Pu=function(i){return f(i.allowHeaderFiltering)?i.allowHeaderFiltering:i.allowFiltering},GO=i=>class extends i{optionChanged(e){if(e.name==="headerFilter"){let t=this.name==="columnHeadersView";this._invalidate(t,t),e.handled=!0}else super.optionChanged(e)}_applyColumnState(e){let t,{rootElement:n}=e,{column:o}=e;if(e.name==="headerFilter"){if(n.find(".dx-header-filter").remove(),Pu(o)){t=super._applyColumnState(e).toggleClass("dx-header-filter-empty",this._isHeaderFilterEmpty(o)),this.option("useLegacyKeyboardNavigation")||t.attr("tabindex",this.option("tabindex")||0);let s=O.format("dxDataGrid-headerFilterIndicatorLabel",o.caption);t.attr("aria-label",s),t.attr("aria-haspopup","dialog"),t.attr("role","button")}return t}return super._applyColumnState(e)}_isHeaderFilterEmpty(e){return!e.filterValues||!e.filterValues.length}_getIndicatorClassName(e){return e==="headerFilter"?"dx-header-filter":super._getIndicatorClassName(e)}_renderIndicator(e){let t=e.container,n=e.indicator;if(e.name==="headerFilter"){let o=this.option("rtlEnabled");if(t.children().length&&(!o&&e.columnAlignment==="right"||o&&e.columnAlignment==="left")){t.prepend(n);return}}super._renderIndicator(e)}};var g9={month:i=>de.getMonthNames()[i-1],quarter:i=>de.format(new Date(2e3,3*i-1),"quarter")};function zL(i,e,t){return e=e||[],t=t||[],i.forEach(n=>{if(f(n.key)){let o=e.length===1;if(e.push(o?n.key-1:n.key),n.items)zL(n.items,e,t);else{let s=new Date(Date.UTC.apply(Date,e));t.push(s)}e.pop()}else t.push(null)}),t}function m9(i,e){let t=zL(i),n=vt(t),o=M.getHeaderFilterGroupParameters(I({},e,{calculateCellValue:s=>s}));return qi.queryByOptions(n,{group:o}).toArray()}function f9(i){return i?.slice(-1)==="Z"||i?.slice(-3)==="'Z'"}var _9=function(i,e,t){let n=Jn.getGroupInterval(e),o=M.getFormatOptionsByColumn(e,"headerFilter");return n&&(o.groupInterval=n[t],M.isDateType(e.dataType)?o.format=g9[n[t]]:e.dataType==="number"&&(o.getDisplayFormat=function(){let s={format:e.format,target:"headerFilter"},r=M.formatValue(i,s),a=i+n[t],l=M.formatValue(a,s);return r&&l?`${r} - ${l}`:""})),o},KO=class extends Ce.ViewController{init(){this._columnsController=this.getController("columns"),this._dataController=this.getController("data"),this._headerFilterView=this.getView("headerFilterView")}_updateSelectedState(e,t){let n=e.length,o=t.filterType==="exclude";for(;n--;){let s=e[n];"items"in e[n]&&this._updateSelectedState(e[n].items,t),$L(s,M.getIndexByKey(e[n].value,t.filterValues,null)>-1,o)}}_normalizeGroupItem(e,t,n){let o,s,{path:r}=n,{valueSelector:a}=n,{displaySelector:l}=n,{column:d}=n;return a&&l?(o=a(e),s=l(e)):(o=e.key,s=o),$(e)?e=m({},e):e={},r.push(o),r.length===1?e.value=r[0]:e.value=r.join("/"),e.text=this.getHeaderItemText(s,d,t,n.headerFilterOptions),e}getHeaderItemText(e,t,n,o){let s=M.formatValue(e,_9(e,t,n));return s||(s=o.texts.emptyValue),s}_processGroupItems(e,t,n,o){let s=this,r,a,{column:l}=o,{lookup:d}=l,{level:c}=o;n=n||[],t=t||0,d&&(r=me(d.displayExpr),a=me(d.valueExpr));for(let h=0;h<e.length;h++)e[h]=s._normalizeGroupItem(e[h],t,{column:o.column,headerFilterOptions:o.headerFilterOptions,displaySelector:r,valueSelector:a,path:n}),"items"in e[h]&&(t===c||!f(e[h].value)?delete e[h].items:s._processGroupItems(e[h].items,t+1,n,o)),n.pop()}getDataSource(e){var t;let n=this._dataController.dataSource(),o=n?.remoteOperations().grouping,s=M.getHeaderFilterGroupParameters(e,o),r=(t=e.headerFilter)===null||t===void 0?void 0:t.dataSource,a=this.option("headerFilter"),l=!1,d={component:this.component};if(!n)return;if(f(r)&&!A(r))d.dataSource=Yi(r);else if(e.lookup)if(l=!0,this.option("syncLookupFilterValues")){this._currentColumn=e;let p=this._dataController.getCombinedFilter();this._currentColumn=null,d.dataSource=M.getWrappedLookupDataSource(e,n,p)}else d.dataSource=M.normalizeLookupDataSource(e.lookup);else{let p=Array.isArray(s)?s.length-1:0;this._currentColumn=e;let g=this._dataController.getCombinedFilter();this._currentColumn=null,d.dataSource={filter:g,group:s,useDefaultSearch:!0,load:C=>{let v=new y;return C.dataField=e.dataField||e.name,n.load(C).done(b=>{o&&f9(e.serializationFormat)&&p>3&&(b=m9(b,e)),h._processGroupItems(b,null,null,{level:p,column:e,headerFilterOptions:a}),v.resolve(b)}).fail(v.reject),v}}}A(r)&&r.call(e,d);let c=d.dataSource.postProcess,h=this;return d.dataSource.postProcess=function(p){let g=p;return l&&(g=g.filter(C=>C[e.lookup.valueExpr]!==null),this.pageIndex()===0&&!this.searchValue()&&(g=g.slice(0),g.unshift(null)),h._processGroupItems(g,null,null,{level:0,column:e,headerFilterOptions:a})),g=c&&c.call(this,g)||g,h._updateSelectedState(g,e),g},d.dataSource}getCurrentColumn(){return this._currentColumn}showHeaderFilterMenu(e,t){let n=this._columnsController,o=m(!0,{},this._columnsController.getColumns()[e]);if(o){let s=n.getVisibleIndex(e),a=(t?this.getView("headerPanel"):this.getView("columnHeadersView")).getColumnElements().eq(t?o.groupIndex:s);this.showHeaderFilterMenuBase({columnElement:a,column:o,applyFilter:!0,apply(){n.columnOption(e,{filterValues:this.filterValues,filterType:this.filterType})}})}}showHeaderFilterMenuBase(e){let t=this,{column:n}=e;if(n){let o=Jn.getGroupInterval(n),s=t._dataController.dataSource(),r=s&&s.remoteOperations().filtering,a=e.onHidden;m(e,n,{type:o&&o.length>1?"tree":"list",remoteFiltering:r,onShowing:l=>{let d=l.component.$overlayContent().dxResizable("instance");d&&d.option("onResizeEnd",c=>{let h=this._columnsController.columnOption(e.dataField,"headerFilter");h=h||{},h.width=c.width,h.height=c.height,this._columnsController.columnOption(e.dataField,"headerFilter",h,!0)})},onHidden:()=>{a?.(),nd(this)}}),e.dataSource=t.getDataSource(e),e.isFilterBuilder&&(e.dataSource.filter=null,e.alignment="right"),t._headerFilterView.showHeaderFilterMenu(e.columnElement,e)}}hideHeaderFilterMenu(){this._headerFilterView.hideHeaderFilterMenu()}},C9=i=>class extends GO(i){_renderCellContent(e,t){let n=this,o,{column:s}=t;!s.command&&Pu(s)&&n.option("headerFilter.visible")&&t.rowType==="header"&&(o=n._applyColumnState({name:"headerFilter",rootElement:e,column:s,showColumnLines:n.option("showColumnLines")}),o&&n._subscribeToIndicatorEvent(o,s,"headerFilter")),super._renderCellContent.apply(this,arguments)}_subscribeToIndicatorEvent(e,t,n){n==="headerFilter"&&_.on(e,oe,this.createAction(o=>{o.event.stopPropagation(),wb(e,this),this._headerFilterController.showHeaderFilterMenu(t.index,!1)}))}_updateIndicator(e,t,n){let o=super._updateIndicator(e,t,n);o&&this._subscribeToIndicatorEvent(o,t,n)}_updateHeaderFilterIndicators(){this.option("headerFilter.visible")&&this._updateIndicators("headerFilter")}_needUpdateFilterIndicators(){return!0}_columnOptionChanged(e){let{optionNames:t}=e,n=M.checkChanges(t,["filterValues","filterValue"]),o=M.checkChanges(t,["filterValues","filterType"]);(n||o)&&this._needUpdateFilterIndicators()&&this._updateHeaderFilterIndicators(),o||super._columnOptionChanged(e)}},x9=i=>class extends GO(i){_createGroupPanelItem(e,t){let n=this,o=super._createGroupPanelItem.apply(n,arguments),s;return!t.command&&Pu(t)&&n.option("headerFilter.visible")&&(s=n._applyColumnState({name:"headerFilter",rootElement:o,column:{alignment:Ui(n.option("rtlEnabled")),filterValues:t.filterValues,allowHeaderFiltering:!0,caption:t.caption},showColumnLines:!0}),s&&_.on(s,oe,n.createAction(r=>{let{event:a}=r;a.stopPropagation(),this._headerFilterController.showHeaderFilterMenu(t.index,!0)}))),o}};var v9=i=>class extends i{skipCalculateColumnFilters(){return!1}_calculateAdditionalFilter(){if(this.skipCalculateColumnFilters())return super._calculateAdditionalFilter();let e=[super._calculateAdditionalFilter()],t=this._columnsController.getVisibleColumns(null,!0),o=this._headerFilterController.getCurrentColumn();return x(t,(s,r)=>{let a;if(!(o&&o.index===r.index)&&Pu(r)&&r.calculateFilterExpression&&Array.isArray(r.filterValues)&&r.filterValues.length){let l=[];x(r.filterValues,(d,c)=>{Array.isArray(c)?a=c:(r.deserializeValue&&!M.isDateType(r.dataType)&&r.dataType!=="number"&&(c=r.deserializeValue(c)),a=r.createFilterExpression(c,"=","headerFilter")),a&&(a.columnIndex=r.index),l.push(a)}),l=M.combineFilters(l,"or"),e.push(r.filterType==="exclude"?["!",l]:l)}}),M.combineFilters(e)}},WL={defaultOptions:()=>({syncLookupFilterValues:!0,headerFilter:{visible:!1,width:252,height:325,allowSelectAll:!0,search:{enabled:!1,timeout:500,mode:"contains",editorOptions:{}},texts:{emptyValue:O.format("dxDataGrid-headerFilterEmptyValue"),ok:O.format("dxDataGrid-headerFilterOK"),cancel:O.format("dxDataGrid-headerFilterCancel")}}}),controllers:{headerFilter:KO},views:{headerFilterView:$m},extenders:{controllers:{data:v9},views:{columnHeadersView:C9,headerPanel:x9}}};H.registerModule("headerFilter",WL);var zm="dx-filterbuilder-range",b9=`${zm}-start`,y9=`${zm}-end`,O9=`${zm}-separator`,GL="\u2013";function S9(i,e){let t=u("<div>").addClass(b9),n=u("<div>").addClass(y9),o=i.value||[],s=function(a){return a&&a.length>0?a[0]:null},r=function(a){return a&&a.length===2?a[1]:null};e.append(t),e.append(u("<span>").addClass(O9).text(GL)),e.append(n),e.addClass(zm),this._editorFactory.createEditor.call(this,t,m({},i.field,i,{value:s(o),parentType:"filterBuilder",setValue(a){o=[a,r(o)],i.setValue(o)}})),this._editorFactory.createEditor.call(this,n,m({},i.field,i,{value:r(o),parentType:"filterBuilder",setValue(a){o=[s(o),a],i.setValue(o)}}))}function UO(i,e){return{name:"between",caption:i,icon:"range",valueSeparator:GL,dataTypes:["number","date","datetime"],editorTemplate:S9.bind(e),notForLookup:!0}}var E9={"=":"equal","<>":"notequal","<":"less","<=":"lessorequal",">":"greater",">=":"greaterorequal",notcontains:"doesnotcontain",contains:"contains",startswith:"startswith",endswith:"endswith",isblank:"isblank",isnotblank:"isnotblank"},w9={"=":"equal","<>":"notEqual","<":"lessThan","<=":"lessThanOrEqual",">":"greaterThan",">=":"greaterThanOrEqual",startswith:"startsWith",contains:"contains",notcontains:"notContains",endswith:"endsWith",isblank:"isBlank",isnotblank:"isNotBlank",between:"between"},jO={getIconByFilterOperation:i=>E9[i],getNameByFilterOperation:i=>w9[i]};var QO="string";var Nr="and",ZO="=",I9="<>",D9={number:["=","<>","<",">","<=",">=","isblank","isnotblank"],string:["contains","notcontains","startswith","endswith","=","<>","isblank","isnotblank"],date:["=","<>","<",">","<=",">=","isblank","isnotblank"],datetime:["=","<>","<",">","<=",">=","isblank","isnotblank"],boolean:["=","<>","isblank","isnotblank"],object:["isblank","isnotblank"]},T9={date:"shortDate",datetime:"shortDateShortTime"},A9=["=","<>","isblank","isnotblank"],M9=["caption","customizeText","dataField","dataType","editorTemplate","falseText","editorOptions","filterOperations","format","lookup","trueText","calculateFilterExpression","name"];function R9(i,e){let t=i.format||T9[i.dataType];return Ig.format(e,t)}function Da(i){return i&&i.length>1&&i[0]==="!"&&!Qt(i)}function Us(i){return Da(i)?i[1]:i}function F9(i,e){return Da(i)?i[1]=e:i=e,i}function P9(i,e){(function(t){return t.indexOf("!")!==-1})(e)?Da(i)||function(t){let n=t.slice(0);t.length=0,t.push("!",n)}(i):Da(i)&&function(t){let n=Us(t);t.length=0,[].push.apply(t,n)}(i)}function qL(i,e){P9(i,e);let t=Us(i),n;return e=function(o){return o.indexOf("!")===-1?o:o.substring(1)}(e),function(o,s){for(n=0;n<o.length;n++)Array.isArray(o[n])||(o[n]=s)}(t,e),i}function YL(i,e){let t=js(i);return e.filter(n=>n.value===t)[0]}function XL(i){if(Qt(i))return Nr;let e="";for(let t=0;t<i.length;t++){let n=i[t];if(!Array.isArray(n)){if(e&&e!==n)throw new st.Error("E4019");n!=="!"&&(e=n)}}return e}function js(i){let e=Us(i),t=XL(e);return t||(t=Nr),e!==i&&(t=`!${t}`),t}function k9(i){return i.lookup&&A9||D9[i.dataType||QO]}function B9(i){return Array.isArray(i)&&i.length}function QL(i){let e=B9(i.filterOperations)?i.filterOperations:k9(i);return m([],e)}function Gm(i,e){let t=jO.getNameByFilterOperation(i);return e&&e[t]?e[t]:t}function ZL(i,e){for(let t=0;t<e.length;t++)if(e[t].value===i)return e[t];throw new Z.Error("E1048",i)}function Io(i,e){let t=i.filter(n=>n.name===e);return t.length?t[0]:null}function JL(i,e,t){let n=QL(i),o=!!i.lookup;return t.forEach(s=>{if(!i.filterOperations&&n.indexOf(s.name)===-1){let r=s&&s.dataTypes;!(o?!!s.notForLookup:!1)&&r&&r.indexOf(i.dataType||QO)>=0&&n.push(s.name)}}),n.map(s=>{let r=Io(t,s);return r?{icon:r.icon||"icon-none",text:r.caption||kn(r.name),value:r.name,isCustom:!0}:{icon:jO.getIconByFilterOperation(s)||"icon-none",text:Gm(s,e),value:s}})}function Bu(i){return i.defaultFilterOperation||QL(i)[0]}function eN(i,e){let t=[i.dataField,"",""],n=Bu(i);return Ym(t,n,e),t}function Km(i,e){let t=Us(i),n=t.indexOf(e);return t.splice(n,1),t.length!==1&&t.splice(n,1),i}function JO(i){let e=eS(i),t=e?tS(i):i;return e?["!",[t]]:[t]}function bd(i,e){let t=Us(e),n=js(t);return t.length===1?t.unshift(i):t.push(i,n),e}function yd(i,e){for(let n=0;n<e.length;n++)if(e[n].name===i||e[n].dataField.toLowerCase()===i.toLowerCase())return e[n];let t=iS(e,!0).filter(n=>n.dataField.toLowerCase()===i.toLowerCase());if(t.length>0)return t[0];throw new Z.Error("E1047",i)}function Do(i){return Array.isArray(i)?i.length<2||Array.isArray(i[0])||Array.isArray(i[1]):!1}function Qt(i){return Array.isArray(i)?i.length>1&&!Array.isArray(i[0])&&!Array.isArray(i[1]):!1}function KL(i,e,t){t=t||Nr;let n=XL(i).toLowerCase()||t,o=[];for(let s=0;s<i.length;s++)Do(i[s])?(o.push(Um(i[s],e,t)),o=YO(o,n)):Qt(i[s])&&(o.push(Wm(i[s],e)),o=YO(o,n));return o.length===0&&(o=YO(o,n)),o}function V9(i,e){let t=Io(e,i[1]);return t&&t.name===i[1]}function Wm(i,e){return V9(i,e)||i.length<3&&(i[2]=i[1],i[1]=ZO),i}function eS(i){return i.indexOf("not")!==-1}function tS(i){return i.substring(3).toLowerCase()}function qO(i,e){let t=eS(e);return e=t?tS(e):e,t?["!",i,e]:[i,e]}function YO(i,e){let t=eS(e);e=t?tS(e):e,i.push(e);let n=i;return t&&(n=["!",n]),n}function Um(i,e,t){return t=t||Nr,i?(i=m(!0,[],i),Qt(i)?qO(Wm(i,e),t):Da(i)?["!",Qt(i[1])?qO(Wm(i[1],e),t):Da(i[1])?qO(Um(i[1],e),t):KL(i[1],e,t)]:KL(i,e,t)):JO(t)}function tN(i){return i.reduce((e,t)=>{if(f(t.dataField)){let n={};for(let o in t)t[o]&&M9.includes(o)&&(n[o]=t[o]);n.defaultCalculateFilterExpression=Jn.defaultCalculateFilterExpression,f(n.dataType)||(n.dataType=QO),f(n.trueText)||(n.trueText=O.format("dxDataGrid-trueText")),f(n.falseText)||(n.falseText=O.format("dxDataGrid-falseText")),e.push(n)}return e},[])}function UL(i,e,t,n){let o=yd(i[0],e),s=Wm(i,t),r=t.length&&Io(t,s[1]);return r&&r.calculateFilterExpression?r.calculateFilterExpression.apply(r,[s[2],o,e]):o.createFilterExpression?o.createFilterExpression.apply(o,[s[2],s[1],n]):o.calculateFilterExpression?o.calculateFilterExpression.apply(o,[s[2],s[1],n]):o.defaultCalculateFilterExpression.apply(o,[s[2],s[1],n])}function Ks(i,e,t,n){if(!f(i))return null;if(Da(i))return["!",Ks(i[1],e,t,n)];let o=Us(i);if(Qt(o))return UL(o,e,t,n)||null;let s=[],r,a=js(o);for(let l=0;l<o.length;l++)Do(o[l])?(r=Ks(o[l],e,t,n),r&&(l&&s.push(a),s.push(r))):Qt(o[l])&&(r=UL(o[l],e,t,n),r&&(s.length&&s.push(a),s.push(r)));return s.length===1&&(s=s[0]),s.length?s:null}function Ta(i){let e=Us(i),t;if(e.length===0)return null;let n=[];for(t=0;t<e.length;t++)if(Do(e[t])){let o=Ta(e[t]);o?e[t]=o:n.push(e[t])}else Qt(e[t])&&(N9(e[t])||n.push(e[t]));for(t=0;t<n.length;t++)Km(e,n[t]);return e.length===1||(e.splice(e.length-1,1),e.length===1&&(i=F9(i,e[0])),i.length===0)?null:i}function jm(i,e,t){if(e===""){t("");return}let{lookup:n}=i;if(n.items)t(n.calculateCellValue(e)||"");else{let o=A(n.dataSource)?n.dataSource({}):n.dataSource;new jt(o).loadSingle(n.valueExpr,e).done(r=>{let a="";r&&(a=n.displayExpr?me(n.displayExpr)(r):r),i.customizeText&&(a=i.customizeText({value:e,valueText:a})),t(a)}).fail(()=>{t("")})}}function iN(i,e,t,n,o){let s;return e===!0?s=i.trueText||O.format("dxDataGrid-trueText"):e===!1?s=i.falseText||O.format("dxDataGrid-falseText"):s=R9(i,e),i.customizeText&&(s=i.customizeText.call(i,{value:e,valueText:s,target:n})),t&&t.customizeText&&(s=t.customizeText.call(t,{value:e,valueText:s,field:i,target:n},o)),s}function L9(i,e,t,n){let o={values:e};return e.map(s=>iN(i,s,t,n,o))}function XO(i){return i===""||i===null}function qm(i,e,t){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"filterBuilder";if(XO(e))return"";if(Array.isArray(e)){let o=new y;return P.apply(this,L9(i,e,t,n)).done(function(){for(var s=arguments.length,r=new Array(s),a=0;a<s;a++)r[a]=arguments[a];let l=r.some(d=>!XO(d))?r.map(d=>XO(d)?"?":d):"";o.resolve(l)}),o}return iN(i,e,t,n)}function jL(i,e){return i.some(t=>t.dataField===e)}function nN(i,e,t){let{dataField:n}=t;nS(n)&&(t.parentId=sN(n),!jL(e,t.parentId)&&!jL(i,t.parentId)&&nN(i,e,{id:t.parentId,dataType:"object",dataField:t.parentId,caption:oN(t.parentId,!0),filterOperations:["isblank","isnotblank"],defaultCalculateFilterExpression:Jn.defaultCalculateFilterExpression})),e.push(t)}function oN(i,e){let t="";if(e)i=i.substring(i.lastIndexOf(".")+1);else if(nS(i))return i.split(".").forEach((n,o,s)=>{t+=kn(n),o!==s.length-1&&(t+=".")}),t;return kn(i)}function iS(i,e){let t=[];for(let n=0;n<i.length;n++){let o=m(!0,{caption:oN(i[n].dataField,e)},i[n]);o.id=o.name||o.dataField,e?nN(i,t,o):t.push(o)}return t}function nS(i){return i.lastIndexOf(".")!==-1}function sN(i){return i.substring(0,i.lastIndexOf("."))}function oS(i,e){if(nS(i.dataField)){let t=sN(i.dataField);for(let n=0;n<e.length;n++)if(e[n].dataField===t)return`${oS(e[n],e)}.${i.caption}`}return i.caption}function Ym(i,e,t){let n=Io(t,e);return n?(n.hasValue===!1?(i[1]=e,i.length=2):(i[1]=e,i[2]=""),i):(e==="isblank"?(i[1]=ZO,i[2]=null):e==="isnotblank"?(i[1]=I9,i[2]=null):(n=Io(t,i[1]),(n||i.length===2||i[2]===null)&&(i[2]=""),i[1]=e),i)}function sS(i){let e;return i[2]===null?i[1]===ZO?e="isblank":e="isnotblank":e=i[1],e}function N9(i){return i[2]!==""}function rN(i,e,t){let n=m(!0,[],i),o=-1;return n.some((s,r)=>{if(s.name==="between")return o=r,!0}),o!==-1?n[o]=m(UO(e,t),n[o]):n.unshift(UO(e,t)),n}function ku(i,e){return i[0]===e}function Xm(i,e){return!i||i.length===0?null:Qt(i)?ku(i,e)?null:i:aN(i,[e],!1)}function aN(i,e,t){let n=[];return i.forEach(o=>{Qt(o)?ku(o,e[0])?t?(n.push(e),t=!1):n.splice(n.length-1,1):n.push(o):(n.length||Do(o))&&n.push(o)}),n.length===0?null:(t&&(n.push(Nr),n.push(e)),n.length===1?n[0]:n)}function rS(i,e){return i===null||i.length===0?e:Qt(i)?ku(i,e[0])?e:[i,Nr,e]:js(i)!==Nr?[e,"and",i]:aN(i,e,!0)}function lN(i,e){return i===null||i.length===0?[]:Qt(i)?ku(i,e)?[i]:[]:js(i)!==Nr?[]:i.filter(o=>Qt(o)&&ku(o,e))}function aS(i,e){return i===null||i.length===0?!1:Qt(i)?i[0]===e:i.some(t=>(Qt(t)||Do(t))&&aS(t,e))}var Vu=function(i,e,t){if(Array.isArray(e)){let n=e.length-1;i.empty(),e.forEach((o,s)=>{u("<span>").addClass("dx-filterbuilder-text-part").text(o).appendTo(i),s!==n&&u("<span>").addClass("dx-filterbuilder-text-separator").text(t&&t.valueSeparator?t.valueSeparator:"|").addClass("dx-filterbuilder-text-separator-empty").appendTo(i)})}else e?i.text(e):i.text(O.format("dxFilterBuilder-enterValueText"))};function dN(i){let e=function(o,s){return s?`${s}/${o}`:o},t=function(o,s){let r=[];return o.forEach(a=>{if(a.items){let l=t(a.items,e(a.text,s));r=r.concat(l)}a.selected&&r.push(e(a.text,s))}),r},n=i&&i.getController("headerFilter");return{dataTypes:["string","date","datetime","number","boolean","object"],calculateFilterExpression:function(o,s,r){let a=[],l=o.length-1;return o&&o.forEach((d,c)=>{if(Qt(d)||Do(d)){let h=Ks(d,r,[],"headerFilter");a.push(h)}else{let h=Ks([s.dataField,"=",d],r,[],"headerFilter");a.push(h)}c!==l&&a.push("or")}),a.length===1?a[0]:a},editorTemplate(o,s){let r=u("<div>").addClass("dx-filterbuilder-item-value-text").appendTo(s),a=m(!0,{},i.columnOption(o.field.dataField));return Vu(r,o.text&&o.text.split("|")),a.filterType="include",a.filterValues=o.value?o.value.slice():[],n.showHeaderFilterMenuBase({columnElement:r,column:a,apply(){l=this.filterValues,o.setValue(l);var l;n.hideHeaderFilterMenu(),o.closeEditor()},onHidden(){o.closeEditor()},isFilterBuilder:!0}),s},customizeText:function(o,s){s=s||{};let{value:r}=o,a=i.columnOption(o.field.dataField),l=a&&a.headerFilter,d=a&&a.lookup,c=s.values||[r];if(l&&l.dataSource||d&&d.dataSource){let p=new y,g=s.items||new y;if(!s.items){a=m({},a,{filterType:"include",filterValues:c});let C=n.getDataSource(a);C.paginate=!1;let v=new jt(C),b=v.store().key();if(b){let{values:T}=s;if(T&&T.length>1){let R=T.reduce((U,Q)=>(U.length&&U.push("or"),U.push([b,"=",Q]),U),[]);v.filter(R)}else v.filter([b,"=",o.value])}else o.field.calculateDisplayValue&&Z.log("W1017");s.items=g,v.load().done(g.resolve)}return g.done(C=>{let v=c.indexOf(o.value);p.resolve(t(C,null)[v])}),p}return n.getHeaderItemText(r,a,0,i.option("headerFilter"))}}}function cN(i){return m(dN(i),{name:"anyof",icon:"selectall",caption:O.format("dxFilterBuilder-filterOperationAnyOf")})}function uN(i){let e=dN(i);return m({},e,{calculateFilterExpression(t,n,o){let s=e.calculateFilterExpression(t,n,o);return!s||s.length===0?null:s[0]==="!"?s:["!",s]},name:"noneof",icon:"unselectall",caption:O.format("dxFilterBuilder-filterOperationNoneOf")})}var H9=["=","<>","<","<=",">",">=","notcontains","contains","startswith","endswith","between"];function as(i){return i.name||i.dataField}function $9(i){i.forEach(e=>{let t=as(e);if(!f(t)&&e.allowFiltering)throw new Z.Error("E1049",e.caption)})}var lS=function(){return{filterType:"include",filterValues:void 0}},fN=function(i){let e=i.filterValues||[];return!Jn.getGroupInterval(i)&&!(i.headerFilter&&i.headerFilter.dataSource)||e.length===1&&e[0]===null},z9=function(i,e){if(!i)return lS();let t,n=i[1],o=i[2],s=Array.isArray(o);if(!s&&!fN(e))return lS();switch(n){case"anyof":case"=":t="include";break;case"noneof":case"<>":t="exclude";break;default:return lS()}return{filterType:t,filterValues:s?o:[o]}},hN=function(i){let e=i.filterValue;if(f(e)){let t=i.selectedFilterOperation||i.defaultFilterOperation||Bu(i);return[as(i),t,i.filterValue]}return null},pN=function(i){let e,t,{filterValues:n}=i;return n?(n.length===1&&fN(i)&&!Array.isArray(n[0])?(i.filterType==="exclude"?e="<>":e="=",t=n[0]):(i.filterType==="exclude"?e="noneof":e="anyof",t=n),[as(i),e,t]):null},gN=function(i,e,t){let n=z9(t,e);i.columnOption(as(e),n)},mN=function(i,e,t){let n,o=t?.[1],s=t?.[2],r=e.filterOperations||e.defaultFilterOperations,a=!r||r.indexOf(o)>=0,l=o===e.defaultFilterOperation,d=H9.includes(o);(a||l)&&d&&(s!==null&&s!=="")?(l&&!f(e.selectedFilterOperation)&&(o=e.selectedFilterOperation),n={filterValue:s,selectedFilterOperation:o}):n={filterValue:void 0,selectedFilterOperation:void 0},i.columnOption(as(e),n)},dS=class extends Ce.Controller{init(){this._dataController=this.getController("data"),this._columnsController=this.getController("columns"),this._dataController.isFilterSyncActive()&&(this._columnsController.isAllDataTypesDefined()?this._initSync():this._dataController.dataSourceChanged.add(()=>this._initSync()))}publicMethods(){return["getCustomFilterOperations"]}syncFilterValue(){let e=this,t=this._columnsController.getFilteringColumns();this._skipSyncColumnOptions=!0,t.forEach(n=>{let o=lN(e.option("filterValue"),as(n));if(o.length===1){let s=o[0];gN(this._columnsController,n,s),mN(this._columnsController,n,s)}else f(n.filterValues)&&gN(this._columnsController,n,null),f(n.filterValue)&&mN(this._columnsController,n,null)}),this._skipSyncColumnOptions=!1}_initSync(){let e=this._columnsController.getColumns(),t=this._dataController.pageIndex();if($9(e),!this.option("filterValue")){let n=this._columnsController.getFilteringColumns(),o=this.getFilterValueFromColumns(n);this._silentOption("filterValue",o)}this.syncFilterValue(),this._dataController.pageIndex(t)}_getSyncFilterRow(e,t){let n=hN(t);return f(n)?rS(e,n):Xm(e,as(t))}_getSyncHeaderFilter(e,t){let n=pN(t);return n?rS(e,n):Xm(e,as(t))}getFilterValueFromColumns(e){if(!this._dataController.isFilterSyncActive())return null;let t=["and"];return e&&e.forEach(n=>{let o=pN(n),s=hN(n);o&&bd(o,t),s&&bd(s,t)}),Ta(t)}syncFilterRow(e,t){this.option("filterValue",this._getSyncFilterRow(this.option("filterValue"),e))}syncHeaderFilter(e){this.option("filterValue",this._getSyncHeaderFilter(this.option("filterValue"),e))}getCustomFilterOperations(){let e=this.option("filterBuilder.customOperations")??[];return[cN(this.component),uN(this.component)].concat(e)}},W9=i=>class extends i{optionChanged(e){switch(e.name){case"filterValue":this._applyFilter(),this.isFilterSyncActive()&&this._filterSyncController.syncFilterValue(),e.handled=!0;break;case"filterSyncEnabled":e.handled=!0;break;case"columns":if(this.isFilterSyncActive()){let t=this._columnsController.getColumnByPath(e.fullName);if(t&&!this._filterSyncController._skipSyncColumnOptions){let n=this._parseColumnPropertyName(e.fullName);this._filterSyncController._skipSyncColumnOptions=!0,n==="filterType"?(e.value==="exclude"||e.previousValue==="exclude")&&this._filterSyncController.syncHeaderFilter(t):n==="filterValues"?this._filterSyncController.syncHeaderFilter(t):["filterValue","selectedFilterOperation"].includes(n)&&this._filterSyncController.syncFilterRow(t,t.filterValue),this._filterSyncController._skipSyncColumnOptions=!1}}super.optionChanged(e);break;default:super.optionChanged(e)}}isFilterSyncActive(){let e=this.option("filterSyncEnabled");return e==="auto"?this.option("filterPanel.visible"):e}skipCalculateColumnFilters(){return(f(this.option("filterValue"))||this._filterSyncController._skipSyncColumnOptions)&&this.isFilterSyncActive()}_calculateAdditionalFilter(){if(this.option("filterPanel.filterEnabled")===!1)return super._calculateAdditionalFilter();let e=[super._calculateAdditionalFilter()],t=this._columnsController.getFilteringColumns(),n=this.option("filterValue");if(this.isFilterSyncActive()){let r=this._headerFilterController.getCurrentColumn(),a=this._applyFilterController.getCurrentColumnForFiltering(),l=r||a;(r||f(a?.filterValue))&&n&&(n=Xm(n,as(l)))}let o=this._filterSyncController.getCustomFilterOperations(),s=Ks(n,t,o,"filterBuilder");return s&&e.push(s),M.combineFilters(e)}_parseColumnPropertyName(e){let t=e.match(/.*\.(.*)/);return t?t[1]:null}clearFilter(e){this.component.beginUpdate(),arguments.length>0?(e==="filterValue"&&this.option("filterValue",null),super.clearFilter(e)):(this.option("filterValue",null),super.clearFilter()),this.component.endUpdate()}_applyFilter(){return this._filterSyncController._skipSyncColumnOptions?new y().resolve():super._applyFilter.apply(this,arguments)}},G9=i=>class extends i{optionChanged(e){e.name==="filterValue"?this._updateHeaderFilterIndicators():super.optionChanged(e)}_isHeaderFilterEmpty(e){return this._dataController.isFilterSyncActive()?!aS(this.option("filterValue"),as(e)):super._isHeaderFilterEmpty(e)}_needUpdateFilterIndicators(){return!this._dataController.isFilterSyncActive()}},_N={defaultOptions:()=>({filterValue:null,filterSyncEnabled:"auto"}),controllers:{filterSync:dS},extenders:{controllers:{data:W9},views:{columnHeadersView:G9}}};H.registerModule("filterSync",_N);var CN="dx-filterbuilder-action-icon";var Qm="dx-state-active";var xN="filterBuilder";var K9=[{name:"onEditorPreparing",config:{excludeValidators:["disabled","readOnly"],category:"rendering"}},{name:"onEditorPrepared",config:{excludeValidators:["disabled","readOnly"],category:"rendering"}},{name:"onValueChanged",config:{excludeValidators:["disabled","readOnly"]}}],vN={and:"and",or:"or",notAnd:"!and",notOr:"!or"},U9=hm(class{}),Zm=class extends Xe{_getDefaultOptions(){return m(super._getDefaultOptions(),{onEditorPreparing:null,onEditorPrepared:null,onValueChanged:null,fields:[],groupOperations:["and","or","notAnd","notOr"],maxGroupLevel:void 0,value:null,allowHierarchicalFields:!1,groupOperationDescriptions:{and:O.format("dxFilterBuilder-and"),or:O.format("dxFilterBuilder-or"),notAnd:O.format("dxFilterBuilder-notAnd"),notOr:O.format("dxFilterBuilder-notOr")},customOperations:[],closePopupOnTargetScroll:!0,filterOperationDescriptions:{between:O.format("dxFilterBuilder-filterOperationBetween"),equal:O.format("dxFilterBuilder-filterOperationEquals"),notEqual:O.format("dxFilterBuilder-filterOperationNotEquals"),lessThan:O.format("dxFilterBuilder-filterOperationLess"),lessThanOrEqual:O.format("dxFilterBuilder-filterOperationLessOrEquals"),greaterThan:O.format("dxFilterBuilder-filterOperationGreater"),greaterThanOrEqual:O.format("dxFilterBuilder-filterOperationGreaterOrEquals"),startsWith:O.format("dxFilterBuilder-filterOperationStartsWith"),contains:O.format("dxFilterBuilder-filterOperationContains"),notContains:O.format("dxFilterBuilder-filterOperationNotContains"),endsWith:O.format("dxFilterBuilder-filterOperationEndsWith"),isBlank:O.format("dxFilterBuilder-filterOperationIsBlank"),isNotBlank:O.format("dxFilterBuilder-filterOperationIsNotBlank")}})}_optionChanged(e){switch(e.name){case"closePopupOnTargetScroll":break;case"onEditorPreparing":case"onEditorPrepared":case"onValueChanged":this._initActions();break;case"customOperations":this._initCustomOperations(),this._invalidate();break;case"fields":case"maxGroupLevel":case"groupOperations":case"allowHierarchicalFields":case"groupOperationDescriptions":case"filterOperationDescriptions":this._invalidate();break;case"value":if(e.value!==e.previousValue){let t=this._disableInvalidateForValue;t||(this._initModel(),this._invalidate()),this._disableInvalidateForValue=!1,this.executeAction("onValueChanged",{value:e.value,previousValue:e.previousValue}),this._disableInvalidateForValue=t}break;default:super._optionChanged(e)}}getFilterExpression(){let e=this._getNormalizedFields(),t=m(!0,[],this._model);return Ks(Ta(t),e,this._customOperations,xN)}_getNormalizedFields(){return tN(this.option("fields"))}_updateFilter(){this._disableInvalidateForValue=!0;let e=m(!0,[],this._model),t=Ta(e),n=Ta(this._getModel(this.option("value")));JSON.stringify(n)!==JSON.stringify(t)&&this.option("value",t),this._disableInvalidateForValue=!1,this._fireContentReadyAction()}_init(){this._initCustomOperations(),this._initModel(),this._initEditorFactory(),this._initActions(),super._init()}_initEditorFactory(){this._editorFactory=new U9}_initCustomOperations(){this._customOperations=rN(this.option("customOperations"),this.option("filterOperationDescriptions.between"),this)}_getDefaultGroupOperation(){var e;return((e=this.option("groupOperations"))===null||e===void 0?void 0:e[0])??vN.and}_getModel(e){return Um(e,this._customOperations,this._getDefaultGroupOperation())}_initModel(){this._model=this._getModel(this.option("value"))}_initActions(){let e=this;e._actions={},K9.forEach(t=>{let n=m({},t.config);e._actions[t.name]=e._createActionByOption(t.name,n)})}executeAction(e,t){let n=this._actions[e];return n&&n(t)}_initMarkup(){this.$element().addClass("dx-filterbuilder"),super._initMarkup(),this._createGroupElementByCriteria(this._model).appendTo(this.$element())}_createConditionElement(e,t){return u("<div>").addClass("dx-filterbuilder-group").append(this._createConditionItem(e,t))}_createGroupElementByCriteria(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,o=this._createGroupElement(e,t,n),s=o.find(".dx-filterbuilder-group-content"),r=Us(e);for(let a=0;a<r.length;a++){let l=r[a];Do(l)?this._createGroupElementByCriteria(l,e,n+1).appendTo(s):Qt(l)&&this._createConditionElement(l,e).appendTo(s)}return o}_createGroupElement(e,t,n){let o=u("<div>").addClass("dx-filterbuilder-group-item"),s=u("<div>").addClass("dx-filterbuilder-group-content"),r=u("<div>").addClass("dx-filterbuilder-group").append(o).append(s);return t!=null&&this._createRemoveButton(()=>{Km(t,e),r.remove(),this._updateFilter()}).appendTo(o),this._createGroupOperationButton(e).appendTo(o),this._createAddButton(()=>{let a=JO(this._getDefaultGroupOperation());bd(a,e),this._createGroupElement(a,e,n+1).appendTo(s),this._updateFilter()},()=>{let a=this.option("fields")[0],l=eN(a,this._customOperations);bd(l,e),this._createConditionElement(l,e).appendTo(s),this._updateFilter()},n).appendTo(o),r}_createButton(e){return u("<div>").text(e)}_createGroupOperationButton(e){let t=this._getGroupOperations(e),n=YL(e,t),o=n.text,s=t&&t.length<2?this._createButton(o).addClass("dx-state-disabled"):this._createButtonWithMenu({caption:o,menu:{items:t,displayExpr:"text",keyExpr:"value",onItemClick:r=>{n!==r.itemData&&(qL(e,r.itemData.value),s.text(r.itemData.text),n=r.itemData,this._updateFilter())},onContentReady(r){r.component.selectItem(n)},cssClass:"dx-filterbuilder-group-operations"}});return s.addClass("dx-filterbuilder-text").addClass("dx-filterbuilder-group-operation").attr("tabindex",0)}_createButtonWithMenu(e){let t=this,n=function(){t.$element().find(`.${Qm}`).removeClass(Qm),t.$element().find(".dx-overlay .dx-treeview").remove(),t.$element().find(".dx-overlay").remove()},o=this.option("rtlEnabled"),s=o?"right":"left",r=this._createButton(e.caption);m(e.menu,{focusStateEnabled:!0,selectionMode:"single",onItemClick:(a=e.menu.onItemClick,function(l){a(l),l.event.type==="dxclick"&&n()}),onHiding(){r.removeClass(Qm)},position:{my:`${s} top`,at:`${s} bottom`,offset:"0 1",of:r,collision:"flip"},animation:null,onHidden(){n()},cssClass:`dx-filterbuilder-overlay ${e.menu.cssClass}`,rtlEnabled:o});var a;return e.popup={onShown(l){let d=u(l.component.content()).find(".dx-treeview"),c=d.dxTreeView("instance");_.on(d,"keyup keydown",h=>{let p=De(h);(h.type==="keydown"&&p==="tab"||h.type==="keyup"&&(p==="escape"||p==="enter"))&&(l.component.hide(),_.trigger(e.menu.position.of,"focus"))}),c.focus(),c.option("focusedElement",null)}},this._subscribeOnClickAndEnterKey(r,()=>{n(),t._createPopupWithTreeView(e,t.$element()),r.addClass(Qm)}),r}_hasValueButton(e){let t=Io(this._customOperations,e[1]);return t?t.hasValue!==!1:e[2]!==null}_createOperationButtonWithMenu(e,t){let n=this,o=JL(t,this.option("filterOperationDescriptions"),this._customOperations),s=ZL(sS(e),o),r=this._createButtonWithMenu({caption:s.text,menu:{items:o,displayExpr:"text",onItemRendered(a){a.itemData.isCustom&&u(a.itemElement).addClass("dx-filterbuilder-menu-custom-operation")},onContentReady(a){a.component.selectItem(s)},onItemClick:a=>{if(s!==a.itemData){s=a.itemData,Ym(e,s.value,n._customOperations);let l=r.siblings().filter(".dx-filterbuilder-item-value");n._hasValueButton(e)?(l.length!==0&&l.remove(),n._createValueButton(e,t).appendTo(r.parent())):l.remove(),r.text(s.text),this._updateFilter()}},cssClass:"dx-filterbuilder-operations"}}).addClass("dx-filterbuilder-text").addClass("dx-filterbuilder-item-operation").attr("tabindex",0);return r}_createOperationAndValueButtons(e,t,n){this._createOperationButtonWithMenu(e,t).appendTo(n),this._hasValueButton(e)&&this._createValueButton(e,t).appendTo(n)}_createFieldButtonWithMenu(e,t,n){let o=this,s=this.option("allowHierarchicalFields"),r=iS(e,s),a=yd(n.name||n.dataField,r),l=function(c,h){return s?oS(c,h):c.caption};t[0]=a.name||a.dataField;let d=this._createButtonWithMenu({caption:l(a,r),menu:{items:r,dataStructure:"plain",keyExpr:"id",parentId:"parentId",displayExpr:"caption",onItemClick:c=>{if(a!==c.itemData){a=c.itemData,t[0]=a.name||a.dataField,t[2]=a.dataType==="object"?null:"",Ym(t,Bu(a),o._customOperations),d.siblings().filter(".dx-filterbuilder-text").remove(),o._createOperationAndValueButtons(t,a,d.parent());let h=l(a,c.component.option("items"));d.text(h),this._updateFilter()}},onContentReady(c){c.component.selectItem(a)},cssClass:"dx-filterbuilder-fields"}}).addClass("dx-filterbuilder-text").addClass("dx-filterbuilder-item-field").attr("tabindex",0);return d}_createConditionItem(e,t){let n=u("<div>").addClass("dx-filterbuilder-group-item"),o=this._getNormalizedFields(),s=yd(e[0],o);return this._createRemoveButton(()=>{Km(t,e),n.parent().children().length===1?n.parent().remove():n.remove(),this._updateFilter()}).appendTo(n),this._createFieldButtonWithMenu(o,e,s).appendTo(n),this._createOperationAndValueButtons(e,s,n),n}_getGroupOperations(e){let t=this.option("groupOperations"),n=this.option("groupOperationDescriptions");return(!t||!t.length)&&(t=[js(e).replace("!","not")]),t.map(o=>({text:n[o],value:vN[o]}))}_createRemoveButton(e){let t=u("<div>").addClass(CN).addClass("dx-icon-remove").addClass("dx-filterbuilder-action").attr("tabindex",0);return this._subscribeOnClickAndEnterKey(t,e),t}_createAddButton(e,t,n){let o,s=this.option("maxGroupLevel");return f(s)&&n>=s?(o=this._createButton(),this._subscribeOnClickAndEnterKey(o,t)):o=this._createButtonWithMenu({menu:{items:[{caption:O.format("dxFilterBuilder-addCondition"),click:t},{caption:O.format("dxFilterBuilder-addGroup"),click:e}],displayExpr:"caption",onItemClick(r){r.itemData.click()},cssClass:"dx-filterbuilder-add-condition"}}),o.addClass(CN).addClass("dx-icon-plus").addClass("dx-filterbuilder-action").attr("tabindex",0)}_createValueText(e,t,n){let o=this,s=u("<div>").html("&nbsp;").addClass("dx-filterbuilder-item-value-text").attr("tabindex",0).appendTo(n),r=e[2],a=Io(o._customOperations,e[1]);return!a&&t.lookup?jm(t,r,l=>{Vu(s,l)}):P(qm(t,r,a)).done(l=>{Vu(s,l,a)}),o._subscribeOnClickAndEnterKey(s,l=>{l.type==="keyup"&&l.stopPropagation(),o._createValueEditorWithEvents(e,t,n)}),s}_updateConditionValue(e,t,n){e[2]!==t&&(e[2]=t),n(),this._updateFilter()}_addDocumentKeyUp(e,t){let n=!1,o=!1,s=w.getDocument(),r=l=>{if(n||o){o=!1;return}t(l)};_.on(s,"keyup",r);let a=e.find("input");_.on(a,"compositionstart",()=>{n=!0}),_.on(a,"compositionend",()=>{n=!1,o=!0}),_.on(a,"keydown",l=>{l.which!==229&&(o=!1)}),this._documentKeyUpHandler=r}_addDocumentClick(e,t){let n=w.getDocument(),o=s=>{this._isFocusOnEditorParts(e,s.target)||(_.trigger(e.find("input"),"change"),t())};_.on(n,"dxpointerdown",o),this._documentClickHandler=o}_isFocusOnEditorParts(e,t){let n=t||w.getActiveElement();return u(n).closest(e.children()).length||u(n).closest(".dx-dropdowneditor-overlay").length}_removeEvents(){let e=w.getDocument();f(this._documentKeyUpHandler)&&_.off(e,"keyup",this._documentKeyUpHandler),f(this._documentClickHandler)&&_.off(e,"dxpointerdown",this._documentClickHandler)}_dispose(){this._removeEvents(),super._dispose()}_createValueEditorWithEvents(e,t,n){let o=e[2],s=()=>(n.empty(),this._removeEvents(),this._createValueText(e,t,n)),r=()=>{this._updateConditionValue(e,o,()=>{s()})},a={value:o===""?null:o,filterOperation:sS(e),setValue(d){o=d===null?"":d},closeEditor:r,text:n.text()};n.empty();let l=this._createValueEditor(n,t,a);_.trigger(l.find("input").not(":hidden").eq(0),"focus"),this._removeEvents(),this._addDocumentClick(l,r),this._addDocumentKeyUp(l,d=>{let c=De(d);if(c==="tab"){if(this._isFocusOnEditorParts(l))return;this._updateConditionValue(e,o,()=>{s(),d.shiftKey&&_.trigger(n.prev(),"focus")})}c==="escape"&&_.trigger(s(),"focus"),c==="enter"&&this._updateConditionValue(e,o,()=>{_.trigger(s(),"focus")})}),this._fireContentReadyAction()}_createValueButton(e,t){let n=u("<div>").addClass("dx-filterbuilder-text").addClass("dx-filterbuilder-item-value");return this._createValueText(e,t,n),n}_createValueEditor(e,t,n){let o=u("<div>").attr("tabindex",0).appendTo(e),s=Io(this._customOperations,n.filterOperation),r=s&&s.editorTemplate?s.editorTemplate:t.editorTemplate;return r?this._getTemplate(r).render({model:m({field:t},n),container:o}):this._editorFactory.createEditor.call(this,o,m({},t,n,{parentType:xN})),o}_createPopupWithTreeView(e,t){let n=this,o=u("<div>").addClass(e.menu.cssClass).appendTo(t);this._createComponent(o,ii,{onHiding:e.menu.onHiding,onHidden:e.menu.onHidden,rtlEnabled:e.menu.rtlEnabled,position:e.menu.position,animation:e.menu.animation,contentTemplate(s){let r=u("<div>").appendTo(s);n._createComponent(r,es,e.menu),this.repaint()},_ignoreFunctionValueDeprecation:!0,maxHeight:()=>xd(e.menu.position.of),visible:!0,focusStateEnabled:!1,preventScrollEvents:!1,hideOnParentScroll:this.option("closePopupOnTargetScroll"),hideOnOutsideClick:!0,onShown:e.popup.onShown,shading:!1,width:"auto",height:"auto",showTitle:!1,_wrapperClassExternal:e.menu.cssClass,_ignorePreventScrollEventsDeprecation:!0})}_subscribeOnClickAndEnterKey(e,t){_.on(e,"dxclick",t),_.on(e,"keyup",n=>{De(n)==="enter"&&t(n)})}};G("dxFilterBuilder",Zm);var bN=Zm;var yN=bN;var cS=class extends Ce.View{init(){super.init(),this._columnsController=this.getController("columns"),this._filterSyncController=this.getController("filterSync")}optionChanged(e){switch(e.name){case"filterBuilder":case"filterBuilderPopup":this._invalidate(),e.handled=!0;break;default:super.optionChanged(e)}}_renderCore(){this._updatePopupOptions()}_updatePopupOptions(){this.option("filterBuilderPopup.visible")?this._initPopup():this._filterBuilderPopup&&this._filterBuilderPopup.hide()}_disposePopup(){this._filterBuilderPopup&&(this._filterBuilderPopup.dispose(),this._filterBuilderPopup=void 0),this._filterBuilder&&(this._filterBuilder.dispose(),this._filterBuilder=void 0)}_initPopup(){let e=this;e._disposePopup(),e._filterBuilderPopup=e._createComponent(e.element(),ii,m({title:O.format("dxDataGrid-filterBuilderPopupTitle"),contentTemplate:t=>e._getPopupContentTemplate(t),onOptionChanged(t){t.name==="visible"&&e.option("filterBuilderPopup.visible",t.value)},toolbarItems:e._getPopupToolbarItems()},e.option("filterBuilderPopup"),{onHidden(){nd(e),e._disposePopup()}}))}_getPopupContentTemplate(e){let t=u(e),n=u("<div>").appendTo(u(e));this._filterBuilder=this._createComponent(n,yN,m({value:this.option("filterValue"),fields:this._columnsController.getFilteringColumns()},this.option("filterBuilder"),{customOperations:this._filterSyncController.getCustomFilterOperations()})),this._createComponent(t,Bl,{direction:"both"})}_getPopupToolbarItems(){let e=this;return[{toolbar:"bottom",location:"after",widget:"dxButton",options:{text:O.format("OK"),onClick(){let t=e._filterBuilder.option("value");e.option("filterValue",t),e._filterBuilderPopup.hide()}}},{toolbar:"bottom",location:"after",widget:"dxButton",options:{text:O.format("Cancel"),onClick(){e._filterBuilderPopup.hide()}}}]}},ON={defaultOptions:()=>({filterBuilder:{groupOperationDescriptions:{and:O.format("dxFilterBuilder-and"),or:O.format("dxFilterBuilder-or"),notAnd:O.format("dxFilterBuilder-notAnd"),notOr:O.format("dxFilterBuilder-notOr")},filterOperationDescriptions:{between:O.format("dxFilterBuilder-filterOperationBetween"),equal:O.format("dxFilterBuilder-filterOperationEquals"),notEqual:O.format("dxFilterBuilder-filterOperationNotEquals"),lessThan:O.format("dxFilterBuilder-filterOperationLess"),lessThanOrEqual:O.format("dxFilterBuilder-filterOperationLessOrEquals"),greaterThan:O.format("dxFilterBuilder-filterOperationGreater"),greaterThanOrEqual:O.format("dxFilterBuilder-filterOperationGreaterOrEquals"),startsWith:O.format("dxFilterBuilder-filterOperationStartsWith"),contains:O.format("dxFilterBuilder-filterOperationContains"),notContains:O.format("dxFilterBuilder-filterOperationNotContains"),endsWith:O.format("dxFilterBuilder-filterOperationEndsWith"),isBlank:O.format("dxFilterBuilder-filterOperationIsBlank"),isNotBlank:O.format("dxFilterBuilder-filterOperationIsNotBlank")}},filterBuilderPopup:{}}),views:{filterBuilderView:cS}};H.registerModule("filterBuilder",ON);var uS=class extends Ce.View{init(){this._dataController=this.getController("data"),this._columnsController=this.getController("columns"),this._filterSyncController=this.getController("filterSync"),this._dataController.dataSourceChanged.add(()=>this.render())}isVisible(){return this.option("filterPanel.visible")&&this._dataController.dataSource()}_renderCore(){let e=this.element();if(e.empty(),!!!this._columnsController.getColumns().length)return;e.addClass(this.addWidgetPrefix("filter-panel"));let n=u("<div>").addClass(this.addWidgetPrefix("filter-panel-left")).appendTo(e);this._renderFilterBuilderText(e,n)}_renderFilterBuilderText(e,t){let n=this._getFilterElement(),o=this._getTextElement();if(this.option("filterValue")||this._filterValueBuffer){let s=this._getCheckElement(),r=this._getRemoveButtonElement();t.append(s).append(n).append(o),e.append(r);return}t.append(n).append(o)}_getCheckElement(){let e=this,t=u("<div>").addClass(this.addWidgetPrefix("filter-panel-checkbox"));return e._createComponent(t,Er,{value:e.option("filterPanel.filterEnabled"),onValueChanged(n){e.option("filterPanel.filterEnabled",n.value)}}),t.attr("title",this.option("filterPanel.texts.filterEnabledHint")),t}_getFilterElement(){let e=this,t=u("<div>").addClass("dx-icon-filter");return _.on(t,"click",()=>e._showFilterBuilder()),Ir("filterPanel",e,t,void 0,()=>e._showFilterBuilder()),e._addTabIndexToElement(t),t}_getTextElement(){let e=this,t=u("<div>").addClass(e.addWidgetPrefix("filter-panel-text")),n,o=e.option("filterValue");return o?P(e.getFilterText(o,this._filterSyncController.getCustomFilterOperations())).done(s=>{let r=e.option("filterPanel.customizeText");if(r){let a=r({component:e.component,filterValue:o,text:s});typeof a=="string"&&(s=a)}t.text(s)}):(n=e.option("filterPanel.texts.createFilter"),t.text(n)),_.on(t,"click",()=>e._showFilterBuilder()),Ir("filterPanel",e,t,void 0,()=>e._showFilterBuilder()),e._addTabIndexToElement(t),t}_showFilterBuilder(){this.option("filterBuilderPopup.visible",!0)}_getRemoveButtonElement(){let e=this,t=()=>e.option("filterValue",null),n=u("<div>").addClass(e.addWidgetPrefix("filter-panel-clear-filter")).text(e.option("filterPanel.texts.clearFilter"));return _.on(n,"click",t),Ir("filterPanel",this,n,void 0,t),e._addTabIndexToElement(n),n}_addTabIndexToElement(e){if(!this.option("useLegacyKeyboardNavigation")){let t=this.option("tabindex")||0;e.attr("tabindex",t)}}optionChanged(e){switch(e.name){case"filterValue":this._invalidate(),this.option("filterPanel.filterEnabled",!0),e.handled=!0;break;case"filterPanel":this._invalidate(),e.handled=!0;break;default:super.optionChanged(e)}}_getConditionText(e,t,n){let o=`[${e}] ${t}`;return f(n)&&(o+=n),o}_getValueMaskedText(e){return Array.isArray(e)?`('${e.join("', '")}')`:` '${e}'`}_getValueText(e,t,n){let o=new y,s=t&&t.customizeText;if(f(n)||s)if(!s&&e.lookup)jm(e,n,r=>{o.resolve(this._getValueMaskedText(r))});else{let r=Array.isArray(n)?n:M.getDisplayValue(e,n,null);P(qm(e,r,t,"filterPanel")).done(a=>{o.resolve(this._getValueMaskedText(a))})}else o.resolve("");return o.promise()}getConditionText(e,t){let n=this,o=e[1],s=new y,r=Io(t.customOperations,o),a,l=yd(e[0],t.columns),d=l.caption||"",c=e[2];return r?a=r.caption||kn(r.name):c===null?a=Gm(o==="="?"isblank":"isnotblank",t.filterOperationDescriptions):a=Gm(o,t.filterOperationDescriptions),this._getValueText(l,r,c).done(h=>{s.resolve(n._getConditionText(d,a,h))}),s}getGroupText(e,t,n){let o=this,s=new y,r=[],a=js(e);return e.forEach(l=>{Qt(l)?r.push(o.getConditionText(l,t)):Do(l)&&r.push(o.getGroupText(l,t,!0))}),P.apply(this,r).done(function(){let l;for(var d=arguments.length,c=new Array(d),h=0;h<d;h++)c[h]=arguments[h];a.startsWith("!")?l=`${t.groupOperationDescriptions[`not${a.substring(1,2).toUpperCase()}${a.substring(2)}`].split(" ")[0]} ${c[0]}`:l=c.join(` ${t.groupOperationDescriptions[a]} `),n&&(l=`(${l})`),s.resolve(l)}),s}getFilterText(e,t){let n={customOperations:t,columns:this._columnsController.getFilteringColumns(),filterOperationDescriptions:this.option("filterBuilder.filterOperationDescriptions"),groupOperationDescriptions:this.option("filterBuilder.groupOperationDescriptions")};return Qt(e)?this.getConditionText(e,n):this.getGroupText(e,n)}},j9=i=>class extends i{optionChanged(e){e.name==="filterPanel"?(this._applyFilter(),e.handled=!0):super.optionChanged(e)}},SN={defaultOptions:()=>({filterPanel:{visible:!1,filterEnabled:!0,texts:{createFilter:O.format("dxDataGrid-filterPanelCreateFilter"),clearFilter:O.format("dxDataGrid-filterPanelClearFilter"),filterEnabledHint:O.format("dxDataGrid-filterPanelFilterEnabledHint")}}}),views:{filterPanelView:uS},extenders:{controllers:{data:j9}}};H.registerModule("filterPanel",SN);function EN(i){return!!(i.allowSearch??i.allowFiltering)}function wN(i,e){let{lookup:t}=i;return i.parseValue?t?i.parseValue.call(t,e):i.parseValue(e):e}var q9=i=>class extends i{optionChanged(e){switch(e.fullName){case"searchPanel.text":case"searchPanel":this._applyFilter(),e.handled=!0;break;default:super.optionChanged(e)}}publicMethods(){return super.publicMethods().concat(["searchByText"])}_calculateAdditionalFilter(){var e,t,n;let o=(e=this._dataController)===null||e===void 0||(t=e.getDataSource)===null||t===void 0?void 0:t.call(e),s=o==null||(n=o.loadOptions)===null||n===void 0||(n=n.call(o))===null||n===void 0?void 0:n.langParams,r=super._calculateAdditionalFilter(),a=this.calculateSearchFilter(this.option("searchPanel.text"),s);return M.combineFilters([r,a])}searchByText(e){this.option("searchPanel.text",e)}calculateSearchFilter(e,t){let n,o=this._columnsController.getColumns(),s=this.option("searchPanel.searchVisibleColumnsOnly"),r,a=[];if(!e)return null;function l(c){let h=me(r.valueExpr);for(let p=0;p<c.length;p++){let g=h(c[p]);a.push(n.createFilterExpression(g,null,"search"))}}for(let c=0;c<o.length;c++)if(n=o[c],!(s&&!n.visible)&&EN(n)&&n.calculateFilterExpression){var d;r=n.lookup;let h=wN(n,e);(d=r)!==null&&d!==void 0&&d.items?vt(r.items,{langParams:t}).filter(n.createFilterExpression.call({dataField:r.displayExpr,dataType:r.dataType,calculateFilterExpression:n.calculateFilterExpression},h,null,"search")).enumerate().done(l):h!==void 0&&a.push(n.createFilterExpression(h,null,"search"))}return a.length===0?["!"]:M.combineFilters(a,"or")}},Y9=i=>class extends i{optionChanged(e){if(e.name==="searchPanel"){if(e.fullName==="searchPanel.text"){let t=this.getSearchTextEditor();t&&t.option("value",e.value)}else this._invalidate();e.handled=!0}else super.optionChanged(e)}_getToolbarItems(){let e=super._getToolbarItems();return this._prepareSearchItem(e)}_prepareSearchItem(e){let t=this,n=this._dataController,o=this.option("searchPanel");if(o&&o.visible){let s={template(r,a,l){let d=u("<div>").addClass(t.addWidgetPrefix("search-panel")).appendTo(l);t._editorFactoryController.createEditor(d,{width:o.width,placeholder:o.placeholder,parentType:"searchPanel",value:t.option("searchPanel.text"),updateValueTimeout:700,setValue(c){n.searchByText(c)},editorOptions:{inputAttr:{"aria-label":O.format(`${t.component.NAME}-ariaSearchInGrid`)}}}),t.resize()},name:"searchPanel",location:"after",locateInMenu:"never",sortIndex:40};e.push(s)}return e}getSearchTextEditor(){let e=this,t=e.element(),n=t.find(`.${e.addWidgetPrefix("search-panel")}`).filter(function(){return u(this).closest(`.${e.addWidgetPrefix("header-panel")}`).is(t)});return n.length?n.dxTextBox("instance"):null}},X9=i=>class extends i{init(){super.init.apply(this,arguments),this._searchParams=[],this._dataController=this.getController("data")}dispose(){clearTimeout(this._highlightTimer),super.dispose()}_getFormattedSearchText(e,t){let n=wN(e,t),o=M.getFormatOptionsByColumn(e,"search");return M.formatValue(n,o)}_getStringNormalizer(){var e,t,n;let o=this.option("searchPanel.highlightCaseSensitive"),s=(e=this._dataController)===null||e===void 0||(t=e.getDataSource)===null||t===void 0?void 0:t.call(e),r=s==null||(n=s.loadOptions)===null||n===void 0||(n=n.call(s))===null||n===void 0?void 0:n.langParams;return a=>Ot(a,o,r)}_findHighlightingTextNodes(e,t,n){var o;let s=this,r=t.parent(),a,l=this._getStringNormalizer(),d=l(n),c=[];if(!r.length)r=u("<div>").append(t);else if(e)if(e.groupIndex>=0&&!e.showWhenGrouped)a=t;else{let h=s._columnsController.getVisibleIndex(e.index);a=r.children("td").eq(h).find("*")}return a=(o=a)!==null&&o!==void 0&&o.length?a:r.find("*"),a.each((h,p)=>{let g=u(p).contents();for(let C=0;C<g.length;C++){let v=g.get(C);v.nodeType===3&&l(v.textContent??v.nodeValue??"").includes(d)&&c.push(v)}}),c}_highlightSearchTextCore(e,t){let n=this,o=u("<span>").addClass(n.addWidgetPrefix("search-text")),s=e.text(),r=e[0],a=this._getStringNormalizer(),l=a(s).indexOf(a(t));if(l>=0)return r.textContent?r.textContent=s.substr(0,l):r.nodeValue=s.substr(0,l),e.after(o.text(s.substr(l,t.length))),e=u(w.createTextNode(s.substr(l+t.length))).insertAfter(o),n._highlightSearchTextCore(e,t)}_highlightSearchText(e,t,n){let o=this,s=this._getStringNormalizer(),r=o.option("searchPanel.text");t&&n&&(r=r&&o._getFormattedSearchText(n,r)),r&&o.option("searchPanel.highlightSearchText")&&o._findHighlightingTextNodes(n,e,r).forEach(l=>{t?s(u(l).text())===s(r??"")&&u(l).replaceWith(u("<span>").addClass(o.addWidgetPrefix("search-text")).text(u(l).text())):o._highlightSearchTextCore(u(l),r)})}_renderCore(){let e=super._renderCore.apply(this,arguments);return(this.option().rowTemplate||this.option("dataRowTemplate"))&&(this.option("templatesRenderAsynchronously")?(clearTimeout(this._highlightTimer),this._highlightTimer=setTimeout(()=>{this._highlightSearchText(this.getTableElement())})):this._highlightSearchText(this.getTableElement())),e}_updateCell(e,t){let{column:n}=t,s=(n.lookup&&n.lookup.dataType||n.dataType)!=="string";EN(n)&&!t.isOnForm&&(this.option("templatesRenderAsynchronously")?(this._searchParams.length||(clearTimeout(this._highlightTimer),this._highlightTimer=setTimeout(()=>{this._searchParams.forEach(r=>{this._highlightSearchText.apply(this,r)}),this._searchParams=[]})),this._searchParams.push([e,s,n])):this._highlightSearchText(e,s,n)),super._updateCell(e,t)}},IN={defaultOptions:()=>({searchPanel:{visible:!1,width:160,placeholder:O.format("dxDataGrid-searchPanelPlaceholder"),highlightSearchText:!0,highlightCaseSensitive:!1,text:"",searchVisibleColumnsOnly:!1}}),extenders:{controllers:{data:q9},views:{headerPanel:Y9,rowsView:X9}}};H.registerModule("search",IN);var Jm=class extends Ol{_optionChanged(e){switch(e.name){case"pageIndex":{let t=this.option("pageIndexChanged");t&&t(e.value);break}case"pageSize":{let t=this.option("pageSizeChanged");t&&t(e.value);break}}super._optionChanged(e)}};function hS(i){var e;let t=K();return i?(e=t.getComputedStyle)===null||e===void 0?void 0:e.call(t,i):null}function ls(i,e){let t=hS(e)??{};return kp(t[i])}function DN(i){let e=ls("paddingLeft",i)+ls("paddingRight",i);return ls("width",i)-e}function Lu(i){let e=ls("marginLeft",i)+ls("marginRight",i),t=ls("width",i);return e+t}function ef(i){return ls("minWidth",i)}var Q9=["contentTemplate","pagerProps"],Z9=i=>{let{contentAttributes:e,infoTextRef:t,infoTextVisible:n,isLargeDisplayMode:o,pageSizesRef:s,pagesRef:r,parentRef:a,props:{contentTemplate:l}}=i;return l(I({rootElementRef:a,pageSizesRef:s,infoTextRef:t,pagesRef:r,infoTextVisible:n,isLargeDisplayMode:o},e))};function J9(i){let{pageSizes:e,pages:t,parent:n}=i;return n-(e+t)>0}function e8(i){let{info:e,pageSizes:t,pages:n,parent:o}=i,s=t+n+e;return o-s>0}function t8(i){let{info:e,pageSizes:t,pages:n,parent:o}=i,s=DN(o),r=Lu(t),a=Lu(e),l=Lu(n);return{parent:s,pageSizes:r,info:a+ls("marginLeft",e)+ls("marginRight",e),pages:l}}var i8={},n8=i=>i&&(i.defaultProps?e=>yt(Ee(2,i,I({},e))):i),TN=(()=>{class i extends Si{constructor(t){super(t),this.parentRef=at(),this.pageSizesRef=at(),this.infoTextRef=at(),this.pagesRef=at(),this.actualIsLargeDisplayMode=!0,this.actualInfoTextVisible=!0,this.state={infoTextVisible:!0,isLargeDisplayMode:!0},this.subscribeToResize=this.subscribeToResize.bind(this),this.effectUpdateChildProps=this.effectUpdateChildProps.bind(this),this.updateAdaptivityProps=this.updateAdaptivityProps.bind(this)}createEffects(){return[new Le(this.subscribeToResize,[this.state.infoTextVisible,this.state.isLargeDisplayMode]),new Le(this.effectUpdateChildProps,[this.props,this.state.infoTextVisible,this.state.isLargeDisplayMode,this.props.pagerProps,this.props.contentTemplate])]}updateEffects(){var t,n;(t=this._effects[0])===null||t===void 0||t.update([this.state.infoTextVisible,this.state.isLargeDisplayMode]),(n=this._effects[1])===null||n===void 0||n.update([this.props,this.state.infoTextVisible,this.state.isLargeDisplayMode,this.props.pagerProps,this.props.contentTemplate])}subscribeToResize(){let t=()=>{this.parentWidth>0&&this.updateAdaptivityProps()};return co.add(t),()=>{co.remove(t)}}effectUpdateChildProps(){this.parentWidth>0&&this.updateAdaptivityProps()}get contentAttributes(){let{className:t,displayMode:n,gridCompatibility:o,hasKnownLastPage:s,infoText:r,label:a,lightModeEnabled:l,maxPagesCount:d,onKeyDown:c,pageCount:h,pageIndex:p,pageIndexChange:g,pageSize:C,pageSizeChange:v,pageSizes:b,pagesCountText:T,pagesNavigatorVisible:R,rtlEnabled:U,showInfo:Q,showNavigationButtons:se,showPageSizes:re,totalCount:Re,visible:we}=this.props.pagerProps;return I({},this.restAttributes,{pageSize:C,pageIndex:p,pageIndexChange:g,pageSizeChange:v,gridCompatibility:o,className:t,showInfo:Q,infoText:r,lightModeEnabled:l,displayMode:n,maxPagesCount:d,pageCount:h,pagesCountText:T,visible:we,hasKnownLastPage:s,pagesNavigatorVisible:R,showPageSizes:re,pageSizes:b,rtlEnabled:U,showNavigationButtons:se,totalCount:Re,onKeyDown:c,label:a})}get parentWidth(){return this.parentRef.current?Lu(this.parentRef.current):0}updateAdaptivityProps(){let t=t8({parent:this.parentRef.current,pageSizes:this.pageSizesRef.current,info:this.infoTextRef.current,pages:this.pagesRef.current});if(this.actualInfoTextVisible!==this.state.infoTextVisible||this.actualIsLargeDisplayMode!==this.state.isLargeDisplayMode)return;let n=!f(this.elementsWidth);n&&(this.elementsWidth={}),(n||this.state.isLargeDisplayMode)&&(this.elementsWidth.pageSizes=t.pageSizes,this.elementsWidth.pages=t.pages),(n||this.state.infoTextVisible)&&(this.elementsWidth.info=t.info),this.actualIsLargeDisplayMode=J9(I({parent:t.parent},{pageSizes:this.elementsWidth.pageSizes,pages:this.elementsWidth.pages})),this.actualInfoTextVisible=e8(I({},t,{info:this.elementsWidth.info})),this.setState(o=>({infoTextVisible:this.actualInfoTextVisible})),this.setState(o=>({isLargeDisplayMode:this.actualIsLargeDisplayMode}))}get restAttributes(){let t=this.props;return ge(t,Q9)}render(){let t=this.props;return Z9({props:I({},t,{contentTemplate:n8(t.contentTemplate)}),infoTextVisible:this.state.infoTextVisible,isLargeDisplayMode:this.state.isLargeDisplayMode,parentRef:this.parentRef,pageSizesRef:this.pageSizesRef,infoTextRef:this.infoTextRef,pagesRef:this.pagesRef,contentAttributes:this.contentAttributes,parentWidth:this.parentWidth,updateAdaptivityProps:this.updateAdaptivityProps,restAttributes:this.restAttributes})}}return i.defaultProps=i8,i})();var pS={gridCompatibility:!0,showInfo:!1,displayMode:"adaptive",maxPagesCount:10,pageCount:10,visible:!0,hasKnownLastPage:!0,pagesNavigatorVisible:"auto",showPageSizes:!0,pageSizes:Object.freeze([5,10]),showNavigationButtons:!1,totalCount:0,get label(){return O.format("dxPager-ariaLabel")}};var AN=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(pS),Object.getOwnPropertyDescriptors({defaultPageSize:5,pageSizeChange:()=>{},defaultPageIndex:1,pageIndexChange:()=>{}}))),Ct=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(pS),Object.getOwnPropertyDescriptors({pageSize:5,pageIndex:1})));var o8=["infoText","pageCount","pageIndex","rootElementRef","totalCount"],MN="dx-info",s8=i=>{let{props:{rootElementRef:e},text:t}=i;return Ke(1,"div","dx-info",t,0,null,null,e)};var r8={get pageIndex(){return Ct.pageIndex},get pageCount(){return Ct.pageCount},get totalCount(){return Ct.totalCount}},RN=(()=>{class i extends _t{constructor(t){super(t),this.state={}}get infoText(){return(this.props.infoText??"")||O.getFormatter("dxPager-infoText")()}get text(){let{pageCount:t,pageIndex:n,totalCount:o}=this.props;return Ii(this.infoText,(n+1).toString(),t.toString(),o.toString())}get restAttributes(){let t=this.props;return ge(t,o8)}render(){let t=this.props;return s8({props:I({},t),infoText:this.infoText,text:this.text,restAttributes:this.restAttributes})}}return i.defaultProps=r8,i})();var Aa=vp(void 0);var a8=["children","className","label","onClick","selected","tabIndex"],l8=i=>{let{props:{children:e,className:t,label:n,selected:o,tabIndex:s},widgetRef:r}=i;return Ke(1,"div",t,e,0,{tabIndex:s,role:"button","aria-label":n,"aria-current":o?"page":void 0},null,r)},d8={className:"",label:"",tabIndex:0,selected:!1},Ma=(()=>{class i extends Si{get keyboardContext(){return this.context[Aa.id]?this.context[Aa.id]:Aa.defaultValue}constructor(t){super(t),this.state={},this.widgetRef=at(),this.keyboardEffect=this.keyboardEffect.bind(this),this.subscribeToClick=this.subscribeToClick.bind(this)}createEffects(){return[new Le(this.keyboardEffect,[this.keyboardContext,this.props.onClick]),new Le(this.subscribeToClick,[this.props.onClick])]}updateEffects(){var t,n;(t=this._effects[0])===null||t===void 0||t.update([this.keyboardContext,this.props.onClick]),(n=this._effects[1])===null||n===void 0||n.update([this.props.onClick])}keyboardEffect(){return this.keyboardContext.registerKeyboardAction(this.widgetRef.current,this.props.onClick)}subscribeToClick(){return oA(this.widgetRef.current,this.props.onClick)}get restAttributes(){let t=this.props;return ge(t,a8)}render(){let t=this.props;return l8({props:I({},t),widgetRef:this.widgetRef,keyboardContext:this.keyboardContext,restAttributes:this.restAttributes})}}return i.defaultProps=d8,i})();var FN="dx-pager",PN="dx-light-mode",kN="dx-pages",BN="dx-page-indexes",VN="dx-page",LN="dx-selection",NN="dx-page-size",HN="dx-page-sizes",$N="dx-page-size dx-selection",zN="dx-first-child";var c8=["className","index","onClick","selected"],u8=i=>{let{className:e,label:t,props:{onClick:n,selected:o},value:s}=i;return Ee(2,Ma,{className:e,label:t,onClick:n,selected:o,children:s})},h8={index:0,selected:!1,className:VN},tf=(()=>{class i extends _t{constructor(t){super(t),this.state={}}get label(){return Ii(O.getFormatter("dxPager-page"),this.value)}get value(){return this.props.index+1}get className(){let{selected:t}=this.props;return ti({[`${this.props.className}`]:!!this.props.className,[LN]:!!t})}get restAttributes(){let t=this.props;return ge(t,c8)}render(){let t=this.props;return u8({props:I({},t),label:this.label,value:this.value,className:this.className,restAttributes:this.restAttributes})}}return i.defaultProps=h8,i})();var p8=["pageIndexes"],g8=["maxPagesCount","pageCount","pageIndex","pageIndexChange"];var m8=i=>{let{pages:e}=i,t=e.map(n=>{let{key:o,pageProps:s}=n;return s?Ee(2,tf,{index:s.index,selected:s.selected,onClick:s.onClick},o):Ke(1,"div","dx-separator",". . .",16,null,o)});return Zi(t,0)};function WN(i,e,t){return i===1?"high":i+e===t-1?"low":"both"}function KN(i,e,t){let n=[],o=[];switch(t){case"none":n=[...i];break;case"both":n=[0,"low",...i,"high",e-1],o=i.slice(1,-1);break;case"high":n=[0,...i,"high",e-1],o=i.slice(0,-1);break;case"low":n=[0,"low",...i,e-1],o=i.slice(1)}return{slidingWindowIndexes:i,indexesForReuse:o,pageIndexes:n}}function GN(i,e,t,n){let o=[];for(let s=0;s<e;s+=1)o.push(s+i);return KN(o,t,n)}var f8={get pageIndex(){return Ct.pageIndex},get maxPagesCount(){return Ct.maxPagesCount},get pageCount(){return Ct.pageCount}},UN=(()=>{class i extends _t{get config(){return this.context[Kt.id]?this.context[Kt.id]:Kt.defaultValue}constructor(t){super(t),this.state={},this.canReuseSlidingWindow=this.canReuseSlidingWindow.bind(this),this.generatePageIndexes=this.generatePageIndexes.bind(this),this.isSlidingWindowMode=this.isSlidingWindowMode.bind(this),this.onPageClick=this.onPageClick.bind(this)}get slidingWindowState(){let t=this.slidingWindowStateHolder;return t||{indexesForReuse:[],slidingWindowIndexes:[]}}canReuseSlidingWindow(t,n){let{indexesForReuse:o}=this.slidingWindowState,s=o.slice(-1)[0]<t-1,r=o.includes(n);return s&&r}generatePageIndexes(){let{pageCount:t,pageIndex:n}=this.props,o=0,{slidingWindowIndexes:s}=this.slidingWindowState;n===s[0]?o=n-1:n===s[s.length-1]?o=n+2-4:n<4?o=1:n>=t-4?o=t-4-1:o=n-1;let r=WN(o,4,t),a=GN(o,4,t,r),{pageIndexes:l}=a,d=ge(a,p8);return this.slidingWindowStateHolder=d,l}isSlidingWindowMode(){let{maxPagesCount:t,pageCount:n}=this.props;return n<=4||n<=t}onPageClick(t){this.props.pageIndexChange(t)}get pageIndexes(){let{pageCount:t}=this.props;if(this.isSlidingWindowMode())return GN(0,t,t,"none").pageIndexes;if(this.canReuseSlidingWindow(t,this.props.pageIndex)){let{slidingWindowIndexes:n}=this.slidingWindowState,o=WN(n[0],4,t);return KN(n,t,o).pageIndexes}return this.generatePageIndexes()}get pages(){var t;let{pageIndex:n}=this.props,o=r=>{let a=r==="low"||r==="high"?null:{index:r,onClick:()=>this.onPageClick(r),selected:n===r};return{key:r.toString(),pageProps:a}};return((t=this.config)!==null&&t!==void 0&&t.rtlEnabled?[...this.pageIndexes].reverse():this.pageIndexes).map(r=>o(r))}get restAttributes(){let t=this.props;return ge(t,g8)}render(){let t=this.props;return m8({props:I({},t),config:this.config,pageIndexes:this.pageIndexes,pages:this.pages,restAttributes:this.restAttributes})}}return i.defaultProps=f8,i})();var Hr={hoverStateEnabled:!0,activeStateEnabled:!0,get focusStateEnabled(){return F.real().deviceType==="desktop"&&!F.isSimulator()}};var Od={label:"",get labelMode(){return it(ct())?"floating":"static"}};var _8=["accessKey","activeStateEnabled","className","defaultValue","disabled","focusStateEnabled","height","hint","hoverStateEnabled","inputAttr","invalidValueMessage","isDirty","isValid","label","labelMode","max","min","mode","name","onClick","onFocusIn","onKeyDown","readOnly","rtlEnabled","showSpinButtons","step","tabIndex","useLargeSpinButtons","validationError","validationErrors","validationMessageMode","validationMessagePosition","validationStatus","value","valueChange","visible","width"];var C8=i=>{let{componentProps:e,restAttributes:t}=i;return yt(Ee(2,Zl,I({componentType:ya,componentProps:e,templateNames:[]},t)))},cn=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(St),Object.getOwnPropertyDescriptors({defaultValue:0,isReactComponentWrapper:!0}))),x8={get defaultValue(){return cn.defaultValue},get readOnly(){return cn.readOnly},get name(){return cn.name},get validationError(){return cn.validationError},get validationErrors(){return cn.validationErrors},get validationMessageMode(){return cn.validationMessageMode},get validationMessagePosition(){return cn.validationMessagePosition},get validationStatus(){return cn.validationStatus},get isValid(){return cn.isValid},get isDirty(){return cn.isDirty},get inputAttr(){return cn.inputAttr},get className(){return cn.className},get activeStateEnabled(){return Hr.activeStateEnabled},get disabled(){return cn.disabled},get focusStateEnabled(){return Hr.focusStateEnabled},get hoverStateEnabled(){return Hr.hoverStateEnabled},get tabIndex(){return cn.tabIndex},get visible(){return cn.visible},get label(){return Od.label},get labelMode(){return Od.labelMode},isReactComponentWrapper:!0},jN=(()=>{class i extends _t{constructor(t){super(t),this.state={value:this.props.value!==void 0?this.props.value:this.props.defaultValue}}get componentProps(){return I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value})}get restAttributes(){let t=I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value});return ge(t,_8)}render(){let t=this.props;return C8({props:I({},t,{value:this.props.value!==void 0?this.props.value:this.state.value}),componentProps:this.componentProps,restAttributes:this.restAttributes})}}return i.defaultProps=x8,i})();function nf(i,e){return i+10*Math.max(...e).toString().length}var v8=["inputAttr","pageCount","pageIndex","pageIndexChange","pagesCountText"],b8=`${MN}  dx-info-text`;var y8=i=>{let{pageIndexRef:e,pagesCountText:t,props:{inputAttr:n,pageCount:o},selectLastPageIndex:s,value:r,valueChange:a,width:l}=i;return Ke(1,"div","dx-light-pages",[Ee(2,jN,{className:"dx-page-index",min:1,max:Math.max(o,r),width:l,value:r,valueChange:a,inputAttr:n}),Ke(1,"span",b8,t,0),Ee(2,tf,{className:"dx-pages-count",selected:!1,index:o-1,onClick:s})],4,null,null,e)},O8={inputAttr:Object.freeze({"aria-label":O.format("dxPager-ariaPageNumber")})},S8={get pageIndex(){return Ct.pageIndex},get pageCount(){return Ct.pageCount},get inputAttr(){return O8.inputAttr}},qN=(()=>{class i extends Si{constructor(t){super(t),this.pageIndexRef=at(),this.state={minWidth:10},this.updateWidth=this.updateWidth.bind(this),this.selectLastPageIndex=this.selectLastPageIndex.bind(this),this.valueChange=this.valueChange.bind(this)}createEffects(){return[new Le(this.updateWidth,[this.state.minWidth])]}updateEffects(){var t;(t=this._effects[0])===null||t===void 0||t.update([this.state.minWidth])}updateWidth(){var t;let n=(t=this.pageIndexRef.current)===null||t===void 0?void 0:t.querySelector(".dx-page-index");this.setState(o=>({minWidth:n&&ef(n)||o.minWidth}))}get value(){return this.props.pageIndex+1}get width(){let{pageCount:t}=this.props;return nf(this.state.minWidth,[t])}get pagesCountText(){return(this.props.pagesCountText??"")||O.getFormatter("dxPager-pagesCountText")()}selectLastPageIndex(){this.props.pageIndexChange(this.props.pageCount-1)}valueChange(t){this.props.pageIndexChange(t-1)}get restAttributes(){let t=this.props;return ge(t,v8)}render(){let t=this.props;return y8({props:I({},t),pageIndexRef:this.pageIndexRef,value:this.value,width:this.width,pagesCountText:this.pagesCountText,selectLastPageIndex:this.selectLastPageIndex,valueChange:this.valueChange,restAttributes:this.restAttributes})}}return i.defaultProps=S8,i})();var E8=["hasKnownLastPage","isLargeDisplayMode","maxPagesCount","pageCount","pageIndex","pageIndexChange","pagesCountText","showNavigationButtons","totalCount"];var w8=()=>O.getFormatter("dxPager-nextPage")(),I8=()=>O.getFormatter("dxPager-prevPage")(),D8={nextEnabledClass:"dx-navigate-button dx-next-button",prevEnabledClass:"dx-navigate-button dx-prev-button",nextDisabledClass:"dx-button-disable dx-navigate-button dx-next-button",prevDisabledClass:"dx-button-disable dx-navigate-button dx-prev-button"},T8={next:"prev",prev:"next"},A8=i=>{let{nextButtonProps:e,pageIndexChange:t,prevButtonProps:n,props:{isLargeDisplayMode:o,maxPagesCount:s,pageCount:r,pageIndex:a,pagesCountText:l},renderNextButton:d,renderPrevButton:c}=i;return Zi([c&&Ee(2,Ma,{label:I8(),className:n.className,tabIndex:n.tabIndex,onClick:n.navigate}),o&&Ee(2,UN,{maxPagesCount:s,pageCount:r,pageIndex:a,pageIndexChange:t}),!o&&Ee(2,qN,{pageCount:r,pageIndex:a,pageIndexChange:t,pagesCountText:l}),d&&Ee(2,Ma,{label:w8(),className:e.className,tabIndex:e.tabIndex,onClick:e.navigate})],0)};function M8(i){return i==="next"?1:-1}var R8={isLargeDisplayMode:!0},F8={get pageIndex(){return Ct.pageIndex},get maxPagesCount(){return Ct.maxPagesCount},get pageCount(){return Ct.pageCount},get hasKnownLastPage(){return Ct.hasKnownLastPage},get showNavigationButtons(){return Ct.showNavigationButtons},get totalCount(){return Ct.totalCount},get isLargeDisplayMode(){return R8.isLargeDisplayMode}},YN=(()=>{class i extends _t{get config(){return this.context[Kt.id]?this.context[Kt.id]:Kt.defaultValue}constructor(t){super(t),this.state={},this.__getterCache={},this.pageIndexChange=this.pageIndexChange.bind(this),this.getButtonProps=this.getButtonProps.bind(this),this.canNavigateToPage=this.canNavigateToPage.bind(this),this.getNextPageIndex=this.getNextPageIndex.bind(this),this.canNavigateTo=this.canNavigateTo.bind(this),this.navigateToPage=this.navigateToPage.bind(this)}pageIndexChange(t){this.canNavigateToPage(t)&&this.props.pageIndexChange(t)}getButtonProps(t){var n;let o=(n=this.config)!==null&&n!==void 0&&n.rtlEnabled?T8[t]:t,s=this.canNavigateTo(o);return{className:D8[`${t}${s?"Enabled":"Disabled"}Class`],tabIndex:s?0:-1,navigate:()=>this.navigateToPage(o)}}canNavigateToPage(t){return this.props.hasKnownLastPage?t>=0&&t<=this.props.pageCount-1:t>=0}getNextPageIndex(t){return this.props.pageIndex+M8(t)}canNavigateTo(t){return this.canNavigateToPage(this.getNextPageIndex(t))}navigateToPage(t){this.pageIndexChange(this.getNextPageIndex(t))}get renderPrevButton(){let{isLargeDisplayMode:t,showNavigationButtons:n}=this.props;return!t||n}get renderNextButton(){return this.renderPrevButton||!this.props.hasKnownLastPage}get prevButtonProps(){return this.__getterCache.prevButtonProps!==void 0?this.__getterCache.prevButtonProps:this.__getterCache.prevButtonProps=this.getButtonProps("prev")}get nextButtonProps(){return this.__getterCache.nextButtonProps!==void 0?this.__getterCache.nextButtonProps:this.__getterCache.nextButtonProps=this.getButtonProps("next")}get restAttributes(){let t=this.props;return ge(t,E8)}componentWillUpdate(t,n,o){(this.context[Kt.id]!==o[Kt.id]||this.props.hasKnownLastPage!==t.hasKnownLastPage||this.props.pageCount!==t.pageCount||this.props.pageIndex!==t.pageIndex||this.props.pageIndexChange!==t.pageIndexChange)&&(this.__getterCache.prevButtonProps=void 0),(this.context[Kt.id]!==o[Kt.id]||this.props.hasKnownLastPage!==t.hasKnownLastPage||this.props.pageCount!==t.pageCount||this.props.pageIndex!==t.pageIndex||this.props.pageIndexChange!==t.pageIndexChange)&&(this.__getterCache.nextButtonProps=void 0)}render(){let t=this.props;return A8({props:I({},t),config:this.config,pageIndexChange:this.pageIndexChange,renderPrevButton:this.renderPrevButton,renderNextButton:this.renderNextButton,prevButtonProps:this.prevButtonProps,nextButtonProps:this.nextButtonProps,restAttributes:this.restAttributes})}}return i.defaultProps=F8,i})();var P8=["accessKey","activeStateEnabled","className","dataSource","defaultValue","disabled","displayExpr","focusStateEnabled","height","hint","hoverStateEnabled","inputAttr","isDirty","isValid","label","labelMode","name","onClick","onFocusIn","onKeyDown","placeholder","readOnly","rtlEnabled","searchEnabled","tabIndex","validationError","validationErrors","validationMessageMode","validationMessagePosition","validationStatus","value","valueChange","valueExpr","visible","width"],k8=i=>{let{componentProps:e,restAttributes:t}=i;return yt(Ee(2,Zl,I({componentType:lm,componentProps:e,templateNames:["dropDownButtonTemplate","groupTemplate","itemTemplate"]},t)))},Wi=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(St),Object.getOwnPropertyDescriptors({placeholder:"",hoverStateEnabled:!0,searchEnabled:!1,defaultValue:null,isReactComponentWrapper:!0}))),B8={get placeholder(){return Wi.placeholder},get hoverStateEnabled(){return Hr.hoverStateEnabled},get searchEnabled(){return Wi.searchEnabled},get defaultValue(){return Wi.defaultValue},get readOnly(){return Wi.readOnly},get name(){return Wi.name},get validationError(){return Wi.validationError},get validationErrors(){return Wi.validationErrors},get validationMessageMode(){return Wi.validationMessageMode},get validationMessagePosition(){return Wi.validationMessagePosition},get validationStatus(){return Wi.validationStatus},get isValid(){return Wi.isValid},get isDirty(){return Wi.isDirty},get inputAttr(){return Wi.inputAttr},get className(){return Wi.className},get activeStateEnabled(){return Hr.activeStateEnabled},get disabled(){return Wi.disabled},get focusStateEnabled(){return Hr.focusStateEnabled},get tabIndex(){return Wi.tabIndex},get visible(){return Wi.visible},get label(){return Od.label},get labelMode(){return Od.labelMode},isReactComponentWrapper:!0},XN=(()=>{class i extends _t{constructor(t){super(t),this.state={value:this.props.value!==void 0?this.props.value:this.props.defaultValue}}get componentProps(){return I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value})}get restAttributes(){let t=I({},this.props,{value:this.props.value!==void 0?this.props.value:this.state.value});return ge(t,P8)}render(){let t=this.props;return k8({props:I({},t,{value:this.props.value!==void 0?this.props.value:this.state.value}),componentProps:this.componentProps,restAttributes:this.restAttributes})}}return i.defaultProps=B8,i})();var V8=["inputAttr","pageSize","pageSizeChange","pageSizes","parentRef"],L8=i=>{let{props:{inputAttr:e,pageSize:t,pageSizeChange:n,pageSizes:o},width:s}=i;return Ee(2,XN,{displayExpr:"text",valueExpr:"value",dataSource:o,value:t,valueChange:n,width:s,inputAttr:e})},N8={inputAttr:Object.freeze({"aria-label":O.format("dxPager-ariaPageSize")})},H8={get pageSize(){return Ct.pageSize},get inputAttr(){return N8.inputAttr}},QN=(()=>{class i extends Si{constructor(t){super(t),this.state={minWidth:10},this.updateWidth=this.updateWidth.bind(this)}createEffects(){return[new Le(this.updateWidth,[this.props,this.state.minWidth,this.props.pageSize,this.props.pageSizeChange,this.props.pageSizes,this.props.inputAttr])]}updateEffects(){var t;(t=this._effects[0])===null||t===void 0||t.update([this.props,this.state.minWidth,this.props.pageSize,this.props.pageSizeChange,this.props.pageSizes,this.props.inputAttr])}updateWidth(){this.setState(t=>({minWidth:ef(this.props.parentRef.current)||t.minWidth}))}get width(){return nf(this.state.minWidth,this.props.pageSizes.map(t=>t.value))}get restAttributes(){let t=this.props;return ge(t,V8)}render(){let t=this.props;return L8({props:I({},t),width:this.width,restAttributes:this.restAttributes})}}return i.defaultProps=H8,i})();var $8=["pageSize","pageSizeChange","pageSizes"],z8=i=>{let{pageSizesText:e}=i;return Zi(e.map(t=>{let{className:n,click:o,label:s,text:r}=t;return Ee(2,Ma,{className:n,label:s,onClick:o,children:r},r)}),0)};var W8={get pageSize(){return Ct.pageSize}},ZN=(()=>{class i extends _t{constructor(t){super(t),this.state={},this.__getterCache={},this.onPageSizeChange=this.onPageSizeChange.bind(this)}get pageSizesText(){return this.__getterCache.pageSizesText!==void 0?this.__getterCache.pageSizesText:this.__getterCache.pageSizesText=(()=>{let{pageSize:t,pageSizes:n}=this.props;return n.map((o,s)=>{let{text:r,value:a}=o;return{className:ti({[a===t?$N:NN]:!0,[zN]:s===0}),click:this.onPageSizeChange(a),label:Ii(O.getFormatter("dxPager-pageSize"),a||O.getFormatter("dxPager-pageSizesAllText")),text:r}})})()}onPageSizeChange(t){return()=>(this.props.pageSizeChange(t),this.props.pageSize)}get restAttributes(){let t=this.props;return ge(t,$8)}componentWillUpdate(t,n,o){(this.props.pageSize!==t.pageSize||this.props.pageSizes!==t.pageSizes||this.props.pageSizeChange!==t.pageSizeChange)&&(this.__getterCache.pageSizesText=void 0)}render(){let t=this.props;return z8({props:I({},t),pageSizesText:this.pageSizesText,restAttributes:this.restAttributes})}}return i.defaultProps=W8,i})();var G8=["isLargeDisplayMode","pageSize","pageSizeChange","pageSizes","rootElementRef"],K8=i=>{let{htmlRef:e,normalizedPageSizes:t,props:{isLargeDisplayMode:n,pageSize:o,pageSizeChange:s}}=i;return Ke(1,"div",HN,[n&&Ee(2,ZN,{pageSizes:t,pageSize:o,pageSizeChange:s}),!n&&Ee(2,QN,{parentRef:e,pageSizes:t,pageSize:o,pageSizeChange:s})],0,null,null,e)};function U8(){return O.getFormatter("dxPager-pageSizesAllText")()}var j8={isLargeDisplayMode:!0},q8={get pageSize(){return Ct.pageSize},get pageSizes(){return Ct.pageSizes},get isLargeDisplayMode(){return j8.isLargeDisplayMode}},JN=(()=>{class i extends Si{constructor(t){super(t),this.state={},this.htmlRef=at(),this.__getterCache={},this.setRootElementRef=this.setRootElementRef.bind(this)}createEffects(){return[new Le(this.setRootElementRef,[])]}setRootElementRef(){let{rootElementRef:t}=this.props;t&&(t.current=this.htmlRef.current)}get normalizedPageSizes(){return this.__getterCache.normalizedPageSizes!==void 0?this.__getterCache.normalizedPageSizes:this.__getterCache.normalizedPageSizes=(()=>{let{pageSizes:t}=this.props;return t.map(n=>n==="all"||n===0?{text:U8(),value:0}:{text:String(n),value:n})})()}get restAttributes(){let t=this.props;return ge(t,G8)}componentWillUpdate(t,n,o){super.componentWillUpdate(),this.props.pageSizes!==t.pageSizes&&(this.__getterCache.normalizedPageSizes=void 0)}render(){let t=this.props;return K8({props:I({},t),htmlRef:this.htmlRef,normalizedPageSizes:this.normalizedPageSizes,restAttributes:this.restAttributes})}}return i.defaultProps=q8,i})();var Y8=["className","displayMode","gridCompatibility","hasKnownLastPage","infoText","infoTextRef","infoTextVisible","isLargeDisplayMode","label","lightModeEnabled","maxPagesCount","onKeyDown","pageCount","pageIndex","pageIndexChange","pageSize","pageSizeChange","pageSizes","pageSizesRef","pagesCountText","pagesNavigatorVisible","pagesRef","rootElementRef","rtlEnabled","showInfo","showNavigationButtons","showPageSizes","totalCount","visible"],X8=i=>{let{aria:e,classes:t,infoVisible:n,isLargeDisplayMode:o,pageIndexSelectorVisible:s,pagesContainerVisibility:r,pagesContainerVisible:a,props:{hasKnownLastPage:l,infoText:d,infoTextRef:c,maxPagesCount:h,pageCount:p,pageIndex:g,pageIndexChange:C,pageSize:v,pageSizeChange:b,pageSizes:T,pageSizesRef:R,pagesCountText:U,pagesRef:Q,rtlEnabled:se,showNavigationButtons:re,showPageSizes:Re,totalCount:we,visible:We},restAttributes:gi,widgetRootElementRef:gt}=i;return yt(Ee(2,Il,I({rootElementRef:gt,rtlEnabled:se,classes:t,visible:We,aria:e},gi,{children:[Re&&Ee(2,JN,{rootElementRef:R,isLargeDisplayMode:o,pageSize:v,pageSizeChange:b,pageSizes:T}),a&&Ke(1,"div",kN,[n&&Ee(2,RN,{rootElementRef:c,infoText:d,pageCount:p,pageIndex:g,totalCount:we}),s&&Ke(1,"div",BN,Ee(2,YN,{hasKnownLastPage:l,isLargeDisplayMode:o,maxPagesCount:h,pageCount:p,pageIndex:g,pageIndexChange:C,pagesCountText:U,showNavigationButtons:re,totalCount:we}),2,null,null,Q)],0,{style:yl({visibility:r})})]})))},Q8=Object.create(Object.prototype,Object.assign(Object.getOwnPropertyDescriptors(Ct),Object.getOwnPropertyDescriptors({infoTextVisible:!0,isLargeDisplayMode:!0}))),eH=(()=>{class i extends Si{constructor(t){super(t),this.state={},this.widgetRootElementRef=at(),this.__getterCache={},this.setRootElementRef=this.setRootElementRef.bind(this),this.createFakeInstance=this.createFakeInstance.bind(this)}createEffects(){return[new Le(this.setRootElementRef,[])]}getChildContext(){return I({},this.context,{[Aa.id]:this.keyboardAction||Aa.defaultValue})}setRootElementRef(){let{rootElementRef:t}=this.props;t&&(t.current=this.widgetRootElementRef.current)}createFakeInstance(){return{option:()=>!1,element:()=>this.widgetRootElementRef.current,_createActionByOption:()=>t=>{var n,o;(n=(o=this.props).onKeyDown)===null||n===void 0||n.call(o,t)}}}get keyboardAction(){return this.__getterCache.keyboardAction!==void 0?this.__getterCache.keyboardAction:this.__getterCache.keyboardAction={registerKeyboardAction:(t,n)=>{let o=this.createFakeInstance();return Lg("pager",o,t,void 0,n)}}}get infoVisible(){let{infoTextVisible:t,showInfo:n}=this.props;return n&&t}get pageIndexSelectorVisible(){return this.props.pageSize!==0}get normalizedDisplayMode(){let{displayMode:t,lightModeEnabled:n}=this.props;return t==="adaptive"&&n!==void 0?n?"compact":"full":t}get pagesContainerVisible(){return!!this.props.pagesNavigatorVisible&&this.props.pageCount>0}get pagesContainerVisibility(){if(this.props.pagesNavigatorVisible==="auto"&&this.props.pageCount===1&&this.props.hasKnownLastPage)return"hidden"}get isLargeDisplayMode(){let t=this.normalizedDisplayMode,n=!1;return t==="adaptive"?n=this.props.isLargeDisplayMode:n=t==="full",n}get classes(){let t={[`${this.props.className}`]:!!this.props.className,[FN]:!0,[PN]:!this.isLargeDisplayMode};return ti(t)}get aria(){return{role:"navigation",label:this.props.label}}get restAttributes(){let t=this.props;return ge(t,Y8)}componentWillUpdate(t,n,o){super.componentWillUpdate(),this.props.onKeyDown!==t.onKeyDown&&(this.__getterCache.keyboardAction=void 0)}render(){let t=this.props;return X8({props:I({},t),widgetRootElementRef:this.widgetRootElementRef,keyboardAction:this.keyboardAction,infoVisible:this.infoVisible,pageIndexSelectorVisible:this.pageIndexSelectorVisible,pagesContainerVisible:this.pagesContainerVisible,pagesContainerVisibility:this.pagesContainerVisibility,isLargeDisplayMode:this.isLargeDisplayMode,classes:this.classes,aria:this.aria,restAttributes:this.restAttributes})}}return i.defaultProps=Q8,i})();var Z8=["className","defaultPageIndex","defaultPageSize","displayMode","gridCompatibility","hasKnownLastPage","infoText","label","lightModeEnabled","maxPagesCount","onKeyDown","pageCount","pageIndex","pageIndexChange","pageSize","pageSizeChange","pageSizes","pagesCountText","pagesNavigatorVisible","rtlEnabled","showInfo","showNavigationButtons","showPageSizes","totalCount","visible"],J8=i=>{let{pagerProps:e,restAttributes:t}=i;return yt(Ee(2,TN,I({contentTemplate:eH,pagerProps:e},t)))},tH=(()=>{class i extends Yn{constructor(t){super(t),this.__getterCache={},this.state={pageSize:this.props.pageSize!==void 0?this.props.pageSize:this.props.defaultPageSize,pageIndex:this.props.pageIndex!==void 0?this.props.pageIndex:this.props.defaultPageIndex},this.pageIndexChange=this.pageIndexChange.bind(this),this.pageSizeChange=this.pageSizeChange.bind(this)}createEffects(){return[zo()]}pageIndexChange(t){if(this.props.gridCompatibility){let n;this.setState(o=>(n=t+1,{pageIndex:n})),this.props.pageIndexChange(n)}else{let n;this.setState(o=>(n=t,{pageIndex:n})),this.props.pageIndexChange(n)}}get pageIndex(){return this.props.gridCompatibility?(this.props.pageIndex!==void 0?this.props.pageIndex:this.state.pageIndex)-1:this.props.pageIndex!==void 0?this.props.pageIndex:this.state.pageIndex}pageSizeChange(t){{let n;this.setState(o=>(n=t,{pageSize:n})),this.props.pageSizeChange(n)}}get className(){return this.props.gridCompatibility?ti({"dx-datagrid-pager":!0,[`${this.props.className}`]:!!this.props.className}):this.props.className}get pagerProps(){return this.__getterCache.pagerProps!==void 0?this.__getterCache.pagerProps:this.__getterCache.pagerProps=I({},I({},this.props,{pageSize:this.props.pageSize!==void 0?this.props.pageSize:this.state.pageSize,pageIndex:this.props.pageIndex!==void 0?this.props.pageIndex:this.state.pageIndex}),{className:this.className,pageIndex:this.pageIndex,pageIndexChange:t=>this.pageIndexChange(t),pageSizeChange:t=>this.pageSizeChange(t)})}get restAttributes(){let t=I({},this.props,{pageSize:this.props.pageSize!==void 0?this.props.pageSize:this.state.pageSize,pageIndex:this.props.pageIndex!==void 0?this.props.pageIndex:this.state.pageIndex});return ge(t,Z8)}componentWillUpdate(t,n,o){super.componentWillUpdate(),(this.props!==t||this.props.gridCompatibility!==t.gridCompatibility||this.props.className!==t.className||this.state.pageIndex!==n.pageIndex||this.props.pageIndex!==t.pageIndex||this.props.pageIndexChange!==t.pageIndexChange||this.props.pageSizeChange!==t.pageSizeChange)&&(this.__getterCache.pagerProps=void 0)}render(){let t=this.props;return J8({props:I({},t,{pageSize:this.props.pageSize!==void 0?this.props.pageSize:this.state.pageSize,pageIndex:this.props.pageIndex!==void 0?this.props.pageIndex:this.state.pageIndex}),pageIndexChange:this.pageIndexChange,pageIndex:this.pageIndex,pageSizeChange:this.pageSizeChange,className:this.className,pagerProps:this.pagerProps,restAttributes:this.restAttributes})}}return i.defaultProps=AN,i})();var Nu=class extends Jm{getProps(){let e=super.getProps();return e.onKeyDown=this._wrapKeyDownHandler(e.onKeyDown),e}get _propsInfo(){return{twoWay:[["pageSize","defaultPageSize","pageSizeChange"],["pageIndex","defaultPageIndex","pageIndexChange"]],allowNull:[],elements:[],templates:[],props:["defaultPageSize","pageSizeChange","defaultPageIndex","pageIndexChange","gridCompatibility","className","showInfo","infoText","lightModeEnabled","displayMode","maxPagesCount","pageCount","pagesCountText","visible","hasKnownLastPage","pagesNavigatorVisible","showPageSizes","pageSizes","rtlEnabled","showNavigationButtons","totalCount","label","onKeyDown","pageSize","pageIndex"]}}get _viewComponent(){return tH}};G("dxPager",Nu);var iH=Nu;var nH=function(i){return 1+(parseInt(i.pageIndex())||0)},gS=class extends Ce.View{init(){let e=this.getController("data");e.changed.add(t=>{if(t&&t.repaintChangesOnly){let n=this._pager;n?n.option({pageIndex:nH(e),pageSize:e.pageSize(),pageCount:e.pageCount(),totalCount:e.totalCount(),hasKnownLastPage:e.hasKnownLastPage()}):this.render()}else(!t||t.changeType!=="update"&&t.changeType!=="updateSelection"&&t.changeType!=="updateFocusedRow")&&(this._pager=null,this.render())})}dispose(){this._pager=null}optionChanged(e){let{name:t}=e,n=t==="pager",o=t==="paging",s=t==="dataSource",r=t==="scrolling",a=this.getController("data");if(n||o||r||s){if(e.handled=!0,a.skipProcessingPagingChange(e.fullName))return;(n||o)&&(this._pageSizes=null),s||(this._pager=null,this._invalidate(),W()&&n&&this.component&&this.component.resize())}}_renderCore(){let e=this,t=e.element().addClass(e.addWidgetPrefix("pager")),n=e.option("pager")??{},o=e.getController("data"),s=e.getController("keyboardNavigation"),r={maxPagesCount:10,pageIndex:nH(o),pageCount:o.pageCount(),pageSize:o.pageSize(),showPageSizes:n.showPageSizeSelector,showInfo:n.showInfo,displayMode:n.displayMode,pagesNavigatorVisible:n.visible,showNavigationButtons:n.showNavigationButtons,label:n.label,pageSizes:e.getPageSizes(),totalCount:o.totalCount(),hasKnownLastPage:o.hasKnownLastPage(),pageIndexChanged(a){o.pageIndex()!==a-1&&o.pageIndex(a-1)},pageSizeChanged(a){o.pageSize(a)},onKeyDown:a=>s&&s.executeAction("onKeyDown",a),useLegacyKeyboardNavigation:this.option("useLegacyKeyboardNavigation"),useKeyboard:this.option("keyboardNavigation.enabled")};if(f(n.infoText)&&(r.infoText=n.infoText),this._pager){this._pager.repaint();return}W()?this._pager=e._createComponent(t,iH,r):t.addClass("dx-pager").html('<div class="dx-pages"><div class="dx-page"></div></div>')}getPager(){return this._pager}getPageSizes(){let e=this,t=e.getController("data"),n=e.option("pager"),o=n&&n.allowedPageSizes,s=t.pageSize();return(!f(e._pageSizes)||!e._pageSizes.includes(s))&&(e._pageSizes=[],n&&(Array.isArray(o)?e._pageSizes=o:o&&s>1&&(e._pageSizes=[Math.floor(s/2),s,2*s]))),e._pageSizes}isVisible(){let e=this.getController("data"),t=this.option("pager"),n=t&&t.visible,o=this.option("scrolling");return n==="auto"&&(o&&(o.mode==="virtual"||o.mode==="infinite")?n=!1:n=e.pageCount()>1||e.isLoaded()&&!e.hasKnownLastPage()),!!n}getHeight(){return this.getElementHeight()}},oH={defaultOptions:()=>({pager:{visible:"auto",showPageSizeSelector:!1,allowedPageSizes:"auto",label:O.format("dxPager-ariaLabel")}}),views:{pagerView:gS}};H.registerModule("pager",oH);var sH="columns-separator-transparent";var vn="dxDataGridResizingReordering";var Hu=function(i){return i.option("allowColumnResizing")||i.getController("columns").isColumnOptionUsed("allowResizing")},rH=function(i){return i.option("allowColumnReordering")||i.getController("columns").isColumnOptionUsed("allowReordering")},fS=class extends Ce.View{init(){super.init(),this._tablePositionController=this.getController("tablePosition"),this._subscribeToCallback()}dispose(){this._unsubscribeFromCallback(),super.dispose()}optionChanged(e){e.name==="allowColumnResizing"&&(this._unsubscribeFromCallback(),e.value&&(this._subscribeToCallback(),this._invalidate())),super.optionChanged(e)}_renderCore(){let e=super._renderCore();return this.element().addClass(this.addWidgetPrefix("tracker")),this.hide(),e}_unsubscribeFromCallback(){this._positionChanged&&this._tablePositionController.positionChanged.remove(this._positionChanged)}_subscribeToCallback(){let e=this;e._positionChanged=function(t){let n=e.element();n&&n.hasClass(e.addWidgetPrefix("tracker"))&&(n.css({top:t.top}),xi(n,t.height))},this._tablePositionController.positionChanged.add(e._positionChanged)}isVisible(){return Hu(this)}show(){this.element().show()}hide(){this.element()&&this.element().hide()}setHeight(e){xi(this.element(),e)}},of=class extends Ce.View{_renderSeparator(){}_renderCore(e){let t=super._renderCore(e);return this._isShown=!0,this._renderSeparator(),this.hide(),t}show(){this._isShown=!0}hide(){this._isShown=!1}height(e){let t=this.element();if(t)if(f(e))xi(t,e);else return Y(t)}width(e){let t=this.element();if(t)if(f(e))Fo(t,e);else return z(t)}},_S=class extends of{init(){super.init(),this._tablePositionController=this.getController("tablePosition"),this._init()}dispose(){this._unsubscribeFromCallback(),super.dispose()}optionChanged(e){e.name==="allowColumnResizing"&&(e.value?(this._init(),this._invalidate(),this.hide(!0)):(this._unsubscribeFromCallback(),this._isTransparent=Hu(this),this.hide(!0))),super.optionChanged(e)}_renderSeparator(){super._renderSeparator(),this.element().addClass(this.addWidgetPrefix("columns-separator"))}_subscribeToCallback(){let e=this,t;e._positionChanged=function(n){t=e.element(),t&&(t.css({top:n.top}),xi(t,n.height))},e._tablePositionController.positionChanged.add(e._positionChanged)}_unsubscribeFromCallback(){this._positionChanged&&this._tablePositionController.positionChanged.remove(this._positionChanged)}_init(){this._isTransparent=Hu(this),this.isVisible()&&this._subscribeToCallback()}isVisible(){return this.option("showColumnHeaders")&&(rH(this)||Hu(this))}show(){let e=this,t=this.element();t&&!e._isShown&&(e._isTransparent?t.removeClass(e.addWidgetPrefix(sH)):t.show()),super.show()}hide(e){let t=this.element(),n=this.addWidgetPrefix(sH);t&&(this._isShown||e)&&(this._isTransparent?(t.addClass(n),t.css("left",""),t.show()):(t.hasClass(n)&&t.removeClass(n),t.hide())),super.hide()}moveByX(e){let t=this.element();t&&t.css("left",e===null?0:e-this._parentElement().offset().left)}changeCursor(e){e=f(e)?e:"";let t=this.element();t&&t.css("cursor",e)}},CS=class extends of{init(){super.init(),this.getController("data").loadingChanged.add(t=>{t||this.hide()})}_renderSeparator(){super._renderSeparator(),this.element().addClass("dx-block-separator").html("&nbsp;")}hide(){let e=this,t=this._parentElement(),n=this.element();n&&this._isShown&&n.css("display","none"),t&&!t.children(".dx-block-separator").length&&t.prepend(e.element()),super.hide()}isVisible(){let e=this.option("groupPanel"),t=this.option("columnChooser");return e&&e.visible||t&&t.enabled}show(e){let t=this.element();if(t&&!this._isShown)switch(e){case"group":this.element().css("display","block");break;case"columnChooser":(function(n){pe.stop(t,!0),pe.animate(t,{type:"slide",from:{width:0,display:n.display},to:n,duration:300,easing:"swing"})})({width:"100%",display:"block"});break;default:t.css("display","")}super.show()}},xS=class extends Ce.View{init(){super.init();let e=this.getController("data");this._controller=this.getController("draggingHeader"),this._columnsResizerViewController=this.getController("columnsResizer"),this._columnsController=this.getController("columns"),this._isDragging=!1,e.loadingChanged.add(t=>{let n=this.element();!t&&n&&n.hide()})}isDragging(){return this._isDragging}_getDraggingPanelByPos(e){let t;return x(this._dragOptions.draggingPanels,(n,o)=>{if(o){let s=o.getBoundingRect();if(s&&(s.bottom===void 0||e.y<s.bottom)&&(s.top===void 0||e.y>s.top)&&(s.left===void 0||e.x>s.left)&&(s.right===void 0||e.x<s.right))return t=o,!1}}),t}_renderCore(){this.element().addClass(`${this.addWidgetPrefix("drag-header")} ${this.addWidgetPrefix("text-content")} dx-widget`).hide()}_resetTargetColumnOptions(){let e=this._dropOptions;e.targetColumnIndex=-1,delete e.targetColumnElement,delete e.isLast,delete e.posX,delete e.posY}_getVisibleIndexObject(e,t){return f(e)?{columnIndex:t,rowIndex:e}:t}dispose(){let e=this.element();this._dragOptions=null,e&&e.parent().find(`.${this.addWidgetPrefix("drag-header")}`).remove()}isVisible(){let e=this._columnsController.getCommonSettings();return this.option("showColumnHeaders")&&(rH(this)||e.allowGrouping||e.allowHiding)}dragHeader(e){let{columnElement:t}=e,n=!!e.sourceColumn.type;this._isDragging=!0,this._dragOptions=e,this._dropOptions={sourceIndex:e.index,sourceColumnIndex:this._getVisibleIndexObject(e.rowIndex,e.columnIndex),sourceColumnElement:e.columnElement,sourceLocation:e.sourceLocation};let o=w.getDocument();this._onSelectStart=o.onselectstart,o.onselectstart=function(){return!1},this._controller.drag(this._dropOptions),this.element().css({textAlign:t&&t.css("textAlign"),height:t&&(n&&t.get(0).clientHeight||Y(t)),width:t&&(n&&t.get(0).clientWidth||z(t)),whiteSpace:t&&t.css("whiteSpace")}).addClass(this.addWidgetPrefix("drag-action")).toggleClass("dx-drag-command-cell",n).text(n?"":e.sourceColumn.caption),this.element().appendTo(wp.getSwatchContainer(t))}moveHeader(e){let t=e.event,{that:n}=t.data,o=Ye(t),s=n._columnsResizerViewController?n._columnsResizerViewController.isResizing():!1,r=n._dragOptions;if(n._isDragging&&!s){let a=n.element(),l=Math.abs(o.x-r.columnElement.offset().left-r.deltaX),d=Math.abs(o.y-r.columnElement.offset().top-r.deltaY);if(a.is(":visible")||l>5||d>5){a.show();let c=o.x-r.deltaX,h=o.y-r.deltaY;a.css({left:c,top:h}),n.dockHeader(o)}t.preventDefault()}}dockHeader(e){let t=this,n=t._getDraggingPanelByPos(e),o=t._controller,s=t._dropOptions,r=t._dragOptions;if(n){let a=t.option("rtlEnabled"),l=n.getName()==="columnChooser",d=l?"y":"x",c=n.getName(),h=c==="headers"?r.rowIndex:void 0,{sourceColumn:p}=r,g=n.getColumnElements(h,p?.ownerBand)||[],C=r.pointsByTarget=r.pointsByTarget||{},v=c==="columnChooser"?[]:C[c]||o._generatePointsByColumns(m({},r,{targetDraggingPanel:n,columns:n.getColumns(h),columnElements:g,isVerticalOrientation:l,startColumnIndex:c==="headers"&&u(g[0]).index()}));if(C[c]=v,s.targetLocation=c,v.length>0)for(let b=0;b<v.length;b++){let T=v[b+1]&&(v[b][d]+v[b+1][d])/2;if(T===void 0||(a&&d==="x"?e[d]>T:e[d]<T)){s.targetColumnIndex=t._getVisibleIndexObject(h,v[b].columnIndex),g[b]?(s.targetColumnElement=g.eq(b),s.isLast=!1):(s.targetColumnElement=g.last(),s.isLast=!0),s.posX=v[b].x,s.posY=v[b].y,o.dock(s);break}}else t._resetTargetColumnOptions(),o.dock(s)}}dropHeader(e){let t=e.event,{that:n}=t.data,o=n._controller;n.element().hide(),o&&n._isDragging&&o.drop(n._dropOptions),n.element().appendTo(n._parentElement()),n._dragOptions=null,n._dropOptions=null,n._isDragging=!1,w.getDocument().onselectstart=n._onSelectStart||null}},mS=function(i){return i.option("columnResizingMode")!=="widget"},vS=class extends Ce.ViewController{init(){this._subscribesToCallbacks=[],Hu(this)&&this._init()}dispose(){this._unsubscribes(),super.dispose()}optionChanged(e){super.optionChanged(e),e.name==="allowColumnResizing"&&(e.value?(this._init(),this._subscribeToEvents()):this._unsubscribes())}_isHeadersRowArea(e){if(this._columnHeadersView){let t=this._columnHeadersView.element();if(t){let n=t.offset().top,o=this._columnHeadersView.getHeadersRowHeight();return e>=n&&e<=n+o}}return!1}_isRtlParentStyle(){var e;return this.option("rtlEnabled")&&((e=this._$parentContainer)===null||e===void 0?void 0:e.parent().css("direction"))==="rtl"}_pointCreated(e,t,n){let o=mS(this),s=this.option("rtlEnabled"),r=this._isRtlParentStyle(),a=!o&&s&&!r?0:1;if(e.index>=a&&e.index<t+(!o&&(!s||r)?1:0)){e.columnIndex-=a;let l=n[e.columnIndex]||{},d=n[e.columnIndex+1]||{};return!(o?l.allowResizing&&d.allowResizing:l.allowResizing)}return!0}_getTargetPoint(e,t,n){if(e){for(let o=0;o<e.length;o++)if(!(e[o].x===e[0].x&&e[o+1]&&e[o].x===e[o+1].x)&&e[o].x-n<=t&&t<=e[o].x+n)return e[o]}return null}_moveSeparator(e){var t;let n=e.event,o=n.data,s=o._columnsSeparatorView.width(),r=mS(o),a=s/2,l=o._$parentContainer.offset(),d=l.left,c=Ye(n),h=o.option("rtlEnabled"),p=this._isRtlParentStyle(),g=(t=o._draggingHeaderView)===null||t===void 0?void 0:t.isDragging();if(o._isResizing&&o._resizingInfo){if((d<=c.x||!r&&p)&&(!r||c.x<=d+z(o._$parentContainer))&&o._updateColumnsWidthIfNeeded(c.x)){let C=o._columnHeadersView.getColumnElements().eq(o._resizingInfo.currentColumnIndex),v=C[0];if(v){let b=v.getBoundingClientRect().width;o._columnsSeparatorView.moveByX(C.offset().left+((r||p)&&h?0:b)),o._tablePositionController.update(o._targetPoint.y),n.preventDefault()}}}else g||(o._isHeadersRowArea(c.y)?(o._previousParentOffset&&(o._previousParentOffset.left!==l.left||o._previousParentOffset.top!==l.top)&&o.pointsByColumns(null),o._targetPoint=o._getTargetPoint(o.pointsByColumns(),c.x,s),o._previousParentOffset=l,o._isReadyResizing=!1,o._targetPoint?(o._columnsSeparatorView.changeCursor("col-resize"),o._columnsSeparatorView.moveByX(o._targetPoint.x-a),o._tablePositionController.update(o._targetPoint.y),o._isReadyResizing=!0,n.preventDefault()):(o._columnsSeparatorView.changeCursor(),o._columnsSeparatorView.moveByX(null))):(o.pointsByColumns(null),o._isReadyResizing=!1,o._columnsSeparatorView.changeCursor(),o._columnsSeparatorView.moveByX(null)))}_endResizing(e){let n=e.event.data;n._isResizing&&(n.pointsByColumns(null),n._resizingInfo=null,n._columnsSeparatorView.hide(),n._columnsSeparatorView.changeCursor(),n._trackerView.hide(),n._isReadyResizing=!1,n._isResizing=!1)}_getNextColumnIndex(e){return e+1}_setupResizingInfo(e){let t=this._targetPoint.columnIndex,n=this._getNextColumnIndex(t),o=this._columnHeadersView.getHeaderElement(t),s=this._columnHeadersView.getHeaderElement(n);this._resizingInfo={startPosX:e,currentColumnIndex:t,currentColumnWidth:o&&o.length>0?Ie(o[0]).width:0,nextColumnIndex:n,nextColumnWidth:s&&s.length>0?Ie(s[0]).width:0}}_startResizing(e){let t=e.event,n=t.data,o=Ye(t);if(gs(t)&&(n._isHeadersRowArea(o.y)?(n._targetPoint=n._getTargetPoint(n.pointsByColumns(),o.x,10),n._targetPoint&&(n._columnsSeparatorView.moveByX(n._targetPoint.x-n._columnsSeparatorView.width()/2),n._isReadyResizing=!0)):n._isReadyResizing=!1),n._isReadyResizing){n._setupResizingInfo(o.x),n._isResizing=!0,n._tablePositionController.update(n._targetPoint.y),n._columnsSeparatorView.show(),n._trackerView.show();let s=n.component.getScrollable();s&&n._isRtlParentStyle()&&(n._scrollRight=z(s.$content())-z(s.container())-s.scrollLeft()),t.preventDefault(),t.stopPropagation()}this.isResizing()&&this._editorFactoryController.loseFocus()}_generateColumnsTopYIndex(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,t=this,n=t._columnsController.getRowCount(),o={},s=r=>{let a=Math.ceil(r.x);return o[a]||(o[a]=r.y),!0};for(let r=0;r<n-1;r++){let a=t._columnHeadersView.getColumnElements(r);a&&a.length>0&&M.getPointsByColumns(a,s,!1,0,e)}return o}_generatePointsByColumns(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,t=this,n=t._generateColumnsTopYIndex(e),o=t._columnsController?t._columnsController.getVisibleColumns():[],s=t._columnHeadersView.getColumnElements();t._pointsByColumns=[],s&&s.length>0&&(t._pointsByColumns=M.getPointsByColumns(s,r=>t._pointCreated((a=>{let l=Math.ceil(a.x);return n[l]&&(a.y=n[l]),a})(r),s.length,o),!1,0,e))}_unsubscribeFromEvents(){this._moveSeparatorHandler&&_.off(w.getDocument(),D(ne.move,vn),this._moveSeparatorHandler),this._startResizingHandler&&_.off(this._$parentContainer,D(ne.down,vn),this._startResizingHandler),this._endResizingHandler&&(_.off(this._columnsSeparatorView.element(),D(ne.up,vn),this._endResizingHandler),_.off(w.getDocument(),D(ne.up,vn),this._endResizingHandler))}_subscribeToEvents(){this._moveSeparatorHandler=this.createAction(this._moveSeparator),this._startResizingHandler=this.createAction(this._startResizing),this._endResizingHandler=this.createAction(this._endResizing),_.on(w.getDocument(),D(ne.move,vn),this,this._moveSeparatorHandler),_.on(this._$parentContainer,D(ne.down,vn),this,this._startResizingHandler),_.on(this._columnsSeparatorView.element(),D(ne.up,vn),this,this._endResizingHandler),_.on(w.getDocument(),D(ne.up,vn),this,this._endResizingHandler)}_updateColumnsWidthIfNeeded(e){let t,n=!1,o=this._rowsView.contentWidth(),s=this._resizingInfo,r=this._columnsController,a=r.getVisibleColumns(),l=this._columnsSeparatorView.width(),d=mS(this),c=d&&this.option("adaptColumnWidthByRatio")&&!this.option("columnAutoWidth"),h=this.option("rtlEnabled"),p=this._isRtlParentStyle(),g=a[s.currentColumnIndex],C=a[s.nextColumnIndex];function v(U){return B(U)&&U.endsWith("%")}function b(U,Q,se,re){if(U){let Re=U.width;Re&&(re=v(Re)),re?(r.columnOption(U.index,"visibleWidth",Q),r.columnOption(U.index,"width",`${(Q/se*100).toFixed(3)}%`)):(r.columnOption(U.index,"visibleWidth",null),r.columnOption(U.index,"width",Q))}}t=e-s.startPosX,(d||p)&&h&&(t=-t);let{cellWidth:T,nextCellWidth:R}=function(U){let Q,se,re,Re=s.currentColumnWidth+U,we=g&&g.minWidth||l,We={};return Re>=we?We.cellWidth=Re:(We.cellWidth=we,re=!0),d&&(se=s.nextColumnWidth-U,Q=C&&C.minWidth||l,se>=Q?re?We.nextCellWidth=s.nextColumnWidth-(U+we-Re):We.nextCellWidth=se:(We.nextCellWidth=Q,We.cellWidth=s.currentColumnWidth+(U-Q+se))),We}(t);if(n=g.width!==T,n){if(r.beginUpdate(),T=Math.floor(T),o=function(U,Q){if(Q.every(re=>re.width)){let re=Q.reduce((Re,we)=>(v(we.width)&&(Re+=parseFloat(we.width)),Re),0);re>100&&(U=U/re*100)}return U}(o,a),b(g,T,o,c),d)R=Math.floor(R),b(C,R,o,c);else{let U=this._columnHeadersView.getColumnWidths();if(U[s.currentColumnIndex]=T,!(U.reduce((se,re)=>se+re,0)>this._rowsView.contentWidth())){let se=M.getLastResizableColumnIndex(a);se>=0&&r.columnOption(a[se].index,"visibleWidth","auto")}for(let se=0;se<U.length;se++)a[se]&&a[se]!==g&&a[se].width===void 0&&r.columnOption(a[se].index,"width",U[se])}if(r.endUpdate(),!d){this.component.updateDimensions();let U=this.component.getScrollable();if(U&&p){let Q=z(U.$content())-z(U.container())-this._scrollRight;U.scrollTo({left:Q})}}}return n}_subscribeToCallback(e,t){e.add(t),this._subscribesToCallbacks.push({callback:e,handler:t})}_unsubscribeFromCallbacks(){for(let e=0;e<this._subscribesToCallbacks.length;e++){let t=this._subscribesToCallbacks[e];t.callback.remove(t.handler)}this._subscribesToCallbacks=[]}_unsubscribes(){this._unsubscribeFromEvents(),this._unsubscribeFromCallbacks()}_init(){let e=()=>{this._isResizing||this.pointsByColumns(null)},t=s=>{this._scrollLeft!==s.left&&(this._scrollLeft=s.left,this.pointsByColumns(null))};this._columnsSeparatorView=this.getView("columnsSeparatorView"),this._columnHeadersView=this.getView("columnHeadersView"),this._trackerView=this.getView("trackerView"),this._rowsView=this.getView("rowsView"),this._columnsController=this.getController("columns"),this._tablePositionController=this.getController("tablePosition"),this._editorFactoryController=this.getController("editorFactory"),this._draggingHeaderView=this.component.getView("draggingHeaderView"),this._$parentContainer=this.component.$element(),this._subscribeToCallback(this._columnHeadersView.renderCompleted,e),this._subscribeToCallback(this._columnHeadersView.resizeCompleted,e),this._subscribeToCallback(this._columnsSeparatorView.renderCompleted,()=>{this._unsubscribeFromEvents(),this._subscribeToEvents()}),this._subscribeToCallback(this._rowsView.renderCompleted,()=>{this._rowsView.scrollChanged.remove(t),this._rowsView.scrollChanged.add(t)});let n=this._rowsView.getScrollbarWidth()!==0,o=0;this._subscribeToCallback(this._tablePositionController.positionChanged,s=>{if(this._isResizing&&!this._rowsView.isResizing){let r=this._rowsView.getScrollbarWidth()!==0;n!==r||o&&o!==s.height?(n=r,o=s.height,this.component.updateDimensions()):this._rowsView.updateFreeSpaceRowHeight()}o=s.height})}isResizing(){return this._isResizing}pointsByColumns(e){if(e!==void 0)this._pointsByColumns=e;else return this._pointsByColumns||this._generatePointsByColumns(),this._pointsByColumns}},bS=class extends Ce.ViewController{constructor(e){super(e),this.positionChanged=ue()}init(){super.init(),this._columnsResizerController=this.getController("columnsResizer"),this._columnHeadersView=this.getView("columnHeadersView"),this._rowsView=this.getView("rowsView"),this._pagerView=this.getView("pagerView"),this._rowsView.resizeCompleted.add(()=>{if(this.option("allowColumnResizing")){let e=this._columnsResizerController._targetPoint;this.update(e?e.y:null)}})}update(e){let t={},n=this._columnHeadersView.element(),o=n&&n.offset(),s=o&&o.top||0,r=f(e)?Math.abs(e-s):0,a=this._columnHeadersView?this._columnHeadersView.getHeight():0,l=this._rowsView.getScrollbarWidth(!0),d=this._rowsView?this._rowsView.height()-l:0,c=this.component.getView("draggingHeaderView");t.height=a,(this._columnsResizerController.isResizing()||c.isDragging())&&(t.height+=d-r),e!==null&&n&&n.length&&(t.top=n[0].offsetTop+r),this.positionChanged.fire(t)}},yS=class extends Ce.ViewController{init(){super.init(),this._columnsController=this.getController("columns"),this._tablePositionController=this.getController("tablePosition"),this._columnHeadersView=this.getView("columnHeadersView"),this._columnsSeparatorView=this.getView("columnsSeparatorView"),this._draggingHeaderView=this.getView("draggingHeaderView"),this._rowsView=this.getView("rowsView"),this._blockSeparatorView=this.getView("blockSeparatorView"),this._headerPanelView=this.getView("headerPanel"),this._columnChooserView=this.getView("columnChooserView");let e=()=>{if(this._draggingHeaderView){let t=[this._columnChooserView,this._columnHeadersView,this._headerPanelView];this._unsubscribeFromEvents(this._draggingHeaderView,t),this._subscribeToEvents(this._draggingHeaderView,t)}};this._columnHeadersView.renderCompleted.add(e),this._headerPanelView&&this._headerPanelView.renderCompleted.add(e),this._columnChooserView&&this._columnChooserView.renderCompleted.add(e)}dispose(){this._draggingHeaderView&&this._unsubscribeFromEvents(this._draggingHeaderView,[this._columnChooserView,this._columnHeadersView,this._headerPanelView])}_generatePointsByColumns(e){let t=this;return this.isCustomGroupColumnPosition=this.checkIsCustomGroupColumnPosition(e),M.getPointsByColumns(e.columnElements,o=>t._pointCreated(o,e.columns,e.targetDraggingPanel.getName(),e.sourceColumn),e.isVerticalOrientation,e.startColumnIndex)}checkIsCustomGroupColumnPosition(e){let t=!0;for(let n=0;n<e.columns.length;n+=1){let o=e.columns[n];if(o.command==="expand"&&!t)return!0;o.command||(t=!1)}return!1}_pointCreated(e,t,n,o){let s=t[e.columnIndex],r=t[e.columnIndex-1],a=r?.command==="expand",l=s?.command==="expand"&&r?.command!=="expand",d=o&&!o.allowReordering,c=!(s!=null&&s.allowReordering)&&!(r!=null&&r.allowReordering);switch(n){case"columnChooser":return!0;case"headers":if(d)return!0;if(!l)return a||c;if(this.isCustomGroupColumnPosition)return!1;for(;((h=t[e.columnIndex])===null||h===void 0?void 0:h.command)==="expand";){var h;e.columnIndex+=1}return!1;default:return t.length===0}}_subscribeToEvents(e,t){let n=this;x(t,(o,s)=>{if(s){let r,a=s.getRowCount?s.getRowCount():1,l=s.getName(),d=function(c,h){if(!h)return;let p=u(h),g=r[c];g&&s.allowDragging(g)&&(p.addClass(n.addWidgetPrefix("drag-action")),_.on(p,D(Ds,vn),n.createAction(C=>{let v=C.event,b=Ye(v);e.dragHeader({deltaX:b.x-u(v.currentTarget).offset().left,deltaY:b.y-u(v.currentTarget).offset().top,sourceColumn:g,index:g.index,columnIndex:c,columnElement:p,sourceLocation:l,draggingPanels:t,rowIndex:n._columnsController.getRowIndex(g.index,!0)})})),_.on(p,D(vo,vn),{that:e},n.createAction(e.moveHeader)),_.on(p,D(Ts,vn),{that:e},n.createAction(e.dropHeader)))};for(let c=0;c<a;c++){let h=s.getColumnElements(c)||[];h.length&&(r=s.getColumns(c)||[],x(h,d))}}})}_unsubscribeFromEvents(e,t){let n=this;x(t,(o,s)=>{if(s){let r=s.getColumnElements()||[];x(r,(a,l)=>{let d=u(l);_.off(d,D(Ds,vn)),_.off(d,D(vo,vn)),_.off(d,D(Ts,vn)),d.removeClass(n.addWidgetPrefix("drag-action"))})}})}_getSeparator(e){return e==="headers"?this._columnsSeparatorView:this._blockSeparatorView}hideSeparators(e){let t=this._blockSeparatorView,n=this._columnsSeparatorView;this._animationColumnIndex=void 0,t&&t.hide(),e!=="block"&&n&&n.hide()}allowDrop(e){return this._columnsController.allowMoveColumn(e.sourceColumnIndex,e.targetColumnIndex,e.sourceLocation,e.targetLocation)}drag(e){let{sourceIndex:t}=e,{sourceLocation:n}=e,{sourceColumnElement:o}=e,s=this._columnHeadersView,r=this._rowsView;o&&(o.css({opacity:.5}),n==="headers"&&(s&&s.setRowsOpacity(t,.5),r&&r.setRowsOpacity(t,.5)))}dock(e){let t=this,n=$(e.targetColumnIndex)?e.targetColumnIndex.columnIndex:e.targetColumnIndex,{sourceLocation:o}=e,{targetLocation:s}=e,r=t._getSeparator(s),a=n>=0;t._columnHeadersView.element().find(".dx-header-row").toggleClass(t.addWidgetPrefix("drop-highlight"),o!=="headers"&&s==="headers"&&!a),r&&(t.allowDrop(e)&&a?s==="group"||s==="columnChooser"?function(){t._animationColumnIndex!==n&&(t.hideSeparators(),r.element()[e.isLast?"insertAfter":"insertBefore"](e.targetColumnElement),t._animationColumnIndex=n,r.show(s))}():(t.hideSeparators("block"),t._tablePositionController.update(e.posY),r.moveByX(e.posX-r.width()),r.show()):t.hideSeparators())}drop(e){let{sourceColumnElement:t}=e;if(t&&(t.css({opacity:""}),this._columnHeadersView.setRowsOpacity(e.sourceIndex,""),this._rowsView.setRowsOpacity(e.sourceIndex,""),this._columnHeadersView.element().find(".dx-header-row").removeClass(this.addWidgetPrefix("drop-highlight"))),this.allowDrop(e)){let n=this._getSeparator(e.targetLocation);n&&n.hide(),this._columnsController.moveColumn(e.sourceColumnIndex,e.targetColumnIndex,e.sourceLocation,e.targetLocation)}}},eZ=i=>class extends i{_needUpdateRowHeight(e){let t=this.option("wordWrapEnabled"),n=this._columnsResizerController.isResizing();return super._needUpdateRowHeight.apply(this,arguments)||e>0&&!!t&&!!n}},tZ=i=>class extends i{renderFocusOverlay(){if(!this._columnsResizerController.isResizing())return super.renderFocusOverlay.apply(this,arguments)}},$r={views:{columnsSeparatorView:_S,blockSeparatorView:CS,draggingHeaderView:xS,trackerView:fS},controllers:{draggingHeader:yS,tablePosition:bS,columnsResizer:vS},extenders:{views:{rowsView:eZ},controllers:{editorFactory:tZ}}};var _st=$r.views.draggingHeaderView,Cst=$r.controllers.draggingHeader,xst=$r.views.columnsSeparatorView,vst=$r.controllers.tablePosition,bst=$r.controllers.columnsResizer,yst=$r.views.trackerView;H.registerModule("columnsResizingReordering",$r);var iZ=(i,e)=>i.length===e.length&&!Object.keys(i).some(t=>i[t]!==e[t]),nZ=(i,e)=>ve(i,e,{maxDepth:4}),oZ=(i,e,t,n)=>{let o=i,s=e;return function(){for(var r=arguments.length,a=new Array(r),l=0;l<r;l++)a[l]=arguments[l];return n(a,o)||(o=a,s=t(...o)),s}},sZ={compareType:"reference"},OS=function(i){let{compareType:e}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:sZ,t=null;return function(){for(var n=arguments.length,o=new Array(n),s=0;s<n;s++)o[s]=arguments[s];if(!t){let r=i(...o);return t=oZ(o,r,i,e==="reference"?iZ:nZ),r}return t(...o)}};var sf={ariaColIndex:"aria-colindex",dragCell:"dx-drag-cell"},rf="rowsview",aH="table",lH="edit-form";var af="dx-data-row",dH="dx-group-row",cH="dx-header-row",uH="edit-form-item",SS="dx-master-detail-row",lf="dx-freespace-row",hH="dx-virtual-row",df="dx-master-detail-cell";var pH="dx-dropdowneditor-overlay",$u="dx-command-expand",gH="dx-command-adaptive",cf="dx-command-select",ES="dx-command-edit",uf="[class^=dx-command]",zu="dx-cell-focus-disabled",mH="dxDateBox",wS="dx-state-focused",fH="dx-widget",_H="dx-revert-button",IS="dx-focused",hf="delete",Sd=`
  input:not([type="hidden"]):not([disabled]),
  textarea:not([disabled]),
  a:not([disabled]),
  select:not([disabled]),
  button:not([disabled]),
  [tabindex]:not([disabled]),
  .dx-checkbox:not([disabled],.dx-state-readonly)
`,DS=`${Sd}, .dx-dropdowneditor-icon`;var TS="row",AS="cell",MS="columnHeadersView",CH="rowsView",xH=["shift","control","alt"];var rZ=i=>i.attr(sf.dragCell)!==void 0,aZ=i=>[`[${sf.ariaColIndex}="${i+1}"]`,`:not([${sf.dragCell}])`,":not([aria-hidden=true])"].join(""),lZ=(i,e)=>i.filter(aZ(e)).first(),RS={isDragCell:rZ,getCellToFocus:lZ};function Ed(i){return i&&i.hasClass(dH)}function vH(i){return i&&i.hasClass("dx-datagrid-group-footer")}function bH(i){return i&&i.hasClass(SS)}function yH(i){return i&&i.hasClass(SS)&&i.hasClass(lH)}function wd(i){return i&&i.hasClass(af)}function OH(i){return!i||i.hasClass(lf)||i.hasClass(hH)}function FS(i,e){return!i._isRowEditMode()&&e&&!e.hasClass(cf)&&e.hasClass(Vr)}function Rn(i){return f(i)&&i.length>0}function pf(){return F.current().deviceType!=="desktop"}function PS(i){return!!i.parent(`.${cH}`).length}function SH(i,e){return i.option("rtlEnabled")?!(e.fixedPosition==="right"||f(e.command)&&!f(e.fixedPosition)):!(!f(e.fixedPosition)||e.fixedPosition==="left")}function EH(i){let e=i.getController("keyboardNavigation");return e._isVirtualScrolling()?i.option("focusedRowIndex")===e.getRowIndex():!1}var wH=i=>class extends i{rowsViewFocusHandler(e){let t=u(e.target);this.translateFocusIfNeed(e,t),super.rowsViewFocusHandler(e)}rowsViewFocusOutHandler(){super.rowsViewFocusOutHandler(),this.makeScrollableFocusableIfNeed()}translateFocusIfNeed(e,t){let n=this.isScrollableNeedFocusable(),o=this._isFixedColumn(0);if(!n||!o)return;let s=this._rowsView.getCell({rowIndex:0,columnIndex:0}),r=!!s.attr("tabindex"),a=t.is(this._$firstNotFixedCell);r&&a&&(e.preventDefault(),this._focus(s))}renderCompleted(e){this._$firstNotFixedCell=this.getFirstNotFixedCell(),this.makeScrollableFocusableIfNeed(),super.renderCompleted(e)}_focus(e,t,n){super._focus(e,t,n),this.makeScrollableFocusableIfNeed()}_tabKeyHandler(e,t){let o=!(f(this._focusedCellPosition)&&!dt(this._focusedCellPosition))||!e.shift&&this._isLastValidCell(this._focusedCellPosition)||e.shift&&this._isFirstValidCell(this._focusedCellPosition),s=this.isScrollableNeedFocusable();if(o&&s){var r;(r=this._$firstNotFixedCell)===null||r===void 0||r.removeAttr("tabIndex")}super._tabKeyHandler(e,t)}getFirstNotFixedCell(){var e;let n=this._columnsController.getVisibleColumns().findIndex(s=>{let{fixed:r}=s;return!r}),o=(e=this._editingController)===null||e===void 0?void 0:e.isEditing();return n===-1||o?void 0:this._rowsView._getCellElement(0,n)}isScrollableNeedFocusable(){var e,t;let n=!!this._rowsView.getScrollable(),o=!!((e=this._rowsView._fixedTableElement)!==null&&e!==void 0&&e.length),s=!!((t=this._rowsView.getCellElements(0))!==null&&t!==void 0&&t.length);return n&&o&&s}makeScrollableFocusableIfNeed(){!this.isScrollableNeedFocusable()||!this._$firstNotFixedCell||this._applyTabIndexToElement(this._$firstNotFixedCell)}};var kS=class extends Ce.ViewController{init(){if(this._dataController=this.getController("data"),this._selectionController=this.getController("selection"),this._editingController=this.getController("editing"),this._headerPanel=this.getView("headerPanel"),this._rowsView=this.getView("rowsView"),this._columnsController=this.getController("columns"),this._editorFactory=this.getController("editorFactory"),this._focusController=this.getController("focus"),this._adaptiveColumnsController=this.getController("adaptiveColumns"),this._columnResizerController=this.getController("columnsResizer"),this._memoFireFocusedCellChanged=OS(this._memoFireFocusedCellChanged.bind(this),{compareType:"value"}),this._memoFireFocusedRowChanged=OS(this._memoFireFocusedRowChanged.bind(this),{compareType:"value"}),this.focusedHandlerWithContext=this.focusedHandlerWithContext||this.focusedHandler.bind(this),this.renderCompletedWithContext=this.renderCompletedWithContext||this.renderCompleted.bind(this),this.rowsViewFocusHandlerContext=this.rowsViewFocusHandlerContext||this.rowsViewFocusHandler.bind(this),this.rowsViewFocusOutHandlerContext=this.rowsViewFocusOutHandlerContext??this.rowsViewFocusOutHandler.bind(this),this._updateFocusTimeout=null,this._fastEditingStarted=!1,this._focusedCellPosition={},this._canceledCellPosition=null,this.isKeyboardEnabled()){var e;hP(),(e=this._editorFactory)===null||e===void 0||e.focused.add(this.focusedHandlerWithContext),this.createAction("onKeyDown")}else{var t;Ib(),(t=this._editorFactory)===null||t===void 0||t.focused.remove(this.focusedHandlerWithContext)}this.initViewHandlers(),this.initDocumentHandlers()}dispose(){super.dispose(),this._resetFocusedView(),Kn.off(this._keyDownListener),_.off(w.getDocument(),D(ne.down,"dxDataGridKeyboardNavigation"),this._documentClickHandler),clearTimeout(this._updateFocusTimeout),Ib()}focusedHandler(e){this.setupFocusedView(),this._isNeedScroll&&e.is(":visible")&&this._focusedView&&this._focusedView.getScrollable()&&(this._focusedView._scrollToElement(e),this._isNeedScroll=!1)}rowsViewFocusHandler(e){let t=u(e.target),n=u(e.relatedTarget).closest(this._rowsView.element()).length,o=t.is("a");if(e.relatedTarget&&o&&!n&&this._isEventInCurrentGrid(e)){let a=this._getFocusedCell();a=Rn(a)?a:this._rowsView.getCellElements(0).filter("[tabindex]").eq(0),t.closest(a).length||(e.preventDefault(),_.trigger(a,"focus"))}let s=t.is("td"),r=(this.option("focusedRowIndex")??-1)<0;s&&r&&this._updateFocusedCellPosition(t)}rowsViewFocusOutHandler(){this._toggleInertAttr(!1)}subscribeToRowsViewFocusEvent(){var e;let t=(e=this._rowsView)===null||e===void 0?void 0:e.element();_.on(t,"focusin",this.rowsViewFocusHandlerContext),_.on(t,"focusout",this.rowsViewFocusOutHandlerContext)}unsubscribeFromRowsViewFocusEvent(){var e;let t=(e=this._rowsView)===null||e===void 0?void 0:e.element();_.off(t,"focusin",this.rowsViewFocusHandlerContext),_.off(t,"focusout",this.rowsViewFocusOutHandlerContext)}renderCompleted(e){let t=this._rowsView.element(),n=!e||e.changeType==="refresh",o=this._focusedView&&this._focusedView.name===this._rowsView.name,s=!1,r=e&&(e.changeType==="append"||e.changeType==="prepend"),l=u(w.getRootNode(t.get&&t.get(0))).find(":focus"),d=this._isFocusedElementCorrect(l,t,e);this.unsubscribeFromRowsViewFocusEvent(),this.subscribeToRowsViewFocusEvent(),this.initPointerEventHandler(),this.initKeyDownHandler(),this._setRowsViewAttributes(),o&&d&&(s=this._isNeedFocus?!r:this._isHiddenFocus&&n&&!(e!=null&&e.virtualColumnsScrolling),s&&this._updateFocus(!0))}_isFocusedElementCorrect(e,t,n){if(e.length&&!e.closest(t).length)return!1;if(!e.length&&n!==null&&n!==void 0&&n.virtualColumnsScrolling){var o;let s=((o=this._focusedCellPosition)===null||o===void 0?void 0:o.columnIndex)??-1;return s-this._getFocusedColumnIndexOffset(s)>=0}return!0}initViewHandlers(){var e;this.unsubscribeFromRowsViewFocusEvent(),this.unsubscribeFromPointerEvent(),this.unsubscribeFromKeyDownEvent(),(e=this._rowsView)===null||e===void 0||(e=e.renderCompleted)===null||e===void 0||e.remove(this.renderCompletedWithContext),this.isKeyboardEnabled()&&this._rowsView.renderCompleted.add(this.renderCompletedWithContext)}initDocumentHandlers(){let e=w.getDocument();this._documentClickHandler=this._documentClickHandler||this.createAction(t=>{var n;let o=u(t.event.target),s=`.${this.addWidgetPrefix(aH)}`,r=`.${this.addWidgetPrefix(rf)}`,a=`.${pH}`;if(!!o.closest(s).length&&!Lo(o)){t.event.preventDefault();return}let d=this._isEventInCurrentGrid(t.event)&&!!o.closest(r).length,c=!!o.closest(a).length,h=!!((n=this._columnResizerController)!==null&&n!==void 0&&n.isResizing());!d&&!c&&!h&&((!this._focusedView||o.closest(this._focusedView.element()).length===0)&&this._resetFocusedCell(!0),this._resetFocusedView())}),_.off(e,D(ne.down,"dxDataGridKeyboardNavigation"),this._documentClickHandler),this.isKeyboardEnabled()&&_.on(e,D(ne.down,"dxDataGridKeyboardNavigation"),this._documentClickHandler)}_setRowsViewAttributes(){let e=this._getRowsViewElement();!this._dataController.getVisibleRows().length&&this._applyTabIndexToElement(e)}unsubscribeFromPointerEvent(){let e=pf()?oe:ne.down,t=this._getRowsViewElement();this._pointerEventAction&&_.off(t,D(e,"dxDataGridKeyboardNavigation"),this._pointerEventAction)}subscribeToPointerEvent(){let e=pf()?oe:ne.down,t=this._getRowsViewElement(),n=`.${So} > td, .${So}`;_.on(t,D(e,"dxDataGridKeyboardNavigation"),n,this._pointerEventAction)}initPointerEventHandler(){this._pointerEventAction=this._pointerEventAction||this.createAction(this._pointerEventHandler),this.unsubscribeFromPointerEvent(),this.subscribeToPointerEvent()}unsubscribeFromKeyDownEvent(){Kn.off(this._keyDownListener)}subscribeToKeyDownEvent(){let e=this._getRowsViewElement();this._keyDownListener=Kn.on(e,null,t=>this._keyDownHandler(t))}initKeyDownHandler(){this._keyDownListener&&this.unsubscribeFromKeyDownEvent(),this.subscribeToKeyDownEvent()}optionChanged(e){switch(e.name){case"keyboardNavigation":e.fullName==="keyboardNavigation.enabled"&&this.init(),e.handled=!0;break;case"useLegacyKeyboardNavigation":this.init(),e.handled=!0;break;default:super.optionChanged(e)}}isRowFocusType(){return this.focusType===TS}isCellFocusType(){return this.focusType===AS}setRowFocusType(){this.option("focusedRowEnabled")&&(this.focusType=TS)}setCellFocusType(){this.focusType=AS}_keyDownHandler(e){var t;let n=!0;this._isNeedFocus=!0,this._isNeedScroll=!0;let o=this._processOnKeyDown(e),s=(t=this._editingController)===null||t===void 0?void 0:t.isEditing(),{originalEvent:r}=e;if(r.isDefaultPrevented()){this._isNeedFocus=!1,this._isNeedScroll=!1;return}if(!xH.includes(e.keyName)&&this._updateFocusedCellPositionByTarget(r.target),!o){switch(e.keyName){case"leftArrow":case"rightArrow":this._leftRightKeysHandler(e,s),o=!0;break;case"upArrow":case"downArrow":e.ctrl?nu("rowsView",this,r):this._upDownKeysHandler(e,s),o=!0;break;case"pageUp":case"pageDown":this._pageUpDownKeyHandler(e),o=!0;break;case"space":o=this._spaceKeyHandler(e,s);break;case"A":ot(e.originalEvent)?(this._ctrlAKeyHandler(e,s),o=!0):o=this._beginFastEditing(e.originalEvent);break;case"tab":this._tabKeyHandler(e,s),o=!0;break;case"enter":this._enterKeyHandler(e,s),o=!0;break;case"escape":o=this._escapeKeyHandler(e,s);break;case"F":ot(e.originalEvent)?(this._ctrlFKeyHandler(e),o=!0):o=this._beginFastEditing(e.originalEvent);break;case"F2":this._f2KeyHandler(),o=!0;break;case"del":case"backspace":this._isFastEditingAllowed()&&!this._isFastEditingStarted()&&(o=this._beginFastEditing(r,!0))}!o&&!this._beginFastEditing(r)&&(this._isNeedFocus=!1,this._isNeedScroll=!1,n=!1),n&&r.stopPropagation()}}_processOnKeyDown(e){let{originalEvent:t}=e,n={handled:!1,event:t};return this.executeAction("onKeyDown",n),e.ctrl=t.ctrlKey,e.alt=t.altKey,e.shift=t.shiftKey,!!n.handled}_closeEditCell(){let e=y();return setTimeout(()=>{this._editingController.closeEditCell().always(e.resolve)}),e}_leftRightKeysHandler(e,t){let n=this.getVisibleRowIndex(),o=e.originalEvent,s=this._focusedView&&this._focusedView.getRow(n),r=this._getDirectionCodeByKey(e.keyName),a=this._isFastEditingStarted();if((!t||a)&&wd(s)){this.setCellFocusType(),a&&this._closeEditCell(),this._isVirtualColumnRender()&&this._processVirtualHorizontalPosition(r);let d=this._getNextCell(r);Rn(d)&&this._arrowKeysHandlerFocusCell(o,d,r),o&&o.preventDefault()}}isInsideMasterDetail(e){let t=e.closest(`.${df}`);return!!t.get(0)&&this.elementIsInsideGrid(t)&&!e.is(t)}_upDownKeysHandler(e,t){var n,o;let s=this.getVisibleRowIndex(),r=this._focusedView&&this._focusedView.getRow(s),a=e.originalEvent,l=e.keyName==="upArrow",d=this._dataController.dataSource(),c=(n=this._editingController)===null||n===void 0||(o=n.isEditRowByIndex)===null||o===void 0?void 0:o.call(n,s),h=this._isFastEditingStarted(),p=this.isInsideMasterDetail(u(a?.target));if((!c||!t||h)&&r&&!yH(r)&&!p){if(h&&this._closeEditCell(),!this._navigateNextCell(a,e.keyName)&&this._isVirtualRowRender()&&l&&d&&!d.isLoading()){let C=X(r),v=this._focusedCellPosition.rowIndex-1;this._scrollBy(0,-C,v,a)}a&&a.preventDefault()}}_pageUpDownKeyHandler(e){let t=this._dataController.pageIndex(),n=this._dataController.pageCount(),o=this.option("paging.enabled"),s=e.keyName==="pageUp",r=s?-1:1,a=this._rowsView.getScrollable();o&&!this._isVirtualScrolling()?(s?t>0:t<n-1)&&!this._isVirtualScrolling()&&(this._dataController.pageIndex(t+r),e.originalEvent.preventDefault()):a&&Y(a.container())<Y(a.$content())&&(this._scrollBy(0,Y(a.container())*r),e.originalEvent.preventDefault())}_spaceKeyHandler(e,t){let n=this.getVisibleRowIndex(),o=u(e.originalEvent&&e.originalEvent.target);if(this.option("selection")&&this.option("selection").mode!=="none"&&!t){let s=this._getElementType(o)==="row"&&this.isRowFocusType()&&wd(o);return o.hasClass(cf)&&this.option("selection.showCheckBoxesMode")==="onClick"&&this._selectionController.startSelectionWithCheckboxes(),s||o.parent().hasClass(af)||o.hasClass(this.addWidgetPrefix(rf))?(this._selectionController.changeItemSelection(n,{shift:e.shift,control:e.ctrl}),e.originalEvent.preventDefault(),!0):!1}return this._beginFastEditing(e.originalEvent)}_ctrlAKeyHandler(e,t){!t&&!e.alt&&this.option("selection.mode")==="multiple"&&this.option("selection.allowSelectAll")&&(this._selectionController.selectAll(),e.originalEvent.preventDefault())}_toggleInertAttr(e){}_tabKeyHandler(e,t){let n=this.option("editing"),o=e.shift?"previous":"next",s=f(this._focusedCellPosition)&&!dt(this._focusedCellPosition),r=e.shift&&this._isFirstValidCell(this._focusedCellPosition),a=!e.shift&&this._isLastValidCell(this._focusedCellPosition),l=!s||r||a,d=e.originalEvent.target,c=this._focusedView&&this._focusedView.element();if(!this._handleTabKeyOnMasterDetailCell(d,o)){if(u(c).addClass(wS),n&&d&&!l)if(u(d).hasClass(this.addWidgetPrefix(rf))&&this._resetFocusedCell(),this._isVirtualColumnRender()&&this._processVirtualHorizontalPosition(o),t){if(!this._editingCellTabHandler(e,o))return}else this._targetCellTabHandler(e,o)&&(l=!0);if(l){let p=this._getFocusedCell().is(uf);a&&!p&&this._toggleInertAttr(!0),this._editorFactory.loseFocus(),this._editingController.isEditing()&&!this._isRowEditMode()&&(this._resetFocusedCell(!0),this._resetFocusedView(),this._closeEditCell())}else e.originalEvent.preventDefault()}}_getMaxHorizontalOffset(){let e=this.component.getScrollable();return e?e.scrollWidth()-z(this._rowsView.element()):0}_isColumnRendered(e){let t=this._columnsController.getVisibleColumns(null,!0),n=this._columnsController.getVisibleColumns(),o=t[e],s=!1;return o&&(s=n.indexOf(o)>=0),s}_isFixedColumn(e){let n=this._columnsController.getVisibleColumns(null,!0)[e];return!!n&&!!n.fixed}_isColumnVirtual(e){let t=e-this._columnsController.getColumnIndexOffset(),o=this._columnsController.getVisibleColumns()[t];return!!o&&o.command==="virtual"}_processVirtualHorizontalPosition(e){let t=this.component.getScrollable(),n=this.getColumnIndex(),o,s=0,r=!1;switch(e){case"next":case"nextInRow":{let a=this._getVisibleColumnCount();o=n+1,s=this.option("rtlEnabled")?this._getMaxHorizontalOffset():0,e==="next"?r=a===o||this._isFixedColumn(n)&&!this._isColumnRendered(o):r=a>o&&this._isFixedColumn(n)&&!this._isColumnRendered(o);break}case"previous":case"previousInRow":if(o=n-1,s=this.option("rtlEnabled")?0:this._getMaxHorizontalOffset(),e==="previous"){let a=this._columnsController.getColumnIndexOffset();r=o<0&&a===0||this._isFixedColumn(n)&&!this._isColumnRendered(o)}else r=o>=0&&this._isFixedColumn(n)&&!this._isColumnRendered(o)}r?t.scrollTo({left:s}):f(o)&&f(e)&&this._isColumnVirtual(o)&&(s=this._getHorizontalScrollPositionOffset(e),s!==0&&t.scrollBy({left:s,top:0}))}_getHorizontalScrollPositionOffset(e){let t=0,n=this._getCell(this._focusedCellPosition),o=n&&ie(n);if(o>0){let s=this.option("rtlEnabled")?-1:1;t=e==="nextInRow"||e==="next"?o*s:o*s*-1}return t}_editingCellTabHandler(e,t){let n=e.originalEvent.target,o=this._getCellElementFromTarget(n),s,r=e.originalEvent,a=this._getElementType(n);if(o.is(uf))return!this._targetCellTabHandler(e,t);this._updateFocusedCellPosition(o);let l=this._getNextCellByTabKey(r,t,a);if(o=l.$cell,!o||this._handleTabKeyOnMasterDetailCell(o,t))return!1;let d=this._getColumnByCellElement(o),c=o.parent(),h=this._getRowIndex(c),p=this._dataController.items()[h],g=this._editingController;if(d&&d.allowEditing){let C=!p||p.rowType==="data";s=g.allowUpdating({row:p})?C:p&&p.isNewRow}return s||this._closeEditCell(),this._focusCell(o,!l.isHighlighted)&&(!this._isRowEditMode()&&s?this._editFocusedCell():this._focusInteractiveElement(o,e.shift)),!0}_targetCellTabHandler(e,t){let n=e.originalEvent,o=n.target,s=this._getElementType(o),r=this._getCellElementFromTarget(o),a=s==="cell"&&this._getInteractiveElement(r,!e.shift),l=!1;if(!FS(this,r)&&a!==null&&a!==void 0&&a.length&&o!==a.get(0))l=!0;else{this._focusedCellPosition.rowIndex===void 0&&u(o).hasClass(So)&&this._updateFocusedCellPosition(r),s=this._getElementType(o),this.isRowFocusType()&&(this.setCellFocusType(),s==="row"&&wd(u(o))&&(o=this.getFirstValidCellInRow(u(o)),s=this._getElementType(o)));let d=this._getNextCellByTabKey(n,t,s);if(r=d.$cell,!r||(r=this._checkNewLineTransition(n,r),!r))return!1;this._focusCell(r,!d.isHighlighted),FS(this,r)||this._focusInteractiveElement(r,e.shift)}return l}_getNextCellByTabKey(e,t,n){let o=this._getNextCell(t,n),s=o&&this._fireFocusedCellChanging(e,o,!0);return!s||s.cancel?{}:(s.$newCellElement&&(o=s.$newCellElement),{$cell:o,isHighlighted:s.isHighlighted})}_checkNewLineTransition(e,t){let n=this.getVisibleRowIndex(),o=t.parent();if(n!==this._getRowIndex(o)){let s=this._getCellPosition(t),r=this._fireFocusedRowChanging(e,o);if(r.cancel)return;r.rowIndexChanged&&s&&(this.setFocusedColumnIndex(s.columnIndex),t=this._getFocusedCell())}return t}_enterKeyHandler(e,t){var n,o;let s=this.getVisibleRowIndex(),r=this._dataController.getKeyByRowIndex(s),a=(n=this._focusedView)===null||n===void 0?void 0:n.getRow(s),l=this._getFocusedCell(),d=this.option("grouping.allowCollapsing")&&Ed(a),c=this.option("masterDetail.enabled")&&l?.hasClass($u),h=l?.hasClass(gH);if(d||c){let p=this._dataController.items()[s],g=p?.data&&!p.data.isContinuation;f(r)&&g&&this._dataController.changeRowExpand(r)}else h?(this._adaptiveColumnsController.toggleExpandAdaptiveDetailRow(r),this._updateFocusedCellPosition(l)):(o=this.getMasterDetailCell(l))!==null&&o!==void 0&&o.is(l)?l.is(":focus")&&this.focusFirstInteractiveElementInside(l):l!=null&&l.hasClass(ES)||this._processEnterKeyForDataCell(e,t)}focusFirstInteractiveElementInside(e){e.find(Sd).get(0).focus()}_processEnterKeyForDataCell(e,t){let n=this._getEnterKeyDirection(e),o=this._allowEditingOnEnterKey();t||!o&&n?this._handleEnterKeyEditingCell(e.originalEvent).done(()=>{n==="next"||n==="previous"?this._targetCellTabHandler(e,n):(n==="upArrow"||n==="downArrow")&&this._navigateNextCell(e.originalEvent,n)}):o&&this._startEditing(e)}_getEnterKeyDirection(e){let t=this.option("keyboardNavigation.enterKeyDirection"),n=e.shift;if(t==="column")return n?"upArrow":"downArrow";if(t==="row")return n?"previous":"next"}_handleEnterKeyEditingCell(e){let t=y(),{target:n}=e,o=this._getCellElementFromTarget(n),s=this._isRowEditMode();return this._updateFocusedCellPosition(o),s?(this._focusEditFormCell(o),setTimeout(this._editingController.saveEditData.bind(this._editingController)),t.resolve()):(_.trigger(u(n),"change"),this._closeEditCell().always(t.resolve),e.preventDefault()),t}_escapeKeyHandler(e,t){let n=this._getCellElementFromTarget(e.originalEvent.target);if(t)return this._updateFocusedCellPosition(n),this._isRowEditMode()?(this._focusEditFormCell(n),this._editingController.cancelEditData(),this._dataController.items().length===0&&(this._resetFocusedCell(),this._editorFactory.loseFocus())):this._editingController.getEditMode()==="cell"?this._editingController.cancelEditData():this._closeEditCell(),e.originalEvent.preventDefault(),!0;let o=this.getMasterDetailCell(n);return o?(this._focusCell(o),!0):!1}_ctrlFKeyHandler(e){if(this.option("searchPanel.visible")){let t=this._headerPanel.getSearchTextEditor();t&&(t.focus(),e.originalEvent.preventDefault())}}_f2KeyHandler(){let e=this._editingController.isEditing(),t=this.getVisibleRowIndex(),n=this._focusedView&&this._focusedView.getRow(t);!e&&wd(n)&&this._startEditing()}_navigateNextCell(e,t){let n=this._getNextCell(t),o=this._getDirectionCodeByKey(t);return n&&this._isCellValid(n)?this._arrowKeysHandlerFocusCell(e,n,o):!1}_arrowKeysHandlerFocusCell(e,t,n){let o=n==="prevRow"||n==="nextRow",s=this._fireFocusChangingEvents(e,t,o,!0);return t=s.$newCellElement,!s.cancel&&this._isCellValid(t)?(this._focus(t,!s.isHighlighted),!0):!1}_beginFastEditing(e,t){if(!this._isFastEditingAllowed()||e.altKey||e.ctrlKey||this._editingController.isEditing())return!1;if(t)this._startEditing(e,hf);else{let{key:n}=e,o=e.keyCode||e.which,s=n||o&&String.fromCharCode(o);s&&(s.length===1||s===hf)&&this._startEditing(e,s)}return!0}_pointerEventHandler(e){var t;let n=e.event||e,o=u(n.currentTarget),s=(t=this._rowsView)===null||t===void 0?void 0:t.element(),r=o.parent(),a=u(n.target).is(Sd),l=!!u(n.target).closest(`.${_H}`).length,d=o.hasClass($u);this._isEventInCurrentGrid(n)&&(!l&&(this._isCellValid(o,!a)||d)?(o=this._isInsideEditForm(o)?u(n.target):o,this._focusView(),u(s).removeClass(wS),r.hasClass(lf)?(this._updateFocusedCellPosition(o),this._applyTabIndexToElement(this._focusedView.element()),this._focusedView.focus(!0)):this.getMasterDetailCell(o)?this._updateFocusedCellPosition(o):this._clickTargetCellHandler(n,o)):o.is("td")&&this._resetFocusedCell())}_clickTargetCellHandler(e,t){let n=this._getColumnByCellElement(t),o=this._isCellEditMode();this.setCellFocusType();let s=this._fireFocusChangingEvents(e,t,!0);if(t=s.$newCellElement,s.cancel)this.setRowFocusType(),this.setFocusedRowIndex(s.prevRowIndex),this._editingController.isEditing()&&o&&this._closeEditCell();else{if(s.resetFocusedRow){this._focusController._resetFocusedRow();return}if(s.rowIndexChanged&&(t=this._getFocusedCell()),!s.isHighlighted&&!o&&this.setRowFocusType(),this._updateFocusedCellPosition(t),this._allowRowUpdating()&&o&&n&&n.allowEditing)this._isNeedFocus=!1,this._isHiddenFocus=!1;else{t=this._getFocusedCell();let r=e&&u(e.target).closest(`${DS}, td`),a=r&&r.not(t).is(DS),d=!(!!n&&!n.command&&t.hasClass(Vr))&&(!s.isHighlighted||a);this._focus(t,d,a)}}}_allowRowUpdating(){let e=this.getVisibleRowIndex(),t=this._dataController.items()[e];return this._editingController.allowUpdating({row:t},"click")}focus(e){let t,n=this.option("focusedRowEnabled"),o=this._isCellElement(u(e));e||(t=".dx-datagrid-rowsview .dx-row[tabindex]",n||(t+=", .dx-datagrid-rowsview .dx-row > td[tabindex]"),e=this.component.$element().find(t).first()),e&&this._focusElement(u(e),o)}getFocusedView(){return this._focusedView}setupFocusedView(){this.isKeyboardEnabled()&&!f(this._focusedView)&&this._focusView()}_focusElement(e,t){let n=u(this._getRowsViewElement()),o=e.closest(n),s=this.isRowFocusType(),r={};!o.length||this._isCellElement(e)&&!this._isCellValid(e)||(this._focusView(),this._isNeedFocus=!0,this._isNeedScroll=!0,(this._isCellElement(e)||Ed(e))&&(this.setCellFocusType(),r=this._fireFocusChangingEvents(null,e,!0,t),e=r.$newCellElement,s&&!r.isHighlighted&&this.setRowFocusType()),r.cancel||(this._focus(e,!r.isHighlighted),this._focusInteractiveElement(e)))}_getFocusedViewByElement(e){let t=this.getFocusedView(),n=t&&u(t.element());return e&&e.closest(n).length!==0}_focusView(){this._focusedView=this._rowsView}_resetFocusedView(){this.setRowFocusType(),this._focusedView=null}_focusInteractiveElement(e,t){if(!e)return;let n=this._getInteractiveElement(e,t);M.focusAndSelectElement(this,n)}_focus(e,t,n){let o=e&&!e.hasClass(So)?e.closest(`.${So}`):e;if(o&&OH(o))return;let s=this._focusedView,r=s&&s.element(),a;this._isHiddenFocus=t;let l=Ed(o)||vH(o)||this.isRowFocusType();l?(a=o,s&&this.setFocusedRowIndex(this._getRowIndex(o))):this._isCellElement(e)&&(a=e,this._updateFocusedCellPosition(e)),a&&(r&&r.find(".dx-row[tabindex], .dx-row > td[tabindex]").filter((d,c)=>M.isElementInCurrentGrid(this,u(c))).not(a).removeClass(zu).removeClass(IS).removeAttr("tabindex"),_.one(a,"blur",d=>{d.relatedTarget&&a.removeClass(zu).removeClass(IS)}),n||(this._applyTabIndexToElement(a),_.trigger(a,"focus")),t?(a.addClass(zu),l&&e.addClass(zu)):this._editorFactory.focus(a))}_updateFocus(e){this._updateFocusTimeout=setTimeout(()=>{if(this._needFocusEditingCell()){this._editingController._focusEditingCell();return}let t=this._getFocusedCell(),n=this._editingController.isEditing();if(!this.getMasterDetailCell(t)||this._isRowEditMode()){if(this._hasSkipRow(t.parent())){let o=this._focusedCellPosition&&this._focusedCellPosition.rowIndex>0?"upArrow":"downArrow";t=this._getNextCell(o)}if(Rn(t))if(t.is("td")||t.hasClass(this.addWidgetPrefix(uH))){let o=t.is(uf),s=t.find(":focus"),r=Rn(s),a=this._getColumnByCellElement(t);if((e||!o)&&this._editorFactory.focus()){if(o&&r){M.focusAndSelectElement(this,s);return}!r&&this._focus(t)}else!r&&(this._isNeedFocus||this._isHiddenFocus)&&this._focus(t,this._isHiddenFocus);n&&!(a!=null&&a.showEditorAlways)&&this._focusInteractiveElement.bind(this)(t)}else _.trigger(t,"focus")}})}_getColumnByCellElement(e){let n=this._rowsView.getCellIndex(e)+this._columnsController.getColumnIndexOffset();return this._columnsController.getVisibleColumns(null,!0)[n]}_needFocusEditingCell(){let e=this._editingController.getEditMode()===Su,t=this._editingController.getEditMode()===Ou,n=e&&this._editingController.hasChanges(),o=t&&this._editingController.isNewRowInEditMode(),s=this._getFocusedCell();return(s.children().length===0||s.find(hd).length>0)&&(n||o)}_getFocusedCell(){return u(this._getCell(this._focusedCellPosition))}_updateFocusedCellPositionByTarget(e){var t;if(this._getElementType(e)==="row"&&f((t=this._focusedCellPosition)===null||t===void 0?void 0:t.columnIndex)){let o=u(e);this._focusedView&&Ed(o)&&this.setFocusedRowIndex(this._getRowIndex(o))}else this._updateFocusedCellPosition(this._getCellElementFromTarget(e))}_updateFocusedCellPosition(e,t){let n=this._getCellPosition(e,t);return n&&(!e.length||n.rowIndex>=0&&n.columnIndex>=0)&&this.setFocusedCellPosition(n.rowIndex,n.columnIndex),n}_getFocusedColumnIndexOffset(e){let t=0,n=this._columnsController.getVisibleColumns()[e];return n&&n.fixed?t=this._getFixedColumnIndexOffset(n):e>=0&&(t=this._columnsController.getColumnIndexOffset()),t}_getFixedColumnIndexOffset(e){return SH(this,e)?this._getVisibleColumnCount()-this._columnsController.getVisibleColumns().length:0}_getCellPosition(e,t){let n,o=Rn(e)&&e.closest("tr");if(Rn(o)){let s=this._getRowIndex(o);return n=this._rowsView.getCellIndex(e,s),n+=this._getFocusedColumnIndexOffset(n),t&&(n=t==="previous"?n-1:n+1,n=this._applyColumnIndexBoundaries(n)),{rowIndex:s,columnIndex:n}}}_focusCell(e,t){if(this._isCellValid(e))return this._focus(e,t),!0}_focusEditFormCell(e){e.hasClass(df)&&this._editorFactory.focus(e,!0)}_resetFocusedCell(e){var t;let n=this._getFocusedCell();Rn(n)&&n.removeAttr("tabindex"),this._isNeedFocus=!1,this._isNeedScroll=!1,this._focusedCellPosition={},clearTimeout(this._updateFocusTimeout),(t=this._focusedView)===null||t===void 0||t.renderFocusState({preventScroll:e})}restoreFocusableElement(e,t){let n=this,o,s,r=f(e),a=this._rowsView.element(),{columnIndex:l}=n._focusedCellPosition,d=n._dataController.getRowIndexOffset();e=r?e:this._rowsView.getTopVisibleItemIndex()+d,r?(s=this._rowsView.getRow(e-d),o=n._fireFocusedRowChanging(t,s),!o.cancel&&o.rowIndexChanged&&(e=o.newRowIndex)):(n._editorFactory.loseFocus(),n._applyTabIndexToElement(a),_.trigger(a,"focus")),(!r||!o.cancel)&&n.setFocusedCellPosition(e,l),r&&n._updateFocus()}_getNewPositionByCode(e,t,n){let{columnIndex:o}=e,{rowIndex:s}=e,r;if(e.rowIndex===void 0&&n==="next")return{columnIndex:0,rowIndex:0};switch(n){case"nextInRow":case"next":r=this._getVisibleColumnCount(),o<r-1&&t!=="row"&&this._hasValidCellAfterPosition({columnIndex:o,rowIndex:s})?o++:!this._isLastRow(s)&&n==="next"&&(o=0,s++);break;case"previousInRow":case"previous":o>0&&t!=="row"&&this._hasValidCellBeforePosition({columnIndex:o,rowIndex:s})?o--:s>0&&n==="previous"&&(s--,r=this._getVisibleColumnCount(),o=r-1);break;case"upArrow":s=s>0?s-1:s;break;case"downArrow":s=this._isLastRow(s)?s:s+1}return{columnIndex:o,rowIndex:s}}setFocusedCellPosition(e,t){this.setFocusedRowIndex(e),this.setFocusedColumnIndex(t)}setFocusedRowIndex(e){this._focusedCellPosition||(this._focusedCellPosition={}),this._focusedCellPosition.rowIndex=e}setFocusedColumnIndex(e){this._focusedCellPosition||(this._focusedCellPosition={}),this._focusedCellPosition.columnIndex=e}getRowIndex(){return this._focusedCellPosition?this._focusedCellPosition.rowIndex:-1}getColumnIndex(){return this._focusedCellPosition?this._focusedCellPosition.columnIndex:-1}getVisibleRowIndex(){var e;let t=(e=this._focusedCellPosition)===null||e===void 0?void 0:e.rowIndex;return!f(t)||t<0?-1:t-this._dataController.getRowIndexOffset()}getVisibleColumnIndex(){var e;let t=(e=this._focusedCellPosition)===null||e===void 0?void 0:e.columnIndex;return f(t)?t-this._columnsController.getColumnIndexOffset():-1}_applyColumnIndexBoundaries(e){let t=this._getVisibleColumnCount();return e<0?e=0:e>=t&&(e=t-1),e}_isCellByPositionValid(e){let t=u(this._getCell(e));return this._isCellValid(t)}_isLastRow(e){let t=this._dataController;if(this._isVirtualRowRender())return e>=t.getMaxRowIndex();let n=Math.max(...t.items().map((o,s)=>o.visible!==!1?s:-1));return e===n}_isFirstValidCell(e){let t=!1;return e.rowIndex===0&&e.columnIndex>=0&&(t=t||!this._hasValidCellBeforePosition(e)),t}_hasValidCellBeforePosition(e){let{columnIndex:t}=e,n=!1;for(;t>0&&!n;){let o={columnIndex:--t,rowIndex:e.rowIndex};n=this._isCellByPositionValid(o)}return n}_hasValidCellAfterPosition(e){let{columnIndex:t}=e,n=!1,o=this._getVisibleColumnCount();for(;t<o-1&&!n;){let s={columnIndex:++t,rowIndex:e.rowIndex};n=this._isCellByPositionValid(s)}return n}_isLastValidCell(e){let t=e.columnIndex>=0?e.columnIndex+1:0,{rowIndex:n}=e,o={columnIndex:t,rowIndex:n},s=this._dataController.getVisibleRows(),r=s&&s[n];return this._isLastRow(n)?(r?.rowType==="group"||r?.rowType==="groupFooter")&&e.columnIndex>0||e.columnIndex===this._getVisibleColumnCount()-1?!0:this._isCellByPositionValid(o)?!1:this._isLastValidCell(o):!1}_isCellValid(e,t){if(Rn(e)){let n=e.parent(),o=this._rowsView.getCellIndex(e)+this._columnsController.getColumnIndexOffset(),s=this._getColumnByCellElement(e),r=this._getVisibleColumnCount(),a=this._editingController,l=bH(n),d=s&&s.showWhenGrouped,c=s&&!e.hasClass($u)&&wd(n),h=function(){return!l&&s&&(!f(s.groupIndex)||d&&c)||parseInt(e.attr("colspan"),10)>1};if(RS.isDragCell(e))return!1;if(this.getMasterDetailCell(e))return!0;if(r>o&&h()){let g=this._dataController.items(),C=this._rowsView.getRowIndex(n),v=g[C],b=a&&this._isCellEditMode()&&a.isEditing(),T=a&&a.isEditRow(C),R=T||b;return s.command?this._isLegacyNavigation()?!R&&s.command==="expand":b?!1:T?s.command!=="select":!R:b&&v&&v.rowType!=="data"?!1:!R||s.allowEditing||t}}}getFirstValidCellInRow(e,t){let n=this,o=e.find("> td"),s,r;t=t||0;for(let a=t;a<o.length;++a)if(s=o.eq(a),n._isCellValid(s)){r=s;break}return r}_getNextCell(e,t,n){let o=n||this._focusedCellPosition,s=this.isRowFocusType(),r=s||["next","previous"].includes(e),a,l;if(this._focusedView&&o){let d=this._getNewPositionByCode(o,t,e);a=u(this._getCell(d));let c=e==="previous"?this._isFirstValidCell(d):this._isLastValidCell(d);if(Rn(a)&&!this._isCellValid(a)&&this._isCellInRow(d,r)&&!c&&(s?a=this.getFirstValidCellInRow(a.parent(),d.columnIndex):a=this._getNextCell(e,"cell",d)),l=Rn(a)&&a.parent(),this._hasSkipRow(l)){let h=this._getRowIndex(l);if(!this._isLastRow(h))a=this._getNextCell(e,"row",{columnIndex:o.columnIndex,rowIndex:h});else return null}return Rn(a)?a:null}return null}_startEditing(e,t){let n=this._focusedCellPosition,o=this.getVisibleRowIndex(),s=this.getVisibleColumnIndex(),r=this._dataController.items()[o],a=this._columnsController.getVisibleColumns()[s];this._isAllowEditing(r,a)&&(this._isRowEditMode()?this._editingController.editRow(o):n&&this._startEditCell(e,t))}_isAllowEditing(e,t){return this._editingController.allowUpdating({row:e})&&t&&t.allowEditing}_editFocusedCell(){let e=this.getVisibleRowIndex(),t=this.getVisibleColumnIndex();return this._editingController.editCell(e,t)}_startEditCell(e,t){this._fastEditingStarted=f(t);let n=this._editFocusedCell(),o=Ha(n);if(!this._isFastEditingStarted()||!o&&!n)return;let r=o&&t===hf?"":t,a=o?n:y().resolve(),l=this._rowsView.waitAsyncTemplates(!0);P(a,l).done(()=>{this._editingCellHandler(e,r)})}_editingCellHandler(e,t){var n;let o=this._getFocusedCell().find(Sd).eq(0),s=o.get(0);if(!s)return;let r=uo(e,{type:"keydown",target:s}),a=uo(e,{type:"keypress",target:s}),l=uo(e,{type:"input",target:s});if(l.originalEvent&&(l.originalEvent=uo(l.originalEvent,{data:t})),(n=s.select)===null||n===void 0||n.call(s),_.trigger(o,r),!r.isDefaultPrevented()&&(_.trigger(o,a),!a.isDefaultPrevented())){let d=be.mozilla?25:0;setTimeout(()=>{let c=this._getKeyPressInputValue(o,t);o.val(c);let h=o.closest(`.${fH}`);_.off(h,"focusout"),_.one(h,"focusout",()=>{_.trigger(o,"change")}),_.trigger(o,l)},d)}}_getKeyPressInputValue(e,t){let n=e.val();return t==="-"&&n==="-0"?"-0":t}_fireFocusChangingEvents(e,t,n,o){let s={},r=this._getCellPosition(t)??{};return this.isCellFocusType()&&(s=this._fireFocusedCellChanging(e,t,o),s.cancel||(r.columnIndex=s.newColumnIndex,r.rowIndex=s.newRowIndex,o=s.isHighlighted,t=u(this._getCell(r)))),!s.cancel&&n&&t&&(s=this._fireFocusedRowChanging(e,t.parent()),s.cancel||(r.rowIndex=s.newRowIndex,s.isHighlighted=o)),s.$newCellElement=u(this._getCell(r)),s.$newCellElement.length||(s.$newCellElement=t),s}_fireFocusedCellChanging(e,t,n){let o=this.option("focusedColumnIndex"),s=this.option("focusedRowIndex"),r=this._getCellPosition(t),a=r?r.columnIndex:-1,l=r?r.rowIndex:-1,d=this._dataController.getVisibleRows(),c=this._columnsController.getVisibleColumns(),h={cellElement:t,prevColumnIndex:o,prevRowIndex:s,newColumnIndex:a,newRowIndex:l,rows:d,columns:c,event:e,isHighlighted:n||!1,cancel:!1};return this._canceledCellPosition=null,this.executeAction("onFocusedCellChanging",h),(h.newColumnIndex!==a||h.newRowIndex!==l)&&(h.$newCellElement=u(this._getCell({columnIndex:h.newColumnIndex,rowIndex:h.newRowIndex}))),h.cancel&&(this._canceledCellPosition={rowIndex:l,columnIndex:a}),h}_fireFocusedCellChanged(e){let t=this._rowsView.getCellIndex(e),n=e?.parent().data("options"),o=n?.key;this._memoFireFocusedCellChanged(o,t)}_memoFireFocusedCellChanged(e,t){let n=this._getFocusedCell(),o=this._getRowIndex(n?.parent()),s=Math.min(o-this._dataController.getRowIndexOffset(),this._dataController.items().length-1);if(this._editingController.isEditCell(s,t))return;let a=this._dataController.items()[s],l=this._columnsController.getVisibleColumns()[t];this.executeAction("onFocusedCellChanged",{cellElement:n?N(n):void 0,columnIndex:t,rowIndex:o,row:a,column:l})}_fireFocusedRowChanging(e,t){let n=this._getRowIndex(t),o=this.option("focusedRowIndex"),s=this._dataController.loadingOperationTypes(),r={rowElement:t,prevRowIndex:o,newRowIndex:n,event:e,rows:this._dataController.getVisibleRows(),cancel:!1},a=s.sorting||s.grouping||s.filtering||s.paging;return!this._dataController||this._dataController.isLoading()&&a?(r.cancel=!0,r):(this.option("focusedRowEnabled")&&(this.executeAction("onFocusedRowChanging",r),!r.cancel&&r.newRowIndex!==n&&(r.resetFocusedRow=r.newRowIndex<0,r.resetFocusedRow||this.setFocusedRowIndex(r.newRowIndex),r.rowIndexChanged=!0)),r)}_fireFocusedRowChanged(){var e;let t=this.option("focusedRowEnabled"),n=this.option("focusedRowKey"),o=(e=this._focusController)===null||e===void 0?void 0:e.getFocusedRowIndexByKey(n);!t||f(n)&&o<0||this._memoFireFocusedRowChanged(n,o)}_memoFireFocusedRowChanged(e,t){let n=t-this._dataController.getRowIndexOffset();this.executeAction("onFocusedRowChanged",{rowElement:t<0?void 0:this._rowsView.getRowElement(n),rowIndex:t,row:t<0?void 0:this._dataController.getVisibleRows()[n]})}_isEventInCurrentGrid(e){return M.isElementInCurrentGrid(this,u(e.target))}_isRowEditMode(){let e=this._editingController.getEditMode();return e===Lr||e===Eu}_isCellEditMode(){let e=this._editingController.getEditMode();return e===Su||e===Ou}_isFastEditingAllowed(){return this._isCellEditMode()&&this.option("keyboardNavigation.editOnKeyPress")}_getInteractiveElement(e,t){let n=e.find(Sd).filter(":visible");return t?n.last():n.first()}_applyTabIndexToElement(e){let t=this.option("tabIndex")??0;e.attr("tabindex",t)}_getCell(e){if(this._focusedView&&e){let t=this._dataController.getRowIndexOffset(),n=this._columnsController.getVisibleColumns(null,!0)[e.columnIndex],o=n&&n.fixed?this._getFixedColumnIndexOffset(n):this._columnsController.getColumnIndexOffset(),s=e.rowIndex>=0?e.rowIndex-t:-1,r=e.columnIndex>=0?e.columnIndex-o:-1;return this._focusedView.getCell({rowIndex:s,columnIndex:r})}}_getRowIndex(e){let t=this._rowsView.getRowIndex(e);return t>=0&&(t+=this._dataController.getRowIndexOffset()),t}_hasSkipRow(e){let t=e&&e.get(0);return t&&t.style.display==="none"}_allowEditingOnEnterKey(){return this.option("keyboardNavigation.enterKeyAction")==="startEdit"}_isLegacyNavigation(){return this.option("useLegacyKeyboardNavigation")}_getDirectionCodeByKey(e){let t;switch(e){case"upArrow":t="prevRow";break;case"downArrow":t="nextRow";break;case"leftArrow":t=this.option("rtlEnabled")?"nextInRow":"previousInRow";break;case"rightArrow":t=this.option("rtlEnabled")?"previousInRow":"nextInRow"}return t}_isVirtualScrolling(){let e=this.option("scrolling.mode");return e==="virtual"||e==="infinite"}_isVirtualRowRender(){return this._isVirtualScrolling()||M.isVirtualRowRendering(this)}_isVirtualColumnRender(){return this.option("scrolling.columnRenderingMode")==="virtual"}_scrollBy(e,t,n,o){let s=this,r=this._rowsView.getScrollable();if(s._focusedCellPosition){let a=function(){r.off("scroll",a),setTimeout(s.restoreFocusableElement.bind(s,n,o))};r.on("scroll",a)}return r.scrollBy({left:e,top:t})}_isInsideEditForm(e){let t=u(e).closest(`.${this.addWidgetPrefix(cd)}`);return t.length&&this.elementIsInsideGrid(t)}getMasterDetailCell(e){let t=u(e).closest(`.${df}`);return t.length&&this.elementIsInsideGrid(t)?t:null}_processNextCellInMasterDetail(e,t){!this._isInsideEditForm(e)&&e&&this._applyTabIndexToElement(e)}_handleTabKeyOnMasterDetailCell(e,t){if(this.getMasterDetailCell(e)){this._updateFocusedCellPosition(u(e),t);let n=this._getNextCell(t,"row");return this._processNextCellInMasterDetail(n,u(e)),!0}return!1}_getElementType(e){return u(e).is("tr")?"row":"cell"}_isFastEditingStarted(){return this._isFastEditingAllowed()&&this._fastEditingStarted}_getVisibleColumnCount(){return this._columnsController.getVisibleColumns(null,!0).length}_isCellInRow(e,t){let{columnIndex:n}=e,o=this._getVisibleColumnCount();return t?n>=0&&n<=o-1:n>0&&n<o-1}_isCellElement(e){return e.length&&e[0].tagName==="TD"}_getCellElementFromTarget(e){let t=this._getElementType(e),n=u(e),o;return t==="cell"?o=n.closest(`.${So} > td`):o=n.children().not(`.${$u}`).first(),o}_getRowsViewElement(){var e;return(e=this._rowsView)===null||e===void 0?void 0:e.element()}isKeyboardEnabled(){return this.option("keyboardNavigation.enabled")}_processCanceledEditCellPosition(e,t){if(this._canceledCellPosition){let n=this._canceledCellPosition.rowIndex===e&&this._canceledCellPosition.columnIndex===t;return this._canceledCellPosition=null,n}}updateFocusedRowIndex(){let e=this._dataController,t=this.getVisibleRowIndex(),n=e.items(),o=n.length?n.length-1:-1,s=e.getRowIndexOffset();o>=0&&t>o&&this.setFocusedRowIndex(o+s)}},dZ=i=>class extends i{_rowClick(e){let t=this._editingController.getEditRowIndex(),n=this._keyboardNavigationController.isKeyboardEnabled();t===e.rowIndex&&this._keyboardNavigationController.setCellFocusType(),(pf()||!n)&&this.option("focusedRowEnabled")&&this._triggerPointerDownEventHandler(e,!n),super._rowClick.apply(this,arguments)}_triggerPointerDownEventHandler(e,t){let{originalEvent:n}=e.event;if(n){let o=u(n.target),s=this.getCellIndex(o),r=this._columnsController.getVisibleColumns()[s],a=this._dataController.items()[e.rowIndex];if(this._keyboardNavigationController._isAllowEditing(a,r)||t){let l=uo(n,{currentTarget:n.target});this._keyboardNavigationController._pointerEventHandler(l)}}}renderFocusState(e){super.renderFocusState(e);let{preventScroll:t,pageSizeChanged:n}=e??{},o=this.element();o&&!pn(o)&&o.attr("tabindex",null),n&&this._keyboardNavigationController.updateFocusedRowIndex();let s=this._keyboardNavigationController.getVisibleRowIndex();(!f(s)||s<0)&&(s=0);let r=this.getCellElements(s);this._keyboardNavigationController.isKeyboardEnabled()&&r!==null&&r!==void 0&&r.length&&this.updateFocusElementTabIndex(r,t)}updateFocusElementTabIndex(e,t){let n=e.eq(0).parent();if(Ed(n))this._keyboardNavigationController._applyTabIndexToElement(n);else{let o=this._keyboardNavigationController.getColumnIndex();(!f(o)||o<0)&&(o=0),this._updateFocusedCellTabIndex(e,o)}}_updateFocusedCellTabIndex(e,t){let n=this._keyboardNavigationController,o=e?e.length:-1,s=function(a){let l=!!n.getMasterDetailCell(a),d=n._isCellValid(a);if(!l&&d&&n._isCellElement(a))return n._applyTabIndexToElement(a),n.setCellFocusType(),!0},r=RS.getCellToFocus(e,t);if(r.length)s(r);else{o<=t&&(t=o-1);for(let a=t;a<o&&!s(u(e[a]));++a);}}renderDelayedTemplates(e){super.renderDelayedTemplates.apply(this,arguments),this.waitAsyncTemplates().done(()=>{this._renderFocusByChange(e)})}_renderFocusByChange(e){var t;let{operationTypes:n,repaintChangesOnly:o}=e??{},{fullReload:s,pageSize:r}=n??{},a=!!(e!=null&&(t=e.changeTypes)!==null&&t!==void 0&&t.find(l=>l==="insert"||l==="remove"));if(!e||!o||s||r||a){let l=EH(this);this.renderFocusState({preventScroll:l,pageSizeChanged:r})}}_renderCore(e){let t=super._renderCore.apply(this,arguments);return this._renderFocusByChange(e),t}_editCellPrepared(e){var t;let n=this._getEditorInstance(e),o=(t=this._keyboardNavigationController)===null||t===void 0?void 0:t._isFastEditingStarted();n&&o&&this._handleEditingNavigationMode(n),super._editCellPrepared.apply(this,arguments)}_handleEditingNavigationMode(e){["downArrow","upArrow"].forEach(n=>{let o=e._supportedKeys()[n];e.registerKeyHandler(n,s=>{if(e._input().attr("aria-expanded")==="true")return o&&o.call(e,s)})}),e.registerKeyHandler("leftArrow",S),e.registerKeyHandler("rightArrow",S),e.NAME===mH&&e.option("useMaskBehavior")&&e.registerKeyHandler("enter",S)}_getEditorInstance(e){let t=e.find(".dx-texteditor").eq(0);return M.getWidgetInstance(t)}},cZ=i=>class extends i{editCell(e,t){if(this._keyboardNavigationController._processCanceledEditCellPosition(e,t))return!1;let n=super.editCell(e,t);return n&&this._keyboardNavigationController.setupFocusedView(),n}editRow(e){let t=this._keyboardNavigationController.getVisibleColumnIndex(),n=this._columnsController.getVisibleColumns()[t];(n&&n.type||this.option("editing.mode")===Eu)&&this._keyboardNavigationController._resetFocusedCell(),super.editRow(e)}addRow(e){return this._keyboardNavigationController.setupFocusedView(),this._keyboardNavigationController.setCellFocusType(),super.addRow.apply(this,arguments)}getFocusedCellInRow(e){let t=super.getFocusedCellInRow(e),n=this._dataController.getRowIndexOffset(),o=this._keyboardNavigationController._focusedCellPosition.rowIndex-n;if(this._keyboardNavigationController.isKeyboardEnabled()&&o===e){let s=this._keyboardNavigationController._getFocusedCell();Rn(s)&&!s.hasClass(ES)&&(t=s)}return t}_processCanceledEditingCell(){this.closeEditCell().done(()=>{this._keyboardNavigationController._updateFocus()})}closeEditCell(){let e=this._keyboardNavigationController;e._fastEditingStarted=!1;let t=super.closeEditCell.apply(this,arguments);return!!this._getFocusedElement().closest(`.${this.addWidgetPrefix(oV)}`).length||e._updateFocus(),t}_getFocusedElement(){var e,t;return u((e=(t=this.component).element)===null||e===void 0?void 0:e.call(t)).find(":focus")}_delayedInputFocus(){this._keyboardNavigationController._isNeedScroll=!0,super._delayedInputFocus.apply(this,arguments)}_isEditingStart(){let e=super._isEditingStart.apply(this,arguments);if(e&&!this._keyboardNavigationController._isNeedFocus){let t=this._keyboardNavigationController._getFocusedCell();this._keyboardNavigationController._focus(t,!0)}return e}},uZ=i=>class extends i{_correctRowIndices(e){let t=this._keyboardNavigationController._focusedCellPosition;if(super._correctRowIndices.apply(this,arguments),t&&t.rowIndex>=0){let n=e(t.rowIndex);n&&(t.rowIndex+=n,this._editorFactoryController.refocus())}}getMaxRowIndex(){let e=this.items().length-1,t=this.virtualItemsCount();if(t){let n=this.getRowIndexOffset();e+=n+t.end}return e}},hZ=i=>class extends i{_showHiddenCellsInView(e){let{viewName:t,$cells:n,isCommandColumn:o}=e;super._showHiddenCellsInView.apply(this,arguments),t===MS&&!o&&n.each((s,r)=>{let a=u(r);PS(a)&&a.attr("tabindex",0)})}_hideVisibleCellInView(e){let{viewName:t,$cell:n,isCommandColumn:o}=e;super._hideVisibleCellInView.apply(this,arguments),t===MS&&!o&&PS(n)&&n.removeAttr("tabindex")}_hideVisibleColumnInView(e){let{view:t,isCommandColumn:n,visibleIndex:o}=e;super._hideVisibleColumnInView({view:t,isCommandColumn:n,visibleIndex:o}),t.name===CH&&this._rowsView.renderFocusState(null)}},IH={defaultOptions:()=>({useLegacyKeyboardNavigation:!1,keyboardNavigation:{enabled:!0,enterKeyAction:"startEdit",enterKeyDirection:"none",editOnKeyPress:!1}}),controllers:{keyboardNavigation:kS},extenders:{views:{rowsView:dZ},controllers:{editing:cZ,data:uZ,adaptiveColumns:hZ,keyboardNavigation:wH}}};H.registerModule("keyboardNavigation",IH);function BS(i,e,t,n){let o=0;if(i<e)for(;o<t.items.length;o++)BS(i+1,e,t.items[o],n);i===e&&n(t)}function gf(i,e){let t;if("map"in i)return i.map(e);let n=new Array(i.length);for(t in i)n[t]=e(i[t],t);return n}function pZ(i){return i!==i||i===""||i===null||i===void 0}function gZ(i){return i===oc.count}function DH(i){let e=me(i.selector),t="skipEmptyValues"in i?i.skipEmptyValues:!0,{aggregator:n}=i;if(typeof n=="string"&&(n=oc[n],!n))throw st.Error("E4001",i.aggregator);return{selector:e,aggregator:n,skipEmptyValues:t}}var mf=class{constructor(e){this._data=e.data,this._groupLevel=e.groupLevel||0,this._totalAggregates=gf(e.totalAggregates||[],DH),this._groupAggregates=gf(e.groupAggregates||[],DH),this._totals=[]}calculate(){this._totalAggregates.length&&this._calculateTotals(0,{items:this._data}),this._groupAggregates.length&&this._groupLevel>0&&this._calculateGroups({items:this._data})}totalAggregates(){return this._totals}_aggregate(e,t,n){let o=t.items?t.items.length:0;for(let s=0;s<e.length;s++){if(gZ(e[s].aggregator)){n[s]=(n[s]||0)+o;continue}for(let r=0;r<o;r++)this._accumulate(s,e[s],n,t.items[r])}}_calculateTotals(e,t){if(e===0&&(this._totals=this._seed(this._totalAggregates)),e===this._groupLevel)this._aggregate(this._totalAggregates,t,this._totals);else for(let n=0;n<t.items.length;n++)this._calculateTotals(e+1,t.items[n]);e===0&&(this._totals=this._finalize(this._totalAggregates,this._totals))}_calculateGroups(e){let t=this._groupLevel,n=t+1,o=this._seed.bind(this,this._groupAggregates),s=this._aggregate.bind(this,this._groupAggregates),r=this._finalize.bind(this,this._groupAggregates);function a(l){l.aggregates=o(n-1),n===t?s(l,l.aggregates):BS(n,t,l,d=>{s(d,l.aggregates)}),l.aggregates=r(l.aggregates)}for(;--n>0;)BS(0,n,e,a)}_seed(e,t){return gf(e,n=>{let{aggregator:o}=n;return"seed"in o?A(o.seed)?o.seed(t):o.seed:NaN})}_accumulate(e,t,n,o){let s=t.selector(o),{aggregator:r}=t,{skipEmptyValues:a}=t;a&&pZ(s)||(n[e]!==n[e]?n[e]=s:n[e]=r.step(n[e],s))}_finalize(e,t){return gf(e,(n,o)=>{let s=n.aggregator.finalize;return s?s(t[o]):t[o]})}};var mZ="dx-cell-focus-disabled";var MH=function(i,e){let t=u(i),{column:n}=e,{summaryItems:o}=e,s=[];if(!n.command&&o){for(let r=0;r<o.length;r++){let a=o[r],l=H.getSummaryText(a,e.summaryTexts);s.push(u("<div>").css("textAlign",a.alignment||n.alignment).addClass("dx-datagrid-summary-item").addClass("dx-datagrid-text-content").addClass(a.cssClass).toggleClass("dx-datagrid-group-text-content",e.rowType==="group").text(l).attr("aria-label",`${n.caption} ${l}`))}t.append(s)}},RH=function(i,e){let t=i.option("summary.texts")||{};return{totalItem:e.row,summaryItems:e.row.summaryCells[e.columnIndex],summaryTexts:t}},VS=function(i){return i.summary||i.aggregates||[]},NS=function(i){return i.option("summary.recalculateWhileEditing")},FH=function(i,e,t,n){n=n||[];for(let o=0;o<i.length;o++)n.push(i[o].key),e===1?t(n,i[o].items):FH(i[o].items,e-1,t,n),n.pop()},PH=function(i,e,t){return t?PH(i,e.map(n=>({items:[n]}),t-1)):i.concat(e)},kH=function(i,e,t){return t?i.map(n=>{let o={},s=kH(n.items||[],e,t-1);return Object.defineProperty(o,"aggregates",{get:()=>n.aggregates,set:r=>{n.aggregates=r}}),m(o,n,{items:s})}):i.filter(n=>e.indexOf(n)<0)},BH=function(i,e,t){if(!i||!e.length)return i;let n=e[0],o=t[0],s;return n&&o&&o.length&&(s=vt(i),x(o,function(r){r===0?s=s.sortBy(this.selector,this.desc):s=s.thenBy(this.selector,this.desc)}),s.enumerate().done(r=>{i=r})),e=e.slice(1),t=t.slice(1),e.length&&t.length&&x(i,function(){this.items=BH(this.items,e,t)}),i},TH=function(i,e,t){let n=t&&t.sortByGroups&&t.sortByGroups();return n&&n.length?BH(i,e,n):i},AH=function(i,e,t,n){let o;if(NS(i)){let s=i._editingController;if(s){let r=s.getInsertedData();r.length&&(t=PH(t,r,n));let a=s.getRemovedData();a.length&&(t=kH(t,a,n))}}return e&&(o=new mf({totalAggregates:e.totalAggregates,groupAggregates:e.groupAggregates,data:t,groupLevel:n}),o.calculate()),o?o.totalAggregates():[]},LS=class extends eo{_getRows(){return this._dataController.footerItems()}_getCellOptions(e){return m(super._getCellOptions(e),RH(this,e))}_renderCellContent(e,t){MH(e,t),super._renderCellContent.apply(this,arguments)}_renderCore(e){let t=!1,n=this._dataController.footerItems()[0];(!e||!e.columnIndices)&&(this.element().empty().addClass("dx-datagrid-total-footer").toggleClass("dx-datagrid-nowrap",!this.option("wordWrapEnabled")),t=!0),n&&n.summaryCells&&n.summaryCells.length&&(this._updateContent(this._renderTable({change:e}),e),t&&this._updateScrollLeftPosition())}_updateContent(e,t){return t&&t.changeType==="update"&&t.columnIndices?this.waitAsyncTemplates().done(()=>{let n=this.getTableElement().find(".dx-row"),o=e.find(".dx-row");this._updateCells(n,o,t.columnIndices[0])}):super._updateContent.apply(this,arguments)}_rowClick(e){let t=this._dataController.footerItems()[e.rowIndex]||{};this.executeAction("onRowClick",m({},e,t))}_columnOptionChanged(e){let{optionNames:t}=e;e.changeTypes.grouping||(t.width||t.visibleWidth)&&super._columnOptionChanged(e)}_handleDataChanged(e){let{changeType:t}=e;e.changeType==="update"&&e.repaintChangesOnly?e.totalColumnIndices?e.totalColumnIndices.length&&this.render(null,{changeType:"update",columnIndices:[e.totalColumnIndices]}):this.render():(t==="refresh"||t==="append"||t==="prepend")&&this.render()}_createRow(e){let t=super._createRow.apply(this,arguments);return e.rowType==="totalFooter"&&(t.addClass("dx-footer-row"),t.addClass(mZ),t.attr("tabindex",0)),t}getHeight(){return this.getElementHeight()}isVisible(){return!!this._dataController.footerItems().length}},fZ=i=>class extends i{init(){super.init.apply(this,arguments),this._editingController=this.getController("editing"),this._totalAggregates=[],this._summaryGetter=S}summaryGetter(e){if(!arguments.length)return this._summaryGetter;A(e)&&(this._summaryGetter=e)}summary(e){if(!arguments.length)return this._summaryGetter();this._summaryGetter=function(){return e}}totalAggregates(){return this._totalAggregates}isLastLevelGroupItemsPagingLocal(){let e=this.summary(),t=e?.sortByGroups();return t?.length}sortLastLevelGroupItems(e,t,n){let o=qi.multiLevelGroup(vt(e),t).toArray(),s=[];return n.forEach(r=>{FH(o,t.length,(a,l)=>{r.toString()===a.toString()&&(s=s.concat(l))})}),s}_customizeRemoteOperations(e){let t=this.summary();t&&(e.remoteOperations.summary?(!e.isCustomLoading||e.storeLoadOptions.isLoadingAll)&&(e.storeLoadOptions.group&&(e.remoteOperations.grouping?e.storeLoadOptions.groupSummary=t.groupAggregates:t.groupAggregates.length&&(e.remoteOperations.paging=!1)),e.storeLoadOptions.totalSummary=t.totalAggregates):(t.totalAggregates.length||t.groupAggregates.length&&e.storeLoadOptions.group)&&(e.remoteOperations.paging=!1)),super._customizeRemoteOperations.apply(this,arguments);let n=e.cachedData.extra;n!=null&&n.summary&&!e.isCustomLoading&&(e.storeLoadOptions.totalSummary=void 0)}_handleDataLoadedCore(e){let t=rn(e.storeLoadOptions.group||e.loadOptions.group||[]),n=e.remoteOperations||{},o=this.summaryGetter()(n);if(!e.isCustomLoading||e.storeLoadOptions.isLoadingAll){if(n.summary)!n.paging&&t.length&&o&&(n.grouping||AH(this,{groupAggregates:o.groupAggregates},e.data,t.length),e.data=TH(e.data,t,o));else if(!n.paging&&o){var s;let r=e.operationTypes||{};if(!Object.keys(r).some(l=>r[l])||!((s=e.cachedData)!==null&&s!==void 0&&(s=s.extra)!==null&&s!==void 0&&s.summary)||t.length&&o.groupAggregates.length){let l=AH(this,o,e.data,t.length);e.extra=q(e.extra)?e.extra:{},e.extra.summary=l,e.cachedData&&(e.cachedData.extra=e.extra)}e.data=TH(e.data,t,o)}}e.isCustomLoading||(this._totalAggregates=e.extra&&e.extra.summary||this._totalAggregates),super._handleDataLoadedCore(e)}};Pr.extend(fZ);var _Z=i=>class extends i{_isDataColumn(e){return e&&(!f(e.groupIndex)||e.showWhenGrouped)}_isGroupFooterVisible(){let e=this.option("summary.groupItems")||[];for(let t=0;t<e.length;t++){let n=e[t],o=this._columnsController.columnOption(n.showInColumn||n.column);if(n.showInGroupFooter&&this._isDataColumn(o))return!0}return!1}_processGroupItems(e,t,n){let o=n&&n.data,s=super._processGroupItems.apply(this,arguments);return n&&(n.isGroupFooterVisible===void 0&&(n.isGroupFooterVisible=this._isGroupFooterVisible()),o&&o.items&&n.isGroupFooterVisible&&(n.collectContinuationItems||!o.isContinuationOnNextPage)&&s.push({rowType:"groupFooter",key:n.path.slice(),data:o,groupIndex:n.path.length-1,values:[]})),s}_processGroupItem(e,t){let n=this;if(t.summaryGroupItems||(t.summaryGroupItems=n.option("summary.groupItems")||[]),e.rowType==="group"){let o=-1,s=-1;x(t.visibleColumns,function(r){let a=t.visibleColumns[r-1];e.groupIndex===this.groupIndex&&(o=this.index),r>0&&a.command==="expand"&&this.command!=="expand"&&(s=this.index)}),e.summaryCells=this._calculateSummaryCells(t.summaryGroupItems,VS(e.data),t.visibleColumns,(r,a)=>r.showInGroupFooter?-1:r.alignByColumn&&a&&!f(a.groupIndex)&&a.index!==s?a.index:o,!0)}return e.rowType==="groupFooter"&&(e.summaryCells=this._calculateSummaryCells(t.summaryGroupItems,VS(e.data),t.visibleColumns,(o,s)=>o.showInGroupFooter&&n._isDataColumn(s)?s.index:-1)),e}_calculateSummaryCells(e,t,n,o,s){let r=this,a=[],l={};return x(e,(d,c)=>{let h=r._columnsController.columnOption(c.column),p=c.showInColumn&&r._columnsController.columnOption(c.showInColumn)||h,g=o(c,p);if(g>=0){l[g]||(l[g]=[]);let C=t[d];if(C===C){let v;f(c.valueFormat)?v=c.valueFormat:c.summaryType!=="count"&&(v=H.getFormatByDataType(h&&h.dataType)),l[g].push(m({},c,{value:B(C)&&h&&h.deserializeValue?h.deserializeValue(C):C,valueFormat:v,columnCaption:h&&h.index!==g?h.caption:void 0}))}}}),dt(l)||n.forEach((d,c)=>{let h=n[c-1],p=s&&(h?.command==="expand"||d.command==="expand")?h?.index:d.index;a.push(l[p]||[])}),a}_getSummaryCells(e,t){let n=this,o=n._columnsController;return n._calculateSummaryCells(e,t,o.getVisibleColumns(),(s,r)=>n._isDataColumn(r)?r.index:-1)}_updateItemsCore(e){let t=this,n,o=t._dataSource,s=t._footerItems,r=s&&s[0]&&s[0].summaryCells,a=t.option("summary.totalItems");if(t._footerItems=[],o&&a&&a.length){let l=o.totalAggregates();n=t._getSummaryCells(a,l),e&&e.repaintChangesOnly&&r&&(e.totalColumnIndices=n.map((d,c)=>JSON.stringify(d)!==JSON.stringify(r[c])?c:-1).filter(d=>d>=0)),n.length&&t._footerItems.push({rowType:"totalFooter",summaryCells:n})}super._updateItemsCore(e)}_prepareUnsavedDataSelector(e){if(NS(this)){let t=this._editingController;if(t)return function(n){return n=t.getUpdatedData(n),e(n)}}return e}_prepareAggregateSelector(e,t){return e=this._prepareUnsavedDataSelector(e),t==="avg"||t==="sum"?function(n){let o=e(n);return f(o)?Number(o):o}:e}_getAggregates(e,t){let n=this,o=n.option("summary.calculateCustomSummary"),s=n.option("summary.skipEmptyValues");return He(e||[],r=>{let a=this._columnsController.columnOption(r.column),l=a&&a.calculateCellValue?a.calculateCellValue.bind(a):me(a?a.dataField:r.column),d=r.summaryType||"count",c=f(r.skipEmptyValues)?r.skipEmptyValues:s;if(t)return{selector:r.column,summaryType:d};let h=n._prepareAggregateSelector(l,d);if(d==="custom"){o||(Z.log("E1026"),o=function(){});let p={component:n.component,name:r.name};o(p),p.summaryProcess="calculate",d={seed(g){return p.summaryProcess="start",p.totalValue=void 0,p.groupIndex=g,delete p.value,o(p),p.totalValue},step(g,C){return p.summaryProcess="calculate",p.totalValue=g,p.value=C,o(p),p.totalValue},finalize(g){return p.summaryProcess="finalize",p.totalValue=g,delete p.value,o(p),p.totalValue}}}return{selector:h,aggregator:d,skipEmptyValues:c}})}_addSortInfo(e,t,n,o){if(t){let{groupIndex:s}=t;o=o||t.sortOrder,f(s)&&(e[s]=e[s]||[],e[s].push({selector:n,desc:o==="desc"}))}}_findSummaryItem(e,t){let n=-1;return f(t)&&x(e||[],function(o){if(this.name===t||o===t||this.summaryType===t||this.column===t||function(s){let{summaryType:r}=s,{column:a}=s;return r&&a&&`${r}_${a}`}(this)===t)return n=o,!1}),n}_getSummarySortByGroups(e,t){let n=this,o=n._columnsController,s=o.getGroupColumns(),r=[];if(!(!t||!t.length))return x(e||[],function(){let{sortOrder:a}=this,{groupColumn:l}=this,d=n._findSummaryItem(t,this.summaryItem);if(d<0)return;let c=function(h){return VS(h)[d]};f(l)?(l=o.columnOption(l),n._addSortInfo(r,l,c,a)):x(s,(h,p)=>{n._addSortInfo(r,p,c,a)})}),r}_createDataSourceAdapterCore(e,t){let n=this,o=super._createDataSourceAdapterCore(e,t);return o.summaryGetter(s=>n._getSummaryOptions(s||t)),o}_getSummaryOptions(e){let t=this,n=t.option("summary.groupItems"),o=t.option("summary.totalItems"),s=t.option("sortByGroupSummaryInfo"),r=t._getAggregates(n,e&&e.grouping&&e.summary),a=t._getAggregates(o,e&&e.summary),l=function(){return t._getSummarySortByGroups(s,n)};if(r.length||a.length)return{groupAggregates:r,totalAggregates:a,sortByGroups:l}}publicMethods(){let e=super.publicMethods();return e.push("getTotalSummaryValue"),e}getTotalSummaryValue(e){let t=this._findSummaryItem(this.option("summary.totalItems"),e),n=this._dataSource.totalAggregates();if(n.length&&t>-1)return n[t]}optionChanged(e){(e.name==="summary"||e.name==="sortByGroupSummaryInfo")&&(e.name="dataSource"),super.optionChanged(e)}init(){this._footerItems=[],super.init()}footerItems(){return this._footerItems}},CZ=i=>class extends i{_refreshSummary(){NS(this)&&!this.isSaving()&&this._dataController.refresh({load:!0,changesOnly:!0})}_addChange(e){let t=super._addChange.apply(this,arguments);return e.type&&this._refreshSummary(),t}_removeChange(){let e=super._removeChange.apply(this,arguments);return this._refreshSummary(),e}cancelEditData(){let e=super.cancelEditData.apply(this,arguments);return this._refreshSummary(),e}},xZ=i=>class extends i{_createRow(e){let t=super._createRow.apply(this,arguments);return e&&t.addClass(e.rowType==="groupFooter"?"dx-datagrid-group-footer":""),t}_renderCells(e,t){super._renderCells.apply(this,arguments),t.row.rowType==="group"&&t.row.summaryCells&&t.row.summaryCells.length&&this._renderGroupSummaryCells(e,t)}_hasAlignByColumnSummaryItems(e,t){return!f(t.columns[e].groupIndex)&&t.row.summaryCells[e].length}_getAlignByColumnCellCount(e,t){let n=0;for(let o=1;o<e;o++){let s=t.row.summaryCells.length-o;n=this._hasAlignByColumnSummaryItems(s,t)?o:n}return n}_renderGroupSummaryCells(e,t){let n=e.children().last(),o=Number(n.attr("colSpan"))||1,s=this._getAlignByColumnCellCount(o,t);this._renderGroupSummaryCellsCore(n,t,o,s)}_renderGroupSummaryCellsCore(e,t,n,o){if(o>0){e.attr("colSpan",n-o);for(let s=0;s<o;s++){let r=t.columns.length-o+s;this._renderCell(e.parent(),m({column:t.columns[r],columnIndex:this._getSummaryCellIndex(r,t.columns)},t))}}}_getSummaryCellIndex(e,t){return e}_getCellTemplate(e){return!e.column.command&&!f(e.column.groupIndex)&&e.summaryItems&&e.summaryItems.length?MH:super._getCellTemplate(e)}_getCellOptions(e){let t=this,n=super._getCellOptions(e);return e.row.summaryCells?m(n,RH(t,e)):n}};H.registerModule("summary",{defaultOptions:()=>({summary:{groupItems:void 0,totalItems:void 0,calculateCustomSummary:void 0,skipEmptyValues:!0,recalculateWhileEditing:!1,texts:{sum:O.format("dxDataGrid-summarySum"),sumOtherColumn:O.format("dxDataGrid-summarySumOtherColumn"),min:O.format("dxDataGrid-summaryMin"),minOtherColumn:O.format("dxDataGrid-summaryMinOtherColumn"),max:O.format("dxDataGrid-summaryMax"),maxOtherColumn:O.format("dxDataGrid-summaryMaxOtherColumn"),avg:O.format("dxDataGrid-summaryAvg"),avgOtherColumn:O.format("dxDataGrid-summaryAvgOtherColumn"),count:O.format("dxDataGrid-summaryCount")}},sortByGroupSummaryInfo:void 0}),views:{footerView:LS},extenders:{controllers:{data:_Z,editing:CZ},views:{rowsView:xZ}}});var vZ="dx-master-detail-row",qs=function(i){let e=-1;return x(i,(t,n)=>{if(n.command==="transparent")return e=t,!1}),e},VH=function(i,e,t){let n=0;if(i&&e&&t)for(let o=0;o<i.length;o++)i[o].command==="transparent"?n+=i[o].colspan:(e[n]<t[o]&&(e[n]=t[o]),n++);return e},HS=i=>class extends i{init(){super.init(),this._isFixedTableRendering=!1,this._isFixedColumns=!1}_createCol(e){return super._createCol(e).toggleClass("dx-col-fixed",!!(this._isFixedTableRendering&&(e.fixed||e.command&&e.command!=="transparent")))}isIndicesArray(e){return Array.isArray(e)&&e.length>0}_correctColumnIndicesForFixedColumns(e,t){var n;let o=t?.columnIndices;if(!this.isIndicesArray(o))return;let s=qs(e),r=e[s].colspan,a=s+r,l=t==null||(n=t.items)===null||n===void 0?void 0:n.map(d=>{let{rowType:c}=d;return c});t.columnIndices=o.map((d,c)=>this.isIndicesArray(d)?l&&l[c]==="group"?[...d]:d.reduce((p,g)=>{switch(!0){case g<s:p.push(g);break;case g>=a:p.push(g-r+1)}return p},[]):d)}_partialUpdateFixedTable(e,t){let n=this._fixedTableElement,o=this._getRowElementsCore(n);n.children("colgroup").replaceWith(this._createColGroup(e));for(let r=0;r<t.length;r++)this._partialUpdateFixedRow(u(o[r]),e,t[r])}_partialUpdateFixedRow(e,t,n){let o=e.get(0).childNodes,s=qs(t),r=t[s],a=this._columnsController.getColumnIndexOffset(),l,d=a+1,{colspan:c}=r;if(e.hasClass(vZ)){var h;o[0].setAttribute("colspan",(h=this._columnsController.getVisibleColumns())===null||h===void 0?void 0:h.length);return}if(e.hasClass("dx-group-row"))if(l=this._getGroupCellOptions({row:n,columns:this._columnsController.getVisibleColumns()}),n.summaryCells.length>0){let g=this._getAlignByColumnCellCount(l.colspan,{columns:this._columnsController.getVisibleColumns(),row:n,isFixed:!0});c=l.colspan-g}else c=l.colspan-Math.max(0,o.length-(l.columnIndex+2));for(let p=0;p<o.length;p++){let g=l?p===l.columnIndex+1:p===s;o[p].setAttribute("aria-colindex",d),g?(o[p].setAttribute("colspan",c),d+=c):d++}}_renderTable(e){let t,n=this.getFixedColumns();this._isFixedColumns=!!n.length;let o=super._renderTable(e);if(this._isFixedColumns){var s;let a=e?.change,l=this._getRowElements(this._fixedTableElement),d=a?.virtualColumnsScrolling&&l.length===(a==null||(s=a.items)===null||s===void 0?void 0:s.length);if(this._isFixedTableRendering=!0,d&&this.option("scrolling.legacyMode")!==!0){var r;this._partialUpdateFixedTable(n,e==null||(r=e.change)===null||r===void 0?void 0:r.items),this._isFixedTableRendering=!1}else{let c=a?.columnIndices;this._correctColumnIndicesForFixedColumns(n,a),t=this._createTable(n),this._renderRows(t,m({},e,{columns:n})),this._updateContent(t,a,!0),c&&(a.columnIndices=c),this._isFixedTableRendering=!1}}else this._fixedTableElement&&this._fixedTableElement.parent().remove(),this._fixedTableElement=null;return o}_renderRow(e,t){let n,{cells:o}=t.row;if(super._renderRow.apply(this,arguments),this._isFixedTableRendering&&o&&o.length){n=0;let s=t.row.cells||[];o=o.slice(),t.row.cells=o;for(let r=0;r<s.length;r++){if(s[r].column&&s[r].column.command==="transparent"){n=(s[r].column.colspan||1)-1;continue}o[r+n]=s[r]}}}_createCell(e){let t=this,{column:n}=e,o=n&&n.command,{rowType:s}=e,r=super._createCell.apply(t,arguments),a,l,d;(t._isFixedTableRendering||s==="filter")&&(a=t.getFixedColumns(),d=qs(a),l=a[d-1]),t._isFixedTableRendering?o==="transparent"&&(r.addClass("dx-pointer-events-none").toggleClass("dx-first-cell",d===0||l&&l.command==="expand").toggleClass("dx-last-cell",a.length&&d===a.length-1),s!=="freeSpace"&&M.setEmptyText(r)):s==="filter"&&r.toggleClass("dx-first-cell",e.columnIndex===d);let c=t.option("rowAlternationEnabled")&&e.isAltRow,h=t.option("selection.mode")==="multiple"&&e.columnIndex===0&&e.rowType==="header";return be.mozilla&&e.column.fixed&&e.rowType!=="group"&&!c&&!h&&r.addClass("dx-col-fixed"),r}_getContent(e){var t;return e?(t=this._fixedTableElement)===null||t===void 0?void 0:t.parent():super._getContent.apply(this,arguments)}_wrapTableInScrollContainer(e,t){let n=super._wrapTableInScrollContainer.apply(this,arguments);return(this._isFixedTableRendering||t)&&n.addClass(this.addWidgetPrefix("content-fixed")),n}_renderCellContent(e,t){let n,{column:o}=t,s=this._isFixedTableRendering,r=t.rowType==="group"&&f(o.groupIndex);if(s&&r&&!o.command&&!o.groupCellTemplate&&e.css("pointerEvents","none"),!s&&this._isFixedColumns){if(n=o.fixed||o.command&&o.fixed!==!1,r&&(n=!1,t.row.summaryCells&&t.row.summaryCells.length)){var a;let l=this._columnsController.getVisibleColumns(),d=((a=this._getAlignByColumnCellCount)===null||a===void 0?void 0:a.call(this,o.colspan,{columns:l,row:t.row,isFixed:!0}))??0;if(d>0){let c=qs(this._columnsController.getFixedColumns());n=l.length-d<c}}if(n){if(o.command&&o.type!=="buttons"||t.rowType==="group"){e.html("&nbsp;").addClass(o.cssClass);return}e.addClass("dx-hidden-cell")}}o.command!=="transparent"&&super._renderCellContent.apply(this,arguments)}_getCellElementsCore(e){let t=super._getCellElementsCore.apply(this,arguments),n=t?.parent().hasClass("dx-group-row"),o=this.name==="columnHeadersView"?e:void 0;if(this._fixedTableElement&&t){let s=this.getFixedColumns(o),r=this._getRowElements(this._fixedTableElement).eq(e).children("td");x(r,(a,l)=>{if(n)t[a]&&l.style.visibility!=="hidden"&&(t[a]=l);else{let d=s[a];if(d)if(d.command==="transparent")r.eq(a).hasClass("dx-master-detail-cell")&&(t[a]=l||t[a]);else{let c=this._columnsController.getVisibleIndexByColumn(d,o);t[c]=l||t[c]}}})}return t}getColumnWidths(e){let t=super.getColumnWidths(),n=this.getFixedColumns(),o=this._fixedTableElement&&t.length?super.getColumnWidths(this._fixedTableElement):void 0;return VH(n,t,o)}getTableElement(e){return e=this._isFixedTableRendering||e,e?this._fixedTableElement:super.getTableElement()}setTableElement(e,t){this._isFixedTableRendering||t?this._fixedTableElement=e.addClass("dx-pointer-events-none"):super.setTableElement(e)}getColumns(e){let t=this.getTableElement();return this._isFixedTableRendering?this.getFixedColumns(e):super.getColumns(e,t)}getRowIndex(e){let t=this._fixedTableElement;return t&&t.find(e).length?this._getRowElements(t).index(e):super.getRowIndex(e)}getTableElements(){let e=super.getTableElements.apply(this,arguments);return this._fixedTableElement&&(e=u([e.get(0),this._fixedTableElement.get(0)])),e}getFixedColumns(e){return this._columnsController.getFixedColumns(e)}getFixedColumnsOffset(){let e={left:0,right:0},t;if(this._fixedTableElement){t=this.getTransparentColumnElement();let n=t.position();e={left:n.left,right:ie(this.element(),!0)-(ie(t,!0)+n.left)}}return e}getTransparentColumnElement(){return this._fixedTableElement&&this._fixedTableElement.find(".dx-pointer-events-none").first()}getFixedTableElement(){return this._fixedTableElement}isFixedColumns(){return this._isFixedColumns}_resizeCore(){super._resizeCore(),this.synchronizeRows()}setColumnWidths(e){var t;let{widths:n}=e,o=this._columnsController.getVisibleColumns(),s=n?.length&&o.some(d=>f(d.visibleWidth)),r=(t=e.optionNames)===null||t===void 0?void 0:t.width;if(super.setColumnWidths(e),this._fixedTableElement){let h=n?.some(p=>p==="auto"||!f(p))&&(!s||!this.isScrollbarVisible(!0))?o:this.getFixedColumns();this.setFixedTableColumnWidths(h,n)}let a=this.option("wordWrapEnabled");(s||r&&a)&&this.synchronizeRows()}setFixedTableColumnWidths(e,t){if(!this._fixedTableElement||!t)return;let n=this._fixedTableElement.children("colgroup").children("col");n.toArray().forEach(s=>s.removeAttribute("style"));let o=0;e.forEach(s=>{if(s.colspan){o+=s.colspan;return}let r=kb(t[o]);f(r)&&$d(n.eq(o),r),o+=1})}_getClientHeight(e){let t=e.getBoundingClientRect&&Ie(e);return t&&t.height?t.height:e.clientHeight}synchronizeRows(){let e=[],t=[],n,o,s,r;this.waitAsyncTemplates(!0).done(()=>{if(this._isFixedColumns&&this._tableElement&&this._fixedTableElement){let a=this._getClientHeight(this._tableElement.get(0)),l=this._getClientHeight(this._fixedTableElement.get(0));if(o=this._getRowElements(this._tableElement),s=this._getRowElements(this._fixedTableElement),r=this._findContentElement(),a!==l){for(r&&r.css("height",a),o.css("height",""),s.css("height",""),n=0;n<o.length;n++)e.push(this._getClientHeight(o.get(n))),t.push(this._getClientHeight(s.get(n)));for(n=0;n<o.length;n++){let d=e[n],c=t[n];d>c?s.eq(n).css("height",d):d<c&&o.eq(n).css("height",c)}r&&r.css("height","")}}})}setScrollerSpacing(e,t){let n=this.option("rtlEnabled");super.setScrollerSpacing(e),this.element().children(`.${this.addWidgetPrefix("content-fixed")}`).css({paddingLeft:n?e:"",paddingRight:n?"":e})}},bZ=i=>class extends HS(i){_getRowVisibleColumns(e){return this._isFixedTableRendering?this.getFixedColumns(e):super._getRowVisibleColumns(e)}getContextMenuItems(e){let{column:t}=e,n=this.option("columnFixing"),o=super.getContextMenuItems(e);if(e.row&&e.row.rowType==="header"&&n.enabled===!0&&t&&t.allowFixing){let s=r=>{switch(r.itemData.value){case"none":this._columnsController.columnOption(t.index,"fixed",!1);break;case"left":this._columnsController.columnOption(t.index,{fixed:!0,fixedPosition:"left"});break;case"right":this._columnsController.columnOption(t.index,{fixed:!0,fixedPosition:"right"})}};o=o||[],o.push({text:n.texts.fix,beginGroup:!0,items:[{text:n.texts.leftPosition,value:"left",disabled:t.fixed&&(!t.fixedPosition||t.fixedPosition==="left"),onItemClick:s},{text:n.texts.rightPosition,value:"right",disabled:t.fixed&&t.fixedPosition==="right",onItemClick:s}]},{text:n.texts.unfix,value:"none",disabled:!t.fixed,onItemClick:s})}return o}getFixedColumnElements(e){let t=this;if(f(e))return this._fixedTableElement&&this._getRowElements(this._fixedTableElement).eq(e).children();let n=t.getColumnElements(),o=t.getTransparentColumnElement();if(n&&o&&o.length){let s=qs(t.getFixedColumns());n.splice(s,o.get(0).colSpan,o.get(0))}return n}getColumnWidths(){let e=this,t,n=super.getColumnWidths(),o=e.getFixedColumnElements(),s=e.getFixedColumns();return e._fixedTableElement&&(o&&o.length?t=e._getWidths(o):t=super.getColumnWidths(e._fixedTableElement)),VH(s,n,t)}},yZ=i=>class extends HS(i){dispose(){super.dispose.apply(this,arguments),clearTimeout(this._fixedScrollTimeout)}optionChanged(e){super.optionChanged(e),e.name==="hoverStateEnabled"&&this._isFixedColumns&&(e.value?this._attachHoverEvents():this._detachHoverEvents())}_detachHoverEvents(){let e=this.element();this._fixedTableElement&&this._tableElement&&_.off(e,"mouseover mouseout",".dx-data-row")}_attachHoverEvents(){this._fixedTableElement&&this._tableElement&&_.on(this.element(),"mouseover mouseout",".dx-data-row",this.createAction(e=>{let{event:t}=e,n=this.getRowIndex(u(t.target).closest(".dx-row")),o=t.type==="mouseover";n>=0&&(this._tableElement&&this._getRowElements(this._tableElement).eq(n).toggleClass("dx-state-hover",o),this._fixedTableElement&&this._getRowElements(this._fixedTableElement).eq(n).toggleClass("dx-state-hover",o))}))}_getScrollDelay(){var e;return((e=this._resizingController)===null||e===void 0?void 0:e.hasResizeTimeout())?this.option("scrolling.updateTimeout"):be.mozilla?60:0}_findContentElement(e){let t,n,o=this.addWidgetPrefix("content"),s=this.element();if(e=this._isFixedTableRendering||e,s&&e){t=s.children(`.${o}`);let r=this.getScrollable();return!t.length&&r&&(t=u("<div>").addClass(o),_.on(t,"scroll",a=>{let{target:l}=a,d=this._getScrollDelay();clearTimeout(this._fixedScrollTimeout),this._fixedScrollTimeout=setTimeout(()=>{n=u(l).scrollTop(),r.scrollTo({y:n})},d)}),_.on(t,dr,a=>{let l=u(a.target).closest(".dx-scrollable"),d=!1;if(r&&r.$element().is(l))d=!0;else{let c=l.length&&Pi.getInstance(l.get(0)),h=c&&c.scrollHeight()-c.clientHeight()>0;d=c&&!h}if(d){n=r.scrollTop(),r.scrollTo({y:n-a.delta});let c=r.scrollTop()+r.clientHeight(),h=r.scrollHeight()+this.getScrollbarWidth();if(r.scrollTop()>0&&c<h)return!1}}),t.appendTo(s)),t}return super._findContentElement()}_updateScrollable(){super._updateScrollable();let e=this.getScrollable();if(e!=null&&e._disposed)return;let t=e&&e.scrollOffset().top;this._updateFixedTablePosition(t)}_renderContent(e,t,n){return this._isFixedTableRendering||n?e.empty().addClass(`${this.addWidgetPrefix("content")} ${this.addWidgetPrefix("content-fixed")}`).append(t):super._renderContent(e,t)}_getGroupCellOptions(e){return this._isFixedTableRendering?super._getGroupCellOptions(m({},e,{columns:this._columnsController.getVisibleColumns()})):super._getGroupCellOptions(e)}_renderGroupedCells(e,t){return super._renderGroupedCells(e,m({},t,{columns:this._columnsController.getVisibleColumns()}))}_renderGroupSummaryCells(e,t){this._isFixedTableRendering?super._renderGroupSummaryCells(e,m({},t,{columns:this._columnsController.getVisibleColumns()})):super._renderGroupSummaryCells(e,t)}_hasAlignByColumnSummaryItems(e,t){let n=super._hasAlignByColumnSummaryItems.apply(this,arguments),o=t.columns[e];return t.isFixed?o.fixed&&(n||o.fixedPosition==="right"):n&&(!this._isFixedColumns||!o.fixed)}_renderGroupSummaryCellsCore(e,t,n,o){let s;if(this._isFixedTableRendering){t.isFixed=!0,s=this._getAlignByColumnCellCount(n,t),t.isFixed=!1;let r=t.columns.length-s;t=m({},t,{columns:this.getFixedColumns()});let a=qs(t.columns);r<a?(s-=t.columns[a].colspan-1||0,n-=t.columns[a].colspan-1||0):o>0&&e.css("visibility","hidden"),o=s}super._renderGroupSummaryCellsCore(e,t,n,o)}_getSummaryCellIndex(e,t){if(this._isFixedTableRendering){let n=qs(t);return e>n&&(e+=t[n].colspan-1),e}return super._getSummaryCellIndex.apply(this,arguments)}_renderCore(e){this._detachHoverEvents();let t=super._renderCore(e),n=this._isFixedColumns;return this.element().toggleClass("dx-fixed-columns",n),this.option("hoverStateEnabled")&&n&&this._attachHoverEvents(),t}setAriaOwns(e,t,n){if(n){var o;let s=this.addWidgetPrefix("content-fixed"),r=(o=this.element())===null||o===void 0?void 0:o.children(`.${s}`),a=this.getFixedTableElement();r.length&&a!==null&&a!==void 0&&a.length&&this.setAria("owns",`${e??""} ${a.attr("id")??""} ${t??""}`.trim(),r)}else super.setAriaOwns.apply(this,arguments)}setRowsOpacity(e,t){super.setRowsOpacity(e,t);let n=this._getRowElements(this._fixedTableElement);this._setRowsOpacityCore(n,this.getFixedColumns(),e,t)}getCellIndex(e){let t=this._fixedTableElement,n=0;if(t&&e.is("td")&&e.closest(t).length){let o=this.getFixedColumns();return x(o,(s,r)=>{if(s===e[0].cellIndex)return!1;if(r.colspan){n+=r.colspan;return}n++}),n}return super.getCellIndex.apply(this,arguments)}_updateFixedTablePosition(e,t){if(this._fixedTableElement&&this._tableElement){let n;this._fixedTableElement.parent().scrollTop(e),t&&this._editorFactoryController&&(n=this._editorFactoryController.focus(),n&&this._editorFactoryController.focus(n))}}setScrollerSpacing(e,t){let n=this,o={marginBottom:0},s=n.element().children(`.${this.addWidgetPrefix("content-fixed")}`);s.length&&n._fixedTableElement&&(s.css(o),n._fixedTableElement.css(o),o[n.option("rtlEnabled")?"marginLeft":"marginRight"]=e,o.marginBottom=t,(n._scrollable&&n._scrollable.option("useNative")?s:n._fixedTableElement).css(o))}_getElasticScrollTop(e){let t=0;if(e.scrollOffset.top<0)t=-e.scrollOffset.top;else if(e.reachedBottom){let n=u(e.component.content()),o=u(e.component.container()),s=Math.max(n.get(0).clientHeight-o.get(0).clientHeight,0);t=Math.min(s-e.scrollOffset.top,0)}return Math.floor(t)}_applyElasticScrolling(e){if(this._fixedTableElement){let t=this._getElasticScrollTop(e);Math.ceil(t)!==0?Ae(this._fixedTableElement,{top:t}):this._fixedTableElement.css("transform","")}}_handleScroll(e){this._updateFixedTablePosition(e.scrollOffset.top,!0),this._applyElasticScrolling(e),super._handleScroll(e)}_updateContentPosition(e){super._updateContentPosition.apply(this,arguments),e||this._updateFixedTablePosition(this._scrollTop)}_afterRowPrepared(e){this._isFixedTableRendering||super._afterRowPrepared(e)}_scrollToElement(e){super._scrollToElement(e,this.getFixedColumnsOffset())}},OZ=i=>class extends HS(i){},SZ=function(i,e,t){let n=qs(e),o=i.length-e.length;return x(t,(s,r)=>{r.index>n&&(r.columnIndex+=o,r.index+=o)}),t},EZ=i=>class extends i{_generatePointsByColumns(e){let t=e.columns,{targetDraggingPanel:n}=e;if(n&&n.getName()==="headers"&&n.isFixedColumns()&&e.sourceColumn.fixed){e.rowIndex||(e.columnElements=n.getFixedColumnElements(0)),e.columns=n.getFixedColumns(e.rowIndex);let o=super._generatePointsByColumns(e);return SZ(t,e.columns,o),o}return super._generatePointsByColumns(e)}_pointCreated(e,t,n,o){let s=super._pointCreated.apply(this,arguments),r=t[e.columnIndex],a=this._columnHeadersView.getTransparentColumnElement();if(!s&&n==="headers"&&a&&a.length){let l=Ie(a.get(0));return o&&o.fixed?o.fixedPosition==="right"?e.x<l.right:e.x>l.left:r&&r.fixed&&r.fixedPosition!=="right"?!0:e.x<l.left||e.x>l.right}return s}},wZ=i=>class extends i{_generatePointsByColumns(){let e=this,t=e._columnsController,n=t&&e._columnsController.getVisibleColumns(),o=t&&e._columnsController.getFixedColumns(),s=qs(o),r=n.length-o.length,a=e._columnHeadersView.getFixedColumnElements();super._generatePointsByColumns(),a&&a.length>0&&(e._pointsByFixedColumns=M.getPointsByColumns(a,l=>(l.index>s&&(l.columnIndex+=r,l.index+=r),e._pointCreated(l,n.length,n))))}_getTargetPoint(e,t,n){let o=this._columnHeadersView.getTransparentColumnElement();if(o&&o.length){let s=Ie(o.get(0));if(t<=s.left||t>=s.right)return super._getTargetPoint(this._pointsByFixedColumns,t,n)}return super._getTargetPoint(e,t,n)}},IZ=i=>class extends i{_setAriaOwns(){var e,t,n;super._setAriaOwns.apply(this,arguments);let o=(e=this._columnHeadersView)===null||e===void 0?void 0:e.getFixedTableElement(),s=(t=this._footerView)===null||t===void 0?void 0:t.getFixedTableElement();(n=this._rowsView)===null||n===void 0||n.setAriaOwns(o?.attr("id"),s?.attr("id"),!0)}},DZ=i=>class extends i{_toggleInertAttr(e){var t;let n=(t=this._rowsView)===null||t===void 0?void 0:t.getFixedContentElement();e?n?.attr("inert",!0):n?.removeAttr("inert")}},LH={defaultOptions:()=>({columnFixing:{enabled:!1,texts:{fix:O.format("dxDataGrid-columnFixingFix"),unfix:O.format("dxDataGrid-columnFixingUnfix"),leftPosition:O.format("dxDataGrid-columnFixingLeftPosition"),rightPosition:O.format("dxDataGrid-columnFixingRightPosition")}}}),extenders:{views:{columnHeadersView:bZ,rowsView:yZ,footerView:OZ},controllers:{draggingHeader:EZ,columnsResizer:wZ,resizing:IZ,keyboardNavigation:DZ}}};H.registerModule("columnFixing",LH);var NH="rowsView",TZ="footerView",$S=["columnHeadersView",NH,TZ],AZ="dxDataGridAdaptivity";var HH="dxDataGrid-ariaAdaptiveExpand",MZ="dxDataGrid-ariaAdaptiveCollapse",RZ="scrolling.legacyMode";function ff(i,e){return i._columnsController.getColumnId(e)}function FZ(i){return i.find("td:not(.dx-datagrid-hidden-column):not([class*='dx-command-'])")}function PZ(i,e){let t,n=u(i),o=e.component.getController("adaptiveColumns");e.rowType==="data"?(t=u("<span>").addClass(o.addWidgetPrefix("adaptive-more")),_.on(t,D(oe,AZ),o.createAction(()=>{o.toggleExpandAdaptiveDetailRow(e.key)})),t.appendTo(n)):M.setEmptyText(n)}function zS(i){var e;let t=(e=i.data)===null||e===void 0?void 0:e.$nextCell;_.off(t,"focus",zS),_.trigger(t,"dxclick")}var WS=class extends Ce.ViewController{init(){this._columnsController=this.getController("columns"),this._dataController=this.getController("data"),this._editingController=this.getController("editing"),this._keyboardNavigationController=this.getController("keyboardNavigation"),this._rowsView=this.getView("rowsView"),this._columnsController.addCommandColumn({type:"adaptive",command:"adaptive",visible:!0,adaptiveHidden:!0,cssClass:"dx-command-adaptive",alignment:"center",width:"auto",cellTemplate:PZ,fixedPosition:"right"}),this._columnsController.columnsChanged.add(()=>{let e=!!this.updateHidingQueue(this._columnsController.getColumns()).length;this._columnsController.columnOption("command:adaptive","adaptiveHidden",!e,!0)}),this._hidingColumnsQueue=[],this._hiddenColumns=[],this.createAction("onAdaptiveDetailRowPreparing"),super.init()}optionChanged(e){e.name==="columnHidingEnabled"&&this._columnsController.columnOption("command:adaptive","adaptiveHidden",!e.value),super.optionChanged(e)}publicMethods(){return["isAdaptiveDetailRowExpanded","expandAdaptiveDetailRow","collapseAdaptiveDetailRow"]}_isRowEditMode(){return this._getEditMode()==="row"}_isItemModified(e,t){let n=this._columnsController.getVisibleIndex(e.column.index),o=this._dataController.getRowIndexByKey(t.key),s=this._dataController.items()[o+1];return s&&s.modifiedValues&&f(s.modifiedValues[n])}_renderFormViewTemplate(e,t,n){let o=this,{column:s}=e,r=o.createAction(()=>{o._editingController.isEditing()&&_.trigger(n,oe)}),a=t.row.data,l=s.calculateCellValue(a),d=M.getDisplayValue(s,l,a,t.rowType),c=M.formatValue(d,s),h=this._editingController.isCellOrBatchEditMode(),p=o._rowsView;if(s.allowEditing&&this._keyboardNavigationController.isKeyboardEnabled()&&(n.attr("tabIndex",o.option("tabIndex")),h&&(_.off(n,"focus",r),_.on(n,"focus",r))),s.cellTemplate){let g=m({},t,{value:l,displayValue:d,text:c,column:s});p.renderTemplate(n,s.cellTemplate,g,Lo(n)).done(()=>{p._cellPrepared(n,t)})}else{let g=n.get(0);s.encodeHtml?g.textContent=c:g.innerHTML=c,n.addClass("dx-adaptive-item-text"),(!f(c)||c==="")&&n.html("&nbsp;"),o._isRowEditMode()||o._isItemModified(e,t)&&n.addClass("dx-item-modified"),p._cellPrepared(n,t)}}_getTemplate(e,t,n){let o=this,{column:s}=e,r=this._editingController;return function(a,l){let d=u(l),c=o._columnsController.getVisibleIndex(s.index),h=m({},t),p=function(){let g=o._isItemEdited(e);h.value=t.row.values[c],g||s.showEditorAlways?r.renderFormEditorTemplate(h,e,a,d,!g):(h.column=s,h.columnIndex=c,o._renderFormViewTemplate(e,h,d))};if(p(),h.watch){let g=h.watch(()=>({isItemEdited:o._isItemEdited(e),value:t.row.values[c]}),()=>{d.contents().remove(),d.removeClass("dx-adaptive-item-text"),p()});_.on(d,Gt,g)}}}_isVisibleColumnsValid(e){return!(e<2||e.length-function(){let t=0;for(let n=0;n<e.length;n++)e[n].command&&t++;return t}()<=1)}_calculatePercentWidths(e,t){let n=this,o=0;return t.forEach((s,r)=>{e[r]!=="adaptiveHidden"&&(o+=n._getItemPercentWidth(s))}),o}_isPercentWidth(e){return B(e)&&e.endsWith("%")}_isColumnHidden(e){return this._hiddenColumns.filter(t=>t.index===e.index).length>0}_getAverageColumnsWidth(e,t,n){let o=this,s=0,r=0;return t.forEach(a=>{if(!o._isColumnHidden(a)){let{width:l}=a;f(l)&&!isNaN(parseFloat(l))?s+=o._isPercentWidth(l)?o._calculatePercentWidth({visibleIndex:a.visibleIndex,columnsCount:t.length,columnsCanFit:n,bestFitWidth:a.bestFitWidth,columnWidth:l,containerWidth:e}):parseFloat(l):r++}}),(e-s)/r}_calculateColumnWidth(e,t,n,o){let s=ff(this,e),r=this._columnsController.columnOption(s,"width"),a=this._columnsController.columnOption(s,"bestFitWidth"),l=n.length,d;if(r&&r!=="auto")if(this._isPercentWidth(r))d=this._calculatePercentWidth({visibleIndex:e.visibleIndex,columnsCount:l,columnsCanFit:o,bestFitWidth:a,columnWidth:r,containerWidth:t});else return parseFloat(r);else d=this.option("columnAutoWidth")||e.command?a:this._getAverageColumnsWidth(t,n,o);return d}_calculatePercentWidth(e){let t=e.visibleIndex<e.columnsCount-1&&e.columnsCanFit,n=e.containerWidth*parseFloat(e.columnWidth)/100,o=e.columnsCanFit&&n<e.bestFitWidth?e.bestFitWidth:n;return t?e.containerWidth*parseFloat(e.columnWidth)/100:o}_getNotTruncatedColumnWidth(e,t,n,o){let s=ff(this,e),r=this._columnsController.columnOption(s,"width"),a=this._columnsController.columnOption(s,"bestFitWidth");if(r&&r!=="auto"&&!this._isPercentWidth(r))return parseFloat(r);let l=this._calculateColumnWidth(e,t,n,o);return l<a?null:l}_getItemPercentWidth(e){let t=0;return e.width&&this._isPercentWidth(e.width)&&(t=parseFloat(e.width)),t}_getCommandColumnsWidth(){let e=this,t=e._columnsController.getVisibleColumns(),n=0;return x(t,(o,s)=>{(s.index<0||s.command)&&(n+=e._columnsController.columnOption(ff(e,s),"bestFitWidth")||0)}),n}_isItemEdited(e){if(this.isFormOrPopupEditMode())return!1;if(this._isRowEditMode()){let t=this.option("editing.editRowKey");if(ve(t,this._dataController.adaptiveExpandedKey()))return!0}else{let t=this._dataController.getRowIndexByKey(this._dataController.adaptiveExpandedKey())+1,n=this._columnsController.getVisibleIndex(e.column.index);return this._editingController.isEditCell(t,n)}}_getFormItemsByHiddenColumns(e){let t=[];return x(e,(n,o)=>{t.push({column:o,name:o.name,dataField:o.dataField,visibleIndex:o.visibleIndex})}),t}_getAdaptiveColumnVisibleIndex(e){for(let t=0;t<e.length;t++)if(e[t].command==="adaptive")return t}_hideAdaptiveColumn(e,t){let n=this._getAdaptiveColumnVisibleIndex(t);f(n)&&(e[n]="adaptiveHidden",this._hideVisibleColumn({isCommandColumn:!0,visibleIndex:n}))}_showHiddenCellsInView(e){let{$cells:t,isCommandColumn:n}=e,o=this.addWidgetPrefix("hidden-column");n?(o="dx-command-adaptive-hidden",t.attr({tabIndex:0,"aria-hidden":null}).removeClass(o)):t.removeClass(o)}_showHiddenColumns(){for(let e=0;e<$S.length;e++){let t=this.getView($S[e]);if(t&&t.isVisible()&&t.element()){let n=t.name,o=t.element().find(".dx-command-adaptive-hidden");this._showHiddenCellsInView({viewName:n,$cells:o,isCommandColumn:!0});let s=t.element().find(`.${this.addWidgetPrefix("hidden-column")}`);this._showHiddenCellsInView({viewName:n,$cells:s})}}}_isCellValid(e){return e&&e.length&&!e.hasClass("dx-master-detail-cell")&&!e.hasClass("dx-group-cell")}_hideVisibleColumn(e){let{isCommandColumn:t,visibleIndex:n}=e,o=this;$S.forEach(s=>{let r=o.getView(s);r&&o._hideVisibleColumnInView({view:r,isCommandColumn:t,visibleIndex:n})})}_hideVisibleColumnInView(e){let{view:t,isCommandColumn:n,visibleIndex:o}=e,s=t.name,r,a=this._columnsController.getVisibleColumns()[o],l=this._editingController&&this._editingController.getEditFormRowIndex();if(t&&t.isVisible()&&a){let d=t.getRowsCount(),c=t._getRowElements();for(let h=0;h<d;h++)if(!(h===l&&s===NH&&this.option("editing.mode")!=="popup")){let g=s==="columnHeadersView"?this._columnsController.getVisibleIndex(a.index,h):o;if(g>=0){let C=c.eq(h);r=this._findCellElementInRow(C,g),this._isCellValid(r)&&this._hideVisibleCellInView({viewName:s,isCommandColumn:n,$cell:r})}}}}_findCellElementInRow(e,t){let n=e.children(),o=t,s=!1;if(e.hasClass("dx-group-row")){let a=e.find(".dx-group-cell"),l=a.attr("colspan");if(a.length&&f(l)){let d=parseInt(l),c=a.index()+d-1;t>c?o=t-d+1:s=!0}}return s?void 0:n.eq(o)}_hideVisibleCellInView(e){let{$cell:t,isCommandColumn:n}=e,o=n?"dx-command-adaptive-hidden":this.addWidgetPrefix("hidden-column");t.attr({tabIndex:-1,"aria-hidden":!0}).addClass(o)}_getEditMode(){return this._editingController.getEditMode()}isFormOrPopupEditMode(){let e=this._getEditMode();return e==="form"||e==="popup"}hideRedundantColumns(e,t,n){let o=this;if(this._hiddenColumns=[],o._isVisibleColumnsValid(t)&&n.length){let s=0,r=o.component.$element(),a=z(r)-o._getCommandColumnsWidth(),l=function(){return t.filter(C=>!C.command&&this._hiddenColumns.filter(v=>v.index===C.index).length===0)}.bind(this),d=l(),c=d.length,h,p,g;do{g=!1,s=0;let C=o._calculatePercentWidths(e,t),v=C<100&&C!==0;for(h=0;h<t.length;h++){let b=t[h],T=o._getNotTruncatedColumnWidth(b,a,d,v),R=ff(o,b),U=o._columnsController.columnOption(R,"width"),Q=o._columnsController.columnOption(R,"minWidth"),se=o._columnsController.columnOption(R,"bestFitWidth");if(e[h]==="adaptiveHidden"){p=!0;continue}if(!T&&!b.command&&!b.fixed){g=!0;break}(!U||U==="auto")&&(T=Math.max(se||0,Q||0)),(b.command!=="adaptive"||p)&&(s+=T)}if(g=g||s>z(r),g){let b=n.pop(),T=o._columnsController.getVisibleIndex(b.index);a+=o._calculateColumnWidth(b,a,d,v),o._hideVisibleColumn({visibleIndex:T}),e[T]="adaptiveHidden",this._hiddenColumns.push(b),d=l()}}while(g&&d.length>1&&n.length);c===d.length&&o._hideAdaptiveColumn(e,t)}else o._hideAdaptiveColumn(e,t)}getAdaptiveDetailItems(){return this._$itemContents}getItemContentByColumnIndex(e){let t;for(let n=0;n<this._$itemContents.length;n++){t=this._$itemContents.eq(n);let o=t.data("dx-form-item");if(o&&o.column&&this._columnsController.getVisibleIndex(o.column.index)===e)return t}}toggleExpandAdaptiveDetailRow(e,t){this.isFormOrPopupEditMode()&&this._editingController.isEditing()||this._dataController.toggleExpandAdaptiveDetailRow(e,t)}createFormByHiddenColumns(e,t){let n=this,o=u(e),s={items:n._getFormItemsByHiddenColumns(n._hiddenColumns),formID:`dx-${new Oe}`},r=it()?{colCount:2}:{};this.executeAction("onAdaptiveDetailRowPreparing",{formOptions:s}),n._$itemContents=null,n._form=n._createComponent(u("<div>").appendTo(o),Am,m(r,s,{customizeItem(a){let l=a.column||n._columnsController.columnOption(a.name||a.dataField);l&&(a.label=a.label||{},a.label.text=a.label.text||l.caption,a.column=l,a.template=n._getTemplate(a,t,n.updateForm.bind(n))),s.customizeItem&&s.customizeItem.call(this,a)},onContentReady(a){s.onContentReady&&s.onContentReady.call(this,a),n._$itemContents=o.find(".dx-field-item-content")}}))}hasAdaptiveDetailRowExpanded(){return f(this._dataController.adaptiveExpandedKey())}updateForm(e){this.hasAdaptiveDetailRowExpanded()&&this._form&&f(this._form._contentReadyAction)&&(e&&e.length?this._form.option("items",this._getFormItemsByHiddenColumns(e)):this._form.repaint())}updateHidingQueue(e){let t=this,n=e.filter(r=>r.visible&&!r.type&&!r.fixed&&!(f(r.groupIndex)&&r.groupIndex>=0)),o,s;if(t._hidingColumnsQueue=[],t.option("allowColumnResizing")&&t.option("columnResizingMode")==="widget")return t._hidingColumnsQueue;for(s=0;s<n.length;s++)f(n[s].hidingPriority)&&n[s].hidingPriority>=0&&(o=!0,t._hidingColumnsQueue[n[s].hidingPriority]=n[s]);if(o)t._hidingColumnsQueue.reverse();else if(t.option("columnHidingEnabled"))for(s=0;s<n.length;s++){let r=t._columnsController.getVisibleIndex(n[s].index);t._hidingColumnsQueue[r]=n[s]}return t._hidingColumnsQueue=t._hidingColumnsQueue.filter(Object),t._hidingColumnsQueue}getHiddenColumns(){return this._hiddenColumns}hasHiddenColumns(){return this._hiddenColumns.length>0}getHidingColumnsQueue(){return this._hidingColumnsQueue}isAdaptiveDetailRowExpanded(e){let t=this._dataController;return t.adaptiveExpandedKey()&&ve(t.adaptiveExpandedKey(),e)}expandAdaptiveDetailRow(e){this.hasAdaptiveDetailRowExpanded()||this.toggleExpandAdaptiveDetailRow(e)}collapseAdaptiveDetailRow(){this.hasAdaptiveDetailRowExpanded()&&this.toggleExpandAdaptiveDetailRow()}updateCommandAdaptiveAriaLabel(e,t){let n=this._dataController.getRowIndexByKey(e);if(n===-1)return;let o=u(this.component.getRowElement(n));this.setCommandAdaptiveAriaLabel(o,t)}setCommandAdaptiveAriaLabel(e,t){e.find(".dx-command-adaptive").attr("aria-label",O.format(t))}},kZ=i=>class extends i{_isCellValid(e,t){return super._isCellValid(e,t)&&!e.hasClass(this.addWidgetPrefix("hidden-column"))&&!e.hasClass("dx-command-adaptive-hidden")}_processNextCellInMasterDetail(e,t){super._processNextCellInMasterDetail(e,t);let n=this._editingController.isCellOrBatchEditMode();this._editingController.isEditing()&&e&&n&&!this._isInsideEditForm(e)&&(_.off(e,"focus",zS),_.on(e,"focus",{$nextCell:e},zS),_.trigger(t,"focus"))}_isCellElement(e){return super._isCellElement(e)||e.hasClass("dx-adaptive-item-text")}},BZ=i=>class extends i{_getCellTemplate(e){let t=this,{column:n}=e;return e.rowType==="detailAdaptive"&&n.command==="detail"?function(o,s){t._adaptiveColumnsController.createFormByHiddenColumns(u(o),s)}:super._getCellTemplate(e)}_createRow(e){let t=super._createRow.apply(this,arguments);return e&&e.rowType==="detailAdaptive"&&e.key===this._dataController.adaptiveExpandedKey()&&t.addClass("dx-adaptive-detail-row"),t}_renderCells(e,t){super._renderCells(e,t);let n=this._adaptiveColumnsController,o=n.getHidingColumnsQueue().length,s=n.getHiddenColumns().length;o&&!s&&FZ(e).last().addClass("dx-last-data-cell"),t.row.rowType==="data"&&n.setCommandAdaptiveAriaLabel(e,HH)}_getColumnIndexByElementCore(e){let t=e.closest(".dx-field-item-content");if(t.length&&t.closest(this.component.$element()).length){let n=t.length?t.first().data("dx-form-item"):null;return n&&n.column&&this._columnsController.getVisibleIndex(n.column.index)}return super._getColumnIndexByElementCore(e)}_cellPrepared(e,t){super._cellPrepared.apply(this,arguments),t.row.rowType!=="detailAdaptive"&&t.column.visibleWidth==="adaptiveHidden"&&e.addClass(this.addWidgetPrefix("hidden-column"))}getCell(e,t){let n=this._dataController.items()[e?.rowIndex];if(n?.rowType==="detailAdaptive"){let o=this._adaptiveColumnsController.getAdaptiveDetailItems();return super.getCell(e,t,o)}return super.getCell.apply(this,arguments)}_getCellElement(e,t){let n=this._dataController.items()[e];return n&&n.rowType==="detailAdaptive"?this._adaptiveColumnsController.getItemContentByColumnIndex(t):super._getCellElement.apply(this,arguments)}getContextMenuItems(e){var t;if(e.row&&e.row.rowType==="detailAdaptive"){let n=this._columnHeadersView,o=u(e.targetElement).closest(".dx-field-item-label").next().data("dx-form-item");return e.column=o?o.column:e.column,n.getContextMenuItems&&n.getContextMenuItems(e)}return(t=super.getContextMenuItems)===null||t===void 0?void 0:t.call(this,e)}isClickableElement(e){var t;return(((t=super.isClickableElement)===null||t===void 0?void 0:t.call(this,e))??!1)||!!e.closest(".dx-command-adaptive").length}},VZ=i=>class extends i{_updateColumnWidth(e,t){super._updateColumnWidth(e,e.visibleWidth==="adaptiveHidden"?e.bestFitWidth:t)}},LZ=i=>class extends i{_pointCreated(e,t,n){let o=super._pointCreated(e,t,n),s=n[e.columnIndex]||{},r=this._getNextColumnIndex(e.columnIndex),a=n[r]||{},l=r!==e.columnIndex+1&&a.command,d=s.visibleWidth==="adaptiveHidden"||l;return o||d}_getNextColumnIndex(e){let t=this._columnsController.getVisibleColumns(),n=super._getNextColumnIndex(e);for(;t[n]&&t[n].visibleWidth==="adaptiveHidden";)n++;return n}},NZ=i=>class extends i{_pointCreated(e,t,n,o){let s=super._pointCreated(e,t,n,o),a=(t[e.columnIndex-1]||{}).visibleWidth==="adaptiveHidden";return s||a}},HZ=i=>class extends i{_isRowEditMode(){return this.getEditMode()==="row"}_getFormEditItemTemplate(e,t){return this.getEditMode()!=="row"&&e.rowType==="detailAdaptive"?(e.columnIndex=this._columnsController.getVisibleIndex(t.index),this.getColumnTemplate(e)):super._getFormEditItemTemplate(e,t)}_closeEditItem(e){let t=e.closest(".dx-field-item-content"),n=this._dataController.getRowIndexByKey(this._dataController.adaptiveExpandedKey())+1,o=t.length?t.first().data("dx-form-item"):null,s=o&&o.column&&this._columnsController.getVisibleIndex(o.column.index);this.isEditCell(n,s)||super._closeEditItem(e)}_beforeUpdateItems(e,t){if(!this._adaptiveColumnsController.isFormOrPopupEditMode()&&this._adaptiveColumnsController.hasHiddenColumns()){let n=this._dataController.items(),o=n[t],s=M.getIndexByKey(this._dataController.adaptiveExpandedKey(),n);this._isForceRowAdaptiveExpand=!this._adaptiveColumnsController.hasAdaptiveDetailRowExpanded(),s>=0&&e.push(s+1),e.push(t+1),this._dataController.adaptiveExpandedKey(o.key)}}_afterInsertRow(e){super._afterInsertRow.apply(this,arguments),this._adaptiveColumnsController.hasHiddenColumns()&&(this._adaptiveColumnsController.toggleExpandAdaptiveDetailRow(e,this.isRowEditMode()),this._isForceRowAdaptiveExpand=!0)}_collapseAdaptiveDetailRow(){this._isRowEditMode()&&this._isForceRowAdaptiveExpand&&(this._adaptiveColumnsController.collapseAdaptiveDetailRow(),this._isForceRowAdaptiveExpand=!1)}_cancelEditAdaptiveDetailRow(){this._adaptiveColumnsController.hasHiddenColumns()&&this._collapseAdaptiveDetailRow()}_afterSaveEditData(){super._afterSaveEditData.apply(this,arguments);let e=new y;return this._isRowEditMode()&&this._adaptiveColumnsController.hasHiddenColumns()?P(this._validatingController.validate(!0)).done(t=>{t&&this._cancelEditAdaptiveDetailRow(),e.resolve()}):e.resolve(),e.promise()}_beforeCancelEditData(){super._beforeCancelEditData(),this._cancelEditAdaptiveDetailRow()}_getRowIndicesForCascadeUpdating(e){let t=super._getRowIndicesForCascadeUpdating.apply(this,arguments);return this._adaptiveColumnsController.isAdaptiveDetailRowExpanded(e.key)&&t.push(e.rowType==="detailAdaptive"?e.rowIndex-1:e.rowIndex+1),t}_beforeCloseEditCellInBatchMode(e){let t=this._dataController._adaptiveExpandedKey;if(t){let n=M.getIndexByKey(t,this._dataController.items());n>-1&&e.unshift(n)}}editRow(e){return this._adaptiveColumnsController.isFormOrPopupEditMode()&&this._adaptiveColumnsController.collapseAdaptiveDetailRow(),super.editRow(e)}deleteRow(e){let t=this._dataController.getKeyByRowIndex(e);this.getEditMode()==="batch"&&this._adaptiveColumnsController.isAdaptiveDetailRowExpanded(t)&&this._adaptiveColumnsController.collapseAdaptiveDetailRow(),super.deleteRow(e)}},$Z=i=>class extends i{init(){super.init(),this._adaptiveExpandedKey=void 0}_processItems(e,t){let{changeType:n}=t;if(e=super._processItems.apply(this,arguments),n==="loadingAll"||!f(this._adaptiveExpandedKey))return e;let o=M.getIndexByKey(this._adaptiveExpandedKey,e),s=this.option(RZ)===!1;if(o>=0){let r=e[o];e.splice(o+1,0,{visible:!0,rowType:"detailAdaptive",key:r.key,data:r.data,node:r.node,modifiedValues:r.modifiedValues,isNewRow:r.isNewRow,values:r.values})}else n==="refresh"&&!(s&&t.repaintChangesOnly)&&(this._adaptiveExpandedKey=void 0);return e}_getRowIndicesForExpand(e){let t=super._getRowIndicesForExpand.apply(this,arguments);if(this._adaptiveColumnsController.isAdaptiveDetailRowExpanded(e)){let n=t[t.length-1];t.push(n+1)}return t}adaptiveExpandedKey(e){if(f(e))this._adaptiveExpandedKey=e;else return this._adaptiveExpandedKey}toggleExpandAdaptiveDetailRow(e,t){let n=M.getIndexByKey(this._adaptiveExpandedKey,this._items),o=M.getIndexByKey(e,this._items);n>=0&&n===o&&!t&&(e=void 0,o=-1);let s=this._adaptiveExpandedKey;this._adaptiveExpandedKey=e,n>=0&&n++,o>=0&&o++;let r=this.getRowIndexDelta();this.updateItems({allowInvisibleRowIndices:!0,changeType:"update",rowIndices:[n-r,o-r]}),this._adaptiveColumnsController.updateCommandAdaptiveAriaLabel(e,MZ),this._adaptiveColumnsController.updateCommandAdaptiveAriaLabel(s,HH)}},zZ=i=>class extends i{_needHideBorder(e){return super._needHideBorder(e)||e?.hasClass("dx-field-item-content")&&e?.find(".dx-checkbox").length}_getFocusCellSelector(){return`${super._getFocusCellSelector()}, .dx-adaptive-detail-row .dx-field-item > .dx-field-item-content`}_getRevertTooltipsSelector(){return`${super._getRevertTooltipsSelector()}, .dx-field-item-content .${this.addWidgetPrefix("revert-tooltip")}`}},WZ=i=>class extends i{_isColumnVisible(e){return super._isColumnVisible(e)&&!e.adaptiveHidden}},GZ=i=>class extends i{dispose(){super.dispose.apply(this,arguments),clearTimeout(this._updateScrollableTimeoutID)}_needBestFit(){return super._needBestFit()||!!this._adaptiveColumnsController.getHidingColumnsQueue().length}_correctColumnWidths(e,t){let n=this._adaptiveColumnsController,o=n.getHiddenColumns(),s=n.updateHidingQueue(this._columnsController.getColumns());n.hideRedundantColumns(e,t,s);let r=n.getHiddenColumns();return n.hasAdaptiveDetailRowExpanded()&&o.length!==r.length&&n.updateForm(r),!r.length&&n.collapseAdaptiveDetailRow(),super._correctColumnWidths.apply(this,arguments)}_toggleBestFitMode(e){e&&this._adaptiveColumnsController._showHiddenColumns(),super._toggleBestFitMode(e)}_needStretch(){let e=this._adaptiveColumnsController;return super._needStretch.apply(this,arguments)||e.getHidingColumnsQueue().length||e.hasHiddenColumns()}},$H={defaultOptions:()=>({columnHidingEnabled:!1,onAdaptiveDetailRowPreparing:null}),controllers:{adaptiveColumns:WS},extenders:{views:{rowsView:BZ},controllers:{export:VZ,columnsResizer:LZ,draggingHeader:NZ,editing:HZ,resizing:GZ,data:$Z,editorFactory:zZ,columns:WZ,keyboardNavigation:kZ}}};H.registerModule("adaptivity",$H);function zH(i,e,t,n,o,s){t=t||0,n=n||[],s=s||[],n[t]=n[t]||0;let r=i[t],a=s[t]+1||0,l=0,d;if(r){for(d=a;d<r.length;d++){let c=r[d],h=d+n[t],p=c.colspan||1;if(zH(i,e,t+(c.rowspan||1),n,p,s),n[t]+=p-1,l+=p,c.rowspan)for(let g=t+1;g<t+c.rowspan;g++)n[g]=n[g]||0,n[g]+=c.colspan||1;if(e(c,h,t,d)===!1||o!==void 0&&l>=o)break}s[t]=d}}function _f(i,e,t){let n=[];zH(i,(o,s,r)=>{let a=o,l,d=a.colspan||1,c=s+d-1>=e&&s<t;if(n[r]=n[r]||[],c)s<e?(l=d-(e-s),s=e):l=d,s+l>t&&(l=t-s),l!==d&&(a=m({},a,{colspan:l})),n[r].push(a);else if(s>t)return!1});for(let o=0;o<n.length;o++)n[o]=n[o]||[];return n}var WH=i=>class extends i{_needToSetCellWidths(){let e=super._needToSetCellWidths();return!e&&this._columnsController.isVirtualMode()&&(e=this._columnsController.getColumns().some(n=>n.width==="auto")),e}},KZ=i=>class extends WH(i){_resizeCore(){super._resizeCore.apply(this,arguments),this._columnsController.resize()}_handleScroll(e){let t=this.getScrollable(),{left:n}=e.scrollOffset;super._handleScroll.apply(this,arguments),this.option("rtlEnabled")&&t&&(n=z(t.$content())-z(t.$element())-n),this._columnsController.setScrollPosition(n)}_renderCore(e){if(e!=null&&e.virtualColumnsScrolling){var t,n;let o=this._findContentElement(),s=(t=this._columnsController)===null||t===void 0?void 0:t.getFixedColumns(),r=(n=this._scrollable)===null||n===void 0?void 0:n.option("useNative");if(s!=null&&s.length){o.css({minHeight:r?Y(o):M.getContentHeightLimit(be)});let a=()=>{this.resizeCompleted.remove(a),o.css({minHeight:""})};this.resizeCompleted.add(a)}}return super._renderCore.apply(this,arguments)}},UZ=i=>class extends WH(i){_renderCore(){let e=super._renderCore.apply(this,arguments);return this._columnsController.isVirtualMode()&&this._updateScrollLeftPosition(),e}},Cf=function(i){return i.map(e=>e.visibleWidth||parseFloat(e.width)||50)},jZ=i=>class extends i{init(){super.init.apply(this,arguments),this._resizingController=this.getController("resizing"),this._beginPageIndex=null,this._endPageIndex=null,this._position??(this._position=0),this._virtualVisibleColumns={}}dispose(){clearTimeout(this._changedTimeout),super.dispose.apply(this,arguments)}resetColumnsCache(){super.resetColumnsCache(),this._virtualVisibleColumns={}}getBeginPageIndex(e){let t=this.getVisibleColumns(void 0,!0),n=Cf(t),o=0;for(let s=0;s<n.length;s++){if(o>=e)return Math.floor(s/this.getColumnPageSize());o+=n[s]}return 0}getTotalWidth(){let e=this.option("width");return typeof e=="number"?e:this._resizingController._lastWidth||ie(this.component.$element())}getEndPageIndex(e){let t=this.getVisibleColumns(void 0,!0),n=Cf(t),o=0;e+=this.getTotalWidth();for(let s=0;s<n.length;s++){if(o>=e)return Math.ceil(s/this.getColumnPageSize());o+=n[s]}return Math.ceil(n.length/this.getColumnPageSize())}getColumnPageSize(){return this.option("scrolling.columnPageSize")}_fireColumnsChanged(){let e=new Date;this.columnsChanged.fire({optionNames:{all:!0,length:1},changeTypes:{columns:!0,virtualColumnsScrolling:!0,length:2}}),this._renderTime=new Date-e}getScrollingTimeout(){let e=this.option("scrolling.columnRenderingThreshold"),t=this.option("scrolling.renderAsync"),n=0;return(!f(t)&&this._renderTime>e||t)&&(n=this.option("scrolling.timeout")),n}setScrollPosition(e){let t=this.getScrollingTimeout();t>0?(clearTimeout(this._changedTimeout),this._changedTimeout=setTimeout(()=>{this._setScrollPositionCore(e)},t)):this._setScrollPositionCore(e)}isVirtualMode(){return W()&&this.option("scrolling.columnRenderingMode")==="virtual"}resize(){this._setScrollPositionCore(this._position)}_setScrollPositionCore(e){let t=this;if(t.isVirtualMode()){let n=t.getBeginPageIndex(e),o=t.getEndPageIndex(e),s=e<t._position?t._beginPageIndex>n:t._endPageIndex<o;t._position=e,s&&(t._beginPageIndex=n,t._endPageIndex=o,t._fireColumnsChanged())}}getFixedColumns(e,t){let n=super.getFixedColumns(e);if(this.isVirtualMode()&&!t&&n.length){let o=n.map(s=>s.command).indexOf("transparent");return n[o].colspan=this.getVisibleColumns().length-super.getFixedColumns().length+1,n}return n}_compileVisibleColumns(e,t){var n;if(t||!this.isVirtualMode()||!this._shouldReturnVisibleColumns())return super._compileVisibleColumns(e);(n=this._columns)!==null&&n!==void 0&&n.length&&!f(this._beginPageIndex)&&!f(this._endPageIndex)&&(this._beginPageIndex=this.getBeginPageIndex(this._position),this._endPageIndex=this.getEndPageIndex(this._position));let o=this._beginPageIndex,s=this._endPageIndex,r=`${e}-${o}-${s}`;if(this._virtualVisibleColumns[r])return this._virtualVisibleColumns[r];let a=super._compileVisibleColumns(),l=this.getRowCount(),d=this.getColumnPageSize(),c=o*d,h=s*d,p=this.getFixedColumns(void 0,!0),g=p.map(re=>re.command).indexOf("transparent"),C=p.length?g:0,v=a.slice(0,C),b=a.slice(C,c),T=Cf(b).reduce((re,Re)=>re+Re,0);T||(c=0);let R=p.length?p.length-g-1:0,U=a.slice(a.length-R),Q=a.slice(h,a.length-R),se=Cf(Q).reduce((re,Re)=>re+Re,0);if(se||(h=a.length),l>1&&typeof e=="number"){let re=[];for(let Re=0;Re<=l;Re++)re.push(super._compileVisibleColumns(Re));v=_f(re,0,v.length)[e]||[],U=_f(re,a.length-U.length,a.length)[e]||[],a=_f(re,c,h)[e]||[]}else a=a.slice(c,h);return T&&(a.unshift({command:"virtual",type:"virtual",width:T}),a=v.concat(a)),se&&(a.push({command:"virtual",type:"virtual",width:se}),a=a.concat(U)),this._virtualVisibleColumns[r]=a,a}getColumnIndexOffset(){let e=0;if(this._beginPageIndex>0){let n=this.getFixedColumns().map(s=>s.command).indexOf("transparent"),o=n>=0?n:0;e=this._beginPageIndex*this.getColumnPageSize()-o-1}return e>0?e:0}},GH={defaultOptions:()=>({scrolling:{columnRenderingMode:"standard",columnPageSize:5,columnRenderingThreshold:300}}),extenders:{controllers:{columns:jZ},views:{columnHeadersView:UZ,rowsView:KZ}}};H.registerModule("virtualColumns",GH);var GS=class{constructor(e,t){let{key:n}=t;this._isSharedDataSource=!1,this._keyExpr=n,this.updateDataSource(e)}_updateDataSource(e){if(e)if(e instanceof jt)this._isSharedDataSource=!0,this._dataSource=e;else{let t=Yi(e);this._dataSource=new jt(m(!0,{},{},t))}}_updateDataSourceByItems(e){this._dataSource=new jt({store:new No({key:this.key(),data:e}),pageSize:0})}_disposeDataSource(){this._dataSource&&(this._isSharedDataSource?this._isSharedDataSource=!1:this._dataSource.dispose(),delete this._dataSource)}load(){return this._dataSource.load()}loadSingle(e,t){if(!this._dataSource)return new y().reject();let n=e,o=t;return arguments.length<2&&(o=e,n=this.key()),this._dataSource.loadSingle(n,o)}loadFromStore(e){return this.store().load(e)}loadNextPage(){return this.pageIndex(1+this.pageIndex()),this.load()}loadOptions(){return this._dataSource.loadOptions()}userData(){return this._dataSource._userData}cancel(e){this._dataSource.cancel(e)}cancelAll(){this._dataSource.cancelAll()}filter(e){return this._dataSource.filter(e)}addSearchFilter(e){this._dataSource._addSearchFilter(e)}group(e){return this._dataSource.group(e)}paginate(){return this._dataSource.paginate()}pageSize(){return this._dataSource._pageSize}pageIndex(e){return e===void 0?this._dataSource.pageIndex(void 0):this._dataSource.pageIndex(e)}resetDataSource(){this._disposeDataSource()}resetDataSourcePageIndex(){this.pageIndex()&&(this.pageIndex(0),this.load())}updateDataSource(e,t){let n=e??this.items();t&&(this._keyExpr=t),this._disposeDataSource(),Array.isArray(n)?this._updateDataSourceByItems(n):this._updateDataSource(n)}totalCount(){return this._dataSource.totalCount()}isLastPage(){return this._dataSource.isLastPage()||!this._dataSource._pageSize}isLoading(){return this._dataSource.isLoading()}isLoaded(){return this._dataSource.isLoaded()}searchValue(e){return this._dataSource.searchValue(e)}searchOperation(e){return this._dataSource.searchOperation(e)}searchExpr(e){return this._dataSource.searchExpr(e)}select(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this._dataSource.select(t)}key(){var e;let t=(e=this._dataSource)===null||e===void 0?void 0:e.key();return f(t)&&this._keyExpr==="this"?t:this._keyExpr}keyOf(e){return this.store().keyOf(e)}store(){return this._dataSource.store()}items(){var e;return(e=this._dataSource)===null||e===void 0?void 0:e.items()}applyMapFunction(e){return this._dataSource._applyMapFunction(e)}getDataSource(){return this._dataSource??null}reload(){return this._dataSource.reload()}on(e,t){this._dataSource.on(e,t)}off(e,t){this._dataSource.off(e,t)}},KH=GS;var UH=KH;var qZ="dx-dropdownbutton-content";var YZ=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{itemTemplate:"item",keyExpr:"this",displayExpr:void 0,selectedItem:null,selectedItemKey:null,stylingMode:"outlined",deferRendering:!0,noDataText:O.format("dxCollectionWidget-noDataText"),useSelectMode:!1,splitButton:!1,showArrowIcon:!0,template:null,text:"",type:"normal",icon:void 0,onButtonClick:null,onSelectionChanged:null,onItemClick:null,opened:!1,items:null,dataSource:null,focusStateEnabled:!0,hoverStateEnabled:!0,dropDownOptions:{},dropDownContentTemplate:"content",wrapItemText:!1,useItemTextAsTitle:!0,grouped:!1,groupTemplate:"group",buttonGroupOptions:{}})},_setOptionsByReference(){this.callBase(),m(this._optionsByReference,{selectedItem:!0})},_init(){this.callBase(),this._createItemClickAction(),this._createActionClickAction(),this._createSelectionChangedAction(),this._initDataController(),this._compileKeyGetter(),this._compileDisplayGetter(),this._options.cache("buttonGroupOptions",this.option("buttonGroupOptions")),this._options.cache("dropDownOptions",this.option("dropDownOptions"))},_initDataController(){let i=this.option("dataSource");this._dataController=new UH(i??this.option("items"),{key:this.option("keyExpr")})},_initTemplates(){this._templateManager.addDefaultTemplates({content:new gn(i=>{let e=u(i.container),t=u("<div>").appendTo(e);this._list=this._createComponent(t,jo,this._listOptions()),this._list.registerKeyHandler("escape",this._escHandler.bind(this)),this._list.registerKeyHandler("tab",this._escHandler.bind(this)),this._list.registerKeyHandler("leftArrow",this._escHandler.bind(this)),this._list.registerKeyHandler("rightArrow",this._escHandler.bind(this))})}),this.callBase()},_compileKeyGetter(){this._keyGetter=me(this._dataController.key())},_compileDisplayGetter(){this._displayGetter=me(this.option("displayExpr"))},_initMarkup(){this.callBase(),this.$element().addClass("dx-dropdownbutton"),this._renderButtonGroup(),this._updateArrowClass(),f(this.option("selectedItemKey"))&&this._loadSelectedItem().done(this._updateActionButton.bind(this))},_renderFocusTarget:S,_render(){(!this.option("deferRendering")||this.option("opened"))&&this._renderPopup(),this.callBase()},_renderContentImpl(){return this._popup&&this._renderPopupContent(),this.callBase()},_loadSelectedItem(){var i;(i=this._loadSingleDeferred)===null||i===void 0||i.reject();let e=y();if(this._list&&this._lastSelectedItemData!==void 0){let n=this.option("useSelectMode")?this._list.option("selectedItem"):this._lastSelectedItemData;return e.resolve(n)}this._lastSelectedItemData=void 0;let t=this.option("selectedItemKey");return this._dataController.loadSingle(t).done(e.resolve).fail(()=>{e.reject(null)}),this._loadSingleDeferred=e,e.promise()},_createActionClickAction(){this._actionClickAction=this._createActionByOption("onButtonClick")},_createSelectionChangedAction(){this._selectionChangedAction=this._createActionByOption("onSelectionChanged")},_createItemClickAction(){this._itemClickAction=this._createActionByOption("onItemClick")},_fireSelectionChangedAction(i){let{previousValue:e,value:t}=i;this._selectionChangedAction({item:t,previousItem:e})},_fireItemClickAction(i){let{event:e,itemElement:t,itemData:n}=i;return this._itemClickAction({event:e,itemElement:t,itemData:this._actionItem||n})},_getButtonTemplate(){let{template:i,splitButton:e,showArrowIcon:t}=this.option();return i||(e||!t?"content":(n,o)=>{let{text:s,icon:r}=n,a=ci(r),l=s?u("<span>").text(s).addClass("dx-button-text"):void 0,d=ci("spindown").addClass("dx-icon-right");u(o).append(a,l,d)})},_getActionButtonConfig(){let{icon:i,text:e,type:t,splitButton:n}=this.option(),o={text:e,icon:i,type:t,template:this._getButtonTemplate(),elementAttr:{class:"dx-dropdownbutton-action"}};return n&&(o.elementAttr.role="menuitem"),o},_getSpinButtonConfig(){let{type:i}=this.option();return{type:i,icon:"spindown",elementAttr:{class:"dx-dropdownbutton-toggle",role:"menuitem"}}},_getButtonGroupItems(){let{splitButton:i}=this.option(),e=[this._getActionButtonConfig()];return i&&e.push(this._getSpinButtonConfig()),e},_buttonGroupItemClick(i){let{event:e,itemData:t}=i,n=t.elementAttr.class==="dx-dropdownbutton-action";t.elementAttr.class==="dx-dropdownbutton-toggle"?this.toggle():n&&(this._actionClickAction({event:e,selectedItem:this.option("selectedItem")}),this.option("splitButton")||this.toggle())},_getButtonGroupOptions(){let{accessKey:i,focusStateEnabled:e,hoverStateEnabled:t,splitButton:n,stylingMode:o,tabIndex:s}=this.option();return m({items:this._getButtonGroupItems(),width:"100%",height:"100%",selectionMode:"none",focusStateEnabled:e,hoverStateEnabled:t,stylingMode:o,accessKey:i,tabIndex:s,elementAttr:{role:n?"menu":"group"},onItemClick:this._buttonGroupItemClick.bind(this),onKeyboardHandled:a=>this._keyboardHandler(a)},this._options.cache("buttonGroupOptions"))},_renderPopupContent(){let i=this._popup.$content(),e=this._getTemplateByOption("dropDownContentTemplate");return i.empty(),this._popupContentId=`dx-${new Oe}`,this.setAria("id",this._popupContentId,i),e.render({container:N(i),model:this.option("items")||this._dataController.getDataSource()})},_popupOptions(){let i=this.option("rtlEnabled")?"right":"left";return m({dragEnabled:!1,focusStateEnabled:!1,deferRendering:this.option("deferRendering"),hideOnOutsideClick:e=>{let t=this.$element();return!u(e.target).closest(".dx-dropdownbutton").is(t)},showTitle:!1,animation:{show:{type:"fade",duration:0,from:0,to:1},hide:{type:"fade",duration:400,from:1,to:0}},_ignoreFunctionValueDeprecation:!0,width:()=>Hl(this.$element()),height:"auto",shading:!1,position:{of:this.$element(),collision:"flipfit",my:`${i} top`,at:`${i} bottom`},_wrapperClassExternal:"dx-dropdowneditor-overlay"},this._options.cache("dropDownOptions"),{visible:this.option("opened")})},_listOptions(){let i=this.option("selectedItemKey"),e=this.option("useSelectMode");return{selectionMode:e?"single":"none",wrapItemText:this.option("wrapItemText"),focusStateEnabled:this.option("focusStateEnabled"),hoverStateEnabled:this.option("hoverStateEnabled"),useItemTextAsTitle:this.option("useItemTextAsTitle"),onContentReady:()=>this._fireContentReadyAction(),selectedItemKeys:f(i)&&e?[i]:[],grouped:this.option("grouped"),groupTemplate:this.option("groupTemplate"),keyExpr:this._dataController.key(),noDataText:this.option("noDataText"),displayExpr:this.option("displayExpr"),itemTemplate:this.option("itemTemplate"),items:this.option("items"),dataSource:this._dataController.getDataSource(),onItemClick:t=>{this.option("useSelectMode")||(this._lastSelectedItemData=t.itemData),this.option("selectedItemKey",this._keyGetter(t.itemData)),this._fireItemClickAction(t)!==!1&&(this.toggle(!1),this._buttonGroup.focus())}}},_upDownKeyHandler(){return this._popup&&this._popup.option("visible")&&this._list?this._list.focus():this.open(),!0},_escHandler(){return this.close(),this._buttonGroup.focus(),!0},_tabHandler(){return this.close(),!0},_renderPopup(){let i=u("<div>");this.$element().append(i),this._popup=this._createComponent(i,ii,this._popupOptions()),this._popup.$content().addClass(qZ),this._popup.$wrapper().addClass("dx-dropdownbutton-popup-wrapper"),this._popup.$overlayContent().attr("aria-label","Dropdown"),this._popup.on("hiding",this._popupHidingHandler.bind(this)),this._popup.on("showing",this._popupShowingHandler.bind(this)),this._bindInnerWidgetOptions(this._popup,"dropDownOptions")},_popupHidingHandler(){this.option("opened",!1),this._updateAriaAttributes(!1)},_popupOptionChanged(i){let e=Xe.getOptionsFromContainer(i);this._setPopupOption(e);let t=Object.keys(e);(t.includes("width")||t.includes("height"))&&this._dimensionChanged()},_dimensionChanged(){$l(this.option("dropDownOptions.width"))===void 0&&this._setPopupOption("width",()=>Hl(this.$element()))},_setPopupOption(i,e){this._setWidgetOption("_popup",arguments)},_popupShowingHandler(){this.option("opened",!0),this._updateAriaAttributes(!0)},_setElementAria(i){let e={owns:i?this._popupContentId:void 0};this.setAria(e,this.$element())},_setButtonsAria(i){let e={expanded:i,haspopup:"listbox"},t={};this.option("text")||(t.label="dropdownbutton"),this._getButtons().each((n,o)=>{n===0?this.setAria(I({},t,e),u(o)):this.setAria(e,u(o))})},_updateAriaAttributes(i){this._setElementAria(i),this._setButtonsAria(i)},_getButtons(){return this._buttonGroup.$element().find(".dx-button")},_renderButtonGroup(){let i=this._buttonGroup&&this._buttonGroup.$element()||u("<div>");this._buttonGroup||this.$element().append(i),this._buttonGroup=this._createComponent(i,sF,this._getButtonGroupOptions()),this._buttonGroup.registerKeyHandler("downArrow",this._upDownKeyHandler.bind(this)),this._buttonGroup.registerKeyHandler("tab",this._tabHandler.bind(this)),this._buttonGroup.registerKeyHandler("upArrow",this._upDownKeyHandler.bind(this)),this._buttonGroup.registerKeyHandler("escape",this._escHandler.bind(this)),this._bindInnerWidgetOptions(this._buttonGroup,"buttonGroupOptions"),this._updateAriaAttributes(this.option("opened"))},_updateArrowClass(){let i=this.option("splitButton")||this.option("showArrowIcon");this.$element().toggleClass("dx-dropdownbutton-has-arrow",i)},toggle(i){return this._popup||(this._renderPopup(),this._renderContent()),this._popup.toggle(i)},open(){return this.toggle(!0)},close(){return this.toggle(!1)},_setListOption(i,e){this._list&&this._list.option(i,e)},_getDisplayValue(i){let t=!$(i)?i:this._displayGetter(i);return $(t)?"":String(Te(t,""))},_updateActionButton(i){this.option("useSelectMode")&&this.option({text:this._getDisplayValue(i),icon:q(i)?i.icon:void 0}),this._setOptionWithoutOptionChange("selectedItem",i),this._setOptionWithoutOptionChange("selectedItemKey",this._keyGetter(i))},_clean(){this._list&&this._list.$element().remove(),this._popup&&this._popup.$element().remove()},_selectedItemKeyChanged(i){this._setListOption("selectedItemKeys",this.option("useSelectMode")&&f(i)?[i]:[]);let e=this.option("selectedItem");this._loadSelectedItem().always(t=>{this._updateActionButton(t),this._displayGetter(e)!==this._displayGetter(t)&&this._fireSelectionChangedAction({previousValue:e,value:t})})},_updateButtonGroup(i,e){this._buttonGroup.option(i,e),this._updateAriaAttributes(this.option("opened"))},_actionButtonOptionChanged(i){let{name:e,value:t}=i,n={};n[e]=t,this._updateButtonGroup("items[0]",m({},this._getActionButtonConfig(),n)),this._popup&&this._popup.repaint()},_selectModeChanged(i){if(i){this._setListOption("selectionMode","single");let e=this.option("selectedItemKey");this._setListOption("selectedItemKeys",f(e)?[e]:[]),this._selectedItemKeyChanged(this.option("selectedItemKey"))}else this._setListOption("selectionMode","none"),this.option({selectedItemKey:void 0,selectedItem:void 0}),this._actionButtonOptionChanged({text:this.option("text")})},_updateItemCollection(i){let e=this.option("selectedItemKey");this._setListOption("selectedItem",null),this._setWidgetOption("_list",[i]),f(e)&&this._loadSelectedItem().done(t=>{this._setListOption("selectedItemKeys",[e]),this._setListOption("selectedItem",t)}).fail(t=>{this._setListOption("selectedItemKeys",[])}).always(this._updateActionButton.bind(this))},_updateDataController(i){this._dataController.updateDataSource(i,this.option("keyExpr")),this._updateKeyExpr()},_updateKeyExpr(){this._compileKeyGetter(),this._setListOption("keyExpr",this._dataController.key())},focus(){this._buttonGroup.focus()},_optionChanged(i){var e;let{name:t,value:n}=i;switch(t){case"useSelectMode":this._selectModeChanged(n);break;case"splitButton":this._updateArrowClass(),this._renderButtonGroup();break;case"displayExpr":this._compileDisplayGetter(),this._setListOption(t,n),this._updateActionButton(this.option("selectedItem"));break;case"keyExpr":this._updateDataController();break;case"buttonGroupOptions":this._innerWidgetOptionChanged(this._buttonGroup,i);break;case"dropDownOptions":if(i.fullName==="dropDownOptions.visible")break;i.value.visible!==void 0&&delete i.value.visible,this._popupOptionChanged(i),this._innerWidgetOptionChanged(this._popup,i);break;case"opened":this.toggle(n);break;case"focusStateEnabled":case"hoverStateEnabled":this._setListOption(t,n),this._updateButtonGroup(t,n),this.callBase(i);break;case"items":this._updateDataController(this.option("items")),this._updateItemCollection(t);break;case"dataSource":this._dataController.updateDataSource(n),this._updateKeyExpr(),this._updateItemCollection(t);break;case"icon":case"text":this._actionButtonOptionChanged(i);break;case"showArrowIcon":this._updateArrowClass(),this._renderButtonGroup(),this._popup&&this._popup.repaint();break;case"width":case"height":this.callBase(i),(e=this._popup)===null||e===void 0||e.repaint();break;case"stylingMode":case"tabIndex":this._updateButtonGroup(t,n);break;case"type":this._updateButtonGroup("items",this._getButtonGroupItems());break;case"itemTemplate":case"grouped":case"noDataText":case"groupTemplate":case"wrapItemText":case"useItemTextAsTitle":this._setListOption(t,n);break;case"dropDownContentTemplate":this._renderContent();break;case"selectedItemKey":this._selectedItemKeyChanged(n);break;case"selectedItem":break;case"onItemClick":this._createItemClickAction();break;case"onButtonClick":this._createActionClickAction();break;case"onSelectionChanged":this._createSelectionChangedAction();break;case"deferRendering":this.toggle(this.option("opened"));break;case"template":this._renderButtonGroup();break;default:this.callBase(i)}},getDataSource(){return this._dataController.getDataSource()}});G("dxDropDownButton",YZ);function jH(i,e){let t=d=>d||1,n=[],o=(i[0]||[]).reduce((d,c)=>d+t(c.colspan),0),s=(d=>{let c=0,h=0;return()=>{let p=d[c]||[],g=p[h++];return h>=p.length&&(c++,h=0),g&&(g.colspan=t(g.colspan),g.rowspan=t(g.rowspan)),g}})(i),r=(d,c,h)=>{let p=n[d]=n[d]||[];if(p[c]=h,h.colspan>1||h.rowspan>1){let g=(C=>m({},C,e))(h);for(let C=1;C<h.colspan;C++)r(d,c+C,g);for(let C=1;C<h.rowspan;C++)for(let v=0;v<h.colspan;v++)r(d+C,c+v,g)}},a=s(),l=0;for(;a;){for(let d=0;d<o&&a;d++)n[l]&&n[l][d]||(r(l,d,a),d+=a.colspan-1,a=s());l++}return n}var KS=class{constructor(e,t,n){this._exportController=e,this._initialColumnWidthsByColumnIndex=t,this._selectedRowsOnly=n}_getGroupValue(e){let{key:t,data:n,rowType:o,groupIndex:s,summaryCells:r}=e,a=this._options.groupColumns[s],l=H.getDisplayValue(a,a.deserializeValue?a.deserializeValue(t[s]):t[s],n,o),d=`${a.caption}: ${H.formatValue(l,a)}`;return r&&r[0]&&r[0].length&&(d+=` ${H.getGroupRowSummaryText(r[0],this._options.summaryTexts)}`),d}_correctCellIndex(e){return e}_initOptions(){let e=this._exportController,t=e._columnsController.getGroupColumns();this._options={columns:e._getColumns(this._initialColumnWidthsByColumnIndex),groupColumns:t,items:this._selectedRowsOnly||e._selectionOnly?e._getSelectedItems():e._getAllItems(),isHeadersVisible:e.option("showColumnHeaders"),summaryTexts:e.option("summary.texts"),rtlEnabled:e.option("rtlEnabled")}}getHeaderStyles(){return[{bold:!0,alignment:"center"},{bold:!0,alignment:"left"},{bold:!0,alignment:"right"}]}getGroupRowStyle(){return{bold:!0,alignment:Ui(this._options.rtlEnabled)}}getColumnStyles(){let e=[];return this.getColumns().forEach(t=>{e.push({alignment:t.alignment||"left",format:t.format,dataType:t.dataType})}),e}getStyles(){return[...this.getHeaderStyles(),...this.getColumnStyles(),this.getGroupRowStyle()]}_getTotalCellStyleId(e){var t;let n=((t=this.getColumns()[e])===null||t===void 0?void 0:t.alignment)||"right";return this.getHeaderStyles().map(o=>o.alignment).indexOf(n)}getStyleId(e,t){return e<this.getHeaderRowCount()?0:this.isTotalCell(e-this.getHeaderRowCount(),t)?this._getTotalCellStyleId(t):this.isGroupRow(e-this.getHeaderRowCount())?this.getHeaderStyles().length+this.getColumns().length:t+this.getHeaderStyles().length}getColumns(e){let{columns:t}=this._options;return e?t:t[t.length-1]}getColumnsWidths(){let e=this.getColumns();return f(e)?e.map(t=>t.width):void 0}getRowsCount(){return this._options.items.length+this.getHeaderRowCount()}getHeaderRowCount(){return this.isHeadersVisible()?this._options.columns.length-1:0}isGroupRow(e){return e<this._options.items.length&&this._options.items[e].rowType==="group"}getGroupLevel(e){let t=this._options.items[e-this.getHeaderRowCount()],n=t&&t.groupIndex;return t&&t.rowType==="totalFooter"?0:f(n)?n:this._options.groupColumns.length}getCellType(e,t){let n=this.getColumns();if(e<this.getHeaderRowCount())return"string";if(e-=this.getHeaderRowCount(),t<n.length){let o=this._options.items.length&&this._options.items[e],s=n[t];return o&&o.rowType==="data"&&isFinite(o.values[this._correctCellIndex(t)])&&!f(s.customizeText)?f(s.lookup)?s.lookup.dataType:s.dataType:"string"}}ready(){this._initOptions();let e=this._options;return P(e.items).done(t=>{e.items=t}).fail(()=>{e.items=[]})}_convertFromGridGroupSummaryItems(e){if(f(e)&&e.length>0)return e.map(t=>({value:t.value,name:t.name}))}getCellData(e,t,n){let o,s,r={cellSourceData:{},value:o},a=this.getColumns(),l=this._correctCellIndex(t);if(e<this.getHeaderRowCount())s=this.getColumns(!0)[e][t],r.cellSourceData.rowType="header",r.cellSourceData.column=s&&s.gridColumn,r.value=s&&s.caption;else{e-=this.getHeaderRowCount();let d=this._options.items.length&&this._options.items[e];if(d){let c=d.values;switch(r.cellSourceData.rowType=d.rowType,r.cellSourceData.column=a[t]&&a[t].gridColumn,d.rowType){case"groupFooter":case"totalFooter":l<c.length&&(o=c[l],f(o)?(r.cellSourceData.value=o.value,r.cellSourceData.totalSummaryItemName=o.name,r.value=H.getSummaryText(o,this._options.summaryTexts)):r.cellSourceData.value=void 0);break;case"group":if(r.cellSourceData.groupIndex=d.groupIndex,t<1)r.cellSourceData.column=this._options.groupColumns[d.groupIndex],r.cellSourceData.value=d.key[d.groupIndex],r.cellSourceData.groupSummaryItems=this._convertFromGridGroupSummaryItems(d.summaryCells[0]),r.value=this._getGroupValue(d);else{let h=d.values[l];if(Array.isArray(h)){r.cellSourceData.groupSummaryItems=this._convertFromGridGroupSummaryItems(h),o="";for(let p=0;p<h.length;p++)o+=(p>0?n?`
`:` 
 `:"")+H.getSummaryText(h[p],this._options.summaryTexts);r.value=o}else r.cellSourceData.value=void 0}break;default:if(s=a[t],s){let h=c[l],p=H.getDisplayValue(s,h,d.data,d.rowType);!isFinite(p)||f(s.customizeText)?n&&f(s.customizeText)&&s.customizeText===this._exportController._columnsController.getCustomizeTextByDataType("boolean")?r.value=p:r.value=H.formatValue(p,s):r.value=p,r.cellSourceData.value=h}r.cellSourceData.data=d.data}}}return r}isHeadersVisible(){return this._options.isHeadersVisible}isTotalCell(e,t){let{items:n}=this._options,o=n[e],s=this._correctCellIndex(t),r=o.summaryCells&&o.summaryCells[s]&&o.summaryCells[s].length>0&&o.summaryCells[s][0].alignByColumn;return o&&o.rowType==="groupFooter"||o.rowType==="totalFooter"||r}getCellMerging(e,t){let{columns:n}=this._options,o=n[e]&&n[e][t];return o?{colspan:(o.exportColspan||1)-1,rowspan:(o.rowspan||1)-1}:{colspan:0,rowspan:0}}getFrozenArea(){return{x:0,y:this.getHeaderRowCount()}}},US=class extends H.ViewController{init(){this.throwWarningIfNoOnExportingEvent(),this._columnsController=this.getController("columns"),this._dataController=this.getController("data"),this._selectionController=this.getController("selection"),this._rowsView=this.getView("rowsView"),this._headersView=this.getView("columnHeadersView"),this.createAction("onExporting",{excludeValidators:["disabled","readOnly"]})}_getEmptyCell(){return{caption:"",colspan:1,rowspan:1}}_updateColumnWidth(e,t){e.width=t}_getColumns(e){let t=[],n,o,s=this._columnsController,r=s.getRowCount();for(n=0;n<=r;n++){let a=[];o=s.getVisibleColumns(n,!0);let l;if(n===r)if(this._updateLockCount)l=e;else{let d=this._getColumnWidths(this._headersView,this._rowsView);if(d&&d.length){l={};for(let c=0;c<o.length;c++)l[o[c].index]=d[c]}}for(let d=0;d<o.length;d++){let c=m({},o[d],{dataType:o[d].dataType==="datetime"?"date":o[d].dataType,gridColumn:o[d]});if(this._needColumnExporting(c)){let h=this._calculateExportColspan(c);f(h)&&(c.exportColspan=h),l&&this._updateColumnWidth(c,l[c.index]),a.push(c)}}t.push(a)}return o=t[r],t=jH(t.slice(0,-1),this._getEmptyCell()),t.push(o),t}_calculateExportColspan(e){if(!e.isBand)return;let t=this._columnsController.getChildrenByBandColumn(e.index,!0);if(f(t))return t.reduce((n,o)=>this._needColumnExporting(o)?n+(this._calculateExportColspan(o)||1):n,0)}_needColumnExporting(e){return!e.command&&(e.allowExporting||e.allowExporting===void 0)}_getFooterSummaryItems(e,t){let n=[],o=1,s=0;do{let r=[];for(let a=0;a<e.length;a++){let l=e[a],d=l.length;o<d&&(o=d),r.push(l[s])}n.push({values:r,rowType:t?"totalFooter":"groupFooter"})}while(s++<o-1);return n}_hasSummaryGroupFooters(){let e=this.option("summary.groupItems");if(f(e)){for(let t=0;t<e.length;t++)if(e[t].showInGroupFooter)return!0}return!1}_getItemsWithSummaryGroupFooters(e){let t=[],n=[],o=[];for(let s=0;s<e.length;s++){let r=e[s];r.rowType==="groupFooter"?(o=this._getFooterSummaryItems(r.summaryCells),t=t.concat(n,o),n=[]):n.push(r)}return t.length?t:n}_updateGroupValuesWithSummaryByColumn(e){let t=[];for(let n=0;n<e.length;n++){let o=e[n],{summaryCells:s}=o;if(o.rowType==="group"&&s&&s.length>1){let r=o.values.length;for(let a=1;a<s.length;a++)for(let l=0;l<s[a].length;l++){let d=s[a][l];d&&d.alignByColumn&&(Array.isArray(t[a-r])||(t[a-r]=[]),t[a-r].push(d))}t.length>0&&(o.values.push(...t),t=[])}}}_processUnExportedItems(e){let t=this._columnsController.getVisibleColumns(null,!0),n=this._columnsController.getGroupColumns(),o,s;for(let r=0;r<e.length;r++){let a=e[r],l=!1;o=[],s=[];for(let d=0;d<t.length;d++){let c=t[d];if(l||(l=["detailExpand","buttons"].includes(c.type)),this._needColumnExporting(c)&&(a.values&&(a.rowType==="group"&&!o.length?o.push(a.key[a.groupIndex]):o.push(a.values[d])),a.summaryCells))if(a.rowType==="group"&&!s.length){let h=d-n.length+a.groupIndex;s.push(a.summaryCells[l?h:h+1])}else s.push(a.summaryCells[d])}o.length&&(a.values=o),s.length&&(a.summaryCells=s)}}_getAllItems(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=this,o=new y,s=this._dataController.footerItems(),r=s.length&&s[0],a=n.option("summary.totalItems"),l;return P(e).done(d=>{this._dataController.loadAll(d,t).done((c,h)=>{n._updateGroupValuesWithSummaryByColumn(c),n._hasSummaryGroupFooters()&&(c=n._getItemsWithSummaryGroupFooters(c)),l=r&&r.summaryCells,f(h)&&a&&(l=n._getSummaryCells(a,h));let p=r&&n._getFooterSummaryItems(l,!0);p&&(c=c.concat(p)),n._processUnExportedItems(c),o.resolve(c)}).fail(o.reject)}).fail(o.reject),o}_getSummaryCells(e,t){return this._dataController._calculateSummaryCells(e,t,this._columnsController.getVisibleColumns(null,!0),(n,o)=>this._dataController._isDataColumn(o)?o.index:-1)}_getSelectedItems(){return this.needLoadItemsOnExportingSelectedItems()?this._getAllItems(this._selectionController.loadSelectedItemsWithFilter(),!0):this._getAllItems(this._selectionController.getSelectedRowsData())}_getColumnWidths(e,t){return e&&e.isVisible()?e.getColumnWidths():t.getColumnWidths()}throwWarningIfNoOnExportingEvent(){var e,t;let n=(e=(t=this.component).hasActionSubscription)===null||e===void 0?void 0:e.call(t,"onExporting");this.option("export.enabled")&&!n&&Z.log("W1024")}callbackNames(){return["selectionOnlyChanged"]}getDataProvider(e){let t=this._getColumnWidths(this._headersView,this._rowsView),n;if(t&&t.length){n={};let o=this._columnsController.getVisibleColumns(this._columnsController.getRowCount(),!0);for(let s=0;s<o.length;s++)n[o[s].index]=t[s]}return new KS(this,n,e)}exportTo(e,t){this._selectionOnly=e;let n=this.getAction("onExporting"),o={rtlEnabled:this.option("rtlEnabled"),selectedRowsOnly:!!e,format:t,fileName:"DataGrid",cancel:!1};A(n)&&n(o)}publicMethods(){return["getDataProvider"]}selectionOnly(e){if(f(e))this._isSelectedRows=e,this.selectionOnlyChanged.fire();else return this._isSelectedRows}optionChanged(e){super.optionChanged(e),e.name==="export"&&this.throwWarningIfNoOnExportingEvent()}needLoadItemsOnExportingSelectedItems(){return this.option("loadItemsOnExportingSelectedItems")??this._dataController._dataSource.remoteOperations().filtering}},XZ=i=>class extends i{callbackNames(){let e=super.callbackNames();return f(e)?e.push("editingButtonsUpdated"):["editingButtonsUpdated"]}_updateEditButtons(){super._updateEditButtons(),this.editingButtonsUpdated.fire()}},QZ=i=>class extends i{_getToolbarItems(){let e=super._getToolbarItems(),t=this._getExportToolbarButton();return t&&(e.push(t),this._correctItemsPosition(e)),e}_getExportToolbarButton(){let e=this._getExportToolbarItems();if(e.length===0)return null;let t=this._needDisableExportButton(),n={name:"exportButton",location:"after",locateInMenu:"auto",sortIndex:30,options:{items:e},disabled:t};if(e.length===1){let o=I({},e[0],{hint:e[0].text,elementAttr:{class:"dx-datagrid-export-button"}});n.widget="dxButton",n.showText="inMenu",n.options=o}else{let o={icon:"export",displayExpr:"text",items:e,hint:this.option("export.texts.exportTo"),elementAttr:{class:"dx-datagrid-export-button"},dropDownOptions:{width:"auto",_wrapperClassExternal:"dx-datagrid-export-menu"}};n.options=o,n.widget="dxDropDownButton",n.menuItemTemplate=(s,r,a)=>{this._createComponent(u(a),jo,{items:e})}}return n}_getExportToolbarItems(){let e=this.option("export"),t=this.option("export.texts"),n=this.option("export.formats")??[];if(!e.enabled)return[];let o=[];return n.forEach(s=>{let r=s.toUpperCase(),a="export";s==="xlsx"&&(r="Excel",a="xlsxfile"),s==="pdf"&&(a="pdffile"),o.push({text:Ii(t.exportAll,r),icon:a,onClick:()=>{this._exportController.exportTo(!1,s)}}),e.allowExportSelectedData&&o.push({text:Ii(t.exportSelectedRows,r),icon:"exportselected",onClick:()=>{this._exportController.exportTo(!0,s)}})}),o}_correctItemsPosition(e){e.sort((t,n)=>t.sortIndex-n.sortIndex)}_isExportButtonVisible(){return this.option("export.enabled")}optionChanged(e){super.optionChanged(e),e.name==="export"&&(e.handled=!0,this._invalidate())}_needDisableExportButton(){let e=!this._columnsController.hasVisibleDataColumns(),t=this._editingController.hasChanges();return e||t}_columnOptionChanged(e){if(super._columnOptionChanged(e),H.checkChanges(e.optionNames,["groupIndex","visible","all"])){let n=this._needDisableExportButton();this.setToolbarItemDisabled("exportButton",n)}}init(){super.init(),this._exportController=this.getController("export"),this._editingController.editingButtonsUpdated.add(()=>{let e=this._needDisableExportButton();this.setToolbarItemDisabled("exportButton",e)})}};H.registerModule("export",{defaultOptions:()=>({export:{enabled:!1,fileName:"DataGrid",formats:["xlsx"],allowExportSelectedData:!1,texts:{exportTo:O.format("dxDataGrid-exportTo"),exportAll:O.format("dxDataGrid-exportAll"),exportSelectedRows:O.format("dxDataGrid-exportSelectedRows")}}}),controllers:{export:US},extenders:{controllers:{editing:XZ},views:{headerPanel:QZ}}});var ZZ=(i,e,t)=>{let{isRemoteFiltering:n,dateSerializationFormat:o,getSelector:s}=t,{selector:r}=i,a=A(r)?r:s(r),l=a?a(e):e[r],d=n&&Et(l)?tt.serializeDate(l,o):l;return{getter:a,rawValue:l,safeValue:d}},qH={getSortFilterValue:ZZ};var JZ=".dx-row.dx-row-focused";var jS=class extends Ce.ViewController{getKeyboardController(){return this.getController("keyboardNavigation")}getDataController(){return this.getController("data")}init(){this.component._optionsByReference.focusedRowKey=!0}optionChanged(e){let{name:t,value:n,previousValue:o}=e;switch(t){case"focusedRowIndex":this._focusRowByIndex(n),this.getKeyboardController()._fireFocusedRowChanged(),e.handled=!0;break;case"focusedRowKey":if(Array.isArray(n)&&JSON.stringify(n)===JSON.stringify(o))return;this._focusRowByKey(n),this.getKeyboardController()._fireFocusedRowChanged(),e.handled=!0;break;case"focusedColumnIndex":case"focusedRowEnabled":case"autoNavigateToFocusedRow":e.handled=!0;break;default:super.optionChanged(e)}}publicMethods(){return["navigateToRow","isRowFocused"]}isAutoNavigateToFocusedRow(){return this.option("scrolling.mode")!=="infinite"&&this.option("autoNavigateToFocusedRow")}_focusRowByIndex(e,t){if(!this.option("focusedRowEnabled"))return;let n=this.getDataController().isEmpty(),o=this._getCurrentFocusRowIndex(n,e);o<0?(n||this.isAutoNavigateToFocusedRow())&&this._resetFocusedRow():this._focusRowByIndexCore(o,t)}_getCurrentFocusRowIndex(e,t){let n=t;return n===void 0&&(e?n=-1:n=this.option("focusedRowIndex")),n}_focusRowByIndexCore(e,t){let n=this.getDataController().pageSize(),o=()=>{if(this._isValidFocusedRowIndex(e)){let s=e-this.getDataController().getRowIndexOffset(!0);if(!t||t.paging&&!t.filtering){let a=this.getDataController()._getLastItemIndex();s=Math.min(s,a)}let r=this.getDataController().getKeyByRowIndex(s,!0);f(r)&&!this.isRowFocused(r)&&this.option("focusedRowKey",r)}};if(n>=0)if(this._isLocalRowIndex(e))o();else{let s=Math.floor(e/this.getDataController().pageSize());P(this.getDataController().pageIndex(s),this.getDataController().waitReady()).done(()=>{o()})}}_isLocalRowIndex(e){if(this.getKeyboardController()._isVirtualScrolling()){let n=Math.floor(e/this.getDataController().pageSize()),o=this.getDataController().virtualItemsCount(),s=o?o.begin:-1,r=this.getDataController().getVisibleRows().length+this.getDataController().getRowIndexOffset(),a=Math.ceil(r/this.getDataController().pageSize());return s<=e&&a>n}return!0}_setFocusedRowKeyByIndex(e){if(this._isValidFocusedRowIndex(e)){let t=Math.min(e-this.getDataController().getRowIndexOffset(),this.getDataController().items().length-1),n=this.getDataController().getKeyByRowIndex(t);f(n)&&!this.isRowFocused(n)&&this.option("focusedRowKey",n)}}_focusRowByKey(e){f(e)?this._navigateToRow(e,!0):this._resetFocusedRow()}_resetFocusedRow(){let e=this.option("focusedRowKey"),t=f(e);!t&&this.option("focusedRowIndex")<0||(t&&this.option("focusedRowKey",null),this.getKeyboardController().setFocusedRowIndex(-1),this.option("focusedRowIndex",-1),this.getDataController().updateItems({changeType:"updateFocusedRow",focusedRowKey:null}),this.getKeyboardController()._fireFocusedRowChanged())}_isValidFocusedRowIndex(e){let t=this.getDataController().getVisibleRows()[e];return!t||t.rowType==="data"||t.rowType==="group"}navigateToRow(e){return this.isAutoNavigateToFocusedRow()||this.option("focusedRowIndex",-1),this._navigateToRow(e)}_navigateToRow(e,t){let n=this,o=n.isAutoNavigateToFocusedRow(),s=new y;if(e===void 0||!this.getDataController().dataSource())return s.reject().promise();let r=n.getFocusedRowIndexByKey(e);return!o&&t||r>=0?n._navigateTo(e,s,t):this.getDataController().getPageIndexByKey(e).done(a=>{if(a<0){s.resolve(-1);return}a===this.getDataController().pageIndex()?this.getDataController().reload().done(()=>{n.isRowFocused(e)&&this.getDataController().getRowIndexByKey(e)>=0?s.resolve(n.getFocusedRowIndexByKey(e)):n._navigateTo(e,s,t)}).fail(s.reject):this.getDataController().pageIndex(a).done(()=>{n._navigateTo(e,s,t)}).fail(s.reject)}).fail(s.reject),s.promise()}_navigateTo(e,t,n){let o=this.getDataController().getRowIndexByKey(e),s=M.isVirtualRowRendering(this);this.isAutoNavigateToFocusedRow()&&s&&o<0?this._navigateToVirtualRow(e,t,n):this._navigateToVisibleRow(e,t,n)}_navigateToVisibleRow(e,t,n){if(n)this._triggerUpdateFocusedRow(e,t);else{let o=this.getFocusedRowIndexByKey(e);this.getView("rowsView").scrollToRowElement(e,t).done(()=>{t.resolve(o)})}}_navigateToVirtualRow(e,t,n){let o=this.getDataController()._rowsScrollController,s=M.getIndexByKey(e,this.getDataController().items(!0)),r=this.getView("rowsView").getScrollable();if(o&&r&&s>=0){let a=s+this.getDataController().getRowIndexOffset(!0),l=o.getItemOffset(a),d=()=>{this.getDataController().totalCount()&&!this.getDataController().items().length||(this.component.off("contentReady",d),n?this._triggerUpdateFocusedRow(e,t):t.resolve(a))};this.component.on("contentReady",d),this.getView("rowsView").scrollTopPosition(l)}else t.resolve(-1)}_triggerUpdateFocusedRow(e,t){let n=this.getFocusedRowIndexByKey(e);if(this._isValidFocusedRowIndex(n)){let o;this.option("focusedRowEnabled")?this.getDataController().updateItems({changeType:"updateFocusedRow",focusedRowKey:e}):o=this.getView("rowsView").scrollToRowElement(e),P(o).done(()=>{this.getKeyboardController().setFocusedRowIndex(n),t&&t.resolve(n)})}else t&&t.resolve(-1)}getFocusedRowIndexByKey(e){let t=this.getDataController().getRowIndexByKey(e,!0);return t>=0?t+this.getDataController().getRowIndexOffset(!0):-1}_focusRowByKeyOrIndex(){let e=this.option("focusedRowKey"),t=this.option("focusedRowIndex");if(f(e)){let n=this.getDataController().getRowIndexByKey(e);n>=0?(this.getKeyboardController()._isVirtualScrolling()&&(t=n+this.getDataController().getRowIndexOffset()),this.getKeyboardController().setFocusedRowIndex(t),this._triggerUpdateFocusedRow(e)):this._navigateToRow(e,!0).done(o=>{t>=0&&o<0?this._focusRowByIndex():t<0&&o>=0&&this.getKeyboardController().setFocusedRowIndex(o)})}else t>=0&&this._focusRowByIndex(t)}isRowFocused(e){let t=this.option("focusedRowKey");if(f(t))return ve(e,this.option("focusedRowKey"))}updateFocusedRow(e){let t=this,n=t.getDataController().getRowIndexByKey(e.focusedRowKey),o=t.getView("rowsView"),s,r;x(o.getTableElements(),(a,l)=>{let d=a===0;s=u(l),t._clearPreviousFocusedRow(s,n);let c=t._prepareFocusedRow({changedItem:t.getDataController().getVisibleRows()[n],$tableElement:s,focusedRowIndex:n});d&&(r=c)}),!e.preventScroll&&r&&o.scrollToElementVertically(r)}_clearPreviousFocusedRow(e,t){let n=e.find(JZ).filter((o,s)=>{let r=u(s).closest(`.${this.addWidgetPrefix("table")}`);return e.is(r)});n.removeClass("dx-row-focused").removeClass("dx-cell-focus-disabled").removeAttr("tabindex"),n.children("td").removeAttr("tabindex"),t!==0&&u(this.getView("rowsView").getRowElement(0)).removeClass("dx-cell-focus-disabled").removeAttr("tabIndex")}_prepareFocusedRow(e){let t,{changedItem:n}=e;if(n&&(n.rowType==="data"||n.rowType==="group")){let{focusedRowIndex:o}=e,{$tableElement:s}=e,r=this.option("tabindex")||0,a=this.getView("rowsView");t=u(a._getRowElements(s).eq(o)),t.addClass("dx-row-focused").attr("tabindex",r)}return t}},e7=i=>class extends i{init(){let e=this.option("focusedRowIndex"),t=this.option("focusedColumnIndex");this.createAction("onFocusedRowChanging",{excludeValidators:["disabled","readOnly"]}),this.createAction("onFocusedRowChanged",{excludeValidators:["disabled","readOnly"]}),this.createAction("onFocusedCellChanging",{excludeValidators:["disabled","readOnly"]}),this.createAction("onFocusedCellChanged",{excludeValidators:["disabled","readOnly"]}),super.init(),this.setRowFocusType(),this._focusedCellPosition={},f(e)&&e>=0&&(this._focusedCellPosition.rowIndex=e),f(t)&&t>=0&&(this._focusedCellPosition.columnIndex=t)}setFocusedRowIndex(e){super.setFocusedRowIndex(e),this.option("focusedRowIndex",e)}setFocusedColumnIndex(e){super.setFocusedColumnIndex(e),this.option("focusedColumnIndex",e)}_escapeKeyHandler(e,t){return t||!this.option("focusedRowEnabled")?super._escapeKeyHandler(e,t):this.isCellFocusType()?(this.setRowFocusType(),this._focus(this._getCellElementFromTarget(e.originalEvent.target),!0),!0):!1}_updateFocusedCellPosition(e,t){let n=super._updateFocusedCellPosition(e,t);return n&&n.columnIndex>=0&&this._fireFocusedCellChanged(e),n}},t7=i=>class extends i{renderFocusOverlay(e,t){var n;let o=this.option("focusedRowEnabled"),s;!o||!((n=this._keyboardNavigationController)!==null&&n!==void 0&&n.isRowFocusType())||this._editingController.isEditing()?super.renderFocusOverlay(e,t):o&&this._keyboardNavigationController._getElementType(e)==="row"&&!e.hasClass("dx-row-focused")&&(s=this._keyboardNavigationController.getFirstValidCellInRow(e),this._keyboardNavigationController.focus(s))}},i7=i=>class extends i{getSortDataSourceParameters(e,t){let n=super.getSortDataSourceParameters.apply(this,arguments),o=this._dataController._dataSource,s=this._dataController.store(),r=s&&s.key(),a=o&&o.remoteOperations()||{},l=Object.keys(a).every(d=>!a[d]);if(r&&(this.option("focusedRowEnabled")&&this._focusController.isAutoNavigateToFocusedRow()!==!1||t)){r=Array.isArray(r)?r:[r];let d=r.filter(c=>!this.columnOption(c,"sortOrder"));d.length&&(n=n||[],l?n.push({selector:o.getDataIndexGetter(),desc:!1}):d.forEach(c=>n.push({selector:c,desc:!1})))}return n}},n7=i=>class extends i{constructor(){super(...arguments),this._needToUpdateFocusedRowByIndex=!1}_applyChange(e){if(!(e&&e.changeType==="updateFocusedRow"))return super._applyChange.apply(this,arguments)}_fireChanged(e){if(super._fireChanged(e),this.option("focusedRowEnabled")&&this._dataSource){let n=e.changeType==="update"&&e.repaintChangesOnly&&e.changeTypes&&e.changeTypes.indexOf("remove")>=0;this._needToUpdateFocusedRowByIndex?(this._needToUpdateFocusedRowByIndex=!1,this._focusController._focusRowByIndex()):e.changeType==="refresh"&&e.items.length||n?(this._updatePageIndexes(),this._updateFocusedRow(e)):e.changeType==="append"||e.changeType==="prepend"?this._updatePageIndexes():e.changeType==="update"&&e.repaintChangesOnly&&this._updateFocusedRow(e)}}_handleDataPushed(e){super._handleDataPushed(e);let t=this.option("focusedRowKey");this._needToUpdateFocusedRowByIndex=e?.some(n=>n.type==="remove"&&ve(n.key,t))}_updatePageIndexes(){let e=this._lastRenderingPageIndex||0,t=this._rowsScrollController?this._rowsScrollController.pageIndex():0;this._lastRenderingPageIndex=t,this._isPagingByRendering=t!==e}isPagingByRendering(){return this._isPagingByRendering}_updateFocusedRow(e){let t=e.operationTypes||{},{reload:n,fullReload:o,pageIndex:s,paging:r}=t,a=this._keyboardNavigationController._isVirtualScrolling(),l=r&&!a,d=this.option("focusedRowKey"),c=this._focusController.isAutoNavigateToFocusedRow();if(n&&s===!1&&!o&&f(d))this._focusController._navigateToRow(d,!0).done(p=>{p<0&&this._focusController._focusRowByIndex(void 0,t)});else if(l&&c){let p=this.getRowIndexByKey(d),g=this.option("focusedRowIndex"),C=p>=0;g>=0&&(g===p||!C)&&this._focusController._focusRowByIndex(g,t)}else l&&!c&&this.getRowIndexByKey(d)<0?this.option("focusedRowIndex",-1):t.fullReload&&this._focusController._focusRowByKeyOrIndex()}getPageIndexByKey(e){let t=this,n=new y;return t.getGlobalRowIndexByKey(e).done(o=>{n.resolve(o>=0?Math.floor(o/t.pageSize()):-1)}).fail(n.reject),n.promise()}getGlobalRowIndexByKey(e){return this._dataSource.group()?this._calculateGlobalRowIndexByGroupedData(e):this._calculateGlobalRowIndexByFlatData(e)}_calculateGlobalRowIndexByFlatData(e,t,n){let o=this,s=new y,r=o._dataSource;if(Array.isArray(e)||hV(e))return s.resolve(-1).promise();let a=o._generateFilterByKey(e);return r.load({filter:o._concatWithCombinedFilter(a),skip:0,take:1}).done(l=>{l.length>0?(a=o._generateOperationFilterByKey(e,l[0],n),r.load({filter:o._concatWithCombinedFilter(a,t),skip:0,take:1,requireTotalCount:!0}).done((d,c)=>{s.resolve(c.totalCount)})):s.resolve(-1)}),s.promise()}_concatWithCombinedFilter(e,t){let n=this.getCombinedFilter();return M.combineFilters([e,n,t])}_generateBooleanFilter(e,t,n){let{desc:o}=n;switch(!0){case(t===!1&&o):return[e,"=",!0];case(t===!1&&!o):return[e,"=",null];case(t===!0&&!o):case(!Qs(t)&&o):return[e,"<>",t];default:return}}_generateOperationFilterByKey(e,t,n){let o=this,s=o.option("dateSerializationFormat"),r=o._dataSource.remoteOperations().filtering,a=o._dataSource.remoteOperations().sorting,l=o._generateFilterByKey(e,"<"),d=o._columnsController.getSortDataSourceParameters(!r,!0);if(n){let c=o._columnsController.getGroupDataSourceParameters(!r);c&&(d=d?c.concat(d):c)}return d&&d.slice().reverse().forEach(c=>{let{selector:h,desc:p,compare:g}=c,{getter:C,rawValue:v,safeValue:b}=qH.getSortFilterValue(c,t,{isRemoteFiltering:r,dateSerializationFormat:s,getSelector:T=>o._columnsController.columnOption(T,"selector")});if(l=[[h,"=",b],"and",l],v===null||Qs(v)){let T=o._generateBooleanFilter(h,b,p);T&&(l=[T,"or",l])}else{let T=p?">":"<",R;g&&!a?R=U=>T==="<"?g(v,C(U))>=1:g(v,C(U))<=-1:(R=[h,T,b],p||(R=[R,"or",[h,"=",null]])),l=[R,"or",l]}}),l}_generateFilterByKey(e,t){let n=this._dataSource.key(),o=[];if(t||(t="="),Array.isArray(n))for(let s=0;s<n.length;++s){let r=e[n[s]];r&&(o.length>0&&o.push("and"),o.push([n[s],t,r]))}else o=[n,t,e];return o}_getLastItemIndex(){return this.items(!0).length-1}},o7=i=>class extends i{_deleteRowCore(e){let t=super._deleteRowCore.apply(this,arguments),n=this._dataController.getKeyByRowIndex(e);t.done(()=>{let o=this._dataController.getRowIndexByKey(n),s=this._dataController.getVisibleRows();o===-1&&!s.length&&this._focusController._resetFocusedRow()})}},s7=i=>class extends i{_createRow(e){let t=super._createRow.apply(this,arguments);return this.option("focusedRowEnabled")&&e&&this._focusController.isRowFocused(e.key)&&t.addClass("dx-row-focused"),t}_checkRowKeys(e){if(super._checkRowKeys.apply(this,arguments),this.option("focusedRowEnabled")&&this.option("dataSource")){let t=this._dataController.store();t&&!t.key()&&this._dataController.fireError("E1042","Row focusing")}}_update(e){e.changeType==="updateFocusedRow"?this.option("focusedRowEnabled")&&this._focusController.updateFocusedRow(e):super._update(e)}updateFocusElementTabIndex(e,t){this.option("focusedRowEnabled")?this._setFocusedRowElementTabIndex(t):super.updateFocusElementTabIndex(e)}_setFocusedRowElementTabIndex(e){let t=this.option("focusedRowKey"),n=this.option("tabIndex")??0,o=this._columnsController,s=this._dataController.getRowIndexByKey(t),r=this.option("focusedColumnIndex"),a=this._findRowElementForTabIndex(),l=this._dataController.dataSource(),d=l?.operationTypes(),c=!d||d.paging;f(this._scrollToFocusOnResize)||(this._scrollToFocusOnResize=()=>{this.scrollToElementVertically(this._findRowElementForTabIndex()),this.resizeCompleted.remove(this._scrollToFocusOnResize)}),a.attr("tabIndex",n);let h=this.option("focusedRowIndex")-this._dataController.getRowIndexOffset(!0);!c&&s<0&&h>=0&&this._focusController.updateFocusedRow({focusedRowKey:t,preventScroll:e}),s>=0&&!e&&(r<0&&(r=0),s+=this._dataController.getRowIndexOffset(),r+=o.getColumnIndexOffset(),this._keyboardNavigationController.setFocusedCellPosition(s,r),this._focusController.isAutoNavigateToFocusedRow()&&!c&&!this._dataController.isPagingByRendering()&&(this.resizeCompleted.remove(this._scrollToFocusOnResize),this.resizeCompleted.add(this._scrollToFocusOnResize)))}_findRowElementForTabIndex(){let e=this.option("focusedRowKey"),t=this._dataController.getRowIndexByKey(e);return u(this.getRowElement(t>=0?t:0))}scrollToRowElement(e){let t=this._dataController.getRowIndexByKey(e),n=u(this.getRow(t));return this.scrollToElementVertically(n)}scrollToElementVertically(e){let t=this.getScrollable();if(t&&e.length){let n=t.getScrollElementPosition(e,"vertical");return this.scrollTopPosition(n)}return new y().resolve()}scrollTopPosition(e){let t=new y,n=this.getScrollable();if(n){let o=n.scrollTop(),s=()=>{n.off("scroll",s),t.resolve()};if(e!==o)return n.on("scroll",s),this._dataController.resetFilterApplying(),n.scrollTo({top:e}),t.promise()}return t.resolve()}},Wu={defaultOptions:()=>({focusedRowEnabled:!1,autoNavigateToFocusedRow:!0,focusedRowKey:null,focusedRowIndex:-1,focusedColumnIndex:-1}),controllers:{focus:jS},extenders:{controllers:{keyboardNavigation:e7,editorFactory:t7,columns:i7,data:n7,editing:o7},views:{rowsView:s7}}};var r7=Number.MAX_SAFE_INTEGER||9007199254740991,a7=i=>class extends Wu.extenders.controllers.data(i){changeRowExpand(e,t){return this.option("focusedRowEnabled")&&Array.isArray(e)&&this.isRowExpanded(e)&&(!t||!this._keyboardNavigationController.isKeyboardEnabled())&&this._isFocusedRowInsideGroup(e)&&this.option("focusedRowKey",e),super.changeRowExpand(e,t)}_isFocusedRowInsideGroup(e){let t=this.option("focusedRowKey"),n=this.getRowIndexByKey(t),o=n>=0&&this.getVisibleRows()[n],s=this._columnsController.getGroupDataSourceParameters(!0);if(o){for(let r=0;r<e.length;++r)if(me(s[r]&&s[r].selector)(o.data)!==e[r])return!1}return!0}_getGroupPath(e,t){let n=[],o=[e];for(;o&&o[0]&&t;){let s=o[0];s.key!==void 0&&n.push(s.key),o=s.items,t--}return n}_expandGroupByPath(e,t,n){let o=new y;return n++,e.expandRow(t.slice(0,n)).done(()=>{n===t.length?o.resolve():e._expandGroupByPath(e,t,n).done(o.resolve).fail(o.reject)}).fail(o.reject),o.promise()}_calculateGlobalRowIndexByGroupedData(e){let t=this,n=t._dataSource,o=t._generateFilterByKey(e),s=new y,r=Array.isArray(e),a=n.group();return r?s.resolve(-1).promise():n._grouping._updatePagingOptions?(n.load({filter:t._concatWithCombinedFilter(o),group:a}).done(l=>{if(!l||l.length===0||!f(l[0].key)||l[0].key===-1)return s.resolve(-1).promise();let d=t._getGroupPath(l[0],a.length);t._expandGroupByPath(t,d,0).done(()=>{t._calculateExpandedRowGlobalIndex(s,e,d,a)}).fail(s.reject)}).fail(s.reject),s.promise()):(t._calculateGlobalRowIndexByFlatData(e,null,!0).done(s.resolve).fail(s.reject),s)}_calculateExpandedRowGlobalIndex(e,t,n,o){let s=ts(n,{group:o}),r=this._dataSource,a=this.option("scrolling.mode"),l=a==="virtual"||a==="infinite",d=r.pageSize(),c;r._grouping._updatePagingOptions({skip:0,take:r7},(h,p)=>{ve(h.path,n)&&(c=p)}),this._calculateGlobalRowIndexByFlatData(t,s).done(h=>{let p,g;if(h<0){e.resolve(-1);return}p=(c%d||d)+h-n.length,l?g=0:g=Math.floor(p/(d-n.length))*n.length,p=c+h+g,e.resolve(p)}).fail(e.reject)}};H.registerModule("focus",I({},Wu,{extenders:I({},Wu.extenders,{controllers:I({},Wu.extenders.controllers,{data:a7})})}));var YH=K(),l7="dxSortable";var XH=i=>u(i).is(":visible"),d7=(i,e)=>{var t,n;if(!i)return;let o=((t=e.to)===null||t===void 0?void 0:t.left)||0,s=((n=e.to)===null||n===void 0?void 0:n.top)||0;i.style.transform=`translate(${o}px,${s}px)`,i.style.transition=pe.off?"":`transform ${e.duration}ms ${e.easing}`},c7=i=>{i&&(i.style.transform="",i.style.transition="")};function u7(i){let e=i.offset(),{style:t}=i[0],n=parseFloat(t.paddingLeft)||0,o=parseFloat(t.paddingRight)||0,s=parseFloat(t.paddingTop)||0,r=i[0].clientWidth-(n+o),a=Y(i),l=e.left+n,d=e.top+s;return{left:l,right:l+r,top:d,bottom:d+a}}var QH=FF.inherit({_init(){this.callBase(),this._sourceScrollHandler=this._handleSourceScroll.bind(this),this._sourceScrollableInfo=null},_getDefaultOptions(){return m(this.callBase(),{clone:!0,filter:"> *",itemOrientation:"vertical",dropFeedbackMode:"push",allowDropInsideItem:!1,allowReordering:!0,moveItemOnDrop:!1,onDragChange:null,onAdd:null,onRemove:null,onReorder:null,onPlaceholderPrepared:null,animation:{type:"slide",duration:300,easing:"ease"},fromIndex:null,toIndex:null,dropInsideItem:!1,itemPoints:null,fromIndexOffset:0,offset:0,autoUpdate:!1,draggableElementSize:0})},reset(){this.option({dropInsideItem:!1,toIndex:null,fromIndex:null,itemPoints:null,fromIndexOffset:0,draggableElementSize:0}),this._$placeholderElement&&this._$placeholderElement.remove(),this._$placeholderElement=null,!this._isIndicateMode()&&this._$modifiedItem&&(this._$modifiedItem.css("marginBottom",this._modifiedItemMargin),this._$modifiedItem=null)},_getPrevVisibleItem:(i,e)=>i.slice(0,e).reverse().filter(XH)[0],_dragStartHandler(i){if(this.callBase.apply(this,arguments),i.cancel===!0)return;let e=this._getSourceElement();this._updateItemPoints(),this._subscribeToSourceScroll(i),this.option("fromIndex",this._getElementIndex(e)),this.option("fromIndexOffset",this.option("offset"))},_subscribeToSourceScroll(i){let e=this._getScrollable(u(i.target));e&&(this._sourceScrollableInfo={element:e,scrollLeft:e.scrollLeft(),scrollTop:e.scrollTop()},_.off(e,"scroll",this._sourceScrollHandler),_.on(e,"scroll",this._sourceScrollHandler))},_unsubscribeFromSourceScroll(){this._sourceScrollableInfo&&(_.off(this._sourceScrollableInfo.element,"scroll",this._sourceScrollHandler),this._sourceScrollableInfo=null)},_handleSourceScroll(i){let e=this._sourceScrollableInfo;e&&["scrollLeft","scrollTop"].forEach(t=>{if(i.target[t]!==e[t]){let n=i.target[t]-e[t];this._correctItemPoints(n),this._movePlaceholder(),e[t]=i.target[t]}})},_dragEnterHandler(i){if(this.callBase.apply(this,arguments),this!==this._getSourceDraggable()&&(this._subscribeToSourceScroll(i),this._updateItemPoints(),this.option("fromIndex",-1),!this._isIndicateMode())){let e=this.option("itemPoints"),t=e[e.length-1];if(t){let n=this.$element(),o=this._getSourceElement(),s=this._isVerticalOrientation(),r=s?X(o,!0):ie(o,!0),a=n.get(0)[s?"scrollHeight":"scrollWidth"],l=n.get(0)[s?"scrollTop":"scrollLeft"],d=s?"top":"left",c=t[d],p=n.offset()[d]+a-l-c;if(p<r&&s){let g=this._getItems(),C=u(this._getPrevVisibleItem(g));this._$modifiedItem=C,this._modifiedItemMargin=C.get(0).style.marginBottom,C.css("marginBottom",r-p);let v=C.closest(".dx-sortable"),b=v.data("dxScrollable")||v.data("dxScrollView");b&&b.update()}}}},_dragLeaveHandler(){this.callBase.apply(this,arguments),this!==this._getSourceDraggable()&&this._unsubscribeFromSourceScroll()},dragEnter(){this!==this._getTargetDraggable()&&this.option("toIndex",-1)},dragLeave(){this!==this._getTargetDraggable()&&this.option("toIndex",this.option("fromIndex"))},_allowDrop(i){let t=this._getTargetDraggable().$element(),n=this._getScrollable(t);if(n){let{left:o,right:s,top:r,bottom:a}=u7(n),l=this.option("toIndex"),d=this.option("itemPoints"),c=d?.filter(h=>h.index===l)[0];if(c&&c.top!==void 0)return this._isVerticalOrientation()?r<=Math.ceil(c.top)&&Math.floor(c.top)<=a:o<=Math.ceil(c.left)&&Math.floor(c.left)<=s}return!0},dragEnd(i){this._unsubscribeFromSourceScroll();let e=this._getSourceElement(),t=this._getSourceDraggable(),n=t.NAME!==this.NAME,o=this.option("toIndex"),{event:s}=i,r=this._allowDrop(s);if(o!==null&&o>=0&&r){let a,l;if(t!==this&&(a=this._fireAddEvent(s),a||(l=this._fireRemoveEvent(s))),n&&Bo(e),this.option("moveItemOnDrop")&&!a&&this._moveItem(e,o,l),t===this)return this._fireReorderEvent(s)}return y().resolve()},dragMove(i){let e=this.option("itemPoints");if(!e)return;let t=this._isVerticalOrientation(),n=t?"top":"left",o=t?i.pageY:i.pageX,s=this.option("rtlEnabled"),r;for(let a=e.length-1;a>=0;a--){let l=e[a+1]&&(e[a][n]+e[a+1][n])/2;if((!t&&s?o>l:l>o)||l===void 0)r=e[a];else break}r&&(this._updatePlaceholderPosition(i,r),this._verticalScrollHelper.isScrolling()&&this._isIndicateMode()&&this._movePlaceholder())},_isIndicateMode(){return this.option("dropFeedbackMode")==="indicate"||this.option("allowDropInsideItem")},_createPlaceholder(){let i;return this._isIndicateMode()&&(i=u("<div>").addClass(this._addWidgetPrefix("placeholder")).insertBefore(this._getSourceDraggable()._$dragElement)),this._$placeholderElement=i,i},_getItems(){let i=this._getItemsSelector();return this._$content().find(i).not(`.${this._addWidgetPrefix("placeholder")}`).not(`.${this._addWidgetPrefix("clone")}`).toArray()},_allowReordering(){let i=this._getSourceDraggable(),e=this._getTargetDraggable();return i!==e||this.option("allowReordering")},_isValidPoint(i,e,t){let n=this.option("allowDropInsideItem");return!(t||this._allowReordering())&&(i!==0||!n)?!1:this._isIndicateMode()?e===-1||i!==e&&(t||i!==e+1):!0},_getItemPoints(){let i=this,e=[],t,n,o,s=i.option("rtlEnabled"),r=i._isVerticalOrientation(),a=i._getItems(),l=a.filter(XH),d=l.length,c=this._getDraggableElement(),h=l.indexOf(c.get(0));if(d){for(let p=0;p<=d;p++){let g=!r&&s^p===d,C=r&&p===d;p<d&&(t=u(l[p]),n=t.offset(),o=ie(t)),e.push({dropInsideItem:!1,left:n.left+(g?o:0),top:n.top+(C?e[p-1].height:0),index:p===d?a.length:a.indexOf(t.get(0)),$item:t,width:ie(t),height:X(t),isValid:i._isValidPoint(p,h)})}if(this.option("allowDropInsideItem")){let p=e;e=[];for(let g=0;g<p.length;g++)e.push(p[g]),p[g+1]&&e.push(m({},p[g],{dropInsideItem:!0,top:Math.floor((p[g].top+p[g+1].top)/2),left:Math.floor((p[g].left+p[g+1].left)/2),isValid:this._isValidPoint(g,h,!0)}))}}else e.push({dropInsideItem:!1,index:0,isValid:!0});return e},_updateItemPoints(i){(i||this.option("autoUpdate")||!this.option("itemPoints"))&&this.option("itemPoints",this._getItemPoints())},_correctItemPoints(i){let e=this.option("itemPoints");if(i&&e&&!this.option("autoUpdate")){let n=this._isVerticalOrientation()?"top":"left";e.forEach(o=>{o[n]-=i})}},_getElementIndex(i){return this._getItems().indexOf(i.get(0))},_getDragTemplateArgs(i){let e=this.callBase.apply(this,arguments);return e.model.fromIndex=this._getElementIndex(i),e},_togglePlaceholder(i){this._$placeholderElement&&this._$placeholderElement.toggle(i)},_isVerticalOrientation(){return this.option("itemOrientation")==="vertical"},_normalizeToIndex(i,e){let t=this._getSourceDraggable()!==this._getTargetDraggable(),n=this._getActualFromIndex();return i===null?n:Math.max(t||n>=i||e?i:i-1,0)},_updatePlaceholderPosition(i,e){let t=this._getSourceDraggable(),n=this._normalizeToIndex(e.index,e.dropInsideItem),o=m(this._getEventArgs(i),{toIndex:n,dropInsideItem:e.dropInsideItem});if(e.isValid&&this._getAction("onDragChange")(o),o.cancel||!e.isValid){e.isValid||this.option({dropInsideItem:!1,toIndex:null});return}this.option({dropInsideItem:e.dropInsideItem,toIndex:e.index}),this._getAction("onPlaceholderPrepared")(m(this._getEventArgs(i),{placeholderElement:N(this._$placeholderElement),dragElement:N(t._$dragElement)})),this._updateItemPoints()},_makeWidthCorrection(i,e){if(this._$scrollable=this._getScrollable(i),this._$scrollable){let t=z(this._$scrollable),n=this._$scrollable.offset().left-i.offset().left,o=ie(i)-n-t;n>0&&(e-=n),o>0&&(e-=o)}return e},_updatePlaceholderSizes(i,e){let t=this.option("dropInsideItem"),n=u(e),o=this._isVerticalOrientation(),s="",r="";i.toggleClass(this._addWidgetPrefix("placeholder-inside"),t),(o||t)&&(s=ie(n)),(!o||t)&&(r=X(n)),s=this._makeWidthCorrection(n,s),i.css({width:s,height:r})},_moveItem(i,e,t){let n,o=this._getItems(),s=o[e],r=this._getSourceDraggable();t&&(i=i.clone(),r._toggleDragSourceClass(!1,i)),s||(n=o[e-1]),this._moveItemCore(i,s,n)},_moveItemCore(i,e,t){!e&&!t?i.appendTo(this.$element()):t?i.insertAfter(u(t)):i.insertBefore(u(e))},_getDragStartArgs(i,e){return m(this.callBase.apply(this,arguments),{fromIndex:this._getElementIndex(e)})},_getEventArgs(i){let e=this._getSourceDraggable(),t=this._getTargetDraggable(),n=t.option("dropInsideItem");return m(this.callBase.apply(this,arguments),{fromIndex:e.option("fromIndex"),toIndex:this._normalizeToIndex(t.option("toIndex"),n),dropInsideItem:n})},_optionChanged(i){let{name:e}=i;switch(e){case"onDragChange":case"onPlaceholderPrepared":case"onAdd":case"onRemove":case"onReorder":this[`_${e}Action`]=this._createActionByOption(e);break;case"itemOrientation":case"allowDropInsideItem":case"moveItemOnDrop":case"dropFeedbackMode":case"itemPoints":case"animation":case"allowReordering":case"fromIndexOffset":case"offset":case"draggableElementSize":case"autoUpdate":break;case"fromIndex":[!1,!0].forEach(t=>{let n=t?i.value:i.previousValue;if(n!==null){let o=u(this._getItems()[n]);this._toggleDragSourceClass(t,o)}});break;case"dropInsideItem":this._optionChangedDropInsideItem(i);break;case"toIndex":this._optionChangedToIndex(i);break;default:this.callBase(i)}},_optionChangedDropInsideItem(){this._isIndicateMode()&&this._$placeholderElement&&this._movePlaceholder()},_isPositionVisible(i){let e=this.$element(),t;if(e.css("overflow")!=="hidden"?t=e.get(0):e.parents().each(function(){if(u(this).css("overflow")!=="visible")return t=this,!1}),t){let n=Ie(t),o=this._isVerticalOrientation(),s=o?"top":"left",r=o?"bottom":"right",a=o?YH.pageYOffset:YH.pageXOffset;if(i[s]<n[s]+a||i[s]>n[r]+a)return!1}return!0},_optionChangedToIndex(i){let e=i.value;if(this._isIndicateMode()){let t=e!==null&&e>=0;this._togglePlaceholder(t),t&&this._movePlaceholder()}else this._moveItems(i.previousValue,i.value,i.fullUpdate)},update(){if(this.option("fromIndex")===null&&this.option("toIndex")===null)return;this._updateItemPoints(!0),this._updateDragSourceClass();let i=this.option("toIndex");this._optionChangedToIndex({value:i,fullUpdate:!0})},_updateDragSourceClass(){let i=this._getActualFromIndex(),e=u(this._getItems()[i]);e.length&&(this._$sourceElement=e,this._toggleDragSourceClass(!0,e))},_makeLeftCorrection(i){let e=this._$scrollable;if(e&&this._isVerticalOrientation()){let t=e.offset().left-i;t>0&&(i+=t)}return i},_movePlaceholder(){let i=this,e=i._$placeholderElement||i._createPlaceholder();if(!e)return;let t=i._getItems(),n=i.option("toIndex"),o=i._isVerticalOrientation(),s=this.option("rtlEnabled"),r=i.option("dropInsideItem"),a=null,l=t[n];if(l){let d=u(l);a=d.offset(),!o&&s&&!r&&(a.left+=ie(d,!0))}else{let d=l=this._getPrevVisibleItem(t,n);d&&(a=u(d).offset(),o?a.top+=X(d,!0):s||(a.left+=ie(d,!0)))}if(i._updatePlaceholderSizes(e,l),a&&!i._isPositionVisible(a)&&(a=null),a){let d=o&&n===t.length,c=X(e);a.left=i._makeLeftCorrection(a.left),a.top=d&&a.top>=c?a.top-c:a.top,i._move(a,e)}e.toggle(!!a)},_getPositions(i,e,t,n){let o=[];for(let s=0;s<i.length;s++){let r=0;if(n===null||t===null){o.push(r);continue}t===-1?s>=n&&(r=e):n===-1?s>t&&(r=-e):t<n?s>t&&s<n&&(r=-e):t>n&&s>=n&&s<t&&(r=e),o.push(r)}return o},_getDraggableElementSize(i){let e=this._getDraggableElement(),t=this.option("draggableElementSize");return t||(t=i?(X(e)+X(e,!0))/2:(ie(e)+ie(e,!0))/2,this.option("autoUpdate")||this.option("draggableElementSize",t)),t},_getActualFromIndex(){let{fromIndex:i,fromIndexOffset:e,offset:t}=this.option();return i==null?null:i+e-t},_moveItems(i,e,t){let n=this._getActualFromIndex(),o=this._isVerticalOrientation(),s=o?"top":"left",r=this._getDraggableElementSize(o),a=this._getItems(),l=this._getPositions(a,r,n,i),d=this._getPositions(a,r,n,e),c=this.option("animation"),h=this.option("rtlEnabled");for(let p=0;p<a.length;p++){let g=a[p],C=l[p],v=d[p];e===null||n===null?c7(g):(C!==v||t&&f(v))&&d7(g,m({},c,{to:{[s]:!o&&h?-v:v}}))}},_toggleDragSourceClass(i,e){let t=e||this._$sourceElement;this.callBase.apply(this,arguments),this._isIndicateMode()||t&&t.toggleClass(this._addWidgetPrefix("source-hidden"),i)},_dispose(){this.reset(),this.callBase()},_fireAddEvent(i){let e=this._getEventArgs(i);return this._getAction("onAdd")(e),e.cancel},_fireRemoveEvent(i){let e=this._getSourceDraggable(),t=this._getEventArgs(i);return e._getAction("onRemove")(t),t.cancel},_fireReorderEvent(i){let e=this._getEventArgs(i);return this._getAction("onReorder")(e),e.promise||y().resolve()}});G(l7,QH);var ZH=QH;var JH=ZH;var e1={dragCell:"dx-drag-cell"},Ys={cellFocusDisabled:"dx-cell-focus-disabled",handleIcon:"drag-icon",commandDrag:"dx-command-drag",sortableWithoutHandle:"dx-sortable-without-handle",rowsView:"rowsview",dragView:"dragview"};var h7=i=>(e,t)=>{let n=u(e);if(t.rowType==="data")return n.addClass(Ys.cellFocusDisabled),u("<span>").addClass(i(Ys.handleIcon));M.setEmptyText(n)},t1={createHandleTemplateFunc:h7};var p7=i=>class extends i{init(){super.init.apply(this,arguments),this._updateHandleColumn()}optionChanged(e){e.name==="rowDragging"&&(this._updateHandleColumn(),this._invalidate(!0,!0),e.handled=!0),super.optionChanged.apply(this,arguments)}_allowReordering(){let e=this.option("rowDragging");return!!(e&&(e.allowReordering||e.allowDropInsideItem||e.group))}_updateHandleColumn(){let e=this.option("rowDragging"),t=this._allowReordering(),n=this._columnsController,o=t&&e.showDragIcons;n?.addCommandColumn({type:"drag",command:"drag",visibleIndex:-2,alignment:"center",elementAttr:[{name:e1.dragCell,value:""}],cssClass:Ys.commandDrag,width:"auto",cellTemplate:this._getHandleTemplate(),visible:o}),n?.columnOption("type:drag","visible",o)}_renderContent(){let e=this.option("rowDragging"),t=this._allowReordering(),n=super._renderContent.apply(this,arguments),o=this._isFixedTableRendering,s=o?"_sortableFixed":"_sortable",r=o?"_sortable":"_sortableFixed",a=c=>{var h;(h=this._sortableFixed)===null||h===void 0||h.$element().css("pointerEvents",c?"auto":"")},l=".dx-row:not(.dx-freespace-row):not(.dx-virtual-row):not(.dx-header-row):not(.dx-footer-row)",d=this.option("dataRowTemplate")?`> table > tbody${l}`:`> table > tbody > ${l}`;return(t||this[s])&&n.length&&(this[s]=this._createComponent(n,JH,m({component:this.component,contentTemplate:null,filter:d,cursorOffset:c=>{let{event:h}=c,p=u(this.element()).offset();return{x:h.pageX-p.left}},onDraggableElementShown:c=>{if(e.dragTemplate)return;let p=u(c.dragElement).children(".dx-widget").data(this.component.NAME);this._synchronizeScrollLeftPosition(p)},dragTemplate:this._getDraggableRowTemplate(),handle:e.showDragIcons&&`.${Ys.commandDrag}`,dropFeedbackMode:"indicate"},e,{onDragStart:c=>{var h,p;(h=this.getController("keyboardNavigation"))===null||h===void 0||h._resetFocusedCell();let g=c.component.getVisibleRows()[c.fromIndex];c.itemData=g&&g.data;let C=g&&g.rowType==="data";c.cancel=!t||!C,(p=e.onDragStart)===null||p===void 0||p.call(e,c)},onDragEnter:c=>{c.fromComponent!==c.toComponent&&a(!0)},onDragLeave:()=>{a(!1)},onDragEnd:c=>{var h;a(!1),(h=e.onDragEnd)===null||h===void 0||h.call(e,c)},onAdd:c=>{var h;a(!1),(h=e.onAdd)===null||h===void 0||h.call(e,c)},dropFeedbackMode:e.dropFeedbackMode,onOptionChanged:c=>{this._sortableFixed&&(c.name==="fromIndex"||c.name==="toIndex")&&this[r].option(c.name,c.value)}})),n.toggleClass("dx-scrollable-container",o),n.toggleClass(Ys.sortableWithoutHandle,t&&!e.showDragIcons)),n}_renderCore(e){super._renderCore.apply(this,arguments),e&&e.changeType==="update"&&e.repaintChangesOnly&&M.isVirtualRowRendering(this)&&Jt(()=>{this._updateSortable()})}_updateSortable(){let e=this._dataController.getRowIndexOffset(),t=e-this._previousOffset;[this._sortable,this._sortableFixed].forEach(n=>{let o=n?.option("toIndex");f(o)&&f(this._previousOffset)&&n?.option("toIndex",o-t),n?.option("offset",e),n?.update()}),this._previousOffset=e}_resizeCore(){super._resizeCore.apply(this,arguments),this._updateSortable()}_getDraggableGridOptions(e){let t=this.option(),n=this.getColumns(),o=u(this.getRowElement(e.rowIndex));return{dataSource:[{id:1,parentId:0}],showBorders:!0,showColumnHeaders:!1,scrolling:{useNative:!1,showScrollbar:"never"},pager:{visible:!1},loadingTimeout:null,columnFixing:t.columnFixing,columnAutoWidth:t.columnAutoWidth,showColumnLines:t.showColumnLines,columns:n.map(s=>({width:s.width||s.visibleWidth,fixed:s.fixed,fixedPosition:s.fixedPosition})),onRowPrepared:s=>{let r=s.component.getView("rowsView");u(s.rowElement).replaceWith(o.eq(r._isFixedTableRendering?1:0).clone())}}}_synchronizeScrollLeftPosition(e){let t=e?.getScrollable();t?.scrollTo({x:this._scrollLeft})}_getDraggableRowTemplate(){return e=>{let t=this.component.$element(),n=u("<div>");Fo(n,z(t));let o=this._dataController.items(),s=o&&o[e.fromIndex],r=this._getDraggableGridOptions(s);return this._createComponent(n,this.component.NAME,r),n.find(".dx-gridbase-container").children(`:not(.${this.addWidgetPrefix(Ys.rowsView)})`).hide(),n.addClass(this.addWidgetPrefix(Ys.dragView)),n}}_getHandleTemplate(){return t1.createHandleTemplateFunc(e=>this.addWidgetPrefix(e))}},i1={defaultOptions:()=>({rowDragging:{showDragIcons:!0,dropFeedbackMode:"indicate",allowReordering:!1,allowDropInsideItem:!1}}),extenders:{views:{rowsView:p7}}};H.registerModule("rowDragging",i1);var n1=xk;var o1=n1;var g7=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get allowColumnReordering(){return this._getOption("allowColumnReordering")}set allowColumnReordering(t){this._setOption("allowColumnReordering",t)}get allowColumnResizing(){return this._getOption("allowColumnResizing")}set allowColumnResizing(t){this._setOption("allowColumnResizing",t)}get autoNavigateToFocusedRow(){return this._getOption("autoNavigateToFocusedRow")}set autoNavigateToFocusedRow(t){this._setOption("autoNavigateToFocusedRow",t)}get cacheEnabled(){return this._getOption("cacheEnabled")}set cacheEnabled(t){this._setOption("cacheEnabled",t)}get cellHintEnabled(){return this._getOption("cellHintEnabled")}set cellHintEnabled(t){this._setOption("cellHintEnabled",t)}get columnAutoWidth(){return this._getOption("columnAutoWidth")}set columnAutoWidth(t){this._setOption("columnAutoWidth",t)}get columnChooser(){return this._getOption("columnChooser")}set columnChooser(t){this._setOption("columnChooser",t)}get columnFixing(){return this._getOption("columnFixing")}set columnFixing(t){this._setOption("columnFixing",t)}get columnHidingEnabled(){return this._getOption("columnHidingEnabled")}set columnHidingEnabled(t){this._setOption("columnHidingEnabled",t)}get columnMinWidth(){return this._getOption("columnMinWidth")}set columnMinWidth(t){this._setOption("columnMinWidth",t)}get columnResizingMode(){return this._getOption("columnResizingMode")}set columnResizingMode(t){this._setOption("columnResizingMode",t)}get columns(){return this._getOption("columns")}set columns(t){this._setOption("columns",t)}get columnWidth(){return this._getOption("columnWidth")}set columnWidth(t){this._setOption("columnWidth",t)}get customizeColumns(){return this._getOption("customizeColumns")}set customizeColumns(t){this._setOption("customizeColumns",t)}get dataRowTemplate(){return this._getOption("dataRowTemplate")}set dataRowTemplate(t){this._setOption("dataRowTemplate",t)}get dataSource(){return this._getOption("dataSource")}set dataSource(t){this._setOption("dataSource",t)}get dateSerializationFormat(){return this._getOption("dateSerializationFormat")}set dateSerializationFormat(t){this._setOption("dateSerializationFormat",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get editing(){return this._getOption("editing")}set editing(t){this._setOption("editing",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get errorRowEnabled(){return this._getOption("errorRowEnabled")}set errorRowEnabled(t){this._setOption("errorRowEnabled",t)}get export(){return this._getOption("export")}set export(t){this._setOption("export",t)}get filterBuilder(){return this._getOption("filterBuilder")}set filterBuilder(t){this._setOption("filterBuilder",t)}get filterBuilderPopup(){return this._getOption("filterBuilderPopup")}set filterBuilderPopup(t){this._setOption("filterBuilderPopup",t)}get filterPanel(){return this._getOption("filterPanel")}set filterPanel(t){this._setOption("filterPanel",t)}get filterRow(){return this._getOption("filterRow")}set filterRow(t){this._setOption("filterRow",t)}get filterSyncEnabled(){return this._getOption("filterSyncEnabled")}set filterSyncEnabled(t){this._setOption("filterSyncEnabled",t)}get filterValue(){return this._getOption("filterValue")}set filterValue(t){this._setOption("filterValue",t)}get focusedColumnIndex(){return this._getOption("focusedColumnIndex")}set focusedColumnIndex(t){this._setOption("focusedColumnIndex",t)}get focusedRowEnabled(){return this._getOption("focusedRowEnabled")}set focusedRowEnabled(t){this._setOption("focusedRowEnabled",t)}get focusedRowIndex(){return this._getOption("focusedRowIndex")}set focusedRowIndex(t){this._setOption("focusedRowIndex",t)}get focusedRowKey(){return this._getOption("focusedRowKey")}set focusedRowKey(t){this._setOption("focusedRowKey",t)}get grouping(){return this._getOption("grouping")}set grouping(t){this._setOption("grouping",t)}get groupPanel(){return this._getOption("groupPanel")}set groupPanel(t){this._setOption("groupPanel",t)}get headerFilter(){return this._getOption("headerFilter")}set headerFilter(t){this._setOption("headerFilter",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get highlightChanges(){return this._getOption("highlightChanges")}set highlightChanges(t){this._setOption("highlightChanges",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get keyboardNavigation(){return this._getOption("keyboardNavigation")}set keyboardNavigation(t){this._setOption("keyboardNavigation",t)}get keyExpr(){return this._getOption("keyExpr")}set keyExpr(t){this._setOption("keyExpr",t)}get loadPanel(){return this._getOption("loadPanel")}set loadPanel(t){this._setOption("loadPanel",t)}get masterDetail(){return this._getOption("masterDetail")}set masterDetail(t){this._setOption("masterDetail",t)}get noDataText(){return this._getOption("noDataText")}set noDataText(t){this._setOption("noDataText",t)}get pager(){return this._getOption("pager")}set pager(t){this._setOption("pager",t)}get paging(){return this._getOption("paging")}set paging(t){this._setOption("paging",t)}get remoteOperations(){return this._getOption("remoteOperations")}set remoteOperations(t){this._setOption("remoteOperations",t)}get renderAsync(){return this._getOption("renderAsync")}set renderAsync(t){this._setOption("renderAsync",t)}get repaintChangesOnly(){return this._getOption("repaintChangesOnly")}set repaintChangesOnly(t){this._setOption("repaintChangesOnly",t)}get rowAlternationEnabled(){return this._getOption("rowAlternationEnabled")}set rowAlternationEnabled(t){this._setOption("rowAlternationEnabled",t)}get rowDragging(){return this._getOption("rowDragging")}set rowDragging(t){this._setOption("rowDragging",t)}get rowTemplate(){return this._getOption("rowTemplate")}set rowTemplate(t){this._setOption("rowTemplate",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get scrolling(){return this._getOption("scrolling")}set scrolling(t){this._setOption("scrolling",t)}get searchPanel(){return this._getOption("searchPanel")}set searchPanel(t){this._setOption("searchPanel",t)}get selectedRowKeys(){return this._getOption("selectedRowKeys")}set selectedRowKeys(t){this._setOption("selectedRowKeys",t)}get selection(){return this._getOption("selection")}set selection(t){this._setOption("selection",t)}get selectionFilter(){return this._getOption("selectionFilter")}set selectionFilter(t){this._setOption("selectionFilter",t)}get showBorders(){return this._getOption("showBorders")}set showBorders(t){this._setOption("showBorders",t)}get showColumnHeaders(){return this._getOption("showColumnHeaders")}set showColumnHeaders(t){this._setOption("showColumnHeaders",t)}get showColumnLines(){return this._getOption("showColumnLines")}set showColumnLines(t){this._setOption("showColumnLines",t)}get showRowLines(){return this._getOption("showRowLines")}set showRowLines(t){this._setOption("showRowLines",t)}get sortByGroupSummaryInfo(){return this._getOption("sortByGroupSummaryInfo")}set sortByGroupSummaryInfo(t){this._setOption("sortByGroupSummaryInfo",t)}get sorting(){return this._getOption("sorting")}set sorting(t){this._setOption("sorting",t)}get stateStoring(){return this._getOption("stateStoring")}set stateStoring(t){this._setOption("stateStoring",t)}get summary(){return this._getOption("summary")}set summary(t){this._setOption("summary",t)}get syncLookupFilterValues(){return this._getOption("syncLookupFilterValues")}set syncLookupFilterValues(t){this._setOption("syncLookupFilterValues",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get toolbar(){return this._getOption("toolbar")}set toolbar(t){this._setOption("toolbar",t)}get twoWayBindingEnabled(){return this._getOption("twoWayBindingEnabled")}set twoWayBindingEnabled(t){this._setOption("twoWayBindingEnabled",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get wordWrapEnabled(){return this._getOption("wordWrapEnabled")}set wordWrapEnabled(t){this._setOption("wordWrapEnabled",t)}onAdaptiveDetailRowPreparing;onCellClick;onCellDblClick;onCellHoverChanged;onCellPrepared;onContentReady;onContextMenuPreparing;onDataErrorOccurred;onDisposing;onEditCanceled;onEditCanceling;onEditingStart;onEditorPrepared;onEditorPreparing;onExporting;onFocusedCellChanged;onFocusedCellChanging;onFocusedRowChanged;onFocusedRowChanging;onInitialized;onInitNewRow;onKeyDown;onOptionChanged;onRowClick;onRowCollapsed;onRowCollapsing;onRowDblClick;onRowExpanded;onRowExpanding;onRowInserted;onRowInserting;onRowPrepared;onRowRemoved;onRowRemoving;onRowUpdated;onRowUpdating;onRowValidating;onSaved;onSaving;onSelectionChanged;onToolbarPreparing;accessKeyChange;activeStateEnabledChange;allowColumnReorderingChange;allowColumnResizingChange;autoNavigateToFocusedRowChange;cacheEnabledChange;cellHintEnabledChange;columnAutoWidthChange;columnChooserChange;columnFixingChange;columnHidingEnabledChange;columnMinWidthChange;columnResizingModeChange;columnsChange;columnWidthChange;customizeColumnsChange;dataRowTemplateChange;dataSourceChange;dateSerializationFormatChange;disabledChange;editingChange;elementAttrChange;errorRowEnabledChange;exportChange;filterBuilderChange;filterBuilderPopupChange;filterPanelChange;filterRowChange;filterSyncEnabledChange;filterValueChange;focusedColumnIndexChange;focusedRowEnabledChange;focusedRowIndexChange;focusedRowKeyChange;groupingChange;groupPanelChange;headerFilterChange;heightChange;highlightChangesChange;hintChange;hoverStateEnabledChange;keyboardNavigationChange;keyExprChange;loadPanelChange;masterDetailChange;noDataTextChange;pagerChange;pagingChange;remoteOperationsChange;renderAsyncChange;repaintChangesOnlyChange;rowAlternationEnabledChange;rowDraggingChange;rowTemplateChange;rtlEnabledChange;scrollingChange;searchPanelChange;selectedRowKeysChange;selectionChange;selectionFilterChange;showBordersChange;showColumnHeadersChange;showColumnLinesChange;showRowLinesChange;sortByGroupSummaryInfoChange;sortingChange;stateStoringChange;summaryChange;syncLookupFilterValuesChange;tabIndexChange;toolbarChange;twoWayBindingEnabledChange;visibleChange;widthChange;wordWrapEnabledChange;get columnsChildren(){return this._getOption("columns")}set columnsChildren(t){this.setChildren("columns",t)}get sortByGroupSummaryInfoChildren(){return this._getOption("sortByGroupSummaryInfo")}set sortByGroupSummaryInfoChildren(t){this.setChildren("sortByGroupSummaryInfo",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"adaptiveDetailRowPreparing",emit:"onAdaptiveDetailRowPreparing"},{subscribe:"cellClick",emit:"onCellClick"},{subscribe:"cellDblClick",emit:"onCellDblClick"},{subscribe:"cellHoverChanged",emit:"onCellHoverChanged"},{subscribe:"cellPrepared",emit:"onCellPrepared"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"contextMenuPreparing",emit:"onContextMenuPreparing"},{subscribe:"dataErrorOccurred",emit:"onDataErrorOccurred"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"editCanceled",emit:"onEditCanceled"},{subscribe:"editCanceling",emit:"onEditCanceling"},{subscribe:"editingStart",emit:"onEditingStart"},{subscribe:"editorPrepared",emit:"onEditorPrepared"},{subscribe:"editorPreparing",emit:"onEditorPreparing"},{subscribe:"exporting",emit:"onExporting"},{subscribe:"focusedCellChanged",emit:"onFocusedCellChanged"},{subscribe:"focusedCellChanging",emit:"onFocusedCellChanging"},{subscribe:"focusedRowChanged",emit:"onFocusedRowChanged"},{subscribe:"focusedRowChanging",emit:"onFocusedRowChanging"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"initNewRow",emit:"onInitNewRow"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"rowClick",emit:"onRowClick"},{subscribe:"rowCollapsed",emit:"onRowCollapsed"},{subscribe:"rowCollapsing",emit:"onRowCollapsing"},{subscribe:"rowDblClick",emit:"onRowDblClick"},{subscribe:"rowExpanded",emit:"onRowExpanded"},{subscribe:"rowExpanding",emit:"onRowExpanding"},{subscribe:"rowInserted",emit:"onRowInserted"},{subscribe:"rowInserting",emit:"onRowInserting"},{subscribe:"rowPrepared",emit:"onRowPrepared"},{subscribe:"rowRemoved",emit:"onRowRemoved"},{subscribe:"rowRemoving",emit:"onRowRemoving"},{subscribe:"rowUpdated",emit:"onRowUpdated"},{subscribe:"rowUpdating",emit:"onRowUpdating"},{subscribe:"rowValidating",emit:"onRowValidating"},{subscribe:"saved",emit:"onSaved"},{subscribe:"saving",emit:"onSaving"},{subscribe:"selectionChanged",emit:"onSelectionChanged"},{subscribe:"toolbarPreparing",emit:"onToolbarPreparing"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"allowColumnReorderingChange"},{emit:"allowColumnResizingChange"},{emit:"autoNavigateToFocusedRowChange"},{emit:"cacheEnabledChange"},{emit:"cellHintEnabledChange"},{emit:"columnAutoWidthChange"},{emit:"columnChooserChange"},{emit:"columnFixingChange"},{emit:"columnHidingEnabledChange"},{emit:"columnMinWidthChange"},{emit:"columnResizingModeChange"},{emit:"columnsChange"},{emit:"columnWidthChange"},{emit:"customizeColumnsChange"},{emit:"dataRowTemplateChange"},{emit:"dataSourceChange"},{emit:"dateSerializationFormatChange"},{emit:"disabledChange"},{emit:"editingChange"},{emit:"elementAttrChange"},{emit:"errorRowEnabledChange"},{emit:"exportChange"},{emit:"filterBuilderChange"},{emit:"filterBuilderPopupChange"},{emit:"filterPanelChange"},{emit:"filterRowChange"},{emit:"filterSyncEnabledChange"},{emit:"filterValueChange"},{emit:"focusedColumnIndexChange"},{emit:"focusedRowEnabledChange"},{emit:"focusedRowIndexChange"},{emit:"focusedRowKeyChange"},{emit:"groupingChange"},{emit:"groupPanelChange"},{emit:"headerFilterChange"},{emit:"heightChange"},{emit:"highlightChangesChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"keyboardNavigationChange"},{emit:"keyExprChange"},{emit:"loadPanelChange"},{emit:"masterDetailChange"},{emit:"noDataTextChange"},{emit:"pagerChange"},{emit:"pagingChange"},{emit:"remoteOperationsChange"},{emit:"renderAsyncChange"},{emit:"repaintChangesOnlyChange"},{emit:"rowAlternationEnabledChange"},{emit:"rowDraggingChange"},{emit:"rowTemplateChange"},{emit:"rtlEnabledChange"},{emit:"scrollingChange"},{emit:"searchPanelChange"},{emit:"selectedRowKeysChange"},{emit:"selectionChange"},{emit:"selectionFilterChange"},{emit:"showBordersChange"},{emit:"showColumnHeadersChange"},{emit:"showColumnLinesChange"},{emit:"showRowLinesChange"},{emit:"sortByGroupSummaryInfoChange"},{emit:"sortingChange"},{emit:"stateStoringChange"},{emit:"summaryChange"},{emit:"syncLookupFilterValuesChange"},{emit:"tabIndexChange"},{emit:"toolbarChange"},{emit:"twoWayBindingEnabledChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"wordWrapEnabledChange"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new o1(t,n)}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("columns",t),this.setupChanges("dataSource",t),this.setupChanges("keyExpr",t),this.setupChanges("selectedRowKeys",t),this.setupChanges("sortByGroupSummaryInfo",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("columns"),this._idh.doCheck("dataSource"),this._idh.doCheck("keyExpr"),this._idh.doCheck("selectedRowKeys"),this._idh.doCheck("sortByGroupSummaryInfo"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-data-grid"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,BD,4),ke(s,VD,4)),n&2){let r;Be(r=Ve())&&(o.columnsChildren=r),Be(r=Ve())&&(o.sortByGroupSummaryInfoChildren=r)}},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",allowColumnReordering:"allowColumnReordering",allowColumnResizing:"allowColumnResizing",autoNavigateToFocusedRow:"autoNavigateToFocusedRow",cacheEnabled:"cacheEnabled",cellHintEnabled:"cellHintEnabled",columnAutoWidth:"columnAutoWidth",columnChooser:"columnChooser",columnFixing:"columnFixing",columnHidingEnabled:"columnHidingEnabled",columnMinWidth:"columnMinWidth",columnResizingMode:"columnResizingMode",columns:"columns",columnWidth:"columnWidth",customizeColumns:"customizeColumns",dataRowTemplate:"dataRowTemplate",dataSource:"dataSource",dateSerializationFormat:"dateSerializationFormat",disabled:"disabled",editing:"editing",elementAttr:"elementAttr",errorRowEnabled:"errorRowEnabled",export:"export",filterBuilder:"filterBuilder",filterBuilderPopup:"filterBuilderPopup",filterPanel:"filterPanel",filterRow:"filterRow",filterSyncEnabled:"filterSyncEnabled",filterValue:"filterValue",focusedColumnIndex:"focusedColumnIndex",focusedRowEnabled:"focusedRowEnabled",focusedRowIndex:"focusedRowIndex",focusedRowKey:"focusedRowKey",grouping:"grouping",groupPanel:"groupPanel",headerFilter:"headerFilter",height:"height",highlightChanges:"highlightChanges",hint:"hint",hoverStateEnabled:"hoverStateEnabled",keyboardNavigation:"keyboardNavigation",keyExpr:"keyExpr",loadPanel:"loadPanel",masterDetail:"masterDetail",noDataText:"noDataText",pager:"pager",paging:"paging",remoteOperations:"remoteOperations",renderAsync:"renderAsync",repaintChangesOnly:"repaintChangesOnly",rowAlternationEnabled:"rowAlternationEnabled",rowDragging:"rowDragging",rowTemplate:"rowTemplate",rtlEnabled:"rtlEnabled",scrolling:"scrolling",searchPanel:"searchPanel",selectedRowKeys:"selectedRowKeys",selection:"selection",selectionFilter:"selectionFilter",showBorders:"showBorders",showColumnHeaders:"showColumnHeaders",showColumnLines:"showColumnLines",showRowLines:"showRowLines",sortByGroupSummaryInfo:"sortByGroupSummaryInfo",sorting:"sorting",stateStoring:"stateStoring",summary:"summary",syncLookupFilterValues:"syncLookupFilterValues",tabIndex:"tabIndex",toolbar:"toolbar",twoWayBindingEnabled:"twoWayBindingEnabled",visible:"visible",width:"width",wordWrapEnabled:"wordWrapEnabled"},outputs:{onAdaptiveDetailRowPreparing:"onAdaptiveDetailRowPreparing",onCellClick:"onCellClick",onCellDblClick:"onCellDblClick",onCellHoverChanged:"onCellHoverChanged",onCellPrepared:"onCellPrepared",onContentReady:"onContentReady",onContextMenuPreparing:"onContextMenuPreparing",onDataErrorOccurred:"onDataErrorOccurred",onDisposing:"onDisposing",onEditCanceled:"onEditCanceled",onEditCanceling:"onEditCanceling",onEditingStart:"onEditingStart",onEditorPrepared:"onEditorPrepared",onEditorPreparing:"onEditorPreparing",onExporting:"onExporting",onFocusedCellChanged:"onFocusedCellChanged",onFocusedCellChanging:"onFocusedCellChanging",onFocusedRowChanged:"onFocusedRowChanged",onFocusedRowChanging:"onFocusedRowChanging",onInitialized:"onInitialized",onInitNewRow:"onInitNewRow",onKeyDown:"onKeyDown",onOptionChanged:"onOptionChanged",onRowClick:"onRowClick",onRowCollapsed:"onRowCollapsed",onRowCollapsing:"onRowCollapsing",onRowDblClick:"onRowDblClick",onRowExpanded:"onRowExpanded",onRowExpanding:"onRowExpanding",onRowInserted:"onRowInserted",onRowInserting:"onRowInserting",onRowPrepared:"onRowPrepared",onRowRemoved:"onRowRemoved",onRowRemoving:"onRowRemoving",onRowUpdated:"onRowUpdated",onRowUpdating:"onRowUpdating",onRowValidating:"onRowValidating",onSaved:"onSaved",onSaving:"onSaving",onSelectionChanged:"onSelectionChanged",onToolbarPreparing:"onToolbarPreparing",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",allowColumnReorderingChange:"allowColumnReorderingChange",allowColumnResizingChange:"allowColumnResizingChange",autoNavigateToFocusedRowChange:"autoNavigateToFocusedRowChange",cacheEnabledChange:"cacheEnabledChange",cellHintEnabledChange:"cellHintEnabledChange",columnAutoWidthChange:"columnAutoWidthChange",columnChooserChange:"columnChooserChange",columnFixingChange:"columnFixingChange",columnHidingEnabledChange:"columnHidingEnabledChange",columnMinWidthChange:"columnMinWidthChange",columnResizingModeChange:"columnResizingModeChange",columnsChange:"columnsChange",columnWidthChange:"columnWidthChange",customizeColumnsChange:"customizeColumnsChange",dataRowTemplateChange:"dataRowTemplateChange",dataSourceChange:"dataSourceChange",dateSerializationFormatChange:"dateSerializationFormatChange",disabledChange:"disabledChange",editingChange:"editingChange",elementAttrChange:"elementAttrChange",errorRowEnabledChange:"errorRowEnabledChange",exportChange:"exportChange",filterBuilderChange:"filterBuilderChange",filterBuilderPopupChange:"filterBuilderPopupChange",filterPanelChange:"filterPanelChange",filterRowChange:"filterRowChange",filterSyncEnabledChange:"filterSyncEnabledChange",filterValueChange:"filterValueChange",focusedColumnIndexChange:"focusedColumnIndexChange",focusedRowEnabledChange:"focusedRowEnabledChange",focusedRowIndexChange:"focusedRowIndexChange",focusedRowKeyChange:"focusedRowKeyChange",groupingChange:"groupingChange",groupPanelChange:"groupPanelChange",headerFilterChange:"headerFilterChange",heightChange:"heightChange",highlightChangesChange:"highlightChangesChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",keyboardNavigationChange:"keyboardNavigationChange",keyExprChange:"keyExprChange",loadPanelChange:"loadPanelChange",masterDetailChange:"masterDetailChange",noDataTextChange:"noDataTextChange",pagerChange:"pagerChange",pagingChange:"pagingChange",remoteOperationsChange:"remoteOperationsChange",renderAsyncChange:"renderAsyncChange",repaintChangesOnlyChange:"repaintChangesOnlyChange",rowAlternationEnabledChange:"rowAlternationEnabledChange",rowDraggingChange:"rowDraggingChange",rowTemplateChange:"rowTemplateChange",rtlEnabledChange:"rtlEnabledChange",scrollingChange:"scrollingChange",searchPanelChange:"searchPanelChange",selectedRowKeysChange:"selectedRowKeysChange",selectionChange:"selectionChange",selectionFilterChange:"selectionFilterChange",showBordersChange:"showBordersChange",showColumnHeadersChange:"showColumnHeadersChange",showColumnLinesChange:"showColumnLinesChange",showRowLinesChange:"showRowLinesChange",sortByGroupSummaryInfoChange:"sortByGroupSummaryInfoChange",sortingChange:"sortingChange",stateStoringChange:"stateStoringChange",summaryChange:"summaryChange",syncLookupFilterValuesChange:"syncLookupFilterValuesChange",tabIndexChange:"tabIndexChange",toolbarChange:"toolbarChange",twoWayBindingEnabledChange:"twoWayBindingEnabledChange",visibleChange:"visibleChange",widthChange:"widthChange",wordWrapEnabledChange:"wordWrapEnabledChange"},standalone:!1,features:[le([ee,ae,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),m7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[PC,Vt,At,Mt,Rt,kt,Bt,mx,fx,BC,Sx,kC,ei,ex,ox,_l,qC,ix,TC,$C,RC,YC,FC,Ti,Ox,AC,MC,dx,Tt,Pt,Ft,Nt,Lt,Ai,zC,GC,LC,NC,KC,QC,WC,UC,jC,rx,JC,ZC,tx,nx,sx,ax,lx,cx,ux,VC,hx,gx,Cx,xx,vx,yx,XC,wx,bx,Ex,qe,ye,PC,Vt,At,Mt,Rt,kt,Bt,mx,fx,BC,Sx,kC,ei,ex,ox,_l,qC,ix,TC,$C,RC,YC,FC,Ti,Ox,AC,MC,dx,Tt,Pt,Ft,Nt,Lt,Ai,zC,GC,LC,NC,KC,QC,WC,UC,jC,rx,JC,ZC,tx,nx,sx,ax,lx,cx,ux,VC,hx,gx,Cx,xx,vx,yx,XC,wx,bx,Ex,ye]})}return i})();var f7={provide:Ri,useExisting:Ht(()=>s1),multi:!0},s1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get acceptCustomValue(){return this._getOption("acceptCustomValue")}set acceptCustomValue(t){this._setOption("acceptCustomValue",t)}get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get adaptivityEnabled(){return this._getOption("adaptivityEnabled")}set adaptivityEnabled(t){this._setOption("adaptivityEnabled",t)}get applyButtonText(){return this._getOption("applyButtonText")}set applyButtonText(t){this._setOption("applyButtonText",t)}get applyValueMode(){return this._getOption("applyValueMode")}set applyValueMode(t){this._setOption("applyValueMode",t)}get buttons(){return this._getOption("buttons")}set buttons(t){this._setOption("buttons",t)}get calendarOptions(){return this._getOption("calendarOptions")}set calendarOptions(t){this._setOption("calendarOptions",t)}get cancelButtonText(){return this._getOption("cancelButtonText")}set cancelButtonText(t){this._setOption("cancelButtonText",t)}get dateOutOfRangeMessage(){return this._getOption("dateOutOfRangeMessage")}set dateOutOfRangeMessage(t){this._setOption("dateOutOfRangeMessage",t)}get dateSerializationFormat(){return this._getOption("dateSerializationFormat")}set dateSerializationFormat(t){this._setOption("dateSerializationFormat",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get disabledDates(){return this._getOption("disabledDates")}set disabledDates(t){this._setOption("disabledDates",t)}get displayFormat(){return this._getOption("displayFormat")}set displayFormat(t){this._setOption("displayFormat",t)}get dropDownButtonTemplate(){return this._getOption("dropDownButtonTemplate")}set dropDownButtonTemplate(t){this._setOption("dropDownButtonTemplate",t)}get dropDownOptions(){return this._getOption("dropDownOptions")}set dropDownOptions(t){this._setOption("dropDownOptions",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get inputAttr(){return this._getOption("inputAttr")}set inputAttr(t){this._setOption("inputAttr",t)}get interval(){return this._getOption("interval")}set interval(t){this._setOption("interval",t)}get invalidDateMessage(){return this._getOption("invalidDateMessage")}set invalidDateMessage(t){this._setOption("invalidDateMessage",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get labelMode(){return this._getOption("labelMode")}set labelMode(t){this._setOption("labelMode",t)}get max(){return this._getOption("max")}set max(t){this._setOption("max",t)}get maxLength(){return this._getOption("maxLength")}set maxLength(t){this._setOption("maxLength",t)}get min(){return this._getOption("min")}set min(t){this._setOption("min",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get opened(){return this._getOption("opened")}set opened(t){this._setOption("opened",t)}get openOnFieldClick(){return this._getOption("openOnFieldClick")}set openOnFieldClick(t){this._setOption("openOnFieldClick",t)}get pickerType(){return this._getOption("pickerType")}set pickerType(t){this._setOption("pickerType",t)}get placeholder(){return this._getOption("placeholder")}set placeholder(t){this._setOption("placeholder",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get showAnalogClock(){return this._getOption("showAnalogClock")}set showAnalogClock(t){this._setOption("showAnalogClock",t)}get showClearButton(){return this._getOption("showClearButton")}set showClearButton(t){this._setOption("showClearButton",t)}get showDropDownButton(){return this._getOption("showDropDownButton")}set showDropDownButton(t){this._setOption("showDropDownButton",t)}get spellcheck(){return this._getOption("spellcheck")}set spellcheck(t){this._setOption("spellcheck",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get todayButtonText(){return this._getOption("todayButtonText")}set todayButtonText(t){this._setOption("todayButtonText",t)}get type(){return this._getOption("type")}set type(t){this._setOption("type",t)}get useMaskBehavior(){return this._getOption("useMaskBehavior")}set useMaskBehavior(t){this._setOption("useMaskBehavior",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get valueChangeEvent(){return this._getOption("valueChangeEvent")}set valueChangeEvent(t){this._setOption("valueChangeEvent",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onChange;onClosed;onContentReady;onCopy;onCut;onDisposing;onEnterKey;onFocusIn;onFocusOut;onInitialized;onInput;onKeyDown;onKeyUp;onOpened;onOptionChanged;onPaste;onValueChanged;acceptCustomValueChange;accessKeyChange;activeStateEnabledChange;adaptivityEnabledChange;applyButtonTextChange;applyValueModeChange;buttonsChange;calendarOptionsChange;cancelButtonTextChange;dateOutOfRangeMessageChange;dateSerializationFormatChange;deferRenderingChange;disabledChange;disabledDatesChange;displayFormatChange;dropDownButtonTemplateChange;dropDownOptionsChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;inputAttrChange;intervalChange;invalidDateMessageChange;isDirtyChange;isValidChange;labelChange;labelModeChange;maxChange;maxLengthChange;minChange;nameChange;openedChange;openOnFieldClickChange;pickerTypeChange;placeholderChange;readOnlyChange;rtlEnabledChange;showAnalogClockChange;showClearButtonChange;showDropDownButtonChange;spellcheckChange;stylingModeChange;tabIndexChange;textChange;todayButtonTextChange;typeChange;useMaskBehaviorChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;valueChangeEventChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};get buttonsChildren(){return this._getOption("buttons")}set buttonsChildren(t){this.setChildren("buttons",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"change",emit:"onChange"},{subscribe:"closed",emit:"onClosed"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"copy",emit:"onCopy"},{subscribe:"cut",emit:"onCut"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"enterKey",emit:"onEnterKey"},{subscribe:"focusIn",emit:"onFocusIn"},{subscribe:"focusOut",emit:"onFocusOut"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"input",emit:"onInput"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"keyUp",emit:"onKeyUp"},{subscribe:"opened",emit:"onOpened"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"paste",emit:"onPaste"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"acceptCustomValueChange"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"adaptivityEnabledChange"},{emit:"applyButtonTextChange"},{emit:"applyValueModeChange"},{emit:"buttonsChange"},{emit:"calendarOptionsChange"},{emit:"cancelButtonTextChange"},{emit:"dateOutOfRangeMessageChange"},{emit:"dateSerializationFormatChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"disabledDatesChange"},{emit:"displayFormatChange"},{emit:"dropDownButtonTemplateChange"},{emit:"dropDownOptionsChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"inputAttrChange"},{emit:"intervalChange"},{emit:"invalidDateMessageChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"labelChange"},{emit:"labelModeChange"},{emit:"maxChange"},{emit:"maxLengthChange"},{emit:"minChange"},{emit:"nameChange"},{emit:"openedChange"},{emit:"openOnFieldClickChange"},{emit:"pickerTypeChange"},{emit:"placeholderChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"showAnalogClockChange"},{emit:"showClearButtonChange"},{emit:"showDropDownButtonChange"},{emit:"spellcheckChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"textChange"},{emit:"todayButtonTextChange"},{emit:"typeChange"},{emit:"useMaskBehaviorChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"valueChangeEventChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new um(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("buttons",t),this.setupChanges("disabledDates",t),this.setupChanges("validationErrors",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("buttons"),this._idh.doCheck("disabledDates"),this._idh.doCheck("validationErrors"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-date-box"]],contentQueries:function(n,o,s){if(n&1&&ke(s,_o,4),n&2){let r;Be(r=Ve())&&(o.buttonsChildren=r)}},hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{acceptCustomValue:"acceptCustomValue",accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",adaptivityEnabled:"adaptivityEnabled",applyButtonText:"applyButtonText",applyValueMode:"applyValueMode",buttons:"buttons",calendarOptions:"calendarOptions",cancelButtonText:"cancelButtonText",dateOutOfRangeMessage:"dateOutOfRangeMessage",dateSerializationFormat:"dateSerializationFormat",deferRendering:"deferRendering",disabled:"disabled",disabledDates:"disabledDates",displayFormat:"displayFormat",dropDownButtonTemplate:"dropDownButtonTemplate",dropDownOptions:"dropDownOptions",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",inputAttr:"inputAttr",interval:"interval",invalidDateMessage:"invalidDateMessage",isDirty:"isDirty",isValid:"isValid",label:"label",labelMode:"labelMode",max:"max",maxLength:"maxLength",min:"min",name:"name",opened:"opened",openOnFieldClick:"openOnFieldClick",pickerType:"pickerType",placeholder:"placeholder",readOnly:"readOnly",rtlEnabled:"rtlEnabled",showAnalogClock:"showAnalogClock",showClearButton:"showClearButton",showDropDownButton:"showDropDownButton",spellcheck:"spellcheck",stylingMode:"stylingMode",tabIndex:"tabIndex",text:"text",todayButtonText:"todayButtonText",type:"type",useMaskBehavior:"useMaskBehavior",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",valueChangeEvent:"valueChangeEvent",visible:"visible",width:"width"},outputs:{onChange:"onChange",onClosed:"onClosed",onContentReady:"onContentReady",onCopy:"onCopy",onCut:"onCut",onDisposing:"onDisposing",onEnterKey:"onEnterKey",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onInitialized:"onInitialized",onInput:"onInput",onKeyDown:"onKeyDown",onKeyUp:"onKeyUp",onOpened:"onOpened",onOptionChanged:"onOptionChanged",onPaste:"onPaste",onValueChanged:"onValueChanged",acceptCustomValueChange:"acceptCustomValueChange",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",adaptivityEnabledChange:"adaptivityEnabledChange",applyButtonTextChange:"applyButtonTextChange",applyValueModeChange:"applyValueModeChange",buttonsChange:"buttonsChange",calendarOptionsChange:"calendarOptionsChange",cancelButtonTextChange:"cancelButtonTextChange",dateOutOfRangeMessageChange:"dateOutOfRangeMessageChange",dateSerializationFormatChange:"dateSerializationFormatChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",disabledDatesChange:"disabledDatesChange",displayFormatChange:"displayFormatChange",dropDownButtonTemplateChange:"dropDownButtonTemplateChange",dropDownOptionsChange:"dropDownOptionsChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",inputAttrChange:"inputAttrChange",intervalChange:"intervalChange",invalidDateMessageChange:"invalidDateMessageChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",labelChange:"labelChange",labelModeChange:"labelModeChange",maxChange:"maxChange",maxLengthChange:"maxLengthChange",minChange:"minChange",nameChange:"nameChange",openedChange:"openedChange",openOnFieldClickChange:"openOnFieldClickChange",pickerTypeChange:"pickerTypeChange",placeholderChange:"placeholderChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",showAnalogClockChange:"showAnalogClockChange",showClearButtonChange:"showClearButtonChange",showDropDownButtonChange:"showDropDownButtonChange",spellcheckChange:"spellcheckChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",textChange:"textChange",todayButtonTextChange:"todayButtonTextChange",typeChange:"typeChange",useMaskBehaviorChange:"useMaskBehaviorChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",valueChangeEventChange:"valueChangeEventChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,f7,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),_7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[ei,Mi,ml,fl,ys,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,qe,ye,ei,Mi,ml,fl,ys,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,ye]})}return i})();var Ei=i=>tt.deserializeDate(i),Ra=(i,e)=>!i&&!e?!0:j.sameDate(Ei(i),Ei(e)),Fa=(i,e)=>{let[t,n]=i,[o,s]=e;return Ra(t,o)&&Ra(n,s)},r1=i=>{let[e,t]=i;return e&&t&&Ei(e)>Ei(t)?[t,e]:i},a1=(i,e)=>12*(e.getFullYear()-i.getFullYear())-i.getMonth()+e.getMonth();var qS=class extends dd{constructor(e){super(),this._dateSelectedCounter=0,this.dateBox=e,this.dateRangeBox=e.option("_dateRangeBoxInstance")}popupConfig(e){return m(!0,super.popupConfig(e),{position:{of:this.getDateRangeBox().$element()}})}popupShowingHandler(){this.getWidget()._restoreViewsMinMaxOptions(),this._dateSelectedCounter=0}_getPopup(){return super._getPopup()||this.getDateRangeBox().getStartDateBox()._popup}supportedKeys(){let e=this.getDateRangeBox();return I({},super.supportedKeys(),{rightArrow:()=>{if(e.option("opened"))return!0},leftArrow:()=>{if(e.option("opened"))return!0},enter:t=>{if(e.option("opened")){let n=this.dateBox.dateOption("value");this.dateBox._valueChangeEventHandler(t);let o=this.dateBox.dateOption("value");return!Ra(n,o)?e.getStartDateBox().getStrategy().getWidget().option("value",e.option("value")):e.getStartDateBox().getStrategy().getWidget()._enterKeyHandler(t),!1}},tab:t=>{if(!e.option("opened"))return;if(!this._getPopup().getFocusableElements().length){(!t.shiftKey&&e._isEndDateActiveElement()||t.shiftKey&&e._isStartDateActiveElement())&&e.close();return}if(!t.shiftKey&&e._isStartDateActiveElement()||t.shiftKey&&e._isEndDateActiveElement())return;let n=t.shiftKey?e.getStartDateBox()._getLastPopupElement():e.getStartDateBox()._getFirstPopupElement();n&&(_.trigger(n,"focus"),n.select()),t.preventDefault()}})}_getWidgetOptions(){let{disabledDates:e,value:t,multiView:n}=this.dateRangeBox.option(),o=A(e)?this._injectComponent(e):e??void 0;return m(super._getWidgetOptions(),{disabledDates:o,value:t,selectionMode:"range",viewsCount:n?2:1,_allowChangeSelectionOrder:!0,_currentSelection:this.getCurrentSelection()})}_refreshActiveDescendant(e){this.getDateRangeBox().setAria("activedescendant",e.actionValue)}_injectComponent(e){return t=>e(m(t,{component:this.getDateRangeBox()}))}getKeyboardListener(){let e=this.getDateRangeBox();return e.getStartDateBox()?e.getStartDateBox().getStrategy().getWidget():this.getWidget()}getValue(){return this.getWidget().option("value")}_updateValue(){let{value:e}=this.getDateRangeBox().option();this.getWidget()&&(this._shouldPreventFocusChange=!0,this.getWidget().option("value",e))}_isInstantlyMode(){return this.getDateRangeBox().option("applyValueMode")==="instantly"}_valueChangedHandler(e){let{value:t,previousValue:n,event:o}=e;if(Fa(t,n)&&!this.getWidget()._valueSelected){this._shouldPreventFocusChange=!1;return}this.getWidget()._valueSelected=!1;let s=this.getDateRangeBox();if(this._isInstantlyMode()){if(!s.option("disableOutOfRangeSelection")){if(this._getCalendarCurrentSelection()==="startDate")this._dateSelectedCounter=0;else if(this._dateSelectedCounter=1,!t[0])this._dateSelectedCounter=-1;else if(Ei(t[0])>Ei(t[1])){s.updateValue([t[0],null],o);return}}if(s.updateValue(t,o),this._dateSelectedCounter+=1,this._dateSelectedCounter===2){s.close();return}}else if(this._getCalendarCurrentSelection()==="endDate"&&t[0]&&Ei(t[0])>Ei(t[1]))return;this._shouldPreventFocusChange||this._moveFocusToNextInput(),this._shouldPreventFocusChange=!1}_moveFocusToNextInput(){let e=this._getCalendarCurrentSelection()==="startDate"?this.getDateRangeBox().getEndDateBox():this.getDateRangeBox().getStartDateBox();e.focus(),_.trigger(e.field(),"dxclick")}getCurrentSelection(){return this.getDateRangeBox().option("_currentSelection")}_getCalendarCurrentSelection(){return this.getWidget().option("_currentSelection")}_closeDropDownByEnter(){return this._getCalendarCurrentSelection()!=="startDate"}dateBoxValue(){let{dateBox:e}=this;return arguments.length?e.dateValue.apply(e,arguments):e.dateOption.apply(e,["value"])}_cellClickHandler(){}setActiveStartDateBox(){this.dateBox=this.getDateRangeBox().getStartDateBox()}setActiveEndDateBox(){this.dateBox=this.getDateRangeBox().getEndDateBox()}getDateRangeBox(){return this.dateRangeBox}getWidget(){return this._widget}},l1=qS;var C7=um,YS=class extends C7{_initStrategy(){this._strategy=new l1(this)}_initMarkup(){super._initMarkup(),this._renderInputClickEvent()}_renderInputClickEvent(){let e=D("dxclick",this.NAME);_.off(this._input(),e),_.on(this._input(),e,t=>{this._processValueChange(t)})}_applyButtonHandler(e){let{event:t}=e,n=this.getStrategy(),o=n.getValue();n.getDateRangeBox().updateValue(o,t),this.close(),this.option("focusStateEnabled")&&this.focus()}_openHandler(e){this.getStrategy().getDateRangeBox().option("opened")||super._openHandler(e)}_renderOpenedState(){let{opened:e}=this.option();this._getDateRangeBox().option("opened",e),this._isStartDateBox()&&(e&&this._createPopup(),this._getDateRangeBox()._popupContentIdentifier(this._getControlsAria()),this._setPopupOption("visible",e),this._getDateRangeBox()._setAriaAttributes())}_getDateRangeBox(){return this.getStrategy().getDateRangeBox()}_isStartDateBox(){return u(this.element()).hasClass("dx-start-datebox")}_renderPopup(){super._renderPopup(),this._isStartDateBox()&&this._getDateRangeBox()._bindInnerWidgetOptions(this._popup,"dropDownOptions")}_popupShownHandler(){var e;super._popupShownHandler(),(e=this._getDateRangeBox()._validationMessage)===null||e===void 0||e.option("positionSide",this._getValidationMessagePositionSide())}_popupHiddenHandler(){var e;super._popupHiddenHandler(),(e=this._getDateRangeBox()._validationMessage)===null||e===void 0||e.option("positionSide",this._getValidationMessagePositionSide())}_focusInHandler(e){super._focusInHandler(e),this._processValueChange(e)}_popupTabHandler(e){let t=u(e.target);e.shiftKey&&t.is(this._getFirstPopupElement())&&(this._getDateRangeBox().getEndDateBox().focus(),e.preventDefault()),!e.shiftKey&&t.is(this._getLastPopupElement())&&(this._getDateRangeBox().getStartDateBox().focus(),e.preventDefault())}_processValueChange(e){let{target:t}=e,n=this._getDateRangeBox(),[o,s]=n.field();if(u(t).is(u(o))&&n.option("_currentSelection","startDate"),u(t).is(u(s))&&n.option("_currentSelection","endDate"),!n.getStartDateBox().getStrategy().getWidget())return;let r=n.getStartDateBox().getStrategy().getWidget(),{value:a}=r.option(),l=Ei(a?.[0]),d=Ei(a?.[1]);u(t).is(u(o))&&(l&&(r._skipNavigate=!0,r.option("currentDate",l)),this.getStrategy().setActiveStartDateBox(),r.option("_currentSelection","startDate"),n.option("disableOutOfRangeSelection")&&r._setViewsMaxOption(d)),u(t).is(u(s))&&(d&&(l&&a1(l,d)>1&&(r.option("currentDate",r._getDateByOffset(null,d)),r.option("currentDate",r._getDateByOffset(-1,d))),r._skipNavigate=!0,r.option("currentDate",d)),n.getStartDateBox().getStrategy().setActiveEndDateBox(),r.option("_currentSelection","endDate"),n.option("disableOutOfRangeSelection")&&r._setViewsMinOption(l))}_invalidate(){super._invalidate(),this._refreshStrategy()}_updateInternalValidationState(e,t){this.option({isValid:e,validationError:e?null:{message:t}})}_recallInternalValidation(e){this._applyInternalValidation(e)}_isTargetOutOfComponent(e){let t=u(this._getDateRangeBox().element()),n=u(e).closest(t).length===0;return super._isTargetOutOfComponent(e)&&n}_updateLabelWidth(){let e=this._getDateRangeBox()._$beforeButtonsContainer,{labelMode:t}=this.option();if(t==="outside"&&e&&this._isStartDateBox()){this._label._updateLabelTransform(z(e));return}super._updateLabelWidth()}_optionChanged(e){switch(e.name){case"isValid":{let t=this._getDateRangeBox().option("isValid");if(this._skipIsValidOptionChange||t===e.value){super._optionChanged(e);return}this._skipIsValidOptionChange=!0,this.option({isValid:t}),this._skipIsValidOptionChange=!1;break}default:super._optionChanged(e)}}close(){this.getStrategy().getDateRangeBox().getStartDateBox().option("opened",!1)}getStrategy(){return this._strategy}},XS=YS;var d1="dx-texteditor-with-floating-label";var x7="dx-show-invalid-badge";var v7=["KeyDown","KeyUp","Change","Cut","Copy","Paste","Input","EnterKey"],xf=class extends oi{_getDefaultOptions(){return m(super._getDefaultOptions(),{acceptCustomValue:!0,activeStateEnabled:!0,applyButtonText:O.format("OK"),applyValueMode:"instantly",buttons:void 0,calendarOptions:{},cancelButtonText:O.format("Cancel"),endDateOutOfRangeMessage:O.format("dxDateRangeBox-endDateOutOfRangeMessage"),dateSerializationFormat:void 0,deferRendering:!0,disableOutOfRangeSelection:!1,disabledDates:null,displayFormat:null,dropDownButtonTemplate:"dropDownButton",dropDownOptions:{},endDate:null,endDateInputAttr:{},endDateLabel:O.format("dxDateRangeBox-endDateLabel"),endDateName:"",endDatePlaceholder:"",endDateText:void 0,focusStateEnabled:!0,hoverStateEnabled:!0,invalidStartDateMessage:O.format("dxDateRangeBox-invalidStartDateMessage"),invalidEndDateMessage:O.format("dxDateRangeBox-invalidEndDateMessage"),isValid:!0,labelMode:"static",max:void 0,min:void 0,multiView:!0,onChange:null,onClosed:null,onCopy:null,onCut:null,onEnterKey:null,onInput:null,onKeyDown:null,onKeyUp:null,onOpened:null,onPaste:null,onValueChanged:null,openOnFieldClick:!0,opened:!1,pickerType:"calendar",readOnly:!1,showClearButton:!1,showDropDownButton:!0,spellcheck:!1,startDate:null,startDateInputAttr:{},startDateLabel:O.format("dxDateRangeBox-startDateLabel"),startDateName:"",startDateOutOfRangeMessage:O.format("dxDateRangeBox-startDateOutOfRangeMessage"),startDatePlaceholder:"",startDateText:void 0,stylingMode:fe().editorStylingMode??"outlined",todayButtonText:O.format("dxCalendar-todayButtonText"),useHiddenSubmitElement:!1,useMaskBehavior:!1,validationError:null,validationErrors:null,validationMessageMode:"auto",validationMessagePosition:"auto",validationStatus:"valid",value:[null,null],valueChangeEvent:"change",_internalValidationErrors:[],_currentSelection:"startDate"})}_defaultOptionsRules(){return super._defaultOptionsRules().concat([{device(){let e=ct();return it(e)},options:{labelMode:"floating",stylingMode:fe().editorStylingMode??"filled"}},{device(){let e=ct();return ut(e)},options:{labelMode:"outside"}},{device(){let e=F.real(),{platform:t}=e;return t==="ios"||t==="android"},options:{multiView:!1}}])}_initOptions(e){super._initOptions(e);let{value:t}=this.initialOption(),{value:n,startDate:o,endDate:s}=this.option();n[0]&&n[1]&&Ei(n[0])>Ei(n[1])&&(n=[n[1],n[0]]),o&&s&&Ei(o)>Ei(s)&&([o,s]=[s,o]),Fa(t,n)?n=[o,s]:[o,s]=n,this.option({startDate:o,endDate:s,value:n})}_createOpenAction(){this._openAction=this._createActionByOption("onOpened",{excludeValidators:["disabled","readOnly"]})}_raiseOpenAction(){this._openAction||this._createOpenAction(),this._openAction()}_createCloseAction(){this._closeAction=this._createActionByOption("onClosed",{excludeValidators:["disabled","readOnly"]})}_raiseCloseAction(){this._closeAction||this._createCloseAction(),this._closeAction()}_createEventAction(e){this[`_${Ci(e)}Action`]=this._createActionByOption(`on${e}`,{excludeValidators:["readOnly"]})}_raiseAction(e,t){this[`_${Ci(e)}Action`]||this._createEventAction(e),this[`_${Ci(e)}Action`]({event:t})}_initTemplates(){this._templateManager.addDefaultTemplates({dropDownButton:new gn(e=>{let t=u("<div>").addClass("dx-dropdowneditor-icon");u(e.container).append(t)})}),super._initTemplates()}_getDefaultButtons(){return[{name:"clear",Ctor:Vl},{name:"dropDown",Ctor:Nl}]}_initMarkup(){u(this.element()).addClass("dx-daterangebox").addClass("dx-texteditor").addClass("dx-dropdowneditor"),this._toggleDropDownEditorActiveClass(),this._toggleEditorLabelClass(),this._toggleReadOnlyState(),this._renderStylingMode(),this._renderEndDateBox(),this._renderSeparator(),this._renderStartDateBox(),this._toggleEmptinessState(),this._renderEmptinessEvent(),this._renderButtonsContainer(),super._initMarkup(),u(this.element()).removeClass(x7)}_renderEmptinessEvent(){let e=D("input blur",this.NAME);_.off(this._focusTarget(),e),_.on(this._focusTarget(),e,this._toggleEmptinessState.bind(this))}_toggleEmptinessState(){let e=u(this.getStartDateBox().element()).hasClass("dx-texteditor-empty")&&u(this.getEndDateBox().element()).hasClass("dx-texteditor-empty");u(this.element()).toggleClass("dx-texteditor-empty",e)}_attachKeyboardEvents(){this.option("readOnly")||super._attachKeyboardEvents()}_toggleReadOnlyState(){let{readOnly:e}=this.option();u(this.element()).toggleClass("dx-state-readonly",!!e)}_toggleDropDownEditorActiveClass(){let{opened:e}=this.option();u(this.element()).toggleClass("dx-dropdowneditor-active",e)}_toggleEditorLabelClass(){let{startDateLabel:e,endDateLabel:t,labelMode:n}=this.option(),o=(!!e||!!t)&&n!=="hidden";u(this.element()).removeClass(d1).removeClass("dx-texteditor-label-outside").removeClass("dx-texteditor-with-label"),o&&(u(this.element()).addClass(n==="floating"?d1:"dx-texteditor-with-label"),n==="outside"&&u(this.element()).addClass("dx-texteditor-label-outside"))}_renderStartDateBox(){this._$startDateBox=u("<div>").addClass("dx-start-datebox").prependTo(this.$element()),this._startDateBox=this._createComponent(this._$startDateBox,XS,this._getStartDateBoxConfig()),this._startDateBox.NAME="_StartDateBox"}_renderEndDateBox(){this._$endDateBox=u("<div>").addClass("dx-end-datebox").appendTo(this.$element()),this._endDateBox=this._createComponent(this._$endDateBox,XS,this._getEndDateBoxConfig()),this._endDateBox.NAME="_EndDateBox"}_renderSeparator(){let e=ci("to");this._$separator=u("<div>").addClass("dx-daterangebox-separator").prependTo(this.$element()),this._renderPreventBlurOnSeparatorClick(),e?.appendTo(this._$separator)}_renderPreventBlurOnSeparatorClick(){let e=D("mousedown",this.NAME);_.off(this._$separator,e),_.on(this._$separator,e,t=>{this._hasActiveElement()||this.focus(),t.preventDefault()})}_renderButtonsContainer(){this._buttonCollection=new Ll(this,this._getDefaultButtons()),this._$beforeButtonsContainer=void 0,this._$afterButtonsContainer=void 0;let{buttons:e}=this.option();this._$beforeButtonsContainer=this._buttonCollection.renderBeforeButtons(e,this.$element()),this._$afterButtonsContainer=this._buttonCollection.renderAfterButtons(e,this.$element())}_updateButtons(e){this._buttonCollection.updateButtons(e)}_openHandler(){this._toggleOpenState()}_shouldCallOpenHandler(){return!0}_toggleOpenState(){let{opened:e}=this.option();e||this.getStartDateBox()._focusInput(),this.option("readOnly")||this.option("opened",!this.option("opened"))}_clearValueHandler(e){e.stopPropagation(),this._saveValueChangeEvent(e),this.clear(),!this._isStartDateActiveElement()&&this.focus(),_.trigger(u(this.startDateField()),"input")}_isClearButtonVisible(){return this.option("showClearButton")&&!this.option("readOnly")}_focusInHandler(e){this._shouldSkipFocusEvent(e)||super._focusInHandler(e)}_focusOutHandler(e){this._shouldSkipFocusEvent(e)||super._focusOutHandler(e)}_shouldSkipFocusEvent(e){let{target:t,relatedTarget:n}=e;return u(t).is(u(this.startDateField()))&&u(n).is(u(this.endDateField()))||u(t).is(u(this.endDateField()))&&u(n).is(u(this.startDateField()))}_getPickerType(){let{pickerType:e}=this.option();return["calendar","native"].includes(e)?e:"calendar"}_getRestErrors(e,t){return e.filter(n=>!t.some(o=>n.message===o.message))}_syncValidationErrors(e,t,n){t||(t=[]),n||(n=[]);let o=this.option(e)||[],s=this._getRestErrors(o,n);this.option(e,[...s,...t])}_getDateBoxConfig(){let e=this.option(),t={acceptCustomValue:e.acceptCustomValue,activeStateEnabled:e.activeStateEnabled,applyValueMode:e.applyValueMode,dateSerializationFormat:e.dateSerializationFormat,deferRendering:e.deferRendering,disabled:e.disabled,displayFormat:e.displayFormat,focusStateEnabled:e.focusStateEnabled,isValid:e.isValid,tabIndex:e.tabIndex,height:e.height,hoverStateEnabled:e.hoverStateEnabled,labelMode:e.labelMode,max:e.max,min:e.min,openOnFieldClick:e.openOnFieldClick,pickerType:this._getPickerType(),readOnly:e.readOnly,rtlEnabled:e.rtlEnabled,spellcheck:e.spellcheck,stylingMode:e.stylingMode,type:"date",useMaskBehavior:e.useMaskBehavior,validationMessageMode:e.validationMessageMode,validationMessagePosition:e.validationMessagePosition,valueChangeEvent:e.valueChangeEvent,onKeyDown:e.onKeyDown,onKeyUp:e.onKeyUp,onChange:e.onChange,onInput:e.onInput,onCut:e.onCut,onCopy:e.onCopy,onPaste:e.onPaste,onEnterKey:e.onEnterKey,_dateRangeBoxInstance:this,_showValidationMessage:!1};return x(v7,(n,o)=>{let s=`on${o}`;this.hasActionSubscription(s)&&(t[s]=r=>{this._raiseAction(o,r.event)})}),t}_hideOnOutsideClickHandler(e){let{target:t}=e,n=u(t),o=this.getButton("dropDown"),s=o?.$element(),r=!!n.closest(u(this.element())).length,a=!!n.closest(s).length;return!r&&!a}_getStartDateBoxConfig(){var e;let t=this.option();return I({},this._getDateBoxConfig(),{applyButtonText:t.applyButtonText,calendarOptions:t.calendarOptions,cancelButtonText:t.cancelButtonText,dateOutOfRangeMessage:t.startDateOutOfRangeMessage,deferRendering:t.deferRendering,disabledDates:(e=t.dropDownOptions)===null||e===void 0?void 0:e.disabledDates,dropDownOptions:I({showTitle:!1,title:"",hideOnOutsideClick:n=>this._hideOnOutsideClickHandler(n),hideOnParentScroll:!1,preventScrollEvents:!1},t.dropDownOptions),invalidDateMessage:t.invalidStartDateMessage,onValueChanged:n=>{let{value:o,event:s}=n,r=[o,this.option("value")[1]];this.updateValue(r,s)},opened:t.opened,onOpened:()=>{this._raiseOpenAction()},onClosed:()=>{this._raiseCloseAction()},onOptionChanged:n=>{let{name:o,value:s,previousValue:r}=n;o==="text"&&this.option("startDateText",s),o==="validationErrors"&&this._syncValidationErrors("_internalValidationErrors",s,r)},todayButtonText:t.todayButtonText,showClearButton:!1,showDropDownButton:!1,value:this.option("value")[0],label:t.startDateLabel,placeholder:t.startDatePlaceholder,inputAttr:t.startDateInputAttr,name:t.startDateName,_showValidationIcon:!1})}_getEndDateBoxConfig(){let e=this.option();return I({},this._getDateBoxConfig(),{invalidDateMessage:e.invalidEndDateMessage,dateOutOfRangeMessage:e.endDateOutOfRangeMessage,onValueChanged:t=>{let{value:n,event:o}=t,s=[this.option("value")[0],n];this.updateValue(s,o)},onOptionChanged:t=>{let{name:n,value:o,previousValue:s}=t;n==="text"&&this.option("endDateText",o),n==="validationErrors"&&this._syncValidationErrors("_internalValidationErrors",o,s)},opened:e.opened,showClearButton:!1,showDropDownButton:!1,value:this.option("value")[1],label:e.endDateLabel,placeholder:e.endDatePlaceholder,deferRendering:!0,inputAttr:e.endDateInputAttr,name:e.endDateName})}_getValidationMessagePosition(){let{validationMessagePosition:e}=this.option();return e==="auto"?this.option("opened")?"top":"bottom":e}_getSerializedDates(e){let[t,n]=e;return[this.getStartDateBox()._serializeDate(Ei(t)),this.getStartDateBox()._serializeDate(Ei(n))]}updateValue(e,t){Fa(e,this.option("value"))||(t&&this._saveValueChangeEvent(t),this.option("value",this._getSerializedDates(e)))}_updateDateBoxesValue(e){let t=this.getStartDateBox(),n=this.getEndDateBox(),[o,s]=e,r=t.option("value"),a=n.option("value");Ra(o,r)||t.option("value",o),Ra(s,a)||n.option("value",s)}_renderAccessKey(){let e=u(this.field()[0]),{accessKey:t}=this.option();e.attr("accesskey",t)}_focusTarget(){return u(this.element()).find(".dx-texteditor-input")}_focusEventTarget(){return this.element()}_focusClassTarget(){return this.$element()}_toggleFocusClass(e,t){super._toggleFocusClass(e,this._focusClassTarget(t))}_hasActiveElement(){return this._isStartDateActiveElement()||this._isEndDateActiveElement()}_isStartDateActiveElement(){return this._isActiveElement(this.startDateField())}_isEndDateActiveElement(){return this._isActiveElement(this.endDateField())}_isActiveElement(e){return u(e).is(u(w.getActiveElement(e)))}_popupContentIdentifier(e){return e&&(this._popupContentId=e),this._popupContentId}_setAriaAttributes(){let{opened:e}=this.option(),t={expanded:e,controls:this._popupContentIdentifier()},n=e?this._popupContentIdentifier():void 0;this.setAria(t),this.setAria("owns",n,this.$element())}_cleanButtonContainers(){var e,t;(e=this._$beforeButtonsContainer)===null||e===void 0||e.remove(),(t=this._$afterButtonsContainer)===null||t===void 0||t.remove(),this._buttonCollection.clean(),this._$beforeButtonsContainer=void 0,this._$afterButtonsContainer=void 0}_applyCustomValidation(e){this.validationRequest.fire({editor:this,value:e})}_clean(){var e,t,n;this._cleanButtonContainers(),(e=this._$startDateBox)===null||e===void 0||e.remove(),(t=this._$endDateBox)===null||t===void 0||t.remove(),(n=this._$separator)===null||n===void 0||n.remove(),super._clean()}_optionChanged(e){let{name:t,fullName:n,value:o,previousValue:s}=e;switch(t){case"acceptCustomValue":case"dateSerializationFormat":case"displayFormat":case"max":case"min":case"openOnFieldClick":case"spellcheck":case"useMaskBehavior":case"valueChangeEvent":this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o);break;case"rtlEnabled":default:super._optionChanged(e);break;case"labelMode":this._toggleEditorLabelClass(),this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o);break;case"applyButtonText":case"applyValueMode":case"cancelButtonText":case"deferRendering":case"disabledDates":case"todayButtonText":this.getStartDateBox().option(t,o);break;case"opened":this._toggleDropDownEditorActiveClass(),this.getStartDateBox().option(t,o),this.getEndDateBox()._setOptionWithoutOptionChange(t,o);break;case"buttons":this._cleanButtonContainers(),this._renderButtonsContainer();break;case"calendarOptions":case"dropDownOptions":this.getStartDateBox().option(n,o);break;case"pickerType":{let r=this._getPickerType();this.getStartDateBox().option(t,r),this.getEndDateBox().option(t,r);break}case"height":this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o),super._optionChanged(e);break;case"dropDownButtonTemplate":case"showDropDownButton":this._updateButtons(["dropDown"]);break;case"showClearButton":this._updateButtons(["clear"]);break;case"endDate":this.updateValue([this.option("value")[0],o]);break;case"startDateLabel":this._toggleEditorLabelClass(),this.getStartDateBox().option("label",o);break;case"endDateLabel":this._toggleEditorLabelClass(),this.getEndDateBox().option("label",o);break;case"startDatePlaceholder":this.getStartDateBox().option("placeholder",o);break;case"endDatePlaceholder":this.getEndDateBox().option("placeholder",o);break;case"startDateInputAttr":this.getStartDateBox().option("inputAttr",o);break;case"startDateName":this.getStartDateBox().option("name",o);break;case"endDateInputAttr":this.getEndDateBox().option("inputAttr",o);break;case"endDateName":this.getEndDateBox().option("name",o);break;case"multiView":this.getStartDateBox().option("calendarOptions.viewsCount",o?2:1);break;case"tabIndex":case"activeStateEnabled":case"focusStateEnabled":case"hoverStateEnabled":super._optionChanged(e),this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o);break;case"onValueChanged":this._createValueChangeAction();break;case"onOpened":this._createOpenAction();break;case"onClosed":this._createCloseAction();break;case"onKeyDown":case"onKeyUp":case"onChange":case"onInput":case"onCut":case"onCopy":case"onPaste":case"onEnterKey":this._createEventAction(t.replace("on",""));break;case"readOnly":case"disabled":this._updateButtons(),super._optionChanged(e),this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o);break;case"disableOutOfRangeSelection":case"startDateText":case"endDateText":case"useHiddenSubmitElement":case"_currentSelection":break;case"startDate":this.updateValue([o,this.option("value")[1]]);break;case"stylingMode":this._renderStylingMode(),this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o);break;case"invalidStartDateMessage":this.getStartDateBox().option("invalidDateMessage",o);break;case"invalidEndDateMessage":this.getEndDateBox().option("invalidDateMessage",o);break;case"startDateOutOfRangeMessage":this.getStartDateBox().option("dateOutOfRangeMessage",o);break;case"endDateOutOfRangeMessage":this.getEndDateBox().option("dateOutOfRangeMessage",o);break;case"validationMessagePosition":this.getStartDateBox().option(t,o),super._optionChanged(e);break;case"_internalValidationErrors":{this._syncValidationErrors("validationErrors",o,s);let r=this.option("validationErrors");this.option("isValid",!(r!=null&&r.length));break}case"isValid":{this.getStartDateBox().option(t,o),this.getEndDateBox().option(t,o);let r=o&&!this.option("_internalValidationErrors").length;if(this._shouldSkipIsValidChange||r===o){super._optionChanged(e);return}this._shouldSkipIsValidChange=!0,this.option("isValid",r),this._shouldSkipIsValidChange=!1;break}case"validationErrors":{let r=this.option("_internalValidationErrors")||[],a=o||[],d=[...this._getRestErrors(a,r),...r],c=d.length?d:null;this._options.silent("validationErrors",c),super._optionChanged(I({},e,{value:c}));break}case"value":{let r=r1(o);if(!Fa(r,s)){let a=!Fa(r,this._initialValue);this.option("isDirty",a),this._setOptionWithoutOptionChange("value",r),this._setOptionWithoutOptionChange("startDate",r[0]),this._setOptionWithoutOptionChange("endDate",r[1]),this._applyCustomValidation(r),this._updateDateBoxesValue(r),this.getStartDateBox().getStrategy().renderValue(),this._toggleEmptinessState(),this._raiseValueChangeAction(r,s),this._saveValueChangeEvent(void 0)}break}}}getStartDateBox(){return this._startDateBox}getEndDateBox(){return this._endDateBox}getButton(e){return this._buttonCollection.getButton(e)}open(){this.option("opened",!0)}close(){this.option("opened",!1)}content(){return this.getStartDateBox().content()}field(){return[this.startDateField(),this.endDateField()]}startDateField(){return this.getStartDateBox().field()}endDateField(){return this.getEndDateBox().field()}focus(){this.getStartDateBox().focus()}reset(){super.reset();let e=this.getStartDateBox(),t=this.getEndDateBox();e.reset(),t.reset(),e._updateInternalValidationState(!0),t._updateInternalValidationState(!0)}clear(){super.clear(),this.getEndDateBox().clear(),this.getStartDateBox().clear()}};G("dxDateRangeBox",xf);var c1=xf;var u1=c1;var b7={provide:Ri,useExisting:Ht(()=>h1),multi:!0},h1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get acceptCustomValue(){return this._getOption("acceptCustomValue")}set acceptCustomValue(t){this._setOption("acceptCustomValue",t)}get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get applyButtonText(){return this._getOption("applyButtonText")}set applyButtonText(t){this._setOption("applyButtonText",t)}get applyValueMode(){return this._getOption("applyValueMode")}set applyValueMode(t){this._setOption("applyValueMode",t)}get buttons(){return this._getOption("buttons")}set buttons(t){this._setOption("buttons",t)}get calendarOptions(){return this._getOption("calendarOptions")}set calendarOptions(t){this._setOption("calendarOptions",t)}get cancelButtonText(){return this._getOption("cancelButtonText")}set cancelButtonText(t){this._setOption("cancelButtonText",t)}get dateSerializationFormat(){return this._getOption("dateSerializationFormat")}set dateSerializationFormat(t){this._setOption("dateSerializationFormat",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get disableOutOfRangeSelection(){return this._getOption("disableOutOfRangeSelection")}set disableOutOfRangeSelection(t){this._setOption("disableOutOfRangeSelection",t)}get displayFormat(){return this._getOption("displayFormat")}set displayFormat(t){this._setOption("displayFormat",t)}get dropDownButtonTemplate(){return this._getOption("dropDownButtonTemplate")}set dropDownButtonTemplate(t){this._setOption("dropDownButtonTemplate",t)}get dropDownOptions(){return this._getOption("dropDownOptions")}set dropDownOptions(t){this._setOption("dropDownOptions",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get endDate(){return this._getOption("endDate")}set endDate(t){this._setOption("endDate",t)}get endDateInputAttr(){return this._getOption("endDateInputAttr")}set endDateInputAttr(t){this._setOption("endDateInputAttr",t)}get endDateLabel(){return this._getOption("endDateLabel")}set endDateLabel(t){this._setOption("endDateLabel",t)}get endDateName(){return this._getOption("endDateName")}set endDateName(t){this._setOption("endDateName",t)}get endDateOutOfRangeMessage(){return this._getOption("endDateOutOfRangeMessage")}set endDateOutOfRangeMessage(t){this._setOption("endDateOutOfRangeMessage",t)}get endDatePlaceholder(){return this._getOption("endDatePlaceholder")}set endDatePlaceholder(t){this._setOption("endDatePlaceholder",t)}get endDateText(){return this._getOption("endDateText")}set endDateText(t){this._setOption("endDateText",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get invalidEndDateMessage(){return this._getOption("invalidEndDateMessage")}set invalidEndDateMessage(t){this._setOption("invalidEndDateMessage",t)}get invalidStartDateMessage(){return this._getOption("invalidStartDateMessage")}set invalidStartDateMessage(t){this._setOption("invalidStartDateMessage",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get labelMode(){return this._getOption("labelMode")}set labelMode(t){this._setOption("labelMode",t)}get max(){return this._getOption("max")}set max(t){this._setOption("max",t)}get min(){return this._getOption("min")}set min(t){this._setOption("min",t)}get multiView(){return this._getOption("multiView")}set multiView(t){this._setOption("multiView",t)}get opened(){return this._getOption("opened")}set opened(t){this._setOption("opened",t)}get openOnFieldClick(){return this._getOption("openOnFieldClick")}set openOnFieldClick(t){this._setOption("openOnFieldClick",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get showClearButton(){return this._getOption("showClearButton")}set showClearButton(t){this._setOption("showClearButton",t)}get showDropDownButton(){return this._getOption("showDropDownButton")}set showDropDownButton(t){this._setOption("showDropDownButton",t)}get spellcheck(){return this._getOption("spellcheck")}set spellcheck(t){this._setOption("spellcheck",t)}get startDate(){return this._getOption("startDate")}set startDate(t){this._setOption("startDate",t)}get startDateInputAttr(){return this._getOption("startDateInputAttr")}set startDateInputAttr(t){this._setOption("startDateInputAttr",t)}get startDateLabel(){return this._getOption("startDateLabel")}set startDateLabel(t){this._setOption("startDateLabel",t)}get startDateName(){return this._getOption("startDateName")}set startDateName(t){this._setOption("startDateName",t)}get startDateOutOfRangeMessage(){return this._getOption("startDateOutOfRangeMessage")}set startDateOutOfRangeMessage(t){this._setOption("startDateOutOfRangeMessage",t)}get startDatePlaceholder(){return this._getOption("startDatePlaceholder")}set startDatePlaceholder(t){this._setOption("startDatePlaceholder",t)}get startDateText(){return this._getOption("startDateText")}set startDateText(t){this._setOption("startDateText",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get todayButtonText(){return this._getOption("todayButtonText")}set todayButtonText(t){this._setOption("todayButtonText",t)}get useMaskBehavior(){return this._getOption("useMaskBehavior")}set useMaskBehavior(t){this._setOption("useMaskBehavior",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get valueChangeEvent(){return this._getOption("valueChangeEvent")}set valueChangeEvent(t){this._setOption("valueChangeEvent",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onChange;onClosed;onContentReady;onCopy;onCut;onDisposing;onEnterKey;onFocusIn;onFocusOut;onInitialized;onInput;onKeyDown;onKeyUp;onOpened;onOptionChanged;onPaste;onValueChanged;acceptCustomValueChange;accessKeyChange;activeStateEnabledChange;applyButtonTextChange;applyValueModeChange;buttonsChange;calendarOptionsChange;cancelButtonTextChange;dateSerializationFormatChange;deferRenderingChange;disabledChange;disableOutOfRangeSelectionChange;displayFormatChange;dropDownButtonTemplateChange;dropDownOptionsChange;elementAttrChange;endDateChange;endDateInputAttrChange;endDateLabelChange;endDateNameChange;endDateOutOfRangeMessageChange;endDatePlaceholderChange;endDateTextChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;invalidEndDateMessageChange;invalidStartDateMessageChange;isDirtyChange;isValidChange;labelModeChange;maxChange;minChange;multiViewChange;openedChange;openOnFieldClickChange;readOnlyChange;rtlEnabledChange;showClearButtonChange;showDropDownButtonChange;spellcheckChange;startDateChange;startDateInputAttrChange;startDateLabelChange;startDateNameChange;startDateOutOfRangeMessageChange;startDatePlaceholderChange;startDateTextChange;stylingModeChange;tabIndexChange;todayButtonTextChange;useMaskBehaviorChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;valueChangeEventChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};get buttonsChildren(){return this._getOption("buttons")}set buttonsChildren(t){this.setChildren("buttons",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"change",emit:"onChange"},{subscribe:"closed",emit:"onClosed"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"copy",emit:"onCopy"},{subscribe:"cut",emit:"onCut"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"enterKey",emit:"onEnterKey"},{subscribe:"focusIn",emit:"onFocusIn"},{subscribe:"focusOut",emit:"onFocusOut"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"input",emit:"onInput"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"keyUp",emit:"onKeyUp"},{subscribe:"opened",emit:"onOpened"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"paste",emit:"onPaste"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"acceptCustomValueChange"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"applyButtonTextChange"},{emit:"applyValueModeChange"},{emit:"buttonsChange"},{emit:"calendarOptionsChange"},{emit:"cancelButtonTextChange"},{emit:"dateSerializationFormatChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"disableOutOfRangeSelectionChange"},{emit:"displayFormatChange"},{emit:"dropDownButtonTemplateChange"},{emit:"dropDownOptionsChange"},{emit:"elementAttrChange"},{emit:"endDateChange"},{emit:"endDateInputAttrChange"},{emit:"endDateLabelChange"},{emit:"endDateNameChange"},{emit:"endDateOutOfRangeMessageChange"},{emit:"endDatePlaceholderChange"},{emit:"endDateTextChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"invalidEndDateMessageChange"},{emit:"invalidStartDateMessageChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"labelModeChange"},{emit:"maxChange"},{emit:"minChange"},{emit:"multiViewChange"},{emit:"openedChange"},{emit:"openOnFieldClickChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"showClearButtonChange"},{emit:"showDropDownButtonChange"},{emit:"spellcheckChange"},{emit:"startDateChange"},{emit:"startDateInputAttrChange"},{emit:"startDateLabelChange"},{emit:"startDateNameChange"},{emit:"startDateOutOfRangeMessageChange"},{emit:"startDatePlaceholderChange"},{emit:"startDateTextChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"todayButtonTextChange"},{emit:"useMaskBehaviorChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"valueChangeEventChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new u1(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("buttons",t),this.setupChanges("validationErrors",t),this.setupChanges("value",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("buttons"),this._idh.doCheck("validationErrors"),this._idh.doCheck("value"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-date-range-box"]],contentQueries:function(n,o,s){if(n&1&&ke(s,_o,4),n&2){let r;Be(r=Ve())&&(o.buttonsChildren=r)}},hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{acceptCustomValue:"acceptCustomValue",accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",applyButtonText:"applyButtonText",applyValueMode:"applyValueMode",buttons:"buttons",calendarOptions:"calendarOptions",cancelButtonText:"cancelButtonText",dateSerializationFormat:"dateSerializationFormat",deferRendering:"deferRendering",disabled:"disabled",disableOutOfRangeSelection:"disableOutOfRangeSelection",displayFormat:"displayFormat",dropDownButtonTemplate:"dropDownButtonTemplate",dropDownOptions:"dropDownOptions",elementAttr:"elementAttr",endDate:"endDate",endDateInputAttr:"endDateInputAttr",endDateLabel:"endDateLabel",endDateName:"endDateName",endDateOutOfRangeMessage:"endDateOutOfRangeMessage",endDatePlaceholder:"endDatePlaceholder",endDateText:"endDateText",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",invalidEndDateMessage:"invalidEndDateMessage",invalidStartDateMessage:"invalidStartDateMessage",isDirty:"isDirty",isValid:"isValid",labelMode:"labelMode",max:"max",min:"min",multiView:"multiView",opened:"opened",openOnFieldClick:"openOnFieldClick",readOnly:"readOnly",rtlEnabled:"rtlEnabled",showClearButton:"showClearButton",showDropDownButton:"showDropDownButton",spellcheck:"spellcheck",startDate:"startDate",startDateInputAttr:"startDateInputAttr",startDateLabel:"startDateLabel",startDateName:"startDateName",startDateOutOfRangeMessage:"startDateOutOfRangeMessage",startDatePlaceholder:"startDatePlaceholder",startDateText:"startDateText",stylingMode:"stylingMode",tabIndex:"tabIndex",todayButtonText:"todayButtonText",useMaskBehavior:"useMaskBehavior",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",valueChangeEvent:"valueChangeEvent",visible:"visible",width:"width"},outputs:{onChange:"onChange",onClosed:"onClosed",onContentReady:"onContentReady",onCopy:"onCopy",onCut:"onCut",onDisposing:"onDisposing",onEnterKey:"onEnterKey",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onInitialized:"onInitialized",onInput:"onInput",onKeyDown:"onKeyDown",onKeyUp:"onKeyUp",onOpened:"onOpened",onOptionChanged:"onOptionChanged",onPaste:"onPaste",onValueChanged:"onValueChanged",acceptCustomValueChange:"acceptCustomValueChange",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",applyButtonTextChange:"applyButtonTextChange",applyValueModeChange:"applyValueModeChange",buttonsChange:"buttonsChange",calendarOptionsChange:"calendarOptionsChange",cancelButtonTextChange:"cancelButtonTextChange",dateSerializationFormatChange:"dateSerializationFormatChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",disableOutOfRangeSelectionChange:"disableOutOfRangeSelectionChange",displayFormatChange:"displayFormatChange",dropDownButtonTemplateChange:"dropDownButtonTemplateChange",dropDownOptionsChange:"dropDownOptionsChange",elementAttrChange:"elementAttrChange",endDateChange:"endDateChange",endDateInputAttrChange:"endDateInputAttrChange",endDateLabelChange:"endDateLabelChange",endDateNameChange:"endDateNameChange",endDateOutOfRangeMessageChange:"endDateOutOfRangeMessageChange",endDatePlaceholderChange:"endDatePlaceholderChange",endDateTextChange:"endDateTextChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",invalidEndDateMessageChange:"invalidEndDateMessageChange",invalidStartDateMessageChange:"invalidStartDateMessageChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",labelModeChange:"labelModeChange",maxChange:"maxChange",minChange:"minChange",multiViewChange:"multiViewChange",openedChange:"openedChange",openOnFieldClickChange:"openOnFieldClickChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",showClearButtonChange:"showClearButtonChange",showDropDownButtonChange:"showDropDownButtonChange",spellcheckChange:"spellcheckChange",startDateChange:"startDateChange",startDateInputAttrChange:"startDateInputAttrChange",startDateLabelChange:"startDateLabelChange",startDateNameChange:"startDateNameChange",startDateOutOfRangeMessageChange:"startDateOutOfRangeMessageChange",startDatePlaceholderChange:"startDatePlaceholderChange",startDateTextChange:"startDateTextChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",todayButtonTextChange:"todayButtonTextChange",useMaskBehaviorChange:"useMaskBehaviorChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",valueChangeEventChange:"valueChangeEventChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,b7,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),y7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[ei,Mi,ml,fl,ys,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,qe,ye,ei,Mi,ml,fl,ys,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,ye]})}return i})();var p1=Fc.inherit({_getDefaultOptions(){return m(this.callBase(),{toolbarItems:[],showCloseButton:!1,enableBodyScroll:!0,showTitle:!1,title:null,titleTemplate:null,onTitleRendered:null,bottomTemplate:null,preventScrollEvents:!1,propagateOutsideClick:!0})},_render(){this.$element().addClass("dx-tooltip"),this.$wrapper().addClass("dx-tooltip-wrapper"),this.callBase()},_renderContent(){this.callBase(),this._toggleAriaAttributes()},_toggleAriaDescription(i){let e=u(this.option("target")),t=i?this._contentId:void 0;Ne(e.get(0))||this.setAria("describedby",t,e)},_toggleAriaAttributes(){this._contentId=`dx-${new Oe}`,this.$overlayContent().attr({id:this._contentId}),this._toggleAriaDescription(!0)}});G("dxTooltip",p1);var g1=p1;var m1=g1;var no={moveTo(i){let{$element:e}=i,{position:t}=i,n=i.direction||"left",o={},s;switch(n){case"right":o.transform=`translate(${t}px, 0px)`,s="custom";break;case"left":o.left=t,s="slide";break;case"top":case"bottom":o.top=t,s="slide"}pe.animate(e,{type:s,to:o,duration:i.duration,complete:i.complete})},margin(i){let{$element:e}=i,{margin:t}=i,n=i.direction||"left",o={};o[`margin${Ci(n,!0)}`]=t,pe.animate(e,{to:o,duration:i.duration,complete:i.complete})},fade(i,e,t,n){pe.animate(i,{type:"fade",to:e.to,from:e.from,duration:t,complete:n})},size(i){let{$element:e}=i,{size:t}=i,n=i.direction||"left",o=i.marginTop||0,{duration:s}=i,r={};n==="right"||n==="left"?r.width=t:r.height=t,n==="bottom"&&(r.marginTop=o),pe.animate(e,{to:r,duration:s,complete:i.complete})},complete(i){pe.stop(i,!0)}};var QS=class{constructor(e){this._drawer=e}getDrawerInstance(){return this._drawer}renderPanelContent(e){let t=this.getDrawerInstance(),n=t._getTemplate(t.option("template"));n&&n.render({container:t.content(),onRendered:()=>{e.resolve()}})}renderPosition(e,t){let n=y(),o=y(),s=this.getDrawerInstance();e&&P.apply(u,[n,o]).done(()=>{s._animationCompleteHandler()}),this._internalRenderPosition(e,n),e||s.resizeViewContent(),this.renderShaderVisibility(e,t,o)}_getPanelOffset(e){let t=this.getDrawerInstance(),n=t.isHorizontalDirection()?t.getRealPanelWidth():t.getRealPanelHeight();return e?-(n-t.getMaxSize()):-(n-t.getMinSize())}_getPanelSize(e){return e?this.getDrawerInstance().getMaxSize():this.getDrawerInstance().getMinSize()}renderShaderVisibility(e,t,n){let o=this.getDrawerInstance(),s=o.option("opened"),r=s?{from:0,to:1}:{from:1,to:0};e?no.fade(u(o._$shader),r,t,()=>{this._drawer._toggleShaderVisibility(s),n.resolve()}):(o._toggleShaderVisibility(s),o._$shader.css("opacity",r.to))}getPanelContent(){return u(this.getDrawerInstance().content())}setPanelSize(e){this.refreshPanelElementSize(e)}refreshPanelElementSize(e){let t=this.getDrawerInstance(),n=this._getPanelSize(t.option("opened"));t.isHorizontalDirection()?Fo(u(t.content()),e?t.getRealPanelWidth():n):xi(u(t.content()),e?t.getRealPanelHeight():n)}isViewContentFirst(){return!1}onPanelContentRendered(){}},Id=QS;var ZS=class extends Id{renderPanelContent(e){delete this._initialPosition;let t=this.getDrawerInstance(),{opened:n,minSize:o}=t.option();t._overlay=t._createComponent(t.content(),Ni,{shading:!1,container:t.content(),visualContainer:t.getOverlayTarget(),position:this._getOverlayPosition(),width:n?"auto":o||0,height:"100%",templatesRenderAsynchronously:t.option("templatesRenderAsynchronously"),animation:{show:{duration:0}},onPositioned:function(s){this._fixOverlayPosition(s.component.$content())}.bind(this),contentTemplate:t.option("template"),onContentReady:s=>{e.resolve(),this._processOverlayZIndex(s.component.content())},visible:!0,propagateOutsideClick:!0})}_fixOverlayPosition(e){let t=Te(this._initialPosition,{left:0,top:0});Ae(e,t),this.getDrawerInstance().calcTargetPosition()==="right"&&e.css("left","auto"),this.getDrawerInstance().calcTargetPosition()==="bottom"&&(e.css("top","auto"),e.css("bottom","0px"))}_getOverlayPosition(){let e=this.getDrawerInstance(),t=e.calcTargetPosition(),n={};switch(t){case"left":n={my:"top left",at:"top left"};break;case"right":n={my:e.option("rtlEnabled")?"top left":"top right",at:"top right"};break;case"top":case"bottom":n={my:t,at:t}}return n.of=e.getOverlayTarget(),n}refreshPanelElementSize(e){let t=this.getDrawerInstance(),n=t.getOverlay();t.isHorizontalDirection()?(n.option("height","100%"),n.option("width",e?t.getRealPanelWidth():this._getPanelSize(t.option("opened")))):(n.option("width",z(t.getOverlayTarget())),n.option("height",e?t.getRealPanelHeight():this._getPanelSize(t.option("opened"))))}onPanelContentRendered(){this._updateViewContentStyles()}_updateViewContentStyles(){let e=this.getDrawerInstance();u(e.viewContent()).css(`padding${Ci(e.calcTargetPosition(),!0)}`,e.option("minSize")),u(e.viewContent()).css("transform","inherit")}_internalRenderPosition(e,t){let n=this.getDrawerInstance(),o=u(n.content()),s=n.getOverlay().$content(),r=n.option("revealMode"),a=n.calcTargetPosition(),l=this._getPanelSize(n.option("opened")),d=this._getPanelOffset(n.option("opened"))*n._getPositionCorrection(),c=n.getRealPanelHeight()-l;this._updateViewContentStyles(),e?r==="slide"?(this._initialPosition=n.isHorizontalDirection()?{left:d}:{top:d},no.moveTo({complete:()=>{t.resolve()},duration:n.option("animationDuration"),direction:a,$element:o,position:d})):r==="expand"&&(this._initialPosition=n.isHorizontalDirection()?{left:0}:{top:0},Ae(s,this._initialPosition),no.size({complete:()=>{t.resolve()},duration:n.option("animationDuration"),direction:a,$element:s,size:l,marginTop:c})):r==="slide"?(this._initialPosition=n.isHorizontalDirection()?{left:d}:{top:d},Ae(o,this._initialPosition)):r==="expand"&&(this._initialPosition=n.isHorizontalDirection()?{left:0}:{top:0},Ae(s,this._initialPosition),n.isHorizontalDirection()?u(s).css("width",l):(u(s).css("height",l),a==="bottom"&&u(s).css("marginTop",c)))}getPanelContent(){return u(this.getDrawerInstance().getOverlay().content())}_processOverlayZIndex(e){let n=u(e).get(0).style.zIndex||1;this.getDrawerInstance().setZIndex(n)}isViewContentFirst(e){return e==="right"||e==="bottom"}},f1=ZS;var JS=class extends Id{_internalRenderPosition(e,t){let n=this.getDrawerInstance(),o=this._getPanelSize(!0),s=this._getPanelSize(n.option("opened"))*n._getPositionCorrection();if(u(n.content()).css(n.isHorizontalDirection()?"width":"height",o),n.getMinSize()){let r="padding";switch(n.calcTargetPosition()){case"left":r+="Right";break;case"right":r+="Left";break;case"top":r+="Bottom";break;case"bottom":r+="Top"}u(n.viewContent()).css(r,n.getMinSize())}e?no.moveTo({$element:u(n.viewContent()),position:s,direction:n.calcTargetPosition(),duration:n.option("animationDuration"),complete:()=>{t.resolve()}}):n.isHorizontalDirection()?Ae(u(n.viewContent()),{left:s}):Ae(u(n.viewContent()),{top:s})}onPanelContentRendered(){u(this.getDrawerInstance().viewContent()).addClass("dx-theme-background-color")}},_1=JS;var eE=class extends Id{_internalRenderPosition(e,t){let n=this.getDrawerInstance(),o=n.calcTargetPosition(),s=u(n.content()),r=this._getPanelSize(n.option("opened")),a=this._getPanelOffset(n.option("opened")),l=n.option("revealMode");e?l==="slide"?no.margin({complete:()=>{t.resolve()},$element:s,duration:n.option("animationDuration"),direction:o,margin:a}):l==="expand"&&no.size({complete:()=>{t.resolve()},$element:s,duration:n.option("animationDuration"),direction:o,size:r}):l==="slide"?s.css(`margin${Ci(o,!0)}`,a):l==="expand"&&s.css(n.isHorizontalDirection()?"width":"height",r)}isViewContentFirst(e,t){return(t?e==="left":e==="right")||e==="bottom"}},C1=eE;var O7=Xe.inherit({_getDefaultOptions(){return m(this.callBase(),{position:"left",opened:!1,minSize:null,maxSize:null,shading:!1,template:"panel",openedStateMode:"shrink",revealMode:"slide",animationEnabled:!0,animationDuration:400,closeOnOutsideClick:!1,contentTemplate:"content"})},_init(){this.callBase(),this._initStrategy(),this.$element().addClass("dx-drawer"),this._whenAnimationCompleted=void 0,this._whenPanelContentRendered=void 0,this._whenPanelContentRefreshed=void 0,this._$wrapper=u("<div>").addClass("dx-drawer-wrapper"),this._$viewContentWrapper=u("<div>").addClass("dx-drawer-content"),this._$wrapper.append(this._$viewContentWrapper),this.$element().append(this._$wrapper)},_initStrategy(){switch(this.option("openedStateMode")){case"push":default:this._strategy=new _1(this);break;case"shrink":this._strategy=new C1(this);break;case"overlap":this._strategy=new f1(this)}},_getAnonymousTemplateName:()=>"content",_initTemplates(){let i={};i.panel=new Vi,i.content=new Vi,this._templateManager.addDefaultTemplates(i),this.callBase()},_viewContentWrapperClickHandler(i){let e=this.option("closeOnOutsideClick");A(e)&&(e=e(i)),e&&this.option("opened")&&(this.stopAnimations(),this.option("shading")&&i.preventDefault(),this.hide())},_initMarkup(){this.callBase(),this._toggleOpenedStateClass(this.option("opened")),this._renderPanelContentWrapper(),this._refreshOpenedStateModeClass(),this._refreshRevealModeClass(),this._renderShader(),this._refreshPositionClass(),this._whenPanelContentRendered=y(),this._strategy.renderPanelContent(this._whenPanelContentRendered),this._strategy.onPanelContentRendered(),this._renderViewContent(),_.off(this._$viewContentWrapper,oe),_.on(this._$viewContentWrapper,oe,this._viewContentWrapperClickHandler.bind(this)),this._refreshWrapperChildrenOrder()},_render(){this._initMinMaxSize(),this.callBase(),this._whenPanelContentRendered.always(()=>{this._initMinMaxSize(),this._strategy.refreshPanelElementSize(this.option("revealMode")==="slide"),this._renderPosition(this.option("opened"),!0),this._removePanelManualPosition()})},_removePanelManualPosition(){this._$panelContentWrapper.attr("manualposition")&&(this._$panelContentWrapper.removeAttr("manualPosition"),this._$panelContentWrapper.css({position:"",top:"",left:"",right:"",bottom:""}))},_togglePanelContentHiddenClass(){let i=()=>{let{minSize:e,opened:t}=this.option(),n=e?!1:!t;this._$panelContentWrapper.toggleClass("dx-drawer-panel-content-hidden",n)};this._whenAnimationCompleted&&!this.option("opened")?P(this._whenAnimationCompleted).done(i):i()},_renderPanelContentWrapper(){let{openedStateMode:i,opened:e,minSize:t}=this.option();this._$panelContentWrapper=u("<div>").addClass("dx-drawer-panel-content"),this._togglePanelContentHiddenClass();let n=this.calcTargetPosition();i==="push"&&["top","bottom"].includes(n)&&this._$panelContentWrapper.addClass("dx-drawer-panel-content-push-top-or-bottom"),i!=="overlap"&&!e&&!t&&(this._$panelContentWrapper.attr("manualposition",!0),this._$panelContentWrapper.css({position:"absolute",top:"-10000px",left:"-10000px",right:"auto",bottom:"auto"})),this._$wrapper.append(this._$panelContentWrapper)},_refreshOpenedStateModeClass(i){i&&this.$element().removeClass(`dx-drawer-${i}`),this.$element().addClass(`dx-drawer-${this.option("openedStateMode")}`)},_refreshPositionClass(){this.$element().removeClass(["left","right","top","bottom"].map(i=>`dx-drawer-${i}`).join(" ")).addClass(`dx-drawer-${this.calcTargetPosition()}`)},_refreshWrapperChildrenOrder(){let i=this.calcTargetPosition();this._strategy.isViewContentFirst(i,this.option("rtlEnabled"))?this._$wrapper.prepend(this._$viewContentWrapper):this._$wrapper.prepend(this._$panelContentWrapper)},_refreshRevealModeClass(i){i&&this.$element().removeClass(`dx-drawer-${i}`),this.$element().addClass(`dx-drawer-${this.option("revealMode")}`)},_renderViewContent(){let i=this.option("contentTemplate"),e=this._getTemplate(i);if(e){let t=e.render({container:this.viewContent(),noModel:!0,transclude:this._templateManager.anonymousTemplateName===i});t.hasClass("ng-scope")&&u(this._$viewContentWrapper).children().not(".dx-drawer-shader").replaceWith(t)}},_renderShader(){this._$shader=this._$shader||u("<div>").addClass("dx-drawer-shader"),this._$shader.appendTo(this.viewContent()),this._toggleShaderVisibility(this.option("opened"))},_initSize(){this._initMinMaxSize()},_initMinMaxSize(){let i=this.isHorizontalDirection()?this.getRealPanelWidth():this.getRealPanelHeight();this._maxSize=this.option("maxSize")||i,this._minSize=this.option("minSize")||0},calcTargetPosition(){let{position:i,rtlEnabled:e}=this.option();return i==="before"?e?"right":"left":i==="after"?e?"left":"right":i},getOverlayTarget(){return this._$wrapper},getOverlay(){return this._overlay},getMaxSize(){return this._maxSize},getMinSize(){return this._minSize},getRealPanelWidth(){return W()?f(this.option("templateSize"))?this.option("templateSize"):Ie(this._getPanelTemplateElement()).width:0},getRealPanelHeight(){return W()?f(this.option("templateSize"))?this.option("templateSize"):Ie(this._getPanelTemplateElement()).height:0},_getPanelTemplateElement(){let i=this._strategy.getPanelContent(),e=i;return i.children().length&&(e=i.children().eq(0),i.hasClass("dx-overlay-content")&&e.hasClass("dx-template-wrapper")&&e.children().length&&(e=e.children().eq(0))),e.get(0)},getElementHeight(i){let e=i.children();return e.length?Ie(e.eq(0).get(0)).height:Ie(i.get(0)).height},isHorizontalDirection(){let i=this.calcTargetPosition();return i==="left"||i==="right"},stopAnimations(i){pe.stop(this._$shader,i),pe.stop(u(this.content()),i),pe.stop(u(this.viewContent()),i);let e=this.getOverlay();e&&pe.stop(u(e.$content()),i)},setZIndex(i){this._$shader.css("zIndex",i-1),this._$panelContentWrapper.css("zIndex",i)},resizeContent(){this.resizeViewContent},resizeViewContent(){bi(this.viewContent())},_isInvertedPosition(){let i=this.calcTargetPosition();return i==="right"||i==="bottom"},_renderPosition(i,e,t){if(this.stopAnimations(t),!W())return;u(this.viewContent()).css("paddingLeft",0),u(this.viewContent()).css("paddingRight",0),u(this.viewContent()).css("paddingTop",0),u(this.viewContent()).css("paddingBottom",0);let n=this.option("animationEnabled");e===!0&&(n=!1),i&&this._toggleShaderVisibility(i),this._strategy.renderPosition(n,this.option("animationDuration"))},_animationCompleteHandler(){this.resizeViewContent(),this._whenAnimationCompleted&&this._whenAnimationCompleted.resolve()},_getPositionCorrection(){return this._isInvertedPosition()?-1:1},_dispose(){no.complete(u(this.viewContent())),this.callBase()},_visibilityChanged(i){i&&this._dimensionChanged()},_dimensionChanged(){this._initMinMaxSize(),this._strategy.refreshPanelElementSize(this.option("revealMode")==="slide"),this._renderPosition(this.option("opened"),!0)},_toggleShaderVisibility(i){this.option("shading")?(this._$shader.toggleClass("dx-state-invisible",!i),this._$shader.css("visibility",i?"visible":"hidden")):this._$shader.toggleClass("dx-state-invisible",!0)},_toggleOpenedStateClass(i){this.$element().toggleClass("dx-drawer-opened",i)},_refreshPanel(){u(this.viewContent()).css("left",0),u(this.viewContent()).css("transform","translate(0px, 0px)"),u(this.viewContent()).removeClass("dx-theme-background-color"),this._removePanelContentWrapper(),this._removeOverlay(),this._renderPanelContentWrapper(),this._refreshWrapperChildrenOrder(),this._whenPanelContentRefreshed=y(),this._strategy.renderPanelContent(this._whenPanelContentRefreshed),this._strategy.onPanelContentRendered(),W()&&this._whenPanelContentRefreshed.always(()=>{this._strategy.refreshPanelElementSize(this.option("revealMode")==="slide"),this._renderPosition(this.option("opened"),!0,!0),this._removePanelManualPosition()})},_clean(){this._cleanFocusState(),this._removePanelContentWrapper(),this._removeOverlay()},_removePanelContentWrapper(){this._$panelContentWrapper&&this._$panelContentWrapper.remove()},_removeOverlay(){this._overlay&&(this._overlay.dispose(),delete this._overlay,delete this._$panelContentWrapper)},_optionChanged(i){switch(i.name){case"width":this.callBase(i),this._dimensionChanged();break;case"opened":this._renderPosition(this.option("opened")),this._toggleOpenedStateClass(i.value),this._togglePanelContentHiddenClass();break;case"position":this._refreshPositionClass(),this._refreshWrapperChildrenOrder(),this._invalidate();break;case"contentTemplate":case"template":this._invalidate();break;case"openedStateMode":this._initStrategy(),this._refreshOpenedStateModeClass(i.previousValue),this._refreshPanel();break;case"minSize":this._initMinMaxSize(),this._renderPosition(this.option("opened"),!0),this._togglePanelContentHiddenClass();break;case"maxSize":this._initMinMaxSize(),this._renderPosition(this.option("opened"),!0);break;case"revealMode":this._refreshRevealModeClass(i.previousValue),this._refreshPanel();break;case"shading":this._toggleShaderVisibility(this.option("opened"));break;case"animationEnabled":case"animationDuration":case"closeOnOutsideClick":break;default:this.callBase(i)}},content(){return N(this._$panelContentWrapper)},viewContent(){return N(this._$viewContentWrapper)},show(){return this.toggle(!0)},hide(){return this.toggle(!1)},toggle(i){let e=i===void 0?!this.option("opened"):i;return this._whenAnimationCompleted=y(),this.option("opened",e),this._whenAnimationCompleted.promise()}});G("dxDrawer",O7);var S7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[qe,ye,ye]})}return i})();var{getActiveElement:E7}=w;var x1=F.real(),v1=zl.inherit({_supportedKeys(){return m({},this.callBase(),{tab(i){if(!this.option("opened"))return;let e=this._getTabbableElements(),t=i.shiftKey?e.last():e.first();t&&_.trigger(t,"focus"),i.preventDefault()}})},_getTabbableElements(){return this._getElements().filter(Yd)},_getElements(){return u(this.content()).find("*")},_getDefaultOptions(){return m(this.callBase(),{acceptCustomValue:!1,contentTemplate:"content",openOnFieldClick:!0,displayValueFormatter:i=>Array.isArray(i)?i.join(", "):i,useHiddenSubmitElement:!0})},_getAnonymousTemplateName:()=>"content",_initTemplates(){this.callBase()},_initMarkup(){this._initDataExpressions(),this.$element().addClass("dx-dropdownbox"),this.callBase()},_setSubmitValue(){let i=this.option("value"),e=this._shouldUseDisplayValue(i)?this._displayGetter(i):i;this._getSubmitElement().val(e)},_shouldUseDisplayValue(i){return this.option("valueExpr")==="this"&&$(i)},_sortValuesByKeysOrder(i,e){return e.sort((n,o)=>i.indexOf(n.itemKey)-i.indexOf(o.itemKey)).map(n=>n.itemDisplayValue)},_renderInputValue(){let{renderOnly:i}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this._rejectValueLoading();let e=[];if(!this._dataSource)return this.callBase({renderOnly:i,value:e}),y().resolve();let n=this._getCurrentValue()??[];n=Array.isArray(n)?n:[n];let o=He(n,r=>{let a=y();return this._loadItem(r).always(l=>{let d=this._displayGetter(l);f(d)?e.push({itemKey:r,itemDisplayValue:d}):this.option("acceptCustomValue")&&e.push({itemKey:r,itemDisplayValue:r}),a.resolve()}),a}),s=this.callBase.bind(this);return P.apply(this,o).always(()=>{let r=this._sortValuesByKeysOrder(n,e);this.option("displayValue",r),s({renderOnly:i,value:e.length&&r})})},_loadItem(i){let e=y(),t=this,n=xt(this.option("items")||[],o=>this._isValueEquals(this._valueGetter(o),i))[0];return n!==void 0?e.resolve(n):this._loadValue(i).done(o=>{e.resolve(o)}).fail(o=>{o!=null&&o.shouldSkipCallback||(t.option("acceptCustomValue")?e.resolve(i):e.reject())}),e.promise()},_popupTabHandler(i){if(De(i)!=="tab")return;let e=this._getTabbableElements().first().get(0),t=this._getTabbableElements().last().get(0),n=i.target,o=!!(n===e&&i.shiftKey),s=n===t&&!i.shiftKey;(o||s)&&(this.close(),_.trigger(this._input(),"focus"),o&&i.preventDefault())},_renderPopupContent(){if(this.option("contentTemplate")==="content")return;let i=this._getTemplateByOption("contentTemplate");if(!(i&&this.option("contentTemplate")))return;let e=this._popup.$content(),t={value:this._fieldRenderData(),component:this};e.empty(),i.render({container:N(e),model:t})},_canShowVirtualKeyboard:()=>x1.mac,_isNestedElementActive(){let i=E7();return i&&this._popup.$content().get(0).contains(i)},_shouldHideOnParentScroll(){return x1.deviceType==="desktop"&&this._canShowVirtualKeyboard()&&this._isNestedElementActive()},_popupHiddenHandler(){this.callBase(),this._popupPosition=void 0},_popupPositionedHandler(i){this.callBase(i),this._popupPosition=i.position},_getDefaultPopupPosition(i){let{my:e,at:t}=this.callBase(i);return{my:e,at:t,offset:{v:-1},collision:"flipfit"}},_popupConfig(){let{focusStateEnabled:i}=this.option();return m(this.callBase(),{tabIndex:-1,dragEnabled:!1,focusStateEnabled:i,contentTemplate:"content",hideOnParentScroll:this._shouldHideOnParentScroll.bind(this),position:m(this.option("popupPosition"),{of:this.$element()}),_ignoreFunctionValueDeprecation:!0,maxHeight:function(){var e;let t=(e=this._popupPosition)===null||e===void 0?void 0:e.v.location;return xd(this.$element(),t)}.bind(this)})},_popupShownHandler(){this.callBase();let i=this._getTabbableElements().first();_.trigger(i,"focus")},_setCollectionWidgetOption:S,_optionChanged(i){switch(this._dataExpressionOptionChanged(i),i.name){case"dataSource":this._renderInputValue();break;case"displayValue":this.option("text",i.value);break;case"displayExpr":this._renderValue();break;case"contentTemplate":this._invalidate();break;default:this.callBase(i)}}}).include(Pc);G("dxDropDownBox",v1);var b1=v1;var y1=b1;var w7=["*"],I7={provide:Ri,useExisting:Ht(()=>O1),multi:!0},O1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get acceptCustomValue(){return this._getOption("acceptCustomValue")}set acceptCustomValue(t){this._setOption("acceptCustomValue",t)}get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get buttons(){return this._getOption("buttons")}set buttons(t){this._setOption("buttons",t)}get contentTemplate(){return this._getOption("contentTemplate")}set contentTemplate(t){this._setOption("contentTemplate",t)}get dataSource(){return this._getOption("dataSource")}set dataSource(t){this._setOption("dataSource",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get displayExpr(){return this._getOption("displayExpr")}set displayExpr(t){this._setOption("displayExpr",t)}get displayValueFormatter(){return this._getOption("displayValueFormatter")}set displayValueFormatter(t){this._setOption("displayValueFormatter",t)}get dropDownButtonTemplate(){return this._getOption("dropDownButtonTemplate")}set dropDownButtonTemplate(t){this._setOption("dropDownButtonTemplate",t)}get dropDownOptions(){return this._getOption("dropDownOptions")}set dropDownOptions(t){this._setOption("dropDownOptions",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get fieldTemplate(){return this._getOption("fieldTemplate")}set fieldTemplate(t){this._setOption("fieldTemplate",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get inputAttr(){return this._getOption("inputAttr")}set inputAttr(t){this._setOption("inputAttr",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get labelMode(){return this._getOption("labelMode")}set labelMode(t){this._setOption("labelMode",t)}get maxLength(){return this._getOption("maxLength")}set maxLength(t){this._setOption("maxLength",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get opened(){return this._getOption("opened")}set opened(t){this._setOption("opened",t)}get openOnFieldClick(){return this._getOption("openOnFieldClick")}set openOnFieldClick(t){this._setOption("openOnFieldClick",t)}get placeholder(){return this._getOption("placeholder")}set placeholder(t){this._setOption("placeholder",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get showClearButton(){return this._getOption("showClearButton")}set showClearButton(t){this._setOption("showClearButton",t)}get showDropDownButton(){return this._getOption("showDropDownButton")}set showDropDownButton(t){this._setOption("showDropDownButton",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get valueChangeEvent(){return this._getOption("valueChangeEvent")}set valueChangeEvent(t){this._setOption("valueChangeEvent",t)}get valueExpr(){return this._getOption("valueExpr")}set valueExpr(t){this._setOption("valueExpr",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onChange;onClosed;onCopy;onCut;onDisposing;onEnterKey;onFocusIn;onFocusOut;onInitialized;onInput;onKeyDown;onKeyUp;onOpened;onOptionChanged;onPaste;onValueChanged;acceptCustomValueChange;accessKeyChange;activeStateEnabledChange;buttonsChange;contentTemplateChange;dataSourceChange;deferRenderingChange;disabledChange;displayExprChange;displayValueFormatterChange;dropDownButtonTemplateChange;dropDownOptionsChange;elementAttrChange;fieldTemplateChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;inputAttrChange;isDirtyChange;isValidChange;itemsChange;labelChange;labelModeChange;maxLengthChange;nameChange;openedChange;openOnFieldClickChange;placeholderChange;readOnlyChange;rtlEnabledChange;showClearButtonChange;showDropDownButtonChange;stylingModeChange;tabIndexChange;textChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;valueChangeEventChange;valueExprChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};get buttonsChildren(){return this._getOption("buttons")}set buttonsChildren(t){this.setChildren("buttons",t)}get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"change",emit:"onChange"},{subscribe:"closed",emit:"onClosed"},{subscribe:"copy",emit:"onCopy"},{subscribe:"cut",emit:"onCut"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"enterKey",emit:"onEnterKey"},{subscribe:"focusIn",emit:"onFocusIn"},{subscribe:"focusOut",emit:"onFocusOut"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"input",emit:"onInput"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"keyUp",emit:"onKeyUp"},{subscribe:"opened",emit:"onOpened"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"paste",emit:"onPaste"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"acceptCustomValueChange"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"buttonsChange"},{emit:"contentTemplateChange"},{emit:"dataSourceChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"displayExprChange"},{emit:"displayValueFormatterChange"},{emit:"dropDownButtonTemplateChange"},{emit:"dropDownOptionsChange"},{emit:"elementAttrChange"},{emit:"fieldTemplateChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"inputAttrChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"itemsChange"},{emit:"labelChange"},{emit:"labelModeChange"},{emit:"maxLengthChange"},{emit:"nameChange"},{emit:"openedChange"},{emit:"openOnFieldClickChange"},{emit:"placeholderChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"showClearButtonChange"},{emit:"showDropDownButtonChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"textChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"valueChangeEventChange"},{emit:"valueExprChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new y1(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("buttons",t),this.setupChanges("dataSource",t),this.setupChanges("items",t),this.setupChanges("validationErrors",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("buttons"),this._idh.doCheck("dataSource"),this._idh.doCheck("items"),this._idh.doCheck("validationErrors"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-drop-down-box"]],contentQueries:function(n,o,s){if(n&1&&(ke(s,_o,4),ke(s,qn,4)),n&2){let r;Be(r=Ve())&&(o.buttonsChildren=r),Be(r=Ve())&&(o.itemsChildren=r)}},hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{acceptCustomValue:"acceptCustomValue",accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",buttons:"buttons",contentTemplate:"contentTemplate",dataSource:"dataSource",deferRendering:"deferRendering",disabled:"disabled",displayExpr:"displayExpr",displayValueFormatter:"displayValueFormatter",dropDownButtonTemplate:"dropDownButtonTemplate",dropDownOptions:"dropDownOptions",elementAttr:"elementAttr",fieldTemplate:"fieldTemplate",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",inputAttr:"inputAttr",isDirty:"isDirty",isValid:"isValid",items:"items",label:"label",labelMode:"labelMode",maxLength:"maxLength",name:"name",opened:"opened",openOnFieldClick:"openOnFieldClick",placeholder:"placeholder",readOnly:"readOnly",rtlEnabled:"rtlEnabled",showClearButton:"showClearButton",showDropDownButton:"showDropDownButton",stylingMode:"stylingMode",tabIndex:"tabIndex",text:"text",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",valueChangeEvent:"valueChangeEvent",valueExpr:"valueExpr",visible:"visible",width:"width"},outputs:{onChange:"onChange",onClosed:"onClosed",onCopy:"onCopy",onCut:"onCut",onDisposing:"onDisposing",onEnterKey:"onEnterKey",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onInitialized:"onInitialized",onInput:"onInput",onKeyDown:"onKeyDown",onKeyUp:"onKeyUp",onOpened:"onOpened",onOptionChanged:"onOptionChanged",onPaste:"onPaste",onValueChanged:"onValueChanged",acceptCustomValueChange:"acceptCustomValueChange",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",buttonsChange:"buttonsChange",contentTemplateChange:"contentTemplateChange",dataSourceChange:"dataSourceChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",displayExprChange:"displayExprChange",displayValueFormatterChange:"displayValueFormatterChange",dropDownButtonTemplateChange:"dropDownButtonTemplateChange",dropDownOptionsChange:"dropDownOptionsChange",elementAttrChange:"elementAttrChange",fieldTemplateChange:"fieldTemplateChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",inputAttrChange:"inputAttrChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",itemsChange:"itemsChange",labelChange:"labelChange",labelModeChange:"labelModeChange",maxLengthChange:"maxLengthChange",nameChange:"nameChange",openedChange:"openedChange",openOnFieldClickChange:"openOnFieldClickChange",placeholderChange:"placeholderChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",showClearButtonChange:"showClearButtonChange",showDropDownButtonChange:"showDropDownButtonChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",textChange:"textChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",valueChangeEventChange:"valueChangeEventChange",valueExprChange:"valueExprChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,I7,k,Se]),J,Ze],ngContentSelectors:w7,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},encapsulation:2})}return i})(),D7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[ei,Mi,ys,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,Ti,qe,ye,ei,Mi,ys,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,Ti,ye]})}return i})();var T7="dx-gallery-item-image";var S1=Xe.inherit({_supportedKeys(){return m(this.callBase(),{pageUp:S,pageDown:S})},_getDefaultOptions(){return m(this.callBase(),{direction:"next",onClick:null,hoverStateEnabled:!0,activeStateEnabled:!0})},_render(){this.callBase();let i=this,e=this.$element(),t=D(oe,this.NAME);e.addClass(`dx-gallery-nav-button-${this.option("direction")}`),_.off(e,t),_.on(e,t,n=>{i._createActionByOption("onClick")({event:n})})},_optionChanged(i){switch(i.name){case"onClick":case"direction":this._invalidate();break;default:this.callBase(i)}}}),E1=In.inherit({_activeStateUnit:".dx-gallery-item",_wasAnyItemTemplateRendered:!1,_getDefaultOptions(){return m(this.callBase(),{activeStateEnabled:!1,animationDuration:400,animationEnabled:!0,loop:!1,swipeEnabled:!0,indicatorEnabled:!0,showIndicator:!0,selectedIndex:0,slideshowDelay:0,showNavButtons:!1,wrapAround:!1,initialItemWidth:void 0,stretchImages:!1,_itemAttributes:{role:"option","aria-label":O.format("dxGallery-itemName")},loopItemFocus:!1,selectOnFocus:!0,selectionMode:"single",selectionRequired:!0,selectByClick:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}}])},_init(){this.callBase(),this.option("loopItemFocus",this.option("loop"))},_initTemplates(){this.callBase(),this._templateManager.addDefaultTemplates({item:new di((i,e)=>{let t=u("<img>").addClass(T7);q(e)?(this._prepareDefaultItemTemplate(e,i),t.attr({src:e.imageSrc,alt:e.imageAlt}).appendTo(i)):t.attr("src",String(e)).appendTo(i)},["imageSrc","imageAlt","text","html"],this.option("integrationOptions.watchMethod"))})},_dataSourceOptions:()=>({paginate:!1}),_itemContainer(){return this._$container},_itemClass:()=>"dx-gallery-item",_itemDataKey:()=>"dxGalleryItemData",_actualItemWidth(){let i=this.option("wrapAround");return this.option("stretchImages")?1/(i?this._itemsPerPage()+1:this._itemsPerPage()):i?this._itemPercentWidth()*this._itemsPerPage()/(this._itemsPerPage()+1):this._itemPercentWidth()},_itemPercentWidth(){let i,e=ie(this.$element()),t=this.option("initialItemWidth");return t&&t<=e?i=t/e:i=1,i},_itemsPerPage(){let i=W()?Math.floor(1/this._itemPercentWidth()):1;return Math.min(i,this._itemsCount())},_pagesCount(){return Math.ceil(this._itemsCount()/this._itemsPerPage())},_itemsCount(){return(this.option("items")||[]).length},_offsetDirection(){return this.option("rtlEnabled")?-1:1},_initMarkup(){this._renderWrapper(),this._renderItemsContainer(),this.$element().addClass("dx-gallery"),this.$element().toggleClass("dx-gallery-loop",this.option("loop")),this.callBase();let e={role:this._itemsCount()>0?"listbox":void 0,label:"gallery"};this.setAria(e)},_render(){this._renderDragHandler(),this._renderContainerPosition(),this._renderItemSizes(),this._renderItemPositions(),this._renderNavButtons(),this._renderIndicator(),this._renderSelectedItem(),this._renderItemVisibility(),this._renderUserInteraction(),this._setupSlideShow(),this._reviseDimensions(),this.callBase()},_dimensionChanged(){let i=this.option("selectedIndex")||0;this._stopItemAnimations(),this._clearCacheWidth(),this._cloneDuplicateItems(),this._renderItemSizes(),this._renderItemPositions(),this._renderIndicator(),this._renderContainerPosition(this._calculateIndexOffset(i),!0),this._renderItemVisibility()},_renderDragHandler(){let i=D("dragstart",this.NAME);_.off(this.$element(),i),_.on(this.$element(),i,"img",()=>!1)},_renderWrapper(){this._$wrapper||(this._$wrapper=u("<div>").addClass("dx-gallery-wrapper").appendTo(this.$element()))},_renderItems(i){if(!W()){let e=this.option("selectedIndex");i=i.length>e?i.slice(e,e+1):i.slice(0,1)}this.callBase(i),this._loadNextPageIfNeeded()},_onItemTemplateRendered(){return()=>{this._wasAnyItemTemplateRendered||(this._wasAnyItemTemplateRendered=!0,bi(this.$element()))}},_renderItemsContainer(){this._$container||(this._$container=u("<div>").addClass("dx-gallery-container").appendTo(this._$wrapper))},_cloneDuplicateItems(){if(!this.option("loop"))return;let e=(this.option("items")||[]).length,t=e-1,n;if(!e)return;this._getLoopedItems().remove();let o=Math.min(this._itemsPerPage(),e),s=this._getRealItems(),r=this._itemContainer();for(n=0;n<o;n++)this._cloneItemForDuplicate(s[n],r);for(n=0;n<o;n++)this._cloneItemForDuplicate(s[t-n],r)},_cloneItemForDuplicate(i,e){if(i){let t=u(i).clone(!1).addClass("dx-gallery-item-loop").removeAttr("id").css("margin",0).appendTo(e);this.setAria({hidden:!0},t)}},_getRealItems(){return this.$element().find(".dx-gallery-item:not(.dx-gallery-item-loop)")},_getLoopedItems(){return this.$element().find(".dx-gallery-item-loop")},_emptyMessageContainer(){return this._$wrapper},_renderItemSizes(i){let e=this._itemElements(),t=this._actualItemWidth();i!==void 0&&(e=e.slice(i)),e.each(n=>{Wd(u(e[n]),100*t+"%")})},_renderItemPositions(){let i=this._actualItemWidth(),e=this._itemsCount(),t=this._itemsPerPage(),n=this.$element().find(".dx-gallery-item-loop").length,o=e+n-1,s=this.option("wrapAround")?.5:0,r=this._itemFreeSpace(),a=!!r,l=this.option("rtlEnabled"),d=this.option("selectedIndex"),c=l?"Right":"Left";this._itemElements().each(function(h){let p=h,g=u(this).hasClass("dx-gallery-item-loop");if(h>e+t-1&&(p=o-p-t),!g&&p!==0){a&&u(this).css(`margin${c}`,100*r+"%");return}let C=i*(p+s)+r*(p+1-s),v=g?c.toLowerCase():`margin${c}`;u(this).css(v,100*C+"%")}),this._relocateItems(d,d,!0)},_itemFreeSpace(){let i=this._itemsPerPage();return this.option("wrapAround")&&(i+=1),(1-this._actualItemWidth()*i)/(i+1)},_renderContainerPosition(i,e,t){this._releaseInvisibleItems(),i=i||0;let n=this,o=this._actualItemWidth(),s=i,r=this._offsetDirection()*s*(o+this._itemFreeSpace()),a;return f(this._animationOverride)&&(t=this._animationOverride,delete this._animationOverride),t?(n._startSwipe(),a=n._animate(r).done(n._endSwipe.bind(n))):(Ae(this._$container,{left:r*this._elementWidth(),top:0}),a=y().resolveWith(n)),a.done(function(){this._deferredAnimate&&n._deferredAnimate.resolveWith(n),e&&this._renderItemVisibility()}),a.promise()},_startSwipe(){this.$element().addClass("dx-gallery-active")},_endSwipe(){this.$element().removeClass("dx-gallery-active")},_animate(i,e){let t=this,n=this._$container,o=y();return pe.animate(this._$container,m({type:"slide",to:{left:i*this._elementWidth()},duration:t.option("animationDuration"),complete(){t._needMoveContainerForward()&&Ae(n,{left:0,top:0}),t._needMoveContainerBack()&&Ae(n,{left:t._maxContainerOffset()*t._elementWidth(),top:0}),o.resolveWith(t)}},e||{})),o},_needMoveContainerForward(){let i=this._$container.position().left*this._offsetDirection(),e=-this._maxItemWidth()*this._elementWidth()*this._itemsCount();return i<=e+1},_needMoveContainerBack(){let i=this._$container.position().left*this._offsetDirection(),e=this._actualItemWidth()*this._elementWidth();return i>=e-1},_maxContainerOffset(){return-this._maxItemWidth()*(this._itemsCount()-this._itemsPerPage())*this._offsetDirection()},_maxItemWidth(){return this._actualItemWidth()+this._itemFreeSpace()},_reviseDimensions(){let i=this,e=i._itemElements().first().find(".dx-item-content");!e||e.is(":hidden")||(i.option("height")||i.option("height",X(e)),i.option("width")||i.option("width",ie(e)),this._dimensionChanged())},_renderIndicator(){let{showIndicator:i}=this.option();if(this._cleanIndicators(),this.$element().toggleClass("dx-gallery-indicator-visible",i),!i)return;let e=this._$indicator=u("<div>").addClass("dx-gallery-indicator").appendTo(this._$wrapper),t=this.option("indicatorEnabled");for(let n=0;n<this._pagesCount();n++){let o=u("<div>").addClass("dx-gallery-indicator-item").appendTo(e);t&&this._attachIndicatorClickHandler(o,n)}this._renderSelectedPageIndicator()},_attachIndicatorClickHandler(i,e){_.on(i,D(oe,this.NAME),t=>{this._indicatorSelectHandler(t,e)})},_detachIndicatorClickHandler(i){_.off(i,D(oe,this.NAME))},_toggleIndicatorInteraction(i){var e;let t=((e=this._$indicator)===null||e===void 0?void 0:e.find(".dx-gallery-indicator-item"))||[];t.length&&t.each((n,o)=>{i?this._attachIndicatorClickHandler(u(o),n):this._detachIndicatorClickHandler(u(o))})},_cleanIndicators(){this._$indicator&&this._$indicator.remove()},_renderSelectedItem(){let i=this.option("selectedIndex");this._itemElements().removeClass("dx-gallery-item-selected").eq(i).addClass("dx-gallery-item-selected")},_renderItemVisibility(){if(this.option("initialItemWidth")||this.option("wrapAround")){this._releaseInvisibleItems();return}let i=this.option("selectedIndex");this._itemElements().each((e,t)=>{i!==e&&u(t).find(".dx-item-content").addClass("dx-gallery-item-invisible")})},_releaseInvisibleItems(){this._itemElements().find(".dx-item-content").removeClass("dx-gallery-item-invisible")},_renderSelectedPageIndicator(){if(!this._$indicator)return;let i=this.option("selectedIndex"),e=this._pagesCount()-1,t=Math.ceil(i/this._itemsPerPage());t=Math.min(e,t),this._$indicator.find(".dx-gallery-indicator-item").removeClass("dx-gallery-indicator-item-selected").eq(t).addClass("dx-gallery-indicator-item-selected")},_renderUserInteraction(){let i=this.$element(),e=this.option("swipeEnabled")&&this._itemsCount()>1;this._createComponent(i,Ns,{disabled:this.option("disabled")||!e,onStart:this._swipeStartHandler.bind(this),onUpdated:this._swipeUpdateHandler.bind(this),onEnd:this._swipeEndHandler.bind(this),itemSizeFunc:this._elementWidth.bind(this)})},_indicatorSelectHandler(i,e){if(!this.option("indicatorEnabled"))return;let t=this._fitPaginatedIndex(e*this._itemsPerPage());this._needLongMove=!0,this.option("selectedIndex",t),this._loadNextPageIfNeeded(t)},_renderNavButtons(){let i=this;if(!i.option("showNavButtons")){i._cleanNavButtons();return}i._prevNavButton=u("<div>").appendTo(this._$wrapper),i._createComponent(i._prevNavButton,S1,{direction:"prev",onClick(){i._prevPage()}}),i._nextNavButton=u("<div>").appendTo(this._$wrapper),i._createComponent(i._nextNavButton,S1,{direction:"next",onClick(){i._nextPage()}}),this._renderNavButtonsVisibility()},_prevPage(){let i=this._itemsPerPage(),e=this.option("selectedIndex")-i;return e===-i&&i===this._itemsCount()?this._relocateItems(e,0):this.goToItem(this._fitPaginatedIndex(e))},_nextPage(){let i=this._itemsPerPage(),e=this.option("selectedIndex")+i;return e===i&&i===this._itemsCount()?this._relocateItems(e,0):this.goToItem(this._fitPaginatedIndex(e)).done(this._loadNextPageIfNeeded)},_loadNextPageIfNeeded(i){i=i===void 0?this.option("selectedIndex"):i,this._dataSource&&this._dataSource.paginate()&&this._shouldLoadNextPage(i)&&!this._isDataSourceLoading()&&!this._isLastPage()&&this._loadNextPage().done(()=>{this._renderIndicator(),this._cloneDuplicateItems(),this._renderItemPositions(),this._renderNavButtonsVisibility(),this._renderItemSizes(i)})},_shouldLoadNextPage(i){let e=this._itemsPerPage();return i+2*e>this.option("items").length},_allowDynamicItemsAppend:()=>!0,_fitPaginatedIndex(i){let e=this._itemsPerPage(),t=i<0?e+i:this._itemsCount()-i;return i>this._itemsCount()-1?(i=0,this._goToGhostItem=!0):t<e&&t>0&&(i>0?i-=e-t:i+=e-t),i},_cleanNavButtons(){this._prevNavButton&&(this._prevNavButton.remove(),delete this._prevNavButton),this._nextNavButton&&(this._nextNavButton.remove(),delete this._nextNavButton)},_renderNavButtonsVisibility(){if(!this.option("showNavButtons")||!this._prevNavButton||!this._nextNavButton)return;let i=this.option("selectedIndex"),e=this.option("loop"),t=this._itemsCount();if(this._prevNavButton.show(),this._nextNavButton.show(),t===0&&(this._prevNavButton.hide(),this._nextNavButton.hide()),e)return;let n=i===t-this._itemsPerPage(),o=t<2||i===0;this._dataSource&&this._dataSource.paginate()?n=n&&this._isLastPage():n=n||t<2,o&&this._prevNavButton.hide(),n&&this._nextNavButton.hide()},_setupSlideShow(){let i=this,e=i.option("slideshowDelay");clearTimeout(i._slideshowTimer),e&&(i._slideshowTimer=setTimeout(()=>{if(i._userInteraction){i._setupSlideShow();return}i.nextItem(!0).done(i._setupSlideShow)},e))},_elementWidth(){return this._cacheElementWidth||(this._cacheElementWidth=z(this.$element())),this._cacheElementWidth},_clearCacheWidth(){delete this._cacheElementWidth},_swipeStartHandler(i){this._releaseInvisibleItems(),this._clearCacheWidth(),this._elementWidth();let e=this._itemsCount();if(!e){i.event.cancel=!0;return}if(this._stopItemAnimations(),this._startSwipe(),this._userInteraction=!0,!this.option("loop")){let t=this.option("selectedIndex"),n=e-t-this._itemsPerPage(),o=t,s=this.option("rtlEnabled");i.event.maxLeftOffset=s?o:n,i.event.maxRightOffset=s?n:o}},_stopItemAnimations(){pe.stop(this._$container,!0)},_swipeUpdateHandler(i){let e=this.option("wrapAround")?1:0,t=this._offsetDirection()*i.event.offset*(this._itemsPerPage()+e)-this.option("selectedIndex");t<0&&this._loadNextPageIfNeeded(Math.ceil(Math.abs(t))),this._renderContainerPosition(t)},_swipeEndHandler(i){let e=i.event.targetOffset*this._offsetDirection()*this._itemsPerPage(),t=this.option("selectedIndex"),n=this._fitIndex(t-e),o=this._fitPaginatedIndex(n);if(Math.abs(e)<this._itemsPerPage()){this._relocateItems(t);return}if(this._itemsPerPage()===this._itemsCount()){e>0?this._relocateItems(-e):this._relocateItems(0);return}this.option("selectedIndex",o)},_setFocusOnSelect(){this._userInteraction=!0;let i=this._getRealItems().filter(".dx-gallery-item-selected");this.option("focusedElement",N(i)),this._userInteraction=!1},_flipIndex(i){let e=this._itemsCount();return i%=e,i>(e+1)/2&&(i-=e),i<-(e-1)/2&&(i+=e),i},_fitIndex(i){if(!this.option("loop"))return i;let e=this._itemsCount();return(i>=e||i<0)&&(this._goToGhostItem=!0),i>=e&&(i=e-i),i%=e,i<0&&(i+=e),i},_clean(){this.callBase(),this._cleanIndicators(),this._cleanNavButtons()},_dispose(){this._wasAnyItemTemplateRendered=null,clearTimeout(this._slideshowTimer),this.callBase()},_updateSelection(i,e){this._stopItemAnimations(),this._renderNavButtonsVisibility(),this._renderSelectedItem(),this._relocateItems(i[0],e[0]),this._renderSelectedPageIndicator()},_relocateItems(i,e,t){e===void 0&&(e=i);let n=this._calculateIndexOffset(i,e);this._renderContainerPosition(n,!0,this.option("animationEnabled")&&!t).done(function(){this._setFocusOnSelect(),this._userInteraction=!1,this._setupSlideShow()})},_focusInHandler(){pe.isAnimating(this._$container)||this._userInteraction||this.callBase.apply(this,arguments)},_focusOutHandler(){pe.isAnimating(this._$container)||this._userInteraction||this.callBase.apply(this,arguments)},_selectFocusedItem:S,_moveFocus(){this._stopItemAnimations(),this.callBase.apply(this,arguments);let i=this.itemElements().index(u(this.option("focusedElement")));this.goToItem(i,this.option("animationEnabled"))},_visibilityChanged(i){i&&this._reviseDimensions()},_calculateIndexOffset(i,e){e===void 0&&(e=i);let t=e-i;return this.option("loop")&&!this._needLongMove&&this._goToGhostItem&&(this._isItemOnFirstPage(i)&&this._isItemOnLastPage(e)?t=-this._itemsPerPage():this._isItemOnLastPage(i)&&this._isItemOnFirstPage(e)&&(t=this._itemsPerPage()),this._goToGhostItem=!1),this._needLongMove=!1,t-=e,t},_isItemOnLastPage(i){return i>=this._itemsCount()-this._itemsPerPage()},_isItemOnFirstPage(i){return i<=this._itemsPerPage()},_optionChanged(i){switch(i.name){case"width":case"initialItemWidth":this.callBase.apply(this,arguments),this._dimensionChanged();break;case"animationDuration":this._renderNavButtonsVisibility();break;case"animationEnabled":break;case"loop":this.$element().toggleClass("dx-gallery-loop",i.value),this.option("loopItemFocus",i.value),W()&&(this._cloneDuplicateItems(),this._renderItemPositions(),this._renderNavButtonsVisibility());break;case"showIndicator":this._renderIndicator();break;case"showNavButtons":this._renderNavButtons();break;case"slideshowDelay":this._setupSlideShow();break;case"wrapAround":case"stretchImages":W()&&(this._renderItemSizes(),this._renderItemPositions(),this._renderItemVisibility());break;case"swipeEnabled":this._renderUserInteraction();break;case"indicatorEnabled":this._toggleIndicatorInteraction(i.value);break;default:this.callBase(i)}},goToItem(i,e){let t=this.option("selectedIndex"),n=this._itemsCount();return e!==void 0&&(this._animationOverride=e),i=this._fitIndex(i),this._deferredAnimate=y(),i>n-1||i<0||t===i?this._deferredAnimate.resolveWith(this).promise():(this.option("selectedIndex",i),this._deferredAnimate.promise())},prevItem(i){return this.goToItem(this.option("selectedIndex")-1,i)},nextItem(i){return this.goToItem(this.option("selectedIndex")+1,i)}});G("dxGallery",E1);var w1=E1;var I1=w1;var A7=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get animationDuration(){return this._getOption("animationDuration")}set animationDuration(t){this._setOption("animationDuration",t)}get animationEnabled(){return this._getOption("animationEnabled")}set animationEnabled(t){this._setOption("animationEnabled",t)}get dataSource(){return this._getOption("dataSource")}set dataSource(t){this._setOption("dataSource",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get indicatorEnabled(){return this._getOption("indicatorEnabled")}set indicatorEnabled(t){this._setOption("indicatorEnabled",t)}get initialItemWidth(){return this._getOption("initialItemWidth")}set initialItemWidth(t){this._setOption("initialItemWidth",t)}get itemHoldTimeout(){return this._getOption("itemHoldTimeout")}set itemHoldTimeout(t){this._setOption("itemHoldTimeout",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get itemTemplate(){return this._getOption("itemTemplate")}set itemTemplate(t){this._setOption("itemTemplate",t)}get loop(){return this._getOption("loop")}set loop(t){this._setOption("loop",t)}get noDataText(){return this._getOption("noDataText")}set noDataText(t){this._setOption("noDataText",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get selectedIndex(){return this._getOption("selectedIndex")}set selectedIndex(t){this._setOption("selectedIndex",t)}get selectedItem(){return this._getOption("selectedItem")}set selectedItem(t){this._setOption("selectedItem",t)}get showIndicator(){return this._getOption("showIndicator")}set showIndicator(t){this._setOption("showIndicator",t)}get showNavButtons(){return this._getOption("showNavButtons")}set showNavButtons(t){this._setOption("showNavButtons",t)}get slideshowDelay(){return this._getOption("slideshowDelay")}set slideshowDelay(t){this._setOption("slideshowDelay",t)}get stretchImages(){return this._getOption("stretchImages")}set stretchImages(t){this._setOption("stretchImages",t)}get swipeEnabled(){return this._getOption("swipeEnabled")}set swipeEnabled(t){this._setOption("swipeEnabled",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get wrapAround(){return this._getOption("wrapAround")}set wrapAround(t){this._setOption("wrapAround",t)}onContentReady;onDisposing;onInitialized;onItemClick;onItemContextMenu;onItemHold;onItemRendered;onOptionChanged;onSelectionChanged;accessKeyChange;animationDurationChange;animationEnabledChange;dataSourceChange;disabledChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;indicatorEnabledChange;initialItemWidthChange;itemHoldTimeoutChange;itemsChange;itemTemplateChange;loopChange;noDataTextChange;rtlEnabledChange;selectedIndexChange;selectedItemChange;showIndicatorChange;showNavButtonsChange;slideshowDelayChange;stretchImagesChange;swipeEnabledChange;tabIndexChange;visibleChange;widthChange;wrapAroundChange;get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"itemClick",emit:"onItemClick"},{subscribe:"itemContextMenu",emit:"onItemContextMenu"},{subscribe:"itemHold",emit:"onItemHold"},{subscribe:"itemRendered",emit:"onItemRendered"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"selectionChanged",emit:"onSelectionChanged"},{emit:"accessKeyChange"},{emit:"animationDurationChange"},{emit:"animationEnabledChange"},{emit:"dataSourceChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"indicatorEnabledChange"},{emit:"initialItemWidthChange"},{emit:"itemHoldTimeoutChange"},{emit:"itemsChange"},{emit:"itemTemplateChange"},{emit:"loopChange"},{emit:"noDataTextChange"},{emit:"rtlEnabledChange"},{emit:"selectedIndexChange"},{emit:"selectedItemChange"},{emit:"showIndicatorChange"},{emit:"showNavButtonsChange"},{emit:"slideshowDelayChange"},{emit:"stretchImagesChange"},{emit:"swipeEnabledChange"},{emit:"tabIndexChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"wrapAroundChange"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new I1(t,n)}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("dataSource",t),this.setupChanges("items",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("dataSource"),this._idh.doCheck("items"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-gallery"]],contentQueries:function(n,o,s){if(n&1&&ke(s,qn,4),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r)}},inputs:{accessKey:"accessKey",animationDuration:"animationDuration",animationEnabled:"animationEnabled",dataSource:"dataSource",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",indicatorEnabled:"indicatorEnabled",initialItemWidth:"initialItemWidth",itemHoldTimeout:"itemHoldTimeout",items:"items",itemTemplate:"itemTemplate",loop:"loop",noDataText:"noDataText",rtlEnabled:"rtlEnabled",selectedIndex:"selectedIndex",selectedItem:"selectedItem",showIndicator:"showIndicator",showNavButtons:"showNavButtons",slideshowDelay:"slideshowDelay",stretchImages:"stretchImages",swipeEnabled:"swipeEnabled",tabIndex:"tabIndex",visible:"visible",width:"width",wrapAround:"wrapAround"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onInitialized:"onInitialized",onItemClick:"onItemClick",onItemContextMenu:"onItemContextMenu",onItemHold:"onItemHold",onItemRendered:"onItemRendered",onOptionChanged:"onOptionChanged",onSelectionChanged:"onSelectionChanged",accessKeyChange:"accessKeyChange",animationDurationChange:"animationDurationChange",animationEnabledChange:"animationEnabledChange",dataSourceChange:"dataSourceChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",indicatorEnabledChange:"indicatorEnabledChange",initialItemWidthChange:"initialItemWidthChange",itemHoldTimeoutChange:"itemHoldTimeoutChange",itemsChange:"itemsChange",itemTemplateChange:"itemTemplateChange",loopChange:"loopChange",noDataTextChange:"noDataTextChange",rtlEnabledChange:"rtlEnabledChange",selectedIndexChange:"selectedIndexChange",selectedItemChange:"selectedItemChange",showIndicatorChange:"showIndicatorChange",showNavButtonsChange:"showNavButtonsChange",slideshowDelayChange:"slideshowDelayChange",stretchImagesChange:"stretchImagesChange",swipeEnabledChange:"swipeEnabledChange",tabIndexChange:"tabIndexChange",visibleChange:"visibleChange",widthChange:"widthChange",wrapAroundChange:"wrapAroundChange"},standalone:!1,features:[le([ee,ae,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),M7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Ti,qe,ye,Ti,ye]})}return i})();var tE=function(i,e,t){let n=u(i),o=t?n.scrollLeft():n.scrollTop(),s=t?"Width":"Height",r=n.prop(`scroll${s}`),a=n.prop(`client${s}`),l=r-a-o|0;if(o===0&&l===0)return!1;let d=o===0&&e>=0,c=l===0&&e<=0,h=o>0&&l>0;if(d||c||h)return!0},D1=function(i,e){let t=u(i);return{validate(n){if(Ut(n)&&(o=n.target,e?u(o).is(i):!0))return tE(t,-n.delta,n.shiftKey)?(n._needSkipEvent=!0,!0):!1;var o}}};var iE=(()=>{class i extends ii{_getDefaultOptions(){return m(super._getDefaultOptions(),{preventScrollEvents:!1})}_getToolbarName(){return"dxToolbar"}}return i.defaultOptions=function(e){ii.defaultOptions(e)},i})();G("dxPopup",iE);var T1=iE;var A1=T1;var R7={provide:Ri,useExisting:Ht(()=>M1),multi:!0},M1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get buttons(){return this._getOption("buttons")}set buttons(t){this._setOption("buttons",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get format(){return this._getOption("format")}set format(t){this._setOption("format",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get inputAttr(){return this._getOption("inputAttr")}set inputAttr(t){this._setOption("inputAttr",t)}get invalidValueMessage(){return this._getOption("invalidValueMessage")}set invalidValueMessage(t){this._setOption("invalidValueMessage",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get labelMode(){return this._getOption("labelMode")}set labelMode(t){this._setOption("labelMode",t)}get max(){return this._getOption("max")}set max(t){this._setOption("max",t)}get min(){return this._getOption("min")}set min(t){this._setOption("min",t)}get mode(){return this._getOption("mode")}set mode(t){this._setOption("mode",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get placeholder(){return this._getOption("placeholder")}set placeholder(t){this._setOption("placeholder",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get showClearButton(){return this._getOption("showClearButton")}set showClearButton(t){this._setOption("showClearButton",t)}get showSpinButtons(){return this._getOption("showSpinButtons")}set showSpinButtons(t){this._setOption("showSpinButtons",t)}get step(){return this._getOption("step")}set step(t){this._setOption("step",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get useLargeSpinButtons(){return this._getOption("useLargeSpinButtons")}set useLargeSpinButtons(t){this._setOption("useLargeSpinButtons",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get valueChangeEvent(){return this._getOption("valueChangeEvent")}set valueChangeEvent(t){this._setOption("valueChangeEvent",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onChange;onContentReady;onCopy;onCut;onDisposing;onEnterKey;onFocusIn;onFocusOut;onInitialized;onInput;onKeyDown;onKeyUp;onOptionChanged;onPaste;onValueChanged;accessKeyChange;activeStateEnabledChange;buttonsChange;disabledChange;elementAttrChange;focusStateEnabledChange;formatChange;heightChange;hintChange;hoverStateEnabledChange;inputAttrChange;invalidValueMessageChange;isDirtyChange;isValidChange;labelChange;labelModeChange;maxChange;minChange;modeChange;nameChange;placeholderChange;readOnlyChange;rtlEnabledChange;showClearButtonChange;showSpinButtonsChange;stepChange;stylingModeChange;tabIndexChange;textChange;useLargeSpinButtonsChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;valueChangeEventChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};get buttonsChildren(){return this._getOption("buttons")}set buttonsChildren(t){this.setChildren("buttons",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"change",emit:"onChange"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"copy",emit:"onCopy"},{subscribe:"cut",emit:"onCut"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"enterKey",emit:"onEnterKey"},{subscribe:"focusIn",emit:"onFocusIn"},{subscribe:"focusOut",emit:"onFocusOut"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"input",emit:"onInput"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"keyUp",emit:"onKeyUp"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"paste",emit:"onPaste"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"buttonsChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"formatChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"inputAttrChange"},{emit:"invalidValueMessageChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"labelChange"},{emit:"labelModeChange"},{emit:"maxChange"},{emit:"minChange"},{emit:"modeChange"},{emit:"nameChange"},{emit:"placeholderChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"showClearButtonChange"},{emit:"showSpinButtonsChange"},{emit:"stepChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"textChange"},{emit:"useLargeSpinButtonsChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"valueChangeEventChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new ya(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("buttons",t),this.setupChanges("validationErrors",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("buttons"),this._idh.doCheck("validationErrors"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-number-box"]],contentQueries:function(n,o,s){if(n&1&&ke(s,_o,4),n&2){let r;Be(r=Ve())&&(o.buttonsChildren=r)}},hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",buttons:"buttons",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",format:"format",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",inputAttr:"inputAttr",invalidValueMessage:"invalidValueMessage",isDirty:"isDirty",isValid:"isValid",label:"label",labelMode:"labelMode",max:"max",min:"min",mode:"mode",name:"name",placeholder:"placeholder",readOnly:"readOnly",rtlEnabled:"rtlEnabled",showClearButton:"showClearButton",showSpinButtons:"showSpinButtons",step:"step",stylingMode:"stylingMode",tabIndex:"tabIndex",text:"text",useLargeSpinButtons:"useLargeSpinButtons",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",valueChangeEvent:"valueChangeEvent",visible:"visible",width:"width"},outputs:{onChange:"onChange",onContentReady:"onContentReady",onCopy:"onCopy",onCut:"onCut",onDisposing:"onDisposing",onEnterKey:"onEnterKey",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onInitialized:"onInitialized",onInput:"onInput",onKeyDown:"onKeyDown",onKeyUp:"onKeyUp",onOptionChanged:"onOptionChanged",onPaste:"onPaste",onValueChanged:"onValueChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",buttonsChange:"buttonsChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",formatChange:"formatChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",inputAttrChange:"inputAttrChange",invalidValueMessageChange:"invalidValueMessageChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",labelChange:"labelChange",labelModeChange:"labelModeChange",maxChange:"maxChange",minChange:"minChange",modeChange:"modeChange",nameChange:"nameChange",placeholderChange:"placeholderChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",showClearButtonChange:"showClearButtonChange",showSpinButtonsChange:"showSpinButtonsChange",stepChange:"stepChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",textChange:"textChange",useLargeSpinButtonsChange:"useLargeSpinButtonsChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",valueChangeEventChange:"valueChangeEventChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,R7,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),F7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[ei,Mi,_l,qe,ye,ei,Mi,_l,ye]})}return i})();var nE=(()=>{class i extends Fc{_getDefaultOptions(){return m(super._getDefaultOptions(),{preventScrollEvents:!1})}_getToolbarName(){return"dxToolbar"}}return i.defaultOptions=function(e){Fc.defaultOptions(e)},i})();G("dxPopover",nE);var R1=nE;var F1=R1;var P7=["*"],k7=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get animation(){return this._getOption("animation")}set animation(t){this._setOption("animation",t)}get closeOnOutsideClick(){return this._getOption("closeOnOutsideClick")}set closeOnOutsideClick(t){this._setOption("closeOnOutsideClick",t)}get container(){return this._getOption("container")}set container(t){this._setOption("container",t)}get contentTemplate(){return this._getOption("contentTemplate")}set contentTemplate(t){this._setOption("contentTemplate",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get enableBodyScroll(){return this._getOption("enableBodyScroll")}set enableBodyScroll(t){this._setOption("enableBodyScroll",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hideEvent(){return this._getOption("hideEvent")}set hideEvent(t){this._setOption("hideEvent",t)}get hideOnOutsideClick(){return this._getOption("hideOnOutsideClick")}set hideOnOutsideClick(t){this._setOption("hideOnOutsideClick",t)}get hideOnParentScroll(){return this._getOption("hideOnParentScroll")}set hideOnParentScroll(t){this._setOption("hideOnParentScroll",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get maxHeight(){return this._getOption("maxHeight")}set maxHeight(t){this._setOption("maxHeight",t)}get maxWidth(){return this._getOption("maxWidth")}set maxWidth(t){this._setOption("maxWidth",t)}get minHeight(){return this._getOption("minHeight")}set minHeight(t){this._setOption("minHeight",t)}get minWidth(){return this._getOption("minWidth")}set minWidth(t){this._setOption("minWidth",t)}get position(){return this._getOption("position")}set position(t){this._setOption("position",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get shading(){return this._getOption("shading")}set shading(t){this._setOption("shading",t)}get shadingColor(){return this._getOption("shadingColor")}set shadingColor(t){this._setOption("shadingColor",t)}get showCloseButton(){return this._getOption("showCloseButton")}set showCloseButton(t){this._setOption("showCloseButton",t)}get showEvent(){return this._getOption("showEvent")}set showEvent(t){this._setOption("showEvent",t)}get showTitle(){return this._getOption("showTitle")}set showTitle(t){this._setOption("showTitle",t)}get target(){return this._getOption("target")}set target(t){this._setOption("target",t)}get title(){return this._getOption("title")}set title(t){this._setOption("title",t)}get titleTemplate(){return this._getOption("titleTemplate")}set titleTemplate(t){this._setOption("titleTemplate",t)}get toolbarItems(){return this._getOption("toolbarItems")}set toolbarItems(t){this._setOption("toolbarItems",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get wrapperAttr(){return this._getOption("wrapperAttr")}set wrapperAttr(t){this._setOption("wrapperAttr",t)}onContentReady;onDisposing;onHidden;onHiding;onInitialized;onOptionChanged;onShowing;onShown;onTitleRendered;animationChange;closeOnOutsideClickChange;containerChange;contentTemplateChange;deferRenderingChange;disabledChange;enableBodyScrollChange;heightChange;hideEventChange;hideOnOutsideClickChange;hideOnParentScrollChange;hintChange;hoverStateEnabledChange;maxHeightChange;maxWidthChange;minHeightChange;minWidthChange;positionChange;rtlEnabledChange;shadingChange;shadingColorChange;showCloseButtonChange;showEventChange;showTitleChange;targetChange;titleChange;titleTemplateChange;toolbarItemsChange;visibleChange;widthChange;wrapperAttrChange;get toolbarItemsChildren(){return this._getOption("toolbarItems")}set toolbarItemsChildren(t){this.setChildren("toolbarItems",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"hidden",emit:"onHidden"},{subscribe:"hiding",emit:"onHiding"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"showing",emit:"onShowing"},{subscribe:"shown",emit:"onShown"},{subscribe:"titleRendered",emit:"onTitleRendered"},{emit:"animationChange"},{emit:"closeOnOutsideClickChange"},{emit:"containerChange"},{emit:"contentTemplateChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"enableBodyScrollChange"},{emit:"heightChange"},{emit:"hideEventChange"},{emit:"hideOnOutsideClickChange"},{emit:"hideOnParentScrollChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"maxHeightChange"},{emit:"maxWidthChange"},{emit:"minHeightChange"},{emit:"minWidthChange"},{emit:"positionChange"},{emit:"rtlEnabledChange"},{emit:"shadingChange"},{emit:"shadingColorChange"},{emit:"showCloseButtonChange"},{emit:"showEventChange"},{emit:"showTitleChange"},{emit:"targetChange"},{emit:"titleChange"},{emit:"titleTemplateChange"},{emit:"toolbarItemsChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"wrapperAttrChange"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new F1(t,n)}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("toolbarItems",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("toolbarItems"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-popover"]],contentQueries:function(n,o,s){if(n&1&&ke(s,rp,4),n&2){let r;Be(r=Ve())&&(o.toolbarItemsChildren=r)}},inputs:{animation:"animation",closeOnOutsideClick:"closeOnOutsideClick",container:"container",contentTemplate:"contentTemplate",deferRendering:"deferRendering",disabled:"disabled",enableBodyScroll:"enableBodyScroll",height:"height",hideEvent:"hideEvent",hideOnOutsideClick:"hideOnOutsideClick",hideOnParentScroll:"hideOnParentScroll",hint:"hint",hoverStateEnabled:"hoverStateEnabled",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",position:"position",rtlEnabled:"rtlEnabled",shading:"shading",shadingColor:"shadingColor",showCloseButton:"showCloseButton",showEvent:"showEvent",showTitle:"showTitle",target:"target",title:"title",titleTemplate:"titleTemplate",toolbarItems:"toolbarItems",visible:"visible",width:"width",wrapperAttr:"wrapperAttr"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onHidden:"onHidden",onHiding:"onHiding",onInitialized:"onInitialized",onOptionChanged:"onOptionChanged",onShowing:"onShowing",onShown:"onShown",onTitleRendered:"onTitleRendered",animationChange:"animationChange",closeOnOutsideClickChange:"closeOnOutsideClickChange",containerChange:"containerChange",contentTemplateChange:"contentTemplateChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",enableBodyScrollChange:"enableBodyScrollChange",heightChange:"heightChange",hideEventChange:"hideEventChange",hideOnOutsideClickChange:"hideOnOutsideClickChange",hideOnParentScrollChange:"hideOnParentScrollChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",maxHeightChange:"maxHeightChange",maxWidthChange:"maxWidthChange",minHeightChange:"minHeightChange",minWidthChange:"minWidthChange",positionChange:"positionChange",rtlEnabledChange:"rtlEnabledChange",shadingChange:"shadingChange",shadingColorChange:"shadingColorChange",showCloseButtonChange:"showCloseButtonChange",showEventChange:"showEventChange",showTitleChange:"showTitleChange",targetChange:"targetChange",titleChange:"titleChange",titleTemplateChange:"titleTemplateChange",toolbarItemsChange:"toolbarItemsChange",visibleChange:"visibleChange",widthChange:"widthChange",wrapperAttrChange:"wrapperAttrChange"},standalone:!1,features:[le([ee,ae,k,Se]),J,Ze],ngContentSelectors:P7,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},encapsulation:2})}return i})(),B7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Cl,Os,Ai,qe,ye,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Cl,Os,Ai,ye]})}return i})();var V7=["*"],L7=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get animation(){return this._getOption("animation")}set animation(t){this._setOption("animation",t)}get closeOnOutsideClick(){return this._getOption("closeOnOutsideClick")}set closeOnOutsideClick(t){this._setOption("closeOnOutsideClick",t)}get container(){return this._getOption("container")}set container(t){this._setOption("container",t)}get contentTemplate(){return this._getOption("contentTemplate")}set contentTemplate(t){this._setOption("contentTemplate",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get dragAndResizeArea(){return this._getOption("dragAndResizeArea")}set dragAndResizeArea(t){this._setOption("dragAndResizeArea",t)}get dragEnabled(){return this._getOption("dragEnabled")}set dragEnabled(t){this._setOption("dragEnabled",t)}get dragOutsideBoundary(){return this._getOption("dragOutsideBoundary")}set dragOutsideBoundary(t){this._setOption("dragOutsideBoundary",t)}get enableBodyScroll(){return this._getOption("enableBodyScroll")}set enableBodyScroll(t){this._setOption("enableBodyScroll",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get fullScreen(){return this._getOption("fullScreen")}set fullScreen(t){this._setOption("fullScreen",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hideOnOutsideClick(){return this._getOption("hideOnOutsideClick")}set hideOnOutsideClick(t){this._setOption("hideOnOutsideClick",t)}get hideOnParentScroll(){return this._getOption("hideOnParentScroll")}set hideOnParentScroll(t){this._setOption("hideOnParentScroll",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get maxHeight(){return this._getOption("maxHeight")}set maxHeight(t){this._setOption("maxHeight",t)}get maxWidth(){return this._getOption("maxWidth")}set maxWidth(t){this._setOption("maxWidth",t)}get minHeight(){return this._getOption("minHeight")}set minHeight(t){this._setOption("minHeight",t)}get minWidth(){return this._getOption("minWidth")}set minWidth(t){this._setOption("minWidth",t)}get position(){return this._getOption("position")}set position(t){this._setOption("position",t)}get resizeEnabled(){return this._getOption("resizeEnabled")}set resizeEnabled(t){this._setOption("resizeEnabled",t)}get restorePosition(){return this._getOption("restorePosition")}set restorePosition(t){this._setOption("restorePosition",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get shading(){return this._getOption("shading")}set shading(t){this._setOption("shading",t)}get shadingColor(){return this._getOption("shadingColor")}set shadingColor(t){this._setOption("shadingColor",t)}get showCloseButton(){return this._getOption("showCloseButton")}set showCloseButton(t){this._setOption("showCloseButton",t)}get showTitle(){return this._getOption("showTitle")}set showTitle(t){this._setOption("showTitle",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get title(){return this._getOption("title")}set title(t){this._setOption("title",t)}get titleTemplate(){return this._getOption("titleTemplate")}set titleTemplate(t){this._setOption("titleTemplate",t)}get toolbarItems(){return this._getOption("toolbarItems")}set toolbarItems(t){this._setOption("toolbarItems",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get wrapperAttr(){return this._getOption("wrapperAttr")}set wrapperAttr(t){this._setOption("wrapperAttr",t)}onContentReady;onDisposing;onHidden;onHiding;onInitialized;onOptionChanged;onResize;onResizeEnd;onResizeStart;onShowing;onShown;onTitleRendered;accessKeyChange;animationChange;closeOnOutsideClickChange;containerChange;contentTemplateChange;deferRenderingChange;disabledChange;dragAndResizeAreaChange;dragEnabledChange;dragOutsideBoundaryChange;enableBodyScrollChange;focusStateEnabledChange;fullScreenChange;heightChange;hideOnOutsideClickChange;hideOnParentScrollChange;hintChange;hoverStateEnabledChange;maxHeightChange;maxWidthChange;minHeightChange;minWidthChange;positionChange;resizeEnabledChange;restorePositionChange;rtlEnabledChange;shadingChange;shadingColorChange;showCloseButtonChange;showTitleChange;tabIndexChange;titleChange;titleTemplateChange;toolbarItemsChange;visibleChange;widthChange;wrapperAttrChange;get toolbarItemsChildren(){return this._getOption("toolbarItems")}set toolbarItemsChildren(t){this.setChildren("toolbarItems",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"hidden",emit:"onHidden"},{subscribe:"hiding",emit:"onHiding"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"resize",emit:"onResize"},{subscribe:"resizeEnd",emit:"onResizeEnd"},{subscribe:"resizeStart",emit:"onResizeStart"},{subscribe:"showing",emit:"onShowing"},{subscribe:"shown",emit:"onShown"},{subscribe:"titleRendered",emit:"onTitleRendered"},{emit:"accessKeyChange"},{emit:"animationChange"},{emit:"closeOnOutsideClickChange"},{emit:"containerChange"},{emit:"contentTemplateChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"dragAndResizeAreaChange"},{emit:"dragEnabledChange"},{emit:"dragOutsideBoundaryChange"},{emit:"enableBodyScrollChange"},{emit:"focusStateEnabledChange"},{emit:"fullScreenChange"},{emit:"heightChange"},{emit:"hideOnOutsideClickChange"},{emit:"hideOnParentScrollChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"maxHeightChange"},{emit:"maxWidthChange"},{emit:"minHeightChange"},{emit:"minWidthChange"},{emit:"positionChange"},{emit:"resizeEnabledChange"},{emit:"restorePositionChange"},{emit:"rtlEnabledChange"},{emit:"shadingChange"},{emit:"shadingColorChange"},{emit:"showCloseButtonChange"},{emit:"showTitleChange"},{emit:"tabIndexChange"},{emit:"titleChange"},{emit:"titleTemplateChange"},{emit:"toolbarItemsChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"wrapperAttrChange"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new A1(t,n)}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("toolbarItems",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("toolbarItems"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-popup"]],contentQueries:function(n,o,s){if(n&1&&ke(s,rp,4),n&2){let r;Be(r=Ve())&&(o.toolbarItemsChildren=r)}},inputs:{accessKey:"accessKey",animation:"animation",closeOnOutsideClick:"closeOnOutsideClick",container:"container",contentTemplate:"contentTemplate",deferRendering:"deferRendering",disabled:"disabled",dragAndResizeArea:"dragAndResizeArea",dragEnabled:"dragEnabled",dragOutsideBoundary:"dragOutsideBoundary",enableBodyScroll:"enableBodyScroll",focusStateEnabled:"focusStateEnabled",fullScreen:"fullScreen",height:"height",hideOnOutsideClick:"hideOnOutsideClick",hideOnParentScroll:"hideOnParentScroll",hint:"hint",hoverStateEnabled:"hoverStateEnabled",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",position:"position",resizeEnabled:"resizeEnabled",restorePosition:"restorePosition",rtlEnabled:"rtlEnabled",shading:"shading",shadingColor:"shadingColor",showCloseButton:"showCloseButton",showTitle:"showTitle",tabIndex:"tabIndex",title:"title",titleTemplate:"titleTemplate",toolbarItems:"toolbarItems",visible:"visible",width:"width",wrapperAttr:"wrapperAttr"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onHidden:"onHidden",onHiding:"onHiding",onInitialized:"onInitialized",onOptionChanged:"onOptionChanged",onResize:"onResize",onResizeEnd:"onResizeEnd",onResizeStart:"onResizeStart",onShowing:"onShowing",onShown:"onShown",onTitleRendered:"onTitleRendered",accessKeyChange:"accessKeyChange",animationChange:"animationChange",closeOnOutsideClickChange:"closeOnOutsideClickChange",containerChange:"containerChange",contentTemplateChange:"contentTemplateChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",dragAndResizeAreaChange:"dragAndResizeAreaChange",dragEnabledChange:"dragEnabledChange",dragOutsideBoundaryChange:"dragOutsideBoundaryChange",enableBodyScrollChange:"enableBodyScrollChange",focusStateEnabledChange:"focusStateEnabledChange",fullScreenChange:"fullScreenChange",heightChange:"heightChange",hideOnOutsideClickChange:"hideOnOutsideClickChange",hideOnParentScrollChange:"hideOnParentScrollChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",maxHeightChange:"maxHeightChange",maxWidthChange:"maxWidthChange",minHeightChange:"minHeightChange",minWidthChange:"minWidthChange",positionChange:"positionChange",resizeEnabledChange:"resizeEnabledChange",restorePositionChange:"restorePositionChange",rtlEnabledChange:"rtlEnabledChange",shadingChange:"shadingChange",shadingColorChange:"shadingColorChange",showCloseButtonChange:"showCloseButtonChange",showTitleChange:"showTitleChange",tabIndexChange:"tabIndexChange",titleChange:"titleChange",titleTemplateChange:"titleTemplateChange",toolbarItemsChange:"toolbarItemsChange",visibleChange:"visibleChange",widthChange:"widthChange",wrapperAttrChange:"wrapperAttrChange"},standalone:!1,features:[le([ee,ae,k,Se]),J,Ze],ngContentSelectors:V7,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},encapsulation:2})}return i})(),N7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,qe,ye,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Ai,ye]})}return i})();var P1=Xn.inherit({_getDefaultOptions(){return m(this.callBase(),{spellcheck:!0,minHeight:void 0,maxHeight:void 0,autoResizeEnabled:!1})},_initMarkup(){this.$element().addClass("dx-textarea"),this.callBase(),this.setAria("multiline","true")},_renderContentImpl(){this._updateInputHeight(),this.callBase()},_renderInput(){this.callBase(),this._renderScrollHandler()},_createInput(){let i=u("<textarea>");return this._applyInputAttributes(i,this.option("inputAttr")),this._updateInputAutoResizeAppearance(i),i},_setInputMinHeight:S,_renderScrollHandler(){this._eventY=0;let i=this._input(),e=D1(i,!0);_.on(i,D(Li.init,this.NAME),e,S),_.on(i,D(ne.down,this.NAME),this._pointerDownHandler.bind(this)),_.on(i,D(ne.move,this.NAME),this._pointerMoveHandler.bind(this))},_pointerDownHandler(i){this._eventY=Ye(i).y},_pointerMoveHandler(i){let e=Ye(i).y,t=this._eventY-e;tE(this._input(),t)&&(i.isScrollingEvent=!0,i.stopPropagation()),this._eventY=e},_renderDimensions(){let i=this.$element(),e=i.get(0),t=this._getOptionValue("width",e),n=this._getOptionValue("height",e),o=this.option("minHeight"),s=this.option("maxHeight");i.css({minHeight:o!==void 0?o:"",maxHeight:s!==void 0?s:"",width:t,height:n})},_resetDimensions(){this.$element().css({height:"",minHeight:"",maxHeight:""})},_renderEvents(){this.option("autoResizeEnabled")&&_.on(this._input(),D("input paste",this.NAME),this._updateInputHeight.bind(this)),this.callBase()},_refreshEvents(){_.off(this._input(),D("input paste",this.NAME)),this.callBase()},_getHeightDifference(i){return sr(this._$element.get(0),!1)+sr(this._$textEditorContainer.get(0),!1)+sr(this._$textEditorInputContainer.get(0),!0)+ch("height",K().getComputedStyle(i.get(0))).margin},_updateInputHeight(){if(!W())return;let i=this._input(),e=this.option("height"),t=e===void 0&&this.option("autoResizeEnabled");if(!(t||e===void 0&&this.option("minHeight"))){i.css("height","");return}this._resetDimensions(),this._$element.css("height",X(this._$element)),i.css("height",0);let o=this._getHeightDifference(i);this._renderDimensions();let s=this._getBoundaryHeight("minHeight"),r=this._getBoundaryHeight("maxHeight"),a=i[0].scrollHeight;if(s!==void 0&&(a=Math.max(a,s-o)),r!==void 0){let l=r-o,d=a>l;a=Math.min(a,l),this._updateInputAutoResizeAppearance(i,!d)}i.css("height",a),t&&this._$element.css("height","auto")},_getBoundaryHeight(i){let e=this.option(i);if(f(e))return typeof e=="number"?e:Wf(e,this.$element().get(0).parentElement,this._$element.get(0))},_renderInputType:S,_visibilityChanged(i){i&&this._updateInputHeight()},_updateInputAutoResizeAppearance(i,e){if(i){let t=Te(e,this.option("autoResizeEnabled"));i.toggleClass("dx-texteditor-input-auto-resize",t)}},_dimensionChanged(){this.option("visible")&&this._updateInputHeight()},_optionChanged(i){switch(i.name){case"autoResizeEnabled":this._updateInputAutoResizeAppearance(this._input(),i.value),this._refreshEvents(),this._updateInputHeight();break;case"value":case"height":this.callBase(i),this._updateInputHeight();break;case"minHeight":case"maxHeight":this._renderDimensions(),this._updateInputHeight();break;case"visible":this.callBase(i),i.value&&this._updateInputHeight();break;default:this.callBase(i)}}});G("dxTextArea",P1);var k1=P1;var B1=k1;var V1=oi.inherit({_supportedKeys(){let i=this.option("rtlEnabled"),e=function(n){n.preventDefault(),this._clickAction({event:n})},t=function(n,o){o.preventDefault(),o.stopPropagation(),this._saveValueChangeEvent(o),this._animateValue(n)};return m(this.callBase(),{space:e,enter:e,leftArrow:t.bind(this,!!i),rightArrow:t.bind(this,!i)})},_useTemplates:()=>!1,_getDefaultOptions(){return m(this.callBase(),{hoverStateEnabled:!0,activeStateEnabled:!0,switchedOnText:O.format("dxSwitch-switchedOnText"),switchedOffText:O.format("dxSwitch-switchedOffText"),value:!1})},_defaultOptionsRules(){return this.callBase().concat([{device:()=>F.real().deviceType==="desktop"&&!F.isSimulator(),options:{focusStateEnabled:!0}}])},_feedbackHideTimeout:0,_animating:!1,_initMarkup(){this._renderContainers(),this.$element().addClass("dx-switch").append(this._$switchWrapper),this._renderSubmitElement(),this._renderClick(),this.setAria("role","switch"),this._renderSwipeable(),this.callBase(),this._renderSwitchInner(),this._renderLabels(),this._renderValue()},_getInnerOffset(i,e){return 100*((e-this._offsetDirection()*+!i)/2)+"%"},_getHandleOffset(i,e){return this.option("rtlEnabled")&&(i=!i),i?`${100*-e-100}%`:100*-e+"%"},_renderSwitchInner(){this._$switchInner=u("<div>").addClass("dx-switch-inner").appendTo(this._$switchContainer),this._$handle=u("<div>").addClass("dx-switch-handle").appendTo(this._$switchInner)},_renderLabels(){this._$labelOn=u("<div>").addClass("dx-switch-on").prependTo(this._$switchInner),this._$labelOff=u("<div>").addClass("dx-switch-off").appendTo(this._$switchInner),this._setLabelsText()},_renderContainers(){this._$switchContainer=u("<div>").addClass("dx-switch-container"),this._$switchWrapper=u("<div>").addClass("dx-switch-wrapper").append(this._$switchContainer)},_renderSwipeable(){this._createComponent(this.$element(),Ns,{elastic:!1,immediate:!0,onStart:this._swipeStartHandler.bind(this),onUpdated:this._swipeUpdateHandler.bind(this),onEnd:this._swipeEndHandler.bind(this),itemSizeFunc:this._getItemSizeFunc.bind(this)})},_getItemSizeFunc(){return ie(this._$switchContainer,!0)-Ie(this._$handle.get(0)).width},_renderSubmitElement(){this._$submitElement=u("<input>").attr("type","hidden").appendTo(this.$element())},_getSubmitElement(){return this._$submitElement},_offsetDirection(){return this.option("rtlEnabled")?-1:1},_renderPosition(i,e){let t=this._getInnerOffset(i,e),n=this._getHandleOffset(i,e);this._$switchInner.css("transform",` translateX(${t})`),this._$handle.css("transform",` translateX(${n})`)},_validateValue(){let i=this.option("value");typeof i!="boolean"&&this._options.silent("value",!!i)},_renderClick(){let i=D(oe,this.NAME),e=this.$element();this._clickAction=this._createAction(this._clickHandler.bind(this)),_.off(e,i),_.on(e,i,t=>{this._clickAction({event:t})})},_clickHandler(i){let e=i.event;this._saveValueChangeEvent(e),!(this._animating||this._swiping)&&this._animateValue(!this.option("value"))},_animateValue(i){let e=this.option("value"),t=i;if(e===t)return;this._animating=!0;let n=this._getInnerOffset(e,0),o=this._getInnerOffset(t,0),s=this._getHandleOffset(e,0),r=this._getHandleOffset(t,0),a=this,l={},d={},c={},h={};l.transform=` translateX(${n})`,d.transform=` translateX(${o})`,c.transform=` translateX(${s})`,h.transform=` translateX(${r})`,this.$element().toggleClass("dx-switch-on-value",t),pe.animate(this._$handle,{from:c,to:h,duration:100}),pe.animate(this._$switchInner,{from:l,to:d,duration:100,complete(){a._animating=!1,a.option("value",t)}})},_swipeStartHandler(i){let e=this.option("value"),t=this.option("rtlEnabled"),n=t?0:1,o=t?1:0;i.event.maxLeftOffset=e?n:o,i.event.maxRightOffset=e?o:n,this._swiping=!0,this._feedbackDeferred=y(),ip(this._feedbackDeferred),this._toggleActiveState(this.$element(),this.option("activeStateEnabled"))},_swipeUpdateHandler(i){this._renderPosition(this.option("value"),i.event.offset)},_swipeEndHandler(i){let e=this,t=this._offsetDirection(),n={},o={},s=this._getInnerOffset(e.option("value"),i.event.targetOffset),r=this._getHandleOffset(e.option("value"),i.event.targetOffset);n.transform=` translateX(${s})`,o.transform=` translateX(${r})`,pe.animate(this._$handle,{to:o,duration:100}),pe.animate(this._$switchInner,{to:n,duration:100,complete(){e._swiping=!1;let a=e.option("value")+t*i.event.targetOffset;e._saveValueChangeEvent(i.event),e.option("value",!!a),e._feedbackDeferred.resolve(),e._toggleActiveState(e.$element(),!1)}})},_renderValue(){this._validateValue();let i=this.option("value");this._renderPosition(i,0),this.$element().toggleClass("dx-switch-on-value",i),this._getSubmitElement().val(i),this.setAria({checked:i,label:i?this.option("switchedOnText"):this.option("switchedOffText")})},_setLabelsText(){this._$labelOn&&this._$labelOn.text(this.option("switchedOnText")),this._$labelOff&&this._$labelOff.text(this.option("switchedOffText"))},_visibilityChanged(i){i&&this.repaint()},_optionChanged(i){switch(i.name){case"width":delete this._marginBound,this._refresh();break;case"switchedOnText":case"switchedOffText":this._setLabelsText();break;case"value":this._renderValue(),this.callBase(i);break;default:this.callBase(i)}}});G("dxSwitch",V1);var L1=V1;var N1=L1;var H7=["*"],$7=(()=>{class i extends et{instance=null;get bounceEnabled(){return this._getOption("bounceEnabled")}set bounceEnabled(t){this._setOption("bounceEnabled",t)}get direction(){return this._getOption("direction")}set direction(t){this._setOption("direction",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get pulledDownText(){return this._getOption("pulledDownText")}set pulledDownText(t){this._setOption("pulledDownText",t)}get pullingDownText(){return this._getOption("pullingDownText")}set pullingDownText(t){this._setOption("pullingDownText",t)}get reachBottomText(){return this._getOption("reachBottomText")}set reachBottomText(t){this._setOption("reachBottomText",t)}get refreshingText(){return this._getOption("refreshingText")}set refreshingText(t){this._setOption("refreshingText",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get scrollByContent(){return this._getOption("scrollByContent")}set scrollByContent(t){this._setOption("scrollByContent",t)}get scrollByThumb(){return this._getOption("scrollByThumb")}set scrollByThumb(t){this._setOption("scrollByThumb",t)}get showScrollbar(){return this._getOption("showScrollbar")}set showScrollbar(t){this._setOption("showScrollbar",t)}get useNative(){return this._getOption("useNative")}set useNative(t){this._setOption("useNative",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onDisposing;onInitialized;onOptionChanged;onPullDown;onReachBottom;onScroll;onUpdated;bounceEnabledChange;directionChange;disabledChange;elementAttrChange;heightChange;pulledDownTextChange;pullingDownTextChange;reachBottomTextChange;refreshingTextChange;rtlEnabledChange;scrollByContentChange;scrollByThumbChange;showScrollbarChange;useNativeChange;widthChange;constructor(t,n,o,s,r,a,l){super(t,n,o,s,a,l),this._createEventEmitters([{subscribe:"disposing",emit:"onDisposing"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"pullDown",emit:"onPullDown"},{subscribe:"reachBottom",emit:"onReachBottom"},{subscribe:"scroll",emit:"onScroll"},{subscribe:"updated",emit:"onUpdated"},{emit:"bounceEnabledChange"},{emit:"directionChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"heightChange"},{emit:"pulledDownTextChange"},{emit:"pullingDownTextChange"},{emit:"reachBottomTextChange"},{emit:"refreshingTextChange"},{emit:"rtlEnabledChange"},{emit:"scrollByContentChange"},{emit:"scrollByThumbChange"},{emit:"showScrollbarChange"},{emit:"useNativeChange"},{emit:"widthChange"}]),r.setHost(this)}_createInstance(t,n){return new Bl(t,n)}ngOnDestroy(){this._destroyWidget()}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-scroll-view"]],inputs:{bounceEnabled:"bounceEnabled",direction:"direction",disabled:"disabled",elementAttr:"elementAttr",height:"height",pulledDownText:"pulledDownText",pullingDownText:"pullingDownText",reachBottomText:"reachBottomText",refreshingText:"refreshingText",rtlEnabled:"rtlEnabled",scrollByContent:"scrollByContent",scrollByThumb:"scrollByThumb",showScrollbar:"showScrollbar",useNative:"useNative",width:"width"},outputs:{onDisposing:"onDisposing",onInitialized:"onInitialized",onOptionChanged:"onOptionChanged",onPullDown:"onPullDown",onReachBottom:"onReachBottom",onScroll:"onScroll",onUpdated:"onUpdated",bounceEnabledChange:"bounceEnabledChange",directionChange:"directionChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",heightChange:"heightChange",pulledDownTextChange:"pulledDownTextChange",pullingDownTextChange:"pullingDownTextChange",reachBottomTextChange:"reachBottomTextChange",refreshingTextChange:"refreshingTextChange",rtlEnabledChange:"rtlEnabledChange",scrollByContentChange:"scrollByContentChange",scrollByThumbChange:"scrollByThumbChange",showScrollbarChange:"showScrollbarChange",useNativeChange:"useNativeChange",widthChange:"widthChange"},standalone:!1,features:[le([ee,ae,k]),J],ngContentSelectors:H7,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},encapsulation:2})}return i})(),z7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[qe,ye,ye]})}return i})();var W7={provide:Ri,useExisting:Ht(()=>H1),multi:!0},H1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get switchedOffText(){return this._getOption("switchedOffText")}set switchedOffText(t){this._setOption("switchedOffText",t)}get switchedOnText(){return this._getOption("switchedOnText")}set switchedOnText(t){this._setOption("switchedOnText",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onContentReady;onDisposing;onInitialized;onOptionChanged;onValueChanged;accessKeyChange;activeStateEnabledChange;disabledChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;isDirtyChange;isValidChange;nameChange;readOnlyChange;rtlEnabledChange;switchedOffTextChange;switchedOnTextChange;tabIndexChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"nameChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"switchedOffTextChange"},{emit:"switchedOnTextChange"},{emit:"tabIndexChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new N1(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("validationErrors",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("validationErrors"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-switch"]],hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",isDirty:"isDirty",isValid:"isValid",name:"name",readOnly:"readOnly",rtlEnabled:"rtlEnabled",switchedOffText:"switchedOffText",switchedOnText:"switchedOnText",tabIndex:"tabIndex",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",visible:"visible",width:"width"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onInitialized:"onInitialized",onOptionChanged:"onOptionChanged",onValueChanged:"onValueChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",nameChange:"nameChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",switchedOffTextChange:"switchedOffTextChange",switchedOnTextChange:"switchedOnTextChange",tabIndexChange:"tabIndexChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,W7,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),G7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[qe,ye,ye]})}return i})();var K7={provide:Ri,useExisting:Ht(()=>$1),multi:!0},$1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get autoResizeEnabled(){return this._getOption("autoResizeEnabled")}set autoResizeEnabled(t){this._setOption("autoResizeEnabled",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get inputAttr(){return this._getOption("inputAttr")}set inputAttr(t){this._setOption("inputAttr",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get labelMode(){return this._getOption("labelMode")}set labelMode(t){this._setOption("labelMode",t)}get maxHeight(){return this._getOption("maxHeight")}set maxHeight(t){this._setOption("maxHeight",t)}get maxLength(){return this._getOption("maxLength")}set maxLength(t){this._setOption("maxLength",t)}get minHeight(){return this._getOption("minHeight")}set minHeight(t){this._setOption("minHeight",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get placeholder(){return this._getOption("placeholder")}set placeholder(t){this._setOption("placeholder",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get spellcheck(){return this._getOption("spellcheck")}set spellcheck(t){this._setOption("spellcheck",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get valueChangeEvent(){return this._getOption("valueChangeEvent")}set valueChangeEvent(t){this._setOption("valueChangeEvent",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onChange;onContentReady;onCopy;onCut;onDisposing;onEnterKey;onFocusIn;onFocusOut;onInitialized;onInput;onKeyDown;onKeyUp;onOptionChanged;onPaste;onValueChanged;accessKeyChange;activeStateEnabledChange;autoResizeEnabledChange;disabledChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;inputAttrChange;isDirtyChange;isValidChange;labelChange;labelModeChange;maxHeightChange;maxLengthChange;minHeightChange;nameChange;placeholderChange;readOnlyChange;rtlEnabledChange;spellcheckChange;stylingModeChange;tabIndexChange;textChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;valueChangeEventChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"change",emit:"onChange"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"copy",emit:"onCopy"},{subscribe:"cut",emit:"onCut"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"enterKey",emit:"onEnterKey"},{subscribe:"focusIn",emit:"onFocusIn"},{subscribe:"focusOut",emit:"onFocusOut"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"input",emit:"onInput"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"keyUp",emit:"onKeyUp"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"paste",emit:"onPaste"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"autoResizeEnabledChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"inputAttrChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"labelChange"},{emit:"labelModeChange"},{emit:"maxHeightChange"},{emit:"maxLengthChange"},{emit:"minHeightChange"},{emit:"nameChange"},{emit:"placeholderChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"spellcheckChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"textChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"valueChangeEventChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new B1(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("validationErrors",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("validationErrors"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-text-area"]],hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",autoResizeEnabled:"autoResizeEnabled",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",inputAttr:"inputAttr",isDirty:"isDirty",isValid:"isValid",label:"label",labelMode:"labelMode",maxHeight:"maxHeight",maxLength:"maxLength",minHeight:"minHeight",name:"name",placeholder:"placeholder",readOnly:"readOnly",rtlEnabled:"rtlEnabled",spellcheck:"spellcheck",stylingMode:"stylingMode",tabIndex:"tabIndex",text:"text",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",valueChangeEvent:"valueChangeEvent",visible:"visible",width:"width"},outputs:{onChange:"onChange",onContentReady:"onContentReady",onCopy:"onCopy",onCut:"onCut",onDisposing:"onDisposing",onEnterKey:"onEnterKey",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onInitialized:"onInitialized",onInput:"onInput",onKeyDown:"onKeyDown",onKeyUp:"onKeyUp",onOptionChanged:"onOptionChanged",onPaste:"onPaste",onValueChanged:"onValueChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",autoResizeEnabledChange:"autoResizeEnabledChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",inputAttrChange:"inputAttrChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",labelChange:"labelChange",labelModeChange:"labelModeChange",maxHeightChange:"maxHeightChange",maxLengthChange:"maxLengthChange",minHeightChange:"minHeightChange",nameChange:"nameChange",placeholderChange:"placeholderChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",spellcheckChange:"spellcheckChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",textChange:"textChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",valueChangeEventChange:"valueChangeEventChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,K7,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),U7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[qe,ye,ye]})}return i})();var j7={provide:Ri,useExisting:Ht(()=>z1),multi:!0},z1=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get buttons(){return this._getOption("buttons")}set buttons(t){this._setOption("buttons",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get inputAttr(){return this._getOption("inputAttr")}set inputAttr(t){this._setOption("inputAttr",t)}get isDirty(){return this._getOption("isDirty")}set isDirty(t){this._setOption("isDirty",t)}get isValid(){return this._getOption("isValid")}set isValid(t){this._setOption("isValid",t)}get label(){return this._getOption("label")}set label(t){this._setOption("label",t)}get labelMode(){return this._getOption("labelMode")}set labelMode(t){this._setOption("labelMode",t)}get mask(){return this._getOption("mask")}set mask(t){this._setOption("mask",t)}get maskChar(){return this._getOption("maskChar")}set maskChar(t){this._setOption("maskChar",t)}get maskInvalidMessage(){return this._getOption("maskInvalidMessage")}set maskInvalidMessage(t){this._setOption("maskInvalidMessage",t)}get maskRules(){return this._getOption("maskRules")}set maskRules(t){this._setOption("maskRules",t)}get maxLength(){return this._getOption("maxLength")}set maxLength(t){this._setOption("maxLength",t)}get mode(){return this._getOption("mode")}set mode(t){this._setOption("mode",t)}get name(){return this._getOption("name")}set name(t){this._setOption("name",t)}get placeholder(){return this._getOption("placeholder")}set placeholder(t){this._setOption("placeholder",t)}get readOnly(){return this._getOption("readOnly")}set readOnly(t){this._setOption("readOnly",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get showClearButton(){return this._getOption("showClearButton")}set showClearButton(t){this._setOption("showClearButton",t)}get showMaskMode(){return this._getOption("showMaskMode")}set showMaskMode(t){this._setOption("showMaskMode",t)}get spellcheck(){return this._getOption("spellcheck")}set spellcheck(t){this._setOption("spellcheck",t)}get stylingMode(){return this._getOption("stylingMode")}set stylingMode(t){this._setOption("stylingMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get text(){return this._getOption("text")}set text(t){this._setOption("text",t)}get useMaskedValue(){return this._getOption("useMaskedValue")}set useMaskedValue(t){this._setOption("useMaskedValue",t)}get validationError(){return this._getOption("validationError")}set validationError(t){this._setOption("validationError",t)}get validationErrors(){return this._getOption("validationErrors")}set validationErrors(t){this._setOption("validationErrors",t)}get validationMessageMode(){return this._getOption("validationMessageMode")}set validationMessageMode(t){this._setOption("validationMessageMode",t)}get validationMessagePosition(){return this._getOption("validationMessagePosition")}set validationMessagePosition(t){this._setOption("validationMessagePosition",t)}get validationStatus(){return this._getOption("validationStatus")}set validationStatus(t){this._setOption("validationStatus",t)}get value(){return this._getOption("value")}set value(t){this._setOption("value",t)}get valueChangeEvent(){return this._getOption("valueChangeEvent")}set valueChangeEvent(t){this._setOption("valueChangeEvent",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onChange;onContentReady;onCopy;onCut;onDisposing;onEnterKey;onFocusIn;onFocusOut;onInitialized;onInput;onKeyDown;onKeyUp;onOptionChanged;onPaste;onValueChanged;accessKeyChange;activeStateEnabledChange;buttonsChange;disabledChange;elementAttrChange;focusStateEnabledChange;heightChange;hintChange;hoverStateEnabledChange;inputAttrChange;isDirtyChange;isValidChange;labelChange;labelModeChange;maskChange;maskCharChange;maskInvalidMessageChange;maskRulesChange;maxLengthChange;modeChange;nameChange;placeholderChange;readOnlyChange;rtlEnabledChange;showClearButtonChange;showMaskModeChange;spellcheckChange;stylingModeChange;tabIndexChange;textChange;useMaskedValueChange;validationErrorChange;validationErrorsChange;validationMessageModeChange;validationMessagePositionChange;validationStatusChange;valueChange;valueChangeEventChange;visibleChange;widthChange;onBlur;change(t){}touched=t=>{};get buttonsChildren(){return this._getOption("buttons")}set buttonsChildren(t){this.setChildren("buttons",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"change",emit:"onChange"},{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"copy",emit:"onCopy"},{subscribe:"cut",emit:"onCut"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"enterKey",emit:"onEnterKey"},{subscribe:"focusIn",emit:"onFocusIn"},{subscribe:"focusOut",emit:"onFocusOut"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"input",emit:"onInput"},{subscribe:"keyDown",emit:"onKeyDown"},{subscribe:"keyUp",emit:"onKeyUp"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"paste",emit:"onPaste"},{subscribe:"valueChanged",emit:"onValueChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"buttonsChange"},{emit:"disabledChange"},{emit:"elementAttrChange"},{emit:"focusStateEnabledChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"inputAttrChange"},{emit:"isDirtyChange"},{emit:"isValidChange"},{emit:"labelChange"},{emit:"labelModeChange"},{emit:"maskChange"},{emit:"maskCharChange"},{emit:"maskInvalidMessageChange"},{emit:"maskRulesChange"},{emit:"maxLengthChange"},{emit:"modeChange"},{emit:"nameChange"},{emit:"placeholderChange"},{emit:"readOnlyChange"},{emit:"rtlEnabledChange"},{emit:"showClearButtonChange"},{emit:"showMaskModeChange"},{emit:"spellcheckChange"},{emit:"stylingModeChange"},{emit:"tabIndexChange"},{emit:"textChange"},{emit:"useMaskedValueChange"},{emit:"validationErrorChange"},{emit:"validationErrorsChange"},{emit:"validationMessageModeChange"},{emit:"validationMessagePositionChange"},{emit:"validationStatusChange"},{emit:"valueChange"},{emit:"valueChangeEventChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"onBlur"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new Xn(t,n)}writeValue(t){this.eventHelper.lockedValueChangeEvent=!0,this.value=t,this.eventHelper.lockedValueChangeEvent=!1}setDisabledState(t){this.disabled=t}registerOnChange(t){this.change=t}registerOnTouched(t){this.touched=t}_createWidget(t){super._createWidget(t),this.instance.on("focusOut",n=>{this.eventHelper.fireNgEvent("onBlur",[n])})}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("buttons",t),this.setupChanges("validationErrors",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("buttons"),this._idh.doCheck("validationErrors"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-text-box"]],contentQueries:function(n,o,s){if(n&1&&ke(s,_o,4),n&2){let r;Be(r=Ve())&&(o.buttonsChildren=r)}},hostBindings:function(n,o){n&1&&mi("valueChange",function(r){return o.change(r)})("onBlur",function(r){return o.touched(r)})},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",buttons:"buttons",disabled:"disabled",elementAttr:"elementAttr",focusStateEnabled:"focusStateEnabled",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",inputAttr:"inputAttr",isDirty:"isDirty",isValid:"isValid",label:"label",labelMode:"labelMode",mask:"mask",maskChar:"maskChar",maskInvalidMessage:"maskInvalidMessage",maskRules:"maskRules",maxLength:"maxLength",mode:"mode",name:"name",placeholder:"placeholder",readOnly:"readOnly",rtlEnabled:"rtlEnabled",showClearButton:"showClearButton",showMaskMode:"showMaskMode",spellcheck:"spellcheck",stylingMode:"stylingMode",tabIndex:"tabIndex",text:"text",useMaskedValue:"useMaskedValue",validationError:"validationError",validationErrors:"validationErrors",validationMessageMode:"validationMessageMode",validationMessagePosition:"validationMessagePosition",validationStatus:"validationStatus",value:"value",valueChangeEvent:"valueChangeEvent",visible:"visible",width:"width"},outputs:{onChange:"onChange",onContentReady:"onContentReady",onCopy:"onCopy",onCut:"onCut",onDisposing:"onDisposing",onEnterKey:"onEnterKey",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onInitialized:"onInitialized",onInput:"onInput",onKeyDown:"onKeyDown",onKeyUp:"onKeyUp",onOptionChanged:"onOptionChanged",onPaste:"onPaste",onValueChanged:"onValueChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",buttonsChange:"buttonsChange",disabledChange:"disabledChange",elementAttrChange:"elementAttrChange",focusStateEnabledChange:"focusStateEnabledChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",inputAttrChange:"inputAttrChange",isDirtyChange:"isDirtyChange",isValidChange:"isValidChange",labelChange:"labelChange",labelModeChange:"labelModeChange",maskChange:"maskChange",maskCharChange:"maskCharChange",maskInvalidMessageChange:"maskInvalidMessageChange",maskRulesChange:"maskRulesChange",maxLengthChange:"maxLengthChange",modeChange:"modeChange",nameChange:"nameChange",placeholderChange:"placeholderChange",readOnlyChange:"readOnlyChange",rtlEnabledChange:"rtlEnabledChange",showClearButtonChange:"showClearButtonChange",showMaskModeChange:"showMaskModeChange",spellcheckChange:"spellcheckChange",stylingModeChange:"stylingModeChange",tabIndexChange:"tabIndexChange",textChange:"textChange",useMaskedValueChange:"useMaskedValueChange",validationErrorChange:"validationErrorChange",validationErrorsChange:"validationErrorsChange",validationMessageModeChange:"validationMessageModeChange",validationMessagePositionChange:"validationMessagePositionChange",validationStatusChange:"validationStatusChange",valueChange:"valueChange",valueChangeEventChange:"valueChangeEventChange",visibleChange:"visibleChange",widthChange:"widthChange",onBlur:"onBlur"},standalone:!1,features:[le([ee,ae,j7,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),q7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[ei,Mi,qe,ye,ei,Mi,ye]})}return i})();var Y7=["*"],oE=(()=>{class i extends et{instance=null;get animation(){return this._getOption("animation")}set animation(t){this._setOption("animation",t)}get closeOnOutsideClick(){return this._getOption("closeOnOutsideClick")}set closeOnOutsideClick(t){this._setOption("closeOnOutsideClick",t)}get container(){return this._getOption("container")}set container(t){this._setOption("container",t)}get contentTemplate(){return this._getOption("contentTemplate")}set contentTemplate(t){this._setOption("contentTemplate",t)}get deferRendering(){return this._getOption("deferRendering")}set deferRendering(t){this._setOption("deferRendering",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hideEvent(){return this._getOption("hideEvent")}set hideEvent(t){this._setOption("hideEvent",t)}get hideOnOutsideClick(){return this._getOption("hideOnOutsideClick")}set hideOnOutsideClick(t){this._setOption("hideOnOutsideClick",t)}get hideOnParentScroll(){return this._getOption("hideOnParentScroll")}set hideOnParentScroll(t){this._setOption("hideOnParentScroll",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get maxHeight(){return this._getOption("maxHeight")}set maxHeight(t){this._setOption("maxHeight",t)}get maxWidth(){return this._getOption("maxWidth")}set maxWidth(t){this._setOption("maxWidth",t)}get minHeight(){return this._getOption("minHeight")}set minHeight(t){this._setOption("minHeight",t)}get minWidth(){return this._getOption("minWidth")}set minWidth(t){this._setOption("minWidth",t)}get position(){return this._getOption("position")}set position(t){this._setOption("position",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get shading(){return this._getOption("shading")}set shading(t){this._setOption("shading",t)}get shadingColor(){return this._getOption("shadingColor")}set shadingColor(t){this._setOption("shadingColor",t)}get showEvent(){return this._getOption("showEvent")}set showEvent(t){this._setOption("showEvent",t)}get target(){return this._getOption("target")}set target(t){this._setOption("target",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}get wrapperAttr(){return this._getOption("wrapperAttr")}set wrapperAttr(t){this._setOption("wrapperAttr",t)}onContentReady;onDisposing;onHidden;onHiding;onInitialized;onOptionChanged;onShowing;onShown;animationChange;closeOnOutsideClickChange;containerChange;contentTemplateChange;deferRenderingChange;disabledChange;heightChange;hideEventChange;hideOnOutsideClickChange;hideOnParentScrollChange;hintChange;hoverStateEnabledChange;maxHeightChange;maxWidthChange;minHeightChange;minWidthChange;positionChange;rtlEnabledChange;shadingChange;shadingColorChange;showEventChange;targetChange;visibleChange;widthChange;wrapperAttrChange;constructor(t,n,o,s,r,a,l){super(t,n,o,s,a,l),this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"hidden",emit:"onHidden"},{subscribe:"hiding",emit:"onHiding"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"showing",emit:"onShowing"},{subscribe:"shown",emit:"onShown"},{emit:"animationChange"},{emit:"closeOnOutsideClickChange"},{emit:"containerChange"},{emit:"contentTemplateChange"},{emit:"deferRenderingChange"},{emit:"disabledChange"},{emit:"heightChange"},{emit:"hideEventChange"},{emit:"hideOnOutsideClickChange"},{emit:"hideOnParentScrollChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"maxHeightChange"},{emit:"maxWidthChange"},{emit:"minHeightChange"},{emit:"minWidthChange"},{emit:"positionChange"},{emit:"rtlEnabledChange"},{emit:"shadingChange"},{emit:"shadingColorChange"},{emit:"showEventChange"},{emit:"targetChange"},{emit:"visibleChange"},{emit:"widthChange"},{emit:"wrapperAttrChange"}]),r.setHost(this)}_createInstance(t,n){return new m1(t,n)}ngOnDestroy(){this._destroyWidget()}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-tooltip"]],inputs:{animation:"animation",closeOnOutsideClick:"closeOnOutsideClick",container:"container",contentTemplate:"contentTemplate",deferRendering:"deferRendering",disabled:"disabled",height:"height",hideEvent:"hideEvent",hideOnOutsideClick:"hideOnOutsideClick",hideOnParentScroll:"hideOnParentScroll",hint:"hint",hoverStateEnabled:"hoverStateEnabled",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",position:"position",rtlEnabled:"rtlEnabled",shading:"shading",shadingColor:"shadingColor",showEvent:"showEvent",target:"target",visible:"visible",width:"width",wrapperAttr:"wrapperAttr"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onHidden:"onHidden",onHiding:"onHiding",onInitialized:"onInitialized",onOptionChanged:"onOptionChanged",onShowing:"onShowing",onShown:"onShown",animationChange:"animationChange",closeOnOutsideClickChange:"closeOnOutsideClickChange",containerChange:"containerChange",contentTemplateChange:"contentTemplateChange",deferRenderingChange:"deferRenderingChange",disabledChange:"disabledChange",heightChange:"heightChange",hideEventChange:"hideEventChange",hideOnOutsideClickChange:"hideOnOutsideClickChange",hideOnParentScrollChange:"hideOnParentScrollChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",maxHeightChange:"maxHeightChange",maxWidthChange:"maxWidthChange",minHeightChange:"minHeightChange",minWidthChange:"minWidthChange",positionChange:"positionChange",rtlEnabledChange:"rtlEnabledChange",shadingChange:"shadingChange",shadingColorChange:"shadingColorChange",showEventChange:"showEventChange",targetChange:"targetChange",visibleChange:"visibleChange",widthChange:"widthChange",wrapperAttrChange:"wrapperAttrChange"},standalone:!1,features:[le([ee,ae,k]),J],ngContentSelectors:Y7,decls:1,vars:0,template:function(n,o){n&1&&(fi(),_i(0))},encapsulation:2})}return i})(),sE=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Cl,Os,qe,ye,Tt,Pt,Ft,Vt,At,Mt,Rt,kt,Bt,Nt,Lt,Cl,Os,ye]})}return i})();var X7=(()=>{class i extends et{_watcherHelper;_idh;instance=null;get accessKey(){return this._getOption("accessKey")}set accessKey(t){this._setOption("accessKey",t)}get activeStateEnabled(){return this._getOption("activeStateEnabled")}set activeStateEnabled(t){this._setOption("activeStateEnabled",t)}get animationEnabled(){return this._getOption("animationEnabled")}set animationEnabled(t){this._setOption("animationEnabled",t)}get collapseIcon(){return this._getOption("collapseIcon")}set collapseIcon(t){this._setOption("collapseIcon",t)}get createChildren(){return this._getOption("createChildren")}set createChildren(t){this._setOption("createChildren",t)}get dataSource(){return this._getOption("dataSource")}set dataSource(t){this._setOption("dataSource",t)}get dataStructure(){return this._getOption("dataStructure")}set dataStructure(t){this._setOption("dataStructure",t)}get disabled(){return this._getOption("disabled")}set disabled(t){this._setOption("disabled",t)}get disabledExpr(){return this._getOption("disabledExpr")}set disabledExpr(t){this._setOption("disabledExpr",t)}get displayExpr(){return this._getOption("displayExpr")}set displayExpr(t){this._setOption("displayExpr",t)}get elementAttr(){return this._getOption("elementAttr")}set elementAttr(t){this._setOption("elementAttr",t)}get expandAllEnabled(){return this._getOption("expandAllEnabled")}set expandAllEnabled(t){this._setOption("expandAllEnabled",t)}get expandedExpr(){return this._getOption("expandedExpr")}set expandedExpr(t){this._setOption("expandedExpr",t)}get expandEvent(){return this._getOption("expandEvent")}set expandEvent(t){this._setOption("expandEvent",t)}get expandIcon(){return this._getOption("expandIcon")}set expandIcon(t){this._setOption("expandIcon",t)}get expandNodesRecursive(){return this._getOption("expandNodesRecursive")}set expandNodesRecursive(t){this._setOption("expandNodesRecursive",t)}get focusStateEnabled(){return this._getOption("focusStateEnabled")}set focusStateEnabled(t){this._setOption("focusStateEnabled",t)}get hasItemsExpr(){return this._getOption("hasItemsExpr")}set hasItemsExpr(t){this._setOption("hasItemsExpr",t)}get height(){return this._getOption("height")}set height(t){this._setOption("height",t)}get hint(){return this._getOption("hint")}set hint(t){this._setOption("hint",t)}get hoverStateEnabled(){return this._getOption("hoverStateEnabled")}set hoverStateEnabled(t){this._setOption("hoverStateEnabled",t)}get itemHoldTimeout(){return this._getOption("itemHoldTimeout")}set itemHoldTimeout(t){this._setOption("itemHoldTimeout",t)}get items(){return this._getOption("items")}set items(t){this._setOption("items",t)}get itemsExpr(){return this._getOption("itemsExpr")}set itemsExpr(t){this._setOption("itemsExpr",t)}get itemTemplate(){return this._getOption("itemTemplate")}set itemTemplate(t){this._setOption("itemTemplate",t)}get keyExpr(){return this._getOption("keyExpr")}set keyExpr(t){this._setOption("keyExpr",t)}get noDataText(){return this._getOption("noDataText")}set noDataText(t){this._setOption("noDataText",t)}get parentIdExpr(){return this._getOption("parentIdExpr")}set parentIdExpr(t){this._setOption("parentIdExpr",t)}get rootValue(){return this._getOption("rootValue")}set rootValue(t){this._setOption("rootValue",t)}get rtlEnabled(){return this._getOption("rtlEnabled")}set rtlEnabled(t){this._setOption("rtlEnabled",t)}get scrollDirection(){return this._getOption("scrollDirection")}set scrollDirection(t){this._setOption("scrollDirection",t)}get searchEditorOptions(){return this._getOption("searchEditorOptions")}set searchEditorOptions(t){this._setOption("searchEditorOptions",t)}get searchEnabled(){return this._getOption("searchEnabled")}set searchEnabled(t){this._setOption("searchEnabled",t)}get searchExpr(){return this._getOption("searchExpr")}set searchExpr(t){this._setOption("searchExpr",t)}get searchMode(){return this._getOption("searchMode")}set searchMode(t){this._setOption("searchMode",t)}get searchTimeout(){return this._getOption("searchTimeout")}set searchTimeout(t){this._setOption("searchTimeout",t)}get searchValue(){return this._getOption("searchValue")}set searchValue(t){this._setOption("searchValue",t)}get selectAllText(){return this._getOption("selectAllText")}set selectAllText(t){this._setOption("selectAllText",t)}get selectByClick(){return this._getOption("selectByClick")}set selectByClick(t){this._setOption("selectByClick",t)}get selectedExpr(){return this._getOption("selectedExpr")}set selectedExpr(t){this._setOption("selectedExpr",t)}get selectionMode(){return this._getOption("selectionMode")}set selectionMode(t){this._setOption("selectionMode",t)}get selectNodesRecursive(){return this._getOption("selectNodesRecursive")}set selectNodesRecursive(t){this._setOption("selectNodesRecursive",t)}get showCheckBoxesMode(){return this._getOption("showCheckBoxesMode")}set showCheckBoxesMode(t){this._setOption("showCheckBoxesMode",t)}get tabIndex(){return this._getOption("tabIndex")}set tabIndex(t){this._setOption("tabIndex",t)}get useNativeScrolling(){return this._getOption("useNativeScrolling")}set useNativeScrolling(t){this._setOption("useNativeScrolling",t)}get virtualModeEnabled(){return this._getOption("virtualModeEnabled")}set virtualModeEnabled(t){this._setOption("virtualModeEnabled",t)}get visible(){return this._getOption("visible")}set visible(t){this._setOption("visible",t)}get width(){return this._getOption("width")}set width(t){this._setOption("width",t)}onContentReady;onDisposing;onInitialized;onItemClick;onItemCollapsed;onItemContextMenu;onItemExpanded;onItemHold;onItemRendered;onItemSelectionChanged;onOptionChanged;onSelectAllValueChanged;onSelectionChanged;accessKeyChange;activeStateEnabledChange;animationEnabledChange;collapseIconChange;createChildrenChange;dataSourceChange;dataStructureChange;disabledChange;disabledExprChange;displayExprChange;elementAttrChange;expandAllEnabledChange;expandedExprChange;expandEventChange;expandIconChange;expandNodesRecursiveChange;focusStateEnabledChange;hasItemsExprChange;heightChange;hintChange;hoverStateEnabledChange;itemHoldTimeoutChange;itemsChange;itemsExprChange;itemTemplateChange;keyExprChange;noDataTextChange;parentIdExprChange;rootValueChange;rtlEnabledChange;scrollDirectionChange;searchEditorOptionsChange;searchEnabledChange;searchExprChange;searchModeChange;searchTimeoutChange;searchValueChange;selectAllTextChange;selectByClickChange;selectedExprChange;selectionModeChange;selectNodesRecursiveChange;showCheckBoxesModeChange;tabIndexChange;useNativeScrollingChange;virtualModeEnabledChange;visibleChange;widthChange;get itemsChildren(){return this._getOption("items")}set itemsChildren(t){this.setChildren("items",t)}constructor(t,n,o,s,r,a,l,d){super(t,n,o,s,l,d),this._watcherHelper=s,this._idh=r,this._createEventEmitters([{subscribe:"contentReady",emit:"onContentReady"},{subscribe:"disposing",emit:"onDisposing"},{subscribe:"initialized",emit:"onInitialized"},{subscribe:"itemClick",emit:"onItemClick"},{subscribe:"itemCollapsed",emit:"onItemCollapsed"},{subscribe:"itemContextMenu",emit:"onItemContextMenu"},{subscribe:"itemExpanded",emit:"onItemExpanded"},{subscribe:"itemHold",emit:"onItemHold"},{subscribe:"itemRendered",emit:"onItemRendered"},{subscribe:"itemSelectionChanged",emit:"onItemSelectionChanged"},{subscribe:"optionChanged",emit:"onOptionChanged"},{subscribe:"selectAllValueChanged",emit:"onSelectAllValueChanged"},{subscribe:"selectionChanged",emit:"onSelectionChanged"},{emit:"accessKeyChange"},{emit:"activeStateEnabledChange"},{emit:"animationEnabledChange"},{emit:"collapseIconChange"},{emit:"createChildrenChange"},{emit:"dataSourceChange"},{emit:"dataStructureChange"},{emit:"disabledChange"},{emit:"disabledExprChange"},{emit:"displayExprChange"},{emit:"elementAttrChange"},{emit:"expandAllEnabledChange"},{emit:"expandedExprChange"},{emit:"expandEventChange"},{emit:"expandIconChange"},{emit:"expandNodesRecursiveChange"},{emit:"focusStateEnabledChange"},{emit:"hasItemsExprChange"},{emit:"heightChange"},{emit:"hintChange"},{emit:"hoverStateEnabledChange"},{emit:"itemHoldTimeoutChange"},{emit:"itemsChange"},{emit:"itemsExprChange"},{emit:"itemTemplateChange"},{emit:"keyExprChange"},{emit:"noDataTextChange"},{emit:"parentIdExprChange"},{emit:"rootValueChange"},{emit:"rtlEnabledChange"},{emit:"scrollDirectionChange"},{emit:"searchEditorOptionsChange"},{emit:"searchEnabledChange"},{emit:"searchExprChange"},{emit:"searchModeChange"},{emit:"searchTimeoutChange"},{emit:"searchValueChange"},{emit:"selectAllTextChange"},{emit:"selectByClickChange"},{emit:"selectedExprChange"},{emit:"selectionModeChange"},{emit:"selectNodesRecursiveChange"},{emit:"showCheckBoxesModeChange"},{emit:"tabIndexChange"},{emit:"useNativeScrollingChange"},{emit:"virtualModeEnabledChange"},{emit:"visibleChange"},{emit:"widthChange"}]),this._idh.setHost(this),a.setHost(this)}_createInstance(t,n){return new es(t,n)}ngOnDestroy(){this._destroyWidget()}ngOnChanges(t){super.ngOnChanges(t),this.setupChanges("dataSource",t),this.setupChanges("items",t),this.setupChanges("searchExpr",t)}setupChanges(t,n){t in this._optionsToUpdate||this._idh.setup(t,n)}ngDoCheck(){this._idh.doCheck("dataSource"),this._idh.doCheck("items"),this._idh.doCheck("searchExpr"),this._watcherHelper.checkWatchers(),super.ngDoCheck(),super.clearChangedOptions()}_setOption(t,n){let o=this._idh.setupSingle(t,n),s=this._idh.getChanges(t,n)!==null;(o||s)&&super._setOption(t,n)}static \u0275fac=function(n){return new(n||i)(E(Pe),E(Ge),E(ee),E(ae),E(Se),E(k),E(je),E(Je))};static \u0275cmp=te({type:i,selectors:[["dx-tree-view"]],contentQueries:function(n,o,s){if(n&1&&ke(s,qn,4),n&2){let r;Be(r=Ve())&&(o.itemsChildren=r)}},inputs:{accessKey:"accessKey",activeStateEnabled:"activeStateEnabled",animationEnabled:"animationEnabled",collapseIcon:"collapseIcon",createChildren:"createChildren",dataSource:"dataSource",dataStructure:"dataStructure",disabled:"disabled",disabledExpr:"disabledExpr",displayExpr:"displayExpr",elementAttr:"elementAttr",expandAllEnabled:"expandAllEnabled",expandedExpr:"expandedExpr",expandEvent:"expandEvent",expandIcon:"expandIcon",expandNodesRecursive:"expandNodesRecursive",focusStateEnabled:"focusStateEnabled",hasItemsExpr:"hasItemsExpr",height:"height",hint:"hint",hoverStateEnabled:"hoverStateEnabled",itemHoldTimeout:"itemHoldTimeout",items:"items",itemsExpr:"itemsExpr",itemTemplate:"itemTemplate",keyExpr:"keyExpr",noDataText:"noDataText",parentIdExpr:"parentIdExpr",rootValue:"rootValue",rtlEnabled:"rtlEnabled",scrollDirection:"scrollDirection",searchEditorOptions:"searchEditorOptions",searchEnabled:"searchEnabled",searchExpr:"searchExpr",searchMode:"searchMode",searchTimeout:"searchTimeout",searchValue:"searchValue",selectAllText:"selectAllText",selectByClick:"selectByClick",selectedExpr:"selectedExpr",selectionMode:"selectionMode",selectNodesRecursive:"selectNodesRecursive",showCheckBoxesMode:"showCheckBoxesMode",tabIndex:"tabIndex",useNativeScrolling:"useNativeScrolling",virtualModeEnabled:"virtualModeEnabled",visible:"visible",width:"width"},outputs:{onContentReady:"onContentReady",onDisposing:"onDisposing",onInitialized:"onInitialized",onItemClick:"onItemClick",onItemCollapsed:"onItemCollapsed",onItemContextMenu:"onItemContextMenu",onItemExpanded:"onItemExpanded",onItemHold:"onItemHold",onItemRendered:"onItemRendered",onItemSelectionChanged:"onItemSelectionChanged",onOptionChanged:"onOptionChanged",onSelectAllValueChanged:"onSelectAllValueChanged",onSelectionChanged:"onSelectionChanged",accessKeyChange:"accessKeyChange",activeStateEnabledChange:"activeStateEnabledChange",animationEnabledChange:"animationEnabledChange",collapseIconChange:"collapseIconChange",createChildrenChange:"createChildrenChange",dataSourceChange:"dataSourceChange",dataStructureChange:"dataStructureChange",disabledChange:"disabledChange",disabledExprChange:"disabledExprChange",displayExprChange:"displayExprChange",elementAttrChange:"elementAttrChange",expandAllEnabledChange:"expandAllEnabledChange",expandedExprChange:"expandedExprChange",expandEventChange:"expandEventChange",expandIconChange:"expandIconChange",expandNodesRecursiveChange:"expandNodesRecursiveChange",focusStateEnabledChange:"focusStateEnabledChange",hasItemsExprChange:"hasItemsExprChange",heightChange:"heightChange",hintChange:"hintChange",hoverStateEnabledChange:"hoverStateEnabledChange",itemHoldTimeoutChange:"itemHoldTimeoutChange",itemsChange:"itemsChange",itemsExprChange:"itemsExprChange",itemTemplateChange:"itemTemplateChange",keyExprChange:"keyExprChange",noDataTextChange:"noDataTextChange",parentIdExprChange:"parentIdExprChange",rootValueChange:"rootValueChange",rtlEnabledChange:"rtlEnabledChange",scrollDirectionChange:"scrollDirectionChange",searchEditorOptionsChange:"searchEditorOptionsChange",searchEnabledChange:"searchEnabledChange",searchExprChange:"searchExprChange",searchModeChange:"searchModeChange",searchTimeoutChange:"searchTimeoutChange",searchValueChange:"searchValueChange",selectAllTextChange:"selectAllTextChange",selectByClickChange:"selectByClickChange",selectedExprChange:"selectedExprChange",selectionModeChange:"selectionModeChange",selectNodesRecursiveChange:"selectNodesRecursiveChange",showCheckBoxesModeChange:"showCheckBoxesModeChange",tabIndexChange:"tabIndexChange",useNativeScrollingChange:"useNativeScrollingChange",virtualModeEnabledChange:"virtualModeEnabledChange",visibleChange:"visibleChange",widthChange:"widthChange"},standalone:!1,features:[le([ee,ae,k,Se]),J,Ze],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return i})(),Q7=(()=>{class i{static \u0275fac=function(n){return new(n||i)};static \u0275mod=L({type:i});static \u0275inj=V({imports:[Ti,px,ei,Mi,qe,ye,Ti,px,ei,Mi,ye]})}return i})();var Z7=["*"];function J7(i,e){if(i&1&&cs(0,"tis-svg",4),i&2){let t=nn();mE(t.variant),mt("icon",t.icon)}}function eJ(i,e){i&1&&_i(0,0,["*ngIf","!label"])}function tJ(i,e){if(i&1&&cs(0,"tis-svg",4),i&2){let t=nn();mt("icon",t.iconRight)}}var lCt=(()=>{class i{constructor(){this.label="",this.variant="default",this.stylingMode="contained",this.fullWidth=!1,this.fullHeight=!1,this.focusStateEnabled=!0,this.isIcon=!1,this.font="default",this.disabled=!1,this.clicked=new un,this.tabindex=-1}get width(){return this.fullWidth?"100%":null}get isIconButton(){return this.isIcon||!!this.icon&&!this.label&&!this.iconRight||!!this.iconRight&&!this.label&&!this.icon||typeof this.label=="number"}get buttonClasses(){return{[`dx-custom-button-font-${this.font}`]:!0,[`dx-custom-button-${this.variant}`]:!0,[`dx-custom-button-${this.stylingMode}`]:!0,"dx-custom-button-with-icon":!!this.icon||!!this.iconRight,"dx-custom-button-without-label":!this.label,"dx-custom-button-icon-button":this.isIconButton}}click(t){this.clicked.emit(t.event)}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=te({type:i,selectors:[["tis-button"]],hostVars:3,hostBindings:function(n,o){n&2&&(Md("tabindex",o.tabindex),gE("width",o.width))},inputs:{label:"label",token:"token",variant:"variant",stylingMode:"stylingMode",fullWidth:"fullWidth",fullHeight:"fullHeight",focusStateEnabled:"focusStateEnabled",height:"height",isIcon:"isIcon",font:"font",icon:"icon",iconRight:"iconRight",disabled:"disabled"},outputs:{clicked:"clicked"},ngContentSelectors:Z7,decls:5,vars:11,consts:[[3,"onClick","disabled","ngClass","height","focusStateEnabled"],[3,"icon","class",4,"ngIf"],[4,"ngIf"],[3,"icon",4,"ngIf"],[3,"icon"]],template:function(n,o){n&1&&(fi(),ro(0,"dx-button",0),mi("onClick",function(r){return o.click(r)}),Gi(1,J7,1,3,"tis-svg",1),Ba(2),Gi(3,eJ,1,0,"ng-content",2)(4,tJ,1,1,"tis-svg",3),ao()),n&2&&(Gr("fullHeight",o.fullHeight),mt("disabled",o.disabled)("ngClass",o.buttonClasses)("height",o.height)("focusStateEnabled",o.focusStateEnabled),Md("data-token",o.token),Zt(),mt("ngIf",o.icon),Zt(),Ku(" ",o.label," "),Zt(),mt("ngIf",!o.label),Zt(),mt("ngIf",o.iconRight))},dependencies:[Na,ju,La,ub,cb,Yu],styles:[`tis-button{display:flex;width:fit-content}tis-button .dx-button{width:100%;height:var(--space-vertical-xxxxlnudge);padding:var(--space-vertical-s) var(--space-horizontal-l);font:var(--font-body-1-strong);white-space:nowrap;border-radius:var(--radius-medium);transition:all .2s}tis-button .dx-button.dx-custom-button-with-icon{padding:var(--space-vertical-s) var(--space-horizontal-m)}tis-button .dx-button.dx-custom-button-font-medium{font:var(--font-body-2-strong)}tis-button .dx-button.dx-custom-button-font-large{font:var(--font-title-3)}tis-button .dx-button.dx-custom-button-without-label{padding:var(--space-vertical-s) var(--space-horizontal-s)}tis-button .dx-button.dx-custom-button-icon-button{min-width:var(--space-vertical-xxxxlnudge);padding:var(--space-vertical-s) calc(var(--space-horizontal-s) - 1px)}tis-button .dx-button.fullHeight{height:100%}tis-button .dx-button .dx-button-content{display:flex;flex-shrink:0;flex-wrap:nowrap;gap:var(--space-horizontal-s);align-items:center;justify-content:center;width:fit-content;padding:0}tis-button .dx-custom-button-default.dx-custom-button-contained{color:var(--btn-default-contained-color);background-color:var(--btn-default-contained-bg-rest);border:1px solid var(--btn-default-contained-bg-rest)}tis-button .dx-custom-button-default.dx-custom-button-contained svg{fill:var(--btn-default-contained-color)}tis-button .dx-custom-button-default.dx-custom-button-contained:hover{color:var(--btn-default-contained-color);background-color:var(--btn-default-contained-bg-hover);border:1px solid var(--btn-default-contained-bg-hover)}tis-button .dx-custom-button-default.dx-custom-button-contained:focus{color:var(--btn-default-contained-color);background-color:var(--btn-default-contained-bg-focused);border:1px solid var(--btn-default-contained-bg-focused)}tis-button .dx-custom-button-default.dx-custom-button-contained:active{color:var(--btn-default-contained-color);background-color:var(--btn-default-contained-bg-active);border:1px solid var(--btn-default-contained-bg-active)}tis-button .dx-custom-button-default.dx-custom-button-contained.dx-state-disabled{color:var(--btn-default-contained-color-disabled);background-color:var(--btn-default-contained-bg-disabled);border:1px solid var(--btn-default-contained-bg-disabled)}tis-button .dx-custom-button-default.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-default-contained-color-disabled)}tis-button .dx-custom-button-default.dx-custom-button-outlined{color:var(--btn-default-outlined-color);background-color:var(--btn-default-outlined-bg-rest);border:1px solid var(--btn-default-outlined-stroke-rest)}tis-button .dx-custom-button-default.dx-custom-button-outlined svg{fill:var(--btn-default-outlined-color)}tis-button .dx-custom-button-default.dx-custom-button-outlined:hover{color:var(--btn-default-outlined-color);background-color:var(--btn-default-outlined-bg-hover);border:1px solid var(--btn-default-outlined-stroke-rest)}tis-button .dx-custom-button-default.dx-custom-button-outlined:focus{color:var(--btn-default-outlined-color);background-color:var(--btn-default-outlined-bg-focused);border:1px solid var(--btn-default-outlined-stroke-rest)}tis-button .dx-custom-button-default.dx-custom-button-outlined:active{color:var(--btn-default-outlined-color);background-color:var(--btn-default-outlined-bg-active);border:1px solid var(--btn-default-outlined-stroke-rest)}tis-button .dx-custom-button-default.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-default-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-default-outlined-stroke-disabled)}tis-button .dx-custom-button-default.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-default-outlined-color-disabled)}tis-button .dx-custom-button-default.dx-custom-button-ghost{color:var(--btn-default-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-default.dx-custom-button-ghost svg{fill:var(--btn-default-ghost-color)}tis-button .dx-custom-button-default.dx-custom-button-ghost:hover{color:var(--btn-default-ghost-color);background-color:var(--btn-default-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-default.dx-custom-button-ghost:focus{color:var(--btn-default-ghost-color);background-color:var(--btn-default-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-default.dx-custom-button-ghost:active{color:var(--btn-default-ghost-color);background-color:var(--btn-default-ghost-bg-active);border:transparent}tis-button .dx-custom-button-default.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-default-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-default.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-default-ghost-color-disabled)}tis-button .dx-custom-button-secondary.dx-custom-button-contained{color:var(--btn-secondary-contained-color);background-color:var(--btn-secondary-contained-bg-rest);border:1px solid var(--btn-secondary-contained-bg-rest)}tis-button .dx-custom-button-secondary.dx-custom-button-contained svg{fill:var(--btn-secondary-contained-color)}tis-button .dx-custom-button-secondary.dx-custom-button-contained:hover{color:var(--btn-secondary-contained-color);background-color:var(--btn-secondary-contained-bg-hover);border:1px solid var(--btn-secondary-contained-bg-hover)}tis-button .dx-custom-button-secondary.dx-custom-button-contained:focus{color:var(--btn-secondary-contained-color);background-color:var(--btn-secondary-contained-bg-focused);border:1px solid var(--btn-secondary-contained-bg-focused)}tis-button .dx-custom-button-secondary.dx-custom-button-contained:active{color:var(--btn-secondary-contained-color);background-color:var(--btn-secondary-contained-bg-active);border:1px solid var(--btn-secondary-contained-bg-active)}tis-button .dx-custom-button-secondary.dx-custom-button-contained.dx-state-disabled{color:var(--btn-secondary-contained-color-disabled);background-color:var(--btn-secondary-contained-bg-disabled);border:1px solid var(--btn-secondary-contained-bg-disabled)}tis-button .dx-custom-button-secondary.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-secondary-contained-color-disabled)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined{color:var(--btn-secondary-outlined-color);background-color:var(--btn-secondary-outlined-bg-rest);border:1px solid var(--btn-secondary-outlined-stroke-rest)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined svg{fill:var(--btn-secondary-outlined-color)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined:hover{color:var(--btn-secondary-outlined-color);background-color:var(--btn-secondary-outlined-bg-hover);border:1px solid var(--btn-secondary-outlined-stroke-rest)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined:focus{color:var(--btn-secondary-outlined-color);background-color:var(--btn-secondary-outlined-bg-focused);border:1px solid var(--btn-secondary-outlined-stroke-rest)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined:active{color:var(--btn-secondary-outlined-color);background-color:var(--btn-secondary-outlined-bg-active);border:1px solid var(--btn-secondary-outlined-stroke-rest)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-secondary-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-secondary-outlined-stroke-disabled)}tis-button .dx-custom-button-secondary.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-secondary-outlined-color-disabled)}tis-button .dx-custom-button-secondary.dx-custom-button-ghost{color:var(--btn-secondary-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-secondary.dx-custom-button-ghost svg{fill:var(--btn-secondary-ghost-color)}tis-button .dx-custom-button-secondary.dx-custom-button-ghost:hover{color:var(--btn-secondary-ghost-color);background-color:var(--btn-secondary-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-secondary.dx-custom-button-ghost:focus{color:var(--btn-secondary-ghost-color);background-color:var(--btn-secondary-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-secondary.dx-custom-button-ghost:active{color:var(--btn-secondary-ghost-color);background-color:var(--btn-secondary-ghost-bg-active);border:transparent}tis-button .dx-custom-button-secondary.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-secondary-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-secondary.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-secondary-ghost-color-disabled)}tis-button .dx-custom-button-alternative.dx-custom-button-contained{color:var(--btn-alternative-contained-color);background-color:var(--btn-alternative-contained-bg-rest);border:1px solid var(--btn-alternative-contained-bg-rest)}tis-button .dx-custom-button-alternative.dx-custom-button-contained svg{fill:var(--btn-alternative-contained-color)}tis-button .dx-custom-button-alternative.dx-custom-button-contained:hover{color:var(--btn-alternative-contained-color);background-color:var(--btn-alternative-contained-bg-hover);border:1px solid var(--btn-alternative-contained-bg-hover)}tis-button .dx-custom-button-alternative.dx-custom-button-contained:focus{color:var(--btn-alternative-contained-color);background-color:var(--btn-alternative-contained-bg-focused);border:1px solid var(--btn-alternative-contained-bg-focused)}tis-button .dx-custom-button-alternative.dx-custom-button-contained:active{color:var(--btn-alternative-contained-color);background-color:var(--btn-alternative-contained-bg-active);border:1px solid var(--btn-alternative-contained-bg-active)}tis-button .dx-custom-button-alternative.dx-custom-button-contained.dx-state-disabled{color:var(--btn-alternative-contained-color-disabled);background-color:var(--btn-alternative-contained-bg-disabled);border:1px solid var(--btn-alternative-contained-bg-disabled)}tis-button .dx-custom-button-alternative.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-alternative-contained-color-disabled)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined{color:var(--btn-alternative-outlined-color);background-color:var(--btn-alternative-outlined-bg-rest);border:1px solid var(--btn-alternative-outlined-stroke-rest)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined svg{fill:var(--btn-alternative-outlined-color)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined:hover{color:var(--btn-alternative-outlined-color);background-color:var(--btn-alternative-outlined-bg-hover);border:1px solid var(--btn-alternative-outlined-stroke-rest)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined:focus{color:var(--btn-alternative-outlined-color);background-color:var(--btn-alternative-outlined-bg-focused);border:1px solid var(--btn-alternative-outlined-stroke-rest)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined:active{color:var(--btn-alternative-outlined-color);background-color:var(--btn-alternative-outlined-bg-active);border:1px solid var(--btn-alternative-outlined-stroke-rest)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-alternative-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-alternative-outlined-stroke-disabled)}tis-button .dx-custom-button-alternative.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-alternative-outlined-color-disabled)}tis-button .dx-custom-button-alternative.dx-custom-button-ghost{color:var(--btn-alternative-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-alternative.dx-custom-button-ghost svg{fill:var(--btn-alternative-ghost-color)}tis-button .dx-custom-button-alternative.dx-custom-button-ghost:hover{color:var(--btn-alternative-ghost-color);background-color:var(--btn-alternative-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-alternative.dx-custom-button-ghost:focus{color:var(--btn-alternative-ghost-color);background-color:var(--btn-alternative-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-alternative.dx-custom-button-ghost:active{color:var(--btn-alternative-ghost-color);background-color:var(--btn-alternative-ghost-bg-active);border:transparent}tis-button .dx-custom-button-alternative.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-alternative-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-alternative.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-alternative-ghost-color-disabled)}tis-button .dx-custom-button-success.dx-custom-button-contained{color:var(--btn-success-contained-color);background-color:var(--btn-success-contained-bg-rest);border:1px solid var(--btn-success-contained-bg-rest)}tis-button .dx-custom-button-success.dx-custom-button-contained svg{fill:var(--btn-success-contained-color)}tis-button .dx-custom-button-success.dx-custom-button-contained:hover{color:var(--btn-success-contained-color);background-color:var(--btn-success-contained-bg-hover);border:1px solid var(--btn-success-contained-bg-hover)}tis-button .dx-custom-button-success.dx-custom-button-contained:focus{color:var(--btn-success-contained-color);background-color:var(--btn-success-contained-bg-focused);border:1px solid var(--btn-success-contained-bg-focused)}tis-button .dx-custom-button-success.dx-custom-button-contained:active{color:var(--btn-success-contained-color);background-color:var(--btn-success-contained-bg-active);border:1px solid var(--btn-success-contained-bg-active)}tis-button .dx-custom-button-success.dx-custom-button-contained.dx-state-disabled{color:var(--btn-success-contained-color-disabled);background-color:var(--btn-success-contained-bg-disabled);border:1px solid var(--btn-success-contained-bg-disabled)}tis-button .dx-custom-button-success.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-success-contained-color-disabled)}tis-button .dx-custom-button-success.dx-custom-button-outlined{color:var(--btn-success-outlined-color);background-color:var(--btn-success-outlined-bg-rest);border:1px solid var(--btn-success-outlined-stroke-rest)}tis-button .dx-custom-button-success.dx-custom-button-outlined svg{fill:var(--btn-success-outlined-color)}tis-button .dx-custom-button-success.dx-custom-button-outlined:hover{color:var(--btn-success-outlined-color);background-color:var(--btn-success-outlined-bg-hover);border:1px solid var(--btn-success-outlined-stroke-rest)}tis-button .dx-custom-button-success.dx-custom-button-outlined:focus{color:var(--btn-success-outlined-color);background-color:var(--btn-success-outlined-bg-focused);border:1px solid var(--btn-success-outlined-stroke-rest)}tis-button .dx-custom-button-success.dx-custom-button-outlined:active{color:var(--btn-success-outlined-color);background-color:var(--btn-success-outlined-bg-active);border:1px solid var(--btn-success-outlined-stroke-rest)}tis-button .dx-custom-button-success.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-success-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-success-outlined-stroke-disabled)}tis-button .dx-custom-button-success.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-success-outlined-color-disabled)}tis-button .dx-custom-button-success.dx-custom-button-ghost{color:var(--btn-success-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-success.dx-custom-button-ghost svg{fill:var(--btn-success-ghost-color)}tis-button .dx-custom-button-success.dx-custom-button-ghost:hover{color:var(--btn-success-ghost-color);background-color:var(--btn-success-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-success.dx-custom-button-ghost:focus{color:var(--btn-success-ghost-color);background-color:var(--btn-success-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-success.dx-custom-button-ghost:active{color:var(--btn-success-ghost-color);background-color:var(--btn-success-ghost-bg-active);border:transparent}tis-button .dx-custom-button-success.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-success-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-success.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-success-ghost-color-disabled)}tis-button .dx-custom-button-info.dx-custom-button-contained{color:var(--btn-info-contained-color);background-color:var(--btn-info-contained-bg-rest);border:1px solid var(--btn-info-contained-bg-rest)}tis-button .dx-custom-button-info.dx-custom-button-contained svg{fill:var(--btn-info-contained-color)}tis-button .dx-custom-button-info.dx-custom-button-contained:hover{color:var(--btn-info-contained-color);background-color:var(--btn-info-contained-bg-hover);border:1px solid var(--btn-info-contained-bg-hover)}tis-button .dx-custom-button-info.dx-custom-button-contained:focus{color:var(--btn-info-contained-color);background-color:var(--btn-info-contained-bg-focused);border:1px solid var(--btn-info-contained-bg-focused)}tis-button .dx-custom-button-info.dx-custom-button-contained:active{color:var(--btn-info-contained-color);background-color:var(--btn-info-contained-bg-active);border:1px solid var(--btn-info-contained-bg-active)}tis-button .dx-custom-button-info.dx-custom-button-contained.dx-state-disabled{color:var(--btn-info-contained-color-disabled);background-color:var(--btn-info-contained-bg-disabled);border:1px solid var(--btn-info-contained-bg-disabled)}tis-button .dx-custom-button-info.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-info-contained-color-disabled)}tis-button .dx-custom-button-info.dx-custom-button-outlined{color:var(--btn-info-outlined-color);background-color:var(--btn-info-outlined-bg-rest);border:1px solid var(--btn-info-outlined-stroke-rest)}tis-button .dx-custom-button-info.dx-custom-button-outlined svg{fill:var(--btn-info-outlined-color)}tis-button .dx-custom-button-info.dx-custom-button-outlined:hover{color:var(--btn-info-outlined-color);background-color:var(--btn-info-outlined-bg-hover);border:1px solid var(--btn-info-outlined-stroke-rest)}tis-button .dx-custom-button-info.dx-custom-button-outlined:focus{color:var(--btn-info-outlined-color);background-color:var(--btn-info-outlined-bg-focused);border:1px solid var(--btn-info-outlined-stroke-rest)}tis-button .dx-custom-button-info.dx-custom-button-outlined:active{color:var(--btn-info-outlined-color);background-color:var(--btn-info-outlined-bg-active);border:1px solid var(--btn-info-outlined-stroke-rest)}tis-button .dx-custom-button-info.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-info-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-info-outlined-stroke-disabled)}tis-button .dx-custom-button-info.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-info-outlined-color-disabled)}tis-button .dx-custom-button-info.dx-custom-button-ghost{color:var(--btn-info-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-info.dx-custom-button-ghost svg{fill:var(--btn-info-ghost-color)}tis-button .dx-custom-button-info.dx-custom-button-ghost:hover{color:var(--btn-info-ghost-color);background-color:var(--btn-info-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-info.dx-custom-button-ghost:focus{color:var(--btn-info-ghost-color);background-color:var(--btn-info-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-info.dx-custom-button-ghost:active{color:var(--btn-info-ghost-color);background-color:var(--btn-info-ghost-bg-active);border:transparent}tis-button .dx-custom-button-info.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-info-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-info.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-info-ghost-color-disabled)}tis-button .dx-custom-button-warning.dx-custom-button-contained{color:var(--btn-warning-contained-color);background-color:var(--btn-warning-contained-bg-rest);border:1px solid var(--btn-warning-contained-bg-rest)}tis-button .dx-custom-button-warning.dx-custom-button-contained svg{fill:var(--btn-warning-contained-color)}tis-button .dx-custom-button-warning.dx-custom-button-contained:hover{color:var(--btn-warning-contained-color);background-color:var(--btn-warning-contained-bg-hover);border:1px solid var(--btn-warning-contained-bg-hover)}tis-button .dx-custom-button-warning.dx-custom-button-contained:focus{color:var(--btn-warning-contained-color);background-color:var(--btn-warning-contained-bg-focused);border:1px solid var(--btn-warning-contained-bg-focused)}tis-button .dx-custom-button-warning.dx-custom-button-contained:active{color:var(--btn-warning-contained-color);background-color:var(--btn-warning-contained-bg-active);border:1px solid var(--btn-warning-contained-bg-active)}tis-button .dx-custom-button-warning.dx-custom-button-contained.dx-state-disabled{color:var(--btn-warning-contained-color-disabled);background-color:var(--btn-warning-contained-bg-disabled);border:1px solid var(--btn-warning-contained-bg-disabled)}tis-button .dx-custom-button-warning.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-warning-contained-color-disabled)}tis-button .dx-custom-button-warning.dx-custom-button-outlined{color:var(--btn-warning-outlined-color);background-color:var(--btn-warning-outlined-bg-rest);border:1px solid var(--btn-warning-outlined-stroke-rest)}tis-button .dx-custom-button-warning.dx-custom-button-outlined svg{fill:var(--btn-warning-outlined-color)}tis-button .dx-custom-button-warning.dx-custom-button-outlined:hover{color:var(--btn-warning-outlined-color);background-color:var(--btn-warning-outlined-bg-hover);border:1px solid var(--btn-warning-outlined-stroke-rest)}tis-button .dx-custom-button-warning.dx-custom-button-outlined:focus{color:var(--btn-warning-outlined-color);background-color:var(--btn-warning-outlined-bg-focused);border:1px solid var(--btn-warning-outlined-stroke-rest)}tis-button .dx-custom-button-warning.dx-custom-button-outlined:active{color:var(--btn-warning-outlined-color);background-color:var(--btn-warning-outlined-bg-active);border:1px solid var(--btn-warning-outlined-stroke-rest)}tis-button .dx-custom-button-warning.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-warning-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-warning-outlined-stroke-disabled)}tis-button .dx-custom-button-warning.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-warning-outlined-color-disabled)}tis-button .dx-custom-button-warning.dx-custom-button-ghost{color:var(--btn-warning-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-warning.dx-custom-button-ghost svg{fill:var(--btn-warning-ghost-color)}tis-button .dx-custom-button-warning.dx-custom-button-ghost:hover{color:var(--btn-warning-ghost-color);background-color:var(--btn-warning-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-warning.dx-custom-button-ghost:focus{color:var(--btn-warning-ghost-color);background-color:var(--btn-warning-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-warning.dx-custom-button-ghost:active{color:var(--btn-warning-ghost-color);background-color:var(--btn-warning-ghost-bg-active);border:transparent}tis-button .dx-custom-button-warning.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-warning-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-warning.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-warning-ghost-color-disabled)}tis-button .dx-custom-button-danger.dx-custom-button-contained{color:var(--btn-danger-contained-color);background-color:var(--btn-danger-contained-bg-rest);border:1px solid var(--btn-danger-contained-bg-rest)}tis-button .dx-custom-button-danger.dx-custom-button-contained svg{fill:var(--btn-danger-contained-color)}tis-button .dx-custom-button-danger.dx-custom-button-contained:hover{color:var(--btn-danger-contained-color);background-color:var(--btn-danger-contained-bg-hover);border:1px solid var(--btn-danger-contained-bg-hover)}tis-button .dx-custom-button-danger.dx-custom-button-contained:focus{color:var(--btn-danger-contained-color);background-color:var(--btn-danger-contained-bg-focused);border:1px solid var(--btn-danger-contained-bg-focused)}tis-button .dx-custom-button-danger.dx-custom-button-contained:active{color:var(--btn-danger-contained-color);background-color:var(--btn-danger-contained-bg-active);border:1px solid var(--btn-danger-contained-bg-active)}tis-button .dx-custom-button-danger.dx-custom-button-contained.dx-state-disabled{color:var(--btn-danger-contained-color-disabled);background-color:var(--btn-danger-contained-bg-disabled);border:1px solid var(--btn-danger-contained-bg-disabled)}tis-button .dx-custom-button-danger.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-danger-contained-color-disabled)}tis-button .dx-custom-button-danger.dx-custom-button-outlined{color:var(--btn-danger-outlined-color);background-color:var(--btn-danger-outlined-bg-rest);border:1px solid var(--btn-danger-outlined-stroke-rest)}tis-button .dx-custom-button-danger.dx-custom-button-outlined svg{fill:var(--btn-danger-outlined-color)}tis-button .dx-custom-button-danger.dx-custom-button-outlined:hover{color:var(--btn-danger-outlined-color);background-color:var(--btn-danger-outlined-bg-hover);border:1px solid var(--btn-danger-outlined-stroke-rest)}tis-button .dx-custom-button-danger.dx-custom-button-outlined:focus{color:var(--btn-danger-outlined-color);background-color:var(--btn-danger-outlined-bg-focused);border:1px solid var(--btn-danger-outlined-stroke-rest)}tis-button .dx-custom-button-danger.dx-custom-button-outlined:active{color:var(--btn-danger-outlined-color);background-color:var(--btn-danger-outlined-bg-active);border:1px solid var(--btn-danger-outlined-stroke-rest)}tis-button .dx-custom-button-danger.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-danger-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-danger-outlined-stroke-disabled)}tis-button .dx-custom-button-danger.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-danger-outlined-color-disabled)}tis-button .dx-custom-button-danger.dx-custom-button-ghost{color:var(--btn-danger-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-danger.dx-custom-button-ghost svg{fill:var(--btn-danger-ghost-color)}tis-button .dx-custom-button-danger.dx-custom-button-ghost:hover{color:var(--btn-danger-ghost-color);background-color:var(--btn-danger-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-danger.dx-custom-button-ghost:focus{color:var(--btn-danger-ghost-color);background-color:var(--btn-danger-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-danger.dx-custom-button-ghost:active{color:var(--btn-danger-ghost-color);background-color:var(--btn-danger-ghost-bg-active);border:transparent}tis-button .dx-custom-button-danger.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-danger-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-danger.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-danger-ghost-color-disabled)}tis-button .dx-custom-button-help.dx-custom-button-contained{color:var(--btn-help-contained-color);background-color:var(--btn-help-contained-bg-rest);border:1px solid var(--btn-help-contained-bg-rest)}tis-button .dx-custom-button-help.dx-custom-button-contained svg{fill:var(--btn-help-contained-color)}tis-button .dx-custom-button-help.dx-custom-button-contained:hover{color:var(--btn-help-contained-color);background-color:var(--btn-help-contained-bg-hover);border:1px solid var(--btn-help-contained-bg-hover)}tis-button .dx-custom-button-help.dx-custom-button-contained:focus{color:var(--btn-help-contained-color);background-color:var(--btn-help-contained-bg-focused);border:1px solid var(--btn-help-contained-bg-focused)}tis-button .dx-custom-button-help.dx-custom-button-contained:active{color:var(--btn-help-contained-color);background-color:var(--btn-help-contained-bg-active);border:1px solid var(--btn-help-contained-bg-active)}tis-button .dx-custom-button-help.dx-custom-button-contained.dx-state-disabled{color:var(--btn-help-contained-color-disabled);background-color:var(--btn-help-contained-bg-disabled);border:1px solid var(--btn-help-contained-bg-disabled)}tis-button .dx-custom-button-help.dx-custom-button-contained.dx-state-disabled svg{fill:var(--btn-help-contained-color-disabled)}tis-button .dx-custom-button-help.dx-custom-button-outlined{color:var(--btn-help-outlined-color);background-color:var(--btn-help-outlined-bg-rest);border:1px solid var(--btn-help-outlined-stroke-rest)}tis-button .dx-custom-button-help.dx-custom-button-outlined svg{fill:var(--btn-help-outlined-color)}tis-button .dx-custom-button-help.dx-custom-button-outlined:hover{color:var(--btn-help-outlined-color);background-color:var(--btn-help-outlined-bg-hover);border:1px solid var(--btn-help-outlined-stroke-rest)}tis-button .dx-custom-button-help.dx-custom-button-outlined:focus{color:var(--btn-help-outlined-color);background-color:var(--btn-help-outlined-bg-focused);border:1px solid var(--btn-help-outlined-stroke-rest)}tis-button .dx-custom-button-help.dx-custom-button-outlined:active{color:var(--btn-help-outlined-color);background-color:var(--btn-help-outlined-bg-active);border:1px solid var(--btn-help-outlined-stroke-rest)}tis-button .dx-custom-button-help.dx-custom-button-outlined.dx-state-disabled{color:var(--btn-help-outlined-color-disabled);background-color:transparent;border:1px solid var(--btn-help-outlined-stroke-disabled)}tis-button .dx-custom-button-help.dx-custom-button-outlined.dx-state-disabled svg{fill:var(--btn-help-outlined-color-disabled)}tis-button .dx-custom-button-help.dx-custom-button-ghost{color:var(--btn-help-ghost-color);background-color:transparent;border:transparent}tis-button .dx-custom-button-help.dx-custom-button-ghost svg{fill:var(--btn-help-ghost-color)}tis-button .dx-custom-button-help.dx-custom-button-ghost:hover{color:var(--btn-help-ghost-color);background-color:var(--btn-help-ghost-bg-hover);border:transparent}tis-button .dx-custom-button-help.dx-custom-button-ghost:focus{color:var(--btn-help-ghost-color);background-color:var(--btn-help-ghost-bg-focused);border:transparent}tis-button .dx-custom-button-help.dx-custom-button-ghost:active{color:var(--btn-help-ghost-color);background-color:var(--btn-help-ghost-bg-active);border:transparent}tis-button .dx-custom-button-help.dx-custom-button-ghost.dx-state-disabled{color:var(--btn-help-ghost-color-disabled);background-color:transparent;border:transparent}tis-button .dx-custom-button-help.dx-custom-button-ghost.dx-state-disabled svg{fill:var(--btn-help-ghost-color-disabled)}
`],encapsulation:2,changeDetection:0})}}return i})();function iJ(i,e){i&1&&cs(0,"div",6)}function nJ(i,e){i&1&&Pa(0)}function oJ(i,e){if(i&1&&(ro(0,"div",7),Gi(1,nJ,1,0,"ng-container",8),ao()),i&2){nn();let t=ka(9);Zt(),mt("ngTemplateOutlet",t)}}function sJ(i,e){i&1&&Pa(0)}function rJ(i,e){if(i&1&&(ro(0,"div",7),Gi(1,sJ,1,0,"ng-container",8),ao()),i&2){nn();let t=ka(9);Zt(),mt("ngTemplateOutlet",t)}}function aJ(i,e){i&1&&cs(0,"div",4)}function lJ(i,e){i&1&&Pa(0)}function dJ(i,e){if(i&1&&(ro(0,"div",7),Gi(1,lJ,1,0,"ng-container",8),ao()),i&2){nn();let t=ka(9);Zt(),mt("ngTemplateOutlet",t)}}function cJ(i,e){i&1&&cs(0,"div",6)}function uJ(i,e){if(i&1&&cs(0,"tis-svg",11),i&2){let t=nn(2);mt("icon",t.icon)}}function hJ(i,e){if(i&1&&(ro(0,"div",12),Ba(1),ao()),i&2){let t=nn(2);Gr("label-bold",t.labelBold),Zt(),CE(t.text)}}function pJ(i,e){if(i&1&&Gi(0,uJ,1,1,"tis-svg",9)(1,hJ,2,3,"div",10),i&2){let t=nn();mt("ngIf",t.icon),Zt(),mt("ngIf",t.text)}}var hCt=(()=>{class i{constructor(){this.margin="small",this.position="left",this.labelBold=!1}get isLeftContent(){return this.position==="left"&&(!!this.icon||!!this.text)}get isCenterContent(){return this.position==="center"&&(!!this.icon||!!this.text)}get isRightContent(){return this.position==="right"&&(!!this.icon||!!this.text)}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=te({type:i,selectors:[["tis-divider"]],inputs:{margin:"margin",position:"position",labelBold:"labelBold",icon:"icon",text:"text"},decls:10,vars:7,consts:[["content",""],[1,"divider-wrapper",3,"ngClass"],["class","divider-mark",4,"ngIf"],["class","content",4,"ngIf"],[1,"divider"],["class","divider",4,"ngIf"],[1,"divider-mark"],[1,"content"],[4,"ngTemplateOutlet"],["class","icon",3,"icon",4,"ngIf"],["class","text",3,"label-bold",4,"ngIf"],[1,"icon",3,"icon"],[1,"text"]],template:function(n,o){n&1&&(ro(0,"div",1),Gi(1,iJ,1,0,"div",2)(2,oJ,2,1,"div",3),cs(3,"div",4),Gi(4,rJ,2,1,"div",3)(5,aJ,1,0,"div",5)(6,dJ,2,1,"div",3)(7,cJ,1,0,"div",2),ao(),Gi(8,pJ,2,2,"ng-template",null,0,Uu)),n&2&&(mt("ngClass",o.margin),Zt(),mt("ngIf",o.isLeftContent),Zt(),mt("ngIf",o.isLeftContent),Zt(2),mt("ngIf",o.isCenterContent),Zt(),mt("ngIf",o.isCenterContent),Zt(),mt("ngIf",o.isRightContent),Zt(),mt("ngIf",o.isRightContent))},dependencies:[Na,ju,La,qu,Yu],styles:["[_nghost-%COMP%]{display:block;width:100%}.divider-wrapper[_ngcontent-%COMP%]{display:flex;flex-wrap:nowrap;gap:8px;align-items:center;width:100%}.divider-wrapper.small[_ngcontent-%COMP%]{margin:4px 0}.divider-wrapper.medium[_ngcontent-%COMP%]{margin:12px 0}.divider-wrapper.large[_ngcontent-%COMP%]{margin:16px 0}.divider-mark[_ngcontent-%COMP%]{width:8px;height:1px;background:var(--divider-stroke-rest)}.divider[_ngcontent-%COMP%]{width:100%;height:1px;background:var(--divider-stroke-rest);margin:0}.content[_ngcontent-%COMP%]{display:flex;flex-wrap:nowrap;font:var(--font-caption-1);white-space:nowrap;gap:4px;align-items:center}.text[_ngcontent-%COMP%]{white-space:nowrap;color:var(--divider-color-rest)}.label-bold[_ngcontent-%COMP%]{font:var(--font-subtitle-2)}.icon[_ngcontent-%COMP%]{fill:var(--divider-color-rest)}"],changeDetection:0})}}return i})();var gJ=()=>({}),mJ=i=>({class:i});function fJ(i,e){i&1&&Pa(0)}function _J(i,e){if(i&1&&(fE(0),Gi(1,fJ,1,0,"ng-container",5),_E()),i&2){let t=nn(3);Zt(),mt("ngTemplateOutlet",t.template)}}function CJ(i,e){if(i&1&&Ba(0),i&2){let t=nn(3);Ku(" ",t.stringContent," ")}}function xJ(i,e){if(i&1&&(ro(0,"div"),Gi(1,_J,2,1,"ng-container",4)(2,CJ,1,1,"ng-template",null,0,Uu),ao()),i&2){let t=ka(3),n=nn(2);Zt(),mt("ngIf",n.template)("ngIfElse",t)}}function vJ(i,e){if(i&1&&(ro(0,"dx-tooltip",2),Gi(1,xJ,4,2,"div",3),ao()),i&2){let t=nn();mt("target",t.target)("position",t.position)("visible",t.visible)("animation",xE(6,gJ))("wrapperAttr",vE(7,mJ,"dx-custom-tooltip "+t.position)),Zt(),mt("dxTemplateOf","tooltipContent")}}var fCt=(()=>{class i{constructor(){this.position="top",this.visible=!1}get template(){return typeof this.content=="string"||typeof this.content=="number"?null:this.content}get stringContent(){return typeof this.content=="string"?this.content.trim():null}get target(){return typeof this.for=="string"?`#${this.for}`:this.for}static{this.\u0275fac=function(n){return new(n||i)}}static{this.\u0275cmp=te({type:i,selectors:[["tis-tooltip"]],inputs:{for:"for",content:"content",position:"position",visible:"visible"},decls:1,vars:1,consts:[["string",""],["contentTemplate","tooltipContent","showEvent","dxhoverstart","hideEvent","dxhoverend",3,"target","position","visible","animation","wrapperAttr",4,"ngIf"],["contentTemplate","tooltipContent","showEvent","dxhoverstart","hideEvent","dxhoverend",3,"target","position","visible","animation","wrapperAttr"],[4,"dxTemplate","dxTemplateOf"],[4,"ngIf","ngIfElse"],[4,"ngTemplateOutlet"]],template:function(n,o){n&1&&Gi(0,vJ,2,9,"dx-tooltip",1),n&2&&mt("ngIf",o.content)},dependencies:[Na,La,qu,sE,oE,Pw],styles:[`.dx-custom-tooltip .dx-overlay-content.dx-popup-normal{max-width:340px;padding:0;word-wrap:break-word;color:var(--tooltip-color);background:var(--tooltip-bg);border:none;border-radius:var(--radius-medium);box-shadow:var(--shadow-8);opacity:1}.dx-custom-tooltip .dx-overlay-content.dx-popup-normal .dx-popup-content.dx-popup-content-scrollable{max-width:340px;padding:0;text-align:start;white-space:normal}.dx-custom-tooltip .dx-overlay-content.dx-popup-normal .dx-popup-content.dx-popup-content-scrollable .dx-template-wrapper{padding:var(--space-vertical-s) var(--space-horizontal-m)}.dx-custom-tooltip .dx-overlay-content.dx-popup-normal .dx-popover-arrow:after{background:var(--tooltip-bg)}.dx-custom-tooltip.dx-tooltip-wrapper .dx-overlay-content .dx-popup-content{font:var(--font-body-1)}.dx-custom-tooltip.right.dx-tooltip-wrapper.dx-popover-wrapper .dx-popover-arrow:after,.dx-custom-tooltip.left.dx-tooltip-wrapper.dx-popover-wrapper .dx-popover-arrow:after{border:none;border-radius:var(--radius-small);margin:0 -2px}.dx-custom-tooltip:not(.right,.left).dx-custom-tooltip .dx-overlay-content.dx-popup-normal .dx-popover-arrow:after{border:none;border-radius:var(--radius-small) 0 0 0}.dx-custom-tooltip.top.dx-tooltip-wrapper.dx-popover-wrapper .dx-popover-arrow:after,.dx-custom-tooltip.bottom.dx-tooltip-wrapper.dx-popover-wrapper .dx-popover-arrow:after{border:none;border-radius:var(--radius-small);margin:-2px 0}
`],encapsulation:2,changeDetection:0})}}return i})();export{Et as a,f as b,A as c,B as d,xe as e,$ as f,m as g,Ii as h,fe as i,W as j,u as k,Pw as l,ea as m,Xi as n,O as o,qn as p,BD as q,Zge as r,Jge as s,eme as t,tme as u,ime as v,nme as w,ome as x,TK as y,sme as z,rme as A,MK as B,RK as C,ze as D,Bp as E,Ri as F,YM as G,HM as H,Ps as I,jAe as J,qAe as K,hg as L,Wc as M,fq as N,XAe as O,Cq as P,uR as Q,hR as R,pR as S,Oq as T,wq as U,Bv as V,QAe as W,ZAe as X,JAe as Y,Sg as Z,de as _,mY as $,M as aa,g7 as ba,m7 as ca,s1 as da,_7 as ea,h1 as fa,y7 as ga,S7 as ha,O1 as ia,D7 as ja,A7 as ka,M7 as la,F7 as ma,k7 as na,B7 as oa,L7 as pa,N7 as qa,$7 as ra,z7 as sa,H1 as ta,G7 as ua,$1 as va,U7 as wa,q7 as xa,X7 as ya,Q7 as za,lCt as Aa,hCt as Ba,fCt as Ca};
