sprof 0.1.5 → 0.1.6

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.
@@ -2,6 +2,7 @@ import { default as Cursor } from './Cursor';
2
2
  export default class Pagination {
3
3
  page: number;
4
4
  rowsPerPage: number;
5
+ rowsNumber: number;
5
6
  cursor: Cursor;
6
7
  cursorMode: boolean;
7
8
  append: boolean;
@@ -91,6 +91,7 @@ declare class S {
91
91
  pagination: {
92
92
  page: number;
93
93
  rowsPerPage: number;
94
+ rowsNumber: number;
94
95
  cursor: {
95
96
  operation: import('../types/Operators').default;
96
97
  column: string;
@@ -394,6 +394,7 @@ export default abstract class S {
394
394
  pagination: {
395
395
  page: number;
396
396
  rowsPerPage: number;
397
+ rowsNumber: number;
397
398
  cursor: {
398
399
  operation: import('../types/Operators').default;
399
400
  column: string;
package/dist/sprof.js CHANGED
@@ -2059,6 +2059,7 @@ class qi {
2059
2059
  constructor(e) {
2060
2060
  a(this, "page", 0);
2061
2061
  a(this, "rowsPerPage", 25);
2062
+ a(this, "rowsNumber", 0);
2062
2063
  a(this, "cursor", new Lu());
2063
2064
  a(this, "cursorMode", !1);
2064
2065
  a(this, "append", !1);
@@ -2084,13 +2085,13 @@ class qi {
2084
2085
  this.page = Number(n.get("offset")), this.rowsPerPage = Number(n.get("col"));
2085
2086
  }
2086
2087
  setAllLoaded(e) {
2087
- this.allLoaded = !(e >= this.limit);
2088
+ this.allLoaded = !(e >= this.rowsPerPage);
2088
2089
  }
2089
2090
  resetAllLoaded() {
2090
2091
  this.allLoaded = !1;
2091
2092
  }
2092
2093
  getPageNum() {
2093
- return this.offset / this.limit + 1;
2094
+ return this.page / this.rowsPerPage + 1;
2094
2095
  }
2095
2096
  drop() {
2096
2097
  this.page = 0, this.rowsPerPage = 25, O.BuildClass(this);
@@ -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 Er;(function(t){(function(e){var n=typeof globalThis=="object"?globalThis:typeof kr=="object"?kr:typeof self=="object"?self:typeof this=="object"?this:c(),r=o(t);typeof n.Reflect<"u"&&(r=o(n.Reflect,r)),e(r,n),typeof n.Reflect>"u"&&(n.Reflect=t);function o(d,u){return function(h,f){Object.defineProperty(d,h,{configurable:!0,writable:!0,value:f}),u&&u(h,f)}}function s(){try{return Function("return this;")()}catch{}}function a(){try{return(0,eval)("(function() { return this; })()")}catch{}}function c(){return s()||a()}})(function(e,n){var r=Object.prototype.hasOwnProperty,o=typeof Symbol=="function",s=o&&typeof Symbol.toPrimitive<"u"?Symbol.toPrimitive:"@@toPrimitive",a=o&&typeof Symbol.iterator<"u"?Symbol.iterator:"@@iterator",c=typeof Object.create=="function",d={__proto__:[]}instanceof Array,u=!c&&!d,h={create:c?function(){return ur(Object.create(null))}:d?function(){return ur({__proto__:null})}:function(){return ur({})},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:tg(),g=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:ng(),C=typeof WeakMap=="function"?WeakMap:ig(),b=o?Symbol.for("@reflect-metadata:registry"):void 0,S=Qp(),$=Kp(S);function L(p,y,k,x){if(T(k)){if(!_a(p))throw new TypeError;if(!Ga(y))throw new TypeError;return jp(p,y)}else{if(!_a(p))throw new TypeError;if(!re(y))throw new TypeError;if(!re(x)&&!T(x)&&!Nt(x))throw new TypeError;return Nt(x)&&(x=void 0),k=He(k),Wp(p,y,k,x)}}e("decorate",L);function P(p,y){function k(x,V){if(!re(x))throw new TypeError;if(!T(V)&&!Xp(V))throw new TypeError;Ha(p,y,x,V)}return k}e("metadata",P);function R(p,y,k,x){if(!re(k))throw new TypeError;return T(x)||(x=He(x)),Ha(p,y,k,x)}e("defineMetadata",R);function H(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),Oa(p,y,k)}e("hasMetadata",H);function Me(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),lr(p,y,k)}e("hasOwnMetadata",Me);function Be(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),Da(p,y,k)}e("getMetadata",Be);function nt(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),La(p,y,k)}e("getOwnMetadata",nt);function Rt(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),qa(p,y)}e("getMetadataKeys",Rt);function Xn(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),Ua(p,y)}e("getOwnMetadataKeys",Xn);function Up(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=Xt(y,k,!1);return T(x)?!1:x.OrdinaryDeleteMetadata(p,y,k)}e("deleteMetadata",Up);function jp(p,y){for(var k=p.length-1;k>=0;--k){var x=p[k],V=x(y);if(!T(V)&&!Nt(V)){if(!Ga(V))throw new TypeError;y=V}}return y}function Wp(p,y,k,x){for(var V=p.length-1;V>=0;--V){var ee=p[V],oe=ee(y,k,x);if(!T(oe)&&!Nt(oe)){if(!re(oe))throw new TypeError;x=oe}}return x}function Oa(p,y,k){var x=lr(p,y,k);if(x)return!0;var V=dr(y);return Nt(V)?!1:Oa(p,V,k)}function lr(p,y,k){var x=Xt(y,k,!1);return T(x)?!1:Wa(x.OrdinaryHasOwnMetadata(p,y,k))}function Da(p,y,k){var x=lr(p,y,k);if(x)return La(p,y,k);var V=dr(y);if(!Nt(V))return Da(p,V,k)}function La(p,y,k){var x=Xt(y,k,!1);if(!T(x))return x.OrdinaryGetOwnMetadata(p,y,k)}function Ha(p,y,k,x){var V=Xt(k,x,!0);V.OrdinaryDefineOwnMetadata(p,y,k,x)}function qa(p,y){var k=Ua(p,y),x=dr(p);if(x===null)return k;var V=qa(x,y);if(V.length<=0)return k;if(k.length<=0)return V;for(var ee=new g,oe=[],q=0,v=k;q<v.length;q++){var B=v[q],I=ee.has(B);I||(ee.add(B),oe.push(B))}for(var A=0,U=V;A<U.length;A++){var B=U[A],I=ee.has(B);I||(ee.add(B),oe.push(B))}return oe}function Ua(p,y){var k=Xt(p,y,!1);return k?k.OrdinaryOwnMetadataKeys(p,y):[]}function ja(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 Nt(p){return p===null}function _p(p){return typeof p=="symbol"}function re(p){return typeof p=="object"?p!==null:typeof p=="function"}function Gp(p,y){switch(ja(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=Za(p,s);if(x!==void 0){var V=x.call(p,k);if(re(V))throw new TypeError;return V}return Zp(p)}function Zp(p,y){var k,x,V;{var ee=p.toString;if(Yn(ee)){var x=ee.call(p);if(!re(x))return x}var k=p.valueOf;if(Yn(k)){var x=k.call(p);if(!re(x))return x}}throw new TypeError}function Wa(p){return!!p}function Jp(p){return""+p}function He(p){var y=Gp(p);return _p(y)?y:Jp(y)}function _a(p){return Array.isArray?Array.isArray(p):p instanceof Object?p instanceof Array:Object.prototype.toString.call(p)==="[object Array]"}function Yn(p){return typeof p=="function"}function Ga(p){return typeof p=="function"}function Xp(p){switch(ja(p)){case 3:return!0;case 4:return!0;default:return!1}}function cr(p,y){return p===y||p!==p&&y!==y}function Za(p,y){var k=p[y];if(k!=null){if(!Yn(k))throw new TypeError;return k}}function Ja(p){var y=Za(p,a);if(!Yn(y))throw new TypeError;var k=y.call(p);if(!re(k))throw new TypeError;return k}function Xa(p){return p.value}function Ya(p){var y=p.next();return y.done?!1:y}function Qa(p){var y=p.return;y&&y.call(p)}function dr(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 Yp(){var p;!T(b)&&typeof n.Reflect<"u"&&!(b in n.Reflect)&&typeof n.Reflect.defineMetadata=="function"&&(p=eg(n.Reflect));var y,k,x,V=new C,ee={registerProvider:oe,getProvider:v,setProvider:I};return ee;function oe(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,U){if(!T(y)){if(y.isProviderFor(A,U))return y;if(!T(k)){if(k.isProviderFor(A,U))return y;if(!T(x))for(var J=Ja(x);;){var te=Ya(J);if(!te)return;var Ae=Xa(te);if(Ae.isProviderFor(A,U))return Qa(J),Ae}}}if(!T(p)&&p.isProviderFor(A,U))return p}function v(A,U){var J=V.get(A),te;return T(J)||(te=J.get(U)),T(te)&&(te=q(A,U),T(te)||(T(J)&&(J=new m,V.set(A,J)),J.set(U,te))),te}function B(A){if(T(A))throw new TypeError;return y===A||k===A||!T(x)&&x.has(A)}function I(A,U,J){if(!B(J))throw new Error("Metadata provider not registered.");var te=v(A,U);if(te!==J){if(!T(te))return!1;var Ae=V.get(A);T(Ae)&&(Ae=new m,V.set(A,Ae)),Ae.set(U,J)}return!0}}function Qp(){var p;return!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&(p=n.Reflect[b]),T(p)&&(p=Yp()),!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&Object.defineProperty(n.Reflect,b,{enumerable:!1,configurable:!1,writable:!1,value:p}),p}function Kp(p){var y=new C,k={isProviderFor:function(B,I){var A=y.get(B);return T(A)?!1:A.has(I)},OrdinaryDefineOwnMetadata:oe,OrdinaryHasOwnMetadata:V,OrdinaryGetOwnMetadata:ee,OrdinaryOwnMetadataKeys:q,OrdinaryDeleteMetadata:v};return S.registerProvider(k),k;function x(B,I,A){var U=y.get(B),J=!1;if(T(U)){if(!A)return;U=new m,y.set(B,U),J=!0}var te=U.get(I);if(T(te)){if(!A)return;if(te=new m,U.set(I,te),!p.setProvider(B,I,k))throw U.delete(I),J&&y.delete(B),new Error("Wrong provider for target.")}return te}function V(B,I,A){var U=x(I,A,!1);return T(U)?!1:Wa(U.has(B))}function ee(B,I,A){var U=x(I,A,!1);if(!T(U))return U.get(B)}function oe(B,I,A,U){var J=x(A,U,!0);J.set(B,I)}function q(B,I){var A=[],U=x(B,I,!1);if(T(U))return A;for(var J=U.keys(),te=Ja(J),Ae=0;;){var Ka=Ya(te);if(!Ka)return A.length=Ae,A;var rg=Xa(Ka);try{A[Ae]=rg}catch(og){try{Qa(te)}finally{throw og}}Ae++}}function v(B,I,A){var U=x(I,A,!1);if(T(U)||!U.delete(B))return!1;if(U.size===0){var J=y.get(I);T(J)||(J.delete(A),J.size===0&&y.delete(J))}return!0}}function eg(p){var y=p.defineMetadata,k=p.hasOwnMetadata,x=p.getOwnMetadata,V=p.getOwnMetadataKeys,ee=p.deleteMetadata,oe=new C,q={isProviderFor:function(v,B){var I=oe.get(v);return!T(I)&&I.has(B)?!0:V(v,B).length?(T(I)&&(I=new g,oe.set(v,I)),I.add(B),!0):!1},OrdinaryDefineOwnMetadata:y,OrdinaryHasOwnMetadata:k,OrdinaryGetOwnMetadata:x,OrdinaryOwnMetadataKeys:V,OrdinaryDeleteMetadata:ee};return q}function Xt(p,y,k){var x=S.getProvider(p,y);if(!T(x))return x;if(k){if(S.setProvider(p,y,$))return $;throw new Error("Illegal state.")}}function tg(){var p={},y=[],k=function(){function q(v,B,I){this._index=0,this._keys=v,this._values=B,this._selector=I}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 B=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:B,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 B=this._find(v,!1);return B>=0?this._values[B]:void 0},q.prototype.set=function(v,B){var I=this._find(v,!0);return this._values[I]=B,this},q.prototype.delete=function(v){var B=this._find(v,!1);if(B>=0){for(var I=this._keys.length,A=B+1;A<I;A++)this._keys[A-1]=this._keys[A],this._values[A-1]=this._values[A];return this._keys.length--,this._values.length--,cr(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,oe)},q.prototype["@@iterator"]=function(){return this.entries()},q.prototype[a]=function(){return this.entries()},q.prototype._find=function(v,B){if(!cr(this._cacheKey,v)){this._cacheIndex=-1;for(var I=0;I<this._keys.length;I++)if(cr(this._keys[I],v)){this._cacheIndex=I;break}}return this._cacheIndex<0&&B&&(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 oe(q,v){return[q,v]}}function ng(){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 ig(){var p=16,y=h.create(),k=x();return function(){function v(){this._key=x()}return v.prototype.has=function(B){var I=V(B,!1);return I!==void 0?h.has(I,this._key):!1},v.prototype.get=function(B){var I=V(B,!1);return I!==void 0?h.get(I,this._key):void 0},v.prototype.set=function(B,I){var A=V(B,!0);return A[this._key]=I,this},v.prototype.delete=function(B){var I=V(B,!1);return I!==void 0?delete I[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,B){if(!r.call(v,k)){if(!B)return;Object.defineProperty(v,k,{value:h.create()})}return v[k]}function ee(v,B){for(var I=0;I<B;++I)v[I]=Math.random()*255|0;return v}function oe(v){if(typeof Uint8Array=="function"){var B=new Uint8Array(v);return typeof crypto<"u"?crypto.getRandomValues(B):typeof msCrypto<"u"?msCrypto.getRandomValues(B):ee(B,v),B}return ee(new Array(v),v)}function q(){var v=oe(p);v[6]=v[6]&79|64,v[8]=v[8]&191|128;for(var B="",I=0;I<p;++I){var A=v[I];(I===4||I===6||I===8)&&(B+="-"),A<16&&(B+="0"),B+=A.toString(16).toLowerCase()}return B}}function ur(p){return p.__=void 0,delete p.__,p}})})(Er||(Er={}));let on;const wl=new Uint8Array(16);function bl(){if(!on&&(on=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!on))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return on(wl)}const ue=[];for(let t=0;t<256;++t)ue.push((t+256).toString(16).slice(1));function Cl(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 xr={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Xe(t,e,n){if(xr.randomUUID&&!t)return xr.randomUUID();t=t||{};const r=t.random||(t.rng||bl)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Cl(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()}}class W{static Capitalize(e){return e?e[0].toUpperCase()+e.slice(1):""}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((o,s)=>s===0?o.toLowerCase():W.Capitalize(o.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,o=>{if(o===o.toLowerCase()){const a=Object.keys(r).find(c=>r[c]===o);return a||""}const s=Object.keys(r).find(a=>r[a]===o.toLowerCase());return s?s.toUpperCase():""}):e.replace(/[A-z/,.;'\][]/g,o=>o===o.toLowerCase()?r[o]:r[o.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,""),o=n.toLowerCase().replaceAll(/\s/g,""),s=W.Translit(r),a=W.Translit(o);return r.includes(o)||s.includes(o)||r.includes(a)}static SearchIn(e,n){return W.StringsEquals(e,n)}static SearchInFields(e,n){let r=!1;for(let o=0;o<n.length;o++)if(W.SearchIn(n[o],e)){r=!0;break}return r}static FormatToPercentage(e){return`${e}%`}static ApplyClassToSubStr(e,n,r){const o=r??"highlight-text",s=new RegExp(W.GetVariants(n).join("|"),"gi");return e.replace(s,`<span class="${o}">$&</span>`)}static GetVariants(e){const n=W.Translit(e);return[e,W.Capitalize(e),e.toLowerCase(),e.toUpperCase(),n,W.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 o=n[r];if(this.isPrimitive(o))e[r]instanceof Date?e[r]=new Date(o):e[r]=o;else if(o!=null&&!Array.isArray(o))if(e[r]&&e[r].constructor)e[r]=new e[r].constructor(o);else{const s=Reflect.getMetadata(r,e);s&&(e[r]=new s[r](o))}if(Array.isArray(o)){if(o.length===0)return;const s=Reflect.getMetadata(r,e);s&&(e[r]=o.map(a=>new s[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 o=n.findIndex(s=>s.id===e);et.RemoveFromClass(o,n,r)}static RemoveFromClass(e,n,r){if(e<0)return;const o=n[e].id;o&&r&&r.push(o),n.splice(e,1)}static GetPropertyName(e){const n=new e;return new Proxy(n,{get(r,o){return o}})}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,o])=>[r,et.DeepMap(e)(o)])):e(n)}static DeepTrim(e){return this.DeepMap(W.TrimText)(e)}};l(et,"GetClassConstructor",e=>(n,r)=>{const o=Reflect.getMetadata(`property:${r}`,n)||{};o[r]=e,Reflect.defineMetadata(r,o,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 ri{static Setup(e){this.staticUrl=e}static get StaticUrl(){return this.staticUrl}}l(ri,"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:`${ri.StaticUrl}/${this.fileSystemPath}`;return new URL(e,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:$e&&$e.tagName.toUpperCase()==="SCRIPT"&&$e.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:$e&&$e.tagName.toUpperCase()==="SCRIPT"&&$e.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 vr{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=W.Capitalize(this.name),this.surname=W.Capitalize(this.surname),this.patronymic=W.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 ot{constructor(e){l(this,"id");l(this,"number");l(this,"description");l(this,"contactId");M.BuildClass(this,e)}static Create(){const e=new ot;return e.id=ne.UUID(),e}}class sn{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class oi{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class an{constructor(e){l(this,"id");l(this,"login","");l(this,"email","");l(this,"password","");M.BuildClass(this,e)}static Create(){const e=new an;return e.id=ne.UUID(),e}}let Sl=(Je=class{},l(Je,"Phone",ot),l(Je,"FileInfo",me),l(Je,"Website",oi),l(Je,"Email",rt),l(Je,"Human",vr),l(Je,"PostAddress",sn),l(Je,"UserAccount",an),Je);var X=(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))(X||{});class ln{constructor(e){l(this,"field","");l(this,"operator",X.Eq);l(this,"value","");M.BuildClass(this,e)}setValue(e){this.value=e}static Create(e,n){return new ln({operator:n,field:e})}eq(e){return this.field===e.field&&this.operator===e.operator}isUnary(){return this.operator===X.Eq||this.operator===X.Gt||this.operator===X.Lt}isBetween(){return this.operator===X.Btw}isSet(){return this.operator===X.In}}class si{constructor(e){l(this,"model","");l(this,"field","");l(this,"value","");l(this,"wheres",[]);M.BuildClass(this,e)}static Create(e){const n=new si;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 o=ln.Create(e,n);return this.wheres.push(o),o}findWhere(e){return this.wheres.find(n=>n.eq(e))}}let Mr=class el{constructor(e){l(this,"id");l(this,"model","");l(this,"wheres",[]);l(this,"joins",[]);M.BuildClass(this,e)}static Create(e){const n=new el;return n.model=e.GetClassName(),n}addWhere(e,n){const r=this.findWhere({field:e,operator:n});if(r)return r;const o=ln.Create(e,n);return this.wheres.push(o),o}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=si.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},(o,s)=>e+s*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,o)=>e[o]==n[o]))}static SwipeById(e,n,r){const o=e.findIndex(a=>n.id===a.id),s=e.findIndex(a=>r.id===a.id);o||s||([e[o],e[s]]=[e[s],e[o]])}static Swap(e,n,r){if(n<0||n>=e.length||r<0||r>=e.length)return;const o=e[n];e[n]=e[r],e[r]=o}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||{}),kl=Object.defineProperty,El=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&kl(e,n,o),o};const Br=class Yt{constructor(e){l(this,"id");l(this,"model","");l(this,"label","");l(this,"col","");l(this,"operator",X.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===X.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}"`:"",o=this.operator?`"operator":"${this.operator}"`:"",s=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===X.In?`"set":${JSON.stringify(this.set)}`:"",f=this.type===ae.Join?`"joinTableModel":"${this.joinTableModel}"`:"";return[e,n,r,o,s,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===X.Eq||this.operator===X.Gt||this.operator===X.Lt}isBetweenFilter(){return this.operator===X.Btw}isSetFilter(){return this.operator===X.In}static Create(e,n,r){const o=new Yt;return o.model=e.GetClassName(),o.col=n??"",o.type=r,o.type===ae.Number&&(o.value1="0"),o.type===ae.String&&(o.value1=""),o.type===ae.Boolean&&(o.value1="false",o.operator=X.Eq),o}static CreateFilterModelWithJoin(e,n,r,o,s,a,c,d){const u=new Yt;return u.id=Xe(),u.joinTable=r,u.joinTablePk=o,u.joinTableFk=s,u.col=n,u.type=a,c&&(u.joinTableId=c),d&&(u.joinTableIdCol=d),u}static CreateFilterModelWithJoinV2(e,n,r,o,s,a,c){const d=new Yt;return d.model=e,d.joinTableModel=r,d.joinTablePk=o,d.joinTableFk=s,d.col=n,d.type=ae.Join,a&&(d.joinTableId=a),c&&(d.joinTableIdCol=c),d}static OnlyIfSecondModelExists(e,n){const r=new Yt;return r.id=Xe(),r.model=W.ToCamelCase(e.GetClassName()),r.joinTableModel=W.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=X.Eq;return}this.setDate2(n),this.operator=X.Btw}};El([M.GetClassConstructor(String)],Br.prototype,"set");let ai=Br;class xl{constructor(){l(this,"operation",X.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,o=r?`"value":"${r}"`:"",s=this.model?`"model":"${this.model}"`:"",a=`"initial":${this.initial}`;return[e,n,o,s,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 cn{constructor(e){l(this,"page",0);l(this,"rowsPerPage",25);l(this,"cursor",new xl);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=X.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=X.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}`,o=`"append":${this.append}`,s=`"allLoaded":${this.allLoaded}`,a=`"cursor":{${this.cursor.toUrlQuery()}}`;return[e,n,r,o,s,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.limit)}resetAllLoaded(){this.allLoaded=!1}getPageNum(){return this.offset/this.limit+1}drop(){this.page=0,this.rowsPerPage=25,M.BuildClass(this)}}var Ee=(t=>(t.Asc="asc",t.Desc="desc",t))(Ee||{});class dn{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,o,s){const a=new dn;return a.model=e.GetClassName(),a.col=n??"",a.order=r??Ee.Asc,a.label=o??"",a.default=s??!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 un{constructor(){l(this,"model","");l(this,"cols",[]);l(this,"models",[])}static Create(e,n){const r=new un;return r.model=e.GetClassName(),r.cols=n,r}}var vl=Object.defineProperty,Pt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&vl(e,n,o),o};const pt=(Se=class{constructor(e){l(this,"id");l(this,"f",[]);l(this,"f2",[]);l(this,"s",[]);l(this,"p",new cn);l(this,"t",new un);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(([o,s])=>o!=="label"&&s!==""&&s!==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 cn}resetF(){this.f=[]}},l(Se,"instance"),Se);Pt([M.GetClassConstructor(ai)],pt.prototype,"f"),Pt([M.GetClassConstructor(Mr)],pt.prototype,"f2"),Pt([M.GetClassConstructor(dn)],pt.prototype,"s"),Pt([M.GetClassConstructor(cn)],pt.prototype,"p"),Pt([M.GetClassConstructor(un)],pt.prototype,"t");let je=pt,Ml=(It=class{},l(It,"SortModel",dn),l(It,"FilterModel",ai),l(It,"FilterModelV2",Mr),l(It,"FTSP",i.reactive(je)),It);function $r(t,e){return function(){return t.apply(e,arguments)}}const{toString:Bl}=Object.prototype,{getPrototypeOf:li}=Object,{iterator:hn,toStringTag:Ir}=Symbol,fn=(t=>e=>{const n=Bl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Re=t=>(t=t.toLowerCase(),e=>fn(e)===t),mn=t=>e=>typeof e===t,{isArray:gt}=Array,Vt=mn("undefined");function Tt(t){return t!==null&&!Vt(t)&&t.constructor!==null&&!Vt(t.constructor)&&we(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Rr=Re("ArrayBuffer");function $l(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Rr(t.buffer),e}const Il=mn("string"),we=mn("function"),Nr=mn("number"),Ft=t=>t!==null&&typeof t=="object",Rl=t=>t===!0||t===!1,pn=t=>{if(fn(t)!=="object")return!1;const e=li(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Ir in t)&&!(hn in t)},Nl=t=>{if(!Ft(t)||Tt(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},Al=Re("Date"),zl=Re("File"),Pl=Re("Blob"),Vl=Re("FileList"),Tl=t=>Ft(t)&&we(t.pipe),Fl=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||we(t.append)&&((e=fn(t))==="formdata"||e==="object"&&we(t.toString)&&t.toString()==="[object FormData]"))},Ol=Re("URLSearchParams"),[Dl,Ll,Hl,ql]=["ReadableStream","Request","Response","Headers"].map(Re),Ul=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ot(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,o;if(typeof t!="object"&&(t=[t]),gt(t))for(r=0,o=t.length;r<o;r++)e.call(null,t[r],r,t);else{if(Tt(t))return;const s=n?Object.getOwnPropertyNames(t):Object.keys(t),a=s.length;let c;for(r=0;r<a;r++)c=s[r],e.call(null,t[c],c,t)}}function Ar(t,e){if(Tt(t))return null;e=e.toLowerCase();const n=Object.keys(t);let r=n.length,o;for(;r-- >0;)if(o=n[r],e===o.toLowerCase())return o;return null}const st=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,zr=t=>!Vt(t)&&t!==st;function ci(){const{caseless:t}=zr(this)&&this||{},e={},n=(r,o)=>{const s=t&&Ar(e,o)||o;pn(e[s])&&pn(r)?e[s]=ci(e[s],r):pn(r)?e[s]=ci({},r):gt(r)?e[s]=r.slice():e[s]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Ot(arguments[r],n);return e}const jl=(t,e,n,{allOwnKeys:r}={})=>(Ot(e,(o,s)=>{n&&we(o)?t[s]=$r(o,n):t[s]=o},{allOwnKeys:r}),t),Wl=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),_l=(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)},Gl=(t,e,n,r)=>{let o,s,a;const c={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),s=o.length;s-- >0;)a=o[s],(!r||r(a,t,e))&&!c[a]&&(e[a]=t[a],c[a]=!0);t=n!==!1&&li(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},Zl=(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},Jl=t=>{if(!t)return null;if(gt(t))return t;let e=t.length;if(!Nr(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},Xl=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&li(Uint8Array)),Yl=(t,e)=>{const r=(t&&t[hn]).call(t);let o;for(;(o=r.next())&&!o.done;){const s=o.value;e.call(t,s[0],s[1])}},Ql=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},Kl=Re("HTMLFormElement"),ec=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Pr=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),tc=Re("RegExp"),Vr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Ot(n,(o,s)=>{let a;(a=e(o,s,t))!==!1&&(r[s]=a||o)}),Object.defineProperties(t,r)},nc=t=>{Vr(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+"'")})}})},ic=(t,e)=>{const n={},r=o=>{o.forEach(s=>{n[s]=!0})};return gt(t)?r(t):r(String(t).split(e)),n},rc=()=>{},oc=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function sc(t){return!!(t&&we(t.append)&&t[Ir]==="FormData"&&t[hn])}const ac=t=>{const e=new Array(10),n=(r,o)=>{if(Ft(r)){if(e.indexOf(r)>=0)return;if(Tt(r))return r;if(!("toJSON"in r)){e[o]=r;const s=gt(r)?[]:{};return Ot(r,(a,c)=>{const d=n(a,o+1);!Vt(d)&&(s[c]=d)}),e[o]=void 0,s}}return r};return n(t,0)},lc=Re("AsyncFunction"),cc=t=>t&&(Ft(t)||we(t))&&we(t.then)&&we(t.catch),Tr=((t,e)=>t?setImmediate:e?((n,r)=>(st.addEventListener("message",({source:o,data:s})=>{o===st&&s===n&&r.length&&r.shift()()},!1),o=>{r.push(o),st.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",we(st.postMessage)),dc=typeof queueMicrotask<"u"?queueMicrotask.bind(st):typeof process<"u"&&process.nextTick||Tr,w={isArray:gt,isArrayBuffer:Rr,isBuffer:Tt,isFormData:Fl,isArrayBufferView:$l,isString:Il,isNumber:Nr,isBoolean:Rl,isObject:Ft,isPlainObject:pn,isEmptyObject:Nl,isReadableStream:Dl,isRequest:Ll,isResponse:Hl,isHeaders:ql,isUndefined:Vt,isDate:Al,isFile:zl,isBlob:Pl,isRegExp:tc,isFunction:we,isStream:Tl,isURLSearchParams:Ol,isTypedArray:Xl,isFileList:Vl,forEach:Ot,merge:ci,extend:jl,trim:Ul,stripBOM:Wl,inherits:_l,toFlatObject:Gl,kindOf:fn,kindOfTest:Re,endsWith:Zl,toArray:Jl,forEachEntry:Yl,matchAll:Ql,isHTMLForm:Kl,hasOwnProperty:Pr,hasOwnProp:Pr,reduceDescriptors:Vr,freezeMethods:nc,toObjectSet:ic,toCamelCase:ec,noop:rc,toFiniteNumber:oc,findKey:Ar,global:st,isContextDefined:zr,isSpecCompliantForm:sc,toJSONObject:ac,isAsyncFn:lc,isThenable:cc,setImmediate:Tr,asap:dc,isIterable:t=>t!=null&&we(t[hn])};function F(t,e,n,r,o){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),o&&(this.response=o,this.status=o.status?o.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 Fr=F.prototype,Or={};["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=>{Or[t]={value:t}}),Object.defineProperties(F,Or),Object.defineProperty(Fr,"isAxiosError",{value:!0}),F.from=(t,e,n,r,o,s)=>{const a=Object.create(Fr);return w.toFlatObject(t,a,function(d){return d!==Error.prototype},c=>c!=="isAxiosError"),F.call(a,t.message,e,n,r,o),a.cause=t,a.name=t.name,s&&Object.assign(a,s),a};const uc=null;function di(t){return w.isPlainObject(t)||w.isArray(t)}function Dr(t){return w.endsWith(t,"[]")?t.slice(0,-2):t}function Lr(t,e,n){return t?t.concat(e).map(function(o,s){return o=Dr(o),!n&&s?"["+o+"]":o}).join(n?".":""):e}function hc(t){return w.isArray(t)&&!t.some(di)}const fc=w.toFlatObject(w,{},null,function(e){return/^is[A-Z]/.test(e)});function gn(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,o=n.visitor||h,s=n.dots,a=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&w.isSpecCompliantForm(e);if(!w.isFunction(o))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 $=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)&&hc(C)||(w.isFileList(C)||w.endsWith(b,"[]"))&&($=w.toArray(C)))return b=Dr(b),$.forEach(function(P,R){!(w.isUndefined(P)||P===null)&&e.append(a===!0?Lr([b],R,s):a===null?b:b+"[]",u(P))}),!1}return di(C)?!0:(e.append(Lr(S,b,s),u(C)),!1)}const f=[],m=Object.assign(fc,{defaultVisitor:h,convertValue:u,isVisitable:di});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($,L){(!(w.isUndefined($)||$===null)&&o.call(e,$,w.isString(L)?L.trim():L,b,m))===!0&&g($,b?b.concat(L):[L])}),f.pop()}}if(!w.isObject(t))throw new TypeError("data must be an object");return g(t),e}function Hr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function ui(t,e){this._pairs=[],t&&gn(t,this,e)}const qr=ui.prototype;qr.append=function(e,n){this._pairs.push([e,n])},qr.toString=function(e){const n=e?function(r){return e.call(this,r,Hr)}:Hr;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function mc(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Ur(t,e,n){if(!e)return t;const r=n&&n.encode||mc;w.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let s;if(o?s=o(e,n):s=w.isURLSearchParams(e)?e.toString():new ui(e,n).toString(r),s){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+s}return t}class jr{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 Wr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},pc={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:ui,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},hi=typeof window<"u"&&typeof document<"u",fi=typeof navigator=="object"&&navigator||void 0,gc=hi&&(!fi||["ReactNative","NativeScript","NS"].indexOf(fi.product)<0),yc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",wc=hi&&window.location.href||"http://localhost",pe={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:hi,hasStandardBrowserEnv:gc,hasStandardBrowserWebWorkerEnv:yc,navigator:fi,origin:wc},Symbol.toStringTag,{value:"Module"})),...pc};function bc(t,e){return gn(t,new pe.classes.URLSearchParams,{visitor:function(n,r,o,s){return pe.isNode&&w.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)},...e})}function Cc(t){return w.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function Sc(t){const e={},n=Object.keys(t);let r;const o=n.length;let s;for(r=0;r<o;r++)s=n[r],e[s]=t[s];return e}function _r(t){function e(n,r,o,s){let a=n[s++];if(a==="__proto__")return!0;const c=Number.isFinite(+a),d=s>=n.length;return a=!a&&w.isArray(o)?o.length:a,d?(w.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!c):((!o[a]||!w.isObject(o[a]))&&(o[a]=[]),e(n,r,o[a],s)&&w.isArray(o[a])&&(o[a]=Sc(o[a])),!c)}if(w.isFormData(t)&&w.isFunction(t.entries)){const n={};return w.forEachEntry(t,(r,o)=>{e(Cc(r),o,n,0)}),n}return null}function kc(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 Dt={transitional:Wr,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,s=w.isObject(e);if(s&&w.isHTMLForm(e)&&(e=new FormData(e)),w.isFormData(e))return o?JSON.stringify(_r(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(s){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 gn(c?{"files[]":e}:e,d&&new d,this.formSerializer)}}return s||o?(n.setContentType("application/json",!1),kc(e)):e}],transformResponse:[function(e){const n=this.transitional||Dt.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(w.isResponse(e)||w.isReadableStream(e))return e;if(e&&w.isString(e)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;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=>{Dt.headers[t]={}});const Ec=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"]),xc=t=>{const e={};let n,r,o;return t&&t.split(`
14
+ ***************************************************************************** */var Er;(function(t){(function(e){var n=typeof globalThis=="object"?globalThis:typeof kr=="object"?kr:typeof self=="object"?self:typeof this=="object"?this:c(),r=o(t);typeof n.Reflect<"u"&&(r=o(n.Reflect,r)),e(r,n),typeof n.Reflect>"u"&&(n.Reflect=t);function o(d,u){return function(h,f){Object.defineProperty(d,h,{configurable:!0,writable:!0,value:f}),u&&u(h,f)}}function s(){try{return Function("return this;")()}catch{}}function a(){try{return(0,eval)("(function() { return this; })()")}catch{}}function c(){return s()||a()}})(function(e,n){var r=Object.prototype.hasOwnProperty,o=typeof Symbol=="function",s=o&&typeof Symbol.toPrimitive<"u"?Symbol.toPrimitive:"@@toPrimitive",a=o&&typeof Symbol.iterator<"u"?Symbol.iterator:"@@iterator",c=typeof Object.create=="function",d={__proto__:[]}instanceof Array,u=!c&&!d,h={create:c?function(){return ur(Object.create(null))}:d?function(){return ur({__proto__:null})}:function(){return ur({})},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:tg(),g=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:ng(),C=typeof WeakMap=="function"?WeakMap:ig(),b=o?Symbol.for("@reflect-metadata:registry"):void 0,S=Qp(),$=Kp(S);function L(p,y,k,x){if(T(k)){if(!_a(p))throw new TypeError;if(!Ga(y))throw new TypeError;return jp(p,y)}else{if(!_a(p))throw new TypeError;if(!re(y))throw new TypeError;if(!re(x)&&!T(x)&&!Nt(x))throw new TypeError;return Nt(x)&&(x=void 0),k=He(k),Wp(p,y,k,x)}}e("decorate",L);function P(p,y){function k(x,V){if(!re(x))throw new TypeError;if(!T(V)&&!Xp(V))throw new TypeError;Ha(p,y,x,V)}return k}e("metadata",P);function R(p,y,k,x){if(!re(k))throw new TypeError;return T(x)||(x=He(x)),Ha(p,y,k,x)}e("defineMetadata",R);function H(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),Oa(p,y,k)}e("hasMetadata",H);function Me(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),lr(p,y,k)}e("hasOwnMetadata",Me);function Be(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),Da(p,y,k)}e("getMetadata",Be);function nt(p,y,k){if(!re(y))throw new TypeError;return T(k)||(k=He(k)),La(p,y,k)}e("getOwnMetadata",nt);function Rt(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),qa(p,y)}e("getMetadataKeys",Rt);function Xn(p,y){if(!re(p))throw new TypeError;return T(y)||(y=He(y)),Ua(p,y)}e("getOwnMetadataKeys",Xn);function Up(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=Xt(y,k,!1);return T(x)?!1:x.OrdinaryDeleteMetadata(p,y,k)}e("deleteMetadata",Up);function jp(p,y){for(var k=p.length-1;k>=0;--k){var x=p[k],V=x(y);if(!T(V)&&!Nt(V)){if(!Ga(V))throw new TypeError;y=V}}return y}function Wp(p,y,k,x){for(var V=p.length-1;V>=0;--V){var ee=p[V],oe=ee(y,k,x);if(!T(oe)&&!Nt(oe)){if(!re(oe))throw new TypeError;x=oe}}return x}function Oa(p,y,k){var x=lr(p,y,k);if(x)return!0;var V=dr(y);return Nt(V)?!1:Oa(p,V,k)}function lr(p,y,k){var x=Xt(y,k,!1);return T(x)?!1:Wa(x.OrdinaryHasOwnMetadata(p,y,k))}function Da(p,y,k){var x=lr(p,y,k);if(x)return La(p,y,k);var V=dr(y);if(!Nt(V))return Da(p,V,k)}function La(p,y,k){var x=Xt(y,k,!1);if(!T(x))return x.OrdinaryGetOwnMetadata(p,y,k)}function Ha(p,y,k,x){var V=Xt(k,x,!0);V.OrdinaryDefineOwnMetadata(p,y,k,x)}function qa(p,y){var k=Ua(p,y),x=dr(p);if(x===null)return k;var V=qa(x,y);if(V.length<=0)return k;if(k.length<=0)return V;for(var ee=new g,oe=[],q=0,v=k;q<v.length;q++){var B=v[q],I=ee.has(B);I||(ee.add(B),oe.push(B))}for(var A=0,U=V;A<U.length;A++){var B=U[A],I=ee.has(B);I||(ee.add(B),oe.push(B))}return oe}function Ua(p,y){var k=Xt(p,y,!1);return k?k.OrdinaryOwnMetadataKeys(p,y):[]}function ja(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 Nt(p){return p===null}function _p(p){return typeof p=="symbol"}function re(p){return typeof p=="object"?p!==null:typeof p=="function"}function Gp(p,y){switch(ja(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=Za(p,s);if(x!==void 0){var V=x.call(p,k);if(re(V))throw new TypeError;return V}return Zp(p)}function Zp(p,y){var k,x,V;{var ee=p.toString;if(Yn(ee)){var x=ee.call(p);if(!re(x))return x}var k=p.valueOf;if(Yn(k)){var x=k.call(p);if(!re(x))return x}}throw new TypeError}function Wa(p){return!!p}function Jp(p){return""+p}function He(p){var y=Gp(p);return _p(y)?y:Jp(y)}function _a(p){return Array.isArray?Array.isArray(p):p instanceof Object?p instanceof Array:Object.prototype.toString.call(p)==="[object Array]"}function Yn(p){return typeof p=="function"}function Ga(p){return typeof p=="function"}function Xp(p){switch(ja(p)){case 3:return!0;case 4:return!0;default:return!1}}function cr(p,y){return p===y||p!==p&&y!==y}function Za(p,y){var k=p[y];if(k!=null){if(!Yn(k))throw new TypeError;return k}}function Ja(p){var y=Za(p,a);if(!Yn(y))throw new TypeError;var k=y.call(p);if(!re(k))throw new TypeError;return k}function Xa(p){return p.value}function Ya(p){var y=p.next();return y.done?!1:y}function Qa(p){var y=p.return;y&&y.call(p)}function dr(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 Yp(){var p;!T(b)&&typeof n.Reflect<"u"&&!(b in n.Reflect)&&typeof n.Reflect.defineMetadata=="function"&&(p=eg(n.Reflect));var y,k,x,V=new C,ee={registerProvider:oe,getProvider:v,setProvider:I};return ee;function oe(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,U){if(!T(y)){if(y.isProviderFor(A,U))return y;if(!T(k)){if(k.isProviderFor(A,U))return y;if(!T(x))for(var J=Ja(x);;){var te=Ya(J);if(!te)return;var Ae=Xa(te);if(Ae.isProviderFor(A,U))return Qa(J),Ae}}}if(!T(p)&&p.isProviderFor(A,U))return p}function v(A,U){var J=V.get(A),te;return T(J)||(te=J.get(U)),T(te)&&(te=q(A,U),T(te)||(T(J)&&(J=new m,V.set(A,J)),J.set(U,te))),te}function B(A){if(T(A))throw new TypeError;return y===A||k===A||!T(x)&&x.has(A)}function I(A,U,J){if(!B(J))throw new Error("Metadata provider not registered.");var te=v(A,U);if(te!==J){if(!T(te))return!1;var Ae=V.get(A);T(Ae)&&(Ae=new m,V.set(A,Ae)),Ae.set(U,J)}return!0}}function Qp(){var p;return!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&(p=n.Reflect[b]),T(p)&&(p=Yp()),!T(b)&&re(n.Reflect)&&Object.isExtensible(n.Reflect)&&Object.defineProperty(n.Reflect,b,{enumerable:!1,configurable:!1,writable:!1,value:p}),p}function Kp(p){var y=new C,k={isProviderFor:function(B,I){var A=y.get(B);return T(A)?!1:A.has(I)},OrdinaryDefineOwnMetadata:oe,OrdinaryHasOwnMetadata:V,OrdinaryGetOwnMetadata:ee,OrdinaryOwnMetadataKeys:q,OrdinaryDeleteMetadata:v};return S.registerProvider(k),k;function x(B,I,A){var U=y.get(B),J=!1;if(T(U)){if(!A)return;U=new m,y.set(B,U),J=!0}var te=U.get(I);if(T(te)){if(!A)return;if(te=new m,U.set(I,te),!p.setProvider(B,I,k))throw U.delete(I),J&&y.delete(B),new Error("Wrong provider for target.")}return te}function V(B,I,A){var U=x(I,A,!1);return T(U)?!1:Wa(U.has(B))}function ee(B,I,A){var U=x(I,A,!1);if(!T(U))return U.get(B)}function oe(B,I,A,U){var J=x(A,U,!0);J.set(B,I)}function q(B,I){var A=[],U=x(B,I,!1);if(T(U))return A;for(var J=U.keys(),te=Ja(J),Ae=0;;){var Ka=Ya(te);if(!Ka)return A.length=Ae,A;var rg=Xa(Ka);try{A[Ae]=rg}catch(og){try{Qa(te)}finally{throw og}}Ae++}}function v(B,I,A){var U=x(I,A,!1);if(T(U)||!U.delete(B))return!1;if(U.size===0){var J=y.get(I);T(J)||(J.delete(A),J.size===0&&y.delete(J))}return!0}}function eg(p){var y=p.defineMetadata,k=p.hasOwnMetadata,x=p.getOwnMetadata,V=p.getOwnMetadataKeys,ee=p.deleteMetadata,oe=new C,q={isProviderFor:function(v,B){var I=oe.get(v);return!T(I)&&I.has(B)?!0:V(v,B).length?(T(I)&&(I=new g,oe.set(v,I)),I.add(B),!0):!1},OrdinaryDefineOwnMetadata:y,OrdinaryHasOwnMetadata:k,OrdinaryGetOwnMetadata:x,OrdinaryOwnMetadataKeys:V,OrdinaryDeleteMetadata:ee};return q}function Xt(p,y,k){var x=S.getProvider(p,y);if(!T(x))return x;if(k){if(S.setProvider(p,y,$))return $;throw new Error("Illegal state.")}}function tg(){var p={},y=[],k=function(){function q(v,B,I){this._index=0,this._keys=v,this._values=B,this._selector=I}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 B=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:B,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 B=this._find(v,!1);return B>=0?this._values[B]:void 0},q.prototype.set=function(v,B){var I=this._find(v,!0);return this._values[I]=B,this},q.prototype.delete=function(v){var B=this._find(v,!1);if(B>=0){for(var I=this._keys.length,A=B+1;A<I;A++)this._keys[A-1]=this._keys[A],this._values[A-1]=this._values[A];return this._keys.length--,this._values.length--,cr(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,oe)},q.prototype["@@iterator"]=function(){return this.entries()},q.prototype[a]=function(){return this.entries()},q.prototype._find=function(v,B){if(!cr(this._cacheKey,v)){this._cacheIndex=-1;for(var I=0;I<this._keys.length;I++)if(cr(this._keys[I],v)){this._cacheIndex=I;break}}return this._cacheIndex<0&&B&&(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 oe(q,v){return[q,v]}}function ng(){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 ig(){var p=16,y=h.create(),k=x();return function(){function v(){this._key=x()}return v.prototype.has=function(B){var I=V(B,!1);return I!==void 0?h.has(I,this._key):!1},v.prototype.get=function(B){var I=V(B,!1);return I!==void 0?h.get(I,this._key):void 0},v.prototype.set=function(B,I){var A=V(B,!0);return A[this._key]=I,this},v.prototype.delete=function(B){var I=V(B,!1);return I!==void 0?delete I[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,B){if(!r.call(v,k)){if(!B)return;Object.defineProperty(v,k,{value:h.create()})}return v[k]}function ee(v,B){for(var I=0;I<B;++I)v[I]=Math.random()*255|0;return v}function oe(v){if(typeof Uint8Array=="function"){var B=new Uint8Array(v);return typeof crypto<"u"?crypto.getRandomValues(B):typeof msCrypto<"u"?msCrypto.getRandomValues(B):ee(B,v),B}return ee(new Array(v),v)}function q(){var v=oe(p);v[6]=v[6]&79|64,v[8]=v[8]&191|128;for(var B="",I=0;I<p;++I){var A=v[I];(I===4||I===6||I===8)&&(B+="-"),A<16&&(B+="0"),B+=A.toString(16).toLowerCase()}return B}}function ur(p){return p.__=void 0,delete p.__,p}})})(Er||(Er={}));let on;const wl=new Uint8Array(16);function bl(){if(!on&&(on=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!on))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return on(wl)}const ue=[];for(let t=0;t<256;++t)ue.push((t+256).toString(16).slice(1));function Cl(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 xr={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Xe(t,e,n){if(xr.randomUUID&&!t)return xr.randomUUID();t=t||{};const r=t.random||(t.rng||bl)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Cl(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()}}class W{static Capitalize(e){return e?e[0].toUpperCase()+e.slice(1):""}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((o,s)=>s===0?o.toLowerCase():W.Capitalize(o.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,o=>{if(o===o.toLowerCase()){const a=Object.keys(r).find(c=>r[c]===o);return a||""}const s=Object.keys(r).find(a=>r[a]===o.toLowerCase());return s?s.toUpperCase():""}):e.replace(/[A-z/,.;'\][]/g,o=>o===o.toLowerCase()?r[o]:r[o.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,""),o=n.toLowerCase().replaceAll(/\s/g,""),s=W.Translit(r),a=W.Translit(o);return r.includes(o)||s.includes(o)||r.includes(a)}static SearchIn(e,n){return W.StringsEquals(e,n)}static SearchInFields(e,n){let r=!1;for(let o=0;o<n.length;o++)if(W.SearchIn(n[o],e)){r=!0;break}return r}static FormatToPercentage(e){return`${e}%`}static ApplyClassToSubStr(e,n,r){const o=r??"highlight-text",s=new RegExp(W.GetVariants(n).join("|"),"gi");return e.replace(s,`<span class="${o}">$&</span>`)}static GetVariants(e){const n=W.Translit(e);return[e,W.Capitalize(e),e.toLowerCase(),e.toUpperCase(),n,W.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 o=n[r];if(this.isPrimitive(o))e[r]instanceof Date?e[r]=new Date(o):e[r]=o;else if(o!=null&&!Array.isArray(o))if(e[r]&&e[r].constructor)e[r]=new e[r].constructor(o);else{const s=Reflect.getMetadata(r,e);s&&(e[r]=new s[r](o))}if(Array.isArray(o)){if(o.length===0)return;const s=Reflect.getMetadata(r,e);s&&(e[r]=o.map(a=>new s[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 o=n.findIndex(s=>s.id===e);et.RemoveFromClass(o,n,r)}static RemoveFromClass(e,n,r){if(e<0)return;const o=n[e].id;o&&r&&r.push(o),n.splice(e,1)}static GetPropertyName(e){const n=new e;return new Proxy(n,{get(r,o){return o}})}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,o])=>[r,et.DeepMap(e)(o)])):e(n)}static DeepTrim(e){return this.DeepMap(W.TrimText)(e)}};l(et,"GetClassConstructor",e=>(n,r)=>{const o=Reflect.getMetadata(`property:${r}`,n)||{};o[r]=e,Reflect.defineMetadata(r,o,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 ri{static Setup(e){this.staticUrl=e}static get StaticUrl(){return this.staticUrl}}l(ri,"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:`${ri.StaticUrl}/${this.fileSystemPath}`;return new URL(e,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:$e&&$e.tagName.toUpperCase()==="SCRIPT"&&$e.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:$e&&$e.tagName.toUpperCase()==="SCRIPT"&&$e.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 vr{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=W.Capitalize(this.name),this.surname=W.Capitalize(this.surname),this.patronymic=W.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 ot{constructor(e){l(this,"id");l(this,"number");l(this,"description");l(this,"contactId");M.BuildClass(this,e)}static Create(){const e=new ot;return e.id=ne.UUID(),e}}class sn{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class oi{constructor(e){l(this,"id");l(this,"address");l(this,"description");M.BuildClass(this,e)}}class an{constructor(e){l(this,"id");l(this,"login","");l(this,"email","");l(this,"password","");M.BuildClass(this,e)}static Create(){const e=new an;return e.id=ne.UUID(),e}}let Sl=(Je=class{},l(Je,"Phone",ot),l(Je,"FileInfo",me),l(Je,"Website",oi),l(Je,"Email",rt),l(Je,"Human",vr),l(Je,"PostAddress",sn),l(Je,"UserAccount",an),Je);var X=(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))(X||{});class ln{constructor(e){l(this,"field","");l(this,"operator",X.Eq);l(this,"value","");M.BuildClass(this,e)}setValue(e){this.value=e}static Create(e,n){return new ln({operator:n,field:e})}eq(e){return this.field===e.field&&this.operator===e.operator}isUnary(){return this.operator===X.Eq||this.operator===X.Gt||this.operator===X.Lt}isBetween(){return this.operator===X.Btw}isSet(){return this.operator===X.In}}class si{constructor(e){l(this,"model","");l(this,"field","");l(this,"value","");l(this,"wheres",[]);M.BuildClass(this,e)}static Create(e){const n=new si;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 o=ln.Create(e,n);return this.wheres.push(o),o}findWhere(e){return this.wheres.find(n=>n.eq(e))}}let Mr=class el{constructor(e){l(this,"id");l(this,"model","");l(this,"wheres",[]);l(this,"joins",[]);M.BuildClass(this,e)}static Create(e){const n=new el;return n.model=e.GetClassName(),n}addWhere(e,n){const r=this.findWhere({field:e,operator:n});if(r)return r;const o=ln.Create(e,n);return this.wheres.push(o),o}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=si.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},(o,s)=>e+s*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,o)=>e[o]==n[o]))}static SwipeById(e,n,r){const o=e.findIndex(a=>n.id===a.id),s=e.findIndex(a=>r.id===a.id);o||s||([e[o],e[s]]=[e[s],e[o]])}static Swap(e,n,r){if(n<0||n>=e.length||r<0||r>=e.length)return;const o=e[n];e[n]=e[r],e[r]=o}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||{}),kl=Object.defineProperty,El=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&kl(e,n,o),o};const Br=class Yt{constructor(e){l(this,"id");l(this,"model","");l(this,"label","");l(this,"col","");l(this,"operator",X.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===X.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}"`:"",o=this.operator?`"operator":"${this.operator}"`:"",s=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===X.In?`"set":${JSON.stringify(this.set)}`:"",f=this.type===ae.Join?`"joinTableModel":"${this.joinTableModel}"`:"";return[e,n,r,o,s,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===X.Eq||this.operator===X.Gt||this.operator===X.Lt}isBetweenFilter(){return this.operator===X.Btw}isSetFilter(){return this.operator===X.In}static Create(e,n,r){const o=new Yt;return o.model=e.GetClassName(),o.col=n??"",o.type=r,o.type===ae.Number&&(o.value1="0"),o.type===ae.String&&(o.value1=""),o.type===ae.Boolean&&(o.value1="false",o.operator=X.Eq),o}static CreateFilterModelWithJoin(e,n,r,o,s,a,c,d){const u=new Yt;return u.id=Xe(),u.joinTable=r,u.joinTablePk=o,u.joinTableFk=s,u.col=n,u.type=a,c&&(u.joinTableId=c),d&&(u.joinTableIdCol=d),u}static CreateFilterModelWithJoinV2(e,n,r,o,s,a,c){const d=new Yt;return d.model=e,d.joinTableModel=r,d.joinTablePk=o,d.joinTableFk=s,d.col=n,d.type=ae.Join,a&&(d.joinTableId=a),c&&(d.joinTableIdCol=c),d}static OnlyIfSecondModelExists(e,n){const r=new Yt;return r.id=Xe(),r.model=W.ToCamelCase(e.GetClassName()),r.joinTableModel=W.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=X.Eq;return}this.setDate2(n),this.operator=X.Btw}};El([M.GetClassConstructor(String)],Br.prototype,"set");let ai=Br;class xl{constructor(){l(this,"operation",X.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,o=r?`"value":"${r}"`:"",s=this.model?`"model":"${this.model}"`:"",a=`"initial":${this.initial}`;return[e,n,o,s,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 cn{constructor(e){l(this,"page",0);l(this,"rowsPerPage",25);l(this,"rowsNumber",0);l(this,"cursor",new xl);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=X.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=X.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}`,o=`"append":${this.append}`,s=`"allLoaded":${this.allLoaded}`,a=`"cursor":{${this.cursor.toUrlQuery()}}`;return[e,n,r,o,s,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 dn{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,o,s){const a=new dn;return a.model=e.GetClassName(),a.col=n??"",a.order=r??Ee.Asc,a.label=o??"",a.default=s??!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 un{constructor(){l(this,"model","");l(this,"cols",[]);l(this,"models",[])}static Create(e,n){const r=new un;return r.model=e.GetClassName(),r.cols=n,r}}var vl=Object.defineProperty,Pt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&vl(e,n,o),o};const pt=(Se=class{constructor(e){l(this,"id");l(this,"f",[]);l(this,"f2",[]);l(this,"s",[]);l(this,"p",new cn);l(this,"t",new un);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(([o,s])=>o!=="label"&&s!==""&&s!==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 cn}resetF(){this.f=[]}},l(Se,"instance"),Se);Pt([M.GetClassConstructor(ai)],pt.prototype,"f"),Pt([M.GetClassConstructor(Mr)],pt.prototype,"f2"),Pt([M.GetClassConstructor(dn)],pt.prototype,"s"),Pt([M.GetClassConstructor(cn)],pt.prototype,"p"),Pt([M.GetClassConstructor(un)],pt.prototype,"t");let je=pt,Ml=(It=class{},l(It,"SortModel",dn),l(It,"FilterModel",ai),l(It,"FilterModelV2",Mr),l(It,"FTSP",i.reactive(je)),It);function $r(t,e){return function(){return t.apply(e,arguments)}}const{toString:Bl}=Object.prototype,{getPrototypeOf:li}=Object,{iterator:hn,toStringTag:Ir}=Symbol,fn=(t=>e=>{const n=Bl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Re=t=>(t=t.toLowerCase(),e=>fn(e)===t),mn=t=>e=>typeof e===t,{isArray:gt}=Array,Vt=mn("undefined");function Tt(t){return t!==null&&!Vt(t)&&t.constructor!==null&&!Vt(t.constructor)&&we(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Rr=Re("ArrayBuffer");function $l(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Rr(t.buffer),e}const Il=mn("string"),we=mn("function"),Nr=mn("number"),Ft=t=>t!==null&&typeof t=="object",Rl=t=>t===!0||t===!1,pn=t=>{if(fn(t)!=="object")return!1;const e=li(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Ir in t)&&!(hn in t)},Nl=t=>{if(!Ft(t)||Tt(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},Al=Re("Date"),zl=Re("File"),Pl=Re("Blob"),Vl=Re("FileList"),Tl=t=>Ft(t)&&we(t.pipe),Fl=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||we(t.append)&&((e=fn(t))==="formdata"||e==="object"&&we(t.toString)&&t.toString()==="[object FormData]"))},Ol=Re("URLSearchParams"),[Dl,Ll,Hl,ql]=["ReadableStream","Request","Response","Headers"].map(Re),Ul=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ot(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,o;if(typeof t!="object"&&(t=[t]),gt(t))for(r=0,o=t.length;r<o;r++)e.call(null,t[r],r,t);else{if(Tt(t))return;const s=n?Object.getOwnPropertyNames(t):Object.keys(t),a=s.length;let c;for(r=0;r<a;r++)c=s[r],e.call(null,t[c],c,t)}}function Ar(t,e){if(Tt(t))return null;e=e.toLowerCase();const n=Object.keys(t);let r=n.length,o;for(;r-- >0;)if(o=n[r],e===o.toLowerCase())return o;return null}const st=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,zr=t=>!Vt(t)&&t!==st;function ci(){const{caseless:t}=zr(this)&&this||{},e={},n=(r,o)=>{const s=t&&Ar(e,o)||o;pn(e[s])&&pn(r)?e[s]=ci(e[s],r):pn(r)?e[s]=ci({},r):gt(r)?e[s]=r.slice():e[s]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Ot(arguments[r],n);return e}const jl=(t,e,n,{allOwnKeys:r}={})=>(Ot(e,(o,s)=>{n&&we(o)?t[s]=$r(o,n):t[s]=o},{allOwnKeys:r}),t),Wl=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),_l=(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)},Gl=(t,e,n,r)=>{let o,s,a;const c={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),s=o.length;s-- >0;)a=o[s],(!r||r(a,t,e))&&!c[a]&&(e[a]=t[a],c[a]=!0);t=n!==!1&&li(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},Zl=(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},Jl=t=>{if(!t)return null;if(gt(t))return t;let e=t.length;if(!Nr(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},Xl=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&li(Uint8Array)),Yl=(t,e)=>{const r=(t&&t[hn]).call(t);let o;for(;(o=r.next())&&!o.done;){const s=o.value;e.call(t,s[0],s[1])}},Ql=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},Kl=Re("HTMLFormElement"),ec=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),Pr=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),tc=Re("RegExp"),Vr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Ot(n,(o,s)=>{let a;(a=e(o,s,t))!==!1&&(r[s]=a||o)}),Object.defineProperties(t,r)},nc=t=>{Vr(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+"'")})}})},ic=(t,e)=>{const n={},r=o=>{o.forEach(s=>{n[s]=!0})};return gt(t)?r(t):r(String(t).split(e)),n},rc=()=>{},oc=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function sc(t){return!!(t&&we(t.append)&&t[Ir]==="FormData"&&t[hn])}const ac=t=>{const e=new Array(10),n=(r,o)=>{if(Ft(r)){if(e.indexOf(r)>=0)return;if(Tt(r))return r;if(!("toJSON"in r)){e[o]=r;const s=gt(r)?[]:{};return Ot(r,(a,c)=>{const d=n(a,o+1);!Vt(d)&&(s[c]=d)}),e[o]=void 0,s}}return r};return n(t,0)},lc=Re("AsyncFunction"),cc=t=>t&&(Ft(t)||we(t))&&we(t.then)&&we(t.catch),Tr=((t,e)=>t?setImmediate:e?((n,r)=>(st.addEventListener("message",({source:o,data:s})=>{o===st&&s===n&&r.length&&r.shift()()},!1),o=>{r.push(o),st.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",we(st.postMessage)),dc=typeof queueMicrotask<"u"?queueMicrotask.bind(st):typeof process<"u"&&process.nextTick||Tr,w={isArray:gt,isArrayBuffer:Rr,isBuffer:Tt,isFormData:Fl,isArrayBufferView:$l,isString:Il,isNumber:Nr,isBoolean:Rl,isObject:Ft,isPlainObject:pn,isEmptyObject:Nl,isReadableStream:Dl,isRequest:Ll,isResponse:Hl,isHeaders:ql,isUndefined:Vt,isDate:Al,isFile:zl,isBlob:Pl,isRegExp:tc,isFunction:we,isStream:Tl,isURLSearchParams:Ol,isTypedArray:Xl,isFileList:Vl,forEach:Ot,merge:ci,extend:jl,trim:Ul,stripBOM:Wl,inherits:_l,toFlatObject:Gl,kindOf:fn,kindOfTest:Re,endsWith:Zl,toArray:Jl,forEachEntry:Yl,matchAll:Ql,isHTMLForm:Kl,hasOwnProperty:Pr,hasOwnProp:Pr,reduceDescriptors:Vr,freezeMethods:nc,toObjectSet:ic,toCamelCase:ec,noop:rc,toFiniteNumber:oc,findKey:Ar,global:st,isContextDefined:zr,isSpecCompliantForm:sc,toJSONObject:ac,isAsyncFn:lc,isThenable:cc,setImmediate:Tr,asap:dc,isIterable:t=>t!=null&&we(t[hn])};function F(t,e,n,r,o){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),o&&(this.response=o,this.status=o.status?o.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 Fr=F.prototype,Or={};["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=>{Or[t]={value:t}}),Object.defineProperties(F,Or),Object.defineProperty(Fr,"isAxiosError",{value:!0}),F.from=(t,e,n,r,o,s)=>{const a=Object.create(Fr);return w.toFlatObject(t,a,function(d){return d!==Error.prototype},c=>c!=="isAxiosError"),F.call(a,t.message,e,n,r,o),a.cause=t,a.name=t.name,s&&Object.assign(a,s),a};const uc=null;function di(t){return w.isPlainObject(t)||w.isArray(t)}function Dr(t){return w.endsWith(t,"[]")?t.slice(0,-2):t}function Lr(t,e,n){return t?t.concat(e).map(function(o,s){return o=Dr(o),!n&&s?"["+o+"]":o}).join(n?".":""):e}function hc(t){return w.isArray(t)&&!t.some(di)}const fc=w.toFlatObject(w,{},null,function(e){return/^is[A-Z]/.test(e)});function gn(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,o=n.visitor||h,s=n.dots,a=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&w.isSpecCompliantForm(e);if(!w.isFunction(o))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 $=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)&&hc(C)||(w.isFileList(C)||w.endsWith(b,"[]"))&&($=w.toArray(C)))return b=Dr(b),$.forEach(function(P,R){!(w.isUndefined(P)||P===null)&&e.append(a===!0?Lr([b],R,s):a===null?b:b+"[]",u(P))}),!1}return di(C)?!0:(e.append(Lr(S,b,s),u(C)),!1)}const f=[],m=Object.assign(fc,{defaultVisitor:h,convertValue:u,isVisitable:di});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($,L){(!(w.isUndefined($)||$===null)&&o.call(e,$,w.isString(L)?L.trim():L,b,m))===!0&&g($,b?b.concat(L):[L])}),f.pop()}}if(!w.isObject(t))throw new TypeError("data must be an object");return g(t),e}function Hr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function ui(t,e){this._pairs=[],t&&gn(t,this,e)}const qr=ui.prototype;qr.append=function(e,n){this._pairs.push([e,n])},qr.toString=function(e){const n=e?function(r){return e.call(this,r,Hr)}:Hr;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function mc(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Ur(t,e,n){if(!e)return t;const r=n&&n.encode||mc;w.isFunction(n)&&(n={serialize:n});const o=n&&n.serialize;let s;if(o?s=o(e,n):s=w.isURLSearchParams(e)?e.toString():new ui(e,n).toString(r),s){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+s}return t}class jr{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 Wr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},pc={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:ui,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},hi=typeof window<"u"&&typeof document<"u",fi=typeof navigator=="object"&&navigator||void 0,gc=hi&&(!fi||["ReactNative","NativeScript","NS"].indexOf(fi.product)<0),yc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",wc=hi&&window.location.href||"http://localhost",pe={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:hi,hasStandardBrowserEnv:gc,hasStandardBrowserWebWorkerEnv:yc,navigator:fi,origin:wc},Symbol.toStringTag,{value:"Module"})),...pc};function bc(t,e){return gn(t,new pe.classes.URLSearchParams,{visitor:function(n,r,o,s){return pe.isNode&&w.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)},...e})}function Cc(t){return w.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function Sc(t){const e={},n=Object.keys(t);let r;const o=n.length;let s;for(r=0;r<o;r++)s=n[r],e[s]=t[s];return e}function _r(t){function e(n,r,o,s){let a=n[s++];if(a==="__proto__")return!0;const c=Number.isFinite(+a),d=s>=n.length;return a=!a&&w.isArray(o)?o.length:a,d?(w.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!c):((!o[a]||!w.isObject(o[a]))&&(o[a]=[]),e(n,r,o[a],s)&&w.isArray(o[a])&&(o[a]=Sc(o[a])),!c)}if(w.isFormData(t)&&w.isFunction(t.entries)){const n={};return w.forEachEntry(t,(r,o)=>{e(Cc(r),o,n,0)}),n}return null}function kc(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 Dt={transitional:Wr,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,s=w.isObject(e);if(s&&w.isHTMLForm(e)&&(e=new FormData(e)),w.isFormData(e))return o?JSON.stringify(_r(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(s){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 gn(c?{"files[]":e}:e,d&&new d,this.formSerializer)}}return s||o?(n.setContentType("application/json",!1),kc(e)):e}],transformResponse:[function(e){const n=this.transitional||Dt.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(w.isResponse(e)||w.isReadableStream(e))return e;if(e&&w.isString(e)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;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=>{Dt.headers[t]={}});const Ec=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"]),xc=t=>{const e={};let n,r,o;return t&&t.split(`
15
15
  `).forEach(function(a){o=a.indexOf(":"),n=a.substring(0,o).trim().toLowerCase(),r=a.substring(o+1).trim(),!(!n||e[n]&&Ec[n])&&(n==="set-cookie"?e[n]?e[n].push(r):e[n]=[r]:e[n]=e[n]?e[n]+", "+r:r)}),e},Gr=Symbol("internals");function Lt(t){return t&&String(t).trim().toLowerCase()}function yn(t){return t===!1||t==null?t:w.isArray(t)?t.map(yn):String(t)}function vc(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 Mc=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function mi(t,e,n,r,o){if(w.isFunction(r))return r.call(this,e,n);if(o&&(e=n),!!w.isString(e)){if(w.isString(r))return e.indexOf(r)!==-1;if(w.isRegExp(r))return r.test(e)}}function Bc(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,r)=>n.toUpperCase()+r)}function $c(t,e){const n=w.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+n,{value:function(o,s,a){return this[r].call(this,e,o,s,a)},configurable:!0})})}let be=class{constructor(e){e&&this.set(e)}set(e,n,r){const o=this;function s(c,d,u){const h=Lt(d);if(!h)throw new Error("header name must be a non-empty string");const f=w.findKey(o,h);(!f||o[f]===void 0||u===!0||u===void 0&&o[f]!==!1)&&(o[f||d]=yn(c))}const a=(c,d)=>w.forEach(c,(u,h)=>s(u,h,d));if(w.isPlainObject(e)||e instanceof this.constructor)a(e,n);else if(w.isString(e)&&(e=e.trim())&&!Mc(e))a(xc(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&&s(n,e,r);return this}get(e,n){if(e=Lt(e),e){const r=w.findKey(this,e);if(r){const o=this[r];if(!n)return o;if(n===!0)return vc(o);if(w.isFunction(n))return n.call(this,o,r);if(w.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=Lt(e),e){const r=w.findKey(this,e);return!!(r&&this[r]!==void 0&&(!n||mi(this,this[r],r,n)))}return!1}delete(e,n){const r=this;let o=!1;function s(a){if(a=Lt(a),a){const c=w.findKey(r,a);c&&(!n||mi(r,r[c],c,n))&&(delete r[c],o=!0)}}return w.isArray(e)?e.forEach(s):s(e),o}clear(e){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const s=n[r];(!e||mi(this,this[s],s,e,!0))&&(delete this[s],o=!0)}return o}normalize(e){const n=this,r={};return w.forEach(this,(o,s)=>{const a=w.findKey(r,s);if(a){n[a]=yn(o),delete n[s];return}const c=e?Bc(s):String(s).trim();c!==s&&delete n[s],n[c]=yn(o),r[c]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return w.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=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(o=>r.set(o)),r}static accessor(e){const r=(this[Gr]=this[Gr]={accessors:{}}).accessors,o=this.prototype;function s(a){const c=Lt(a);r[c]||($c(o,a),r[c]=!0)}return w.isArray(e)?e.forEach(s):s(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 pi(t,e){const n=this||Dt,r=e||n,o=be.from(r.headers);let s=r.data;return w.forEach(t,function(c){s=c.call(n,s,o.normalize(),e?e.status:void 0)}),o.normalize(),s}function Zr(t){return!!(t&&t.__CANCEL__)}function yt(t,e,n){F.call(this,t??"canceled",F.ERR_CANCELED,e,n),this.name="CanceledError"}w.inherits(yt,F,{__CANCEL__:!0});function Jr(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 Ic(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function Rc(t,e){t=t||10;const n=new Array(t),r=new Array(t);let o=0,s=0,a;return e=e!==void 0?e:1e3,function(d){const u=Date.now(),h=r[s];a||(a=u),n[o]=d,r[o]=u;let f=s,m=0;for(;f!==o;)m+=n[f++],f=f%t;if(o=(o+1)%t,o===s&&(s=(s+1)%t),u-a<e)return;const g=h&&u-h;return g?Math.round(m*1e3/g):void 0}}function Nc(t,e){let n=0,r=1e3/e,o,s;const a=(u,h=Date.now())=>{n=h,o=null,s&&(clearTimeout(s),s=null),t(...u)};return[(...u)=>{const h=Date.now(),f=h-n;f>=r?a(u,h):(o=u,s||(s=setTimeout(()=>{s=null,a(o)},r-f)))},()=>o&&a(o)]}const wn=(t,e,n=3)=>{let r=0;const o=Rc(50,250);return Nc(s=>{const a=s.loaded,c=s.lengthComputable?s.total:void 0,d=a-r,u=o(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:s,lengthComputable:c!=null,[e?"download":"upload"]:!0};t(f)},n)},Xr=(t,e)=>{const n=t!=null;return[r=>e[0]({lengthComputable:n,total:t,loaded:r}),e[1]]},Yr=t=>(...e)=>w.asap(()=>t(...e)),Ac=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,zc=pe.hasStandardBrowserEnv?{write(t,e,n,r,o,s){const a=[t+"="+encodeURIComponent(e)];w.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),w.isString(r)&&a.push("path="+r),w.isString(o)&&a.push("domain="+o),s===!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 Pc(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Vc(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function Qr(t,e,n){let r=!Pc(e);return t&&(r||n==!1)?Vc(t,e):e}const Kr=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 o(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 s(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:s,method:s,data:s,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)=>o(Kr(u),Kr(h),f,!0)};return w.forEach(Object.keys({...t,...e}),function(h){const f=d[h]||o,m=f(t[h],e[h],h);w.isUndefined(m)&&f!==c||(n[h]=m)}),n}const eo=t=>{const e=at({},t);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:s,headers:a,auth:c}=e;e.headers=a=be.from(a),e.url=Ur(Qr(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&&Ac(e.url))){const u=o&&s&&zc.read(s);u&&a.set(o,u)}return e},Tc=typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,r){const o=eo(t);let s=o.data;const a=be.from(o.headers).normalize();let{responseType:c,onUploadProgress:d,onDownloadProgress:u}=o,h,f,m,g,C;function b(){g&&g(),C&&C(),o.cancelToken&&o.cancelToken.unsubscribe(h),o.signal&&o.signal.removeEventListener("abort",h)}let S=new XMLHttpRequest;S.open(o.method.toUpperCase(),o.url,!0),S.timeout=o.timeout;function $(){if(!S)return;const P=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:P,config:t,request:S};Jr(function(Be){n(Be),b()},function(Be){r(Be),b()},H),S=null}"onloadend"in S?S.onloadend=$:S.onreadystatechange=function(){!S||S.readyState!==4||S.status===0&&!(S.responseURL&&S.responseURL.indexOf("file:")===0)||setTimeout($)},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 R=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const H=o.transitional||Wr;o.timeoutErrorMessage&&(R=o.timeoutErrorMessage),r(new F(R,H.clarifyTimeoutError?F.ETIMEDOUT:F.ECONNABORTED,t,S)),S=null},s===void 0&&a.setContentType(null),"setRequestHeader"in S&&w.forEach(a.toJSON(),function(R,H){S.setRequestHeader(H,R)}),w.isUndefined(o.withCredentials)||(S.withCredentials=!!o.withCredentials),c&&c!=="json"&&(S.responseType=o.responseType),u&&([m,C]=wn(u,!0),S.addEventListener("progress",m)),d&&S.upload&&([f,g]=wn(d),S.upload.addEventListener("progress",f),S.upload.addEventListener("loadend",g)),(o.cancelToken||o.signal)&&(h=P=>{S&&(r(!P||P.type?new yt(null,t,S):P),S.abort(),S=null)},o.cancelToken&&o.cancelToken.subscribe(h),o.signal&&(o.signal.aborted?h():o.signal.addEventListener("abort",h)));const L=Ic(o.url);if(L&&pe.protocols.indexOf(L)===-1){r(new F("Unsupported protocol "+L+":",F.ERR_BAD_REQUEST,t));return}S.send(s||null)})},Fc=(t,e)=>{const{length:n}=t=t?t.filter(Boolean):[];if(e||n){let r=new AbortController,o;const s=function(u){if(!o){o=!0,c();const h=u instanceof Error?u:this.reason;r.abort(h instanceof F?h:new yt(h instanceof Error?h.message:h))}};let a=e&&setTimeout(()=>{a=null,s(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(s):u.removeEventListener("abort",s)}),t=null)};t.forEach(u=>u.addEventListener("abort",s));const{signal:d}=r;return d.unsubscribe=()=>w.asap(c),d}},Oc=function*(t,e){let n=t.byteLength;if(n<e){yield t;return}let r=0,o;for(;r<n;)o=r+e,yield t.slice(r,o),r=o},Dc=async function*(t,e){for await(const n of Lc(t))yield*Oc(n,e)},Lc=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()}},to=(t,e,n,r)=>{const o=Dc(t,e);let s=0,a,c=d=>{a||(a=!0,r&&r(d))};return new ReadableStream({async pull(d){try{const{done:u,value:h}=await o.next();if(u){c(),d.close();return}let f=h.byteLength;if(n){let m=s+=f;n(m)}d.enqueue(new Uint8Array(h))}catch(u){throw c(u),u}},cancel(d){return c(d),o.return()}},{highWaterMark:2})},bn=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",no=bn&&typeof ReadableStream=="function",Hc=bn&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),io=(t,...e)=>{try{return!!t(...e)}catch{return!1}},qc=no&&io(()=>{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}),ro=64*1024,gi=no&&io(()=>w.isReadableStream(new Response("").body)),Cn={stream:gi&&(t=>t.body)};bn&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!Cn[e]&&(Cn[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 Uc=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 Hc(t)).byteLength},jc=async(t,e)=>{const n=w.toFiniteNumber(t.getContentLength());return n??Uc(e)},yi={http:uc,xhr:Tc,fetch:bn&&(async t=>{let{url:e,method:n,data:r,signal:o,cancelToken:s,timeout:a,onDownloadProgress:c,onUploadProgress:d,responseType:u,headers:h,withCredentials:f="same-origin",fetchOptions:m}=eo(t);u=u?(u+"").toLowerCase():"text";let g=Fc([o,s&&s.toAbortSignal()],a),C;const b=g&&g.unsubscribe&&(()=>{g.unsubscribe()});let S;try{if(d&&qc&&n!=="get"&&n!=="head"&&(S=await jc(h,r))!==0){let H=new Request(e,{method:"POST",body:r,duplex:"half"}),Me;if(w.isFormData(r)&&(Me=H.headers.get("content-type"))&&h.setContentType(Me),H.body){const[Be,nt]=Xr(S,wn(Yr(d)));r=to(H.body,ro,Be,nt)}}w.isString(f)||(f=f?"include":"omit");const $="credentials"in Request.prototype;C=new Request(e,{...m,signal:g,method:n.toUpperCase(),headers:h.normalize().toJSON(),body:r,duplex:"half",credentials:$?f:void 0});let L=await fetch(C,m);const P=gi&&(u==="stream"||u==="response");if(gi&&(c||P&&b)){const H={};["status","statusText","headers"].forEach(Rt=>{H[Rt]=L[Rt]});const Me=w.toFiniteNumber(L.headers.get("content-length")),[Be,nt]=c&&Xr(Me,wn(Yr(c),!0))||[];L=new Response(to(L.body,ro,Be,()=>{nt&&nt(),b&&b()}),H)}u=u||"text";let R=await Cn[w.findKey(Cn,u)||"text"](L,t);return!P&&b&&b(),await new Promise((H,Me)=>{Jr(H,Me,{data:R,headers:be.from(L.headers),status:L.status,statusText:L.statusText,config:t,request:C})})}catch($){throw b&&b(),$&&$.name==="TypeError"&&/Load failed|fetch/i.test($.message)?Object.assign(new F("Network Error",F.ERR_NETWORK,t,C),{cause:$.cause||$}):F.from($,$&&$.code,t,C)}})};w.forEach(yi,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const oo=t=>`- ${t}`,Wc=t=>w.isFunction(t)||t===null||t===!1,so={getAdapter:t=>{t=w.isArray(t)?t:[t];const{length:e}=t;let n,r;const o={};for(let s=0;s<e;s++){n=t[s];let a;if(r=n,!Wc(n)&&(r=yi[(a=String(n)).toLowerCase()],r===void 0))throw new F(`Unknown adapter '${a}'`);if(r)break;o[a||"#"+s]=r}if(!r){const s=Object.entries(o).map(([c,d])=>`adapter ${c} `+(d===!1?"is not supported by the environment":"is not available in the build"));let a=e?s.length>1?`since :
17
17
  `+s.map(oo).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.5",
5
+ "version": "0.1.6",
6
6
  "private": false,
7
7
  "type": "module",
8
8
  "main": "./dist/sprof.umd.cjs",