@curatedotfun/translate-transform
Version:
Translation transform plugin for curatedotfun using DeepL
3 lines • 405 kB
JavaScript
(()=>{var __webpack_modules__={9725:function(e,t,n){"use strict";var a=n(5542),i=n(4195);let o=null;function r(e){let t=i.getGlobalFederationInstance(e.name,e.version);return t?(t.initOptions(e),o||(o=t),t):(o=new(a.getGlobalFederationConstructor()||a.FederationHost)(e),a.setGlobalFederationInstance(o),o)}function s(...e){return a.assert(o,"Please call init first"),o.loadRemote.apply(o,e)}function c(...e){return a.assert(o,"Please call init first"),o.loadShare.apply(o,e)}function l(...e){return a.assert(o,"Please call init first"),o.loadShareSync.apply(o,e)}function p(...e){return a.assert(o,"Please call init first"),o.preloadRemote.apply(o,e)}function u(...e){return a.assert(o,"Please call init first"),o.registerRemotes.apply(o,e)}function d(...e){return a.assert(o,"Please call init first"),o.registerPlugins.apply(o,e)}function m(){return o}a.setGlobalFederationConstructor(a.FederationHost),Object.defineProperty(t,"FederationHost",{enumerable:!0,get:function(){return a.FederationHost}}),Object.defineProperty(t,"Module",{enumerable:!0,get:function(){return a.Module}}),Object.defineProperty(t,"getRemoteEntry",{enumerable:!0,get:function(){return a.getRemoteEntry}}),Object.defineProperty(t,"getRemoteInfo",{enumerable:!0,get:function(){return a.getRemoteInfo}}),Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return a.loadScript}}),Object.defineProperty(t,"loadScriptNode",{enumerable:!0,get:function(){return a.loadScriptNode}}),Object.defineProperty(t,"registerGlobalPlugins",{enumerable:!0,get:function(){return a.registerGlobalPlugins}}),t.getInstance=m,t.init=r,t.loadRemote=s,t.loadShare=c,t.loadShareSync=l,t.preloadRemote=p,t.registerPlugins=d,t.registerRemotes=u},4195:function(e,t,n){"use strict";var a=n(5542);function i(){return"undefined"!=typeof FEDERATION_BUILD_IDENTIFIER?FEDERATION_BUILD_IDENTIFIER:""}t.getGlobalFederationInstance=function(e,t){let n=i();return a.CurrentGlobal.__FEDERATION__.__INSTANCES__.find(a=>!!n&&a.options.id===i()||a.options.name===e&&!a.options.version&&!t||a.options.name===e&&!!t&&a.options.version===t)}},3232:function(e,t){"use strict";let n="RUNTIME-001",a="RUNTIME-002",i="RUNTIME-003",o="RUNTIME-004",r="RUNTIME-005",s="RUNTIME-006",c="RUNTIME-007",l="RUNTIME-008",p="TYPE-001",u="BUILD-001",d=e=>{let t=e.split("-")[0].toLowerCase();return`https://module-federation.io/guide/troubleshooting/${t}/${e}`},m=(e,t,n,a)=>{let i=[`${[t[e]]} #${e}`];return n&&i.push(`args: ${JSON.stringify(n)}`),i.push(d(e)),a&&i.push(`Original Error Message:
${a}`),i.join("\n")};function f(){return(f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e}).apply(this,arguments)}let h={[n]:"Failed to get remoteEntry exports.",[a]:'The remote entry interface does not contain "init"',[i]:"Failed to get manifest.",[o]:"Failed to locate remote.",[r]:"Invalid loadShareSync function call from bundler runtime",[s]:"Invalid loadShareSync function call from runtime",[c]:"Failed to get remote snapshot.",[l]:"Failed to load script resources."},x={[p]:"Failed to generate type declaration."},v={[u]:"Failed to find expose module."},g=f({},h,x,v);t.BUILD_001=u,t.RUNTIME_001=n,t.RUNTIME_002=a,t.RUNTIME_003=i,t.RUNTIME_004=o,t.RUNTIME_005=r,t.RUNTIME_006=s,t.RUNTIME_007=c,t.RUNTIME_008=l,t.TYPE_001=p,t.buildDescMap=v,t.errorDescMap=g,t.getShortErrorMsg=m,t.runtimeDescMap=h,t.typeDescMap=x},5542:function(e,t,n){"use strict";var a=n(2335),i=n(5851),o=n(3232);let r="[ Federation Runtime ]",s=i.createLogger(r);function c(e,t){e||l(t)}function l(e){if(e instanceof Error)throw e.message=`${r}: ${e.message}`,e;throw Error(`${r}: ${e}`)}function p(e){e instanceof Error&&(e.message=`${r}: ${e.message}`),s.warn(e)}function u(e,t){return -1===e.findIndex(e=>e===t)&&e.push(t),e}function d(e){return"version"in e&&e.version?`${e.name}:${e.version}`:"entry"in e&&e.entry?`${e.name}:${e.entry}`:`${e.name}`}function m(e){return void 0!==e.entry}function f(e){return!e.entry.includes(".json")&&e.entry.includes(".js")}async function h(e,t){try{return await e()}catch(e){t||p(e);return}}function x(e){return e&&"object"==typeof e}let v=Object.prototype.toString;function g(e){return"[object Object]"===v.call(e)}function y(e,t){let n=/^(https?:)?\/\//i;return e.replace(n,"").replace(/\/$/,"")===t.replace(n,"").replace(/\/$/,"")}function b(e){return Array.isArray(e)?e:[e]}function E(e){let t={url:"",type:"global",globalName:""};return i.isBrowserEnv()||i.isReactNativeEnv()?"remoteEntry"in e?{url:e.remoteEntry,type:e.remoteEntryType,globalName:e.globalName}:t:"ssrRemoteEntry"in e?{url:e.ssrRemoteEntry||t.url,type:e.ssrRemoteEntryType||t.type,globalName:e.globalName}:t}let w=(e,t)=>{let n;return n=e.endsWith("/")?e.slice(0,-1):e,t.startsWith(".")&&(t=t.slice(1)),n+=t},_="object"==typeof globalThis?globalThis:window,S=(()=>{try{return document.defaultView}catch(e){return _}})(),R=S;function O(e,t,n){Object.defineProperty(e,t,{value:n,configurable:!1,writable:!0})}function I(e,t){return Object.hasOwnProperty.call(e,t)}I(_,"__GLOBAL_LOADING_REMOTE_ENTRY__")||O(_,"__GLOBAL_LOADING_REMOTE_ENTRY__",{});let T=_.__GLOBAL_LOADING_REMOTE_ENTRY__;function C(e){var t,n,a,i,o,r,s,c,l,p,u,d;I(e,"__VMOK__")&&!I(e,"__FEDERATION__")&&O(e,"__FEDERATION__",e.__VMOK__),I(e,"__FEDERATION__")||(O(e,"__FEDERATION__",{__GLOBAL_PLUGIN__:[],__INSTANCES__:[],moduleInfo:{},__SHARE__:{},__MANIFEST_LOADING__:{},__PRELOADED_MAP__:new Map}),O(e,"__VMOK__",e.__FEDERATION__)),null!=(s=(t=e.__FEDERATION__).__GLOBAL_PLUGIN__)||(t.__GLOBAL_PLUGIN__=[]),null!=(c=(n=e.__FEDERATION__).__INSTANCES__)||(n.__INSTANCES__=[]),null!=(l=(a=e.__FEDERATION__).moduleInfo)||(a.moduleInfo={}),null!=(p=(i=e.__FEDERATION__).__SHARE__)||(i.__SHARE__={}),null!=(u=(o=e.__FEDERATION__).__MANIFEST_LOADING__)||(o.__MANIFEST_LOADING__={}),null!=(d=(r=e.__FEDERATION__).__PRELOADED_MAP__)||(r.__PRELOADED_MAP__=new Map)}function D(){_.__FEDERATION__.__GLOBAL_PLUGIN__=[],_.__FEDERATION__.__INSTANCES__=[],_.__FEDERATION__.moduleInfo={},_.__FEDERATION__.__SHARE__={},_.__FEDERATION__.__MANIFEST_LOADING__={},Object.keys(T).forEach(e=>{delete T[e]})}function k(e){_.__FEDERATION__.__INSTANCES__.push(e)}function A(){return _.__FEDERATION__.__DEBUG_CONSTRUCTOR__}function L(e,t=i.isDebugMode()){t&&(_.__FEDERATION__.__DEBUG_CONSTRUCTOR__=e,_.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__="0.11.2")}function N(e,t){if("string"==typeof t){if(e[t])return{value:e[t],key:t};for(let n of Object.keys(e)){let[a,i]=n.split(":"),o=`${a}:${t}`,r=e[o];if(r)return{value:r,key:o}}return{value:void 0,key:t}}throw Error("key must be string")}C(_),C(S);let j=()=>S.__FEDERATION__.moduleInfo,F=(e,t)=>{let n=N(t,d(e)).value;if(n&&!n.version&&"version"in e&&e.version&&(n.version=e.version),n)return n;if("version"in e&&e.version){let{version:t}=e,n=d(a._object_without_properties_loose(e,["version"])),i=N(S.__FEDERATION__.moduleInfo,n).value;if((null==i?void 0:i.version)===t)return i}},P=e=>F(e,S.__FEDERATION__.moduleInfo),M=(e,t)=>{let n=d(e);return S.__FEDERATION__.moduleInfo[n]=t,S.__FEDERATION__.moduleInfo},U=e=>(S.__FEDERATION__.moduleInfo=a._extends({},S.__FEDERATION__.moduleInfo,e),()=>{for(let t of Object.keys(e))delete S.__FEDERATION__.moduleInfo[t]}),B=(e,t)=>{let n=t||`__FEDERATION_${e}:custom__`,a=_[n];return{remoteEntryKey:n,entryExports:a}},$=e=>{let{__GLOBAL_PLUGIN__:t}=S.__FEDERATION__;e.forEach(e=>{-1===t.findIndex(t=>t.name===e.name)?t.push(e):p(`The plugin ${e.name} has been registered.`)})},z=()=>S.__FEDERATION__.__GLOBAL_PLUGIN__,H=e=>_.__FEDERATION__.__PRELOADED_MAP__.get(e),q=e=>_.__FEDERATION__.__PRELOADED_MAP__.set(e,!0),G="default",W="global",V="[0-9A-Za-z-]+",Z=`(?:\\+(${V}(?:\\.${V})*))`,K="0|[1-9]\\d*",J="[0-9]+",X="\\d*[a-zA-Z-][a-zA-Z0-9-]*",Y=`(?:${J}|${X})`,Q=`(?:-?(${Y}(?:\\.${Y})*))`,ee=`(?:${K}|${X})`,et=`(?:-(${ee}(?:\\.${ee})*))`,en=`${K}|x|X|\\*`,ea=`[v=\\s]*(${en})(?:\\.(${en})(?:\\.(${en})(?:${et})?${Z}?)?)?`,ei=`^\\s*(${ea})\\s+-\\s+(${ea})\\s*$`,eo=`(${J})\\.(${J})\\.(${J})`,er=`[v=\\s]*${eo}${Q}?${Z}?`,es="((?:<|>)?=?)",ec=`(\\s*)${es}\\s*(${er}|${ea})`,el="(?:~>?)",ep=`(\\s*)${el}\\s+`,eu="(?:\\^)",ed=`(\\s*)${eu}\\s+`,em="(<|>)?=?\\s*\\*",ef=`^${eu}${ea}$`,eh=`(${K})\\.(${K})\\.(${K})`,ex=`v?${eh}${et}?${Z}?`,ev=`^${el}${ea}$`,eg=`^${es}\\s*${ea}$`,ey=`^${es}\\s*(${ex})$|^$`,eb="^\\s*>=\\s*0.0.0\\s*$";function eE(e){return new RegExp(e)}function ew(e){return!e||"x"===e.toLowerCase()||"*"===e}function e_(...e){return t=>e.reduce((e,t)=>t(e),t)}function eS(e){return e.match(eE(ey))}function eR(e,t,n,a){let i=`${e}.${t}.${n}`;return a?`${i}-${a}`:i}function eO(e){return e.replace(eE(ei),(e,t,n,a,i,o,r,s,c,l,p,u)=>(t=ew(n)?"":ew(a)?`>=${n}.0.0`:ew(i)?`>=${n}.${a}.0`:`>=${t}`,s=ew(c)?"":ew(l)?`<${Number(c)+1}.0.0-0`:ew(p)?`<${c}.${Number(l)+1}.0-0`:u?`<=${c}.${l}.${p}-${u}`:`<=${s}`,`${t} ${s}`.trim()))}function eI(e){return e.replace(eE(ec),"$1$2$3")}function eT(e){return e.replace(eE(ep),"$1~")}function eC(e){return e.replace(eE(ed),"$1^")}function eD(e){return e.trim().split(/\s+/).map(e=>e.replace(eE(ef),(e,t,n,a,i)=>{if(ew(t))return"";if(ew(n))return`>=${t}.0.0 <${Number(t)+1}.0.0-0`;if(ew(a))if("0"===t)return`>=${t}.${n}.0 <${t}.${Number(n)+1}.0-0`;else return`>=${t}.${n}.0 <${Number(t)+1}.0.0-0`;if(i)if("0"!==t)return`>=${t}.${n}.${a}-${i} <${Number(t)+1}.0.0-0`;else if("0"===n)return`>=${t}.${n}.${a}-${i} <${t}.${n}.${Number(a)+1}-0`;else return`>=${t}.${n}.${a}-${i} <${t}.${Number(n)+1}.0-0`;if("0"===t)if("0"===n)return`>=${t}.${n}.${a} <${t}.${n}.${Number(a)+1}-0`;else return`>=${t}.${n}.${a} <${t}.${Number(n)+1}.0-0`;return`>=${t}.${n}.${a} <${Number(t)+1}.0.0-0`})).join(" ")}function ek(e){return e.trim().split(/\s+/).map(e=>e.replace(eE(ev),(e,t,n,a,i)=>ew(t)?"":ew(n)?`>=${t}.0.0 <${Number(t)+1}.0.0-0`:ew(a)?`>=${t}.${n}.0 <${t}.${Number(n)+1}.0-0`:i?`>=${t}.${n}.${a}-${i} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${a} <${t}.${Number(n)+1}.0-0`)).join(" ")}function eA(e){return e.split(/\s+/).map(e=>e.trim().replace(eE(eg),(e,t,n,a,i,o)=>{let r=ew(n),s=r||ew(a),c=s||ew(i);if("="===t&&c&&(t=""),o="",r)if(">"===t||"<"===t)return"<0.0.0-0";else return"*";return t&&c?(s&&(a=0),i=0,">"===t?(t=">=",s?(n=Number(n)+1,a=0):a=Number(a)+1,i=0):"<="===t&&(t="<",s?n=Number(n)+1:a=Number(a)+1),"<"===t&&(o="-0"),`${t+n}.${a}.${i}${o}`):s?`>=${n}.0.0${o} <${Number(n)+1}.0.0-0`:c?`>=${n}.${a}.0${o} <${n}.${Number(a)+1}.0-0`:e})).join(" ")}function eL(e){return e.trim().replace(eE(em),"")}function eN(e){return e.trim().replace(eE(eb),"")}function ej(e,t){return(e=Number(e)||e)>(t=Number(t)||t)?1:e===t?0:-1}function eF(e,t){let{preRelease:n}=e,{preRelease:a}=t;if(void 0===n&&a)return 1;if(n&&void 0===a)return -1;if(void 0===n&&void 0===a)return 0;for(let e=0,t=n.length;e<=t;e++){let t=n[e],i=a[e];if(t!==i){if(void 0===t&&void 0===i)return 0;if(!t)return 1;if(!i)return -1;return ej(t,i)}}return 0}function eP(e,t){return ej(e.major,t.major)||ej(e.minor,t.minor)||ej(e.patch,t.patch)||eF(e,t)}function eM(e,t){return e.version===t.version}function eU(e,t){switch(e.operator){case"":case"=":return eM(e,t);case">":return 0>eP(e,t);case">=":return eM(e,t)||0>eP(e,t);case"<":return eP(e,t)>0;case"<=":return eM(e,t)||eP(e,t)>0;case void 0:return!0;default:return!1}}function eB(e){return e_(eD,ek,eA,eL)(e)}function e$(e){return e_(eO,eI,eT,eC)(e.trim()).split(/\s+/).join(" ")}function ez(e,t){if(!e)return!1;let n=e$(t).split(" ").map(e=>eB(e)).join(" ").split(/\s+/).map(e=>eN(e)),a=eS(e);if(!a)return!1;let[,i,,o,r,s,c]=a,l={operator:i,version:eR(o,r,s,c),major:o,minor:r,patch:s,preRelease:null==c?void 0:c.split(".")};for(let e of n){let t=eS(e);if(!t)return!1;let[,n,,a,i,o,r]=t;if(!eU({operator:n,version:eR(a,i,o,r),major:a,minor:i,patch:o,preRelease:null==r?void 0:r.split(".")},l))return!1}return!0}function eH(e,t,n,i){var o,r,s;let c;return c="get"in e?e.get:"lib"in e?()=>Promise.resolve(e.lib):()=>Promise.resolve(()=>{throw Error(`Can not get shared '${n}'!`)}),e.strategy&&p('"shared.strategy is deprecated, please set in initOptions.shareStrategy instead!"'),a._extends({deps:[],useIn:[],from:t,loading:null},e,{shareConfig:a._extends({requiredVersion:`^${e.version}`,singleton:!1,eager:!1,strictVersion:!1},e.shareConfig),get:c,loaded:null!=e&&!!e.loaded||"lib"in e||void 0,version:null!=(o=e.version)?o:"0",scope:Array.isArray(e.scope)?e.scope:[null!=(r=e.scope)?r:"default"],strategy:(null!=(s=e.strategy)?s:i)||"version-first"})}function eq(e,t){let n=t.shared||{},i=t.name,o=Object.keys(n).reduce((e,a)=>{let o=b(n[a]);return e[a]=e[a]||[],o.forEach(n=>{e[a].push(eH(n,i,a,t.shareStrategy))}),e},{}),r=a._extends({},e.shared);return Object.keys(o).forEach(e=>{r[e]?o[e].forEach(t=>{r[e].find(e=>e.version===t.version)||r[e].push(t)}):r[e]=o[e]}),{shared:r,shareInfos:o}}function eG(e,t){let n=e=>{if(!Number.isNaN(Number(e))){let t=e.split("."),n=e;for(let e=0;e<3-t.length;e++)n+=".0";return n}return e};return!!ez(n(e),`<=${n(t)}`)}let eW=(e,t)=>{let n=t||function(e,t){return eG(e,t)};return Object.keys(e).reduce((e,t)=>!e||n(e,t)||"0"===e?t:e,0)},eV=e=>!!e.loaded||"function"==typeof e.lib,eZ=e=>!!e.loading;function eK(e,t,n){let a=e[t][n],i=function(e,t){return!eV(a[e])&&eG(e,t)};return eW(e[t][n],i)}function eJ(e,t,n){let a=e[t][n],i=function(e,t){let n=e=>eV(e)||eZ(e);if(n(a[t]))if(n(a[e]))return!!eG(e,t);else return!0;return!n(a[e])&&eG(e,t)};return eW(e[t][n],i)}function eX(e){return"loaded-first"===e?eJ:eK}function eY(e,t,n,a){if(!e)return;let{shareConfig:i,scope:o=G,strategy:r}=n;for(let s of Array.isArray(o)?o:[o])if(i&&e[s]&&e[s][t]){let{requiredVersion:o}=i,c=eX(r)(e,s,t),u=()=>{if(i.singleton){if("string"==typeof o&&!ez(c,o)){let a=`Version ${c} from ${c&&e[s][t][c].from} of shared singleton module ${t} does not satisfy the requirement of ${n.from} which needs ${o})`;i.strictVersion?l(a):p(a)}return e[s][t][c]}if(!1===o||"*"===o||ez(c,o))return e[s][t][c];for(let[n,a]of Object.entries(e[s][t]))if(ez(n,o))return a},d={shareScopeMap:e,scope:s,pkgName:t,version:c,GlobalFederation:R.__FEDERATION__,resolver:u};return(a.emit(d)||d).resolver()}}function eQ(){return R.__FEDERATION__.__SHARE__}function e0(e){var t;let{pkgName:n,extraOptions:a,shareInfos:i}=e,o=e=>{if(!e)return;let t={};e.forEach(e=>{t[e.version]=e});let n=function(e,n){return!eV(t[e])&&eG(e,n)},a=eW(t,n);return t[a]};return Object.assign({},(null!=(t=null==a?void 0:a.resolver)?t:o)(i[n]),null==a?void 0:a.customShareInfo)}var e1={global:{Global:R,nativeGlobal:S,resetFederationGlobalInfo:D,setGlobalFederationInstance:k,getGlobalFederationConstructor:A,setGlobalFederationConstructor:L,getInfoWithoutType:N,getGlobalSnapshot:j,getTargetSnapshotInfoByModuleInfo:F,getGlobalSnapshotInfoByModuleInfo:P,setGlobalSnapshotInfoByModuleInfo:M,addGlobalSnapshot:U,getRemoteEntryExports:B,registerGlobalPlugins:$,getGlobalHostPlugins:z,getPreloaded:H,setPreloaded:q},share:{getRegisteredShare:eY,getGlobalShareScope:eQ}};function e2(){return"undefined"!=typeof FEDERATION_BUILD_IDENTIFIER?FEDERATION_BUILD_IDENTIFIER:""}function e3(e,t){for(let n of e){let e=t.startsWith(n.name),a=t.replace(n.name,"");if(e){if(a.startsWith("/"))return{pkgNameOrAlias:n.name,expose:a=`.${a}`,remote:n};else if(""===a)return{pkgNameOrAlias:n.name,expose:".",remote:n}}let i=n.alias&&t.startsWith(n.alias),o=n.alias&&t.replace(n.alias,"");if(n.alias&&i){if(o&&o.startsWith("/"))return{pkgNameOrAlias:n.alias,expose:o=`.${o}`,remote:n};else if(""===o)return{pkgNameOrAlias:n.alias,expose:".",remote:n}}}}function e6(e,t){for(let n of e)if(t===n.name||n.alias&&t===n.alias)return n}function e4(e,t){let n=z();return n.length>0&&n.forEach(t=>{(null==e?void 0:e.find(e=>e.name!==t.name))&&e.push(t)}),e&&e.length>0&&e.forEach(e=>{t.forEach(t=>{t.applyPlugin(e)})}),e}async function e8({entry:e,remoteEntryExports:t}){return new Promise((n,a)=>{try{t?n(t):"undefined"!=typeof FEDERATION_ALLOW_NEW_FUNCTION?Function("callbacks",`import("${e}").then(callbacks[0]).catch(callbacks[1])`)([n,a]):import(e).then(n).catch(a)}catch(e){a(e)}})}async function e5({entry:e,remoteEntryExports:t}){return new Promise((n,a)=>{try{t?n(t):Function("callbacks",`System.import("${e}").then(callbacks[0]).catch(callbacks[1])`)([n,a])}catch(e){a(e)}})}async function e7({name:e,globalName:t,entry:n,loaderHook:a}){let{entryExports:r}=B(e,t);return r||i.loadScript(n,{attrs:{},createScriptHook:(e,t)=>{let n=a.lifecycle.createScript.emit({url:e,attrs:t});if(n&&(n instanceof HTMLScriptElement||"script"in n||"timeout"in n))return n}}).then(()=>{let{remoteEntryKey:a,entryExports:i}=B(e,t);return c(i,o.getShortErrorMsg(o.RUNTIME_001,o.runtimeDescMap,{remoteName:e,remoteEntryUrl:n,remoteEntryKey:a})),i}).catch(t=>{throw c(void 0,o.getShortErrorMsg(o.RUNTIME_008,o.runtimeDescMap,{remoteName:e,resourceUrl:n})),t})}async function e9({remoteInfo:e,remoteEntryExports:t,loaderHook:n}){let{entry:a,entryGlobalName:i,name:o,type:r}=e;switch(r){case"esm":case"module":return e8({entry:a,remoteEntryExports:t});case"system":return e5({entry:a,remoteEntryExports:t});default:return e7({entry:a,globalName:i,name:o,loaderHook:n})}}async function te({remoteInfo:e,loaderHook:t}){let{entry:n,entryGlobalName:a,name:r,type:s}=e,{entryExports:l}=B(r,a);return l||i.loadScriptNode(n,{attrs:{name:r,globalName:a,type:s},loaderHook:{createScriptHook:(e,n={})=>{let a=t.lifecycle.createScript.emit({url:e,attrs:n});if(a&&"url"in a)return a}}}).then(()=>{let{remoteEntryKey:e,entryExports:t}=B(r,a);return c(t,o.getShortErrorMsg(o.RUNTIME_001,o.runtimeDescMap,{remoteName:r,remoteEntryUrl:n,remoteEntryKey:e})),t}).catch(e=>{throw e})}function tt(e){let{entry:t,name:n}=e;return i.composeKeyWithSeparator(n,t)}async function tn({origin:e,remoteEntryExports:t,remoteInfo:n}){let a=tt(n);if(t)return t;if(!T[a]){let o=e.remoteHandler.hooks.lifecycle.loadEntry,r=e.loaderHook;T[a]=o.emit({loaderHook:r,remoteInfo:n,remoteEntryExports:t}).then(e=>e||(i.isBrowserEnv()?e9({remoteInfo:n,remoteEntryExports:t,loaderHook:r}):te({remoteInfo:n,loaderHook:r})))}return T[a]}function ta(e){return a._extends({},e,{entry:"entry"in e?e.entry:"",type:e.type||W,entryGlobalName:e.entryGlobalName||e.name,shareScope:e.shareScope||G})}let ti=class{async getEntry(){let e;if(this.remoteEntryExports)return this.remoteEntryExports;try{e=await tn({origin:this.host,remoteInfo:this.remoteInfo,remoteEntryExports:this.remoteEntryExports})}catch(n){let t=tt(this.remoteInfo);e=await this.host.loaderHook.lifecycle.loadEntryError.emit({getRemoteEntry:tn,origin:this.host,remoteInfo:this.remoteInfo,remoteEntryExports:this.remoteEntryExports,globalLoading:T,uniqueKey:t})}return c(e,`remoteEntryExports is undefined
${i.safeToString(this.remoteInfo)}`),this.remoteEntryExports=e,this.remoteEntryExports}async get(e,t,n,i){let r,{loadFactory:s=!0}=n||{loadFactory:!0},p=await this.getEntry();if(!this.inited){let t=this.host.shareScopeMap,n=this.remoteInfo.shareScope||"default";t[n]||(t[n]={});let r=t[n],s=[],c={version:this.remoteInfo.version||""};Object.defineProperty(c,"shareScopeMap",{value:t,enumerable:!1});let u=await this.host.hooks.lifecycle.beforeInitContainer.emit({shareScope:r,remoteEntryInitOptions:c,initScope:s,remoteInfo:this.remoteInfo,origin:this.host});void 0===(null==p?void 0:p.init)&&l(o.getShortErrorMsg(o.RUNTIME_002,o.runtimeDescMap,{remoteName:name,remoteEntryUrl:this.remoteInfo.entry,remoteEntryKey:this.remoteInfo.entryGlobalName})),await p.init(u.shareScope,u.initScope,u.remoteEntryInitOptions),await this.host.hooks.lifecycle.initContainer.emit(a._extends({},u,{id:e,remoteSnapshot:i,remoteEntryExports:p}))}this.lib=p,this.inited=!0,(r=await this.host.loaderHook.lifecycle.getModuleFactory.emit({remoteEntryExports:p,expose:t,moduleInfo:this.remoteInfo}))||(r=await p.get(t)),c(r,`${d(this.remoteInfo)} remote don't export ${t}.`);let u=w(this.remoteInfo.name,t),m=this.wraperFactory(r,u);return s?await m():m}wraperFactory(e,t){function n(e,t){e&&"object"==typeof e&&Object.isExtensible(e)&&!Object.getOwnPropertyDescriptor(e,Symbol.for("mf_module_id"))&&Object.defineProperty(e,Symbol.for("mf_module_id"),{value:t,enumerable:!1})}return e instanceof Promise?async()=>{let a=await e();return n(a,t),a}:()=>{let a=e();return n(a,t),a}}constructor({remoteInfo:e,host:t}){this.inited=!1,this.lib=void 0,this.remoteInfo=e,this.host=t}};class to{on(e){"function"==typeof e&&this.listeners.add(e)}once(e){let t=this;this.on(function n(...a){return t.remove(n),e.apply(null,a)})}emit(...e){let t;return this.listeners.size>0&&this.listeners.forEach(n=>{t=n(...e)}),t}remove(e){this.listeners.delete(e)}removeAll(){this.listeners.clear()}constructor(e){this.type="",this.listeners=new Set,e&&(this.type=e)}}class tr extends to{emit(...e){let t,n=Array.from(this.listeners);if(n.length>0){let a=0,i=t=>!1!==t&&(a<n.length?Promise.resolve(n[a++].apply(null,e)).then(i):t);t=i()}return Promise.resolve(t)}}function ts(e,t){if(!x(t))return!1;if(e!==t){for(let n in e)if(!(n in t))return!1}return!0}class tc extends to{emit(e){for(let t of(x(e)||l(`The data for the "${this.type}" hook should be an object.`),this.listeners))try{let n=t(e);if(ts(e,n))e=n;else{this.onerror(`A plugin returned an unacceptable value for the "${this.type}" type.`);break}}catch(e){p(e),this.onerror(e)}return e}constructor(e){super(),this.onerror=l,this.type=e}}class tl extends to{emit(e){x(e)||l(`The response data for the "${this.type}" hook must be an object.`);let t=Array.from(this.listeners);if(t.length>0){let n=0,a=t=>(p(t),this.onerror(t),e),i=o=>{if(ts(e,o)){if(e=o,n<t.length)try{return Promise.resolve(t[n++](e)).then(i,a)}catch(e){return a(e)}}else this.onerror(`A plugin returned an incorrect value for the "${this.type}" type.`);return e};return Promise.resolve(i(e))}return Promise.resolve(e)}constructor(e){super(),this.onerror=l,this.type=e}}class tp{applyPlugin(e){c(g(e),"Plugin configuration is invalid.");let t=e.name;c(t,"A name must be provided by the plugin."),this.registerPlugins[t]||(this.registerPlugins[t]=e,Object.keys(this.lifecycle).forEach(t=>{let n=e[t];n&&this.lifecycle[t].on(n)}))}removePlugin(e){c(e,"A name is required.");let t=this.registerPlugins[e];c(t,`The plugin "${e}" is not registered.`),Object.keys(t).forEach(e=>{"name"!==e&&this.lifecycle[e].remove(t[e])})}inherit({lifecycle:e,registerPlugins:t}){Object.keys(e).forEach(t=>{c(!this.lifecycle[t],`The hook "${t}" has a conflict and cannot be inherited.`),this.lifecycle[t]=e[t]}),Object.keys(t).forEach(e=>{c(!this.registerPlugins[e],`The plugin "${e}" has a conflict and cannot be inherited.`),this.applyPlugin(t[e])})}constructor(e){this.registerPlugins={},this.lifecycle=e,this.lifecycleKeys=Object.keys(e)}}function tu(e){return a._extends({resourceCategory:"sync",share:!0,depsRemote:!0,prefetchInterface:!1},e)}function td(e,t){return t.map(t=>{let n=e6(e,t.nameOrAlias);return c(n,`Unable to preload ${t.nameOrAlias} as it is not included in ${!n&&i.safeToString({remoteInfo:n,remotes:e})}`),{remote:n,preloadConfig:tu(t)}})}function tm(e){return e?e.map(e=>"."===e?e:e.startsWith("./")?e.replace("./",""):e):[]}function tf(e,t,n,a=!0){let{cssAssets:o,jsAssetsWithoutEntry:r,entryAssets:s}=n;if(t.options.inBrowser){if(s.forEach(n=>{let{moduleInfo:a}=n,i=t.moduleCache.get(e.name);i?tn({origin:t,remoteInfo:a,remoteEntryExports:i.remoteEntryExports}):tn({origin:t,remoteInfo:a,remoteEntryExports:void 0})}),a){let e={rel:"preload",as:"style"};o.forEach(n=>{let{link:a,needAttach:o}=i.createLink({url:n,cb:()=>{},attrs:e,createLinkHook:(e,n)=>{let a=t.loaderHook.lifecycle.createLink.emit({url:e,attrs:n});if(a instanceof HTMLLinkElement)return a}});o&&document.head.appendChild(a)})}else{let e={rel:"stylesheet",type:"text/css"};o.forEach(n=>{let{link:a,needAttach:o}=i.createLink({url:n,cb:()=>{},attrs:e,createLinkHook:(e,n)=>{let a=t.loaderHook.lifecycle.createLink.emit({url:e,attrs:n});if(a instanceof HTMLLinkElement)return a},needDeleteLink:!1});o&&document.head.appendChild(a)})}if(a){let e={rel:"preload",as:"script"};r.forEach(n=>{let{link:a,needAttach:o}=i.createLink({url:n,cb:()=>{},attrs:e,createLinkHook:(e,n)=>{let a=t.loaderHook.lifecycle.createLink.emit({url:e,attrs:n});if(a instanceof HTMLLinkElement)return a}});o&&document.head.appendChild(a)})}else{let n={fetchpriority:"high",type:(null==e?void 0:e.type)==="module"?"module":"text/javascript"};r.forEach(e=>{let{script:a,needAttach:o}=i.createScript({url:e,cb:()=>{},attrs:n,createScriptHook:(e,n)=>{let a=t.loaderHook.lifecycle.createScript.emit({url:e,attrs:n});if(a instanceof HTMLScriptElement)return a},needDeleteScript:!0});o&&document.head.appendChild(a)})}}}function th(e,t){let n=E(t);n.url||l(`The attribute remoteEntry of ${e.name} must not be undefined.`);let a=i.getResourceUrl(t,n.url);i.isBrowserEnv()||a.startsWith("http")||(a=`https:${a}`),e.type=n.type,e.entryGlobalName=n.globalName,e.entry=a,e.version=t.version,e.buildVersion=t.buildVersion}function tx(){return{name:"snapshot-plugin",async afterResolve(e){let{remote:t,pkgNameOrAlias:n,expose:i,origin:o,remoteInfo:r}=e;if(!m(t)||!f(t)){let{remoteSnapshot:s,globalSnapshot:c}=await o.snapshotHandler.loadRemoteSnapshotInfo(t);th(r,s);let l={remote:t,preloadConfig:{nameOrAlias:n,exposes:[i],resourceCategory:"sync",share:!1,depsRemote:!1}},p=await o.remoteHandler.hooks.lifecycle.generatePreloadAssets.emit({origin:o,preloadOptions:l,remoteInfo:r,remote:t,remoteSnapshot:s,globalSnapshot:c});return p&&tf(r,o,p,!1),a._extends({},e,{remoteSnapshot:s})}return e}}}function tv(e){let t=e.split(":");return 1===t.length?{name:t[0],version:void 0}:2===t.length?{name:t[0],version:t[1]}:{name:t[1],version:t[2]}}function tg(e,t,n,a,o={},r){let{value:s}=N(e,d(t)),c=r||s;if(c&&!i.isManifestProvider(c)&&(n(c,t,a),c.remotesInfo))for(let t of Object.keys(c.remotesInfo)){if(o[t])continue;o[t]=!0;let a=tv(t),i=c.remotesInfo[t];tg(e,{name:a.name,version:i.matchedVersion},n,!1,o,void 0)}}let ty=(e,t)=>document.querySelector(`${e}[${"link"===e?"href":"src"}="${t}"]`);function tb(e,t,n,a,o){let r=[],s=[],c=[],l=new Set,p=new Set,{options:u}=e,{preloadConfig:d}=t,{depsRemote:m}=d;if(tg(a,n,(t,n,a)=>{let o;if(a)o=d;else if(Array.isArray(m)){let e=m.find(e=>e.nameOrAlias===n.name||e.nameOrAlias===n.alias);if(!e)return;o=tu(e)}else{if(!0!==m)return;o=d}let l=i.getResourceUrl(t,E(t).url);l&&c.push({name:n.name,moduleInfo:{name:n.name,entry:l,type:"remoteEntryType"in t?t.remoteEntryType:"global",entryGlobalName:"globalName"in t?t.globalName:n.name,shareScope:"",version:"version"in t?t.version:void 0},url:l});let p="modules"in t?t.modules:[],u=tm(o.exposes);if(u.length&&"modules"in t){var f;p=null==t||null==(f=t.modules)?void 0:f.reduce((e,t)=>((null==u?void 0:u.indexOf(t.moduleName))!==-1&&e.push(t),e),[])}function h(e){let n=e.map(e=>i.getResourceUrl(t,e));return o.filter?n.filter(o.filter):n}if(p){let a=p.length;for(let i=0;i<a;i++){let a=p[i],c=`${n.name}/${a.moduleName}`;e.remoteHandler.hooks.lifecycle.handlePreloadModule.emit({id:"."===a.moduleName?n.name:c,name:n.name,remoteSnapshot:t,preloadConfig:o,remote:n,origin:e}),H(c)||("all"===o.resourceCategory?(r.push(...h(a.assets.css.async)),r.push(...h(a.assets.css.sync)),s.push(...h(a.assets.js.async))):(o.resourceCategory="sync",r.push(...h(a.assets.css.sync))),s.push(...h(a.assets.js.sync)),q(c))}}},!0,{},o),o.shared){let t=(t,n)=>{let a=eY(e.shareScopeMap,n.sharedName,t,e.sharedHandler.hooks.lifecycle.resolveShare);a&&"function"==typeof a.lib&&(n.assets.js.sync.forEach(e=>{l.add(e)}),n.assets.css.sync.forEach(e=>{p.add(e)}))};o.shared.forEach(e=>{var n;let a=null==(n=u.shared)?void 0:n[e.sharedName];if(!a)return;let i=e.version?a.find(t=>t.version===e.version):a;i&&b(i).forEach(n=>{t(n,e)})})}let f=s.filter(e=>!l.has(e)&&!ty("script",e));return{cssAssets:r.filter(e=>!p.has(e)&&!ty("link",e)),jsAssetsWithoutEntry:f,entryAssets:c.filter(e=>!ty("script",e.url))}}let tE=function(){return{name:"generate-preload-assets-plugin",async generatePreloadAssets(e){let{origin:t,preloadOptions:n,remoteInfo:a,remote:o,globalSnapshot:r,remoteSnapshot:s}=e;return i.isBrowserEnv()?m(o)&&f(o)?{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[{name:o.name,url:o.entry,moduleInfo:{name:a.name,entry:o.entry,type:a.type||"global",entryGlobalName:"",shareScope:""}}]}:(th(a,s),tb(t,n,a,r,s)):{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[]}}}};function tw(e,t){let n=P({name:t.options.name,version:t.options.version}),a=n&&"remotesInfo"in n&&n.remotesInfo&&N(n.remotesInfo,e.name).value;return a&&a.matchedVersion?{hostGlobalSnapshot:n,globalSnapshot:j(),remoteSnapshot:P({name:e.name,version:a.matchedVersion})}:{hostGlobalSnapshot:void 0,globalSnapshot:j(),remoteSnapshot:P({name:e.name,version:"version"in e?e.version:void 0})}}class t_{async loadSnapshot(e){let{options:t}=this.HostInstance,{hostGlobalSnapshot:n,remoteSnapshot:a,globalSnapshot:i}=this.getGlobalRemoteInfo(e),{remoteSnapshot:o,globalSnapshot:r}=await this.hooks.lifecycle.loadSnapshot.emit({options:t,moduleInfo:e,hostGlobalSnapshot:n,remoteSnapshot:a,globalSnapshot:i});return{remoteSnapshot:o,globalSnapshot:r}}async loadRemoteSnapshotInfo(e){let t,n,{options:r}=this.HostInstance;await this.hooks.lifecycle.beforeLoadRemoteSnapshot.emit({options:r,moduleInfo:e});let s=P({name:this.HostInstance.options.name,version:this.HostInstance.options.version});s||(s={version:this.HostInstance.options.version||"",remoteEntry:"",remotesInfo:{}},U({[this.HostInstance.options.name]:s})),s&&"remotesInfo"in s&&!N(s.remotesInfo,e.name).value&&("version"in e||"entry"in e)&&(s.remotesInfo=a._extends({},null==s?void 0:s.remotesInfo,{[e.name]:{matchedVersion:"version"in e?e.version:e.entry}}));let{hostGlobalSnapshot:c,remoteSnapshot:p,globalSnapshot:u}=this.getGlobalRemoteInfo(e),{remoteSnapshot:d,globalSnapshot:f}=await this.hooks.lifecycle.loadSnapshot.emit({options:r,moduleInfo:e,hostGlobalSnapshot:c,remoteSnapshot:p,globalSnapshot:u});if(d)if(i.isManifestProvider(d)){let o=i.isBrowserEnv()?d.remoteEntry:d.ssrRemoteEntry||d.remoteEntry||"",r=await this.getManifestJson(o,e,{}),s=M(a._extends({},e,{entry:o}),r);t=r,n=s}else{let{remoteSnapshot:a}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:d,from:"global"});t=a,n=f}else if(m(e)){let a=await this.getManifestJson(e.entry,e,{}),i=M(e,a),{remoteSnapshot:o}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:a,from:"global"});t=o,n=i}else l(o.getShortErrorMsg(o.RUNTIME_007,o.runtimeDescMap,{hostName:e.name,hostVersion:e.version,globalSnapshot:JSON.stringify(f)}));return await this.hooks.lifecycle.afterLoadSnapshot.emit({options:r,moduleInfo:e,remoteSnapshot:t}),{remoteSnapshot:t,globalSnapshot:n}}getGlobalRemoteInfo(e){return tw(e,this.HostInstance)}async getManifestJson(e,t,n){let a=async()=>{let n=this.manifestCache.get(e);if(n)return n;try{let t=await this.loaderHook.lifecycle.fetch.emit(e,{});t&&t instanceof Response||(t=await fetch(e,{})),n=await t.json()}catch(a){(n=await this.HostInstance.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:a,from:"runtime",lifecycle:"afterResolve",origin:this.HostInstance}))||(delete this.manifestLoading[e],l(o.getShortErrorMsg(o.RUNTIME_003,o.runtimeDescMap,{manifestUrl:e,moduleName:t.name},`${a}`)))}return c(n.metaData&&n.exposes&&n.shared,`${e} is not a federation manifest`),this.manifestCache.set(e,n),n},r=async()=>{let n=await a(),o=i.generateSnapshotFromManifest(n,{version:e}),{remoteSnapshot:r}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:t,manifestJson:n,remoteSnapshot:o,manifestUrl:e,from:"manifest"});return r};return this.manifestLoading[e]||(this.manifestLoading[e]=r().then(e=>e)),this.manifestLoading[e]}constructor(e){this.loadingHostSnapshot=null,this.manifestCache=new Map,this.hooks=new tp({beforeLoadRemoteSnapshot:new tr("beforeLoadRemoteSnapshot"),loadSnapshot:new tl("loadGlobalSnapshot"),loadRemoteSnapshot:new tl("loadRemoteSnapshot"),afterLoadSnapshot:new tl("afterLoadSnapshot")}),this.manifestLoading=R.__FEDERATION__.__MANIFEST_LOADING__,this.HostInstance=e,this.loaderHook=e.loaderHook}}class tS{registerShared(e,t){let{shareInfos:n,shared:a}=eq(e,t);return Object.keys(n).forEach(e=>{n[e].forEach(n=>{!eY(this.shareScopeMap,e,n,this.hooks.lifecycle.resolveShare)&&n&&n.lib&&this.setShared({pkgName:e,lib:n.lib,get:n.get,loaded:!0,shared:n,from:t.name})})}),{shareInfos:n,shared:a}}async loadShare(e,t){let{host:n}=this,a=e0({pkgName:e,extraOptions:t,shareInfos:n.options.shared});(null==a?void 0:a.scope)&&await Promise.all(a.scope.map(async e=>{await Promise.all(this.initializeSharing(e,{strategy:a.strategy}))}));let{shareInfo:i}=await this.hooks.lifecycle.beforeLoadShare.emit({pkgName:e,shareInfo:a,shared:n.options.shared,origin:n});c(i,`Cannot find ${e} Share in the ${n.options.name}. Please ensure that the ${e} Share parameters have been injected`);let o=eY(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare),r=e=>{e.useIn||(e.useIn=[]),u(e.useIn,n.options.name)};if(o&&o.lib)return r(o),o.lib;if(o&&o.loading&&!o.loaded){let e=await o.loading;return o.loaded=!0,o.lib||(o.lib=e),r(o),e}if(o){let t=(async()=>{let t=await o.get();i.lib=t,i.loaded=!0,r(i);let n=eY(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare);return n&&(n.lib=t,n.loaded=!0),t})();return this.setShared({pkgName:e,loaded:!1,shared:o,from:n.options.name,lib:null,loading:t}),t}{if(null==t?void 0:t.customShareInfo)return!1;let a=(async()=>{let t=await i.get();i.lib=t,i.loaded=!0,r(i);let n=eY(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare);return n&&(n.lib=t,n.loaded=!0),t})();return this.setShared({pkgName:e,loaded:!1,shared:i,from:n.options.name,lib:null,loading:a}),a}}initializeSharing(e=G,t){let{host:n}=this,a=null==t?void 0:t.from,i=null==t?void 0:t.strategy,o=null==t?void 0:t.initScope,r=[];if("build"!==a){let{initTokens:t}=this;o||(o=[]);let n=t[e];if(n||(n=t[e]={from:this.host.name}),o.indexOf(n)>=0)return r;o.push(n)}let s=this.shareScopeMap,c=n.options.name;s[e]||(s[e]={});let l=s[e],p=(e,t)=>{var n;let{version:a,eager:i}=t;l[e]=l[e]||{};let o=l[e],r=o[a],s=!!(r&&(r.eager||(null==(n=r.shareConfig)?void 0:n.eager)));(!r||"loaded-first"!==r.strategy&&!r.loaded&&(!i!=!s?i:c>r.from))&&(o[a]=t)},u=t=>t&&t.init&&t.init(s[e],o),d=async e=>{let{module:t}=await n.remoteHandler.getRemoteModuleAndOptions({id:e});if(t.getEntry){let a;try{a=await t.getEntry()}catch(t){a=await n.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:t,from:"runtime",lifecycle:"beforeLoadShare",origin:n})}t.inited||(await u(a),t.inited=!0)}};return Object.keys(n.options.shared).forEach(t=>{n.options.shared[t].forEach(n=>{n.scope.includes(e)&&p(t,n)})}),("version-first"===n.options.shareStrategy||"version-first"===i)&&n.options.remotes.forEach(t=>{t.shareScope===e&&r.push(d(t.name))}),r}loadShareSync(e,t){let{host:n}=this,a=e0({pkgName:e,extraOptions:t,shareInfos:n.options.shared});(null==a?void 0:a.scope)&&a.scope.forEach(e=>{this.initializeSharing(e,{strategy:a.strategy})});let i=eY(this.shareScopeMap,e,a,this.hooks.lifecycle.resolveShare),r=e=>{e.useIn||(e.useIn=[]),u(e.useIn,n.options.name)};if(i){if("function"==typeof i.lib)return r(i),i.loaded||(i.loaded=!0,i.from===n.options.name&&(a.loaded=!0)),i.lib;if("function"==typeof i.get){let t=i.get();if(!(t instanceof Promise))return r(i),this.setShared({pkgName:e,loaded:!0,from:n.options.name,lib:t,shared:i}),t}}if(a.lib)return a.loaded||(a.loaded=!0),a.lib;if(a.get){let i=a.get();if(i instanceof Promise){let a=(null==t?void 0:t.from)==="build"?o.RUNTIME_005:o.RUNTIME_006;throw Error(o.getShortErrorMsg(a,o.runtimeDescMap,{hostName:n.options.name,sharedPkgName:e}))}return a.lib=i,this.setShared({pkgName:e,loaded:!0,from:n.options.name,lib:a.lib,shared:a}),a.lib}throw Error(o.getShortErrorMsg(o.RUNTIME_006,o.runtimeDescMap,{hostName:n.options.name,sharedPkgName:e}))}initShareScopeMap(e,t,n={}){let{host:a}=this;this.shareScopeMap[e]=t,this.hooks.lifecycle.initContainerShareScopeMap.emit({shareScope:t,options:a.options,origin:a,scopeName:e,hostShareScopeMap:n.hostShareScopeMap})}setShared({pkgName:e,shared:t,from:n,lib:i,loading:o,loaded:r,get:s}){let{version:c,scope:l="default"}=t,p=a._object_without_properties_loose(t,["version","scope"]);(Array.isArray(l)?l:[l]).forEach(t=>{if(this.shareScopeMap[t]||(this.shareScopeMap[t]={}),this.shareScopeMap[t][e]||(this.shareScopeMap[t][e]={}),!this.shareScopeMap[t][e][c]){this.shareScopeMap[t][e][c]=a._extends({version:c,scope:["default"]},p,{lib:i,loaded:r,loading:o}),s&&(this.shareScopeMap[t][e][c].get=s);return}let n=this.shareScopeMap[t][e][c];o&&!n.loading&&(n.loading=o)})}_setGlobalShareScopeMap(e){let t=eQ(),n=e.id||e.name;n&&!t[n]&&(t[n]=this.shareScopeMap)}constructor(e){this.hooks=new tp({afterResolve:new tl("afterResolve"),beforeLoadShare:new tl("beforeLoadShare"),loadShare:new tr,resolveShare:new tc("resolveShare"),initContainerShareScopeMap:new tc("initContainerShareScopeMap")}),this.host=e,this.shareScopeMap={},this.initTokens={},this._setGlobalShareScopeMap(e.options)}}class tR{formatAndRegisterRemote(e,t){return(t.remotes||[]).reduce((e,t)=>(this.registerRemote(t,e,{force:!1}),e),e.remotes)}setIdToRemoteMap(e,t){let{remote:n,expose:a}=t,{name:i,alias:o}=n;if(this.idToRemoteMap[e]={name:n.name,expose:a},o&&e.startsWith(i)){let t=e.replace(i,o);this.idToRemoteMap[t]={name:n.name,expose:a};return}if(o&&e.startsWith(o)){let t=e.replace(o,i);this.idToRemoteMap[t]={name:n.name,expose:a}}}async loadRemote(e,t){let{host:n}=this;try{let{loadFactory:a=!0}=t||{loadFactory:!0},{module:i,moduleOptions:o,remoteMatchInfo:r}=await this.getRemoteModuleAndOptions({id:e}),{pkgNameOrAlias:s,remote:c,expose:l,id:p,remoteSnapshot:u}=r,d=await i.get(p,l,t,u),m=await this.hooks.lifecycle.onLoad.emit({id:p,pkgNameOrAlias:s,expose:l,exposeModule:a?d:void 0,exposeModuleFactory:a?void 0:d,remote:c,options:o,moduleInstance:i,origin:n});if(this.setIdToRemoteMap(e,r),"function"==typeof m)return m;return d}catch(o){let{from:a="runtime"}=t||{from:"runtime"},i=await this.hooks.lifecycle.errorLoadRemote.emit({id:e,error:o,from:a,lifecycle:"onLoad",origin:n});if(!i)throw o;return i}}async preloadRemote(e){let{host:t}=this;await this.hooks.lifecycle.beforePreloadRemote.emit({preloadOps:e,options:t.options,origin:t});let n=td(t.options.remotes,e);await Promise.all(n.map(async e=>{let{remote:n}=e,a=ta(n),{globalSnapshot:i,remoteSnapshot:o}=await t.snapshotHandler.loadRemoteSnapshotInfo(n),r=await this.hooks.lifecycle.generatePreloadAssets.emit({origin:t,preloadOptions:e,remote:n,remoteInfo:a,globalSnapshot:i,remoteSnapshot:o});r&&tf(a,t,r)}))}registerRemotes(e,t){let{host:n}=this;e.forEach(e=>{this.registerRemote(e,n.options.remotes,{force:null==t?void 0:t.force})})}async getRemoteModuleAndOptions(e){let t,{host:n}=this,{id:i}=e;try{t=await this.hooks.lifecycle.beforeRequest.emit({id:i,options:n.options,origin:n})}catch(e){if(!(t=await this.hooks.lifecycle.errorLoadRemote.emit({id:i,options:n.options,origin:n,from:"runtime",error:e,lifecycle:"beforeRequest"})))throw e}let{id:r}=t,s=e3(n.options.remotes,r);c(s,o.getShortErrorMsg(o.RUNTIME_004,o.runtimeDescMap,{hostName:n.options.name,requestId:r}));let{remote:l}=s,p=ta(l),u=await n.sharedHandler.hooks.lifecycle.afterResolve.emit(a._extends({id:r},s,{options:n.options,origin:n,remoteInfo:p})),{remote:d,expose:m}=u;c(d&&m,`The 'beforeRequest' hook was executed, but it failed to return the correct 'remote' and 'expose' values while loading ${r}.`);let f=n.moduleCache.get(d.name),h={host:n,remoteInfo:p};return f||(f=new ti(h),n.moduleCache.set(d.name,f)),{module:f,moduleOptions:h,remoteMatchInfo:u}}registerRemote(e,t,n){let{host:a}=this,o=()=>{if(e.alias){let n=t.find(t=>{var n;return e.alias&&(t.name.startsWith(e.alias)||(null==(n=t.alias)?void 0:n.startsWith(e.alias)))});c(!n,`The alias ${e.alias} of remote ${e.name} is not allowed to be the prefix of ${n&&n.name} name or alias`)}"entry"in e&&i.isBrowserEnv()&&!e.entry.startsWith("http")&&(e.entry=new URL(e.entry,window.location.origin).href),e.shareScope||(e.shareScope=G),e.type||(e.type=W)};this.hooks.lifecycle.beforeRegisterRemote.emit({remote:e,origin:a});let r=t.find(t=>t.name===e.name);if(r){let s=[`The remote "${e.name}" is already registered.`,"Please note that overriding it may cause unexpected errors."];(null==n?void 0:n.force)&&(this.removeRemote(r),o(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:a}),i.warn(s.join(" ")))}else o(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:a})}removeRemote(e){try{let{host:n}=this,{name:a}=e,o=n.options.remotes.findIndex(e=>e.name===a);-1!==o&&n.options.remotes.splice(o,1);let r=n.moduleCache.get(e.name);if(r){let a=r.remoteInfo,o=a.entryGlobalName;if(_[o]){var t;(null==(t=Object.getOwnPropertyDescriptor(_,o))?void 0:t.configurable)?delete _[o]:_[o]=void 0}let s=tt(r.remoteInfo);T[s]&&delete T[s],n.snapshotHandler.manifestCache.delete(a.entry);let c=a.buildVersion?i.composeKeyWithSeparator(a.name,a.buildVersion):a.name,l=_.__FEDERATION__.__INSTANCES__.findIndex(e=>a.buildVersion?e.options.id===c:e.name===c);if(-1!==l){let e=_.__FEDERATION__.__INSTANCES__[l];c=e.options.id||c;let t=eQ(),n=!0,i=[];Object.keys(t).forEach(e=>{let o=t[e];o&&Object.keys(o).forEach(t=>{let r=o[t];r&&Object.keys(r).forEach(o=>{let s=r[o];s&&Object.keys(s).forEach(r=>{let c=s[r];c&&"object"==typeof c&&c.from===a.name&&(c.loaded||c.loading?(c.useIn=c.useIn.filter(e=>e!==a.name),c.useIn.length?n=!1:i.push([e,t,o,r])):i.push([e,t,o,r]))})})})}),n&&(e.shareScopeMap={},delete t[c]),i.forEach(([e,n,a,i])=>{var o,r,s;null==(s=t[e])||null==(r=s[n])||null==(o=r[a])||delete o[i]}),_.__FEDERATION__.__INSTANCES__.splice(l,1)}let{hostGlobalSnapshot:p}=tw(e,n);if(p){let t=p&&"remotesInfo"in p&&p.remotesInfo&&N(p.remotesInfo,e.name).key;t&&(delete p.remotesInfo[t],R.__FEDERATION__.__MANIFEST_LOADING__[t]&&delete R.__FEDERATION__.__MANIFEST_LOADING__[t])}n.moduleCache.delete(e.name)}}catch(e){s.log("removeRemote fail: ",e)}}constructor(e){this.hooks=new tp({beforeRegisterRemote:new tc("beforeRegisterRemote"),registerRemote:new tc("registerRemote"),beforeRequest:new tl("beforeRequest"),onLoad:new tr("onLoad"),handlePreloadModule:new to("handlePreloadModule"),errorLoadRemote:new tr("errorLoadRemote"),beforePreloadRemote:new tr("beforePreloadRemote"),generatePreloadAssets:new tr("generatePreloadAssets"),afterPreloadRemote:new tr,loadEntry:new tr}),this.host=e,this.idToRemoteMap={}}}class tO{initOptions(e){this.registerPlugins(e.plugins);let t=this.formatOptions(this.options,e);return this.options=t,t}async loadShare(e,t){return this.sharedHandler.loadShare(e,t)}loadShareSync(e,t){return this.sharedHandler.loadShareSync(e,t)}initializeSharing(e=G,t){return this.sharedHandler.initializeSharing(e,t)}initRawContainer(e,t,n){let a=new ti({host:this,remoteInfo:ta({name:e,entry:t})});return a.remoteEntryExports=n,this.moduleCache.set(e,a),a}async loadRemote(e,t){return this.remoteHandler.loadRemote(e,t)}async preloadRemote(e){return this.remoteHandler.preloadRemote(e)}initShareScopeMap(e,t,n={}){this.sharedHandler.initShareScopeMap(e,t,n)}formatOptions(e,t){let{shared:n}=eq(e,t),{userOptions:i,options:o}=this.hooks.lifecycle.beforeInit.emit({origin:this,userOptions:t,options:e,shareInfo:n}),r=this.remoteHandler.formatAndRegisterRemote(o,i),{shared:s}=this.sharedHandler.registerShared(o,i),c=[...o.plugins];i.plugins&&i.plugins.forEach(e=>{c.includes(e)||c.push(e)});let l=a._extends({},e,t,{plugins:c,remotes:r,shared:s});return this.hooks.lifecycle.init.emit({origin:this,options:l}),l}registerPlugins(e){let t=e4(e,[this.hooks,this.remoteHandler.hooks,this.sharedHandler.hooks,this.snapshotHandler.hooks,this.loaderHook,this.bridgeHook]);this.options.plugins=this.options.plugins.reduce((e,t)=>(t&&e&&!e.find(e=>e.name===t.name)&&e.push(t),e),t||[])}registerRemotes(e,t){return this.remoteHandler.registerRemotes(e,t)}constructor(e){this.hooks=new tp({beforeInit:new tc("beforeInit"),init:new to,beforeInitContainer:new tl("beforeInitContainer"),initContainer:new tl("initContainer")}),this.version="0.11.2",this.moduleCache=new Map,this.loaderHook=new tp({getModuleInfo:new to,createScript:new to,createLink:new to,fetch:new tr,loadEntryError:new tr,getModuleFactory:new tr}),this.bridgeHook=new tp({beforeBridgeRender:new to,afterBridgeRender:new to,beforeBridgeDestroy:new to,afterBridgeDestroy:new to});let t={id:e2(),name:e.name,plugins:[tx(),tE()],remotes:[],shared:{},inBrowser:i.isBrowserEnv()};this.name=e.name,this.options=t,this.snapshotHandler=new t_(this),this.sharedHandler=new tS(this),this.remoteHandler=new tR(this),this.shareScopeMap=this.sharedHandler.shareScopeMap,this.registerPlugins([...t.plugins,...e.plugins||[]]),this.options=this.formatOptions(t,e)}}var tI=Object.freeze({__proto__:null});Object.defineProperty(t,"loadScript",{enumerable:!0,get:function(){return i.loadScript}}),Object.defineProperty(t,"loadScriptNode",{enumerable:!0,get:function(){return i.loadScriptNode}}),t.CurrentGlobal=_,t.FederationHost=tO,t.Global=R,t.Module=ti,t.addGlobalSnapshot=U,t.assert=c,t.getGlobalFederationConstructor=A,t.getGlobalSnapshot=j,t.getInfoWithoutType=N,t.getRegisteredShare=eY,t.getRemoteEntry=tn,t.getRemoteInfo=ta,t.helpers=e1,t.isStaticResourcesEqual=y,t.matchRemoteWithNameAndExpose=e3,t.registerGlobalPlugins=$,t.resetFederationGlobalInfo=D,t.safeWrapper=h,t.satisfy=ez,t.setGlobalFederationConstructor=L,t.setGlobalFederationInstance=k,t.types=tI},2335:function(e,t){"use strict";function n(){return(n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e}).apply(this,arguments)}function a(e,t){if(null==e)return{};var n,a,i={},o=Object.keys(e);for(a=0;a<o.length;a++)n=o[a],t.indexOf(n)>=0||(i[n]=e[n]);return i}t._extends=n,t._object_without_properties_loose=a},5851:function(__unused_webpack_module,exports,__webpack_require__){"use strict";var polyfills=__webpack_require__(2512);let FederationModuleManifest="federation-manifest.json",MANIFEST_EXT=".json",BROWSER_LOG_KEY="FEDERATION_DEBUG",BROWSER_LOG_VALUE="1",NameTransformSymbol={AT:"@",HYPHEN:"-",SLASH:"/"},NameTransformMap={[NameTransformSymbol.AT]:"scope_",[NameTransformSymbol.HYPHEN]:"_",[NameTransformSymbol.SLASH]:"__"},EncodedNameTransformMap={[NameTransformMap[NameTransformSymbol.AT]]:NameTransformSymbol.AT,[NameTransformMap[NameTransformSymbol.HYPHEN]]:NameTransformSymbol.HYPHEN,[NameTransformMap[NameTransformSymbol.SLASH]]:NameTransformSymbol.SLASH},SEPARATOR=":",ManifestFileName="mf-manifest.json",StatsFileName="mf-stats.json",MFModuleType={NPM:"npm",APP:"app"},MODULE_DEVTOOL_IDENTIFIER="__MF_DEVTOOLS_MODULE_INFO__",ENCODE_NAME_PREFIX="ENCODE_NAME_PREFIX",TEMP_DIR=".federation",MFPrefetchCommon={identifier:"MFDataPrefetch",globalKey:"__PREFETCH__",library:"mf-data-prefetch",exportsKey:"__PREFETCH_EXPORTS__",fileName:"bootstrap.js"};var ContainerPlugin=Object.freeze({__proto__:null}),ContainerReferencePlugin=Object.freeze({__proto__:null}),ModuleFederationPlugin=Object.freeze({__proto__:null}),SharePlugin=Object.freeze({__proto__:null});function isBrowserEnv(){return"undefined"!=typeof window&&void 0!==window.document}function isReactNativeEnv(){var e;return"undefined"!=typeof navigator&&(null==(e=navigator)?void 0:e.product)==="ReactNative"}function isBrowserDebug(){try{if(isBrowserEnv()&&window.localStorage)return localStorage.getItem(BROWSER_LOG_KEY)===BROWSER_LOG_VALUE}catch(e){}return!1}function isDebugMode(){return"undefined"!=typeof process&&process.env&&process.env.FEDERATION_DEBUG?!!process.env.FEDERATION_DEBUG:!!("undefined"!=typeof FEDERATION_DEBUG&&FEDERATION_DEBUG)||isBrowserDebug()}let getProcessEnv=function(){return"undefined"!=typeof process&&process.env?process.env:{}},LOG_CATEGORY="[ Federation Runtime ]",parseEntry=(e,t,n=SEPARATOR)=>{let a=e.split(n),i="development"===getProcessEnv().NODE_ENV&&t,o="*",r=e=>e.startsWith("http")||e.includes(MANIFEST_EXT);if(a.length>=2){let[t,...s]=a;e.startsWith(n)&&(t=a.slice(0,2).join(n),s=[i||a.slice(2).join(n)]);let c=i||s.join(n);return r(c)?{name:t,entry:c}:{name:t,version:c||o}}if(1===a.length){let[e]=a;return i&&r(i)?{name:e,entry:i}:{name:e,version:i||o}}throw`Invalid entry value: ${e}`},composeKeyWithSeparator=function(...e){return e.length?e.reduce((e,t)=>t?e?`${e}${SEPARATOR}${t}`:t:e,""):""},encodeName=function(e,t="",n=!1){try{let a=n?".js":"";return`${t}${e.replace(RegExp(`${NameTransformSymbol.AT}`,"g"),NameTransformMap[NameTransformSymbol.AT]).replace(RegExp(`${NameTransformSymbol.HYPHEN}`,"g"),NameTransformMap[NameTransformSymbol.HYPHEN]).replace(RegExp(`${NameTransformSymbol.SLASH}`,"g"),NameTransformMap[NameTransformSymbol.SLASH])}${a}`}catch(e){throw e}},decodeName=function(e,t,n){try{let a=e;if(t){if(!a.startsWith(t))return a;a=a.replace(RegExp(t,"g"),"")}return a=a.replace(RegExp(`${NameTransformMap[NameTransformSymbol.AT]}`,"g"),EncodedNameTransformMap[NameTransformMap[NameTransformSymbol.AT]]).replace(RegExp(`${NameTransformMap[NameTransformSymbol.SLASH]}`,"g"),EncodedNameTransformMap[NameTransformMap[NameTransformSymbol.SLASH]]).replace(RegExp(`${NameTransformMap[NameTransformSymbol.HYPHEN]}`,"g"),EncodedNameTransformMap[NameTransformMap[NameTransformSymbol.HYPHEN]]),n&&(a=a.replace(".js","")),a}catch(e){throw e}},generateExposeFilename=(e,t)=>{if(!e)return"";let n=e;return"."===n&&(n="default_export"),n.startsWith("./")&&(n=n.replace("./","")),encodeName(n,"__federation_expose_",t)},generateShareFilename=(e,t)=>e?encodeName(e,"__federation_shared_",t):"",getResourceUrl=(e,t)=>{if("getPublicPath"in e){let n;return n=e.getPublicPath.startsWith("function")?Function("return "+e.getPublicPath)()():Function(e.getPublicPath)(),`${n}${t}`}return"publicPath"in e?`${e.publicPath}${t}`:(console.warn("Cannot get resource URL. If in debug mode, please ignore.",e,t),"")},assert=(e,t)=>{e||