jamis
Version:
一种支持通过JSON配置方式生成页面的组件库
15 lines • 77.3 kB
JavaScript
import{g as Fr,F as Hr,G as Br,H as Se,J as Oe,K as te,L as $r,M as nr,N as rt,Q as Gr,S as ht,T as mt,U as qr}from"../sdk.js";import{_ as Qr}from"./typeof.b6c3327d.js";function _t(e,t,r,n,o,i,a){try{var l=e[i](a),c=l.value}catch(u){r(u);return}l.done?t(c):Promise.resolve(c).then(n,o)}function K(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(c){_t(i,n,o,a,l,"next",c)}function l(c){_t(i,n,o,a,l,"throw",c)}a(void 0)})}}var or={exports:{}};(function(e){var t=Qr.default;function r(){e.exports=r=function(){return o},e.exports.__esModule=!0,e.exports.default=e.exports;var n,o={},i=Object.prototype,a=i.hasOwnProperty,l=Object.defineProperty||function(w,p,b){w[p]=b.value},c=typeof Symbol=="function"?Symbol:{},u=c.iterator||"@@iterator",s=c.asyncIterator||"@@asyncIterator",g=c.toStringTag||"@@toStringTag";function f(w,p,b){return Object.defineProperty(w,p,{value:b,enumerable:!0,configurable:!0,writable:!0}),w[p]}try{f({},"")}catch{f=function(b,L,I){return b[L]=I}}function d(w,p,b,L){var I=p&&p.prototype instanceof P?p:P,S=Object.create(I.prototype),D=new $(L||[]);return l(S,"_invoke",{value:re(w,b,D)}),S}function h(w,p,b){try{return{type:"normal",arg:w.call(p,b)}}catch(L){return{type:"throw",arg:L}}}o.wrap=d;var v="suspendedStart",y="suspendedYield",m="executing",E="completed",_={};function P(){}function O(){}function x(){}var T={};f(T,u,function(){return this});var A=Object.getPrototypeOf,U=A&&A(A(z([])));U&&U!==i&&a.call(U,u)&&(T=U);var C=x.prototype=P.prototype=Object.create(T);function M(w){["next","throw","return"].forEach(function(p){f(w,p,function(b){return this._invoke(p,b)})})}function j(w,p){function b(I,S,D,R){var N=h(w[I],w,S);if(N.type!=="throw"){var H=N.arg,F=H.value;return F&&t(F)=="object"&&a.call(F,"__await")?p.resolve(F.__await).then(function(q){b("next",q,D,R)},function(q){b("throw",q,D,R)}):p.resolve(F).then(function(q){H.value=q,D(H)},function(q){return b("throw",q,D,R)})}R(N.arg)}var L;l(this,"_invoke",{value:function(S,D){function R(){return new p(function(N,H){b(S,D,N,H)})}return L=L?L.then(R,R):R()}})}function re(w,p,b){var L=v;return function(I,S){if(L===m)throw Error("Generator is already running");if(L===E){if(I==="throw")throw S;return{value:n,done:!0}}for(b.method=I,b.arg=S;;){var D=b.delegate;if(D){var R=W(D,b);if(R){if(R===_)continue;return R}}if(b.method==="next")b.sent=b._sent=b.arg;else if(b.method==="throw"){if(L===v)throw L=E,b.arg;b.dispatchException(b.arg)}else b.method==="return"&&b.abrupt("return",b.arg);L=m;var N=h(w,p,b);if(N.type==="normal"){if(L=b.done?E:y,N.arg===_)continue;return{value:N.arg,done:b.done}}N.type==="throw"&&(L=E,b.method="throw",b.arg=N.arg)}}}function W(w,p){var b=p.method,L=w.iterator[b];if(L===n)return p.delegate=null,b==="throw"&&w.iterator.return&&(p.method="return",p.arg=n,W(w,p),p.method==="throw")||b!=="return"&&(p.method="throw",p.arg=new TypeError("The iterator does not provide a '"+b+"' method")),_;var I=h(L,w.iterator,p.arg);if(I.type==="throw")return p.method="throw",p.arg=I.arg,p.delegate=null,_;var S=I.arg;return S?S.done?(p[w.resultName]=S.value,p.next=w.nextLoc,p.method!=="return"&&(p.method="next",p.arg=n),p.delegate=null,_):S:(p.method="throw",p.arg=new TypeError("iterator result is not an object"),p.delegate=null,_)}function ie(w){var p={tryLoc:w[0]};1 in w&&(p.catchLoc=w[1]),2 in w&&(p.finallyLoc=w[2],p.afterLoc=w[3]),this.tryEntries.push(p)}function G(w){var p=w.completion||{};p.type="normal",delete p.arg,w.completion=p}function $(w){this.tryEntries=[{tryLoc:"root"}],w.forEach(ie,this),this.reset(!0)}function z(w){if(w||w===""){var p=w[u];if(p)return p.call(w);if(typeof w.next=="function")return w;if(!isNaN(w.length)){var b=-1,L=function I(){for(;++b<w.length;)if(a.call(w,b))return I.value=w[b],I.done=!1,I;return I.value=n,I.done=!0,I};return L.next=L}}throw new TypeError(t(w)+" is not iterable")}return O.prototype=x,l(C,"constructor",{value:x,configurable:!0}),l(x,"constructor",{value:O,configurable:!0}),O.displayName=f(x,g,"GeneratorFunction"),o.isGeneratorFunction=function(w){var p=typeof w=="function"&&w.constructor;return!!p&&(p===O||(p.displayName||p.name)==="GeneratorFunction")},o.mark=function(w){return Object.setPrototypeOf?Object.setPrototypeOf(w,x):(w.__proto__=x,f(w,g,"GeneratorFunction")),w.prototype=Object.create(C),w},o.awrap=function(w){return{__await:w}},M(j.prototype),f(j.prototype,s,function(){return this}),o.AsyncIterator=j,o.async=function(w,p,b,L,I){I===void 0&&(I=Promise);var S=new j(d(w,p,b,L),I);return o.isGeneratorFunction(p)?S:S.next().then(function(D){return D.done?D.value:S.next()})},M(C),f(C,g,"Generator"),f(C,u,function(){return this}),f(C,"toString",function(){return"[object Generator]"}),o.keys=function(w){var p=Object(w),b=[];for(var L in p)b.push(L);return b.reverse(),function I(){for(;b.length;){var S=b.pop();if(S in p)return I.value=S,I.done=!1,I}return I.done=!0,I}},o.values=z,$.prototype={constructor:$,reset:function(p){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(G),!p)for(var b in this)b.charAt(0)==="t"&&a.call(this,b)&&!isNaN(+b.slice(1))&&(this[b]=n)},stop:function(){this.done=!0;var p=this.tryEntries[0].completion;if(p.type==="throw")throw p.arg;return this.rval},dispatchException:function(p){if(this.done)throw p;var b=this;function L(H,F){return D.type="throw",D.arg=p,b.next=H,F&&(b.method="next",b.arg=n),!!F}for(var I=this.tryEntries.length-1;I>=0;--I){var S=this.tryEntries[I],D=S.completion;if(S.tryLoc==="root")return L("end");if(S.tryLoc<=this.prev){var R=a.call(S,"catchLoc"),N=a.call(S,"finallyLoc");if(R&&N){if(this.prev<S.catchLoc)return L(S.catchLoc,!0);if(this.prev<S.finallyLoc)return L(S.finallyLoc)}else if(R){if(this.prev<S.catchLoc)return L(S.catchLoc,!0)}else{if(!N)throw Error("try statement without catch or finally");if(this.prev<S.finallyLoc)return L(S.finallyLoc)}}}},abrupt:function(p,b){for(var L=this.tryEntries.length-1;L>=0;--L){var I=this.tryEntries[L];if(I.tryLoc<=this.prev&&a.call(I,"finallyLoc")&&this.prev<I.finallyLoc){var S=I;break}}S&&(p==="break"||p==="continue")&&S.tryLoc<=b&&b<=S.finallyLoc&&(S=null);var D=S?S.completion:{};return D.type=p,D.arg=b,S?(this.method="next",this.next=S.finallyLoc,_):this.complete(D)},complete:function(p,b){if(p.type==="throw")throw p.arg;return p.type==="break"||p.type==="continue"?this.next=p.arg:p.type==="return"?(this.rval=this.arg=p.arg,this.method="return",this.next="end"):p.type==="normal"&&b&&(this.next=b),_},finish:function(p){for(var b=this.tryEntries.length-1;b>=0;--b){var L=this.tryEntries[b];if(L.finallyLoc===p)return this.complete(L.completion,L.afterLoc),G(L),_}},catch:function(p){for(var b=this.tryEntries.length-1;b>=0;--b){var L=this.tryEntries[b];if(L.tryLoc===p){var I=L.completion;if(I.type==="throw"){var S=I.arg;G(L)}return S}}throw Error("illegal catch attempt")},delegateYield:function(p,b,L){return this.delegate={iterator:z(p),resultName:b,nextLoc:L},this.method==="next"&&(this.arg=n),_}},o}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports})(or);var Yr=or.exports,Me=Yr(),Xr=Me;try{regeneratorRuntime=Me}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=Me:Function("r","regeneratorRuntime = r")(Me)}const k=Fr(Xr);function Vr(e){if(Array.isArray(e))return Hr(e)}function zr(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Zr(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ge(e){return Vr(e)||zr(e)||Br(e)||Zr()}var Te="data-wujie-id",Ne="data-wujie-script-id",ir="data-wujie-Flag",nt="data-container-position-flag",We="data-container-overflow-flag",gt="data-loading-flag",Pt="data-wujie-attach-css-flag",Kr="wujie_iframe",Ce="_wujie_all_event",en="position: fixed; z-index: 2147483647; visibility: hidden; inset: 0px; backface-visibility: hidden;",tn="position: absolute; width: 100%; height: 100%; display: flex; justify-content: center; align-items: center; z-index:1;",rn=`<svg xmlns="http://www.w3.org/2000/svg" width="24px" height="30px" viewBox="0 0 24 30">
<rect x="0" y="13" width="4" height="5" fill="#909090">
<animate attributeName="height" attributeType="XML" values="5;21;5" begin="0s" dur="0.6s" repeatCount="indefinite"></animate>
<animate attributeName="y" attributeType="XML" values="13; 5; 13" begin="0s" dur="0.6s" repeatCount="indefinite"></animate>
</rect>
<rect x="10" y="13" width="4" height="5" fill="#909090">
<animate attributeName="height" attributeType="XML" values="5;21;5" begin="0.15s" dur="0.6s" repeatCount="indefinite"></animate>
<animate attributeName="y" attributeType="XML" values="13; 5; 13" begin="0.15s" dur="0.6s" repeatCount="indefinite"></animate>
</rect>
<rect x="20" y="13" width="4" height="5" fill="#909090">
<animate attributeName="height" attributeType="XML" values="5;21;5" begin="0.3s" dur="0.6s" repeatCount="indefinite"></animate>
<animate attributeName="y" attributeType="XML" values="13; 5; 13" begin="0.3s" dur="0.6s" repeatCount="indefinite"></animate>
</rect>
</svg>`,nn="url参数为空",ar="子应用调用reload无法生效",ur="此报错可以忽略,iframe主动中断主应用代码在子应用运行",on=ur+",详见:https://github.com/Tencent/wujie/issues/54",Lt="事件订阅数量为空",an="window上不存在fetch属性,需要自行polyfill",un="当前浏览器不支持无界,子应用将采用iframe方式渲染",Ie="脚本请求出现错误",ze="样式请求出现错误",St="html请求出现错误",It="无界组件短时间重复渲染了两次,可能存在性能问题请检查代码",cn="目标Script尚未准备好或已经被移除",ln="不支持document.getElementById()传入特殊字符,请参考document.querySelector文档";function le(e){return typeof e=="function"}function sn(e){return(e==null?void 0:e.toUpperCase())==="LINK"||(e==null?void 0:e.toUpperCase())==="STYLE"||(e==null?void 0:e.toUpperCase())==="SCRIPT"||(e==null?void 0:e.toUpperCase())==="IFRAME"}var cr=window.Proxy&&window.CustomElementRegistry,dn=typeof document.all=="function"&&typeof document.all>"u",Tt=new WeakMap,ke=function(t){if(Tt.has(t))return!0;var r=dn?typeof t=="function"&&typeof t<"u":typeof t=="function";return r&&Tt.set(t,r),r},Ze=new WeakMap;function lr(e){if(Ze.has(e))return Ze.get(e);var t=e.name.indexOf("bound ")===0&&!e.hasOwnProperty("prototype");return Ze.set(e,t),t}var Ke=new WeakMap;function yt(e){var t=e.prototype&&e.prototype.constructor===e&&Object.getOwnPropertyNames(e.prototype).length>1;if(t)return!0;if(Ke.has(e))return Ke.get(e);var r=t;if(!r){var n=e.toString(),o=/^function\b\s[A-Z].*/,i=/^class\b/;r=o.test(n)||i.test(n)}return Ke.set(e,r),r}var Q=new WeakMap;function fn(e,t){ke(t)&&!lr(t)&&!yt(t)&&(Q.has(e)?Q.get(e).has(t)||Q.get(e).set(t,t):(Q.set(e,new WeakMap),Q.get(e).set(t,t)))}function Le(e,t){var r=e[t];if(Q.has(e)&&Q.get(e).has(r))return Q.get(e).get(r);if(ke(r)&&!lr(r)&&!yt(r)){var n=Function.prototype.bind.call(r,e);Q.has(e)||Q.set(e,new WeakMap),Q.get(e).set(r,n);for(var o in r)n[o]=r[o];return r.hasOwnProperty("prototype")&&!n.hasOwnProperty("prototype")&&Object.defineProperty(n,"prototype",{value:r.prototype,enumerable:!1,writable:!0}),n}return r}function sr(e){return window.document.querySelector("iframe[".concat(Te,'="').concat(e,'"]'))}function qe(e,t){Object.keys(t).forEach(function(r){e.setAttribute(r,t[r])})}function dr(e){if(!e)throw Z(nn),new Error;var t=ee(e),r=t.protocol+"//"+t.host,n=t.pathname+t.search+t.hash;return n.startsWith("/")||(n="/"+n),{urlElement:t,appHostPath:r,appRoutePath:n}}function ee(e){var t=window.document.createElement("a");return t.href=e,t.href=t.href,t}function _e(e){var t=e.search||"";return Ge(new URLSearchParams(t).entries()).reduce(function(r,n){return r[n[0]]=n[1],r},{})}function fr(e){var t=_e(ee(window.location.href));return Object.keys(t).includes(e)}function me(e,t,r){var n=e.Element.prototype.setAttribute;t.prototype.setAttribute=function(u,s){var g=s;u===r&&(g=se(s,this.baseURI||"",!0)),n.call(this,u,g)};var o=Object.getOwnPropertyDescriptor(t.prototype,r),i=o.enumerable,a=o.configurable,l=o.get,c=o.set;Object.defineProperty(t.prototype,r,{enumerable:i,configurable:a,get:function(){return l.call(this)},set:function(s){c.call(this,se(s,this.baseURI,!0))}})}function Qe(e){var t=e;return t.protocol+"//"+t.host+t.pathname}function se(e,t,r){try{return e&&(r&&e.startsWith("#")?e:new URL(e,t).href)}catch{return e}}function vn(e,t){var r,n=ee(window.location.href),o=_e(n);n=null;var i=window.decodeURIComponent(o[e]||""),a=(r=i.match(/^{([^}]*)}/))===null||r===void 0?void 0:r[1];return t&&a?i.replace("{".concat(a,"}"),t[a]):i}var Et=window.requestIdleCallback||function(e){return setTimeout(e,1)};function vr(e){return typeof e=="string"?document.querySelector(e):e}function B(e,t){var r;(r=console)===null||r===void 0||r.warn("[wujie warn]: ".concat(e),t)}function Z(e,t){var r;(r=console)===null||r===void 0||r.error("[wujie error]: ".concat(e),t)}function ot(e){var t=e.indexOf(">")+1,r=e.lastIndexOf("<");return e.substring(t,r)}function pn(e){if(Se(e)==="object")return"/";try{var t=new URL(e,location.href),r=t.origin,n=t.pathname,o=n.split("/");return o.pop(),"".concat(r).concat(o.join("/"),"/")}catch(i){return console.warn(i),""}}function Ye(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];return e.reduce(function(i,a){return le(a)?a.apply(void 0,[i].concat(n)):i},t||"")}}function Re(e){Promise.resolve().then(e)}function Y(e,t){for(var r=arguments.length,n=new Array(r>2?r-2:0),o=2;o<r;o++)n[o-2]=arguments[o];try{e&&e.length>0&&e.map(function(i){return i[t]}).filter(function(i){return le(i)}).forEach(function(i){return i.apply(void 0,n)})}catch(i){Z(i)}}function Xe(e){var t;return((t=e.tagName)===null||t===void 0?void 0:t.toUpperCase())==="SCRIPT"}var hn=1;function pr(e,t){if(Xe(e)){var r=t||String(hn++);e.setAttribute(Ne,r)}}function hr(e){return Xe(e)?e.getAttribute(Ne):null}function mr(e,t){return{name:e.name,el:e.el||(t==null?void 0:t.el),url:e.url||(t==null?void 0:t.url),html:e.html||(t==null?void 0:t.html),exec:e.exec!==void 0?e.exec:t==null?void 0:t.exec,replace:e.replace||(t==null?void 0:t.replace),fetch:e.fetch||(t==null?void 0:t.fetch),props:e.props||(t==null?void 0:t.props),sync:e.sync!==void 0?e.sync:t==null?void 0:t.sync,prefix:e.prefix||(t==null?void 0:t.prefix),loading:e.loading||(t==null?void 0:t.loading),attrs:e.attrs!==void 0?e.attrs:(t==null?void 0:t.attrs)||{},degradeAttrs:e.degradeAttrs!==void 0?e.degradeAttrs:(t==null?void 0:t.degradeAttrs)||{},fiber:e.fiber!==void 0?e.fiber:(t==null?void 0:t.fiber)!==void 0?t==null?void 0:t.fiber:!0,alive:e.alive!==void 0?e.alive:t==null?void 0:t.alive,degrade:e.degrade!==void 0?e.degrade:t==null?void 0:t.degrade,plugins:e.plugins||(t==null?void 0:t.plugins),lifecycles:{beforeLoad:e.beforeLoad||(t==null?void 0:t.beforeLoad),beforeMount:e.beforeMount||(t==null?void 0:t.beforeMount),afterMount:e.afterMount||(t==null?void 0:t.afterMount),beforeUnmount:e.beforeUnmount||(t==null?void 0:t.beforeUnmount),afterUnmount:e.afterUnmount||(t==null?void 0:t.afterUnmount),activated:e.activated||(t==null?void 0:t.activated),deactivated:e.deactivated||(t==null?void 0:t.deactivated),loadError:e.loadError||(t==null?void 0:t.loadError)}}}function je(e,t,r){var n;typeof window.CustomEvent=="function"?n=new CustomEvent(t,{detail:r}):(n=document.createEvent("CustomEvent"),n.initCustomEvent(t,!0,!1,r)),e.dispatchEvent(n)}function gr(){throw B(on),new Error(ur)}var mn=/(<script[\s\S]*?>)[\s\S]*?<\/script>/gi,gn=/<(script)\s+((?!type=('|")text\/ng-template\3)[^])*?>[^]*?<\/\1>/i,Ot=/.*\ssrc=('|")?([^>'"\s]+)/,yn=/.*\stype=('|")?([^>'"\s]+)/,En=/.*\sentry\s*.*/,bn=/.*\sasync\s*.*/,wn=/.*\sdefer\s*.*/,_n=/.*\snomodule\s*.*/,Pn=/.*\stype=('|")?module('|")?\s*.*/,Ln=/<(link)\s+[^]*?>/gi,Sn=/\srel=('|")?(preload|prefetch|modulepreload)\1/,Ct=/.*\shref=('|")?([^>'"\s]+)/,In=/.*\sas=('|")?font\1.*/,Tn=/<style[^>]*>[\s\S]*?<\/style>/gi,On=/\s+rel=('|")?stylesheet\1.*/,Cn=/.*\shref=('|")?([^>'"\s]+)/,Rn=/<!--([\s\S]*?)-->/g,jn=/<link(\s+|\s+[^]+\s+)ignore(\s*|\s+[^]*|=[^]*)>/i,xn=/<style(\s+|\s+[^]+\s+)ignore(\s*|\s+[^]*|=[^]*)>/i,Un=/<script(\s+|\s+[^]+\s+)ignore(\s*|\s+[^]*|=[^]*)>/i,An=/.*\scrossorigin=?('|")?(use-credentials|anonymous)?('|")?/i;function Rt(e){return e.startsWith("//")||e.startsWith("http://")||e.startsWith("https://")}function jt(e,t){return new URL(e,t).toString()}function Mn(e){var t=["text/javascript","module","application/javascript","text/ecmascript","application/ecmascript"];return!e||t.indexOf(e)!==-1}function fe(e){var t=/<[-\w]+\s+([^>]*)>/i,r=t.exec(e);if(!r)return{};for(var n=r[1],o=/([^\s=]+)\s*=\s*(['"])(.*?)\2/g,i={},a;(a=o.exec(n))!==null;){var l=a[1],c=a[3];i[l]=c}return i}function Dn(){var e=window.document.createElement("script");return"noModule"in e}var it=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return"<!-- ".concat(r?"prefetch/preload/modulepreload":""," link ").concat(t," replaced by wujie -->")},yr=function(t){return"<!-- inline-style-".concat(t," replaced by wujie -->")},Nn=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return"<!-- ".concat(r," script ").concat(t," replaced by wujie -->")},Wn="<!-- inline scripts replaced by wujie -->",xe=function(t){return"<!-- ignore asset ".concat(t||"file"," replaced by wujie -->")},xt=function(t,r){return"<!-- ".concat(r?"nomodule":"module"," script ").concat(t," ignored by wujie -->")};function kn(e,t,r){var n=[],o=[],i=null,a=Dn(),l=e.replace(Rn,"").replace(Ln,function(u){var s=!!u.match(On);if(s){var g=u.match(Cn),f=u.match(jn);if(g){var d=g&&g[2],h=d;return d&&!Rt(d)&&(h=jt(d,t)),f?xe(h):(o.push({src:h}),it(h))}}var v=u.match(Sn)&&u.match(Ct)&&!u.match(In);if(v){var y=u.match(Ct),m=Oe(y,3),E=m[2];return it(E,!0)}return u}).replace(Tn,function(u){if(xn.test(u))return xe("style file");var s=ot(u);return o.push({src:"",content:s}),yr(o.length-1)}).replace(mn,function(u,s){var g=s.match(Un),f=!!s.match(Pn),d=s.match(An),h=(d==null?void 0:d[2])||"",v=a&&!!s.match(_n)||!a&&f,y=s.match(yn),m=y&&y[2];if(!Mn(m))return u;if(gn.test(u)&&s.match(Ot)){var E=s.match(En),_=s.match(Ot),P=_&&_[2];if(i&&E)throw new SyntaxError("You should not set multiply entry script!");if(P&&!Rt(P)&&(P=jt(P,t)),i=i||E&&P,g)return xe(P||"js file");if(v)return xt(P||"js file",a);if(P){var O=!!s.match(bn),x=!!s.match(wn);return n.push(O||x?{async:O,defer:x,src:P,module:f,crossorigin:!!d,crossoriginType:h,attrs:fe(u)}:{src:P,module:f,crossorigin:!!d,crossoriginType:h,attrs:fe(u)}),Nn(P,O&&"async"||x&&"defer"||"")}return u}else{if(g)return xe("js file");if(v)return xt("js file",a);var T=ot(u),A=T.split(/[\r\n]+/).every(function(U){return!U.trim()||U.trim().startsWith("//")});return!A&&T&&n.push({src:"",content:T,module:f,crossorigin:!!d,crossoriginType:h,attrs:fe(u)}),Wn}}),c={template:l,scripts:n,styles:o,entry:i||n[n.length-1]};return typeof r=="function"&&(c=r(c)),c}function at(e){var t=e.plugins,r=e.replace;return function(n){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",i=arguments.length>2?arguments[2]:void 0;return Ye(t.map(function(a){return a.cssLoader}))(r?r(n):n,o,i)}}function Jn(e){var t=e.plugins,r=e.replace;return function(n){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",i=arguments.length>2?arguments[2]:void 0;return Ye(t.map(function(a){return a.jsLoader}))(r?r(n):n,o,i)}}function Je(e,t){var r=t.map(function(o){return o[e]}).filter(function(o){return o==null?void 0:o.length}),n=r.reduce(function(o,i){return o.concat(i)},[]);return e==="cssBeforeLoaders"?n.reverse():n}function ue(e,t){return t.map(function(r){return r[e]}).filter(function(r){return r==null?void 0:r.length}).reduce(function(r,n){return r.concat(n)},[])}function ce(e,t){return t.some(function(r){return typeof r=="string"?e===r:r.test(e)})}function Fn(e,t,r){var n=t?se(t,r):r,o=/url\((['"]?)((?:[^()]+|\((?:[^()]+|\([^()]*\))*\))*)(\1)\)/g;return e.replace(o,function(i,a,l,c){var u=/^data:/,s=u.test(l);return s?i:"url(".concat(a).concat(se(l,n)).concat(c,")")})}var Ut={cssLoader:Fn,cssBeforeLoaders:[{content:"html {view-transition-name: none;}"}]};function Er(e){return Array.isArray(e)?[Ut].concat(Ge(e)):[Ut]}function At(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ee(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?At(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):At(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Hn={},et={},tt={};if(!window.fetch)throw Z(an),new Error;var bt=window.fetch.bind(window);function Bn(e){return e}function br(e,t,r){return ut.apply(this,arguments)}function ut(){return ut=K(k.mark(function e(t,r,n){var o,i,a,l;return k.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return o=Qe(t.proxyLocation),i=Ye(t.plugins.map(function(s){return s.cssLoader})),a=n().map(function(s){var g=s.src,f=s.ignore,d=s.contentPromise;return{src:g,ignore:f,contentPromise:d.then(function(h){return i(h,g,o)})}}),u.next=5,$n(r,a);case 5:return l=u.sent,u.abrupt("return",t.replace?t.replace(l):l);case 7:case"end":return u.stop()}},e)})),ut.apply(this,arguments)}function $n(e,t){return ct.apply(this,arguments)}function ct(){return ct=K(k.mark(function e(t,r){var n;return k.wrap(function(i){for(;;)switch(i.prev=i.next){case 0:return n=t,i.abrupt("return",Promise.all(r.map(function(a,l){return a.contentPromise.then(function(c){a.src?n=n.replace(it(a.src),a.ignore?'<link href="'.concat(a.src,'" rel="stylesheet" type="text/css">'):"<style>/* ".concat(a.src," */").concat(c,"</style>")):c&&(n=n.replace(yr(l),"<style>/* inline-style-".concat(l," */").concat(c,"</style>")))})})).then(function(){return n}));case 2:case"end":return i.stop()}},e)})),ct.apply(this,arguments)}var Gn=function(t){return t.startsWith("<")},De=function(t,r,n,o,i){return r[t]||(r[t]=n(t).then(function(a){if(a.status>=400){if(r[t]=null,o)return Z(ze,{src:t,response:a}),i==null||i(t,new Error(ze)),"";throw Z(Ie,{src:t,response:a}),i==null||i(t,new Error(Ie)),new Error(Ie)}return a.text()}).catch(function(a){return r[t]=null,o?(Z(ze,t),i==null||i(t,a),""):(Z(Ie,t),i==null||i(t,a),"")}))};function Fe(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:bt,r=arguments.length>2?arguments[2]:void 0;return e.map(function(n){var o=n.src,i=n.content,a=n.ignore;return i?{src:"",contentPromise:Promise.resolve(i)}:Gn(o)?{src:"",contentPromise:Promise.resolve(ot(o))}:{src:o,ignore:a,contentPromise:a?Promise.resolve(""):De(o,Hn,t,!0,r)}})}function wr(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:bt,r=arguments.length>2?arguments[2]:void 0,n=arguments.length>3?arguments[3]:void 0;return e.map(function(o){var i=o.src,a=o.async,l=o.defer,c=o.module,u=o.ignore,s=null;return(a||l)&&i&&!c?s=new Promise(function(g,f){return n?Et(function(){return De(i,et,t,!1,r).then(g,f)}):De(i,et,t,!1,r).then(g,f)}):c&&i||u?s=Promise.resolve(""):i?s=De(i,et,t,!1,r):s=Promise.resolve(o.content),c&&!a&&(o.defer=!0),Ee(Ee({},o),{},{contentPromise:s})})}function lt(e){var t,r,n=e.url,o=e.opts,i=e.html,a=(t=o.fetch)!==null&&t!==void 0?t:bt,l=(r=o.fiber)!==null&&r!==void 0?r:!0,c=o.plugins,u=o.loadError,s=c?Ye(c.map(function(m){return m.htmlLoader})):Bn,g=ue("jsExcludes",c),f=ue("cssExcludes",c),d=ue("jsIgnores",c),h=ue("cssIgnores",c),v=pn,y=function(E,_,P){return(_?Promise.resolve(_):a(E).then(function(O){return O.status>=400?(Z(St,{url:E,response:O}),u==null||u(E,new Error(St)),""):O.text()}).catch(function(O){return tt[E]=null,u==null||u(E,O),Promise.reject(O)})).then(function(O){var x=v(E),T=kn(P(O),x),A=T.template,U=T.scripts,C=T.styles;return{template:A,assetPublicPath:x,getExternalScripts:function(){return wr(U.filter(function(j){return!j.src||!ce(j.src,g)}).map(function(j){return Ee(Ee({},j),{},{ignore:j.src&&ce(j.src,d)})}),a,u,l)},getExternalStyleSheets:function(){return Fe(C.filter(function(j){return!j.src||!ce(j.src,f)}).map(function(j){return Ee(Ee({},j),{},{ignore:j.src&&ce(j.src,h)})}),a,u)}}})};return o!=null&&o.plugins.some(function(m){return m.htmlLoader})?y(n,i,s):tt[n]||(tt[n]=y(n,i,s))}function qn(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function Qn(e,t,r){if($r())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,t);var o=new(e.bind.apply(e,n));return r&&nr(o,r.prototype),o}function st(e){var t=typeof Map=="function"?new Map:void 0;return st=function(n){if(n===null||!qn(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(n))return t.get(n);t.set(n,o)}function o(){return Qn(n,arguments,rt(this).constructor)}return o.prototype=Object.create(n.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),nr(o,n)},st(e)}function Mt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function He(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Mt(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Mt(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var X=window.__POWERED_BY_WUJIE__?window.__WUJIE.inject.idToSandboxMap:new Map;function oe(e){var t;return((t=X.get(e))===null||t===void 0?void 0:t.wujie)||null}function _r(e){var t;return((t=X.get(e))===null||t===void 0?void 0:t.options)||null}function Yn(e,t){var r=X.get(e);r?X.set(e,He(He({},r),{},{wujie:t})):X.set(e,{wujie:t})}function Xn(e){var t=X.get(e);t!=null&&t.options&&X.set(e,{options:t.options}),X.delete(e)}function Vn(e,t){var r=X.get(e);r?X.set(e,He(He({},r),{},{options:t})):X.set(e,{options:t})}var J={modifyLocalProperties:["createElement","createTextNode","documentURI","URL","getElementsByTagName","getElementById"],modifyProperties:["createElement","createTextNode","documentURI","URL","getElementsByTagName","getElementsByClassName","getElementsByName","getElementById","querySelector","querySelectorAll","documentElement","scrollingElement","forms","images","links"],shadowProperties:["activeElement","childElementCount","children","firstElementChild","firstChild","fullscreenElement","lastElementChild","pictureInPictureElement","pointerLockElement","styleSheets"],shadowMethods:["append","contains","getSelection","elementFromPoint","elementsFromPoint","getAnimations","replaceChildren"],documentProperties:["characterSet","compatMode","contentType","designMode","dir","doctype","embeds","fullscreenEnabled","hidden","implementation","lastModified","pictureInPictureEnabled","plugins","readyState","referrer","visibilityState","fonts"],documentMethods:["execCommand","caretPositionFromPoint","createRange","exitFullscreen","exitPictureInPicture","getElementsByTagNameNS","hasFocus","prepend"],documentEvents:["onpointerlockchange","onpointerlockerror","onbeforecopy","onbeforecut","onbeforepaste","onfreeze","onresume","onsearch","onfullscreenchange","onfullscreenerror","onsecuritypolicyviolation","onvisibilitychange"],ownerProperties:["head","body"]},Dt=["DOMContentLoaded","readystatechange"],zn=["onreadystatechange"],Nt=["fullscreenchange","fullscreenerror","selectionchange","visibilitychange","wheel","keydown","keypress","keyup"],Wt=["gotpointercapture","lostpointercapture"],kt=["hashchange","popstate","DOMContentLoaded","load","beforeunload","unload","message","error","unhandledrejection"],Zn=["onload","onbeforeunload","onunload","onerror","onunhandledrejection"],Kn={IMG:"src",A:"href",SOURCE:"src"},eo=["getComputedStyle","visualViewport","matchMedia","DOMParser"],to=[/animationFrame$/i,/resizeObserver$|mutationObserver$|intersectionObserver$/i,/height$|width$|left$/i,/^screen/i,/CSSStyleSheet$/i,/X$|Y$/],Pr=HTMLElement.prototype.appendChild,Lr=HTMLElement.prototype.removeChild,Jt=HTMLElement.prototype.contains,ro=HTMLHeadElement.prototype.insertBefore,no=HTMLBodyElement.prototype.insertBefore,wt=Node.prototype.addEventListener,Ve=Node.prototype.removeEventListener,Ft=window.addEventListener,Ht=window.removeEventListener,ve=Node.prototype.appendChild,pe=window.__POWERED_BY_WUJIE__?window.__WUJIE_RAW_DOCUMENT_QUERY_SELECTOR__:Document.prototype.querySelector;function Bt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ge(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Bt(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Bt(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function oo(e,t){return Object.defineProperties(e,{srcElement:{get:t},target:{get:t}}),e}function Ue(e,t){var r=new CustomEvent(t),n=oo(r,function(){return e});le(e["on".concat(t)])?e["on".concat(t)](n):e.dispatchEvent(n)}function be(e,t){if(!(!e.innerHTML||t.degrade)){var r=function(){var o=jr([e.sheet]),i=Oe(o,2),a=i[0],l=i[1];a&&t.shadowRoot.head.appendChild(a),l&&t.shadowRoot.host.appendChild(l),e._patcher=void 0};e._patcher&&clearTimeout(e._patcher),e._patcher=setTimeout(r,50)}}function io(e,t,r,n){var o;if(e._hasPatchStyle)return;var i=Object.getOwnPropertyDescriptor(Element.prototype,"innerHTML"),a=Object.getOwnPropertyDescriptor(HTMLElement.prototype,"innerText"),l=Object.getOwnPropertyDescriptor(Node.prototype,"textContent"),c=(o=e.sheet)===null||o===void 0?void 0:o.insertRule;function u(){c&&(e.sheet.insertRule=function(s,g){return i?e.innerHTML+=s:e.innerText+=s,c.call(e.sheet,s,g)})}u(),i&&Object.defineProperties(e,{innerHTML:{get:function(){return i.get.call(e)},set:function(g){var f=this;i.set.call(e,t(g,"",n)),Re(function(){return be(f,r)})}}}),Object.defineProperties(e,{innerText:{get:function(){return a.get.call(e)},set:function(g){var f=this;a.set.call(e,t(g,"",n)),Re(function(){return be(f,r)})}},textContent:{get:function(){return l.get.call(e)},set:function(g){var f=this;l.set.call(e,t(g,"",n)),Re(function(){return be(f,r)})}},appendChild:{value:function(g){var f=this;if(Re(function(){return be(f,r)}),g.nodeType===Node.TEXT_NODE){var d=ve.call(e,e.ownerDocument.createTextNode(t(g.textContent,"",n)));return u(),d}else return ve(g)}},_hasPatchStyle:{get:function(){return!0}}})}var $t=Promise.resolve();function Ae(e){return function(r,n){var o=this,i=r,a=e.rawDOMAppendOrInsertBefore,l=e.wujieId,c=oe(l),u=c.styleSheetElements,s=c.replace,g=c.fetch,f=c.plugins,d=c.iframe,h=c.lifecycles,v=c.proxyLocation,y=c.fiber;if(!sn(i.tagName)||!l){var m=a.call(this,i,n);return ne(i,d.contentWindow),Y(f,"appendOrInsertElementHook",i,d.contentWindow),m}var E=d.contentDocument,_=Qe(v);if(i.tagName){var P;switch((P=i.tagName)===null||P===void 0?void 0:P.toUpperCase()){case"LINK":{var O=i,x=O.href,T=O.rel,A=O.type,U=T==="stylesheet"||A==="text/css"||x.endsWith(".css");if(!U){var C=a.call(this,i,n);return Y(f,"appendOrInsertElementHook",i,d.contentWindow),C}x&&!ce(x,ue("cssExcludes",f))&&Fe([{src:x,ignore:ce(x,ue("cssIgnores",f))}],g,h.loadError).forEach(function(N){var H=N.src,F=N.ignore,q=N.contentPromise;return q.then(function(Wr){var kr=fe(i.outerHTML);if(F&&H)a.call(o,i,n);else{var Pe=E.createElement("style"),Jr=at({plugins:f,replace:s});Pe.innerHTML=Jr(Wr,H,_),u.push(Pe),qe(Pe,kr),a.call(o,Pe,n),be(Pe,c),Ue(i,"load")}i=null},function(){Ue(i,"error"),i=null})});var M=E.createComment("dynamic link ".concat(x," replaced by wujie"));return a.call(this,M,n)}case"STYLE":{var j=r;u.push(j);var re=j.innerHTML,W=at({plugins:f,replace:s});re&&(j.innerHTML=W(re,"",_));var ie=a.call(this,i,n);return io(j,W,c,_),be(j,c),Y(f,"appendOrInsertElementHook",i,d.contentWindow),ie}case"SCRIPT":{pr(i);var G=i,$=G.src,z=G.text,w=G.type,p=G.crossOrigin;if($&&!ce($,ue("jsExcludes",f))){var b=function(H){if(c.iframe===null)return B(It);var F=function(){Ue(i,"load"),i=null};V(ge(ge({},H),{},{onload:F}),c.iframe.contentWindow,i)},L={src:$,module:w==="module",crossorigin:p!==null,crossoriginType:p||"",ignore:ce($,ue("jsIgnores",f)),attrs:fe(i.outerHTML)};wr([L],g,h.loadError,y).forEach(function(N){$t=$t.then(function(){return N.contentPromise.then(function(H){var F;if(c.execQueue===null)return B(It);var q=(F=c.execQueue)===null||F===void 0?void 0:F.length;c.execQueue.push(function(){return y?c.requestIdleCallback(function(){b(ge(ge({},N),{},{content:H}))}):b(ge(ge({},N),{},{content:H}))}),q||c.execQueue.shift()()},function(){Ue(i,"error"),i=null})})})}else{var I,S=(I=c.execQueue)===null||I===void 0?void 0:I.length;c.execQueue.push(function(){return y?c.requestIdleCallback(function(){V({src:null,content:z,attrs:fe(i.outerHTML)},c.iframe.contentWindow,i)}):V({src:null,content:z,attrs:fe(i.outerHTML)},c.iframe.contentWindow,i)}),S||c.execQueue.shift()()}var D=E.createComment("dynamic script ".concat($," replaced by wujie"));return a.call(this,D,n)}case"IFRAME":{if(i.getAttribute(ir)==="")return ve.call(pe.call(this.ownerDocument,"html"),i);var R=a.call(this,i,n);return Y(f,"appendOrInsertElementHook",i,d.contentWindow),R}}}}}function Sr(e,t){var r=hr(e),n=oe(t),o=n.iframe,i=o.contentWindow.__WUJIE_RAW_DOCUMENT_HEAD__.querySelector("script[".concat(Ne,"='").concat(r,"']"));return i===null&&B(cn,"<script ".concat(Ne,"='").concat(r,"'/>")),{targetScript:i,iframe:o}}function Gt(e){return function(r){var n=r,o=e.rawElementContains,i=e.wujieId;if(n&&Xe(n)){var a=Sr(n,i),l=a.targetScript;return l!==null}return o(n)}}function ao(e){return function(r){var n=r,o=e.rawElementRemoveChild,i=e.wujieId;if(n&&Xe(n)){var a=Sr(n,i),l=a.targetScript,c=a.iframe;return l!==null?c.contentWindow.__WUJIE_RAW_DOCUMENT_HEAD__.removeChild(l):null}return o(n)}}function qt(e){var t=new Map;e._cacheListeners=t,e.addEventListener=function(r,n,o){var i=t.get(r)||[];return t.set(r,[].concat(Ge(i),[n])),wt.call(e,r,n,o)},e.removeEventListener=function(r,n,o){var i=t.get(r),a=i==null?void 0:i.indexOf(n);return i!=null&&i.length&&a!==-1&&i.splice(a,1),Ve.call(e,r,n,o)}}function Qt(e){var t=e._cacheListeners;Ge(t.entries()).forEach(function(r){var n=Oe(r,2),o=n[0],i=n[1];i.forEach(function(a){return Ve.call(e,o,a)})})}function Ir(e,t,r){r||(qt(e.head),qt(e.body)),e.head.appendChild=Ae({rawDOMAppendOrInsertBefore:ve,wujieId:t}),e.head.insertBefore=Ae({rawDOMAppendOrInsertBefore:ro,wujieId:t}),e.head.removeChild=ao({rawElementRemoveChild:Lr.bind(e.head),wujieId:t}),e.head.contains=Gt({rawElementContains:Jt.bind(e.head),wujieId:t}),e.contains=Gt({rawElementContains:Jt.bind(e),wujieId:t}),e.body.appendChild=Ae({rawDOMAppendOrInsertBefore:ve,wujieId:t}),e.body.insertBefore=Ae({rawDOMAppendOrInsertBefore:no,wujieId:t})}function Yt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Xt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Yt(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Yt(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function uo(e,t,r){return t=rt(t),qr(e,Tr()?Reflect.construct(t,r||[],rt(e).constructor):t.apply(e,r))}function Tr(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Tr=function(){return!!e})()}var co={":root":":host"};function lo(){var e=window.customElements;if(e&&!(e!=null&&e.get("wujie-app"))){var t=function(r){function n(){return mt(this,n),uo(this,n,arguments)}return Gr(n,r),ht(n,[{key:"connectedCallback",value:function(){if(!this.shadowRoot){var i=this.attachShadow({mode:"open"}),a=oe(this.getAttribute(Te));ne(i,a.iframe.contentWindow),a.shadowRoot=i}}},{key:"disconnectedCallback",value:function(){var i=oe(this.getAttribute(Te));i==null||i.unmount()}}])}(st(HTMLElement));e==null||e.define("wujie-app",t)}}function so(e){var t=window.document.createElement("wujie-app");return t.setAttribute(Te,e),t.classList.add(Kr),t}function he(e,t){var r=vr(t);return r&&!r.contains(e)&&(r.querySelector("div[".concat(gt,"]"))||de(r),e&&Pr.call(r,e)),r}function Or(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=po(e,r),o=he(n,t),i=n.contentWindow.document;return i.open(),i.write("<!DOCTYPE html><html><head></head><body></body></html>"),i.close(),{iframe:n,container:o}}function Cr(e,t){return dt.apply(this,arguments)}function dt(){return dt=K(k.mark(function e(t,r){var n,o,i,a,l,c,u,s;return k.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return n=t.iframe.contentDocument,o=t.plugins,i=t.replace,a=t.proxyLocation,l=at({plugins:o,replace:i}),c=Je("cssBeforeLoaders",o),u=Je("cssAfterLoaders",o),s=Qe(a),f.next=8,Promise.all([Promise.all(Fe(c,t.fetch,t.lifecycles.loadError).map(function(d){var h=d.src,v=d.contentPromise;return v.then(function(y){return{src:h,content:y}})})).then(function(d){d.forEach(function(h){var v=h.src,y=h.content;if(y){var m=n.createElement("style");m.setAttribute("type","text/css"),m.appendChild(n.createTextNode(y&&l(y,v,s)));var E=r.querySelector("head"),_=r.querySelector("body");r.insertBefore(m,E||_||r.firstChild)}})}),Promise.all(Fe(u,t.fetch,t.lifecycles.loadError).map(function(d){var h=d.src,v=d.contentPromise;return v.then(function(y){return{src:h,content:y}})})).then(function(d){d.forEach(function(h){var v=h.src,y=h.content;if(y){var m=n.createElement("style");m.setAttribute("type","text/css"),m.appendChild(n.createTextNode(y&&l(y,v,s))),r.appendChild(m)}})})]).then(function(){return r},function(){return r});case 8:return f.abrupt("return",f.sent);case 9:case"end":return f.stop()}},e)})),dt.apply(this,arguments)}function fo(e,t,r){var n=e.querySelector("head"),o=e.querySelector("body");if(n){for(;n.firstChild;)ve.call(t,n.firstChild.cloneNode(!0)),n.removeChild(n.firstChild);n.parentNode.replaceChild(t,n)}if(o){for(;o.firstChild;)ve.call(r,o.firstChild.cloneNode(!0)),o.removeChild(o.firstChild);o.parentNode.replaceChild(r,o)}return e}function Rr(e,t){var r=e.__WUJIE,n=r.head,o=r.body,i=r.alive,a=r.execFlag,l=e.document,c=new DOMParser,u=c.parseFromString(t,"text/html"),s=u.documentElement,g=s.attributes,f=l.createElement("html");f.innerHTML=t;for(var d=0;d<g.length;d++)f.setAttribute(g[d].name,g[d].value);!i&&a?f=fo(f,n,o):(r.head=f.querySelector("head"),r.body=f.querySelector("body"));for(var h=l.createTreeWalker(f,NodeFilter.SHOW_ELEMENT,null,!1),v=h.currentNode;v;){ne(v,e);var y=Kn[v.tagName],m=v[y];y&&v.setAttribute(y,se(m,v.baseURI||"")),v=h.nextNode()}if(!f.querySelector("head")){var E=l.createElement("head");f.appendChild(E)}if(!f.querySelector("body")){var _=l.createElement("body");f.appendChild(_)}return f}function vo(e,t,r){return ft.apply(this,arguments)}function ft(){return ft=K(k.mark(function e(t,r,n){var o,i,a;return k.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return o=Rr(r,n),c.next=3,Cr(r.__WUJIE,o);case 3:i=c.sent,t.appendChild(i),a=document.createElement("div"),a.setAttribute("style",en),i.insertBefore(a,i.firstChild),t.head=t.querySelector("head"),t.body=t.querySelector("body"),Object.defineProperty(t.firstChild,"parentNode",{enumerable:!0,configurable:!0,get:function(){return r.document}}),Ir(t,r.__WUJIE.id,!1);case 12:case"end":return c.stop()}},e)})),ft.apply(this,arguments)}function po(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=document.createElement("iframe"),n="height:100%;width:100%";return qe(r,Xt(Xt({},t),{},te({style:[n,t.style].join(";")},Te,e))),r}function Vt(e,t,r){return vt.apply(this,arguments)}function vt(){return vt=K(k.mark(function e(t,r,n){var o,i;return k.wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return o=Rr(r,n),l.next=3,Cr(r.__WUJIE,o);case 3:i=l.sent,t.replaceChild(i,t.documentElement),Object.defineProperty(t.documentElement,"parentNode",{enumerable:!0,configurable:!0,get:function(){return r.document}}),Ir(t,r.__WUJIE.id,!0);case 7:case"end":return l.stop()}},e)})),vt.apply(this,arguments)}function de(e){for(;e!=null&&e.firstChild;)Lr.call(e,e.firstChild)}function ho(e,t){var r=vr(e);de(r);var n=null;try{n=window.getComputedStyle(r)}catch{return}n.position==="static"?(r.setAttribute(nt,n.position),r.setAttribute(We,n.overflow==="visible"?"":n.overflow),r.style.setProperty("position","relative"),r.style.setProperty("overflow","hidden")):["relative","sticky"].includes(n.position)&&(r.setAttribute(We,n.overflow==="visible"?"":n.overflow),r.style.setProperty("overflow","hidden"));var o=document.createElement("div");o.setAttribute(gt,""),o.setAttribute("style",tn),t?o.appendChild(t):o.innerHTML=rn,r.appendChild(o)}function zt(e){var t=e.getAttribute(nt),r=e.getAttribute(We);t&&e.style.removeProperty("position"),r!==null&&(r?e.style.setProperty("overflow",r):e.style.removeProperty("overflow")),e.removeAttribute(nt),e.removeAttribute(We);var n=e.querySelector("div[".concat(gt,"]"));n&&e.removeChild(n)}function jr(e){for(var t=[],r=[],n=/:root/g,o=0;o<e.length;o++)for(var i,a,l=(i=(a=e[o])===null||a===void 0?void 0:a.cssRules)!==null&&i!==void 0?i:[],c=0;c<l.length;c++){var u=l[c].cssText;n.test(u)&&t.push(u.replace(n,function(f){return co[f]})),l[c].type===CSSRule.FONT_FACE_RULE&&r.push(u)}var s=null,g=null;return t.length&&(s=window.document.createElement("style"),s.innerHTML=t.join("")),r.length&&(g=window.document.createElement("style"),g.innerHTML=r.join("")),[s,g]}function we(e){var t=e.__WUJIE,r=t.sync,n=t.id,o=t.prefix,i=ee(window.location.href),a=_e(i);if(!r&&!a[n])return i=null;var l=e.location.pathname+e.location.search+e.location.hash,c="";o&&Object.keys(o).forEach(function(s){var g=o[s];l.startsWith(g)&&(!c||g.length>o[c].length)&&(c=s)}),r?a[n]=window.encodeURIComponent(c?l.replace(o[c],"{".concat(c,"}")):l):delete a[n];var u="?"+Object.keys(a).map(function(s){return s+"="+a[s]}).join("&");i.search=u,i.href!==window.location.href&&window.history.replaceState(null,"",i.href),i=null}function mo(e){var t=e.location,r=t.pathname,n=t.search,o=t.hash,i=e.__WUJIE,a=i.id,l=i.url,c=i.sync,u=i.execFlag,s=i.prefix,g=i.inject,f=c&&!u?vn(a,s):l,d=(/^http/.test(f)?null:f)||l,h=dr(d),v=h.appRoutePath,y=r+n+o;y!==v&&e.history.replaceState(null,"",g.mainHostPath+v)}function go(){var e=ee(window.location.href),t=_e(e);Object.keys(t).forEach(function(n){var o=oe(n);o&&o.execFlag&&o.sync&&!o.hrefFlag&&!o.activeFlag&&delete t[n]});var r="?"+Object.keys(t).map(function(n){return n+"="+t[n]}).join("&");e.search=r,e.href!==window.location.href&&window.history.replaceState(null,"",e.href),e=null}function yo(e,t){var r=ee(window.location.href),n=_e(r);n[e]=window.encodeURIComponent(t);var o="?"+Object.keys(n).map(function(i){return i+"="+n[i]}).join("&");r.search=o,window.history.pushState(null,"",r.href),r=null}function Eo(){window.addEventListener("popstate",function(){var e=ee(window.location.href),t=_e(e);e=null,Object.keys(t).map(function(r){return oe(r)}).filter(function(r){return r}).forEach(function(r){var n=t[r.id],o=pe.call(r.iframe.contentDocument,"body");if(/http/.test(n))r.degrade?(he(r.document.documentElement,o),$e(window.decodeURIComponent(n),sr(r.id).parentElement,r.degradeAttrs)):$e(window.decodeURIComponent(n),r.shadowRoot.host.parentElement,r.degradeAttrs),r.hrefFlag=!0;else if(r.hrefFlag){if(r.degrade){var i=Or(r.id,r.el,r.degradeAttrs),a=i.iframe;xr(a.contentWindow,r.iframe.contentWindow),a.contentWindow.onunload=function(){r.unmount()},a.contentDocument.appendChild(o.firstElementChild),r.document=a.contentDocument}else he(r.shadowRoot.host,r.el);r.hrefFlag=!1}})})}function Zt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Be(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Zt(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Zt(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function bo(e){e.__WUJIE_EVENTLISTENER__=e.__WUJIE_EVENTLISTENER__||new Set,e.addEventListener=function(r,n,o){if(Y(e.__WUJIE.plugins,"windowAddEventListenerHook",e,r,n,o),e.__WUJIE_EVENTLISTENER__.add({type:r,listener:n,options:o}),kt.includes(r)||Se(o)==="object"&&o.targetWindow){var i=Se(o)==="object"&&o.targetWindow?o==null?void 0:o.targetWindow:e;return Ft.call(i,r,n,o)}Ft.call(window.__WUJIE_RAW_WINDOW__||window,r,n,o)},e.removeEventListener=function(r,n,o){if(Y(e.__WUJIE.plugins,"windowRemoveEventListenerHook",e,r,n,o),e.__WUJIE_EVENTLISTENER__.forEach(function(a){a.listener===n&&a.type===r&&o==a.options&&e.__WUJIE_EVENTLISTENER__.delete(a)}),kt.includes(r)||Se(o)==="object"&&o.targetWindow){var i=Se(o)==="object"&&o.targetWindow?o==null?void 0:o.targetWindow:e;return Ht.call(i,r,n,o)}Ht.call(window.__WUJIE_RAW_WINDOW__||window,r,n,o)}}function Kt(e,t,r){e.__WUJIE=t,e.__WUJIE_PUBLIC_PATH__=r+"/",e.$wujie=t.provide,e.__WUJIE_RAW_WINDOW__=e}function wo(e,t,r){var n=e.history,o=n.pushState,i=n.replaceState;n.pushState=function(a,l,c){var u=r+e.location.pathname+e.location.search+e.location.hash,s=se(c==null?void 0:c.replace(t,""),u),g=c===void 0;o.call(n,a,l,g?void 0:s),!g&&(er(e,t,r),we(e))},n.replaceState=function(a,l,c){var u=r+e.location.pathname+e.location.search+e.location.hash,s=se(c==null?void 0:c.replace(t,""),u),g=c===void 0;i.call(n,a,l,g?void 0:s),!g&&(er(e,t,r),we(e))}}function er(e,t,r){var n,o=new URL((n=e.location.href)===null||n===void 0?void 0:n.replace(r,""),t),i=pe.call(e.document,"base");i&&i.setAttribute("href",t+o.pathname)}function _o(e){function t(n){var o=e[n];try{return typeof o=="function"&&!yt(o)?e[n]=window[n].bind(window):e[n]=window[n],!0}catch(i){return B(i.message),!1}}Object.getOwnPropertyNames(e).forEach(function(n){if(n==="getSelection"){Object.defineProperty(e,n,{get:function(){return e.document[n]}});return}if(eo.includes(n)){t(n);return}to.some(function(o){return o.test(n)&&n in e.parent?t(n):!1})});var r=Object.getOwnPropertyNames(window).filter(function(n){return/^on/.test(n)}).filter(function(n){return!Zn.includes(n)});r.forEach(function(n){var o=Object.getOwnPropertyDescriptor(e,n)||{enumerable:!0,writable:!0};try{Object.defineProperty(e,n,{enumerable:o.enumerable,configurable:!0,get:function(){return window[n]},set:o.writable||o.set?function(i){window[n]=typeof i=="function"?i.bind(e):i}:void 0})}catch(i){B(i.message)}}),Y(e.__WUJIE.plugins,"windowPropertyOverride",e)}function Po(e){var t=e.__WUJIE;e.Node.prototype.addEventListener=function(r,n,o){var i=t.elementEventCacheMap.get(this);return i?i.find(function(a){return a.type===r&&a.handler===n})||i.push({type:r,handler:n,options:o}):t.elementEventCacheMap.set(this,[{type:r,handler:n,options:o}]),wt.call(this,r,n,o)},e.Node.prototype.removeEventListener=function(r,n,o){var i=t.elementEventCacheMap.get(this);if(i){var a=i==null?void 0:i.findIndex(function(l){return l.type===r&&l.handler===n});i.splice(a,1)}return i!=null&&i.length||t.elementEventCacheMap.delete(this),Ve.call(this,r,n,o)}}function Lo(e,t){for(var r=t.__WUJIE,n=new WeakMap,o=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,null,!1),i=o.currentNode;i;){var a=r.elementEventCacheMap.get(i);a!=null&&a.length&&(n.set(i,a),a.forEach(function(l){i.addEventListener(l.type,l.handler,l.options)})),i=o.nextNode()}r.elementEventCacheMap=n}function So(e,t,r){var n=r.__WUJIE,o=new WeakMap,i=n.elementEventCacheMap.get(e);i!=null&&i.length&&(o.set(t,i),i.forEach(function(a){t.addEventListener(a.type,a.handler,a.options)})),n.elementEventCacheMap=o}function xr(e,t){Object.defineProperty(e.Event.prototype,"timeStamp",{get:function(){return t.document.createEvent("Event").timeStamp}})}function Io(e){var t=e.__WUJIE,r=new WeakMap,n=new WeakMap;e.Document.prototype.addEventListener=function(d,h,v){if(h){var y=r.get(h),m=n.get(h);if(y||(y=typeof h=="function"?h.bind(this):h,r.set(h,y)),m?m.includes(d)||m.push(d):n.set(h,[d]),Y(e.__WUJIE.plugins,"documentAddEventListenerHook",e,d,y,v),Dt.includes(d))return wt.call(this,d,y,v);if(t.degrade)return t.document.addEventListener(d,y,v);if(Nt.includes(d))return window.document.addEventListener(d,y,v);if(Wt.includes(d)){window.document.addEventListener(d,y,v),t.shadowRoot.addEventListener(d,y,v);return}t.shadowRoot.addEventListener(d,y,v)}},e.Document.prototype.removeEventListener=function(d,h,v){var y=r.get(h),m=n.get(h);if(y){if(m!=null&&m.includes(d)&&(m.splice(m.indexOf(d),1),m.length||(r.delete(h),n.delete(h))),Y(e.__WUJIE.plugins,"documentRemoveEventListenerHook",e,d,y,v),Dt.includes(d))return Ve.call(this,d,y,v);if(t.degrade)return t.document.removeEventListener(d,y,v);if(Nt.includes(d))return window.document.removeEventListener(d,y,v);if(Wt.includes(d)){window.document.removeEventListener(d,y,v),t.shadowRoot.removeEventListener(d,y,v);return}t.shadowRoot.removeEventListener(d,y,v)}};var o=Object.keys(e.HTMLElement.prototype).filter(function(d){return/^on/.test(d)}),i=Object.keys(e.Document.prototype).filter(function(d){return/^on/.test(d)}).filter(function(d){return!zn.includes(d)});o.filter(function(d){return i.includes(d)}).forEach(function(d){var h=Object.getOwnPropertyDescriptor(e.Document.prototype,d)||{enumerable:!0,writable:!0};try{Object.defineProperty(e.Docume