iobroker.iot 5.0.13 → 6.0.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 +6 -6
- package/admin/assets/index-39e7CNHj.js +705 -0
- package/admin/index_m.html +1 -1
- package/admin/rules/@mf-types/compiled-types/ActionVisu.d.ts +1 -1
- package/admin/rules/@mf-types.zip +0 -0
- package/admin/rules/assets/{ActionVisu-BN0Kjfo9.js → ActionVisu-BCZFwf_Y.js} +1 -1
- package/admin/rules/assets/{index-FrXvyqvW.js → index-DYx5xsZT.js} +76 -76
- package/admin/rules/assets/{localSharedImportMap-8wECk2hR.js → localSharedImportMap-CNn4MUou.js} +1 -1
- package/admin/rules/assets/{virtualExposes-b6CxLzZb.js → virtualExposes-B2aPQUg7.js} +1 -1
- package/admin/rules/customRuleBlocks.js +2 -2
- package/admin/rules/mf-stats.json +1 -1
- package/build/lib/AlexaSmartHomeV3/Alexa/Directives/Discovery.js +2 -1
- package/build/lib/AlexaSmartHomeV3/Alexa/Directives/Discovery.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/AirCondition.js +2 -2
- package/build/lib/AlexaSmartHomeV3/Controls/AirCondition.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Ct.js +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Ct.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Rgb.js +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Rgb.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/RgbSingle.js +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/RgbSingle.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/RgbwSingle.js +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/RgbwSingle.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Thermostat.js +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Thermostat.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Controls/Volume.js +2 -2
- package/build/lib/AlexaSmartHomeV3/Controls/Volume.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/DeviceManager.js +18 -9
- package/build/lib/AlexaSmartHomeV3/DeviceManager.js.map +1 -1
- package/build/lib/AlexaSmartHomeV3/Helpers/DiscoveryValidator.js +283 -0
- package/build/lib/AlexaSmartHomeV3/Helpers/DiscoveryValidator.js.map +1 -0
- package/build/lib/AlexaSmartHomeV3/Helpers/Utils.js +4 -0
- package/build/lib/AlexaSmartHomeV3/Helpers/Utils.js.map +1 -1
- package/build/lib/alisa.js +15 -14
- package/build/lib/googleHome.js +151 -207
- package/io-package.json +14 -14
- package/package.json +1 -1
- package/admin/assets/index-DCr4hGKK.js +0 -705
package/admin/rules/assets/{localSharedImportMap-8wECk2hR.js → localSharedImportMap-CNn4MUou.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a={"@iobroker/adapter-react-v5":async()=>await import("./index-
|
|
1
|
+
const a={"@iobroker/adapter-react-v5":async()=>await import("./index-DYx5xsZT.js"),react:async()=>await import("./index-Ccpql4vu.js").then(t=>t.i),"react-dom":async()=>await import("./index-DiSsXjpZ.js").then(t=>t.i)},n={"@iobroker/adapter-react-v5":{name:"@iobroker/adapter-react-v5",version:"8.1.6",scope:["default"],loaded:!1,from:"ActionVisu",async get(){n["@iobroker/adapter-react-v5"].loaded=!0;const{"@iobroker/adapter-react-v5":e}=a,r={...await e()};return Object.defineProperty(r,"__esModule",{value:!0,enumerable:!1}),function(){return r}},shareConfig:{singleton:!0,requiredVersion:"*"}},react:{name:"react",version:"18.3.1",scope:["default"],loaded:!1,from:"ActionVisu",async get(){n.react.loaded=!0;const{react:e}=a,r={...await e()};return Object.defineProperty(r,"__esModule",{value:!0,enumerable:!1}),function(){return r}},shareConfig:{singleton:!0,requiredVersion:"*"}},"react-dom":{name:"react-dom",version:"18.3.1",scope:["default"],loaded:!1,from:"ActionVisu",async get(){n["react-dom"].loaded=!0;const{"react-dom":e}=a,r={...await e()};return Object.defineProperty(r,"__esModule",{value:!0,enumerable:!1}),function(){return r}},shareConfig:{singleton:!0,requiredVersion:"*"}}},s=[];export{s as usedRemotes,n as usedShared};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const u={},o=new Set;async function c(r){if(typeof document>"u")return;const s=u[r]||[];await Promise.all(s.map(n=>{const e=new URL(n,import.meta.url).href;return o.has(e)||(o.add(e),document.querySelector(`link[rel="stylesheet"][data-mf-href="${e}"]`))?Promise.resolve():new Promise((i,a)=>{const t=document.createElement("link");t.rel="stylesheet",t.href=e,t.setAttribute("data-mf-href",e),t.onload=()=>i(),t.onerror=()=>a(new Error(`[Module Federation] Failed to load CSS asset: ${e}`)),document.head.appendChild(t)})}))}const f={"./ActionVisu":async()=>{await c("./ActionVisu");const r=await import("./ActionVisu-
|
|
1
|
+
const u={},o=new Set;async function c(r){if(typeof document>"u")return;const s=u[r]||[];await Promise.all(s.map(n=>{const e=new URL(n,import.meta.url).href;return o.has(e)||(o.add(e),document.querySelector(`link[rel="stylesheet"][data-mf-href="${e}"]`))?Promise.resolve():new Promise((i,a)=>{const t=document.createElement("link");t.rel="stylesheet",t.href=e,t.setAttribute("data-mf-href",e),t.onload=()=>i(),t.onerror=()=>a(new Error(`[Module Federation] Failed to load CSS asset: ${e}`)),document.head.appendChild(t)})}))}const f={"./ActionVisu":async()=>{await c("./ActionVisu");const r=await import("./ActionVisu-BCZFwf_Y.js"),s={};return Object.assign(s,r),Object.defineProperty(s,"__esModule",{value:!0,enumerable:!1}),s}};export{f as default};
|
|
@@ -3,5 +3,5 @@ var ir={},ar={},Tt={},P={},D={},v={};const ln="federation-manifest.json",cn=".js
|
|
|
3
3
|
${r.slice(0,5).join(`
|
|
4
4
|
`)}`:void 0}catch{return}}var Sr=class{constructor(e,t=ge){this.prefix=e,this.delegate=t??ge}setPrefix(e){this.prefix=e}setDelegate(e){this.delegate=e??ge}emit(e,t){const r=this.delegate,n=Ot.isDebugMode()?Wn():void 0,o=n?[...t,n]:t,s=(()=>{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(const i of s){const a=r[i];if(typeof a=="function"){a.call(r,this.prefix,...o);return}}for(const i of s){const a=ge[i];if(typeof a=="function"){a.call(ge,this.prefix,...o);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){Ot.isDebugMode()&&this.emit("debug",e)}};function br(e){return new Sr(e)}function Rr(e){const t=new Sr(e);return Object.defineProperty(t,"__mf_infrastructure_logger__",{value:!0,enumerable:!1,configurable:!1}),t}function Bn(e,t,r){if(e.__mf_infrastructure_logger__&&t!=null&&t.getInfrastructureLogger)try{const n=t.getInfrastructureLogger(r);n&&typeof n=="object"&&(typeof n.log=="function"||typeof n.info=="function"||typeof n.warn=="function"||typeof n.error=="function")&&e.setDelegate(n)}catch{e.setDelegate(void 0)}}const Vn=br(yr),jn=Rr(yr);fe.bindLoggerToCompiler=Bn;fe.createInfrastructureLogger=Rr;fe.createLogger=br;fe.infrastructureLogger=jn;fe.logger=Vn;var de={};const Xn=H;async function Nt(e,t){try{return await e()}catch(r){!t&&Xn.warn(r);return}}function Ge(e,t){const r=/^(https?:)?\/\//i;return e.replace(r,"").replace(/\/$/,"")===t.replace(r,"").replace(/\/$/,"")}function Tr(e){let t=null,r=!0,n=2e4,o;const s=document.getElementsByTagName("script");for(let l=0;l<s.length;l++){const u=s[l],d=u.getAttribute("src");if(d&&Ge(d,e.url)){t=u,r=!1;break}}if(!t){const l=e.attrs;t=document.createElement("script"),t.type=(l==null?void 0:l.type)==="module"?"module":"text/javascript";let u;e.createScriptHook&&(u=e.createScriptHook(e.url,e.attrs),u instanceof HTMLScriptElement?t=u:typeof u=="object"&&("script"in u&&u.script&&(t=u.script),"timeout"in u&&u.timeout&&(n=u.timeout))),t.src||(t.src=e.url),l&&!u&&Object.keys(l).forEach(d=>{t&&(d==="async"||d==="defer"?t[d]=l[d]:t.getAttribute(d)||t.setAttribute(d,l[d]))})}let i=null;const a=typeof window<"u"?l=>{if(l.filename&&Ge(l.filename,e.url)){const u=new Error(`ScriptExecutionError: Script "${e.url}" loaded but threw a runtime error during execution: ${l.message} (${l.filename}:${l.lineno}:${l.colno})`);u.name="ScriptExecutionError",i=u}}:null;a&&window.addEventListener("error",a);const c=async(l,u)=>{clearTimeout(o),a&&window.removeEventListener("error",a);const d=()=>{if((u==null?void 0:u.type)==="error"){const f=new Error(u!=null&&u.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.)`);f.name="ScriptNetworkError",e!=null&&e.onErrorCallback&&(e==null||e.onErrorCallback(f))}else i?e!=null&&e.onErrorCallback&&(e==null||e.onErrorCallback(i)):e!=null&&e.cb&&(e==null||e.cb())};if(t&&(t.onerror=null,t.onload=null,Nt(()=>{const{needDeleteScript:f=!0}=e;f&&t!=null&&t.parentNode&&t.parentNode.removeChild(t)}),l&&typeof l=="function")){const f=l(u);if(f instanceof Promise){const h=await f;return d(),h}return d(),f}d()};return t.onerror=c.bind(null,t.onerror),t.onload=c.bind(null,t.onload),o=setTimeout(()=>{c(null,{type:"error",isTimeout:!0})},n),{script:t,needAttach:r}}function xn(e){let t=null,r=!0;const n=document.getElementsByTagName("link");for(let s=0;s<n.length;s++){const i=n[s],a=i.getAttribute("href"),c=i.getAttribute("rel");if(a&&Ge(a,e.url)&&c===e.attrs.rel){t=i,r=!1;break}}if(!t){t=document.createElement("link"),t.setAttribute("href",e.url);let s;const i=e.attrs;e.createLinkHook&&(s=e.createLinkHook(e.url,i),s instanceof HTMLLinkElement&&(t=s)),i&&!s&&Object.keys(i).forEach(a=>{t&&!t.getAttribute(a)&&t.setAttribute(a,i[a])})}const o=(s,i)=>{const a=()=>{(i==null?void 0:i.type)==="error"?e!=null&&e.onErrorCallback&&(e==null||e.onErrorCallback(i)):e!=null&&e.cb&&(e==null||e.cb())};if(t&&(t.onerror=null,t.onload=null,Nt(()=>{const{needDeleteLink:c=!0}=e;c&&t!=null&&t.parentNode&&t.parentNode.removeChild(t)}),s)){const c=s(i);return a(),c}a()};return t.onerror=o.bind(null,t.onerror),t.onload=o.bind(null,t.onload),{link:t,needAttach:r}}function Kn(e,t){const{attrs:r={},createScriptHook:n}=t;return new Promise((o,s)=>{const{script:i,needAttach:a}=Tr({url:e,cb:o,onErrorCallback:s,attrs:{fetchpriority:"high",...r},createScriptHook:n,needDeleteScript:!0});a&&document.head.appendChild(i)})}de.createLink=xn;de.createScript=Tr;de.isStaticResourcesEqual=Ge;de.loadScript=Kn;de.safeWrapper=Nt;var Mt={};const Yn=(e,t,r,n)=>{t(new Error("createScriptNode is disabled in non-Node.js environment"))},zn=(e,t)=>{throw new Error("loadScriptNode is disabled in non-Node.js environment")};Mt.createScriptNode=Yn;Mt.loadScriptNode=zn;var Ir={};function Jn(e,t,r){return function(n){if(n===!1)return!1;if(typeof n>"u")return e?t:!1;if(n===!0)return t;if(n&&typeof n=="object")return{...t,...n};throw new Error(`Unexpected type for \`${r}\`, expect boolean/undefined/object, got: ${typeof n}`)}}Ir.normalizeOptions=Jn;var Nr={};const Zn=e=>e;Nr.createModuleFederationConfig=Zn;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=v,r=lr,n=cr,o=ur,s=fr,i=dr,a=hr,c=J,l=H,u=ue,d=fe,f=de,h=Mt,m=Ir,_=Nr;e.BROWSER_LOG_KEY=t.BROWSER_LOG_KEY,e.ENCODE_NAME_PREFIX=t.ENCODE_NAME_PREFIX,e.EncodedNameTransformMap=t.EncodedNameTransformMap,e.FederationModuleManifest=t.FederationModuleManifest,e.MANIFEST_EXT=t.MANIFEST_EXT,e.MFModuleType=t.MFModuleType,e.MFPrefetchCommon=t.MFPrefetchCommon,e.MODULE_DEVTOOL_IDENTIFIER=t.MODULE_DEVTOOL_IDENTIFIER,e.ManifestFileName=t.ManifestFileName,e.NameTransformMap=t.NameTransformMap,e.NameTransformSymbol=t.NameTransformSymbol,e.SEPARATOR=t.SEPARATOR,e.StatsFileName=t.StatsFileName,e.TEMP_DIR=t.TEMP_DIR,e.TreeShakingStatus=t.TreeShakingStatus,e.assert=l.assert,e.bindLoggerToCompiler=d.bindLoggerToCompiler,e.composeKeyWithSeparator=l.composeKeyWithSeparator,Object.defineProperty(e,"consumeSharedPlugin",{enumerable:!0,get:function(){return i.ConsumeSharedPlugin_exports}}),Object.defineProperty(e,"containerPlugin",{enumerable:!0,get:function(){return r.ContainerPlugin_exports}}),Object.defineProperty(e,"containerReferencePlugin",{enumerable:!0,get:function(){return n.ContainerReferencePlugin_exports}}),e.createInfrastructureLogger=d.createInfrastructureLogger,e.createLink=f.createLink,e.createLogger=d.createLogger,e.createModuleFederationConfig=_.createModuleFederationConfig,e.createScript=f.createScript,e.createScriptNode=h.createScriptNode,e.decodeName=l.decodeName,e.encodeName=l.encodeName,e.error=l.error,e.generateExposeFilename=l.generateExposeFilename,e.generateShareFilename=l.generateShareFilename,e.generateSnapshotFromManifest=u.generateSnapshotFromManifest,e.getManifestFileName=u.getManifestFileName,e.getProcessEnv=c.getProcessEnv,e.getResourceUrl=l.getResourceUrl,e.inferAutoPublicPath=u.inferAutoPublicPath,e.infrastructureLogger=d.infrastructureLogger,e.isBrowserEnv=c.isBrowserEnv,e.isBrowserEnvValue=c.isBrowserEnvValue,e.isDebugMode=c.isDebugMode,e.isManifestProvider=u.isManifestProvider,e.isReactNativeEnv=c.isReactNativeEnv,e.isRequiredVersion=l.isRequiredVersion,e.isStaticResourcesEqual=f.isStaticResourcesEqual,e.loadScript=f.loadScript,e.loadScriptNode=h.loadScriptNode,e.logger=d.logger,Object.defineProperty(e,"moduleFederationPlugin",{enumerable:!0,get:function(){return o.ModuleFederationPlugin_exports}}),e.normalizeOptions=m.normalizeOptions,e.parseEntry=l.parseEntry,Object.defineProperty(e,"provideSharedPlugin",{enumerable:!0,get:function(){return a.ProvideSharedPlugin_exports}}),e.safeToString=l.safeToString,e.safeWrapper=f.safeWrapper,Object.defineProperty(e,"sharePlugin",{enumerable:!0,get:function(){return s.SharePlugin_exports}}),e.simpleJoinRemoteEntry=u.simpleJoinRemoteEntry,e.warn=l.warn})(D);var Mr={},Pt={};const Qn=e=>`View the docs to see how to solve: https://module-federation.io/guide/troubleshooting/${e.split("-")[0].toLowerCase()}#${e.toLowerCase()}`,eo=(e,t,r,n)=>{const o=[`${[t[e]]} #${e}`];return r&&o.push(`args: ${JSON.stringify(r)}`),o.push(Qn(e)),n&&o.push(`Original Error Message:
|
|
5
5
|
${n}`),o.join(`
|
|
6
|
-
`)};Pt.getShortErrorMsg=eo;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Pt;function r(n,o,s,i,a,c){return i(t.getShortErrorMsg(n,o,s,a))}e.logAndReport=r})(Mr);let to=D,ro=Mr;const ee="[ Federation Runtime ]",ht=(0,to.createLogger)(ee);function no(e,t,r,n,o){e||(r!==void 0?mt(t,r,n,void 0,o):mt(t))}function mt(e,t,r,n,o){if(t!==void 0)return(0,ro.logAndReport)(e,t,r??{},i=>{throw new Error(`${ee}: ${i}`)},n,o);const s=e;throw s instanceof Error?(s.message.startsWith(ee)||(s.message=`${ee}: ${s.message}`),s):new Error(`${ee}: ${s}`)}function oo(e){e instanceof Error&&(e.message.startsWith(ee)||(e.message=`${ee}: ${e.message}`)),ht.warn(e)}P.assert=no;P.error=mt;P.logger=ht;P.warn=oo;var N={};const so=P;let Ft=D;function io(e,t){return e.findIndex(r=>r===t)===-1&&e.push(t),e}function ao(e){return"version"in e&&e.version?`${e.name}:${e.version}`:"entry"in e&&e.entry?`${e.name}:${e.entry}`:`${e.name}`}function lo(e){return typeof e.entry<"u"}function co(e){return!e.entry.includes(".json")}async function uo(e,t){try{return await e()}catch(r){!t&&so.warn(r);return}}function fo(e){return e&&typeof e=="object"}const Pr=Object.prototype.toString;function ho(e){return Pr.call(e)==="[object Object]"}function mo(e,t){const r=/^(https?:)?\/\//i;return e.replace(r,"").replace(/\/$/,"")===t.replace(r,"").replace(/\/$/,"")}function _o(e){return Array.isArray(e)?e:[e]}function go(e){const t={url:"",type:"global",globalName:""};return Ft.isBrowserEnvValue||(0,Ft.isReactNativeEnv)()||!("ssrRemoteEntry"in e)?"remoteEntry"in e?{url:e.remoteEntry,type:e.remoteEntryType,globalName:e.globalName}:t:"ssrRemoteEntry"in e?{url:e.ssrRemoteEntry||t.url,type:e.ssrRemoteEntryType||t.type,globalName:e.globalName}:t}const po=(e,t)=>{let r;return e.endsWith("/")?r=e.slice(0,-1):r=e,t.startsWith(".")&&(t=t.slice(1)),r=r+t,r};N.addUniqueItem=io;N.arrayOptions=_o;N.getFMId=ao;N.getRemoteEntryInfoFromSnapshot=go;N.isObject=fo;N.isPlainObject=ho;N.isPureRemoteEntry=co;N.isRemoteInfoWithEntry=lo;N.isStaticResourcesEqual=mo;N.objectToString=Pr;N.processModuleAlias=po;N.safeWrapper=uo;var b={};const vr=P,_t=N;let Eo=D;const k=typeof globalThis=="object"?globalThis:window,C=(()=>{try{return document.defaultView}catch{return k}})(),yo=C;function He(e,t,r){Object.defineProperty(e,t,{value:r,configurable:!1,writable:!0})}function Ce(e,t){return Object.hasOwnProperty.call(e,t)}Ce(k,"__GLOBAL_LOADING_REMOTE_ENTRY__")||He(k,"__GLOBAL_LOADING_REMOTE_ENTRY__",{});const gt=k.__GLOBAL_LOADING_REMOTE_ENTRY__;function Ar(e){Ce(e,"__VMOK__")&&!Ce(e,"__FEDERATION__")&&He(e,"__FEDERATION__",e.__VMOK__),Ce(e,"__FEDERATION__")||(He(e,"__FEDERATION__",{__GLOBAL_PLUGIN__:[],__INSTANCES__:[],moduleInfo:{},__SHARE__:{},__MANIFEST_LOADING__:{},__PRELOADED_MAP__:new Map}),He(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}Ar(k);Ar(C);function So(){k.__FEDERATION__.__GLOBAL_PLUGIN__=[],k.__FEDERATION__.__INSTANCES__=[],k.__FEDERATION__.moduleInfo={},k.__FEDERATION__.__SHARE__={},k.__FEDERATION__.__MANIFEST_LOADING__={},Object.keys(gt).forEach(e=>{delete gt[e]})}function bo(e){k.__FEDERATION__.__INSTANCES__.push(e)}function Ro(){return k.__FEDERATION__.__DEBUG_CONSTRUCTOR__}function To(e,t=(0,Eo.isDebugMode)()){t&&(k.__FEDERATION__.__DEBUG_CONSTRUCTOR__=e,k.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__="2.3.0")}function pt(e,t){if(typeof t=="string"){if(e[t])return{value:e[t],key:t};{const r=Object.keys(e);for(const n of r){const[o,s]=n.split(":"),i=`${o}:${t}`,a=e[i];if(a)return{value:a,key:i}}return{value:void 0,key:t}}}else vr.error(`getInfoWithoutType: "key" must be a string, got ${typeof t} (${JSON.stringify(t)}).`)}const Io=()=>C.__FEDERATION__.moduleInfo,$r=(e,t)=>{const r=pt(t,_t.getFMId(e)).value;if(r&&!r.version&&"version"in e&&e.version&&(r.version=e.version),r)return r;if("version"in e&&e.version){const{version:n,...o}=e,s=_t.getFMId(o),i=pt(C.__FEDERATION__.moduleInfo,s).value;if((i==null?void 0:i.version)===n)return i}},No=e=>$r(e,C.__FEDERATION__.moduleInfo),Mo=(e,t)=>{const r=_t.getFMId(e);return C.__FEDERATION__.moduleInfo[r]=t,C.__FEDERATION__.moduleInfo},Po=e=>(C.__FEDERATION__.moduleInfo={...C.__FEDERATION__.moduleInfo,...e},()=>{const t=Object.keys(e);for(const r of t)delete C.__FEDERATION__.moduleInfo[r]}),vo=(e,t)=>{const r=t||`__FEDERATION_${e}:custom__`;return{remoteEntryKey:r,entryExports:k[r]}},Ao=e=>{const{__GLOBAL_PLUGIN__:t}=C.__FEDERATION__;e.forEach(r=>{t.findIndex(n=>n.name===r.name)===-1?t.push(r):vr.warn(`The plugin ${r.name} has been registered.`)})},$o=()=>C.__FEDERATION__.__GLOBAL_PLUGIN__,ko=e=>k.__FEDERATION__.__PRELOADED_MAP__.get(e),Oo=e=>k.__FEDERATION__.__PRELOADED_MAP__.set(e,!0);b.CurrentGlobal=k;b.Global=yo;b.addGlobalSnapshot=Po;b.getGlobalFederationConstructor=Ro;b.getGlobalHostPlugins=$o;b.getGlobalSnapshot=Io;b.getGlobalSnapshotInfoByModuleInfo=No;b.getInfoWithoutType=pt;b.getPreloaded=ko;b.getRemoteEntryExports=vo;b.getTargetSnapshotInfoByModuleInfo=$r;b.globalLoading=gt;b.nativeGlobal=C;b.registerGlobalPlugins=Ao;b.resetFederationGlobalInfo=So;b.setGlobalFederationConstructor=To;b.setGlobalFederationInstance=bo;b.setGlobalSnapshotInfoByModuleInfo=Mo;b.setPreloaded=Oo;var vt={},ne={},W={};const wt="[0-9A-Za-z-]+",At=`(?:\\+(${wt}(?:\\.${wt})*))`,Re="0|[1-9]\\d*",qe="[0-9]+",kr="\\d*[a-zA-Z-][a-zA-Z0-9-]*",Lt=`(?:${qe}|${kr})`,Fo=`(?:-?(${Lt}(?:\\.${Lt})*))`,Dt=`(?:${Re}|${kr})`,Or=`(?:-(${Dt}(?:\\.${Dt})*))`,ze=`${Re}|x|X|\\*`,ce=`[v=\\s]*(${ze})(?:\\.(${ze})(?:\\.(${ze})(?:${Or})?${At}?)?)?`,wo=`^\\s*(${ce})\\s+-\\s+(${ce})\\s*$`,Lo=`[v=\\s]*${`(${qe})\\.(${qe})\\.(${qe})`}${Fo}?${At}?`,$t="((?:<|>)?=?)",Do=`(\\s*)${$t}\\s*(${Lo}|${ce})`,Fr="(?:~>?)",Ho=`(\\s*)${Fr}\\s+`,wr="(?:\\^)",Co=`(\\s*)${wr}\\s+`,qo="(<|>)?=?\\s*\\*",Uo=`^${wr}${ce}$`,Go=`v?${`(${Re})\\.(${Re})\\.(${Re})`}${Or}?${At}?`,Wo=`^${Fr}${ce}$`,Bo=`^${$t}\\s*${ce}$`,Vo=`^${$t}\\s*(${Go})$|^$`,jo="^\\s*>=\\s*0.0.0\\s*$";W.caret=Uo;W.caretTrim=Co;W.comparator=Vo;W.comparatorTrim=Do;W.gte0=jo;W.hyphenRange=wo;W.star=qo;W.tilde=Wo;W.tildeTrim=Ho;W.xRange=Bo;const Xo=W;function Lr(e){return new RegExp(e)}function xo(e){return!e||e.toLowerCase()==="x"||e==="*"}function Ko(...e){return t=>e.reduce((r,n)=>n(r),t)}function Yo(e){return e.match(Lr(Xo.comparator))}function zo(e,t,r,n){const o=`${e}.${t}.${r}`;return n?`${o}-${n}`:o}ne.combineVersion=zo;ne.extractComparator=Yo;ne.isXVersion=xo;ne.parseRegex=Lr;ne.pipe=Ko;var j={};const x=W,T=ne;function Jo(e){return e.replace(T.parseRegex(x.hyphenRange),(t,r,n,o,s,i,a,c,l,u,d,f)=>(T.isXVersion(n)?r="":T.isXVersion(o)?r=`>=${n}.0.0`:T.isXVersion(s)?r=`>=${n}.${o}.0`:r=`>=${r}`,T.isXVersion(l)?c="":T.isXVersion(u)?c=`<${Number(l)+1}.0.0-0`:T.isXVersion(d)?c=`<${l}.${Number(u)+1}.0-0`:f?c=`<=${l}.${u}.${d}-${f}`:c=`<=${c}`,`${r} ${c}`.trim()))}function Zo(e){return e.replace(T.parseRegex(x.comparatorTrim),"$1$2$3")}function Qo(e){return e.replace(T.parseRegex(x.tildeTrim),"$1~")}function es(e){return e.replace(T.parseRegex(x.caretTrim),"$1^")}function ts(e){return e.trim().split(/\s+/).map(t=>t.replace(T.parseRegex(x.caret),(r,n,o,s,i)=>T.isXVersion(n)?"":T.isXVersion(o)?`>=${n}.0.0 <${Number(n)+1}.0.0-0`:T.isXVersion(s)?n==="0"?`>=${n}.${o}.0 <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.0 <${Number(n)+1}.0.0-0`:i?n==="0"?o==="0"?`>=${n}.${o}.${s}-${i} <${n}.${o}.${Number(s)+1}-0`:`>=${n}.${o}.${s}-${i} <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.${s}-${i} <${Number(n)+1}.0.0-0`:n==="0"?o==="0"?`>=${n}.${o}.${s} <${n}.${o}.${Number(s)+1}-0`:`>=${n}.${o}.${s} <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.${s} <${Number(n)+1}.0.0-0`)).join(" ")}function rs(e){return e.trim().split(/\s+/).map(t=>t.replace(T.parseRegex(x.tilde),(r,n,o,s,i)=>T.isXVersion(n)?"":T.isXVersion(o)?`>=${n}.0.0 <${Number(n)+1}.0.0-0`:T.isXVersion(s)?`>=${n}.${o}.0 <${n}.${Number(o)+1}.0-0`:i?`>=${n}.${o}.${s}-${i} <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.${s} <${n}.${Number(o)+1}.0-0`)).join(" ")}function ns(e){return e.split(/\s+/).map(t=>t.trim().replace(T.parseRegex(x.xRange),(r,n,o,s,i,a)=>{const c=T.isXVersion(o),l=c||T.isXVersion(s),u=l||T.isXVersion(i);return n==="="&&u&&(n=""),a="",c?n===">"||n==="<"?"<0.0.0-0":"*":n&&u?(l&&(s=0),i=0,n===">"?(n=">=",l?(o=Number(o)+1,s=0,i=0):(s=Number(s)+1,i=0)):n==="<="&&(n="<",l?o=Number(o)+1:s=Number(s)+1),n==="<"&&(a="-0"),`${n+o}.${s}.${i}${a}`):l?`>=${o}.0.0${a} <${Number(o)+1}.0.0-0`:u?`>=${o}.${s}.0${a} <${o}.${Number(s)+1}.0-0`:r})).join(" ")}function os(e){return e.trim().replace(T.parseRegex(x.star),"")}function ss(e){return e.trim().replace(T.parseRegex(x.gte0),"")}j.parseCaretTrim=es;j.parseCarets=ts;j.parseComparatorTrim=Zo;j.parseGTE0=ss;j.parseHyphen=Jo;j.parseStar=os;j.parseTildeTrim=Qo;j.parseTildes=rs;j.parseXRanges=ns;var Dr={};function Ue(e,t){return e=Number(e)||e,t=Number(t)||t,e>t?1:e===t?0:-1}function is(e,t){const{preRelease:r}=e,{preRelease:n}=t;if(r===void 0&&n)return 1;if(r&&n===void 0)return-1;if(r===void 0&&n===void 0)return 0;for(let o=0,s=r.length;o<=s;o++){const i=r[o],a=n[o];if(i!==a)return i===void 0&&a===void 0?0:i?a?Ue(i,a):-1:1}return 0}function Oe(e,t){return Ue(e.major,t.major)||Ue(e.minor,t.minor)||Ue(e.patch,t.patch)||is(e,t)}function Je(e,t){return e.version===t.version}function as(e,t){switch(e.operator){case"":case"=":return Je(e,t);case">":return Oe(e,t)<0;case">=":return Je(e,t)||Oe(e,t)<0;case"<":return Oe(e,t)>0;case"<=":return Je(e,t)||Oe(e,t)>0;case void 0:return!0;default:return!1}}Dr.compare=as;const ae=ne,X=j,ls=Dr;function cs(e){return ae.pipe(X.parseCarets,X.parseTildes,X.parseXRanges,X.parseStar)(e)}function us(e){return ae.pipe(X.parseHyphen,X.parseComparatorTrim,X.parseTildeTrim,X.parseCaretTrim)(e.trim()).split(/\s+/).join(" ")}function fs(e,t){if(!e)return!1;const r=ae.extractComparator(e);if(!r)return!1;const[,n,,o,s,i,a]=r,c={operator:n,version:ae.combineVersion(o,s,i,a),major:o,minor:s,patch:i,preRelease:a==null?void 0:a.split(".")},l=t.split("||");for(const u of l){const d=u.trim();if(!d||d==="*"||d==="x")return!0;try{const f=us(d);if(!f.trim())return!0;const h=f.split(" ").map(g=>cs(g)).join(" ");if(!h.trim())return!0;const m=h.split(/\s+/).map(g=>X.parseGTE0(g)).filter(Boolean);if(m.length===0)continue;let _=!0;for(const g of m){const p=ae.extractComparator(g);if(!p){_=!1;break}const[,y,,I,O,E,M]=p;if(!ls.compare({operator:y,version:ae.combineVersion(I,O,E,M),major:I,minor:O,patch:E,preRelease:M==null?void 0:M.split(".")},c)){_=!1;break}}if(_)return!0}catch(f){console.error(`[semver] Error processing range part "${d}":`,f);continue}}return!1}vt.satisfy=fs;var q={},oe={};const ds="default",hs="global";oe.DEFAULT_REMOTE_TYPE=hs;oe.DEFAULT_SCOPE=ds;const We=P,Hr=N,Cr=b,ms=oe,ye=vt;let Et=D;function _s(e,t,r,n){var s,i;let o;return"get"in e?o=e.get:"lib"in e?o=()=>Promise.resolve(e.lib):o=()=>Promise.resolve(()=>{We.error(`Cannot get shared "${r}" from "${t}": neither "get" nor "lib" is provided in the share config.`)}),(s=e.shareConfig)!=null&&s.eager&&((i=e.treeShaking)!=null&&i.mode)&&We.error(`Invalid shared config for "${r}" 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:o,loaded:e!=null&&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??n)||"version-first",treeShaking:e.treeShaking?{...e.treeShaking,mode:e.treeShaking.mode??"server-calc",status:e.treeShaking.status??Et.TreeShakingStatus.UNKNOWN,useIn:[]}:void 0}}function gs(e,t){const r=t.shared||{},n=t.name,o=Object.keys(r).reduce((i,a)=>{const c=Hr.arrayOptions(r[a]);return i[a]=i[a]||[],c.forEach(l=>{i[a].push(_s(l,n,a,t.shareStrategy))}),i},{}),s={...e.shared};return Object.keys(o).forEach(i=>{s[i]?o[i].forEach(a=>{s[i].find(c=>c.version===a.version)||s[i].push(a)}):s[i]=o[i]}),{allShareInfos:s,newShareInfos:o}}function Te(e,t){if(!e)return!1;const{status:r,mode:n}=e;return r===Et.TreeShakingStatus.NO_USE?!1:r===Et.TreeShakingStatus.CALCULATED?!0:n==="runtime-infer"?t?Es(e,t):!0:!1}function te(e,t){const r=n=>{if(!Number.isNaN(Number(n))){const o=n.split(".");let s=n;for(let i=0;i<3-o.length;i++)s+=".0";return s}return n};return!!ye.satisfy(r(e),`<=${r(t)}`)}const Ie=(e,t)=>{const r=t||function(n,o){return te(n,o)};return Object.keys(e).reduce((n,o)=>!n||r(n,o)||n==="0"?o:n,0)},Be=e=>!!e.loaded||typeof e.lib=="function",ps=e=>!!e.loading,Es=(e,t)=>{if(!e||!t)return!1;const{usedExports:r}=e;return r?!!t.every(n=>r.includes(n)):!1};function ys(e,t,r,n){const o=e[t][r];let s="",i=Te(n);const a=function(c,l){return i?o[c].treeShaking?o[l].treeShaking?!Be(o[c].treeShaking)&&te(c,l):!1:!0:!Be(o[c])&&te(c,l)};if(i){if(s=Ie(e[t][r],a),s)return{version:s,useTreesShaking:i};i=!1}return{version:Ie(e[t][r],a),useTreesShaking:i}}const se=e=>Be(e)||ps(e);function Ss(e,t,r,n){const o=e[t][r];let s="",i=Te(n);const a=function(c,l){if(i){if(!o[c].treeShaking)return!0;if(!o[l].treeShaking)return!1;if(se(o[l].treeShaking))return se(o[c].treeShaking)?!!te(c,l):!0;if(se(o[c].treeShaking))return!1}return se(o[l])?se(o[c])?!!te(c,l):!0:se(o[c])?!1:te(c,l)};if(i){if(s=Ie(e[t][r],a),s)return{version:s,useTreesShaking:i};i=!1}return{version:Ie(e[t][r],a),useTreesShaking:i}}function bs(e){return e==="loaded-first"?Ss:ys}function Rs(e,t,r,n){if(!e)return;const{shareConfig:o,scope:s=ms.DEFAULT_SCOPE,strategy:i,treeShaking:a}=r,c=Array.isArray(s)?s:[s];for(const l of c)if(o&&e[l]&&e[l][t]){const{requiredVersion:u}=o,{version:d,useTreesShaking:f}=bs(i)(e,l,t,a),h=()=>{const _=e[l][t][d];if(o.singleton){if(typeof u=="string"&&!ye.satisfy(d,u)){const g=`Version ${d} from ${d&&_.from} of shared singleton module ${t} does not satisfy the requirement of ${r.from} which needs ${u})`;o.strictVersion?We.error(g):We.warn(g)}return{shared:_,useTreesShaking:f}}else{if(u===!1||u==="*")return{shared:_,useTreesShaking:f};if(ye.satisfy(d,u))return{shared:_,useTreesShaking:f};const g=Te(a);if(g){for(const[p,y]of Object.entries(e[l][t]))if(Te(y.treeShaking,a==null?void 0:a.usedExports)&&ye.satisfy(p,u))return{shared:y,useTreesShaking:g}}for(const[p,y]of Object.entries(e[l][t]))if(ye.satisfy(p,u))return{shared:y,useTreesShaking:!1}}},m={shareScopeMap:e,scope:l,pkgName:t,version:d,GlobalFederation:Cr.Global.__FEDERATION__,shareInfo:r,resolver:h};return(n.emit(m)||m).resolver()}}function Ts(){return Cr.Global.__FEDERATION__.__SHARE__}function Is(e){const{pkgName:t,extraOptions:r,shareInfos:n}=e,o=c=>{if(!c)return;const l={};return c.forEach(d=>{l[d.version]=d}),l[Ie(l,function(d,f){return!Be(l[d])&&te(d,f)})]},s=(r==null?void 0:r.resolver)??o,i=c=>c!==null&&typeof c=="object"&&!Array.isArray(c),a=(...c)=>{const l={};for(const u of c)if(u)for(const[d,f]of Object.entries(u)){const h=l[d];i(h)&&i(f)?l[d]=a(h,f):f!==void 0&&(l[d]=f)}return l};return a(s(n[t]),r==null?void 0:r.customShareInfo)}const Ns=(e,t)=>{e.useIn||(e.useIn=[]),Hr.addUniqueItem(e.useIn,t)};function Ms(e,t){return t&&e.treeShaking?e.treeShaking:e}q.addUseIn=Ns;q.directShare=Ms;q.formatShareConfigs=gs;q.getGlobalShareScope=Ts;q.getRegisteredShare=Rs;q.getTargetSharedOptions=Is;q.shouldUseTreeShaking=Te;var he={};function Ps(e,t){for(const r of e){const n=t.startsWith(r.name);let o=t.replace(r.name,"");if(n){if(o.startsWith("/")){const a=r.name;return o=`.${o}`,{pkgNameOrAlias:a,expose:o,remote:r}}else if(o==="")return{pkgNameOrAlias:r.name,expose:".",remote:r}}const s=r.alias&&t.startsWith(r.alias);let i=r.alias&&t.replace(r.alias,"");if(r.alias&&s){if(i&&i.startsWith("/")){const a=r.alias;return i=`.${i}`,{pkgNameOrAlias:a,expose:i,remote:r}}else if(i==="")return{pkgNameOrAlias:r.alias,expose:".",remote:r}}}}function vs(e,t){for(const r of e)if(t===r.name||r.alias&&t===r.alias)return r}he.matchRemote=vs;he.matchRemoteWithNameAndExpose=Ps;var K={},Y={},w={};const As="RUNTIME-001",$s="RUNTIME-002",ks="RUNTIME-003",Os="RUNTIME-004",Fs="RUNTIME-005",ws="RUNTIME-006",Ls="RUNTIME-007",Ds="RUNTIME-008",Hs="RUNTIME-009",Cs="RUNTIME-010",qs="RUNTIME-011",Us="RUNTIME-012",Gs="TYPE-001",Ws="BUILD-001",Bs="BUILD-002";w.BUILD_001=Ws;w.BUILD_002=Bs;w.RUNTIME_001=As;w.RUNTIME_002=$s;w.RUNTIME_003=ks;w.RUNTIME_004=Os;w.RUNTIME_005=Fs;w.RUNTIME_006=ws;w.RUNTIME_007=Ls;w.RUNTIME_008=Ds;w.RUNTIME_009=Hs;w.RUNTIME_010=Cs;w.RUNTIME_011=qs;w.RUNTIME_012=Us;w.TYPE_001=Gs;var Pe={};const L=w,qr={[L.RUNTIME_001]:"Failed to get remoteEntry exports.",[L.RUNTIME_002]:'The remote entry interface does not contain "init"',[L.RUNTIME_003]:"Failed to get manifest.",[L.RUNTIME_004]:"Failed to locate remote.",[L.RUNTIME_005]:"Invalid loadShareSync function call from bundler runtime",[L.RUNTIME_006]:"Invalid loadShareSync function call from runtime",[L.RUNTIME_007]:"Failed to get remote snapshot.",[L.RUNTIME_008]:"Failed to load script resources.",[L.RUNTIME_009]:"Please call createInstance first.",[L.RUNTIME_010]:'The name option cannot be changed after initialization. If you want to create a new instance with a different name, please use "createInstance" api.',[L.RUNTIME_011]:"The remoteEntry URL is missing from the remote snapshot.",[L.RUNTIME_012]:'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.'},Ur={[L.TYPE_001]:"Failed to generate type declaration. Execute the below cmd to reproduce and fix the error."},Gr={[L.BUILD_001]:"Failed to find expose module.",[L.BUILD_002]:"PublicPath is required in prod mode."},Vs={...qr,...Ur,...Gr};Pe.buildDescMap=Gr;Pe.errorDescMap=Vs;Pe.runtimeDescMap=qr;Pe.typeDescMap=Ur;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=w,r=Pt,n=Pe;e.BUILD_001=t.BUILD_001,e.BUILD_002=t.BUILD_002,e.RUNTIME_001=t.RUNTIME_001,e.RUNTIME_002=t.RUNTIME_002,e.RUNTIME_003=t.RUNTIME_003,e.RUNTIME_004=t.RUNTIME_004,e.RUNTIME_005=t.RUNTIME_005,e.RUNTIME_006=t.RUNTIME_006,e.RUNTIME_007=t.RUNTIME_007,e.RUNTIME_008=t.RUNTIME_008,e.RUNTIME_009=t.RUNTIME_009,e.RUNTIME_010=t.RUNTIME_010,e.RUNTIME_011=t.RUNTIME_011,e.RUNTIME_012=t.RUNTIME_012,e.TYPE_001=t.TYPE_001,e.buildDescMap=n.buildDescMap,e.errorDescMap=n.errorDescMap,e.getShortErrorMsg=r.getShortErrorMsg,e.runtimeDescMap=n.runtimeDescMap,e.typeDescMap=n.typeDescMap})(Y);const je=P,le=b,Ht=oe;let Wr=D,Ne=Y;const Br=".then(callbacks[0]).catch(callbacks[1])";async function js({entry:e,remoteEntryExports:t}){return new Promise((r,n)=>{try{t?r(t):typeof FEDERATION_ALLOW_NEW_FUNCTION<"u"?new Function("callbacks",`import("${e}")${Br}`)([r,n]):import(e).then(r).catch(n)}catch(o){je.error(`Failed to load ESM entry from "${e}". ${o instanceof Error?o.message:String(o)}`)}})}async function Xs({entry:e,remoteEntryExports:t}){return new Promise((r,n)=>{try{t?r(t):typeof __system_context__>"u"?System.import(e).then(r).catch(n):new Function("callbacks",`System.import("${e}")${Br}`)([r,n])}catch(o){je.error(`Failed to load SystemJS entry from "${e}". ${o instanceof Error?o.message:String(o)}`)}})}function xs(e,t,r){const{remoteEntryKey:n,entryExports:o}=le.getRemoteEntryExports(e,t);return o||je.error(Ne.RUNTIME_001,Ne.runtimeDescMap,{remoteName:e,remoteEntryUrl:r,remoteEntryKey:n}),o}async function Ks({name:e,globalName:t,entry:r,loaderHook:n,getEntryUrl:o}){const{entryExports:s}=le.getRemoteEntryExports(e,t);if(s)return s;const i=o?o(r):r;return(0,Wr.loadScript)(i,{attrs:{},createScriptHook:(a,c)=>{const l=n.lifecycle.createScript.emit({url:a,attrs:c});if(l&&(l instanceof HTMLScriptElement||"script"in l||"timeout"in l))return l}}).then(()=>xs(e,t,r),a=>{const c=a instanceof Error?a.message:String(a);je.error(Ne.RUNTIME_008,Ne.runtimeDescMap,{remoteName:e,resourceUrl:i},c)})}async function Ys({remoteInfo:e,remoteEntryExports:t,loaderHook:r,getEntryUrl:n}){const{entry:o,entryGlobalName:s,name:i,type:a}=e;switch(a){case"esm":case"module":return js({entry:o,remoteEntryExports:t});case"system":return Xs({entry:o,remoteEntryExports:t});default:return Ks({entry:o,globalName:s,name:i,loaderHook:r,getEntryUrl:n})}}function yt(e){const{entry:t,name:r}=e;return(0,Wr.composeKeyWithSeparator)(r,t)}async function Vr(e){const{origin:t,remoteEntryExports:r,remoteInfo:n,getEntryUrl:o,_inErrorHandling:s=!1}=e,i=yt(n);if(r)return r;if(!le.globalLoading[i]){const a=t.remoteHandler.hooks.lifecycle.loadEntry,c=t.loaderHook;le.globalLoading[i]=a.emit({loaderHook:c,remoteInfo:n,remoteEntryExports:r}).then(l=>l||Ys({remoteInfo:n,remoteEntryExports:r,loaderHook:c,getEntryUrl:o})).catch(async l=>{const u=yt(n),d=l instanceof Error&&l.message.includes("ScriptExecutionError");if(l instanceof Error&&l.message.includes(Ne.RUNTIME_008)&&!d&&!s){const f=m=>Vr({...m,_inErrorHandling:!0}),h=await t.loaderHook.lifecycle.loadEntryError.emit({getRemoteEntry:f,origin:t,remoteInfo:n,remoteEntryExports:r,globalLoading:le.globalLoading,uniqueKey:u});if(h)return h}throw l})}return le.globalLoading[i]}function zs(e){return{...e,entry:"entry"in e?e.entry:"",type:e.type||Ht.DEFAULT_REMOTE_TYPE,entryGlobalName:e.entryGlobalName||e.name,shareScope:e.shareScope||Ht.DEFAULT_SCOPE}}K.getRemoteEntry=Vr;K.getRemoteEntryUniqueKey=yt;K.getRemoteInfo=zs;var jr={};function Js(){return typeof FEDERATION_BUILD_IDENTIFIER<"u"?FEDERATION_BUILD_IDENTIFIER:""}jr.getBuilderId=Js;var Xr={};const Zs=b;function Qs(e,t){const r=Zs.getGlobalHostPlugins(),n=[t.hooks,t.remoteHandler.hooks,t.sharedHandler.hooks,t.snapshotHandler.hooks,t.loaderHook,t.bridgeHook];return r.length>0&&r.forEach(o=>{e!=null&&e.find(s=>s.name!==o.name)&&e.push(o)}),e&&e.length>0&&e.forEach(o=>{n.forEach(s=>{s.applyPlugin(o,t)})}),e}Xr.registerPlugins=Qs;var ve={};function ei(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 ti(e){var r,n,o,s,i,a;const t={};for(const[c,l]of Object.entries(e.shared)){const u=l[0];u&&(t[c]={version:u.version,singleton:(r=u.shareConfig)==null?void 0:r.singleton,requiredVersion:((n=u.shareConfig)==null?void 0:n.requiredVersion)===!1?!1:(o=u.shareConfig)==null?void 0:o.requiredVersion,eager:u.eager,strictVersion:(s=u.shareConfig)==null?void 0:s.strictVersion})}return{project:{name:e.name,mfRole:((i=e.remotes)==null?void 0:i.length)>0?"host":"unknown"},mfConfig:{name:e.name,remotes:((a=e.remotes)==null?void 0:a.map(ei))??[],shared:t}}}ve.optionsToMFContext=ti;var xr={},Z={};const ri=P,ni=he,Ct=K;let Se=D;function Kr(e){return{resourceCategory:"sync",share:!0,depsRemote:!0,prefetchInterface:!1,...e}}function oi(e,t){return t.map(r=>{const n=ni.matchRemote(e,r.nameOrAlias);return ri.assert(n,`Unable to preload ${r.nameOrAlias} as it is not included in ${!n&&(0,Se.safeToString)({remoteInfo:n,remotes:e})}`),{remote:n,preloadConfig:Kr(r)}})}function si(e){return e?e.map(t=>t==="."?t:t.startsWith("./")?t.replace("./",""):t):[]}function ii(e,t,r,n=!0){const{cssAssets:o,jsAssetsWithoutEntry:s,entryAssets:i}=r;if(t.options.inBrowser){if(i.forEach(a=>{const{moduleInfo:c}=a,l=t.moduleCache.get(e.name);l?Ct.getRemoteEntry({origin:t,remoteInfo:c,remoteEntryExports:l.remoteEntryExports}):Ct.getRemoteEntry({origin:t,remoteInfo:c,remoteEntryExports:void 0})}),n){const a={rel:"preload",as:"style"};o.forEach(c=>{const{link:l,needAttach:u}=(0,Se.createLink)({url:c,cb:()=>{},attrs:a,createLinkHook:(d,f)=>{const h=t.loaderHook.lifecycle.createLink.emit({url:d,attrs:f});if(h instanceof HTMLLinkElement)return h}});u&&document.head.appendChild(l)})}else{const a={rel:"stylesheet",type:"text/css"};o.forEach(c=>{const{link:l,needAttach:u}=(0,Se.createLink)({url:c,cb:()=>{},attrs:a,createLinkHook:(d,f)=>{const h=t.loaderHook.lifecycle.createLink.emit({url:d,attrs:f});if(h instanceof HTMLLinkElement)return h},needDeleteLink:!1});u&&document.head.appendChild(l)})}if(n){const a={rel:"preload",as:"script"};s.forEach(c=>{const{link:l,needAttach:u}=(0,Se.createLink)({url:c,cb:()=>{},attrs:a,createLinkHook:(d,f)=>{const h=t.loaderHook.lifecycle.createLink.emit({url:d,attrs:f});if(h instanceof HTMLLinkElement)return h}});u&&document.head.appendChild(l)})}else{const a={fetchpriority:"high",type:(e==null?void 0:e.type)==="module"?"module":"text/javascript"};s.forEach(c=>{const{script:l,needAttach:u}=(0,Se.createScript)({url:c,cb:()=>{},attrs:a,createScriptHook:(d,f)=>{const h=t.loaderHook.lifecycle.createScript.emit({url:d,attrs:f});if(h instanceof HTMLScriptElement)return h},needDeleteScript:!0});u&&document.head.appendChild(l)})}}}Z.defaultPreloadArgs=Kr;Z.formatPreloadArgs=oi;Z.normalizePreloadExposes=si;Z.preloadAssets=ii;const F=b,qt=q,ai=he,li=K,ci=Z,ui={getRegisteredShare:qt.getRegisteredShare,getGlobalShareScope:qt.getGlobalShareScope},fi={Global:F.Global,nativeGlobal:F.nativeGlobal,resetFederationGlobalInfo:F.resetFederationGlobalInfo,setGlobalFederationInstance:F.setGlobalFederationInstance,getGlobalFederationConstructor:F.getGlobalFederationConstructor,setGlobalFederationConstructor:F.setGlobalFederationConstructor,getInfoWithoutType:F.getInfoWithoutType,getGlobalSnapshot:F.getGlobalSnapshot,getTargetSnapshotInfoByModuleInfo:F.getTargetSnapshotInfoByModuleInfo,getGlobalSnapshotInfoByModuleInfo:F.getGlobalSnapshotInfoByModuleInfo,setGlobalSnapshotInfoByModuleInfo:F.setGlobalSnapshotInfoByModuleInfo,addGlobalSnapshot:F.addGlobalSnapshot,getRemoteEntryExports:F.getRemoteEntryExports,registerGlobalPlugins:F.registerGlobalPlugins,getGlobalHostPlugins:F.getGlobalHostPlugins,getPreloaded:F.getPreloaded,setPreloaded:F.setPreloaded};var di={global:fi,share:ui,utils:{matchRemoteWithNameAndExpose:ai.matchRemoteWithNameAndExpose,preloadAssets:ci.preloadAssets,getRemoteInfo:li.getRemoteInfo}};xr.default=di;var Xe={};const Ze=P,Ut=N,hi=K,mi=ve;let _i=D,Gt=Y;function gi(e,t,r){const n=t,o=Array.isArray(e.shareScope)?e.shareScope:[e.shareScope];o.length||o.push("default"),o.forEach(i=>{n[i]||(n[i]={})});const s={version:e.version||"",shareScopeKeys:Array.isArray(e.shareScope)?o:e.shareScope||"default"};return Object.defineProperty(s,"shareScopeMap",{value:n,enumerable:!1}),{remoteEntryInitOptions:s,shareScope:n[o[0]],initScope:r??[]}}var pi=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;const e=await hi.getRemoteEntry({origin:this.host,remoteInfo:this.remoteInfo,remoteEntryExports:this.remoteEntryExports});return Ze.assert(e,`remoteEntryExports is undefined
|
|
7
|
-
${(0,_i.safeToString)(this.remoteInfo)}`),this.remoteEntryExports=e,this.remoteEntryExports}async init(e,t,r){const n=await this.getEntry();if(this.inited)return n;if(this.initPromise)return await this.initPromise,n;this.initing=!0,this.initPromise=(async()=>{const{remoteEntryInitOptions:o,shareScope:s,initScope:i}=gi(this.remoteInfo,this.host.shareScopeMap,r),a=await this.host.hooks.lifecycle.beforeInitContainer.emit({shareScope:s,remoteEntryInitOptions:o,initScope:i,remoteInfo:this.remoteInfo,origin:this.host});typeof(n==null?void 0:n.init)>"u"&&Ze.error(Gt.RUNTIME_002,Gt.runtimeDescMap,{hostName:this.host.name,remoteName:this.remoteInfo.name,remoteEntryUrl:this.remoteInfo.entry,remoteEntryKey:this.remoteInfo.entryGlobalName},void 0,mi.optionsToMFContext(this.host.options)),await n.init(a.shareScope,a.initScope,a.remoteEntryInitOptions),await this.host.hooks.lifecycle.initContainer.emit({...a,id:e,remoteSnapshot:t,remoteEntryExports:n}),this.inited=!0})();try{await this.initPromise}finally{this.initing=!1,this.initPromise=void 0}return n}async get(e,t,r,n){const{loadFactory:o=!0}=r||{loadFactory:!0},s=await this.init(e,n);this.lib=s;let i;i=await this.host.loaderHook.lifecycle.getModuleFactory.emit({remoteEntryExports:s,expose:t,moduleInfo:this.remoteInfo}),i||(i=await s.get(t)),Ze.assert(i,`${Ut.getFMId(this.remoteInfo)} remote don't export ${t}.`);const a=Ut.processModuleAlias(this.remoteInfo.name,t),c=this.wraperFactory(i,a);return o?await c():c}wraperFactory(e,t){function r(n,o){n&&typeof n=="object"&&Object.isExtensible(n)&&!Object.getOwnPropertyDescriptor(n,Symbol.for("mf_module_id"))&&Object.defineProperty(n,Symbol.for("mf_module_id"),{value:o,enumerable:!1})}return e instanceof Promise?async()=>{const n=await e();return r(n,t),n}:()=>{const n=e();return r(n,t),n}}};Xe.Module=pi;var Yr={},me={},Ei=class{constructor(e){this.type="",this.listeners=new Set,e&&(this.type=e)}on(e){typeof e=="function"&&this.listeners.add(e)}once(e){const t=this;this.on(function r(...n){return t.remove(r),e.apply(null,n)})}emit(...e){let t;return this.listeners.size>0&&this.listeners.forEach(r=>{t=r(...e)}),t}remove(e){this.listeners.delete(e)}removeAll(){this.listeners.clear()}};me.SyncHook=Ei;var Ae={};const yi=me;var Si=class extends yi.SyncHook{emit(...e){let t;const r=Array.from(this.listeners);if(r.length>0){let n=0;const o=s=>s===!1?!1:n<r.length?Promise.resolve(r[n++].apply(null,e)).then(o):s;t=o()}return Promise.resolve(t)}};Ae.AsyncHook=Si;var _e={};const Qe=P,zr=N,bi=me;function Jr(e,t){if(!zr.isObject(t))return!1;if(e!==t){for(const r in e)if(!(r in t))return!1}return!0}var Ri=class extends bi.SyncHook{constructor(e){super(),this.onerror=Qe.error,this.type=e}emit(e){zr.isObject(e)||Qe.error(`The data for the "${this.type}" hook should be an object.`);for(const t of this.listeners)try{const r=t(e);if(Jr(e,r))e=r;else{this.onerror(`A plugin returned an unacceptable value for the "${this.type}" type.`);break}}catch(r){Qe.warn(r),this.onerror(r)}return e}};_e.SyncWaterfallHook=Ri;_e.checkReturnData=Jr;var $e={};const et=P,Ti=N,Ii=me,Ni=_e;var Mi=class extends Ii.SyncHook{constructor(e){super(),this.onerror=et.error,this.type=e}emit(e){Ti.isObject(e)||et.error(`The response data for the "${this.type}" hook must be an object.`);const t=Array.from(this.listeners);if(t.length>0){let r=0;const n=s=>(et.warn(s),this.onerror(s),e),o=s=>{if(Ni.checkReturnData(e,s)){if(e=s,r<t.length)try{return Promise.resolve(t[r++](e)).then(o,n)}catch(i){return n(i)}}else this.onerror(`A plugin returned an incorrect value for the "${this.type}" type.`);return e};return Promise.resolve(o(e))}return Promise.resolve(e)}};$e.AsyncWaterfallHook=Mi;var ke={};const Fe=P,Pi=N;var vi=class{constructor(e){this.registerPlugins={},this.lifecycle=e,this.lifecycleKeys=Object.keys(e)}applyPlugin(e,t){var n;Fe.assert(Pi.isPlainObject(e),"Plugin configuration is invalid.");const r=e.name;Fe.assert(r,"A name must be provided by the plugin."),this.registerPlugins[r]||(this.registerPlugins[r]=e,(n=e.apply)==null||n.call(e,t),Object.keys(this.lifecycle).forEach(o=>{const s=e[o];s&&this.lifecycle[o].on(s)}))}removePlugin(e){Fe.assert(e,"A name is required.");const t=this.registerPlugins[e];Fe.assert(t,`The plugin "${e}" is not registered.`),Object.keys(t).forEach(r=>{r!=="name"&&this.lifecycle[r].remove(t[r])})}};ke.PluginSystem=vi;var xe={};const Ai=P,St=N,$i=Z;let Wt=D,Bt=Y;function Zr(e,t){const r=St.getRemoteEntryInfoFromSnapshot(t);r.url||Ai.error(Bt.RUNTIME_011,Bt.runtimeDescMap,{remoteName:e.name});let n=(0,Wt.getResourceUrl)(t,r.url);!Wt.isBrowserEnvValue&&!n.startsWith("http")&&(n=`https:${n}`),e.type=r.type,e.entryGlobalName=r.globalName,e.entry=n,e.version=t.version,e.buildVersion=t.buildVersion}function ki(){return{name:"snapshot-plugin",async afterResolve(e){const{remote:t,pkgNameOrAlias:r,expose:n,origin:o,remoteInfo:s,id:i}=e;if(!St.isRemoteInfoWithEntry(t)||!St.isPureRemoteEntry(t)){const{remoteSnapshot:a,globalSnapshot:c}=await o.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:t,id:i});Zr(s,a);const l={remote:t,preloadConfig:{nameOrAlias:r,exposes:[n],resourceCategory:"sync",share:!1,depsRemote:!1}},u=await o.remoteHandler.hooks.lifecycle.generatePreloadAssets.emit({origin:o,preloadOptions:l,remoteInfo:s,remote:t,remoteSnapshot:a,globalSnapshot:c});return u&&$i.preloadAssets(s,o,u,!1),{...e,remoteSnapshot:a}}return e}}}xe.assignRemoteInfo=Zr;xe.snapshotPlugin=ki;var Qr={};const Me=N,bt=b,Oi=q,Vt=Z,Fi=xe;let Ve=D;function wi(e){const 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 en(e,t,r,n,o={},s){const{value:i}=bt.getInfoWithoutType(e,Me.getFMId(t)),a=s||i;if(a&&!(0,Ve.isManifestProvider)(a)&&(r(a,t,n),a.remotesInfo)){const c=Object.keys(a.remotesInfo);for(const l of c){if(o[l])continue;o[l]=!0;const u=wi(l),d=a.remotesInfo[l];en(e,{name:u.name,version:d.matchedVersion},r,!1,o,void 0)}}}const tt=(e,t)=>document.querySelector(`${e}[${e==="link"?"href":"src"}="${t}"]`);function Li(e,t,r,n,o){const s=[],i=[],a=[],c=new Set,l=new Set,{options:u}=e,{preloadConfig:d}=t,{depsRemote:f}=d;if(en(n,r,(m,_,g)=>{var M;let p;if(g)p=d;else if(Array.isArray(f)){const R=f.find(A=>A.nameOrAlias===_.name||A.nameOrAlias===_.alias);if(!R)return;p=Vt.defaultPreloadArgs(R)}else if(f===!0)p=d;else return;const y=(0,Ve.getResourceUrl)(m,Me.getRemoteEntryInfoFromSnapshot(m).url);y&&a.push({name:_.name,moduleInfo:{name:_.name,entry:y,type:"remoteEntryType"in m?m.remoteEntryType:"global",entryGlobalName:"globalName"in m?m.globalName:_.name,shareScope:"",version:"version"in m?m.version:void 0},url:y});let I="modules"in m?m.modules:[];const O=Vt.normalizePreloadExposes(p.exposes);O.length&&"modules"in m&&(I=(M=m==null?void 0:m.modules)==null?void 0:M.reduce((R,A)=>((O==null?void 0:O.indexOf(A.moduleName))!==-1&&R.push(A),R),[]));function E(R){const A=R.map(B=>(0,Ve.getResourceUrl)(m,B));return p.filter?A.filter(p.filter):A}if(I){const R=I.length;for(let A=0;A<R;A++){const B=I[A],Ye=`${_.name}/${B.moduleName}`;e.remoteHandler.hooks.lifecycle.handlePreloadModule.emit({id:B.moduleName==="."?_.name:Ye,name:_.name,remoteSnapshot:m,preloadConfig:p,remote:_,origin:e}),!bt.getPreloaded(Ye)&&(p.resourceCategory==="all"?(s.push(...E(B.assets.css.async)),s.push(...E(B.assets.css.sync)),i.push(...E(B.assets.js.async)),i.push(...E(B.assets.js.sync))):p.resourceCategory==="sync"&&(s.push(...E(B.assets.css.sync)),i.push(...E(B.assets.js.sync))),bt.setPreloaded(Ye))}}},!0,{},o),o.shared&&o.shared.length>0){const m=(_,g)=>{const{shared:p}=Oi.getRegisteredShare(e.shareScopeMap,g.sharedName,_,e.sharedHandler.hooks.lifecycle.resolveShare)||{};p&&typeof p.lib=="function"&&(g.assets.js.sync.forEach(y=>{c.add(y)}),g.assets.css.sync.forEach(y=>{l.add(y)}))};o.shared.forEach(_=>{var y;const g=(y=u.shared)==null?void 0:y[_.sharedName];if(!g)return;const p=_.version?g.find(I=>I.version===_.version):g;p&&Me.arrayOptions(p).forEach(I=>{m(I,_)})})}const h=i.filter(m=>!c.has(m)&&!tt("script",m));return{cssAssets:s.filter(m=>!l.has(m)&&!tt("link",m)),jsAssetsWithoutEntry:h,entryAssets:a.filter(m=>!tt("script",m.url))}}const Di=function(){return{name:"generate-preload-assets-plugin",async generatePreloadAssets(e){const{origin:t,preloadOptions:r,remoteInfo:n,remote:o,globalSnapshot:s,remoteSnapshot:i}=e;return Ve.isBrowserEnvValue?Me.isRemoteInfoWithEntry(o)&&Me.isPureRemoteEntry(o)?{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[{name:o.name,url:o.entry,moduleInfo:{name:n.name,entry:o.entry,type:n.type||"global",entryGlobalName:"",shareScope:""}}]}:(Fi.assignRemoteInfo(n,i),Li(t,r,n,s,i)):{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[]}}}};Qr.generatePreloadAssetsPlugin=Di;var Ke={};const rt=P,Hi=N,G=b,jt=ve,Ci=Ae,nt=$e,qi=ke;let ot=D,we=Y;function tn(e,t){const r=G.getGlobalSnapshotInfoByModuleInfo({name:t.name,version:t.options.version}),n=r&&"remotesInfo"in r&&r.remotesInfo&&G.getInfoWithoutType(r.remotesInfo,e.name).value;return n&&n.matchedVersion?{hostGlobalSnapshot:r,globalSnapshot:G.getGlobalSnapshot(),remoteSnapshot:G.getGlobalSnapshotInfoByModuleInfo({name:e.name,version:n.matchedVersion})}:{hostGlobalSnapshot:void 0,globalSnapshot:G.getGlobalSnapshot(),remoteSnapshot:G.getGlobalSnapshotInfoByModuleInfo({name:e.name,version:"version"in e?e.version:void 0})}}var Ui=class{constructor(e){this.loadingHostSnapshot=null,this.manifestCache=new Map,this.hooks=new qi.PluginSystem({beforeLoadRemoteSnapshot:new Ci.AsyncHook("beforeLoadRemoteSnapshot"),loadSnapshot:new nt.AsyncWaterfallHook("loadGlobalSnapshot"),loadRemoteSnapshot:new nt.AsyncWaterfallHook("loadRemoteSnapshot"),afterLoadSnapshot:new nt.AsyncWaterfallHook("afterLoadSnapshot")}),this.manifestLoading=G.Global.__FEDERATION__.__MANIFEST_LOADING__,this.HostInstance=e,this.loaderHook=e.loaderHook}async loadRemoteSnapshotInfo({moduleInfo:e,id:t,expose:r}){const{options:n}=this.HostInstance;await this.hooks.lifecycle.beforeLoadRemoteSnapshot.emit({options:n,moduleInfo:e});let o=G.getGlobalSnapshotInfoByModuleInfo({name:this.HostInstance.options.name,version:this.HostInstance.options.version});o||(o={version:this.HostInstance.options.version||"",remoteEntry:"",remotesInfo:{}},G.addGlobalSnapshot({[this.HostInstance.options.name]:o})),o&&"remotesInfo"in o&&!G.getInfoWithoutType(o.remotesInfo,e.name).value&&("version"in e||"entry"in e)&&(o.remotesInfo={...o==null?void 0:o.remotesInfo,[e.name]:{matchedVersion:"version"in e?e.version:e.entry}});const{hostGlobalSnapshot:s,remoteSnapshot:i,globalSnapshot:a}=this.getGlobalRemoteInfo(e),{remoteSnapshot:c,globalSnapshot:l}=await this.hooks.lifecycle.loadSnapshot.emit({options:n,moduleInfo:e,hostGlobalSnapshot:s,remoteSnapshot:i,globalSnapshot:a});let u,d;if(c)if((0,ot.isManifestProvider)(c)){const f=ot.isBrowserEnvValue?c.remoteEntry:c.ssrRemoteEntry||c.remoteEntry||"",h=await this.getManifestJson(f,e,{}),m=G.setGlobalSnapshotInfoByModuleInfo({...e,entry:f},h);u=h,d=m}else{const{remoteSnapshot:f}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:c,from:"global"});u=f,d=l}else if(Hi.isRemoteInfoWithEntry(e)){const f=await this.getManifestJson(e.entry,e,{}),h=G.setGlobalSnapshotInfoByModuleInfo(e,f),{remoteSnapshot:m}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:f,from:"global"});u=m,d=h}else rt.error(we.RUNTIME_007,we.runtimeDescMap,{remoteName:e.name,remoteVersion:e.version,hostName:this.HostInstance.options.name,globalSnapshot:JSON.stringify(l)},void 0,jt.optionsToMFContext(this.HostInstance.options));return await this.hooks.lifecycle.afterLoadSnapshot.emit({id:t,host:this.HostInstance,options:n,moduleInfo:e,remoteSnapshot:u}),{remoteSnapshot:u,globalSnapshot:d}}getGlobalRemoteInfo(e){return tn(e,this.HostInstance)}async getManifestJson(e,t,r){const n=async()=>{let s=this.manifestCache.get(e);if(s)return s;try{let i=await this.loaderHook.lifecycle.fetch.emit(e,{});(!i||!(i instanceof Response))&&(i=await fetch(e,{})),s=await i.json()}catch(i){s=await this.HostInstance.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:i,from:"runtime",lifecycle:"afterResolve",origin:this.HostInstance}),s||(delete this.manifestLoading[e],rt.error(we.RUNTIME_003,we.runtimeDescMap,{manifestUrl:e,moduleName:t.name,hostName:this.HostInstance.options.name},`${i}`,jt.optionsToMFContext(this.HostInstance.options)))}return rt.assert(s.metaData&&s.exposes&&s.shared,`"${e}" is not a valid federation manifest for remote "${t.name}". Missing required fields: ${[!s.metaData&&"metaData",!s.exposes&&"exposes",!s.shared&&"shared"].filter(Boolean).join(", ")}.`),this.manifestCache.set(e,s),s},o=async()=>{const s=await n(),i=(0,ot.generateSnapshotFromManifest)(s,{version:e}),{remoteSnapshot:a}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:t,manifestJson:s,remoteSnapshot:i,manifestUrl:e,from:"manifest"});return a};return this.manifestLoading[e]||(this.manifestLoading[e]=o().then(s=>s)),this.manifestLoading[e]}};Ke.SnapshotHandler=Ui;Ke.getGlobalRemoteInfo=tn;var rn={};const st=P,Gi=oe,$=q,Xt=ve,Wi=Ae,it=_e,xt=$e,Bi=ke;let pe=Y;var Vi=class{constructor(e){this.hooks=new Bi.PluginSystem({beforeRegisterShare:new it.SyncWaterfallHook("beforeRegisterShare"),afterResolve:new xt.AsyncWaterfallHook("afterResolve"),beforeLoadShare:new xt.AsyncWaterfallHook("beforeLoadShare"),loadShare:new Wi.AsyncHook,resolveShare:new it.SyncWaterfallHook("resolveShare"),initContainerShareScopeMap:new it.SyncWaterfallHook("initContainerShareScopeMap")}),this.host=e,this.shareScopeMap={},this.initTokens={},this._setGlobalShareScopeMap(e.options)}registerShared(e,t){const{newShareInfos:r,allShareInfos:n}=$.formatShareConfigs(e,t);return Object.keys(r).forEach(o=>{r[o].forEach(s=>{s.scope.forEach(i=>{var a;this.hooks.lifecycle.beforeRegisterShare.emit({origin:this.host,pkgName:o,shared:s}),(a=this.shareScopeMap[i])!=null&&a[o]||this.setShared({pkgName:o,lib:s.lib,get:s.get,loaded:s.loaded||!!s.lib,shared:s,from:t.name})})})}),{newShareInfos:r,allShareInfos:n}}async loadShare(e,t){const{host:r}=this,n=$.getTargetSharedOptions({pkgName:e,extraOptions:t,shareInfos:r.options.shared});n!=null&&n.scope&&await Promise.all(n.scope.map(async a=>{await Promise.all(this.initializeSharing(a,{strategy:n.strategy}))}));const{shareInfo:o}=await this.hooks.lifecycle.beforeLoadShare.emit({pkgName:e,shareInfo:n,shared:r.options.shared,origin:r});st.assert(o,`Cannot find shared "${e}" in host "${r.options.name}". Ensure the shared config for "${e}" is declared in the federation plugin options and the host has been initialized before loading shares.`);const{shared:s,useTreesShaking:i}=$.getRegisteredShare(this.shareScopeMap,e,o,this.hooks.lifecycle.resolveShare)||{};if(s){const a=$.directShare(s,i);if(a.lib)return $.addUseIn(a,r.options.name),a.lib;if(a.loading&&!a.loaded){const c=await a.loading;return a.loaded=!0,a.lib||(a.lib=c),$.addUseIn(a,r.options.name),c}else{const l=(async()=>{const u=await a.get();return $.addUseIn(a,r.options.name),a.loaded=!0,a.lib=u,u})();return this.setShared({pkgName:e,loaded:!1,shared:s,from:r.options.name,lib:null,loading:l,treeShaking:i?a:void 0}),l}}else{if(t!=null&&t.customShareInfo)return!1;const a=$.shouldUseTreeShaking(o.treeShaking),c=$.directShare(o,a),u=(async()=>{const d=await c.get();c.lib=d,c.loaded=!0,$.addUseIn(c,r.options.name);const{shared:f,useTreesShaking:h}=$.getRegisteredShare(this.shareScopeMap,e,o,this.hooks.lifecycle.resolveShare)||{};if(f){const m=$.directShare(f,h);m.lib=d,m.loaded=!0,f.from=o.from}return d})();return this.setShared({pkgName:e,loaded:!1,shared:o,from:r.options.name,lib:null,loading:u,treeShaking:a?c:void 0}),u}}initializeSharing(e=Gi.DEFAULT_SCOPE,t){const{host:r}=this,n=t==null?void 0:t.from,o=t==null?void 0:t.strategy;let s=t==null?void 0:t.initScope;const i=[];if(n!=="build"){const{initTokens:f}=this;s||(s=[]);let h=f[e];if(h||(h=f[e]={from:this.host.name}),s.indexOf(h)>=0)return i;s.push(h)}const a=this.shareScopeMap,c=r.options.name;a[e]||(a[e]={});const l=a[e],u=(f,h)=>{var I;const{version:m,eager:_}=h;l[f]=l[f]||{};const g=l[f],p=g[m]&&$.directShare(g[m]),y=!!(p&&("eager"in p&&p.eager||"shareConfig"in p&&((I=p.shareConfig)!=null&&I.eager)));(!p||p.strategy!=="loaded-first"&&!p.loaded&&(!_!=!y?_:c>g[m].from))&&(g[m]=h)},d=async f=>{const{module:h}=await r.remoteHandler.getRemoteModuleAndOptions({id:f});let m;try{m=await h.getEntry()}catch(_){if(m=await r.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:f,error:_,from:"runtime",lifecycle:"beforeLoadShare",origin:r}),!m)return}finally{m!=null&&m.init&&!h.initing&&(h.remoteEntryExports=m,await h.init(void 0,void 0,s))}};return Object.keys(r.options.shared).forEach(f=>{r.options.shared[f].forEach(h=>{h.scope.includes(e)&&u(f,h)})}),(r.options.shareStrategy==="version-first"||o==="version-first")&&r.options.remotes.forEach(f=>{f.shareScope===e&&i.push(d(f.name))}),i}loadShareSync(e,t){const{host:r}=this,n=$.getTargetSharedOptions({pkgName:e,extraOptions:t,shareInfos:r.options.shared});n!=null&&n.scope&&n.scope.forEach(i=>{this.initializeSharing(i,{strategy:n.strategy})});const{shared:o,useTreesShaking:s}=$.getRegisteredShare(this.shareScopeMap,e,n,this.hooks.lifecycle.resolveShare)||{};if(o){if(typeof o.lib=="function")return $.addUseIn(o,r.options.name),o.loaded||(o.loaded=!0,o.from===r.options.name&&(n.loaded=!0)),o.lib;if(typeof o.get=="function"){const i=o.get();if(!(i instanceof Promise))return $.addUseIn(o,r.options.name),this.setShared({pkgName:e,loaded:!0,from:r.options.name,lib:i,shared:o}),i}}if(n.lib)return n.loaded||(n.loaded=!0),n.lib;if(n.get){const i=n.get();return i instanceof Promise&&st.error((t==null?void 0:t.from)==="build"?pe.RUNTIME_005:pe.RUNTIME_006,pe.runtimeDescMap,{hostName:r.options.name,sharedPkgName:e},void 0,Xt.optionsToMFContext(r.options)),n.lib=i,this.setShared({pkgName:e,loaded:!0,from:r.options.name,lib:n.lib,shared:n}),n.lib}st.error(pe.RUNTIME_006,pe.runtimeDescMap,{hostName:r.options.name,sharedPkgName:e},void 0,Xt.optionsToMFContext(r.options))}initShareScopeMap(e,t,r={}){const{host:n}=this;this.shareScopeMap[e]=t,this.hooks.lifecycle.initContainerShareScopeMap.emit({shareScope:t,options:n.options,origin:n,scopeName:e,hostShareScopeMap:r.hostShareScopeMap})}setShared({pkgName:e,shared:t,from:r,lib:n,loading:o,loaded:s,get:i,treeShaking:a}){const{version:c,scope:l="default",...u}=t,d=Array.isArray(l)?l:[l],f=h=>{const m=(g,p,y)=>{y&&!g[p]&&(g[p]=y)},_=a?h.treeShaking:h;m(_,"loaded",s),m(_,"loading",o),m(_,"get",i)};d.forEach(h=>{this.shareScopeMap[h]||(this.shareScopeMap[h]={}),this.shareScopeMap[h][e]||(this.shareScopeMap[h][e]={}),this.shareScopeMap[h][e][c]||(this.shareScopeMap[h][e][c]={version:c,scope:[h],...u,lib:n});const m=this.shareScopeMap[h][e][c];f(m),r&&m.from!==r&&(m.from=r)})}_setGlobalShareScopeMap(e){const t=$.getGlobalShareScope(),r=e.id||e.name;r&&!t[r]&&(t[r]=this.shareScopeMap)}};rn.SharedHandler=Vi;var nn={};const Le=P,U=b,Kt=oe,ji=q,Xi=he,at=K,xi=ve,Yt=Z,Ki=Xe,Yi=me,ie=Ae,zt=_e,zi=$e,Ji=ke,Zi=Ke;let lt=D,Jt=Y;var Qi=class{constructor(e){this.hooks=new Ji.PluginSystem({beforeRegisterRemote:new zt.SyncWaterfallHook("beforeRegisterRemote"),registerRemote:new zt.SyncWaterfallHook("registerRemote"),beforeRequest:new zi.AsyncWaterfallHook("beforeRequest"),onLoad:new ie.AsyncHook("onLoad"),handlePreloadModule:new Yi.SyncHook("handlePreloadModule"),errorLoadRemote:new ie.AsyncHook("errorLoadRemote"),beforePreloadRemote:new ie.AsyncHook("beforePreloadRemote"),generatePreloadAssets:new ie.AsyncHook("generatePreloadAssets"),afterPreloadRemote:new ie.AsyncHook,loadEntry:new ie.AsyncHook}),this.host=e,this.idToRemoteMap={}}formatAndRegisterRemote(e,t){return(t.remotes||[]).reduce((r,n)=>(this.registerRemote(n,r,{force:!1}),r),e.remotes)}setIdToRemoteMap(e,t){const{remote:r,expose:n}=t,{name:o,alias:s}=r;if(this.idToRemoteMap[e]={name:r.name,expose:n},s&&e.startsWith(o)){const i=e.replace(o,s);this.idToRemoteMap[i]={name:r.name,expose:n};return}if(s&&e.startsWith(s)){const i=e.replace(s,o);this.idToRemoteMap[i]={name:r.name,expose:n}}}async loadRemote(e,t){const{host:r}=this;try{const{loadFactory:n=!0}=t||{loadFactory:!0},{module:o,moduleOptions:s,remoteMatchInfo:i}=await this.getRemoteModuleAndOptions({id:e}),{pkgNameOrAlias:a,remote:c,expose:l,id:u,remoteSnapshot:d}=i,f=await o.get(u,l,t,d),h=await this.hooks.lifecycle.onLoad.emit({id:u,pkgNameOrAlias:a,expose:l,exposeModule:n?f:void 0,exposeModuleFactory:n?void 0:f,remote:c,options:s,moduleInstance:o,origin:r});return this.setIdToRemoteMap(e,i),typeof h=="function"?h:f}catch(n){const{from:o="runtime"}=t||{from:"runtime"},s=await this.hooks.lifecycle.errorLoadRemote.emit({id:e,error:n,from:o,lifecycle:"onLoad",origin:r});if(!s)throw n;return s}}async preloadRemote(e){const{host:t}=this;await this.hooks.lifecycle.beforePreloadRemote.emit({preloadOps:e,options:t.options,origin:t});const r=Yt.formatPreloadArgs(t.options.remotes,e);await Promise.all(r.map(async n=>{const{remote:o}=n,s=at.getRemoteInfo(o),{globalSnapshot:i,remoteSnapshot:a}=await t.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:o}),c=await this.hooks.lifecycle.generatePreloadAssets.emit({origin:t,preloadOptions:n,remote:o,remoteInfo:s,globalSnapshot:i,remoteSnapshot:a});c&&Yt.preloadAssets(s,t,c)}))}registerRemotes(e,t){const{host:r}=this;e.forEach(n=>{this.registerRemote(n,r.options.remotes,{force:t==null?void 0:t.force})})}async getRemoteModuleAndOptions(e){const{host:t}=this,{id:r}=e;let n;try{n=await this.hooks.lifecycle.beforeRequest.emit({id:r,options:t.options,origin:t})}catch(h){if(n=await this.hooks.lifecycle.errorLoadRemote.emit({id:r,options:t.options,origin:t,from:"runtime",error:h,lifecycle:"beforeRequest"}),!n)throw h}const{id:o}=n,s=Xi.matchRemoteWithNameAndExpose(t.options.remotes,o);s||Le.error(Jt.RUNTIME_004,Jt.runtimeDescMap,{hostName:t.options.name,requestId:o},void 0,xi.optionsToMFContext(t.options));const{remote:i}=s,a=at.getRemoteInfo(i),c=await t.sharedHandler.hooks.lifecycle.afterResolve.emit({id:o,...s,options:t.options,origin:t,remoteInfo:a}),{remote:l,expose:u}=c;Le.assert(l&&u,`The 'beforeRequest' hook was executed, but it failed to return the correct 'remote' and 'expose' values while loading ${o}.`);let d=t.moduleCache.get(l.name);const f={host:t,remoteInfo:a};return d||(d=new Ki.Module(f),t.moduleCache.set(l.name,d)),{module:d,moduleOptions:f,remoteMatchInfo:c}}registerRemote(e,t,r){const{host:n}=this,o=()=>{if(e.alias){const i=t.find(a=>{var c;return e.alias&&(a.name.startsWith(e.alias)||((c=a.alias)==null?void 0:c.startsWith(e.alias)))});Le.assert(!i,`The alias ${e.alias} of remote ${e.name} is not allowed to be the prefix of ${i&&i.name} name or alias`)}"entry"in e&<.isBrowserEnvValue&&typeof window<"u"&&!e.entry.startsWith("http")&&(e.entry=new URL(e.entry,window.location.origin).href),e.shareScope||(e.shareScope=Kt.DEFAULT_SCOPE),e.type||(e.type=Kt.DEFAULT_REMOTE_TYPE)};this.hooks.lifecycle.beforeRegisterRemote.emit({remote:e,origin:n});const s=t.find(i=>i.name===e.name);if(!s)o(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:n});else{const i=[`The remote "${e.name}" is already registered.`,"Please note that overriding it may cause unexpected errors."];r!=null&&r.force&&(this.removeRemote(s),o(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:n}),(0,lt.warn)(i.join(" ")))}}removeRemote(e){var t;try{const{host:r}=this,{name:n}=e,o=r.options.remotes.findIndex(i=>i.name===n);o!==-1&&r.options.remotes.splice(o,1);const s=r.moduleCache.get(e.name);if(s){const i=s.remoteInfo,a=i.entryGlobalName;U.CurrentGlobal[a]&&((t=Object.getOwnPropertyDescriptor(U.CurrentGlobal,a))!=null&&t.configurable?delete U.CurrentGlobal[a]:U.CurrentGlobal[a]=void 0);const c=at.getRemoteEntryUniqueKey(s.remoteInfo);U.globalLoading[c]&&delete U.globalLoading[c],r.snapshotHandler.manifestCache.delete(i.entry);let l=i.buildVersion?(0,lt.composeKeyWithSeparator)(i.name,i.buildVersion):i.name;const u=U.CurrentGlobal.__FEDERATION__.__INSTANCES__.findIndex(f=>i.buildVersion?f.options.id===l:f.name===l);if(u!==-1){const f=U.CurrentGlobal.__FEDERATION__.__INSTANCES__[u];l=f.options.id||l;const h=ji.getGlobalShareScope();let m=!0;const _=[];Object.keys(h).forEach(g=>{const p=h[g];p&&Object.keys(p).forEach(y=>{const I=p[y];I&&Object.keys(I).forEach(O=>{const E=I[O];E&&Object.keys(E).forEach(M=>{const R=E[M];R&&typeof R=="object"&&R.from===i.name&&(R.loaded||R.loading?(R.useIn=R.useIn.filter(A=>A!==i.name),R.useIn.length?m=!1:_.push([g,y,O,M])):_.push([g,y,O,M]))})})})}),m&&(f.shareScopeMap={},delete h[l]),_.forEach(([g,p,y,I])=>{var O,E,M;(M=(E=(O=h[g])==null?void 0:O[p])==null?void 0:E[y])==null||delete M[I]}),U.CurrentGlobal.__FEDERATION__.__INSTANCES__.splice(u,1)}const{hostGlobalSnapshot:d}=Zi.getGlobalRemoteInfo(e,r);if(d){const f=d&&"remotesInfo"in d&&d.remotesInfo&&U.getInfoWithoutType(d.remotesInfo,e.name).key;f&&(delete d.remotesInfo[f],U.Global.__FEDERATION__.__MANIFEST_LOADING__[f]&&delete U.Global.__FEDERATION__.__MANIFEST_LOADING__[f])}r.moduleCache.delete(e.name)}}catch(r){Le.logger.error(`removeRemote failed: ${r instanceof Error?r.message:String(r)}`)}}};nn.RemoteHandler=Qi;const ea=P,ta=oe,ra=q,na=jr,oa=Xr,sa=K,ia=Xe,z=me,ct=Ae,aa=_e,Zt=$e,ut=ke,la=xe,ca=Qr,ua=Ke,fa=rn,da=nn;let ha=D,ft=Y;const ma=typeof FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN=="boolean"?!FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN:!0;var _a=class{constructor(e){this.hooks=new ut.PluginSystem({beforeInit:new aa.SyncWaterfallHook("beforeInit"),init:new z.SyncHook,beforeInitContainer:new Zt.AsyncWaterfallHook("beforeInitContainer"),initContainer:new Zt.AsyncWaterfallHook("initContainer")}),this.version="2.3.0",this.moduleCache=new Map,this.loaderHook=new ut.PluginSystem({getModuleInfo:new z.SyncHook,createScript:new z.SyncHook,createLink:new z.SyncHook,fetch:new ct.AsyncHook,loadEntryError:new ct.AsyncHook,getModuleFactory:new ct.AsyncHook}),this.bridgeHook=new ut.PluginSystem({beforeBridgeRender:new z.SyncHook,afterBridgeRender:new z.SyncHook,beforeBridgeDestroy:new z.SyncHook,afterBridgeDestroy:new z.SyncHook});const t=ma?[la.snapshotPlugin(),ca.generatePreloadAssetsPlugin()]:[],r={id:na.getBuilderId(),name:e.name,plugins:t,remotes:[],shared:{},inBrowser:ha.isBrowserEnvValue};this.name=e.name,this.options=r,this.snapshotHandler=new ua.SnapshotHandler(this),this.sharedHandler=new fa.SharedHandler(this),this.remoteHandler=new da.RemoteHandler(this),this.shareScopeMap=this.sharedHandler.shareScopeMap,this.registerPlugins([...r.plugins,...e.plugins||[]]),this.options=this.formatOptions(r,e)}initOptions(e){e.name&&e.name!==this.options.name&&ea.error((0,ft.getShortErrorMsg)(ft.RUNTIME_010,ft.runtimeDescMap)),this.registerPlugins(e.plugins);const 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=ta.DEFAULT_SCOPE,t){return this.sharedHandler.initializeSharing(e,t)}initRawContainer(e,t,r){const n=sa.getRemoteInfo({name:e,entry:t}),o=new ia.Module({host:this,remoteInfo:n});return o.remoteEntryExports=r,this.moduleCache.set(e,o),o}async loadRemote(e,t){return this.remoteHandler.loadRemote(e,t)}async preloadRemote(e){return this.remoteHandler.preloadRemote(e)}initShareScopeMap(e,t,r={}){this.sharedHandler.initShareScopeMap(e,t,r)}formatOptions(e,t){const{allShareInfos:r}=ra.formatShareConfigs(e,t),{userOptions:n,options:o}=this.hooks.lifecycle.beforeInit.emit({origin:this,userOptions:t,options:e,shareInfo:r}),s=this.remoteHandler.formatAndRegisterRemote(o,n),{allShareInfos:i}=this.sharedHandler.registerShared(o,n),a=[...o.plugins];n.plugins&&n.plugins.forEach(l=>{a.includes(l)||a.push(l)});const c={...e,...t,plugins:a,remotes:s,shared:i};return this.hooks.lifecycle.init.emit({origin:this,options:c}),c}registerPlugins(e){const t=oa.registerPlugins(e,this);this.options.plugins=this.options.plugins.reduce((r,n)=>(n&&r&&!r.find(o=>o.name===n.name)&&r.push(n),r),t||[])}registerRemotes(e,t){return this.remoteHandler.registerRemotes(e,t)}registerShared(e){this.sharedHandler.registerShared(this.options,{...this.options,shared:e})}};Yr.ModuleFederation=_a;var on={},sn={},Qt=Object.defineProperty,ga=(e,t)=>{let r={};for(var n in e)Qt(r,n,{get:e[n],enumerable:!0});return t||Qt(r,Symbol.toStringTag,{value:"Module"}),r};sn.__exportAll=ga;(function(e){var r=sn.__exportAll({});Object.defineProperty(e,"type_exports",{enumerable:!0,get:function(){return r}})})(on);(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=P,r=N,n=b,o=vt,s=q,i=he,a=K,c=xr,l=Xe,u=Yr,d=on;let f=D;const h=c.default;e.CurrentGlobal=n.CurrentGlobal,e.Global=n.Global,e.Module=l.Module,e.ModuleFederation=u.ModuleFederation,e.addGlobalSnapshot=n.addGlobalSnapshot,e.assert=t.assert,e.error=t.error,e.getGlobalFederationConstructor=n.getGlobalFederationConstructor,e.getGlobalSnapshot=n.getGlobalSnapshot,e.getInfoWithoutType=n.getInfoWithoutType,e.getRegisteredShare=s.getRegisteredShare,e.getRemoteEntry=a.getRemoteEntry,e.getRemoteInfo=a.getRemoteInfo,e.helpers=h,e.isStaticResourcesEqual=r.isStaticResourcesEqual,Object.defineProperty(e,"loadScript",{enumerable:!0,get:function(){return f.loadScript}}),Object.defineProperty(e,"loadScriptNode",{enumerable:!0,get:function(){return f.loadScriptNode}}),e.matchRemoteWithNameAndExpose=i.matchRemoteWithNameAndExpose,e.registerGlobalPlugins=n.registerGlobalPlugins,e.resetFederationGlobalInfo=n.resetFederationGlobalInfo,e.safeWrapper=r.safeWrapper,e.satisfy=o.satisfy,e.setGlobalFederationConstructor=n.setGlobalFederationConstructor,e.setGlobalFederationInstance=n.setGlobalFederationInstance,Object.defineProperty(e,"types",{enumerable:!0,get:function(){return d.type_exports}})})(Tt);let pa=Tt;function Ea(){return typeof FEDERATION_BUILD_IDENTIFIER<"u"?FEDERATION_BUILD_IDENTIFIER:""}function ya(e,t){const r=Ea();return pa.CurrentGlobal.__FEDERATION__.__INSTANCES__.find(n=>!!(r&&n.options.id===r||n.options.name===e&&!n.options.version&&!t||n.options.name===e&&t&&n.options.version===t))}ar.getGlobalFederationInstance=ya;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=ar;let r=Tt,n=Y;function o(_){const g=new((0,r.getGlobalFederationConstructor)()||r.ModuleFederation)(_);return(0,r.setGlobalFederationInstance)(g),g}let s=null;function i(_){const g=t.getGlobalFederationInstance(_.name,_.version);return g?(g.initOptions(_),s||(s=g),g):(s=o(_),s)}function a(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.loadRemote.apply(s,_)}function c(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.loadShare.apply(s,_)}function l(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.loadShareSync.apply(s,_)}function u(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.preloadRemote.apply(s,_)}function d(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.registerRemotes.apply(s,_)}function f(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.registerPlugins.apply(s,_)}function h(){return s}function m(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.registerShared.apply(s,_)}(0,r.setGlobalFederationConstructor)(r.ModuleFederation),Object.defineProperty(e,"Module",{enumerable:!0,get:function(){return r.Module}}),e.ModuleFederation=r.ModuleFederation,e.createInstance=o,e.getInstance=h,Object.defineProperty(e,"getRemoteEntry",{enumerable:!0,get:function(){return r.getRemoteEntry}}),Object.defineProperty(e,"getRemoteInfo",{enumerable:!0,get:function(){return r.getRemoteInfo}}),e.init=i,e.loadRemote=a,Object.defineProperty(e,"loadScript",{enumerable:!0,get:function(){return r.loadScript}}),Object.defineProperty(e,"loadScriptNode",{enumerable:!0,get:function(){return r.loadScriptNode}}),e.loadShare=c,e.loadShareSync=l,e.preloadRemote=u,Object.defineProperty(e,"registerGlobalPlugins",{enumerable:!0,get:function(){return r.registerGlobalPlugins}}),e.registerPlugins=f,e.registerRemotes=d,e.registerShared=m})(ir);typeof __VUE_HMR_RUNTIME__>"u"&&(globalThis.__VUE_HMR_RUNTIME__={createRecord(){},rerender(){},reload(){}});const an="__mf_init____mf__virtual/ActionVisu__mf_v__runtimeInit__mf_v__.js__";let Rt=globalThis[an];if(!Rt){let e,t;const r=new Promise((n,o)=>{e=n,t=o});Rt=globalThis[an]={initPromise:r,initResolve:e,initReject:t},typeof window>"u"&&e({loadRemote:function(){return Promise.resolve(void 0)},loadShare:function(){return Promise.resolve(void 0)}})}const Sa=Rt.initResolve,er={},tr="default",rr="ActionVisu";let nr,or;async function ba(){return nr??=import("./assets/localSharedImportMap-8wECk2hR.js"),nr}async function Ra(){return or??=import("./assets/virtualExposes-b6CxLzZb.js").then(e=>e.default??e),or}async function Ia(e={},t=[]){const{usedShared:r,usedRemotes:n}=await ba(),o=ir.init({name:rr,remotes:n,shared:r,plugins:[],shareStrategy:"version-first"});var s=er[tr];if(s||(s=er[tr]={from:rr}),!(t.indexOf(s)>=0)){t.push(s),o.initShareScopeMap("default",e),Sa(o);try{await Promise.all(await o.initializeSharing("default",{strategy:"version-first",from:"build",initScope:t}))}catch(i){console.error("[Module Federation]",i)}return o}}async function Na(e){const t=await Ra();if(!(e in t))throw new Error(`[Module Federation] Module ${e} does not exist in container.`);return t[e]().then(r=>()=>r)}export{Na as get,Ia as init};
|
|
6
|
+
`)};Pt.getShortErrorMsg=eo;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Pt;function r(n,o,s,i,a,c){return i(t.getShortErrorMsg(n,o,s,a))}e.logAndReport=r})(Mr);let to=D,ro=Mr;const ee="[ Federation Runtime ]",ht=(0,to.createLogger)(ee);function no(e,t,r,n,o){e||(r!==void 0?mt(t,r,n,void 0,o):mt(t))}function mt(e,t,r,n,o){if(t!==void 0)return(0,ro.logAndReport)(e,t,r??{},i=>{throw new Error(`${ee}: ${i}`)},n,o);const s=e;throw s instanceof Error?(s.message.startsWith(ee)||(s.message=`${ee}: ${s.message}`),s):new Error(`${ee}: ${s}`)}function oo(e){e instanceof Error&&(e.message.startsWith(ee)||(e.message=`${ee}: ${e.message}`)),ht.warn(e)}P.assert=no;P.error=mt;P.logger=ht;P.warn=oo;var N={};const so=P;let Ft=D;function io(e,t){return e.findIndex(r=>r===t)===-1&&e.push(t),e}function ao(e){return"version"in e&&e.version?`${e.name}:${e.version}`:"entry"in e&&e.entry?`${e.name}:${e.entry}`:`${e.name}`}function lo(e){return typeof e.entry<"u"}function co(e){return!e.entry.includes(".json")}async function uo(e,t){try{return await e()}catch(r){!t&&so.warn(r);return}}function fo(e){return e&&typeof e=="object"}const Pr=Object.prototype.toString;function ho(e){return Pr.call(e)==="[object Object]"}function mo(e,t){const r=/^(https?:)?\/\//i;return e.replace(r,"").replace(/\/$/,"")===t.replace(r,"").replace(/\/$/,"")}function _o(e){return Array.isArray(e)?e:[e]}function go(e){const t={url:"",type:"global",globalName:""};return Ft.isBrowserEnvValue||(0,Ft.isReactNativeEnv)()||!("ssrRemoteEntry"in e)?"remoteEntry"in e?{url:e.remoteEntry,type:e.remoteEntryType,globalName:e.globalName}:t:"ssrRemoteEntry"in e?{url:e.ssrRemoteEntry||t.url,type:e.ssrRemoteEntryType||t.type,globalName:e.globalName}:t}const po=(e,t)=>{let r;return e.endsWith("/")?r=e.slice(0,-1):r=e,t.startsWith(".")&&(t=t.slice(1)),r=r+t,r};N.addUniqueItem=io;N.arrayOptions=_o;N.getFMId=ao;N.getRemoteEntryInfoFromSnapshot=go;N.isObject=fo;N.isPlainObject=ho;N.isPureRemoteEntry=co;N.isRemoteInfoWithEntry=lo;N.isStaticResourcesEqual=mo;N.objectToString=Pr;N.processModuleAlias=po;N.safeWrapper=uo;var b={};const vr=P,_t=N;let Eo=D;const k=typeof globalThis=="object"?globalThis:window,C=(()=>{try{return document.defaultView}catch{return k}})(),yo=C;function He(e,t,r){Object.defineProperty(e,t,{value:r,configurable:!1,writable:!0})}function Ce(e,t){return Object.hasOwnProperty.call(e,t)}Ce(k,"__GLOBAL_LOADING_REMOTE_ENTRY__")||He(k,"__GLOBAL_LOADING_REMOTE_ENTRY__",{});const gt=k.__GLOBAL_LOADING_REMOTE_ENTRY__;function Ar(e){Ce(e,"__VMOK__")&&!Ce(e,"__FEDERATION__")&&He(e,"__FEDERATION__",e.__VMOK__),Ce(e,"__FEDERATION__")||(He(e,"__FEDERATION__",{__GLOBAL_PLUGIN__:[],__INSTANCES__:[],moduleInfo:{},__SHARE__:{},__MANIFEST_LOADING__:{},__PRELOADED_MAP__:new Map}),He(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}Ar(k);Ar(C);function So(){k.__FEDERATION__.__GLOBAL_PLUGIN__=[],k.__FEDERATION__.__INSTANCES__=[],k.__FEDERATION__.moduleInfo={},k.__FEDERATION__.__SHARE__={},k.__FEDERATION__.__MANIFEST_LOADING__={},Object.keys(gt).forEach(e=>{delete gt[e]})}function bo(e){k.__FEDERATION__.__INSTANCES__.push(e)}function Ro(){return k.__FEDERATION__.__DEBUG_CONSTRUCTOR__}function To(e,t=(0,Eo.isDebugMode)()){t&&(k.__FEDERATION__.__DEBUG_CONSTRUCTOR__=e,k.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__="2.3.1")}function pt(e,t){if(typeof t=="string"){if(e[t])return{value:e[t],key:t};{const r=Object.keys(e);for(const n of r){const[o,s]=n.split(":"),i=`${o}:${t}`,a=e[i];if(a)return{value:a,key:i}}return{value:void 0,key:t}}}else vr.error(`getInfoWithoutType: "key" must be a string, got ${typeof t} (${JSON.stringify(t)}).`)}const Io=()=>C.__FEDERATION__.moduleInfo,$r=(e,t)=>{const r=pt(t,_t.getFMId(e)).value;if(r&&!r.version&&"version"in e&&e.version&&(r.version=e.version),r)return r;if("version"in e&&e.version){const{version:n,...o}=e,s=_t.getFMId(o),i=pt(C.__FEDERATION__.moduleInfo,s).value;if((i==null?void 0:i.version)===n)return i}},No=e=>$r(e,C.__FEDERATION__.moduleInfo),Mo=(e,t)=>{const r=_t.getFMId(e);return C.__FEDERATION__.moduleInfo[r]=t,C.__FEDERATION__.moduleInfo},Po=e=>(C.__FEDERATION__.moduleInfo={...C.__FEDERATION__.moduleInfo,...e},()=>{const t=Object.keys(e);for(const r of t)delete C.__FEDERATION__.moduleInfo[r]}),vo=(e,t)=>{const r=t||`__FEDERATION_${e}:custom__`;return{remoteEntryKey:r,entryExports:k[r]}},Ao=e=>{const{__GLOBAL_PLUGIN__:t}=C.__FEDERATION__;e.forEach(r=>{t.findIndex(n=>n.name===r.name)===-1?t.push(r):vr.warn(`The plugin ${r.name} has been registered.`)})},$o=()=>C.__FEDERATION__.__GLOBAL_PLUGIN__,ko=e=>k.__FEDERATION__.__PRELOADED_MAP__.get(e),Oo=e=>k.__FEDERATION__.__PRELOADED_MAP__.set(e,!0);b.CurrentGlobal=k;b.Global=yo;b.addGlobalSnapshot=Po;b.getGlobalFederationConstructor=Ro;b.getGlobalHostPlugins=$o;b.getGlobalSnapshot=Io;b.getGlobalSnapshotInfoByModuleInfo=No;b.getInfoWithoutType=pt;b.getPreloaded=ko;b.getRemoteEntryExports=vo;b.getTargetSnapshotInfoByModuleInfo=$r;b.globalLoading=gt;b.nativeGlobal=C;b.registerGlobalPlugins=Ao;b.resetFederationGlobalInfo=So;b.setGlobalFederationConstructor=To;b.setGlobalFederationInstance=bo;b.setGlobalSnapshotInfoByModuleInfo=Mo;b.setPreloaded=Oo;var vt={},ne={},W={};const wt="[0-9A-Za-z-]+",At=`(?:\\+(${wt}(?:\\.${wt})*))`,Re="0|[1-9]\\d*",qe="[0-9]+",kr="\\d*[a-zA-Z-][a-zA-Z0-9-]*",Lt=`(?:${qe}|${kr})`,Fo=`(?:-?(${Lt}(?:\\.${Lt})*))`,Dt=`(?:${Re}|${kr})`,Or=`(?:-(${Dt}(?:\\.${Dt})*))`,ze=`${Re}|x|X|\\*`,ce=`[v=\\s]*(${ze})(?:\\.(${ze})(?:\\.(${ze})(?:${Or})?${At}?)?)?`,wo=`^\\s*(${ce})\\s+-\\s+(${ce})\\s*$`,Lo=`[v=\\s]*${`(${qe})\\.(${qe})\\.(${qe})`}${Fo}?${At}?`,$t="((?:<|>)?=?)",Do=`(\\s*)${$t}\\s*(${Lo}|${ce})`,Fr="(?:~>?)",Ho=`(\\s*)${Fr}\\s+`,wr="(?:\\^)",Co=`(\\s*)${wr}\\s+`,qo="(<|>)?=?\\s*\\*",Uo=`^${wr}${ce}$`,Go=`v?${`(${Re})\\.(${Re})\\.(${Re})`}${Or}?${At}?`,Wo=`^${Fr}${ce}$`,Bo=`^${$t}\\s*${ce}$`,Vo=`^${$t}\\s*(${Go})$|^$`,jo="^\\s*>=\\s*0.0.0\\s*$";W.caret=Uo;W.caretTrim=Co;W.comparator=Vo;W.comparatorTrim=Do;W.gte0=jo;W.hyphenRange=wo;W.star=qo;W.tilde=Wo;W.tildeTrim=Ho;W.xRange=Bo;const Xo=W;function Lr(e){return new RegExp(e)}function xo(e){return!e||e.toLowerCase()==="x"||e==="*"}function Ko(...e){return t=>e.reduce((r,n)=>n(r),t)}function Yo(e){return e.match(Lr(Xo.comparator))}function zo(e,t,r,n){const o=`${e}.${t}.${r}`;return n?`${o}-${n}`:o}ne.combineVersion=zo;ne.extractComparator=Yo;ne.isXVersion=xo;ne.parseRegex=Lr;ne.pipe=Ko;var j={};const x=W,T=ne;function Jo(e){return e.replace(T.parseRegex(x.hyphenRange),(t,r,n,o,s,i,a,c,l,u,d,f)=>(T.isXVersion(n)?r="":T.isXVersion(o)?r=`>=${n}.0.0`:T.isXVersion(s)?r=`>=${n}.${o}.0`:r=`>=${r}`,T.isXVersion(l)?c="":T.isXVersion(u)?c=`<${Number(l)+1}.0.0-0`:T.isXVersion(d)?c=`<${l}.${Number(u)+1}.0-0`:f?c=`<=${l}.${u}.${d}-${f}`:c=`<=${c}`,`${r} ${c}`.trim()))}function Zo(e){return e.replace(T.parseRegex(x.comparatorTrim),"$1$2$3")}function Qo(e){return e.replace(T.parseRegex(x.tildeTrim),"$1~")}function es(e){return e.replace(T.parseRegex(x.caretTrim),"$1^")}function ts(e){return e.trim().split(/\s+/).map(t=>t.replace(T.parseRegex(x.caret),(r,n,o,s,i)=>T.isXVersion(n)?"":T.isXVersion(o)?`>=${n}.0.0 <${Number(n)+1}.0.0-0`:T.isXVersion(s)?n==="0"?`>=${n}.${o}.0 <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.0 <${Number(n)+1}.0.0-0`:i?n==="0"?o==="0"?`>=${n}.${o}.${s}-${i} <${n}.${o}.${Number(s)+1}-0`:`>=${n}.${o}.${s}-${i} <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.${s}-${i} <${Number(n)+1}.0.0-0`:n==="0"?o==="0"?`>=${n}.${o}.${s} <${n}.${o}.${Number(s)+1}-0`:`>=${n}.${o}.${s} <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.${s} <${Number(n)+1}.0.0-0`)).join(" ")}function rs(e){return e.trim().split(/\s+/).map(t=>t.replace(T.parseRegex(x.tilde),(r,n,o,s,i)=>T.isXVersion(n)?"":T.isXVersion(o)?`>=${n}.0.0 <${Number(n)+1}.0.0-0`:T.isXVersion(s)?`>=${n}.${o}.0 <${n}.${Number(o)+1}.0-0`:i?`>=${n}.${o}.${s}-${i} <${n}.${Number(o)+1}.0-0`:`>=${n}.${o}.${s} <${n}.${Number(o)+1}.0-0`)).join(" ")}function ns(e){return e.split(/\s+/).map(t=>t.trim().replace(T.parseRegex(x.xRange),(r,n,o,s,i,a)=>{const c=T.isXVersion(o),l=c||T.isXVersion(s),u=l||T.isXVersion(i);return n==="="&&u&&(n=""),a="",c?n===">"||n==="<"?"<0.0.0-0":"*":n&&u?(l&&(s=0),i=0,n===">"?(n=">=",l?(o=Number(o)+1,s=0,i=0):(s=Number(s)+1,i=0)):n==="<="&&(n="<",l?o=Number(o)+1:s=Number(s)+1),n==="<"&&(a="-0"),`${n+o}.${s}.${i}${a}`):l?`>=${o}.0.0${a} <${Number(o)+1}.0.0-0`:u?`>=${o}.${s}.0${a} <${o}.${Number(s)+1}.0-0`:r})).join(" ")}function os(e){return e.trim().replace(T.parseRegex(x.star),"")}function ss(e){return e.trim().replace(T.parseRegex(x.gte0),"")}j.parseCaretTrim=es;j.parseCarets=ts;j.parseComparatorTrim=Zo;j.parseGTE0=ss;j.parseHyphen=Jo;j.parseStar=os;j.parseTildeTrim=Qo;j.parseTildes=rs;j.parseXRanges=ns;var Dr={};function Ue(e,t){return e=Number(e)||e,t=Number(t)||t,e>t?1:e===t?0:-1}function is(e,t){const{preRelease:r}=e,{preRelease:n}=t;if(r===void 0&&n)return 1;if(r&&n===void 0)return-1;if(r===void 0&&n===void 0)return 0;for(let o=0,s=r.length;o<=s;o++){const i=r[o],a=n[o];if(i!==a)return i===void 0&&a===void 0?0:i?a?Ue(i,a):-1:1}return 0}function Oe(e,t){return Ue(e.major,t.major)||Ue(e.minor,t.minor)||Ue(e.patch,t.patch)||is(e,t)}function Je(e,t){return e.version===t.version}function as(e,t){switch(e.operator){case"":case"=":return Je(e,t);case">":return Oe(e,t)<0;case">=":return Je(e,t)||Oe(e,t)<0;case"<":return Oe(e,t)>0;case"<=":return Je(e,t)||Oe(e,t)>0;case void 0:return!0;default:return!1}}Dr.compare=as;const ae=ne,X=j,ls=Dr;function cs(e){return ae.pipe(X.parseCarets,X.parseTildes,X.parseXRanges,X.parseStar)(e)}function us(e){return ae.pipe(X.parseHyphen,X.parseComparatorTrim,X.parseTildeTrim,X.parseCaretTrim)(e.trim()).split(/\s+/).join(" ")}function fs(e,t){if(!e)return!1;const r=ae.extractComparator(e);if(!r)return!1;const[,n,,o,s,i,a]=r,c={operator:n,version:ae.combineVersion(o,s,i,a),major:o,minor:s,patch:i,preRelease:a==null?void 0:a.split(".")},l=t.split("||");for(const u of l){const d=u.trim();if(!d||d==="*"||d==="x")return!0;try{const f=us(d);if(!f.trim())return!0;const h=f.split(" ").map(g=>cs(g)).join(" ");if(!h.trim())return!0;const m=h.split(/\s+/).map(g=>X.parseGTE0(g)).filter(Boolean);if(m.length===0)continue;let _=!0;for(const g of m){const p=ae.extractComparator(g);if(!p){_=!1;break}const[,y,,I,O,E,M]=p;if(!ls.compare({operator:y,version:ae.combineVersion(I,O,E,M),major:I,minor:O,patch:E,preRelease:M==null?void 0:M.split(".")},c)){_=!1;break}}if(_)return!0}catch(f){console.error(`[semver] Error processing range part "${d}":`,f);continue}}return!1}vt.satisfy=fs;var q={},oe={};const ds="default",hs="global";oe.DEFAULT_REMOTE_TYPE=hs;oe.DEFAULT_SCOPE=ds;const We=P,Hr=N,Cr=b,ms=oe,ye=vt;let Et=D;function _s(e,t,r,n){var s,i;let o;return"get"in e?o=e.get:"lib"in e?o=()=>Promise.resolve(e.lib):o=()=>Promise.resolve(()=>{We.error(`Cannot get shared "${r}" from "${t}": neither "get" nor "lib" is provided in the share config.`)}),(s=e.shareConfig)!=null&&s.eager&&((i=e.treeShaking)!=null&&i.mode)&&We.error(`Invalid shared config for "${r}" 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:o,loaded:e!=null&&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??n)||"version-first",treeShaking:e.treeShaking?{...e.treeShaking,mode:e.treeShaking.mode??"server-calc",status:e.treeShaking.status??Et.TreeShakingStatus.UNKNOWN,useIn:[]}:void 0}}function gs(e,t){const r=t.shared||{},n=t.name,o=Object.keys(r).reduce((i,a)=>{const c=Hr.arrayOptions(r[a]);return i[a]=i[a]||[],c.forEach(l=>{i[a].push(_s(l,n,a,t.shareStrategy))}),i},{}),s={...e.shared};return Object.keys(o).forEach(i=>{s[i]?o[i].forEach(a=>{s[i].find(c=>c.version===a.version)||s[i].push(a)}):s[i]=o[i]}),{allShareInfos:s,newShareInfos:o}}function Te(e,t){if(!e)return!1;const{status:r,mode:n}=e;return r===Et.TreeShakingStatus.NO_USE?!1:r===Et.TreeShakingStatus.CALCULATED?!0:n==="runtime-infer"?t?Es(e,t):!0:!1}function te(e,t){const r=n=>{if(!Number.isNaN(Number(n))){const o=n.split(".");let s=n;for(let i=0;i<3-o.length;i++)s+=".0";return s}return n};return!!ye.satisfy(r(e),`<=${r(t)}`)}const Ie=(e,t)=>{const r=t||function(n,o){return te(n,o)};return Object.keys(e).reduce((n,o)=>!n||r(n,o)||n==="0"?o:n,0)},Be=e=>!!e.loaded||typeof e.lib=="function",ps=e=>!!e.loading,Es=(e,t)=>{if(!e||!t)return!1;const{usedExports:r}=e;return r?!!t.every(n=>r.includes(n)):!1};function ys(e,t,r,n){const o=e[t][r];let s="",i=Te(n);const a=function(c,l){return i?o[c].treeShaking?o[l].treeShaking?!Be(o[c].treeShaking)&&te(c,l):!1:!0:!Be(o[c])&&te(c,l)};if(i){if(s=Ie(e[t][r],a),s)return{version:s,useTreesShaking:i};i=!1}return{version:Ie(e[t][r],a),useTreesShaking:i}}const se=e=>Be(e)||ps(e);function Ss(e,t,r,n){const o=e[t][r];let s="",i=Te(n);const a=function(c,l){if(i){if(!o[c].treeShaking)return!0;if(!o[l].treeShaking)return!1;if(se(o[l].treeShaking))return se(o[c].treeShaking)?!!te(c,l):!0;if(se(o[c].treeShaking))return!1}return se(o[l])?se(o[c])?!!te(c,l):!0:se(o[c])?!1:te(c,l)};if(i){if(s=Ie(e[t][r],a),s)return{version:s,useTreesShaking:i};i=!1}return{version:Ie(e[t][r],a),useTreesShaking:i}}function bs(e){return e==="loaded-first"?Ss:ys}function Rs(e,t,r,n){if(!e)return;const{shareConfig:o,scope:s=ms.DEFAULT_SCOPE,strategy:i,treeShaking:a}=r,c=Array.isArray(s)?s:[s];for(const l of c)if(o&&e[l]&&e[l][t]){const{requiredVersion:u}=o,{version:d,useTreesShaking:f}=bs(i)(e,l,t,a),h=()=>{const _=e[l][t][d];if(o.singleton){if(typeof u=="string"&&!ye.satisfy(d,u)){const g=`Version ${d} from ${d&&_.from} of shared singleton module ${t} does not satisfy the requirement of ${r.from} which needs ${u})`;o.strictVersion?We.error(g):We.warn(g)}return{shared:_,useTreesShaking:f}}else{if(u===!1||u==="*")return{shared:_,useTreesShaking:f};if(ye.satisfy(d,u))return{shared:_,useTreesShaking:f};const g=Te(a);if(g){for(const[p,y]of Object.entries(e[l][t]))if(Te(y.treeShaking,a==null?void 0:a.usedExports)&&ye.satisfy(p,u))return{shared:y,useTreesShaking:g}}for(const[p,y]of Object.entries(e[l][t]))if(ye.satisfy(p,u))return{shared:y,useTreesShaking:!1}}},m={shareScopeMap:e,scope:l,pkgName:t,version:d,GlobalFederation:Cr.Global.__FEDERATION__,shareInfo:r,resolver:h};return(n.emit(m)||m).resolver()}}function Ts(){return Cr.Global.__FEDERATION__.__SHARE__}function Is(e){const{pkgName:t,extraOptions:r,shareInfos:n}=e,o=c=>{if(!c)return;const l={};return c.forEach(d=>{l[d.version]=d}),l[Ie(l,function(d,f){return!Be(l[d])&&te(d,f)})]},s=(r==null?void 0:r.resolver)??o,i=c=>c!==null&&typeof c=="object"&&!Array.isArray(c),a=(...c)=>{const l={};for(const u of c)if(u)for(const[d,f]of Object.entries(u)){const h=l[d];i(h)&&i(f)?l[d]=a(h,f):f!==void 0&&(l[d]=f)}return l};return a(s(n[t]),r==null?void 0:r.customShareInfo)}const Ns=(e,t)=>{e.useIn||(e.useIn=[]),Hr.addUniqueItem(e.useIn,t)};function Ms(e,t){return t&&e.treeShaking?e.treeShaking:e}q.addUseIn=Ns;q.directShare=Ms;q.formatShareConfigs=gs;q.getGlobalShareScope=Ts;q.getRegisteredShare=Rs;q.getTargetSharedOptions=Is;q.shouldUseTreeShaking=Te;var he={};function Ps(e,t){for(const r of e){const n=t.startsWith(r.name);let o=t.replace(r.name,"");if(n){if(o.startsWith("/")){const a=r.name;return o=`.${o}`,{pkgNameOrAlias:a,expose:o,remote:r}}else if(o==="")return{pkgNameOrAlias:r.name,expose:".",remote:r}}const s=r.alias&&t.startsWith(r.alias);let i=r.alias&&t.replace(r.alias,"");if(r.alias&&s){if(i&&i.startsWith("/")){const a=r.alias;return i=`.${i}`,{pkgNameOrAlias:a,expose:i,remote:r}}else if(i==="")return{pkgNameOrAlias:r.alias,expose:".",remote:r}}}}function vs(e,t){for(const r of e)if(t===r.name||r.alias&&t===r.alias)return r}he.matchRemote=vs;he.matchRemoteWithNameAndExpose=Ps;var K={},Y={},w={};const As="RUNTIME-001",$s="RUNTIME-002",ks="RUNTIME-003",Os="RUNTIME-004",Fs="RUNTIME-005",ws="RUNTIME-006",Ls="RUNTIME-007",Ds="RUNTIME-008",Hs="RUNTIME-009",Cs="RUNTIME-010",qs="RUNTIME-011",Us="RUNTIME-012",Gs="TYPE-001",Ws="BUILD-001",Bs="BUILD-002";w.BUILD_001=Ws;w.BUILD_002=Bs;w.RUNTIME_001=As;w.RUNTIME_002=$s;w.RUNTIME_003=ks;w.RUNTIME_004=Os;w.RUNTIME_005=Fs;w.RUNTIME_006=ws;w.RUNTIME_007=Ls;w.RUNTIME_008=Ds;w.RUNTIME_009=Hs;w.RUNTIME_010=Cs;w.RUNTIME_011=qs;w.RUNTIME_012=Us;w.TYPE_001=Gs;var Pe={};const L=w,qr={[L.RUNTIME_001]:"Failed to get remoteEntry exports.",[L.RUNTIME_002]:'The remote entry interface does not contain "init"',[L.RUNTIME_003]:"Failed to get manifest.",[L.RUNTIME_004]:"Failed to locate remote.",[L.RUNTIME_005]:"Invalid loadShareSync function call from bundler runtime",[L.RUNTIME_006]:"Invalid loadShareSync function call from runtime",[L.RUNTIME_007]:"Failed to get remote snapshot.",[L.RUNTIME_008]:"Failed to load script resources.",[L.RUNTIME_009]:"Please call createInstance first.",[L.RUNTIME_010]:'The name option cannot be changed after initialization. If you want to create a new instance with a different name, please use "createInstance" api.',[L.RUNTIME_011]:"The remoteEntry URL is missing from the remote snapshot.",[L.RUNTIME_012]:'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.'},Ur={[L.TYPE_001]:"Failed to generate type declaration. Execute the below cmd to reproduce and fix the error."},Gr={[L.BUILD_001]:"Failed to find expose module.",[L.BUILD_002]:"PublicPath is required in prod mode."},Vs={...qr,...Ur,...Gr};Pe.buildDescMap=Gr;Pe.errorDescMap=Vs;Pe.runtimeDescMap=qr;Pe.typeDescMap=Ur;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=w,r=Pt,n=Pe;e.BUILD_001=t.BUILD_001,e.BUILD_002=t.BUILD_002,e.RUNTIME_001=t.RUNTIME_001,e.RUNTIME_002=t.RUNTIME_002,e.RUNTIME_003=t.RUNTIME_003,e.RUNTIME_004=t.RUNTIME_004,e.RUNTIME_005=t.RUNTIME_005,e.RUNTIME_006=t.RUNTIME_006,e.RUNTIME_007=t.RUNTIME_007,e.RUNTIME_008=t.RUNTIME_008,e.RUNTIME_009=t.RUNTIME_009,e.RUNTIME_010=t.RUNTIME_010,e.RUNTIME_011=t.RUNTIME_011,e.RUNTIME_012=t.RUNTIME_012,e.TYPE_001=t.TYPE_001,e.buildDescMap=n.buildDescMap,e.errorDescMap=n.errorDescMap,e.getShortErrorMsg=r.getShortErrorMsg,e.runtimeDescMap=n.runtimeDescMap,e.typeDescMap=n.typeDescMap})(Y);const je=P,le=b,Ht=oe;let Wr=D,Ne=Y;const Br=".then(callbacks[0]).catch(callbacks[1])";async function js({entry:e,remoteEntryExports:t}){return new Promise((r,n)=>{try{t?r(t):typeof FEDERATION_ALLOW_NEW_FUNCTION<"u"?new Function("callbacks",`import("${e}")${Br}`)([r,n]):import(e).then(r).catch(n)}catch(o){je.error(`Failed to load ESM entry from "${e}". ${o instanceof Error?o.message:String(o)}`)}})}async function Xs({entry:e,remoteEntryExports:t}){return new Promise((r,n)=>{try{t?r(t):typeof __system_context__>"u"?System.import(e).then(r).catch(n):new Function("callbacks",`System.import("${e}")${Br}`)([r,n])}catch(o){je.error(`Failed to load SystemJS entry from "${e}". ${o instanceof Error?o.message:String(o)}`)}})}function xs(e,t,r){const{remoteEntryKey:n,entryExports:o}=le.getRemoteEntryExports(e,t);return o||je.error(Ne.RUNTIME_001,Ne.runtimeDescMap,{remoteName:e,remoteEntryUrl:r,remoteEntryKey:n}),o}async function Ks({name:e,globalName:t,entry:r,loaderHook:n,getEntryUrl:o}){const{entryExports:s}=le.getRemoteEntryExports(e,t);if(s)return s;const i=o?o(r):r;return(0,Wr.loadScript)(i,{attrs:{},createScriptHook:(a,c)=>{const l=n.lifecycle.createScript.emit({url:a,attrs:c});if(l&&(l instanceof HTMLScriptElement||"script"in l||"timeout"in l))return l}}).then(()=>xs(e,t,r),a=>{const c=a instanceof Error?a.message:String(a);je.error(Ne.RUNTIME_008,Ne.runtimeDescMap,{remoteName:e,resourceUrl:i},c)})}async function Ys({remoteInfo:e,remoteEntryExports:t,loaderHook:r,getEntryUrl:n}){const{entry:o,entryGlobalName:s,name:i,type:a}=e;switch(a){case"esm":case"module":return js({entry:o,remoteEntryExports:t});case"system":return Xs({entry:o,remoteEntryExports:t});default:return Ks({entry:o,globalName:s,name:i,loaderHook:r,getEntryUrl:n})}}function yt(e){const{entry:t,name:r}=e;return(0,Wr.composeKeyWithSeparator)(r,t)}async function Vr(e){const{origin:t,remoteEntryExports:r,remoteInfo:n,getEntryUrl:o,_inErrorHandling:s=!1}=e,i=yt(n);if(r)return r;if(!le.globalLoading[i]){const a=t.remoteHandler.hooks.lifecycle.loadEntry,c=t.loaderHook;le.globalLoading[i]=a.emit({loaderHook:c,remoteInfo:n,remoteEntryExports:r}).then(l=>l||Ys({remoteInfo:n,remoteEntryExports:r,loaderHook:c,getEntryUrl:o})).catch(async l=>{const u=yt(n),d=l instanceof Error&&l.message.includes("ScriptExecutionError");if(l instanceof Error&&l.message.includes(Ne.RUNTIME_008)&&!d&&!s){const f=m=>Vr({...m,_inErrorHandling:!0}),h=await t.loaderHook.lifecycle.loadEntryError.emit({getRemoteEntry:f,origin:t,remoteInfo:n,remoteEntryExports:r,globalLoading:le.globalLoading,uniqueKey:u});if(h)return h}throw l})}return le.globalLoading[i]}function zs(e){return{...e,entry:"entry"in e?e.entry:"",type:e.type||Ht.DEFAULT_REMOTE_TYPE,entryGlobalName:e.entryGlobalName||e.name,shareScope:e.shareScope||Ht.DEFAULT_SCOPE}}K.getRemoteEntry=Vr;K.getRemoteEntryUniqueKey=yt;K.getRemoteInfo=zs;var jr={};function Js(){return typeof FEDERATION_BUILD_IDENTIFIER<"u"?FEDERATION_BUILD_IDENTIFIER:""}jr.getBuilderId=Js;var Xr={};const Zs=b;function Qs(e,t){const r=Zs.getGlobalHostPlugins(),n=[t.hooks,t.remoteHandler.hooks,t.sharedHandler.hooks,t.snapshotHandler.hooks,t.loaderHook,t.bridgeHook];return r.length>0&&r.forEach(o=>{e!=null&&e.find(s=>s.name!==o.name)&&e.push(o)}),e&&e.length>0&&e.forEach(o=>{n.forEach(s=>{s.applyPlugin(o,t)})}),e}Xr.registerPlugins=Qs;var ve={};function ei(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 ti(e){var r,n,o,s,i,a;const t={};for(const[c,l]of Object.entries(e.shared)){const u=l[0];u&&(t[c]={version:u.version,singleton:(r=u.shareConfig)==null?void 0:r.singleton,requiredVersion:((n=u.shareConfig)==null?void 0:n.requiredVersion)===!1?!1:(o=u.shareConfig)==null?void 0:o.requiredVersion,eager:u.eager,strictVersion:(s=u.shareConfig)==null?void 0:s.strictVersion})}return{project:{name:e.name,mfRole:((i=e.remotes)==null?void 0:i.length)>0?"host":"unknown"},mfConfig:{name:e.name,remotes:((a=e.remotes)==null?void 0:a.map(ei))??[],shared:t}}}ve.optionsToMFContext=ti;var xr={},Z={};const ri=P,ni=he,Ct=K;let Se=D;function Kr(e){return{resourceCategory:"sync",share:!0,depsRemote:!0,prefetchInterface:!1,...e}}function oi(e,t){return t.map(r=>{const n=ni.matchRemote(e,r.nameOrAlias);return ri.assert(n,`Unable to preload ${r.nameOrAlias} as it is not included in ${!n&&(0,Se.safeToString)({remoteInfo:n,remotes:e})}`),{remote:n,preloadConfig:Kr(r)}})}function si(e){return e?e.map(t=>t==="."?t:t.startsWith("./")?t.replace("./",""):t):[]}function ii(e,t,r,n=!0){const{cssAssets:o,jsAssetsWithoutEntry:s,entryAssets:i}=r;if(t.options.inBrowser){if(i.forEach(a=>{const{moduleInfo:c}=a,l=t.moduleCache.get(e.name);l?Ct.getRemoteEntry({origin:t,remoteInfo:c,remoteEntryExports:l.remoteEntryExports}):Ct.getRemoteEntry({origin:t,remoteInfo:c,remoteEntryExports:void 0})}),n){const a={rel:"preload",as:"style"};o.forEach(c=>{const{link:l,needAttach:u}=(0,Se.createLink)({url:c,cb:()=>{},attrs:a,createLinkHook:(d,f)=>{const h=t.loaderHook.lifecycle.createLink.emit({url:d,attrs:f});if(h instanceof HTMLLinkElement)return h}});u&&document.head.appendChild(l)})}else{const a={rel:"stylesheet",type:"text/css"};o.forEach(c=>{const{link:l,needAttach:u}=(0,Se.createLink)({url:c,cb:()=>{},attrs:a,createLinkHook:(d,f)=>{const h=t.loaderHook.lifecycle.createLink.emit({url:d,attrs:f});if(h instanceof HTMLLinkElement)return h},needDeleteLink:!1});u&&document.head.appendChild(l)})}if(n){const a={rel:"preload",as:"script"};s.forEach(c=>{const{link:l,needAttach:u}=(0,Se.createLink)({url:c,cb:()=>{},attrs:a,createLinkHook:(d,f)=>{const h=t.loaderHook.lifecycle.createLink.emit({url:d,attrs:f});if(h instanceof HTMLLinkElement)return h}});u&&document.head.appendChild(l)})}else{const a={fetchpriority:"high",type:(e==null?void 0:e.type)==="module"?"module":"text/javascript"};s.forEach(c=>{const{script:l,needAttach:u}=(0,Se.createScript)({url:c,cb:()=>{},attrs:a,createScriptHook:(d,f)=>{const h=t.loaderHook.lifecycle.createScript.emit({url:d,attrs:f});if(h instanceof HTMLScriptElement)return h},needDeleteScript:!0});u&&document.head.appendChild(l)})}}}Z.defaultPreloadArgs=Kr;Z.formatPreloadArgs=oi;Z.normalizePreloadExposes=si;Z.preloadAssets=ii;const F=b,qt=q,ai=he,li=K,ci=Z,ui={getRegisteredShare:qt.getRegisteredShare,getGlobalShareScope:qt.getGlobalShareScope},fi={Global:F.Global,nativeGlobal:F.nativeGlobal,resetFederationGlobalInfo:F.resetFederationGlobalInfo,setGlobalFederationInstance:F.setGlobalFederationInstance,getGlobalFederationConstructor:F.getGlobalFederationConstructor,setGlobalFederationConstructor:F.setGlobalFederationConstructor,getInfoWithoutType:F.getInfoWithoutType,getGlobalSnapshot:F.getGlobalSnapshot,getTargetSnapshotInfoByModuleInfo:F.getTargetSnapshotInfoByModuleInfo,getGlobalSnapshotInfoByModuleInfo:F.getGlobalSnapshotInfoByModuleInfo,setGlobalSnapshotInfoByModuleInfo:F.setGlobalSnapshotInfoByModuleInfo,addGlobalSnapshot:F.addGlobalSnapshot,getRemoteEntryExports:F.getRemoteEntryExports,registerGlobalPlugins:F.registerGlobalPlugins,getGlobalHostPlugins:F.getGlobalHostPlugins,getPreloaded:F.getPreloaded,setPreloaded:F.setPreloaded};var di={global:fi,share:ui,utils:{matchRemoteWithNameAndExpose:ai.matchRemoteWithNameAndExpose,preloadAssets:ci.preloadAssets,getRemoteInfo:li.getRemoteInfo}};xr.default=di;var Xe={};const Ze=P,Ut=N,hi=K,mi=ve;let _i=D,Gt=Y;function gi(e,t,r){const n=t,o=Array.isArray(e.shareScope)?e.shareScope:[e.shareScope];o.length||o.push("default"),o.forEach(i=>{n[i]||(n[i]={})});const s={version:e.version||"",shareScopeKeys:Array.isArray(e.shareScope)?o:e.shareScope||"default"};return Object.defineProperty(s,"shareScopeMap",{value:n,enumerable:!1}),{remoteEntryInitOptions:s,shareScope:n[o[0]],initScope:r??[]}}var pi=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;const e=await hi.getRemoteEntry({origin:this.host,remoteInfo:this.remoteInfo,remoteEntryExports:this.remoteEntryExports});return Ze.assert(e,`remoteEntryExports is undefined
|
|
7
|
+
${(0,_i.safeToString)(this.remoteInfo)}`),this.remoteEntryExports=e,this.remoteEntryExports}async init(e,t,r){const n=await this.getEntry();if(this.inited)return n;if(this.initPromise)return await this.initPromise,n;this.initing=!0,this.initPromise=(async()=>{const{remoteEntryInitOptions:o,shareScope:s,initScope:i}=gi(this.remoteInfo,this.host.shareScopeMap,r),a=await this.host.hooks.lifecycle.beforeInitContainer.emit({shareScope:s,remoteEntryInitOptions:o,initScope:i,remoteInfo:this.remoteInfo,origin:this.host});typeof(n==null?void 0:n.init)>"u"&&Ze.error(Gt.RUNTIME_002,Gt.runtimeDescMap,{hostName:this.host.name,remoteName:this.remoteInfo.name,remoteEntryUrl:this.remoteInfo.entry,remoteEntryKey:this.remoteInfo.entryGlobalName},void 0,mi.optionsToMFContext(this.host.options)),await n.init(a.shareScope,a.initScope,a.remoteEntryInitOptions),await this.host.hooks.lifecycle.initContainer.emit({...a,id:e,remoteSnapshot:t,remoteEntryExports:n}),this.inited=!0})();try{await this.initPromise}finally{this.initing=!1,this.initPromise=void 0}return n}async get(e,t,r,n){const{loadFactory:o=!0}=r||{loadFactory:!0},s=await this.init(e,n);this.lib=s;let i;i=await this.host.loaderHook.lifecycle.getModuleFactory.emit({remoteEntryExports:s,expose:t,moduleInfo:this.remoteInfo}),i||(i=await s.get(t)),Ze.assert(i,`${Ut.getFMId(this.remoteInfo)} remote don't export ${t}.`);const a=Ut.processModuleAlias(this.remoteInfo.name,t),c=this.wraperFactory(i,a);return o?await c():c}wraperFactory(e,t){function r(n,o){n&&typeof n=="object"&&Object.isExtensible(n)&&!Object.getOwnPropertyDescriptor(n,Symbol.for("mf_module_id"))&&Object.defineProperty(n,Symbol.for("mf_module_id"),{value:o,enumerable:!1})}return e instanceof Promise?async()=>{const n=await e();return r(n,t),n}:()=>{const n=e();return r(n,t),n}}};Xe.Module=pi;var Yr={},me={},Ei=class{constructor(e){this.type="",this.listeners=new Set,e&&(this.type=e)}on(e){typeof e=="function"&&this.listeners.add(e)}once(e){const t=this;this.on(function r(...n){return t.remove(r),e.apply(null,n)})}emit(...e){let t;return this.listeners.size>0&&this.listeners.forEach(r=>{t=r(...e)}),t}remove(e){this.listeners.delete(e)}removeAll(){this.listeners.clear()}};me.SyncHook=Ei;var Ae={};const yi=me;var Si=class extends yi.SyncHook{emit(...e){let t;const r=Array.from(this.listeners);if(r.length>0){let n=0;const o=s=>s===!1?!1:n<r.length?Promise.resolve(r[n++].apply(null,e)).then(o):s;t=o()}return Promise.resolve(t)}};Ae.AsyncHook=Si;var _e={};const Qe=P,zr=N,bi=me;function Jr(e,t){if(!zr.isObject(t))return!1;if(e!==t){for(const r in e)if(!(r in t))return!1}return!0}var Ri=class extends bi.SyncHook{constructor(e){super(),this.onerror=Qe.error,this.type=e}emit(e){zr.isObject(e)||Qe.error(`The data for the "${this.type}" hook should be an object.`);for(const t of this.listeners)try{const r=t(e);if(Jr(e,r))e=r;else{this.onerror(`A plugin returned an unacceptable value for the "${this.type}" type.`);break}}catch(r){Qe.warn(r),this.onerror(r)}return e}};_e.SyncWaterfallHook=Ri;_e.checkReturnData=Jr;var $e={};const et=P,Ti=N,Ii=me,Ni=_e;var Mi=class extends Ii.SyncHook{constructor(e){super(),this.onerror=et.error,this.type=e}emit(e){Ti.isObject(e)||et.error(`The response data for the "${this.type}" hook must be an object.`);const t=Array.from(this.listeners);if(t.length>0){let r=0;const n=s=>(et.warn(s),this.onerror(s),e),o=s=>{if(Ni.checkReturnData(e,s)){if(e=s,r<t.length)try{return Promise.resolve(t[r++](e)).then(o,n)}catch(i){return n(i)}}else this.onerror(`A plugin returned an incorrect value for the "${this.type}" type.`);return e};return Promise.resolve(o(e))}return Promise.resolve(e)}};$e.AsyncWaterfallHook=Mi;var ke={};const Fe=P,Pi=N;var vi=class{constructor(e){this.registerPlugins={},this.lifecycle=e,this.lifecycleKeys=Object.keys(e)}applyPlugin(e,t){var n;Fe.assert(Pi.isPlainObject(e),"Plugin configuration is invalid.");const r=e.name;Fe.assert(r,"A name must be provided by the plugin."),this.registerPlugins[r]||(this.registerPlugins[r]=e,(n=e.apply)==null||n.call(e,t),Object.keys(this.lifecycle).forEach(o=>{const s=e[o];s&&this.lifecycle[o].on(s)}))}removePlugin(e){Fe.assert(e,"A name is required.");const t=this.registerPlugins[e];Fe.assert(t,`The plugin "${e}" is not registered.`),Object.keys(t).forEach(r=>{r!=="name"&&this.lifecycle[r].remove(t[r])})}};ke.PluginSystem=vi;var xe={};const Ai=P,St=N,$i=Z;let Wt=D,Bt=Y;function Zr(e,t){const r=St.getRemoteEntryInfoFromSnapshot(t);r.url||Ai.error(Bt.RUNTIME_011,Bt.runtimeDescMap,{remoteName:e.name});let n=(0,Wt.getResourceUrl)(t,r.url);!Wt.isBrowserEnvValue&&!n.startsWith("http")&&(n=`https:${n}`),e.type=r.type,e.entryGlobalName=r.globalName,e.entry=n,e.version=t.version,e.buildVersion=t.buildVersion}function ki(){return{name:"snapshot-plugin",async afterResolve(e){const{remote:t,pkgNameOrAlias:r,expose:n,origin:o,remoteInfo:s,id:i}=e;if(!St.isRemoteInfoWithEntry(t)||!St.isPureRemoteEntry(t)){const{remoteSnapshot:a,globalSnapshot:c}=await o.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:t,id:i});Zr(s,a);const l={remote:t,preloadConfig:{nameOrAlias:r,exposes:[n],resourceCategory:"sync",share:!1,depsRemote:!1}},u=await o.remoteHandler.hooks.lifecycle.generatePreloadAssets.emit({origin:o,preloadOptions:l,remoteInfo:s,remote:t,remoteSnapshot:a,globalSnapshot:c});return u&&$i.preloadAssets(s,o,u,!1),{...e,remoteSnapshot:a}}return e}}}xe.assignRemoteInfo=Zr;xe.snapshotPlugin=ki;var Qr={};const Me=N,bt=b,Oi=q,Vt=Z,Fi=xe;let Ve=D;function wi(e){const 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 en(e,t,r,n,o={},s){const{value:i}=bt.getInfoWithoutType(e,Me.getFMId(t)),a=s||i;if(a&&!(0,Ve.isManifestProvider)(a)&&(r(a,t,n),a.remotesInfo)){const c=Object.keys(a.remotesInfo);for(const l of c){if(o[l])continue;o[l]=!0;const u=wi(l),d=a.remotesInfo[l];en(e,{name:u.name,version:d.matchedVersion},r,!1,o,void 0)}}}const tt=(e,t)=>document.querySelector(`${e}[${e==="link"?"href":"src"}="${t}"]`);function Li(e,t,r,n,o){const s=[],i=[],a=[],c=new Set,l=new Set,{options:u}=e,{preloadConfig:d}=t,{depsRemote:f}=d;if(en(n,r,(m,_,g)=>{var M;let p;if(g)p=d;else if(Array.isArray(f)){const R=f.find(A=>A.nameOrAlias===_.name||A.nameOrAlias===_.alias);if(!R)return;p=Vt.defaultPreloadArgs(R)}else if(f===!0)p=d;else return;const y=(0,Ve.getResourceUrl)(m,Me.getRemoteEntryInfoFromSnapshot(m).url);y&&a.push({name:_.name,moduleInfo:{name:_.name,entry:y,type:"remoteEntryType"in m?m.remoteEntryType:"global",entryGlobalName:"globalName"in m?m.globalName:_.name,shareScope:"",version:"version"in m?m.version:void 0},url:y});let I="modules"in m?m.modules:[];const O=Vt.normalizePreloadExposes(p.exposes);O.length&&"modules"in m&&(I=(M=m==null?void 0:m.modules)==null?void 0:M.reduce((R,A)=>((O==null?void 0:O.indexOf(A.moduleName))!==-1&&R.push(A),R),[]));function E(R){const A=R.map(B=>(0,Ve.getResourceUrl)(m,B));return p.filter?A.filter(p.filter):A}if(I){const R=I.length;for(let A=0;A<R;A++){const B=I[A],Ye=`${_.name}/${B.moduleName}`;e.remoteHandler.hooks.lifecycle.handlePreloadModule.emit({id:B.moduleName==="."?_.name:Ye,name:_.name,remoteSnapshot:m,preloadConfig:p,remote:_,origin:e}),!bt.getPreloaded(Ye)&&(p.resourceCategory==="all"?(s.push(...E(B.assets.css.async)),s.push(...E(B.assets.css.sync)),i.push(...E(B.assets.js.async)),i.push(...E(B.assets.js.sync))):p.resourceCategory==="sync"&&(s.push(...E(B.assets.css.sync)),i.push(...E(B.assets.js.sync))),bt.setPreloaded(Ye))}}},!0,{},o),o.shared&&o.shared.length>0){const m=(_,g)=>{const{shared:p}=Oi.getRegisteredShare(e.shareScopeMap,g.sharedName,_,e.sharedHandler.hooks.lifecycle.resolveShare)||{};p&&typeof p.lib=="function"&&(g.assets.js.sync.forEach(y=>{c.add(y)}),g.assets.css.sync.forEach(y=>{l.add(y)}))};o.shared.forEach(_=>{var y;const g=(y=u.shared)==null?void 0:y[_.sharedName];if(!g)return;const p=_.version?g.find(I=>I.version===_.version):g;p&&Me.arrayOptions(p).forEach(I=>{m(I,_)})})}const h=i.filter(m=>!c.has(m)&&!tt("script",m));return{cssAssets:s.filter(m=>!l.has(m)&&!tt("link",m)),jsAssetsWithoutEntry:h,entryAssets:a.filter(m=>!tt("script",m.url))}}const Di=function(){return{name:"generate-preload-assets-plugin",async generatePreloadAssets(e){const{origin:t,preloadOptions:r,remoteInfo:n,remote:o,globalSnapshot:s,remoteSnapshot:i}=e;return Ve.isBrowserEnvValue?Me.isRemoteInfoWithEntry(o)&&Me.isPureRemoteEntry(o)?{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[{name:o.name,url:o.entry,moduleInfo:{name:n.name,entry:o.entry,type:n.type||"global",entryGlobalName:"",shareScope:""}}]}:(Fi.assignRemoteInfo(n,i),Li(t,r,n,s,i)):{cssAssets:[],jsAssetsWithoutEntry:[],entryAssets:[]}}}};Qr.generatePreloadAssetsPlugin=Di;var Ke={};const rt=P,Hi=N,G=b,jt=ve,Ci=Ae,nt=$e,qi=ke;let ot=D,we=Y;function tn(e,t){const r=G.getGlobalSnapshotInfoByModuleInfo({name:t.name,version:t.options.version}),n=r&&"remotesInfo"in r&&r.remotesInfo&&G.getInfoWithoutType(r.remotesInfo,e.name).value;return n&&n.matchedVersion?{hostGlobalSnapshot:r,globalSnapshot:G.getGlobalSnapshot(),remoteSnapshot:G.getGlobalSnapshotInfoByModuleInfo({name:e.name,version:n.matchedVersion})}:{hostGlobalSnapshot:void 0,globalSnapshot:G.getGlobalSnapshot(),remoteSnapshot:G.getGlobalSnapshotInfoByModuleInfo({name:e.name,version:"version"in e?e.version:void 0})}}var Ui=class{constructor(e){this.loadingHostSnapshot=null,this.manifestCache=new Map,this.hooks=new qi.PluginSystem({beforeLoadRemoteSnapshot:new Ci.AsyncHook("beforeLoadRemoteSnapshot"),loadSnapshot:new nt.AsyncWaterfallHook("loadGlobalSnapshot"),loadRemoteSnapshot:new nt.AsyncWaterfallHook("loadRemoteSnapshot"),afterLoadSnapshot:new nt.AsyncWaterfallHook("afterLoadSnapshot")}),this.manifestLoading=G.Global.__FEDERATION__.__MANIFEST_LOADING__,this.HostInstance=e,this.loaderHook=e.loaderHook}async loadRemoteSnapshotInfo({moduleInfo:e,id:t,expose:r}){const{options:n}=this.HostInstance;await this.hooks.lifecycle.beforeLoadRemoteSnapshot.emit({options:n,moduleInfo:e});let o=G.getGlobalSnapshotInfoByModuleInfo({name:this.HostInstance.options.name,version:this.HostInstance.options.version});o||(o={version:this.HostInstance.options.version||"",remoteEntry:"",remotesInfo:{}},G.addGlobalSnapshot({[this.HostInstance.options.name]:o})),o&&"remotesInfo"in o&&!G.getInfoWithoutType(o.remotesInfo,e.name).value&&("version"in e||"entry"in e)&&(o.remotesInfo={...o==null?void 0:o.remotesInfo,[e.name]:{matchedVersion:"version"in e?e.version:e.entry}});const{hostGlobalSnapshot:s,remoteSnapshot:i,globalSnapshot:a}=this.getGlobalRemoteInfo(e),{remoteSnapshot:c,globalSnapshot:l}=await this.hooks.lifecycle.loadSnapshot.emit({options:n,moduleInfo:e,hostGlobalSnapshot:s,remoteSnapshot:i,globalSnapshot:a});let u,d;if(c)if((0,ot.isManifestProvider)(c)){const f=ot.isBrowserEnvValue?c.remoteEntry:c.ssrRemoteEntry||c.remoteEntry||"",h=await this.getManifestJson(f,e,{}),m=G.setGlobalSnapshotInfoByModuleInfo({...e,entry:f},h);u=h,d=m}else{const{remoteSnapshot:f}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:c,from:"global"});u=f,d=l}else if(Hi.isRemoteInfoWithEntry(e)){const f=await this.getManifestJson(e.entry,e,{}),h=G.setGlobalSnapshotInfoByModuleInfo(e,f),{remoteSnapshot:m}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:e,remoteSnapshot:f,from:"global"});u=m,d=h}else rt.error(we.RUNTIME_007,we.runtimeDescMap,{remoteName:e.name,remoteVersion:e.version,hostName:this.HostInstance.options.name,globalSnapshot:JSON.stringify(l)},void 0,jt.optionsToMFContext(this.HostInstance.options));return await this.hooks.lifecycle.afterLoadSnapshot.emit({id:t,host:this.HostInstance,options:n,moduleInfo:e,remoteSnapshot:u}),{remoteSnapshot:u,globalSnapshot:d}}getGlobalRemoteInfo(e){return tn(e,this.HostInstance)}async getManifestJson(e,t,r){const n=async()=>{let s=this.manifestCache.get(e);if(s)return s;try{let i=await this.loaderHook.lifecycle.fetch.emit(e,{});(!i||!(i instanceof Response))&&(i=await fetch(e,{})),s=await i.json()}catch(i){s=await this.HostInstance.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:e,error:i,from:"runtime",lifecycle:"afterResolve",origin:this.HostInstance}),s||(delete this.manifestLoading[e],rt.error(we.RUNTIME_003,we.runtimeDescMap,{manifestUrl:e,moduleName:t.name,hostName:this.HostInstance.options.name},`${i}`,jt.optionsToMFContext(this.HostInstance.options)))}return rt.assert(s.metaData&&s.exposes&&s.shared,`"${e}" is not a valid federation manifest for remote "${t.name}". Missing required fields: ${[!s.metaData&&"metaData",!s.exposes&&"exposes",!s.shared&&"shared"].filter(Boolean).join(", ")}.`),this.manifestCache.set(e,s),s},o=async()=>{const s=await n(),i=(0,ot.generateSnapshotFromManifest)(s,{version:e}),{remoteSnapshot:a}=await this.hooks.lifecycle.loadRemoteSnapshot.emit({options:this.HostInstance.options,moduleInfo:t,manifestJson:s,remoteSnapshot:i,manifestUrl:e,from:"manifest"});return a};return this.manifestLoading[e]||(this.manifestLoading[e]=o().then(s=>s)),this.manifestLoading[e]}};Ke.SnapshotHandler=Ui;Ke.getGlobalRemoteInfo=tn;var rn={};const st=P,Gi=oe,$=q,Xt=ve,Wi=Ae,it=_e,xt=$e,Bi=ke;let pe=Y;var Vi=class{constructor(e){this.hooks=new Bi.PluginSystem({beforeRegisterShare:new it.SyncWaterfallHook("beforeRegisterShare"),afterResolve:new xt.AsyncWaterfallHook("afterResolve"),beforeLoadShare:new xt.AsyncWaterfallHook("beforeLoadShare"),loadShare:new Wi.AsyncHook,resolveShare:new it.SyncWaterfallHook("resolveShare"),initContainerShareScopeMap:new it.SyncWaterfallHook("initContainerShareScopeMap")}),this.host=e,this.shareScopeMap={},this.initTokens={},this._setGlobalShareScopeMap(e.options)}registerShared(e,t){const{newShareInfos:r,allShareInfos:n}=$.formatShareConfigs(e,t);return Object.keys(r).forEach(o=>{r[o].forEach(s=>{s.scope.forEach(i=>{var a;this.hooks.lifecycle.beforeRegisterShare.emit({origin:this.host,pkgName:o,shared:s}),(a=this.shareScopeMap[i])!=null&&a[o]||this.setShared({pkgName:o,lib:s.lib,get:s.get,loaded:s.loaded||!!s.lib,shared:s,from:t.name})})})}),{newShareInfos:r,allShareInfos:n}}async loadShare(e,t){const{host:r}=this,n=$.getTargetSharedOptions({pkgName:e,extraOptions:t,shareInfos:r.options.shared});n!=null&&n.scope&&await Promise.all(n.scope.map(async a=>{await Promise.all(this.initializeSharing(a,{strategy:n.strategy}))}));const{shareInfo:o}=await this.hooks.lifecycle.beforeLoadShare.emit({pkgName:e,shareInfo:n,shared:r.options.shared,origin:r});st.assert(o,`Cannot find shared "${e}" in host "${r.options.name}". Ensure the shared config for "${e}" is declared in the federation plugin options and the host has been initialized before loading shares.`);const{shared:s,useTreesShaking:i}=$.getRegisteredShare(this.shareScopeMap,e,o,this.hooks.lifecycle.resolveShare)||{};if(s){const a=$.directShare(s,i);if(a.lib)return $.addUseIn(a,r.options.name),a.lib;if(a.loading&&!a.loaded){const c=await a.loading;return a.loaded=!0,a.lib||(a.lib=c),$.addUseIn(a,r.options.name),c}else{const l=(async()=>{const u=await a.get();return $.addUseIn(a,r.options.name),a.loaded=!0,a.lib=u,u})();return this.setShared({pkgName:e,loaded:!1,shared:s,from:r.options.name,lib:null,loading:l,treeShaking:i?a:void 0}),l}}else{if(t!=null&&t.customShareInfo)return!1;const a=$.shouldUseTreeShaking(o.treeShaking),c=$.directShare(o,a),u=(async()=>{const d=await c.get();c.lib=d,c.loaded=!0,$.addUseIn(c,r.options.name);const{shared:f,useTreesShaking:h}=$.getRegisteredShare(this.shareScopeMap,e,o,this.hooks.lifecycle.resolveShare)||{};if(f){const m=$.directShare(f,h);m.lib=d,m.loaded=!0,f.from=o.from}return d})();return this.setShared({pkgName:e,loaded:!1,shared:o,from:r.options.name,lib:null,loading:u,treeShaking:a?c:void 0}),u}}initializeSharing(e=Gi.DEFAULT_SCOPE,t){const{host:r}=this,n=t==null?void 0:t.from,o=t==null?void 0:t.strategy;let s=t==null?void 0:t.initScope;const i=[];if(n!=="build"){const{initTokens:f}=this;s||(s=[]);let h=f[e];if(h||(h=f[e]={from:this.host.name}),s.indexOf(h)>=0)return i;s.push(h)}const a=this.shareScopeMap,c=r.options.name;a[e]||(a[e]={});const l=a[e],u=(f,h)=>{var I;const{version:m,eager:_}=h;l[f]=l[f]||{};const g=l[f],p=g[m]&&$.directShare(g[m]),y=!!(p&&("eager"in p&&p.eager||"shareConfig"in p&&((I=p.shareConfig)!=null&&I.eager)));(!p||p.strategy!=="loaded-first"&&!p.loaded&&(!_!=!y?_:c>g[m].from))&&(g[m]=h)},d=async f=>{const{module:h}=await r.remoteHandler.getRemoteModuleAndOptions({id:f});let m;try{m=await h.getEntry()}catch(_){if(m=await r.remoteHandler.hooks.lifecycle.errorLoadRemote.emit({id:f,error:_,from:"runtime",lifecycle:"beforeLoadShare",origin:r}),!m)return}finally{m!=null&&m.init&&!h.initing&&(h.remoteEntryExports=m,await h.init(void 0,void 0,s))}};return Object.keys(r.options.shared).forEach(f=>{r.options.shared[f].forEach(h=>{h.scope.includes(e)&&u(f,h)})}),(r.options.shareStrategy==="version-first"||o==="version-first")&&r.options.remotes.forEach(f=>{f.shareScope===e&&i.push(d(f.name))}),i}loadShareSync(e,t){const{host:r}=this,n=$.getTargetSharedOptions({pkgName:e,extraOptions:t,shareInfos:r.options.shared});n!=null&&n.scope&&n.scope.forEach(i=>{this.initializeSharing(i,{strategy:n.strategy})});const{shared:o,useTreesShaking:s}=$.getRegisteredShare(this.shareScopeMap,e,n,this.hooks.lifecycle.resolveShare)||{};if(o){if(typeof o.lib=="function")return $.addUseIn(o,r.options.name),o.loaded||(o.loaded=!0,o.from===r.options.name&&(n.loaded=!0)),o.lib;if(typeof o.get=="function"){const i=o.get();if(!(i instanceof Promise))return $.addUseIn(o,r.options.name),this.setShared({pkgName:e,loaded:!0,from:r.options.name,lib:i,shared:o}),i}}if(n.lib)return n.loaded||(n.loaded=!0),n.lib;if(n.get){const i=n.get();return i instanceof Promise&&st.error((t==null?void 0:t.from)==="build"?pe.RUNTIME_005:pe.RUNTIME_006,pe.runtimeDescMap,{hostName:r.options.name,sharedPkgName:e},void 0,Xt.optionsToMFContext(r.options)),n.lib=i,this.setShared({pkgName:e,loaded:!0,from:r.options.name,lib:n.lib,shared:n}),n.lib}st.error(pe.RUNTIME_006,pe.runtimeDescMap,{hostName:r.options.name,sharedPkgName:e},void 0,Xt.optionsToMFContext(r.options))}initShareScopeMap(e,t,r={}){const{host:n}=this;this.shareScopeMap[e]=t,this.hooks.lifecycle.initContainerShareScopeMap.emit({shareScope:t,options:n.options,origin:n,scopeName:e,hostShareScopeMap:r.hostShareScopeMap})}setShared({pkgName:e,shared:t,from:r,lib:n,loading:o,loaded:s,get:i,treeShaking:a}){const{version:c,scope:l="default",...u}=t,d=Array.isArray(l)?l:[l],f=h=>{const m=(g,p,y)=>{y&&!g[p]&&(g[p]=y)},_=a?h.treeShaking:h;m(_,"loaded",s),m(_,"loading",o),m(_,"get",i)};d.forEach(h=>{this.shareScopeMap[h]||(this.shareScopeMap[h]={}),this.shareScopeMap[h][e]||(this.shareScopeMap[h][e]={}),this.shareScopeMap[h][e][c]||(this.shareScopeMap[h][e][c]={version:c,scope:[h],...u,lib:n});const m=this.shareScopeMap[h][e][c];f(m),r&&m.from!==r&&(m.from=r)})}_setGlobalShareScopeMap(e){const t=$.getGlobalShareScope(),r=e.id||e.name;r&&!t[r]&&(t[r]=this.shareScopeMap)}};rn.SharedHandler=Vi;var nn={};const Le=P,U=b,Kt=oe,ji=q,Xi=he,at=K,xi=ve,Yt=Z,Ki=Xe,Yi=me,ie=Ae,zt=_e,zi=$e,Ji=ke,Zi=Ke;let lt=D,Jt=Y;var Qi=class{constructor(e){this.hooks=new Ji.PluginSystem({beforeRegisterRemote:new zt.SyncWaterfallHook("beforeRegisterRemote"),registerRemote:new zt.SyncWaterfallHook("registerRemote"),beforeRequest:new zi.AsyncWaterfallHook("beforeRequest"),onLoad:new ie.AsyncHook("onLoad"),handlePreloadModule:new Yi.SyncHook("handlePreloadModule"),errorLoadRemote:new ie.AsyncHook("errorLoadRemote"),beforePreloadRemote:new ie.AsyncHook("beforePreloadRemote"),generatePreloadAssets:new ie.AsyncHook("generatePreloadAssets"),afterPreloadRemote:new ie.AsyncHook,loadEntry:new ie.AsyncHook}),this.host=e,this.idToRemoteMap={}}formatAndRegisterRemote(e,t){return(t.remotes||[]).reduce((r,n)=>(this.registerRemote(n,r,{force:!1}),r),e.remotes)}setIdToRemoteMap(e,t){const{remote:r,expose:n}=t,{name:o,alias:s}=r;if(this.idToRemoteMap[e]={name:r.name,expose:n},s&&e.startsWith(o)){const i=e.replace(o,s);this.idToRemoteMap[i]={name:r.name,expose:n};return}if(s&&e.startsWith(s)){const i=e.replace(s,o);this.idToRemoteMap[i]={name:r.name,expose:n}}}async loadRemote(e,t){const{host:r}=this;try{const{loadFactory:n=!0}=t||{loadFactory:!0},{module:o,moduleOptions:s,remoteMatchInfo:i}=await this.getRemoteModuleAndOptions({id:e}),{pkgNameOrAlias:a,remote:c,expose:l,id:u,remoteSnapshot:d}=i,f=await o.get(u,l,t,d),h=await this.hooks.lifecycle.onLoad.emit({id:u,pkgNameOrAlias:a,expose:l,exposeModule:n?f:void 0,exposeModuleFactory:n?void 0:f,remote:c,options:s,moduleInstance:o,origin:r});return this.setIdToRemoteMap(e,i),typeof h=="function"?h:f}catch(n){const{from:o="runtime"}=t||{from:"runtime"},s=await this.hooks.lifecycle.errorLoadRemote.emit({id:e,error:n,from:o,lifecycle:"onLoad",origin:r});if(!s)throw n;return s}}async preloadRemote(e){const{host:t}=this;await this.hooks.lifecycle.beforePreloadRemote.emit({preloadOps:e,options:t.options,origin:t});const r=Yt.formatPreloadArgs(t.options.remotes,e);await Promise.all(r.map(async n=>{const{remote:o}=n,s=at.getRemoteInfo(o),{globalSnapshot:i,remoteSnapshot:a}=await t.snapshotHandler.loadRemoteSnapshotInfo({moduleInfo:o}),c=await this.hooks.lifecycle.generatePreloadAssets.emit({origin:t,preloadOptions:n,remote:o,remoteInfo:s,globalSnapshot:i,remoteSnapshot:a});c&&Yt.preloadAssets(s,t,c)}))}registerRemotes(e,t){const{host:r}=this;e.forEach(n=>{this.registerRemote(n,r.options.remotes,{force:t==null?void 0:t.force})})}async getRemoteModuleAndOptions(e){const{host:t}=this,{id:r}=e;let n;try{n=await this.hooks.lifecycle.beforeRequest.emit({id:r,options:t.options,origin:t})}catch(h){if(n=await this.hooks.lifecycle.errorLoadRemote.emit({id:r,options:t.options,origin:t,from:"runtime",error:h,lifecycle:"beforeRequest"}),!n)throw h}const{id:o}=n,s=Xi.matchRemoteWithNameAndExpose(t.options.remotes,o);s||Le.error(Jt.RUNTIME_004,Jt.runtimeDescMap,{hostName:t.options.name,requestId:o},void 0,xi.optionsToMFContext(t.options));const{remote:i}=s,a=at.getRemoteInfo(i),c=await t.sharedHandler.hooks.lifecycle.afterResolve.emit({id:o,...s,options:t.options,origin:t,remoteInfo:a}),{remote:l,expose:u}=c;Le.assert(l&&u,`The 'beforeRequest' hook was executed, but it failed to return the correct 'remote' and 'expose' values while loading ${o}.`);let d=t.moduleCache.get(l.name);const f={host:t,remoteInfo:a};return d||(d=new Ki.Module(f),t.moduleCache.set(l.name,d)),{module:d,moduleOptions:f,remoteMatchInfo:c}}registerRemote(e,t,r){const{host:n}=this,o=()=>{if(e.alias){const i=t.find(a=>{var c;return e.alias&&(a.name.startsWith(e.alias)||((c=a.alias)==null?void 0:c.startsWith(e.alias)))});Le.assert(!i,`The alias ${e.alias} of remote ${e.name} is not allowed to be the prefix of ${i&&i.name} name or alias`)}"entry"in e&<.isBrowserEnvValue&&typeof window<"u"&&!e.entry.startsWith("http")&&(e.entry=new URL(e.entry,window.location.origin).href),e.shareScope||(e.shareScope=Kt.DEFAULT_SCOPE),e.type||(e.type=Kt.DEFAULT_REMOTE_TYPE)};this.hooks.lifecycle.beforeRegisterRemote.emit({remote:e,origin:n});const s=t.find(i=>i.name===e.name);if(!s)o(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:n});else{const i=[`The remote "${e.name}" is already registered.`,"Please note that overriding it may cause unexpected errors."];r!=null&&r.force&&(this.removeRemote(s),o(),t.push(e),this.hooks.lifecycle.registerRemote.emit({remote:e,origin:n}),(0,lt.warn)(i.join(" ")))}}removeRemote(e){var t;try{const{host:r}=this,{name:n}=e,o=r.options.remotes.findIndex(i=>i.name===n);o!==-1&&r.options.remotes.splice(o,1);const s=r.moduleCache.get(e.name);if(s){const i=s.remoteInfo,a=i.entryGlobalName;U.CurrentGlobal[a]&&((t=Object.getOwnPropertyDescriptor(U.CurrentGlobal,a))!=null&&t.configurable?delete U.CurrentGlobal[a]:U.CurrentGlobal[a]=void 0);const c=at.getRemoteEntryUniqueKey(s.remoteInfo);U.globalLoading[c]&&delete U.globalLoading[c],r.snapshotHandler.manifestCache.delete(i.entry);let l=i.buildVersion?(0,lt.composeKeyWithSeparator)(i.name,i.buildVersion):i.name;const u=U.CurrentGlobal.__FEDERATION__.__INSTANCES__.findIndex(f=>i.buildVersion?f.options.id===l:f.name===l);if(u!==-1){const f=U.CurrentGlobal.__FEDERATION__.__INSTANCES__[u];l=f.options.id||l;const h=ji.getGlobalShareScope();let m=!0;const _=[];Object.keys(h).forEach(g=>{const p=h[g];p&&Object.keys(p).forEach(y=>{const I=p[y];I&&Object.keys(I).forEach(O=>{const E=I[O];E&&Object.keys(E).forEach(M=>{const R=E[M];R&&typeof R=="object"&&R.from===i.name&&(R.loaded||R.loading?(R.useIn=R.useIn.filter(A=>A!==i.name),R.useIn.length?m=!1:_.push([g,y,O,M])):_.push([g,y,O,M]))})})})}),m&&(f.shareScopeMap={},delete h[l]),_.forEach(([g,p,y,I])=>{var O,E,M;(M=(E=(O=h[g])==null?void 0:O[p])==null?void 0:E[y])==null||delete M[I]}),U.CurrentGlobal.__FEDERATION__.__INSTANCES__.splice(u,1)}const{hostGlobalSnapshot:d}=Zi.getGlobalRemoteInfo(e,r);if(d){const f=d&&"remotesInfo"in d&&d.remotesInfo&&U.getInfoWithoutType(d.remotesInfo,e.name).key;f&&(delete d.remotesInfo[f],U.Global.__FEDERATION__.__MANIFEST_LOADING__[f]&&delete U.Global.__FEDERATION__.__MANIFEST_LOADING__[f])}r.moduleCache.delete(e.name)}}catch(r){Le.logger.error(`removeRemote failed: ${r instanceof Error?r.message:String(r)}`)}}};nn.RemoteHandler=Qi;const ea=P,ta=oe,ra=q,na=jr,oa=Xr,sa=K,ia=Xe,z=me,ct=Ae,aa=_e,Zt=$e,ut=ke,la=xe,ca=Qr,ua=Ke,fa=rn,da=nn;let ha=D,ft=Y;const ma=typeof FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN=="boolean"?!FEDERATION_OPTIMIZE_NO_SNAPSHOT_PLUGIN:!0;var _a=class{constructor(e){this.hooks=new ut.PluginSystem({beforeInit:new aa.SyncWaterfallHook("beforeInit"),init:new z.SyncHook,beforeInitContainer:new Zt.AsyncWaterfallHook("beforeInitContainer"),initContainer:new Zt.AsyncWaterfallHook("initContainer")}),this.version="2.3.1",this.moduleCache=new Map,this.loaderHook=new ut.PluginSystem({getModuleInfo:new z.SyncHook,createScript:new z.SyncHook,createLink:new z.SyncHook,fetch:new ct.AsyncHook,loadEntryError:new ct.AsyncHook,getModuleFactory:new ct.AsyncHook}),this.bridgeHook=new ut.PluginSystem({beforeBridgeRender:new z.SyncHook,afterBridgeRender:new z.SyncHook,beforeBridgeDestroy:new z.SyncHook,afterBridgeDestroy:new z.SyncHook});const t=ma?[la.snapshotPlugin(),ca.generatePreloadAssetsPlugin()]:[],r={id:na.getBuilderId(),name:e.name,plugins:t,remotes:[],shared:{},inBrowser:ha.isBrowserEnvValue};this.name=e.name,this.options=r,this.snapshotHandler=new ua.SnapshotHandler(this),this.sharedHandler=new fa.SharedHandler(this),this.remoteHandler=new da.RemoteHandler(this),this.shareScopeMap=this.sharedHandler.shareScopeMap,this.registerPlugins([...r.plugins,...e.plugins||[]]),this.options=this.formatOptions(r,e)}initOptions(e){e.name&&e.name!==this.options.name&&ea.error((0,ft.getShortErrorMsg)(ft.RUNTIME_010,ft.runtimeDescMap)),this.registerPlugins(e.plugins);const 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=ta.DEFAULT_SCOPE,t){return this.sharedHandler.initializeSharing(e,t)}initRawContainer(e,t,r){const n=sa.getRemoteInfo({name:e,entry:t}),o=new ia.Module({host:this,remoteInfo:n});return o.remoteEntryExports=r,this.moduleCache.set(e,o),o}async loadRemote(e,t){return this.remoteHandler.loadRemote(e,t)}async preloadRemote(e){return this.remoteHandler.preloadRemote(e)}initShareScopeMap(e,t,r={}){this.sharedHandler.initShareScopeMap(e,t,r)}formatOptions(e,t){const{allShareInfos:r}=ra.formatShareConfigs(e,t),{userOptions:n,options:o}=this.hooks.lifecycle.beforeInit.emit({origin:this,userOptions:t,options:e,shareInfo:r}),s=this.remoteHandler.formatAndRegisterRemote(o,n),{allShareInfos:i}=this.sharedHandler.registerShared(o,n),a=[...o.plugins];n.plugins&&n.plugins.forEach(l=>{a.includes(l)||a.push(l)});const c={...e,...t,plugins:a,remotes:s,shared:i};return this.hooks.lifecycle.init.emit({origin:this,options:c}),c}registerPlugins(e){const t=oa.registerPlugins(e,this);this.options.plugins=this.options.plugins.reduce((r,n)=>(n&&r&&!r.find(o=>o.name===n.name)&&r.push(n),r),t||[])}registerRemotes(e,t){return this.remoteHandler.registerRemotes(e,t)}registerShared(e){this.sharedHandler.registerShared(this.options,{...this.options,shared:e})}};Yr.ModuleFederation=_a;var on={},sn={},Qt=Object.defineProperty,ga=(e,t)=>{let r={};for(var n in e)Qt(r,n,{get:e[n],enumerable:!0});return t||Qt(r,Symbol.toStringTag,{value:"Module"}),r};sn.__exportAll=ga;(function(e){var r=sn.__exportAll({});Object.defineProperty(e,"type_exports",{enumerable:!0,get:function(){return r}})})(on);(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=P,r=N,n=b,o=vt,s=q,i=he,a=K,c=xr,l=Xe,u=Yr,d=on;let f=D;const h=c.default;e.CurrentGlobal=n.CurrentGlobal,e.Global=n.Global,e.Module=l.Module,e.ModuleFederation=u.ModuleFederation,e.addGlobalSnapshot=n.addGlobalSnapshot,e.assert=t.assert,e.error=t.error,e.getGlobalFederationConstructor=n.getGlobalFederationConstructor,e.getGlobalSnapshot=n.getGlobalSnapshot,e.getInfoWithoutType=n.getInfoWithoutType,e.getRegisteredShare=s.getRegisteredShare,e.getRemoteEntry=a.getRemoteEntry,e.getRemoteInfo=a.getRemoteInfo,e.helpers=h,e.isStaticResourcesEqual=r.isStaticResourcesEqual,Object.defineProperty(e,"loadScript",{enumerable:!0,get:function(){return f.loadScript}}),Object.defineProperty(e,"loadScriptNode",{enumerable:!0,get:function(){return f.loadScriptNode}}),e.matchRemoteWithNameAndExpose=i.matchRemoteWithNameAndExpose,e.registerGlobalPlugins=n.registerGlobalPlugins,e.resetFederationGlobalInfo=n.resetFederationGlobalInfo,e.safeWrapper=r.safeWrapper,e.satisfy=o.satisfy,e.setGlobalFederationConstructor=n.setGlobalFederationConstructor,e.setGlobalFederationInstance=n.setGlobalFederationInstance,Object.defineProperty(e,"types",{enumerable:!0,get:function(){return d.type_exports}})})(Tt);let pa=Tt;function Ea(){return typeof FEDERATION_BUILD_IDENTIFIER<"u"?FEDERATION_BUILD_IDENTIFIER:""}function ya(e,t){const r=Ea();return pa.CurrentGlobal.__FEDERATION__.__INSTANCES__.find(n=>!!(r&&n.options.id===r||n.options.name===e&&!n.options.version&&!t||n.options.name===e&&t&&n.options.version===t))}ar.getGlobalFederationInstance=ya;(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=ar;let r=Tt,n=Y;function o(_){const g=new((0,r.getGlobalFederationConstructor)()||r.ModuleFederation)(_);return(0,r.setGlobalFederationInstance)(g),g}let s=null;function i(_){const g=t.getGlobalFederationInstance(_.name,_.version);return g?(g.initOptions(_),s||(s=g),g):(s=o(_),s)}function a(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.loadRemote.apply(s,_)}function c(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.loadShare.apply(s,_)}function l(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.loadShareSync.apply(s,_)}function u(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.preloadRemote.apply(s,_)}function d(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.registerRemotes.apply(s,_)}function f(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.registerPlugins.apply(s,_)}function h(){return s}function m(..._){return(0,r.assert)(s,n.RUNTIME_009,n.runtimeDescMap),s.registerShared.apply(s,_)}(0,r.setGlobalFederationConstructor)(r.ModuleFederation),Object.defineProperty(e,"Module",{enumerable:!0,get:function(){return r.Module}}),e.ModuleFederation=r.ModuleFederation,e.createInstance=o,e.getInstance=h,Object.defineProperty(e,"getRemoteEntry",{enumerable:!0,get:function(){return r.getRemoteEntry}}),Object.defineProperty(e,"getRemoteInfo",{enumerable:!0,get:function(){return r.getRemoteInfo}}),e.init=i,e.loadRemote=a,Object.defineProperty(e,"loadScript",{enumerable:!0,get:function(){return r.loadScript}}),Object.defineProperty(e,"loadScriptNode",{enumerable:!0,get:function(){return r.loadScriptNode}}),e.loadShare=c,e.loadShareSync=l,e.preloadRemote=u,Object.defineProperty(e,"registerGlobalPlugins",{enumerable:!0,get:function(){return r.registerGlobalPlugins}}),e.registerPlugins=f,e.registerRemotes=d,e.registerShared=m})(ir);typeof __VUE_HMR_RUNTIME__>"u"&&(globalThis.__VUE_HMR_RUNTIME__={createRecord(){},rerender(){},reload(){}});const an="__mf_init____mf__virtual/ActionVisu__mf_v__runtimeInit__mf_v__.js__";let Rt=globalThis[an];if(!Rt){let e,t;const r=new Promise((n,o)=>{e=n,t=o});Rt=globalThis[an]={initPromise:r,initResolve:e,initReject:t},typeof window>"u"&&e({loadRemote:function(){return Promise.resolve(void 0)},loadShare:function(){return Promise.resolve(void 0)}})}const Sa=Rt.initResolve,er={},tr="default",rr="ActionVisu";let nr,or;async function ba(){return nr??=import("./assets/localSharedImportMap-CNn4MUou.js"),nr}async function Ra(){return or??=import("./assets/virtualExposes-B2aPQUg7.js").then(e=>e.default??e),or}async function Ia(e={},t=[]){const{usedShared:r,usedRemotes:n}=await ba(),o=ir.init({name:rr,remotes:n,shared:r,plugins:[],shareStrategy:"version-first"});var s=er[tr];if(s||(s=er[tr]={from:rr}),!(t.indexOf(s)>=0)){t.push(s),o.initShareScopeMap("default",e),Sa(o);try{await Promise.all(await o.initializeSharing("default",{strategy:"version-first",from:"build",initScope:t}))}catch(i){console.error("[Module Federation]",i)}return o}}async function Na(e){const t=await Ra();if(!(e in t))throw new Error(`[Module Federation] Module ${e} does not exist in container.`);return t[e]().then(r=>()=>r)}export{Na as get,Ia as init};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"id":"ActionVisu","name":"ActionVisu","metaData":{"name":"ActionVisu","type":"app","buildInfo":{"buildVersion":"1.0.0","buildName":"ActionVisu"},"remoteEntry":{"name":"customRuleBlocks.js","path":"","type":"module"},"ssrRemoteEntry":{"name":"customRuleBlocks.js","path":"","type":"module"},"types":{"path":"","name":""},"globalName":"ActionVisu","pluginVersion":"0.2.5","publicPath":"./"},"shared":[{"id":"ActionVisu:react","name":"react","version":"18.3.1","singleton":true,"requiredVersion":"*","assets":{"js":{"async":[],"sync":["assets/index-Ccpql4vu.js"]},"css":{"async":[],"sync":[]}}},{"id":"ActionVisu:@iobroker/adapter-react-v5","name":"@iobroker/adapter-react-v5","version":"8.1.6","singleton":true,"requiredVersion":"*","assets":{"js":{"async":[],"sync":["assets/index-
|
|
1
|
+
{"id":"ActionVisu","name":"ActionVisu","metaData":{"name":"ActionVisu","type":"app","buildInfo":{"buildVersion":"1.0.0","buildName":"ActionVisu"},"remoteEntry":{"name":"customRuleBlocks.js","path":"","type":"module"},"ssrRemoteEntry":{"name":"customRuleBlocks.js","path":"","type":"module"},"types":{"path":"","name":""},"globalName":"ActionVisu","pluginVersion":"0.2.5","publicPath":"./"},"shared":[{"id":"ActionVisu:react","name":"react","version":"18.3.1","singleton":true,"requiredVersion":"*","assets":{"js":{"async":[],"sync":["assets/index-Ccpql4vu.js"]},"css":{"async":[],"sync":[]}}},{"id":"ActionVisu:@iobroker/adapter-react-v5","name":"@iobroker/adapter-react-v5","version":"8.1.6","singleton":true,"requiredVersion":"*","assets":{"js":{"async":[],"sync":["assets/index-DYx5xsZT.js"]},"css":{"async":[],"sync":[]}}},{"id":"ActionVisu:react-dom","name":"react-dom","version":"18.3.1","singleton":true,"requiredVersion":"*","assets":{"js":{"async":[],"sync":["assets/index-DiSsXjpZ.js"]},"css":{"async":[],"sync":[]}}}],"remotes":[],"exposes":[{"id":"ActionVisu:ActionVisu","name":"ActionVisu","assets":{"js":{"async":[],"sync":["assets/ActionVisu-BCZFwf_Y.js"]},"css":{"async":[],"sync":[]}},"path":"./ActionVisu"}],"buildOutput":[{"fileName":"customRuleBlocks.js","type":"chunk","isEntry":true,"size":77210},{"fileName":"assets/ActionVisu__loadShare___mf_0_iobroker_mf_1_adapter_mf_2_react_mf_2_v5__loadShare__.js-D5qEIjqV.js","type":"chunk","isEntry":false,"size":2470},{"fileName":"assets/ActionVisu__loadShare__react__loadShare__.js-aa1tDx2C.js","type":"chunk","isEntry":false,"size":2183},{"fileName":"assets/ActionVisu__loadShare__react__loadShare__.js_commonjs-proxy-DX6cx281.js","type":"chunk","isEntry":false,"size":854},{"fileName":"assets/ActionVisu__loadShare__react_mf_2_dom__loadShare__.js-uY2qDezJ.js","type":"chunk","isEntry":false,"size":1463},{"fileName":"assets/ActionVisu__loadShare__react_mf_2_dom__loadShare__.js_commonjs-proxy-27bLZRGy.js","type":"chunk","isEntry":false,"size":211},{"fileName":"assets/hostInit-CoWylRge.js","type":"chunk","isEntry":true,"size":152},{"fileName":"assets/virtualExposes-B2aPQUg7.js","type":"chunk","isEntry":true,"size":840},{"fileName":"assets/ActionVisu-BCZFwf_Y.js","type":"chunk","isEntry":true,"size":2273},{"fileName":"assets/index-C1ZEp-2N.js","type":"chunk","isEntry":true,"size":865},{"fileName":"assets/preload-helper-BDBacUwf.js","type":"chunk","isEntry":false,"size":1264},{"fileName":"assets/localSharedImportMap-CNn4MUou.js","type":"chunk","isEntry":false,"size":1412},{"fileName":"assets/bootstrap-QjsDSZNA.js","type":"chunk","isEntry":false,"size":531},{"fileName":"assets/index-DYx5xsZT.js","type":"chunk","isEntry":false,"size":2265601},{"fileName":"assets/jsx-runtime-CnsYFZsa.js","type":"chunk","isEntry":false,"size":724},{"fileName":"assets/index-Ccpql4vu.js","type":"chunk","isEntry":false,"size":6974},{"fileName":"assets/index-DiSsXjpZ.js","type":"chunk","isEntry":false,"size":134353},{"fileName":"index.html","type":"asset","isEntry":false,"size":630},{"fileName":"mf-manifest.json","type":"asset","isEntry":false,"size":1226}],"assetAnalysis":{"./src/ActionVisu.tsx":{"js":{"sync":["assets/ActionVisu-BCZFwf_Y.js"],"async":[]},"css":{"sync":[],"async":[]}},"@iobroker/adapter-react-v5":{"js":{"sync":["assets/index-DYx5xsZT.js"],"async":[]},"css":{"sync":[],"async":[]}},"react":{"js":{"sync":["assets/index-Ccpql4vu.js"],"async":[]},"css":{"sync":[],"async":[]}},"react-dom":{"js":{"sync":["assets/index-DiSsXjpZ.js"],"async":[]},"css":{"sync":[],"async":[]}}}}
|
|
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const AlexaResponse_1 = __importDefault(require("../AlexaResponse"));
|
|
7
7
|
const Base_1 = __importDefault(require("./Base"));
|
|
8
|
+
const DiscoveryValidator_1 = require("../../Helpers/DiscoveryValidator");
|
|
8
9
|
class Discovery extends Base_1.default {
|
|
9
10
|
static setAllProactiveAndRetrievableFalse(obj) {
|
|
10
11
|
if (obj === null || obj === undefined) {
|
|
@@ -54,11 +55,11 @@ class Discovery extends Base_1.default {
|
|
|
54
55
|
});
|
|
55
56
|
});
|
|
56
57
|
const json = response.get();
|
|
57
|
-
this.log.silly(`${JSON.stringify(response.get())}`);
|
|
58
58
|
// To do, activate it again after status report will work
|
|
59
59
|
//if (endpointManager.validTill <= Date.now()) {
|
|
60
60
|
Discovery.setAllProactiveAndRetrievableFalse(json);
|
|
61
61
|
//}
|
|
62
|
+
(0, DiscoveryValidator_1.validateDiscoveryResponse)(json, this.log);
|
|
62
63
|
return Promise.resolve(json);
|
|
63
64
|
}
|
|
64
65
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Discovery.js","sourceRoot":"","sources":["../../../../../src/lib/AlexaSmartHomeV3/Alexa/Directives/Discovery.ts"],"names":[],"mappings":";;;;;AAAA,qEAA6C;AAC7C,kDAA0B;
|
|
1
|
+
{"version":3,"file":"Discovery.js","sourceRoot":"","sources":["../../../../../src/lib/AlexaSmartHomeV3/Alexa/Directives/Discovery.ts"],"names":[],"mappings":";;;;;AAAA,qEAA6C;AAC7C,kDAA0B;AAG1B,yEAA6E;AAE7E,MAAqB,SAAU,SAAQ,cAAI;IACvC,MAAM,CAAC,kCAAkC,CAAC,GAAQ;QAC9C,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,KAAK,SAAS,EAAE,CAAC;YACpC,OAAO,GAAG,CAAC;QACf,CAAC;QAED,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;YACrB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBAClC,SAAS,CAAC,kCA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B,CAAC;gBACxB,UAAU,EAAE,QAAQ,CAAC,EAAE;gBACvB,WAAW,EAAE,QAAQ,CAAC,WAAW,IAAI,SAAS;gBAC9C,YAAY,EAAE,QAAQ,CAAC,YAAY;gBACnC,iBAAiB,EAAE,QAAQ,CAAC,iBAAiB,IAAI,EAAE;gBACnD,YAAY,EACR,QAAQ,CAAC,YAAY,EAAE,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC,QAAQ,CAAC,oBAAoB,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;oBACjG,EAAE;aACT,CAAC,CAAC;QACP,CAAC,CAAC,CAAC;QAEH,MAAM,IAAI,GAAG,QAAQ,CAAC,GAAG,EAAE,CAAC;QAE5B,yDAAyD;QACzD,gDAAgD;QAChD,SAAS,CAAC,kCAAkC,CAAC,IAAI,CAAC,CAAC;QACnD,GAAG;QAEH,IAAA,8CAAyB,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC;QAE1C,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IACjC,CAAC;CACJ;AAtED,4BAsEC","sourcesContent":["import AlexaResponse from '../AlexaResponse';\nimport Base from './Base';\nimport type { AlexaV3Request } from '../../types';\nimport type DeviceManager from '../../DeviceManager';\nimport { validateDiscoveryResponse } from '../../Helpers/DiscoveryValidator';\n\nexport default class Discovery extends Base {\n static setAllProactiveAndRetrievableFalse(obj: any): any {\n if (obj === null || obj === undefined) {\n return obj;\n }\n\n if (Array.isArray(obj)) {\n for (let i = 0; i < obj.length; i++) {\n Discovery.setAllProactiveAndRetrievableFalse(obj[i]);\n }\n return obj;\n }\n\n if (typeof obj === 'object') {\n for (const key of Object.keys(obj)) {\n if (key === 'proactivelyReported' || key === 'retrievable') {\n obj[key] = false;\n } else {\n Discovery.setAllProactiveAndRetrievableFalse(obj[key]);\n }\n }\n }\n\n return obj;\n }\n\n handle(event: AlexaV3Request, endpointManager: DeviceManager): Promise<AlexaResponse> {\n this.log.debug(`handling Discovery`);\n this.log.silly(`${JSON.stringify(event)}`);\n\n const endpoints = endpointManager.endpoints;\n\n const response = new AlexaResponse({\n namespace: Discovery.namespace,\n name: 'Discover.Response',\n messageId: event?.directive?.header?.messageId,\n });\n\n let count = 0;\n\n endpoints.forEach(endpoint => {\n count++;\n if (count > 300) {\n this.log.warn(\n `Too many devices. Alexa supports up to 300 devices. ${endpoint.friendlyName} will not be discovered.`,\n );\n return;\n }\n response.addPayloadEndpoint({\n endpointId: endpoint.id,\n description: endpoint.description || undefined,\n friendlyName: endpoint.friendlyName,\n displayCategories: endpoint.displayCategories || [],\n capabilities:\n endpoint.capabilities?.map(capability => response.asEndpointCapability(capability.alexaResponse)) ||\n [],\n });\n });\n\n const json = response.get();\n\n // To do, activate it again after status report will work\n //if (endpointManager.validTill <= Date.now()) {\n Discovery.setAllProactiveAndRetrievableFalse(json);\n //}\n\n validateDiscoveryResponse(json, this.log);\n\n return Promise.resolve(json);\n }\n}\n"]}
|
|
@@ -58,7 +58,7 @@ class AirCondition extends AdjustableControl_1.default {
|
|
|
58
58
|
// set mode to OFF
|
|
59
59
|
const modeOffValue = this._thermostatMode.supportedModesAsEnum[ThermostatMode_1.default.OFF];
|
|
60
60
|
await AdapterProvider_1.default.setState(this._thermostatMode.setId, modeOffValue);
|
|
61
|
-
this._thermostatMode.currentValue =
|
|
61
|
+
this._thermostatMode.currentValue = modeOffValue;
|
|
62
62
|
this._powerState.currentValue = false;
|
|
63
63
|
}
|
|
64
64
|
}
|
|
@@ -158,7 +158,7 @@ class AirCondition extends AdjustableControl_1.default {
|
|
|
158
158
|
return 0;
|
|
159
159
|
},
|
|
160
160
|
alexaGetter: function (value) {
|
|
161
|
-
return (value !== undefined && states[value]
|
|
161
|
+
return (value !== undefined && states[value]) || 'AUTO';
|
|
162
162
|
},
|
|
163
163
|
supportedModes: supportedModes,
|
|
164
164
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AirCondition.js","sourceRoot":"","sources":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AG,CAAE;YAC/B,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,CAAE;SAC7D,CAAC;IACN,CAAC;CACJ;AA5LD,+BA4LC","sourcesContent":["import ThermostatController from '../Alexa/Capabilities/ThermostatController';\nimport ThermostatMode from '../Alexa/Properties/ThermostatMode';\nimport PowerController from '../Alexa/Capabilities/PowerController';\nimport TemperatureSensor from '../Alexa/Capabilities/TemperatureSensor';\nimport PowerState from '../Alexa/Properties/PowerState';\nimport AdjustableControl from './AdjustableControl';\nimport { ensureValueInRange } from '../Helpers/Utils';\nimport TargetSetpoint from '../Alexa/Properties/TargetSetpoint';\nimport type { Base as PropertiesBase, ControlStateInitObject } from '../Alexa/Properties/Base';\nimport AdapterProvider from '../Helpers/AdapterProvider';\nimport type {\n AlexaV3Category,\n AlexaV3DirectiveValue,\n AlexaV3ThermostatMode,\n IotExternalDetectorState,\n IotExternalPatternControl,\n} from '../types';\nimport EndpointHealth from '../Alexa/Capabilities/EndpointHealth';\n\nexport default class AirCondition extends AdjustableControl {\n private readonly _thermostatController: ThermostatController;\n private readonly _thermostatMode: ThermostatMode;\n private readonly _powerController: PowerController;\n private readonly _powerState: PowerState;\n private _lastKnownMode: number | string | undefined;\n\n constructor(detectedControl: IotExternalPatternControl) {\n super(detectedControl);\n\n this._thermostatController = new ThermostatController(\n this.composeInitObjectTargetSetpoint(),\n this.composeInitObjectThermostatMode(),\n );\n this._thermostatMode = this._thermostatController.thermostatMode;\n this._powerController = new PowerController(this.composeInitObjectPowerState());\n this._powerState = this._powerController.powerState;\n\n this._supported = [\n new TemperatureSensor(this.composeInitObjectTemperature()),\n this._thermostatController,\n this._powerController,\n ];\n const health = this.connectivityInitObject();\n if (health) {\n this._supported.push(new EndpointHealth(health));\n }\n }\n\n get categories(): AlexaV3Category[] {\n return ['AIR_CONDITIONER'];\n }\n\n adjustableProperties(): (typeof PropertiesBase)[] {\n return [TargetSetpoint];\n }\n\n get dedicatedOnOff(): boolean {\n return this.states[this.statesMap.power] !== undefined;\n }\n\n async setState(property: PropertiesBase, value: ioBroker.StateValue | undefined): Promise<void> {\n // if we set power ON/OFF via thermostat mode\n if (property.propertyName === PowerState.propertyName && !this.dedicatedOnOff) {\n // set the mode to the last known value or AUTO by switching power ON\n if (value) {\n this._lastKnownMode ||= this._thermostatMode.supportedModesAsEnum[ThermostatMode.AUTO];\n await AdapterProvider.setState(this._thermostatMode.setId, this._lastKnownMode);\n this._thermostatMode.currentValue = this._lastKnownMode;\n this._powerState.currentValue = true;\n } else {\n // set mode to OFF\n const modeOffValue = this._thermostatMode.supportedModesAsEnum[ThermostatMode.OFF];\n await AdapterProvider.setState(this._thermostatMode.setId, modeOffValue);\n this._thermostatMode.currentValue = this._lastKnownMode;\n this._powerState.currentValue = false;\n }\n } else {\n // just set the property\n await AdapterProvider.setState(property.setId, value!);\n property.currentValue = value;\n\n if (property.propertyName === ThermostatMode.propertyName) {\n this._lastKnownMode = value as string;\n if (!this.dedicatedOnOff) {\n this._powerState.currentValue = this._thermostatMode.alexaValue(value) !== ThermostatMode.OFF;\n }\n }\n }\n }\n\n async getOrRetrieveCurrentValue(property: PropertiesBase): Promise<ioBroker.StateValue> {\n if (property.currentValue === undefined) {\n property.currentValue = await AdapterProvider.getState(property.getId);\n\n // convert mode != OFF to power = true\n if (property.propertyName === this._powerState.propertyName && !this.dedicatedOnOff) {\n property.currentValue =\n property.currentValue !== this._thermostatMode.supportedModesAsEnum[ThermostatMode.OFF];\n }\n }\n\n if (property.currentValue === undefined) {\n throw new Error(`unable to retrieve ${property.getId}`);\n }\n\n return property.currentValue;\n }\n\n private composeInitObjectPowerState(): ControlStateInitObject {\n const map = this.statesMap;\n return {\n setState: this.states[map.power] || this.states[map.mode]!,\n getState: this.states[map.power] || this.states[map.mode]!,\n alexaSetter: function (alexaValue: AlexaV3DirectiveValue): boolean {\n return alexaValue === PowerState.ON;\n },\n alexaGetter: function (value: ioBroker.StateValue | undefined): AlexaV3DirectiveValue {\n return value ? PowerState.ON : PowerState.OFF;\n },\n };\n }\n\n private composeInitObjectThermostatMode(): ControlStateInitObject {\n const map = this.statesMap;\n // extract all modes\n const modes = this.states[map.mode];\n let states = modes?.common?.states || {};\n const supportedModes: AlexaV3ThermostatMode[] = [];\n if (states) {\n if (Array.isArray(states)) {\n const _states: { [modeValue: string]: string } = {};\n states.forEach(state => {\n _states[state] = state.toUpperCase();\n });\n states = _states;\n }\n // Try map to known modes 'AUTO' | 'COOL' | 'HEAT' | 'OFF' | 'ECO' | 'EM_HEAT'\n Object.keys(states).forEach(state => {\n const mode = states[state].toUpperCase();\n if (mode.includes('AUTO')) {\n supportedModes[parseInt(state, 10)] = 'AUTO';\n states[state] = 'AUTO';\n } else if (mode.includes('COOL')) {\n supportedModes[parseInt(state, 10)] = 'COOL';\n states[state] = 'COOL';\n } else if (mode.includes('HEAT')) {\n supportedModes[parseInt(state, 10)] = 'HEAT';\n states[state] = 'HEAT';\n } else if (mode.includes('ECO')) {\n supportedModes[parseInt(state, 10)] = 'ECO';\n states[state] = 'ECO';\n } else if (mode.includes('OFF')) {\n supportedModes[parseInt(state, 10)] = 'OFF';\n states[state] = 'OFF';\n } else {\n states[state] = mode;\n }\n });\n }\n if (!supportedModes.length) {\n supportedModes.push('AUTO');\n }\n\n return {\n setState: this.states[map.mode] || ({ id: undefined } as unknown as IotExternalDetectorState),\n getState: this.states[map.mode] || ({ id: undefined } as unknown as IotExternalDetectorState),\n alexaSetter: function (this: PropertiesBase, alexaValue: AlexaV3DirectiveValue): ioBroker.StateValue {\n // Convert 'AUTO' and so on into 0, 1\n const pos = Object.keys(states).indexOf(alexaValue as AlexaV3ThermostatMode);\n if (pos !== -1) {\n return Object.keys(states)[pos];\n }\n return 0;\n },\n alexaGetter: function (value: ioBroker.StateValue | undefined): AlexaV3DirectiveValue {\n return (value !== undefined && states[value as number] !== undefined) || 'AUTO';\n },\n supportedModes: supportedModes,\n };\n }\n\n private composeInitObjectTargetSetpoint(): ControlStateInitObject {\n const map = this.statesMap;\n // const range = Utils.configuredRangeOrDefault(this.states[map.set]);\n return {\n setState: this.states[map.set]!,\n getState: this.states[map.actual] || this.states[map.set]!,\n alexaSetter: function (this: PropertiesBase, alexaValue: AlexaV3DirectiveValue): ioBroker.StateValue {\n return ensureValueInRange(\n alexaValue as number,\n this.valuesRangeMin as number,\n this.valuesRangeMax as number,\n );\n },\n alexaGetter: function (value: ioBroker.StateValue | undefined): AlexaV3DirectiveValue {\n return value || 0;\n },\n };\n }\n\n private composeInitObjectTemperature(): ControlStateInitObject {\n const map = this.statesMap;\n return {\n setState: this.states[map.set]!,\n getState: this.states[map.actual] || this.states[map.set]!,\n };\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"AirCondition.js","sourceRoot":"","sources":["../../../../src/lib/AlexaSmartHomeV3/Controls/AirCondition.ts"],"names":[],"mappings":";;;;;AAAA,sGAA8E;AAC9E,wFAAgE;AAChE,4FAAoE;AACpE,gGAAwE;AACxE,gFAAwD;AACxD,4EAAoD;AACpD,4CAAsD;AACtD,wFAAgE;AAEhE,iFAAyD;AAQzD,0FAAkE;AAElE,MAAqB,YAAa,SAAQ,2BAAiB;IACtC,qBAAqB,CAAuB;IAC5C,eAAe,CAAiB;IAChC,gBAAgB,CAAkB;IAClC,WAAW,CAAa;IACjC,cAAc,CAA8B;IAEpD,YAAY,eAA0C;QAClD,KAAK,CAAC,eAAe,CAAC,CAAC;QAEvB,IAAI,CAAC,qBAAqB,GAAG,IAAI,8BAAoB,CACjD,IAAI,CAAC,+BAA+B,EAAE,EACtC,IAAI,CAAC,+BAA+B,EAAE,CACzC,CAAC;QACF,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC,qBAAqB,CAAC,cAAc,CAAC;QACjE,IAAI,CAAC,gBAAgB,GAAG,IAAI,yBAAe,CAAC,IAAI,CAAC,2BAA2B,EAAE,CAAC,CAAC;QAChF,IAAI,CAAC,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/B,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,CAAE;YAC1D,WAAW,EAAE,UAAgC,UAAiC;gBAC1E,OAAO,IAAA,0BAAkB,EACrB,UAAoB,EACpB,IAAI,CAAC,cAAwB,EAC7B,IAAI,CAAC,cAAwB,CAChC,CAAC;YACN,CAAC;YACD,WAAW,EAAE,UAAU,KAAsC;gBACzD,OAAO,KAAK,IAAI,CAAC,CAAC;YACtB,CAAC;SACJ,CAAC;IACN,CAAC;IAEO,4BAA4B;QAChC,MAAM,GAAG,GAAG,IAAI,CAAC,SAAS,CAAC;QAC3B,OAAO;YACH,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,CAAE;YAC/B,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,CAAE;SAC7D,CAAC;IACN,CAAC;CACJ;AA5LD,+BA4LC","sourcesContent":["import ThermostatController from '../Alexa/Capabilities/ThermostatController';\nimport ThermostatMode from '../Alexa/Properties/ThermostatMode';\nimport PowerController from '../Alexa/Capabilities/PowerController';\nimport TemperatureSensor from '../Alexa/Capabilities/TemperatureSensor';\nimport PowerState from '../Alexa/Properties/PowerState';\nimport AdjustableControl from './AdjustableControl';\nimport { ensureValueInRange } from '../Helpers/Utils';\nimport TargetSetpoint from '../Alexa/Properties/TargetSetpoint';\nimport type { Base as PropertiesBase, ControlStateInitObject } from '../Alexa/Properties/Base';\nimport AdapterProvider from '../Helpers/AdapterProvider';\nimport type {\n AlexaV3Category,\n AlexaV3DirectiveValue,\n AlexaV3ThermostatMode,\n IotExternalDetectorState,\n IotExternalPatternControl,\n} from '../types';\nimport EndpointHealth from '../Alexa/Capabilities/EndpointHealth';\n\nexport default class AirCondition extends AdjustableControl {\n private readonly _thermostatController: ThermostatController;\n private readonly _thermostatMode: ThermostatMode;\n private readonly _powerController: PowerController;\n private readonly _powerState: PowerState;\n private _lastKnownMode: number | string | undefined;\n\n constructor(detectedControl: IotExternalPatternControl) {\n super(detectedControl);\n\n this._thermostatController = new ThermostatController(\n this.composeInitObjectTargetSetpoint(),\n this.composeInitObjectThermostatMode(),\n );\n this._thermostatMode = this._thermostatController.thermostatMode;\n this._powerController = new PowerController(this.composeInitObjectPowerState());\n this._powerState = this._powerController.powerState;\n\n this._supported = [\n new TemperatureSensor(this.composeInitObjectTemperature()),\n this._thermostatController,\n this._powerController,\n ];\n const health = this.connectivityInitObject();\n if (health) {\n this._supported.push(new EndpointHealth(health));\n }\n }\n\n get categories(): AlexaV3Category[] {\n return ['AIR_CONDITIONER'];\n }\n\n adjustableProperties(): (typeof PropertiesBase)[] {\n return [TargetSetpoint];\n }\n\n get dedicatedOnOff(): boolean {\n return this.states[this.statesMap.power] !== undefined;\n }\n\n async setState(property: PropertiesBase, value: ioBroker.StateValue | undefined): Promise<void> {\n // if we set power ON/OFF via thermostat mode\n if (property.propertyName === PowerState.propertyName && !this.dedicatedOnOff) {\n // set the mode to the last known value or AUTO by switching power ON\n if (value) {\n this._lastKnownMode ||= this._thermostatMode.supportedModesAsEnum[ThermostatMode.AUTO];\n await AdapterProvider.setState(this._thermostatMode.setId, this._lastKnownMode);\n this._thermostatMode.currentValue = this._lastKnownMode;\n this._powerState.currentValue = true;\n } else {\n // set mode to OFF\n const modeOffValue = this._thermostatMode.supportedModesAsEnum[ThermostatMode.OFF];\n await AdapterProvider.setState(this._thermostatMode.setId, modeOffValue);\n this._thermostatMode.currentValue = modeOffValue;\n this._powerState.currentValue = false;\n }\n } else {\n // just set the property\n await AdapterProvider.setState(property.setId, value!);\n property.currentValue = value;\n\n if (property.propertyName === ThermostatMode.propertyName) {\n this._lastKnownMode = value as string;\n if (!this.dedicatedOnOff) {\n this._powerState.currentValue = this._thermostatMode.alexaValue(value) !== ThermostatMode.OFF;\n }\n }\n }\n }\n\n async getOrRetrieveCurrentValue(property: PropertiesBase): Promise<ioBroker.StateValue> {\n if (property.currentValue === undefined) {\n property.currentValue = await AdapterProvider.getState(property.getId);\n\n // convert mode != OFF to power = true\n if (property.propertyName === this._powerState.propertyName && !this.dedicatedOnOff) {\n property.currentValue =\n property.currentValue !== this._thermostatMode.supportedModesAsEnum[ThermostatMode.OFF];\n }\n }\n\n if (property.currentValue === undefined) {\n throw new Error(`unable to retrieve ${property.getId}`);\n }\n\n return property.currentValue;\n }\n\n private composeInitObjectPowerState(): ControlStateInitObject {\n const map = this.statesMap;\n return {\n setState: this.states[map.power] || this.states[map.mode]!,\n getState: this.states[map.power] || this.states[map.mode]!,\n alexaSetter: function (alexaValue: AlexaV3DirectiveValue): boolean {\n return alexaValue === PowerState.ON;\n },\n alexaGetter: function (value: ioBroker.StateValue | undefined): AlexaV3DirectiveValue {\n return value ? PowerState.ON : PowerState.OFF;\n },\n };\n }\n\n private composeInitObjectThermostatMode(): ControlStateInitObject {\n const map = this.statesMap;\n // extract all modes\n const modes = this.states[map.mode];\n let states = modes?.common?.states || {};\n const supportedModes: AlexaV3ThermostatMode[] = [];\n if (states) {\n if (Array.isArray(states)) {\n const _states: { [modeValue: string]: string } = {};\n states.forEach(state => {\n _states[state] = state.toUpperCase();\n });\n states = _states;\n }\n // Try map to known modes 'AUTO' | 'COOL' | 'HEAT' | 'OFF' | 'ECO' | 'EM_HEAT'\n Object.keys(states).forEach(state => {\n const mode = states[state].toUpperCase();\n if (mode.includes('AUTO')) {\n supportedModes[parseInt(state, 10)] = 'AUTO';\n states[state] = 'AUTO';\n } else if (mode.includes('COOL')) {\n supportedModes[parseInt(state, 10)] = 'COOL';\n states[state] = 'COOL';\n } else if (mode.includes('HEAT')) {\n supportedModes[parseInt(state, 10)] = 'HEAT';\n states[state] = 'HEAT';\n } else if (mode.includes('ECO')) {\n supportedModes[parseInt(state, 10)] = 'ECO';\n states[state] = 'ECO';\n } else if (mode.includes('OFF')) {\n supportedModes[parseInt(state, 10)] = 'OFF';\n states[state] = 'OFF';\n } else {\n states[state] = mode;\n }\n });\n }\n if (!supportedModes.length) {\n supportedModes.push('AUTO');\n }\n\n return {\n setState: this.states[map.mode] || ({ id: undefined } as unknown as IotExternalDetectorState),\n getState: this.states[map.mode] || ({ id: undefined } as unknown as IotExternalDetectorState),\n alexaSetter: function (this: PropertiesBase, alexaValue: AlexaV3DirectiveValue): ioBroker.StateValue {\n // Convert 'AUTO' and so on into 0, 1\n const pos = Object.keys(states).indexOf(alexaValue as AlexaV3ThermostatMode);\n if (pos !== -1) {\n return Object.keys(states)[pos];\n }\n return 0;\n },\n alexaGetter: function (value: ioBroker.StateValue | undefined): AlexaV3DirectiveValue {\n return (value !== undefined && states[value as number]) || 'AUTO';\n },\n supportedModes: supportedModes,\n };\n }\n\n private composeInitObjectTargetSetpoint(): ControlStateInitObject {\n const map = this.statesMap;\n // const range = Utils.configuredRangeOrDefault(this.states[map.set]);\n return {\n setState: this.states[map.set]!,\n getState: this.states[map.actual] || this.states[map.set]!,\n alexaSetter: function (this: PropertiesBase, alexaValue: AlexaV3DirectiveValue): ioBroker.StateValue {\n return ensureValueInRange(\n alexaValue as number,\n this.valuesRangeMin as number,\n this.valuesRangeMax as number,\n );\n },\n alexaGetter: function (value: ioBroker.StateValue | undefined): AlexaV3DirectiveValue {\n return value || 0;\n },\n };\n }\n\n private composeInitObjectTemperature(): ControlStateInitObject {\n const map = this.statesMap;\n return {\n setState: this.states[map.set]!,\n getState: this.states[map.actual] || this.states[map.set]!,\n };\n }\n}\n"]}
|
|
@@ -29,7 +29,7 @@ class Ct extends AdjustableControl_1.default {
|
|
|
29
29
|
if (this.states[map.on] || this._brightness) {
|
|
30
30
|
if (!this.states[map.on]) {
|
|
31
31
|
const offValue = AdapterProvider_1.default.deviceOffLevel();
|
|
32
|
-
this._offValue = (0, Utils_1.denormalize_0_100)(offValue, this._brightness.valuesRangeMin, this._brightness.
|
|
32
|
+
this._offValue = (0, Utils_1.denormalize_0_100)(offValue, this._brightness.valuesRangeMin, this._brightness.valuesRangeMax || 100);
|
|
33
33
|
}
|
|
34
34
|
this._supported.push(new Capabilities_1.default.PowerController(this.composeInitObjectPowerState()));
|
|
35
35
|
}
|