@sidesuit/pkg-module-proxy 1.1.2 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/global.d.ts +41 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1 -1
- package/dist/relayStoreFinderParents.d.ts +12 -0
- package/package.json +8 -8
package/dist/global.d.ts
CHANGED
|
@@ -8,6 +8,24 @@ import {
|
|
|
8
8
|
StoreFinderFunction,
|
|
9
9
|
} from "./types";
|
|
10
10
|
|
|
11
|
+
// RelayStoreFinder 相关类型定义
|
|
12
|
+
interface Source {
|
|
13
|
+
__id: string;
|
|
14
|
+
__typename: string;
|
|
15
|
+
[key: string]:
|
|
16
|
+
| string
|
|
17
|
+
| {
|
|
18
|
+
__ref: string;
|
|
19
|
+
}
|
|
20
|
+
| {
|
|
21
|
+
__refs: string[];
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
interface SearchConfig {
|
|
26
|
+
depth?: number;
|
|
27
|
+
}
|
|
28
|
+
|
|
11
29
|
export declare global {
|
|
12
30
|
interface Window {
|
|
13
31
|
// window.require
|
|
@@ -19,5 +37,28 @@ export declare global {
|
|
|
19
37
|
storeFinder: StoreFinderFunction;
|
|
20
38
|
moduleProxyImmediately: ModuleProxyImmediatelyFunction;
|
|
21
39
|
ajaxHijack: AjaxHijackFunction;
|
|
40
|
+
|
|
41
|
+
// RelayStoreFinder Parents 函数
|
|
42
|
+
storeFinderFindParentsSourcesByStoreId: (
|
|
43
|
+
storeId: string,
|
|
44
|
+
configs?: SearchConfig
|
|
45
|
+
) => Source[] | null;
|
|
46
|
+
|
|
47
|
+
storeFinderFindParentsTypenamesByStoreId: (
|
|
48
|
+
storeId: string,
|
|
49
|
+
configs?: SearchConfig
|
|
50
|
+
) => string[] | null;
|
|
51
|
+
|
|
52
|
+
storeFinderFindParentSourceByTypename: (
|
|
53
|
+
storeId: string,
|
|
54
|
+
__typename: string,
|
|
55
|
+
configs: SearchConfig
|
|
56
|
+
) => Source | null;
|
|
57
|
+
|
|
58
|
+
storeFinderFindParentByExistingValue: (
|
|
59
|
+
storeId: string,
|
|
60
|
+
valueRule: string,
|
|
61
|
+
configs: SearchConfig
|
|
62
|
+
) => string | null;
|
|
22
63
|
}
|
|
23
64
|
}
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(){"use strict";function e(e){return e.split("").reverse().map((e=>String.fromCharCode(e.charCodeAt(0)-1))).join("")}function n(n){const[t,r="default"]=e(n).split("|");return[t,r]}function t(e){const n=function(e){let n=e.slice(e.indexOf("{")+1,e.lastIndexOf("}"));return n||""}(e),t=function(e){let n=e.replace(r,""),t=n.slice(n.indexOf("(")+1,n.indexOf(")")).match(o);null===t&&(t=[]);return t}(e),i="id_"+function(){let e=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(n){var t=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"==n?t:3&t|8).toString(16)}))}();let c=`window['__fnCache']["${i}"]= function(${t}){${n}}`,s=document.createElement("script");try{s.appendChild(document.createTextNode(c))}catch(a){s.text=c}let l=document.getElementsByTagName("head")[0]||document.documentElement;return l.appendChild(s),l.removeChild(s),window.__fnCache[`${i}`]}window.__fnCache=window.__fnCache||{};let r=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,o=/([^\s,]+)/g;function i(e,n,t=!1){const r=n.split(/\.|\[(\d+)\]/).filter(Boolean);let o,i=e;for(let c=0;c<r.length;c++){if(o=i,i=i[r[c]],void 0===i)return t?o:void 0}return t?o:i}(r=>{if(window.GZUAwCFuFf)return;window.GZUAwCFuFf=!0;const o={},c={},s={},l={},a={};let d=window.__d;window.__d&&(~d.toString().indexOf("__d_stub")?delete window.__d:d=new Proxy(window.__d,{apply:(e,n,t)=>(t=u(t),e.apply(n,t))})),Object.defineProperty(window,"__d",{get:function(){return d},set:function(e){d=new Proxy(e,{apply:(e,n,t)=>(t=u(t),e.apply(n,t))})}});const f=[];function u(e){let[n,r,a]=e;return"string"!=typeof n||f.includes(n)||(f.push(n),e[2]=function(e,n){if(!s[n])return e;const r=s[n];r.sort(((e,n)=>e.options.order-n.options.order));const o=r.find((e=>e.options.skipOthers));if(o)return t(o.replacement(e.toString()));return t(r.reduce(((e,n)=>e=n.replacement(e)),e.toString()))}(e[2],n),e[2]=function(e,n){return c[n]?new Proxy(e,{apply(e,t,r){if(r[5]&&r[5].dependencies)for(let n=0;n<r[5].dependencies.length;n++)r.push(r[5].dependencies[n].exports);const o=e.apply(t,r);return c[n].map((e=>{e(r)})),o}}):e}(e[2],n),e[2]=function(e,n){if(!o[n]||0===o[n].length)return e;const t=o[n];t.sort(((e,n)=>e.options.order-n.options.order));const r=t.reduce(((e,n)=>{const t=n.options.definerPath;return e[t]=e[t]||[],e[t].push(n),e}),{});return new Proxy(e,{apply(e,o,c){const s=e.apply(o,c);if(c[5]&&c[5].dependencies)for(let n=0;n<c[5].dependencies.length;n++)c.push(c[5].dependencies[n].exports);const l=c[3],a=(0,c[2])("CometErrorBoundary.react"),d=e=>(console.error(e),"Error");for(let f in r){const e=i(c,f,!0),o=f.split(".").pop(),s=i(c,f);e[o]=function(...e){const o=s.apply(s,e),i=e[0],{useState:u,useEffect:x,jsx:g,Fragment:w}=l("react"),[h,y]=u(0),v=()=>{if(!r[f])return _(o);const s=r[f].find((e=>e.options.skipOthers));if(s&&s.component)return g(s.fallback?a:w,{fallback:s.fallback,children:g(s.component,{payload:i,SourceCmp:o,lastCmp:_(o),definedArgs:c,callingArgs:e,extraPayloadFromDefiner:s.options.extraPayload,proxyCount:0,removeThisModuleProxy(){const e=r[f].indexOf(s);~e&&r[f].splice(e,1)}})});let l=0;return r[f].reduce(((s,d)=>(d.component&&(s=g(d.fallback?a:w,{fallback:d.fallback,children:g(d.component,{payload:i,SourceCmp:o,lastCmp:s,extraPayloadFromDefiner:d.options.extraPayload,proxyCount:l,definedArgs:c,callingArgs:e,removeThisModuleProxy(){const e=r[f].indexOf(d);if(~e){const o=t.indexOf(d);r[f].splice(e,1),t.splice(o,1),m(n)}}})}),l++),s)),_(o))};function _(e){return e&&e.$1&&"function"==typeof e.$1?g(e,e.props):e}return x((()=>{const e=p(n,(()=>{y(Math.random())}));return()=>e()}),[]),g(a,{fallback:d,children:v()})}}return s}})}(e[2],n),l[n]&&console.log(n,e)),e}function p(e,n){return a[e]=a[e]||[],a[e].push(n),()=>{const t=a[e].findIndex(n);a[e].splice(t,1)}}function m(e){if(a[e])for(let n of a[e])n()}r.zKjQYvgSmF=function(n){return window.require(e(n))},r.zKjQYvcSmF=(e,t,r)=>{const[i,c]=n(e);o[i]||console.error(`Undefined module ${i} from ${c} #1`);const s=o[i].find((e=>e.extensionId===c));if(!s)return console.error(`Undefined module ${i} from ${c} #2`);const{fallback:l}=r||{};s.component=t,s.fallback=l,m(i)},r.zKjQYVcSmF=(e,t)=>{const r=Object.assign({order:10,skipOthers:!1,beforeInject:()=>!0,afterInject:()=>{},extraPayload:void 0,definerPath:"[6].default"},t),[i,c]=n(e);o[i]=o[i]||[],o[i].push({extensionId:c,moduleName:i,options:r,component:void 0,fallback:void 0})},r.zKjQYwcSmF=n=>{l[e(n)]=!0},r.zKjQYvcSfF=(e,t,r)=>{const o=Object.assign({order:10,skipOthers:!1},r),[i,c]=n(e);s[i]=s[i]||[],s[i].push({moduleName:i,options:o,replacement:t})},r.zKGQYvcSmF=(n,t)=>{n=e(n),c[n]=c[n]||[],c[n].push(t)},r.zKjQYvcSfF("umvbgfe}spssf.cg",(e=>e.replace('debugjs.")','debugjs.");console.error(b.stackFrames.slice(0,10).map(e=>e.text).join("\\n"))'))),r.zKjQYvcSfF("umvbgfe}djttbmd/epsq.NPEudbfS",(e=>e.replace(/Error\(\w\(418\)\)/g,"void 0"))),r.zKjQYvcSfF("umvbgfe}fvfvRitjmcvQzbmfS0fsput0fnjuovs.zbmfs",(e=>e.replace(/,(\w)=new\(b\("relay-runtime\/mutations\/RelayRecordSourceProxy"/,',$1=window["RlbiULLGWt"]=new(b("relay-runtime/mutations/RelayRecordSourceProxy"'))),r.zKjQYvcSfF("umvbgfe}fvfvRitjmcvQzbmfS0fsput0fnjuovs.zbmfs",(e=>e=e.replace(/;(\w)\.commitPayload=function\(([\w,]+)\){/,";$1.commitPayload=function($2){try{if(arguments[0]){if(arguments[0]?.request?.variables?.__relay_internal__pv__CometUFIReactionEnableShortNamerelayprovider === true) return;};}catch(e){console.log('relayStoreCommitPayload',e)};")))})(window),(e=>{if(e.vTUNhjwVvX)return;e.vTUNhjwVvX=!0;e.zKjqYvcSmF=(n,t,r)=>{const o=e.RlbiULLGWt,i="string"==typeof n?o.get(n):n;if(void 0===i)return i;let c=(s=t.replace(/\[(\d+)\]/g,".$1"),s.replace(/\((.*?)\.(.*?)\)/g,"($1_*_*_*_*_$2)")).split(".");var s;c=c.map((e=>function(e){return e.replaceAll("_*_*_*_*_",".")}(e)));let l=i;for(let e=0;e<c.length;e++){const n=c[e];if("*"===n)return l;if(0===n.indexOf("^^")){const[e,t]=a(n.substring(2));if(l=l.getLinkedRecords(e,t),void 0===l)return d(n),l}else if(0===n.indexOf("^")){const[e,t]=a(n.substring(1));if(l=l.getLinkedRecord(e,t),null==l)return d(n),l}else if(n.match(/^\d+$/)){if(l=l[parseInt(n)],null==l)return d(n),l}else{const[e,t]=a(n);if(l=l.getValue(e,t),null==l)return d(n),l}}return l;function a(e){const[n,t]=e.split("{");if(!t)return[n,{}];if(!r)throw new Error("args undefined");return[n,r[t.substring(0,t.length-1)]||{}]}function d(o){~e.location.search.indexOf("debug")&&console.warn("undefined value",{id:n,path:t,args:r,currentPath:o})}}})(window),(n=>{if(window.xmxlgxMDjA)return;window.xmxlgxMDjA=!0;let t={};n.zKGQYvcSmF("sf{jmbjsfTbubEfmqnjTsiy",(e=>{const n=e[4].exports.default;e[4].exports.default=function(...e){const r=e[0].fb_api_req_friendly_name;return r&&t[r]&&(e[0]=t[r].reduce(((e,n)=>e=n(e)),e[0])),n.apply(n,e)}}));n.zkjQYvcSmF=(n,r)=>{n=e(n),t[n]=t[n]||[],t[n].push(r)}})(window)}();
|
|
1
|
+
!function(){"use strict";function n(n){return n.split("").reverse().map(n=>String.fromCharCode(n.charCodeAt(0)-1)).join("")}function t(t){const r={rzPQs:"default",qznUE:function(n,t){return n(t)}},[e,o=r.rzPQs]=r.qznUE(n,t).split("|");return[e,o]}function r(n){const t=e(n),r=function(n,t){return n(t)}(i,n),o=function(n,t){return n+t}("id_",function(n){return n()}(f));let u="window['__fnCache'][\""+o+'"]= function('+r+"){"+t+"}",c=document.createElement("script");try{c.appendChild(document.createTextNode(u))}catch(l){c.text=u}let s=document.getElementsByTagName("head")[0]||document.documentElement;return s.appendChild(c),s.removeChild(c),window.__fnCache[""+o]}function e(n){return function(n){return n||""}(n.slice(n.indexOf("{")+1,n.lastIndexOf("}")))}window.__fnCache=window.__fnCache||{};let o=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,u=/([^\s,]+)/g;function i(n){let t=n.replace(o,""),r=t.slice((e=t.indexOf("("),i=1,e+i),t.indexOf(")")).match(u);var e,i;return function(n,t){return n===t}(null,r)&&(r=[]),r}function c(n,t,r=!1){const e=function(n,t){return n<t},o=function(n,t){return n===t},u=t.split(/\.|\[(\d+)\]/).filter(Boolean);let i,c=n;for(let f=0;e(f,u.length);f++)if(i=c,c=c[u[f]],o(void 0,c))return r?i:void 0;return r?i:c}function f(){const n={kJGmy:function(n,t){return n|t},KYodb:function(n,t){return n%t},PYOqI:function(n,t){return n+t},foKIU:function(n,t){return n*t},PJvOG:function(n,t){return n/t},siSsC:function(n,t){return n==t},uOVGg:function(n,t){return n|t},UTLTB:function(n,t){return n&t},fZCKD:"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx"};let t=(new Date).getTime();return n.fZCKD.replace(/[xy]/g,function(r){var e=n.kJGmy(n.KYodb(n.PYOqI(t,n.foKIU(16,Math.random())),16),0);return t=Math.floor(n.PJvOG(t,16)),(n.siSsC("x",r)?e:n.uOVGg(n.UTLTB(3,e),8)).toString(16)})}(e=>{const o=function(n,t){return n(t)},u=function(n,t){return n(t)},i=function(n,t){return n<t},f=function(n,t,r){return n(t,r)},s=function(n,t,r){return n(t,r)},l=function(n,t){return n==t},d="function",a="react",p=function(n,t){return n(t)},m=function(n,t,r){return n(t,r)},x=function(n){return n()},g="CometErrorBoundary.react",_=function(n,t,r,e){return n(t,r,e)},h=function(n,t){return n===t},v=function(n,t){return n!=t},y="string",w=function(n){return n()},b=function(n,t){return n(t)},S=function(n,t){return n(t)},j=function(n,t){return n||t},k="[6].default",P="__d_stub",F="__d",K="umvbgfe}spssf.cg",z="umvbgfe}djttbmd/epsq.NPEudbfS",U="umvbgfe}fvfvRitjmcvQzbmfS0fsput0fnjuovs.zbmfs";if(window.GZUAwCFuFf)return;window.GZUAwCFuFf=!0;const Y={},Q={},C={},O={},A={};let R=window.__d;window.__d&&(~R.toString().indexOf(P)?delete window.__d:R=new Proxy(window.__d,{apply:(n,t,r)=>(r=E(r),n.apply(t,r))})),Object.defineProperty(window,F,{get:function(){return R},set:function(n){R=new Proxy(n,{apply:(n,t,r)=>(r=E(r),n.apply(t,r))})}});const T=[];function E(n){const t={kfRHQ:function(n,t){return o(n,t)},jkDKS:function(n,t){return u(n,t)},rkLJt:function(n,t){return i(n,t)},JSNQh:function(n,t){return o(n,t)},GPbYf:function(n,t,r){return f(n,t,r)},UldUm:function(n,t,r){return f(n,t,r)},Eaizd:function(n,t){return u(n,t)},VVEQj:function(n,t){return o(n,t)},xxFcU:function(n,t,r){return s(n,t,r)},jnKtz:function(n,t){return l(n,t)},ezKxu:d,fZoNM:function(n,t){return o(n,t)},rUFgW:a,Qebpa:function(n,t){return p(n,t)},FsiIa:function(n,t,r){return m(n,t,r)},RsAsP:function(n,t,r){return f(n,t,r)},YvvfL:function(n){return x(n)},aPjfz:g,YTWkP:function(n,t,r,e){return _(n,t,r,e)},rJXAX:function(n,t){return h(n,t)}};let[e,w,b]=n;return v(y,typeof e)||T.includes(e)||(T.push(e),n[2]=function(n,e){if(!C[e])return n;const o=C[e];o.sort((n,t)=>n.options.order-t.options.order);const u=o.find(n=>n.options.skipOthers);return t.kfRHQ(r,u?u.replacement(n.toString()):o.reduce((n,t)=>t.replacement(n),n.toString()))}(n[2],e),n[2]=(S=n[2],Q[j=e]?new Proxy(S,{apply(n,r,e){if(e[5]&&e[5].dependencies)for(let u=0;t.rkLJt(u,e[5].dependencies.length);u++)e.push(e[5].dependencies[u].exports);const o=n.apply(r,e);return Q[j].map(n=>{!function(n,r){t.jkDKS(n,r)}(n,e)}),o}}):S),n[2]=function(n,r){if(!Y[r]||t.rJXAX(0,Y[r].length))return n;const e=Y[r];e.sort((n,t)=>n.options.order-t.options.order);const o=e.reduce((n,t)=>{const r=t.options.definerPath;return n[r]=n[r]||[],n[r].push(t),n},{});return new Proxy(n,{apply(n,u,i){const f={IRVEg:function(n,r){return t.JSNQh(n,r)},TCFgX:function(n,r,e){return t.GPbYf(n,r,e)},lkgtH:function(n,r,e){return t.UldUm(n,r,e)},fweuK:function(n,r){return t.Eaizd(n,r)},FhdPV:function(n,r){return t.VVEQj(n,r)},IfxZj:function(n,r,e){return t.xxFcU(n,r,e)},rNGpX:function(n,r){return t.jnKtz(n,r)},XyAqm:t.ezKxu,DAZhU:function(n,r,e){return t.UldUm(n,r,e)},YmVWW:function(n,r){return t.fZoNM(n,r)},SvCHG:t.rUFgW,fWAMh:function(n,r){return t.Qebpa(n,r)},wBWSN:function(n,r,e){return t.FsiIa(n,r,e)},TKLQf:function(n,r,e){return t.RsAsP(n,r,e)},DRKHd:function(n){return t.YvvfL(n)}},s=n.apply(u,i);if(i[5]&&i[5].dependencies)for(let r=0;t.rkLJt(r,i[5].dependencies.length);r++)i.push(i[5].dependencies[r].exports);const l=i[3],d=(0,i[2])(t.aPjfz),a=n=>(console.error(n),"Error");for(let p in o){const n=t.YTWkP(c,i,p,!0),u=p.split(".").pop(),s=t.UldUm(c,i,p);n[u]=function(...n){const t={nJpTY:function(n,t){return f.rNGpX(n,t)},HOBvS:f.XyAqm,znAWd:function(n,t,r){return f.DAZhU(n,t,r)},MSdLK:function(n,t){return f.YmVWW(n,t)}},u=s.apply(s,n),c=n[0],{useState:m,useEffect:x,jsx:g,Fragment:_}=f.IRVEg(l,f.SvCHG),[h,v]=f.fWAMh(m,0);function y(n){return n&&n.$1&&t.nJpTY(t.HOBvS,typeof n.$1)?t.znAWd(g,n,n.props):n}return f.wBWSN(x,()=>{const n=f.IfxZj(L,r,()=>{t.MSdLK(v,Math.random())});return()=>n()},[]),f.TKLQf(g,d,{fallback:a,children:f.DRKHd(()=>{if(!o[p])return f.IRVEg(y,u);const t=o[p].find(n=>n.options.skipOthers);if(t&&t.component)return f.TCFgX(g,t.fallback?d:_,{fallback:t.fallback,children:f.lkgtH(g,t.component,{payload:c,SourceCmp:u,lastCmp:f.fweuK(y,u),definedArgs:i,callingArgs:n,extraPayloadFromDefiner:t.options.extraPayload,proxyCount:0,removeThisModuleProxy(){const n=o[p].indexOf(t);~n&&o[p].splice(n,1)}})});let s=0;return o[p].reduce((t,l)=>(l.component&&(t=g(l.fallback?d:_,{fallback:l.fallback,children:g(l.component,{payload:c,SourceCmp:u,lastCmp:t,extraPayloadFromDefiner:l.options.extraPayload,proxyCount:s,definedArgs:i,callingArgs:n,removeThisModuleProxy(){const n=o[p].indexOf(l);if(~n){const t=e.indexOf(l);o[p].splice(n,1),e.splice(t,1),f.IRVEg(G,r)}}})}),s++),t),f.FhdPV(y,u))})})}}return s}})}(n[2],e),O[e]&&console.log(e,n)),n;var S,j}function L(n,t){return A[n]=A[n]||[],A[n].push(t),()=>{const r=A[n].findIndex(t);A[n].splice(r,1)}}function G(n){if(A[n])for(let t of A[n])w(t)}e.zKjQYvgSmF=function(t){return window.require(b(n,t))},e.zKjQYvcSmF=(n,r,e)=>{const[o,u]=S(t,n);Y[o]||console.error("Undefined module "+o+" from "+u+" #1");const i=Y[o].find(n=>n.extensionId===u);if(!i)return console.error("Undefined module "+o+" from "+u+" #2");const{fallback:c}=j(e,{});i.component=r,i.fallback=c,b(G,o)},e.zKjQYVcSmF=(n,r)=>{const e=Object.assign({order:10,skipOthers:!1,beforeInject:()=>!0,afterInject:()=>{},extraPayload:void 0,definerPath:k},r),[o,u]=p(t,n);Y[o]=Y[o]||[],Y[o].push({extensionId:u,moduleName:o,options:e,component:void 0,fallback:void 0})},e.zKjQYwcSmF=t=>{O[o(n,t)]=!0},e.zKjQYvcSfF=(n,r,e)=>{const o=Object.assign({order:10,skipOthers:!1},e),[u,i]=b(t,n);C[u]=C[u]||[],C[u].push({moduleName:u,options:o,replacement:r})},e.zKGQYvcSmF=(t,r)=>{t=p(n,t),Q[t]=Q[t]||[],Q[t].push(r)},e.zKjQYvcSfF(K,n=>n.replace('debugjs.")','debugjs.");console.error(b.stackFrames.slice(0,10).map(e=>e.text).join("\\n"))')),e.zKjQYvcSfF(z,n=>n.replace(/Error\(\w\(418\)\)/g,"void 0")),e.zKjQYvcSfF(U,n=>n.replace(/,(\w)=new\(b\("relay-runtime\/mutations\/RelayRecordSourceProxy"/,',$1=window["RlbiULLGWt"]=new(b("relay-runtime/mutations/RelayRecordSourceProxy"')),e.zKjQYvcSfF(U,n=>n.replace(/;(\w)\.commitPayload=function\(([\w,]+)\){/,";$1.commitPayload=function($2){try{if(arguments[0]){if(arguments[0]?.request?.variables?.__relay_internal__pv__CometUFIReactionEnableShortNamerelayprovider === true) return;};}catch(e){console.log('relayStoreCommitPayload',e)};"))})(window),(n=>{const t="_*_*_*_*_",r="args undefined",e=function(n,t){return n-t},o="debug",u="undefined value",i=function(n,t){return n==t},c="string",f=function(n,t){return n===t},s=".$1",l="($1_*_*_*_*_$2)",d=function(n,t){return n<t},a=function(n,t){return n===t},p=function(n,t){return n(t)},m=function(n,t){return n===t},x=function(n,t){return n(t)},g=function(n,t){return n===t},_=function(n,t){return n==t},h=function(n,t){return n(t)},v=function(n,t){return n==t},y=function(n,t){return n(t)},w=function(n,t){return n(t)},b=function(n,t){return n(t)};n.vTUNhjwVvX||(n.vTUNhjwVvX=!0,n.zKjqYvcSmF=(S,j,k)=>{const P={BtjQg:r,SYWng:function(n,t){return e(n,t)},BKfeQ:o,SvJMd:u},F=n.RlbiULLGWt,K=i(c,typeof S)?F.get(S):S;if(f(void 0,K))return K;let z=(U=j.replace(/\[(\d+)\]/g,s),U.replace(/\((.*?)\.(.*?)\)/g,l)).split(".");var U;z=z.map(n=>n.replaceAll(t,"."));let Y=K;for(let n=0;d(n,z.length);n++){const t=z[n];if(f("*",t))return Y;if(a(0,t.indexOf("^^"))){const[n,r]=p(Q,t.substring(2));if(Y=Y.getLinkedRecords(n,r),m(void 0,Y))return x(C,t),Y}else if(g(0,t.indexOf("^"))){const[n,r]=x(Q,t.substring(1));if(Y=Y.getLinkedRecord(n,r),_(null,Y))return x(C,t),Y}else if(t.match(/^\d+$/)){if(Y=Y[h(parseInt,t)],v(null,Y))return y(C,t),Y}else{const[n,r]=w(Q,t);if(Y=Y.getValue(n,r),i(null,Y))return b(C,t),Y}}return Y;function Q(n){const[t,r]=n.split("{");if(!r)return[t,{}];if(!k)throw new Error(P.BtjQg);return[t,k[r.substring(0,P.SYWng(r.length,1))]||{}]}function C(t){~n.location.search.indexOf(P.BKfeQ)&&console.warn(P.SvJMd,{id:S,path:j,args:k,currentPath:t})}})})(window),(n=>{const t=function(n,t){return n!==t},r=function(n,t){return n==t},e="object",o=function(n,t){return n in t},u=function(n,t){return n===t},i=function(n,t){return n==t},c=function(n,t){return n!==t},f=function(n,t){return n in t},s=function(n,t){return n<t},l=function(n,t){return n(t)},d=function(n,t,r){return n(t,r)},a=function(n,t){return n!==t},p="continue",m=function(n,t){return n===t};function x(s){const l=function(){const t=function(n,t){return function(n,t){return function(n,t){return n instanceof t}(n,t)}(n,t)},r=n.RlbiULLGWt.getRoot();let e=[];return Object.keys(r).forEach(n=>{const o=r[n];if(o.__sources&&Array.isArray(o.__sources)){const n=o.__sources;for(const r of n)for(const n in r){const o=r[n];t(o,Map)&&e.push(o)}}}),e}();for(const n of l)for(const[l,d]of n)for(const[n,a]of Object.entries(d))if(t("__id",n)&&t("__typename",n)){if(r(e,typeof a)&&t(null,a)&&o("__ref",a)&&u(a.__ref,s))return d;if(i(e,typeof a)&&c(null,a)&&f("__refs",a)&&Array.isArray(a.__refs)&&a.__refs.includes(s))return d}return null}function g(n,t,r){const e=[];let o=n,u=0;for(;s(u,t);){const n=l(x,o);if(!n)break;e.push(n);const t=d(r,n,e);if(a(p,t)){if(m("break",t))break;return t}o=n.__id,u++}return null}function _(n,t){const r=[];return function(n,t,r,e){n(t,r,e)}(g,n,(null==t?void 0:t.depth)||10,(n,t)=>(r.push(n),"continue")),function(n,t){return n>t}(r.length,0)?r:null}!n.vTUNhJwVvX&&n.RlbiULLGWt&&(n.vTUNhJwVvX=!0,n.zkjQYvCSmF=_,n.zkJqYvcSmF=function(n,t){const r=function(n,t,r){return n(t,r)}(_,n,t);return r?r.map(n=>n.__typename):null},n.zkJQyvcSmF=function(n,t,r){return function(n,t,r,e){return n(t,r,e)}(g,n,(null==r?void 0:r.depth)||10,n=>n.__typename===t?n:"continue")},n.zkjQYvcSMf=function(t,r,e){const o=function(n,t){return function(n,t){return n!=t}(n,t)},u=p;return function(n,t,r,e){return n(t,r,e)}(g,t,(null==e?void 0:e.depth)||10,t=>{try{const e=n.zKjqYvcSmF(t.__id,r);if(o(null,e))return t.__id}catch(e){}return u})})})(window),(t=>{if(window.xmxlgxMDjA)return;window.xmxlgxMDjA=!0;let r={};t.zKGQYvcSmF("sf{jmbjsfTbubEfmqnjTsiy",n=>{const t=n[4].exports.default;n[4].exports.default=function(...n){const e=n[0].fb_api_req_friendly_name;return e&&r[e]&&(n[0]=r[e].reduce((n,t)=>t(n),n[0])),t.apply(t,n)}}),t.zkjQYvcSmF=(t,e)=>{t=function(n,t){return n(t)}(n,t),r[t]=r[t]||[],r[t].push(e)}})(window)}();
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sidesuit/pkg-module-proxy",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.iife.js",
|
|
7
7
|
"module": "./dist/index.iife.js",
|
|
@@ -17,21 +17,21 @@
|
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
19
|
"@rollup/plugin-replace": "^5.0.5",
|
|
20
|
-
"@sidesuit/pkg-vite-plugins": "^
|
|
20
|
+
"@sidesuit/pkg-vite-plugins": "^1.2.0",
|
|
21
21
|
"@types/lodash-es": "^4.17.12",
|
|
22
|
-
"@types/node": "^20.11.
|
|
23
|
-
"@types/react": "^18.2.
|
|
22
|
+
"@types/node": "^20.11.24",
|
|
23
|
+
"@types/react": "^18.2.61",
|
|
24
24
|
"@vitejs/plugin-react": "4.2.1",
|
|
25
25
|
"glob": "10.3.10",
|
|
26
26
|
"javascript-obfuscator-unstring-array": "^4.1.1",
|
|
27
27
|
"lodash-es": "^4.17.21",
|
|
28
28
|
"npm-check": "^6.0.1",
|
|
29
|
-
"prettier": "^3.2.
|
|
29
|
+
"prettier": "^3.2.5",
|
|
30
30
|
"react": "^18.2.0",
|
|
31
|
-
"terser": "^5.
|
|
31
|
+
"terser": "^5.28.1",
|
|
32
32
|
"tsc-alias": "^1.8.8",
|
|
33
33
|
"typescript": "^5.3.3",
|
|
34
|
-
"vite": "^
|
|
35
|
-
"vite-plugin-static-copy": "^0.
|
|
34
|
+
"vite": "^5.1.4",
|
|
35
|
+
"vite-plugin-static-copy": "^1.0.1"
|
|
36
36
|
}
|
|
37
37
|
}
|