@rimori/playwright-testing 0.3.29 → 0.3.30-next.1
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/README.md +4 -4
- package/dist/core/MessageChannelSimulator.js +2 -2
- package/dist/core/RimoriTestEnvironment.d.ts +1 -1
- package/dist/core/RimoriTestEnvironment.js +3 -3
- package/dist/harness/__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_client__loadShare__.mjs.js +3 -3
- package/dist/harness/__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_react_mf_2_client__loadShare__.mjs.js +40 -40
- package/dist/harness/__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare__react_mf_2_dom_mf_1_client__loadShare__.mjs.js +1 -1
- package/dist/harness/hostInit.js +1 -1
- package/dist/harness/index.html +0 -2
- package/dist/harness/index.js +1 -1
- package/dist/harness/localSharedImportMap.js +1 -1
- package/dist/harness/remoteEntry.js +1 -2
- package/dist/harness/virtual_mf-REMOTE_ENTRY_ID___mfe_internal__rimori-scenario-host__remoteEntry-_hash_.js +4 -0
- package/package.json +4 -4
- package/dist/harness/dist.js +0 -4
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import{t as e}from"./preload-helper.js";var t=`FEDERATION_DEBUG`,n={AT:`@`,HYPHEN:`-`,SLASH:`/`},r={[n.AT]:`scope_`,[n.HYPHEN]:`_`,[n.SLASH]:`__`};r[n.AT],n.AT,r[n.HYPHEN],n.HYPHEN,r[n.SLASH],n.SLASH;var i=function(e){return e[e.UNKNOWN=1]=`UNKNOWN`,e[e.CALCULATED=2]=`CALCULATED`,e[e.NO_USE=0]=`NO_USE`,e}({});function a(){return!0}function o(){return typeof navigator<`u`&&navigator?.product===`ReactNative`}function s(){try{if(a()&&window.localStorage)return!!localStorage.getItem(t)}catch{return!1}return!1}function c(){return typeof process<`u`&&{}.FEDERATION_DEBUG?!!{}.FEDERATION_DEBUG:typeof FEDERATION_DEBUG<`u`&&FEDERATION_DEBUG?!0:s()}var l=`[ Federation Runtime ]`,u=function(...e){return e.length?e.reduce((e,t)=>t?e?`${e}:${t}`:t:e,``):``},d=(e,t)=>{if(`getPublicPath`in e){let n;return n=e.getPublicPath.startsWith(`function`)?Function(`return `+e.getPublicPath)()():Function(e.getPublicPath)(),`${n}${t}`}else if(`publicPath`in e)return!a()&&!o()&&`ssrPublicPath`in e&&typeof e.ssrPublicPath==`string`?`${e.ssrPublicPath}${t}`:`${e.publicPath}${t}`;else return console.warn(`Cannot get resource URL. If in debug mode, please ignore.`,e,t),``},f=e=>{console.warn(`${l}: ${e}`)};function p(e){try{return JSON.stringify(e,null,2)}catch{return``}}var m=(e,t)=>{if(!e)return t;let n=(e=>{if(e===`.`)return``;if(e.startsWith(`./`))return e.replace(`./`,``);if(e.startsWith(`/`)){let t=e.slice(1);return t.endsWith(`/`)?t.slice(0,-1):t}return e})(e);return n?n.endsWith(`/`)?`${n}${t}`:`${n}/${t}`:t};function ee(e){return e.replace(/#.*$/,``).replace(/\?.*$/,``).replace(/\/[^\/]+$/,`/`)}function te(e,t={}){let{remotes:n={},overrides:r={},version:i}=t,a,o=()=>`publicPath`in e.metaData?(e.metaData.publicPath===`auto`||e.metaData.publicPath===``)&&i?ee(i):e.metaData.publicPath:e.metaData.getPublicPath,s=Object.keys(r),c={};Object.keys(n).length||(c=e.remotes?.reduce((e,t)=>{let n,i=t.federationContainerName;return n=s.includes(i)?r[i]:`version`in t?t.version:t.entry,e[i]={matchedVersion:n},e},{})||{}),Object.keys(n).forEach(e=>c[e]={matchedVersion:s.includes(e)?r[e]:n[e]});let{remoteEntry:{path:l,name:u,type:d},types:f={path:``,name:``,zip:``,api:``},buildInfo:{buildVersion:p},globalName:te,ssrRemoteEntry:h}=e.metaData,{exposes:ne}=e,g={version:i||``,buildVersion:p,globalName:te,remoteEntry:m(l,u),remoteEntryType:d,remoteTypes:m(f.path,f.name),remoteTypesZip:f.zip||``,remoteTypesAPI:f.api||``,remotesInfo:c,shared:e?.shared.map(e=>({assets:e.assets,sharedName:e.name,version:e.version,usedExports:e.referenceExports||[]})),modules:ne?.map(e=>({moduleName:e.name,modulePath:e.path,assets:e.assets}))};if(e.metaData?.prefetchInterface){let t=e.metaData.prefetchInterface;g={...g,prefetchInterface:t}}if(e.metaData?.prefetchEntry){let{path:t,name:n,type:r}=e.metaData.prefetchEntry;g={...g,prefetchEntry:m(t,n),prefetchEntryType:r}}if(`publicPath`in e.metaData?(a={...g,publicPath:o()},typeof e.metaData.ssrPublicPath==`string`&&(a.ssrPublicPath=e.metaData.ssrPublicPath)):a={...g,getPublicPath:o()},h){let e=m(h.path,h.name);a.ssrRemoteEntry=e,a.ssrRemoteEntryType=h.type||`commonjs-module`}return a}function h(e){return!!(`remoteEntry`in e&&e.remoteEntry.includes(`.json`))}var ne=`[ Module Federation ]`,g=console,re=[`logger.ts`,`logger.js`,`captureStackTrace`,`Logger.emit`,`Logger.log`,`Logger.info`,`Logger.warn`,`Logger.error`,`Logger.debug`];function ie(){try{let e=Error().stack;if(!e)return;let[,...t]=e.split(`
|
|
2
|
+
`),n=t.filter(e=>!re.some(t=>e.includes(t)));return n.length?`Stack trace:\n${n.slice(0,5).join(`
|
|
3
|
+
`)}`:void 0}catch{return}}var ae=class{constructor(e,t=g){this.prefix=e,this.delegate=t??g}setPrefix(e){this.prefix=e}setDelegate(e){this.delegate=e??g}emit(e,t){let n=this.delegate,r=c()?ie():void 0,i=r?[...t,r]:t,a=(()=>{switch(e){case`log`:return[`log`,`info`];case`info`:return[`info`,`log`];case`warn`:return[`warn`,`info`,`log`];case`error`:return[`error`,`warn`,`log`];default:return[`debug`,`log`]}})();for(let e of a){let t=n[e];if(typeof t==`function`){t.call(n,this.prefix,...i);return}}for(let e of a){let t=g[e];if(typeof t==`function`){t.call(g,this.prefix,...i);return}}}log(...e){this.emit(`log`,e)}warn(...e){this.emit(`warn`,e)}error(...e){this.emit(`error`,e)}success(...e){this.emit(`info`,e)}info(...e){this.emit(`info`,e)}ready(...e){this.emit(`info`,e)}debug(...e){c()&&this.emit(`debug`,e)}};function oe(e){return new ae(e)}function se(e){let t=new ae(e);return Object.defineProperty(t,`__mf_infrastructure_logger__`,{value:!0,enumerable:!1,configurable:!1}),t}oe(ne),se(ne);async function ce(e,t){try{return await e()}catch(e){!t&&f(e);return}}function le(e,t){let n=/^(https?:)?\/\//i;return e.replace(n,``).replace(/\/$/,``)===t.replace(n,``).replace(/\/$/,``)}function ue(e){let t=null,n=!0,r=2e4,i,a=document.getElementsByTagName(`script`);for(let r=0;r<a.length;r++){let i=a[r],o=i.getAttribute(`src`);if(o&&le(o,e.url)){t=i,n=!1;break}}if(!t){let n=e.attrs;t=document.createElement(`script`),t.type=n?.type===`module`?`module`:`text/javascript`;let i;e.createScriptHook&&(i=e.createScriptHook(e.url,e.attrs),i instanceof HTMLScriptElement?t=i:typeof i==`object`&&(`script`in i&&i.script&&(t=i.script),`timeout`in i&&i.timeout&&(r=i.timeout))),t.src||=e.url,n&&!i&&Object.keys(n).forEach(e=>{t&&(e===`async`||e===`defer`?t[e]=n[e]:t.getAttribute(e)||t.setAttribute(e,n[e]))})}let o=null,s=typeof window<`u`?t=>{if(t.filename&&le(t.filename,e.url)){let n=Error(`ScriptExecutionError: Script "${e.url}" loaded but threw a runtime error during execution: ${t.message} (${t.filename}:${t.lineno}:${t.colno})`);n.name=`ScriptExecutionError`,o=n}}:null;s&&window.addEventListener(`error`,s);let c=async(n,r)=>{clearTimeout(i),s&&window.removeEventListener(`error`,s);let a=()=>{if(r?.type===`error`){let t=Error(r?.isTimeout?`ScriptNetworkError: Script "${e.url}" timed out.`:`ScriptNetworkError: Failed to load script "${e.url}" - the script URL is unreachable or the server returned an error (network failure, 404, CORS, etc.)`);t.name=`ScriptNetworkError`,e?.onErrorCallback&&e?.onErrorCallback(t)}else o?e?.onErrorCallback&&e?.onErrorCallback(o):e?.cb&&e?.cb()};if(t&&(t.onerror=null,t.onload=null,ce(()=>{let{needDeleteScript:n=!0}=e;n&&t?.parentNode&&t.parentNode.removeChild(t)}),n&&typeof n==`function`)){let e=n(r);if(e instanceof Promise){let t=await e;return a(),t}return a(),e}a()};return t.onerror=c.bind(null,t.onerror),t.onload=c.bind(null,t.onload),i=setTimeout(()=>{c(null,{type:`error`,isTimeout:!0})},r),{script:t,needAttach:n}}function de(e){let t=null,n=!0,r=document.getElementsByTagName(`link`);for(let i=0;i<r.length;i++){let a=r[i],o=a.getAttribute(`href`),s=a.getAttribute(`rel`);if(o&&le(o,e.url)&&s===e.attrs.rel){t=a,n=!1;break}}if(!t){t=document.createElement(`link`),t.setAttribute(`href`,e.url);let n,r=e.attrs;e.createLinkHook&&(n=e.createLinkHook(e.url,r),n instanceof HTMLLinkElement&&(t=n)),r&&!n&&Object.keys(r).forEach(e=>{t&&!t.getAttribute(e)&&t.setAttribute(e,r[e])})}let i=(n,r)=>{let i=()=>{r?.type===`error`?e?.onErrorCallback&&e?.onErrorCallback(r):e?.cb&&e?.cb()};if(t&&(t.onerror=null,t.onload=null,ce(()=>{let{needDeleteLink:n=!0}=e;n&&t?.parentNode&&t.parentNode.removeChild(t)}),n)){let e=n(r);return i(),e}i()};return t.onerror=i.bind(null,t.onerror),t.onload=i.bind(null,t.onload),{link:t,needAttach:n}}function fe(e,t){let{attrs:n={},createScriptHook:r}=t;return new Promise((t,i)=>{let{script:a,needAttach:o}=ue({url:e,cb:t,onErrorCallback:i,attrs:{fetchpriority:`high`,...n},createScriptHook:r,needDeleteScript:!0});o&&document.head.appendChild(a)})}var pe=e=>`View the docs to see how to solve: https://module-federation.io/guide/troubleshooting/${e.split(`-`)[0].toLowerCase()}#${e.toLowerCase()}`,me=(e,t,n,r)=>{let i=[`${[t[e]]} #${e}`];return n&&i.push(`args: ${JSON.stringify(n)}`),i.push(pe(e)),r&&i.push(`Original Error Message:\n ${r}`),i.join(`
|
|
4
|
+
`)};function he(e,t,n,r,i,a){return r(me(e,t,n,i))}var _=`[ Federation Runtime ]`,ge=oe(_);function v(e,t,n,r,i){e||(n===void 0?y(t):y(t,n,r,void 0,i))}function y(e,t,n,r,i){if(t!==void 0)return he(e,t,n??{},e=>{throw Error(`${_}: ${e}`)},r,i);let a=e;throw a instanceof Error?(a.message.startsWith(_)||(a.message=`${_}: ${a.message}`),a):Error(`${_}: ${a}`)}function _e(e){e instanceof Error&&(e.message.startsWith(_)||(e.message=`${_}: ${e.message}`)),ge.warn(e)}function ve(e,t){return e.findIndex(e=>e===t)===-1&&e.push(t),e}function b(e){return`version`in e&&e.version?`${e.name}:${e.version}`:`entry`in e&&e.entry?`${e.name}:${e.entry}`:`${e.name}`}function ye(e){return e.entry!==void 0}function be(e){return!e.entry.includes(`.json`)}function xe(e){return e&&typeof e==`object`}var Se=Object.prototype.toString;function Ce(e){return Se.call(e)===`[object Object]`}function we(e){return Array.isArray(e)?e:[e]}function Te(e){return`remoteEntry`in e?{url:e.remoteEntry,type:e.remoteEntryType,globalName:e.globalName}:{url:``,type:`global`,globalName:``}}var Ee=(e,t)=>{let n;return n=e.endsWith(`/`)?e.slice(0,-1):e,t.startsWith(`.`)&&(t=t.slice(1)),n+=t,n},x=typeof globalThis==`object`?globalThis:window,S=(()=>{try{return document.defaultView}catch{return x}})(),C=S;function w(e,t,n){Object.defineProperty(e,t,{value:n,configurable:!1,writable:!0})}function T(e,t){return Object.hasOwnProperty.call(e,t)}T(x,`__GLOBAL_LOADING_REMOTE_ENTRY__`)||w(x,`__GLOBAL_LOADING_REMOTE_ENTRY__`,{});var E=x.__GLOBAL_LOADING_REMOTE_ENTRY__;function De(e){T(e,`__VMOK__`)&&!T(e,`__FEDERATION__`)&&w(e,`__FEDERATION__`,e.__VMOK__),T(e,`__FEDERATION__`)||(w(e,`__FEDERATION__`,{__GLOBAL_PLUGIN__:[],__INSTANCES__:[],moduleInfo:{},__SHARE__:{},__MANIFEST_LOADING__:{},__PRELOADED_MAP__:new Map}),w(e,`__VMOK__`,e.__FEDERATION__)),e.__FEDERATION__.__GLOBAL_PLUGIN__??=[],e.__FEDERATION__.__INSTANCES__??=[],e.__FEDERATION__.moduleInfo??={},e.__FEDERATION__.__SHARE__??={},e.__FEDERATION__.__MANIFEST_LOADING__??={},e.__FEDERATION__.__PRELOADED_MAP__??=new Map}De(x),De(S);function Oe(e){x.__FEDERATION__.__INSTANCES__.push(e)}function ke(){return x.__FEDERATION__.__DEBUG_CONSTRUCTOR__}function Ae(e,t=c()){t&&(x.__FEDERATION__.__DEBUG_CONSTRUCTOR__=e,x.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__=`2.3.3`)}function D(e,t){if(typeof t==`string`){if(e[t])return{value:e[t],key:t};{let n=Object.keys(e);for(let r of n){let[n,i]=r.split(`:`),a=`${n}:${t}`,o=e[a];if(o)return{value:o,key:a}}return{value:void 0,key:t}}}else y(`getInfoWithoutType: "key" must be a string, got ${typeof t} (${JSON.stringify(t)}).`)}var je=()=>S.__FEDERATION__.moduleInfo,Me=(e,t)=>{let n=D(t,b(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,...n}=e,r=b(n),i=D(S.__FEDERATION__.moduleInfo,r).value;if(i?.version===t)return i}},O=e=>Me(e,S.__FEDERATION__.moduleInfo),Ne=(e,t)=>{let n=b(e);return S.__FEDERATION__.moduleInfo[n]=t,S.__FEDERATION__.moduleInfo},Pe=e=>(S.__FEDERATION__.moduleInfo={...S.__FEDERATION__.moduleInfo,...e},()=>{let t=Object.keys(e);for(let e of t)delete S.__FEDERATION__.moduleInfo[e]}),Fe=(e,t)=>{let n=t||`__FEDERATION_${e}:custom__`;return{remoteEntryKey:n,entryExports:x[n]}},Ie=()=>S.__FEDERATION__.__GLOBAL_PLUGIN__,Le=e=>x.__FEDERATION__.__PRELOADED_MAP__.get(e),Re=e=>x.__FEDERATION__.__PRELOADED_MAP__.set(e,!0),ze=`[0-9A-Za-z-]+`,Be=`(?:\\+(${ze}(?:\\.${ze})*))`,k=`0|[1-9]\\d*`,A=`[0-9]+`,Ve=`\\d*[a-zA-Z-][a-zA-Z0-9-]*`,He=`(?:${A}|${Ve})`,Ue=`(?:-?(${He}(?:\\.${He})*))`,We=`(?:${k}|${Ve})`,Ge=`(?:-(${We}(?:\\.${We})*))`,Ke=`${k}|x|X|\\*`,j=`[v=\\s]*(${Ke})(?:\\.(${Ke})(?:\\.(${Ke})(?:${Ge})?${Be}?)?)?`,qe=`^\\s*(${j})\\s+-\\s+(${j})\\s*$`,Je=`[v=\\s]*${`(${A})\\.(${A})\\.(${A})`}${Ue}?${Be}?`,Ye=`((?:<|>)?=?)`,Xe=`(\\s*)${Ye}\\s*(${Je}|${j})`,Ze=`(?:~>?)`,Qe=`(\\s*)${Ze}\\s+`,$e=`(?:\\^)`,et=`(\\s*)${$e}\\s+`,tt=`(<|>)?=?\\s*\\*`,nt=`^${$e}${j}$`,rt=`v?${`(${k})\\.(${k})\\.(${k})`}${Ge}?${Be}?`,it=`^${Ze}${j}$`,at=`^${Ye}\\s*${j}$`,ot=`^${Ye}\\s*(${rt})$|^$`,st=`^\\s*>=\\s*0.0.0\\s*$`;function M(e){return new RegExp(e)}function N(e){return!e||e.toLowerCase()===`x`||e===`*`}function ct(...e){return t=>e.reduce((e,t)=>t(e),t)}function lt(e){return e.match(M(ot))}function ut(e,t,n,r){let i=`${e}.${t}.${n}`;return r?`${i}-${r}`:i}function dt(e){return e.replace(M(qe),(e,t,n,r,i,a,o,s,c,l,u,d)=>(t=N(n)?``:N(r)?`>=${n}.0.0`:N(i)?`>=${n}.${r}.0`:`>=${t}`,s=N(c)?``:N(l)?`<${Number(c)+1}.0.0-0`:N(u)?`<${c}.${Number(l)+1}.0-0`:d?`<=${c}.${l}.${u}-${d}`:`<=${s}`,`${t} ${s}`.trim()))}function ft(e){return e.replace(M(Xe),`$1$2$3`)}function pt(e){return e.replace(M(Qe),`$1~`)}function mt(e){return e.replace(M(et),`$1^`)}function ht(e){return e.trim().split(/\s+/).map(e=>e.replace(M(nt),(e,t,n,r,i)=>N(t)?``:N(n)?`>=${t}.0.0 <${Number(t)+1}.0.0-0`:N(r)?t===`0`?`>=${t}.${n}.0 <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.0 <${Number(t)+1}.0.0-0`:i?t===`0`?n===`0`?`>=${t}.${n}.${r}-${i} <${t}.${n}.${Number(r)+1}-0`:`>=${t}.${n}.${r}-${i} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${r}-${i} <${Number(t)+1}.0.0-0`:t===`0`?n===`0`?`>=${t}.${n}.${r} <${t}.${n}.${Number(r)+1}-0`:`>=${t}.${n}.${r} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${r} <${Number(t)+1}.0.0-0`)).join(` `)}function gt(e){return e.trim().split(/\s+/).map(e=>e.replace(M(it),(e,t,n,r,i)=>N(t)?``:N(n)?`>=${t}.0.0 <${Number(t)+1}.0.0-0`:N(r)?`>=${t}.${n}.0 <${t}.${Number(n)+1}.0-0`:i?`>=${t}.${n}.${r}-${i} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${r} <${t}.${Number(n)+1}.0-0`)).join(` `)}function _t(e){return e.split(/\s+/).map(e=>e.trim().replace(M(at),(e,t,n,r,i,a)=>{let o=N(n),s=o||N(r),c=s||N(i);return t===`=`&&c&&(t=``),a=``,o?t===`>`||t===`<`?`<0.0.0-0`:`*`:t&&c?(s&&(r=0),i=0,t===`>`?(t=`>=`,s?(n=Number(n)+1,r=0,i=0):(r=Number(r)+1,i=0)):t===`<=`&&(t=`<`,s?n=Number(n)+1:r=Number(r)+1),t===`<`&&(a=`-0`),`${t+n}.${r}.${i}${a}`):s?`>=${n}.0.0${a} <${Number(n)+1}.0.0-0`:c?`>=${n}.${r}.0${a} <${n}.${Number(r)+1}.0-0`:e})).join(` `)}function vt(e){return e.trim().replace(M(tt),``)}function yt(e){return e.trim().replace(M(st),``)}function bt(e,t){return e=Number(e)||e,t=Number(t)||t,e>t?1:e===t?0:-1}function xt(e,t){let{preRelease:n}=e,{preRelease:r}=t;if(n===void 0&&r)return 1;if(n&&r===void 0)return-1;if(n===void 0&&r===void 0)return 0;for(let e=0,t=n.length;e<=t;e++){let t=n[e],i=r[e];if(t!==i)return t===void 0&&i===void 0?0:t?i?bt(t,i):-1:1}return 0}function P(e,t){return bt(e.major,t.major)||bt(e.minor,t.minor)||bt(e.patch,t.patch)||xt(e,t)}function St(e,t){return e.version===t.version}function Ct(e,t){switch(e.operator){case``:case`=`:return St(e,t);case`>`:return P(e,t)<0;case`>=`:return St(e,t)||P(e,t)<0;case`<`:return P(e,t)>0;case`<=`:return St(e,t)||P(e,t)>0;case void 0:return!0;default:return!1}}function wt(e){return ct(ht,gt,_t,vt)(e)}function Tt(e){return ct(dt,ft,pt,mt)(e.trim()).split(/\s+/).join(` `)}function F(e,t){if(!e)return!1;let n=lt(e);if(!n)return!1;let[,r,,i,a,o,s]=n,c={operator:r,version:ut(i,a,o,s),major:i,minor:a,patch:o,preRelease:s?.split(`.`)},l=t.split(`||`);for(let e of l){let t=e.trim();if(!t||t===`*`||t===`x`)return!0;try{let e=Tt(t);if(!e.trim())return!0;let n=e.split(` `).map(e=>wt(e)).join(` `);if(!n.trim())return!0;let r=n.split(/\s+/).map(e=>yt(e)).filter(Boolean);if(r.length===0)continue;let i=!0;for(let e of r){let t=lt(e);if(!t){i=!1;break}let[,n,,r,a,o,s]=t;if(!Ct({operator:n,version:ut(r,a,o,s),major:r,minor:a,patch:o,preRelease:s?.split(`.`)},c)){i=!1;break}}if(i)return!0}catch(e){console.error(`[semver] Error processing range part "${t}":`,e);continue}}return!1}var I=`default`,Et=`global`;function Dt(e,t,n,r){let a;return a=`get`in e?e.get:`lib`in e?()=>Promise.resolve(e.lib):()=>Promise.resolve(()=>{y(`Cannot get shared "${n}" from "${t}": neither "get" nor "lib" is provided in the share config.`)}),e.shareConfig?.eager&&e.treeShaking?.mode&&y(`Invalid shared config for "${n}" from "${t}": cannot use both "eager: true" and "treeShaking.mode" simultaneously. Choose one strategy.`),{deps:[],useIn:[],from:t,loading:null,...e,shareConfig:{requiredVersion:`^${e.version}`,singleton:!1,eager:!1,strictVersion:!1,...e.shareConfig},get:a,loaded:e?.loaded||`lib`in e?!0:void 0,version:e.version??`0`,scope:Array.isArray(e.scope)?e.scope:[e.scope??`default`],strategy:(e.strategy??r)||`version-first`,treeShaking:e.treeShaking?{...e.treeShaking,mode:e.treeShaking.mode??`server-calc`,status:e.treeShaking.status??i.UNKNOWN,useIn:[]}:void 0}}function Ot(e,t){let n=t.shared||{},r=t.name,i=Object.keys(n).reduce((e,i)=>{let a=we(n[i]);return e[i]=e[i]||[],a.forEach(n=>{e[i].push(Dt(n,r,i,t.shareStrategy))}),e},{}),a={...e.shared};return Object.keys(i).forEach(e=>{a[e]?i[e].forEach(t=>{a[e].find(e=>e.version===t.version)||a[e].push(t)}):a[e]=i[e]}),{allShareInfos:a,newShareInfos:i}}function L(e,t){if(!e)return!1;let{status:n,mode:r}=e;return n===i.NO_USE?!1:n===i.CALCULATED?!0:r===`runtime-infer`?t?At(e,t):!0:!1}function R(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!!F(n(e),`<=${n(t)}`)}var z=(e,t)=>{let n=t||function(e,t){return R(e,t)};return Object.keys(e).reduce((e,t)=>!e||n(e,t)||e===`0`?t:e,0)},B=e=>!!e.loaded||typeof e.lib==`function`,kt=e=>!!e.loading,At=(e,t)=>{if(!e||!t)return!1;let{usedExports:n}=e;return n?!!t.every(e=>n.includes(e)):!1};function jt(e,t,n,r){let i=e[t][n],a=``,o=L(r),s=function(e,t){return o?i[e].treeShaking?i[t].treeShaking?!B(i[e].treeShaking)&&R(e,t):!1:!0:!B(i[e])&&R(e,t)};if(o){if(a=z(e[t][n],s),a)return{version:a,useTreesShaking:o};o=!1}return{version:z(e[t][n],s),useTreesShaking:o}}var V=e=>B(e)||kt(e);function Mt(e,t,n,r){let i=e[t][n],a=``,o=L(r),s=function(e,t){if(o){if(!i[e].treeShaking)return!0;if(!i[t].treeShaking)return!1;if(V(i[t].treeShaking))return V(i[e].treeShaking)?!!R(e,t):!0;if(V(i[e].treeShaking))return!1}return V(i[t])?V(i[e])?!!R(e,t):!0:V(i[e])?!1:R(e,t)};if(o){if(a=z(e[t][n],s),a)return{version:a,useTreesShaking:o};o=!1}return{version:z(e[t][n],s),useTreesShaking:o}}function Nt(e){return e===`loaded-first`?Mt:jt}function H(e,t,n,r){if(!e)return;let{shareConfig:i,scope:a=I,strategy:o,treeShaking:s}=n,c=Array.isArray(a)?a:[a];for(let a of c)if(i&&e[a]&&e[a][t]){let{requiredVersion:c}=i,{version:l,useTreesShaking:u}=Nt(o)(e,a,t,s),d={shareScopeMap:e,scope:a,pkgName:t,version:l,GlobalFederation:C.__FEDERATION__,shareInfo:n,resolver:()=>{let r=e[a][t][l];if(i.singleton){if(typeof c==`string`&&!F(l,c)){let e=`Version ${l} from ${l&&r.from} of shared singleton module ${t} does not satisfy the requirement of ${n.from} which needs ${c})`;i.strictVersion?y(e):_e(e)}return{shared:r,useTreesShaking:u}}else{if(c===!1||c===`*`||F(l,c))return{shared:r,useTreesShaking:u};let n=L(s);if(n){for(let[r,i]of Object.entries(e[a][t]))if(L(i.treeShaking,s?.usedExports)&&F(r,c))return{shared:i,useTreesShaking:n}}for(let[n,r]of Object.entries(e[a][t]))if(F(n,c))return{shared:r,useTreesShaking:!1}}}};return(r.emit(d)||d).resolver()}}function Pt(){return C.__FEDERATION__.__SHARE__}function Ft(e){let{pkgName:t,extraOptions:n,shareInfos:r}=e,i=n?.resolver??(e=>{if(!e)return;let t={};return e.forEach(e=>{t[e.version]=e}),t[z(t,function(e,n){return!B(t[e])&&R(e,n)})]}),a=e=>typeof e==`object`&&!!e&&!Array.isArray(e),o=(...e)=>{let t={};for(let n of e)if(n)for(let[e,r]of Object.entries(n)){let n=t[e];a(n)&&a(r)?t[e]=o(n,r):r!==void 0&&(t[e]=r)}return t};return o(i(r[t]),n?.customShareInfo)}var U=(e,t)=>{e.useIn||=[],ve(e.useIn,t)};function W(e,t){return t&&e.treeShaking?e.treeShaking:e}function It(e,t){for(let n of e){let e=t.startsWith(n.name),r=t.replace(n.name,``);if(e){if(r.startsWith(`/`)){let e=n.name;return r=`.${r}`,{pkgNameOrAlias:e,expose:r,remote:n}}else if(r===``)return{pkgNameOrAlias:n.name,expose:`.`,remote:n}}let i=n.alias&&t.startsWith(n.alias),a=n.alias&&t.replace(n.alias,``);if(n.alias&&i){if(a&&a.startsWith(`/`)){let e=n.alias;return a=`.${a}`,{pkgNameOrAlias:e,expose:a,remote:n}}else if(a===``)return{pkgNameOrAlias:n.alias,expose:`.`,remote:n}}}}function Lt(e,t){for(let n of e)if(t===n.name||n.alias&&t===n.alias)return n}var Rt=`RUNTIME-001`,zt=`RUNTIME-002`,Bt=`RUNTIME-003`,Vt=`RUNTIME-004`,Ht=`RUNTIME-005`,Ut=`RUNTIME-006`,Wt=`RUNTIME-007`,Gt=`RUNTIME-008`,Kt=`RUNTIME-009`,qt=`RUNTIME-010`,Jt=`RUNTIME-011`,Yt=`RUNTIME-012`,Xt=`TYPE-001`,Zt=`BUILD-001`,Qt=`BUILD-002`,G={[Rt]:`Failed to get remoteEntry exports.`,[zt]:`The remote entry interface does not contain "init"`,[Bt]:`Failed to get manifest.`,[Vt]:`Failed to locate remote.`,[Ht]:`Invalid loadShareSync function call from bundler runtime`,[Ut]:`Invalid loadShareSync function call from runtime`,[Wt]:`Failed to get remote snapshot.`,[Gt]:`Failed to load script resources.`,[Kt]:`Please call createInstance first.`,[qt]:`The name option cannot be changed after initialization. If you want to create a new instance with a different name, please use "createInstance" api.`,[Jt]:`The remoteEntry URL is missing from the remote snapshot.`,[Yt]:`The getter for the shared module is not a function. This may be caused by setting "shared.import: false" without the host providing the corresponding lib.`},$t={[Xt]:`Failed to generate type declaration. Execute the below cmd to reproduce and fix the error.`},en={[Zt]:`Failed to find expose module.`,[Qt]:`PublicPath is required in prod mode.`};({...G,...$t,...en});var tn=`.then(callbacks[0]).catch(callbacks[1])`;async function nn({entry:t,remoteEntryExports:n}){return new Promise((r,i)=>{try{n?r(n):typeof FEDERATION_ALLOW_NEW_FUNCTION<`u`?Function(`callbacks`,`import("${t}")${tn}`)([r,i]):e(()=>import(t).then(r),[]).catch(i)}catch(e){y(`Failed to load ESM entry from "${t}". ${e instanceof Error?e.message:String(e)}`)}})}async function rn({entry:e,remoteEntryExports:t}){return new Promise((n,r)=>{try{t?n(t):typeof __system_context__>`u`?System.import(e).then(n).catch(r):Function(`callbacks`,`System.import("${e}")${tn}`)([n,r])}catch(t){y(`Failed to load SystemJS entry from "${e}". ${t instanceof Error?t.message:String(t)}`)}})}function an(e,t,n){let{remoteEntryKey:r,entryExports:i}=Fe(e,t);return i||y(Rt,G,{remoteName:e,remoteEntryUrl:n,remoteEntryKey:r}),i}async function on({name:e,globalName:t,entry:n,remoteInfo:r,loaderHook:i,getEntryUrl:a}){let{entryExports:o}=Fe(e,t);if(o)return o;let s=a?a(n):n;return fe(s,{attrs:{},createScriptHook:(e,t)=>{let n=i.lifecycle.createScript.emit({url:e,attrs:t,remoteInfo:r});if(n&&(n instanceof HTMLScriptElement||`script`in n||`timeout`in n))return n}}).then(()=>an(e,t,n),t=>{let n=t instanceof Error?t.message:String(t);y(Gt,G,{remoteName:e,resourceUrl:s},n)})}async function sn({remoteInfo:e,remoteEntryExports:t,loaderHook:n,getEntryUrl:r}){let{entry:i,entryGlobalName:a,name:o,type:s}=e;switch(s){case`esm`:case`module`:return nn({entry:i,remoteEntryExports:t});case`system`:return rn({entry:i,remoteEntryExports:t});default:return on({entry:i,globalName:a,name:o,remoteInfo:e,loaderHook:n,getEntryUrl:r})}}function cn(e){let{entry:t,name:n}=e;return u(n,t)}async function ln(e){let{origin:t,remoteEntryExports:n,remoteInfo:r,getEntryUrl:i,_inErrorHandling:a=!1}=e,o=cn(r);if(n)return n;if(!E[o]){let e=t.remoteHandler.hooks.lifecycle.loadEntry,s=t.loaderHook;E[o]=e.emit({loaderHook:s,remoteInfo:r,remoteEntryExports:n}).then(e=>e||sn({remoteInfo:r,remoteEntryExports:n,loaderHook:s,getEntryUrl:i})).catch(async e=>{let i=cn(r),o=e instanceof Error&&e.message.includes(`ScriptExecutionError`);if(e instanceof Error&&e.message.includes(`RUNTIME-008`)&&!o&&!a){let e=await t.loaderHook.lifecycle.loadEntryError.emit({getRemoteEntry:e=>ln({...e,_inErrorHandling:!0}),origin:t,remoteInfo:r,remoteEntryExports:n,globalLoading:E,uniqueKey:i});if(e)return e}throw e})}return E[o]}function K(e){return{...e,entry:`entry`in e?e.entry:``,type:e.type||`global`,entryGlobalName:e.entryGlobalName||e.name,shareScope:e.shareScope||`default`}}function un(){return typeof FEDERATION_BUILD_IDENTIFIER<`u`?FEDERATION_BUILD_IDENTIFIER:``}function dn(e,t){let n=Ie(),r=[t.hooks,t.remoteHandler.hooks,t.sharedHandler.hooks,t.snapshotHandler.hooks,t.loaderHook,t.bridgeHook];return n.length>0&&n.forEach(t=>{e?.find(e=>e.name!==t.name)&&e.push(t)}),e&&e.length>0&&e.forEach(e=>{r.forEach(n=>{n.applyPlugin(e,t)})}),e}function fn(e){return{name:e.name,alias:e.alias,entry:`entry`in e?e.entry:void 0,version:`version`in e?e.version:void 0,type:e.type,entryGlobalName:e.entryGlobalName,shareScope:e.shareScope}}function q(e){let t={};for(let[n,r]of Object.entries(e.shared)){let e=r[0];e&&(t[n]={version:e.version,singleton:e.shareConfig?.singleton,requiredVersion:e.shareConfig?.requiredVersion===!1?!1:e.shareConfig?.requiredVersion,eager:e.eager,strictVersion:e.shareConfig?.strictVersion})}return{project:{name:e.name,mfRole:e.remotes?.length>0?`host`:`unknown`},mfConfig:{name:e.name,remotes:e.remotes?.map(fn)??[],shared:t}}}function pn(e){return{resourceCategory:`sync`,share:!0,depsRemote:!0,prefetchInterface:!1,...e}}function mn(e,t){return t.map(t=>{let n=Lt(e,t.nameOrAlias);return v(n,`Unable to preload ${t.nameOrAlias} as it is not included in ${!n&&p({remoteInfo:n,remotes:e})}`),{remote:n,preloadConfig:pn(t)}})}function hn(e){return e?e.map(e=>e===`.`?e:e.startsWith(`./`)?e.replace(`./`,``):e):[]}function gn(e,t,n,r=!0){let{cssAssets:i,jsAssetsWithoutEntry:a,entryAssets:o}=n;if(t.options.inBrowser){if(o.forEach(n=>{let{moduleInfo:r}=n,i=t.moduleCache.get(e.name);ln(i?{origin:t,remoteInfo:r,remoteEntryExports:i.remoteEntryExports}:{origin:t,remoteInfo:r,remoteEntryExports:void 0})}),r){let n={rel:`preload`,as:`style`};i.forEach(r=>{let{link:i,needAttach:a}=de({url:r,cb:()=>{},attrs:n,createLinkHook:(n,r)=>{let i=t.loaderHook.lifecycle.createLink.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLLinkElement)return i}});a&&document.head.appendChild(i)})}else{let n={rel:`stylesheet`,type:`text/css`};i.forEach(r=>{let{link:i,needAttach:a}=de({url:r,cb:()=>{},attrs:n,createLinkHook:(n,r)=>{let i=t.loaderHook.lifecycle.createLink.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLLinkElement)return i},needDeleteLink:!1});a&&document.head.appendChild(i)})}if(r){let n={rel:`preload`,as:`script`};a.forEach(r=>{let{link:i,needAttach:a}=de({url:r,cb:()=>{},attrs:n,createLinkHook:(n,r)=>{let i=t.loaderHook.lifecycle.createLink.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLLinkElement)return i}});a&&document.head.appendChild(i)})}else{let n={fetchpriority:`high`,type:e?.type===`module`?`module`:`text/javascript`};a.forEach(r=>{let{script:i,needAttach:a}=ue({url:r,cb:()=>{},attrs:n,createScriptHook:(n,r)=>{let i=t.loaderHook.lifecycle.createScript.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLScriptElement)return i},needDeleteScript:!0});a&&document.head.appendChild(i)})}}}function _n(e,t,n){let r=t,i=Array.isArray(e.shareScope)?e.shareScope:[e.shareScope];i.length||i.push(`default`),i.forEach(e=>{r[e]||(r[e]={})});let a={version:e.version||``,shareScopeKeys:Array.isArray(e.shareScope)?i:e.shareScope||`default`};return Object.defineProperty(a,`shareScopeMap`,{value:r,enumerable:!1}),{remoteEntryInitOptions:a,shareScope:r[i[0]],initScope:n??[]}}var vn=class{constructor({remoteInfo:e,host:t}){this.inited=!1,this.initing=!1,this.lib=void 0,this.remoteInfo=e,this.host=t}async getEntry(){if(this.remoteEntryExports)return this.remoteEntryExports;let e=await ln({origin:this.host,remoteInfo:this.remoteInfo,remoteEntryExports:this.remoteEntryExports});return v(e,`remoteEntryExports is undefined \n ${p(this.remoteInfo)}`),this.remoteEntryExports=e,this.remoteEntryExports}async init(e,t,n){let r=await this.getEntry();if(this.inited)return r;if(this.initPromise)return await this.initPromise,r;this.initing=!0,this.initPromise=(async()=>{let{remoteEntryInitOptions:i,shareScope:a,initScope:o}=_n(this.remoteInfo,this.host.shareScopeMap,n),s=await this.host.hooks.lifecycle.beforeInitContainer.emit({shareScope:a,remoteEntryInitOptions:i,initScope:o,remoteInfo:this.remoteInfo,origin:this.host});r?.init===void 0&&y(zt,G,{hostName:this.host.name,remoteName:this.remoteInfo.name,remoteEntryUrl:this.remoteInfo.entry,remoteEntryKey:this.remoteInfo.entryGlobalName},void 0,q(this.host.options)),await r.init(s.shareScope,s.initScope,s.remoteEntryInitOptions),await this.host.hooks.lifecycle.initContainer.emit({...s,id:e,remoteSnapshot:t,remoteEntryExports:r}),this.inited=!0})();try{await this.initPromise}finally{this.initing=!1,this.initPromise=void 0}return r}async get(e,t,n,r){let{loadFactory:i=!0}=n||{loadFactory:!0},a=await this.init(e,r);this.lib=a;let o;o=await this.host.loaderHook.lifecycle.getModuleFactory.emit({remoteEntryExports:a,expose:t,moduleInfo:this.remoteInfo}),o||=await a.get(t),v(o,`${b(this.remoteInfo)} remote don't export ${t}.`);let s=Ee(this.remoteInfo.name,t),c=this.wraperFactory(o,s);return i?await c():c}wraperFactory(e,t){function n(e,t){e&&typeof e==`object`&&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 r=await e();return n(r,t),r}:()=>{let r=e();return n(r,t),r}}},J=class{constructor(e){this.type=``,this.listeners=new Set,e&&(this.type=e)}on(e){typeof e==`function`&&this.listeners.add(e)}once(e){let t=this;this.on(function n(...r){return t.remove(n),e.apply(null,r)})}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()}},Y=class extends J{emit(...e){let t,n=Array.from(this.listeners);if(n.length>0){let r=0,i=t=>t===!1?!1:r<n.length?Promise.resolve(n[r++].apply(null,e)).then(i):t;t=i()}return Promise.resolve(t)}};function yn(e,t){if(!xe(t))return!1;if(e!==t){for(let n in e)if(!(n in t))return!1}return!0}var X=class extends J{constructor(e){super(),this.onerror=y,this.type=e}emit(e){xe(e)||y(`The data for the "${this.type}" hook should be an object.`);for(let t of this.listeners)try{let n=t(e);if(yn(e,n))e=n;else{this.onerror(`A plugin returned an unacceptable value for the "${this.type}" type.`);break}}catch(e){_e(e),this.onerror(e)}return e}},Z=class extends J{constructor(e){super(),this.onerror=y,this.type=e}emit(e){xe(e)||y(`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,r=t=>(_e(t),this.onerror(t),e),i=a=>{if(yn(e,a)){if(e=a,n<t.length)try{return Promise.resolve(t[n++](e)).then(i,r)}catch(e){return r(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)}},Q=class{constructor(e){this.registerPlugins={},this.lifecycle=e,this.lifecycleKeys=Object.keys(e)}applyPlugin(e,t){v(Ce(e),`Plugin configuration is invalid.`);let n=e.name;v(n,`A name must be provided by the plugin.`),this.registerPlugins[n]||(this.registerPlugins[n]=e,e.apply?.(t),Object.keys(this.lifecycle).forEach(t=>{let n=e[t];n&&this.lifecycle[t].on(n)}))}removePlugin(e){v(e,`A name is required.`);let t=this.registerPlugins[e];v(t,`The plugin "${e}" is not registered.`),Object.keys(t).forEach(e=>{e!==`name`&&this.lifecycle[e].remove(t[e])})}};function bn(e,t){let n=Te(t);n.url||y(Jt,G,{remoteName:e.name});let r=d(t,n.url);e.type=n.type,e.entryGlobalName=n.globalName,e.entry=r,e.version=t.version,e.buildVersion=t.buildVersion}function xn(){return{name:`snapshot-plugin`,async afterResolve(e){let{remote:t,pkgNameOrAlias:n,expose:r,origin:i,remoteInfo:a,id:o}=e;if(!ye(t)||!be(t)){let{remoteSnapshot:s,globalSnapshot:c}=await i.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:t,id:o});bn(a,s);let l={remote:t,preloadConfig:{nameOrAlias:n,exposes:[r],resourceCategory:`sync`,share:!1,depsRemote:!1}},u=await i.remoteHandler.hooks.lifecycle.generatePreloadAssets.emit({origin:i,preloadOptions:l,remoteInfo:a,remote:t,remoteSnapshot:s,globalSnapshot:c});return u&&gn(a,i,u,!1),{...e,remoteSnapshot:s}}return e}}}function Sn(e){let t=e.split(`:`);return t.length===1?{name:t[0],version:void 0}:t.length===2?{name:t[0],version:t[1]}:{name:t[1],version:t[2]}}function Cn(e,t,n,r,i={},a){let{value:o}=D(e,b(t)),s=a||o;if(s&&!h(s)&&(n(s,t,r),s.remotesInfo)){let t=Object.keys(s.remotesInfo);for(let r of t){if(i[r])continue;i[r]=!0;let t=Sn(r),a=s.remotesInfo[r];Cn(e,{name:t.name,version:a.matchedVersion},n,!1,i,void 0)}}}var wn=(e,t)=>document.querySelector(`${e}[${e===`link`?`href`:`src`}="${t}"]`);function Tn(e,t,n,r,i){let a=[],o=[],s=[],c=new Set,l=new Set,{options:u}=e,{preloadConfig:f}=t,{depsRemote:p}=f;if(Cn(r,n,(t,n,r)=>{let i;if(r)i=f;else if(Array.isArray(p)){let e=p.find(e=>e.nameOrAlias===n.name||e.nameOrAlias===n.alias);if(!e)return;i=pn(e)}else if(p===!0)i=f;else return;let c=d(t,Te(t).url);c&&s.push({name:n.name,moduleInfo:{name:n.name,entry:c,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:c});let l=`modules`in t?t.modules:[],u=hn(i.exposes);u.length&&`modules`in t&&(l=t?.modules?.reduce((e,t)=>(u?.indexOf(t.moduleName)!==-1&&e.push(t),e),[]));function m(e){let n=e.map(e=>d(t,e));return i.filter?n.filter(i.filter):n}if(l){let r=l.length;for(let s=0;s<r;s++){let r=l[s],c=`${n.name}/${r.moduleName}`;e.remoteHandler.hooks.lifecycle.handlePreloadModule.emit({id:r.moduleName===`.`?n.name:c,name:n.name,remoteSnapshot:t,preloadConfig:i,remote:n,origin:e}),!Le(c)&&(i.resourceCategory===`all`?(a.push(...m(r.assets.css.async)),a.push(...m(r.assets.css.sync)),o.push(...m(r.assets.js.async)),o.push(...m(r.assets.js.sync))):i.resourceCategory===`sync`&&(a.push(...m(r.assets.css.sync)),o.push(...m(r.assets.js.sync))),Re(c))}}},!0,{},i),i.shared&&i.shared.length>0){let t=(t,n)=>{let{shared:r}=H(e.shareScopeMap,n.sharedName,t,e.sharedHandler.hooks.lifecycle.resolveShare)||{};r&&typeof r.lib==`function`&&(n.assets.js.sync.forEach(e=>{c.add(e)}),n.assets.css.sync.forEach(e=>{l.add(e)}))};i.shared.forEach(e=>{let n=u.shared?.[e.sharedName];if(!n)return;let r=e.version?n.find(t=>t.version===e.version):n;r&&we(r).forEach(n=>{t(n,e)})})}let m=o.filter(e=>!c.has(e)&&!wn(`script`,e));return{cssAssets:a.filter(e=>!l.has(e)&&!wn(`link`,e)),jsAssetsWithoutEntry:m,entryAssets:s.filter(e=>!wn(`script`,e.url))}}var En=function(){return{name:`generate-preload-assets-plugin`,async generatePreloadAssets(e){let{origin:t,preloadOptions:n,remoteInfo:r,remote:i,globalSnapshot:a,remoteSnapshot:o}=e;return ye(i)&&be(i)?{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[{name:i.name,url:i.entry,moduleInfo:{name:r.name,entry:i.entry,type:r.type||`global`,entryGlobalName:``,shareScope:``}}]}:(bn(r,o),Tn(t,n,r,a,o))}}};function Dn(e,t){let n=O({name:t.name,version:t.options.version}),r=n&&`remotesInfo`in n&&n.remotesInfo&&D(n.remotesInfo,e.name).value;return r&&r.matchedVersion?{hostGlobalSnapshot:n,globalSnapshot:je(),remoteSnapshot:O({name:e.name,version:r.matchedVersion})}:{hostGlobalSnapshot:void 0,globalSnapshot:je(),remoteSnapshot:O({name:e.name,version:`version`in e?e.version:void 0})}}var On=class{constructor(e){this.loadingHostSnapshot=null,this.manifestCache=new Map,this.hooks=new Q({beforeLoadRemoteSnapshot:new Y(`beforeLoadRemoteSnapshot`),loadSnapshot:new Z(`loadGlobalSnapshot`),loadRemoteSnapshot:new Z(`loadRemoteSnapshot`),afterLoadSnapshot:new Z(`afterLoadSnapshot`)}),this.manifestLoading=C.__FEDERATION__.__MANIFEST_LOADING__,this.HostInstance=e,this.loaderHook=e.loaderHook}async loadRemoteSnapshotInfo({moduleInfo:e,id:t,expose:n}){let{options:r}=this.HostInstance;await this.hooks.lifecycle.beforeLoadRemoteSnapshot.emit({options:r,moduleInfo:e});let i=O({name:this.HostInstance.options.name,version:this.HostInstance.options.version});i||(i={version:this.HostInstance.options.version||``,remoteEntry:``,remotesInfo:{}},Pe({[this.HostInstance.options.name]:i})),i&&`remotesInfo`in i&&!D(i.remotesInfo,e.name).value&&(`version`in e||`entry`in e)&&(i.remotesInfo={...i?.remotesInfo,[e.name]:{matchedVersion:`version`in e?e.version:e.entry}});let{hostGlobalSnapshot:a,remoteSnapshot:o,globalSnapshot:s}=this.getGlobalRemoteInfo(e),{remoteSnapshot:c,globalSnapshot:l}=await this.hooks.lifecycle.loadSnapshot.emit({options:r,moduleInfo:e,hostGlobalSnapshot:a,remoteSnapshot:o,globalSnapshot:s}),u,d;if(c)if(h(c)){let t=c.remoteEntry,n=await this.getManifestJson(t,e,{}),r=Ne({...e,entry:t},n);u=n,d=r}else{let{remoteSnapshot:t}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:c,from:`global`});u=t,d=l}else if(ye(e)){let t=await this.getManifestJson(e.entry,e,{}),n=Ne(e,t),{remoteSnapshot:r}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:t,from:`global`});u=r,d=n}else y(Wt,G,{remoteName:e.name,remoteVersion:e.version,hostName:this.HostInstance.options.name,globalSnapshot:JSON.stringify(l)},void 0,q(this.HostInstance.options));return await this.hooks.lifecycle.afterLoadSnapshot.emit({id:t,host:this.HostInstance,options:r,moduleInfo:e,remoteSnapshot:u}),{remoteSnapshot:u,globalSnapshot:d}}getGlobalRemoteInfo(e){return Dn(e,this.HostInstance)}async getManifestJson(e,t,n){let r=async()=>{let n=this.manifestCache.get(e);if(n)return n;try{let r=await this.loaderHook.lifecycle.fetch.emit(e,{},K(t));(!r||!(r instanceof Response))&&(r=await fetch(e,{})),n=await r.json()}catch(r){n=await this.HostInstance.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:r,from:`runtime`,lifecycle:`afterResolve`,origin:this.HostInstance}),n||(delete this.manifestLoading[e],y(Bt,G,{manifestUrl:e,moduleName:t.name,hostName:this.HostInstance.options.name},`${r}`,q(this.HostInstance.options)))}return v(n.metaData&&n.exposes&&n.shared,`"${e}" is not a valid federation manifest for remote "${t.name}". Missing required fields: ${[!n.metaData&&`metaData`,!n.exposes&&`exposes`,!n.shared&&`shared`].filter(Boolean).join(`, `)}.`),this.manifestCache.set(e,n),n},i=async()=>{let n=await r(),i=te(n,{version:e}),{remoteSnapshot:a}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:t,manifestJson:n,remoteSnapshot:i,manifestUrl:e,from:`manifest`});return a};return this.manifestLoading[e]||(this.manifestLoading[e]=i().then(e=>e)),this.manifestLoading[e]}},kn=class{constructor(e){this.hooks=new Q({beforeRegisterShare:new X(`beforeRegisterShare`),afterResolve:new Z(`afterResolve`),beforeLoadShare:new Z(`beforeLoadShare`),loadShare:new Y,resolveShare:new X(`resolveShare`),initContainerShareScopeMap:new X(`initContainerShareScopeMap`)}),this.host=e,this.shareScopeMap={},this.initTokens={},this._setGlobalShareScopeMap(e.options)}registerShared(e,t){let{newShareInfos:n,allShareInfos:r}=Ot(e,t);return Object.keys(n).forEach(e=>{n[e].forEach(n=>{n.scope.forEach(r=>{this.hooks.lifecycle.beforeRegisterShare.emit({origin:this.host,pkgName:e,shared:n}),this.shareScopeMap[r]?.[e]||this.setShared({pkgName:e,lib:n.lib,get:n.get,loaded:n.loaded||!!n.lib,shared:n,from:t.name})})})}),{newShareInfos:n,allShareInfos:r}}async loadShare(e,t){let{host:n}=this,r=Ft({pkgName:e,extraOptions:t,shareInfos:n.options.shared});r?.scope&&await Promise.all(r.scope.map(async e=>{await Promise.all(this.initializeSharing(e,{strategy:r.strategy}))}));let{shareInfo:i}=await this.hooks.lifecycle.beforeLoadShare.emit({pkgName:e,shareInfo:r,shared:n.options.shared,origin:n});v(i,`Cannot find shared "${e}" in host "${n.options.name}". Ensure the shared config for "${e}" is declared in the federation plugin options and the host has been initialized before loading shares.`);let{shared:a,useTreesShaking:o}=H(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare)||{};if(a){let t=W(a,o);if(t.lib)return U(t,n.options.name),t.lib;if(t.loading&&!t.loaded){let e=await t.loading;return t.loaded=!0,t.lib||=e,U(t,n.options.name),e}else{let r=(async()=>{let e=await t.get();return U(t,n.options.name),t.loaded=!0,t.lib=e,e})();return this.setShared({pkgName:e,loaded:!1,shared:a,from:n.options.name,lib:null,loading:r,treeShaking:o?t:void 0}),r}}else{if(t?.customShareInfo)return!1;let r=L(i.treeShaking),a=W(i,r),o=(async()=>{let t=await a.get();a.lib=t,a.loaded=!0,U(a,n.options.name);let{shared:r,useTreesShaking:o}=H(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare)||{};if(r){let e=W(r,o);e.lib=t,e.loaded=!0,r.from=i.from}return t})();return this.setShared({pkgName:e,loaded:!1,shared:i,from:n.options.name,lib:null,loading:o,treeShaking:r?a:void 0}),o}}initializeSharing(e=I,t){let{host:n}=this,r=t?.from,i=t?.strategy,a=t?.initScope,o=[];if(r!==`build`){let{initTokens:t}=this;a||=[];let n=t[e];if(n||=t[e]={from:this.host.name},a.indexOf(n)>=0)return o;a.push(n)}let s=this.shareScopeMap,c=n.options.name;s[e]||(s[e]={});let l=s[e],u=(e,t)=>{let{version:n,eager:r}=t;l[e]=l[e]||{};let i=l[e],a=i[n]&&W(i[n]),o=!!(a&&(`eager`in a&&a.eager||`shareConfig`in a&&a.shareConfig?.eager));(!a||a.strategy!==`loaded-first`&&!a.loaded&&(!r==!o?c>i[n].from:r))&&(i[n]=t)},d=async e=>{let{module:t}=await n.remoteHandler.getRemoteModuleAndOptions({id:e}),r;try{r=await t.getEntry()}catch(t){if(r=await n.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:t,from:`runtime`,lifecycle:`beforeLoadShare`,origin:n}),!r)return}finally{r?.init&&!t.initing&&(t.remoteEntryExports=r,await t.init(void 0,void 0,a))}};return Object.keys(n.options.shared).forEach(t=>{n.options.shared[t].forEach(n=>{n.scope.includes(e)&&u(t,n)})}),(n.options.shareStrategy===`version-first`||i===`version-first`)&&n.options.remotes.forEach(t=>{t.shareScope===e&&o.push(d(t.name))}),o}loadShareSync(e,t){let{host:n}=this,r=Ft({pkgName:e,extraOptions:t,shareInfos:n.options.shared});r?.scope&&r.scope.forEach(e=>{this.initializeSharing(e,{strategy:r.strategy})});let{shared:i,useTreesShaking:a}=H(this.shareScopeMap,e,r,this.hooks.lifecycle.resolveShare)||{};if(i){if(typeof i.lib==`function`)return U(i,n.options.name),i.loaded||(i.loaded=!0,i.from===n.options.name&&(r.loaded=!0)),i.lib;if(typeof i.get==`function`){let t=i.get();if(!(t instanceof Promise))return U(i,n.options.name),this.setShared({pkgName:e,loaded:!0,from:n.options.name,lib:t,shared:i}),t}}if(r.lib)return r.loaded||=!0,r.lib;if(r.get){let i=r.get();return i instanceof Promise&&y(t?.from===`build`?Ht:Ut,G,{hostName:n.options.name,sharedPkgName:e},void 0,q(n.options)),r.lib=i,this.setShared({pkgName:e,loaded:!0,from:n.options.name,lib:r.lib,shared:r}),r.lib}y(Ut,G,{hostName:n.options.name,sharedPkgName:e},void 0,q(n.options))}initShareScopeMap(e,t,n={}){let{host:r}=this;this.shareScopeMap[e]=t,this.hooks.lifecycle.initContainerShareScopeMap.emit({shareScope:t,options:r.options,origin:r,scopeName:e,hostShareScopeMap:n.hostShareScopeMap})}setShared({pkgName:e,shared:t,from:n,lib:r,loading:i,loaded:a,get:o,treeShaking:s}){let{version:c,scope:l=`default`,...u}=t,d=Array.isArray(l)?l:[l],f=e=>{let t=(e,t,n)=>{n&&!e[t]&&(e[t]=n)},n=s?e.treeShaking:e;t(n,`loaded`,a),t(n,`loading`,i),t(n,`get`,o)};d.forEach(t=>{this.shareScopeMap[t]||(this.shareScopeMap[t]={}),this.shareScopeMap[t][e]||(this.shareScopeMap[t][e]={}),this.shareScopeMap[t][e][c]||(this.shareScopeMap[t][e][c]={version:c,scope:[t],...u,lib:r});let i=this.shareScopeMap[t][e][c];f(i),n&&i.from!==n&&(i.from=n)})}_setGlobalShareScopeMap(e){let t=Pt(),n=e.id||e.name;n&&!t[n]&&(t[n]=this.shareScopeMap)}},An=class{constructor(e){this.hooks=new Q({beforeRegisterRemote:new X(`beforeRegisterRemote`),registerRemote:new X(`registerRemote`),beforeRequest:new Z(`beforeRequest`),onLoad:new Y(`onLoad`),handlePreloadModule:new J(`handlePreloadModule`),errorLoadRemote:new Y(`errorLoadRemote`),beforePreloadRemote:new Y(`beforePreloadRemote`),generatePreloadAssets:new Y(`generatePreloadAssets`),afterPreloadRemote:new Y,loadEntry:new Y}),this.host=e,this.idToRemoteMap={}}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:r}=t,{name:i,alias:a}=n;if(this.idToRemoteMap[e]={name:n.name,expose:r},a&&e.startsWith(i)){let t=e.replace(i,a);this.idToRemoteMap[t]={name:n.name,expose:r};return}if(a&&e.startsWith(a)){let t=e.replace(a,i);this.idToRemoteMap[t]={name:n.name,expose:r}}}async loadRemote(e,t){let{host:n}=this;try{let{loadFactory:r=!0}=t||{loadFactory:!0},{module:i,moduleOptions:a,remoteMatchInfo:o}=await this.getRemoteModuleAndOptions({id:e}),{pkgNameOrAlias:s,remote:c,expose:l,id:u,remoteSnapshot:d}=o,f=await i.get(u,l,t,d),p=await this.hooks.lifecycle.onLoad.emit({id:u,pkgNameOrAlias:s,expose:l,exposeModule:r?f:void 0,exposeModuleFactory:r?void 0:f,remote:c,options:a,moduleInstance:i,origin:n});return this.setIdToRemoteMap(e,o),typeof p==`function`?p:f}catch(r){let{from:i=`runtime`}=t||{from:`runtime`},a=await this.hooks.lifecycle.errorLoadRemote.emit({id:e,error:r,from:i,lifecycle:`onLoad`,origin:n});if(!a)throw r;return a}}async preloadRemote(e){let{host:t}=this;await this.hooks.lifecycle.beforePreloadRemote.emit({preloadOps:e,options:t.options,origin:t});let n=mn(t.options.remotes,e);await Promise.all(n.map(async e=>{let{remote:n}=e,r=K(n),{globalSnapshot:i,remoteSnapshot:a}=await t.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:n}),o=await this.hooks.lifecycle.generatePreloadAssets.emit({origin:t,preloadOptions:e,remote:n,remoteInfo:r,globalSnapshot:i,remoteSnapshot:a});o&&gn(r,t,o)}))}registerRemotes(e,t){let{host:n}=this;e.forEach(e=>{this.registerRemote(e,n.options.remotes,{force:t?.force})})}async getRemoteModuleAndOptions(e){let{host:t}=this,{id:n}=e,r;try{r=await this.hooks.lifecycle.beforeRequest.emit({id:n,options:t.options,origin:t})}catch(e){if(r=await this.hooks.lifecycle.errorLoadRemote.emit({id:n,options:t.options,origin:t,from:`runtime`,error:e,lifecycle:`beforeRequest`}),!r)throw e}let{id:i}=r,a=It(t.options.remotes,i);a||y(Vt,G,{hostName:t.options.name,requestId:i},void 0,q(t.options));let{remote:o}=a,s=K(o),c=await t.sharedHandler.hooks.lifecycle.afterResolve.emit({id:i,...a,options:t.options,origin:t,remoteInfo:s}),{remote:l,expose:u}=c;v(l&&u,`The 'beforeRequest' hook was executed, but it failed to return the correct 'remote' and 'expose' values while loading ${i}.`);let d=t.moduleCache.get(l.name),f={host:t,remoteInfo:s};return d||(d=new vn(f),t.moduleCache.set(l.name,d)),{module:d,moduleOptions:f,remoteMatchInfo:c}}registerRemote(e,t,n){let{host:r}=this,i=()=>{if(e.alias){let n=t.find(t=>e.alias&&(t.name.startsWith(e.alias)||t.alias?.startsWith(e.alias)));v(!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&&typeof window<`u`&&!e.entry.startsWith(`http`)&&(e.entry=new URL(e.entry,window.location.origin).href),e.shareScope||=I,e.type||=Et};this.hooks.lifecycle.beforeRegisterRemote.emit({remote:e,origin:r});let a=t.find(t=>t.name===e.name);if(!a)i(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:r});else{let o=[`The remote "${e.name}" is already registered.`,`Please note that overriding it may cause unexpected errors.`];n?.force&&(this.removeRemote(a),i(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:r}),f(o.join(` `)))}}removeRemote(e){try{let{host:t}=this,{name:n}=e,r=t.options.remotes.findIndex(e=>e.name===n);r!==-1&&t.options.remotes.splice(r,1);let i=t.moduleCache.get(e.name);if(i){let n=i.remoteInfo,r=n.entryGlobalName;x[r]&&(Object.getOwnPropertyDescriptor(x,r)?.configurable?delete x[r]:x[r]=void 0);let a=cn(i.remoteInfo);E[a]&&delete E[a],t.snapshotHandler.manifestCache.delete(n.entry);let o=n.buildVersion?u(n.name,n.buildVersion):n.name,s=x.__FEDERATION__.__INSTANCES__.findIndex(e=>n.buildVersion?e.options.id===o:e.name===o);if(s!==-1){let e=x.__FEDERATION__.__INSTANCES__[s];o=e.options.id||o;let t=Pt(),r=!0,i=[];Object.keys(t).forEach(e=>{let a=t[e];a&&Object.keys(a).forEach(t=>{let o=a[t];o&&Object.keys(o).forEach(a=>{let s=o[a];s&&Object.keys(s).forEach(o=>{let c=s[o];c&&typeof c==`object`&&c.from===n.name&&(c.loaded||c.loading?(c.useIn=c.useIn.filter(e=>e!==n.name),c.useIn.length?r=!1:i.push([e,t,a,o])):i.push([e,t,a,o]))})})})}),r&&(e.shareScopeMap={},delete t[o]),i.forEach(([e,n,r,i])=>{delete t[e]?.[n]?.[r]?.[i]}),x.__FEDERATION__.__INSTANCES__.splice(s,1)}let{hostGlobalSnapshot:c}=Dn(e,t);if(c){let t=c&&`remotesInfo`in c&&c.remotesInfo&&D(c.remotesInfo,e.name).key;t&&(delete c.remotesInfo[t],C.__FEDERATION__.__MANIFEST_LOADING__[t]&&delete C.__FEDERATION__.__MANIFEST_LOADING__[t])}t.moduleCache.delete(e.name)}}catch(e){ge.error(`removeRemote failed: ${e instanceof Error?e.message:String(e)}`)}}},jn=typeof FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN==`boolean`?!FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN:!0,Mn=class{constructor(e){this.hooks=new Q({beforeInit:new X(`beforeInit`),init:new J,beforeInitContainer:new Z(`beforeInitContainer`),initContainer:new Z(`initContainer`)}),this.version=`2.3.3`,this.moduleCache=new Map,this.loaderHook=new Q({getModuleInfo:new J,createScript:new J,createLink:new J,fetch:new Y,loadEntryError:new Y,getModuleFactory:new Y}),this.bridgeHook=new Q({beforeBridgeRender:new J,afterBridgeRender:new J,beforeBridgeDestroy:new J,afterBridgeDestroy:new J});let t=jn?[xn(),En()]:[],n={id:un(),name:e.name,plugins:t,remotes:[],shared:{},inBrowser:!0};this.name=e.name,this.options=n,this.snapshotHandler=new On(this),this.sharedHandler=new kn(this),this.remoteHandler=new An(this),this.shareScopeMap=this.sharedHandler.shareScopeMap,this.registerPlugins([...n.plugins,...e.plugins||[]]),this.options=this.formatOptions(n,e)}initOptions(e){e.name&&e.name!==this.options.name&&y(me(qt,G)),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=I,t){return this.sharedHandler.initializeSharing(e,t)}initRawContainer(e,t,n){let r=K({name:e,entry:t}),i=new vn({host:this,remoteInfo:r});return i.remoteEntryExports=n,this.moduleCache.set(e,i),i}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{allShareInfos:n}=Ot(e,t),{userOptions:r,options:i}=this.hooks.lifecycle.beforeInit.emit({origin:this,userOptions:t,options:e,shareInfo:n}),a=this.remoteHandler.formatAndRegisterRemote(i,r),{allShareInfos:o}=this.sharedHandler.registerShared(i,r),s=[...i.plugins];r.plugins&&r.plugins.forEach(e=>{s.includes(e)||s.push(e)});let c={...e,...t,plugins:s,remotes:a,shared:o};return this.hooks.lifecycle.init.emit({origin:this,options:c}),c}registerPlugins(e){let t=dn(e,this);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)}registerShared(e){this.sharedHandler.registerShared(this.options,{...this.options,shared:e})}};function Nn(e){let t=new((ke())||Mn)(e);return Oe(t),t}Ae(Mn),typeof __VUE_HMR_RUNTIME__>`u`&&(globalThis.__VUE_HMR_RUNTIME__={createRecord(){},rerender(){},reload(){}});var Pn=`__mf_init____mf__virtual/__mfe_internal__rimori_mf_2_scenario_mf_2_host__mf_v__runtimeInit__mf_v__.js__`,Fn=globalThis[Pn];if(!Fn){let e,t,n=new Promise((n,r)=>{e=n,t=r});Fn=globalThis[Pn]={initPromise:n,initResolve:e,initReject:t},typeof window>`u`&&e({loadRemote:function(){return Promise.resolve(void 0)},loadShare:function(){return Promise.resolve(void 0)}})}var In=Fn.initResolve,Ln=`__mf_module_cache__`;globalThis[Ln]||={share:{},remote:{}},globalThis[Ln].share||={},globalThis[Ln].remote||={};var $=globalThis[Ln],Rn={},zn=`default`,Bn=`__mfe_internal__rimori-scenario-host`,Vn,Hn,Un;async function Wn(){return Hn??=e(()=>import(`./localSharedImportMap.js`),[]),Hn}async function Gn(){return Un??=e(()=>import(`./virtualExposes.js`).then(e=>e.default??e),[]),Un}async function Kn(t={},n=[]){let{usedShared:r,usedRemotes:i}=await Wn();if($.share.react===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_react_mf_2_client__loadShare__.mjs.js`).then(e=>(e.y(),e.v)),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share.react=t}if($.share[`react-dom`]===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_react_mf_2_client__loadShare__.mjs.js`).then(e=>(e.c(),e.s)),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share[`react-dom`]=t}if($.share[`react/jsx-dev-runtime`]===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare__react_mf_1_jsx_mf_2_dev_mf_2_runtime__loadShare__.mjs.js`).then(e=>e.t),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share[`react/jsx-dev-runtime`]=t}if($.share[`react/jsx-runtime`]===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_react_mf_2_client__loadShare__.mjs.js`).then(e=>e.a),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share[`react/jsx-runtime`]=t}if($.share[`@rimori/client`]===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_client__loadShare__.mjs.js`).then(e=>e.s),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share[`@rimori/client`]=t}if($.share[`@rimori/react-client`]===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_rimori_mf_1_react_mf_2_client__loadShare__.mjs.js`).then(e=>e.n),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share[`@rimori/react-client`]=t}if($.share[`@tanstack/react-query`]===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare___mf_0_tanstack_mf_1_react_mf_2_query__loadShare__.mjs.js`).then(e=>e.t),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share[`@tanstack/react-query`]=t}if($.share.zod===void 0){let t={...await e(()=>import(`./__mfe_internal__rimori_mf_2_scenario_mf_2_host__loadShare__zod__loadShare__.mjs.js`).then(e=>e.t),[])};Object.defineProperty(t,`__esModule`,{value:!0,enumerable:!1}),$.share.zod=t}let a={name:Bn,remotes:i,shared:r,plugins:[],shareStrategy:`version-first`};Vn?Vn.initOptions(a):Vn=Nn(a);let o=Vn;var s=Rn[zn];if(s||=Rn[zn]={from:Bn},!(n.indexOf(s)>=0)){n.push(s),o.initShareScopeMap(`default`,t),In(o);try{await Promise.all(await o.initializeSharing(`default`,{strategy:`version-first`,from:`build`,initScope:n}))}catch(e){console.error(`[Module Federation]`,e)}return o}}async function qn(e){let t=await Gn();if(!(e in t))throw Error(`[Module Federation] Module ${e} does not exist in container.`);return t[e]().then(e=>()=>e)}export{Kn as n,qn as t};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rimori/playwright-testing",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.30-next.1",
|
|
4
4
|
"description": "Playwright testing utilities for Rimori plugins and workers",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"types": "dist/index.d.ts",
|
|
12
12
|
"source": "src/index.ts",
|
|
13
13
|
"scripts": {
|
|
14
|
-
"build": "tsc -p tsconfig.json &&
|
|
14
|
+
"build": "tsc -p tsconfig.json && pnpm build:harness",
|
|
15
15
|
"build:harness": "vite build --config harness.vite.config.mts",
|
|
16
16
|
"dev": "tsc -w --preserveWatchOutput -p tsconfig.json",
|
|
17
17
|
"clean": "rimraf dist",
|
|
@@ -27,13 +27,13 @@
|
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"@playwright/test": "^1.40.0",
|
|
30
|
-
"@rimori/client": "
|
|
30
|
+
"@rimori/client": "2.5.39-next.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@module-federation/enhanced": "2.3.3",
|
|
34
34
|
"@module-federation/vite": "1.15.0",
|
|
35
35
|
"@playwright/test": "^1.40.0",
|
|
36
|
-
"@rimori/client": "
|
|
36
|
+
"@rimori/client": "2.5.39-next.0",
|
|
37
37
|
"@rimori/react-client": "^0.4.19",
|
|
38
38
|
"@tanstack/react-query": "^5.56.2",
|
|
39
39
|
"@types/node": "^20.12.7",
|
package/dist/harness/dist.js
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./preload-helper.js";var t=`FEDERATION_DEBUG`,n={AT:`@`,HYPHEN:`-`,SLASH:`/`},r={[n.AT]:`scope_`,[n.HYPHEN]:`_`,[n.SLASH]:`__`};r[n.AT],n.AT,r[n.HYPHEN],n.HYPHEN,r[n.SLASH],n.SLASH;var i=function(e){return e[e.UNKNOWN=1]=`UNKNOWN`,e[e.CALCULATED=2]=`CALCULATED`,e[e.NO_USE=0]=`NO_USE`,e}({});function a(){return!0}function o(){return typeof navigator<`u`&&navigator?.product===`ReactNative`}function s(){try{if(a()&&window.localStorage)return!!localStorage.getItem(t)}catch{return!1}return!1}function c(){return typeof process<`u`&&{}.FEDERATION_DEBUG?!!{}.FEDERATION_DEBUG:typeof FEDERATION_DEBUG<`u`&&FEDERATION_DEBUG?!0:s()}var l=`[ Federation Runtime ]`,u=function(...e){return e.length?e.reduce((e,t)=>t?e?`${e}:${t}`:t:e,``):``},d=(e,t)=>{if(`getPublicPath`in e){let n;return n=e.getPublicPath.startsWith(`function`)?Function(`return `+e.getPublicPath)()():Function(e.getPublicPath)(),`${n}${t}`}else if(`publicPath`in e)return!a()&&!o()&&`ssrPublicPath`in e&&typeof e.ssrPublicPath==`string`?`${e.ssrPublicPath}${t}`:`${e.publicPath}${t}`;else return console.warn(`Cannot get resource URL. If in debug mode, please ignore.`,e,t),``},f=e=>{console.warn(`${l}: ${e}`)};function p(e){try{return JSON.stringify(e,null,2)}catch{return``}}var m=(e,t)=>{if(!e)return t;let n=(e=>{if(e===`.`)return``;if(e.startsWith(`./`))return e.replace(`./`,``);if(e.startsWith(`/`)){let t=e.slice(1);return t.endsWith(`/`)?t.slice(0,-1):t}return e})(e);return n?n.endsWith(`/`)?`${n}${t}`:`${n}/${t}`:t};function ee(e){return e.replace(/#.*$/,``).replace(/\?.*$/,``).replace(/\/[^\/]+$/,`/`)}function te(e,t={}){let{remotes:n={},overrides:r={},version:i}=t,a,o=()=>`publicPath`in e.metaData?(e.metaData.publicPath===`auto`||e.metaData.publicPath===``)&&i?ee(i):e.metaData.publicPath:e.metaData.getPublicPath,s=Object.keys(r),c={};Object.keys(n).length||(c=e.remotes?.reduce((e,t)=>{let n,i=t.federationContainerName;return n=s.includes(i)?r[i]:`version`in t?t.version:t.entry,e[i]={matchedVersion:n},e},{})||{}),Object.keys(n).forEach(e=>c[e]={matchedVersion:s.includes(e)?r[e]:n[e]});let{remoteEntry:{path:l,name:u,type:d},types:f={path:``,name:``,zip:``,api:``},buildInfo:{buildVersion:p},globalName:te,ssrRemoteEntry:h}=e.metaData,{exposes:ne}=e,g={version:i||``,buildVersion:p,globalName:te,remoteEntry:m(l,u),remoteEntryType:d,remoteTypes:m(f.path,f.name),remoteTypesZip:f.zip||``,remoteTypesAPI:f.api||``,remotesInfo:c,shared:e?.shared.map(e=>({assets:e.assets,sharedName:e.name,version:e.version,usedExports:e.referenceExports||[]})),modules:ne?.map(e=>({moduleName:e.name,modulePath:e.path,assets:e.assets}))};if(e.metaData?.prefetchInterface){let t=e.metaData.prefetchInterface;g={...g,prefetchInterface:t}}if(e.metaData?.prefetchEntry){let{path:t,name:n,type:r}=e.metaData.prefetchEntry;g={...g,prefetchEntry:m(t,n),prefetchEntryType:r}}if(`publicPath`in e.metaData?(a={...g,publicPath:o()},typeof e.metaData.ssrPublicPath==`string`&&(a.ssrPublicPath=e.metaData.ssrPublicPath)):a={...g,getPublicPath:o()},h){let e=m(h.path,h.name);a.ssrRemoteEntry=e,a.ssrRemoteEntryType=h.type||`commonjs-module`}return a}function h(e){return!!(`remoteEntry`in e&&e.remoteEntry.includes(`.json`))}var ne=`[ Module Federation ]`,g=console,re=[`logger.ts`,`logger.js`,`captureStackTrace`,`Logger.emit`,`Logger.log`,`Logger.info`,`Logger.warn`,`Logger.error`,`Logger.debug`];function ie(){try{let e=Error().stack;if(!e)return;let[,...t]=e.split(`
|
|
2
|
-
`),n=t.filter(e=>!re.some(t=>e.includes(t)));return n.length?`Stack trace:\n${n.slice(0,5).join(`
|
|
3
|
-
`)}`:void 0}catch{return}}var ae=class{constructor(e,t=g){this.prefix=e,this.delegate=t??g}setPrefix(e){this.prefix=e}setDelegate(e){this.delegate=e??g}emit(e,t){let n=this.delegate,r=c()?ie():void 0,i=r?[...t,r]:t,a=(()=>{switch(e){case`log`:return[`log`,`info`];case`info`:return[`info`,`log`];case`warn`:return[`warn`,`info`,`log`];case`error`:return[`error`,`warn`,`log`];default:return[`debug`,`log`]}})();for(let e of a){let t=n[e];if(typeof t==`function`){t.call(n,this.prefix,...i);return}}for(let e of a){let t=g[e];if(typeof t==`function`){t.call(g,this.prefix,...i);return}}}log(...e){this.emit(`log`,e)}warn(...e){this.emit(`warn`,e)}error(...e){this.emit(`error`,e)}success(...e){this.emit(`info`,e)}info(...e){this.emit(`info`,e)}ready(...e){this.emit(`info`,e)}debug(...e){c()&&this.emit(`debug`,e)}};function oe(e){return new ae(e)}function se(e){let t=new ae(e);return Object.defineProperty(t,`__mf_infrastructure_logger__`,{value:!0,enumerable:!1,configurable:!1}),t}oe(ne),se(ne);async function ce(e,t){try{return await e()}catch(e){!t&&f(e);return}}function le(e,t){let n=/^(https?:)?\/\//i;return e.replace(n,``).replace(/\/$/,``)===t.replace(n,``).replace(/\/$/,``)}function ue(e){let t=null,n=!0,r=2e4,i,a=document.getElementsByTagName(`script`);for(let r=0;r<a.length;r++){let i=a[r],o=i.getAttribute(`src`);if(o&&le(o,e.url)){t=i,n=!1;break}}if(!t){let n=e.attrs;t=document.createElement(`script`),t.type=n?.type===`module`?`module`:`text/javascript`;let i;e.createScriptHook&&(i=e.createScriptHook(e.url,e.attrs),i instanceof HTMLScriptElement?t=i:typeof i==`object`&&(`script`in i&&i.script&&(t=i.script),`timeout`in i&&i.timeout&&(r=i.timeout))),t.src||=e.url,n&&!i&&Object.keys(n).forEach(e=>{t&&(e===`async`||e===`defer`?t[e]=n[e]:t.getAttribute(e)||t.setAttribute(e,n[e]))})}let o=null,s=typeof window<`u`?t=>{if(t.filename&&le(t.filename,e.url)){let n=Error(`ScriptExecutionError: Script "${e.url}" loaded but threw a runtime error during execution: ${t.message} (${t.filename}:${t.lineno}:${t.colno})`);n.name=`ScriptExecutionError`,o=n}}:null;s&&window.addEventListener(`error`,s);let c=async(n,r)=>{clearTimeout(i),s&&window.removeEventListener(`error`,s);let a=()=>{if(r?.type===`error`){let t=Error(r?.isTimeout?`ScriptNetworkError: Script "${e.url}" timed out.`:`ScriptNetworkError: Failed to load script "${e.url}" - the script URL is unreachable or the server returned an error (network failure, 404, CORS, etc.)`);t.name=`ScriptNetworkError`,e?.onErrorCallback&&e?.onErrorCallback(t)}else o?e?.onErrorCallback&&e?.onErrorCallback(o):e?.cb&&e?.cb()};if(t&&(t.onerror=null,t.onload=null,ce(()=>{let{needDeleteScript:n=!0}=e;n&&t?.parentNode&&t.parentNode.removeChild(t)}),n&&typeof n==`function`)){let e=n(r);if(e instanceof Promise){let t=await e;return a(),t}return a(),e}a()};return t.onerror=c.bind(null,t.onerror),t.onload=c.bind(null,t.onload),i=setTimeout(()=>{c(null,{type:`error`,isTimeout:!0})},r),{script:t,needAttach:n}}function de(e){let t=null,n=!0,r=document.getElementsByTagName(`link`);for(let i=0;i<r.length;i++){let a=r[i],o=a.getAttribute(`href`),s=a.getAttribute(`rel`);if(o&&le(o,e.url)&&s===e.attrs.rel){t=a,n=!1;break}}if(!t){t=document.createElement(`link`),t.setAttribute(`href`,e.url);let n,r=e.attrs;e.createLinkHook&&(n=e.createLinkHook(e.url,r),n instanceof HTMLLinkElement&&(t=n)),r&&!n&&Object.keys(r).forEach(e=>{t&&!t.getAttribute(e)&&t.setAttribute(e,r[e])})}let i=(n,r)=>{let i=()=>{r?.type===`error`?e?.onErrorCallback&&e?.onErrorCallback(r):e?.cb&&e?.cb()};if(t&&(t.onerror=null,t.onload=null,ce(()=>{let{needDeleteLink:n=!0}=e;n&&t?.parentNode&&t.parentNode.removeChild(t)}),n)){let e=n(r);return i(),e}i()};return t.onerror=i.bind(null,t.onerror),t.onload=i.bind(null,t.onload),{link:t,needAttach:n}}function fe(e,t){let{attrs:n={},createScriptHook:r}=t;return new Promise((t,i)=>{let{script:a,needAttach:o}=ue({url:e,cb:t,onErrorCallback:i,attrs:{fetchpriority:`high`,...n},createScriptHook:r,needDeleteScript:!0});o&&document.head.appendChild(a)})}var pe=e=>`View the docs to see how to solve: https://module-federation.io/guide/troubleshooting/${e.split(`-`)[0].toLowerCase()}#${e.toLowerCase()}`,me=(e,t,n,r)=>{let i=[`${[t[e]]} #${e}`];return n&&i.push(`args: ${JSON.stringify(n)}`),i.push(pe(e)),r&&i.push(`Original Error Message:\n ${r}`),i.join(`
|
|
4
|
-
`)};function he(e,t,n,r,i,a){return r(me(e,t,n,i))}var _=`[ Federation Runtime ]`,ge=oe(_);function v(e,t,n,r,i){e||(n===void 0?y(t):y(t,n,r,void 0,i))}function y(e,t,n,r,i){if(t!==void 0)return he(e,t,n??{},e=>{throw Error(`${_}: ${e}`)},r,i);let a=e;throw a instanceof Error?(a.message.startsWith(_)||(a.message=`${_}: ${a.message}`),a):Error(`${_}: ${a}`)}function _e(e){e instanceof Error&&(e.message.startsWith(_)||(e.message=`${_}: ${e.message}`)),ge.warn(e)}function ve(e,t){return e.findIndex(e=>e===t)===-1&&e.push(t),e}function b(e){return`version`in e&&e.version?`${e.name}:${e.version}`:`entry`in e&&e.entry?`${e.name}:${e.entry}`:`${e.name}`}function ye(e){return e.entry!==void 0}function be(e){return!e.entry.includes(`.json`)}function xe(e){return e&&typeof e==`object`}var Se=Object.prototype.toString;function Ce(e){return Se.call(e)===`[object Object]`}function we(e){return Array.isArray(e)?e:[e]}function Te(e){return`remoteEntry`in e?{url:e.remoteEntry,type:e.remoteEntryType,globalName:e.globalName}:{url:``,type:`global`,globalName:``}}var Ee=(e,t)=>{let n;return n=e.endsWith(`/`)?e.slice(0,-1):e,t.startsWith(`.`)&&(t=t.slice(1)),n+=t,n},x=typeof globalThis==`object`?globalThis:window,S=(()=>{try{return document.defaultView}catch{return x}})(),C=S;function w(e,t,n){Object.defineProperty(e,t,{value:n,configurable:!1,writable:!0})}function T(e,t){return Object.hasOwnProperty.call(e,t)}T(x,`__GLOBAL_LOADING_REMOTE_ENTRY__`)||w(x,`__GLOBAL_LOADING_REMOTE_ENTRY__`,{});var E=x.__GLOBAL_LOADING_REMOTE_ENTRY__;function De(e){T(e,`__VMOK__`)&&!T(e,`__FEDERATION__`)&&w(e,`__FEDERATION__`,e.__VMOK__),T(e,`__FEDERATION__`)||(w(e,`__FEDERATION__`,{__GLOBAL_PLUGIN__:[],__INSTANCES__:[],moduleInfo:{},__SHARE__:{},__MANIFEST_LOADING__:{},__PRELOADED_MAP__:new Map}),w(e,`__VMOK__`,e.__FEDERATION__)),e.__FEDERATION__.__GLOBAL_PLUGIN__??=[],e.__FEDERATION__.__INSTANCES__??=[],e.__FEDERATION__.moduleInfo??={},e.__FEDERATION__.__SHARE__??={},e.__FEDERATION__.__MANIFEST_LOADING__??={},e.__FEDERATION__.__PRELOADED_MAP__??=new Map}De(x),De(S);function Oe(e){x.__FEDERATION__.__INSTANCES__.push(e)}function ke(){return x.__FEDERATION__.__DEBUG_CONSTRUCTOR__}function Ae(e,t=c()){t&&(x.__FEDERATION__.__DEBUG_CONSTRUCTOR__=e,x.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__=`2.3.3`)}function D(e,t){if(typeof t==`string`){if(e[t])return{value:e[t],key:t};{let n=Object.keys(e);for(let r of n){let[n,i]=r.split(`:`),a=`${n}:${t}`,o=e[a];if(o)return{value:o,key:a}}return{value:void 0,key:t}}}else y(`getInfoWithoutType: "key" must be a string, got ${typeof t} (${JSON.stringify(t)}).`)}var je=()=>S.__FEDERATION__.moduleInfo,Me=(e,t)=>{let n=D(t,b(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,...n}=e,r=b(n),i=D(S.__FEDERATION__.moduleInfo,r).value;if(i?.version===t)return i}},O=e=>Me(e,S.__FEDERATION__.moduleInfo),Ne=(e,t)=>{let n=b(e);return S.__FEDERATION__.moduleInfo[n]=t,S.__FEDERATION__.moduleInfo},Pe=e=>(S.__FEDERATION__.moduleInfo={...S.__FEDERATION__.moduleInfo,...e},()=>{let t=Object.keys(e);for(let e of t)delete S.__FEDERATION__.moduleInfo[e]}),Fe=(e,t)=>{let n=t||`__FEDERATION_${e}:custom__`;return{remoteEntryKey:n,entryExports:x[n]}},Ie=()=>S.__FEDERATION__.__GLOBAL_PLUGIN__,Le=e=>x.__FEDERATION__.__PRELOADED_MAP__.get(e),Re=e=>x.__FEDERATION__.__PRELOADED_MAP__.set(e,!0),ze=`[0-9A-Za-z-]+`,Be=`(?:\\+(${ze}(?:\\.${ze})*))`,k=`0|[1-9]\\d*`,A=`[0-9]+`,Ve=`\\d*[a-zA-Z-][a-zA-Z0-9-]*`,He=`(?:${A}|${Ve})`,Ue=`(?:-?(${He}(?:\\.${He})*))`,We=`(?:${k}|${Ve})`,Ge=`(?:-(${We}(?:\\.${We})*))`,Ke=`${k}|x|X|\\*`,j=`[v=\\s]*(${Ke})(?:\\.(${Ke})(?:\\.(${Ke})(?:${Ge})?${Be}?)?)?`,qe=`^\\s*(${j})\\s+-\\s+(${j})\\s*$`,Je=`[v=\\s]*${`(${A})\\.(${A})\\.(${A})`}${Ue}?${Be}?`,Ye=`((?:<|>)?=?)`,Xe=`(\\s*)${Ye}\\s*(${Je}|${j})`,Ze=`(?:~>?)`,Qe=`(\\s*)${Ze}\\s+`,$e=`(?:\\^)`,et=`(\\s*)${$e}\\s+`,tt=`(<|>)?=?\\s*\\*`,nt=`^${$e}${j}$`,rt=`v?${`(${k})\\.(${k})\\.(${k})`}${Ge}?${Be}?`,it=`^${Ze}${j}$`,at=`^${Ye}\\s*${j}$`,ot=`^${Ye}\\s*(${rt})$|^$`,st=`^\\s*>=\\s*0.0.0\\s*$`;function M(e){return new RegExp(e)}function N(e){return!e||e.toLowerCase()===`x`||e===`*`}function ct(...e){return t=>e.reduce((e,t)=>t(e),t)}function lt(e){return e.match(M(ot))}function ut(e,t,n,r){let i=`${e}.${t}.${n}`;return r?`${i}-${r}`:i}function dt(e){return e.replace(M(qe),(e,t,n,r,i,a,o,s,c,l,u,d)=>(t=N(n)?``:N(r)?`>=${n}.0.0`:N(i)?`>=${n}.${r}.0`:`>=${t}`,s=N(c)?``:N(l)?`<${Number(c)+1}.0.0-0`:N(u)?`<${c}.${Number(l)+1}.0-0`:d?`<=${c}.${l}.${u}-${d}`:`<=${s}`,`${t} ${s}`.trim()))}function ft(e){return e.replace(M(Xe),`$1$2$3`)}function pt(e){return e.replace(M(Qe),`$1~`)}function mt(e){return e.replace(M(et),`$1^`)}function ht(e){return e.trim().split(/\s+/).map(e=>e.replace(M(nt),(e,t,n,r,i)=>N(t)?``:N(n)?`>=${t}.0.0 <${Number(t)+1}.0.0-0`:N(r)?t===`0`?`>=${t}.${n}.0 <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.0 <${Number(t)+1}.0.0-0`:i?t===`0`?n===`0`?`>=${t}.${n}.${r}-${i} <${t}.${n}.${Number(r)+1}-0`:`>=${t}.${n}.${r}-${i} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${r}-${i} <${Number(t)+1}.0.0-0`:t===`0`?n===`0`?`>=${t}.${n}.${r} <${t}.${n}.${Number(r)+1}-0`:`>=${t}.${n}.${r} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${r} <${Number(t)+1}.0.0-0`)).join(` `)}function gt(e){return e.trim().split(/\s+/).map(e=>e.replace(M(it),(e,t,n,r,i)=>N(t)?``:N(n)?`>=${t}.0.0 <${Number(t)+1}.0.0-0`:N(r)?`>=${t}.${n}.0 <${t}.${Number(n)+1}.0-0`:i?`>=${t}.${n}.${r}-${i} <${t}.${Number(n)+1}.0-0`:`>=${t}.${n}.${r} <${t}.${Number(n)+1}.0-0`)).join(` `)}function _t(e){return e.split(/\s+/).map(e=>e.trim().replace(M(at),(e,t,n,r,i,a)=>{let o=N(n),s=o||N(r),c=s||N(i);return t===`=`&&c&&(t=``),a=``,o?t===`>`||t===`<`?`<0.0.0-0`:`*`:t&&c?(s&&(r=0),i=0,t===`>`?(t=`>=`,s?(n=Number(n)+1,r=0,i=0):(r=Number(r)+1,i=0)):t===`<=`&&(t=`<`,s?n=Number(n)+1:r=Number(r)+1),t===`<`&&(a=`-0`),`${t+n}.${r}.${i}${a}`):s?`>=${n}.0.0${a} <${Number(n)+1}.0.0-0`:c?`>=${n}.${r}.0${a} <${n}.${Number(r)+1}.0-0`:e})).join(` `)}function vt(e){return e.trim().replace(M(tt),``)}function yt(e){return e.trim().replace(M(st),``)}function P(e,t){return e=Number(e)||e,t=Number(t)||t,e>t?1:e===t?0:-1}function bt(e,t){let{preRelease:n}=e,{preRelease:r}=t;if(n===void 0&&r)return 1;if(n&&r===void 0)return-1;if(n===void 0&&r===void 0)return 0;for(let e=0,t=n.length;e<=t;e++){let t=n[e],i=r[e];if(t!==i)return t===void 0&&i===void 0?0:t?i?P(t,i):-1:1}return 0}function F(e,t){return P(e.major,t.major)||P(e.minor,t.minor)||P(e.patch,t.patch)||bt(e,t)}function xt(e,t){return e.version===t.version}function St(e,t){switch(e.operator){case``:case`=`:return xt(e,t);case`>`:return F(e,t)<0;case`>=`:return xt(e,t)||F(e,t)<0;case`<`:return F(e,t)>0;case`<=`:return xt(e,t)||F(e,t)>0;case void 0:return!0;default:return!1}}function Ct(e){return ct(ht,gt,_t,vt)(e)}function wt(e){return ct(dt,ft,pt,mt)(e.trim()).split(/\s+/).join(` `)}function I(e,t){if(!e)return!1;let n=lt(e);if(!n)return!1;let[,r,,i,a,o,s]=n,c={operator:r,version:ut(i,a,o,s),major:i,minor:a,patch:o,preRelease:s?.split(`.`)},l=t.split(`||`);for(let e of l){let t=e.trim();if(!t||t===`*`||t===`x`)return!0;try{let e=wt(t);if(!e.trim())return!0;let n=e.split(` `).map(e=>Ct(e)).join(` `);if(!n.trim())return!0;let r=n.split(/\s+/).map(e=>yt(e)).filter(Boolean);if(r.length===0)continue;let i=!0;for(let e of r){let t=lt(e);if(!t){i=!1;break}let[,n,,r,a,o,s]=t;if(!St({operator:n,version:ut(r,a,o,s),major:r,minor:a,patch:o,preRelease:s?.split(`.`)},c)){i=!1;break}}if(i)return!0}catch(e){console.error(`[semver] Error processing range part "${t}":`,e);continue}}return!1}var L=`default`,Tt=`global`;function Et(e,t,n,r){let a;return a=`get`in e?e.get:`lib`in e?()=>Promise.resolve(e.lib):()=>Promise.resolve(()=>{y(`Cannot get shared "${n}" from "${t}": neither "get" nor "lib" is provided in the share config.`)}),e.shareConfig?.eager&&e.treeShaking?.mode&&y(`Invalid shared config for "${n}" from "${t}": cannot use both "eager: true" and "treeShaking.mode" simultaneously. Choose one strategy.`),{deps:[],useIn:[],from:t,loading:null,...e,shareConfig:{requiredVersion:`^${e.version}`,singleton:!1,eager:!1,strictVersion:!1,...e.shareConfig},get:a,loaded:e?.loaded||`lib`in e?!0:void 0,version:e.version??`0`,scope:Array.isArray(e.scope)?e.scope:[e.scope??`default`],strategy:(e.strategy??r)||`version-first`,treeShaking:e.treeShaking?{...e.treeShaking,mode:e.treeShaking.mode??`server-calc`,status:e.treeShaking.status??i.UNKNOWN,useIn:[]}:void 0}}function Dt(e,t){let n=t.shared||{},r=t.name,i=Object.keys(n).reduce((e,i)=>{let a=we(n[i]);return e[i]=e[i]||[],a.forEach(n=>{e[i].push(Et(n,r,i,t.shareStrategy))}),e},{}),a={...e.shared};return Object.keys(i).forEach(e=>{a[e]?i[e].forEach(t=>{a[e].find(e=>e.version===t.version)||a[e].push(t)}):a[e]=i[e]}),{allShareInfos:a,newShareInfos:i}}function R(e,t){if(!e)return!1;let{status:n,mode:r}=e;return n===i.NO_USE?!1:n===i.CALCULATED?!0:r===`runtime-infer`?t?kt(e,t):!0:!1}function z(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!!I(n(e),`<=${n(t)}`)}var B=(e,t)=>{let n=t||function(e,t){return z(e,t)};return Object.keys(e).reduce((e,t)=>!e||n(e,t)||e===`0`?t:e,0)},V=e=>!!e.loaded||typeof e.lib==`function`,Ot=e=>!!e.loading,kt=(e,t)=>{if(!e||!t)return!1;let{usedExports:n}=e;return n?!!t.every(e=>n.includes(e)):!1};function At(e,t,n,r){let i=e[t][n],a=``,o=R(r),s=function(e,t){return o?i[e].treeShaking?i[t].treeShaking?!V(i[e].treeShaking)&&z(e,t):!1:!0:!V(i[e])&&z(e,t)};if(o){if(a=B(e[t][n],s),a)return{version:a,useTreesShaking:o};o=!1}return{version:B(e[t][n],s),useTreesShaking:o}}var H=e=>V(e)||Ot(e);function jt(e,t,n,r){let i=e[t][n],a=``,o=R(r),s=function(e,t){if(o){if(!i[e].treeShaking)return!0;if(!i[t].treeShaking)return!1;if(H(i[t].treeShaking))return H(i[e].treeShaking)?!!z(e,t):!0;if(H(i[e].treeShaking))return!1}return H(i[t])?H(i[e])?!!z(e,t):!0:H(i[e])?!1:z(e,t)};if(o){if(a=B(e[t][n],s),a)return{version:a,useTreesShaking:o};o=!1}return{version:B(e[t][n],s),useTreesShaking:o}}function Mt(e){return e===`loaded-first`?jt:At}function U(e,t,n,r){if(!e)return;let{shareConfig:i,scope:a=L,strategy:o,treeShaking:s}=n,c=Array.isArray(a)?a:[a];for(let a of c)if(i&&e[a]&&e[a][t]){let{requiredVersion:c}=i,{version:l,useTreesShaking:u}=Mt(o)(e,a,t,s),d={shareScopeMap:e,scope:a,pkgName:t,version:l,GlobalFederation:C.__FEDERATION__,shareInfo:n,resolver:()=>{let r=e[a][t][l];if(i.singleton){if(typeof c==`string`&&!I(l,c)){let e=`Version ${l} from ${l&&r.from} of shared singleton module ${t} does not satisfy the requirement of ${n.from} which needs ${c})`;i.strictVersion?y(e):_e(e)}return{shared:r,useTreesShaking:u}}else{if(c===!1||c===`*`||I(l,c))return{shared:r,useTreesShaking:u};let n=R(s);if(n){for(let[r,i]of Object.entries(e[a][t]))if(R(i.treeShaking,s?.usedExports)&&I(r,c))return{shared:i,useTreesShaking:n}}for(let[n,r]of Object.entries(e[a][t]))if(I(n,c))return{shared:r,useTreesShaking:!1}}}};return(r.emit(d)||d).resolver()}}function Nt(){return C.__FEDERATION__.__SHARE__}function Pt(e){let{pkgName:t,extraOptions:n,shareInfos:r}=e,i=n?.resolver??(e=>{if(!e)return;let t={};return e.forEach(e=>{t[e.version]=e}),t[B(t,function(e,n){return!V(t[e])&&z(e,n)})]}),a=e=>typeof e==`object`&&!!e&&!Array.isArray(e),o=(...e)=>{let t={};for(let n of e)if(n)for(let[e,r]of Object.entries(n)){let n=t[e];a(n)&&a(r)?t[e]=o(n,r):r!==void 0&&(t[e]=r)}return t};return o(i(r[t]),n?.customShareInfo)}var W=(e,t)=>{e.useIn||=[],ve(e.useIn,t)};function G(e,t){return t&&e.treeShaking?e.treeShaking:e}function Ft(e,t){for(let n of e){let e=t.startsWith(n.name),r=t.replace(n.name,``);if(e){if(r.startsWith(`/`)){let e=n.name;return r=`.${r}`,{pkgNameOrAlias:e,expose:r,remote:n}}else if(r===``)return{pkgNameOrAlias:n.name,expose:`.`,remote:n}}let i=n.alias&&t.startsWith(n.alias),a=n.alias&&t.replace(n.alias,``);if(n.alias&&i){if(a&&a.startsWith(`/`)){let e=n.alias;return a=`.${a}`,{pkgNameOrAlias:e,expose:a,remote:n}}else if(a===``)return{pkgNameOrAlias:n.alias,expose:`.`,remote:n}}}}function It(e,t){for(let n of e)if(t===n.name||n.alias&&t===n.alias)return n}var Lt=`RUNTIME-001`,Rt=`RUNTIME-002`,zt=`RUNTIME-003`,Bt=`RUNTIME-004`,Vt=`RUNTIME-005`,Ht=`RUNTIME-006`,Ut=`RUNTIME-007`,Wt=`RUNTIME-008`,Gt=`RUNTIME-009`,Kt=`RUNTIME-010`,qt=`RUNTIME-011`,Jt=`RUNTIME-012`,Yt=`TYPE-001`,Xt=`BUILD-001`,Zt=`BUILD-002`,K={[Lt]:`Failed to get remoteEntry exports.`,[Rt]:`The remote entry interface does not contain "init"`,[zt]:`Failed to get manifest.`,[Bt]:`Failed to locate remote.`,[Vt]:`Invalid loadShareSync function call from bundler runtime`,[Ht]:`Invalid loadShareSync function call from runtime`,[Ut]:`Failed to get remote snapshot.`,[Wt]:`Failed to load script resources.`,[Gt]:`Please call createInstance first.`,[Kt]:`The name option cannot be changed after initialization. If you want to create a new instance with a different name, please use "createInstance" api.`,[qt]:`The remoteEntry URL is missing from the remote snapshot.`,[Jt]:`The getter for the shared module is not a function. This may be caused by setting "shared.import: false" without the host providing the corresponding lib.`},Qt={[Yt]:`Failed to generate type declaration. Execute the below cmd to reproduce and fix the error.`},$t={[Xt]:`Failed to find expose module.`,[Zt]:`PublicPath is required in prod mode.`};({...K,...Qt,...$t});var en=`.then(callbacks[0]).catch(callbacks[1])`;async function tn({entry:t,remoteEntryExports:n}){return new Promise((r,i)=>{try{n?r(n):typeof FEDERATION_ALLOW_NEW_FUNCTION<`u`?Function(`callbacks`,`import("${t}")${en}`)([r,i]):e(()=>import(t).then(r),[]).catch(i)}catch(e){y(`Failed to load ESM entry from "${t}". ${e instanceof Error?e.message:String(e)}`)}})}async function nn({entry:e,remoteEntryExports:t}){return new Promise((n,r)=>{try{t?n(t):typeof __system_context__>`u`?System.import(e).then(n).catch(r):Function(`callbacks`,`System.import("${e}")${en}`)([n,r])}catch(t){y(`Failed to load SystemJS entry from "${e}". ${t instanceof Error?t.message:String(t)}`)}})}function rn(e,t,n){let{remoteEntryKey:r,entryExports:i}=Fe(e,t);return i||y(Lt,K,{remoteName:e,remoteEntryUrl:n,remoteEntryKey:r}),i}async function an({name:e,globalName:t,entry:n,remoteInfo:r,loaderHook:i,getEntryUrl:a}){let{entryExports:o}=Fe(e,t);if(o)return o;let s=a?a(n):n;return fe(s,{attrs:{},createScriptHook:(e,t)=>{let n=i.lifecycle.createScript.emit({url:e,attrs:t,remoteInfo:r});if(n&&(n instanceof HTMLScriptElement||`script`in n||`timeout`in n))return n}}).then(()=>rn(e,t,n),t=>{let n=t instanceof Error?t.message:String(t);y(Wt,K,{remoteName:e,resourceUrl:s},n)})}async function on({remoteInfo:e,remoteEntryExports:t,loaderHook:n,getEntryUrl:r}){let{entry:i,entryGlobalName:a,name:o,type:s}=e;switch(s){case`esm`:case`module`:return tn({entry:i,remoteEntryExports:t});case`system`:return nn({entry:i,remoteEntryExports:t});default:return an({entry:i,globalName:a,name:o,remoteInfo:e,loaderHook:n,getEntryUrl:r})}}function sn(e){let{entry:t,name:n}=e;return u(n,t)}async function cn(e){let{origin:t,remoteEntryExports:n,remoteInfo:r,getEntryUrl:i,_inErrorHandling:a=!1}=e,o=sn(r);if(n)return n;if(!E[o]){let e=t.remoteHandler.hooks.lifecycle.loadEntry,s=t.loaderHook;E[o]=e.emit({loaderHook:s,remoteInfo:r,remoteEntryExports:n}).then(e=>e||on({remoteInfo:r,remoteEntryExports:n,loaderHook:s,getEntryUrl:i})).catch(async e=>{let i=sn(r),o=e instanceof Error&&e.message.includes(`ScriptExecutionError`);if(e instanceof Error&&e.message.includes(`RUNTIME-008`)&&!o&&!a){let e=await t.loaderHook.lifecycle.loadEntryError.emit({getRemoteEntry:e=>cn({...e,_inErrorHandling:!0}),origin:t,remoteInfo:r,remoteEntryExports:n,globalLoading:E,uniqueKey:i});if(e)return e}throw e})}return E[o]}function q(e){return{...e,entry:`entry`in e?e.entry:``,type:e.type||`global`,entryGlobalName:e.entryGlobalName||e.name,shareScope:e.shareScope||`default`}}function ln(){return typeof FEDERATION_BUILD_IDENTIFIER<`u`?FEDERATION_BUILD_IDENTIFIER:``}function un(e,t){let n=Ie(),r=[t.hooks,t.remoteHandler.hooks,t.sharedHandler.hooks,t.snapshotHandler.hooks,t.loaderHook,t.bridgeHook];return n.length>0&&n.forEach(t=>{e?.find(e=>e.name!==t.name)&&e.push(t)}),e&&e.length>0&&e.forEach(e=>{r.forEach(n=>{n.applyPlugin(e,t)})}),e}function dn(e){return{name:e.name,alias:e.alias,entry:`entry`in e?e.entry:void 0,version:`version`in e?e.version:void 0,type:e.type,entryGlobalName:e.entryGlobalName,shareScope:e.shareScope}}function J(e){let t={};for(let[n,r]of Object.entries(e.shared)){let e=r[0];e&&(t[n]={version:e.version,singleton:e.shareConfig?.singleton,requiredVersion:e.shareConfig?.requiredVersion===!1?!1:e.shareConfig?.requiredVersion,eager:e.eager,strictVersion:e.shareConfig?.strictVersion})}return{project:{name:e.name,mfRole:e.remotes?.length>0?`host`:`unknown`},mfConfig:{name:e.name,remotes:e.remotes?.map(dn)??[],shared:t}}}function fn(e){return{resourceCategory:`sync`,share:!0,depsRemote:!0,prefetchInterface:!1,...e}}function pn(e,t){return t.map(t=>{let n=It(e,t.nameOrAlias);return v(n,`Unable to preload ${t.nameOrAlias} as it is not included in ${!n&&p({remoteInfo:n,remotes:e})}`),{remote:n,preloadConfig:fn(t)}})}function mn(e){return e?e.map(e=>e===`.`?e:e.startsWith(`./`)?e.replace(`./`,``):e):[]}function hn(e,t,n,r=!0){let{cssAssets:i,jsAssetsWithoutEntry:a,entryAssets:o}=n;if(t.options.inBrowser){if(o.forEach(n=>{let{moduleInfo:r}=n,i=t.moduleCache.get(e.name);cn(i?{origin:t,remoteInfo:r,remoteEntryExports:i.remoteEntryExports}:{origin:t,remoteInfo:r,remoteEntryExports:void 0})}),r){let n={rel:`preload`,as:`style`};i.forEach(r=>{let{link:i,needAttach:a}=de({url:r,cb:()=>{},attrs:n,createLinkHook:(n,r)=>{let i=t.loaderHook.lifecycle.createLink.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLLinkElement)return i}});a&&document.head.appendChild(i)})}else{let n={rel:`stylesheet`,type:`text/css`};i.forEach(r=>{let{link:i,needAttach:a}=de({url:r,cb:()=>{},attrs:n,createLinkHook:(n,r)=>{let i=t.loaderHook.lifecycle.createLink.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLLinkElement)return i},needDeleteLink:!1});a&&document.head.appendChild(i)})}if(r){let n={rel:`preload`,as:`script`};a.forEach(r=>{let{link:i,needAttach:a}=de({url:r,cb:()=>{},attrs:n,createLinkHook:(n,r)=>{let i=t.loaderHook.lifecycle.createLink.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLLinkElement)return i}});a&&document.head.appendChild(i)})}else{let n={fetchpriority:`high`,type:e?.type===`module`?`module`:`text/javascript`};a.forEach(r=>{let{script:i,needAttach:a}=ue({url:r,cb:()=>{},attrs:n,createScriptHook:(n,r)=>{let i=t.loaderHook.lifecycle.createScript.emit({url:n,attrs:r,remoteInfo:e});if(i instanceof HTMLScriptElement)return i},needDeleteScript:!0});a&&document.head.appendChild(i)})}}}function gn(e,t,n){let r=t,i=Array.isArray(e.shareScope)?e.shareScope:[e.shareScope];i.length||i.push(`default`),i.forEach(e=>{r[e]||(r[e]={})});let a={version:e.version||``,shareScopeKeys:Array.isArray(e.shareScope)?i:e.shareScope||`default`};return Object.defineProperty(a,`shareScopeMap`,{value:r,enumerable:!1}),{remoteEntryInitOptions:a,shareScope:r[i[0]],initScope:n??[]}}var _n=class{constructor({remoteInfo:e,host:t}){this.inited=!1,this.initing=!1,this.lib=void 0,this.remoteInfo=e,this.host=t}async getEntry(){if(this.remoteEntryExports)return this.remoteEntryExports;let e=await cn({origin:this.host,remoteInfo:this.remoteInfo,remoteEntryExports:this.remoteEntryExports});return v(e,`remoteEntryExports is undefined \n ${p(this.remoteInfo)}`),this.remoteEntryExports=e,this.remoteEntryExports}async init(e,t,n){let r=await this.getEntry();if(this.inited)return r;if(this.initPromise)return await this.initPromise,r;this.initing=!0,this.initPromise=(async()=>{let{remoteEntryInitOptions:i,shareScope:a,initScope:o}=gn(this.remoteInfo,this.host.shareScopeMap,n),s=await this.host.hooks.lifecycle.beforeInitContainer.emit({shareScope:a,remoteEntryInitOptions:i,initScope:o,remoteInfo:this.remoteInfo,origin:this.host});r?.init===void 0&&y(Rt,K,{hostName:this.host.name,remoteName:this.remoteInfo.name,remoteEntryUrl:this.remoteInfo.entry,remoteEntryKey:this.remoteInfo.entryGlobalName},void 0,J(this.host.options)),await r.init(s.shareScope,s.initScope,s.remoteEntryInitOptions),await this.host.hooks.lifecycle.initContainer.emit({...s,id:e,remoteSnapshot:t,remoteEntryExports:r}),this.inited=!0})();try{await this.initPromise}finally{this.initing=!1,this.initPromise=void 0}return r}async get(e,t,n,r){let{loadFactory:i=!0}=n||{loadFactory:!0},a=await this.init(e,r);this.lib=a;let o;o=await this.host.loaderHook.lifecycle.getModuleFactory.emit({remoteEntryExports:a,expose:t,moduleInfo:this.remoteInfo}),o||=await a.get(t),v(o,`${b(this.remoteInfo)} remote don't export ${t}.`);let s=Ee(this.remoteInfo.name,t),c=this.wraperFactory(o,s);return i?await c():c}wraperFactory(e,t){function n(e,t){e&&typeof e==`object`&&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 r=await e();return n(r,t),r}:()=>{let r=e();return n(r,t),r}}},Y=class{constructor(e){this.type=``,this.listeners=new Set,e&&(this.type=e)}on(e){typeof e==`function`&&this.listeners.add(e)}once(e){let t=this;this.on(function n(...r){return t.remove(n),e.apply(null,r)})}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()}},X=class extends Y{emit(...e){let t,n=Array.from(this.listeners);if(n.length>0){let r=0,i=t=>t===!1?!1:r<n.length?Promise.resolve(n[r++].apply(null,e)).then(i):t;t=i()}return Promise.resolve(t)}};function vn(e,t){if(!xe(t))return!1;if(e!==t){for(let n in e)if(!(n in t))return!1}return!0}var Z=class extends Y{constructor(e){super(),this.onerror=y,this.type=e}emit(e){xe(e)||y(`The data for the "${this.type}" hook should be an object.`);for(let t of this.listeners)try{let n=t(e);if(vn(e,n))e=n;else{this.onerror(`A plugin returned an unacceptable value for the "${this.type}" type.`);break}}catch(e){_e(e),this.onerror(e)}return e}},Q=class extends Y{constructor(e){super(),this.onerror=y,this.type=e}emit(e){xe(e)||y(`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,r=t=>(_e(t),this.onerror(t),e),i=a=>{if(vn(e,a)){if(e=a,n<t.length)try{return Promise.resolve(t[n++](e)).then(i,r)}catch(e){return r(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)}},$=class{constructor(e){this.registerPlugins={},this.lifecycle=e,this.lifecycleKeys=Object.keys(e)}applyPlugin(e,t){v(Ce(e),`Plugin configuration is invalid.`);let n=e.name;v(n,`A name must be provided by the plugin.`),this.registerPlugins[n]||(this.registerPlugins[n]=e,e.apply?.(t),Object.keys(this.lifecycle).forEach(t=>{let n=e[t];n&&this.lifecycle[t].on(n)}))}removePlugin(e){v(e,`A name is required.`);let t=this.registerPlugins[e];v(t,`The plugin "${e}" is not registered.`),Object.keys(t).forEach(e=>{e!==`name`&&this.lifecycle[e].remove(t[e])})}};function yn(e,t){let n=Te(t);n.url||y(qt,K,{remoteName:e.name});let r=d(t,n.url);e.type=n.type,e.entryGlobalName=n.globalName,e.entry=r,e.version=t.version,e.buildVersion=t.buildVersion}function bn(){return{name:`snapshot-plugin`,async afterResolve(e){let{remote:t,pkgNameOrAlias:n,expose:r,origin:i,remoteInfo:a,id:o}=e;if(!ye(t)||!be(t)){let{remoteSnapshot:s,globalSnapshot:c}=await i.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:t,id:o});yn(a,s);let l={remote:t,preloadConfig:{nameOrAlias:n,exposes:[r],resourceCategory:`sync`,share:!1,depsRemote:!1}},u=await i.remoteHandler.hooks.lifecycle.generatePreloadAssets.emit({origin:i,preloadOptions:l,remoteInfo:a,remote:t,remoteSnapshot:s,globalSnapshot:c});return u&&hn(a,i,u,!1),{...e,remoteSnapshot:s}}return e}}}function xn(e){let t=e.split(`:`);return t.length===1?{name:t[0],version:void 0}:t.length===2?{name:t[0],version:t[1]}:{name:t[1],version:t[2]}}function Sn(e,t,n,r,i={},a){let{value:o}=D(e,b(t)),s=a||o;if(s&&!h(s)&&(n(s,t,r),s.remotesInfo)){let t=Object.keys(s.remotesInfo);for(let r of t){if(i[r])continue;i[r]=!0;let t=xn(r),a=s.remotesInfo[r];Sn(e,{name:t.name,version:a.matchedVersion},n,!1,i,void 0)}}}var Cn=(e,t)=>document.querySelector(`${e}[${e===`link`?`href`:`src`}="${t}"]`);function wn(e,t,n,r,i){let a=[],o=[],s=[],c=new Set,l=new Set,{options:u}=e,{preloadConfig:f}=t,{depsRemote:p}=f;if(Sn(r,n,(t,n,r)=>{let i;if(r)i=f;else if(Array.isArray(p)){let e=p.find(e=>e.nameOrAlias===n.name||e.nameOrAlias===n.alias);if(!e)return;i=fn(e)}else if(p===!0)i=f;else return;let c=d(t,Te(t).url);c&&s.push({name:n.name,moduleInfo:{name:n.name,entry:c,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:c});let l=`modules`in t?t.modules:[],u=mn(i.exposes);u.length&&`modules`in t&&(l=t?.modules?.reduce((e,t)=>(u?.indexOf(t.moduleName)!==-1&&e.push(t),e),[]));function m(e){let n=e.map(e=>d(t,e));return i.filter?n.filter(i.filter):n}if(l){let r=l.length;for(let s=0;s<r;s++){let r=l[s],c=`${n.name}/${r.moduleName}`;e.remoteHandler.hooks.lifecycle.handlePreloadModule.emit({id:r.moduleName===`.`?n.name:c,name:n.name,remoteSnapshot:t,preloadConfig:i,remote:n,origin:e}),!Le(c)&&(i.resourceCategory===`all`?(a.push(...m(r.assets.css.async)),a.push(...m(r.assets.css.sync)),o.push(...m(r.assets.js.async)),o.push(...m(r.assets.js.sync))):i.resourceCategory===`sync`&&(a.push(...m(r.assets.css.sync)),o.push(...m(r.assets.js.sync))),Re(c))}}},!0,{},i),i.shared&&i.shared.length>0){let t=(t,n)=>{let{shared:r}=U(e.shareScopeMap,n.sharedName,t,e.sharedHandler.hooks.lifecycle.resolveShare)||{};r&&typeof r.lib==`function`&&(n.assets.js.sync.forEach(e=>{c.add(e)}),n.assets.css.sync.forEach(e=>{l.add(e)}))};i.shared.forEach(e=>{let n=u.shared?.[e.sharedName];if(!n)return;let r=e.version?n.find(t=>t.version===e.version):n;r&&we(r).forEach(n=>{t(n,e)})})}let m=o.filter(e=>!c.has(e)&&!Cn(`script`,e));return{cssAssets:a.filter(e=>!l.has(e)&&!Cn(`link`,e)),jsAssetsWithoutEntry:m,entryAssets:s.filter(e=>!Cn(`script`,e.url))}}var Tn=function(){return{name:`generate-preload-assets-plugin`,async generatePreloadAssets(e){let{origin:t,preloadOptions:n,remoteInfo:r,remote:i,globalSnapshot:a,remoteSnapshot:o}=e;return ye(i)&&be(i)?{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[{name:i.name,url:i.entry,moduleInfo:{name:r.name,entry:i.entry,type:r.type||`global`,entryGlobalName:``,shareScope:``}}]}:(yn(r,o),wn(t,n,r,a,o))}}};function En(e,t){let n=O({name:t.name,version:t.options.version}),r=n&&`remotesInfo`in n&&n.remotesInfo&&D(n.remotesInfo,e.name).value;return r&&r.matchedVersion?{hostGlobalSnapshot:n,globalSnapshot:je(),remoteSnapshot:O({name:e.name,version:r.matchedVersion})}:{hostGlobalSnapshot:void 0,globalSnapshot:je(),remoteSnapshot:O({name:e.name,version:`version`in e?e.version:void 0})}}var Dn=class{constructor(e){this.loadingHostSnapshot=null,this.manifestCache=new Map,this.hooks=new $({beforeLoadRemoteSnapshot:new X(`beforeLoadRemoteSnapshot`),loadSnapshot:new Q(`loadGlobalSnapshot`),loadRemoteSnapshot:new Q(`loadRemoteSnapshot`),afterLoadSnapshot:new Q(`afterLoadSnapshot`)}),this.manifestLoading=C.__FEDERATION__.__MANIFEST_LOADING__,this.HostInstance=e,this.loaderHook=e.loaderHook}async loadRemoteSnapshotInfo({moduleInfo:e,id:t,expose:n}){let{options:r}=this.HostInstance;await this.hooks.lifecycle.beforeLoadRemoteSnapshot.emit({options:r,moduleInfo:e});let i=O({name:this.HostInstance.options.name,version:this.HostInstance.options.version});i||(i={version:this.HostInstance.options.version||``,remoteEntry:``,remotesInfo:{}},Pe({[this.HostInstance.options.name]:i})),i&&`remotesInfo`in i&&!D(i.remotesInfo,e.name).value&&(`version`in e||`entry`in e)&&(i.remotesInfo={...i?.remotesInfo,[e.name]:{matchedVersion:`version`in e?e.version:e.entry}});let{hostGlobalSnapshot:a,remoteSnapshot:o,globalSnapshot:s}=this.getGlobalRemoteInfo(e),{remoteSnapshot:c,globalSnapshot:l}=await this.hooks.lifecycle.loadSnapshot.emit({options:r,moduleInfo:e,hostGlobalSnapshot:a,remoteSnapshot:o,globalSnapshot:s}),u,d;if(c)if(h(c)){let t=c.remoteEntry,n=await this.getManifestJson(t,e,{}),r=Ne({...e,entry:t},n);u=n,d=r}else{let{remoteSnapshot:t}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:c,from:`global`});u=t,d=l}else if(ye(e)){let t=await this.getManifestJson(e.entry,e,{}),n=Ne(e,t),{remoteSnapshot:r}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:t,from:`global`});u=r,d=n}else y(Ut,K,{remoteName:e.name,remoteVersion:e.version,hostName:this.HostInstance.options.name,globalSnapshot:JSON.stringify(l)},void 0,J(this.HostInstance.options));return await this.hooks.lifecycle.afterLoadSnapshot.emit({id:t,host:this.HostInstance,options:r,moduleInfo:e,remoteSnapshot:u}),{remoteSnapshot:u,globalSnapshot:d}}getGlobalRemoteInfo(e){return En(e,this.HostInstance)}async getManifestJson(e,t,n){let r=async()=>{let n=this.manifestCache.get(e);if(n)return n;try{let r=await this.loaderHook.lifecycle.fetch.emit(e,{},q(t));(!r||!(r instanceof Response))&&(r=await fetch(e,{})),n=await r.json()}catch(r){n=await this.HostInstance.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:r,from:`runtime`,lifecycle:`afterResolve`,origin:this.HostInstance}),n||(delete this.manifestLoading[e],y(zt,K,{manifestUrl:e,moduleName:t.name,hostName:this.HostInstance.options.name},`${r}`,J(this.HostInstance.options)))}return v(n.metaData&&n.exposes&&n.shared,`"${e}" is not a valid federation manifest for remote "${t.name}". Missing required fields: ${[!n.metaData&&`metaData`,!n.exposes&&`exposes`,!n.shared&&`shared`].filter(Boolean).join(`, `)}.`),this.manifestCache.set(e,n),n},i=async()=>{let n=await r(),i=te(n,{version:e}),{remoteSnapshot:a}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:t,manifestJson:n,remoteSnapshot:i,manifestUrl:e,from:`manifest`});return a};return this.manifestLoading[e]||(this.manifestLoading[e]=i().then(e=>e)),this.manifestLoading[e]}},On=class{constructor(e){this.hooks=new $({beforeRegisterShare:new Z(`beforeRegisterShare`),afterResolve:new Q(`afterResolve`),beforeLoadShare:new Q(`beforeLoadShare`),loadShare:new X,resolveShare:new Z(`resolveShare`),initContainerShareScopeMap:new Z(`initContainerShareScopeMap`)}),this.host=e,this.shareScopeMap={},this.initTokens={},this._setGlobalShareScopeMap(e.options)}registerShared(e,t){let{newShareInfos:n,allShareInfos:r}=Dt(e,t);return Object.keys(n).forEach(e=>{n[e].forEach(n=>{n.scope.forEach(r=>{this.hooks.lifecycle.beforeRegisterShare.emit({origin:this.host,pkgName:e,shared:n}),this.shareScopeMap[r]?.[e]||this.setShared({pkgName:e,lib:n.lib,get:n.get,loaded:n.loaded||!!n.lib,shared:n,from:t.name})})})}),{newShareInfos:n,allShareInfos:r}}async loadShare(e,t){let{host:n}=this,r=Pt({pkgName:e,extraOptions:t,shareInfos:n.options.shared});r?.scope&&await Promise.all(r.scope.map(async e=>{await Promise.all(this.initializeSharing(e,{strategy:r.strategy}))}));let{shareInfo:i}=await this.hooks.lifecycle.beforeLoadShare.emit({pkgName:e,shareInfo:r,shared:n.options.shared,origin:n});v(i,`Cannot find shared "${e}" in host "${n.options.name}". Ensure the shared config for "${e}" is declared in the federation plugin options and the host has been initialized before loading shares.`);let{shared:a,useTreesShaking:o}=U(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare)||{};if(a){let t=G(a,o);if(t.lib)return W(t,n.options.name),t.lib;if(t.loading&&!t.loaded){let e=await t.loading;return t.loaded=!0,t.lib||=e,W(t,n.options.name),e}else{let r=(async()=>{let e=await t.get();return W(t,n.options.name),t.loaded=!0,t.lib=e,e})();return this.setShared({pkgName:e,loaded:!1,shared:a,from:n.options.name,lib:null,loading:r,treeShaking:o?t:void 0}),r}}else{if(t?.customShareInfo)return!1;let r=R(i.treeShaking),a=G(i,r),o=(async()=>{let t=await a.get();a.lib=t,a.loaded=!0,W(a,n.options.name);let{shared:r,useTreesShaking:o}=U(this.shareScopeMap,e,i,this.hooks.lifecycle.resolveShare)||{};if(r){let e=G(r,o);e.lib=t,e.loaded=!0,r.from=i.from}return t})();return this.setShared({pkgName:e,loaded:!1,shared:i,from:n.options.name,lib:null,loading:o,treeShaking:r?a:void 0}),o}}initializeSharing(e=L,t){let{host:n}=this,r=t?.from,i=t?.strategy,a=t?.initScope,o=[];if(r!==`build`){let{initTokens:t}=this;a||=[];let n=t[e];if(n||=t[e]={from:this.host.name},a.indexOf(n)>=0)return o;a.push(n)}let s=this.shareScopeMap,c=n.options.name;s[e]||(s[e]={});let l=s[e],u=(e,t)=>{let{version:n,eager:r}=t;l[e]=l[e]||{};let i=l[e],a=i[n]&&G(i[n]),o=!!(a&&(`eager`in a&&a.eager||`shareConfig`in a&&a.shareConfig?.eager));(!a||a.strategy!==`loaded-first`&&!a.loaded&&(!r==!o?c>i[n].from:r))&&(i[n]=t)},d=async e=>{let{module:t}=await n.remoteHandler.getRemoteModuleAndOptions({id:e}),r;try{r=await t.getEntry()}catch(t){if(r=await n.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:t,from:`runtime`,lifecycle:`beforeLoadShare`,origin:n}),!r)return}finally{r?.init&&!t.initing&&(t.remoteEntryExports=r,await t.init(void 0,void 0,a))}};return Object.keys(n.options.shared).forEach(t=>{n.options.shared[t].forEach(n=>{n.scope.includes(e)&&u(t,n)})}),(n.options.shareStrategy===`version-first`||i===`version-first`)&&n.options.remotes.forEach(t=>{t.shareScope===e&&o.push(d(t.name))}),o}loadShareSync(e,t){let{host:n}=this,r=Pt({pkgName:e,extraOptions:t,shareInfos:n.options.shared});r?.scope&&r.scope.forEach(e=>{this.initializeSharing(e,{strategy:r.strategy})});let{shared:i,useTreesShaking:a}=U(this.shareScopeMap,e,r,this.hooks.lifecycle.resolveShare)||{};if(i){if(typeof i.lib==`function`)return W(i,n.options.name),i.loaded||(i.loaded=!0,i.from===n.options.name&&(r.loaded=!0)),i.lib;if(typeof i.get==`function`){let t=i.get();if(!(t instanceof Promise))return W(i,n.options.name),this.setShared({pkgName:e,loaded:!0,from:n.options.name,lib:t,shared:i}),t}}if(r.lib)return r.loaded||=!0,r.lib;if(r.get){let i=r.get();return i instanceof Promise&&y(t?.from===`build`?Vt:Ht,K,{hostName:n.options.name,sharedPkgName:e},void 0,J(n.options)),r.lib=i,this.setShared({pkgName:e,loaded:!0,from:n.options.name,lib:r.lib,shared:r}),r.lib}y(Ht,K,{hostName:n.options.name,sharedPkgName:e},void 0,J(n.options))}initShareScopeMap(e,t,n={}){let{host:r}=this;this.shareScopeMap[e]=t,this.hooks.lifecycle.initContainerShareScopeMap.emit({shareScope:t,options:r.options,origin:r,scopeName:e,hostShareScopeMap:n.hostShareScopeMap})}setShared({pkgName:e,shared:t,from:n,lib:r,loading:i,loaded:a,get:o,treeShaking:s}){let{version:c,scope:l=`default`,...u}=t,d=Array.isArray(l)?l:[l],f=e=>{let t=(e,t,n)=>{n&&!e[t]&&(e[t]=n)},n=s?e.treeShaking:e;t(n,`loaded`,a),t(n,`loading`,i),t(n,`get`,o)};d.forEach(t=>{this.shareScopeMap[t]||(this.shareScopeMap[t]={}),this.shareScopeMap[t][e]||(this.shareScopeMap[t][e]={}),this.shareScopeMap[t][e][c]||(this.shareScopeMap[t][e][c]={version:c,scope:[t],...u,lib:r});let i=this.shareScopeMap[t][e][c];f(i),n&&i.from!==n&&(i.from=n)})}_setGlobalShareScopeMap(e){let t=Nt(),n=e.id||e.name;n&&!t[n]&&(t[n]=this.shareScopeMap)}},kn=class{constructor(e){this.hooks=new $({beforeRegisterRemote:new Z(`beforeRegisterRemote`),registerRemote:new Z(`registerRemote`),beforeRequest:new Q(`beforeRequest`),onLoad:new X(`onLoad`),handlePreloadModule:new Y(`handlePreloadModule`),errorLoadRemote:new X(`errorLoadRemote`),beforePreloadRemote:new X(`beforePreloadRemote`),generatePreloadAssets:new X(`generatePreloadAssets`),afterPreloadRemote:new X,loadEntry:new X}),this.host=e,this.idToRemoteMap={}}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:r}=t,{name:i,alias:a}=n;if(this.idToRemoteMap[e]={name:n.name,expose:r},a&&e.startsWith(i)){let t=e.replace(i,a);this.idToRemoteMap[t]={name:n.name,expose:r};return}if(a&&e.startsWith(a)){let t=e.replace(a,i);this.idToRemoteMap[t]={name:n.name,expose:r}}}async loadRemote(e,t){let{host:n}=this;try{let{loadFactory:r=!0}=t||{loadFactory:!0},{module:i,moduleOptions:a,remoteMatchInfo:o}=await this.getRemoteModuleAndOptions({id:e}),{pkgNameOrAlias:s,remote:c,expose:l,id:u,remoteSnapshot:d}=o,f=await i.get(u,l,t,d),p=await this.hooks.lifecycle.onLoad.emit({id:u,pkgNameOrAlias:s,expose:l,exposeModule:r?f:void 0,exposeModuleFactory:r?void 0:f,remote:c,options:a,moduleInstance:i,origin:n});return this.setIdToRemoteMap(e,o),typeof p==`function`?p:f}catch(r){let{from:i=`runtime`}=t||{from:`runtime`},a=await this.hooks.lifecycle.errorLoadRemote.emit({id:e,error:r,from:i,lifecycle:`onLoad`,origin:n});if(!a)throw r;return a}}async preloadRemote(e){let{host:t}=this;await this.hooks.lifecycle.beforePreloadRemote.emit({preloadOps:e,options:t.options,origin:t});let n=pn(t.options.remotes,e);await Promise.all(n.map(async e=>{let{remote:n}=e,r=q(n),{globalSnapshot:i,remoteSnapshot:a}=await t.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:n}),o=await this.hooks.lifecycle.generatePreloadAssets.emit({origin:t,preloadOptions:e,remote:n,remoteInfo:r,globalSnapshot:i,remoteSnapshot:a});o&&hn(r,t,o)}))}registerRemotes(e,t){let{host:n}=this;e.forEach(e=>{this.registerRemote(e,n.options.remotes,{force:t?.force})})}async getRemoteModuleAndOptions(e){let{host:t}=this,{id:n}=e,r;try{r=await this.hooks.lifecycle.beforeRequest.emit({id:n,options:t.options,origin:t})}catch(e){if(r=await this.hooks.lifecycle.errorLoadRemote.emit({id:n,options:t.options,origin:t,from:`runtime`,error:e,lifecycle:`beforeRequest`}),!r)throw e}let{id:i}=r,a=Ft(t.options.remotes,i);a||y(Bt,K,{hostName:t.options.name,requestId:i},void 0,J(t.options));let{remote:o}=a,s=q(o),c=await t.sharedHandler.hooks.lifecycle.afterResolve.emit({id:i,...a,options:t.options,origin:t,remoteInfo:s}),{remote:l,expose:u}=c;v(l&&u,`The 'beforeRequest' hook was executed, but it failed to return the correct 'remote' and 'expose' values while loading ${i}.`);let d=t.moduleCache.get(l.name),f={host:t,remoteInfo:s};return d||(d=new _n(f),t.moduleCache.set(l.name,d)),{module:d,moduleOptions:f,remoteMatchInfo:c}}registerRemote(e,t,n){let{host:r}=this,i=()=>{if(e.alias){let n=t.find(t=>e.alias&&(t.name.startsWith(e.alias)||t.alias?.startsWith(e.alias)));v(!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&&typeof window<`u`&&!e.entry.startsWith(`http`)&&(e.entry=new URL(e.entry,window.location.origin).href),e.shareScope||=L,e.type||=Tt};this.hooks.lifecycle.beforeRegisterRemote.emit({remote:e,origin:r});let a=t.find(t=>t.name===e.name);if(!a)i(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:r});else{let o=[`The remote "${e.name}" is already registered.`,`Please note that overriding it may cause unexpected errors.`];n?.force&&(this.removeRemote(a),i(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:r}),f(o.join(` `)))}}removeRemote(e){try{let{host:t}=this,{name:n}=e,r=t.options.remotes.findIndex(e=>e.name===n);r!==-1&&t.options.remotes.splice(r,1);let i=t.moduleCache.get(e.name);if(i){let n=i.remoteInfo,r=n.entryGlobalName;x[r]&&(Object.getOwnPropertyDescriptor(x,r)?.configurable?delete x[r]:x[r]=void 0);let a=sn(i.remoteInfo);E[a]&&delete E[a],t.snapshotHandler.manifestCache.delete(n.entry);let o=n.buildVersion?u(n.name,n.buildVersion):n.name,s=x.__FEDERATION__.__INSTANCES__.findIndex(e=>n.buildVersion?e.options.id===o:e.name===o);if(s!==-1){let e=x.__FEDERATION__.__INSTANCES__[s];o=e.options.id||o;let t=Nt(),r=!0,i=[];Object.keys(t).forEach(e=>{let a=t[e];a&&Object.keys(a).forEach(t=>{let o=a[t];o&&Object.keys(o).forEach(a=>{let s=o[a];s&&Object.keys(s).forEach(o=>{let c=s[o];c&&typeof c==`object`&&c.from===n.name&&(c.loaded||c.loading?(c.useIn=c.useIn.filter(e=>e!==n.name),c.useIn.length?r=!1:i.push([e,t,a,o])):i.push([e,t,a,o]))})})})}),r&&(e.shareScopeMap={},delete t[o]),i.forEach(([e,n,r,i])=>{delete t[e]?.[n]?.[r]?.[i]}),x.__FEDERATION__.__INSTANCES__.splice(s,1)}let{hostGlobalSnapshot:c}=En(e,t);if(c){let t=c&&`remotesInfo`in c&&c.remotesInfo&&D(c.remotesInfo,e.name).key;t&&(delete c.remotesInfo[t],C.__FEDERATION__.__MANIFEST_LOADING__[t]&&delete C.__FEDERATION__.__MANIFEST_LOADING__[t])}t.moduleCache.delete(e.name)}}catch(e){ge.error(`removeRemote failed: ${e instanceof Error?e.message:String(e)}`)}}},An=typeof FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN==`boolean`?!FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN:!0,jn=class{constructor(e){this.hooks=new $({beforeInit:new Z(`beforeInit`),init:new Y,beforeInitContainer:new Q(`beforeInitContainer`),initContainer:new Q(`initContainer`)}),this.version=`2.3.3`,this.moduleCache=new Map,this.loaderHook=new $({getModuleInfo:new Y,createScript:new Y,createLink:new Y,fetch:new X,loadEntryError:new X,getModuleFactory:new X}),this.bridgeHook=new $({beforeBridgeRender:new Y,afterBridgeRender:new Y,beforeBridgeDestroy:new Y,afterBridgeDestroy:new Y});let t=An?[bn(),Tn()]:[],n={id:ln(),name:e.name,plugins:t,remotes:[],shared:{},inBrowser:!0};this.name=e.name,this.options=n,this.snapshotHandler=new Dn(this),this.sharedHandler=new On(this),this.remoteHandler=new kn(this),this.shareScopeMap=this.sharedHandler.shareScopeMap,this.registerPlugins([...n.plugins,...e.plugins||[]]),this.options=this.formatOptions(n,e)}initOptions(e){e.name&&e.name!==this.options.name&&y(me(Kt,K)),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=L,t){return this.sharedHandler.initializeSharing(e,t)}initRawContainer(e,t,n){let r=q({name:e,entry:t}),i=new _n({host:this,remoteInfo:r});return i.remoteEntryExports=n,this.moduleCache.set(e,i),i}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{allShareInfos:n}=Dt(e,t),{userOptions:r,options:i}=this.hooks.lifecycle.beforeInit.emit({origin:this,userOptions:t,options:e,shareInfo:n}),a=this.remoteHandler.formatAndRegisterRemote(i,r),{allShareInfos:o}=this.sharedHandler.registerShared(i,r),s=[...i.plugins];r.plugins&&r.plugins.forEach(e=>{s.includes(e)||s.push(e)});let c={...e,...t,plugins:s,remotes:a,shared:o};return this.hooks.lifecycle.init.emit({origin:this,options:c}),c}registerPlugins(e){let t=un(e,this);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)}registerShared(e){this.sharedHandler.registerShared(this.options,{...this.options,shared:e})}};function Mn(e){let t=new((ke())||jn)(e);return Oe(t),t}Ae(jn);export{Mn as t};
|