@dappworks/urpc
Advanced tools
Comparing version 0.0.11 to 0.0.12
@@ -11,14 +11,15 @@ // Generated by dts-bundle-generator v9.5.1 | ||
export type FormConfigType<T> = { | ||
[F in keyof T]?: { | ||
title?: string; | ||
description?: string; | ||
required?: boolean; | ||
selectOptions?: { | ||
label: string; | ||
value: string; | ||
}[]; | ||
} & UiSchema; | ||
[F in keyof T]?: FormConfigItem; | ||
}; | ||
export type FormConfigItem = { | ||
title?: string; | ||
description?: string; | ||
required?: boolean; | ||
selectOptions?: { | ||
label: string; | ||
value: string; | ||
}[]; | ||
} & UiSchema; | ||
export interface URPC_Function<T extends Object = {}, R = any> { | ||
uid?: string; | ||
uid: string; | ||
type?: "func"; | ||
@@ -34,3 +35,3 @@ name?: string; | ||
export interface URPC_Variable<T extends () => any = () => any, R = any> { | ||
uid?: string; | ||
uid: string; | ||
type?: "var"; | ||
@@ -51,7 +52,15 @@ name?: string; | ||
uidSchemas: URPC_Schema; | ||
static Var<T extends () => any, R = any>(args: URPC_Variable<T, R>): URPC_Variable<T, R>; | ||
static Func<T extends Object = {}, R = any>(args: URPC_Function<T, R>): URPC_Function<T, R>; | ||
static Var<T extends () => any, R = any>(args: Partial<URPC_Variable<T, R>>): URPC_Variable<T, R>; | ||
static Func<T extends Object = {}, R = any>(args: Partial<URPC_Function<T, R>>): URPC_Function<T, R>; | ||
static UI: { | ||
Table({ actions }: { | ||
actions: { | ||
title: string; | ||
event: string; | ||
}[]; | ||
}): FormConfigItem; | ||
}; | ||
constructor(args?: Partial<URPC<T>>); | ||
loadFull(): ({ | ||
uid: string | undefined; | ||
uid: string; | ||
type: "func"; | ||
@@ -64,3 +73,3 @@ name: string | undefined; | ||
} | { | ||
uid: string | undefined; | ||
uid: string; | ||
type: "var" | undefined; | ||
@@ -120,3 +129,3 @@ name: string | undefined; | ||
loadFull(): Promise<({ | ||
uid: string | undefined; | ||
uid: string; | ||
type: "func"; | ||
@@ -129,3 +138,3 @@ name: string | undefined; | ||
} | { | ||
uid: string | undefined; | ||
uid: string; | ||
type: "var" | undefined; | ||
@@ -132,0 +141,0 @@ name: string | undefined; |
@@ -1,1 +0,1 @@ | ||
var R$=Object.create;var{defineProperty:uU,getPrototypeOf:J$,getOwnPropertyNames:B$}=Object;var X$=Object.prototype.hasOwnProperty;var PU=(U,Z,$)=>{$=U!=null?R$(J$(U)):{};const Q=Z||!U||!U.__esModule?uU($,"default",{value:U,enumerable:!0}):$;for(let R of B$(U))if(!X$.call(Q,R))uU(Q,R,{get:()=>U[R],enumerable:!0});return Q};var EU=(U,Z)=>()=>(Z||U((Z={exports:{}}).exports,Z),Z.exports);var BZ=EU((U1,JZ)=>{var z$=function(U,Z){return U==null?void 0:U[Z]},D$=function(U){var Z=!1;if(U!=null&&typeof U.toString!="function")try{Z=!!(U+"")}catch($){}return Z},I=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},C$=function(){this.__data__=y?y(null):{}},f$=function(U){return this.has(U)&&delete this.__data__[U]},T$=function(U){var Z=this.__data__;if(y){var $=Z[U];return $===tU?void 0:$}return s.call(Z,U)?Z[U]:void 0},m$=function(U){var Z=this.__data__;return y?Z[U]!==void 0:s.call(Z,U)},d$=function(U,Z){var $=this.__data__;return $[U]=y&&Z===void 0?tU:Z,this},m=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},p$=function(){this.__data__=[]},g$=function(U){var Z=this.__data__,$=l(Z,U);if($<0)return!1;var Q=Z.length-1;if($==Q)Z.pop();else x$.call(Z,$,1);return!0},j$=function(U){var Z=this.__data__,$=l(Z,U);return $<0?void 0:Z[$][1]},n$=function(U){return l(this.__data__,U)>-1},k$=function(U,Z){var $=this.__data__,Q=l($,U);if(Q<0)$.push([U,Z]);else $[Q][1]=Z;return this},x=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},y$=function(){this.__data__={hash:new I,map:new(A$||m),string:new I}},h$=function(U){return o(this,U).delete(U)},b$=function(U){return o(this,U).get(U)},v$=function(U){return o(this,U).has(U)},i$=function(U,Z){return o(this,U).set(U,Z),this},c$=function(U,Z,$){var Q=U[Z];if(!(s.call(U,Z)&&QZ(Q,$))||$===void 0&&!(Z in U))U[Z]=$},l=function(U,Z){var $=U.length;while($--)if(QZ(U[$][0],Z))return $;return-1},u$=function(U){if(!u(U)||e$(U))return!1;var Z=QQ(U)||D$(U)?I$:L$;return Z.test($Q(U))},s$=function(U,Z,$,Q){if(!u(U))return U;Z=t$(Z,U)?[Z]:o$(Z);var R=-1,J=Z.length,B=J-1,X=U;while(X!=null&&++R<J){var Y=ZQ(Z[R]),K=$;if(R!=B){var _=X[Y];if(K=Q?Q(_,Y,X):void 0,K===void 0)K=u(_)?_:r$(Z[R+1])?[]:{}}c$(X,Y,K),X=X[Y]}return U},l$=function(U){if(typeof U=="string")return U;if(MU(U))return rU?rU.call(U):"";var Z=U+"";return Z=="0"&&1/U==-aU?"-0":Z},o$=function(U){return RZ(U)?U:UQ(U)},o=function(U,Z){var $=U.__data__;return a$(Z)?$[typeof Z=="string"?"string":"hash"]:$.map},$Z=function(U,Z){var $=z$(U,Z);return u$($)?$:void 0},r$=function(U,Z){return Z=Z==null?W$:Z,!!Z&&(typeof U=="number"||O$.test(U))&&(U>-1&&U%1==0&&U<Z)},t$=function(U,Z){if(RZ(U))return!1;var $=typeof U;if($=="number"||$=="symbol"||$=="boolean"||U==null||MU(U))return!0;return q$.test(U)||!w$.test(U)||Z!=null&&U in Object(Z)},a$=function(U){var Z=typeof U;return Z=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?U!=="__proto__":U===null},e$=function(U){return!!sU&&sU in U},ZQ=function(U){if(typeof U=="string"||MU(U))return U;var Z=U+"";return Z=="0"&&1/U==-aU?"-0":Z},$Q=function(U){if(U!=null){try{return UZ.call(U)}catch(Z){}try{return U+""}catch(Z){}}return""},HU=function(U,Z){if(typeof U!="function"||Z&&typeof Z!="function")throw new TypeError(Y$);var $=function(){var Q=arguments,R=Z?Z.apply(this,Q):Q[0],J=$.cache;if(J.has(R))return J.get(R);var B=U.apply(this,Q);return $.cache=J.set(R,B),B};return $.cache=new(HU.Cache||x),$},QZ=function(U,Z){return U===Z||U!==U&&Z!==Z},QQ=function(U){var Z=u(U)?ZZ.call(U):"";return Z==K$||Z==_$},u=function(U){var Z=typeof U;return!!U&&(Z=="object"||Z=="function")},RQ=function(U){return!!U&&typeof U=="object"},MU=function(U){return typeof U=="symbol"||RQ(U)&&ZZ.call(U)==G$},JQ=function(U){return U==null?"":l$(U)},BQ=function(U,Z,$){return U==null?U:s$(U,Z,$)},Y$="Expected a function",tU="__lodash_hash_undefined__",aU=Infinity,W$=9007199254740991,K$="[object Function]",_$="[object GeneratorFunction]",G$="[object Symbol]",w$=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,q$=/^\w*$/,F$=/^\./,N$=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,P$=/[\\^$.*+?()[\]{}|]/g,E$=/\\(\\)?/g,L$=/^\[object .+?Constructor\]$/,O$=/^(?:0|[1-9]\d*)$/,H$=typeof global=="object"&&global&&global.Object===Object&&global,M$=typeof self=="object"&&self&&self.Object===Object&&self,OU=H$||M$||Function("return this")(),S$=Array.prototype,V$=Function.prototype,eU=Object.prototype,LU=OU["__core-js_shared__"],sU=function(){var U=/[^.]+$/.exec(LU&&LU.keys&&LU.keys.IE_PROTO||"");return U?"Symbol(src)_1."+U:""}(),UZ=V$.toString,s=eU.hasOwnProperty,ZZ=eU.toString,I$=RegExp("^"+UZ.call(s).replace(P$,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),lU=OU.Symbol,x$=S$.splice,A$=$Z(OU,"Map"),y=$Z(Object,"create"),oU=lU?lU.prototype:void 0,rU=oU?oU.toString:void 0;I.prototype.clear=C$;I.prototype.delete=f$;I.prototype.get=T$;I.prototype.has=m$;I.prototype.set=d$;m.prototype.clear=p$;m.prototype.delete=g$;m.prototype.get=j$;m.prototype.has=n$;m.prototype.set=k$;x.prototype.clear=y$;x.prototype.delete=h$;x.prototype.get=b$;x.prototype.has=v$;x.prototype.set=i$;var UQ=HU(function(U){U=JQ(U);var Z=[];if(F$.test(U))Z.push("");return U.replace(N$,function($,Q,R,J){Z.push(R?J.replace(E$,"$1"):Q||$)}),Z});HU.Cache=x;var RZ=Array.isArray;JZ.exports=BQ});var hZ=EU((e,p)=>{var TQ=function(U,Z,$,Q){var R=-1,J=U?U.length:0;while(++R<J){var B=U[R];Z(Q,B,$(B),U)}return Q},mQ=function(U,Z){var $=-1,Q=U?U.length:0;while(++$<Q)if(Z(U[$],$,U))return!0;return!1},dQ=function(U){return function(Z){return Z==null?void 0:Z[U]}},pQ=function(U,Z){var $=-1,Q=Array(U);while(++$<U)Q[$]=Z($);return Q},gQ=function(U){return function(Z){return U(Z)}},jQ=function(U,Z){return U==null?void 0:U[Z]},AU=function(U){var Z=!1;if(U!=null&&typeof U.toString!="function")try{Z=!!(U+"")}catch($){}return Z},nQ=function(U){var Z=-1,$=Array(U.size);return U.forEach(function(Q,R){$[++Z]=[R,Q]}),$},kQ=function(U,Z){return function($){return U(Z($))}},yQ=function(U){var Z=-1,$=Array(U.size);return U.forEach(function(Q){$[++Z]=Q}),$},A=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},aQ=function(){this.__data__=b?b(null):{}},eQ=function(U){return this.has(U)&&delete this.__data__[U]},UR=function(U){var Z=this.__data__;if(b){var $=Z[U];return $===dU?void 0:$}return L.call(Z,U)?Z[U]:void 0},ZR=function(U){var Z=this.__data__;return b?Z[U]!==void 0:L.call(Z,U)},$R=function(U,Z){var $=this.__data__;return $[U]=b&&Z===void 0?dU:Z,this},O=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},QR=function(){this.__data__=[]},RR=function(U){var Z=this.__data__,$=WU(Z,U);if($<0)return!1;var Q=Z.length-1;if($==Q)Z.pop();else cQ.call(Z,$,1);return!0},JR=function(U){var Z=this.__data__,$=WU(Z,U);return $<0?void 0:Z[$][1]},BR=function(U){return WU(this.__data__,U)>-1},XR=function(U,Z){var $=this.__data__,Q=WU($,U);if(Q<0)$.push([U,Z]);else $[Q][1]=Z;return this},H=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},YR=function(){this.__data__={hash:new A,map:new(h||O),string:new A}},WR=function(U){return KU(this,U).delete(U)},KR=function(U){return KU(this,U).get(U)},_R=function(U){return KU(this,U).has(U)},GR=function(U,Z){return KU(this,U).set(U,Z),this},JU=function(U){var Z=-1,$=U?U.length:0;this.__data__=new H;while(++Z<$)this.add(U[Z])},wR=function(U){return this.__data__.set(U,dU),this},qR=function(U){return this.__data__.has(U)},E=function(U){this.__data__=new O(U)},FR=function(){this.__data__=new O},NR=function(U){return this.__data__.delete(U)},PR=function(U){return this.__data__.get(U)},ER=function(U){return this.__data__.has(U)},LR=function(U,Z){var $=this.__data__;if($ instanceof O){var Q=$.__data__;if(!h||Q.length<KQ-1)return Q.push([U,Z]),this;$=this.__data__=new H(Q)}return $.set(U,Z),this},OR=function(U,Z){var $=D(U)||kZ(U)?pQ(U.length,String):[],Q=$.length,R=!!Q;for(var J in U)if((Z||L.call(U,J))&&!(R&&(J=="length"||pZ(J,Q))))$.push(J);return $},WU=function(U,Z){var $=U.length;while($--)if(nZ(U[$][0],Z))return $;return-1},HR=function(U,Z,$,Q){return MR(U,function(R,J,B){Z(Q,R,$(R),B)}),Q},DR=function(U,Z){return U&&zR(U,Z,BU)},TZ=function(U,Z){Z=_U(Z,U)?[Z]:mZ(Z);var $=0,Q=Z.length;while(U!=null&&$<Q)U=U[GU(Z[$++])];return $&&$==Q?U:void 0},SR=function(U){return j.call(U)},VR=function(U,Z){return U!=null&&Z in Object(U)},pU=function(U,Z,$,Q,R){if(U===Z)return!0;if(U==null||Z==null||!wU(U)&&!qU(Z))return U!==U&&Z!==Z;return IR(U,Z,pU,$,Q,R)},IR=function(U,Z,$,Q,R,J){var B=D(U),X=D(Z),Y=IU,K=IU;if(!B)Y=z(U),Y=Y==UU?d:Y;if(!X)K=z(Z),K=K==UU?d:K;var _=Y==d&&!AU(U),q=K==d&&!AU(Z),G=Y==K;if(G&&!_)return J||(J=new E),B||rR(U)?dZ(U,Z,$,Q,R,J):yR(U,Z,Y,$,Q,R,J);if(!(R&g)){var F=_&&L.call(U,"__wrapped__"),N=q&&L.call(Z,"__wrapped__");if(F||N){var M=F?U.value():U,P=N?Z.value():Z;return J||(J=new E),$(M,P,Q,R,J)}}if(!G)return!1;return J||(J=new E),hR(U,Z,$,Q,R,J)},xR=function(U,Z,$,Q){var R=$.length,J=R,B=!Q;if(U==null)return!J;U=Object(U);while(R--){var X=$[R];if(B&&X[2]?X[1]!==U[X[0]]:!(X[0]in U))return!1}while(++R<J){X=$[R];var Y=X[0],K=U[Y],_=X[1];if(B&&X[2]){if(K===void 0&&!(Y in U))return!1}else{var q=new E;if(Q)var G=Q(K,_,Y,U,Z,q);if(!(G===void 0?pU(_,K,Q,XU|g,q):G))return!1}}return!0},AR=function(U){if(!wU(U)||cR(U))return!1;var Z=yZ(U)||AU(U)?vQ:xQ;return Z.test(C(U))},CR=function(U){return qU(U)&&nU(U.length)&&!!W[j.call(U)]},fR=function(U){if(typeof U=="function")return U;if(U==null)return U8;if(typeof U=="object")return D(U)?dR(U[0],U[1]):mR(U);return Z8(U)},TR=function(U){if(!uR(U))return uQ(U);var Z=[];for(var $ in Object(U))if(L.call(U,$)&&$!="constructor")Z.push($);return Z},mR=function(U){var Z=bR(U);if(Z.length==1&&Z[0][2])return jZ(Z[0][0],Z[0][1]);return function($){return $===U||xR($,U,Z)}},dR=function(U,Z){if(_U(U)&&gZ(Z))return jZ(GU(U),Z);return function($){var Q=aR($,U);return Q===void 0&&Q===Z?eR($,U):pU(Z,Q,void 0,XU|g)}},pR=function(U){return function(Z){return TZ(Z,U)}},gR=function(U){if(typeof U=="string")return U;if(kU(U))return PZ?PZ.call(U):"";var Z=U+"";return Z=="0"&&1/U==-EZ?"-0":Z},mZ=function(U){return D(U)?U:sR(U)},jR=function(U,Z){return function($,Q){var R=D($)?TQ:HR,J=Z?Z():{};return R($,U,fR(Q,2),J)}},nR=function(U,Z){return function($,Q){if($==null)return $;if(!jU($))return U($,Q);var R=$.length,J=Z?R:-1,B=Object($);while(Z?J--:++J<R)if(Q(B[J],J,B)===!1)break;return $}},kR=function(U){return function(Z,$,Q){var R=-1,J=Object(Z),B=Q(Z),X=B.length;while(X--){var Y=B[U?X:++R];if($(J[Y],Y,J)===!1)break}return Z}},dZ=function(U,Z,$,Q,R,J){var B=R&g,X=U.length,Y=Z.length;if(X!=Y&&!(B&&Y>X))return!1;var K=J.get(U);if(K&&J.get(Z))return K==Z;var _=-1,q=!0,G=R&XU?new JU:void 0;J.set(U,Z),J.set(Z,U);while(++_<X){var F=U[_],N=Z[_];if(Q)var M=B?Q(N,F,_,Z,U,J):Q(F,N,_,U,Z,J);if(M!==void 0){if(M)continue;q=!1;break}if(G){if(!mQ(Z,function(P,V){if(!G.has(V)&&(F===P||$(F,P,Q,R,J)))return G.add(V)})){q=!1;break}}else if(!(F===N||$(F,N,Q,R,J))){q=!1;break}}return J.delete(U),J.delete(Z),q},yR=function(U,Z,$,Q,R,J,B){switch($){case QU:if(U.byteLength!=Z.byteLength||U.byteOffset!=Z.byteOffset)return!1;U=U.buffer,Z=Z.buffer;case xZ:if(U.byteLength!=Z.byteLength||!Q(new NZ(U),new NZ(Z)))return!1;return!0;case OZ:case HZ:case DZ:return nZ(+U,+Z);case MZ:return U.name==Z.name&&U.message==Z.message;case SZ:case VZ:return U==Z+"";case ZU:var X=nQ;case $U:var Y=J&g;if(X||(X=yQ),U.size!=Z.size&&!Y)return!1;var K=B.get(U);if(K)return K==Z;J|=XU,B.set(U,Z);var _=dZ(X(U),X(Z),Q,R,J,B);return B.delete(U),_;case IZ:if(VU)return VU.call(U)==VU.call(Z)}return!1},hR=function(U,Z,$,Q,R,J){var B=R&g,X=BU(U),Y=X.length,K=BU(Z),_=K.length;if(Y!=_&&!B)return!1;var q=Y;while(q--){var G=X[q];if(!(B?G in Z:L.call(Z,G)))return!1}var F=J.get(U);if(F&&J.get(Z))return F==Z;var N=!0;J.set(U,Z),J.set(Z,U);var M=B;while(++q<Y){G=X[q];var P=U[G],V=Z[G];if(Q)var cU=B?Q(V,P,G,Z,U,J):Q(P,V,G,U,Z,J);if(!(cU===void 0?P===V||$(P,V,Q,R,J):cU)){N=!1;break}M||(M=G=="constructor")}if(N&&!M){var i=U.constructor,c=Z.constructor;if(i!=c&&(("constructor"in U)&&("constructor"in Z))&&!(typeof i=="function"&&i instanceof i&&typeof c=="function"&&c instanceof c))N=!1}return J.delete(U),J.delete(Z),N},KU=function(U,Z){var $=U.__data__;return iR(Z)?$[typeof Z=="string"?"string":"hash"]:$.map},bR=function(U){var Z=BU(U),$=Z.length;while($--){var Q=Z[$],R=U[Q];Z[$]=[Q,R,gZ(R)]}return Z},n=function(U,Z){var $=jQ(U,Z);return AR($)?$:void 0},vR=function(U,Z,$){Z=_U(Z,U)?[Z]:mZ(Z);var Q,R=-1,B=Z.length;while(++R<B){var J=GU(Z[R]);if(!(Q=U!=null&&$(U,J)))break;U=U[J]}if(Q)return Q;var B=U?U.length:0;return!!B&&nU(B)&&pZ(J,B)&&(D(U)||kZ(U))},pZ=function(U,Z){return Z=Z==null?LZ:Z,!!Z&&(typeof U=="number"||AQ.test(U))&&(U>-1&&U%1==0&&U<Z)},_U=function(U,Z){if(D(U))return!1;var $=typeof U;if($=="number"||$=="symbol"||$=="boolean"||U==null||kU(U))return!0;return zQ.test(U)||!MQ.test(U)||Z!=null&&U in Object(Z)},iR=function(U){var Z=typeof U;return Z=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?U!=="__proto__":U===null},cR=function(U){return!!qZ&&qZ in U},uR=function(U){var Z=U&&U.constructor,$=typeof Z=="function"&&Z.prototype||YU;return U===$},gZ=function(U){return U===U&&!wU(U)},jZ=function(U,Z){return function($){if($==null)return!1;return $[U]===Z&&(Z!==void 0||(U in Object($)))}},GU=function(U){if(typeof U=="string"||kU(U))return U;var Z=U+"";return Z=="0"&&1/U==-EZ?"-0":Z},C=function(U){if(U!=null){try{return fZ.call(U)}catch(Z){}try{return U+""}catch(Z){}}return""},gU=function(U,Z){if(typeof U!="function"||Z&&typeof Z!="function")throw new TypeError(_Q);var $=function(){var Q=arguments,R=Z?Z.apply(this,Q):Q[0],J=$.cache;if(J.has(R))return J.get(R);var B=U.apply(this,Q);return $.cache=J.set(R,B),B};return $.cache=new(gU.Cache||H),$},nZ=function(U,Z){return U===Z||U!==U&&Z!==Z},kZ=function(U){return oR(U)&&L.call(U,"callee")&&(!iQ.call(U,"callee")||j.call(U)==UU)},jU=function(U){return U!=null&&nU(U.length)&&!yZ(U)},oR=function(U){return qU(U)&&jU(U)},yZ=function(U){var Z=wU(U)?j.call(U):"";return Z==zZ||Z==GQ},nU=function(U){return typeof U=="number"&&U>-1&&U%1==0&&U<=LZ},wU=function(U){var Z=typeof U;return!!U&&(Z=="object"||Z=="function")},qU=function(U){return!!U&&typeof U=="object"},kU=function(U){return typeof U=="symbol"||qU(U)&&j.call(U)==IZ},tR=function(U){return U==null?"":gR(U)},aR=function(U,Z,$){var Q=U==null?void 0:TZ(U,Z);return Q===void 0?$:Q},eR=function(U,Z){return U!=null&&vR(U,Z,VR)},BU=function(U){return jU(U)?OR(U):TR(U)},U8=function(U){return U},Z8=function(U){return _U(U)?dQ(GU(U)):pR(U)},KQ=200,_Q="Expected a function",dU="__lodash_hash_undefined__",XU=1,g=2,EZ=Infinity,LZ=9007199254740991,UU="[object Arguments]",IU="[object Array]",OZ="[object Boolean]",HZ="[object Date]",MZ="[object Error]",zZ="[object Function]",GQ="[object GeneratorFunction]",ZU="[object Map]",DZ="[object Number]",d="[object Object]",WZ="[object Promise]",SZ="[object RegExp]",$U="[object Set]",VZ="[object String]",IZ="[object Symbol]",xU="[object WeakMap]",xZ="[object ArrayBuffer]",QU="[object DataView]",wQ="[object Float32Array]",qQ="[object Float64Array]",FQ="[object Int8Array]",NQ="[object Int16Array]",PQ="[object Int32Array]",EQ="[object Uint8Array]",LQ="[object Uint8ClampedArray]",OQ="[object Uint16Array]",HQ="[object Uint32Array]",MQ=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,zQ=/^\w*$/,DQ=/^\./,SQ=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,VQ=/[\\^$.*+?()[\]{}|]/g,IQ=/\\(\\)?/g,xQ=/^\[object .+?Constructor\]$/,AQ=/^(?:0|[1-9]\d*)$/,W={};W[wQ]=W[qQ]=W[FQ]=W[NQ]=W[PQ]=W[EQ]=W[LQ]=W[OQ]=W[HQ]=!0;W[UU]=W[IU]=W[xZ]=W[OZ]=W[QU]=W[HZ]=W[MZ]=W[zZ]=W[ZU]=W[DZ]=W[d]=W[SZ]=W[$U]=W[VZ]=W[xU]=!1;var AZ=typeof global=="object"&&global&&global.Object===Object&&global,CQ=typeof self=="object"&&self&&self.Object===Object&&self,S=AZ||CQ||Function("return this")(),CZ=typeof e=="object"&&e&&!e.nodeType&&e,KZ=CZ&&typeof p=="object"&&p&&!p.nodeType&&p,fQ=KZ&&KZ.exports===CZ,_Z=fQ&&AZ.process,GZ=function(){try{return _Z&&_Z.binding("util")}catch(U){}}(),wZ=GZ&&GZ.isTypedArray,hQ=Array.prototype,bQ=Function.prototype,YU=Object.prototype,SU=S["__core-js_shared__"],qZ=function(){var U=/[^.]+$/.exec(SU&&SU.keys&&SU.keys.IE_PROTO||"");return U?"Symbol(src)_1."+U:""}(),fZ=bQ.toString,L=YU.hasOwnProperty,j=YU.toString,vQ=RegExp("^"+fZ.call(L).replace(VQ,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),FZ=S.Symbol,NZ=S.Uint8Array,iQ=YU.propertyIsEnumerable,cQ=hQ.splice,uQ=kQ(Object.keys,Object),CU=n(S,"DataView"),h=n(S,"Map"),fU=n(S,"Promise"),TU=n(S,"Set"),mU=n(S,"WeakMap"),b=n(Object,"create"),sQ=C(CU),lQ=C(h),oQ=C(fU),rQ=C(TU),tQ=C(mU),RU=FZ?FZ.prototype:void 0,VU=RU?RU.valueOf:void 0,PZ=RU?RU.toString:void 0;A.prototype.clear=aQ;A.prototype.delete=eQ;A.prototype.get=UR;A.prototype.has=ZR;A.prototype.set=$R;O.prototype.clear=QR;O.prototype.delete=RR;O.prototype.get=JR;O.prototype.has=BR;O.prototype.set=XR;H.prototype.clear=YR;H.prototype.delete=WR;H.prototype.get=KR;H.prototype.has=_R;H.prototype.set=GR;JU.prototype.add=JU.prototype.push=wR;JU.prototype.has=qR;E.prototype.clear=FR;E.prototype.delete=NR;E.prototype.get=PR;E.prototype.has=ER;E.prototype.set=LR;var MR=nR(DR),zR=kR(),z=SR;if(CU&&z(new CU(new ArrayBuffer(1)))!=QU||h&&z(new h)!=ZU||fU&&z(fU.resolve())!=WZ||TU&&z(new TU)!=$U||mU&&z(new mU)!=xU)z=function(U){var Z=j.call(U),$=Z==d?U.constructor:void 0,Q=$?C($):void 0;if(Q)switch(Q){case sQ:return QU;case lQ:return ZU;case oQ:return WZ;case rQ:return $U;case tQ:return xU}return Z};var sR=gU(function(U){U=tR(U);var Z=[];if(DQ.test(U))Z.push("");return U.replace(SQ,function($,Q,R,J){Z.push(R?J.replace(IQ,"$1"):Q||$)}),Z}),lR=jR(function(U,Z,$){U[$]=Z});gU.Cache=H;var D=Array.isArray,rR=wZ?gQ(wZ):CR;p.exports=lR});var $$=EU((F1,Z$)=>{var N8=function(U,Z){return U==null?void 0:U[Z]},P8=function(U){var Z=!1;if(U!=null&&typeof U.toString!="function")try{Z=!!(U+"")}catch($){}return Z},f=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},z8=function(){this.__data__=v?v(null):{}},D8=function(U){return this.has(U)&&delete this.__data__[U]},S8=function(U){var Z=this.__data__;if(v){var $=Z[U];return $===sZ?void 0:$}return bU.call(Z,U)?Z[U]:void 0},V8=function(U){var Z=this.__data__;return v?Z[U]!==void 0:bU.call(Z,U)},I8=function(U,Z){var $=this.__data__;return $[U]=v&&Z===void 0?sZ:Z,this},k=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},x8=function(){this.__data__=[]},A8=function(U){var Z=this.__data__,$=FU(Z,U);if($<0)return!1;var Q=Z.length-1;if($==Q)Z.pop();else H8.call(Z,$,1);return!0},C8=function(U){var Z=this.__data__,$=FU(Z,U);return $<0?void 0:Z[$][1]},f8=function(U){return FU(this.__data__,U)>-1},T8=function(U,Z){var $=this.__data__,Q=FU($,U);if(Q<0)$.push([U,Z]);else $[Q][1]=Z;return this},T=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var Q=U[Z];this.set(Q[0],Q[1])}},m8=function(){this.__data__={hash:new f,map:new(M8||k),string:new f}},d8=function(U){return NU(this,U).delete(U)},p8=function(U){return NU(this,U).get(U)},g8=function(U){return NU(this,U).has(U)},j8=function(U,Z){return NU(this,U).set(U,Z),this},FU=function(U,Z){var $=U.length;while($--)if(l8(U[$][0],Z))return $;return-1},n8=function(U,Z){Z=b8(Z,U)?[Z]:h8(Z);var $=0,Q=Z.length;while(U!=null&&$<Q)U=U[u8(Z[$++])];return $&&$==Q?U:void 0},k8=function(U){if(!U$(U)||i8(U))return!1;var Z=o8(U)||P8(U)?O8:w8;return Z.test(s8(U))},y8=function(U){if(typeof U=="string")return U;if(iU(U))return uZ?uZ.call(U):"";var Z=U+"";return Z=="0"&&1/U==-lZ?"-0":Z},h8=function(U){return eZ(U)?U:c8(U)},NU=function(U,Z){var $=U.__data__;return v8(Z)?$[typeof Z=="string"?"string":"hash"]:$.map},aZ=function(U,Z){var $=N8(U,Z);return k8($)?$:void 0},b8=function(U,Z){if(eZ(U))return!1;var $=typeof U;if($=="number"||$=="symbol"||$=="boolean"||U==null||iU(U))return!0;return Y8.test(U)||!X8.test(U)||Z!=null&&U in Object(Z)},v8=function(U){var Z=typeof U;return Z=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?U!=="__proto__":U===null},i8=function(U){return!!vZ&&vZ in U},u8=function(U){if(typeof U=="string"||iU(U))return U;var Z=U+"";return Z=="0"&&1/U==-lZ?"-0":Z},s8=function(U){if(U!=null){try{return rZ.call(U)}catch(Z){}try{return U+""}catch(Z){}}return""},vU=function(U,Z){if(typeof U!="function"||Z&&typeof Z!="function")throw new TypeError(Q8);var $=function(){var Q=arguments,R=Z?Z.apply(this,Q):Q[0],J=$.cache;if(J.has(R))return J.get(R);var B=U.apply(this,Q);return $.cache=J.set(R,B),B};return $.cache=new(vU.Cache||T),$},l8=function(U,Z){return U===Z||U!==U&&Z!==Z},o8=function(U){var Z=U$(U)?tZ.call(U):"";return Z==R8||Z==J8},U$=function(U){var Z=typeof U;return!!U&&(Z=="object"||Z=="function")},r8=function(U){return!!U&&typeof U=="object"},iU=function(U){return typeof U=="symbol"||r8(U)&&tZ.call(U)==B8},t8=function(U){return U==null?"":y8(U)},a8=function(U,Z,$){var Q=U==null?void 0:n8(U,Z);return Q===void 0?$:Q},Q8="Expected a function",sZ="__lodash_hash_undefined__",lZ=Infinity,R8="[object Function]",J8="[object GeneratorFunction]",B8="[object Symbol]",X8=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Y8=/^\w*$/,W8=/^\./,K8=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,_8=/[\\^$.*+?()[\]{}|]/g,G8=/\\(\\)?/g,w8=/^\[object .+?Constructor\]$/,q8=typeof global=="object"&&global&&global.Object===Object&&global,F8=typeof self=="object"&&self&&self.Object===Object&&self,hU=q8||F8||Function("return this")(),E8=Array.prototype,L8=Function.prototype,oZ=Object.prototype,yU=hU["__core-js_shared__"],vZ=function(){var U=/[^.]+$/.exec(yU&&yU.keys&&yU.keys.IE_PROTO||"");return U?"Symbol(src)_1."+U:""}(),rZ=L8.toString,bU=oZ.hasOwnProperty,tZ=oZ.toString,O8=RegExp("^"+rZ.call(bU).replace(_8,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),iZ=hU.Symbol,H8=E8.splice,M8=aZ(hU,"Map"),v=aZ(Object,"create"),cZ=iZ?iZ.prototype:void 0,uZ=cZ?cZ.toString:void 0;f.prototype.clear=z8;f.prototype.delete=D8;f.prototype.get=S8;f.prototype.has=V8;f.prototype.set=I8;k.prototype.clear=x8;k.prototype.delete=A8;k.prototype.get=C8;k.prototype.has=f8;k.prototype.set=T8;T.prototype.clear=m8;T.prototype.delete=d8;T.prototype.get=p8;T.prototype.has=g8;T.prototype.set=j8;var c8=vU(function(U){U=t8(U);var Z=[];if(W8.test(U))Z.push("");return U.replace(K8,function($,Q,R,J){Z.push(R?J.replace(G8,"$1"):Q||$)}),Z});vU.Cache=T;var eZ=Array.isArray;Z$.exports=a8});var XZ=PU(BZ(),1),r={isNamespace:(U)=>U&&!U.type,flattenSchema(U,Z){return Object.entries(U).reduce(($,[Q,R])=>{const J=Z?`${Z}.${Q}`:Q;if(r.isNamespace(R))$={...$,...r.flattenSchema(R,J)};else Object.assign(R,{name:J}),$[R.uid]=R;return $},{})},wrapSchema(U){return Object.values(U).reduce((Z,$)=>{return XZ.default(Z,$.path,$),Z},{})}};var t,XQ=new Uint8Array(16);function zU(){if(!t){if(t=typeof crypto!=="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!t)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported")}return t(XQ)}function YZ(U,Z=0){return w[U[Z+0]]+w[U[Z+1]]+w[U[Z+2]]+w[U[Z+3]]+"-"+w[U[Z+4]]+w[U[Z+5]]+"-"+w[U[Z+6]]+w[U[Z+7]]+"-"+w[U[Z+8]]+w[U[Z+9]]+"-"+w[U[Z+10]]+w[U[Z+11]]+w[U[Z+12]]+w[U[Z+13]]+w[U[Z+14]]+w[U[Z+15]]}var w=[];for(let U=0;U<256;++U)w.push((U+256).toString(16).slice(1));var YQ=typeof crypto!=="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),DU={randomUUID:YQ};var WQ=function(U,Z,$){if(DU.randomUUID&&!Z&&!U)return DU.randomUUID();U=U||{};const Q=U.random||(U.rng||zU)();if(Q[6]=Q[6]&15|64,Q[8]=Q[8]&63|128,Z){$=$||0;for(let R=0;R<16;++R)Z[$+R]=Q[R];return Z}return YZ(Q)},a=WQ;var bZ=PU(hZ(),1);class $8{schemas;falttenSchema;uidSchemas;static Var(U){return{...U,type:"var",uid:a()}}static Func(U){return{...U,type:"func",uid:a()}}constructor(U={}){Object.assign(this,U),this.falttenSchema=r.flattenSchema(this.schemas),this.uidSchemas=bZ.default(this.schemas,"uid")}loadFull(){return Object.entries(this.falttenSchema).map(([U,Z])=>{if(Z.type=="func"){const{uid:$,type:Q,input:R,name:J,uiConfig:B}=Z;return{uid:$,type:Q,name:J,input:R,uiConfig:B?B():null}}if(Z.type=="var"){const{uid:$,type:Q,get:R,set:J,name:B,uiConfig:X}=Z;return{uid:$,type:Q,name:B,value:R(),uiConfig:X?X():null,set:!!J}}return{type:"unknown",name:U}})}loadVars(){return Object.entries(this.falttenSchema).filter(([U,Z])=>Z.type=="var").map(([U,Z])=>{const{get:$,name:Q}=Z;return{name:Q,value:$()}})}}var Q$=PU($$(),1),N1=(U)=>{return{schema:{async loadFull(){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"schema.loadFull"})}).then((Z)=>Z.json())},async loadVars(){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"schema.loadVars"})}).then((Z)=>Z.json())}},func:{async call(Z){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"func.call",params:Z})}).then(($)=>$.json())}},var:{async set(Z){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"var.set",params:Z})}).then(($)=>$.json())},async patch(Z){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"var.patch",params:Z})}).then(($)=>$.json())}}}},P1=({urpc:U})=>{const Z={urpc:U,handle({name:$,params:Q}){const R=Q$.default(Z,$);if(!R)throw new Error("invalid name");return R(Q)},schema:{async loadFull(){return U.loadFull()},async loadVars(){return U.loadVars()}},func:{async call($){const Q=U.uidSchemas[$.method]||U.falttenSchema[$.method];if(!Q)throw new Error("invalid func name");return Q.func({input:$.input})}},var:{async set($){const Q=U.uidSchemas[$.name]||U.falttenSchema[$.name];if(!Q)throw new Error("invalid var name");if(!Q.set)throw new Error("variable can't be set");return Q.set($.value)},async patch($){throw new Error("TBD")}}};return Z};export{r as utils,N1 as createSimpleHttpClient,P1 as createServerClient,$8 as URPC}; | ||
var Q$=Object.create;var{defineProperty:uU,getPrototypeOf:J$,getOwnPropertyNames:B$}=Object;var X$=Object.prototype.hasOwnProperty;var NU=(U,Z,$)=>{$=U!=null?Q$(J$(U)):{};const R=Z||!U||!U.__esModule?uU($,"default",{value:U,enumerable:!0}):$;for(let Q of B$(U))if(!X$.call(R,Q))uU(R,Q,{get:()=>U[Q],enumerable:!0});return R};var EU=(U,Z)=>()=>(Z||U((Z={exports:{}}).exports,Z),Z.exports);var BZ=EU((U1,JZ)=>{var z$=function(U,Z){return U==null?void 0:U[Z]},D$=function(U){var Z=!1;if(U!=null&&typeof U.toString!="function")try{Z=!!(U+"")}catch($){}return Z},I=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},A$=function(){this.__data__=y?y(null):{}},T$=function(U){return this.has(U)&&delete this.__data__[U]},f$=function(U){var Z=this.__data__;if(y){var $=Z[U];return $===tU?void 0:$}return s.call(Z,U)?Z[U]:void 0},m$=function(U){var Z=this.__data__;return y?Z[U]!==void 0:s.call(Z,U)},d$=function(U,Z){var $=this.__data__;return $[U]=y&&Z===void 0?tU:Z,this},m=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},p$=function(){this.__data__=[]},g$=function(U){var Z=this.__data__,$=l(Z,U);if($<0)return!1;var R=Z.length-1;if($==R)Z.pop();else x$.call(Z,$,1);return!0},j$=function(U){var Z=this.__data__,$=l(Z,U);return $<0?void 0:Z[$][1]},n$=function(U){return l(this.__data__,U)>-1},k$=function(U,Z){var $=this.__data__,R=l($,U);if(R<0)$.push([U,Z]);else $[R][1]=Z;return this},x=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},y$=function(){this.__data__={hash:new I,map:new(C$||m),string:new I}},h$=function(U){return o(this,U).delete(U)},b$=function(U){return o(this,U).get(U)},i$=function(U){return o(this,U).has(U)},v$=function(U,Z){return o(this,U).set(U,Z),this},c$=function(U,Z,$){var R=U[Z];if(!(s.call(U,Z)&&RZ(R,$))||$===void 0&&!(Z in U))U[Z]=$},l=function(U,Z){var $=U.length;while($--)if(RZ(U[$][0],Z))return $;return-1},u$=function(U){if(!u(U)||e$(U))return!1;var Z=RR(U)||D$(U)?I$:L$;return Z.test($R(U))},s$=function(U,Z,$,R){if(!u(U))return U;Z=t$(Z,U)?[Z]:o$(Z);var Q=-1,J=Z.length,B=J-1,X=U;while(X!=null&&++Q<J){var Y=ZR(Z[Q]),K=$;if(Q!=B){var _=X[Y];if(K=R?R(_,Y,X):void 0,K===void 0)K=u(_)?_:r$(Z[Q+1])?[]:{}}c$(X,Y,K),X=X[Y]}return U},l$=function(U){if(typeof U=="string")return U;if(MU(U))return rU?rU.call(U):"";var Z=U+"";return Z=="0"&&1/U==-aU?"-0":Z},o$=function(U){return QZ(U)?U:UR(U)},o=function(U,Z){var $=U.__data__;return a$(Z)?$[typeof Z=="string"?"string":"hash"]:$.map},$Z=function(U,Z){var $=z$(U,Z);return u$($)?$:void 0},r$=function(U,Z){return Z=Z==null?W$:Z,!!Z&&(typeof U=="number"||O$.test(U))&&(U>-1&&U%1==0&&U<Z)},t$=function(U,Z){if(QZ(U))return!1;var $=typeof U;if($=="number"||$=="symbol"||$=="boolean"||U==null||MU(U))return!0;return q$.test(U)||!G$.test(U)||Z!=null&&U in Object(Z)},a$=function(U){var Z=typeof U;return Z=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?U!=="__proto__":U===null},e$=function(U){return!!sU&&sU in U},ZR=function(U){if(typeof U=="string"||MU(U))return U;var Z=U+"";return Z=="0"&&1/U==-aU?"-0":Z},$R=function(U){if(U!=null){try{return UZ.call(U)}catch(Z){}try{return U+""}catch(Z){}}return""},HU=function(U,Z){if(typeof U!="function"||Z&&typeof Z!="function")throw new TypeError(Y$);var $=function(){var R=arguments,Q=Z?Z.apply(this,R):R[0],J=$.cache;if(J.has(Q))return J.get(Q);var B=U.apply(this,R);return $.cache=J.set(Q,B),B};return $.cache=new(HU.Cache||x),$},RZ=function(U,Z){return U===Z||U!==U&&Z!==Z},RR=function(U){var Z=u(U)?ZZ.call(U):"";return Z==K$||Z==_$},u=function(U){var Z=typeof U;return!!U&&(Z=="object"||Z=="function")},QR=function(U){return!!U&&typeof U=="object"},MU=function(U){return typeof U=="symbol"||QR(U)&&ZZ.call(U)==w$},JR=function(U){return U==null?"":l$(U)},BR=function(U,Z,$){return U==null?U:s$(U,Z,$)},Y$="Expected a function",tU="__lodash_hash_undefined__",aU=Infinity,W$=9007199254740991,K$="[object Function]",_$="[object GeneratorFunction]",w$="[object Symbol]",G$=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,q$=/^\w*$/,F$=/^\./,P$=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,N$=/[\\^$.*+?()[\]{}|]/g,E$=/\\(\\)?/g,L$=/^\[object .+?Constructor\]$/,O$=/^(?:0|[1-9]\d*)$/,H$=typeof global=="object"&&global&&global.Object===Object&&global,M$=typeof self=="object"&&self&&self.Object===Object&&self,OU=H$||M$||Function("return this")(),S$=Array.prototype,V$=Function.prototype,eU=Object.prototype,LU=OU["__core-js_shared__"],sU=function(){var U=/[^.]+$/.exec(LU&&LU.keys&&LU.keys.IE_PROTO||"");return U?"Symbol(src)_1."+U:""}(),UZ=V$.toString,s=eU.hasOwnProperty,ZZ=eU.toString,I$=RegExp("^"+UZ.call(s).replace(N$,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),lU=OU.Symbol,x$=S$.splice,C$=$Z(OU,"Map"),y=$Z(Object,"create"),oU=lU?lU.prototype:void 0,rU=oU?oU.toString:void 0;I.prototype.clear=A$;I.prototype.delete=T$;I.prototype.get=f$;I.prototype.has=m$;I.prototype.set=d$;m.prototype.clear=p$;m.prototype.delete=g$;m.prototype.get=j$;m.prototype.has=n$;m.prototype.set=k$;x.prototype.clear=y$;x.prototype.delete=h$;x.prototype.get=b$;x.prototype.has=i$;x.prototype.set=v$;var UR=HU(function(U){U=JR(U);var Z=[];if(F$.test(U))Z.push("");return U.replace(P$,function($,R,Q,J){Z.push(Q?J.replace(E$,"$1"):R||$)}),Z});HU.Cache=x;var QZ=Array.isArray;JZ.exports=BR});var hZ=EU((e,p)=>{var fR=function(U,Z,$,R){var Q=-1,J=U?U.length:0;while(++Q<J){var B=U[Q];Z(R,B,$(B),U)}return R},mR=function(U,Z){var $=-1,R=U?U.length:0;while(++$<R)if(Z(U[$],$,U))return!0;return!1},dR=function(U){return function(Z){return Z==null?void 0:Z[U]}},pR=function(U,Z){var $=-1,R=Array(U);while(++$<U)R[$]=Z($);return R},gR=function(U){return function(Z){return U(Z)}},jR=function(U,Z){return U==null?void 0:U[Z]},CU=function(U){var Z=!1;if(U!=null&&typeof U.toString!="function")try{Z=!!(U+"")}catch($){}return Z},nR=function(U){var Z=-1,$=Array(U.size);return U.forEach(function(R,Q){$[++Z]=[Q,R]}),$},kR=function(U,Z){return function($){return U(Z($))}},yR=function(U){var Z=-1,$=Array(U.size);return U.forEach(function(R){$[++Z]=R}),$},C=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},aR=function(){this.__data__=b?b(null):{}},eR=function(U){return this.has(U)&&delete this.__data__[U]},UQ=function(U){var Z=this.__data__;if(b){var $=Z[U];return $===dU?void 0:$}return L.call(Z,U)?Z[U]:void 0},ZQ=function(U){var Z=this.__data__;return b?Z[U]!==void 0:L.call(Z,U)},$Q=function(U,Z){var $=this.__data__;return $[U]=b&&Z===void 0?dU:Z,this},O=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},RQ=function(){this.__data__=[]},QQ=function(U){var Z=this.__data__,$=WU(Z,U);if($<0)return!1;var R=Z.length-1;if($==R)Z.pop();else cR.call(Z,$,1);return!0},JQ=function(U){var Z=this.__data__,$=WU(Z,U);return $<0?void 0:Z[$][1]},BQ=function(U){return WU(this.__data__,U)>-1},XQ=function(U,Z){var $=this.__data__,R=WU($,U);if(R<0)$.push([U,Z]);else $[R][1]=Z;return this},H=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},YQ=function(){this.__data__={hash:new C,map:new(h||O),string:new C}},WQ=function(U){return KU(this,U).delete(U)},KQ=function(U){return KU(this,U).get(U)},_Q=function(U){return KU(this,U).has(U)},wQ=function(U,Z){return KU(this,U).set(U,Z),this},JU=function(U){var Z=-1,$=U?U.length:0;this.__data__=new H;while(++Z<$)this.add(U[Z])},GQ=function(U){return this.__data__.set(U,dU),this},qQ=function(U){return this.__data__.has(U)},E=function(U){this.__data__=new O(U)},FQ=function(){this.__data__=new O},PQ=function(U){return this.__data__.delete(U)},NQ=function(U){return this.__data__.get(U)},EQ=function(U){return this.__data__.has(U)},LQ=function(U,Z){var $=this.__data__;if($ instanceof O){var R=$.__data__;if(!h||R.length<KR-1)return R.push([U,Z]),this;$=this.__data__=new H(R)}return $.set(U,Z),this},OQ=function(U,Z){var $=D(U)||kZ(U)?pR(U.length,String):[],R=$.length,Q=!!R;for(var J in U)if((Z||L.call(U,J))&&!(Q&&(J=="length"||pZ(J,R))))$.push(J);return $},WU=function(U,Z){var $=U.length;while($--)if(nZ(U[$][0],Z))return $;return-1},HQ=function(U,Z,$,R){return MQ(U,function(Q,J,B){Z(R,Q,$(Q),B)}),R},DQ=function(U,Z){return U&&zQ(U,Z,BU)},fZ=function(U,Z){Z=_U(Z,U)?[Z]:mZ(Z);var $=0,R=Z.length;while(U!=null&&$<R)U=U[wU(Z[$++])];return $&&$==R?U:void 0},SQ=function(U){return j.call(U)},VQ=function(U,Z){return U!=null&&Z in Object(U)},pU=function(U,Z,$,R,Q){if(U===Z)return!0;if(U==null||Z==null||!GU(U)&&!qU(Z))return U!==U&&Z!==Z;return IQ(U,Z,pU,$,R,Q)},IQ=function(U,Z,$,R,Q,J){var B=D(U),X=D(Z),Y=IU,K=IU;if(!B)Y=z(U),Y=Y==UU?d:Y;if(!X)K=z(Z),K=K==UU?d:K;var _=Y==d&&!CU(U),q=K==d&&!CU(Z),w=Y==K;if(w&&!_)return J||(J=new E),B||rQ(U)?dZ(U,Z,$,R,Q,J):yQ(U,Z,Y,$,R,Q,J);if(!(Q&g)){var F=_&&L.call(U,"__wrapped__"),P=q&&L.call(Z,"__wrapped__");if(F||P){var M=F?U.value():U,N=P?Z.value():Z;return J||(J=new E),$(M,N,R,Q,J)}}if(!w)return!1;return J||(J=new E),hQ(U,Z,$,R,Q,J)},xQ=function(U,Z,$,R){var Q=$.length,J=Q,B=!R;if(U==null)return!J;U=Object(U);while(Q--){var X=$[Q];if(B&&X[2]?X[1]!==U[X[0]]:!(X[0]in U))return!1}while(++Q<J){X=$[Q];var Y=X[0],K=U[Y],_=X[1];if(B&&X[2]){if(K===void 0&&!(Y in U))return!1}else{var q=new E;if(R)var w=R(K,_,Y,U,Z,q);if(!(w===void 0?pU(_,K,R,XU|g,q):w))return!1}}return!0},CQ=function(U){if(!GU(U)||cQ(U))return!1;var Z=yZ(U)||CU(U)?iR:xR;return Z.test(A(U))},AQ=function(U){return qU(U)&&nU(U.length)&&!!W[j.call(U)]},TQ=function(U){if(typeof U=="function")return U;if(U==null)return U8;if(typeof U=="object")return D(U)?dQ(U[0],U[1]):mQ(U);return Z8(U)},fQ=function(U){if(!uQ(U))return uR(U);var Z=[];for(var $ in Object(U))if(L.call(U,$)&&$!="constructor")Z.push($);return Z},mQ=function(U){var Z=bQ(U);if(Z.length==1&&Z[0][2])return jZ(Z[0][0],Z[0][1]);return function($){return $===U||xQ($,U,Z)}},dQ=function(U,Z){if(_U(U)&&gZ(Z))return jZ(wU(U),Z);return function($){var R=aQ($,U);return R===void 0&&R===Z?eQ($,U):pU(Z,R,void 0,XU|g)}},pQ=function(U){return function(Z){return fZ(Z,U)}},gQ=function(U){if(typeof U=="string")return U;if(kU(U))return NZ?NZ.call(U):"";var Z=U+"";return Z=="0"&&1/U==-EZ?"-0":Z},mZ=function(U){return D(U)?U:sQ(U)},jQ=function(U,Z){return function($,R){var Q=D($)?fR:HQ,J=Z?Z():{};return Q($,U,TQ(R,2),J)}},nQ=function(U,Z){return function($,R){if($==null)return $;if(!jU($))return U($,R);var Q=$.length,J=Z?Q:-1,B=Object($);while(Z?J--:++J<Q)if(R(B[J],J,B)===!1)break;return $}},kQ=function(U){return function(Z,$,R){var Q=-1,J=Object(Z),B=R(Z),X=B.length;while(X--){var Y=B[U?X:++Q];if($(J[Y],Y,J)===!1)break}return Z}},dZ=function(U,Z,$,R,Q,J){var B=Q&g,X=U.length,Y=Z.length;if(X!=Y&&!(B&&Y>X))return!1;var K=J.get(U);if(K&&J.get(Z))return K==Z;var _=-1,q=!0,w=Q&XU?new JU:void 0;J.set(U,Z),J.set(Z,U);while(++_<X){var F=U[_],P=Z[_];if(R)var M=B?R(P,F,_,Z,U,J):R(F,P,_,U,Z,J);if(M!==void 0){if(M)continue;q=!1;break}if(w){if(!mR(Z,function(N,V){if(!w.has(V)&&(F===N||$(F,N,R,Q,J)))return w.add(V)})){q=!1;break}}else if(!(F===P||$(F,P,R,Q,J))){q=!1;break}}return J.delete(U),J.delete(Z),q},yQ=function(U,Z,$,R,Q,J,B){switch($){case RU:if(U.byteLength!=Z.byteLength||U.byteOffset!=Z.byteOffset)return!1;U=U.buffer,Z=Z.buffer;case xZ:if(U.byteLength!=Z.byteLength||!R(new PZ(U),new PZ(Z)))return!1;return!0;case OZ:case HZ:case DZ:return nZ(+U,+Z);case MZ:return U.name==Z.name&&U.message==Z.message;case SZ:case VZ:return U==Z+"";case ZU:var X=nR;case $U:var Y=J&g;if(X||(X=yR),U.size!=Z.size&&!Y)return!1;var K=B.get(U);if(K)return K==Z;J|=XU,B.set(U,Z);var _=dZ(X(U),X(Z),R,Q,J,B);return B.delete(U),_;case IZ:if(VU)return VU.call(U)==VU.call(Z)}return!1},hQ=function(U,Z,$,R,Q,J){var B=Q&g,X=BU(U),Y=X.length,K=BU(Z),_=K.length;if(Y!=_&&!B)return!1;var q=Y;while(q--){var w=X[q];if(!(B?w in Z:L.call(Z,w)))return!1}var F=J.get(U);if(F&&J.get(Z))return F==Z;var P=!0;J.set(U,Z),J.set(Z,U);var M=B;while(++q<Y){w=X[q];var N=U[w],V=Z[w];if(R)var cU=B?R(V,N,w,Z,U,J):R(N,V,w,U,Z,J);if(!(cU===void 0?N===V||$(N,V,R,Q,J):cU)){P=!1;break}M||(M=w=="constructor")}if(P&&!M){var v=U.constructor,c=Z.constructor;if(v!=c&&(("constructor"in U)&&("constructor"in Z))&&!(typeof v=="function"&&v instanceof v&&typeof c=="function"&&c instanceof c))P=!1}return J.delete(U),J.delete(Z),P},KU=function(U,Z){var $=U.__data__;return vQ(Z)?$[typeof Z=="string"?"string":"hash"]:$.map},bQ=function(U){var Z=BU(U),$=Z.length;while($--){var R=Z[$],Q=U[R];Z[$]=[R,Q,gZ(Q)]}return Z},n=function(U,Z){var $=jR(U,Z);return CQ($)?$:void 0},iQ=function(U,Z,$){Z=_U(Z,U)?[Z]:mZ(Z);var R,Q=-1,B=Z.length;while(++Q<B){var J=wU(Z[Q]);if(!(R=U!=null&&$(U,J)))break;U=U[J]}if(R)return R;var B=U?U.length:0;return!!B&&nU(B)&&pZ(J,B)&&(D(U)||kZ(U))},pZ=function(U,Z){return Z=Z==null?LZ:Z,!!Z&&(typeof U=="number"||CR.test(U))&&(U>-1&&U%1==0&&U<Z)},_U=function(U,Z){if(D(U))return!1;var $=typeof U;if($=="number"||$=="symbol"||$=="boolean"||U==null||kU(U))return!0;return zR.test(U)||!MR.test(U)||Z!=null&&U in Object(Z)},vQ=function(U){var Z=typeof U;return Z=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?U!=="__proto__":U===null},cQ=function(U){return!!qZ&&qZ in U},uQ=function(U){var Z=U&&U.constructor,$=typeof Z=="function"&&Z.prototype||YU;return U===$},gZ=function(U){return U===U&&!GU(U)},jZ=function(U,Z){return function($){if($==null)return!1;return $[U]===Z&&(Z!==void 0||(U in Object($)))}},wU=function(U){if(typeof U=="string"||kU(U))return U;var Z=U+"";return Z=="0"&&1/U==-EZ?"-0":Z},A=function(U){if(U!=null){try{return TZ.call(U)}catch(Z){}try{return U+""}catch(Z){}}return""},gU=function(U,Z){if(typeof U!="function"||Z&&typeof Z!="function")throw new TypeError(_R);var $=function(){var R=arguments,Q=Z?Z.apply(this,R):R[0],J=$.cache;if(J.has(Q))return J.get(Q);var B=U.apply(this,R);return $.cache=J.set(Q,B),B};return $.cache=new(gU.Cache||H),$},nZ=function(U,Z){return U===Z||U!==U&&Z!==Z},kZ=function(U){return oQ(U)&&L.call(U,"callee")&&(!vR.call(U,"callee")||j.call(U)==UU)},jU=function(U){return U!=null&&nU(U.length)&&!yZ(U)},oQ=function(U){return qU(U)&&jU(U)},yZ=function(U){var Z=GU(U)?j.call(U):"";return Z==zZ||Z==wR},nU=function(U){return typeof U=="number"&&U>-1&&U%1==0&&U<=LZ},GU=function(U){var Z=typeof U;return!!U&&(Z=="object"||Z=="function")},qU=function(U){return!!U&&typeof U=="object"},kU=function(U){return typeof U=="symbol"||qU(U)&&j.call(U)==IZ},tQ=function(U){return U==null?"":gQ(U)},aQ=function(U,Z,$){var R=U==null?void 0:fZ(U,Z);return R===void 0?$:R},eQ=function(U,Z){return U!=null&&iQ(U,Z,VQ)},BU=function(U){return jU(U)?OQ(U):fQ(U)},U8=function(U){return U},Z8=function(U){return _U(U)?dR(wU(U)):pQ(U)},KR=200,_R="Expected a function",dU="__lodash_hash_undefined__",XU=1,g=2,EZ=Infinity,LZ=9007199254740991,UU="[object Arguments]",IU="[object Array]",OZ="[object Boolean]",HZ="[object Date]",MZ="[object Error]",zZ="[object Function]",wR="[object GeneratorFunction]",ZU="[object Map]",DZ="[object Number]",d="[object Object]",WZ="[object Promise]",SZ="[object RegExp]",$U="[object Set]",VZ="[object String]",IZ="[object Symbol]",xU="[object WeakMap]",xZ="[object ArrayBuffer]",RU="[object DataView]",GR="[object Float32Array]",qR="[object Float64Array]",FR="[object Int8Array]",PR="[object Int16Array]",NR="[object Int32Array]",ER="[object Uint8Array]",LR="[object Uint8ClampedArray]",OR="[object Uint16Array]",HR="[object Uint32Array]",MR=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,zR=/^\w*$/,DR=/^\./,SR=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,VR=/[\\^$.*+?()[\]{}|]/g,IR=/\\(\\)?/g,xR=/^\[object .+?Constructor\]$/,CR=/^(?:0|[1-9]\d*)$/,W={};W[GR]=W[qR]=W[FR]=W[PR]=W[NR]=W[ER]=W[LR]=W[OR]=W[HR]=!0;W[UU]=W[IU]=W[xZ]=W[OZ]=W[RU]=W[HZ]=W[MZ]=W[zZ]=W[ZU]=W[DZ]=W[d]=W[SZ]=W[$U]=W[VZ]=W[xU]=!1;var CZ=typeof global=="object"&&global&&global.Object===Object&&global,AR=typeof self=="object"&&self&&self.Object===Object&&self,S=CZ||AR||Function("return this")(),AZ=typeof e=="object"&&e&&!e.nodeType&&e,KZ=AZ&&typeof p=="object"&&p&&!p.nodeType&&p,TR=KZ&&KZ.exports===AZ,_Z=TR&&CZ.process,wZ=function(){try{return _Z&&_Z.binding("util")}catch(U){}}(),GZ=wZ&&wZ.isTypedArray,hR=Array.prototype,bR=Function.prototype,YU=Object.prototype,SU=S["__core-js_shared__"],qZ=function(){var U=/[^.]+$/.exec(SU&&SU.keys&&SU.keys.IE_PROTO||"");return U?"Symbol(src)_1."+U:""}(),TZ=bR.toString,L=YU.hasOwnProperty,j=YU.toString,iR=RegExp("^"+TZ.call(L).replace(VR,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),FZ=S.Symbol,PZ=S.Uint8Array,vR=YU.propertyIsEnumerable,cR=hR.splice,uR=kR(Object.keys,Object),AU=n(S,"DataView"),h=n(S,"Map"),TU=n(S,"Promise"),fU=n(S,"Set"),mU=n(S,"WeakMap"),b=n(Object,"create"),sR=A(AU),lR=A(h),oR=A(TU),rR=A(fU),tR=A(mU),QU=FZ?FZ.prototype:void 0,VU=QU?QU.valueOf:void 0,NZ=QU?QU.toString:void 0;C.prototype.clear=aR;C.prototype.delete=eR;C.prototype.get=UQ;C.prototype.has=ZQ;C.prototype.set=$Q;O.prototype.clear=RQ;O.prototype.delete=QQ;O.prototype.get=JQ;O.prototype.has=BQ;O.prototype.set=XQ;H.prototype.clear=YQ;H.prototype.delete=WQ;H.prototype.get=KQ;H.prototype.has=_Q;H.prototype.set=wQ;JU.prototype.add=JU.prototype.push=GQ;JU.prototype.has=qQ;E.prototype.clear=FQ;E.prototype.delete=PQ;E.prototype.get=NQ;E.prototype.has=EQ;E.prototype.set=LQ;var MQ=nQ(DQ),zQ=kQ(),z=SQ;if(AU&&z(new AU(new ArrayBuffer(1)))!=RU||h&&z(new h)!=ZU||TU&&z(TU.resolve())!=WZ||fU&&z(new fU)!=$U||mU&&z(new mU)!=xU)z=function(U){var Z=j.call(U),$=Z==d?U.constructor:void 0,R=$?A($):void 0;if(R)switch(R){case sR:return RU;case lR:return ZU;case oR:return WZ;case rR:return $U;case tR:return xU}return Z};var sQ=gU(function(U){U=tQ(U);var Z=[];if(DR.test(U))Z.push("");return U.replace(SR,function($,R,Q,J){Z.push(Q?J.replace(IR,"$1"):R||$)}),Z}),lQ=jQ(function(U,Z,$){U[$]=Z});gU.Cache=H;var D=Array.isArray,rQ=GZ?gR(GZ):AQ;p.exports=lQ});var $$=EU((F1,Z$)=>{var P8=function(U,Z){return U==null?void 0:U[Z]},N8=function(U){var Z=!1;if(U!=null&&typeof U.toString!="function")try{Z=!!(U+"")}catch($){}return Z},T=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},z8=function(){this.__data__=i?i(null):{}},D8=function(U){return this.has(U)&&delete this.__data__[U]},S8=function(U){var Z=this.__data__;if(i){var $=Z[U];return $===sZ?void 0:$}return bU.call(Z,U)?Z[U]:void 0},V8=function(U){var Z=this.__data__;return i?Z[U]!==void 0:bU.call(Z,U)},I8=function(U,Z){var $=this.__data__;return $[U]=i&&Z===void 0?sZ:Z,this},k=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},x8=function(){this.__data__=[]},C8=function(U){var Z=this.__data__,$=FU(Z,U);if($<0)return!1;var R=Z.length-1;if($==R)Z.pop();else H8.call(Z,$,1);return!0},A8=function(U){var Z=this.__data__,$=FU(Z,U);return $<0?void 0:Z[$][1]},T8=function(U){return FU(this.__data__,U)>-1},f8=function(U,Z){var $=this.__data__,R=FU($,U);if(R<0)$.push([U,Z]);else $[R][1]=Z;return this},f=function(U){var Z=-1,$=U?U.length:0;this.clear();while(++Z<$){var R=U[Z];this.set(R[0],R[1])}},m8=function(){this.__data__={hash:new T,map:new(M8||k),string:new T}},d8=function(U){return PU(this,U).delete(U)},p8=function(U){return PU(this,U).get(U)},g8=function(U){return PU(this,U).has(U)},j8=function(U,Z){return PU(this,U).set(U,Z),this},FU=function(U,Z){var $=U.length;while($--)if(l8(U[$][0],Z))return $;return-1},n8=function(U,Z){Z=b8(Z,U)?[Z]:h8(Z);var $=0,R=Z.length;while(U!=null&&$<R)U=U[u8(Z[$++])];return $&&$==R?U:void 0},k8=function(U){if(!U$(U)||v8(U))return!1;var Z=o8(U)||N8(U)?O8:G8;return Z.test(s8(U))},y8=function(U){if(typeof U=="string")return U;if(vU(U))return uZ?uZ.call(U):"";var Z=U+"";return Z=="0"&&1/U==-lZ?"-0":Z},h8=function(U){return eZ(U)?U:c8(U)},PU=function(U,Z){var $=U.__data__;return i8(Z)?$[typeof Z=="string"?"string":"hash"]:$.map},aZ=function(U,Z){var $=P8(U,Z);return k8($)?$:void 0},b8=function(U,Z){if(eZ(U))return!1;var $=typeof U;if($=="number"||$=="symbol"||$=="boolean"||U==null||vU(U))return!0;return Y8.test(U)||!X8.test(U)||Z!=null&&U in Object(Z)},i8=function(U){var Z=typeof U;return Z=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?U!=="__proto__":U===null},v8=function(U){return!!iZ&&iZ in U},u8=function(U){if(typeof U=="string"||vU(U))return U;var Z=U+"";return Z=="0"&&1/U==-lZ?"-0":Z},s8=function(U){if(U!=null){try{return rZ.call(U)}catch(Z){}try{return U+""}catch(Z){}}return""},iU=function(U,Z){if(typeof U!="function"||Z&&typeof Z!="function")throw new TypeError(R8);var $=function(){var R=arguments,Q=Z?Z.apply(this,R):R[0],J=$.cache;if(J.has(Q))return J.get(Q);var B=U.apply(this,R);return $.cache=J.set(Q,B),B};return $.cache=new(iU.Cache||f),$},l8=function(U,Z){return U===Z||U!==U&&Z!==Z},o8=function(U){var Z=U$(U)?tZ.call(U):"";return Z==Q8||Z==J8},U$=function(U){var Z=typeof U;return!!U&&(Z=="object"||Z=="function")},r8=function(U){return!!U&&typeof U=="object"},vU=function(U){return typeof U=="symbol"||r8(U)&&tZ.call(U)==B8},t8=function(U){return U==null?"":y8(U)},a8=function(U,Z,$){var R=U==null?void 0:n8(U,Z);return R===void 0?$:R},R8="Expected a function",sZ="__lodash_hash_undefined__",lZ=Infinity,Q8="[object Function]",J8="[object GeneratorFunction]",B8="[object Symbol]",X8=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Y8=/^\w*$/,W8=/^\./,K8=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,_8=/[\\^$.*+?()[\]{}|]/g,w8=/\\(\\)?/g,G8=/^\[object .+?Constructor\]$/,q8=typeof global=="object"&&global&&global.Object===Object&&global,F8=typeof self=="object"&&self&&self.Object===Object&&self,hU=q8||F8||Function("return this")(),E8=Array.prototype,L8=Function.prototype,oZ=Object.prototype,yU=hU["__core-js_shared__"],iZ=function(){var U=/[^.]+$/.exec(yU&&yU.keys&&yU.keys.IE_PROTO||"");return U?"Symbol(src)_1."+U:""}(),rZ=L8.toString,bU=oZ.hasOwnProperty,tZ=oZ.toString,O8=RegExp("^"+rZ.call(bU).replace(_8,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),vZ=hU.Symbol,H8=E8.splice,M8=aZ(hU,"Map"),i=aZ(Object,"create"),cZ=vZ?vZ.prototype:void 0,uZ=cZ?cZ.toString:void 0;T.prototype.clear=z8;T.prototype.delete=D8;T.prototype.get=S8;T.prototype.has=V8;T.prototype.set=I8;k.prototype.clear=x8;k.prototype.delete=C8;k.prototype.get=A8;k.prototype.has=T8;k.prototype.set=f8;f.prototype.clear=m8;f.prototype.delete=d8;f.prototype.get=p8;f.prototype.has=g8;f.prototype.set=j8;var c8=iU(function(U){U=t8(U);var Z=[];if(W8.test(U))Z.push("");return U.replace(K8,function($,R,Q,J){Z.push(Q?J.replace(w8,"$1"):R||$)}),Z});iU.Cache=f;var eZ=Array.isArray;Z$.exports=a8});var XZ=NU(BZ(),1),r={isNamespace:(U)=>U&&!U.type,flattenSchema(U,Z){return Object.entries(U).reduce(($,[R,Q])=>{const J=Z?`${Z}.${R}`:R;if(r.isNamespace(Q))$={...$,...r.flattenSchema(Q,J)};else Object.assign(Q,{name:J}),$[Q.uid]=Q;return $},{})},wrapSchema(U){return Object.values(U).reduce((Z,$)=>{return XZ.default(Z,$.path,$),Z},{})}};var t,XR=new Uint8Array(16);function zU(){if(!t){if(t=typeof crypto!=="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!t)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported")}return t(XR)}function YZ(U,Z=0){return G[U[Z+0]]+G[U[Z+1]]+G[U[Z+2]]+G[U[Z+3]]+"-"+G[U[Z+4]]+G[U[Z+5]]+"-"+G[U[Z+6]]+G[U[Z+7]]+"-"+G[U[Z+8]]+G[U[Z+9]]+"-"+G[U[Z+10]]+G[U[Z+11]]+G[U[Z+12]]+G[U[Z+13]]+G[U[Z+14]]+G[U[Z+15]]}var G=[];for(let U=0;U<256;++U)G.push((U+256).toString(16).slice(1));var YR=typeof crypto!=="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),DU={randomUUID:YR};var WR=function(U,Z,$){if(DU.randomUUID&&!Z&&!U)return DU.randomUUID();U=U||{};const R=U.random||(U.rng||zU)();if(R[6]=R[6]&15|64,R[8]=R[8]&63|128,Z){$=$||0;for(let Q=0;Q<16;++Q)Z[$+Q]=R[Q];return Z}return YZ(R)},a=WR;var bZ=NU(hZ(),1);class $8{schemas;falttenSchema;uidSchemas;static Var(U){return{...U,type:"var",uid:a()}}static Func(U){return{...U,type:"func",uid:a()}}static UI={Table({actions:U}){return{"ui:widget":"Table","ui:options":{actions:U}}}};constructor(U={}){Object.assign(this,U),this.falttenSchema=r.flattenSchema(this.schemas),this.uidSchemas=bZ.default(this.schemas,"uid")}loadFull(){return Object.entries(this.falttenSchema).map(([U,Z])=>{if(Z.type=="func"){const{uid:$,type:R,input:Q,name:J,uiConfig:B}=Z;return{uid:$,type:R,name:J,input:Q,uiConfig:B?B():null}}if(Z.type=="var"){const{uid:$,type:R,get:Q,set:J,name:B,uiConfig:X}=Z;return{uid:$,type:R,name:B,value:Q(),uiConfig:X?X():null,set:!!J}}return{type:"unknown",name:U}})}loadVars(){return Object.entries(this.falttenSchema).filter(([U,Z])=>Z.type=="var").map(([U,Z])=>{const{get:$,name:R}=Z;return{name:R,value:$()}})}}var R$=NU($$(),1),P1=(U)=>{return{schema:{async loadFull(){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"schema.loadFull"})}).then((Z)=>Z.json())},async loadVars(){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"schema.loadVars"})}).then((Z)=>Z.json())}},func:{async call(Z){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"func.call",params:Z})}).then(($)=>$.json())}},var:{async set(Z){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"var.set",params:Z})}).then(($)=>$.json())},async patch(Z){return fetch(`${U.url}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:"var.patch",params:Z})}).then(($)=>$.json())}}}},N1=({urpc:U})=>{const Z={urpc:U,handle({name:$,params:R}){const Q=R$.default(Z,$);if(!Q)throw new Error("invalid name");return Q(R)},schema:{async loadFull(){return U.loadFull()},async loadVars(){return U.loadVars()}},func:{async call($){const R=U.uidSchemas[$.method]||U.falttenSchema[$.method];if(!R)throw new Error("invalid func name");return R.func({input:$.input})}},var:{async set($){const R=U.uidSchemas[$.name]||U.falttenSchema[$.name];if(!R)throw new Error("invalid var name");if(!R.set)throw new Error("variable can't be set");return R.set($.value)},async patch($){throw new Error("TBD")}}};return Z};export{r as utils,P1 as createSimpleHttpClient,N1 as createServerClient,$8 as URPC}; |
{ | ||
"name": "@dappworks/urpc", | ||
"version": "0.0.11", | ||
"version": "0.0.12", | ||
"module": "index.ts", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
32377
270