sprof 0.1.29 → 0.1.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/sprof.js CHANGED
@@ -1605,7 +1605,7 @@ const St = class St {
1605
1605
  if (s.length === 0)
1606
1606
  return;
1607
1607
  const r = Reflect.getMetadata(n, e);
1608
- r && (e[n] = s.map((o) => new r[n](o)));
1608
+ s.length !== 0 && !r && (e[n] = s), r && (e[n] = s.map((o) => new r[n](o)));
1609
1609
  }
1610
1610
  });
1611
1611
  }
@@ -11,7 +11,7 @@
11
11
 
12
12
  See the Apache Version 2.0 License for specific language governing permissions
13
13
  and limitations under the License.
14
- ***************************************************************************** */var Br;(function(t){(function(e){var n=typeof globalThis=="object"?globalThis:typeof Mr=="object"?Mr:typeof self=="object"?self:typeof this=="object"?this:c(),r=s(t);typeof n.Reflect<"u"&&(r=s(n.Reflect,r)),e(r,n),typeof n.Reflect>"u"&&(n.Reflect=t);function s(d,u){return function(h,f){Object.defineProperty(d,h,{configurable:!0,writable:!0,value:f}),u&&u(h,f)}}function o(){try{return Function("return this;")()}catch{}}function a(){try{return(0,eval)("(function() { return this; })()")}catch{}}function c(){return o()||a()}})(function(e,n){var r=Object.prototype.hasOwnProperty,s=typeof Symbol=="function",o=s&&typeof Symbol.toPrimitive<"u"?Symbol.toPrimitive:"@@toPrimitive",a=s&&typeof Symbol.iterator<"u"?Symbol.iterator:"@@iterator",c=typeof Object.create=="function",d={__proto__:[]}instanceof Array,u=!c&&!d,h={create:c?function(){return mr(Object.create(null))}:d?function(){return mr({__proto__:null})}:function(){return mr({})},has:u?function(p,y){return r.call(p,y)}:function(p,y){return y in p},get:u?function(p,y){return r.call(p,y)?p[y]:void 0}:function(p,y){return p[y]}},f=Object.getPrototypeOf(Function),m=typeof Map=="function"&&typeof Map.prototype.entries=="function"?Map:wg(),g=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:bg(),C=typeof WeakMap=="function"?WeakMap:Cg(),b=s?Symbol.for("@reflect-metadata:registry"):void 0,S=pg(),I=gg(S);function L(p,y,k,x){if(T(k)){if(!Qa(p))throw new TypeError;if(!Ka(y))throw new TypeError;return ag(p,y)}else{if(!Qa(p))throw new TypeError;if(!re(y))throw new TypeError;if(!re(x)&&!T(x)&&!Pt(x))throw new TypeError;return Pt(x)&&(x=void 0),k=He(k),lg(p,y,k,x)}}e("decorate",L);function z(p,y){function k(x,V){if(!re(x))throw new TypeError;if(!T(V)&&!fg(V))throw new TypeError;Ga(p,y,x,V)}return k}e("metadata",z);function N(p,y,k,x){if(!re(k))throw new TypeError;return T(x)||(x=He(x)),Ga(p,y,k,x)}e("defineMetadata",N);function H(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),ja(p,y,k)}e("hasMetadata",H);function Be(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),ur(p,y,k)}e("hasOwnMetadata",Be);function $e(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),Wa(p,y,k)}e("getMetadata",$e);function nt(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),_a(p,y,k)}e("getOwnMetadata",nt);function At(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),Za(p,y)}e("getMetadataKeys",At);function Yn(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),Ja(p,y)}e("getOwnMetadataKeys",Yn);function og(p,y,k){if(!re(y))throw new TypeError;if(T(k)||(k=He(k)),!re(y))throw new TypeError;T(k)||(k=He(k));var x=Qt(y,k,!1);return T(x)?!1:x.OrdinaryDeleteMetadata(p,y,k)}e("deleteMetadata",og);function ag(p,y){for(var k=p.length-1;k>=0;--k){var x=p[k],V=x(y);if(!T(V)&&!Pt(V)){if(!Ka(V))throw new TypeError;y=V}}return y}function lg(p,y,k,x){for(var V=p.length-1;V>=0;--V){var ee=p[V],se=ee(y,k,x);if(!T(se)&&!Pt(se)){if(!re(se))throw new TypeError;x=se}}return x}function ja(p,y,k){var x=ur(p,y,k);if(x)return!0;var V=fr(y);return Pt(V)?!1:ja(p,V,k)}function ur(p,y,k){var x=Qt(y,k,!1);return T(x)?!1:Ya(x.OrdinaryHasOwnMetadata(p,y,k))}function Wa(p,y,k){var x=ur(p,y,k);if(x)return _a(p,y,k);var V=fr(y);if(!Pt(V))return Wa(p,V,k)}function _a(p,y,k){var x=Qt(y,k,!1);if(!T(x))return x.OrdinaryGetOwnMetadata(p,y,k)}function Ga(p,y,k,x){var V=Qt(k,x,!0);V.OrdinaryDefineOwnMetadata(p,y,k,x)}function Za(p,y){var k=Ja(p,y),x=fr(p);if(x===null)return k;var V=Za(x,y);if(V.length<=0)return k;if(k.length<=0)return V;for(var ee=new g,se=[],q=0,v=k;q<v.length;q++){var $=v[q],R=ee.has($);R||(ee.add($),se.push($))}for(var A=0,j=V;A<j.length;A++){var $=j[A],R=ee.has($);R||(ee.add($),se.push($))}return se}function Ja(p,y){var k=Qt(p,y,!1);return k?k.OrdinaryOwnMetadataKeys(p,y):[]}function Xa(p){if(p===null)return 1;switch(typeof p){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return p===null?1:6;default:return 6}}function T(p){return p===void 0}function Pt(p){return p===null}function cg(p){return typeof p=="symbol"}function re(p){return typeof p=="object"?p!==null:typeof p=="function"}function dg(p,y){switch(Xa(p)){case 0:return p;case 1:return p;case 2:return p;case 3:return p;case 4:return p;case 5:return p}var k="string",x=el(p,o);if(x!==void 0){var V=x.call(p,k);if(re(V))throw new TypeError;return V}return ug(p)}function ug(p,y){var k,x,V;{var ee=p.toString;if(Qn(ee)){var x=ee.call(p);if(!re(x))return x}var k=p.valueOf;if(Qn(k)){var x=k.call(p);if(!re(x))return x}}throw new TypeError}function Ya(p){return!!p}function hg(p){return""+p}function He(p){var y=dg(p);return cg(y)?y:hg(y)}function Qa(p){return Array.isArray?Array.isArray(p):p instanceof Object?p instanceof Array:Object.prototype.toString.call(p)==="[object Array]"}function Qn(p){return typeof p=="function"}function Ka(p){return typeof p=="function"}function fg(p){switch(Xa(p)){case 3:return!0;case 4:return!0;default:return!1}}function hr(p,y){return p===y||p!==p&&y!==y}function el(p,y){var k=p[y];if(k!=null){if(!Qn(k))throw new TypeError;return k}}function tl(p){var y=el(p,a);if(!Qn(y))throw new TypeError;var k=y.call(p);if(!re(k))throw new TypeError;return k}function nl(p){return p.value}function il(p){var y=p.next();return y.done?!1:y}function rl(p){var y=p.return;y&&y.call(p)}function fr(p){var y=Object.getPrototypeOf(p);if(typeof p!="function"||p===f||y!==f)return y;var k=p.prototype,x=k&&Object.getPrototypeOf(k);if(x==null||x===Object.prototype)return y;var V=x.constructor;return typeof V!="function"||V===p?y:V}function mg(){var p;!T(b)&&typeof n.Reflect<"u"&&!(b in n.Reflect)&&typeof n.Reflect.defineMetadata=="function"&&(p=yg(n.Reflect));var y,k,x,V=new C,ee={registerProvider:se,getProvider:v,setProvider:R};return ee;function se(A){if(!Object.isExtensible(ee))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case p===A:break;case T(y):y=A;break;case y===A:break;case T(k):k=A;break;case k===A:break;default:x===void 0&&(x=new g),x.add(A);break}}function q(A,j){if(!T(y)){if(y.isProviderFor(A,j))return y;if(!T(k)){if(k.isProviderFor(A,j))return y;if(!T(x))for(var J=tl(x);;){var te=il(J);if(!te)return;var Pe=nl(te);if(Pe.isProviderFor(A,j))return rl(J),Pe}}}if(!T(p)&&p.isProviderFor(A,j))return p}function v(A,j){var J=V.get(A),te;return T(J)||(te=J.get(j)),T(te)&&(te=q(A,j),T(te)||(T(J)&&(J=new m,V.set(A,J)),J.set(j,te))),te}function $(A){if(T(A))throw new TypeError;return y===A||k===A||!T(x)&&x.has(A)}function R(A,j,J){if(!$(J))throw new Error("Metadata provider not registered.");var te=v(A,j);if(te!==J){if(!T(te))return!1;var Pe=V.get(A);T(Pe)&&(Pe=new m,V.set(A,Pe)),Pe.set(j,J)}return!0}}function pg(){var p;return!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&(p=n.Reflect[b]),T(p)&&(p=mg()),!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&Object.defineProperty(n.Reflect,b,{enumerable:!1,configurable:!1,writable:!1,value:p}),p}function gg(p){var y=new C,k={isProviderFor:function($,R){var A=y.get($);return T(A)?!1:A.has(R)},OrdinaryDefineOwnMetadata:se,OrdinaryHasOwnMetadata:V,OrdinaryGetOwnMetadata:ee,OrdinaryOwnMetadataKeys:q,OrdinaryDeleteMetadata:v};return S.registerProvider(k),k;function x($,R,A){var j=y.get($),J=!1;if(T(j)){if(!A)return;j=new m,y.set($,j),J=!0}var te=j.get(R);if(T(te)){if(!A)return;if(te=new m,j.set(R,te),!p.setProvider($,R,k))throw j.delete(R),J&&y.delete($),new Error("Wrong provider for target.")}return te}function V($,R,A){var j=x(R,A,!1);return T(j)?!1:Ya(j.has($))}function ee($,R,A){var j=x(R,A,!1);if(!T(j))return j.get($)}function se($,R,A,j){var J=x(A,j,!0);J.set($,R)}function q($,R){var A=[],j=x($,R,!1);if(T(j))return A;for(var J=j.keys(),te=tl(J),Pe=0;;){var sl=il(te);if(!sl)return A.length=Pe,A;var Sg=nl(sl);try{A[Pe]=Sg}catch(kg){try{rl(te)}finally{throw kg}}Pe++}}function v($,R,A){var j=x(R,A,!1);if(T(j)||!j.delete($))return!1;if(j.size===0){var J=y.get(R);T(J)||(J.delete(A),J.size===0&&y.delete(J))}return!0}}function yg(p){var y=p.defineMetadata,k=p.hasOwnMetadata,x=p.getOwnMetadata,V=p.getOwnMetadataKeys,ee=p.deleteMetadata,se=new C,q={isProviderFor:function(v,$){var R=se.get(v);return!T(R)&&R.has($)?!0:V(v,$).length?(T(R)&&(R=new g,se.set(v,R)),R.add($),!0):!1},OrdinaryDefineOwnMetadata:y,OrdinaryHasOwnMetadata:k,OrdinaryGetOwnMetadata:x,OrdinaryOwnMetadataKeys:V,OrdinaryDeleteMetadata:ee};return q}function Qt(p,y,k){var x=S.getProvider(p,y);if(!T(x))return x;if(k){if(S.setProvider(p,y,I))return I;throw new Error("Illegal state.")}}function wg(){var p={},y=[],k=function(){function q(v,$,R){this._index=0,this._keys=v,this._values=$,this._selector=R}return q.prototype["@@iterator"]=function(){return this},q.prototype[a]=function(){return this},q.prototype.next=function(){var v=this._index;if(v>=0&&v<this._keys.length){var $=this._selector(this._keys[v],this._values[v]);return v+1>=this._keys.length?(this._index=-1,this._keys=y,this._values=y):this._index++,{value:$,done:!1}}return{value:void 0,done:!0}},q.prototype.throw=function(v){throw this._index>=0&&(this._index=-1,this._keys=y,this._values=y),v},q.prototype.return=function(v){return this._index>=0&&(this._index=-1,this._keys=y,this._values=y),{value:v,done:!0}},q}(),x=function(){function q(){this._keys=[],this._values=[],this._cacheKey=p,this._cacheIndex=-2}return Object.defineProperty(q.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),q.prototype.has=function(v){return this._find(v,!1)>=0},q.prototype.get=function(v){var $=this._find(v,!1);return $>=0?this._values[$]:void 0},q.prototype.set=function(v,$){var R=this._find(v,!0);return this._values[R]=$,this},q.prototype.delete=function(v){var $=this._find(v,!1);if($>=0){for(var R=this._keys.length,A=$+1;A<R;A++)this._keys[A-1]=this._keys[A],this._values[A-1]=this._values[A];return this._keys.length--,this._values.length--,hr(v,this._cacheKey)&&(this._cacheKey=p,this._cacheIndex=-2),!0}return!1},q.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=p,this._cacheIndex=-2},q.prototype.keys=function(){return new k(this._keys,this._values,V)},q.prototype.values=function(){return new k(this._keys,this._values,ee)},q.prototype.entries=function(){return new k(this._keys,this._values,se)},q.prototype["@@iterator"]=function(){return this.entries()},q.prototype[a]=function(){return this.entries()},q.prototype._find=function(v,$){if(!hr(this._cacheKey,v)){this._cacheIndex=-1;for(var R=0;R<this._keys.length;R++)if(hr(this._keys[R],v)){this._cacheIndex=R;break}}return this._cacheIndex<0&&$&&(this._cacheIndex=this._keys.length,this._keys.push(v),this._values.push(void 0)),this._cacheIndex},q}();return x;function V(q,v){return q}function ee(q,v){return v}function se(q,v){return[q,v]}}function bg(){var p=function(){function y(){this._map=new m}return Object.defineProperty(y.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),y.prototype.has=function(k){return this._map.has(k)},y.prototype.add=function(k){return this._map.set(k,k),this},y.prototype.delete=function(k){return this._map.delete(k)},y.prototype.clear=function(){this._map.clear()},y.prototype.keys=function(){return this._map.keys()},y.prototype.values=function(){return this._map.keys()},y.prototype.entries=function(){return this._map.entries()},y.prototype["@@iterator"]=function(){return this.keys()},y.prototype[a]=function(){return this.keys()},y}();return p}function Cg(){var p=16,y=h.create(),k=x();return function(){function v(){this._key=x()}return v.prototype.has=function($){var R=V($,!1);return R!==void 0?h.has(R,this._key):!1},v.prototype.get=function($){var R=V($,!1);return R!==void 0?h.get(R,this._key):void 0},v.prototype.set=function($,R){var A=V($,!0);return A[this._key]=R,this},v.prototype.delete=function($){var R=V($,!1);return R!==void 0?delete R[this._key]:!1},v.prototype.clear=function(){this._key=x()},v}();function x(){var v;do v="@@WeakMap@@"+q();while(h.has(y,v));return y[v]=!0,v}function V(v,$){if(!r.call(v,k)){if(!$)return;Object.defineProperty(v,k,{value:h.create()})}return v[k]}function ee(v,$){for(var R=0;R<$;++R)v[R]=Math.random()*255|0;return v}function se(v){if(typeof Uint8Array=="function"){var $=new Uint8Array(v);return typeof crypto<"u"?crypto.getRandomValues($):typeof msCrypto<"u"?msCrypto.getRandomValues($):ee($,v),$}return ee(new Array(v),v)}function q(){var v=se(p);v[6]=v[6]&79|64,v[8]=v[8]&191|128;for(var $="",R=0;R<p;++R){var A=v[R];(R===4||R===6||R===8)&&($+="-"),A<16&&($+="0"),$+=A.toString(16).toLowerCase()}return $}}function mr(p){return p.__=void 0,delete p.__,p}})})(Br||(Br={}));let an;const vl=new Uint8Array(16);function Ml(){if(!an&&(an=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!an))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return an(vl)}const ue=[];for(let t=0;t<256;++t)ue.push((t+256).toString(16).slice(1));function Bl(t,e=0){return ue[t[e+0]]+ue[t[e+1]]+ue[t[e+2]]+ue[t[e+3]]+"-"+ue[t[e+4]]+ue[t[e+5]]+"-"+ue[t[e+6]]+ue[t[e+7]]+"-"+ue[t[e+8]]+ue[t[e+9]]+"-"+ue[t[e+10]]+ue[t[e+11]]+ue[t[e+12]]+ue[t[e+13]]+ue[t[e+14]]+ue[t[e+15]]}const $r={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Xe(t,e,n){if($r.randomUUID&&!t)return $r.randomUUID();t=t||{};const r=t.random||(t.rng||Ml)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Bl(r)}class ne{static UUID(){return Xe()}static GUID(){const e=function(){return((1+Math.random())*65536|0).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}}function $l(t){var e=[];if(t.length===0)return"";if(typeof t[0]!="string")throw new TypeError("Url must be a string. Received "+t[0]);if(t[0].match(/^[^/:]+:\/*$/)&&t.length>1){var n=t.shift();t[0]=n+t[0]}t[0].match(/^file:\/\/\//)?t[0]=t[0].replace(/^([^/:]+):\/*/,"$1:///"):t[0]=t[0].replace(/^([^/:]+):\/*/,"$1://");for(var r=0;r<t.length;r++){var s=t[r];if(typeof s!="string")throw new TypeError("Url must be a string. Received "+s);s!==""&&(r>0&&(s=s.replace(/^[\/]+/,"")),r<t.length-1?s=s.replace(/[\/]+$/,""):s=s.replace(/[\/]+$/,"/"),e.push(s))}var o=e.join("/");o=o.replace(/\/(\?|&|#[^!])/g,"$1");var a=o.split("?");return o=a.shift()+(a.length>0?"?":"")+a.join("&"),o}function si(){var t;return typeof arguments[0]=="object"?t=arguments[0]:t=[].slice.call(arguments),$l(t)}class U{static Capitalize(e){return e?e[0].toUpperCase()+e.slice(1):""}static BuildSafeUrl(e,n,r){try{const s=new URL(e);return s.port=n.toString(),si(s.toString(),r)}catch{throw new Error(`Invalid host URL: ${e}`)}}static ToCamelCase(e){const n=new RegExp(["[А-Я][а-я][A-Z][a-z]+","[А-Я]+(?=[А-Я][а-я])","[A-Z]+(?=[A-Z][a-z])","[А-Я]+","[A-Z]+","[а-я]+","[a-z]+","[0-9]+"].join("|"),"g");return e.match(n).map((s,o)=>o===0?s.toLowerCase():U.Capitalize(s.toLowerCase())).join("")}static ToKebabCase(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase()}static GetStringBetweenChars(e,n,r){return e.substring(e.indexOf(n)+2,e.lastIndexOf(r))}static Translit(e,n){const r={q:"й",w:"ц",e:"у",r:"к",t:"е",y:"н",u:"г",i:"ш",o:"щ",p:"з","[":"х","]":"ъ",a:"ф",s:"ы",d:"в",f:"а",g:"п",h:"р",j:"о",k:"л",l:"д",";":"ж","'":"э",z:"я",x:"ч",c:"с",v:"м",b:"и",n:"т",m:"ь",",":"б",".":"ю","/":"."};return n&&/[а-яА-Я]/g.test(e)?e.replace(/[А-я/,.;'\][]/g,s=>{if(s===s.toLowerCase()){const a=Object.keys(r).find(c=>r[c]===s);return a||""}const o=Object.keys(r).find(a=>r[a]===s.toLowerCase());return o?o.toUpperCase():""}):e.replace(/[A-z/,.;'\][]/g,s=>s===s.toLowerCase()?r[s]:r[s.toLowerCase()].toUpperCase())}static RemoveEmoji(e){const n=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;return e.replace(n,"")}static CanBeTranslited(e){return/^[~`!@#$%^&*()_+=[\]\\{}|;':",.\/<>?a-zA-Z0-9-]+$/.test(e)}static StringsEquals(e,n){const r=e.toLowerCase().replaceAll(/\s/g,""),s=n.toLowerCase().replaceAll(/\s/g,""),o=U.Translit(r),a=U.Translit(s);return r.includes(s)||o.includes(s)||r.includes(a)}static SearchIn(e,n){return U.StringsEquals(e,n)}static SearchInFields(e,n){let r=!1;for(let s=0;s<n.length;s++)if(U.SearchIn(n[s],e)){r=!0;break}return r}static FormatToPercentage(e){return`${e}%`}static ApplyClassToSubStr(e,n,r){const s=r??"highlight-text",o=new RegExp(U.GetVariants(n).join("|"),"gi");return e.replace(o,`<span class="${s}">$&</span>`)}static GetVariants(e){const n=U.Translit(e);return[e,U.Capitalize(e),e.toLowerCase(),e.toUpperCase(),n,U.Capitalize(n),n.toLowerCase(),n.toUpperCase()]}static ContainsNum(e){return/\d/.test(e)}static JoinSnake(...e){return e.join("_")}static GetDynamicCountName(e,n){const r=[2,0,1,1,1,2];return e.length+" "+n[e.length%100>4&&e.length%100<20?2:r[e.length%10<5?e.length%10:5]]}static TrimText(e){return typeof e=="string"?e.trim():e}}const et=class et{static BuildClass(e,n){n&&Object.keys(n).forEach(r=>{const s=n[r];if(this.isPrimitive(s))e[r]instanceof Date?e[r]=new Date(s):e[r]=s;else if(s!=null&&!Array.isArray(s))if(e[r]&&e[r].constructor)e[r]=new e[r].constructor(s);else{const o=Reflect.getMetadata(r,e);o&&(e[r]=new o[r](s))}if(Array.isArray(s)){if(s.length===0)return;const o=Reflect.getMetadata(r,e);o&&(e[r]=s.map(a=>new o[r](a)))}})}static isPrimitive(e){return e!==null&&typeof e<"u"&&e!==Object(e)}static RemoveFromClassByIndex(e,n,r){et.RemoveFromClass(e,n,r)}static RemoveFromClassById(e,n,r){if(!e)return;const s=n.findIndex(o=>o.id===e);et.RemoveFromClass(s,n,r)}static RemoveFromClass(e,n,r){if(e<0)return;const s=n[e].id;s&&r&&r.push(s),n.splice(e,1)}static GetPropertyName(e){const n=new e;return new Proxy(n,{get(r,s){return s}})}static InitClassInstance(e,n){const r=e.constructor(n);return et.BuildClass(r),r.id=ne.UUID(),r}static ExistsWithId(e,n){return e.some(r=>r.id===n)}static DeepMap(e){return n=>Array.isArray(n)?n.map(et.DeepMap(e)):Object(n)===n?Object.fromEntries(Object.entries(n).map(([r,s])=>[r,et.DeepMap(e)(s)])):e(n)}static DeepTrim(e){return this.DeepMap(U.TrimText)(e)}};l(et,"GetClassConstructor",e=>(n,r)=>{const s=Reflect.getMetadata(`property:${r}`,n)||{};s[r]=e,Reflect.defineMetadata(r,s,n)});let M=et;class rt{constructor(e){l(this,"id");l(this,"address");l(this,"description");l(this,"contactId");M.BuildClass(this,e)}static Create(){const e=new rt;return e.id=ne.UUID(),e}}class oi{static Setup(e="http://localhost",n="9000",r="api"){this.staticUrl=U.BuildSafeUrl(e,n,r),this.staticUrl=si(this.staticUrl,"static")}static get StaticUrl(){return this.staticUrl}}l(oi,"staticUrl","");class me{constructor(e){l(this,"name","");l(this,"url","");l(this,"src","");l(this,"raw");l(this,"blob");l(this,"file");l(this,"type","");l(this,"id");l(this,"originalName","");l(this,"fileSystemPath","");l(this,"itemId");l(this,"itemOneId");l(this,"description","");l(this,"order",0);M.BuildClass(this,e)}getFileUrl(){const e=this.url?this.url:`${oi.StaticUrl}/${this.fileSystemPath}`;return new URL(e,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Ie&&Ie.tagName.toUpperCase()==="SCRIPT"&&Ie.src||new URL("sprof.umd.cjs",document.baseURI).href)}getFileListObject(){return{name:this.originalName,url:this.url}}static CreatePreviewFile(e,n){const r=new me;return r.id=n??ne.UUID(),r.originalName=e.name,r.file=e.blob,r.fileSystemPath=ne.UUID(),r}setFile(e){this.id||(this.id=ne.UUID()),this.originalName=e.name,this.file=e,this.fileSystemPath=ne.UUID(),this.url=e.src}clearFile(){this.url="",this.file=void 0,this.fileSystemPath="",this.originalName=""}errorImg(e,n){if(e.target){let r="";return n&&(r=`@/assets/img/${n}`),new URL(r,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Ie&&Ie.tagName.toUpperCase()==="SCRIPT"&&Ie.src||new URL("sprof.umd.cjs",document.baseURI).href)}}getFileInfos(){return[this]}isPdf(){return this.getExtension(this.originalName)===""}getExtension(e){const n=e.split(".");return n[n.length-1]}}class Ir{constructor(e){l(this,"id");l(this,"name","");l(this,"surname","");l(this,"patronymic","");l(this,"isMale",!0);l(this,"dateBirth",new Date);l(this,"contactId");l(this,"slug","");l(this,"postIndex","");l(this,"address","");l(this,"editNameMode",!1);M.BuildClass(this,e)}setEditNameMode(e){this.editNameMode=e}getFullName(){return!this.surname.length&&!this.name.length&&!this.patronymic.length?"":`${this.surname} ${this.name} ${this.patronymic}`}getInitialsName(){return`${this.name.slice(0,1)}.${this.patronymic.slice(0,1)}. ${this.surname}`}getGender(e){return e?this.isMale?"Мужской":"Женский":this.isMale?"М":"Ж"}capitalizeName(){this.name=U.Capitalize(this.name),this.surname=U.Capitalize(this.surname),this.patronymic=U.Capitalize(this.patronymic)}trimName(){this.name=this.name.trim(),this.surname=this.surname.trim(),this.patronymic=this.patronymic.trim()}sanitizeName(){this.trimName(),this.capitalizeName()}setFullName(e){this.surname=e.surname,this.name=e.name,this.patronymic=e.patronymic}}class st{constructor(e){l(this,"id");l(this,"number");l(this,"description");l(this,"contactId");M.BuildClass(this,e)}static Create(){const e=new st;return e.id=ne.UUID(),e}}class ln{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class ai{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class cn{constructor(e){l(this,"id");l(this,"login","");l(this,"email","");l(this,"password","");M.BuildClass(this,e)}static Create(){const e=new cn;return e.id=ne.UUID(),e}}let Il=(Je=class{},l(Je,"Phone",st),l(Je,"FileInfo",me),l(Je,"Website",ai),l(Je,"Email",rt),l(Je,"Human",Ir),l(Je,"PostAddress",ln),l(Je,"UserAccount",cn),Je);var Y=(t=>(t.Eq="=",t.Ne="!=",t.Gt=">",t.Lt="<",t.Btw="between",t.In="in",t.Like="like",t.Null="is null",t.NotNull="is not null",t))(Y||{});class dn{constructor(e){l(this,"field","");l(this,"operator",Y.Eq);l(this,"value","");M.BuildClass(this,e)}setValue(e){this.value=e}static Create(e,n){return new dn({operator:n,field:e})}eq(e){return this.field===e.field&&this.operator===e.operator}isUnary(){return this.operator===Y.Eq||this.operator===Y.Gt||this.operator===Y.Lt}isBetween(){return this.operator===Y.Btw}isSet(){return this.operator===Y.In}}class li{constructor(e){l(this,"model","");l(this,"field","");l(this,"value","");l(this,"wheres",[]);M.BuildClass(this,e)}static Create(e){const n=new li;return n.model=e.GetClassName(),n}eq(e){return e.model===this.model&&e.field===this.field}addWhere(e,n){const r=this.findWhere({field:e,operator:n});if(r)return r;const s=dn.Create(e,n);return this.wheres.push(s),s}findWhere(e){return this.wheres.find(n=>n.eq(e))}}let Rr=class ol{constructor(e){l(this,"id");l(this,"model","");l(this,"wheres",[]);l(this,"joins",[]);M.BuildClass(this,e)}static Create(e){const n=new ol;return n.model=e.GetClassName(),n}addWhere(e,n){const r=this.findWhere({field:e,operator:n});if(r)return r;const s=dn.Create(e,n);return this.wheres.push(s),s}removeWhere(e){const n=this.wheres.findIndex(r=>r.eq(e));n>-1&&this.wheres.splice(n,1)}addJoin(e){const n=this.findJoin({model:e.GetClassName()});if(n)return n;const r=li.Create(e);return this.joins.push(r),r}findJoin(e){return this.joins.find(n=>n.eq(e))}findWhere(e){return this.wheres.find(n=>n.eq(e))}toRef(){return i.ref(this)}};class Ue{static Shuffle(e){for(let n=e.length-1;n>0;n--){const r=Math.floor(Math.random()*(n+1));[e[n],e[r]]=[e[r],e[n]]}}static GenerateNumsRange(e,n,r=1){return Array.from({length:(n-e)/r+1},(s,o)=>e+o*r)}static GetLast(e){return e[e.length-1]}static GetFirst(e){return e[0]}static GetRandEL(e){return e[Math.floor(Math.random()*e.length)]}static Sort(e){e.forEach((n,r)=>n.order=r)}static Refill(e,n){e.splice(0,e.length),e.push(...n)}static Eq(e,n){return e.length===n.length&&(e==null?void 0:e.every((r,s)=>e[s]==n[s]))}static SwipeById(e,n,r){const s=e.findIndex(a=>n.id===a.id),o=e.findIndex(a=>r.id===a.id);s||o||([e[s],e[o]]=[e[o],e[s]])}static Swap(e,n,r){if(n<0||n>=e.length||r<0||r>=e.length)return;const s=e[n];e[n]=e[r],e[r]=s}static MoveUp(e,n){e[n].order=n-1,e[n-1]&&(e[n-1].order=n),[e[n],e[n-1]]=[e[n-1],e[n]]}static MoveDown(e,n){e[n].order=n+1,e[n+1]&&(e[n+1].order=n),[e[n],e[n+1]]=[e[n+1],e[n]]}}var ae=(t=>(t.Date="date",t.String="string",t.Boolean="boolean",t.Number="number",t.Set="set",t.Join="join",t.ArrayString="arrayString",t.ArrayNumber="arrayNumber",t))(ae||{}),Rl=Object.defineProperty,Nl=(t,e,n,r)=>{for(var s=void 0,o=t.length-1,a;o>=0;o--)(a=t[o])&&(s=a(e,n,s)||s);return s&&Rl(e,n,s),s};const Nr=class Kt{constructor(e){l(this,"id");l(this,"model","");l(this,"label","");l(this,"col","");l(this,"operator",Y.Eq);l(this,"date1");l(this,"date2");l(this,"value1","");l(this,"boolean",!1);l(this,"number",0);l(this,"type",ae.String);l(this,"set",[]);l(this,"isSet",!1);l(this,"joinTable","");l(this,"joinTableModel","");l(this,"joinTableFk","");l(this,"joinTablePk","");l(this,"joinTableId","");l(this,"joinTableIdCol","");M.BuildClass(this,e)}eq(e){if(!e)return!1;if(this.type===ae.Join){const n=e.model===this.model&&e.operator===this.operator&&this.joinTableModel===e.joinTableModel;return e.operator===Y.In?n&&Ue.Eq(this.set,e.set):n}return e.model===this.model&&e.col===this.col&&e.operator===this.operator}valueEq(e){return!this||!e||!this.eq(e)?!1:this.type===ae.Boolean?this.boolean===(e==null?void 0:e.boolean):this.type===ae.String?this.value1===(e==null?void 0:e.value1):this.type===ae.Join&&this.set.length?Ue.Eq(this.set,e.set):!1}toUrlQuery(){const e=this.type?`"type":"${this.type}"`:"",n=this.model?`"model":"${this.model}"`:"",r=this.col?`"col":"${this.col}"`:"",s=this.operator?`"operator":"${this.operator}"`:"",o=this.value1?`"value1":"${this.value1}"`:"",a=this.type===ae.Boolean?`"boolean":${this.boolean}`:"",c=this.type===ae.Date&&this.date1?`"date1":"${this.date1.toISOString()}"`:"",d=this.type===ae.Date&&this.date2?`"date2":"${this.date2.toISOString()}"`:"",u=this.type===ae.Number?`"number":${this.number}`:"",h=this.type===ae.Set||this.operator===Y.In?`"set":${JSON.stringify(this.set)}`:"",f=this.type===ae.Join?`"joinTableModel":"${this.joinTableModel}"`:"";return[e,n,r,s,o,a,c,d,u,h,f].filter(m=>m!=="").toString()}fromUrlQuery(e){this.model=e.get("model")??"",this.col=e.get("col")??"",this.label=e.get("label")??"",this.operator=e.get("operator")??"",this.value1=e.get("value1")??"",this.type=e.get("type")??"",this.boolean=!!(e.get("boolean")??""),this.joinTableModel=e.get("joinTableModel")??"",this.joinTableId=e.get("joinTableId")??"",this.joinTableFk=e.get("joinTableFk")??"",this.joinTableIdCol=e.get("joinTableIdCol")??"",this.joinTablePk=e.get("joinTablePk")??""}isUnaryFilter(){return this.operator===Y.Eq||this.operator===Y.Gt||this.operator===Y.Lt}isBetweenFilter(){return this.operator===Y.Btw}isSetFilter(){return this.operator===Y.In}static Create(e,n,r){const s=new Kt;return s.model=e.GetClassName(),s.col=n??"",s.type=r,s.type===ae.Number&&(s.value1="0"),s.type===ae.String&&(s.value1=""),s.type===ae.Boolean&&(s.value1="false",s.operator=Y.Eq),s}static CreateFilterModelWithJoin(e,n,r,s,o,a,c,d){const u=new Kt;return u.id=Xe(),u.joinTable=r,u.joinTablePk=s,u.joinTableFk=o,u.col=n,u.type=a,c&&(u.joinTableId=c),d&&(u.joinTableIdCol=d),u}static CreateFilterModelWithJoinV2(e,n,r,s,o,a,c){const d=new Kt;return d.model=e,d.joinTableModel=r,d.joinTablePk=s,d.joinTableFk=o,d.col=n,d.type=ae.Join,a&&(d.joinTableId=a),c&&(d.joinTableIdCol=c),d}static OnlyIfSecondModelExists(e,n){const r=new Kt;return r.id=Xe(),r.model=U.ToCamelCase(e.GetClassName()),r.joinTableModel=U.ToCamelCase(n.GetClassName()),r.type=ae.Join,r}addToSet(...e){e.forEach(n=>{if(this.set.indexOf(n)===-1){this.set.push(n);return}this.set=this.set.filter(r=>r!==n)})}pushToSet(...e){e.forEach(n=>{this.set.indexOf(n)===-1&&this.set.push(n)})}replaceSet(...e){this.set=e}setBoolean(e){this.boolean=e}toRef(){return i.ref(this)}setDate1(e){this.date1=e}setDate2(e){this.date2=e}dropDates(){this.setDate1(),this.setDate2()}setDatesRange(e,n){if(!e&&!n){this.dropDates();return}if(!n){this.setDate1(e),this.operator=Y.Eq;return}this.setDate2(n),this.operator=Y.Btw}};Nl([M.GetClassConstructor(String)],Nr.prototype,"set");let ci=Nr;class Al{constructor(){l(this,"operation",Y.Lt);l(this,"column","");l(this,"value");l(this,"initial",!0);l(this,"tableName","");l(this,"version","");l(this,"model","")}toUrlQuery(){const e=this.operation?`"operation":"${this.operation}"`:"",n=this.column?`"column":"${this.column}"`:"",r=this.value&&typeof this.value.toISOString=="function"?this.value.toISOString():this.value,s=r?`"value":"${r}"`:"",o=this.model?`"model":"${this.model}"`:"",a=`"initial":${this.initial}`;return[e,n,s,o,a].filter(c=>c!=="").toString()}fromUrlQuery(e){e.cursvalue&&(this.value=e.cursvalue),e.curscolumn&&(this.column=String(e.curscolumn)),e.cursinitial!==void 0&&(this.initial=!!e.cursinitial),e.curstableName&&(this.tableName=String(e.curstableName)),e.cursoperation&&(this.operation=e.cursoperation)}}class un{constructor(e){l(this,"page",0);l(this,"rowsPerPage",25);l(this,"rowsNumber",0);l(this,"cursor",new Al);l(this,"cursorMode",!1);l(this,"append",!1);l(this,"allLoaded",!1);l(this,"version","");M.BuildClass(this,e)}setLoadMore(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=Y.Gt,this.cursor.column=n,this.cursor.tableName=r,this.cursorMode=!0}setLoadMoreV2(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=Y.Gt,this.cursor.column=n,this.cursor.model=r,this.cursorMode=!0,this.version="v2"}setOffset(e){this.page=e}toUrlQuery(){const e=`"offset":${this.offset}`,n=`"limit":${this.limit}`,r=`"cursorMode":${this.cursorMode}`,s=`"append":${this.append}`,o=`"allLoaded":${this.allLoaded}`,a=`"cursor":{${this.cursor.toUrlQuery()}}`;return[e,n,r,s,o,a].toString()}fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("p=")+2,e.lastIndexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.page=Number(r.get("offset")),this.rowsPerPage=Number(r.get("col"))}setAllLoaded(e){this.allLoaded=!(e>=this.rowsPerPage)}resetAllLoaded(){this.allLoaded=!1}getPageNum(){return this.page/this.rowsPerPage+1}drop(){this.page=0,this.rowsPerPage=25,M.BuildClass(this)}}var Ee=(t=>(t.Asc="asc",t.Desc="desc",t))(Ee||{});class hn{constructor(e){l(this,"model","");l(this,"col","");l(this,"order");l(this,"label","");l(this,"default",!1);l(this,"selected",!1);M.BuildClass(this,e)}static Create(e,n,r=Ee.Asc,s,o){const a=new hn;return a.model=e.GetClassName(),a.col=n??"",a.order=r??Ee.Asc,a.label=s??"",a.default=o??!1,a}isAsc(){return this.order===Ee.Asc}isDesc(){return this.order===Ee.Desc}eq(e){return e.model===this.model&&e.col===this.col&&e.order===this.order}toUrlQuery(){const e=this.model?`"model":"${this.model}"`:"",n=this.col?`"col":"${this.col}"`:"",r=this.order?`"order":"${this.order}"`:"";return[e,n,r].toString()}async fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("s=")+2,e.indexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.model=r.get("model")??"",this.col=r.get("col")??"",this.label=r.get("label")??"",this.default=!!r.get("default"),this.order=r.get("order")??""}asc(){this.order=Ee.Asc}desc(){this.order=Ee.Desc}}class fn{constructor(){l(this,"model","");l(this,"cols",[]);l(this,"models",[])}static Create(e,n){const r=new fn;return r.model=e.GetClassName(),r.cols=n,r}}var Pl=Object.defineProperty,Tt=(t,e,n,r)=>{for(var s=void 0,o=t.length-1,a;o>=0;o--)(a=t[o])&&(s=a(e,n,s)||s);return s&&Pl(e,n,s),s};const gt=(Se=class{constructor(e){l(this,"id");l(this,"f",[]);l(this,"f2",[]);l(this,"s",[]);l(this,"p",new un);l(this,"t",new fn);M.BuildClass(this,e)}static Get(){return this.instance||(this.instance=new Se),this.instance}createFrom(e){const n=new Se(JSON.parse(e));this.f=n.f}clearForHTTP(){const e=new Se(this);return e.f=this.f.map(n=>Se.EmptyEntiries(n)),e.f2=this.f2.map(n=>Se.EmptyEntiries(n)),e.s=this.s.map(n=>Se.EmptyEntiries(n)),e.p=Se.EmptyEntiries(this.p),e.t=Se.EmptyEntiries(this.t),e}static EmptyEntiries(e){if(!e)return;const r=Object.entries(e).filter(([s,o])=>s!=="label"&&o!==""&&o!==null);return Object.fromEntries(r)}findFilterModel(e){return this.f.find(n=>e.id===n.id)}getFirstSortModel(){return Ue.GetLast(this.s)}setSortModel(e){e&&(this.s[0]=e)}setS(e){this.s[0]=e}setF(e){this.f.push(e)}setF2(e){this.f2.push(e)}replaceF(e,n){this.removeF(n),e&&this.setF(e)}removeF(e){const n=this.f.findIndex(r=>r.eq(e));M.RemoveFromClassByIndex(n,this.f)}reset(){this.f=[],this.s=[],this.p=new un}resetF(){this.f=[]}},l(Se,"instance"),Se);Tt([M.GetClassConstructor(ci)],gt.prototype,"f"),Tt([M.GetClassConstructor(Rr)],gt.prototype,"f2"),Tt([M.GetClassConstructor(hn)],gt.prototype,"s"),Tt([M.GetClassConstructor(un)],gt.prototype,"p"),Tt([M.GetClassConstructor(fn)],gt.prototype,"t");let je=gt,zl=(Nt=class{},l(Nt,"SortModel",hn),l(Nt,"FilterModel",ci),l(Nt,"FilterModelV2",Rr),l(Nt,"FTSP",je),Nt);function Ar(t,e){return function(){return t.apply(e,arguments)}}const{toString:Vl}=Object.prototype,{getPrototypeOf:di}=Object,{iterator:mn,toStringTag:Pr}=Symbol,pn=(t=>e=>{const n=Vl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Ne=t=>(t=t.toLowerCase(),e=>pn(e)===t),gn=t=>e=>typeof e===t,{isArray:yt}=Array,Ft=gn("undefined");function Ot(t){return t!==null&&!Ft(t)&&t.constructor!==null&&!Ft(t.constructor)&&we(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const zr=Ne("ArrayBuffer");function Tl(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&zr(t.buffer),e}const Fl=gn("string"),we=gn("function"),Vr=gn("number"),Dt=t=>t!==null&&typeof t=="object",Ol=t=>t===!0||t===!1,yn=t=>{if(pn(t)!=="object")return!1;const e=di(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Pr in t)&&!(mn in t)},Dl=t=>{if(!Dt(t)||Ot(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},Ll=Ne("Date"),Hl=Ne("File"),ql=Ne("Blob"),Ul=Ne("FileList"),jl=t=>Dt(t)&&we(t.pipe),Wl=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||we(t.append)&&((e=pn(t))==="formdata"||e==="object"&&we(t.toString)&&t.toString()==="[object FormData]"))},_l=Ne("URLSearchParams"),[Gl,Zl,Jl,Xl]=["ReadableStream","Request","Response","Headers"].map(Ne),Yl=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Lt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,s;if(typeof t!="object"&&(t=[t]),yt(t))for(r=0,s=t.length;r<s;r++)e.call(null,t[r],r,t);else{if(Ot(t))return;const o=n?Object.getOwnPropertyNames(t):Object.keys(t),a=o.length;let c;for(r=0;r<a;r++)c=o[r],e.call(null,t[c],c,t)}}function Tr(t,e){if(Ot(t))return null;e=e.toLowerCase();const n=Object.keys(t);let r=n.length,s;for(;r-- >0;)if(s=n[r],e===s.toLowerCase())return s;return null}const ot=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Fr=t=>!Ft(t)&&t!==ot;function ui(){const{caseless:t}=Fr(this)&&this||{},e={},n=(r,s)=>{const o=t&&Tr(e,s)||s;yn(e[o])&&yn(r)?e[o]=ui(e[o],r):yn(r)?e[o]=ui({},r):yt(r)?e[o]=r.slice():e[o]=r};for(let r=0,s=arguments.length;r<s;r++)arguments[r]&&Lt(arguments[r],n);return e}const Ql=(t,e,n,{allOwnKeys:r}={})=>(Lt(e,(s,o)=>{n&&we(s)?t[o]=Ar(s,n):t[o]=s},{allOwnKeys:r}),t),Kl=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),ec=(t,e,n,r)=>{t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},tc=(t,e,n,r)=>{let s,o,a;const c={};if(e=e||{},t==null)return e;do{for(s=Object.getOwnPropertyNames(t),o=s.length;o-- >0;)a=s[o],(!r||r(a,t,e))&&!c[a]&&(e[a]=t[a],c[a]=!0);t=n!==!1&&di(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},nc=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const r=t.indexOf(e,n);return r!==-1&&r===n},ic=t=>{if(!t)return null;if(yt(t))return t;let e=t.length;if(!Vr(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},rc=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&di(Uint8Array)),sc=(t,e)=>{const r=(t&&t[mn]).call(t);let s;for(;(s=r.next())&&!s.done;){const o=s.value;e.call(t,o[0],o[1])}},oc=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},ac=Ne("HTMLFormElement"),lc=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),Or=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),cc=Ne("RegExp"),Dr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Lt(n,(s,o)=>{let a;(a=e(s,o,t))!==!1&&(r[o]=a||s)}),Object.defineProperties(t,r)},dc=t=>{Dr(t,(e,n)=>{if(we(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=t[n];if(we(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},uc=(t,e)=>{const n={},r=s=>{s.forEach(o=>{n[o]=!0})};return yt(t)?r(t):r(String(t).split(e)),n},hc=()=>{},fc=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function mc(t){return!!(t&&we(t.append)&&t[Pr]==="FormData"&&t[mn])}const pc=t=>{const e=new Array(10),n=(r,s)=>{if(Dt(r)){if(e.indexOf(r)>=0)return;if(Ot(r))return r;if(!("toJSON"in r)){e[s]=r;const o=yt(r)?[]:{};return Lt(r,(a,c)=>{const d=n(a,s+1);!Ft(d)&&(o[c]=d)}),e[s]=void 0,o}}return r};return n(t,0)},gc=Ne("AsyncFunction"),yc=t=>t&&(Dt(t)||we(t))&&we(t.then)&&we(t.catch),Lr=((t,e)=>t?setImmediate:e?((n,r)=>(ot.addEventListener("message",({source:s,data:o})=>{s===ot&&o===n&&r.length&&r.shift()()},!1),s=>{r.push(s),ot.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",we(ot.postMessage)),wc=typeof queueMicrotask<"u"?queueMicrotask.bind(ot):typeof process<"u"&&process.nextTick||Lr,w={isArray:yt,isArrayBuffer:zr,isBuffer:Ot,isFormData:Wl,isArrayBufferView:Tl,isString:Fl,isNumber:Vr,isBoolean:Ol,isObject:Dt,isPlainObject:yn,isEmptyObject:Dl,isReadableStream:Gl,isRequest:Zl,isResponse:Jl,isHeaders:Xl,isUndefined:Ft,isDate:Ll,isFile:Hl,isBlob:ql,isRegExp:cc,isFunction:we,isStream:jl,isURLSearchParams:_l,isTypedArray:rc,isFileList:Ul,forEach:Lt,merge:ui,extend:Ql,trim:Yl,stripBOM:Kl,inherits:ec,toFlatObject:tc,kindOf:pn,kindOfTest:Ne,endsWith:nc,toArray:ic,forEachEntry:sc,matchAll:oc,isHTMLForm:ac,hasOwnProperty:Or,hasOwnProp:Or,reduceDescriptors:Dr,freezeMethods:dc,toObjectSet:uc,toCamelCase:lc,noop:hc,toFiniteNumber:fc,findKey:Tr,global:ot,isContextDefined:Fr,isSpecCompliantForm:mc,toJSONObject:pc,isAsyncFn:gc,isThenable:yc,setImmediate:Lr,asap:wc,isIterable:t=>t!=null&&we(t[mn])};function F(t,e,n,r,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),s&&(this.response=s,this.status=s.status?s.status:null)}w.inherits(F,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:w.toJSONObject(this.config),code:this.code,status:this.status}}});const Hr=F.prototype,qr={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{qr[t]={value:t}}),Object.defineProperties(F,qr),Object.defineProperty(Hr,"isAxiosError",{value:!0}),F.from=(t,e,n,r,s,o)=>{const a=Object.create(Hr);return w.toFlatObject(t,a,function(d){return d!==Error.prototype},c=>c!=="isAxiosError"),F.call(a,t.message,e,n,r,s),a.cause=t,a.name=t.name,o&&Object.assign(a,o),a};const bc=null;function hi(t){return w.isPlainObject(t)||w.isArray(t)}function Ur(t){return w.endsWith(t,"[]")?t.slice(0,-2):t}function jr(t,e,n){return t?t.concat(e).map(function(s,o){return s=Ur(s),!n&&o?"["+s+"]":s}).join(n?".":""):e}function Cc(t){return w.isArray(t)&&!t.some(hi)}const Sc=w.toFlatObject(w,{},null,function(e){return/^is[A-Z]/.test(e)});function wn(t,e,n){if(!w.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=w.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(b,S){return!w.isUndefined(S[b])});const r=n.metaTokens,s=n.visitor||h,o=n.dots,a=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&w.isSpecCompliantForm(e);if(!w.isFunction(s))throw new TypeError("visitor must be a function");function u(C){if(C===null)return"";if(w.isDate(C))return C.toISOString();if(w.isBoolean(C))return C.toString();if(!d&&w.isBlob(C))throw new F("Blob is not supported. Use a Buffer instead.");return w.isArrayBuffer(C)||w.isTypedArray(C)?d&&typeof Blob=="function"?new Blob([C]):Buffer.from(C):C}function h(C,b,S){let I=C;if(C&&!S&&typeof C=="object"){if(w.endsWith(b,"{}"))b=r?b:b.slice(0,-2),C=JSON.stringify(C);else if(w.isArray(C)&&Cc(C)||(w.isFileList(C)||w.endsWith(b,"[]"))&&(I=w.toArray(C)))return b=Ur(b),I.forEach(function(z,N){!(w.isUndefined(z)||z===null)&&e.append(a===!0?jr([b],N,o):a===null?b:b+"[]",u(z))}),!1}return hi(C)?!0:(e.append(jr(S,b,o),u(C)),!1)}const f=[],m=Object.assign(Sc,{defaultVisitor:h,convertValue:u,isVisitable:hi});function g(C,b){if(!w.isUndefined(C)){if(f.indexOf(C)!==-1)throw Error("Circular reference detected in "+b.join("."));f.push(C),w.forEach(C,function(I,L){(!(w.isUndefined(I)||I===null)&&s.call(e,I,w.isString(L)?L.trim():L,b,m))===!0&&g(I,b?b.concat(L):[L])}),f.pop()}}if(!w.isObject(t))throw new TypeError("data must be an object");return g(t),e}function Wr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function fi(t,e){this._pairs=[],t&&wn(t,this,e)}const _r=fi.prototype;_r.append=function(e,n){this._pairs.push([e,n])},_r.toString=function(e){const n=e?function(r){return e.call(this,r,Wr)}:Wr;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function kc(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Gr(t,e,n){if(!e)return t;const r=n&&n.encode||kc;w.isFunction(n)&&(n={serialize:n});const s=n&&n.serialize;let o;if(s?o=s(e,n):o=w.isURLSearchParams(e)?e.toString():new fi(e,n).toString(r),o){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+o}return t}class Zr{constructor(){this.handlers=[]}use(e,n,r){return this.handlers.push({fulfilled:e,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){w.forEach(this.handlers,function(r){r!==null&&e(r)})}}const Jr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ec={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:fi,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},mi=typeof window<"u"&&typeof document<"u",pi=typeof navigator=="object"&&navigator||void 0,xc=mi&&(!pi||["ReactNative","NativeScript","NS"].indexOf(pi.product)<0),vc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Mc=mi&&window.location.href||"http://localhost",pe={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:mi,hasStandardBrowserEnv:xc,hasStandardBrowserWebWorkerEnv:vc,navigator:pi,origin:Mc},Symbol.toStringTag,{value:"Module"})),...Ec};function Bc(t,e){return wn(t,new pe.classes.URLSearchParams,{visitor:function(n,r,s,o){return pe.isNode&&w.isBuffer(n)?(this.append(r,n.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...e})}function $c(t){return w.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function Ic(t){const e={},n=Object.keys(t);let r;const s=n.length;let o;for(r=0;r<s;r++)o=n[r],e[o]=t[o];return e}function Xr(t){function e(n,r,s,o){let a=n[o++];if(a==="__proto__")return!0;const c=Number.isFinite(+a),d=o>=n.length;return a=!a&&w.isArray(s)?s.length:a,d?(w.hasOwnProp(s,a)?s[a]=[s[a],r]:s[a]=r,!c):((!s[a]||!w.isObject(s[a]))&&(s[a]=[]),e(n,r,s[a],o)&&w.isArray(s[a])&&(s[a]=Ic(s[a])),!c)}if(w.isFormData(t)&&w.isFunction(t.entries)){const n={};return w.forEachEntry(t,(r,s)=>{e($c(r),s,n,0)}),n}return null}function Rc(t,e,n){if(w.isString(t))try{return(e||JSON.parse)(t),w.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(t)}const Ht={transitional:Jr,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,o=w.isObject(e);if(o&&w.isHTMLForm(e)&&(e=new FormData(e)),w.isFormData(e))return s?JSON.stringify(Xr(e)):e;if(w.isArrayBuffer(e)||w.isBuffer(e)||w.isStream(e)||w.isFile(e)||w.isBlob(e)||w.isReadableStream(e))return e;if(w.isArrayBufferView(e))return e.buffer;if(w.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let c;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Bc(e,this.formSerializer).toString();if((c=w.isFileList(e))||r.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return wn(c?{"files[]":e}:e,d&&new d,this.formSerializer)}}return o||s?(n.setContentType("application/json",!1),Rc(e)):e}],transformResponse:[function(e){const n=this.transitional||Ht.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(w.isResponse(e)||w.isReadableStream(e))return e;if(e&&w.isString(e)&&(r&&!this.responseType||s)){const a=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(e)}catch(c){if(a)throw c.name==="SyntaxError"?F.from(c,F.ERR_BAD_RESPONSE,this,null,this.response):c}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:pe.classes.FormData,Blob:pe.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};w.forEach(["delete","get","head","post","put","patch"],t=>{Ht.headers[t]={}});const Nc=w.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Ac=t=>{const e={};let n,r,s;return t&&t.split(`
14
+ ***************************************************************************** */var Br;(function(t){(function(e){var n=typeof globalThis=="object"?globalThis:typeof Mr=="object"?Mr:typeof self=="object"?self:typeof this=="object"?this:c(),r=s(t);typeof n.Reflect<"u"&&(r=s(n.Reflect,r)),e(r,n),typeof n.Reflect>"u"&&(n.Reflect=t);function s(d,u){return function(h,f){Object.defineProperty(d,h,{configurable:!0,writable:!0,value:f}),u&&u(h,f)}}function o(){try{return Function("return this;")()}catch{}}function a(){try{return(0,eval)("(function() { return this; })()")}catch{}}function c(){return o()||a()}})(function(e,n){var r=Object.prototype.hasOwnProperty,s=typeof Symbol=="function",o=s&&typeof Symbol.toPrimitive<"u"?Symbol.toPrimitive:"@@toPrimitive",a=s&&typeof Symbol.iterator<"u"?Symbol.iterator:"@@iterator",c=typeof Object.create=="function",d={__proto__:[]}instanceof Array,u=!c&&!d,h={create:c?function(){return mr(Object.create(null))}:d?function(){return mr({__proto__:null})}:function(){return mr({})},has:u?function(p,y){return r.call(p,y)}:function(p,y){return y in p},get:u?function(p,y){return r.call(p,y)?p[y]:void 0}:function(p,y){return p[y]}},f=Object.getPrototypeOf(Function),m=typeof Map=="function"&&typeof Map.prototype.entries=="function"?Map:wg(),g=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:bg(),C=typeof WeakMap=="function"?WeakMap:Cg(),b=s?Symbol.for("@reflect-metadata:registry"):void 0,S=pg(),I=gg(S);function L(p,y,k,x){if(T(k)){if(!Qa(p))throw new TypeError;if(!Ka(y))throw new TypeError;return ag(p,y)}else{if(!Qa(p))throw new TypeError;if(!re(y))throw new TypeError;if(!re(x)&&!T(x)&&!Pt(x))throw new TypeError;return Pt(x)&&(x=void 0),k=He(k),lg(p,y,k,x)}}e("decorate",L);function z(p,y){function k(x,V){if(!re(x))throw new TypeError;if(!T(V)&&!fg(V))throw new TypeError;Ga(p,y,x,V)}return k}e("metadata",z);function N(p,y,k,x){if(!re(k))throw new TypeError;return T(x)||(x=He(x)),Ga(p,y,k,x)}e("defineMetadata",N);function H(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),ja(p,y,k)}e("hasMetadata",H);function Be(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),ur(p,y,k)}e("hasOwnMetadata",Be);function $e(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),Wa(p,y,k)}e("getMetadata",$e);function nt(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),_a(p,y,k)}e("getOwnMetadata",nt);function At(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),Za(p,y)}e("getMetadataKeys",At);function Yn(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),Ja(p,y)}e("getOwnMetadataKeys",Yn);function og(p,y,k){if(!re(y))throw new TypeError;if(T(k)||(k=He(k)),!re(y))throw new TypeError;T(k)||(k=He(k));var x=Qt(y,k,!1);return T(x)?!1:x.OrdinaryDeleteMetadata(p,y,k)}e("deleteMetadata",og);function ag(p,y){for(var k=p.length-1;k>=0;--k){var x=p[k],V=x(y);if(!T(V)&&!Pt(V)){if(!Ka(V))throw new TypeError;y=V}}return y}function lg(p,y,k,x){for(var V=p.length-1;V>=0;--V){var ee=p[V],se=ee(y,k,x);if(!T(se)&&!Pt(se)){if(!re(se))throw new TypeError;x=se}}return x}function ja(p,y,k){var x=ur(p,y,k);if(x)return!0;var V=fr(y);return Pt(V)?!1:ja(p,V,k)}function ur(p,y,k){var x=Qt(y,k,!1);return T(x)?!1:Ya(x.OrdinaryHasOwnMetadata(p,y,k))}function Wa(p,y,k){var x=ur(p,y,k);if(x)return _a(p,y,k);var V=fr(y);if(!Pt(V))return Wa(p,V,k)}function _a(p,y,k){var x=Qt(y,k,!1);if(!T(x))return x.OrdinaryGetOwnMetadata(p,y,k)}function Ga(p,y,k,x){var V=Qt(k,x,!0);V.OrdinaryDefineOwnMetadata(p,y,k,x)}function Za(p,y){var k=Ja(p,y),x=fr(p);if(x===null)return k;var V=Za(x,y);if(V.length<=0)return k;if(k.length<=0)return V;for(var ee=new g,se=[],q=0,v=k;q<v.length;q++){var $=v[q],R=ee.has($);R||(ee.add($),se.push($))}for(var A=0,j=V;A<j.length;A++){var $=j[A],R=ee.has($);R||(ee.add($),se.push($))}return se}function Ja(p,y){var k=Qt(p,y,!1);return k?k.OrdinaryOwnMetadataKeys(p,y):[]}function Xa(p){if(p===null)return 1;switch(typeof p){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return p===null?1:6;default:return 6}}function T(p){return p===void 0}function Pt(p){return p===null}function cg(p){return typeof p=="symbol"}function re(p){return typeof p=="object"?p!==null:typeof p=="function"}function dg(p,y){switch(Xa(p)){case 0:return p;case 1:return p;case 2:return p;case 3:return p;case 4:return p;case 5:return p}var k="string",x=el(p,o);if(x!==void 0){var V=x.call(p,k);if(re(V))throw new TypeError;return V}return ug(p)}function ug(p,y){var k,x,V;{var ee=p.toString;if(Qn(ee)){var x=ee.call(p);if(!re(x))return x}var k=p.valueOf;if(Qn(k)){var x=k.call(p);if(!re(x))return x}}throw new TypeError}function Ya(p){return!!p}function hg(p){return""+p}function He(p){var y=dg(p);return cg(y)?y:hg(y)}function Qa(p){return Array.isArray?Array.isArray(p):p instanceof Object?p instanceof Array:Object.prototype.toString.call(p)==="[object Array]"}function Qn(p){return typeof p=="function"}function Ka(p){return typeof p=="function"}function fg(p){switch(Xa(p)){case 3:return!0;case 4:return!0;default:return!1}}function hr(p,y){return p===y||p!==p&&y!==y}function el(p,y){var k=p[y];if(k!=null){if(!Qn(k))throw new TypeError;return k}}function tl(p){var y=el(p,a);if(!Qn(y))throw new TypeError;var k=y.call(p);if(!re(k))throw new TypeError;return k}function nl(p){return p.value}function il(p){var y=p.next();return y.done?!1:y}function rl(p){var y=p.return;y&&y.call(p)}function fr(p){var y=Object.getPrototypeOf(p);if(typeof p!="function"||p===f||y!==f)return y;var k=p.prototype,x=k&&Object.getPrototypeOf(k);if(x==null||x===Object.prototype)return y;var V=x.constructor;return typeof V!="function"||V===p?y:V}function mg(){var p;!T(b)&&typeof n.Reflect<"u"&&!(b in n.Reflect)&&typeof n.Reflect.defineMetadata=="function"&&(p=yg(n.Reflect));var y,k,x,V=new C,ee={registerProvider:se,getProvider:v,setProvider:R};return ee;function se(A){if(!Object.isExtensible(ee))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case p===A:break;case T(y):y=A;break;case y===A:break;case T(k):k=A;break;case k===A:break;default:x===void 0&&(x=new g),x.add(A);break}}function q(A,j){if(!T(y)){if(y.isProviderFor(A,j))return y;if(!T(k)){if(k.isProviderFor(A,j))return y;if(!T(x))for(var J=tl(x);;){var te=il(J);if(!te)return;var Pe=nl(te);if(Pe.isProviderFor(A,j))return rl(J),Pe}}}if(!T(p)&&p.isProviderFor(A,j))return p}function v(A,j){var J=V.get(A),te;return T(J)||(te=J.get(j)),T(te)&&(te=q(A,j),T(te)||(T(J)&&(J=new m,V.set(A,J)),J.set(j,te))),te}function $(A){if(T(A))throw new TypeError;return y===A||k===A||!T(x)&&x.has(A)}function R(A,j,J){if(!$(J))throw new Error("Metadata provider not registered.");var te=v(A,j);if(te!==J){if(!T(te))return!1;var Pe=V.get(A);T(Pe)&&(Pe=new m,V.set(A,Pe)),Pe.set(j,J)}return!0}}function pg(){var p;return!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&(p=n.Reflect[b]),T(p)&&(p=mg()),!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&Object.defineProperty(n.Reflect,b,{enumerable:!1,configurable:!1,writable:!1,value:p}),p}function gg(p){var y=new C,k={isProviderFor:function($,R){var A=y.get($);return T(A)?!1:A.has(R)},OrdinaryDefineOwnMetadata:se,OrdinaryHasOwnMetadata:V,OrdinaryGetOwnMetadata:ee,OrdinaryOwnMetadataKeys:q,OrdinaryDeleteMetadata:v};return S.registerProvider(k),k;function x($,R,A){var j=y.get($),J=!1;if(T(j)){if(!A)return;j=new m,y.set($,j),J=!0}var te=j.get(R);if(T(te)){if(!A)return;if(te=new m,j.set(R,te),!p.setProvider($,R,k))throw j.delete(R),J&&y.delete($),new Error("Wrong provider for target.")}return te}function V($,R,A){var j=x(R,A,!1);return T(j)?!1:Ya(j.has($))}function ee($,R,A){var j=x(R,A,!1);if(!T(j))return j.get($)}function se($,R,A,j){var J=x(A,j,!0);J.set($,R)}function q($,R){var A=[],j=x($,R,!1);if(T(j))return A;for(var J=j.keys(),te=tl(J),Pe=0;;){var sl=il(te);if(!sl)return A.length=Pe,A;var Sg=nl(sl);try{A[Pe]=Sg}catch(kg){try{rl(te)}finally{throw kg}}Pe++}}function v($,R,A){var j=x(R,A,!1);if(T(j)||!j.delete($))return!1;if(j.size===0){var J=y.get(R);T(J)||(J.delete(A),J.size===0&&y.delete(J))}return!0}}function yg(p){var y=p.defineMetadata,k=p.hasOwnMetadata,x=p.getOwnMetadata,V=p.getOwnMetadataKeys,ee=p.deleteMetadata,se=new C,q={isProviderFor:function(v,$){var R=se.get(v);return!T(R)&&R.has($)?!0:V(v,$).length?(T(R)&&(R=new g,se.set(v,R)),R.add($),!0):!1},OrdinaryDefineOwnMetadata:y,OrdinaryHasOwnMetadata:k,OrdinaryGetOwnMetadata:x,OrdinaryOwnMetadataKeys:V,OrdinaryDeleteMetadata:ee};return q}function Qt(p,y,k){var x=S.getProvider(p,y);if(!T(x))return x;if(k){if(S.setProvider(p,y,I))return I;throw new Error("Illegal state.")}}function wg(){var p={},y=[],k=function(){function q(v,$,R){this._index=0,this._keys=v,this._values=$,this._selector=R}return q.prototype["@@iterator"]=function(){return this},q.prototype[a]=function(){return this},q.prototype.next=function(){var v=this._index;if(v>=0&&v<this._keys.length){var $=this._selector(this._keys[v],this._values[v]);return v+1>=this._keys.length?(this._index=-1,this._keys=y,this._values=y):this._index++,{value:$,done:!1}}return{value:void 0,done:!0}},q.prototype.throw=function(v){throw this._index>=0&&(this._index=-1,this._keys=y,this._values=y),v},q.prototype.return=function(v){return this._index>=0&&(this._index=-1,this._keys=y,this._values=y),{value:v,done:!0}},q}(),x=function(){function q(){this._keys=[],this._values=[],this._cacheKey=p,this._cacheIndex=-2}return Object.defineProperty(q.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),q.prototype.has=function(v){return this._find(v,!1)>=0},q.prototype.get=function(v){var $=this._find(v,!1);return $>=0?this._values[$]:void 0},q.prototype.set=function(v,$){var R=this._find(v,!0);return this._values[R]=$,this},q.prototype.delete=function(v){var $=this._find(v,!1);if($>=0){for(var R=this._keys.length,A=$+1;A<R;A++)this._keys[A-1]=this._keys[A],this._values[A-1]=this._values[A];return this._keys.length--,this._values.length--,hr(v,this._cacheKey)&&(this._cacheKey=p,this._cacheIndex=-2),!0}return!1},q.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=p,this._cacheIndex=-2},q.prototype.keys=function(){return new k(this._keys,this._values,V)},q.prototype.values=function(){return new k(this._keys,this._values,ee)},q.prototype.entries=function(){return new k(this._keys,this._values,se)},q.prototype["@@iterator"]=function(){return this.entries()},q.prototype[a]=function(){return this.entries()},q.prototype._find=function(v,$){if(!hr(this._cacheKey,v)){this._cacheIndex=-1;for(var R=0;R<this._keys.length;R++)if(hr(this._keys[R],v)){this._cacheIndex=R;break}}return this._cacheIndex<0&&$&&(this._cacheIndex=this._keys.length,this._keys.push(v),this._values.push(void 0)),this._cacheIndex},q}();return x;function V(q,v){return q}function ee(q,v){return v}function se(q,v){return[q,v]}}function bg(){var p=function(){function y(){this._map=new m}return Object.defineProperty(y.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),y.prototype.has=function(k){return this._map.has(k)},y.prototype.add=function(k){return this._map.set(k,k),this},y.prototype.delete=function(k){return this._map.delete(k)},y.prototype.clear=function(){this._map.clear()},y.prototype.keys=function(){return this._map.keys()},y.prototype.values=function(){return this._map.keys()},y.prototype.entries=function(){return this._map.entries()},y.prototype["@@iterator"]=function(){return this.keys()},y.prototype[a]=function(){return this.keys()},y}();return p}function Cg(){var p=16,y=h.create(),k=x();return function(){function v(){this._key=x()}return v.prototype.has=function($){var R=V($,!1);return R!==void 0?h.has(R,this._key):!1},v.prototype.get=function($){var R=V($,!1);return R!==void 0?h.get(R,this._key):void 0},v.prototype.set=function($,R){var A=V($,!0);return A[this._key]=R,this},v.prototype.delete=function($){var R=V($,!1);return R!==void 0?delete R[this._key]:!1},v.prototype.clear=function(){this._key=x()},v}();function x(){var v;do v="@@WeakMap@@"+q();while(h.has(y,v));return y[v]=!0,v}function V(v,$){if(!r.call(v,k)){if(!$)return;Object.defineProperty(v,k,{value:h.create()})}return v[k]}function ee(v,$){for(var R=0;R<$;++R)v[R]=Math.random()*255|0;return v}function se(v){if(typeof Uint8Array=="function"){var $=new Uint8Array(v);return typeof crypto<"u"?crypto.getRandomValues($):typeof msCrypto<"u"?msCrypto.getRandomValues($):ee($,v),$}return ee(new Array(v),v)}function q(){var v=se(p);v[6]=v[6]&79|64,v[8]=v[8]&191|128;for(var $="",R=0;R<p;++R){var A=v[R];(R===4||R===6||R===8)&&($+="-"),A<16&&($+="0"),$+=A.toString(16).toLowerCase()}return $}}function mr(p){return p.__=void 0,delete p.__,p}})})(Br||(Br={}));let an;const vl=new Uint8Array(16);function Ml(){if(!an&&(an=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!an))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return an(vl)}const ue=[];for(let t=0;t<256;++t)ue.push((t+256).toString(16).slice(1));function Bl(t,e=0){return ue[t[e+0]]+ue[t[e+1]]+ue[t[e+2]]+ue[t[e+3]]+"-"+ue[t[e+4]]+ue[t[e+5]]+"-"+ue[t[e+6]]+ue[t[e+7]]+"-"+ue[t[e+8]]+ue[t[e+9]]+"-"+ue[t[e+10]]+ue[t[e+11]]+ue[t[e+12]]+ue[t[e+13]]+ue[t[e+14]]+ue[t[e+15]]}const $r={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Xe(t,e,n){if($r.randomUUID&&!t)return $r.randomUUID();t=t||{};const r=t.random||(t.rng||Ml)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Bl(r)}class ne{static UUID(){return Xe()}static GUID(){const e=function(){return((1+Math.random())*65536|0).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}}function $l(t){var e=[];if(t.length===0)return"";if(typeof t[0]!="string")throw new TypeError("Url must be a string. Received "+t[0]);if(t[0].match(/^[^/:]+:\/*$/)&&t.length>1){var n=t.shift();t[0]=n+t[0]}t[0].match(/^file:\/\/\//)?t[0]=t[0].replace(/^([^/:]+):\/*/,"$1:///"):t[0]=t[0].replace(/^([^/:]+):\/*/,"$1://");for(var r=0;r<t.length;r++){var s=t[r];if(typeof s!="string")throw new TypeError("Url must be a string. Received "+s);s!==""&&(r>0&&(s=s.replace(/^[\/]+/,"")),r<t.length-1?s=s.replace(/[\/]+$/,""):s=s.replace(/[\/]+$/,"/"),e.push(s))}var o=e.join("/");o=o.replace(/\/(\?|&|#[^!])/g,"$1");var a=o.split("?");return o=a.shift()+(a.length>0?"?":"")+a.join("&"),o}function si(){var t;return typeof arguments[0]=="object"?t=arguments[0]:t=[].slice.call(arguments),$l(t)}class U{static Capitalize(e){return e?e[0].toUpperCase()+e.slice(1):""}static BuildSafeUrl(e,n,r){try{const s=new URL(e);return s.port=n.toString(),si(s.toString(),r)}catch{throw new Error(`Invalid host URL: ${e}`)}}static ToCamelCase(e){const n=new RegExp(["[А-Я][а-я][A-Z][a-z]+","[А-Я]+(?=[А-Я][а-я])","[A-Z]+(?=[A-Z][a-z])","[А-Я]+","[A-Z]+","[а-я]+","[a-z]+","[0-9]+"].join("|"),"g");return e.match(n).map((s,o)=>o===0?s.toLowerCase():U.Capitalize(s.toLowerCase())).join("")}static ToKebabCase(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase()}static GetStringBetweenChars(e,n,r){return e.substring(e.indexOf(n)+2,e.lastIndexOf(r))}static Translit(e,n){const r={q:"й",w:"ц",e:"у",r:"к",t:"е",y:"н",u:"г",i:"ш",o:"щ",p:"з","[":"х","]":"ъ",a:"ф",s:"ы",d:"в",f:"а",g:"п",h:"р",j:"о",k:"л",l:"д",";":"ж","'":"э",z:"я",x:"ч",c:"с",v:"м",b:"и",n:"т",m:"ь",",":"б",".":"ю","/":"."};return n&&/[а-яА-Я]/g.test(e)?e.replace(/[А-я/,.;'\][]/g,s=>{if(s===s.toLowerCase()){const a=Object.keys(r).find(c=>r[c]===s);return a||""}const o=Object.keys(r).find(a=>r[a]===s.toLowerCase());return o?o.toUpperCase():""}):e.replace(/[A-z/,.;'\][]/g,s=>s===s.toLowerCase()?r[s]:r[s.toLowerCase()].toUpperCase())}static RemoveEmoji(e){const n=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;return e.replace(n,"")}static CanBeTranslited(e){return/^[~`!@#$%^&*()_+=[\]\\{}|;':",.\/<>?a-zA-Z0-9-]+$/.test(e)}static StringsEquals(e,n){const r=e.toLowerCase().replaceAll(/\s/g,""),s=n.toLowerCase().replaceAll(/\s/g,""),o=U.Translit(r),a=U.Translit(s);return r.includes(s)||o.includes(s)||r.includes(a)}static SearchIn(e,n){return U.StringsEquals(e,n)}static SearchInFields(e,n){let r=!1;for(let s=0;s<n.length;s++)if(U.SearchIn(n[s],e)){r=!0;break}return r}static FormatToPercentage(e){return`${e}%`}static ApplyClassToSubStr(e,n,r){const s=r??"highlight-text",o=new RegExp(U.GetVariants(n).join("|"),"gi");return e.replace(o,`<span class="${s}">$&</span>`)}static GetVariants(e){const n=U.Translit(e);return[e,U.Capitalize(e),e.toLowerCase(),e.toUpperCase(),n,U.Capitalize(n),n.toLowerCase(),n.toUpperCase()]}static ContainsNum(e){return/\d/.test(e)}static JoinSnake(...e){return e.join("_")}static GetDynamicCountName(e,n){const r=[2,0,1,1,1,2];return e.length+" "+n[e.length%100>4&&e.length%100<20?2:r[e.length%10<5?e.length%10:5]]}static TrimText(e){return typeof e=="string"?e.trim():e}}const et=class et{static BuildClass(e,n){n&&Object.keys(n).forEach(r=>{const s=n[r];if(this.isPrimitive(s))e[r]instanceof Date?e[r]=new Date(s):e[r]=s;else if(s!=null&&!Array.isArray(s))if(e[r]&&e[r].constructor)e[r]=new e[r].constructor(s);else{const o=Reflect.getMetadata(r,e);o&&(e[r]=new o[r](s))}if(Array.isArray(s)){if(s.length===0)return;const o=Reflect.getMetadata(r,e);s.length!==0&&!o&&(e[r]=s),o&&(e[r]=s.map(a=>new o[r](a)))}})}static isPrimitive(e){return e!==null&&typeof e<"u"&&e!==Object(e)}static RemoveFromClassByIndex(e,n,r){et.RemoveFromClass(e,n,r)}static RemoveFromClassById(e,n,r){if(!e)return;const s=n.findIndex(o=>o.id===e);et.RemoveFromClass(s,n,r)}static RemoveFromClass(e,n,r){if(e<0)return;const s=n[e].id;s&&r&&r.push(s),n.splice(e,1)}static GetPropertyName(e){const n=new e;return new Proxy(n,{get(r,s){return s}})}static InitClassInstance(e,n){const r=e.constructor(n);return et.BuildClass(r),r.id=ne.UUID(),r}static ExistsWithId(e,n){return e.some(r=>r.id===n)}static DeepMap(e){return n=>Array.isArray(n)?n.map(et.DeepMap(e)):Object(n)===n?Object.fromEntries(Object.entries(n).map(([r,s])=>[r,et.DeepMap(e)(s)])):e(n)}static DeepTrim(e){return this.DeepMap(U.TrimText)(e)}};l(et,"GetClassConstructor",e=>(n,r)=>{const s=Reflect.getMetadata(`property:${r}`,n)||{};s[r]=e,Reflect.defineMetadata(r,s,n)});let M=et;class rt{constructor(e){l(this,"id");l(this,"address");l(this,"description");l(this,"contactId");M.BuildClass(this,e)}static Create(){const e=new rt;return e.id=ne.UUID(),e}}class oi{static Setup(e="http://localhost",n="9000",r="api"){this.staticUrl=U.BuildSafeUrl(e,n,r),this.staticUrl=si(this.staticUrl,"static")}static get StaticUrl(){return this.staticUrl}}l(oi,"staticUrl","");class me{constructor(e){l(this,"name","");l(this,"url","");l(this,"src","");l(this,"raw");l(this,"blob");l(this,"file");l(this,"type","");l(this,"id");l(this,"originalName","");l(this,"fileSystemPath","");l(this,"itemId");l(this,"itemOneId");l(this,"description","");l(this,"order",0);M.BuildClass(this,e)}getFileUrl(){const e=this.url?this.url:`${oi.StaticUrl}/${this.fileSystemPath}`;return new URL(e,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Ie&&Ie.tagName.toUpperCase()==="SCRIPT"&&Ie.src||new URL("sprof.umd.cjs",document.baseURI).href)}getFileListObject(){return{name:this.originalName,url:this.url}}static CreatePreviewFile(e,n){const r=new me;return r.id=n??ne.UUID(),r.originalName=e.name,r.file=e.blob,r.fileSystemPath=ne.UUID(),r}setFile(e){this.id||(this.id=ne.UUID()),this.originalName=e.name,this.file=e,this.fileSystemPath=ne.UUID(),this.url=e.src}clearFile(){this.url="",this.file=void 0,this.fileSystemPath="",this.originalName=""}errorImg(e,n){if(e.target){let r="";return n&&(r=`@/assets/img/${n}`),new URL(r,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Ie&&Ie.tagName.toUpperCase()==="SCRIPT"&&Ie.src||new URL("sprof.umd.cjs",document.baseURI).href)}}getFileInfos(){return[this]}isPdf(){return this.getExtension(this.originalName)===""}getExtension(e){const n=e.split(".");return n[n.length-1]}}class Ir{constructor(e){l(this,"id");l(this,"name","");l(this,"surname","");l(this,"patronymic","");l(this,"isMale",!0);l(this,"dateBirth",new Date);l(this,"contactId");l(this,"slug","");l(this,"postIndex","");l(this,"address","");l(this,"editNameMode",!1);M.BuildClass(this,e)}setEditNameMode(e){this.editNameMode=e}getFullName(){return!this.surname.length&&!this.name.length&&!this.patronymic.length?"":`${this.surname} ${this.name} ${this.patronymic}`}getInitialsName(){return`${this.name.slice(0,1)}.${this.patronymic.slice(0,1)}. ${this.surname}`}getGender(e){return e?this.isMale?"Мужской":"Женский":this.isMale?"М":"Ж"}capitalizeName(){this.name=U.Capitalize(this.name),this.surname=U.Capitalize(this.surname),this.patronymic=U.Capitalize(this.patronymic)}trimName(){this.name=this.name.trim(),this.surname=this.surname.trim(),this.patronymic=this.patronymic.trim()}sanitizeName(){this.trimName(),this.capitalizeName()}setFullName(e){this.surname=e.surname,this.name=e.name,this.patronymic=e.patronymic}}class st{constructor(e){l(this,"id");l(this,"number");l(this,"description");l(this,"contactId");M.BuildClass(this,e)}static Create(){const e=new st;return e.id=ne.UUID(),e}}class ln{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class ai{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class cn{constructor(e){l(this,"id");l(this,"login","");l(this,"email","");l(this,"password","");M.BuildClass(this,e)}static Create(){const e=new cn;return e.id=ne.UUID(),e}}let Il=(Je=class{},l(Je,"Phone",st),l(Je,"FileInfo",me),l(Je,"Website",ai),l(Je,"Email",rt),l(Je,"Human",Ir),l(Je,"PostAddress",ln),l(Je,"UserAccount",cn),Je);var Y=(t=>(t.Eq="=",t.Ne="!=",t.Gt=">",t.Lt="<",t.Btw="between",t.In="in",t.Like="like",t.Null="is null",t.NotNull="is not null",t))(Y||{});class dn{constructor(e){l(this,"field","");l(this,"operator",Y.Eq);l(this,"value","");M.BuildClass(this,e)}setValue(e){this.value=e}static Create(e,n){return new dn({operator:n,field:e})}eq(e){return this.field===e.field&&this.operator===e.operator}isUnary(){return this.operator===Y.Eq||this.operator===Y.Gt||this.operator===Y.Lt}isBetween(){return this.operator===Y.Btw}isSet(){return this.operator===Y.In}}class li{constructor(e){l(this,"model","");l(this,"field","");l(this,"value","");l(this,"wheres",[]);M.BuildClass(this,e)}static Create(e){const n=new li;return n.model=e.GetClassName(),n}eq(e){return e.model===this.model&&e.field===this.field}addWhere(e,n){const r=this.findWhere({field:e,operator:n});if(r)return r;const s=dn.Create(e,n);return this.wheres.push(s),s}findWhere(e){return this.wheres.find(n=>n.eq(e))}}let Rr=class ol{constructor(e){l(this,"id");l(this,"model","");l(this,"wheres",[]);l(this,"joins",[]);M.BuildClass(this,e)}static Create(e){const n=new ol;return n.model=e.GetClassName(),n}addWhere(e,n){const r=this.findWhere({field:e,operator:n});if(r)return r;const s=dn.Create(e,n);return this.wheres.push(s),s}removeWhere(e){const n=this.wheres.findIndex(r=>r.eq(e));n>-1&&this.wheres.splice(n,1)}addJoin(e){const n=this.findJoin({model:e.GetClassName()});if(n)return n;const r=li.Create(e);return this.joins.push(r),r}findJoin(e){return this.joins.find(n=>n.eq(e))}findWhere(e){return this.wheres.find(n=>n.eq(e))}toRef(){return i.ref(this)}};class Ue{static Shuffle(e){for(let n=e.length-1;n>0;n--){const r=Math.floor(Math.random()*(n+1));[e[n],e[r]]=[e[r],e[n]]}}static GenerateNumsRange(e,n,r=1){return Array.from({length:(n-e)/r+1},(s,o)=>e+o*r)}static GetLast(e){return e[e.length-1]}static GetFirst(e){return e[0]}static GetRandEL(e){return e[Math.floor(Math.random()*e.length)]}static Sort(e){e.forEach((n,r)=>n.order=r)}static Refill(e,n){e.splice(0,e.length),e.push(...n)}static Eq(e,n){return e.length===n.length&&(e==null?void 0:e.every((r,s)=>e[s]==n[s]))}static SwipeById(e,n,r){const s=e.findIndex(a=>n.id===a.id),o=e.findIndex(a=>r.id===a.id);s||o||([e[s],e[o]]=[e[o],e[s]])}static Swap(e,n,r){if(n<0||n>=e.length||r<0||r>=e.length)return;const s=e[n];e[n]=e[r],e[r]=s}static MoveUp(e,n){e[n].order=n-1,e[n-1]&&(e[n-1].order=n),[e[n],e[n-1]]=[e[n-1],e[n]]}static MoveDown(e,n){e[n].order=n+1,e[n+1]&&(e[n+1].order=n),[e[n],e[n+1]]=[e[n+1],e[n]]}}var ae=(t=>(t.Date="date",t.String="string",t.Boolean="boolean",t.Number="number",t.Set="set",t.Join="join",t.ArrayString="arrayString",t.ArrayNumber="arrayNumber",t))(ae||{}),Rl=Object.defineProperty,Nl=(t,e,n,r)=>{for(var s=void 0,o=t.length-1,a;o>=0;o--)(a=t[o])&&(s=a(e,n,s)||s);return s&&Rl(e,n,s),s};const Nr=class Kt{constructor(e){l(this,"id");l(this,"model","");l(this,"label","");l(this,"col","");l(this,"operator",Y.Eq);l(this,"date1");l(this,"date2");l(this,"value1","");l(this,"boolean",!1);l(this,"number",0);l(this,"type",ae.String);l(this,"set",[]);l(this,"isSet",!1);l(this,"joinTable","");l(this,"joinTableModel","");l(this,"joinTableFk","");l(this,"joinTablePk","");l(this,"joinTableId","");l(this,"joinTableIdCol","");M.BuildClass(this,e)}eq(e){if(!e)return!1;if(this.type===ae.Join){const n=e.model===this.model&&e.operator===this.operator&&this.joinTableModel===e.joinTableModel;return e.operator===Y.In?n&&Ue.Eq(this.set,e.set):n}return e.model===this.model&&e.col===this.col&&e.operator===this.operator}valueEq(e){return!this||!e||!this.eq(e)?!1:this.type===ae.Boolean?this.boolean===(e==null?void 0:e.boolean):this.type===ae.String?this.value1===(e==null?void 0:e.value1):this.type===ae.Join&&this.set.length?Ue.Eq(this.set,e.set):!1}toUrlQuery(){const e=this.type?`"type":"${this.type}"`:"",n=this.model?`"model":"${this.model}"`:"",r=this.col?`"col":"${this.col}"`:"",s=this.operator?`"operator":"${this.operator}"`:"",o=this.value1?`"value1":"${this.value1}"`:"",a=this.type===ae.Boolean?`"boolean":${this.boolean}`:"",c=this.type===ae.Date&&this.date1?`"date1":"${this.date1.toISOString()}"`:"",d=this.type===ae.Date&&this.date2?`"date2":"${this.date2.toISOString()}"`:"",u=this.type===ae.Number?`"number":${this.number}`:"",h=this.type===ae.Set||this.operator===Y.In?`"set":${JSON.stringify(this.set)}`:"",f=this.type===ae.Join?`"joinTableModel":"${this.joinTableModel}"`:"";return[e,n,r,s,o,a,c,d,u,h,f].filter(m=>m!=="").toString()}fromUrlQuery(e){this.model=e.get("model")??"",this.col=e.get("col")??"",this.label=e.get("label")??"",this.operator=e.get("operator")??"",this.value1=e.get("value1")??"",this.type=e.get("type")??"",this.boolean=!!(e.get("boolean")??""),this.joinTableModel=e.get("joinTableModel")??"",this.joinTableId=e.get("joinTableId")??"",this.joinTableFk=e.get("joinTableFk")??"",this.joinTableIdCol=e.get("joinTableIdCol")??"",this.joinTablePk=e.get("joinTablePk")??""}isUnaryFilter(){return this.operator===Y.Eq||this.operator===Y.Gt||this.operator===Y.Lt}isBetweenFilter(){return this.operator===Y.Btw}isSetFilter(){return this.operator===Y.In}static Create(e,n,r){const s=new Kt;return s.model=e.GetClassName(),s.col=n??"",s.type=r,s.type===ae.Number&&(s.value1="0"),s.type===ae.String&&(s.value1=""),s.type===ae.Boolean&&(s.value1="false",s.operator=Y.Eq),s}static CreateFilterModelWithJoin(e,n,r,s,o,a,c,d){const u=new Kt;return u.id=Xe(),u.joinTable=r,u.joinTablePk=s,u.joinTableFk=o,u.col=n,u.type=a,c&&(u.joinTableId=c),d&&(u.joinTableIdCol=d),u}static CreateFilterModelWithJoinV2(e,n,r,s,o,a,c){const d=new Kt;return d.model=e,d.joinTableModel=r,d.joinTablePk=s,d.joinTableFk=o,d.col=n,d.type=ae.Join,a&&(d.joinTableId=a),c&&(d.joinTableIdCol=c),d}static OnlyIfSecondModelExists(e,n){const r=new Kt;return r.id=Xe(),r.model=U.ToCamelCase(e.GetClassName()),r.joinTableModel=U.ToCamelCase(n.GetClassName()),r.type=ae.Join,r}addToSet(...e){e.forEach(n=>{if(this.set.indexOf(n)===-1){this.set.push(n);return}this.set=this.set.filter(r=>r!==n)})}pushToSet(...e){e.forEach(n=>{this.set.indexOf(n)===-1&&this.set.push(n)})}replaceSet(...e){this.set=e}setBoolean(e){this.boolean=e}toRef(){return i.ref(this)}setDate1(e){this.date1=e}setDate2(e){this.date2=e}dropDates(){this.setDate1(),this.setDate2()}setDatesRange(e,n){if(!e&&!n){this.dropDates();return}if(!n){this.setDate1(e),this.operator=Y.Eq;return}this.setDate2(n),this.operator=Y.Btw}};Nl([M.GetClassConstructor(String)],Nr.prototype,"set");let ci=Nr;class Al{constructor(){l(this,"operation",Y.Lt);l(this,"column","");l(this,"value");l(this,"initial",!0);l(this,"tableName","");l(this,"version","");l(this,"model","")}toUrlQuery(){const e=this.operation?`"operation":"${this.operation}"`:"",n=this.column?`"column":"${this.column}"`:"",r=this.value&&typeof this.value.toISOString=="function"?this.value.toISOString():this.value,s=r?`"value":"${r}"`:"",o=this.model?`"model":"${this.model}"`:"",a=`"initial":${this.initial}`;return[e,n,s,o,a].filter(c=>c!=="").toString()}fromUrlQuery(e){e.cursvalue&&(this.value=e.cursvalue),e.curscolumn&&(this.column=String(e.curscolumn)),e.cursinitial!==void 0&&(this.initial=!!e.cursinitial),e.curstableName&&(this.tableName=String(e.curstableName)),e.cursoperation&&(this.operation=e.cursoperation)}}class un{constructor(e){l(this,"page",0);l(this,"rowsPerPage",25);l(this,"rowsNumber",0);l(this,"cursor",new Al);l(this,"cursorMode",!1);l(this,"append",!1);l(this,"allLoaded",!1);l(this,"version","");M.BuildClass(this,e)}setLoadMore(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=Y.Gt,this.cursor.column=n,this.cursor.tableName=r,this.cursorMode=!0}setLoadMoreV2(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=Y.Gt,this.cursor.column=n,this.cursor.model=r,this.cursorMode=!0,this.version="v2"}setOffset(e){this.page=e}toUrlQuery(){const e=`"offset":${this.offset}`,n=`"limit":${this.limit}`,r=`"cursorMode":${this.cursorMode}`,s=`"append":${this.append}`,o=`"allLoaded":${this.allLoaded}`,a=`"cursor":{${this.cursor.toUrlQuery()}}`;return[e,n,r,s,o,a].toString()}fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("p=")+2,e.lastIndexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.page=Number(r.get("offset")),this.rowsPerPage=Number(r.get("col"))}setAllLoaded(e){this.allLoaded=!(e>=this.rowsPerPage)}resetAllLoaded(){this.allLoaded=!1}getPageNum(){return this.page/this.rowsPerPage+1}drop(){this.page=0,this.rowsPerPage=25,M.BuildClass(this)}}var Ee=(t=>(t.Asc="asc",t.Desc="desc",t))(Ee||{});class hn{constructor(e){l(this,"model","");l(this,"col","");l(this,"order");l(this,"label","");l(this,"default",!1);l(this,"selected",!1);M.BuildClass(this,e)}static Create(e,n,r=Ee.Asc,s,o){const a=new hn;return a.model=e.GetClassName(),a.col=n??"",a.order=r??Ee.Asc,a.label=s??"",a.default=o??!1,a}isAsc(){return this.order===Ee.Asc}isDesc(){return this.order===Ee.Desc}eq(e){return e.model===this.model&&e.col===this.col&&e.order===this.order}toUrlQuery(){const e=this.model?`"model":"${this.model}"`:"",n=this.col?`"col":"${this.col}"`:"",r=this.order?`"order":"${this.order}"`:"";return[e,n,r].toString()}async fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("s=")+2,e.indexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.model=r.get("model")??"",this.col=r.get("col")??"",this.label=r.get("label")??"",this.default=!!r.get("default"),this.order=r.get("order")??""}asc(){this.order=Ee.Asc}desc(){this.order=Ee.Desc}}class fn{constructor(){l(this,"model","");l(this,"cols",[]);l(this,"models",[])}static Create(e,n){const r=new fn;return r.model=e.GetClassName(),r.cols=n,r}}var Pl=Object.defineProperty,Tt=(t,e,n,r)=>{for(var s=void 0,o=t.length-1,a;o>=0;o--)(a=t[o])&&(s=a(e,n,s)||s);return s&&Pl(e,n,s),s};const gt=(Se=class{constructor(e){l(this,"id");l(this,"f",[]);l(this,"f2",[]);l(this,"s",[]);l(this,"p",new un);l(this,"t",new fn);M.BuildClass(this,e)}static Get(){return this.instance||(this.instance=new Se),this.instance}createFrom(e){const n=new Se(JSON.parse(e));this.f=n.f}clearForHTTP(){const e=new Se(this);return e.f=this.f.map(n=>Se.EmptyEntiries(n)),e.f2=this.f2.map(n=>Se.EmptyEntiries(n)),e.s=this.s.map(n=>Se.EmptyEntiries(n)),e.p=Se.EmptyEntiries(this.p),e.t=Se.EmptyEntiries(this.t),e}static EmptyEntiries(e){if(!e)return;const r=Object.entries(e).filter(([s,o])=>s!=="label"&&o!==""&&o!==null);return Object.fromEntries(r)}findFilterModel(e){return this.f.find(n=>e.id===n.id)}getFirstSortModel(){return Ue.GetLast(this.s)}setSortModel(e){e&&(this.s[0]=e)}setS(e){this.s[0]=e}setF(e){this.f.push(e)}setF2(e){this.f2.push(e)}replaceF(e,n){this.removeF(n),e&&this.setF(e)}removeF(e){const n=this.f.findIndex(r=>r.eq(e));M.RemoveFromClassByIndex(n,this.f)}reset(){this.f=[],this.s=[],this.p=new un}resetF(){this.f=[]}},l(Se,"instance"),Se);Tt([M.GetClassConstructor(ci)],gt.prototype,"f"),Tt([M.GetClassConstructor(Rr)],gt.prototype,"f2"),Tt([M.GetClassConstructor(hn)],gt.prototype,"s"),Tt([M.GetClassConstructor(un)],gt.prototype,"p"),Tt([M.GetClassConstructor(fn)],gt.prototype,"t");let je=gt,zl=(Nt=class{},l(Nt,"SortModel",hn),l(Nt,"FilterModel",ci),l(Nt,"FilterModelV2",Rr),l(Nt,"FTSP",je),Nt);function Ar(t,e){return function(){return t.apply(e,arguments)}}const{toString:Vl}=Object.prototype,{getPrototypeOf:di}=Object,{iterator:mn,toStringTag:Pr}=Symbol,pn=(t=>e=>{const n=Vl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Ne=t=>(t=t.toLowerCase(),e=>pn(e)===t),gn=t=>e=>typeof e===t,{isArray:yt}=Array,Ft=gn("undefined");function Ot(t){return t!==null&&!Ft(t)&&t.constructor!==null&&!Ft(t.constructor)&&we(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const zr=Ne("ArrayBuffer");function Tl(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&zr(t.buffer),e}const Fl=gn("string"),we=gn("function"),Vr=gn("number"),Dt=t=>t!==null&&typeof t=="object",Ol=t=>t===!0||t===!1,yn=t=>{if(pn(t)!=="object")return!1;const e=di(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Pr in t)&&!(mn in t)},Dl=t=>{if(!Dt(t)||Ot(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},Ll=Ne("Date"),Hl=Ne("File"),ql=Ne("Blob"),Ul=Ne("FileList"),jl=t=>Dt(t)&&we(t.pipe),Wl=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||we(t.append)&&((e=pn(t))==="formdata"||e==="object"&&we(t.toString)&&t.toString()==="[object FormData]"))},_l=Ne("URLSearchParams"),[Gl,Zl,Jl,Xl]=["ReadableStream","Request","Response","Headers"].map(Ne),Yl=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Lt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,s;if(typeof t!="object"&&(t=[t]),yt(t))for(r=0,s=t.length;r<s;r++)e.call(null,t[r],r,t);else{if(Ot(t))return;const o=n?Object.getOwnPropertyNames(t):Object.keys(t),a=o.length;let c;for(r=0;r<a;r++)c=o[r],e.call(null,t[c],c,t)}}function Tr(t,e){if(Ot(t))return null;e=e.toLowerCase();const n=Object.keys(t);let r=n.length,s;for(;r-- >0;)if(s=n[r],e===s.toLowerCase())return s;return null}const ot=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Fr=t=>!Ft(t)&&t!==ot;function ui(){const{caseless:t}=Fr(this)&&this||{},e={},n=(r,s)=>{const o=t&&Tr(e,s)||s;yn(e[o])&&yn(r)?e[o]=ui(e[o],r):yn(r)?e[o]=ui({},r):yt(r)?e[o]=r.slice():e[o]=r};for(let r=0,s=arguments.length;r<s;r++)arguments[r]&&Lt(arguments[r],n);return e}const Ql=(t,e,n,{allOwnKeys:r}={})=>(Lt(e,(s,o)=>{n&&we(s)?t[o]=Ar(s,n):t[o]=s},{allOwnKeys:r}),t),Kl=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),ec=(t,e,n,r)=>{t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},tc=(t,e,n,r)=>{let s,o,a;const c={};if(e=e||{},t==null)return e;do{for(s=Object.getOwnPropertyNames(t),o=s.length;o-- >0;)a=s[o],(!r||r(a,t,e))&&!c[a]&&(e[a]=t[a],c[a]=!0);t=n!==!1&&di(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},nc=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const r=t.indexOf(e,n);return r!==-1&&r===n},ic=t=>{if(!t)return null;if(yt(t))return t;let e=t.length;if(!Vr(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},rc=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&di(Uint8Array)),sc=(t,e)=>{const r=(t&&t[mn]).call(t);let s;for(;(s=r.next())&&!s.done;){const o=s.value;e.call(t,o[0],o[1])}},oc=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},ac=Ne("HTMLFormElement"),lc=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),Or=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),cc=Ne("RegExp"),Dr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Lt(n,(s,o)=>{let a;(a=e(s,o,t))!==!1&&(r[o]=a||s)}),Object.defineProperties(t,r)},dc=t=>{Dr(t,(e,n)=>{if(we(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=t[n];if(we(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},uc=(t,e)=>{const n={},r=s=>{s.forEach(o=>{n[o]=!0})};return yt(t)?r(t):r(String(t).split(e)),n},hc=()=>{},fc=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function mc(t){return!!(t&&we(t.append)&&t[Pr]==="FormData"&&t[mn])}const pc=t=>{const e=new Array(10),n=(r,s)=>{if(Dt(r)){if(e.indexOf(r)>=0)return;if(Ot(r))return r;if(!("toJSON"in r)){e[s]=r;const o=yt(r)?[]:{};return Lt(r,(a,c)=>{const d=n(a,s+1);!Ft(d)&&(o[c]=d)}),e[s]=void 0,o}}return r};return n(t,0)},gc=Ne("AsyncFunction"),yc=t=>t&&(Dt(t)||we(t))&&we(t.then)&&we(t.catch),Lr=((t,e)=>t?setImmediate:e?((n,r)=>(ot.addEventListener("message",({source:s,data:o})=>{s===ot&&o===n&&r.length&&r.shift()()},!1),s=>{r.push(s),ot.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",we(ot.postMessage)),wc=typeof queueMicrotask<"u"?queueMicrotask.bind(ot):typeof process<"u"&&process.nextTick||Lr,w={isArray:yt,isArrayBuffer:zr,isBuffer:Ot,isFormData:Wl,isArrayBufferView:Tl,isString:Fl,isNumber:Vr,isBoolean:Ol,isObject:Dt,isPlainObject:yn,isEmptyObject:Dl,isReadableStream:Gl,isRequest:Zl,isResponse:Jl,isHeaders:Xl,isUndefined:Ft,isDate:Ll,isFile:Hl,isBlob:ql,isRegExp:cc,isFunction:we,isStream:jl,isURLSearchParams:_l,isTypedArray:rc,isFileList:Ul,forEach:Lt,merge:ui,extend:Ql,trim:Yl,stripBOM:Kl,inherits:ec,toFlatObject:tc,kindOf:pn,kindOfTest:Ne,endsWith:nc,toArray:ic,forEachEntry:sc,matchAll:oc,isHTMLForm:ac,hasOwnProperty:Or,hasOwnProp:Or,reduceDescriptors:Dr,freezeMethods:dc,toObjectSet:uc,toCamelCase:lc,noop:hc,toFiniteNumber:fc,findKey:Tr,global:ot,isContextDefined:Fr,isSpecCompliantForm:mc,toJSONObject:pc,isAsyncFn:gc,isThenable:yc,setImmediate:Lr,asap:wc,isIterable:t=>t!=null&&we(t[mn])};function F(t,e,n,r,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),s&&(this.response=s,this.status=s.status?s.status:null)}w.inherits(F,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:w.toJSONObject(this.config),code:this.code,status:this.status}}});const Hr=F.prototype,qr={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{qr[t]={value:t}}),Object.defineProperties(F,qr),Object.defineProperty(Hr,"isAxiosError",{value:!0}),F.from=(t,e,n,r,s,o)=>{const a=Object.create(Hr);return w.toFlatObject(t,a,function(d){return d!==Error.prototype},c=>c!=="isAxiosError"),F.call(a,t.message,e,n,r,s),a.cause=t,a.name=t.name,o&&Object.assign(a,o),a};const bc=null;function hi(t){return w.isPlainObject(t)||w.isArray(t)}function Ur(t){return w.endsWith(t,"[]")?t.slice(0,-2):t}function jr(t,e,n){return t?t.concat(e).map(function(s,o){return s=Ur(s),!n&&o?"["+s+"]":s}).join(n?".":""):e}function Cc(t){return w.isArray(t)&&!t.some(hi)}const Sc=w.toFlatObject(w,{},null,function(e){return/^is[A-Z]/.test(e)});function wn(t,e,n){if(!w.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=w.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(b,S){return!w.isUndefined(S[b])});const r=n.metaTokens,s=n.visitor||h,o=n.dots,a=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&w.isSpecCompliantForm(e);if(!w.isFunction(s))throw new TypeError("visitor must be a function");function u(C){if(C===null)return"";if(w.isDate(C))return C.toISOString();if(w.isBoolean(C))return C.toString();if(!d&&w.isBlob(C))throw new F("Blob is not supported. Use a Buffer instead.");return w.isArrayBuffer(C)||w.isTypedArray(C)?d&&typeof Blob=="function"?new Blob([C]):Buffer.from(C):C}function h(C,b,S){let I=C;if(C&&!S&&typeof C=="object"){if(w.endsWith(b,"{}"))b=r?b:b.slice(0,-2),C=JSON.stringify(C);else if(w.isArray(C)&&Cc(C)||(w.isFileList(C)||w.endsWith(b,"[]"))&&(I=w.toArray(C)))return b=Ur(b),I.forEach(function(z,N){!(w.isUndefined(z)||z===null)&&e.append(a===!0?jr([b],N,o):a===null?b:b+"[]",u(z))}),!1}return hi(C)?!0:(e.append(jr(S,b,o),u(C)),!1)}const f=[],m=Object.assign(Sc,{defaultVisitor:h,convertValue:u,isVisitable:hi});function g(C,b){if(!w.isUndefined(C)){if(f.indexOf(C)!==-1)throw Error("Circular reference detected in "+b.join("."));f.push(C),w.forEach(C,function(I,L){(!(w.isUndefined(I)||I===null)&&s.call(e,I,w.isString(L)?L.trim():L,b,m))===!0&&g(I,b?b.concat(L):[L])}),f.pop()}}if(!w.isObject(t))throw new TypeError("data must be an object");return g(t),e}function Wr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function fi(t,e){this._pairs=[],t&&wn(t,this,e)}const _r=fi.prototype;_r.append=function(e,n){this._pairs.push([e,n])},_r.toString=function(e){const n=e?function(r){return e.call(this,r,Wr)}:Wr;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function kc(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Gr(t,e,n){if(!e)return t;const r=n&&n.encode||kc;w.isFunction(n)&&(n={serialize:n});const s=n&&n.serialize;let o;if(s?o=s(e,n):o=w.isURLSearchParams(e)?e.toString():new fi(e,n).toString(r),o){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+o}return t}class Zr{constructor(){this.handlers=[]}use(e,n,r){return this.handlers.push({fulfilled:e,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){w.forEach(this.handlers,function(r){r!==null&&e(r)})}}const Jr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ec={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:fi,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},mi=typeof window<"u"&&typeof document<"u",pi=typeof navigator=="object"&&navigator||void 0,xc=mi&&(!pi||["ReactNative","NativeScript","NS"].indexOf(pi.product)<0),vc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Mc=mi&&window.location.href||"http://localhost",pe={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:mi,hasStandardBrowserEnv:xc,hasStandardBrowserWebWorkerEnv:vc,navigator:pi,origin:Mc},Symbol.toStringTag,{value:"Module"})),...Ec};function Bc(t,e){return wn(t,new pe.classes.URLSearchParams,{visitor:function(n,r,s,o){return pe.isNode&&w.isBuffer(n)?(this.append(r,n.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...e})}function $c(t){return w.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function Ic(t){const e={},n=Object.keys(t);let r;const s=n.length;let o;for(r=0;r<s;r++)o=n[r],e[o]=t[o];return e}function Xr(t){function e(n,r,s,o){let a=n[o++];if(a==="__proto__")return!0;const c=Number.isFinite(+a),d=o>=n.length;return a=!a&&w.isArray(s)?s.length:a,d?(w.hasOwnProp(s,a)?s[a]=[s[a],r]:s[a]=r,!c):((!s[a]||!w.isObject(s[a]))&&(s[a]=[]),e(n,r,s[a],o)&&w.isArray(s[a])&&(s[a]=Ic(s[a])),!c)}if(w.isFormData(t)&&w.isFunction(t.entries)){const n={};return w.forEachEntry(t,(r,s)=>{e($c(r),s,n,0)}),n}return null}function Rc(t,e,n){if(w.isString(t))try{return(e||JSON.parse)(t),w.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(t)}const Ht={transitional:Jr,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,o=w.isObject(e);if(o&&w.isHTMLForm(e)&&(e=new FormData(e)),w.isFormData(e))return s?JSON.stringify(Xr(e)):e;if(w.isArrayBuffer(e)||w.isBuffer(e)||w.isStream(e)||w.isFile(e)||w.isBlob(e)||w.isReadableStream(e))return e;if(w.isArrayBufferView(e))return e.buffer;if(w.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let c;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Bc(e,this.formSerializer).toString();if((c=w.isFileList(e))||r.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return wn(c?{"files[]":e}:e,d&&new d,this.formSerializer)}}return o||s?(n.setContentType("application/json",!1),Rc(e)):e}],transformResponse:[function(e){const n=this.transitional||Ht.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(w.isResponse(e)||w.isReadableStream(e))return e;if(e&&w.isString(e)&&(r&&!this.responseType||s)){const a=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(e)}catch(c){if(a)throw c.name==="SyntaxError"?F.from(c,F.ERR_BAD_RESPONSE,this,null,this.response):c}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:pe.classes.FormData,Blob:pe.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};w.forEach(["delete","get","head","post","put","patch"],t=>{Ht.headers[t]={}});const Nc=w.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Ac=t=>{const e={};let n,r,s;return t&&t.split(`
15
15
  `).forEach(function(a){s=a.indexOf(":"),n=a.substring(0,s).trim().toLowerCase(),r=a.substring(s+1).trim(),!(!n||e[n]&&Nc[n])&&(n==="set-cookie"?e[n]?e[n].push(r):e[n]=[r]:e[n]=e[n]?e[n]+", "+r:r)}),e},Yr=Symbol("internals");function qt(t){return t&&String(t).trim().toLowerCase()}function bn(t){return t===!1||t==null?t:w.isArray(t)?t.map(bn):String(t)}function Pc(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(t);)e[r[1]]=r[2];return e}const zc=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function gi(t,e,n,r,s){if(w.isFunction(r))return r.call(this,e,n);if(s&&(e=n),!!w.isString(e)){if(w.isString(r))return e.indexOf(r)!==-1;if(w.isRegExp(r))return r.test(e)}}function Vc(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,r)=>n.toUpperCase()+r)}function Tc(t,e){const n=w.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+n,{value:function(s,o,a){return this[r].call(this,e,s,o,a)},configurable:!0})})}let be=class{constructor(e){e&&this.set(e)}set(e,n,r){const s=this;function o(c,d,u){const h=qt(d);if(!h)throw new Error("header name must be a non-empty string");const f=w.findKey(s,h);(!f||s[f]===void 0||u===!0||u===void 0&&s[f]!==!1)&&(s[f||d]=bn(c))}const a=(c,d)=>w.forEach(c,(u,h)=>o(u,h,d));if(w.isPlainObject(e)||e instanceof this.constructor)a(e,n);else if(w.isString(e)&&(e=e.trim())&&!zc(e))a(Ac(e),n);else if(w.isObject(e)&&w.isIterable(e)){let c={},d,u;for(const h of e){if(!w.isArray(h))throw TypeError("Object iterator must return a key-value pair");c[u=h[0]]=(d=c[u])?w.isArray(d)?[...d,h[1]]:[d,h[1]]:h[1]}a(c,n)}else e!=null&&o(n,e,r);return this}get(e,n){if(e=qt(e),e){const r=w.findKey(this,e);if(r){const s=this[r];if(!n)return s;if(n===!0)return Pc(s);if(w.isFunction(n))return n.call(this,s,r);if(w.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=qt(e),e){const r=w.findKey(this,e);return!!(r&&this[r]!==void 0&&(!n||gi(this,this[r],r,n)))}return!1}delete(e,n){const r=this;let s=!1;function o(a){if(a=qt(a),a){const c=w.findKey(r,a);c&&(!n||gi(r,r[c],c,n))&&(delete r[c],s=!0)}}return w.isArray(e)?e.forEach(o):o(e),s}clear(e){const n=Object.keys(this);let r=n.length,s=!1;for(;r--;){const o=n[r];(!e||gi(this,this[o],o,e,!0))&&(delete this[o],s=!0)}return s}normalize(e){const n=this,r={};return w.forEach(this,(s,o)=>{const a=w.findKey(r,o);if(a){n[a]=bn(s),delete n[o];return}const c=e?Vc(o):String(o).trim();c!==o&&delete n[o],n[c]=bn(s),r[c]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return w.forEach(this,(r,s)=>{r!=null&&r!==!1&&(n[s]=e&&w.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
16
16
  `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...n){const r=new this(e);return n.forEach(s=>r.set(s)),r}static accessor(e){const r=(this[Yr]=this[Yr]={accessors:{}}).accessors,s=this.prototype;function o(a){const c=qt(a);r[c]||(Tc(s,a),r[c]=!0)}return w.isArray(e)?e.forEach(o):o(e),this}};be.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),w.reduceDescriptors(be.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(r){this[n]=r}}}),w.freezeMethods(be);function yi(t,e){const n=this||Ht,r=e||n,s=be.from(r.headers);let o=r.data;return w.forEach(t,function(c){o=c.call(n,o,s.normalize(),e?e.status:void 0)}),s.normalize(),o}function Qr(t){return!!(t&&t.__CANCEL__)}function wt(t,e,n){F.call(this,t??"canceled",F.ERR_CANCELED,e,n),this.name="CanceledError"}w.inherits(wt,F,{__CANCEL__:!0});function Kr(t,e,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?t(n):e(new F("Request failed with status code "+n.status,[F.ERR_BAD_REQUEST,F.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function Fc(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function Oc(t,e){t=t||10;const n=new Array(t),r=new Array(t);let s=0,o=0,a;return e=e!==void 0?e:1e3,function(d){const u=Date.now(),h=r[o];a||(a=u),n[s]=d,r[s]=u;let f=o,m=0;for(;f!==s;)m+=n[f++],f=f%t;if(s=(s+1)%t,s===o&&(o=(o+1)%t),u-a<e)return;const g=h&&u-h;return g?Math.round(m*1e3/g):void 0}}function Dc(t,e){let n=0,r=1e3/e,s,o;const a=(u,h=Date.now())=>{n=h,s=null,o&&(clearTimeout(o),o=null),t(...u)};return[(...u)=>{const h=Date.now(),f=h-n;f>=r?a(u,h):(s=u,o||(o=setTimeout(()=>{o=null,a(s)},r-f)))},()=>s&&a(s)]}const Cn=(t,e,n=3)=>{let r=0;const s=Oc(50,250);return Dc(o=>{const a=o.loaded,c=o.lengthComputable?o.total:void 0,d=a-r,u=s(d),h=a<=c;r=a;const f={loaded:a,total:c,progress:c?a/c:void 0,bytes:d,rate:u||void 0,estimated:u&&c&&h?(c-a)/u:void 0,event:o,lengthComputable:c!=null,[e?"download":"upload"]:!0};t(f)},n)},es=(t,e)=>{const n=t!=null;return[r=>e[0]({lengthComputable:n,total:t,loaded:r}),e[1]]},ts=t=>(...e)=>w.asap(()=>t(...e)),Lc=pe.hasStandardBrowserEnv?((t,e)=>n=>(n=new URL(n,pe.origin),t.protocol===n.protocol&&t.host===n.host&&(e||t.port===n.port)))(new URL(pe.origin),pe.navigator&&/(msie|trident)/i.test(pe.navigator.userAgent)):()=>!0,Hc=pe.hasStandardBrowserEnv?{write(t,e,n,r,s,o){const a=[t+"="+encodeURIComponent(e)];w.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),w.isString(r)&&a.push("path="+r),w.isString(s)&&a.push("domain="+s),o===!0&&a.push("secure"),document.cookie=a.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function qc(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Uc(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function ns(t,e,n){let r=!qc(e);return t&&(r||n==!1)?Uc(t,e):e}const is=t=>t instanceof be?{...t}:t;function at(t,e){e=e||{};const n={};function r(u,h,f,m){return w.isPlainObject(u)&&w.isPlainObject(h)?w.merge.call({caseless:m},u,h):w.isPlainObject(h)?w.merge({},h):w.isArray(h)?h.slice():h}function s(u,h,f,m){if(w.isUndefined(h)){if(!w.isUndefined(u))return r(void 0,u,f,m)}else return r(u,h,f,m)}function o(u,h){if(!w.isUndefined(h))return r(void 0,h)}function a(u,h){if(w.isUndefined(h)){if(!w.isUndefined(u))return r(void 0,u)}else return r(void 0,h)}function c(u,h,f){if(f in e)return r(u,h);if(f in t)return r(void 0,u)}const d={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:c,headers:(u,h,f)=>s(is(u),is(h),f,!0)};return w.forEach(Object.keys({...t,...e}),function(h){const f=d[h]||s,m=f(t[h],e[h],h);w.isUndefined(m)&&f!==c||(n[h]=m)}),n}const rs=t=>{const e=at({},t);let{data:n,withXSRFToken:r,xsrfHeaderName:s,xsrfCookieName:o,headers:a,auth:c}=e;e.headers=a=be.from(a),e.url=Gr(ns(e.baseURL,e.url,e.allowAbsoluteUrls),t.params,t.paramsSerializer),c&&a.set("Authorization","Basic "+btoa((c.username||"")+":"+(c.password?unescape(encodeURIComponent(c.password)):"")));let d;if(w.isFormData(n)){if(pe.hasStandardBrowserEnv||pe.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((d=a.getContentType())!==!1){const[u,...h]=d?d.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([u||"multipart/form-data",...h].join("; "))}}if(pe.hasStandardBrowserEnv&&(r&&w.isFunction(r)&&(r=r(e)),r||r!==!1&&Lc(e.url))){const u=s&&o&&Hc.read(o);u&&a.set(s,u)}return e},jc=typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,r){const s=rs(t);let o=s.data;const a=be.from(s.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:u}=s,h,f,m,g,C;function b(){g&&g(),C&&C(),s.cancelToken&&s.cancelToken.unsubscribe(h),s.signal&&s.signal.removeEventListener("abort",h)}let S=new XMLHttpRequest;S.open(s.method.toUpperCase(),s.url,!0),S.timeout=s.timeout;function I(){if(!S)return;const z=be.from("getAllResponseHeaders"in S&&S.getAllResponseHeaders()),H={data:!c||c==="text"||c==="json"?S.responseText:S.response,status:S.status,statusText:S.statusText,headers:z,config:t,request:S};Kr(function($e){n($e),b()},function($e){r($e),b()},H),S=null}"onloadend"in S?S.onloadend=I:S.onreadystatechange=function(){!S||S.readyState!==4||S.status===0&&!(S.responseURL&&S.responseURL.indexOf("file:")===0)||setTimeout(I)},S.onabort=function(){S&&(r(new F("Request aborted",F.ECONNABORTED,t,S)),S=null)},S.onerror=function(){r(new F("Network Error",F.ERR_NETWORK,t,S)),S=null},S.ontimeout=function(){let N=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const H=s.transitional||Jr;s.timeoutErrorMessage&&(N=s.timeoutErrorMessage),r(new F(N,H.clarifyTimeoutError?F.ETIMEDOUT:F.ECONNABORTED,t,S)),S=null},o===void 0&&a.setContentType(null),"setRequestHeader"in S&&w.forEach(a.toJSON(),function(N,H){S.setRequestHeader(H,N)}),w.isUndefined(s.withCredentials)||(S.withCredentials=!!s.withCredentials),c&&c!=="json"&&(S.responseType=s.responseType),u&&([m,C]=Cn(u,!0),S.addEventListener("progress",m)),d&&S.upload&&([f,g]=Cn(d),S.upload.addEventListener("progress",f),S.upload.addEventListener("loadend",g)),(s.cancelToken||s.signal)&&(h=z=>{S&&(r(!z||z.type?new wt(null,t,S):z),S.abort(),S=null)},s.cancelToken&&s.cancelToken.subscribe(h),s.signal&&(s.signal.aborted?h():s.signal.addEventListener("abort",h)));const L=Fc(s.url);if(L&&pe.protocols.indexOf(L)===-1){r(new F("Unsupported protocol "+L+":",F.ERR_BAD_REQUEST,t));return}S.send(o||null)})},Wc=(t,e)=>{const{length:n}=t=t?t.filter(Boolean):[];if(e||n){let r=new AbortController,s;const o=function(u){if(!s){s=!0,c();const h=u instanceof Error?u:this.reason;r.abort(h instanceof F?h:new wt(h instanceof Error?h.message:h))}};let a=e&&setTimeout(()=>{a=null,o(new F(`timeout ${e} of ms exceeded`,F.ETIMEDOUT))},e);const c=()=>{t&&(a&&clearTimeout(a),a=null,t.forEach(u=>{u.unsubscribe?u.unsubscribe(o):u.removeEventListener("abort",o)}),t=null)};t.forEach(u=>u.addEventListener("abort",o));const{signal:d}=r;return d.unsubscribe=()=>w.asap(c),d}},_c=function*(t,e){let n=t.byteLength;if(n<e){yield t;return}let r=0,s;for(;r<n;)s=r+e,yield t.slice(r,s),r=s},Gc=async function*(t,e){for await(const n of Zc(t))yield*_c(n,e)},Zc=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const e=t.getReader();try{for(;;){const{done:n,value:r}=await e.read();if(n)break;yield r}}finally{await e.cancel()}},ss=(t,e,n,r)=>{const s=Gc(t,e);let o=0,a,c=d=>{a||(a=!0,r&&r(d))};return new ReadableStream({async pull(d){try{const{done:u,value:h}=await s.next();if(u){c(),d.close();return}let f=h.byteLength;if(n){let m=o+=f;n(m)}d.enqueue(new Uint8Array(h))}catch(u){throw c(u),u}},cancel(d){return c(d),s.return()}},{highWaterMark:2})},Sn=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",os=Sn&&typeof ReadableStream=="function",Jc=Sn&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),as=(t,...e)=>{try{return!!t(...e)}catch{return!1}},Xc=os&&as(()=>{let t=!1;const e=new Request(pe.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e}),ls=64*1024,wi=os&&as(()=>w.isReadableStream(new Response("").body)),kn={stream:wi&&(t=>t.body)};Sn&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!kn[e]&&(kn[e]=w.isFunction(t[e])?n=>n[e]():(n,r)=>{throw new F(`Response type '${e}' is not supported`,F.ERR_NOT_SUPPORT,r)})})})(new Response);const Yc=async t=>{if(t==null)return 0;if(w.isBlob(t))return t.size;if(w.isSpecCompliantForm(t))return(await new Request(pe.origin,{method:"POST",body:t}).arrayBuffer()).byteLength;if(w.isArrayBufferView(t)||w.isArrayBuffer(t))return t.byteLength;if(w.isURLSearchParams(t)&&(t=t+""),w.isString(t))return(await Jc(t)).byteLength},Qc=async(t,e)=>{const n=w.toFiniteNumber(t.getContentLength());return n??Yc(e)},bi={http:bc,xhr:jc,fetch:Sn&&(async t=>{let{url:e,method:n,data:r,signal:s,cancelToken:o,timeout:a,onDownloadProgress:c,onUploadProgress:d,responseType:u,headers:h,withCredentials:f="same-origin",fetchOptions:m}=rs(t);u=u?(u+"").toLowerCase():"text";let g=Wc([s,o&&o.toAbortSignal()],a),C;const b=g&&g.unsubscribe&&(()=>{g.unsubscribe()});let S;try{if(d&&Xc&&n!=="get"&&n!=="head"&&(S=await Qc(h,r))!==0){let H=new Request(e,{method:"POST",body:r,duplex:"half"}),Be;if(w.isFormData(r)&&(Be=H.headers.get("content-type"))&&h.setContentType(Be),H.body){const[$e,nt]=es(S,Cn(ts(d)));r=ss(H.body,ls,$e,nt)}}w.isString(f)||(f=f?"include":"omit");const I="credentials"in Request.prototype;C=new Request(e,{...m,signal:g,method:n.toUpperCase(),headers:h.normalize().toJSON(),body:r,duplex:"half",credentials:I?f:void 0});let L=await fetch(C,m);const z=wi&&(u==="stream"||u==="response");if(wi&&(c||z&&b)){const H={};["status","statusText","headers"].forEach(At=>{H[At]=L[At]});const Be=w.toFiniteNumber(L.headers.get("content-length")),[$e,nt]=c&&es(Be,Cn(ts(c),!0))||[];L=new Response(ss(L.body,ls,$e,()=>{nt&&nt(),b&&b()}),H)}u=u||"text";let N=await kn[w.findKey(kn,u)||"text"](L,t);return!z&&b&&b(),await new Promise((H,Be)=>{Kr(H,Be,{data:N,headers:be.from(L.headers),status:L.status,statusText:L.statusText,config:t,request:C})})}catch(I){throw b&&b(),I&&I.name==="TypeError"&&/Load failed|fetch/i.test(I.message)?Object.assign(new F("Network Error",F.ERR_NETWORK,t,C),{cause:I.cause||I}):F.from(I,I&&I.code,t,C)}})};w.forEach(bi,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const cs=t=>`- ${t}`,Kc=t=>w.isFunction(t)||t===null||t===!1,ds={getAdapter:t=>{t=w.isArray(t)?t:[t];const{length:e}=t;let n,r;const s={};for(let o=0;o<e;o++){n=t[o];let a;if(r=n,!Kc(n)&&(r=bi[(a=String(n)).toLowerCase()],r===void 0))throw new F(`Unknown adapter '${a}'`);if(r)break;s[a||"#"+o]=r}if(!r){const o=Object.entries(s).map(([c,d])=>`adapter ${c} `+(d===!1?"is not supported by the environment":"is not available in the build"));let a=e?o.length>1?`since :
17
17
  `+o.map(cs).join(`
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "sprof",
3
3
  "description": "components for the designer and uikit.",
4
4
  "author": "Stanislav Lushnikov, Daniil Gaivoronskiy",
5
- "version": "0.1.29",
5
+ "version": "0.1.31",
6
6
  "private": false,
7
7
  "type": "module",
8
8
  "main": "./dist/sprof.umd.cjs",